/* =========================================================
   zone-jbo.com.cn — shared site.css
   Night command deck + exhibition index
   ========================================================= */

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

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

body, h1, h2, h3, h4, p, ul, ol, figure, blockquote, dl, dd { margin: 0; }
ul[class], ol[class] { list-style: none; padding: 0; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }

/* ---------- tokens ---------- */
:root {
  --ink: #07131F;
  --hull: #0D2233;
  --steel: #587080;
  --glass: #9CB6C6;
  --cyan: #21E6C1;
  --teal: #0B8F80;
  --gold: #FF8A3D;
  --sand: #FFC48A;
  --violet: #8A7CFF;
  --fog: #EAF6FF;
  --abyss: #030A12;

  --font-sans: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-mono: "JetBrains Mono", "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;

  --wrap: 1180px;
  --gutter: clamp(1rem, 4vw, 2.5rem);

  --line: rgba(156, 182, 198, 0.18);
  --line-strong: rgba(156, 182, 198, 0.34);
  --glass-bg: rgba(156, 182, 198, 0.08);
  --glass-bg-strong: rgba(156, 182, 198, 0.14);

  --radius-sm: 3px;
  --radius: 8px;
  --radius-lg: 16px;

  --dur: 180ms;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);

  --fs-12: 0.75rem;
  --fs-14: 0.875rem;
  --fs-16: 1rem;
  --fs-20: 1.25rem;
  --fs-28: 1.75rem;
  --fs-40: 2.5rem;
  --fs-64: 4rem;
  --fs-96: 6rem;
}

/* ---------- base ---------- */
body {
  min-height: 100vh;
  background-color: var(--ink);
  background-image:
    radial-gradient(900px 520px at 88% -10%, rgba(33, 230, 193, 0.09), transparent 62%),
    radial-gradient(720px 460px at 2% 6%, rgba(255, 138, 61, 0.07), transparent 64%);
  background-repeat: no-repeat;
  background-attachment: fixed;
  color: var(--fog);
  font-family: var(--font-sans);
  font-size: var(--fs-16);
  font-weight: 400;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection {
  background: rgba(33, 230, 193, 0.32);
  color: var(--fog);
}

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

/* ---------- layout helpers ---------- */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.wrap--narrow { max-width: 760px; }

.section { padding-block: clamp(2.5rem, 6vw, 5rem); }

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--line);
  margin-bottom: 1.75rem;
}

.section-kicker {
  font-family: var(--font-mono);
  font-size: var(--fs-12);
  letter-spacing: 0.14em;
  color: var(--teal);
  text-transform: uppercase;
}

.section-title {
  font-size: clamp(1.5rem, 3.4vw, var(--fs-40));
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1.25;
  color: var(--fog);
}

.lede {
  max-width: 62ch;
  font-size: var(--fs-16);
  line-height: 1.8;
  color: var(--glass);
}

.mono-label {
  font-family: var(--font-mono);
  font-size: var(--fs-12);
  letter-spacing: 0.08em;
  color: var(--steel);
}

.divider {
  height: 1px;
  border: 0;
  background: linear-gradient(90deg, var(--line-strong), transparent);
  margin-block: 2rem;
}

/* ---------- panels ---------- */
.panel {
  background: var(--hull);
  border-radius: var(--radius);
  padding: clamp(1.25rem, 3vw, 2rem);
}
.panel--glass {
  background: var(--glass-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.25rem, 3vw, 2rem);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

/* ---------- breadcrumbs ---------- */
.breadcrumbs { padding-block: 0.875rem; }
.breadcrumbs__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: var(--fs-12);
  letter-spacing: 0.06em;
  color: var(--steel);
}
.breadcrumbs__item::after {
  content: "/";
  margin-left: 0.5rem;
  color: rgba(88, 112, 128, 0.6);
}
.breadcrumbs__item:last-child::after { content: ""; margin-left: 0; }
.breadcrumbs__item a { color: var(--glass); }
.breadcrumbs__item a:hover { color: var(--cyan); }
.breadcrumbs__item [aria-current="page"] { color: var(--fog); }

/* ---------- tags & pills ---------- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.25rem 0.625rem;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: var(--fs-12);
  letter-spacing: 0.08em;
  border: 1px solid transparent;
  white-space: nowrap;
}
.tag--cyan { color: var(--cyan); border-color: rgba(33, 230, 193, 0.42); background: rgba(33, 230, 193, 0.1); }
.tag--gold { color: var(--gold); border-color: rgba(255, 138, 61, 0.45); background: rgba(255, 138, 61, 0.1); }
.tag--violet { color: var(--violet); border-color: rgba(138, 124, 255, 0.45); background: rgba(138, 124, 255, 0.1); }
.tag--sand { color: var(--sand); border-color: rgba(255, 196, 138, 0.42); background: rgba(255, 196, 138, 0.08); }

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4375rem;
  padding: 0.1875rem 0.625rem 0.1875rem 0.5rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: var(--fs-12);
  letter-spacing: 0.08em;
}
.status-pill::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}
.status-pill--live { color: var(--cyan); background: rgba(33, 230, 193, 0.12); }
.status-pill--check { color: var(--gold); background: rgba(255, 138, 61, 0.12); }
.status-pill--archive { color: var(--glass); background: var(--glass-bg); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.625rem 1.125rem;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font-family: var(--font-sans);
  font-size: var(--fs-14);
  font-weight: 600;
  letter-spacing: 0.06em;
  line-height: 1.3;
  transition: background var(--dur) var(--ease),
              color var(--dur) var(--ease),
              border-color var(--dur) var(--ease),
              filter var(--dur) var(--ease);
}
.btn:active { filter: brightness(1.14); }

.btn--primary { background: var(--cyan); color: var(--ink); }
.btn--primary:hover { background: #45f0d3; }

.btn--ghost {
  border-color: rgba(33, 230, 193, 0.42);
  color: var(--cyan);
  background: rgba(33, 230, 193, 0.04);
}
.btn--ghost:hover { background: rgba(33, 230, 193, 0.14); border-color: var(--cyan); }

.btn--gold { background: var(--gold); color: var(--ink); }
.btn--gold:hover { background: #ffa063; }

/* ---------- figure containers (page-stage image slots) ---------- */
.figure {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  background:
    linear-gradient(150deg, rgba(13, 34, 51, 0.96), rgba(7, 19, 31, 0.98));
}
.figure > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.figure--ratio-16x9 { aspect-ratio: 16 / 9; }
.figure--ratio-4x3 { aspect-ratio: 4 / 3; }
.figure--ratio-1x1 { aspect-ratio: 1 / 1; }
.figure--device {
  aspect-ratio: 9 / 16;
  width: 100%;
  max-width: 320px;
  margin-inline: auto;
}
.figure__tag {
  position: absolute;
  left: 0.75rem;
  bottom: 0.75rem;
  padding: 0.25rem 0.625rem;
  border-radius: var(--radius-sm);
  background: rgba(3, 10, 18, 0.82);
  border: 1px solid rgba(33, 230, 193, 0.32);
  font-family: var(--font-mono);
  font-size: var(--fs-12);
  letter-spacing: 0.08em;
  color: var(--cyan);
}

/* ---------- filter component ---------- */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding-block: 0.25rem;
}
.filter-btn {
  padding: 0.4375rem 0.875rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong);
  font-family: var(--font-mono);
  font-size: var(--fs-12);
  letter-spacing: 0.08em;
  color: var(--glass);
  background: transparent;
  transition: color var(--dur) var(--ease),
              border-color var(--dur) var(--ease),
              background var(--dur) var(--ease);
}
.filter-btn:hover { color: var(--fog); border-color: var(--glass); }
.filter-btn[aria-pressed="true"] {
  color: var(--ink);
  background: var(--cyan);
  border-color: var(--cyan);
}
.filter-count {
  font-family: var(--font-mono);
  font-size: var(--fs-12);
  letter-spacing: 0.08em;
  color: var(--steel);
  margin-block: 0.75rem;
}
[data-filter-item][hidden] { display: none !important; }

@keyframes filterIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}
.is-filtered-in { animation: filterIn 180ms var(--ease) both; }

/* =========================================================
   HEADER
   ========================================================= */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -100px;
  z-index: 200;
  padding: 0.625rem 1rem;
  border-radius: var(--radius-sm);
  background: var(--cyan);
  color: var(--ink);
  font-size: var(--fs-14);
  font-weight: 700;
  letter-spacing: 0.06em;
  transition: top var(--dur) var(--ease);
}
.skip-link:focus { top: 0.625rem; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(7, 19, 31, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow var(--dur) var(--ease),
              background var(--dur) var(--ease);
}
.site-header.is-scrolled {
  background: rgba(5, 15, 25, 0.98);
  box-shadow: 0 14px 34px rgba(3, 10, 18, 0.55);
}

/* --- command rail --- */
.command-rail {
  background: linear-gradient(90deg, rgba(3, 10, 18, 0.98), rgba(13, 34, 51, 0.92));
  border-bottom: 1px solid rgba(33, 230, 193, 0.16);
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  color: var(--glass);
}
.command-rail__inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  max-width: var(--wrap);
  margin-inline: auto;
  padding: 0.4375rem var(--gutter);
}
.command-rail__status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--fog);
}
.command-rail__hint {
  margin-left: auto;
  color: var(--steel);
}
.command-rail__cta {
  color: var(--cyan);
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur) var(--ease);
}
.command-rail__cta:hover,
.command-rail__cta:focus-visible { border-bottom-color: var(--cyan); }

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 0 3px rgba(33, 230, 193, 0.18);
  animation: statusPulse 2.6s ease-in-out infinite;
}
@keyframes statusPulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(33, 230, 193, 0.18); }
  50% { box-shadow: 0 0 0 6px rgba(33, 230, 193, 0.05); }
}

/* --- nav shell --- */
.nav-shell__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: var(--wrap);
  margin-inline: auto;
  padding: 0.6875rem var(--gutter);
  min-height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  flex: 0 0 auto;
}
.brand__mark {
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--ink);
  background: var(--cyan);
  padding: 0.375rem 0.625rem;
  border-radius: 2px;
  clip-path: polygon(0 0, 100% 0, 100% 72%, 86% 100%, 0 100%);
}
.brand__text {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}
.brand__line {
  font-size: 0.9375rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--fog);
}
.brand__sub {
  font-family: var(--font-mono);
  font-size: 0.625rem;
  letter-spacing: 0.16em;
  color: var(--steel);
}

.nav__list {
  display: flex;
  align-items: center;
  gap: 0.125rem;
}
.nav__link {
  display: inline-flex;
  align-items: baseline;
  gap: 0.375rem;
  padding: 0.5rem 0.625rem;
  border-radius: var(--radius-sm);
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
  color: var(--glass);
  transition: color var(--dur) var(--ease),
              background var(--dur) var(--ease),
              box-shadow var(--dur) var(--ease);
}
.nav__link:hover {
  color: var(--fog);
  background: var(--glass-bg);
}
.nav__idx {
  font-family: var(--font-mono);
  font-size: 0.625rem;
  letter-spacing: 0.06em;
  color: var(--teal);
  transition: color var(--dur) var(--ease);
}
.nav__link:hover .nav__idx { color: var(--cyan); }
.nav__link[aria-current="page"] {
  color: var(--cyan);
  background: rgba(33, 230, 193, 0.1);
  box-shadow: inset 0 -2px 0 var(--cyan);
}
.nav__link[aria-current="page"] .nav__idx { color: var(--cyan); }

.nav-shell__actions {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  flex: 0 0 auto;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 40px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  transition: border-color var(--dur) var(--ease);
}
.nav-toggle:hover { border-color: var(--cyan); }
.nav-toggle__bar {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--fog);
  transition: transform var(--dur) var(--ease), opacity var(--dur) var(--ease);
}
.nav-toggle.is-open .nav-toggle__bar:nth-child(1) { transform: translateY(3.5px) rotate(45deg); }
.nav-toggle.is-open .nav-toggle__bar:nth-child(2) { transform: translateY(-3.5px) rotate(-45deg); }

/* --- scroll meter --- */
.scroll-meter {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  overflow: hidden;
  pointer-events: none;
  background: rgba(156, 182, 198, 0.12);
}
.scroll-meter__fill {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, var(--cyan), var(--gold));
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform 90ms linear;
}

/* --- mobile quick rail --- */
.quickrail { display: none; }

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer {
  margin-top: clamp(3rem, 7vw, 6rem);
  background: linear-gradient(180deg, var(--ink) 0%, var(--abyss) 100%);
  border-top: 1px solid var(--line);
  color: var(--glass);
  padding-top: clamp(2.5rem, 6vw, 4rem);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.25rem;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
  padding-bottom: clamp(2rem, 5vw, 3rem);
}
.footer-brand { max-width: 34ch; }
.footer-brand__mark {
  font-family: var(--font-mono);
  font-size: clamp(1.75rem, 5vw, 2.5rem);
  font-weight: 300;
  letter-spacing: 0.12em;
  color: var(--fog);
  line-height: 1;
}
.footer-brand__mark span {
  font-size: 0.4375em;
  color: var(--teal);
  letter-spacing: 0.2em;
  margin-left: 0.25rem;
}
.footer-brand__name {
  margin-top: 0.75rem;
  font-size: var(--fs-16);
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--fog);
}
.footer-brand__desc {
  margin-top: 0.625rem;
  font-size: var(--fs-14);
  line-height: 1.8;
  color: var(--steel);
}
.footer-brand__tag {
  display: inline-block;
  margin-top: 1rem;
  padding: 0.25rem 0.625rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 138, 61, 0.38);
  font-family: var(--font-mono);
  font-size: var(--fs-12);
  letter-spacing: 0.08em;
  color: var(--gold);
}

.footer-label {
  font-family: var(--font-mono);
  font-size: var(--fs-12);
  letter-spacing: 0.16em;
  color: var(--teal);
  padding-bottom: 0.75rem;
  margin-bottom: 0.75rem;
  border-bottom: 1px solid var(--line);
}
.footer-nav__list {
  display: grid;
  gap: 0.125rem;
}
.footer-nav__link {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  padding: 0.375rem 0;
  font-size: var(--fs-14);
  color: var(--glass);
  transition: color var(--dur) var(--ease);
}
.footer-nav__link:hover,
.footer-nav__link:focus-visible { color: var(--cyan); }
.footer-nav__idx {
  font-family: var(--font-mono);
  font-size: var(--fs-12);
  letter-spacing: 0.06em;
  color: var(--steel);
}
.footer-line {
  font-size: var(--fs-14);
  line-height: 1.9;
  color: var(--glass);
  word-break: break-word;
}
.footer-line--dim { color: var(--steel); font-size: var(--fs-12); }

.footer-base {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  max-width: var(--wrap);
  margin-inline: auto;
  padding: 1.125rem var(--gutter) 1.5rem;
  border-top: 1px solid var(--line);
  font-size: var(--fs-12);
  color: var(--steel);
}
.footer-base__copy { line-height: 1.6; }
.footer-base__mono {
  font-family: var(--font-mono);
  letter-spacing: 0.06em;
  color: var(--glass);
}
.footer-base__legal {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
}
.footer-base__legal a {
  color: var(--glass);
  border-bottom: 1px solid transparent;
  transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.footer-base__legal a:hover,
.footer-base__legal a:focus-visible {
  color: var(--cyan);
  border-bottom-color: var(--cyan);
}

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (min-width: 700px) {
  .footer-grid {
    grid-template-columns: 1.3fr 1fr;
    gap: 2.5rem 3rem;
  }
  .footer-brand { grid-column: 1 / -1; }
}

@media (min-width: 900px) {
  .footer-grid {
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 3rem;
  }
  .footer-brand { grid-column: auto; }
}

@media (max-width: 899px) {
  body { padding-bottom: 4.75rem; }

  .command-rail__hint { display: none; }
  .command-rail__cta { margin-left: auto; }

  .nav {
    position: fixed;
    inset: 0;
    z-index: 40;
    margin: 0;
    padding: 6.5rem var(--gutter) 7rem;
    overflow-y: auto;
    background: rgba(7, 19, 31, 0.985);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-100%);
    transition: transform 220ms var(--ease),
                opacity 220ms var(--ease),
                visibility 0s linear 220ms;
  }
  .nav[data-open] {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: transform 220ms var(--ease),
                opacity 220ms var(--ease),
                visibility 0s linear 0s;
  }
  .nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0.125rem;
  }
  .nav__link {
    justify-content: flex-start;
    padding: 0.9375rem 0.75rem;
    border-radius: 0;
    border-bottom: 1px solid var(--line);
    font-size: 1.0625rem;
    color: var(--fog);
  }
  .nav__idx { font-size: 0.75rem; color: var(--teal); }
  .nav__link[aria-current="page"] {
    box-shadow: inset 3px 0 0 var(--cyan);
    background: rgba(33, 230, 193, 0.08);
  }

  .nav-shell__actions .btn--ghost { display: none; }
  .nav-toggle { display: inline-flex; }

  .quickrail {
    display: flex;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 55;
    gap: 0.25rem;
    padding: 0.375rem 0.5rem calc(0.375rem + env(safe-area-inset-bottom, 0px));
    background: rgba(3, 10, 18, 0.96);
    border-top: 1px solid rgba(33, 230, 193, 0.24);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
  }
  .quickrail__link {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.125rem;
    padding: 0.375rem 0.25rem;
    border-radius: var(--radius-sm);
    font-size: 0.6875rem;
    letter-spacing: 0.04em;
    color: var(--glass);
  }
  .quickrail__link[aria-current="page"] { color: var(--cyan); }
  .quickrail__idx {
    font-family: var(--font-mono);
    font-size: 0.5625rem;
    letter-spacing: 0.1em;
    color: var(--teal);
  }
  .quickrail__label { color: inherit; }
}

@media (max-width: 559px) {
  .brand__sub { display: none; }
  .footer-base { justify-content: flex-start; }
}

/* =========================================================
   MOTION PREFERENCES
   ========================================================= */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .status-dot { animation: none; }
  .scroll-meter__fill { transition: none; }
  .nav { transition: none; }
}
