/* ==========================================================================
   components.css — reusable UI components for elclassi.co.
   Depends on tokens.css + base.css. Mobile-first; data tables collapse to
   stacked cards <= 640px. Crests come later (T4.2); here we use the neutral
   team-dot fallback.
   ========================================================================== */

/* ==========================================================================
   Buttons & controls
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  line-height: 1;
  border: var(--rule-width) solid var(--rule-strong);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--ink);
  text-decoration: none;
  cursor: pointer;
  transition:
    background var(--motion-fast) var(--ease),
    border-color var(--motion-fast) var(--ease);
}

.btn:hover {
  background: var(--surface-2);
  color: var(--ink);
}

.btn--primary {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.btn--primary:hover {
  background: var(--ink);
  color: var(--bg);
  opacity: 0.9;
}

.btn--sm {
  padding: var(--space-1) var(--space-3);
  font-size: var(--fs-xs);
}

/* Icon-only button (e.g. theme toggle) */
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  width: auto;
  min-height: 2.4rem;
  padding: var(--space-2) var(--space-3);
  border: var(--rule-width) solid var(--rule-strong);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
  font-size: var(--fs-sm);
}
.icon-btn:hover {
  background: var(--surface-2);
}
.icon-btn svg {
  width: 1.15rem;
  height: 1.15rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ----- Theme toggle: show the icon for the theme it will switch TO -------- */
.theme-toggle__sun {
  display: none;
}
.theme-toggle__moon {
  display: inline-block;
}
/* When dark is active (either media default or forced), show the sun. */
@media (prefers-color-scheme: dark) {
  .theme-toggle__sun {
    display: inline-block;
  }
  .theme-toggle__moon {
    display: none;
  }
}
html[data-theme="dark"] .theme-toggle__sun {
  display: inline-block;
}
html[data-theme="dark"] .theme-toggle__moon {
  display: none;
}
html[data-theme="light"] .theme-toggle__sun {
  display: none;
}
html[data-theme="light"] .theme-toggle__moon {
  display: inline-block;
}

/* ==========================================================================
   Form fields / search box
   ========================================================================== */
.field {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.field__label {
  font-size: var(--fs-xs);
  font-weight: var(--fw-semibold);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-muted);
}

.input,
.select {
  width: 100%;
  padding: var(--space-2) var(--space-3);
  background: var(--surface);
  color: var(--ink);
  border: var(--rule-width) solid var(--rule-strong);
  border-radius: var(--radius-md);
  font-size: var(--fs-sm);
}

.input::placeholder {
  color: var(--ink-faint);
}

.search-box {
  position: relative;
}
.search-box .input {
  padding-left: 2.2rem;
}
.search-box__icon {
  position: absolute;
  left: var(--space-3);
  top: 50%;
  transform: translateY(-50%);
  width: 1.1rem;
  height: 1.1rem;
  pointer-events: none;
  color: var(--ink-faint);
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

/* ==========================================================================
   Team dot (crest fallback — SHOW_CLUB_CRESTS off, or pre-T4.2)
   ========================================================================== */
.team-dot {
  display: inline-block;
  width: 0.75em;
  height: 0.75em;
  border-radius: var(--radius-pill);
  vertical-align: baseline;
  flex: none;
}
.team-dot--barca {
  background: var(--barca-fill);
}
.team-dot--real {
  background: var(--real-fill);
}
.team-dot--draw {
  background: var(--draw-fill);
}

.team-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  white-space: nowrap;
}
.team-label--barca {
  color: var(--barca-ink);
}
.team-label--real {
  color: var(--real-ink);
}

/* ==========================================================================
   Club crest (SHOW_CLUB_CRESTS on) — rendered by {% club_crest %}
   Equal visual weight for both clubs: identical box, object-fit contain.
   ========================================================================== */
.club-crest {
  display: inline-block;
  object-fit: contain;
  vertical-align: middle;
  flex: none;
}

/* ==========================================================================
   Tally bar — all-time W / D / W, two accents + grey at EQUAL weight
   ========================================================================== */
.tally {
  display: block;
}

.tally__bar {
  display: flex;
  width: 100%;
  height: 2.25rem;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: var(--rule-width) solid var(--rule);
  background: var(--surface-2);
}

.tally__seg {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 2.5rem;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
  color: #fff;
  overflow: hidden;
  white-space: nowrap;
}
.tally__seg--barca {
  background: var(--barca-fill);
  color: var(--barca-on);
}
.tally__seg--draw {
  background: var(--draw-fill);
  color: var(--draw-on);
}
.tally__seg--real {
  background: var(--real-fill);
  color: var(--real-on);
}

.tally__legend {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3) var(--space-5);
  margin-top: var(--space-3);
  font-size: var(--fs-sm);
  color: var(--ink-muted);
  list-style: none;
  padding: 0;
}
.tally__legend li {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.tally__legend .num {
  color: var(--ink);
  font-weight: var(--fw-semibold);
}

/* ==========================================================================
   Score badge
   ========================================================================== */
.score {
  display: inline-flex;
  align-items: stretch;
  border: var(--rule-width) solid var(--rule-strong);
  border-radius: var(--radius-md);
  overflow: hidden;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.score__side {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  font-weight: var(--fw-semibold);
}
.score__num {
  font-size: var(--fs-md);
}
.score__sep {
  display: flex;
  align-items: center;
  padding-inline: var(--space-1);
  background: var(--surface-2);
  color: var(--ink-muted);
}
.score__side--barca {
  background: var(--barca-soft);
  color: var(--barca-ink);
}
.score__side--real {
  background: var(--real-soft);
  color: var(--real-ink);
}
.score--lg .score__num {
  font-size: var(--fs-2xl);
}
.score--lg .score__side {
  padding: var(--space-3) var(--space-5);
}

/* Result pill (W/D/L context) */
.result-pill {
  display: inline-block;
  padding: 0 var(--space-2);
  border-radius: var(--radius-sm);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  font-family: var(--font-mono);
  line-height: 1.6;
}
.result-pill--barca {
  background: var(--barca-fill);
  color: var(--barca-on);
}
.result-pill--real {
  background: var(--real-fill);
  color: var(--real-on);
}
.result-pill--draw {
  background: var(--draw-fill);
  color: var(--draw-on);
}

/* ==========================================================================
   Stat card
   ========================================================================== */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
  gap: var(--space-4);
}

.stat-card {
  background: var(--surface);
  border: var(--rule-width) solid var(--rule);
  border-radius: var(--radius-lg);
  padding: var(--space-4) var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.stat-card__label {
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-muted);
  font-weight: var(--fw-semibold);
}

.stat-card__value {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: var(--fs-2xl);
  font-weight: var(--fw-bold);
  line-height: 1;
  color: var(--ink);
}

.stat-card__context {
  font-size: var(--fs-sm);
  color: var(--ink-muted);
}

.stat-card--barca {
  border-top: 3px solid var(--barca-fill);
}
.stat-card--real {
  border-top: 3px solid var(--real-fill);
}

/* ==========================================================================
   Data table — sortable, sticky header; stacks to cards <= 640px
   ========================================================================== */
.table-wrap {
  overflow-x: auto;
  border: var(--rule-width) solid var(--rule);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--fs-sm);
}

.data-table caption {
  text-align: left;
  padding: var(--space-3) var(--space-4);
  color: var(--ink-muted);
  font-size: var(--fs-sm);
  border-bottom: var(--rule-width) solid var(--rule);
  caption-side: top;
}

.data-table th,
.data-table td {
  padding: var(--space-2) var(--space-4);
  text-align: left;
  border-bottom: var(--rule-width) solid var(--rule);
  vertical-align: middle;
}

.data-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--surface-2);
  color: var(--ink);
  font-weight: var(--fw-semibold);
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.data-table tbody tr:last-child td {
  border-bottom: none;
}

.data-table tbody tr:hover {
  background: var(--surface-2);
}

.data-table .num {
  text-align: right;
}

/* Sortable column affordance */
.data-table th .sort-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  color: inherit;
  text-decoration: none;
}
.data-table th .sort-link:hover {
  color: var(--link);
}
.data-table th[aria-sort] .sort-link::after {
  content: "";
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  opacity: 0.4;
}
.data-table th[aria-sort="none"] .sort-link::after {
  border-top: 5px solid currentColor;
  opacity: 0.25;
}
.data-table th[aria-sort="ascending"] .sort-link::after {
  border-bottom: 5px solid currentColor;
  opacity: 1;
}
.data-table th[aria-sort="descending"] .sort-link::after {
  border-top: 5px solid currentColor;
  opacity: 1;
}

/* Mobile: stacked cards */
@media (max-width: 640px) {
  .data-table.is-stackable thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }
  .data-table.is-stackable,
  .data-table.is-stackable tbody,
  .data-table.is-stackable tr,
  .data-table.is-stackable td {
    display: block;
    width: 100%;
  }
  .data-table.is-stackable tr {
    border: var(--rule-width) solid var(--rule);
    border-radius: var(--radius-md);
    margin: var(--space-3);
    background: var(--surface);
  }
  .data-table.is-stackable td {
    display: flex;
    justify-content: space-between;
    gap: var(--space-4);
    text-align: right;
    border-bottom: var(--rule-width) solid var(--rule);
    padding: var(--space-2) var(--space-3);
  }
  .data-table.is-stackable td:last-child {
    border-bottom: none;
  }
  .data-table.is-stackable td::before {
    content: attr(data-label);
    font-weight: var(--fw-semibold);
    text-transform: uppercase;
    font-size: var(--fs-xs);
    letter-spacing: 0.04em;
    color: var(--ink-muted);
    text-align: left;
  }
  .data-table.is-stackable .num {
    text-align: right;
  }
}

/* ==========================================================================
   Chips (filter / preset)
   ========================================================================== */
.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  align-items: center;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1) var(--space-3);
  border: var(--rule-width) solid var(--rule-strong);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--ink);
  font-size: var(--fs-sm);
  text-decoration: none;
  cursor: pointer;
  line-height: 1.6;
}
.chip:hover {
  background: var(--surface-2);
  color: var(--ink);
}
.chip[aria-pressed="true"],
.chip.is-active {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}

/* Removable filter chip */
.chip--filter {
  background: var(--surface-2);
}
.chip__remove {
  display: inline-flex;
  width: 1rem;
  height: 1rem;
  align-items: center;
  justify-content: center;
  border: none;
  background: none;
  color: var(--ink-muted);
  cursor: pointer;
  border-radius: var(--radius-pill);
  font-size: var(--fs-sm);
  line-height: 1;
  padding: 0;
}
.chip__remove:hover {
  color: var(--ink);
}

/* ==========================================================================
   Lens bar — the filter UI shell (wiring in T4.3)
   ========================================================================== */
.lens {
  background: var(--surface);
  border: var(--rule-width) solid var(--rule);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
}

.lens__presets {
  margin-bottom: var(--space-4);
  padding-bottom: var(--space-4);
  border-bottom: var(--rule-width) solid var(--rule);
}

.lens__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
  gap: var(--space-3) var(--space-4);
}

.lens__actions {
  display: flex;
  gap: var(--space-2);
  align-items: center;
  margin-top: var(--space-4);
  padding-top: var(--space-4);
  border-top: var(--rule-width) solid var(--rule);
  flex-wrap: wrap;
}

.lens__actions .lens__spacer {
  margin-left: auto;
}

/* Collapsible sheet on mobile */
.lens__summary {
  display: none;
}

@media (max-width: 640px) {
  .lens[data-collapsible] .lens__summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    font-weight: var(--fw-semibold);
    list-style: none;
  }
  .lens[data-collapsible] .lens__summary::-webkit-details-marker {
    display: none;
  }
  .lens[data-collapsible] .lens__summary::after {
    content: "+";
    font-family: var(--font-mono);
    font-size: var(--fs-lg);
  }
  .lens[data-collapsible][open] .lens__summary::after {
    content: "−";
  }
  .lens[data-collapsible] .lens__body {
    margin-top: var(--space-4);
  }
}

/* Active (removable) filter chips row, sits under the presets. */
.lens__active {
  margin-bottom: var(--space-4);
}
.chip__label {
  color: var(--ink-muted);
}

/* Checkbox groups (competition, decade, extra time). */
.lens__fieldset {
  border: 0;
  margin: 0;
  padding: 0;
  min-width: 0;
}
.lens__checks {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1) var(--space-3);
}
.lens__check {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--fs-sm);
  line-height: 1.6;
  cursor: pointer;
}
.lens__check input {
  accent-color: var(--ink);
}

/* Polite notice for ignored / invalid lens input. */
.lens__notice {
  margin-bottom: var(--space-4);
  padding: var(--space-2) var(--space-3);
  border: var(--rule-width) solid var(--warn-ink);
  border-radius: var(--radius-md);
  background: var(--warn-soft);
  color: var(--warn-ink);
  font-size: var(--fs-sm);
}
.lens__notice-list {
  margin: 0;
  padding-left: var(--space-4);
}

/* HTMX busy indicator (shown only while a request is in flight). */
.htmx-indicator {
  opacity: 0;
  transition: opacity 150ms ease-in;
}
.htmx-request .htmx-indicator,
.htmx-request.htmx-indicator {
  opacity: 1;
}
.lens__indicator {
  font-size: var(--fs-sm);
  color: var(--ink-muted);
}

/* Results count line above a filtered table. */
.results__count {
  color: var(--ink-muted);
  font-size: var(--fs-sm);
  margin-bottom: var(--space-3);
}

/* ==========================================================================
   Pagination
   ========================================================================== */
.pagination {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
  justify-content: center;
  margin-top: var(--space-5);
}
.pagination__info {
  font-size: var(--fs-sm);
  color: var(--ink-muted);
  font-variant-numeric: tabular-nums;
}
.pagination__list {
  display: flex;
  gap: var(--space-1);
  list-style: none;
  padding: 0;
  margin: 0;
}
.pagination__link {
  display: inline-flex;
  min-width: 2.25rem;
  justify-content: center;
  padding: var(--space-1) var(--space-2);
  border: var(--rule-width) solid var(--rule-strong);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: var(--ink);
  font-size: var(--fs-sm);
  font-variant-numeric: tabular-nums;
}
.pagination__link:hover {
  background: var(--surface-2);
  color: var(--ink);
}
.pagination__link[aria-current="page"] {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.pagination__link[aria-disabled="true"] {
  opacity: 0.4;
  pointer-events: none;
}

/* ==========================================================================
   Empty state
   ========================================================================== */
.empty-state {
  text-align: center;
  padding: var(--space-8) var(--space-4);
  border: 1px dashed var(--rule-strong);
  border-radius: var(--radius-lg);
  color: var(--ink-muted);
}
.empty-state__title {
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  color: var(--ink);
  margin-bottom: var(--space-2);
}

/* ==========================================================================
   Coverage note — caveat callout for partial data
   ========================================================================== */
.coverage-note {
  display: flex;
  gap: var(--space-3);
  align-items: flex-start;
  background: var(--warn-soft);
  border: var(--rule-width) solid var(--warn-rule);
  border-left: 3px solid var(--warn-ink);
  border-radius: var(--radius-md);
  padding: var(--space-3) var(--space-4);
  font-size: var(--fs-sm);
  color: var(--ink);
}
.coverage-note__icon {
  flex: none;
  width: 1.1rem;
  height: 1.1rem;
  margin-top: 0.15rem;
  color: var(--warn-ink);
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.coverage-note strong {
  color: var(--warn-ink);
}
.coverage-note p {
  margin: 0;
  max-width: none;
}

/* Inline coverage flag (e.g. next to a stat value) */
.coverage-flag {
  font-size: var(--fs-xs);
  color: var(--warn-ink);
  font-weight: var(--fw-semibold);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ==========================================================================
   Timeline — goals / cards in a match
   ========================================================================== */
.timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  position: relative;
}
.timeline::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: var(--rule-width);
  background: var(--rule);
  transform: translateX(-50%);
}
.timeline__item {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--space-3);
  padding-block: var(--space-2);
}
.timeline__minute {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
  background: var(--surface);
  border: var(--rule-width) solid var(--rule-strong);
  border-radius: var(--radius-pill);
  padding: 0 var(--space-2);
  min-width: 2.75rem;
  text-align: center;
  z-index: 1;
}
.timeline__event {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.timeline__event--barca {
  justify-content: flex-end;
  text-align: right;
}
.timeline__event--real {
  grid-column: 3;
  justify-content: flex-start;
  text-align: left;
}
.timeline__kind {
  font-size: var(--fs-xs);
  color: var(--ink-muted);
}
.timeline__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.2rem;
  height: 1.2rem;
  border-radius: var(--radius-pill);
  font-size: var(--fs-xs);
  flex: none;
}
.timeline__badge--goal {
  background: var(--surface-2);
}
.timeline__badge--red {
  background: #c81e1e;
  color: #fff;
}

@media (max-width: 640px) {
  .timeline::before {
    left: 1.4rem;
  }
  .timeline__item {
    grid-template-columns: auto 1fr;
    gap: var(--space-3);
  }
  .timeline__minute {
    grid-row: 1;
  }
  .timeline__event--barca,
  .timeline__event--real {
    grid-column: 2;
    justify-content: flex-start;
    text-align: left;
  }
}

/* ==========================================================================
   Scoreline heatmap (CSS grid) — small preview on the styleguide
   ========================================================================== */
.heatmap {
  display: grid;
  gap: 2px;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}
.heatmap__cell {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--fs-xs);
  border-radius: var(--radius-sm);
  color: var(--ink);
  background: var(--surface-2);
}

/* ==========================================================================
   Chart container + table fallback (<details>)
   ========================================================================== */
.chart-figure {
  margin: 0;
}
.chart-box {
  position: relative;
  width: 100%;
  background: var(--surface);
  border: var(--rule-width) solid var(--rule);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
}
.chart-fallback {
  margin-top: var(--space-3);
}
.chart-fallback > summary {
  cursor: pointer;
  font-size: var(--fs-sm);
  color: var(--link);
}

/* ==========================================================================
   Badges / meta
   ========================================================================== */
.badge {
  display: inline-block;
  padding: 0 var(--space-2);
  border-radius: var(--radius-sm);
  font-size: var(--fs-xs);
  font-weight: var(--fw-semibold);
  background: var(--surface-2);
  color: var(--ink-muted);
  border: var(--rule-width) solid var(--rule);
  line-height: 1.7;
}
.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-4);
  font-size: var(--fs-sm);
  color: var(--ink-muted);
}

/* ==========================================================================
   Search combobox — header live suggestions (T5.2)
   The input is role="combobox"; .search-pop is its role="listbox" popup.
   ========================================================================== */
.search-combo {
  position: relative;
}

.search-pop {
  position: absolute;
  z-index: 60;
  top: calc(100% + var(--space-2));
  left: 0;
  right: 0;
  max-height: min(70vh, 26rem);
  overflow-y: auto;
  padding: var(--space-2);
  background: var(--surface);
  border: var(--rule-width) solid var(--rule-strong);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}
.search-pop[hidden] {
  display: none;
}

.combo-group + .combo-group {
  margin-top: var(--space-2);
  padding-top: var(--space-2);
  border-top: var(--rule-width) solid var(--rule);
}
.combo-group__title {
  margin: 0;
  padding: var(--space-1) var(--space-2);
  font-size: var(--fs-xs);
  font-weight: var(--fw-semibold);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-muted);
}

.combo-opt {
  display: flex;
  align-items: baseline;
  gap: var(--space-2);
  padding: var(--space-2);
  border-radius: var(--radius-sm);
  color: var(--ink);
  cursor: pointer;
}
.combo-opt__label {
  font-weight: var(--fw-medium);
}
.combo-opt__sub {
  font-size: var(--fs-xs);
  color: var(--ink-muted);
}
.combo-opt__type {
  margin-left: auto;
  font-size: var(--fs-xs);
  font-family: var(--font-mono, monospace);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink-muted);
}
.combo-opt:hover {
  background: var(--surface-2);
}
.combo-opt.is-active {
  background: var(--surface-2);
  outline: 2px solid var(--focus);
  outline-offset: -2px;
}

.combo-empty {
  margin: 0;
  padding: var(--space-3);
  font-size: var(--fs-sm);
  color: var(--ink-muted);
}

/* Give labels room on narrow screens: drop the decorative type badge. */
@media (max-width: 30rem) {
  .combo-opt__type {
    display: none;
  }
}
