:root {
  --ink:        oklch(0.26 0.014 250);
  --muted:      oklch(0.52 0.013 250);
  --faint:      oklch(0.64 0.010 250);
  --line:       oklch(0.90 0.006 250);
  --line-soft:  oklch(0.94 0.005 250);
  --bg:         oklch(0.992 0.0025 250);
  --white:      #ffffff;

  /* Behandlungsbereich-Farben:
     cool-Slot = ROT (#FA1700) -> Allgemeinmedizin (links)
     warm-Slot = BLAU          -> Innere Medizin & Diabetologie (rechts) */
  --cool:       oklch(0.615 0.255 29);   /* #FA1700 */
  --cool-deep:  oklch(0.515 0.205 28);
  --cool-tint:  oklch(0.967 0.020 29);
  --cool-tint2: oklch(0.945 0.038 29);

  --warm:       oklch(0.52 0.120 248);
  --warm-deep:  oklch(0.44 0.115 250);
  --warm-tint:  oklch(0.975 0.018 248);
  --warm-tint2: oklch(0.955 0.028 248);

  --header-h: 84px;
  --footer-h: 92px;
  --pad: clamp(20px, 4vw, 56px);
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", "Menlo", "Consolas", monospace;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  line-height: 1.5;
}
a { color: inherit; text-decoration: none; }

.page {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

/* ---------- HEADER ---------- */
header {
  height: var(--header-h);
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 0 var(--pad);
  background: rgba(255,255,255,0.86);
  border-bottom: 1px solid var(--line-soft);
  position: relative;
  z-index: 40;
}
.brand { display: flex; align-items: center; gap: 14px; min-width: 0; }
.mark { flex: 0 0 auto; width: 38px; height: 38px; display: block; }
.brand-text { display: flex; flex-direction: column; min-width: 0; }
.brand-kicker {
  font-size: 12.1px; font-weight: 500; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--faint);
  font-family: var(--mono);
}
.brand-name {
  font-size: clamp(15.4px, 1.54vw, 18.15px); font-weight: 700;
  letter-spacing: -0.01em; color: var(--ink); white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis;
}

nav.desktop-nav { display: flex; align-items: center; gap: 4px; }
nav.desktop-nav a {
  font-size: 15.95px; font-weight: 500; color: var(--muted);
  padding: 9px 14px; border-radius: 8px;
  transition: color .18s ease, background .18s ease;
}
nav.desktop-nav a:hover { color: var(--ink); background: oklch(0.96 0.004 250); }
nav.desktop-nav a.active { color: var(--ink); }

/* ---------- NAV DROPDOWN ---------- */
.nav-dropdown { position: relative; display: flex; }
.nav-toggle {
  font: inherit; font-size: 15.95px; font-weight: 500; color: var(--muted);
  background: none; border: none; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px;
  padding: 9px 14px; border-radius: 8px;
  transition: color .18s ease, background .18s ease;
}
.nav-toggle .chev { width: 13px; height: 13px; transition: transform .22s ease; }
.nav-dropdown:hover .nav-toggle,
.nav-dropdown:focus-within .nav-toggle,
.nav-dropdown.open .nav-toggle { color: var(--ink); background: oklch(0.96 0.004 250); }
.nav-dropdown:hover .nav-toggle .chev,
.nav-dropdown:focus-within .nav-toggle .chev,
.nav-dropdown.open .nav-toggle .chev { transform: rotate(180deg); }

.dropdown-menu {
  position: absolute; top: 100%; left: 0; padding-top: 8px;
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
  z-index: 50;
}
.nav-dropdown:hover .dropdown-menu,
.nav-dropdown:focus-within .dropdown-menu,
.nav-dropdown.open .dropdown-menu {
  opacity: 1; visibility: visible; transform: translateY(0);
}
.dropdown-panel {
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  box-shadow: 0 18px 44px -22px oklch(0.40 0.03 250 / 0.45),
              0 2px 8px -4px oklch(0.40 0.03 250 / 0.18);
  padding: 6px; min-width: 252px;
  display: flex; flex-direction: column; gap: 2px;
}
.dropdown-panel a {
  display: flex; align-items: center; gap: 11px;
  padding: 11px 13px; border-radius: 9px;
  font-size: 15.95px; font-weight: 500; color: var(--muted); white-space: nowrap;
  transition: background .15s ease, color .15s ease;
}
.dropdown-panel a:hover { color: var(--ink); }
.dropdown-panel a:nth-child(1):hover { background: var(--cool-tint); }
.dropdown-panel a:nth-child(2):hover { background: var(--warm-tint); }
.dot { width: 9px; height: 9px; border-radius: 50%; flex: 0 0 auto; }
.dot--cool { background: var(--cool); }
.dot--warm { background: var(--warm); }

.menu-btn {
  display: none; width: 42px; height: 42px; border: 1px solid var(--line);
  background: #fff; border-radius: 10px; cursor: pointer; padding: 0;
  align-items: center; justify-content: center; flex-direction: column; gap: 4px;
}
.menu-btn span { display: block; width: 18px; height: 1.6px; background: var(--ink); border-radius: 2px; transition: transform .25s ease, opacity .2s ease; }
.menu-btn[aria-expanded="true"] span:nth-child(1) { transform: translateY(5.6px) rotate(45deg); }
.menu-btn[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-btn[aria-expanded="true"] span:nth-child(3) { transform: translateY(-5.6px) rotate(-45deg); }

.mobile-nav {
  display: none; position: absolute; top: 100%; left: 0; right: 0;
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line); padding: 8px var(--pad) 18px;
  flex-direction: column; z-index: 39;
}
.mobile-nav a {
  font-size: 17.6px; font-weight: 500; color: var(--ink);
  padding: 14px 4px; border-bottom: 1px solid var(--line-soft);
}
.mobile-nav a:last-child { border-bottom: none; }
.mobile-nav .mobile-sub {
  padding-left: 18px; font-size: 16.5px; color: var(--muted);
  display: flex; align-items: center; gap: 11px;
}
.mobile-nav.open { display: flex; }

/* ---------- SPLIT ---------- */
.split {
  flex: 1 1 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  position: relative;
  isolation: isolate;
}

.half {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: clamp(36px, 5vh, 72px) clamp(24px, 5vw, 88px);
  overflow: hidden;
  cursor: pointer;
}
/* full-bleed striped photo placeholder background */
.half-bg {
  position: absolute; inset: 0; z-index: 0;
  transition: transform .6s cubic-bezier(.2,.7,.2,1), filter .4s ease;
}
.half--cool .half-bg {
  background:
    repeating-linear-gradient(135deg,
      oklch(0.955 0.022 29) 0 13px,
      oklch(0.975 0.014 29) 13px 26px);
}
.half--warm .half-bg {
  background:
    repeating-linear-gradient(135deg,
      oklch(0.948 0.024 248) 0 13px,
      oklch(0.972 0.015 248) 13px 26px);
}
/* readability + center glow so the welcome box reads cleanly */
.half--cool::before {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: radial-gradient(120% 90% at 90% 50%, transparent 40%, oklch(0.99 0.006 29 / 0.55) 100%);
}
.half--warm::before {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: radial-gradient(120% 90% at 10% 50%, transparent 40%, oklch(0.99 0.006 248 / 0.55) 100%);
}
.half:hover .half-bg { transform: scale(1.03); }
.photo-tag {
  position: absolute; z-index: 3; bottom: 16px;
  font-family: var(--mono); font-size: 11.55px; letter-spacing: 0.04em;
  color: var(--faint); background: rgba(255,255,255,0.8);
  padding: 5px 9px; border-radius: 7px; border: 1px solid var(--line-soft);
}
.half--cool .photo-tag { left: 22px; }
.half--warm .photo-tag { right: 22px; }

/* divider line */
.split::before {
  content: ""; position: absolute; top: 8%; bottom: 8%; left: 50%;
  width: 1px; background: var(--line); transform: translateX(-0.5px);
  z-index: 5;
}

/* top accent reveal on hover */
.half::after {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  z-index: 4;
  transform: scaleX(0); transform-origin: center;
  transition: transform .4s cubic-bezier(.2,.7,.2,1);
}
.half--cool::after { background: var(--cool); }
.half--warm::after { background: var(--warm); }
.half:hover::after, .half:focus-visible::after { transform: scaleX(1); }
.half:focus-visible { outline: none; }

.half-inner {
  position: relative; z-index: 2;
  display: flex; flex-direction: column;
  max-width: clamp(220px, 30vw, 380px); width: 100%;
}
/* anchor content toward the outer edge so the central welcome box keeps a clear gutter */
.half--cool .half-inner { align-items: flex-start; text-align: left; margin-right: auto; }
.half--warm .half-inner { align-items: flex-end; text-align: right; margin-left: auto; }

.kicker {
  font-family: var(--mono); font-size: 12.65px; font-weight: 500;
  letter-spacing: 0.18em; text-transform: uppercase;
  margin: 0 0 14px;
}
.half--cool .kicker { color: var(--cool); }
.half--warm .kicker { color: var(--warm); }

.half h2 {
  margin: 0 0 12px; font-weight: 700; letter-spacing: -0.02em;
  font-size: clamp(28.6px, 2.86vw, 39.6px); line-height: 1.1; color: var(--ink);
  text-wrap: balance;
}
.half p {
  margin: 0 0 22px; color: var(--muted); font-size: clamp(16.5px, 1.32vw, 18.15px);
  max-width: 32ch; text-wrap: pretty;
}
.docs {
  display: flex; flex-direction: column; gap: 3px;
  margin: 0 0 26px; padding-top: 16px; border-top: 1px solid var(--line);
  width: 100%; max-width: 32ch;
}
.docs .docs-label {
  font-family: var(--mono); font-size: 11.55px; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--faint); margin-bottom: 5px;
}
.docs span.doc { font-size: 15.95px; font-weight: 600; color: var(--ink); letter-spacing: -0.005em; }

.cta {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: 15.95px; font-weight: 600; letter-spacing: 0.01em;
  padding: 12px 22px; border-radius: 999px;
  background: #fff; border: 1px solid var(--line);
  transition: gap .25s ease, border-color .25s ease, color .25s ease, box-shadow .25s ease;
}
.half--cool .cta { color: var(--cool-deep); }
.half--warm .cta { color: var(--warm-deep); }
.cta svg { width: 16px; height: 16px; transition: transform .25s ease; }
.half--cool:hover .cta { border-color: var(--cool); box-shadow: 0 6px 22px -12px oklch(0.615 0.21 29 / 0.5); }
.half--warm:hover .cta { border-color: var(--warm); box-shadow: 0 6px 22px -12px oklch(0.52 0.12 248 / 0.5); }
.half:hover .cta { gap: 13px; }
.half:hover .cta svg { transform: translateX(3px); }

/* ---------- WELCOME OVERLAY ---------- */
.welcome {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  z-index: 20;
  width: min(412px, 74vw);
  background: rgba(255,255,255,0.72);
  backdrop-filter: blur(16px) saturate(1.1);
  -webkit-backdrop-filter: blur(16px) saturate(1.1);
  border: 1px solid rgba(255,255,255,0.9);
  box-shadow: 0 30px 70px -34px oklch(0.4 0.03 250 / 0.45),
              0 2px 0 rgba(255,255,255,0.6) inset;
  border-radius: 20px;
  padding: clamp(30px, 4vw, 44px) clamp(28px, 4vw, 46px);
  text-align: center;
  opacity: 1;
  transition: opacity .85s ease;
}
.welcome .w-body { transition: transform .85s cubic-bezier(.2,.7,.2,1); }
.welcome.preload { opacity: 0; }
.welcome.preload .w-body { transform: translateY(16px); }
.welcome .w-mark { width: 40px; height: 40px; margin: 0 auto 18px; display: block; }
.welcome .w-kicker {
  font-family: var(--mono); font-size: 12.1px; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--faint); margin: 0 0 10px;
}
.welcome h1 {
  margin: 0 0 14px; font-size: clamp(33px, 3.74vw, 46.2px); font-weight: 700;
  letter-spacing: -0.025em; line-height: 1.04;
}
.welcome p {
  margin: 0 auto; color: var(--muted); font-size: clamp(16.5px, 1.43vw, 18.7px);
  max-width: 30ch; text-wrap: pretty;
}
.welcome .w-rule {
  width: 44px; height: 2px; margin: 20px auto 0;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--cool), var(--warm));
}
.welcome .w-note {
  margin: 18px auto 0; max-width: 30ch;
  font-size: clamp(15px, 1.3vw, 17px); line-height: 1.55; color: var(--muted); text-wrap: pretty;
}
.welcome .w-note a {
  color: var(--ink); font-weight: 600;
  text-decoration: underline; text-underline-offset: 2px;
}

/* ---------- FOOTER ---------- */
footer {
  flex: 0 0 auto;
  min-height: var(--footer-h);
  display: flex; align-items: center; justify-content: space-between;
  gap: 28px; flex-wrap: wrap;
  padding: 16px var(--pad);
  background: #fff;
  border-top: 1px solid var(--line-soft);
  position: relative; z-index: 30;
}
.partners { display: flex; align-items: center; gap: 24px; flex-wrap: nowrap; }
.partners .p-label {
  font-family: var(--mono); font-size: 11.55px; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--faint);
}
.partners img {
  height: 38px; width: auto; display: block;
  opacity: 0.82; transition: opacity .25s ease;
}
.partners img.tall { height: 46px; }
.partners a:hover img { opacity: 1; }

.foot-right {
  display: flex; align-items: center; gap: 22px; flex-wrap: wrap;
  justify-content: flex-end;
}
.foot-right .addr {
  font-size: 14.3px; color: var(--faint); white-space: nowrap;
}
.foot-links { display: flex; align-items: center; gap: 18px; }
.foot-links a {
  font-size: 14.85px; font-weight: 500; color: var(--muted);
  transition: color .18s ease;
}
.foot-links a:hover { color: var(--ink); }

/* Back-to-top button (mobile only) */
.to-top {
  display: none;
  align-items: center; justify-content: center; gap: 8px;
  font-family: inherit; font-size: 14.85px; font-weight: 600; color: var(--ink);
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  padding: 13px 22px; cursor: pointer;
  transition: border-color .2s ease, background .2s ease;
}
.to-top svg { width: 16px; height: 16px; }
.to-top:hover { border-color: var(--faint); background: oklch(0.98 0.003 250); }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 860px) {
  nav.desktop-nav { display: none; }
  .menu-btn { display: inline-flex; }

  .split {
    grid-template-columns: 1fr;
    grid-auto-rows: auto;
  }
  .split::before { display: none; }

  .half { padding: clamp(40px, 7vw, 64px) 24px; min-height: 46vw; align-items: center; }
  .half--cool .half-inner, .half--warm .half-inner {
    margin: 0 auto; max-width: 420px; align-items: center; text-align: center;
  }
  .welcome { order: 0; }
  .half--cool { order: 1; border-bottom: 1px solid var(--line-soft); }
  .half--warm { order: 2; }

  .welcome {
    position: static; transform: none;
    width: auto; margin: 0; border-radius: 0;
    background: var(--bg);
    backdrop-filter: none; -webkit-backdrop-filter: none;
    box-shadow: none; border: none;
    border-bottom: 1px solid var(--line-soft);
    padding: clamp(22px, 5vw, 32px) 24px;
  }
  .welcome .w-mark { display: none; }
}

@media (max-width: 560px) {
  .brand-name { white-space: normal; font-size: 14.85px; line-height: 1.25; }
  .brand-kicker { font-size: 11px; }
  footer { flex-flow: row wrap; align-items: center; justify-content: space-between; gap: 14px 8px; }
  .foot-right { justify-content: flex-end; }
  .to-top { display: inline-flex; flex: 1 0 100%; }
  /* hide the "PARTNER" label and address on mobile (keep partner logos) */
  .partners .p-label { display: none; }
  .foot-right .addr { display: none; }
  /* fit logos (left) + legal links (right) on one line */
  .partners { gap: 14px; }
  .partners img { height: 32px; }
  .partners img.tall { height: 40px; }
  .foot-links { gap: 12px; }
  .foot-links a { font-size: 13px; }
}

@media (prefers-reduced-motion: reduce) {
  .welcome, .welcome.preload { opacity: 1 !important; transition: none !important; }
  .welcome .w-body, .welcome.preload .w-body { transform: none !important; }
  .half, .cta, .cta svg, .half::after, .half-bg { transition: none; }
}
