/* CommunitasIQ marketing layout — edit site-config.css for fonts, colors, images */

:root {
  --color-surface: #ffffff;
  --shadow-sm: 0 2px 8px rgba(0, 35, 64, 0.05);
  --shadow-md: 0 12px 32px rgba(0, 35, 64, 0.08);
  --shadow-lg: 0 24px 48px rgba(0, 35, 64, 0.1);
  --radius: 8px;
  /* Topbar + copyright footer bar height */
  --header-height: 4.8rem;
  --footer-bar-height: 4.8rem;
  /* Vertical space between major sections (matches green bar → quote) */
  --section-space: 4.25rem;
  /*
   * Content → full-width color band (navy free app & green CTA).
   * White/page gap before the band = --pre-band-gap + --pre-band-margin
   * (blue free-app spacing is the reference; green matches it).
   */
  --pre-band-gap: 1.5rem;
  --pre-band-margin: 1.75rem;
  --band-inner-y: 1.75rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4,
.brand span,
.btn {
  font-family: var(--font-heading);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-secondary-blue);
  text-decoration: none;
}

.container {
  width: min(100% - 2.5rem, var(--max-width));
  margin-inline: auto;
}

.container--wide {
  width: min(100% - 1.5rem, calc(var(--max-width) + 80px));
  margin-inline: auto;
}

/* ── Header (Kubio-style transparent → solid on scroll optional; keep clean white) ── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid var(--color-border);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 72px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--color-primary);
  font-weight: 700;
  font-size: 1.12rem;
}

.brand:hover {
  text-decoration: none;
}

.brand__logo {
  width: 44px;
  height: 44px;
  object-fit: contain;
}

/* Solid navy top bar (sticky; frosts on scroll) */
.site-topbar {
  position: sticky;
  top: 0;
  height: var(--header-height);
  min-height: var(--header-height);
  max-height: var(--header-height);
  background-color: #002340;
  box-shadow: none;
  border-bottom: none;
  overflow: visible;
  z-index: 50;
  display: flex;
  align-items: center;
  transition:
    background-color 0.35s ease,
    box-shadow 0.35s ease,
    backdrop-filter 0.35s ease,
    -webkit-backdrop-filter 0.35s ease;
}

/* After user starts scrolling: navy frosted glass (not fully clear — avoids white/grey wash) */
.site-topbar.is-scrolled {
  background-color: rgba(0, 35, 64, 0.55);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.site-topbar__inner {
  width: min(100% - 2.5rem, var(--max-width));
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}

.site-topbar__logo-link {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  padding: 0.45rem 0;
}

.site-topbar__logo {
  display: block;
  width: auto;
  height: auto;
  max-height: calc(var(--header-height) - 1.4rem);
  max-width: 2.75rem;
  object-fit: contain;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}

.site-nav a:not(.btn) {
  color: var(--color-text);
  font-size: 0.95rem;
  font-weight: 500;
}

.site-nav a:not(.btn):hover {
  color: var(--color-primary);
  text-decoration: none;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.8rem 1.5rem;
  border-radius: 4px;
  border: 2px solid transparent;
  font-weight: 600;
  font-size: 0.92rem;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.btn:hover {
  text-decoration: none;
}

.btn-primary {
  background: var(--color-primary-green);
  color: #fff;
}

.btn-primary:hover {
  background: #256628;
  color: #fff;
}

.btn-outline {
  background: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}

.btn-outline:hover {
  background: var(--color-primary);
  color: #fff;
}

.btn-light {
  background: #fff;
  color: var(--color-primary);
  padding: 0.45rem 1.35rem;
  min-height: 0;
  line-height: 1.25;
}

.btn-light:hover {
  background: var(--color-border);
  color: var(--color-primary);
}

/* ── Media placeholders (swap via site-config.css) ── */
.media-box {
  display: block;
  position: relative;
  overflow: hidden;
  border-radius: var(--section-radius);
  background-color: #e6e6e6;
  background-image: none;
  background-size: cover;
  background-position: center;
}

.media-box--hero {
  min-height: 520px;
  background-color: #e6e6e6;
  background-image: var(--image-hero);
}

.media-box--about {
  aspect-ratio: 4 / 3;
  background-color: #e6e6e6;
  background-image: var(--image-about);
}

.media-box--approach {
  position: relative;
  aspect-ratio: 4 / 3;
  max-width: 248px; /* further −10% from 276px */
  width: 100%;
  margin-inline: auto;
  background-color: #e6e6e6;
  background-image: var(--image-approach);
  background-size: cover;
  background-position: center;
  border-radius: 8px;
  overflow: hidden;
}

/* Clients shouldn’t feel like another account */
.media-box--approach-partnership {
  background-image: url("../images/icon-partnership.png");
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  background-color: transparent;
}

/* Recommendations should tell you what's next */
.media-box--approach-action {
  background-image: url("../images/icon-action.png");
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  background-color: transparent;
}

/* Every project ultimately serves residents */
.media-box--approach-neighborhood {
  background-image: url("../images/icon-neighborhood.png");
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  background-color: transparent;
}

/* No border on problem-solution / engage picture placeholders */
.media-box--approach::after {
  display: none;
}

/* Dashboard crop: zoom/cover to fill approach placeholder ratio */
img.media-box--dashboard {
  width: 100%;
  height: auto;
  max-width: none;
  margin-inline: 0;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: center top;
  background-image: none;
  border: 0;
  border-radius: 8px;
}

/* Clickable media → lightbox */
.media-zoom-trigger {
  display: block;
  position: relative;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
  max-width: 248px; /* further −10% from 276px */
  width: 100%;
  margin-inline: auto;
  text-align: left;
  box-sizing: border-box;
  border-radius: 8px;
  overflow: hidden;
}

/* Frame drawn on top of the placeholder (not outside/clipped) */
.media-zoom-trigger::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  border-radius: 8px;
  box-shadow: inset 0 0 0 1px #e6e6e6;
}

.media-zoom-trigger .media-box {
  margin-inline: 0;
  max-width: none;
  width: 100%;
  transition: transform 0.2s ease;
}

.media-zoom-trigger:hover .media-box,
.media-zoom-trigger:focus-visible .media-box {
  transform: scale(1.01);
}

.media-zoom-trigger:focus-visible {
  outline: 2px solid var(--color-primary-green);
  outline-offset: 3px;
}

/* Full-image lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  margin: 0;
  border: 0;
}

.lightbox.is-open {
  display: flex;
}

.lightbox__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 20, 40, 0.88);
  cursor: zoom-out;
}

.lightbox__dialog {
  position: relative;
  z-index: 1;
  max-width: min(96vw, 1100px);
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.lightbox__img {
  display: block;
  max-width: 100%;
  max-height: calc(92vh - 3rem);
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.35);
  background: #fff;
}

.lightbox__close {
  position: absolute;
  top: -0.25rem;
  right: -0.25rem;
  z-index: 2;
  width: 2.5rem;
  height: 2.5rem;
  border: 0;
  border-radius: 50%;
  background: #fff;
  color: #002340;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.lightbox__close:hover {
  background: var(--color-primary-green);
  color: #fff;
}

.media-box--partnership {
  aspect-ratio: 4 / 3;
  background-color: #e6e6e6;
  background-image: var(--image-partnership);
}

.media-box--feature {
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: none;
  background-color: #e6e6e6;
  background-size: cover;
  background-position: center;
}

/* Practical tools cards: placeholders span the full card width */
.feature-card > .media-box--feature {
  width: 100%;
  max-width: none;
}

.media-box--feature-1,
.media-box--feature-2,
.media-box--feature-3,
.media-box--feature-4,
.media-box--feature-5,
.media-box--feature-6 {
  background-color: #e6e6e6;
}

.media-box--feature-1 { background-image: var(--image-feature-1); }
.media-box--feature-2 { background-image: var(--image-feature-2); }
.media-box--feature-3 { background-image: var(--image-feature-3); }
.media-box--feature-4 { background-image: var(--image-feature-4); }
.media-box--feature-5 { background-image: var(--image-feature-5); }
.media-box--feature-6 { background-image: var(--image-feature-6); }

/* ── Hero slider (carousel) ── */
.ciq-hero {
  position: relative;
  width: 100%;
  /*
   * Prefer 16:9 from viewport width; cap so topbar + hero fit one screen
   * (no scroll needed to see the full slide frame).
   */
  height: min(calc(100vw * 9 / 16), var(--hero-max-height));
  max-height: var(--hero-max-height);
  min-height: 0;
  aspect-ratio: auto;
  overflow: hidden;
  color: #fff;
  background: #002340;
  /* Logo + headline scale with hero width (cqi) */
  container-type: inline-size;
  container-name: ciq-hero;
}

.ciq-hero__slides {
  position: absolute;
  inset: 0;
  background: #002340;
}

.ciq-hero__slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1s ease;
}

.ciq-hero__slide.is-active {
  opacity: 1;
  z-index: 1;
}

.ciq-hero__slide--video {
  background: #002340;
}

.ciq-hero__slide-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  pointer-events: none;
}

.ciq-hero__slide--fallback {
  opacity: 1;
  background: linear-gradient(135deg, #003a5c 0%, #002340 55%, #1a4a35 100%);
}

.ciq-hero__overlay {
  position: absolute;
  inset: 0;
  background: #002340;
  opacity: 0.55;
  z-index: 2;
  pointer-events: none;
}

.ciq-hero__brand {
  position: absolute;
  top: 19.5%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 4;
  text-align: center;
  width: 34.68cqi;
  max-width: 34.68%;
  opacity: 1;
}

/* Hold slogan overlay invisible until delayed first-load reveal */
.ciq-hero__brand.is-brand-pending {
  opacity: 0 !important;
  visibility: hidden;
  transition: none !important;
  animation: none !important;
}

.ciq-hero__brand.is-fading-in {
  visibility: visible;
  animation: ciq-hero-headline-in 0.85s ease both;
}

.ciq-hero__logo {
  display: block;
  margin: 0 auto;
  width: 100%;
  height: auto;
  max-height: 10.12cqi;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 35, 0.35));
}

.ciq-hero__content {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
  height: 100%;
  /* Wider headline block; slightly below center */
  padding: 10% 2% 8%;
  box-sizing: border-box;
}

.ciq-hero__inner {
  width: min(98%, 98cqi);
  margin-inline: auto;
  text-align: center;
  transform: translateY(2%);
}

.ciq-hero__dots {
  position: absolute;
  z-index: 4;
  left: 50%;
  bottom: 1.75rem;
  transform: translateX(-50%);
  display: flex;
  gap: 0.5rem;
}

.ciq-hero__dot {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 50%;
  padding: 0;
  background: rgba(255, 255, 255, 0.45);
  cursor: pointer;
}

.ciq-hero__dot.is-active {
  background: #fff;
}

.ciq-hero__arrows {
  position: absolute;
  z-index: 4;
  inset: 0;
  pointer-events: none;
}

.ciq-hero__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: auto;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 50%;
  background: rgba(0, 35, 64, 0.35);
  color: #fff;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
}

.ciq-hero__arrow--prev {
  left: 1rem;
}

.ciq-hero__arrow--next {
  right: 1rem;
}

.ciq-hero h1 {
  margin: 0;
  font-family: "Source Sans Pro", var(--font-body);
  /*
   * Still scales with hero width on large screens; higher rem floor so
   * portrait mobile matches landscape readability (picture frame unchanged).
   */
  font-size: clamp(2.5rem, 5.98cqi, 5.175rem);
  line-height: 1.15;
  font-weight: 400;
  color: #fff;
  letter-spacing: 0.01em;
  opacity: 1;
  transition: opacity 0.5s ease;
}

/* Hold first headline invisible until delayed reveal (beats FOUC / race) */
.ciq-hero__inner.is-headline-pending h1 {
  opacity: 0 !important;
  visibility: hidden;
  transition: none !important;
  animation: none !important;
}

/* Sync with slide crossfade: out with old image, in with new */
.ciq-hero h1.is-fading-out {
  opacity: 0;
}

.ciq-hero h1.is-fading-in {
  visibility: visible;
  animation: ciq-hero-headline-in 0.85s ease both;
}

@keyframes ciq-hero-headline-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.ciq-hero .hero__headline-primary {
  display: block;
  white-space: normal;
}

.ciq-hero .hero__headline-secondary {
  display: block;
}

/* Desktop: one line per headline row when there’s room */
@container ciq-hero (min-width: 720px) {
  .ciq-hero .hero__headline-primary,
  .ciq-hero .hero__headline-secondary {
    white-space: nowrap;
  }
}

/* Fallback if container queries unsupported */
@supports not (font-size: 1cqi) {
  .ciq-hero__brand {
    width: min(34.68vw, 34.68%);
  }

  .ciq-hero__logo {
    max-height: 8.67vw;
  }

  .ciq-hero h1 {
    font-size: clamp(2.5rem, 5.98vw, 5.175rem);
  }

  @media (max-width: 768px) {
    .ciq-hero h1 {
      font-size: clamp(1.25rem, 7.2vw, 2.65rem);
    }
  }
}

.section__eyebrow {
  margin: 0 0 0.65rem;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-secondary-teal);
}

/* ── Sections ── */
.section {
  padding-top: var(--section-space);
  padding-bottom: var(--section-space);
}

/*
 * Consecutive major sections would stack top+bottom padding (2× gap).
 * Keep a single --section-space between them (same as stats-band → quote).
 * Applies to current and future .section siblings under main.
 */
main > .section + .section {
  padding-top: 0;
}

.section--grey {
  background: #f0f0f0;
}

.section--primary {
  background: var(--color-primary);
  color: #fff;
}

.section__eyebrow {
  margin: 0 0 0.65rem;
  font-family: var(--font-heading);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-secondary-teal);
}

.section--primary .section__eyebrow {
  color: rgba(255, 255, 255, 0.75);
}

/* Same type as lead quote under the green band */
.section__title {
  margin: 0 0 1rem;
  font-family: var(--font-heading);
  font-size: clamp(1.575rem, 2.88vw, 2.25rem);
  font-weight: 550;
  line-height: 1.15;
  color: var(--color-primary);
  letter-spacing: -0.02em;
}

.section--primary .section__title {
  color: #fff;
}

.section__intro {
  margin: 0;
  font-size: 1.08rem;
  color: var(--color-muted);
  max-width: 36rem;
}

.section__header--center {
  text-align: center;
  max-width: min(100%, 76rem);
  margin: 0 auto 2.5rem;
  padding-inline: 0;
}

.section--lead-quote {
  padding-top: 1.75rem;
  padding-bottom: 1.75rem;
  background: #fff;
}

.section--lead-quote .section__header--center {
  margin-bottom: 0;
}

.section--lead-quote .section__title {
  /* Same size as other section headlines (e.g. approach titles) */
  font-size: clamp(1.575rem, 2.88vw, 2.25rem);
  font-weight: 550;
  color: var(--color-primary);
  text-align: center;
}

/* Mobile-only slogan strip under hero (hidden on desktop) */
.hero-mobile-brand {
  display: none;
}

.lead-intro {
  width: 100%;
}

.section__header--center .section__title {
  margin: 0 auto;
  max-width: min(100%, 62rem);
}

.section--primary .section__intro {
  color: rgba(255, 255, 255, 0.88);
}

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.split--reverse .split__media {
  order: 2;
}

.split--reverse .split__content {
  order: 1;
}

/* Picture left, text right for all approach articles */
.approach-block .split {
  align-items: start;
  grid-template-columns: minmax(0, 242px) minmax(0, 1fr); /* further −10% from 269px */
  gap: 2.5rem;
}

.approach-block .split__media {
  max-width: 242px; /* further −10% from 269px */
  order: 1;
}

.approach-block .split__content {
  order: 2;
}

.section.approach-block {
  padding-bottom: 1.5rem;
}

main > .section.approach-block + .section.approach-block {
  padding-top: 1.75rem;
}

/* Last problem article → navy free-app (reference spacing) */
main > .section.approach-block:has(+ .app-highlight),
main > .section.approach-block:has(+ #neighborhood-database) {
  padding-bottom: var(--pre-band-gap);
}

main > .section.approach-block + .app-highlight,
main > .section.approach-block + #neighborhood-database {
  /* Extra white gap outside the navy (not inside the band) */
  margin-top: var(--pre-band-margin);
}

/* Fixed sizes so portrait matches landscape readability (same idea as info cards) */
.approach-block .section__title {
  font-size: 2.25rem;
}

.approach-block .section__intro {
  font-family: "Source Sans Pro", var(--font-body);
  font-size: 1.25rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.4;
  max-width: none;
}

#services > .container > .section__intro,
#who-we-serve > .container > .section__intro {
  font-family: "Source Sans Pro", var(--font-body);
  font-size: 1.15rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.4;
  max-width: none;
}

/* ── Stats band (three-column row) ── */
.stats-band {
  background: var(--color-primary-green);
  color: #fff;
  padding: 2.5rem 0;
}

.stats-band__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: 3.5rem;
  row-gap: 1.5rem;
}

.stats-band .stat-item strong {
  display: block;
  font-family: "Source Sans Pro", var(--font-body);
  font-size: 1.5rem;
  font-weight: 400;
  letter-spacing: 0.01em;
  line-height: 1.15;
  margin-bottom: 0.55rem;
  text-align: left;
}

.stats-band .stat-item span {
  display: block;
  font-family: "Source Sans Pro", var(--font-body);
  font-size: 1.25rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.4;
  text-align: left;
}

.stats-band .stat-item a,
.stats-band .stat-item a:link,
.stats-band .stat-item a:visited,
.stats-band .stat-item a:hover,
.stats-band .stat-item a:active,
.stats-band .stat-item a:focus,
.stats-band .stat-item a:focus-visible {
  color: rgba(255, 255, 255, 0.78) !important;
  text-decoration: none !important;
  outline: none;
  cursor: inherit;
}

/* Neighborhood Database app highlight (navy band) */
.blue-band,
.app-highlight {
  background: #002340;
  color: #fff;
  /* Match green CTA band: same inner vertical padding (not full --section-space) */
  padding: var(--band-inner-y, 1.75rem) 0;
}

/* Match .section__title size/style; keep white for navy band */
#neighborhood-database h2.app-highlight__title,
.app-highlight h2.app-highlight__title {
  margin: 0 0 1rem;
  font-family: var(--font-heading);
  font-size: clamp(1.575rem, 2.88vw, 2.25rem);
  font-weight: 550;
  line-height: 1.15;
  color: #fff;
  text-align: left;
  letter-spacing: -0.02em;
}

.app-highlight__body {
  max-width: none;
  width: auto;
  overflow: visible;
}

.app-highlight__body p {
  margin: 0 0 1.1rem;
  font-family: "Source Sans 3", var(--font-body);
  font-size: clamp(1.08rem, 0.55vw + 1.02rem, 1.42rem);
  font-weight: 400;
  line-height: 1.42;
  color: rgba(255, 255, 255, 0.9);
}

/* Match info-card body type; keep white on navy band */
.app-highlight__list {
  margin: 0 0 1.1rem;
  padding-left: 1.35em;
  list-style: disc;
  font-family: "Source Sans Pro", var(--font-body);
  /* Same size as Ready to invest list */
  font-size: clamp(1.2rem, 2.05vw, 1.35rem);
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.92);
}

.app-highlight__list li {
  margin-bottom: 0.75rem;
}

.app-highlight__list li:last-child {
  margin-bottom: 0;
}

.app-highlight__body > :last-child {
  margin-bottom: 0;
}

.app-highlight__body strong {
  font-weight: 700;
  color: #fff;
}

.app-highlight__body a:not(.btn) {
  color: #fff;
  font-weight: 600;
  text-decoration: none;
}

.app-highlight__body a:not(.btn):hover {
  color: #fff;
  text-decoration: underline;
  text-decoration-color: #fff;
  text-underline-offset: 0.15em;
}

.app-highlight__cta-wrap {
  margin-top: 1.75rem !important;
  text-align: center;
}

.app-highlight .btn-light {
  color: #002340;
}

/* ── App-style modal (View Demo chooser) ── */
.ciq-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.ciq-modal.is-open {
  display: flex;
}

.ciq-modal[hidden] {
  display: none !important;
}

.ciq-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(4px);
  cursor: pointer;
}

.ciq-modal__dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 28rem;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 20px 50px rgba(0, 35, 64, 0.22);
}

.ciq-modal__dialog--wide {
  max-width: min(44rem, 96vw);
}

.ciq-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid #f0f0f0;
  flex-shrink: 0;
}

.ciq-modal__title {
  margin: 0;
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 550;
  color: #111827;
}

.ciq-modal__close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #9ca3af;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
}

.ciq-modal__close:hover {
  background: #f3f4f6;
  color: #4b5563;
}

.ciq-modal__body {
  padding: 1.25rem 1.5rem 1.5rem;
  overflow-y: auto;
}

.demo-chooser {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}

.demo-chooser__col {
  padding: 0.25rem 1.25rem 0.25rem 0;
}

.demo-chooser__col + .demo-chooser__col {
  padding: 0.25rem 0 0.25rem 1.25rem;
  border-left: 1px solid #e5e7eb;
}

.demo-chooser__heading {
  margin: 0 0 0.75rem;
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--color-primary);
}

.demo-chooser__list {
  margin: 0 0 1.15rem;
  padding-left: 1.2em;
  /* Match info-card / free-app list body type */
  font-family: "Source Sans Pro", var(--font-body);
  font-size: clamp(1.05rem, 1.7vw, 1.15rem);
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.4;
  color: #374151;
}

.demo-chooser__list li {
  margin-bottom: 0.5rem;
}

.demo-chooser .btn {
  width: 100%;
  text-align: center;
  text-decoration: none;
}

.ciq-modal .btn-primary {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
}

.ciq-modal .btn-primary:hover {
  background: #001a30;
  color: #fff;
}

@media (max-width: 640px) {
  .demo-chooser {
    grid-template-columns: 1fr;
  }

  .demo-chooser__col {
    padding: 0 0 1.25rem;
  }

  .demo-chooser__col + .demo-chooser__col {
    padding: 1.25rem 0 0;
    border-left: 0;
    border-top: 1px solid #e5e7eb;
  }
}

/* Free app → Practical Tools */
main > .app-highlight + .section,
main > #neighborhood-database + .section,
#services.section {
  padding-top: 1.75rem;
}

/* Practical Tools → Partnership services: match approach-section spacing */
#services.section {
  padding-bottom: 1.5rem;
}

#partnership-services.section {
  padding-top: 1.75rem;
  padding-bottom: 1.5rem;
}

#engage.approach-block {
  padding-top: 1.5rem;
  padding-bottom: 1.5rem;
  background: var(--color-primary-green);
  color: #fff;
}

#engage .section__title {
  color: #fff;
  font-weight: 550;
}

#engage .section__intro {
  max-width: none;
  /* Match info-card body size; keep light text on green */
  font-family: "Source Sans Pro", var(--font-body);
  font-size: clamp(1.05rem, 1.7vw, 1.15rem);
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.92);
}

/* Engage → Ready to invest: tighter gap above Ready to invest */
main > #engage + .cta-band,
main > #engage + #ready-to-invest {
  margin-top: 0;
}

#ready-to-invest.cta-band {
  padding-top: 1.15rem;
}

/* ── Feature cards with images ── */
#services .section__title,
#partnership-services .section__title {
  margin-bottom: 2rem;
}

#services .container,
#services .feature-grid,
#partnership-services .container,
#partnership-services .feature-grid {
  margin-bottom: 0;
  padding-bottom: 0;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

/*
 * Card frame like problem-solution pics: 1px navy on top of the card.
 */
.feature-card {
  position: relative;
  background: #fff;
  border: 0;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s, transform 0.2s;
  box-sizing: border-box;
}

.feature-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  border-radius: 8px;
  box-shadow: inset 0 0 0 1px #e6e6e6;
}

.feature-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

a.feature-card--link {
  display: block;
  color: inherit;
  text-decoration: none;
  cursor: pointer;
}

a.feature-card--link:hover h3 {
  color: var(--color-secondary-blue);
}

/* Reveal must not leave cards washed out after animation */
#services .feature-card.js-reveal.is-revealed {
  opacity: 1;
  filter: none;
}

.feature-card__media {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #e6e6e6;
  margin: 0;
  padding: 0;
  border: 0;
}

.feature-card__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  border: 0;
}

.feature-card--album {
  cursor: pointer;
}

.feature-card--album:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* Eye cue: Lucide Eye — album cards only, hover/focus */
.feature-card__preview-hint {
  position: absolute;
  top: 0.95rem;
  right: 0.95rem;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.25rem;
  border-radius: 0.25rem;
  background: transparent;
  color: #9ca3af;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease;
}

.feature-card__preview-hint svg {
  width: 17px;
  height: 17px;
}

.feature-card--album:hover .feature-card__preview-hint,
.feature-card--album:focus-visible .feature-card__preview-hint {
  opacity: 1;
  color: #9ca3af;
}

.feature-card__body {
  padding: 1.35rem 1.5rem 1.5rem;
}

/* Album modal: same shell as View Demo; image only (no title, padding, or borders) */
.album-modal__dialog {
  /* Fill most of the viewport while keeping 16:9 */
  width: min(94vw, calc(92vh * 16 / 9));
  max-width: 94vw;
  max-height: 92vh;
  background: #fff;
  overflow: hidden;
  padding: 0;
  border: 0;
}

.album-modal__stage {
  margin: 0;
  padding: 0;
  border: 0;
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: 92vh;
  background: #000;
  line-height: 0;
}

.album-modal__img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  border: 0;
  margin: 0;
  padding: 0;
}

.album-modal__close {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.45);
  color: #fff;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
}

.album-modal__close:hover {
  background: rgba(0, 0, 0, 0.65);
}

.album-modal__nav {
  position: absolute;
  top: 50%;
  z-index: 3;
  transform: translateY(-50%);
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.45);
  color: #fff;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

.album-modal__nav:hover {
  background: rgba(0, 0, 0, 0.65);
}

.album-modal__nav--prev {
  left: 0.5rem;
}

.album-modal__nav--next {
  right: 0.5rem;
}

.album-modal__nav[hidden] {
  display: none !important;
}

/* Match green stats-band type (Source Sans Pro, weights/sizes); darker colors for white cards */
.feature-card h3 {
  margin: 0 0 0.55rem;
  font-family: "Source Sans Pro", var(--font-body);
  /* Fixed at former clamp max so portrait matches landscape readability */
  font-size: 1.275rem;
  font-weight: 550;
  letter-spacing: 0.01em;
  line-height: 1.15;
  color: var(--color-primary);
}

.feature-card p {
  margin: 0;
  font-family: "Source Sans Pro", var(--font-body);
  /* Fixed at former clamp max so portrait matches landscape readability */
  font-size: 1.15rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.4;
  color: var(--color-muted);
}

.feature-card__note {
  margin: 0.85rem 0 0;
  font-family: "Source Sans Pro", var(--font-body);
  font-size: clamp(0.95rem, 1.4vw, 1.05rem);
  font-weight: 400;
  font-style: italic;
  letter-spacing: 0.02em;
  line-height: 1.35;
  color: var(--color-muted);
}

.feature-card__note--sm {
  font-size: clamp(0.75rem, 1vw, 0.85rem);
}

/* ── Pillars / icon row ── */
.pillar-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1rem;
}

.pillar-item {
  padding: 1.5rem 1.25rem;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  border-top: 3px solid var(--color-primary-green);
}

.pillar-item h3 {
  margin: 0 0 0.5rem;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--color-primary);
}

.pillar-item p {
  margin: 0;
  font-size: 0.88rem;
  color: var(--color-muted);
  line-height: 1.5;
}

/* ── PSO cards ── */
.card-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.info-card {
  padding: 2rem 1.75rem;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
}

.card-row > .info-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  min-height: 100%;
}

.card-row .info-card__icon {
  display: flex;
  justify-content: center;
  margin-bottom: 1.25rem;
}

.card-row .info-card__icon svg,
.card-row .info-card__icon img {
  display: block;
  width: 64px;
  height: 64px;
}

.card-row .info-card__text {
  flex: 1;
  margin: 0 0 1.25rem;
  color: var(--color-muted);
  font-size: clamp(1.08rem, 0.55vw + 1.02rem, 1.42rem);
  line-height: 1.42;
  min-height: calc(5 * 1.42em);
}

.card-row .info-card__label {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--color-primary);
  text-align: center;
}

.info-card h3 {
  margin: 0 0 0.65rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--color-primary);
}

.info-card p {
  margin: 0;
  color: var(--color-muted);
  font-size: 0.96rem;
}

/* ── Quote block ── */
.quote-band {
  padding: 0;
}

.quote-band__grid {
  display: grid;
  grid-template-columns: 1fr 3fr;
  align-items: stretch;
}

.quote-band__brand {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 0.75rem 1.5rem 0.75rem 0;
  background: #fff;
}

.quote-band__brand img {
  width: 280px;
  max-width: 100%;
  height: auto;
  display: block;
}

.quote-band__content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  padding: 0.75rem 0 0.75rem 1.5rem;
  background: #ffffff;
  text-align: left;
}

.quote-band blockquote {
  margin: 0;
  width: 100%;
  max-width: none;
  font-family: var(--font-heading);
  font-size: clamp(1.75rem, 3.2vw, 2.5rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #002340;
}

.quote-band cite {
  display: block;
  margin-top: 1rem;
  font-family: "Source Sans Pro", var(--font-body);
  font-size: clamp(1.5rem, 2.7vw, 1.8rem);
  font-style: normal;
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: 0.02em;
  color: #7a7a7a;
}

/* ── Audience tags ── */
.tag-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.tag {
  padding: 0.5rem 1rem;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  font-size: 0.9rem;
  color: var(--color-text);
}

/* ── CTA (Ready to invest) — white band, navy type ── */
.cta-band {
  position: relative;
  padding: var(--band-inner-y, 1.75rem) 0;
  background-color: #fff;
  background-image: none;
  color: #002340;
  text-align: left;
}

.cta-band::before {
  display: none;
}

.cta-band .container {
  position: relative;
  z-index: 1;
}

.cta-band__title {
  margin: 0 0 1rem;
  font-family: var(--font-heading);
  font-size: clamp(1.575rem, 2.88vw, 2.25rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #002340;
  text-align: center;
}

.cta-band__body {
  max-width: none;
  width: auto;
}

.cta-band__list {
  margin: 0 0 1.1rem;
  padding-left: 1.35em;
  list-style: disc;
  /* Match feature-card body type; keep navy */
  font-family: "Source Sans Pro", var(--font-body);
  font-size: clamp(1.2rem, 2.05vw, 1.35rem);
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.4;
  color: #002340;
}

.cta-band__list li {
  margin-bottom: 0.75rem;
  padding-left: 0.25em;
}

.cta-band__list li:last-child {
  margin-bottom: 0;
}

.cta-band__cta-wrap {
  margin: 1.75rem 0 0;
  text-align: center;
}

.cta-band .btn-light {
  background: #002340;
  color: #fff;
  border-color: #002340;
}

.cta-band .btn-light:hover {
  background: #001a30;
  color: #fff;
  border-color: #001a30;
}

/* ── Footer (copyright bar only — same height as topbar) ── */
.site-footer {
  background: #002340;
  color: rgba(255, 255, 255, 0.85);
  height: var(--footer-bar-height);
  min-height: var(--footer-bar-height);
  max-height: var(--footer-bar-height);
  padding: 0;
  border-top: 0;
  box-sizing: border-box;
  display: flex;
  align-items: center;
}

.site-footer .container {
  width: min(100% - 2.5rem, var(--max-width));
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}

.footer-bottom {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.65);
  line-height: 1;
  text-align: center;
}

.mobile-toggle {
  display: none;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  padding: 0.5rem 0.75rem;
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--color-primary);
  cursor: pointer;
}

@media (max-width: 1024px) {
  .split,
  .feature-grid,
  .card-row,
  .pillar-row {
    grid-template-columns: 1fr 1fr;
  }

  .pillar-row {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  /* Same fit rule on small screens: full slide frame, no vertical scroll */
  .ciq-hero {
    height: min(calc(100vw * 9 / 16), var(--hero-max-height));
    max-height: var(--hero-max-height);
    min-height: 0;
    aspect-ratio: auto;
  }

  .ciq-hero__slide {
    background-size: cover;
    background-position: center center;
  }

  .ciq-hero__slide-video {
    object-fit: cover;
    object-position: center center;
  }

  /* Hide on-image slogan; topbar logo stays. Headlines scale fluidly & wrap freely. */
  .ciq-hero__brand {
    display: none !important;
  }

  .ciq-hero h1 {
    font-size: clamp(1.25rem, 7.2cqi, 2.65rem);
  }

  .ciq-hero__content {
    align-items: center;
    justify-content: center;
    padding: 12% 4% 14%;
  }

  .ciq-hero__inner {
    transform: none;
  }

  .ciq-hero .hero__headline-primary,
  .ciq-hero .hero__headline-secondary {
    white-space: normal;
  }

  /* Slogan banner + pull quote as one white block under hero */
  .section--lead-quote {
    padding-top: 0;
    padding-bottom: 1.5rem;
  }

  .hero-mobile-brand {
    display: block;
    width: 100%;
    margin: 0;
    padding: 1.15rem 0 0.35rem;
    background: #fff;
    text-align: center;
    line-height: 0;
  }

  .hero-mobile-brand__logo {
    display: block;
    width: 90%;
    max-width: 90%;
    height: auto;
    margin: 0 auto;
    object-fit: contain;
  }

  .section--lead-quote .container {
    padding-top: 0.75rem;
  }

  /* Problem-solving / approach: tighter vertical space above each article */
  .section.approach-block {
    padding-top: 1.25rem;
    padding-bottom: 1rem;
  }

  main > .section.approach-block + .section.approach-block {
    padding-top: 1rem;
  }

  /* Problem-solving / approach: text first, picture under */
  .approach-block .split {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .approach-block .split__content {
    order: 1;
  }

  .approach-block .split__media {
    order: 2;
    max-width: none;
    width: 100%;
    justify-self: stretch;
  }

  .approach-block .media-zoom-trigger {
    max-width: none;
    width: 100%;
    margin-inline: 0;
  }

  .approach-block .media-box--approach,
  .approach-block img.media-box--dashboard {
    max-width: none;
    width: 100%;
  }

  .quote-band__grid {
    grid-template-columns: 1fr;
  }

  .quote-band__brand {
    justify-content: center;
    align-items: center;
    padding: 1rem 0;
  }

  .quote-band__brand img {
    width: 280px;
    height: auto;
  }

  .quote-band__content {
    padding: 1rem 0;
  }

  .ciq-hero__arrow {
    display: none;
  }

  .split,
  .feature-grid,
  .card-row,
  .pillar-row,
  .stats-band__grid {
    grid-template-columns: 1fr;
  }

  /* Same enlarged type as desktop (vw clamp was stuck on the small floor) */
  .stats-band .stat-item strong {
    font-size: 1.5rem;
  }

  .stats-band .stat-item span {
    font-size: 1.25rem;
  }

  .split--reverse .split__media,
  .split--reverse .split__content {
    order: unset;
  }

  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    background: #fff;
    border-bottom: 1px solid var(--color-border);
    padding: 1rem;
    gap: 0.75rem;
  }

  .site-nav.is-open {
    display: flex;
  }

  .mobile-toggle {
    display: inline-flex;
  }

  .site-header__inner {
    position: relative;
  }
}

/* ── Scroll reveal (shared timing) ── */
.js-reveal {
  /* Longer ease-out tail so motion softens toward the end (not a delayed start) */
  --reveal-duration: 3.25s;
  --reveal-ease: cubic-bezier(0.08, 0.82, 0.12, 1);
  --reveal-distance: 2.25rem;
  opacity: 0;
  transform: translate3d(0, 0, 0);
  transition:
    opacity var(--reveal-duration) var(--reveal-ease),
    transform var(--reveal-duration) var(--reveal-ease);
  transition-delay: var(--reveal-delay, 0ms);
  will-change: opacity, transform;
}

.js-reveal[data-reveal="left"] {
  transform: translate3d(calc(var(--reveal-distance) * -1), 0, 0);
}

.js-reveal[data-reveal="right"] {
  transform: translate3d(var(--reveal-distance), 0, 0);
}

.js-reveal[data-reveal="up"] {
  transform: translate3d(0, var(--reveal-distance), 0);
}

.js-reveal.is-revealed {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

@media (prefers-reduced-motion: reduce) {
  .js-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}