/* Public pages and the dealer colour generator. No build step needed. */
:root {
  --brand: #c8102e; --brand-dark: #9e0c24; --ink: #1d1d1f; --muted: #6b6b70;
  --bg: #f6f5f3; --card: #ffffff; --line: #e4e2de; --ok: #1f7a3d; --warn: #9a5b00; --err: #b3261e;
  --radius: 14px;
}
@media (prefers-color-scheme: dark) {
  :root { --ink: #f2f2f2; --muted: #a5a5ab; --bg: #141416; --card: #1e1e21; --line: #333338; }
}
* { box-sizing: border-box; }
body { margin: 0; font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--ink); background: var(--bg); }
a { color: var(--brand); }
header.site { background: var(--card); border-bottom: 1px solid var(--line); }
header.site .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .75rem 16px; }
header.site img { height: 40px; display: block; }
header.site nav { display: flex; gap: 1rem; font-size: .95rem; }
.wrap { max-width: 960px; margin: 0 auto; padding: 0 16px; }
main { padding: 2rem 0 3rem; }
.narrow { max-width: 460px; margin: 0 auto; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; }
h1 { font-size: 1.6rem; line-height: 1.25; margin: 0 0 .75rem; }
h2 { font-size: 1.15rem; margin: 1.75rem 0 .5rem; }
p.lead { color: var(--muted); margin-top: 0; }
label { display: block; font-weight: 600; font-size: .9rem; margin: 1rem 0 .3rem; }
input, select, textarea { width: 100%; padding: .7rem .8rem; font: inherit; color: inherit; background: var(--bg); border: 1px solid var(--line); border-radius: 10px; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--brand); outline-offset: 1px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; width: 100%; margin-top: 1.25rem; padding: .8rem 1rem; font: inherit; font-weight: 600; color: #fff; background: var(--brand); border: 0; border-radius: 10px; cursor: pointer; text-decoration: none; }
.btn:hover { background: var(--brand-dark); }
.btn.secondary { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.alert { padding: .8rem 1rem; border-radius: 10px; margin-bottom: 1rem; font-size: .95rem; }
.alert.ok { background: color-mix(in srgb, var(--ok) 12%, transparent); color: var(--ok); }
.alert.err { background: color-mix(in srgb, var(--err) 12%, transparent); color: var(--err); }
.error { color: var(--err); font-size: .85rem; margin-top: .25rem; }
.muted { color: var(--muted); font-size: .9rem; }
.divider { display: flex; align-items: center; gap: .75rem; color: var(--muted); font-size: .85rem; margin: 1.25rem 0 0; }
.divider::before, .divider::after { content: ""; flex: 1; border-top: 1px solid var(--line); }
.hp { position: absolute; left: -9999px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1rem; }
@media (max-width: 560px) { .grid2 { grid-template-columns: 1fr; } header.site nav { gap: .6rem; font-size: .85rem; } }
.swatch { width: 100%; aspect-ratio: 3 / 1; border-radius: 12px; border: 1px solid var(--line); }
.chip { display: inline-block; width: 1rem; height: 1rem; border-radius: 50%; vertical-align: -3px; border: 1px solid var(--line); margin-right: .4rem; }
.sizes { display: flex; gap: .5rem; flex-wrap: wrap; margin: 1rem 0; }
.sizes button { flex: 1; min-width: 70px; padding: .6rem; font: inherit; font-weight: 600; border-radius: 10px; border: 1px solid var(--line); background: var(--card); color: var(--ink); cursor: pointer; }
.sizes button[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: #fff; }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th, td { text-align: left; padding: .55rem .4rem; border-bottom: 1px solid var(--line); }
th { color: var(--muted); font-weight: 600; font-size: .85rem; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
tfoot td { font-weight: 700; border-bottom: 0; }
.meta { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: .75rem; margin: 1rem 0; }
.meta div { background: var(--bg); border-radius: 10px; padding: .6rem .8rem; }
.meta span { display: block; color: var(--muted); font-size: .8rem; }
footer.site { color: var(--muted); font-size: .85rem; padding: 2rem 0; text-align: center; }
footer.site a { color: inherit; margin: 0 .5rem; }
.suggest { list-style: none; margin: .25rem 0 0; padding: 0; border: 1px solid var(--line); border-radius: 10px; background: var(--card); max-height: 240px; overflow: auto; }
.suggest li { padding: .5rem .8rem; cursor: pointer; }
.suggest li:hover, .suggest li[aria-selected="true"] { background: var(--bg); }
