/* ==========================================================
   wAItblick – Stylesheet
   Corporate Design v1.0: Petrol dominant, Weinrot sparsam,
   Manrope für Wortmarke und Überschriften, Inter für Text.
   ========================================================== */

/* ---------- Schriften (lokal eingebunden, keine Google-Abfrage) ---------- */
@font-face {
  font-family: "Manrope";
  src: url("../fonts/Manrope-Variable.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter-Regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter-Medium.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}

/* ---------- Design-Tokens ---------- */
:root {
  --petrol: #1F4E56;
  --petrol-m: #2E6A73;
  --wine: #6B2D3A;
  --text: #202D31;
  --slate: #5D696C;
  --warm: #F7F5F2;
  --white: #FFFFFF;
  --line: #D9DFDF;

  --font-head: "Manrope", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;

  --wrap: 72rem;
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --section: clamp(4.5rem, 10vw, 8rem);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 5rem;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--warm);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  font-feature-settings: "cv11", "ss01";
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a {
  color: var(--petrol);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}
a:hover { color: var(--wine); }

:focus-visible {
  outline: 2px solid var(--wine);
  outline-offset: 3px;
  border-radius: 2px;
}

h1, h2, h3 {
  font-family: var(--font-head);
  color: var(--petrol);
  margin: 0;
  font-weight: 700;
  letter-spacing: -0.02em;
}

p { margin: 0 0 1em; }

.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0.5rem;
  background: var(--petrol);
  color: var(--white);
  padding: 0.5rem 1rem;
  z-index: 100;
}
.skip-link:focus { left: 0.5rem; }

/* ---------- Wortmarke ---------- */
.wordmark {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.375rem;
  letter-spacing: -0.03em;
  color: var(--petrol);
  text-decoration: none;
}
.wordmark .ai { color: var(--wine); }
.wordmark:hover { color: var(--petrol); }

/* ---------- Navigation ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(247, 245, 242, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}
.site-header.scrolled { border-bottom-color: var(--line); }

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  min-height: 4.25rem;
}

.nav { display: flex; gap: 1.75rem; }
.nav a {
  color: var(--text);
  text-decoration: none;
  font-size: 0.9375rem;
  font-weight: 500;
}
.nav a:hover { color: var(--petrol); text-decoration: underline; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 0.4rem 0.75rem;
  font: 500 0.9375rem var(--font-body);
  color: var(--petrol);
  cursor: pointer;
}

/* ---------- Hero ---------- */
.hero {
  padding-top: clamp(4rem, 12vw, 9rem);
  padding-bottom: 0;
}

.hero h1 {
  font-size: clamp(2.5rem, 7vw, 5.25rem);
  line-height: 1.04;
  letter-spacing: -0.035em;
  font-weight: 700;
  max-width: 14ch;
}

.hero-intro {
  margin-top: 2rem;
  max-width: 38rem;
  font-size: clamp(1.0625rem, 1.6vw, 1.25rem);
  color: var(--slate);
}
.hero-intro strong { color: var(--text); font-weight: 600; }
.hero-intro p { margin: 0 0 0.9em; }
.hero-intro p:last-child { margin-bottom: 0; }

.hero-actions {
  margin-top: 2.25rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.btn {
  display: inline-block;
  padding: 0.8rem 1.4rem;
  border-radius: 4px;
  font-weight: 600;
  font-size: 0.9375rem;
  text-decoration: none;
  border: 1.5px solid var(--petrol);
  transition: background-color 0.15s, color 0.15s;
}
.btn-primary { background: var(--petrol); color: var(--white); }
.btn-primary:hover { background: var(--petrol-m); border-color: var(--petrol-m); color: var(--white); }
.btn-ghost { color: var(--petrol); }
.btn-ghost:hover { background: var(--white); color: var(--petrol); }

/* Die Horizontlinie: das einzige markante Gestaltungselement */
.horizon {
  margin-top: clamp(4rem, 9vw, 7rem);
  width: 100%;
  height: auto;
  display: block;
}
.horizon path {
  fill: none;
  stroke: var(--petrol);
  stroke-width: 1.25;
  stroke-linejoin: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
}
@media (prefers-reduced-motion: no-preference) {
  .horizon path {
    stroke-dashoffset: 1;
    animation: draw 2.4s cubic-bezier(0.65, 0, 0.35, 1) 0.3s forwards;
  }
}
@keyframes draw { to { stroke-dashoffset: 0; } }

/* ---------- Abschnitte: Titel links, Inhalt rechts ---------- */
.section {
  padding: var(--section) 0;
}
.section + .section { border-top: 1px solid var(--line); }

.section .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2.2fr);
  gap: 2rem clamp(2rem, 6vw, 6rem);
}

.section-title {
  font-size: clamp(1.5rem, 2.4vw, 1.875rem);
  line-height: 1.2;
}
.section-title-wrap { align-self: start; position: sticky; top: 6rem; }
.section-note {
  margin-top: 0.75rem;
  color: var(--slate);
  font-size: 0.9375rem;
  max-width: 18rem;
}

.content { max-width: 40rem; }

.lead {
  font-size: 1.1875rem;
  line-height: 1.6;
  color: var(--text);
}

/* ---------- Haltung ---------- */
.principle {
  margin: 2.5rem 0 0;
  padding: 0 0 0 1.5rem;
  border-left: 2px solid var(--wine);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: clamp(1.25rem, 2.2vw, 1.5rem);
  line-height: 1.4;
  letter-spacing: -0.015em;
  color: var(--petrol);
}

.portrait {
  margin: 1.75rem 0 0;
  width: min(100%, 15rem);
  aspect-ratio: 4 / 5;
  background: var(--white);
  border: 1px solid var(--line);
  overflow: hidden;
  border-radius: 4px;
}
.portrait img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Schwerpunkte ---------- */
.focus-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2.25rem;
}
.focus-list h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}
.focus-list p { margin: 0; }
.focus-tools {
  margin-top: 0.5rem !important;
  font-size: 0.875rem;
  color: var(--slate);
}

/* ---------- Projekte ---------- */
.case {
  padding: 2.25rem 0;
  border-top: 1px solid var(--line);
}
.case:first-of-type { border-top: 0; padding-top: 0; }

.case h3 {
  font-size: clamp(1.25rem, 2vw, 1.5rem);
  line-height: 1.3;
}
.case-context {
  margin: 0.4rem 0 1rem;
  font-size: 0.9375rem;
  color: var(--petrol-m);
  font-weight: 500;
}
.case-facts {
  margin: 1.25rem 0 0;
  display: grid;
  grid-template-columns: 7.5rem 1fr;
  gap: 0.35rem 1.25rem;
  font-size: 0.9375rem;
}
.case-facts dt { color: var(--slate); }
.case-facts dd { margin: 0; }

/* ---------- KI-Werkstatt ---------- */
.lab {
  display: grid;
  gap: 1.75rem;
  margin-top: 2rem;
}
@media (min-width: 1100px) {
  .lab { grid-template-columns: 1fr 1fr; gap: 1.25rem; }
}
.lab-item {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 1.5rem 1.75rem;
}
.lab-item h3 { font-size: 1.125rem; }
.lab-item p { margin: 0.5rem 0 0; }
.lab-tools {
  margin-top: 0.75rem !important;
  font-size: 0.875rem;
  color: var(--petrol-m);
}

/* ---------- Werdegang ---------- */
.timeline {
  list-style: none;
  margin: 0;
  padding: 0;
}
.timeline li {
  display: grid;
  grid-template-columns: 9.5rem 1fr;
  gap: 1rem;
  padding: 0.9rem 0;
  border-top: 1px solid var(--line);
}
.timeline li:first-child { border-top: 0; padding-top: 0; }
.timeline time, .timeline .when {
  color: var(--slate);
  font-size: 0.9375rem;
  font-variant-numeric: tabular-nums;
}
.timeline .role { font-weight: 600; display: block; }
.timeline .org { color: var(--petrol-m); font-size: 0.9375rem; }

.after-list { margin-top: 2rem; }

/* ---------- Kontakt ---------- */
.contact {
  background: var(--petrol);
  color: var(--white);
}
.contact .section-title { color: var(--white); }
.contact .section-note { color: #C5D5D7; }
.contact .lead { color: var(--white); }
.contact-list {
  list-style: none;
  margin: 2rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.75rem;
  font-size: 1.125rem;
}
.contact-list span {
  display: inline-block;
  min-width: 6.5rem;
  color: #C5D5D7;
  font-size: 0.9375rem;
}
.contact a { color: var(--white); }
.contact a:hover { color: #F2D9DE; }
.contact :focus-visible { outline-color: var(--white); }
.contact.section + .site-footer { border-top: 0; }

/* ---------- Footer ---------- */
.site-footer {
  padding: 2rem 0 2.5rem;
  font-size: 0.875rem;
  color: var(--slate);
}
.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  align-items: baseline;
}
.site-footer nav { display: flex; gap: 1.5rem; }
.site-footer a { color: var(--slate); }

/* ---------- Rechtstexte ---------- */
.legal { padding: clamp(3rem, 8vw, 6rem) 0; }
.legal .wrap { max-width: 46rem; }
.legal h1 { font-size: clamp(2rem, 4vw, 2.75rem); margin-bottom: 2rem; }
.legal h2 { font-size: 1.25rem; margin: 2.5rem 0 0.75rem; }
.legal .draft {
  background: var(--white);
  border-left: 3px solid var(--wine);
  padding: 1rem 1.25rem;
  font-size: 0.9375rem;
  margin-bottom: 2rem;
}

/* ---------- Responsiv ---------- */
@media (max-width: 860px) {
  .section .wrap { grid-template-columns: 1fr; }
  .section-title-wrap { position: static; }
}

@media (max-width: 720px) {
  .nav-toggle { display: inline-block; }
  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: var(--warm);
    border-bottom: 1px solid var(--line);
    padding: 0.5rem var(--gutter) 1rem;
  }
  .nav.open { display: flex; }
  .nav a { padding: 0.7rem 0; border-top: 1px solid var(--line); }
  .nav a:first-child { border-top: 0; }

  .timeline li { grid-template-columns: 1fr; gap: 0.15rem; }
  .case-facts { grid-template-columns: 1fr; gap: 0; }
  .case-facts dd { margin-bottom: 0.6rem; }
}

@media print {
  .site-header, .hero-actions, .horizon { display: none; }
  body { background: var(--white); }
}
