/* diy.wanwan.ink — 共用设计系统
   纸质编辑风格：近黑底、暖白字、朱红点缀、细线分隔 */

:root {
  --ink: #0a0b0c;
  --ink-2: #101113;
  --ink-3: #16181b;
  --line: rgba(255, 255, 255, 0.09);
  --line-strong: rgba(255, 255, 255, 0.18);
  --text: #ecebe7;
  --muted: #8b8e93;
  --muted-2: #61656b;
  --acc: #e5452f;
  --ok: #3ed598;
  --sans: "MiSans", -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Noto Sans SC", sans-serif;
  --mono: "SF Mono", "JetBrains Mono", ui-monospace, Menlo, Consolas, "Courier New", monospace;
  --ease: cubic-bezier(0.76, 0, 0.24, 1);
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--ink);
  color: var(--text);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body { min-height: 100vh; }

a { color: inherit; text-decoration: none; }

button, input, textarea, select { font: inherit; color: inherit; }

::selection { background: var(--acc); color: #fff; }

/* 细密点阵纹理，避免大面积纯黑的廉价感 */
.grain::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: radial-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 3px 3px;
  opacity: 0.6;
  z-index: 1;
}

.label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}

.hairline { height: 1px; background: var(--line); border: 0; margin: 0; }

/* ———————————————————— 入口页 */

.gate {
  position: relative;
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  padding: 28px 36px;
  z-index: 2;
}

.gate-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-size: 13px;
  letter-spacing: 0.24em;
  font-weight: 600;
  text-transform: uppercase;
}

.brand i {
  width: 6px;
  height: 6px;
  background: var(--acc);
  display: block;
  transform: rotate(45deg) translateY(-1px);
}

.brand span { color: var(--muted); font-weight: 400; letter-spacing: 0.12em; font-size: 11px; }

.gate-center {
  display: grid;
  place-items: center;
  padding: 40px 0;
}

.card {
  width: 100%;
  max-width: 428px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.022), rgba(255, 255, 255, 0));
  background-color: var(--ink-2);
  padding: 38px 34px 30px;
  position: relative;
  box-shadow: 0 40px 120px -60px rgba(0, 0, 0, 0.9);
}

.card::after {
  content: "";
  position: absolute;
  top: -1px;
  left: 34px;
  width: 44px;
  height: 2px;
  background: var(--acc);
}

.card h1 {
  margin: 18px 0 6px;
  font-size: 27px;
  line-height: 1.25;
  letter-spacing: -0.02em;
  font-weight: 600;
}

.card .desc {
  margin: 0 0 28px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.field { position: relative; }

.field input {
  width: 100%;
  height: 58px;
  background: #0d0e10;
  border: 1px solid var(--line);
  border-radius: 0;
  padding: 0 16px;
  font-family: var(--mono);
  font-size: 22px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s, background 0.2s;
}

.field input::placeholder { color: var(--muted-2); letter-spacing: 0.18em; font-size: 15px; }

.field input:focus { border-color: var(--line-strong); background: #111214; }

.field .count {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--muted-2);
  pointer-events: none;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 52px;
  width: 100%;
  margin-top: 26px;
  border: 1px solid var(--acc);
  background: var(--acc);
  color: #fff;
  font-size: 14px;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: transform 0.18s var(--ease), background 0.2s, opacity 0.2s;
}

.btn:hover { background: #f04d36; }
.btn:active { transform: scale(0.985); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }

.btn.ghost {
  background: transparent;
  border-color: var(--line-strong);
  color: var(--text);
}

.btn.ghost:hover { background: rgba(255, 255, 255, 0.04); border-color: var(--muted); }

.err {
  margin-top: 14px;
  font-size: 12px;
  color: #ff7a63;
  min-height: 16px;
  letter-spacing: 0.02em;
}

.note {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 11px;
  color: var(--muted-2);
  line-height: 1.8;
  letter-spacing: 0.02em;
}

/* 验证面板 */

.captcha {
  margin-top: 4px;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.45s var(--ease), opacity 0.3s, margin-top 0.3s;
}

.captcha.on { max-height: 320px; opacity: 1; margin-top: 10px; }

.stage {
  position: relative;
  width: 340px;
  height: 200px;
  margin: 0 auto;
  border: 1px solid var(--line);
  background-color: #0c0d0f;
  background-image: linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 34px 34px;
  overflow: hidden;
  cursor: default;
  user-select: none;
  touch-action: none;
}


.hole {
  position: absolute;
  border: 1px dashed rgba(255, 255, 255, 0.32);
  border-radius: 10px;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.55);
  background: rgba(0, 0, 0, 0.55);
}

.piece {
  position: absolute;
  left: 0;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 10px;
  background-color: #202227;
  background-image: repeating-linear-gradient(
    -45deg,
    rgba(255, 255, 255, 0.055) 0 6px,
    rgba(255, 255, 255, 0) 6px 12px
  );
  cursor: grab;
  z-index: 3;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.piece:active { cursor: grabbing; }

.piece .grip {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-family: var(--mono);
  font-size: 16px;
  color: rgba(255, 255, 255, 0.42);
  letter-spacing: 1px;
}

.piece.done {
  border-color: var(--ok);
  box-shadow: 0 0 0 1px rgba(62, 213, 152, 0.5), 0 0 22px -6px rgba(62, 213, 152, 0.7);
  cursor: default;
}

.piece.done .grip { color: var(--ok); }

.piece.snap { transition: left 0.18s ease-out; }

.track {
  position: relative;
  width: 340px;
  height: 44px;
  margin: 12px auto 0;
  border: 1px solid var(--line);
  background: #0d0e10;
}

.track .fill {
  position: absolute;
  inset: 0 auto 0 0;
  width: 52px;
  background: rgba(229, 69, 47, 0.12);
}

.track .thumb {
  position: absolute;
  top: 0;
  left: 0;
  width: 52px;
  height: 42px;
  display: grid;
  place-items: center;
  border-right: 1px solid var(--line);
  background: var(--ink-3);
  cursor: grab;
  touch-action: none;
}

.track .thumb:active { cursor: grabbing; }

.track .hint {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 11px;
  letter-spacing: 0.16em;
  color: var(--muted-2);
  pointer-events: none;
  text-transform: uppercase;
}

.track.ok .thumb { background: rgba(62, 213, 152, 0.14); border-color: rgba(62, 213, 152, 0.5); }
.track.ok .hint { color: var(--ok); }

.gate-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  font-size: 11px;
  color: var(--muted-2);
  letter-spacing: 0.06em;
}

.gate-bottom nav { display: flex; gap: 18px; flex-wrap: wrap; }

.gate-bottom nav a { color: var(--muted); border-bottom: 1px solid transparent; padding-bottom: 2px; transition: color 0.2s, border-color 0.2s; }

.gate-bottom nav a:hover { color: var(--text); border-color: var(--line-strong); }

.fade-out { animation: fadeOut 0.4s var(--ease) forwards; }

@keyframes fadeOut {
  to { opacity: 0; transform: translateY(-10px) scale(0.99); filter: blur(4px); }
}

/* ———————————————————— 项目展示页（PPT 式） */

.deck {
  position: fixed;
  inset: 0;
  overflow: hidden;
  background: var(--ink);
}

.slides {
  display: flex;
  height: 100%;
  width: 100%;
  will-change: transform;
  transition: transform 0.66s var(--ease);
}

.slide {
  position: relative;
  flex: 0 0 100vw;
  height: 100vh;
  padding: 96px 88px 96px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  background: var(--ink);
}

.slide[data-bg="paper"] { background: #f4f2ec; color: #141414; }
.slide[data-bg="paper"] .kicker { color: rgba(0, 0, 0, 0.45); }
.slide[data-bg="paper"] .slide-body { color: rgba(0, 0, 0, 0.62); }
.slide[data-bg="accent"] { background: var(--acc); color: #fff; }
.slide[data-bg="accent"] .kicker { color: rgba(255, 255, 255, 0.72); }
.slide[data-bg="accent"] .slide-body { color: rgba(255, 255, 255, 0.82); }

.kicker {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 26px;
}

.slide-title {
  font-size: clamp(38px, 5.2vw, 76px);
  line-height: 1.08;
  letter-spacing: -0.032em;
  font-weight: 600;
  margin: 0;
  max-width: 15em;
}

.slide-body {
  margin-top: 26px;
  font-size: 16px;
  line-height: 1.85;
  color: var(--muted);
  max-width: 34em;
  white-space: pre-wrap;
}

.slide[data-align="center"] {
  align-items: center;
  text-align: center;
  justify-content: center;
}

.slide[data-align="center"] .slide-title,
.slide[data-align="center"] .slide-body { margin-left: auto; margin-right: auto; }

/* cover */
.lay-cover { justify-content: center; }
.lay-cover .cover-main { display: flex; flex-direction: column; gap: 26px; max-width: 62%; }

.lay-cover .cover-title {
  font-size: clamp(46px, 7vw, 104px);
  line-height: 1.02;
  letter-spacing: -0.04em;
  font-weight: 600;
  margin: 0;
}

.lay-cover .cover-sub { font-size: 17px; line-height: 1.7; color: var(--muted); max-width: 30em; }

.cover-visual {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 40%;
  overflow: hidden;
  border-left: 1px solid var(--line);
}

.cover-visual img { width: 100%; height: 100%; object-fit: cover; }

.cover-foot {
  position: absolute;
  left: 88px;
  bottom: 92px;
  display: flex;
  align-items: center;
  gap: 16px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  color: var(--muted-2);
  text-transform: uppercase;
}

/* section */
.lay-section { justify-content: center; }

.lay-section .big-index {
  font-size: clamp(96px, 17vw, 220px);
  line-height: 0.82;
  font-weight: 600;
  letter-spacing: -0.05em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255, 255, 255, 0.28);
  margin-bottom: 18px;
  user-select: none;
}

.slide[data-bg="paper"] .lay-section .big-index { -webkit-text-stroke-color: rgba(0, 0, 0, 0.22); }

.lay-section .slide-title { font-size: clamp(30px, 3.6vw, 52px); }

/* statement */
.lay-statement { justify-content: center; }

.lay-statement .slide-body {
  margin: 0;
  font-size: clamp(22px, 2.35vw, 34px);
  line-height: 1.72;
  color: var(--text);
  max-width: 24em;
  white-space: pre-wrap;
  letter-spacing: -0.008em;
}

.slide[data-bg="paper"] .lay-statement .slide-body { color: #1b1b1b; }

/* split */
.lay-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
  padding: 0;
}

.lay-split .split-text { padding: 96px 0 96px 88px; }
.lay-split .split-media { height: 100vh; overflow: hidden; border-left: 1px solid var(--line); }
.lay-split .split-media img { width: 100%; height: 100%; object-fit: cover; }

/* image */
.lay-image { padding: 0; }

.lay-image img.full {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lay-image .caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 120px 88px 84px;
  background: linear-gradient(180deg, rgba(6, 7, 8, 0) 0%, rgba(6, 7, 8, 0.86) 78%);
  color: #fff;
}

.lay-image .caption .slide-title { font-size: clamp(34px, 4vw, 58px); }
.lay-image .caption .kicker { color: rgba(255, 255, 255, 0.7); margin-bottom: 12px; }

/* gallery */
.lay-gallery { padding: 88px; }
.lay-gallery .gal-grid {
  display: grid;
  gap: 14px;
  flex: 1;
  margin-top: 28px;
  min-height: 0;
  grid-template-columns: repeat(2, 1fr);
}
.lay-gallery .gal-grid.n3 { grid-template-columns: repeat(3, 1fr); }
.lay-gallery .gal-grid.n4 { grid-template-columns: repeat(2, 1fr); grid-template-rows: repeat(2, 1fr); }
.lay-gallery .gal-grid figure { margin: 0; overflow: hidden; background: var(--ink-3); }
.lay-gallery .gal-grid img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* end */
.lay-end { align-items: center; justify-content: center; text-align: center; }
.lay-end .slide-title { font-size: clamp(40px, 5vw, 72px); }
.lay-end .end-code {
  margin-top: 34px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.3em;
  color: var(--muted);
  text-transform: uppercase;
}

/* 缺图占位 */
.placeholder {
  width: 100%;
  height: 100%;
  min-height: 180px;
  background-color: #111317;
  background-image: repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.016) 0 1px, transparent 1px 15px);
  display: grid;
  place-items: center;
  color: var(--muted-2);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

/* 顶栏与底栏 */
.deck-top {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 34px;
  z-index: 20;
  pointer-events: none;
  mix-blend-mode: difference;
}

.deck-top.on-light { mix-blend-mode: normal; color: #141414; }

.deck-top > * { pointer-events: auto; }

.deck-id {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.62);
}

.deck-top.on-light .deck-id { color: rgba(0, 0, 0, 0.55); }

.deck-id b { color: var(--acc); font-weight: 500; }
.deck-top.on-light .deck-id b { color: var(--acc); }

.deck-actions { display: flex; gap: 8px; align-items: center; }

.icon-btn {
  height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(0, 0, 0, 0.28);
  color: rgba(255, 255, 255, 0.8);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
  backdrop-filter: blur(8px);
}

.icon-btn:hover { border-color: rgba(255, 255, 255, 0.4); color: #fff; }

.deck-foot {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: 62px;
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 0 34px;
  z-index: 20;
  mix-blend-mode: difference;
}

.progress {
  flex: 1;
  height: 1px;
  background: rgba(255, 255, 255, 0.16);
  position: relative;
}

.progress span {
  position: absolute;
  inset: 0 auto 0 0;
  background: var(--acc);
  transition: width 0.5s var(--ease);
}

.counter { font-family: var(--mono); font-size: 11px; letter-spacing: 0.14em; color: rgba(255, 255, 255, 0.55); }

.nav-btn {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: transparent;
  color: rgba(255, 255, 255, 0.75);
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}

.nav-btn:hover { border-color: rgba(255, 255, 255, 0.5); color: #fff; }

.nav-btn[disabled] { opacity: 0.28; cursor: default; }

/* ———————————————————— 后台 */

.admin-body { background: #0b0c0d; }

.admin-login {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.admin-login .card { max-width: 380px; }

.admin-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 300px 1fr;
}

.rail {
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  background: #090a0b;
  max-height: 100vh;
  position: sticky;
  top: 0;
}

.rail-head { padding: 22px 20px 16px; border-bottom: 1px solid var(--line); }

.rail-head .label { display: block; margin-bottom: 10px; }

.rail-head strong { font-size: 15px; letter-spacing: 0.02em; }

.rail-list { flex: 1; overflow-y: auto; padding: 10px; }

.rail-item {
  display: block;
  width: 100%;
  text-align: left;
  padding: 12px 12px 13px;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
  margin-bottom: 4px;
}

.rail-item:hover { background: rgba(255, 255, 255, 0.03); }

.rail-item.active { border-color: var(--line-strong); background: rgba(255, 255, 255, 0.045); }

.rail-item .code {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  color: var(--acc);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.rail-item .nm { display: block; margin-top: 6px; font-size: 13.5px; letter-spacing: 0.01em; }

.rail-item .meta { display: block; margin-top: 3px; font-size: 11px; color: var(--muted-2); }

.dot { width: 5px; height: 5px; border-radius: 50%; display: inline-block; }
.dot.draft { background: #55585e; }
.dot.published { background: var(--ok); }

.rail-foot { padding: 14px; border-top: 1px solid var(--line); display: grid; gap: 8px; }

.editor { padding: 22px 26px 80px; overflow-y: auto; max-height: 100vh; }

.editor-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 22px;
  flex-wrap: wrap;
}

.editor-head h2 { margin: 0 0 4px; font-size: 19px; letter-spacing: -0.01em; }

.editor-head .hint { font-size: 11px; color: var(--muted-2); font-family: var(--mono); letter-spacing: 0.08em; }

.head-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.mini-btn {
  height: 34px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--text);
  font-size: 12px;
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, opacity 0.15s;
  white-space: nowrap;
}

.mini-btn:hover { background: rgba(255, 255, 255, 0.05); }

.mini-btn.primary { background: var(--acc); border-color: var(--acc); color: #fff; }

.mini-btn.primary:hover { background: #f04d36; }

.mini-btn.danger { border-color: rgba(229, 69, 47, 0.4); color: #ff7a63; }

.mini-btn.danger:hover { background: rgba(229, 69, 47, 0.1); }

.panel {
  border: 1px solid var(--line);
  padding: 20px;
  margin-bottom: 18px;
  background: #0e0f11;
}

.panel > .label { display: block; margin-bottom: 16px; }

.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

.grid3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }

.f { display: flex; flex-direction: column; gap: 6px; }

.f label { font-size: 11px; color: var(--muted); letter-spacing: 0.06em; }

.f input[type="text"], .f input[type="number"], .f textarea, .f select {
  background: #0a0b0d;
  border: 1px solid var(--line);
  padding: 9px 11px;
  font-size: 13px;
  outline: none;
  transition: border-color 0.15s;
  width: 100%;
}

.f input:focus, .f textarea:focus, .f select:focus { border-color: var(--line-strong); }

.f textarea { resize: vertical; min-height: 78px; line-height: 1.6; font-size: 13px; }

.f input[type="color"] { width: 44px; height: 34px; padding: 2px; background: #0a0b0d; border: 1px solid var(--line); }

.switch { display: flex; align-items: center; gap: 9px; font-size: 12px; color: var(--muted); cursor: pointer; user-select: none; }

.switch input { appearance: none; width: 34px; height: 18px; border: 1px solid var(--line-strong); background: #0a0b0d; position: relative; cursor: pointer; transition: background 0.2s, border-color 0.2s; flex: none; }

.switch input::after { content: ""; position: absolute; top: 2px; left: 2px; width: 12px; height: 12px; background: var(--muted); transition: transform 0.18s var(--ease), background 0.2s; }

.switch input:checked { border-color: var(--ok); background: rgba(62, 213, 152, 0.1); }

.switch input:checked::after { transform: translateX(16px); background: var(--ok); }

.slide-card { border: 1px solid var(--line); margin-bottom: 12px; background: #0c0d0f; }

.slide-card header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
}

.slide-card header .idx { font-family: var(--mono); font-size: 10px; color: var(--acc); letter-spacing: 0.14em; }

.slide-card header .lay { font-family: var(--mono); font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }

.slide-card header .sp { flex: 1; }

.slide-card .body { padding: 14px 12px; display: grid; gap: 12px; }

.icon-mini {
  width: 26px;
  height: 24px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-size: 11px;
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
}

.icon-mini:hover { color: var(--text); border-color: var(--line-strong); }

.thumb-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }

.thumb {
  width: 92px;
  height: 62px;
  border: 1px solid var(--line);
  background: #101113;
  overflow: hidden;
  position: relative;
  flex: none;
}

.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }

.thumb .gap { display: grid; place-items: center; height: 100%; font-size: 10px; color: var(--muted-2); font-family: var(--mono); }

.thumb .del {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.7);
  color: #ff7a63;
  font-size: 10px;
  cursor: pointer;
  border: 0;
}

.file-label {
  display: inline-flex;
  align-items: center;
  height: 30px;
  padding: 0 12px;
  border: 1px dashed var(--line-strong);
  color: var(--muted);
  font-size: 11px;
  cursor: pointer;
  letter-spacing: 0.04em;
  transition: color 0.15s, border-color 0.15s;
}

.file-label:hover { color: var(--text); border-color: var(--muted); }

.file-label input { display: none; }

.toast {
  position: fixed;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%) translateY(14px);
  background: #16181b;
  border: 1px solid var(--line-strong);
  padding: 10px 18px;
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--text);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.24s, transform 0.24s var(--ease);
  z-index: 100;
  max-width: 92vw;
}

.toast.on { opacity: 1; transform: translateX(-50%) translateY(0); }

.toast.bad { border-color: rgba(229, 69, 47, 0.55); color: #ff9f8d; }

.empty {
  padding: 60px 20px;
  text-align: center;
  color: var(--muted-2);
  font-size: 12px;
  border: 1px dashed var(--line);
  letter-spacing: 0.04em;
}

/* 滚动条 */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: #08090a; }
::-webkit-scrollbar-thumb { background: #24262a; }
::-webkit-scrollbar-thumb:hover { background: #33363b; }

/* ———————————————————— 移动端 */

@media (max-width: 860px) {
  .gate { padding: 20px; }
  .card { padding: 30px 22px 24px; }
  .card h1 { font-size: 23px; }
  .stage, .track { width: 100%; max-width: 340px; }
  .gate-bottom { flex-direction: column; align-items: flex-start; gap: 10px; }

  .slide { padding: 76px 26px; }
  .slide-title { font-size: clamp(28px, 8vw, 44px); }
  .lay-cover { padding: 90px 26px 70px; }
  .lay-cover .cover-main { max-width: 100%; }
  .cover-visual { position: relative; width: 100%; height: 40vh; border-left: 0; border-top: 1px solid var(--line); }
  .lay-cover { justify-content: center; padding: 84px 26px 130px; gap: 20px; }
  .cover-foot { left: 26px; bottom: 74px; }
  .lay-split { grid-template-columns: 1fr; gap: 0; }
  .lay-split .split-text { padding: 76px 26px; }
  .lay-split .split-media { height: 42vh; border-left: 0; border-top: 1px solid var(--line); }
  .lay-gallery { padding: 74px 20px; }
  .lay-gallery .gal-grid.n3 { grid-template-columns: repeat(2, 1fr); }
  .lay-image .caption { padding: 90px 26px 64px; }
  .deck-top { padding: 0 16px; height: 58px; }
  .deck-foot { padding: 0 16px; height: 54px; }
  .admin-shell { grid-template-columns: 1fr; }
  .rail { position: static; max-height: none; border-right: 0; border-bottom: 1px solid var(--line); }
  .rail-list { max-height: 42vh; }
  .editor { max-height: none; padding: 18px 16px 60px; }
  .grid2, .grid3 { grid-template-columns: 1fr; }
}
