:root {
  --bg: #0b0f17;
  --bg-alt: #0f1521;
  --surface: #141b2a;
  --border: #222c40;
  --text: #e7ecf3;
  --muted: #94a0b4;
  --accent: #22d3ee;
  --accent-2: #a78bfa;
  --grad: linear-gradient(90deg, var(--accent), var(--accent-2));
  --radius: 16px;
  --max: 1120px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, Segoe UI, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
.mono { font-family: 'JetBrains Mono', ui-monospace, monospace; }
.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 760px; }
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 14px 26px; border-radius: 999px;
  background: var(--grad); color: #06121a; font-weight: 700;
  transition: transform .2s, box-shadow .2s;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 10px 30px -10px rgba(34, 211, 238, .6); }
.btn-ghost { background: transparent; color: var(--text); border: 1px solid var(--border); }
.btn-ghost:hover { border-color: var(--accent); box-shadow: none; }
.btn-sm { padding: 9px 18px; font-size: 15px; }
.link { color: var(--accent); font-weight: 600; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(11, 15, 23, .8); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-inner { display: flex; align-items: center; gap: 32px; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 18px; }
.brand strong { color: var(--accent); }
.brand-mark {
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px;
  background: var(--grad); color: #06121a; font-weight: 800;
}
.nav-links { display: flex; gap: 28px; margin-left: auto; font-size: 15px; color: var(--muted); }
.nav-links a:hover { color: var(--text); }
.nav-toggle { display: none; background: none; border: 0; width: 36px; height: 36px; cursor: pointer; }
.nav-toggle span { display: block; height: 2px; background: var(--text); margin: 7px 6px; transition: .2s; }

/* Hero */
.hero { position: relative; padding: 110px 0 90px; overflow: hidden; }
.hero-glow {
  position: absolute; inset: -30% -10% auto; height: 700px;
  background: radial-gradient(closest-side, rgba(34, 211, 238, .18), transparent),
              radial-gradient(closest-side at 70% 40%, rgba(167, 139, 250, .16), transparent);
  pointer-events: none;
}
.hero-inner { position: relative; text-align: center; }
.eyebrow { color: var(--accent); font-weight: 600; font-size: 14px; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 14px; }
h1 { font-size: clamp(38px, 6.4vw, 72px); line-height: 1.05; letter-spacing: -.03em; font-weight: 800; max-width: 900px; margin: 0 auto 24px; }
h2 { font-size: clamp(30px, 4vw, 44px); line-height: 1.12; letter-spacing: -.02em; font-weight: 800; margin-bottom: 18px; }
h3 { font-size: 20px; font-weight: 700; margin-bottom: 8px; }
.lead { font-size: clamp(17px, 2vw, 20px); color: var(--muted); max-width: 720px; margin: 0 auto 36px; }
.lead strong { color: var(--text); font-weight: 600; }
.hero-cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

.hero-diagram {
  display: grid; grid-template-columns: 1fr 80px 1.1fr 80px 1fr; align-items: center;
  margin-top: 72px; text-align: left;
}
.node {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px; display: flex; flex-wrap: wrap; gap: 8px; align-content: flex-start;
}
.node-label { width: 100%; font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.chip { font-size: 13px; padding: 4px 10px; border-radius: 999px; background: var(--bg-alt); border: 1px solid var(--border); }
.node-core {
  border-color: transparent; text-align: center; justify-content: center; padding: 28px 20px;
  background: linear-gradient(var(--surface), var(--surface)) padding-box, var(--grad) border-box;
  border: 1.5px solid transparent;
  box-shadow: 0 0 60px -20px rgba(34, 211, 238, .5);
}
.node-core .node-label { color: var(--accent); }
.core-title { font-size: 22px; font-weight: 800; }
.wire { position: relative; height: 2px; background: var(--border); overflow: hidden; }
.pulse { position: absolute; top: 0; left: -40%; width: 40%; height: 100%; background: var(--grad); animation: flow 2.2s linear infinite; }
.wire:last-of-type .pulse { animation-delay: 1.1s; }
@keyframes flow { to { left: 100%; } }

/* Sections */
.section { padding: 100px 0; }
.section-alt { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-lead { color: var(--muted); font-size: 19px; max-width: 680px; margin-bottom: 48px; }

.pillars { display: grid; grid-template-columns: 1.3fr 1fr; gap: 20px; margin-top: 40px; }
.pillar { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 36px; }
.pillar h3 { font-size: 26px; margin: 14px 0 10px; }
.pillar p { color: var(--muted); margin-bottom: 20px; }
.pillar-main {
  background: linear-gradient(160deg, rgba(34, 211, 238, .1), rgba(167, 139, 250, .08) 60%, var(--surface));
  border-color: rgba(34, 211, 238, .35);
}
.tag { display: inline-block; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; padding: 5px 12px; border-radius: 999px; background: rgba(34, 211, 238, .14); color: var(--accent); }
.tag-muted { background: var(--bg-alt); color: var(--muted); }

.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; transition: border-color .2s, transform .2s; }
.card:hover { border-color: rgba(34, 211, 238, .5); transform: translateY(-3px); }
.card p { color: var(--muted); font-size: 15.5px; }
.card-icon {
  display: inline-grid; place-items: center; width: 52px; height: 40px; border-radius: 10px; margin-bottom: 18px;
  font-size: 13px; color: var(--accent); background: rgba(34, 211, 238, .1); border: 1px solid rgba(34, 211, 238, .25);
}

.usecases { margin-top: 48px; padding: 32px; border-radius: var(--radius); border: 1px dashed var(--border); }
.usecases ul { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 32px; margin-top: 16px; }
.usecases li { color: var(--muted); padding-left: 22px; position: relative; }
.usecases li::before { content: '→'; position: absolute; left: 0; color: var(--accent); }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.split .section-lead { margin-bottom: 0; }
.checklist li { padding: 18px 0 18px 36px; border-bottom: 1px solid var(--border); position: relative; color: var(--muted); }
.checklist li:first-child { border-top: 1px solid var(--border); }
.checklist li strong { color: var(--text); }
.checklist li::before {
  content: '✓'; position: absolute; left: 0; top: 18px; width: 22px; height: 22px; border-radius: 50%;
  display: grid; place-items: center; font-size: 12px; color: #06121a; background: var(--grad);
}

.section-statement { text-align: center; }
.statement { font-size: clamp(32px, 5vw, 56px); margin-bottom: 56px; }
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; text-align: left; max-width: 860px; margin: 0 auto; }
.compare-col { border-radius: var(--radius); padding: 32px; border: 1px solid var(--border); }
.compare-col li { padding: 10px 0 10px 28px; position: relative; }
.compare-old { background: var(--bg-alt); color: var(--muted); }
.compare-old li::before { content: '✕'; position: absolute; left: 0; color: #6b7487; }
.compare-new { background: var(--surface); border-color: rgba(34, 211, 238, .4); }
.compare-new h3 { color: var(--accent); }
.compare-new li::before { content: '✓'; position: absolute; left: 0; color: var(--accent); }

.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; counter-reset: s; }
.steps li { padding: 28px; border-top: 2px solid var(--border); position: relative; }
.steps li::before { content: ''; position: absolute; top: -2px; left: 0; width: 48px; height: 2px; background: var(--grad); }
.step-n { display: block; color: var(--accent); font-size: 14px; margin-bottom: 12px; }
.steps p { color: var(--muted); font-size: 15.5px; }

.founder { display: grid; grid-template-columns: 200px 1fr; gap: 56px; align-items: start; }
.founder-avatar {
  width: 200px; height: 200px; border-radius: 28px; display: grid; place-items: center;
  font-size: 64px; font-weight: 800; color: #06121a; background: var(--grad);
}
.founder h2 { margin-bottom: 4px; }
.founder-role { color: var(--accent); font-weight: 600; margin-bottom: 18px; }
.founder p { color: var(--muted); max-width: 680px; }
.stats { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }
.stats li { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 14px 20px; display: flex; flex-direction: column; }
.stats strong { font-size: 18px; }
.stats span { font-size: 13px; color: var(--muted); }

details { border-bottom: 1px solid var(--border); padding: 22px 0; }
details:first-of-type { border-top: 1px solid var(--border); margin-top: 24px; }
summary { cursor: pointer; font-weight: 600; font-size: 18px; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: '+'; color: var(--accent); font-size: 24px; line-height: 1; transition: transform .2s; }
details[open] summary::after { transform: rotate(45deg); }
details p { color: var(--muted); margin-top: 12px; }

.cta { text-align: center; position: relative; overflow: hidden; }
.cta::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(closest-side at 50% 60%, rgba(34, 211, 238, .14), transparent 70%);
}
.cta-inner { position: relative; }
.cta h2 { max-width: 760px; margin: 0 auto 14px; }
.cta p { color: var(--muted); margin-bottom: 32px; font-size: 19px; }

.footer { border-top: 1px solid var(--border); padding: 28px 0; color: var(--muted); font-size: 14px; }
.footer-inner { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.footer a:hover { color: var(--text); }

/* Reveal */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .pulse { animation: none; }
  html { scroll-behavior: auto; }
}

/* Responsive */
@media (max-width: 1100px) { .cards { grid-template-columns: 1fr 1fr; } }
@media (max-width: 980px) {
  .cards, .steps { grid-template-columns: 1fr 1fr; }
  .split { grid-template-columns: 1fr; gap: 36px; }
  .hero-diagram { grid-template-columns: 1fr; gap: 0; max-width: 420px; margin-left: auto; margin-right: auto; }
  .wire { width: 2px; height: 36px; margin: 0 auto; }
  .pulse { width: 100%; height: 40%; left: 0; top: -40%; animation-name: flow-v; }
  @keyframes flow-v { to { top: 100%; } }
}
@media (max-width: 760px) {
  body { font-size: 16px; }
  .container { padding: 0 16px; }
  .nav-inner { gap: 12px; }
  .nav-links {
    position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--border); display: none; margin: 0;
  }
  .nav-links a { padding: 16px; border-top: 1px solid var(--border); }
  .nav.open .nav-links { display: flex; }
  .nav .btn-sm { margin-left: auto; }
  .nav-toggle { display: block; }
  .nav.open .nav-toggle span:first-child { transform: translateY(4.5px) rotate(45deg); }
  .nav.open .nav-toggle span:last-child { transform: translateY(-4.5px) rotate(-45deg); }
  .hero { padding: 72px 0 64px; }
  .section { padding: 72px 0; }
  .pillars, .cards, .steps, .compare, .usecases ul { grid-template-columns: 1fr; }
  .pillar, .compare-col, .usecases { padding: 24px; }
  .founder { grid-template-columns: 1fr; gap: 28px; }
  .founder-avatar { width: 120px; height: 120px; font-size: 40px; border-radius: 22px; }
}
@media (max-width: 420px) {
  .nav .btn-sm { display: none; }
  .nav-toggle { margin-left: auto; }
}
.cta .cta-email { margin: 24px 0 0; font-size: 16px; }
.cta-email a { color: var(--accent); }
.cta-email a:hover { text-decoration: underline; }

/* Portfólio */
.projects { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.project { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: border-color .2s; }
.project:hover { border-color: rgba(34, 211, 238, .45); }
.project-visual { height: 280px; position: relative; overflow: hidden; }
.project-body { padding: 28px; display: flex; flex-direction: column; gap: 14px; flex: 1; }
.project-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.project-top h3 { font-size: 24px; margin: 0; }
.project-body > p { color: var(--muted); font-size: 15.5px; }
.status { font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 999px; color: #fbbf24; background: rgba(251, 191, 36, .12); border: 1px solid rgba(251, 191, 36, .3); }
.project-points li { color: var(--muted); font-size: 15px; padding: 4px 0 4px 20px; position: relative; }
.project-points li::before { content: '→'; position: absolute; left: 0; color: var(--accent); }
.stack { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: 6px; }
.stack li { font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: 12px; padding: 4px 10px; border-radius: 6px; background: var(--bg-alt); border: 1px solid var(--border); color: var(--muted); }

.visual-cvblocks { background: #f4f5f7; }
.visual-cvblocks img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }

.visual-ementa { background: radial-gradient(circle at 30% 20%, #23594b, #173f35 70%); display: flex; align-items: center; justify-content: center; gap: 18px; padding: 24px; }
.ementa-phone { width: 210px; background: #f6f3e9; color: #1d2a26; border-radius: 22px; padding: 16px 14px; box-shadow: 0 20px 40px -12px rgba(0, 0, 0, .5); border: 5px solid #0d2620; }
.ementa-head { display: flex; align-items: center; gap: 8px; font-family: Georgia, serif; font-weight: 700; font-size: 15px; margin-bottom: 10px; }
.ementa-head img { border-radius: 7px; }
.ementa-head em { margin-left: auto; font-style: normal; font-family: Inter, sans-serif; font-size: 10px; color: #4b6b61; }
.ementa-item { display: flex; justify-content: space-between; font-size: 12.5px; padding: 8px 0; border-bottom: 1px dashed #d6d0bd; }
.ementa-item b { color: #173f35; }
.ementa-btn { margin-top: 12px; text-align: center; font-size: 12px; font-weight: 700; padding: 9px; border-radius: 10px; background: #173f35; color: #f6f3e9; }
.ementa-ticket { align-self: flex-end; margin-bottom: 20px; background: #0d2620; border: 1px solid #2f6b5b; border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; color: #f6f3e9; box-shadow: 0 10px 30px -10px rgba(0, 0, 0, .6); }
.ementa-ticket .mono { font-size: 10px; color: #7fd1b2; letter-spacing: .1em; }
.ementa-ticket strong { font-size: 13px; }
.ementa-ticket small { font-size: 11px; color: #9fbfb4; }

/* Games */
.section-games { background: linear-gradient(180deg, var(--bg), #0d1a14 60%, var(--bg)); }
.section-games .eyebrow { color: #86efac; }
.game { display: grid; grid-template-columns: 1.15fr 1fr; background: var(--surface); border: 1px solid rgba(134, 239, 172, .25); border-radius: 22px; overflow: hidden; }
.game-visual { background: radial-gradient(ellipse at 50% 30%, #4a7650, #3b6442 75%); display: flex; align-items: flex-end; }
.game-visual img { width: 100%; height: auto; display: block; }
.game-body { padding: 36px; display: flex; flex-direction: column; gap: 18px; }
.game-title { display: flex; align-items: center; gap: 14px; }
.game-title img { border-radius: 14px; }
.game-title h3 { font-size: 26px; margin: 0; }
.game-sub { color: var(--muted); font-size: 14px; }
.game-body > p { color: var(--muted); }
.game-facts { display: flex; gap: 12px; flex-wrap: wrap; }
.game-facts li { flex: 1; min-width: 90px; background: var(--bg-alt); border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; }
.game-facts strong { font-size: 22px; color: #86efac; }
.game-facts span { font-size: 12.5px; color: var(--muted); }
.game .stack { margin-top: 0; }
.game-soon { color: #86efac !important; font-weight: 600; font-size: 15px; }

@media (max-width: 980px) {
  .projects, .game { grid-template-columns: 1fr; }
  .game-visual { aspect-ratio: 1200 / 630; }
}
@media (max-width: 760px) {
  .project-body, .game-body { padding: 22px; }
  .project-visual { height: 240px; }
  .ementa-ticket { display: none; }
}
