/* ============================================================
   365官方游戏 · 共享样式表 /assets/site.css
   夜间电竞控制台 · 深色优先 · 切角面板 · 分区色块
   ============================================================ */

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 132px; }
body, h1, h2, h3, h4, p, ul, ol, li, figure, blockquote, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg, video { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
table { border-collapse: collapse; width: 100%; }
b, strong { font-weight: 700; }

/* ---------- tokens ---------- */
:root {
  --ink: #0B1030;
  --panel: #151A2E;
  --mist: #1E2542;
  --snow: #EDF2FF;
  --fog: #A8B3D1;
  --cyan: #2FE3E0;
  --amber: #FFA23A;
  --violet: #A66BFF;
  --deep-teal: #0D3A38;
  --wine: #4A1B2E;
  --online: #37E39B;
  --line: #2A3358;

  --font-display: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --font-body: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --font-serif: "Playfair Display", "Source Han Serif SC", "Songti SC", "SimSun", "Times New Roman", serif;
  --font-mono: "JetBrains Mono", "SFMono-Regular", "Cascadia Mono", Consolas, "Liberation Mono", monospace;

  --shell-w: 1180px;
  --gutter: 16px;
  --cut: 18px;
  --sp: clamp(48px, 7vw, 96px);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* ---------- base ---------- */
body {
  background-color: var(--ink);
  color: var(--snow);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.75;
  font-weight: 400;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

h1 { font-size: clamp(34px, 6.2vw, 64px); }
h2 { font-size: clamp(24px, 3.4vw, 40px); }
h3 { font-size: clamp(18px, 2.2vw, 24px); }

p { max-width: 42em; }

::selection { background: var(--cyan); color: #06122A; }

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

/* ---------- utilities ---------- */
.container {
  width: min(var(--shell-w), calc(100% - var(--gutter) * 2));
  margin-inline: auto;
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
  text-shadow: 0 0 6px rgba(47, 227, 224, 0.35);
}

.glow {
  text-shadow: 0 0 12px rgba(47, 227, 224, 0.45);
}

.skip-link {
  position: fixed;
  top: -80px;
  left: 16px;
  z-index: 200;
  padding: 10px 18px;
  background: var(--cyan);
  color: #06122A;
  font-size: 14px;
  font-weight: 700;
  transition: top 0.16s var(--ease);
}
.skip-link:focus { top: 12px; }

/* ---------- header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 90;
  background-color: transparent;
  border-bottom: 1px solid transparent;
  transition: background-color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.site-header[data-scrolled="true"] {
  background-color: #11162C;
  border-bottom-color: var(--cyan);
}

.status-strip {
  background-color: #080B22;
  border-bottom: 1px solid var(--line);
  font-size: 12px;
  color: var(--fog);
}
.status-strip__inner {
  width: min(var(--shell-w), calc(100% - var(--gutter) * 2));
  margin-inline: auto;
  min-height: 28px;
  padding: 4px 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}
.status-strip__item { line-height: 1.4; }
.status-strip__item--end { margin-left: auto; }
.status-strip__item .mono { color: var(--snow); }

.status-dot {
  flex: none;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: var(--online);
  box-shadow: 0 0 10px rgba(55, 227, 155, 0.65);
}

.header-bar__inner {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 12px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: none;
}
.brand__mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  background-color: var(--cyan);
  color: #06122A;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -0.02em;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 9px), calc(100% - 9px) 100%, 0 100%);
}
.brand__text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}
.brand__name {
  font-size: 16px;
  font-weight: 900;
  letter-spacing: -0.01em;
  color: var(--snow);
}
.brand__sub {
  font-size: 11px;
  color: var(--fog);
  letter-spacing: 0.06em;
}

.nav { display: block; }
.nav__list {
  display: flex;
  align-items: center;
  gap: clamp(6px, 1.6vw, 22px);
}
.nav__link {
  position: relative;
  display: inline-block;
  padding: 8px 2px;
  font-size: 14px;
  font-weight: 500;
  color: var(--fog);
  white-space: nowrap;
  transition: color 0.18s var(--ease);
}
.nav__link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 1px;
  height: 2px;
  background-color: var(--cyan);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.18s var(--ease);
}
.nav__link:hover { color: var(--snow); }
.nav__link:hover::after { transform: scaleX(1); }
.nav__link[aria-current="page"] { color: var(--cyan); }
.nav__link[aria-current="page"]::after { transform: scaleX(1); }

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
  flex: none;
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 1px solid var(--line);
  background-color: var(--mist);
  transition: border-color 0.18s var(--ease);
}
.nav-toggle:hover { border-color: var(--cyan); }
.nav-toggle__bar {
  display: block;
  width: 18px;
  height: 2px;
  background-color: var(--snow);
  transition: transform 0.18s var(--ease), opacity 0.18s var(--ease);
}
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(1) { transform: translateY(7px) 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(-7px) rotate(-45deg); }

.scroll-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  overflow: hidden;
  pointer-events: none;
}
.scroll-progress__bar {
  display: block;
  height: 100%;
  width: 100%;
  transform: scaleX(0);
  transform-origin: 0 50%;
  background-image: linear-gradient(90deg, var(--cyan), var(--violet), var(--amber));
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 20px;
  font-size: 14px;
  font-weight: 500;
  border: 1px solid var(--line);
  color: var(--snow);
  background-color: transparent;
  white-space: nowrap;
  transition: background-color 0.18s var(--ease), color 0.18s var(--ease), border-color 0.18s var(--ease);
}
.btn--primary {
  border: 0;
  padding: 13px 22px;
  background-color: var(--amber);
  color: #1A0E00;
  font-weight: 900;
  letter-spacing: 0.01em;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 12px), calc(100% - 12px) 100%, 0 100%);
}
.btn--primary:hover { background-color: #FFC072; }
.btn--ghost:hover { border-color: var(--cyan); color: var(--cyan); }
.btn--sm { padding: 7px 14px; font-size: 13px; }

/* ---------- sections ---------- */
.section {
  position: relative;
  padding-block: var(--sp);
}
.section > * { position: relative; z-index: 1; }

.section--panel { background-color: var(--panel); }
.section--mist  { background-color: var(--mist); }
.section--teal  { background-color: var(--deep-teal); }
.section--wine  { background-color: var(--wine); }

.section--panel::before,
.section--mist::before,
.section--teal::before,
.section--wine::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.35;
  background-image: repeating-linear-gradient(
    0deg,
    rgba(237, 242, 255, 0.05) 0 1px,
    transparent 1px 4px
  );
}

/* ---------- chapter heading ---------- */
.chapter {
  display: grid;
  grid-template-columns: auto auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 14px;
  align-items: center;
  margin-bottom: clamp(24px, 3vw, 40px);
}
.chapter__num {
  grid-row: 1 / span 2;
  grid-column: 1;
  font-family: var(--font-serif);
  font-size: clamp(34px, 5.2vw, 58px);
  font-weight: 600;
  line-height: 1;
  color: var(--fog);
  transition: color 0.22s var(--ease), text-shadow 0.22s var(--ease);
}
.chapter[data-seen="true"] .chapter__num {
  color: var(--violet);
  text-shadow: 0 0 12px rgba(166, 107, 255, 0.4);
}
.chapter__rule {
  grid-row: 1;
  grid-column: 2;
  width: 48px;
  height: 2px;
  background-color: var(--cyan);
}
.chapter__title {
  grid-row: 1;
  grid-column: 3;
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 900;
}
.chapter__kicker {
  grid-row: 2;
  grid-column: 2 / span 2;
  margin-top: 6px;
  font-size: 13px;
  color: var(--fog);
  letter-spacing: 0.02em;
  max-width: 46em;
}

/* ---------- panel (corner-cut) ---------- */
.panel {
  position: relative;
  background-color: var(--panel);
  border: 1px solid var(--line);
  padding: clamp(18px, 2.4vw, 28px);
}
.panel::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: calc(var(--cut) + 2px);
  height: calc(var(--cut) + 2px);
  pointer-events: none;
  clip-path: polygon(0 0, 100% 0, 0 100%);
  background-image: linear-gradient(
    135deg,
    var(--zone-bg, var(--ink)) 0 49.4%,
    var(--line) 49.4% 51%,
    transparent 51% 100%
  );
  transition: background-image 0.18s var(--ease);
}
.panel:hover::after {
  background-image: linear-gradient(
    135deg,
    var(--zone-bg, var(--ink)) 0 49.4%,
    var(--cyan) 49.4% 51%,
    transparent 51% 100%
  );
}

/* ---------- card ---------- */
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px;
  background-color: var(--panel);
  border: 1px solid var(--line);
  transition: border-color 0.18s var(--ease), background-color 0.18s var(--ease);
}
.card:hover { border-color: var(--cyan); background-color: var(--mist); }
.card__title {
  font-size: 17px;
  font-weight: 900;
  letter-spacing: -0.01em;
  line-height: 1.35;
}
.card__meta {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  color: var(--fog);
  letter-spacing: 0.02em;
}

/* ---------- tags ---------- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  font-size: 12px;
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
  line-height: 1.6;
  border: 1px solid var(--line);
  color: var(--fog);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 7px), calc(100% - 7px) 100%, 0 100%);
}
.tag--cyan   { color: var(--cyan);   border-color: rgba(47, 227, 224, 0.45); }
.tag--amber  { color: var(--amber);  border-color: rgba(255, 162, 58, 0.45); }
.tag--violet { color: var(--violet); border-color: rgba(166, 107, 255, 0.45); }
.tag--online { color: var(--online); border-color: rgba(55, 227, 155, 0.45); }

/* ---------- chips (filters) ---------- */
.chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.chip {
  padding: 7px 14px;
  font-size: 13px;
  line-height: 1.5;
  border: 1px solid var(--line);
  color: var(--fog);
  background-color: transparent;
  transition: color 0.16s var(--ease), border-color 0.16s var(--ease), background-color 0.16s var(--ease);
}
.chip:hover { color: var(--snow); border-color: var(--mist); background-color: var(--mist); }
.chip[aria-pressed="true"] {
  background-color: var(--cyan);
  border-color: var(--cyan);
  color: #06122A;
  font-weight: 700;
}

/* ---------- grid ---------- */
.grid {
  display: grid;
  gap: clamp(14px, 2vw, 22px);
}
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* ---------- media frame ---------- */
.media-frame {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background-color: var(--mist);
  border: 1px solid var(--line);
}
.media-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.media-frame::before,
.media-frame::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  border: 1px solid var(--cyan);
  opacity: 0.7;
  pointer-events: none;
}
.media-frame::before { top: 8px; left: 8px; border-right: 0; border-bottom: 0; }
.media-frame::after { right: 8px; bottom: 8px; border-left: 0; border-top: 0; }
.media-frame--phone { aspect-ratio: 9 / 16; }
.media-frame--wide { aspect-ratio: 21 / 9; }
.media-frame__caption {
  margin-top: 10px;
  font-size: 12px;
  font-family: var(--font-mono);
  color: var(--fog);
  letter-spacing: 0.02em;
}

/* ---------- stat ---------- */
.stat { display: block; }
.stat__value {
  display: block;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: clamp(24px, 3.4vw, 36px);
  font-weight: 700;
  line-height: 1.15;
  color: var(--snow);
  text-shadow: 0 0 12px rgba(47, 227, 224, 0.4);
}
.stat__label {
  display: block;
  margin-top: 6px;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--fog);
}

/* ---------- breadcrumb ---------- */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 16px 0 0;
  font-size: 12px;
  font-family: var(--font-mono);
  color: var(--fog);
  letter-spacing: 0.02em;
}
.breadcrumb li { display: flex; align-items: center; gap: 8px; }
.breadcrumb li + li::before { content: "/"; color: var(--line); }
.breadcrumb a { transition: color 0.16s var(--ease); }
.breadcrumb a:hover { color: var(--cyan); }
.breadcrumb__current { color: var(--snow); }

/* ---------- prose ---------- */
.prose {
  max-width: 42em;
  font-size: 16px;
  line-height: 1.75;
  color: var(--snow);
}
.prose p + p { margin-top: 1em; }
.prose a {
  color: var(--cyan);
  border-bottom: 1px solid rgba(47, 227, 224, 0.4);
  transition: border-color 0.16s var(--ease);
}
.prose a:hover { border-bottom-color: var(--cyan); }
.prose h3 { margin-top: 1.4em; margin-bottom: 0.5em; }

/* ---------- footer ---------- */
.site-footer {
  background-color: #0A0E24;
  border-top: 1px solid var(--line);
}

.footer-feedback {
  background-color: var(--panel);
  border-bottom: 1px solid var(--line);
}
.footer-feedback__bar {
  width: min(var(--shell-w), calc(100% - var(--gutter) * 2));
  margin-inline: auto;
  min-height: 52px;
  padding: 10px 0;
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: left;
  color: var(--snow);
  font-size: 14px;
}
.footer-feedback__text { font-weight: 500; }
.footer-feedback__arrow {
  margin-left: auto;
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--cyan);
  border-bottom: 2px solid var(--cyan);
  transform: rotate(45deg);
  transition: transform 0.18s var(--ease);
}
.footer-feedback__bar[aria-expanded="true"] .footer-feedback__arrow { transform: rotate(-135deg); }

.footer-feedback__panel {
  width: min(var(--shell-w), calc(100% - var(--gutter) * 2));
  margin-inline: auto;
  padding: 4px 0 22px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.footer-feedback__panel[hidden] { display: none; }
.footer-feedback__lead {
  font-size: 13px;
  color: var(--fog);
  max-width: 46em;
}
.footer-feedback__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.footer-feedback__mail { font-size: 13px; color: var(--snow); }

.footer-main { padding-block: clamp(36px, 5vw, 64px); }
.footer-main__inner {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr 1.5fr;
  gap: clamp(20px, 3vw, 36px);
}

.footer-brand { display: flex; flex-direction: column; gap: 14px; }
.footer-brand__note {
  font-size: 13px;
  line-height: 1.7;
  color: var(--fog);
  max-width: 26em;
}

.footer-col__title {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--cyan);
  margin-bottom: 12px;
}
.footer-col__list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 13px;
  color: var(--fog);
}
.footer-col__list a { transition: color 0.16s var(--ease); }
.footer-col__list a:hover { color: var(--snow); }

.footer-contact__item {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  line-height: 1.6;
  word-break: break-all;
}
.footer-contact__k {
  flex: none;
  min-width: 4.5em;
  color: var(--line);
}
.footer-contact__k + * { color: var(--fog); }

.footer-legal {
  border-top: 1px solid var(--line);
  padding-block: 18px;
}
.footer-legal__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
  color: var(--fog);
}
.footer-legal__inner p { max-width: none; }
.footer-legal__note { font-family: var(--font-mono); letter-spacing: 0.02em; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .nav__list { gap: 10px; }
  .nav__link { font-size: 13px; }
  .footer-main__inner { grid-template-columns: 1.5fr 1fr 1fr 1.5fr; }
  .footer-main__inner > .footer-col:nth-of-type(3) { grid-column: 2; }
}

@media (max-width: 900px) {
  :root { --gutter: 14px; }

  .nav-toggle { display: flex; }

  .nav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 120;
    padding: 16px var(--gutter) calc(20px + env(safe-area-inset-bottom, 0px));
    background-color: var(--panel);
    border-top: 1px solid var(--cyan);
    transform: translateY(105%);
    pointer-events: none;
    transition: transform 0.2s var(--ease);
    max-height: 76vh;
    overflow-y: auto;
  }
  .nav[data-open="true"] {
    transform: translateY(0);
    pointer-events: auto;
  }
  .nav__list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }
  .nav__link {
    display: block;
    padding: 14px 12px;
    font-size: 15px;
    color: var(--snow);
    background-color: var(--mist);
    border: 1px solid var(--line);
  }
  .nav__link::after { display: none; }
  .nav__link[aria-current="page"] {
    color: var(--cyan);
    border-color: var(--cyan);
  }

  .grid--3, .grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-main__inner { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-main__inner > .footer-col:nth-of-type(3) { grid-column: auto; }
  .footer-brand { grid-column: 1 / -1; }
  .footer-contact { grid-column: 1 / -1; }
}

@media (max-width: 620px) {
  .status-strip__item--end { margin-left: 0; }
  .brand__sub { display: none; }
  .grid--2, .grid--3, .grid--4 { grid-template-columns: minmax(0, 1fr); }
  .footer-main__inner { grid-template-columns: minmax(0, 1fr); }
  .chapter { grid-template-columns: auto 1fr; }
  .chapter__rule { display: none; }
  .chapter__title { grid-column: 2; }
  .chapter__kicker { grid-column: 2; }
  .footer-legal__inner { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 420px) {
  .header-actions .btn--primary { display: none; }
}

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0ms !important;
  }
}
