/* FFB design system — site-wide tokens and reusable components.
   Promoted from the Form & Fixtures radar so every page can share one look.
   Page-specific styles still live in each page's own css fragment; anything
   reused across pages belongs here. Class prefix: ffb-. Token prefix: --ffb-. */

:root {
  /* Neutrals */
  --ffb-slate:  #141A22;
  --ffb-slate2: #1F2833;
  --ffb-line:   #DADEE3;
  --ffb-muted:  #63707E;
  --ffb-panel:  #fff;

  /* Semantic accents */
  --ffb-buy:    #00996B;
  --ffb-early:  #C9820A;
  --ffb-cash:   #5B5BD6;
  --ffb-avoid:  #B23A48;

  /* Fixture-difficulty ramp: d1 (easiest) … d5 (hardest). Shared with .fpl-difficulty-1..5. */
  --ffb-d1: #00996B;
  --ffb-d2: #6FA83C;
  --ffb-d3: #C9A227;
  --ffb-d4: #D9772F;
  --ffb-d5: #B23A48;
}

/* Typography ---------------------------------------------------------------- */

/* Small tracked monospace label that introduces a page or a control. */
.ffb-kicker {
  font-size: 11.5px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ffb-muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* Page display heading. */
.ffb-h1 {
  font-weight: 800;
  letter-spacing: -.02em;
}

/* Intro paragraph under a heading. */
.ffb-lede {
  color: var(--ffb-muted);
  max-width: 62ch;
}

/* Tabular figures for stat/number columns. */
.ffb-tnums {
  font-variant-numeric: tabular-nums;
}

/* Chip buttons -------------------------------------------------------------- */

/* Pill toggle group. Pressed state via aria-pressed="true" or Bootstrap's .active. */
.ffb-chips {
  display: inline-flex;
  gap: 5px;
  flex-wrap: wrap;
}
.ffb-chips button {
  font-weight: 600;
  font-size: 13.5px;
  border: 1px solid var(--ffb-line);
  background: var(--ffb-panel);
  color: var(--ffb-slate2);
  padding: 7px 13px;
  border-radius: 999px;
  cursor: pointer;
}
.ffb-chips button[aria-pressed="true"],
.ffb-chips button.active {
  background: var(--ffb-slate);
  color: #fff;
  border-color: var(--ffb-slate);
}
.ffb-chips button:focus-visible {
  outline: 2px solid var(--ffb-cash);
  outline-offset: 2px;
}

/* Card surface -------------------------------------------------------------- */

/* Rounded panel used for content cards (promoted from the radar's .ffr-pc). */
.ffb-card {
  background: var(--ffb-panel);
  border: 1px solid var(--ffb-line);
  border-radius: 16px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 11px;
}

/* Pips ---------------------------------------------------------------------- */

/* Row of difficulty pips. */
.ffb-pips {
  display: flex;
  gap: 4px;
  align-items: center;
  flex-wrap: wrap;
}
/* Coloured rounded chip; pair with a .fpl-difficulty-1..5 class for its band colour. */
.ffb-pip {
  min-width: 30px;
  height: 22px;
  padding: 0 6px;
  border-radius: 5px;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 600;
  color: #fff;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* Related-page links -------------------------------------------------------- */

/* Responsive row of "explore next" cards linking to sibling pages. */
.ffb-related {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 10px;
  margin-top: 10px;
}
.ffb-related-item {
  display: block;
  padding: 11px 13px;
  border: 1px solid var(--ffb-line);
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.ffb-related-item:hover,
.ffb-related-item:focus {
  border-color: var(--ffb-slate);
  box-shadow: 0 1px 3px rgba(20, 26, 34, .12);
  text-decoration: none;
}
.ffb-related-title {
  display: block;
  font-weight: 700;
  font-size: 14px;
  color: var(--ffb-slate2);
}
.ffb-related-desc {
  display: block;
  margin-top: 2px;
  font-size: 12.5px;
  color: var(--ffb-muted);
}

/* Legend -------------------------------------------------------------------- */

.ffb-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  align-items: center;
  font-size: 12px;
  color: var(--ffb-muted);
  margin-bottom: 16px;
}
.ffb-legend .ffb-swatch {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.ffb-legend .ffb-chip {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  display: inline-block;
  flex: 0 0 auto;
}
