/* ============================================================
   v5 本地修订（Alder，2026-11-04）—— 按 2026-11-03 的 12 条批注新增的样式
   只新增类名（v5- 前缀），不改动原有样式定义。
   ============================================================ */

/* ---------- 通用：回到顶部 ---------- */
.v5-topbtn {
  position: fixed; right: 18px; bottom: 84px; z-index: 60;
  width: 48px; height: 48px; border-radius: 999px;
  background: var(--yellow); color: var(--black);
  border: 3px solid var(--black); box-shadow: 3px 3px 0 var(--red);
  font-size: 20px; font-weight: 900; cursor: pointer;
  opacity: 0; pointer-events: none; transition: opacity .2s;
}
.v5-topbtn.show { opacity: 1; pointer-events: auto; }

/* ---------- 通用卡片 ---------- */
.v5-card {
  margin: 18px 0; padding: 16px 18px; border-radius: 16px;
  background: var(--panel); border: 2px solid var(--cyan);
}
.v5-card > h3, .v5-card > h4 { margin: 2px 0 10px; color: var(--cyan); }
.v5-card .v5-note { color: var(--gray); font-size: 14px; }
.v5-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--panel2); color: var(--white);
  border: 2px solid var(--line); border-radius: 999px;
  padding: 7px 14px; font-weight: 800; font-size: 14px; cursor: pointer;
  font-family: var(--font);
}
.v5-btn:hover { border-color: var(--yellow); }
.v5-btn.on { background: var(--yellow); color: var(--black); border-color: var(--yellow); }
.v5-btn.primary { background: var(--yellow); color: var(--black); border-color: var(--yellow); }

/* ---------- 第一章：采样交互台 ---------- */
.v5-pads { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 12px 0; }
.v5-pad {
  aspect-ratio: 1.35; border-radius: 12px; border: 2px solid var(--line);
  background: var(--panel2); color: var(--white); cursor: pointer;
  font-family: var(--font); font-weight: 900; font-size: 15px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
}
.v5-pad small { color: var(--gray); font-weight: 700; font-size: 12px; }
.v5-pad:hover { border-color: var(--cyan); }
.v5-pad.hit { background: var(--yellow); color: var(--black); border-color: var(--yellow); }
.v5-pad.hit small { color: var(--black); }
.v5-wave { width: 100%; height: 84px; display: block; background: #0e0e12; border: 2px solid var(--line); border-radius: 10px; }
.v5-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 10px 0; }
.v5-status { color: var(--yellow); font-weight: 800; font-size: 14px; min-height: 1.4em; }

/* ---------- 第一章：工程动态图 ---------- */
.v5-banks { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.v5-bankpads { display: grid; grid-template-columns: repeat(8, 1fr); gap: 6px; margin: 10px 0; }
.v5-bpad {
  aspect-ratio: 1.5; border-radius: 8px; border: 2px solid var(--line);
  background: var(--panel2); color: var(--gray); font-size: 12px; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
}
.v5-bpad.filled { color: var(--black); font-weight: 900; }
.v5-seqchips { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0; }
.v5-seqsteps { display: grid; grid-template-columns: repeat(16, 1fr); gap: 4px; margin: 8px 0; }
.v5-seqstep { height: 22px; border-radius: 5px; background: var(--panel2); border: 1px solid var(--line); }
.v5-seqstep.on-kick { background: var(--red); }
.v5-seqstep.on-snare { background: var(--yellow); }
.v5-seqstep.on-hat { background: var(--cyan); }

/* ---------- 速查页：目录与侧栏 ---------- */
.v5-toc { margin: 14px 0; padding: 10px 16px; background: var(--panel); border: 2px solid var(--line); border-radius: 14px; }
.v5-toc summary { cursor: pointer; font-weight: 900; color: var(--yellow); }
.v5-toc ul { margin: 8px 0 4px; padding-left: 20px; }
.v5-toc li { padding: 3px 0; }
.v5-sidenav {
  display: none; position: fixed; left: 10px; top: 110px; z-index: 40;
  width: 176px; padding: 10px; background: rgba(22,22,27,.96);
  border: 2px solid var(--line); border-radius: 14px;
}
.v5-sidenav a { display: block; color: var(--white); font-size: 13.5px; font-weight: 700; padding: 5px 8px; border-radius: 8px; }
.v5-sidenav a:hover { background: var(--panel2); text-decoration: none; color: var(--yellow); }
@media (min-width: 1500px) { .v5-sidenav { display: block; } }

/* ---------- 速查页：面板总览一屏 + 编号点选 ---------- */
.v5-figtools { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 10px; align-items: center; }
#fig-overview.v5-fit svg { max-height: 76vh; width: auto; max-width: 100%; margin: 0 auto; }
#fig-overview .marker { cursor: pointer; }
#fig-overview .marker.v5-sel circle { fill: var(--yellow); stroke: var(--white); }
#fig-overview .marker.v5-sel text { fill: var(--black); }
.v5-markerinfo {
  display: none; margin: 10px 0 4px; padding: 12px 16px;
  background: #18170D; border: 2px dashed var(--yellow); border-radius: 14px;
}
.v5-markerinfo.show { display: block; }
.v5-markerinfo .v5-mi-head { font-weight: 900; font-size: 18px; margin-bottom: 4px; }
tr.v5-hl td { background: rgba(255, 229, 0, .16) !important; }

/* ---------- 速查页：快捷键卡 / 接法卡 ---------- */
.v5-keys { columns: 2; column-gap: 26px; margin: 6px 0; padding-left: 0; list-style: none; }
.v5-keys li { break-inside: avoid; padding: 5px 0; border-bottom: 1px dashed var(--line); }
@media (max-width: 640px) { .v5-keys { columns: 1; } }
.v5-conn { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; margin: 12px 0; }
.v5-conn .v5-conn-item { background: var(--panel2); border: 2px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.v5-conn .v5-conn-item b { color: var(--yellow); display: block; margin-bottom: 3px; }
.v5-conn .v5-conn-item span { color: var(--gray); font-size: 14px; }

/* ---------- 术语表：搜索 ---------- */
.v5-gsearch { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 14px 0 4px; }
.v5-gsearch input {
  flex: 1 1 260px; padding: 10px 14px; border-radius: 999px;
  border: 2px solid var(--line); background: var(--panel2); color: var(--white);
  font-size: 16px; font-family: var(--font);
}
.v5-gsearch input:focus { outline: none; border-color: var(--yellow); }
.v5-gcount { color: var(--gray); font-size: 14px; font-weight: 700; }

/* ---------- 实验室：网页内横版播放器 ---------- */
.v5-player {
  margin: 14px 0; padding: 14px 16px; border-radius: 16px;
  background: #101014; border: 2px solid var(--yellow);
}
.v5-player .v5-p-head { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 10px; }
.v5-player .v5-p-title { font-weight: 900; font-size: 17px; }
.v5-player .v5-p-title small { color: var(--gray); font-weight: 700; margin-left: 8px; font-size: 13px; }
.v5-play {
  width: 52px; height: 52px; border-radius: 999px; flex: none;
  background: var(--yellow); color: var(--black); border: 3px solid var(--black);
  box-shadow: 3px 3px 0 var(--red); font-size: 20px; font-weight: 900; cursor: pointer;
}
.v5-player input[type="range"] { accent-color: var(--yellow); }
.v5-track { display: grid; grid-template-columns: 86px 1fr; gap: 10px; align-items: center; margin: 5px 0; }
.v5-track .v5-tname { font-weight: 800; font-size: 14px; color: var(--white); text-align: right; }
.v5-track .v5-tname small { display: block; color: var(--gray); font-weight: 700; font-size: 11px; }
.v5-cells { display: grid; gap: 3px; }
.v5-cell { height: 26px; border-radius: 5px; background: #1D1D24; border: 1px solid #2A2A33; position: relative; }
.v5-cell.beat { border-color: #3D3D49; }
.v5-cell.now { outline: 2px solid var(--white); outline-offset: -1px; }
.v5-ev {
  position: absolute; top: 3px; bottom: 3px; border-radius: 4px;
  background: var(--cyan); opacity: .92;
}
.v5-ev.kick { background: var(--red); }
.v5-ev.snare, .v5-ev.clap { background: var(--yellow); }
.v5-ev.hat, .v5-ev.shaker, .v5-ev.ride { background: var(--cyan); }
.v5-ev.bass { background: #7CFC00; }
.v5-ev.chord { background: #C792FF; }
.v5-ev.vocal { background: #FF9DE2; }
.v5-piano { display: flex; margin: 10px 0 2px; height: 74px; position: relative; }
.v5-wkey {
  flex: 1; background: #EDEDF2; border: 1px solid #999; border-radius: 0 0 5px 5px;
  position: relative; z-index: 1;
}
.v5-wkey.lit { background: var(--yellow); }
.v5-bkey {
  position: absolute; top: 0; height: 44px; background: #17171C; border: 1px solid #000;
  border-radius: 0 0 4px 4px; z-index: 2; transform: translateX(-50%);
}
.v5-bkey.lit { background: var(--red); }
.v5-chordname { font-weight: 900; color: var(--yellow); min-height: 1.5em; }

/* 实验室版式：播放器已横版化，左右栏改为上下排，内容更宽 */
.lab-cols.v5-stack { grid-template-columns: 1fr; }
.v5-oldvideo { margin: 6px 0; }
.v5-oldvideo summary { cursor: pointer; color: var(--gray); font-weight: 800; font-size: 14px; }
.v5-oldvideo video.local-video { max-width: 340px; }

/* 参数标签可点解释 */
.lp.v5-lp { cursor: pointer; border-bottom: 2px dotted var(--cyan); }
.v5-lpbox {
  display: none; margin: 8px 0; padding: 10px 14px; border-radius: 12px;
  background: var(--panel2); border: 2px solid var(--cyan); font-size: 15px;
}
.v5-lpbox.show { display: block; }
.v5-lpbox b { color: var(--cyan); }

/* 动手步骤跟练清单 */
.v5-do { margin: 0 0 16px; padding: 14px 16px; border-radius: 14px; background: #18170D; border: 2px dashed var(--yellow); }
.v5-do h4 { margin: 2px 0 8px; color: var(--yellow); }
.v5-do ol { margin: 6px 0; padding-left: 6px; list-style: none; }
.v5-do li { padding: 6px 0; border-bottom: 1px dashed var(--line); }
.v5-do li:last-child { border-bottom: 0; }
.v5-do label { cursor: pointer; display: flex; gap: 9px; align-items: flex-start; }
.v5-do input[type="checkbox"] { transform: scale(1.3); margin-top: 4px; accent-color: var(--yellow); flex: none; }
.v5-do .done { color: var(--gray); text-decoration: line-through; }
.v5-do .v5-do-pos { color: var(--cyan); font-weight: 700; }
.v5-do .v5-prog { color: var(--gray); font-size: 13.5px; font-weight: 700; }
