/* =================================================================
   Service365 Verwaltung – Design System
   ================================================================= */

:root {
  /* Palette – pure white + midnight navy only */
  --bg:           #ffffff;
  --bg-soft:      #f4f6fa;
  --bg-card:      #ffffff;
  --bg-light:     #ffffff;
  --bg-warm:      #f4f6fa;
  --bg-dark:      #0f1a2b;
  --bg-dark-2:    #182640;

  --ink:          #0f1a2b;
  --ink-2:        #4a5568;
  --ink-3:        #8b95a5;
  --ink-on-dark:  #ffffff;
  --ink-on-dark-2:#a8b1c2;

  --line:         #e2e6ee;
  --line-strong:  #c3c9d6;
  --line-dark:    rgba(255, 255, 255, 0.14);

  --accent:       #2d4a6b;
  --accent-hover: #1d3552;
  --accent-soft:  #e8edf2;
  --champagne:    #8b95a5;

  --font-display: 'Manrope', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', sans-serif;
  --font-body:    'Manrope', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', sans-serif;
  --font-mono:    'JetBrains Mono', ui-monospace, SFMono-Regular, monospace;

  --container:    1320px;
  --gutter:       32px;
  --radius:       0;
  --radius-lg:    0;

  --ease:         cubic-bezier(0.2, 0.7, 0.2, 1);
}

  /* Sizing */
  --container:    1240px;
  --gutter:       24px;
  --radius:       4px;
  --radius-lg:    10px;

  /* Motion */
  --ease:         cubic-bezier(0.2, 0.7, 0.2, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { overflow-x: hidden; max-width: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

/* ---------- Layout primitives ---------- */
.wrap {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
  box-sizing: border-box;
}
.wrap-narrow {
  width: 100%;
  max-width: 880px;
  margin: 0 auto;
  padding: 0 var(--gutter);
  box-sizing: border-box;
}

/* ---------- Typography ---------- */
.eyebrow {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 0 0 28px;
  display: inline-flex;
  align-items: center;
  gap: 14px;
}
.eyebrow::before {
  content: '';
  width: 32px;
  height: 1px;
  background: var(--ink);
}

.display {
  font-family: var(--font-display);
  font-weight: 300;
  font-style: normal;
  letter-spacing: -0.035em;
  line-height: 1.05;
  color: var(--ink);
  margin: 0;
}
.display-xl { font-size: clamp(44px, 6.8vw, 92px); }
.display-lg { font-size: clamp(36px, 5vw, 64px); }
.display-md { font-size: clamp(28px, 3.6vw, 44px); }

h1, h2, h3, h4 { color: var(--ink); margin: 0; }
.h-section {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(36px, 4.4vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.035em;
  margin: 0 0 24px;
  color: var(--ink);
}
.h-sub {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 18px;
  line-height: 1.4;
  letter-spacing: -0.005em;
}
.lede {
  font-size: clamp(17px, 1.5vw, 20px);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 60ch;
}
.text-mono {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 16px 28px;
  border-radius: 0;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: all 0.3s var(--ease);
  border: 1px solid transparent;
  white-space: nowrap;
}
.btn-primary {
  background: var(--bg-dark);
  color: var(--ink-on-dark);
  border-color: var(--bg-dark);
}
.btn-primary:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--ink-on-dark);
}
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--ink-2);
}
.btn-ghost:hover {
  background: var(--bg-dark);
  color: var(--ink-on-dark);
  border-color: var(--bg-dark);
}
.btn-light {
  background: var(--bg);
  color: var(--ink);
  border-color: var(--bg);
}
.btn-light:hover { background: transparent; color: var(--bg); border-color: var(--bg); }
.btn-arrow::after {
  content: '→';
  font-family: var(--font-body);
  transition: transform 0.3s var(--ease);
}
.btn-arrow:hover::after { transform: translateX(6px); }

/* ---------- Header ---------- */
.topbar {
  background: var(--bg);
  color: var(--ink-2);
  font-size: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  letter-spacing: 0.04em;
}
.topbar .wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}
.topbar a { color: var(--ink); }
.topbar-left { display: flex; gap: 28px; align-items: center; white-space: nowrap; }
.topbar-right { display: flex; gap: 28px; align-items: center; white-space: nowrap; }
.topbar-dot {
  width: 6px;
  height: 6px;
  background: #4caf50;
  border-radius: 50%;
  display: inline-block;
  margin-right: 10px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
}
.brand {
  display: flex;
  align-items: baseline;
  gap: 14px;
  font-weight: 600;
  letter-spacing: 0.04em;
  font-size: 14px;
  text-transform: uppercase;
}
.brand-mark {
  width: 44px;
  height: 44px;
  border-radius: 0;
  background: transparent;
  display: grid;
  place-items: center;
  align-self: center;
  overflow: visible;
}
.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.footer-brand .brand-mark {
  width: 72px;
  height: 72px;
  background: transparent;
  overflow: visible;
  align-self: center;
}
.footer-brand .brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: none;
  display: block;
}
.footer-brand .brand-name {
  font-size: 18px;
}
.brand-name { line-height: 1.2; }
.brand-name small {
  display: block;
  font-size: 10px;
  font-weight: 400;
  color: var(--ink-3);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-top: 4px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}
.nav-links a {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-2);
  transition: color 0.2s;
  white-space: nowrap;
}
.nav-links a:hover, .nav-links a.active { color: var(--ink); }
.nav-cta { display: flex; gap: 12px; align-items: center; }

.mobile-toggle {
  display: none;
  background: none;
  border: 0;
  padding: 8px;
}
.mobile-toggle span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--ink);
  margin: 5px 0;
  transition: 0.3s;
}

/* ---------- Sections ---------- */
.section {
  padding: clamp(64px, 9vw, 120px) 0;
}
.section-tight { padding: clamp(48px, 6vw, 80px) 0; }
.section-dark {
  background: var(--bg-dark);
  color: var(--ink-on-dark);
}
.section-dark .h-section,
.section-dark h1, .section-dark h2, .section-dark h3 { color: var(--ink-on-dark); }
.section-dark .lede { color: var(--ink-on-dark-2); }
.section-dark .eyebrow { color: var(--ink-on-dark-2); }
.section-dark .eyebrow::before { background: var(--ink-on-dark-2); }

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 40px;
  margin-bottom: 56px;
  flex-wrap: wrap;
}
.section-head .lede { margin-top: 8px; }
.section-head-stack { max-width: 720px; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--bg-dark);
  color: var(--ink-on-dark-2);
  padding: 80px 0 32px;
  font-size: 14px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 64px;
}
.footer-col h4 {
  color: var(--ink-on-dark);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin: 0 0 18px;
  position: relative;
}
.footer-col h4 .fc-toggle { display: none; }
.footer-col ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.footer-col a { color: var(--ink-on-dark-2); transition: color 0.2s; }
.footer-col a:hover { color: var(--ink-on-dark); }
.footer-brand { display: flex; gap: 14px; align-items: center; margin-bottom: 20px; }
.footer-brand .brand-mark { background: transparent; color: var(--ink-on-dark); width: 72px; height: 72px; overflow: visible; }
.footer-brand .brand-mark img { width: 100%; height: 100%; object-fit: contain; display: block; }
.footer-brand .brand-name { color: var(--ink-on-dark); font-size: 18px; font-weight: 700; align-self: center; }
.footer-bottom {
  border-top: 1px solid var(--line-dark);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 13px;
  color: var(--ink-on-dark-2);
}
.footer-legal { display: flex; gap: 20px; flex-wrap: wrap; }

/* ---------- Cards ---------- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: all 0.3s var(--ease);
}
.card:hover {
  border-color: var(--line-strong);
  transform: translateY(-2px);
}

/* ---------- Utility ---------- */
.divider { height: 1px; background: var(--line); border: 0; margin: 0; }
.kbd-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  color: var(--ink-2);
  font-weight: 500;
}
.list-clean { list-style: none; padding: 0; margin: 0; }
.text-center { text-align: center; }

/* ---------- CTA Band (shared across pages) ---------- */
.cta-band {
  background: var(--bg-warm);
  color: var(--ink);
  padding: clamp(80px, 10vw, 140px) 0 clamp(96px, 12vw, 160px);
  text-align: center;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.cta-band .eyebrow { color: var(--ink-3); }
.cta-band .eyebrow::before { background: var(--ink-3); }
.cta-band .display, .cta-band h2 { color: var(--ink); margin-top: 20px; }
.cta-band .lede { color: var(--ink-2); margin: 24px auto 40px; max-width: 50ch; }
.cta-band .hero-actions { justify-content: center; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
@media (max-width: 600px) {
  .hero-actions { flex-direction: column; gap: 12px; align-items: center; }
  .hero-actions .btn { width: auto; justify-content: center; }
}
.cta-band .btn-primary {
  background: var(--bg-dark);
  color: var(--ink-on-dark);
  border-color: var(--bg-dark);
}
.cta-band .btn-primary:hover {
  background: var(--accent);
  color: var(--ink-on-dark);
  border-color: var(--accent);
}
.cta-band .btn-ghost {
  color: var(--ink);
  border-color: var(--ink-2);
}
.cta-band .btn-ghost:hover {
  background: var(--bg-dark);
  color: var(--ink-on-dark);
  border-color: var(--bg-dark);
}

/* ---------- FAQ accordion (global) ---------- */
.faq-list {
  margin-top: 24px;
}
.faq-item {
  border-top: 1px solid var(--line);
}
.faq-list .faq-item:last-of-type { border-bottom: 1px solid var(--line); }
.faq-q {
  width: 100%;
  text-align: left;
  background: transparent;
  border: 0;
  padding: 24px 0;
  font: inherit;
  font-family: var(--font-body);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.005em;
  color: var(--ink);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  cursor: pointer;
  transition: color 0.2s var(--ease);
}
.faq-q:hover { color: var(--accent); }
.faq-q .plus {
  width: 22px; height: 22px;
  position: relative; flex-shrink: 0;
}
.faq-q .plus::before, .faq-q .plus::after {
  content: '';
  position: absolute;
  background: var(--ink);
  top: 50%; left: 50%;
}
.faq-q .plus::before { width: 12px; height: 1.5px; transform: translate(-50%, -50%); }
.faq-q .plus::after  { width: 1.5px; height: 12px; transform: translate(-50%, -50%); transition: transform 0.3s var(--ease); }
.faq-item.open .faq-q .plus::after { transform: translate(-50%, -50%) scaleY(0); }
.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s var(--ease);
  font-size: 16px;
  color: var(--ink-2);
  line-height: 1.65;
}
.faq-a-inner {
  padding: 0 0 24px;
  max-width: 70ch;
}
.faq-item.open .faq-a { max-height: 600px; }

/* Reset prose ul styles inside FAQ */
.prose .faq-list, .prose .faq-list ul { padding: 0; }
.prose .faq-list .faq-item { padding: 0; }
.prose .faq-list .faq-item::before { content: none; }

/* ---------- Reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
  will-change: opacity, transform;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.section-light { background: var(--bg-light); }
.section-cream { background: var(--bg); }
.section-soft  { background: var(--bg-soft); }

/* ---------- Process grid (4-step layouts on dark sections) ---------- */
.process-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  margin-top: 64px;
  border-top: 1px solid var(--line-dark);
}
.process-step {
  padding: 40px 24px 8px 24px;
  border-right: 1px solid var(--line-dark);
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: relative;
}
.process-step:first-child { padding-left: 0; }
.process-step:last-child { border-right: 0; padding-right: 0; }
.process-step::before {
  content: '';
  position: absolute;
  top: -1px;
  left: 24px;
  width: 32px;
  height: 1px;
  background: var(--ink-on-dark);
}
.process-step:first-child::before { left: 0; }
.process-step .step-num {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  color: var(--ink-on-dark-2);
  text-transform: uppercase;
}
.process-step h3 {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(22px, 2vw, 30px);
  line-height: 1.1;
  letter-spacing: -0.025em;
  color: var(--ink-on-dark);
  margin: 0;
}
.process-step p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink-on-dark-2);
  margin: 0;
  max-width: 26ch;
}
.section-dark .process-grid { border-top-color: rgba(255, 255, 255, 0.18); }
.section-dark .process-step { border-right-color: rgba(255, 255, 255, 0.14); }
.section-dark .process-step::before { background: rgba(255, 255, 255, 0.85); }

@media (max-width: 900px) {
  .process-grid { grid-template-columns: 1fr 1fr; }
  .process-step:nth-child(2) { border-right: 0; }
}
@media (max-width: 540px) {
  .process-grid { grid-template-columns: 1fr; }
  .process-step { border-right: 0; border-bottom: 1px solid var(--line-dark); padding-bottom: 32px; }
  .process-step:last-child { border-bottom: 0; }
  .section-dark .process-step { border-bottom-color: rgba(255, 255, 255, 0.14); }
}

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .nav-links { gap: 24px; }
  .nav-links a { font-size: 11px; letter-spacing: 0.08em; }
}
@media (max-width: 980px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 36px; }
}
@media (max-width: 1366px) {
  .topbar { display: none; }
  .nav-links { display: none; }
  .mobile-toggle { display: block; }
  .nav-cta .btn-ghost { display: none; }
  .footer-grid { grid-template-columns: 1fr; gap: 0; }
  .footer-col { border-top: 1px solid var(--line-dark); }
  .footer-col:first-child { border-top: 0; }
  .footer-col h4 {
    margin: 0;
    padding: 20px 0;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  .footer-col h4 .fc-toggle {
    display: block;
    position: relative;
    width: 14px; height: 14px;
    flex-shrink: 0;
  }
  .footer-col h4 .fc-toggle::before,
  .footer-col h4 .fc-toggle::after {
    content: '';
    position: absolute;
    background: var(--ink-on-dark-2);
    top: 50%; left: 50%;
  }
  .footer-col h4 .fc-toggle::before { width: 12px; height: 1.5px; transform: translate(-50%,-50%); }
  .footer-col h4 .fc-toggle::after { width: 1.5px; height: 12px; transform: translate(-50%,-50%); transition: transform 0.25s var(--ease); }
  .footer-col.open h4 .fc-toggle::after { transform: translate(-50%,-50%) scaleY(0); }
  .footer-col ul {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s var(--ease);
    gap: 0;
  }
  .footer-col.open ul { max-height: 600px; padding-bottom: 18px; }
  .footer-col ul li { padding: 7px 0; }
  .footer-col:first-child { padding-top: 0; }
  .footer-col:first-child h4 { cursor: default; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .section-head { flex-direction: column; align-items: flex-start; }
}
