:root {
  --ink: #071C18;
  --ink-2: #0D3029;
  --cyan: #00E5C3;
  --cyan-soft: #8CF7E7;
  --warn: #FFD166;
  --red: #FF4D5E;
  --paper: #F4F7F5;
  --muted: #A9BDB5;
  --line: #123A34;
  --cyan-dim: #008C7A;
  --shell: 1240px;
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-pill: 999px;
  --font-display: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", "Heiti SC", sans-serif;
  --font-body: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --font-mono: "SFMono-Regular", "Menlo", "Consolas", "Roboto Mono", monospace;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.7;
  letter-spacing: 0.01em;
  text-rendering: optimizeLegibility;
}

img, svg, video { max-width: 100%; height: auto; display: block; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.08;
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(40px, 7.6vw, 88px); }
h2 { font-size: clamp(28px, 4vw, 44px); }
h3 { font-size: clamp(20px, 2.4vw, 28px); }

p { margin: 0 0 1em; }

a { color: var(--cyan); text-decoration: none; transition: color 0.18s var(--ease); }
a:hover { color: var(--cyan-soft); }

ul { margin: 0; padding: 0; list-style: none; }

button { font: inherit; color: inherit; }

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

.shell {
  width: 100%;
  max-width: var(--shell);
  margin: 0 auto;
  padding-inline: 20px;
}

.skip-link {
  position: absolute;
  top: -80px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 90;
  padding: 10px 22px;
  border-radius: var(--radius-pill);
  background: var(--cyan);
  color: var(--ink);
  font-weight: 700;
  transition: top 0.2s var(--ease);
}
.skip-link:focus { top: 12px; color: var(--ink); }

/* ---------- Masthead ---------- */
.masthead {
  position: sticky;
  top: 0;
  z-index: 60;
  background: linear-gradient(180deg, #09231D 0%, var(--ink) 100%);
  border-bottom: 1px solid var(--line);
  transition: padding 0.24s var(--ease);
}

.masthead__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding-block: 20px 8px;
  text-align: center;
}

.masthead__brand { display: flex; flex-direction: column; align-items: center; gap: 4px; }

.masthead__brand-link { display: inline-flex; align-items: baseline; gap: 10px; color: var(--paper); }
.masthead__brand-link:hover { color: var(--paper); }

.masthead__brand-name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(30px, 5.4vw, 52px);
  letter-spacing: -0.03em;
  line-height: 1;
  background: linear-gradient(92deg, var(--paper) 30%, var(--cyan) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.masthead__edition {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.28em;
  color: var(--cyan-soft);
  border-left: 1px solid var(--line);
  padding-left: 10px;
  text-transform: uppercase;
}

.masthead__tagline {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.2em;
  color: var(--muted);
}

.masthead__utility {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}

.masthead__live { letter-spacing: 0.04em; }

.masthead__stage {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--muted);
  padding: 6px 12px;
  border: 1px dashed var(--line);
  border-radius: var(--radius-pill);
}

.masthead__search {
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  position: relative;
  transition: border-color 0.18s var(--ease), background 0.18s var(--ease);
}
.masthead__search:hover { border-color: var(--cyan); background: rgba(0, 229, 195, 0.08); }
.masthead__search-ring {
  position: absolute;
  inset: 11px 11px auto auto;
  width: 11px;
  height: 11px;
  border: 2px solid var(--cyan-soft);
  border-radius: 50%;
}
.masthead__search-ring::after {
  content: "";
  position: absolute;
  right: -6px;
  bottom: -5px;
  width: 7px;
  height: 2px;
  background: var(--cyan-soft);
  transform: rotate(45deg);
  border-radius: 2px;
}

.masthead__toggle {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  background: transparent;
  border: 1px solid var(--cyan-dim);
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: border-color 0.18s var(--ease), background 0.18s var(--ease);
}
.masthead__toggle:hover { border-color: var(--cyan); background: rgba(0, 229, 195, 0.1); }
.masthead__toggle-bar { width: 16px; height: 2px; background: var(--cyan); border-radius: 2px; display: block; }
.masthead__toggle-text { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.16em; color: var(--cyan-soft); }

.masthead__nav {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px 6px;
  padding-block: 10px 18px;
}

.masthead__nav-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
}

.nav-pill {
  display: inline-block;
  padding: 9px 18px;
  border-radius: var(--radius-pill);
  font-size: 15px;
  font-weight: 600;
  color: var(--paper);
  border: 1px solid transparent;
  transition: color 0.18s var(--ease), background 0.18s var(--ease), border-color 0.18s var(--ease);
}
.nav-pill:hover {
  color: var(--cyan);
  background: rgba(0, 229, 195, 0.08);
  border-color: var(--cyan-dim);
}
.nav-pill[aria-current="page"] {
  color: var(--ink);
  background: var(--cyan);
  border-color: var(--cyan);
  font-weight: 700;
}
.nav-pill[aria-current="page"]:hover { color: var(--ink); background: var(--cyan-soft); }

.masthead__cta { margin-left: 10px; }

.masthead__rule { height: 10px; }

.tick-rail {
  background-image: repeating-linear-gradient(
    to right,
    var(--line) 0,
    var(--line) 1px,
    transparent 1px,
    transparent 12px
  );
  background-position: left bottom;
  background-repeat: repeat-x;
  background-size: 12px 100%;
  opacity: 0.7;
}

.scroll-progress {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 2px;
  width: 100%;
  transform: scaleX(var(--progress, 0));
  transform-origin: left center;
  background: linear-gradient(90deg, var(--cyan), var(--cyan-soft) 60%, var(--warn));
}

/* ---------- Buttons & chips ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 26px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--cyan-dim);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: transform 0.16s var(--ease), background 0.18s var(--ease), color 0.18s var(--ease), border-color 0.18s var(--ease);
}
.btn--primary { background: var(--cyan); border-color: var(--cyan); color: var(--ink); }
.btn--primary:hover { background: var(--cyan-soft); border-color: var(--cyan-soft); color: var(--ink); transform: translateY(-2px); }
.btn--primary:active { background: var(--cyan-dim); color: var(--paper); transform: translateY(0); }
.btn--ghost { background: transparent; color: var(--cyan-soft); }
.btn--ghost:hover { color: var(--ink); background: var(--cyan-soft); border-color: var(--cyan-soft); transform: translateY(-2px); }
.btn--ghost:active { transform: translateY(0); }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.5;
  border: 1px solid var(--line);
  color: var(--cyan-soft);
  background: rgba(0, 229, 195, 0.06);
}
.chip--ghost { border-style: dashed; color: var(--muted); background: transparent; }
.chip--ghost:hover { color: var(--cyan); border-color: var(--cyan-dim); }
.chip--warn { color: var(--ink); background: var(--warn); border-color: var(--warn); }
.chip--red { color: var(--ink); background: var(--red); border-color: var(--red); }

/* ---------- Plates (exhibition caption) ---------- */
.plate {
  display: inline-flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 16px;
  border-radius: var(--radius-md);
  background: var(--paper);
  color: var(--ink);
  border: 1px solid var(--line);
}
.plate__label {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #4A625B;
}
.plate__value {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 20px;
  color: var(--ink);
}

/* ---------- Breadcrumb ---------- */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--muted);
  padding-block: 18px 0;
}
.breadcrumb__item { color: var(--muted); }
.breadcrumb__item a { color: var(--muted); }
.breadcrumb__item a:hover { color: var(--cyan); }
.breadcrumb__item + .breadcrumb__item::before { content: "/"; margin-right: 8px; color: var(--line); }

/* ---------- Layout utilities ---------- */
.prose {
  max-width: 68ch;
  color: #DCE7E2;
  font-size: 17px;
  line-height: 1.7;
}
.prose h2 { color: var(--paper); margin-top: 1.6em; }
.prose h3 { color: var(--cyan-soft); }
.prose a { border-bottom: 1px solid var(--cyan-dim); }

.grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.grid--asym { grid-template-columns: 1.35fr 1fr; }
.grid--cards { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }

.card {
  background: linear-gradient(160deg, var(--ink-2) 0%, #0A2620 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 22px;
  transition: transform 0.2s var(--ease), border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.card:hover {
  transform: translateY(-4px);
  border-color: var(--cyan-dim);
  box-shadow: 0 18px 40px -26px rgba(0, 229, 195, 0.55);
}

.section-head { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px; margin-bottom: 22px; }
.section-head__title { margin: 0; }
.section-head__note {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  color: var(--cyan-soft);
  writing-mode: vertical-rl;
  text-orientation: mixed;
  align-self: flex-start;
}

/* ---------- Image frames ---------- */
.img-frame {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  background:
    radial-gradient(circle at 22% 18%, rgba(0, 229, 195, 0.18), transparent 55%),
    linear-gradient(150deg, #0A2620 0%, var(--ink) 100%);
  aspect-ratio: 16 / 10;
}
.img-frame > img { width: 100%; height: 100%; object-fit: cover; }
.img-frame--wide { aspect-ratio: 21 / 9; }
.img-frame--tall { aspect-ratio: 3 / 4; }
.img-frame__caption {
  position: absolute;
  left: 14px;
  bottom: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  background: rgba(7, 28, 24, 0.82);
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.12em;
  color: var(--cyan-soft);
  backdrop-filter: blur(4px);
}

/* ---------- Timeline ---------- */
.timeline { position: relative; padding-left: 26px; }
.timeline::before {
  content: "";
  position: absolute;
  left: 6px;
  top: 4px;
  bottom: 4px;
  width: 1px;
  background: linear-gradient(180deg, var(--cyan-dim), transparent);
}
.timeline__item { position: relative; padding-block: 10px; }
.timeline__dot {
  position: absolute;
  left: -26px;
  top: 18px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  border: 2px solid var(--cyan);
  background: var(--ink);
  transition: background 0.18s var(--ease), box-shadow 0.18s var(--ease);
}
.timeline__item:hover .timeline__dot,
.timeline__item:focus-within .timeline__dot {
  background: var(--cyan);
  box-shadow: 0 0 0 5px rgba(0, 229, 195, 0.16);
}

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.5s var(--ease), transform 0.5s var(--ease); }
.reveal[data-visible] { opacity: 1; transform: none; }

/* ---------- Footer ---------- */
.footer {
  position: relative;
  background: var(--ink);
  border-top: 1px solid var(--line);
  padding-top: 46px;
  margin-top: 60px;
}
.footer__inner { display: grid; gap: 30px; grid-template-columns: 1.2fr 1.6fr 1.2fr; padding-bottom: 34px; }
.footer__brand-line {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(20px, 2.6vw, 26px);
  letter-spacing: -0.02em;
  color: var(--paper);
  margin-bottom: 10px;
}
.footer__region {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.22em;
  color: var(--cyan);
  border: 1px solid var(--cyan-dim);
  border-radius: var(--radius-pill);
  padding: 4px 14px;
  margin-bottom: 12px;
}
.footer__note { color: var(--muted); font-size: 13.5px; line-height: 1.75; margin: 0; }

.footer__cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.footer__col-title {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.2em;
  color: var(--cyan-soft);
  text-transform: uppercase;
  margin: 0 0 12px;
}
.footer__list li + li { margin-top: 8px; }
.footer__list a { color: #CBD9D3; font-size: 15px; }
.footer__list a:hover { color: var(--cyan); }

.footer__facts { display: flex; flex-direction: column; gap: 10px; }
.footer__fact { margin: 0; font-size: 14px; color: #CBD9D3; display: flex; flex-wrap: wrap; gap: 8px; }
.footer__fact-key {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  color: var(--muted);
  min-width: 62px;
}
.footer__fact a { color: #CBD9D3; word-break: break-all; }
.footer__fact a:hover { color: var(--cyan); }

.footer__rail { height: 10px; margin-bottom: 16px; }

.footer__legal {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  padding-block: 0 28px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--muted);
}
.footer__copy, .footer__icp { margin: 0; }

/* ---------- To top ---------- */
.to-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 70;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--cyan-dim);
  background: rgba(13, 48, 41, 0.9);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity 0.24s var(--ease), transform 0.24s var(--ease), visibility 0.24s, border-color 0.18s var(--ease);
}
.to-top[data-shown] { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { border-color: var(--cyan); background: rgba(0, 229, 195, 0.16); }
.to-top__arrow {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 12px;
  height: 12px;
  border-left: 2px solid var(--cyan);
  border-top: 2px solid var(--cyan);
  transform: rotate(45deg) translate(2px, 2px);
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .grid--asym { grid-template-columns: 1fr; }
  .footer__inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
  body { font-size: 15.5px; }

  .masthead__inner { padding-block: 14px 6px; gap: 8px; }
  .masthead__toggle { display: inline-flex; }
  .masthead__nav {
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    padding-block: 12px 18px;
    border-top: 1px solid var(--line);
  }
  .masthead__nav[data-open] { display: flex; }
  .masthead__nav-list { flex-direction: column; align-items: stretch; gap: 8px; }
  .nav-pill { display: block; text-align: center; }
  .masthead__cta { margin-left: 0; width: 100%; }

  .footer__inner { grid-template-columns: 1fr; }
  .footer__cols { grid-template-columns: 1fr 1fr; }
  .footer__legal { flex-direction: column; }
}

@media (max-width: 520px) {
  .shell { padding-inline: 16px; }
  .masthead__brand-link { flex-direction: column; align-items: center; gap: 4px; }
  .masthead__edition { border-left: 0; padding-left: 0; }
  .masthead__stage { display: none; }
  .footer__cols { grid-template-columns: 1fr; }
  .img-frame--tall { aspect-ratio: 4 / 5; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .reveal { opacity: 1; transform: none; }
  .to-top { transform: none; }
}
