/* ==========================================================================
   初声实验室 · Effect Deck 调音中心 (克制暗黑 + 四色流光定制版)
   ========================================================================== */
@font-face {
  font-family: 'YinPinHongMeng';
  src: url('../assets/fonts/YinPinHongMeng.woff2?v=20261205a') format('woff2'),
       url('../assets/fonts/YinPinHongMeng.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'MSJH';
  src: url('../assets/fonts/msjh-light.woff2') format('woff2');
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'MSJH';
  src: url('../assets/fonts/msjh-regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'MSJH';
  src: url('../assets/fonts/msjh-bold.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
:root {
  --ios-bg-deep: #121214;
  --ios-glass-bg: rgba(28, 28, 30, 0.85);
  --ios-glass-card: rgba(36, 36, 38, 0.78);
  --ios-glass-inner: rgba(20, 20, 22, 0.85);
  --ios-border-light: rgba(255, 255, 255, 0.08);
  --ios-border-glow: rgba(255, 255, 255, 0.24);

  --ios-accent-pill: #636366;
  --ios-track-bg: #2c2c2e;

  --aura-cyan: #38bdf8;
  --aura-green: #34d399;
  --aura-purple: #a78bfa;
  --aura-pink: #f472b6;
  --aura-gradient: linear-gradient(90deg, #38bdf8 0%, #34d399 35%, #a78bfa 70%, #f472b6 100%);

  --ios-blue: #38bdf8;
  --ios-yellow: #f5c242;
  --ios-green: #34c759;
  --ios-red: #ff453a;
  --curve-init-gray: #6e7078;

  --text-main: #ffffff;
  --text-sub: #98989f;
  --text-dim: #636366;

  --font-display: "YinPinHongMeng", "MSJH", "Microsoft JhengHei", sans-serif;
  --font-sans: "MSJH", "Microsoft JhengHei", -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", sans-serif;
  --font-mono: "SF Mono", "JetBrains Mono", "Cascadia Code", Consolas, monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-synthesis: none;
}

button, input, select, textarea {
  font-family: inherit;
}

html, body {
  position: relative;
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  background-color: var(--ios-bg-deep);
  background-image: none;
  color: var(--text-main);
  font-family: var(--font-sans);
  margin: 0 auto;
  overflow-x: hidden;
  padding-bottom: calc(96px + env(safe-area-inset-bottom));
}

#bgTechCanvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  display: block;
  background-color: var(--ios-bg-deep);
}

.view {
  position: relative;
  z-index: 10;
  display: none;
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 20px 20px 32px;
  animation: iosViewFade 0.32s cubic-bezier(0.16, 1, 0.3, 1);
}
.view.active { display: block; }

@keyframes iosViewFade {
  from { opacity: 0; transform: translateY(10px) scale(0.992); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* 顶部 HUD */
.top-hud {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 18px;
  margin-bottom: 18px;
  background: var(--ios-glass-bg);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--ios-border-light);
  border-radius: 16px;
}
.hud-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.3px;
  color: var(--text-main);
}
.hud-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ffffff;
}
.hud-logo {
  display: block;
  width: 104px;
  height: auto;
  opacity: 1;
  align-self: center;
  position: relative;
  top: 5px;
}
.hud-back-btn {
  height: 34px;
  padding: 0 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: var(--text-main);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.hud-back-btn:hover {
  background: rgba(255, 255, 255, 0.15);
}

/* 视图 1：欢迎页 */
.welcome-shell {
  min-height: calc(100dvh - 80px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 44px 28px;
  position: relative;
  background: rgba(24, 24, 27, 0.78);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  border: 1px solid var(--ios-border-light);
  border-radius: 28px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
}
.welcome-tag {
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-sub);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 6px 18px;
  border-radius: 999px;
  margin-bottom: 22px;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.welcome-h1 {
  font-size: clamp(28px, 4.6vw, 46px);
  font-weight: 800;
  line-height: 1.28;
  letter-spacing: -0.5px;
  margin-bottom: 18px;
  color: #ffffff;
}
.welcome-h1 span {
  display: inline-block;
  margin-top: 6px;
  background: var(--aura-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-weight: 800;
  filter: drop-shadow(0 4px 18px rgba(56, 189, 248, 0.22));
}
.welcome-desc {
  color: var(--text-sub);
  font-size: clamp(13.5px, 1.2vw, 15.5px);
  font-weight: 400;
  line-height: 1.75;
  max-width: 560px;
  margin-bottom: 32px;
}
.zzz-btn-primary {
  padding: 15px 38px;
  border-radius: 999px;
  background: #f2f2f7;
  border: none;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35);
  color: #141416;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.4px;
  cursor: pointer;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.zzz-btn-primary:hover {
  transform: translateY(-2px);
  background: #ffffff;
}
.zzz-btn-primary:active {
  transform: translateY(1px) scale(0.985);
}
.welcome-foot {
  margin-top: 22px;
  font-size: 12px;
  color: var(--text-dim);
  letter-spacing: 1px;
}

/* 双入口：iOS / Android */
.enter-split {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
}
.zzz-btn-primary-alt {
  background: var(--ios-track-bg);
  color: #ffffff;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35), inset 0 0 0 1px rgba(255, 255, 255, 0.16);
}
.zzz-btn-primary-alt:hover {
  background: #3a3a3c;
}

/* 安卓二维码区 */
.qr-name-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}
.qr-name-row label {
  font-size: 12px;
  color: var(--text-sub);
}
.qr-preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}
.qr-img {
  width: 220px;
  height: 220px;
  border-radius: 12px;
  background: #ffffff;
  padding: 10px;
}
.eq-param-img {
  width: min(100%, 420px);
  height: auto;
  border-radius: 12px;
  background: #0b0b0d;
}
.eq-profile-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}
@media (max-width: 720px) {
  .eq-profile-grid { grid-template-columns: 1fr; }
}
.eq-profile-card {
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 14px;
  padding: 12px;
  background: var(--ios-glass-inner);
  font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
  text-align: center;
}
.eq-profile-card.recommended { border-color: rgba(52, 211, 153, .65); }
.eq-profile-card.warning { border-color: rgba(255, 69, 58, .75); }
.eq-profile-head {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 4px;
}
.eq-profile-title {
  font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.35;
  color: #fff;
}
.eq-profile-head .tag {
  font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.12);
}
.eq-profile-card.recommended .tag { background: rgba(52,211,153,.22); color: #34d399; }
.eq-profile-card.warning .tag { background: rgba(255,69,58,.2); color: #ff6961; }
.eq-profile-vol {
  font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  text-align: center;
  margin: 5px 0 10px;
}
.eq-profile-card img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  background: #0b0b0d;
}
.eq-profile-meta {
  font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-sub);
  text-align: center;
  line-height: 1.5;
  margin: 8px 0;
}
.eq-profile-actions { display: flex; gap: 8px; }
.eq-profile-actions button {
  flex: 1;
  font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
  font-size: 12px;
  font-weight: 600;
}
.eq-profile-note {
  grid-column: 1 / -1;
  font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
  font-size: 12.5px;
  font-weight: 400;
  color: var(--text-sub);
  line-height: 1.8;
  margin-top: 4px;
  text-align: left;
  background: rgba(255,255,255,.035);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 12px;
  padding: 12px 14px;
}
.eq-profile-note-title {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 7px;
}
.eq-profile-note p { margin: 5px 0; }
.eq-profile-note strong { color: #fff; font-weight: 700; }
.eq-profile-note-choice {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(255,255,255,.08);
  color: var(--text-sub);
}
.qr-disclaimer {
  background: rgba(255, 200, 80, 0.07);
  border: 1px solid rgba(255, 200, 80, 0.22);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 12px;
  font-size: 12px;
  line-height: 1.7;
  color: var(--text-sub);
}
.qr-disclaimer p + p { margin-top: 6px; }
.qr-disclaimer strong { color: #ffd166; font-weight: 600; }
.qr-fit-note {
  padding: 7px 9px;
  border-left: 2px solid #2997ff;
  border-radius: 6px;
  background: rgba(41, 151, 255, .08);
  color: #9fc9ff;
  font-size: 11.5px;
  line-height: 1.6;
}
.qr-loudness-note {
  padding: 7px 9px;
  border-left: 2px solid #ffd166;
  border-radius: 6px;
  background: rgba(255, 209, 102, .08);
  color: #ffe0a3;
  font-size: 11.5px;
  line-height: 1.6;
}

/* 模态对话框 */
.modal-mask {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  z-index: 300;
  align-items: center;
  justify-content: center;
  padding: 18px;
}
.modal-mask.show { display: flex; }
.modal-box {
  width: 100%;
  max-width: 500px;
  max-height: 86vh;
  overflow-y: auto;
  background: #1c1c1e;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.75);
  border-radius: 26px;
  padding: 24px 22px;
}
.modal-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.modal-head h3 {
  font-size: 17px;
  font-weight: 700;
  color: #ffffff;
}
.modal-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: var(--text-sub);
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.modal-body ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 20px;
}
.modal-body li {
  font-size: 13.5px;
  color: var(--text-sub);
  line-height: 1.65;
}
.modal-body li strong { color: #ffffff; font-weight: 700; }
.modal-body li code {
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
  padding: 2px 8px;
  border-radius: 6px;
}
.modal-body li b { color: #ffffff; font-weight: 600; }
.modal-body li.guide-group {
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.035);
}
.modal-body ul.guide-sub {
  display: block;
  margin: 7px 0 2px;
  padding-left: 16px;
  gap: 5px;
  list-style: disc;
}
.modal-body ul.guide-sub li {
  font-size: 12px;
  line-height: 1.55;
  color: var(--text-dim);
}
.modal-body ul.guide-sub li::marker { color: var(--text-dim); }
.modal-verify {
  background: #141416;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 14px 16px;
  margin-bottom: 20px;
}
.verify-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13.5px;
  font-weight: 600;
  margin-bottom: 8px;
}
.badge-checking, .badge-ok, .badge-warn {
  font-size: 12px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.badge-checking { color: var(--text-sub); }
.badge-ok { color: var(--ios-green); border-color: rgba(52, 199, 89, 0.35); }
.badge-warn { color: var(--ios-red); border-color: rgba(255, 69, 58, 0.35); }
.verify-tip { font-size: 12px; color: var(--text-dim); }

/* 搜索框与品牌胶囊过滤栏 */
.search-bar-wrap {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}
.search-box {
  width: 100%;
  background: var(--ios-glass-bg);
  border: 1px solid var(--ios-border-light);
  border-radius: 999px;
  padding: 14px 20px;
  color: var(--text-main);
  font-size: 14px;
  outline: none;
  transition: all 0.2s ease;
}
.search-box::placeholder { color: var(--text-dim); }
.search-box:focus {
  border-color: rgba(255, 255, 255, 0.28);
}
.filter-tabs {
  display: inline-flex;
  align-self: flex-start;
  gap: 4px;
  padding: 4px;
  background: var(--ios-track-bg);
  border-radius: 999px;
  overflow-x: auto;
  max-width: 100%;
}
.filter-btn {
  background: transparent;
  border: none;
  color: var(--text-sub);
  padding: 7px 16px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}
.filter-btn.active {
  background: var(--ios-accent-pill);
  color: #ffffff;
  font-weight: 600;
}

/* 机型卡片网格 */
.device-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
  margin-bottom: 22px;
}
.brand-heading {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 6px 0 0;
  padding-top: 8px;
}
.brand-heading-name {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text-sub);
  text-transform: none;
  white-space: nowrap;
}
.brand-heading-line {
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, rgba(255,255,255,.16), rgba(255,255,255,.02));
}
.device-card {
  background: var(--ios-glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--ios-border-light);
  border-radius: 22px;
  padding: 18px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.device-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.22);
}
.device-card.active {
  border-color: rgba(255, 255, 255, 0.45);
  background: rgba(44, 44, 46, 0.9);
}
.device-card-inner {
  display: grid;
  grid-template-columns: 84px 1fr;
  grid-template-rows: auto auto auto;
  column-gap: 16px;
  align-items: center;
}
.device-icon-box,
.device-img-thumb {
  grid-column: 1;
  grid-row: 1 / span 3;
  width: 84px;
  height: 84px;
  background: transparent !important;
  border: none !important;
  object-fit: contain;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.45));
  transition: transform 0.25s ease;
}
.device-card:hover .device-img-thumb {
  transform: scale(1.05);
}
.device-name {
  grid-column: 2;
  grid-row: 1;
  font-size: 17.5px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 3px;
}
.device-sub {
  grid-column: 2;
  grid-row: 2;
  font-size: 12px;
  color: var(--text-sub);
  margin-bottom: 10px;
}
.device-pills {
  grid-column: 2;
  grid-row: 3;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.device-pill {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-sub);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 3px 10px;
  border-radius: 999px;
}

/* 音效抽屉面板 */
.drawer-panel {
  display: block;
  background: var(--ios-glass-bg);
  border: 1px solid var(--ios-border-light);
  border-radius: 26px;
  margin-top: 0px;
  padding: 0 18px;
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transform: translateY(-8px) scale(0.99);
  pointer-events: none;
  transition: 
    max-height 0.48s cubic-bezier(0.16, 1, 0.3, 1),
    opacity 0.32s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.40s cubic-bezier(0.16, 1, 0.3, 1),
    padding 0.40s cubic-bezier(0.16, 1, 0.3, 1),
    margin-top 0.40s cubic-bezier(0.16, 1, 0.3, 1);
}
.drawer-panel.is-open {
  max-height: 2200px;
  opacity: 1;
  padding: 22px 18px;
  margin-top: 16px;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}
.drawer-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 16.5px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 16px;
}
.drawer-title::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 18px;
  border-radius: 4px;
  background: #ffffff;
}

.ladder-style-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}
.ladder-mode-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
  min-height: 148px;
  background: var(--ios-glass-card);
  border: 1px solid var(--ios-border-light);
  border-radius: 20px;
  padding: 18px;
  cursor: pointer;
  overflow: hidden;
  transition: all 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}
.ladder-mode-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.24);
}
/* 默认状态（桌面端）：偏小、偏暗、黑白去色滤镜 */
.ladder-mode-bg-img {
  position: absolute;
  right: -5%;
  top: -15%;
  height: 125%;
  width: 55%;
  object-fit: contain;
  object-position: center;

  /* 关键：默认黑白去色 + 压暗 + 略微缩小 */
  filter: grayscale(100%) brightness(0.65) contrast(1.1);
  opacity: 0.22;
  transform: scale(0.92);

  pointer-events: none;
  z-index: 1;
  -webkit-mask-image: radial-gradient(ellipse at center, black 35%, transparent 82%);
  mask-image: radial-gradient(ellipse at center, black 35%, transparent 82%);
  transition: all 0.38s cubic-bezier(0.16, 1, 0.3, 1);
}
/* 鼠标悬停时（桌面端）：放大、恢复全彩、提升亮度 */
.ladder-mode-card:hover .ladder-mode-bg-img {
  filter: grayscale(0%) brightness(1.0) contrast(1.0);
  opacity: 0.42;
  transform: scale(1.04);
}
/* 移动端/触屏适配：手机端默认直接显示全彩，不依赖 Hover */
@media (hover: none), (max-width: 768px) {
  .ladder-mode-bg-img {
    filter: grayscale(0%) brightness(0.9) contrast(1.0);
    opacity: 0.32;
    transform: scale(1.0);
  }
}
.ladder-mode-info {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-width: 78%;
}
.ladder-mode-info h4 {
  font-size: 16px;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.35;
}
.ladder-mode-info p {
  font-size: 12px;
  color: var(--text-sub);
  line-height: 1.5;
}
.ladder-mode-right {
  position: relative;
  z-index: 2;
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
}

/* 推荐标识徽章：采用四色流光渐变 */
.ladder-badge-pill {
  flex-shrink: 0;
  font-size: 11.5px;
  font-weight: 700;
  color: #0b0d14 !important;
  background: var(--aura-gradient) !important;
  border: 1px solid rgba(255, 255, 255, 0.45);
  padding: 6px 14px;
  border-radius: 999px;
  box-shadow: 0 2px 10px rgba(56, 189, 248, 0.3);
}

.ladder-mode-action {
  flex: 1;
  text-align: center;
  font-size: 14px;
  font-weight: 600;
  color: #ffffff;
  background: var(--ios-accent-pill);
  border: none;
  padding: 9px 18px;
  border-radius: 999px;
  transition: all 0.2s ease;
}
.ladder-mode-card:hover .ladder-mode-action {
  background: #7c7c80;
}

/* 约克大学 BRIR 混响折叠卡 */
.ir-accordion {
  background: #161618;
  border: 1px solid var(--ios-border-light);
  border-radius: 18px;
  overflow: hidden;
}
.ir-accordion-header {
  padding: 15px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
}
.ir-accordion-header h4 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 700;
  color: #ffffff;
}
.ir-accordion-header h4::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #a78bfa;
}
.ir-accordion-body {
  display: none;
  padding: 0 18px 16px;
  font-size: 12.5px;
  color: var(--text-sub);
  line-height: 1.6;
}
.ir-accordion.open .ir-accordion-body { display: block; }
.ir-btn-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.ir-dl-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-main);
  padding: 9px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  transition: all 0.2s;
}
.ir-dl-btn:hover {
  background: rgba(255, 255, 255, 0.14);
}

/* 视图 3：音效详情 */
.tabs-scroll-bar {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
  margin-bottom: 16px;
  scrollbar-width: none;
}
.tabs-scroll-bar::-webkit-scrollbar { display: none; }
.tab-pill {
  flex-shrink: 0;
  background: var(--ios-track-bg);
  border: 1px solid var(--ios-border-light);
  color: var(--text-sub);
  padding: 8px 18px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}
.tab-pill.active {
  background: var(--ios-accent-pill);
  color: #ffffff;
  font-weight: 600;
}

.panel-card {
  background: var(--ios-glass-bg);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--ios-border-light);
  border-radius: 24px;
  padding: 20px;
  margin-bottom: 18px;
}
.panel-card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 14px;
}
.panel-card-head h3 {
  font-size: 17px;
  font-weight: 700;
  color: #ffffff;
}

.specs-matrix-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: #141416;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 18px;
  overflow: hidden;
  margin-bottom: 16px;
}
.spec-cell {
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  border-right: 1px solid rgba(255, 255, 255, 0.05);
}
.spec-cell:nth-child(2n) { border-right: none; }
.spec-cell:nth-child(n+3) { border-bottom: none; }
.spec-val {
  font-family: var(--font-sans);
  font-size: 22px;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.2;
}
.spec-val small {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-sub);
  margin-left: 3px;
}
.spec-lbl {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--text-dim);
  letter-spacing: 0.8px;
  margin-top: 4px;
  text-transform: uppercase;
}

.canvas-viewport {
  position: relative;
  width: 100%;
  aspect-ratio: 2 / 1;
  background: #141416;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 12px;
}
.canvas-mode-bg {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(1);
  height: 80%;
  width: 60%;
  object-fit: contain;
  object-position: center;
  opacity: 0.06;
  pointer-events: none;
  z-index: 1;
  -webkit-mask-image: radial-gradient(ellipse at center, rgba(0,0,0,1) 10%, transparent 70%);
  mask-image: radial-gradient(ellipse at center, rgba(0,0,0,1) 10%, transparent 70%);
  /* 升级为丝滑的透明度与微缩放过渡 */
  transition: opacity 0.36s cubic-bezier(0.22, 1, 0.36, 1), transform 0.36s cubic-bezier(0.22, 1, 0.36, 1);
}

/* 切换底图时的淡出过渡态 */
.canvas-mode-bg.bg-switching {
  opacity: 0 !important;
  transform: translate(-50%, -50%) scale(0.95);
}
.canvas-viewport.is-loading::before {
  content: '曲线数据载入中...';
  position: absolute;
  inset: 0;
  background: rgba(20, 20, 22, 0.72);
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-sub);
}
#fr-canvas {
  position: relative;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 2;
}

/* 交互式图例栏 */
.legend-bar {
  display: flex;
  justify-content: center;
  gap: 10px;
  font-size: 12px;
  color: var(--text-sub);
  flex-wrap: wrap;
}
.legend-bar > span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 13px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  cursor: pointer;
  transition: all 0.2s ease;
}
.legend-bar > span:hover {
  background: rgba(255, 255, 255, 0.1);
}
.legend-bar > span.legend-off {
  opacity: 0.35;
  text-decoration: line-through;
}
.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}
.dot-init { background: #6e7078; }
.dot-target { background: #ffffff; box-shadow: 0 0 6px rgba(255, 255, 255, 0.5); }
.dot-fitted { background: var(--aura-gradient) !important; box-shadow: 0 0 6px rgba(168, 85, 247, 0.45); }

/* A/B 切换分段胶囊控件 */
.ab-rack {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: var(--ios-track-bg);
  padding: 4px;
  border-radius: 999px;
  gap: 4px;
  margin-bottom: 14px;
}
.ab-btn {
  background: transparent;
  border: none;
  border-radius: 999px;
  padding: 10px 14px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
  color: var(--text-sub);
}
.ab-btn.active {
  background: var(--ios-accent-pill);
  color: #ffffff;
}
.ab-btn.is-loading-audio {
  opacity: 0.5;
  pointer-events: none;
}
.ab-btn strong {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: inherit;
}
.ab-btn span {
  display: none;
}

.player-dock-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 8px;
}
.play-main-btn {
  height: 42px;
  padding: 0 24px;
  border-radius: 999px;
  background: #f2f2f7;
  border: none;
  color: #141416;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}
.play-main-btn:disabled,
.play-main-btn.is-loading-audio {
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.5);
  cursor: wait;
}
.dock-seek-bar {
  flex: 1;
  height: 6px;
  accent-color: #ffffff;
  cursor: pointer;
}
.dock-seek-bar:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.time-mono {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-sub);
  white-space: nowrap;
}

/* 底部下载按钮：专属四色流光渐变 */
#btn-download-json {
  background: var(--aura-gradient) !important;
  color: #0b0d14 !important;
  font-weight: 700;
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: 0 8px 24px rgba(56, 189, 248, 0.25), 0 2px 8px rgba(244, 114, 182, 0.18);
}
#btn-download-json:hover {
  transform: translateY(-2px);
  filter: brightness(1.06);
}

.sec-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #ffffff;
  padding: 9px 18px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
}

/* 底部悬浮 Dock */
.ios-bottom-dock {
  position: fixed;
  left: 50%;
  bottom: calc(12px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  width: calc(100% - 28px);
  max-width: 520px;
  height: 64px;
  background: rgba(24, 24, 26, 0.85);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.65);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  align-items: center;
  padding: 0 10px;
  z-index: 200;
  transition: opacity 0.28s ease, transform 0.28s ease;
}
.ios-bottom-dock.dock-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 24px);
}
.dock-tab-item {
  background: none;
  border: none;
  color: var(--text-dim);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  height: 100%;
  cursor: pointer;
}
.dock-tab-item svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
}
.dock-tab-item span {
  font-size: 11px;
  font-weight: 500;
}
.dock-tab-item.active {
  color: #ffffff;
}

@media (max-width: 768px) {
  .view { padding: 12px 14px 28px; }
  .top-hud { padding: 11px 14px; margin-bottom: 14px; border-radius: 14px; }
  .hud-brand { font-size: 14px; }
  .hud-logo { width: 84px; top: 4px; }
  .welcome-shell { min-height: calc(100dvh - 48px); padding: 28px 20px; border-radius: 24px; }
  .welcome-h1 { font-size: 26px; }
  .zzz-btn-primary { width: 100%; padding: 14px 20px; font-size: 15.5px; }
  .device-grid { grid-template-columns: 1fr; gap: 12px; }
  .ladder-style-grid { grid-template-columns: 1fr; gap: 12px; }
  .canvas-viewport { aspect-ratio: 16 / 10; }
  .player-dock-row { flex-wrap: wrap; gap: 12px; }
  .play-main-btn { width: 100%; height: 42px; }
}

/* ==========================================================================
   字体层级：标题/大数字用 YinPinHongMeng（不再加粗，靠颜色与字号分层）
   正文/次级文字用 MSJH 300 / 400 / 700 三档
   ========================================================================== */
h1, h2, h3, h4,
.welcome-h1,
.hud-brand,
.drawer-title,
.panel-card-head h3,
.modal-head h3,
.admin-head h1,
.spec-val,
.ladder-mode-info h4,
.ir-accordion-header h4 {
  font-family: var(--font-display);
  font-weight: 400;
}

.welcome-desc,
.welcome-foot,
.admin-hint,
.verify-tip,
.spec-lbl,
.qr-disclaimer {
  font-weight: 300;
}

.welcome-h1 span {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: 0.5px;
}

.spec-val small {
  font-weight: 400;
}
