/* ─────────────────────────────────────────────────────────────
   Adnan K. — Quiet Luxury Design System
   Warm cream, near-black, restrained terracotta.
   Typography is defined once in typography.css; the original wordmark is preserved here.
   ───────────────────────────────────────────────────────────── */

:root {
  /* ─── Quiet Luxury palette ─── */
  --bg:        #F4F0EA;          /* warm cream */
  --bg-soft:   #ECE7DE;          /* secondary surface (warmer cream) */
  --surface:   #FBF8F2;          /* lightest paper */
  --ink:       #1A1612;          /* warm near-black */
  --ink-soft:  #2A241E;
  --muted:     #6C6258;          /* warm muted */
  --muted-2:   #9C9286;
  --line:      #D9D2C4;          /* warm hairline */
  --line-soft: #E5DFD0;

  /* Terracotta — used SPARINGLY. Most pages should have ZERO. */
  --accent:        #8B3A1F;
  --accent-deep:   #6F2C16;
  --accent-soft:   #F0E4DC;
  --accent-hover:  #9F4528;

  /* Rare-use secondary */
  --green:     #5E7A4A;          /* muted olive for verified ticks */
  --gold:      #B08A4A;          /* muted ochre for review stars */

  /* ─── Type ─── */

  /* ─── Geometry — sharper, less rounded ─── */
  --r-sm: 2px;
  --r-md: 4px;
  --r-lg: 6px;
  --r-xl: 10px;

  --shadow-soft: 0 1px 0 rgba(26,22,18,0.04), 0 8px 24px -14px rgba(26,22,18,0.10);
  --shadow-card: 0 1px 2px rgba(26,22,18,0.04), 0 20px 48px -28px rgba(26,22,18,0.16);
  --shadow-pop:  0 1px 2px rgba(26,22,18,0.06), 0 30px 60px -22px rgba(139,58,31,0.18);
}
@media (max-width: 560px) {
  .buyer-assurance-row {
    grid-template-columns: 1fr !important;
    gap: 0.7rem !important;
  }
  .buyer-assurance-row p:first-child {
    letter-spacing: 0.2em !important;
  }
  .buyer-assurance-row p:last-child {
    font-size: 1rem !important;
    line-height: 1.58 !important;
  }
}

.home-page {

  }

/* ── Base ── */
*, *::before, *::after { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
  -webkit-text-size-adjust: 100%;
  max-width: 100%;
  overflow-x: hidden;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-serif);
  font-size: 17px;
  line-height: 1.7;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-synthesis:weight style;
  font-feature-settings: "ss01", "ss02";
  max-width: 100%;
  overflow-x: hidden;
}

.skip-link {
  position: fixed;
  z-index: 1000;
  top: 0.75rem;
  left: 0.75rem;
  transform: translateY(-160%);
  padding: 0.7rem 1rem;
  border-radius: 4px;
  background: #0f0c09;
  color: #fff;
  font: 600 0.85rem/1 var(--font-sans);
  transition: transform 0.18s ease;
}
.skip-link:focus { transform: translateY(0); }

img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
::selection { background: var(--ink); color: var(--bg); }

/* ── Typography ── */
.font-display {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0;
}
.font-serif { font-family: var(--font-serif); font-weight: 400; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  font-size: 0.7rem; font-weight: 500;
  text-transform: uppercase; letter-spacing: 0.22em;
  color: var(--muted);
  font-family: var(--font-sans);
}
.eyebrow::before {
  content: ""; width: 22px; height: 1px; background: var(--muted);
}

.serif { font-family: var(--font-editorial); font-weight: 500; }
/* Italic accent — serif italic for editorial punch, NOT colored */
.italic-serif {
  font-family: var(--font-editorial);
  font-style: italic;
  font-weight: 500;
  color: inherit;
}

/* Display heading scale */
.h-display {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.4rem, 6.4vw, 5.6rem);
  line-height: 0.98;
  letter-spacing: -0.015em;
  color: var(--ink);
  text-wrap: balance;
  overflow-wrap: break-word;
}
.h-1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.9rem, 4.4vw, 3.6rem);
  line-height: 1.02;
  letter-spacing: -0.015em;
  text-wrap: balance;
  overflow-wrap: break-word;
}
.h-2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.4rem, 2.6vw, 2rem);
  line-height: 1.12;
  letter-spacing: -0.012em;
  text-wrap: pretty;
}
.h-3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.08rem;
  line-height: 1.35;
  letter-spacing: -0.012em;
}

/* Lead paragraph — serif, generous */
.lead {
  font-family: var(--font-serif);
  font-size: clamp(1.08rem, 1.3vw, 1.22rem);
  color: var(--ink-soft);
  line-height: 1.65;
  letter-spacing: -0.005em;
  font-weight: 400;
  max-width: 60ch;
}

.prose {
  font-family: var(--font-serif);
  font-size: 1.08rem;
  line-height: 1.75;
  color: var(--ink-soft);
  max-width: 62ch;
}
.prose p { margin: 0 0 1.2em; }
.prose p:last-child { margin-bottom: 0; }
.prose em { font-style: italic; }
.prose strong { font-weight: 600; color: var(--ink); }

.eyebrow-rule {
  display: flex; align-items: center; gap: 14px;
  font-size: 0.7rem; font-weight: 500;
  text-transform: uppercase; letter-spacing: 0.2em;
  color: var(--muted);
  font-family: var(--font-sans);
}
.eyebrow-rule::before, .eyebrow-rule::after {
  content: ""; flex: 1; height: 1px; background: var(--line);
}

/* ── Layout ── */
.container { max-width: 1280px; margin: 0 auto; padding: 0 2rem; }
.container-narrow { max-width: 880px; margin: 0 auto; padding: 0 2rem; }
.container-tight { max-width: 680px; margin: 0 auto; padding: 0 2rem; }
.section { padding: 6rem 0; }
.section-sm { padding: 4rem 0; }
.section-lg { padding: 7rem 0; }
@media (max-width: 768px) {
  .container, .container-narrow, .container-tight { padding: 0 1.4rem; }
  .section, .section-lg { padding: 4.5rem 0; }
  .section-sm { padding: 3rem 0; }
}

/* ── Buttons — restrained editorial ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 0.9rem 1.5rem;
  border-radius: var(--r-md);
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 0.92rem;
  letter-spacing: -0.005em;
  transition: transform .2s ease, background .25s ease, color .25s ease, border-color .25s ease, box-shadow .25s ease;
  white-space: nowrap;
  position: relative;
  isolation: isolate;
}
.btn-primary {
  background: var(--ink); color: var(--bg);
}
.btn-primary:hover {
  background: var(--ink-soft);
  transform: translateY(-1px);
}

/* Editorial text-link with underline-swipe */
.btn-editorial {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0.4rem 0 0.6rem;
  color: var(--ink);
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: -0.005em;
  position: relative;
  transition: gap .35s cubic-bezier(.2,.7,.2,1);
}
.btn-editorial::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px; background: var(--ink);
  transform-origin: left;
  transition: transform .45s cubic-bezier(.2,.7,.2,1);
}
.btn-editorial:hover { gap: 14px; color: var(--ink); }
.btn-editorial:hover::after { animation: linkSwipe .8s cubic-bezier(.2,.7,.2,1); }
@keyframes linkSwipe {
  0%   { transform: scaleX(1); transform-origin: right; }
  49%  { transform: scaleX(0); transform-origin: right; }
  50%  { transform: scaleX(0); transform-origin: left; }
  100% { transform: scaleX(1); transform-origin: left; }
}

.btn-accent {
  background: var(--accent); color: var(--bg);
}
.btn-accent:hover { background: var(--accent-hover); transform: translateY(-1px); }

.btn-ghost {
  background: transparent; color: var(--ink);
  border: 1px solid var(--ink);
}
.btn-ghost:hover {
  background: var(--ink);
  color: var(--bg);
}

.btn-link {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--ink);
  font-weight: 500;
  font-size: 0.92rem;
  font-family: var(--font-sans);
  position: relative;
  letter-spacing: -0.005em;
  padding-bottom: 2px;
}
.btn-link::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px; background: currentColor;
  transform: scaleX(1); transform-origin: left;
  transition: transform .35s cubic-bezier(.2,.7,.2,1);
  opacity: 0.4;
}
.btn-link:hover::after { opacity: 1; }

/* ── Cards ── */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 2rem;
  transition: border-color .25s ease, transform .25s ease, box-shadow .25s ease;
}
.card:hover {
  border-color: var(--ink);
  box-shadow: var(--shadow-soft);
}
.card-static {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg); padding: 2rem;
}

/* ── Nav — restrained, no capsule, sits flush with type ── */

body { padding-top: 76px; }

.nav-bar {
  position: fixed;
  top: 0;
  left: 0; right: 0;
  z-index: 60;
  background: rgba(244, 240, 234, 0.78);
  backdrop-filter: saturate(160%) blur(18px);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
  border-bottom: 1px solid transparent;
  transition: background .3s ease, border-color .3s ease;
}
.nav-bar.scrolled {
  background: rgba(244, 240, 234, 0.94);
  border-bottom-color: var(--line);
}

.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 76px;
  padding: 0 2rem;
  max-width: 1400px;
  margin: 0 auto;
}

.nav-logo {
  font-family: var(--font-logo);
  font-size: 1.32rem;
  font-weight: 500;
  font-style: italic;
  letter-spacing: -0.02em;
  color: var(--ink);
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0;
  line-height: 1;
  transition: opacity .2s;
  padding-bottom: 2px;
}
.nav-logo:hover { opacity: 0.7; }
.nav-logo::after {
  content: "";
  display: inline-block;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--accent);
  margin-left: 5px;
  align-self: center;
  transform: translateY(-2px);
}
.nav-logo .dot {
  display: inline-block;
  font-family: var(--font-sans);
  font-style: normal;
  font-weight: 500;
  font-size: 0.5rem;
  letter-spacing: 0.42em;
  color: var(--muted);
  text-transform: uppercase;
  margin-left: 0.42rem;
  transform: translateY(-1px);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav-link {
  position: relative;
  font-family: var(--font-sans);
  font-size: 0.84rem;
  font-weight: 500;
  letter-spacing: 0.005em;
  color: var(--ink-soft);
  padding: 0.5rem 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: color .2s ease;
  background: transparent;
  border: 0;
  cursor: pointer;
}
.nav-link::after {
  content: '';
  position: absolute;
  left: 0.9rem;
  right: 0.9rem;
  bottom: 0.36rem;
  height: 1px;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform .42s cubic-bezier(.2,.7,.2,1);
}
.nav-link:hover { color: var(--ink); }
.nav-link:hover::after,
.nav-link[aria-expanded="true"]::after { transform: scaleX(1); }
.nav-link[aria-expanded="true"] { color: var(--ink); }

.nav-link svg {
  transition: transform .4s cubic-bezier(.2,.7,.2,1);
  opacity: 0.5;
}
.nav-link:hover svg { opacity: 1; }
.nav-link[aria-expanded="true"] svg {
  transform: rotate(180deg);
  opacity: 1;
}

/* Nav CTA group — keeps Free Audit + Get in touch together on the right */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

/* Free Audit button in nav */
.btn-audit {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.55rem 1.1rem !important;
  font-size: 0.82rem !important;
  font-weight: 600;
  font-family: var(--font-sans);
  letter-spacing: 0.005em;
  border-radius: var(--r-md) !important;
  background: transparent;
  color: var(--accent);
  border: 1.5px solid var(--accent);
  text-decoration: none;
  transition: background .18s, color .18s;
  white-space: nowrap;
}
.btn-audit:hover { background: var(--accent); color: var(--bg); }

/* Free Audit link in mobile panel */
.mobile-panel a.btn-audit-mobile {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin: 0.5rem 1.25rem 0;
  padding: 0.8rem 1.25rem;
  border-radius: 10px;
  border: 1.5px solid var(--accent);
  background: transparent;
  color: var(--accent);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition: background .18s, color .18s;
}
.mobile-panel a.btn-audit-mobile:hover { background: var(--accent); color: var(--bg); }

/* Primary CTA in the nav */
.nav-bar .btn-primary {
  padding: 0.55rem 1.15rem !important;
  font-size: 0.82rem !important;
  font-weight: 500;
  letter-spacing: 0.005em;
  border-radius: var(--r-md) !important;
}

/* ── Mega menu ── */
.mega-wrap { position: relative; }
.mega-wrap::after {
  content: '';
  position: absolute;
  top: 100%;
  left: -20px;
  right: -20px;
  height: 22px;
  pointer-events: none;
}
.mega-wrap:hover::after,
.mega-wrap:focus-within::after { pointer-events: auto; }

.mega {
  position: fixed;
  top: 86px;
  left: 50%;
  transform: translateX(-50%) translateY(-6px);
  width: min(1080px, 94vw);
  max-width: calc(100vw - 1.5rem);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-card);
  padding: 1.75rem;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1.15fr;
  gap: 1.25rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity .22s cubic-bezier(.2,.7,.2,1), transform .25s cubic-bezier(.2,.7,.2,1);
  z-index: 65;
}
@media (max-width: 1000px) { .mega { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px)  { .mega { grid-template-columns: 1fr; } }
.mega-wrap:hover .mega,
.mega-wrap:focus-within .mega,
.mega.open {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}
.mega-col h4 {
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted);
  margin: 0 0 1rem;
}
.mega-link {
  display: block;
  padding: 0.7rem 0.85rem;
  margin: 0 -0.85rem;
  border-radius: var(--r-md);
  transition: background .15s;
}
.mega-link:hover { background: var(--bg-soft); }
.mega-link-title {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 1.05rem;
  color: var(--ink);
  line-height: 1.25;
  letter-spacing: -0.01em;
}
.mega-link-desc {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 4px;
}
.mega-feature {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 1.4rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.mega-feature .tag {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.66rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.18em;
  color: var(--muted);
}

/* ── Mobile menu button (hamburger) ── */
.menu-btn { display: none; }

/* ════════════════════════════════════════════════════════════
   FULL-SCREEN MOBILE NAV OVERLAY (.mnav)
   ════════════════════════════════════════════════════════════ */
.mnav {
  display: none; /* shown only via media query */
  position: fixed;
  top: 0; right: 0; bottom: 0; left: 0;
  inset: 0;
  width: 100%; height: 100%;
  z-index: 1000;
  background: #1a1612;
  transform: translateX(100%);
  transition: transform .46s cubic-bezier(.76,0,.24,1);
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  will-change: transform;
}
.mnav.open {
  transform: translateX(0);
}
#mobilePanel.open {
  transform: translateX(0);
}

.mnav-inner {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  min-height: 100dvh;
  padding: 0 1.5rem calc(2rem + env(safe-area-inset-bottom, 0px));
}

/* Top bar */
.mnav-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  flex-shrink: 0;
  border-bottom: 1px solid rgba(255,255,255,.08);
  margin-bottom: 2rem;
}
.mnav-logo {
  font-family: var(--font-logo);
  font-size: 1.15rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  color: rgba(244,240,234,.92);
  text-decoration: none;
}
.mnav-logo span {
  font-family: var(--font-sans);
  font-size: 0.62rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: rgba(244,240,234,.45);
  margin-left: 4px;
}
.mnav-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px; height: 42px;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 10px;
  background: transparent;
  color: rgba(244,240,234,.8);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  transition: background .15s, color .15s;
}
.mnav-close:hover { background: rgba(255,255,255,.08); color: #f4f0ea; }

/* Primary nav links */
.mnav-primary {
  display: flex;
  flex-direction: column;
  gap: 0;
  flex: 1;
  margin-bottom: 2.5rem;
}
.mnav-link {
  position: relative;
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  padding: 1rem 0;
  border-bottom: 1px solid rgba(255,255,255,.06);
  text-decoration: none;
  color: rgba(244,240,234,.88);
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1.7rem, 6vw, 2.2rem);
  font-weight: 400;
  letter-spacing: -0.025em;
  transition: color .2s ease;
  -webkit-tap-highlight-color: transparent;
}
.mnav-link::before {
  content: attr(data-num);
  font-family: var(--font-sans);
  font-style: normal;
  font-size: 0.6rem;
  font-weight: 500;
  color: rgba(244,240,234,.3);
  letter-spacing: 0.1em;
  line-height: 1;
  align-self: center;
  margin-top: 2px;
}
.mnav-link:hover,
.mnav-link:focus { color: #f4f0ea; }
.mnav-link:hover::after {
  content: '→';
  position: absolute;
  right: 0;
  font-style: normal;
  font-size: 1rem;
  color: rgba(244,240,234,.4);
}

/* Services mini-grid */
.mnav-services {
  margin-bottom: 2rem;
}
.mnav-label {
  font-family: var(--font-sans);
  font-size: 0.62rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: rgba(244,240,234,.3);
  margin: 0 0 0.9rem;
}
.mnav-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}
.mnav-grid a {
  display: block;
  padding: 0.65rem 0;
  border-bottom: 1px solid rgba(255,255,255,.05);
  color: rgba(244,240,234,.55);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 500;
  text-decoration: none;
  transition: color .15s;
  -webkit-tap-highlight-color: transparent;
}
.mnav-grid a:nth-child(odd)  { padding-right: 1rem; border-right: 1px solid rgba(255,255,255,.08); }
.mnav-grid a:nth-child(even) { padding-left: 1rem; }
.mnav-grid a:hover, .mnav-grid a:focus { color: rgba(244,240,234,.9); }

/* Free Audit link */
.mnav-audit-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  padding: 0.75rem 1rem;
  border: 1px solid rgba(139,58,31,.5);
  border-radius: 10px;
  background: rgba(139,58,31,.1);
  color: #c8714a;
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: 0.01em;
  -webkit-tap-highlight-color: transparent;
  transition: background .15s, border-color .15s;
}
.mnav-audit-link:hover { background: rgba(139,58,31,.18); border-color: rgba(139,58,31,.7); }

/* Footer CTA */
.mnav-foot {
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,.08);
}
.mnav-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  width: 100%;
  padding: 1rem 1.5rem;
  background: rgba(244,240,234,.96);
  color: #1a1612;
  border-radius: 100px;
  font-family: var(--font-sans);
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-decoration: none;
  transition: background .2s;
  -webkit-tap-highlight-color: transparent;
}
.mnav-cta:hover { background: #f4f0ea; }
.mnav-meta {
  text-align: center;
  margin: 0.9rem 0 0;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  color: rgba(244,240,234,.25);
  letter-spacing: 0.05em;
}

/* Scroll lock — just overflow hidden, no position:fixed needed */
html.menu-lock,
body.menu-lock { overflow: hidden !important; }

@media (max-width: 880px) {
  html { scroll-padding-top: 64px; }
  body { padding-top: 64px; }
  .nav-links { display: none; }
  .nav-inner { height: 64px; padding: 0 1.25rem; }
  .menu-btn {
    display: inline-flex; align-items: center; justify-content: center;
    width: 44px; height: 44px;
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    background: transparent;
    color: var(--ink);
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
  }
  .nav-actions { display: none !important; }
  .mnav { display: block; }
  /* Tighten hero section inline padding on mobile */
  .paper { padding-top: 3rem !important; padding-bottom: 2.5rem !important; }
}

/* ── Footer ── */
.site-footer { border-top: 1px solid var(--line); padding: 5rem 0 2.5rem; background: var(--bg); }
.site-footer h5,
.site-footer .footer-label {
  font-family: var(--font-sans);
  font-size: 0.68rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.2em;
  color: var(--muted); margin: 0 0 1.25rem;
}
.site-footer a { color: var(--ink-soft); font-family: var(--font-sans); }
.site-footer a:hover { color: var(--ink); }
.site-footer a.btn-primary,
.site-footer a.btn-primary:hover {
  color: var(--bg);
}
.site-footer .meta { color: var(--muted); font-size: 0.85rem; font-family: var(--font-sans); }

/* ── Utility ── */
.divider { height: 1px; background: var(--line); border: 0; margin: 0; }
.tag-pill {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--font-sans);
  font-size: 0.72rem; font-weight: 500;
  padding: 4px 10px; border-radius: 100px;
  background: var(--bg-soft); color: var(--ink-soft);
  border: 1px solid var(--line);
  letter-spacing: 0.005em;
}
.kbd-pill {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--font-mono);
  font-size: 0.76rem; padding: 4px 10px;
  border-radius: var(--r-sm); background: var(--bg-soft); color: var(--ink-soft);
  border: 1px solid var(--line);
}

/* Big-number — display weight, tabular numerals.
   Constrained so it never overflows its grid column. */
.bignum {
  font-family: var(--font-display);
  font-size: clamp(2rem, 3vw, 2.8rem);
  line-height: 0.95;
  letter-spacing: -0.035em;
  font-weight: 500;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
  display: inline-flex;
  align-items: baseline;
  white-space: nowrap;
  max-width: 100%;
}
.bignum > span:not([data-count]) {
  margin-left: 1px;
  letter-spacing: 0;
}
.bignum-accent { color: var(--ink); }

/* Larger variant — for hero-style standalone stat blocks */
.bignum-xl {
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 4.2vw, 3.6rem);
  line-height: 0.95;
  letter-spacing: -0.04em;
  font-weight: 500;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
  display: inline-flex;
  align-items: baseline;
  white-space: nowrap;
  max-width: 100%;
}

/* ── Form — boxed fallback ── */
.form-field { margin-bottom: 1rem; }
.form-field label {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.7rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.18em;
  color: var(--muted); margin-bottom: 0.5rem;
}
.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  padding: 0.9rem 1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  font: inherit;
  color: var(--ink);
  transition: border-color .2s, box-shadow .2s;
  outline: none;
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(26,22,18,0.06);
}
.form-field textarea { min-height: 110px; resize: vertical; }

/* ── Editorial form — underline-only inputs ── */
.form-editorial {
  background: transparent;
  display: flex;
  flex-direction: column;
  gap: 2.2rem;
}
.form-editorial .form-field {
  margin: 0;
  position: relative;
}
.form-editorial label {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
  margin-bottom: 0.7rem;
}
.form-editorial input,
.form-editorial select,
.form-editorial textarea {
  width: 100%;
  padding: 0.5rem 0 0.85rem;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(1.1rem, 1.5vw, 1.3rem);
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--ink);
  outline: none;
  transition: border-bottom-color .35s ease;
  box-shadow: none;
}
.form-editorial input:focus,
.form-editorial select:focus,
.form-editorial textarea:focus {
  border-bottom-color: var(--ink);
  box-shadow: none;
}
.form-editorial input::placeholder,
.form-editorial textarea::placeholder {
  color: var(--muted-2);
  font-weight: 400;
  font-style: italic;
  letter-spacing: -0.005em;
}
.form-editorial select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%231A1612' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0 center;
  padding-right: 2rem;
  cursor: pointer;
}
.form-editorial textarea {
  min-height: 80px;
  resize: vertical;
}
.form-editorial button[type=submit] {
  width: 100%;
  padding: 1.15rem 1rem;
  background: var(--ink);
  color: var(--bg);
  border: 0;
  border-radius: var(--r-md);
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.005em;
  cursor: pointer;
  margin-top: 0.6rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: background .25s ease, transform .15s ease;
}
.form-editorial button[type=submit]:hover {
  background: var(--ink-soft);
  transform: translateY(-1px);
}

/* FAQ */
details.faq {
  border-bottom: 1px solid var(--line);
  padding: 1.6rem 0;
}
details.faq[open] summary { color: var(--ink); }
details.faq summary {
  list-style: none;
  cursor: pointer;
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.18rem;
  letter-spacing: -0.018em;
  color: var(--ink);
}
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary .plus {
  font-family: var(--font-sans);
  font-size: 1.4rem;
  color: var(--muted);
  font-weight: 300;
  transition: transform .25s;
}
details.faq[open] summary .plus { transform: rotate(45deg); color: var(--ink); }
details.faq .faq-body {
  padding-top: 0.85rem;
  color: var(--ink-soft);
  font-family: var(--font-serif);
  font-size: 1.05rem;
  line-height: 1.7;
  max-width: 60ch;
}

/* Subtle paper texture */
.paper {
  background-image:
    radial-gradient(circle at 18% 22%, rgba(139,58,31,0.018) 0, transparent 60%),
    radial-gradient(circle at 82% 78%, rgba(26,22,18,0.022) 0, transparent 60%);
}

/* Reveal animation */
[data-reveal] { opacity: 1; transform: none; transition: opacity .8s ease, transform .8s ease; }
[data-reveal].in { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1 !important; transform: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* ── Trust badges ── */
.trust-badges { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.trust-badge {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 5px 12px 5px 10px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 100px;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--ink-soft);
  letter-spacing: -0.005em;
  white-space: nowrap;
}
.trust-badge::before {
  content: "·";
  color: var(--accent);
  font-weight: 800;
  font-size: 1.2em;
  line-height: 1;
}

/* ── Word-stagger reveal ── */
.word-mask {
  display: inline-block;
  overflow: hidden;
  vertical-align: top;
  line-height: inherit;
  padding-bottom: 0.18em;
  margin-bottom: -0.18em;
}
.word {
  display: inline-block;
  line-height: inherit;
}
[data-split="words"] { visibility: hidden; }
[data-split="words"].split-done { visibility: visible; }
[data-split="words"].split-done .word {
  will-change: transform;
  animation: wordRise 1.15s cubic-bezier(.2,.7,.2,1) backwards;
  animation-delay: calc(var(--i, 0) * 0.05s + 0.08s);
}
@keyframes wordRise {
  from { transform: translateY(110%); }
  to   { transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  [data-split="words"] { visibility: visible !important; }
  [data-split="words"].split-done .word { animation: none; }
}

/* Counter — tabular numerals */
[data-count] { font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; }

/* Magnetic CTA */
[data-magnetic] { will-change: transform; }

/* Tilt card */
.tilt-card {
  transform-style: preserve-3d;
  transition: transform 0.45s cubic-bezier(.2,.7,.2,1), box-shadow 0.45s, border-color 0.3s;
  will-change: transform;
}
.tilt-card:hover {
  transform: perspective(1200px) rotateY(-1.2deg) rotateX(1.4deg) translateY(-4px);
  box-shadow: var(--shadow-card);
  border-color: var(--ink);
}
@media (prefers-reduced-motion: reduce) {
  .tilt-card:hover { transform: none; }
}

/* ── Brand Strip ── */
.brand-strip {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 2rem 0;
  background: var(--bg);
  overflow: hidden;
}
.brand-strip-label {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
  text-align: center;
  margin: 0 0 1.5rem;
}

/* Marquee ticker */
.brand-marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 8%, #000 92%, transparent 100%);
  mask-image: linear-gradient(to right, transparent 0%, #000 8%, #000 92%, transparent 100%);
}
.brand-marquee-track {
  display: flex;
  align-items: center;
  gap: 0;
  width: max-content;
  animation: marquee-scroll 32s linear infinite;
  will-change: transform;
}
.brand-marquee-track span {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1rem, 1.4vw, 1.3rem);
  letter-spacing: -0.015em;
  color: var(--ink-soft);
  white-space: nowrap;
  padding: 0 0.3rem;
  opacity: 0.65;
}
.brand-marquee-track .bm-sep {
  /* separator dots */
  opacity: 0.3;
  font-style: normal;
  font-size: 0.8em;
  padding: 0 0.6rem;
}
@keyframes marquee-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .brand-marquee-track { animation: none; }
}
/* Selected clients — static name strip */
.client-names {
  list-style: none; margin: 1.6rem auto 0; padding: 0 1.5rem;
  max-width: 1000px; display: flex; flex-wrap: wrap;
  justify-content: center; align-items: center; gap: 0.5rem 1.7rem;
}
.client-names li {
  font-family: var(--font-serif); font-style: italic;
  font-size: clamp(1rem, 1.4vw, 1.25rem); letter-spacing: -0.01em;
  color: var(--ink-soft); opacity: 0.62; white-space: nowrap; transition: opacity .2s;
}
.client-names li:hover { opacity: 1; }
@media (max-width: 640px) {
  .client-names { gap: 0.4rem 1.1rem; margin-top: 1.2rem; }
  .client-names li { font-size: 0.98rem; }
}

/* ── Editorial Case Studies ── */
.case-grid { display: grid; gap: 6rem; }
.case-study {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 3.5rem;
  align-items: center;
}
.case-study.flip { grid-template-columns: 1fr 1.1fr; }
.case-study.flip .case-image { order: 2; }
.case-study.flip .case-content { order: 1; }
@media (max-width: 880px) {
  .case-grid { gap: 4rem; }
  .case-study, .case-study.flip { grid-template-columns: 1fr; gap: 1.75rem; }
  .case-study.flip .case-image, .case-study.flip .case-content { order: initial; }
}
.case-image {
  position: relative;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--bg-soft);
  aspect-ratio: 16/11;
  transition: transform .6s cubic-bezier(.2,.7,.2,1);
  will-change: transform;
  border: 1px solid var(--line);
}
.case-image img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
  transition: transform .8s cubic-bezier(.2,.7,.2,1), opacity .5s ease;
  filter: saturate(0.95);
}
.case-study:hover .case-image img { transform: scale(1.025); filter: saturate(1); }
.case-screenshot-frame {
  width: 100%;
  max-width: min(100%, 1100px);
  margin-inline: auto;
  box-shadow: 0 28px 82px -60px rgba(26, 22, 18, 0.48);
}
.case-screenshot-frame a { display: block; }
.case-screenshot-img {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
  object-fit: contain;
  object-position: top center;
  filter: none;
  transform: none;
}
@media (max-width: 720px) {
  .case-screenshot-frame {
    max-width: 100%;
    border-radius: 14px !important;
  }
}
.case-tag {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
  margin-bottom: 1.4rem;
}
.case-name {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.9rem, 3.2vw, 2.8rem);
  line-height: 1.02;
  letter-spacing: -0.038em;
  color: var(--ink);
  margin: 0 0 1.1rem;
}
.case-desc {
  font-family: var(--font-serif);
  font-size: 1.08rem;
  line-height: 1.65;
  color: var(--ink-soft);
  max-width: 52ch;
  margin: 0 0 1.75rem;
}
.case-metric {
  padding: 1.4rem 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  margin: 0 0 1.9rem;
  display: flex;
  align-items: baseline;
  gap: 1.5rem;
  flex-wrap: wrap;
}
.case-metric .num {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.9rem, 2.8vw, 2.4rem);
  line-height: 1;
  letter-spacing: -0.038em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.case-metric .lbl {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  line-height: 1.4;
  color: var(--muted);
  max-width: 30ch;
}
.case-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 0.93rem;
  letter-spacing: -0.005em;
  color: var(--ink);
  padding: 0.3rem 0 0.6rem;
  position: relative;
  transition: gap .35s cubic-bezier(.2,.7,.2,1);
}
.case-link::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px; background: var(--ink);
  transform-origin: left;
  transition: transform .45s cubic-bezier(.2,.7,.2,1);
}
.case-link:hover { gap: 14px; }
.case-link:hover::after { animation: linkSwipe .8s cubic-bezier(.2,.7,.2,1); }

/* Reviews grid */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}
.review-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 2rem;
  display: flex; flex-direction: column;
  transition: border-color .25s, transform .35s cubic-bezier(.2,.7,.2,1);
}
.review-card:hover { border-color: var(--ink); transform: translateY(-3px); }
.review-stars {
  font-size: 0.95rem; letter-spacing: 4px; color: var(--gold);
  margin-bottom: 1.2rem; line-height: 1;
}
.review-body {
  font-family: var(--font-serif);
  font-size: 1.06rem;
  font-style: italic;
  line-height: 1.55;
  letter-spacing: -0.005em;
  color: var(--ink);
  flex: 1;
  margin: 0 0 1.5rem;
}
.review-meta { display: flex; align-items: center; gap: 0.75rem; padding-top: 1.4rem; border-top: 1px solid var(--line); }
.review-avatar {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--bg); color: var(--ink-soft);
  border: 1px solid var(--line);
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-sans);
  font-weight: 600; font-size: 0.78rem; flex-shrink: 0;
}
.review-meta-text { line-height: 1.4; font-family: var(--font-sans); }
.review-meta-name { font-weight: 600; font-size: 0.86rem; color: var(--ink); }
.review-meta-project { color: var(--muted); font-size: 0.78rem; }
.review-meta-badge {
  font-size: 0.68rem; color: var(--green); font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.16em;
  margin-top: 4px; display: block;
  font-family: var(--font-sans);
}

/* Client Feedback Insights */
.insights-band {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.insight-cell {
  padding: 2.4rem 1.6rem;
  border-right: 1px solid var(--line);
  display: flex; flex-direction: column; gap: 0.4rem;
  background: transparent;
  transition: background .25s;
}
.insight-cell:hover { background: var(--bg-soft); }
.insight-cell:last-child { border-right: 0; }
.insight-count {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(2.4rem, 4.2vw, 3.2rem);
  line-height: 0.95;
  letter-spacing: -0.045em;
  color: var(--ink);
}
.insight-trait {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.08rem;
  line-height: 1.25;
  letter-spacing: -0.008em;
  color: var(--ink);
  margin-top: 0.6rem;
}
.insight-sub {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--muted);
  margin-top: 0.3rem;
}
@media (max-width: 800px) {
  .insight-cell { border-right: 0; border-bottom: 1px solid var(--line); }
  .insight-cell:last-child { border-bottom: 0; }
}

/* ── Portfolio grid (small cards, ALL projects) ── */
.work-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  grid-auto-rows: 1fr;
  gap: 2rem;
}
.work-card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  overflow: hidden;
  transition: border-color .25s, transform .35s cubic-bezier(.2,.7,.2,1), box-shadow .35s;
}
.work-card:hover {
  border-color: var(--ink);
  transform: translateY(-4px);
  box-shadow: var(--shadow-soft);
}
.work-card-img {
  aspect-ratio: 4/3;
  flex: none;
  background: var(--bg-soft);
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}
.work-card-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: top center;
  filter: saturate(0.92);
  transition: filter .4s, transform .6s cubic-bezier(.2,.7,.2,1);
}
.work-card:hover .work-card-img img {
  filter: saturate(1);
  transform: scale(1.03);
}
.work-card-body { padding: 1.4rem 1.5rem 1.5rem; flex: 1 1 auto; display: flex; flex-direction: column; }
.work-card-meta {
  font-family: var(--font-sans);
  font-size: 0.66rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted);
  margin-bottom: 0.6rem;
}
.work-card-name {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.3rem;
  letter-spacing: -0.024em;
  color: var(--ink);
  line-height: 1.15;
  margin: 0 0 0.5rem;
}
.work-card-tag {
  font-family: var(--font-serif);
  font-size: 0.95rem;
  line-height: 1.45;
  color: var(--muted);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ── Pull statement ── */
.pullquote {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.5rem, 3vw, 2.4rem);
  line-height: 1.25;
  letter-spacing: -0.018em;
  color: var(--ink);
  max-width: 28ch;
  margin: 0;
}
.pullquote::before {
  content: '"';
  display: inline-block;
  font-size: 1.8em;
  line-height: 0;
  vertical-align: -0.35em;
  margin-right: 0.05em;
  color: var(--accent);
  font-style: normal;
}

/* ── Process page elements ── */
.phase-row {
  display: grid;
  grid-template-columns: 80px 1fr 1fr;
  gap: 3rem;
  padding: 4rem 0;
  border-bottom: 1px solid var(--line);
  align-items: start;
}
.phase-row:last-child { border-bottom: 0; }
.phase-num {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 2.4rem;
  letter-spacing: -0.02em;
  color: var(--accent);
  line-height: 1;
}
@media (max-width: 880px) {
  .phase-row { grid-template-columns: 1fr; gap: 1.25rem; padding: 2.5rem 0; }
  .phase-num { font-size: 1.8rem; }
}

/* ── Notes list ── */
.note-row {
  display: grid;
  grid-template-columns: 130px 1fr 80px;
  gap: 2rem;
  padding: 2rem 0;
  border-bottom: 1px solid var(--line);
  align-items: baseline;
  transition: padding-left .3s ease;
}
.note-row:hover { padding-left: 0.5rem; }
.note-row:last-child { border-bottom: 0; }
.note-date {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
}
.note-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.35rem;
  letter-spacing: -0.024em;
  color: var(--ink);
  line-height: 1.25;
}
.note-title em { font-family: var(--font-serif); font-weight: 400; font-style: italic; }
.note-time {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  color: var(--muted);
  text-align: right;
}
@media (max-width: 720px) {
  .note-row { grid-template-columns: 1fr; gap: 0.4rem; padding: 1.4rem 0; }
  .note-time { text-align: left; }
}

/* ── Now page card ── */
.now-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}
.now-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 1.8rem;
}
.now-card-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--muted);
  margin-bottom: 1rem;
}
.now-card-status::before {
  content: '';
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 3px rgba(94,122,74,0.18);
  animation: nowPulse 2.4s ease-in-out infinite;
}
@keyframes nowPulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(94,122,74,0.12); }
  50% { box-shadow: 0 0 0 5px rgba(94,122,74,0.06); }
}
.now-card-status.queued::before { background: var(--muted-2); animation: none; }
.now-card-status.shipped::before { background: var(--accent); animation: none; }

/* Print-marker — small decoration */
.print-mark {
  font-family: var(--font-serif);
  font-style: italic;
  color: var(--accent);
  margin: 0 0.1em;
}

/* Gold for review stars */
:root { --gold: #B08A4A; }

/* ─────────────────────────────────────────────────────────────
   Floating widgets — cookie, accessibility, WhatsApp, chatbot
   ───────────────────────────────────────────────────────────── */

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

.legal h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  letter-spacing: 0;
  margin: 2.5rem 0 0.75rem;
}
.legal h3 {
  font-size: 1rem;
  font-weight: 600;
  margin: 1.5rem 0 0.5rem;
}
.legal p,
.legal li {
  color: var(--ink-soft);
  line-height: 1.75;
}
.legal ul {
  padding-left: 1.25rem;
  margin: 0.5rem 0 1rem;
}
.legal li { margin-bottom: 0.4rem; }
.legal a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.legal .note {
  background: var(--accent-soft);
  border-left: 3px solid var(--accent);
  padding: 1rem 1.25rem;
  margin: 2rem 0;
  border-radius: 0 var(--r-md) var(--r-md) 0;
  font-size: 0.92rem;
  color: var(--ink);
}

/* ── Cookie banner ── */
.cookie-banner {
  position: fixed;
  bottom: 1rem; left: 1rem; right: 1rem;
  max-width: 720px;
  margin: 0 auto;
  z-index: 80;
  background: var(--ink);
  color: var(--bg);
  border-radius: var(--r-lg);
  box-shadow: 0 20px 60px -20px rgba(26,22,18,0.45), 0 1px 0 rgba(255,255,255,0.04) inset;
  transition: opacity .3s, transform .3s;
  opacity: 1;
  transform: translateY(0);
  font-family: var(--font-sans);
}
.cookie-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1.25rem;
  align-items: center;
  padding: 1rem 1.25rem;
}
.cookie-text {
  font-family: var(--font-serif);
  font-size: 0.93rem;
  line-height: 1.55;
  color: rgba(244,240,234,0.92);
  margin: 0;
  letter-spacing: -0.005em;
}
.cookie-text a { color: var(--bg); text-decoration: underline; text-underline-offset: 3px; }
.cookie-text a:hover { text-decoration-color: rgba(244,240,234,0.5); }
.cookie-actions { display: flex; gap: 0.5rem; flex-shrink: 0; }
.cookie-btn {
  padding: 0.55rem 1.05rem;
  border-radius: 100px;
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 500;
  border: 1px solid rgba(244,240,234,0.22);
  background: transparent;
  color: var(--bg);
  cursor: pointer;
  transition: background .2s, border-color .2s;
}
.cookie-decline:hover { border-color: rgba(244,240,234,0.45); }
.cookie-accept {
  background: var(--bg);
  color: var(--ink);
  border-color: var(--bg);
}
.cookie-accept:hover { background: rgba(244,240,234,0.88); }
@media (max-width: 640px) {
  .cookie-banner { bottom: 0.6rem; left: 0.6rem; right: 0.6rem; }
  .cookie-inner { grid-template-columns: 1fr auto; gap: 0.55rem; padding: 0.68rem 0.72rem; }
  .cookie-text { font-size: 0.74rem; line-height: 1.28; }
  .cookie-actions { justify-content: flex-end; gap: 0.35rem; }
  .cookie-btn { min-height: 34px; padding: 0.36rem 0.62rem; font-size: 0.72rem; }
}

/* ── Visitor-controlled accessibility preferences ── */
.a11y-launcher,
.wa-launcher {
  position: fixed;
  z-index: 74;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0.78rem 1.06rem;
  border-radius: 100px;
  font-family: var(--font-sans);
  font-size: 0.84rem;
  font-weight: 560;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 18px 48px -18px rgba(26,22,18,0.25), 0 1px 0 rgba(255,255,255,0.45) inset;
  transition: transform .24s cubic-bezier(.2,.7,.2,1), background .24s, color .24s, border-color .24s, opacity .24s;
}
.a11y-launcher {
  bottom: 1.5rem;
  left: 1.5rem;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line);
}
.a11y-launcher:hover {
  transform: translateY(-2px);
  border-color: var(--ink);
}
.a11y-panel {
  position: fixed;
  bottom: 5.6rem;
  left: 1.5rem;
  z-index: 78;
  width: min(362px, calc(100vw - 2rem));
  max-height: min(560px, calc(100svh - 7rem));
  overflow: auto;
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 30px 80px -28px rgba(26,22,18,0.32), 0 1px 0 rgba(255,255,255,0.52) inset;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px) scale(.98);
  transform-origin: bottom left;
  transition: opacity .26s cubic-bezier(.2,.7,.2,1), transform .26s cubic-bezier(.2,.7,.2,1);
}
.a11y-panel.open,
.a11y-panel[aria-hidden="false"] {
  opacity: 1 !important;
  pointer-events: auto;
  transform: translateY(0) scale(1) !important;
  transition: none;
}
.a11y-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1rem 0.85rem;
  border-bottom: 1px solid var(--line);
  background: var(--bg);
}
.a11y-kicker {
  margin: 0 0 0.25rem;
  font-family: var(--font-sans);
  font-size: 0.62rem;
  font-weight: 650;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}
.a11y-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 560;
  letter-spacing: 0;
}
.a11y-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.a11y-body {
  display: grid;
  gap: 0.55rem;
  padding: 0.9rem;
}
.a11y-option {
  min-height: 58px;
  text-align: left;
  display: grid;
  gap: 0.2rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
  color: var(--ink);
  padding: 0.75rem 0.86rem;
  cursor: pointer;
  transition: border-color .2s, background .2s, transform .2s;
}
.a11y-option:hover {
  border-color: var(--ink);
  transform: translateY(-1px);
}
.a11y-option span {
  font-family: var(--font-sans);
  font-size: 0.91rem;
  font-weight: 650;
}
.a11y-option small {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  line-height: 1.35;
  color: var(--muted);
}
.a11y-option[aria-pressed="true"] {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 9%, var(--bg));
}
.a11y-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 0.85rem 1rem 1rem;
  border-top: 1px solid var(--line-soft);
  font-family: var(--font-sans);
  font-size: 0.73rem;
}
.a11y-reset {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  font: inherit;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.a11y-foot a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.wa-launcher {
  bottom: 5.05rem;
  right: 1.5rem;
  color: #fffaf3;
  background: #175c3c;
  border: 1px solid rgba(255,255,255,0.14);
}
.wa-launcher:hover {
  transform: translateY(-2px);
  background: #124a31;
  color: #fffaf3;
}
.cookie-banner ~ .a11y-launcher { bottom: 5.5rem; }
.cookie-banner ~ .a11y-panel { bottom: 9.6rem; }
.cookie-banner ~ .wa-launcher { bottom: 9.05rem; }

/* ── Chat launcher button ── */
.chat-launcher {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 75;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0.85rem 1.2rem 0.85rem 1rem;
  border-radius: 100px;
  background: var(--ink);
  color: var(--bg);
  border: 0;
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 0.86rem;
  font-weight: 500;
  letter-spacing: -0.005em;
  box-shadow: 0 18px 48px -16px rgba(26,22,18,0.42), 0 1px 0 rgba(255,255,255,0.06) inset;
  transition: transform .25s cubic-bezier(.2,.7,.2,1), background .25s, box-shadow .25s, opacity .25s;
  position: fixed;
}
.chat-launcher:hover {
  background: var(--ink-soft);
  transform: translateY(-2px);
  box-shadow: 0 24px 60px -18px rgba(26,22,18,0.5);
}
.chat-launcher-label { white-space: nowrap; }
.chat-launcher-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #5E7A4A;
  box-shadow: 0 0 0 3px rgba(94,122,74,0.25);
  animation: chatPulse 2.4s ease-in-out infinite;
}
@keyframes chatPulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(94,122,74,0.22); }
  50% { box-shadow: 0 0 0 6px rgba(94,122,74,0.08); }
}
.chat-launcher-bump { animation: chatBump 0.7s ease-out 2; }
@keyframes chatBump {
  0% { transform: translateY(0) scale(1); }
  35% { transform: translateY(-6px) scale(1.04); }
  70% { transform: translateY(0) scale(1); }
  100% { transform: translateY(0) scale(1); }
}
.chat-launcher-open svg { transform: rotate(90deg); transition: transform .35s; }

@media (max-width: 640px) {
  .chat-launcher { bottom: 1rem; right: 1rem; padding: 0.8rem 1.05rem 0.8rem 0.95rem; }
  .chat-launcher-label { display: none; }
}

/* ── Chat panel ── */
.chat-panel {
  position: fixed;
  bottom: 5.25rem;
  right: 1.5rem;
  z-index: 76;
  width: min(380px, calc(100vw - 2rem));
  max-height: min(620px, calc(100vh - 7rem));
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 30px 80px -24px rgba(26,22,18,0.32), 0 1px 0 rgba(255,255,255,0.5) inset;
  display: flex;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px) scale(0.98);
  transform-origin: bottom right;
  transition: opacity .28s cubic-bezier(.2,.7,.2,1), transform .28s cubic-bezier(.2,.7,.2,1);
  overflow: hidden;
}
.chat-panel.open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}
@media (max-width: 640px) {
  .chat-panel {
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    max-height: 92svh;
    border-radius: 20px 20px 0 0;
    border: none;
    border-top: 1px solid var(--line);
    transform-origin: bottom center;
    transform: translateY(100%);
    box-shadow: 0 -8px 40px rgba(26,22,18,.18);
  }
  .chat-panel.open {
    transform: translateY(0) !important;
    opacity: 1 !important;
  }
  .chat-head {
    position: relative;
    padding-top: 1.75rem;
  }
  .chat-head::before {
    content: '';
    position: absolute;
    top: 0.7rem; left: 50%;
    transform: translateX(-50%);
    width: 36px; height: 4px;
    background: var(--line);
    border-radius: 100px;
  }
  .chat-log { max-height: 42svh; }
  .chat-launcher {
    bottom: calc(68px + env(safe-area-inset-bottom, 0px)) !important;
  }
}
.chat-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.1rem 1.25rem;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.chat-head-meta { display: flex; align-items: center; gap: 0.75rem; }
.chat-avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--bg);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.82rem;
  display: inline-flex; align-items: center; justify-content: center;
  letter-spacing: 0.5px;
}
.chat-name {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.95rem;
  margin: 0 0 2px;
  letter-spacing: -0.012em;
  color: var(--ink);
}
.chat-sub {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  color: var(--muted);
  margin: 0;
  display: flex; align-items: center; gap: 6px;
  letter-spacing: 0.005em;
}
.chat-pulse {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #5E7A4A;
  box-shadow: 0 0 0 2px rgba(94,122,74,0.25);
  animation: chatPulse 2.4s ease-in-out infinite;
}
.chat-close {
  width: 32px; height: 32px;
  display: inline-flex; align-items: center; justify-content: center;
  background: transparent;
  border: 0;
  border-radius: var(--r-md);
  color: var(--muted);
  cursor: pointer;
  transition: color .2s, background .2s;
}
.chat-close:hover { color: var(--ink); background: var(--bg-soft); }

.chat-log {
  flex: 1;
  overflow-y: auto;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  scroll-behavior: smooth;
}
.chat-msg {
  max-width: 84%;
  padding: 0.75rem 1rem;
  border-radius: 14px;
  font-family: var(--font-serif);
  font-size: 0.97rem;
  line-height: 1.55;
  letter-spacing: -0.005em;
  animation: chatMsgIn .35s cubic-bezier(.2,.7,.2,1) backwards;
}
@keyframes chatMsgIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
.chat-msg-assistant {
  align-self: flex-start;
  background: var(--bg);
  color: var(--ink);
  border: 1px solid var(--line);
  border-bottom-left-radius: 4px;
}
.chat-msg-user {
  align-self: flex-end;
  background: var(--ink);
  color: var(--bg);
  border-bottom-right-radius: 4px;
  font-family: var(--font-sans);
  font-size: 0.92rem;
}
.chat-msg-assistant a.chat-link,
.chat-msg-assistant a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.chat-typing {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 0.85rem 1rem;
}
.chat-typing span {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--muted-2);
  animation: chatTyping 1.2s ease-in-out infinite;
}
.chat-typing span:nth-child(2) { animation-delay: 0.15s; }
.chat-typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes chatTyping {
  0%, 60%, 100% { opacity: 0.3; transform: translateY(0); }
  30% { opacity: 1; transform: translateY(-3px); }
}

.chat-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 1.25rem 0.75rem;
}
.chat-chip {
  padding: 6px 12px;
  border-radius: 100px;
  background: var(--bg);
  border: 1px solid var(--line);
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--ink-soft);
  cursor: pointer;
  transition: border-color .2s, color .2s, background .2s;
  letter-spacing: 0.005em;
}
.chat-chip:hover {
  border-color: var(--ink);
  color: var(--ink);
  background: var(--bg-soft);
}

.chat-cta {
  margin: 0.25rem 0 0.5rem;
  padding: 1.2rem 1.25rem 1.25rem 1.4rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 2.5px solid var(--accent);
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.chat-cta-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.6rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--accent);
  margin: 0;
}
.chat-cta-text {
  font-family: var(--font-serif);
  font-size: 0.88rem;
  margin: 0;
  color: var(--ink);
  line-height: 1.55;
}
.chat-cta-actions { margin-top: 0.35rem; }
.chat-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0.58rem 1.1rem;
  border-radius: 100px;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 500;
  border: none;
  cursor: pointer;
  transition: background .2s, gap .25s cubic-bezier(.2,.7,.2,1);
}
.chat-cta-primary {
  background: var(--accent);
  color: #fff !important;
  text-decoration: none;
}
.chat-cta-primary:hover {
  background: #732f19;
  gap: 11px;
}

.chat-form {
  display: flex;
  gap: 8px;
  padding: 0.85rem 1rem;
  border-top: 1px solid var(--line);
  background: var(--surface);
}
.chat-form input {
  flex: 1;
  padding: 0.7rem 1rem;
  font-family: var(--font-serif);
  font-size: 16px;
  border: 1px solid var(--line);
  border-radius: 100px;
  background: var(--bg);
  color: var(--ink);
  outline: none;
  transition: border-color .2s;
}
.chat-form input:focus { border-color: var(--ink); }
.chat-form input::placeholder { color: var(--muted-2); font-style: italic; }
.chat-send {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--bg);
  border: 0;
  display: inline-flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: background .2s, transform .2s;
  flex-shrink: 0;
}
.chat-send:hover { background: var(--ink-soft); transform: translateX(1px); }

.chat-foot {
  padding: 0.6rem 1rem 0.85rem;
  margin: 0;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  color: var(--muted);
  text-align: center;
  letter-spacing: 0.04em;
  background: var(--surface);
  border-top: 1px solid var(--line-soft);
}
.chat-foot a { color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }
.chat-foot a:hover { color: var(--ink); }

/* When cookie banner present, lift chat launcher above it */
.cookie-banner ~ .chat-launcher { bottom: 5.5rem; }
@media (max-width: 640px) {
  .cookie-banner ~ .chat-launcher { bottom: 7.5rem; }
}

/* Accessibility preference effects are opt-in and reversible. */
html.a11y-text-lg body { font-size: 18px; }
html.a11y-text-lg .lead,
html.a11y-text-lg .essay-para,
html.a11y-text-lg .prose,
html.a11y-text-lg .legal p,
html.a11y-text-lg .legal li,
html.a11y-text-lg .chat-msg { font-size: 1.1em; }
html.a11y-contrast {
  --bg: #fffdf8;
  --bg-soft: #f1ece3;
  --surface: #ffffff;
  --ink: #080706;
  --ink-soft: #171411;
  --muted: #443a31;
  --muted-2: #5b5146;
  --line: #51463a;
  --line-soft: #cfc2b2;
  --accent: #73280f;
  --accent-deep: #5d1f0c;
}
html[data-theme="dark"].a11y-contrast {
  --bg: #080706;
  --bg-soft: #12100d;
  --surface: #17120f;
  --ink: #fffaf2;
  --ink-soft: #f4ebdf;
  --muted: #d8cbbb;
  --muted-2: #bcae9b;
  --line: #8d7f6d;
  --line-soft: #4a4035;
  --accent: #ff996f;
  --accent-deep: #ffb190;
}
html.a11y-links a:not(.btn):not(.btn-primary):not(.nav-logo):not(.nav-link):not(.pf-card-img):not(.pf-card-img-link):not(.work-card-img-link):not(.chat-launcher):not(.wa-launcher):not(.a11y-launcher):not(.mob-bar-item):not(.audit-cta) {
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1.5px;
}
html.a11y-reduce-motion {
  scroll-behavior: auto !important;
}
html.a11y-reduce-motion *,
html.a11y-reduce-motion *::before,
html.a11y-reduce-motion *::after {
  animation-duration: .001ms !important;
  animation-iteration-count: 1 !important;
  scroll-behavior: auto !important;
  transition-duration: .001ms !important;
}
html.a11y-spacing .lead,
html.a11y-spacing .essay-para,
html.a11y-spacing .prose p,
html.a11y-spacing .legal p,
html.a11y-spacing .legal li,
html.a11y-spacing .chat-msg {
  line-height: 1.85;
}

/* ─────────────────────────────────────────────────────────────
   Hero 2-col grid with sidecar
   ───────────────────────────────────────────────────────────── */
.hero-grid {
  display: grid;
  grid-template-columns: 1.55fr 1fr;
  gap: 4rem;
  align-items: start;
  max-width: 100%;
}
.hero-main { min-width: 0; }
.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem 1.2rem;
  margin-top: 1.45rem;
}
.hero-sidecar { position: sticky; top: 110px; }
@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; gap: 3rem; }
  .hero-sidecar { position: static; }
}
@media (max-width: 768px) {
  /* Hide 3D card stack on mobile — 10 background-image loads kill perf */
  .hero-sidecar { display: none; }
}

.hero-sidecar-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 1.75rem;
  box-shadow: 0 1px 0 rgba(255,255,255,0.5) inset, 0 18px 48px -30px rgba(26,22,18,0.18);
}
.hero-sidecar-head {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
  margin-bottom: 1.4rem;
}
.hero-sidecar-pulse {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 3px rgba(94,122,74,0.22);
  animation: chatPulse 2.4s ease-in-out infinite;
  flex-shrink: 0;
}
.hero-sidecar-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 1rem; }
.hero-sidecar-list li {
  display: grid;
  grid-template-columns: 70px 1fr;
  gap: 0.85rem;
  align-items: baseline;
}
.hero-sidecar-tag {
  font-family: var(--font-sans);
  font-size: 0.66rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent);
  padding-top: 2px;
}
.hero-sidecar-line {
  font-family: var(--font-serif);
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--ink-soft);
  letter-spacing: -0.005em;
}
.hero-sidecar-divider {
  height: 1px;
  background: var(--line);
  margin: 1.5rem 0;
}
.hero-sidecar-note {
  display: block;
  transition: transform .25s ease;
}
.hero-sidecar-note:hover { transform: translateX(2px); }
.hero-sidecar-note-label {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.66rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted);
  margin-bottom: 0.55rem;
}
.hero-sidecar-note-title {
  display: block;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.02rem;
  line-height: 1.3;
  letter-spacing: -0.018em;
  color: var(--ink);
  margin-bottom: 0.65rem;
}
.hero-sidecar-note-arrow {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  color: var(--ink);
  border-bottom: 1px solid var(--ink);
  padding-bottom: 1px;
}
.hero-sidecar-availability { display: grid; gap: 0.45rem; }
.hero-sidecar-availability-label {
  font-family: var(--font-sans);
  font-size: 0.66rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted);
}
.hero-sidecar-availability-value {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.4rem;
  letter-spacing: -0.025em;
  color: var(--ink);
}
.hero-sidecar-availability-link {
  font-family: var(--font-sans);
  font-size: 0.82rem;
  color: var(--accent);
  border-bottom: 1px solid var(--accent);
  padding-bottom: 1px;
  align-self: start;
  margin-top: 0.35rem;
}

/* ─────────────────────────────────────────────────────────────
   Rich footer
   ───────────────────────────────────────────────────────────── */
.footer-rich { padding: 6rem 0 2.5rem; }

.footer-top {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 5rem;
  padding-bottom: 4rem;
  border-bottom: 1px solid var(--line);
  margin-bottom: 4rem;
}
@media (max-width: 900px) {
  .footer-top { grid-template-columns: 1fr; gap: 3rem; padding-bottom: 3rem; margin-bottom: 3rem; }
}

.footer-brand { display: flex; flex-direction: column; gap: 1.5rem; }
.footer-logo {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(2.5rem, 5vw, 4rem);
  line-height: 0.95;
  letter-spacing: -0.035em;
  color: var(--ink);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
}
.footer-logo {
  align-items: baseline;
  gap: 1rem;
}
.footer-logo-italic {
  font-family: var(--font-logo);
  font-style: italic;
  font-weight: 500;
  letter-spacing: -0.025em;
  color: var(--ink);
}
.footer-logo-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  margin-left: 4px;
  vertical-align: top;
  transform: translateY(0.45em);
}
.footer-logo-caps {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.42em;
  color: var(--muted);
  text-transform: uppercase;
  transform: translateY(-0.4em);
}
.footer-tag {
  font-family: var(--font-serif);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--ink-soft);
  max-width: 42ch;
  margin: 0;
}

/* Newsletter */
.footer-newsletter { display: flex; flex-direction: column; gap: 1rem; }
.footer-newsletter-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
  margin: 0;
}
.footer-newsletter-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.4rem, 2.2vw, 1.85rem);
  line-height: 1.2;
  letter-spacing: -0.025em;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}
.footer-newsletter-form {
  display: flex;
  gap: 0;
  align-items: stretch;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 0.5rem;
  margin-top: 0.5rem;
}
.footer-newsletter-form input {
  flex: 1;
  padding: 0.65rem 0;
  font-family: var(--font-serif);
  font-size: 1.1rem;
  letter-spacing: -0.005em;
  background: transparent;
  border: 0;
  outline: none;
  color: var(--ink);
}
.footer-newsletter-form input::placeholder {
  color: var(--muted-2);
  font-style: italic;
}
.footer-newsletter-form button {
  padding: 0.55rem 1.25rem;
  background: var(--ink);
  color: var(--bg);
  border: 0;
  border-radius: 100px;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: background .2s ease, transform .2s ease;
  align-self: center;
  white-space: nowrap;
}
.footer-newsletter-form button:hover {
  background: var(--ink-soft);
  transform: translateX(1px);
}
.footer-newsletter-note {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  color: var(--muted);
  margin: 0.25rem 0 0;
  letter-spacing: 0.005em;
}
.footer-newsletter-success {
  padding: 1rem 1.25rem;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  font-family: var(--font-serif);
  color: var(--ink);
  font-size: 0.95rem;
}

/* Currently shipping snippet */
.footer-now {
  padding: 2.5rem 0;
  margin-bottom: 3.5rem;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.footer-now-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 1.75rem;
  flex-wrap: wrap;
}
.footer-now-pulse {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 3px rgba(94,122,74,0.22);
  animation: chatPulse 2.4s ease-in-out infinite;
}
.footer-now-label {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
  flex: 1;
}
.footer-now-link {
  font-family: var(--font-sans);
  font-size: 0.82rem;
  color: var(--ink);
  border-bottom: 1px solid var(--ink);
  padding-bottom: 1px;
}
.footer-now-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}
.footer-now-item { display: flex; flex-direction: column; gap: 0.65rem; }
.footer-now-tag {
  display: inline-block;
  align-self: flex-start;
  font-family: var(--font-sans);
  font-size: 0.66rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--accent);
}
.footer-now-text {
  font-family: var(--font-serif);
  font-size: 1rem;
  line-height: 1.55;
  color: var(--ink-soft);
  margin: 0;
}

/* Footer link columns */
.footer-rich .footer-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr 0.95fr minmax(260px, 1.15fr);
  gap: 3rem;
  margin-bottom: 3rem;
  align-items: start;
}
.footer-start-card {
  padding: 1.25rem;
  border: 1px solid var(--line);
  background:
    linear-gradient(145deg, rgba(251,248,242,0.74), rgba(236,231,222,0.42));
  box-shadow: var(--shadow-soft);
}
.footer-start-card h3 {
  margin: 0;
  max-width: 12ch;
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 2vw, 2.2rem);
  font-weight: 500;
  line-height: 0.98;
  letter-spacing: -0.04em;
  color: var(--ink);
}
.footer-start-card p:not(.footer-label) {
  margin: 0.95rem 0 0;
  max-width: 34ch;
  font-family: var(--font-serif);
  font-size: 0.98rem;
  line-height: 1.55;
  color: var(--ink-soft);
}
.footer-start-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem 1rem;
  margin-top: 1.25rem;
}
.footer-start-actions .btn {
  min-height: 42px;
  padding: 0.72rem 1rem;
  font-size: 0.82rem;
}
.footer-start-actions .btn-link {
  font-size: 0.82rem;
}
.footer-start-links {
  margin-top: 1.35rem !important;
  padding-top: 1rem !important;
  border-top: 1px solid var(--line);
}
.footer-start-links a {
  display: inline-flex;
  font-size: 0.86rem;
}
@media (max-width: 880px) {
  .footer-rich .footer-grid { grid-template-columns: 1fr 1fr !important; gap: 2.5rem !important; }
}
@media (max-width: 560px) {
  .footer-rich .footer-grid { grid-template-columns: 1fr !important; }
  .footer-start-card { padding: 1.1rem; }
  .footer-start-card h3 { max-width: 10ch; }
}

/* Footer bottom */
.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
}

/* ─────────────────────────────────────────────────────────────
   Editorial essay section — homepage "A short essay"
   ───────────────────────────────────────────────────────────── */

.essay-section { padding: 7rem 0; }
@media (max-width: 768px) { .essay-section { padding: 5rem 0; } }

.essay-grid {
  display: grid;
  grid-template-columns: 0.85fr 2fr;
  gap: 5rem;
  max-width: 1180px;
  margin: 0 auto;
  align-items: start;
}
@media (max-width: 900px) {
  .essay-grid { grid-template-columns: 1fr; gap: 3rem; }
}

/* ── Sticky editorial meta column ── */
.essay-meta {
  position: sticky;
  top: 110px;
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}
@media (max-width: 900px) {
  .essay-meta { position: static; gap: 2rem; }
}

.essay-chapter {
  display: flex;
  align-items: center;
  gap: 14px;
}
.essay-chapter-num {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 3.2rem;
  line-height: 0.9;
  letter-spacing: -0.04em;
  color: var(--accent);
}
.essay-chapter-rule {
  width: 24px;
  height: 1px;
  background: var(--ink);
}
.essay-chapter-label {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.24em;
  color: var(--ink);
}

.essay-side-note {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.4rem, 2.1vw, 1.85rem);
  line-height: 1.25;
  letter-spacing: -0.018em;
  color: var(--ink);
  margin: 0;
  padding: 1.5rem 0 1.5rem 1.5rem;
  border-left: 2px solid var(--accent);
  max-width: 28ch;
}

.essay-meta-block {
  display: grid;
  gap: 1rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
}
.essay-meta-row {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 1rem;
  align-items: baseline;
}
.essay-meta-key {
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted);
}
.essay-meta-val {
  font-family: var(--font-serif);
  font-size: 0.98rem;
  color: var(--ink);
  letter-spacing: -0.005em;
}

.essay-side-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
}
.essay-side-stats > div { display: flex; flex-direction: column; gap: 0.25rem; }
.essay-side-stat-num {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.7rem, 2.6vw, 2.1rem);
  line-height: 1;
  letter-spacing: -0.035em;
  color: var(--ink);
}
.essay-side-stat-lbl {
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--muted);
}

/* ── Essay body ── */
.essay-body { min-width: 0; max-width: 64ch; }

.essay-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(2.2rem, 4.6vw, 3.6rem);
  line-height: 1.02;
  letter-spacing: -0.035em;
  color: var(--ink);
  margin: 0 0 0;
  text-wrap: balance;
}
.essay-title-sub {
  display: block;
  margin-top: 0.4rem;
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.8rem, 3.4vw, 2.6rem);
  line-height: 1.1;
  letter-spacing: -0.022em;
  color: var(--ink-soft);
}

.essay-divider {
  display: flex;
  align-items: center;
  margin: 2.5rem 0 2rem;
}
.essay-divider span {
  width: 64px;
  height: 1px;
  background: var(--ink);
  display: block;
  position: relative;
}
.essay-divider span::after {
  content: '';
  position: absolute;
  right: -5px;
  top: -3px;
  width: 7px;
  height: 7px;
  background: var(--accent);
  border-radius: 50%;
}

.essay-lede {
  font-family: var(--font-serif);
  font-size: clamp(1.15rem, 1.5vw, 1.32rem);
  line-height: 1.65;
  color: var(--ink);
  letter-spacing: -0.008em;
  margin: 0 0 1.5rem;
}

.essay-dropcap {
  float: left;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 4.6em;
  line-height: 0.88;
  padding: 0.1em 0.12em 0 0;
  color: var(--accent);
  letter-spacing: -0.04em;
}

.essay-para {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  line-height: 1.75;
  color: var(--ink-soft);
  letter-spacing: -0.005em;
  margin: 0 0 1.5rem;
}
.essay-para em { font-style: italic; color: var(--ink); }
.essay-para strong { font-weight: 600; color: var(--ink); }

/* ── Pull statement ── */
.essay-pull {
  position: relative;
  margin: 3rem 0 2.5rem;
  padding: 2rem 0 2rem 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2rem;
  align-items: center;
}
.essay-pull-text {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.5rem, 2.6vw, 2rem);
  line-height: 1.2;
  letter-spacing: -0.028em;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}
.essay-pull-mark {
  font-family: var(--font-serif);
  font-size: clamp(3rem, 5vw, 4.5rem);
  line-height: 0.9;
  color: var(--accent);
  opacity: 0.6;
  align-self: start;
}

.essay-close {
  padding-top: 0.5rem;
  border-top: 1px dashed var(--line);
  margin-top: 1.5rem;
}

/* ── Closing footer links ── */
.essay-foot {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--line);
}
.essay-foot-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 0.72rem 0;
  font-family: var(--font-sans);
  font-size: 0.92rem;
  color: var(--ink);
  transition: gap .3s cubic-bezier(.2,.7,.2,1), color .25s;
  width: max-content;
  max-width: 100%;
}
.essay-foot-link:hover { gap: 14px; color: var(--accent); }
.essay-foot-arrow {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--accent);
}
.essay-foot-text {
  border-bottom: 1px solid var(--ink);
  padding-bottom: 2px;
  letter-spacing: -0.005em;
}

/* ─────────────────────────────────────────────────────────────
   Hero stats grid — proper containment, breathing room
   ───────────────────────────────────────────────────────────── */

/* ── Founder strip — paired pill cards linking to each Upwork profile ── */
.founder-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin-top: 2.25rem;
  max-width: 560px;
}
.founder-pill {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.85rem 1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  text-decoration: none;
  transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease;
  position: relative;
}
.founder-pill:hover {
  border-color: var(--ink);
  transform: translateY(-1px);
  box-shadow: 0 8px 24px -16px rgba(26,22,18,0.3);
}
.founder-pill-avatar {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 500;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}
.founder-pill-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  flex: 1;
}
.founder-pill-name {
  font-family: var(--font-sans);
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.2;
}
.founder-pill-loc {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  color: var(--muted);
  letter-spacing: 0.01em;
}
.founder-pill-arrow {
  color: var(--muted);
  flex-shrink: 0;
  transition: transform .18s ease, color .18s ease;
}
.founder-pill:hover .founder-pill-arrow {
  color: var(--accent);
  transform: translate(2px, -2px);
}
@media (max-width: 520px) {
  .founder-strip { grid-template-columns: 1fr; gap: 0.5rem; max-width: 100%; }
  .founder-pill { padding: 0.7rem 0.85rem; }
  .founder-pill-avatar { flex-basis: 32px; width: 32px; height: 32px; font-size: 0.95rem; }
}

.hero-stats {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 2.25rem 2.5rem;
  max-width: 820px;
}
.home-page .hero-proof-strip {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-width: 560px;
  gap: 0;
  padding: 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.home-page .hero-proof-strip .hero-stat {
  position: relative;
  gap: 0.72rem;
  min-height: 6.9rem;
  justify-content: center;
  padding: 1.15rem clamp(1rem, 2vw, 1.35rem);
}
.home-page .hero-proof-strip .hero-stat + .hero-stat {
  border-left: 1px solid var(--line);
}
.home-page .hero-proof-strip .hero-stat:nth-child(odd) {
  border-left: 0;
}
.home-page .hero-proof-strip .hero-stat:nth-child(n+3) {
  border-top: 1px solid var(--line);
}
.home-page .hero-proof-strip .hero-stat:first-child {
  padding-left: clamp(1rem, 2vw, 1.35rem);
}
.home-page .hero-proof-strip .bignum {
  font-size: clamp(2.15rem, 4.2vw, 3.55rem);
  line-height: 0.92;
  gap: 0;
}
.home-page .hero-proof-strip .bignum-suffix {
  margin-left: 1px;
  transform: translateY(-0.06em);
}
.home-page .hero-proof-strip .bignum-word {
  max-width: 8ch;
  white-space: normal;
  font-size: clamp(1.55rem, 2.5vw, 2.24rem);
  line-height: 0.98;
  letter-spacing: -0.045em;
}
.home-page .hero-proof-strip .hero-stat-lbl {
  max-width: 13ch;
  font-size: 0.68rem;
  letter-spacing: 0.17em;
}
.hero-stats-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); max-width: 1000px; }

@media (max-width: 960px) {
  .hero-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2rem 2rem; }
  .home-page .hero-proof-strip .hero-stat {
    min-height: 6.7rem;
    padding: 1rem 1.2rem;
  }
  .hero-stats-5 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 520px) {
  .home-page .hero-main .h-display {
    font-size: 2.48rem;
    line-height: 1.03;
    letter-spacing: 0;
    text-wrap: balance;
  }
  .home-page .hero-main .word-mask,
  .home-page .hero-main .word {
    display: inline;
    overflow: visible;
    padding-bottom: 0;
    margin-bottom: 0;
    vertical-align: baseline;
    animation: none;
  }

  .hero-stats, .hero-stats-5 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.75rem 1.5rem; }
  .hero-stats-5 .bignum {
    white-space: normal;
    overflow-wrap: break-word;
  }
  .home-page .hero-proof-strip {
    grid-template-columns: 1fr;
    gap: 0;
    padding: 0;
  }
  .home-page .hero-proof-strip .hero-stat {
    min-height: auto;
    align-items: flex-start;
    padding: 1.15rem 0.95rem;
    border-left: 0 !important;
    border-top: 1px solid var(--line);
  }
  .home-page .hero-proof-strip .hero-stat:first-child {
    border-top: 0;
  }
  .home-page .hero-proof-strip .bignum {
    width: max-content;
    max-width: 100%;
    font-size: clamp(2.2rem, 12vw, 3rem);
  }
  .home-page .hero-proof-strip .bignum-word {
    max-width: none;
    font-size: clamp(1.62rem, 8vw, 2.1rem);
  }
  .home-page .hero-proof-strip .hero-stat-lbl {
    max-width: none;
  }
}

.hero-stat {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.hero-stat-lbl {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  margin: 0;
  line-height: 1.4;
}

/* Bignum suffix — small marks like + % yrs ★ */
.bignum-suffix {
  font-size: 0.5em;
  font-weight: 500;
  letter-spacing: 0;
  margin-left: 1px;
  color: var(--ink);
  align-self: baseline;
}

/* ─────────────────────────────────────────────────────────────
   Keyboard accessibility — visible focus ring
   ───────────────────────────────────────────────────────────── */
:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}
.btn:focus-visible,
.btn-primary:focus-visible,
.btn-ghost:focus-visible,
.btn-accent:focus-visible {
  outline-offset: 3px;
}
.nav-link:focus-visible,
.work-card:focus-visible,
.case-study a:focus-visible,
.btn-link:focus-visible,
.btn-editorial:focus-visible {
  outline-offset: 4px;
}
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.chat-launcher:focus-visible {
  outline: 2px solid var(--bg);
  outline-offset: 3px;
  box-shadow: 0 0 0 5px var(--accent);
}

/* ─────────────────────────────────────────────────────────────
   Portfolio work-card refinements — case study link + live URL
   ───────────────────────────────────────────────────────────── */
.work-card-img-link { display: block; }
.work-card-actions {
  margin-top: auto;
  padding-top: 1.1rem;
  border-top: 1px solid var(--line-soft);
  display: flex;
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}
.work-card-cs {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--ink);
  border-bottom: 1px solid var(--ink);
  padding-bottom: 1px;
  letter-spacing: -0.005em;
  transition: color .25s, border-color .25s;
}
.work-card-cs:hover { color: var(--accent); border-bottom-color: var(--accent); }
.work-card-live {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0;
  transition: color .25s;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 60%;
}
.work-card-live:hover { color: var(--ink); }

/* ─────────────────────────────────────────────────────────────
   Portfolio: branded placeholder + featured badge
   ───────────────────────────────────────────────────────────── */
.work-card-placeholder {
  height: 100%;
  background: linear-gradient(135deg, var(--bg-soft) 0%, var(--surface) 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  position: relative;
}
.work-card-placeholder::before {
  content: '';
  position: absolute;
  inset: 16px;
  border: 1px dashed var(--line);
  border-radius: 4px;
  pointer-events: none;
}
.work-card-placeholder-mark {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 5rem;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--accent);
  opacity: 0.7;
}
.work-card-placeholder-label {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
}

.work-card-img-link { position: relative; }
.work-card-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  background: var(--ink);
  color: var(--bg);
  font-family: var(--font-sans);
  font-size: 0.66rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  border-radius: 100px;
  pointer-events: none;
}
.work-card-badge::before {
  content: '';
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--accent);
}
.work-card-featured { /* No size difference — same grid cell. Just the badge. */ }

/* ─────────────────────────────────────────────────────────────
   1. Subtle grain texture — adds tactile quality across the site
   ───────────────────────────────────────────────────────────── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.035;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' seed='4' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.1  0 0 0 0 0.09  0 0 0 0 0.07  0 0 0 0.9 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  background-size: 200px 200px;
}
@media (prefers-reduced-motion: reduce), (max-width: 640px) {
  body::before { display: none; }
}

/* ─────────────────────────────────────────────────────────────
   2. Custom cursor — terracotta dot + outline ring
   ───────────────────────────────────────────────────────────── */
@media (hover: hover) and (pointer: fine) {
  body.cursor-ready { cursor: none; }
  body.cursor-ready a,
  body.cursor-ready button,
  body.cursor-ready input,
  body.cursor-ready textarea,
  body.cursor-ready select,
  body.cursor-ready [role="button"] { cursor: none; }
  body.cursor-ready textarea, body.cursor-ready input { cursor: none; }

  .cursor-dot,
  .cursor-ring {
    position: fixed;
    top: 0; left: 0;
    pointer-events: none;
    z-index: 9999;
    will-change: transform;
    transform: translate3d(0, 0, 0);
    mix-blend-mode: normal;
  }
  .cursor-dot {
    width: 6px; height: 6px;
    background: var(--accent);
    border-radius: 50%;
    transition: transform .12s cubic-bezier(.2,.7,.2,1), opacity .2s;
    margin: -3px 0 0 -3px;
  }
  .cursor-ring {
    width: 32px; height: 32px;
    border: 1px solid var(--ink);
    border-radius: 50%;
    transition: transform .35s cubic-bezier(.2,.7,.2,1), opacity .25s, width .3s, height .3s, background .3s;
    margin: -16px 0 0 -16px;
    opacity: 0.4;
  }
  body.cursor-hover .cursor-ring {
    width: 56px; height: 56px;
    margin: -28px 0 0 -28px;
    border-color: var(--accent);
    background: rgba(139, 58, 31, 0.06);
    opacity: 0.7;
  }
  body.cursor-hover .cursor-dot { transform: scale(0); }
}

/* ─────────────────────────────────────────────────────────────
   3. Device mockup — browser frame cycling client screenshots
   ───────────────────────────────────────────────────────────── */
.device-mockup {
  position: relative;
  background: linear-gradient(140deg, var(--surface) 0%, var(--bg-soft) 100%);
  border-radius: 12px;
  border: 1px solid var(--line);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.7) inset,
    0 30px 60px -30px rgba(26,22,18,0.18),
    0 1px 2px rgba(26,22,18,0.04);
  overflow: hidden;
  aspect-ratio: 4 / 3;
}
.device-chrome {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 11px 14px;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.device-chrome-dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--line);
  flex-shrink: 0;
}
.device-chrome-dot:first-child { background: rgba(139, 58, 31, 0.45); }
.device-chrome-url {
  flex: 1;
  margin-left: 14px;
  padding: 4px 10px;
  background: var(--bg-soft);
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--muted);
  letter-spacing: -0.005em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: center;
  transition: color .35s ease;
}
.device-viewport {
  position: relative;
  width: 100%;
  height: calc(100% - 38px);
  background: var(--bg-soft);
  overflow: hidden;
}
.device-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity .9s cubic-bezier(.2,.7,.2,1);
  background-size: cover;
  background-position: top center;
  filter: saturate(0.96);
}
.device-slide.is-active { opacity: 1; }

.device-caption {
  position: absolute;
  bottom: 14px;
  left: 14px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 12px;
  background: rgba(26,22,18,0.85);
  backdrop-filter: blur(8px);
  color: var(--bg);
  border-radius: 6px;
  font-family: var(--font-sans);
  pointer-events: none;
}
.device-caption-name {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: -0.005em;
}
.device-caption-tag {
  font-size: 0.62rem;
  font-weight: 500;
  color: rgba(244,240,234,0.7);
  text-transform: uppercase;
  letter-spacing: 0.18em;
}

.device-progress {
  position: absolute;
  top: 38px;
  left: 0;
  height: 2px;
  background: var(--accent);
  width: 0%;
  transition: width 0.05s linear;
  z-index: 2;
}

/* ─────────────────────────────────────────────────────────────
   4. Sticky "Book a free audit" CTA pill (mirrors chatbot bottom-right)
   ───────────────────────────────────────────────────────────── */
.audit-cta {
  position: fixed;
  bottom: 5.45rem;
  left: 1.5rem;
  z-index: 70;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0.85rem 1.3rem 0.85rem 1.1rem;
  background: var(--bg);
  color: var(--ink);
  border: 1px solid var(--ink);
  border-radius: 100px;
  font-family: var(--font-sans);
  font-size: 0.86rem;
  font-weight: 500;
  letter-spacing: -0.005em;
  text-decoration: none;
  box-shadow: 0 18px 48px -16px rgba(26,22,18,0.18);
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: transform .35s cubic-bezier(.2,.7,.2,1), background .25s, color .25s, opacity .35s;
}
.audit-cta.is-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.audit-cta:hover {
  background: var(--ink);
  color: var(--bg);
  transform: translateY(-2px);
}
.audit-cta-mark {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
  box-shadow: 0 0 0 3px rgba(139, 58, 31, 0.18);
}
.audit-cta-svg {
  margin-left: 2px;
  transition: transform .35s cubic-bezier(.2,.7,.2,1);
}
.audit-cta:hover .audit-cta-svg { transform: translateX(3px); }
body.is-contact-visible .audit-cta,
body.is-contact-visible .chat-launcher,
body.is-contact-visible .wa-launcher {
  opacity: 0;
  transform: translateY(16px);
  pointer-events: none;
}
body:has(.cookie-banner) .audit-cta {
  bottom: 9.35rem;
}
@media (max-width: 640px) {
  body:has(.cookie-banner) .audit-cta,
  .audit-cta {
    bottom: 1rem;
    left: 1rem;
    padding: 0.75rem 1.1rem 0.75rem 0.95rem;
    font-size: 0.82rem;
  }
}

/* ─────────────────────────────────────────────────────────────
   5. Aggregate metrics band — defensible per-engagement ranges
   ───────────────────────────────────────────────────────────── */
.metrics-band {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
@media (max-width: 880px) { .metrics-band { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .metrics-band { grid-template-columns: 1fr; } }

.metric-cell {
  padding: 2.5rem 2rem;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--surface);
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  transition: background .3s ease;
}
.metric-cell:hover { background: var(--bg); }
.metric-cell:nth-child(3n) { border-right: 0; }
.metric-cell:nth-last-child(-n+3) { border-bottom: 0; }
@media (max-width: 880px) {
  .metric-cell { border-right: 1px solid var(--line) !important; border-bottom: 1px solid var(--line) !important; }
  .metric-cell:nth-child(2n) { border-right: 0 !important; }
  .metric-cell:nth-last-child(-n+2) { border-bottom: 0 !important; }
}
@media (max-width: 520px) {
  .metric-cell { border-right: 0 !important; border-bottom: 1px solid var(--line) !important; }
  .metric-cell:last-child { border-bottom: 0 !important; }
}

.metric-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.66rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--accent);
}
.metric-headline {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.6rem, 2.8vw, 2.1rem);
  line-height: 1.12;
  letter-spacing: -0.028em;
  color: var(--ink);
}
.metric-headline em {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
}
.metric-detail {
  font-family: var(--font-serif);
  font-size: 0.97rem;
  line-height: 1.55;
  color: var(--ink-soft);
  letter-spacing: -0.005em;
  margin: 0;
}

/* ─────────────────────────────────────────────────────────────
   6. Mobile typography & density refinements
   ───────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  body { font-size: 16px; line-height: 1.65; }
  .h-display { font-size: clamp(2.2rem, 9vw, 3.4rem); line-height: 1.02; }
  .h-1 { font-size: clamp(1.7rem, 6.5vw, 2.4rem); line-height: 1.08; }
  .h-2 { font-size: clamp(1.3rem, 5vw, 1.65rem); }
  .lead { font-size: 1.06rem; line-height: 1.6; max-width: 100%; }
  .prose { font-size: 1.04rem; line-height: 1.7; }
  .prose p { margin: 0 0 1.1em; }
  .essay-body { max-width: 100%; }
  .essay-lede { font-size: 1.1rem; line-height: 1.6; }
  .essay-para { font-size: 1.04rem; line-height: 1.7; margin-bottom: 1.25rem; }
  .essay-pull { margin: 2rem 0 1.75rem; padding: 1.5rem 0; }
  .essay-pull-text { font-size: 1.3rem; }
  .essay-dropcap { font-size: 3.8em; }
  .btn { padding: 0.95rem 1.4rem; min-height: 44px; }
  .btn-primary { min-height: 44px; }
  .nav-link { padding: 0.6rem 0.85rem; min-height: 40px; }
  .case-desc { font-size: 1rem; line-height: 1.55; }
  .case-name { font-size: clamp(1.7rem, 6vw, 2.2rem); }
  .work-card-name { font-size: 1.2rem; }
  .work-card-tag { font-size: 0.95rem; line-height: 1.5; }
  details.faq { padding: 1.3rem 0; }
  details.faq summary { font-size: 1.06rem; line-height: 1.35; }
  .footer-top { gap: 2.5rem; padding-bottom: 2.5rem; margin-bottom: 2.5rem; }
  .footer-newsletter-form input { font-size: 1rem; padding: 0.6rem 0 0.7rem; }
  .container, .container-narrow { padding: 0 1.25rem; }
}

/* Larger touch targets for tap-only contexts */
@media (hover: none) and (pointer: coarse) {
  .work-card-cs, .work-card-live, .btn-link, .btn-editorial, .case-link {
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }
}

/* ─────────────────────────────────────────────────────────────
   Hero device mockup — v2, cinematic + tighter
   ───────────────────────────────────────────────────────────── */

/* Override v1 device-mockup with a tighter, more cinematic build */
.device-mockup {
  aspect-ratio: 16 / 11;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, var(--surface) 0%, var(--bg-soft) 100%);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.85) inset,
    0 1px 2px rgba(26,22,18,0.06),
    0 18px 36px -18px rgba(26,22,18,0.16),
    0 50px 80px -40px rgba(26,22,18,0.22);
  position: relative;
}
.device-mockup::after {
  /* Subtle highlight at the very top of the frame */
  content: '';
  position: absolute;
  top: 0; left: 5%; right: 5%;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.85) 50%, transparent 100%);
  pointer-events: none;
}

.device-chrome {
  padding: 9px 14px;
  background: var(--bg);
  border-bottom: 1px solid var(--line-soft);
  gap: 5px;
  position: relative;
  z-index: 1;
}
.device-chrome-dot {
  width: 8px; height: 8px;
}
.device-chrome-dot:first-child { background: #C2614A; }
.device-chrome-dot:nth-child(2) { background: #C8A24A; }
.device-chrome-dot:nth-child(3) { background: #6E8B5F; }

.device-chrome-url {
  margin-left: 10px;
  padding: 3px 12px;
  background: var(--bg-soft);
  border-radius: 100px;
  font-size: 0.66rem;
  letter-spacing: 0;
  color: var(--ink-soft);
  border: 1px solid transparent;
  transition: color .35s ease;
}
.device-chrome-url::before {
  content: '🔒\00a0';
  font-size: 0.7em;
  opacity: 0.45;
  margin-right: 1px;
}

.device-viewport {
  height: calc(100% - 32px);
  background: var(--bg);
}

.device-progress {
  top: 32px;
  height: 1.5px;
  background: var(--accent);
  opacity: 0.8;
}

.device-slide {
  transition: opacity 1s cubic-bezier(.2,.7,.2,1), transform 1.4s cubic-bezier(.2,.7,.2,1);
  transform: scale(1.03);
  filter: saturate(0.96) brightness(0.99);
}
.device-slide.is-active {
  transform: scale(1);
  filter: saturate(1) brightness(1);
}

.device-caption {
  bottom: 12px;
  left: 12px;
  padding: 7px 11px 8px;
  background: rgba(26,22,18,0.88);
  border-radius: 7px;
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.05);
}
.device-caption-name {
  font-size: 0.76rem;
  letter-spacing: -0.005em;
}
.device-caption-tag {
  font-size: 0.6rem;
  letter-spacing: 0.16em;
}

/* Give the mockup MORE width in the hero grid — was 1.55fr/1fr, now 1.3fr/1fr */
.hero-grid {
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 3rem;
}
.hero-main { min-width: 0; max-width: 100%; }
.hero-sidecar { min-width: 0; max-width: 100%; }
.hero-title {
  max-width: 11.4em;
  font-size: 4.35rem;
  line-height: 1.04;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}
.home-page .hero-main .word-mask,
.home-page .hero-main .word {
  overflow: visible;
  padding-bottom: 0.05em;
  margin-bottom: 0;
  vertical-align: baseline;
}
.hero-title .italic-serif {
  font-family: var(--font-logo);
  font-size: 0.9em;
  line-height: 1.08;
  letter-spacing: -0.045em;
}
.hero-lead {
  font-size: clamp(1.02rem, 1.15vw, 1.14rem);
  line-height: 1.58;
}

@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 3rem; }
  .hero-title {
    font-size: 3.7rem;
  }
}
@media (max-width: 640px) {
  .hero-title {
    font-size: 2.55rem;
    line-height: 1.06;
  }
  .hero-title .italic-serif {
    font-size: 0.92em;
    letter-spacing: -0.04em;
  }
  .hero-lead { line-height: 1.62; }
}

@media (max-width: 420px) {
  .hero-title {
    font-size: 2.28rem;
  }
}

/* Device mockup must size from its grid cell, never from its content */
.device-mockup {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

/* Reduce gap between mockup and the "Next available slot" line below */
.hero-sidecar {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.hero-proof-panel {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 1.25rem 3rem;
  align-items: start;
  margin-top: 0.35rem;
  padding-top: 1.45rem;
  border-top: 1px solid var(--line);
}
.hero-proof-copy {
  min-width: 0;
  display: grid;
  gap: 0.95rem;
  align-content: start;
}
.hero-proof-panel .founder-strip,
.hero-proof-panel .trust-badges,
.hero-proof-panel .hero-proof-strip {
  margin-top: 0;
}
.hero-proof-panel .hero-proof-strip {
  width: 100%;
  max-width: none;
}
@media (max-width: 1024px) {
  .hero-proof-panel {
    grid-template-columns: 1fr;
    gap: 1.35rem;
    margin-top: 0.75rem;
  }
  .hero-proof-panel .hero-proof-strip {
    max-width: 100%;
  }
}
@media (max-width: 640px) {
  .hero-proof-panel {
    margin-top: 0.5rem;
    padding-top: 1.2rem;
  }
}

/* ─────────────────────────────────────────────────────────────
   Portfolio card placeholder v2 — branded mark, not "pending"
   ───────────────────────────────────────────────────────────── */
.work-card-placeholder {
  background: linear-gradient(155deg, var(--bg) 0%, var(--bg-soft) 60%, var(--surface) 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 2rem 1.5rem;
  position: relative;
}
.work-card-placeholder::before {
  content: '';
  position: absolute;
  inset: 22px;
  border: 1px solid var(--line);
  border-radius: 6px;
  pointer-events: none;
}
.work-card-placeholder::after {
  /* Small terracotta accent dot at top */
  content: '';
  position: absolute;
  top: 32px; left: 50%;
  transform: translateX(-50%);
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.85;
}
.work-card-placeholder-mark {
  display: none; /* hide the big initial — name does the work */
}
.work-card-placeholder-name {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.6rem, 3.2vw, 2.1rem);
  line-height: 1.05;
  letter-spacing: -0.025em;
  color: var(--ink);
  text-align: center;
  max-width: 80%;
  padding: 0 1rem;
}
.work-card-placeholder-label {
  margin-top: 1rem;
  font-family: var(--font-sans);
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.24em;
  color: var(--muted);
  text-align: center;
}


/* ─────────────────────────────────────────────────────────────
   Case-study wordmark (homepage Selected Work — for projects
   with hideScreenshot: true, mirrors portfolio listing treatment)
   ───────────────────────────────────────────────────────────── */
.case-wordmark {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 360px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 2rem;
  background: linear-gradient(155deg, var(--bg) 0%, var(--bg-soft) 60%, var(--surface) 100%);
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  overflow: hidden;
  aspect-ratio: 16 / 11;
}
.case-wordmark::before {
  content: '';
  position: absolute;
  inset: 22px;
  border: 1px dashed var(--line);
  border-radius: 6px;
  pointer-events: none;
}
.case-wordmark::after {
  content: '';
  position: absolute;
  top: 36px; left: 50%;
  transform: translateX(-50%);
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.85;
}
.case-wordmark-name {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(2.6rem, 5.4vw, 4rem);
  line-height: 1.02;
  letter-spacing: -0.035em;
  color: var(--ink);
  max-width: 14ch;
  margin: 0;
}
.case-wordmark-tag {
  margin-top: 1.25rem;
  font-family: var(--font-sans);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.24em;
  color: var(--muted);
}
.case-wordmark-cta {
  margin-top: 2rem;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  color: var(--ink);
  border-bottom: 1px solid var(--ink);
  padding-bottom: 2px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.case-study a.case-image:has(.case-wordmark) {
  background: transparent;
  border: 0;
}
.case-study a.case-image:has(.case-wordmark)::after {
  display: none;
}

/* ─────────────────────────────────────────────────────────────
   Homepage Selected Work — redesigned editorial card grid
   (replaces the alternating case-study layout)
   ───────────────────────────────────────────────────────────── */

/* Grid wrapper */
.pf-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.75rem;
}

/* Featured card — spans both columns, horizontal layout */
.pf-card--featured {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 0;
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface);
  transition: box-shadow .4s ease, border-color .4s ease;
}
.pf-card--featured:hover {
  box-shadow: 0 14px 48px rgba(26,22,18,.08);
  border-color: rgba(26,22,18,.15);
}

/* Regular card — portrait, image top */
.pf-card {
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface);
  display: flex;
  flex-direction: column;
  transition: transform .4s cubic-bezier(.2,.7,.2,1), box-shadow .4s ease, border-color .4s ease;
}
.pf-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 48px rgba(26,22,18,.08);
  border-color: rgba(26,22,18,.15);
}

/* Image wrapper */
.pf-card-img {
  position: relative;
  overflow: hidden;
  background: var(--bg-soft);
  display: block;
  flex-shrink: 0;
}
.pf-card .pf-card-img { aspect-ratio: 16 / 10; }
.pf-card--featured .pf-card-img { height: 100%; min-height: 400px; }

.pf-card-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
  transition: transform .9s cubic-bezier(.2,.7,.2,1), filter .5s ease;
  filter: saturate(0.9);
}
.pf-card:hover .pf-card-img img,
.pf-card--featured:hover .pf-card-img img {
  transform: scale(1.04);
  filter: saturate(1);
}

/* Number badge — overlaid top-left on image */
.pf-card-num {
  position: absolute;
  top: 1rem; left: 1rem;
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.08em;
  color: rgba(244,240,234,.9);
  background: rgba(26,22,18,.45);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  padding: 0.22rem 0.6rem;
  border-radius: 4px;
  line-height: 1;
  pointer-events: none;
}

/* Card body — content below image (or beside for featured) */
.pf-card-body {
  padding: 1.6rem 1.9rem 1.9rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.pf-card--featured .pf-card-body {
  padding: 2.5rem 2.75rem;
  justify-content: center;
}

.pf-card-tag {
  font-family: var(--font-sans);
  font-size: 0.64rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
  margin-bottom: 0.85rem;
}

.pf-card-name {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.45rem, 2.2vw, 1.85rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--ink);
  margin: 0 0 0.85rem;
}
.pf-card--featured .pf-card-name {
  font-size: clamp(1.9rem, 3vw, 2.8rem);
  margin-bottom: 1.1rem;
}

.pf-card-desc {
  font-family: var(--font-serif);
  font-size: 1rem;
  line-height: 1.62;
  color: var(--ink-soft);
  margin: 0 0 1.75rem;
  max-width: 48ch;
  flex: 1;
}
.pf-card--featured .pf-card-desc {
  font-size: 1.06rem;
  margin-bottom: 2rem;
}

/* Card footer — metric left, link right */
.pf-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1.1rem;
  border-top: 1px solid var(--line);
  margin-top: auto;
  flex-wrap: wrap;
}

.pf-card-metric {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  color: var(--muted);
  letter-spacing: 0.01em;
  line-height: 1.4;
}
.pf-card-metric strong {
  display: block;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.35rem;
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--ink);
  margin-bottom: 0.15rem;
}

.pf-card-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--ink);
  white-space: nowrap;
  transition: gap .3s cubic-bezier(.2,.7,.2,1);
}
.pf-card-link svg { flex-shrink: 0; }
.pf-card-link:hover { gap: 12px; }

/* Wordmark variant — for projects without screenshots */
.pf-card-wm {
  width: 100%; height: 100%;
  min-height: 240px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 2rem;
  background: linear-gradient(155deg, var(--bg) 0%, var(--bg-soft) 60%, var(--surface) 100%);
  position: relative;
  overflow: hidden;
}
.pf-card--featured .pf-card-wm { min-height: 400px; }
.pf-card-wm::before {
  content: '';
  position: absolute;
  inset: 20px;
  border: 1px dashed rgba(26,22,18,.12);
  border-radius: 6px;
  pointer-events: none;
}
.pf-card-wm::after {
  content: '';
  position: absolute;
  top: 32px; left: 50%;
  transform: translateX(-50%);
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.7;
}
.pf-card-wm-name {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
  color: var(--ink);
  margin: 0;
}
.pf-card-wm-sub {
  margin-top: 1rem;
  font-family: var(--font-sans);
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
}

/* Responsive */
@media (max-width: 960px) {
  .pf-card--featured {
    grid-template-columns: 1fr;
  }
  .pf-card--featured .pf-card-img {
    height: auto;
    min-height: unset;
    aspect-ratio: 16 / 10;
  }
}
@media (max-width: 680px) {
  .pf-grid { grid-template-columns: 1fr; gap: 1.25rem; }
}

/* ═══════════════════════════════════════════════════════════════
   MOBILE — App-grade polish layer
   Assembled for iOS + Android. Keeps the Quiet Luxury aesthetic
   while delivering a native-feeling touch experience.
   ═══════════════════════════════════════════════════════════════ */

/* ── Global mobile fundamentals ── */
@media (max-width: 640px) {
  * { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
  html,
  body {
    max-width: 100%;
    overflow-x: hidden;
  }
  body { padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px)); }
  .section { padding: 4rem 0; }
  .section-lg { padding: 4rem 0; }
  .section-sm { padding: 2.5rem 0; }
  .container, .container-narrow, .container-tight { padding: 0 1.1rem; }
}

/* ── Mobile bottom navigation bar ── */
.mob-bar {
  display: none;
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 170;
  background: rgba(244,240,234,.92);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-top: 1px solid var(--line);
  padding: 0.28rem 0.75rem max(0.38rem, env(safe-area-inset-bottom, 0px));
  align-items: center;
  gap: 0.2rem;
}
@media (max-width: 640px) { .mob-bar { display: flex; } }

.mob-bar-item {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 0.28rem 0.2rem;
  font-family: var(--font-sans);
  font-size: 0.52rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  transition: color .18s ease;
  background: transparent;
  border: 0;
  cursor: pointer;
  min-height: 44px;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}
.mob-bar-item:active { color: var(--ink); transform: scale(0.94); }

.mob-bar-cta {
  flex: 1.35;
  flex-direction: row;
  gap: 5px;
  background: var(--ink);
  color: var(--bg) !important;
  border-radius: 100px;
  font-size: 0.68rem;
  font-weight: 500;
  line-height: 1.12;
  letter-spacing: -0.005em;
  text-transform: none;
  padding: 0.44rem 0.82rem;
  min-height: 44px;
  margin: 0.1rem 0.35rem;
  text-decoration: none;
}
.mob-bar-cta svg {
  width: 12px;
  height: 12px;
}
.mob-bar-cta:active { background: var(--ink-soft) !important; transform: scale(0.97); }

@media (max-width: 380px) {
  .mob-bar { padding-inline: 0.55rem; }
  .mob-bar-item { font-size: 0.5rem; }
  .mob-bar-cta {
    flex: 1.25;
    font-size: 0.64rem;
    padding: 0.4rem 0.68rem;
    margin-inline: 0.22rem;
  }
}

/* Hide floating chat/WhatsApp launchers on mobile — bottom bar has the routes */
@media (max-width: 640px) {
  .chat-launcher,
  .wa-launcher { display: none; }
  .audit-cta { display: none !important; }
  .a11y-launcher {
    bottom: calc(72px + env(safe-area-inset-bottom, 0px) + 0.85rem);
    left: 0.85rem;
    z-index: 171;
    width: 46px;
    height: 46px;
    min-height: 46px;
    padding: 0;
    border-radius: 50%;
  }
  .a11y-launcher-label { display: none; }
  .a11y-panel {
    left: 0.75rem;
    right: 0.75rem;
    bottom: calc(72px + env(safe-area-inset-bottom, 0px) + 4.25rem);
    z-index: 172;
    width: auto;
    max-height: min(72svh, 520px);
    border-radius: 14px;
    transform-origin: bottom left;
  }
  body.chat-open .a11y-launcher,
  body.menu-lock .a11y-launcher,
  body.chat-open .a11y-panel,
  body.menu-lock .a11y-panel {
    display: none;
  }
  .audit-cta {
    bottom: calc(112px + env(safe-area-inset-bottom, 0px)) !important;
    left: auto !important;
    right: 1rem !important;
    font-size: 0.72rem !important;
    padding: 0.55rem 0.95rem !important;
    white-space: nowrap;
  }
}

/* Hide bottom bar when chat is open full-screen */
body.chat-open .mob-bar { display: none; }

/* ── Cookie banner — lift above bottom bar ── */
@media (max-width: 640px) {
  .cookie-banner {
    left: 0.75rem !important;
    right: 0.75rem !important;
    bottom: calc(72px + env(safe-area-inset-bottom, 0px) + 0.5rem) !important;
    border-radius: var(--r-lg) !important;
    width: auto !important;
    z-index: 169;
    background: rgba(251,248,242,0.97);
    color: var(--ink);
    border: 1px solid var(--line);
    box-shadow: 0 18px 44px -22px rgba(26,22,18,0.34), 0 1px 0 rgba(255,255,255,0.65) inset;
  }
  .cookie-inner {
    grid-template-columns: 1fr auto;
    gap: 0.55rem;
    padding: 0.68rem 0.72rem;
  }
  .cookie-text {
    font-family: var(--font-sans);
    font-size: 0.74rem;
    line-height: 1.28;
    color: var(--ink-soft);
  }
  .cookie-text a {
    color: var(--ink);
  }
  .cookie-actions {
    justify-content: flex-end;
    gap: 0.35rem;
  }
  .cookie-btn {
    min-height: 34px;
    padding: 0.36rem 0.62rem;
    font-size: 0.72rem;
    color: var(--ink);
    border-color: var(--line);
  }
  .cookie-accept {
    background: var(--ink);
    color: var(--bg);
    border-color: var(--ink);
  }
  .cookie-banner ~ .a11y-launcher {
    opacity: 0;
    pointer-events: none;
    transform: translateY(8px) scale(0.94);
  }
  .cookie-banner ~ .a11y-panel {
    display: none;
  }
}

/* ── Hero — trust badges horizontal scroll ── */
@media (max-width: 680px) {
  .trust-badges {
    display: flex;
    flex-wrap: wrap;
    overflow-x: visible;
    gap: 0.4rem;
    padding-bottom: 0.4rem;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: none;
    scrollbar-width: none;
    margin-right: 0;
    padding-right: 0;
  }
  .trust-badges::-webkit-scrollbar { display: none; }
  .trust-badge {
    scroll-snap-align: start;
    flex-shrink: 0;
    max-width: 100%;
    font-size: 0.66rem;
    padding: 0.4rem 0.8rem;
    white-space: nowrap;
  }
  .hero-stat-lbl { font-size: 0.6rem; }
}

@media (max-width: 760px) {
  .founders-grid {
    grid-template-columns: 1fr !important;
    gap: 1.25rem !important;
    min-width: 0;
  }
  .founder-card {
    min-width: 0;
    padding: 1.45rem !important;
  }
  .founder-card > div:first-child {
    flex-wrap: wrap;
  }
  .founder-card .trust-badges {
    margin-right: 0;
    padding-right: 0;
  }
  .capability-table-wrap {
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .capability-table {
    min-width: 560px;
  }
}

/* ── Reviews — horizontal scroll carousel ── */
@media (max-width: 680px) {
  .reviews-grid {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 0.85rem;
    padding-bottom: 1rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    margin-right: -1.1rem;
    padding-right: 1.1rem;
  }
  .reviews-grid::-webkit-scrollbar { display: none; }
  .review-card {
    scroll-snap-align: start;
    flex: 0 0 84vw;
    min-width: 0;
    max-width: 320px;
  }
}

/* ── Portfolio cards — tighter padding ── */
@media (max-width: 680px) {
  .pf-grid { gap: 1rem; }
  .pf-card-body { padding: 1.15rem 1.3rem 1.4rem; }
  .pf-card--featured .pf-card-body { padding: 1.4rem 1.4rem 1.6rem; }
  .pf-card-name { font-size: clamp(1.25rem, 5.5vw, 1.55rem); }
  .pf-card--featured .pf-card-name { font-size: clamp(1.45rem, 6vw, 1.85rem); }
  .pf-card-desc { font-size: 0.9rem; }
  .pf-card-metric strong { font-size: 1.15rem; }
}

/* ── Metrics band ── */
@media (max-width: 520px) {
  .metrics-band { gap: 0.85rem; }
  .metric-headline { font-size: clamp(1rem, 5.5vw, 1.3rem); }
}

/* ── Insights band — 2 per row on mobile ── */
@media (max-width: 640px) {
  .insights-band { grid-template-columns: repeat(2, 1fr) !important; gap: 0; }
  .insight-cell { padding: 1.5rem 1.1rem; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
  .insight-cell:nth-child(2n) { border-right: 0; }
  .insight-count { font-size: clamp(1.9rem, 9vw, 2.6rem); }
  .insight-trait { font-size: 0.92rem; margin-top: 0.4rem; }
  .insight-sub { font-size: 0.58rem; letter-spacing: 0.14em; }
}

/* ── Essay section — hide sidebar meta ── */
@media (max-width: 640px) {
  .essay-meta { display: none; }
  .essay-grid { grid-template-columns: 1fr !important; gap: 0 !important; }
  .essay-title { font-size: clamp(1.55rem, 6.5vw, 2rem); line-height: 1.12; }
}

/* ── Approach section ── */
@media (max-width: 640px) {
  .approach-grid { grid-template-columns: 1fr !important; gap: 2rem !important; }
}

/* ── Contact section ── */
.contact-form-intro {
  margin: 0 0 2rem;
}

.contact-form-intro h3 {
  margin: 0.75rem 0 0.5rem;
  font-family: var(--font-display);
  font-size: clamp(1.45rem, 2vw, 1.85rem);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: 0;
}

.contact-form-intro p {
  margin: 0;
  color: var(--muted);
  font-family: var(--font-sans);
  font-size: 0.88rem;
  line-height: 1.55;
}

@media (max-width: 640px) {
  .contact-grid { grid-template-columns: 1fr !important; gap: 2rem !important; }
  .contact-form-card { order: -1; }
  .card-static { padding: 1.75rem 1.25rem !important; }
}

/* ── FAQ accordion ── */
@media (max-width: 640px) {
  .faq summary { padding: 1.1rem 0; font-size: 0.96rem; min-height: 52px; display: flex; align-items: center; justify-content: space-between; }
}

/* ── Built-on + Integrations: interactive marquees ── */
.stack-band { padding: 5rem 0; border-bottom: 1px solid var(--line); background: var(--bg); }
.int-band   { padding: 6rem 0; background: var(--bg); }
.stack-head { text-align: center; max-width: 660px; margin: 0 auto 2.3rem; }
.stack-head--lg { max-width: 720px; margin-bottom: 3rem; }

.marq {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
}
.marq + .marq { margin-top: 0.85rem; }
.marq-track { display: flex; width: max-content; animation: marq-scroll 46s linear infinite; }
.marq--rev .marq-track { animation-direction: reverse; }
.marq:hover .marq-track { animation-play-state: paused; }
@keyframes marq-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

.chip {
  display: inline-flex; align-items: center; gap: 0.55rem;
  margin-right: 0.7rem; padding: 0.62rem 1.15rem; border-radius: 100px;
  border: 1px solid var(--line); background: var(--surface);
  font-family: var(--font-sans); font-size: 0.92rem; font-weight: 500;
  color: var(--ink-soft); white-space: nowrap;
  transition: transform .25s cubic-bezier(.2,.7,.2,1), border-color .25s, color .25s, background .25s, box-shadow .25s;
}
.chip:hover {
  transform: translateY(-4px);
  border-color: var(--ink); color: var(--ink); background: var(--bg);
  box-shadow: var(--shadow-soft);
}
.chip-dot {
  width: 7px; height: 7px; border-radius: 50%; background: var(--accent);
  opacity: 0.5; flex: none; transition: opacity .25s, transform .25s;
}
.chip:hover .chip-dot { opacity: 1; transform: scale(1.25); }
.chip-logo { width: 17px; height: 17px; flex: none; opacity: 0.55; object-fit: contain; transition: opacity .25s; }
.chip:hover .chip-logo { opacity: 1; }
.builton-cred a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; transition: color .2s; }
.builton-cred a:hover { color: var(--accent); }

/* Credibility line (reused under Built on) */
.builton-cred {
  margin: 1.6rem 0 0; text-align: center;
  font-family: var(--font-sans); font-size: 0.74rem;
  letter-spacing: 0.04em; color: var(--muted);
  display: flex; align-items: center; justify-content: center; gap: 0.6rem; flex-wrap: wrap;
}
.builton-cred-mark {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent); display: inline-block; flex: none;
}

@media (prefers-reduced-motion: reduce) {
  .marq-track { animation: none; flex-wrap: wrap; width: auto; justify-content: center; }
  .marq { -webkit-mask-image: none; mask-image: none; }
}
@media (max-width: 640px) {
  .stack-band { padding: 3.25rem 0; }
  .int-band { padding: 3.75rem 0; }
  .stack-head { margin-bottom: 1.8rem; }
  .stack-head--lg { margin-bottom: 2.2rem; }
  .chip { font-size: 0.82rem; padding: 0.5rem 0.9rem; gap: 0.45rem; margin-right: 0.5rem; }
  .marq-track { animation-duration: 32s; }
  .builton-cred { font-size: 0.68rem; margin-top: 1.2rem; }
}

/* ── Footer ── */
@media (max-width: 640px) {
  .footer-rich { padding: 3rem 0 1.5rem; }
  .footer-now-grid { grid-template-columns: 1fr !important; gap: 0.75rem !important; }
  .footer-bottom { flex-direction: column !important; gap: 0.4rem !important; text-align: center; }
  .footer-grid { gap: 2rem !important; }
}

/* ── CTA after cases ── */
@media (max-width: 640px) {
  .cta-after-cases {
    padding: 2rem 1.5rem !important;
  }
}

/* ── Touch targets — minimum 44px on coarse pointer ── */
@media (hover: none) and (pointer: coarse) {
  .btn, .btn-primary, .chat-cta-btn { min-height: 48px; }
  .pf-card-link { min-height: 44px; display: inline-flex; align-items: center; }
  .nav-link, .mega-link { min-height: 44px; }
  select, input[type="text"], input[type="email"], input[type="url"] {
    min-height: 48px;
    font-size: 16px; /* prevents iOS auto-zoom on focus */
  }
}

/* ── Smooth momentum scroll on all scroll containers ── */
.reviews-grid, .trust-badges, .chat-log, .mobile-panel {
  -webkit-overflow-scrolling: touch;
}

/* ═══════════════════════════════════════════════════════════════
   3D HERO CARD STACK
   ═══════════════════════════════════════════════════════════════ */

.stack-scene {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3.2;
  perspective: 1100px;
  perspective-origin: 50% 40%;
  cursor: grab;
  user-select: none;
}
.stack-scene:active { cursor: grabbing; }

/* ── Individual cards ── */
.stack-card {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transition: transform 0.65s cubic-bezier(0.23, 1, 0.32, 1),
              box-shadow 0.65s cubic-bezier(0.23, 1, 0.32, 1),
              opacity 0.5s ease;
  border-radius: 14px;
  will-change: transform;
}

.stack-card-inner {
  width: 100%;
  height: 100%;
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  box-shadow:
    0 2px 0 rgba(255,255,255,0.8) inset,
    0 25px 50px -15px rgba(26,22,18,0.22),
    0 2px 4px rgba(26,22,18,0.06);
}

/* Default stacked positions — 10 cards (only top 4 visually matter) */
.stack-card--1  { transform: rotateX(4deg) rotateY(-8deg) translateZ(0px)    translateX(0px)  translateY(0px);  z-index: 10; }
.stack-card--2  { transform: rotateX(4deg) rotateY(-8deg) translateZ(-22px)  translateX(13px) translateY(11px); z-index: 9;  opacity: 0.85; }
.stack-card--3  { transform: rotateX(4deg) rotateY(-8deg) translateZ(-44px)  translateX(24px) translateY(20px); z-index: 8;  opacity: 0.65; }
.stack-card--4  { transform: rotateX(4deg) rotateY(-8deg) translateZ(-66px)  translateX(34px) translateY(28px); z-index: 7;  opacity: 0.45; }
.stack-card--5  { transform: rotateX(4deg) rotateY(-8deg) translateZ(-88px)  translateX(42px) translateY(34px); z-index: 6;  opacity: 0.20; }
.stack-card--6  { transform: rotateX(4deg) rotateY(-8deg) translateZ(-108px) translateX(50px) translateY(40px); z-index: 5;  opacity: 0.08; }
.stack-card--7  { transform: rotateX(4deg) rotateY(-8deg) translateZ(-120px) translateX(55px) translateY(44px); z-index: 4;  opacity: 0; }
.stack-card--8  { transform: rotateX(4deg) rotateY(-8deg) translateZ(-120px) translateX(55px) translateY(44px); z-index: 3;  opacity: 0; }
.stack-card--9  { transform: rotateX(4deg) rotateY(-8deg) translateZ(-120px) translateX(55px) translateY(44px); z-index: 2;  opacity: 0; }
.stack-card--10 { transform: rotateX(4deg) rotateY(-8deg) translateZ(-120px) translateX(55px) translateY(44px); z-index: 1;  opacity: 0; }

/* Active (front) card gets full lift */
.stack-card.is-front {
  box-shadow:
    0 2px 0 rgba(255,255,255,0.9) inset,
    0 50px 80px -20px rgba(26,22,18,0.28),
    0 4px 8px rgba(26,22,18,0.08);
}

/* ── Card chrome bar ── */
.stack-card-chrome {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 10px 12px;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  flex-shrink: 0;
}
.scc-dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--line);
}
.scc-dot:nth-child(1) { background: #C2614A; }
.scc-dot:nth-child(2) { background: #C8A24A; }
.scc-dot:nth-child(3) { background: #6E8B5F; }
.scc-url {
  flex: 1;
  margin-left: 10px;
  padding: 3px 8px;
  background: var(--bg-soft);
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: #5b5146;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
html[data-theme="dark"] .scc-url {
  color: #ded7cc;
  background: rgba(244, 240, 234, 0.08);
}

/* ── Screenshot area ── */
.stack-card-img {
  display: block;
  width: 100%;
  flex: 1;
  object-fit: cover;
  object-position: top center;
  background-size: cover;
  background-position: top center;
  background-color: var(--surface);
  min-height: 0;
  transition: background-position 3s ease, opacity .35s ease;
}
.stack-card.is-front .stack-card-img {
  object-position: bottom center;
  background-position: bottom center;
}

/* ── Caption footer ── */
.stack-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: rgba(26,22,18,0.88);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  flex-shrink: 0;
}
.scf-name {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--bg);
  letter-spacing: -0.01em;
}
.scf-tag {
  font-family: var(--font-sans);
  font-size: 0.62rem;
  font-weight: 500;
  color: rgba(244,240,234,0.65);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

/* ── Floating badges ── */
.stack-badge {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 6px 11px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--ink);
  box-shadow: 0 4px 16px rgba(26,22,18,0.1);
  z-index: 10;
  animation: badgeFloat 3s ease-in-out infinite alternate;
  pointer-events: none;
}
.stack-badge svg { color: var(--accent); flex-shrink: 0; }
.stack-badge--tl {
  top: -14px;
  left: -10px;
  animation-delay: 0s;
}
.stack-badge--br {
  bottom: 52px;
  right: -14px;
  animation-delay: 1.5s;
}
@keyframes badgeFloat {
  from { transform: translateY(0px); }
  to   { transform: translateY(-6px); }
}

/* ── Mobile: crossfade gallery — no 3D transforms ── */
@media (max-width: 768px) {
  .hero-sidecar { display: block; position: static; }

  .stack-scene {
    perspective: none !important;
    position: relative;
    width: 100%;
    aspect-ratio: 3 / 2;
    border-radius: var(--r-xl);
    overflow: hidden;
    background: var(--surface);
    box-shadow: 0 4px 32px -8px rgba(26,22,18,.18);
  }

  /* All cards stack on top of each other, hidden by default */
  [data-stack-card] {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    transform: none !important;
    opacity: 0 !important;
    transition: opacity .7s ease !important;
    animation: none !important;
    border-radius: 0 !important;
    z-index: 1 !important;
  }

  /* Only the front card is visible */
  [data-stack-card].is-front {
    opacity: 1 !important;
    z-index: 2 !important;
  }

  .stack-card-inner {
    border-radius: 0;
    box-shadow: none;
    height: 100%;
  }

  .stack-card-chrome { display: none; }

  .stack-card-img {
    flex: 1;
    min-height: 0;
  }

  .stack-card-foot {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: 10px 14px;
  }

  /* Progress dots */
  .stack-scene::after {
    content: '';
    position: absolute;
    bottom: 52px; left: 50%;
    transform: translateX(-50%);
    display: block;
    z-index: 10;
  }

  .stack-badge--tl { top: 12px; left: 12px; }
  .stack-badge--br { bottom: 52px; right: 12px; }
}

@media (max-width: 768px) {
  .hero-sidecar { display: none; }
}

/* ═══════════════════════════════════════════════════════════════
   GLASS CONVERSATION POPUP (mobile)
   ═══════════════════════════════════════════════════════════════ */

.conv-popup {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 300;
  align-items: flex-end;
}
@media (max-width: 860px) { .conv-popup { display: flex; } }

.conv-popup-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(26,22,18,0.5);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity .32s ease;
}
.conv-popup.open .conv-popup-backdrop {
  opacity: 1;
}

.conv-popup-sheet {
  position: relative;
  z-index: 1;
  width: 100%;
  background: rgba(253,250,246,0.82);
  backdrop-filter: blur(32px) saturate(200%);
  -webkit-backdrop-filter: blur(32px) saturate(200%);
  border-top: 1px solid rgba(255,255,255,0.6);
  border-radius: 24px 24px 0 0;
  padding: 0 1.5rem calc(2.5rem + env(safe-area-inset-bottom, 0px));
  box-shadow:
    0 -2px 0 rgba(255,255,255,0.9) inset,
    0 -32px 64px rgba(26,22,18,0.18);
  transform: translateY(100%);
  transition: transform .42s cubic-bezier(.22,1,.36,1);
}
.conv-popup.open .conv-popup-sheet {
  transform: translateY(0);
}

/* Not open = invisible + no pointer events */
.conv-popup:not(.open) {
  pointer-events: none;
}

.conv-popup-handle {
  width: 40px; height: 4px;
  background: rgba(26,22,18,0.18);
  border-radius: 100px;
  margin: 1rem auto 1.75rem;
}

.conv-popup-close {
  position: absolute;
  top: 0.8rem;
  right: 1rem;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(26,22,18,0.12);
  border-radius: 50%;
  background: rgba(253,250,246,0.76);
  color: var(--ink);
  cursor: pointer;
}

.conv-popup-close:hover,
.conv-popup-close:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
}

.conv-popup-avatar {
  width: 52px; height: 52px;
  border-radius: 14px;
  background: var(--ink);
  color: var(--bg);
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.conv-popup-title {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.2;
  margin-bottom: 0.6rem;
}

.conv-popup-sub {
  font-family: var(--font-sans);
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.55;
  margin-bottom: 1.75rem;
}

.conv-popup-actions {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-bottom: 1.25rem;
}

.conv-popup-btn-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0.95rem 1.25rem;
  background: var(--ink);
  color: var(--bg) !important;
  border: none;
  border-radius: 12px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background .15s ease, transform .12s ease;
  -webkit-tap-highlight-color: transparent;
}
.conv-popup-btn-primary:active { background: var(--accent); transform: scale(0.98); }

.conv-popup-btn-secondary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0.9rem 1.25rem;
  background: rgba(26,22,18,0.06);
  color: var(--ink);
  border: 1px solid rgba(26,22,18,0.12);
  border-radius: 12px;
  font-family: var(--font-sans);
  font-size: 0.92rem;
  font-weight: 500;
  cursor: pointer;
  transition: background .15s ease, transform .12s ease;
  -webkit-tap-highlight-color: transparent;
}
.conv-popup-btn-secondary:active { background: rgba(26,22,18,0.1); transform: scale(0.98); }

.conv-popup-btn-ghost {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0.7rem;
  color: var(--muted);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: 8px;
  transition: color .15s ease;
  -webkit-tap-highlight-color: transparent;
}
.conv-popup-btn-ghost:active { color: var(--accent); }

.conv-popup-note {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  color: var(--muted);
  text-align: center;
  letter-spacing: 0.02em;
}

/* Inline form inside popup */
.conv-popup-back {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: none;
  border: none;
  color: var(--muted);
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}
.conv-popup-back:active { color: var(--ink); }

.conv-inline-form {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-bottom: 0.75rem;
}
.conv-field {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  background: var(--bg);
  font-family: var(--font-sans);
  font-size: 16px;
  color: var(--ink);
  outline: none;
  -webkit-appearance: none;
  appearance: none;
  transition: border-color .15s;
}
.conv-field:focus { border-color: var(--accent); }
.conv-field::placeholder { color: var(--muted); }
.conv-field-ta { resize: none; line-height: 1.5; }
.conv-form-error {
  font-size: 0.78rem;
  color: var(--red, #991B1B);
  padding: 0.2rem 0;
}

/* Success state */
.conv-success-check {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: #D1FAE5;
  color: #065F46;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
}

/* Hide header CTA on mobile — redundant with the floating bottom bar */
@media (max-width: 640px) {
  .nav-bar .btn-primary { display: none; }
}

/* ═══════════════════════════════════════════════════════════════
   DARK THEME  (toggle: light / dark / device — default device)
   Light mode is untouched; these only apply on [data-theme="dark"].
   ═══════════════════════════════════════════════════════════════ */
html[data-theme="dark"] {
  --bg:        #221D17;
  --bg-soft:   #2B251D;
  --surface:   #332C23;
  --ink:       #F3EEE4;
  --ink-soft:  #DED6C8;
  --muted:     #B4AA98;
  --muted-2:   #8B8372;
  --line:      #463D31;
  --line-soft: #3A3228;
  --accent:        #D77A55;
  --accent-deep:   #C0623B;
  --accent-soft:   #3A271B;
  --accent-hover:  #E58A65;
  --green:     #8DAC70;
  --gold:      #D2AC68;
  --shadow-soft: 0 1px 0 rgba(0,0,0,0.30), 0 8px 24px -14px rgba(0,0,0,0.55);
  --shadow-card: 0 1px 2px rgba(0,0,0,0.30), 0 20px 48px -28px rgba(0,0,0,0.60);
  --shadow-pop:  0 1px 2px rgba(0,0,0,0.35), 0 30px 60px -22px rgba(0,0,0,0.65);
  color-scheme: dark;
}
/* Hardcoded light page-chrome → dark equivalents */
html[data-theme="dark"] .nav-bar { background: rgba(34,29,23,0.80); }
html[data-theme="dark"] .nav-bar.scrolled { background: rgba(34,29,23,0.94); }
html[data-theme="dark"] .mob-bar { background: rgba(34,29,23,0.92); }
html[data-theme="dark"] .conv-popup-sheet { background: rgba(43,37,29,0.94); }
html[data-theme="dark"] .cookie-banner { background: var(--surface); }
/* Black simple-icon SVGs would vanish on dark → invert to light */
html[data-theme="dark"] .chip-logo { filter: invert(0.9) brightness(1.15); }

/* ── Inverted "ink" bands: pin back to true dark in dark mode ─────── */
html[data-theme="dark"] [style*="background:var(--ink)"],
html[data-theme="dark"] [style*="background: var(--ink)"] {
  background: #15110B !important;
  color: var(--ink) !important;
}
html[data-theme="dark"] [style*="background:var(--ink)"] [style*="color:var(--bg)"],
html[data-theme="dark"] [style*="background: var(--ink)"] [style*="color:var(--bg)"],
html[data-theme="dark"] [style*="background:var(--ink)"] [style*="color: var(--bg)"],
html[data-theme="dark"] [style*="background: var(--ink)"] [style*="color: var(--bg)"] {
  color: var(--ink) !important;
}
html[data-theme="dark"] [style*="background:var(--ink)"] [style*="background:var(--bg)"],
html[data-theme="dark"] [style*="background: var(--ink)"] [style*="background:var(--bg)"],
html[data-theme="dark"] [style*="background:var(--ink)"] [style*="background: var(--bg)"],
html[data-theme="dark"] [style*="background: var(--ink)"] [style*="background: var(--bg)"] {
  background: var(--ink) !important;
  color: #15110B !important;
}
/* Portfolio filter bar hardcoded light bg */
html[data-theme="dark"] .pf-filter-bar { background: rgba(28,23,18,.95) !important; }

/* ── Inverted "ink" bands ──────────────────────────────────────────
   Sections/cards built as dark bands in light mode use inline
   background:var(--ink);color:var(--bg). In dark mode those tokens
   flip — the band turns cream and the (hardcoded-light) text vanishes.
   Pin them back to a true dark band with light text. */
html[data-theme="dark"] [style*="background:var(--ink)"],
html[data-theme="dark"] [style*="background: var(--ink)"] {
  background: #15110B !important;
  color: var(--ink) !important;
}
/* Text that used color:var(--bg) (now dark) inside those bands → light */
html[data-theme="dark"] [style*="background:var(--ink)"] [style*="color:var(--bg)"],
html[data-theme="dark"] [style*="background: var(--ink)"] [style*="color:var(--bg)"],
html[data-theme="dark"] [style*="background:var(--ink)"] [style*="color: var(--bg)"],
html[data-theme="dark"] [style*="background: var(--ink)"] [style*="color: var(--bg)"] {
  color: var(--ink) !important;
}
/* Light "cream" buttons (bg:var(--bg)) inside those bands → keep them readable */
html[data-theme="dark"] [style*="background:var(--ink)"] [style*="background:var(--bg)"],
html[data-theme="dark"] [style*="background: var(--ink)"] [style*="background:var(--bg)"],
html[data-theme="dark"] [style*="background:var(--ink)"] [style*="background: var(--bg)"],
html[data-theme="dark"] [style*="background: var(--ink)"] [style*="background: var(--bg)"] {
  background: var(--ink) !important;
  color: #15110B !important;
}

/* ── Portfolio filter bar: hardcoded light background didn't adapt ── */
html[data-theme="dark"] .pf-filter-bar { background: rgba(28,23,18,.95) !important; }

/* Smooth the flip */
html { transition: background-color .3s ease, color .3s ease; }

/* ── Scroll progress bar (injected into .nav-bar by main.js) ──
   Sits flush along the bottom edge of the menu bar, fills + glows
   as the page is scrolled from top to bottom. */
.scroll-progress {
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 2px;
  pointer-events: none;
  overflow: hidden;
}
.scroll-progress__fill {
  height: 100%;
  width: 0;
  transform-origin: left center;
  background: linear-gradient(90deg, var(--accent-deep), var(--accent));
  box-shadow: 0 0 6px 0 var(--accent), 0 0 12px 0 color-mix(in srgb, var(--accent) 55%, transparent);
  border-radius: 0 2px 2px 0;
  will-change: width;
}
@media (prefers-reduced-motion: no-preference) {
  .scroll-progress__fill { transition: width .12s ease-out; }
}

/* ── Theme toggle control (injected into the nav by main.js) ── */
.theme-toggle { display:inline-flex; align-items:center; gap:1px; padding:3px;
  border:1px solid var(--line); border-radius:100px; background:var(--surface); margin-left:0.4rem; }
.theme-opt { display:inline-flex; align-items:center; justify-content:center; width:30px; height:30px;
  border:0; background:none; border-radius:50%; color:var(--muted); cursor:pointer;
  transition:color .2s, background .2s; -webkit-tap-highlight-color:transparent; }
.theme-opt:hover { color:var(--ink); }
.theme-opt.is-active { background:var(--bg); color:var(--accent); box-shadow:0 1px 2px rgba(0,0,0,0.10); }
@media (max-width:880px){ .theme-toggle{ margin-left:0; margin-right:0.4rem; padding:3px; } .theme-opt{ width:34px; height:34px; } }

/* ═══════════════════════════════════════════════════════════════
   Location SEO and AI calling pages
   ═══════════════════════════════════════════════════════════════ */
.loc-hero {
  padding: clamp(5.8rem, 8vw, 8rem) 0 clamp(4.2rem, 7vw, 6.5rem);
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.loc-hero.ai-hero { background: var(--bg); }
.region-hero {
  padding: clamp(4.8rem, 6vw, 6.2rem) 0 clamp(3.6rem, 5vw, 5rem);
}
.region-hero .loc-hero-copy .h-display {
  max-width: 15.5ch;
  font-size: clamp(3rem, 6.4vw, 6.2rem);
  line-height: 0.96;
}
.region-hero .loc-hero-copy .lead { max-width: 74ch; }
.loc-hero-copy { max-width: 980px; }
.loc-hero-copy .h-display {
  margin: 1.1rem 0 0;
  max-width: 12.5ch;
}
.loc-hero-copy .lead { margin: 1.6rem 0 0; }
.loc-breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
  color: var(--muted);
  font-family: var(--font-sans);
  font-size: 0.78rem;
}
.loc-breadcrumb a {
  color: var(--muted);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
.loc-breadcrumb a:hover { color: var(--ink); }
.loc-breadcrumb span:last-child { color: var(--ink); }
.loc-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 2.2rem;
}
.loc-section-head {
  max-width: 760px;
  margin-bottom: 2.2rem;
}
.loc-section-head .h-1,
.loc-section-head h2 { margin: 1rem 0 0; }
.loc-section-head p {
  max-width: 64ch;
  margin: 1rem 0 0;
  color: var(--ink-soft);
}
.loc-grid {
  display: grid;
  gap: 1rem;
}
.loc-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.loc-grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.loc-card {
  min-width: 0;
  padding: clamp(1.35rem, 2vw, 1.8rem);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
}
.loc-card h3 {
  margin: 0.55rem 0 0.55rem;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(1.1rem, 1.6vw, 1.34rem);
  font-weight: 500;
  line-height: 1.16;
  letter-spacing: -0.02em;
}
.loc-card p {
  margin: 0;
  color: var(--ink-soft);
  font-family: var(--font-sans);
  font-size: 0.94rem;
  line-height: 1.62;
}
.loc-card-link {
  display: block;
  transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease, background .22s ease;
}
.loc-card-link:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: var(--shadow-card);
}
.loc-card-kicker {
  display: block;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.loc-band {
  padding: 6rem 0;
  background: var(--bg-soft);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.loc-split {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}
.loc-split .h-1 { margin: 1rem 0 0; }
.loc-flow {
  display: grid;
  border-top: 1px solid var(--line);
}
.loc-flow div {
  display: grid;
  grid-template-columns: minmax(8rem, 0.34fr) minmax(0, 1fr);
  gap: 1.25rem;
  padding: 1.15rem 0;
  border-bottom: 1px solid var(--line);
}
.loc-flow strong {
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -0.01em;
}
.loc-flow span { color: var(--ink-soft); }
.loc-inline-links {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
  margin-top: 2rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-family: var(--font-sans);
  font-size: 0.9rem;
}
.loc-inline-links a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}
.loc-inline-links a:hover { color: var(--accent); }
.loc-faq {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}
.loc-faq .h-1 { margin: 1rem 0 0; }
.footer-rich ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.7rem;
}
@media (max-width: 980px) {
  .loc-grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .loc-grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .loc-split,
  .loc-faq { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .loc-hero { padding: 5.4rem 0 3.8rem; }
  .region-hero { padding: 4.8rem 0 3.4rem; }
  .region-hero .loc-hero-copy .h-display { font-size: clamp(2.55rem, 13vw, 4.4rem); line-height: 0.98; }
  .loc-hero-copy .h-display { max-width: 100%; }
  .loc-grid-3,
  .loc-grid-4 { grid-template-columns: 1fr; }
  .loc-band { padding: 4.2rem 0; }
  .loc-flow div {
    grid-template-columns: 1fr;
    gap: 0.35rem;
  }
  .loc-actions .btn {
    width: 100%;
    white-space: normal;
  }
}

/* ═══════════════════════════════════════════════════════════════
   Blog comments — high-end, theme-aware (used on blog posts)
   ═══════════════════════════════════════════════════════════════ */
.comments { padding: 1rem 0 6rem; }
.comments .container-narrow { max-width: 760px; }
.comments-head { padding-top: 2.5rem; border-top: 1px solid var(--line); margin-bottom: 2rem; }
.comments-head h2 { font-family: var(--font-display); letter-spacing: -0.03em; margin: 0; font-size: clamp(1.6rem, 3vw, 2.1rem); }
.comments-count { color: var(--muted); font-weight: 400; font-size: 0.7em; margin-left: 0.4rem; }
.comments-sub { color: var(--muted); margin: 0.5rem 0 0; font-size: 0.95rem; }

.comments-list { list-style: none; margin: 0 0 2.5rem; padding: 0; display: grid; gap: 1.4rem; }
.comments-empty { color: var(--muted); font-style: italic; margin: 0 0 2rem; }
.comment { display: grid; grid-template-columns: 44px 1fr; gap: 1rem; align-items: start;
  animation: comment-in .4s cubic-bezier(.2,.7,.2,1) both; }
.comment--new { animation: comment-pop .5s cubic-bezier(.2,.7,.2,1) both; }
@keyframes comment-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes comment-pop { 0% { opacity: 0; transform: translateY(-6px) scale(.98); } 100% { opacity: 1; transform: none; } }
.comment-avatar {
  width: 44px; height: 44px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-sans); font-weight: 700; font-size: 0.92rem; letter-spacing: 0.02em;
  color: var(--accent);
  background: hsl(var(--h, 20) 38% 92%);
  box-shadow: inset 0 0 0 1px hsl(var(--h, 20) 40% 84%);
  user-select: none;
}
html[data-theme="dark"] .comment-avatar { background: hsl(var(--h, 20) 30% 20%); color: var(--accent-hover); box-shadow: inset 0 0 0 1px hsl(var(--h, 20) 30% 30%); }
.comment-main { min-width: 0; }
.comment-meta { display: flex; align-items: baseline; gap: 0.6rem; flex-wrap: wrap; }
.comment-name { font-family: var(--font-sans); font-weight: 600; color: var(--ink); font-size: 0.96rem; }
.comment-time { font-size: 0.78rem; color: var(--muted-2); }
.comment-text { margin: 0.35rem 0 0; color: var(--ink-soft); line-height: 1.66; font-size: 1rem;
  overflow-wrap: anywhere; }

/* Form */
.comment-form { border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface);
  padding: 1.5rem; box-shadow: var(--shadow-soft); }
.cf-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; margin-bottom: 0.75rem; }
.cf-input { width: 100%; font-family: var(--font-sans); font-size: 1rem; color: var(--ink);
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-md);
  padding: 0.8rem 0.95rem; transition: border-color .2s, box-shadow .2s; -webkit-appearance: none; }
.cf-input::placeholder { color: var(--muted-2); }
.cf-input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.cf-text { resize: vertical; min-height: 110px; line-height: 1.6; }
.cf-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.cf-foot { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 1rem; flex-wrap: wrap; }
.cf-note { font-size: 0.82rem; color: var(--muted); margin: 0; }
.cf-note--err { color: var(--accent-deep); }
html[data-theme="dark"] .cf-note--err { color: var(--accent-hover); }
.cf-submit { white-space: nowrap; }
.cf-submit.is-loading { opacity: 0.6; pointer-events: none; }
.cf-submit:disabled { opacity: 0.6; cursor: default; }
@media (max-width: 560px) { .cf-row { grid-template-columns: 1fr; } .comment { grid-template-columns: 38px 1fr; gap: 0.8rem; } .comment-avatar { width: 38px; height: 38px; } }

/* ── Blog: filter pills + "All Posts" card grid ──────────────────── */
button.kbd-pill { transition: color .18s, background .18s, border-color .18s; }
button.kbd-pill:hover { color: var(--ink); border-color: var(--muted); }
button.kbd-pill.is-active {
  background: var(--ink); color: var(--bg);
  border-color: var(--ink);
}

.post-card { position: relative; display: flex; min-width: 0; }
.post-card-link {
  display: flex; flex-direction: column; width: 100%; min-width: 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  overflow: hidden;
  text-decoration: none; color: inherit;
  transition: transform .28s cubic-bezier(.2,.7,.2,1), box-shadow .28s ease, border-color .28s ease;
}
.post-card-link:hover {
  transform: translateY(-3px);
  border-color: var(--accent);
  box-shadow: var(--shadow-card);
}
.post-card-img {
  display: block; width: 100%; height: auto; aspect-ratio: 16 / 9;
  object-fit: cover; background: var(--bg-soft);
  border-bottom: 1px solid var(--line);
  transition: transform .4s cubic-bezier(.2,.7,.2,1);
}
.post-card-link:hover .post-card-img { transform: scale(1.025); }
.post-card-body {
  display: flex; flex-direction: column; flex: 1;
  padding: 1.35rem 1.4rem 1.45rem;
}
.post-hero-img {
  display: block; width: 100%; height: auto; aspect-ratio: 16 / 9;
  object-fit: cover; border-radius: var(--r-lg);
  border: 1px solid var(--line); margin: 0.5rem 0 0;
}
.post-card-meta {
  display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 0.72rem; color: var(--muted);
  margin-bottom: 0.95rem;
}
.post-card-meta time { letter-spacing: 0.01em; }
.post-card-meta .tag-pill { font-size: 0.68rem; padding: 3px 9px; }
.post-card-title {
  font-family: var(--font-serif);
  font-size: clamp(1.18rem, 1.5vw, 1.38rem);
  line-height: 1.26; font-weight: 500;
  letter-spacing: -0.012em; color: var(--ink);
  margin: 0 0 0.65rem;
  transition: color .2s ease;
}
.post-card-link:hover .post-card-title { color: var(--accent); }
.post-card-excerpt {
  font-family: var(--font-sans);
  font-size: 0.92rem; line-height: 1.62;
  color: var(--muted); margin: 0 0 1.4rem;
}
.post-card-cta {
  margin-top: auto;
  font-family: var(--font-sans);
  font-size: 0.82rem; font-weight: 500;
  color: var(--accent);
  transition: transform .22s ease;
}
.post-card-link:hover .post-card-cta { transform: translateX(4px); }
.blog-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 2.4rem;
}
.blog-page-btn {
  min-width: 2.35rem;
  height: 2.35rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink-soft);
  font-family: var(--font-mono);
  font-size: 0.76rem;
  cursor: pointer;
  transition: background .18s ease, color .18s ease, border-color .18s ease, transform .18s ease;
}
.blog-page-btn:hover {
  transform: translateY(-1px);
  border-color: var(--muted);
  color: var(--ink);
}
.blog-page-btn.is-active {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.blog-page-btn[disabled] {
  cursor: not-allowed;
  opacity: 0.42;
  transform: none;
}
.blog-page-status {
  width: 100%;
  margin-top: 0.35rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-align: center;
}

/* Portfolio upgrade: dark, image-led selected work */
.home-portfolio-stage {
  position: relative;
  overflow: hidden;
  border-top: 0;
  background:
    linear-gradient(180deg, #171717 0%, #111111 54%, #171310 100%);
  color: #F7F0E8;
}
.home-portfolio-stage::before {
  content: "SELECTED WORK";
  position: absolute;
  left: -0.08em;
  top: 0.12em;
  font-family: var(--font-display);
  font-size: 9rem;
  line-height: 0.8;
  font-weight: 600;
  letter-spacing: 0;
  color: rgba(247,240,232,0.055);
  white-space: nowrap;
  pointer-events: none;
}
.home-portfolio-stage .container {
  position: relative;
  z-index: 1;
}
.home-portfolio-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 4rem;
}
.home-portfolio-copy {
  max-width: 720px;
}
.home-portfolio-stage .eyebrow,
.portfolio-hero-stage .eyebrow {
  color: var(--muted);
}
.home-portfolio-stage .eyebrow::before,
.portfolio-hero-stage .eyebrow::before {
  background: var(--muted);
}
.home-portfolio-stage .h-1 {
  max-width: 12.4em;
  margin: 1.2rem 0 0;
  color: #F7F0E8;
  font-size: 3.2rem;
  line-height: 1.02;
  letter-spacing: 0;
}
.home-portfolio-lead {
  max-width: 48ch;
  margin: 1.2rem 0 0;
  font-family: var(--font-serif);
  font-size: 1.08rem;
  line-height: 1.62;
  color: rgba(247,240,232,0.72);
}
.home-portfolio-link {
  color: #F7F0E8;
}
.home-portfolio-stage .pf-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2rem 2.15rem;
  align-items: start;
}
.home-portfolio-stage .pf-card,
.home-portfolio-stage .pf-card--featured {
  grid-column: auto;
  display: flex;
  flex-direction: column;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.home-portfolio-stage .pf-card:nth-child(even),
.home-portfolio-stage .pf-card--featured:nth-child(even) {
  margin-top: 4rem;
}
.home-portfolio-stage .pf-card:hover,
.home-portfolio-stage .pf-card--featured:hover {
  transform: translateY(-4px);
  box-shadow: none;
  border-color: transparent;
}
.home-portfolio-stage .pf-card-img,
.home-portfolio-stage .pf-card--featured .pf-card-img {
  height: auto;
  min-height: 0;
  aspect-ratio: 16 / 11;
  border: 1px solid rgba(247,240,232,0.14);
  border-radius: 8px;
  background: #222;
  box-shadow: 0 22px 70px -48px rgba(0,0,0,0.9);
}
.home-portfolio-stage .pf-card-img img {
  filter: saturate(0.94) contrast(1.02);
}
.home-portfolio-stage .pf-card-body,
.home-portfolio-stage .pf-card--featured .pf-card-body {
  padding: 1.15rem 0 0;
}
.home-portfolio-stage .pf-card-tag {
  color: rgba(247,240,232,0.58);
  letter-spacing: 0.14em;
}
.home-portfolio-stage .pf-card-name,
.home-portfolio-stage .pf-card--featured .pf-card-name {
  color: #F7F0E8;
  font-size: 1.65rem;
  line-height: 1.06;
  letter-spacing: 0;
}
.home-portfolio-stage .pf-card-desc,
.home-portfolio-stage .pf-card--featured .pf-card-desc {
  max-width: 54ch;
  color: rgba(247,240,232,0.72);
  font-size: 0.98rem;
  line-height: 1.58;
}
.home-portfolio-stage .pf-card-foot {
  border-top-color: rgba(247,240,232,0.16);
}
.home-portfolio-stage .pf-card-metric {
  color: rgba(247,240,232,0.6);
}
.home-portfolio-stage .pf-card-metric strong,
.home-portfolio-stage .pf-card-link {
  color: #F7F0E8;
}
.home-portfolio-stage .pf-card-num {
  background: rgba(17,17,17,0.72);
  color: #F7F0E8;
}
.home-portfolio-full {
  margin-top: 3.5rem;
  text-align: center;
}
.home-portfolio-full p {
  margin: 0 0 1.5rem;
  font-family: var(--font-sans);
  font-size: 0.86rem;
  color: rgba(247,240,232,0.64);
}
.home-portfolio-full .btn-primary {
  padding: 0.9rem 2.2rem;
  font-size: 0.86rem;
  background: #F7F0E8;
  color: #171717;
  border-color: #F7F0E8;
}
.home-portfolio-stage .cta-after-cases {
  margin-top: 5rem;
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 2.5rem;
  align-items: center;
  padding: 2.5rem;
  border: 1px solid rgba(247,240,232,0.14);
  border-radius: 8px;
  background: rgba(247,240,232,0.06);
}
.home-portfolio-stage .cta-after-kicker {
  margin: 0 0 1rem;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  color: rgba(247,240,232,0.62);
  text-transform: uppercase;
  letter-spacing: 0.18em;
}
.home-portfolio-stage .cta-after-cases .h-2 {
  margin: 0 0 0.75rem;
  color: #F7F0E8;
  letter-spacing: 0;
}
.home-portfolio-stage .cta-after-cases p:last-child {
  max-width: 56ch;
  margin: 0;
  font-family: var(--font-serif);
  font-size: 1.05rem;
  line-height: 1.6;
  color: rgba(247,240,232,0.78);
}
.home-portfolio-stage .cta-after-cases .btn {
  justify-self: end;
  align-self: center;
  padding: 1rem 1.6rem;
  background: #F7F0E8;
  color: #171717;
}

.portfolio-page {
  background: #111111;
}
body.portfolio-page.cursor-ready,
body.portfolio-page.cursor-ready a,
body.portfolio-page.cursor-ready button,
body.portfolio-page.cursor-ready input,
body.portfolio-page.cursor-ready textarea,
body.portfolio-page.cursor-ready select,
body.portfolio-page.cursor-ready [role="button"] {
  cursor: auto;
}
body.portfolio-page .cursor-dot,
body.portfolio-page .cursor-ring {
  display: none;
}
.portfolio-hero-stage {
  position: relative;
  overflow: hidden;
  padding: 7.5rem 0 3rem;
  background: var(--bg);
  color: var(--ink);
  border-bottom: 1px solid var(--line);
}
.portfolio-hero-stage::before {
  content: "PORTFOLIO";
  position: absolute;
  left: -0.05em;
  top: 0.16em;
  font-family: var(--font-display);
  font-size: 10rem;
  line-height: 0.78;
  font-weight: 600;
  letter-spacing: 0;
  color: rgba(26,22,18,0.05);
  pointer-events: none;
}
.portfolio-hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.62fr);
  gap: 3rem;
  align-items: end;
  z-index: 1;
}
.portfolio-hero-copy .h-display {
  max-width: 10.8em;
  margin: 1.4rem 0 0;
  color: var(--ink);
  font-size: 4.35rem;
  line-height: 1;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}
.portfolio-hero-copy .lead {
  max-width: 56ch;
  margin-top: 1.6rem;
  color: var(--muted);
}
.portfolio-hero-actions {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  margin-top: 2rem;
  flex-wrap: wrap;
}
.portfolio-hero-actions .btn-primary {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.portfolio-hero-actions .btn-link {
  color: var(--ink);
}
.portfolio-hero-proof {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 1.35rem;
  background: var(--surface);
}
.portfolio-proof-kicker {
  margin: 0 0 0.8rem;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
}
.portfolio-proof-copy {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 1rem;
  line-height: 1.58;
  color: var(--ink);
}
.portfolio-proof-strip {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 1px;
  margin-top: 4rem;
  border: 1px solid var(--line);
  background: var(--line);
}
.portfolio-proof-strip span {
  min-width: 0;
  padding: 1rem 0.8rem;
  background: var(--bg);
  color: var(--muted);
  font-family: var(--font-sans);
  font-size: 0.78rem;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.portfolio-hero-stats {
  position: relative;
  z-index: 1;
  margin-top: 2rem;
  border-color: rgba(247,240,232,0.13);
}
.portfolio-hero-stats .hero-stat {
  border-color: rgba(247,240,232,0.13);
}
.portfolio-hero-stats .bignum {
  color: #F7F0E8;
  letter-spacing: 0;
}
.portfolio-hero-stats .hero-stat-lbl,
.portfolio-hero-stats .bignum-suffix {
  color: rgba(247,240,232,0.62);
}
.portfolio-page .pf-filter-bar {
  top: var(--nav-h, 72px) !important;
  background: rgba(17,17,17,0.94) !important;
  border-top-color: rgba(247,240,232,0.1) !important;
  border-bottom-color: rgba(247,240,232,0.16) !important;
  box-shadow: 0 18px 42px -34px rgba(0,0,0,0.85) !important;
}
.portfolio-page .pf-filter-label,
.portfolio-page .pf-filter-count {
  color: rgba(247,240,232,0.58);
}
.portfolio-page .pf-filter-divider {
  background: rgba(247,240,232,0.16);
}
.portfolio-page .filter-btn {
  background: transparent !important;
  border-color: rgba(247,240,232,0.24) !important;
  color: rgba(247,240,232,0.78) !important;
}
.portfolio-page .filter-btn:hover {
  background: rgba(247,240,232,0.1) !important;
  color: #F7F0E8 !important;
}
.portfolio-page .filter-btn.active {
  background: #F7F0E8 !important;
  color: #111111 !important;
  border-color: #F7F0E8 !important;
}
.portfolio-page .portfolio-search {
  background: rgba(247,240,232,0.08) !important;
  border-color: rgba(247,240,232,0.2) !important;
  color: #F7F0E8 !important;
}
.portfolio-page .portfolio-search::placeholder {
  color: rgba(247,240,232,0.42);
}
.portfolio-work-stage {
  padding: 4rem 0 6.5rem;
  background: #111111;
}
.portfolio-page #workGrid.work-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-auto-rows: auto;
  gap: 3.2rem 2.4rem;
  align-items: start;
}
.portfolio-page .work-card {
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.portfolio-page .work-card:nth-child(even) {
  margin-top: 0;
}
.portfolio-page .work-card:hover {
  transform: translateY(-4px);
  box-shadow: none;
  border-color: transparent;
}
.portfolio-page .work-card-img-link {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(247,240,232,0.14);
  border-radius: 8px;
  background: #222;
  box-shadow: 0 20px 65px -48px rgba(0,0,0,0.9);
}
.portfolio-page .work-card-img {
  aspect-ratio: 16 / 11;
  border-bottom: 0;
  background: #222;
}
.portfolio-page .work-card-img img {
  filter: saturate(0.94) contrast(1.02);
}
.portfolio-page .work-card-body {
  padding: 1.05rem 0 0;
}
.portfolio-page .work-card-meta {
  margin-bottom: 0.48rem;
  color: rgba(247,240,232,0.56);
  letter-spacing: 0.12em;
}
.portfolio-page .work-card-name {
  margin-bottom: 0.4rem;
  color: #F7F0E8;
  font-size: 1.62rem;
  line-height: 1.06;
  letter-spacing: 0;
}
.portfolio-page .work-card-tag {
  max-width: 48ch;
  color: rgba(247,240,232,0.68);
}
.portfolio-page .work-card-actions {
  margin-top: 1rem;
  padding-top: 0.85rem;
  border-top-color: rgba(247,240,232,0.14);
}
.portfolio-page .work-card-cs {
  color: #F7F0E8;
  border-bottom-color: rgba(247,240,232,0.72);
}
.portfolio-page .work-card-cs:hover {
  color: #F7F0E8;
  border-bottom-color: #F7F0E8;
}
.portfolio-page .work-card-live {
  color: rgba(247,240,232,0.52);
}
.portfolio-page .work-card-live:hover {
  color: #F7F0E8;
}
.portfolio-page .work-card-badge {
  background: rgba(17,17,17,0.76);
  color: #F7F0E8;
}
.portfolio-page .work-card-placeholder {
  background: linear-gradient(145deg, #212121 0%, #151515 100%);
}
.portfolio-page .work-card-placeholder::before {
  border-color: rgba(247,240,232,0.16);
}
.portfolio-page .work-card-placeholder-name {
  color: #F7F0E8;
}
.portfolio-page .work-card-placeholder-label {
  color: rgba(247,240,232,0.58);
}

/* Premium mockup-frame thumbnails for selected work and portfolio cards */
.home-portfolio-stage .pf-card-img,
.home-portfolio-stage .pf-card--featured .pf-card-img,
.portfolio-page .work-card-img-link {
  isolation: isolate;
  overflow: hidden;
  border-color: rgba(247,240,232,0.18);
  border-radius: 16px;
  background:
    radial-gradient(circle at 18% 0%, rgba(139,58,31,0.34), transparent 36%),
    linear-gradient(145deg, #2b241f 0%, #171413 48%, #0b0b0b 100%);
  box-shadow:
    0 38px 96px -58px rgba(0,0,0,0.98),
    0 16px 34px -26px rgba(139,58,31,0.55),
    inset 0 1px 0 rgba(247,240,232,0.11);
  transition:
    transform .45s cubic-bezier(.2,.7,.2,1),
    border-color .35s ease,
    box-shadow .45s ease,
    background .45s ease;
}
.home-portfolio-stage .pf-card-img::before,
.home-portfolio-stage .pf-card--featured .pf-card-img::before,
.portfolio-page .work-card-img-link::before {
  content: "";
  position: absolute;
  z-index: 5;
  top: 0;
  left: 0;
  right: 0;
  height: 34px;
  border-bottom: 1px solid rgba(247,240,232,0.16);
  background:
    radial-gradient(circle at 18px 50%, rgba(139,58,31,0.96) 0 3px, transparent 4px),
    radial-gradient(circle at 33px 50%, rgba(247,240,232,0.42) 0 3px, transparent 4px),
    radial-gradient(circle at 48px 50%, rgba(247,240,232,0.24) 0 3px, transparent 4px),
    linear-gradient(180deg, rgba(66,55,48,0.94), rgba(30,26,24,0.88));
  box-shadow:
    inset 0 1px 0 rgba(247,240,232,0.12),
    0 10px 26px -22px rgba(0,0,0,0.9);
  pointer-events: none;
}
.home-portfolio-stage .pf-card-img::after,
.home-portfolio-stage .pf-card--featured .pf-card-img::after,
.portfolio-page .work-card-img-link::after {
  content: "";
  position: absolute;
  z-index: 4;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(247,240,232,0.12), rgba(247,240,232,0) 24%),
    radial-gradient(circle at 48% 0%, rgba(247,240,232,0.12), transparent 42%),
    linear-gradient(0deg, rgba(0,0,0,0.18), rgba(0,0,0,0) 35%);
  opacity: 0.78;
  pointer-events: none;
}
.home-portfolio-stage .pf-card:hover .pf-card-img,
.home-portfolio-stage .pf-card--featured:hover .pf-card-img,
.portfolio-page .work-card:hover .work-card-img-link {
  border-color: rgba(247,240,232,0.34);
  box-shadow:
    0 44px 104px -58px rgba(0,0,0,1),
    0 18px 38px -24px rgba(139,58,31,0.68),
    inset 0 1px 0 rgba(247,240,232,0.14);
}
.home-portfolio-stage .pf-card-img img,
.home-portfolio-stage .pf-card--featured .pf-card-img img,
.portfolio-page .work-card-img img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  filter: saturate(0.98) contrast(1.05) brightness(0.96);
  transform: scale(1.01);
  transition:
    transform .78s cubic-bezier(.2,.7,.2,1),
    filter .45s ease;
}
.home-portfolio-stage .pf-card:hover .pf-card-img img,
.home-portfolio-stage .pf-card--featured:hover .pf-card-img img,
.portfolio-page .work-card:hover .work-card-img img {
  filter: saturate(1.07) contrast(1.07) brightness(1);
  transform: scale(1.045);
}
.portfolio-page .work-card-img {
  overflow: hidden;
  border-radius: inherit;
  background: transparent;
}
.home-portfolio-stage .pf-card-num,
.portfolio-page .work-card-badge {
  z-index: 6;
  top: 46px;
  left: 18px;
  border: 1px solid rgba(247,240,232,0.16);
  background: rgba(12,12,12,0.66);
  box-shadow: 0 10px 24px -18px rgba(0,0,0,0.8);
}
.portfolio-page .work-card-placeholder {
  position: relative;
  z-index: 1;
  overflow: hidden;
  background:
    radial-gradient(circle at 78% 18%, rgba(139,58,31,0.36), transparent 34%),
    linear-gradient(145deg, #28211d 0%, #171514 52%, #101010 100%);
}
.portfolio-page .work-card-placeholder::before {
  inset: 22%;
  border-color: rgba(247,240,232,0.18);
  box-shadow: 0 0 0 1px rgba(247,240,232,0.04);
}
.portfolio-page .work-card-placeholder::after {
  display: none;
}
.portfolio-page .work-card-placeholder-name,
.portfolio-page .work-card-placeholder-label {
  position: relative;
  z-index: 2;
}
.portfolio-page .work-card-designed {
  position: relative;
  z-index: 2;
  display: flex;
  min-height: 100%;
  height: 100%;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.72rem;
  overflow: hidden;
  padding: clamp(3.6rem, 7vw, 6.2rem) clamp(1.35rem, 4vw, 3rem) clamp(2.5rem, 5vw, 4.8rem);
  text-align: center;
  color: #F7F0E8;
  background:
    radial-gradient(circle at 12% 15%, rgba(247,240,232,0.16), transparent 28%),
    radial-gradient(circle at 78% 20%, rgba(139,58,31,0.42), transparent 34%),
    radial-gradient(circle at 58% 92%, rgba(72,109,115,0.32), transparent 34%),
    linear-gradient(145deg, #27201c 0%, #151413 58%, #0c0c0c 100%);
}
.portfolio-page .work-card-designed::before {
  content: "";
  position: absolute;
  inset: 34px 0 0;
  z-index: -1;
  background:
    linear-gradient(rgba(247,240,232,0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(247,240,232,0.045) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: radial-gradient(circle at 50% 46%, #000 0 36%, transparent 74%);
  opacity: 0.72;
}
.portfolio-page .work-card-designed::after {
  content: "";
  position: absolute;
  inset: 17% 12%;
  z-index: -1;
  border: 1px solid rgba(247,240,232,0.12);
  border-radius: 18px;
  background: linear-gradient(160deg, rgba(247,240,232,0.08), rgba(247,240,232,0.025));
  box-shadow:
    inset 0 1px 0 rgba(247,240,232,0.08),
    0 26px 70px -48px rgba(0,0,0,0.9);
}
.portfolio-page .work-card-designed[data-tone="brand"] {
  background:
    radial-gradient(circle at 16% 14%, rgba(190,144,255,0.22), transparent 30%),
    radial-gradient(circle at 80% 30%, rgba(139,58,31,0.36), transparent 36%),
    linear-gradient(145deg, #211b24 0%, #151313 60%, #0b0b0b 100%);
}
.portfolio-page .work-card-designed[data-tone="commerce"] {
  background:
    radial-gradient(circle at 16% 14%, rgba(248,188,92,0.24), transparent 31%),
    radial-gradient(circle at 82% 76%, rgba(139,58,31,0.4), transparent 34%),
    linear-gradient(145deg, #281f17 0%, #151413 58%, #0c0c0c 100%);
}
.portfolio-page .work-card-designed[data-tone="finance"] {
  background:
    radial-gradient(circle at 16% 14%, rgba(72,109,115,0.3), transparent 32%),
    radial-gradient(circle at 82% 30%, rgba(139,58,31,0.34), transparent 36%),
    linear-gradient(145deg, #172426 0%, #121616 58%, #0b0b0b 100%);
}
.portfolio-page .work-card-designed[data-tone="field"] {
  background:
    radial-gradient(circle at 16% 16%, rgba(103,142,96,0.28), transparent 31%),
    radial-gradient(circle at 82% 26%, rgba(139,58,31,0.4), transparent 36%),
    linear-gradient(145deg, #1d2419 0%, #151413 58%, #0b0b0b 100%);
}
.portfolio-page .work-card-designed[data-tone="care"] {
  background:
    radial-gradient(circle at 16% 14%, rgba(98,168,185,0.24), transparent 31%),
    radial-gradient(circle at 82% 30%, rgba(139,58,31,0.32), transparent 36%),
    linear-gradient(145deg, #172126 0%, #121414 58%, #0b0b0b 100%);
}
.portfolio-page .work-card-designed[data-tone="studio"] {
  background:
    radial-gradient(circle at 16% 14%, rgba(247,240,232,0.2), transparent 28%),
    radial-gradient(circle at 82% 28%, rgba(139,58,31,0.38), transparent 35%),
    linear-gradient(145deg, #26221e 0%, #151313 58%, #0b0b0b 100%);
}
.work-card-designed-kicker,
.work-card-designed-meta {
  font-family: var(--font-mono);
  font-size: clamp(0.56rem, 1vw, 0.68rem);
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: rgba(247,240,232,0.56);
}
.work-card-designed-name {
  display: block;
  max-width: 13ch;
  font-family: var(--font-serif);
  font-size: clamp(2rem, 5vw, 4.15rem);
  font-style: italic;
  font-weight: 500;
  line-height: 0.95;
  letter-spacing: 0;
  text-wrap: balance;
  color: #F7F0E8;
  text-shadow: 0 20px 54px rgba(0,0,0,0.46);
}
.work-card-designed-place {
  display: inline-flex;
  max-width: min(28ch, 100%);
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(247,240,232,0.14);
  border-radius: 999px;
  padding: 0.48rem 0.76rem;
  background: rgba(247,240,232,0.07);
  color: rgba(247,240,232,0.78);
  font-family: var(--font-sans);
  font-size: clamp(0.72rem, 1.4vw, 0.9rem);
  line-height: 1.1;
}

/* Theme-correct selected work: light stays light, dark stays dark */
.home-portfolio-stage {
  border-top: 1px solid var(--line-soft);
  background:
    linear-gradient(180deg, var(--surface) 0%, var(--bg) 48%, var(--bg-soft) 100%);
  color: var(--ink);
}
.home-portfolio-stage::before {
  color: rgba(26,22,18,0.055);
}
.home-portfolio-stage .eyebrow {
  color: var(--muted);
}
.home-portfolio-stage .eyebrow::before {
  background: var(--muted-2);
}
.home-portfolio-stage .h-1,
.home-portfolio-stage .pf-card-name,
.home-portfolio-stage .pf-card--featured .pf-card-name,
.home-portfolio-stage .cta-after-cases .h-2 {
  color: var(--ink);
}
.home-portfolio-lead,
.home-portfolio-stage .pf-card-desc,
.home-portfolio-stage .pf-card--featured .pf-card-desc,
.home-portfolio-full p,
.home-portfolio-stage .cta-after-cases p:last-child {
  color: var(--muted);
}
.home-portfolio-link,
.home-portfolio-stage .pf-card-metric strong,
.home-portfolio-stage .pf-card-link {
  color: var(--ink);
}
.home-portfolio-stage .pf-card-tag,
.home-portfolio-stage .pf-card-metric,
.home-portfolio-stage .cta-after-kicker {
  color: var(--muted);
}
.home-portfolio-stage .pf-card-foot {
  border-top-color: var(--line);
}
.home-portfolio-full .btn-primary,
.home-portfolio-stage .cta-after-cases .btn {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.home-portfolio-stage .cta-after-cases {
  border-color: var(--line);
  background: rgba(251,248,242,0.62);
}
.home-portfolio-stage .pf-card-img,
.home-portfolio-stage .pf-card--featured .pf-card-img {
  border-color: rgba(26,22,18,0.14);
  background:
    radial-gradient(circle at 18% 0%, rgba(139,58,31,0.16), transparent 34%),
    linear-gradient(145deg, #fbf8f2 0%, #ece7de 52%, #ddd3c4 100%);
  box-shadow:
    0 34px 84px -60px rgba(26,22,18,0.58),
    0 14px 30px -26px rgba(139,58,31,0.34),
    inset 0 1px 0 rgba(255,255,255,0.72);
}
.home-portfolio-stage .pf-card-img::before,
.home-portfolio-stage .pf-card--featured .pf-card-img::before {
  border-bottom-color: rgba(26,22,18,0.12);
  background:
    radial-gradient(circle at 18px 50%, rgba(139,58,31,0.9) 0 3px, transparent 4px),
    radial-gradient(circle at 33px 50%, rgba(26,22,18,0.3) 0 3px, transparent 4px),
    radial-gradient(circle at 48px 50%, rgba(26,22,18,0.18) 0 3px, transparent 4px),
    linear-gradient(180deg, rgba(251,248,242,0.96), rgba(229,223,208,0.9));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.72),
    0 10px 26px -24px rgba(26,22,18,0.34);
}
.home-portfolio-stage .pf-card-img::after,
.home-portfolio-stage .pf-card--featured .pf-card-img::after {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.14), rgba(255,255,255,0) 22%),
    radial-gradient(circle at 48% 0%, rgba(255,255,255,0.16), transparent 42%),
    linear-gradient(0deg, rgba(26,22,18,0.06), rgba(26,22,18,0) 34%);
  opacity: 0.52;
}
.home-portfolio-stage .pf-card:hover .pf-card-img,
.home-portfolio-stage .pf-card--featured:hover .pf-card-img {
  border-color: rgba(26,22,18,0.24);
  box-shadow:
    0 40px 94px -62px rgba(26,22,18,0.68),
    0 16px 36px -26px rgba(139,58,31,0.42),
    inset 0 1px 0 rgba(255,255,255,0.8);
}
.home-portfolio-stage .pf-card-img img,
.home-portfolio-stage .pf-card--featured .pf-card-img img {
  filter: saturate(0.98) contrast(1.02) brightness(1.02);
}
.home-portfolio-stage .pf-card:hover .pf-card-img img,
.home-portfolio-stage .pf-card--featured:hover .pf-card-img img {
  filter: saturate(1.04) contrast(1.04) brightness(1.03);
}
.home-portfolio-stage .pf-card-num {
  color: var(--ink);
  border-color: rgba(26,22,18,0.14);
  background: rgba(251,248,242,0.78);
  box-shadow: 0 10px 24px -18px rgba(26,22,18,0.34);
}
html[data-theme="dark"] .home-portfolio-stage {
  border-top: 0;
  background:
    linear-gradient(180deg, #171717 0%, #111111 54%, #171310 100%);
  color: #F7F0E8;
}
html[data-theme="dark"] .home-portfolio-stage::before {
  color: rgba(247,240,232,0.055);
}
html[data-theme="dark"] .home-portfolio-stage .eyebrow {
  color: rgba(247,240,232,0.68);
}
html[data-theme="dark"] .home-portfolio-stage .eyebrow::before {
  background: rgba(247,240,232,0.42);
}
html[data-theme="dark"] .home-portfolio-stage .h-1,
html[data-theme="dark"] .home-portfolio-stage .pf-card-name,
html[data-theme="dark"] .home-portfolio-stage .pf-card--featured .pf-card-name,
html[data-theme="dark"] .home-portfolio-stage .cta-after-cases .h-2,
html[data-theme="dark"] .home-portfolio-link,
html[data-theme="dark"] .home-portfolio-stage .pf-card-metric strong,
html[data-theme="dark"] .home-portfolio-stage .pf-card-link {
  color: #F7F0E8;
}
html[data-theme="dark"] .home-portfolio-lead,
html[data-theme="dark"] .home-portfolio-stage .pf-card-desc,
html[data-theme="dark"] .home-portfolio-stage .pf-card--featured .pf-card-desc,
html[data-theme="dark"] .home-portfolio-stage .cta-after-cases p:last-child {
  color: rgba(247,240,232,0.72);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card-tag,
html[data-theme="dark"] .home-portfolio-stage .pf-card-metric,
html[data-theme="dark"] .home-portfolio-stage .cta-after-kicker {
  color: rgba(247,240,232,0.58);
}
html[data-theme="dark"] .home-portfolio-full p {
  color: rgba(247,240,232,0.64);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card-foot {
  border-top-color: rgba(247,240,232,0.16);
}
html[data-theme="dark"] .home-portfolio-full .btn-primary,
html[data-theme="dark"] .home-portfolio-stage .cta-after-cases .btn {
  background: #F7F0E8;
  color: #171717;
  border-color: #F7F0E8;
}
html[data-theme="dark"] .home-portfolio-stage .cta-after-cases {
  border-color: rgba(247,240,232,0.14);
  background: rgba(247,240,232,0.06);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card-img,
html[data-theme="dark"] .home-portfolio-stage .pf-card--featured .pf-card-img {
  border-color: rgba(247,240,232,0.18);
  background:
    radial-gradient(circle at 18% 0%, rgba(139,58,31,0.34), transparent 36%),
    linear-gradient(145deg, #2b241f 0%, #171413 48%, #0b0b0b 100%);
  box-shadow:
    0 38px 96px -58px rgba(0,0,0,0.98),
    0 16px 34px -26px rgba(139,58,31,0.55),
    inset 0 1px 0 rgba(247,240,232,0.11);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card-img::before,
html[data-theme="dark"] .home-portfolio-stage .pf-card--featured .pf-card-img::before {
  border-bottom-color: rgba(247,240,232,0.16);
  background:
    radial-gradient(circle at 18px 50%, rgba(139,58,31,0.96) 0 3px, transparent 4px),
    radial-gradient(circle at 33px 50%, rgba(247,240,232,0.42) 0 3px, transparent 4px),
    radial-gradient(circle at 48px 50%, rgba(247,240,232,0.24) 0 3px, transparent 4px),
    linear-gradient(180deg, rgba(66,55,48,0.94), rgba(30,26,24,0.88));
  box-shadow:
    inset 0 1px 0 rgba(247,240,232,0.12),
    0 10px 26px -22px rgba(0,0,0,0.9);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card-img::after,
html[data-theme="dark"] .home-portfolio-stage .pf-card--featured .pf-card-img::after {
  background:
    linear-gradient(180deg, rgba(247,240,232,0.12), rgba(247,240,232,0) 24%),
    radial-gradient(circle at 48% 0%, rgba(247,240,232,0.12), transparent 42%),
    linear-gradient(0deg, rgba(0,0,0,0.18), rgba(0,0,0,0) 35%);
  opacity: 0.78;
}
html[data-theme="dark"] .home-portfolio-stage .pf-card:hover .pf-card-img,
html[data-theme="dark"] .home-portfolio-stage .pf-card--featured:hover .pf-card-img {
  border-color: rgba(247,240,232,0.34);
  box-shadow:
    0 44px 104px -58px rgba(0,0,0,1),
    0 18px 38px -24px rgba(139,58,31,0.68),
    inset 0 1px 0 rgba(247,240,232,0.14);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card-img img,
html[data-theme="dark"] .home-portfolio-stage .pf-card--featured .pf-card-img img {
  filter: saturate(0.98) contrast(1.05) brightness(0.96);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card:hover .pf-card-img img,
html[data-theme="dark"] .home-portfolio-stage .pf-card--featured:hover .pf-card-img img {
  filter: saturate(1.07) contrast(1.07) brightness(1);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card-num {
  color: #F7F0E8;
  border-color: rgba(247,240,232,0.16);
  background: rgba(12,12,12,0.66);
  box-shadow: 0 10px 24px -18px rgba(0,0,0,0.8);
}
.portfolio-page #emptyState p {
  color: rgba(247,240,232,0.75) !important;
}
.portfolio-page #pagination {
  margin-top: 4rem !important;
}
.portfolio-thread-section {
  background: #111111;
  color: #F7F0E8;
  border-top: 1px solid rgba(247,240,232,0.1);
  padding-top: 8rem;
}
.portfolio-thread-section .essay-grid {
  color: #F7F0E8;
}
.portfolio-thread-section .eyebrow {
  color: rgba(247,240,232,0.58);
}
.portfolio-thread-section .eyebrow::before {
  background: rgba(247,240,232,0.38);
}
.portfolio-thread-section .prose,
.portfolio-thread-section .prose p {
  color: rgba(247,240,232,0.74);
}
.portfolio-thread-section .h-1,
.portfolio-thread-section .italic-serif {
  color: #F7F0E8;
}
.portfolio-thread-section .word-mask {
  overflow: visible;
  padding-bottom: 0;
  margin-bottom: 0;
}
.portfolio-thread-section .word {
  transform: translateY(0) !important;
}
.portfolio-thread-link {
  color: #F7F0E8;
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: rgba(247,240,232,0.55);
}
.portfolio-thread-link:hover {
  text-decoration-color: #F7F0E8;
}

/* Theme-correct portfolio archive: light mode stays warm and editorial. */
.portfolio-page {
  background: var(--bg);
}
.portfolio-page .portfolio-hero-stats {
  border-color: var(--line);
}
.portfolio-page .portfolio-hero-stats .hero-stat {
  border-color: var(--line);
}
.portfolio-page .portfolio-hero-stats .bignum {
  color: var(--ink);
}
.portfolio-page .portfolio-hero-stats .hero-stat-lbl,
.portfolio-page .portfolio-hero-stats .bignum-suffix {
  color: var(--muted);
}
.portfolio-page .pf-filter-bar {
  background: rgba(244,240,234,0.96) !important;
  border-top-color: rgba(26,22,18,0.05) !important;
  border-bottom-color: var(--line) !important;
  box-shadow: 0 16px 38px -32px rgba(26,22,18,0.34) !important;
}
.portfolio-page .pf-filter-label,
.portfolio-page .pf-filter-count {
  color: var(--muted);
}
.portfolio-page .pf-filter-divider {
  background: var(--line);
}
.portfolio-page .filter-btn {
  background: transparent !important;
  border-color: var(--line) !important;
  color: var(--ink-soft) !important;
}
.portfolio-page .filter-btn:hover {
  background: var(--surface) !important;
  color: var(--ink) !important;
}
.portfolio-page .filter-btn.active {
  background: var(--ink) !important;
  color: var(--bg) !important;
  border-color: var(--ink) !important;
}
.portfolio-page .portfolio-search {
  background: var(--surface) !important;
  border-color: var(--line) !important;
  color: var(--ink) !important;
}
.portfolio-page .portfolio-search::placeholder {
  color: var(--muted-2);
}
.portfolio-work-stage {
  background: var(--bg);
}
.portfolio-page .work-card-img-link {
  border-color: rgba(26,22,18,0.14);
  background:
    radial-gradient(circle at 18% 0%, rgba(139,58,31,0.16), transparent 34%),
    linear-gradient(145deg, #fbf8f2 0%, #ece7de 52%, #ddd3c4 100%);
  box-shadow:
    0 34px 84px -60px rgba(26,22,18,0.58),
    0 14px 30px -26px rgba(139,58,31,0.34),
    inset 0 1px 0 rgba(255,255,255,0.72);
}
.portfolio-page .work-card-img-link::before {
  border-bottom-color: rgba(26,22,18,0.12);
  background:
    radial-gradient(circle at 18px 50%, rgba(139,58,31,0.9) 0 3px, transparent 4px),
    radial-gradient(circle at 33px 50%, rgba(26,22,18,0.3) 0 3px, transparent 4px),
    radial-gradient(circle at 48px 50%, rgba(26,22,18,0.18) 0 3px, transparent 4px),
    linear-gradient(180deg, rgba(251,248,242,0.96), rgba(229,223,208,0.9));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.72),
    0 10px 26px -24px rgba(26,22,18,0.34);
}
.portfolio-page .work-card-img-link::after {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.14), rgba(255,255,255,0) 22%),
    radial-gradient(circle at 48% 0%, rgba(255,255,255,0.16), transparent 42%),
    linear-gradient(0deg, rgba(26,22,18,0.06), rgba(26,22,18,0) 34%);
  opacity: 0.52;
}
.portfolio-page .work-card:hover .work-card-img-link {
  border-color: rgba(26,22,18,0.24);
  box-shadow:
    0 40px 94px -62px rgba(26,22,18,0.68),
    0 16px 36px -26px rgba(139,58,31,0.42),
    inset 0 1px 0 rgba(255,255,255,0.8);
}
.portfolio-page .work-card-img img {
  filter: saturate(0.98) contrast(1.02) brightness(1.02);
}
.portfolio-page .work-card:hover .work-card-img img {
  filter: saturate(1.04) contrast(1.04) brightness(1.03);
}
.portfolio-page .work-card-meta {
  color: var(--muted);
}
.portfolio-page .work-card-name {
  color: var(--ink);
}
.portfolio-page .work-card-tag {
  color: var(--muted);
}
.portfolio-page .work-card-actions {
  border-top-color: var(--line);
}
.portfolio-page .work-card-cs {
  color: var(--ink);
  border-bottom-color: rgba(26,22,18,0.52);
}
.portfolio-page .work-card-cs:hover {
  color: var(--ink);
  border-bottom-color: var(--ink);
}
.portfolio-page .work-card-live {
  color: var(--muted);
}
.portfolio-page .work-card-live:hover {
  color: var(--ink);
}
.portfolio-page .work-card-badge {
  color: var(--ink);
  border-color: rgba(26,22,18,0.14);
  background: rgba(251,248,242,0.78);
  box-shadow: 0 10px 24px -18px rgba(26,22,18,0.34);
}
.portfolio-page .work-card-placeholder {
  background: linear-gradient(155deg, var(--bg) 0%, var(--bg-soft) 60%, var(--surface) 100%);
}
.portfolio-page .work-card-placeholder::before {
  border-color: var(--line);
}
.portfolio-page .work-card-placeholder-name {
  color: var(--ink);
}
.portfolio-page .work-card-placeholder-label {
  color: var(--muted);
}
.portfolio-page .work-card-designed,
.portfolio-page .work-card-designed[data-tone="brand"],
.portfolio-page .work-card-designed[data-tone="commerce"],
.portfolio-page .work-card-designed[data-tone="finance"],
.portfolio-page .work-card-designed[data-tone="field"],
.portfolio-page .work-card-designed[data-tone="care"],
.portfolio-page .work-card-designed[data-tone="studio"] {
  --thumb-accent: 139 58 31;
  --thumb-accent-2: 70 96 101;
  --thumb-base: #FBF8F2;
  --thumb-mid: #E9DED1;
  --thumb-deep: #D2C0AA;
  position: relative;
  isolation: isolate;
  align-items: flex-start;
  justify-content: flex-end;
  gap: 0.62rem;
  min-height: 100%;
  height: 100%;
  overflow: hidden;
  padding: clamp(4.65rem, 6vw, 5.6rem) clamp(1.25rem, 3vw, 2rem) clamp(1.25rem, 3vw, 1.85rem);
  text-align: left;
  color: var(--ink);
  background:
    linear-gradient(rgba(26,22,18,0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(26,22,18,0.028) 1px, transparent 1px),
    radial-gradient(circle at 16% 22%, rgb(var(--thumb-accent) / 0.23), transparent 32%),
    radial-gradient(circle at 84% 14%, rgb(var(--thumb-accent-2) / 0.16), transparent 36%),
    radial-gradient(circle at 78% 88%, rgba(205,159,91,0.18), transparent 38%),
    linear-gradient(145deg, var(--thumb-base) 0%, var(--thumb-mid) 58%, var(--thumb-deep) 100%);
  background-size: 42px 42px, 42px 42px, auto, auto, auto, auto;
}
.portfolio-page .work-card-designed[data-tone="brand"] {
  --thumb-accent: 126 78 139;
  --thumb-accent-2: 139 58 31;
  --thumb-mid: #E8DDE6;
  --thumb-deep: #D0BFCA;
}
.portfolio-page .work-card-designed[data-tone="commerce"] {
  --thumb-accent: 211 141 45;
  --thumb-accent-2: 139 58 31;
  --thumb-mid: #ECDFC8;
  --thumb-deep: #D7C09D;
}
.portfolio-page .work-card-designed[data-tone="finance"] {
  --thumb-accent: 58 108 117;
  --thumb-accent-2: 139 58 31;
  --thumb-mid: #DDE8E6;
  --thumb-deep: #BDD0D0;
}
.portfolio-page .work-card-designed[data-tone="field"] {
  --thumb-accent: 83 125 78;
  --thumb-accent-2: 139 58 31;
  --thumb-mid: #E1E6D4;
  --thumb-deep: #C4D0B4;
}
.portfolio-page .work-card-designed[data-tone="care"] {
  --thumb-accent: 72 134 149;
  --thumb-accent-2: 139 58 31;
  --thumb-mid: #DFEAE8;
  --thumb-deep: #C1D4D1;
}
.portfolio-page .work-card-designed::before {
  content: attr(data-initials);
  position: absolute;
  top: clamp(0.8rem, 2vw, 1.25rem);
  right: clamp(-0.24rem, -1vw, -0.08rem);
  z-index: 0;
  font-family: var(--font-display);
  font-size: clamp(7.4rem, 17vw, 12.6rem);
  font-weight: 600;
  line-height: 0.72;
  letter-spacing: -0.08em;
  color: rgb(var(--thumb-accent) / 0.16);
  text-transform: uppercase;
  text-shadow: 0 1px 0 rgba(255,255,255,0.44);
  pointer-events: none;
}
.portfolio-page .work-card-designed::after {
  content: "";
  position: absolute;
  inset: 0.92rem;
  z-index: 1;
  border: 1px solid rgba(26,22,18,0.12);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.66), rgba(255,255,255,0.13) 56%, rgba(26,22,18,0.04)),
    radial-gradient(circle at 18% 12%, rgb(var(--thumb-accent) / 0.1), transparent 34%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.7),
    0 30px 70px -56px rgba(26,22,18,0.62);
  pointer-events: none;
}
.portfolio-page .work-card-designed .work-card-designed-kicker {
  position: absolute;
  top: 1.62rem;
  right: 1.52rem;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.44rem;
  max-width: 15ch;
  text-align: right;
  color: rgba(26,22,18,0.54);
}
.portfolio-page .work-card-designed .work-card-designed-kicker::before {
  content: "";
  width: 0.42rem;
  height: 0.42rem;
  border-radius: 999px;
  background: rgb(var(--thumb-accent));
  box-shadow:
    0.68rem 0 0 rgb(var(--thumb-accent) / 0.28),
    1.36rem 0 0 rgb(var(--thumb-accent-2) / 0.24);
}
.portfolio-page .work-card-designed .work-card-designed-meta {
  position: relative;
  z-index: 2;
  max-width: min(32ch, 100%);
  color: rgba(26,22,18,0.52);
}
.portfolio-page .work-card-designed .work-card-designed-name {
  position: relative;
  z-index: 2;
  max-width: min(14ch, 100%);
  font-size: clamp(1.82rem, 3.6vw, 3.38rem);
  line-height: 0.98;
  color: var(--ink);
  overflow-wrap: anywhere;
  text-shadow: 0 1px 0 rgba(255,255,255,0.48), 0 18px 48px rgba(255,255,255,0.24);
}
.portfolio-page .work-card-designed .work-card-designed-place {
  position: relative;
  z-index: 2;
  justify-content: flex-start;
  max-width: min(30ch, 100%);
  background: rgba(251,248,242,0.78);
  border-color: rgba(26,22,18,0.13);
  color: var(--ink-soft);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.portfolio-page #emptyState p {
  color: var(--muted) !important;
}
.portfolio-thread-section {
  background: var(--bg);
  color: var(--ink);
  border-top: 1px solid var(--line);
}
.portfolio-thread-section .essay-grid,
.portfolio-thread-section .h-1,
.portfolio-thread-section .italic-serif {
  color: var(--ink);
}
.portfolio-thread-section .eyebrow {
  color: var(--muted);
}
.portfolio-thread-section .eyebrow::before {
  background: var(--muted);
}
.portfolio-thread-section .prose,
.portfolio-thread-section .prose p {
  color: var(--ink-soft);
}
.portfolio-thread-link {
  color: var(--ink);
  text-decoration-color: rgba(26,22,18,0.45);
}
.portfolio-thread-link:hover {
  text-decoration-color: var(--ink);
}
.portfolio-closing-cta {
  background: var(--surface);
  color: var(--ink);
  border-top: 1px solid var(--line);
}
.portfolio-closing-cta .container-narrow {
  text-align: center;
  padding: 4rem 0;
}
.portfolio-closing-cta .h-1 {
  color: var(--ink);
  margin: 0 0 1.5rem;
}
.portfolio-closing-cta p {
  max-width: 56ch;
  margin: 0 auto 2.5rem;
  color: var(--muted);
  font-family: var(--font-serif);
  font-size: 1.15rem;
  line-height: 1.65;
}
.portfolio-closing-cta .btn {
  padding: 1rem 2rem;
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}

html[data-theme="dark"] .portfolio-page {
  background: #111111;
}
html[data-theme="dark"] .portfolio-page .portfolio-hero-stats {
  border-color: rgba(247,240,232,0.13);
}
html[data-theme="dark"] .portfolio-page .portfolio-hero-stats .hero-stat {
  border-color: rgba(247,240,232,0.13);
}
html[data-theme="dark"] .portfolio-page .portfolio-hero-stats .bignum {
  color: #F7F0E8;
}
html[data-theme="dark"] .portfolio-page .portfolio-hero-stats .hero-stat-lbl,
html[data-theme="dark"] .portfolio-page .portfolio-hero-stats .bignum-suffix {
  color: rgba(247,240,232,0.62);
}
html[data-theme="dark"] .portfolio-page .pf-filter-bar {
  background: rgba(17,17,17,0.94) !important;
  border-top-color: rgba(247,240,232,0.1) !important;
  border-bottom-color: rgba(247,240,232,0.16) !important;
  box-shadow: 0 18px 42px -34px rgba(0,0,0,0.85) !important;
}
html[data-theme="dark"] .portfolio-page .pf-filter-label,
html[data-theme="dark"] .portfolio-page .pf-filter-count {
  color: rgba(247,240,232,0.58);
}
html[data-theme="dark"] .portfolio-page .pf-filter-divider {
  background: rgba(247,240,232,0.16);
}
html[data-theme="dark"] .portfolio-page .filter-btn {
  background: transparent !important;
  border-color: rgba(247,240,232,0.24) !important;
  color: rgba(247,240,232,0.78) !important;
}
html[data-theme="dark"] .portfolio-page .filter-btn:hover {
  background: rgba(247,240,232,0.1) !important;
  color: #F7F0E8 !important;
}
html[data-theme="dark"] .portfolio-page .filter-btn.active {
  background: #F7F0E8 !important;
  color: #111111 !important;
  border-color: #F7F0E8 !important;
}
html[data-theme="dark"] .portfolio-page .portfolio-search {
  background: rgba(247,240,232,0.08) !important;
  border-color: rgba(247,240,232,0.2) !important;
  color: #F7F0E8 !important;
}
html[data-theme="dark"] .portfolio-page .portfolio-search::placeholder {
  color: rgba(247,240,232,0.42);
}
html[data-theme="dark"] .portfolio-work-stage,
html[data-theme="dark"] .portfolio-thread-section {
  background: #111111;
  color: #F7F0E8;
}
html[data-theme="dark"] .portfolio-thread-section {
  border-top-color: rgba(247,240,232,0.1);
}
html[data-theme="dark"] .portfolio-page .work-card-meta,
html[data-theme="dark"] .portfolio-thread-section .eyebrow {
  color: rgba(247,240,232,0.58);
}
html[data-theme="dark"] .portfolio-thread-section .eyebrow::before {
  background: rgba(247,240,232,0.38);
}
html[data-theme="dark"] .portfolio-page .work-card-name,
html[data-theme="dark"] .portfolio-thread-section .essay-grid,
html[data-theme="dark"] .portfolio-thread-section .h-1,
html[data-theme="dark"] .portfolio-thread-section .italic-serif,
html[data-theme="dark"] .portfolio-thread-link {
  color: #F7F0E8;
}
html[data-theme="dark"] .portfolio-page .work-card-tag,
html[data-theme="dark"] .portfolio-thread-section .prose,
html[data-theme="dark"] .portfolio-thread-section .prose p {
  color: rgba(247,240,232,0.74);
}
html[data-theme="dark"] .portfolio-page .work-card-actions {
  border-top-color: rgba(247,240,232,0.14);
}
html[data-theme="dark"] .portfolio-page .work-card-cs {
  color: #F7F0E8;
  border-bottom-color: rgba(247,240,232,0.72);
}
html[data-theme="dark"] .portfolio-page .work-card-cs:hover {
  color: #F7F0E8;
  border-bottom-color: #F7F0E8;
}
html[data-theme="dark"] .portfolio-page .work-card-live {
  color: rgba(247,240,232,0.52);
}
html[data-theme="dark"] .portfolio-page .work-card-live:hover {
  color: #F7F0E8;
}
html[data-theme="dark"] .portfolio-page .work-card-img-link {
  border-color: rgba(247,240,232,0.18);
  background:
    radial-gradient(circle at 18% 0%, rgba(139,58,31,0.34), transparent 36%),
    linear-gradient(145deg, #2b241f 0%, #171413 48%, #0b0b0b 100%);
  box-shadow:
    0 38px 96px -58px rgba(0,0,0,0.98),
    0 16px 34px -26px rgba(139,58,31,0.55),
    inset 0 1px 0 rgba(247,240,232,0.11);
}
html[data-theme="dark"] .portfolio-page .work-card-img-link::before {
  border-bottom-color: rgba(247,240,232,0.16);
  background:
    radial-gradient(circle at 18px 50%, rgba(139,58,31,0.96) 0 3px, transparent 4px),
    radial-gradient(circle at 33px 50%, rgba(247,240,232,0.42) 0 3px, transparent 4px),
    radial-gradient(circle at 48px 50%, rgba(247,240,232,0.24) 0 3px, transparent 4px),
    linear-gradient(180deg, rgba(66,55,48,0.94), rgba(30,26,24,0.88));
  box-shadow:
    inset 0 1px 0 rgba(247,240,232,0.12),
    0 10px 26px -22px rgba(0,0,0,0.9);
}
html[data-theme="dark"] .portfolio-page .work-card-img-link::after {
  background:
    linear-gradient(180deg, rgba(247,240,232,0.12), rgba(247,240,232,0) 24%),
    radial-gradient(circle at 48% 0%, rgba(247,240,232,0.12), transparent 42%),
    linear-gradient(0deg, rgba(0,0,0,0.18), rgba(0,0,0,0) 35%);
  opacity: 0.78;
}
html[data-theme="dark"] .portfolio-page .work-card:hover .work-card-img-link {
  border-color: rgba(247,240,232,0.34);
  box-shadow:
    0 44px 104px -58px rgba(0,0,0,1),
    0 18px 38px -24px rgba(139,58,31,0.68),
    inset 0 1px 0 rgba(247,240,232,0.14);
}
html[data-theme="dark"] .portfolio-page .work-card-img img {
  filter: saturate(0.98) contrast(1.05) brightness(0.96);
}
html[data-theme="dark"] .portfolio-page .work-card:hover .work-card-img img {
  filter: saturate(1.07) contrast(1.07) brightness(1);
}
html[data-theme="dark"] .portfolio-page .work-card-badge {
  color: #F7F0E8;
  border-color: rgba(247,240,232,0.16);
  background: rgba(12,12,12,0.66);
  box-shadow: 0 10px 24px -18px rgba(0,0,0,0.8);
}
html[data-theme="dark"] .portfolio-page .work-card-placeholder {
  background:
    radial-gradient(circle at 78% 18%, rgba(139,58,31,0.36), transparent 34%),
    linear-gradient(145deg, #28211d 0%, #171514 52%, #101010 100%);
}
html[data-theme="dark"] .portfolio-page .work-card-placeholder::before {
  border-color: rgba(247,240,232,0.18);
}
html[data-theme="dark"] .portfolio-page .work-card-placeholder-name,
html[data-theme="dark"] .portfolio-page .work-card-designed .work-card-designed-name {
  color: #F7F0E8;
}
html[data-theme="dark"] .portfolio-page .work-card-placeholder-label,
html[data-theme="dark"] .portfolio-page .work-card-designed .work-card-designed-kicker,
html[data-theme="dark"] .portfolio-page .work-card-designed .work-card-designed-meta {
  color: rgba(247,240,232,0.56);
}
html[data-theme="dark"] .portfolio-page .work-card-designed,
html[data-theme="dark"] .portfolio-page .work-card-designed[data-tone="brand"],
html[data-theme="dark"] .portfolio-page .work-card-designed[data-tone="commerce"],
html[data-theme="dark"] .portfolio-page .work-card-designed[data-tone="finance"],
html[data-theme="dark"] .portfolio-page .work-card-designed[data-tone="field"],
html[data-theme="dark"] .portfolio-page .work-card-designed[data-tone="care"],
html[data-theme="dark"] .portfolio-page .work-card-designed[data-tone="studio"] {
  color: #F7F0E8;
  background:
    radial-gradient(circle at 12% 15%, rgba(247,240,232,0.16), transparent 28%),
    radial-gradient(circle at 78% 20%, rgba(139,58,31,0.42), transparent 34%),
    radial-gradient(circle at 58% 92%, rgba(72,109,115,0.32), transparent 34%),
    linear-gradient(145deg, #27201c 0%, #151413 58%, #0c0c0c 100%);
}
html[data-theme="dark"] .portfolio-page .work-card-designed::before {
  background:
    linear-gradient(rgba(247,240,232,0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(247,240,232,0.045) 1px, transparent 1px);
}
html[data-theme="dark"] .portfolio-page .work-card-designed::after {
  border-color: rgba(247,240,232,0.12);
  background: linear-gradient(160deg, rgba(247,240,232,0.08), rgba(247,240,232,0.025));
  box-shadow:
    inset 0 1px 0 rgba(247,240,232,0.08),
    0 26px 70px -48px rgba(0,0,0,0.9);
}
html[data-theme="dark"] .portfolio-page .work-card-designed .work-card-designed-name {
  text-shadow: 0 20px 54px rgba(0,0,0,0.46);
}
html[data-theme="dark"] .portfolio-page .work-card-designed .work-card-designed-place {
  border-color: rgba(247,240,232,0.14);
  background: rgba(247,240,232,0.07);
  color: rgba(247,240,232,0.78);
}
html[data-theme="dark"] .portfolio-thread-link {
  text-decoration-color: rgba(247,240,232,0.55);
}
html[data-theme="dark"] .portfolio-thread-link:hover {
  text-decoration-color: #F7F0E8;
}
html[data-theme="dark"] .portfolio-closing-cta {
  background: #15110B;
  color: #F7F0E8;
  border-top-color: rgba(247,240,232,0.1);
}
html[data-theme="dark"] .portfolio-closing-cta .h-1 {
  color: #F7F0E8;
}
html[data-theme="dark"] .portfolio-closing-cta p {
  color: rgba(247,240,232,0.78);
}
html[data-theme="dark"] .portfolio-closing-cta .btn {
  background: #F7F0E8;
  color: #15110B;
  border-color: #F7F0E8;
}

@media (max-width: 980px) {
  .home-portfolio-stage .h-1 {
    font-size: 2.55rem;
  }
  .home-portfolio-head,
  .portfolio-hero-grid,
  .home-portfolio-stage .cta-after-cases {
    grid-template-columns: 1fr;
  }
  .home-portfolio-head {
    display: grid;
    align-items: start;
  }
  .home-portfolio-stage .pf-card:nth-child(even),
  .home-portfolio-stage .pf-card--featured:nth-child(even),
  .portfolio-page .work-card:nth-child(even) {
    margin-top: 0;
  }
  .portfolio-hero-copy .h-display {
    font-size: 3.45rem;
  }
  .portfolio-proof-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .home-portfolio-stage .cta-after-cases .btn {
    justify-self: start;
  }
}

@media (max-width: 720px) {
  .home-portfolio-stage::before,
  .portfolio-hero-stage::before {
    font-size: 4.8rem;
  }
  .home-portfolio-stage .h-1,
  .portfolio-hero-copy .h-display {
    font-size: 2.32rem;
    line-height: 1.04;
  }
  .home-portfolio-stage .pf-grid,
  .portfolio-page #workGrid.work-grid {
    grid-template-columns: 1fr;
    gap: 1.8rem;
  }
  .home-portfolio-stage .pf-card-img,
  .home-portfolio-stage .pf-card--featured .pf-card-img,
  .portfolio-page .work-card-img {
    aspect-ratio: 1.18 / 1;
  }
  .home-portfolio-stage .pf-card-img,
  .home-portfolio-stage .pf-card--featured .pf-card-img,
  .portfolio-page .work-card-img-link {
    border-radius: 13px;
  }
  .home-portfolio-stage .pf-card-img::before,
  .home-portfolio-stage .pf-card--featured .pf-card-img::before,
  .portfolio-page .work-card-img-link::before {
    height: 30px;
  }
  .home-portfolio-stage .pf-card-num,
  .portfolio-page .work-card-badge {
    top: 40px;
    left: 13px;
  }
  .home-portfolio-stage .pf-card-name,
  .home-portfolio-stage .pf-card--featured .pf-card-name,
  .portfolio-page .work-card-name {
    font-size: 1.38rem;
  }
  .portfolio-hero-stage {
    padding: 5.3rem 0 2.2rem;
  }
  .portfolio-hero-proof {
    display: none;
  }
  .portfolio-proof-strip {
    display: flex;
    gap: 1px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    margin-top: 2.4rem;
  }
  .portfolio-proof-strip::-webkit-scrollbar {
    display: none;
  }
  .portfolio-proof-strip span {
    min-width: 150px;
    padding: 0.85rem 0.75rem;
  }
  .portfolio-hero-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.4rem 1.2rem;
  }
  .portfolio-work-stage {
    padding-top: 2.6rem;
  }
  .portfolio-page .pf-filter-row-tools {
    align-items: stretch;
  }
}

@media (max-width: 520px) {
  .home-portfolio-stage .h-1,
  .portfolio-hero-copy .h-display {
    font-size: 2rem;
  }
  .portfolio-page .paper .h-display {
    max-width: 100%;
    font-size: clamp(2.05rem, 9.2vw, 2.52rem);
    line-height: 1.03;
    text-wrap: balance;
  }
  .portfolio-page .paper .h-display .italic-serif {
    display: block;
    margin-top: 0.12em;
  }
  .portfolio-page .work-card-designed {
    justify-content: center;
    padding: 4.25rem 1.1rem 1.45rem;
  }
  .portfolio-page .work-card-designed::before {
    top: 4.1rem;
    right: -0.18rem;
    font-size: clamp(6.4rem, 28vw, 8.2rem);
    color: rgb(var(--thumb-accent) / 0.2);
  }
  .portfolio-page .work-card-designed::after {
    inset: 0.7rem;
    border-radius: 14px;
  }
  .portfolio-page .work-card-designed .work-card-designed-kicker {
    top: 1.35rem;
    right: 1rem;
    font-size: 0.54rem;
  }
  .portfolio-page .work-card-designed .work-card-designed-name {
    max-width: 11ch;
    font-size: clamp(1.65rem, 8.2vw, 2.18rem);
  }
  .portfolio-page .work-card-designed .work-card-designed-place {
    font-size: 0.76rem;
  }
  .home-portfolio-stage .pf-card-img,
  .home-portfolio-stage .pf-card--featured .pf-card-img,
  .portfolio-page .work-card-img {
    aspect-ratio: 1 / 0.92;
  }
  .home-portfolio-stage .pf-card-img,
  .home-portfolio-stage .pf-card--featured .pf-card-img,
  .portfolio-page .work-card-img-link {
    border-radius: 11px;
  }
  .home-portfolio-stage .pf-card-img::before,
  .home-portfolio-stage .pf-card--featured .pf-card-img::before,
  .portfolio-page .work-card-img-link::before {
    height: 27px;
  }
  .home-portfolio-stage .pf-card-num,
  .portfolio-page .work-card-badge {
    top: 35px;
    left: 11px;
  }
  .home-portfolio-stage .cta-after-cases {
    padding: 1.35rem;
  }
}

/* Homepage portfolio gallery reset */
.home-portfolio-stage {
  background:
    linear-gradient(180deg, #fbf8f2 0%, #f6f0e7 56%, #f0e7dc 100%);
  color: var(--ink);
}
.home-portfolio-stage::before {
  top: 0.1em;
  color: rgba(26,22,18,0.038);
}
.home-portfolio-stage .home-portfolio-head {
  align-items: end;
  margin-bottom: clamp(2.75rem, 5.5vw, 5.75rem);
}
.home-portfolio-stage .h-1 {
  max-width: 16.5ch;
  line-height: 1.02;
  padding-bottom: 0.05em;
}
.home-portfolio-stage .home-portfolio-lead {
  margin-top: 1.1rem;
  color: color-mix(in srgb, var(--muted) 88%, #111 12%);
}
.home-portfolio-stage .home-portfolio-link {
  color: var(--ink);
}
.home-portfolio-stage .pf-grid {
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(2.2rem, 3.8vw, 4.8rem) clamp(1.5rem, 2.7vw, 2.6rem);
}
.home-portfolio-stage .pf-card,
.home-portfolio-stage .pf-card--featured {
  grid-column: span 6;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  margin-top: 0;
  overflow: visible;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  transform: none;
}
.home-portfolio-stage .pf-card--featured {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1.42fr) minmax(300px, 0.58fr);
  gap: clamp(1.8rem, 4vw, 4.8rem);
  align-items: center;
}
.home-portfolio-stage .pf-card:nth-child(even),
.home-portfolio-stage .pf-card--featured:nth-child(even),
.home-portfolio-stage .pf-card:nth-child(4n+3) {
  margin-top: 0;
}
.home-portfolio-stage .pf-card:hover,
.home-portfolio-stage .pf-card--featured:hover {
  transform: none;
  box-shadow: none;
}
.home-portfolio-stage .pf-card-img,
.home-portfolio-stage .pf-card--featured .pf-card-img,
.home-portfolio-stage .pf-card:nth-child(4n+2) .pf-card-img,
.home-portfolio-stage .pf-card:nth-child(4n+3) .pf-card-img,
.home-portfolio-stage .pf-card:nth-child(4n) .pf-card-img {
  --glow-x: 50%;
  --glow-y: 45%;
  position: relative;
  isolation: isolate;
  display: block;
  min-height: 0;
  aspect-ratio: 16 / 10.4;
  overflow: hidden;
  border: 1px solid rgba(26,22,18,0.15);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.86), rgba(255,255,255,0.28)),
    linear-gradient(135deg, #efe8dc 0%, #d7ddda 52%, #b6b0a7 100%);
  box-shadow:
    0 38px 90px -62px rgba(26,22,18,0.86),
    0 16px 42px -34px rgba(139,58,31,0.34),
    inset 0 1px 0 rgba(255,255,255,0.72);
  perspective: none;
  transform: translate3d(0,0,0);
  transform-style: flat;
  transition:
    transform .38s cubic-bezier(.2,.7,.2,1),
    border-color .25s ease,
    box-shadow .38s ease,
    background .38s ease;
  will-change: transform;
}
.home-portfolio-stage .pf-card--featured .pf-card-img {
  aspect-ratio: 16 / 9.4;
  border-radius: 22px;
}
.home-portfolio-stage .pf-card:nth-child(4n+2) .pf-card-img {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.88), rgba(255,255,255,0.22)),
    linear-gradient(135deg, #edf4df 0%, #d8e2dc 52%, #9fb0a6 100%);
}
.home-portfolio-stage .pf-card:nth-child(4n+3) .pf-card-img {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.88), rgba(255,255,255,0.22)),
    linear-gradient(135deg, #f0e9f7 0%, #ddd9e8 52%, #a3a8b7 100%);
}
.home-portfolio-stage .pf-card:nth-child(4n) .pf-card-img {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.88), rgba(255,255,255,0.22)),
    linear-gradient(135deg, #f4e6d4 0%, #ddd1c4 52%, #aea094 100%);
}
.home-portfolio-stage .pf-card-img::before,
.home-portfolio-stage .pf-card--featured .pf-card-img::before,
.home-portfolio-stage .pf-card:nth-child(3n+1) .pf-card-img::before {
  content: "";
  position: absolute;
  z-index: 4;
  top: 0;
  left: 0;
  right: 0;
  bottom: auto;
  height: 34px;
  border: 0;
  border-radius: 0;
  clip-path: none;
  filter: none;
  transform: none;
  background:
    radial-gradient(circle at 22px 50%, #a14b2d 0 4px, transparent 4.6px),
    radial-gradient(circle at 40px 50%, rgba(26,22,18,0.22) 0 4px, transparent 4.6px),
    radial-gradient(circle at 58px 50%, rgba(26,22,18,0.18) 0 4px, transparent 4.6px),
    linear-gradient(180deg, rgba(255,255,255,0.8), rgba(238,233,225,0.72));
  box-shadow:
    inset 0 -1px 0 rgba(26,22,18,0.12),
    inset 0 1px 0 rgba(255,255,255,0.72);
  pointer-events: none;
}
.home-portfolio-stage .pf-card-img::after,
.home-portfolio-stage .pf-card--featured .pf-card-img::after {
  content: "";
  position: absolute;
  z-index: 5;
  inset: 34px 0 0;
  background:
    linear-gradient(115deg, rgba(255,255,255,0.26) 0%, rgba(255,255,255,0.06) 25%, transparent 42%),
    linear-gradient(0deg, rgba(26,22,18,0.18) 0%, transparent 36%);
  opacity: 0.38;
  pointer-events: none;
  transition: opacity .28s ease;
}
.home-portfolio-stage .pf-card-img img,
.home-portfolio-stage .pf-card--featured .pf-card-img img,
.home-portfolio-stage .pf-card:nth-child(3n+1) .pf-card-img img,
.home-portfolio-stage .pf-card:nth-child(4n+2) .pf-card-img img {
  position: absolute;
  z-index: 2;
  top: 34px;
  left: 0;
  width: 100%;
  height: calc(100% - 34px);
  display: block;
  object-fit: cover;
  object-position: top center;
  border: 0;
  border-radius: 0;
  background: #f8f5ef;
  box-shadow: none;
  filter: saturate(1.08) contrast(1.04) brightness(1.02);
  transform: scale(1.001);
  transform-origin: 50% 20%;
  transition:
    transform .55s cubic-bezier(.2,.7,.2,1),
    filter .34s ease;
}
.home-portfolio-stage .pf-card:hover .pf-card-img,
.home-portfolio-stage .pf-card--featured:hover .pf-card-img,
.home-portfolio-stage .pf-card-img.is-previewing {
  border-color: rgba(26,22,18,0.25);
  box-shadow:
    0 48px 112px -70px rgba(26,22,18,0.95),
    0 20px 52px -35px rgba(139,58,31,0.42),
    inset 0 1px 0 rgba(255,255,255,0.82);
  transform: translate3d(0,-6px,0);
}
.home-portfolio-stage .pf-card:hover .pf-card-img::after,
.home-portfolio-stage .pf-card--featured:hover .pf-card-img::after,
.home-portfolio-stage .pf-card-img.is-previewing::after {
  opacity: 0.58;
}
.home-portfolio-stage .pf-card:hover .pf-card-img img,
.home-portfolio-stage .pf-card--featured:hover .pf-card-img img {
  filter: saturate(1.16) contrast(1.06) brightness(1.04);
  transform: scale(1.035);
}
.home-portfolio-stage .pf-card-num {
  z-index: 6;
  top: 8px;
  left: auto;
  right: 12px;
  min-width: 42px;
  padding: 0.25rem 0.58rem;
  border: 1px solid rgba(26,22,18,0.12);
  border-radius: 999px;
  background: rgba(255,255,255,0.76);
  color: rgba(26,22,18,0.66);
  box-shadow: none;
  font-size: 0.72rem;
}
.home-portfolio-stage .pf-card-body,
.home-portfolio-stage .pf-card--featured .pf-card-body {
  padding: 1.1rem 0 0;
}
.home-portfolio-stage .pf-card--featured .pf-card-body {
  padding: 0;
}
.home-portfolio-stage .pf-card-tag {
  margin-bottom: 0.72rem;
  color: color-mix(in srgb, var(--muted) 90%, #111 10%);
}
.home-portfolio-stage .pf-card-name,
.home-portfolio-stage .pf-card--featured .pf-card-name {
  color: var(--ink);
  letter-spacing: 0;
}
.home-portfolio-stage .pf-card-name {
  font-size: clamp(1.5rem, 2.3vw, 2.05rem);
  line-height: 1.02;
}
.home-portfolio-stage .pf-card--featured .pf-card-name {
  font-size: clamp(2.45rem, 5vw, 4.3rem);
  line-height: 0.95;
}
.home-portfolio-stage .pf-card-desc,
.home-portfolio-stage .pf-card--featured .pf-card-desc {
  color: color-mix(in srgb, var(--muted) 92%, #111 8%);
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}
.home-portfolio-stage .pf-card--featured .pf-card-desc {
  -webkit-line-clamp: 5;
}
.home-portfolio-stage .pf-card-foot {
  border-top-color: rgba(26,22,18,0.14);
}
.home-portfolio-stage .pf-card-metric {
  color: var(--muted);
}
.home-portfolio-stage .pf-card-metric strong,
.home-portfolio-stage .pf-card-link {
  color: var(--ink);
}
.home-portfolio-stage .pf-card:hover .pf-card-link {
  gap: 0.7rem;
}
html[data-theme="dark"] .home-portfolio-stage {
  background:
    linear-gradient(180deg, #121212 0%, #0f0e0d 54%, #15110f 100%);
  color: #F7F0E8;
}
html[data-theme="dark"] .home-portfolio-stage::before {
  color: rgba(247,240,232,0.045);
}
html[data-theme="dark"] .home-portfolio-stage .home-portfolio-link,
html[data-theme="dark"] .home-portfolio-stage .pf-card-name,
html[data-theme="dark"] .home-portfolio-stage .pf-card--featured .pf-card-name,
html[data-theme="dark"] .home-portfolio-stage .pf-card-metric strong,
html[data-theme="dark"] .home-portfolio-stage .pf-card-link {
  color: #F7F0E8;
}
html[data-theme="dark"] .home-portfolio-stage .home-portfolio-lead,
html[data-theme="dark"] .home-portfolio-stage .pf-card-desc,
html[data-theme="dark"] .home-portfolio-stage .pf-card--featured .pf-card-desc {
  color: rgba(247,240,232,0.72);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card-tag,
html[data-theme="dark"] .home-portfolio-stage .pf-card-metric {
  color: rgba(247,240,232,0.58);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card-foot {
  border-top-color: rgba(247,240,232,0.16);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card-img,
html[data-theme="dark"] .home-portfolio-stage .pf-card--featured .pf-card-img,
html[data-theme="dark"] .home-portfolio-stage .pf-card:nth-child(4n+2) .pf-card-img,
html[data-theme="dark"] .home-portfolio-stage .pf-card:nth-child(4n+3) .pf-card-img,
html[data-theme="dark"] .home-portfolio-stage .pf-card:nth-child(4n) .pf-card-img {
  border-color: rgba(247,240,232,0.16);
  background:
    linear-gradient(180deg, rgba(247,240,232,0.12), rgba(247,240,232,0.03)),
    linear-gradient(135deg, #2e2b28 0%, #171514 56%, #080808 100%);
  box-shadow:
    0 48px 110px -72px rgba(0,0,0,1),
    0 18px 46px -34px rgba(139,58,31,0.48),
    inset 0 1px 0 rgba(247,240,232,0.12);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card-img::before,
html[data-theme="dark"] .home-portfolio-stage .pf-card--featured .pf-card-img::before,
html[data-theme="dark"] .home-portfolio-stage .pf-card:nth-child(3n+1) .pf-card-img::before {
  background:
    radial-gradient(circle at 22px 50%, #b15a36 0 4px, transparent 4.6px),
    radial-gradient(circle at 40px 50%, rgba(247,240,232,0.28) 0 4px, transparent 4.6px),
    radial-gradient(circle at 58px 50%, rgba(247,240,232,0.18) 0 4px, transparent 4.6px),
    linear-gradient(180deg, rgba(40,37,34,0.96), rgba(25,23,21,0.92));
  box-shadow:
    inset 0 -1px 0 rgba(247,240,232,0.11),
    inset 0 1px 0 rgba(247,240,232,0.08);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card-img::after,
html[data-theme="dark"] .home-portfolio-stage .pf-card--featured .pf-card-img::after {
  background:
    linear-gradient(115deg, rgba(247,240,232,0.16) 0%, rgba(247,240,232,0.04) 25%, transparent 42%),
    linear-gradient(0deg, rgba(0,0,0,0.32) 0%, transparent 40%);
}
html[data-theme="dark"] .home-portfolio-stage .pf-card-num {
  border-color: rgba(247,240,232,0.16);
  background: rgba(19,18,17,0.78);
  color: rgba(247,240,232,0.78);
}

@media (max-width: 980px) {
  .home-portfolio-stage .home-portfolio-head,
  .home-portfolio-stage .pf-card--featured {
    grid-template-columns: 1fr;
  }
  .home-portfolio-stage .pf-grid {
    grid-template-columns: 1fr;
    gap: 2.8rem;
  }
  .home-portfolio-stage .pf-card,
  .home-portfolio-stage .pf-card--featured {
    grid-column: 1 / -1;
  }
  .home-portfolio-stage .pf-card--featured .pf-card-body {
    padding: 0;
  }
}

@media (max-width: 720px) {
  .home-portfolio-stage .home-portfolio-head {
    margin-bottom: 2rem;
  }
  .home-portfolio-stage .h-1 {
    max-width: 12ch;
    line-height: 1.04;
  }
  .home-portfolio-stage .pf-grid {
    gap: 2.35rem;
  }
  .home-portfolio-stage .pf-card-img,
  .home-portfolio-stage .pf-card--featured .pf-card-img,
  .home-portfolio-stage .pf-card:nth-child(4n+2) .pf-card-img,
  .home-portfolio-stage .pf-card:nth-child(4n+3) .pf-card-img,
  .home-portfolio-stage .pf-card:nth-child(4n) .pf-card-img {
    aspect-ratio: 1.04 / 1;
    border-radius: 15px;
    transform: translate3d(0,0,0) !important;
  }
  .home-portfolio-stage .pf-card-img::before,
  .home-portfolio-stage .pf-card--featured .pf-card-img::before,
  .home-portfolio-stage .pf-card:nth-child(3n+1) .pf-card-img::before {
    height: 30px;
  }
  .home-portfolio-stage .pf-card-img::after,
  .home-portfolio-stage .pf-card--featured .pf-card-img::after {
    top: 30px;
  }
  .home-portfolio-stage .pf-card-img img,
  .home-portfolio-stage .pf-card--featured .pf-card-img img,
  .home-portfolio-stage .pf-card:nth-child(3n+1) .pf-card-img img,
  .home-portfolio-stage .pf-card:nth-child(4n+2) .pf-card-img img {
    top: 30px;
    height: calc(100% - 30px);
    transform: scale(1.001);
  }
  .home-portfolio-stage .pf-card:hover .pf-card-img,
  .home-portfolio-stage .pf-card--featured:hover .pf-card-img,
  .home-portfolio-stage .pf-card-img.is-previewing {
    transform: translate3d(0,-3px,0) !important;
  }
  .home-portfolio-stage .pf-card-num {
    top: 6px;
    right: 9px;
    min-width: 36px;
    padding: 0.22rem 0.5rem;
  }
  .home-portfolio-stage .pf-card--featured .pf-card-name,
  .home-portfolio-stage .pf-card-name {
    font-size: clamp(1.55rem, 8vw, 2.2rem);
  }
  .home-portfolio-stage .pf-card:nth-of-type(n+7) {
    display: none;
  }
  .home-portfolio-stage .pf-card-foot {
    align-items: flex-start;
    gap: 0.75rem;
  }
  .home-portfolio-stage .pf-card-link {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 0.58rem 0;
  }
  .home-portfolio-stage .pf-card-metric {
    max-width: 12rem;
  }
}

/* ── Lofts diagnostic tools ───────────────────────────────────── */
.tool-launchpad-section {
  padding: 0 0 4.5rem;
}
.tool-launchpad-head,
.home-tools-head {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(280px, 0.72fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: end;
  margin-bottom: clamp(1.6rem, 4vw, 2.8rem);
}
.tool-launchpad-head .h-1,
.home-tools-head .h-1 {
  margin: 1rem 0 0;
  max-width: 11ch;
}
.tool-launchpad-head p,
.home-tools-head p {
  margin: 0;
  font-family: var(--font-serif);
  color: var(--ink-soft);
  line-height: 1.62;
  font-size: clamp(1rem, 1.7vw, 1.2rem);
}
.tool-launchpad-grid,
.home-tools-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1rem, 2.2vw, 1.5rem);
}
.studio-tool-card,
.home-tool-card {
  position: relative;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  gap: 1.35rem;
  padding: clamp(1.35rem, 3vw, 2rem);
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.34), rgba(255,255,255,0)),
    var(--surface);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: transform 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}
.studio-tool-card::before,
.home-tool-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(139,58,31,0.10), transparent 42%),
    repeating-linear-gradient(90deg, rgba(26,22,18,0.045) 0 1px, transparent 1px 92px);
  opacity: 0.55;
}
.studio-tool-card:hover,
.home-tool-card:hover {
  transform: translateY(-4px);
  border-color: rgba(139,58,31,0.42);
  box-shadow: 0 28px 80px -46px rgba(26,22,18,0.34);
}
.studio-tool-card > *,
.home-tool-card > * {
  position: relative;
  z-index: 1;
}
.studio-tool-label,
.home-tool-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
}
.studio-tool-label::before {
  content: "";
  width: 0.46rem;
  height: 0.46rem;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 6px rgba(139,58,31,0.08);
}
.studio-tool-card h3,
.home-tool-card h3 {
  margin: 0;
  max-width: 12ch;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 4.2vw, 3rem);
  line-height: 0.98;
  font-weight: 520;
  letter-spacing: -0.035em;
}
.studio-tool-card p,
.home-tool-card p {
  margin: 0.85rem 0 0;
  max-width: 48ch;
  font-family: var(--font-serif);
  color: var(--ink-soft);
  line-height: 1.58;
}
.studio-tool-card ul {
  display: grid;
  gap: 0.55rem;
  margin: auto 0 0;
  padding: 1rem 0 0;
  border-top: 1px solid var(--line-soft);
  list-style: none;
  font-family: var(--font-sans);
  font-size: 0.93rem;
  color: var(--ink-soft);
}
.studio-tool-card li {
  display: flex;
  gap: 0.55rem;
  align-items: baseline;
}
.studio-tool-card li::before {
  content: "";
  flex: 0 0 auto;
  width: 0.36rem;
  height: 0.36rem;
  margin-top: 0.44rem;
  border-radius: 50%;
  background: var(--accent);
}
.studio-tool-cta,
.home-tool-card strong {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-top: 0.2rem;
  font-family: var(--font-sans);
  font-size: 0.98rem;
  font-weight: 540;
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 0.28rem;
  text-decoration-thickness: 1px;
}
.studio-tool-card--aeo,
.home-tool-card--aeo {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.32), rgba(255,255,255,0)),
    linear-gradient(145deg, var(--surface), #EFF2E8 72%);
}
.home-tools-section {
  border-top: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.30), transparent 34%),
    var(--bg);
}
.home-tool-card {
  min-height: clamp(300px, 28vw, 400px);
}
.home-tool-topline i {
  font-style: normal;
  color: var(--muted-2);
  letter-spacing: 0.12em;
}
.home-tool-meter {
  width: min(100%, 360px);
  height: 0.5rem;
  margin-top: auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(26,22,18,0.05);
  overflow: hidden;
}
.home-tool-meter span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--gold));
}

/* ── SEO/AEO checker page ───────────────────────────────────── */
.diagnostic-page {
  min-height: 100vh;
  padding-top: 0;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.24), transparent 36%),
    var(--bg);
}
.diagnostic-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  min-height: 76px;
  padding: 0 clamp(1rem, 4vw, 3rem);
  border-bottom: 1px solid rgba(217,210,196,0.82);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}
.diagnostic-logo {
  display: inline-flex;
  align-items: baseline;
  gap: 0.35rem;
  font-family: var(--font-logo);
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  font-style: italic;
  line-height: 1;
}
.diagnostic-logo span {
  font-family: var(--font-sans);
  font-size: 0.58em;
  font-style: normal;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
}
.diagnostic-nav-links {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-family: var(--font-sans);
  font-size: 0.9rem;
}
.diagnostic-nav-links a {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  padding: 0.55rem 0.95rem;
  border: 1px solid transparent;
  border-radius: 999px;
}
.diagnostic-nav-links a:hover,
.diagnostic-nav-links a:focus-visible {
  border-color: var(--line);
  background: var(--surface);
}
.diagnostic-a11y {
  display: none;
}
.diagnostic-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(340px, 0.68fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}
.diagnostic-page .diagnostic-hero {
  padding: clamp(2.25rem, 3.5vw, 3rem) 0 clamp(2.75rem, 5vw, 4rem);
}
.diagnostic-copy .h-display {
  margin-top: 1.2rem;
  max-width: 9ch;
}
.diagnostic-copy .lead {
  max-width: 62ch;
}
.diagnostic-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1.65rem;
}
.diagnostic-badges span {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0.45rem 0.8rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--font-sans);
  font-size: 0.82rem;
  color: var(--ink-soft);
  background: rgba(251,248,242,0.7);
}
.diagnostic-panel {
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.38), rgba(255,255,255,0)),
    var(--surface);
  box-shadow: var(--shadow-pop);
}
.diagnostic-form {
  display: grid;
  gap: 1rem;
  padding: clamp(1.1rem, 3vw, 1.6rem);
}
.diagnostic-form label {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--muted);
}
.diagnostic-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.7rem;
}
.diagnostic-input-row input {
  min-width: 0;
  min-height: 54px;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 0 1rem;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 1rem;
  outline: none;
}
.diagnostic-input-row input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(139,58,31,0.10);
}
.diagnostic-input-row button {
  min-height: 54px;
  border: 1px solid var(--ink);
  border-radius: var(--r-lg);
  padding: 0 1.1rem;
  background: var(--ink);
  color: var(--surface);
  font-family: var(--font-sans);
  font-weight: 560;
  white-space: nowrap;
}
.diagnostic-input-row button:disabled {
  opacity: 0.72;
  cursor: wait;
}
.diagnostic-form p {
  margin: 0;
  color: var(--muted);
  font-family: var(--font-serif);
  line-height: 1.55;
}
.diagnostic-results-wrap {
  padding-top: 0;
}
.aeo-results {
  display: grid;
  gap: 1rem;
}
.aeo-loading,
.aeo-error,
.aeo-score-card,
.aeo-action-panel {
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: var(--shadow-card);
}
.aeo-loading,
.aeo-error {
  padding: 1.35rem;
}
.aeo-loading {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  font-family: var(--font-sans);
  color: var(--ink-soft);
}
.aeo-loading span {
  width: 1rem;
  height: 1rem;
  border: 2px solid var(--line);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: aeo-spin 0.8s linear infinite;
}
@keyframes aeo-spin { to { transform: rotate(360deg); } }
.aeo-error strong,
.aeo-action-panel h3,
.aeo-score-card h2 {
  font-family: var(--font-display);
  letter-spacing: -0.03em;
}
.aeo-error p {
  margin: 0.3rem 0 0;
  color: var(--muted);
}
.aeo-score-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: clamp(1rem, 3vw, 1.8rem);
  align-items: center;
  padding: clamp(1.25rem, 3vw, 1.8rem);
}
.aeo-score-ring {
  width: clamp(110px, 14vw, 150px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, var(--surface) 0 57%, transparent 58%),
    conic-gradient(var(--accent) 0 var(--score), var(--line-soft) var(--score) 360deg);
  box-shadow: inset 0 0 0 1px var(--line);
  font-family: var(--font-sans);
  color: var(--ink);
}
.aeo-score-ring span {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 560;
  line-height: 0.9;
}
.aeo-score-ring small {
  align-self: start;
  margin-top: -1.15rem;
  color: var(--muted);
  font-size: 0.72rem;
}
.aeo-kicker {
  margin: 0 0 0.35rem;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}
.aeo-score-card h2 {
  margin: 0;
  font-size: clamp(1.45rem, 3vw, 2.25rem);
  line-height: 1.05;
}
.aeo-score-card p:last-child {
  margin: 0.65rem 0 0;
  color: var(--ink-soft);
  line-height: 1.55;
}
.aeo-category-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.7rem;
}
.aeo-cat {
  min-height: 118px;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--surface);
  font-family: var(--font-sans);
}
.aeo-cat strong {
  display: block;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  line-height: 1;
}
.aeo-cat span {
  display: block;
  margin-top: 0.45rem;
  color: var(--ink-soft);
  font-size: 0.82rem;
  line-height: 1.2;
}
.aeo-cat i {
  display: block;
  margin-top: 0.55rem;
  color: var(--muted);
  font-size: 0.74rem;
  font-style: normal;
}
.aeo-action-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  padding: 1.15rem 1.3rem;
}
.aeo-action-panel h3 {
  margin: 0;
  font-size: 1.22rem;
}
.aeo-action-panel a {
  flex: 0 0 auto;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  padding: 0 1rem;
  border-radius: var(--r-lg);
  background: var(--ink);
  color: var(--surface);
  font-family: var(--font-sans);
  font-size: 0.9rem;
}
.aeo-check-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}
.aeo-check {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 0.85rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--surface);
}
.aeo-check > span {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  line-height: 1;
}
.aeo-check.pass > span {
  background: rgba(94,122,74,0.13);
  color: var(--green);
}
.aeo-check.fail > span {
  background: rgba(139,58,31,0.13);
  color: var(--accent);
}
.aeo-check strong {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.96rem;
  line-height: 1.2;
}
.aeo-check p,
.aeo-check em {
  display: block;
  margin: 0.35rem 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
  font-style: normal;
}
.aeo-check em {
  color: var(--accent-deep);
}
.diagnostic-explain {
  border-top: 1px solid var(--line);
}
.diagnostic-explain-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.75fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 5rem);
}
.diagnostic-explain-grid .h-1 {
  margin: 1rem 0 0;
}
.diagnostic-explain-list {
  display: grid;
  gap: 1rem;
}
.diagnostic-explain-list article {
  padding: 1rem 0 1.05rem;
  border-bottom: 1px solid var(--line);
}
.diagnostic-explain-list strong {
  font-family: var(--font-sans);
  font-size: 1.02rem;
}
.diagnostic-explain-list p {
  margin: 0.35rem 0 0;
  color: var(--ink-soft);
  line-height: 1.55;
}
.diagnostic-deep-dive,
.diagnostic-playbook,
.diagnostic-faq {
  border-top: 1px solid var(--line);
}
.diagnostic-deep-head,
.diagnostic-faq-head {
  max-width: 860px;
}
.diagnostic-deep-head .h-1,
.diagnostic-faq-head .h-1,
.diagnostic-playbook-grid .h-1 {
  margin: 1rem 0 0;
}
.diagnostic-deep-head p,
.diagnostic-playbook-grid p {
  max-width: 68ch;
  margin: 1.1rem 0 0;
  color: var(--ink-soft);
  font-family: var(--font-serif);
  font-size: clamp(1.02rem, 1.6vw, 1.2rem);
  line-height: 1.65;
}
.diagnostic-signal-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  margin-top: clamp(2rem, 5vw, 3.5rem);
  border: 1px solid var(--line);
  background: var(--line);
}
.diagnostic-signal-grid article {
  min-height: 260px;
  display: flex;
  flex-direction: column;
  padding: clamp(1.1rem, 2.4vw, 1.6rem);
  background: var(--surface);
}
.diagnostic-signal-grid span {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  letter-spacing: 0.12em;
  color: var(--accent);
}
.diagnostic-signal-grid h3 {
  margin: auto 0 0;
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 2.4vw, 2rem);
  letter-spacing: -0.035em;
  line-height: 1.02;
}
.diagnostic-signal-grid p {
  margin: 1rem 0 0;
  color: var(--ink-soft);
  line-height: 1.55;
}
.diagnostic-playbook-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}
.diagnostic-playbook-grid a {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-top: 1.4rem;
  padding: 0 1rem;
  border: 1px solid var(--ink);
  border-radius: var(--r-lg);
  background: var(--ink);
  color: var(--surface);
  font-family: var(--font-sans);
  font-size: 0.9rem;
}
.diagnostic-priority-list {
  counter-reset: diagnostic-priority;
  list-style: none;
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
}
.diagnostic-priority-list li {
  counter-increment: diagnostic-priority;
  display: grid;
  grid-template-columns: 46px minmax(0, 0.72fr) minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
  padding: 1.05rem 0;
  border-bottom: 1px solid var(--line);
}
.diagnostic-priority-list li::before {
  content: counter(diagnostic-priority, decimal-leading-zero);
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--accent);
}
.diagnostic-priority-list strong {
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.25;
}
.diagnostic-priority-list span {
  color: var(--ink-soft);
  line-height: 1.55;
}
.diagnostic-faq .container {
  max-width: 1000px;
}
.diagnostic-related-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-top: 1.6rem;
}
.diagnostic-related-links a {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  font-family: var(--font-sans);
  font-size: 0.86rem;
  color: var(--ink-soft);
}
.diagnostic-related-links a:hover,
.diagnostic-related-links a:focus-visible {
  border-color: var(--accent);
  color: var(--ink);
}

html[data-theme="dark"] .tool-launchpad-section,
html[data-theme="dark"] .home-tools-section,
html[data-theme="dark"] .diagnostic-page {
  background: #11100F;
}
html[data-theme="dark"] .studio-tool-card,
html[data-theme="dark"] .home-tool-card,
html[data-theme="dark"] .diagnostic-panel,
html[data-theme="dark"] .aeo-loading,
html[data-theme="dark"] .aeo-error,
html[data-theme="dark"] .aeo-score-card,
html[data-theme="dark"] .aeo-action-panel,
html[data-theme="dark"] .aeo-cat,
html[data-theme="dark"] .aeo-check {
  background: #171514;
  border-color: rgba(247,240,232,0.14);
}
html[data-theme="dark"] .diagnostic-nav {
  border-color: rgba(247,240,232,0.12);
  background: rgba(17,16,15,0.88);
}
html[data-theme="dark"] .diagnostic-input-row input {
  background: #11100F;
  border-color: rgba(247,240,232,0.16);
}
html[data-theme="dark"] .diagnostic-badges span {
  background: rgba(247,240,232,0.06);
  border-color: rgba(247,240,232,0.14);
}
html[data-theme="dark"] .aeo-score-ring {
  background:
    radial-gradient(circle at center, #171514 0 57%, transparent 58%),
    conic-gradient(var(--accent-hover) 0 var(--score), rgba(247,240,232,0.12) var(--score) 360deg);
}
html[data-theme="dark"] .aeo-action-panel a,
html[data-theme="dark"] .diagnostic-input-row button,
html[data-theme="dark"] .diagnostic-playbook-grid a {
  background: var(--surface);
  color: var(--ink);
  border-color: var(--surface);
}
html[data-theme="dark"] .diagnostic-signal-grid {
  border-color: rgba(247,240,232,0.14);
  background: rgba(247,240,232,0.14);
}
html[data-theme="dark"] .diagnostic-signal-grid article,
html[data-theme="dark"] .diagnostic-related-links a {
  background: #171514;
  border-color: rgba(247,240,232,0.14);
}

@media (max-width: 980px) {
  .tool-launchpad-head,
  .home-tools-head,
  .diagnostic-shell,
  .diagnostic-explain-grid,
  .diagnostic-playbook-grid {
    grid-template-columns: 1fr;
  }
  .tool-launchpad-head,
  .home-tools-head {
    align-items: start;
  }
  .tool-launchpad-head .h-1,
  .home-tools-head .h-1,
  .diagnostic-copy .h-display {
    max-width: 12ch;
  }
  .aeo-category-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .diagnostic-signal-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .tool-launchpad-section {
    padding-bottom: 3.25rem;
  }
  .tool-launchpad-grid,
  .home-tools-grid,
  .aeo-check-grid {
    grid-template-columns: 1fr;
  }
  .studio-tool-card,
  .home-tool-card {
    padding: 1.2rem;
  }
  .studio-tool-card h3,
  .home-tool-card h3 {
    max-width: 11.5ch;
  }
  .home-tool-card {
    min-height: 0;
  }
  .diagnostic-nav {
    min-height: 66px;
    padding-inline: 1rem;
  }
  .diagnostic-nav-links {
    gap: 0;
    font-size: 0.82rem;
  }
  .diagnostic-nav-links a {
    padding-inline: 0.55rem;
  }
  .diagnostic-nav-links a:nth-child(2) {
    display: none;
  }
  .diagnostic-a11y {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    min-height: 42px;
    margin-left: 0.15rem;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: var(--surface);
    color: var(--ink);
    font-family: var(--font-mono);
    font-size: 0.72rem;
    cursor: pointer;
  }
  .diagnostic-a11y:hover,
  .diagnostic-a11y:focus-visible {
    border-color: var(--accent);
    color: var(--accent);
  }
  .diagnostic-page .diagnostic-hero {
    padding-top: 2rem;
    padding-bottom: 2.5rem;
  }
  .diagnostic-input-row {
    grid-template-columns: 1fr;
  }
  .diagnostic-input-row button {
    width: 100%;
  }
  .aeo-score-card {
    grid-template-columns: 1fr;
  }
  .aeo-category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .aeo-action-panel {
    align-items: stretch;
    flex-direction: column;
  }
  .aeo-action-panel a {
    justify-content: center;
  }
  .diagnostic-priority-list li {
    grid-template-columns: 40px minmax(0, 1fr);
  }
  .diagnostic-priority-list span {
    grid-column: 2;
  }
}

@media (max-width: 480px) {
  .aeo-category-grid {
    grid-template-columns: 1fr;
  }
  .diagnostic-signal-grid {
    grid-template-columns: 1fr;
  }
  .diagnostic-signal-grid article {
    min-height: 220px;
  }
  .home-tool-topline,
  .studio-tool-label {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.55rem;
  }
}

/* Regional country hubs: keep first-screen copy readable and CTA visible */
.region-hero {
  padding: clamp(4.2rem, 5.2vw, 5.6rem) 0 clamp(3rem, 4.2vw, 4.4rem);
}
.region-hero .loc-hero-copy .h-display {
  max-width: 19ch;
  font-size: clamp(2.9rem, 5vw, 4.9rem);
  line-height: 0.98;
}
.region-hero .loc-hero-copy .lead {
  max-width: 68ch;
  font-size: clamp(1rem, 1.35vw, 1.18rem);
}
@media (max-width: 640px) {
  .region-hero {
    padding: 4.15rem 0 2.9rem;
  }
  .region-hero .loc-hero-copy .h-display {
    max-width: 100%;
    font-size: clamp(2.05rem, 9.1vw, 3.05rem);
    line-height: 1.01;
  }
  .region-hero .loc-hero-copy .lead {
    font-size: 1rem;
    line-height: 1.55;
    margin-top: 1.25rem;
  }
  .region-hero .loc-actions {
    margin-top: 1.55rem;
  }
}

/* Paid landing-page sprint: proof-led conversion path */
.lp-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  margin-top: 2rem;
}
.lp-hero-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  align-items: center;
  padding-left: 0.5rem;
}
.lp-hero-links a {
  color: var(--ink-soft);
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}
.lp-hero-proof {
  margin: 1.5rem 0 0;
  max-width: 760px;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.6;
}
.lp-hero-proof strong { color: var(--ink); }
.landing-page-paid [data-split="words"],
.landing-page-paid [data-split="words"].split-done {
  visibility: visible;
}
.landing-page-paid [data-split="words"].split-done .word {
  animation: none;
  will-change: auto;
}
.lp-hero-proof a,
.lp-direct-contact a,
.lp-work-more a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}
.lp-proof-section {
  padding: 3.5rem 0;
  border-top: 1px solid rgba(255,255,255,0.12);
  border-bottom: 1px solid rgba(255,255,255,0.12);
  background: #171717;
  color: #f7f0e8;
}
.lp-proof-head,
.lp-work-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.75fr);
  gap: 3rem;
  align-items: end;
}
.lp-proof-head .eyebrow { color: rgba(247,240,232,0.62); }
.lp-proof-head .h-2 {
  margin: 0.85rem 0 0;
  color: #f7f0e8;
  font-size: clamp(1.8rem, 3vw, 2.8rem);
  line-height: 1.08;
  letter-spacing: 0;
}
.lp-proof-head p,
.lp-work-head p {
  margin: 0;
  color: rgba(247,240,232,0.68);
  line-height: 1.65;
}
.lp-proof-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 2.5rem;
  border-top: 1px solid rgba(247,240,232,0.2);
  border-bottom: 1px solid rgba(247,240,232,0.2);
}
.lp-proof-cell {
  min-width: 0;
  padding: 1.65rem 1.5rem;
  border-right: 1px solid rgba(247,240,232,0.2);
}
.lp-proof-cell:first-child { padding-left: 0; }
.lp-proof-cell:last-child { border-right: 0; }
.lp-proof-cell strong {
  display: block;
  color: #f7f0e8;
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 3.6vw, 3.2rem);
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0;
}
.lp-proof-cell span {
  display: block;
  margin-top: 0.6rem;
  color: rgba(247,240,232,0.62);
  font-size: 0.82rem;
  line-height: 1.45;
}
.lp-proof-profiles {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 2rem;
  margin-top: 1.35rem;
}
.lp-proof-profiles a {
  color: rgba(247,240,232,0.74);
  font-size: 0.8rem;
  line-height: 1.5;
  text-decoration: underline;
  text-decoration-color: rgba(247,240,232,0.35);
  text-underline-offset: 4px;
}
.lp-proof-profiles a:hover { color: #f7f0e8; }
.lp-proof-profiles strong { color: #f7f0e8; }
.lp-proof-work {
  display: grid;
  grid-template-columns: minmax(140px, 0.65fr) repeat(4, minmax(0, 1fr));
  gap: 0;
  align-items: stretch;
  margin-top: 1.5rem;
  border-top: 1px solid rgba(247,240,232,0.2);
  border-bottom: 1px solid rgba(247,240,232,0.2);
}
.lp-proof-work > span,
.lp-proof-work a {
  display: flex;
  align-items: center;
  min-width: 0;
  padding: 1rem 1.1rem;
  border-right: 1px solid rgba(247,240,232,0.2);
  color: rgba(247,240,232,0.68);
  font-size: 0.78rem;
  line-height: 1.45;
}
.lp-proof-work > span {
  padding-left: 0;
  color: rgba(247,240,232,0.52);
  font-weight: 600;
  text-transform: uppercase;
}
.lp-proof-work a:last-child { border-right: 0; }
.lp-proof-work a:hover { color: #f7f0e8; }
.lp-proof-work strong {
  margin-right: 0.35rem;
  color: #f7f0e8;
}

.lp-book-section {
  scroll-margin-top: 96px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.lp-book-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  column-gap: clamp(2.5rem, 6vw, 5.5rem);
  row-gap: 0;
  align-items: start;
}
.lp-book-intro {
  grid-column: 1;
  grid-row: 1;
}
.lp-book-details {
  grid-column: 1;
  grid-row: 2;
}
.lp-book-grid > .lp-form-card {
  grid-column: 2;
  grid-row: 1 / span 2;
}
.lp-inclusion-list {
  display: grid;
  gap: 0;
  margin: 0.75rem 0 0;
  padding: 0;
  border-top: 1px solid var(--line);
  list-style: none;
}
.lp-inclusion-list li {
  display: grid;
  grid-template-columns: 2.25rem minmax(0, 1fr);
  gap: 0.75rem;
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink-soft);
  line-height: 1.55;
}
.lp-inclusion-list li > span {
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
}
.lp-inclusion-list strong {
  display: block;
  color: var(--ink);
  font-size: 0.92rem;
}
.lp-inclusion-list small {
  display: block;
  margin-top: 0.2rem;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.5;
}
.lp-stack-label {
  margin: 1.65rem 0 0;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
}
.lp-guarantee {
  margin-top: 1.25rem;
  padding: 1.1rem 1.2rem;
  border-left: 3px solid var(--accent);
  background: var(--accent-soft);
}
.lp-guarantee strong {
  color: var(--ink);
  font-size: 0.9rem;
}
.lp-guarantee p {
  margin: 0.35rem 0 0;
  color: var(--ink-soft);
  font-size: 0.84rem;
  line-height: 1.55;
}
.lp-direct-contact {
  margin: 1.5rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.65;
}
.lp-form-card {
  padding: 2.5rem;
  border-radius: 8px;
}
.field-required,
.field-optional {
  margin-left: 0.35rem;
  color: var(--muted);
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
}
.field-required { color: var(--accent-deep); }
.field-help {
  display: block;
  margin-top: 0.45rem;
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.4;
}
.lp-form-actions {
  display: grid;
  gap: 1rem;
}
.form-editorial .form-consent {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 0.75rem;
  align-items: start;
  margin: 0;
  color: var(--muted);
  font-family: var(--font-sans);
  font-size: 0.76rem;
  font-weight: 400;
  line-height: 1.55;
  letter-spacing: 0;
  text-align: left;
  text-transform: none;
}
.form-editorial .form-consent input {
  width: 18px;
  height: 18px;
  margin: 1px 0 0;
  padding: 0;
  border: 1px solid var(--muted-2);
  border-radius: 4px;
  accent-color: var(--accent);
}
.form-editorial .lp-form-actions .lp-submit {
  margin-top: 0.25rem;
}
.lp-submit {
  width: 100%;
  min-height: 52px;
  padding: 1rem;
}
.lp-form-privacy {
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.5;
  text-align: center;
}

.lp-work-section {
  border-bottom: 1px solid var(--line);
  background: var(--bg-soft);
}
.lp-work-head .h-1 {
  margin: 1rem 0 0;
  letter-spacing: 0;
}
.lp-work-head p { color: var(--muted); }
.lp-work-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.25rem;
  margin-top: 2.5rem;
}
.lp-work-card {
  display: flex;
  min-width: 0;
  overflow: hidden;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  transition: border-color .2s ease, transform .25s ease;
}
.lp-work-card:hover {
  border-color: var(--ink-soft);
  transform: translateY(-3px);
}
.lp-work-image {
  display: block;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  border-bottom: 1px solid var(--line);
  background: var(--bg);
}
.lp-work-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform .35s ease;
}
.lp-work-card:hover .lp-work-image img { transform: scale(1.02); }
.lp-work-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 1.45rem;
}
.lp-work-body > span {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.lp-work-body h3 {
  margin: 0.65rem 0 0;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 550;
  letter-spacing: 0;
}
.lp-work-body p {
  margin: 0.7rem 0 1.25rem;
  color: var(--muted);
  line-height: 1.6;
}
.lp-work-body a {
  align-self: flex-start;
  margin-top: auto;
  color: var(--ink);
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.lp-work-more { margin: 1.75rem 0 0; text-align: right; }
.landing-page-paid .footer-top {
  grid-template-columns: minmax(0, 760px);
  gap: 0;
}
.landing-page-paid .a11y-launcher,
.landing-page-paid .a11y-panel,
.landing-page-paid .wa-launcher,
.landing-page-paid .chat-launcher,
.landing-page-paid .chat-panel {
  display: none !important;
}
.landing-page-paid:has(.cookie-banner) .audit-cta { display: none; }
@media (min-width: 681px) {
  .landing-page-paid .cookie-banner {
    right: 1.5rem;
    left: auto;
    width: min(440px, calc(100vw - 3rem));
    max-width: none;
    margin: 0;
    border-radius: 8px;
  }
}

@media (max-width: 900px) {
  .lp-proof-head,
  .lp-work-head,
  .lp-book-grid { grid-template-columns: 1fr; gap: 1.75rem; }
  .lp-book-intro,
  .lp-book-details,
  .lp-book-grid > .lp-form-card {
    grid-column: 1;
    grid-row: auto;
  }
  .lp-book-intro { order: 1; }
  .lp-book-grid > .lp-form-card { order: 2; }
  .lp-book-details { order: 3; }
  .lp-proof-work { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lp-proof-work > span { grid-column: 1 / -1; border-right: 0; }
  .lp-work-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 680px) {
  .landing-page-paid .cookie-banner { bottom: 0.75rem !important; }
  .lp-book-section { scroll-margin-top: 80px; }
  .lp-hero-actions { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.7rem; }
  .lp-hero-actions .btn { justify-content: center; min-width: 0; padding: 0.85rem 0.7rem; font-size: 0.8rem; }
  .lp-hero-links { justify-content: space-between; padding: 0.45rem 0 0; }
  .lp-hero-links a { font-size: 0.82rem; }
  .lp-proof-section { padding: 2.75rem 0; }
  .lp-proof-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lp-proof-cell { padding: 1.35rem 1rem; border-bottom: 1px solid rgba(247,240,232,0.2); }
  .lp-proof-cell:nth-child(2) { border-right: 0; }
  .lp-proof-cell:nth-child(3),
  .lp-proof-cell:nth-child(4) { border-bottom: 0; }
  .lp-proof-cell:nth-child(3) { padding-left: 0; }
  .lp-proof-profiles { display: grid; gap: 0.75rem; }
  .lp-proof-work { grid-template-columns: 1fr; }
  .lp-proof-work > span,
  .lp-proof-work a {
    grid-column: auto;
    padding: 0.8rem 0;
    border-right: 0;
    border-bottom: 1px solid rgba(247,240,232,0.2);
  }
  .lp-proof-work a:last-child { border-bottom: 0; }
  .lp-work-grid { grid-template-columns: 1fr; }
  .lp-work-card:hover { transform: none; }
  .lp-work-more { text-align: left; }
}

/* Ads Command */
.agency-command-page {
  --ac-bg: #f4f6f5;
  --ac-surface: #ffffff;
  --ac-ink: #171a19;
  --ac-muted: #66706c;
  --ac-line: #dce2df;
  --ac-line-strong: #c3ccc8;
  --ac-green: #16735e;
  --ac-green-soft: #e7f2ee;
  --ac-blue: #285da8;
  --ac-blue-soft: #e9f0fa;
  --ac-amber: #a76412;
  --ac-amber-soft: #fff2dc;
  --ac-red: #a53b42;
  --ac-red-soft: #fae9eb;
  --ac-sidebar: #171a19;
  --ac-sidebar-muted: #9ca6a2;
  margin: 0;
  padding-top: 0;
  min-width: 320px;
  min-height: 100vh;
  overflow: hidden;
  background: var(--ac-bg);
  color: var(--ac-ink);
  font-family:var(--font-serif);
}
.agency-command-page * { box-sizing: border-box; }
.agency-command-page button,
.agency-command-page input,
.agency-command-page select,
.agency-command-page textarea { font: inherit; letter-spacing: 0; }
.agency-command-page button { cursor: pointer; }
.agency-command-page [hidden] { display: none !important; }
.agency-command-page svg { width: 18px; height: 18px; stroke-width: 1.8; }

.agency-auth {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 1.25rem;
  background: #121514;
}
.agency-auth-box {
  width: min(420px, 100%);
  padding: 2rem;
  border: 1px solid #343a37;
  border-radius: 8px;
  background: #1a1e1c;
  color: #fff;
}
.agency-auth-box h1 { margin: 0 0 1.8rem; font-size: 2rem; letter-spacing: 0; }
.agency-auth-box label,
.agency-form-grid label,
.agency-modal > form > label {
  display: grid;
  gap: 0.45rem;
  color: inherit;
  font-size: 0.78rem;
  font-weight: 600;
}
.agency-auth-box input,
.agency-form-grid input,
.agency-form-grid select,
.agency-modal > form > label select {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--ac-line-strong);
  border-radius: 6px;
  padding: 0.65rem 0.75rem;
  background: var(--ac-surface);
  color: var(--ac-ink);
  outline: none;
}
.agency-auth-box input { margin-bottom: 0.9rem; border-color: #454d49; background: #101311; color: #fff; }
.agency-auth-box input:focus,
.agency-form-grid input:focus,
.agency-form-grid select:focus { border-color: var(--ac-green); box-shadow: 0 0 0 3px rgba(22,115,94,0.12); }
.agency-mark {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  margin-bottom: 1.3rem;
  border-radius: 7px;
  background: var(--ac-green);
  color: #fff;
}
.agency-eyebrow {
  margin: 0 0 0.35rem;
  color: var(--ac-muted);
  font-family:var(--font-mono);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.agency-auth-box .agency-eyebrow { color: #91a09a; }
.agency-form-error { min-height: 1.2rem; margin: 0.7rem 0 0; color: #f29096; font-size: 0.78rem; }

.agency-shell { display: grid; grid-template-columns: 244px minmax(0, 1fr); height: 100vh; }
.agency-sidebar {
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 1rem 0.85rem;
  overflow-y: auto;
  background: var(--ac-sidebar);
  color: #fff;
  border-right: 1px solid #111;
}
.agency-brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  min-height: 48px;
  padding: 0.25rem 0.35rem;
  color: #fff;
  text-decoration: none;
}
.agency-brand-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border-radius: 7px;
  background: var(--ac-green);
}
.agency-brand strong,
.agency-brand small { display: block; letter-spacing: 0; }
.agency-brand strong { font-size: 0.94rem; }
.agency-brand small { margin-top: 0.08rem; color: var(--ac-sidebar-muted); font-size: 0.66rem; font-weight: 500; }
.agency-project-select-wrap { margin: 1.15rem 0 1rem; padding: 0.75rem; border: 1px solid #343a37; border-radius: 7px; }
.agency-project-select-wrap label { display: block; margin-bottom: 0.45rem; color: var(--ac-sidebar-muted); font-size: 0.64rem; font-weight: 600; text-transform: uppercase; }
.agency-project-select-wrap select {
  width: 100%;
  border: 0;
  padding: 0;
  background: transparent;
  color: #fff;
  font-size: 0.86rem;
  font-weight: 650;
  outline: none;
}
.agency-project-select-wrap option { color: #111; }
.agency-nav { display: grid; gap: 0.2rem; }
.agency-nav-item,
.agency-sidebar-footer a,
.agency-sidebar-footer button {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.55rem;
  width: 100%;
  min-height: 40px;
  padding: 0.55rem 0.7rem;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #bac2bf;
  text-align: left;
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 550;
}
.agency-nav-item:hover,
.agency-sidebar-footer a:hover,
.agency-sidebar-footer button:hover { background: #232825; color: #fff; }
.agency-nav-item.active { background: #2b322f; color: #fff; }
.agency-nav-item.active svg { color: #65c7aa; }
.agency-nav-item em {
  min-width: 22px;
  padding: 0.15rem 0.32rem;
  border-radius: 5px;
  background: #303734;
  color: #d6ddda;
  font-family:var(--font-mono);
  font-size: 0.6rem;
  font-style: normal;
  text-align: center;
}
.agency-sidebar-footer { display: grid; gap: 0.15rem; margin-top: auto; padding-top: 1rem; border-top: 1px solid #303633; }

.agency-main { min-width: 0; overflow-y: auto; background: var(--ac-bg); }
.agency-topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 76px;
  padding: 0.9rem 1.5rem;
  border-bottom: 1px solid var(--ac-line);
  background: rgba(244,246,245,0.96);
  backdrop-filter: blur(10px);
}
.agency-title-block > p { margin: 0 0 0.2rem; color: var(--ac-muted); font-size: 0.7rem; }
.agency-title-line { display: flex; align-items: center; gap: 0.7rem; }
.agency-title-line h1 { margin: 0; font-size: 1.45rem; font-weight: 700; letter-spacing: 0; }
.agency-status-dot,
.agency-chip {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 24px;
  border-radius: 5px;
  padding: 0.25rem 0.5rem;
  font-size: 0.68rem;
  font-weight: 650;
  text-transform: capitalize;
}
.agency-status-dot { background: var(--ac-green-soft); color: var(--ac-green); }
.agency-topbar-actions,
.agency-toolbar-controls,
.agency-modal-actions { display: flex; align-items: center; gap: 0.55rem; }
.agency-range-control { display: inline-grid; grid-template-columns: repeat(3, 42px); overflow: hidden; border: 1px solid var(--ac-line-strong); border-radius: 6px; background: var(--ac-surface); }
.agency-range-control button { height: 34px; border: 0; border-right: 1px solid var(--ac-line); background: transparent; color: var(--ac-muted); font-size: 0.68rem; font-weight: 700; }
.agency-range-control button:last-child { border-right: 0; }
.agency-range-control button.active { background: var(--ac-ink); color: #fff; }
.agency-primary-btn,
.agency-secondary-btn,
.agency-icon-btn,
.agency-text-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 36px;
  border-radius: 6px;
  padding: 0.55rem 0.8rem;
  font-size: 0.76rem;
  font-weight: 650;
}
.agency-primary-btn { border: 1px solid var(--ac-green); background: var(--ac-green); color: #fff; }
.agency-primary-btn:hover { background: #115e4d; }
.agency-secondary-btn { border: 1px solid var(--ac-line-strong); background: var(--ac-surface); color: var(--ac-ink); }
.agency-secondary-btn.danger { color: var(--ac-red); }
.agency-icon-btn { width: 36px; padding: 0; border: 1px solid var(--ac-line-strong); background: var(--ac-surface); color: var(--ac-ink); }
.agency-text-btn { border: 0; background: transparent; color: var(--ac-green); padding-right: 0; }
.agency-primary-btn svg,
.agency-secondary-btn svg,
.agency-icon-btn svg,
.agency-text-btn svg { width: 15px; height: 15px; }

.agency-alert-strip {
  margin: 1rem 1.5rem 0;
  padding: 0.75rem 0.9rem;
  border: 1px solid #e3b967;
  border-radius: 6px;
  background: var(--ac-amber-soft);
  color: #764605;
  font-size: 0.8rem;
}
.agency-view { display: none; padding: 1.35rem 1.5rem 3rem; }
.agency-view.active { display: block; }
.agency-metric-band {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  margin-bottom: 1.2rem;
  overflow: hidden;
  border: 1px solid var(--ac-line);
  border-radius: 7px;
  background: var(--ac-line);
  gap: 1px;
}
.agency-metric-band.compact { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.agency-metric {
  min-width: 0;
  min-height: 112px;
  padding: 1rem;
  background: var(--ac-surface);
}
.agency-metric-label { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; color: var(--ac-muted); font-size: 0.68rem; font-weight: 600; }
.agency-metric-label svg { width: 15px; height: 15px; }
.agency-metric strong { display: block; margin-top: 0.75rem; overflow-wrap: anywhere; font-size: 1.65rem; line-height: 1; letter-spacing: 0; }
.agency-metric small { display: block; margin-top: 0.55rem; color: var(--ac-muted); font-size: 0.68rem; }

.agency-overview-grid { display: grid; grid-template-columns: minmax(0, 1.75fr) minmax(270px, 0.65fr); gap: 1rem; margin-bottom: 1.35rem; }
.agency-surface,
.agency-health-panel,
.agency-settings-band,
.agency-report-header {
  border: 1px solid var(--ac-line);
  border-radius: 7px;
  background: var(--ac-surface);
}
.agency-surface { padding: 1.15rem; }
.agency-section-head,
.agency-view-toolbar,
.agency-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}
.agency-section-head { margin-bottom: 1rem; }
.agency-section-head h2,
.agency-view-toolbar h2,
.agency-modal-head h2 { margin: 0; font-size: 1.06rem; letter-spacing: 0; }
.agency-view-toolbar { align-items: center; margin-bottom: 1.15rem; }
.agency-chart-legend { display: flex; align-items: center; gap: 0.75rem; color: var(--ac-muted); font-size: 0.68rem; }
.agency-chart-legend span { display: inline-flex; align-items: center; gap: 0.35rem; }
.agency-chart-legend i { width: 8px; height: 8px; border-radius: 2px; }
.agency-chart-legend i.spend { background: var(--ac-blue); }
.agency-chart-legend i.lead { background: var(--ac-green); }
.agency-chart-wrap { position: relative; min-height: 270px; }
.agency-chart-wrap svg { width: 100%; height: 270px; overflow: visible; }
.agency-chart-empty { position: absolute; inset: 0; display: grid; place-items: center; color: var(--ac-muted); font-size: 0.8rem; }
.agency-health-panel { padding: 1.15rem; background: #1b211e; color: #fff; border-color: #1b211e; }
.agency-health-score { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; padding-bottom: 1rem; border-bottom: 1px solid #39413d; }
.agency-health-score strong { font-size: 2.4rem; letter-spacing: 0; }
.agency-health-score span { color: #aeb8b4; font-size: 0.72rem; }
.agency-health-list { display: grid; gap: 0.75rem; margin-top: 1rem; }
.agency-health-row { display: grid; grid-template-columns: 18px minmax(0,1fr) auto; align-items: center; gap: 0.55rem; font-size: 0.76rem; }
.agency-health-row svg { width: 15px; height: 15px; }
.agency-health-row.good svg { color: #64c8aa; }
.agency-health-row.warn svg { color: #f2bc63; }
.agency-health-row small { color: #aeb8b4; font-size: 0.65rem; }

.agency-table-section { margin-top: 1.35rem; }
.agency-table-wrap { width: 100%; overflow-x: auto; border: 1px solid var(--ac-line); border-radius: 7px; background: var(--ac-surface); }
.agency-data-table { width: 100%; min-width: 780px; border-collapse: collapse; table-layout: auto; }
.agency-data-table th,
.agency-data-table td { padding: 0.78rem 0.85rem; border-bottom: 1px solid var(--ac-line); text-align: left; vertical-align: middle; white-space: nowrap; font-size: 0.75rem; }
.agency-data-table th { background: #f7f8f7; color: var(--ac-muted); font-size: 0.63rem; font-weight: 700; text-transform: uppercase; }
.agency-data-table tbody tr:last-child td { border-bottom: 0; }
.agency-data-table tbody tr:hover td { background: #f9fbfa; }
.agency-data-table td strong { display: block; max-width: 360px; overflow: hidden; text-overflow: ellipsis; }
.agency-data-table td small { display: block; margin-top: 0.2rem; color: var(--ac-muted); }
.agency-table-number { font-family:var(--font-mono); font-size: 0.7rem; }
.agency-chip.green { background: var(--ac-green-soft); color: var(--ac-green); }
.agency-chip.blue { background: var(--ac-blue-soft); color: var(--ac-blue); }
.agency-chip.amber { background: var(--ac-amber-soft); color: var(--ac-amber); }
.agency-chip.red { background: var(--ac-red-soft); color: var(--ac-red); }
.agency-chip.gray { background: #edf0ef; color: #606966; }
.agency-lower-grid { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: 1rem; margin-top: 1.35rem; }
.agency-funnel { display: grid; gap: 0.8rem; }
.agency-funnel-row { display: grid; grid-template-columns: 82px minmax(0,1fr) 42px; align-items: center; gap: 0.7rem; font-size: 0.72rem; }
.agency-funnel-track { height: 10px; overflow: hidden; border-radius: 3px; background: #edf0ef; }
.agency-funnel-fill { height: 100%; min-width: 2px; background: var(--ac-green); }
.agency-funnel-row strong { text-align: right; font-family:var(--font-mono); }
.agency-activity-list { display: grid; gap: 0; }
.agency-activity-item { display: grid; grid-template-columns: 34px minmax(0,1fr) auto; align-items: center; gap: 0.7rem; width: 100%; min-height: 54px; padding: 0; border: 0; border-bottom: 1px solid var(--ac-line); background: transparent; color: var(--ac-ink); text-align: left; }
.agency-activity-item:last-child { border-bottom: 0; }
.agency-avatar { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 6px; background: var(--ac-blue-soft); color: var(--ac-blue); font-size: 0.68rem; font-weight: 750; }
.agency-activity-item strong,
.agency-activity-item small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.agency-activity-item strong { font-size: 0.76rem; }
.agency-activity-item small { margin-top: 0.15rem; color: var(--ac-muted); font-size: 0.66rem; }
.agency-activity-item time { color: var(--ac-muted); font-family:var(--font-mono); font-size: 0.62rem; }
.agency-empty { display: grid; place-items: center; min-height: 140px; color: var(--ac-muted); font-size: 0.78rem; text-align: center; }

.agency-campaign-summary { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 1px; margin-bottom: 1rem; overflow: hidden; border: 1px solid var(--ac-line); border-radius: 7px; background: var(--ac-line); }
.agency-summary-cell { padding: 0.95rem; background: var(--ac-surface); }
.agency-summary-cell span { display: block; color: var(--ac-muted); font-size: 0.65rem; }
.agency-summary-cell strong { display: block; margin-top: 0.45rem; font-size: 1.2rem; }
.agency-detail-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 1rem; margin-top: 1rem; }
.agency-detail-block { padding: 1rem; border: 1px solid var(--ac-line); border-radius: 7px; background: var(--ac-surface); }
.agency-detail-block h3 { margin: 0 0 0.75rem; font-size: 0.88rem; }
.agency-key-value { display: grid; grid-template-columns: 110px minmax(0,1fr); gap: 0.6rem; padding: 0.45rem 0; border-bottom: 1px solid var(--ac-line); font-size: 0.7rem; }
.agency-key-value:last-child { border-bottom: 0; }
.agency-key-value span { color: var(--ac-muted); }
.agency-key-value strong { overflow-wrap: anywhere; }

.agency-search-control { display: flex; align-items: center; gap: 0.45rem; min-width: 220px; min-height: 36px; padding: 0 0.65rem; border: 1px solid var(--ac-line-strong); border-radius: 6px; background: var(--ac-surface); }
.agency-search-control svg { width: 15px; height: 15px; color: var(--ac-muted); }
.agency-search-control input { width: 100%; border: 0; outline: 0; background: transparent; color: var(--ac-ink); font-size: 0.75rem; }
.agency-toolbar-controls > select { min-height: 36px; border: 1px solid var(--ac-line-strong); border-radius: 6px; padding: 0 0.65rem; background: var(--ac-surface); color: var(--ac-ink); font-size: 0.75rem; }
.agency-toggle { display: inline-flex; align-items: center; gap: 0.45rem; color: var(--ac-muted); font-size: 0.72rem; font-weight: 600; }
.agency-toggle input { position: absolute; opacity: 0; }
.agency-toggle span { position: relative; width: 34px; height: 19px; border-radius: 10px; background: #c9d0cd; }
.agency-toggle span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 13px; height: 13px; border-radius: 50%; background: #fff; transition: transform .16s ease; }
.agency-toggle input:checked + span { background: var(--ac-green); }
.agency-toggle input:checked + span::after { transform: translateX(15px); }

.agency-lead-workspace { display: grid; grid-template-columns: minmax(340px, 0.85fr) minmax(0, 1.15fr); min-height: 620px; overflow: hidden; border: 1px solid var(--ac-line); border-radius: 7px; background: var(--ac-surface); }
.agency-lead-list { overflow-y: auto; border-right: 1px solid var(--ac-line); }
.agency-lead-row { display: grid; grid-template-columns: 34px minmax(0,1fr) auto; gap: 0.7rem; align-items: center; width: 100%; min-height: 68px; padding: 0.75rem; border: 0; border-bottom: 1px solid var(--ac-line); background: transparent; color: var(--ac-ink); text-align: left; }
.agency-lead-row:hover,
.agency-lead-row.active { background: #f2f7f5; }
.agency-lead-row.active { box-shadow: inset 3px 0 0 var(--ac-green); }
.agency-lead-row strong,
.agency-lead-row small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.agency-lead-row strong { font-size: 0.78rem; }
.agency-lead-row small { margin-top: 0.2rem; color: var(--ac-muted); font-size: 0.67rem; }
.agency-lead-meta { display: grid; justify-items: end; gap: 0.3rem; }
.agency-lead-meta time { color: var(--ac-muted); font-size: 0.62rem; }
.agency-lead-detail { min-width: 0; padding: 1.15rem; overflow-y: auto; background: #fbfcfb; }
.agency-lead-detail-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding-bottom: 1rem; border-bottom: 1px solid var(--ac-line); }
.agency-lead-detail-head h2 { margin: 0; font-size: 1.25rem; }
.agency-lead-detail-head p { margin: 0.25rem 0 0; color: var(--ac-muted); font-size: 0.72rem; }
.agency-lead-head-actions { display: flex; align-items: center; gap: 0.55rem; }
.agency-lead-controls { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 0.7rem; margin: 1rem 0; }
.agency-lead-control-wide { grid-column: 1/-1; }
.agency-lead-test-toggle { align-self: end; }
.agency-lead-controls label { display: grid; gap: 0.35rem; color: var(--ac-muted); font-size: 0.65rem; font-weight: 650; }
.agency-lead-controls input,
.agency-lead-controls select { width: 100%; min-height: 38px; border: 1px solid var(--ac-line-strong); border-radius: 6px; padding: 0.55rem; background: var(--ac-surface); color: var(--ac-ink); }
.agency-lead-sections { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 0.9rem; }
.agency-lead-section { min-width: 0; padding: 0.85rem; border: 1px solid var(--ac-line); border-radius: 6px; background: var(--ac-surface); }
.agency-lead-section.wide { grid-column: 1/-1; }
.agency-lead-section h3 { margin: 0 0 0.6rem; font-size: 0.76rem; }
.agency-lead-section dl { margin: 0; }
.agency-lead-section dl div { display: grid; grid-template-columns: 100px minmax(0,1fr); gap: 0.55rem; padding: 0.38rem 0; border-bottom: 1px solid var(--ac-line); font-size: 0.68rem; }
.agency-lead-section dl div:last-child { border-bottom: 0; }
.agency-lead-section dt { color: var(--ac-muted); }
.agency-lead-section dd { margin: 0; overflow-wrap: anywhere; }
.agency-note-form { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 0.55rem; }
.agency-note-form textarea { min-height: 70px; resize: vertical; border: 1px solid var(--ac-line-strong); border-radius: 6px; padding: 0.6rem; }
.agency-note-list { display: grid; gap: 0.55rem; margin-top: 0.75rem; }
.agency-note { padding: 0.6rem; border-left: 2px solid var(--ac-green); background: #f4f8f6; font-size: 0.7rem; }
.agency-note time { display: block; margin-top: 0.35rem; color: var(--ac-muted); font-size: 0.6rem; }
.agency-timeline { display: grid; gap: 0.65rem; }
.agency-timeline-item { display: grid; grid-template-columns: 30px minmax(0,1fr); gap: 0.65rem; padding-bottom: 0.65rem; border-bottom: 1px solid var(--ac-line); }
.agency-timeline-item:last-child { padding-bottom: 0; border-bottom: 0; }
.agency-timeline-item > span { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 5px; background: #eef1ef; color: var(--ac-muted); }
.agency-timeline-item.email > span { background: var(--ac-green-soft); color: var(--ac-green); }
.agency-timeline-item.reply > span,
.agency-timeline-item.booking > span { background: var(--ac-blue-soft); color: var(--ac-blue); }
.agency-timeline-item svg { width: 14px; height: 14px; }
.agency-timeline-item strong,
.agency-timeline-item small { display: block; }
.agency-timeline-item strong { font-size: 0.72rem; }
.agency-timeline-item small { margin-top: 0.18rem; color: var(--ac-muted); font-size: 0.62rem; }
.agency-timeline-item p { margin: 0.5rem 0 0; color: var(--ac-muted); font-size: 0.68rem; line-height: 1.5; white-space: pre-wrap; }

.agency-pipeline-total { text-align: right; }
.agency-pipeline-total span,
.agency-pipeline-total strong { display: block; }
.agency-pipeline-total span { color: var(--ac-muted); font-size: 0.65rem; }
.agency-pipeline-total strong { margin-top: 0.2rem; font-size: 1.1rem; }
.agency-pipeline-board { display: grid; grid-template-columns: repeat(6,minmax(230px,1fr)); gap: 0.8rem; overflow-x: auto; padding-bottom: 0.6rem; }
.agency-pipeline-column { min-height: 520px; padding: 0.65rem; border: 1px solid var(--ac-line); border-radius: 7px; background: #eef1ef; }
.agency-pipeline-column.drag-over { border-color: var(--ac-green); background: var(--ac-green-soft); }
.agency-pipeline-head { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; min-height: 38px; padding: 0 0.15rem 0.55rem; }
.agency-pipeline-head strong { font-size: 0.75rem; text-transform: capitalize; }
.agency-pipeline-head span { color: var(--ac-muted); font-family:var(--font-mono); font-size: 0.62rem; }
.agency-pipeline-cards { display: grid; gap: 0.55rem; }
.agency-deal-card { padding: 0.75rem; border: 1px solid var(--ac-line); border-radius: 6px; background: var(--ac-surface); box-shadow: 0 2px 6px rgba(18,29,24,0.04); cursor: grab; }
.agency-deal-card:active { cursor: grabbing; }
.agency-deal-card strong,
.agency-deal-card small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.agency-deal-card strong { font-size: 0.76rem; }
.agency-deal-card small { margin-top: 0.2rem; color: var(--ac-muted); font-size: 0.65rem; }
.agency-deal-foot { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; margin-top: 0.7rem; color: var(--ac-muted); font-size: 0.62rem; }
.agency-deal-foot b { color: var(--ac-ink); }

.agency-research-layout { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 1rem; }
.agency-research-tools { display: flex; flex-wrap: wrap; gap: 0.45rem; margin-top: 0.8rem; }
.agency-research-tools span { padding: 0.35rem 0.5rem; border: 1px solid var(--ac-line); border-radius: 5px; background: #f7f8f7; font-size: 0.68rem; font-weight: 600; }
.agency-research-copy { margin: 0.8rem 0 0; color: var(--ac-muted); font-size: 0.78rem; line-height: 1.55; }
.agency-check-list { display: grid; gap: 0.65rem; margin-top: 0.8rem; }
.agency-check-item { display: grid; grid-template-columns: 18px minmax(0,1fr) auto; gap: 0.5rem; align-items: center; font-size: 0.72rem; }
.agency-check-item svg { width: 15px; height: 15px; color: var(--ac-green); }
.agency-rejection-list { display: grid; gap: 1px; overflow: hidden; border: 1px solid var(--ac-line); border-radius: 7px; background: var(--ac-line); }
.agency-rejection-item { display: grid; grid-template-columns: minmax(220px,0.55fr) minmax(0,1.45fr); gap: 1rem; padding: 0.85rem; background: var(--ac-surface); font-size: 0.74rem; }
.agency-rejection-item span { color: var(--ac-muted); }
.agency-updated-label { color: var(--ac-muted); font-family:var(--font-mono); font-size: 0.65rem; }

.agency-report-header { display: grid; grid-template-columns: minmax(0,1.4fr) repeat(3,minmax(130px,0.5fr)); gap: 1px; margin-bottom: 1rem; overflow: hidden; background: var(--ac-line); }
.agency-report-cell { padding: 1rem; background: var(--ac-surface); }
.agency-report-cell span { display: block; color: var(--ac-muted); font-size: 0.65rem; }
.agency-report-cell strong { display: block; margin-top: 0.4rem; font-size: 1.2rem; }
.agency-report-cell.lead strong { font-size: 1rem; }
.agency-connection-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 0.8rem; }
.agency-connection { display: grid; grid-template-columns: 38px minmax(0,1fr) auto; align-items: center; gap: 0.7rem; min-height: 86px; padding: 0.85rem; border: 1px solid var(--ac-line); border-radius: 7px; background: var(--ac-surface); }
.agency-connection-icon { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 6px; background: #eef1ef; color: var(--ac-ink); }
.agency-connection strong,
.agency-connection small { display: block; }
.agency-connection strong { font-size: 0.78rem; }
.agency-connection small { margin-top: 0.2rem; color: var(--ac-muted); font-size: 0.65rem; }
.agency-settings-band { margin-top: 1rem; padding: 1rem; }
.agency-sync-meta { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 1rem; }
.agency-sync-meta span,
.agency-sync-meta strong { display: block; }
.agency-sync-meta span { color: var(--ac-muted); font-size: 0.65rem; }
.agency-sync-meta strong { margin-top: 0.35rem; overflow-wrap: anywhere; font-size: 0.76rem; }
.agency-sync-actions { display: flex; justify-content: flex-end; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--ac-line); }
.agency-sync-actions-split { justify-content: space-between; }
.agency-sync-actions-split > span { display: flex; gap: 0.55rem; }
.agency-readiness-list { display: grid; gap: 0.45rem; margin-top: 1rem; padding: 0.8rem; border: 1px solid #f0d4d0; border-radius: 6px; background: #fff7f5; color: #8f322d; }
.agency-readiness-list.ready { border-color: #cce6da; background: var(--ac-green-soft); color: var(--ac-green); }
.agency-readiness-list span { display: flex; align-items: center; gap: 0.45rem; font-size: 0.7rem; }
.agency-readiness-list svg { width: 15px; height: 15px; flex: none; }
.agency-primary-btn:disabled,
.agency-secondary-btn:disabled { cursor: not-allowed; opacity: 0.5; }
.agency-project-profile-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 1rem; }
.agency-project-profile-grid div span,
.agency-project-profile-grid div strong { display: block; }
.agency-project-profile-grid div span { color: var(--ac-muted); font-size: 0.65rem; }
.agency-project-profile-grid div strong { margin-top: 0.35rem; overflow-wrap: anywhere; font-size: 0.76rem; }

.agency-modal { width: min(680px, calc(100% - 2rem)); max-height: calc(100vh - 2rem); overflow-y: auto; border: 1px solid var(--ac-line-strong); border-radius: 8px; padding: 0; background: var(--ac-surface); color: var(--ac-ink); box-shadow: 0 20px 60px rgba(0,0,0,0.22); }
.agency-modal-wide { width: min(820px, calc(100% - 2rem)); }
.agency-modal::backdrop { background: rgba(12,16,14,0.58); }
.agency-modal form { padding: 1.25rem; }
.agency-modal-head { align-items: center; margin-bottom: 1.15rem; }
.agency-code-output { width: 100%; min-height: 380px; resize: vertical; border: 1px solid var(--ac-line-strong); border-radius: 6px; padding: 0.8rem; background: #141816; color: #d9e2de; font-family:var(--font-mono); font-size: 0.68rem; line-height: 1.55; }
.agency-form-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 0.85rem; }
.agency-form-grid.metrics { grid-template-columns: repeat(3,minmax(0,1fr)); margin-top: 0.9rem; }
.agency-form-grid .wide { grid-column: 1/-1; }
.agency-form-grid textarea { width: 100%; min-height: 220px; resize: vertical; border: 1px solid var(--ac-line-strong); border-radius: 6px; padding: 0.7rem; background: var(--ac-surface); color: var(--ac-ink); font: inherit; line-height: 1.55; }
.agency-form-grid textarea:focus { border-color: var(--ac-green); outline: 0; box-shadow: 0 0 0 3px rgba(22,115,94,0.12); }
.agency-option-fieldset { display: flex; flex-wrap: wrap; align-items: center; gap: 0.8rem 1.25rem; margin: 0; border: 1px solid var(--ac-line); border-radius: 6px; padding: 0.8rem; }
.agency-option-fieldset legend { padding: 0 0.35rem; color: var(--ac-muted); font-size: 0.65rem; font-weight: 700; }
.agency-day-picker { display: flex; flex-wrap: wrap; gap: 0.35rem; width: 100%; }
.agency-day-picker label { position: relative; display: grid; place-items: center; min-width: 48px; min-height: 34px; overflow: hidden; border: 1px solid var(--ac-line-strong); border-radius: 5px; color: var(--ac-muted); font-size: 0.68rem; font-weight: 700; cursor: pointer; }
.agency-day-picker input { position: absolute; opacity: 0; }
.agency-day-picker label:has(input:checked) { border-color: var(--ac-green); background: var(--ac-green-soft); color: var(--ac-green); }
.agency-form-note { margin: 0.9rem 0 0; color: var(--ac-muted); font-size: 0.68rem; line-height: 1.55; }
.agency-sequence-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; overflow: hidden; border: 1px solid var(--ac-line); border-radius: 5px; background: var(--ac-line); }
.agency-sequence-summary > div { padding: 0.65rem; background: #fafbfa; }
.agency-sequence-summary span,
.agency-sequence-summary strong { display: block; }
.agency-sequence-summary span { color: var(--ac-muted); font-size: 0.6rem; }
.agency-sequence-summary strong { margin-top: 0.3rem; overflow-wrap: anywhere; font-size: 0.68rem; }
.agency-insight-list { display: grid; gap: 0.4rem; margin: 0.8rem 0 0; padding-left: 1.1rem; color: var(--ac-muted); font-size: 0.68rem; line-height: 1.5; }
.agency-sequence-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0.45rem; margin-top: 0.8rem; }
.agency-sequence-steps > span { display: grid; grid-template-columns: 8px minmax(0, 1fr); gap: 0.35rem; align-items: center; min-height: 42px; padding: 0.45rem; border: 1px solid var(--ac-line); border-radius: 5px; color: var(--ac-ink); font-size: 0.62rem; }
.agency-sequence-steps i { width: 7px; height: 7px; border-radius: 50%; background: #abb5b0; }
.agency-sequence-steps small { grid-column: 2; color: var(--ac-muted); font-size: 0.56rem; }
.agency-sequence-steps .sent i,
.agency-sequence-steps .scheduled i { background: var(--ac-green); }
.agency-sequence-steps .sending i { background: var(--ac-amber); }
.agency-sequence-steps .skipped i { background: var(--ac-muted); }
.agency-sequence-actions { display: flex; justify-content: flex-end; gap: 0.5rem; margin-top: 0.8rem; }

.form-consent { display: grid; grid-template-columns: 18px minmax(0, 1fr); gap: 0.65rem; align-items: start; margin: 0.25rem 0 0.75rem; color: var(--muted); font-family: var(--font-sans); font-size: 0.76rem; line-height: 1.5; text-align: left; }
.form-consent input { width: 16px; height: 16px; margin: 2px 0 0; accent-color: var(--accent); }
.agency-modal-actions { justify-content: flex-end; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--ac-line); }
.agency-toast { position: fixed; right: 1rem; bottom: 1rem; z-index: 120; max-width: min(360px, calc(100% - 2rem)); padding: 0.75rem 0.9rem; border-radius: 6px; background: #171a19; color: #fff; font-size: 0.76rem; opacity: 0; transform: translateY(8px); pointer-events: none; transition: opacity .16s, transform .16s; }
.agency-toast.show { opacity: 1; transform: translateY(0); }

@media (max-width: 1180px) {
  .agency-metric-band { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .agency-overview-grid { grid-template-columns: 1fr; }
  .agency-health-panel { display: grid; grid-template-columns: 210px minmax(0,1fr); gap: 1rem; }
  .agency-health-list { margin-top: 0; }
  .agency-connection-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 900px) {
  .agency-shell { grid-template-columns: 72px minmax(0,1fr); }
  .agency-sidebar { padding: 0.85rem 0.65rem; }
  .agency-brand { justify-content: center; }
  .agency-brand > span:last-child,
  .agency-project-select-wrap label,
  .agency-project-select-wrap select,
  .agency-nav-item span,
  .agency-nav-item em,
  .agency-sidebar-footer span { display: none; }
  .agency-project-select-wrap { height: 1px; padding: 0; margin: 0.8rem 0; border: 0; border-top: 1px solid #343a37; border-radius: 0; }
  .agency-nav-item,
  .agency-sidebar-footer a,
  .agency-sidebar-footer button { grid-template-columns: 1fr; justify-items: center; padding: 0.55rem; }
  .agency-lower-grid,
  .agency-research-layout { grid-template-columns: 1fr; }
  .agency-detail-grid { grid-template-columns: 1fr; }
  .agency-lead-workspace { grid-template-columns: minmax(300px,0.75fr) minmax(420px,1.25fr); overflow-x: auto; }
  .agency-report-header { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .agency-project-profile-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .agency-sync-meta { grid-template-columns: repeat(3,minmax(0,1fr)); }
}
@media (max-width: 680px) {
  .agency-command-page { overflow: auto; }
  .agency-shell { display: block; height: auto; min-height: 100vh; padding-bottom: 62px; }
  .agency-sidebar { position: fixed; right: 0; bottom: 0; left: 0; z-index: 40; display: block; width: auto; height: 62px; min-height: 0; padding: 0.45rem; overflow: hidden; border: 0; border-top: 1px solid #303633; }
  .agency-brand,
  .agency-project-select-wrap,
  .agency-sidebar-footer,
  .agency-nav-item[data-view="research"],
  .agency-nav-item[data-view="reports"],
  .agency-nav-item[data-view="settings"] { display: none; }
  .agency-nav { grid-template-columns: repeat(5,minmax(0,1fr)); gap: 0.2rem; }
  .agency-nav-item { display: grid; min-height: 52px; align-content: center; justify-items: center; gap: 0.15rem; padding: 0.2rem; font-size: 0.58rem; }
  .agency-nav-item span { display: block; max-width: 100%; overflow: hidden; font-size: 0.52rem; line-height: 1; text-overflow: ellipsis; white-space: nowrap; }
  .agency-main { overflow: visible; }
  .agency-topbar { min-height: 70px; padding: 0.75rem; }
  .agency-title-line h1 { font-size: 1.1rem; }
  .agency-status-dot,
  .agency-range-control,
  .agency-secondary-btn#agency-new-project { display: none; }
  .agency-view { padding: 1rem 0.75rem 2rem; }
  .agency-alert-strip { margin: 0.75rem 0.75rem 0; }
  .agency-metric-band,
  .agency-metric-band.compact { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .agency-metric { min-height: 102px; }
  .agency-health-panel { display: block; }
  .agency-health-list { margin-top: 1rem; }
  .agency-view-toolbar,
  .agency-filter-toolbar { align-items: flex-start; flex-direction: column; }
  .agency-toolbar-controls { width: 100%; flex-wrap: wrap; }
  .agency-search-control { min-width: 100%; }
  .agency-lead-workspace { display: block; min-height: 0; overflow: visible; }
  .agency-lead-list { max-height: 430px; border-right: 0; border-bottom: 1px solid var(--ac-line); }
  .agency-lead-detail { min-height: 460px; }
  .agency-lead-detail-head { flex-wrap: wrap; }
  .agency-lead-head-actions { width: 100%; justify-content: space-between; }
  .agency-lead-controls,
  .agency-lead-sections,
  .agency-form-grid,
  .agency-form-grid.metrics,
  .agency-connection-grid,
  .agency-project-profile-grid { grid-template-columns: 1fr; }
  .agency-sync-meta { grid-template-columns: 1fr 1fr; }
  .agency-sequence-summary,
  .agency-sequence-steps { grid-template-columns: 1fr 1fr; }
  .agency-sync-actions-split { align-items: stretch; flex-direction: column; }
  .agency-sync-actions-split > span { display: grid; grid-template-columns: 1fr 1fr; }
  .agency-sync-actions-split button { width: 100%; }
  .agency-rejection-item { grid-template-columns: 1fr; gap: 0.35rem; }
  .agency-report-header { grid-template-columns: 1fr 1fr; }
}

@media print {
  .agency-command-page { overflow: visible; background: #fff; }
  .agency-sidebar,
  .agency-topbar-actions,
  .agency-alert-strip,
  .agency-view-toolbar button { display: none !important; }
  .agency-shell { display: block; height: auto; }
  .agency-main { overflow: visible; }
  .agency-topbar { position: static; padding: 0 0 1rem; background: #fff; }
  .agency-view { display: none !important; padding: 0; }
  #view-reports { display: block !important; }
}

/* First-party call booking */
.booking-page,
.unsubscribe-page { min-height: 100vh; margin: 0; background: #f4f6f5; color: #17201b; font-family:var(--font-serif); }
.booking-page [hidden],
.unsubscribe-page [hidden] { display: none !important; }
.booking-header { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 72px; padding: 0 4vw; border-bottom: 1px solid #d9dfdc; background: #fff; }
.booking-brand { color: #17201b; font-family:var(--font-serif); font-size: 1.25rem; font-weight: 600; text-decoration: none; }
.booking-help { color: #53625b; font-size: 0.78rem; text-decoration: none; }
.booking-main { display: grid; grid-template-columns: minmax(260px, 0.72fr) minmax(520px, 1.28fr); gap: clamp(2rem, 6vw, 7rem); width: min(1180px, calc(100% - 3rem)); margin: 0 auto; padding: clamp(3rem, 7vw, 6.5rem) 0 4rem; }
.booking-intro { align-self: start; padding-top: 1rem; }
.booking-kicker { margin: 0 0 0.75rem; color: #12634f; font-size: 0.68rem; font-weight: 700; text-transform: uppercase; }
.booking-intro h1 { max-width: 10ch; margin: 0; font-family:var(--font-serif); font-size: clamp(2.3rem, 4.5vw, 4.1rem); line-height: 1.02; letter-spacing: 0; }
.booking-intro > p:not(.booking-kicker) { max-width: 46ch; margin: 1.5rem 0 0; color: #5a6761; font-size: 1rem; line-height: 1.7; }
.booking-facts { display: grid; gap: 0; margin: 2.5rem 0 0; border-top: 1px solid #d9dfdc; }
.booking-facts div { display: grid; grid-template-columns: minmax(110px, 0.8fr) minmax(0, 1.2fr); gap: 1rem; padding: 0.9rem 0; border-bottom: 1px solid #d9dfdc; }
.booking-facts dt { display: flex; align-items: center; gap: 0.45rem; color: #68756f; font-size: 0.74rem; }
.booking-facts dt svg { width: 15px; height: 15px; }
.booking-facts dd { margin: 0; font-size: 0.78rem; font-weight: 700; text-align: right; }
.booking-tool { min-width: 0; border: 1px solid #d4dbd7; border-radius: 8px; background: #fff; box-shadow: 0 18px 50px rgba(24, 39, 31, 0.07); }
.booking-tool-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding: 1.35rem; border-bottom: 1px solid #e1e6e3; }
.booking-tool-head h2,
.booking-confirmed h2 { margin: 0; font-size: 1.2rem; letter-spacing: 0; }
.booking-timezone { display: flex; align-items: center; gap: 0.4rem; min-height: 36px; padding: 0 0.55rem; border: 1px solid #d4dbd7; border-radius: 5px; color: #53625b; }
.booking-timezone svg { width: 14px; height: 14px; }
.booking-timezone select { max-width: 180px; border: 0; outline: 0; background: transparent; color: #26332d; font: inherit; font-size: 0.7rem; }
.booking-status { display: flex; align-items: center; justify-content: center; gap: 0.65rem; min-height: 260px; padding: 2rem; color: #64716b; font-size: 0.8rem; text-align: center; }
.booking-status.error { color: #8a2f2f; }
.booking-spinner { width: 18px; height: 18px; border: 2px solid #d7dedb; border-top-color: #12634f; border-radius: 50%; animation: booking-spin 0.8s linear infinite; }
@keyframes booking-spin { to { transform: rotate(360deg); } }
.booking-days { max-height: 480px; padding: 0 1.35rem; overflow-y: auto; }
.booking-day { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 1rem; padding: 1rem 0; border-bottom: 1px solid #e6eae8; }
.booking-day:last-child { border-bottom: 0; }
.booking-day-label strong,
.booking-day-label span { display: block; }
.booking-day-label strong { font-size: 0.78rem; }
.booking-day-label span { margin-top: 0.2rem; color: #718078; font-size: 0.68rem; }
.booking-slot-grid { display: grid; grid-template-columns: repeat(4, minmax(72px, 1fr)); gap: 0.45rem; }
.booking-slot { min-height: 38px; border: 1px solid #cad4cf; border-radius: 5px; background: #fff; color: #1f2b25; font: inherit; font-size: 0.72rem; font-weight: 700; cursor: pointer; }
.booking-slot:hover,
.booking-slot.selected { border-color: #12634f; background: #e8f4ef; color: #0e5845; }
.booking-details { padding: 1.35rem; border-top: 1px solid #e1e6e3; background: #fafbfa; }
.booking-selected { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0.8rem; border-radius: 5px; background: #e8f4ef; color: #0e5845; font-size: 0.78rem; }
.booking-selected span { display: flex; align-items: center; gap: 0.45rem; }
.booking-selected svg { width: 15px; height: 15px; }
.booking-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 0.8rem; margin-top: 1rem; }
.booking-fields label { position: relative; display: grid; gap: 0.35rem; color: #5d6a64; font-size: 0.68rem; font-weight: 700; }
.booking-fields label span { position: absolute; top: 0; right: 0; color: #89938e; font-weight: 400; }
.booking-fields input,
.booking-fields textarea { width: 100%; min-height: 42px; box-sizing: border-box; border: 1px solid #cad4cf; border-radius: 5px; padding: 0.65rem; background: #fff; color: #1f2b25; font: inherit; font-size: 0.78rem; }
.booking-fields input:focus,
.booking-fields textarea:focus { border-color: #12634f; outline: 0; box-shadow: 0 0 0 3px rgba(18, 99, 79, 0.1); }
.booking-form-error { min-height: 1.1rem; margin: 0.65rem 0 0; color: #9b3131; font-size: 0.72rem; }
.booking-confirm,
.booking-calendar-button,
.unsubscribe-panel button { display: inline-flex; align-items: center; justify-content: center; gap: 0.45rem; min-height: 42px; margin-top: 0.5rem; border: 0; border-radius: 5px; padding: 0.7rem 1rem; background: #12634f; color: #fff; font: inherit; font-size: 0.78rem; font-weight: 700; cursor: pointer; }
.booking-confirm { width: 100%; }
.booking-confirm svg,
.booking-calendar-button svg { width: 15px; height: 15px; }
.booking-confirm:disabled { cursor: wait; opacity: 0.55; }
.booking-confirmed { padding: clamp(2rem, 7vw, 4rem) 1.5rem; text-align: center; }
.booking-confirmed-icon { display: grid; place-items: center; width: 46px; height: 46px; margin: 0 auto 1.2rem; border-radius: 50%; background: #e8f4ef; color: #12634f; }
.booking-confirmed-icon svg { width: 21px; height: 21px; }
.booking-confirmed > p:not(.booking-kicker) { margin: 0.8rem 0 1rem; color: #5d6a64; }
.booking-confirmed small { display: block; max-width: 42ch; margin: 1rem auto 0; color: #78847e; line-height: 1.5; }
.booking-footer { display: flex; justify-content: center; gap: 1rem; padding: 1.25rem; border-top: 1px solid #d9dfdc; color: #738079; font-size: 0.67rem; }
.booking-footer a { color: inherit; }
.unsubscribe-page { display: grid; place-items: center; padding: 1.5rem; }
.unsubscribe-panel { width: min(520px, 100%); padding: clamp(2rem, 7vw, 4rem); box-sizing: border-box; border: 1px solid #d4dbd7; border-radius: 8px; background: #fff; box-shadow: 0 18px 50px rgba(24, 39, 31, 0.07); }
.unsubscribe-panel .booking-kicker { margin-top: 2.5rem; }
.unsubscribe-panel h1 { margin: 0; font-family:var(--font-serif); font-size: clamp(2rem, 6vw, 3.3rem); line-height: 1.05; letter-spacing: 0; }
.unsubscribe-panel > p:not(.booking-kicker):not(.booking-form-error) { color: #5d6a64; line-height: 1.65; }

@media (max-width: 860px) {
  .booking-main { grid-template-columns: 1fr; width: min(680px, calc(100% - 2rem)); padding-top: 2rem; }
  .booking-intro h1 { max-width: 14ch; }
}
@media (max-width: 560px) {
  .booking-header { min-height: 62px; padding: 0 1rem; }
  .booking-main { width: calc(100% - 1rem); gap: 1.5rem; padding: 1.5rem 0 2rem; }
  .booking-intro { padding: 0 0.5rem; }
  .booking-tool-head { display: grid; }
  .booking-timezone { width: 100%; box-sizing: border-box; }
  .booking-timezone select { width: 100%; max-width: none; }
  .booking-day { grid-template-columns: 1fr; gap: 0.65rem; }
  .booking-slot-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .booking-fields { grid-template-columns: 1fr; }
  .booking-footer { flex-wrap: wrap; }
}

/* 2026-08 QA hardening: shared header, type rhythm, and dense utility cards */
html,
body {
  max-width: 100%;
  overflow-x: clip;
}

.nav-bar {
  min-height: var(--nav-h, 76px);
  isolation: isolate;
}

.nav-bar .nav-inner {
  width: 100%;
  max-width: 1400px;
  margin-inline: auto;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: clamp(0.55rem, 1vw, 0.9rem);
  min-height: var(--nav-h, 76px);
  padding-inline: clamp(1rem, 3vw, 2.25rem);
}

.nav-logo {
  flex: 0 0 auto;
  min-width: max-content;
  white-space: nowrap;
  line-height: 1;
}

.nav-logo .dot {
  white-space: nowrap;
}

.nav-links {
  min-width: 0;
}

.nav-actions {
  flex: 0 0 auto;
}

.nav-link,
.nav-actions .btn,
.menu-btn,
.theme-toggle {
  transition: background-color 200ms ease-out, color 200ms ease-out, border-color 200ms ease-out, transform 200ms ease-out, opacity 200ms ease-out;
}

.eyebrow {
  position: relative;
  z-index: 2;
  max-width: 100%;
  margin-bottom: clamp(0.75rem, 1.3vw, 1.15rem);
  line-height: 1.22;
  transform: none;
  flex-wrap: wrap;
}

.hero-grid,
.page-hero,
.section-head,
.article-hero {
  min-width: 0;
}

.h-display,
.hero-title,
.page-hero h1,
.article-hero h1 {
  overflow-wrap: normal;
  text-wrap: balance;
}

.post-card,
.resource-card,
.tool-card,
.guide-card,
.blog-card {
  min-width: 0;
}

.post-card h2,
.post-card h3,
.resource-card h2,
.resource-card h3,
.tool-card h2,
.tool-card h3,
.guide-card h2,
.guide-card h3,
.blog-card h2,
.blog-card h3 {
  max-width: 100%;
  font-size: clamp(1.55rem, 2.25vw, 2.65rem) !important;
  line-height: 1.08 !important;
  letter-spacing: 0;
  overflow-wrap: anywhere;
  hyphens: auto;
}

.post-card p,
.resource-card p,
.tool-card p,
.guide-card p,
.blog-card p {
  font-size: clamp(0.95rem, 1vw, 1.08rem) !important;
  line-height: 1.58 !important;
}

.newsletter-form,
.subscribe-form,
.newsletter-signup,
.footer-newsletter form {
  display: flex;
  align-items: stretch;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.newsletter-form input,
.subscribe-form input,
.newsletter-signup input,
.footer-newsletter input {
  flex: 1 1 16rem;
  min-width: 0;
}

.newsletter-form button,
.subscribe-form button,
.newsletter-signup button,
.footer-newsletter button {
  flex: 0 0 auto;
}

@media (max-width: 980px) {
  .nav-bar .nav-links,
  .nav-bar .nav-actions {
    display: none !important;
  }

  .nav-bar .menu-btn {
    display: inline-flex !important;
  }

  .nav-bar .theme-toggle {
    display: flex !important;
  }

  .nav-bar .nav-inner {
    min-height: 72px;
    padding-inline: clamp(0.85rem, 4vw, 1rem);
    justify-content: space-between;
  }

  .nav-logo {
    min-width: 0;
  }

  .nav-logo .dot {
    letter-spacing: 0.24em;
  }
}

@media (max-width: 620px) {
  .eyebrow {
    font-size: 0.68rem;
    gap: 0.45rem;
  }

  .post-card h2,
  .post-card h3,
  .resource-card h2,
  .resource-card h3,
  .tool-card h2,
  .tool-card h3,
  .guide-card h2,
  .guide-card h3,
  .blog-card h2,
  .blog-card h3 {
    font-size: clamp(1.35rem, 8vw, 2.2rem) !important;
  }

  .newsletter-form,
  .subscribe-form,
  .newsletter-signup,
  .footer-newsletter form {
    flex-direction: column;
  }

  .newsletter-form button,
  .subscribe-form button,
  .newsletter-signup button,
  .footer-newsletter button {
    width: 100%;
    justify-content: center;
  }
}

/* 2026-08-22 sitewide QA rescue: readable mobile nav, dark forms, compact cards. */
.mnav {
  position: fixed;
  inset: 0;
  z-index: 999;
  overflow-y: auto;
  background: #15110d;
  color: #f6efe5;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-6px);
  transition: opacity 200ms ease-out, transform 200ms ease-out, visibility 200ms ease-out;
}

.mnav.open,
#mobilePanel.open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: none;
}

.menu-lock {
  overflow: hidden !important;
}

.mnav-inner {
  min-height: 100%;
  padding: 1rem clamp(1rem, 5vw, 1.5rem) 5rem;
  display: grid;
  gap: 1.5rem;
  align-content: start;
}

.mnav-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.mnav-logo {
  color: inherit;
  font-family: var(--font-wordmark, "Iowan Old Style", Georgia, serif);
  font-size: 1.45rem;
  text-decoration: none;
}

.mnav-logo span {
  margin-left: 0.35rem;
  font-family: var(--font-serif, Georgia, serif);
  font-size: 0.62rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  opacity: 0.75;
}

.mnav-close {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: inherit;
}

.mnav-primary {
  display: grid;
}

.mnav-link {
  display: grid;
  grid-template-columns: 2.2rem 1fr auto;
  align-items: center;
  gap: 0.65rem;
  padding: 1rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  color: inherit;
  text-decoration: none;
  font-family: var(--font-serif, Georgia, serif);
  font-size: clamp(1.8rem, 8vw, 2.6rem);
  line-height: 1;
}

.mnav-link::before {
  content: attr(data-num);
  font-size: 0.62rem;
  opacity: 0.55;
}

.mnav-link::after {
  content: "→";
  font-size: 1.1rem;
  opacity: 0.7;
}

.mnav-label {
  margin: 0 0 0.6rem;
  font-size: 0.66rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  opacity: 0.58;
}

.mnav-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.mnav-grid a {
  color: inherit;
  text-decoration: none;
  padding: 0.85rem;
  border-right: 1px solid rgba(255, 255, 255, 0.1);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  opacity: 0.82;
}

.mnav-grid a:nth-child(2n) {
  border-right: 0;
}

.mnav-audit-link,
.mnav-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 48px;
  padding: 0.9rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  color: inherit;
  text-decoration: none;
}

.mnav-cta {
  background: #f6efe5;
  color: #15110d;
}

.mnav-meta {
  margin: 0.75rem 0 0;
  color: rgba(246, 239, 229, 0.6);
  font-size: 0.8rem;
}

html[data-theme="dark"] .newsletter-form input,
html[data-theme="dark"] .subscribe-form input,
html[data-theme="dark"] .newsletter-signup input,
html[data-theme="dark"] .footer-newsletter input,
html[data-theme="dark"] .footer-newsletter-form input {
  background: rgba(255, 255, 255, 0.06) !important;
  border-color: rgba(255, 255, 255, 0.14) !important;
  color: #f6efe5 !important;
}

html[data-theme="dark"] .newsletter-form input::placeholder,
html[data-theme="dark"] .subscribe-form input::placeholder,
html[data-theme="dark"] .newsletter-signup input::placeholder,
html[data-theme="dark"] .footer-newsletter input::placeholder,
html[data-theme="dark"] .footer-newsletter-form input::placeholder {
  color: rgba(246, 239, 229, 0.58) !important;
}

.newsletter-form,
.subscribe-form,
.newsletter-signup,
.footer-newsletter form,
.footer-newsletter-form {
  max-width: min(100%, 46rem);
}

.newsletter-form button,
.subscribe-form button,
.newsletter-signup button,
.footer-newsletter button,
.footer-newsletter-form button {
  white-space: nowrap;
}

.route-tools .resource-grid,
.route-tools .post-grid,
.route-blog .post-grid,
.blog-grid {
  align-items: stretch;
}

.route-tools .post-card,
.route-tools .resource-card,
.route-tools .guide-card,
.route-tools .tool-card,
.route-blog .post-card {
  min-height: 0 !important;
  padding: clamp(1.25rem, 2vw, 1.7rem) !important;
}

.route-tools .post-card h2,
.route-tools .resource-card h2,
.route-tools .guide-card h2,
.route-tools .tool-card h2,
.route-blog .post-card h2,
.route-blog .post-card h3 {
  font-size: clamp(1.45rem, 1.75vw, 2.15rem) !important;
  line-height: 1.08 !important;
  text-wrap: balance;
  overflow-wrap: anywhere;
}

.route-tools .post-card p,
.route-tools .resource-card p,
.route-tools .guide-card p,
.route-tools .tool-card p,
.route-blog .post-card p {
  font-size: 0.98rem !important;
  line-height: 1.5 !important;
}

@media (max-width: 760px) {
  .page-hero,
  .article-hero {
    padding-top: clamp(1.5rem, 7vw, 2.5rem) !important;
  }

  .page-hero .h-display,
  .page-hero h1,
  .article-hero h1 {
    font-size: clamp(2.45rem, 11vw, 3.8rem) !important;
    line-height: 0.98 !important;
    max-width: 10ch !important;
  }

  .route-tools .post-card h2,
  .route-tools .resource-card h2,
  .route-tools .guide-card h2,
  .route-tools .tool-card h2,
  .route-blog .post-card h2,
  .route-blog .post-card h3 {
    font-size: clamp(1.35rem, 7vw, 2rem) !important;
  }

  .newsletter-form,
  .subscribe-form,
  .newsletter-signup,
  .footer-newsletter form,
  .footer-newsletter-form {
    display: grid !important;
    grid-template-columns: 1fr !important;
  }

  .newsletter-form button,
  .subscribe-form button,
  .newsletter-signup button,
  .footer-newsletter button,
  .footer-newsletter-form button {
    width: 100%;
  }
}

/* 2026-08-22 final sitewide QA lock. */
:root {
  --nav-height: 76px;
  --nav-h: 76px;
}

html {
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.nav-bar {
  min-height: var(--nav-height) !important;
}

.nav-bar .nav-inner {
  min-height: var(--nav-height) !important;
  max-width: min(100% - clamp(1.5rem, 4vw, 4rem), 1740px) !important;
  margin-inline: auto !important;
}

.nav-logo {
  font-family: "Iowan Old Style", Baskerville, "Palatino Linotype", Georgia, serif !important;
  font-size: clamp(1.35rem, 1.5vw, 1.6rem) !important;
  line-height: 1 !important;
  letter-spacing: 0 !important;
}

.nav-logo small,
.nav-logo .studio {
  font-size: 0.62rem !important;
  letter-spacing: 0.12em !important;
}

.nav-links,
.nav-actions {
  font-family: "Libertinus Math", Georgia, "Times New Roman", serif !important;
  font-size: clamp(0.82rem, 0.82vw, 0.94rem) !important;
}

.page-hero .eyebrow,
.article-hero .eyebrow,
.section-eyebrow,
.diagnostic-hero .eyebrow,
.hero-eyebrow {
  position: relative !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 0.55rem !important;
  margin: 0 0 0.75rem !important;
  inset: auto !important;
  transform: none !important;
  white-space: normal !important;
  line-height: 1.2 !important;
}

.page-hero h1,
.page-hero .h-display,
.article-hero h1,
.diagnostic-hero h1 {
  margin-top: 0 !important;
  text-wrap: balance;
}

.newsletter-form,
.subscribe-form,
.newsletter-signup,
.footer-newsletter form,
.footer-newsletter-form {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto !important;
  align-items: center !important;
  gap: 0.75rem !important;
}

.newsletter-form input,
.subscribe-form input,
.newsletter-signup input,
.footer-newsletter input,
.footer-newsletter-form input {
  min-width: 0 !important;
  color: inherit;
  opacity: 1;
}

.route-tools .resource-grid,
.route-tools .post-grid,
body.tools-page .resource-grid,
.tools-grid,
.guide-grid,
.blog-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)) !important;
  gap: clamp(0.9rem, 2vw, 1.3rem) !important;
}

.route-tools .post-card h2,
.route-tools .resource-card h2,
.route-tools .guide-card h2,
.route-tools .tool-card h2,
body.tools-page .resource-card h2,
body.tools-page .guide-card h2,
body.tools-page .tool-card h2 {
  font-size: clamp(1.28rem, 1.55vw, 1.85rem) !important;
  line-height: 1.08 !important;
  overflow-wrap: anywhere;
}

.route-tools .post-card,
.route-tools .resource-card,
.route-tools .guide-card,
.route-tools .tool-card,
body.tools-page .post-card,
body.tools-page .resource-card,
body.tools-page .guide-card,
body.tools-page .tool-card {
  min-height: 0 !important;
}

@media (min-width: 761px) {
  .wa-launcher {
    right: max(1rem, env(safe-area-inset-right)) !important;
    bottom: 5.15rem !important;
    z-index: 130 !important;
  }

  .chat-launcher {
    right: max(1rem, env(safe-area-inset-right)) !important;
    bottom: 1rem !important;
    z-index: 130 !important;
  }

  .a11y-launcher {
    right: calc(max(1rem, env(safe-area-inset-right)) + 4.25rem) !important;
    bottom: 1rem !important;
    z-index: 130 !important;
  }
}

@media (max-width: 760px) {
  :root {
    --nav-height: 72px;
    --nav-h: 72px;
  }

  .nav-links,
  .nav-actions {
    display: none !important;
  }

  .menu-btn {
    display: inline-flex !important;
    min-width: 44px !important;
    min-height: 44px !important;
  }

  .nav-logo {
    font-size: 1.35rem !important;
  }

  .page-hero,
  .article-hero,
  .diagnostic-hero {
    padding-top: clamp(1.15rem, 5vw, 2rem) !important;
  }

  .page-hero .h-display,
  .page-hero h1,
  .article-hero h1,
  .diagnostic-hero h1,
  .section-title {
    font-size: clamp(2.2rem, 10vw, 3.35rem) !important;
    line-height: 1.03 !important;
    letter-spacing: -0.018em !important;
    max-width: 100% !important;
  }

  .newsletter-form,
  .subscribe-form,
  .newsletter-signup,
  .footer-newsletter form,
  .footer-newsletter-form {
    grid-template-columns: 1fr !important;
  }

  .newsletter-form button,
  .subscribe-form button,
  .newsletter-signup button,
  .footer-newsletter button,
  .footer-newsletter-form button {
    width: 100% !important;
  }
}
