/* UNDISMISS 官网
 * 布局刻意区别于参考站的「居中单列 hero + 堆叠 section」：
 * 开场用三栏卷宗版式（时间戳竖排 / 正文 / 通知卡），
 * 六章走横向链条，嫌疑板走网格，实机图走横向滑轨。
 * 配色沿用游戏本体：近黑底 + 单一琥珀强调色。
 */

:root {
  --bg: #0b0b0e;
  --ink: #ececed;
  --dim: #8b8b94;
  --faint: #5c5c65;
  --line: rgba(255, 255, 255, 0.1);
  --line-2: rgba(255, 255, 255, 0.055);
  --panel: #131318;
  --panel-2: #17171d;
  --amber: #ffc75a;
  --amber-dim: rgba(255, 199, 90, 0.3);
  --red: #ff6b6b;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei",
    system-ui, sans-serif;
  --pad: clamp(18px, 5vw, 64px);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

a { color: inherit; }

/* 极轻噪点：给近黑底一点质感，不然大面积纯色发闷 */
.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.035;
  background-image: radial-gradient(rgba(255, 255, 255, 0.9) 0.5px, transparent 0.5px);
  background-size: 3px 3px;
}

/* ---------------- 顶栏 ---------------- */

.bar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px var(--pad);
  background: rgba(11, 11, 14, 0.86);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line-2);
}

.mark {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  margin-right: auto;
}

.mark-dot {
  width: 22px;
  height: 12px;
  border-radius: 4px;
  background: var(--amber);
  flex: none;
}

.mark-text {
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1.4px;
  line-height: 1.15;
}

.mark-text em {
  display: block;
  font-style: normal;
  font-size: 10px;
  letter-spacing: 1.8px;
  color: var(--faint);
  font-weight: 500;
}

.bar-nav {
  display: flex;
  gap: 22px;
  font-size: 13px;
}

.bar-nav a {
  text-decoration: none;
  color: var(--dim);
  padding: 4px 0;
  border-bottom: 1px solid transparent;
  transition: color 0.16s ease, border-color 0.16s ease;
}

.bar-nav a:hover { color: var(--ink); border-bottom-color: var(--amber); }

.bar-toggle {
  display: none;
  width: 40px;
  height: 34px;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  padding: 0 8px;
  background: none;
  border: 1px solid var(--line);
  border-radius: 9px;
  cursor: pointer;
}

.bar-toggle span { display: block; height: 1.5px; background: var(--ink); }

/* ---------------- 开场：三栏卷宗 ---------------- */

.open {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) minmax(0, 312px);
  gap: clamp(20px, 4vw, 56px);
  align-items: center; /* 机身比文案高，居中对齐比顶对齐平衡 */
  padding: clamp(46px, 8vw, 92px) var(--pad) clamp(62px, 8vw, 104px);
  border-bottom: 1px solid var(--line-2);
}

.open-stamp {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding-top: 8px;
}

.open-time {
  font-family: var(--mono);
  font-size: clamp(26px, 3vw, 34px);
  font-weight: 700;
  color: var(--amber);
  letter-spacing: -1px;
}

.open-line { flex: 1; width: 1px; min-height: 90px; background: linear-gradient(var(--amber-dim), transparent); }

.open-tag {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 2.4px;
  color: var(--faint);
  writing-mode: vertical-rl;
  white-space: nowrap;
}

.open-body h1 {
  margin: 0 0 20px;
  font-size: clamp(32px, 5.6vw, 62px);
  line-height: 1.08;
  letter-spacing: -1.2px;
  font-weight: 700;
}

.open-lede { margin: 0 0 26px; color: var(--dim); font-size: clamp(15px, 1.6vw, 18px); max-width: 46ch; }

.open-facts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 0 0 22px;
  max-width: 520px;
}

/* 四格等高：标签行数不一（Actually lying 会折成两行），
   用 grid 把数值统一压到底部，否则四个格子高矮不齐。 */
.open-facts div {
  display: grid;
  grid-template-rows: auto 1fr;
  min-height: 78px;
  padding: 11px 11px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
}

.open-facts dt {
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 1.2px;
  line-height: 1.35;
  color: var(--faint);
  text-transform: uppercase;
}

.open-facts dd {
  margin: 0;
  align-self: end;
  font-size: 24px;
  font-weight: 700;
  color: var(--amber);
  font-family: var(--mono);
  line-height: 1;
}

.open-note { margin: 0; font-size: 13px; color: var(--faint); max-width: 52ch; }

/* 右栏放真实截图而不是手绘假卡：既是实机画面，也刚好把这一栏填满。
   外壳只做一个克制的机身轮廓，不画花哨的边框装饰。 */
.open-card {
  margin: 0;
  display: grid;
  gap: 18px;
  justify-items: center;
}

.phone {
  position: relative;
  width: min(272px, 100%);
  padding: 9px;
  border-radius: 34px;
  background: linear-gradient(160deg, #26262e, #131317 42%, #0e0e12);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow:
    0 34px 80px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

/* 顶部听筒条：一笔带过，够暗示是台手机就行 */
.phone-notch {
  position: absolute;
  top: 17px;
  left: 50%;
  transform: translateX(-50%);
  width: 58px;
  height: 4px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.13);
  z-index: 2;
}

.phone img {
  width: 100%;
  border-radius: 26px;
  display: block;
}

/* 机身底下垫一层琥珀辉光，把右栏那片死黑压住 */
.phone::after {
  content: "";
  position: absolute;
  left: 12%;
  right: 12%;
  bottom: -34px;
  height: 60px;
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(255, 199, 90, 0.16), transparent 70%);
  filter: blur(10px);
  pointer-events: none;
}

.open-card figcaption {
  max-width: 300px;
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--faint);
  text-align: left;
}

.open-card figcaption b {
  display: block;
  color: var(--dim);
  font-size: 13px;
  margin-bottom: 3px;
}

/* ---------------- 通用小节头 ---------------- */

section { position: relative; z-index: 1; }

.sec-head { padding: clamp(44px, 7vw, 86px) var(--pad) 0; max-width: 780px; }

.sec-no {
  display: inline-block;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 2.6px;
  color: var(--amber);
  border: 1px solid var(--amber-dim);
  border-radius: 99px;
  padding: 3px 11px;
  margin-bottom: 14px;
}

.sec-head h2 {
  margin: 0 0 12px;
  font-size: clamp(24px, 3.4vw, 38px);
  line-height: 1.18;
  letter-spacing: -0.6px;
}

.sec-head p { margin: 0; color: var(--dim); font-size: clamp(14px, 1.4vw, 16px); }

/* ---------------- 六章横向链条 ---------------- */

.chain {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(248px, 1fr);
  gap: 0;
  list-style: none;
  margin: clamp(28px, 4vw, 48px) 0 0;
  padding: 0 var(--pad) clamp(44px, 6vw, 76px);
  overflow-x: auto;
  scrollbar-width: none;
}

.chain::-webkit-scrollbar { display: none; }

.chain li {
  position: relative;
  padding: 30px 24px 26px 0;
  border-top: 1px solid var(--line);
}

.chain li::before {
  content: "";
  position: absolute;
  top: -4px;
  left: 0;
  width: 7px;
  height: 7px;
  border-radius: 99px;
  background: var(--faint);
}

.chain li:first-child::before,
.chain .chain-last::before { background: var(--amber); }

.chain .chain-last { border-top-color: var(--amber-dim); }

.chain-no {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1.6px;
  color: var(--faint);
}

.chain h3 { margin: 8px 0 8px; font-size: 20px; letter-spacing: -0.3px; }
.chain-q { margin: 0 0 12px; font-size: 13.5px; color: var(--dim); max-width: 30ch; }
.chain-apps { margin: 0; font-family: var(--mono); font-size: 11.5px; letter-spacing: 0.6px; color: var(--faint); }

/* ---------------- 手势表 ---------------- */

.gestures { border-top: 1px solid var(--line-2); }

.hands {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(248px, 1fr));
  gap: 1px;
  margin: clamp(26px, 4vw, 44px) var(--pad) 0;
  background: var(--line-2);
  border: 1px solid var(--line-2);
  border-radius: 16px;
  overflow: hidden;
}

.hands article { padding: 22px 20px; background: var(--panel); }

.hand-do {
  display: inline-block;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--amber);
  padding: 3px 9px;
  border: 1px solid var(--amber-dim);
  border-radius: 6px;
  margin-bottom: 12px;
}

.hands h3 { margin: 0 0 6px; font-size: 17px; }
.hands p { margin: 0; font-size: 13.5px; color: var(--dim); }

.hands-foot {
  margin: 18px var(--pad) 0;
  padding-bottom: clamp(44px, 6vw, 76px);
  font-size: 13.5px;
  color: var(--faint);
  max-width: 74ch;
}

/* ---------------- 嫌疑板 ---------------- */

.suspects { border-top: 1px solid var(--line-2); }

.board {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  margin: clamp(26px, 4vw, 44px) var(--pad) 0;
  padding-bottom: clamp(44px, 6vw, 76px);
}

.board figure {
  margin: 0;
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel);
}

.board img { width: 46px; height: 46px; border-radius: 12px; }
.board figcaption { min-width: 0; }
.board b { display: block; font-size: 14px; }
.board span { display: block; font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.5px; color: var(--faint); margin-top: 2px; }

/* ---------------- 实机图滑轨 ---------------- */

.shots { border-top: 1px solid var(--line-2); }

.rail {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: min(280px, 74vw);
  gap: 18px;
  margin-top: clamp(26px, 4vw, 44px);
  padding: 0 var(--pad) clamp(44px, 6vw, 76px);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.rail::-webkit-scrollbar { display: none; }

.rail figure { margin: 0; scroll-snap-align: start; }

.rail img {
  width: 100%;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: #000;
}

.rail figcaption {
  margin-top: 12px;
  font-size: 12.5px;
  color: var(--faint);
  line-height: 1.5;
}

/* ---------------- FAQ ---------------- */

.asks { border-top: 1px solid var(--line-2); }

.ask-list {
  margin: clamp(24px, 4vw, 40px) var(--pad) 0;
  padding-bottom: clamp(44px, 6vw, 76px);
  max-width: 860px;
}

.ask-list details {
  border-bottom: 1px solid var(--line-2);
  padding: 4px 0;
}

.ask-list summary {
  cursor: pointer;
  list-style: none;
  padding: 16px 34px 16px 0;
  font-size: 15.5px;
  font-weight: 600;
  position: relative;
}

.ask-list summary::-webkit-details-marker { display: none; }

.ask-list summary::after {
  content: "+";
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--amber);
  font-family: var(--mono);
  font-size: 17px;
}

.ask-list details[open] summary::after { content: "–"; }
.ask-list p { margin: 0 0 18px; color: var(--dim); font-size: 14px; max-width: 70ch; }

/* ---------------- 收尾 ---------------- */

.tail {
  border-top: 1px solid var(--line-2);
  padding: clamp(56px, 9vw, 110px) var(--pad);
  text-align: center;
}

.tail-time {
  margin: 0 0 10px;
  font-family: var(--mono);
  font-size: clamp(44px, 9vw, 96px);
  font-weight: 700;
  color: var(--amber);
  letter-spacing: -3px;
  line-height: 1;
}

.tail h2 { margin: 0 0 14px; font-size: clamp(22px, 3vw, 34px); letter-spacing: -0.5px; }
.tail-note { margin: 0 auto; max-width: 52ch; color: var(--dim); font-size: 14.5px; }

/* ---------------- 页脚 ---------------- */

.foot { border-top: 1px solid var(--line-2); padding: 30px var(--pad) 40px; }

.foot-in {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 28px;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line-2);
}

.foot-brand { margin: 0; font-family: var(--mono); font-size: 13px; font-weight: 700; letter-spacing: 1.4px; }
.foot-brand span { display: block; font-size: 10px; letter-spacing: 1.8px; color: var(--faint); font-weight: 500; }

.foot-nav { display: flex; flex-wrap: wrap; gap: 20px; font-size: 13px; }
.foot-nav a { color: var(--dim); text-decoration: none; }
.foot-nav a:hover { color: var(--amber); }

/* 联系方式：独立开发者的邮箱，比正文亮一档，方便审核和玩家找到 */
.foot-contact {
  margin: 16px 0 0;
  font-size: 12.5px;
  color: var(--dim);
}

.foot-contact a {
  color: var(--amber);
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 199, 90, 0.32);
}

.foot-contact a:hover { border-bottom-color: var(--amber); }

.foot-fine { margin: 16px 0 0; font-size: 11.5px; color: var(--faint); max-width: 78ch; line-height: 1.7; }

/* ---------------- 自适应 ---------------- */

@media (max-width: 1040px) {
  .open { grid-template-columns: 72px minmax(0, 1fr); align-items: start; }

  /* 窄屏改成机身与说明左右并排，避免机身独占一行拉出大片空白 */
  .open-card {
    grid-column: 2 / -1;
    grid-template-columns: 208px minmax(0, 1fr);
    align-items: center;
    justify-items: start;
    gap: 22px;
    margin-top: 8px;
  }

  .phone { width: 208px; }
  .open-card figcaption { max-width: none; }
}

@media (max-width: 760px) {
  .bar-toggle { display: flex; }

  .bar-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    padding: 6px var(--pad) 14px;
    background: rgba(11, 11, 14, 0.97);
    border-bottom: 1px solid var(--line);
    display: none;
  }

  .bar-nav.open { display: flex; }
  .bar-nav a { padding: 12px 0; border-bottom: 1px solid var(--line-2); }

  .open { grid-template-columns: 1fr; padding-top: 34px; }

  .open-stamp {
    flex-direction: row;
    align-items: center;
    gap: 12px;
    padding-top: 0;
  }

  .open-line { width: auto; min-height: 0; height: 1px; flex: 1; background: linear-gradient(90deg, var(--amber-dim), transparent); }
  .open-tag { writing-mode: horizontal-tb; }
  .open-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .open-card {
    grid-column: 1 / -1;
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 26px;
    margin-top: 18px;
  }

  .phone { width: min(232px, 68vw); }
  .open-card figcaption { text-align: center; max-width: 42ch; }
  .chain { grid-auto-columns: min(268px, 78vw); }
}
