/* Static stylesheet for the crawlable card gallery (/cards/**). Deliberately
   plain CSS, not Tailwind — these pages are generated by build-card-gallery.mjs
   outside Vite's build pipeline, so they can't reference the app's
   content-hashed CSS bundle. Hand-tuned to match the main site's palette.
   Copied verbatim to public/cards/gallery.css by build-card-gallery.mjs. */

* { box-sizing: border-box; }
html { color-scheme: dark; }
body {
  margin: 0;
  background: #0d0d0d;
  color: #d6d3d1;
  font-family: 'Inter', system-ui, sans-serif;
  line-height: 1.5;
}
a { color: inherit; }
.font-display { font-family: 'Cinzel Decorative', serif; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 1.25rem; }

header.site {
  position: sticky; top: 0; z-index: 20;
  background: rgba(13,13,13,0.9); backdrop-filter: blur(6px);
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
header.site .bar { display: flex; align-items: center; justify-content: space-between; padding: 0.9rem 0; }
header.site .brand { display: flex; align-items: center; gap: 0.5rem; text-decoration: none; font-size: 0.95rem; color: #f5f5f4; }
header.site .brand b { color: #ef4444; font-weight: 800; }
header.site nav { display: flex; gap: 1.5rem; font-size: 0.85rem; }
header.site nav a { text-decoration: none; color: #a8a29e; transition: color 0.15s; }
header.site nav a:hover, header.site nav a.is-current { color: #fff; }
header.site .cta {
  background: linear-gradient(135deg, #dc2626, #7f1d1d);
  color: #fff; padding: 0.55rem 1rem; border-radius: 0.5rem;
  text-decoration: none; font-weight: 700; font-size: 0.75rem;
  text-transform: uppercase; letter-spacing: 0.04em;
}

main { padding: 2.5rem 0 4rem; }

.breadcrumb { font-size: 0.75rem; color: #78716c; margin-bottom: 1rem; }
.breadcrumb a { text-decoration: none; color: #a8a29e; }
.breadcrumb a:hover { color: #fff; }

h1.page-title { font-size: 1.9rem; color: #fafaf9; margin: 0 0 0.6rem; }
p.lede { color: #a8a29e; max-width: 42rem; margin: 0 0 1.75rem; font-size: 0.95rem; }

.filters { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1.75rem; }
.filters button {
  font: inherit; cursor: pointer; font-size: 0.75rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.03em;
  background: rgba(255,255,255,0.03); color: #a8a29e;
  border: 1px solid #292524; border-radius: 999px; padding: 0.4rem 0.9rem;
  transition: all 0.15s;
}
.filters button:hover { border-color: #57534e; color: #fff; }
.filters button.is-active { background: #7f1d1d; border-color: #991b1b; color: #fff; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 0.9rem; }
.tile {
  display: block; text-decoration: none; color: inherit;
  background: rgba(20,18,17,0.9); border: 1px solid #292524; border-left: 3px solid var(--accent, #57534e);
  border-radius: 0.6rem; padding: 0.8rem; transition: transform 0.12s, border-color 0.12s;
}
.tile:hover { transform: translateY(-2px); border-color: #57534e; border-left-color: var(--accent, #78716c); }
.tile .row1 { display: flex; justify-content: space-between; align-items: baseline; gap: 0.5rem; margin-bottom: 0.3rem; }
.tile .cost {
  display: inline-flex; align-items: center; justify-content: center;
  width: 1.4rem; height: 1.4rem; border-radius: 999px; background: #1c1917;
  border: 1px solid #44403c; font-size: 0.7rem; font-weight: 800; color: #fff; flex-shrink: 0;
}
.tile img.art { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 0.4rem; margin-bottom: 0.5rem; background: #1c1917; }
.tile .name { font-weight: 700; font-size: 0.9rem; color: #fafaf9; }
.tile .meta { font-size: 0.65rem; text-transform: uppercase; letter-spacing: 0.04em; color: #78716c; margin-bottom: 0.35rem; }
.tile .stat { font-size: 0.7rem; font-weight: 700; color: var(--accent, #a8a29e); }
.tile .snippet { font-size: 0.75rem; color: #a8a29e; margin: 0.3rem 0 0; }
.tile.is-hidden { display: none; }

.badge {
  display: inline-block; font-size: 0.62rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.04em; padding: 0.15rem 0.5rem; border-radius: 999px;
  background: rgba(255,255,255,0.06); color: #d6d3d1; margin: 0 0.3rem 0.3rem 0;
}

.detail-hero { display: grid; grid-template-columns: 240px 1fr; gap: 2rem; margin-bottom: 2rem; }
.detail-hero img.art { width: 100%; border-radius: 0.75rem; border: 1px solid #292524; background: #1c1917; }
.detail-hero .stats { display: flex; gap: 1.5rem; margin: 1rem 0; }
.detail-hero .stats div { text-align: center; }
.detail-hero .stats .n { font-size: 1.5rem; font-weight: 800; color: #fff; display: block; }
.detail-hero .stats .l { font-size: 0.65rem; text-transform: uppercase; letter-spacing: 0.05em; color: #78716c; }
.rules-text { background: rgba(255,255,255,0.03); border: 1px solid #292524; border-radius: 0.6rem; padding: 1rem 1.25rem; margin: 1rem 0; font-size: 0.95rem; }
.quote { font-style: italic; color: #78716c; margin: 0.75rem 0 0; }
.keyword-list { margin: 1rem 0; padding: 0; list-style: none; }
.keyword-list li { margin-bottom: 0.5rem; font-size: 0.85rem; }
.keyword-list b { color: #fca5a5; text-transform: capitalize; }

section.identity {
  background: rgba(255,255,255,0.02); border: 1px solid #292524; border-radius: 0.75rem;
  padding: 1.25rem 1.5rem; margin: 2rem 0;
}
section.identity h2 { font-size: 1rem; margin: 0 0 0.4rem; color: #fafaf9; }
section.identity p { margin: 0; font-size: 0.85rem; color: #a8a29e; }

.related h2 { font-size: 1rem; color: #fafaf9; }
.related-links { display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; font-size: 0.8rem; }
.related-links a { text-decoration: none; color: #a8a29e; }
.related-links a:hover { color: #fff; text-decoration: underline; }

.back-link { display: inline-block; margin-top: 2rem; font-size: 0.85rem; color: #a8a29e; text-decoration: none; }
.back-link:hover { color: #fff; }

footer.site { border-top: 1px solid rgba(255,255,255,0.06); padding: 2rem 0; margin-top: 3rem; }
footer.site p { font-size: 0.75rem; color: #57534e; margin: 0; }
footer.site a { color: #78716c; text-decoration: none; }
footer.site a:hover { color: #a8a29e; }

@media (max-width: 640px) {
  header.site nav { display: none; }
  .detail-hero { grid-template-columns: 1fr; }
  .detail-hero img.art { max-width: 220px; margin: 0 auto; }
}
