:root {
  /* 暖骨纸 × 青玉底晕 × 朱砂印 — 去塑料平涂 */
  --page: #EFEAE3;
  --page-deep: #E6E0D7;
  --card: #FBF8F3;
  --ink: #1A1714;
  --ink-soft: #2C2824;
  --muted: #7A736B;
  --line: rgba(56, 44, 32, 0.08);
  --line-strong: rgba(56, 44, 32, 0.12);
  --play: #1C1916;
  --accent: #C41E2A;
  --accent-deep: #9E1520;
  --accent-soft: #F3E4E5;
  --jade: #8A9A88;
  --jade-mist: rgba(138, 154, 136, 0.22);
  --gold: #A8893A;
  /* 登录光源银（2026-09-18）：亮端/暗端。压墨 15.7:1 / 5.4:1，压暖骨纸 1.05:1 / 2.8:1
     首版 F2F5F7/9AA4AD 被用户判「稍微淡了」，两端各压深一档到现值 */
  --silver-hi: #EDF1F5;
  --silver-lo: #858F98;
  --rail: 220px;
  --dock: 56px;
  --radius: 10px;
  --radius-lg: 14px;
  --shadow:
    0 1px 0 rgba(255, 252, 247, 0.7) inset,
    0 10px 28px -18px rgba(40, 28, 18, 0.28);
  --shadow-soft: 0 8px 24px -16px rgba(40, 28, 18, 0.18);
  --ease: cubic-bezier(0.22, 0.8, 0.24, 1);
  --font-ui: "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  --font-brand: "Songti SC", "STSong", "Noto Serif SC", "SimSun", serif;
}
* { box-sizing: border-box; }
html, body {
  margin: 0;
  min-height: 100%;
  color: var(--ink);
  font-family: var(--font-ui);
  font-feature-settings: "kern" 1;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
  text-rendering: optimizeLegibility;
}
body.app {
  padding-left: var(--rail);
  background-color: var(--page);
  background-image:
    radial-gradient(ellipse 90% 55% at 8% -8%, var(--jade-mist), transparent 52%),
    radial-gradient(ellipse 70% 45% at 96% 2%, rgba(196, 30, 42, 0.05), transparent 48%),
    radial-gradient(ellipse 50% 30% at 50% 100%, rgba(168, 137, 58, 0.04), transparent 55%),
    linear-gradient(165deg, #F3EEE7 0%, var(--page) 42%, var(--page-deep) 100%);
  background-attachment: fixed;
}
section.view[hidden] { display: none !important; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2 { margin: 0; font-weight: 600; letter-spacing: 0.02em; }
h1 { font-size: 22px; }
h2 { font-size: 15px; }
.sub, .hint { margin: 0 0 18px; color: var(--muted); font-size: 13px; line-height: 1.65; }
.hint.tight { margin: 4px 0 0; }
.page-head {
  display: grid; grid-template-columns: 56px 1fr 56px; align-items: center;
  margin: 0 0 18px; min-height: 44px;
}
.page-head h1 {
  font-size: 17px; text-align: center;
  font-family: var(--font-brand);
  font-weight: 600;
  letter-spacing: 0.08em;
}
.back { color: var(--ink-soft); text-decoration: none; font-size: 14px; }
a.chip { display: inline-flex; align-items: center; text-decoration: none; }
a.ov-act { text-decoration: none; }

.rail {
  position: fixed; inset: 0 auto 0 0; width: var(--rail);
  padding: 28px 14px; z-index: 8;
  background:
    linear-gradient(180deg, rgba(251, 248, 243, 0.72) 0%, rgba(236, 232, 224, 0.88) 100%);
  border-right: 1px solid var(--line);
  backdrop-filter: blur(12px) saturate(1.05);
  -webkit-backdrop-filter: blur(12px) saturate(1.05);
}
.brand {
  display: block; color: var(--ink); text-decoration: none;
  font-family: var(--font-brand);
  font-size: 18px; font-weight: 600;
  letter-spacing: 0.14em;
  margin: 0 10px 36px;
}
.rail nav a {
  display: block; color: #5E574F; text-decoration: none;
  padding: 11px 12px; border-radius: 8px; margin-bottom: 3px; font-size: 14px;
  letter-spacing: 0.04em;
  transition: color 0.22s var(--ease), background 0.22s var(--ease);
}
.rail nav a:hover { color: var(--ink); background: rgba(251, 248, 243, 0.55); }
.rail nav a.active {
  background: var(--card);
  color: var(--ink);
  font-weight: 600;
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--line);
}

.main { min-height: 100vh; }
.view { min-height: 100vh; }
.play-view { background: transparent; }
/* 轮播：仅有接口 items 时显示；空 items 保持 hidden，禁止假幻灯 */
.home-banner {
  display: flex;
  gap: 8px;
  padding: 8px 12px 0;
  overflow-x: auto;
}
.home-banner[hidden] { display: none !important; }
.home-banner-item {
  flex: 0 0 auto;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
  color: var(--ink);
  text-decoration: none;
  font-size: 13px;
}
/* 继续观看：仅有接口 items 时显示；空 items 保持 hidden，禁假进度句 */
.continue-watch {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(26, 23, 20, 0.35);
  padding: 24px;
}
.continue-watch[hidden] { display: none !important; }
.continue-watch-card {
  width: min(360px, 100%);
  padding: 20px 18px;
  border-radius: var(--radius-lg);
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.5) inset;
}
.continue-watch-card p {
  margin: 0 0 16px;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.5;
}
.continue-watch-acts {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}
.btn-ghost {
  appearance: none;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink-soft);
  border-radius: var(--radius);
  padding: 8px 14px;
  font-size: 14px;
  cursor: pointer;
}
.shuffle-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 12px 0 4px;
}
.shuffle-bar .hint {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}
.light-view { padding: 28px 32px 48px; background: transparent; }
.sheet { width: 720px; max-width: 100%; margin: 0 auto; }
.desk {
  width: 1040px; max-width: 100%; margin: 0 auto;
  background: var(--card);
  border-radius: var(--radius-lg);
  padding: 28px 32px 36px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.theater {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
}
.stage {
  position: relative;
  aspect-ratio: 9 / 16;
  height: min(100vh - 32px, 920px);
  width: auto;
  max-width: 100%;
  background: var(--play);
  border-radius: var(--radius-lg);
  overflow: hidden;
  color: #F7F1EA;
  border: 1px solid rgba(255, 248, 240, 0.06);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.06) inset,
    0 24px 56px -20px rgba(20, 14, 10, 0.55),
    0 0 0 1px rgba(40, 28, 18, 0.2);
}
.stage video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: contain;
  background: var(--play);
}
.empty {
  margin: 0; position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  padding: 32px; text-align: center;
  color: #EDE6DC; font-size: 15px; font-weight: 500;
  letter-spacing: 0.06em;
  z-index: 1;
}
.empty[hidden], video[hidden] { display: none; }
.play-fade-top, .play-fade-bot {
  position: absolute; left: 0; right: 0; z-index: 2; pointer-events: none;
}
.play-fade-top {
  top: 0; height: 110px;
  background: linear-gradient(to bottom, rgba(18, 14, 12, 0.55), transparent);
}
.play-fade-bot {
  bottom: 0; height: 180px;
  background: linear-gradient(to top, rgba(18, 14, 12, 0.62), transparent);
}

.play-top {
  position: absolute; left: 0; right: 0; top: 0; z-index: 3;
  height: 58px; display: flex; align-items: flex-end; justify-content: center;
  gap: 32px; padding: 0 56px 12px;
}
.play-top a {
  color: rgba(247, 241, 234, 0.5); text-decoration: none; font-size: 15px;
  letter-spacing: 0.08em; position: relative;
  transition: color 0.2s var(--ease);
}
.play-top a.on { color: #F7F1EA; font-weight: 600; }
.play-top a.on::after {
  content: ""; position: absolute; left: 22%; right: 22%; bottom: -8px;
  height: 1.5px; background: var(--accent); border-radius: 1px;
  box-shadow: 0 0 8px rgba(196, 30, 42, 0.35);
}
.search-hit {
  position: absolute; right: 14px; bottom: 8px;
  width: 36px; height: 36px; display: grid; place-items: center; color: #F7F1EA;
  opacity: 0.88;
}
.search-hit svg { width: 20px; height: 20px; }

.ov-right {
  position: absolute; right: 10px; bottom: 118px; z-index: 3;
  display: flex; flex-direction: column; align-items: center; gap: 18px;
}
.ov-act {
  border: 0; background: transparent; color: #F7F1EA;
  display: flex; flex-direction: column; align-items: center; gap: 5px;
  font-size: 11px; letter-spacing: 0.04em;
  opacity: 0.92;
  transition: color 0.2s var(--ease), opacity 0.2s var(--ease);
}
.ov-act svg { width: 30px; height: 30px; filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.35)); }
.ov-act.is-on { color: #E84A54; opacity: 1; }
.ov-act.is-on svg path { fill: currentColor; }
.ov-bot {
  position: absolute; left: 16px; right: 76px; bottom: 24px; z-index: 3;
}
.ov-bot strong {
  display: block; font-size: 17px; font-weight: 600;
  font-family: var(--font-brand); letter-spacing: 0.06em;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.35);
}
.ov-bot p { margin: 6px 0 0; font-size: 12px; color: rgba(247, 241, 234, 0.72); line-height: 1.5; }
.ov-chips { display: flex; gap: 8px; margin-top: 14px; }
.chip {
  height: 28px; padding: 0 12px; border: 1px solid rgba(247, 241, 234, 0.18);
  border-radius: 8px;
  background: rgba(28, 25, 22, 0.28); color: #F7F1EA; font-size: 12px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.scrub {
  position: absolute; left: 12px; right: 12px; bottom: 6px; z-index: 4;
  height: 18px; margin: 0; appearance: none; background: transparent;
  accent-color: var(--accent);
}
.scrub::-webkit-slider-runnable-track {
  height: 2px; background: rgba(247, 241, 234, 0.22); border-radius: 1px;
}
.scrub::-webkit-slider-thumb {
  appearance: none; width: 9px; height: 9px; margin-top: -3.5px;
  border-radius: 50%; background: #F7F1EA;
  box-shadow: 0 0 0 2px rgba(196, 30, 42, 0.35);
}
.scrub::-moz-range-track { height: 2px; background: rgba(247, 241, 234, 0.22); }
.scrub::-moz-range-thumb {
  width: 9px; height: 9px; border: 0; border-radius: 50%; background: #F7F1EA;
}

.search-bar {
  display: flex; align-items: center; gap: 8px;
  height: 40px; padding: 0 14px; margin-bottom: 14px;
  background: rgba(251, 248, 243, 0.65);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 1px 0 rgba(255, 252, 247, 0.5) inset;
}
.search-bar svg { width: 18px; height: 18px; color: var(--muted); flex: none; }
.search-bar input {
  flex: 1; border: 0; background: transparent; outline: none; font-size: 14px;
}
.tabs {
  display: flex; gap: 20px; overflow-x: auto; padding: 0 2px 14px;
  font-size: 15px; color: var(--muted); scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tabs button {
  border: 0; background: none; color: inherit; padding: 0 0 8px; position: relative; white-space: nowrap;
  letter-spacing: 0.04em;
  transition: color 0.2s var(--ease);
}
.tabs button.on { color: var(--ink); font-weight: 600; }
.tabs button.on::after {
  content: ""; position: absolute; left: 12%; right: 12%; bottom: 0;
  height: 1.5px; background: var(--accent); border-radius: 1px;
}
.grid3 {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px 10px;
}
.poster {
  display: block; text-decoration: none; color: inherit;
}
.poster-fill {
  display: block; aspect-ratio: 9 / 16; border-radius: 8px;
  position: relative; overflow: hidden;
  border: 1px solid var(--line);
  background:
    radial-gradient(ellipse 80% 60% at 30% 20%, rgba(251, 248, 243, 0.55), transparent 55%),
    linear-gradient(155deg, #C8C2B6 0%, #A8B0A0 42%, #8F9588 100%);
  box-shadow: var(--shadow-soft);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}
.poster-fill::before {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(125deg, rgba(255, 255, 255, 0.18) 0%, transparent 42%),
    radial-gradient(circle at 70% 80%, rgba(196, 30, 42, 0.08), transparent 45%);
  pointer-events: none;
}
.poster-fill::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 42%;
  background: linear-gradient(to top, rgba(26, 23, 20, 0.42), transparent);
}
@media (prefers-reduced-motion: no-preference) {
  .poster:hover .poster-fill {
    transform: translateY(-3px);
    box-shadow: 0 14px 32px -16px rgba(40, 28, 18, 0.35);
  }
}
.poster b {
  display: block; margin-top: 8px; font-size: 12px; font-weight: 500;
  letter-spacing: 0.02em; color: var(--ink-soft);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.empty-copy {
  margin: 48px 0; text-align: center; color: var(--muted); font-size: 14px;
  letter-spacing: 0.04em;
}

.wallet {
  display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 0;
  background: var(--card); border-radius: var(--radius); padding: 18px 0; margin-bottom: 12px;
  text-align: center;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
}
.wallet > div + div { box-shadow: -1px 0 0 var(--line); }
.wallet b { display: block; font-size: 12px; color: var(--muted); font-weight: 500; letter-spacing: 0.04em; }
.wallet strong { display: block; margin-top: 6px; font-size: 18px; font-weight: 600; font-variant-numeric: tabular-nums; }
.wallet .is-gold strong { color: var(--gold); }
.panel {
  background: var(--card); border-radius: var(--radius); padding: 14px 16px 16px; margin-bottom: 12px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
}
.panel-hd { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.text-btn { border: 0; background: none; color: var(--accent); font-weight: 600; font-size: 13px; }
.days {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; text-align: center;
}
.days li {
  height: 34px; display: grid; place-items: center;
  border-radius: 8px; color: var(--muted); font-size: 12px;
  background: rgba(232, 226, 216, 0.65);
  border: 1px solid transparent;
}
.days li.today {
  color: var(--accent-deep); background: var(--accent-soft);
  font-weight: 600; border-color: rgba(196, 30, 42, 0.18);
}
.rows {
  background: var(--card); border-radius: var(--radius); overflow: hidden; margin-bottom: 12px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
}
.row-item {
  display: flex; align-items: center; justify-content: space-between;
  width: 100%; padding: 15px 16px; border: 0; background: transparent;
  border-bottom: 1px solid var(--line); text-align: left;
  color: inherit; text-decoration: none; min-height: 52px; font-size: 15px;
  transition: background 0.18s var(--ease);
}
.row-item:hover { background: rgba(239, 234, 227, 0.45); }
.row-item:last-child { border-bottom: 0; }
.row-item span { color: var(--muted); font-size: 13px; margin-left: auto; padding-right: 8px; }
.row-item:not(.static)::after {
  content: ""; width: 6px; height: 6px; flex: none;
  border-right: 1.5px solid #B5A99C; border-top: 1.5px solid #B5A99C;
  transform: rotate(45deg);
}
.freeze {
  margin: 8px 0 0; padding: 12px 14px; border-radius: 8px;
  background: var(--accent-soft); color: var(--ink); font-size: 13px;
  border: 1px solid rgba(196, 30, 42, 0.12);
}

/* 登录页协议行（对齐聚客伙伴 clients/wechat/pages/login 标准：
   勾选框 + 「我已阅读并同意」+ 两枚可点协议链；未勾选不出网、只本地提示） */
.agree-row {
  /* 与「登录」按钮、「没有账号，去注册」同轴居中（登录页整列居中，协议行不得单独左对齐） */
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  margin-top: 18px; padding: 0 2px;
}
.agree-box {
  width: 20px; height: 20px; margin-right: 9px; flex: none;
  border: 1.5px solid #B5A99C; border-radius: 5px; background: transparent;
  display: flex; align-items: center; justify-content: center; cursor: pointer;
}
.agree-on { border-color: var(--accent); }
.agree-tick { font-size: 14px; color: var(--accent); line-height: 1; }
.agree-text { font-size: 14px; color: var(--muted); letter-spacing: 0.02em; line-height: 1.75; }
.agree-link { font-size: 14px; color: var(--accent); text-decoration: none; line-height: 1.75; }
.agree-link:hover { text-decoration: underline; }

/* 协议：专业法务版式 —— 文档头 + 目录 + 条号悬挂缩进；正文只跟 GET /api/legal/* */
.legal { padding: 0 0 40px; }

.legal-head {
  text-align: center;
  padding: 4px 0 20px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 22px;
}
.legal-doc-title {
  font-family: var(--font-brand);
  font-size: 22px; font-weight: 600; color: var(--ink);
  letter-spacing: 0.16em; line-height: 1.5; margin: 0 0 14px;
}
.legal-rule { width: 40px; height: 2px; background: var(--accent); margin: 0 auto 14px; }
.legal-meta {
  margin: 0; color: var(--muted); font-size: 12px; letter-spacing: 0.1em;
  font-variant-numeric: tabular-nums;
}
.legal-draft {
  display: inline-block; margin-top: 12px; padding: 3px 10px;
  border: 1px solid rgba(196, 30, 42, 0.3); border-radius: 6px;
  color: var(--accent); font-size: 11px; letter-spacing: 0.18em;
}

.legal-toc {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 16px 16px 10px; margin-bottom: 28px;
  box-shadow: var(--shadow-soft);
}
.legal-toc-h {
  margin: 0 0 10px; color: var(--muted); font-size: 11px;
  letter-spacing: 0.3em; text-align: center;
}
.legal-toc-item {
  display: grid; grid-template-columns: 62px 1fr; gap: 10px;
  align-items: baseline; padding: 8px 2px; cursor: pointer;
  border-bottom: 1px dashed rgba(44, 40, 36, 0.09);
}
.legal-toc-item:last-child { border-bottom: 0; }
.legal-toc-item:hover .legal-toc-title { color: var(--ink); }
.legal-toc-no {
  color: var(--accent); font-size: 11.5px; letter-spacing: 0.06em;
  text-align: right; font-variant-numeric: tabular-nums;
}
.legal-toc-title { color: var(--ink-soft); font-size: 13px; line-height: 1.5; }

.legal-sec { margin-bottom: 26px; }
.legal-sec-h {
  position: relative; margin: 30px 0 14px; padding-left: 13px;
  font-family: var(--font-brand); font-size: 15.5px; font-weight: 600;
  color: var(--ink); letter-spacing: 0.1em; line-height: 1.6;
}
.legal-sec-h::before {
  content: ""; position: absolute; left: 0; top: 0.5em;
  width: 3px; height: 0.95em; background: var(--accent); border-radius: 1px;
}
.legal-sec-no {
  color: var(--accent); margin-right: 9px; font-size: 13px;
  letter-spacing: 0.08em; font-family: var(--font-brand);
}

.legal-clause {
  display: grid; grid-template-columns: 44px 1fr; gap: 8px;
  margin: 0 0 9px; align-items: start;
}
.legal-clause-no {
  color: var(--muted); font-size: 12.5px; text-align: right;
  padding-top: 3px; font-variant-numeric: tabular-nums; letter-spacing: 0.02em;
}
.legal-clause-text {
  margin: 0; color: var(--ink-soft); font-size: 13.5px; line-height: 1.92;
  letter-spacing: 0.02em; text-align: justify; text-justify: inter-ideograph;
}
.legal-clause-text strong { color: var(--ink); font-weight: 600; }
.legal-para {
  margin: 0 0 9px; color: var(--ink-soft); font-size: 13.5px; line-height: 1.92;
  letter-spacing: 0.02em; text-align: justify; text-justify: inter-ideograph;
}
.legal-para strong { color: var(--ink); font-weight: 600; }

.legal-sub {
  margin: 18px 0 8px; font-size: 13.5px; font-weight: 600;
  color: var(--ink); letter-spacing: 0.04em; line-height: 1.7;
}
.legal-sub strong { color: var(--ink); font-weight: 600; }
.legal-bullet {
  display: grid; grid-template-columns: 44px 1fr; gap: 8px;
  margin: 0 0 7px; align-items: start;
}
.legal-bullet-mark {
  color: var(--muted); text-align: right; font-size: 13px; line-height: 1.92;
}
.legal-bullet-text {
  margin: 0; color: var(--ink-soft); font-size: 13.5px; line-height: 1.92;
  letter-spacing: 0.02em; text-align: justify; text-justify: inter-ideograph;
}
.legal-bullet-text strong { color: var(--ink); font-weight: 600; }
.legal-tr {
  display: flex; gap: 10px; padding: 9px 11px; margin: 0 0 7px;
  background: var(--card); border: 1px solid var(--line); border-radius: 8px;
  font-size: 12.5px; line-height: 1.7; color: var(--ink-soft);
}
.legal-td { flex: 1; min-width: 0; }
.legal-td-key { flex: 0 0 34%; color: var(--ink); font-weight: 600; }
.legal-tr strong { color: var(--ink); font-weight: 600; }

.legal-hint {
  margin: 40px 0 0; padding: 12px 14px; border-radius: 8px;
  background: var(--accent-soft); color: var(--ink); font-size: 13px;
  border: 1px solid rgba(196, 30, 42, 0.12); text-align: center;
}
.legal-foot {
  margin-top: 38px; padding-top: 18px; border-top: 1px solid var(--line);
  text-align: center; color: var(--muted); font-size: 11.5px; letter-spacing: 0.14em;
}

/* 登录：淡入眼帘；封面底与界面同骨纸 #EFEAE3 无缝；流星落星标 */
.login-view {
  padding-top: 0;
  background: #EFEAE3;
}
.login-sheet { max-width: 420px; padding-bottom: 32px; }
.login-hero {
  /* 限高时同步缩宽，保持 3:4；底与页同色，禁色差方块 */
  position: relative;
  width: 100%;
  max-width: min(100%, calc(min(52vh, 420px) * 3 / 4));
  aspect-ratio: 3 / 4;
  max-height: min(52vh, 420px);
  margin: 0 auto 18px;
  overflow: hidden;
  border-radius: 0;
  background: #EFEAE3;
  border-bottom: 0;
}
.login-hero::before {
  /* 色相贴合骨纸：保留墨字明度，纸底与界面无缝 */
  content: "";
  position: absolute;
  inset: 0;
  background: #EFEAE3;
  mix-blend-mode: color;
  pointer-events: none;
  z-index: 1;
}
.login-hero::after {
  /* 旧融色条关闭；巨线改走 login-ju-trace，禁止椭圆圈套巨 */
  content: none;
  display: none;
}
.login-ju-trace {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 2;
}
.login-ju-trace-arm {
  /* 星标 70.1%/22.9% 十字半幅约 4.5；线不得过 (210.3,91.6)，禁 y=97.6 星下缺口，上沿贴墨经 209.7 84.8 */
  fill: none;
  stroke: url(#juSilver);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
  animation: loginJuTraceDraw 1.7s ease-in-out 1s forwards;
}
.login-word-trace {
  /* 四字+印线贴墨；银渐变；与巨线同拍从左至右走出（印线是 147.6×0.7 横细带，扫掠与绕一周观感等价） */
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 2;
  clip-path: inset(0 100% 0 0);
  animation: loginWordSweep 1.7s ease-in-out 1s forwards;
}
.login-word-trace-arm {
  fill: none;
  stroke: url(#juSilver);
  stroke-width: 0.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.login-cover {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
  opacity: 0;
  transform: none !important;
  animation: loginLgSettle 0.9s ease-out forwards;
}
/* 流星：顶栏底边×巨斜左上 → 顶右星标；尾翼跟滑落轴淡入落位；限英雄区不压提示语 */
.login-flash {
  position: absolute;
  top: 22.9%;
  left: 70.1%;
  width: 88px;
  height: 2px;
  margin: -1px 0 0 -84px;
  pointer-events: none;
  z-index: 3;
  border-radius: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(133, 143, 152, 0.12) 22%,
    rgba(237, 241, 245, 0.5) 55%,
    #EDF1F5 86%,
    #858F98 100%
  );
  box-shadow:
    0 0 2px rgba(237, 241, 245, 0.85),
    0 0 5px rgba(133, 143, 152, 0.35);
  opacity: 0;
  transform-origin: right center;
  animation: loginFlashStrike 0.68s cubic-bezier(0.18, 0.72, 0.22, 1) 0.3s forwards;
}
.login-flash::before {
  /* 星标落点：菱形尖头，对准巨字角上星标 */
  content: "";
  position: absolute;
  right: -2px;
  top: 50%;
  width: 5px;
  height: 5px;
  margin-top: -2.5px;
  background: #EDF1F5;
  transform: rotate(45deg);
  box-shadow:
    0 0 3px #EDF1F5,
    0 0 6px rgba(237, 241, 245, 0.85),
    0 0 10px rgba(133, 143, 152, 0.4);
}
.login-flash::after {
  /* 尾翼：跟滑落方向（父级 43.5deg）自起点侧向星标头 scaleX 淡入落位；路径坐标不变 */
  content: "";
  position: absolute;
  right: 6px;
  top: 50%;
  width: 64px;
  height: 14px;
  margin-top: -7px;
  border-radius: 50% 4px 4px 50%;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(133, 143, 152, 0.06) 22%,
    rgba(237, 241, 245, 0.22) 55%,
    rgba(237, 241, 245, 0.55) 100%
  );
  filter: blur(0.5px);
  opacity: 0;
  transform: scaleX(0);
  transform-origin: right center;
  animation: loginFlashWing 0.68s cubic-bezier(0.18, 0.72, 0.22, 1) 0.3s forwards;
  pointer-events: none;
}
@keyframes loginLgSettle {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes loginFlashStrike {
  /* 1B+2A+3A：top:0%/left:38% → 70.1%/22.9%；角=atan2(22.9%×4/3,32.1%)≈43.5deg；禁循环 */
  0% {
    opacity: 0;
    top: 0%;
    left: 38%;
    transform: rotate(43.5deg) scaleX(0.65);
  }
  28% {
    opacity: 0.85;
    top: 10%;
    left: 52%;
    transform: rotate(43.5deg) scaleX(0.95);
  }
  48% {
    opacity: 1;
    top: 22.9%;
    left: 70.1%;
    transform: rotate(43.5deg) scaleX(1);
  }
  62% {
    opacity: 1;
    top: 22.9%;
    left: 70.1%;
    transform: rotate(43.5deg) scaleX(1);
  }
  100% {
    opacity: 0;
    top: 22.9%;
    left: 70.1%;
    transform: rotate(43.5deg) scaleX(0.9);
  }
}
@keyframes loginFlashWing {
  /* 跟滑落轴：自尾（顶栏侧）向头（星标）展开后随击灭 */
  0% { opacity: 0; transform: scaleX(0); }
  28% { opacity: 0.45; transform: scaleX(0.55); }
  48% { opacity: 0.85; transform: scaleX(1); }
  62% { opacity: 0.65; transform: scaleX(1); }
  100% { opacity: 0; transform: scaleX(0.9); }
}
/* 巨字顶右星标：细小星芒闪烁（小面积；与 strike 分离；禁把 strike 改循环） */
.login-star {
  position: absolute;
  top: 22.9%;
  left: 70.1%;
  width: 3px;
  height: 3px;
  margin: -1.5px 0 0 -1.5px;
  pointer-events: none;
  z-index: 4;
  opacity: 0;
  border-radius: 50%;
  background: #EDF1F5;
  box-shadow: 0 0 1.5px rgba(237, 241, 245, 0.95);
  animation: loginStarTwinkle 2.2s ease-in-out 1s infinite;
}
.login-star::before,
.login-star::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(237, 241, 245, 0.95) 50%,
    transparent 100%
  );
  box-shadow: none;
}
/* 十字细芒：像小星星，不铺大光斑 */
.login-star::before {
  width: 9px;
  height: 1px;
  margin: -0.5px 0 0 -4.5px;
}
.login-star::after {
  width: 1px;
  height: 9px;
  margin: -4.5px 0 0 -0.5px;
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(237, 241, 245, 0.95) 50%,
    transparent 100%
  );
}
@keyframes loginJuTraceDraw {
  from { stroke-dashoffset: 100; }
  to { stroke-dashoffset: 0; }
}
@keyframes loginWordSweep {
  /* 四字+印线：左→右走出，与 loginJuTraceDraw 同拍（1.7s / 延迟 1s）。clip-path 不被支持时退化为淡入，不消失 */
  from { clip-path: inset(0 100% 0 0); opacity: 0; }
  1% { opacity: 1; }
  to { clip-path: inset(0 0 0 0); opacity: 1; }
}
@keyframes loginStarTwinkle {
  0%, 100% { opacity: 0.15; transform: scale(0.55); }
  18% { opacity: 0.9; transform: scale(1); }
  32% { opacity: 0.25; transform: scale(0.6); }
  48% { opacity: 0.75; transform: scale(0.92); }
  62% { opacity: 0.2; transform: scale(0.55); }
  78% { opacity: 0.85; transform: scale(1.05); }
}
@media (prefers-reduced-motion: reduce) {
  .login-cover { animation: none; opacity: 1; }
  .login-flash,
  .login-flash::after { animation: none; opacity: 0; }
  .login-ju-trace-arm {
    animation: none;
    stroke-dashoffset: 0;
  }
  .login-word-trace {
    animation: none;
    clip-path: none;
  }
  .login-star { animation: none; opacity: 0.45; transform: scale(0.85); }
}
.login-hint { text-align: center; margin: 0 0 20px; letter-spacing: 0.04em; }
.login-form { padding: 0 4px; }
.login-field {
  display: block;
  margin: 0 0 12px;
  font-size: 12px;
  color: #7A736B;
  letter-spacing: 0.14em;
}
.login-field .login-static {
  display: block;
  width: 100%;
  margin-top: 8px;
  height: 48px;
  line-height: 48px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid rgba(56, 44, 32, 0.12);
  background: #FBF8F3;
  color: #1A1714;
  letter-spacing: 0.02em;
}
.login-field input {
  display: block;
  width: 100%;
  margin-top: 8px;
  height: 48px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid rgba(56, 44, 32, 0.12);
  background: #FBF8F3;
  color: #1A1714;
  font-size: 15px;
  letter-spacing: 0.02em;
  box-sizing: border-box;
}
.login-field input:focus {
  outline: none;
  border-color: rgba(196, 30, 42, 0.35);
  box-shadow: 0 0 0 3px rgba(196, 30, 42, 0.08);
}
.login-field-row {
  position: relative;
  display: block;
  margin-top: 8px;
}
.login-field-row input {
  margin-top: 0;
  padding-right: 36px;
}
.login-mark {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  line-height: 1;
  pointer-events: none;
}
.login-mark.is-ok { color: var(--jade); }
.login-mark.is-bad { color: var(--accent); }
.login-sms-btn:disabled {
  opacity: 0.45;
  cursor: default;
}
.login-sms-btn.is-ready {
  border-color: rgba(138, 154, 136, 0.55);
  color: var(--ink);
}
.login-sms-btn.is-wait {
  letter-spacing: 0;
  color: var(--ink-soft);
}
.login-sms-btn.is-frequent {
  letter-spacing: 0.06em;
  color: var(--accent);
}
.login-meta {
  display: flex;
  justify-content: flex-end;
  margin: 2px 0 18px;
}
.login-switch {
  margin: 18px 0 0;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.04em;
}
.login-switch a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid rgba(196, 30, 42, 0.35);
  padding-bottom: 1px;
}
.login-link {
  border: 0;
  background: transparent;
  color: #7A736B;
  font-size: 12px;
  letter-spacing: 0.06em;
  padding: 0;
  cursor: pointer;
  text-decoration: none;
}
.login-link:hover { color: var(--accent-deep); }
.login-submit {
  width: 100%;
  height: 48px;
  border-radius: 10px;
  letter-spacing: 0.2em;
}
.login-or {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  margin: 22px 0 14px;
  color: #9A9288;
  font-size: 11px;
  letter-spacing: 0.16em;
}
.login-or::before,
.login-or::after {
  content: "";
  height: 1px;
  background: rgba(56, 44, 32, 0.1);
}
.login-sms-row .login-sms-line {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  margin-top: 8px;
  align-items: stretch;
}
.login-sms-row input {
  margin-top: 0;
}
.login-sms-btn {
  height: 48px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid rgba(56, 44, 32, 0.14);
  background: #FBF8F3;
  color: #1A1714;
  font-size: 12px;
  letter-spacing: 0.06em;
  white-space: nowrap;
  cursor: pointer;
}
.login-sms-btn:hover {
  border-color: rgba(196, 30, 42, 0.35);
  color: var(--accent-deep);
}
.login-quick {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}
.login-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 44px;
  border-radius: 10px;
  border: 1px solid transparent;
  font-size: 12px;
  letter-spacing: 0.04em;
  cursor: pointer;
  background: #FBF8F3;
  color: #1A1714;
}
/* 官方徽章图形：色值锁平台官方色，禁漂朱砂；图形为色标示意（非商标位图） */
.login-badge-mark {
  width: 18px;
  height: 18px;
  flex: none;
  display: inline-block;
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
}
.login-badge-mark-weixin {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%2307C160' d='M9.4 3.1C5.1 3.1 1.7 6 1.7 9.6c0 2.1 1.2 4 3.1 5.2l-.6 2.3 2.5-1.3c.7.2 1.5.3 2.3.3.3 0 .5 0 .8 0-.2-.5-.3-1-.3-1.6 0-3.7 3.5-6.7 7.9-6.7.3 0 .5 0 .8.1C17.1 5.3 13.5 3.1 9.4 3.1z'/%3E%3Cpath fill='%2307C160' d='M17.4 10.4c-3.5 0-6.4 2.4-6.4 5.3s2.9 5.3 6.4 5.3c.6 0 1.1-.1 1.6-.2l2 1.1-.5-1.9c1.5-1 2.5-2.5 2.5-4.3 0-2.9-2.9-5.3-6.4-5.3z'/%3E%3C/svg%3E");
}
.login-badge-mark-douyin {
  /* 抖音官方双色 #25F4EE / #FE2C55 */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%2325F4EE' d='M14.2 2.2h2.2c.2 1.9 1.4 3.5 3.2 4.2v2.3c-1.3-.1-2.5-.6-3.5-1.4v6.6c0 3.2-2.6 5.7-5.8 5.7S4.5 17.1 4.5 13.9s2.6-5.7 5.8-5.7c.3 0 .6 0 .9.1v2.5c-.3-.1-.6-.2-.9-.2-1.8 0-3.3 1.5-3.3 3.3s1.5 3.3 3.3 3.3 3.3-1.5 3.3-3.3V2.2z'/%3E%3Cpath fill='%23FE2C55' d='M15.4 3.4h2.2c.2 1.9 1.4 3.5 3.2 4.2v2.3c-1.3-.1-2.5-.6-3.5-1.4v6.6c0 3.2-2.6 5.7-5.8 5.7S5.7 18.3 5.7 15.1s2.6-5.7 5.8-5.7c.3 0 .6 0 .9.1v2.5c-.3-.1-.6-.2-.9-.2-1.8 0-3.3 1.5-3.3 3.3s1.5 3.3 3.3 3.3 3.3-1.5 3.3-3.3V3.4z' opacity='.85'/%3E%3C/svg%3E");
}
.login-badge-mark-kuaishou {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Crect x='3.2' y='3.2' width='17.6' height='17.6' rx='5.2' fill='%23FF5000'/%3E%3Cpath fill='%23FBF8F3' d='M10 8.2v7.6l6.4-3.8z'/%3E%3C/svg%3E");
}
.login-badge-mark-xhs {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23FF2442' d='M6.2 4.2h4.2c.4 0 .8.2 1.1.5L12 5.4l.5-.7c.3-.3.7-.5 1.1-.5h4.2c.8 0 1.4.6 1.4 1.4v12.8c0 .8-.6 1.4-1.4 1.4H13c-.8 0-1.4-.6-1.4-1.4V9.6L12 8.8l-.6.8v8.8c0 .8-.6 1.4-1.4 1.4H6.2c-.8 0-1.4-.6-1.4-1.4V5.6c0-.8.6-1.4 1.4-1.4z'/%3E%3C/svg%3E");
}
/* 官方色标：微信绿 / 抖音青红 / 快手橙 / 小红书红（禁 #C41E2A） */
.login-badge-weixin {
  border-color: rgba(7, 193, 96, 0.35);
  color: #07C160;
}
.login-badge-douyin {
  border-color: rgba(22, 24, 35, 0.28);
  color: #161823;
}
.login-badge-kuaishou {
  border-color: rgba(255, 80, 0, 0.35);
  color: #FF5000;
}
.login-badge-xhs {
  border-color: rgba(255, 36, 66, 0.35);
  color: #FF2442;
}
.login-quick-btn {
  width: 100%;
  height: 44px;
  border-radius: 10px;
  border: 1px solid rgba(56, 44, 32, 0.14);
  background: transparent;
  color: #1A1714;
  font-size: 13px;
  letter-spacing: 0.12em;
  cursor: pointer;
}
.login-quick-btn:hover {
  border-color: rgba(196, 30, 42, 0.35);
  color: var(--accent-deep);
}
.login-form .freeze { margin-top: 14px; }

.me-head {
  display: grid; grid-template-columns: 56px 1fr auto; gap: 12px; align-items: center;
  margin-bottom: 16px;
}
.me-head .ghost-btn[hidden] { display: none; }
.avatar {
  width: 56px; height: 56px; border-radius: 50%;
  border: 1px solid var(--line-strong);
  background-color: #D8D0C4;
  background-image:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237A736B' stroke-width='1.5'><circle cx='12' cy='8.2' r='3.1'/><path d='M5.2 19c1.3-3 3.6-4.4 6.8-4.4s5.5 1.4 6.8 4.4'/></svg>"),
    radial-gradient(circle at 35% 28%, #F5F0E8, #D0C8BA 72%);
  background-repeat: no-repeat, no-repeat;
  background-position: center 10px, center;
  background-size: 30px, cover;
}
.ghost-btn {
  height: 32px; padding: 0 14px; border-radius: 8px;
  border: 1px solid rgba(196, 30, 42, 0.45); color: var(--accent-deep); text-decoration: none;
  display: grid; place-items: center; font-size: 13px; font-weight: 600;
  background: rgba(251, 248, 243, 0.9);
  letter-spacing: 0.04em;
}
.pyramid { display: grid; gap: 8px; margin-bottom: 12px; position: relative; padding-left: 14px; }
.pyramid::before {
  content: ""; position: absolute; left: 4px; top: 16px; bottom: 16px; width: 1px; background: var(--line-strong);
}
.lv {
  background: var(--card); border-radius: var(--radius); padding: 14px 16px;
  display: grid; grid-template-columns: 1fr auto; grid-template-rows: auto auto;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft); position: relative;
  color: inherit; text-decoration: none;
}
.lv::before {
  content: ""; position: absolute; left: -14px; top: 50%; width: 10px; height: 1px; background: var(--line-strong);
}
.lv b { font-size: 13px; font-weight: 600; letter-spacing: 0.04em; }
.lv strong {
  grid-column: 2; grid-row: 1 / span 2; font-size: 24px; align-self: center;
  font-variant-numeric: tabular-nums; color: var(--accent);
}
.lv span { grid-column: 1; color: var(--muted); font-size: 12px; margin-top: 2px; }
.invite {
  display: flex; align-items: center; justify-content: space-between;
  background: var(--card); border-radius: var(--radius); padding: 18px 16px; margin-bottom: 12px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
}
.invite span { font-size: 13px; color: var(--muted); }
.invite strong { font-size: 16px; color: var(--muted); font-weight: 600; letter-spacing: 0.06em; }

label { display: block; margin: 0 0 14px; font-size: 13px; color: #5E574F; letter-spacing: 0.02em; }
input[type="url"], input[type="text"], input[type="tel"], input[type="search"] {
  display: block; width: 100%; margin-top: 6px; height: 44px; padding: 0 14px;
  border: 1px solid var(--line-strong); border-radius: 8px;
  background: rgba(251, 248, 243, 0.92);
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
input[type="url"]:focus, input[type="text"]:focus, input[type="tel"]:focus, input[type="search"]:focus {
  outline: none;
  border-color: rgba(196, 30, 42, 0.35);
  box-shadow: 0 0 0 3px rgba(196, 30, 42, 0.08);
}
.check { display: flex; align-items: center; gap: 8px; height: 44px; }
.btn, .btn-dark {
  display: block; width: 100%; margin: 0 0 10px; height: 46px; border-radius: 9px;
  text-align: center; text-decoration: none; font-weight: 600; border: 0;
  letter-spacing: 0.06em;
  transition: transform 0.18s var(--ease), filter 0.18s var(--ease);
}
.btn {
  background: rgba(251, 248, 243, 0.95); color: var(--ink);
  border: 1px solid var(--line-strong);
  box-shadow: none;
}
.btn-dark {
  background: linear-gradient(180deg, #D42834 0%, var(--accent) 48%, var(--accent-deep) 100%);
  color: #FFF8F5;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.18) inset, 0 8px 18px -10px rgba(158, 21, 32, 0.55);
}
.btn-dark[hidden] { display: none; }
@media (prefers-reduced-motion: no-preference) {
  .btn-dark:hover { filter: brightness(1.03); }
  .btn-dark:active, .btn:active { transform: translateY(1px); }
}
.preview {
  margin-top: 14px; padding: 12px; background: rgba(239, 234, 227, 0.7); border-radius: 8px;
  white-space: pre-wrap; font-size: 12px; max-height: 240px; overflow: auto;
  border: 1px solid var(--line);
}
.table { width: 100%; border-collapse: collapse; font-size: 13px; }
.table th { text-align: left; color: var(--muted); font-weight: 500; padding: 8px 0; border-bottom: 1px solid var(--line); }
.table td { padding: 12px 0; border-bottom: 1px solid var(--line); word-break: break-all; }
.table select { max-width: 120px; border: 0; background: rgba(239, 234, 227, 0.8); border-radius: 8px; padding: 6px 8px; font: inherit; }
.ops-pane select {
  display: block; width: 100%; margin: 6px 0 12px; height: 44px;
  border: 1px solid var(--line); border-radius: 8px; background: rgba(239, 234, 227, 0.65); padding: 0 12px; font: inherit;
}
.ops-tabs {
  display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 22px;
}
.ops-tabs a, .ops-tabs button {
  height: 32px; padding: 0 12px; border: 1px solid var(--line); border-radius: 8px;
  background: rgba(239, 234, 227, 0.7); color: #5E574F; font-size: 13px;
  text-decoration: none; display: inline-flex; align-items: center;
  letter-spacing: 0.02em;
}
.ops-tabs a.on, .ops-tabs button.on {
  background: var(--accent); color: #FFF8F5; border-color: transparent;
}
.ep-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.ep-grid a, .ep-grid button {
  height: 40px; border: 1px solid var(--line); border-radius: 8px;
  background: rgba(239, 234, 227, 0.7); font-weight: 600;
  display: grid; place-items: center; text-decoration: none; color: inherit;
}
.ep-grid .on { background: var(--accent-soft); color: var(--accent-deep); border-color: rgba(196, 30, 42, 0.2); }

.tabbar { display: none; }
.ic {
  width: 22px; height: 22px; display: block; background: currentColor;
  -webkit-mask: var(--ico) center / 22px no-repeat;
  mask: var(--ico) center / 22px no-repeat;
}
.ic-home { --ico: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.7'><path d='M4 10.5 12 4l8 6.5V20a1 1 0 0 1-1 1h-5v-6H10v6H5a1 1 0 0 1-1-1z'/></svg>"); }
.ic-grid { --ico: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.7'><rect x='4' y='4' width='6.5' height='6.5' rx='1.2'/><rect x='13.5' y='4' width='6.5' height='6.5' rx='1.2'/><rect x='4' y='13.5' width='6.5' height='6.5' rx='1.2'/><rect x='13.5' y='13.5' width='6.5' height='6.5' rx='1.2'/></svg>"); }
.ic-gift { --ico: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.7'><rect x='3' y='10' width='18' height='10' rx='1.4'/><path d='M3 10h18M12 10V20M12 10c0-3 2-5 4.5-5S21 7 21 10h-9c0-3-2-5-4.5-5S3 7 3 10h9z'/></svg>"); }
.ic-me { --ico: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.7'><circle cx='12' cy='8' r='3.2'/><path d='M5 19c1.4-3 3.8-4.5 7-4.5S17.6 16 19 19'/></svg>"); }

.mask {
  position: fixed; inset: 0; z-index: 20;
  background: rgba(28, 22, 16, 0.32); display: flex; align-items: flex-end; justify-content: center;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}
.mask[hidden] { display: none; }
.drawer {
  width: min(520px, 100%); background: var(--card);
  border-radius: 16px 16px 0 0;
  padding: 8px 16px 28px; max-height: 72vh; overflow: auto;
  border: 1px solid var(--line);
  border-bottom: 0;
  box-shadow: 0 -12px 40px -12px rgba(40, 28, 18, 0.28);
}
.drawer-hd {
  display: flex; align-items: center; justify-content: space-between;
  height: 48px;
}
.icon-x { border: 0; background: none; color: var(--muted); font-size: 13px; letter-spacing: 0.04em; }
.drawer-bd .ep {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; padding: 8px 0 16px;
}
.drawer-bd .ep button, .speed-list button {
  height: 40px; border: 1px solid var(--line); border-radius: 8px;
  background: rgba(239, 234, 227, 0.7); font-weight: 600;
}
.drawer-bd .ep button.on, .speed-list button.on {
  background: var(--accent-soft); color: var(--accent-deep); border-color: rgba(196, 30, 42, 0.2);
}
.speed-list { display: grid; gap: 8px; padding: 8px 0 12px; }
.comment-empty { color: var(--muted); text-align: center; padding: 28px 0; letter-spacing: 0.04em; }
.comment-form { display: flex; gap: 8px; }
.comment-form input {
  flex: 1; height: 40px; margin: 0; border-radius: 8px;
}
.comment-form button {
  height: 40px; padding: 0 16px; border: 0; border-radius: 8px;
  background: linear-gradient(180deg, #D42834 0%, var(--accent) 100%);
  color: #FFF8F5; font-weight: 600; letter-spacing: 0.04em;
}

@media (max-width: 860px) {
  body.app { padding-left: 0; padding-bottom: calc(var(--dock) + env(safe-area-inset-bottom)); }
  .rail { display: none; }
  .light-view { padding: 12px 0 24px; }
  .sheet, .desk { width: 100%; border-radius: 0; box-shadow: none; border-left: 0; border-right: 0; }
  .desk { padding: 16px; }
  .sheet { padding: 0 16px; }
  .tabbar {
    display: grid; grid-template-columns: repeat(4, 1fr);
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 9;
    height: calc(var(--dock) + env(safe-area-inset-bottom));
    padding-bottom: env(safe-area-inset-bottom);
    background: rgba(251, 248, 243, 0.92);
    border-top: 1px solid var(--line);
    backdrop-filter: blur(14px) saturate(1.05);
    -webkit-backdrop-filter: blur(14px) saturate(1.05);
    box-shadow: none;
  }
  .tabbar a {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 2px; color: #8E857C; text-decoration: none; font-size: 10px;
    letter-spacing: 0.04em;
    transition: color 0.2s var(--ease);
  }
  .tabbar a.active { color: var(--accent); font-weight: 600; }
}
@media (min-width: 861px) {
  .tabbar { display: none !important; }
}
@media (orientation: portrait) and (max-width: 480px) {
  .play-view, .theater { background: var(--play); }
  .theater { min-height: calc(100vh - var(--dock) - env(safe-area-inset-bottom)); }
  .stage {
    width: 100%; height: calc(100vh - var(--dock) - env(safe-area-inset-bottom));
    max-width: none; border-radius: 0; aspect-ratio: auto;
    box-shadow: none; border: 0;
  }
}
@media (orientation: landscape) and (max-width: 860px) {
  body.app { padding-bottom: 0; }
  .tabbar { display: none !important; }
  .theater { min-height: 100vh; background: transparent; }
  .stage {
    width: auto; height: 100vh; aspect-ratio: 9 / 16; margin: 0 auto; border-radius: 12px;
  }
  .ov-right { bottom: 48px; }
  .ov-bot { bottom: 16px; }
}
