:root {
  --bg: #14171c;
  --ink: #f2f4f7;
  --muted: #a9b0ba;
  --accent: #5cc9b3;
  --accent-2: #f0b35b;
  --card: #1c2128;
  --line: #2a313a;
  --shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  --header-bg: rgba(20, 23, 28, 0.88);
  --header-line: rgba(42, 49, 58, 0.9);
  --body-bg-1: #202731;
  --body-bg-2: #1a2b28;
  --body-bg-3: #2a2420;
  --input-bg: #12161c;
  --glow-a: rgba(92, 201, 179, 0.39);
  --glow-b: rgba(240, 179, 91, 0.22);
  --glow-c: rgba(94, 144, 255, 0.12);
  --glow-d: rgba(120, 255, 207, 0.14);
  --glow-e: rgba(111, 227, 255, 0.12);
  --glow-highlight: rgba(255, 255, 255, 0.08);
}

[data-theme='light'] {
  --bg: #f7f2ea;
  --ink: #0e1a2b;
  --muted: #546173;
  --accent: #0f5b4f;
  --accent-2: #d3872a;
  --card: #ffffff;
  --line: #d8d1c4;
  --shadow: 0 16px 40px rgba(14, 26, 43, 0.12);
  --header-bg: rgba(247, 242, 234, 0.8);
  --header-line: rgba(216, 209, 196, 0.6);
  --body-bg-1: #f1dfc4;
  --body-bg-2: #c7e1dd;
  --body-bg-3: #f7f2ea;
  --input-bg: #ffffff;
  --glow-a: rgba(15, 91, 79, 0.34);
  --glow-b: rgba(211, 135, 42, 0.18);
  --glow-c: rgba(14, 26, 43, 0.08);
  --glow-d: rgba(15, 91, 79, 0.12);
  --glow-e: rgba(15, 91, 79, 0.16);
  --glow-highlight: rgba(255, 255, 255, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Source Sans 3", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: radial-gradient(1200px 600px at 10% 5%, var(--body-bg-1) 0%, transparent 60%),
    radial-gradient(900px 500px at 90% 0%, var(--body-bg-2) 0%, transparent 55%),
    radial-gradient(700px 420px at 20% 85%, var(--body-bg-3) 0%, transparent 55%),
    var(--bg);
}

html {
  scroll-padding-top: 180px;
}

section[id] {
  scroll-margin-top: 180px;
}

a {
  color: inherit;
  text-decoration: none;
}

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

.container {
  width: min(1120px, 92vw);
  margin: 0 auto;
}

.header {
  position: sticky;
  top: 0;
  backdrop-filter: blur(14px);
  background: var(--header-bg);
  border-bottom: 1px solid var(--header-line);
  z-index: 10;
  overflow: hidden;
}

.header::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0), var(--glow-a), transparent 50%),
    radial-gradient(520px 200px at 10% 80%, var(--glow-a), transparent 80%),
    radial-gradient(520px 220px at 90% 20%, var(--glow-b), transparent 82%);
  opacity: 0.75;
  pointer-events: none;
}

.header::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, var(--glow-highlight), transparent 80%);
  opacity: 0.35;
  pointer-events: none;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  position: relative;
  z-index: 1;
}

.brand {
  font-family: "Libre Baskerville", "Times New Roman", serif;
  font-size: 1.4rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.brand-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.logo {
  display: block;
  width: 280px;
  height: auto;
  margin: 0 auto;
}

.logo-light {
  display: none;
}

[data-theme='light'] .logo-dark {
  display: none;
}

[data-theme='light'] .logo-light {
  display: block;
}

.header .logo {
  width: 220px;
  height: auto;
}

.footer .logo {
  width: 280px;
  height: auto;
  margin-top: -40px;
}

.nav-links {
  display: flex;
  gap: 18px;
  font-size: 0.95rem;
}

.nav-links a {
  padding: 6px 0;
  border-bottom: 2px solid transparent;
}

.nav-links a:hover,
.nav-links a:focus {
  border-color: var(--accent);
}

.hero {
  padding: 90px 0 60px;
}

.hero-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 32px;
  align-items: center;
}

.hero h1 {
  font-family: "Libre Baskerville", "Times New Roman", serif;
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  margin: 0 0 16px;
}

.hero p {
  font-size: 1.1rem;
  color: var(--muted);
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 22px;
  border-radius: 999px;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
  position: relative;
  overflow: hidden;
}

.button.secondary {
  background: transparent;
  color: var(--accent);
}

.button:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 24px rgba(15, 91, 79, 0.25);
  filter: saturate(1.15);
}

.button::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.35), transparent 55%);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.button:hover::after {
  opacity: 0.6;
}

.hero-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 28px;
  box-shadow: var(--shadow);
}

.hero-card h3 {
  margin-top: 0;
  font-size: 1.15rem;
}

.section {
  padding: 70px 0;
}

.section-title {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px;
  margin-bottom: 28px;
}

.section-title h2 {
  font-family: "Libre Baskerville", "Times New Roman", serif;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  margin: 0;
}

.section-title span {
  color: var(--muted);
  font-size: 0.95rem;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 22px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
}

.card h3 {
  margin: 0 0 10px;
}

.card p {
  color: var(--muted);
  line-height: 1.6;
}

.card ul {
  color: var(--muted);
  line-height: 1.6;
  padding-left: 1.2rem;
  margin: 0 0 1rem;
}

.card li {
  margin-bottom: 0.35rem;
}


.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(92, 201, 179, 0.12);
  color: var(--accent);
  border-radius: 999px;
  padding: 6px 14px;
  font-weight: 600;
  font-size: 0.85rem;
}

#projekte .card {
  display: flex;
  flex-direction: column;
}

#projekte .badge {
  margin-top: auto;
  align-self: flex-start;
}

.kpi {
  font-size: 2rem;
  font-weight: 700;
  margin: 12px 0 4px;
}

.split {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.form {
  display: grid;
  gap: 14px;
}

.form input,
.form textarea,
.form select {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  font-family: inherit;
  background: var(--input-bg);
  color: var(--ink);
}

.form textarea {
  resize: none;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--ink);
  cursor: pointer;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.theme-toggle:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: 0 12px 22px rgba(0, 0, 0, 0.22);
}

.phase-diagram {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 18px;
  position: relative;
}

.phase {
  padding: 18px;
  border-radius: 16px;
  border: 1px solid transparent;
  background: rgba(255, 255, 255, 0.03);
  position: relative;
}

.phase::after {
  content: '';
  position: absolute;
  top: 32px;
  right: -18px;
  width: 18px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
}

.phase:last-child::after {
  display: none;
}

.phase-step {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  border: 1px solid transparent;
  background: linear-gradient(135deg, #6fe3ff, #5e90ff);
  font-weight: 700;
  margin-bottom: 12px;
}

.phase h3 {
  margin: 0 0 8px;
}

.phase p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.phase:nth-child(1) {
  background: linear-gradient(135deg, rgba(111, 227, 255, 0.12), rgba(94, 144, 255, 0.08));
  border-color: rgba(111, 227, 255, 0.35);
}

.phase:nth-child(1) .phase-step {
  background: linear-gradient(135deg, #6fe3ff, #5e90ff);
}

.phase:nth-child(2) {
  background: linear-gradient(135deg, rgba(120, 255, 207, 0.12), rgba(78, 201, 153, 0.08));
  border-color: rgba(120, 255, 207, 0.35);
}

.phase:nth-child(2) .phase-step {
  background: linear-gradient(135deg, #78ffcf, #4ec999);
}

.phase:nth-child(3) {
  background: linear-gradient(135deg, rgba(255, 211, 105, 0.14), rgba(255, 140, 84, 0.1));
  border-color: rgba(255, 211, 105, 0.35);
}

.phase:nth-child(3) .phase-step {
  background: linear-gradient(135deg, #ffd369, #ff8c54);
}

.phase:nth-child(4) {
  background: linear-gradient(135deg, rgba(255, 140, 190, 0.14), rgba(214, 98, 255, 0.1));
  border-color: rgba(255, 140, 190, 0.35);
}

.phase:nth-child(4) .phase-step {
  background: linear-gradient(135deg, #ff8cbe, #d662ff);
}

.phase:nth-child(5) {
  background: linear-gradient(135deg, rgba(156, 245, 122, 0.14), rgba(69, 207, 119, 0.1));
  border-color: rgba(156, 245, 122, 0.35);
}

.phase:nth-child(5) .phase-step {
  background: linear-gradient(135deg, #9cf57a, #45cf77);
}

.form button {
  width: 100%;
}

.footer {
  padding: 40px 0 60px;
  backdrop-filter: blur(14px);
  background: var(--header-bg);
  border-top: 1px solid var(--header-line);
  color: var(--muted);
  font-size: 0.95rem;
  position: relative;
  overflow: hidden;
}

.footer-top {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 18px;
  position: relative;
  z-index: 1;
}

.footer::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0), var(--glow-a), transparent 50%),
    radial-gradient(520px 200px at 10% 80%, var(--glow-a), transparent 80%),
    radial-gradient(520px 220px at 90% 20%, var(--glow-b), transparent 82%);
  opacity: 0.75;
  pointer-events: none;
}

.footer::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, var(--glow-highlight), transparent 80%);
  opacity: 0.35;
  pointer-events: none;
}

.footer .footer-glow-band {
  display: none;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 24px;
  position: relative;
  z-index: 1;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(160px, 1fr));
  gap: 20px;
  align-items: start;
}

.footer-legal p {
  margin: 0 0 8px;
}

.footer-right {
  text-align: right;
  display: grid;
  gap: 12px;
  justify-items: end;
}

.footer-right p {
  margin: 0;
}

@media (max-width: 760px) {
  .nav {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .nav-links {
    flex-wrap: wrap;
  }
}
