/* Store pages on top of brand.css and app.css: item cards, the browse page with its filter column, the item page with its
   gallery, check results. Colours only from the brand tokens; no inline styles (strict CSP). */

/* item cards (brand .item-card): the card itself is not a link, its picture, title and publisher are */
.cards { margin: 0; }
.item-card { min-width: 0; }
.item-card .thumb { text-decoration: none; }
.item-card .thumb .icon.big, .item-visual .icon.big { width: 72px; height: 72px; border-radius: var(--r-md); background: var(--white); border: 1px solid var(--line); }
.item-card .thumb .icon.big svg, .item-visual .icon.big svg { width: 36px; height: 36px; }
.item-card .tags { gap: 8px; }
.item-card h3 { font-size: 17px; }
.item-card h3 a { color: var(--ink); text-decoration: none; }
.item-card h3 a:hover { color: var(--blue-dark); text-decoration: underline; }
.item-card .summary { margin: 0; font-size: 14px; color: var(--ink-2); overflow-wrap: anywhere; }
.item-card .meta a { color: var(--link); font-weight: 600; text-decoration: none; }
.item-card .meta a:hover { text-decoration: underline; }

/* browse: filters at the left, results at the right */
.browse { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 32px; align-items: start; }
.filter-col h2 { font: 700 12px var(--text); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); margin: 22px 0 6px; }
.filter-col form .btn { width: 100%; }
.facets { list-style: none; margin: 0; padding: 0; display: grid; gap: 1px; font-size: 14px; }
.facets a { display: flex; justify-content: space-between; gap: 8px; padding: 6px 10px; border-radius: var(--r-sm); color: var(--ink); text-decoration: none; }
.facets a:hover { background: var(--soft); }
.facets a[aria-current="page"] { background: var(--tint); color: var(--blue-dark); font-weight: 600; }
.facets .n { color: var(--ink-2); font-variant-numeric: tabular-nums; }
.sort-bar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: flex-end; margin-bottom: 14px; }
.sort-bar > .muted { margin-right: auto; font-size: 14px; }
.sort-bar .sort { display: inline-flex; gap: 8px; align-items: center; font-weight: 500; }
.results .pager { margin-top: 20px; }

/* item page: pictures, or the area's icon when there are none */
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin-bottom: 20px; }
.gallery figure { margin: 0; min-width: 0; }
.gallery img { display: block; width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top left; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--soft); }
.gallery a:hover img { border-color: var(--blue); }
.gallery.small { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
.gallery.small form { margin-top: 6px; }
.item-visual { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; min-height: 200px; margin-bottom: 20px;
  border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--soft); color: var(--ink-2); font-weight: 600; font-size: 14px; }
.prose { max-width: 75ch; }
.btn.block { width: 100%; }
.hero .hero-meta .badge.ok { background: var(--ok-bg); }

/* review: check results */
.item-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 20px; align-items: start; }
.item-layout section { margin-bottom: 14px; }
.checks-list { list-style: none; padding: 0; margin: 4px 0; font-size: 14px; }
.checks-list li { padding: 3px 0; }
.narrow-card { max-width: 640px; }

@media (max-width: 900px) {
  .browse { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .browse .filter-col { order: 2; border-top: 1px solid var(--line); padding-top: 8px; }
  .item-layout { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .item-card .thumb.no-pic { aspect-ratio: 16 / 6; }
}
