/* ==========================================================
   Klunder & Partners – IT-Services
   Schwarz/Weiß im Stil des Logos, mobile first
   ========================================================== */

:root {
  --black: #111111;
  --ink: #222222;
  --muted: #5f6368;
  --line: #e4e4e4;
  --bg: #ffffff;
  --bg-alt: #f6f6f4;
  --radius: 10px;
  --maxw: 1100px;
  --header-h: 72px;
  --font: "Inter", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 10px); }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3 { color: var(--black); line-height: 1.2; margin: 0 0 .5em; }

.container { width: min(100% - 2.5rem, var(--maxw)); margin-inline: auto; }
.narrow { max-width: 720px; }
.center { text-align: center; }

/* ---------- Header: Logo immer mittig ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .95);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s, box-shadow .2s;
}
.site-header.scrolled {
  border-color: var(--line);
  box-shadow: 0 2px 12px rgba(0, 0, 0, .05);
}

.header-inner {
  position: relative;
  height: var(--header-h);
  display: flex;
  justify-content: center;   /* Logo exakt in der Mitte */
  align-items: center;
  padding-inline: 1.25rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .7rem;
  text-decoration: none;
  color: var(--black);
}
.brand-icon { width: 40px; height: auto; }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-name { font-weight: 800; font-size: 1.15rem; letter-spacing: -.01em; }
.brand-sub  { font-size: .85rem; font-weight: 400; text-align: right; }

/* Hamburger (nur mobil) – absolut positioniert, damit das Logo mittig bleibt */
.nav-toggle {
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  width: 44px; height: 44px;
  display: flex; flex-direction: column; justify-content: center; gap: 5px;
  padding: 10px;
  background: none; border: 0; cursor: pointer;
}
.nav-toggle span {
  display: block; height: 2px; width: 100%;
  background: var(--black); border-radius: 2px;
  transition: transform .25s, opacity .2s;
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Navigation: mobil ausklappbar, darunter zentriert */
.site-nav {
  display: none;
  flex-direction: column;
  align-items: center;
  padding: .5rem 0 1rem;
  border-top: 1px solid var(--line);
  background: var(--bg);
}
.site-nav.open { display: flex; }
.nav-group { display: flex; flex-direction: column; align-items: center; }
.site-nav a {
  padding: .6rem 1rem;
  text-decoration: none;
  font-weight: 500;
  color: var(--ink);
}
.site-nav a:hover { color: var(--black); text-decoration: underline; text-underline-offset: 4px; }

/* ---------- Hero ---------- */
.hero {
  min-height: calc(100vh - var(--header-h));
  min-height: calc(100svh - var(--header-h));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 1.25rem 4rem;
  background:
    radial-gradient(circle at 50% 35%, rgba(0,0,0,.035), transparent 60%),
    var(--bg);
}

.hero-logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: fadeUp .8s ease both;
}
.hero-icon { width: clamp(90px, 22vw, 150px); height: auto; margin-bottom: 1.2rem; }
.hero-name {
  font-size: clamp(2rem, 7vw, 3.6rem);
  font-weight: 800;
  letter-spacing: -.02em;
  margin: 0;
}
.hero-sub {
  margin: .2rem 0 0;
  font-size: clamp(1.05rem, 3vw, 1.5rem);
  align-self: flex-end;      /* wie im Logo: rechtsbündig unter dem Namen */
}
.hero-logo { width: max-content; max-width: 100%; }

.hero-claim {
  max-width: 560px;
  margin: 2rem auto 2.2rem;
  font-size: clamp(1rem, 2.4vw, 1.2rem);
  color: var(--muted);
  animation: fadeUp .8s .15s ease both;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .8rem;
  animation: fadeUp .8s .3s ease both;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: .85rem 1.6rem;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
  border: 2px solid var(--black);
  transition: background .2s, color .2s, transform .15s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--black); color: #fff; }
.btn-primary:hover { background: #333; border-color: #333; }
.btn-ghost { background: transparent; color: var(--black); }
.btn-ghost:hover { background: var(--black); color: #fff; }
.btn-light { background: #fff; color: var(--black); border-color: #fff; word-break: break-all; }
.btn-light:hover { background: transparent; color: #fff; }

/* ---------- Sections ---------- */
.section { padding: clamp(3.5rem, 9vw, 6rem) 0; }
.section-alt { background: var(--bg-alt); }
.section-dark { background: var(--black); color: #ddd; }
.section-dark .section-title { color: #fff; }
.section-dark .section-lead { color: #bbb; }

.section-title {
  font-size: clamp(1.6rem, 4.5vw, 2.3rem);
  text-align: center;
  position: relative;
  padding-bottom: .6rem;
  margin-bottom: 1rem;
}
.section-title::after {
  content: "";
  position: absolute;
  left: 50%; bottom: 0;
  width: 48px; height: 3px;
  transform: translateX(-50%);
  background: currentColor;
  border-radius: 2px;
}
.section-lead {
  text-align: center;
  color: var(--muted);
  max-width: 600px;
  margin: 0 auto 2.5rem;
}

/* ---------- Karten ---------- */
.cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.8rem 1.5rem;
  text-align: center;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.card:hover {
  transform: translateY(-4px);
  border-color: var(--black);
  box-shadow: 0 10px 28px rgba(0, 0, 0, .08);
}
.card-icon {
  width: 56px; height: 56px;
  margin: 0 auto 1rem;
  display: grid; place-items: center;
  border: 2px solid var(--black);
  border-radius: 8px;
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--black);
}
.card h3 { font-size: 1.15rem; }
.card p { margin: 0; color: var(--muted); }

/* ---------- Schritte ---------- */
.steps {
  list-style: none;
  padding: 0;
  margin: 2.5rem 0 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  counter-reset: none;
}
.steps li { text-align: center; padding: 0 .5rem; }
.step-no {
  display: inline-grid; place-items: center;
  width: 48px; height: 48px;
  border-radius: 50%;
  background: var(--black); color: #fff;
  font-weight: 700;
  margin-bottom: .8rem;
}
.steps h3 { font-size: 1.1rem; }
.steps p { margin: 0; color: var(--muted); }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem 0;
  font-size: .9rem;
  color: var(--muted);
}
.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .6rem;
  text-align: center;
}
.footer-inner p { margin: 0; }
.footer-icon { width: 30px; height: auto; opacity: .85; }
.footer-nav { display: flex; gap: 1.2rem; }
.footer-nav a { text-decoration: none; }
.footer-nav a:hover { color: var(--black); text-decoration: underline; }

/* ---------- Unterseiten (Impressum / Datenschutz) ---------- */
.legal { padding: clamp(2.5rem, 7vw, 4.5rem) 0; }
.legal h1 { font-size: clamp(1.8rem, 5vw, 2.4rem); text-align: center; margin-bottom: 2rem; }
.legal h2 { font-size: 1.2rem; margin-top: 2rem; }
.back-link { display: inline-block; margin-top: 2.5rem; font-weight: 600; }

/* ==========================================================
   Responsive Breakpoints
   ========================================================== */

/* Tablet */
@media (min-width: 640px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
}

/* Desktop: Navigation links/rechts, Logo bleibt in der Mitte */
@media (min-width: 960px) {
  :root { --header-h: 84px; }

  .nav-toggle { display: none; }
  .brand-icon { width: 46px; }
  .brand-name { font-size: 1.3rem; }

  .site-nav {
    display: grid;
    position: absolute;
    inset: 0;
    grid-template-columns: 1fr auto 1fr;   /* links | Logo-Platz | rechts */
    align-items: center;
    padding: 0 2rem;
    border: 0;
    background: transparent;
    pointer-events: none;                  /* Logo darunter bleibt klickbar */
    max-width: var(--maxw);
    margin-inline: auto;
  }
  .site-nav a { pointer-events: auto; }
  .site-nav::before {
    content: "";
    grid-column: 2; grid-row: 1;
    width: 300px;                          /* Platzhalter für das Logo */
  }
  .nav-group { display: flex; flex-direction: row; gap: .5rem; grid-row: 1; }
  .nav-left  { grid-column: 1; justify-content: flex-end; }
  .nav-right { grid-column: 3; justify-content: flex-start; }

  .cards { grid-template-columns: repeat(4, 1fr); }
  .steps { grid-template-columns: repeat(4, 1fr); }
}

/* Sehr kleine Displays */
@media (max-width: 360px) {
  .brand-icon { width: 32px; }
  .brand-name { font-size: 1rem; }
  .brand-sub { font-size: .75rem; }
}

/* Weniger Bewegung, wenn gewünscht */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
