:root {
  color-scheme: light;
  --paper: #F4F4F1;
  --paper-elevated: #FFFFFF;
  --paper-dim: #EAEAE5;
  --ink: #15181A;
  --ink-muted: #6B6F68;
  --felt: #1C6B4E;
  --felt-deep: #103E2C;
  --brass: #8F6A12;
  --rule: #DDDDD7;
  --diamond: #C0C6B9;
}

* { box-sizing: border-box; }

html, body { background: var(--paper); margin: 0; }

body {
  color: var(--ink);
  font-family: "Work Sans", -apple-system, "Segoe UI", sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.display {
  font-family: "Bebas Neue", "Arial Narrow", sans-serif;
  letter-spacing: 0.02em;
  text-wrap: balance;
}

.mono {
  font-family: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
  font-variant-numeric: tabular-nums;
}

a { color: inherit; }
:focus-visible { outline: 2px solid var(--felt); outline-offset: 2px; }

/* ---------- diamond rule ---------- */
.diamond-rule {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2.5rem;
  padding: 1.9rem 0;
}
.diamond-rule::before,
.diamond-rule::after {
  content: "";
  height: 1px;
  flex: 1;
  max-width: 9rem;
  background: var(--rule);
}
.diamond-rule .marks {
  display: flex;
  gap: 0.6rem;
}
.diamond-rule .marks span {
  width: 7px;
  height: 7px;
  background: var(--diamond);
  transform: rotate(45deg);
  display: block;
}

/* ---------- header ---------- */
header {
  max-width: 68rem;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 0;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.wordmark {
  font-family: "Bebas Neue", sans-serif;
  font-size: 1.4rem;
  letter-spacing: 0.06em;
}
.wordmark .ball {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 50%;
  background: #16171A;
  color: #fff;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.65rem;
  margin-right: 0.5rem;
  vertical-align: middle;
  position: relative;
  top: -1px;
  box-shadow: inset 0 0 0 3px rgba(255,255,255,0.16);
}
nav.tag {
  font-size: 0.78rem;
  color: var(--ink-muted);
  letter-spacing: 0.02em;
}

/* ---------- hero ---------- */
.hero {
  position: relative;
  max-width: 68rem;
  margin: 0 auto;
  padding: 2.75rem 1.5rem 1.5rem;
  overflow: hidden;
}
.hero-diagram {
  position: absolute;
  top: -1rem;
  right: -1rem;
  width: min(30rem, 60%);
  height: auto;
  pointer-events: none;
  z-index: 0;
}
.hero-content { position: relative; z-index: 1; }
.hero h1 {
  font-size: clamp(2.7rem, 6.4vw, 4.6rem);
  line-height: 0.95;
  margin: 0 0 0.9rem;
}
.hero p.lede {
  max-width: 36rem;
  font-size: 1.08rem;
  color: var(--ink-muted);
  margin: 0 0 1.6rem;
}
.disclosure {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: var(--ink-muted);
  border: 1px solid var(--rule);
  border-radius: 999px;
  padding: 0.4rem 0.9rem;
}
.disclosure .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brass);
  flex: none;
}

/* ---------- filters ---------- */
.filters {
  max-width: 68rem;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.chip {
  font-family: "Work Sans", sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink);
  background: var(--paper-dim);
  border: 1px solid var(--rule);
  border-radius: 999px;
  padding: 0.5rem 1.05rem 0.5rem 0.85rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.chip::before {
  content: "";
  width: 6px;
  height: 6px;
  background: var(--diamond);
  transform: rotate(45deg);
  display: block;
  flex: none;
  transition: background 0.15s ease;
}
.chip:hover { background: #EFEFEA; }
.chip[aria-pressed="true"] {
  background: var(--felt);
  border-color: var(--felt);
  color: #FFFFFF;
}
.chip[aria-pressed="true"]::before { background: #FFFFFF; }

/* ---------- grid ---------- */
.grid {
  max-width: 68rem;
  margin: 0 auto;
  padding: 1.75rem 1.5rem 1rem;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15.5rem, 1fr));
  gap: 1.1rem;
}
.card {
  background: var(--paper-elevated);
  border: 1px solid var(--rule);
  border-radius: 14px;
  padding: 1.15rem 1.15rem 1.3rem;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  transition: box-shadow 0.15s ease, border-color 0.15s ease;
}
.card:hover {
  border-color: #D2D2CB;
  box-shadow: 0 6px 20px -12px rgba(21, 24, 26, 0.18);
}
.card .top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}
.ball-badge {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "IBM Plex Mono", monospace;
  font-weight: 600;
  font-size: 0.85rem;
  box-shadow: inset 0 0 0 4px rgba(255,255,255,0.18);
}
.card .category {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brass);
  text-align: right;
}
.card h3 {
  font-family: "Work Sans", sans-serif;
  font-size: 1.02rem;
  font-weight: 700;
  margin: 0;
  text-wrap: balance;
}
.card p.desc {
  font-size: 0.86rem;
  color: var(--ink-muted);
  margin: 0;
  flex: 1;
}
.card .foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding-top: 0.35rem;
  border-top: 1px dashed var(--rule);
}
.price {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--ink);
}
.price span { color: var(--ink-muted); font-weight: 500; font-size: 0.75rem; }
.go-link {
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: none;
  color: var(--felt-deep);
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  white-space: nowrap;
}
.go-link:hover { text-decoration: underline; }

.empty-state {
  max-width: 68rem;
  margin: 0 auto;
  padding: 3rem 1.5rem;
  text-align: center;
  color: var(--ink-muted);
}

/* ---------- footer ---------- */
footer {
  max-width: 68rem;
  margin: 0 auto;
  padding: 0.5rem 1.5rem 3rem;
}
footer .legal {
  font-size: 0.76rem;
  color: var(--ink-muted);
  max-width: 40rem;
  line-height: 1.6;
}
footer .brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.4rem;
}
footer .brand-row .wordmark { font-size: 1.1rem; }
footer .social {
  display: flex;
  gap: 0.9rem;
  font-size: 0.78rem;
  color: var(--ink-muted);
}
footer .social a {
  color: var(--felt-deep);
  font-weight: 600;
  text-decoration: none;
}
footer .social a:hover { text-decoration: underline; }

@media (prefers-reduced-motion: reduce) {
  .card { transition: none; }
}

[hidden] { display: none !important; }
