/* WP-N1: Funding. Everything here is prefixed fn- so it cannot collide with a class another
   package under active build adds to its own stylesheet. Base look and feel (cards, grids,
   tabs, status pills, chips, the drawer, .tbl rows) all come from next.css; this file only
   adds what Funding needs that is not already there. */

.fn-years{align-items:stretch}
.fn-yr{display:flex;flex-direction:column;gap:.7rem}
.fn-yr.fn-partial{background:#fbfcfc}
.fn-yr-h{display:flex;align-items:center;gap:.5rem;font-family:var(--font-mono);font-size:1.05rem;border-bottom:1px solid #eef2f4;padding-bottom:.5rem}
.fn-yr-s{display:flex;flex-direction:column;gap:.2rem}
.fn-sep{font-size:var(--t-chip);font-weight:600;color:var(--muted);text-transform:uppercase;letter-spacing:.06em}
.fn-yr-v{font-family:var(--font-mono);font-size:1.2rem;font-weight:600;letter-spacing:-.01em}
.fn-yr.fn-partial .fn-yr-v{opacity:.75}
.fn-yr-none{font-size:var(--t-ui-sm);color:var(--unknown);font-weight:600}
.fn-yr-s p.note{margin:0}

.fn-lanes{align-items:stretch}
.fn-lane{border-top:3px solid var(--teal);display:flex;flex-direction:column;gap:.35rem}
.fn-lane-contract{border-top-color:var(--partial)}
.fn-lane-absence{border-top-color:var(--unknown)}
.fn-big{font-family:var(--font-mono);font-size:1.75rem;font-weight:600;letter-spacing:-.02em;line-height:1.15}
.fn-big-unit{font-family:var(--font-ui);font-size:1rem;font-weight:600}
.fn-absent-big{font-size:1.25rem;color:var(--unknown)}

.fn-absence-head{display:flex;align-items:center;gap:.6rem;margin-bottom:.3rem}
.fn-absent{font-family:var(--font-mono);font-size:1.1rem;font-weight:600;color:var(--unknown)}

.fn-toolbar{display:flex;align-items:flex-end;gap:1rem;flex-wrap:wrap;margin-bottom:.9rem}
.fn-toolbar select{padding:.5rem .65rem;border:1px solid var(--line);border-radius:7px;background:#fff;color:var(--ink);font-size:var(--t-ui-sm)}
.fn-toggle{display:flex;gap:.5rem;margin-bottom:.8rem;flex-wrap:wrap}
.fn-basis-note{background:var(--warm);border:1px solid var(--line);border-radius:8px;padding:.7rem .85rem;margin:0 0 .9rem}

.fn-pager{display:flex;align-items:center;gap:.9rem;margin-top:.9rem;flex-wrap:wrap}

.fn-scroll{overflow-x:auto;margin-bottom:.4rem}
.fn-tbl{min-width:640px}
.fn-tbl-awards{grid-template-columns:1.9fr 1.7fr 1fr .9fr}
.fn-tbl-awards-mb{grid-template-columns:1.5fr 1.3fr .9fr .8fr 1fr}
/* Value is right-aligned and Evidence window is left-aligned, so they lean into each other and
   the shared .6rem gap is the entire distance between a long figure and a long date range. On a
   wide screen they touched. The column gap is widened for this table only, and Value is given a
   little more track, because it holds the longest strings on the page. */
.fn-tbl-funders{grid-template-columns:1.6fr .7fr .85fr 1.15fr 1.35fr;column-gap:2.25rem}
/* Both tables put a right-aligned figure immediately before a left-aligned text column, so the
   two lean into each other and the shared .6rem gap is the whole distance between them. Measured
   at 10px on a wide screen in each. Same treatment as the Funders table above. */
/* Pack A (clean-up run, 10 Sep 2026): Supplier now carries a charity name above its OSCR
   number, not just the eight-character number this ratio was originally sized for, so the room
   is taken from Title (1.6fr -> 1.2fr) and given to Supplier (1fr -> 1.4fr). Column count and
   order are unchanged. */
.fn-tbl-contracts{grid-template-columns:1.4fr 1.2fr .9fr .8fr 1fr 1.2fr;min-width:820px;column-gap:2.25rem}
/* Six columns since 10 September: the payee, as published, leads the row. The width comes from
   Description, which is the column that can afford it: a payee is a name and reads at a glance,
   while the description is boilerplate ledger text that a reader skims. */
.fn-tbl-payments{grid-template-columns:1.4fr .9fr 1.4fr .8fr 1fr 1.2fr;min-width:900px;column-gap:2.25rem}
.fn-tbl-coverage{grid-template-columns:1.6fr 1fr .8fr .9fr;min-width:520px}
.fn-tbl-cov{grid-template-columns:1.6fr .9fr 1.7fr .9fr;min-width:640px}
.fn-tbl-cov-p{grid-template-columns:1.6fr .9fr 1.7fr 1.1fr .9fr;min-width:760px}
.fn-cov-chip{display:inline-flex;align-items:center;gap:.3rem;margin-right:.5rem;font-size:.85em}
.fn-cov-distinct{display:block;margin-top:.2rem}
.fn-tbl-history{grid-template-columns:1.4fr .9fr .9fr 1fr .9fr;min-width:520px}
.fn-covid{background:var(--partial-tint)}

.fn-basis-line{margin:0 0 .8rem}
.fn-count{margin:.9rem 0 0}
.fn-cov-explain{background:var(--warm);border:1px solid var(--line);border-radius:8px;padding:.7rem .85rem;margin:0 0 1rem}

.fn-period-chip{background:var(--sea);color:var(--navy);border-color:#b9d3e8}
.fn-presets{display:flex;flex-wrap:wrap;gap:.4rem}

@media(max-width:1050px){
  .fn-lanes{grid-template-columns:1fr}
}
@media(max-width:650px){
  .fn-toolbar{flex-direction:column;align-items:flex-start}
  .fn-pager{justify-content:space-between}
}

/* A year drawn but outside the selected period: shown, and plainly not counted. */
.fn-yr.fn-outside{opacity:.5;background:#fbfcfc}

/* The funder detail view (#/funding/funder/<id>). Two small tables, neither of them paged: the
   whole-of-Scotland basis is the point of this page, so nothing on it is capped by a column
   width choice the way the tabs above are. A third rule stood here for a provenance table that
   was removed the same day it was built; provenance lives on Data and sources. */
.fn-tbl-funder-areas{grid-template-columns:1.6fr .9fr 1fr}
.fn-tbl-funder-class{grid-template-columns:2fr 1fr}
