/* ==========================================================================
   LMML 2026 — Learning Marathon of Machine Learning
   Main stylesheet. Organized by section; see index.html for markup order.
   ========================================================================== */

:root {
  --bg: #0A0F0D;
  --fg: #D8E5DF;
  --fg-strong: #EAFFF8;
  --fg-muted: #9FBFB2;
  --fg-dim: #56907F;
  --fg-dimmer: #3E6D5F;

  --accent: #64FAD7;
  --accent-rgb: 100, 250, 215;
  --accent-light: #A8FFE9;
  --accent-deep: #009668;
  --accent-deep-rgb: 0, 150, 104;
  --accent-glow-rgb: 0, 236, 164;
  --teal-tint-rgb: 0, 100, 88;

  --card-bg: #0E1512;
  --card-bg-alt: #12211C;

  --purple: #B39CFF;
  --purple-light: #D4C5FF;

  --font-mono: 'JetBrains Mono', monospace;
  --font-sans: 'Onest', sans-serif;

  --max-narrow: 800px;
  --max-content: 1100px;
  --max-wide: 1400px;
}

/* ---------- Reset & base ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-light); }
img { max-width: 100%; }
::selection { background: rgba(var(--accent-rgb), 0.3); }
button { font: inherit; }

/* ---------- Keyframes ---------- */
@keyframes blink { 0%, 49% { opacity: 1; } 50%, 100% { opacity: 0; } }
@keyframes aurora {
  0%, 100% { transform: translate3d(-6%, -2%, 0) scale(1); opacity: 0.75; }
  33% { transform: translate3d(10%, 4%, 0) scale(1.14); opacity: 1; }
  66% { transform: translate3d(2%, -5%, 0) scale(1.05); opacity: 0.85; }
}
@keyframes declassify {
  0% { opacity: 0; } 12% { opacity: 1; } 20% { opacity: 0.1; } 32% { opacity: 1; }
  42% { opacity: 0.35; } 55% { opacity: 1; } 62% { opacity: 0.7; } 100% { opacity: 1; }
}
@keyframes glitchsplit {
  0%, 96.2%, 100% { transform: none; text-shadow: 0 0 40px rgba(var(--accent-rgb), 0.35); clip-path: none; }
  96.4% { transform: translate(-2px, 1px); text-shadow: 3px 0 rgba(255,70,120,0.75), -3px 0 rgba(var(--accent-rgb), 0.75), 0 0 40px rgba(var(--accent-rgb), 0.35); }
  97.0% { transform: translate(2px, -1px); text-shadow: -4px 0 rgba(255,70,120,0.6), 4px 0 rgba(var(--accent-rgb), 0.6), 0 0 40px rgba(var(--accent-rgb), 0.35); }
  97.6% { transform: translate(-1px, 0); text-shadow: 2px 0 rgba(255,70,120,0.5), -2px 0 rgba(var(--accent-rgb), 0.8), 0 0 40px rgba(var(--accent-rgb), 0.35); opacity: 0.85; }
  98.4% { transform: translate(1px, 1px); text-shadow: 5px 0 rgba(var(--accent-rgb), 0.35), -2px 0 rgba(255,70,120,0.45), 0 0 40px rgba(var(--accent-rgb), 0.35); }
  99.2% { transform: none; text-shadow: 1px 0 rgba(var(--accent-rgb), 0.4), 0 0 40px rgba(var(--accent-rgb), 0.35); }
}
@keyframes glitchflicker {
  0%, 96.2%, 100% { opacity: 1; transform: none; }
  96.6% { opacity: 0.55; transform: translateX(3px); }
  97.4% { opacity: 1; transform: translateX(-2px); }
  98.6% { opacity: 0.75; transform: translateX(1px); }
}
@keyframes shimmerpass {
  0%, 70% { transform: translateX(-180%) skewX(-18deg); }
  86%, 100% { transform: translateX(280%) skewX(-18deg); }
}
@keyframes griddrift { from { background-position: 0 0, 0 0; } to { background-position: 0 44px, 44px 0; } }
/* The hashtag marquee is no longer a CSS animation — js/main.js drives its
   transform directly every frame (see initMarquees()/startMarquee()) so no
   browser has to compute a loop point from intrinsic sizing. */

@media (prefers-reduced-motion: reduce) {
  /* animation-duration alone isn't enough for the page's other `infinite`
     loops (aurora, grid drift, shimmer, blink, glitch title) — an
     infinite animation squeezed to ~0 duration doesn't stop, it just
     spins through its whole cycle thousands of times a second forever,
     which different browsers/engines sample inconsistently: some settle
     on a static frame, others visibly stutter/jump between frames.
     Capping every animation to a single iteration makes it play once
     (effectively instantly) and then genuinely stop, landing cleanly on
     its resting state instead of looping forever. */
  * { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

/* ---------- Scanline overlay ---------- */
.scanlines {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 60;
  background: repeating-linear-gradient(0deg, rgba(0,0,0,0) 0px, rgba(0,0,0,0) 3px, rgba(var(--accent-rgb), 0.015) 3px, rgba(var(--accent-rgb), 0.015) 4px);
}

/* ---------- Page shell ---------- */
.page {
  min-height: 100vh;
  background: var(--bg);
  position: relative;
  overflow-x: clip;
}

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 24px;
  background: rgba(10,15,13,0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(var(--accent-rgb), 0.18);
  font-family: var(--font-sans);
}
.nav__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  color: var(--fg-strong);
  font-weight: 800;
  font-size: 15px;
  letter-spacing: 0.06em;
}
.nav__brand img { height: 22px; width: auto; display: block; }
.nav__brand .sep { color: rgba(216,229,223,0.4); }
.nav__links {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 14px;
  font-weight: 500;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.nav__link { color: var(--fg-muted); transition: color 140ms ease; }
.nav__link:hover { color: var(--accent); }
.nav__link--alt { color: var(--purple); }
.nav__link--alt:hover { color: var(--purple-light); }

.lang-btn {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  padding: 8px 12px;
  background: transparent;
  border: 1px solid rgba(var(--accent-rgb), 0.3);
  color: var(--accent);
  border-radius: 3px;
  cursor: pointer;
  transition: border-color 140ms ease, color 140ms ease;
}
.lang-btn:hover { border-color: var(--accent); color: #FFFFFF; }

.ticket-btn {
  font-family: var(--font-mono);
  padding: 9px 18px;
  background: transparent;
  border: 1px solid rgba(var(--accent-rgb), 0.38);
  color: #9FF5D8;
  font-weight: 700;
  font-size: 13px;
  border-radius: 3px;
  transition: border-color 140ms ease, color 140ms ease;
}
.ticket-btn:hover { border-color: var(--accent); color: var(--fg-strong); }

/* ---------- Nav burger (mobile) ---------- */
.nav__burger {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  padding: 0;
  background: transparent;
  border: 1px solid rgba(var(--accent-rgb), 0.3);
  border-radius: 3px;
  cursor: pointer;
  flex-shrink: 0;
}
.nav__burger:hover { border-color: var(--accent); }
.nav__burger span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--accent);
  transition: transform 200ms ease, opacity 150ms ease;
}
.nav.is-open .nav__burger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav.is-open .nav__burger span:nth-child(2) { opacity: 0; }
.nav.is-open .nav__burger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.btn-primary {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 15px;
  padding: 15px 30px;
  background: var(--accent);
  border: 1px solid var(--accent-light);
  color: #06120E;
  box-shadow: 0 0 34px rgba(var(--accent-rgb), 0.55);
  border-radius: 3px;
  transition: box-shadow 140ms ease, background 140ms ease;
  display: inline-block;
}
.btn-primary:hover { background: var(--accent-light); box-shadow: 0 0 48px rgba(var(--accent-rgb), 0.85); color: #06120E; }
.btn-primary--big { font-size: 16px; padding: 17px 36px; box-shadow: 0 0 38px rgba(var(--accent-rgb), 0.6); }
.btn-primary--big:hover { box-shadow: 0 0 54px rgba(var(--accent-rgb), 0.9); }

.btn-ghost {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 15px;
  padding: 15px 30px;
  background-color: transparent;
  background-image: linear-gradient(90deg, rgba(var(--accent-rgb), 0.16), rgba(var(--accent-rgb), 0.05));
  background-repeat: no-repeat;
  background-position: left center;
  background-size: 0% 100%;
  border: 1px solid rgba(var(--accent-rgb), 0.28);
  color: var(--fg-muted);
  border-radius: 3px;
  transition: border-color 140ms ease, color 140ms ease, background-size 420ms cubic-bezier(.22,.61,.36,1);
}
.btn-ghost:hover { border-color: rgba(var(--accent-rgb), 0.65); color: var(--fg-strong); background-size: 100% 100%; }
.btn-ghost__shimmer {
  position: absolute; top: 0; bottom: 0; left: 0; width: 56px;
  background: linear-gradient(90deg, transparent, rgba(var(--accent-rgb), 0.28), transparent);
  pointer-events: none;
  animation: shimmerpass 5.5s cubic-bezier(.22,.61,.36,1) infinite;
}
.btn-ghost__chevron { color: var(--accent); opacity: 0.75; }
.btn-ghost__cursor { display: inline-block; width: 8px; height: 15px; background: var(--accent); animation: blink 1.05s step-end infinite; }

.btn-outline {
  display: inline-block;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 14px;
  padding: 13px 26px;
  background: transparent;
  border: 1px solid rgba(var(--accent-rgb), 0.38);
  color: #9FF5D8;
  border-radius: 3px;
  white-space: nowrap;
  transition: border-color 140ms ease, color 140ms ease;
}
.btn-outline:hover { border-color: var(--accent); color: var(--fg-strong); }

.btn-outline--purple {
  border-color: rgba(179,156,255,0.5);
  color: var(--purple);
  transition: box-shadow 140ms ease, color 140ms ease;
}
.btn-outline--purple:hover { box-shadow: 0 0 20px rgba(179,156,255,0.35); color: var(--purple-light); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 96px 24px 72px;
  text-align: center;
  overflow: clip;
}
.hero__spotlight {
  position: absolute; left: 0; top: 0;
  width: 760px; height: 760px;
  margin: -380px 0 0 -380px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 400ms cubic-bezier(.22,.61,.36,1);
  background: radial-gradient(circle, rgba(var(--accent-rgb),0.07), rgba(var(--accent-glow-rgb),0.03) 38%, transparent 68%);
}
.hero__aurora-wrap {
  position: absolute; inset: -20% -10% auto -10%; height: 120%;
  pointer-events: none; overflow: hidden;
}
.hero__aurora {
  position: absolute; top: -10%; left: 8%; width: 72%; height: 78%;
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(var(--accent-glow-rgb),0.22), rgba(0,145,130,0.1) 48%, transparent 72%);
  filter: blur(70px);
  animation: aurora 40s ease-in-out infinite;
}
.hero__trail {
  position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 2;
  font-family: var(--font-mono); font-size: 12px; color: var(--accent);
}
.hero__trail span { position: absolute; left: 0; top: 0; opacity: 0; }
.hero__radial {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse 70% 55% at 50% 0%, rgba(var(--accent-deep-rgb),0.28), transparent 70%);
}
.hero__grid {
  position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(rgba(var(--accent-rgb),0.05) 1px, transparent 1px), linear-gradient(90deg, rgba(var(--accent-rgb),0.05) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, black, transparent);
  animation: griddrift 44s linear infinite;
}

.hero__inner {
  position: relative;
  max-width: 1240px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 24px;
}
.hero__copy {
  position: relative;
  flex: 1 1 460px;
  max-width: 900px;
  margin: 0 auto 0 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}
.hero__title {
  margin: 0;
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: clamp(26px, 4.2vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--fg-strong);
  text-shadow: 0 0 40px rgba(var(--accent-rgb), 0.35);
}
.hero__title-line1 { display: block; white-space: nowrap; animation: glitchsplit 8s steps(1, end) infinite; }
.hero__title-line2 {
  display: block; white-space: nowrap;
  background: linear-gradient(120deg, var(--accent), var(--accent-deep));
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: glitchflicker 8s steps(1, end) infinite;
}

.hero__typed { font-family: var(--font-mono); font-size: 15px; color: #7FDDC2; min-height: 24px; }
.hero__typed .prompt { color: var(--fg-dim); }
.hero__cursor { display: inline-block; width: 9px; height: 18px; background: var(--accent); vertical-align: -3px; animation: blink 1s step-end infinite; }

.pill-row { font-family: var(--font-mono); display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; font-size: 14px; }
.pill {
  display: inline-flex; align-items: center; gap: 8px;
  border: 1px solid rgba(var(--accent-rgb), 0.3);
  border-radius: 3px; padding: 8px 14px; white-space: nowrap;
}
.pill__key { color: var(--fg-dim); }
.pill__val { color: var(--accent); font-weight: 700; }

.countdown-wrap { display: flex; flex-direction: column; align-items: center; gap: 10px; margin-top: 4px; }
.countdown { display: flex; align-items: flex-end; gap: 10px; font-family: var(--font-mono); }
.countdown__unit { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.countdown__value {
  font-weight: 800; font-size: clamp(28px, 4.4vw, 44px); line-height: 1;
  color: var(--accent); text-shadow: 0 0 20px rgba(var(--accent-rgb), 0.4);
  font-variant-numeric: tabular-nums;
}
.countdown__value--sec { color: rgba(var(--accent-rgb), 0.7); text-shadow: none; }
.countdown__label { font-size: 10px; color: var(--fg-dim); letter-spacing: 0.16em; }
.countdown__sep { font-weight: 800; font-size: clamp(22px, 3.4vw, 34px); line-height: 1.15; color: rgba(var(--accent-rgb), 0.35); }

.hero__ctas { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; margin-top: 8px; }

.hero__mascot {
  position: relative;
  flex: 0 1 480px;
  min-width: 300px;
  align-self: flex-end;
  display: flex;
  justify-content: center;
}
.hero__mascot-halo {
  position: absolute; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 420px; height: 420px; border-radius: 50%;
  background: radial-gradient(circle, rgba(var(--accent-glow-rgb),0.22), transparent 70%);
  filter: blur(10px);
}
.hero__mascot-glow {
  position: absolute; left: 50%; bottom: 6%;
  width: 46%; height: 20%; transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(var(--accent-rgb),0.55), rgba(var(--accent-glow-rgb),0.18) 55%, transparent 78%);
  filter: blur(14px); opacity: 0.25; pointer-events: none; z-index: 2;
}
.hero__mascot-img {
  position: relative; display: block; width: 100%;
  mask-image: linear-gradient(to bottom, black 74%, transparent 97%);
  -webkit-mask-image: linear-gradient(to bottom, black 74%, transparent 97%);
  max-width: 520px; height: auto; will-change: transform;
  filter: drop-shadow(0 0 50px rgba(var(--accent-glow-rgb),0.28));
}

/* ---------- Marquee ---------- */
.marquee {
  overflow: hidden;
  border-top: 1px solid rgba(var(--accent-rgb), 0.15);
  border-bottom: 1px solid rgba(var(--accent-rgb), 0.15);
  padding: 12px 0;
  background: rgba(var(--teal-tint-rgb), 0.08);
}
.marquee__track {
  display: flex; white-space: nowrap;
  font-family: var(--font-mono); font-size: 14px; color: var(--fg-dim);
  will-change: transform;
}
/* The track holds two identical .marquee__group copies of the tag list.
   js/main.js's startMarquee() measures the real gap between them with
   getBoundingClientRect() and sets this element's `transform` itself on
   every animation frame, wrapping the position by exactly that measured
   pixel width — no CSS animation/keyframe involved at all. Earlier
   attempts here used a CSS `animation: marquee ...`, first looping via
   `translateX(-50%)` of the track's own intrinsic width, then via a
   measured value fed back through a --marquee-shift custom property —
   both still handed the actual per-frame scrolling to the browser's CSS
   animation engine, which kept landing differently between Chromium and
   Safari. Driving the transform directly removes that engine from the
   loop entirely. See also .partners-marquee__track in
   css/style-2025.css. */
.marquee__group { display: flex; flex: 0 0 auto; gap: 40px; margin-right: 40px; }
.marquee__track span.hi { color: var(--accent); }

/* ---------- Sections (shared) ---------- */
.section { position: relative; padding: 88px 24px; }
.section--narrow { max-width: var(--max-narrow); margin: 0 auto; }
.section--content { max-width: var(--max-content); margin: 0 auto; }
.section--wide { max-width: var(--max-wide); margin: 0 auto; }
.section--band { border-top: 1px solid rgba(var(--accent-rgb), 0.12); }
#stats { padding: 80px 24px; }
.section--band-both { border-top: 1px solid rgba(var(--accent-rgb), 0.12); border-bottom: 1px solid rgba(var(--accent-rgb), 0.12); }
.section--tint { background: rgba(var(--teal-tint-rgb), 0.05); }
.section--fade { background: linear-gradient(180deg, rgba(var(--teal-tint-rgb), 0.1), rgba(10,15,13,0)); }

.section-depth { position: relative; }
.section-depth::after {
  content: '';
  position: absolute; inset: 0 auto 0 50%;
  width: 100vw; transform: translateX(-50%);
  pointer-events: none; z-index: 0;
  background: radial-gradient(ellipse 78% 68% at 50% 50%, transparent 42%, rgba(0,0,0,0.42) 100%);
}
.section > * { position: relative; z-index: 1; }

.eyebrow {
  font-family: var(--font-mono); font-size: 13px; color: var(--accent);
  letter-spacing: 0.16em; margin-bottom: 14px;
  display: flex; align-items: baseline; gap: 14px;
}
.eyebrow__num {
  font-size: 44px; font-weight: 800; line-height: 0.8; letter-spacing: -0.04em;
  color: rgba(var(--accent-rgb), 0.14);
}
.h2 {
  margin: 0 0 18px; font-family: var(--font-mono); font-weight: 800;
  font-size: clamp(30px, 4.5vw, 46px); color: var(--fg-strong); letter-spacing: -0.02em;
}
.h2--tight { margin-bottom: 14px; font-size: clamp(30px, 4.4vw, 48px); }
.h2--md { font-size: clamp(28px, 4vw, 42px); margin-bottom: 40px; }
.lede { margin: 0 0 44px; max-width: none; font-size: 17px; line-height: 1.6; color: var(--fg-muted); }
.lede--strong { font-size: 17px; color: var(--fg); margin-bottom: 8px; }
.lede--sub { font-size: 16px; color: var(--fg-muted); margin-bottom: 36px; }

/* ---------- Feature cards ---------- */
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 18px; }
.card-grid--wide { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.card {
  border: 1px solid rgba(var(--accent-rgb), 0.22);
  background: var(--card-bg);
  padding: 26px 22px;
  border-radius: 4px;
  transition: all 140ms ease;
}
.card:hover { border-color: rgba(var(--accent-rgb), 0.6); box-shadow: 0 0 20px rgba(var(--accent-rgb), 0.15); transform: translateY(-2px); }
.card--pad-lg { padding: 28px 24px; }
.card__icon { font-family: var(--font-mono); color: var(--accent); font-size: 22px; margin-bottom: 14px; }
.card__tag { font-family: var(--font-mono); font-size: 12px; color: var(--accent); letter-spacing: 0.12em; margin-bottom: 12px; }
.card__title { font-family: var(--font-mono); font-weight: 700; font-size: 16px; color: var(--fg-strong); margin-bottom: 8px; }
.card__title--lg { font-size: 18px; margin-bottom: 10px; }
.card__text { margin: 0; font-size: 14px; line-height: 1.55; color: var(--fg-muted); }

/* ---------- Stats ---------- */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 16px; margin-bottom: 36px; }
.stat-card {
  border: 1px solid rgba(var(--accent-rgb), 0.2);
  background: var(--card-bg);
  padding: 24px 18px; border-radius: 4px; text-align: center;
}
.stat-card__value {
  font-family: var(--font-mono); font-weight: 800; font-size: clamp(30px, 3.6vw, 42px);
  color: var(--accent); text-shadow: 0 0 18px rgba(var(--accent-rgb), 0.4);
}
.stat-card__label { font-family: var(--font-sans); font-size: 13px; font-weight: 500; color: var(--fg-muted); letter-spacing: 0.02em; margin-top: 8px; }

/* ---------- Map ---------- */
.map-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, 320px); gap: 28px; align-items: start; }
.map-board {
  position: relative;
  border: 1px solid rgba(var(--accent-rgb), 0.2);
  background: var(--card-bg);
  border-radius: 4px;
  padding: 24px;
}
.map-board__lines {
  position: absolute; inset: 24px; pointer-events: none; z-index: 3;
  background-image: linear-gradient(90deg, var(--card-bg) 0px, var(--card-bg) 1px, transparent 1px);
  background-size: calc(100% / 96) 100%;
  opacity: 0.85;
}
.map-grid { display: flex; flex-direction: column; gap: 1px; position: relative; }
.map-row { display: flex; gap: 1px; }
.map-cell { border-radius: 1px; position: relative; }

.map-info {
  position: relative;
  border: 1px solid rgba(var(--accent-rgb), 0.25);
  background: var(--card-bg);
  border-radius: 4px; padding: 22px;
  position: sticky; top: 90px;
}
.map-info__coord {
  position: absolute; top: 20px; right: 20px;
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.12em;
  color: var(--fg-dimmer); text-align: right; line-height: 1.5;
}
.map-info__eyebrow { font-family: var(--font-mono); font-size: 11px; color: var(--fg-dim); letter-spacing: 0.14em; margin-bottom: 12px; }
.map-info__name {
  font-family: var(--font-mono); font-weight: 800; font-size: 20px; color: var(--accent);
  text-shadow: 0 0 16px rgba(var(--accent-rgb), 0.35); margin-bottom: 6px;
  min-height: 24px;
}
.map-info__domain { font-family: var(--font-sans); font-weight: 600; font-size: 15px; color: var(--fg-strong); margin-bottom: 10px; min-height: 19px; }
.map-info__desc { margin: 0 0 16px; font-size: 14px; line-height: 1.6; color: var(--fg-muted); }

.legend { display: flex; flex-direction: column; gap: 8px; margin-top: 18px; }
.legend__item {
  display: flex; align-items: center; gap: 10px;
  background: none; border: none; padding: 4px 0; cursor: pointer; text-align: left;
  font-family: var(--font-sans); font-size: 13px; color: var(--fg-muted); width: 100%;
}
.legend__item.is-active { color: var(--fg-strong); }
.legend__swatch { width: 10px; height: 10px; border-radius: 1px; flex-shrink: 0; }

.classified-box {
  margin-top: 16px;
  border: 1px solid rgba(143,191,180,0.45);
  background: #0C1614; border-radius: 4px; padding: 16px;
  animation: declassify 900ms cubic-bezier(.22,.61,.36,1) both;
}
.classified-box__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.classified-box__tag { font-family: var(--font-mono); font-weight: 800; font-size: 13px; color: #C7E6DE; letter-spacing: 0.1em; }
.classified-box__stamp {
  font-family: var(--font-mono); font-size: 10px; color: #8FBFB4;
  border: 1px solid rgba(143,191,180,0.6); padding: 3px 7px; letter-spacing: 0.16em;
  transform: rotate(-3deg);
}
.classified-box__body { margin: 0; font-family: var(--font-mono); font-size: 11px; line-height: 1.65; color: #7FA79C; }

/* ---------- Team ---------- */
.team-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 18px; }
.team-card {
  border: 1px solid rgba(var(--accent-rgb), 0.2);
  background: var(--card-bg);
  border-radius: 4px; overflow: hidden; transition: all 140ms ease;
}
.team-card:hover { border-color: rgba(var(--accent-rgb), 0.55); transform: translateY(-2px); box-shadow: 0 0 20px rgba(var(--accent-rgb), 0.12); }
.team-card__photo {
  aspect-ratio: 1;
  background: linear-gradient(140deg, var(--card-bg), #123028);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono); font-weight: 800; font-size: 40px;
  color: rgba(var(--accent-rgb), 0.5);
  border-bottom: 1px solid rgba(var(--accent-rgb), 0.15);
  overflow: hidden;
}
.team-card__photo-img { width: 100%; height: 100%; background-size: cover; background-position: center 18%; }
.team-card__body { padding: 16px; }
.team-card__row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.team-card__name { font-family: var(--font-sans); font-weight: 700; font-size: 15px; color: var(--fg-strong); }
.team-card__in {
  color: var(--fg-dim); font-family: var(--font-mono); font-size: 13px;
  border: 1px solid rgba(var(--accent-rgb), 0.25); padding: 2px 6px; border-radius: 3px;
  transition: color 140ms ease, border-color 140ms ease;
}
.team-card__in:hover { color: var(--accent); border-color: var(--accent); }
.team-card__role { font-size: 13px; color: var(--fg-muted); margin-top: 5px; }

/* ---------- Partners ---------- */
.partners-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap; margin-bottom: 48px; }
.partners-head__left { display: flex; flex-direction: column; gap: 12px; }
.partner-groups { display: flex; flex-direction: column; gap: 40px; }
.partner-group { display: flex; flex-direction: column; align-items: center; gap: 16px; }
.partner-group__label-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: center; }
.partner-group__rule { width: 28px; height: 1px; background: rgba(var(--accent-rgb), 0.3); }
.partner-group__label { font-family: var(--font-mono); font-size: 11px; color: var(--accent); letter-spacing: 0.18em; }
.partner-group__sub { font-family: var(--font-sans); font-size: 13px; color: var(--fg-dim); }
.partner-logos { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.partner-logos--nowrap { flex-wrap: nowrap; }
.partner-item { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.partner-item__label { font-family: var(--font-mono); font-size: 11px; color: var(--accent); letter-spacing: 0.16em; }

.logo-card {
  width: 200px; height: 120px;
  border: 1px solid rgba(var(--accent-rgb), 0.16);
  background-color: var(--card-bg);
  border-radius: 4px;
  display: flex; align-items: center; justify-content: center; padding: 12px;
  position: relative; overflow: hidden; opacity: 0.82;
  background-image: linear-gradient(90deg, var(--accent), var(--accent));
  background-repeat: no-repeat; background-position: left bottom; background-size: 0% 1px;
  transition: opacity 200ms cubic-bezier(.22,.61,.36,1), transform 200ms cubic-bezier(.22,.61,.36,1),
    border-color 200ms cubic-bezier(.22,.61,.36,1), box-shadow 200ms cubic-bezier(.22,.61,.36,1),
    background-color 200ms cubic-bezier(.22,.61,.36,1), background-size 420ms cubic-bezier(.22,.61,.36,1);
}
.logo-card:hover {
  opacity: 1; transform: translateY(-3px);
  border-color: rgba(var(--accent-rgb), 0.45);
  background-color: var(--card-bg-alt);
  background-size: 100% 1px;
  box-shadow: 0 10px 24px -10px rgba(0,0,0,0.6);
}
.logo-card--sm { width: 172px; height: 96px; }
.logo-card--flex { flex: 0 1 200px; min-width: 0; height: 120px; }
.logo-card--flex-sm { flex: 0 1 172px; min-width: 0; height: 96px; }
/* Extra-wide variant for banner-shaped logos (e.g. Innovate Moldova's
   lockup, which also carries the Sweden/UK funder flags and is much wider
   than it is tall) — the card's own width is what limits an img's
   rendered size here (max-width:100%, height auto), so a very wide/short
   source image stays visually tiny in a standard 200px card no matter
   what max-height you put on it. Widening the card gives it real room. */
.logo-card--wide { width: 340px; height: 120px; }
.logo-card img { max-width: 100%; width: auto; object-fit: contain; display: block; }

/* ---------- About Sigmoid ---------- */
.sigmoid-head { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; margin: 0 0 30px; }
.sigmoid-head__logo { height: 96px; width: auto; display: block; filter: drop-shadow(0 0 24px rgba(var(--accent-rgb),0.2)); }
.sigmoid-head__mission { flex: 1 1 300px; min-width: 260px; padding-left: 22px; border-left: 1px solid rgba(var(--accent-rgb), 0.22); }
.sigmoid-head__mission-title { font-family: var(--font-mono); font-weight: 700; font-size: 17px; color: var(--accent); margin-bottom: 10px; }
.sigmoid-head__mission-text { margin: 0; font-size: 16px; line-height: 1.6; color: var(--fg-muted); }
.sigmoid-why { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 40px; max-width: 100%; margin: 0 0 44px; }
.sigmoid-why__title { font-family: var(--font-mono); font-weight: 700; font-size: 17px; color: var(--accent); margin-bottom: 10px; }
.sigmoid-why__text { margin: 0; font-size: 16px; line-height: 1.6; color: var(--fg-muted); }
.sigmoid-lead { margin: 0 0 24px; max-width: 680px; font-size: 16px; line-height: 1.6; color: var(--fg-muted); }

/* ---------- FAQ ---------- */
.faq-list { display: flex; flex-direction: column; gap: 12px; }
.faq-item { border: 1px solid rgba(var(--accent-rgb), 0.2); background: var(--card-bg); border-radius: 4px; overflow: hidden; }
.faq-item__btn {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 20px; background: none; border: none; cursor: pointer; text-align: left;
  font-family: var(--font-mono); font-weight: 700; font-size: 15px; color: var(--fg-strong);
  transition: color 140ms ease;
}
.faq-item__btn:hover { color: var(--accent); }
.faq-item__marker { color: var(--accent); flex-shrink: 0; }
.faq-item__answer {
  padding: 0 20px 20px; font-size: 15px; line-height: 1.6; color: var(--fg-muted);
  border-top: 1px dashed rgba(var(--accent-rgb), 0.15); padding-top: 16px;
}

/* ---------- Tickets CTA ---------- */
.cta-section { position: relative; padding: 110px 24px; text-align: center; overflow: clip; }
.cta-section__glow {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse 60% 70% at 50% 100%, rgba(var(--accent-deep-rgb),0.25), transparent 70%);
}
.cta-section__inner { position: relative; max-width: 700px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; gap: 22px; }
.cta-section__eyebrow { font-family: var(--font-mono); font-size: 13px; color: var(--accent); letter-spacing: 0.16em; }
.cta-section__title { margin: 0; font-family: var(--font-mono); font-weight: 800; font-size: clamp(32px, 5vw, 56px); color: var(--fg-strong); letter-spacing: -0.02em; white-space: nowrap; }
.cta-section__text { margin: 0; font-size: 17px; color: var(--fg-muted); max-width: none; line-height: 1.6; white-space: nowrap; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid rgba(var(--accent-rgb), 0.15); padding: 48px 24px 36px; font-family: var(--font-sans); }
.footer__grid {
  max-width: var(--max-content); margin: 0 auto;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 32px; align-items: start;
}
.footer__brand { display: flex; flex-direction: column; gap: 12px; }
.footer__brand-row { display: flex; align-items: center; gap: 10px; font-family: var(--font-mono); font-weight: 800; font-size: 15px; color: var(--fg-strong); letter-spacing: 0.06em; }
.footer__brand-row img { height: 24px; width: auto; display: block; }
.footer__brand-text { font-size: 12px; color: var(--fg-dim); line-height: 1.6; }
.footer__col { display: flex; flex-direction: column; gap: 10px; font-size: 13px; }
.footer__col-label { font-family: var(--font-mono); font-size: 11px; color: var(--fg-dim); letter-spacing: 0.14em; }
.footer__col a { color: var(--fg-muted); transition: color 140ms ease; }
.footer__col a:hover { color: var(--accent); }
.footer__meta { display: flex; flex-direction: column; gap: 10px; font-size: 12px; color: var(--fg-dim); line-height: 1.6; }

/* ---------- Utility ---------- */
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ==========================================================================
   Responsive
   ========================================================================== */

/* ---- Tablet / small desktop: nav collapses to a burger menu ---- */
@media (max-width: 880px) {
  .nav__burger { display: flex; }

  .nav__links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 49;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    background: rgba(10, 15, 13, 0.97);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(var(--accent-rgb), 0.18);
    padding: 4px 24px 0;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transition: max-height 280ms cubic-bezier(.22,.61,.36,1), opacity 200ms ease;
  }
  .nav.is-open .nav__links {
    max-height: 480px;
    opacity: 1;
    pointer-events: auto;
  }
  .nav__links > * { width: 100%; }
  .nav__link, .nav__link--alt {
    padding: 14px 2px;
    border-bottom: 1px solid rgba(var(--accent-rgb), 0.1);
  }
  .lang-btn, .ticket-btn {
    margin: 14px 0;
    text-align: center;
  }

  .map-layout { grid-template-columns: 1fr; }
  .map-info { position: static; top: auto; }

  .team-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* ---- Phone ---- */
@media (max-width: 600px) {
  .section { padding: 64px 20px; }
  #stats { padding: 56px 20px; }
  .hero { padding: 108px 20px 56px; }
  .cta-section { padding: 72px 20px; }

  .nav { padding: 12px 16px; }
  .nav__links { padding-left: 16px; padding-right: 16px; }

  .hero__title-line1, .hero__title-line2 { white-space: normal; }
  .hero__title { font-size: clamp(30px, 8vw, 56px); }

  .countdown { gap: 6px; }
  .countdown__value { font-size: clamp(24px, 8vw, 44px); }
  .countdown__sep { font-size: clamp(18px, 6vw, 34px); }

  .cta-section__title, .cta-section__text { white-space: normal; }

  /* Stack the two hero CTAs and make them match widths instead of wrapping
     side by side at mismatched, content-sized widths (this used to only
     kick in below 380px, which misses most phones — 390px+ — entirely). */
  .hero__ctas { flex-direction: column; align-items: stretch; }
  .hero__ctas .btn-primary, .hero__ctas .btn-ghost { justify-content: center; text-align: center; }

  .team-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .team-card__photo { font-size: 28px; }

  .map-board { padding: 14px; }
  .map-board__lines { inset: 14px; }
  .map-info { padding: 18px; }

  .partners-head { flex-direction: column; align-items: flex-start; }
  .partner-logos--nowrap { flex-wrap: wrap; }
  .partner-logos--nowrap .logo-card--flex,
  .partner-logos--nowrap .logo-card--flex-sm { flex: 0 1 45%; }

  .sigmoid-head { flex-direction: column; align-items: flex-start; }
  /* `flex: 1 1 300px` on .sigmoid-head__mission sets a *width* basis for the
     desktop row layout; once .sigmoid-head switches to a column here, that
     same flex-basis is read as a 300px *height* instead, leaving a big empty
     gap under the (much shorter) mission text. Reset it to size to content. */
  .sigmoid-head__mission { flex-basis: auto; border-left: none; border-top: 1px solid rgba(var(--accent-rgb), 0.22); padding-left: 0; padding-top: 16px; }

  .footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 380px) {
  .team-grid { grid-template-columns: 1fr 1fr; }
  .pill-row { font-size: 12px; }
}
