/* =========================================================
   NOTIFICATION MODAL — findfyre.com
   Layout mirrors the profile page's fpModal: compact card,
   small top-left icon, LEFT-aligned title/message, a coloured
   top border per type, and buttons in a bottom row. This is the
   single site-wide alert (all $.confirm calls route here), so
   every alert shares this look.

   NOTE: all text is sized in px ON PURPOSE — the legacy site
   sets the root font-size to 10px, so rem-based sizes render
   tiny. Do not convert these back to rem.
   ========================================================= */

#ffnotif-modalRoot,
#ffnotif-modalRoot *,
#ffnotif-modalRoot *::before,
#ffnotif-modalRoot *::after {
    box-sizing: border-box;
}

#ffnotif-modalRoot {
    all: initial;
    font-family: Inter, system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif !important;
    font-size: 15px !important;
    line-height: 1.4 !important;
    color: #fff !important;
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: none;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

#ffnotif-modalRoot * {
    font-family: inherit !important;
}

#ffnotif-modalRoot.ffnotif-isOpen {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

/* Backdrop */
#ffnotif-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(4, 6, 10, 0.72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    animation: ffnotifFadeIn 180ms ease-out forwards;
}

@keyframes ffnotifFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* Dialog — compact card, LEFT aligned, coloured top edge per type */
#ffnotif-dialog {
    position: relative;
    width: 100%;
    max-width: 380px;
    border-radius: 18px;
    padding: 22px 24px 22px;
    background: #1a1922;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-top: 3px solid #ff2f86; /* overridden per type below */
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.58);
    display: flex;
    flex-direction: column;
    align-items: stretch;
    text-align: left;
    animation: ffnotifSlideUp 200ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes ffnotifSlideUp {
    from { opacity: 0; transform: translateY(10px) scale(0.98); }
    to   { opacity: 1; transform: translateY(0)    scale(1);    }
}

#ffnotif-dialog.ffnotif-closing {
    animation: ffnotifSlideDown 170ms ease-in forwards;
}

@keyframes ffnotifSlideDown {
    from { opacity: 1; transform: translateY(0)   scale(1);    }
    to   { opacity: 0; transform: translateY(8px) scale(0.98); }
}

/* Topbar (logo + X) hidden — this layout closes via the footer
   button, the backdrop, or Escape, matching the fpModal design. */
#ffnotif-topbar {
    display: none !important;
}

/* Icon — small circle, top-left */
#ffnotif-icon,
.ffnotif-icon--circle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: 700;
    line-height: 1;
    flex-shrink: 0;
    margin: 0 0 14px 0;
    align-self: flex-start;
}

/* Type colours — icon + matching coloured top border */
#ffnotif-dialog.ffnotif-success { border-top-color: #56d93f; }
#ffnotif-dialog.ffnotif-error   { border-top-color: #ff5d73; }
#ffnotif-dialog.ffnotif-info    { border-top-color: #ff2f86; }
#ffnotif-dialog.ffnotif-warning { border-top-color: #f5b83d; }

#ffnotif-dialog.ffnotif-success #ffnotif-icon,
#ffnotif-dialog.ffnotif-success .ffnotif-icon--circle {
    background: rgba(86, 217, 63, 0.14);
    color: #56d93f;
}

#ffnotif-dialog.ffnotif-error #ffnotif-icon,
#ffnotif-dialog.ffnotif-error .ffnotif-icon--circle {
    background: rgba(255, 93, 115, 0.14);
    color: #ff5d73;
}

#ffnotif-dialog.ffnotif-info #ffnotif-icon,
#ffnotif-dialog.ffnotif-info .ffnotif-icon--circle {
    background: rgba(255, 47, 134, 0.13);
    color: #ff2f86;
}

#ffnotif-dialog.ffnotif-warning #ffnotif-icon,
#ffnotif-dialog.ffnotif-warning .ffnotif-icon--circle {
    background: rgba(245, 184, 61, 0.14);
    color: #f5b83d;
}

/* Title */
#ffnotif-title {
    margin: 0;
    font-weight: 800;
    font-size: 20px;
    line-height: 1.25;
    color: #ffffff;
    letter-spacing: -0.01em;
    text-align: left;
}

/* Message */
#ffnotif-message {
    margin: 7px 0 0;
    font-weight: 400;
    font-size: 14.5px;
    line-height: 1.55;
    color: rgba(255, 255, 255, 0.66);
    text-align: left;
}

/* Links inside the message render as HTML (see notification-modal.js),
   so make them stand out against the muted body text. */
#ffnotif-message a {
    color: #ff6ba6;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color 0.15s;
}

#ffnotif-message a:hover {
    color: #ff9ac4;
}

/* Actions — buttons in a row, aligned to the bottom-right */
#ffnotif-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    width: 100%;
    margin-top: 22px;
    justify-content: flex-end;
}

/* Button base */
.ffnotif-btn {
    padding: 11px 20px;
    border-radius: 11px;
    border: 1px solid transparent;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    min-height: 44px;
    min-width: 108px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform 130ms ease, box-shadow 130ms ease, filter 130ms ease, background 130ms ease;
    letter-spacing: 0.01em;
}

.ffnotif-btn:active {
    transform: scale(0.97) !important;
}

/* Primary — FindFyre pink */
.ffnotif-btn-primary {
    background: #e0548d;
    color: #fff;
    border-color: transparent;
}

.ffnotif-btn-primary:hover {
    background: #ec3f8f;
    filter: brightness(1.04);
}

/* Secondary — ghost */
.ffnotif-btn-secondary {
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.78);
    border-color: rgba(255, 255, 255, 0.12);
}

.ffnotif-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.10);
    border-color: rgba(255, 255, 255, 0.20);
}

/* Responsive */
@media (max-width: 480px) {
    #ffnotif-dialog {
        max-width: calc(100% - 24px);
        padding: 18px 18px 20px;
        border-radius: 16px;
    }

    #ffnotif-title {
        font-size: 18px;
    }

    #ffnotif-message {
        font-size: 14px;
    }

    #ffnotif-actions {
        justify-content: stretch;
    }

    .ffnotif-btn {
        flex: 1 1 auto;
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    #ffnotif-backdrop,
    #ffnotif-dialog,
    #ffnotif-icon,
    .ffnotif-icon--circle {
        animation: none !important;
    }
}

/* Light mode — same card language as jquery-confirm (screenshot 2) */
body.fp-light #ffnotif-modalRoot {
    color: #0a3049 !important;
}

body.fp-light #ffnotif-dialog {
    background: #ffffff !important;
    border-color: rgba(10, 48, 73, 0.10) !important;
    border-top: 3px solid #ff2f86 !important;
    box-shadow: 0 22px 50px rgba(10, 48, 73, 0.16) !important;
    color: #0a3049 !important;
}

body.fp-light #ffnotif-title {
    color: #0a3049 !important;
}

body.fp-light #ffnotif-message {
    color: #4a5568 !important;
}

body.fp-light .ffnotif-btn-primary {
    background: #ff2f86 !important;
    color: #fff !important;
    border-radius: 999px !important;
}

body.fp-light .ffnotif-btn-secondary {
    background: none !important;
    color: #ff2f86 !important;
    border: 0 !important;
}
