:root {
  color-scheme: light;
  font-family: system-ui, sans-serif;
  color: #251e18;
  background: #f8f3e8;
}
body { margin: 0; }
.wrap { width: min(92%, 75rem); margin-inline: auto; }
header { background: #39241d; color: #fff8e9; padding: 2rem 0; border-bottom: 5px solid #ae512f; }
header a { color: inherit; }
h1 { font: bold clamp(2rem, 5vw, 3.5rem) Georgia, serif; margin: 1rem 0 .5rem; }
main { padding-block: 1.5rem 3rem; }
.filters { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); gap: 1rem; }
label { display: grid; gap: .4rem; font-weight: bold; }
input, select, button { font: inherit; padding: .65rem; border: 1px solid #796650; border-radius: .3rem; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 10rem), 1fr)); gap: 1rem; }
.card { display: flex; flex-direction: column; background: white; border: 1px solid #d5c5ae; border-radius: .4rem; overflow: hidden; color: inherit; text-decoration: none; }
.card:hover strong { text-decoration: underline; }
.cover { display: grid; place-items: center; aspect-ratio: 4 / 5; background: #eee4d4; color: #604538; }
.cover img { width: 100%; height: 100%; min-height: 0; object-fit: contain; }
.caption { padding: .7rem; overflow-wrap: anywhere; }
.caption small { display: block; margin-top: .35rem; color: #604538; }
button { margin-top: 1.25rem; background: #39241d; color: white; cursor: pointer; }
:focus-visible { outline: 3px solid #ba541d; outline-offset: 2px; }

/* Letterpress masthead and warm newsprint for the archive pages. */
:root {
  --ink: #211c18;
  --rust: #9f3323;
  --paper: #f8edd0;
  color: var(--ink);
  background: repeating-linear-gradient(0deg, #6f4a1b07 0 1px, transparent 1px 4px), #eee0bc;
}
header { background: var(--paper); color: var(--ink); border-block: 9px solid var(--rust); }
header a { font-weight: 750; text-underline-offset: .22em; }
.kicker {
  display: block;
  font: bold .82rem 'Courier New', monospace;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--rust);
}
h1 { font-family: Impact, 'Arial Black', Georgia, serif; line-height: 1; }
.library-header h1 { font-size: clamp(2.25rem, 8vw, 6rem); text-transform: uppercase; }
.library-header p { max-width: 46rem; }
.filters { border-block: 3px double var(--ink); padding-block: .8rem; }
input, select, button { border-radius: 0; }
.grid { gap: 1.15rem; }
.card { border: 1px solid var(--ink); border-radius: 0; box-shadow: 3px 3px 0 #211c1840; background: var(--paper); }
.card:hover { border-color: var(--rust); }
.cover { background: #302820; color: var(--paper); }
.caption { border-top: 3px solid var(--rust); }
.caption small { font-size: .76rem; }
button { background: var(--ink); }
#more { margin-top: 1.5rem; }

[hidden] { display: none !important; }
.filters input, .filters select { width: 100%; min-width: 0; box-sizing: border-box; }
.filters label { min-width: 0; }
.result-bar { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem 1rem; margin-bottom: .65rem; }
.result-bar button { margin: 0; }

.search-actions { display: flex; align-items: center; flex-wrap: wrap; gap: .65rem 1.25rem; padding-top: .75rem; }
.search-actions label { display: flex; align-items: center; }
.search-actions button { margin: 0; }

.refinements { display: flex; flex-wrap: wrap; gap: .65rem 1rem; margin-top: .75rem; }
.refinements label { display: flex; align-items: center; }
.refinements select { min-width: 0; max-width: 100%; }
