/* --- Story-world colour hook: any element with data-world exposes --world. --- */
[data-world="scared"] { --world: var(--world-scared); }
[data-world="culture"] { --world: var(--world-culture); }
[data-world="plan"] { --world: var(--world-plan); }
[data-world="made"] { --world: var(--world-made); }

/* --- Custom cursor (fine pointers only): a small ink dot that swells over links. --- */
@media (hover: hover) and (pointer: fine) {
  html.has-cursor, html.has-cursor body, html.has-cursor a, html.has-cursor button, html.has-cursor label { cursor: none; }
}
.custom-cursor {
  --cx: 0px; --cy: 0px;
  position: fixed; left: 0; top: 0;
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--color-clay);
  pointer-events: none;
  transform: translate(calc(var(--cx) - 50%), calc(var(--cy) - 50%));
  z-index: 210;
  opacity: 0;
  transition: width 0.35s var(--ease-out), height 0.35s var(--ease-out),
    background-color 0.35s var(--ease-out), opacity 0.3s var(--ease-out);
}
.custom-cursor.is-ready { opacity: 1; }
.custom-cursor--active { width: 44px; height: 44px; background: rgba(255, 222, 89, 0.55); }
@media (hover: none), (pointer: coarse) { .custom-cursor { display: none; } }

/* --- Logo crop: assets/img/brand/logo.png has wide transparent margins around the stacked wordmark,
   so these classes scale the image and show only the wordmark region. --- */
.site-logo { display: flex; align-items: center; min-height: 44px; min-width: 44px; border-radius: var(--radius-full); }
.logo-mark { position: relative; overflow: hidden; display: block; flex-shrink: 0; }
.logo-mark img { position: absolute; max-width: none; }
.logo-mark--nav { width: 53.3px; height: 32px; }
.logo-mark--nav img { width: 157.9px; height: 89.37px; top: -27.7px; left: -52.36px; }

/* --- Floating island nav; switches to a dark glass over dark sections. --- */
.site-header {
  position: fixed; top: var(--space-4); left: 0; right: 0; z-index: 60;
  display: flex; justify-content: center;
  padding: 0 var(--space-4);
  pointer-events: none;
  transition: transform 0.7s var(--ease-out);
}
.site-header.is-hidden { transform: translateY(calc(-100% - var(--space-5))); }
.site-header__inner {
  pointer-events: auto;
  display: flex; align-items: center; gap: var(--space-4);
  padding: var(--space-2) var(--space-2) var(--space-2) var(--space-4);
  border-radius: var(--radius-full);
  background: rgba(247, 241, 230, 0.78);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  box-shadow: 0 0 0 1px var(--color-line), 0 16px 40px -20px rgba(31, 22, 18, 0.35);
  transition: background-color 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out);
}
.site-nav { display: flex; gap: 2px; align-items: center; }
.site-nav a {
  font-size: 0.92rem; font-weight: 600;
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-full);
  color: var(--color-ink);
  transition: background-color 0.4s var(--ease-out), color 0.4s var(--ease-out);
}
.site-nav a:hover { color: var(--color-ink-deep); background: rgba(31, 22, 18, 0.06); }
.site-nav a.is-active { color: var(--color-ink-deep); background: var(--color-surface); box-shadow: 0 0 0 1px var(--color-line); }
.site-header__cta { padding-left: var(--space-3); }

.site-header.is-dark .site-header__inner { background: rgba(31, 22, 18, 0.72); box-shadow: 0 0 0 1px var(--color-line-dark), 0 16px 40px -20px rgba(0, 0, 0, 0.6); }
.site-header.is-dark .site-logo { background: var(--color-paper); padding: 0 var(--space-2); }
.site-header.is-dark .site-nav a { color: var(--color-on-dark-muted); }
.site-header.is-dark .site-nav a:hover { color: var(--color-on-dark); background: rgba(247, 241, 230, 0.08); }
.site-header.is-dark .site-nav a.is-active { color: var(--color-ink-deep); background: var(--color-paper); }
.site-header.is-dark .btn--primary { background-color: var(--color-ochre); color: var(--color-ink-deep); }
.site-header.is-dark .btn--primary .btn__icon { background: var(--color-ink-deep); color: var(--color-ochre); }

.nav-toggle {
  display: none; position: relative;
  width: 44px; height: 44px; border-radius: 50%; border: 0;
  background: var(--color-ink-deep); cursor: pointer; z-index: 2;
}
.nav-toggle span {
  position: absolute; left: 14px; right: 14px; height: 2px;
  background: var(--color-on-dark); border-radius: 2px;
  transition: transform 0.6s var(--ease-out), top 0.6s var(--ease-out);
}
.nav-toggle span:nth-child(1) { top: 18px; }
.nav-toggle span:nth-child(2) { top: 25px; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { top: 21px; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { top: 21px; transform: rotate(-45deg); }
.site-header.is-dark .nav-toggle { background: var(--color-paper); }
.site-header.is-dark .nav-toggle span { background: var(--color-ink-deep); }

@media (max-width: 960px) {
  .site-nav, .site-header__cta { display: none; }
  .nav-toggle { display: block; }
  .site-header__inner { width: 100%; justify-content: space-between; }
}

/* --- Full-screen menu overlay --- */
.menu-overlay {
  position: fixed; inset: 0; z-index: 55;
  display: flex; flex-direction: column; justify-content: center;
  padding: var(--space-10) var(--gutter) var(--space-7);
  background: var(--color-espresso);
  color: var(--color-on-dark);
  opacity: 0; visibility: hidden;
  transition: opacity 0.6s var(--ease-out), visibility 0s linear 0.6s;
}
.menu-overlay.is-open { opacity: 1; visibility: visible; transition: opacity 0.6s var(--ease-out); }
.menu-overlay__nav { display: flex; flex-direction: column; gap: var(--space-1); }
.menu-overlay__nav a {
  display: block; overflow: hidden;
  font-family: var(--font-display); text-transform: uppercase;
  font-size: clamp(2.6rem, 12vw, 5.5rem); line-height: 1.02;
}
.menu-overlay__nav a span { display: block; transform: translateY(110%); transition: transform 0.9s var(--ease-out), color 0.3s var(--ease-out); }
.menu-overlay.is-open .menu-overlay__nav a span { transform: none; }
.menu-overlay.is-open .menu-overlay__nav a:nth-child(2) span { transition-delay: 50ms; }
.menu-overlay.is-open .menu-overlay__nav a:nth-child(3) span { transition-delay: 100ms; }
.menu-overlay.is-open .menu-overlay__nav a:nth-child(4) span { transition-delay: 150ms; }
.menu-overlay.is-open .menu-overlay__nav a:nth-child(5) span { transition-delay: 200ms; }
.menu-overlay.is-open .menu-overlay__nav a:nth-child(6) span { transition-delay: 250ms; }
.menu-overlay__nav a:hover span, .menu-overlay__nav a.is-active span { color: var(--color-ochre); }
.menu-overlay__meta { margin-top: var(--space-7); color: var(--color-ochre); font-size: 1.6rem; }
body.menu-open { overflow: hidden; }

/* --- Eyebrow label --- */
.eyebrow {
  display: inline-flex; align-items: center; gap: var(--space-2);
  font-size: 0.74rem; font-weight: 800; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--color-ink);
  margin-bottom: var(--space-5);
}
.eyebrow::before { content: ""; width: 22px; height: 2px; border-radius: 2px; background: var(--color-clay); }
.eyebrow--dark { color: var(--color-on-dark-muted); }
.eyebrow--dark::before { background: var(--color-ochre); }

/* --- Buttons: pill with a nested circular icon. --- */
.btn {
  position: relative;
  display: inline-flex; align-items: center; gap: var(--space-3);
  font-family: var(--font-body); font-weight: 700; font-size: 0.95rem; line-height: 1;
  padding: 6px 6px 6px var(--space-5);
  min-height: 52px;
  border-radius: var(--radius-full);
  border: 0; cursor: pointer;
  --fx-glow: rgba(255, 222, 89, 0.3);
  --fx-halo: rgba(227, 111, 60, 0.4);
  --fx-a: var(--color-ochre);
  --fx-b: var(--color-clay);
  background-image: radial-gradient(120% 90% at 50% 100%, var(--fx-glow), transparent 70%);
  background-repeat: no-repeat; background-size: 100% 200%; background-position: 50% -100%;
  transition: transform 0.5s var(--ease-out), background-color 0.4s var(--ease-out),
    box-shadow 0.5s var(--ease-out), background-position 0.6s var(--ease-out), color 0.4s var(--ease-out);
}
.btn:active { transform: scale(0.97); }
.btn__icon {
  width: 40px; height: 40px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
  transition: transform 0.5s var(--ease-out);
}
.btn__icon svg { width: 16px; height: 16px; }
.btn:hover .btn__icon { transform: translate(3px, -2px) scale(1.06); }
.btn--primary { background-color: var(--color-ink-deep); color: var(--color-on-dark); }
.btn--primary .btn__icon { background: var(--color-ochre); color: var(--color-ink-deep); }
.btn--ochre { background-color: var(--color-ochre); color: var(--color-ink-deep); --fx-glow: rgba(255, 255, 255, 0.6); --fx-halo: rgba(255, 222, 89, 0.7); --fx-a: var(--color-clay); --fx-b: var(--color-paper); }
.btn--ochre .btn__icon { background: var(--color-ink-deep); color: var(--color-ochre); }
.btn--ghost { background-color: transparent; color: var(--color-ink-deep); box-shadow: inset 0 0 0 1.5px var(--color-field-border); --fx-glow: rgba(227, 111, 60, 0.12); }
.btn--ghost .btn__icon { background: rgba(31, 22, 18, 0.07); }
.btn--ghost:hover { background-color: var(--color-surface); }
.btn--light { background-color: var(--color-paper); color: var(--color-ink-deep); }
.btn--light .btn__icon { background: var(--color-ink-deep); color: var(--color-ochre); }
.btn--ghost-dark { background-color: transparent; color: var(--color-on-dark); box-shadow: inset 0 0 0 1.5px rgba(247, 241, 230, 0.4); }
.btn--ghost-dark .btn__icon { background: rgba(247, 241, 230, 0.12); }
.btn--sm { min-height: 44px; font-size: 0.88rem; padding-left: var(--space-4); }
.btn--sm .btn__icon { width: 32px; height: 32px; }
.btn--back .btn__icon { order: -1; }
.btn--back { padding: 6px var(--space-5) 6px 6px; }
.btn--back:hover .btn__icon { transform: translate(-3px, 0) scale(1.06); }
.btn[aria-disabled="true"] { opacity: 0.7; pointer-events: none; }

/* Button "galaxy" hover: glow rises, halo blooms, sparkles twinkle. main.js injects .btn__fx. */
.btn__fx { position: absolute; inset: 0; pointer-events: none; border-radius: inherit; }
.btn__spark { position: absolute; width: 11px; height: 11px; color: var(--fx-a); opacity: 0; transform: scale(0.4); }
.btn__spark:nth-child(1) { left: -5px; top: -6px; }
.btn__spark:nth-child(2) { right: 14%; bottom: -7px; width: 8px; height: 8px; color: var(--fx-b); }
.btn__spark:nth-child(3) { right: -4px; top: 22%; width: 7px; height: 7px; }
.btn__streak {
  position: absolute; left: var(--x); top: var(--y);
  width: 2px; height: 7px; margin: -3.5px 0 0 -1px; border-radius: 2px;
  background: var(--c); opacity: 0;
  transform: rotate(var(--r)) translate(0, 0) scale(0.6);
}
@media (hover: hover) {
  .btn:hover, .btn:focus-visible { background-position: 50% 0%; box-shadow: 0 0 0 1px var(--fx-halo), 0 10px 34px -6px var(--fx-halo); }
  .btn--ghost:hover, .btn--ghost:focus-visible { box-shadow: inset 0 0 0 1.5px var(--color-ink-deep), 0 10px 30px -8px var(--fx-halo); }
  .btn:hover .btn__spark, .btn:focus-visible .btn__spark { animation: btn-twinkle 1.6s var(--ease-in-out) infinite; }
  .btn:hover .btn__spark:nth-child(2), .btn:focus-visible .btn__spark:nth-child(2) { animation-delay: 0.35s; }
  .btn:hover .btn__spark:nth-child(3), .btn:focus-visible .btn__spark:nth-child(3) { animation-delay: 0.7s; }
  .btn:hover .btn__streak, .btn:focus-visible .btn__streak { animation: btn-streak 1.4s cubic-bezier(0.22, 0.61, 0.36, 1) var(--delay) infinite; }
}
@keyframes btn-twinkle {
  0%, 100% { opacity: 0; transform: scale(0.4) rotate(0deg); }
  45% { opacity: 1; transform: scale(1.15) rotate(45deg); }
  70% { opacity: 0.8; transform: scale(0.9) rotate(70deg); }
}
@keyframes btn-streak {
  0% { opacity: 0; transform: rotate(var(--r)) translate(0, 0) scale(0.6); }
  25% { opacity: 1; }
  100% { opacity: 0; transform: rotate(var(--r)) translate(0, calc(var(--d) * -1)) scale(1); }
}
@media (prefers-reduced-motion: reduce) { .btn__fx { display: none; } }

/* --- Badges and world labels --- */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.68rem; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase;
  padding: 6px 10px; border-radius: var(--radius-full);
  background: var(--color-surface); color: var(--color-ink-deep);
  box-shadow: 0 0 0 1px var(--color-line);
}
.badge--dark { background: var(--color-ink-deep); color: var(--color-on-dark); box-shadow: none; }
.world-badge {
  display: inline-flex; align-items: center; gap: 8px; width: fit-content;
  font-size: 0.8rem; font-weight: 700; color: var(--color-ink);
}
.world-badge::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--world, var(--color-cream)); box-shadow: 0 0 0 1.5px var(--color-ink-deep); }
a.world-badge:hover { color: var(--color-ink-deep); text-decoration: underline; text-underline-offset: 3px; }

/* --- Sticky notes: the handwritten accent device, lifted from the notes in the hero art. --- */
.note {
  position: relative; display: inline-block;
  max-width: 15ch;
  margin: 0;
  padding: 16px 18px 18px;
  font-family: var(--font-accent); font-weight: 600; font-size: 1.45rem; line-height: 1.05;
  color: var(--color-ink-deep);
  background: var(--note-bg, var(--color-ochre));
  border-radius: 2px 2px 16px 2px;
  box-shadow: var(--shadow-note);
  rotate: var(--tilt, -3deg);
}
.note::before {
  content: ""; position: absolute; top: -10px; left: 50%;
  width: 56px; height: 20px; translate: -50% 0; rotate: 3deg;
  background: rgba(255, 253, 248, 0.6);
  box-shadow: 0 1px 2px rgba(31, 22, 18, 0.12);
}
.note--clay { --note-bg: var(--color-clay); }
.note--sage { --note-bg: var(--color-sage); }
.note--lilac { --note-bg: var(--color-lilac); }
.note--paper { --note-bg: var(--color-surface); }

/* --- Chips (picker options, world tabs) --- */
.chip {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 48px; padding: 0 20px 0 16px;
  border: 0; border-radius: var(--radius-full);
  background: var(--color-surface);
  box-shadow: inset 0 0 0 1.5px var(--color-line-strong);
  font-weight: 700; font-size: 0.98rem; color: var(--color-ink-deep);
  cursor: pointer;
  transition: transform 0.45s var(--ease-spring), background-color 0.35s var(--ease-out), color 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}
.chip::before {
  content: ""; width: 12px; height: 12px; border-radius: 50%;
  background: var(--world, var(--color-ink-deep));
  box-shadow: 0 0 0 1.5px var(--color-ink-deep);
  transition: transform 0.45s var(--ease-spring);
}
.chip--all::before { background: conic-gradient(var(--world-scared) 0 25%, var(--world-culture) 0 50%, var(--world-plan) 0 75%, var(--world-made) 0); }
.chip:hover { transform: translateY(-2px); box-shadow: inset 0 0 0 1.5px var(--color-ink-deep); }
.chip:hover::before { transform: scale(1.25); }
.chip[aria-pressed="true"], .chip.is-active { background: var(--color-ink-deep); color: var(--color-on-dark); box-shadow: none; }
.chip[aria-pressed="true"]::before, .chip.is-active::before { box-shadow: 0 0 0 2px var(--color-on-dark); }

/* --- Story journey cards --- */
.story-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 290px), 1fr)); gap: var(--space-6) var(--space-5); }
.story-card {
  position: relative;
  color: var(--color-ink-deep);
  border-radius: var(--radius-lg);
  background: var(--color-surface);
  box-shadow: 0 0 0 1px var(--color-line);
  transition: transform 0.7s var(--ease-out), box-shadow 0.7s var(--ease-out);
}
.is-flipping .story-card { transition: none !important; }
.story-card:hover { transform: translateY(-6px) rotate(-0.4deg); box-shadow: 0 0 0 1px var(--color-line), var(--shadow-soft); }
.story-card__link { display: flex; flex-direction: column; height: 100%; border-radius: inherit; }
.story-card__media {
  position: relative; aspect-ratio: 4 / 3; overflow: hidden;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  background: var(--world, var(--color-cream));
}
.story-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease-out); }
.story-card:hover .story-card__media img { transform: scale(1.05); }
/* YouTube hqdefault thumbnails are 4:3 with the 16:9 frame letterboxed; 4/3 scale crops the bars. */
.story-card__media--yt img { transform: scale(1.34); }
.story-card:hover .story-card__media--yt img { transform: scale(1.4); }
.story-card__placeholder {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--space-3);
  padding: var(--space-6); text-align: center;
  font-family: var(--font-accent); font-weight: 600; font-size: clamp(1.6rem, 2.4vw, 2rem); line-height: 1.05;
}
.story-card__placeholder .doodle { width: 44px; height: 44px; color: var(--color-ink-deep); }
.story-card__format { position: absolute; top: 14px; left: 14px; }
.story-card__play {
  position: absolute; right: 14px; bottom: 14px; width: 52px; height: 52px; border-radius: 50%;
  background: var(--color-paper); box-shadow: var(--shadow-note);
  transition: transform 0.6s var(--ease-spring);
}
.story-card:hover .story-card__play { transform: scale(1.12) rotate(-8deg); }
.story-card__play::after {
  content: ""; position: absolute; top: 50%; left: 54%; transform: translate(-50%, -50%);
  border-style: solid; border-width: 8px 0 8px 13px; border-color: transparent transparent transparent var(--color-ink-deep);
}
.story-card__body { display: flex; flex-direction: column; gap: var(--space-2); flex: 1; padding: var(--space-5) var(--space-5) var(--space-6); }
.story-card__title { margin: var(--space-1) 0 0; font-size: clamp(1.25rem, 1.7vw, 1.45rem); }
.story-card__line { margin: 0; font-family: var(--font-accent); font-weight: 600; font-size: 1.45rem; line-height: 1.1; color: var(--color-terracotta); }
.story-card__excerpt { margin: 0; font-size: 0.95rem; color: var(--color-ink-soft); }
.story-card__more {
  margin-top: auto; padding-top: var(--space-3);
  display: inline-flex; align-items: center; gap: var(--space-2);
  font-size: 0.86rem; font-weight: 800; color: var(--color-ink-deep);
}
.story-card__more svg { width: 14px; height: 14px; transition: transform 0.5s var(--ease-out); }
.story-card:hover .story-card__more svg { transform: translate(3px, -2px); }
.story-card__date { font-size: 0.78rem; color: var(--color-ink-soft); }

/* --- Forms --- */
.form { display: flex; flex-direction: column; gap: var(--space-5); }
.form .btn { align-self: flex-start; margin-top: var(--space-2); }
.form-field { display: flex; flex-direction: column; gap: var(--space-2); border: 0; padding: 0; margin: 0; min-width: 0; }
.form-field label, .form-field legend { font-weight: 800; font-size: 0.78rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--color-ink); padding: 0; }
.form-field legend { margin-bottom: var(--space-3); }
.form-field input, .form-field textarea, .form-field select {
  font-family: var(--font-body); font-size: 1rem;
  padding: var(--space-4);
  border: 0; border-radius: var(--radius-md);
  background: var(--color-paper); color: var(--color-ink-deep);
  box-shadow: inset 0 0 0 1.5px var(--color-field-border);
  transition: box-shadow 0.4s var(--ease-out), background-color 0.4s var(--ease-out);
}
.form-field textarea { resize: vertical; min-height: 160px; }
.form-field input:focus, .form-field textarea:focus, .form-field select:focus {
  outline: none; background: var(--color-surface);
  box-shadow: inset 0 0 0 2px var(--color-ink-deep), 0 0 0 5px rgba(255, 222, 89, 0.6);
}
.form-honeypot { position: absolute; left: -9999px; }
.form-hint { font-size: 0.86rem; color: var(--color-ink-soft); margin: 0; }
.form-required { color: var(--color-terracotta); }
.form-error { margin: 0; font-size: 0.88rem; font-weight: 700; color: var(--color-terracotta); }
.form-error::before { content: "! "; font-weight: 800; }
.form-field.has-error input, .form-field.has-error textarea { box-shadow: inset 0 0 0 2px var(--color-terracotta); }

/* Radio chips for enquiry types: the real radio stays focusable, visually hidden. */
.choice-chips { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.form-field .choice-chip { position: relative; text-transform: none; letter-spacing: 0; color: var(--color-ink-deep); }
.choice-chip input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.choice-chip span {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 var(--space-4);
  border-radius: var(--radius-full); font-weight: 700; font-size: 0.92rem;
  background: var(--color-paper); box-shadow: inset 0 0 0 1.5px var(--color-field-border);
  transition: background-color 0.3s var(--ease-out), color 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
}
.choice-chip input:checked + span { background: var(--color-ink-deep); color: var(--color-on-dark); box-shadow: none; }
.choice-chip input:focus-visible + span { box-shadow: 0 0 0 2px var(--color-surface), 0 0 0 4px var(--color-clay); }

/* --- Alerts --- */
.alert { padding: var(--space-4) var(--space-5); border-radius: var(--radius-md); margin-bottom: var(--space-5); }
.alert--success { background: color-mix(in oklab, var(--color-sage) 35%, white); }
.alert--error { background: color-mix(in oklab, var(--color-terracotta) 12%, white); color: var(--color-terracotta); }
.alert ul { margin: var(--space-2) 0 0; padding-left: var(--space-5); }

.doodle { color: var(--color-ink); }

/* --- Marquee band: moves only as the page scrolls (ScrollTrigger in main.js). --- */
.marquee {
  overflow: hidden;
  background: var(--color-espresso);
  color: var(--color-on-dark);
  padding: var(--space-5) 0;
}
.marquee__track { display: flex; width: max-content; will-change: transform; }
.marquee__group { display: flex; align-items: center; flex-shrink: 0; }
.marquee__item {
  font-family: var(--font-display); text-transform: uppercase;
  font-size: clamp(2rem, 4.6vw, 3.6rem); line-height: 1.05;
  padding: 0 var(--space-5); white-space: nowrap;
}
.marquee__item--accent { font-family: var(--font-accent); text-transform: none; font-size: clamp(2.2rem, 5vw, 4rem); color: var(--color-ochre); }
.marquee__item--outline { color: transparent; -webkit-text-stroke: 1.2px var(--color-on-dark-muted); }
.marquee .doodle--star { width: 26px; height: 26px; color: var(--color-clay); flex-shrink: 0; }

/* --- Empty state --- */
.empty-state { display: flex; flex-direction: column; align-items: center; gap: var(--space-5); text-align: center; padding: var(--space-8) var(--space-4); }
.empty-state__caption { font-size: 1.6rem; margin: 0; color: var(--color-ink); max-width: 26ch; }

/* --- Pagination --- */
.pagination { display: flex; gap: var(--space-2); justify-content: center; margin-top: var(--space-9); flex-wrap: wrap; }
.pagination__link {
  min-width: 48px; height: 48px; padding: 0 var(--space-3);
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-full); font-weight: 700;
  box-shadow: inset 0 0 0 1.5px var(--color-field-border);
  transition: background-color 0.4s var(--ease-out);
}
.pagination__link:hover { background: var(--color-surface); }
.pagination__link.is-active { background: var(--color-ink-deep); color: var(--color-on-dark); box-shadow: none; }

/* --- Video embeds (lite facade for YouTube, lazy iframes for TikTok/Instagram) --- */
.video-embed { position: relative; width: 100%; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--radius-xl); background: var(--color-espresso); }
.video-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-embed--tiktok { max-width: 340px; aspect-ratio: 9 / 17.5; margin: 0 auto; }
.video-embed--instagram { max-width: 420px; aspect-ratio: 4 / 6.2; margin: 0 auto; background: var(--color-surface); }
.video-facade { position: absolute; inset: 0; display: block; cursor: pointer; }
/* In a 16:9 box, object-fit: cover trims exactly the letterbox bars of a 4:3 YouTube thumbnail. */
.video-facade img { width: 100%; height: 100%; object-fit: cover; }
.video-facade__play {
  position: absolute; left: 50%; top: 50%; translate: -50% -50%;
  display: inline-flex; align-items: center; gap: var(--space-3);
  padding: 10px 22px 10px 10px; border-radius: var(--radius-full);
  background: var(--color-paper); color: var(--color-ink-deep); font-weight: 800;
  box-shadow: var(--shadow-float);
  transition: transform 0.5s var(--ease-spring);
}
.video-facade__play::before {
  content: ""; width: 48px; height: 48px; border-radius: 50%;
  background: var(--color-clay) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 7l9 5-9 5z' fill='%231F1612'/%3E%3C/svg%3E") center / 26px no-repeat;
}
.video-facade:hover .video-facade__play, .video-facade:focus-visible .video-facade__play { transform: scale(1.06); }

/* --- Intro: "life plan buffering" counter, first home visit per session only. The
   inline script in header.php adds html.show-intro before first paint. --- */
.intro { display: none; }
.show-intro .intro {
  position: fixed; inset: 0; z-index: 200;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: calc(var(--gutter) + 8px) var(--gutter);
  background: var(--color-espresso); color: var(--color-on-dark);
  cursor: pointer;
}
.intro__top { display: flex; justify-content: space-between; align-items: center; gap: var(--space-4); }
.intro__label { margin: 0; font-size: 0.78rem; font-weight: 800; letter-spacing: 0.22em; text-transform: uppercase; color: var(--color-on-dark-muted); }
.intro__skip { font-size: 0.85rem; color: var(--color-on-dark-muted); }
.intro__middle { display: flex; align-items: flex-end; justify-content: space-between; gap: var(--space-5); flex-wrap: wrap; }
.intro__count { margin: 0; font-family: var(--font-display); font-size: clamp(7rem, 26vw, 22rem); line-height: 0.82; font-variant-numeric: tabular-nums; }
.intro__count small { font-size: 0.22em; color: var(--color-on-dark-muted); margin-left: 0.2em; }
/* Anton's digits differ in width, so a fixed box stops each tick nudging the "/100" (layout shift). */
.intro__count [data-intro-count] { display: inline-block; width: 3ch; text-align: right; }
/* One line at a fixed minimum width: the changing status text must never
   re-wrap the row (that counted as layout shift). Stacked under the count on phones. */
.intro__status { margin: 0 0 var(--space-4); font-size: clamp(2rem, 4.5vw, 3.4rem); color: var(--color-ochre); white-space: nowrap; min-width: 10em; }
@media (max-width: 760px) { .intro__middle { flex-direction: column; align-items: flex-start; } }
.intro__bar { height: 3px; border-radius: 3px; background: var(--color-line-dark); overflow: hidden; }
.intro__bar span { display: block; height: 100%; background: var(--color-ochre); transform: scaleX(0); transform-origin: left; }
.show-intro body { overflow: hidden; }

/* --- Floating "work with Kim" box (desktop), hidden near the hero and footer. --- */
.float-box {
  position: fixed; right: var(--space-5); bottom: var(--space-5); z-index: 50;
  display: flex; align-items: center; gap: var(--space-4);
  padding: 10px 10px 10px 20px;
  border-radius: 22px;
  background: var(--color-espresso); color: var(--color-on-dark);
  box-shadow: 0 0 0 1px var(--color-line-dark), var(--shadow-float);
  transform-origin: bottom right;
  transition: transform 0.6s var(--ease-spring), opacity 0.4s var(--ease-out), visibility 0s linear 0s;
}
.float-box.is-hidden { opacity: 0; transform: scale(0.6) translateY(16px); visibility: hidden; pointer-events: none; transition: transform 0.4s var(--ease-out), opacity 0.3s var(--ease-out), visibility 0s linear 0.4s; }
.float-box__text { margin: 0; display: flex; flex-direction: column; line-height: 1.2; }
.float-box__text span { font-size: 0.74rem; color: var(--color-on-dark-muted); }
.float-box__text strong { font-size: 0.98rem; }
.float-box__close {
  width: 32px; height: 32px; border: 0; border-radius: 50%; cursor: pointer;
  background: transparent; color: var(--color-on-dark-muted);
  display: inline-flex; align-items: center; justify-content: center; margin-left: -8px;
}
.float-box__close:hover { color: var(--color-on-dark); background: rgba(247, 241, 230, 0.08); }
.float-box__close svg { width: 14px; height: 14px; }
@media (max-width: 760px) { .float-box { display: none; } }

/* --- Star field: rows of sparkles that turn towards the cursor (main.js). --- */
.star-field {
  display: grid; grid-template-columns: repeat(24, 1fr);
  margin: var(--space-8) 0 0;
  color: rgba(247, 241, 230, 0.32);
}
.star-field__item { aspect-ratio: 1; display: flex; align-items: center; justify-content: center; transition: transform 0.35s var(--ease-out), color 0.35s var(--ease-out); }
.star-field__item svg { width: 34%; height: 34%; }
.star-field__item.is-near { color: var(--color-ochre); }
@media (max-width: 760px) {
  .star-field { grid-template-columns: repeat(12, 1fr); }
  .star-field__item:nth-child(n+37) { display: none; }
}

/* --- Footer --- */
.site-footer {
  position: relative;
  margin: var(--space-8) clamp(8px, 1.2vw, 16px) 0;
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  background: var(--color-espresso);
  color: var(--color-on-dark);
  padding-top: var(--space-10);
  overflow: hidden;
}
.site-footer__top { display: grid; grid-template-columns: 1.8fr 1fr 1fr 1fr; gap: var(--space-7); }
.site-footer__title { font-size: clamp(2.4rem, 5vw, 4.25rem); max-width: 14ch; margin-bottom: var(--space-4); }
.site-footer__note { margin: 0 0 var(--space-6); font-size: 1.7rem; color: var(--color-ochre); }
.site-footer__label { font-size: 0.72rem; font-weight: 800; letter-spacing: 0.18em; text-transform: uppercase; color: var(--color-on-dark-muted); margin-bottom: var(--space-3); }
.site-footer__nav { display: flex; flex-direction: column; }
.site-footer__nav a { font-size: 1.02rem; width: fit-content; min-height: 44px; display: flex; align-items: center; transition: color 0.4s var(--ease-out); }
.site-footer__nav a:hover { color: var(--color-ochre); }

/* Social logos (icon_social()), in each platform's own colours. */
.social-icon { width: 24px; height: 24px; flex-shrink: 0; transition: transform 0.5s var(--ease-spring); }
.site-footer__nav .site-footer__social { gap: var(--space-3); }
.site-footer__social:hover .social-icon, .btn:hover .social-icon { transform: scale(1.12) rotate(-6deg); }
.btn .social-icon { width: 22px; height: 22px; margin-right: -4px; }
.site-footer__wordmark {
  margin: var(--space-4) 0 0;
  display: flex; flex-wrap: nowrap; justify-content: space-between;
  font-family: var(--font-display); text-transform: uppercase;
  font-size: clamp(2.4rem, 10.2vw, 10.5rem); line-height: 0.86;
  white-space: nowrap; overflow: hidden;
  color: var(--color-ochre);
}
.site-footer__wordmark span { display: inline-block; }
.site-footer__wordmark .is-alt { color: var(--color-clay); }
.site-footer__meta {
  display: flex; justify-content: space-between; gap: var(--space-4); flex-wrap: wrap;
  padding: var(--space-6) 0; margin-top: var(--space-6);
  border-top: 1px solid var(--color-line-dark);
  font-size: 0.86rem; color: var(--color-on-dark-muted);
}
.site-footer__meta a { min-height: 44px; min-width: 44px; display: inline-flex; align-items: center; justify-content: flex-end; margin: -11px 0; }
.site-footer__meta a:hover { color: var(--color-on-dark); }
.site-footer__links { display: inline-flex; gap: var(--space-5); }
@media (max-width: 960px) {
  .site-footer__top { grid-template-columns: 1fr 1fr; }
  .site-footer__cta { grid-column: 1 / -1; }
}
