/* ==========================================================================
   Rafa Félix · Diagnóstico extrajudicial gratuito
   Estrutura na linha da página de referência do Jeff (Mentoria Farma
   Clínico, do Mário): hero com promessa e números, faixa de credenciais,
   seções centralizadas com título em duas cores, cartões curtos, pilares em
   3 cartões, mentora com checklist, CTA final em cartão.
   Identidade da Rafa no lugar do azul: vinho #440B11, dourado #CEA95D,
   Chonza Bularoi nos títulos, General Sans no resto.

   1 Fontes  2 Tokens  3 Base  4 Peças  6 Hero  7 Faixa
   8 Seções  9 Dores  10 Números  11 Mentora  12 Depoimentos  13 Pilares
   14 Dúvidas  15 CTA e formulário  16 Rodapé e barra  17 Movimento
   18 Telas largas
   ========================================================================== */

/* 1. Fontes ---------------------------------------------------------------- */
@font-face { font-family: "Chonza Bularoi"; src: url("assets/fontes/chonza-regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Chonza Bularoi"; src: url("assets/fontes/chonza-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "General Sans"; src: url("assets/fontes/general-regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "General Sans"; src: url("assets/fontes/general-medium.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "General Sans"; src: url("assets/fontes/general-semibold.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }

/* 2. Tokens ---------------------------------------------------------------- */
:root {
  --vinho: #440B11;
  --noite: #1F0407;
  --ouro: #CEA95D;
  --ouro-claro: #E1CC8C;

  --fundo: #170306;                      /* um passo abaixo da noite, pras seções lisas */
  --cartao: rgb(68 11 17 / .38);
  --creme: #F3EADF;
  --creme-medio: rgb(243 234 223 / .74);
  --creme-fraco: rgb(243 234 223 / .55);
  --fio: rgb(206 169 93 / .16);
  --fio-forte: rgb(206 169 93 / .38);
  --brilho: rgb(206 169 93 / .22);

  --raio: 22px;

  --titulo: "Chonza Bularoi", "Didot", Georgia, serif;
  --texto: "General Sans", "Helvetica Neue", Arial, sans-serif;

  --larg: 1200px;
  --gutter: clamp(20px, 5vw, 56px);
  --lado: max(var(--gutter), calc((100vw - var(--larg)) / 2));
  --secao: clamp(80px, 9vw, 120px);
  --ease: cubic-bezier(.16, 1, .3, 1);
}

/* 3. Base ------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
html { color-scheme: dark; overflow-x: clip; -webkit-text-size-adjust: 100%; font-synthesis: none; scroll-padding-top: 84px; interpolate-size: allow-keywords; }
/* rolagem nativa (sem Lenis): responde na hora ao dedo e à roda do mouse */
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
html:has(dialog[open]) { overflow: hidden; }
body { margin: 0; background: var(--fundo); color: var(--creme); font: 400 1.0625rem/1.6 var(--texto); -webkit-font-smoothing: antialiased; overflow-x: clip; }
img, svg { display: block; max-width: 100%; height: auto; }
h1, h2, h3, p, ul, ol, dl, dd, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }
::selection { background: var(--ouro); color: var(--noite); }
:focus-visible { outline: 2px solid var(--ouro); outline-offset: 4px; }

/* títulos: Chonza grande, segunda parte em dourado (o "azul" do Mário) */
h1, h2 { font-family: var(--titulo); font-weight: 400; line-height: 1.04; letter-spacing: -.01em; text-wrap: balance; color: var(--creme); }
h2 { font-size: clamp(2.5rem, 5.4vw, 4.4rem); }
.ouro { color: var(--ouro); }
h3 { font: 500 1.2rem/1.3 var(--texto); }
p { text-wrap: pretty; }
.linha-mask { padding: 0 .08em .12em; margin: 0 -.08em -.12em; }

/* 4. Peças ----------------------------------------------------------------- */
.rotulo, .selo { display: inline-flex; align-items: center; gap: 8px; font: 500 .74rem/1 var(--texto); letter-spacing: .24em; text-transform: uppercase; color: var(--ouro); }
.rotulo svg, .selo svg { width: 15px; height: 15px; }
.selo { padding: 9px 16px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--fio-forte); background: rgb(206 169 93 / .06); }

.botao {
  position: relative; isolation: isolate; overflow: hidden;
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  min-height: 54px; padding: 0 30px; border: 0; border-radius: 999px;
  font: 500 1rem/1 var(--texto); white-space: nowrap; text-decoration: none; cursor: pointer;
  transition: background-color .3s, box-shadow .5s var(--ease);
}
.botao:active { scale: .98; }
.botao--ouro { color: var(--noite); background: var(--ouro); box-shadow: inset 0 1px 0 rgb(255 255 255 / .35), 0 14px 40px -12px rgb(206 169 93 / .55); }
.botao--ouro::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(105deg, transparent 35%, rgb(255 255 255 / .45) 50%, transparent 65%); translate: -120% 0; transition: translate .9s var(--ease); }
.botao--ouro:hover { background: var(--ouro-claro); box-shadow: inset 0 1px 0 rgb(255 255 255 / .45), 0 18px 50px -10px rgb(206 169 93 / .7); }
.botao--ouro:hover::after { translate: 120% 0; }
.botao--pequeno { min-height: 42px; padding: 0 20px; font-size: .9rem; }
.botao--grande { min-height: 62px; padding: 0 40px; font-size: 1.04rem; letter-spacing: .04em; }
.link { display: inline-flex; align-items: center; gap: 8px; color: var(--creme-medio); font-weight: 500; text-decoration: none; transition: color .2s; }
.link svg { width: 15px; height: 15px; transition: translate .4s var(--ease); }
.link:hover { color: var(--ouro-claro); }
.link:hover svg { translate: 3px 0; }

.checks { display: grid; gap: 14px; }
.checks li { display: grid; grid-template-columns: 22px 1fr; gap: 12px; align-items: start; color: var(--creme); line-height: 1.45; }
.checks svg { width: 22px; height: 22px; color: var(--ouro); }

/* 6. Hero: a foto da Rafa é o fundo, fundindo no vinho -------------------- */
.hero {
  position: relative; overflow: hidden; isolation: isolate;
  min-height: 100svh; display: grid; align-items: end;
  padding: 0 var(--lado) max(9svh, 56px);
  background: var(--noite);
}
/* celular e tablet: a foto vertical inteira na largura (2:3), presa no topo; o texto
   entra na parte escura de baixo dela, sem cobrir o rosto nem as mãos */
.hero__foto { position: absolute; inset: 0 0 auto; height: 150vw; z-index: -1; margin: 0; }
.hero__foto picture { display: contents; }
.hero__foto img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 0%; }
.hero__foto::after { /* celular: a foto ocupa o topo e escurece para o texto embaixo */
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to bottom, transparent 55%, rgb(31 4 7 / .6) 75%, var(--noite) 100%);
}
/* celular e tablet: texto centralizado embaixo do retrato, como na página da Érica */
.hero__texto { display: grid; gap: 22px; justify-items: center; text-align: center; }
.hero__titulo { margin-inline: auto; }
.hero__sub { margin-inline: auto; }
.hero__titulo { font-size: clamp(2.3rem, 9.6vw, 5.6rem); line-height: 1.02; max-width: 12ch; }
.hero__sub { max-width: 34rem; color: var(--creme-medio); font-size: clamp(.98rem, 3.9vw, 1.12rem); line-height: 1.6; }
.hero__acoes { margin-top: 6px; }

/* 7. Faixa de credenciais -------------------------------------------------- */
.faixa-cred { padding: 26px var(--lado); text-align: center; font: 500 .72rem/1.9 var(--texto); letter-spacing: .24em; text-transform: uppercase; color: var(--creme-fraco); background: var(--noite); border-block: 1px solid var(--fio); }

/* 8. Seções ---------------------------------------------------------------- */
.secao { position: relative; isolation: isolate; padding: var(--secao) var(--lado); }
.secao--trama { background: radial-gradient(70% 70% at 50% 0%, rgb(68 11 17 / .75), transparent 75%), var(--noite); border-block: 1px solid var(--fio); }
.secao--centro { display: grid; justify-items: center; text-align: center; }
.secao--centro h2 { max-width: 20ch; margin-top: 16px; }
.secao__sub { margin-top: 18px; max-width: 38rem; color: var(--creme-medio); font-size: 1.1rem; }

/* cartão com brilho que segue o cursor (o "glow" da referência) */
[data-cartao]:not(form) { position: relative; border-radius: var(--raio); background: var(--cartao); box-shadow: inset 0 0 0 1px var(--fio); overflow: hidden; transition: box-shadow .4s, translate .5s var(--ease); }
[data-cartao]:not(form)::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .4s; background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 0%), var(--brilho), transparent 70%); }
[data-cartao]:not(form):hover { box-shadow: inset 0 0 0 1px var(--fio-forte); translate: 0 -3px; }
[data-cartao]:not(form):hover::before { opacity: 1; }

/* 9. Dores ----------------------------------------------------------------- */
.dores { margin-top: 48px; width: min(100%, 800px); display: grid; gap: 14px; text-align: left; }
.dores li { padding: 24px 26px 24px 52px; font-size: 1.04rem; line-height: 1.45; }
.dores li::after { content: ""; position: absolute; left: 26px; top: 33px; width: 12px; height: 1px; background: var(--ouro); }

/* 10. Números -------------------------------------------------------------- */
.numeros { margin-top: 48px; width: 100%; display: grid; gap: 14px; }
.numeros div { padding: 34px 24px; }
.numeros dt { font: 400 clamp(3.4rem, 7vw, 5rem)/1 var(--titulo); color: var(--ouro); font-variant-numeric: lining-nums; }
.numeros dd { margin-top: 12px; color: var(--creme-medio); }
.numeros sup, .fontes sup { color: var(--ouro); font-size: .62em; margin-left: 2px; }
.fontes { margin-top: 24px; max-width: 60rem; font-size: .76rem; line-height: 1.9; color: var(--creme-fraco); }
.fontes a { color: inherit; text-underline-offset: 3px; text-decoration-color: var(--fio-forte); }
.fontes a:hover { color: var(--ouro-claro); }

/* 11. Mentora -------------------------------------------------------------- */
.mentora { display: grid; gap: 48px; align-items: center; }
.mentora__foto { position: relative; isolation: isolate; margin: 0; width: min(100%, 480px); justify-self: center; }
.mentora__foto::before { content: ""; position: absolute; inset: 6% -8% -4%; z-index: -1; background: radial-gradient(closest-side, rgb(206 169 93 / .26), transparent); filter: blur(30px); }
.mentora__foto img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: 50% 18%; border-radius: 28px; box-shadow: inset 0 0 0 1px var(--fio-forte); }
.mentora__texto { display: grid; gap: 20px; justify-items: start; }
.mentora__texto h2 { font-size: clamp(3rem, 6.4vw, 5rem); }
.mentora__texto > p { max-width: 34rem; color: var(--creme-medio); }
.mentora__texto strong { color: var(--creme); font-weight: 500; }
.mentora .checks { margin-top: 8px; }
.mentora__numeros { display: grid; grid-template-columns: 1fr 1fr; width: 100%; max-width: 34rem; border-block: 1px solid var(--fio); }
.mentora__numeros div { padding: 20px 16px 20px 0; }
.mentora__numeros div + div { padding-left: 20px; border-left: 1px solid var(--fio); }
.mentora__numeros dt { font: 400 clamp(2.4rem, 4.4vw, 3.4rem)/1 var(--titulo); color: var(--ouro); white-space: nowrap; }
.mentora__numeros dd { margin-top: 8px; font-size: .9rem; color: var(--creme-medio); }

/* 12. Depoimentos ---------------------------------------------------------- */
/* colunas que sobem sem parar (adaptado do testimonial-v2 do 21st.dev, sem
   React: a lista é duplicada pelo cena.js e anda -50% em loop) */
.depoimentos { overflow: hidden; }
.depo {
  margin-top: 52px; width: 100%; max-height: 740px; overflow: hidden;
  display: flex; justify-content: center; gap: 22px; text-align: left;
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 12%, #000 88%, transparent);
          mask-image: linear-gradient(to bottom, transparent, #000 12%, #000 88%, transparent);
}
.depo__coluna { flex: 0 1 340px; min-width: 0; }
.depo__coluna--2, .depo__coluna--3 { display: none; }
.depo ul { will-change: transform; display: flex; flex-direction: column; gap: 22px; padding-bottom: 22px; }
.depo li {
  position: relative; padding: 32px 30px; border-radius: 24px;
  background: var(--cartao); box-shadow: inset 0 0 0 1px var(--fio);
  transition: translate .5s var(--ease), box-shadow .4s, background-color .4s;
}
.depo li:hover { translate: 0 -6px; background: rgb(68 11 17 / .6); box-shadow: inset 0 0 0 1px var(--fio-forte), 0 30px 60px -30px rgb(206 169 93 / .35); }
.depo li svg { width: 28px; height: 28px; color: var(--ouro); margin-bottom: 16px; }
.depo li p { color: var(--creme); font-size: 1rem; line-height: 1.65; }
@media (prefers-reduced-motion: no-preference) {
  .depo ul.is-loop { animation: subir-depo var(--duracao, 36s) linear infinite; }
  .depo:hover ul.is-loop { animation-play-state: paused; }
}
@keyframes subir-depo { to { translate: 0 -50%; } }
@media (prefers-reduced-motion: reduce) {
  .depo { max-height: none; -webkit-mask-image: none; mask-image: none; flex-wrap: wrap; }
}
@media (min-width: 768px) { .depo__coluna--2 { display: block; } }
@media (min-width: 1024px) { .depo__coluna--3 { display: block; } }

/* 13. Pilares -------------------------------------------------------------- */
.pilares { margin-top: 52px; width: 100%; display: grid; gap: 16px; text-align: left; }
.pilar { padding: 34px 30px 36px; display: grid; gap: 12px; align-content: start; }
.pilar__num { font: 400 3.6rem/1 var(--titulo); color: transparent; -webkit-text-stroke: 1px var(--fio-forte); margin-bottom: 14px; }
.pilar p { color: var(--creme-medio); }

/* 13b. A tese: bússola + frase, com a tela presa ------------------------- */
.mercado__palco {
  position: relative; isolation: isolate; height: 100svh; overflow: hidden;
  display: grid; place-items: center; align-content: center; gap: 4.5vh;
  padding: 0 var(--gutter); text-align: center;
  background: radial-gradient(60% 55% at 50% 45%, rgb(110 20 30 / .55), transparent 70%), var(--fundo);
}
.mercado__bussola { width: min(30vmin, 270px); }
.mercado__titulo { max-width: 14ch; font-size: clamp(2.6rem, 6.4vw, 5.6rem); line-height: 1.04; }
.mercado__titulo em { font-style: italic; color: var(--ouro); }
.mercado__acao { margin-top: 1vh; }

/* 14. Dúvidas -------------------------------------------------------------- */
.perguntas { margin-top: 40px; width: min(100%, 760px); display: grid; gap: 10px; text-align: left; }
.perguntas details { border-radius: 16px; background: var(--cartao); box-shadow: inset 0 0 0 1px var(--fio); }
.perguntas summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 20px 24px; font-weight: 500; }
.perguntas summary::-webkit-details-marker { display: none; }
.perguntas summary svg { flex: none; width: 20px; height: 20px; color: var(--ouro); transition: rotate .4s var(--ease); }
.perguntas details[open] summary svg { rotate: 45deg; }
.perguntas details p { padding: 0 24px 22px; color: var(--creme-medio); }
.perguntas details::details-content { height: 0; overflow: clip; transition: height .5s var(--ease), content-visibility .5s allow-discrete; }
.perguntas details[open]::details-content { height: auto; }

/* 16. Rodapé e barra ------------------------------------------------------- */
.rodape { padding: 44px var(--gutter) calc(96px + env(safe-area-inset-bottom)); display: grid; justify-items: center; gap: 6px; text-align: center; font-size: .84rem; color: var(--creme-fraco); }
.rodape img { width: 32px; margin-bottom: 8px; }
.rodape a { color: var(--ouro-claro); text-decoration: none; }
.barra { position: fixed; z-index: 40; left: 0; right: 0; bottom: 0; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px var(--gutter) calc(12px + env(safe-area-inset-bottom)); background: rgb(23 3 6 / .94); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); box-shadow: 0 -1px 0 var(--fio); font-size: .88rem; translate: 0 110%; transition: translate .45s var(--ease); }
.barra.is-visivel { translate: 0 0; }

/* 17. Movimento: estados iniciais (só com JS e movimento liberado) --------- */
@media (prefers-reduced-motion: no-preference) {
  .js [data-surge], .js [data-linhas], .js [data-cartao], .js [data-hero-foto],
  .js [data-bussola], .js [data-mercado-titulo], .js [data-mercado-acao] { visibility: hidden; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; }
}

/* 18. Telas largas --------------------------------------------------------- */
@media (min-width: 720px) {
  .numeros { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1024px) {
  .barra { display: none; }
  .rodape { padding-bottom: 44px; }

  /* desktop: retrato em painel à direita, na altura toda; texto à esquerda */
  .hero { align-items: center; padding-block: 72px; }
  .hero__foto { inset: 0; height: auto; }
  /* banner horizontal ocupando a tela toda; o lado esquerdo dele já é liso e escuro.
     Ancorado no topo à direita: em tela mais larga que 16:9 o corte cai no pé e na
     esquerda, nunca na cabeça dela */
  .hero__foto img { object-position: 72% 0%; }
  .hero__foto::after {
    background:
      linear-gradient(to right, rgb(31 4 7 / .55) 0%, transparent 40%),
      linear-gradient(to bottom, transparent 70%, var(--noite) 100%);
  }
  .hero__texto { max-width: 50%; justify-items: start; text-align: left; }
  .hero__titulo, .hero__sub { margin-inline: 0; }
  .hero__titulo { font-size: clamp(3.4rem, 4.6vw, 5.4rem); max-width: none; white-space: nowrap; }
  .hero__titulo .ouro { display: block; }

  .pilares { grid-template-columns: repeat(3, 1fr); }
  .mentora { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 88px; }
}

.barra span { white-space: nowrap; }

/* celular: a Rafa maior (foto ampliada ~33%) e o título começando logo abaixo das
   mãos. As mãos ficam a ~48% da altura do banner vertical; com a foto em 200vw de
   altura elas caem em ~96vw, e o texto começa em 100vw. */
@media (max-width: 699px) {
  .hero { min-height: 100svh; align-items: start; padding-top: 100vw; padding-bottom: 48px; }
  .hero__foto { height: 200vw; }
  .hero__foto img { object-position: 50% 0%; }
  .hero__foto::after { background: linear-gradient(to bottom, transparent 46%, rgb(31 4 7 / .55) 56%, rgb(31 4 7 / .9) 68%, var(--noite) 82%); }
}

/* celular e tablet: título em 2 linhas fixas, "Consultoria Gratuita / de Extrajudicial".
   Na Chonza, "Consultoria Gratuita" mede 8,0× o tamanho da fonte; dividir a largura
   útil por 8,4 faz a linha ocupar a tela com folga, em qualquer celular. */
@media (max-width: 1023px) {
  .hero__titulo { max-width: none; white-space: nowrap; font-size: min(calc((100vw - 2 * var(--gutter)) / 8.4), 5.6rem); }
  .hero__titulo .ouro { display: block; }
}
