/* ==========================================================================
   Red Creative block theme
   Ported from the static draft (NewSite/assets/css/style.css) and mapped onto
   core block markup. Section classes are set on Group blocks in the page content.
   ========================================================================== */

:root {
  --red: #c2000b;
  --red-deep: #940812;
  --ink: #241d1b;
  --ink-soft: #4a403c;
  --muted: #776b66;
  --paper: #fbf7f2;
  --paper-2: #f5eee6;
  --blush: #f2e1d8;
  --sage: #5e8c7e;
  --sage-soft: #dfe9e4;
  --line: #e6dbd2;
  --white: #fff;

  --font-display: "Fraunces", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --font-body: "DM Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --radius: 18px;
  --radius-lg: 28px;
  --shadow: 0 1px 2px rgba(36, 29, 27, .04), 0 12px 32px -12px rgba(36, 29, 27, .14);
  --ease: cubic-bezier(.2, .7, .2, 1);

  --container: 1200px;
  --gutter: clamp(20px, 5vw, 48px);
  --section: clamp(72px, 11vw, 140px);
  --header-h: 84px;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: var(--header-h); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: clamp(16px, 1.05vw + 11px, 18px);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; height: auto; display: block; }
figure, .wp-block-image { margin: 0; }
a { color: inherit; }
p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }
h1, h2, h3, h4 { margin: 0; font-weight: 400; line-height: 1.12; }
ul, ol { margin: 0; padding: 0; }

::selection { background: var(--red); color: var(--white); }

:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link.screen-reader-text:focus {
  background: var(--ink); color: var(--white);
  border-radius: 8px; text-decoration: none;
}

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

.pt-0 { padding-top: 0 !important; }
.mt-l { margin-top: 48px; }

/* --- Type ---------------------------------------------------------------- */

.display-xl, .display-lg, .display-md, .display-sm {
  font-family: var(--font-display);
  font-weight: 300;
  letter-spacing: -.015em;
  font-optical-sizing: auto;
}
.display-xl { font-size: clamp(2.7rem, 5.6vw, 5rem); line-height: 1.02; }
.display-lg { font-size: clamp(2.3rem, 4.6vw, 4rem); line-height: 1.06; }
.display-md { font-size: clamp(1.9rem, 3.4vw, 2.9rem); line-height: 1.1; }
.display-sm { font-size: clamp(1.4rem, 2.2vw, 1.85rem); line-height: 1.25; }

.display-xl em, .display-lg em, .display-md em, .display-sm em {
  font-style: italic;
  color: var(--red);
}

.eyebrow, .is-style-eyebrow {
  display: inline-flex; align-items: center; gap: .7em;
  margin: 0 0 1.4rem;
  font-size: .78rem; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase;
  color: var(--red);
}
.eyebrow::before, .is-style-eyebrow::before {
  content: ""; width: 28px; height: 1px; background: currentColor;
}
/* an eyebrow sits on its own line above the heading */
.eyebrow + *, .is-style-eyebrow + * { display: block; }

.lead {
  font-size: clamp(1.1rem, 1.4vw, 1.3rem);
  line-height: 1.6;
  color: var(--ink-soft);
}
.display-sm + .lead { margin-top: 1.6rem; }

.muted { color: var(--muted); }

.prose { max-width: 66ch; color: var(--ink-soft); }
.prose a, .text-link, .note a, .mt-l a, .rc-prose a {
  color: var(--red);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: .2em;
  transition: color .2s;
}
.prose a:hover, .text-link:hover, .note a:hover, .mt-l a:hover, .rc-prose a:hover { color: var(--red-deep); }

/* --- Buttons --------------------------------------------------------------- */

.btn,
.wp-block-button .wp-block-button__link {
  --btn-bg: transparent; --btn-fg: var(--ink); --btn-bd: var(--ink);
  display: inline-flex; align-items: center; justify-content: center; gap: .6em;
  min-height: 52px; padding: 0 28px;
  border-radius: 999px; border: 1px solid var(--btn-bd);
  background: var(--btn-bg); color: var(--btn-fg);
  font: 500 .95rem/1 var(--font-body);
  text-decoration: none; cursor: pointer;
  transition: background-color .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease), transform .25s var(--ease);
}
.btn:hover, .wp-block-button .wp-block-button__link:hover { transform: translateY(-2px); }
.btn:active, .wp-block-button .wp-block-button__link:active { transform: translateY(0); }

/* the default button is the filled red one */
.btn-primary,
.wp-block-button:not(.is-style-outline) .wp-block-button__link { --btn-bg: var(--red); --btn-fg: var(--white); --btn-bd: var(--red); }
.btn-primary:hover,
.wp-block-button:not(.is-style-outline) .wp-block-button__link:hover { --btn-bg: var(--red-deep); --btn-bd: var(--red-deep); }
.wp-block-button.is-style-outline .wp-block-button__link { padding: 0 28px; border-width: 1px; }
.btn-outline:hover,
.wp-block-button.is-style-outline .wp-block-button__link:hover { --btn-bg: var(--ink); --btn-fg: var(--white); }

.btn .arrow, .wp-block-button.is-style-arrow .wp-block-button__link::after { transition: transform .25s var(--ease); }
.wp-block-button.is-style-arrow .wp-block-button__link::after { content: "→"; }
.btn:hover .arrow, .wp-block-button.is-style-arrow .wp-block-button__link:hover::after { transform: translateX(4px); }

.wp-block-buttons { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 2rem; }

.is-style-arrow-link a {
  display: inline-flex; align-items: center; gap: .5em;
  font-weight: 500; text-decoration: none; color: var(--ink);
  border-bottom: 1px solid var(--line);
  padding-bottom: 4px;
  transition: border-color .25s, color .25s;
}
.is-style-arrow-link a::after { content: "→"; transition: transform .25s var(--ease); }
.is-style-arrow-link a:hover { color: var(--red); border-color: var(--red); }
.is-style-arrow-link a:hover::after { transform: translateX(4px); }
p.is-style-arrow-link { margin-top: 2rem; }
.section-head-split p.is-style-arrow-link { margin: 0; }

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

.site-header {
  position: sticky; top: 0; z-index: 50;
  padding-top: env(safe-area-inset-top, 0px);
  background: rgba(251, 247, 242, .82);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, box-shadow .3s;
}
.admin-bar .site-header { top: var(--wp-admin--admin-bar--height, 0px); }
.site-header.is-scrolled {
  border-color: var(--line);
  box-shadow: 0 6px 24px -18px rgba(36, 29, 27, .35);
}
/* backdrop-filter would make the header the containing block for the fixed mobile menu */
.has-modal-open .site-header { background: var(--paper); backdrop-filter: none; -webkit-backdrop-filter: none; }

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

.header-inner .brand img { width: clamp(170px, 18vw, 220px) !important; }

.site-nav .wp-block-navigation__container { gap: 30px; align-items: center; }
.site-nav .wp-block-navigation-item__content {
  position: relative;
  font-size: .95rem; font-weight: 500;
  text-decoration: none; color: var(--ink-soft);
  padding: 6px 0;
  transition: color .2s;
}
.site-nav .wp-block-navigation-item:not(.nav-cta) .wp-block-navigation-item__content::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0;
  height: 1px; background: var(--red);
  transform: scaleX(0); transform-origin: left;
  transition: transform .35s var(--ease);
}
.site-nav .wp-block-navigation-item__content:hover,
.site-nav .current-menu-item > .wp-block-navigation-item__content { color: var(--ink); }
.site-nav .wp-block-navigation-item:not(.nav-cta) .wp-block-navigation-item__content:hover::after,
.site-nav .current-menu-item:not(.nav-cta) > .wp-block-navigation-item__content::after { transform: scaleX(1); }

.site-nav .nav-cta { margin-left: 6px; }
.site-nav .nav-cta .wp-block-navigation-item__content {
  display: inline-flex; align-items: center;
  min-height: 44px; padding: 0 22px;
  border-radius: 999px; background: var(--red); color: var(--white);
  font-size: .9rem; line-height: 1;
  transition: background-color .25s var(--ease), transform .25s var(--ease);
}
.site-nav .nav-cta .wp-block-navigation-item__content:hover,
.site-nav .nav-cta.current-menu-item > .wp-block-navigation-item__content { background: var(--red-deep); color: var(--white); transform: translateY(-2px); }

.site-nav .wp-block-navigation__responsive-container-open,
.site-nav .wp-block-navigation__responsive-container-close {
  width: 48px; height: 48px;
  align-items: center; justify-content: center;
  border: 1px solid var(--line); border-radius: 50%;
  background: var(--white); color: var(--ink);
}
/* sit exactly where the open button was */
.site-nav .is-menu-open .wp-block-navigation__responsive-container-close {
  position: fixed; top: calc((var(--header-h) - 48px) / 2 + env(safe-area-inset-top, 0px)); right: var(--gutter);
}
.admin-bar .site-nav .is-menu-open .wp-block-navigation__responsive-container-close { margin-top: var(--wp-admin--admin-bar--height, 0px); }
.site-nav .wp-block-navigation__responsive-container-open svg,
.site-nav .wp-block-navigation__responsive-container-close svg { width: 22px; height: 22px; }

/* core switches to the overlay menu at 600px; the full menu needs 900px */
@media (max-width: 900px) {
  :root { --header-h: 72px; }
  .site-nav .wp-block-navigation__responsive-container-open:not(.always-shown) { display: flex; }
  .site-nav .wp-block-navigation__responsive-container:not(.hidden-by-default):not(.is-menu-open) { display: none; }
}
.site-nav .wp-block-navigation__responsive-container.is-menu-open {
  background: var(--paper); color: var(--ink);
  padding: calc(var(--header-h) + 24px) var(--gutter) 48px;
  /* the desktop menu is right-aligned; the overlay reads from the left */
  --navigation-layout-justification-setting: flex-start;
  --navigation-layout-justify: flex-start;
  --navigation-layout-align: flex-start;
}
.site-nav .is-menu-open .wp-block-navigation__responsive-container-content { padding-top: 0; height: 100%; justify-content: center; align-items: flex-start; }
.site-nav .is-menu-open .nav-cta .wp-block-navigation-item__content { min-height: 52px; padding: 0 28px; font-size: .95rem; }
.site-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content .wp-block-navigation__container { flex-direction: column; align-items: flex-start; gap: 6px; }
.site-nav .is-menu-open .wp-block-navigation-item:not(.nav-cta) .wp-block-navigation-item__content {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(2rem, 8vw, 2.8rem); line-height: 1.3; color: var(--ink);
}
.site-nav .is-menu-open .wp-block-navigation-item__content::after { display: none; }
.site-nav .is-menu-open .current-menu-item:not(.nav-cta) > .wp-block-navigation-item__content { color: var(--red); font-style: italic; }
.site-nav .is-menu-open .nav-cta { margin: 34px 0 0; }

/* --- Sections -------------------------------------------------------------- */

.section { padding-block: var(--section); }
.section-tight { padding-block: calc(var(--section) * .6); }
.section-alt { background: var(--paper-2); }
.section-head { max-width: 760px; margin-bottom: clamp(40px, 6vw, 72px); }
.section-head .lead { margin-top: 1.4rem; }
.section-head-split {
  display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 24px 48px;
  max-width: none;
}
.section-head-split > div { max-width: 680px; }
.section-head-split > .muted { max-width: 34ch; margin: 0; }

/* --- Home hero ------------------------------------------------------------- */

/* Kept shorter than the draft so the client marquee peeks in above the fold
   instead of the hero filling the first screen exactly (the "false floor"). */
.hero { padding-block: clamp(32px, 5vw, 64px) clamp(40px, 5vw, 72px); overflow: hidden; }
.hero-grid {
  display: grid; grid-template-columns: 1.1fr .9fr;
  align-items: center; gap: clamp(40px, 6vw, 96px);
}
.hero-copy .lead { max-width: 34ch; margin-top: 1.8rem; }

.hero-media { position: relative; }
.is-style-arch {
  position: relative;
  border-radius: 999px 999px var(--radius-lg) var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4 / 5;
  max-height: max(420px, calc(100svh - var(--header-h) - 200px));
  box-shadow: var(--shadow);
}
.is-style-arch img { width: 100%; height: 100%; object-fit: cover; object-position: 30% 50%; }

.badge {
  position: absolute; left: -42px; bottom: 56px;
  width: 136px; height: 136px; border-radius: 50%;
  background: var(--paper);
  display: grid; place-items: center;
  box-shadow: var(--shadow);
}
.badge svg { position: absolute; inset: 0; width: 100%; height: 100%; animation: spin 26s linear infinite; }
.badge text { font: 600 9.5px var(--font-body); letter-spacing: .26em; text-transform: uppercase; fill: var(--ink); }
.badge-core {
  font-family: var(--font-display); font-style: italic; font-size: 2rem; color: var(--red); line-height: 1;
}
@keyframes spin { to { transform: rotate(-360deg); } } /* anticlockwise: the top of the badge moves left, like the marquee */

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-media { max-width: 440px; width: 88%; margin-inline: auto 0; }
  .badge { left: -28px; width: 112px; height: 112px; }
}

/* --- Marquee --------------------------------------------------------------- */

.marquee {
  border-block: 1px solid var(--line);
  padding-block: 26px;
  overflow: hidden;
  background: var(--paper);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track { display: flex; width: max-content; }
/* main.js duplicates the list for a seamless loop, then starts the animation */
.marquee.is-ready .marquee-track { animation: marquee 70s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee ul { display: flex; list-style: none; }
.marquee li {
  display: flex; align-items: center; white-space: nowrap;
  font-family: var(--font-display); font-weight: 300; font-size: clamp(1.15rem, 1.8vw, 1.5rem);
  color: var(--ink-soft);
}
.marquee li::after {
  content: "✦"; font-size: .6em; color: var(--red); margin-inline: 1.6em;
}
@keyframes marquee { to { transform: translateX(-50%); } }

/* --- Intro ----------------------------------------------------------------- */

.intro-grid {
  display: grid; grid-template-columns: 5fr 7fr; gap: clamp(32px, 6vw, 96px);
}
.intro-grid .display-sm { color: var(--ink); }

.is-style-chips { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; margin-top: 2rem; }
.is-style-chips li {
  padding: 10px 18px;
  border: 1px solid var(--line); border-radius: 999px;
  background: var(--white);
  font-size: .93rem; color: var(--ink-soft);
}

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

/* --- Service cards --------------------------------------------------------- */

.cards {
  display: grid; gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  counter-reset: card;
}
.card {
  position: relative;
  display: flex; flex-direction: column;
  padding: clamp(28px, 3vw, 40px);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  counter-increment: card;
  transition: transform .4s var(--ease), box-shadow .4s var(--ease), border-color .4s;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: transparent; }
.card::before, .service-group > .wp-block-group:first-child::before {
  font-family: var(--font-display); font-style: italic;
  color: var(--red); font-size: 1.05rem;
}
.card::before { content: "0" counter(card); margin-bottom: 3.5rem; }
.card h3 {
  font-family: var(--font-display); font-weight: 400;
  font-size: 1.55rem; margin-bottom: .7rem;
}
.card p { color: var(--muted); font-size: .97rem; }
.card .card-more {
  margin-top: auto; padding-top: 1.6rem;
  font-size: .9rem; font-weight: 500; color: var(--ink);
  display: inline-flex; gap: .4em;
}
.card-more a { text-decoration: none; }
.card-more a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; } /* whole card is the link */
.card-more::after { content: "→"; transition: transform .3s var(--ease); }
.card:hover .card-more { color: var(--red); }
.card:hover .card-more::after { transform: translateX(4px); }
.card:has(a:focus-visible) { outline: 2px solid var(--red); outline-offset: 3px; }
.card-more a:focus-visible { outline: none; }

/* --- Process --------------------------------------------------------------- */

.process {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 0;
  counter-reset: step;
  border-top: 1px solid var(--line);
}
.process > * {
  position: relative;
  padding: 36px 28px 0 0;
  counter-increment: step;
}
.process > *::before {
  content: "0" counter(step);
  display: block; margin-bottom: 1.4rem;
  font-family: var(--font-display); font-style: italic; color: var(--red);
}
.process > *::after {
  content: ""; position: absolute; top: -5px; left: 0;
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--paper-2); border: 1px solid var(--red);
}
.process h3 { font-family: var(--font-display); font-size: 1.3rem; margin-bottom: .6rem; }
.process p { font-size: .95rem; color: var(--muted); }

@media (max-width: 1000px) {
  .process { grid-template-columns: 1fr; border-top: 0; border-left: 1px solid var(--line); }
  .process > * { padding: 0 0 36px 32px; }
  .process > *::after { top: 6px; left: -5px; }
  .process > *::before { margin-bottom: .5rem; }
}

/* --- Founder / quote ------------------------------------------------------- */

.founder {
  display: grid; grid-template-columns: 4fr 7fr; gap: clamp(36px, 6vw, 96px); align-items: center;
}
.is-style-portrait {
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--blush);
}
.is-style-portrait img { width: 100%; height: 100%; object-fit: cover; }
.quote {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(1.6rem, 3vw, 2.5rem); line-height: 1.22; letter-spacing: -.01em;
}
.quote em { color: var(--red); }
.quote-by { margin-top: 1.6rem; font-size: .95rem; color: var(--muted); }
.quote-by strong { display: block; color: var(--ink); font-weight: 600; }

@media (max-width: 900px) {
  .founder { grid-template-columns: 1fr; }
  .is-style-portrait { max-width: 360px; }
}

/* --- Stats ----------------------------------------------------------------- */

.stats {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 0;
  border-block: 1px solid var(--line);
}
.stats > * { padding: clamp(28px, 4vw, 48px) 24px; border-left: 1px solid var(--line); }
.stats > :first-child { border-left: 0; padding-left: 0; }
.stats .stat-num {
  margin: 0;
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(2.4rem, 4.5vw, 3.6rem); line-height: 1; letter-spacing: -.02em;
}
.stat-num.has-plus::after { content: "+"; font-size: .45em; color: var(--red); vertical-align: top; margin-left: 2px; }
.stat-label { margin-top: .8rem; font-size: .92rem; color: var(--muted); }

@media (max-width: 800px) {
  .stats { grid-template-columns: 1fr 1fr; }
  .stats > :nth-child(odd) { border-left: 0; padding-left: 0; }
  .stats > :nth-child(n+3) { border-top: 1px solid var(--line); }
}

/* --- CTA band ------------------------------------------------------------- */

.cta-band { background: var(--blush); overflow: hidden; }
.cta-inner {
  position: relative;
  display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 48px;
  padding-block: clamp(72px, 9vw, 120px);
}
.cta-copy { max-width: 640px; }
.cta-copy > p:not(.eyebrow) { margin-top: 1.4rem; color: var(--ink-soft); }
.cta-plane, .contact-plane { animation: float 7s ease-in-out infinite; }
.cta-plane { width: clamp(160px, 22vw, 280px); }
.cta-plane img, .contact-plane img { width: 100%; }
@keyframes float {
  0%, 100% { transform: translate(0, 0) rotate(0); }
  50% { transform: translate(-8px, -12px) rotate(-2deg); }
}
@media (max-width: 760px) {
  .cta-inner { grid-template-columns: 1fr; }
  .cta-plane { justify-self: end; margin-top: -24px; width: 150px; }
}

/* --- Page hero (inner pages) ---------------------------------------------- */

.page-hero { padding-block: clamp(56px, 9vw, 120px) clamp(48px, 6vw, 80px); }
.page-hero .display-xl { max-width: 15ch; }
.page-hero .lead { max-width: 52ch; margin-top: 1.8rem; }

.is-style-banner {
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 16 / 6;
}
.is-style-banner img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 55%; }
@media (max-width: 700px) { .is-style-banner { aspect-ratio: 4 / 3; } }

/* --- Split content ---------------------------------------------------------- */

.split {
  display: grid; grid-template-columns: 4fr 7fr; gap: clamp(32px, 6vw, 96px);
}
.split + .split { margin-top: clamp(64px, 8vw, 112px); }
.split-aside { position: relative; }
.split-aside .sticky { position: sticky; top: calc(var(--header-h) + 32px); }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }

/* --- Values ------------------------------------------------------------------ */

.values { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.values > * {
  padding: 32px; border-radius: var(--radius);
  background: var(--white); border: 1px solid var(--line);
}
.values h3 { font-family: var(--font-display); font-size: 1.5rem; margin-bottom: .6rem; }
.values h3 em { color: var(--red); }
.values p { color: var(--muted); font-size: .97rem; }
@media (max-width: 800px) { .values { grid-template-columns: 1fr; } }

/* --- Timeline ---------------------------------------------------------------- */

.is-style-timeline { list-style: none; border-left: 1px solid var(--line); margin-top: 2.5rem; }
.is-style-timeline li { position: relative; padding: 0 0 32px 32px; color: var(--muted); font-size: .95rem; }
.is-style-timeline li:last-child { padding-bottom: 0; }
.is-style-timeline li::before {
  content: ""; position: absolute; left: -5px; top: 10px;
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--paper); border: 1px solid var(--red);
}
.is-style-timeline li:last-child::before { background: var(--red); }
.is-style-timeline strong { display: block; font-family: var(--font-display); font-weight: 400; font-size: 1.35rem; color: var(--ink); }

/* --- Service groups ------------------------------------------------------- */

.service-groups { counter-reset: service; }
.service-group {
  display: grid; grid-template-columns: 1fr 1.4fr; gap: clamp(28px, 5vw, 80px);
  padding-block: clamp(40px, 5vw, 64px);
  border-top: 1px solid var(--line);
  counter-increment: service;
}
.service-group:last-child { border-bottom: 1px solid var(--line); }
.service-group > .wp-block-group:first-child::before { content: "0" counter(service); display: block; margin-bottom: 1rem; }
.service-group h3 { font-family: var(--font-display); font-size: clamp(1.7rem, 2.6vw, 2.2rem); margin-bottom: 1rem; }
.service-group > div > p { color: var(--muted); max-width: 40ch; }
.is-style-tick { list-style: none; display: grid; gap: 0; align-content: start; }
.is-style-tick li {
  display: flex; gap: 14px; align-items: baseline;
  padding: 14px 0; border-bottom: 1px solid var(--line);
}
.is-style-tick li:first-child { padding-top: 0; }
.is-style-tick li:last-child { border-bottom: 0; }
.is-style-tick li::before { content: "✦"; color: var(--red); font-size: .7rem; flex: none; transform: translateY(-1px); }
@media (max-width: 800px) { .service-group { grid-template-columns: 1fr; } }

.note {
  margin-top: 48px;
  padding: 28px 32px; border-radius: var(--radius);
  background: var(--sage-soft); color: var(--ink-soft);
}
.note strong { color: var(--ink); }

/* --- Folio ------------------------------------------------------------------ */

.folio-grid {
  display: grid; gap: 20px;
  grid-template-columns: repeat(6, 1fr);
}
/* Tiles come from the Folio grid block (blocks/folio-grid), which sets each tile's width class */
.folio-tile {
  position: relative; overflow: hidden; isolation: isolate;
  border-radius: var(--radius);
  min-height: 300px;
  display: flex; flex-direction: column; justify-content: flex-end; align-items: flex-start;
  padding: 28px;
  background: var(--tile, var(--blush));
  color: var(--ink); text-decoration: none;
  transition: transform .5s var(--ease);
}
.folio-tile.span-2 { grid-column: span 2; }
.folio-tile.span-3 { grid-column: span 3; }
.folio-tile.span-4 { grid-column: span 4; }
.folio-tile.span-6 { grid-column: span 6; }
.folio-tile.is-big { min-height: 440px; }
.folio-tile:hover { transform: scale(.985); }
/* no cover image yet: the project's initial, large and faint */
.folio-tile:not(.has-image)::before {
  content: var(--mark, "");
  position: absolute; top: 18px; right: 24px;
  font-family: var(--font-display); font-style: italic; font-weight: 300;
  font-size: clamp(4rem, 9vw, 7rem); line-height: 1; color: rgba(255,255,255,.6);
}
.folio-img {
  position: absolute; inset: 0; z-index: -2;
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .8s var(--ease);
}
.folio-tile.has-image { color: var(--white); }
.folio-tile.has-image::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(to top, rgba(36, 29, 27, .78), rgba(36, 29, 27, .25) 45%, transparent 70%);
}
.folio-tile.has-image:hover .folio-img { transform: scale(1.04); }
.folio-tile .folio-tag {
  font-size: .72rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  padding: 6px 12px; border-radius: 999px; background: rgba(255,255,255,.75); color: var(--ink);
  margin: 0 0 14px;
}
.folio-tile h3 { font-family: var(--font-display); font-size: 1.5rem; }
.folio-tile p { font-size: .9rem; color: var(--ink-soft); margin: .3rem 0 0; }
.folio-tile.has-image p { color: rgba(255,255,255,.85); }
.folio-more { margin-top: 1rem; font-size: .9rem; font-weight: 500; display: inline-flex; gap: .4em; }
.folio-more::after { content: "→"; transition: transform .3s var(--ease); }
.folio-tile:hover .folio-more::after { transform: translateX(4px); }
.js .folio-tile.is-extra { display: none; }
.js .folio.show-all .folio-tile.is-extra { display: flex; }
.folio-more-row { margin-top: 32px; text-align: center; }
@media (max-width: 900px) {
  .folio-grid { grid-template-columns: 1fr 1fr; }
  .folio-tile[class*="span-"] { grid-column: span 1; min-height: 240px; }
  .folio-tile.tablet-wide { grid-column: span 2; }
  .folio-tile.is-big { min-height: 320px; }
}
@media (max-width: 560px) {
  .folio-grid { grid-template-columns: 1fr; }
  .folio-tile[class*="span-"], .folio-tile.tablet-wide { grid-column: span 1; }
}

/* Project (case study) pages */
.project-terms { margin-top: 1.4rem; font-size: .85rem; color: var(--muted); }
.project-terms a { color: inherit; text-decoration: none; pointer-events: none; }
.page-hero .eyebrow a { text-decoration: none; }
.page-hero .wp-block-post-excerpt__excerpt { margin: 0; }
.page-hero .wp-block-post-excerpt { max-width: 52ch; margin-top: 1.8rem; }
.project-cover { margin-bottom: clamp(48px, 6vw, 80px); }
.rc-content > :is(.wp-block-gallery, .alignwide, .wp-block-columns) {
  width: min(100% - var(--gutter) * 2, var(--container));
  margin-inline: auto; margin-block: 2rem;
}
.rc-content > :is(.wp-block-image, .wp-block-gallery, .wp-block-embed, .wp-block-video) { margin-block: 2rem; }
.rc-content > .wp-block-image img { border-radius: var(--radius); }
.project-back { padding-block: 0 var(--section); max-width: calc(760px + var(--gutter) * 2); }
.project-content > :last-child { margin-bottom: 48px !important; }
.project-content:empty, .project-content:not(:has(*)) { display: none; }

.client-list ul {
  columns: 3 240px; column-gap: 48px;
  list-style: none;
}
.client-list li {
  break-inside: avoid;
  padding: 14px 0; border-bottom: 1px solid var(--line);
  font-family: var(--font-display); font-size: 1.2rem; font-weight: 300;
  transition: color .2s, padding-left .3s var(--ease);
}
.client-list li:hover { color: var(--red); padding-left: 8px; }

/* --- Contact -------------------------------------------------------------- */

.contact-grid { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(40px, 6vw, 96px); align-items: start; }
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; } }

.contact-list { display: grid; gap: 28px; margin-top: 2.5rem; }
.contact-list .label {
  margin: 0 0 .3rem;
  font-size: .75rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  color: var(--muted);
}
.contact-value {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(1.3rem, 2vw, 1.6rem); line-height: 1.35;
  color: var(--ink);
  overflow-wrap: anywhere;
}
.contact-value a { text-decoration: none; }
.contact-value a:hover { color: var(--red); }
.contact-plane { width: 200px; margin-top: 3rem; }

.form-card {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(28px, 4vw, 48px);
  box-shadow: var(--shadow);
}
.form-card h2 { margin-bottom: .6rem; }
.form-card h2 + p { color: var(--muted); margin-bottom: 2rem; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 600px) { .form-grid { grid-template-columns: 1fr; } }

.field label, .field legend {
  display: block; margin-bottom: 8px;
  font-size: .88rem; font-weight: 500; color: var(--ink);
}
.field .opt { color: var(--muted); font-weight: 400; }
.field input, .field textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--line); border-radius: 12px;
  background: var(--paper);
  font: inherit; font-size: 1rem; color: var(--ink);
  transition: border-color .2s, background-color .2s, box-shadow .2s;
}
.field textarea { min-height: 150px; resize: vertical; }
.field input:focus, .field textarea:focus {
  outline: none; background: var(--white);
  border-color: var(--red); box-shadow: 0 0 0 4px rgba(194, 0, 11, .1);
}

fieldset.field { border: 0; margin: 0; padding: 0; min-width: 0; }
.chip-options { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-options .wpcf7-list-item { display: block; margin: 0; }
.field .chip-options label { position: relative; margin: 0; cursor: pointer; }
.chip-options input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; pointer-events: none; }
.chip-options label > span {
  display: inline-block; padding: 9px 16px;
  border: 1px solid var(--line); border-radius: 999px;
  font-size: .9rem; font-weight: 400; color: var(--ink-soft);
  transition: all .2s;
}
.chip-options label:hover span { border-color: var(--ink-soft); }
.chip-options input:checked + span { background: var(--ink); border-color: var(--ink); color: var(--white); }
.chip-options input:focus-visible + span { outline: 2px solid var(--red); outline-offset: 2px; }

/* Contact Form 7 (its own stylesheet may load after ours, hence the .wpcf7 prefix) */
.wpcf7 .wpcf7-form-control-wrap { display: block; }
.wpcf7 .field .wpcf7-not-valid { border-color: var(--red); }
.wpcf7 .wpcf7-not-valid-tip { display: block; margin-top: 6px; font-size: .85rem; color: var(--red); }
.wpcf7 form .wpcf7-response-output {
  margin: 0 0 24px; padding: 18px 22px; border: 0; border-radius: 14px;
  font-size: .97rem; background: #fbe4e3; color: var(--red-deep);
}
.wpcf7 form.sent .wpcf7-response-output { background: var(--sage-soft); color: var(--ink); }
.wpcf7 form.init .wpcf7-response-output, .wpcf7 form.resetting .wpcf7-response-output, .wpcf7 form.submitting .wpcf7-response-output { display: none; }
.wpcf7 .wpcf7-submit:disabled { opacity: .6; cursor: progress; transform: none; }
.wpcf7 .wpcf7-spinner { vertical-align: middle; margin-inline: 16px 0; }
/* the Turnstile check normally runs invisibly; drop its empty grid row */
.form-grid > .full:has(> .wpcf7-turnstile) { margin-block: -10px; }

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

.site-footer {
  background: var(--ink); color: rgba(255,255,255,.72);
  padding-top: clamp(64px, 8vw, 104px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  font-size: .95rem;
}
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1.3fr; gap: 48px; }
.footer-brand .wp-block-image { margin-bottom: 1.6rem; }
.footer-brand p { max-width: 40ch; }
.site-footer .footer-heading {
  font-family: var(--font-body);
  font-size: .75rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase;
  color: var(--white); margin-bottom: 1.2rem;
}
.footer-links { list-style: none; display: grid; gap: 10px; }
.footer-links a { text-decoration: none; transition: color .2s; overflow-wrap: anywhere; }
.footer-links a:hover { color: var(--white); }
.site-footer .muted { color: rgba(255,255,255,.5); }
.footer-base {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px;
  margin-top: clamp(48px, 6vw, 80px);
  padding-block: 28px;
  /* divider aligned to the content column rather than the padded box */
  background: linear-gradient(rgba(255,255,255,.12), rgba(255,255,255,.12)) no-repeat top / 100% 1px;
  background-origin: content-box; background-clip: content-box;
  font-size: .85rem; color: rgba(255,255,255,.5);
}
.footer-base p { margin: 0; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }

/* --- Plain content (posts, or pages built without the locked sections) ------ */

.rc-content > :is(p, h1, h2, h3, h4, ul, ol, blockquote, table, figure, .wp-block-buttons, .wp-block-image) {
  width: min(100% - var(--gutter) * 2, 760px);
  margin-inline: auto;
}
.rc-content > :is(ul, ol) { padding-left: 1.25em; margin-bottom: 1.1em; }
.rc-content > :is(h2, h3, h4) { margin-block: 1.6em .6em; font-family: var(--font-display); }
.rc-content > :is(p, h1, h2, h3, h4, ul, ol, blockquote, table, figure, .wp-block-buttons, .wp-block-image):last-child { margin-bottom: var(--section); }
.post-list > li { list-style: none; padding-block: 28px; border-bottom: 1px solid var(--line); }
.post-list .eyebrow { margin-bottom: .6rem; }
.wp-block-post-title a { text-decoration: none; }
.wp-block-query { margin-top: 48px; }

/* --- Reveal on scroll ------------------------------------------------------- */

.js .reveal {
  opacity: 0; transform: translateY(24px);
  transition: opacity .9s var(--ease), transform .9s var(--ease);
  transition-delay: var(--d, 0s);
}
.js .reveal.is-visible { opacity: 1; transform: none; }

/* stagger siblings that come into view together */
:is(.hero-copy, .page-hero .container) > .reveal:nth-child(2) { --d: .08s; }
:is(.hero-copy, .page-hero .container) > .reveal:nth-child(3) { --d: .16s; }
.hero-copy > .reveal:nth-child(4) { --d: .24s; }
.hero-media { --d: .2s; }
:is(.intro-grid, .split, .founder, .contact-grid) > .reveal:nth-child(2) { --d: .1s; }
:is(.cards, .values) > .reveal:nth-child(2),
.folio-grid > .reveal:nth-child(3n+2) { --d: .08s; }
:is(.cards, .values) > .reveal:nth-child(3), .folio-grid > .reveal:nth-child(3n) { --d: .16s; }
.cards > .reveal:nth-child(4) { --d: .24s; }
:is(.process, .stats) > .reveal:nth-child(2) { --d: .06s; }
:is(.process, .stats) > .reveal:nth-child(3) { --d: .12s; }
:is(.process, .stats) > .reveal:nth-child(4) { --d: .18s; }
.process > .reveal:nth-child(5) { --d: .24s; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}
