/* ─── Reset ─────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ─── Tokens ─────────────────────────────────────── */
:root {
  --black: #1d1d1b;
  --white: #ffffff;
  --grey:  #c8c8c4;
  --font:  'STIX Two Math', Georgia, serif;

  --cols: 6;
  --gap:  clamp(24px, 3vw, 56px);
  --pad:  clamp(28px, 6vw, 96px);
  --nav-h: clamp(220px, 8vh, 88px);
  --row-h: clamp(80px, 10vh, 130px);
}

/* ─── Base ───────────────────────────────────────── */
html { font-size: clamp(16px, 1.4vw, 22px); scroll-behavior: smooth; scrollbar-width: none; }
html::-webkit-scrollbar { display: none; }

body {
  font-family: var(--font);
  font-weight: 400;
  color: var(--black);
  background: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
}

em  { font-style: italic; }
a   { color: var(--black); text-decoration: none; }
a:hover { text-decoration: underline; }
h3  { font-weight: 400; font-size: 1.1em; margin-bottom: .5em; }
h4  { font-weight: 400; font-style: italic; font-size: .9em; margin-top: 1.4em; margin-bottom: .3em; }

/* ─── Wasserzeichen ──────────────────────────────── */
/* ─── Wasserzeichen ──────────────────────────────── */
.wm {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.wm::before {
  content: '';
  position: absolute;
  width: 240vw; height: 240vh;
  top: -70vh; left: -70vw;
  background-image: var(--wm-url, url('../grafiken/wasserzeichen_einzeln.svg'));
  background-size: clamp(200px, 22vw, 340px);
  background-repeat: repeat;
  transform: rotate(-30deg);
  opacity: var(--wm-opacity, 0.1);
}
.wm::after {
  content: '';
  position: absolute;
  width: 240vw; height: 240vh;
  top: -70vh; left: -70vw;
  background-image: url('../grafiken/wasserzeichen_einzeln_hell.svg');
  background-size: clamp(200px, 22vw, 340px) clamp(200px, 22vw, 340px);
  background-repeat: repeat;
  transform: rotate(-30deg);
  opacity: 0; /* startet unsichtbar */
  transition: opacity 0.1s ease;
}

.wm.inverted::before { opacity: 0; }
.wm.inverted::after  { opacity: 0.15; }
/* ─── Nav ────────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--pad);
  background: rgba(255,255,255,.75);
  backdrop-filter: blur(10px);
  border-bottom: .5px solid var(--grey);
}

.nav-left   { display: flex; flex-direction: column; gap: 0px; line-height: 0.9; }
.nav-title  { font-size: clamp(1.1rem, 1.6vw, 1.5rem); line-height: 1; }
.nav-sub    { font-size: clamp(.75rem, .9vw, .9rem); line-height: 1; }
.nav-links  { display: flex; gap: clamp(20px, 3vw, 48px); }
.nav-links a { font-size: clamp(.8rem, .95vw, 1rem); }

/* ─── Logo ───────────────────────────────────────── */

.logo {
  position: fixed;
  top: calc(var(--nav-h) + clamp(20px, 3vh, 40px));
  right: clamp(20px, 3vw, 40px);
  z-index: 100;
  width: clamp(100px, 22vw, 280px);
  height: clamp(100px, 22vw, 280px);
  pointer-events: none;
  display: block;
}

.logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.logo-inner {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-inner svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
/* ─── Page ───────────────────────────────────────── */
.page {
  position: relative;
  z-index: 1;
  min-height: 100svh;
  padding: calc(var(--nav-h) + clamp(60px, 10vh, 130px)) var(--pad) clamp(60px, 10vh, 130px);
  border-bottom: .5px solid var(--grey);
}

/* ─── 6-Spalten Raster ───────────────────────────── */
.grid-6 {
  display: grid;
  grid-template-columns: repeat(var(--cols), 1fr);
  grid-auto-rows: var(--row-h);
  gap: 0 var(--gap);
  max-width: 1600px;
  margin: 0 auto;
}

.hero-page .grid-6 {
  grid-auto-rows: minmax(var(--row-h), auto);
}

.about-page .grid-6 {
  grid-auto-rows: minmax(var(--row-h), auto);
}

/* Spalten */
.col-1 { grid-column-start: 1; }
.col-2 { grid-column-start: 2; }
.col-3 { grid-column-start: 3; }
.col-4 { grid-column-start: 4; }
.col-5 { grid-column-start: 5; }

.col-span-2 { grid-column-end: span 2; }
.col-span-3 { grid-column-end: span 3; }
.col-span-4 { grid-column-end: span 4; }
.col-span-5 { grid-column-end: span 5; }

/* Zeilen */
.row-1  { grid-row: 1; }
.row-2  { grid-row: 2; }
.row-3  { grid-row: 3; }
.row-4  { grid-row: 4; }
.row-5  { grid-row: 5; }
.row-6  { grid-row: 6; }
.row-7  { grid-row: 7; }
.row-8  { grid-row: 8; }
.row-9  { grid-row: 9; }

/* ─── Blöcke ─────────────────────────────────────── */
.block-label {
  display: flex;
  align-items: flex-start;
  gap: .3em;
  font-size: clamp(1.8rem, 2.8vw, 2.8rem);
  font-style: italic;
  align-self: start;
  padding-top: .1em;
}
.arr { font-style: normal; }

.block-text {
  align-self: start;
  padding-bottom: clamp(16px, 2.5vh, 36px);
}
.block-text p + p { margin-top: .85em; }
.block-text p { font-size: clamp(.92rem, 1.1vw, 1.1rem); max-width: 54ch; line-height: 1.5; }

.meta {
  align-self: start;
  text-align: right;
  font-size: clamp(.8rem, .95vw, 1rem);
  line-height: 1.8;
  /* Abstand vom Logo */
  padding-right: clamp(130px, 16vw, 230px);
}

/* ─── Open Call ──────────────────────────────────── */
.open-call {
  position: fixed;
  bottom: clamp(20px, 4vw, 40px);
  left: clamp(20px, 4vw, 40px);
  display: flex;
  flex-direction: column;
  line-height: 0.92;
  padding-bottom: clamp(12px, 2vh, 28px);
  z-index: 99;
  pointer-events: auto;
  transition: opacity 0.3s ease;
}

.open-call span {
  font-style: italic;
  font-size: clamp(4.5rem, 10vw, 12rem);
  letter-spacing: -0.02em;
}

.open-call span:last-child {
  padding-left: clamp(1.5rem, 4vw, 5rem);
}

/* ─── About ──────────────────────────────────────── */
.about-page .block-text h3 {
  font-size: clamp(1.2rem, 1.6vw, 1.7rem);
  margin-bottom: .7em;
}

.team-statement {
  padding-top: clamp(20px, 3.5vh, 40px);
  align-self: start;
  grid-row: span 2;
}
.team-statement p { font-size: clamp(.88rem, 1.05vw, 1.05rem); max-width: 72ch; }

.kontakt-row {
  display: flex;
  gap: clamp(20px, 4vw, 60px);
  font-size: clamp(.92rem, 1.1vw, 1.15rem);
  line-height: 2.2;
}

/* ─── Impressum ──────────────────────────────────── */
.impressum-page {
  min-height: auto;
  padding: clamp(28px, 6vw, 96px) var(--pad);
  background: rgba(255,255,255,.95);
  backdrop-filter: blur(8px);
  border-top: .5px solid var(--grey);
}
.impressum-content {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(20px, 3vw, 40px);
  max-width: 1600px;
  margin: 0 auto;
}
.impressum-col h4 { font-weight: 400; font-style: italic; font-size: .9em; margin-top: 0; margin-bottom: .5em; }
.impressum-col p { font-size: clamp(.85rem, 1vw, 1rem); line-height: 1.6; }

/* ─── Footer ─────────────────────────────────────── */
.footer {
  display: none;
}

/* ─── Fade ───────────────────────────────────────── */
.fade { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.fade.in { opacity: 1; transform: none; }

/* ─── Tablet ─────────────────────────────────────── */
@media (max-width: 960px) {
  :root { --cols: 4; --row-h: clamp(70px, 9vh, 110px); }

  .col-5       { grid-column-start: 3; }
  .col-span-4  { grid-column-end: span 3; }
  .col-span-5  { grid-column-end: span 4; }
  .meta        { padding-right: clamp(90px, 18vw, 160px); }
  .logo        { width: clamp(100px, 16vw, 150px); height: clamp(100px, 16vw, 150px); }
}






/* ─── Mobile ─────────────────────────────────────── */
@media (max-width: 600px) {
  :root { 
    --pad: max(22px, env(safe-area-inset-right));
    --nav-h: clamp(50px, 12vh, 70px);
  }

  /* Nav mit Safe Area */
  .nav {
    position: fixed;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: max(12px, env(safe-area-inset-top)) var(--pad) max(12px, env(safe-area-inset-bottom)) max(22px, env(safe-area-inset-left));
    height: var(--nav-h);
  }
  .nav-left { margin-bottom: 0; display: flex; flex-direction: column; }
  .nav-links { 
    position: fixed;
    bottom: clamp(120px, 28vh, 200px);
    right: max(clamp(12px, 2vw, 24px), env(safe-area-inset-right));
    flex-direction: column; 
    gap: 8px; 
    align-items: flex-end;
    z-index: 101;
  }
  .nav-links a { font-size: 0.75rem; }

  .hero-page {
    padding-top: calc(var(--nav-h) + clamp(120px, 25vw, 160px));
  }

  .page {
    padding: clamp(12px, 3vh, 20px) var(--pad) clamp(60px, 10vh, 130px);
  }
  .grid-6 {
    display: flex;
    flex-direction: column;
    gap: clamp(28px, 5vh, 44px);
  }
  
  .block-label { grid-column: unset !important; grid-row: unset !important; }
  .block-text { grid-column: unset !important; grid-row: unset !important; }
  .col-1, .col-2, .col-3, .col-4, .col-5 { grid-column-start: unset !important; }
  .col-span-2, .col-span-3, .col-span-4, .col-span-5 { grid-column-end: unset !important; }
  .row-1, .row-3, .row-5, .row-7, .row-9, .row-13 { grid-row: unset !important; }

  /* Meta & Content */
  .meta { text-align: left; padding-right: 0; display: none; }
  .open-call { 
    position: fixed !important; 
    bottom: clamp(20px, 4vh, 40px); 
    left: max(var(--pad), env(safe-area-inset-left)); 
    width: auto; 
    display: flex; 
    flex-direction: column; 
    gap: -5px;
    font-size: clamp(2rem, 9vw, 3.2rem); 
    line-height: 0.92;
  }
  
  .open-call span:last-child {
    padding-left: clamp(0.8rem, 3vw, 2rem);
  }
  
  /* Logo Mobile - oben rechts unter Nav */
  .logo {
    position: fixed;
    top: calc(var(--nav-h) + 8px);
    bottom: auto;
    right: max(clamp(8px, 2vw, 16px), env(safe-area-inset-right));
    width: clamp(80px, 20vw, 140px);
    height: clamp(80px, 20vw, 140px);
    z-index: 100;
  }
  
  /* Impressum Mobile Layout */
  .impressum-content {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: clamp(12px, 2vw, 24px);
  }
  .impressum-col { grid-column: span 1; }
  .impressum-col h4 { font-size: 0.85rem; }
  .impressum-col p { font-size: 0.8rem; }
}
