/* ============================================================
   Funnel T1.5 — email-capture / check-inbox overlay
   Loaded ONLY when flags.funnel is on (gated <link> on calc pages).
   Token: src/css/tokens.css (Overlock, olive/terracotta/cream).
   Adattato 1:1 dal layout di funnel/entry.jsx (FxEmailCapture / FxCheckInbox),
   reso coi token Bonus Immobiliare (Warm Editorial), non col font dell'app.
   Tutte le classi prefissate .fc-  (funnel-capture).
   ============================================================ */

.fc-overlay {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    overflow-y: auto;
    padding: clamp(16px, 6vh, 64px) 16px 48px;
    background: radial-gradient(120% 80% at 50% -10%, var(--terracotta-pale), rgba(20, 16, 22, 0.55) 60%);
    -webkit-backdrop-filter: blur(3px);
    backdrop-filter: blur(3px);
}
.fc-overlay[x-cloak] { display: none; }

.fc-shell {
    width: 100%;
    max-width: 412px;
    font-family: var(--font-body);
    color: var(--bark);
}

.fc-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 12px;
    background: transparent;
    border: none;
    cursor: pointer;
    font-family: var(--font-body);
    font-size: 0.84rem;
    font-weight: 600;
    color: var(--cream);
    opacity: 0.92;
}
.fc-back svg { width: 15px; height: 15px; }

.fc-brand {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 16px;
}
.fc-brand img { display: block; width: 34px; height: 34px; flex-shrink: 0; }
.fc-brand-word { font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; color: var(--cream); line-height: 1; }
.fc-brand-word em { font-style: italic; color: var(--terracotta-light); }

.fc-card {
    background: var(--bg-surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-medium);
    padding: var(--space-lg);
}

.fc-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-body);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--terracotta);
    background: var(--terracotta-pale);
    padding: 5px 11px;
    border-radius: var(--radius-full);
    margin-bottom: 14px;
}
.fc-badge svg { width: 13px; height: 13px; }

.fc-h1 {
    font-family: var(--font-display);
    font-weight: var(--weight-bold);
    font-size: 1.4rem;
    line-height: 1.2;
    letter-spacing: -0.01em;
    color: var(--olive-deep);
    margin: 0 0 8px;
}
.fc-p { font-size: 0.92rem; line-height: 1.55; color: var(--earth); margin: 0 0 18px; }
.fc-p b { color: var(--bark); }

/* property recap row (FxPropRow) */
.fc-prop {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: var(--radius-md);
    background: var(--cream-dark);
    border: 1px solid var(--stone);
    margin-bottom: 18px;
}
.fc-prop-ic {
    width: 40px; height: 40px;
    border-radius: 9px;
    flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    background: var(--terracotta-pale);
    color: var(--terracotta);
}
.fc-prop-ic svg { width: 20px; height: 20px; }
.fc-prop-main { flex: 1; min-width: 0; line-height: 1.35; }
.fc-prop-addr { font-size: 0.9rem; font-weight: 700; color: var(--bark); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fc-prop-meta { font-size: 0.8rem; color: var(--earth); }

.fc-field { display: flex; flex-direction: column; gap: 12px; }
.fc-label { font-size: 0.78rem; font-weight: 700; color: var(--bark); }
.fc-input-wrap {
    display: flex; align-items: center; gap: 9px;
    height: 46px;
    padding: 0 13px;
    border-radius: var(--radius-md);
    border: 1.5px solid var(--stone);
    background: var(--bg-surface);
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}
.fc-input-wrap:focus-within { border-color: var(--olive); box-shadow: 0 0 0 3px var(--sage-mist); }
.fc-input-wrap svg { width: 17px; height: 17px; color: var(--earth); flex-shrink: 0; }
.fc-input {
    flex: 1; min-width: 0;
    border: none; outline: none; background: transparent;
    font-family: var(--font-body); font-size: 0.95rem; color: var(--bark);
}

.fc-check {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    margin-top: 12px;
    font-size: 0.8rem;
    line-height: 1.45;
    color: var(--earth);
    cursor: pointer;
}
.fc-check input {
    width: 16px;
    height: 16px;
    margin: 2px 0 0;
    accent-color: var(--olive);
    flex-shrink: 0;
}

.fc-turnstile { margin: 14px 0 4px; min-height: 65px; }

.fc-err { font-size: 0.85rem; color: var(--terracotta); margin: 10px 0 0; min-height: 1px; }

.fc-trust {
    display: flex; align-items: center; justify-content: center; gap: 14px;
    margin-top: 16px; flex-wrap: wrap;
}
.fc-trust span { display: inline-flex; align-items: center; gap: 5px; font-size: 0.74rem; font-weight: 600; color: var(--earth); }
.fc-trust svg { width: 13px; height: 13px; color: var(--olive); }

.fc-foot { text-align: center; font-size: 0.74rem; color: var(--cream); opacity: 0.85; margin-top: 14px; line-height: 1.5; }
.fc-foot--ink { color: var(--earth); opacity: 1; }

/* check-inbox state */
.fc-icon-badge {
    width: 60px; height: 60px;
    border-radius: var(--radius-full);
    background: var(--terracotta-pale);
    color: var(--terracotta);
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 16px;
}
.fc-icon-badge svg { width: 28px; height: 28px; }
.fc-center { text-align: center; }

.fc-resend { font-size: 0.82rem; color: var(--earth); margin: 0 0 18px; }
.fc-link { color: var(--terracotta); font-weight: 600; cursor: pointer; background: none; border: none; font-family: var(--font-body); font-size: inherit; padding: 0; }
.fc-link[disabled] { color: var(--earth); cursor: default; opacity: 0.7; }

/* in-result save-hook (replaces the Bonus Immobiliare warning when flags.funnel) */
.ccr-savehook { text-align: center; }
.ccr-savehook-cta {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.ccr-savehook-cta svg { width: 18px; height: 18px; }
.ccr-savehook-note { font-size: 0.84rem; line-height: 1.5; color: var(--earth); margin: 10px 0 0; }
.ccr-savehook-error {
    margin: 16px 0 4px;
    padding: 16px;
    border: 1px solid var(--stone);
    border-radius: 8px;
    background: var(--cream);
}
