/* ============================================================
   BASE — Reset, Typografie, Korn-Overlay, Layout-Primitive
   ============================================================ */

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  font-size: var(--t-body);
  font-weight: var(--w-normal);
  line-height: var(--lh-body);
  letter-spacing: var(--ls-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, svg, video { display: block; max-width: 100%; }
button, input, textarea { font: inherit; letter-spacing: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4, h5, p, figure, blockquote { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }

/* Markierung in Bernstein statt Tinte — der einzige Ort, an dem die
   warme Hero-Farbe auf der ganzen Seite auftauchen kann. 6,9:1. */
::selection { background: var(--c-amber); color: var(--c-ink); }

/* ---------- KORN ---------------------------------------------------
   Das Original legt eine 161px gekachelte Noise-PNG mit opacity .04
   über die gesamte Seite. Hier per feTurbulence erzeugt — identische
   Wirkung, keine externe Datei. */
.grain {
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  opacity: 0.04;
  background-repeat: repeat;
  background-size: 161px 161px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='161' height='161'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.6' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='161' height='161' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- TYPOGRAFIE-KLASSEN ------------------------------------- */

.t-h1 {
  font-size: var(--t-h1);
  font-weight: var(--w-semi);
  line-height: var(--lh-tight);
  letter-spacing: var(--ls-display);
}


.t-h3 {
  font-size: var(--t-h3);
  font-weight: var(--w-medium);
  line-height: var(--lh-snug);
  letter-spacing: var(--ls-display);
}

.t-h4 {
  font-size: var(--t-h4);
  font-weight: var(--w-medium);
  line-height: var(--lh-snug);
  letter-spacing: normal;
}


.t-body {
  font-size: var(--t-body);
  line-height: var(--lh-body);
  letter-spacing: var(--ls-body);
}

.t-small {
  font-size: var(--t-small);
  line-height: var(--lh-body);
  letter-spacing: var(--ls-body);   /* muss gesetzt sein: letter-spacing
     vererbt sich als berechnete Länge, nicht als em-Wert */
}

/* ---------- LAYOUT-PRIMITIVE --------------------------------------- */
.container {
  width: min(var(--container), 100% - var(--gutter) * 2);
  margin-inline: auto;
}

/* Framer setzt zwischen allen Bändern einen 10px-Flexabstand.
   Ohne den verschiebt sich jede Sektion darunter. */
main {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.section {
  padding-top: var(--section-pt);
}

/* Services folgt direkt auf die gepinnte Scrub-Sektion und hat
   deshalb als einzige keinen eigenen Kopfabstand. */
.section--flush { padding-top: 0; }

.section__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: var(--section-gap);
}

/* Wie im Original brechen lange Sektionstitel auf zwei Zeilen um,
   statt die Zeile bis zum Button auszureizen. */
.section__head > :first-child { max-width: 480px; }

@media (max-width: 680px) {
  .section__head { flex-direction: column; align-items: flex-start; }
}
