:root {
  --black: #0d0d0f;
  --panel: #17171a;
  --panel-2: #1f1f24;
  --white: #f4f4f5;
  --grey: #a7a7ae;
  --red: #d81f26;
  --red-bright: #f03038;
  --line: #2c2c32;

  --font-display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --font-body: "Barlow", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  height: 100%;
}

body {
  margin: 0;
  background: var(--black);
  color: var(--white);
  font-family: var(--font-body);
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.content { flex: 1; }

.wrap {
  max-width: 980px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

h2 {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 700;
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin: 0 0 1.4rem;
}

h2::after {
  content: "";
  display: block;
  width: 3.2rem;
  height: 4px;
  margin-top: 0.5rem;
  background: var(--red);
  transform: skewX(-20deg);
}

/* ---- header ---- */

.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--black);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.5rem;
}

.logo { height: 46px; width: auto; }

.brand { display: flex; flex-direction: column; }

.brand-mark {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 700;
  font-size: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  line-height: 1;
}

.brand-sub {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--grey);
  margin-top: 0.25rem;
}

.header-social {
  margin-left: auto;
  display: flex;
  gap: 0.9rem;
}

.header-social a {
  color: var(--grey);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  align-self: center;
  transition: color 0.2s ease;
}

.header-social a:hover { color: var(--red-bright); }

.header-social:not([hidden]) + .header-cta { margin-left: 1rem; }

.header-cta {
  margin-left: auto;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 700;
  font-size: 1.05rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--white);
  background: var(--red);
  text-decoration: none;
  padding: 0.5rem 1.1rem;
  clip-path: polygon(8px 0, 100% 0, calc(100% - 8px) 100%, 0 100%);
  transition: background 0.2s ease;
}

.header-cta:hover { background: var(--red-bright); }

/* ---- hero banner image (full width, under header) ---- */

.hero-banner-img {
  display: block;
  width: 100%;
  height: auto;
  border-bottom: 1px solid var(--line);
}

/* ---- hero ---- */

.hero {
  position: relative;
  overflow: hidden;
  padding: 5rem 0 4.5rem;
  background:
    radial-gradient(ellipse 90% 70% at 75% 20%, #26262c 0%, transparent 60%),
    var(--black);
}

.hero-slash {
  position: absolute;
  top: 0;
  left: -12%;
  width: 38%;
  height: 100%;
  background: linear-gradient(160deg, rgba(216, 31, 38, 0.16), transparent 65%);
  transform: skewX(-18deg);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 2.5rem;
  align-items: center;
}

.hero-side-img {
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
}

@media (max-width: 780px) {
  .hero-inner { grid-template-columns: 1fr; }
}

.hero-kicker {
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--grey);
  margin: 0 0 1.2rem;
  max-width: 60ch;
}

.hero h1 {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 700;
  font-size: clamp(2.6rem, 7vw, 4.2rem);
  text-transform: uppercase;
  line-height: 1.02;
  margin: 0 0 1.4rem;
  max-width: 18ch;
}

.hero h1 .accent { color: var(--red-bright); }

.hero-text {
  max-width: 62ch;
  color: var(--grey);
  font-size: 1.05rem;
  margin: 0 0 2rem;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

.hero-badges span {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.98rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border: 1px solid var(--line);
  border-left: 3px solid var(--red);
  background: var(--panel);
  padding: 0.45rem 0.9rem;
}

/* ---- merksatz band ---- */

.merksatz-band {
  background: var(--red);
  padding: 0.9rem 0;
}

.merksatz-band p {
  margin: 0;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 700;
  font-size: clamp(1.1rem, 3vw, 1.45rem);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  text-align: center;
}

/* ---- sections ---- */

.section { padding: 3.5rem 1.5rem; }

.section-banner-img {
  display: block;
  width: 100%;
  height: auto;
  margin-bottom: 1.8rem;
  border: 1px solid var(--line);
}

.section-dark {
  background: var(--panel);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 3.5rem 0;
}

.prose {
  white-space: pre-wrap;
  color: var(--grey);
  max-width: 72ch;
  margin: 0;
}

/* leistungen */

.leistungen-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.2rem;
}

.leistung-card {
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-top: 3px solid var(--red);
  padding: 1.4rem 1.5rem 1.5rem;
}

.leistung-card h3 {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 700;
  font-size: 1.35rem;
  text-transform: uppercase;
  margin: 0 0 0.7rem;
}

.leistung-card p {
  color: var(--grey);
  font-size: 0.94rem;
  margin: 0;
}

.leistung-card ul {
  margin: 0.8rem 0 0;
  padding: 0;
  list-style: none;
}

.leistung-card li {
  font-size: 0.9rem;
  color: var(--white);
  padding: 0.25rem 0 0.25rem 1.2rem;
  position: relative;
}

.leistung-card li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 0.55rem;
  height: 2px;
  background: var(--red);
  transform: skewX(-20deg);
}

/* warum check-list */

.check-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 0.55rem 2rem;
}

.check-list li {
  position: relative;
  padding: 0.35rem 0 0.35rem 2rem;
  font-size: 1rem;
}

.check-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0.3rem;
  width: 1.35rem;
  height: 1.35rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--white);
  background: var(--red);
  border-radius: 50%;
}

/* ablauf steps */

.ablauf-steps {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.2rem;
}

.ablauf-steps li {
  counter-increment: step;
  background: var(--panel-2);
  border: 1px solid var(--line);
  padding: 1.3rem 1.4rem;
  position: relative;
}

.ablauf-steps li::before {
  content: counter(step, decimal-leading-zero);
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 700;
  font-size: 2.4rem;
  line-height: 1;
  color: var(--red);
  display: block;
  margin-bottom: 0.6rem;
}

.ablauf-steps h3 {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 700;
  font-size: 1.25rem;
  text-transform: uppercase;
  margin: 0 0 0.4rem;
}

.ablauf-steps p {
  color: var(--grey);
  font-size: 0.92rem;
  margin: 0;
}

/* gallery (optional) */

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}

.gallery figure {
  margin: 0;
  position: relative;
  overflow: hidden;
  background: var(--panel-2);
  border: 1px solid var(--line);
}

.gallery img {
  display: block;
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.gallery figcaption {
  padding: 0.5rem 0.7rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--grey);
}

/* notfall */

.notfall {
  background:
    linear-gradient(120deg, rgba(216, 31, 38, 0.22), transparent 55%),
    var(--panel);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 3.5rem 0;
  text-align: center;
}

.notfall h2 { display: inline-block; }

.notfall p {
  max-width: 58ch;
  margin: 0 auto 1.6rem;
  color: var(--grey);
}

.notfall-phone {
  display: inline-block;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 700;
  font-size: clamp(1.6rem, 5vw, 2.4rem);
  letter-spacing: 0.03em;
  color: var(--white);
  background: var(--red);
  text-decoration: none;
  padding: 0.7rem 2rem;
  clip-path: polygon(12px 0, 100% 0, calc(100% - 12px) 100%, 0 100%);
  transition: background 0.2s ease;
}

.notfall-phone:hover { background: var(--red-bright); }

.notfall-schluss {
  margin-top: 1.8rem !important;
  font-weight: 600;
  color: var(--white) !important;
}

/* kontakt */

.kontakt-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 1.2rem;
}

.kontakt-block {
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 3px solid var(--red);
  padding: 1.1rem 1.3rem;
}

.kontakt-block h3 {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 700;
  font-size: 1.05rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--grey);
  margin: 0 0 0.4rem;
}

.kontakt-block p { margin: 0; font-size: 0.98rem; }

.kontakt-block a {
  color: var(--white);
  text-decoration: none;
  border-bottom: 1px solid var(--red);
}

.kontakt-block a:hover { color: var(--red-bright); }

/* footer */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem 0;
  font-size: 0.85rem;
  text-align: center;
  color: var(--grey);
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.7rem;
}

.social-links { display: flex; gap: 1rem; }

.social-links a {
  color: var(--red-bright);
  text-decoration: none;
  font-weight: 500;
}

.impressum summary {
  cursor: pointer;
  font-size: 0.8rem;
  color: var(--grey);
}

.impressum p {
  max-width: 520px;
  margin: 0.9rem auto 0;
  font-size: 0.78rem;
  line-height: 1.7;
  color: var(--grey);
  text-align: left;
  white-space: pre-wrap;
}

/* fallback state when config.json cannot load */

.load-error {
  max-width: 480px;
  margin: 4rem auto;
  padding: 2rem;
  text-align: center;
  color: var(--grey);
}

@media (max-width: 560px) {
  .header-cta { display: none; }
  .header-social { display: none; }
}
