/* ============================================================
   堂吉诃德 · 哔哔啵啵声线器
   纸感 / 印章 / 骑士故事书 —— 不用外部图片，全部 CSS + SVG
   ============================================================ */
:root {
  --paper: #F2E6D0;
  --paper-2: #FBF3E3;
  --paper-3: #FFF9EC;
  --ink: #241A18;
  --ink-2: #55423A;
  --crimson: #A62B3A;
  --crimson-2: #7E1F2C;
  --gold: #D6A243;
  --gold-2: #F0C97A;
  --navy: #1C2438;
  --mint: #8FE3C0;
  --line: rgba(36, 26, 24, .16);
  --line-strong: rgba(36, 26, 24, .34);
  --sans: "Noto Sans SC", "PingFang SC", "Hiragino Sans GB", "Source Han Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  --serif: "Noto Serif SC", "Songti SC", "Source Han Serif SC", Georgia, "Times New Roman", serif;
  --mono: "JetBrains Mono", "SFMono-Regular", "Cascadia Code", "Roboto Mono", ui-monospace, monospace;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(1100px 600px at 12% -4%, rgba(214, 162, 67, .14), transparent 60%),
    radial-gradient(900px 520px at 92% 8%, rgba(166, 43, 58, .07), transparent 62%),
    var(--paper);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}
::selection { background: var(--crimson); color: var(--paper-3); }
a { color: var(--crimson); text-underline-offset: 2px; }
button, input, textarea { font: inherit; }
button { color: inherit; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

.grain {
  position: fixed;
  inset: 0;
  z-index: 40;
  pointer-events: none;
  opacity: .22;
  background-image: radial-gradient(rgba(36, 26, 24, .55) .55px, transparent .7px);
  background-size: 5px 5px;
  mix-blend-mode: multiply;
}

.shell {
  position: relative;
  z-index: 1;
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: 24px 22px 46px;
}

/* ---------- 顶栏 ---------- */
.topline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line-strong);
  font: 500 9px/1.3 var(--mono);
  letter-spacing: .19em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.topline b { color: var(--crimson); font-weight: 700; }
.topline-right { text-align: right; }

/* ---------- 标题区 ---------- */
.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 270px;
  align-items: end;
  gap: 20px;
  padding: 30px 0 26px;
}
.eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  font: 600 9px/1.3 var(--mono);
  letter-spacing: .17em;
  color: var(--ink-2);
}
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--crimson); flex: none; }
.hero h1 {
  margin: 12px 0 0;
  font-size: clamp(58px, 9.6vw, 112px);
  line-height: .86;
  font-weight: 900;
  letter-spacing: -.045em;
  color: var(--ink);
}
.hero-en {
  margin-top: 13px;
  font-family: var(--serif);
  font-size: clamp(13px, 1.7vw, 18px);
  letter-spacing: .33em;
  color: var(--crimson);
}
.tagline {
  margin: 15px 0 0;
  font-size: 15px;
  color: var(--ink-2);
  letter-spacing: .01em;
}
.tagline b {
  color: var(--ink);
  background: linear-gradient(transparent 63%, var(--gold-2) 63%);
  padding: 0 .08em;
}

.hero-art {
  position: relative;
  height: 226px;
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
}
.windmill {
  width: 208px;
  height: auto;
  color: var(--ink);
  opacity: .88;
  margin-bottom: 2px;
}
.windmill-line {
  fill: none;
  stroke: currentColor;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.windmill .spars { stroke-width: 1.3; opacity: .42; }
.windmill .ground { opacity: .26; }
.windmill .blades {
  transform-box: view-box;
  transform-origin: 100px 114px;
  animation: spin 28s linear infinite;
}
.seal {
  position: absolute;
  right: 2px;
  bottom: 5px;
  width: 80px;
  height: 80px;
  display: grid;
  grid-template-rows: 1fr auto;
  place-items: center;
  padding: 9px 0 7px;
  border: 2px solid var(--crimson);
  border-radius: 4px;
  color: var(--crimson);
  background: rgba(242, 230, 208, .82);
  transform: rotate(-5deg);
  box-shadow: 0 4px 0 rgba(166, 43, 58, .16);
}
.seal span { font-family: var(--serif); font-size: 11px; letter-spacing: .16em; line-height: 1; }
.seal strong { font: 700 27px/1 var(--mono); letter-spacing: -.05em; }

/* ---------- 分隔线 ---------- */
.rule {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 22px;
  color: var(--ink-2);
}
.rule span { flex: 1; height: 1px; background: var(--line-strong); }
.rule i {
  font: 500 8px/1 var(--mono);
  font-style: normal;
  letter-spacing: .2em;
  white-space: nowrap;
}

/* ---------- 主网格 ---------- */
.grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(300px, .85fr);
  gap: 22px;
  align-items: start;
}
.card {
  position: relative;
  background: var(--paper-2);
  border: 2px solid var(--ink);
  border-radius: 18px;
  box-shadow: 6px 8px 0 rgba(36, 26, 24, .13);
  padding: 22px 24px;
}
.card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 15px;
}
.kicker {
  font: 700 8px/1.3 var(--mono);
  letter-spacing: .21em;
  color: var(--crimson);
}
.card-head h2 {
  margin: 5px 0 0;
  font-family: var(--serif);
  font-size: 26px;
  line-height: 1.15;
  letter-spacing: .02em;
  font-weight: 800;
}
.card-num {
  flex: none;
  padding: 3px 7px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font: 500 9px/1.2 var(--mono);
  letter-spacing: .1em;
  color: var(--ink-2);
}

/* ---------- 输入 ---------- */
.field-label {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 8px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .03em;
}
.hint { font-size: 10px; font-weight: 400; color: var(--ink-2); }
.textarea-wrap { position: relative; }
textarea {
  display: block;
  width: 100%;
  min-height: 118px;
  max-height: 280px;
  resize: vertical;
  padding: 14px 16px 30px;
  border: 2px solid var(--ink);
  border-radius: 12px;
  background: var(--paper-3);
  color: var(--ink);
  font-size: 17px;
  line-height: 1.65;
  letter-spacing: .01em;
  box-shadow: inset 0 2px 0 rgba(36, 26, 24, .05);
  transition: border-color .15s, box-shadow .15s;
}
textarea:focus {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
  border-color: var(--crimson);
}
textarea::placeholder { color: rgba(85, 66, 58, .55); }
.count {
  position: absolute;
  right: 11px;
  bottom: 8px;
  padding: 1px 4px;
  font: 500 9px/1.4 var(--mono);
  color: var(--ink-2);
  background: var(--paper-3);
  border-radius: 3px;
  pointer-events: none;
}

/* ---------- 示例 ---------- */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 12px 0 18px;
}
.chip {
  padding: 6px 11px;
  border: 1.5px solid var(--line-strong);
  border-radius: 999px;
  background: transparent;
  color: var(--ink-2);
  font-size: 12px;
  line-height: 1.3;
  cursor: pointer;
  transition: background .15s, border-color .15s, color .15s, transform .08s;
}
.chip:hover { background: var(--gold-2); border-color: var(--ink); color: var(--ink); }
.chip:active { transform: translateY(1px); }

/* ---------- 滑杆 ---------- */
.controls {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 15px;
  margin: 4px 0 15px;
}
.control-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 4px;
}
.control-top label { font-size: 11px; font-weight: 800; letter-spacing: .04em; }
.control-top output {
  padding: 1px 5px;
  border-radius: 3px;
  background: rgba(166, 43, 58, .08);
  color: var(--crimson);
  font: 600 9px/1.5 var(--mono);
}
input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  display: block;
  width: 100%;
  height: 26px;
  margin: 0;
  background: transparent;
  cursor: pointer;
}
input[type="range"]::-webkit-slider-runnable-track {
  height: 6px;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: #E5D4B5;
  box-shadow: inset 0 1px 0 rgba(36, 26, 24, .12);
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  margin-top: -7.5px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: var(--crimson);
  box-shadow: 0 2px 0 rgba(36, 26, 24, .22);
}
input[type="range"]::-moz-range-track {
  height: 6px;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: #E5D4B5;
}
input[type="range"]::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: var(--crimson);
}
input[type="range"]:active::-webkit-slider-thumb { background: var(--crimson-2); transform: scale(1.06); }
.scale {
  display: flex;
  justify-content: space-between;
  margin-top: -2px;
  font: 500 8px/1.3 var(--mono);
  letter-spacing: .08em;
  color: var(--ink-2);
}

/* ---------- 开关 ---------- */
.switch-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px 0;
  border-top: 1px dashed var(--line-strong);
  border-bottom: 1px dashed var(--line-strong);
  margin-bottom: 15px;
}
.switch {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  cursor: pointer;
  user-select: none;
}
.switch input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}
.track {
  position: relative;
  flex: none;
  width: 38px;
  height: 22px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: #E5D4B5;
  transition: background .18s;
}
.thumb {
  position: absolute;
  left: 2px;
  top: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--ink);
  transition: transform .18s, background .18s;
}
.switch input:checked + .track { background: var(--crimson); }
.switch input:checked + .track .thumb { transform: translateX(16px); background: var(--paper-3); }
.switch input:focus-visible + .track { outline: 3px solid var(--gold); outline-offset: 2px; }
.switch-label { font-size: 11px; font-weight: 800; line-height: 1.35; }
.switch-label small { display: block; font-size: 8px; font-weight: 400; color: var(--ink-2); letter-spacing: .02em; }
.switch-note { font: 500 8px/1.3 var(--mono); letter-spacing: .14em; color: var(--ink-2); }

/* ---------- 按钮 ---------- */
.actions {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 10px;
}
.btn {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 16px;
  border: 2px solid var(--ink);
  border-radius: 12px;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: .04em;
  cursor: pointer;
  box-shadow: 0 4px 0 var(--ink);
  transition: transform .08s, box-shadow .08s, background .15s, opacity .15s;
}
.btn svg { width: 17px; height: 17px; display: block; }
.btn-primary { background: var(--crimson); color: #FFF7E9; }
.btn-primary svg { fill: currentColor; }
.btn-primary:hover { background: var(--crimson-2); }
.btn-secondary { background: transparent; color: var(--ink); }
.btn-secondary svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.btn-secondary:hover { background: var(--gold-2); }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--ink); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: 0 2px 0 var(--ink); }
.under-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 10px 0 16px;
  font-size: 10px;
  color: var(--ink-2);
}
#status { letter-spacing: .02em; }
.linkbtn {
  padding: 0;
  border: 0;
  border-bottom: 1px solid currentColor;
  background: none;
  color: var(--ink-2);
  font-size: 10px;
  line-height: 1.4;
  cursor: pointer;
}
.linkbtn:hover { color: var(--crimson); }
.linkbtn:disabled { opacity: .45; cursor: not-allowed; border-bottom-color: transparent; }

/* ---------- 波形 ---------- */
.wave-card {
  padding: 11px 12px 9px;
  border: 2px solid var(--ink);
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .035), transparent 55%),
    var(--navy);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .05);
}
.wave-head, .wave-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  font: 500 8px/1.4 var(--mono);
  letter-spacing: .16em;
}
.wave-head { color: var(--gold-2); }
.wave-head span:last-child { color: rgba(255, 255, 255, .64); letter-spacing: .08em; }
#wave {
  display: block;
  width: 100%;
  height: 124px;
  margin: 7px 0 5px;
}
.wave-foot { color: rgba(255, 255, 255, .6); letter-spacing: .08em; }
.wave-foot span:last-child { color: rgba(143, 227, 192, .72); }

/* ---------- 声线档案 ---------- */
.dossier { position: sticky; top: 18px; }
.portrait {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 3px 0 14px;
  border-bottom: 1px solid var(--line);
}
.portrait svg {
  flex: none;
  width: 92px;
  height: auto;
  filter: drop-shadow(0 3px 0 rgba(36, 26, 24, .14));
}
.portrait-cap {
  font: 500 7px/1.6 var(--mono);
  letter-spacing: .15em;
  color: var(--ink-2);
}
.name-block { padding: 14px 0 12px; }
.name-block h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: 30px;
  line-height: 1.1;
  letter-spacing: .02em;
}
.name-en {
  margin-top: 4px;
  font: 600 8px/1.4 var(--mono);
  letter-spacing: .26em;
  color: var(--crimson);
}
.name-block p {
  margin: 8px 0 0;
  font-size: 10px;
  line-height: 1.65;
  color: var(--ink-2);
}
.name-block p span { font-size: 9px; opacity: .85; }

.section-mini {
  padding: 11px 0;
  border-top: 1px dashed var(--line-strong);
}
.mini-head {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
  font: 600 7.5px/1.4 var(--mono);
  letter-spacing: .15em;
  color: var(--ink-2);
}
.mini-head span:first-child { color: var(--crimson); }
.stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px 12px;
}
.stat { display: flex; align-items: baseline; gap: 3px; flex-wrap: wrap; }
.stat span { width: 100%; font-size: 8.5px; line-height: 1.3; letter-spacing: .04em; color: var(--ink-2); }
.stat b { font: 600 20px/1 var(--mono); letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.stat i { font: 400 8px/1 var(--mono); font-style: normal; color: var(--ink-2); }
.formants {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  margin-top: 9px;
  font: 500 8px/1.4 var(--mono);
  color: var(--ink-2);
}
.formants span {
  padding: 2px 5px;
  border: 1px solid var(--line-strong);
  border-radius: 3px;
}
.formants span:last-child { border: 0; padding-left: 0; }

.bands {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 5px;
  height: 82px;
  align-items: end;
  padding-bottom: 1px;
  border-bottom: 1px solid var(--line-strong);
}
.band {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  height: 100%;
  gap: 2px;
}
.band i {
  width: 100%;
  height: var(--h);
  min-height: 3px;
  border: 1px solid var(--ink);
  border-radius: 3px 3px 0 0;
  background: linear-gradient(180deg, var(--gold) 0%, var(--crimson) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25);
}
.band span { font: 600 8px/1 var(--mono); color: var(--ink-2); }
.band em { font-style: normal; font-size: 6.5px; line-height: 1.2; color: var(--ink-2); white-space: nowrap; }

.mapping { margin: 0; }
.mapping div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 5px 0;
  border-bottom: 1px dotted var(--line-strong);
}
.mapping div:last-child { border-bottom: 0; padding-bottom: 0; }
.mapping dt { font-size: 9px; color: var(--ink-2); }
.mapping dd { margin: 0; font: 500 9px/1.5 var(--mono); text-align: right; letter-spacing: -.01em; }
.source {
  margin: 10px 0 0;
  padding-top: 10px;
  border-top: 1px dashed var(--line-strong);
  font-size: 8px;
  line-height: 1.65;
  color: var(--ink-2);
}

/* ---------- 原理 ---------- */
.notes { margin-top: 22px; padding: 26px 28px 22px; }
.notes-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 18px;
}
.notes-head h2 {
  margin: 5px 0 0;
  font-family: var(--serif);
  font-size: 30px;
  line-height: 1.15;
  letter-spacing: .01em;
}
.notes-eq {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 32px;
  padding-bottom: 3px;
}
.notes-eq i {
  display: block;
  width: 5px;
  border-radius: 2px;
  background: var(--crimson);
  animation: eq 1.5s ease-in-out infinite;
}
.notes-eq i:nth-child(1) { height: 12px; animation-delay: -.2s; }
.notes-eq i:nth-child(2) { height: 26px; animation-delay: -.5s; background: var(--gold); }
.notes-eq i:nth-child(3) { height: 18px; animation-delay: -.8s; }
.notes-eq i:nth-child(4) { height: 30px; animation-delay: -.35s; background: var(--gold); }
.notes-eq i:nth-child(5) { height: 14px; animation-delay: -.65s; }

.steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0;
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line-strong);
}
.steps li {
  padding: 14px 16px 4px;
  border-left: 1px solid var(--line);
}
.steps li:first-child { border-left: 0; padding-left: 0; }
.step-n {
  font: 600 8px/1.4 var(--mono);
  letter-spacing: .16em;
  color: var(--crimson);
}
.steps h3 {
  margin: 5px 0 6px;
  font-size: 13px;
  line-height: 1.4;
  letter-spacing: .01em;
}
.steps p {
  margin: 0;
  font-size: 10.5px;
  line-height: 1.75;
  color: var(--ink-2);
}
.steps code {
  display: inline-block;
  margin-top: 8px;
  padding: 3px 6px;
  border-radius: 4px;
  background: rgba(36, 26, 24, .06);
  color: var(--crimson);
  font: 500 8px/1.4 var(--mono);
  white-space: nowrap;
}
.notes-foot {
  margin: 18px 0 0;
  padding-top: 13px;
  border-top: 1px solid var(--line);
  text-align: center;
  font-size: 10px;
  letter-spacing: .03em;
  color: var(--ink-2);
}

/* ---------- 页脚 ---------- */
.foot {
  display: grid;
  grid-template-columns: 1fr 1.35fr 1.35fr;
  gap: 22px;
  margin-top: 28px;
  padding-top: 17px;
  border-top: 2px solid var(--ink);
  font-size: 9.5px;
  line-height: 1.7;
  color: var(--ink-2);
}
.foot b {
  display: block;
  margin-bottom: 3px;
  font: 700 9px/1.4 var(--mono);
  letter-spacing: .18em;
  color: var(--ink);
}
.foot span { display: block; }

/* ---------- 提示 ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 22px;
  z-index: 60;
  max-width: calc(100vw - 32px);
  padding: 10px 16px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper-3);
  font-size: 12px;
  line-height: 1.4;
  box-shadow: 0 4px 0 rgba(0, 0, 0, .18);
  opacity: 0;
  transform: translate(-50%, 14px);
  pointer-events: none;
  transition: opacity .2s, transform .2s;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.noscript {
  position: fixed;
  inset: 20px;
  z-index: 100;
  display: grid;
  place-items: center;
  border: 2px solid var(--ink);
  background: var(--paper-2);
  font-size: 15px;
}

/* ---------- 动效 ---------- */
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes eq {
  0%, 100% { transform: scaleY(.55); }
  50% { transform: scaleY(1); }
}

/* ---------- 响应式 ---------- */
@media (max-width: 980px) {
  .grid { grid-template-columns: 1fr; }
  .dossier { position: static; }
  .hero { grid-template-columns: 1fr 210px; }
  .hero-art { height: 190px; }
  .windmill { width: 176px; }
  .seal { width: 70px; height: 70px; }
  .seal strong { font-size: 23px; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps li { border-top: 1px solid var(--line); }
  .steps li:nth-child(-n+2) { border-top: 0; }
  .steps li:nth-child(odd) { border-left: 0; padding-left: 0; }
  .foot { grid-template-columns: 1fr 1fr; }
  .foot > div:last-child { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
  .shell { padding: 18px 16px 38px; }
  .topline-right { display: none; }
  .hero { grid-template-columns: 1fr; gap: 4px; padding: 24px 0 18px; }
  .hero h1 { font-size: clamp(54px, 15vw, 84px); }
  .hero-en { letter-spacing: .26em; }
  .hero-art {
    position: absolute;
    right: -8px;
    bottom: 4px;
    height: 120px;
    width: 150px;
    opacity: .95;
    pointer-events: none;
  }
  .windmill { width: 118px; opacity: .55; }
  .seal { width: 58px; height: 58px; right: 0; bottom: 0; padding: 6px 0 5px; }
  .seal span { font-size: 8px; }
  .seal strong { font-size: 19px; }
  .tagline { margin-top: 11px; font-size: 13px; max-width: 22em; }
  .rule i { display: none; }
  .card { padding: 18px 17px; box-shadow: 4px 6px 0 rgba(36, 26, 24, .12); }
  .card-head h2 { font-size: 23px; }
  .controls { grid-template-columns: 1fr; gap: 9px; }
  .actions { grid-template-columns: 1fr; }
  .btn { min-height: 46px; }
  .under-actions { margin-bottom: 14px; }
  #wave { height: 112px; }
  .steps { grid-template-columns: 1fr; margin-top: 17px; }
  .steps li, .steps li:nth-child(odd) {
    border-left: 0;
    border-top: 1px solid var(--line);
    padding: 13px 0;
  }
  .steps li:first-child { border-top: 0; padding-top: 4px; }
  .steps p { font-size: 11px; }
  .notes { padding: 21px 18px 18px; }
  .notes-head h2 { font-size: 25px; }
  .notes-eq { display: none; }
  .foot { grid-template-columns: 1fr; gap: 12px; }
  .foot > div:last-child { grid-column: auto; }
  .toast { bottom: 16px; }
}

@media (max-width: 420px) {
  .hero h1 { font-size: 48px; }
  .hero-en { font-size: 11px; }
  .hero-art { width: 120px; height: 104px; opacity: .9; }
  .windmill { width: 98px; }
  .seal { width: 50px; height: 50px; }
  .seal strong { font-size: 16px; }
  .seal span { font-size: 7px; }
  .chip { font-size: 11px; padding: 5px 9px; }
  .stats { gap: 8px 8px; }
  .stat b { font-size: 18px; }
  .band em { font-size: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  .windmill .blades, .notes-eq i { animation: none; }
  * { transition-duration: .01ms !important; }
}

/* ============================================================
   Step 3 · 小骑士贴纸角 / 童趣层
   所有插画为原创 SVG；不使用官方立绘
   ============================================================ */

.doodle-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: .26;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240' viewBox='0 0 240 240'%3E%3Cg fill='none' stroke='%23241A18' stroke-width='1.4' opacity='.55'%3E%3Cpath d='M28 34l5 11 11 5-11 5-5 11-5-11-11-5 11-5z'/%3E%3Cpath d='M178 26v34M161 43h34M172 30l22 22M194 30l-22 22'/%3E%3Cpath d='M66 186q12-20 24 0 12-16 22 4'/%3E%3Ccircle cx='194' cy='164' r='5'/%3E%3Cpath d='M116 96l9 9m0-9l-9 9'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 240px 240px;
}

.hero-stickers {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 14px;
}
.mini-sticker {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 10px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .04em;
  box-shadow: 2px 2px 0 rgba(36, 26, 24, .18);
}
.mini-red { background: var(--crimson); color: var(--paper-3); transform: rotate(-3deg); }
.mini-gold { background: var(--gold-2); color: var(--ink); transform: rotate(2deg); }
.mini-mint { background: var(--mint); color: var(--ink); transform: rotate(-1.5deg); }

/* ---------- 骑士小剧场 ---------- */
.knight-strip {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 370px;
  align-items: center;
  gap: 22px;
  margin-top: 24px;
  padding: 28px 32px 26px;
  overflow: hidden;
  border: 2px solid var(--ink);
  border-radius: 20px;
  background:
    radial-gradient(rgba(36, 26, 24, .12) .8px, transparent .9px) 0 0 / 9px 9px,
    linear-gradient(135deg, rgba(240, 201, 122, .26), transparent 58%),
    var(--paper-3);
  box-shadow: 6px 8px 0 rgba(36, 26, 24, .13);
}
.knight-strip::after {
  content: "";
  position: absolute;
  right: -60px;
  bottom: -90px;
  width: 260px;
  height: 260px;
  border: 2px dashed rgba(166, 43, 58, .22);
  border-radius: 50%;
  pointer-events: none;
}
.tape {
  position: absolute;
  top: -13px;
  left: 38px;
  width: 82px;
  height: 25px;
  background: rgba(240, 201, 122, .78);
  border: 1px dashed rgba(36, 26, 24, .35);
  transform: rotate(-4deg);
  box-shadow: 0 2px 0 rgba(36, 26, 24, .08);
  pointer-events: none;
}
.tape-right { left: auto; right: 46px; transform: rotate(3.5deg); background: rgba(143, 227, 192, .62); }
.knight-copy { position: relative; z-index: 2; }
.knight-copy h2 {
  margin: 8px 0 10px;
  font-family: var(--serif);
  font-size: clamp(28px, 3.8vw, 38px);
  line-height: 1.2;
  letter-spacing: .01em;
}
.knight-copy h2 em {
  font-style: normal;
  color: var(--crimson);
  background: linear-gradient(transparent 64%, var(--gold-2) 64%);
  padding: 0 .06em;
}
.knight-copy p {
  max-width: 42ch;
  margin: 0;
  font-size: 12.5px;
  line-height: 1.8;
  color: var(--ink-2);
}
.sticker-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
}
.sticker {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 7px 15px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: .04em;
  box-shadow: 3px 3px 0 var(--ink);
}
.sticker-red { background: var(--crimson); color: var(--paper-3); transform: rotate(-2.5deg); }
.sticker-gold { background: var(--gold-2); color: var(--ink); transform: rotate(1.8deg); }
.sticker-mint { background: var(--mint); color: var(--ink); transform: rotate(-1deg); }
.knight-note {
  margin: 14px 0 0 !important;
  font: 500 9px/1.5 var(--mono) !important;
  letter-spacing: .08em;
  color: var(--ink-2);
}

.knight-stage {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  min-height: 330px;
  padding-top: 8px;
  background: radial-gradient(circle at 58% 58%, rgba(214, 162, 67, .18), transparent 58%);
}
.chibi {
  position: relative;
  z-index: 2;
  width: 232px;
  height: auto;
  filter: drop-shadow(0 5px 0 rgba(36, 26, 24, .14));
  transform-origin: 50% 92%;
  animation: knight-bob 4.8s ease-in-out infinite;
}
.speech {
  position: absolute;
  z-index: 4;
  top: 4px;
  left: 0;
  max-width: 188px;
  padding: 11px 13px 10px;
  border: 2px solid var(--ink);
  border-radius: 14px 14px 14px 4px;
  background: var(--paper-3);
  box-shadow: 3px 3px 0 var(--ink);
  transform: rotate(-2deg);
}
.speech b {
  display: block;
  font-family: var(--serif);
  font-size: 13px;
  line-height: 1.45;
  color: var(--ink);
}
.speech span {
  display: block;
  margin-top: 4px;
  font-size: 9px;
  line-height: 1.4;
  color: var(--ink-2);
}
.burst {
  position: absolute;
  z-index: 5;
  padding: 2px 8px;
  border: 2px solid var(--ink);
  border-radius: 4px;
  box-shadow: 2px 2px 0 var(--ink);
  font-family: var(--serif);
  font-size: 12px;
  font-weight: 900;
  line-height: 1.5;
  color: var(--ink);
  background: var(--gold-2);
}
.burst-a { top: 66px; right: 4px; transform: rotate(8deg); background: var(--mint); }
.burst-b { bottom: 30px; left: 4px; transform: rotate(-9deg); background: var(--paper-3); color: var(--crimson); }

/* ---------- 手机快捷条 ---------- */
.quickbar { display: none; }
.quick-btn {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 2px solid var(--ink);
  border-radius: 12px;
  font-size: 15px;
  font-weight: 900;
  letter-spacing: .04em;
  cursor: pointer;
  box-shadow: 0 3px 0 var(--ink);
}
.quick-btn:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--ink); }
.quick-btn:disabled { opacity: .55; cursor: not-allowed; }
.quick-say { flex: 1; background: var(--crimson); color: var(--paper-3); }
.quick-say svg { width: 18px; height: 18px; fill: currentColor; }
.quick-mp3 { width: 88px; background: var(--paper-3); color: var(--ink); font-size: 13px; }
.quickbar-star { color: var(--crimson); font-size: 20px; flex: none; }

/* ---------- 可读性 / 触控补丁 ---------- */
.chip {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
}
input[type="range"] { height: 38px; }
input[type="range"]::-webkit-slider-thumb { width: 22px; height: 22px; margin-top: -9.5px; }
input[type="range"]::-moz-range-thumb { width: 20px; height: 20px; }
.switch { min-height: 44px; }
.track { width: 44px; height: 26px; }
.thumb { width: 18px; height: 18px; }
.switch input:checked + .track .thumb { transform: translateX(18px); }
.linkbtn {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  padding: 6px 2px;
  font-size: 11px;
}
.under-actions { font-size: 11.5px; }
#status { font-size: 11.5px; }
.wave-head, .wave-foot { font-size: 9px; }
.band span { font-size: 9px; }
.band em { font-size: 8px; }
.scale { font-size: 9px; }
.mapping dt, .mapping dd { font-size: 10.5px; }
.source { font-size: 9.5px; }
.foot { font-size: 10.5px; }
.portrait-cap { font-size: 8px; }
.name-block p { font-size: 11px; }
.name-block p span { font-size: 9.5px; }
.mini-head { font-size: 8.5px; }
.stat span { font-size: 9.5px; }
.stat i { font-size: 9px; }
.formants { font-size: 9px; }
.switch-label { font-size: 12px; }
.switch-label small { font-size: 9.5px; }
.switch-note { font-size: 9px; }
.count { font-size: 10px; }
.field-label { font-size: 12.5px; }
.hint { font-size: 10.5px; }
.notes-foot { font-size: 10.5px; }
.steps p { font-size: 11px; }
.steps code { font-size: 9px; }

@keyframes knight-bob {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50% { transform: translateY(-5px) rotate(1deg); }
}
@keyframes knight-hop {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50% { transform: translateY(-9px) rotate(2deg); }
}
body.is-playing .chibi { animation: knight-hop .62s ease-in-out infinite; }
body.is-playing .windmill .blades { animation-duration: 5s; }
body.is-playing .burst-a { animation: pop .7s ease-in-out infinite alternate; }
@keyframes pop { from { transform: rotate(8deg) scale(.94); } to { transform: rotate(11deg) scale(1.08); } }

@media (max-width: 980px) {
  .knight-strip { grid-template-columns: minmax(0, 1fr) 320px; padding: 24px 24px 22px; }
  .knight-stage { min-height: 300px; }
  .chibi { width: 210px; }
  .speech { max-width: 168px; }
}

@media (max-width: 760px) {
  body { padding-bottom: calc(84px + env(safe-area-inset-bottom)); }
  .quickbar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
    background: rgba(242, 230, 208, .96);
    border-top: 2px solid var(--ink);
    box-shadow: 0 -4px 0 rgba(36, 26, 24, .10);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
  }
  .quickbar-star { display: none; }
  .quick-say { flex: 1; }
  .toast { bottom: calc(86px + env(safe-area-inset-bottom)); }
  .knight-strip {
    grid-template-columns: 1fr;
    gap: 4px;
    padding: 24px 18px 20px;
  }
  .knight-copy h2 { font-size: 27px; }
  .knight-copy p { font-size: 12px; }
  .knight-stage { min-height: 300px; margin-top: 10px; }
  .chibi { width: 205px; }
  .speech { top: 0; left: 0; max-width: 172px; }
  .tape { left: 20px; width: 64px; }
  .tape-right { right: 20px; }
  .chip { min-height: 44px; padding: 10px 14px; font-size: 12px; }
  input[type="range"] { height: 44px; }
  .switch { min-height: 48px; }
  .linkbtn { min-height: 44px; font-size: 12px; }
  .under-actions { font-size: 12px; }
  #status { font-size: 12px; }
  .mapping dt, .mapping dd { font-size: 10.5px; }
  .band span { font-size: 9px; }
  .band em { font-size: 8px; }
  .source { font-size: 10px; }
  .foot { font-size: 10.5px; }
  .stats { gap: 10px 12px; }
  .stat b { font-size: 20px; }
  .knight-note { font-size: 9px !important; }
  .scroll-pad { padding-bottom: 12px; }
}

@media (max-width: 420px) {
  .knight-strip { padding: 22px 15px 18px; }
  .knight-copy h2 { font-size: 24px; }
  .chibi { width: 184px; }
  .knight-stage { min-height: 274px; }
  .speech { max-width: 154px; padding: 9px 10px; }
  .speech b { font-size: 12px; }
  .burst-a { top: 52px; }
  .burst-b { bottom: 22px; }
  .sticker { min-height: 38px; font-size: 12px; padding: 6px 12px; }
  .mini-sticker { font-size: 10px; padding: 3px 8px; }
  .band em { font-size: 7.5px; }
}

@media (prefers-reduced-motion: reduce) {
  .chibi, body.is-playing .chibi, body.is-playing .burst-a { animation: none !important; }
  .doodle-bg { opacity: .15; }
}

.quickbar {
  transition: transform .2s ease, opacity .2s ease;
}
.quickbar.is-hidden {
  transform: translateY(calc(100% + 10px));
  opacity: 0;
  pointer-events: none;
}

/* Mobile readability floor: keep the stamped-label look, but not at 7–8px. */
@media (max-width: 760px) {
  .kicker,
  .name-en,
  .card-num,
  .control-top output,
  .slider-ends span,
  .switch-note,
  .wave-head span,
  .wave-foot span,
  .band span,
  .stat-label,
  .mapping-key,
  .source,
  .footer,
  .knight-note,
  .seal span,
  .seal b,
  .speech span {
    font-size: 10px;
  }
  .kicker {
    letter-spacing: .13em;
  }
}

/* ============================================================
   Step 7 · 官方立绘 / 原版徽记 / 金橙奶油配色
   金色 > 橙色 > 暖白 > 墨黑；去掉薄荷绿与冷调蓝。
   ============================================================ */
:root {
  --paper: #FFF9EE;
  --paper-2: #FFFCF6;
  --paper-3: #FFFFFF;
  --ink: #1B1A18;
  --ink-2: #6A5540;
  --crimson: #C26A22;       /* 主橙：只做点缀与大字 */
  --crimson-2: #9E4F14;     /* 深橙：小字/链接，奶油底 5.59:1 */
  --gold: #C79B3B;
  --gold-2: #F2C94C;        /* 发色金：主按钮/贴纸 */
  --navy: #2A2119;          /* 暖黑：只保留极少量深色块 */
  --mint: #F1D59A;          /* 旧变量名保留，值改为浅金 */
  --line: rgba(27, 26, 24, .14);
  --line-strong: rgba(27, 26, 24, .30);
}

body {
  background:
    radial-gradient(1100px 600px at 12% -4%, rgba(242, 201, 76, .20), transparent 60%),
    radial-gradient(900px 520px at 92% 8%, rgba(194, 106, 34, .09), transparent 62%),
    var(--paper);
}
::selection { background: var(--gold-2); color: var(--ink); }
a { color: var(--crimson-2); }
.grain { opacity: .10; }
.topline b, .dot { color: var(--crimson-2); background-color: var(--crimson-2); }
.topline b { background: none; }
.hero-en, .name-en, .eyebrow { color: var(--crimson-2); }
.eyebrow { color: var(--ink-2); }
.hero-en { color: var(--crimson-2); }
.seal { color: var(--crimson-2); border-color: var(--crimson); }
.seal span { color: var(--crimson-2); }
.doodle-bg { opacity: .16; }

/* 按钮：金底墨字，橙色硬阴影；不再用大面积绯红 */
.btn-primary {
  background: var(--gold-2);
  color: var(--ink);
  box-shadow: 0 4px 0 var(--crimson-2);
}
.btn-primary:hover { background: var(--gold); color: var(--ink); }
.btn-primary svg { fill: currentColor; }
.btn-secondary {
  background: var(--paper-3);
  color: var(--ink);
  box-shadow: 0 4px 0 var(--gold);
}
.btn-secondary:hover { background: var(--paper-2); }
.btn:active { box-shadow: 0 1px 0 var(--crimson-2); }
.actions { margin-top: 14px; }
.under-actions { margin: 10px 0 17px; }

.quick-say {
  background: var(--gold-2);
  color: var(--ink);
  box-shadow: 0 3px 0 var(--crimson-2);
}
.quick-say svg { fill: currentColor; }
.quick-mp3 {
  background: var(--paper-3);
  color: var(--ink);
  box-shadow: 0 3px 0 var(--gold);
}
.quickbar-star { color: var(--crimson-2); }

/* 波形：从深蓝块改为奶油纸，减少黑色重量 */
.wave-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .72), transparent 55%),
    #FBF0D6;
  border-color: var(--ink);
  box-shadow: inset 0 0 0 1px rgba(199, 155, 59, .35), 4px 5px 0 rgba(199, 155, 59, .20);
}
.wave-head { color: var(--crimson-2); }
.wave-head span:last-child { color: var(--ink-2); }
.wave-foot { color: var(--ink-2); }
.wave-foot span:last-child { color: var(--crimson-2); }

/* 声线档案里的原版徽记：不改色，放在暖白/浅金底盘上 */
.portrait {
  align-items: center;
  gap: 14px;
  padding: 2px 0 14px;
}
.portrait-plate {
  position: relative;
  flex: none;
  display: grid;
  place-items: center;
  width: 104px;
  height: 112px;
  border: 2px solid var(--ink);
  border-radius: 14px;
  background: radial-gradient(circle at 50% 36%, #FFFEF9 0 52%, #F8E8C8 100%);
  box-shadow: 3px 3px 0 var(--gold);
  overflow: hidden;
}
.portrait-plate::before {
  content: "";
  position: absolute;
  inset: 4px;
  border: 1px solid rgba(199, 155, 59, .55);
  border-radius: 10px;
  pointer-events: none;
}
.crest-logo {
  display: block;
  width: 82px;
  height: auto;
  position: relative;
  z-index: 1;
}
.portrait-cap { color: var(--ink-2); font-size: 10px; }

/* 角色铭牌：正式立绘 + 纸感框 + 少量贴纸 */
.knight-strip {
  grid-template-columns: minmax(0, 1fr) 440px;
  align-items: center;
  gap: 26px;
  padding: 30px 32px 30px;
  background:
    radial-gradient(rgba(27, 26, 24, .10) .8px, transparent .9px) 0 0 / 9px 9px,
    radial-gradient(ellipse at 78% 45%, rgba(242, 201, 76, .34), transparent 62%),
    linear-gradient(135deg, rgba(242, 201, 76, .16), transparent 58%),
    var(--paper-3);
  box-shadow: 7px 8px 0 rgba(158, 79, 20, .16);
}
.knight-strip::after { border-color: rgba(194, 106, 34, .22); }
.tape { background: rgba(242, 201, 76, .78); }
.tape-right { background: rgba(199, 155, 59, .38); }
.knight-copy h2 em {
  color: var(--crimson-2);
  background: linear-gradient(transparent 64%, var(--gold-2) 64%);
}
.knight-copy p { font-size: 13px; max-width: 36ch; }
.knight-meta {
  display: grid;
  gap: 5px;
  max-width: 38ch;
  margin: 16px 0 0;
  padding-top: 12px;
  border-top: 1px dashed var(--line-strong);
}
.knight-meta div { display: flex; gap: 10px; align-items: baseline; }
.knight-meta dt {
  flex: none;
  width: 3.4em;
  margin: 0;
  font: 700 10px/1.6 var(--mono);
  letter-spacing: .04em;
  color: var(--crimson-2);
}
.knight-meta dd {
  margin: 0;
  font-size: 12px;
  line-height: 1.65;
  color: var(--ink-2);
}
.knight-note { color: var(--ink-2); }

.knight-stage {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  min-height: 0;
  margin: 0;
  padding: 4px 0 18px;
  background: radial-gradient(ellipse at 58% 56%, rgba(199, 155, 59, .22), transparent 62%);
}
.standee {
  position: relative;
  z-index: 2;
  display: block;
  width: min(320px, 60vw);
  margin-top: 8px;
  filter:
    drop-shadow(0 3px 0 rgba(255, 249, 238, .95))
    drop-shadow(0 7px 0 rgba(158, 79, 20, .16));
  transition: transform .25s ease;
}
.standee img { display: block; width: 100%; height: auto; }
body.is-playing .standee { transform: translateY(-3px) rotate(-.35deg); }
.figure-cap {
  position: relative;
  z-index: 3;
  margin-top: -4px;
  padding: 5px 11px;
  border: 1.5px solid var(--ink);
  background: var(--paper-3);
  box-shadow: 2px 2px 0 var(--gold);
  font: 600 9.5px/1.4 var(--mono);
  letter-spacing: .13em;
  color: var(--ink-2);
  transform: rotate(-1.1deg);
}
.figure-cap span { color: var(--crimson-2); }
.speech {
  background: var(--paper-3);
  border-color: var(--ink);
  box-shadow: 3px 3px 0 var(--gold);
}
.speech b { color: var(--ink); }
.speech span { color: var(--ink-2); }
.burst-a { background: var(--gold-2); }
.burst-b { background: var(--paper-3); color: var(--crimson-2); }

/* 手机：立绘改为头部到大腿的竖裁（图片本身已是撕纸边） */
@media (max-width: 980px) {
  .knight-strip { grid-template-columns: minmax(0, 1fr) 330px; gap: 16px; padding: 24px 22px 24px; }
  .standee { width: min(270px, 56vw); }
  .knight-meta { max-width: 32ch; }
}
@media (max-width: 760px) {
  .quickbar {
    background: rgba(255, 249, 238, .97);
    border-top-color: var(--ink);
    box-shadow: 0 -4px 0 rgba(199, 155, 59, .20);
  }
  .knight-strip {
    grid-template-columns: 1fr;
    gap: 2px;
    padding: 24px 18px 22px;
  }
  .knight-copy h2 { font-size: 27px; }
  .knight-copy p { font-size: 13px; }
  .knight-meta { margin-top: 12px; }
  .knight-stage { padding: 0 0 22px; }
  .standee { width: min(300px, 78vw); margin-top: 0; }
  .speech { top: 10px; left: 0; max-width: 170px; }
  .burst-a { top: 34px; right: 2px; }
  .burst-b { bottom: 34px; left: 2px; }
  .figure-cap { font-size: 10px; }
}
@media (max-width: 420px) {
  .standee { width: min(252px, 78vw); }
  .speech { max-width: 156px; padding: 9px 10px; }
  .speech b { font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .standee, body.is-playing .standee { transition: none; transform: none; }
}

/* 小字最低 10px（手机），并把页脚链接的点击高度抬起来 */
@media (max-width: 760px) {
  .band em, .band span, .formants, .steps code, .wave-head, .wave-foot,
  .scale, .mapping dt, .mapping dd, .source, .foot, .portrait-cap,
  .mini-head, .stat span, .stat i, .switch-label small, .switch-note,
  .count, .hint, .knight-note, .figure-cap, .step-n, .seal span, .seal b,
  .speech span, .topline, .card-num {
    font-size: 10px !important;
  }
  .foot a { display: inline-block; padding: 7px 0; }
}

/* 角色铭牌的台词块与桌面尺寸配平 */
.knight-quote {
  max-width: 34ch;
  margin: 18px 0 0;
  padding: 11px 14px 10px;
  border-left: 3px solid var(--crimson);
  background: rgba(242, 201, 76, .16);
  font-family: var(--serif);
  font-size: 15px;
  line-height: 1.7;
  color: var(--ink);
}
.knight-quote cite {
  display: block;
  margin-top: 3px;
  font: 500 9.5px/1.4 var(--mono);
  font-style: normal;
  letter-spacing: .06em;
  color: var(--crimson-2);
}
@media (min-width: 981px) {
  .standee { width: min(272px, 52vw); }
  .knight-stage { min-height: 790px; }
}
@media (max-width: 980px) and (min-width: 761px) {
  .standee { width: min(245px, 50vw); }
  .knight-quote { max-width: 30ch; font-size: 14px; }
}
@media (max-width: 760px) {
  .knight-quote { max-width: none; font-size: 14px; }
}

/* 桌面：气泡靠近头部，而不是悬在版面上方 */
@media (min-width: 761px) {
  .knight-quote { max-width: min(40ch, 100%); }
  .speech { top: 228px; left: -74px; max-width: 190px; }
  .burst-a { top: 54px; right: 6px; }
}
@media (max-width: 980px) and (min-width: 761px) {
  .speech { top: 210px; left: -66px; max-width: 176px; }
}

/* 徽记再大一点，让 116px 原图在 2x 屏上也看得清 */
.portrait-plate { width: 112px; height: 120px; }
.crest-logo { width: 94px; }
.portrait { gap: 15px; }

/* 桌面也把 7–9px 的注释字抬到 10px，保持档案感但不费眼 */
@media (min-width: 761px) {
  .band em, .band span, .formants, .steps code, .wave-head, .wave-foot,
  .scale, .mapping dt, .mapping dd, .source, .foot, .portrait-cap,
  .mini-head, .stat span, .stat i, .switch-label small, .switch-note,
  .count, .hint, .knight-note, .figure-cap, .step-n, .seal span, .seal b,
  .speech span, .card-num {
    font-size: 10px;
  }
}

/* 320 窄屏：把「啵」贴纸抬离图注，别压住 DON 字样 */
@media (max-width: 760px) {
  .burst-b { bottom: 62px; left: 0; }
  .figure-cap { z-index: 4; }
}

/* 窄屏让名牌压住一点撕纸边，视觉上像名牌压在纸片上，而不是腰斩 */
@media (max-width: 760px) {
  .figure-cap { margin-top: -14px; }
}
