/* ===== IA$ · identidade visual =====
   Fundo noturno, verde-dinheiro, dourado de moeda e violeta de tecnologia. */
:root {
  --fundo: #060914;
  --fundo-2: #0b1020;
  --cartao: rgba(255, 255, 255, .045);
  --cartao-solido: #111729;
  --cartao-hover: rgba(255, 255, 255, .075);
  --texto: #eef2ff;
  --suave: #9aa4bf;
  --linha: rgba(255, 255, 255, .09);
  --linha-forte: rgba(255, 255, 255, .16);
  --verde: #10e3a0;
  --verde-escuro: #0aa876;
  --ciano: #22d3ee;
  --ouro: #fbbf24;
  --ouro-claro: #fde68a;
  --ouro-escuro: #b7791f;
  --violeta: #8b5cf6;
  --rosa: #f472b6;
  --marca: var(--verde);
  --marca-forte: #5ff5c4;
  --marca-fundo: rgba(16, 227, 160, .12);
  --ok: #34d399;
  --ok-fundo: rgba(52, 211, 153, .13);
  --alerta: #fbbf24;
  --alerta-fundo: rgba(251, 191, 36, .13);
  --perigo: #fb7185;
  --gradiente: linear-gradient(120deg, #10e3a0 0%, #22d3ee 55%, #8b5cf6 100%);
  --gradiente-ouro: linear-gradient(135deg, #fde68a 0%, #fbbf24 45%, #d97706 100%);
  --sombra: 0 10px 30px -12px rgba(0, 0, 0, .6);
  --brilho: 0 0 0 1px rgba(16, 227, 160, .35), 0 12px 40px -10px rgba(16, 227, 160, .35);
  --raio: 16px;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--fundo); }
body {
  margin: 0; min-height: 100vh; color: var(--texto); background: var(--fundo);
  font: 16px/1.55 "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  background-image:
    radial-gradient(900px 600px at 0% -10%, rgba(16, 227, 160, .16), transparent 60%),
    radial-gradient(800px 600px at 100% 0%, rgba(139, 92, 246, .20), transparent 60%),
    radial-gradient(700px 500px at 60% 110%, rgba(251, 191, 36, .09), transparent 60%);
  background-attachment: fixed;
}
/* grade de "piso digital" bem sutil */
body::before {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: -1;
  background-image: linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at 50% 0%, #000 0%, transparent 75%);
}
a { color: var(--marca); text-decoration: none; }
a:hover { color: var(--marca-forte); }
h1, h2, h3 { line-height: 1.22; margin: 0 0 .5rem; letter-spacing: -.01em; }
h1 { font-size: 1.75rem; font-weight: 750; }
h2 { font-size: 1.22rem; font-weight: 700; }
h3 { font-size: 1.03rem; font-weight: 650; }
p { margin: 0 0 .75rem; }
.suave { color: var(--suave); }
.pequeno { font-size: .875rem; }
.texto-gradiente { background: var(--gradiente); -webkit-background-clip: text; background-clip: text; color: transparent; }
.texto-ouro { background: var(--gradiente-ouro); -webkit-background-clip: text; background-clip: text; color: transparent; }
::selection { background: rgba(16, 227, 160, .35); }

/* ===== topo ===== */
.topo { position: sticky; top: 0; z-index: 20; background: rgba(6, 9, 20, .72); backdrop-filter: blur(14px) saturate(140%); border-bottom: 1px solid var(--linha); }
.topo-dentro { max-width: 1200px; margin: 0 auto; padding: .65rem 16px; display: flex; gap: .4rem 1.1rem; align-items: center; flex-wrap: wrap; }
.logo { display: flex; align-items: center; gap: .6rem; color: var(--texto); font-weight: 800; font-size: 1.25rem; letter-spacing: -.02em; margin-right: .5rem; }
.logo:hover { color: var(--texto); }
.logo .marca-texto b { background: var(--gradiente-ouro); -webkit-background-clip: text; background-clip: text; color: transparent; }
.menu { display: flex; gap: .2rem; flex-wrap: wrap; flex: 1; }
.menu a { color: var(--suave); padding: .42rem .8rem; border-radius: 10px; font-weight: 550; white-space: nowrap; transition: color .2s, background .2s; }
.menu a:hover { color: var(--texto); background: rgba(255,255,255,.05); }
.menu a.ativo { color: #04140f; background: var(--gradiente); box-shadow: 0 6px 20px -8px rgba(16, 227, 160, .7); }
.selo { display: inline-block; min-width: 1.35rem; padding: 0 .35rem; border-radius: 99px; background: var(--gradiente-ouro); color: #3b2300; font-size: .74rem; font-weight: 800; text-align: center; line-height: 1.35rem; margin-left: .3rem; }
.conta { display: flex; gap: .85rem; align-items: center; font-size: .9rem; }
@media (max-width: 640px) {
  .conta { margin-left: auto; }
  .menu { order: 3; flex-basis: 100%; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
}

main { max-width: 1200px; margin: 0 auto; padding: 1.75rem 16px 4rem; }
.estreito { max-width: 800px; }

/* ===== blocos ===== */
.cartao {
  position: relative; background: var(--cartao); border: 1px solid var(--linha); border-radius: var(--raio);
  padding: 1.2rem 1.3rem; box-shadow: var(--sombra); backdrop-filter: blur(10px);
}
.cartao + .cartao { margin-top: 1rem; }
a.cartao { color: inherit; transition: transform .25s ease, border-color .25s, background .25s, box-shadow .25s; }
a.cartao:hover { border-color: rgba(16, 227, 160, .45); background: var(--cartao-hover); box-shadow: var(--brilho); color: inherit; }
.cartao.destaque { border-color: transparent; background:
  linear-gradient(var(--cartao-solido), var(--cartao-solido)) padding-box,
  var(--gradiente) border-box; border: 1px solid transparent; }
.grade { display: grid; gap: 1rem; }
.grade-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grade-3 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.linha { display: flex; gap: .6rem; align-items: center; flex-wrap: wrap; }
.entre { justify-content: space-between; }
.pilha > * + * { margin-top: 1rem; }
.cabecalho { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.4rem; }
.migalha { font-size: .85rem; color: var(--suave); margin-bottom: .4rem; }
.migalha a { color: var(--suave); }
.migalha a:hover { color: var(--texto); }
.vazio { text-align: center; padding: 2.2rem 1rem; color: var(--suave); }

/* inclinação 3D nos cartões (o JS move as variáveis) */
[data-inclinar] { transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateZ(0); transform-style: preserve-3d; will-change: transform; }
[data-inclinar]::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: var(--luz, 0);
  background: radial-gradient(400px circle at var(--mx, 50%) var(--my, 50%), rgba(255,255,255,.10), transparent 45%);
  transition: opacity .3s;
}

/* ===== números ===== */
.numero { font-size: 2.3rem; font-weight: 800; line-height: 1; letter-spacing: -.03em; }
.rotulo { font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; color: var(--suave); font-weight: 650; }
.barra { height: 9px; background: rgba(255,255,255,.07); border-radius: 99px; overflow: hidden; }
.barra > div { height: 100%; background: var(--gradiente); border-radius: 99px; box-shadow: 0 0 14px rgba(16, 227, 160, .6); min-width: 2px; }
.barra.ok > div { background: var(--gradiente-ouro); box-shadow: 0 0 14px rgba(251, 191, 36, .6); }

/* ===== botões e formulários ===== */
.botao, button {
  font: inherit; cursor: pointer; border: 1px solid var(--linha-forte); background: rgba(255,255,255,.04); color: var(--texto);
  padding: .55rem 1rem; border-radius: 11px; font-weight: 650; display: inline-flex; align-items: center; gap: .45rem;
  text-decoration: none; transition: transform .15s, box-shadow .2s, background .2s, border-color .2s;
}
.botao:hover, button:hover { border-color: rgba(255,255,255,.3); background: rgba(255,255,255,.08); color: var(--texto); }
.botao:active, button:active { transform: translateY(1px); }
.primario, .botao.primario { background: var(--gradiente); border-color: transparent; color: #03130e; box-shadow: 0 10px 26px -10px rgba(16, 227, 160, .8); }
.primario:hover, .botao.primario:hover { background: var(--gradiente); color: #03130e; filter: brightness(1.08); box-shadow: 0 14px 32px -10px rgba(16, 227, 160, .95); }
.sucesso, .botao.sucesso { background: var(--gradiente-ouro); border-color: transparent; color: #2f1c00; box-shadow: 0 10px 26px -10px rgba(251, 191, 36, .8); }
.sucesso:hover { background: var(--gradiente-ouro); color: #2f1c00; filter: brightness(1.06); }
.perigo { color: var(--perigo); }
.link, button.link { background: none; border: none; padding: 0; color: var(--marca); font-weight: 550; box-shadow: none; }
.link:hover, button.link:hover { background: none; color: var(--marca-forte); }
.link.perigo { color: var(--perigo); }
.pequeno-botao { padding: .28rem .65rem; font-size: .85rem; }
label { display: block; font-size: .85rem; font-weight: 650; margin-bottom: .3rem; color: #cfd6ea; }
input[type=text], input[type=email], input[type=password], input[type=url], input[type=number], input[type=date], input[type=file], select, textarea {
  width: 100%; font: inherit; color: var(--texto); background: rgba(3, 6, 15, .55); border: 1px solid var(--linha-forte);
  border-radius: 11px; padding: .55rem .75rem; transition: border-color .2s, box-shadow .2s;
}
select option { background: var(--cartao-solido); }
input::placeholder, textarea::placeholder { color: #6c7590; }
textarea { resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--verde); box-shadow: 0 0 0 3px rgba(16, 227, 160, .2); }
input[type=checkbox] { accent-color: var(--verde); width: 1rem; height: 1rem; }
.campo { margin-bottom: .9rem; }
.campo .ajuda { font-size: .8rem; color: var(--suave); margin-top: .25rem; }
.erro, .errorlist { color: var(--perigo); font-size: .85rem; margin: .3rem 0 0; padding: 0; list-style: none; }
.checks label { display: flex; align-items: center; gap: .5rem; font-weight: 500; margin: .25rem 0; }

/* ===== avisos ===== */
.avisos { list-style: none; padding: 0; margin: 0 0 1.1rem; }
.avisos li { padding: .7rem 1rem; border-radius: 12px; margin-bottom: .5rem; background: var(--marca-fundo); border: 1px solid rgba(16, 227, 160, .3); }
.avisos li.success { background: var(--ok-fundo); }
.avisos li.error { background: var(--alerta-fundo); border-color: rgba(251, 191, 36, .35); }

/* ===== moeda 3D ===== */
.moeda { --tam: 160px; --esp: 14px; position: relative; width: var(--tam); height: var(--tam); transform-style: preserve-3d; animation: girar 7s linear infinite; }
.moeda .camada, .moeda .face { position: absolute; inset: 0; border-radius: 50%; }
.moeda .camada { background: linear-gradient(90deg, #8a5a12, #d99a1e 50%, #8a5a12); }
.moeda .face {
  display: grid; place-items: center; backface-visibility: hidden;
  background: radial-gradient(circle at 32% 28%, #fff7cc 0%, #fde68a 18%, #fbbf24 48%, #d48a10 78%, #9a5d0b 100%);
  box-shadow: inset 0 0 0 calc(var(--tam) * .045) rgba(154, 93, 11, .55), inset 0 0 0 calc(var(--tam) * .075) #fcd34d, inset 0 0 calc(var(--tam) * .2) rgba(120, 60, 0, .45);
  color: #7a4a06; font-weight: 900; font-size: calc(var(--tam) * .5); text-shadow: 0 2px 0 #fff1b8, 0 -1px 0 rgba(90, 50, 0, .5);
}
.moeda .face.verso { font-size: calc(var(--tam) * .3); letter-spacing: -.04em; }
.moeda .frente { transform: translateZ(calc(var(--esp) / 2)); }
.moeda .verso { transform: rotateY(180deg) translateZ(calc(var(--esp) / 2)); }
.moeda.mini { --tam: 34px; --esp: 5px; animation-duration: 9s; }
.moeda.mini .face { font-size: 19px; text-shadow: none; }
.moeda.mini .face.verso { font-size: 12px; }
@keyframes girar { from { transform: rotateX(12deg) rotateY(0deg); } to { transform: rotateX(12deg) rotateY(360deg); } }

/* ===== cubo 3D ===== */
.cubo { --lado: 92px; width: var(--lado); height: var(--lado); position: relative; transform-style: preserve-3d; animation: rolar 16s linear infinite; }
.cubo > span {
  position: absolute; inset: 0; display: grid; place-items: center; font-weight: 800; font-size: calc(var(--lado) * .34); color: #e9ffff;
  background: linear-gradient(135deg, rgba(34, 211, 238, .28), rgba(139, 92, 246, .30)); border: 1px solid rgba(165, 243, 252, .55);
  border-radius: 10px; box-shadow: inset 0 0 22px rgba(34, 211, 238, .35); backdrop-filter: blur(2px);
}
.cubo > span:nth-child(1) { transform: translateZ(calc(var(--lado) / 2)); }
.cubo > span:nth-child(2) { transform: rotateY(180deg) translateZ(calc(var(--lado) / 2)); }
.cubo > span:nth-child(3) { transform: rotateY(90deg) translateZ(calc(var(--lado) / 2)); }
.cubo > span:nth-child(4) { transform: rotateY(-90deg) translateZ(calc(var(--lado) / 2)); }
.cubo > span:nth-child(5) { transform: rotateX(90deg) translateZ(calc(var(--lado) / 2)); }
.cubo > span:nth-child(6) { transform: rotateX(-90deg) translateZ(calc(var(--lado) / 2)); }
@keyframes rolar { from { transform: rotateX(-18deg) rotateY(0deg) rotateZ(6deg); } to { transform: rotateX(342deg) rotateY(360deg) rotateZ(6deg); } }

/* ===== cena 3D (início e entrada) ===== */
.cena { position: relative; height: 300px; perspective: 900px; transform-style: preserve-3d; }
.cena .camada-cena { position: absolute; inset: 0; transform-style: preserve-3d; transform: rotateX(var(--cx, 0deg)) rotateY(var(--cy, 0deg)); transition: transform .4s ease-out; }
.cena .piso {
  position: absolute; left: 50%; bottom: 18px; width: 360px; height: 360px; margin-left: -180px; border-radius: 50%;
  transform: rotateX(78deg); background: radial-gradient(circle, rgba(16, 227, 160, .45), rgba(16, 227, 160, .08) 45%, transparent 70%);
  box-shadow: 0 0 0 1px rgba(16, 227, 160, .25), 0 0 0 40px rgba(16, 227, 160, .04), 0 0 0 80px rgba(139, 92, 246, .03);
}
.cena .moeda { position: absolute; left: 50%; top: 44px; margin-left: calc(var(--tam) / -2); }
.cena .flutua { position: absolute; animation: flutuar 6s ease-in-out infinite; transform-style: preserve-3d; }
.cena .f1 { left: 6%; top: 34px; }
.cena .f2 { right: 4%; top: 120px; animation-delay: -2s; }
.cena .f3 { left: 14%; bottom: 40px; animation-delay: -4s; }
.cena .ficha {
  width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; font-weight: 900; font-size: 1.3rem; color: #3b2300;
  background: var(--gradiente-ouro); box-shadow: 0 6px 0 #9a5d0b, 0 14px 30px -6px rgba(251, 191, 36, .6); transform: rotateX(28deg);
}
.cena .grafico { display: flex; align-items: flex-end; gap: 6px; height: 70px; padding: 8px 10px; border-radius: 12px;
  background: rgba(255,255,255,.06); border: 1px solid var(--linha-forte); backdrop-filter: blur(6px); transform: rotateY(-18deg); }
.cena .grafico i { width: 10px; border-radius: 4px 4px 0 0; background: var(--gradiente); animation: crescer 3.2s ease-in-out infinite; }
.cena .grafico i:nth-child(1) { height: 30%; } .cena .grafico i:nth-child(2) { height: 48%; animation-delay: -.6s; }
.cena .grafico i:nth-child(3) { height: 40%; animation-delay: -1.2s; } .cena .grafico i:nth-child(4) { height: 70%; animation-delay: -1.8s; }
.cena .grafico i:nth-child(5) { height: 92%; animation-delay: -2.4s; }
.cena .particula { position: absolute; width: 6px; height: 6px; border-radius: 50%; background: var(--verde); box-shadow: 0 0 12px var(--verde); animation: subir 5s linear infinite; opacity: 0; }
.cena .p1 { left: 30%; bottom: 40px; } .cena .p2 { left: 62%; bottom: 30px; animation-delay: -1.6s; background: var(--ouro); box-shadow: 0 0 12px var(--ouro); }
.cena .p3 { left: 48%; bottom: 20px; animation-delay: -3.1s; background: var(--violeta); box-shadow: 0 0 12px var(--violeta); }
.cena .p4 { left: 75%; bottom: 60px; animation-delay: -4.2s; }
@keyframes flutuar { 0%, 100% { transform: translateY(0) translateZ(30px); } 50% { transform: translateY(-16px) translateZ(60px); } }
@keyframes crescer { 0%, 100% { transform: scaleY(.85); } 50% { transform: scaleY(1.08); } }
@keyframes subir { 0% { transform: translateY(0); opacity: 0; } 15% { opacity: 1; } 100% { transform: translateY(-220px); opacity: 0; } }

/* ===== herói da página inicial ===== */
.heroi { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 1.5rem; align-items: center; padding: 1.6rem 1.8rem; margin-bottom: 1.5rem; overflow: hidden; }
.heroi h1 { font-size: clamp(1.8rem, 3.6vw, 2.7rem); line-height: 1.08; margin-bottom: .7rem; }
.heroi .chamada { font-size: 1.06rem; color: #c8d0e6; max-width: 34rem; }
.heroi .cena { height: 280px; }
.etiqueta-brilho { display: inline-flex; gap: .4rem; align-items: center; font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--ouro-claro); background: rgba(251, 191, 36, .1); border: 1px solid rgba(251, 191, 36, .35); padding: .25rem .7rem; border-radius: 99px; margin-bottom: .9rem; }
@media (max-width: 820px) { .heroi { grid-template-columns: 1fr; padding: 1.3rem; } .heroi .cena { height: 230px; order: -1; } }

/* ===== curso ===== */
.modulo { padding: 0; overflow: hidden; }
.modulo-topo { padding: 1rem 1.25rem; display: flex; justify-content: space-between; gap: 1rem; align-items: center; border-bottom: 1px solid var(--linha); }
.modulo-topo h2 { display: flex; align-items: center; gap: .8rem; }
.selo-modulo {
  flex: none; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-weight: 900; font-size: 1.15rem; color: #04140f;
  background: var(--gradiente); box-shadow: 0 5px 0 rgba(0,0,0,.35), 0 10px 22px -8px rgba(16, 227, 160, .7); transform: perspective(200px) rotateX(14deg) rotateY(-14deg);
}
.pilha > .modulo:nth-child(5n+2) .selo-modulo { background: var(--gradiente-ouro); color: #3b2300; box-shadow: 0 5px 0 rgba(0,0,0,.35), 0 10px 22px -8px rgba(251, 191, 36, .7); }
.pilha > .modulo:nth-child(5n+3) .selo-modulo { background: linear-gradient(135deg, #a78bfa, #7c3aed); color: #fff; box-shadow: 0 5px 0 rgba(0,0,0,.35), 0 10px 22px -8px rgba(139, 92, 246, .7); }
.pilha > .modulo:nth-child(5n+4) .selo-modulo { background: linear-gradient(135deg, #67e8f9, #0891b2); box-shadow: 0 5px 0 rgba(0,0,0,.35), 0 10px 22px -8px rgba(34, 211, 238, .7); }
.pilha > .modulo:nth-child(5n+5) .selo-modulo { background: linear-gradient(135deg, #f9a8d4, #db2777); color: #fff; box-shadow: 0 5px 0 rgba(0,0,0,.35), 0 10px 22px -8px rgba(244, 114, 182, .7); }
.lista-aulas { list-style: none; margin: 0; padding: 0; }
.lista-aulas li { border-bottom: 1px solid var(--linha); }
.lista-aulas li:last-child { border-bottom: none; }
.lista-aulas a { display: flex; gap: .8rem; align-items: center; padding: .72rem 1.25rem; color: var(--texto); transition: background .2s, padding .2s; }
.lista-aulas a:hover { background: rgba(16, 227, 160, .06); padding-left: 1.5rem; color: var(--texto); }
.marca-aula { width: 24px; height: 24px; flex: none; border-radius: 50%; border: 2px solid var(--linha-forte); display: grid; place-items: center; font-size: .75rem; font-weight: 800; }
.marca-aula.feita { background: var(--gradiente-ouro); border-color: transparent; color: #3b2300; box-shadow: 0 0 12px rgba(251, 191, 36, .55); }
.etiqueta { font-size: .74rem; padding: .14rem .55rem; border-radius: 99px; background: rgba(255,255,255,.06); border: 1px solid var(--linha); color: var(--suave); white-space: nowrap; }

/* ===== aula ===== */
.aula-grade { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 1.25rem; align-items: start; }
@media (max-width: 900px) { .aula-grade { grid-template-columns: 1fr; } }
.video { position: relative; aspect-ratio: 16 / 9; background: #000; border-radius: var(--raio); overflow: hidden; box-shadow: var(--sombra), 0 0 0 1px var(--linha-forte); }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.leitor { width: 100%; height: 78vh; min-height: 480px; border: 1px solid var(--linha-forte); border-radius: var(--raio); background: #fff; box-shadow: var(--sombra); }
@media (max-width: 640px) { .leitor { height: 70vh; min-height: 360px; } }
.video-fora { background: linear-gradient(135deg, rgba(16, 227, 160, .12), rgba(139, 92, 246, .14)); border: 1px solid var(--linha-forte); border-radius: var(--raio); padding: 1.6rem; text-align: center; }
#estudo { position: sticky; top: 76px; }
@media (max-width: 900px) { #estudo { position: relative; top: 0; } }
.abas { display: flex; flex-wrap: wrap; gap: .25rem; margin: -.2rem 0 1rem; padding: .25rem; background: rgba(0,0,0,.25); border-radius: 12px; border: 1px solid var(--linha); }
.abas button { flex: 1; justify-content: center; border: none; border-radius: 9px; background: none; padding: .45rem .55rem; color: var(--suave); white-space: nowrap; font-size: .9rem; box-shadow: none; }
.abas button:hover { background: rgba(255,255,255,.05); }
.abas button.ativa { background: rgba(16, 227, 160, .16); color: var(--marca-forte); }
.painel[hidden] { display: none; }
.notas { min-height: 340px; line-height: 1.65; }
.salvo { font-size: .8rem; color: var(--suave); margin-top: .3rem; }
.materiais { list-style: none; padding: 0; margin: 0; }
.materiais li { padding: .5rem 0; border-bottom: 1px dashed var(--linha); }
.materiais li:last-child { border-bottom: none; }
.mini-card { border: 1px solid var(--linha); background: rgba(255,255,255,.03); border-radius: 11px; padding: .65rem .8rem; margin-bottom: .5rem; font-size: .92rem; }
.mini-card b { display: block; }
details summary { cursor: pointer; font-weight: 650; color: var(--marca); }
details[open] summary { margin-bottom: .8rem; }

/* ===== revisão (cartão que vira em 3D) ===== */
.flash { min-height: 280px; display: flex; flex-direction: column; justify-content: center; text-align: center; padding: 2.2rem 1.6rem; }
.flash .pergunta { font-size: 1.35rem; font-weight: 650; white-space: pre-wrap; }
.flash .resposta { font-size: 1.12rem; white-space: pre-wrap; border-top: 1px solid var(--linha); margin-top: 1.25rem; padding-top: 1.25rem; color: var(--ouro-claro); animation: virar .5s ease; }
@keyframes virar { from { transform: perspective(700px) rotateX(-70deg); opacity: 0; } to { transform: perspective(700px) rotateX(0); opacity: 1; } }
.respostas { display: grid; grid-template-columns: repeat(3, 1fr); gap: .7rem; margin-top: 1rem; }
.respostas button { justify-content: center; flex-direction: column; gap: 0; padding: .8rem; }
.respostas small { font-weight: 400; color: var(--suave); }
.respostas .r-errei { border-color: rgba(251, 113, 133, .5); color: var(--perigo); }
.respostas .r-lembrei { border-color: rgba(52, 211, 153, .55); color: var(--ok); }

/* ===== plano ===== */
.quadro { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
@media (max-width: 800px) { .quadro { grid-template-columns: 1fr; } }
.coluna { background: rgba(0,0,0,.22); border: 1px solid var(--linha); border-radius: var(--raio); padding: .8rem; min-height: 120px; }
.coluna h3 { display: flex; justify-content: space-between; font-size: .95rem; padding: 0 .25rem; }
.coluna:nth-child(1) h3 span:first-child { color: #cbd5e1; }
.coluna:nth-child(2) h3 span:first-child { color: var(--ciano); }
.coluna:nth-child(3) h3 span:first-child { color: var(--ouro); }
.item { background: var(--cartao-solido); border: 1px solid var(--linha); border-radius: 12px; padding: .75rem .85rem; margin-top: .6rem; transition: border-color .2s, transform .2s; }
.item:hover { border-color: var(--linha-forte); transform: translateY(-2px); }
.item .acoes { display: flex; gap: .75rem; margin-top: .5rem; font-size: .82rem; flex-wrap: wrap; }
.item form { display: inline; }
.form-plano { display: grid; gap: .75rem; grid-template-columns: minmax(140px, .7fr) minmax(200px, 2fr) minmax(140px, .8fr) auto; align-items: end; }
.form-plano .largo { grid-column: 1 / -1; }
@media (max-width: 700px) { .form-plano { grid-template-columns: 1fr; } }
.atrasado { color: var(--perigo); font-weight: 650; }

/* ===== tabela ===== */
.tabela { width: 100%; border-collapse: collapse; font-size: .93rem; }
.tabela th, .tabela td { text-align: left; padding: .6rem .5rem; border-bottom: 1px solid var(--linha); vertical-align: top; }
.tabela th { font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; color: var(--suave); }
.rolar { overflow-x: auto; }

/* ===== entrada (login) ===== */
.entrada { min-height: calc(100vh - 3.5rem); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 440px); gap: 2rem; align-items: center; max-width: 1040px; margin: 0 auto; }
.entrada .apresentacao h1 { font-size: clamp(2.2rem, 5vw, 3.4rem); line-height: 1.02; margin: .4rem 0 .8rem; }
.entrada .apresentacao p { color: #c8d0e6; font-size: 1.08rem; max-width: 30rem; }
.entrada .cartao { width: 100%; padding: 2rem; }
.entrada .cena { height: 260px; }
@media (max-width: 860px) {
  .entrada { grid-template-columns: 1fr; gap: 1rem; min-height: auto; padding-top: .5rem; }
  .entrada .cena { height: 200px; }
  .entrada .apresentacao { text-align: center; }
  .entrada .apresentacao p { margin-inline: auto; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  [data-inclinar] { transform: none !important; }
}

/* espessura da moeda: 9 discos empilhados */
.moeda .camada:nth-child(1) { transform: translateZ(calc(var(--esp) * (0 / 8 - .5))); }
.moeda .camada:nth-child(2) { transform: translateZ(calc(var(--esp) * (1 / 8 - .5))); }
.moeda .camada:nth-child(3) { transform: translateZ(calc(var(--esp) * (2 / 8 - .5))); }
.moeda .camada:nth-child(4) { transform: translateZ(calc(var(--esp) * (3 / 8 - .5))); }
.moeda .camada:nth-child(5) { transform: translateZ(calc(var(--esp) * (4 / 8 - .5))); }
.moeda .camada:nth-child(6) { transform: translateZ(calc(var(--esp) * (5 / 8 - .5))); }
.moeda .camada:nth-child(7) { transform: translateZ(calc(var(--esp) * (6 / 8 - .5))); }
.moeda .camada:nth-child(8) { transform: translateZ(calc(var(--esp) * (7 / 8 - .5))); }
.moeda .camada:nth-child(9) { transform: translateZ(calc(var(--esp) * (8 / 8 - .5))); }

/* cena menor em telas estreitas */
@media (max-width: 820px) {
  .cena .moeda:not(.mini) { --tam: 124px; --esp: 11px; top: 40px; }
  .cena .cubo { --lado: 60px; }
  .cena .f1 { left: 3%; top: 14px; }
  .cena .f2 { right: 2%; top: 96px; }
  .cena .f3 { left: 10%; bottom: 24px; }
  .cena .ficha { width: 44px; height: 44px; font-size: 1.05rem; }
  .cena .grafico { height: 54px; }
}

/* ===== celular e toque ===== */
.menu-celular, .apostila-celular, .so-celular { display: none; }
.apostila-celular { align-items: center; gap: .9rem; padding: 1rem 1.1rem; border-color: rgba(16, 227, 160, .4); }
.apostila-celular .icone-pdf {
  flex: none; width: 48px; height: 58px; border-radius: 8px; display: grid; place-items: center; font-weight: 900; font-size: .8rem; color: #fff;
  background: linear-gradient(160deg, #fb7185, #e11d48); box-shadow: 0 5px 0 #9f1239, 0 10px 20px -6px rgba(225, 29, 72, .6); transform: perspective(200px) rotateY(-12deg);
}
.apostila-celular .seta { margin-left: auto; font-size: 1.4rem; color: var(--verde); }

/* telas de toque: o celular não mostra PDF dentro da página, então vira um botão */
@media (hover: none) and (pointer: coarse) {
  .leitor, .so-computador { display: none !important; }
  .apostila-celular { display: flex; }
  .so-celular { display: block; }
  .botao, button { min-height: 44px; }
  .pequeno-botao { min-height: 38px; padding: .4rem .8rem; }
  .link, button.link { min-height: 0; }
  .item .acoes { gap: 1.1rem; font-size: .9rem; }
  .item .acoes button.link { padding: .35rem 0; }
  .lista-aulas a { padding-top: .9rem; padding-bottom: .9rem; }
  details summary { padding: .4rem 0; }
  [data-inclinar] { transform: none; }
}

@media (max-width: 640px) {
  /* menu de baixo, estilo aplicativo */
  .topo .menu { display: none; }
  .topo-dentro { padding-top: .55rem; padding-bottom: .55rem; }
  .menu-celular {
    display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
    padding: .35rem .5rem calc(.35rem + env(safe-area-inset-bottom)); background: rgba(6, 9, 20, .9);
    backdrop-filter: blur(16px) saturate(150%); border-top: 1px solid var(--linha);
  }
  .menu-celular a { position: relative; display: flex; flex-direction: column; align-items: center; gap: .15rem; padding: .4rem 0 .3rem;
    border-radius: 12px; color: var(--suave); font-size: .72rem; font-weight: 650; }
  .menu-celular svg { width: 23px; height: 23px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
  .menu-celular a.ativo { color: var(--verde); background: rgba(16, 227, 160, .1); }
  .menu-celular a.ativo svg { filter: drop-shadow(0 0 6px rgba(16, 227, 160, .7)); }
  .menu-celular .selo { position: absolute; top: 0; left: 55%; margin: 0; font-size: .66rem; min-width: 1.15rem; line-height: 1.15rem; }
  main { padding: 1.1rem 14px calc(5.5rem + env(safe-area-inset-bottom)); }
  h1 { font-size: 1.45rem; }
  .cartao { padding: 1rem; border-radius: 14px; }
  .cabecalho { margin-bottom: 1rem; }
  .cabecalho .linha { width: 100%; }
  .cabecalho .linha .botao { flex: 1; justify-content: center; }
  .numero { font-size: 2rem; }
  .grade-3 { grid-template-columns: 1fr 1fr; }
  .grade-3 > :first-child:nth-last-child(odd) { grid-column: 1 / -1; }
  .heroi { padding: 1.1rem; gap: .5rem; }
  .heroi .linha .botao { width: 100%; justify-content: center; }
  .modulo-topo { padding: .85rem 1rem; }
  .modulo-topo h2 { font-size: 1.02rem; gap: .6rem; }
  .selo-modulo { width: 38px; height: 38px; font-size: 1rem; }
  .lista-aulas a { padding-left: 1rem; padding-right: 1rem; }
  .respostas { gap: .45rem; }
  .respostas button { padding: .65rem .3rem; font-size: .95rem; }
  .flash { padding: 1.6rem 1rem; min-height: 230px; }
  .flash .pergunta { font-size: 1.18rem; }
  .notas { min-height: 260px; }
  .abas button { font-size: .85rem; padding: .5rem .3rem; }
  .entrada .cartao { padding: 1.4rem; }
  .entrada .apresentacao h1 { font-size: 2rem; }
  .avisos li { font-size: .92rem; }
}
@media (max-width: 360px) {
  .grade-3 { grid-template-columns: 1fr; }
  .menu-celular a { font-size: .66rem; }
}
@media (max-width: 700px) { .form-plano .largo { order: 4; } .form-plano > button { order: 5; justify-content: center; } }

/* ===== entrar: criar conta pelo WhatsApp ===== */
.divisor { display: flex; align-items: center; gap: .7rem; margin: 1.2rem 0 .9rem; color: var(--suave); font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; }
.divisor::before, .divisor::after { content: ""; flex: 1; height: 1px; background: var(--linha-forte); }
.botao-whatsapp { width: 100%; justify-content: center; min-height: 46px; color: #dcffe9; border-color: rgba(37, 211, 102, .55); background: rgba(37, 211, 102, .1); }
.botao-whatsapp:hover { color: #fff; background: #1faa53; border-color: #25d366; box-shadow: 0 10px 26px -10px rgba(37, 211, 102, .8); }
.botao-whatsapp svg { width: 20px; height: 20px; fill: #25d366; }
.botao-whatsapp:hover svg { fill: #fff; }
