/* =====================================================================
   Entwurf 2 — "Im offenen Wasser"
   Design-Tokens, Reset, Basis-Typografie & Layout-Helfer.
   Portiert aus mockups/entwurf-2/assets/css/site.css (Abschnitte 1-4).
   ===================================================================== */

/* ---------- 1 · Tokens, Reset & Basis-Stil ---------- */
.entwurf2 {
  /* Wasser-Skala (heller, freundlicher als V3-Navy) */
  --water-50: #eef6fb;
  --water-100: #d4e7f1;
  --water-200: #b8d9ec;
  --water-300: #88bdde;
  --water-400: #58a3cf;
  --water: #2e7ebd; /* Primary */
  --water-600: #1f6aa3;
  --water-700: #155084;
  --water-900: #0a2c4e;

  /* Konstanten aus design-uebersicht.md */
  --navy: #232845;
  --red: #ff2640;
  --red-deep: #d61f34;
  --ink: #1a2236;
  --muted: #5e6878;
  --paper: #fff;
  --paper-2: #f6fafd;
  --line: #d8e3eb;
  --foam: #f0f7fb;

  /* Schriften — Outfit (Display) + DM Sans (Body). */
  --f-display: 'Outfit', system-ui, -apple-system, sans-serif;
  --f-body: 'DM Sans', system-ui, -apple-system, sans-serif;

  /* Raster */
  --max: 1240px;
  --pad-x: clamp(1.25rem, 4vw, 3rem);
  --pad-y: clamp(2rem, 4vw, 3.5rem);
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);
  --shadow-card: 0 1px 3px rgb(35 40 69 / 0.04), 0 10px 30px -12px rgb(46 126 189 / 0.18);
  --shadow-hov: 0 2px 6px rgb(35 40 69 / 0.06), 0 30px 60px -16px rgb(46 126 189 / 0.32);

  font-family: var(--f-body);
  font-weight: 400;
  font-size: clamp(15.5px, 0.25vw + 14.5px, 17px);
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

/* Globalen Theme-Header/-Footer auf dem Entwurf-2-Template ausblenden —
   das Template bringt eigene Nav + Footer mit (analog .praesentation-only).
   Greift per ID auf den globalen Header/Footer aus header.php/footer.php. */
body.entwurf2-only #site-header,
body.entwurf2-only #site-footer {
  display: none;
}

/* ---------- 2 · Reset / Base ---------- */
.entwurf2 *,
.entwurf2 *::before,
.entwurf2 *::after {
  box-sizing: border-box;
}

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

.entwurf2 a {
  color: inherit;
  text-decoration: none;
}

.entwurf2 button {
  font: inherit;
  cursor: pointer;
}

.entwurf2 ::selection {
  background: var(--water);
  color: #fff;
}

/* ---------- 3 · Typografie ---------- */
.entwurf2 h1,
.entwurf2 h2,
.entwurf2 h3,
.entwurf2 h4 {
  font-family: var(--f-display);
  font-weight: 700;
  color: var(--navy);
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 0;
}

.entwurf2 h1 {
  font-size: clamp(2.4rem, 5vw + 0.4rem, 4rem);
  font-weight: 800;
}

.entwurf2 h2 {
  font-size: clamp(1.9rem, 2.8vw + 0.4rem, 2.8rem);
}

.entwurf2 h3 {
  font-size: clamp(1.2rem, 1vw + 0.4rem, 1.5rem);
}

.entwurf2 p {
  margin: 0 0 1rem;
}

.entwurf2 .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--f-body);
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--water);
}

.entwurf2 .eyebrow::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  background: var(--water);
  border-radius: 50%;
}

.entwurf2 .eyebrow--inv {
  color: rgb(255 255 255 / 0.92);
}

.entwurf2 .eyebrow--inv::before {
  background: var(--red);
}

.entwurf2 .lead {
  font-family: var(--f-body);
  font-size: clamp(1.05rem, 0.7vw + 0.8rem, 1.25rem);
  line-height: 1.5;
  color: var(--muted);
}

/* ---------- 4 · Layout ---------- */
.entwurf2 .wrap {
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--pad-x);
}

.entwurf2 .section {
  padding-block: var(--pad-y);
  position: relative;
}

.entwurf2 .section--water {
  background: var(--water-50);
}

.entwurf2 .section--deep {
  background: linear-gradient(180deg, var(--water-700) 0%, var(--water-900) 100%);
  color: #fff;
}

.entwurf2 .section--deep h1,
.entwurf2 .section--deep h2,
.entwurf2 .section--deep h3 {
  color: #fff;
}

.entwurf2 .section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-bottom: clamp(2rem, 4vw, 3rem);
}

.entwurf2 .section-head h2 {
  max-width: 18ch;
  margin-top: 0.6rem;
}

.entwurf2 .section-head .lead {
  max-width: 50ch;
  margin: 0.25rem 0 0;
}

/* ---------- A11y ---------- */
.entwurf2 :focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
}

.entwurf2 .skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--navy);
  color: #fff;
  padding: 0.75rem 1rem;
  font-weight: 600;
  z-index: 999;
}

.entwurf2 .skip:focus {
  left: 1rem;
  top: 1rem;
}

/* ---------- Reveal-Animationen ---------- */
.entwurf2 .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity 0.9s var(--ease),
    transform 0.9s var(--ease);
}

.entwurf2 .reveal.is-in {
  opacity: 1;
  transform: none;
}

.entwurf2 .reveal--stagger > * {
  opacity: 0;
  transform: translateY(14px);
  transition:
    opacity 0.8s var(--ease),
    transform 0.8s var(--ease);
}

.entwurf2 .reveal--stagger.is-in > * {
  opacity: 1;
  transform: none;
}

.entwurf2 .reveal--stagger.is-in > *:nth-child(2) {
  transition-delay: 0.1s;
}

.entwurf2 .reveal--stagger.is-in > *:nth-child(3) {
  transition-delay: 0.2s;
}

.entwurf2 .reveal--stagger.is-in > *:nth-child(4) {
  transition-delay: 0.3s;
}

/* ---------- Schwebender Zurück-Button (Demo-Meta-Navigation) ---------- */
.demo-back {
  position: fixed;
  top: 1rem;
  left: 1rem;
  z-index: 999;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #fff;
  color: #232845;
  box-shadow:
    0 2px 8px rgb(10 30 60 / 0.18),
    0 8px 24px rgb(10 30 60 / 0.16);
  text-decoration: none;
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease;
}

.demo-back:hover {
  transform: translateY(-2px);
  box-shadow:
    0 4px 12px rgb(10 30 60 / 0.22),
    0 12px 32px rgb(10 30 60 / 0.2);
}

.demo-back:active {
  transform: translateY(0);
}

.demo-back:focus-visible {
  outline: 3px solid #ff2640;
  outline-offset: 3px;
}

/* WP-Adminbar überlagert den Button, wenn ein eingeloggter Nutzer die
   Seite ansieht — dann nach unten unter die Leiste schieben
   (32 px Desktop, 46 px auf schmalen Viewports). */
.admin-bar .demo-back {
  top: calc(1rem + 32px);
}

@media (width <= 782px) {
  .admin-bar .demo-back {
    top: calc(1rem + 46px);
  }
}

/* ---------- Reduced Motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .entwurf2 *,
  .entwurf2 *::before,
  .entwurf2 *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .entwurf2 .reveal,
  .entwurf2 .reveal--stagger > * {
    opacity: 1;
    transform: none;
  }
}
