/* Robyn Craigie-Williams portfolio
   Layout idea: editorial single column with a 12-col grid, arch-framed imagery,
   a fine-line sunburst mark, serif display with italic accent words. */

:root {
  --paper: #F5EEE6;
  --surface: #FCF8F3;
  --ink: #141B29;
  --ink-soft: #4F4B57;
  --line: #DCCFC2;
  --accent: #7B3B55;
  --accent-hover: #63293F;
  --on-accent: #FFF8F2;
  --gold: #C4963C;
  --gold-text: #7A5414;
  --blush: #EDD9D2;
  --deep: #111A28;
  --on-deep: #F3EBE1;
  --on-deep-soft: #B9B3BA;
  --deep-line: #2B3547;
  --deep-accent: #E7A9BC;
  --error: #9B2C2C;
  --ok: #2F6B4F;

  --font-display: "Playfair Display", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --font-label: "Marcellus", "Optima", "Candara", "Gill Sans", serif;
  --font-body: "Hanken Grotesk", "Helvetica Neue", Helvetica, Arial, sans-serif;

  --step--1: clamp(0.84rem, 0.82rem + 0.1vw, 0.9rem);
  --step-0: clamp(1rem, 0.97rem + 0.16vw, 1.1rem);
  --step-1: clamp(1.2rem, 1.12rem + 0.38vw, 1.42rem);
  --step-2: clamp(1.5rem, 1.32rem + 0.9vw, 2.05rem);
  --step-3: clamp(1.95rem, 1.6rem + 1.75vw, 3rem);
  --step-4: clamp(2.35rem, 1.75rem + 3vw, 4.25rem);
  --step-5: clamp(3rem, 2rem + 5vw, 6rem);

  --gutter: clamp(1.15rem, 0.6rem + 2.8vw, 3rem);
  --section: clamp(4rem, 3rem + 5vw, 7.5rem);
  --max: 76rem;
  --radius: 14px;
  --arch: 999px 999px 14px 14px;
  --shadow: 0 1px 2px rgba(20, 27, 41, .05), 0 12px 32px -18px rgba(20, 27, 41, .28);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0C121C;
    --surface: #151D2B;
    --ink: #F3EBE1;
    --ink-soft: #B7B0B6;
    --line: #2B3547;
    --accent: #E7A9BC;
    --accent-hover: #F3C4D2;
    --on-accent: #1C0F17;
    --gold: #E0B866;
    --gold-text: #E0B866;
    --blush: #2A2130;
    --deep: #070B12;
    --on-deep: #F3EBE1;
    --on-deep-soft: #B7B0B6;
    --deep-line: #232C3C;
    --deep-accent: #E7A9BC;
    --error: #F2A3A3;
    --ok: #8FD3B0;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 14px 34px -18px rgba(0, 0, 0, .7);
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --paper: #0C121C;
  --surface: #151D2B;
  --ink: #F3EBE1;
  --ink-soft: #B7B0B6;
  --line: #2B3547;
  --accent: #E7A9BC;
  --accent-hover: #F3C4D2;
  --on-accent: #1C0F17;
  --gold: #E0B866;
  --gold-text: #E0B866;
  --blush: #2A2130;
  --deep: #070B12;
  --on-deep: #F3EBE1;
  --on-deep-soft: #B7B0B6;
  --deep-line: #232C3C;
  --deep-accent: #E7A9BC;
  --error: #F2A3A3;
  --ok: #8FD3B0;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 14px 34px -18px rgba(0, 0, 0, .7);
  color-scheme: dark;
}

/* Base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 5.5rem; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  transition: background-color .3s ease, color .3s ease;
}
img, svg { max-width: 100%; display: block; }
img { height: auto; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 500; line-height: 1.12; margin: 0; text-wrap: balance; letter-spacing: -0.01em; }
h1 { font-size: var(--step-4); }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); line-height: 1.25; }
p { margin: 0; max-width: 65ch; }
ul, ol { margin: 0; padding: 0; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .2em; }
a:hover { color: var(--accent); }
em.accent { font-style: italic; color: var(--accent); }
strong { font-weight: 600; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--accent); color: var(--on-accent); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 1rem; top: -4rem; z-index: 200; background: var(--ink); color: var(--paper); padding: .7rem 1rem; border-radius: 8px; }
.skip-link:focus { top: 1rem; color: var(--paper); }

.wrap { width: min(100% - 2 * var(--gutter), var(--max)); margin-inline: auto; }
.section { padding-block: var(--section); }
.section--tight { padding-block: calc(var(--section) * .6); }
.section--surface { background: var(--surface); border-block: 1px solid var(--line); }
.section--deep { background: var(--deep); color: var(--on-deep); }
.section--deep .lede, .section--deep .muted { color: var(--on-deep-soft); }
.section--deep em.accent, .section--deep a:hover { color: var(--deep-accent); }
.stack > * + * { margin-top: 1.1em; }
.lede { font-size: var(--step-1); line-height: 1.5; color: var(--ink-soft); }
.muted { color: var(--ink-soft); }
.eyebrow {
  font-family: var(--font-label); text-transform: uppercase; letter-spacing: .16em;
  font-size: var(--step--1); color: var(--gold-text); display: flex; align-items: center; gap: .7rem; margin: 0 0 1.2rem;
}
.eyebrow::before { content: ""; width: 2rem; height: 1px; background: currentColor; flex: none; }
.section--deep .eyebrow { color: var(--gold); }
.section-head { display: grid; gap: 1.2rem; margin-bottom: clamp(2rem, 1.5rem + 2vw, 3.5rem); }
@media (min-width: 60rem) {
  .section-head--split { grid-template-columns: 1.1fr 1fr; align-items: end; column-gap: 4rem; }
}

/* Buttons and links */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  min-height: 3rem; padding: .75rem 1.4rem; border-radius: 999px; border: 1px solid transparent;
  font: 600 var(--step-0)/1.2 var(--font-body); text-decoration: none; cursor: pointer;
  transition: background-color .2s ease, color .2s ease, border-color .2s ease, transform .2s ease;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--accent); color: var(--on-accent); }
.btn--primary:hover { background: var(--accent-hover); color: var(--on-accent); }
.btn--ghost { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn--ghost:hover { background: var(--ink); color: var(--paper); }
.section--deep .btn--primary { background: var(--deep-accent); color: #1C0F17; }
.section--deep .btn--primary:hover { background: #F3C4D2; color: #1C0F17; }
.section--deep .btn--ghost { border-color: var(--on-deep); color: var(--on-deep); }
.section--deep .btn--ghost:hover { background: var(--on-deep); color: var(--deep); }
.btn .arrow, .link-arrow .arrow { transition: transform .2s ease; }
.btn:hover .arrow, .link-arrow:hover .arrow { transform: translateX(4px); }
.btn-row { display: flex; flex-wrap: wrap; gap: .8rem; }
.link-arrow { display: inline-flex; align-items: center; gap: .5rem; font-weight: 600; text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: .15rem; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 100;
  border-bottom: 1px solid transparent; transition: border-color .2s ease;
}
/* The blur sits on a pseudo-element: a backdrop-filter on the header itself would trap the fixed mobile menu inside it. */
.site-header::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  transition: background-color .3s ease;
}
body.menu-open .site-header::before { background: var(--paper); }
.site-header.is-scrolled { border-bottom-color: var(--line); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 4.5rem; }
.brand { display: inline-flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand svg { width: 2.4rem; height: auto; color: var(--gold); flex: none; }
.brand-name { font-family: var(--font-label); text-transform: uppercase; letter-spacing: .14em; font-size: .92rem; line-height: 1.2; }
.nav-list { display: flex; align-items: center; gap: clamp(1rem, 2vw, 2rem); list-style: none; }
.nav-list a:not(.btn) { text-decoration: none; font-size: .98rem; padding: .4rem 0; position: relative; }
.nav-list a:not(.btn)::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .25s ease; }
.nav-list a:not(.btn):hover::after, .nav-list a[aria-current="page"]::after { transform: scaleX(1); }
.nav-list a[aria-current="page"] { color: var(--accent); }
.nav-list .btn { min-height: 2.6rem; padding: .5rem 1.1rem; font-size: .95rem; }
.header-tools { display: flex; align-items: center; gap: .5rem; }
.icon-btn {
  width: 2.75rem; height: 2.75rem; display: inline-grid; place-items: center; border-radius: 50%;
  background: transparent; border: 1px solid var(--line); color: var(--ink); cursor: pointer;
  transition: border-color .2s ease, background-color .2s ease, transform .3s ease;
}
.icon-btn:hover { border-color: var(--ink); }
.icon-btn svg { width: 1.2rem; height: 1.2rem; }
.theme-toggle .icon-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun { display: none; }
  :root:not([data-theme="light"]) .theme-toggle .icon-moon { display: block; }
}
.menu-toggle { display: none; }
@media (max-width: 61.99rem) {
  .menu-toggle { display: inline-grid; }
  .site-nav {
    position: fixed; top: 4.5rem; left: 0; right: 0; bottom: 0; height: calc(100dvh - 4.5rem); z-index: 99; background: var(--paper); padding: 1.5rem var(--gutter) 2.5rem;
    overflow-y: auto; visibility: hidden; opacity: 0; transform: translateY(-8px);
    transition: opacity .25s ease, transform .25s ease, visibility 0s linear .25s;
  }
  .site-nav.is-open { visibility: visible; opacity: 1; transform: none; transition-delay: 0s; }
  .nav-list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-list li { border-bottom: 1px solid var(--line); }
  .nav-list a:not(.btn) { display: block; font-family: var(--font-display); font-size: 1.9rem; padding: 1rem 0; }
  .nav-list a:not(.btn)::after { display: none; }
  .nav-list li:last-child { border: 0; padding-top: 1.5rem; }
  .nav-list .btn { width: 100%; min-height: 3.2rem; font-size: 1.05rem; }
  .brand-name { font-size: .78rem; letter-spacing: .12em; }
  body.menu-open { overflow: hidden; }
}
@media (max-width: 23rem) { .brand-name { max-width: 9rem; } }

/* Hero */
.hero { padding-block: clamp(3rem, 2.5rem + 3vw, 5.5rem) var(--section); position: relative; overflow: hidden; }
.hero-grid { display: grid; gap: clamp(2rem, 1rem + 4vw, 4.5rem); align-items: center; }
.hero h1 { font-size: var(--step-4); max-width: 17ch; }
.hero .lede { margin-top: 1.5rem; max-width: 34rem; }
.hero .btn-row { margin-top: 2rem; }
.hero-note { margin-top: 1.6rem; display: flex; align-items: center; gap: .6rem; font-size: var(--step--1); color: var(--ink-soft); }
.dot { width: .55rem; height: .55rem; border-radius: 50%; background: var(--ok); flex: none; box-shadow: 0 0 0 4px color-mix(in srgb, var(--ok) 20%, transparent); }
.hero-figure { position: relative; justify-self: center; width: min(100%, 26rem); }
.arch { border-radius: var(--arch); overflow: hidden; background: var(--blush); aspect-ratio: 4 / 5; box-shadow: var(--shadow); }
.arch img { width: 100%; height: 100%; object-fit: cover; }
.hero-figure .burst { position: absolute; top: -4.6rem; left: 50%; transform: translateX(-50%); width: 9rem; color: var(--gold); z-index: -1; }
.hero-card {
  position: absolute; left: -1rem; bottom: 1.5rem; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: .9rem 1.1rem; box-shadow: var(--shadow); max-width: 13.5rem;
}
.hero-card b { display: block; font: 500 1.9rem/1 var(--font-display); color: var(--accent); }
.hero-card span { font-size: .85rem; color: var(--ink-soft); line-height: 1.35; display: block; margin-top: .3rem; }
@media (min-width: 56rem) {
  .hero-grid { grid-template-columns: 1.25fr .9fr; }
  .hero-figure { justify-self: end; }
}
@media (max-width: 55.99rem) {
  .hero-figure { width: min(78%, 20rem); margin-top: 1.5rem; }
  .hero-card { left: -1.6rem; }
}

/* Page hero (inner pages) */
.page-hero { padding-block: clamp(2.5rem, 2rem + 3vw, 5rem) clamp(2rem, 1.5rem + 2vw, 3.5rem); }
.page-hero h1 { max-width: 20ch; }
.page-hero .lede { margin-top: 1.4rem; max-width: 40rem; }
.breadcrumb { font-size: var(--step--1); color: var(--ink-soft); margin-bottom: 1.6rem; }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; gap: .5rem; }
.breadcrumb li + li::before { content: "/"; margin-right: .5rem; color: var(--line); }
.breadcrumb a { text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(11.5rem, 1fr)); gap: 0; border-top: 1px solid var(--line); list-style: none; }
.stat { padding: 1.6rem 1.4rem 1.6rem 0; border-bottom: 1px solid var(--line); }
.stat-value { font: 500 var(--step-3)/1 var(--font-display); font-variant-numeric: tabular-nums lining-nums; color: var(--accent); display: block; white-space: nowrap; }
.stat-label { display: block; margin-top: .6rem; font-size: .95rem; line-height: 1.45; color: var(--ink-soft); max-width: 22ch; }
.stat-source { display: block; margin-top: .5rem; font: 400 .72rem/1.3 var(--font-label); letter-spacing: .12em; text-transform: uppercase; color: var(--gold-text); }
.section--deep .stats, .section--deep .stat { border-color: var(--deep-line); }
.section--deep .stat-value { color: var(--deep-accent); }
.section--deep .stat-label { color: var(--on-deep-soft); }
.section--deep .stat-source { color: var(--gold); }
.stats--big .stat-value { font-size: var(--step-4); }
.stats--even { grid-template-columns: 1fr; border-top: 0; }
.stats--even .stat { padding: 1.4rem 0; text-align: center; border-bottom: 1px solid var(--line); }
.stats--even .stat:last-child { border-bottom: 0; }
.stats--even .stat-label { max-width: none; }
@media (min-width: 44rem) {
  .stats--even { grid-template-columns: repeat(3, 1fr); }
  .stats--even .stat { padding: .6rem 1.5rem; border-bottom: 0; border-left: 1px solid var(--line); }
  .stats--even .stat:first-child { border-left: 0; }
}

/* Client names */
.clients { display: flex; flex-wrap: wrap; gap: .6rem 2.2rem; list-style: none; align-items: baseline; }
.clients li { font-family: var(--font-label); text-transform: uppercase; letter-spacing: .14em; font-size: clamp(.95rem, .9rem + .3vw, 1.15rem); color: var(--ink-soft); }

.clients--logos { gap: 1.5rem clamp(1.5rem, 2.4vw, 2.2rem); align-items: center; }
.clients--logos li { display: flex; align-items: center; }
.logo { display: block; width: calc(var(--w) * .72px); height: calc(var(--h) * .72px); background-color: var(--ink-soft); -webkit-mask-size: contain; mask-size: contain; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; -webkit-mask-position: center; mask-position: center; transition: background-color .2s ease; }
.logo:hover { background-color: var(--ink); }

/* Two column prose */
.split { display: grid; gap: clamp(2rem, 1rem + 4vw, 5rem); }
@media (min-width: 56rem) { .split { grid-template-columns: 1fr 1.25fr; } .split--even { grid-template-columns: 1fr 1fr; } }
.prose > * + * { margin-top: 1.15em; }
.prose h2 { font-size: var(--step-2); margin-top: 2.2em; }
.prose h3 { margin-top: 1.8em; }
.prose ul { padding-left: 1.2rem; }
.prose li + li { margin-top: .45em; }
.prose li::marker { color: var(--gold); }

/* Service list (home + services) */
.service-list { list-style: none; border-top: 1px solid var(--line); }
.service-row { border-bottom: 1px solid var(--line); }
.service-row a {
  display: grid; grid-template-columns: 3.2rem 1fr auto; gap: 1rem 1.5rem; align-items: baseline;
  padding: 1.6rem 0; text-decoration: none; color: inherit; transition: padding .25s ease, color .2s ease;
}
.service-row a:hover { padding-left: .8rem; color: var(--accent); }
.service-num { font: italic 400 1.15rem/1 var(--font-display); color: var(--gold-text); font-variant-numeric: lining-nums; }
.service-row h3 { font-size: var(--step-2); }
.service-row p { grid-column: 2; color: var(--ink-soft); max-width: 52ch; margin-top: -.4rem; }
.service-row .arrow { grid-row: 1; grid-column: 3; font-size: 1.4rem; }
@media (min-width: 56rem) {
  .service-row a { grid-template-columns: 4rem 1fr 1.3fr auto; align-items: center; }
  .service-row p { grid-column: 3; margin-top: 0; }
  .service-row .arrow { grid-column: 4; }
}

/* Cards */
.grid { display: grid; gap: clamp(1.25rem, 1rem + 1.2vw, 2rem); }
.grid--3 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 19rem), 1fr)); }
.grid--2 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 24rem), 1fr)); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem; }
.section--surface .card { background: var(--paper); }
.card h3 + p { margin-top: .6rem; color: var(--ink-soft); }
.card .step-num { font: italic 400 1.1rem/1 var(--font-display); color: var(--gold-text); display: block; margin-bottom: 1rem; }

/* Work cards */
.work-grid { display: grid; gap: clamp(1.5rem, 1rem + 2vw, 2.5rem); grid-template-columns: repeat(auto-fill, minmax(min(100%, 21rem), 1fr)); list-style: none; }
.work-card { position: relative; display: flex; flex-direction: column; }
.work-card[hidden] { display: none; }
.work-media { border-radius: var(--radius); overflow: hidden; background: var(--blush); aspect-ratio: 4 / 3; position: relative; }
.work-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.2, .7, .2, 1); }
.work-card:hover .work-media img { transform: scale(1.04); }
.work-metric {
  position: absolute; left: .8rem; bottom: .8rem; background: var(--deep); color: var(--on-deep);
  border-radius: 999px; padding: .4rem .9rem; font-size: .85rem; font-weight: 600;
}
.work-body { padding-top: 1.1rem; display: grid; gap: .5rem; }
.work-client { font: 400 .76rem/1.3 var(--font-label); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-text); }
.work-card h2, .work-card h3 { font-size: var(--step-1); line-height: 1.25; }
.work-card h2 a, .work-card h3 a { text-decoration: none; }
.work-card h2 a::after, .work-card h3 a::after { content: ""; position: absolute; inset: 0; }
.work-card p { color: var(--ink-soft); font-size: .98rem; }
.tags { display: flex; flex-wrap: wrap; gap: .4rem; list-style: none; margin-top: .3rem; }
.tag { font-size: .78rem; border: 1px solid var(--line); border-radius: 999px; padding: .15rem .65rem; color: var(--ink-soft); }
.work-grid--feature .work-card:first-child { grid-column: 1 / -1; }
@media (min-width: 56rem) { .work-grid--feature { grid-template-columns: 1fr 1fr; } }
@media (min-width: 56rem) {
  .work-grid--feature .work-card:first-child { flex-direction: row; gap: 2.5rem; align-items: center; }
  .work-grid--feature .work-card:first-child .work-media { flex: 1.3; aspect-ratio: 16 / 10; }
  .work-grid--feature .work-card:first-child .work-body { flex: 1; padding: 0; }
  .work-grid--feature .work-card:first-child h3 { font-size: var(--step-2); }
}

/* Filters */
.filters { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1rem; }
.chip {
  min-height: 2.6rem; padding: .4rem 1rem; border-radius: 999px; border: 1px solid var(--line); background: transparent;
  color: var(--ink); font: 500 .95rem/1.2 var(--font-body); cursor: pointer; transition: background-color .2s ease, color .2s ease, border-color .2s ease;
}
.chip:hover { border-color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.filter-status { font-size: var(--step--1); color: var(--ink-soft); margin-bottom: 2rem; min-height: 1.5em; }
@media (max-width: 40rem) {
  .filters { flex-wrap: nowrap; overflow-x: auto; margin-inline: calc(var(--gutter) * -1); padding: .25rem var(--gutter) .6rem; scrollbar-width: none; }
  .filters::-webkit-scrollbar { display: none; }
  .chip { flex: none; }
}

/* Case study */
.case-hero { background: var(--deep); color: var(--on-deep); padding-block: clamp(2.5rem, 2rem + 3vw, 5rem); position: relative; overflow: hidden; }
.case-hero .breadcrumb, .case-hero .lede { color: var(--on-deep-soft); }
.case-hero .breadcrumb li + li::before { color: var(--deep-line); }
.case-hero a:hover { color: var(--deep-accent); }
.case-hero .eyebrow { color: var(--gold); }
.case-hero em.accent { color: var(--deep-accent); }
.case-num { position: absolute; right: var(--gutter); top: 1rem; font: italic 400 clamp(6rem, 4rem + 14vw, 16rem)/1 var(--font-display); color: var(--deep-line); pointer-events: none; user-select: none; }
.case-hero .wrap { position: relative; }
.case-hero h1 { max-width: 24ch; font-size: var(--step-3); line-height: 1.15; }
.case-meta { display: grid; grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr)); gap: 1.5rem; margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid var(--deep-line); }
.case-meta dt { font: 400 .74rem/1.3 var(--font-label); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); }
.case-meta dd { margin: .35rem 0 0; font-size: .98rem; }
.case-media { margin-top: calc(var(--section) * -.35); position: relative; }
.case-media img { border-radius: var(--radius); width: 100%; aspect-ratio: 16 / 9; object-fit: cover; box-shadow: var(--shadow); background: var(--blush); }
.case-body { display: grid; gap: 3rem; }
@media (min-width: 60rem) { .case-body { grid-template-columns: 15rem 1fr; gap: 5rem; } .case-toc { position: sticky; top: 6.5rem; align-self: start; } }
.case-toc ol { list-style: none; display: grid; gap: .1rem; border-left: 1px solid var(--line); }
.case-toc a { display: block; padding: .4rem 0 .4rem 1rem; margin-left: -1px; border-left: 1px solid transparent; text-decoration: none; font-size: .95rem; color: var(--ink-soft); }
.case-toc a:hover, .case-toc a.is-active { color: var(--accent); border-left-color: var(--accent); }
.case-toc h2 { font: 400 .74rem/1.3 var(--font-label); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-text); margin-bottom: .9rem; }
@media (max-width: 59.99rem) { .case-toc { display: none; } }
.case-section + .case-section { margin-top: clamp(2.5rem, 2rem + 2vw, 4rem); padding-top: clamp(2.5rem, 2rem + 2vw, 4rem); border-top: 1px solid var(--line); }
.case-section h2 { font-size: var(--step-2); margin-bottom: 1.2rem; }
.channels { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; margin-top: 1.4rem; }
.channels li { background: var(--blush); border-radius: 999px; padding: .3rem .9rem; font-size: .9rem; }

/* Bar chart */
.chart { margin-top: 2rem; padding: 1.5rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.chart figcaption { font-size: .92rem; color: var(--ink-soft); margin-bottom: 1.2rem; }
.chart-rows { display: grid; gap: 1rem; list-style: none; }
.chart-row { display: grid; gap: .35rem; }
.chart-label { display: flex; justify-content: space-between; gap: 1rem; font-size: .92rem; }
.chart-label b { font-variant-numeric: tabular-nums; }
.chart-track { height: .7rem; border-radius: 999px; background: var(--blush); overflow: hidden; }
.chart-bar { display: block; height: 100%; width: var(--w); border-radius: 999px; background: var(--accent); transform-origin: left; }
.chart-row:last-child .chart-bar { background: var(--gold); }
.js .chart.will-reveal .chart-bar { transform: scaleX(0); }
.js .chart.is-in .chart-bar { transform: none; transition: transform 1s cubic-bezier(.2, .7, .2, 1); }
.chart-note { margin-top: 1rem; font-size: .8rem; color: var(--ink-soft); }

.next-case { display: grid; gap: .6rem; text-decoration: none; padding: 2rem 0; border-block: 1px solid var(--line); }
.next-case span { font: 400 .76rem/1.3 var(--font-label); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-text); }
.next-case b { font: 500 var(--step-2)/1.15 var(--font-display); }

/* Timeline */
.timeline { list-style: none; border-top: 1px solid var(--line); }
.timeline > li { border-bottom: 1px solid var(--line); }
.timeline summary {
  display: grid; grid-template-columns: 1fr auto; gap: .3rem 1.5rem; align-items: center; padding: 1.4rem 0; cursor: pointer; list-style: none;
}
.timeline summary::-webkit-details-marker { display: none; }
.tl-dates { font: 400 .78rem/1.3 var(--font-label); letter-spacing: .12em; text-transform: uppercase; color: var(--gold-text); grid-column: 1; }
.tl-role { font: 500 var(--step-1)/1.25 var(--font-display); grid-column: 1; }
.tl-org { color: var(--ink-soft); grid-column: 1; font-size: .98rem; }
.tl-icon { grid-column: 2; grid-row: 1 / span 3; width: 2.4rem; height: 2.4rem; border: 1px solid var(--line); border-radius: 50%; display: grid; place-items: center; transition: transform .3s ease, background-color .2s ease, color .2s ease; }
.timeline summary:hover .tl-icon { background: var(--ink); color: var(--paper); border-color: var(--ink); }
details[open] .tl-icon { transform: rotate(45deg); }
.tl-body { padding: 0 0 1.8rem; max-width: 46rem; }
.tl-body ul { padding-left: 1.2rem; margin-top: .9rem; }
.tl-body li + li { margin-top: .4em; }
.tl-body li::marker { color: var(--gold); }
.tl-icon { grid-row: 1 / span 2; }

/* Tabs */
.tablist { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1.5rem; }
.tab { min-height: 2.6rem; padding: .4rem 1rem; border-radius: 999px; border: 1px solid var(--line); background: transparent; color: var(--ink); font: 500 .95rem/1.2 var(--font-body); cursor: pointer; }
.tab:hover { border-color: var(--ink); }
.tab[aria-selected="true"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.tabpanel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(1.4rem, 1rem + 2vw, 2.5rem); }
.tabpanel[hidden] { display: none; }
.tabpanel h3 { font-size: var(--step-2); }
.tabpanel p { margin-top: .8rem; color: var(--ink-soft); }
.skill-cols { display: grid; gap: 1.5rem 3rem; grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); margin-top: 1.6rem; }
.skill-cols h4 { font: 400 .76rem/1.3 var(--font-label); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-text); margin-bottom: .7rem; }
.skill-cols ul { list-style: none; display: flex; flex-wrap: wrap; gap: .4rem; }
.skill-cols li { border: 1px solid var(--line); border-radius: 999px; padding: .2rem .75rem; font-size: .9rem; background: var(--paper); transition: border-color .2s ease, transform .2s ease; }
.skill-cols li:hover { border-color: var(--accent); transform: translateY(-1px); }
@media (max-width: 40rem) {
  .tablist { flex-wrap: nowrap; overflow-x: auto; margin-inline: calc(var(--gutter) * -1); padding: .25rem var(--gutter) .6rem; scrollbar-width: none; }
  .tablist::-webkit-scrollbar { display: none; }
  .tab { flex: none; }
}

/* Service detail */
.service-detail { display: grid; gap: 2rem; padding-block: clamp(2.5rem, 2rem + 2vw, 4.5rem); border-top: 1px solid var(--line); }
.service-detail:first-of-type { border-top: 0; }
@media (min-width: 60rem) { .service-detail { grid-template-columns: 1fr 1.5fr; gap: 5rem; } .service-detail > header { position: sticky; top: 6.5rem; align-self: start; } }
.service-detail .service-num { font-size: 1.4rem; display: block; margin-bottom: 1rem; }
.service-detail h2 { font-size: var(--step-3); }
.service-detail header p { margin-top: 1rem; color: var(--ink-soft); }
.modes { display: flex; flex-wrap: wrap; gap: .4rem; list-style: none; margin-top: 1.3rem; }
.modes li { font-size: .8rem; border-radius: 999px; padding: .2rem .7rem; background: var(--blush); }
.service-blocks { display: grid; gap: 1.8rem; }
.service-blocks h3 { font: 400 .78rem/1.3 var(--font-label); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-text); margin-bottom: .6rem; }
.deliverables { list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); gap: 0 2rem; }
.deliverables li { padding: .6rem 0; border-bottom: 1px solid var(--line); font-size: .98rem; }
.evidence { background: var(--surface); border: 1px solid var(--line); border-left: 3px solid var(--accent); border-radius: 0 var(--radius) var(--radius) 0; padding: 1.1rem 1.3rem; font-size: .98rem; }
.evidence a { font-weight: 600; }

/* FAQ */
.faq { border-top: 1px solid var(--line); max-width: 52rem; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { display: flex; justify-content: space-between; gap: 1.5rem; align-items: center; padding: 1.2rem 0; cursor: pointer; list-style: none; font: 500 var(--step-1)/1.3 var(--font-display); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 300 1.6rem/1 var(--font-body); color: var(--accent); transition: transform .3s ease; flex: none; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding-bottom: 1.4rem; color: var(--ink-soft); }

/* Form */
.form { display: grid; gap: 1.3rem; }
.field { display: grid; gap: .4rem; }
.field-row { display: grid; gap: 1.3rem; }
@media (min-width: 40rem) { .field-row { grid-template-columns: 1fr 1fr; } }
label, legend { font-weight: 600; font-size: .95rem; }
.optional { font-weight: 400; color: var(--ink-soft); }
input[type="text"], input[type="email"], textarea, select {
  width: 100%; font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line);
  border-radius: 10px; padding: .8rem .95rem; min-height: 3rem; transition: border-color .2s ease, box-shadow .2s ease;
}
textarea { min-height: 9.5rem; resize: vertical; }
input:hover, textarea:hover, select:hover { border-color: var(--ink-soft); }
input:focus-visible, textarea:focus-visible, select:focus-visible { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent); }
[aria-invalid="true"] { border-color: var(--error) !important; }
.field-error { color: var(--error); font-size: .88rem; min-height: 0; }
.field-hint { color: var(--ink-soft); font-size: .88rem; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { border-radius: 10px; padding: 1rem 1.2rem; border: 1px solid var(--line); background: var(--surface); }
.form-status:empty { display: none; }
.form-status[data-state="error"] { border-color: var(--error); color: var(--error); }
.form-status[data-state="ok"] { border-color: var(--ok); }
.contact-grid { display: grid; gap: 3rem; }
@media (min-width: 60rem) { .contact-grid { grid-template-columns: 1.4fr 1fr; gap: 5rem; } }
.contact-details { display: grid; gap: 1.6rem; align-content: start; }
.contact-details dt { font: 400 .76rem/1.3 var(--font-label); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-text); }
.contact-details dd { margin: .35rem 0 0; }
.contact-details dl { display: grid; gap: 1.4rem; }

/* CTA band + footer */
.cta-band h2 { font-size: var(--step-4); max-width: 16ch; }
.cta-band .lede { margin-top: 1.2rem; max-width: 36rem; }
.cta-band .btn-row { margin-top: 2rem; }
.cta-band { position: relative; overflow: hidden; }
.cta-band .burst { position: absolute; right: -3rem; bottom: -1rem; width: clamp(14rem, 30vw, 26rem); color: var(--deep-line); pointer-events: none; }
.cta-band .wrap { position: relative; }
.site-footer { background: var(--deep); color: var(--on-deep); border-top: 1px solid var(--deep-line); padding-block: 3rem 2rem; }
.footer-grid { display: grid; gap: 2.5rem; grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); }
.site-footer .brand { color: var(--on-deep); }
.site-footer h2 { font: 400 .76rem/1.3 var(--font-label); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-bottom: .9rem; }
.site-footer ul { list-style: none; display: grid; gap: .45rem; }
.site-footer a { text-decoration: none; color: var(--on-deep); }
.site-footer a:hover { color: var(--deep-accent); text-decoration: underline; }
.site-footer p { color: var(--on-deep-soft); font-size: .95rem; margin-top: 1rem; max-width: 30ch; }
.footer-base { margin-top: 2.5rem; padding-top: 1.4rem; border-top: 1px solid var(--deep-line); display: flex; flex-wrap: wrap; justify-content: space-between; gap: .8rem; font-size: .85rem; color: var(--on-deep-soft); }

.to-top { position: fixed; right: 1rem; bottom: 1rem; z-index: 90; background: var(--surface); opacity: 0; visibility: hidden; transform: translateY(8px); transition: opacity .25s ease, transform .25s ease, visibility 0s linear .25s; box-shadow: var(--shadow); }
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }

/* Motion */
.js .will-reveal { opacity: 0; transform: translateY(18px); }
.js .will-reveal.is-in { opacity: 1; transform: none; transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .2, 1); }
.burst line { stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; }
.js .hero .burst line { stroke-dasharray: 30; stroke-dashoffset: 30; animation: ray .9s ease forwards; animation-delay: calc(var(--i) * 45ms + 200ms); }
@keyframes ray { to { stroke-dashoffset: 0; } }
@view-transition { navigation: auto; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; }
  .js .will-reveal { opacity: 1; transform: none; }
  .js .chart.will-reveal .chart-bar { transform: none; }
  .js .hero .burst line { stroke-dashoffset: 0; animation: none; }
  @view-transition { navigation: none; }
}

@media print {
  .site-header, .to-top, .cta-band, .filters { display: none; }
  body { background: #fff; color: #000; }
}

/* Mobile menu button shows a close mark while the menu is open */
.menu-toggle[aria-expanded="true"] svg { display: none; }
.menu-toggle[aria-expanded="true"]::after { content: "\00d7"; font: 300 1.7rem/1 var(--font-body); }
