/* ===================================================================
   Landing do e-book "O Manual de IA da Sua Empresa"
   Compartilhado por /ebook/, /ebook/en/, /ebook/obrigado/
   e /ebook/pagamento-cancelado/.
   Paleta do site (fundo escuro, acento #00b2f0) com a tipografia do
   briefing: Nunito nos títulos, Inter no texto. Nunito é arredondada e
   suave; Inter foi desenhada para leitura em tela.
   =================================================================== */

:root {
    --accent:      #00b2f0;
    --accent-soft: rgba(0, 178, 240, 0.12);
    --accent-line: rgba(0, 178, 240, 0.28);
    --ok:          #10b981;
    --bg:          #05080f;
    --surface:     #080d18;
    --surface2:    #0c1220;
    --border:      rgba(255, 255, 255, 0.07);
    --border-str:  rgba(255, 255, 255, 0.14);
    --text:        #e8eef7;
    --text-body:   #94a3b8;
    --text-dim:    #64748b;
}

html { scroll-behavior: smooth; }

body {
    background: var(--bg);
    color: var(--text);
    font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1, h2, h3, .font-display {
    font-family: 'Nunito', 'Inter', system-ui, sans-serif;
    letter-spacing: -0.015em;
}

/* Texto corrido um pouco mais solto: Inter fica apertada no default. */
p, li { line-height: 1.65; }

/* ── Fundo com brilho sutil no topo ───────────────────────────────── */
.glow-top::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(900px 420px at 78% -8%, rgba(0, 178, 240, 0.16), transparent 62%),
        radial-gradient(700px 380px at 8% 10%, rgba(0, 178, 240, 0.07), transparent 60%);
    pointer-events: none;
}

/* ── Reveal on scroll (mesmo padrão de solucoes/) ─────────────────── */
.reveal {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity 0.75s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.75s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal.visible { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .reveal { opacity: 1; transform: none; transition: none; }
}

/* ── Elementos de marca ───────────────────────────────────────────── */
.badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--accent-soft);
    border: 1px solid var(--accent-line);
    color: var(--accent);
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.09em;
    text-transform: uppercase;
}

.eyebrow {
    color: var(--accent);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.rule {
    width: 56px;
    height: 3px;
    border-radius: 2px;
    background: var(--accent);
}

/* ── Cards ────────────────────────────────────────────────────────── */
.card {
    position: relative;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 18px;
    transition: border-color 0.35s, transform 0.35s, box-shadow 0.35s;
}
.card:hover {
    border-color: var(--accent-line);
    box-shadow: 0 22px 60px rgba(0, 0, 0, 0.5);
}
.card-accent::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    border-radius: 18px 18px 0 0;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 0;
    transition: opacity 0.35s;
}
.card-accent:hover::after { opacity: 1; }

/* ── Botões ───────────────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border-radius: 12px;
    font-weight: 700;
    text-align: center;
    padding: 15px 28px;
    transition: transform 0.2s, background 0.2s, border-color 0.2s, opacity 0.2s;
    cursor: pointer;
    border: 1px solid transparent;
    line-height: 1.2;
}
/* CTAs inline ficam numa linha só; os de largura total podem quebrar,
   senão estouram a tela em aparelho estreito. */
.btn:not(.w-full) { white-space: nowrap; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }

.btn-primary { background: var(--accent); color: #04121c; }
.btn-primary:hover:not(:disabled) { background: #2ac2f7; }

.btn-ghost {
    background: transparent;
    color: var(--text);
    border-color: var(--border-str);
}
.btn-ghost:hover:not(:disabled) { border-color: var(--accent); color: var(--accent); }

.btn-wa { background: #1f2d3d; color: #e8eef7; border-color: var(--border-str); }
.btn-wa:hover { border-color: #25d366; color: #25d366; }

/* ── Formulários ──────────────────────────────────────────────────── */
.field {
    width: 100%;
    background: #060a12;
    border: 1px solid var(--border-str);
    border-radius: 11px;
    padding: 12px 14px;
    color: var(--text);
    font-size: 15px;
    font-family: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.field::placeholder { color: #4b5b70; }
.field:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(0, 178, 240, 0.14);
}
.field:invalid:not(:placeholder-shown) { border-color: #f87171; }

select.field { appearance: none; cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%2364748b' stroke-width='2'%3E%3Cpath d='M4 6l4 4 4-4'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 38px;
}
select.field option { background: #0c1220; color: var(--text); }

.field-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-body);
    margin-bottom: 6px;
}

/* Honeypot: escondido por CSS, nunca com type="hidden". */
.hp-field {
    position: absolute !important;
    left: -9999px !important;
    top: -9999px !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* Caixa de consentimento */
.consent-box {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    background: #060a12;
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 14px;
}
.consent-box input[type="checkbox"] {
    margin-top: 3px;
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
    accent-color: var(--accent);
    cursor: pointer;
}

/* Aviso do formulário */
.form-note { font-size: 14px; min-height: 20px; }
.form-note.err { color: #fca5a5; }
.form-note.ok  { color: var(--ok); }

/* ── Páginas reais do livro ───────────────────────────────────────── */
.page-shot {
    border-radius: 12px;
    border: 1px solid var(--border-str);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.55);
    display: block;
    width: 100%;
    height: auto;
    background: #fff;
}

/* ── Barra de distribuição dos prompts ────────────────────────────── */
.bar-track {
    height: 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.06);
    overflow: hidden;
}
.bar-fill {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--accent), #7dd8ff);
    width: 0;
    transition: width 1.1s cubic-bezier(0.22, 1, 0.36, 1);
}

/* ── Sumário ──────────────────────────────────────────────────────── */
.toc-row {
    display: flex;
    align-items: baseline;
    gap: 10px;
    padding: 9px 0;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.08);
}
.toc-row:last-child { border-bottom: none; }
.toc-num {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    color: var(--accent);
    font-size: 13px;
    flex: 0 0 auto;
    width: 26px;
}
.toc-dots { flex: 1 1 auto; border-bottom: 1px dotted rgba(255, 255, 255, 0.16); }
.toc-pg { color: var(--text-dim); font-size: 13px; font-variant-numeric: tabular-nums; }

/* ── FAQ ──────────────────────────────────────────────────────────── */
details.faq {
    border-bottom: 1px solid var(--border);
    padding: 4px 0;
}
details.faq summary {
    cursor: pointer;
    list-style: none;
    padding: 18px 40px 18px 0;
    font-weight: 700;
    font-size: 16px;
    position: relative;
    color: var(--text);
}
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after {
    content: '+';
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 22px;
    color: var(--accent);
    font-weight: 400;
    line-height: 1;
}
details.faq[open] summary::after { content: '–'; }
details.faq summary:hover { color: var(--accent); }
details.faq .faq-a {
    color: var(--text-body);
    padding: 0 40px 20px 0;
    line-height: 1.7;
    font-size: 15px;
}

/* ── Barra fixa de compra no mobile ───────────────────────────────── */
#sticky-buy {
    position: fixed;
    left: 0; right: 0; bottom: 0;
    z-index: 60;
    background: rgba(8, 13, 24, 0.94);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid var(--border-str);
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
    display: none;
    align-items: center;
    gap: 12px;
}
#sticky-buy.show { display: flex; }
@media (min-width: 1024px) { #sticky-buy { display: none !important; } }

/* Respiro para a barra fixa não cobrir o fim do rodapé. Só nas páginas
   que realmente têm a barra — obrigado/ e pagamento-cancelado/ não têm. */
@media (max-width: 1023px) {
    body:has(#sticky-buy) { padding-bottom: 78px; }
}

/* ── Utilidades ───────────────────────────────────────────────────── */
.text-body { color: var(--text-body); }
.text-dim  { color: var(--text-dim); }
.hairline  { border-color: var(--border); }
.surface   { background: var(--surface); }
.surface2  { background: var(--surface2); }

.link-a { color: var(--accent); text-decoration: none; }
.link-a:hover { border-bottom: 1px solid var(--accent); }

/* Rodapé compartilhado do site é claro; garante respiro acima dele. */
foo-ter { display: block; }

/* ═══════════════════════════════════════════════════════════════════
   Blocos de impacto
   Tudo aqui existe para mostrar substância, não para enfeitar: o
   mosaico desenha os 500 prompts de verdade, a calculadora roda o
   método do capítulo 1 com os números do visitante.
   ═══════════════════════════════════════════════════════════════════ */

/* ── Hero: brilho e flutuação do livro ───────────────────────────── */
.hero-book { position: relative; }
.hero-book::before {
    content: '';
    position: absolute;
    inset: -14% -8%;
    background: radial-gradient(closest-side, rgba(0,178,240,0.30), transparent 72%);
    filter: blur(38px);
    z-index: 0;
    pointer-events: none;
}
.hero-book img {
    position: relative;
    z-index: 1;
    animation: flutua 7s ease-in-out infinite;
}
@keyframes flutua {
    0%, 100% { transform: translateY(0) }
    50%      { transform: translateY(-12px) }
}
@media (prefers-reduced-motion: reduce) {
    .hero-book img { animation: none; }
}

/* Contadores: tabular-nums evita o número "dançar" enquanto sobe. */
.counter { font-variant-numeric: tabular-nums; }

/* ── Mosaico dos 500 prompts ─────────────────────────────────────── */
.mosaico {
    display: grid;
    grid-template-columns: repeat(25, 1fr);
    gap: 3px;
    margin-top: 4px;
}
@media (max-width: 640px) {
    .mosaico { grid-template-columns: repeat(20, 1fr); gap: 2px; }
}
.mosaico i {
    display: block;
    aspect-ratio: 1;
    border-radius: 2px;
    background: var(--cel, rgba(0,178,240,0.34));
    opacity: 0;
    transform: scale(0.4);
    transition: opacity .45s ease, transform .45s ease, background .25s ease;
}
.mosaico.on i { opacity: 1; transform: scale(1); }
/* Quando um setor está selecionado, os outros recuam. */
.mosaico.filtrando i { background: rgba(255,255,255,0.07); }
.mosaico.filtrando i.ativo { background: var(--accent); }

.setor-linha {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 7px 9px;
    border-radius: 9px;
    border: 1px solid transparent;
    background: transparent;
    cursor: pointer;
    text-align: left;
    transition: background .2s, border-color .2s;
    font-family: inherit;
    color: inherit;
}
.setor-linha:hover { background: rgba(255,255,255,0.04); }
.setor-linha.sel {
    background: var(--accent-soft);
    border-color: var(--accent-line);
}
.setor-tag {
    flex: 0 0 auto;
    width: 42px;
    font-weight: 800;
    font-size: 11px;
    letter-spacing: .06em;
    color: var(--accent);
}
.setor-nome { flex: 1 1 auto; font-size: 13.5px; color: var(--text-body); }
.setor-qtd  { flex: 0 0 auto; font-size: 13px; color: var(--text-dim); font-variant-numeric: tabular-nums; }
.setor-linha.sel .setor-nome { color: var(--text); }

/* ── Calculadora da régua dos 20 minutos ─────────────────────────── */
.calc-campo { display: flex; flex-direction: column; gap: 6px; }
.calc-campo input[type=range] {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 4px;
    border-radius: 999px;
    background: rgba(255,255,255,0.12);
    outline: none;
    cursor: pointer;
}
.calc-campo input[type=range]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px; height: 20px;
    border-radius: 50%;
    background: var(--accent);
    border: 3px solid var(--surface2);
    box-shadow: 0 0 0 1px var(--accent-line);
    cursor: grab;
}
.calc-campo input[type=range]::-moz-range-thumb {
    width: 16px; height: 16px;
    border-radius: 50%;
    background: var(--accent);
    border: 3px solid var(--surface2);
    cursor: grab;
}
.calc-topo {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 10px;
}
.calc-valor {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    color: var(--text);
    font-variant-numeric: tabular-nums;
    font-size: 15px;
}
.calc-saida {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

/* ── Páginas reais: ampliar no clique ────────────────────────────── */
.page-shot { cursor: zoom-in; transition: transform .35s, box-shadow .35s; }
.page-shot:hover { transform: translateY(-5px); box-shadow: 0 26px 64px rgba(0,0,0,0.6); }

#lightbox {
    position: fixed;
    inset: 0;
    z-index: 90;
    background: rgba(3, 6, 12, 0.93);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
}
#lightbox.open { display: flex; }
#lightbox img {
    max-width: min(760px, 100%);
    max-height: 92vh;
    width: auto;
    border-radius: 10px;
    box-shadow: 0 30px 90px rgba(0,0,0,0.7);
}
#lightbox button {
    position: absolute;
    top: 18px; right: 18px;
    width: 42px; height: 42px;
    border-radius: 50%;
    border: 1px solid var(--border-str);
    background: rgba(255,255,255,0.06);
    color: #fff;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
}
#lightbox button:hover { border-color: var(--accent); color: var(--accent); }
