/* Mamma Consulting — base, layout, components. Tokens in tokens.css. */

/* ---------- Base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  font-family: var(--font-text);
  font-size: var(--fs-body);
  line-height: 1.55;
  color: var(--c-ink);
  background: var(--c-white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

h1, h2, h3 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  letter-spacing: var(--display-tracking);
  color: inherit;
  text-wrap: balance;
}
h1 { font-size: var(--fs-display); line-height: 1.02; }
h2 { font-size: var(--fs-h2); line-height: 1.08; }
h3 { font-size: var(--fs-h3); line-height: 1.15; }
h1 em, h2 em { font-style: italic; color: var(--c-primary); }

p { margin: 0; max-width: 66ch; text-wrap: pretty; }
ul { margin: 0; padding: 0; list-style: none; }

a { color: var(--c-primary); text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
a:hover { color: var(--c-primary-dark); text-decoration-thickness: 2px; }

:focus-visible { outline: 2px solid var(--c-ink); outline-offset: 3px; }
.on-dark :focus-visible { outline-color: var(--c-accent); }

.skip-link {
  position: absolute; left: 16px; top: -100px; z-index: 100;
  padding: 12px 16px; background: var(--c-ink); color: var(--c-white);
}
.skip-link:focus { top: 16px; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ---------- Layout ---------- */
.container {
  width: 100%;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: var(--section-y); }
.section--surface { background: var(--c-surface); }
.section--alt { background: var(--c-surface-alt); }
/* Continues the section above on the same background (wide photo strips) */
.section--flush-top { padding-top: 0; }

.section-head { display: grid; gap: var(--s-4); margin-bottom: var(--s-8); max-width: 820px; }
.section-head .lead { margin-top: var(--s-2); }

.eyebrow {
  margin: 0;
  font-size: var(--fs-eyebrow);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-primary);
}
/* Small caps labels on coloured bands: always solid white (7.8:1 on primary, 11.4:1 on primary-dark, 12.9:1 on ink) */
.on-dark .eyebrow, .door--plum .eyebrow { color: var(--c-white); }
.eyebrow--rule::before {
  content: ""; display: inline-block; width: 28px; height: 2px;
  margin-right: 12px; vertical-align: middle; background: var(--c-accent);
}

.lead { font-size: var(--fs-lead); line-height: 1.45; color: var(--c-ink); }
.small { font-size: var(--fs-small); color: var(--c-muted); }

/* ---------- Buttons & links ---------- */
.actions { display: flex; flex-wrap: wrap; gap: var(--s-3); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 14px 28px;
  border: 1px solid transparent; border-radius: var(--radius);
  font-family: var(--font-text); font-size: var(--fs-small); font-weight: 600;
  letter-spacing: 0.04em; line-height: 1.2; text-decoration: none;
  cursor: pointer;
  transition: background-color var(--t-fast) ease-out, color var(--t-fast) ease-out,
    border-color var(--t-fast) ease-out, transform var(--t-fast) ease-out;
}
.btn:active { transform: translateY(1px); }
.btn[disabled], .btn[aria-disabled="true"] {
  background: var(--c-on-ink-muted); border-color: var(--c-on-ink-muted);
  color: var(--c-muted); cursor: not-allowed; transform: none;
}

.btn-primary { background: var(--c-primary); color: var(--c-white); }
.btn-primary:hover { background: var(--c-primary-dark); color: var(--c-white); }

.btn-secondary { border-color: var(--c-primary); color: var(--c-primary); background: transparent; }
.btn-secondary:hover { background: var(--c-primary); color: var(--c-white); }

.btn-light { background: var(--c-white); color: var(--c-primary-dark); }
.btn-light:hover { background: var(--c-surface-alt); color: var(--c-primary-dark); }

.btn-ghost-light { border-color: rgba(255, 255, 255, 0.55); color: var(--c-white); background: transparent; }
.btn-ghost-light:hover { background: var(--c-white); color: var(--c-ink); }

.arrow-link {
  display: inline-flex; align-items: center; gap: 8px;
  font-weight: 600; color: var(--c-primary); text-decoration: none;
}
.arrow-link::after {
  content: "\2192"; transition: transform var(--t-fast) ease-out;
}
/* Animated underline: grows from the left on hover and keyboard focus */
.arrow-link, .u-link {
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size 320ms var(--ease), color var(--t-fast) ease-out;
}
.arrow-link { padding-bottom: 2px; }
a.arrow-link:hover, a:hover .arrow-link, a.arrow-link:focus-visible, a:focus-visible .arrow-link,
a.u-link:hover, a.u-link:focus-visible { background-size: 100% 1px; text-decoration: none; }
a.arrow-link:hover::after, a:hover .arrow-link::after { transform: translateX(4px); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid transparent;
  transition: border-color var(--t-fast) ease-out, transform 320ms var(--ease);
}
.site-header.is-scrolled { border-bottom-color: var(--c-line); }
/* Compact header: transform only, so nothing below it moves (CLS 0).
   Not while the mobile menu is open: a transformed header would become
   the containing block of the fixed menu panel. */
.header-inner, .brand img { transition: transform 320ms var(--ease); }
.brand img { transform-origin: left center; }
.site-header.is-compact:not(.nav-open) { transform: translateY(-12px); }
.site-header.is-compact:not(.nav-open) .header-inner { transform: translateY(6px); }
.site-header.is-compact:not(.nav-open) .brand img { transform: scale(0.86); }
.read-progress {
  position: absolute; left: 0; right: 0; bottom: -1px; height: 2px;
  background: var(--c-primary); transform: scaleX(0); transform-origin: 0 50%;
  pointer-events: none;
}
/* Desktop only: backdrop-filter would become the containing block of the fixed mobile nav */
@media (min-width: 1024px) {
  @supports (backdrop-filter: blur(8px)) {
    .site-header { background: rgba(255, 255, 255, 0.86); backdrop-filter: blur(10px); }
  }
}

.header-inner {
  display: flex; align-items: center; justify-content: space-between; gap: var(--s-5);
  min-height: var(--header-h);
}

.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--c-ink); text-decoration: none; }
.brand img { width: auto; height: 36px; }
.brand-name {
  font-family: var(--font-display); font-weight: var(--display-weight-strong);
  font-size: calc(1.3rem * var(--display-scale)); letter-spacing: var(--display-tracking); line-height: 1;
}
.brand:hover { color: var(--c-ink); }

.nav-toggle {
  display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 4px;
  border: 0; background: none; color: var(--c-ink); cursor: pointer;
  font: 600 var(--fs-small) / 1 var(--font-text); letter-spacing: 0.08em; text-transform: uppercase;
}
.nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after {
  display: block; width: 22px; height: 1.5px; background: currentColor; content: "";
  transition: transform var(--t-fast) ease-out, opacity var(--t-fast) ease-out;
}
.nav-toggle-bars { position: relative; }
.nav-toggle-bars::before { position: absolute; top: -6px; }
.nav-toggle-bars::after { position: absolute; top: 6px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after { transform: translateY(-6px) rotate(-45deg); }

/* Mobile nav panel */
.site-nav {
  position: fixed; inset: var(--header-h) 0 0 0;
  display: none; flex-direction: column; gap: var(--s-6);
  padding: var(--s-6) var(--gutter) var(--s-8);
  background: var(--c-white); overflow-y: auto;
  border-top: 1px solid var(--c-line);
}
.site-nav.is-open { display: flex; }
.no-js .site-nav { position: static; display: flex; }

.nav-list { display: grid; gap: var(--s-2); }
.nav-list > li > a,
.nav-sub-toggle {
  display: flex; align-items: center; justify-content: space-between; width: 100%;
  min-height: 48px; padding: 0;
  border: 0; background: none; cursor: pointer; text-align: left;
  font-family: var(--font-display); font-weight: var(--display-weight);
  font-size: calc(1.75rem * var(--display-scale)); letter-spacing: var(--display-tracking);
  color: var(--c-ink); text-decoration: none;
}
.nav-list > li > a:hover, .nav-sub-toggle:hover { color: var(--c-primary); }
.nav-list a[aria-current="page"] { color: var(--c-primary); }
.nav-sub-toggle::after {
  content: ""; width: 9px; height: 9px; margin-right: 6px;
  border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg) translateY(-3px); transition: transform var(--t-fast) ease-out;
}
.nav-sub-toggle[aria-expanded="true"]::after { transform: rotate(-135deg) translateY(-3px); }

.nav-sub { display: none; padding: var(--s-2) 0 var(--s-4) var(--s-4); border-left: 2px solid var(--c-accent); }
.nav-sub.is-open { display: grid; gap: var(--s-1); }
.no-js .nav-sub { display: grid; }
.nav-sub a {
  display: block; padding: 10px 0; color: var(--c-ink); text-decoration: none; font-weight: 500;
}
.nav-sub a:hover { color: var(--c-primary); }

.nav-cta { align-self: flex-start; }

@media (min-width: 1024px) {
  .nav-toggle { display: none; }
  .site-nav {
    position: static; display: flex; flex-direction: row; align-items: center; gap: var(--s-6);
    padding: 0; background: none; border: 0; overflow: visible;
  }
  .nav-list { display: flex; align-items: center; gap: var(--s-6); }
  .nav-list > li { position: relative; }
  .nav-list > li > a,
  .nav-sub-toggle {
    min-height: 44px; width: auto; gap: 8px; position: relative;
    font-family: var(--font-text); font-size: 1rem; font-weight: 500; letter-spacing: 0.01em;
  }
  .nav-list a[aria-current="page"]::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: 6px; height: 2px; background: var(--c-accent);
  }
  .nav-sub-toggle::after { width: 6px; height: 6px; margin-right: 0; border-width: 1.5px; }
  .nav-sub {
    position: absolute; top: calc(100% + 8px); left: -24px; min-width: 320px;
    padding: var(--s-3) var(--s-5); background: var(--c-white);
    border: 1px solid var(--c-line); border-top: 2px solid var(--c-primary);
  }
  .no-js .nav-sub { display: none; }
  .no-js .has-sub:hover .nav-sub, .no-js .has-sub:focus-within .nav-sub { display: grid; }
  .nav-sub a { padding: 10px 0; border-bottom: 1px solid var(--c-line); }
  .nav-sub li:last-child a { border-bottom: 0; }
  /* Same type as the menu (16px / 500), slim box — a quiet accent, not a block */
  .nav-cta {
    align-self: auto; min-height: 40px; padding: 8px 18px;
    font-size: 1rem; font-weight: 500; letter-spacing: 0.01em;
  }
}

/* ---------- Photo slots ---------- */
.photo-slot {
  position: relative; margin: 0; overflow: hidden;
  background:
    repeating-linear-gradient(135deg, transparent 0 22px, rgba(37, 51, 64, 0.035) 22px 23px),
    var(--c-surface-alt);
  border: 1px solid var(--c-line);
}
.photo-slot img { width: 100%; height: 100%; object-fit: cover; }
.photo-slot figcaption {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: var(--s-4) var(--s-5);
  font-size: 0.8125rem; line-height: 1.45; color: var(--c-muted);
}
.photo-slot figcaption::before {
  content: ""; display: block; width: 10px; height: 10px; margin-bottom: 10px;
  border-radius: 50%; background: var(--c-primary);
}
.photo-slot--dark {
  background:
    repeating-linear-gradient(135deg, transparent 0 22px, rgba(255, 255, 255, 0.05) 22px 23px),
    rgba(0, 0, 0, 0.14);
  border-color: var(--c-line-dark);
}
.photo-slot--dark figcaption { color: var(--c-on-plum-muted); }
.photo-slot--dark figcaption::before { background: var(--c-accent); }

.ratio-4-5 { aspect-ratio: 4 / 5; }
.ratio-4-3 { aspect-ratio: 4 / 3; }
.ratio-3-2 { aspect-ratio: 3 / 2; }

/* Visible placeholder text */
.ph { color: var(--c-primary); font-weight: 500; }
.on-dark .ph { color: var(--c-accent-soft); }

/* ---------- Hero (home): photo-led editorial block ---------- */
.hero {
  position: relative; isolation: isolate; overflow: clip;
  padding-block: clamp(32px, 5vw, 88px) clamp(56px, 7vw, 112px);
}
.hero-grid { display: grid; gap: var(--s-7); align-items: end; }
.hero-copy { display: grid; gap: var(--s-5); }
.hero h1 {
  max-width: 12ch;
  font-size: calc(clamp(2.875rem, 1.35rem + 6.2vw, 6.5rem) * var(--display-scale));
  line-height: 0.98;
}
.hero .lead { max-width: 40ch; color: var(--c-ink); }
.hero .actions { margin-top: var(--s-4); }
.hero-meta {
  display: flex; flex-wrap: wrap; gap: var(--s-2) var(--s-5); margin-top: var(--s-5); padding-top: var(--s-4);
  border-top: 1px solid var(--c-line); font-size: var(--fs-small); color: var(--c-muted);
}
.hero-meta li { display: inline-flex; align-items: center; gap: var(--s-5); }
.hero-meta li:not(:last-child)::after {
  content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--c-accent);
}

@media (min-width: 1024px) {
  .hero-grid { grid-template-columns: repeat(12, 1fr); column-gap: var(--grid-gap); }
  .hero-copy { grid-column: 1 / span 7; padding-bottom: var(--s-2); }
  .hero-media { grid-column: 8 / span 5; }
}

/* ---------- Doors ---------- */
.doors { padding-bottom: var(--section-y); }
.doors-grid { display: grid; gap: var(--s-4); }
.door {
  position: relative; display: grid; align-content: space-between; gap: var(--s-7);
  min-height: 300px; padding: clamp(28px, 4vw, 56px);
  text-decoration: none; color: var(--c-ink);
  transition: background-color var(--t-fast) ease-out;
}
.door:hover { color: inherit; }
.door-top { display: grid; gap: var(--s-4); }
.door h2 { font-size: var(--fs-h2); }
.door p:not(.eyebrow) { font-size: var(--fs-lead); line-height: 1.45; max-width: 34ch; }
.door--light { background: var(--c-surface-alt); }
.door--light:hover { background: #E8EBEA; }
.door--plum { background: var(--c-primary); color: var(--c-white); }
.door--plum:hover { background: var(--c-primary-dark); color: var(--c-white); }
.door--plum .arrow-link { color: var(--c-white); }
.door--plum:focus-visible { outline-color: var(--c-ink); }

@media (min-width: 768px) {
  .doors-grid { grid-template-columns: 1fr 1fr; }
  .door { min-height: 420px; }
}

/* ---------- What we do ---------- */
.services { display: grid; border-top: 1px solid var(--c-line); }
.service {
  display: grid; gap: var(--s-4); align-content: start;
  padding: var(--s-7) 0; border-bottom: 1px solid var(--c-line);
}
.service-top {
  display: flex; align-items: center; justify-content: space-between; gap: var(--s-4);
  min-height: 32px; /* same height with or without a tag, so all H3s share one baseline */
}
.service h3 { font-weight: var(--display-weight-strong); }
.service-num {
  font-family: var(--font-display); font-size: calc(1.125rem * var(--display-scale));
  color: var(--c-muted); font-variant-numeric: lining-nums;
}
.service-num::after {
  content: ""; display: inline-block; width: 20px; height: 2px; margin-left: 12px;
  vertical-align: middle; background: var(--c-accent);
}
.service p { color: var(--c-muted); max-width: 44ch; }
.service .arrow-link { margin-top: var(--s-2); }
.tag {
  justify-self: start; padding: 5px 10px;
  border: 1px solid var(--c-primary); color: var(--c-primary-dark); background: var(--c-white);
  font-size: var(--fs-eyebrow); font-weight: 600; line-height: 1.2; letter-spacing: 0.1em; text-transform: uppercase;
}

@media (min-width: 768px) {
  .services { grid-template-columns: 1fr 1fr; column-gap: var(--grid-gap); }
  .service { padding: var(--s-8) var(--s-6) var(--s-8) 0; }
}

@media (min-width: 1024px) {
  .services--3 { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- Ground transportation band ---------- */
.band-plum { background: var(--c-primary-dark); color: var(--c-white); }
.band-plum .lead { color: var(--c-white); }
.band-plum p { color: var(--c-on-plum-muted); }
.gt-grid { display: grid; gap: var(--s-8); align-items: center; }
.gt-copy { display: grid; gap: var(--s-5); }
.gt-list { display: grid; margin-top: var(--s-3); border-top: 1px solid var(--c-line-dark); }
.gt-list li {
  display: grid; grid-template-columns: 14px 1fr; gap: var(--s-4); align-items: baseline;
  padding: var(--s-4) 0; border-bottom: 1px solid var(--c-line-dark);
  font-size: var(--fs-lead); line-height: 1.35; color: var(--c-white);
}
.gt-list li::before {
  content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--c-accent);
  transform: translateY(-2px);
}
.gt-copy .actions { margin-top: var(--s-4); }

@media (min-width: 1024px) {
  .gt-grid { grid-template-columns: repeat(12, 1fr); column-gap: var(--grid-gap); }
  .gt-copy { grid-column: 1 / span 6; }
  .gt-photo { grid-column: 8 / span 5; }
}

/* ---------- Selected formats ---------- */
.formats { display: grid; gap: var(--grid-gap); }
/* Grid items default to min-width:auto, so a wide child (the note panel below) could drag the
   whole track past the viewport on phones — measured 152-212 px of horizontal overflow at 390 px.
   Letting the items shrink keeps every block inside the screen. */
.formats > * { min-width: 0; }
.format-feature { display: grid; gap: var(--s-5); align-content: start; min-width: 0; }
.format-feature .meta { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.format-feature h3 { font-size: var(--fs-h3); max-width: 22ch; }
.format-feature .note { font-style: italic; color: var(--c-muted); }
.format-side { display: grid; gap: var(--grid-gap); align-content: start; }
.format-ph {
  display: grid; gap: var(--s-3); align-content: start;
  padding: var(--s-6); border: 1px dashed #B9BEC3; background: var(--c-white);
}
.format-ph .photo-slot { margin-bottom: var(--s-2); }
.format-ph h3 { font-size: calc(1.375rem * var(--display-scale)); }

@media (min-width: 1024px) {
  .formats { grid-template-columns: repeat(12, 1fr); }
  .format-feature { grid-column: 1 / span 7; }
  .format-side { grid-column: 9 / span 4; }
}

/* ---------- Where we work ---------- */
.where { padding-block: calc(var(--section-y) * 0.6); }
.where-inner { display: grid; gap: var(--s-5); }
.where-list {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--s-2) var(--s-5);
  font-family: var(--font-display); font-weight: var(--display-weight);
  font-size: var(--fs-h3); line-height: 1.2; letter-spacing: var(--display-tracking);
}
.where-list li { display: inline-flex; align-items: baseline; gap: var(--s-5); }
.where-list li:not(:last-child)::after {
  content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--c-accent);
  transform: translateY(-0.3em);
}
.where-list small {
  font-family: var(--font-text); font-size: var(--fs-small); font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--c-primary);
}

@media (min-width: 1024px) {
  .where-inner { grid-template-columns: 3fr 9fr; align-items: baseline; column-gap: var(--grid-gap); }
}

/* ---------- For partners ---------- */
.partners-grid { display: grid; gap: var(--s-7); }
.partners-copy { display: grid; gap: var(--s-5); align-content: start; }
.check-list { display: grid; border-top: 1px solid var(--c-line); }
.check-list li {
  display: grid; grid-template-columns: 28px 1fr; gap: var(--s-3);
  padding: var(--s-4) 0; border-bottom: 1px solid var(--c-line);
}
.check-list li::before {
  content: ""; width: 16px; height: 2px; margin-top: 0.75em; background: var(--c-primary);
}

@media (min-width: 1024px) {
  .partners-grid { grid-template-columns: repeat(12, 1fr); column-gap: var(--grid-gap); }
  .partners-copy { grid-column: 1 / span 6; }
  .partners-side { grid-column: 8 / span 5; padding-top: var(--s-2); }
}

/* ---------- Contact strip ---------- */
.band-ink { background: var(--c-ink); color: var(--c-white); }
.band-ink p { color: var(--c-on-ink-muted); }
.band-ink a:not(.btn) { color: var(--c-white); }
.contact-head { display: grid; gap: var(--s-5); margin-bottom: var(--s-8); }
.contact-head .stack { display: grid; gap: var(--s-5); }
.contact-grid { display: grid; border-top: 1px solid var(--c-line-dark); }
.contact-item {
  display: grid; gap: var(--s-2); padding: var(--s-5) 0; border-bottom: 1px solid var(--c-line-dark);
}
.contact-item .label {
  font-size: var(--fs-eyebrow); font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--c-white);
}
.contact-item a {
  font-family: var(--font-display); font-weight: var(--display-weight);
  font-size: calc(1.5rem * var(--display-scale)); letter-spacing: var(--display-tracking);
  text-decoration: none; overflow-wrap: anywhere;
}
.contact-item a:hover { color: var(--c-white); text-decoration: underline; text-decoration-thickness: 1px; }
.social-row { display: flex; flex-wrap: wrap; gap: var(--s-2) var(--s-6); margin-top: var(--s-7); }
.social-row a { font-weight: 500; text-decoration: none; }
.social-row a:hover { text-decoration: underline; }

@media (min-width: 768px) {
  .contact-grid { grid-template-columns: 1fr 1fr; column-gap: var(--grid-gap); }
}
@media (min-width: 1024px) {
  .contact-head { grid-template-columns: 7fr 5fr; align-items: end; column-gap: var(--grid-gap); }
  .contact-head .actions { justify-content: flex-end; }
  .contact-grid { grid-template-columns: repeat(4, 1fr); }
}

/* ---------- Footer ---------- */
.site-footer {
  padding-block: var(--s-8) var(--s-6);
  background: var(--c-ink); color: var(--c-on-ink-muted);
  border-top: 1px solid var(--c-line-dark); font-size: var(--fs-small);
}
.site-footer a { color: var(--c-white); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-grid { display: grid; gap: var(--s-7); }
.footer-brand { display: grid; gap: var(--s-4); align-content: start; }
.footer-brand .brand { color: var(--c-white); }
.footer-col { display: grid; gap: var(--s-2); align-content: start; }
.footer-col h2 {
  margin-bottom: var(--s-2); font-family: var(--font-text); font-size: var(--fs-eyebrow);
  font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--c-white);
}
.footer-bottom {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--s-3);
  margin-top: var(--s-8); padding-top: var(--s-5); border-top: 1px solid var(--c-line-dark);
}
.site-footer .ph { color: var(--c-accent-soft); }

@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; column-gap: var(--grid-gap); }
}

/* =====================================================================
   Inner pages
   ===================================================================== */

/* ---------- Header: current section ---------- */
.nav-sub a[aria-current="page"] { color: var(--c-primary); font-weight: 600; }
@media (min-width: 1024px) {
  .nav-sub-toggle.is-current::before {
    content: ""; position: absolute; left: 0; right: 14px; bottom: 6px; height: 2px; background: var(--c-accent);
  }
}

/* ---------- Page hero ---------- */
.page-hero { padding-block: clamp(28px, 5vw, 72px) clamp(56px, 7vw, 112px); }
.breadcrumb { margin-bottom: var(--s-7); font-size: var(--fs-small); }
.breadcrumb ol { display: flex; flex-wrap: wrap; gap: 4px 10px; margin: 0; padding: 0; list-style: none; color: var(--c-muted); }
.breadcrumb li:not(:last-child)::after { content: "/"; margin-left: 10px; color: var(--c-muted); }
.breadcrumb a { color: var(--c-muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--c-primary); text-decoration: underline; }
.page-hero-grid { display: grid; gap: var(--s-7); align-items: end; }
.page-hero-copy { display: grid; gap: var(--s-5); }
.page-hero h1 { max-width: 14ch; }
.page-hero .lead { max-width: 44ch; }
.page-hero .actions { margin-top: var(--s-4); }
.page-hero-photo { aspect-ratio: 4 / 3; }

@media (min-width: 1024px) {
  .page-hero-grid { grid-template-columns: repeat(12, 1fr); column-gap: var(--grid-gap); }
  .page-hero-copy { grid-column: 1 / span 7; padding-bottom: var(--s-4); }
  .page-hero-photo { grid-column: 9 / span 4; aspect-ratio: 4 / 5; }
}

/* ---------- Intro split: heading left, text right ---------- */
.split { display: grid; gap: var(--s-6); }
.split-head { display: grid; gap: var(--s-4); align-content: start; }
.split-body { display: grid; gap: var(--s-5); align-content: start; }
@media (min-width: 1024px) {
  .split { grid-template-columns: repeat(12, 1fr); column-gap: var(--grid-gap); }
  .split-head { grid-column: 1 / span 5; }
  .split-body { grid-column: 7 / span 6; }
}

/* ---------- Bullet list (inside service blocks, cards) ---------- */
.bullets { display: grid; gap: var(--s-2); margin-top: var(--s-2); }
.bullets li { display: grid; grid-template-columns: 14px 1fr; gap: var(--s-3); align-items: baseline; }
.bullets li::before {
  content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--c-accent); transform: translateY(-2px);
}
.service .bullets { color: var(--c-ink); }

/* ---------- Cards (situations) ---------- */
.cards { display: grid; gap: var(--s-4); }
.card {
  display: grid; gap: var(--s-3); align-content: start;
  padding: var(--s-6); background: var(--c-white); border-top: 2px solid var(--c-primary);
}
.card h3 { font-size: calc(1.375rem * var(--display-scale)); font-weight: var(--display-weight-strong); }
.card p { color: var(--c-muted); }
.section:not(.section--surface):not(.section--alt) .card { background: var(--c-surface); }
@media (min-width: 768px) { .cards { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) {
  .cards--4 { grid-template-columns: repeat(4, 1fr); }
  .cards--3 { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- Steps (How we work) ---------- */
.steps { display: grid; gap: var(--s-6); counter-reset: step; }
.step {
  display: grid; gap: var(--s-3); align-content: start;
  padding-top: var(--s-5); border-top: 1px solid var(--c-line); counter-increment: step;
}
.step::before {
  content: counter(step, decimal-leading-zero);
  font-family: var(--font-display); font-size: calc(1.125rem * var(--display-scale)); color: var(--c-muted);
}
.step h3 { font-family: var(--font-text); font-size: var(--fs-h4); font-weight: 600; letter-spacing: 0; line-height: 1.3; }
.step p { color: var(--c-muted); }
.on-dark .step { border-top-color: var(--c-line-dark); }
.on-dark .step::before { color: var(--c-accent-soft); }
.on-dark .step h3 { color: var(--c-white); }
.on-dark .step p { color: var(--c-on-plum-muted); }
@media (min-width: 768px) { .steps { grid-template-columns: 1fr 1fr; column-gap: var(--grid-gap); } }
@media (min-width: 1024px) {
  .steps--4 { grid-template-columns: repeat(4, 1fr); }
  .steps--3 { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- Guest journey (ground transportation) ---------- */
.journey { display: grid; margin: 0; padding: 0; list-style: none; }
.journey li {
  position: relative; display: grid; gap: var(--s-2); align-content: start;
  padding: 0 0 var(--s-6) var(--s-7);
}
.journey li::before {
  content: ""; position: absolute; left: 6px; top: 6px; z-index: 1;
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--c-white); border: 2px solid var(--c-primary);
}
.journey li::after {
  content: ""; position: absolute; left: 13px; top: 20px; bottom: 0; width: 1px; background: var(--c-primary);
}
.journey li:last-child::after { display: none; }
.journey li:first-child::before,
.journey li:last-child::before { background: var(--c-accent); border-color: var(--c-accent); }
.journey strong {
  font-family: var(--font-display); font-weight: var(--display-weight-strong);
  font-size: calc(1.375rem * var(--display-scale)); line-height: 1.2; letter-spacing: var(--display-tracking);
}
.journey span { color: var(--c-muted); font-size: var(--fs-small); max-width: 30ch; }
@media (min-width: 1024px) {
  .journey { grid-template-columns: repeat(5, 1fr); column-gap: var(--grid-gap); }
  .journey li { padding: var(--s-7) 0 0 0; }
  .journey li::before { left: 0; top: 0; }
  .journey li::after { left: 14px; right: calc(-1 * var(--grid-gap)); top: 7px; bottom: auto; width: auto; height: 1px; }
}

/* ---------- Two-column checklist block ---------- */
.checklist-grid { display: grid; gap: var(--s-7); }
.checklist-grid > :first-child { display: grid; gap: var(--s-5); align-content: start; }
@media (min-width: 1024px) {
  .checklist-grid { grid-template-columns: repeat(12, 1fr); column-gap: var(--grid-gap); }
  .checklist-grid > :first-child { grid-column: 1 / span 6; }
  .checklist-grid > :last-child { grid-column: 8 / span 5; }
}
.on-dark .check-list { border-top-color: var(--c-line-dark); }
.on-dark .check-list li { border-bottom-color: var(--c-line-dark); color: var(--c-white); }
.on-dark .check-list li::before { background: var(--c-accent); }

/* ---------- Placeholder cards grid (cases, formats) ---------- */
.ph-grid { display: grid; gap: var(--grid-gap); }
@media (min-width: 768px) { .ph-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .ph-grid--3 { grid-template-columns: repeat(3, 1fr); } }

/* ---------- Cross-link strip ---------- */
.crosslink {
  display: grid; gap: var(--s-5); padding: clamp(28px, 4vw, 48px);
  background: var(--c-surface-alt); border-left: 3px solid var(--c-primary);
}
.crosslink h2 { font-size: var(--fs-h3); }
.crosslink > div { display: grid; gap: var(--s-3); }
@media (min-width: 1024px) {
  .crosslink { grid-template-columns: 1fr auto; align-items: center; column-gap: var(--s-7); }
}

/* ---------- FAQ ---------- */
.faq { border-top: 1px solid var(--c-line); }
.faq details { border-bottom: 1px solid var(--c-line); }
.faq summary {
  display: flex; justify-content: space-between; align-items: baseline; gap: var(--s-5);
  padding: var(--s-5) 0; cursor: pointer; list-style: none;
  font-family: var(--font-display); font-weight: var(--display-weight-strong);
  font-size: calc(1.375rem * var(--display-scale)); line-height: 1.25; letter-spacing: var(--display-tracking);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; flex: none; font-family: var(--font-text); font-weight: 400; font-size: 1.75rem; line-height: 1;
  color: var(--c-primary);
}
.faq details[open] summary::after { content: "\2212"; }
.faq summary:hover { color: var(--c-primary); }
.faq-a { display: grid; gap: var(--s-3); max-width: 66ch; padding-bottom: var(--s-6); }

/* ---------- Team ---------- */
.team { display: grid; gap: var(--s-8) var(--grid-gap); }
.person { display: grid; gap: var(--s-3); align-content: start; }
.person .photo-slot { margin-bottom: var(--s-3); }
.person h3 { font-weight: var(--display-weight-strong); }
.person .role { font-weight: 600; color: var(--c-primary); }
.person p:not(.role) { color: var(--c-muted); }
@media (min-width: 768px) { .team { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) {
  .team { grid-template-columns: repeat(12, 1fr); }
  .person:first-child { grid-column: 1 / span 5; }
  .person:last-child { grid-column: 7 / span 5; }
}

/* ---------- CTA band (ink) ---------- */
.cta-band .contact-head { margin-bottom: 0; }

/* ---------- Contact page & form ---------- */
.contact-layout { display: grid; gap: var(--s-8); }
@media (min-width: 1024px) {
  .contact-layout { grid-template-columns: repeat(12, 1fr); column-gap: var(--grid-gap); }
  .contact-form-wrap { grid-column: 1 / span 7; }
  .contact-aside { grid-column: 9 / span 4; }
}
.form { position: relative; display: grid; gap: var(--s-5); }
.form-grid { display: grid; gap: var(--s-5); }
@media (min-width: 768px) {
  .form-grid { grid-template-columns: 1fr 1fr; column-gap: var(--s-5); }
  .field--full { grid-column: 1 / -1; }
}
.field { display: grid; gap: var(--s-2); align-content: start; }
.field label { font-size: var(--fs-small); font-weight: 600; }
.field .opt { font-weight: 400; color: var(--c-muted); }
.field input, .field select, .field textarea {
  width: 100%; min-height: 52px; padding: 12px 14px;
  border: 1px solid var(--c-muted); border-radius: var(--radius); background: var(--c-white);
  font: inherit; font-size: 1.0625rem; color: var(--c-ink);
  transition: border-color var(--t-fast) ease-out;
}
.field textarea { min-height: 168px; resize: vertical; }
.field select {
  appearance: none; padding-right: 44px;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--c-ink) 50%),
    linear-gradient(135deg, var(--c-ink) 50%, transparent 50%);
  background-position: calc(100% - 22px) 50%, calc(100% - 16px) 50%;
  background-size: 6px 6px; background-repeat: no-repeat;
}
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--c-ink); }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible {
  outline: 2px solid var(--c-primary); outline-offset: 0; border-color: var(--c-primary);
}
.field-hint { font-size: var(--fs-small); color: var(--c-muted); }
.field-error { font-size: var(--fs-small); font-weight: 500; color: var(--c-error); }
.field-error:empty { display: none; }
.field.is-invalid input, .field.is-invalid select, .field.is-invalid textarea {
  border-color: var(--c-error); box-shadow: inset 0 0 0 1px var(--c-error);
}
.hp-field { position: absolute !important; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.form-note { font-size: var(--fs-small); color: var(--c-muted); }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-4) var(--s-5); }
.form-status { display: grid; gap: var(--s-2); padding: var(--s-4) var(--s-5); border-left: 3px solid var(--c-error); background: #FBEFEE; }
.form-status[hidden], .form-success[hidden] { display: none; }
.form-success {
  display: grid; gap: var(--s-4); padding: clamp(28px, 4vw, 48px);
  background: var(--c-surface-alt); border-top: 2px solid var(--c-primary);
}
.form-success:focus { outline: none; }
.form-success h2 { font-size: var(--fs-h3); }
.btn.is-loading { opacity: 0.75; cursor: progress; }

.contact-aside { display: grid; gap: var(--s-6); align-content: start; }
.aside-block { display: grid; gap: var(--s-2); padding-top: var(--s-5); border-top: 1px solid var(--c-line); }
.aside-block .label {
  font-size: var(--fs-eyebrow); font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--c-primary);
}
.aside-block .big {
  font-family: var(--font-display); font-weight: var(--display-weight);
  font-size: calc(1.375rem * var(--display-scale)); letter-spacing: var(--display-tracking);
  text-decoration: none; overflow-wrap: anywhere;
}
.aside-block .big:hover { text-decoration: underline; text-decoration-thickness: 1px; }
.aside-links { display: flex; flex-wrap: wrap; gap: var(--s-2) var(--s-5); }
.aside-links a { font-weight: 500; }

/* ---------- Prose (privacy) ---------- */
.prose { display: grid; gap: var(--s-4); max-width: var(--container-narrow); }
.prose h2 { font-size: var(--fs-h3); margin-top: var(--s-7); }
.prose h3 { font-family: var(--font-text); font-size: var(--fs-h4); font-weight: 600; letter-spacing: 0; margin-top: var(--s-3); }
.prose ul { display: grid; gap: var(--s-2); }
.prose ul li { display: grid; grid-template-columns: 14px 1fr; gap: var(--s-3); }
.prose ul li::before {
  content: ""; width: 6px; height: 6px; margin-top: 0.65em; border-radius: 50%; background: var(--c-primary);
}
.draft-note { padding: var(--s-4) var(--s-5); background: var(--c-surface-alt); border-left: 3px solid var(--c-accent); }

/* ---------- 404 ---------- */
.notfound { padding-block: clamp(48px, 10vw, 144px); }
.notfound .page-hero-copy { max-width: 820px; }
.notfound-links { display: grid; border-top: 1px solid var(--c-line); margin-top: var(--s-7); }
.notfound-links li { border-bottom: 1px solid var(--c-line); }
.notfound-links a { display: flex; padding: var(--s-4) 0; }
@media (min-width: 768px) { .notfound-links { grid-template-columns: 1fr 1fr; column-gap: var(--grid-gap); } }

/* ---------- Cookie notice (only when analyticsId is set in config.json) ---------- */
.cookie-note {
  position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 70;
  display: grid; gap: var(--s-4); max-width: 520px; padding: var(--s-5);
  background: var(--c-ink); color: var(--c-white); font-size: var(--fs-small);
}
.cookie-note p { color: var(--c-on-ink-muted); }
.cookie-note a { color: var(--c-white); }
.cookie-note .btn { min-height: 44px; padding: 10px 18px; }

/* =====================================================================
   Run 3 — photography, interaction, editorial polish
   ===================================================================== */

/* ---------- Type polish: rhythm, hyphenation, optical alignment ---------- */
h1, h2, h3 { hyphens: manual; overflow-wrap: break-word; }
/* Serif capitals carry a side bearing: pull large headings back to the text edge */
h1, .hero h1 { margin-left: -0.04em; }
h2 { margin-left: -0.025em; }
.card p, .service p, .step p, .person p, .bullets li, .jr-panel p { hyphens: auto; -webkit-hyphens: auto; }
.lead { max-width: 62ch; }

/* ---------- Section numbering (01 / 02 / 03) and hairlines ---------- */
main { counter-reset: sec; }
main .section .eyebrow--rule { counter-increment: sec; }
main .section .eyebrow--rule::before {
  content: counter(sec, decimal-leading-zero);
  width: auto; height: auto; margin-right: 14px; padding-right: 34px;
  background: linear-gradient(var(--c-accent), var(--c-accent)) right center / 20px 2px no-repeat;
  font-family: var(--font-display); font-weight: var(--display-weight); font-size: 1rem;
  letter-spacing: 0; color: var(--c-muted); vertical-align: baseline;
}
main .band-plum .eyebrow--rule::before { color: var(--c-on-plum-muted); }
main .band-ink .eyebrow--rule::before { color: var(--c-on-ink-muted); }

.section-head { max-width: none; padding-top: var(--s-5); border-top: 1px solid var(--c-line); }
.section-head > * { max-width: 820px; }
.split-head, .checklist-grid > :first-child { padding-top: var(--s-5); border-top: 1px solid var(--c-line); }
@media (min-width: 1024px) {
  /* Side by side: the hairline runs over both columns */
  .split-body, .checklist-grid > :last-child { padding-top: var(--s-5); border-top: 1px solid var(--c-line); }
  .checklist-grid > :last-child > .check-list:first-child { border-top: 0; }
}
.on-dark .section-head, .on-dark .split-head, .on-dark .split-body,
.on-dark .checklist-grid > * { border-top-color: var(--c-line-dark); }

/* ---------- Photographs ---------- */
.photo { position: relative; display: grid; gap: var(--s-3); margin: 0; align-content: start; }
.photo-frame {
  position: relative; overflow: hidden; aspect-ratio: var(--ar, 4 / 5);
  background: var(--c-surface-alt);
}
.photo-frame picture { display: block; width: 100%; height: 100%; }
.photo-frame img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 900ms var(--ease);
}
.ar-4-5 { --ar: 4 / 5; }
.ar-3-4 { --ar: 3 / 4; }
.ar-1-1 { --ar: 1 / 1; }
.ar-4-3 { --ar: 4 / 3; }
.ar-3-2 { --ar: 3 / 2; }
.ar-16-9 { --ar: 16 / 9; }
.ar-12-5 { --ar: 12 / 5; }

/* Brand tint — only where text sits on or right next to the image */
.photo-frame--tint::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(93, 33, 93, 0.08) 0%, rgba(93, 33, 93, 0.18) 100%);
  mix-blend-mode: multiply;
}

/* Parallax layer: 8% taller than the frame, moved by JS under 6% of the frame in total */
.parallax { position: absolute; inset: -4% 0; }
.parallax picture, .parallax img { height: 100%; }

/* Film grain (static, inline SVG — no request) */
.grain::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.15 0 0 0 0 0.2 0 0 0 0 0.25 0 0 0 0.09 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 180px 180px;
}
.photo-frame.grain::before { z-index: 1; opacity: 0.9; mix-blend-mode: overlay; }

/* Captions — one style everywhere */
.cap {
  display: flex; gap: 10px; align-items: baseline; max-width: 60ch;
  font-size: 0.875rem; line-height: 1.45; color: var(--c-muted);
}
.cap::before {
  content: ""; flex: none; width: 14px; height: 1px; background: var(--c-accent); transform: translateY(-0.3em);
}
.band-plum .cap { color: var(--c-on-plum-muted); }
.band-ink .cap { color: var(--c-on-ink-muted); }

/* Hover: a slow, slight zoom on linked photos and gallery items */
a:hover .photo-frame img, .gallery-item:hover img, .gallery-item:focus-visible img { transform: scale(1.035); }

/* Inner-page hero with a real photo */
.page-hero-media { align-self: end; }
@media (min-width: 1024px) {
  .page-hero-media { grid-column: 9 / span 4; }
  .page-hero--text .page-hero-copy { grid-column: 1 / span 7; }
  .page-hero--text h1 { max-width: 20ch; }
}

/* Inner hero with no usable photo: the copy keeps the left seven columns and the right side is
   closed by the client's own positioning line and the market list. Measured reason: with the copy
   spanning nine columns and a 16ch headline the right third of the hero stayed empty. */
.hero-aside { display: grid; gap: var(--s-4); align-content: start; min-width: 0; }
/* Quote + scope list read as one group; the market line stays a footer pinned to the panel bottom,
   so the panel has a single wide gap instead of two. */
.hero-aside .aside-top { display: grid; gap: var(--s-5); align-content: start; }
.hero-aside .aside-line {
  margin: 0; font-family: var(--font-display); font-style: italic; font-weight: var(--display-weight);
  font-size: calc(1.3125rem * var(--display-scale)); line-height: 1.25;
  letter-spacing: var(--display-tracking); color: var(--c-primary-dark);
}
.hero-aside .aside-markets {
  display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 0; padding: 0; list-style: none;
  font-size: var(--fs-small); color: var(--c-muted);
}
/* The three scope lines are the same services the home page already lists, so the column carries
   the same weight as the copy instead of leaving a hole. */
.hero-aside .aside-list { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.hero-aside .aside-list li {
  display: block; padding: 10px 0; border-top: 1px solid var(--c-line);
  font-size: var(--fs-small); color: var(--c-muted);
}
.hero-aside .aside-list li:last-child { border-bottom: 1px solid var(--c-line); }
.hero-aside .aside-markets li { display: flex; align-items: center; gap: 8px; }
.hero-aside .aside-markets li + li::before {
  content: ""; width: 4px; height: 4px; border-radius: 50%; background: currentColor; opacity: 0.55;
}
@media (min-width: 1024px) {
  /* A content-sized panel aligned to the top of the copy. Review rounds showed that stretching the
     panel to the full hero height (with space-between inside) always left a large empty middle,
     so the card now hugs its own content. */
  .page-hero--text .hero-aside {
    grid-column: 9 / span 4; align-self: start;
    padding: clamp(20px, 2.2vw, 32px);
    background: var(--c-surface); border-left: 2px solid var(--c-primary);
  }
}

/* ---------- Brand notes (client's typographic cards, shown as notes) ---------- */
.note { display: grid; gap: var(--s-4); margin: 0; align-content: start; }
.note-frame {
  padding: clamp(12px, 1.6vw, 20px); background: var(--c-surface-alt); border: 1px solid var(--c-line);
}
.note-frame .photo-frame { background: var(--c-white); }
.note figcaption { display: grid; gap: var(--s-2); }
.note-k {
  font-size: var(--fs-eyebrow); font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--c-primary);
}
.note-q {
  margin: 0; font-family: var(--font-display); font-weight: var(--display-weight);
  font-size: calc(1.375rem * var(--display-scale)); line-height: 1.25; letter-spacing: var(--display-tracking);
  color: var(--c-ink);
}
.note-o { font-size: var(--fs-small); color: var(--c-muted); }
.on-dark .note-frame { background: rgba(255, 255, 255, 0.06); border-color: var(--c-line-dark); }
.on-dark .note-k, .on-dark .note-q { color: var(--c-white); }
.band-plum .note-o { color: var(--c-on-plum-muted); }

.notes { display: grid; gap: var(--s-7) var(--grid-gap); }
@media (min-width: 768px) { .notes { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) {
  .notes-wrap { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: var(--grid-gap); }
  .notes-wrap > .section-head { grid-column: 1 / span 4; align-self: start; margin-bottom: 0; }
  .notes-wrap > .notes { grid-column: 6 / span 7; }
}

/* Home GT band: note instead of a placeholder photo */
@media (min-width: 1024px) { .gt-note { grid-column: 8 / span 4; } }

/* ---------- Intro split (home "who we are", photo-led sections) ---------- */
.media-split { display: grid; gap: var(--s-7); align-items: center; }
.media-split-copy { display: grid; gap: var(--s-5); align-content: start; }
@media (min-width: 1024px) {
  .media-split { grid-template-columns: repeat(12, 1fr); column-gap: var(--grid-gap); }
  .media-split > .photo { grid-column: 1 / span 6; }
  .media-split > .media-split-copy { grid-column: 8 / span 5; }
  .media-split--flip > .photo { grid-column: 7 / span 6; order: 2; }
  .media-split--flip > .media-split-copy { grid-column: 1 / span 5; order: 1; }
}
.pull-quote {
  margin: var(--s-3) 0 0; padding-left: var(--s-5); border-left: 2px solid var(--c-accent);
  font-family: var(--font-display); font-style: italic; font-weight: var(--display-weight);
  font-size: var(--fs-h3); line-height: 1.2; letter-spacing: var(--display-tracking); color: var(--c-primary);
}
.signature { font-size: var(--fs-small); font-weight: 600; letter-spacing: 0.04em; color: var(--c-ink); }
.signature span { font-weight: 400; color: var(--c-muted); }

/* ---------- Format cards (photo + copy, side column of "Selected formats") ---------- */
.format-card {
  display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: var(--s-5); align-items: start;
  padding-top: var(--s-5); border-top: 1px solid var(--c-line); color: inherit; text-decoration: none;
}
.format-card:hover { color: inherit; }
.format-card-copy { display: grid; gap: var(--s-3); align-content: start; }
.format-card h3 { font-size: calc(1.5rem * var(--display-scale)); font-weight: var(--display-weight-strong); }
.format-card-ph { aspect-ratio: 4 / 5; }
.format-card .arrow-link { justify-self: start; }

/* ---------- About: joint portrait + two founders ---------- */
.team-duo { display: grid; gap: var(--s-7); }
.team-people { display: grid; gap: var(--s-7); align-content: start; }
.team-people .person { padding-top: var(--s-5); border-top: 1px solid var(--c-line); }
@media (min-width: 768px) { .team-people { grid-template-columns: 1fr 1fr; column-gap: var(--grid-gap); } }
@media (min-width: 1024px) {
  .team-duo { grid-template-columns: repeat(12, 1fr); column-gap: var(--grid-gap); }
  .team-duo > .photo { grid-column: 1 / span 5; }
  .team-people { grid-column: 7 / span 6; grid-template-columns: 1fr; }
}

/* =====================================================================
   Run 4 — no empty photo slots: typographic panels, spec notes, case cards
   ===================================================================== */

/* ---------- Home hero: a larger photo on wide screens (>= 45% of the container, 4:5 kept) ---------- */
@media (min-width: 1280px) {
  .hero-copy { grid-column: 1 / span 6; }
  .hero-media { grid-column: 7 / span 6; }
  .hero h1 { font-size: calc(clamp(2.875rem, 1.35rem + 5.4vw, 6rem) * var(--display-scale)); }
}

/* ---------- Inner hero with a note card and a long H1 (GT): one more column for the copy ---------- */
@media (min-width: 1024px) {
  .page-hero--wide-copy .page-hero-copy { grid-column: 1 / span 8; }
}

/* ---------- Quote panel: the client's own line set in type on plum (stands in for a missing photo) ---------- */
.quote-panel {
  position: relative; isolation: isolate; display: grid; align-content: space-between; gap: var(--s-6);
  margin: 0; padding: clamp(24px, 4vw, 48px); aspect-ratio: 3 / 2;
  background: var(--c-primary-dark); color: var(--c-white);
  /* clip the ornament without overflow:hidden, so the box can still grow taller than 3:2 on phones */
  clip-path: inset(0);
}
@media (max-width: 767px) { .quote-panel { gap: var(--s-5); } }
/* Oversized opening quote mark as the only ornament */
.quote-panel::before {
  content: "\201C"; position: absolute; right: clamp(16px, 3vw, 40px); top: -0.12em; z-index: -1;
  font-family: var(--font-display); font-style: italic; font-weight: var(--display-weight);
  font-size: clamp(9rem, 6rem + 10vw, 16rem); line-height: 1; color: rgba(255, 255, 255, 0.08);
}
.quote-panel .eyebrow { color: var(--c-white); }
.quote-panel blockquote { margin: 0; }
.quote-panel blockquote p {
  max-width: 18ch; font-family: var(--font-display); font-style: italic; font-weight: var(--display-weight);
  font-size: calc(clamp(1.875rem, 1.3rem + 2.4vw, 3.25rem) * var(--display-scale)); line-height: 1.08;
  letter-spacing: var(--display-tracking); color: var(--c-white);
}
.quote-panel figcaption {
  display: flex; flex-wrap: wrap; gap: 4px 12px; padding-top: var(--s-4);
  border-top: 1px solid var(--c-line-dark); font-size: var(--fs-small); color: var(--c-on-plum-muted);
}
.quote-panel figcaption [lang] { font-style: italic; color: var(--c-white); }

/* ---------- Format spec: a hairline note with the facts of a format (no photo yet) ---------- */
.format-spec {
  display: grid; gap: var(--s-6); align-content: start; padding: clamp(24px, 4vw, 48px);
  background: var(--c-surface); border: 1px solid var(--c-line); border-top: 2px solid var(--c-primary);
}
.format-spec h3 { font-size: var(--fs-h3); max-width: 20ch; }
.spec { display: grid; margin: 0; border-top: 1px solid var(--c-line); }
.spec > div {
  display: grid; gap: 4px var(--s-5); padding: var(--s-4) 0; border-bottom: 1px solid var(--c-line);
}
.spec dt {
  font-size: var(--fs-eyebrow); font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--c-primary);
}
.spec dd { margin: 0; font-size: var(--fs-lead); line-height: 1.35; color: var(--c-ink); }
@media (min-width: 768px) {
  .spec > div { grid-template-columns: 9rem 1fr; align-items: baseline; }
}

/* ---------- Monogram tile: format cards without a photo ---------- */
.mono-tile {
  position: relative; display: grid; place-items: center; aspect-ratio: 4 / 5; overflow: hidden;
  background: var(--c-primary-dark);
}
.mono-tile span {
  font-family: var(--font-display); font-style: italic; font-weight: var(--display-weight);
  font-size: clamp(5rem, 3rem + 6vw, 8rem); line-height: 1; color: var(--c-accent-soft);
  transform: translateY(-0.04em);
}
.mono-tile::after {
  content: ""; position: absolute; left: 14%; right: 14%; bottom: 14%; height: 1px; background: var(--c-line-dark);
}

/* ---------- Case cards: numbered, no photo frame until real cases arrive ---------- */
.case-card { border: 1px solid var(--c-line); border-top: 2px solid var(--c-primary); background: var(--c-surface); }
.case-num {
  font-family: var(--font-display); font-weight: var(--display-weight); line-height: 1;
  font-size: calc(clamp(2.5rem, 2rem + 2vw, 3.5rem) * var(--display-scale));
  color: var(--c-primary); font-variant-numeric: lining-nums;
}

/* ---------- Spacing between the hero, marquee and the doors ---------- */
.marquee + .doors { padding-top: calc(var(--section-y) * 0.5); }

/* The cinematic band straddles the hero (white) and the next section (surface) */
.cine-wrap { background: linear-gradient(180deg, var(--c-white) 50%, var(--c-surface) 50%); }

/* ---------- Cinematic band (gt_cars: dark frame, 45% overlay, type on top) ---------- */
.cine {
  position: relative; isolation: isolate; display: grid; align-items: end;
  min-height: 460px; overflow: hidden; background: var(--c-ink); color: var(--c-white);
}
.cine-media { position: absolute; inset: 0; z-index: -2; }
.cine-media picture, .cine-media img { width: 100%; height: 100%; }
.cine-media img { object-fit: cover; object-position: 28% 60%; }
.cine::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(90deg, rgba(37, 51, 64, 0.35) 0%, rgba(93, 33, 93, 0.45) 45%, rgba(37, 51, 64, 0.5) 100%);
}
.cine-copy {
  display: grid; gap: var(--s-4); max-width: 34rem; margin-left: auto;
  padding: clamp(28px, 5vw, 64px);
  background: linear-gradient(180deg, rgba(37, 51, 64, 0) 0%, rgba(37, 51, 64, 0.35) 100%);
}
.cine blockquote {
  margin: 0; font-family: var(--font-display); font-weight: var(--display-weight);
  font-size: calc(clamp(1.375rem, 1.1rem + 1vw, 2rem) * var(--display-scale)); line-height: 1.25;
  letter-spacing: var(--display-tracking);
}
.cine .eyebrow { color: var(--c-white); }
.cine cite { font-style: normal; font-size: var(--fs-small); color: var(--c-on-ink-muted); }
@media (min-width: 768px) { .cine { min-height: 0; aspect-ratio: 12 / 5; } }

/* ---------- Capability marquee ---------- */
.marquee {
  position: relative; display: flex; align-items: center; overflow: hidden;
  border-block: 1px solid var(--c-line); background: var(--c-white);
}
.marquee-viewport { flex: 1; min-width: 0; overflow: hidden; }
.marquee-track { display: flex; width: max-content; animation: marquee 80s linear infinite; }
.marquee:hover .marquee-track, .marquee:focus-within .marquee-track,
.marquee.is-paused .marquee-track { animation-play-state: paused; }
.marquee-list { display: flex; flex: none; }
.marquee-list li {
  display: flex; align-items: center; gap: var(--s-6); padding: var(--s-5) var(--s-6) var(--s-5) 0;
  font-family: var(--font-display); font-weight: var(--display-weight); white-space: nowrap;
  font-size: calc(clamp(1.25rem, 1rem + 0.9vw, 1.75rem) * var(--display-scale)); letter-spacing: var(--display-tracking);
}
.marquee-list li::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--c-accent); }
.marquee-toggle {
  flex: none; display: grid; place-items: center; width: 48px; height: 48px; margin: 0 var(--gutter) 0 var(--s-3);
  border: 1px solid var(--c-line); background: var(--c-white); color: var(--c-ink); cursor: pointer;
  transition: border-color var(--t-fast) ease-out, color var(--t-fast) ease-out;
}
.marquee-toggle:hover { border-color: var(--c-primary); color: var(--c-primary); }
.marquee-toggle svg { width: 14px; height: 14px; }
.marquee-toggle .i-play, .marquee.is-paused .marquee-toggle .i-pause { display: none; }
.marquee.is-paused .marquee-toggle .i-play { display: block; }
.no-js .marquee-toggle { display: none; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Gallery + lightbox ---------- */
/* Phones: a swipeable strip (scrolls inside itself, never the page). Tablet and up: three columns */
.gallery {
  display: grid; grid-auto-flow: column; grid-auto-columns: 72%; gap: var(--s-5);
  overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain;
  margin: -6px; padding: 6px 6px 14px; scrollbar-width: thin;
}
.gallery > * { scroll-snap-align: start; }
@media (min-width: 768px) {
  .gallery {
    grid-auto-flow: row; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-6) var(--grid-gap);
    overflow: visible; margin: 0; padding: 0;
  }
}
span.photo-frame { display: block; }
.gallery-item { display: grid; gap: var(--s-3); align-content: start; color: inherit; text-decoration: none; }
.gallery-item:hover { color: inherit; }
.gallery-item:focus-visible { outline-offset: 4px; }
.gallery-zoom {
  position: absolute; right: 12px; bottom: 12px; z-index: 2;
  display: grid; place-items: center; width: 36px; height: 36px;
  background: var(--c-white); color: var(--c-ink);
  opacity: 0; transform: translateY(4px); transition: opacity var(--t-fast) ease-out, transform var(--t-fast) ease-out;
}
.gallery-zoom svg { width: 14px; height: 14px; }
.gallery-item:hover .gallery-zoom, .gallery-item:focus-visible .gallery-zoom { opacity: 1; transform: none; }
@media (hover: none) { .gallery-zoom { opacity: 1; transform: none; } }

.lightbox {
  position: fixed; inset: 0; z-index: 100;
  display: grid; grid-template-rows: auto minmax(0, 1fr) auto;
  background: rgba(22, 30, 38, 0.95); color: var(--c-white);
  opacity: 0; transition: opacity 240ms var(--ease);
}
.lightbox[hidden] { display: none; }
.lightbox.is-open { opacity: 1; }
.lb-bar {
  display: flex; align-items: center; justify-content: space-between; gap: var(--s-4);
  padding: var(--s-3) var(--gutter);
}
.lb-count { font-size: var(--fs-small); letter-spacing: 0.08em; color: var(--c-on-ink-muted); font-variant-numeric: tabular-nums; }
.lb-stage { display: grid; place-items: center; min-height: 0; padding: 0 var(--gutter); }
.lb-img {
  max-width: 100%; max-height: calc(100vh - 176px); width: auto; height: auto; object-fit: contain;
  background: rgba(255, 255, 255, 0.04);
}
@supports (height: 100dvh) { .lb-img { max-height: calc(100dvh - 176px); } }
.lb-foot {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: var(--s-4);
  padding: var(--s-3) var(--gutter) var(--s-5);
}
.lb-cap { margin: 0 auto; max-width: 60ch; text-align: center; font-size: var(--fs-small); color: var(--c-on-ink-muted); }
.lb-btn {
  display: grid; place-items: center; width: 48px; height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.4); background: transparent; color: var(--c-white); cursor: pointer;
  transition: background-color var(--t-fast) ease-out, color var(--t-fast) ease-out;
}
.lb-btn[hidden] { display: none; }
.lb-btn:hover { background: var(--c-white); color: var(--c-ink); }
.lb-btn:focus-visible { outline: 2px solid var(--c-accent); outline-offset: 3px; }
.lb-btn svg { width: 18px; height: 18px; }

/* ---------- Guest journey (interactive) ---------- */
.jr { display: grid; gap: var(--s-7); }
.jr-tabs { position: relative; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); border-top: 1px solid var(--c-line); }
.jr-fill {
  position: absolute; left: 0; right: 0; top: -1px; height: 2px; background: var(--c-primary);
  transform: scaleX(var(--p, 0.2)); transform-origin: 0 50%; transition: transform 520ms var(--ease);
}
.jr-tab {
  position: relative; display: grid; gap: 4px; align-content: start; min-height: 44px;
  padding: var(--s-5) var(--s-2) var(--s-3) 0; border: 0; background: none; cursor: pointer;
  font: inherit; text-align: left; color: var(--c-muted);
  transition: color var(--t-fast) ease-out;
}
.jr-tab::before {
  content: ""; position: absolute; left: 0; top: -7px; width: 12px; height: 12px; border-radius: 50%;
  background: var(--c-surface-alt); border: 2px solid var(--c-muted);
  transition: background-color var(--t-fast) ease-out, border-color var(--t-fast) ease-out, transform var(--t-fast) ease-out;
}
.jr-tab.is-past::before { background: var(--c-primary); border-color: var(--c-primary); }
.jr-tab[aria-selected="true"]::before { background: var(--c-accent); border-color: var(--c-accent); transform: scale(1.25); }
.jr-tab:hover, .jr-tab[aria-selected="true"] { color: var(--c-ink); }
.jr-tab:focus-visible { outline-offset: 4px; }
.jr-n { font-family: var(--font-display); font-size: 1rem; font-variant-numeric: lining-nums; }
.jr-l { font-size: var(--fs-small); font-weight: 600; line-height: 1.25; }
.jr-tab[aria-selected="true"] .jr-l { color: var(--c-primary); }
@media (min-width: 768px) { .jr-l { font-size: 1.0625rem; } }

.jr-panels { display: grid; }
.jr-panel {
  grid-area: 1 / 1; display: grid; gap: var(--s-5);
  visibility: hidden; opacity: 0; transform: translateY(8px);
  transition: opacity 360ms var(--ease), transform 360ms var(--ease), visibility 0s linear 360ms;
}
.jr-panel.is-active { visibility: visible; opacity: 1; transform: none; transition-delay: 0s; }
.jr-panel:focus-visible { outline-offset: 8px; }
.jr-panel-head { display: grid; gap: var(--s-3); align-content: start; }
.jr-big {
  font-family: var(--font-display); font-weight: var(--display-weight); line-height: 1;
  font-size: calc(clamp(3rem, 2rem + 4vw, 6rem) * var(--display-scale)); color: var(--c-primary);
  font-variant-numeric: lining-nums;
}
.jr-panel h3 { font-size: var(--fs-h3); }
.jr-panel-body { display: grid; gap: var(--s-4); align-content: start; }
.jr-panel-body .lead { color: var(--c-ink); }
.jr-nav { display: flex; gap: var(--s-3); margin-top: var(--s-3); }
.jr-nav .btn { min-height: 44px; padding: 10px 18px; }
.jr-nav .btn[disabled] { background: transparent; border-color: var(--c-line); color: var(--c-muted); }
@media (min-width: 1024px) {
  .jr-panel { grid-template-columns: repeat(12, 1fr); column-gap: var(--grid-gap); }
  .jr-panel-head { grid-column: 1 / span 5; }
  .jr-panel-body { grid-column: 7 / span 6; }
}
/* Without JS: plain stacked list of stages */
.no-js .jr-tabs, .no-js .jr-nav { display: none; }
.no-js .jr-panels { gap: var(--s-7); }
.no-js .jr-panel { grid-area: auto; visibility: visible; opacity: 1; transform: none; }

/* ---------- FAQ: smooth height ---------- */
.faq summary { transition: color var(--t-fast) ease-out; }
.faq summary::after { transition: transform 320ms var(--ease); }
.faq-a { overflow: hidden; }
/* the icon follows the button state, not the (delayed) open attribute */
.faq details[open] summary[aria-expanded="false"]::after { content: "+"; }

/* ---------- Back to top ---------- */
.to-top {
  position: fixed; right: clamp(16px, 3vw, 32px); bottom: clamp(16px, 3vw, 32px); z-index: 60;
  display: grid; place-items: center; width: 48px; height: 48px;
  border: 0; background: var(--c-ink); color: var(--c-white); cursor: pointer;
  opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: opacity 240ms var(--ease), transform 240ms var(--ease), visibility 0s linear 240ms, background-color var(--t-fast) ease-out;
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.to-top:hover { background: var(--c-primary); }
.to-top svg { width: 18px; height: 18px; }

/* ---------- Micro-interactions ---------- */
.card { transition: border-color var(--t-fast) ease-out, background-color var(--t-fast) ease-out; }
.card:hover { border-top-color: var(--c-accent); }
.footer-col a, .social-row a, .aside-links a, .breadcrumb a {
  text-decoration: none;
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size 320ms var(--ease), color var(--t-fast) ease-out;
}
.footer-col a:hover, .social-row a:hover, .aside-links a:hover, .breadcrumb a:hover,
.footer-col a:focus-visible, .social-row a:focus-visible { background-size: 100% 1px; text-decoration: none; }
@media (min-width: 1024px) {
  .nav-list > li > a { background: linear-gradient(currentColor, currentColor) 0 calc(100% - 7px) / 0 1px no-repeat; transition: background-size 320ms var(--ease), color var(--t-fast) ease-out; }
  .nav-list > li > a:hover { background-size: 100% 1px; }
  .nav-list > li > a[aria-current="page"] { background: none; }
}

/* ---------- Hero heading: word mask ---------- */
.mask-w {
  display: inline-block; overflow: hidden; vertical-align: top;
  /* room for descenders and the italic overhang, given back with negative margins */
  padding: 0 0.06em 0.1em 0; margin: 0 -0.06em -0.1em 0;
}
/* Слова разложены по маскам прямо в разметке (tools/presplit_headings.py),
   поэтому появление слов — чистая CSS-анимация: раскладка не меняется и сдвига нет. */
.mask-w > span {
  display: inline-block; transform: translateY(105%);
  animation: word-in 900ms var(--ease) forwards;
  animation-delay: calc(var(--w, 0) * 70ms + 120ms);
}
@keyframes word-in { to { transform: none; } }
.is-split.is-in .mask-w > span { transform: none; }

/* ---------- Scroll reveal ---------- */
.js .reveal {
  opacity: 0; transform: translateY(16px);
  transition: opacity var(--t-reveal) var(--ease), transform var(--t-reveal) var(--ease);
  transition-delay: calc(var(--i, 0) * 80ms);
}
@media (max-width: 767px) {
  /* Shorter travel and no stagger on phones: nothing jumps while scrolling with a thumb */
  .js .reveal { transform: translateY(10px); transition-delay: 0ms; }
}
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important; animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important; transition-delay: 0s !important; scroll-behavior: auto !important;
  }
  .js .reveal { opacity: 1; transform: none; }
  .mask-w > span { transform: none !important; animation: none !important; }
  .parallax { transform: none !important; }
  .site-header.is-compact:not(.nav-open), .site-header.is-compact:not(.nav-open) .header-inner,
  .site-header.is-compact:not(.nav-open) .brand img { transform: none; }
  a:hover .photo-frame img, .gallery-item:hover img, .gallery-item:focus-visible img { transform: none; }
  /* Marquee becomes a static, wrapped list */
  .marquee-track { animation: none !important; width: auto; }
  .marquee-list { flex-wrap: wrap; padding-left: var(--gutter); }
  .marquee-list[aria-hidden="true"], .marquee-toggle { display: none; }
}

/* --- Moments: gallery --- */

/* Compact inner hero (Moments) */
.page-hero--compact { padding-block: clamp(24px, 4vw, 56px) clamp(32px, 4.5vw, 72px); }
.page-hero--compact .breadcrumb { margin-bottom: var(--s-6); }
.page-hero--compact .page-hero-copy { max-width: 760px; }

/* Founders: one line of copy above, then two photos of equal height.
   The copy used to sit in a narrow left column next to two tall photos, which left a hole
   under the sentence — the block reads better as a full-width line plus a two-up pair. */
.mo-founders { display: grid; gap: var(--s-7); }
.mo-founders-copy { max-width: 54ch; }
.mo-founders-copy .lead {
  font-family: var(--font-display); font-size: clamp(24px, 2.3vw, 38px); line-height: 1.22;
  letter-spacing: -0.01em; max-width: 26ch;
}
.mo-founders-photos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-4); align-items: start; }
@media (min-width: 1024px) {
  .mo-founders { grid-template-columns: repeat(12, 1fr); column-gap: var(--grid-gap); }
  .mo-founders-copy { grid-column: 1 / span 7; }
  .mo-founders-photos { grid-column: 1 / span 12; gap: var(--grid-gap); }
}

/* Masonry: CSS columns, every card keeps its own aspect ratio */
.mo-grid { columns: 2; column-gap: var(--s-4); }
.mo-grid > .mo-item { margin-bottom: var(--s-5); break-inside: avoid; }
@media (min-width: 900px) {
  .mo-grid { columns: 3; column-gap: var(--grid-gap); }
  .mo-grid > .mo-item { margin-bottom: var(--grid-gap); }
}

/* Home teaser: one row, widths proportional to aspect ratio so all three share one height.
   Phones: a swipeable strip that scrolls inside itself, like the gallery strip above. */
.mo-row {
  display: flex; gap: var(--s-4); overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain;
  margin: -6px; padding: 6px 6px 14px; scrollbar-width: thin;
}
.mo-row > .mo-item { flex: none; width: calc(260px * var(--arw)); scroll-snap-align: start; }
@media (min-width: 768px) {
  .mo-row { gap: var(--grid-gap); overflow: visible; margin: 0; padding: 0; }
  .mo-row > .mo-item { flex: var(--arw) 1 0; width: auto; min-width: 0; }
}
.mo-more { margin-top: var(--s-6); }

.mo-item { perspective: 900px; }
.mo-card {
  position: relative;
  transform: translateY(var(--lift, 0px)) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transform-style: preserve-3d;
  transition: transform 480ms var(--ease), box-shadow 480ms var(--ease);
}
/* while the mouse moves, follow it closely */
.mo-card.is-tilting { transition: transform 120ms linear, box-shadow 480ms var(--ease); }

.mo-open { display: grid; gap: var(--s-2); color: inherit; text-decoration: none; }
.mo-open:hover { color: inherit; }
.mo-open:focus-visible { outline: 2px solid var(--c-ink); outline-offset: 4px; }
.mo-media {
  position: relative; display: block; overflow: hidden; aspect-ratio: var(--ar, 4 / 5);
  background: var(--c-surface-alt);
}
.mo-media picture { display: block; width: 100%; height: 100%; }
.mo-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 700ms var(--ease); }
/* the frame shown on hover when motion is reduced */
.mo-media::after {
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none;
  border: 2px solid transparent; transition: border-color var(--t-fast) ease-out;
}
/* the card whose photo is flying into the lightbox */
.mo-card.is-source .mo-media { visibility: hidden; }

/* Video card: the poster is an <img> (fixed size, webp + jpg); the video fades in over it while playing */
.mo-video {
  position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transition: opacity 240ms var(--ease);
}
.mo-card.is-playing .mo-video { opacity: 1; }
.mo-play {
  position: absolute; left: 12px; top: 12px; z-index: 3;
  display: grid; place-items: center; width: 48px; height: 48px; padding: 0;
  border: 0; border-radius: 50%; background: rgba(255, 255, 255, 0.94); color: var(--c-primary-dark); cursor: pointer;
  transform: translateZ(1px); transition: opacity var(--t-fast) ease-out, background-color var(--t-fast) ease-out;
}
.mo-play:hover { background: var(--c-white); }
.mo-play:focus-visible { outline: 2px solid var(--c-ink); outline-offset: 3px; }
.mo-play svg { width: 14px; height: 14px; }
.mo-play .i-pause, .mo-card.is-playing .mo-play .i-play { display: none; }
.mo-card.is-playing .mo-play .i-pause { display: block; }
.no-js .mo-play { display: none; }

/* Mouse and trackpad: the caption slides up over the photo, the card lifts and tilts.
   Touch and no-JS: the caption stays visible under the photo. */
@media (hover: hover) and (pointer: fine) {
  .js .mo-open { position: relative; overflow: hidden; }
  .js .mo-cap {
    position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; max-width: none;
    padding: 32px 16px 14px; color: var(--c-white);
    background: linear-gradient(180deg, rgba(37, 51, 64, 0) 0%, rgba(37, 51, 64, 0.8) 100%);
    transform: translateY(101%); transition: transform 420ms var(--ease);
  }
  .js .mo-card:hover .mo-cap, .js .mo-open:focus-visible .mo-cap { transform: none; }
  .mo-card:hover { --lift: -4px; box-shadow: 0 22px 44px -22px rgba(37, 51, 64, 0.55); }
  .mo-card:hover .mo-media img { transform: scale(1.04); }
  /* the preview plays on hover, so the button only shows on hover or keyboard focus */
  .mo-play { opacity: 0; }
  .mo-card:hover .mo-play, .mo-play:focus-visible { opacity: 1; }
}

/* Moments lightbox: blurred backdrop, media sized by JS (contain-fit, never above the source size) */
.mlb {
  position: fixed; inset: 0; z-index: 100;
  display: grid; grid-template-rows: auto minmax(0, 1fr) auto;
  background: rgba(22, 30, 38, 0.92); color: var(--c-white);
  opacity: 0; transition: opacity 260ms var(--ease);
}
@supports ((backdrop-filter: blur(6px)) or (-webkit-backdrop-filter: blur(6px))) {
  .mlb { background: rgba(22, 30, 38, 0.78); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
}
.mlb[hidden] { display: none; }
.mlb.is-open { opacity: 1; }
.mlb.is-hiding { opacity: 0; }
.mlb { transition: opacity 260ms var(--ease), background-color 360ms var(--ease), backdrop-filter 360ms var(--ease); }
.mlb.is-closing { background-color: rgba(22, 30, 38, 0); -webkit-backdrop-filter: blur(0); backdrop-filter: blur(0); }
.mlb-bar, .mlb-foot { transition: opacity 200ms var(--ease); }
.mlb.is-closing .mlb-bar, .mlb.is-closing .mlb-foot { opacity: 0; }
.mlb-bar {
  display: flex; align-items: center; justify-content: space-between; gap: var(--s-4);
  padding: var(--s-3) var(--gutter);
}
.mlb-count { font-size: var(--fs-small); letter-spacing: 0.08em; color: var(--c-on-ink-muted); font-variant-numeric: tabular-nums; }
.mlb-stage { display: grid; place-items: center; min-height: 0; padding: 0 var(--gutter); overflow: hidden; }
.mlb-media {
  position: relative; background: rgba(255, 255, 255, 0.04);
  box-shadow: 0 30px 80px -30px rgba(0, 0, 0, 0.6); transform-origin: 50% 50%;
}
.mlb-media img, .mlb-media video { display: block; width: 100%; height: 100%; object-fit: cover; }
.mlb-video { position: relative; width: 100%; height: 100%; background: var(--c-ink); }
.mlb-video video:focus-visible { outline: 2px solid var(--c-accent); outline-offset: 3px; }
.mlb-sound {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  display: inline-flex; align-items: center; gap: 10px; min-height: 48px; padding: 12px 20px;
  border: 0; background: var(--c-white); color: var(--c-primary-dark); cursor: pointer; white-space: nowrap;
  font: 600 var(--fs-small) / 1.2 var(--font-text); letter-spacing: 0.04em;
}
.mlb-sound[hidden] { display: none; }
.mlb-sound svg { width: 14px; height: 14px; }
.mlb-sound:hover { background: var(--c-surface-alt); }
.mlb-sound:focus-visible { outline: 2px solid var(--c-accent); outline-offset: 3px; }
.mlb-foot {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: var(--s-4);
  padding: var(--s-3) var(--gutter) var(--s-5);
}
.mlb-cap { margin: 0 auto; max-width: 60ch; text-align: center; font-size: var(--fs-small); color: var(--c-on-ink-muted); }

/* About: founders_hall next to the two founders (wide screens), under them otherwise */
.team-hall { max-width: 420px; }
@media (min-width: 768px) { .team-people .team-hall { grid-column: 1 / -1; } }
@media (min-width: 1280px) {
  .team-people { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .team-people .person { grid-column: 1; }
  .team-people .team-hall { grid-column: 2; grid-row: 1 / span 2; max-width: none; }
}

@media (prefers-reduced-motion: reduce) {
  /* no tilt, lift or zoom: only the caption and a frame */
  .mo-card, .mo-card:hover { transform: none; box-shadow: none; }
  .mo-card:hover .mo-media img { transform: none; }
  .mo-card:hover .mo-media::after, .mo-open:focus-visible .mo-media::after { border-color: var(--c-primary); }
  .js .mo-cap { transform: none !important; opacity: 0; }
  .js .mo-card:hover .mo-cap, .js .mo-open:focus-visible .mo-cap { opacity: 1; }
  /* touch keeps the caption visible under the photo */
  @media (hover: none), (pointer: coarse) { .js .mo-cap { opacity: 1; } }
  /* the viewer only fades in */
  .mlb { transition: opacity 200ms linear !important; }
}
