/* ============================================================================
   bombina — Base Styles
   Reset minimal + Typografie-Defaults nach Prototyp C. Setzt voraus, dass
   tokens.css vorher geladen wurde und die Schriften (Outfit, Cormorant
   Garamond, JetBrains Mono) per <link> bereitstehen.
   ============================================================================ */

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

* {
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-body);
  line-height: var(--leading-body);
  color: var(--text1);
  background: var(--background);
  overflow-x: hidden;
  transition:
    background var(--duration-slow) var(--ease-soft),
    color      var(--duration-slow) var(--ease-soft);
}

img,
svg,
video {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: var(--text1);
  text-decoration: none;
  transition: color var(--duration-fast) var(--ease-out);
}
a:hover { color: var(--accent-dark); }

::selection {
  background: var(--accent-subtle);
  color: var(--text1);
}

/* Focus — Amber-Ring (Prototyp C) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: var(--radius-focus);
}

/* ── HEADINGS — Cormorant Garamond, weight 500 ── */
h1, h2, h3, h4, h5, h6,
.display {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: var(--tracking-tight);
  color: var(--text1);
}

.display {
  font-size: var(--text-display);
  line-height: var(--leading-display);
}
h1 {
  font-size: var(--text-h1);
  line-height: var(--leading-h1);
}
h2 {
  font-size: var(--text-h2);
  line-height: var(--leading-h2);
}
h3 {
  font-size: var(--text-h3);
  line-height: var(--leading-h3);
  letter-spacing: 0;
}

p {
  color: var(--text2);
  margin-bottom: 1em;
}
p:last-child {
  margin-bottom: 0;
}

/* ── UTILITIES ── */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-body);
  font-size: var(--text-eyebrow);
  line-height: var(--leading-label);
  font-weight: 600;
  letter-spacing: var(--tracking-loose);
  text-transform: uppercase;
  color: var(--accent);
}
.eyebrow::before {
  content: "";
  display: block;
  width: 18px;
  height: 1px;
  background: currentColor;
  flex-shrink: 0;
}
.eyebrow.moss { color: var(--moss); }

.lede {
  font-size: var(--text-lede);
  line-height: 1.62;
  color: var(--text1);
  max-width: 54ch;
}

/* Cormorant-Italic als Akzent (ersetzt die frühere Caveat-Schreibschrift) */
.script {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.4rem;
  font-weight: 400;
  letter-spacing: 0;
  color: var(--text2);
}

.mono {
  font-family: var(--font-mono);
  letter-spacing: 0.02em;
}

.text-2 { color: var(--text2); }
.text-3 { color: var(--text3); }
.muted  { color: var(--text3); }

.body-sm  { font-size: var(--text-body-sm); line-height: var(--leading-body-sm); }
.caption  { font-size: var(--text-caption); line-height: var(--leading-caption); color: var(--text3); }

/* ── LAYOUT ── */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}
.container-narrow {
  max-width: var(--container-narrow);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

.section {
  padding: var(--section-pad) 0;
}
.section-sm,
.section.tight {
  padding: var(--section-pad-tight) 0;
}
.section-alt,
.section.soft {
  background: var(--surface2);
}

/* ── ACCESSIBILITY ── */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--text1);
  color: var(--surface1);
  padding: 10px 14px;
  z-index: 300;
  border-radius: var(--radius-pill);
}
.skip-link:focus {
  left: 12px;
  top: 12px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ── REDUCED MOTION ── */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
