:root {
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);

  --bg: #ffffff;
  --surface: #ffffff;
  --surface-2: #f3f6fa;
  --ink: #101823;
  --muted: #4d5a6a;
  --line: #dde3ea;
  --line-2: #c8d1dc;
  --accent: #1a56c4;
  --accent-hi: #1547a5;
  --accent-soft: #e8effb;
  --on-accent: #ffffff;

  --dark: #0f1c30;
  --dark-ink: #eef3fa;
  --dark-muted: #b3c1d3;
  --dark-line: #26374f;
  --dark-accent: #7ea9f5;

  --ph-a: #e4eaf2;
  --ph-b: #cfd9e6;
  --ph-ink: #45536a;

  --shadow: 0 1px 2px rgba(16, 24, 35, 0.04), 0 6px 18px rgba(16, 24, 35, 0.05);
  --radius: 8px;
  --shell: min(1200px, 100% - 2.5rem);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b111b;
    --surface: #111a27;
    --surface-2: #131d2c;
    --ink: #eef3fa;
    --muted: #a9b7c9;
    --line: #222f42;
    --line-2: #2e3d53;
    --accent: #7ea9f5;
    --accent-hi: #9cbdff;
    --accent-soft: #16233a;
    --on-accent: #08111f;

    --dark: #08111f;
    --dark-ink: #eef3fa;
    --dark-muted: #adbccf;
    --dark-line: #1e2d43;
    --dark-accent: #7ea9f5;

    --ph-a: #1a2536;
    --ph-b: #121b28;
    --ph-ink: #b7c5d6;

    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 6px 18px rgba(0, 0, 0, 0.3);
  }
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: clamp(1rem, 0.97rem + 0.16vw, 1.05rem);
  line-height: 1.65;
  overflow-x: hidden;
  overflow-wrap: break-word;
}

h1, h2, h3 {
  margin: 0;
  line-height: 1.1;
  letter-spacing: -0.02em;
  overflow-wrap: break-word;
}
h1 { font-size: clamp(2.1rem, 1.35rem + 3.2vw, 3.7rem); font-weight: 700; line-height: 1.06; }
h2 { font-size: clamp(1.6rem, 1.2rem + 1.7vw, 2.35rem); font-weight: 650; }
h3 { font-size: clamp(1.05rem, 1rem + 0.24vw, 1.18rem); font-weight: 650; line-height: 1.3; }

p { margin: 0 0 1rem; }
a { color: inherit; }
svg { max-width: 100%; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.gallery-back:focus-visible,
.section--band :focus-visible,
.site-footer :focus-visible {
  outline-color: var(--dark-accent);
}

.shell {
  width: var(--shell);
  margin-inline: auto;
}

.eyebrow {
  margin: 0 0 0.6rem;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}

.lead {
  font-size: clamp(1.05rem, 1rem + 0.4vw, 1.2rem);
  color: var(--muted);
  max-width: 46ch;
}

/* Back to gallery */
.gallery-back {
  display: block;
  padding: 0.5rem 1.25rem;
  background: #0b1626;
  color: #e6edf7;
  font-size: 13px;
  letter-spacing: 0.02em;
  text-decoration: none;
  transition: color 160ms var(--ease-out), background-color 160ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .gallery-back:hover { background: #12213a; color: #ffffff; }
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header__inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 72px;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  margin-right: auto;
  text-decoration: none;
  transition: transform 160ms var(--ease-out);
}
.brand:active { transform: scale(0.97); }
.brand__slot {
  display: grid;
  place-items: center;
  min-width: 74px;
  padding: 0.4rem 0.55rem;
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  background: var(--surface-2);
  color: var(--muted);
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.14em;
}
.brand__name { font-weight: 650; letter-spacing: -0.01em; }

.nav ul {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.nav a {
  display: block;
  padding: 0.5rem 0.85rem;
  border-radius: var(--radius);
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 550;
  text-decoration: none;
  transition: color 180ms var(--ease-out), background-color 180ms var(--ease-out), transform 160ms var(--ease-out);
}
.nav a:active { transform: scale(0.97); }
@media (hover: hover) and (pointer: fine) {
  .nav a:hover { color: var(--ink); background: var(--surface-2); }
  .nav__cta:hover { background: var(--accent-hi); color: var(--on-accent); }
}
.nav__cta {
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 600;
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 0.55rem;
  padding: 0.5rem 0.85rem;
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 160ms var(--ease-out), background-color 180ms var(--ease-out);
}
.nav-toggle:active { transform: scale(0.97); }
.nav-toggle__bars { display: grid; gap: 3px; }
.nav-toggle__bars i {
  display: block;
  width: 16px;
  height: 2px;
  background: currentColor;
  transition: transform 200ms var(--ease-in-out), opacity 150ms var(--ease-out);
}
.nav-toggle[aria-expanded="true"] .nav-toggle__bars i:nth-child(1) { transform: translateY(5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars i:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars i:nth-child(3) { transform: translateY(-5px) rotate(-45deg); }

/* Hero */
.hero { padding: clamp(2.5rem, 1.5rem + 4vw, 5rem) 0 clamp(2rem, 1rem + 3vw, 3.5rem); }
.hero__grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: clamp(1.5rem, 1rem + 2vw, 3rem);
  align-items: center;
}
.hero__body { grid-column: span 7; }
.hero__art { grid-column: span 5; }
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-top: 1.75rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.72rem 1.35rem;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform 160ms var(--ease-out), background-color 180ms var(--ease-out), color 180ms var(--ease-out), border-color 180ms var(--ease-out);
}
.btn:active { transform: scale(0.97); }
.btn--primary { background: var(--accent); color: var(--on-accent); }
.btn--ghost { background: var(--surface); color: var(--ink); border-color: var(--line-2); }
@media (hover: hover) and (pointer: fine) {
  .btn--primary:hover { background: var(--accent-hi); }
  .btn--ghost:hover { border-color: var(--accent); color: var(--accent); }
}

/* Image placeholders */
.ph {
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 3;
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  background:
    repeating-linear-gradient(135deg, transparent 0 14px, rgba(26, 86, 196, 0.05) 14px 15px),
    linear-gradient(150deg, var(--ph-a), var(--ph-b));
  box-shadow: var(--shadow);
}
.ph span {
  padding: 0.35rem 0.9rem;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ph-ink);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.ph--hero { aspect-ratio: 5 / 4; }

/* Figures band */
.figures {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin: clamp(2rem, 1.4rem + 2vw, 3.25rem) 0 0;
  padding: 0;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-2);
  overflow: hidden;
}
.figures li {
  padding: 1.25rem 1.4rem;
  border-left: 1px solid var(--line);
}
.figures li:first-child { border-left: 0; }
.figures__num {
  display: block;
  font-size: clamp(1.5rem, 1.2rem + 1.1vw, 2.1rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--accent);
}
.figures__label {
  display: block;
  font-size: 0.83rem;
  color: var(--muted);
}

/* Sections */
.section { padding: clamp(3rem, 2rem + 4vw, 5.5rem) 0; }
.section--alt { background: var(--surface-2); border-block: 1px solid var(--line); }
.section--band {
  background: var(--dark);
  color: var(--dark-ink);
}
.section--band .eyebrow { color: var(--dark-accent); }

.section__head {
  max-width: 44ch;
  margin-bottom: clamp(1.75rem, 1.2rem + 1.6vw, 2.75rem);
}

/* Services */
.services {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.25rem;
}
.card {
  grid-column: span 4;
  padding: 1.5rem 1.4rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  transition: transform 200ms var(--ease-out), border-color 200ms var(--ease-out), box-shadow 200ms var(--ease-out);
}
.card--wide {
  grid-column: span 12;
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: center;
  gap: 0 1.1rem;
  background: var(--accent-soft);
  border-color: color-mix(in srgb, var(--accent) 28%, transparent);
}
.card--wide p { margin: 0; }
.card--wide .card__icon { margin: 0; }
@media (hover: hover) and (pointer: fine) {
  .card:hover {
    transform: translateY(-3px);
    border-color: var(--line-2);
    box-shadow: 0 2px 4px rgba(16, 24, 35, 0.05), 0 14px 30px rgba(16, 24, 35, 0.08);
  }
}
.card__icon {
  width: 30px;
  height: 30px;
  margin-bottom: 0.9rem;
  color: var(--accent);
}
.card h3 { margin-bottom: 0.3rem; }
.card p { margin: 0; color: var(--muted); font-size: 0.94rem; }
.card--wide p { color: var(--muted); }

/* Process spine */
.steps {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.step {
  position: relative;
  grid-column: span 3;
  padding-top: 2.6rem;
  border-top: 1px solid var(--dark-line);
}
/* Marker sits on the top rule so the steps read as one line */
.step::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  width: 46px;
  height: 3px;
  background: var(--dark-accent);
  transform-origin: left center;
  transform: scaleX(0);
  transition: transform 260ms var(--ease-out) 120ms;
}
.step.is-in::before { transform: scaleX(1); }
.step__num {
  position: absolute;
  top: 0.9rem;
  left: 0;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--dark-accent);
}
.step h3 { margin-bottom: 0.35rem; }
.step p { margin: 0; color: var(--dark-muted); font-size: 0.94rem; }

/* Über uns */
.split {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: clamp(1.5rem, 1rem + 2vw, 3rem);
  align-items: center;
}
.split__text { grid-column: span 6; }
.split__text p { color: var(--muted); max-width: 42ch; }
.split__art { grid-column: span 6; }
.split__art .ph { aspect-ratio: 16 / 9; }

/* Contact */
.contact {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: clamp(1.5rem, 1rem + 2vw, 2.5rem);
  align-items: start;
}
.form {
  grid-column: span 7;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.field { display: grid; gap: 0.35rem; }
.field--wide { grid-column: 1 / -1; }
.field label { font-size: 0.85rem; font-weight: 600; color: var(--muted); }
.field input[type="text"],
.field input[type="email"],
.field textarea {
  width: 100%;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: 0.95rem;
  transition: border-color 180ms var(--ease-out), box-shadow 180ms var(--ease-out);
}
.field textarea { resize: vertical; }
.field input:focus,
.field textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
  outline: none;
}
.field--check {
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 0.6rem;
}
.field--check input { width: 1.05rem; height: 1.05rem; accent-color: var(--accent); }
.field--check label { font-weight: 450; }

.form__status {
  margin: 0.9rem 0 0;
  color: var(--accent);
  font-size: 0.92rem;
  font-weight: 600;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 200ms var(--ease-out), transform 200ms var(--ease-out);
}
.form__status.is-visible { opacity: 1; transform: none; }

.contact__info {
  grid-column: span 5;
  padding: 1.5rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.contact__info dl { display: grid; margin: 0; }
.contact__info dt {
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.contact__info dd {
  margin: 0.15rem 0 1.1rem;
  padding-bottom: 1.1rem;
  border-bottom: 1px solid var(--line);
  font-weight: 550;
}
.contact__info dd:last-child { margin-bottom: 0; padding-bottom: 0; border-bottom: 0; }

/* Footer */
.site-footer {
  padding: 1.75rem 0;
  background: var(--dark);
  color: var(--dark-muted);
}
.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.site-footer__brand { margin: 0; color: var(--dark-ink); font-weight: 650; }
.site-footer ul {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.92rem;
}
.site-footer a {
  text-decoration: none;
  transition: color 180ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .site-footer a:hover { color: var(--dark-ink); }
}

/* Reveal */
.reveal {
  opacity: 0;
  transform: translateY(14px) scale(0.985);
  transition: opacity 240ms var(--ease-out) var(--delay, 0ms), transform 240ms var(--ease-out) var(--delay, 0ms);
}
.reveal.is-in { opacity: 1; transform: none; }

/* Breakpoints */
@media (max-width: 900px) {
  .hero__body, .hero__art,
  .split__text, .split__art { grid-column: span 12; }
  .card { grid-column: span 6; }
  .step { grid-column: span 6; }
  .form, .contact__info { grid-column: span 12; }
}

@media (max-width: 780px) {
  .nav-toggle { display: inline-flex; }
  .nav {
    flex-basis: 100%;
    display: none;
    padding-bottom: 0.9rem;
  }
  .nav.is-open { display: block; }
  .nav ul { flex-direction: column; align-items: stretch; gap: 0.15rem; }
  .nav a { padding: 0.65rem 0.85rem; }
  .nav__cta { text-align: center; margin-top: 0.35rem; }
  .figures { grid-template-columns: repeat(2, 1fr); }
  .figures li:nth-child(3) { border-left: 0; }
  .figures li:nth-child(n + 3) { border-top: 1px solid var(--line); }
}

@media (max-width: 560px) {
  :root { --shell: min(1200px, 100% - 1.75rem); }
  .card, .card--wide, .step { grid-column: span 12; }
  .card--wide { grid-template-columns: auto 1fr; }
  .form { grid-template-columns: 1fr; }
  .field { grid-column: 1 / -1; }
  .hero__actions .btn { flex: 1 1 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 150ms !important;
    transition-property: opacity, color, background-color, border-color !important;
    transition-delay: 0ms !important;
  }
  .reveal { transform: none; }
  .step::before { transform: scaleX(1); }
}
