/* Gallery pages. Builds on /styles.css variables; no inline styles (CSP). */
.eyebrow a { color: inherit; text-decoration: none; }
.eyebrow a:hover { text-decoration: underline; }

.deck-head { padding: 64px 24px 24px; }
.deck-head h1 { max-width: none; }

main section { padding-top: 32px; }
main h2 { margin-top: 8px; }
main h3 { font-size: 18px; margin: 20px 0 8px; }
.cards .card h3 { margin: 0; }

.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 24px 0 0; }
.facts div { padding: 12px 14px; background: var(--surface); border: 1px solid var(--border); border-radius: 10px; }
.facts dt { font-size: 12px; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); }
.facts dd { margin: 4px 0 0; font-size: 18px; font-weight: 600; }
.facts.small { margin: 0; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.facts.small div { padding: 8px 10px; }
.facts.small dd { font-size: 15px; }

.toc { display: flex; flex-wrap: wrap; gap: 8px 18px; padding: 14px 0; border-bottom: 1px solid var(--border); font-weight: 500; }

.panel { padding: 18px 20px; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; }
.panel h3 { margin-top: 0; }
.panel p { margin: 0; }

table { width: 100%; border-collapse: collapse; margin: 12px 0; font-size: 15px; background: var(--surface); }
th, td { padding: 8px 10px; border: 1px solid var(--border); text-align: left; vertical-align: top; }
th { font-size: 13px; color: var(--muted); font-weight: 600; }
td:first-child { min-width: 9em; }
.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
tr.total td { font-weight: 600; }

ul.plain { padding-left: 18px; }
ul.plain li + li { margin-top: 6px; }
.warnings { list-style: none; padding: 0; display: grid; gap: 6px; }
.warnings li { padding: 8px 12px; border: 1px solid var(--border); border-left-width: 4px; border-radius: 6px; background: var(--surface); }
.warnings li.warning { border-left-color: #b7791f; }
.warnings li.error, .warnings li.failure { border-left-color: #c53030; }
.code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; color: var(--muted); margin-right: 6px; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 0.9em; }

.ok, .bad { font-size: 12px; font-weight: 600; padding: 1px 6px; border-radius: 999px; white-space: nowrap; }
.ok { background: #e3f1ea; color: #22543d; }
.bad { background: #fbe9e7; color: #9b2c2c; }
@media (prefers-color-scheme: dark) {
  .ok { background: #1f3a2e; color: #9ae6b4; }
  .bad { background: #43211f; color: #feb2b2; }
}

.stages { padding-left: 22px; }
.stages > li { padding: 4px 0 8px; }
.stages > li h3 { margin-top: 12px; }
.stages p { margin: 4px 0; }

details { margin: 8px 0; }
summary { cursor: pointer; font-weight: 500; }
dl.kv dt { font-weight: 600; margin-top: 8px; }
dl.kv dd { margin: 2px 0 0; }

.decklist { columns: 3 260px; column-gap: 28px; }
.decklist .group { break-inside: avoid; margin-bottom: 12px; }
.decklist h3 { margin-top: 4px; }
.decklist ul { list-style: none; margin: 0; padding: 0; font-size: 15px; }
.decklist li { padding: 1px 0; }
