/* ICE-DA design system: International Consulting Engineers' look as icengineers.net renders
 * it (measured September 30, 2026). Silver #C7CACC page, grey #575F66 header with the black ICE
 * logo, a dark slate nav bar (#39414B) whose current item is silver, navy #0B2A4A buttons,
 * slate #1F2933 text and headings, a grey-blue #6B7280 band for headline numbers, white cards,
 * square corners. Roboto Bold for headings and figures; Nunito Sans stands in for the site's
 * Avenir text. The site has no dark mode, so neither does ICE-DA.
 *
 * Status colors mean one thing each and nothing else:
 *   yellow = check soon (aging)   red = out of date   gold, dashed = estimate or projected
 *   steel blue = open / published
 *
 * Templates must not use inline style attributes: the site's CSP only allows this file.
 */

@font-face {
  font-family: "Nunito Sans";
  font-style: normal;
  font-weight: 200 1000;
  font-display: swap;
  src: url("../vendor/fonts/nunito-sans-latin-wght-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304,
    U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Nunito Sans";
  font-style: normal;
  font-weight: 200 1000;
  font-display: swap;
  src: url("../vendor/fonts/nunito-sans-latin-ext-wght-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308,
    U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113,
    U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Roboto";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../vendor/fonts/roboto-latin-wght-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304,
    U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Roboto";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../vendor/fonts/roboto-latin-ext-wght-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308,
    U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113,
    U+2C60-2C7F, U+A720-A7FF;
}

/* ---------------------------------------------------------------- tokens */

:root {
  color-scheme: light;

  /* From the site's Wix theme and its rendered pages. */
  --silver: #c7cacc;
  --header: #575f66;
  --nav: #39414b;
  --band: #6b7280;
  --footer: #8f9499;
  --navy: #0b2a4a;
  --navy-hover: #123c66;
  --steel: #3a5f7d;
  --slate: #1f2933;
  --grey: #575f66;
  --gold: #b08d57;

  --page: var(--silver);
  --panel: #ffffff;
  --panel-2: #f1f2f3;
  --text: var(--slate);
  --muted: var(--grey);
  --line: #d9dbdd;
  --line-strong: var(--footer);
  --link: var(--navy);

  --check: #ffcb05;
  --check-edge: #a38100;
  --stale: #c4161c;
  --stale-edge: #8e1014;
  --gold-text: #7a5c2e;
  --gold-soft: #f3ece1;
  --gold-hatch: #dfcbaa;
  --open: var(--steel);

  --focus: var(--navy);

  --heading: "Roboto", "Segoe UI", Arial, sans-serif;
  --body: "Nunito Sans", "Segoe UI", Arial, sans-serif;

  --gutter: 1.5rem;
  --measure: 68ch;
}

/* ---------------------------------------------------------------- base */

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

html {
  font-family: var(--body);
  font-size: 100%;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--page);
  color: var(--text);
  font-size: 1rem;
  line-height: 1.5;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--heading);
  font-weight: 700;
  line-height: 1.15;
  color: var(--slate);
}

h1 {
  font-size: 2.25rem;
}

h2 {
  font-size: 1.25rem;
}

h3 {
  font-size: 1rem;
}

p {
  margin: 0;
  max-width: var(--measure);
}

a {
  color: var(--link);
  text-underline-offset: 0.18em;
}

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

.muted {
  color: var(--muted);
}

.num {
  font-family: var(--heading);
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -3rem;
  z-index: 10;
  padding: 0.5rem 0.75rem;
  background: var(--panel);
  color: var(--text);
  border: 2px solid var(--navy);
}

.skip-link:focus {
  top: 0.5rem;
}

/* ---------------------------------------------------------------- header, as on the site */

.topbar {
  display: flex;
  align-items: center;
  gap: 2rem;
  min-height: 5rem;
  padding: 0 var(--gutter);
  background: var(--header);
  color: #ffffff;
}

.topbar :focus-visible {
  outline-color: #ffffff;
}

.brand {
  display: flex;
  align-items: center;
}

.brand img {
  height: 52px;
  width: auto;
}

/* The site's nav: one dark slate bar, the current page in silver. */
.nav {
  display: flex;
  margin: 0;
  padding: 0;
  list-style: none;
  background: var(--nav);
}

.nav a {
  display: block;
  padding: 0.875rem 1.125rem;
  color: #ffffff;
  font-family: var(--body);
  font-weight: 400;
  text-decoration: none;
}

.nav a:hover {
  background: #4a525c;
}

.nav a[aria-current="page"] {
  background: var(--silver);
  color: var(--slate);
}

.account {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 0 0 0 auto;
}

.who {
  color: #ffffff;
  font-size: 0.875rem;
}

.dev-banner {
  padding: 0.3125rem var(--gutter);
  background: var(--panel-2);
  color: var(--muted);
  border-bottom: 1px dashed var(--line-strong);
  font-size: 0.8125rem;
  font-weight: 600;
}

/* ---------------------------------------------------------------- page */

.page {
  max-width: 82rem;
  margin: 0 auto;
  padding: 2rem var(--gutter) 4rem;
}

.panel {
  background: var(--panel);
}

.panel-head {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  padding: 1rem 1.25rem 0.875rem;
  border-bottom: 1px solid var(--line);
}

/* An (i) button in a panel heading sits after the count; its text opens below the heading. */
.panel-head {
  position: relative;
}

.panel-head .why summary {
  position: static;
}

.panel-head .why p {
  position: absolute;
  top: 100%;
  right: 0;
  left: 0;
  z-index: 2;
  margin: 0;
  padding: 0.75rem 1.25rem;
  border: 1px solid var(--line);
  background: var(--panel);
}

.panel-head .count {
  color: var(--muted);
  font-family: var(--heading);
  font-variant-numeric: tabular-nums;
}

.panel-head .end {
  margin-left: auto;
}

.panel-body {
  padding: 1.25rem;
}

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

.button {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.6875rem 1.25rem;
  border: 1px solid var(--navy);
  background: var(--navy);
  color: #ffffff;
  font: inherit;
  font-family: var(--body);
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
}

.button:hover {
  background: var(--navy-hover);
  border-color: var(--navy-hover);
}

.button--outline {
  background: transparent;
  color: var(--navy);
}

.button--outline:hover {
  background: var(--panel-2);
  color: var(--navy);
}

.button--small {
  padding: 0.4375rem 0.875rem;
  font-size: 0.875rem;
}

.button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ---------------------------------------------------------------- flash messages */

.flash {
  max-width: var(--measure);
  margin: 0 0 1.5rem;
  padding: 0.75rem 1rem;
  background: var(--panel);
  border-left: 4px solid var(--steel);
}

.flash-error {
  border-left-color: var(--stale);
}

/* ---------------------------------------------------------------- status chips and marks */

.status {
  display: inline-block;
  padding: 0.0625rem 0.4375rem;
  border: 1px solid;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1.5;
  white-space: nowrap;
}

.status--current {
  border-color: var(--line);
  color: var(--muted);
}

.status--check {
  background: var(--check);
  border-color: var(--check-edge);
  color: var(--slate);
}

.status--stale {
  background: var(--stale);
  border-color: var(--stale-edge);
  color: #ffffff;
}

.status--estimate {
  background: var(--gold-soft);
  border: 1px dashed var(--gold);
  color: var(--gold-text);
}

.status--published {
  border-color: var(--open);
  color: var(--open);
}

/* ---------------------------------------------------------------- organization page */

.org-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1rem;
  margin-bottom: 1.25rem;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.org-head .tags {
  flex-basis: 100%;
}

.tags li {
  padding: 0.125rem 0.625rem;
  background: var(--panel);
  color: var(--slate);
  font-size: 0.875rem;
}

.badge {
  padding: 0.0625rem 0.5rem;
  background: var(--panel);
  border: 1px dashed var(--line-strong);
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1.5;
}

.sheet {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 20rem;
  gap: 1.25rem;
  align-items: start;
}

/* minmax(0, 1fr): without it the track grows to the calendar's minimum width on phones
   instead of letting the table scroll inside its region. */
.sheet-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.25rem;
  min-width: 0;
}

/* Key figures: white cards on the silver page, like the site's service grid. Flex rather than
   grid, so a short last row stretches instead of leaving empty cells. */
/* A grid, so a tile that wraps onto a new row keeps the width of the ones above it. */
.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(10.5rem, 1fr));
  gap: 2px;
}

.tile {
  position: relative;
  display: grid;
  flex: 1 1 10.5rem;
  align-content: start;
  gap: 0.125rem;
  padding: 1.125rem 1.25rem 1rem;
  background: var(--panel);
}

.tile-top {
  display: flex;
  align-items: center;
  min-height: 2.5rem;
  padding-right: 1.75rem;
}

.tile-value {
  color: var(--navy);
  font-family: var(--heading);
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}

.tile--no .tile-value {
  color: var(--muted);
}

.tile-label {
  font-weight: 700;
}

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

.tile-link {
  margin-top: 0.25rem;
  font-size: 0.875rem;
  font-weight: 700;
}

/* The reason behind a figure, behind an info button in the tile's corner. */
.why summary {
  position: absolute;
  top: 0.875rem;
  right: 0.875rem;
  display: grid;
  place-items: center;
  width: 1.75rem;
  height: 1.75rem;
  color: var(--muted);
  cursor: pointer;
  list-style: none;
}

.why summary::-webkit-details-marker {
  display: none;
}

.why summary svg {
  width: 1.125rem;
  height: 1.125rem;
}

.why summary:hover,
.why[open] summary {
  color: var(--navy);
}

.why p {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.875rem;
}

.rev-source {
  display: block;
  font-weight: 700;
}

.rev-date {
  display: block;
  color: var(--muted);
  font-family: var(--heading);
  font-variant-numeric: tabular-nums;
}

/* ---------------------------------------------------------------- tables */

.table-scroll {
  position: relative;
  max-width: 100%;
  overflow-x: auto;
}

.data {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

.data th {
  padding: 0.625rem 1rem;
  background: var(--panel-2);
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 700;
  text-align: left;
  vertical-align: bottom;
  border-bottom: 1px solid var(--line);
}

/* text-wrap-style, not the text-wrap shorthand: the shorthand resets the wrap mode and
   would undo white-space: nowrap on number cells. */
.data td {
  padding: 0.75rem 1rem;
  vertical-align: top;
  border-bottom: 1px solid var(--line);
  text-wrap-style: pretty;
}

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

.data tbody tr:hover td {
  background: var(--panel-2);
}

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

.data .id {
  display: block;
  color: var(--muted);
  font-family: var(--heading);
  font-size: 0.8125rem;
  font-variant-numeric: tabular-nums;
}

.cap {
  display: block;
  color: var(--muted);
  font-size: 0.75rem;
}

/* ---------------------------------------------------------------- application calendar */

.cal {
  width: 100%;
  min-width: 46rem;
  border-collapse: collapse;
  font-size: 0.875rem;
  table-layout: fixed;
}

.cal col.cal-name {
  width: 14rem;
}

.cal th {
  padding: 0.375rem 0.125rem;
  color: var(--muted);
  font-family: var(--heading);
  font-weight: 500;
  font-size: 0.8125rem;
  text-align: center;
}

.cal abbr[title] {
  text-decoration: none;
}

.cal thead tr:first-child th {
  padding-top: 0.75rem;
  color: var(--text);
  font-weight: 700;
  text-align: left;
}

.cal th.year-start,
.cal td.year-start {
  border-left: 2px solid var(--line-strong);
}

.cal tbody th {
  padding: 0.5rem 0.75rem 0.5rem 1.25rem;
  color: var(--text);
  font-family: var(--body);
  font-size: 0.875rem;
  font-weight: 700;
  text-align: left;
  border-top: 1px solid var(--line);
}

.cal tbody th .muted {
  display: block;
  font-weight: 400;
}

.cal td {
  padding: 0;
  border-top: 1px solid var(--line);
}

.cal td:last-child span.m {
  margin-right: 1.25rem;
}

.cal span.m {
  display: block;
  height: 1.5rem;
  margin: 0.5rem 1px;
}

.m--open {
  background: var(--open);
}

.m--projected {
  background: repeating-linear-gradient(
    135deg,
    var(--gold-soft) 0 5px,
    var(--gold-hatch) 5px 8px
  );
  outline: 1px dashed var(--gold);
  outline-offset: -1px;
}

.m--closed {
  background: var(--panel-2);
}

.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  margin: 0;
  padding: 0.875rem 1.25rem;
  list-style: none;
  color: var(--muted);
  font-size: 0.8125rem;
  border-top: 1px solid var(--line);
}

.legend--top {
  border-top: 0;
  border-bottom: 1px solid var(--line);
}

.legend li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.legend .m {
  display: inline-block;
  width: 1.75rem;
  height: 0.875rem;
}

.legend .m--closed {
  outline: 1px solid var(--line-strong);
  outline-offset: -1px;
}

/* ---------------------------------------------------------------- empty states */

.empty {
  padding: 1.25rem;
  color: var(--muted);
}

/* ---------------------------------------------------------------- sign-in */

.signin {
  display: grid;
  place-items: center;
  min-height: calc(100vh - 12rem);
}

.signin-card {
  display: grid;
  justify-items: center;
  gap: 2rem;
  width: min(100%, 26rem);
  padding: 3rem 2.5rem 2.75rem;
  background: var(--panel);
}

.signin-card img {
  width: 100%;
  max-width: 18.75rem;
  height: auto;
}

.signin-card .button {
  width: 100%;
  justify-content: center;
}

.ms-logo {
  width: 1.125rem;
  height: 1.125rem;
  flex: none;
}

.dev-login {
  display: flex;
  gap: 0.75rem;
  width: 100%;
  padding-top: 1.25rem;
  border-top: 1px dashed var(--line);
}

.dev-login .button {
  flex: 1;
}

/* ---------------------------------------------------------------- home */

/* The site's numbers band: white Roboto figures on grey-blue #6B7280. */
.home-tiles {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
}

.home-tile {
  display: grid;
  flex: 1 1 14rem;
  align-content: start;
  gap: 0.25rem;
  padding: 1.75rem 1.5rem 1.5rem;
  background: var(--band);
  color: #ffffff;
  text-decoration: none;
}

.home-tile .tile-value {
  color: #ffffff;
  font-size: 3rem;
}

.home-tile .tile-label {
  color: #ffffff;
}

a.home-tile {
  background: var(--navy);
}

a.home-tile:hover {
  background: var(--navy-hover);
}

.home-tile .badge {
  justify-self: start;
  margin-top: 0.75rem;
  background: transparent;
  border-color: rgb(255 255 255 / 0.75);
  color: #ffffff;
}

.home-tile {
  position: relative;
}

.home-tile .why summary {
  color: rgb(255 255 255 / 0.8);
}

.home-tile .why summary:hover,
.home-tile .why[open] summary {
  color: #ffffff;
}

.home-tile .why p {
  color: #ffffff;
  border-top-color: rgb(255 255 255 / 0.35);
}

/* The panels under the numbers band: two columns that stack their panels independently, so a
   long panel doesn't leave a hole beside it; one column on narrow screens. */
.dash {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
  align-items: start;
  margin-top: 1.25rem;
}

/* minmax(0, 1fr), as in .sheet-main: an auto track would grow to a table's minimum width on
   phones instead of letting the table scroll inside its region. */
.dash-col {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.25rem;
  min-width: 0;
}

.dash-wide {
  margin-top: 1.25rem;
}

.data caption {
  padding: 0.25rem 1.25rem 0.625rem;
  color: var(--text);
  font-family: var(--heading);
  font-weight: 700;
  text-align: left;
}

/* Counts as bars: the label and number on one line, the bar under them. */
.bars {
  display: grid;
  gap: 0.75rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.bars li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 0.25rem 1rem;
}

.bar-label {
  font-size: 0.9375rem;
}

.bar-n {
  font-family: var(--heading);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.bar {
  display: block;
  grid-column: 1 / -1;
  width: 100%;
  height: 0.5rem;
}

.bar-track {
  fill: var(--panel-2);
}

.bar-fill {
  fill: var(--navy);
}

.screens {
  display: grid;
  gap: 1.5rem;
}

.screens h3 {
  margin-bottom: 0.75rem;
  color: var(--muted);
  font-size: 0.875rem;
}

/* The application calendar cut to the next few months. On wide screens it scrolls inside its
   panel under a header that stays put. */
.cal--short {
  min-width: 22rem;
}

.cal--short col.cal-name {
  width: 55%;
}

.window-scroll thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--panel);
}

@media (min-width: 64.0625rem) {
  .window-scroll {
    max-height: 30rem;
    overflow-y: auto;
    overscroll-behavior: contain;
  }
}

.source-list {
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.875rem;
}

.source-list li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0 1rem;
  padding: 0.75rem 1.25rem;
  border-bottom: 1px solid var(--line);
}

.source-list li:last-child {
  border-bottom: 0;
}

.source-list .muted {
  grid-column: 1 / -1;
}

.source-status {
  grid-column: 1 / -1;
  margin-top: 0.375rem;
}

.legend--status .status {
  flex: none;
}

.source-list--columns {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(22rem, 1fr));
}

.source-list--columns li:last-child {
  border-bottom: 1px solid var(--line);
}

/* ---------------------------------------------------------------- organization list */

.filters {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 0.75rem 1rem;
  margin-bottom: 1.25rem;
  padding: 1rem 1.25rem;
}

.filter {
  display: grid;
  gap: 0.25rem;
  flex: 1 1 10rem;
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 700;
}

.filter--wide {
  flex-basis: 16rem;
}

.filter input,
.filter select {
  width: 100%;
  min-height: 2.5rem;
  padding: 0.4375rem 0.625rem;
  border: 1px solid var(--line-strong);
  background: var(--panel);
  color: var(--text);
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 400;
}

.data td a {
  font-weight: 700;
  text-decoration: none;
}

.data td a:hover {
  text-decoration: underline;
}

.pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border-top: 1px solid var(--line);
}

.plain-list {
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.9375rem;
}

.plain-list li {
  padding: 0.625rem 1.25rem;
  border-bottom: 1px solid var(--line);
}

.plain-list li:last-child {
  border-bottom: 0;
}

.stack {
  display: grid;
  grid-template-columns: minmax(0, 1fr);  /* lets wide tables scroll inside on phones */
  gap: 1.25rem;
}

/* ---------------------------------------------------------------- connect Claude (MCP) */

.consent {
  max-width: 40rem;
  margin: 2rem auto 0;
}

.consent .panel-head h1 {
  margin: 0;
  font-size: 1.375rem;
}

.consent p {
  margin: 0 0 1rem;
}

.consent .consent-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.5rem 0 0;
}

/* ---------------------------------------------------------------- the Ask tab */

.ask-log {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-height: 12rem;
  max-height: 60vh;
  padding: 1.25rem;
  overflow-y: auto;
}

.ask-hint {
  max-width: var(--measure);
  margin: 0;
}

.ask-msg {
  max-width: 48rem;
  padding: 0.75rem 1rem;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.ask-msg--you {
  align-self: flex-end;
  background: var(--navy);
  color: #ffffff;
}

.ask-msg--claude {
  align-self: flex-start;
  background: var(--panel-2);
}

.ask-msg--wait {
  color: var(--muted);
}

.ask-msg--error {
  border-left: 4px solid var(--stale);
  background: var(--panel-2);
}

.ask-form {
  display: flex;
  gap: 0.75rem;
  align-items: end;
  padding: 1rem 1.25rem;
  border-top: 1px solid var(--line);
}

.ask-form textarea {
  flex: 1 1 auto;
  min-height: 2.75rem;
  padding: 0.5rem 0.625rem;
  border: 1px solid var(--line-strong);
  background: var(--panel);
  color: var(--text);
  font: inherit;
  resize: vertical;
}

.ask-note {
  margin: 0;
  padding: 0 1.25rem 1rem;
  font-size: 0.8125rem;
}

/* ---------------------------------------------------------------- settings */

.settings-intro {
  max-width: var(--measure);
  margin: 0 0 1rem;
}

.settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
  gap: 0.75rem 1rem;
}

/* ---------------------------------------------------------------- accounts */

.filters--flat {
  margin: 0;
  border-bottom: 1px solid var(--line);
}

.inline-form,
.account-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

.inline-form select {
  min-height: 2.125rem;
  padding: 0.25rem 0.5rem;
  border: 1px solid var(--line-strong);
  background: var(--panel);
  color: var(--text);
  font: inherit;
  font-size: 0.875rem;
}

.confirm summary {
  list-style: none;
}

.confirm summary::-webkit-details-marker {
  display: none;
}

.confirm[open] {
  display: flex;
  gap: 0.5rem;
}

.button--danger {
  border-color: var(--stale);
  background: var(--stale);
}

.button--danger:hover {
  border-color: var(--stale-edge);
  background: var(--stale-edge);
}

.accounts td:last-child {
  white-space: nowrap;
}

/* ---------------------------------------------------------------- small screens */

@media (max-width: 64rem) {
  .sheet,
  .dash {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 40rem) {
  :root {
    --gutter: 1rem;
  }

  h1 {
    font-size: 1.75rem;
  }

  .topbar {
    flex-wrap: wrap;
    gap: 0.75rem 1rem;
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
  }

  .brand img {
    height: 40px;
  }

  .nav {
    order: 3;
    flex-basis: 100%;
    flex-wrap: wrap;
  }

  .nav a {
    padding: 0.625rem 0.875rem;
  }

  .who {
    display: none;
  }

  .page {
    padding-top: 1.25rem;
  }

  .table-scroll .data {
    min-width: 36rem;
  }

  .table-scroll .data td:first-child,
  .table-scroll .data th:first-child {
    min-width: 11rem;
  }

  .signin-card {
    padding: 2rem 1.5rem;
  }

  /* Two headline figures to a row instead of four stacked. */
  .home-tile {
    flex-basis: 40%;
    padding: 1.25rem 1rem 1rem;
  }

  .home-tile .tile-value {
    font-size: 2.25rem;
  }
}

/* Windows high contrast and other forced-color modes. */
@media (forced-colors: active) {
  .m--open {
    forced-color-adjust: none;
    background: CanvasText;
  }

  .m--closed {
    outline: 1px solid GrayText;
    outline-offset: -1px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }
}

/* app.js moves focus to the main area after switching pages, for screen readers; the outline
   would only flash around the whole page. */
#main:focus {
  outline: none;
}

/* A program's terms: label over value, in a grid of short blocks. */
.facts {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(18rem, 1fr));
  margin: 0;
}

.facts div {
  padding: 0.875rem 1.25rem;
  border-bottom: 1px solid var(--line);
}

.facts dt {
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 700;
}

.facts dd {
  margin: 0.125rem 0 0;
  white-space: pre-line;
}

.cal tbody th a {
  text-decoration: none;
}

.cal tbody th a:hover {
  text-decoration: underline;
}

/* ---------------------------------------------------------------- MRP profile */

/* One page per community, after Grant Services' October 2026 drafts. On screen it sits on a
   white sheet; printed, it fills one letter page and the site's chrome drops away. */
.mrp-profile {
  max-width: 60rem;
  margin: 0 auto;
  padding: 1.75rem 2rem 1.5rem;
  background: var(--panel);
}

.mp-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem 2rem;
  padding-bottom: 1rem;
  border-bottom: 3px solid var(--navy);
}

.mp-kicker {
  margin: 0 0 0.25rem;
  color: var(--muted);
  font-family: var(--heading);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.mp-head h1 {
  margin: 0;
}

.mp-tags {
  margin: 0.25rem 0 0;
  color: var(--muted);
}

.mp-score {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-align: right;
}

.mp-score-label {
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.mp-score-value {
  color: var(--navy);
  font-family: var(--heading);
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}

.mp-score-value small {
  color: var(--muted);
  font-size: 1rem;
}

.mp-score-sub {
  font-size: 0.875rem;
}

.mp-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  margin: 1rem 0 0;
}

.mp-section {
  margin-top: 1.25rem;
}

.mp-section h2 {
  margin: 0 0 0.5rem;
  color: var(--navy);
  font-size: 0.875rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.mp-sub,
.mp-small {
  margin: 0 0 0.5rem;
  color: var(--muted);
  font-size: 0.8125rem;
}

.mp-small {
  margin-top: 0.75rem;
}

.mp-bar {
  display: block;
  width: 100%;
  height: 1.75rem;
}

.mp-bar-base,
.mp-key--base {
  fill: var(--navy);
  background: var(--navy);
}

.mp-bar-control,
.mp-key--control {
  fill: var(--gold);
  background: var(--gold);
}

.mp-bar-none,
.mp-key--none {
  fill: var(--panel-2);
  background: var(--panel-2);
}

.mp-key--none {
  outline: 1px solid var(--line-strong);
  outline-offset: -1px;
}

.mp-bar-line {
  stroke: var(--stale);
  stroke-width: 2;
  stroke-dasharray: 3 2;
  vector-effect: non-scaling-stroke;
}

.mp-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
  margin: 0.5rem 0 0;
  padding: 0;
  list-style: none;
  font-size: 0.875rem;
}

.mp-key {
  display: inline-block;
  width: 0.75rem;
  height: 0.75rem;
  margin-right: 0.375rem;
  vertical-align: -0.0625rem;
}

.mp-line {
  margin: 0.375rem 0 0;
  font-size: 0.875rem;
  font-weight: 700;
}

.mp-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr));
  gap: 0 2rem;
}

.mp-grid > :only-child {
  grid-column: 1 / -1;
}

.mp-table tbody th[scope="row"] {
  background: none;
  color: var(--text);
}

.mp-table tbody th[scope="row"],
.mp-table tfoot th[scope="row"] {
  vertical-align: top;
}

.mp-table th[scope="row"] {
  font-weight: 700;
  white-space: nowrap;
}

.mp-table td,
.mp-table th {
  padding: 0.375rem 0.5rem;
  font-size: 0.875rem;
}

.mp-table .num {
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.mp-table tfoot th,
.mp-table tfoot td {
  border-top: 2px solid var(--navy);
  color: var(--navy);
  font-weight: 700;
}

.mp-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem 1rem;
  margin: 0;
}

.mp-facts div {
  display: flex;
  flex-direction: column-reverse;
}

.mp-facts dt {
  color: var(--muted);
  font-size: 0.8125rem;
}

.mp-facts dd {
  margin: 0;
  color: var(--navy);
  font-family: var(--heading);
  font-size: 1.375rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.mp-note {
  margin: 0;
  white-space: pre-line;
  font-size: 0.875rem;
}

.mp-steps {
  margin: 0;
  padding-left: 1.125rem;
  font-size: 0.875rem;
}

.mp-steps li + li {
  margin-top: 0.25rem;
}

.mp-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem 2rem;
  margin-top: 1.25rem;
  padding-top: 0.625rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.75rem;
}

.mp-foot p {
  flex: 1 1 24rem;
  margin: 0;
}

.mp-foot .mp-by {
  flex: 0 0 auto;
  font-weight: 700;
}

/* The grant profile (MRP and TxCDBG side by side) reuses the MRP profile's sheet. */
.gp-fit {
  color: var(--navy);
  font-family: var(--heading);
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.15;
}

/* Label on the left, value on the right, one row each: long values wrap in their own cell. */
.gp-list {
  margin: 0;
  font-size: 0.875rem;
}

.gp-list div {
  display: grid;
  grid-template-columns: minmax(0, 11rem) minmax(0, 1fr);
  gap: 0.75rem;
  padding: 0.3125rem 0;
  border-bottom: 1px solid var(--line);
}

.gp-list dt {
  color: var(--muted);
}

.gp-list dd {
  margin: 0;
  font-weight: 700;
}

.gp-list dd .muted {
  font-weight: 400;
}

.gp-dates {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.875rem;
}

.gp-research {
  margin: 0;
  padding-left: 1.125rem;
  font-size: 0.875rem;
}

.gp-research li {
  padding-bottom: 0.875rem;
  border-bottom: 1px solid var(--line);
}

.gp-research li + li {
  margin-top: 0.375rem;
}

@media print {
  @page {
    size: letter;
    margin: 0.4in 0.5in;
  }

  body {
    background: #fff;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .topbar,
  .skip-link,
  .dev-banner,
  .no-print {
    display: none !important;
  }

  /* Everything is sized in rem, so a smaller root scales the page to fit one sheet. */
  html {
    font-size: 12.5px;
  }

  .page {
    max-width: none;
    padding: 0;
  }

  .mrp-profile {
    max-width: none;
    padding: 0;
  }

  .mp-head {
    flex-wrap: nowrap;
  }

  .mp-title {
    flex: 1 1 auto;
    min-width: 0;
  }

  .mp-score {
    flex: 0 0 auto;
  }

  .mp-grid {
    grid-template-columns: 1fr 1fr;
  }

  .mp-section {
    break-inside: avoid;
  }
}

/* ---------------------------------------------------------------- funding programs (org page) */

/* The programs an organization can apply to, grouped by answer; each group folds. */
/* Find a program on the organization page; shown only when its script runs. */
.prog-filter {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 0.75rem 1rem;
  padding: 0.875rem 1.25rem;
  border-bottom: 1px solid var(--line);
}

.prog-count {
  margin: 0 0 0.5rem;
  font-size: 0.875rem;
}

.elig[hidden],
.prog-filter[hidden] {
  display: none;
}

.elig {
  border-top: 1px solid var(--line);
}

.elig summary {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  cursor: pointer;
  font-family: var(--heading);
  font-weight: 700;
}

.elig summary .count {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.elig--apply .elig-title {
  color: var(--steel);
}

.elig--check .elig-title {
  color: var(--gold-text);
}

.elig--no .elig-title,
.elig--not_open .elig-title {
  color: var(--muted);
}

.elig .data td:last-child {
  white-space: nowrap;
}

/* Note under the project list filters */
.list-note {
  margin: -0.5rem 0 1rem;
  font-size: 0.875rem;
}

/* ---------------------------------------------------------------- BD tracker */

.crm-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.crm-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.crm-nav li a {
  display: inline-block;
  padding: 0.5rem 0.875rem;
  background: var(--panel);
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
}

.crm-nav li a:hover {
  background: var(--panel-2);
}

.crm-nav li a[aria-current="page"] {
  background: var(--navy);
  color: #ffffff;
}

.crm-actions,
.crm-row-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: start;
  gap: 0.5rem;
}

.crm-actions {
  margin-top: 0.75rem;
}

.crm-tiles {
  margin-bottom: 1.25rem;
}

.panel-head .panel-action {
  margin-left: auto;
}

.crm-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.crm-list > li {
  display: flex;
  flex-wrap: wrap;
  align-items: start;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  padding: 0.875rem 1.25rem;
  border-bottom: 1px solid var(--line);
}

.crm-list > li:last-child {
  border-bottom: 0;
}

.crm-list > li > div:first-child {
  display: grid;
  flex: 1 1 16rem;
  gap: 0.125rem;
  min-width: 0;
  overflow-wrap: anywhere;
}

.crm-text {
  white-space: pre-line;
}

.crm-follow {
  margin-top: 0.25rem;
  padding-left: 0.625rem;
  border-left: 3px solid var(--check-edge);
}

.crm-follow--done {
  border-left-color: var(--line-strong);
  color: var(--muted);
}

.crm-note-form {
  display: grid;
  gap: 0.5rem;
  justify-items: start;
  border-bottom: 1px solid var(--line);
}

.crm-note-form textarea,
.crm-form textarea {
  width: 100%;
  padding: 0.5rem 0.625rem;
  border: 1px solid var(--line-strong);
  background: var(--panel);
  color: var(--text);
  font: inherit;
  font-size: 0.9375rem;
}

.crm-form {
  max-width: 60rem;
}

.crm-form-title {
  margin: 0;
  font-size: 1.25rem;
}

.crm-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem 1.25rem;
}

.crm-wide {
  grid-column: 1 / -1;
}

.crm-fields .filter {
  align-content: start;
}

.crm-check {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 2.75rem;
  font-weight: 700;
}

.crm-check input {
  width: 1.25rem;
  height: 1.25rem;
}

.crm-invalid input,
.crm-invalid select,
.crm-invalid textarea {
  border-color: var(--stale);
  border-width: 2px;
}

.crm-error {
  color: var(--stale);
  font-weight: 700;
}

.crm-form-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.crm-find {
  display: grid;
  gap: 0.375rem;
  margin-bottom: 0.75rem;
  font-weight: 700;
}

.crm-find input {
  min-height: 2.5rem;
  padding: 0.4375rem 0.625rem;
  border: 1px solid var(--line-strong);
  font: inherit;
}

.crm-find .button {
  justify-self: start;
}

@media (max-width: 64rem) {
  /* Contacts first on narrow screens, above the long lists of activity and pursuits. */
  .crm-sheet > aside {
    order: -1;
  }
}

@media (max-width: 40rem) {
  .crm-fields {
    grid-template-columns: minmax(0, 1fr);
  }

  .crm-list > li {
    padding: 0.75rem 1rem;
  }
}
