.os-preview { padding-block: 2rem 4rem; }
.os-preview h1 { color: #79132a; font-size: clamp(1.8rem, 4vw, 3rem); line-height: 1.15; margin-bottom: .6rem; }
.os-preview p { max-width: 85ch; line-height: 1.6; }
.os-warning { background: #faf2e7; border-inline-start: 4px solid #79132a; padding: 1rem; border-radius: .25rem; }
.os-intro { color: #4f4846; margin-bottom: 1.25rem; }
.os-fallback { font-size: .88rem; margin-block: .75rem 1.25rem; }
.os-fallback a { color: #625a58; }
.os-form { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.1rem; padding: 1.25rem; background: #f6f4f1; border: 1px solid #e4ded8; border-radius: .8rem; box-shadow: 0 8px 24px rgba(38,32,32,.06); }
.os-form label { display: flex; flex-direction: column; gap: .45rem; min-width: 0; position: relative; }
.os-form input { width: 100%; min-width: 0; box-sizing: border-box; min-height: 48px; padding: .7rem .8rem; border: 1px solid #8c8585; border-radius: .35rem; background: white; color: #262020; font: inherit; }
.os-form input:focus { border-color: #79132a; box-shadow: 0 0 0 3px rgba(121,19,42,.15); outline: none; }
.os-form button { grid-column: 1 / -1; justify-self: start; min-height: 48px; padding: .7rem 1.5rem; background: #79132a; color: white; border: 0; border-radius: .35rem; font: inherit; cursor: pointer; }
.os-form button:hover { background: #5e0e21; }
.os-preview :is(input, button, a):focus-visible { outline: 3px solid #1b639b; outline-offset: 4px; }
.os-field-help, .os-suggest-status { color: #625a58; font-size: .82rem; min-height: 1.1em; }
.os-suggestions { position: absolute; z-index: 5; inset-inline: 0; top: calc(100% + 3.4rem); margin: 0; padding: .25rem; list-style: none; background: white; border: 1px solid #c7c0bc; border-radius: .35rem; box-shadow: 0 10px 24px rgba(38,32,32,.16); max-height: 16rem; overflow: auto; }
.os-suggestions li { padding: .6rem .7rem; border-radius: .25rem; cursor: pointer; }
.os-suggestions li:hover, .os-suggestions li[aria-selected="true"] { background: #f3e7ea; color: #79132a; }
.os-book { display: grid; grid-template-columns: 100px minmax(0, 1fr); gap: 1.5rem; padding: 1.5rem 0; border-top: 1px solid #ded8d3; }
.os-book img { width: 100%; height: auto; max-height: 180px; object-fit: contain; align-self: start; font-size: .75rem; }
.os-book h2 { margin: 0 0 1rem; font-size: clamp(1.15rem, 2vw, 1.5rem); line-height: 1.4; overflow-wrap: anywhere; }
.os-book a { color: #79132a; text-underline-offset: .2em; }
.os-book dl { display: grid; grid-template-columns: 10rem minmax(0, 1fr); gap: .3rem 1rem; margin: 0; }
.os-book dt { color: #625a58; }
.os-book dd { margin: 0; overflow-wrap: anywhere; }
.os-pagination { margin-block: 1.5rem; padding-top: 1rem; border-top: 1px solid #ded8d3; }
.os-pagination form { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .75rem; }
.os-pagination button { min-height: 44px; padding: .65rem 1rem; border: 1px solid #79132a; border-radius: .35rem; background: #79132a; color: white; font: inherit; cursor: pointer; }
.os-pagination button:disabled { color: #625a58; border-color: #c7c0bc; background: #f6f4f1; cursor: default; }
.os-pagination span { font-weight: 600; }
.os-note { color: #625a58; font-size: .9rem; }
#os-results { scroll-margin-top: 1rem; }
@media (max-width: 760px) {
  .os-form { grid-template-columns: minmax(0, 1fr); }
  .os-form button { grid-column: auto; width: 100%; }
  .os-suggestions { top: calc(100% + 3.4rem); }
  .os-book { grid-template-columns: 70px minmax(0, 1fr); gap: 1rem; }
  .os-book dl { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .os-book dd { margin-bottom: .7rem; }
}
