/* ==========================================================================
   Condo Bridge — lightweight static stylesheet
   Edit the variables below to tune the whole site.
   ========================================================================== */

:root {
  --brand: #2d6ed4; /* #136fff; */          /* primary accent */
  --brand-dark: #1b5fd0;
  --orange: #f97316;         /* Get Quote button */
  --orange-dark: #ea580c;
  --green: #16a34a;
  --green-dark: #15803d;
  --navy: #0e2238;           /* headings / dark sections */
  --ink: #33445c;            /* body text */
  --muted: #46556c;
  --bg: #ffffff;
  --bg-soft: #e8f0fb;
  --line: #e3e9f2;
  --line-soft: #eef2f8;      /* subtler border for cards */
  --heading: var(--navy);    /* headings & strong text (lightens in dark mode) */
  --surface: #ffffff;        /* cards, dropdowns, dialogs */
  --radius: 14px;
  --shadow: 0 10px 30px rgba(14, 34, 56, .08);
  --maxw: 1140px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-dark); }

h1, h2, h3, h4, h5 { color: var(--heading); line-height: 1.2; font-weight: 700; }
h1 { font-size: clamp(2.1rem, 5vw, 3.2rem); letter-spacing: -.02em; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.3rem); letter-spacing: -.01em; }
h3 { font-size: 1.35rem; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* Small uppercase label above headings */
.eyebrow {
  display: inline-block;
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: .6rem;
  padding: .2rem .7rem;
  border: 1px solid #a9c8fb;
  border-radius: 999px;
}

.lead { font-size: 1.15rem; color: var(--muted); }

.highlight { color: var(--brand); }
section.dark .highlight { color: #7fb0ff; }

/* Buttons */
.btn {
  display: inline-block;
  white-space: nowrap;
  padding: .8rem 1.7rem;
  border-radius: 999px;
  font: inherit;
  font-weight: 600;
  letter-spacing: .02em;
  line-height: 1.4;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all .18s ease;
}
/* Solid variants share the gradient/lift/press effect, borderless with
   padding compensating for the removed 2px border */
.btn-primary,
.btn-green,
.btn-orange,
.btn-dark {
  color: #fff;
  border: none;
  padding: calc(.8rem + 2px) calc(1.7rem + 2px);
  text-shadow: 0 1px 1px rgba(0, 0, 0, .18);
}
.btn-primary:hover,
.btn-green:hover,
.btn-orange:hover,
.btn-dark:hover {
  color: #fff;
  transform: translateY(-1px);
}
.btn-primary:active,
.btn-green:active,
.btn-orange:active,
.btn-dark:active,
.btn-outline:active {
  transform: none;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, .2);
}
.btn-primary {
  background: linear-gradient(180deg, #4a8bf7 0%, #3781f6 45%, var(--brand-dark) 100%);
  box-shadow: 0 2px 8px rgba(27, 95, 208, .3);
}
.btn-primary:hover {
  background: linear-gradient(180deg, #3781f6 0%, var(--brand-dark) 100%);
  box-shadow: 0 4px 12px rgba(27, 95, 208, .4);
}
.btn-green {
  background: linear-gradient(180deg, #1db150 0%, var(--green) 45%, var(--green-dark) 100%);
  box-shadow: 0 2px 8px rgba(22, 163, 74, .3);
}
.btn-green:hover {
  background: linear-gradient(180deg, var(--green) 0%, var(--green-dark) 100%);
  box-shadow: 0 4px 12px rgba(22, 163, 74, .4);
}
.btn-orange {
  background: linear-gradient(180deg, #fb851d 0%, var(--orange) 45%, var(--orange-dark) 100%);
  box-shadow: 0 2px 8px rgba(234, 88, 12, .3);
}
.btn-orange:hover {
  background: linear-gradient(180deg, var(--orange) 0%, var(--orange-dark) 100%);
  box-shadow: 0 4px 12px rgba(234, 88, 12, .4);
}
.btn-dark {
  background: linear-gradient(180deg, #1f4265 0%, #16334f 45%, var(--navy) 100%);
  box-shadow: 0 2px 8px rgba(14, 34, 56, .35);
}
.btn-dark:hover {
  background: linear-gradient(180deg, #16334f 0%, var(--navy) 100%);
  box-shadow: 0 4px 12px rgba(14, 34, 56, .45);
}
.btn-outline { border-color: var(--heading); color: var(--heading); background: transparent; }
.btn-outline:hover {
  color: #fff;
  background: linear-gradient(180deg, #16334f 0%, var(--navy) 100%);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(14, 34, 56, .45);
  text-shadow: 0 1px 1px rgba(0, 0, 0, .18);
}
.btn-light { background: #fff; color: var(--navy); }
.btn-light:hover { background: var(--bg-soft); }

/* ==========================================================================
   Header / navigation
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.nav-wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  min-height: 72px;
}

.logo img { height: 46px; width: auto; }

.nav-toggle { display: none; }
.nav-backdrop { display: none; }
.nav-toggle-label {
  display: none;
  margin-left: auto;
  cursor: pointer;
  width: 30px;
  height: 22px;
  position: relative;
}
.nav-toggle-label span,
.nav-toggle-label span::before,
.nav-toggle-label span::after {
  content: "";
  position: absolute;
  height: 3px;
  width: 100%;
  border-radius: 3px;
  background: var(--heading);
  transition: all .3s ease;
}
.nav-toggle-label span { top: 9px; }
.nav-toggle-label span::before { top: -9px; }
.nav-toggle-label span::after { top: 9px; }
/* hamburger ⇄ X: the two icons sit on top of each other and fade in
   sequence — the visible one fades out first, then the other fades in.
   Each rule's transition applies when moving TO that state, so fade-ins
   (to the visible state) carry a .3s delay and fade-outs run at once. */
.nav-toggle-label span { opacity: 1; transition: opacity .3s ease .3s; }
.nav-toggle-label::before,
.nav-toggle-label::after {
  content: "";
  position: absolute;
  top: 9px;
  height: 3px;
  width: 100%;
  border-radius: 3px;
  background: var(--heading);
  opacity: 0;
  transition: opacity .3s ease;
}
.nav-toggle-label::before { transform: rotate(45deg); }
.nav-toggle-label::after { transform: rotate(-45deg); }
.nav-toggle:checked ~ .nav-toggle-label span {
  opacity: 0;
  transition: opacity .3s ease;
}
.nav-toggle:checked ~ .nav-toggle-label::before,
.nav-toggle:checked ~ .nav-toggle-label::after {
  opacity: 1;
  transition: opacity .3s ease .3s;
}

nav.main-nav { margin: 0 auto; }
nav.main-nav ul { list-style: none; display: flex; gap: .3rem; align-items: center; }
nav.main-nav > ul > li { position: relative; }
nav.main-nav a {
  display: block;
  padding: .55rem .85rem;
  color: var(--heading);
  font-weight: 600;
  font-size: .96rem;
  border-radius: 8px;
}
nav.main-nav a:hover { background: var(--bg-soft); color: var(--brand); }

/* Dropdown */
li.has-sub > a::after { content: " ▾"; font-size: 1.15em; line-height: 1; }
li.has-sub .sub {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 200px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow);
  padding: 0;
  overflow: hidden;   /* keep item hover backgrounds inside the rounded corners */
  display: none;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
}
/* invisible hover bridge so the menu doesn't close crossing the 6px gap */
li.has-sub::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  height: 6px;
}
li.has-sub:hover .sub,
li.has-sub:focus-within .sub { display: flex; }
li.has-sub .sub li { width: 100%; margin: 0; }
li.has-sub .sub a {
  display: block;
  width: 100%;
  padding: .55rem 1.2rem;   /* matches previous panel padding + item padding */
  white-space: nowrap;
  border-radius: 0;   /* flush edge-to-edge hover highlight */
}
li.has-sub .sub li:first-child a { padding-top: .95rem; }
li.has-sub .sub li:last-child a { padding-bottom: .95rem; }

.nav-cta { display: flex; gap: .6rem; align-items: center; }
.nav-cta .btn { padding: .55rem 1.2rem; font-size: .92rem; }
.nav-cta .btn-orange,
.nav-cta .btn-primary { padding: calc(.55rem + 2px) calc(1.2rem + 2px); }

/* Mobile nav — breakpoint sits just above the width the one-line header
   needs (~1045px), so the squeezed wrapping state never shows */
@media (max-width: 1060px) {
  .nav-toggle-label { display: block; }
  nav.main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
    margin: 0;
  }
  .nav-toggle:checked ~ nav.main-nav { display: block; }
  /* lock page scroll while the menu is expanded (same trick as dialogs);
     the menu itself scrolls when taller than the viewport */
  body:has(.nav-toggle:checked) { overflow: hidden; }
  /* dimmed + blurred backdrop matching dialog::backdrop. The visual layer
     lives on body::before — inside .site-header a backdrop-filter can't
     sample the page (the header's own backdrop-filter makes it a backdrop
     root). The invisible in-header label handles click-to-close. */
  body:has(.nav-toggle:checked)::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 99;   /* just under the header (100), above the page */
    background: rgba(10, 20, 35, .55);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
  }
  .nav-toggle:checked ~ .nav-backdrop {
    display: block;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    height: 100vh;
  }
  nav.main-nav { max-height: calc(100vh - 72px); overflow-y: auto; }
  nav.main-nav ul { flex-direction: column; align-items: stretch; padding: .8rem 1rem .8rem 2rem; }
  /* submenus collapse; tapping the parent toggles .open (see layout JS).
     hover/focus-within must not reveal them here like they do on desktop */
  li.has-sub .sub,
  li.has-sub:hover .sub,
  li.has-sub:focus-within .sub {
    position: static;
    /* always rendered so expand/collapse can animate via max-height */
    display: flex;
    max-height: 0;
    overflow: hidden;
    visibility: hidden;
    border: none;
    border-radius: 0;
    box-shadow: none;
    margin-left: 1.05rem;
    padding-left: .4rem;
    transition: max-height .6s ease, visibility .6s;
  }
  li.has-sub.open .sub {
    max-height: 22rem;
    visibility: visible;
  }
  /* light vertical line marking the items as children of the parent;
     on the last item it stops at the row's middle */
  li.has-sub .sub li { border-left: 2px solid var(--line); }
  li.has-sub .sub li:last-child {
    border-left: 2px solid transparent;
    background: linear-gradient(var(--line), var(--line)) 0 0 / 2px 75% no-repeat;
    /* align the strip with the border-drawn line of the items above */
    background-origin: border-box;
  }
  li.has-sub > a::after { content: " ▸"; }
  li.has-sub.open > a::after { content: " ▾"; }
  /* right-side group: CTAs stay visible while they fit, then the
     theme toggle, then the hamburger (DOM order differs) */
  .nav-cta { order: 1; margin-left: auto; }
  .theme-toggle { order: 2; }
  .nav-toggle-label { order: 3; margin-left: 0; }
}
/* phones: both CTAs move out of the bar into the expanded menu,
   right-aligned at the top */
.menu-login { display: none; }
@media (max-width: 580px) {
  .nav-wrap { gap: .8rem; }
  .nav-cta { display: none; }
  .theme-toggle { margin-left: auto; }
  .menu-login {
    display: flex;
    justify-content: flex-end;
    gap: .6rem;
    padding: .55rem .85rem;
  }
  .menu-login .btn {
    padding: calc(.55rem + 2px) calc(1.2rem + 2px);
    font-size: .92rem;
  }
}

/* ==========================================================================
   Sections
   ========================================================================== */

section { padding: 72px 0; }
section.soft { background: var(--bg-soft); }
section.dark { background: var(--navy); }
section.dark h1, section.dark h2, section.dark h3 { color: #fff; }
section.dark p { color: #c6d3e4; }
section.dark .eyebrow {
  color: #7fb0ff;
  background: rgba(127, 176, 255, .14);
  border-color: rgba(127, 176, 255, .35);
}

/* No pill border for eyebrows sitting on plain white sections */
section:not(.soft):not(.dark):not(.page-hero) .eyebrow {
  border: none;
  padding: 0;
}

.section-head { text-align: center; max-width: 720px; margin: 0 auto 3rem; }

/* Heading forced onto a single line (slightly smaller so it fits) */
.h2-one-line { white-space: nowrap; font-size: clamp(1.5rem, 4.5vw, 2rem); }
@media (max-width: 760px) { .h2-one-line { white-space: normal; } }

/* Hero */
.hero { padding: 96px 0; text-align: center; }

/* Flipping highlighted word in hero heading */
.flip-word-wrap {
  display: grid;           /* block-level: flipping word gets its own line */
  justify-items: center;
}
.flip-word-wrap > * { grid-area: 1 / 1; }
.flip-sizer { visibility: hidden; }  /* reserves the width of the longest word */
.flip-word {
  display: inline-block;
  color: var(--brand);
  transition: opacity .4s ease;
}
.flip-word.out {
  opacity: 0;
}
.hero p.lead { max-width: 620px; margin: 1.2rem auto 2rem; }
.hero .actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* City hero: photo background (set per-page via --city-hero-img);
   text shadows carry the readability */
section.city-hero {
  position: relative;
  overflow: hidden;
}
/* image layer is 20% taller than the hero so the JS-driven shift never shows a gap */
section.city-hero::before {
  content: "";
  position: absolute;
  inset: -20% 0;
  background: var(--city-hero-img) center / cover no-repeat;
  transform: translate3d(0, var(--parallax-shift, 0px), 0);
  will-change: transform;
}
section.city-hero > .container { position: relative; }
section.city-hero h1 {
  text-shadow:
    0 1px 2px rgba(10, 20, 35, .9),
    0 3px 10px rgba(10, 20, 35, .65),
    0 10px 40px rgba(10, 20, 35, .6);
}
section.city-hero .lead { color: #fff; text-shadow: 0 1px 3px rgba(10, 20, 35, .7), 0 2px 16px rgba(10, 20, 35, .6); }
section.city-hero .eyebrow {
  color: var(--brand);
  border-color: var(--brand);
  background: #fff;
  text-shadow: none;
}
/* frosted panel wrapping the hero eyebrow, title and quote form */
section.city-hero .hero-panel {
  max-width: 720px;
  margin: 0 auto;
  padding: 2.2rem 2rem;
  border: 1px solid rgba(255, 255, 255, .25);
  border-radius: var(--radius);
  background: rgba(14, 34, 56, .65);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 10px 30px rgba(10, 20, 35, .35);
}
@media (max-width: 700px) {
  section.city-hero .hero-panel { padding: 1.4rem; }
}
section.city-hero .inline-quote-form .form-title {
  grid-column: 1 / -1;
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
  text-align: left;
  text-shadow: 0 1px 2px rgba(10, 20, 35, .6);
}

/* Page hero (inner pages) */
.page-hero { padding: 80px 0 64px; text-align: center; background: var(--bg-soft); }
.page-hero p.lead { max-width: 640px; margin: 1rem auto 0; }

/* Two-column split (text + image) */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}
.split.reverse > .split-media { order: -1; }
.split > .split-media.align-top { align-self: start; }
.split-media img { border-radius: var(--radius); }
.split h2 { margin-bottom: 1rem; }
.split .eyebrow { margin-bottom: .4rem; }
.split p + p { margin-top: 1rem; }
.split .btn { margin-top: 1.6rem; }

.checks { list-style: none; margin-top: 1.4rem; }
.checks li { padding-left: 1.4rem; position: relative; margin-bottom: .5rem; font-weight: 600; color: var(--heading); }
.checks li::before { content: "✓"; position: absolute; left: 0; color: var(--brand); font-weight: 800; }
/* side-by-side variant */
.checks-row { display: flex; flex-wrap: wrap; gap: .5rem 2rem; }
.checks-row li { margin-bottom: 0; }

@media (max-width: 820px) {
  .split { grid-template-columns: 1fr; gap: 2.2rem; }
  .split.reverse > .split-media { order: 0; }
}

/* Feature cards */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.6rem;
}
/* fixed two-up variant, stays side by side even in narrow columns */
.cards-2 { grid-template-columns: 1fr 1fr; }
.card-icon { width: 26px; height: 26px; fill: var(--brand); flex-shrink: 0; }
/* icon sits left of the card title, description spans full width below */
.card:has(> .card-icon) { display: grid; grid-template-columns: auto 1fr; column-gap: .7rem; align-items: center; align-content: start; }
.card:has(> .card-icon) h3, .card:has(> .card-icon) h4 { margin-bottom: 0; }
.card:has(> .card-icon) p { grid-column: 2; margin-top: .6rem; }
.card {
  background: var(--surface);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 1.8rem;
  box-shadow: 0 4px 14px rgba(14, 34, 56, .04);
}
/* Formerly glassy card variant — now flat white with a soft shadow */
.card.glass {
  background: var(--surface);
  border: 1px solid #e7e7e7;
  box-shadow: 0 2px 8px rgba(14, 34, 56, .06);
}

.card h3, .card h4 { margin-bottom: .6rem; font-size: 1.15rem; }
.card p { font-size: .98rem; color: var(--muted); }
section.dark .card {
  background: linear-gradient(160deg, rgba(84, 140, 220, .28) 0%, rgba(47, 125, 246, .12) 55%, rgba(20, 45, 80, .25) 100%);
  border-color: rgba(140, 180, 240, .25);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08);
}
section.dark .card h3, section.dark .card h4 { color: #fff; }
section.dark .card-icon { fill: #7fb0ff; }
section.dark .card p { color: #dbe5f2; }

/* Card flow with arrows between cards */
.cards-flow {
  grid-template-columns: 1fr auto 1fr auto 1fr;
  align-items: center;
  gap: 1.2rem;
}
.card-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #7fb0ff;
}
@media (max-width: 900px) {
  .cards-flow { grid-template-columns: 1fr; }
  .card-arrow svg { transform: rotate(90deg); }
}

/* Media row (image trio) */
.media-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.6rem; align-items: center; }
.media-row img { border-radius: var(--radius); }

/* Testimonials */
.testimonials { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.6rem; }
.quote {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.8rem;
  display: flex;
  flex-direction: column;
  box-shadow: 0 5px 12px rgba(14, 34, 56, .1);
}
.quote p { font-size: .97rem; flex: 1; }
.quote footer { margin-top: 1.2rem; }
.quote cite { font-style: normal; font-weight: 700; color: var(--heading); display: block; }
.quote small { color: var(--muted); }

/* FAQ */
.faq { max-width: 800px; margin: 0 auto; }
.faq details {
  border: 1px solid var(--line-soft);
  border-radius: 12px;
  margin-bottom: .9rem;
  background: var(--surface);
}
.faq summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--heading);
  list-style: none;
  position: relative;
  /* padding lives here (not on <details>) so the click hit box reaches the border */
  padding: 1.1rem 3.4rem 1.1rem 1.4rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 1.4rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.3rem;
  color: var(--brand);
}
.faq details[open] { background: var(--bg-soft); border-color: var(--bg-soft); }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin-top: -.3rem; padding: 0 1.4rem 1.1rem; color: var(--muted); }

/* Team */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  column-gap: 2rem;
  row-gap: 3.5rem;
}
.member {
  text-align: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 2rem 2rem;
  margin-top: 65px;              /* room for the photo peeking above */
  display: flex;
  flex-direction: column;
  box-shadow: 0 5px 12px rgba(14, 34, 56, .1);
}
.member img {
  width: 130px;
  height: 130px;
  object-fit: cover;
  border-radius: 50%;
  margin: -65px auto 1.2rem;     /* top half floats above the card */
  border: 4px solid var(--surface);
  box-shadow: 0 6px 18px rgba(14, 34, 56, .15);
}
.member h3 { margin-bottom: .2rem; font-size: 1.25rem; }
.member .role {
  color: var(--brand);
  font-weight: 700;
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--line);
}
.member .role-creds {
  display: block;
  margin-top: .25rem;
  font-size: .9em;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: .04em;
}
.member p {
  font-size: .92rem;
  line-height: 1.6;
  color: var(--muted);
  text-align: left;
}

/* Service area lists */
.area-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; }
.area-cols ul { list-style: none; margin-top: 1rem; }
.area-cols li { padding: .3rem 0; break-inside: avoid; }
@media (max-width: 700px) { .area-cols { grid-template-columns: 1fr; } }

/* Forms */
.form-grid { display: grid; gap: 1rem; }
.form-grid label { font-weight: 600; color: var(--heading); font-size: .92rem; }
.form-grid input, .form-grid textarea {
  width: 100%;
  padding: .8rem 1rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  font: inherit;
  color: #33445c;   /* pinned: inputs keep a white background in dark mode */
  background: #fff;
}
.form-grid input:focus, .form-grid textarea:focus {
  outline: 2px solid var(--brand);
  border-color: var(--brand);
}

/* CTA band */
.cta-band { text-align: center; }
.cta-band .btn { margin-top: 1.6rem; }

/* Inline quote form (in the dark CTA band)
   Row 1: Email (full width) · Row 2: Total Units + Address · Row 3: button */
.inline-quote-form {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: .8rem;
  max-width: 480px;
  margin: 1.8rem auto 0;
}
.inline-quote-form input {
  min-width: 0;
  padding: .8rem 1rem;
  border: none;
  border-radius: 10px;
  font: inherit;
  color: #33445c;   /* pinned: inputs keep a white background in dark mode */
  background: #fff;
}
.inline-quote-form input:focus { outline: 2px solid var(--brand); }

.inline-quote-form input[name="email"] { grid-column: 1 / -1; }

/* Units: narrow column, no spinner arrows */
.inline-quote-form input[name="units"] {
  -moz-appearance: textfield;
  appearance: textfield;
}
.inline-quote-form input[name="units"]::-webkit-outer-spin-button,
.inline-quote-form input[name="units"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.inline-quote-form .btn { margin-top: .4rem; grid-column: 1 / -1; justify-self: stretch; }

@media (max-width: 700px) {
  .inline-quote-form { grid-template-columns: 1fr; }
  .inline-quote-form input[name="units"] { grid-column: 1 / -1; }
  .inline-quote-form .btn { justify-self: stretch; }
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer { background: var(--navy); color: #b9c7da; padding: 64px 0 32px; font-size: .95rem; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 3rem;
}
.site-footer img { height: 48px; width: auto; margin-bottom: 1rem; }
.site-footer h5 { color: #fff; margin-bottom: .9rem; font-size: 1rem; }
.site-footer ul { list-style: none; }
.site-footer li { margin-bottom: .5rem; }
.site-footer a { color: #b9c7da; }
.site-footer a:hover { color: #fff; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .12);
  padding-top: 1.6rem;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.footer-bottom ul { list-style: none; display: flex; gap: 1.4rem; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }

/* ==========================================================================
   Modals (login + video) — native <dialog>
   ========================================================================== */

dialog {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
  border: none;
  border-radius: var(--radius);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .35);
  background: var(--surface);
  color: var(--ink);
  padding: 2.2rem;
  max-width: 420px;
  width: calc(100% - 40px);
}
dialog::backdrop { background: rgba(10, 20, 35, .55); backdrop-filter: blur(3px); }
/* lock background scroll while any modal is open */
body:has(dialog[open]) { overflow: hidden; }
dialog h4 { margin-bottom: .4rem; font-size: 1.3rem; }
dialog .form-grid .btn { margin-top: .6rem; }
dialog .login-options { display: grid; gap: .8rem; margin-top: 1.4rem; }
dialog .login-options .btn { text-align: center; }
dialog input[type="number"] {
  -moz-appearance: textfield;
  appearance: textfield;
}
dialog input[type="number"]::-webkit-outer-spin-button,
dialog input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
dialog .close-x {
  position: absolute;
  top: .8rem;
  right: 1rem;
  background: none;
  border: none;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--muted);
}
/* fill the viewport while keeping the full 16:9 frame visible */
dialog.video-modal {
  padding: 0;
  background: #000;
  max-width: none;
  width: min(100vw - 48px, (100vh - 48px) * 16 / 9);
}
dialog.video-modal iframe { display: block; width: 100%; aspect-ratio: 16/9; border: 0; }
dialog.pdf-modal { max-width: 1400px; width: calc(100% - 48px); padding: 2.6rem 0 0; }
dialog.pdf-modal iframe { display: block; width: 100%; height: calc(94vh - 2.6rem); border: 0; }

/* Utility */
.center { text-align: center; }
.mt-2 { margin-top: 2rem; }
.section-cta { text-align: center; margin-top: 2.4rem; }

/* Flash message (Laravel session feedback) */
.flash-success {
  position: sticky;
  top: 72px;
  z-index: 90;
  text-align: center;
  padding: .8rem 1.2rem;
  background: #e7f7ee;
  color: #15803d;
  font-weight: 600;
  border-bottom: 1px solid #bbe7cd;
}

/* ==========================================================================
   Theme toggle + dark theme
   Toggled by data-theme="dark" on <html>; persisted in localStorage
   (see layouts/app). Light sections restyle via the variables below;
   section.dark, city heroes and the footer already sit on navy.
   ========================================================================== */

/* Miniature day/night sky switch: sun + clouds by day; the thumb slides
   right and becomes a cratered moon while stars fade in at night. */
.theme-toggle {
  position: relative;
  width: 60px;
  height: 30px;
  flex-shrink: 0;
  padding: 0;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  overflow: hidden;
  background: linear-gradient(180deg, #2f7dc9 0%, #62aee9 55%, #a3d4f7 100%);
  box-shadow: inset 0 2px 4px rgba(10, 30, 60, .35);
  transition: background .5s ease;
}
.theme-toggle:hover { filter: brightness(1.08); }
/* sun / moon */
.theme-toggle .tt-thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff3a6, #ffd23e 55%, #f79e02);
  box-shadow: 0 0 8px rgba(255, 205, 60, .9);
  transition: transform .5s cubic-bezier(.5, 1.5, .5, 1), background .5s ease, box-shadow .5s ease;
}
/* moon craters (hidden during the day) */
.theme-toggle .tt-thumb::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background:
    radial-gradient(circle at 30% 30%, rgba(140, 155, 180, .55) 0 3px, transparent 3.5px),
    radial-gradient(circle at 62% 55%, rgba(140, 155, 180, .5) 0 2.5px, transparent 3px),
    radial-gradient(circle at 42% 72%, rgba(140, 155, 180, .45) 0 2px, transparent 2.5px);
  opacity: 0;
  transition: opacity .5s ease;
}
/* clouds drift near the bottom right during the day */
.theme-toggle .tt-clouds {
  position: absolute;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #fff;
  right: 16px;
  bottom: 12px;
  box-shadow:
    7px 3px 0 1px #fff,
    -6px 4px 0 0 #fff,
    13px 6px 0 2px #eef7ff,
    1px 6px 0 2px #eef7ff;
  transition: transform .5s ease, opacity .4s ease;
}
/* stars come out at night on the left */
.theme-toggle .tt-stars {
  position: absolute;
  top: 8px;
  left: 15px;
  width: 2px;
  height: 2px;
  border-radius: 50%;
  background: #fff;
  box-shadow:
    7px 6px 0 0 #fff,
    14px -2px 0 0 #fff,
    16px 9px 0 -.5px #fff,
    4px 13px 0 -.5px #fff;
  opacity: 0;
  transform: translateY(-8px);
  transition: transform .5s ease, opacity .4s ease;
}
html[data-theme="dark"] .theme-toggle {
  background: linear-gradient(180deg, #0a1430 0%, #17264a 60%, #263760 100%);
}
/* crescent moon: transparent disc where only the inset shadow is drawn */
html[data-theme="dark"] .theme-toggle .tt-thumb {
  transform: translateX(30px);
  background: transparent;
  box-shadow: inset -7px 0 0 0 #f4d871;
}
html[data-theme="dark"] .theme-toggle .tt-clouds { transform: translateY(14px); opacity: 0; }
html[data-theme="dark"] .theme-toggle .tt-stars { transform: translateY(0); opacity: 1; }

/* the nav shows whichever logo matches the theme */
.logo .logo-dark { display: none; }
html[data-theme="dark"] .logo .logo-light { display: none; }
html[data-theme="dark"] .logo .logo-dark { display: block; }

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0b1826;
  --bg-soft: #10202f;
  --surface: #142639;
  --ink: #c6d3e4;
  --muted: #9aabc2;
  --heading: #eaf1fa;
  --line: #24405c;
  --line-soft: #1d3450;
  --shadow: 0 10px 30px rgba(0, 0, 0, .35);
}
html[data-theme="dark"] .site-header { background: rgba(11, 24, 38, .92); }
html[data-theme="dark"] a:not(.btn) { color: #7fb0ff; }
html[data-theme="dark"] a:not(.btn):hover { color: #a9c8fb; }
/* brand blue is too dark against navy — reuse the dark-section accent */
html[data-theme="dark"] .highlight,
html[data-theme="dark"] .flip-word { color: #7fb0ff; }
html[data-theme="dark"] .eyebrow {
  color: #7fb0ff;
  border-color: rgba(127, 176, 255, .35);
}
/* city hero eyebrow sits on a photo in a white pill — same in both themes */
html[data-theme="dark"] section.city-hero .eyebrow {
  color: var(--brand);
  border-color: var(--brand);
}
html[data-theme="dark"] .card-icon { fill: #7fb0ff; }
html[data-theme="dark"] .faq summary::after { color: #7fb0ff; }
html[data-theme="dark"] .checks li::before { color: #7fb0ff; }
html[data-theme="dark"] .member .role { color: #7fb0ff; }
html[data-theme="dark"] .card.glass { border-color: var(--line-soft); }
html[data-theme="dark"] .flash-success {
  background: #0f2b1c;
  color: #4ade80;
  border-bottom-color: #1d4d33;
}
