/* ============================================================
   Kingsbury & Marshall — site styles
   ============================================================ */

@font-face {
  font-family: "Satoshi";
  src: url("fonts/Satoshi-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Satoshi";
  src: url("fonts/Satoshi-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Satoshi";
  src: url("fonts/Satoshi-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Satoshi";
  src: url("fonts/Satoshi-Black.woff2") format("woff2");
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --cream: #FBF7F0;
  --border: #D8DCE6;
  --ink: #0B1B3A;
  --black: #0B1B3A;
  --white: #FFFFFF;
  --brand: #4F7FFF;
  --brand-dark: #3B68E8;
  --navy: #0B1B3A;
  --navy-muted: #5C6B87;

  --font-serif: "Satoshi", Helvetica, Arial, sans-serif;
  --font-sans: "Satoshi", Helvetica, Arial, sans-serif;
  --font-editorial: "Satoshi", Helvetica, Arial, sans-serif;

  --gap: 16px;
  --side: 48px;
  --max: 1329px;
}

* { box-sizing: border-box; }

html { -webkit-font-smoothing: antialiased; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--black);
  font-family: var(--font-editorial);
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

/* ---------------- Header ---------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--cream);
}

.header-inner { position: relative; }

.header-inner {
  width: 100%;
  padding: 0 var(--side);
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo { display: flex; align-items: center; flex-shrink: 0; }
.logo-img { height: 26px; width: auto; display: block; }

.header-right {
  display: flex;
  align-items: center;
  margin-left: auto;
}

/* Flyout nav: pinned to the burger's left edge, unfurls leftward as it opens */
.flyout-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  max-width: 0;
  opacity: 0;
  overflow: hidden;
  white-space: nowrap;
  transition: max-width .45s cubic-bezier(.65,0,.35,1), opacity .3s ease, margin-right .45s cubic-bezier(.65,0,.35,1);
}
.flyout-nav.is-open {
  max-width: 480px;
  opacity: 1;
  margin-right: 32px;
  transition: max-width .45s cubic-bezier(.65,0,.35,1) .05s, opacity .35s ease .1s, margin-right .45s cubic-bezier(.65,0,.35,1) .05s;
}

.flyout-nav a {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 14px;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--black);
  position: relative;
  padding-bottom: 2px;
}

.flyout-nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 100%;
  bottom: 0;
  height: 1px;
  background: currentColor;
  transition: right .25s ease;
}
.flyout-nav a:hover::after { right: 0; }

.menu-btn {
  background: none;
  border: none;
  cursor: pointer;
  width: 32px; height: 32px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.menu-icon {
  position: relative;
  width: 22px;
  height: 14px;
}
.menu-icon .bar {
  position: absolute;
  left: 0;
  width: 100%;
  height: 1.5px;
  background: var(--black);
  transition: top .3s ease, transform .3s ease;
}
.menu-icon .bar:nth-child(1) { top: 0; }
.menu-icon .bar:nth-child(2) { top: 100%; margin-top: -1.5px; }

.menu-btn.is-open .menu-icon .bar:nth-child(1) { top: 50%; margin-top: -0.75px; transform: rotate(45deg); }
.menu-btn.is-open .menu-icon .bar:nth-child(2) { top: 50%; margin-top: -0.75px; transform: rotate(-45deg); }

/* ---------------- Hero ---------------- */

.hero {
  position: relative;
  overflow: hidden;
  width: 100%;
  min-height: calc(100vh - 76px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  cursor: default;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 1020px;
  padding: 0 var(--side);
}

/* ---------------- Hero testimonials (frosted glass over the cursor trail) ---------------- */

.hero-testimonials {
  position: relative;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: stretch;
  gap: 20px;
  width: 100%;
  max-width: 1020px;
  margin-top: 56px;
  padding: 0 var(--side);
}

.testimonial-card {
  position: relative;
  flex: 1 1 260px;
  max-width: 300px;
  margin: 0;
  padding: 24px 26px;
  text-align: left;
  overflow: hidden;
  background: linear-gradient(155deg, rgba(255, 255, 255, .62), rgba(255, 255, 255, .22));
  -webkit-backdrop-filter: blur(40px) saturate(200%);
  backdrop-filter: blur(40px) saturate(200%);
  border: 1px solid rgba(255, 255, 255, .8);
  border-radius: 22px;
  box-shadow:
    0 24px 50px rgba(11, 27, 58, .16),
    inset 0 1px 0 rgba(255, 255, 255, .9),
    inset 0 0 0 1px rgba(255, 255, 255, .12);
}

.testimonial-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(120% 90% at 15% -10%, rgba(255, 255, 255, .55), transparent 55%);
  pointer-events: none;
}

.testimonial-card p {
  position: relative;
  z-index: 1;
  margin: 0 0 14px;
  font-family: var(--font-editorial);
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink);
}

.testimonial-card cite {
  display: block;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--navy-muted);
  font-style: normal;
}

.hero-heading {
  position: relative;
  z-index: 2;
  font-family: var(--font-serif);
  font-weight: 500;
  letter-spacing: -0.01em;
  font-size: 60px;
  line-height: 1.2;
  color: var(--black);
  margin: 0;
}

/* ---------------- Hero mouse trail gallery ---------------- */

.hero-trail {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.trail-img {
  position: absolute;
  width: 160px;
  height: 200px;
  object-fit: cover;
  border-radius: 6px;
  box-shadow: 0 18px 40px rgba(11, 27, 58, .22);
  opacity: 0;
  transform: translate(-50%, -50%) scale(.55) rotate(var(--rot, 0deg));
  transition: opacity .35s ease, transform .45s cubic-bezier(.22,1,.36,1);
  will-change: opacity, transform;
}
.trail-img.is-in {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1) rotate(var(--rot, 0deg));
}
.trail-img.is-out {
  opacity: 0;
  transform: translate(-50%, -50%) scale(.8) rotate(var(--rot, 0deg));
  transition: opacity .5s ease, transform .5s ease;
}

.accent {
  color: var(--brand);
}

/* ---------------- Grid / cards ---------------- */

.grid {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--side) var(--gap);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--gap);
}

/* service cards (s1–s4) zig-zag down the mosaic so no two sit side by side */
.grid-mixed {
  grid-template-columns: repeat(4, 1fr);
  grid-template-areas:
    "s1 s1 m3 m3"
    "s1 s1 m3 m3"
    "m4 m4 s2 s2"
    "m4 m4 s2 s2"
    "s3 s3 m1 m2"
    "s3 s3 m6 m7"
    "m5 m5 s4 s4"
    "m5 m5 s4 s4";
}

[data-area="m1"] { grid-area: m1; }
[data-area="m2"] { grid-area: m2; }
[data-area="m3"] { grid-area: m3; }
[data-area="m4"] { grid-area: m4; }
[data-area="m5"] { grid-area: m5; }
[data-area="m6"] { grid-area: m6; }
[data-area="m7"] { grid-area: m7; }
[data-area="s1"] { grid-area: s1; }
[data-area="s2"] { grid-area: s2; }
[data-area="s3"] { grid-area: s3; }
[data-area="s4"] { grid-area: s4; }

.card--small { aspect-ratio: 1 / 1; }
.card--tall  { aspect-ratio: 1 / 1; }
.card--big   { aspect-ratio: 1 / 1; }

.grid-2x1 { grid-template-columns: 1fr 1fr; }
.grid-2x1 .card--big { aspect-ratio: 1 / 1; }

.card {
  position: relative;
  display: block;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--ink);
  isolation: isolate;
}

.card > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .6s cubic-bezier(.16,1,.3,1);
}

.card:hover > img,
.card:hover .split-img img { transform: scale(1.06); }

.split-img {
  position: absolute;
  inset: 0;
  display: flex;
}
.split-img img {
  position: relative;
  inset: auto;
  width: 50%;
  height: 100%;
  object-fit: cover;
  flex-shrink: 0;
}
.split-img img:first-child { object-position: left center; }
.split-img img:last-child { object-position: right center; border-left: 6px solid var(--cream); }

.card-scrim {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 55%;
  background: linear-gradient(to top, rgba(0,0,0,.65), rgba(0,0,0,0));
  z-index: 1;
}
.card-scrim--full { height: 100%; background: rgba(0,0,0,.42); }

[data-variant="dark-pattern"] { background: var(--ink); }
[data-variant="dark-pattern"] .card-scrim--full { background: rgba(0,0,0,.2); }

[data-variant="cta-brand"] { background: var(--brand); }

.card-top, .card-bottom, .card-center {
  position: relative;
  z-index: 2;
  padding: 24px;
  color: var(--white);
}

.card-top {
  position: absolute;
  top: 0; left: 0; right: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.card-bottom {
  position: absolute;
  bottom: 0; left: 0; right: 0;
}

.card-bottom--center { text-align: center; }

.card-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 4px;
}

.dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--white);
  flex-shrink: 0;
}

.eyebrow {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.card-title {
  margin: 8px 0 6px;
  font-weight: 500;
  color: var(--white);
}
.card-title--sans {
  font-family: var(--font-editorial);
  font-size: 26px;
  line-height: 1.22;
}
.card--small .card-title--sm { font-size: 19px; }
.card-title--serif {
  font-family: var(--font-serif);
  font-size: 30px;
  line-height: 1.2;
}
.card-title--cta { font-size: 32px; margin: 0; }

.card-byline {
  font-family: var(--font-editorial);
  font-size: 14px;
  opacity: .85;
  margin: 0 0 14px;
}
.card-byline--inline {
  display: block;
  font-size: 13px;
  margin-top: 4px;
  opacity: .8;
}

.card-cta {
  display: inline-block;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--white);
  border-bottom: 1px solid rgba(255,255,255,.5);
  padding-bottom: 2px;
  transition: border-color .2s ease;
}
.card:hover .card-cta { border-color: var(--white); }

.card--cta .card-title--cta { color: var(--white); }

/* ---------------- Work detail pages ---------------- */

.work-detail {
  max-width: var(--max);
  margin: 0 auto;
  padding: 64px var(--side) 96px;
}

.work-back {
  display: inline-block;
  margin-bottom: 32px;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--navy-muted);
}
.work-back:hover { color: var(--brand); }

.work-detail-eyebrow {
  display: block;
  color: var(--brand);
  font-weight: 500;
}

.work-detail-title {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: 44px;
  letter-spacing: -0.01em;
  line-height: 1.15;
  color: var(--black);
  margin: 10px 0 6px;
}

.work-detail-sub {
  font-family: var(--font-editorial);
  font-size: 17px;
  color: var(--navy-muted);
  margin: 0 0 36px;
}

.work-detail-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 40px;
}
.work-detail-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.work-detail-body {
  max-width: 700px;
}
.work-detail-body p {
  font-family: var(--font-editorial);
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink);
  margin: 0 0 20px;
}

@media (max-width: 980px) {
  .work-detail { padding: 48px 24px 72px; }
  .work-detail-title { font-size: 32px; }
  .work-detail-image { aspect-ratio: 4 / 3; margin-bottom: 28px; }
}

/* ---------------- Service characters (simple studio backdrop) ---------------- */

.card--room,
.room-hero {
  background: radial-gradient(120% 95% at 50% 38%, var(--bd-1) 0%, var(--bd-2) 48%, var(--bd-3) 100%);
}
[data-room="web"]       { --bd-1: #3B4B68; --bd-2: #28344D; --bd-3: #161E2E; } /* navy */
[data-room="marketing"] { --bd-1: #6B2E3A; --bd-2: #4A1F29; --bd-3: #2A1117; } /* maroon */
[data-room="ai"]        { --bd-1: #2F5A48; --bd-2: #1F3F33; --bd-3: #11251D; } /* dark green */
[data-room="digital"]   { --bd-1: #4E3566; --bd-2: #362448; --bd-3: #1E1429; } /* plum */

.room3d {
  position: absolute;
  inset: 0;
}
.room3d canvas {
  display: block;
  width: 100%;
  height: 100%;
}

/* service page hero: the same character, wider frame */
.room-hero {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 40px;
}

.service-list {
  list-style: none;
  margin: 8px 0 32px;
  padding: 0;
  border-top: 1px solid var(--border);
}
.service-list li {
  font-family: var(--font-editorial);
  font-size: 17px;
  color: var(--ink);
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.service-list-heading {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--navy-muted);
  margin: 36px 0 8px;
}
.service-cta {
  display: inline-block;
  padding: 14px 24px;
  border-radius: 100px;
  background: var(--brand);
  color: var(--white);
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 14px;
  letter-spacing: .02em;
  transition: background .2s ease;
}
.service-cta:hover { background: var(--brand-dark); }



/* tile video: rests on its first frame, plays while the card is hovered */
.card-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* light photos need more shade behind white captions */
.card-scrim--strong { height: 100%; background: linear-gradient(to top, rgba(0,0,0,.78), rgba(0,0,0,.25) 70%, rgba(0,0,0,.1)); }

/* ---------------- Blog text tiles ---------------- */

.card--text[data-tone="cream"] { background: #F3EBDD; }
.card--text[data-tone="sky"]   { background: #DCE6FF; }
.card--text[data-tone="blue"]  { background: var(--brand); }
.card--text[data-tone="navy"]  { background: var(--navy); }

.card--text[data-tone="cream"] .card-top,
.card--text[data-tone="cream"] .card-bottom,
.card--text[data-tone="cream"] .card-title,
.card--text[data-tone="sky"] .card-top,
.card--text[data-tone="sky"] .card-bottom,
.card--text[data-tone="sky"] .card-title { color: var(--ink); }
.card--text[data-tone="cream"] .dot,
.card--text[data-tone="sky"] .dot { background: var(--ink); }
.card--text[data-tone="cream"] .card-cta,
.card--text[data-tone="sky"] .card-cta { color: var(--ink); border-bottom-color: rgba(11, 27, 58, .4); }
.card--text[data-tone="cream"]:hover .card-cta,
.card--text[data-tone="sky"]:hover .card-cta { border-color: var(--ink); }

.card--text.card--big .card-title { font-size: 34px; line-height: 1.15; max-width: 82%; }

/* ---------------- Founder tiles + About page ---------------- */

.card--founder { background: var(--brand); }
.founder-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 56px;
  letter-spacing: .02em;
  color: rgba(255, 255, 255, .9);
  background: var(--brand);
}

.founders {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin: 0 0 40px;
}
.founder-photo {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 16px;
}
.founder-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.founder-photo .founder-fallback { font-size: 80px; }
.founder-name {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 24px;
  color: var(--ink);
  margin: 0 0 4px;
}
.founder-role {
  font-family: var(--font-sans);
  font-size: 13px;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--brand);
  margin: 0 0 10px;
}
.founder-bio {
  font-family: var(--font-editorial);
  font-size: 16px;
  line-height: 1.6;
  color: var(--navy-muted);
  margin: 0;
}

/* ---------------- Article pages ---------------- */

.article-body h2 {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 24px;
  line-height: 1.3;
  color: var(--ink);
  margin: 40px 0 12px;
}
.article-body ul {
  margin: 0 0 20px;
  padding-left: 22px;
}
.article-body li {
  font-family: var(--font-editorial);
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink);
  margin-bottom: 6px;
}
.article-body a:not(.service-cta):not(.sp-pill) {
  color: var(--brand);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.article-body .service-cta { margin-top: 20px; }

@media (max-width: 560px) {
  .founders { grid-template-columns: 1fr; }
  .card--text.card--big .card-title { font-size: 26px; }
}

/* ---------------- Subpages (work, services, guides, about, consultancy) ---------------- */

.sp { padding-bottom: 48px; }

.sp-wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding-left: var(--side);
  padding-right: var(--side);
}

/* hero */
.sp-hero { padding-top: 56px; padding-bottom: 72px; }
.sp-hero--split {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  gap: 64px;
  align-items: stretch;
}
.sp-hero-text { display: flex; flex-direction: column; min-width: 0; }
.sp-hero--split .sp-meta { margin-top: auto; }
.sp-hero--split .sp-lede { margin-bottom: 48px; }

.sp-back {
  align-self: flex-start;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--navy-muted);
  margin-bottom: 56px;
  transition: color .2s ease;
}
.sp-back:hover { color: var(--brand); }

.sp-eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--brand);
}
.sp-eyebrow .dot { background: var(--brand); }
.sp-eyebrow--light { color: var(--white); }
.sp-eyebrow--light .dot { background: var(--white); }

.sp-title {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: clamp(44px, 5.6vw, 80px);
  line-height: 1.02;
  letter-spacing: -0.03em;
  color: var(--ink);
  margin: 0;
}
.sp-title--long { font-size: clamp(34px, 3.9vw, 56px); line-height: 1.08; letter-spacing: -0.02em; }

.sp-lede {
  font-family: var(--font-sans);
  font-size: clamp(19px, 1.6vw, 23px);
  line-height: 1.45;
  color: var(--navy-muted);
  max-width: 620px;
  margin: 24px 0 0;
}

.sp-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin: 56px 0 0;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}
.sp-meta dt {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--navy-muted);
}
.sp-meta dd {
  margin: 8px 0 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.45;
  color: var(--ink);
}
.sp-meta a,
.sp-prose a,
.sp-faq a {
  color: var(--brand);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

/* hero media (photo, video or a service character) */
.sp-media {
  position: relative;
  margin: 0;
  height: min(72vh, 700px);
  min-height: 420px;
  border-radius: 16px;
  overflow: hidden;
  background: var(--ink);
}
.sp-media img,
.sp-media video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.sp-media.room-hero { aspect-ratio: auto; margin: 0; }

/* numbered sections: sticky label left, content right */
.sp-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: 48px;
  padding-top: 64px;
  padding-bottom: 64px;
  position: relative;
}
.sp-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: var(--side);
  right: var(--side);
  border-top: 1px solid var(--border);
}
.sp-label {
  position: sticky;
  top: 96px;
  align-self: start;
  display: flex;
  gap: 14px;
  margin: 6px 0 0;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--ink);
}
.sp-num { color: var(--brand); }
.sp-content { min-width: 0; }

.sp-h2 {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: clamp(28px, 2.9vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0 0 24px;
  max-width: 760px;
}
.sp-prose { max-width: 680px; }
.sp-prose p {
  font-family: var(--font-sans);
  font-size: 18px;
  line-height: 1.7;
  color: var(--ink);
  margin: 0 0 18px;
}
.sp-prose p:last-child { margin-bottom: 0; }

.sp-subhead {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--navy-muted);
  margin: 40px 0 4px;
}

/* cards */
.sp-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--gap);
}
.sp-card {
  position: relative;
  display: block;
  padding: 28px 28px 30px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 16px;
  transition: border-color .25s ease, transform .25s ease, box-shadow .25s ease;
}
.sp-card-num {
  display: block;
  margin-bottom: 28px;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: .06em;
  color: var(--brand);
}
.sp-card h3 {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 21px;
  line-height: 1.25;
  color: var(--ink);
  margin: 0 0 8px;
}
.sp-card p {
  font-family: var(--font-sans);
  font-size: 15.5px;
  line-height: 1.55;
  color: var(--navy-muted);
  margin: 0;
}
.sp-card--link:hover {
  border-color: var(--brand);
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(11, 27, 58, .08);
}
.sp-card-arrow {
  position: absolute;
  top: 26px;
  right: 28px;
  font-size: 18px;
  color: var(--brand);
  transition: transform .25s ease;
}
.sp-card--link:hover .sp-card-arrow { transform: translateX(4px); }

/* steps */
.sp-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px 48px;
}
.sp-step { border-top: 2px solid var(--ink); padding-top: 18px; }
.sp-step-num {
  display: block;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 44px;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--brand);
  margin-bottom: 18px;
}
.sp-step h3 {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 21px;
  color: var(--ink);
  margin: 0 0 8px;
}
.sp-step p {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--navy-muted);
  margin: 0;
}

/* checklist */
.sp-checks { list-style: none; margin: 0; padding: 0; max-width: 720px; }
.sp-checks li {
  position: relative;
  padding: 18px 0 18px 44px;
  border-bottom: 1px solid var(--border);
  font-family: var(--font-sans);
  font-size: 18px;
  line-height: 1.5;
  color: var(--ink);
}
.sp-checks li:first-child { border-top: 1px solid var(--border); }
.sp-checks li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 19px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--brand) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 14px no-repeat;
}

/* FAQ */
.sp-faqs { max-width: 760px; border-top: 1px solid var(--border); }
.sp-faq { border-bottom: 1px solid var(--border); }
.sp-faq summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 22px 0;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 19px;
  color: var(--ink);
}
.sp-faq summary::-webkit-details-marker { display: none; }
.sp-faq summary:hover { color: var(--brand); }
.sp-faq-icon { position: relative; flex-shrink: 0; width: 14px; height: 14px; }
.sp-faq-icon::before,
.sp-faq-icon::after {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 14px;
  height: 2px;
  background: currentColor;
  transition: transform .3s ease;
}
.sp-faq-icon::after { transform: rotate(90deg); }
.sp-faq[open] .sp-faq-icon::after { transform: rotate(0deg); }
.sp-faq p {
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.65;
  color: var(--navy-muted);
  margin: -6px 0 24px;
  max-width: 660px;
}

/* gallery */
.sp-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--gap);
  padding-top: 8px;
  padding-bottom: 64px;
}
.sp-gallery figure { margin: 0; border-radius: 16px; overflow: hidden; aspect-ratio: 4 / 5; }
.sp-gallery img { width: 100%; height: 100%; object-fit: cover; }

/* related tiles (reuse the homepage .card) */
.sp-related { padding-top: 64px; padding-bottom: var(--gap); position: relative; }
.sp-related::before {
  content: "";
  position: absolute;
  top: 0;
  left: var(--side);
  right: var(--side);
  border-top: 1px solid var(--border);
}
.sp-related-title {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: clamp(26px, 2.4vw, 34px);
  letter-spacing: -0.015em;
  color: var(--ink);
  margin: 0 0 28px;
}
.sp-related-grid { display: grid; gap: var(--gap); }
.sp-related-grid--1 { grid-template-columns: 1fr; }
.sp-related-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.sp-related-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.sp-related-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.sp-related-grid .card { aspect-ratio: 4 / 5; }
.sp-related-grid--1 .card { aspect-ratio: 21 / 9; }
.sp-related-grid--2 .card { aspect-ratio: 4 / 3; }
.sp-related-grid--4 .card { aspect-ratio: 3 / 4; }
.sp-related-grid--4 .card-title--sans { font-size: 22px; }

/* next-page band */
.sp-next {
  position: relative;
  display: flex;
  align-items: flex-end;
  min-height: 440px;
  margin-top: var(--gap);
  padding: 44px;
  border-radius: 16px;
  overflow: hidden;
  isolation: isolate;
  color: var(--white);
  background-color: var(--ink);
}
.sp-next > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
  transition: transform .8s cubic-bezier(.16,1,.3,1);
}
.sp-next:hover > img { transform: scale(1.04); }
.sp-next-scrim {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(to top, rgba(0,0,0,.72), rgba(0,0,0,.15) 65%, rgba(0,0,0,.05));
}
.sp-next-text { display: flex; flex-direction: column; position: relative; z-index: 1; }
.sp-next-text .sp-eyebrow { margin-bottom: 14px; }
.sp-next-title {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: clamp(40px, 5.4vw, 76px);
  line-height: 1;
  letter-spacing: -0.03em;
}
.sp-next-cta {
  align-self: flex-start;
  margin-top: 22px;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: .06em;
  text-transform: uppercase;
  border-bottom: 1px solid rgba(255,255,255,.5);
  padding-bottom: 2px;
  transition: border-color .2s ease;
}
.sp-next:hover .sp-next-cta { border-color: var(--white); }

.sp-next.sp-next--room { aspect-ratio: auto; margin-bottom: 0; }
.sp-next-char {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 55%;
}

/* guide pages */
.sp-article {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: 48px;
  padding-top: 64px;
  padding-bottom: 72px;
  position: relative;
}
.sp-article::before {
  content: "";
  position: absolute;
  top: 0;
  left: var(--side);
  right: var(--side);
  border-top: 1px solid var(--border);
}
.sp-toc { position: sticky; top: 96px; align-self: start; }
.sp-toc-title {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 6px 0 16px;
}
.sp-toc ol { list-style: none; margin: 0; padding: 0; counter-reset: toc; }
.sp-toc li { counter-increment: toc; margin: 0; }
.sp-toc a {
  display: flex;
  gap: 12px;
  padding: 8px 0;
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.4;
  color: var(--navy-muted);
  transition: color .2s ease;
}
.sp-toc a::before { content: counter(toc, decimal-leading-zero); color: var(--brand); font-size: 13px; padding-top: 1px; }
.sp-toc a:hover { color: var(--ink); }

.sp-article-body { max-width: 700px; }
.sp-article-body > p:first-child {
  font-size: 21px;
  line-height: 1.55;
  color: var(--ink);
  margin-bottom: 28px;
}
.sp-article-body p {
  font-family: var(--font-sans);
  font-size: 18px;
  line-height: 1.75;
  color: var(--ink);
  margin: 0 0 20px;
}
.sp-article-body h2 { font-size: 26px; margin: 48px 0 14px; scroll-margin-top: 96px; }
.sp-article-body li { font-size: 18px; }

.sp-callout {
  position: relative;
  margin-top: 56px;
  padding: 40px;
  border-radius: 16px;
  color: var(--white);
}
.sp-callout.room-hero { aspect-ratio: auto; width: auto; margin-bottom: 0; }
.sp-callout .sp-eyebrow { margin-bottom: 14px; }
.sp-callout-title {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 32px;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 10px;
}
.sp-callout-text {
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.55;
  color: rgba(255,255,255,.82);
  max-width: 520px;
  margin: 0 0 26px;
}
.sp-pill {
  display: inline-block;
  padding: 13px 22px;
  border-radius: 100px;
  background: var(--white);
  color: var(--ink);
  text-decoration: none;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 14px;
  letter-spacing: .01em;
  transition: transform .2s ease, box-shadow .2s ease;
}
.sp-pill:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(0,0,0,.2); }

/* about: client list */
.sp-list-links { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--border); }
.sp-list-links a {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 24px;
  align-items: center;
  gap: 24px;
  padding: 24px 0;
  border-bottom: 1px solid var(--border);
  transition: color .2s ease, padding .3s ease;
}
.sp-list-name {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: clamp(22px, 2.2vw, 30px);
  letter-spacing: -0.015em;
  color: var(--ink);
  transition: color .2s ease;
}
.sp-list-meta { font-family: var(--font-sans); font-size: 16px; color: var(--navy-muted); }
.sp-list-arrow { color: var(--brand); font-size: 20px; transition: transform .25s ease; }
.sp-list-links a:hover .sp-list-name { color: var(--brand); }
.sp-list-links a:hover .sp-list-arrow { transform: translateX(4px); }

.sp .founders { margin: 0; }
.sp .founder-name { font-size: 24px; }

@media (max-width: 980px) {
  .sp-hero { padding-top: 32px; padding-bottom: 48px; }
  .sp-hero--split { grid-template-columns: 1fr; gap: 40px; }
  .sp-hero--split .sp-lede { margin-bottom: 0; }
  .sp-back { margin-bottom: 32px; }
  .sp-meta { margin-top: 36px; }
  .sp-media { height: auto; min-height: 0; aspect-ratio: 4 / 5; max-height: 80vh; }
  .sp-media.room-hero { aspect-ratio: 1 / 1; }
  .sp-section, .sp-article { grid-template-columns: 1fr; gap: 28px; padding-top: 48px; padding-bottom: 48px; }
  .sp-label, .sp-toc { position: static; }
  .sp-toc { display: none; }
  .sp-related-grid--3, .sp-related-grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sp-related-grid--1 .card { aspect-ratio: 4 / 3; }
  .sp-next { min-height: 340px; padding: 28px; }
  .sp-next-char { width: 100%; opacity: .9; }
  .sp-next--room .sp-next-char { bottom: 30%; }
}

@media (max-width: 560px) {
  .sp-meta { grid-template-columns: 1fr; gap: 16px; }
  .sp-cards, .sp-steps, .sp-gallery { grid-template-columns: 1fr; }
  .sp-related-grid--2, .sp-related-grid--3, .sp-related-grid--4 { grid-template-columns: 1fr; }
  .sp-related-grid .card, .sp-related-grid--4 .card { aspect-ratio: 4 / 5; }
  .sp-list-links a { grid-template-columns: minmax(0, 1fr) 24px; }
  .sp-list-meta { display: none; }
  .sp-callout { padding: 28px; }
  .sp-next--room { min-height: 420px; }
}

/* ---------------- Footer ---------------- */

.site-footer {
  background: var(--navy);
  color: var(--white);
  margin-top: var(--gap);
}

.footer-inner {
  max-width: 1425px;
  margin: 0 auto;
  padding: 56px var(--side) 40px;
  display: flex;
  gap: 96px;
  flex-wrap: wrap;
}

.footer-col { display: flex; flex-direction: column; gap: 10px; min-width: 140px; }
.footer-col--motion { margin-left: auto; align-items: flex-start; }

.footer-heading {
  font-family: var(--font-editorial);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: .06em;
  text-transform: uppercase;
  margin: 0 0 6px;
  opacity: .85;
}

.footer-col a {
  font-family: var(--font-editorial);
  font-size: 14px;
  opacity: .95;
}
.footer-col a:hover { text-decoration: underline; }

.motion-toggle { display: flex; gap: 8px; margin-bottom: 16px; }
.motion-btn {
  font-family: var(--font-sans);
  font-size: 12px;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--white);
  background: none;
  border: 1px solid rgba(255,255,255,.5);
  border-radius: 100px;
  padding: 6px 16px;
  cursor: pointer;
}
.motion-btn.is-active { background: rgba(255,255,255,.15); border-color: var(--white); }

.footer-copyright {
  font-family: var(--font-editorial);
  font-size: 13px;
  opacity: .8;
  margin: 0;
}

/* ---------------- Scroll-in ---------------- */

.card, .hero-heading {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .6s ease, transform .6s ease;
}
.card.is-visible, .hero-heading.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------------- Responsive ---------------- */

@media (max-width: 980px) {
  .hero-content { padding: 0 24px; }
  .hero-heading { font-size: 36px; }
  .hero-testimonials { padding: 0 24px; margin-top: 40px; }
  .testimonial-card { flex: 1 1 100%; max-width: 400px; }

  :root { --side: 24px; }

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

  .grid-mixed {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "s1 s1"
      "m3 m3"
      "m4 m4"
      "s2 s2"
      "m1 m2"
      "s3 s3"
      "m6 m7"
      "m5 m5"
      "s4 s4";
  }

  .grid-2x1 { grid-template-columns: 1fr; }

  .footer-inner { gap: 40px; padding: 40px 24px 32px; }
  .footer-col--motion { margin-left: 0; }
}

@media (max-width: 560px) {
  .grid-mixed {
    grid-template-columns: 1fr;
    grid-template-areas:
      "s1"
      "m3"
      "m4"
      "s2"
      "m1"
      "m2"
      "s3"
      "m6"
      "m7"
      "m5"
      "s4";
  }
  .card-title--sans { font-size: 21px; }
  .card-title--serif { font-size: 24px; }

  .logo-img { height: 20px; }

  /* Below this width even a shrunk logo + 3 links won't fit inline, so the
     nav drops into a full-width panel under the header instead of spilling
     left in place. */
  .flyout-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    max-width: none;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    max-height: 0;
    opacity: 1;
    background: var(--cream);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 12px 24px rgba(11,27,58,.08);
    transition: max-height .4s cubic-bezier(.65,0,.35,1);
  }
  .flyout-nav.is-open {
    max-height: 220px;
    margin-right: 0;
    transition: max-height .4s cubic-bezier(.65,0,.35,1);
  }
  .flyout-nav a {
    width: 100%;
    padding: 16px 24px;
    font-size: 14px;
  }
  .flyout-nav a::after { display: none; }
}
