/* NBRT RBX — portfólio. Tokens = social/contas/roblox/brand/brand.ts (v1 aprovada).
   Ideia: tudo é bloco. Sombras são duras e deslocadas (extrusão azul); a extrusão cresce com a velocidade do scroll (--ext, app.js). */
:root {
  --noite: #0b0c12;
  --painel: #161926;
  --painel-2: #22263a;
  --linha: rgba(255, 255, 255, .1);
  --texto: #f5f7ff;
  --muted: #9aa0b8;
  --volt: #c6ff3d;
  --bloco: #3d7bff;
  --bug: #ff4d6d;
  --ouro: #ffc93d;
  --f-display: "Unbounded", system-ui, sans-serif;
  --f-body: "Rubik", system-ui, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, monospace;
  --gutter: clamp(16px, 4.5vw, 72px);
  --r: 22px;
  --ext: 8px;
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
body { margin: 0; background: var(--noite); color: var(--texto); font: 400 1.0625rem/1.6 var(--f-body); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
a { color: inherit; }
img, video { display: block; max-width: 100%; }
h1, h2, h3 { margin: 0; font-family: var(--f-display); font-weight: 800; letter-spacing: -.01em; line-height: 1.02; }
:focus-visible { outline: 3px solid var(--volt); outline-offset: 3px; border-radius: 6px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 12px; z-index: 100; background: var(--volt); color: var(--noite); padding: 8px 12px; }

/* bloco = sombra dura azul que "extruda" */
.block { box-shadow: var(--ext) var(--ext) 0 var(--bloco); }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 0 26px; border-radius: 14px; background: var(--volt); color: var(--noite); font: 800 .9375rem var(--f-display); text-decoration: none; transition: transform .15s; }
.btn:hover { transform: translate(-2px, -2px); }
.btn:active { transform: translate(calc(var(--ext) * .8), calc(var(--ext) * .8)); box-shadow: 0 0 0 var(--bloco); }
.btn.ghost { background: transparent; color: var(--texto); border: 2px solid var(--painel-2); box-shadow: none; font-family: var(--f-mono); font-weight: 700; }
.btn.ghost:hover { border-color: var(--volt); color: var(--volt); }
.ctas { display: flex; flex-wrap: wrap; gap: 14px 18px; }

/* topo */
.top { position: fixed; inset: 0 0 auto; z-index: 50; display: flex; align-items: center; justify-content: space-between; padding: 14px var(--gutter); pointer-events: none; }
.top > * { pointer-events: auto; }
.logo svg { width: 44px; height: 44px; display: block; }
.top nav { display: flex; gap: 4px; padding: 6px; border-radius: 16px; background: rgba(22, 25, 38, .72); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border: 1px solid var(--linha); }
.top nav a { padding: 8px 14px; border-radius: 11px; font: 500 .875rem var(--f-body); text-decoration: none; color: var(--muted); }
.top nav a:hover, .top nav a.on { color: var(--noite); background: var(--volt); }

/* ---------- hero ---------- */
.hero { position: relative; min-height: 100svh; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); align-items: center; gap: 24px; padding: 110px var(--gutter) 80px; overflow: hidden; isolation: isolate; }
.studs { position: absolute; inset: -10%; z-index: -2; background-image: radial-gradient(circle, rgba(255, 255, 255, .13) 1.6px, transparent 2px); background-size: 28px 28px; mask-image: radial-gradient(ellipse at 60% 45%, #000 20%, transparent 75%); -webkit-mask-image: radial-gradient(ellipse at 60% 45%, #000 20%, transparent 75%); }
.hero::after { content: ""; position: absolute; z-index: -1; right: -10%; top: 5%; width: 70vmin; height: 70vmin; border-radius: 50%; background: radial-gradient(circle, rgba(61, 123, 255, .35), transparent 65%); filter: blur(20px); }
.wordmark { display: flex; flex-wrap: wrap; align-items: center; gap: .1em .22em; font-size: clamp(4.2rem, 13.5vw, 13rem); font-weight: 900; letter-spacing: .02em; line-height: .86; }
.wordmark .w { display: inline-flex; }
.wordmark .w b { display: inline-block; font-weight: 900; }
.key { display: inline-block; font-size: .5em; letter-spacing: .01em; padding: .14em .3em .12em; border-radius: .22em; background: var(--volt); color: var(--noite); --ext: .1em; transform-origin: 50% 100%; }
.line { margin: 34px 0 32px; max-width: 30ch; font: 500 clamp(1.15rem, 1.9vw, 1.5rem)/1.4 var(--f-body); color: #d9dcea; }
.avatar { margin: 0; justify-self: end; width: min(100%, 560px); aspect-ratio: 1; border-radius: 34px; overflow: hidden; --ext: 14px; box-shadow: var(--ext) var(--ext) 0 var(--bloco); }
.avatar img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.08); }
.cubes { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.cube { position: absolute; left: var(--x); top: var(--y); width: var(--s); height: var(--s); border-radius: 22%; background: var(--volt); box-shadow: calc(var(--s) * .16) calc(var(--s) * .16) 0 var(--bloco); }
.cube.blue { background: var(--bloco); box-shadow: calc(var(--s) * .16) calc(var(--s) * .16) 0 #23408a; }
.cube.gold { background: var(--ouro); box-shadow: calc(var(--s) * .16) calc(var(--s) * .16) 0 #a8761a; }
.scroll-cue { position: absolute; left: 50%; bottom: 26px; width: 26px; height: 42px; margin-left: -13px; border: 2px solid var(--painel-2); border-radius: 14px; }
.scroll-cue span { position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: var(--volt); animation: cue 1.6s infinite; }
@keyframes cue { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }

/* ---------- títulos de seção ---------- */
.sec-head { display: grid; grid-template-columns: minmax(0, auto) minmax(0, 34ch); align-items: end; justify-content: space-between; gap: 16px 48px; padding: 0 var(--gutter); }
.sec-head h2 { font-size: clamp(2.6rem, 8vw, 7rem); font-weight: 900; }
.sec-head p { margin: 0; color: var(--muted); font-size: 1.125rem; }

/* ---------- feito por mim (anel 3D) ---------- */
.made { padding: 120px 0 40px; overflow: hidden; }
.ring-wrap { position: relative; height: min(62vh, 600px); margin-top: 24px; perspective: 1700px; perspective-origin: 50% 40%; touch-action: pan-y; cursor: grab; }
.ring-wrap:active { cursor: grabbing; }
.ring { position: absolute; left: 50%; top: 50%; width: var(--cw); height: calc(var(--cw) * .66); margin: calc(var(--cw) * -.33) 0 0 calc(var(--cw) / -2); transform-style: preserve-3d; --cw: min(46vw, 560px); }
.card3d { position: absolute; inset: 0; margin: 0; border-radius: 22px; overflow: hidden; background: var(--painel); box-shadow: var(--ext) var(--ext) 0 var(--bloco); backface-visibility: hidden; transform: rotateY(calc(var(--i) * var(--step))) translateZ(var(--radius)); transition: filter .4s; user-select: none; }
.card3d img, .card3d video { width: 100%; height: 100%; object-fit: cover; pointer-events: none; display: block; }
.card3d figcaption { position: absolute; left: 0; right: 0; bottom: 0; display: flex; justify-content: space-between; align-items: end; gap: 12px; padding: 40px 18px 14px; background: linear-gradient(transparent, rgba(11, 12, 18, .85)); opacity: 0; transition: opacity .3s; }
.card3d.front figcaption { opacity: 1; }
.card3d figcaption b { font: 800 1.15rem var(--f-display); }
.card3d figcaption span { font: 700 .75rem var(--f-mono); color: var(--volt); }
.ring-ui { display: flex; align-items: center; justify-content: center; gap: 20px; margin-top: 18px; padding: 0 var(--gutter); }
.ring-btn { width: 52px; height: 52px; border: 0; border-radius: 14px; background: var(--painel-2); color: var(--texto); cursor: pointer; display: grid; place-items: center; transition: background .2s, color .2s; }
.ring-btn:hover { background: var(--volt); color: var(--noite); }
.ring-btn svg { width: 22px; height: 22px; }
.ring-caption { margin: 0; min-width: 15ch; text-align: center; }
.ring-caption b { display: block; font: 800 1.3rem var(--f-display); }
.ring-caption span { font: 700 .8125rem var(--f-mono); color: var(--volt); }
/* sem JS: vira uma faixa que rola de lado */
html:not(.js3d) .ring-wrap { height: auto; perspective: none; overflow-x: auto; scroll-snap-type: x mandatory; }
html:not(.js3d) .ring { position: static; margin: 0; width: auto; height: auto; display: flex; gap: 16px; padding: 0 var(--gutter) 20px; }
html:not(.js3d) .card3d { position: relative; flex: 0 0 min(80vw, 520px); aspect-ratio: 3 / 2; transform: none; scroll-snap-align: center; }
html:not(.js3d) .card3d figcaption { opacity: 1; }
html:not(.js3d) .ring-ui { display: none; }

/* ---------- jogos (lista compacta) ---------- */
.games { padding: 120px 0 40px; }
.game-list { list-style: none; margin: 48px 0 0; padding: 0 var(--gutter); display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 18px; }
.game { display: flex; flex-direction: column; gap: 8px; padding: 22px; border-radius: var(--r); background: var(--painel); border: 1px solid var(--linha); }
.game.live { border-color: var(--volt); }
.game .status { align-self: start; display: inline-flex; align-items: center; gap: 8px; margin: 0 0 8px; padding: 5px 11px; border-radius: 9px; background: var(--painel-2); font: 700 .75rem var(--f-mono); color: var(--ouro); }
.game .status::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: currentColor; }
.game.live .status { color: var(--volt); }
.game.live .status::before { animation: blink 1.2s steps(2) infinite; }
@keyframes blink { 50% { opacity: .2; } }
.game h3 { font-size: 1.5rem; font-weight: 900; }
.game .genre { margin: 0; color: var(--muted); font: 500 .8125rem var(--f-mono); }
.game .btn { margin-top: auto; align-self: start; }
.game.live .genre { margin-bottom: 14px; }

/* ---------- diário ---------- */
.devlog { display: grid; grid-template-columns: minmax(0, 360px) minmax(0, 1fr); gap: clamp(32px, 7vw, 110px); align-items: center; padding: 120px var(--gutter); }
.phone { border-radius: 30px; overflow: hidden; background: var(--painel); --ext: 14px; }
.phone video { width: 100%; height: auto; aspect-ratio: 9 / 16; object-fit: cover; }
.devlog h2 { font-size: clamp(2.4rem, 6vw, 5.4rem); font-weight: 900; }
.devlog-copy > p:first-of-type { margin: 22px 0 0; max-width: 34ch; font-size: 1.25rem; color: #cfd3e3; }
.day { display: flex; align-items: baseline; gap: 16px; margin: 30px 0 34px; font-family: var(--f-display); }
.day span { font-size: 1.4rem; font-weight: 800; color: var(--muted); }
.day b { font-size: clamp(5rem, 12vw, 9rem); line-height: .8; font-weight: 900; color: var(--volt); text-shadow: .06em .06em 0 var(--bloco); }

/* ---------- fim ---------- */
.end { padding: 120px var(--gutter) 36px; text-align: center; background: linear-gradient(transparent, rgba(61, 123, 255, .14)); }
.big { margin: 0 0 40px; font: 900 clamp(3rem, 12vw, 11rem)/.9 var(--f-display); letter-spacing: -.01em; }
.big .q { color: var(--volt); display: inline-block; }
.btn.xl { min-height: 66px; padding: 0 40px; font-size: 1.125rem; --ext: 10px; }
.fine { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 110px; padding-top: 22px; border-top: 1px solid var(--linha); color: var(--muted); font: 500 .8125rem var(--f-mono); text-align: left; }
.fine p { margin: 0; }
.fine .logo svg { width: 32px; height: 32px; }

/* ---------- telas menores ---------- */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; padding-top: 96px; }
  .avatar { justify-self: start; width: min(78%, 380px); order: -1; }
  .top nav a { padding: 7px 9px; font-size: .8125rem; }
  .cube:nth-child(1), .cube:nth-child(3) { display: none; }
  .ring { --cw: 74vw; }
  .ring-wrap { height: 62vw; perspective: 1100px; }
  .sec-head { grid-template-columns: 1fr; }
  .devlog { grid-template-columns: 1fr; }
  .phone { max-width: 320px; }
  .fine { flex-direction: column; text-align: center; }
}
@media (max-width: 520px) {
  .top nav a:nth-child(3) { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
