/* ═══════════════════════════════════════════════════════════════
   HACK26 — design system
   Dark, energetic, terminal-tinged. Violet → cyan accent gradient.
   ═══════════════════════════════════════════════════════════════ */

:root {
  --bg: #06070d;
  --bg-2: #0b0e1a;
  --panel: rgba(255, 255, 255, 0.03);
  --panel-border: rgba(255, 255, 255, 0.08);
  --ink: #eef1ff;
  --muted: #97a0bf;
  --violet: #7c5cff;
  --cyan: #22d3ee;
  --amber: #fbbf24;
  --grad: linear-gradient(100deg, var(--violet), var(--cyan));
  --radius: 18px;
  --font-display: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection { background: var(--violet); color: #fff; }

.mono { font-family: var(--font-mono); }

.grad-text {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ── Buttons & chips ─────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 26px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn--primary {
  background: var(--grad);
  color: #fff;
  box-shadow: 0 0 24px rgba(124, 92, 255, 0.35);
}
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 0 36px rgba(34, 211, 238, 0.45); }
.btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--panel-border);
}
.btn--ghost:hover { background: rgba(255, 255, 255, 0.06); transform: translateY(-2px); }
.btn--sm { padding: 9px 18px; font-size: 13.5px; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--panel-border);
  background: var(--panel);
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--muted);
}
.chip--amber { border-color: rgba(251, 191, 36, 0.4); color: var(--amber); }

/* ── OKTA gate ───────────────────────────────────────────────── */
body.locked { overflow: hidden; }

.gate {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  background:
    radial-gradient(700px 400px at 50% 30%, rgba(124, 92, 255, 0.14), transparent),
    var(--bg);
  transition: opacity 0.4s ease;
}
.gate--open { opacity: 0; pointer-events: none; }

.gate__card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
  padding: 48px 56px;
  border-radius: 24px;
  border: 1px solid var(--panel-border);
  background: var(--panel);
  text-align: center;
}
.gate__logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 30px;
  letter-spacing: 0.04em;
}
.gate__status { color: var(--muted); font-size: 13px; letter-spacing: 0.08em; }

.nav__user { color: var(--muted); font-size: 12.5px; margin-left: auto; }
@media (max-width: 720px) { .nav__user { display: none; } }

/* ── Nav ─────────────────────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px clamp(16px, 4vw, 48px);
  background: rgba(6, 7, 13, 0.7);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s ease;
}
.nav.scrolled { border-bottom-color: var(--panel-border); }

.nav__logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: 0.04em;
  color: var(--ink);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav__logo-mark { color: var(--cyan); font-size: 14px; }

.nav__links { display: flex; gap: clamp(12px, 2.5vw, 32px); }
.nav__links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color 0.15s ease;
}
.nav__links a:hover { color: var(--ink); }

@media (max-width: 720px) { .nav__links { display: none; } }

/* ── Hero ────────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 120px 20px 0;
  overflow: hidden;
}

#starfield { position: absolute; inset: 0; width: 100%; height: 100%; }

.hero__glow {
  position: absolute;
  width: 900px; height: 900px;
  top: -420px; left: 50%;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(124, 92, 255, 0.22), transparent 65%);
  pointer-events: none;
}

.hero__inner { position: relative; z-index: 2; max-width: 900px; }

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border-radius: 999px;
  border: 1px solid var(--panel-border);
  background: var(--panel);
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--muted);
  margin-bottom: 32px;
}
.pulse-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #34d399;
  animation: pulse-dot 2s infinite;
}
@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.6); }
  50% { box-shadow: 0 0 0 7px rgba(52, 211, 153, 0); }
}

.hero__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(64px, 15vw, 168px);
  line-height: 0.95;
  letter-spacing: -0.02em;
  margin-bottom: 28px;
  text-shadow: 0 0 80px rgba(124, 92, 255, 0.35);
}

.hero__tagline {
  font-size: clamp(19px, 3vw, 26px);
  color: var(--muted);
  margin-bottom: 30px;
}
.hero__tagline strong { color: var(--ink); }

.hero__meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-bottom: 42px;
}

/* Countdown */
.countdown {
  display: inline-flex;
  align-items: baseline;
  gap: clamp(8px, 2vw, 18px);
  padding: 22px clamp(20px, 4vw, 44px);
  border-radius: var(--radius);
  border: 1px solid var(--panel-border);
  background: rgba(11, 14, 26, 0.6);
  backdrop-filter: blur(8px);
  margin-bottom: 42px;
}
.countdown__cell { display: flex; flex-direction: column; align-items: center; min-width: 62px; }
.countdown__num {
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: clamp(34px, 6vw, 54px);
  line-height: 1;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-variant-numeric: tabular-nums;
}
.countdown__label {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--muted);
  margin-top: 8px;
}
.countdown__sep { font-family: var(--font-mono); font-size: 34px; color: var(--panel-border); }

.hero__ctas { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-bottom: 80px; }

/* Marquee */
.marquee {
  position: relative;
  z-index: 2;
  width: 100%;
  border-top: 1px solid var(--panel-border);
  border-bottom: 1px solid var(--panel-border);
  background: rgba(11, 14, 26, 0.5);
  overflow: hidden;
  padding: 14px 0;
}
.marquee__track {
  display: flex;
  white-space: nowrap;
  animation: marquee 30s linear infinite;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.3em;
  color: var(--muted);
}
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ── Stats ───────────────────────────────────────────────────── */
.stats { padding: clamp(48px, 8vw, 90px) clamp(20px, 5vw, 64px); }
.stats__grid {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
}
.stat {
  padding: 30px;
  border-radius: var(--radius);
  border: 1px solid var(--panel-border);
  background: var(--panel);
  text-align: center;
}
.stat__num {
  display: block;
  font-size: 46px;
  font-weight: 600;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.stat__label { color: var(--muted); font-size: 14px; }

/* ── Sections ────────────────────────────────────────────────── */
.section {
  max-width: 1100px;
  margin: 0 auto;
  padding: clamp(64px, 10vw, 120px) clamp(20px, 5vw, 64px);
}
.section__kicker { color: var(--cyan); font-size: 13px; margin-bottom: 14px; letter-spacing: 0.08em; }
.section__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(32px, 6vw, 54px);
  letter-spacing: -0.02em;
  margin-bottom: clamp(32px, 5vw, 56px);
}

/* ── About ───────────────────────────────────────────────────── */
.about__grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(28px, 5vw, 64px);
  align-items: start;
}
@media (max-width: 860px) { .about__grid { grid-template-columns: 1fr; } }

.about__copy p { color: var(--muted); margin-bottom: 18px; font-size: 17px; }
.about__copy strong { color: var(--ink); }

.about__cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
@media (max-width: 480px) { .about__cards { grid-template-columns: 1fr; } }

.mini-card {
  padding: 22px;
  border-radius: var(--radius);
  border: 1px solid var(--panel-border);
  background: var(--panel);
  transition: transform 0.2s ease, border-color 0.2s ease;
}
.mini-card:hover { transform: translateY(-4px); border-color: rgba(124, 92, 255, 0.45); }
.mini-card__icon { font-size: 26px; display: block; margin-bottom: 10px; }
.mini-card h3 { font-family: var(--font-display); font-size: 16px; margin-bottom: 6px; }
.mini-card p { color: var(--muted); font-size: 13.5px; line-height: 1.55; }

/* ── Tracks ──────────────────────────────────────────────────── */
.tracks__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}
.track {
  position: relative;
  padding: 30px 26px;
  border-radius: var(--radius);
  border: 1px solid var(--panel-border);
  background: linear-gradient(160deg, rgba(124, 92, 255, 0.06), rgba(34, 211, 238, 0.03));
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.track:hover {
  transform: translateY(-6px);
  border-color: rgba(34, 211, 238, 0.5);
  box-shadow: 0 12px 40px rgba(124, 92, 255, 0.18);
}
.track__icon { font-size: 34px; display: block; margin-bottom: 16px; }
.track h3 { font-family: var(--font-display); font-size: 20px; margin-bottom: 10px; }
.track p { color: var(--muted); font-size: 14.5px; margin-bottom: 18px; }
.track__tag {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--cyan);
  border: 1px solid rgba(34, 211, 238, 0.3);
  border-radius: 999px;
  padding: 4px 10px;
}

/* ── Timeline ────────────────────────────────────────────────── */
.timeline { list-style: none; position: relative; padding-left: 36px; }
.timeline::before {
  content: "";
  position: absolute;
  left: 7px; top: 8px; bottom: 8px;
  width: 2px;
  background: linear-gradient(var(--violet), var(--cyan));
  opacity: 0.5;
}
.timeline__item { position: relative; padding-bottom: clamp(28px, 4vw, 44px); }
.timeline__item:last-child { padding-bottom: 0; }
.timeline__item::before {
  content: "";
  position: absolute;
  left: -36px; top: 7px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--bg);
  border: 3px solid var(--violet);
  box-shadow: 0 0 14px rgba(124, 92, 255, 0.6);
}
.timeline__item:last-child::before { border-color: var(--cyan); box-shadow: 0 0 14px rgba(34, 211, 238, 0.6); }
.timeline__date { color: var(--cyan); font-size: 12.5px; letter-spacing: 0.15em; }
.timeline__item h3 { font-family: var(--font-display); font-size: 21px; margin: 6px 0 8px; }
.timeline__item p { color: var(--muted); font-size: 15px; max-width: 560px; }

/* ── Prizes ──────────────────────────────────────────────────── */
.prizes__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 20px;
  margin-bottom: clamp(40px, 6vw, 72px);
}
.prize {
  position: relative;
  padding: 30px 26px;
  border-radius: var(--radius);
  border: 1px solid var(--panel-border);
  background: var(--panel);
  transition: transform 0.2s ease, border-color 0.2s ease;
}
.prize:hover { transform: translateY(-6px); }
.prize--gold {
  border-color: rgba(251, 191, 36, 0.45);
  background: linear-gradient(160deg, rgba(251, 191, 36, 0.08), rgba(251, 191, 36, 0.02));
}
.prize--gold:hover { box-shadow: 0 12px 44px rgba(251, 191, 36, 0.18); }
.prize__place {
  position: absolute;
  top: 18px; right: 20px;
  font-size: 13px;
  color: var(--muted);
  letter-spacing: 0.1em;
}
.prize--gold .prize__place { color: var(--amber); }
.prize__icon { font-size: 34px; display: block; margin-bottom: 14px; }
.prize h3 { font-family: var(--font-display); font-size: 19px; margin-bottom: 8px; }
.prize p { color: var(--muted); font-size: 14px; margin-bottom: 18px; }

/* Judging */
.judging {
  padding: clamp(28px, 4vw, 44px);
  border-radius: var(--radius);
  border: 1px solid var(--panel-border);
  background: var(--panel);
}
.judging__title { font-family: var(--font-display); font-size: 20px; margin-bottom: 26px; }
.judging__bars { display: grid; gap: 20px; }
.jbar__head {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  margin-bottom: 8px;
}
.jbar__head .mono { color: var(--cyan); font-size: 13px; }
.jbar__track {
  height: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
}
.jbar__fill {
  height: 100%;
  width: var(--w);
  border-radius: 999px;
  background: var(--grad);
  transform-origin: left;
  animation: grow 1.2s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
@keyframes grow { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* ── BMac voice section ──────────────────────────────────────── */
.section--bmac { text-align: center; }
.bmac__sub { color: var(--muted); max-width: 560px; margin: -20px auto 48px; }

.bmac__stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding: clamp(36px, 6vw, 64px) 24px;
  border-radius: 24px;
  border: 1px solid var(--panel-border);
  background:
    radial-gradient(600px 300px at 50% 0%, rgba(124, 92, 255, 0.1), transparent),
    var(--bg-2);
}

.orb {
  position: relative;
  width: 150px; height: 150px;
  border-radius: 50%;
  border: none;
  background: var(--grad);
  cursor: pointer;
  display: grid;
  place-items: center;
  box-shadow: 0 0 60px rgba(124, 92, 255, 0.45);
  transition: transform 0.2s ease, box-shadow 0.3s ease;
}
.orb:hover { transform: scale(1.05); }
.orb:active { transform: scale(0.97); }
.orb__core { font-size: 44px; }
.orb__ring {
  position: absolute;
  inset: -14px;
  border-radius: 50%;
  border: 2px solid rgba(124, 92, 255, 0.4);
  opacity: 0;
}
.orb__ring--2 { inset: -30px; border-color: rgba(34, 211, 238, 0.3); }

/* orb states */
.orb.connecting { animation: orb-breathe 1.2s ease-in-out infinite; }
.orb.live .orb__ring { animation: ring 2.4s ease-out infinite; }
.orb.live .orb__ring--2 { animation: ring 2.4s ease-out 0.6s infinite; }
.orb.speaking { box-shadow: 0 0 90px rgba(34, 211, 238, 0.7); animation: orb-talk 0.5s ease-in-out infinite; }
@keyframes orb-breathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.06); } }
@keyframes orb-talk { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.04); } }
@keyframes ring {
  0% { opacity: 0.9; transform: scale(0.85); }
  100% { opacity: 0; transform: scale(1.35); }
}

.bmac__status { color: var(--muted); font-size: 13px; letter-spacing: 0.08em; }

.bmac__captions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: min(620px, 100%);
  min-height: 20px;
}
.caption {
  padding: 12px 18px;
  border-radius: 14px;
  font-size: 14.5px;
  text-align: left;
  max-width: 85%;
  animation: caption-in 0.25s ease both;
}
.caption--ai {
  align-self: flex-start;
  background: rgba(124, 92, 255, 0.14);
  border: 1px solid rgba(124, 92, 255, 0.3);
}
.caption--user {
  align-self: flex-end;
  background: rgba(34, 211, 238, 0.1);
  border: 1px solid rgba(34, 211, 238, 0.28);
}
@keyframes caption-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.bmac__note { color: var(--muted); font-size: 12px; opacity: 0.7; }

/* ── FAQ ─────────────────────────────────────────────────────── */
.faq__list { display: grid; gap: 12px; max-width: 760px; }
.faq__item {
  border: 1px solid var(--panel-border);
  border-radius: 14px;
  background: var(--panel);
  overflow: hidden;
  transition: border-color 0.2s ease;
}
.faq__item[open] { border-color: rgba(124, 92, 255, 0.4); }
.faq__item summary {
  padding: 18px 22px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  list-style: none;
  position: relative;
  padding-right: 48px;
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after {
  content: "+";
  position: absolute;
  right: 22px; top: 50%;
  transform: translateY(-50%);
  font-family: var(--font-mono);
  font-size: 20px;
  color: var(--cyan);
  transition: transform 0.2s ease;
}
.faq__item[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq__item p { padding: 0 22px 20px; color: var(--muted); font-size: 15px; }

/* ── Footer ──────────────────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--panel-border);
  padding: 48px 24px 56px;
  text-align: center;
}
.footer__logo { font-family: var(--font-display); font-weight: 700; font-size: 18px; display: block; margin-bottom: 12px; }
.footer p { color: var(--muted); font-size: 13.5px; }
.footer__easter { margin-top: 16px; opacity: 0.45; font-size: 12px; }
.footer__build { margin-top: 14px; font-size: 12px; opacity: 0.55; letter-spacing: 0.04em; }

/* ── Scroll reveal ───────────────────────────────────────────── */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1); }
.reveal.visible { opacity: 1; transform: none; }

/* ── Reduced motion ──────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .marquee__track, .orb.connecting, .orb.speaking, .orb.live .orb__ring,
  .orb.live .orb__ring--2, .pulse-dot, .jbar__fill { animation: none; }
  .jbar__fill { transform: none; }
}
