/* Fonts are in fonts.css, the brand values in theme.css and the header in header.css
   (all three also used by the admin). */

/* ==========================================================================
   Base
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-heading);
  font-weight: var(--heading-weight);
  letter-spacing: var(--heading-tracking);
  line-height: 1.15;
  color: var(--color-text);
}
h1 { font-size: clamp(1.9rem, 4vw, 2.6rem); margin: 0 0 6px; }
h2 { font-size: 1.15rem; margin: 0 0 12px; letter-spacing: calc(var(--heading-tracking) / 2); }

a { color: var(--color-accent); text-underline-offset: 2px; }
a:hover { color: var(--color-accent-strong); }

:focus-visible { outline: 3px solid var(--color-accent-decor); outline-offset: 2px; }

.muted { color: var(--color-muted); }
.small { font-size: 0.875rem; }

input, button, select, textarea { font: inherit; color: inherit; }

/* ==========================================================================
   Page frame: width and footer (the header is in header.css)
   ========================================================================== */

.page { width: 100%; max-width: 1100px; margin: 0 auto; padding: 28px 24px; flex: 1; }

.site-footer {
  padding: 24px;
  background: var(--footer-bg);
  color: var(--footer-text);
  font-size: 0.875rem;
  text-align: center;
}
.site-footer a { color: inherit; }

/* ==========================================================================
   Building blocks
   ========================================================================== */

.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  padding: 24px;
  margin-bottom: 18px;
}

/* Buttons: solid for the main action, outlined for secondary ones. */
.button,
button[type="submit"]:not(.link-button):not(.button-secondary):not(.icon-button):not(.currency-option):not(.menu-item) {
  display: inline-block;
  background: var(--color-accent);
  color: var(--color-on-accent);
  border: 1px solid var(--color-accent);
  border-radius: var(--radius);
  padding: 11px 22px;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: var(--button-transform);
  letter-spacing: var(--button-tracking);
  text-decoration: none;
  cursor: pointer;
}
.button:hover,
button[type="submit"]:not(.link-button):not(.button-secondary):not(.icon-button):not(.currency-option):not(.menu-item):hover {
  background: var(--color-accent-strong);
  border-color: var(--color-accent-strong);
  color: var(--color-on-accent);
}

.button-secondary {
  background: transparent;
  color: var(--color-accent);
  border: 1px solid var(--color-accent);
  border-radius: var(--radius);
  padding: 9px 18px;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: var(--button-transform);
  letter-spacing: var(--button-tracking);
  cursor: pointer;
}
.button-secondary:hover { background: var(--color-accent-soft); }
/* Pinnacle: 14px, and the secondary button outlined in ink, as on the new site. */
[data-brand="pinnacle"] .button,
[data-brand="pinnacle"] button[type="submit"]:not(.link-button):not(.button-secondary):not(.icon-button):not(.currency-option):not(.menu-item) {
  font-size: 0.875rem;
}
[data-brand="pinnacle"] .button-secondary {
  font-size: 0.875rem;
  color: var(--color-text);
  background: var(--color-field);
  border-color: rgb(16 28 34 / 0.16);
}
[data-brand="pinnacle"] .button-secondary:hover { border-color: var(--color-text); background: var(--color-field); }

.link-button {
  background: none;
  border: 0;
  padding: 0;
  color: var(--header-text);
  font-size: 0.875rem;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* Form fields (login, password reset, two-factor, search). */
input[type="text"], input[type="email"], input[type="password"], input[type="search"],
input:not([type]), select, textarea {
  width: 100%;
  max-width: 28rem;
  padding: 11px 16px;
  background: var(--color-field);
  border: 1px solid var(--color-field-border);
  border-radius: var(--radius);
}
input:focus, select:focus, textarea:focus { border-color: var(--color-accent); }
textarea { padding: 12px 16px; }
label { font-size: 0.875rem; font-weight: 600; }

/* Messages: notes that slide in at the top right, under the header. Success and
   info notes fade after 7 seconds (paused while hovered or focused); errors stay
   until closed. static/js/site.js adds the close buttons. */
.toasts {
  position: fixed;
  top: 84px;
  right: clamp(12px, 3vw, 32px);
  z-index: 30;
  display: grid;
  gap: 8px;
  width: min(380px, calc(100vw - 24px));
  margin: 0;
  padding: 0;
  list-style: none;
}
.toast {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 12px 12px 14px;
  border-radius: var(--radius);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  box-shadow: 0 12px 32px rgb(16 28 34 / 0.14);
  animation: toast-in 0.25s ease-out;
}
.toast > .icon { margin-top: 2px; color: var(--color-accent); }
.toast.success > .icon { color: var(--status-good); }
.toast.error { border-color: var(--color-danger); color: var(--color-danger); }
.toast.error > .icon { color: var(--color-danger); }
.toast-text { flex: 1; }
.toast-close {
  display: inline-flex;
  padding: 2px;
  border: 0;
  border-radius: 6px;
  background: none;
  color: var(--color-muted);
  cursor: pointer;
}
.toast-close:hover { color: var(--color-text); background: var(--color-surface-alt); }
.toast.success, .toast.info { animation: toast-in 0.25s ease-out, toast-out 0.4s ease-in 7s forwards; }
.toast:hover, .toast:focus-within { animation-play-state: paused; }
@keyframes toast-in { from { opacity: 0; transform: translateY(-8px); } }
@keyframes toast-out { to { opacity: 0; transform: translateY(-8px); visibility: hidden; } }

/* A message inside a page (e.g. a form's errors), not a floating note. */
.message:not(.toast) {
  padding: 10px 14px;
  border-radius: var(--radius);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-left: 4px solid var(--color-accent-decor);
}
.message.error:not(.toast) { border-color: var(--color-danger); color: var(--color-danger); }

/* Empty pages: an icon in a soft circle above the existing sentence. */
.empty-block { display: grid; justify-items: center; gap: 4px; padding: 28px 16px; text-align: center; color: var(--color-muted); }
.empty-block > .icon {
  width: 44px;
  height: 44px;
  margin-bottom: 6px;
  padding: 11px;
  border-radius: 50%;
  background: var(--color-accent-soft);
  color: var(--color-accent);
}
.empty-block p { margin: 0; max-width: 36rem; }
.empty-block strong { color: var(--color-text); }

.notice {
  padding: 8px 12px;
  border-radius: var(--radius);
  background: var(--color-notice-bg);
  border: 1px solid var(--color-notice-border);
}

/* ==========================================================================
   Dashboard
   --------------------------------------------------------------------------
   Received / pending / forecast is one blue running dark to light: money that
   is more certain is darker. Same on both brands, so a colour always means the
   same thing. Checked with the dataviz palette validator (ordinal ramp: one
   hue, monotone lightness, visible steps, light end visible on both surfaces).
   ========================================================================== */

:root {
  --color-carried: #06213f;     /* beginning balance: money already in hand */
  --color-received: #104281;
  --color-pending: #256abf;
  --color-forecast: #86b6ef;
  --color-track: #e6edf7;      /* lighter step of the same blue */
  /* Trends chart: green for gifts received, red for expenses. Checked with the
     palette validator on both brands' card colours: contrast and normal vision
     pass, but red-green colour-blind separation is only 7.2 (target 8), so the
     expense bars and their key also carry diagonal stripes; colour is never
     the only cue. */
  --color-income: #008300;
  --color-expense: #e34948;
  /* Balance line on the Trends tab: green above zero, red below (the status
     colours, as on "Healthy" / "In deficit"), black at zero. */
  --color-balance-zero: #000000;
}

.page-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 12px;
  margin-bottom: 22px;
}
.dot-sep { margin: 0 6px; }

.eyebrow {
  margin: 0 0 14px;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: var(--label-tracking);
  text-transform: var(--label-transform);
  color: var(--eyebrow-color);
}

/* The one headline number. Proportional figures look right at this size. */
.hero { margin-bottom: 18px; }
.hero-value {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(2.6rem, 6vw, 3.5rem);
  font-weight: var(--heading-weight);
  letter-spacing: var(--heading-tracking);
  line-height: 1;
}
.hero-context { margin: 8px 0 0; color: var(--color-muted); }
.hero-context strong { color: var(--color-text); font-weight: 700; }
.hero.centered { text-align: center; }


/* Progress meter */
.meter { margin-bottom: 22px; }
.meter-bar { display: block; overflow: visible; }
.meter-track { fill: var(--color-track); }
.meter-segment { cursor: default; transition: opacity 0.15s; }
.meter-segment.received { fill: var(--color-received); }
.meter-segment.pending { fill: var(--color-pending); }
.meter-segment.forecast { fill: var(--color-forecast); }
.meter-segment:focus { outline: none; }
.meter-bar:has(.is-active) .meter-segment:not(.is-active) { opacity: 0.55; }
.meter-gap { stroke: var(--color-surface); stroke-width: 2; }
.meter-goal { stroke: var(--color-text); stroke-width: 2; }
.meter-scale { display: flex; justify-content: space-between; gap: 12px; margin-top: 6px; }

/* Stat tiles: also the bar's legend. */
.stat-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  margin: 0 0 14px;
}
/* Soft tinted tiles without borders; a small icon leads each label. */
.stat-tile {
  padding: 14px 16px;
  border-radius: var(--radius);
  background: var(--color-surface-alt);
}
.stat-tile dt { display: flex; align-items: center; gap: 6px; color: var(--color-muted); font-size: 0.85rem; font-weight: 600; }
.stat-tile dt .icon { color: var(--color-accent); }
.stat-tile dd { margin: 6px 0 0; font-size: 1.35rem; font-weight: 600; letter-spacing: -0.01em; font-variant-numeric: tabular-nums; }
.stat-note { margin: 2px 0 0; color: var(--color-muted); font-size: 0.78rem; }

/* Colour keys: identity sits beside the text; text keeps its own colour. */
.key { display: inline-block; flex: none; width: 10px; height: 10px; border-radius: 3px; margin-right: 8px; }
.key.received { background: var(--color-received); }
.key.pending { background: var(--color-pending); }
.key.forecast { background: var(--color-forecast); }
.key.remaining { background: var(--color-track); box-shadow: inset 0 0 0 1px var(--color-border); }
.key.goal { width: 2px; height: 12px; border-radius: 0; background: var(--color-text); vertical-align: middle; }

.footnote { margin: 0; }

.chart-tooltip {
  position: absolute;
  z-index: 10;
  display: grid;
  gap: 2px;
  padding: 8px 10px;
  background: var(--color-text);
  color: var(--color-surface);
  border-radius: 6px;
  font-size: 0.85rem;
  pointer-events: none;
  box-shadow: 0 4px 14px rgb(0 0 0 / 0.15);
}
.chart-tooltip[hidden] { display: none; }
.chart-tooltip strong { font-size: 1rem; }

/* Tables */
.card-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 8px; }
.card-head h2 { margin: 0; }
.count {
  min-width: 1.6em;
  padding: 0 7px;
  border-radius: 999px;
  background: var(--color-surface-alt);
  color: var(--color-muted);
  font-size: 0.78rem;
  font-weight: 600;
  text-align: center;
}
/* position: relative keeps absolutely positioned content (such as visually hidden
   headings) inside the scroll area, so it can't widen the page. */
.table-wrap { overflow-x: auto; position: relative; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 11px 10px; border-bottom: 1px solid var(--color-border); white-space: nowrap; }
tbody tr:last-child td, tbody tr:last-child th { border-bottom: 0; }
tbody tr:hover td, tbody tr:hover th { background: var(--color-surface-alt); }
th {
  font-size: 0.72rem;
  color: var(--color-muted);
  font-weight: 600;
  text-transform: var(--label-transform);
  letter-spacing: var(--label-tracking);
}
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }

/* Received / pending as rounded pills, in the blues the meter uses for them. */
.status-pill {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
}
.status-pill.received { background: #dce8f7; color: #0c3264; }
.status-pill.pending { background: #eef4fc; color: #1d4f8f; box-shadow: inset 0 0 0 1px #c3d7f0; }

/* On phones, each row of a .table-cards table becomes a small card, every value
   labelled from its data-label. */
@media (max-width: 600px) {
  .table-cards thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }
  .table-cards, .table-cards tbody, .table-cards tfoot { display: block; }
  .table-cards tr {
    display: block;
    margin-bottom: 10px;
    padding: 10px 14px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: var(--color-surface);
  }
  .table-cards td, .table-cards tfoot th {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 4px 0;
    border: 0;
    white-space: normal;
    text-align: right;
  }
  .table-cards td::before {
    content: attr(data-label);
    color: var(--color-muted);
    font-size: 0.8rem;
    text-align: left;
  }
  .table-cards tbody tr:hover td { background: none; }
  .table-wrap:has(.table-cards) { overflow: visible; }
}
/* Row labels (e.g. the health view's month-by-month table) read as body text. */
tbody th[scope="row"] { font-size: inherit; color: var(--color-text); text-transform: none; letter-spacing: normal; }
.status { display: inline-flex; align-items: center; }
.empty { margin: 4px 0 0; }
.empty-state { text-align: center; padding: 36px 20px; }

/* ==========================================================================
   Forms (embedded from a form service)
   ========================================================================== */

.form-list { list-style: none; margin: 0; padding: 0; }
.form-list li { padding: 12px 0; border-bottom: 1px solid var(--color-border); }
.form-list li:last-child { border-bottom: 0; }
.form-list a { font-weight: 600; }
.form-list p { margin: 4px 0 0; }
.form-frame {
  display: block;
  width: 100%;
  height: 80vh;
  min-height: 600px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  background: #fff;
}
/* Built-here forms (online_forms/native.py) */
.native-form { max-width: 40rem; display: flex; flex-direction: column; gap: 18px; }
.form-field label, .form-field legend { display: block; margin-bottom: 4px; font-weight: 600; }
.form-field fieldset { margin: 0; padding: 0; border: 0; }
.form-field fieldset > div { display: flex; flex-wrap: wrap; gap: 4px 18px; }
.form-field fieldset label { display: inline-flex; align-items: center; gap: 6px; margin: 0; font-weight: 400; }
.form-field input:not([type="radio"]):not([type="checkbox"]), .form-field select, .form-field textarea { width: 100%; }
.form-field p { margin: 4px 0 0; }
.form-actions { display: flex; gap: 8px; }
/* Forms that report their height start here, then fit exactly (js/form-frame.js). */
.form-frame.fits-content { height: 600px; }
.form-frame.fitted { min-height: 0; }

/* ==========================================================================
   Staff: view a teacher's dashboard
   ========================================================================== */

.title-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; }
.title-row h1 { margin-bottom: 0; }

.result-list { margin: 0; padding-left: 20px; }
.result-list li { padding: 4px 0; }

/* ==========================================================================
   Small screens
   ========================================================================== */

@media (max-width: 600px) {
  .pill { max-width: 100%; }
  .year-select select { min-width: 0; max-width: 100%; text-overflow: ellipsis; }
  /* The calendar icon says it's the year; the label stays for screen readers. */
  .year-select label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .gauge-scale span:nth-child(4) { display: none; }  /* "2 months" and "3+" don't both fit */
  .toasts { top: auto; bottom: 12px; }
  .page { padding: 20px 16px; }
  .stat-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat-tile dd { font-size: 1.15rem; }
}

/* ==========================================================================
   Sign-in and account pages
   ========================================================================== */

.signin { max-width: 32rem; margin: 0 auto; }
.stack { display: grid; gap: 14px; }
.stack label { display: block; margin-bottom: 4px; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; }
.field-error { margin: 4px 0 0; color: var(--color-danger); font-size: 0.875rem; }
.button-block { display: block; width: 100%; max-width: 28rem; text-align: center; }
.signin input { max-width: 28rem; }
.divider {
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 28rem;
  margin: 18px 0;
  color: var(--color-muted);
  font-size: 0.8rem;
  text-transform: var(--label-transform);
  letter-spacing: var(--label-tracking);
}
.divider::before, .divider::after { content: ""; flex: 1; border-top: 1px solid var(--color-border); }

/* Staging banner (SITE_ENVIRONMENT=staging) */
.environment-banner {
  padding: 6px 16px;
  background: #5b2a86;
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 600;
  text-align: center;
}

/* --- Tabs (gifts, recurring gifts, expenses) -------------------------------- */
.tablist {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 24px;
  margin: -4px 0 14px;
  border-bottom: 1px solid var(--color-border);
}
.tablist [role="tab"] {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: -1px;
  padding: 8px 2px 10px;
  background: none;
  border: 0;
  border-bottom: 2px solid transparent;
  color: var(--color-muted);
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
}
.tablist [role="tab"]:hover { color: var(--color-text); }
.tablist [role="tab"][aria-selected="true"] {
  color: var(--color-text);
  border-bottom-color: var(--color-accent-decor);
}
[data-brand="pinnacle"] .tablist [role="tab"] { font-size: 0.95rem; font-weight: 500; }
.tabpanel:focus-visible { outline-offset: 4px; }
/* With the script, the tab names act as headings; keep them for screen readers. */
.tabs-ready .panel-heading {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
/* Without it, panels show one under another with their own headings. */
.tabs:not(.tabs-ready) .tabpanel + .tabpanel { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--color-border); }
.coming-soon { padding: 28px 16px; text-align: center; }
.coming-soon p { margin: 0 0 6px; }

/* --- Carry-over, expenses and Financial Health -------------------------------- */
.key.carried { background: var(--color-carried); }
.key.deficit { background: #ffffff; box-shadow: inset 0 0 0 2px var(--color-danger); }
.meter-segment.carried { fill: var(--color-carried); }

.subheading {
  margin: 22px 0 8px;
  font-size: 0.95rem;
  letter-spacing: calc(var(--heading-tracking) / 3);
}
/* Collapsible section (<details>): the heading is the toggle, with a chevron. */
.collapsible > summary { display: flex; align-items: center; gap: 8px; cursor: pointer; list-style: none; margin: 22px 0 8px; }
.collapsible > summary::-webkit-details-marker { display: none; }
.collapsible > summary::before {
  content: "";
  width: 7px;
  height: 7px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-45deg);
  transition: transform 0.15s;
}
.collapsible[open] > summary::before { transform: rotate(45deg); }
.collapsible > summary .subheading { margin: 0; }
@media (prefers-reduced-motion: reduce) { .collapsible > summary::before { transition: none; } }
/* Trends chart (health view) */
.trend-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 0 0 6px; }
.trend-legend > span { display: inline-flex; align-items: center; }
.key.income { background: var(--color-income); }
.key.expenses {
  background: repeating-linear-gradient(45deg, rgb(255 255 255 / 0.35) 0 1.5px, transparent 1.5px 4px), var(--color-expense);
}
.trend-chart { display: block; overflow: visible; }
.trend-grid { stroke: var(--color-border); stroke-width: 1; }
.trend-zero { stroke: var(--color-muted); stroke-width: 1; }
.trend-axis { fill: var(--color-muted); font-size: 0.72rem; font-variant-numeric: tabular-nums; }
.trend-bar { transition: opacity 0.15s; }
.trend-bar.income { fill: var(--color-income); }
.trend-bar.expenses { fill: var(--color-expense); }
.trend-hatch { pointer-events: none; }
.trend-hatch-line { fill: rgb(255 255 255 / 0.3); }
.trend-bar:focus { outline: none; }
.trend-bar:focus-visible { stroke: var(--color-text); stroke-width: 2; }
.trend-chart:has(.is-active) .trend-bar:not(.is-active) { opacity: 0.55; }
.trend-months { display: grid; grid-template-columns: repeat(6, 1fr); margin-top: 6px; text-align: center; }
.balance-chart { display: block; overflow: visible; margin-top: 4px; }
.balance-line { stroke-width: 2; stroke-linecap: round; }
.balance-dot { stroke: var(--color-surface); stroke-width: 2; }
.balance-line.surplus { stroke: var(--status-good); }
.balance-dot.surplus { fill: var(--status-good); }
.balance-line.deficit { stroke: var(--status-critical); }
.balance-dot.deficit { fill: var(--status-critical); }
.balance-line.zero { stroke: var(--color-balance-zero); }
.balance-dot.zero { fill: var(--color-balance-zero); }
.balance-hit { fill: transparent; cursor: default; }
.balance-hit:focus { outline: none; }
.balance-hit:focus-visible { stroke: var(--color-text); stroke-width: 2; fill: none; }
@media (prefers-reduced-motion: reduce) { .trend-bar { transition: none; } }
td.wrap { white-space: normal; min-width: 14rem; }
td.negative { color: var(--color-danger); }
tfoot th, tfoot td { border-top: 2px solid var(--color-border); border-bottom: 0; font-weight: 700; }
tfoot th { text-transform: none; letter-spacing: 0; font-size: 0.9rem; color: var(--color-text); background: none; }

/* Status: icon + word, in a status colour (never colour alone). */
:root {
  --status-good: #1d6b45;
  --status-warning: #8a5300;
  --status-critical: #b42318;
}
/* Status as a pill: icon + word on a pale tint, never colour alone. Readable on
   light cards and on the dark balance panel. */
.health-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
}
.health-status.healthy, .health-status.surplus { background: #e1f5ee; color: #085041; }
.health-status.building { background: #faeeda; color: #633806; }
.health-status.deficit { background: #fcebeb; color: #791f1f; }
.health-status.balanced { background: #eceef0; color: #3d4248; }

/* The balance panel: the headline balance and gauge in the brand's panel colours
   (Pinnacle: dark teal; ELIC: light, with a border). */
.balance-panel {
  margin: 4px 0 16px;
  padding: 28px clamp(16px, 4vw, 32px) 22px;
  border-radius: calc(var(--radius-card) - 6px);
  border: 1px solid var(--color-hero-border);
  background: var(--color-hero-bg);
  color: var(--color-hero-text);
}
.balance-panel .hero { margin-bottom: 20px; }
.balance-panel .hero-value { color: var(--color-hero-strong); }
.balance-panel .hero-context, .balance-panel .gauge-scale { color: var(--color-hero-muted); }
.balance-panel .hero-context strong { color: var(--color-hero-strong); }
.balance-panel .meter { margin-bottom: 0; }
.balance-panel .health-gauge .gauge-zero { stroke: var(--color-hero-muted); }
.balance-panel .health-gauge .gauge-marker { stroke: #ffffff; }
/* The light version (progress toward the profile): page background, normal text. */
.balance-panel.light { background: var(--color-bg); border: 1px solid var(--color-border); color: var(--color-text); }
.balance-panel.light .hero-value, .balance-panel.light .hero-context strong { color: var(--color-text); }
.balance-panel.light .hero-context, .balance-panel.light .meter-scale { color: var(--color-muted); }

.health-gauge { display: block; overflow: visible; }
.health-gauge .zone-deficit { fill: #f8dcd9; }
.health-gauge .zone-building { fill: var(--color-track); }
.health-gauge .zone-healthy { fill: #d5ecdf; }
.health-gauge .gauge-zero { stroke: var(--color-muted); stroke-width: 1; }
.health-gauge .gauge-marker { stroke: var(--color-surface); stroke-width: 2; }
.health-gauge .gauge-marker.healthy { fill: var(--status-good); }
.health-gauge .gauge-marker.building { fill: var(--status-warning); }
.health-gauge .gauge-marker.deficit { fill: var(--status-critical); }
/* Labels under -1, 0, 2 and 3 months: the gauge's 0%, 25%, 75% and 100% points. */
.gauge-scale { display: grid; grid-template-columns: 25% 50% 25%; margin-top: 6px; }
.gauge-scale span:nth-child(1) { grid-column: 1; }
.gauge-scale span:nth-child(2) { grid-column: 2; }
.gauge-scale span:nth-child(3) { grid-column: 3; grid-row: 1; justify-self: start; }
.gauge-scale span:nth-child(4) { grid-column: 3; grid-row: 1; justify-self: end; }

/* ==========================================================================
   Profile Builder
   ========================================================================== */
.page-wide { max-width: none; }

.filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px 16px; margin-bottom: 18px; }
.filters .field { display: flex; flex-direction: column; gap: 4px; }
.filters .field-grow { flex: 1 1 14rem; }
.filters select { min-width: 9rem; }

.pb-status {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  border: 1px solid var(--color-border);
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
}
.pb-status-open { border-color: var(--color-accent); color: var(--color-accent); }
.pb-status-submitted { background: var(--color-accent-soft); border-color: var(--color-accent); color: var(--color-accent-strong); }
.pb-status-locked { background: var(--color-surface-alt); color: var(--color-muted); }
.pb-status-declined { border-color: var(--color-danger); color: var(--color-danger); }
.pb-status-ready { border-color: var(--color-accent); color: var(--color-accent); }
.pb-status-draft { border-style: dashed; color: var(--color-muted); }

/* Profile Builder home: budgets, then templates in a section of their own. */
.pb-home-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin-bottom: 12px; }
.pb-home-head h2 { margin: 0; margin-right: auto; }
.pb-home-table { width: 100%; table-layout: fixed; }
.pb-home-table .pb-col-year { width: 22%; }
.pb-home-table .pb-col-wide { width: 20%; }
.pb-home-table th[scope="row"] { font-weight: 600; text-align: left; }
/* "View older years": the same columns, so its rows line up with the table above. */
.pb-home-more { margin-top: 8px; }
.pb-home-more summary {
  display: inline-block;
  padding: 6px 0;
  font-weight: 600;
  color: var(--color-accent);
  cursor: pointer;
  list-style: none;
}
.pb-home-more summary::-webkit-details-marker { display: none; }
.pb-home-more summary::before { content: "▸ "; }
.pb-home-more[open] summary::before { content: "▾ "; }
.pb-home-more .pb-more-open, .pb-home-more[open] .pb-more-closed { display: none; }
.pb-home-more[open] .pb-more-open { display: inline; }
.pb-home-table .pb-home-repeat th { height: 0; padding-top: 0; padding-bottom: 0; border: 0; font-size: 0; line-height: 0; }
.pb-home-table .pb-home-repeat th > * { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.pb-home-table thead .pb-status { font-size: 0.75rem; }
.pb-home-templates { margin-top: 32px; background: var(--color-surface-alt); }
.pb-home-templates .table-wrap { background: var(--color-surface); border-radius: var(--radius); }
.pb-home-subhead { margin: 24px 0 4px; font-size: 1rem; }

.pb-setup { margin: 6px 0 0; }
.pb-summary { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.pb-summary .eyebrow { margin: 0; }
.pb-total { font-size: 2rem; font-weight: 700; line-height: 1.15; font-variant-numeric: tabular-nums; }
.pb-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.pb-note { margin-bottom: 16px; }
a.button-secondary { display: inline-block; text-decoration: none; }
.pb-row-buttons { display: flex; gap: 6px; }
.pb-row-buttons a { padding: 3px 10px; font-size: 0.72rem; }

.pb-dialog {
  max-width: 26rem;
  padding: 20px 22px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  background: var(--color-surface);
  color: var(--color-text);
}
.pb-dialog::backdrop { background: rgb(0 0 0 / 0.35); }
.pb-dialog p { margin: 0 0 18px; }
.pb-dialog-buttons { display: flex; justify-content: flex-end; gap: 10px; }

/* The budget grid: line items down the side, months across. */
.pb-sheet-card { padding: 0; overflow: hidden; }
.pb-sheet-wrap { max-height: calc(100vh - 160px); min-height: 18rem; overflow: auto; }
.pb-sheet { font-size: 0.85rem; }
.pb-sheet th, .pb-sheet td { padding: 5px 8px; }
.pb-sheet thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--color-surface-alt);
}
.pb-sheet .pb-label {
  position: sticky;
  left: 0;
  z-index: 1;
  min-width: 15rem;
  max-width: 20rem;
  overflow: hidden;
  text-overflow: ellipsis;
  background: var(--color-surface);
  text-align: left;
  text-transform: none;
  letter-spacing: normal;
  font-size: 0.85rem;
  font-weight: 400;
  color: var(--color-text);
  border-right: 1px solid var(--color-border);
}
.pb-sheet thead .pb-label { z-index: 3; background: var(--color-surface-alt); font-weight: 700; }
.pb-sheet tbody tr:hover .pb-label { background: var(--color-surface-alt); }
.pb-sheet .pb-row-total { font-weight: 600; border-left: 1px solid var(--color-border); }
.pb-sheet tr.pb-parent td, .pb-sheet tr.pb-parent .pb-label { font-weight: 600; }
/* Sums shown after their rows: sections (Monthly, Annual / Periodic) and, heavier, Grand Total. */
.pb-sheet tr.pb-total-line td, .pb-sheet tr.pb-total-line .pb-label {
  background: var(--color-surface-alt);
  border-top: 1px solid var(--color-muted);
}
.pb-sheet tr.pb-total-line.pb-depth-0 td, .pb-sheet tr.pb-total-line.pb-depth-0 .pb-label {
  border-top: 2px solid var(--color-text);
}
.pb-sheet tr.pb-tax td, .pb-sheet tr.pb-tax .pb-label { color: var(--color-muted); font-style: italic; }
.pb-depth-1 .pb-label { padding-left: 22px; }
.pb-depth-2 .pb-label { padding-left: 36px; }
.pb-depth-3 .pb-label { padding-left: 50px; }
.pb-depth-4 .pb-label { padding-left: 64px; }
.pb-depth-5 .pb-label, .pb-depth-6 .pb-label { padding-left: 78px; }
.pb-sheet input {
  width: 6.5rem;
  max-width: none;
  padding: 3px 6px;
  text-align: right;
  font-variant-numeric: tabular-nums;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
}
.pb-sheet input:focus { outline: 2px solid var(--color-accent); outline-offset: -1px; }
.pb-sheet input.pb-changed { background: var(--color-accent-soft); border-color: var(--color-accent); }
/* Months the budget leaves out (GAP's summer): narrow, with a + to add them back. */
.pb-sheet .pb-month-off {
  width: 2.25rem;
  min-width: 2.25rem;
  padding: 5px 2px;
  text-align: center;
  color: var(--color-muted);
  background: repeating-linear-gradient(
    -45deg, var(--color-surface-alt) 0 4px, var(--color-surface) 4px 8px
  );
}
.pb-sheet thead .pb-month-off { background: var(--color-surface-alt); font-weight: 400; }
.pb-sheet thead .pb-month-off span { display: block; }
.pb-month-button,
.pb-row-remove {
  min-height: 0;
  padding: 0 5px;
  font-size: 0.85rem;
  line-height: 1.3;
  color: var(--color-accent);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  cursor: pointer;
}
.pb-month-button:hover,
.pb-row-remove:hover { background: var(--color-accent-soft); border-color: var(--color-accent); }
.pb-row-remove { float: right; margin-left: 6px; color: var(--color-muted); }
.pb-add-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid var(--color-border);
}
.pb-add-row select { max-width: 32rem; }
.pb-add-row .pb-help { flex-basis: 100%; margin: 0; }

.pb-save-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 5;
  box-shadow: 0 -2px 8px rgb(0 0 0 / 0.08);
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 16px;
  padding: 12px 16px;
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
}
.pb-preview-note { font-size: 0.8rem; }
.pb-preview-note.pb-unsaved { color: var(--color-accent-strong); font-weight: 600; }
.pb-sheet input.pb-invalid { border-color: var(--color-danger); background: var(--color-surface); color: var(--color-danger); }
/* Room for the fixed save bar, so it never covers the last rows or the footer. */
.page-wide:has(.pb-save-bar) { padding-bottom: 84px; }

/* Profile Builder's own menu: the main menu's rounded highlight, one size down. */
.pb-subnav { display: flex; flex-wrap: wrap; gap: 4px 6px; margin: -6px 0 20px; }
.pb-subnav a {
  padding: 6px 12px;
  border-radius: var(--radius);
  color: var(--color-muted);
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.15s, color 0.15s;
}
.pb-subnav a:hover { background: var(--color-surface-alt); color: var(--color-text); }
.pb-subnav a[aria-current="page"] { background: var(--color-accent-soft); color: var(--color-accent-strong); }

/* Profile Builder forms and lists */
.pb-form { max-width: 60rem; }
.pb-form h2 { margin: 10px 0 0; }
.pb-form-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 14px 18px; }
.pb-field label, .pb-field legend { display: block; margin-bottom: 4px; font-size: 0.875rem; font-weight: 600; }
.pb-field fieldset { margin: 0; padding: 0; border: 0; }
.pb-field fieldset > div { display: flex; flex-wrap: wrap; gap: 4px 14px; }
.pb-field fieldset label { display: inline-flex; align-items: center; gap: 6px; margin: 0; font-weight: 400; }
.pb-field input[type="number"] { width: 100%; max-width: 28rem; padding: 9px 12px; border: 1px solid var(--color-border); border-radius: var(--radius); background: var(--color-surface); }
.pb-check { display: inline-flex; align-items: center; gap: 8px; font-weight: 400; }
.pb-help { margin: 4px 0 0; font-size: 0.8rem; }
.pb-rules-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(18rem, 1fr)); gap: 16px 24px; }
.pb-rules-grid fieldset > div { max-height: 12rem; overflow: auto; padding: 8px; border: 1px solid var(--color-border); border-radius: var(--radius); flex-direction: column; flex-wrap: nowrap; }
.pb-actions-left { justify-content: flex-start; }
.pb-picked summary { cursor: pointer; font-weight: 600; }
.pb-picked ul { margin: 8px 0 0; padding-left: 20px; max-height: 12rem; overflow: auto; font-size: 0.875rem; }

.pb-bulk-bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 10px; }
.pb-bulk-bar button[disabled] { opacity: 0.45; cursor: not-allowed; }

.pb-tree .pb-label { min-width: 18rem; }
.pb-tree .pb-label a { color: inherit; }
.pb-tree td { white-space: normal; }
.pb-tree tr.pb-retired th, .pb-tree tr.pb-retired td { color: var(--color-muted); text-decoration: line-through; }
.pb-rules span { display: block; font-size: 0.8rem; }
.pb-row-buttons form { display: flex; gap: 4px; }
.pb-icon-button { padding: 2px 8px; font-size: 0.85rem; }

/* --- Currency switch (dashboard header) ------------------------------------ */
.head-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.currency-switch form { display: inline-flex; }
.currency-switch { display: inline-flex; border: 1px solid var(--color-border); border-radius: var(--radius); overflow: hidden; }
.currency-option {
  padding: 5px 12px;
  border: 0;
  background: var(--color-surface);
  color: var(--color-muted);
  font: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-decoration: none;
  cursor: pointer;
}
.currency-option + .currency-option { border-left: 1px solid var(--color-border); }
.currency-option:hover { color: var(--color-text); }
.currency-option[aria-pressed="true"], .currency-option[aria-current="true"] {
  background: var(--color-accent);
  color: var(--color-on-accent);
}
@media (max-width: 640px) { .head-actions { align-items: flex-start; } }

/* --- Year selector and past years ------------------------------------------- */
/* The "Profile year" line under the title is the selector: it reads as text,
   with a light outline so it's still clearly something to change. */
.page-eyebrow { margin-bottom: 4px; }
/* The profile year and fund as small rounded pills under the greeting; the year
   pill holds the selector, which reads as text inside it. */
.profile-year { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 10px 0 0; }
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  background: var(--color-surface);
  color: var(--color-muted);
  font-size: 0.85rem;
}
.year-select { display: inline-flex; align-items: center; gap: 6px; margin: 0; }
.year-select label { margin: 0; white-space: nowrap; font: inherit; color: inherit; }
.year-select select {
  width: auto;
  max-width: none;
  padding: 0 2px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--color-text);
  font: inherit;
  cursor: pointer;
}
.pill:has(select:hover) { border-color: var(--color-muted); }
.past-bars { display: grid; gap: 12px; margin-bottom: 18px; }
.past-row { display: grid; gap: 6px; }
.past-label { font-size: 0.9rem; }
.past-label strong { margin-left: 6px; }
.meter-segment.spent { fill: var(--color-expense); }
.meter-segment.deficit { fill: var(--status-critical); }
/* Gross salary: the calculated amount shows as the placeholder; a typed override is marked. */
.pb-sheet input::placeholder { color: var(--color-muted); opacity: 1; }
.pb-sheet input.pb-overridden { border-color: var(--color-accent); border-style: dashed; font-weight: 600; }

/* Budget / template tabs: the sheet and the salary calculation. */
.pb-tabs { display: flex; gap: 4px; margin: 0 0 14px; border-bottom: 1px solid var(--color-border); }
.pb-tabs a {
  padding: 8px 14px;
  border: 1px solid transparent;
  border-bottom: 0;
  border-radius: var(--radius) var(--radius) 0 0;
  color: var(--color-muted);
  font-weight: 600;
  text-decoration: none;
  margin-bottom: -1px;
}
.pb-tabs a:hover { color: var(--color-text); }
.pb-tabs a[aria-current="page"] {
  color: var(--color-text);
  background: var(--color-surface);
  border-color: var(--color-border);
  border-top: 3px solid var(--color-accent-decor);
}

/* Salary tab */
.pb-earner { margin-bottom: 18px; }
.pb-earner-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px 16px; margin-bottom: 10px; }
.pb-earner-head h2 { margin: 0; }
.pb-salary-table td, .pb-salary-table th { padding: 8px 10px; }
.pb-salary-table tfoot td, .pb-salary-table tfoot th { font-weight: 600; border-top: 1px solid var(--color-muted); background: var(--color-surface-alt); }
.pb-month-strip { font-size: 0.85rem; }
.pb-month-strip td.pb-two-paydays { font-weight: 700; }
.pb-period-form { margin-top: 14px; padding: 14px; border: 1px solid var(--color-border); border-radius: var(--radius); background: var(--color-surface-alt); }
.pb-period-form h3 { margin: 0 0 10px; font-size: 1rem; }
.pb-period-form .pb-form-grid { grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); }
.pb-period-form input[type="number"] { max-width: 10rem; }
.pb-warning { color: var(--color-danger); font-size: 0.875rem; }
.pb-inline-form { display: inline; }
/* Canadian budgets: the estimated CAD total under the USD one. */
.pb-cad-total { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; margin-top: 4px; padding-top: 6px; border-top: 1px dashed var(--color-border); }
.pb-total.pb-total-cad { font-size: 1rem; font-weight: 600; color: var(--color-muted); }
.pb-rate-note { font-size: 0.78rem; text-align: right; max-width: 18rem; }
.pb-cad-note { margin: 0 0 12px; }
.pb-tax-fields { margin-top: 10px; align-items: end; }
.pb-field-wrap[hidden] { display: none; }
.pb-plan { display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: 0.85rem; }
.pb-plan select { width: auto; padding: 4px 8px; }
.pb-plan button { padding: 4px 10px; }
/* Set-cost rows (from the Profile Matrix): a light tint; hovering the name says so. */
.pb-sheet tr.pb-set-cost td, .pb-sheet tr.pb-set-cost .pb-label {
  background: color-mix(in srgb, #e9b949 12%, var(--color-surface));
}
.pb-sheet tr.pb-set-cost .pb-label { cursor: help; box-shadow: inset 3px 0 0 #e0b84a; }
.pb-set-cost-note { display: block; font-size: .8125rem; color: var(--color-muted); }

/* ==========================================================================
   Motion: small and quick. Buttons lift slightly on hover, tab underlines
   ease in, and bars grow in once when the page loads. All of it is off for
   people whose system asks for reduced motion.
   ========================================================================== */

.button, .button-secondary, button[type="submit"], .tablist [role="tab"] {
  transition: background-color 0.15s, border-color 0.15s, color 0.15s, transform 0.15s, box-shadow 0.15s;
}
.button:hover,
.button-secondary:hover,
button[type="submit"]:not(.link-button):not(.icon-button):not(.currency-option):not(.menu-item):hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgb(16 28 34 / 0.1);
}
.meter-segment, .health-gauge rect {
  transform-box: fill-box;
  transform-origin: left center;
  animation: bar-grow 0.6s ease-out;
}
@keyframes bar-grow { from { transform: scaleX(0); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
  .button:hover, .button-secondary:hover, button[type="submit"]:hover { transform: none; }
}

/* Pinnacle reads slightly larger, as on the new Pinnacle site. */
[data-brand="pinnacle"] body { font-size: 1.0625rem; }

/* Line items: the retire bar above the tree, and the tick column. */
.pb-retire-bar { padding: 12px 16px; border-bottom: 1px solid var(--color-border); }
.pb-retire-label { font-weight: 600; }
.pb-retire-bar .pb-actions { align-items: center; flex-wrap: nowrap; }
.pb-retire-bar select { width: auto; min-width: 8rem; }
.pb-sheet .pb-tick { width: 2rem; text-align: center; }
.pb-sheet .pb-tick input { width: auto; }

/* Month picker (static/js/month-picker.js): the year with arrows, then twelve months. */
.month-picker { position: relative; display: inline-block; }
.month-picker-toggle {
  min-width: 12rem;
  padding: 8px 12px;
  font: inherit;
  text-align: left;
  color: var(--color-text);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  cursor: pointer;
}
.month-picker-toggle::after { content: " \25BE"; float: right; color: var(--color-muted); }
.month-picker-panel {
  position: absolute;
  z-index: 20;
  top: calc(100% + 6px);
  left: 0;
  width: 17rem;
  padding: 12px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  box-shadow: 0 8px 24px rgb(0 0 0 / 0.15);
}
.month-picker-head { display: flex; align-items: center; justify-content: center; gap: 18px; margin-bottom: 10px; }
.month-picker-year { min-width: 4ch; font-weight: 700; text-align: center; }
.month-picker-arrow {
  padding: 2px 6px;
  font-size: 0.8rem;
  color: var(--color-accent);
  background: none;
  border: 0;
  cursor: pointer;
}
.month-picker-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  padding: 8px 0;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}
.month-picker-month {
  padding: 8px 0;
  font: inherit;
  font-weight: 600;
  color: var(--color-accent);
  background: none;
  border: 1px solid transparent;
  border-radius: 999px;
  cursor: pointer;
}
.month-picker-month:hover { background: var(--color-accent-soft); }
.month-picker-month.is-today { border-color: var(--color-border); }
.month-picker-month[aria-pressed="true"] { color: var(--color-on-accent); background: var(--color-accent); }
.month-picker-foot { display: flex; justify-content: flex-end; padding-top: 8px; }
.month-picker-cancel { font: inherit; font-weight: 600; color: var(--color-accent); background: none; border: 0; cursor: pointer; }

/* Cost center reports: the checkbox lists in columns, the totals table compact. */
.pb-cc-form ul { display: flex; flex-wrap: wrap; gap: 4px 18px; margin: 0; padding: 0; list-style: none; }
.pb-cc-form ul label { display: inline-flex; align-items: center; gap: 6px; font-weight: 400; }
.pb-cc-table th[scope="row"] { text-align: left; font-weight: 600; white-space: nowrap; }
.pb-cc-table .pb-row-total { font-weight: 700; }

/* Progress report (finance/templates/finance/progress.html) */
.progress-filter { display: grid; gap: 12px; }
.progress-filter fieldset { margin: 0; padding: 0; border: 0; }
.progress-filter legend { margin-bottom: 6px; font-weight: 600; }
.progress-statuses { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.progress-status { display: inline-flex; align-items: center; gap: 6px; }
.progress-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.progress-hint { margin: 0; font-size: 0.85rem; }
.progress-table thead th { background: #1f2328; color: #fff; }
.progress-table thead th a { color: inherit; text-decoration: none; }
.progress-table thead th a:hover { text-decoration: underline; }
.progress-name a { font-weight: 600; }
.progress-sub { display: block; font-size: 0.75rem; font-weight: 400; color: var(--color-muted); }
.progress-percent { font-weight: 600; color: #1f2328; }
.progress-table td.pct-0 { background: #f28e86; }
.progress-table td.pct-1 { background: #f49d80; }
.progress-table td.pct-2 { background: #f6ab7a; }
.progress-table td.pct-3 { background: #f9ba74; }
.progress-table td.pct-4 { background: #fbc86e; }
.progress-table td.pct-5 { background: #fdd768; }
.progress-table td.pct-6 { background: #e5d472; }
.progress-table td.pct-7 { background: #cdd27b; }
.progress-table td.pct-8 { background: #b5d085; }
.progress-table td.pct-9 { background: #9dcd8e; }
.progress-table td.pct-10 { background: #85cb98; }
