/* =============================================================================
   Confirm dialog. Loaded by every layout that can destroy something, so it is
   its own file rather than a passage inside site.css or admin.css: the two
   would drift, and this is one of the few pieces of the site where a difference
   between the public side and the panel would actually matter.

   Deliberately neutral in colour so it reads the same over the light public
   pages and the dark panel: the box is white, the backdrop is near-black.
   ========================================================================== */
.cfm {
  position: fixed; inset: 0; z-index: 9000;
  display: flex; align-items: center; justify-content: center; padding: 24px;
  background: rgba(12,14,10,.55); backdrop-filter: blur(3px);
  animation: cfm-in .14s ease;
}
@keyframes cfm-in { from { opacity: 0; } to { opacity: 1; } }

.cfm__box {
  width: 100%; max-width: 400px; box-sizing: border-box;
  background: #fff; color: #14160f; border-radius: 16px; padding: 26px 26px 20px;
  text-align: center; box-shadow: 0 24px 60px -18px rgba(0,0,0,.5);
  font-family: "Segoe UI", system-ui, -apple-system, sans-serif;
  animation: cfm-pop .16s cubic-bezier(.2,.9,.3,1.2);
}
@keyframes cfm-pop { from { transform: scale(.94); } to { transform: scale(1); } }

.cfm__icon {
  width: 52px; height: 52px; margin: 0 auto 14px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: #eef8f2; color: #05a558;
}
.cfm__icon--danger { background: #fdecea; color: #c0392b; }

.cfm__title { margin: 0 0 7px; font-size: 19px; font-weight: 700; line-height: 1.25; }
/* The question can carry a title somebody typed, so it wraps rather than runs. */
.cfm__text { margin: 0; font-size: 14px; line-height: 1.55; color: #565a4f; overflow-wrap: anywhere; }

.cfm__acts { display: flex; gap: 10px; margin-top: 22px; }
.cfm__btn {
  flex: 1; font: inherit; font-size: 14.5px; font-weight: 600; cursor: pointer;
  padding: 11px 16px; border-radius: 999px; border: 1px solid transparent;
  background: #14160f; color: #fff;
}
.cfm__btn:hover { filter: brightness(1.12); }
.cfm__btn:focus-visible { outline: 2px solid #05a558; outline-offset: 2px; }
.cfm__btn--ghost { background: #fff; color: #565a4f; border-color: rgba(20,22,15,.22); }
.cfm__btn--ghost:hover { background: #f6f8f4; filter: none; }
.cfm__btn--danger { background: #c0392b; }

@media (max-width: 420px) {
  .cfm__acts { flex-direction: column-reverse; }
}
