/* ========== Reset ========== */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  min-height: 100vh;
  font-family: 'Inter', 'Noto Sans SC', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  background: #0B1526;
  color: #F5F2EB;
  -webkit-font-smoothing: antialiased;
}
img, picture, video, canvas, svg { display: block; max-width: 100%; }
input, button, textarea, select { font: inherit; color: inherit; }
button { background: none; border: none; cursor: pointer; }
h1, h2, h3, h4, h5, h6, p { overflow-wrap: break-word; }
a { color: inherit; }
ul, ol { padding-left: 1.4em; }
[hidden] { display: none !important; }

/* ========== Tokens ========== */
:root {
  --navy: #0B1526;
  --midnight: #132743;
  --neon: #39FF14;
  --orange: #FF6B00;
  --slate: #8B9BAB;
  --moss: #4A7C59;
  --terra: #C97B63;
  --cream: #F5F2EB;

  --bg: var(--navy);
  --bg-card: var(--midnight);
  --text: var(--cream);
  --text-2: var(--slate);
  --accent: var(--neon);
  --accent-2: var(--orange);

  --font-head: 'Archivo Black', 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --font-body: 'Inter', 'Noto Sans SC', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', system-ui, sans-serif;
  --font-data: 'JetBrains Mono', 'SFMono-Regular', 'Menlo', 'Consolas', 'Liberation Mono', monospace;

  --radius: 20px;
  --radius-pill: 999px;
  --container: 1240px;
  --track-w: 72px;
  --header-h: 112px;
  --transition: .3s cubic-bezier(.4, 0, .2, 1);
  color-scheme: dark;
}

/* ========== Base ========== */
::selection { background: rgba(57, 255, 20, .25); color: #F5F2EB; }
:focus { outline: none; }
:focus-visible {
  outline: 3px solid var(--neon);
  outline-offset: 3px;
  border-radius: 6px;
}
#main-content { scroll-margin-top: calc(var(--header-h) + 20px); }

/* ========== Layout Utilities ========== */
.main-content {
  position: relative;
  min-height: 65vh;
  z-index: 1;
}
@media (min-width: 1200px) {
  .main-content { margin-left: var(--track-w); }
}
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 24px;
}
.grid { display: grid; gap: 24px; }
.grid-cards { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }

/* ========== Buttons ========== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 26px;
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: .02em;
  text-decoration: none;
  line-height: 1.4;
  border: none;
  cursor: pointer;
  transition: background .3s ease, color .3s ease, transform .2s ease, box-shadow .3s ease;
}
.btn-primary {
  background: var(--orange);
  color: var(--navy);
}
.btn-primary:hover {
  background: #FF8240;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255, 107, 0, .35);
}
.btn-ghost {
  background: transparent;
  color: var(--cream);
  box-shadow: inset 0 0 0 1px rgba(245, 242, 235, .35);
}
.btn-ghost:hover {
  box-shadow: inset 0 0 0 1px var(--neon);
  color: var(--neon);
  background: rgba(57, 255, 20, .05);
}

/* ========== Section Titles ========== */
.section-title {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--font-head);
  font-size: clamp(26px, 3.4vw, 40px);
  font-weight: 900;
  line-height: 1.15;
  letter-spacing: .01em;
  color: var(--cream);
  transform: skewX(-5deg);
  margin-bottom: 28px;
}
.section-title::before {
  content: '';
  flex: 0 0 auto;
  width: 14px;
  height: 14px;
  background: var(--orange);
  border-radius: 3px;
  transform: skewX(-10deg) rotate(4deg);
  box-shadow: 0 0 16px rgba(255, 107, 0, .3);
}
.section-index {
  font-family: var(--font-data);
  font-size: 13px;
  color: var(--neon);
  letter-spacing: .1em;
  margin-right: 4px;
}

/* ========== Cards ========== */
.card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 28px;
  border: 1px solid rgba(139, 155, 171, .12);
  transition: all var(--transition);
}
.card:hover {
  border-color: rgba(57, 255, 20, .35);
  transform: translateY(-4px) rotate(-.4deg);
  box-shadow: 0 16px 40px rgba(0, 0, 0, .3);
}
.card-title {
  font-family: var(--font-head);
  font-size: 20px;
  font-weight: 800;
  color: var(--cream);
  line-height: 1.3;
  margin-bottom: 10px;
}
.card-text {
  font-size: 14px;
  color: var(--slate);
  line-height: 1.7;
}

/* ========== Media Frame ========== */
.media-frame {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: linear-gradient(140deg, var(--midnight), #0A1524);
  border: 1px solid rgba(139, 155, 171, .12);
}
.media-frame::before {
  content: '';
  display: block;
  aspect-ratio: 16 / 9;
  background: repeating-linear-gradient(-45deg, rgba(57, 255, 20, .04) 0, rgba(57, 255, 20, .04) 1px, transparent 1px, transparent 14px);
}
.media-frame img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .6s ease;
}
.media-frame:hover img {
  transform: scale(1.04) rotate(.3deg);
}

/* ========== Filter ========== */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 4px 0 24px;
}
.filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 18px;
  border: 1px solid rgba(139, 155, 171, .3);
  border-radius: var(--radius-pill);
  background: transparent;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  color: var(--slate);
  cursor: pointer;
  transition: all var(--transition);
}
.filter-btn:hover { color: var(--cream); border-color: rgba(57, 255, 20, .5); }
.filter-btn[aria-pressed="true"] {
  background: var(--neon);
  border-color: var(--neon);
  color: var(--navy);
  box-shadow: 0 4px 16px rgba(57, 255, 20, .25);
}

/* ========== Timeline ========== */
.timeline {
  position: relative;
  padding-left: 24px;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 11px;
  top: 4px;
  bottom: 4px;
  width: 2px;
  background: linear-gradient(180deg, rgba(57, 255, 20, .5), rgba(255, 107, 0, .2));
}
.timeline-item {
  position: relative;
  padding-left: 28px;
  margin-bottom: 28px;
}
.timeline-item::before {
  content: '';
  position: absolute;
  left: -18px;
  top: 6px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--navy);
  border: 2px solid var(--neon);
  box-shadow: 0 0 12px rgba(57, 255, 20, .4);
}

/* ========== Reveal Protocol ========== */
[data-reveal] {
  transition: opacity .7s ease, transform .7s ease;
}
.is-reveal-pending {
  opacity: 0;
  transform: translateY(26px);
}
.is-revealed {
  opacity: 1;
  transform: translateY(0);
}

/* ========== Skip Link ========== */
.skip-link {
  position: fixed;
  top: -100%;
  left: 16px;
  z-index: 300;
  padding: 12px 22px;
  background: var(--orange);
  color: var(--navy);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  border-radius: 0 0 12px 12px;
  transition: top .3s ease;
  box-shadow: 0 8px 24px rgba(255, 107, 0, .3);
}
.skip-link:focus { top: 0; }

/* ========== Header ========== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(11, 21, 38, .8);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(139, 155, 171, .14);
  transition: background .4s ease, box-shadow .4s ease;
}
.site-header[data-scrolled] {
  background: rgba(11, 21, 38, .96);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .4);
}
.header-progress {
  position: absolute;
  top: 0;
  left: 0;
  height: 2px;
  width: 0;
  background: linear-gradient(90deg, var(--neon), var(--orange));
  z-index: 10;
}
.header-inner {
  max-width: var(--container);
  margin-inline: auto;
}
.masthead {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 14px 24px 4px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}
.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--neon), #64FF3D);
  color: var(--navy);
  font-family: var(--font-head);
  font-size: 19px;
  font-weight: 900;
  border-radius: 10px;
  transform: skewX(-10deg) rotate(-2deg);
  box-shadow: 0 0 20px rgba(57, 255, 20, .3);
}
.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}
.brand-name {
  font-family: var(--font-head);
  font-size: clamp(20px, 2.6vw, 28px);
  font-weight: 900;
  letter-spacing: .08em;
  color: var(--cream);
  transform: skewX(-8deg);
}
.brand-sub {
  font-family: var(--font-data);
  font-size: 10px;
  letter-spacing: .3em;
  color: var(--neon);
  text-transform: uppercase;
  margin-top: 3px;
}

/* ========== Navigation ========== */
.site-nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 4px;
  padding: 8px 24px 14px;
}
.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 18px;
  border-radius: var(--radius-pill);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: .04em;
  color: var(--slate);
  text-decoration: none;
  transition: color .3s ease, background .3s ease, box-shadow .3s ease;
}
.nav-link:hover {
  color: var(--cream);
  background: rgba(57, 255, 20, .08);
}
.nav-link[aria-current="page"] {
  color: var(--neon);
  background: rgba(57, 255, 20, .1);
  box-shadow: inset 0 0 0 1px rgba(57, 255, 20, .35);
}

/* ========== Nav Toggle ========== */
.nav-toggle {
  display: none;
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  align-items: center;
  gap: 8px;
  background: rgba(57, 255, 20, .08);
  border: 1px solid rgba(57, 255, 20, .2);
  border-radius: var(--radius-pill);
  padding: 8px 16px;
  color: var(--cream);
  transition: background .3s ease;
}
.nav-toggle:hover { background: rgba(57, 255, 20, .16); }
.nav-toggle-bars {
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
}
.nav-toggle-bar {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--neon);
  border-radius: 2px;
  transition: transform .3s ease, opacity .3s ease;
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
.nav-toggle-label {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .1em;
  color: var(--cream);
}

/* ========== Brand Track ========== */
.brand-track {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: var(--track-w);
  height: 100vh;
  z-index: 90;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  padding: calc(var(--header-h) + 20px) 10px 24px;
  background: linear-gradient(180deg, rgba(19, 39, 67, 0) 0%, rgba(11, 21, 38, .35) 30%, rgba(11, 21, 38, .85) 100%);
  border-right: 1px solid rgba(139, 155, 171, .1);
  pointer-events: none;
  user-select: none;
}
@media (min-width: 1200px) {
  .brand-track { display: flex; }
}
.track-live-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(57, 255, 20, .1);
  border: 1px solid rgba(57, 255, 20, .3);
  border-radius: var(--radius-pill);
  padding: 5px 10px;
}
.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--neon);
  box-shadow: 0 0 10px var(--neon);
  animation: livePulse 2s ease-in-out infinite;
}
@keyframes livePulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(57, 255, 20, .6); }
  50% { opacity: .6; box-shadow: 0 0 0 6px rgba(57, 255, 20, 0); }
}
.track-live-text {
  font-family: var(--font-data);
  font-size: 10px;
  letter-spacing: .12em;
  color: var(--neon);
}
.track-words {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.track-word {
  writing-mode: vertical-rl;
  font-size: 11px;
  letter-spacing: .28em;
  color: var(--slate);
  border-left: 1px solid rgba(139, 155, 171, .22);
  padding-left: 8px;
  text-transform: uppercase;
}
.track-foot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.track-year {
  font-family: var(--font-data);
  font-size: 12px;
  color: var(--slate);
}
.track-seal {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: var(--orange);
  color: var(--navy);
  font-family: var(--font-head);
  font-size: 10px;
  font-weight: 900;
  border-radius: 8px;
  transform: skewX(-8deg);
  box-shadow: 0 4px 12px rgba(255, 107, 0, .3);
}

/* ========== Footer ========== */
.site-footer {
  position: relative;
  z-index: 2;
  background: linear-gradient(180deg, var(--midnight), var(--navy) 40%, #060D19);
  border-top: 1px solid rgba(139, 155, 171, .12);
}
.site-footer::before {
  content: '';
  display: block;
  height: 2px;
  background: linear-gradient(90deg, var(--neon), transparent 30%, transparent 70%, var(--orange));
  opacity: .5;
}
.site-footer::after {
  content: '';
  position: absolute;
  top: -40px;
  right: 8%;
  width: 320px;
  height: 160px;
  background: radial-gradient(closest-side, rgba(57, 255, 20, .09), transparent);
  pointer-events: none;
}
.footer-inner {
  max-width: var(--container);
  margin-inline: auto;
  padding: 56px 24px 40px;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1.4fr;
  gap: 48px;
}
@media (min-width: 1200px) {
  .site-footer .footer-inner {
    margin-left: var(--track-w);
  }
}
@media (max-width: 900px) {
  .footer-inner {
    grid-template-columns: 1fr;
    gap: 36px;
    padding: 40px 24px 28px;
  }
}
.footer-brand-col {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  transform: skewX(-6deg);
  width: fit-content;
}
.footer-brand-name {
  font-family: var(--font-head);
  font-size: 26px;
  font-weight: 900;
  letter-spacing: .06em;
  color: var(--cream);
}
.footer-brand-sub {
  font-family: var(--font-data);
  font-size: 11px;
  letter-spacing: .28em;
  color: var(--neon);
}
.footer-trust {
  font-size: 14px;
  line-height: 1.7;
  color: var(--slate);
  max-width: 360px;
}
.footer-col {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-col-title {
  font-family: var(--font-data);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .22em;
  color: var(--neon);
  text-transform: uppercase;
  margin-bottom: 6px;
}
.footer-col a {
  color: var(--slate);
  text-decoration: none;
  font-size: 14px;
  width: fit-content;
  transition: color .3s ease;
}
.footer-col a:hover { color: var(--neon); }
.footer-contact-line {
  font-size: 13px;
  color: var(--slate);
  line-height: 1.7;
}
.footer-contact-note {
  font-size: 12px;
  color: var(--terra);
  margin-top: 4px;
}
.footer-bottom {
  max-width: var(--container);
  margin-inline: auto;
  padding: 18px 24px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  border-top: 1px solid rgba(139, 155, 171, .1);
}
@media (min-width: 1200px) {
  .site-footer .footer-bottom {
    margin-left: var(--track-w);
  }
}
.footer-copy,
.footer-icp {
  font-size: 12px;
  color: var(--slate);
}

/* ========== Responsive ========== */
@media (max-width: 768px) {
  .masthead {
    padding: 12px 16px 2px;
  }
  .nav-toggle { display: inline-flex; }
  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 12px 20px 20px;
    background: rgba(11, 21, 38, .97);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    box-shadow: 0 24px 48px rgba(0, 0, 0, .45);
    border-bottom: 1px solid rgba(57, 255, 20, .2);
  }
  .site-nav[data-open] { display: flex; }
  .nav-link {
    width: 100%;
    text-align: center;
    padding: 14px 16px;
    font-size: 15px;
    border-radius: 12px;
  }
  .nav-link[aria-current="page"] {
    background: rgba(57, 255, 20, .12);
  }
}
@media (max-width: 480px) {
  .nav-toggle-label { display: none; }
  .nav-toggle { padding: 10px; }
}

/* ========== Reduced Motion ========== */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  [data-reveal] { transition: none !important; }
  .is-reveal-pending {
    opacity: 1 !important;
    transform: none !important;
  }
}
