:root {
  /* Farben von der Agile-Heart-Visitenkarte */
  --navy: #0e1829;
  --navy-2: #1a2640;
  --red: #a20030;
  --bg: #f4f5f7;
  --bg-alt: #e9ecf1;
  --surface: #ffffff;
  --ink: #0e1829;
  --ink-soft: #3c4659;
  --muted: #6b7486;
  --line: #d9dee6;
  --accent: #a20030;
  --radius: 6px;
  --shadow: 0 1px 2px rgba(14, 24, 41, .08), 0 6px 18px rgba(14, 24, 41, .06);
  --display: "Open Sans", Arial, Helvetica, sans-serif;
  --sans: Arial, Helvetica, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 15px/1.45 var(--sans);
  letter-spacing: -.01em;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
b { font-weight: 600; }

.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 24px; }
.wrap.narrow { max-width: 860px; }

/* Kopfzeile */
.topbar {
  position: sticky; top: 0; z-index: 10;
  background: var(--navy);
}
.topbar-inner { display: flex; align-items: center; gap: 24px; height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; flex-shrink: 0; }
.brand img { height: 30px; width: auto; }
.brand .wordmark { height: 16px; }
.nav { display: flex; gap: 4px; margin-left: auto; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.nav::-webkit-scrollbar { display: none; }
.nav a {
  color: #c5cbd6; text-decoration: none; font-family: var(--display); font-size: .82rem; font-weight: 500;
  padding: 6px 10px; white-space: nowrap; border-bottom: 2px solid transparent;
}
.nav a:hover { color: #fff; }
.nav a.active { color: #fff; border-bottom-color: var(--red); }

/* Hero */
.hero { padding: 64px 0 56px; background: var(--navy); color: #fff; }
.hero-inner { display: grid; grid-template-columns: 260px 1fr; gap: 48px; align-items: center; }
.portrait { margin: 0; position: relative; }
.portrait::before {
  content: ""; position: absolute; inset: 12px -12px -12px 12px;
  border-radius: var(--radius); background: var(--red);
}
.portrait img { position: relative; border-radius: var(--radius); width: 100%; aspect-ratio: 4 / 5; object-fit: cover; box-shadow: var(--shadow); }
h1 {
  font-family: var(--display); font-weight: 600; letter-spacing: 0;
  font-size: clamp(2rem, 4.6vw, 3rem); line-height: 1.1; margin: 0 0 8px; color: #fff;
}
.role { font-family: var(--display); font-size: 1.15rem; color: #d7dbe3; font-weight: 400; margin: 0 0 22px; padding-bottom: 18px; border-bottom: 2px solid #fff; max-width: 520px; }
.cert-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; color: #c5cbd6; }
.cert-list li { padding-left: 22px; position: relative; }
.cert-list li::before {
  content: ""; position: absolute; left: 0; top: .62em; width: 10px; height: 10px;
  border-radius: 50%; background: var(--red);
}
.cert-list b { color: #fff; }

/* Abschnitte */
.section { padding: 72px 0; }
.section.alt { background: var(--bg-alt); }
h2 {
  font-family: var(--display); font-weight: 600; letter-spacing: 0;
  font-size: clamp(1.45rem, 3vw, 1.9rem); line-height: 1.2; margin: 0 0 28px;
}
h2::after { content: ""; display: block; width: 48px; height: 3px; background: var(--accent); margin-top: 14px; border-radius: 2px; }
h3 { font-size: 1.15rem; line-height: 1.35; margin: 0 0 12px; }
h3 a { color: var(--ink); text-decoration-color: var(--accent); }
.where { font-weight: 400; color: var(--muted); font-size: .95rem; }

.prose p { margin: 0 0 1em; }
.lead { font-size: 1.05rem; color: var(--ink-soft); }
.lead b { color: var(--ink); }

/* Logos */
.logos {
  list-style: none; padding: 0; margin: 40px 0 0;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 28px 48px;
}
.logos img { height: 64px; width: auto; }

/* Lebenslauf */
.cv-list, .overview, .early { list-style: none; margin: 0; padding: 0; }
.cv-list li { display: grid; grid-template-columns: 130px 1fr; gap: 16px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.cv-list li:last-child { border-bottom: 0; }
.when { font-weight: 600; font-variant-numeric: tabular-nums; color: var(--ink); white-space: nowrap; }

/* Überblick */
.overview { position: relative; }
.overview::before { content: ""; position: absolute; left: 6px; top: 8px; bottom: 8px; width: 2px; background: var(--line); }
.overview li { position: relative; padding-left: 32px; }
.overview li::before {
  content: ""; position: absolute; left: 0; top: 20px; width: 14px; height: 14px; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--accent);
}
.overview a {
  display: grid; grid-template-columns: 170px 1fr; gap: 12px; padding: 12px 14px; margin: 2px 0;
  border-radius: 10px; text-decoration: none; color: var(--ink);
}
.overview a:hover { background: var(--surface); box-shadow: var(--shadow); }
.overview a:hover b { color: var(--red); }
.overview .when { color: var(--muted); font-weight: 500; }
.overview small { color: var(--muted); font-size: .9rem; }

/* Projekte im Detail */
.job {
  display: grid; grid-template-columns: 180px 1fr; gap: 32px;
  background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 32px; margin-bottom: 24px;
}
.job-when {
  font-weight: 600; color: var(--accent); font-variant-numeric: tabular-nums;
  position: sticky; top: 84px; align-self: start;
}
.job-body p, .job-body ul { margin: 0 0 1em; }
.job-body > :last-child { margin-bottom: 0; }
.job-body ul { padding-left: 1.2em; }
.job-body li { margin-bottom: .25em; }
.job-body li::marker { color: var(--accent); }
.facts {
  list-style: none; padding: 6px 18px !important; background: var(--surface);
  border: 1px solid var(--line); border-top: 3px solid var(--navy); border-radius: 4px;
  font-size: .95rem; color: var(--ink);
}
.facts li { display: grid; grid-template-columns: 120px 1fr; gap: 14px; padding: 8px 0; margin: 0 !important; border-bottom: 1px solid var(--line); }
.facts li:last-child { border-bottom: 0; }
.facts .k { font: 600 .72rem/1.6 var(--display); text-transform: uppercase; letter-spacing: .08em; color: var(--red); }
.facts .v { min-width: 0; }
.label { color: var(--ink); }

/* Vor Agilität */
.early li { display: grid; grid-template-columns: 170px 1fr; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.early li:last-child { border-bottom: 0; }
.early h3 { margin-bottom: 6px; font-size: 1.05rem; }
.early p { margin: 0; color: var(--ink-soft); }
.early .when { color: var(--muted); font-weight: 500; }

/* Tabelle */
.table-scroll { overflow-x: auto; background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); }
.trainings { width: 100%; border-collapse: collapse; font-size: .95rem; }
.trainings th, .trainings td { text-align: left; padding: 12px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
.trainings th { font-weight: 600; background: var(--navy); color: #fff; font-family: var(--display); }
.trainings tr:last-child td { border-bottom: 0; }
.trainings td:first-child { font-weight: 600; font-variant-numeric: tabular-nums; }
.trainings td:last-child { color: var(--ink-soft); }

/* Zertifikate */
.gallery { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 20px; }
.cert {
  all: unset; box-sizing: border-box; cursor: zoom-in; display: flex; flex-direction: column; height: 100%; width: 100%;
  background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden;
  transition: transform .2s, box-shadow .2s;
}
.cert:hover, .cert:focus-visible { transform: translateY(-3px); box-shadow: 0 2px 4px rgba(29,36,51,.08), 0 16px 32px rgba(29,36,51,.1); }
.cert:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.cert img { width: 100%; aspect-ratio: 4 / 3; object-fit: contain; background: #fff; padding: 10px; border-bottom: 1px solid var(--line); }
.cap { padding: 14px 16px 16px; display: grid; gap: 4px; font-size: .92rem; line-height: 1.4; }
.cap small { color: var(--muted); font-size: .85rem; }

dialog#lightbox { border: 0; padding: 0; background: transparent; max-width: 94vw; max-height: 92vh; }
dialog#lightbox::backdrop { background: rgba(20, 24, 33, .82); }
dialog#lightbox img { max-width: 94vw; max-height: 88vh; width: auto; border-radius: 8px; background: #fff; }
dialog#lightbox .close {
  position: fixed; top: 16px; right: 16px; width: 44px; height: 44px; border-radius: 50%; border: 0;
  background: #fff; color: var(--ink); font-size: 28px; line-height: 1; cursor: pointer;
}

/* Fußzeile */
.footer { background: var(--navy); color: #c5cbd6; padding: 40px 0; font-size: .9rem; }
.footer-logo { height: 110px; width: auto; }
.footer .wrap { display: grid; grid-template-columns: auto 1fr auto; align-items: start; gap: 32px 48px; }
.footer p { margin: 0 0 4px; }
.footer a { color: #fff; }

/* Mobil */
@media (max-width: 760px) {
  .wrap { padding: 0 16px; }
  .topbar-inner { gap: 12px; }
  .brand .wordmark { display: none; }
  .nav { margin-left: 0; }
  .hero { padding: 40px 0 32px; }
  .hero-inner { grid-template-columns: 1fr; gap: 32px; }
  .portrait { max-width: 220px; }
  .section { padding: 52px 0; }
  .cv-list li, .early li { grid-template-columns: 1fr; gap: 4px; }
  .overview a { grid-template-columns: 1fr; gap: 2px; }
  .job { grid-template-columns: 1fr; gap: 12px; padding: 22px 18px; }
  .job-when { position: static; }
  .facts li { grid-template-columns: 1fr; gap: 0; }
  .logos { gap: 20px 32px; }
  .logos img { height: 48px; }
}

/* Druck */
@media print {
  .topbar, .footer, dialog { display: none !important; }
  body { background: #fff; font-size: 11pt; }
  .section, .section.alt, .hero { background: #fff; padding: 20px 0; }
  .job { box-shadow: none; border: 1px solid var(--line); break-inside: avoid; }
  .job-when { position: static; }
  a { color: inherit; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

/* Sprachumschalter */
[hidden] { display: none !important; }
.lang-switch { display: flex; align-items: center; flex-shrink: 0; margin-left: 20px; padding-left: 20px; border-left: 1px solid rgba(255, 255, 255, .2); }
.lang-switch button {
  font: 600 .78rem/1 var(--display); letter-spacing: .12em; cursor: pointer;
  padding: 6px 2px; margin: 0 6px; border: 0; border-bottom: 1px solid transparent;
  background: none; color: #8f98a8;
}
.lang-switch button + button { position: relative; }
.lang-switch button + button::before { content: ""; position: absolute; left: -7px; top: 5px; bottom: 5px; width: 1px; background: rgba(255, 255, 255, .25); }
.lang-switch button:hover { color: #fff; }
.lang-switch button[aria-pressed="true"] { color: #fff; border-bottom-color: var(--red); }
.lang-switch button:focus-visible { outline: 1px solid #fff; outline-offset: 3px; }
.no-cookies { color: #8f98a8; }
@media print { .lang-switch { display: none; } }
@media (max-width: 760px) { .lang-switch { margin-left: 6px; padding-left: 8px; } }

/* Externe Links: öffnen in neuem Fenster, rotes Symbol dahinter */
main a[target="_blank"]::after {
  content: ""; display: inline-block; width: .78em; height: .78em; margin-left: .28em; vertical-align: -.04em;
  background: var(--red);
  -webkit-mask: var(--ext-icon) no-repeat center / contain; mask: var(--ext-icon) no-repeat center / contain;
}
:root { --ext-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M19 19H5V5h7V3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7h-2v7zM14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3h-7z'/%3E%3C/svg%3E"); }

/* Fußbereich: Adresse und Cookie-Hinweis */
.footer address { font-style: normal; margin: 0 0 4px; }
.footer a[href^="tel:"] { color: inherit; text-decoration: none; }
.no-cookies { display: flex; align-items: center; gap: 8px; }
.no-cookies svg { width: 18px; height: 18px; flex-shrink: 0; }
.footer-pdf { justify-self: center; }
.footer-pdf, .footer-info { margin-top: -4px; }
.pdf-title { display: flex; align-items: center; gap: 8px; }
.pdf-title .ico { width: 16px; height: 16px; flex-shrink: 0; position: relative; top: 1px; }
.pdf-links { padding-left: 0; }
.pdf-word { color: var(--red); font-weight: 700; }
.pdf-links a { text-decoration-color: var(--red); text-decoration-thickness: 2px; }
.pdf-ico { width: 15px; height: 15px; margin-left: 4px; vertical-align: -2px; color: #fff; opacity: .45; }
@media (max-width: 760px) {
  .footer .wrap { grid-template-columns: 1fr; gap: 24px; }
  .footer-pdf { justify-self: start; }
  .footer-pdf, .footer-info { margin-top: 0; }
}
