:root {
  /* Hugo brand palette — neutral first. Violet and conifer are punctuation,
     never color zones. The shell structure stays deliberately unchanged. */
  --page: #f4f2ee;
  --page-dim: #f4f2ee;
  --page-low: #f4f2ee;
  --page-deep: #f4f2ee;
  --surface: #ffffff;
  --surface-muted: #f4f2ee;
  --surface-raise: #ffffff;
  --ink: #0a0a0a;
  --ink-soft: #3d3d3d;
  --muted: #737373;
  --faint: #737373;
  --line: #e5e5e5;
  --line-soft: #e5e5e5;
  --line-strong: #e5e5e5;
  /* Input/select/textarea border only (#10, 1.4.11): --line's ~1.28:1 against
     --surface is well under the 3:1 non-text-contrast minimum. This gray hits
     ~3.4:1 on white without going as dark as --ink, so the resting state still
     reads quiet next to the --accent focus ring, which is untouched. */
  --line-input: #737373;
  --accent: #4f06eb;
  --accent-soft: rgba(79, 6, 235, 0.1);
  --accent-line: #e5e5e5;
  --live: #0a0a0a;
  --live-bg: #cfff5e;
  --live-line: #e5e5e5;
  /* Conifer — used sparingly, small badges/highlight chips only (brand system). */
  --conifer: #cfff5e;

  /* Grid pattern shown outside the bounded card (Hugo called this out). */
  --grid-line: rgba(10, 10, 10, 0.035);
  --grid-size: 84px;

  /* Spacing — one ruler for every gap, margin, and pad */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 22px;
  --space-6: 30px;
  --space-7: 42px;
  --space-8: 58px;
  --space-9: 84px;
  --card-pad: clamp(24px, 3.4vw, 36px);

  /* Type ramp — smaller, tighter. Body 14, labels 10 tracked, display numbers */
  --fs-display: clamp(30px, 3.6vw, 44px);
  --fs-h2: clamp(19px, 1.9vw, 23px);
  --fs-h3: 16px;
  --fs-body: 14px;
  --fs-small: 13px;
  --fs-meta: 12px;
  --fs-label: 10px;
  --lh-body: 1.62;

  --radius-lg: 4px;
  --radius-md: 3px;
  --radius-sm: 3px;
  --shadow: 0 18px 50px rgba(10, 10, 10, 0.05);
  --shadow-frame: 0 24px 70px rgba(10, 10, 10, 0.08);
  /* Kept as --serif to avoid a needless component refactor; it now carries
     the approved display face across every existing heading and number. */
  --serif: 'Bricolage Grotesque', -apple-system, BlinkMacSystemFont, sans-serif;
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  /* The grid pattern lives on the page itself, so it shows around the frame. */
  background:
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px),
    linear-gradient(180deg, var(--grid-line) 1px, transparent 1px),
    var(--page);
  background-size: var(--grid-size) var(--grid-size);
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
}

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

/* ---- Small-caps label, the connective tissue of the whole system --------- */
.eyebrow,
.section-kicker,
.ad-kicker,
.metric-label,
.stat-label,
.ad-stat-label,
.mini-label,
.summary dt,
.carryover .co-label,
.chip,
.side-nav a,
.nav-link,
label {
  font-family: var(--sans);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

/* ---- Keyboard focus ------------------------------------------------------
   One visible treatment for every interactive element. Electric violet is
   reserved for this high-value interaction cue and a small number of links.
   The paired white ring keeps it visible on dark panels and black buttons.
   :focus-visible only, so a mouse click never draws the ring. */
:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 2px;
  box-shadow: 0 0 0 4px var(--surface);
}

/* ---- Buttons + inputs --------------------------------------------------- */
button,
a.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border: 1px solid var(--ink);
  border-radius: 0;
  background: var(--ink);
  color: var(--page);
  cursor: pointer;
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.22em;
  padding: 0 20px;
  text-decoration: none;
  text-transform: uppercase;
  transition:
    background 0.25s var(--ease),
    border-color 0.25s var(--ease),
    color 0.25s var(--ease),
    transform 0.25s var(--ease);
  white-space: nowrap;
}

button:hover,
a.button:hover {
  background: var(--ink-soft);
  border-color: var(--ink-soft);
  transform: translateY(-1px);
}

button:disabled {
  cursor: default;
  opacity: 0.55;
  transform: none;
}

/* Legible plus on the launch buttons — an inline SVG, not the thin glyph. */
.btn-plus {
  flex: none;
  width: 13px;
  height: 13px;
  margin-right: 9px;
}

input,
select,
textarea {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line-input);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--ink);
  font-size: var(--fs-body);
  padding: 0 15px;
  outline: 0;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

textarea {
  padding: 12px 15px;
  line-height: var(--lh-body);
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

label {
  display: block;
  color: var(--muted);
  margin-bottom: var(--space-3);
}

/* =========================================================================
   APP FRAME — the bounded card that sits on the grid pattern
   ========================================================================= */
.shell {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  padding: clamp(16px, 3vw, 34px);
}

.app-frame {
  width: min(1420px, 100%);
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-frame);
}

.product-shell {
  display: grid;
  grid-template-columns: 236px minmax(0, 1fr);
  min-height: min(880px, calc(100vh - 120px));
}

/* ---- Sidebar ------------------------------------------------------------ */
.side-nav {
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--line);
  background: var(--surface-raise);
}

.side-logo {
  display: flex;
  align-items: center;
  height: 74px;
  padding: 0 22px;
  border-bottom: 1px solid var(--line);
}

.side-logo img {
  width: 132px;
  height: auto;
}

/* ---- The off-canvas menu ------------------------------------------------
   Ruling 7/30 (audit #4, reworked): below 960px the destinations move behind a
   hamburger and open as an off-canvas drawer, replacing the horizontal tab
   scroller. The scroller's problem was structural — the strip could only ever
   show two or three destinations, so "is there more?" was a question the agent
   had to answer by guessing they could swipe. A menu button asks nothing.
   Everything from here to the responsive block is desktop-neutral: the drawer
   is a plain flex column that leaves the 236px rail exactly as it was, and the
   button and scrim are display:none until the breakpoint. */
.side-drawer {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
}

.nav-toggle,
.nav-scrim,
.drawer-head {
  display: none;
}

/* nav.js sets this only while the drawer is open, so the page behind the panel
   cannot scroll out from under it. */
body.nav-open {
  overflow: hidden;
}

.side-nav nav {
  display: grid;
  gap: var(--space-2);
  padding: var(--space-6) var(--space-4);
}

/* Scoped to nav links only. The logo is ALSO an <a> inside .side-nav; if this
   selector caught it, its higher specificity (.side-nav a beats .side-logo)
   forced the logo into the 18px icon grid track and the global img max-width
   clamped the wordmark to ~18px. Scoping to `nav a` leaves the logo alone. */
.side-nav nav a {
  display: grid;
  grid-template-columns: 18px 1fr;
  gap: var(--space-3);
  align-items: center;
  min-height: 44px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  padding: 11px 12px;
  color: var(--muted);
  letter-spacing: 0.14em;
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.side-nav nav a:hover {
  color: var(--ink);
  border-color: var(--line-soft);
}

.side-nav nav a.is-active {
  border-color: var(--line);
  background: var(--page-deep);
  color: var(--ink);
}

/* Ruling 7/30 (audit #13, held): the rail icons stay. Hugo looked at the
   typography-only rail and kept the marks. */
.nav-icon {
  width: 15px;
  height: 15px;
  border: 1.5px solid currentColor;
  border-radius: 2px;
}

/* Ruling 7/30 (audit #17, custom): the standing conifer dot next to Brand Ads
   is replaced by a thin violet underline. Lime marks a real, new state — Sam's
   published review still wears it — so a permanent invitation gets the quieter
   inline accent instead.
   justify-self keeps the rule the width of the words: .nav-label sits in the
   second grid track of .side-nav nav a and would otherwise stretch, drawing the
   underline across the empty rail to the right of the label. */
.nav-flag {
  justify-self: start;
  padding-bottom: 2px;
  border-bottom: 2px solid var(--accent);
}

/* Sidebar bottom: one simple Sign out control, one line. No agent name, no
   region, no "signed in as". */
.side-card {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  margin: auto var(--space-4) var(--space-5);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--page-low);
  padding: var(--space-4);
}

.side-signout {
  flex: none;
  display: inline-block;
  color: var(--muted);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.side-signout:hover {
  color: var(--accent);
  border-color: var(--accent-line);
}

/* ---- Main column + topbar ---------------------------------------------- */
.main {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--page-low);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 12;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--space-4);
  align-items: center;
  min-height: 74px;
  padding: var(--space-3) clamp(18px, 2.5vw, 26px);
  border-bottom: 1px solid var(--line);
  background: var(--surface-raise);
}

.topbar-lead {
  min-width: 0;
}

.search {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  width: min(420px, 100%);
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
  padding: 0 13px;
}

.search:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.search-mark {
  position: relative;
  flex: none;
  width: 13px;
  height: 13px;
  border: 2px solid var(--muted);
  border-radius: 50%;
}

.search-mark::after {
  content: "";
  position: absolute;
  right: -6px;
  bottom: -3px;
  width: 7px;
  height: 2px;
  background: var(--muted);
  transform: rotate(45deg);
}

.search input {
  min-height: 0;
  height: 42px;
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0;
}

.search input:focus {
  box-shadow: none;
}

.topbar-crumb {
  color: var(--muted);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  justify-self: end;
}

.topbar-back {
  color: var(--muted);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.2s ease;
}

.topbar-back:hover {
  color: var(--accent);
}

/* The topbar primary action: compact black pill, never full-width */
.topbar .button {
  min-height: 38px;
  padding: 0 16px;
}

.content {
  flex: 1;
  padding: clamp(24px, 3vw, 34px);
}

/* ---- Screen heading ----------------------------------------------------- */
.page-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--space-6);
  align-items: end;
  padding-bottom: var(--space-6);
  margin-bottom: var(--space-6);
  border-bottom: 1px solid var(--accent-line);
}

.page-head .eyebrow {
  color: var(--accent);
  margin-bottom: var(--space-4);
}

h1,
.page-title {
  color: var(--ink);
  font-family: var(--serif);
  font-size: var(--fs-display);
  font-weight: 400;
  letter-spacing: -0.012em;
  line-height: 1.05;
}

.lede {
  color: var(--ink-soft);
  font-family: var(--serif);
  font-size: clamp(17px, 1.5vw, 19px);
  line-height: 1.55;
  margin-top: var(--space-4);
  max-width: 52ch;
}

.page-head .lede {
  margin-top: var(--space-4);
  max-width: none;
}

/* Home subhead stays on one line at desktop; wraps naturally below. */
@media (min-width: 961px) {
  .home-lede {
    white-space: nowrap;
  }
}

.region-pill {
  align-self: end;
  color: var(--muted);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* ---- Page-head launch CTA (Overview's "+ Launch new listing") ----------- */
.page-head-cta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: var(--space-3);
}

.page-head-cta-eyebrow {
  max-width: 230px;
  color: var(--muted);
  font-family: var(--sans);
  font-size: var(--fs-meta);
  font-weight: 400;
  letter-spacing: normal;
  text-align: right;
  text-transform: none;
  line-height: 1.45;
}

/* =========================================================================
   STAT CARDS — Option A's five-up overview, real data
   ========================================================================= */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: var(--space-3);
  margin-bottom: var(--space-6);
}

.stat {
  display: flex;
  flex-direction: column;
  min-height: 128px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-raise);
  padding: var(--space-5) var(--space-4) var(--space-4);
}

.stat-label {
  color: var(--muted);
  letter-spacing: 0.15em;
}

.stat-value {
  margin-top: auto;
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(28px, 2.6vw, 36px);
  font-variant-numeric: tabular-nums;
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
}

.stat-value.is-quiet {
  color: var(--faint);
  font-size: clamp(19px, 1.9vw, 23px);
}

/* Reserve two lines so a longer caption (card 5) can't push its number higher
   than the others — every stat-value bottom-aligns on a common baseline. */
.stat-delta {
  margin-top: var(--space-3);
  min-height: 2.8em;
  color: var(--muted);
  font-size: var(--fs-meta);
  line-height: 1.4;
}

/* ---- Dashboard split: photo panel + insight rail ------------------------ */
.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 322px;
  gap: var(--space-4);
  align-items: start;
}

.panel {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-5) var(--space-5) var(--space-4);
  border-bottom: 1px solid var(--line-soft);
}

.panel-title {
  color: var(--ink);
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 500;
  letter-spacing: -0.01em;
}

.panel-note {
  margin-top: 2px;
  color: var(--muted);
  font-size: var(--fs-meta);
}

/* =========================================================================
   PHOTO-LED LISTING CARDS — "Active homes"
   ========================================================================= */
.listing-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
  padding: var(--space-4);
}

.listing-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-raise);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.listing-card:hover {
  border-color: var(--accent-line);
  box-shadow: 0 12px 30px rgba(10, 10, 10, 0.06);
}

.listing-card.featured {
  grid-column: 1 / -1;
  flex-direction: row;
}

.listing-photo {
  position: relative;
  width: 100%;
  height: 188px;
  background: var(--page-deep);
  overflow: hidden;
}

.listing-card.featured .listing-photo {
  width: 46%;
  height: auto;
  min-height: 260px;
  flex: none;
}

.listing-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Graceful photo-less fallback: an intentional monogram plate, not a broken box. */
.listing-photo.is-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px),
    linear-gradient(180deg, var(--grid-line) 1px, transparent 1px),
    var(--page-deep);
  background-size: 26px 26px;
}

.listing-photo .photo-fallback {
  font-family: var(--serif);
  font-size: 40px;
  font-weight: 500;
  color: var(--faint);
  letter-spacing: 0.04em;
}

.listing-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: var(--space-4);
  padding: var(--space-5);
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.chip {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--page-low);
  color: var(--muted);
  padding: 4px 9px;
  letter-spacing: 0.12em;
}

.chip.live {
  border-color: var(--live-line);
  background: var(--live-bg);
  color: var(--live);
}

.listing-card h4,
.listing-title {
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(19px, 2vw, 22px);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.1;
}

.mini-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-3);
  margin-top: auto;
  padding-top: var(--space-4);
  border-top: 1px solid var(--line-soft);
}

.mini-value {
  display: block;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 17px;
  font-variant-numeric: tabular-nums;
  line-height: 1.15;
}

.mini-value.is-quiet {
  color: var(--faint);
}

.mini-label {
  display: block;
  margin-top: var(--space-1);
  color: var(--muted);
  letter-spacing: 0.12em;
}

.card-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3);
}

/* =========================================================================
   SHARED SPOTLIGHT / WALL LISTING CARD — ui.js's listingCard(). Used on
   Overview (spotlight, large) and Listings (wall, regular grid).
   ========================================================================= */
.lc-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
}

/* Overview's spotlight cards: 1-2 listings, always full panel width (never
   sharing a 2-up grid the way the Listings wall does). */
.lc-stack {
  display: grid;
  gap: var(--space-4);
  padding: var(--space-4);
}

.lc {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-raise);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.lc:hover {
  border-color: var(--accent-line);
  box-shadow: 0 12px 30px rgba(10, 10, 10, 0.06);
}

.lc-photo {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  background: var(--page-deep);
  overflow: hidden;
  text-decoration: none;
}

.lc-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lc-photo.is-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px),
    linear-gradient(180deg, var(--grid-line) 1px, transparent 1px),
    var(--page-deep);
  background-size: 26px 26px;
}

.lc-monogram {
  font-family: var(--serif);
  font-size: 40px;
  font-weight: 500;
  color: var(--faint);
  letter-spacing: 0.04em;
}

.lc-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: var(--space-3);
  padding: var(--space-5);
}

.lc-eyebrow {
  color: var(--accent);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.lc-address {
  display: block;
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(19px, 2vw, 22px);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.15;
  text-decoration: none;
  overflow-wrap: anywhere;
}

a.lc-address:hover {
  color: var(--accent);
}

.lc-flight {
  color: var(--muted);
  font-size: var(--fs-meta);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.03em;
}

.lc-links {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--space-3) var(--space-5);
  margin-top: auto;
  padding-top: var(--space-3);
}

/* Open report is primary (underlined, ink); its per-listing view count rides
   right after it as a muted "· N views". */
.lc-report {
  display: inline-flex;
  align-items: baseline;
  gap: var(--space-2);
}

.lc-views {
  color: var(--muted);
  font-size: var(--fs-meta);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

/* Both links share one baseline (the anchor defaults to center, the <button>
   variant to flex-start — force baseline so the pair reads deliberate). */
.lc-links .text-link,
.lc-links button.text-link {
  align-self: baseline;
}

/* Update emails is the secondary link: same left-aligned baseline, quieter. */
.lc-links .text-link.is-secondary {
  color: var(--muted);
  border-bottom-color: var(--line);
}

.lc-links .text-link.is-secondary:hover {
  color: var(--accent);
  border-bottom-color: var(--accent-line);
}

.lc-renew {
  width: 100%;
  margin-top: var(--space-2);
}

.lc-quiet-link {
  color: var(--muted);
  font-size: var(--fs-meta);
}

/* Overview spotlight: 1-2 active listings, shown LARGE (row layout). */
.lc-spotlight {
  flex-direction: row;
}

.lc-spotlight .lc-photo {
  width: 42%;
  aspect-ratio: auto;
  min-height: 260px;
  flex: none;
}

.lc-spotlight .lc-body {
  justify-content: center;
}

.lc-spotlight .lc-address {
  font-size: clamp(24px, 2.6vw, 30px);
}

@media (max-width: 720px) {
  .lc-grid {
    grid-template-columns: 1fr;
  }

  .lc-spotlight {
    flex-direction: column;
  }

  .lc-spotlight .lc-photo {
    width: 100%;
    min-height: 0;
    aspect-ratio: 4 / 3;
  }
}

/* =========================================================================
   UPDATE-EMAILS MODAL
   ========================================================================= */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(10, 10, 10, 0.5);
  padding: var(--space-4);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.modal-overlay.open {
  opacity: 1;
}

.modal-card {
  width: min(440px, 100%);
  max-height: 88vh;
  overflow: auto;
  border: 1px solid var(--line);
  border-top: 2px solid var(--accent);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-frame);
  padding: clamp(22px, 4vw, 32px);
}

.modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-4);
  margin-bottom: var(--space-5);
}

.modal-eyebrow {
  color: var(--accent);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: var(--space-2);
}

.modal-title {
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(20px, 2.4vw, 25px);
  font-weight: 400;
  line-height: 1.15;
}

.modal-x {
  flex: none;
  width: 30px;
  height: 30px;
  min-height: 0;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: transparent;
  color: var(--muted);
  font-size: 16px;
  line-height: 1;
}

.modal-x:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--page);
  transform: none;
}

.modal-label {
  margin-bottom: var(--space-2);
}

.modal-readonly {
  background: var(--page-low);
  color: var(--muted);
  margin-bottom: var(--space-4);
  cursor: default;
}

.modal-help {
  color: var(--muted);
  font-size: var(--fs-small);
  line-height: 1.55;
  margin: var(--space-3) 0 var(--space-5);
}

.modal-card .button {
  width: 100%;
}

/* =========================================================================
   CUSTOM AUDIENCES
   ========================================================================= */
.audience-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
}

.audience-card {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-raise);
  padding: var(--space-5);
}

.audience-head {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}

.audience-thumb {
  flex: none;
  width: 64px;
  height: 64px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--page-deep);
}

.audience-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.audience-thumb.is-empty {
  display: flex;
  align-items: center;
  justify-content: center;
}

.audience-thumb .lc-monogram {
  font-size: 24px;
}

.audience-address {
  color: var(--ink);
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 500;
  line-height: 1.2;
}

.audience-approach {
  display: block;
  margin-top: var(--space-1);
  color: var(--accent);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

/* Readable confirmation of who this audience is, replacing the geo pills:
   one plain sentence the agent can read and instantly say "yes, that's them",
   with the load-bearing terms (places + buyer profile) in bold. */
.audience-confirm {
  color: var(--ink-soft);
  font-family: var(--serif);
  font-size: 16px;
  line-height: 1.55;
}

.audience-confirm strong {
  color: var(--ink);
  font-weight: 600;
}

.audience-card .button {
  width: 100%;
  margin-top: auto;
}

@media (max-width: 720px) {
  .audience-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================================
   INSIGHT RAIL — dark "Last week's top ad" showcase + cross-sell + change
   ========================================================================= */
.insight-stack {
  display: grid;
  gap: var(--space-4);
}

.insight {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-raise);
  padding: var(--space-5);
}

.insight .label,
.insight-label {
  display: block;
  color: var(--accent);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.insight h4 {
  margin-top: var(--space-3);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 500;
  line-height: 1.2;
}

/* The Top Ad and "Change something" cards are siblings: same eyebrow + display
   heading + body register. This gives the change card's CTA the same rhythm. */
.insight .button {
  margin-top: var(--space-5);
}

/* Top Ad byline: agent name + one supporting line, quiet on the dark card. */
.insight .insight-byline {
  margin-top: var(--space-2);
  color: var(--faint);
  font-family: var(--sans);
  font-size: var(--fs-meta);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.insight.dark .insight-byline {
  color: var(--page);
}

.insight p {
  margin-top: var(--space-3);
  color: var(--ink-soft);
  font-size: var(--fs-small);
  line-height: 1.55;
}

/* Dark showcase panel */
.insight.dark {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--surface);
}

.insight.dark .insight-label {
  color: var(--faint);
}

.insight.dark h4 {
  color: var(--surface);
}

.insight.dark p {
  color: var(--page);
}

.top-ad-photo {
  display: block;
  width: 100%;
  max-width: 240px;
  aspect-ratio: 300 / 250;
  margin-top: var(--space-4);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.04);
}

.top-ad-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.top-ad-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-3);
  margin-top: var(--space-5);
  padding-top: var(--space-4);
  border-top: 1px solid rgba(255, 255, 255, 0.16);
}

.top-ad-meta .mini-value {
  color: var(--surface);
}

.top-ad-meta .mini-label {
  color: var(--faint);
}

.insight.dark .empty-inline {
  margin-top: var(--space-4);
  color: var(--page);
  font-family: var(--serif);
  font-size: 15px;
  line-height: 1.5;
}

/* =========================================================================
   RECEIPTS
   ========================================================================= */
.receipt-list {
  display: grid;
  gap: var(--space-3);
}

.receipt {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--space-4);
  align-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
  padding: var(--space-4) var(--space-5);
}

.receipt strong {
  display: block;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 500;
  line-height: 1.15;
}

.receipt span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: var(--fs-meta);
}

/* =========================================================================
   SHARED CONTENT COMPONENTS — kept intact for history / change / flows
   ========================================================================= */
.section + .section {
  margin-top: var(--space-7);
}

aside .section + .section {
  margin-top: var(--space-6);
}

.section-head {
  margin-bottom: var(--space-5);
  padding-bottom: var(--space-4);
  border-bottom: 1px solid var(--line-soft);
}

.section-kicker {
  display: block;
  color: var(--accent);
  letter-spacing: 0.22em;
  margin-bottom: var(--space-3);
}

.section-title {
  color: var(--ink);
  font-family: var(--serif);
  font-size: var(--fs-h2);
  font-weight: 400;
  letter-spacing: -0.004em;
  line-height: 1.12;
  overflow-wrap: anywhere;
}

.section-note {
  color: var(--muted);
  font-size: var(--fs-meta);
  line-height: 1.5;
  margin-top: var(--space-2);
  overflow-wrap: anywhere;
}

/* ---- Ad rows as report stat blocks (history, recent, flow summaries) ---- */
.list {
  display: grid;
  gap: var(--space-4);
}

.ad-row {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
  padding: var(--space-6);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.ad-row:hover {
  border-color: var(--accent-line);
  box-shadow: 0 12px 30px rgba(10, 10, 10, 0.05);
}

.ad-kicker {
  color: var(--accent);
  letter-spacing: 0.18em;
}

.ad-title {
  margin-top: var(--space-2);
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(19px, 2vw, 22px);
  font-weight: 400;
  letter-spacing: -0.006em;
  line-height: 1.14;
}

.ad-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-5);
  margin-top: var(--space-5);
  padding-top: var(--space-5);
  border-top: 1px solid var(--line-soft);
}

.ad-stat {
  min-width: 0;
}

.ad-stat-value {
  color: var(--ink);
  font-family: var(--serif);
  font-size: 18px;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.ad-stat-value.is-empty {
  color: var(--faint);
}

.ad-stat-label {
  margin-top: var(--space-2);
  color: var(--muted);
  letter-spacing: 0.15em;
}

.ad-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-5);
}

/* Text link — the tracked underline from the kit */
.text-link {
  display: inline-flex;
  align-items: center;
  align-self: center;
  color: var(--ink);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.18em;
  padding: 0 2px 2px;
  border-bottom: 1px solid currentColor;
  text-decoration: none;
  text-transform: uppercase;
  transition: color 0.25s ease;
  white-space: nowrap;
}

.text-link:hover {
  color: var(--accent);
}

/* A <button class="text-link"> (the emails-modal trigger, etc.) must escape
   the tag-selector button reset above — same specificity, so it needs an
   explicit override here rather than relying on cascade order alone. */
button.text-link {
  min-height: 0;
  border: 0;
  background: transparent;
  padding: 0 2px 2px;
  justify-content: flex-start;
  align-self: flex-start;
}

button.text-link:hover {
  background: transparent;
  transform: none;
}

.quiet-button {
  background: transparent;
  border-color: var(--line);
  color: var(--ink);
}

.quiet-button:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--page);
}

/* ---- History by year ---------------------------------------------------- */
.year-block {
  margin-top: var(--space-7);
}

.year-block:first-of-type {
  margin-top: 0;
}

.year-label {
  position: sticky;
  top: 74px;
  z-index: 1;
  width: max-content;
  margin: 0 0 var(--space-4);
  padding: var(--space-2) 0;
  background: var(--page-low);
  color: var(--muted);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

/* ---- Sidebar cards / quick cards / announcements ------------------------ */
.quick-grid,
.announcement-grid {
  display: grid;
  gap: var(--space-4);
}

.quick-card,
.announcement {
  padding: var(--space-5);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-raise);
}

.quick-card h3,
.announcement h3 {
  color: var(--ink);
  font-family: var(--serif);
  font-size: var(--fs-h3);
  font-weight: 500;
  line-height: 1.2;
  margin-bottom: var(--space-3);
}

.quick-card p,
.announcement p {
  color: var(--ink-soft);
  font-size: var(--fs-small);
  line-height: 1.62;
}

.quick-card .button,
.quick-card .text-link,
.announcement .text-link {
  margin-top: var(--space-5);
}

.empty {
  padding: var(--space-6);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-raise);
  color: var(--ink-soft);
  font-family: var(--serif);
  font-size: var(--fs-h3);
  line-height: 1.5;
}

/* ---- Locked brand preview (listing-only cross-sell) — neutral, no yellow - */
.quick-card.locked {
  position: relative;
  background: var(--page-dim);
  border-style: dashed;
  color: var(--muted);
}

.quick-card.locked h3 {
  color: var(--ink-soft);
}

.quick-card.locked p {
  color: var(--muted);
}

.lock-badge {
  display: inline-block;
  margin-bottom: var(--space-3);
  color: var(--accent);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.see-more {
  margin-top: var(--space-5);
}

/* ---- Single-column flow (Request a change) ------------------------------ */
.flow-single {
  width: min(640px, 100%);
}

/* ---- Flow (Extend / Launch similar) ------------------------------------- */
.flow {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(320px, 0.6fr);
  gap: clamp(28px, 4vw, 52px);
  align-items: start;
}

.summary {
  border: 1px solid var(--line);
  border-top: 2px solid var(--accent);
  border-radius: var(--radius-sm);
  background: var(--surface-raise);
  padding: clamp(26px, 4vw, 36px);
}

.summary .eyebrow {
  color: var(--accent);
  margin-bottom: var(--space-4);
}

.summary h2 {
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 400;
  letter-spacing: -0.008em;
  line-height: 1.08;
}

.summary dl {
  margin-top: var(--space-6);
  border-top: 1px solid var(--line-soft);
}

.summary-row {
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr);
  gap: var(--space-4);
  align-items: baseline;
  padding: var(--space-4) 0;
  border-bottom: 1px solid var(--line-soft);
}

.summary dt {
  color: var(--muted);
  letter-spacing: 0.15em;
}

.summary dd {
  color: var(--ink-soft);
  font-family: var(--serif);
  font-size: 16px;
}

.form-panel {
  padding-top: var(--space-2);
}

.form-panel h2 {
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(20px, 2.2vw, 25px);
  font-weight: 400;
  letter-spacing: -0.004em;
  line-height: 1.12;
  margin-bottom: var(--space-6);
}

.carryover {
  display: grid;
  margin: 0 0 var(--space-5);
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line-soft);
}

.carryover li {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr);
  gap: var(--space-4);
  align-items: baseline;
  padding: var(--space-4) 0;
  border-bottom: 1px solid var(--line-soft);
}

.carryover .co-label {
  color: var(--muted);
  letter-spacing: 0.15em;
}

.carryover .co-value {
  color: var(--ink-soft);
  font-family: var(--serif);
  font-size: 16px;
  line-height: 1.4;
}

.field-stack {
  display: grid;
  gap: var(--space-5);
}

.fine-print {
  color: var(--muted);
  font-size: var(--fs-small);
  line-height: 1.62;
  margin-top: var(--space-5);
}

.form-panel button,
.form-panel .button {
  margin-top: var(--space-6);
}

.result {
  display: none;
  margin-top: var(--space-6);
  padding-top: var(--space-5);
  border-top: 1px solid var(--line-soft);
  color: var(--ink-soft);
  font-size: var(--fs-small);
}

.result.show {
  display: block;
}

.result.is-error {
  color: var(--accent);
}

/* ---- Copied-on-updates: card note + the emails flow list ---------------- */
.copied-note {
  color: var(--muted);
  font-size: var(--fs-meta);
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.ad-row .copied-note {
  margin-top: var(--space-4);
}

.copied-list {
  display: grid;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.copied-list .co-value {
  font-family: var(--serif);
  font-size: 16px;
  color: var(--ink-soft);
  overflow-wrap: anywhere;
}

.copied-list .co-value.is-empty {
  color: var(--faint);
}

.copied-list.saved {
  margin-top: var(--space-3);
}

.result input {
  margin: var(--space-3) 0;
  font-size: var(--fs-small);
}

.result .button {
  margin-top: var(--space-2);
}

/* ---- Search empty state ------------------------------------------------- */
.search-empty {
  display: none;
  margin-top: var(--space-5);
  padding: var(--space-6);
  border: 1px dashed var(--line);
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-family: var(--serif);
  font-size: var(--fs-h3);
}

.search-empty.show {
  display: block;
}

/* =========================================================================
   LOGIN — the private front door, centered on the grid pattern
   ========================================================================= */
.login-shell {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  padding: clamp(16px, 3vw, 34px);
}

.login-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(1420px, 100%);
  margin: 0 auto var(--space-6);
  padding: var(--space-2) 0;
}

.login-bar img {
  width: 104px;
  height: auto;
}

.login-bar span {
  color: var(--muted);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.hero-login {
  display: grid;
  flex: 1;
  place-items: center;
  padding: clamp(24px, 6vw, 64px) 0;
}

.login-inner {
  width: min(560px, 100%);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-frame);
  padding: clamp(34px, 6vw, 58px);
}

.eyebrow {
  color: var(--accent);
  letter-spacing: 0.22em;
}

.login-inner .eyebrow {
  margin-bottom: var(--space-5);
}

.login-form {
  display: grid;
  gap: var(--space-4);
  margin-top: var(--space-7);
  text-align: left;
}

.login-form .field {
  min-width: 0;
}

.notice {
  color: var(--muted);
  font-size: var(--fs-small);
  margin-top: var(--space-5);
  min-height: 20px;
}

.notice .notice-main {
  display: block;
  color: var(--ink-soft);
}

.notice .notice-sub {
  display: block;
  margin-top: var(--space-1);
  color: var(--faint);
  font-size: var(--fs-meta);
}

/* =========================================================================
   FOOTER — sits on the grid pattern, below the frame
   ========================================================================= */
.footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--space-3) var(--space-6);
  width: min(1420px, 100%);
  margin: var(--space-6) auto 0;
  padding: var(--space-6) clamp(8px, 2vw, 20px) var(--space-4);
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.02em;
}

.footer-link {
  color: var(--muted);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
  transition: color 0.25s ease, border-color 0.25s ease;
}

.footer-link:hover {
  color: var(--accent);
  border-color: var(--accent-line);
}

.loading {
  padding: var(--space-8) var(--space-6);
  color: var(--muted);
  font-family: var(--serif);
  font-size: var(--fs-h2);
}

/* ---- Reveal ------------------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.reveal.in {
  opacity: 1;
  transform: none;
}

/* =========================================================================
   RESPONSIVE
   ========================================================================= */
@media (max-width: 1180px) {
  .stat-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .dashboard-grid,
  .flow {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 960px) {
  /* Sidebar collapses into a single bar at the top of the frame: hugo on the
     left, Menu on the right, destinations behind it. */
  .product-shell {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .side-nav {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-3);
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .side-logo {
    height: auto;
    padding: var(--space-3) var(--space-4);
    border-bottom: 0;
    flex: none;
  }

  /* The button carries the word as well as the bars. This audience is not
     technical and the glyph alone is an assumption; "Menu" costs 40px and
     removes it. 44px minimum touch target (audit #4). */
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    gap: var(--space-3);
    flex: none;
    min-height: 44px;
    margin-right: var(--space-4);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: var(--surface);
    color: var(--ink);
    font-family: var(--sans);
    font-size: var(--fs-label);
    font-weight: 600;
    letter-spacing: 0.2em;
    padding: 0 var(--space-4);
    text-transform: uppercase;
    cursor: pointer;
  }

  .nav-toggle-bars,
  .nav-toggle-bars::before,
  .nav-toggle-bars::after {
    display: block;
    width: 16px;
    height: 2px;
    border-radius: 1px;
    background: currentColor;
  }

  .nav-toggle-bars {
    position: relative;
  }

  .nav-toggle-bars::before {
    content: "";
    position: absolute;
    top: -5px;
  }

  .nav-toggle-bars::after {
    content: "";
    position: absolute;
    top: 5px;
  }

  /* Fixed, not absolute: .app-frame clips with overflow:hidden, and a fixed box
     escapes that clip (no transformed ancestor sits above it), so the panel can
     run the full height of the viewport rather than the height of the frame. */
  .side-drawer {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 40;
    width: min(288px, 84vw);
    border-right: 1px solid var(--line);
    background: var(--surface-raise);
    box-shadow: var(--shadow-frame);
    overflow-y: auto;
    /* visibility is what takes the closed drawer out of the tab order — a
       translated panel is still focusable, so keyboard users would tab into an
       invisible menu. It transitions stepwise, so the slide-out still plays. */
    visibility: hidden;
    transform: translateX(-100%);
    transition:
      transform 0.28s var(--ease),
      visibility 0s linear 0.28s;
  }

  .side-nav.is-open .side-drawer {
    visibility: visible;
    transform: none;
    transition:
      transform 0.28s var(--ease),
      visibility 0s;
  }

  /* Kept in the layout and faded rather than toggled on display, so the wash
     can actually animate. pointer-events is what makes the closed scrim
     harmless: it covers the whole viewport at all times. */
  .nav-scrim {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 39;
    background: rgba(10, 10, 10, 0.42);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.28s var(--ease);
  }

  .side-nav.is-open .nav-scrim {
    opacity: 1;
    pointer-events: auto;
  }

  .drawer-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-3);
    min-height: 74px;
    border-bottom: 1px solid var(--line);
    padding: 0 var(--space-4) 0 var(--space-5);
  }

  .drawer-title {
    color: var(--muted);
    font-family: var(--sans);
    font-size: var(--fs-label);
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
  }

  .drawer-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--ink);
    font-size: 22px;
    line-height: 1;
    padding: 0;
    cursor: pointer;
  }

  .drawer-close:hover {
    background: var(--page-deep);
  }

  /* The drawer has room the tab strip never had, so the destinations get their
     full names on one line each and the current route keeps its filled field —
     "where am I" is answered by looking, not by scrolling (absorbs audit #15). */
  .side-nav nav {
    padding: var(--space-5) var(--space-4);
  }

  /* Sign out was hidden at this width because the tab strip had nowhere to put
     it. The drawer does. */
  .side-card {
    display: flex;
  }
}

@media (prefers-reduced-motion: reduce) {
  .side-drawer,
  .nav-scrim {
    transition: none;
  }
}

@media (max-width: 720px) {
  .stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .listing-card.featured {
    flex-direction: column;
  }

  .listing-card.featured .listing-photo {
    width: 100%;
    min-height: 0;
    height: 200px;
  }

  .page-head {
    grid-template-columns: 1fr;
    gap: var(--space-4);
  }

  .page-head-cta {
    align-items: flex-start;
  }

  .page-head-cta-eyebrow {
    max-width: none;
    text-align: left;
  }

  .region-pill {
    justify-self: start;
  }

  .topbar {
    grid-template-columns: 1fr;
    row-gap: var(--space-3);
    padding: var(--space-4) var(--space-4);
  }

  .search {
    width: 100%;
  }

  .topbar-actions {
    justify-self: start;
  }
}

@media (max-width: 520px) {
  .shell,
  .login-shell {
    padding: 10px;
  }

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

  .stat {
    min-height: 0;
    flex-direction: row;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--space-3);
  }

  .stat-value {
    margin-top: 0;
  }

  .stat-delta {
    display: none;
  }

  .ad-stats {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-4);
  }

  /* Actions go full width on a phone. The two chrome controls do not: the Menu
     button shares the top bar with the logo, and the drawer's close is a 44px
     square. Both are excluded here rather than fighting this rule with a wider
     selector of their own. */
  button:not(.text-link):not(.modal-x):not(.nav-toggle):not(.drawer-close),
  a.button {
    width: 100%;
  }

  .topbar .button {
    width: auto;
  }

  .summary-row,
  .carryover li {
    grid-template-columns: 1fr;
    gap: var(--space-1);
  }

  .footer {
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal {
    transition: none;
    opacity: 1;
    transform: none;
  }
}
</content>
