/* =========================================================
   REKTIOM — layout: boot, nav, hero, marquee, section heads, footer
   ========================================================= */

/* ---------- BOOT ---------- */
.boot {
  position: fixed; inset: 0; z-index: 500; background: var(--bg);
  display: grid; place-items: center; padding: var(--pad);
  transition: opacity .5s var(--ease), visibility .5s;
}
.boot.is-done { opacity: 0; visibility: hidden; pointer-events: none; }
.boot.is-done .boot__inner { transform: scale(1.04); filter: blur(2px); }
.boot__inner { width: min(560px, 100%); transition: transform .5s var(--ease), filter .5s; }
.boot__logo {
  font-family: var(--f-display); font-stretch: 125%; font-weight: 900; font-size: clamp(40px, 9vw, 76px);
  letter-spacing: -0.03em; line-height: .9; margin-bottom: 28px;
}
.boot__logo { animation: bootFlicker 2.4s steps(1) infinite; }
.boot__logo::before, .boot__logo::after { opacity: .85; animation: glitchA .5s steps(2) infinite; }
.boot__logo::after { animation-name: glitchB; }
@keyframes bootFlicker { 0%, 100% { opacity: 1; } 7% { opacity: .6; } 9% { opacity: 1; } 51% { opacity: .85; } 53% { opacity: 1; } }
.boot__log {
  font-family: var(--f-mono); font-size: 13px; line-height: 1.8; color: var(--green); min-height: 11em;
  margin: 0 0 22px; white-space: pre-wrap; text-shadow: 0 0 10px rgba(57,255,101,.35);
}
.boot__log .muted { color: var(--dim); text-shadow: none; }
.boot__bar { height: 4px; background: rgba(255,255,255,.06); position: relative; overflow: hidden; }
.boot__fill { position: absolute; inset: 0; background: var(--green); transform-origin: left; transform: scaleX(0); box-shadow: 0 0 12px var(--green); }
.boot__meta { display: flex; justify-content: space-between; margin-top: 10px; font-family: var(--f-mono); font-size: 11px; color: var(--muted); letter-spacing: .08em; }
.boot__skip {
  position: absolute; right: 20px; bottom: 20px; font-family: var(--f-mono); font-size: 11px; letter-spacing: .1em;
  color: var(--muted); padding: 8px 10px; border: 1px solid var(--line-2);
}
.boot__skip:hover { color: var(--green); border-color: var(--green); }
.boot__skip kbd { font-family: inherit; opacity: .6; margin-left: 6px; }

/* ---------- NAV ---------- */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 100;
  background: rgba(5,5,5,.78); backdrop-filter: blur(12px) saturate(1.2); -webkit-backdrop-filter: blur(12px) saturate(1.2);
  border-bottom: 1px solid var(--line);
}
.nav__inner {
  max-width: var(--max); margin: 0 auto; padding: 0 var(--pad); height: var(--nav-h);
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px;
}
.logo {
  justify-self: start; font-family: var(--f-display); font-stretch: 125%; font-weight: 900; font-size: 20px;
  letter-spacing: -0.02em; line-height: 1;
}
.logo--lg { font-size: clamp(40px, 7vw, 88px); letter-spacing: -0.04em; }
.logo__cursor { color: var(--green); animation: blink 1.05s steps(1) infinite; }
.nav__links { display: flex; gap: 4px; }
.nav__links a {
  position: relative; font-family: var(--f-mono); font-size: 12px; letter-spacing: .12em; color: var(--text-2);
  padding: 8px 14px; transition: color .2s;
}
.nav__links a::before { content: "["; opacity: 0; margin-right: 4px; color: var(--green); transition: opacity .2s; }
.nav__links a::after { content: "]"; opacity: 0; margin-left: 4px; color: var(--green); transition: opacity .2s; }
.nav__links a:hover, .nav__links a.is-active { color: var(--text); }
.nav__links a:hover::before, .nav__links a:hover::after, .nav__links a.is-active::before, .nav__links a.is-active::after { opacity: 1; }
.nav__right { justify-self: end; display: flex; align-items: center; gap: 10px; }
.sfx-toggle { font-family: var(--f-mono); font-size: 11px; color: var(--muted); height: 30px; padding: 0 8px; border: 1px solid transparent; letter-spacing: .06em; }
.sfx-toggle b { font-weight: 700; margin-left: 4px; }
.sfx-toggle:hover { border-color: var(--line-2); color: var(--text); }
.sfx-toggle[aria-pressed="true"] b { color: var(--green); }
.burger { display: none; width: 40px; height: 40px; position: relative; border: 1px solid var(--line-2); }
.burger span { position: absolute; left: 11px; right: 11px; height: 1.5px; background: var(--text); transition: transform .3s var(--ease), top .3s var(--ease); }
.burger span:first-child { top: 15px; }
.burger span:last-child { top: 23px; }
.burger[aria-expanded="true"] span:first-child { top: 19px; transform: rotate(45deg); }
.burger[aria-expanded="true"] span:last-child { top: 19px; transform: rotate(-45deg); }

.nav__tape { height: var(--tape-h); border-top: 1px solid var(--line); overflow: hidden; position: relative; }
.nav__tape::before, .nav__tape::after { content: ""; position: absolute; top: 0; bottom: 0; width: 60px; z-index: 1; }
.nav__tape::before { left: 0; background: linear-gradient(90deg, var(--bg), transparent); }
.nav__tape::after { right: 0; background: linear-gradient(-90deg, var(--bg), transparent); }
.tape { display: flex; width: max-content; height: 100%; align-items: center; animation: tape 60s linear infinite; font-family: var(--f-mono); font-size: 11px; }
.tape:hover { animation-play-state: paused; }
.tape__item { display: inline-flex; gap: 8px; padding: 0 18px; border-right: 1px solid var(--line); white-space: nowrap; color: var(--text-2); }
.tape__item b { font-weight: 500; color: var(--text); }
.tape__item .up { color: var(--green); }
.tape__item .dn { color: var(--red); }
.tape__demo { color: #ffb020; font-weight: 700; letter-spacing: .1em; }
@keyframes tape { to { transform: translateX(-50%); } }

.mobile-menu {
  position: fixed; inset: calc(var(--nav-h)) 0 0; z-index: 99; background: var(--bg);
  display: flex; flex-direction: column; justify-content: space-between; padding: 32px var(--pad) 40px;
  border-top: 1px solid var(--line);
}
.mobile-menu[hidden] { display: none; }
.mobile-menu nav { display: grid; }
.mobile-menu nav a {
  font-family: var(--f-display); font-stretch: 125%; font-weight: 900; font-size: clamp(34px, 11vw, 56px);
  letter-spacing: -0.03em; line-height: 1.1; padding: 10px 0; border-bottom: 1px solid var(--line);
  display: flex; align-items: baseline; gap: 16px; animation: menuIn .5s var(--ease) both;
}
.mobile-menu nav a:nth-child(2) { animation-delay: .05s; } .mobile-menu nav a:nth-child(3) { animation-delay: .1s; } .mobile-menu nav a:nth-child(4) { animation-delay: .15s; }
.mobile-menu nav a small { font-family: var(--f-mono); font-size: 12px; color: var(--green); font-weight: 400; }
.mobile-menu nav a:active { color: var(--green); }
.mobile-menu__foot { display: grid; gap: 16px; }
.mobile-menu__foot p { font-size: 12px; }
@keyframes menuIn { from { opacity: 0; transform: translateY(12px); } }

/* ---------- HERO ---------- */
.hero {
  position: relative; min-height: 100svh; padding-top: calc(var(--nav-h) + var(--tape-h));
  display: flex; flex-direction: column; overflow: hidden; isolation: isolate;
}
.hero__candles { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -2; opacity: .5; }
.hero__grid {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    linear-gradient(var(--line) 1px, transparent 1px) 0 0 / 100% 80px,
    linear-gradient(90deg, var(--line) 1px, transparent 1px) 0 0 / 80px 100%;
  mask-image: radial-gradient(90% 80% at 60% 40%, #000 20%, transparent 80%);
  -webkit-mask-image: radial-gradient(90% 80% at 60% 40%, #000 20%, transparent 80%);
}
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(90deg, var(--bg) 0%, rgba(5,5,5,.85) 35%, rgba(5,5,5,.2) 70%, rgba(5,5,5,.6) 100%),
              linear-gradient(0deg, var(--bg) 0%, transparent 25%);
}
.hero__copy { container-type: inline-size; min-width: 0; }
.hero__inner {
  flex: 1; display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); align-items: center;
  gap: clamp(24px, 4vw, 64px); padding-top: clamp(32px, 6vh, 72px); padding-bottom: clamp(32px, 5vh, 56px);
}
.prompt { font-size: clamp(12px, 1.1vw, 14px); letter-spacing: .14em; color: var(--text-2); margin-bottom: 18px; }
.hero__title {
  font-family: var(--f-display); font-stretch: 125%; font-weight: 900;
  font-size: clamp(48px, 10.4vw, 172px); font-size: min(15cqi, 172px); line-height: .82; letter-spacing: -0.055em;
  margin-left: -0.04em; color: #f2f2f2;
  text-shadow: 0 0 60px rgba(57,255,101,.08);
}
.hero__sub {
  margin-top: clamp(14px, 2vh, 24px); font-family: var(--f-mono); font-weight: 700;
  font-size: clamp(13px, 1.35vw, 18px); letter-spacing: .32em; color: var(--purple);
}
.hero__slogan {
  margin-top: clamp(20px, 3vh, 36px); font-family: var(--f-display); font-stretch: 100%; font-weight: 800;
  font-size: clamp(30px, 3.9vw, 62px); line-height: .98; letter-spacing: -0.03em;
}
.hero__slogan .line { display: block; overflow: hidden; }
.hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: clamp(24px, 4vh, 40px); }
.ca {
  margin-top: 22px; display: inline-grid; grid-template-columns: auto 1fr auto; align-items: center;
  border: 1px solid var(--line-2); background: rgba(10,10,12,.7); max-width: 100%;
}
.ca__label { font-size: 10.5px; letter-spacing: .14em; padding: 0 12px; border-right: 1px solid var(--line-2); height: 100%; display: flex; align-items: center; }
.ca__value { font-family: var(--f-mono); font-size: 12px; padding: 11px 14px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.ca__copy { display: flex; align-items: center; gap: 6px; height: 100%; padding: 0 14px; border-left: 1px solid var(--line-2); font-family: var(--f-mono); font-size: 11px; letter-spacing: .1em; color: var(--text); }
.ca__copy:hover:not([disabled]) { background: var(--green); color: #000; }
.ca__copy[disabled] { color: var(--dim); cursor: not-allowed; }

.hero__station { position: relative; padding-bottom: 72px; }
.station { position: relative; border: 1px solid var(--line-2); background: var(--panel); box-shadow: 0 40px 120px rgba(0,0,0,.7), 0 0 0 1px rgba(0,0,0,.6); }
.station::before { content: ""; position: absolute; inset: -1px; border: 1px solid transparent; background: linear-gradient(135deg, rgba(139,53,255,.5), transparent 30%, transparent 70%, rgba(57,255,101,.35)) border-box; -webkit-mask: linear-gradient(#000 0 0) padding-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; pointer-events: none; }
.station__bar { display: flex; justify-content: space-between; gap: 12px; padding: 9px 12px; font-size: 10.5px; letter-spacing: .1em; border-bottom: 1px solid var(--line-2); }
.station__screen { aspect-ratio: 376 / 328; max-height: 62vh; }
.station__screen img { transform: scale(1.02); transition: transform 1.2s var(--ease); }
.station:hover .station__screen img { transform: scale(1.05); }
.station__hud { position: absolute; left: 12px; bottom: 12px; display: grid; gap: 2px; font-size: 10.5px; letter-spacing: .08em; z-index: 2; text-shadow: 0 1px 0 #000; }
.station__hud b { font-weight: 700; }
.station__rec { position: absolute; right: 12px; top: 12px; z-index: 2; font-size: 10.5px; letter-spacing: .1em; }
.station__desk { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 1px; background: var(--line-2); border-top: 1px solid var(--line-2); }
.station__desk span { height: 14px; background: repeating-linear-gradient(90deg, #0d0d10 0 6px, #111115 6px 7px); }

.hero__term { position: absolute; left: -12%; bottom: 0; width: min(440px, 92%); z-index: 3; }

.hero__foot {
  display: flex; justify-content: space-between; gap: 16px; padding-top: 14px; padding-bottom: 18px;
  font-size: 10.5px; letter-spacing: .14em; color: var(--muted); border-top: 1px solid var(--line);
}

/* ---------- MARQUEE ---------- */
.marquee { border-block: 1px solid var(--line-2); overflow: hidden; background: var(--green); color: #000; }
.marquee__track {
  display: flex; align-items: center; gap: 28px; width: max-content; padding: 14px 0;
  font-family: var(--f-display); font-stretch: 125%; font-weight: 900; font-size: clamp(18px, 2.2vw, 30px); letter-spacing: -0.02em;
  animation: tape 38s linear infinite;
}
.marquee__track i { font-style: normal; font-family: var(--f-mono); font-size: .7em; }

/* ---------- SECTION SCAFFOLD ---------- */
.section { position: relative; padding: clamp(80px, 12vw, 160px) 0; border-bottom: 1px solid var(--line); }
.section-head { margin-bottom: clamp(36px, 5vw, 64px); max-width: 980px; }
.section-head--row { max-width: none; display: flex; justify-content: space-between; align-items: end; gap: 32px; }
.section-head--row .section-lede { max-width: 380px; }
.eyebrow { font-size: 11.5px; letter-spacing: .18em; color: var(--muted); margin-bottom: 18px; }
.section-title {
  font-family: var(--f-display); font-stretch: 125%; font-weight: 900; font-size: clamp(40px, 6.4vw, 104px);
  line-height: .9; letter-spacing: -0.045em;
}
.section-title--xl { font-size: clamp(48px, 10vw, 168px); }
.section-title .outline { color: transparent; -webkit-text-stroke: 1.5px var(--text); }
.section-lede { margin-top: 20px; color: var(--text-2); font-size: clamp(15px, 1.2vw, 17px); max-width: 620px; }

/* reveal on scroll */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }

/* ---------- FOOTER ---------- */
.footer { padding: clamp(64px, 9vw, 120px) 0 28px; background: linear-gradient(180deg, var(--bg), #000); }
.footer__top { display: flex; justify-content: space-between; align-items: end; gap: 32px; flex-wrap: wrap; padding-bottom: 36px; border-bottom: 1px solid var(--line); }
.footer__slogan { margin-top: 14px; font-family: var(--f-mono); font-size: 13px; letter-spacing: .2em; color: var(--green); }
.footer__links { display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: 12px; letter-spacing: .12em; }
.footer__links a { color: var(--text-2); transition: color .2s; }
.footer__links a:hover:not(.is-pending) { color: var(--green); }
.footer__links a.is-pending { color: var(--dim); }
.footer__disclaimer { padding: 28px 0; max-width: 820px; color: var(--muted); font-size: 13.5px; }
.footer__bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 10.5px; letter-spacing: .12em; color: var(--dim); padding-top: 20px; border-top: 1px solid var(--line); }
.footer__bottom a:hover { color: var(--green); }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1100px) {
  .nav__links { display: none; }
  .nav__inner { grid-template-columns: 1fr auto; }
  .burger { display: inline-block; }
  .hero__inner { grid-template-columns: 1fr; }
  .hero__station { max-width: 620px; padding-bottom: 0; }
  .hero__term { position: relative; left: auto; bottom: auto; width: 100%; margin-top: -40px; margin-left: 24px; width: calc(100% - 24px); }
  .hero::after { background: linear-gradient(180deg, rgba(5,5,5,.6), rgba(5,5,5,.9) 60%, var(--bg)); }
}
@media (max-width: 720px) {
  :root { --nav-h: 56px; }
  .chip--net, .sfx-toggle { display: none; }
  .nav__right .btn { display: none; }
  .hero__title { font-size: min(17cqi, 120px); font-stretch: 100%; }
  .section-title, .boot__logo, .logo--lg { font-stretch: 100%; }
  .section-title { font-size: clamp(34px, 11vw, 60px); }
  .section-title--xl { font-size: clamp(40px, 13vw, 72px); }
  .hero__ctas .btn { flex: 1 1 100%; }
  .ca { display: grid; width: 100%; }
  .hero__term { margin-left: 12px; width: calc(100% - 12px); margin-top: -28px; }
  .hero__foot-mid { display: none; }
  .section-head--row { display: block; }
  .station__bar span:last-child { display: none; }
}
