@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&family=VT323&display=swap');

:root {
  --ink: #192617;
  --ink-deep: #0d1610;
  --ink-soft: #22331f;
  --green: #87ff71;
  --yellow: #ffce5c;
  --paper: #e8ffe2;
  --dim: #b8d3b1;
  --line: rgba(135, 255, 113, 0.28);
  --line-hard: rgba(135, 255, 113, 0.55);
  --glass: rgba(233, 255, 226, 0.06);
  --pixel: 'Press Start 2P', 'Courier New', monospace;
  --mono: 'VT323', 'Courier New', monospace;
  --cjk: -apple-system, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Noto Sans SC', sans-serif;
  --dock: 118px;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  overflow-x: hidden;
  font-family: var(--mono), var(--cjk);
  font-size: 17px;
  line-height: 1.75;
  color: var(--paper);
  background-color: var(--ink);
  background-image:
    radial-gradient(circle at 12% 8%, rgba(135, 255, 113, 0.12), transparent 42%),
    radial-gradient(circle at 88% 24%, rgba(255, 206, 92, 0.1), transparent 38%),
    radial-gradient(rgba(135, 255, 113, 0.16) 1px, transparent 1px);
  background-size: auto, auto, 22px 22px;
  background-attachment: scroll, scroll, fixed;
}

img { max-width: 100%; height: auto; display: block; }
p { margin: 0 0 1.1em; }
a { color: var(--yellow); text-decoration: none; }
a:hover { color: var(--green); }

h1, h2, h3 {
  font-family: var(--cjk);
  font-weight: 800;
  letter-spacing: 0.02em;
  color: var(--green);
  margin: 0 0 0.6em;
}

h1 { font-size: clamp(1.9rem, 7.4vw, 4rem); line-height: 1.28; }
h2 { font-size: clamp(1.3rem, 3.4vw, 1.9rem); line-height: 1.4; }
h3 { font-size: 1.12rem; line-height: 1.5; color: var(--yellow); }

small {
  display: block;
  font-family: var(--pixel);
  font-size: 0.56rem;
  letter-spacing: 0.16em;
  color: var(--yellow);
  margin-bottom: 0.55rem;
}

/* ---------- 底部固定导航 ---------- */
.dock {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 60;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom, 0px));
  background: rgba(13, 22, 16, 0.92);
  border-top: 3px dashed var(--line-hard);
  backdrop-filter: blur(10px);
}

.dock::before {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: -7px;
  height: 4px;
  background: repeating-linear-gradient(90deg, var(--green) 0 14px, transparent 14px 26px);
  opacity: 0.7;
}

.brand {
  order: 1;
  font-family: var(--pixel);
  font-size: 0.72rem;
  line-height: 1.5;
  color: var(--green);
  padding: 10px 4px;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  text-shadow: 2px 2px 0 rgba(255, 206, 92, 0.35);
}

.dock-nav {
  order: 3;
  flex: 1 0 100%;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}

.dock-nav p {
  display: flex;
  gap: 6px;
  margin: 0;
  white-space: nowrap;
}

.dock-nav a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 42px;
  padding: 6px 12px;
  font-size: 16px;
  line-height: 1.4;
  color: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--glass);
}

.dock-nav a:hover,
.dock-nav a:focus-visible {
  color: var(--ink);
  background: var(--green);
  border-color: var(--green);
}

.idx {
  font-family: var(--pixel);
  font-size: 0.5rem;
  color: var(--yellow);
}

.dock-nav a:hover .idx { color: var(--ink); }

.cta {
  order: 2;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 6px 20px;
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
  background: var(--yellow);
  border-radius: 10px;
  clip-path: polygon(8px 0, 100% 0, calc(100% - 8px) 100%, 0 100%);
}

.cta:hover { color: var(--ink); background: var(--green); }

/* ---------- 主体 ---------- */
.shell {
  display: block;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 18px calc(var(--dock) + 40px);
}

.lead-strip {
  position: relative;
  padding: 54px 0 34px;
  border-bottom: 3px dashed var(--line-hard);
}

.lead-strip h1 { margin-bottom: 0.4em; text-shadow: 4px 4px 0 rgba(135, 255, 113, 0.3); }

.lead-strip::after {
  content: '';
  position: absolute;
  right: 0;
  bottom: -9px;
  width: 120px;
  height: 16px;
  background: var(--yellow);
  clip-path: polygon(0 60%, 100% 0, 100% 40%, 0 100%);
}

.cat-strip { background: linear-gradient(90deg, rgba(135, 255, 113, 0.1), transparent 60%); }

.stamp {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  font-size: 16px;
  color: var(--dim);
  margin-bottom: 0.8em;
}

.stamp .sep {
  width: 24px;
  height: 3px;
  background: var(--yellow);
  clip-path: polygon(0 60%, 100% 0, 100% 40%, 0 100%);
}

/* ---------- 首屏 ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
  align-items: center;
  gap: 28px;
  padding: 56px 0 70px;
  overflow: hidden;
}

.hero-txt { position: relative; z-index: 2; text-align: left; }

.hero-txt h1 {
  color: var(--paper);
  text-shadow: 4px 4px 0 rgba(135, 255, 113, 0.35);
}

.art-hero { min-height: auto; padding-top: 40px; }

.lede {
  max-width: 30em;
  color: var(--dim);
  font-size: 1.02rem;
  line-height: 1.8;
}

.rule {
  display: block;
  width: 88px;
  height: 12px;
  background: var(--yellow);
  clip-path: polygon(0 40%, 100% 0, 100% 60%, 0 100%);
}

.hero-art {
  position: relative;
  margin: 0;
  z-index: 1;
  transform: rotate(-2.4deg);
}

.art-in {
  position: relative;
  border: 3px solid var(--yellow);
  border-radius: 18px;
  overflow: hidden;
  background: var(--ink-soft);
  clip-path: polygon(0 2%, 100% 0, 97% 100%, 3% 97%);
  box-shadow: 10px 12px 0 rgba(135, 255, 113, 0.22);
}

.art-in img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; }

.art-fallback {
  width: 100%;
  aspect-ratio: 3 / 4;
  background:
    repeating-linear-gradient(45deg, rgba(135, 255, 113, 0.18) 0 12px, transparent 12px 24px),
    var(--ink-soft);
}

.slash {
  position: absolute;
  left: -6%;
  right: -6%;
  bottom: 34px;
  height: 18px;
  background: linear-gradient(90deg, var(--green), var(--yellow));
  clip-path: polygon(0 60%, 100% 0, 100% 40%, 0 100%);
  opacity: 0.9;
  pointer-events: none;
}

.blob {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  mix-blend-mode: screen;
  opacity: 0.55;
}

.blob-a {
  width: 170px;
  height: 170px;
  top: 12%;
  right: 4%;
  border: 12px dotted var(--green);
  transform: rotate(12deg);
}

.blob-b {
  width: 90px;
  height: 90px;
  bottom: 16%;
  left: 42%;
  background: var(--yellow);
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
  border-radius: 0;
}

/* ---------- 正文区 ---------- */
.zig {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 34px;
  align-items: start;
  padding-top: 12px;
}

.side-art {
  grid-column: 1 / -1;
  position: relative;
  margin: 0 0 6px;
  border-radius: 18px;
  overflow: hidden;
  border: 2px solid var(--line-hard);
  background: var(--glass);
  backdrop-filter: blur(8px);
}

.side-art img { width: 100%; aspect-ratio: 21 / 7; object-fit: cover; }

.band-fallback {
  width: 100%;
  height: 120px;
  background:
    repeating-linear-gradient(90deg, rgba(255, 206, 92, 0.22) 0 18px, transparent 18px 40px),
    var(--ink-soft);
}

.tri {
  position: absolute;
  right: 14px;
  bottom: 10px;
  width: 0;
  height: 0;
  border-left: 22px solid transparent;
  border-right: 22px solid transparent;
  border-bottom: 34px solid var(--green);
  opacity: 0.85;
  mix-blend-mode: screen;
}

.dot-field {
  position: absolute;
  left: 10px;
  top: 10px;
  width: 46px;
  height: 46px;
  background-image: radial-gradient(var(--yellow) 1.6px, transparent 1.6px);
  background-size: 9px 9px;
  opacity: 0.8;
}

.prose {
  min-width: 0;
  font-size: 17px;
  line-height: 1.85;
  color: var(--paper);
}

.prose > div {
  padding: 30px 0;
  border-top: 2px dashed var(--line);
}

.prose > div:first-child { border-top: 0; padding-top: 6px; }

.prose div[id] { scroll-margin-top: 18px; }

.prose h2 {
  display: inline-block;
  padding: 4px 0 4px 14px;
  border-left: 8px solid var(--yellow);
  color: var(--green);
}

.prose h3 {
  padding-left: 12px;
  border-left: 4px dotted var(--green);
}

.prose a {
  color: var(--yellow);
  border-bottom: 2px dotted var(--yellow);
}

.prose a:hover { color: var(--ink); background: var(--green); border-color: var(--green); }

.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.1em; }
.prose li { margin-bottom: 0.5em; }
.prose li::marker { color: var(--yellow); }

.prose blockquote {
  margin: 1.2em 0;
  padding: 14px 18px;
  background: var(--glass);
  border-left: 6px solid var(--green);
  border-radius: 0 14px 14px 0;
  color: var(--dim);
}

.prose figure { margin: 1.2em 0; }
.prose img, .prose figure img {
  border-radius: 14px;
  border: 2px solid var(--line);
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: 16px;
  margin: 1.2em 0;
  display: block;
  overflow-x: auto;
}

.prose th, .prose td {
  border: 1px dashed var(--line-hard);
  padding: 9px 12px;
  text-align: left;
}

.prose th { background: rgba(135, 255, 113, 0.12); color: var(--green); }

.prose code {
  font-family: var(--mono), monospace;
  background: rgba(255, 206, 92, 0.16);
  padding: 1px 6px;
  border-radius: 6px;
  color: var(--yellow);
}

.prose hr {
  border: 0;
  height: 6px;
  margin: 1.6em 0;
  background: repeating-linear-gradient(90deg, var(--green) 0 10px, transparent 10px 20px);
}

.legal { font-size: 17px; }

/* ---------- 子页列表 ---------- */
.kid-wrap {
  position: relative;
  margin: 1.4em 0 0;
  padding: 16px;
  border: 2px dashed var(--line-hard);
  border-radius: 18px;
  background: var(--glass);
}

.kid-wrap figcaption { margin-bottom: 10px; }

.kid-list { list-style: none; margin: 0; padding: 0; }

.kid { margin-bottom: 10px; }

.kid a {
  display: block;
  padding: 12px 14px;
  min-height: 40px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(13, 22, 16, 0.5);
  color: var(--paper);
}

.kid a:hover { background: rgba(135, 255, 113, 0.16); color: var(--paper); }

.kid-t { display: block; font-weight: 700; color: var(--green); }
.kid-d { display: block; font-size: 16px; color: var(--dim); line-height: 1.6; }
.kid time { display: inline-block; margin-top: 6px; font-size: 16px; color: var(--yellow); }

/* ---------- 右侧栏 ---------- */
.rail {
  position: sticky;
  top: 24px;
  padding: 18px 16px 16px;
  border-radius: 18px;
  border: 1px solid var(--line-hard);
  background: var(--glass);
  backdrop-filter: blur(9px);
  clip-path: polygon(0 0, 100% 10px, 100% 100%, 10px calc(100% - 10px));
}

.rail h2 { font-size: 1.16rem; margin-bottom: 0.8rem; }

.rail-list {
  list-style: none;
  margin: 0 0 14px;
  padding: 0;
}

.rail-list li { margin-bottom: 6px; }

.rail-list a {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 6px 10px;
  font-size: 16px;
  color: var(--paper);
  border: 1px dashed var(--line);
  border-radius: 10px;
}

.rail-list a:hover {
  color: var(--ink);
  background: var(--yellow);
  border-color: var(--yellow);
}

.rail-list a:hover .idx { color: var(--ink); }

.rail-top {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 4px 14px;
  font-size: 16px;
  color: var(--ink);
  background: var(--green);
  border-radius: 10px;
}

/* ---------- 页脚 ---------- */
.foot {
  max-width: 1180px;
  margin: 0 auto;
  padding: 44px 18px calc(var(--dock) + 26px);
  border-top: 3px solid var(--line-hard);
}

.giant {
  margin: 0 0 20px;
  font-family: var(--cjk);
  font-weight: 800;
  font-size: clamp(1.8rem, 11vw, 5rem);
  line-height: 1.1;
  letter-spacing: 0.02em;
  color: transparent;
  -webkit-text-stroke: 2px var(--green);
  text-stroke: 2px var(--green);
}

.foot-cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  padding: 16px 0;
  border-top: 2px dashed var(--line);
}

.foot-cols dl { margin: 0; }

.foot-cols dt {
  font-family: var(--pixel);
  font-size: 0.56rem;
  color: var(--yellow);
  margin-bottom: 8px;
  letter-spacing: 0.1em;
}

.foot-cols dd { margin: 0; }

.foot-cols a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  font-size: 16px;
  color: var(--dim);
}

.foot-cols a:hover { color: var(--green); }

.copy {
  margin: 8px 0 0;
  font-size: 16px;
  color: var(--dim);
  border-top: 2px dashed var(--line);
  padding-top: 12px;
}

/* ---------- 动效 ---------- */
.js .reveal {
  opacity: 0;
  transform: translateY(22px) rotate(-1.2deg);
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.2, 0.8, 0.3, 1);
}

.js .reveal.in {
  opacity: 1;
  transform: none;
}

/* ---------- 断点 ---------- */
@media (max-width: 900px) {
  .zig { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .rail { position: static; }
  .hero { grid-template-columns: minmax(0, 1fr); min-height: auto; padding: 34px 0 44px; gap: 22px; }
  .hero-art { transform: rotate(-1.6deg); }
  .art-in img, .art-fallback { aspect-ratio: 4 / 3; }
  .slash { bottom: 8px; height: 12px; }
  .blob-a { width: 110px; height: 110px; top: 4%; opacity: 0.4; }
  .blob-b { display: none; }
  .foot-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lead-strip { padding: 34px 0 26px; }
}

@media (max-width: 560px) {
  :root { --dock: 128px; }
  .shell { padding-left: 14px; padding-right: 14px; }
  .foot { padding-left: 14px; padding-right: 14px; }
  .brand { font-size: 0.62rem; }
  .dock-nav a { padding: 6px 10px; font-size: 16px; }
  .cta { padding-left: 14px; padding-right: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .art-in { transform: none !important; }
}

button[aria-expanded]{min-width:44px;min-height:44px}
