:root {
  color-scheme: light;
  --ink: #172b27;
  --green: #164c3e;
  --paper: #faf9f4;
  --line: #c6cfc5;
  --accent: #ff895e;
  --muted: #485e54;
  font: 100%/1.55 "DM Sans", system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; }
.frame { max-width: 76rem; padding-inline: clamp(1rem, 4vw, 4rem); margin: auto; }
.masthead { background: var(--green); color: white; }
.head-inner, .toolbar, .section-head, .import-strip, .actions, .tabs, nav, .filters { display: flex; align-items: center; flex-wrap: wrap; gap: .8rem; }
.head-inner { min-height: 4.6rem; justify-content: space-between; }
.brand { font: bold 2rem/1 Georgia, serif; letter-spacing: -.06em; display: flex; align-items: center; gap: .6rem; }
.brand i { width: 1.6rem; aspect-ratio: 1; border: .34rem double var(--accent); border-radius: 50%; background: radial-gradient(circle, var(--accent) 0 17%, transparent 19%); }
.privacy { font-size: .88rem; color: #e4eae1; }
.skip { position: absolute; transform: translateY(-130%); padding: .7rem; background: white; z-index: 2; }
.skip:focus { transform: translateY(0); }
h1, h2, h3, p { margin: 0; }
h1, h2, .large { font-family: "DM Serif Text", Georgia, serif; font-weight: 500; }
h1 { font-size: clamp(2.7rem, 6vw, 5rem); letter-spacing: -.06em; line-height: 1.05; margin: 1.4rem 0 .65rem; }
h2 { font-size: clamp(1.75rem, 3.4vw, 2.35rem); letter-spacing: -.045em; line-height: 1.15; }
h3 { font-size: 1.1rem; margin: .8rem 0 .25rem; line-height: 1.35; }
p { max-width: 74ch; margin-block: .65rem; }
a { color: var(--green); text-decoration-thickness: .075em; text-underline-offset: .17em; }
button, input, select { font: inherit; color: inherit; }
button, input::file-selector-button { background: var(--paper); border: 1px solid #9baea2; border-radius: .4rem; cursor: pointer; padding: .55rem .85rem; font-weight: 600; }
button:hover:enabled, a:hover { color: #704022; }
button:hover:enabled { background-color: #f5eadc; }
button:disabled { opacity: .64; cursor: default; }
:focus-visible { outline: .2rem solid #b34519; outline-offset: .2rem; }
label { display: inline-grid; gap: .25rem; font-size: .9rem; font-weight: 650; }
select, input[type=search] { border: 1px solid #93a79a; border-radius: .35rem; background-color: #fff; padding: .58rem .7rem; max-width: 100%; }
select { min-width: 6rem; appearance: none; padding-right: 2.2rem; background-image: linear-gradient(45deg, transparent 50%, var(--green) 51%), linear-gradient(135deg, var(--green) 50%, transparent 51%); background-size: .32rem .32rem; background-repeat: no-repeat; background-position: right 1rem center, right .71rem center; }
.welcome { display: grid; grid-template-columns: 1.1fr 1fr; align-items: center; gap: 2rem; padding: clamp(2rem, 5vw, 4.5rem) 0 2rem; }
.intro h1 { font-size: clamp(4rem, 7.4vw, 6.9rem); margin: 0; line-height: .97; }
.intro em { color: var(--green); font-weight: 400; }
.intro p { max-width: 34ch; margin-top: 1.3rem; font-size: 1.15rem; }
.art { position: relative; isolation: isolate; overflow: hidden; min-height: 14rem; aspect-ratio: 1.85; background: #e3e7d7; border-radius: .65rem; }
.record, .sleeve { position: absolute; aspect-ratio: 1; width: 53%; top: 50%; }
.record { right: 6%; transform: translateY(-50%); border-radius: 50%; background: radial-gradient(circle, #e3e7d7 0 2%, #c85835 2.4% 22%, transparent 22.5%), repeating-radial-gradient(circle, #1f332d 0 2px, #37483e 3px, #1d3029 4px); box-shadow: .25rem .4rem .75rem #20312244; }
.sleeve { left: 9%; transform: translateY(-50%) rotate(-7deg); background: #fb8658; box-shadow: .2rem .6rem 1rem #20312240; overflow: hidden; }
.print { position: absolute; inset: 9%; border: 1px solid #37362b; background: repeating-radial-gradient(ellipse at 0 100%, #143d31 0 5%, transparent 5.4% 10%); }
.import-strip { background: #e8eee5; padding: 1.3rem clamp(1rem, 2.2vw, 2rem); border: 1px solid var(--line); border-radius: .5rem; justify-content: space-between; }
.import-strip label { font-size: 1.24rem; }
small { display: block; font-size: .89rem; color: var(--muted); }
input[type=file] { width: min(100%, 20rem); font-size: .94rem; }
input::file-selector-button { background: var(--green); color: white; margin-right: .7rem; font: inherit; }
#status { color: var(--muted); }
#export-guide { margin: 2.3rem 0 3rem; }
.steps { list-style: decimal-leading-zero; display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; margin: 1.3rem 0; padding: 0; }
.steps li { border-top: 1px solid var(--line); padding: .8rem 0 0; list-style-position: inside; }
.steps li::marker { color: var(--green); font: .94rem ui-monospace, monospace; }
.steps h3 { margin-top: .35rem; }
.steps p { margin: .4rem 0; color: var(--muted); }
body:has(#workspace:not([hidden])) .import-strip { margin-top: 1.25rem; }
.toolbar { justify-content: space-between; padding: 1rem 0; border-bottom: 1px solid var(--line); }
.toolbar label { max-width: 100%; }
nav, .tabs { gap: .3rem; }
nav button, .tabs button { background: transparent; border-color: transparent; }
button[aria-current=page], button[aria-pressed=true] { color: white; background: var(--green); }
#view { margin-bottom: 4rem; overflow-wrap: anywhere; }
#view[aria-busy=true] { visibility: hidden; }
#view:focus { outline: none; }
#view:focus-visible > h1:first-child { text-decoration: underline; text-decoration-color: var(--accent); }
.coverage, .result-count { color: var(--muted); }
.metrics { display: grid; grid-template-columns: 1.5fr repeat(3, 1fr); background: var(--green); color: white; border-radius: .65rem; padding: clamp(1rem, 2.7vw, 2rem); gap: 1rem; }
.metrics dt { color: #dce7da; font-size: .92rem; }
.metrics dd, .large { font: 500 clamp(1.55rem, 3.4vw, 2.8rem)/1.2 Georgia, serif; letter-spacing: -.05em; margin: .45rem 0 0; }
details { margin: 1rem 0; }
summary { color: var(--green); font-weight: 600; cursor: pointer; }
.paper { padding: clamp(1rem, 2.3vw, 1.8rem); margin-block: 1.1rem; border: 1px solid var(--line); border-radius: .6rem; background: #fffefa; min-width: 0; }
.section-head { justify-content: space-between; }
.chart { display: flex; overflow-x: auto; padding: .5rem .25rem; gap: .4rem; }
.bar { flex: 1 0 3.6rem; min-width: 0; padding: .3rem; border: 0; border-radius: .2rem; text-align: center; background: transparent; }
.bar small { min-height: 3.5em; font-size: .77rem; font-weight: 450; }
.bar b { display: block; margin: .25rem 0; }
.well { display: flex; height: 5.5rem; align-items: end; background: #edf1e8; border-bottom: 1px solid var(--line); }
.well i { width: 100%; background: #408165; min-height: 0; }
.bar[data-availability=recorded] i { min-height: 3px; }
.bar[data-availability=outside] .well { background: repeating-linear-gradient(-45deg, transparent 0 4px, #e1e5df 4px 5px); }
.columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.columns .paper { margin: 0; }
.rows { padding: 0; list-style: none; margin: .8rem 0; }
.rows li { border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: .8rem; padding: .8rem 0; }
.rows li > div { min-width: 0; }
.rows li > small { text-align: right; }
.rows li button { flex-shrink: 0; font-size: .86rem; }
.filters, .actions { margin: 1rem 0; }
.chapter { border-top: .45rem solid var(--accent); }
.chapter > h2 { margin: .6rem 0 1.2rem; }
[data-benchmark-royalty] { margin-top: 1.5rem; border-top: 1px solid var(--line); padding-top: 1.5rem; }
[data-benchmark-royalty=citation] { background: #f3ecdf; padding: 1.4rem; }
@media (max-width: 720px) {
  .columns, .steps { grid-template-columns: 1fr; gap: .85rem; }
  .welcome { gap: .75rem; grid-template-columns: 1.15fr 1fr; }
  .intro h1 { font-size: clamp(2.6rem, 8.5vw, 4.5rem); }
  .intro p { font-size: 1rem; }
  .art { min-height: 0; aspect-ratio: 1; }
  .record, .sleeve { width: 65%; }
  .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .toolbar { align-items: start; }
  .bar { flex-basis: 4rem; }
  .head-inner { min-height: 3.7rem; }
  .rows li { flex-wrap: wrap; }
  .rows li > small { text-align: left; }
}
@media (max-width: 400px) {
  .privacy { font-size: .79rem; }
  main { padding-inline: 1rem; }
  .toolbar, .filters { gap: .5rem; }
}

.rank { font-variant-numeric: tabular-nums; color: var(--muted); }
.rows li:has(.rank) > div { flex: 1; }
.bar:disabled { opacity: 1; }
