/* css/styles.css
   CultivarKnowledge — Narrative Scroll
   Concept: cinematic ink hero → warm parchment "living journal" → ink closing bookend.
   Petrol (#2F6F73) is the single chromatic accent. Everything else is ink/parchment/neutral. */

:root {
  --ink: #1C1810;
  --ink-deep: #141009;
  /* deepest tone for hero vignette */
  --parchment: #F5F0E8;
  --parchment-shade: #EDE8DF;
  --parchment-edge: #E4DDD0;
  /* card hairline / soft borders */
  --petrol: #2F6F73;
  --petrol-deep: #285F62;
  /* CTA hover */
  --petrol-light: #5AB5BB;
  /* small text on dark only */
  --text: #1C1810;
  --text-muted: #6B6455;
  --text-on-ink: #F5F0E8;
  --text-muted-on-ink: #A89E86;
  --maxw: 840px;
  --space: clamp(3.5rem, 9vw, 7.5rem);

  --font-display: 'Neue Haas Grotesk Text Pro', 'Neue Haas Grotesk', 'Helvetica Neue', Arial, sans-serif;
  --font-body: 'Neue Haas Grotesk Text Pro', 'Neue Haas Grotesk', 'Helvetica Neue', Arial, sans-serif;

  --shadow-card: 0 1px 2px rgba(28, 24, 16, 0.04), 0 8px 24px -16px rgba(28, 24, 16, 0.22);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-optical-sizing: auto;
  color: var(--text);
  background: var(--parchment);
  line-height: 1.65;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ------------------------------------------------------------------
   Paper grain — a faint fractal-noise wash over the whole page,
   warmer/denser on parchment, near-invisible but tactile.
------------------------------------------------------------------ */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.5;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.06'/%3E%3C/svg%3E");
}

/* Keep real content above the grain layer */
body>* {
  position: relative;
  z-index: 2;
}

/* ==================================================================
   HERO / INK BOOKEND
================================================================== */
.site-header {
  position: relative;
  background: var(--ink);
  color: var(--text-on-ink);
  overflow: hidden;
}

/* Cinematic atmosphere: a warm low spotlight + cool depth vignette */
.hero-atmosphere {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(120% 90% at 18% 8%, rgba(47, 111, 115, 0.16) 0%, transparent 46%),
    radial-gradient(140% 120% at 80% 110%, rgba(120, 96, 60, 0.14) 0%, transparent 52%),
    radial-gradient(120% 130% at 50% 0%, var(--ink) 0%, var(--ink-deep) 100%);
}

/* Alpine contour wash — anchored to the top-right corner, behind the text */
.hero-contours {
  position: absolute;
  top: -6%;
  right: -8%;
  width: clamp(280px, 50vw, 620px);
  height: auto;
  opacity: 0.16;
  pointer-events: none;
}

.topbar {
  position: relative;
  z-index: 3;
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 1.75rem 1.5rem 0;
}

.brand {
  display: inline-flex;
  line-height: 0;
}

.brand-logo {
  height: 22px;
  width: auto;
}

/* Knockout so the logo reads on ink */
.site-header .brand-logo,
.closing .footer-logo {
  filter: brightness(0) invert(0.92);
}

.lang-toggle {
  background: transparent;
  color: var(--text-on-ink);
  border: 1px solid rgba(168, 158, 134, 0.5);
  border-radius: 999px;
  padding: 0.4rem 0.95rem;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color .35s var(--ease), border-color .35s var(--ease), background .35s var(--ease);
}

.lang-toggle:hover {
  color: var(--ink);
  background: var(--text-on-ink);
  border-color: var(--text-on-ink);
}

.hero {
  position: relative;
  z-index: 3;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 3rem 1.5rem 4rem;
  min-height: clamp(520px, 75vh, 800px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Category eyebrow — orients referred visitors before the hook */
.hero-eyebrow {
  display: block;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--petrol-light);
  margin: 0 0 1.4rem;
}

.hero-scene {
  color: var(--petrol-light);
  font-family: var(--font-body);
  font-style: italic;
  font-size: clamp(1.02rem, 2.2vw, 1.18rem);
  letter-spacing: 0.01em;
  margin: 0 0 1.15rem;
  max-width: 30em;
}

.hero-headline {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2.4rem, 7vw, 4.2rem);
  line-height: 1.06;
  letter-spacing: -0.018em;
  margin: 0 0 1.6rem;
  text-wrap: balance;
}

.hero-sub {
  color: var(--text-muted-on-ink);
  font-size: clamp(1.08rem, 2.4vw, 1.22rem);
  line-height: 1.6;
  max-width: 33em;
  margin: 0 0 2.75rem;
}

/* ------------------------------------------------------------------
   THE CURTAIN — the signature ink → parchment transition.
   A soft torn paper edge rising over the bottom of the hero, plus a
   gradient feather, so the warm body "rises" out of the dark.
------------------------------------------------------------------ */
.curtain {
  position: relative;
  z-index: 3;
  height: clamp(60px, 9vw, 120px);
  margin-top: -1px;
  background: linear-gradient(180deg, rgba(28, 24, 16, 0) 0%, var(--parchment) 88%);
}

.curtain::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 40%;
  background:
    radial-gradient(120% 100% at 50% 100%, rgba(47, 111, 115, 0.10), transparent 70%);
}

/* Mirror for the parchment → ink closing transition */
.curtain--up {
  background: linear-gradient(180deg, var(--parchment) 0%, rgba(28, 24, 16, 0) 92%);
}

/* ==================================================================
   CTA
================================================================== */
.cta {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
  font-family: var(--font-body);
  font-size: 0.96rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-decoration: none;
  padding: 0.95rem 1.7rem;
  border-radius: 2px;
  transition: transform .3s var(--ease), background-color .3s var(--ease),
    color .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease);
}

.cta::after {
  content: "→";
  font-size: 1.05em;
  transition: transform .3s var(--ease);
}

.cta:hover::after {
  transform: translateX(4px);
}

.cta-hero {
  border: 1px solid rgba(245, 240, 232, 0.5);
  color: var(--text-on-ink);
}

.cta-hero:hover {
  background: var(--text-on-ink);
  color: var(--ink);
  border-color: var(--text-on-ink);
  transform: translateY(-2px);
}

.cta-closing {
  background: var(--petrol);
  color: #fff;
  box-shadow: 0 10px 30px -12px rgba(47, 111, 115, 0.7);
}

.cta-closing:hover {
  background: var(--petrol-deep);
  transform: translateY(-2px);
  box-shadow: 0 16px 36px -12px rgba(47, 111, 115, 0.8);
}

/* ==================================================================
   PARCHMENT BODY — "the living journal"
================================================================== */
.band {
  position: relative;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: var(--space) 1.5rem;
}

/* hairline separators between journal entries */
.band+.band::before {
  content: "";
  position: absolute;
  top: 0;
  left: 1.5rem;
  right: 1.5rem;
  height: 1px;
  background: linear-gradient(90deg, var(--parchment-edge), transparent 70%);
}

.label {
  display: inline-flex;
  align-items: center;
  gap: 0.7em;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--petrol);
  margin: 0 0 1.1rem;
}

.label::before {
  content: "";
  width: 1.6em;
  height: 1px;
  background: var(--petrol);
  opacity: 0.55;
}

.band-headline {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.75rem, 4.6vw, 2.6rem);
  line-height: 1.16;
  letter-spacing: -0.012em;
  margin: 0 0 1.3rem;
  text-wrap: balance;
}

.band-body {
  color: var(--text-muted);
  font-size: clamp(1.04rem, 2.2vw, 1.12rem);
  margin: 0 0 1rem;
  max-width: 34em;
}

/* Founders — airy editorial entries, each marked with a short petrol rule */
.founders {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.25rem;
  margin: 1.5rem 0 0;
}

.founder::before {
  content: "";
  display: block;
  width: 34px;
  height: 2px;
  background: var(--petrol);
  margin-bottom: 1.1rem;
}

.founder-name {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.3rem;
  line-height: 1.2;
  margin: 0 0 0.3rem;
}

.founder-role {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.74rem;
  font-weight: 600;
  color: var(--petrol);
  margin: 0 0 0.85rem;
}

.founder-bio {
  color: var(--text-muted);
  font-size: 0.99rem;
  margin: 0;
}

/* Pull-quote — set like a marginal note, large literary serif */
.pull-quote {
  position: relative;
  margin: 2rem 0 0;
  padding: 1.4rem 0 0.3rem 2rem;
  border: 0;
  border-left: 2px solid var(--petrol);
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.3rem, 3.2vw, 1.65rem);
  line-height: 1.4;
  letter-spacing: -0.01em;
  color: var(--ink);
}

.pull-quote::before {
  content: "\201C";
  position: absolute;
  left: 0.55rem;
  top: -0.35rem;
  font-size: 3.2rem;
  line-height: 1;
  color: var(--petrol);
  opacity: 0.28;
}

/* ------------------------------------------------------------------
   Strata emblem — the two-tier model as layered contours with a rising sprout
------------------------------------------------------------------ */
.approach-diagram {
  margin: 0.75rem auto 2rem;
  max-width: 420px;
  width: 100%;
}

.approach-diagram svg {
  display: block;
  width: 100%;
  height: auto;
}

/* ------------------------------------------------------------------
   TWO-COLUMN KNOWLEDGE MODEL — paired cards with raised depth
------------------------------------------------------------------ */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin: 0.5rem 0 1.75rem;
}

.knowledge-card {
  position: relative;
  background: linear-gradient(180deg, #FBF8F2, var(--parchment-shade));
  border: 1px solid var(--parchment-edge);
  border-radius: 6px;
  padding: 1.5rem 1.4rem;
  box-shadow: var(--shadow-card);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease);
  overflow: hidden;
}

.knowledge-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--petrol), var(--petrol-light));
}

.knowledge-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 2px 4px rgba(28, 24, 16, 0.05), 0 18px 38px -20px rgba(28, 24, 16, 0.32);
}

.card-label {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.74rem;
  font-weight: 600;
  color: var(--petrol);
  margin: 0 0 0.65rem;
}

.card-body {
  color: var(--text-muted);
  font-size: 0.99rem;
  margin: 0;
}

/* ------------------------------------------------------------------
   CHIPS — founding-partner benefits
------------------------------------------------------------------ */
.chips {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  padding: 0;
  margin: 1.6rem 0 0;
}

.chip {
  display: inline-flex;
  align-items: center;
  background: transparent;
  color: var(--petrol);
  border: 1px solid rgba(47, 111, 115, 0.45);
  border-radius: 999px;
  font-size: 0.86rem;
  font-weight: 600;
  padding: 0.5rem 1rem;
  transition: background-color .3s var(--ease), color .3s var(--ease), border-color .3s var(--ease);
}

.chip::before {
  content: "✓";
  margin-right: 0.5em;
  font-size: 0.85em;
  color: var(--petrol);
  transition: color .3s var(--ease);
}

.chip:hover {
  background: var(--petrol);
  border-color: var(--petrol);
  color: #fff;
}

.chip:hover::before {
  color: #fff;
}

/* ==================================================================
   CLOSING / INK BOOKEND (mirrors hero)
================================================================== */
.closing {
  position: relative;
  background: var(--ink);
  color: var(--text-on-ink);
  overflow: hidden;
}

.closing .curtain--up,
.closing .hero-atmosphere {
  z-index: 0;
}

.closing .hero-atmosphere {
  background:
    radial-gradient(120% 90% at 82% 12%, rgba(47, 111, 115, 0.16) 0%, transparent 48%),
    radial-gradient(140% 120% at 18% 110%, rgba(120, 96, 60, 0.13) 0%, transparent 54%),
    radial-gradient(120% 130% at 50% 100%, var(--ink) 0%, var(--ink-deep) 100%);
}

.closing-inner {
  position: relative;
  z-index: 3;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(4rem, 11vw, 7rem) 1.5rem var(--space);
  text-align: center;
}

.closing-inner .label {
  color: var(--petrol-light);
  justify-content: center;
}

.closing-inner .label::before {
  background: var(--petrol-light);
}

.closing-headline {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2rem, 5.5vw, 3.1rem);
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin: 0 0 1.1rem;
  text-wrap: balance;
}

.closing-body {
  color: var(--text-muted-on-ink);
  font-size: clamp(1.05rem, 2.3vw, 1.15rem);
  max-width: 32em;
  margin: 0 auto 2.25rem;
}

.footer-bar {
  position: relative;
  z-index: 3;
  border-top: 1px solid rgba(168, 158, 134, 0.18);
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 1.6rem 1.5rem 2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.84rem;
  color: var(--text-muted-on-ink);
}

.footer-logo {
  height: 18px;
}

.footer-rights {
  letter-spacing: 0.005em;
}

.footer-contact {
  color: var(--petrol-light);
  text-decoration: none;
  margin-left: auto;
  font-weight: 600;
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease);
}

.footer-contact:hover {
  border-color: var(--petrol-light);
}

/* ==================================================================
   SCROLL REVEALS (Task 6 wires the JS; CSS degrades gracefully)
   Hidden/animated state is gated behind the root `.js` class that
   main.js adds, so without JS all content renders fully visible.
================================================================== */
.js .reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .8s var(--ease), transform .8s var(--ease);
}

.js .reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* Hero gets a staggered page-load reveal once JS is active. */
.js .hero>* {
  opacity: 0;
  transform: translateY(16px);
  animation: rise 0.9s var(--ease) forwards;
}

.js .hero .hero-eyebrow {
  animation-delay: 0.15s;
}

.js .hero .hero-scene {
  animation-delay: 0.30s;
}

.js .hero .hero-headline {
  animation-delay: 0.45s;
}

.js .hero .hero-sub {
  animation-delay: 0.65s;
}

.js .hero .cta-hero {
  animation-delay: 0.85s;
}

/* The hero section itself shouldn't fade as a block — its children do. */
.js .hero.reveal {
  opacity: 1;
  transform: none;
}

@keyframes rise {
  to {
    opacity: 1;
    transform: none;
  }
}

/* ==================================================================
   RESPONSIVE
================================================================== */
@media (max-width: 640px) {
  .two-col {
    grid-template-columns: 1fr;
  }

  .founders {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }

  .hero {
    padding-top: 3rem;
  }

  .footer-bar {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-contact {
    margin-left: 0;
  }
}

/* ==================================================================
   FOCUS VISIBILITY
================================================================== */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--petrol-light);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ==================================================================
   REDUCED MOTION — collapse all reveals / transitions to instant
================================================================== */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal,
  .hero>*,
  .js .reveal,
  .js .hero>* {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
    animation: none !important;
  }

  .cta,
  .chip,
  .knowledge-card,
  .lang-toggle,
  .footer-contact {
    transition: none;
  }
}


/* ==================================================================
   SITE REFINEMENTS — copy layout, hero, footer
   (consolidated from former inline <style> in index.html)
================================================================== */

/* Hero contour waves — anchored to the right edge so they stay visible on
   wide screens; echo the strata emblem in the approach section */
.hero-contours { right: 0; top: -6%; width: clamp(360px, 48vw, 920px); opacity: 0.32; }
.hero-contours g { stroke: #5AB5BB; }
.hero-contours path:nth-child(1) { stroke-width: 1.6; }
.hero-contours path:nth-child(2) { stroke-width: 1.2; stroke-opacity: 0.8; }
.hero-contours path:nth-child(3) { stroke-width: 1; stroke-opacity: 0.6; }
.hero-contours path:nth-child(4) { stroke-width: 1; stroke-opacity: 0.45; }

.hero-scene, .hero-eyebrow { color: #DED8CC; }

.cta-hero { background: var(--petrol); color: #fff; border-color: var(--petrol); }
.cta-hero:hover { background: var(--petrol-deep); color: #fff; }

.chips { flex-direction: column; align-items: flex-start; }
.chip { background: none; border: none; border-radius: 0; padding: 0; }
.chip:hover { background: none; color: var(--petrol); }

/* Full-column width for copy and buttons */
.hero-scene, .hero-sub, .band-body, .closing-body, .pull-quote { max-width: none; }
.cta-hero, .cta-closing { display: flex; width: 100%; justify-content: center; }

/* Large, prominent eyebrow title */
.hero-eyebrow {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4.5vw, 2.6rem);
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1.12;
  color: #DED8CC;
  margin-bottom: 1.8rem;
}

/* Scene (question) leading into the headline (answer) */
.hero-scene {
  font-size: clamp(1.15rem, 2.8vw, 1.5rem);
  font-style: italic;
  margin-bottom: 1rem;
}
.hero-headline {
  padding-left: 1.4rem;
  border-left: 4px solid var(--petrol-light);
}

/* Footer: contact block below the logo, copyright, legal links */
.footer-bar { flex-direction: column; align-items: flex-start; gap: 1.5rem; }
.footer-brand { display: flex; flex-direction: column; align-items: flex-start; gap: 1rem; }
.footer-logo { align-self: flex-start; width: auto; max-width: 100%; }
.footer-contact-block { display: flex; flex-direction: column; gap: 0.25rem; font-size: 0.9rem; }
.footer-contact-head {
  text-transform: uppercase; letter-spacing: 0.18em; font-size: 0.72rem;
  font-weight: 600; color: var(--petrol-light); margin: 0 0 0.35rem;
}
.footer-contact-block a { color: var(--text-muted-on-ink); text-decoration: none; }
.footer-contact-block a:hover { color: var(--text-on-ink); }
.footer-legal {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem 1.4rem;
  width: 100%; border-top: 1px solid rgba(168, 158, 134, 0.18); padding-top: 1.2rem;
  font-size: 0.8rem; letter-spacing: 0.06em;
}
.footer-links { display: inline-flex; gap: 1.3rem; margin-left: auto; }
.footer-links a { color: var(--petrol-light); text-decoration: none; letter-spacing: 0.02em; }
.footer-links a:hover { text-decoration: underline; }

/* ==================================================================
   LEGAL PAGES (Impressum, Datenschutz)
================================================================== */
.legal-nav { max-width: var(--maxw); margin: 0 auto; padding: 1.75rem 1.5rem 0; display: flex; justify-content: space-between; align-items: center; }
.legal-nav img { height: 22px; width: auto; }
.legal-lang { color: var(--petrol); text-decoration: none; font-size: 0.72rem; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; border: 1px solid rgba(47, 111, 115, 0.4); border-radius: 999px; padding: 0.4rem 0.95rem; }
.legal-lang:hover { background: var(--petrol); color: #fff; border-color: var(--petrol); }
.legal-main { max-width: var(--maxw); margin: 0 auto; padding: clamp(2.5rem, 7vw, 5rem) 1.5rem clamp(3.5rem, 9vw, 7rem); }
.legal-main h1 { font-family: var(--font-display); font-weight: 500; font-size: clamp(1.9rem, 5vw, 2.8rem); line-height: 1.1; margin: 0 0 0.5rem; }
.legal-date { color: var(--text-muted); font-size: 0.9rem; margin: 0 0 2.5rem; }
.legal-main h2 { font-family: var(--font-display); font-weight: 500; font-size: 1.15rem; margin: 2.2rem 0 0.5rem; }
.legal-main p { color: var(--text-muted); max-width: 42em; margin: 0 0 0.9rem; }
.legal-main a { color: var(--petrol); }
.legal-back { display: inline-block; margin-top: 2.8rem; color: var(--petrol); text-decoration: none; font-weight: 500; }
.legal-back:hover { text-decoration: underline; }
