/*
 * InfinityCharge — pages.css
 * Estilos para páginas de conteúdo (termos, privacidade, sobre, contato)
 * Deferido via Optimizer::css() na view
 * Variáveis: critical.css (:root)
 */

/* ── Page hero (reutilizado de pricing, redeclarado pra independência) ──── */

.page-hero {
    padding: 130px 0 60px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.page-hero::before {
    content: '';
    position: absolute;
    top: -200px;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
    pointer-events: none;
}

.page-hero h1 {
    font-family: 'Bricolage Grotesque',sans-serif;
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin-bottom: 16px;
    position: relative;
    color: var(--text-primary);
}

.page-hero p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 560px;
    margin: 0 auto;
    position: relative;
    line-height: 1.6;
}

/* ── Prose (conteúdo de texto longo) ──────────────────────────────────────── */

.prose {
    max-width: 760px;
    margin: 0 auto;
    padding: 60px 0 100px;
}

.prose h2 {
    font-family: 'Bricolage Grotesque',sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 48px 0 16px;
}

.prose h2:first-child {
    margin-top: 0;
}

.prose h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 32px 0 12px;
}

.prose p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 16px;
}

.prose ul,
.prose ol {
    margin: 0 0 16px 24px;
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.8;
}

.prose li {
    margin-bottom: 8px;
}

.prose strong {
    color: var(--text-primary);
    font-weight: 600;
}

.prose a {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.prose a:hover {
    color: var(--accent-hover);
}

.prose-date {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-bottom: 40px;
    display: block;
}

.prose-divider {
    height: 1px;
    background: var(--border-subtle);
    margin: 48px 0;
}

/* ── About page — team / values grid ──────────────────────────────────────── */

.values-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin: 40px 0;
}

.value-card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: 16px;
    padding: 32px;
    box-shadow: var(--card-shadow);
    transition: all 0.3s ease;
}

.value-card:hover {
    border-color: var(--border);
    transform: translateY(-3px);
}

.value-icon {
    font-size: 2rem;
    margin-bottom: 16px;
}

.value-card h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 8px;
}

.value-card p {
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 0;
}

/* ── Contact page — form + info ───────────────────────────────────────────── */

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    max-width: 900px;
    margin: 0 auto;
    padding: 60px 0 100px;
}

.contact-info h2 {
    font-family: 'Bricolage Grotesque',sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 16px;
}

.contact-info p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 32px;
}

.contact-channel {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 24px;
}

.contact-channel-icon {
    width: 44px;
    height: 44px;
    background: var(--accent-glow);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.contact-channel h3 {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 4px;
}

.contact-channel p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.5;
}

.contact-form h2 {
    font-family: 'Bricolage Grotesque',sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 24px;
}

.contact-form .field {
    margin-bottom: 16px;
}

.contact-form label {
    display: block;
    font-size: 0.82rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--bg-card);
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.9rem;
    color: var(--text-primary);
    outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
    box-sizing: border-box;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: var(--text-muted);
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.contact-form textarea {
    min-height: 120px;
    resize: vertical;
}

/* ── Responsive ───────────────────────────────────────────────────────────── */

@media (max-width: 768px) {
    .page-hero {
        padding: 110px 0 40px;
    }

    .prose {
        padding: 40px 0 60px;
    }

    .values-grid {
        grid-template-columns: 1fr;
    }

    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
        padding: 40px 0 60px;
    }
}

.contact-form__hint {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin: 0 0 12px;
}


/* ── Textos legais (L-114): termos, privacidade, acordo de dados ─────────── */

.legal-doc .prose-date {
    margin-bottom: 8px;
}

.legal-note {
    font-size: 0.82rem !important;
    color: var(--text-muted) !important;
    margin-bottom: 40px !important;
}

.legal-value {
    color: var(--text-primary);
    font-weight: 600;
    overflow-wrap: anywhere;
}

/* Dado da empresa ainda não configurado: visível, nunca colchete. */
.legal-pending {
    display: inline;
    padding: 1px 6px;
    white-space: nowrap;
    border: 1px dashed #b45309;
    border-radius: 6px;
    background: #fef3c7;
    color: #92400e;
    font-weight: 600;
    font-size: 0.85em;
    line-height: 1.6;
}

.legal-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 24px;
    margin-top: 24px;
    font-size: 0.9rem;
}

.legal-links span[aria-current="page"] {
    color: var(--text-primary);
    font-weight: 600;
}

/* ── Contato com envio pelo servidor (L-118) ──────────────────────────────── */

.contact-grid { grid-template-columns: 3fr 2fr; max-width: 1000px; }
.contact-form .field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.contact-form .field__optional { font-weight: 400; color: var(--text-muted); }
.contact-form .field__hint { margin-top: 6px; font-size: 0.8rem; color: var(--text-muted); }
.contact-form .field__error { margin-top: 6px; font-size: 0.82rem; font-weight: 600; color: #b42318; }
.contact-form [aria-invalid="true"] { border-color: #b42318; }
.contact-form .field--trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.contact-form__alert { margin: 0 0 20px; padding: 12px 16px; border-radius: 10px; background: #fdecea; color: #8a1c12; font-size: 0.9rem; font-weight: 500; }
.contact-form__submit { width: 100%; justify-content: center; }
.contact-sent { background: var(--bg-card); border: 1px solid var(--accent); border-radius: 18px; padding: 36px 28px; text-align: center; box-shadow: 0 0 40px var(--accent-glow); }
.contact-sent:focus { outline: none; }
.contact-sent__icon { width: 52px; height: 52px; margin: 0 auto 16px; border-radius: 50%; background: var(--accent); color: #fff; font-size: 1.6rem; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.contact-sent h2 { margin-bottom: 10px; }
.contact-sent p { color: var(--text-secondary); line-height: 1.6; margin-bottom: 12px; }
.contact-sent .btn { margin-top: 8px; }

/* ── Dúvidas frequentes (L-118) ───────────────────────────────────────────── */

.help-page { padding: 8px 0 72px; }
.help-toc { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; margin-bottom: 40px; }
.help-toc a { padding: 8px 16px; border-radius: 100px; background: var(--bg-card); border: 1px solid var(--border-subtle); font-size: 0.9rem; font-weight: 600; color: var(--text-secondary); }
.help-toc a:hover { color: var(--accent); border-color: var(--accent); }
.help-section { padding: 0; margin-bottom: 40px; scroll-margin-top: 96px; }
.help-section__title { font-family: 'Bricolage Grotesque',sans-serif; font-size: 1.4rem; font-weight: 800; color: var(--text-primary); max-width: 820px; margin: 0 auto 16px; }
.help-legal { text-align: center; font-size: 0.9rem; color: var(--text-muted); }

@media (max-width: 768px) {
    .contact-grid { grid-template-columns: 1fr; }
    .contact-form .field-row { grid-template-columns: 1fr; }
    /* 16px: o iOS não dá zoom ao focar o campo. */
    .contact-form input, .contact-form select, .contact-form textarea { font-size: 16px; }
}

.values-title { font-family: 'Bricolage Grotesque',sans-serif; font-size: 1.5rem; font-weight: 800; text-align: center; color: var(--text-primary); margin: 8px 0 0; }

/* ── Páginas de solução (L-178; visual da landing desde 08/11) ──────── */
.solution-hero { padding: 132px 0 80px; }
.solution-hero h1 { font-size: clamp(2.1rem, 4.6vw, 3.4rem); }
.solution-hero .hero-sub { max-width: 680px; margin-bottom: 18px; }
.solution-hero__trial { display: inline-flex; align-items: center; gap: 8px; margin: 0 auto 28px; padding: 8px 16px; border-radius: 999px; background: #e3f4ec; color: var(--accent-hover); font-weight: 600; font-size: .95rem; animation: fadeUp .6s ease-out .25s both; }
.solution-hero__trial .icon { color: var(--accent); }
.solution-hero .hero-start { margin-bottom: 0; }
.solution-problem { padding: 72px 0 0; }
.problem-card { display: flex; gap: 24px; align-items: flex-start; max-width: 960px; margin: 0 auto; padding: 36px 40px; border-radius: 20px; background: #fbf0dd; border: 1px solid #f1dcb4; }
.problem-card__icon { display: inline-flex; flex: 0 0 56px; height: 56px; align-items: center; justify-content: center; border-radius: 16px; background: #fff; color: #b45309; }
.problem-card__icon .icon { width: 28px; height: 28px; }
.problem-card h2 { font-size: clamp(1.4rem, 2.6vw, 1.9rem); font-weight: 800; line-height: 1.2; margin-bottom: 14px; color: var(--text-primary); }
.problem-card p { color: #3a3226; line-height: 1.7; }
.problem-card p + p { margin-top: 12px; }
.solution-how .features-grid { margin-top: 48px; }
.solution-steps-section .steps { margin-top: 40px; }
.solution-steps-section .step p { font-size: .95rem; }
.solution-note { display: flex; gap: 18px; align-items: flex-start; max-width: 900px; margin: 64px auto 0; padding: 26px 30px; border-radius: 16px; background: #e7effb; border: 1px solid #c9daf3; }
.solution-note__icon { display: inline-flex; flex: 0 0 44px; height: 44px; align-items: center; justify-content: center; border-radius: 12px; background: #fff; color: #1d4ed8; }
.solution-note__icon .icon { width: 22px; height: 22px; }
.solution-note h2 { font-size: 1.15rem; font-weight: 800; margin-bottom: 6px; }
.solution-note p { color: var(--text-secondary); line-height: 1.65; }
.solution-faq { padding: 96px 0 24px; }
.solution-faq .section-title { margin-bottom: 32px; font-size: clamp(1.7rem, 3.4vw, 2.4rem); }
.solution-related { padding: 72px 0 24px; }
.solution-related .section-title { font-size: clamp(1.5rem, 3vw, 2rem); }
.solution-related .topic-cards { margin-top: 28px; }

@media (max-width: 768px) {
    .solution-hero { padding: 108px 0 56px; }
    .problem-card { flex-direction: column; padding: 26px 22px; gap: 16px; }
    .solution-note { flex-direction: column; padding: 22px 20px; margin-top: 40px; }
    .solution-faq { padding-top: 64px; }
}
.help-solutions__list { max-width: 820px; margin: 0 auto; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px 24px; }
.help-solutions__list a { color: var(--accent-hover); font-weight: 600; }
@media (max-width: 768px) { .help-solutions__list { grid-template-columns: 1fr; } }

/* ── Guia do escritório (/ajuda/guia) ─────────────────────────────────────
   Sumário fixo ao lado (recolhível no topo até 1023 px), um passo por bloco
   com tipografia grande para projetar; prints com borda e sombra. */
.guide-hero { padding-bottom: 32px; }
.guide-hero .container { max-width: 980px; }
.guide-crumbs { display: flex; justify-content: center; gap: 8px; font-size: .95rem; color: var(--text-muted); margin-bottom: 12px; }
.guide-crumbs a { color: var(--accent); font-weight: 600; }
.guide { display: grid; grid-template-columns: 264px minmax(0, 1fr); gap: 48px; padding-top: 8px; padding-bottom: 32px; align-items: start; }
.guide-toc { position: sticky; top: 92px; max-height: calc(100vh - 108px); overflow-y: auto; border-radius: 16px; }
.guide-toc__box { background: var(--bg-card); border: 1px solid var(--border-subtle); border-radius: 16px; padding: 18px 14px; box-shadow: var(--card-shadow); }
.guide-toc__title { font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800; font-size: 1.05rem; color: var(--text-primary); cursor: pointer; padding: 0 8px 8px; list-style: none; }
.guide-toc__title::-webkit-details-marker { display: none; }
.guide-toc__list { list-style: none; padding: 0; margin: 0; display: grid; gap: 2px; }
.guide-toc__list a { display: flex; align-items: center; gap: 10px; padding: 6px 10px; border-radius: 10px; color: var(--text-secondary); font-weight: 600; font-size: .95rem; line-height: 1.3; }
.guide-toc__list a:hover, .guide-toc__list a.is-current { background: var(--accent-glow); color: var(--accent-hover); }
.guide-toc__n { flex: 0 0 28px; height: 28px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: var(--surface); color: var(--accent-hover); font-size: .85rem; font-weight: 800; }
.guide-toc__list a.is-current .guide-toc__n { background: var(--accent); color: #fff; }
.guide-steps { min-width: 0; }
.guide-step { padding: 40px 0 48px; border-bottom: 1px solid var(--border-subtle); scroll-margin-top: 88px; }
.guide-step:first-child { padding-top: 8px; }
.guide-step__head { display: flex; align-items: center; gap: 16px; margin-bottom: 14px; }
.guide-step__icon { flex: 0 0 56px; height: 56px; border-radius: 16px; display: inline-flex; align-items: center; justify-content: center; background: var(--accent); color: #fff; }
.guide-step__icon svg { width: 28px; height: 28px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.guide-step__count { margin: 0; font-size: .9rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); }
.guide-step h2 { margin: 0; font-size: clamp(1.6rem, 2.6vw, 2.3rem); line-height: 1.15; color: var(--text-primary); }
.guide-step__lead { font-size: clamp(1.1rem, 1.5vw, 1.3rem); color: var(--text-secondary); max-width: 860px; margin: 0 0 18px; }
.guide-step__points { list-style: none; padding: 0; margin: 0 0 20px; display: grid; gap: 12px; max-width: 900px; }
.guide-step__points li { scroll-margin-top: 88px; border-radius: 8px; display: flex; gap: 12px; font-size: clamp(1rem, 1.3vw, 1.15rem); line-height: 1.55; color: var(--text-primary); }
.guide-step__check { flex: 0 0 26px; height: 26px; margin-top: 1px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: var(--surface); color: var(--accent-hover); }
.guide-step__check svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
/* S240: o ponto aberto pelo "Como funciona" de uma tela do painel (`/ajuda/guia#daily-p6`). */
.guide-step__points li:target { background: #ecfdf5; box-shadow: 0 0 0 8px #ecfdf5; }
.guide-step__tip { display: flex; gap: 12px; align-items: flex-start; max-width: 900px; margin: 0 0 24px; padding: 14px 18px; border-radius: 14px; background: #fff8e6; border: 1px solid #f3d38b; color: #5b3d06; font-size: 1.02rem; }
.guide-step__tip p { margin: 0; }
.guide-step__tip-icon { flex: 0 0 22px; color: #92400e; margin-top: 2px; }
.guide-step__tip-icon svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.guide-shot { margin: 0 0 24px; }
.guide-shot a { display: block; cursor: zoom-in; }
.guide-shot img { display: block; width: 100%; height: auto; border-radius: 14px; border: 1px solid var(--border); box-shadow: var(--card-shadow); background: var(--bg-card); }
.guide-shot figcaption { margin-top: 10px; font-size: .95rem; color: var(--text-muted); }
.guide-shot--mobile { max-width: 380px; }
.guide-shot--mobile img { border-radius: 24px; }
.guide-step__nav { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin-top: 8px; }
.guide-step__nav .guide-step__next { display: inline-flex; align-items: center; gap: 10px; max-width: 100%; white-space: normal; text-align: left; }
.guide-step__nav .guide-step__next span { min-width: 0; white-space: normal; overflow-wrap: anywhere; }
.guide-step__next svg { flex: 0 0 18px; width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.guide-step__top { font-weight: 600; color: var(--text-muted); }
.help-guide-card { max-width: 820px; margin: 0 auto 40px; display: flex; gap: 18px; align-items: center; padding: 22px 24px; border-radius: 18px; background: var(--bg-card); border: 2px solid var(--accent); box-shadow: var(--card-shadow); }
.help-guide-card__icon { flex: 0 0 52px; height: 52px; border-radius: 14px; display: inline-flex; align-items: center; justify-content: center; background: var(--accent); color: #fff; }
.help-guide-card__icon svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.help-guide-card__body { flex: 1; min-width: 0; }
.help-guide-card__title { margin: 0 0 4px; font-size: 1.25rem; color: var(--text-primary); }
.help-guide-card__desc { margin: 0; color: var(--text-secondary); }
@media (min-width: 1024px) and (min-height: 700px) {
    /* Projetando: cada passo ocupa ao menos uma tela ao rolar. */
    .guide-step { min-height: calc(100vh - 96px); }
}
@media (max-width: 1023px) {
    .guide { grid-template-columns: minmax(0, 1fr); gap: 16px; }
    .guide-toc { position: static; max-height: none; overflow: visible; }
    .guide-toc__title { padding-bottom: 0; }
    .guide-toc__box[open] .guide-toc__title { padding-bottom: 8px; }
    .guide-toc__title::after { content: ' ▾'; color: var(--accent); }
}
@media (max-width: 600px) {
    .guide-step { padding: 28px 0 32px; }
    .guide-step__head { gap: 12px; }
    .guide-step__icon { flex-basis: 44px; height: 44px; border-radius: 12px; }
    .guide-step__icon svg { width: 22px; height: 22px; }
    .guide-step__next { width: 100%; justify-content: space-between; }
    .help-guide-card { flex-direction: column; align-items: flex-start; }
}
