/* 《第一案》深色悬疑基调 · 移动优先 */
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
:root {
  --bg: #0d0f14;
  --panel: #161a22;
  --panel2: #1e2430;
  --text: #d8dbe2;
  --dim: #8a90a0;
  --accent: #d4a24e;
  --accent-dim: #8a6a30;
  --danger: #c0554d;
  --ok: #5e9e6f;
}
html, body { height: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.75;
  padding-bottom: 44px; /* footer */
}
.hidden { display: none !important; }
.screen { min-height: calc(100vh - 44px); }

/* 通用面板 */
.panel {
  max-width: 640px;
  margin: 0 auto;
  padding: 28px 20px 40px;
}
h1 { font-size: 2rem; letter-spacing: .06em; }
h2 { font-size: 1.4rem; margin-bottom: 18px; color: var(--accent); letter-spacing: .08em; }
h3 { font-size: 1.05rem; margin: 22px 0 10px; color: var(--accent); }
.label {
  display: inline-block; color: var(--accent-dim); font-size: .82rem;
  margin-right: 10px; letter-spacing: .1em; flex-shrink: 0;
}
.btn {
  display: inline-block; border: none; cursor: pointer;
  font-size: 1rem; padding: 12px 28px; border-radius: 6px;
  margin: 18px 8px 0 0; letter-spacing: .15em; min-height: 44px;
}
.btn-primary { background: var(--accent); color: #14100a; font-weight: 600; }
.btn-primary:disabled { background: #3a3f4b; color: #6a7080; cursor: not-allowed; }
.btn-ghost { background: transparent; color: var(--dim); border: 1px solid #333a48; }

/* 封面 */
#screen-cover { display: flex; align-items: center; justify-content: center; text-align: center;
  background: radial-gradient(ellipse at 50% 30%, #1a2030 0%, var(--bg) 70%); }
.cover-inner { padding: 20px; }
.cover-kicker { color: var(--accent-dim); letter-spacing: .3em; font-size: .85rem; margin-bottom: 14px; }
.cover-sub { color: var(--dim); margin-top: 14px; font-size: .95rem; }
#screen-cover .btn { margin-top: 36px; }

/* 简报 */
.brief-meta div { display: flex; margin-bottom: 6px; }
.brief-summary { white-space: pre-line; margin-top: 14px; }
.timeline { list-style: none; }
.timeline li { display: flex; gap: 12px; padding: 7px 0; border-bottom: 1px dashed #262c38; }
.timeline .t { color: var(--accent); font-variant-numeric: tabular-nums; flex-shrink: 0; width: 88px; }
.characters { list-style: none; }
.characters li { padding: 7px 0; border-bottom: 1px dashed #262c38; }
.characters .role { color: var(--accent-dim); font-size: .85rem; margin-left: 8px; }
.characters .note { color: var(--dim); font-size: .88rem; display: block; }

/* 全景现场 */
#screen-scene { position: relative; height: calc(100vh - 44px); }
#panorama { width: 100%; height: 100%; background: #000; }
#scene-loading {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: var(--bg); color: var(--accent); letter-spacing: .2em; z-index: 5;
}
.scene-hud {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 6;
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
  background: linear-gradient(transparent, rgba(6,8,12,.92) 40%);
}
#hud-progress { color: var(--accent); font-size: .9rem; letter-spacing: .05em; }
.btn-hud { margin: 0 0 0 10px; padding: 10px 18px; background: rgba(30,36,48,.9);
  color: var(--text); border: 1px solid #39404f; }
.btn-accuse:not(:disabled) { background: var(--accent); color: #14100a; font-weight: 600; border-color: var(--accent); }
.btn-accuse:disabled { color: #6a7080; }
#debug-coords {
  position: absolute; top: 10px; left: 10px; z-index: 9; background: rgba(0,0,0,.75);
  color: #7CFC00; font-family: monospace; font-size: 12px; padding: 6px 10px; border-radius: 4px;
}

/* 热区 */
.hotspot-dot {
  width: 26px; height: 26px; border-radius: 50%;
  background: rgba(212,162,78,.28); border: 2px solid var(--accent);
  animation: pulse 1.8s infinite; cursor: pointer;
  /* 扩大点击区 ≥44px */
  box-shadow: 0 0 0 10px rgba(0,0,0,0.01);
}
.hotspot-dot.collected { background: rgba(94,158,111,.4); border-color: var(--ok); animation: none; }
.hotspot-dot.collected::after {
  content: "✓"; color: var(--ok); display: block; text-align: center; line-height: 22px; font-size: 14px;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(212,162,78,.5); }
  70% { box-shadow: 0 0 0 16px rgba(212,162,78,0); }
  100% { box-shadow: 0 0 0 0 rgba(212,162,78,0); }
}

/* 物证弹窗 */
.modal { position: fixed; inset: 0; z-index: 20; background: rgba(4,6,10,.86);
  display: flex; align-items: center; justify-content: center; padding: 18px; }
.modal-box {
  background: var(--panel); border: 1px solid #2a3140; border-radius: 10px;
  max-width: 460px; width: 100%; max-height: 86vh; overflow-y: auto;
  padding: 20px; position: relative;
}
.modal-close { position: absolute; top: 8px; right: 12px; background: none; border: none;
  color: var(--dim); font-size: 26px; cursor: pointer; min-width: 44px; min-height: 44px; }
#ev-thumb { width: 100%; border-radius: 6px; margin-bottom: 12px; background: #0a0c10; }
#modal-evidence p { margin-top: 10px; white-space: pre-line; }
.forensic-card { background: var(--panel2); border-left: 3px solid var(--accent);
  padding: 12px 14px; border-radius: 6px; margin-top: 12px; }
.forensic-card p { display: flex; margin: 6px 0; }
.points-to span:last-child { color: var(--accent); }

/* 物证袋 */
.bag-progress { color: var(--dim); font-size: .9rem; margin-left: 10px; }
.bag-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; margin-top: 10px; }
.bag-item {
  background: var(--panel2); border: 1px solid #2a3140; border-radius: 8px;
  padding: 10px; cursor: pointer; text-align: center;
}
.bag-item img { width: 100%; border-radius: 4px; background: #0a0c10; aspect-ratio: 1; object-fit: cover; }
.bag-item .nm { font-size: .85rem; margin-top: 6px; display: block; }
.bag-item .key-tag { font-size: .7rem; color: var(--accent); }
.bag-item.selected { border-color: var(--accent); box-shadow: 0 0 0 2px rgba(212,162,78,.35); }
.bag-empty { color: var(--dim); }

/* 指认 */
.hint { color: var(--dim); margin: 10px 0; }
.suspect-cards { display: grid; gap: 12px; }
.suspect-card {
  display: flex; gap: 14px; background: var(--panel2); border: 1px solid #2a3140;
  border-radius: 8px; padding: 12px; cursor: pointer;
}
.suspect-card img { width: 84px; height: 84px; border-radius: 6px; object-fit: cover; background: #0a0c10; flex-shrink: 0; }
.suspect-card.selected { border-color: var(--accent); box-shadow: 0 0 0 2px rgba(212,162,78,.35); }
.suspect-card .nm { color: var(--accent); font-weight: 600; }
.suspect-card p { font-size: .86rem; color: var(--dim); margin-top: 4px; }
.confirm-text { color: var(--danger); margin-top: 18px; font-weight: 600; }

/* 判定 */
#verdict-title.ok { color: var(--ok); }
#verdict-title.lucky { color: var(--accent); }
#verdict-title.fail { color: var(--danger); }
.reason-item {
  display: flex; gap: 12px; background: var(--panel2); border-radius: 8px;
  padding: 10px 12px; margin-bottom: 10px; align-items: flex-start;
}
.reason-item img { width: 56px; height: 56px; border-radius: 4px; object-fit: cover; background: #0a0c10; flex-shrink: 0; }
.reason-item p { font-size: .92rem; }

/* 案后档案 */
.epilogue-kicker { color: var(--accent-dim); letter-spacing: .1em; font-size: .88rem; }
.next-case { background: var(--panel2); border-radius: 8px; padding: 14px 16px; margin-top: 22px; }
.next-case p { color: var(--dim); }

/* 页脚声明（每屏常驻） */
#site-footer {
  position: fixed; left: 0; right: 0; bottom: 0; height: 44px; z-index: 30;
  display: flex; align-items: center; justify-content: center;
  background: #0a0c10; color: #5a6070; font-size: .68rem; letter-spacing: .04em;
  padding: 0 10px; text-align: center; border-top: 1px solid #1a1f2a;
}

/* 校验横幅 */
#validator-banner {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  background: var(--danger); color: #fff; padding: 8px 14px; font-size: .85rem;
}

@media (min-width: 700px) {
  h1 { font-size: 2.6rem; }
  .suspect-cards { grid-template-columns: 1fr; max-width: 560px; }
}
