:root {
  --bg: #0a0a0c;
  --panel: #131318;
  --panel-2: #17171d;
  --line: #26262f;
  --ink: #f4f2ee;
  --dim: #8d8d99;
  --yuck: #b6ff3c;
  --hot: #ff4d6d;
  --gold: #ffd166;
  --mono: ui-monospace, "Cascadia Code", Consolas, "SF Mono", monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans SC",
    "PingFang SC", "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.7 var(--sans);
  overflow-x: hidden;
  background-image:
    radial-gradient(900px 500px at 12% -8%, #1b2410 0%, transparent 62%),
    radial-gradient(700px 420px at 105% 6%, #2a0f18 0%, transparent 58%);
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.014) 0 1px,
    transparent 1px 3px
  );
  mix-blend-mode: overlay;
}

a { color: var(--yuck); text-decoration: none; border-bottom: 1px dashed #b6ff3c55; }
a:hover { color: #fff; border-bottom-color: var(--yuck); }

.wrap { width: min(1080px, calc(100% - 40px)); margin: 0 auto; }

/* ---------------- top bar ---------------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(14px);
  background: #0a0a0ccc;
  border-bottom: 1px solid var(--line);
}
.topbar .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  height: 58px;
}
.brand {
  font: 700 14px/1 var(--mono);
  letter-spacing: 0.02em;
  display: flex;
  align-items: center;
  gap: 9px;
}
.brand i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--yuck);
  box-shadow: 0 0 0 3px #b6ff3c22;
  font-style: normal;
}
.nav { display: flex; gap: 16px; font: 12px/1 var(--mono); color: var(--dim); }
.nav a { color: var(--dim); border: 0; }
.nav a:hover { color: var(--yuck); }

/* ---------------- hero ---------------- */
.hero { padding: 74px 0 40px; position: relative; }

.tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border: 1px solid #b6ff3c44;
  border-radius: 999px;
  color: var(--yuck);
  font: 11px/1 var(--mono);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  background: #b6ff3c0d;
  margin-bottom: 16px;
}

h1.num {
  margin: 0;
  display: block;
  width: fit-content;
  font: 800 clamp(30px, 7.4vw, 82px) / 1 var(--mono);
  letter-spacing: -0.045em;
  position: relative;
}
h1.num::before,
h1.num::after {
  content: attr(data-text);
  position: absolute;
  inset: 0;
  clip-path: inset(0 0 55% 0);
  opacity: 0.75;
}
h1.num::before { color: var(--hot); transform: translate(-2px, -1px); }
h1.num::after { color: var(--yuck); clip-path: inset(52% 0 0 0); transform: translate(2px, 1px); }
h1.num:hover::before { animation: jit 0.18s steps(2) infinite; }
h1.num:hover::after { animation: jit 0.22s steps(2) infinite reverse; }
@keyframes jit {
  0% { transform: translate(-2px, -1px); }
  50% { transform: translate(3px, 1px); }
  100% { transform: translate(-3px, 2px); }
}

.lead {
  margin: 22px 0 0;
  max-width: 62ch;
  color: #cfcdc7;
  font-size: clamp(15px, 1.8vw, 17px);
}
.lead b { color: var(--gold); font-weight: 600; }

.meter { margin: 34px 0 0; }
.meter .row {
  display: flex;
  justify-content: space-between;
  font: 11px/1 var(--mono);
  letter-spacing: 0.1em;
  color: var(--dim);
  text-transform: uppercase;
  margin-bottom: 8px;
}
.bar {
  height: 12px;
  border-radius: 999px;
  background: #1b1b22;
  border: 1px solid var(--line);
  overflow: hidden;
}
.bar > i {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--yuck), var(--gold) 60%, var(--hot));
  animation: fillbar 1.5s cubic-bezier(0.2, 0.8, 0.2, 1) 0.25s forwards;
}
@keyframes fillbar { to { width: 100%; } }
.meter .verdict {
  margin-top: 9px;
  font: 12px/1.6 var(--mono);
  color: var(--hot);
  opacity: 0;
  animation: fadein 0.5s ease 1.5s forwards;
}
@keyframes fadein { to { opacity: 1; } }

/* ---------------- marquee ---------------- */
.marquee {
  margin: 46px 0;
  border-block: 1px solid var(--line);
  background: #101015;
  overflow: hidden;
  padding: 10px 0;
}
.marquee div {
  display: flex;
  gap: 34px;
  width: max-content;
  animation: slide 26s linear infinite;
  font: 700 13px/1 var(--mono);
  color: #4e4e5c;
  letter-spacing: 0.22em;
  white-space: nowrap;
}
.marquee span:nth-child(3n) { color: #b6ff3c99; }
@keyframes slide { to { transform: translateX(-50%); } }

/* ---------------- sections ---------------- */
section { padding: 44px 0; }
.sec-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 22px; }
.sec-head h2 {
  margin: 0;
  font: 700 clamp(20px, 3vw, 27px) / 1.25 var(--sans);
  letter-spacing: -0.01em;
}
.sec-head em {
  font: 11px/1 var(--mono);
  font-style: normal;
  color: var(--yuck);
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.grid { display: grid; gap: 14px; }
.g3 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.g2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }

.card {
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 20px;
  position: relative;
  overflow: hidden;
}
.card h3 { margin: 0 0 8px; font: 700 16px/1.4 var(--sans); }
.card p { margin: 0; color: #b9b7b1; font-size: 14.5px; }
.card .big {
  font: 800 30px/1 var(--mono);
  letter-spacing: -0.03em;
  margin-bottom: 10px;
  display: block;
}
.card.hot .big { color: var(--hot); }
.card.yuck .big { color: var(--yuck); }
.card.gold .big { color: var(--gold); }
.jp { font: 12.5px/1.7 var(--mono); color: var(--dim); display: block; margin-top: 10px; }
.tiny { font-size: 12.5px; color: var(--dim); }

/* timeline */
.tl { display: grid; gap: 0; border-left: 1px solid var(--line); margin-left: 8px; }
.tl li {
  list-style: none;
  padding: 0 0 22px 24px;
  position: relative;
}
.tl li::before {
  content: "";
  position: absolute;
  left: -5px;
  top: 7px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--yuck);
}
.tl time {
  font: 11.5px/1 var(--mono);
  color: var(--yuck);
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 5px;
}
.tl b { display: block; font-weight: 600; margin-bottom: 2px; }
.tl span { color: #a9a7a1; font-size: 14.5px; }

/* machine */
.machine {
  background: #0c0c10;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
}
.machine .bar-top {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  background: #101015;
}
.machine .bar-top i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #2f2f3a;
}
.machine .bar-top i:nth-child(1) { background: #ff5f56; }
.machine .bar-top i:nth-child(2) { background: #ffbd2e; }
.machine .bar-top i:nth-child(3) { background: #27c93f; }
.machine .bar-top span {
  margin-left: auto;
  font: 11px/1 var(--mono);
  color: #55555f;
  letter-spacing: 0.08em;
}
.machine .body { padding: 18px; }

.field { display: flex; gap: 10px; flex-wrap: wrap; }
.field input {
  flex: 1 1 180px;
  min-width: 0;
  background: #08080b;
  border: 1px solid var(--line);
  color: var(--ink);
  border-radius: 9px;
  padding: 12px 14px;
  font: 15px/1 var(--mono);
  outline: none;
}
.field input:focus { border-color: #b6ff3c66; box-shadow: 0 0 0 3px #b6ff3c14; }
.field button,
.btn {
  border: 0;
  border-radius: 9px;
  padding: 12px 18px;
  font: 600 14px/1 var(--sans);
  background: var(--yuck);
  color: #10130a;
  cursor: pointer;
  transition: transform 0.12s, filter 0.12s;
}
.field button:hover, .btn:hover { filter: brightness(1.08); transform: translateY(-1px); }
.field button:active, .btn:active { transform: translateY(1px); }
.btn.ghost {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink);
}

.out {
  margin-top: 16px;
  font: 14px/1.9 var(--mono);
  color: #d9d7d1;
  min-height: 92px;
  white-space: pre-wrap;
  word-break: break-word;
}
.out .k { color: var(--dim); }
.out .eq { color: var(--yuck); font-weight: 700; }
.out .bad { color: var(--gold); }
.out .qed { color: var(--hot); }

/* danmaku */
.danmaku {
  position: relative;
  height: 230px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #08080b;
  overflow: hidden;
  margin-bottom: 14px;
}
.danmaku b {
  position: absolute;
  left: 100%;
  white-space: nowrap;
  font: 600 15px/1 var(--mono);
  text-shadow: 0 0 10px currentColor;
  animation: fly linear forwards;
  will-change: transform;
}
@keyframes fly {
  from { transform: translateX(0); }
  to { transform: translateX(calc(-100vw - 100%)); }
}

/* rules */
.rules { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.rules li {
  display: flex;
  gap: 13px;
  align-items: flex-start;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  font-size: 14.5px;
  color: #c3c1bb;
}
.rules li strong { color: var(--ink); font-weight: 600; }
.rules .ico { font-size: 17px; line-height: 1.35; flex: 0 0 auto; }

/* misc */
.counter {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 6px;
}
.counter .n {
  font: 800 26px/1 var(--mono);
  color: var(--yuck);
  min-width: 3ch;
}

.quote {
  margin-top: 14px;
  border-left: 3px solid var(--gold);
  padding: 6px 0 6px 14px;
  color: #d9d7d1;
}
.quote b { font: 700 17px/1.5 var(--sans); display: block; }
.quote span { font-size: 13px; color: var(--dim); }

footer {
  margin-top: 40px;
  padding: 30px 0 60px;
  border-top: 1px solid var(--line);
  color: var(--dim);
  font-size: 13px;
}
footer .cols {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  margin-bottom: 20px;
}
footer h4 {
  margin: 0 0 8px;
  font: 11px/1 var(--mono);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--yuck);
}
footer ul { margin: 0; padding-left: 16px; }
footer li { margin-bottom: 5px; }
footer .fine { font-size: 11.5px; color: #55555f; line-height: 1.8; }

.float {
  position: fixed;
  z-index: 30;
  pointer-events: none;
  font: 800 20px/1 var(--mono);
  color: var(--yuck);
  animation: up 1.1s ease-out forwards;
}
@keyframes up {
  to { transform: translateY(-90px) rotate(9deg); opacity: 0; }
}

/* ---------------- 恶臭广播 ---------------- */
.broadcast {
  margin: 26px 0 0;
  border: 1px solid #ff4d6d4d;
  border-radius: 14px;
  background: linear-gradient(180deg, #1b0d13, #110a0d 72%);
  position: relative;
  overflow: hidden;
  cursor: pointer;
  user-select: none;
  transition: border-color 0.2s, transform 0.2s;
}
.broadcast:hover { border-color: #ff4d6d99; }
.broadcast::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 7px;
  background: repeating-linear-gradient(135deg, var(--hot) 0 6px, transparent 6px 12px);
  opacity: 0.9;
}
.broadcast::after {
  content: "";
  position: absolute;
  right: -40px;
  top: -40px;
  width: 160px;
  height: 160px;
  background: radial-gradient(circle, #ff4d6d22 0%, transparent 70%);
  pointer-events: none;
}
.bc-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 18px 0 22px;
  font: 11px/1 var(--mono);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #ff8fa3;
}
.bc-rec { display: inline-flex; align-items: center; gap: 7px; color: var(--hot); }
.bc-rec i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--hot);
  box-shadow: 0 0 0 3px #ff4d6d22;
  animation: blink 1.4s steps(2) infinite;
}
@keyframes blink { 50% { opacity: 0.15; } }
.bc-cat {
  margin-left: auto;
  padding: 3px 9px;
  border: 1px solid #ff4d6d44;
  border-radius: 999px;
  color: #ff9fb0;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: none;
}
.bc-body { padding: 14px 22px 4px; }
.bc-line {
  margin: 0;
  font: 700 clamp(19px, 2.5vw, 26px) / 1.45 var(--sans);
  color: #ffe9ee;
  text-shadow: 0 0 26px #ff4d6d3d;
  min-height: 2.2em;
}
.bc-line::after {
  content: "▌";
  color: var(--hot);
  margin-left: 3px;
  animation: blink 0.9s steps(2) infinite;
}
.bc-foot { display: flex; align-items: flex-end; gap: 14px; padding: 6px 22px 16px; }
.bc-level {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 22px;
  flex: 1;
  max-width: 240px;
  opacity: 0.9;
}
.bc-level i {
  flex: 1;
  height: 55%;
  border-radius: 2px 2px 0 0;
  background: linear-gradient(180deg, #ff6b85, #6d1f2c);
  animation: eq 1.15s ease-in-out infinite alternate;
}
.bc-level i:nth-child(2n) { animation-duration: 0.85s; animation-delay: -0.2s; }
.bc-level i:nth-child(3n) { animation-duration: 1.35s; height: 34%; }
.bc-level i:nth-child(4n) { animation-duration: 0.95s; height: 74%; }
.bc-level i:nth-child(5n) { animation-duration: 1.5s; height: 22%; }
.bc-level i:nth-child(7n) { animation-duration: 0.7s; }
@keyframes eq {
  from { height: 12%; }
  to { height: 96%; }
}
.bc-hint { margin-left: auto; font: 11px/1 var(--mono); color: #8a6270; }
.bc-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: #ff4d6d1f;
}
.bc-progress i {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--hot), var(--yuck));
}
.bc-progress i.run { animation: bcprog linear infinite; }
@keyframes bcprog {
  from { width: 0; }
  to { width: 100%; }
}

/* ---------------- 语音库 ---------------- */
.voice-grid { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.voice-btn {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: left;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  color: var(--ink);
  font: 600 14px/1.45 var(--sans);
  cursor: pointer;
  transition: border-color 0.15s, transform 0.12s, box-shadow 0.15s;
}
.voice-btn:hover { border-color: #ff4d6d66; transform: translateY(-1px); }
.voice-btn.playing { border-color: var(--hot); box-shadow: 0 0 0 3px #ff4d6d1f; }
.voice-btn .ico {
  font: 11px/1 var(--mono);
  letter-spacing: 0.1em;
  color: var(--hot);
}
.voice-btn small { font: 400 12px/1.5 var(--sans); color: var(--dim); }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  /* 动画被关掉时，直接给出最终状态，别让条形图和结论消失 */
  .bar > i { width: 100% !important; }
  .meter .verdict { opacity: 1 !important; }
  .danmaku b { left: 0; }
}
