/* ==========================================================
   CODERLUN STUDIO
   Sora (voz da marca) · Instrument Serif (o toque humano) · JetBrains Mono (a máquina)
   ========================================================== */
:root {
  --void: #05040b;
  --ink: #f3f1ff;
  --muted: #a39fbf;
  --faint: #6f6b8e;
  --line: rgba(255, 255, 255, .09);
  --line-2: rgba(255, 255, 255, .16);
  --violet: #7c5cff;
  --cyan: #4fd8e8;
  --glass: rgba(13, 11, 28, .58);
  --glass-2: rgba(20, 17, 42, .72);
  --grad: linear-gradient(100deg, var(--violet), var(--cyan));
  --sans: 'Sora', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --serif: 'Instrument Serif', 'Times New Roman', serif;
  --mono: 'JetBrains Mono', ui-monospace, Consolas, monospace;
  --pad: clamp(16px, 4.4vw, 64px);
  --ease: cubic-bezier(.16, 1, .3, 1);
  --radius: 22px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; overflow-x: clip; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }
body {
  margin: 0; background: var(--void); color: var(--ink);
  font: 400 16px/1.6 var(--sans); -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
body.is-locked { overflow: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
::selection { background: var(--violet); color: #fff; }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; border-radius: 8px; }
.mono { font-family: var(--mono); font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; }
.serif, em.serif { font-family: var(--serif); font-style: italic; font-weight: 400; letter-spacing: -.01em; }
.skip { position: fixed; left: -9999px; top: 8px; z-index: 999; background: var(--ink); color: var(--void); padding: 10px 16px; border-radius: 10px; }
.skip:focus { left: 8px; }

/* ---------- camadas de fundo ---------- */
#cosmos { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 0; display: block; }
.no-gl body { background:
  radial-gradient(circle at 72% 50%, #05040b 0 18vmin, rgba(79,216,232,.55) 18.4vmin, rgba(124,92,255,.25) 24vmin, transparent 40vmin), var(--void); }
.grain { position: fixed; inset: -50%; z-index: 1; pointer-events: none; opacity: .07; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1.2s steps(6) infinite; }
@keyframes grain { 0%{transform:translate(0,0)} 20%{transform:translate(-3%,2%)} 40%{transform:translate(2%,-3%)} 60%{transform:translate(-2%,-1%)} 80%{transform:translate(3%,3%)} 100%{transform:translate(0,0)} }
.vignette { position: fixed; inset: 0; z-index: 1; pointer-events: none;
  background: radial-gradient(120% 90% at 50% 50%, transparent 55%, rgba(0,0,0,.55) 100%); }
main, .foot { position: relative; z-index: 2; }

/* ---------- botões ---------- */
.btn { --h: 54px; position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  height: var(--h); padding: 0 26px; border-radius: 999px; font-weight: 500; font-size: 15px; letter-spacing: -.01em;
  white-space: nowrap; transition: transform .5s var(--ease), background .3s, border-color .3s, color .3s, box-shadow .4s; isolation: isolate; }
.btn--sm { --h: 42px; padding: 0 18px; font-size: 14px; }
.btn--glow { color: #fff; background: #0c0a1c; box-shadow: 0 0 0 1px rgba(255,255,255,.14) inset, 0 10px 40px -12px rgba(124,92,255,.8); overflow: hidden; }
.btn--glow::before { content: ""; position: absolute; inset: -2px; z-index: -2; border-radius: inherit;
  background: conic-gradient(from var(--a, 0deg), var(--violet), var(--cyan), #fff, var(--violet)); animation: spin 4s linear infinite; }
.btn--glow::after { content: ""; position: absolute; inset: 1.5px; z-index: -1; border-radius: inherit; background: linear-gradient(180deg, #16123a, #0a0818); }
.btn--glow:hover { box-shadow: 0 0 0 1px rgba(255,255,255,.2) inset, 0 16px 60px -10px rgba(79,216,232,.7); }
@property --a { syntax: '<angle>'; initial-value: 0deg; inherits: false; }
@keyframes spin { to { --a: 360deg; } }
.btn__arrow { transition: transform .5s var(--ease); }
.btn:hover .btn__arrow { transform: translateX(5px); }
.btn--ghost { border: 1px solid var(--line-2); background: rgba(255,255,255,.03); backdrop-filter: blur(10px); color: var(--ink); }
.btn--ghost:hover { border-color: rgba(255,255,255,.4); background: rgba(255,255,255,.07); }
.btn--light { background: var(--ink); color: var(--void); }
.btn--light:hover { background: #fff; box-shadow: 0 10px 40px -10px rgba(255,255,255,.5); }
.btn[disabled] { opacity: .35; pointer-events: none; }
.btn__wave { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.btn__wave path { animation: wave 1.1s ease-in-out infinite alternate; transform-origin: center; }

/* ---------- PORTAL ---------- */
.gate { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 24px var(--pad); }
.gate__center { position: relative; text-align: center; max-width: 720px; display: grid; justify-items: center; gap: 22px; }
.gate__kicker { display: inline-flex; align-items: center; gap: 10px; color: var(--cyan); margin: 0; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 12px var(--cyan); animation: blink 1.6s ease-in-out infinite; }
@keyframes blink { 50% { opacity: .25; } }
.gate__title { margin: 0; font-weight: 700; font-size: clamp(46px, 10vw, 128px); line-height: .9; letter-spacing: -.055em; }
.gate__title em { font-family: var(--serif); font-weight: 400; font-style: italic; letter-spacing: -.02em;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; padding-right: .08em; }
.gate__lede { margin: 0; color: var(--muted); font-size: clamp(15px, 1.6vw, 18px); max-width: 420px; }
.gate__actions { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 6px; }
.gate__load { display: flex; align-items: center; gap: 14px; color: var(--faint); margin-top: 10px; }
.gate__load i { width: 120px; height: 1px; background: var(--line-2); position: relative; overflow: hidden; }
.gate__load b { position: absolute; inset: 0 auto 0 0; width: 0; background: var(--grad); }
.gate__hud { position: absolute; display: grid; gap: 4px; color: var(--faint); }
.gate__hud--tl { top: 22px; left: var(--pad); } .gate__hud--tr { top: 22px; right: var(--pad); text-align: right; }
.gate__hud--bl { bottom: 22px; left: var(--pad); } .gate__hud--br { bottom: 22px; right: var(--pad); text-align: right; }

/* ---------- NAV ---------- */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 50; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 16px var(--pad); transition: transform .6s var(--ease), background .4s, backdrop-filter .4s; }
.nav.is-scrolled { background: linear-gradient(180deg, rgba(5,4,11,.75), rgba(5,4,11,0)); backdrop-filter: blur(6px); }
.nav.is-hidden { transform: translateY(-110%); }
.nav__brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; letter-spacing: -.02em; font-size: 16px; }
.nav__brand b { font-weight: 300; color: var(--muted); margin-left: 2px; }
.nav__links { display: flex; gap: 4px; padding: 5px; border-radius: 999px; border: 1px solid var(--line); background: rgba(10,9,22,.45); backdrop-filter: blur(14px); }
.nav__links a { padding: 8px 14px; border-radius: 999px; font-size: 13.5px; color: var(--muted); transition: color .3s, background .3s; }
.nav__links a:hover, .nav__links a.is-active { color: var(--ink); background: rgba(255,255,255,.07); }
.nav__right { display: flex; align-items: center; gap: 10px; }

.voice-toggle { display: inline-flex; align-items: center; gap: 9px; height: 42px; padding: 0 14px; border-radius: 999px;
  border: 1px solid var(--line-2); background: rgba(10,9,22,.45); backdrop-filter: blur(14px); color: var(--muted); transition: color .3s, border-color .3s; }
.voice-toggle:hover { color: var(--ink); border-color: rgba(255,255,255,.35); }
.voice-toggle__bars { display: flex; align-items: center; gap: 2px; height: 14px; }
.voice-toggle__bars i { width: 2px; height: calc(3px + var(--l, 0) * 11px); border-radius: 2px; background: var(--cyan); transition: height .08s; }
.voice-toggle[aria-pressed="false"] .voice-toggle__bars i { background: var(--faint); height: 2px; }
.voice-toggle[aria-pressed="false"] .voice-toggle__txt { text-decoration: line-through; }

/* ---------- LEGENDA ---------- */
.caption { position: fixed; left: 50%; bottom: max(22px, env(safe-area-inset-bottom)); z-index: 60; width: min(760px, calc(100vw - 32px));
  transform: translate(-50%, 20px); opacity: 0; pointer-events: none; transition: opacity .5s var(--ease), transform .7s var(--ease);
  display: flex; gap: 16px; align-items: flex-start; padding: 16px 20px; border-radius: 18px;
  background: rgba(8,7,18,.7); border: 1px solid var(--line); backdrop-filter: blur(18px) saturate(1.3); box-shadow: 0 20px 60px -20px rgba(0,0,0,.8); }
.caption.is-on { opacity: 1; transform: translate(-50%, 0); }
.caption__who { color: var(--cyan); white-space: nowrap; padding-top: 4px; }
.caption__text { margin: 0; font-size: clamp(15px, 1.5vw, 18px); line-height: 1.45; letter-spacing: -.01em; }
.caption__text span { color: rgba(243,241,255,.22); transition: color .25s, text-shadow .25s; }
.caption__text span.is-said { color: var(--ink); }
.caption__text span.is-now { color: #fff; text-shadow: 0 0 18px rgba(79,216,232,.9); }

/* ---------- CURSOR ---------- */
.cursor { position: fixed; left: 0; top: 0; z-index: 200; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%;
  pointer-events: none; border: 1px solid rgba(255,255,255,.7); opacity: 0; display: grid; place-items: center;
  transition: width .4s var(--ease), height .4s var(--ease), margin .4s var(--ease), background .3s, border-color .3s; }
.cursor.has-label { width: 84px; height: 84px; margin: -42px 0 0 -42px; background: rgba(243,241,255,.95); border-color: transparent; }
.cursor__label { font: 600 12px/1 var(--sans); color: var(--void); opacity: 0; transition: opacity .2s; }
.cursor.has-label .cursor__label { opacity: 1; }
.cursor.is-down { transform: scale(.8); }
@media (hover: none), (pointer: coarse) { .cursor { display: none; } }

.progress { position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 70; pointer-events: none; }
.progress i { display: block; height: 100%; width: 100%; transform-origin: 0 50%; transform: scaleX(0); background: var(--grad); box-shadow: 0 0 12px var(--cyan); }

/* ---------- BASE DE SEÇÃO ---------- */
section { position: relative; padding: clamp(90px, 14vw, 180px) var(--pad); }
.label { color: var(--cyan); margin: 0 0 22px; }
.h2 { margin: 0; font-weight: 600; font-size: clamp(38px, 6.4vw, 92px); line-height: .98; letter-spacing: -.05em; }
.h2 em { color: transparent; background: var(--grad); -webkit-background-clip: text; background-clip: text; padding-right: .06em; }
.section-head { max-width: 1100px; margin-bottom: clamp(48px, 7vw, 90px); }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head--center .section-head__lede { margin-inline: auto; }
.section-head__lede { color: var(--muted); font-size: clamp(16px, 1.5vw, 19px); max-width: 560px; margin: 26px 0 0; }
.split-line { padding-bottom: .06em; }

/* ---------- HERO ---------- */
.hero { min-height: 100svh; display: flex; align-items: center; padding-top: 120px; padding-bottom: 120px; }
.hero__inner { position: relative; z-index: 2; max-width: min(760px, 58vw); }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; color: var(--muted); margin: 0 0 28px;
  padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: rgba(10,9,22,.4); backdrop-filter: blur(10px); }
.pulse { width: 7px; height: 7px; border-radius: 50%; background: #3dffa0; box-shadow: 0 0 0 0 rgba(61,255,160,.6); animation: pulse 2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(61,255,160,0); } 100% { box-shadow: 0 0 0 0 rgba(61,255,160,0); } }
.hero__title { margin: 0; font-weight: 700; font-size: clamp(50px, 8.6vw, 148px); line-height: .9; letter-spacing: -.06em; }
.hero__title .split-line { padding-bottom: .1em; margin-bottom: -.1em; }
body.is-locked main { visibility: hidden; }
.hero__title em { font-weight: 400; font-size: 1.08em; letter-spacing: -.03em; color: transparent;
  background: linear-gradient(100deg, #fff 0%, var(--cyan) 40%, var(--violet) 100%); -webkit-background-clip: text; background-clip: text; padding-right: .1em; }
.hero__lede { margin: 34px 0 0; max-width: 520px; color: var(--muted); font-size: clamp(16px, 1.45vw, 19px); }
.hero__cta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 40px; }
.hero__eclipse { position: absolute; z-index: 1; left: 72%; top: 50%; width: min(46vw, 46vh); aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%; }
.hero__hud { position: absolute; left: var(--pad); bottom: 36px; display: flex; gap: 22px; color: var(--faint); }
.hero__scroll { position: absolute; right: var(--pad); bottom: 36px; display: flex; align-items: center; gap: 12px; color: var(--faint); }
.hero__scroll i { width: 1px; height: 38px; background: linear-gradient(var(--cyan), transparent); animation: drop 2s var(--ease) infinite; transform-origin: top; }
@keyframes drop { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); transform-origin: top; } 51% { transform-origin: bottom; } 100% { transform: scaleY(0); transform-origin: bottom; } }

/* ---------- TICKER ---------- */
.ticker { position: relative; z-index: 2; overflow: hidden; padding: 26px 0; border-block: 1px solid var(--line);
  background: rgba(5,4,11,.5); backdrop-filter: blur(8px); transform: rotate(-1.4deg) scale(1.02); }
.ticker__row { display: flex; gap: 38px; width: max-content; align-items: center; font-size: clamp(26px, 3.8vw, 52px); font-weight: 600; letter-spacing: -.04em; will-change: transform; }
.ticker__row span:nth-child(4n+1) { font-family: var(--serif); font-style: italic; font-weight: 400; }
.ticker__row b { font-size: .6em; color: var(--cyan); font-weight: 400; }

/* ---------- MANIFESTO ---------- */
.manifesto__text { max-width: 1250px; margin: 0; font-size: clamp(30px, 4.6vw, 70px); line-height: 1.08; letter-spacing: -.045em; font-weight: 500; }
.manifesto__text em { font-family: var(--serif); font-weight: 400; color: var(--cyan); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; margin-top: clamp(60px, 9vw, 120px); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--line); }
.stat { padding: 30px 26px; background: rgba(8,7,18,.72); backdrop-filter: blur(12px); display: grid; gap: 10px; }
.stat b { font-size: clamp(48px, 6vw, 88px); line-height: 1; font-weight: 600; letter-spacing: -.06em; background: linear-gradient(180deg, #fff, rgba(255,255,255,.45)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat span { color: var(--muted); font-size: 14px; max-width: 200px; }

/* ---------- SERVIÇOS (bento) ---------- */
.bento { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: minmax(280px, auto); gap: 16px; }
.card { --mx: 50%; --my: 50%; position: relative; padding: 28px; border-radius: var(--radius); overflow: hidden;
  background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(16px); display: flex; flex-direction: column; justify-content: flex-end;
  transition: border-color .4s, transform .6s var(--ease); transform-style: preserve-3d; }
.card::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .4s;
  background: radial-gradient(400px circle at var(--mx) var(--my), rgba(124,92,255,.22), transparent 45%); }
.card::after { content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none; opacity: 0; transition: opacity .4s;
  background: radial-gradient(300px circle at var(--mx) var(--my), rgba(79,216,232,.9), transparent 50%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; }
.card:hover::before, .card:hover::after { opacity: 1; }
.card--xl { grid-row: span 2; }
.card--wide { grid-column: span 2; }
.card h3 { margin: 0 0 10px; font-size: clamp(22px, 2.2vw, 30px); font-weight: 600; letter-spacing: -.035em; line-height: 1.1; }
.card p { margin: 0; color: var(--muted); font-size: 15px; max-width: 440px; }
.card__n { color: var(--faint); margin-bottom: auto !important; position: absolute; top: 26px; left: 28px; }
.card__ex { margin-top: 18px !important; color: var(--cyan) !important; font-size: 10.5px !important; }
.card__viz { position: absolute; top: 26px; right: 26px; pointer-events: none; }
/* mini-ilustrações em CSS */
.viz-phone { width: 120px; height: 230px; border-radius: 26px; border: 1px solid var(--line-2); background: linear-gradient(160deg, rgba(124,92,255,.25), rgba(79,216,232,.08)); right: 34px; top: 34px; padding: 18px 12px; display: grid; align-content: start; gap: 9px; }
.viz-phone i { height: 34px; border-radius: 10px; background: rgba(255,255,255,.08); animation: float 4s ease-in-out infinite; }
.viz-phone i:nth-child(2) { animation-delay: -1.3s; width: 80%; } .viz-phone i:nth-child(3) { animation-delay: -2.6s; width: 60%; }
.viz-phone span { position: absolute; bottom: 14px; left: 50%; width: 40px; height: 4px; border-radius: 4px; background: rgba(255,255,255,.3); transform: translateX(-50%); }
.card--xl .viz-phone { width: 150px; height: 300px; }
@keyframes float { 50% { transform: translateY(-5px); } }
.viz-window { width: 120px; height: 82px; border-radius: 12px; border: 1px solid var(--line-2); background: rgba(255,255,255,.04); overflow: hidden; }
.viz-window i { display: block; height: 16px; border-bottom: 1px solid var(--line); background: radial-gradient(circle at 10px 8px, #ff5f57 3px, transparent 3.5px), radial-gradient(circle at 20px 8px, #febc2e 3px, transparent 3.5px), radial-gradient(circle at 30px 8px, #28c840 3px, transparent 3.5px); }
.viz-window span { display: block; margin: 10px; height: 4px; width: 60%; background: var(--cyan); border-radius: 2px; box-shadow: 0 10px 0 rgba(255,255,255,.18), 0 20px 0 rgba(255,255,255,.12), 0 30px 0 rgba(124,92,255,.5); animation: type 3s steps(6) infinite; }
@keyframes type { 0% { width: 10%; } 100% { width: 70%; } }
.viz-cart { display: flex; gap: 8px; align-items: flex-end; height: 70px; }
.viz-cart i { width: 26px; border-radius: 8px; background: linear-gradient(var(--violet), transparent); animation: bars 2.4s ease-in-out infinite; }
.viz-cart i:nth-child(1) { height: 40%; } .viz-cart i:nth-child(2) { height: 80%; animation-delay: -.8s; } .viz-cart i:nth-child(3) { height: 60%; animation-delay: -1.6s; background: linear-gradient(var(--cyan), transparent); }
@keyframes bars { 50% { transform: scaleY(.6); } }
.viz-cart i { transform-origin: bottom; }
.viz-graph { width: 46%; height: 90px; }
.viz-graph svg { width: 100%; height: 100%; overflow: visible; }
.viz-graph path { fill: none; stroke: url(#none); stroke: var(--cyan); stroke-width: 2; stroke-dasharray: 400; stroke-dashoffset: 400; filter: drop-shadow(0 0 6px var(--cyan)); animation: drawp 4s var(--ease) infinite; }
@keyframes drawp { 60%, 100% { stroke-dashoffset: 0; } }
.viz-grid { display: grid; grid-template-columns: repeat(3, 22px); gap: 6px; }
.viz-grid i { height: 22px; border-radius: 6px; border: 1px solid var(--line-2); animation: lit 3s infinite; }
.viz-grid i:nth-child(2) { animation-delay: .5s; } .viz-grid i:nth-child(3) { animation-delay: 1s; } .viz-grid i:nth-child(4) { animation-delay: 1.5s; } .viz-grid i:nth-child(5) { animation-delay: 2s; } .viz-grid i:nth-child(6) { animation-delay: 2.5s; }
@keyframes lit { 0%, 30%, 100% { background: transparent; } 10% { background: rgba(124,92,255,.6); } }
.viz-brand span { display: block; width: 74px; height: 74px; border-radius: 50%; background: conic-gradient(from 0deg, var(--violet), var(--cyan), #fff, var(--violet)); animation: spinr 8s linear infinite; -webkit-mask: radial-gradient(circle, transparent 26px, #000 27px); mask: radial-gradient(circle, transparent 26px, #000 27px); }
@keyframes spinr { to { transform: rotate(360deg); } }

/* ---------- OBRAS ---------- */
.works { padding: 0; }
.works__pin { height: 100vh; display: flex; flex-direction: column; justify-content: center; overflow: hidden; padding: 100px 0 40px; }
.works__head { display: flex; align-items: flex-end; justify-content: flex-start; column-gap: 32px; gap: 20px; padding: 0 var(--pad); margin-bottom: clamp(26px, 4vh, 48px); flex-wrap: wrap; }
.works__head .label { width: 100%; margin-bottom: 0; }
.works__count { color: var(--muted); font-size: 14px; padding-bottom: .9em; }
.works__count span:first-child { color: var(--ink); }
.works__track { display: flex; gap: clamp(16px, 2.2vw, 32px); padding: 0 var(--pad); width: max-content; will-change: transform; }
.work { position: relative; flex: 0 0 auto; width: clamp(300px, 46vw, 760px); cursor: pointer; }
.work__media { position: relative; aspect-ratio: 16 / 10; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: #0c0a1a; }
.work__media img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.12); transition: transform 1.2s var(--ease), filter .6s; filter: saturate(.9) brightness(.92); }
.work:hover .work__media img { filter: saturate(1.05) brightness(1); }
.work__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 50%, rgba(5,4,11,.75)); }
.work__tag { position: absolute; z-index: 2; top: 16px; left: 16px; padding: 7px 12px; border-radius: 999px; background: rgba(5,4,11,.6); backdrop-filter: blur(10px); border: 1px solid var(--line); color: var(--ink); }
.work__open { position: absolute; z-index: 2; right: 16px; bottom: 16px; width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: var(--ink); color: var(--void); font-size: 20px; transform: scale(.7); opacity: 0; transition: transform .5s var(--ease), opacity .4s; }
.work:hover .work__open, .work:focus-visible .work__open { transform: scale(1); opacity: 1; }
.work__info { display: grid; grid-template-columns: auto 1fr; gap: 6px 18px; margin-top: 20px; align-items: baseline; }
.work__n { color: var(--faint); grid-row: span 2; }
.work__name { margin: 0; font-size: clamp(24px, 2.6vw, 38px); font-weight: 600; letter-spacing: -.04em; line-height: 1; }
.work__lede { margin: 0; color: var(--muted); font-family: var(--serif); font-style: italic; font-size: clamp(17px, 1.5vw, 21px); }
.works__bar { margin: clamp(26px, 4vh, 44px) var(--pad) 0; height: 1px; background: var(--line); }
.works__bar i { display: block; height: 100%; width: 100%; transform: scaleX(0); transform-origin: left; background: var(--grad); }

/* ---------- MÉTODO ---------- */
.method { display: grid; grid-template-columns: 1fr; }
.steps { list-style: none; margin: 0; padding: 0 0 0 clamp(36px, 6vw, 90px); display: grid; gap: clamp(40px, 7vw, 90px); position: relative; max-width: 960px; margin-left: auto; margin-right: 6vw; }
.step { position: relative; opacity: .28; transition: opacity .6s var(--ease); }
.step.is-on { opacity: 1; }
.step__orb { position: absolute; left: calc(-1 * clamp(36px, 6vw, 90px) - 7px); top: 6px; width: 15px; height: 15px; border-radius: 50%; border: 1px solid var(--line-2); background: var(--void); transition: background .5s, box-shadow .5s, border-color .5s; }
.step.is-on .step__orb { background: var(--cyan); border-color: var(--cyan); box-shadow: 0 0 0 6px rgba(79,216,232,.12), 0 0 24px var(--cyan); }
.step__n { color: var(--cyan); margin: 0 0 12px; }
.step h3 { margin: 0 0 12px; font-size: clamp(34px, 4.6vw, 64px); font-weight: 600; letter-spacing: -.05em; line-height: 1; }
.step p:last-child { margin: 0; color: var(--muted); font-size: clamp(16px, 1.4vw, 19px); max-width: 560px; }
.method__line { position: absolute; top: 0; bottom: 0; width: 1px; background: var(--line); pointer-events: none; }
.method__line i { display: block; width: 100%; height: 100%; transform: scaleY(0); transform-origin: top; background: linear-gradient(var(--violet), var(--cyan)); box-shadow: 0 0 10px var(--cyan); }

/* ---------- DIFERENCIAIS ---------- */
.edge__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 4vw, 60px); align-items: start; }
.rules { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.rule { border-bottom: 1px solid var(--line); }
.rule button { width: 100%; display: flex; align-items: center; gap: 18px; padding: 26px 0; text-align: left; font-size: clamp(22px, 2.4vw, 34px); font-weight: 500; letter-spacing: -.035em; transition: color .3s, padding .5s var(--ease); }
.rule button span { color: var(--faint); font-size: 11.5px; }
.rule button i { margin-left: auto; font-style: normal; font-weight: 300; font-size: 28px; color: var(--muted); transition: transform .5s var(--ease); }
.rule button:hover { padding-left: 10px; }
.rule.is-open button i { transform: rotate(45deg); color: var(--cyan); }
.rule__body { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .6s var(--ease); }
.rule.is-open .rule__body { grid-template-rows: 1fr; }
.rule__body p { overflow: hidden; margin: 0; color: var(--muted); font-size: 16.5px; max-width: 520px; padding-left: 36px; }
.rule.is-open .rule__body p { padding-bottom: 26px; }
.terminal { position: sticky; top: 110px; margin: 0; border-radius: var(--radius); border: 1px solid var(--line); background: rgba(8,7,18,.82); backdrop-filter: blur(16px); overflow: hidden; box-shadow: 0 40px 100px -40px rgba(124,92,255,.45); }
.terminal__bar { display: flex; align-items: center; gap: 7px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.terminal__bar i { width: 11px; height: 11px; border-radius: 50%; background: #2a2740; }
.terminal__bar i:nth-child(1) { background: #ff5f57; } .terminal__bar i:nth-child(2) { background: #febc2e; } .terminal__bar i:nth-child(3) { background: #28c840; }
.terminal__bar span { margin-left: 12px; color: var(--faint); font-size: 10.5px; text-transform: none; letter-spacing: .02em; }
.terminal__code { margin: 0; padding: 22px 22px 28px; min-height: 380px; font-size: 12.5px; line-height: 1.75; text-transform: none; letter-spacing: 0; color: #d6d2f0; white-space: pre-wrap; overflow-x: auto; }
.terminal__code c { color: #6f6b8e; font-style: italic; } .terminal__code k { color: #b39dff; } .terminal__code s { color: var(--cyan); text-decoration: none; }
.terminal__code .caret { display: inline-block; width: 8px; height: 1.1em; vertical-align: -3px; background: var(--cyan); animation: blink 1s steps(2) infinite; }

/* ---------- SIMULADOR ---------- */
.console { max-width: 1240px; margin: 0 auto; display: grid; grid-template-columns: 1.6fr 1fr; border-radius: 28px; border: 1px solid var(--line-2); overflow: hidden;
  background: rgba(8,7,18,.78); backdrop-filter: blur(22px) saturate(1.3); box-shadow: 0 60px 140px -50px rgba(124,92,255,.55), 0 0 0 1px rgba(255,255,255,.03) inset; }
.console__main { padding: clamp(22px, 3.4vw, 44px); display: flex; flex-direction: column; min-height: 600px; }
.console__top { display: flex; justify-content: space-between; align-items: center; color: var(--faint); margin-bottom: 30px; }
.console__top b { color: var(--ink); font-weight: 500; }
.console__dots { display: flex; gap: 6px; }
.console__dots i { width: 26px; height: 3px; border-radius: 3px; background: var(--line-2); transition: background .4s; }
.console__dots i.is-on { background: var(--cyan); box-shadow: 0 0 8px var(--cyan); }
.console__body { flex: 1; position: relative; }
.q { display: none; }
.q.is-on { display: block; }
.q__title { margin: 0 0 8px; font-size: clamp(26px, 3vw, 40px); font-weight: 600; letter-spacing: -.04em; line-height: 1.05; }
.q__hint { margin: 0 0 28px; color: var(--muted); }
.opts { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.opts--chips { display: flex; flex-wrap: wrap; gap: 8px; }
.opt { position: relative; text-align: left; padding: 18px 18px 16px; border-radius: 16px; border: 1px solid var(--line); background: rgba(255,255,255,.025);
  transition: border-color .3s, background .3s, transform .4s var(--ease); display: grid; gap: 4px; }
.opt:hover { border-color: rgba(255,255,255,.3); transform: translateY(-2px); }
.opt b { padding-right: 22px; font-weight: 500; font-size: 16px; letter-spacing: -.02em; }
.opt span { color: var(--faint); font-size: 13px; }
.opt::after { content: ""; position: absolute; top: 14px; right: 14px; width: 14px; height: 14px; border-radius: 50%; border: 1px solid var(--line-2); transition: all .3s; }
.opt[aria-pressed="true"] { border-color: var(--cyan); background: linear-gradient(135deg, rgba(124,92,255,.18), rgba(79,216,232,.08)); }
.opt[aria-pressed="true"]::after { background: var(--cyan); border-color: var(--cyan); box-shadow: 0 0 12px var(--cyan); }
.opts--chips .opt { padding: 11px 16px; border-radius: 999px; display: inline-flex; }
.opts--chips .opt::after { display: none; }
.opts--chips .opt b { font-size: 14px; }
.opts--chips .opt[aria-pressed="true"] b::before { content: "✓ "; color: var(--cyan); }
.console__nav { display: flex; justify-content: space-between; margin-top: 30px; gap: 10px; }
.field { display: grid; gap: 8px; margin-bottom: 14px; }
.field label { color: var(--faint); }
.field input, .field textarea { width: 100%; font: inherit; color: var(--ink); background: rgba(255,255,255,.04); border: 1px solid var(--line-2); border-radius: 14px; padding: 14px 16px; transition: border-color .3s, background .3s; resize: vertical; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--cyan); background: rgba(79,216,232,.05); }
.fields2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.result__class { font-size: clamp(34px, 4.4vw, 60px); font-weight: 600; letter-spacing: -.05em; line-height: 1; margin: 0 0 6px;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.result__sum { color: var(--muted); margin: 0 0 24px; }
.result__mods { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 26px; padding: 0; list-style: none; }
.result__mods li { padding: 6px 11px; border-radius: 999px; border: 1px solid var(--line-2); font-size: 12.5px; color: var(--muted); }
.result__send { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 6px; }
.readout { padding: clamp(22px, 3vw, 40px); border-left: 1px solid var(--line); background: linear-gradient(180deg, rgba(124,92,255,.08), rgba(79,216,232,.03)); display: flex; flex-direction: column; }
.readout__title { color: var(--cyan); margin: 0 0 20px; }
.gauge { position: relative; width: 100%; max-width: 300px; margin: 0 auto; }
.gauge svg { width: 100%; display: block; overflow: visible; }
.gauge path { fill: none; stroke-width: 10; stroke-linecap: round; }
.gauge__track { stroke: rgba(255,255,255,.07); }
.gauge__fill { stroke: url(#g); stroke: var(--cyan); filter: drop-shadow(0 0 8px var(--cyan)); stroke-dasharray: 252; stroke-dashoffset: 252; transition: stroke-dashoffset 1s var(--ease); }
.gauge__val { position: absolute; left: 0; right: 0; bottom: 0; text-align: center; display: grid; }
.gauge__val b { font-size: 46px; font-weight: 600; letter-spacing: -.05em; line-height: 1; }
.gauge__val span { color: var(--faint); font-size: 10px; }
.readout__list { margin: 30px 0 0; display: grid; gap: 0; }
.readout__list div { display: flex; justify-content: space-between; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.readout__list dt { color: var(--faint); }
.readout__list dd { margin: 0; text-align: right; font-size: 14px; }
.readout__note { margin: auto 0 0; padding-top: 24px; color: var(--faint); font-size: 12.5px; }

/* ---------- FAQ ---------- */
.faq__list { max-width: 980px; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 20px; padding: 28px 0; font-size: clamp(20px, 2.2vw, 30px); font-weight: 500; letter-spacing: -.035em; transition: color .3s; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary:hover { color: var(--cyan); }
.faq summary i { margin-left: auto; position: relative; width: 18px; height: 18px; flex: none; }
.faq summary i::before, .faq summary i::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1.5px; background: currentColor; transition: transform .5s var(--ease); }
.faq summary i::after { transform: rotate(90deg); }
.faq details[open] summary i::after { transform: rotate(0); }
.faq details p { margin: 0; padding: 0 0 30px; color: var(--muted); max-width: 720px; font-size: 17px; }

/* ---------- FINAL ---------- */
.final { min-height: 100svh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.final__title { margin: 0; max-width: 1200px; font-weight: 600; font-size: clamp(44px, 7.6vw, 128px); line-height: .95; letter-spacing: -.055em; text-shadow: 0 0 60px rgba(5,4,11,.9); }
.final__title em { color: transparent; background: var(--grad); -webkit-background-clip: text; background-clip: text; padding-right: .08em; }
.final__mail { margin-top: 44px; font-family: var(--serif); font-style: italic; font-size: clamp(28px, 4vw, 58px); letter-spacing: -.02em; position: relative; }
.final__mail::after { content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 1px; background: var(--grad); transform: scaleX(.2); transition: transform .8s var(--ease); }
.final__mail:hover::after { transform: scaleX(1); }
.final__cta { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 40px; }

.foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; padding: 30px var(--pad) 40px; border-top: 1px solid var(--line); background: rgba(5,4,11,.7); }
.foot__brand { display: flex; gap: 10px; align-items: center; font-weight: 600; }
.foot__brand b { font-weight: 300; color: var(--muted); margin-left: 2px; }
.foot__links { display: flex; gap: 22px; flex-wrap: wrap; }
.foot__links a { color: var(--muted); transition: color .3s; }
.foot__links a:hover { color: var(--cyan); }
.foot__copy { color: var(--faint); margin: 0; }

/* ---------- ESTUDO DE CASO ---------- */
.case { position: fixed; inset: 0; z-index: 90; }
.case[hidden] { display: none; }
.case__backdrop { position: absolute; inset: 0; background: rgba(3,2,8,.72); backdrop-filter: blur(10px); }
.case__panel { position: absolute; top: 0; right: 0; bottom: 0; width: min(920px, 100vw); overflow-y: auto; overscroll-behavior: contain;
  background: #0a0916; border-left: 1px solid var(--line-2); box-shadow: -40px 0 120px -20px rgba(0,0,0,.8); }
.case__close { position: sticky; top: 16px; float: right; margin: 16px 16px 0 0; z-index: 3; padding: 11px 16px; border-radius: 999px; background: rgba(5,4,11,.7); border: 1px solid var(--line-2); backdrop-filter: blur(10px); }
.case__close:hover { border-color: var(--cyan); color: var(--cyan); }
.case__hero { aspect-ratio: 16 / 9; overflow: hidden; }
.case__hero img { width: 100%; height: 100%; object-fit: cover; }
.case__body { padding: clamp(24px, 5vw, 60px); }
.case__meta { color: var(--cyan); margin: 0 0 14px; }
.case__title { margin: 0; font-size: clamp(44px, 7vw, 96px); font-weight: 700; letter-spacing: -.06em; line-height: .92; }
.case__lede { margin: 16px 0 26px; font-size: clamp(22px, 2.6vw, 34px); color: var(--ink); line-height: 1.15; }
.case__text { margin: 0; color: var(--muted); font-size: 17.5px; line-height: 1.7; max-width: 680px; }
.case__facts { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; margin: 36px 0; background: var(--line); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.case__facts div { padding: 20px; background: #0d0c1c; display: grid; gap: 8px; }
.case__facts dt { color: var(--faint); }
.case__facts dd { margin: 0; font-size: 15px; }
.case__extra { margin: 0 0 36px; border-radius: 18px; overflow: hidden; border: 1px solid var(--line); }
.case__extra img { width: 100%; }
.case__cta { display: flex; gap: 10px; flex-wrap: wrap; }

.toast { position: fixed; left: 50%; top: 84px; z-index: 120; padding: 12px 18px; border-radius: 999px; background: var(--ink); color: var(--void); transform: translate(-50%, -20px); opacity: 0; pointer-events: none; transition: all .5s var(--ease); }
.toast.is-on { transform: translate(-50%, 0); opacity: 1; }

@keyframes wave { from { transform: scaleY(.4); } to { transform: scaleY(1); } }
.btn__wave path:nth-child(2) { animation-delay: -.2s; } .btn__wave path:nth-child(3) { animation-delay: -.5s; }

/* ---------- RESPONSIVO ---------- */
@media (max-width: 1080px) {
  .nav__links { display: none; }
  .bento { grid-template-columns: 1fr 1fr; }
  .card--wide { grid-column: span 2; }
  .edge__grid { grid-template-columns: 1fr; }
  .terminal { position: relative; top: 0; }
  .console { grid-template-columns: 1fr; }
  .readout { border-left: 0; border-top: 1px solid var(--line); }
}
@media (max-width: 900px) {
  .hero { align-items: flex-end; padding-top: 56vh; padding-bottom: 90px; }
  .hero__inner { max-width: 100%; }
  .hero__eclipse { left: 50%; top: 28%; width: min(64vw, 40vh); }
  .hero__hud { display: none; }
  .hero__scroll { display: none; }
  .stats { grid-template-columns: 1fr 1fr; }
  .works__pin { height: auto; padding: 90px 0 30px; }
  .works__track { width: auto; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 10px; scrollbar-width: none; }
  .works__track::-webkit-scrollbar { display: none; }
  .work { width: 82vw; scroll-snap-align: center; }
  .work__open { opacity: 1; transform: scale(.85); }
  .steps { margin-right: 0; }
  .gate__hud--bl, .gate__hud--br { display: none; }
}
@media (max-width: 640px) {
  .voice-toggle__txt { display: none; }
  .nav { padding-top: 12px; }
  .nav__right .btn { display: none; }
  .bento { grid-template-columns: 1fr; }
  .card--wide, .card--xl { grid-column: auto; grid-row: auto; }
  .card { min-height: 280px; }
  .card--xl .viz-phone, .viz-phone { width: 84px; height: 150px; top: 22px; right: 22px; border-radius: 20px; padding: 12px 9px; gap: 6px; }
  .viz-phone i { height: 22px; }
  .card { min-height: 300px; }
  .viz-graph { width: 55%; }
  .stat { padding: 22px 18px; }
  .fields2 { grid-template-columns: 1fr; }
  .opts { grid-template-columns: 1fr 1fr; }
  .opt { padding: 14px 14px 12px; }
  .case__facts { grid-template-columns: 1fr; }
  .caption { gap: 10px; padding: 12px 14px; flex-direction: column; }
  .gate__hud--tr span:last-child { display: none; }
  .console__main { min-height: 0; }
}

@media (min-width: 901px) {
  .caption { left: auto; right: var(--pad); width: min(520px, 40vw); transform: translateY(20px); }
  .caption.is-on { transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .grain { display: none; }
}
