:root {
  --bg: #020304;
  --bg2: #070a0d;
  --text: #eaeef3;
  --muted: #778092;
  --accent: #8fe3ff;
  --line: rgba(255,255,255,.09);
  --ease: cubic-bezier(.22, 1, .36, 1);
  --display: "Space Grotesk", system-ui, sans-serif;
  --body: "Space Grotesk", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --pad: clamp(20px, 5vw, 60px);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg); color: var(--text);
  font-family: var(--body); font-weight: 300; line-height: 1.7;
  overflow-x: hidden; -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
::selection { background: var(--accent); color: #001018; }

/* ---------- Chrome ---------- */
.progress {
  position: fixed; top: 0; left: 0; height: 1px; width: 100%; z-index: 100;
  background: var(--accent); box-shadow: 0 0 10px var(--accent);
  transform-origin: 0 50%; transform: scaleX(0);
}
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; justify-content: space-between; align-items: center;
  padding: 22px var(--pad); border-bottom: 1px solid transparent;
  transition: background .5s var(--ease), backdrop-filter .5s, padding .5s var(--ease), border-color .5s;
}
.nav.scrolled { background: rgba(2,3,4,.72); backdrop-filter: blur(16px); padding-top: 14px; padding-bottom: 14px; border-color: var(--line); }
.logo { font-family: var(--mono); font-weight: 500; letter-spacing: .3em; font-size: .85rem; }
.logo span { color: var(--accent); }
.nav nav { display: flex; align-items: center; gap: clamp(14px, 3vw, 34px); }
.nav nav a {
  position: relative; font-family: var(--mono); font-size: .68rem; text-transform: uppercase;
  letter-spacing: .22em; color: var(--muted); transition: color .3s;
}
.nav nav a::after {
  content: ""; position: absolute; left: 0; bottom: -6px; height: 1px; width: 100%;
  background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .4s var(--ease);
}
.nav nav a:hover { color: var(--text); }
.nav nav a:hover::after { transform: scaleX(1); }
.nav .nav-cta { color: var(--accent); border: 1px solid rgba(143,227,255,.35); padding: 6px 14px; }
.nav .nav-cta::after { display: none; }
.nav .nav-cta:hover { background: var(--accent); color: #001018; }

/* ---------- Panels ---------- */
.panel { position: relative; min-height: 100vh; min-height: 100svh; display: grid; place-items: center; overflow: hidden; text-align: center; }
.bg-media {
  position: absolute; inset: -8% 0; width: 100%; height: 116%;
  object-fit: cover; background-size: cover; background-position: center; background-color: var(--bg2);
  opacity: 0; transition: opacity 1.4s var(--ease); will-change: transform; filter: grayscale(.6) contrast(1.1);
}
.bg-media.ready, .bg-media.img { opacity: .75; }
.scrim {
  position: absolute; inset: 0;
  background: linear-gradient(to bottom, rgba(2,3,4,.6), transparent 30%, transparent 70%, var(--bg));
}
.scene { position: absolute; inset: 0; width: 100%; height: 100%; }
.grid-bg {
  position: absolute; inset: 0; opacity: .5;
  background-image:
    linear-gradient(rgba(143,227,255,.07) 1px, transparent 1px), linear-gradient(90deg, rgba(143,227,255,.07) 1px, transparent 1px),
    linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 120px 120px, 120px 120px, 24px 24px, 24px 24px;
  mask-image: radial-gradient(ellipse at center, #000 10%, transparent 72%);
}
@keyframes gridMove { to { background-position: 120px 120px, 120px 120px, 24px 24px, 24px 24px; } }

/* HUD */
.hud {
  position: absolute; z-index: 3; font-family: var(--mono); font-size: .62rem; line-height: 1.9;
  letter-spacing: .2em; color: var(--muted); text-transform: uppercase;
  opacity: 0; animation: fadeIn 1.6s var(--ease) 3.9s forwards;
}
.hud b { font-weight: 400; }
.hud .online { color: #4ade80; text-shadow: 0 0 10px rgba(74,222,128,.35); animation: alpha 4s ease-in-out infinite; }
@keyframes alpha { 0%, 100% { opacity: 1; } 50% { opacity: .95; } }
.hud::before { content: ""; position: absolute; width: 14px; height: 14px; border: 0 solid var(--accent); opacity: .7; }
.hud.tl { top: 84px; left: var(--pad); padding: 12px 0 0 18px; }
.hud.tr { top: 84px; right: var(--pad); padding: 12px 18px 0 0; text-align: right; }
.hud.bl { bottom: 32px; left: var(--pad); padding: 0 0 12px 18px; }
.hud.br { bottom: 32px; right: var(--pad); padding: 0 18px 12px 0; text-align: right; }
.hud.tl::before { top: 0; left: 0; border-width: 1px 0 0 1px; }
.hud.tr::before { top: 0; right: 0; border-width: 1px 1px 0 0; }
.hud.bl::before { bottom: 0; left: 0; border-width: 0 0 1px 1px; }
.hud.br::before { bottom: 0; right: 0; border-width: 0 1px 1px 0; }

.hero-inner { position: relative; z-index: 3; padding: 0 20px; }
.eyebrow { font-family: var(--mono); font-size: .7rem; letter-spacing: .5em; text-transform: uppercase; color: var(--accent); margin-bottom: 22px; }
h1 {
  font-family: var(--display); font-weight: 600; white-space: nowrap;
  font-size: clamp(3rem, 13vw, 10rem); line-height: 1; letter-spacing: .08em; padding-left: .08em;
}
.tag { font-family: var(--mono); color: var(--muted); margin-top: 26px; font-size: clamp(.68rem, 1.6vw, .85rem); letter-spacing: .18em; text-transform: uppercase; }

/* ---------- Intro: LUKE -> LUK3 -> LUK303 (pure CSS, no JS needed) ---------- */
.logo-anim .ltr, .logo-anim .tail { display: inline-block; }
.logo-anim .ltr { opacity: 0; transform: translateY(.25em); filter: blur(12px); animation: letterIn .9s var(--ease) forwards; }
.logo-anim .ltr:nth-child(1) { animation-delay: .3s; }
.logo-anim .ltr:nth-child(2) { animation-delay: .45s; }
.logo-anim .ltr:nth-child(3) { animation-delay: .6s; }
.logo-anim .ltr:nth-child(4) { animation-delay: .75s; }
@keyframes letterIn { to { opacity: 1; transform: none; filter: none; } }

/* E and 3 share one cell; E glitches out, 3 glitches in */
.logo-anim .swap { display: inline-grid; }
.logo-anim .g { grid-area: 1 / 1; font-style: normal; text-align: center; }
.logo-anim .g.e { animation: eOut .6s steps(1, end) 2s forwards; }
.logo-anim .g.three { color: var(--accent); opacity: 0; animation: threeIn 1.4s steps(1, end) 2s forwards; }
@keyframes eOut {
  0% { opacity: 1; } 15% { opacity: 0; } 30% { opacity: 1; transform: translateX(-.04em); color: var(--accent); }
  50% { opacity: 0; } 65% { opacity: .7; color: var(--accent); } 100% { opacity: 0; }
}
@keyframes threeIn {
  0% { opacity: 0; } 20% { opacity: 1; color: var(--accent); text-shadow: 0 0 40px var(--accent); }
  35% { opacity: .1; } 50% { opacity: 1; color: #fff; text-shadow: 0 0 40px var(--accent); transform: translateX(.03em); }
  70% { opacity: 1; color: var(--accent); transform: none; } 100% { opacity: 1; color: var(--accent); text-shadow: none; }
}

/* the tail keeps its final width from the start, so the logo never shifts */
.logo-anim .tail { color: var(--accent); vertical-align: bottom; white-space: nowrap; padding-right: .08em; }
.logo-anim .tail span { display: inline-block; opacity: 0; transform: translateY(.3em); filter: blur(10px); animation: letterIn .9s var(--ease) forwards; }
.logo-anim .tail span:nth-child(1) { animation-delay: 2.8s; }
.logo-anim .tail span:nth-child(2) { animation-delay: 3s; }

.fade-in { opacity: 0; animation: fadeIn 1.2s var(--ease) var(--d, 0s) forwards; }
@keyframes fadeIn { to { opacity: 1; } }

.visual .big {
  position: relative; z-index: 2; font-family: var(--display); font-weight: 500; text-transform: uppercase;
  font-size: clamp(2.2rem, 8vw, 6.5rem); line-height: 1.05; letter-spacing: .06em;
}

/* ---------- Content ---------- */
.content { position: relative; z-index: 2; padding: clamp(90px, 16vh, 180px) 0; }
.wrap { width: min(1100px, 100% - 40px); margin: 0 auto; }
.wrap.two { display: grid; grid-template-columns: 1fr 1.2fr; gap: clamp(30px, 6vw, 90px); align-items: start; }
.wrap.center { text-align: center; }
h2 { font-family: var(--display); font-weight: 500; font-size: clamp(2rem, 5vw, 3.6rem); line-height: 1.1; letter-spacing: -.01em; }
.content p { color: var(--muted); font-size: 1.05rem; }
.content .eyebrow { color: var(--accent); }
.content a:not(.btn):not(.track) { border-bottom: 1px solid var(--line); transition: color .3s, border-color .3s; }
.content a:not(.btn):not(.track):hover { color: var(--accent); border-color: var(--accent); }

.facts { list-style: none; margin-top: 28px; border-top: 1px solid var(--line); }
.facts li { display: flex; gap: 20px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.facts b { width: 110px; flex: none; font-family: var(--mono); font-weight: 400; color: var(--muted); text-transform: uppercase; font-size: .65rem; letter-spacing: .22em; padding-top: 5px; }

.tracks { margin-top: 50px; border-top: 1px solid var(--line); }
.track {
  position: relative; display: grid; grid-template-columns: 60px 1.4fr 1fr auto; gap: 20px; align-items: center;
  padding: 26px 8px; border-bottom: 1px solid var(--line);
  transition: background .5s var(--ease), padding .5s var(--ease);
}
.track::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: var(--accent); transform: scaleY(0); transition: transform .5s var(--ease); }
.track:hover { background: linear-gradient(90deg, rgba(143,227,255,.06), transparent 70%); padding-left: 24px; }
.track:hover::before { transform: scaleY(1); }
.track .num { font-family: var(--mono); font-size: .7rem; letter-spacing: .3em; color: var(--accent); }
.track .name { font-size: clamp(1.15rem, 2.6vw, 1.7rem); font-weight: 500; color: var(--text); }
.track .meta { font-family: var(--mono); font-size: .68rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.track .go { font-family: var(--mono); font-size: .7rem; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); transition: color .3s, transform .5s var(--ease); }
.track:hover .go { color: var(--accent); transform: translateX(6px); }
.hint { margin-top: 40px; font-family: var(--mono); font-size: .68rem !important; letter-spacing: .1em; opacity: .5; }

.btn {
  display: inline-block; margin-top: 22px; padding: 11px 24px; border: 1px solid var(--line); color: var(--text);
  font-family: var(--mono); font-size: .7rem; letter-spacing: .22em; text-transform: uppercase;
  transition: background .4s var(--ease), color .4s var(--ease), border-color .4s, box-shadow .4s var(--ease);
}
.btn:hover { background: var(--accent); border-color: var(--accent); color: #001018; box-shadow: 0 0 40px rgba(143,227,255,.35); }
.big-btn { font-size: clamp(.75rem, 2vw, 1rem); padding: 16px 38px; margin-top: 30px; }
.social { display: flex; gap: 28px; justify-content: center; flex-wrap: wrap; margin-top: 46px; }
.social a { font-family: var(--mono); color: var(--muted); font-size: .68rem; letter-spacing: .22em; text-transform: uppercase; transition: color .3s; }
.social a:hover { color: var(--accent); }
footer { margin-top: 110px; text-align: center; font-family: var(--mono); color: var(--muted); font-size: .65rem; letter-spacing: .25em; opacity: .6; }

/* ---------- Scroll reveal ---------- */
.reveal { opacity: 0; transform: translateY(40px); filter: blur(6px); transition: opacity 1s var(--ease), transform 1s var(--ease), filter 1s var(--ease); }
.reveal.delay { transition-delay: .15s; }
.reveal.delay2 { transition-delay: .3s; }
.reveal.in { opacity: 1; transform: none; filter: none; }

@media (max-width: 760px) {
  .wrap.two { grid-template-columns: 1fr; }
  .nav nav a:nth-child(-n+3) { display: none; }
  .hud.tl, .hud.tr { display: none; }
  .track { grid-template-columns: 40px 1fr auto; }
  .track .meta { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { transition: none; opacity: 1; transform: none; filter: none; }
  .grid-bg, 
  .logo-anim .ltr, .logo-anim .tail span, .fade-in, .hud { animation: none; opacity: 1; transform: none; filter: none; }
  .logo-anim .g.e { display: none; }
  .logo-anim .g.three { animation: none; opacity: 1; }
}


/* ---------- Occasional logo glitch: data-scan + precise slice cuts ---------- */
.logo-anim { position: relative; }
.logo-anim::before, .logo-anim::after {
  content: attr(data-text); position: absolute; inset: 0; padding-left: .08em; pointer-events: none; opacity: 0;
}
/* thin, cleanly cut slices of the word, shifted sideways in cyan */
.logo-anim::before { color: var(--accent); }
.logo-anim.fx::before { animation: cut .8s steps(1, end); }
@keyframes cut {
  0%   { opacity: .9; clip-path: inset(18% 0 78% 0); transform: translateX(-8px); }
  12%  { opacity: .9; clip-path: inset(62% 0 34% 0); transform: translateX(10px); }
  24%  { opacity: 0; }
  36%  { opacity: .9; clip-path: inset(38% 0 58% 0); transform: translateX(-12px); }
  48%  { opacity: .9; clip-path: inset(80% 0 14% 0); transform: translateX(6px); }
  60%  { opacity: 0; }
  72%  { opacity: .9; clip-path: inset(8% 0 88% 0); transform: translateX(9px); }
  84%  { opacity: 0; }
  100% { opacity: 0; }
}
/* a light beam scanning across the letters */
.logo-anim::after {
  color: transparent;
  background: linear-gradient(100deg, transparent 42%, #fff 50%, var(--accent) 54%, transparent 62%) 130% 0 / 260% 100% no-repeat;
  -webkit-background-clip: text; background-clip: text;
}
.logo-anim.fx::after { opacity: 1; animation: scan .8s cubic-bezier(.5, 0, .3, 1) forwards; }
@keyframes scan { from { background-position: 130% 0; } to { background-position: -30% 0; } }
@media (prefers-reduced-motion: reduce) { .logo-anim.fx::before, .logo-anim.fx::after, .hud .online { animation: none; } }

/* SCROLL arrow: barely-there nudge */
.hud .arrow { display: inline-block; color: var(--accent); animation: nudge 3.2s ease-in-out infinite; }
@keyframes nudge { 0%, 60%, 100% { transform: translateY(0); opacity: .6; } 80% { transform: translateY(3px); opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .hud .arrow { animation: none; } }

/* "the dark." flickers like a failing light, now and then */
.dark { display: inline-block; }
.dark.fx { animation: lights 1.1s steps(1, end); }
@keyframes lights {
  0%   { opacity: 1; }
  8%   { opacity: .12; text-shadow: none; }
  14%  { opacity: 1; text-shadow: 0 0 24px rgba(143,227,255,.5); }
  22%  { opacity: .05; text-shadow: none; }
  30%  { opacity: .6; }
  36%  { opacity: 0; }
  62%  { opacity: 0; }
  68%  { opacity: .9; text-shadow: 0 0 30px rgba(143,227,255,.6); }
  74%  { opacity: .2; text-shadow: none; }
  82%  { opacity: 1; text-shadow: 0 0 18px rgba(143,227,255,.35); }
  100% { opacity: 1; text-shadow: none; }
}
@media (prefers-reduced-motion: reduce) { .dark.fx { animation: none; } }

/* scroll-linked headings (JS sets --b / --g; without JS everything is visible) */
.visual .big .ln { display: block; }
/* "Sound is architecture.": built up from the ground line by line, framed by two guide lines */
.build .ln { clip-path: inset(calc((1 - var(--b, 1)) * 100%) 0 0 0); }
.build::before, .build::after {
  content: ""; position: absolute; left: 0; right: 0; height: 1px; background: rgba(143,227,255,.55);
  transform: translateX(var(--x, 0px)); opacity: var(--lo, 1);
}
.build::before { top: -.2em; --x: var(--x1, 0px); }
.build::after { bottom: -.2em; --x: var(--x2, 0px); }
/* "Live in the dark.": no movement, alpha 0 -> 100% while scrolling */


/* ---------- Pinned scroll scene: section holds while the lines fly in + glitch ---------- */
.pin { position: relative; height: var(--pinh, 360vh); }
#top { --pinh: 230vh; }
#pin1 { --pinh: 300vh; }
#visuals { --pinh: 260vh; }
.pin > .panel { position: sticky; top: 0; height: 100vh; height: 100svh; min-height: 0; }
.visual .big[data-fly] .ln, .build[data-fly]::before, .build[data-fly]::after { will-change: transform, opacity; }
@media (prefers-reduced-motion: reduce) {
  .pin { height: auto; }
  .pin > .panel { position: relative; height: auto; min-height: 100svh; }
}

/* "Live in the dark.": the section holds, the text emerges out of the dark (JS sets --a / --dim on the pinned section) */
.dim { position: absolute; inset: 0; background: #000; opacity: var(--dim, 0); pointer-events: none; }
.emerge { opacity: var(--a, 1); filter: blur(calc((1 - var(--a, 1)) * 14px)); }

/* "Sound is architecture.": rare, random glitch, independent of the scroll animation */
.build.gl .ln:nth-child(1) { animation: glA .45s steps(1, end); }
.build.gl .ln:nth-child(2) { animation: glB .45s steps(1, end); }
@keyframes glA {
  0% { transform: translateX(-5px); text-shadow: 4px 0 rgba(143,227,255,.6), -4px 0 rgba(255,255,255,.25); }
  25% { transform: translateX(4px); text-shadow: -3px 0 rgba(143,227,255,.6), 3px 0 rgba(255,255,255,.25); }
  50% { transform: translateX(-2px) skewX(-2deg); text-shadow: 2px 0 rgba(143,227,255,.5); }
  75% { transform: translateX(3px); text-shadow: -2px 0 rgba(143,227,255,.5); }
  100% { transform: none; text-shadow: none; }
}
@keyframes glB {
  0% { transform: translateX(5px); text-shadow: -4px 0 rgba(143,227,255,.6), 4px 0 rgba(255,255,255,.25); }
  30% { transform: translateX(-4px); text-shadow: 3px 0 rgba(143,227,255,.6); }
  60% { transform: translateX(2px) skewX(2deg); text-shadow: -2px 0 rgba(143,227,255,.5); }
  100% { transform: none; text-shadow: none; }
}
@media (prefers-reduced-motion: reduce) { .build.gl .ln { animation: none; } .emerge { filter: none; } }

/* Landing pin: the hero holds while the particles rise out of the screen (JS drives it) */
#top .hero-inner { will-change: transform, filter; }

/* ---------- Sound control (top right) ---------- */
.snd { display: flex; align-items: center; gap: 4px; margin-left: 6px; }
.snd button { display: grid; place-items: center; width: 34px; height: 34px; background: none; border: 1px solid transparent; color: var(--muted); cursor: pointer; transition: color .3s, border-color .3s; }
.snd button:hover, .snd button:focus-visible { color: var(--accent); border-color: rgba(143,227,255,.35); outline: none; }
.snd .w1, .snd .w2, .snd .x { opacity: 0; transition: opacity .3s; }
.snd[data-level="off"] .x { opacity: 1; }
.snd[data-level="low"] .w1, .snd[data-level="high"] .w1, .snd[data-level="high"] .w2 { opacity: 1; }
.snd[data-level="low"] button, .snd[data-level="high"] button { color: var(--accent); }
.snd input { -webkit-appearance: none; appearance: none; width: 0; height: 1px; margin: 0; padding: 0; opacity: 0; background: rgba(255,255,255,.25); cursor: pointer; transition: width .5s var(--ease), opacity .4s; }
.snd:hover input, .snd:focus-within input { width: 84px; opacity: 1; margin-right: 6px; }
.snd input::-webkit-slider-thumb { -webkit-appearance: none; width: 9px; height: 9px; background: var(--accent); border-radius: 50%; box-shadow: 0 0 8px rgba(143,227,255,.6); }
.snd input::-moz-range-thumb { width: 9px; height: 9px; background: var(--accent); border: 0; border-radius: 50%; }
@media (hover: none) { .snd input { display: none; } }

/* ---------- Soft light: gaussian falloff (no visible rings) + film grain to dither 8-bit banding ---------- */
.hero-inner::before {
  content: ""; position: absolute; left: 50%; top: 46%; z-index: -1; pointer-events: none;
  width: min(1200px, 130vw); height: min(560px, 70vh); transform: translate(-50%, -50%);
  background: radial-gradient(closest-side, rgba(143,227,255,0.0750) 0.0%, rgba(143,227,255,0.0738) 6.2%, rgba(143,227,255,0.0705) 12.5%, rgba(143,227,255,0.0652) 18.8%, rgba(143,227,255,0.0584) 25.0%, rgba(143,227,255,0.0507) 31.2%, rgba(143,227,255,0.0427) 37.5%, rgba(143,227,255,0.0349) 43.8%, rgba(143,227,255,0.0276) 50.0%, rgba(143,227,255,0.0212) 56.2%, rgba(143,227,255,0.0157) 62.5%, rgba(143,227,255,0.0113) 68.8%, rgba(143,227,255,0.0079) 75.0%, rgba(143,227,255,0.0053) 81.2%, rgba(143,227,255,0.0035) 87.5%, rgba(143,227,255,0.0022) 93.8%, rgba(143,227,255,0.0000) 100.0%);
  animation: breathe 9s ease-in-out infinite;
}
@keyframes breathe { 0%, 100% { opacity: .8; } 50% { opacity: 1; } }
body::after {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 90; opacity: .028;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .6 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
@media (prefers-reduced-motion: reduce) { .hero-inner::before { animation: none; } }
