/* ==========================================================================
   HornetHacks — shared stylesheet
   Clean voxel-technical: near-black surfaces, hairline borders, extruded
   3D-block buttons, isometric cube accents, and a restrained emerald
   palette. Inspired by vercel.com / cursor.com with a quiet 8-bit wink.
   ========================================================================== */

/* ---- Fonts (self-hosted, see assets/fonts) ------------------------------ */
@font-face {
  font-family: "Geist Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../assets/fonts/geist-sans-latin-400-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Geist Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../assets/fonts/geist-sans-latin-500-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Geist Sans";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../assets/fonts/geist-sans-latin-600-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Geist Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../assets/fonts/geist-sans-latin-700-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Geist Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../assets/fonts/geist-mono-latin-400-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Geist Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../assets/fonts/geist-mono-latin-500-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Silkscreen";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../assets/fonts/silkscreen-latin-400-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Silkscreen";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../assets/fonts/silkscreen-latin-700-normal.woff2") format("woff2");
}

/* ---- Design tokens ------------------------------------------------------ */
:root {
  --bg: #0a0a0a;
  --surface: #101010;
  --surface-2: #161616;
  --border: #222222;
  --border-strong: #383838;
  --text: #ededed;
  --text-dim: #9b9b9b;
  --text-faint: #6b6b6b;
  --green: #34d399;
  --green-bright: #6ee7b7;
  --green-deep: #0e9f6e;
  --green-dark: #0b6b4c;
  --green-darker: #07452f;
  --green-glow: rgba(52, 211, 153, 0.13);
  --grad: linear-gradient(100deg, var(--green-bright), var(--green) 45%, var(--green-deep));
  --radius: 2px;
  --wrap: 1080px;
  --pad: clamp(1.25rem, 5vw, 2.5rem);
  --font: "Geist Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI",
    Helvetica, Arial, sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", SFMono-Regular, Menlo,
    Consolas, monospace;
  --pixel: "Silkscreen", "Geist Mono", monospace;
}

/* ---- Base --------------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  margin: 0;
  position: relative;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Faint pixel-grid graph paper behind the top of every page */
body::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 130vh;
  background-image: linear-gradient(rgba(52, 211, 153, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(52, 211, 153, 0.05) 1px, transparent 1px);
  background-size: 34px 34px;
  -webkit-mask-image: radial-gradient(ellipse 75% 90% at 50% 0%, #000 30%, transparent 78%);
  mask-image: radial-gradient(ellipse 75% 90% at 50% 0%, #000 30%, transparent 78%);
  pointer-events: none;
  z-index: 0;
}
/* The home page keeps its background to a single effect (the hive canvas),
   so the graph paper stays off there. */
body.home::before {
  display: none;
}
body > * {
  position: relative;
  z-index: 1;
}

h1,
h2,
h3 {
  line-height: 1.1;
  letter-spacing: -0.025em;
  margin: 0 0 0.5em;
  font-weight: 600;
  text-wrap: balance;
}

p {
  margin: 0 0 1em;
}

a {
  color: inherit;
}

img,
svg,
canvas {
  max-width: 100%;
  display: block;
}

::selection {
  background: var(--green);
  color: #05130d;
}

:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 3px;
  border-radius: 4px;
}

.wrap {
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--pad);
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -3.5rem;
  z-index: 100;
  background: var(--text);
  color: var(--bg);
  padding: 0.6rem 1rem;
  border-radius: 8px;
  text-decoration: none;
  transition: top 0.2s;
}
.skip-link:focus {
  top: 1rem;
}

/* ---- Buttons & links ---------------------------------------------------- */
/* Extruded voxel block: the darker green "side faces" build the 3D depth */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.65em;
  padding: 0.85em 1.5em;
  border: 0;
  border-radius: 0;
  background: var(--green);
  color: #04130c;
  font: 500 0.9063rem/1 var(--font);
  letter-spacing: 0.005em;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.12s, box-shadow 0.12s, background 0.12s;
  box-shadow: 1px 1px 0 0 var(--green-deep), 2px 2px 0 0 var(--green-deep),
    3px 3px 0 0 var(--green-dark), 4px 4px 0 0 var(--green-dark),
    5px 5px 0 0 var(--green-darker), 0 0 34px -8px rgba(52, 211, 153, 0.4);
}
.btn:hover {
  background: var(--green-bright);
  transform: translate(-1px, -1px);
  box-shadow: 1px 1px 0 0 var(--green-deep), 2px 2px 0 0 var(--green-deep),
    3px 3px 0 0 var(--green-dark), 4px 4px 0 0 var(--green-dark),
    5px 5px 0 0 var(--green-darker), 6px 6px 0 0 var(--green-darker),
    0 0 40px -6px rgba(52, 211, 153, 0.55);
}
.btn:active {
  transform: translate(3px, 3px);
  box-shadow: 1px 1px 0 0 var(--green-darker), 2px 2px 0 0 var(--green-darker);
}
.btn .hex {
  width: 0.9em;
  height: 0.9em;
  flex: none;
}

.btn--ghost {
  background: var(--surface-2);
  color: var(--text);
  border: 1px solid var(--border-strong);
  box-shadow: 2px 2px 0 0 #1a1a1a, 4px 4px 0 0 #111;
}
.btn--ghost:hover {
  background: #1c1c1c;
  border-color: var(--green-deep);
  box-shadow: 2px 2px 0 0 #1a1a1a, 4px 4px 0 0 #111, 5px 5px 0 0 #0c0c0c;
}

.link-quiet {
  color: var(--text-dim);
  font-size: 0.875rem;
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: #3a3a3a;
  transition: color 0.15s, text-decoration-color 0.15s;
}
.link-quiet:hover {
  color: var(--text);
  text-decoration-color: var(--green);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.9em;
  font-family: var(--pixel);
  font-size: 0.6875rem;
  font-weight: 400;
  /* numeric line-height keeps the box the same before/after Silkscreen
     loads, so the page never reflows on font arrival */
  line-height: 1.6;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin: 0 0 1.2rem;
}
.eyebrow::before,
.eyebrow::after {
  content: "";
  width: 0.42em;
  height: 0.42em;
  background: var(--green);
  opacity: 0.9;
}

/* Status pill (hero) */
.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.9em;
  font-family: var(--pixel);
  font-size: 0.6875rem;
  color: var(--text-dim);
  border: 1px solid var(--border);
  background: rgba(16, 16, 16, 0.6);
  border-radius: 0;
  padding: 0.7em 1.1em;
  margin-bottom: 1.5rem;
}
.status-pill .pulse {
  width: 6px;
  height: 6px;
  background: var(--green); /* square: a single lit voxel */
  box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.6);
  animation: pulse 2.4s infinite;
}
@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.55);
  }
  70% {
    box-shadow: 0 0 0 7px rgba(52, 211, 153, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(52, 211, 153, 0);
  }
}

/* ---- Header ------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 10, 10, 0.75);
  backdrop-filter: blur(12px) saturate(1.4);
  -webkit-backdrop-filter: blur(12px) saturate(1.4);
  border-bottom: 1px solid var(--border);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  font-family: var(--pixel);
  font-weight: 700;
  font-size: 1.125rem; /* 18px */
  letter-spacing: 0.01em;
  color: var(--text);
}
.brand svg {
  width: 1.71875rem; /* 2.5px per cell of the 11x10 sprite (27.5x25px) */
  height: 1.5625rem;
  position: relative;
  top: -2px; /* optical alignment with the wordmark */
  flex: none;
  color: var(--text); /* pixel hornet picks this up via currentColor */
  image-rendering: pixelated;
}
.brand span b {
  color: var(--green);
  font-weight: 700;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(0.9rem, 2.2vw, 1.7rem);
}
.site-nav a:not(.btn) {
  text-decoration: none;
  font-weight: 400;
  font-size: 0.875rem;
  color: var(--text-dim);
  padding: 0.35rem 0;
  transition: color 0.15s;
}
.site-nav a:not(.btn):hover {
  color: var(--text);
}
.site-nav a[aria-current="page"] {
  color: var(--text);
}
.site-nav .btn {
  padding: 0.6em 1.05em;
  font-size: 0.8125rem;
  box-shadow: 1px 1px 0 0 var(--green-deep), 2px 2px 0 0 var(--green-dark),
    3px 3px 0 0 var(--green-darker);
}
.site-nav .btn:hover {
  box-shadow: 1px 1px 0 0 var(--green-deep), 2px 2px 0 0 var(--green-dark),
    3px 3px 0 0 var(--green-darker), 4px 4px 0 0 var(--green-darker);
}

.nav-toggle {
  display: none;
  border: 0;
  background: none;
  padding: 0.55rem;
  margin-right: -0.55rem;
  cursor: pointer;
}
.nav-toggle .bars,
.nav-toggle .bars::before,
.nav-toggle .bars::after {
  display: block;
  width: 1.35rem;
  height: 1.5px;
  border-radius: 2px;
  background: var(--text);
  transition: transform 0.25s, opacity 0.2s;
  content: "";
}
.nav-toggle .bars {
  position: relative;
}
.nav-toggle .bars::before {
  position: absolute;
  top: -6px;
}
.nav-toggle .bars::after {
  position: absolute;
  top: 6px;
}
.nav-toggle[aria-expanded="true"] .bars {
  transform: rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .bars::before {
  transform: rotate(-90deg) translateX(-6px);
}
.nav-toggle[aria-expanded="true"] .bars::after {
  opacity: 0;
}

@media (max-width: 760px) {
  .nav-toggle {
    display: block;
  }
  .site-nav {
    position: absolute;
    inset: 100% 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: rgba(10, 10, 10, 0.97);
    border-bottom: 1px solid var(--border);
    padding: 0.5rem var(--pad) 1.25rem;
    display: none;
  }
  .site-nav.open {
    display: flex;
  }
  .site-nav a:not(.btn) {
    padding: 0.85rem 0.25rem;
    border-bottom: 1px solid var(--border);
    font-size: 1rem;
    color: var(--text);
  }
  .site-nav .btn {
    margin-top: 1rem;
    justify-content: center;
  }
}

/* ---- Hero --------------------------------------------------------------- */
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  text-align: center;
  padding: clamp(3.5rem, 10vh, 7rem) 0 clamp(3.5rem, 9vh, 6rem);
  background:
    radial-gradient(ellipse 55% 36% at 50% 42%, rgba(52, 211, 153, 0.065), transparent 72%),
    linear-gradient(180deg, rgba(6, 12, 9, 0.12), transparent 72%);
}
.hero-content {
  position: relative;
  z-index: 3;
}
.hero .eyebrow {
  display: flex;
  justify-content: center;
}
.hero h1 {
  font-size: clamp(2.8rem, 8.5vw, 5rem);
  font-weight: 700;
  letter-spacing: -0.045em;
  margin-bottom: 0.4em;
  color: #fff;
}
.hero h1 .sting {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 26px rgba(52, 211, 153, 0.3));
}
/* With JS, the canvas wordmark owns the title slot from first paint; its
   height is reserved up front via aspect-ratio so nothing below shifts
   when the canvas draws. The text h1 stays in the page for screen
   readers, SEO, and no-JS; voxel-title.js sets .no-voxel on <html> if
   canvas init fails, restoring the text headline. */
html.js:not(.no-voxel) .hero h1 {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.voxel-title {
  position: relative;
  display: none;
  justify-content: center;
  align-items: center;
  margin: 0 auto 1.6rem;
  width: min(860px, 100%);
}
html.js:not(.no-voxel) .voxel-title {
  display: flex;
  /* the 63x5-block raster: (63+2 side pad) : (5 + 0.5 extrusion drop) */
  aspect-ratio: 65 / 5.5;
}
@media (max-width: 760px) {
  /* phones: bleed the wordmark through most of the page padding, keeping
     a 1rem breathing gap at each screen edge */
  .voxel-title {
    width: calc(100% + (var(--pad) - 1rem) * 2);
    margin-inline: calc(1rem - var(--pad));
  }
}
.voxel-title canvas {
  filter: drop-shadow(0 6px 30px rgba(52, 211, 153, 0.22));
}
.hero .lede {
  font-size: clamp(1rem, 2.2vw, 1.125rem);
  color: var(--text-dim);
  max-width: 36em;
  margin-inline: auto;
}

.event-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.5rem 1rem;
  margin: 1.5rem 0 2.2rem;
  font-family: var(--mono);
  font-size: clamp(0.75rem, 1.8vw, 0.8438rem);
  letter-spacing: 0.02em;
  color: var(--text-dim);
}
.event-meta .dot {
  color: var(--green);
  font-size: 0.72em;
}
@media (max-width: 640px) {
  .event-meta {
    flex-direction: column;
    gap: 0.45rem;
  }
  .event-meta .dot {
    display: none;
  }
}

.cta-row {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

/* MLH affiliation: the classic hanging trust badge — a white ribbon pinned
   to the hero's top-right corner, extruded like the site's 3D buttons. */
.mlh-badge {
  position: absolute;
  top: 0;
  right: clamp(1rem, 6vw, 4rem);
  z-index: 4;
  display: block;
  width: clamp(118px, 12vw, 152px);
  padding: 0.95rem 0.7rem 0.75rem;
  background: #fff;
  text-align: center;
  text-decoration: none;
  filter: drop-shadow(3px 3px 0 var(--border-strong)) drop-shadow(0 16px 30px rgba(0, 0, 0, 0.5));
  transition: transform 0.18s ease;
}
/* Ribbon tail: two points at the edges, notch rising in the center */
.mlh-badge::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  height: 14px;
  background: #fff;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 45%, 0 100%);
}
.mlh-badge img {
  display: block;
  width: 100%;
  height: auto;
}
/* The caption sits below a hairline rule that runs the full width of the
   banner (negative margins cancel the badge's side padding). */
.mlh-badge-label {
  display: block;
  margin: 0.65rem -0.7rem 0;
  padding: 0.6rem 0.5rem 0;
  border-top: 1px solid rgba(36, 36, 37, 0.25);
  font-family: var(--pixel);
  font-size: 0.8125rem;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  text-wrap: balance;
  color: #242425;
}
.mlh-badge:hover {
  transform: translateY(3px);
}
.mlh-badge:focus-visible {
  outline: 3px solid var(--green-bright);
  outline-offset: 4px;
}
/* phones: the ribbon becomes a slim horizontal banner across the top of
   the hero, so the headline doesn't have to clear a hanging tail */
@media (max-width: 640px) {
  .mlh-badge {
    left: 0;
    right: 0;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    padding: 0.5rem 1rem;
    filter: drop-shadow(0 8px 22px rgba(0, 0, 0, 0.45));
  }
  .mlh-badge::after {
    display: none; /* no ribbon tail on the banner */
  }
  .mlh-badge:hover {
    transform: none;
  }
  .mlh-badge img {
    width: 72px;
    flex: none;
  }
  .mlh-badge-label {
    margin: 0;
    padding: 0.1rem 0 0.1rem 0.8rem;
    border-top: 0;
    border-left: 1px solid rgba(36, 36, 37, 0.25);
    font-size: 0.5938rem;
    white-space: nowrap;
  }
  /* the top-left cube ducks below the banner */
  .voxel-decor .vcube-a {
    top: 13%;
  }
}

/* ---- Hero atmosphere + startup choreography ---------------------------- */
.hero-atmosphere {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  pointer-events: none;
  /* the hive dissolves cleanly into the black page below */
  -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 52%, transparent 97%);
  mask-image: linear-gradient(180deg, #000 0%, #000 52%, transparent 97%);
}
.hero-boot {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  opacity: 0;
  overflow: hidden;
  font: 500 0.625rem/1 var(--mono);
  letter-spacing: 0.12em;
  color: rgba(110, 231, 183, 0.72);
}
.boot-skip {
  position: absolute;
  opacity: 0;
  left: 50%;
  bottom: 1rem;
  transform: translateX(-50%);
  width: max-content;
  color: rgba(155, 155, 155, 0.58);
  letter-spacing: 0.06em;
}
html.hero-intro-active .hero {
  background-color: #050806;
  animation: hero-power-on 2.65s ease-out both;
}
html.hero-intro-active .hero-boot { opacity: 1; }
html.hero-intro-active .boot-skip { animation: boot-skip 1.7s 0.3s ease both; }
html.hero-intro-active .hero .status-pill { animation: hero-arrive 0.52s 1.54s ease-out both; }
html.hero-intro-active .hero .eyebrow { animation: hero-arrive 0.52s 1.66s ease-out both; }
html.hero-intro-active .hero .lede { animation: hero-arrive 0.56s 1.84s ease-out both; }
html.hero-intro-active .hero .event-meta { animation: hero-arrive 0.56s 1.98s ease-out both; }
html.hero-intro-active .hero .cta-row { animation: hero-arrive 0.56s 2.12s ease-out both; }
html.hero-intro-active .hero .mlh-badge { animation: badge-drop 0.56s 2.24s ease-out both; }
html.hero-intro-active .hero-content a { pointer-events: none; }
html.hero-intro-skipped .hero .status-pill,
html.hero-intro-skipped .hero .eyebrow,
html.hero-intro-skipped .hero .lede,
html.hero-intro-skipped .hero .event-meta,
html.hero-intro-skipped .hero .cta-row,
html.hero-intro-skipped .hero .mlh-badge {
  animation: none;
  opacity: 1;
  transform: none;
}
html.hero-intro-skipped .hero-boot,
html.hero-intro-done .hero-boot {
  opacity: 0;
  visibility: hidden;
}
@keyframes hero-power-on {
  0% { background-color: #020403; }
  38% { background-color: #050806; }
  100% { background-color: transparent; }
}
@keyframes boot-skip {
  0%, 12%, 100% { opacity: 0; }
  28%, 72% { opacity: 1; }
}
@keyframes hero-arrive {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}
/* The badge drops into place, like a ribbon unrolling from the header */
@keyframes badge-drop {
  from { opacity: 0; transform: translateY(-14px); }
  to { opacity: 1; transform: none; }
}

/* The hero's primary action gets a directional, contained energy pass. */
.hero .cta-row .btn {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: 48px;
  --btn-x: 50%;
}
.hero .cta-row .btn::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0;
  background:
    radial-gradient(circle at var(--btn-x) 50%, rgba(255, 255, 255, 0.35), transparent 28%),
    linear-gradient(105deg, transparent 34%, rgba(255, 255, 255, 0.25) 49%, transparent 64%);
  transform: translateX(-45%);
  transition: opacity 0.18s, transform 0.45s ease-out;
}
.hero .cta-row .btn:hover::before,
.hero .cta-row .btn:focus-visible::before {
  opacity: 0.75;
  transform: translateX(45%);
}
.hero .cta-row .btn:focus-visible {
  outline: 3px solid var(--green-bright);
  outline-offset: 5px;
}
.button-pixel {
  position: absolute;
  z-index: 8;
  width: 4px;
  height: 4px;
  pointer-events: none;
  background: var(--green-bright);
  box-shadow: 0 0 8px rgba(52, 211, 153, 0.8);
  animation: button-pixel 0.52s ease-out forwards;
}
@keyframes button-pixel {
  to { opacity: 0; transform: translate(var(--burst-x), var(--burst-y)) rotate(90deg); }
}

/* ---- Floating isometric voxel cubes behind the hero ---------------------- */
.voxel-decor {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  overflow: hidden;
}
.vcube {
  position: absolute;
  opacity: 0.8;
  transform-origin: center;
  will-change: transform;
}
/* The cubes live in the corners the centered text column never reaches:
   big one top-left above the wordmark, the smaller two low in the right
   corner below the lede/CTA column. */
.vcube-a {
  width: clamp(70px, 9vw, 130px);
  left: 3%;
  top: 8%;
  animation: float-a 11s ease-in-out infinite;
}
.vcube-b {
  width: clamp(44px, 5.5vw, 80px);
  right: 6%;
  bottom: 16%;
  animation: float-b 13s ease-in-out infinite;
}
.vcube-c {
  width: clamp(30px, 3.8vw, 56px);
  right: 20%;
  bottom: 4%;
  animation: float-a 9s ease-in-out 1.2s infinite;
}
@keyframes float-a {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-28px) rotate(4deg);
  }
}
@keyframes float-b {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(22px) rotate(-5deg);
  }
}
@media (max-width: 760px) {
  .vcube-a {
    left: 2%;
    top: 4%;
  }
  .vcube-b {
    right: 3%;
    top: auto;
    bottom: 6%;
  }
  .vcube-c {
    display: none;
  }
}
/* small phones: the centered text column reaches nearly edge to edge, so
   there is no corner left where a cube can float without touching copy —
   the hive and MLH banner carry the theming alone */
@media (max-width: 560px) {
  .vcube-a,
  .vcube-b {
    display: none;
  }
}

/* ---- Fact strip --------------------------------------------------------- */
.facts {
  padding: 0 0 clamp(3rem, 8vh, 5rem);
}
.facts .grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.fact {
  padding: 1.5rem 1.6rem 1.6rem;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  /* the site's extruded-block signature, in quiet grays until hovered */
  box-shadow: 2px 2px 0 0 var(--border-strong), 4px 4px 0 0 var(--border);
  transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s, background 0.15s;
}
.fact:hover {
  background: var(--surface-2);
  transform: translate(-3px, -3px);
  /* the lift IS the effect: no color shift, just a deeper extrusion */
  box-shadow: 4px 4px 0 0 var(--border-strong), 8px 8px 0 0 var(--border);
}
/* Subtle entrance: the site's standard quiet fade-up, done as an
   animation so the generic reveal's transition-delay never lingers on
   the hover transitions */
html.js .fact.reveal,
html.js .fact.reveal.in {
  transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s, background 0.15s;
  transition-delay: 0s;
}
html.js .fact.reveal {
  opacity: 0;
}
html.js .fact.reveal.in {
  opacity: 1;
  /* backwards fill (not both): once the entrance ends the animation
     releases transform, so the hover lift works again */
  animation: fact-in 0.55s ease-out backwards;
  animation-delay: var(--reveal-delay, 0s);
}
/* outweigh the generic .reveal.in transform pin so the lift survives */
html.js .fact.reveal.in:hover {
  transform: translate(-3px, -3px);
}
@keyframes fact-in {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
.fact .label {
  font-family: var(--pixel);
  font-size: 0.7188rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--green);
  margin-bottom: 0.6rem;
}
.fact .value {
  font-size: 1.0625rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.35;
  color: var(--text);
}
.fact .sub {
  color: var(--text-faint);
  font-size: 0.875rem;
  margin: 0.25rem 0 0;
}
@media (max-width: 700px) {
  .facts .grid {
    grid-template-columns: 1fr;
  }
}

/* ---- Generic content sections (subpages) -------------------------------- */
.page-hero {
  text-align: center;
  padding: clamp(3rem, 8vh, 5rem) 0 clamp(1.5rem, 4vh, 2.5rem);
}
.page-hero h1 {
  font-size: clamp(2.2rem, 6vw, 3.4rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  color: #fff;
}
.page-hero .lede {
  color: var(--text-dim);
  font-size: clamp(1rem, 2vw, 1.0938rem);
  max-width: 40em;
  margin-inline: auto;
}

.section {
  padding: clamp(1.5rem, 4vh, 2.5rem) 0;
}
.section:last-of-type {
  padding-bottom: clamp(4rem, 9vh, 6rem);
}
.section h2 {
  font-size: clamp(1.4rem, 3.2vw, 1.8rem);
  margin-bottom: 1.2rem;
  color: #fff;
}

.prose {
  max-width: 44em;
  margin-inline: auto;
}
.prose p {
  color: var(--text-dim);
}
.prose strong {
  color: var(--text);
  font-weight: 600;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1rem;
}
.card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  background: var(--surface);
  box-shadow: 3px 3px 0 0 rgba(255, 255, 255, 0.03); /* faint extruded edge */
  transition: background 0.15s, box-shadow 0.15s, border-color 0.15s, transform 0.15s;
}
.card:hover {
  background: var(--surface-2);
  border-color: var(--green-dark);
  transform: translate(-1px, -1px);
  box-shadow: 4px 4px 0 0 rgba(52, 211, 153, 0.14), 0 0 30px -12px rgba(52, 211, 153, 0.35);
}
.card h3 {
  font-size: 1.0313rem;
  margin-bottom: 0.4rem;
  color: var(--text);
}
.card p {
  color: var(--text-dim);
  font-size: 0.9063rem;
  margin: 0;
}
.card .cell-icon {
  width: 1.7rem;
  height: 1.9rem;
  margin-bottom: 1rem;
  color: var(--green);
}

/* Partner feature on the sponsors page. The official color mark sits on a
   quiet light field so its supplied colors remain true and fully legible. */
.partner-section {
  padding-top: 1rem;
}
.mlh-partner-panel {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(250px, 0.75fr);
  align-items: center;
  gap: clamp(2rem, 6vw, 5rem);
  padding: clamp(1.75rem, 5vw, 3rem);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  box-shadow: 4px 4px 0 0 var(--border);
  overflow: hidden;
}
.mlh-partner-panel::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 2px;
  background: var(--grad);
}
.mlh-partner-copy {
  position: relative;
}
.mlh-partner-copy .eyebrow {
  margin-bottom: 0.8rem;
}
.mlh-partner-copy h2 {
  margin-bottom: 0.75rem;
}
.mlh-partner-copy > p:not(.eyebrow) {
  max-width: 38em;
  color: var(--text-dim);
  margin-bottom: 1rem;
}
.mlh-partner-logo {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 180px;
  padding: 2rem;
  background: #ffffff;
  border: 1px solid #d8d8d8;
  box-shadow: 3px 3px 0 0 var(--border-strong), 6px 6px 0 0 var(--border);
}
.mlh-partner-logo img {
  width: min(220px, 100%);
  height: auto;
}

@media (max-width: 700px) {
  .mlh-partner-panel {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }
  .mlh-partner-logo {
    min-height: 145px;
    padding: 1.5rem;
  }
  .mlh-partner-logo img {
    width: min(190px, 70%);
  }
}

/* ---- Timeline (schedule) ------------------------------------------------ */
.timeline {
  max-width: 640px;
  margin-inline: auto;
  border-top: 1px solid var(--border);
  list-style: none;
  padding-left: 0;
}
.timeline li {
  display: grid;
  grid-template-columns: 9rem 1fr;
  gap: 1.25rem;
  padding: 1.05rem 0.25rem;
  border-bottom: 1px solid var(--border);
  align-items: baseline;
}
.timeline .time {
  font-family: var(--pixel);
  font-weight: 400;
  font-size: 0.7813rem;
  line-height: 1.6;
  color: var(--green);
}
.timeline .what b {
  display: block;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
}
.timeline .what span {
  color: var(--text-faint);
  font-size: 0.875rem;
}
/* phones: the time ranges are too wide for a side column, so each entry
   stacks with its time above the title */
@media (max-width: 480px) {
  .timeline li {
    grid-template-columns: 1fr;
    gap: 0.3rem;
  }
}

/* ---- FAQ ---------------------------------------------------------------- */
.faq {
  max-width: 680px;
  margin-inline: auto;
}
.faq details {
  border-bottom: 1px solid var(--border);
}
.faq details:first-of-type {
  border-top: 1px solid var(--border);
}
.faq summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1.1rem 0.25rem;
  font-weight: 500;
  font-size: 0.9688rem;
  color: var(--text);
  transition: color 0.15s;
}
.faq summary:hover {
  color: var(--green);
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: "+";
  flex: none;
  font-family: var(--pixel);
  font-size: 0.7rem;
  width: 1.55rem;
  height: 1.55rem;
  display: grid;
  place-items: center;
  border: 1px solid var(--border-strong);
  border-radius: 0;
  font-weight: 400;
  color: var(--text-dim);
  transition: transform 0.2s, border-color 0.2s, color 0.2s;
}
.faq details[open] summary::after {
  content: "−";
  color: var(--green);
  border-color: var(--green);
}
.faq details p {
  padding: 0 2.6rem 1.15rem 0.25rem;
  color: var(--text-dim);
  font-size: 0.9375rem;
  margin: 0;
}

/* ---- Callout band ------------------------------------------------------- */
.band {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 4px);
  padding: clamp(2.25rem, 6vw, 3.5rem);
  text-align: center;
  overflow: hidden;
}
.band::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(45% 110% at 22% 0%, var(--green-glow), transparent 70%),
    radial-gradient(45% 110% at 78% 0%, rgba(52, 211, 153, 0.07), transparent 70%);
  pointer-events: none;
}
.band::after {
  content: "";
  position: absolute;
  inset: 0 12% auto;
  height: 2px;
  background: var(--grad);
  opacity: 0.85;
}
.band > * {
  position: relative;
}
.band h2 {
  color: #fff;
}
.band p {
  color: var(--text-dim);
  max-width: 36em;
  margin-inline: auto;
}
.band .btn {
  margin-top: 0.75rem;
}
.band .link-quiet {
  color: var(--text-faint);
}

/* ---- Sponsors strip ------------------------------------------------------ */
/* One real logo per announced sponsor; the rest render as blurred grey
   placeholder wordmarks until they're revealed. */
.sponsors-strip .wrap {
  text-align: center;
}
.sponsors-strip h2 {
  color: #fff;
  margin-bottom: 2.4rem;
}
.tier {
  margin-bottom: 2.6rem;
}
.tier-label {
  font-family: var(--pixel);
  font-size: 0.6875rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: 1.2rem;
}
.tier-gold .tier-label { color: #cdb26a; }
.tier-silver .tier-label { color: #a9b0b6; }
.tier-bronze .tier-label { color: #b18a67; }
.tier-logos {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 2rem 3.5rem;
}
.sponsor-logo {
  height: 58px;
  width: auto;
}
.tier-silver .sponsor-logo { height: 38px; }
.tier-bronze .sponsor-logo { height: 26px; }
.sponsor-logo.tba {
  fill: var(--text-faint);
  opacity: 0.45;
  filter: blur(6px);
}
.tier-silver .sponsor-logo.tba { filter: blur(5px); }
.tier-bronze .sponsor-logo.tba { filter: blur(4px); }
.sponsors-tba {
  display: inline-flex;
  align-items: center;
  gap: 0.9em;
  font-family: var(--pixel);
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin: 0.6rem 0 1.2rem;
}
.sponsors-tba .pulse {
  width: 6px;
  height: 6px;
  background: var(--green);
  animation: pulse 2.4s infinite;
}
@media (max-width: 640px) {
  .tier-logos { gap: 1.4rem 2rem; }
  .sponsor-logo { height: 44px; }
  .tier-silver .sponsor-logo { height: 30px; }
  .tier-bronze .sponsor-logo { height: 22px; }
}
.band .link-quiet:hover {
  color: var(--text);
}

/* ---- Footer ------------------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 2.5rem 0 3rem;
  font-size: 0.875rem;
}
.site-footer .top {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem 2.5rem;
  justify-content: space-between;
  align-items: flex-start;
}
.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.4rem;
}
.site-footer nav a {
  text-decoration: none;
  color: var(--text-dim);
  transition: color 0.15s;
}
.site-footer nav a:hover {
  color: var(--text);
}
.site-footer .fine {
  margin-top: 1.75rem;
  color: var(--text-faint);
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  justify-content: space-between;
  font-family: var(--mono);
  font-size: 0.75rem;
}
.site-footer .fine p {
  margin: 0;
}
.site-footer .fine .link-quiet {
  font-size: inherit;
  font-family: var(--mono);
}

/* ---- Alive: entrances, reveals, micro-interactions ----------------------- */
@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
.page-hero .eyebrow {
  animation: rise 0.5s 0.05s ease-out both;
}
.page-hero h1 {
  animation: rise 0.5s 0.12s ease-out both;
}
.page-hero .lede {
  animation: rise 0.5s 0.2s ease-out both;
}

/* Scroll reveals (motion.js adds .reveal/.in; html.js guard keeps no-JS visible) */
html.js .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.55s ease-out, transform 0.55s ease-out;
  transition-delay: var(--reveal-delay, 0s);
}
html.js .reveal.in {
  opacity: 1;
  transform: none;
}

/* Reserve the hero eyebrow's line box while it types itself out —
   must equal the .eyebrow line-height so the first typed character
   doesn't grow the line */
.hero .eyebrow [data-type] {
  display: inline-block;
  min-height: 1.6em;
}

/* The pixel hornet in the header buzzes when you poke it */
@keyframes buzz {
  0%,
  100% {
    transform: none;
  }
  20% {
    transform: translate(-1px, 1px) rotate(-4deg);
  }
  40% {
    transform: translate(1px, -1px) rotate(4deg);
  }
  60% {
    transform: translate(-1px, -1px) rotate(-3deg);
  }
  80% {
    transform: translate(1px, 1px) rotate(3deg);
  }
}
.brand:hover svg,
.brand:focus-visible svg {
  /* the flap keyframes flip the --fw-a/--fw-b wing-frame opacities, which
     inherit into the #hh-mark <use> shadow DOM; 5 cycles x 150ms outlasts
     the 0.45s buzz a touch, so the wings wind down after the shake */
  animation: buzz 0.45s linear, hh-flap-brand 150ms linear 5;
}
@keyframes hh-flap-brand {
  0%,
  49.9% {
    --fw-a: 1;
    --fw-b: 0;
  }
  50%,
  100% {
    --fw-a: 0;
    --fw-b: 1;
  }
}

/* Card cube icons pop on hover */
.card .cell-icon {
  transition: transform 0.2s, color 0.2s;
}
.card:hover .cell-icon {
  transform: translateY(-3px) scale(1.1);
  color: var(--green-bright);
}

/* Button cube gives a little hop */
.btn .hex {
  transition: transform 0.2s;
}
.btn:hover .hex {
  transform: translateY(-2px) rotate(-8deg);
}

/* The band's gradient hairline drifts slowly */
.band::after {
  background-size: 220% 100%;
  animation: grad-slide 7s ease-in-out infinite alternate;
}
@keyframes grad-slide {
  from {
    background-position: 0% 0;
  }
  to {
    background-position: 100% 0;
  }
}

/* FAQ answers ease open */
.faq details[open] p {
  animation: faq-in 0.28s ease-out both;
}
@keyframes faq-in {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
}

@keyframes hh-flap {
  0%,
  49.9% {
    opacity: 1;
  }
  50%,
  100% {
    opacity: 0;
  }
}

/* The flyby hornet rides fixed on <body>, above everything; clicking it
   swats it out of the air (motion.js supplies flight and the fall). */
.flyby {
  position: fixed;
  top: 0;
  left: 0;
  width: 44px; /* 4px per cell of the 11x10 sprite */
  height: 40px;
  color: var(--text);
  filter: drop-shadow(0 0 8px rgba(52, 211, 153, 0.35));
  will-change: transform;
  z-index: 80; /* above the sticky header; only the focus-only skip-link outranks it */
  cursor: pointer;
  pointer-events: auto;
}
.flyby::after {
  /* generous tap target for a small moving sprite */
  content: "";
  position: absolute;
  inset: -10px;
}
.flyby .fw-b {
  opacity: 0;
}
html.js .flyby .fw-a {
  animation: hh-flap 160ms linear infinite;
}
html.js .flyby .fw-b {
  animation: hh-flap 160ms linear infinite;
  animation-delay: -80ms;
}
.flyby.dead {
  cursor: default;
}
.flyby.dead .fw-a,
.flyby.dead .fw-b {
  animation: none;
}
.flyby.dead .fw-a {
  opacity: 0;
}
.flyby.dead .fw-b {
  opacity: 1; /* wings splayed flat — very dead */
}

@media (max-width: 760px) {
  .hero {
    padding-top: clamp(3rem, 8vh, 4.5rem);
  }
  .hero-atmosphere { opacity: 0.75; }
}
/* On phones the hero only needs to clear the slim horizontal MLH banner.
   (Kept after the 760px rule above, which also sets .hero padding-top.) */
@media (max-width: 640px) {
  .hero {
    padding-top: 5.75rem;
  }
}

@media (max-height: 520px) and (orientation: landscape) {
  .hero { padding-block: 2.25rem 2.75rem; }
  .hero .status-pill { margin-bottom: 0.8rem; }
  .hero .eyebrow { margin-bottom: 0.8rem; }
  .voxel-title { margin-bottom: 1rem; }
  .event-meta { margin-block: 1rem 1.5rem; }
}

/* ---- Motion ------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
  .hero-boot,
  .flyby,
  .button-pixel {
    display: none !important;
  }
  .hero-content,
  .vcube {
    transform: none !important;
  }
}
