/* ─────────────────────────────────────────────────────────────
   Sambusa City — base reset + typography
   ───────────────────────────────────────────────────────────── */

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

* { margin: 0; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  background: var(--cream);
  color: var(--coffee);
  font-family: var(--font-body);
  font-size: var(--fs-base);
  font-weight: 400;
  line-height: var(--lh-body);
  font-feature-settings: 'kern' 1, 'liga' 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  overflow-x: clip;
}

img, picture, video, canvas, svg { display: block; max-width: 100%; }

/* Picture wrappers must fill their aspect-ratio containers so the inner
   <img> can object-fit:cover into the full area. Without this, picture
   defaults to content-sized height and leaves dead space inside the
   media box. */
.card__media > picture,
.hero__media > picture,
.intro__photo > picture,
.story__photo > picture,
.split__media > picture,
.about__photo > picture,
[class$="__media"] > picture,
[class$="__photo"] > picture {
  width: 100%;
  height: 100%;
}

button, input, textarea, select {
  font: inherit;
  color: inherit;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--dur-micro) var(--ease-out);
}

/* ─ Typography ─────────────────────────────────────────────── */

h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: var(--lh-heading);
  letter-spacing: -0.005em;
  text-wrap: balance;
}

h1 {
  font-size: clamp(var(--fs-4xl), 7vw, var(--fs-6xl));
  line-height: var(--lh-display);
  font-variation-settings: 'opsz' 72;
  letter-spacing: -0.015em;
}

h2 {
  font-size: clamp(var(--fs-2xl), 4.5vw, var(--fs-3xl));
  font-variation-settings: 'opsz' 48;
}

h3 {
  font-size: var(--fs-xl);
  line-height: var(--lh-h3);
  font-variation-settings: 'opsz' 32;
}

h4 { font-size: var(--fs-lg); line-height: var(--lh-h3); }
h5 { font-size: var(--fs-md); line-height: 1.3; }

p { max-width: 60ch; }
.lead { font-size: var(--fs-md); max-width: 56ch; }

em { font-style: normal; color: var(--saffron-deep); }

strong { font-weight: 600; }

/* ─ Eyebrows + uppercase labels ──────────────────────────── */

.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--saffron-deep);
}

/* On dark surfaces the eyebrow flips to bright saffron. */
.surface--coffee .eyebrow { color: var(--saffron); }

/* ─ Container ────────────────────────────────────────────── */

.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ─ Section rhythm ───────────────────────────────────────── */

.section {
  padding-block: var(--space-6);
}
@media (max-width: 720px) {
  .section { padding-block: var(--space-5); }
}

.surface--cream   { background: var(--cream); color: var(--coffee); }
.surface--cream-2 { background: var(--cream-2); color: var(--coffee); }
.surface--coffee  { background: var(--coffee); color: var(--cream); }
.surface--coffee  em { color: var(--saffron); }
.surface--coffee  h1, .surface--coffee  h2, .surface--coffee  h3 { color: var(--cream); }

/* ─ Reveal on scroll (motion controller in main.js) ───────── */

.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity var(--dur-large) var(--ease-out),
              transform var(--dur-large) var(--ease-out);
}
.reveal.is-in {
  opacity: 1;
  transform: translateY(0);
}
.reveal--delay-1 { transition-delay: 80ms; }
.reveal--delay-2 { transition-delay: 160ms; }
.reveal--delay-3 { transition-delay: 240ms; }

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

/* ─ Focus visibility ──────────────────────────────────────── */

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

/* ─ Selection ─────────────────────────────────────────────── */

::selection {
  background: var(--saffron);
  color: var(--coffee);
}
