:root {
  color-scheme: light;
  --paper: #f6f4ed;
  --surface: #fffef9;
  --ink: #172d27;
  --green: #205749;
  --muted: #59665e;
  --line: #d0d3c7;
  --wash: #e7ece2;
  --red: #963927;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); font-size: 16px; line-height: 1.62; }
button, input, select, textarea { font: inherit; color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { cursor: default; opacity: .52; }
button:not(:disabled), a { touch-action: manipulation; }
a { color: var(--green); text-underline-offset: 3px; }
:focus-visible { outline: 3px solid #b66e35; outline-offset: 3px; }
[hidden], .issues:empty { display: none !important; }
.shell { max-width: 1216px; width: 100%; padding-inline: clamp(22px, 5vw, 74px); margin: 0 auto; }
.topbar { border-bottom: 1px solid var(--line); }
.toprow { min-height: 77px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.wordmark { display: flex; align-items: center; gap: 12px; font-size: 21px; font-weight: 700; letter-spacing: .04em; }
.brand-symbol { display: inline-flex; align-items: center; gap: 3px; height: 28px; transform: skewY(-12deg); }
.brand-symbol i { display: block; width: 5px; height: 14px; background: var(--green); border-radius: 5px; }
.brand-symbol i:nth-child(2) { height: 26px; }
.brand-symbol i:last-child { height: 19px; }
.help-button, .close-button { border: 0; background: transparent; }
.help-button { display: flex; align-items: center; gap: 7px; min-height: 44px; padding: 6px 0 6px 8px; font-size: 14px; color: var(--muted); }
.help-button span:first-child { display: grid; place-items: center; width: 18px; height: 18px; border: 1.3px solid currentColor; border-radius: 50%; font: 600 12px/1 system-ui; }
.account-nav { display: flex; align-items: center; gap: clamp(12px, 2vw, 26px); }
.account-nav a { min-height: 44px; display: inline-flex; align-items: center; padding-inline: 3px; font-size: 14px; font-weight: 600; text-decoration: none; }
.account-nav a:is(:hover,[aria-current=page]) { text-decoration: underline; text-underline-offset: 5px; }
.help-button:hover { color: var(--green); text-decoration: underline; text-underline-offset: 3px; }
h1, h2, h3, p { margin: 0; }
h1, .serif { font-family: "Hedvig Letters Serif", "Songti SC", "Noto Serif CJK SC", "Source Han Serif SC", "STSong", serif; }
h1 { line-height: 1.25; font-size: clamp(32px, 4vw, 49px); font-weight: 650; letter-spacing: .015em; }
h2 { font-size: 21px; line-height: 1.4; }
h3 { font-size: 16px; line-height: 1.5; }
.muted, .intro, .footnote { color: var(--muted); }
.intro { margin-top: 12px; max-width: 39em; }
.loading { padding-block: 76px; color: var(--muted); }
.entrance { display: grid; grid-template-columns: minmax(260px, .94fr) minmax(360px, 1.06fr); margin: clamp(36px, 7.5vh, 90px) auto 60px; max-width: 1000px; min-height: 444px; overflow: hidden; border: 1px solid #c6cbbf; border-radius: 12px; background: var(--surface); box-shadow: 0 8px 35px #2035280a; }
.entrance-form { display: flex; flex-direction: column; justify-content: center; align-items: stretch; padding: clamp(32px, 4.8vw, 73px); }
.entrance-form h1 { font-size: clamp(34px, 3.6vw, 48px); }
.entrance-form .intro { margin-top: 16px; }
.entrance-form form { margin-top: 35px; }
.entrance-form form .primary { margin-top: 17px; width: 100%; justify-content: space-between; }
.sleeve, .soundstage { position: relative; isolation: isolate; overflow: hidden; background: #304f46; }
.sleeve::before, .soundstage::before { content: ""; position: absolute; inset: 0; background: linear-gradient(135deg,#778972 0%,#34554a 50%,#223e36 100%); }
.paper-sleeve { position: absolute; width: 91%; aspect-ratio: 1; top: 15%; left: -6%; border: 1px solid #c3b9a0; background: repeating-linear-gradient(25deg,#c7bd9f 0 1px,#c9c0a5 1px 3px); transform: rotate(-12deg); box-shadow: 4px 14px 20px #1528214a; }
.disc { position: absolute; aspect-ratio: 1; width: 100%; left: 5%; top: 7%; border-radius: 50%; border: 2px solid #27332b; background:
    radial-gradient(circle,transparent 0 60%,#121d1740 84%,#121c16 99%),
    repeating-radial-gradient(circle at center,#141f1a40 0 1px,#d9e1cf14 1px 2px,#1e2922a1 2px 3px),
    conic-gradient(from 22deg,#202f28 0deg,#59635a 34deg,#25362e 70deg,#18251e 110deg,#556258 171deg,#24332c 214deg,#102018 266deg,#636e62 317deg,#202f28 360deg);
  box-shadow: 6px 13px 18px #14251a59, inset 0 0 0 3px #17281a;
}
.disc::before { content: ""; position: absolute; inset: 33.5%; border-radius: 50%; background: radial-gradient(circle,#1b3025 0 3%,#e8ce8f 3.5% 5%,transparent 5.5%),linear-gradient(124deg,#d7b177,#dfc397 55%,#bfa074); box-shadow: 0 0 0 3px #15231b,0 0 0 5px #4b5448; }
.disc::after { content: ""; position: absolute; inset: 40%; border-radius: 50%; border: 1px solid #a28559; }
.sleeve::after { content: ""; pointer-events:none; position:absolute; inset:0; box-shadow:inset 0 0 50px #2437282b; }
.field { display: block; margin-top: 20px; }
.field:first-child, .field:first-of-type { margin-top: 0; }
.field-name { display: block; margin-bottom: 7px; font-weight: 650; font-size: 15px; line-height: 1.6; }
input:not([type=checkbox]), select, textarea { display: block; width: 100%; min-width: 0; border: 1px solid #a7afa3; border-radius: 5px; background: var(--surface); padding: 10px 12px; line-height: 1.5; }
input::placeholder, textarea::placeholder { color: #778174; }
textarea { min-height: 98px; resize: vertical; }
select { min-height: 46px; }
input[type=checkbox] { width: 19px; height: 19px; accent-color: var(--green); }
.primary, .secondary { display: inline-flex; align-items: center; justify-content: center; gap: 14px; min-height: 46px; padding: 10px 20px; border-radius: 6px; font-size: 15px; font-weight: 620; text-decoration: none; }
.primary { border: 1px solid var(--green); color: #fffef4; background: var(--green); }
.primary:hover:not(:disabled) { background: #164638; }
.secondary { background: transparent; color: var(--green); border: 1px solid #8f9f91; }
.secondary:hover:not(:disabled) { background: var(--wash); }
.arrow { font-size: 20px; line-height: 1; font-weight: 400; }
.issues { border-left: 3px solid #af5c41; background: #fbede5; color: #873c2a; padding: 10px 13px; margin-top: 16px; overflow-wrap: anywhere; }
.workspace { margin: 40px auto 70px; max-width: 830px; }
.identity { display: flex; flex-wrap: wrap; gap: 8px 18px; color: var(--muted); font-size: 14px; margin-bottom: 13px; }
.identity span + span { border-left: 1px solid #b5bfb2; padding-left: 16px; }
.steps { list-style: none; margin: 29px 0 22px; padding: 0; display: flex; gap: 5px; }
.steps li { flex: 1; min-width: 0; border-top: 3px solid #d0d4c9; padding-top: 8px; font-size: 13px; color: #606c62; }
.steps li.past { border-color: #8b9f8c; }
.steps li.current { border-color: var(--green); font-weight: 700; color: var(--green); }
.panel { border: 1px solid var(--line); background: var(--surface); border-radius: 10px; padding: clamp(21px, 4vw, 39px); }
.panel form { margin-top: 22px; }
.panel form .primary, .action { margin-top: 20px; }
.panel .footnote { margin-top: 9px; font-size: 14px; }
.panel form .field + .field { margin-top: 22px; }
.soundbox { background: #1b342d; color: #f9f6e9; border-radius: 9px; overflow: hidden; }
.audioface { display: grid; grid-template-columns: 160px 1fr; min-height: 163px; align-items: center; }
.soundstage { align-self: stretch; }
.soundstage .paper-sleeve { width: 120%; left: -30%; top: 23%; }
.soundstage .disc { width: 128%; left: -20%; top: 0; }
.soundmain { padding: 23px 27px; min-width: 0; }
.clock { display: block; font: 500 16px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace; color: #e2e7d7; }
.playline { display: flex; align-items: center; gap: 16px; margin-bottom: 15px; flex-wrap: wrap; }
.play { display: inline-flex; align-items: center; gap: 10px; min-height: 42px; border: 1px solid #e0e5d0; background: #e9edda; color: #193b31; padding: 8px 15px; font-size: 14px; font-weight: 650; border-radius: 50px; }
.play i { width: 0; height: 0; border-top: 6px solid transparent; border-bottom: 6px solid transparent; border-left: 9px solid currentColor; }
.play[data-playing=true] i { width: 9px; height: 12px; border: 0; border-inline: 3px solid currentColor; }
progress { appearance: none; -webkit-appearance: none; width: 100%; height: 5px; display: block; border: 0; border-radius: 8px; overflow: hidden; color: #cfb685; background: #4a6055; }
progress::-webkit-progress-bar { background: #4a6055; }
progress::-webkit-progress-value { background: #cfb685; }
progress::-moz-progress-bar { background: #cfb685; }
video { display: block; width: 100%; max-height: 56vh; background: #101c18; }
.soundbox:has(video) .audioface { display: block; min-height: 0; }
.soundbox:has(video) .soundstage { display: none; }
.soundbox:has(video) .soundmain { padding: 15px 22px 20px; }
.listen-note { margin-top: 16px; }
.check { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; }
.check input { flex-shrink: 0; margin: 3px 0 0; }
.check + .primary { margin-top: 14px; }
#confirm-box { margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line); }
.score-section { padding: 24px 0; border-bottom: 1px solid var(--line); }
.score-section:last-of-type { border: 0; padding-bottom: 8px; }
.score-row { display: grid; grid-template-columns: minmax(120px,1fr) 94px; gap: 8px 16px; align-items: center; padding: 17px 0; border-bottom: 1px dashed var(--line); }
.score-row:last-child { border-bottom: 0; padding-bottom: 0; }
.score-name { font-size: 15px; font-weight: 600; }
.score-value { display: flex; align-items: center; gap: 5px; font-size: 13px; color: var(--muted); }
.score-value input { text-align: center; padding: 7px 4px; width: 52px; color: var(--ink); }
.score-row .evidence { grid-column: 1/-1; font-size: 15px; }
.score-row input[type=number] { appearance: textfield; -moz-appearance: textfield; }
.score-row input::-webkit-inner-spin-button { -webkit-appearance: none; }
.two-fields { display: grid; grid-template-columns: 1fr 1.2fr; gap: 16px; }
.panel .two-fields .field { margin: 0; }
.final-note { padding-top: 22px; border-top: 1px solid var(--line); }
.received { width: 53px; height: 53px; display: grid; place-items: center; border-radius: 50%; background: var(--wash); color: var(--green); font-size: 26px; margin-bottom: 18px; }
.receipt-info { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 18px; color: var(--muted); font-size: 14px; }
.host-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 24px 0; }
.host-intro { padding-bottom: 25px; border-bottom: 1px solid var(--line); }
.counts { color: var(--green); font-size: 24px; line-height: 1.5; font-weight: 600; }
.seat-row { padding: 18px 0; display: grid; grid-template-columns: 1fr 1.4fr .8fr; gap: 12px; align-items: start; border-bottom: 1px solid var(--line); }
.seat-row h3 { overflow-wrap: anywhere; }
.seat-row:last-child { padding-bottom: 0; border-bottom: 0; }
.seat-row .muted, .seat-row small { font-size: 13px; }
.seat-phase { display: inline-flex; gap: 7px; align-items: center; }
.seat-phase::before { content: ""; width: 8px; height: 8px; display: inline-block; border-radius: 50%; background: #839586; }
.seat-row[data-done=true] .seat-phase::before { background: #206d49; }
.seat-grade { text-align: right; }
.sample-meta { color: var(--green); font-weight: 600; margin-top: 14px; }
.join-note, .record-meta { color: var(--muted); font-size: 14px; }
.join-note { margin-top: 17px; }
.record-meta { margin-top: 5px; }
.history-work .intro { max-width: 48em; }
.record-list { list-style: none; padding: 0; margin: 26px 0 0; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--surface); }
.record-list li + li { border-top: 1px solid var(--line); }
.history-record { padding: clamp(17px,3vw,28px); display: flex; align-items: center; justify-content: space-between; gap: 18px; text-decoration: none; color: var(--ink); }
.history-record:hover, .history-record:focus-visible { background: var(--wash); }
.history-record:focus-visible { outline-offset: -3px; }
.history-record h2, .saved-score h3 { overflow-wrap: anywhere; }
.record-action { display: grid; gap: 4px; text-align: right; flex-shrink: 0; font-size: 14px; }
.record-action strong { color: var(--green); }
.history-empty, .notice { margin-top: 24px; }
.history-empty p { margin-top: 10px; }
#review-receipt section + section { margin-top: 32px; border-top: 1px solid var(--line); padding-top: 22px; }
.saved-answer dt { font-size: 15px; font-weight: 650; color: var(--green); }
.saved-answer dd { margin: 4px 0 0; }
.saved-answer + .saved-answer { margin-top: 19px; }
.verbatim { white-space: pre-wrap; overflow-wrap: anywhere; }
.saved-score { padding-block: 13px; border-bottom: 1px solid var(--line); }
.score-summary, .section-title { display: flex; gap: 12px; align-items: baseline; justify-content: space-between; }
.score-summary span { white-space: nowrap; color: var(--green); font-variant-numeric: tabular-nums; }
.saved-score p { margin-top: 6px; color: var(--muted); }
.lyrics { border-top: 1px solid var(--line); margin-top: 24px; padding-top: 14px; }
.lyrics summary { width: fit-content; cursor: pointer; padding: 6px 0; color: var(--green); font-weight: 650; }
.lyrics p { margin-top: 12px; }
.host-section { margin-top: 25px; }
.section-title { margin-bottom: 10px; }
.section-title span { font-size: 14px; font-variant-numeric: tabular-nums; color: var(--muted); }
.issues + button.secondary { margin-top: 10px; }
dialog { max-width: min(480px, calc(100% - 36px)); width: 100%; padding: 26px; border: 1px solid var(--line); border-radius: 12px; color: var(--ink); background: var(--surface); box-shadow: 0 8px 60px #102a2140; }
dialog::backdrop { background: #102a2159; }
.dialog-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 19px; }
.close-button { min-width: 40px; min-height: 40px; border-radius: 50%; color: var(--muted); font: 26px/1 system-ui; }
.close-button:hover { background: var(--wash); }
#guide-content p + p { margin-top: 12px; }
noscript { display: block; padding: 20px; }
@media (max-width: 720px) {
  .entrance { grid-template-columns: minmax(180px,.77fr) minmax(276px,1.23fr); min-height: 360px; }
  .entrance-form { padding: 30px; }
  .sleeve .disc { width: 153%; left: -26%; top: 7%; }
  .sleeve .paper-sleeve { width: 142%; left: -48%; }
  .toprow { min-height: 66px; }
}
@media (max-width: 565px) {
  .entrance { grid-template-columns: minmax(0,1fr); margin-top: 25px; min-height: 0; }
  .sleeve { height: clamp(145px,40vw,210px); }
  .sleeve .paper-sleeve { width: 68%; top: 19%; left: 6%; }
  .sleeve .disc { width: 74%; top: -17%; left: 21%; }
  .entrance-form { padding: 26px 23px 29px; }
  .entrance-form form { margin-top: 25px; }
  .entrance-form .intro { margin-top: 9px; }
  .workspace { margin-top: 25px; }
  .audioface { grid-template-columns: 65px 1fr; min-height: 124px; }
  .soundstage .disc { width: 185%; left: -42%; top: 10%; }
  .soundstage .paper-sleeve { width: 190%; left: -70%; }
  .soundmain { padding: 16px; }
  .playline { gap: 9px; }
  .clock { font-size: 13px; }
  .steps { margin-top: 21px; }
  .two-fields { display: block; }
  .panel .two-fields .field + .field { margin-top: 17px; }
  .seat-row { grid-template-columns: 1fr 1fr; }
  .seat-grade { grid-column: 2; text-align: left; }
  .panel .primary.action, .panel form > .primary { width: 100%; }
}
@media (max-width: 360px) {
  .shell { padding-inline: 15px; }
  .entrance-form, .panel { padding: 20px 16px; }
  .audioface { grid-template-columns: 45px 1fr; }
}
@media (max-width: 430px) {
  .account-nav { gap: 9px; }
  .account-nav .help-text { display: none; }
  .account-nav .help-button { min-width: 44px; justify-content: center; padding: 5px; }
  .history-record { display: block; }
  .record-action { display: flex; justify-content: space-between; text-align: left; margin-top: 13px; }
}

.pair-work { max-width: 740px; }
.pair-intro { margin: 8px 0 23px; color: var(--muted); }
.pair-work fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
.pair-tracks { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px; }
.pair-card { border: 1px solid var(--line); border-radius: 10px; padding: 17px; background: var(--surface); }
.pair-card:has(.pick-song input:checked) { border-color: var(--green); box-shadow: inset 0 0 0 1px var(--green); }
.pair-card-top { display: flex; align-items: center; gap: 11px; }
.pair-card h2 { font-size: 19px; white-space: nowrap; }
.pair-play { display: grid; place-items: center; flex: 0 0 44px; height: 44px; color: #fffef4; background: var(--green); border: 0; border-radius: 50%; }
.pair-play i { width: 0; height: 0; margin-left: 3px; border-style: solid; border-width: 7px 0 7px 11px; border-color: transparent transparent transparent currentColor; }
.pair-play[data-playing=true] i { width: 12px; height: 14px; margin: 0; border: solid currentColor; border-width: 0 4px; }
.pick-song { display: flex; margin-left: auto; align-items: center; gap: 6px; min-height: 44px; cursor: pointer; font-size: 14px; white-space: nowrap; }
.pair-card .pick-song input { width: 17px; height: 17px; margin: 0; accent-color: var(--green); }
.pair-transport { display: flex; align-items: center; gap: 10px; margin-top: 9px; }
.pair-transport input.seek { flex: 1; width: 0; height: 28px; margin: 0; padding: 0; border: 0; background: transparent; accent-color: var(--green); }
.pair-transport span { font: 12px/1.4 ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--muted); white-space: nowrap; }
.pair-work .rating-set { margin-top: 25px; }
.rating-set legend { padding: 0; margin-bottom: 10px; font-size: 18px; font-weight: 650; }
.rating-options { display: grid; grid-template-columns: repeat(10,minmax(0,1fr)); gap: 6px; }
.rating-option { position: relative; cursor: pointer; }
.rating-option input, .visually-hidden { position: absolute; width: 1px !important; height: 1px; overflow: hidden; padding: 0 !important; margin: 0; clip-path: inset(50%); white-space: nowrap; }
.rating-option span { display: grid; place-items: center; height: 43px; border-radius: 6px; border: 1px solid var(--line); background: var(--surface); font-variant-numeric: tabular-nums; font-weight: 600; }
.rating-option input:checked + span { background: var(--green); color: white; border-color: var(--green); }
.rating-option input:focus-visible + span { outline: 3px solid #b66e35; outline-offset: 2px; }
.rating-hint { font-size: 13px; margin-top: 6px; color: var(--muted); }
#optional-reason { margin: 13px 0 16px; }
#optional-reason summary { display: list-item; width: fit-content; padding: 7px 0; color: var(--muted); cursor: pointer; font-size: 15px; }
#optional-reason textarea { margin-top: 5px; min-height: 60px; }
.pair-path { display: inline-block; margin: 0 0 20px; font-weight: 600; }
#submit-pair { min-width: 160px; }
#pair-receipt { margin-top: 22px; }
.pair-result { font-size: 20px; }
.pair-reason { margin-block: 14px; }
.pair-stat { padding-block: 11px; border-top: 1px solid var(--line); }
.pair-stat h3 { overflow-wrap: anywhere; }
.pair-stat p { margin-top: 4px; }
.pair-summary { padding-bottom: 20px; margin-bottom: 20px; border-bottom: 1px solid var(--line); }
.pair-summary:first-child { margin-top: 0; }
@media (max-width: 610px) {
  .pair-tracks { grid-template-columns: 1fr; gap: 10px; }
  .pair-card { padding: 11px 15px 6px; }
  .pair-transport { margin-top: 2px; }
  .pair-work .rating-set { margin-top: 19px; }
  .rating-options { grid-template-columns: repeat(5,minmax(0,1fr)); }
  #submit-pair { width: 100%; }
}
