/* amznbk: one stylesheet for the home page and the viewer.
   Palette: cool paper, navy ink, pencil grey, a teal for actions, and one highlighter yellow that is used
   for exactly one thing everywhere: the price that wins. Fonts are served from this site (no outside requests). */
@font-face{font-family:"Atkinson Hyperlegible";font-weight:400;font-display:swap;src:url(fonts/atkinson-hyperlegible-latin-400-normal.woff2) format("woff2");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:"Atkinson Hyperlegible";font-weight:700;font-display:swap;src:url(fonts/atkinson-hyperlegible-latin-700-normal.woff2) format("woff2");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:"Atkinson Hyperlegible";font-weight:400;font-display:swap;src:url(fonts/atkinson-hyperlegible-latin-ext-400-normal.woff2) format("woff2");unicode-range:U+0100-02AF,U+1E00-1EFF,U+2020,U+20A0-20AB,U+20AD-20CF,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:"Atkinson Hyperlegible";font-weight:700;font-display:swap;src:url(fonts/atkinson-hyperlegible-latin-ext-700-normal.woff2) format("woff2");unicode-range:U+0100-02AF,U+1E00-1EFF,U+2020,U+20A0-20AB,U+20AD-20CF,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:"Literata";font-weight:600;font-display:swap;src:url(fonts/literata-latin-600-normal.woff2) format("woff2")}

:root{--paper:#fbfcfd;--ink:#14213d;--pencil:#55657c;--teal:#0f766e;--teal-dark:#0b5a54;--marker:#ffe27a;--rule:#d5dde6;--wash:#eef2f6;--warn:#8a4b00;
  --body:"Atkinson Hyperlegible",Verdana,"Segoe UI",system-ui,sans-serif;--display:"Literata","Iowan Old Style",Palatino,Georgia,serif}
*{box-sizing:border-box}
html{font-size:112.5%;-webkit-text-size-adjust:100%}
body{margin:0;background:var(--paper);color:var(--ink);font:1rem/1.55 var(--body)}
a{color:#0b5f8a;text-underline-offset:.15em}
:focus-visible{outline:3px solid var(--ink);outline-offset:2px;border-radius:4px}
[hidden]{display:none!important}
.wrap{max-width:68rem;margin:0 auto;padding:0 1.25rem}
.top{display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:1.1rem 0}
.brand{font:600 1.45rem/1 var(--display);color:var(--ink);text-decoration:none;letter-spacing:-.01em}
.top select{font:inherit;font-size:.9rem;padding:.3rem .5rem;border:1px solid var(--rule);border-radius:6px;background:#fff;color:var(--ink)}
h1{font:600 clamp(2rem,4.6vw,3.25rem)/1.12 var(--display);letter-spacing:-.015em;margin:0 0 1rem;max-width:17em}
h2{font:600 1.6rem/1.2 var(--display);margin:0 0 .9rem}
p{margin:0 0 1rem;max-width:38em}
.lead{font-size:1.15rem;color:#2b3a55}
.small{font-size:.9rem;color:var(--pencil)}
.btn{display:inline-flex;align-items:center;justify-content:center;gap:.5rem;font:700 1.15rem/1.2 var(--body);padding:.95rem 1.6rem;border-radius:10px;border:2px solid var(--teal);
  background:var(--teal);color:#fff;text-decoration:none;cursor:pointer;min-height:3.4rem}
.btn:hover{background:var(--teal-dark);border-color:var(--teal-dark)}
.btn.quiet{background:transparent;color:var(--teal-dark);font-weight:400;font-size:1rem;min-height:2.6rem;padding:.5rem 1rem;border-width:1.5px}
.btn.quiet:hover{background:var(--wash)}
.btn:disabled{opacity:.5;cursor:default}
mark{background:var(--marker);color:inherit;padding:0 .2em;border-radius:3px}

/* ---- home: the shelf. One book, several editions, the cheapest one pulled out. ---- */
.hero{display:grid;grid-template-columns:minmax(0,1.05fr) minmax(0,.95fr);gap:3rem;align-items:end;padding:2.5rem 0 3.5rem}
.shelf{position:relative;padding-top:2.2rem}
.spines{display:flex;align-items:flex-end;gap:5px;height:17rem;border-bottom:10px solid var(--ink);padding:0 .75rem}
.spine{flex:1 1 0;max-width:3.6rem;border-radius:3px 3px 0 0;position:relative;display:flex;align-items:flex-end;justify-content:center;padding-bottom:.6rem;color:#fff}
.spine b{writing-mode:vertical-rl;transform:rotate(180deg);font:700 .95rem/1 var(--body);letter-spacing:.02em;white-space:nowrap}
.spine span{position:absolute;top:.5rem;left:50%;transform:translateX(-50%);writing-mode:vertical-rl;font-size:.72rem;opacity:.85;white-space:nowrap}
.spine.win{transform:translateY(-1.6rem);box-shadow:0 1.6rem 0 -1.35rem rgba(20,33,61,.18)}
.spine.win b{background:var(--marker);color:var(--ink);padding:.45rem .12rem;border-radius:3px}
.shelf figcaption{margin-top:.8rem;font-size:.9rem;color:var(--pencil)}
@media (prefers-reduced-motion:no-preference){.spine.win{animation:pull .9s .5s cubic-bezier(.2,.8,.2,1) both}@keyframes pull{from{transform:translateY(0);box-shadow:none}}}
.steps{list-style:none;counter-reset:s;margin:0;padding:0;display:grid;gap:1.1rem;max-width:40em}
.steps li{counter-increment:s;display:grid;grid-template-columns:2.6rem 1fr;gap:.9rem;align-items:start}
.steps li::before{content:counter(s);font:600 1.9rem/1 var(--display);color:var(--teal-dark)}
.band{border-top:1px solid var(--rule);padding:3rem 0}
.two{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:2.5rem 3rem}
dl.facts{margin:0;display:grid;gap:1.2rem}
dl.facts dt{font-weight:700}
dl.facts dd{margin:.15rem 0 0;color:#2b3a55;max-width:34em}
details.q{border-bottom:1px solid var(--rule);padding:.9rem 0;max-width:44em}
details.q summary{cursor:pointer;font-weight:700}
details.q p{margin:.6rem 0 0}
code,.code{font:.85rem/1.4 ui-monospace,Menlo,Consolas,monospace;background:var(--wash);padding:.1rem .35rem;border-radius:4px;word-break:break-all}
footer{border-top:1px solid var(--rule);padding:1.6rem 0 2.4rem;font-size:.85rem;color:var(--pencil)}
footer p{max-width:none;margin:0 0 .3rem}

/* ---- viewer ---- */
.card{border:1.5px solid var(--rule);border-radius:14px;background:#fff;padding:1.6rem 1.75rem;margin:0 0 1.5rem}
.card.compact h1{font-size:1.5rem;margin-bottom:.2rem}.card.compact .lead{display:none}.card.compact{padding-top:1.1rem;padding-bottom:1.1rem}
.go{display:flex;flex-wrap:wrap;gap:.9rem;align-items:end;margin-top:1.2rem}
.go label{display:grid;gap:.25rem;font-size:.9rem;color:var(--pencil)}
.go select{font:inherit;padding:.75rem .7rem;min-height:3.4rem;border:1.5px solid var(--rule);border-radius:10px;background:#fff;color:var(--ink);max-width:100%}
textarea{font:inherit;width:100%;max-width:44rem;padding:.6rem .7rem;border:1.5px solid var(--rule);border-radius:10px;color:var(--ink);background:#fff}
.bar select{font:inherit;padding:.5rem .6rem;border:1.5px solid var(--rule);border-radius:8px;background:#fff;color:var(--ink);max-width:14rem}
.note{background:#fff8e1;border:1.5px solid #e8c766;border-radius:10px;padding:.9rem 1.1rem;margin-top:1.1rem;color:#4a3500}
.note p{margin:0 0 .7rem}.note p:last-child{margin:0}
.progress{display:grid;gap:.7rem}
.meter{height:.8rem;background:var(--wash);border-radius:.4rem;overflow:hidden}
.meter i{display:block;height:100%;width:0;background:var(--teal);transition:width .5s}
.meter.busy i{width:35%!important;animation:slide 1.6s infinite ease-in-out}
@keyframes slide{0%{margin-left:-35%}100%{margin-left:100%}}
@media (prefers-reduced-motion:reduce){.meter.busy i{animation:none;width:100%!important;opacity:.4}}
.sum{font:600 1.35rem/1.3 var(--display);margin:0 0 .3rem;max-width:none}
.bar{display:flex;flex-wrap:wrap;gap:.7rem 1rem;align-items:center;margin:1.2rem 0 .8rem}
.tabs{display:flex;flex-wrap:wrap;gap:.3rem}
.tabs button{font:inherit;padding:.5rem .9rem;border:1.5px solid var(--rule);background:#fff;color:var(--ink);border-radius:8px;cursor:pointer}
.tabs button[aria-selected=true]{background:var(--ink);border-color:var(--ink);color:#fff}
.bar input[type=search]{font:inherit;padding:.5rem .7rem;border:1.5px solid var(--rule);border-radius:8px;min-width:12rem;flex:1 1 12rem;max-width:22rem;color:var(--ink);background:#fff}
.bar label.chk{display:flex;gap:.4rem;align-items:center;font-size:.95rem}
.bar .dl{margin-inline-start:auto;display:flex;gap:.5rem;flex-wrap:wrap}
.tablewrap{overflow:auto;border:1.5px solid var(--rule);border-radius:10px;background:#fff;max-height:75vh}
table{border-collapse:collapse;width:100%;font-size:.92rem}
th,td{padding:.55rem .7rem;text-align:start;border-bottom:1px solid var(--wash);vertical-align:top}
td{white-space:nowrap;max-width:20rem;overflow:hidden;text-overflow:ellipsis}
th{position:sticky;top:0;background:var(--wash);z-index:1;white-space:nowrap;padding:0}
th button{all:unset;display:block;width:100%;box-sizing:border-box;padding:.6rem .7rem;cursor:pointer;font-weight:700}
th button:focus-visible{outline:3px solid var(--ink);outline-offset:-3px}
th[aria-sort=ascending] button::after{content:" ▲";font-size:.7em}
th[aria-sort=descending] button::after{content:" ▼";font-size:.7em}
td.n,th.n{text-align:end;white-space:nowrap;font-variant-numeric:tabular-nums}
td:first-child{min-width:16rem;max-width:26rem;font-weight:700;white-space:normal}
td.win{font-weight:700}
tbody tr:hover{background:#f6f9fb}
.under{display:flex;flex-wrap:wrap;gap:1rem;align-items:center;justify-content:space-between;margin:.8rem 0 0}
.drop{outline:3px dashed var(--teal);outline-offset:-10px}

@media (max-width:30rem){.spine span{display:none}}
@media (max-width:52rem){.hero{grid-template-columns:1fr;gap:2rem;padding-top:1.5rem}.two{grid-template-columns:1fr}.spines{height:13rem}.bar .dl{margin-inline-start:0}.card{padding:1.2rem}}
