/*
 * public-shell-civic.css — Civic polish for the public site header & footer.
 *
 * Presentation-only. No markup, data, or runtime changes. Loaded site-wide on
 * public pages AFTER site-theme.css and public-shell.css (so it overrides the
 * default light theme).
 *
 * Precedence notes:
 * - Header/nav colors are driven by CSS custom properties. Overriding the
 *   default `:root` tokens here beats the legacy green `:root` (later in the
 *   cascade) while `html[data-theme="dark"]` / `html[data-accessibility="cb"]`
 *   keep winning (attribute selectors out-rank `:root`), so dark and
 *   color-blind themes are untouched.
 * - Footer overrides target `.site-footer--surface`; the high-contrast theme
 *   (`body.theme-high-contrast ...`) and the legacy footer builder
 *   (`.site-footer--legacy-builder`) have their own rules and stay intact.
 *
 * Visual DNA: deep civic navy foundation, warm white text, restrained gold
 * accent, low noise, dignified — no neon green, no heavy gradients.
 */

:root {
  /* Civic shell palette (aligned with home-civic.css). */
  --civic-shell-navy: #0f4c81;
  --civic-shell-navy-deep: #0b3358;
  --civic-shell-navy-ink: #0a2540;
  --civic-shell-gold: #c8a23c;
  --civic-shell-gold-soft: #e7d9a8;
  --civic-shell-paper: #f7f5f0;
  --civic-shell-line: #e7e2d6;

  /* Municipal header: brand navy (matches footer / primary SILA surfaces). */
  --tt-header-bg: var(--civic-shell-navy);
  --tt-header-nav-bg: transparent;
  --tt-header-text: #f7f5f0;
  --tt-header-text-muted: rgba(247, 245, 240, 0.72);
  --tt-nav-link: rgba(247, 245, 240, 0.92);
  --tt-nav-link-hover: #ffffff;
  --tt-nav-active-bg: transparent;
  --tt-nav-active-underline: 2px solid var(--civic-shell-gold);
}

/* ===================== HEADER (municipal two-row) ===================== */

.tt-header.tt-header--municipal {
  background: var(--civic-shell-navy);
  color: #f7f5f0;
  border-top: 0;
  border-bottom: 1px solid rgba(200, 162, 60, 0.28);
  box-shadow: none;
}

/* --- Utility bar: same brand navy (no near-duplicate hex drift) --- */
.tt-header--municipal .tt-header__utility-bar {
  background: var(--civic-shell-navy);
  color: rgba(247, 245, 240, 0.88);
  /* Unified navy header: no light separator between utility + main nav */
  border-bottom: none;
}
.tt-header--municipal .tt-header__utility-bar-inner {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  min-height: 34px;
  padding-block: 0.2rem;
}
.tt-header--municipal .tt-header__utility-left:not(:empty) {
  margin-right: auto;
}
.tt-header--municipal .tt-header__utility-left,
.tt-header--municipal .tt-header__utility-right {
  display: flex;
  align-items: center;
  gap: 0.35rem 0.65rem;
  min-width: 0;
}
.tt-header--municipal .tt-header__welcome {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: rgba(247, 245, 240, 0.72);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 28rem;
}
.tt-header--municipal .tt-header__utility-link {
  font-size: 0.72rem;
  font-weight: 500;
  line-height: 1;
  color: rgba(247, 245, 240, 0.78);
  text-decoration: none;
  padding: 0.25rem 0.4rem;
  border-radius: 3px;
  background: transparent;
  border: 0;
  cursor: pointer;
}
.tt-header--municipal .tt-header__utility-link:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}
.tt-header--municipal .tt-tools--utility {
  display: inline-flex;
  align-items: center;
  gap: 0.1rem;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  border-radius: 0;
}
.tt-header--municipal .tt-tools--utility .tt-tools__btn {
  min-height: 26px;
  min-width: 26px;
  height: 26px;
  padding: 0 0.35rem;
  font-size: 0.68rem;
  font-weight: 500;
  color: rgba(247, 245, 240, 0.7);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 3px;
}
.tt-header--municipal .tt-tools--utility .tt-tools__btn--lang {
  width: 26px;
  min-width: 26px;
  height: 26px;
  min-height: 26px;
  padding: 0;
  border-radius: 999px;
}
.tt-header--municipal .tt-tools--utility .tt-tools__label {
  font-size: 0.68rem;
  font-weight: 500;
  opacity: 0.85;
}
.tt-header--municipal .tt-tools--utility .tt-tools__btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.16);
}
.tt-header--municipal .tt-tools--utility .tt-tools__btn.is-active {
  color: #ffffff;
  background: rgba(200, 162, 60, 0.28);
  border-color: rgba(200, 162, 60, 0.45);
}
.tt-header--municipal .tt-tools--utility .tt-tools__sep {
  width: 1px;
  height: 0.85rem;
  margin: 0 0.15rem;
  background: rgba(255, 255, 255, 0.22);
}
.tt-header--municipal .tt-tools--utility .tt-tools__flag {
  width: 18px;
  height: 18px;
  border-color: rgba(255, 255, 255, 0.45);
  box-shadow: none;
}
.tt-header--municipal .tt-tools--utility .tt-tools__btn:focus-visible {
  outline: 2px solid var(--civic-shell-gold);
  outline-offset: 1px;
}

/* --- Main navy masthead (same brand navy as utility strip / footer primary) --- */
.tt-header--municipal .tt-header__main {
  background: var(--civic-shell-navy);
}
.tt-header--municipal .tt-header__main-inner {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.15rem;
  min-height: 0;
  padding-block: 0.4rem 0.3rem;
}
.tt-header--municipal .tt-header__masthead {
  display: flex;
  align-items: center;
  gap: 0.75rem 1rem;
  min-width: 0;
}
.tt-header--municipal .tt-header__brand {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: #f7f5f0;
  text-decoration: none;
  min-width: 0;
  max-width: none;
}
.tt-header--municipal .tt-header__brand:hover {
  color: #ffffff;
  opacity: 1;
}
.tt-header--municipal .tt-header__logo img {
  height: 4rem;
  width: auto;
  max-width: 4rem;
  object-fit: contain;
  display: block;
  flex: none;
}
.tt-header--municipal .tt-header__org {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.06rem;
  min-width: 0;
}
.tt-header--municipal .tt-header__org-name {
  margin: 0;
  font-size: 1.45rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #f7f5f0;
  white-space: normal;
  overflow: visible;
  text-overflow: unset;
}
.tt-header--municipal .tt-header__org-sub {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: 0.01em;
  color: var(--civic-shell-gold-soft);
  opacity: 1;
  white-space: normal;
  overflow: visible;
  text-overflow: unset;
}

/* Dedicated primary-navigation row under the masthead (same navy, not a separate slab). */
.tt-header--municipal .tt-nav--inline {
  flex: none;
  width: 100%;
  min-width: 0;
  background: transparent !important;
  border: 0;
  border-top: 1px solid rgba(247, 245, 240, 0.14);
  box-shadow: none;
  padding-top: 0.15rem;
}
.tt-header--municipal .tt-nav--inline .tt-nav__inner {
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 0.15rem 0.35rem;
  padding: 0.05rem 0 0.1rem;
  width: 100%;
}
.tt-header--municipal .tt-nav--inline .tt-nav__link {
  min-height: 2.5rem;
  padding: 0.4rem 0.75rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: rgba(247, 245, 240, 0.92);
  border-radius: 4px;
  border-bottom: 2px solid transparent;
  white-space: nowrap;
}
.tt-header--municipal .tt-nav--inline .tt-nav__link:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}
.tt-header--municipal .tt-nav--inline .tt-nav__link--active {
  color: #ffffff;
  background: transparent;
  border-bottom-color: var(--civic-shell-gold);
  box-shadow: none;
}
.tt-header--municipal .tt-nav--inline .tt-nav__link:focus-visible {
  outline: 2px solid var(--civic-shell-gold);
  outline-offset: 2px;
}
.tt-header--municipal .tt-nav__submenu {
  background: #ffffff;
  color: var(--civic-shell-navy-ink);
  border: 1px solid var(--civic-shell-line);
  border-radius: 0.65rem;
  box-shadow: 0 10px 28px rgba(10, 37, 64, 0.18);
}
.tt-header--municipal .tt-nav__submenuLink {
  color: var(--civic-shell-navy-deep);
}
.tt-header--municipal .tt-nav__submenuLink:hover,
.tt-header--municipal .tt-nav__submenuLink:focus-visible {
  background: rgba(15, 76, 129, 0.07);
  color: var(--civic-shell-navy-ink);
}

/* Search + CTA cluster */
.tt-header--municipal .tt-header__actions {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex: 0 0 auto;
  margin-left: auto;
}
.tt-header--municipal .tt-header__search {
  display: none;
  align-items: center;
  position: relative;
  width: 168px;
}
.tt-header--municipal .tt-header__search-input {
  width: 100%;
  height: 2.15rem;
  padding: 0 2.1rem 0 0.85rem;
  border: 1px solid rgba(247, 245, 240, 0.35);
  border-radius: 999px;
  background: #f7f5f0;
  color: var(--civic-shell-navy-ink);
  font-size: 0.82rem;
  line-height: 1;
  outline: none;
}
.tt-header--municipal .tt-header__search-input::placeholder {
  color: #7a8790;
}
.tt-header--municipal .tt-header__search-input:focus {
  border-color: var(--civic-shell-gold);
  box-shadow: 0 0 0 3px rgba(200, 162, 60, 0.28);
  background: #ffffff;
}
.tt-header--municipal .tt-header__search-submit {
  position: absolute;
  right: 0.2rem;
  top: 50%;
  transform: translateY(-50%);
  width: 1.75rem;
  height: 1.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--civic-shell-navy);
  cursor: pointer;
}
.tt-header--municipal .tt-header__search-submit:hover {
  color: var(--civic-shell-navy-ink);
  background: rgba(15, 76, 129, 0.08);
}
.tt-header--municipal .tt-header__search-submit svg {
  width: 0.95rem;
  height: 0.95rem;
}

/* Primary civic service CTA — strongest header action, still compact. */
.tt-header--municipal .tt-header__cta {
  align-items: center;
  gap: 0.4rem;
  margin-left: 0;
  padding: 0.48rem 0.9rem;
  border-radius: 0.55rem;
  background: var(--civic-shell-gold);
  color: #2a2000;
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.1;
  white-space: nowrap;
  text-decoration: none;
  border: 1px solid transparent;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.18);
  transition: background 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}
@media (min-width: 1024px) {
  .tt-header--municipal a.tt-header__cta:not(.tt-header__cta--drawer) {
    display: inline-flex;
  }
  .tt-header--municipal .tt-header__search {
    display: inline-flex;
  }
}
.tt-header--municipal .tt-header__cta:hover {
  background: #d8b352;
  transform: translateY(-1px);
  color: #2a2000;
}
.tt-header--municipal .tt-header__cta:focus-visible {
  outline: 2px solid var(--civic-shell-gold-soft);
  outline-offset: 2px;
}
.tt-header--municipal .tt-header__cta svg { flex: none; }
/* Drawer is a sibling of <header>, not a descendant — keep this rule unscoped. */
.tt-header__cta--drawer {
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 100%;
  min-height: 44px;
  margin: 0 0 0.75rem;
  padding: 0.75rem 1.15rem;
  border-radius: 0.55rem;
  background: var(--civic-shell-gold);
  color: #2a2000;
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.1;
  white-space: nowrap;
  text-decoration: none;
  border: 1px solid transparent;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.18);
}
.tt-header__cta--drawer:hover {
  background: #d8b352;
  color: #2a2000;
}
.tt-header__cta--drawer:focus-visible {
  outline: 2px solid var(--civic-shell-gold-soft);
  outline-offset: 2px;
}

/* Mobile menu button on navy masthead */
.tt-header--municipal .tt-header__menu-btn {
  background: rgba(247, 245, 240, 0.08);
  border: 1px solid rgba(247, 245, 240, 0.28);
  color: #f7f5f0;
}
.tt-header--municipal .tt-header__menu-btn:hover {
  background: rgba(247, 245, 240, 0.14);
  border-color: rgba(247, 245, 240, 0.4);
}
.tt-header--municipal .tt-header__menu-btn:focus-visible {
  outline-color: var(--civic-shell-gold);
}
.tt-header--municipal .tt-header__menu-btn .tt-icon-bars span {
  background: #f7f5f0;
}

.tt-nav__link--search {
  align-items: center;
  gap: 0.5rem;
}
.tt-nav__link--search svg {
  width: 0.95rem;
  height: 0.95rem;
  flex: none;
}

/* Desktop: keep readable type; composition (nav row) absorbs width, not font shrinkage. */
@media (min-width: 1024px) {
  .tt-header--municipal .tt-header__search {
    width: 168px;
  }
  .tt-header--municipal .tt-nav--inline .tt-nav__inner {
    flex-wrap: wrap;
  }
}
@media (min-width: 1280px) {
  .tt-header--municipal .tt-header__search {
    width: 188px;
  }
  .tt-header--municipal .tt-nav--inline .tt-nav__inner {
    gap: 0.2rem 0.55rem;
  }
  .tt-header--municipal .tt-nav--inline .tt-nav__link {
    padding: 0.45rem 0.85rem;
    font-size: 1rem;
  }
}

/* Mobile / tablet: compact identity row; nav lives in drawer */
@media (max-width: 1023px) {
  .tt-header--municipal .tt-header__utility-bar {
    display: none;
  }
  .tt-header--municipal .tt-header__main-inner {
    min-height: 0;
    padding-block: 0.5rem;
    gap: 0;
  }
  .tt-header--municipal .tt-header__masthead {
    width: 100%;
    gap: 0.55rem;
  }
  .tt-header--municipal .tt-header__brand {
    flex: 1 1 auto;
    max-width: none;
    gap: 0.55rem;
  }
  .tt-header--municipal .tt-header__logo img {
    height: 2.85rem;
    max-width: 2.85rem;
  }
  .tt-header--municipal .tt-header__org-name {
    font-size: 1.12rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .tt-header--municipal .tt-header__org-sub {
    font-size: 0.78rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .tt-header--municipal .tt-header__menu-btn {
    min-height: 40px;
    min-width: 40px;
    padding: 0.4rem;
  }
}
@media (max-width: 430px) {
  .tt-header--municipal .tt-header__main-inner {
    padding-block: 0.42rem;
  }
  .tt-header--municipal .tt-header__logo img {
    height: 2.55rem;
    max-width: 2.55rem;
  }
  .tt-header--municipal .tt-header__org-name {
    font-size: 1.05rem;
  }
  .tt-header--municipal .tt-header__org-sub {
    font-size: 0.74rem;
  }
}

/* A keyboard-only route around the entire masthead. */
.tt-skip-link {
  position: fixed;
  top: 0.65rem;
  left: 0.65rem;
  z-index: 80;
  padding: 0.65rem 0.9rem;
  border-radius: 0.5rem;
  background: #ffffff;
  color: var(--civic-shell-navy-ink);
  box-shadow: 0 8px 24px rgba(10, 37, 64, 0.22);
  font-weight: 700;
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform 0.16s ease;
}
.tt-skip-link:focus {
  transform: translateY(0);
  outline: 3px solid var(--civic-shell-gold);
  outline-offset: 2px;
}
@media (prefers-reduced-motion: reduce) {
  .tt-skip-link {
    transition: none;
  }
}

/* Mobile drawer: match the civic navy shell. */
.tt-drawer__panel {
  background: linear-gradient(180deg, #0f4c81 0%, #0b2f52 100%);
}

/* ===================== FOOTER ===================== */

/* Official civic closing section: deep navy foundation, gold framing rule. */
.site-footer--surface {
  position: relative;
  overflow: hidden;
  background: linear-gradient(180deg, #0f4c81 0%, #0b2f52 100%);
  color: rgba(255, 255, 255, 0.8);
  border-top: 3px solid var(--civic-shell-gold);
}
.site-footer--surface > *:not(.site-footer__sos) {
  position: relative;
  z-index: 1;
}

/* Compact civic closing: retain identity, trim vertical bulk ~25%. */
.site-footer--surface .site-footer__inner {
  padding-top: 2.5rem;
  padding-bottom: 0.35rem;
}
.site-footer--surface .site-footer__brandrow {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.7rem;
}
.site-footer--surface .site-footer__brandmark {
  flex: none;
  width: 3rem;
  height: 3rem;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(231, 217, 168, 0.34);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
  overflow: hidden;
}
.site-footer--surface .site-footer__brandmark img {
  width: 2.2rem;
  height: 2.2rem;
  object-fit: contain;
  display: block;
}
.site-footer--surface .site-footer__brandtext {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.site-footer--surface .site-footer__brand {
  display: inline-block;
  color: #ffffff;
  font-style: normal;
  font-size: 1.45rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: 0.01em;
  padding-bottom: 0.4rem;
  margin: 0;
  position: relative;
}
.site-footer--surface .site-footer__brand::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 2.5rem;
  height: 3px;
  border-radius: 2px;
  background: var(--civic-shell-gold);
}
.site-footer--surface .site-footer__subtitle {
  margin: 0;
  color: rgba(255, 255, 255, 0.74);
}
.site-footer--surface .site-footer__hours {
  color: rgba(255, 255, 255, 0.64);
}

/* Group headings in restrained gold to separate civic sections. */
.site-footer--surface .site-footer__heading {
  color: var(--civic-shell-gold-soft);
}

/* Links (main links / citizen services / public information) */
.site-footer--surface .site-footer__link {
  color: rgba(255, 255, 255, 0.74);
}
.site-footer--surface .site-footer__link:hover {
  color: #ffffff;
}
.site-footer--surface .site-footer__link--strong {
  color: #ffffff;
}

/* Contact block */
.site-footer--surface .site-footer__contactlabel,
.site-footer--surface .site-footer__contacticon {
  color: var(--civic-shell-gold-soft);
}
.site-footer--surface .site-footer__address {
  color: rgba(255, 255, 255, 0.74);
}

/* Icon links */
.site-footer--surface .site-footer__iconlink {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.24);
}
.site-footer--surface .site-footer__iconlink:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(200, 162, 60, 0.6);
}

/* Closing bar + legal */
.site-footer--surface .site-footer__bar {
  border-top-color: rgba(255, 255, 255, 0.2);
}
.site-footer--surface .site-footer__copy {
  color: rgba(255, 255, 255, 0.84);
  font-size: 0.86rem;
  font-weight: 500;
}
.site-footer--surface .site-footer__platform-credit {
  font-size: 0.76rem;
  font-weight: 450;
  color: rgba(255, 255, 255, 0.62);
  white-space: nowrap;
}
.site-footer--surface .site-footer__legal-link {
  color: rgba(255, 255, 255, 0.86);
  font-weight: 500;
}
.site-footer--surface .site-footer__legal-link:hover {
  color: #ffffff;
}

/* Footer accessibility strip */
.site-footer--surface .site-footer__a11y {
  border-top-color: rgba(255, 255, 255, 0.18);
}
.site-footer--surface .site-footer__a11y-inner,
.site-footer--surface .site-footer__a11y-label {
  color: rgba(255, 255, 255, 0.82);
}
.site-footer--surface .site-footer__a11y-link {
  color: rgba(255, 255, 255, 0.88);
}
.site-footer--surface .site-footer__a11y-link:hover,
.site-footer--surface .site-footer__a11y-link.is-active {
  color: #ffffff;
}

/* Controlled emergency action: keep behavior, remove broken floating-dot feel. */
.site-footer--surface .site-footer__sos {
  position: fixed;
  left: auto;
  right: max(1rem, env(safe-area-inset-right));
  bottom: max(1rem, env(safe-area-inset-bottom));
  z-index: 70;
  min-width: 0;
  min-height: 0;
  height: 2.75rem;
  max-width: calc(100vw - 2rem);
  padding: 0 1rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: #b42318;
  box-shadow: 0 10px 24px rgba(10, 37, 64, 0.22);
  color: #ffffff;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  line-height: 1;
  white-space: nowrap;
  transform: none;
}
.site-footer--surface .site-footer__sos::before {
  content: "";
  width: 0.48rem;
  height: 0.48rem;
  margin-right: 0.45rem;
  border-radius: 999px;
  background: #ffffff;
  opacity: 0.9;
}
.site-footer--surface .site-footer__sos:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(10, 37, 64, 0.26);
  background: #a61e14;
}
@media (max-width: 640px) {
  .site-footer--surface .site-footer__sos {
    right: 0.75rem;
    bottom: 0.75rem;
    height: 2.35rem;
    padding-inline: 0.8rem;
    font-size: 0.72rem;
  }
}

/* The public homepage already exposes official contact channels in the hero trust strip and footer. */
.site-footer--surface .site-footer__sos {
  display: none;
}

/* ===================== PUBLIC INNER SURFACES ===================== */

body.public-inner-surface {
  background: var(--civic-shell-paper);
  color: #1f2a37;
}

.public-inner-surface main[role="main"] {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92) 0, var(--civic-shell-paper) 18rem),
    var(--civic-shell-paper);
}

.public-inner-surface .public-inner-shell {
  gap: clamp(1rem, 3vw, 1.75rem);
}

.public-inner-surface aside[aria-label] {
  border-right-color: rgba(231, 226, 214, 0.9);
  background: transparent;
}

.public-inner-surface aside nav {
  padding-top: 2rem;
}

.public-inner-surface .sidebar-link {
  border-radius: 10px;
  color: #334155;
}

.public-inner-surface .sidebar-link:hover {
  background: rgba(15, 76, 129, 0.08);
  color: var(--civic-shell-navy-deep);
}

.public-inner-surface .sidebar-link.active {
  background: rgba(15, 76, 129, 0.1);
  color: var(--civic-shell-navy-deep);
  border-left-color: var(--civic-shell-gold);
}

.public-inner-surface .public-inner-card {
  border-color: var(--civic-shell-line, #e7e2d6);
  border-radius: 16px;
  box-shadow: 0 1px 2px rgba(10, 37, 64, 0.06), 0 12px 28px rgba(10, 37, 64, 0.06);
}

.public-inner-surface .prose-custom {
  color: #334155;
}

.public-inner-surface .prose-custom h1,
.public-inner-surface .prose-custom h2,
.public-inner-surface .prose-custom h3,
.public-inner-surface .site-listing-title,
.public-inner-surface .site-detail-title {
  color: var(--civic-shell-navy-ink);
  letter-spacing: -0.01em;
}

.public-inner-surface .site-listing-head,
.public-inner-surface .site-detail-head {
  margin-bottom: clamp(1.25rem, 3vw, 1.75rem);
}

.public-inner-surface .site-heading-rule {
  width: 2.75rem;
  height: 2px;
  background-color: var(--civic-shell-gold) !important;
  border-radius: 999px;
}

.public-inner-surface nav[aria-label="Breadcrumb"] {
  color: #64748b;
}

.public-inner-surface nav[aria-label="Breadcrumb"] a {
  color: var(--civic-shell-navy);
  text-decoration: none;
}

.public-inner-surface nav[aria-label="Breadcrumb"] a:hover {
  color: var(--civic-shell-navy-deep);
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.public-inner-surface .text-primary-600,
.public-inner-surface .text-primary-700,
.public-inner-surface .hover\:text-primary-600:hover,
.public-inner-surface .hover\:text-primary-700:hover {
  color: var(--civic-shell-navy) !important;
}

.public-inner-surface .bg-primary-50 {
  background-color: rgba(15, 76, 129, 0.08) !important;
}

.public-inner-surface .bg-primary-600,
.public-inner-surface .bg-primary-700 {
  background-color: var(--civic-shell-navy) !important;
}

.public-inner-surface a.bg-primary-600,
.public-inner-surface button.bg-primary-600 {
  background-color: var(--civic-shell-gold) !important;
  color: #2a2000 !important;
}

.public-inner-surface a.bg-primary-600:hover,
.public-inner-surface button.bg-primary-600:hover {
  background-color: #d8b352 !important;
}

.public-inner-surface .site-heading-rule.bg-primary-600 {
  background-color: var(--civic-shell-gold) !important;
}

.public-inner-surface .border-primary-200,
.public-inner-surface .hover\:border-primary-200:hover,
.public-inner-surface .hover\:border-primary-500:hover {
  border-color: rgba(200, 162, 60, 0.52) !important;
}

.public-inner-surface article a.block.rounded-xl,
.public-inner-surface .doc-card,
.public-inner-surface .rounded-xl.border.border-slate-200.bg-white,
.public-inner-surface .rounded-xl.border.border-slate-200.bg-slate-50\/50 {
  border-color: var(--civic-shell-line, #e7e2d6) !important;
  border-radius: 14px;
  background-color: #ffffff;
  box-shadow: 0 1px 2px rgba(10, 37, 64, 0.05);
}

.public-inner-surface article a.block.rounded-xl:hover,
.public-inner-surface .doc-card:hover,
.public-inner-surface .rounded-xl.border.border-slate-200.bg-white:hover,
.public-inner-surface .rounded-xl.border.border-slate-200.bg-slate-50\/50:hover {
  border-color: rgba(200, 162, 60, 0.65) !important;
  box-shadow: 0 10px 24px rgba(10, 37, 64, 0.08);
}

.public-inner-surface .site-empty-state,
.public-inner-surface .nh-procurement-empty {
  border: 1px dashed var(--civic-shell-line, #e7e2d6);
  border-radius: 14px;
  background: #fbfaf7;
  color: #64748b;
  padding: 1rem 1.1rem;
  line-height: 1.65;
}

.public-inner-surface input,
.public-inner-surface textarea,
.public-inner-surface select {
  border-color: #cbd5e1;
}

.public-inner-surface input:focus,
.public-inner-surface textarea:focus,
.public-inner-surface select:focus {
  border-color: var(--civic-shell-gold) !important;
  box-shadow: 0 0 0 3px rgba(200, 162, 60, 0.24) !important;
  outline: none;
}

.site-footer__platform-credit--legacy {
  margin: 0.65rem 0 0;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.8);
}

/* Rebalance footer when the contact column is omitted (no empty hole). */
@media (min-width: 1024px) {
  .site-footer--surface .site-footer__grid:not(:has(.site-footer__col--contact)) {
    grid-template-columns: minmax(0, 1.2fr) repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 639.98px) {
  .site-footer--surface .site-footer__inner {
    padding-top: 1.2rem;
    padding-bottom: 0.8rem;
  }
  .site-footer--surface .site-footer__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.9rem 1rem;
  }
  .site-footer--surface .site-footer__col:first-child {
    grid-column: 1 / -1;
  }
}

@media (max-width: 1023px) {
  .public-inner-surface .public-inner-shell {
    display: block;
  }
}

@media (max-width: 640px) {
  .public-inner-surface .public-inner-card > div {
    padding: 1.25rem;
  }
}

/* Sidebar subtle scrolling and active accent styling */
.public-inner-surface aside nav::-webkit-scrollbar {
  width: 4px;
}
.public-inner-surface aside nav::-webkit-scrollbar-track {
  background: transparent;
}
.public-inner-surface aside nav::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.3);
  border-radius: 4px;
}
.public-inner-surface aside nav::-webkit-scrollbar-thumb:hover {
  background: rgba(148, 163, 184, 0.5);
}

.public-inner-surface .sidebar-link.active {
  background: rgba(15, 76, 129, 0.05) !important;
  color: var(--civic-shell-navy-deep) !important;
  border-left: 3px solid var(--civic-shell-gold) !important;
  border-top-left-radius: 0 !important;
  border-bottom-left-radius: 0 !important;
  font-weight: 600 !important;
}

/* Hide summary marker for sitemap accordions and all nested details */
details summary::-webkit-details-marker,
details.group summary::-webkit-details-marker {
  display: none !important;
}
details summary,
details.group summary {
  list-style: none !important;
}


/* Municipal dark / CB: keep utility bar institutional; masthead follows theme tokens. */
html[data-theme="dark"] .tt-header--municipal {
  background: #0f172a;
  color: #f1f5f9;
  border-bottom-color: #334155;
}
html[data-theme="dark"] .tt-header--municipal .tt-header__utility-bar {
  background: #020617;
}
html[data-theme="dark"] .tt-header--municipal .tt-header__main {
  background: #0f172a;
}
html[data-theme="dark"] .tt-header--municipal .tt-header__org-name,
html[data-theme="dark"] .tt-header--municipal .tt-header__brand {
  color: #f8fafc;
}
html[data-theme="dark"] .tt-header--municipal .tt-header__org-sub {
  color: #94a3b8;
}
html[data-theme="dark"] .tt-header--municipal .tt-nav--inline .tt-nav__link {
  color: #cbd5e1;
}
html[data-theme="dark"] .tt-header--municipal .tt-header__search-input {
  background: #1e293b;
  border-color: #334155;
  color: #f1f5f9;
}
html[data-accessibility="cb"] .tt-header--municipal {
  border-bottom: 2px solid #0a2540;
}

/*
 * Opt-in Civic homepage extension sections (site-search, banner-strip, video,
 * ebooks, official-letters). Reuses the .sila-civic-home palette tokens from
 * home-civic.css; no autoplay or auto-rotation anywhere.
 */
.sila-civic-home .civic-ext-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem 1rem;
}
.sila-civic-home .civic-ext-head__all {
  color: var(--civic-navy);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.sila-civic-home .civic-ext-search {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}
.sila-civic-home .civic-ext-search__label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.sila-civic-home .civic-ext-search__input {
  flex: 1 1 16rem;
  min-width: 0;
  padding: 0.75rem 1rem;
  border: 1px solid var(--civic-line);
  border-radius: var(--civic-radius-sm);
  background: var(--civic-surface);
  color: var(--civic-ink);
  font: inherit;
}
.sila-civic-home .civic-ext-search__input:focus-visible,
.sila-civic-home .civic-ext-banner__strip:focus-visible {
  outline: 2px solid var(--civic-navy);
  outline-offset: 2px;
}
.sila-civic-home .civic-ext-banner__single,
.sila-civic-home .civic-ext-banner__item {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: var(--civic-radius-sm);
}
.sila-civic-home .civic-ext-banner__single {
  width: 100%;
  height: clamp(160px, 22vw, 280px);
  object-fit: cover;
}
.sila-civic-home .civic-ext-banner__strip {
  display: flex;
  gap: var(--civic-gap);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  overscroll-behavior-x: contain;
  padding-bottom: 0.5rem;
}
.sila-civic-home .civic-ext-banner__item {
  flex: 0 0 auto;
  height: clamp(160px, 22vw, 280px);
  aspect-ratio: 16 / 9;
  max-width: 100%;
  scroll-snap-align: start;
  object-fit: cover;
}
.sila-civic-home .civic-ext-video__frame {
  position: relative;
  aspect-ratio: 16 / 9;
  max-width: 56rem;
  overflow: hidden;
  border-radius: var(--civic-radius-sm);
  background: var(--civic-navy-ink);
}
.sila-civic-home .civic-ext-video__frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.sila-civic-home .civic-ext-books {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr));
  gap: var(--civic-gap);
  margin: 0;
  padding: 0;
  list-style: none;
}
.sila-civic-home .civic-ext-books__link {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  color: var(--civic-ink);
  text-decoration: none;
}
.sila-civic-home .civic-ext-books__cover {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border: 1px solid var(--civic-line);
  border-radius: var(--civic-radius-sm);
  background: var(--civic-surface-soft);
}
.sila-civic-home .civic-ext-books__cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.sila-civic-home .civic-ext-books__fallback {
  color: var(--civic-muted);
  font-weight: 700;
}
.sila-civic-home .civic-ext-books__title {
  font-weight: 600;
  line-height: 1.4;
}
.sila-civic-home .civic-ext-books__link:hover .civic-ext-books__title {
  color: var(--civic-navy);
  text-decoration: underline;
}
.sila-civic-home .civic-ext-books__date,
.sila-civic-home .civic-ext-letters__meta {
  color: var(--civic-muted);
  font-size: var(--civic-type-meta);
}
.sila-civic-home .civic-ext-letters {
  margin: 0;
  padding: 0;
  list-style: none;
}
.sila-civic-home .civic-ext-letters__item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--civic-line);
}
.sila-civic-home .civic-ext-letters__title {
  color: var(--civic-ink);
  font-weight: 600;
  line-height: 1.45;
}
.sila-civic-home a.civic-ext-letters__title {
  color: var(--civic-navy);
}
.sila-civic-home .civic-ext-letters__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1rem;
}

/* ==== weather-air-quality (civic extension) ==== */
.sila-civic-home .civic-ext--weather-air-quality .civic-ext-weather {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
  gap: var(--civic-gap);
}
.sila-civic-home .civic-ext--weather-air-quality .civic-ext-weather__place {
  font-size: 0.7em;
  font-weight: 500;
  color: var(--civic-muted, var(--civic-ink));
}
.sila-civic-home .civic-ext--weather-air-quality .civic-ext-weather__card {
  padding: 1rem 1.125rem;
  background: #fff;
  border: 1px solid var(--civic-line);
  border-radius: var(--civic-radius, 0.75rem);
}
.sila-civic-home .civic-ext--weather-air-quality .civic-ext-weather__label,
.sila-civic-home .civic-ext--weather-air-quality .civic-ext-weather__note,
.sila-civic-home .civic-ext--weather-air-quality .civic-ext-weather__value {
  margin: 0;
}
.sila-civic-home .civic-ext--weather-air-quality .civic-ext-weather__label {
  font-weight: 600;
  color: var(--civic-ink);
}
.sila-civic-home .civic-ext--weather-air-quality .civic-ext-weather__value {
  margin-top: 0.25rem;
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.2;
  color: var(--civic-navy);
}
.sila-civic-home .civic-ext--weather-air-quality .civic-ext-weather__unit {
  font-size: 0.9rem;
  font-weight: 500;
}
.sila-civic-home .civic-ext--weather-air-quality .civic-ext-weather__note {
  margin-top: 0.25rem;
  color: var(--civic-ink);
}
.sila-civic-home .civic-ext--weather-air-quality .civic-ext-weather__category {
  font-weight: 600;
}
.sila-civic-home .civic-ext--weather-air-quality .civic-ext-weather__card--pm {
  border-inline-start: 6px solid var(--civic-line);
}
.sila-civic-home .civic-ext--weather-air-quality [data-pm25-level="1"] { border-inline-start-color: #1b7f4b; }
.sila-civic-home .civic-ext--weather-air-quality [data-pm25-level="2"] { border-inline-start-color: #5a9a1e; }
.sila-civic-home .civic-ext--weather-air-quality [data-pm25-level="3"] { border-inline-start-color: #b7791f; }
.sila-civic-home .civic-ext--weather-air-quality [data-pm25-level="4"] { border-inline-start-color: #c2570c; }
.sila-civic-home .civic-ext--weather-air-quality [data-pm25-level="5"] { border-inline-start-color: #b42318; }
.sila-civic-home .civic-ext--weather-air-quality .civic-ext-weather__meta {
  margin: 0.75rem 0 0;
  font-size: 0.875rem;
  color: var(--civic-ink);
}
@media (prefers-reduced-motion: reduce) {
  .sila-civic-home .civic-ext--weather-air-quality * {
    animation: none !important;
    transition: none !important;
  }
}
/* ==== /weather-air-quality ==== */
