/* ==========================================================================
   Auxílio Fácil — landing da marca (índigo, violeta, coral, lavanda)
   Usada por landing-af.html. O maternidade.css continua servindo a landing antiga.
   Pensada primeiro para o celular; quebras em 640, 900 e 1100 px.
   ========================================================================== */

:root {
    --af-indigo: #1A1B4B;
    --af-indigo-700: #23255F;
    --af-violet: #6C63FF;
    --af-violet-deep: #4F46E5;      /* links e texto pequeno: 6,3:1 no branco */
    --af-coral: #FF7A6B;            /* só decoração: com texto branco dá 2,55:1 */
    --af-coral-deep: #C94A3D;       /* texto ou fundo com branco: 4,6:1 */
    --af-lavender: #EDE8FF;
    --af-bg-soft: #F7F5FF;
    --af-border: #DCD9FF;
    --af-line: #ECE9FF;
    --af-ink: #1A1B4B;
    --af-text: #34355C;
    --af-muted: #5A5B78;
    --af-ok: #1B7A4E;
    --af-error: #B42318;

    --af-font-display: 'Lexend', 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --af-font-body: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

    --af-radius-sm: 12px;
    --af-radius-md: 16px;
    --af-radius-lg: 24px;
    --af-radius-pill: 999px;

    --af-shadow-sm: 0 1px 2px rgba(26, 27, 75, .06);
    --af-shadow-md: 0 8px 24px rgba(26, 27, 75, .08);
    --af-shadow-lg: 0 18px 48px rgba(26, 27, 75, .14);

    --af-ease: cubic-bezier(.22, 1, .36, 1);
    --af-header-h: 66px;

    /* Compatibilidade: maternidade.js:304 usa esta variável num estilo inline. */
    --color-rose-dark: var(--af-indigo);
}

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--af-header-h) + 16px);
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    font-family: var(--af-font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--af-text);
    background: #fff;
    -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }
h1, h2, h3 {
    margin: 0;
    font-family: var(--af-font-display);
    color: var(--af-ink);
    line-height: 1.12;
    letter-spacing: -0.02em;
    text-wrap: balance;
}
p { margin: 0; }
a { color: var(--af-violet-deep); }
button { font: inherit; }

:focus-visible {
    outline: 3px solid var(--af-violet);
    outline-offset: 3px;
}

[hidden], .hidden { display: none !important; }

.af-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.af-skip-link {
    position: absolute;
    left: 16px;
    top: -100px;
    z-index: 100;
    padding: 10px 16px;
    border-radius: var(--af-radius-pill);
    background: var(--af-indigo);
    color: #fff;
    font-weight: 600;
    text-decoration: none;
}
.af-skip-link:focus { top: 12px; }

.af-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
}

/* ---------- Botões e links ---------- */

.af-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 48px;
    padding: 14px 22px;
    border: 1.5px solid transparent;
    border-radius: var(--af-radius-pill);
    font-family: var(--af-font-body);
    font-size: 16px;
    font-weight: 600;
    line-height: 1;
    text-decoration: none;
    cursor: pointer;
    transition: transform .2s var(--af-ease), background-color .2s, border-color .2s, box-shadow .2s, color .2s;
}
.af-btn:disabled { opacity: .6; cursor: wait; transform: none; }

.af-btn-primary {
    background: var(--af-indigo);
    color: #fff;
    box-shadow: 0 8px 20px rgba(26, 27, 75, .22);
}
.af-btn-primary:hover { background: var(--af-indigo-700); transform: translateY(-1px); }

.af-btn-outline {
    background: #fff;
    color: var(--af-indigo);
    border-color: var(--af-border);
}
.af-btn-outline:hover { border-color: var(--af-violet); }

.af-btn-light { background: #fff; color: var(--af-indigo); }
.af-btn-light:hover { background: var(--af-lavender); transform: translateY(-1px); }

.af-btn-sm { min-height: 40px; padding: 10px 16px; font-size: 14px; box-shadow: none; }
.af-btn-lg { min-height: 56px; padding: 16px 28px; font-size: 17px; }
.af-btn-block { width: 100%; }

.af-arrow {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform .2s var(--af-ease);
}
.af-btn:hover .af-arrow { transform: translateX(3px); }

.af-link {
    display: inline-flex;
    align-items: center;
    min-height: 48px;
    color: var(--af-indigo);
    font-weight: 600;
    text-decoration: underline;
    text-decoration-color: var(--af-border);
    text-decoration-thickness: 2px;
    text-underline-offset: 6px;
}
.af-link:hover { text-decoration-color: var(--af-violet); }

.af-link-button {
    padding: 4px 0;
    border: 0;
    background: none;
    color: var(--af-violet-deep);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 4px;
    cursor: pointer;
}

/* ---------- Cabeçalho em cápsula ---------- */

.af-header {
    position: sticky;
    top: 0;
    z-index: 50;
    height: var(--af-header-h);
    padding: 10px 12px 0;
}

.af-header .af-header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 52px;
    padding: 6px 6px 6px 16px;
    border: 1px solid rgba(220, 217, 255, .8);
    border-radius: var(--af-radius-pill);
    background: rgba(255, 255, 255, .92);
    box-shadow: var(--af-shadow-md);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
}

.af-logo img { width: auto; height: 34px; }

.af-nav { display: none; }

/* ---------- Hero ---------- */

.af-hero {
    position: relative;
    margin-top: calc(-1 * var(--af-header-h));
    background: var(--af-bg-soft);
    overflow: hidden;
}

.af-hero-photo {
    position: relative;
    display: block;
    aspect-ratio: 4 / 3;
    overflow: hidden;
}
.af-hero-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 50% 20%;
}
.af-hero-photo::after {
    content: '';
    position: absolute;
    inset: auto 0 0 0;
    height: 40%;
    background: linear-gradient(to bottom, rgba(247, 245, 255, 0), var(--af-bg-soft));
}

.af-hero-inner {
    position: relative;
    z-index: 1;
    margin-top: -36px;
    padding-bottom: 48px;
}

.af-eyebrow {
    display: inline-flex;
    padding: 8px 14px;
    border: 1px solid var(--af-border);
    border-radius: var(--af-radius-pill);
    background: rgba(255, 255, 255, .85);
    color: var(--af-indigo);
    font-size: 11.5px;
    font-weight: 600;
    letter-spacing: .16em;
    line-height: 1.2;
    text-transform: uppercase;
}

.af-hero-title {
    margin: 18px 0 16px;
    font-size: clamp(30px, 8vw, 38px);
    font-weight: 700;
    letter-spacing: -0.025em;
}

.af-highlight {
    display: block;
    margin-top: 4px;
    color: var(--af-violet-deep);
}
@supports ((-webkit-background-clip: text) or (background-clip: text)) {
    .af-highlight {
        /* Pontas escurecidas para passar 3:1 em texto grande. */
        background: linear-gradient(90deg, #5B52F0 0%, #8A4FE0 50%, #E2574A 100%);
        -webkit-background-clip: text;
        background-clip: text;
        color: transparent;
    }
}

.af-hero-lead {
    max-width: 560px;
    color: var(--af-text);
    font-size: 17px;
    line-height: 1.6;
}

.af-hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 24px;
    margin-top: 28px;
}

.af-hero-note {
    margin-top: 12px;
    color: var(--af-muted);
    font-size: 13.5px;
}

.af-hero-cards {
    display: grid;
    gap: 10px;
    margin: 28px 0 0;
    padding: 0;
    list-style: none;
}

.af-hero-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border: 1px solid rgba(220, 217, 255, .9);
    border-radius: var(--af-radius-md);
    background: rgba(255, 255, 255, .88);
    box-shadow: var(--af-shadow-sm);
    color: var(--af-muted);
    font-size: 13.5px;
    line-height: 1.35;
}
.af-hero-card strong {
    display: block;
    color: var(--af-ink);
    font-size: 14.5px;
    font-weight: 600;
}

.af-hero-card-icon {
    display: grid;
    flex: none;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--af-lavender);
    color: var(--af-violet-deep);
}
.af-hero-card-icon svg { width: 20px; height: 20px; }
.af-hero-card-icon.af-icon-coral { background: #FFE9E5; color: var(--af-coral-deep); }

/* ---------- Seções ---------- */

.af-section { padding: 64px 0; }
.af-section-white { background: #fff; }
.af-section-soft { background: var(--af-bg-soft); }

.af-heading {
    max-width: 720px;
    margin: 0 auto 40px;
    text-align: center;
}
.af-heading-left { margin-left: 0; text-align: left; }

.af-kicker {
    margin-bottom: 12px;
    color: var(--af-violet-deep);
    font-size: 12.5px;
    font-weight: 600;
    letter-spacing: .16em;
    line-height: 1.2;
    text-transform: uppercase;
}

.af-heading h2 {
    margin-bottom: 16px;
    font-size: clamp(27px, 6.4vw, 40px);
    font-weight: 600;
}
.af-heading h2::after {
    content: '';
    display: block;
    width: 56px;
    height: 4px;
    margin: 16px auto 0;
    border-radius: 4px;
    background: linear-gradient(90deg, var(--af-violet), var(--af-coral));
}
.af-heading-left h2::after { margin-left: 0; }

.af-heading > p:not(.af-kicker) {
    color: var(--af-muted);
    font-size: 17px;
}

.af-split { display: grid; gap: 40px; }

.af-checks {
    display: grid;
    gap: 10px;
    margin: 20px 0 0;
    padding: 0;
    list-style: none;
    text-align: left;
}
.af-checks li {
    position: relative;
    padding-left: 30px;
    color: var(--af-text);
    font-size: 15.5px;
}
.af-checks li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 3px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--af-lavender) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234F46E5' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 12px no-repeat;
}
.af-heading .af-checks + .af-btn { margin-top: 28px; }

/* ---------- Dúvidas reais ---------- */

.af-qa-grid { display: grid; gap: 16px; }

.af-qa {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 20px;
    border: 1px solid var(--af-line);
    border-radius: 20px;
    background: #FCFBFF;
}

.af-qa-q {
    align-self: flex-start;
    padding: 12px 16px;
    border-radius: 18px 18px 18px 6px;
    background: var(--af-lavender);
    color: var(--af-ink);
    font-size: 15.5px;
    font-weight: 600;
    line-height: 1.4;
}

.af-qa-a {
    padding-left: 4px;
    color: var(--af-text);
    font-size: 15px;
}

.af-qa-cta {
    justify-content: center;
    border-color: var(--af-indigo);
    background: var(--af-indigo);
    color: rgba(255, 255, 255, .84);
}
.af-qa-cta-title {
    color: #fff;
    font-family: var(--af-font-display);
    font-size: 20px;
    font-weight: 600;
}
.af-qa-cta .af-btn { align-self: flex-start; }

/* ---------- Como funciona ---------- */

.af-steps {
    margin: 0;
    padding: 0;
    list-style: none;
}

.af-step {
    position: relative;
    display: grid;
    grid-template-columns: 52px 1fr;
    gap: 16px;
    padding-bottom: 28px;
}
.af-step:not(:last-child)::before {
    content: '';
    position: absolute;
    left: 25px;
    top: 56px;
    bottom: 4px;
    width: 2px;
    border-radius: 2px;
    background: var(--af-border);
}

.af-step-num {
    display: grid;
    place-items: center;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: var(--af-indigo);
    color: #fff;
    font-family: var(--af-font-display);
    font-size: 16px;
    font-weight: 600;
}
.af-step:nth-child(2) .af-step-num { background: var(--af-violet-deep); }
.af-step:nth-child(3) .af-step-num { background: var(--af-coral-deep); }

.af-step h3 { margin: 4px 0 6px; font-size: 22px; font-weight: 600; }
.af-step p { color: var(--af-muted); }

.af-tracker {
    justify-self: center;
    width: 100%;
    max-width: 420px;
    margin: 0;
    padding: 24px;
    border: 1px solid var(--af-line);
    border-radius: var(--af-radius-lg);
    background: #fff;
    box-shadow: var(--af-shadow-lg);
}

.af-tracker-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--af-line);
}
.af-tracker-head img { width: 40px; height: 40px; border-radius: 10px; }
.af-tracker-head strong {
    display: block;
    color: var(--af-ink);
    font-family: var(--af-font-display);
    font-size: 16px;
    font-weight: 600;
}
.af-tracker-head span { color: var(--af-muted); font-size: 13px; }

.af-tracker-list { margin: 0; padding: 0; list-style: none; }
.af-tracker-list li {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    color: var(--af-muted);
    font-size: 15px;
}
.af-tracker-list li:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 11px;
    top: 34px;
    width: 2px;
    height: 20px;
    background: var(--af-border);
}
.af-tracker-list li.is-done::after { background: var(--af-ok); }

.af-tracker-dot {
    position: relative;
    flex: none;
    width: 24px;
    height: 24px;
    border: 2px solid var(--af-border);
    border-radius: 50%;
    background: #fff;
}
.is-done, .is-current { color: var(--af-ink); }
.is-current { font-weight: 600; }
.is-done .af-tracker-dot { border-color: var(--af-ok); background: var(--af-ok); }
.is-done .af-tracker-dot::after {
    content: '';
    position: absolute;
    left: 6px;
    top: 2px;
    width: 6px;
    height: 11px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}
.is-current .af-tracker-dot {
    border-color: var(--af-violet-deep);
    box-shadow: 0 0 0 4px rgba(108, 99, 255, .15);
}
.is-current .af-tracker-dot::after {
    content: '';
    position: absolute;
    inset: 4px;
    border-radius: 50%;
    background: var(--af-violet-deep);
}

.af-tracker figcaption {
    margin-top: 14px;
    color: var(--af-muted);
    font-size: 12.5px;
}

/* ---------- Quem pode ---------- */

.af-profiles { display: grid; gap: 16px; }

.af-profile {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 24px;
    border: 1px solid var(--af-line);
    border-radius: 20px;
    background: #fff;
    transition: border-color .2s, box-shadow .2s, transform .2s var(--af-ease);
}
.af-profile:hover {
    border-color: var(--af-border);
    box-shadow: var(--af-shadow-md);
    transform: translateY(-2px);
}
.af-profile:first-child { background: linear-gradient(180deg, #F3F1FF, #fff 70%); }

.af-profile h3 {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.3;
}
.af-profile h3 svg {
    flex: none;
    width: 22px;
    height: 22px;
    margin-top: 1px;
    color: var(--af-violet-deep);
}
.af-profile p { flex: 1; color: var(--af-muted); font-size: 15px; }

.af-pill {
    align-self: flex-start;
    padding: 6px 12px;
    border-radius: var(--af-radius-pill);
    background: var(--af-lavender);
    color: var(--af-indigo);
    font-size: 12.5px;
    font-weight: 600;
}

.af-profiles-note {
    margin-top: 28px;
    color: var(--af-muted);
    font-size: 15.5px;
    text-align: center;
}

/* ---------- Primeiro passo (simulador) ---------- */

.af-sim-card {
    padding: 22px 18px;
    border: 1px solid var(--af-line);
    border-radius: var(--af-radius-lg);
    background: #fff;
    box-shadow: var(--af-shadow-lg);
}

.af-sim-step {
    min-width: 0;
    margin: 0 0 24px;
    padding: 0;
    border: 0;
}
.af-sim-step legend {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 14px;
    padding: 0;
    color: var(--af-ink);
    font-family: var(--af-font-display);
    font-size: 16.5px;
    font-weight: 500;
    line-height: 1.4;
}

.af-sim-num {
    display: grid;
    flex: none;
    place-items: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--af-indigo);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
}

.af-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
}

.af-option { position: relative; display: block; cursor: pointer; }
.af-option input {
    position: absolute;
    top: 50%;
    left: 18px;
    width: 1px;
    height: 1px;
    opacity: 0;
}
.af-option span {
    position: relative;
    display: flex;
    align-items: center;
    height: 100%;
    min-height: 52px;
    padding: 12px 14px 12px 44px;
    border: 1.5px solid var(--af-border);
    border-radius: 14px;
    background: #fff;
    color: var(--af-ink);
    font-size: 15px;
    font-weight: 500;
    line-height: 1.3;
    transition: border-color .2s, background-color .2s;
}
.af-option span::before {
    content: '';
    position: absolute;
    left: 14px;
    top: 50%;
    width: 20px;
    height: 20px;
    margin-top: -10px;
    border: 2px solid #B9B5F5;
    border-radius: 50%;
    background: #fff;
}
.af-option:hover span { border-color: var(--af-violet); }
.af-option input:checked + span { border-color: var(--af-violet-deep); background: #F3F1FF; }
.af-option input:checked + span::before {
    border-color: var(--af-violet-deep);
    background: var(--af-violet-deep);
    box-shadow: inset 0 0 0 4px #fff;
}
.af-option input:focus-visible + span { outline: 3px solid var(--af-violet); outline-offset: 2px; }

/* Resultado desenhado pelo maternidade.js */
.sim-result-box {
    margin-top: 20px;
    padding: 20px;
    border: 1.5px solid var(--af-border);
    border-radius: 18px;
    background: var(--af-bg-soft);
    animation: af-rise .35s var(--af-ease);
}
.sim-result-box.result-approved { border-color: #BFE5D1; background: #F0FAF5; }
.sim-result-box.result-warning { border-color: #F5D9A8; background: #FFF7EB; }
.sim-result-box.result-denied { border-color: #F7C6BF; background: #FFF1EF; }

.sim-result-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
    color: var(--af-ink);
    font-family: var(--af-font-display);
    font-size: 18px;
    font-weight: 600;
    line-height: 1.3;
}
.sim-result-desc { margin-bottom: 16px; color: var(--af-text); font-size: 15px; }

.btn-result-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 46px;
    padding: 12px 18px;
    border: 1.5px solid var(--af-indigo);
    border-radius: var(--af-radius-pill);
    background: var(--af-indigo);
    color: #fff;
    font-family: var(--af-font-body);
    font-size: 14.5px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color .2s, transform .2s var(--af-ease);
}
.btn-result-cta:hover { transform: translateY(-1px); }

.icon-inline { flex: none; width: 18px; height: 18px; }

/* ---------- Clara ---------- */

.af-clara-avatar { flex: none; width: 40px; height: 40px; }

.af-chat-mock {
    justify-self: center;
    width: 100%;
    max-width: 420px;
    margin: 0;
    overflow: hidden;
    border: 1px solid var(--af-line);
    border-radius: 28px;
    background: var(--af-bg-soft);
    box-shadow: var(--af-shadow-lg);
}

.af-chat-mock-head {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: var(--af-indigo);
    color: #fff;
}
.af-chat-mock-head .af-clara-avatar { border-radius: 50%; box-shadow: 0 0 0 2px rgba(255, 255, 255, .55); }
.af-chat-mock-head strong {
    display: block;
    font-family: var(--af-font-display);
    font-size: 16px;
    font-weight: 600;
}
.af-chat-mock-head span { font-size: 12.5px; opacity: .82; }

.af-chat-mock-body {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 20px;
}

.af-bubble {
    max-width: 85%;
    padding: 12px 16px;
    border-radius: 18px;
    font-size: 15px;
    line-height: 1.45;
}
.af-bubble-agent {
    align-self: flex-start;
    border: 1px solid var(--af-line);
    border-bottom-left-radius: 6px;
    background: #fff;
    color: var(--af-ink);
}
.af-bubble-user {
    align-self: flex-end;
    border-bottom-right-radius: 6px;
    background: var(--af-indigo);
    color: #fff;
}

.af-chat-mock figcaption {
    padding: 0 20px 16px;
    color: var(--af-muted);
    font-size: 12.5px;
    text-align: center;
}

/* ---------- FAQ ---------- */

.af-faq { max-width: 840px; }
.af-faq-list { display: grid; gap: 12px; }

.af-faq-item {
    border: 1px solid var(--af-line);
    border-radius: var(--af-radius-md);
    background: #fff;
    transition: border-color .2s, box-shadow .2s;
}
.af-faq-item[open] { border-color: var(--af-border); box-shadow: var(--af-shadow-md); }

.af-faq-item summary {
    position: relative;
    padding: 18px 56px 18px 20px;
    color: var(--af-ink);
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
    list-style: none;
    cursor: pointer;
}
.af-faq-item summary::-webkit-details-marker { display: none; }
.af-faq-item summary::after {
    content: '';
    position: absolute;
    right: 18px;
    top: 50%;
    width: 24px;
    height: 24px;
    margin-top: -12px;
    border-radius: 50%;
    background: var(--af-lavender) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231A1B4B' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M12 5v14M5 12h14'/%3E%3C/svg%3E") center / 12px no-repeat;
    transition: transform .25s var(--af-ease);
}
.af-faq-item[open] summary::after { transform: rotate(45deg); }
.af-faq-item p { padding: 0 20px 20px; color: var(--af-text); font-size: 15.5px; }

/* ---------- Faixa final ---------- */

.af-final {
    position: relative;
    overflow: hidden;
    padding: 72px 0;
    background: var(--af-indigo);
    color: #fff;
    text-align: center;
}

.af-final-inner { position: relative; z-index: 1; }

.af-final h2 {
    max-width: 760px;
    margin: 0 auto 14px;
    color: #fff;
    font-size: clamp(28px, 6.6vw, 44px);
    font-weight: 600;
}
.af-final h2 span { display: block; color: #C9C5FF; }
.af-final p { margin-bottom: 28px; color: rgba(255, 255, 255, .84); font-size: 17px; }

/* Fitas da marca: pílulas inclinadas que lembram os traços do símbolo AF. */
.af-ribbon {
    position: absolute;
    height: 64px;
    border-radius: var(--af-radius-pill);
    pointer-events: none;
    transform: rotate(-32deg);
}
.af-ribbon-violet {
    right: -160px;
    top: 20px;
    width: 380px;
    background: linear-gradient(90deg, #4F46E5, #8B85FF);
    opacity: .4;
}
.af-ribbon-coral {
    left: -170px;
    bottom: 10px;
    width: 340px;
    background: linear-gradient(90deg, #FF7A6B, #FFB08A);
    opacity: .6;
}

/* ---------- Rodapé ---------- */

.af-footer {
    padding: 48px 0 24px;
    border-top: 1px solid var(--af-line);
    background: #fff;
}

.af-footer-grid { display: grid; gap: 28px; }
.af-footer-brand img { width: 200px; height: auto; }
.af-footer-brand p {
    max-width: 460px;
    margin-top: 16px;
    color: var(--af-muted);
    font-size: 14px;
}

.af-footer-nav { display: flex; flex-wrap: wrap; gap: 12px 24px; }
.af-footer-nav a {
    color: var(--af-ink);
    font-size: 15px;
    font-weight: 500;
    text-decoration: none;
}
.af-footer-nav a:hover { color: var(--af-violet-deep); text-decoration: underline; }

.af-footer-legal {
    margin-top: 32px;
    padding-top: 20px;
    border-top: 1px solid var(--af-line);
    color: var(--af-muted);
    font-size: 13px;
}

/* ---------- Balão da Clara e barra do celular ---------- */

.af-clara-bubble { display: none; }

/* No celular o convite principal fica na barra de baixo, ao alcance do polegar. */
.af-header-cta { display: none; }

.af-mobile-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 55;
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 10px;
    padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--af-line);
    background: rgba(255, 255, 255, .97);
    box-shadow: 0 -8px 24px rgba(26, 27, 75, .1);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    transition: transform .28s var(--af-ease), opacity .28s var(--af-ease);
}
.af-mobile-bar.is-hidden {
    transform: translateY(110%);
    opacity: 0;
    pointer-events: none;
}
.af-mobile-bar .af-btn { box-shadow: none; }

.af-mobile-clara {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 52px;
    padding: 6px 14px 6px 6px;
    border: 1.5px solid var(--af-border);
    border-radius: var(--af-radius-pill);
    background: #fff;
    color: var(--af-ink);
    text-align: left;
    cursor: pointer;
    transition: border-color .2s, background-color .2s;
}
.af-mobile-clara:active { background: var(--af-bg-soft); }
.af-mobile-clara:hover { border-color: var(--af-violet); }

.af-mobile-clara-avatar { position: relative; flex: none; width: 40px; height: 40px; }
.af-mobile-clara-avatar .af-clara-avatar { width: 40px; height: 40px; }
.af-online-dot {
    position: absolute;
    right: -1px;
    bottom: 0;
    width: 12px;
    height: 12px;
    border: 2px solid #fff;
    border-radius: 50%;
    background: #22A06B;
}

.af-mobile-clara-text { display: grid; line-height: 1.15; }
.af-mobile-clara-text strong {
    font-family: var(--af-font-display);
    font-size: 15px;
    font-weight: 600;
}
.af-mobile-clara-text span { color: var(--af-muted); font-size: 12px; }

.af-mobile-start { min-height: 52px; padding: 14px 16px; font-size: 15.5px; }

@media (max-width: 359px) {
    .af-mobile-clara { padding-right: 6px; }
    .af-mobile-clara-text { display: none; }
}

body { padding-bottom: 72px; }

/* ---------- Gaveta do chat ---------- */

.af-drawer {
    position: fixed;
    inset: 0;
    z-index: 70;
    display: flex;
    flex-direction: column;
    background: #fff;
}

.af-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: calc(12px + env(safe-area-inset-top)) 12px 12px 18px;
    background: var(--af-indigo);
    color: #fff;
}
.af-drawer-id { display: flex; align-items: center; gap: 12px; }
.af-drawer-id strong {
    display: block;
    font-family: var(--af-font-display);
    font-size: 16px;
    font-weight: 600;
}
.af-drawer-id span { font-size: 12.5px; opacity: .82; }
.af-drawer-actions { display: flex; gap: 4px; }

.af-icon-button {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: inherit;
    cursor: pointer;
    transition: background-color .2s;
}
.af-icon-button svg { width: 20px; height: 20px; }
.af-icon-button:hover { background: rgba(255, 255, 255, .14); }
.af-icon-button:disabled { opacity: .45; cursor: not-allowed; }

.af-messages {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 10px;
    padding: 18px;
    overflow-y: auto;
    background: var(--af-bg-soft);
}

.msg-bubble {
    max-width: 85%;
    padding: 11px 15px;
    border-radius: 18px;
    font-size: 15px;
    line-height: 1.5;
    overflow-wrap: anywhere;
}
.msg-bubble.agent {
    align-self: flex-start;
    border: 1px solid var(--af-line);
    border-bottom-left-radius: 6px;
    background: #fff;
    color: var(--af-ink);
}
.msg-bubble.user {
    align-self: flex-end;
    border-bottom-right-radius: 6px;
    background: var(--af-indigo);
    color: #fff;
}
#clara-typing { color: var(--af-muted); font-style: italic; }

/* Respostas rápidas ao convite do fim da triagem (maternidade.js) */
.af-quick-replies {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px 18px 0;
}
.af-quick-replies[hidden] { display: none; }
.af-quick-reply {
    min-height: 44px;
    padding: 0 18px;
    border: 1.5px solid var(--af-indigo);
    border-radius: var(--af-radius-pill);
    background: #fff;
    color: var(--af-indigo);
    font: 600 15px var(--af-font-body);
    cursor: pointer;
}
.af-quick-reply:first-child { background: var(--af-indigo); color: #fff; }
.af-quick-reply:focus-visible { outline: 3px solid var(--af-violet); outline-offset: 2px; }
/* Answer buttons: every option looks the same, so none is suggested; "Não sei" is quieter. */
.af-quick-replies.is-answers { gap: 6px; padding-top: 8px; }
.af-quick-replies.is-answers .af-quick-reply {
    min-height: 40px;
    padding: 0 14px;
    background: #fff;
    color: var(--af-indigo);
    font-size: 14px;
}
.af-quick-replies.is-answers .af-quick-reply:hover { background: var(--af-lavender); }
.af-quick-replies.is-answers .af-quick-reply.is-quiet {
    border-color: var(--af-border);
    color: var(--af-muted);
    font-weight: 500;
}
.af-quick-reply:disabled { opacity: .45; cursor: not-allowed; }
.af-quick-select {
    min-height: 40px;
    padding: 0 12px;
    border: 1.5px solid var(--af-border);
    border-radius: 12px;
    background: #fff;
    color: var(--af-ink);
    font: 500 15px var(--af-font-body);
}
.af-quick-select:focus-visible { outline: 3px solid var(--af-violet); outline-offset: 2px; }
#clara-lead-form.is-highlighted {
    padding: 6px 14px;
    border-radius: var(--af-radius-pill);
    background: var(--af-lavender);
    text-decoration: none;
}

.af-drawer-status {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 4px 12px;
    padding: 8px 18px;
    border-top: 1px solid var(--af-line);
    color: var(--af-muted);
    font-size: 12.5px;
}
#clara-notice { flex-basis: 100%; color: var(--af-error); font-weight: 500; }

.af-drawer-form {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 12px calc(12px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--af-line);
    background: #fff;
}
.af-drawer-form .af-icon-button { color: var(--af-muted); }
.af-drawer-form .af-icon-button:hover:not(:disabled) { background: var(--af-lavender); }
.af-drawer-form input {
    flex: 1;
    min-width: 0;
    min-height: 46px;
    padding: 0 16px;
    border: 1.5px solid var(--af-border);
    border-radius: var(--af-radius-pill);
    color: var(--af-ink);
    font: 16px var(--af-font-body);
}

.af-send-button {
    display: grid;
    flex: none;
    place-items: center;
    width: 46px;
    height: 46px;
    border: 0;
    border-radius: 50%;
    background: var(--af-indigo);
    color: #fff;
    cursor: pointer;
}
.af-send-button svg { width: 18px; height: 18px; }
.af-send-button:disabled { opacity: .5; cursor: not-allowed; }

/* Cartão de documento (maternidade.js) */
.doc-card-msg {
    align-self: flex-start;
    max-width: 90%;
    padding: 14px;
    border: 1px solid var(--af-line);
    border-radius: var(--af-radius-md);
    background: #fff;
    font-size: 14px;
}
.doc-card-header { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.doc-card-title strong { display: block; color: var(--af-ink); }
.doc-card-title span { color: var(--af-muted); font-size: 12px; }
.probative-bar-header { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 6px; font-size: 12.5px; }
.probative-bar-track { height: 8px; overflow: hidden; border-radius: var(--af-radius-pill); background: var(--af-lavender); }
.probative-bar-fill { height: 100%; }
.doc-checklist-mini { display: grid; gap: 4px; margin-top: 10px; }
.doc-check-item { display: flex; gap: 8px; font-size: 13px; }
.doc-check-item.ok { color: var(--af-ok); }
.doc-check-item.missing { color: var(--af-muted); }

/* ---------- Modal de contato ---------- */

.af-modal {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    background: rgba(18, 19, 58, .55);
}

.af-modal-card {
    position: relative;
    width: 100%;
    max-width: 480px;
    max-height: 100vh;
    overflow-y: auto;
    padding: 28px 20px calc(20px + env(safe-area-inset-bottom));
    border-radius: 24px 24px 0 0;
    background: #fff;
    box-shadow: 0 24px 64px rgba(26, 27, 75, .3);
    animation: af-rise .3s var(--af-ease);
}
.af-modal-card h3 { margin-bottom: 8px; padding-right: 40px; font-size: 22px; font-weight: 600; }
.af-modal-desc { margin-bottom: 20px; color: var(--af-muted); font-size: 14.5px; }
.af-modal-close { position: absolute; top: 14px; right: 14px; color: var(--af-muted); }
.af-modal-close:hover { background: var(--af-lavender); }

.af-field { display: grid; gap: 6px; margin-bottom: 14px; }
.af-field label { color: var(--af-ink); font-size: 14px; font-weight: 600; }
.af-field input {
    min-height: 48px;
    padding: 0 14px;
    border: 1.5px solid var(--af-border);
    border-radius: var(--af-radius-sm);
    background: #fff;
    color: var(--af-ink);
    font: 16px var(--af-font-body);
}
.af-field input:focus,
.af-drawer-form input:focus {
    border-color: var(--af-violet-deep);
    outline: none;
    box-shadow: 0 0 0 3px rgba(108, 99, 255, .2);
}

.af-consents { display: grid; gap: 12px; margin: 18px 0 20px; }
.af-consent {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    color: var(--af-text);
    font-size: 13.5px;
    line-height: 1.45;
    cursor: pointer;
}
.af-consent input {
    flex: none;
    width: 20px;
    height: 20px;
    margin: 1px 0 0;
    accent-color: var(--af-violet-deep);
}

.lead-feedback { margin-top: 12px; color: var(--af-ok); font-size: 14px; font-weight: 500; }
.lead-feedback.error { color: var(--af-error); }
.af-modal-note { margin-top: 12px; color: var(--af-muted); font-size: 12.5px; text-align: center; }

@keyframes af-rise {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: none; }
}

/* ==========================================================================
   640 px ou mais
   ========================================================================== */

@media (min-width: 640px) {
    .af-container { padding: 0 24px; }

    .af-hero-cards { grid-template-columns: repeat(3, 1fr); }
    .af-hero-card { flex-direction: column; align-items: flex-start; }

    .af-qa-grid { grid-template-columns: repeat(2, 1fr); }
    .af-profiles { grid-template-columns: repeat(2, 1fr); }

    .af-sim-card { padding: 32px; }

    .af-drawer {
        inset: auto 20px 20px auto;
        width: 400px;
        height: min(640px, calc(100vh - 40px));
        overflow: hidden;
        border: 1px solid var(--af-line);
        border-radius: var(--af-radius-lg);
        box-shadow: 0 24px 64px rgba(26, 27, 75, .28);
    }
    .af-drawer-header { padding-top: 12px; }

    .af-modal { align-items: center; padding: 20px; }
    .af-modal-card { padding: 32px; border-radius: var(--af-radius-lg); }
}

/* ==========================================================================
   900 px ou mais
   ========================================================================== */

@media (min-width: 900px) {
    body { padding-bottom: 0; font-size: 17px; }

    .af-header .af-header-bar { padding-left: 22px; }
    .af-logo img { height: 40px; }

    .af-header-cta { display: inline-flex; }
    .af-nav { display: flex; gap: 28px; }
    .af-nav a {
        color: var(--af-ink);
        font-size: 15px;
        font-weight: 500;
        text-decoration: none;
    }
    .af-nav a:hover { color: var(--af-violet-deep); }

    .af-hero {
        display: flex;
        align-items: center;
        min-height: min(860px, 100vh);
    }
    .af-hero-photo { position: absolute; inset: 0; aspect-ratio: auto; }
    .af-hero-photo img { object-position: 75% 30%; }
    .af-hero-photo::after {
        inset: 0;
        height: auto;
        background:
            linear-gradient(90deg, var(--af-bg-soft) 0%, rgba(247, 245, 255, .97) 30%, rgba(247, 245, 255, .78) 44%, rgba(247, 245, 255, 0) 60%),
            linear-gradient(to top, rgba(247, 245, 255, .9), rgba(247, 245, 255, 0) 22%);
    }
    .af-hero-inner {
        margin-top: 0;
        padding-top: calc(var(--af-header-h) + 56px);
        padding-bottom: 64px;
    }
    .af-hero-copy { max-width: 600px; }
    .af-hero-title { font-size: clamp(38px, 3.9vw, 54px); }
    .af-hero-lead { font-size: 18px; }

    .af-section { padding: 96px 0; }

    .af-heading h2 { font-size: clamp(32px, 3.2vw, 40px); }

    .af-split {
        grid-template-columns: 1.1fr .9fr;
        align-items: center;
        gap: 64px;
    }
    .af-split-start { align-items: start; }
    .af-sim-intro { position: sticky; top: calc(var(--af-header-h) + 32px); }

    .af-final { padding: 96px 0; }
    .af-ribbon { height: 84px; }
    .af-ribbon-violet { right: -80px; top: 40px; width: 520px; opacity: .55; }
    .af-ribbon-coral { left: -100px; bottom: 30px; width: 460px; opacity: .8; }

    .af-footer-grid { grid-template-columns: 1.4fr 1fr; align-items: start; }
    .af-footer-nav { justify-content: flex-end; }

    .af-mobile-bar { display: none; }

    .af-clara-bubble {
        position: fixed;
        right: 20px;
        bottom: 20px;
        z-index: 60;
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 8px 18px 8px 8px;
        border: 1px solid var(--af-border);
        border-radius: var(--af-radius-pill);
        background: #fff;
        box-shadow: var(--af-shadow-lg);
        color: var(--af-ink);
        text-align: left;
        cursor: pointer;
        transition: transform .2s var(--af-ease), opacity .2s;
    }
    .af-clara-bubble:hover { transform: translateY(-2px); }
    .af-clara-bubble[aria-expanded="true"] { opacity: 0; pointer-events: none; }
    .af-clara-bubble-text strong {
        display: block;
        font-family: var(--af-font-display);
        font-size: 15px;
        font-weight: 600;
        line-height: 1.2;
    }
    .af-clara-bubble-text span { color: var(--af-muted); font-size: 12.5px; }
}

/* ==========================================================================
   1100 px ou mais
   ========================================================================== */

@media (min-width: 1100px) {
    .af-qa-grid { grid-template-columns: repeat(3, 1fr); }
    .af-profiles { grid-template-columns: repeat(4, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }
}
