/* 2malK-Kompetenzwerkstatt
   Layout: fixierte Kopfzeile mit Menü, Banner in voller Breite, darunter
   Abschnitte in einer 1080px-Spalte; Kennzahlen und Kompetenzfelder als Raster. */
:root {
  --bg: #f5f7fa;
  --surface: #ffffff;
  --fg: #1b2532;
  --muted: #566376;
  --line: #dbe2eb;
  --accent: #1a74ec;
  --accent-soft: #e6effc;
  --on-accent: #ffffff;

  --font-display: "Segoe UI Variable Display", "Segoe UI", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-body: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Helvetica, Arial, sans-serif;

  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: 1.25rem;
  --step-2: 1.6rem;
  --step-3: clamp(1.9rem, 1.4rem + 2vw, 2.6rem);

  --wrap: 1080px;
  --gutter: 20px;
  --header-h: 64px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f151d;
    --surface: #16202b;
    --fg: #e5ebf2;
    --muted: #9aa8b9;
    --line: #283544;
    --accent: #5aa0ff;
    --accent-soft: #1a2a40;
    --on-accent: #0f151d;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0f151d;
  --surface: #16202b;
  --fg: #e5ebf2;
  --muted: #9aa8b9;
  --line: #283544;
  --accent: #5aa0ff;
  --accent-soft: #1a2a40;
  --on-accent: #0f151d;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); }
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}
h1, h2, h3 { font-family: var(--font-display); line-height: 1.2; text-wrap: balance; margin: 0; -webkit-hyphens: auto; hyphens: auto; overflow-wrap: break-word; }
p { margin: 0; }
.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ---------- Kopfzeile ---------- */
.site-header {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 10;
  background: var(--surface);
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; min-height: var(--header-h);
}
.brand {
  display: flex; align-items: baseline; gap: 10px;
  color: var(--fg); text-decoration: none;
}
.brand-mark { font-family: var(--font-display); font-weight: 800; font-size: clamp(1.05rem, 0.85rem + 1vw, 1.4rem); letter-spacing: -0.01em; white-space: nowrap; }
.brand-mark span { color: var(--accent); }

.nav-toggle {
  display: none;
  background: none; border: 1px solid var(--line); border-radius: 8px;
  color: var(--fg); font: inherit; font-size: var(--step--1);
  padding: 8px 12px; cursor: pointer;
}
.nav-toggle-bars { display: inline-block; width: 16px; vertical-align: middle; margin-right: 8px; }
.nav-toggle-bars i { display: block; height: 2px; background: currentColor; margin: 3px 0; border-radius: 2px; }

.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; }
.main-nav a {
  display: block; padding: 8px 12px; border-radius: 8px;
  color: var(--fg); text-decoration: none; font-size: 0.95rem; font-weight: 500; white-space: nowrap;
}
.main-nav a:hover { background: var(--accent-soft); color: var(--accent); }
.main-nav a.nav-cta { background: var(--accent); color: var(--on-accent); }
.main-nav a.nav-cta:hover { filter: brightness(1.08); }

@media (max-width: 1140px) {
  .nav-toggle { display: inline-flex; align-items: center; }
  .main-nav {
    position: absolute; left: 0; right: 0; top: 100%;
    background: var(--surface); border-bottom: 1px solid var(--line);
    display: none;
  }
  .main-nav.open { display: block; }
  .main-nav ul { flex-direction: column; padding: 8px var(--gutter) 16px; }
  .main-nav a { padding: 12px; font-size: var(--step-0); }
}

@media (max-width: 400px) {
  .nav-toggle-text { display: none; }
  .nav-toggle-bars { margin-right: 0; }
  .nav-toggle { padding: 10px; }
}

/* ---------- Banner ---------- */
.hero { position: relative; background: #eef3f9; }
.hero picture, .hero img { width: 100%; }
.hero img { aspect-ratio: 1983 / 793; object-fit: cover; }
.ai-label {
  /* links unten, bündig mit dem Bildtext (der beginnt bei ca. 7,7 % der Bildbreite) */
  position: absolute; left: 7.7%; bottom: 1.6%;
  color: rgba(27, 37, 50, 0.55);
  font-size: 0.6rem; line-height: 1; letter-spacing: 0.04em;
}
@media (max-width: 700px) {
  .hero img { aspect-ratio: 880 / 793; }
  .ai-label { left: 17.4%; bottom: 2%; }
}

/* ---------- Abschnitte ---------- */
main section { padding-block: clamp(56px, 8vw, 96px); }
main section + section { border-top: 1px solid var(--line); }
.section-head { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; margin-bottom: 36px; max-width: 46rem; }
.eyebrow {
  font-size: 0.78rem; font-weight: 600; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--accent);
}
.section-head h2 { font-size: var(--step-3); font-weight: 700; letter-spacing: -0.01em; }
.lead { font-size: var(--step-1); color: var(--muted); max-width: 40rem; }

/* Leistungen */
.fields {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px;
}
.fields li {
  background: var(--surface); border: 1px solid var(--line); border-radius: 10px;
  padding: 18px 20px; font-weight: 600; display: flex; gap: 12px; align-items: flex-start;
}
.fields li::before {
  content: ""; flex: 0 0 8px; height: 8px; margin-top: 0.55em;
  border-radius: 2px; background: var(--accent);
}
.fields li.wide { grid-column: 1 / -1; }
@media (max-width: 600px) { .fields { grid-template-columns: minmax(0, 1fr); } }
.recipe {
  margin-top: 48px;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); gap: 32px;
}
.recipe h3 { font-size: var(--step-1); margin-bottom: 10px; }
.recipe ul { margin: 0; padding-left: 1.1em; display: grid; gap: 6px; }
.recipe .highlight {
  font-family: var(--font-display); font-size: var(--step-2); font-weight: 700;
  color: var(--accent); line-height: 1.25;
}

/* Ziel */
.goal { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 48px; align-items: start; }
.goal-statement {
  font-family: var(--font-display); font-weight: 700; letter-spacing: -0.015em;
  font-size: clamp(2rem, 1.5rem + 2.4vw, 3.1rem); line-height: 1.12;
}
.goal-statement em { font-style: normal; color: var(--accent); }
.goal-text { display: grid; gap: 16px; max-width: 36rem; font-size: var(--step-1); color: var(--muted); }
@media (max-width: 760px) { .goal { grid-template-columns: 1fr; gap: 24px; } }

/* Team */
.team { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 20px; }
.person {
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px;
  padding: 22px; display: grid; gap: 14px; align-content: start; min-width: 0;
}
.person-top { display: flex; gap: 14px; align-items: center; }
.person-top > div:last-child { min-width: 0; }
@media (min-width: 900px) {
  .person-top { flex-direction: column; align-items: flex-start; gap: 16px; }
  .person .avatar { flex-basis: 112px; width: 112px; height: 112px; }
}
.avatar {
  flex: 0 0 96px; width: 96px; height: 96px; border-radius: 50%;
  background: var(--accent-soft); color: var(--accent);
  display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 700; font-size: 1.3rem;
  overflow: hidden;
}
.avatar picture, .avatar img { width: 100%; height: 100%; }
.avatar img { object-fit: cover; }
.person h3 { font-size: var(--step-1); -webkit-hyphens: manual; hyphens: manual; overflow-wrap: normal; word-break: normal; }
.role { font-size: var(--step--1); color: var(--muted); }
.tagline { font-size: 0.8rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); }
.person p.bio { color: var(--muted); }
.placeholder {
  border: 1px dashed var(--accent); border-radius: 8px; padding: 10px 12px;
  color: var(--accent); background: var(--accent-soft); font-size: var(--step--1);
}

/* Referenzen */
.facts {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 48px;
}
.fact { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 20px; }
.fact-value {
  font-family: var(--font-display); font-weight: 700; font-size: var(--step-2);
  font-variant-numeric: tabular-nums; line-height: 1.2;
}
.fact-label { color: var(--muted); font-size: var(--step--1); margin-top: 4px; }
@media (max-width: 700px) { .facts { grid-template-columns: 1fr; } }

.clients-title, .projects-title { font-size: var(--step-1); margin-bottom: 14px; }
.clients { list-style: none; margin: 0 0 48px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.clients li {
  border: 1px solid var(--line); background: var(--surface); border-radius: 999px;
  padding: 6px 14px; font-size: 0.95rem;
}
.projects { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
.projects details { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; }
.projects summary {
  cursor: pointer; list-style: none; padding: 16px 20px;
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 4px 12px;
  font-weight: 600; font-size: var(--step-1);
}
.projects summary::-webkit-details-marker { display: none; }
.projects summary .count { font-size: 1.4rem; line-height: 1; color: var(--accent); font-weight: 600; }
.projects summary .count::after { content: "+"; }
.projects details[open] summary .count::after { content: "–"; }
.projects ul {
  margin: 0; padding: 0 16px 20px 2em; min-width: 0;
  columns: 2 260px; column-gap: 40px;
}
.projects li { break-inside: avoid; margin-bottom: 6px; -webkit-hyphens: auto; hyphens: auto; overflow-wrap: break-word; }
.note { margin-top: 20px; color: var(--muted); }

/* Leitbild */
.principles-intro { font-size: var(--step-1); margin-bottom: 20px; max-width: 40rem; }
.principles { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; max-width: 44rem; }
.principles li {
  padding: 14px 0 14px 28px; border-bottom: 1px solid var(--line);
  position: relative; font-size: var(--step-1);
}
.principles li::before {
  content: "→"; position: absolute; left: 0; color: var(--accent); font-weight: 700;
}
.quote {
  margin: 56px 0 0; padding: 28px 32px; max-width: 44rem;
  background: var(--accent-soft); border-radius: 12px;
}
.quote blockquote { margin: 0; font-family: var(--font-display); font-size: var(--step-2); line-height: 1.35; font-weight: 600; }
.quote figcaption { margin-top: 12px; color: var(--muted); font-size: var(--step--1); }

/* Kontakt */
.contact { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 12px; }
.contact-item { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 20px; min-width: 0; }
.contact-item h3 { font-size: 0.8rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; font-weight: 600; }
.contact-item p { overflow-wrap: anywhere; }

/* Kontaktformular */
.message-block {
  margin-top: 32px;
  display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); gap: 20px; align-items: start;
}
@media (max-width: 860px) { .message-block { grid-template-columns: minmax(0, 1fr); } }
.contact-form, .direct-contact {
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 24px;
  display: grid; gap: 16px; min-width: 0;
}
.form-title { font-size: var(--step-1); }
.form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 600px) { .form-row { grid-template-columns: minmax(0, 1fr); } }
.field { display: grid; gap: 6px; min-width: 0; }
.field label { font-size: 0.9rem; font-weight: 600; }
.field .req { color: var(--accent); }
.field .opt { font-weight: 400; color: var(--muted); }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--fg);
  background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px;
}
.field textarea { resize: vertical; min-height: 140px; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent);
}
.field [aria-invalid="true"] { border-color: #c62828; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-note { font-size: var(--step--1); color: var(--muted); }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.form-status { font-size: 0.95rem; min-width: 0; }
.form-status.ok { color: #1f7a3d; }
.form-status.err { color: #c62828; }
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font: inherit; font-weight: 600; font-size: 1rem; text-decoration: none; cursor: pointer;
  border-radius: 8px; padding: 11px 20px; border: 1px solid var(--accent);
}
.btn-primary { background: var(--accent); color: var(--on-accent); }
.btn-primary:hover { filter: brightness(1.08); }
.btn-primary[disabled] { opacity: 0.6; cursor: wait; }
.btn-secondary { background: transparent; color: var(--accent); }
.btn-secondary:hover { background: var(--accent-soft); }
.direct-contact p { color: var(--muted); }
.direct-contact .direct-small { font-size: var(--step--1); overflow-wrap: anywhere; }

/* Fußzeile */
.site-footer { border-top: 1px solid var(--line); background: var(--surface); padding-block: 28px; font-size: var(--step--1); color: var(--muted); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.site-footer nav a { display: inline-block; padding-block: 10px; }
.site-footer a { color: var(--muted); }
.site-footer a:hover { color: var(--accent); }

/* Unterseiten (Impressum, Datenschutz) */
.legal { padding-block: 56px 80px; max-width: 46rem; }
.legal h1 { font-size: var(--step-3); margin-bottom: 24px; }
.legal h2 { font-size: var(--step-1); margin: 32px 0 8px; }
.legal p + p { margin-top: 10px; }

.legal ul { margin: 8px 0 0; padding-left: 1.2em; display: grid; gap: 4px; }
.legal p + ul, .legal ul + p { margin-top: 10px; }
.legal .ph { background: var(--accent-soft); color: var(--accent); border: 1px dashed var(--accent); border-radius: 4px; padding: 0 4px; }
.legal .stand { margin-top: 40px; color: var(--muted); font-size: var(--step--1); }

.back-link {
  color: var(--fg); text-decoration: none; font-size: 0.95rem; font-weight: 500;
  padding: 8px 12px; border-radius: 8px; white-space: nowrap;
}
.back-link:hover { background: var(--accent-soft); color: var(--accent); }
@media (max-width: 480px) { .back-link span { display: none; } .back-link { font-size: 1.2rem; padding: 6px 10px; } }

/* Kein automatisches Vergrößern der Schrift beim Drehen auf dem iPhone */
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
