/*
  essenz-it · main.css
  ─────────────────────────────────────────────────────────────
  Seitenübergreifende Basis-Styles.
  Wird von ALLEN Seiten eingebunden.

  Enthält:
    1. Design Tokens (Custom Properties)
    2. Reset & Base
    3. Layout-Utilities (.wrap, .sec, .sec-*)
    4. Typografie-Utilities (.lbl, .h2, .lead)
    5. Buttons (.btn-h, .btn-ghost, .btn-cta-*)
    6. Navigation (.nav)
    7. Footer (.footer)
    8. Scroll-Animationen (.up)
    9. Responsive Breakpoints (globale Regeln)

  Seiten-spezifische Styles → jeweilige CSS-Datei:
    home.css      → Startseite
    kontakt.css   → Kontaktseite
    impressum.css → Impressum / Datenschutz
  ─────────────────────────────────────────────────────────────
*/

/* ═══════════════════════════════════════
   1. DESIGN TOKENS
   ═══════════════════════════════════════ */
:root {
  /* Markenfarbe — dekorativ (Hintergründe, Linien, Punkte, Flächen) */
  --m:       #E6017E;
  /* Markenfarbe — Text & Buttons (4.96:1 auf weiß, BFSG-konform) */
  --m-text:  #D9007A;
  --m-dk:    #C00068;
  /* Hover: dunkel statt heller — #FF2E90 hatte nur 3.47:1 auf weiß */
  --m-lt:    #D9007A;
  --m-tint:  rgba(230,1,126,.07);
  --m-ring:  rgba(230,1,126,.20);

  /* Neutraltöne — feste Hex-Werte (BFSG-konform, keine rgba für Text)
     --i70: #595856 → 7.11:1 auf weiß, 6.58:1 auf cream, 6.03:1 auf stone
     --i50: #767472 → 4.65:1 auf weiß, 4.31:1 auf cream (AA)           */
  --ink:     #0F0F0E;
  --i70:     #595856;
  --i50:     #767472;
  --i35:     #767472;   /* Alias — BFSG-Upgrade von rgba(.35) */
  --i12:     rgba(15,15,14,.12);
  --i06:     rgba(15,15,14,.06);

  /* Hintergründe */
  --white:   #ffffff;
  --cream:   #F7F6F4;
  --stone:   #EEECEA;
  --nav-bg:  #0F0F0E;

  /* Typografie */
  --fh: 'Barlow Semi Condensed', sans-serif;
  --fb: 'Barlow', sans-serif;

  /* Layout */
  --r:   clamp(1.5rem, 4vw, 4.5rem);
  --mw:  1240px;

  /* Easing */
  --ease: cubic-bezier(.16,1,.3,1);
}

/* ═══════════════════════════════════════
   2. RESET & BASE
   ═══════════════════════════════════════ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--fb);
  font-size: 1rem; /* Basis: 16px — Mindestgröße für alle Lesetexte */
  color: var(--ink);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  padding-top: 60px; /* Höhe der fixen Nav */
}

/* ═══════════════════════════════════════
   3. LAYOUT-UTILITIES
   ═══════════════════════════════════════ */
.wrap {
  max-width: var(--mw);
  margin: 0 auto;
  padding: 0 var(--r);
}

/* Visuell versteckt, aber für Screenreader & Crawler sichtbar */
.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;
}

/* Scroll-Offset für fixe Nav bei Anchor-Links */
section[id],
div[id] {
  scroll-margin-top: 60px;
}

/* Lbl-Linie: startet unsichtbar, wächst per .in-Klasse */
.lbl::before {
  transition: transform .5s var(--ease);
  transform-origin: left;
  transform: scaleX(0);
}
.lbl.in::before {
  transform: scaleX(1);
}

.sec         { padding: clamp(4rem, 8vw, 7rem) 0; }
.sec-sm      { padding: clamp(2.5rem, 5vw, 4rem) 0; }
.sec-dark    { background: var(--ink); }
.sec-cream   { background: var(--cream); }
.sec-stone   { background: var(--stone); }

/* ═══════════════════════════════════════
   4. TYPOGRAFIE-UTILITIES
   ═══════════════════════════════════════ */

/* Section-Eyebrow: "Das Problem", "Die Lösung" etc. */
.lbl {
  display: inline-flex;
  align-items: center;
  gap: .6em;
  font-family: var(--fb);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: .17em;
  text-transform: uppercase;
  color: var(--m-text);
  margin-bottom: 1.1rem;
}
.lbl::before {
  content: '';
  width: 16px;
  height: 1.5px;
  background: var(--m);
  flex-shrink: 0;
}

/* Section-Headline */
.h2 {
  font-family: var(--fh);
  font-size: clamp(1.75rem, 3.2vw, 2.75rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -.005em;
  color: var(--ink);
}
.h2 .dim    { color: var(--i35); font-weight: 400; }
.h2-w       { color: var(--white); }
.h2-w .dim  { color: rgba(255,255,255,.45); }

/* Einleitungstext / Lead */
.lead {
  font-family: var(--fb);
  font-size: clamp(1rem, 1.2vw, 1.05rem);
  font-weight: 300;
  color: var(--i70);
  line-height: 1.8;
  max-width: 52ch;
}
.lead strong { font-weight: 600; color: var(--ink); }

/* ═══════════════════════════════════════
   5. BUTTONS
   ═══════════════════════════════════════ */

/* Primär-Button (auf dunklem Hintergrund) */
.btn-h {
  display: inline-flex;
  align-items: center;
  gap: .5em;
  padding: .85em 1.75em;
  background: var(--m-text);
  color: var(--white);
  font-family: var(--fb);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: .02em;
  text-decoration: none;
  border-radius: 2px;
  transition: background .15s, transform .1s;
  white-space: nowrap;
}
.btn-h:hover  { background: var(--m-dk); }
.btn-h:active { transform: scale(.98); }
.btn-h svg    { width: 14px; height: 14px; flex-shrink: 0; transition: transform .15s; }
.btn-h:hover svg { transform: translateX(3px); }

/* Ghost-Link (auf dunklem Hintergrund) */
.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: .4em;
  font-family: var(--fb);
  font-size: 1rem;
  font-weight: 400;
  color: rgba(255,255,255,.60);
  text-decoration: none;
  transition: color .15s;
}
.btn-ghost:hover  { color: rgba(255,255,255,.85); }
.btn-ghost svg    { width: 13px; height: 13px; }

/* CTA-Buttons (im Magenta-Banner) */
.btn-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .5em;
  padding: .95em 1.75em;
  border-radius: 2px;
  font-family: var(--fb);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: .02em;
  text-decoration: none;
  transition: background .15s, border-color .15s, color .15s, transform .1s;
}
.btn-cta:active  { transform: scale(.98); }

.btn-cta-wh          { background: var(--white); color: var(--m); }
.btn-cta-wh:hover    { background: rgba(255,255,255,.9); }

.btn-cta-ol          { background: transparent; color: rgba(255,255,255,.8); border: 1.5px solid rgba(255,255,255,.3); }
.btn-cta-ol:hover    { border-color: rgba(255,255,255,.7); color: var(--white); }

/* ═══════════════════════════════════════
   6. NAVIGATION
   ═══════════════════════════════════════ */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 200;
  background: var(--nav-bg);
  border-bottom: 1px solid rgba(255,255,255,.06);
  transition: border-bottom-color .3s var(--ease), box-shadow .3s var(--ease);
}
.nav--scrolled {
  border-bottom-color: rgba(255,255,255,.14);
  box-shadow: 0 1px 28px rgba(0,0,0,.4);
}
.nav-i {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
  gap: 2rem;
  transition: height .3s var(--ease);
}
.nav--scrolled .nav-i {
  height: 52px;
}
.nav-logo {
  display: flex;
  align-items: center;
  height: 22px;
  flex-shrink: 0;
}
.nav-logo img {
  height: 100%;
  width: auto;
  display: block;
}
.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
}
.nav-links a {
  font-family: var(--fb);
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: .02em;
  color: rgba(255,255,255,.5);
  text-decoration: none;
  transition: color .15s;
}
.nav-links a:hover       { color: rgba(255,255,255,.95); }
.nav-links a.active      { color: var(--white); position: relative; }
.nav-links a.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--m);
  border-radius: 2px;
}

.nav-btn {
  display: inline-flex;
  align-items: center;
  gap: .4em;
  padding: .5em 1.2em;
  background: var(--m);
  color: var(--white);
  font-family: var(--fb);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: .03em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 2px;
  transition: background .15s;
  white-space: nowrap;
}
.nav-btn:hover   { background: var(--m-dk); }
.nav-btn svg     { width: 12px; height: 12px; transition: transform .15s; }
.nav-btn:hover svg { transform: translateX(3px); }

/* ═══════════════════════════════════════
   7. FOOTER
   ═══════════════════════════════════════ */
.footer {
  background: #0C0C0B;
  padding: 4rem 0 2rem;
}
.footer-top {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.f-logo {
  height: 20px;
  margin-bottom: .875rem;
}
.f-logo img {
  height: 100%;
  width: auto;
  display: block;
}
.f-tag {
  font-family: var(--fb);
  font-size: 1rem;
  color: rgba(255,255,255,.60);
  line-height: 1.7;
  max-width: 22ch;
}
.f-col-h {
  font-family: var(--fb);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: rgba(255,255,255,.60);
  margin-bottom: 1.2rem;
}
.f-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: .6rem;
}
.f-links a {
  font-family: var(--fb);
  font-size: 1rem;
  color: rgba(255,255,255,.65);
  text-decoration: none;
  transition: color .15s;
}
.f-links a:hover { color: var(--white); }

.f-kv {
  display: flex;
  flex-direction: column;
  gap: .2rem;
  margin-bottom: .8rem;
}
.f-kv-l {
  font-family: var(--fb);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(255,255,255,.55);
}
.f-kv-v {
  font-family: var(--fb);
  font-size: 1rem;
  color: rgba(255,255,255,.65);
  line-height: 1.5;
}
.f-kv-v a             { color: rgba(255,255,255,.65); text-decoration: none; }
.f-kv-v a:hover       { color: var(--white); }

.footer-bot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}
.f-copy {
  font-family: var(--fb);
  font-size: 0.875rem;
  color: rgba(255,255,255,.55);
}
.f-leg {
  list-style: none;
  display: flex;
  gap: 1.5rem;
}
.f-leg a {
  font-family: var(--fb);
  font-size: 1rem;
  color: rgba(255,255,255,.55);
  text-decoration: none;
  transition: color .15s;
}
.f-leg a:hover { color: rgba(255,255,255,.6); }

/* ═══════════════════════════════════════
   8. SCROLL-ANIMATIONEN
   ═══════════════════════════════════════ */
@media (prefers-reduced-motion: no-preference) {
  .up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity .7s var(--ease), transform .7s var(--ease);
  }
  .up.in { opacity: 1; transform: none; }
  .up:nth-child(2) { transition-delay: .1s; }
  .up:nth-child(3) { transition-delay: .2s; }
  .up:nth-child(4) { transition-delay: .3s; }
}

/* ═══════════════════════════════════════
   9. RESPONSIVE — globale Regeln
   Seiten-spezifische Breakpoints in home.css etc.
   ═══════════════════════════════════════ */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .footer-top { grid-template-columns: 1fr; }
}

@media (max-width: 1024px) {
  .footer-top { grid-template-columns: 1fr 1fr; gap: 2.5rem; }
}
