/* ==========================================================================
   Blue Logix GmbH — zentrales Stylesheet
   Farben, Schriften und Abstände sind als CSS-Variablen oben definiert.
   Wer nur Farben/Schriftgrößen ändern möchte, muss nur den :root-Block
   unten anpassen.
   ========================================================================== */

:root {
  /* Marken-Farben (aus dem Blue-Logix-Logo abgeleitet) */
  --navy: #0b2a6b;          /* dunkles Blau – Überschriften, "BLUE" im Logo */
  --blue: #0b5fff;          /* helles Markenblau – Buttons, Links, Akzente */
  --blue-light: #4fc3ff;    /* helleres Blau – Verlauf, dekorativer Ring */
  --ink: #12151a;           /* fast Schwarz – Fließtext, "LOGIX" im Logo */
  --muted: #5b6472;         /* gedämpftes Grau-Blau – Nebentext */
  --bg: #ffffff;
  --bg-alt: #f3f6fb;        /* sehr helles Blaugrau für Wechsel-Sektionen */
  --bg-dark: #0b1830;       /* dunkles Navy für Kontrast-Sektionen */
  --line: #e0e5ee;          /* Trennlinien / Rahmen */
  --line-dark: rgba(255,255,255,0.14);

  --font-head: "Space Grotesk", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Inter", "Helvetica Neue", Arial, sans-serif;

  --max-width: 1180px;
  --radius: 10px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-head);
  color: var(--navy);
  line-height: 1.15;
  margin: 0 0 0.5em 0;
  font-weight: 600;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.1rem, 4vw, 3.2rem); font-weight: 700; }
h2 { font-size: clamp(1.6rem, 2.6vw, 2.2rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em 0; max-width: 68ch; }
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
ul { padding-left: 1.2em; }
img { max-width: 100%; display: block; }

:focus-visible {
  outline: 3px solid var(--blue-light);
  outline-offset: 2px;
}

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.section { padding: 88px 0; }
.section--tight { padding: 56px 0; }
.section--alt { background: var(--bg-alt); }
.section--dark { background: var(--bg-dark); color: #dbe4f5; }
.section--dark h2, .section--dark h3 { color: #fff; }
.section--dark p, .section--dark li { color: #b7c4dd; }
.section--dark a { color: var(--blue-light); }

.eyebrow {
  display: inline-block;
  font-size: 0.85rem;
  color: var(--blue);
  font-weight: 600;
  margin-bottom: 0.6em;
}

.lead {
  font-size: 1.2rem;
  color: var(--muted);
  max-width: 62ch;
}

.section--dark .lead { color: #c3cfe6; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.98rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease, color .15s ease;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }

.btn-primary {
  background: var(--blue);
  color: #fff;
}
.btn-primary:hover { background: var(--navy); color: #fff; }

.btn-outline {
  background: transparent;
  border-color: var(--line);
  color: var(--navy);
}
.btn-outline:hover { border-color: var(--blue); color: var(--blue); }

.section--dark .btn-outline { border-color: var(--line-dark); color: #fff; }
.section--dark .btn-outline:hover { border-color: var(--blue-light); color: var(--blue-light); }

/* ---------- Header / Navigation ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 84px;
}

.brand { display: flex; align-items: center; flex-shrink: 0; }
.brand-logo { height: 63px; width: auto; }

.site-nav ul {
  list-style: none;
  display: flex;
  gap: 10px;
  margin: 0;
  padding: 0;
  align-items: center;
}

.site-nav > ul > li { position: relative; }

.site-nav > ul > li > a {
  color: var(--navy);
  font-weight: 500;
  font-size: 0.98rem;
  padding: 10px 20px;
  display: inline-block;
  background: #e8f0ff;
  border-radius: 999px;
  transition: background 0.15s ease, color 0.15s ease;
}
.site-nav > ul > li > a:hover { background: #d6e6ff; color: var(--blue); text-decoration: none; }
.site-nav a.active { background: var(--blue); color: #fff; }
.site-nav a.active:hover { background: var(--navy); color: #fff; }

/* "Dienstleistungen"-Eintrag: Link + separate Klick-Schaltfläche für das
   Untermenü. Der Link navigiert normal zur Übersichtsseite; die kleine
   Pfeil-Schaltfläche daneben öffnet/schließt nur das Untermenü. */
.has-sub {
  display: flex;
  align-items: center;
  gap: 6px;
}

.sub-toggle {
  background: #e8f0ff;
  border: none;
  border-radius: 50%;
  width: 34px;
  height: 34px;
  margin: 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--navy);
  flex-shrink: 0;
  transition: background 0.15s ease;
}
.sub-toggle:hover { background: #d6e6ff; }
.sub-toggle::after {
  content: "";
  width: 6px;
  height: 6px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
  transition: transform 0.15s ease;
}
.has-sub.open .sub-toggle::after { transform: rotate(-135deg); }

.sub-nav {
  display: none;
  position: absolute;
  top: 100%;
  left: -16px;
  margin-top: 10px;
  background: #cfe0ff;
  border: 1px solid #b7d1ff;
  border-radius: var(--radius);
  box-shadow: 0 12px 32px rgba(11,42,107,0.16);
  padding: 8px;
  min-width: 240px;
  flex-direction: column;
  gap: 4px;
  z-index: 50;
}
/* Hinweis: Ob das Untermenü sichtbar ist, wird ausschließlich per
   JavaScript direkt am Element gesteuert (style="display:none/flex"),
   nicht über diese Stylesheet-Regel. Das macht das Verhalten unabhängig
   von Hover-Zuständen und von zwischengespeicherten alten CSS-Dateien. */

.sub-nav li a {
  display: block;
  padding: 10px 16px;
  border-radius: 999px;
  color: var(--navy);
  font-size: 0.94rem;
  font-weight: 500;
  background: transparent;
}
.sub-nav li a:hover { background: #b7d1ff; color: var(--navy); text-decoration: none; }
.sub-nav li a.active { background: var(--navy); color: #fff; }

.header-cta { flex-shrink: 0; }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--navy);
  border-radius: 2px;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 50px 0 50px;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}

.hero-media {
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  aspect-ratio: 4/3.1;
}
.hero-media img { width: 100%; height: 100%; object-fit: cover; }

.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, rgba(11,42,107,0.35), rgba(11,95,255,0.05) 55%);
}

.hero-actions {
  display: flex;
  gap: 14px;
  margin-top: 1.6em;
  flex-wrap: wrap;
}

/* decorative ring — echoes the logo's circle motif */
.ring-accent {
  position: absolute;
  border-radius: 50%;
  border: 26px solid transparent;
  border-top-color: var(--blue);
  border-right-color: var(--blue-light);
  opacity: 0.16;
  pointer-events: none;
}

.page-hero {
  padding: 56px 0 64px;
  border-bottom: 1px solid var(--line);
  background: var(--bg-alt);
}
.page-hero .eyebrow { margin-bottom: 0.8em; }

/* ---------- Grids & Cards ---------- */
.grid {
  display: grid;
  gap: 28px;
}
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px;
  background: #fff;
}
.section--alt .card { background: #fff; }
.section--dark .card {
  background: rgba(255,255,255,0.04);
  border-color: var(--line-dark);
}

.card h3 { margin-bottom: 0.5em; }
.card p:last-child { margin-bottom: 0; }

.icon-badge {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 2px solid var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  color: var(--blue);
  font-family: var(--font-head);
  font-weight: 700;
}

.service-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: #fff;
}
.service-card img { height: 190px; object-fit: cover; width: 100%; }
.service-card-body { padding: 26px 28px 28px; display: flex; flex-direction: column; flex: 1; }
.service-card-body p { flex: 1; }
.service-card-body .btn { align-self: flex-start; margin-top: 12px; }

/* ---------- Stats ---------- */
.stat-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-top: 40px;
}
.stat { text-align: left; border-top: 3px solid var(--blue); padding-top: 14px; }
.stat .num { font-family: var(--font-head); font-size: 2.1rem; font-weight: 700; color: var(--navy); display: block; }
.section--dark .stat .num { color: #fff; }
.stat .label { color: var(--muted); font-size: 0.95rem; }
.section--dark .stat .label { color: #b7c4dd; }

/* ---------- Numbered steps (used only for genuine sequences) --------- */
.steps { display: flex; flex-direction: column; gap: 0; }
.step {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 20px;
  padding: 26px 0;
  border-top: 1px solid var(--line);
}
.section--dark .step { border-top-color: var(--line-dark); }
.step:last-child { }
.step-num {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.3rem;
  color: var(--blue);
}

/* ---------- Two-column content blocks ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
.split img { border-radius: 14px; width: 100%; height: 100%; object-fit: cover; }
.split.reverse .split-media { order: 2; }

.tag-list { display: flex; flex-wrap: wrap; gap: 10px; padding: 0; list-style: none; margin: 1.2em 0; }
.tag-list li {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 16px;
  font-size: 0.9rem;
  color: var(--navy);
  background: var(--bg-alt);
}
.section--dark .tag-list li { border-color: var(--line-dark); background: rgba(255,255,255,0.05); color: #dbe4f5; }

.check-list { list-style: none; padding: 0; margin: 1.2em 0; }
.check-list li {
  position: relative;
  padding-left: 30px;
  margin-bottom: 12px;
}
.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid var(--blue);
}
.check-list li::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 9px;
  width: 8px;
  height: 4px;
  border-left: 2px solid var(--blue);
  border-bottom: 2px solid var(--blue);
  transform: rotate(-45deg);
}

/* ---------- Quote / callout ---------- */
.callout {
  border-left: 3px solid var(--blue);
  padding: 6px 0 6px 28px;
  margin: 0;
}
.callout p { font-size: 1.3rem; color: var(--navy); font-family: var(--font-head); font-weight: 500; }

/* ---------- Logos strip ---------- */
.logo-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  align-items: center;
  margin-top: 30px;
}
.logo-strip .logo-slot {
  height: 40px;
  padding: 0 18px;
  display: flex;
  align-items: center;
  color: var(--muted);
  font-family: var(--font-head);
  font-weight: 600;
  border: 1px dashed var(--line);
  border-radius: 8px;
}

/* ---------- CTA band ---------- */
.cta-band {
  border-radius: 20px;
  background: linear-gradient(135deg, var(--navy), #133a94 60%, var(--blue));
  color: #fff;
  padding: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}
.cta-band h2 { color: #fff; margin-bottom: 0.3em; }
.cta-band p { color: #cfe0ff; margin-bottom: 0; }
.cta-band .btn-primary { background: #fff; color: var(--navy); }
.cta-band .btn-primary:hover { background: var(--bg-alt); }

/* ---------- Forms ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-grid .full { grid-column: 1 / -1; }
label { display: block; font-weight: 600; font-size: 0.92rem; margin-bottom: 6px; color: var(--navy); }

.field-error {
  display: none;
  color: #c0392b;
  font-size: 0.85rem;
  margin-top: 6px;
}
.field-error.visible { display: block; }
input.invalid, textarea.invalid, select.invalid {
  border-color: #c0392b;
}
input.invalid:focus, textarea.invalid:focus, select.invalid:focus {
  box-shadow: 0 0 0 3px rgba(192,57,43,0.15);
}
.form-banner {
  display: none;
  background: #fdecea;
  border: 1px solid #f3b8b2;
  color: #c0392b;
  padding: 14px 18px;
  border-radius: 8px;
  font-size: 0.95rem;
  margin-bottom: 20px;
}
.form-banner.visible { display: block; }

input, textarea, select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 1rem;
  background: #fff;
  color: var(--ink);
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(11,95,255,0.15);
}
textarea { min-height: 140px; resize: vertical; }

.contact-info-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px;
  background: var(--bg-alt);
}
.contact-info-card h3 { margin-top: 1.2em; font-size: 1rem; color: var(--muted); text-transform: none; }
.contact-info-card h3:first-child { margin-top: 0; }
.contact-info-card p { margin-bottom: 0.3em; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--bg-dark);
  color: #b7c4dd;
  padding-top: 64px;
}
.footer-inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 36px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--line-dark);
}
.footer-logo { height: 51px; margin-bottom: 16px; filter: brightness(0) invert(1); }
.footer-brand p { font-size: 0.94rem; color: #94a4c4; }
.footer-col h3 { color: #fff; font-size: 0.95rem; margin-bottom: 1em; }
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 10px; }
.footer-col a { color: #b7c4dd; font-size: 0.94rem; }
.footer-col a:hover { color: var(--blue-light); }
address { font-style: normal; font-size: 0.94rem; }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding: 22px 0;
  font-size: 0.88rem;
  color: #7b8bab;
}
.legal-links { list-style: none; display: flex; gap: 20px; padding: 0; margin: 0; }
.legal-links a { color: #7b8bab; }
.legal-links a:hover { color: var(--blue-light); }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-media { order: -1; }
  .split { grid-template-columns: 1fr; }
  .split .split-media { order: -1 !important; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 720px) {
  .site-nav, .header-cta { display: none; }
  .nav-toggle { display: flex; }
  .site-header.nav-open .site-nav {
    display: block;
    position: absolute;
    top: 84px;
    left: 0;
    right: 0;
    background: #fff;
    border-bottom: 1px solid var(--line);
    padding: 12px 24px 24px;
  }
  .site-header.nav-open .site-nav ul { flex-direction: column; gap: 8px; align-items: stretch; }
  .site-header.nav-open .site-nav > ul > li > a { display: block; text-align: left; }
  .has-sub { flex-wrap: wrap; }
  .site-header.nav-open .sub-nav[style*="flex"] {
    position: static;
    box-shadow: none;
    border: none;
    padding-left: 12px;
    width: 100%;
  }
  .site-header.nav-open .header-cta {
    display: inline-flex;
    margin: 14px 24px 20px;
  }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .cta-band { padding: 36px; flex-direction: column; text-align: left; }
  .section { padding: 60px 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn { transition: none; }
}
