/* Segel Immoverwaltung — Hausverwaltung & Koordination homepage */

:root {
  --color-bg: #f6f5f4;
  --color-bg-alt: #eeedeb;
  --color-surface: #ffffff;
  --color-text: #141218;
  --color-text-muted: #5c5856;
  --color-accent: #9f1239;
  --color-accent-hover: #831032;
  --color-accent-soft: #f7ecef;
  --color-accent-tint: rgba(159, 18, 57, 0.07);
  --color-border: #e0ddd9;
  --color-footer-bg: #1f1818;
  --color-footer-text: #d4cfcd;
  --color-footer-link: #f5f0ef;
  --color-footer-link-hover: #ffffff;
  --font-sans: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --space-xs: 0.35rem;
  --space-sm: 0.75rem;
  --space-md: 1.25rem;
  --space-lg: 2rem;
  --space-xl: 3.5rem;
  --space-2xl: 4.5rem;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 10px 36px rgba(20, 18, 24, 0.07);
  --shadow-hover: 0 16px 44px rgba(20, 18, 24, 0.11);
  --max-width: 72rem;
  --max-width-prose: 40rem;
  --header-h: 4.25rem;
}

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

html {
  scroll-behavior: smooth;
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--color-text);
  background: var(--color-bg);
}

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

a {
  color: var(--color-accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

a:hover {
  color: var(--color-accent-hover);
}

:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  left: 0.5rem;
  top: -100vh;
  padding: var(--space-sm) var(--space-md);
  background: var(--color-accent);
  color: #fff;
  z-index: 200;
  border-radius: var(--radius-sm);
  text-decoration: none;
}

.skip-link:focus {
  top: 0.5rem;
}

.skip-link:focus-visible {
  outline-color: #fff;
  outline-offset: 3px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.lang-toggle-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.5rem 0.85rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-surface);
  color: var(--color-text);
  cursor: pointer;
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.lang-toggle-btn:hover {
  background: var(--color-accent-soft);
  border-color: rgba(159, 18, 57, 0.35);
}

.lang-toggle-btn:focus-visible {
  outline-offset: 2px;
}

.lang-toggle-btn svg {
  flex-shrink: 0;
}

.region-highlight {
  font-weight: 600;
  color: var(--color-text);
}

.region-follow {
  margin-top: var(--space-md);
}

.steps li > strong {
  display: block;
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.35;
}

.step-body {
  margin: 0.5rem 0 0;
  color: var(--color-text-muted);
}

.contact-block h2 {
  margin-top: 0;
  margin-bottom: var(--space-md);
}

.imprint-footer-h2 {
  color: #fff;
  font-size: 1.1rem;
  margin-top: 0;
}

.footer-brand-sub {
  margin: 0.35rem 0 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--color-bg) 94%, transparent);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}

@supports not (background: color-mix(in srgb, white 50%, black)) {
  .site-header {
    background: rgba(246, 245, 244, 0.94);
  }
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--space-sm) var(--space-md);
  min-height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  flex-wrap: wrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  text-decoration: none;
  color: inherit;
}

.brand:hover {
  color: inherit;
}

.brand:focus-visible {
  border-radius: var(--radius-sm);
}

.brand img {
  width: auto;
  max-height: 2.75rem;
  height: auto;
}

/* Logo scroll-transition choreography
   - logo-in-hero  : initial state, header logo is an invisible placeholder
   - logo-moving   : during the flight animation (header logo still hidden)
   - logo-in-header: final state, header logo visible, hero logo removed
*/
html.logo-in-hero .brand img,
html.logo-moving .brand img {
  visibility: hidden;
}

html.logo-moving .hero-logo-wrap {
  visibility: hidden;
}

html.logo-in-header .hero-logo-wrap {
  display: none;
}

.logo-flight {
  position: fixed;
  margin: 0;
  z-index: 60;
  pointer-events: none;
  transform-origin: top left;
  will-change: transform;
}

@media (prefers-reduced-motion: reduce) {
  .logo-flight {
    display: none !important;
  }
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.brand-name {
  font-weight: 700;
  font-size: 1.0625rem;
  letter-spacing: -0.02em;
}

.brand-tag {
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-sm) var(--space-md);
  flex-wrap: wrap;
}

.lang-switch-wrap {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm) var(--space-md);
  /* Stretch so every item shares the same row height; centering per-item then aligns labels. */
  align-items: stretch;
}

.site-nav > a {
  display: flex;
  align-items: center;
  line-height: 1.25;
}

.site-nav a {
  color: var(--color-text);
  text-decoration: none;
  font-size: 0.9375rem;
  font-weight: 500;
  transition: color 0.2s ease;
}

.site-nav a:hover {
  color: var(--color-accent);
}

.nav-dropdown {
  position: relative;
}

/* Top-level dropdown in header: match height and vertical centering of adjacent <a> links. */
.site-nav > .nav-dropdown {
  display: flex;
  flex-direction: column;
  justify-content: center;
  margin: 0;
  padding: 0;
}

.nav-dropdown__summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.4rem;
  font-size: 0.9375rem;
  font-weight: 500;
  line-height: 1.25;
  color: var(--color-text);
  padding: 0.15rem 0;
}

.nav-dropdown__summary::-webkit-details-marker {
  display: none;
}

.nav-dropdown__summary::after {
  content: "";
  display: block;
  width: 0.38em;
  height: 0.38em;
  margin: 0;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  flex-shrink: 0;
  align-self: center;
  opacity: 0.65;
  transform: rotate(45deg);
  transform-origin: 50% 50%;
}

@media (prefers-reduced-motion: no-preference) {
  .nav-dropdown__summary::after {
    transition: transform 0.22s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.2s ease;
  }

  .nav-dropdown[open] > .nav-dropdown__panel {
    transform-origin: top left;
    animation: nav-dropdown-panel-in 0.22s cubic-bezier(0.4, 0, 0.2, 1) both;
  }
}

@keyframes nav-dropdown-panel-in {
  from {
    opacity: 0;
    transform: translateY(-0.35rem);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.nav-dropdown[open] .nav-dropdown__summary {
  color: var(--color-accent);
}

.nav-dropdown[open] .nav-dropdown__summary::after {
  transform: rotate(225deg);
}

.nav-dropdown__panel {
  position: absolute;
  top: calc(100% + 0.35rem);
  left: 0;
  min-width: 15rem;
  padding: var(--space-sm);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  z-index: 70;
}

.nav-dropdown__panel ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.nav-dropdown__panel a {
  display: block;
  padding: 0.45rem 0.65rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text);
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}

.nav-dropdown__panel a:hover {
  background: var(--color-accent-soft);
  color: var(--color-accent);
}


.detail-breadcrumb {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  margin: 0 0 var(--space-md);
}

.detail-breadcrumb a {
  font-weight: 600;
  text-decoration: none;
}

.detail-breadcrumb a:hover {
  text-decoration: underline;
}

.detail-breadcrumb__sep {
  margin: 0 0.5rem;
  opacity: 0.55;
}

.detail-breadcrumb__current {
  color: var(--color-text);
  font-weight: 600;
}

.detail-back {
  display: inline-block;
  margin: 0 0 var(--space-lg);
  font-weight: 600;
  text-decoration: none;
}

.detail-back:hover {
  text-decoration: underline;
}

.page-detail {
  background: var(--color-bg);
}

.detail-hero {
  position: relative;
  isolation: isolate;
  overflow: clip;
  /* Shorter than full viewport so the next section is partly visible (scroll cue). */
  min-height: max(20rem, 62vh);
  min-height: max(20rem, 62dvh);
  display: flex;
  align-items: flex-end;
  padding: calc(var(--header-h) + var(--space-lg)) var(--space-md) var(--space-xl);
}

.detail-hero__parallax {
  position: absolute;
  left: 0;
  right: 0;
  top: -25%;
  height: 125%;
  z-index: 0;
  background-color: #2a2624;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  transform: translate3d(0, 0, 0);
  will-change: transform;
}

.detail-hero__scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    to top,
    rgba(20, 18, 24, 0.92) 0%,
    rgba(20, 18, 24, 0.55) 42%,
    rgba(20, 18, 24, 0.4) 100%
  );
  pointer-events: none;
}

.detail-hero__content {
  position: relative;
  z-index: 2;
  width: 100%;
}

.detail-hero__content > :last-child {
  margin-bottom: 0;
}

.detail-hero h1 {
  margin-top: 0;
  color: #fff;
  text-wrap: balance;
}

.detail-hero .detail-breadcrumb {
  color: rgba(255, 255, 255, 0.78);
}

.detail-hero .detail-breadcrumb a {
  color: #fff;
}

.detail-hero .detail-breadcrumb a:hover {
  color: #fff;
}

.detail-hero .detail-breadcrumb__current {
  color: #fff;
}

.detail-hero .detail-back {
  color: #fff;
}

.detail-hero .detail-back:hover {
  color: #fff;
}

.detail-hero .lead-muted {
  color: rgba(255, 255, 255, 0.92);
}

.detail-hero__teaser {
  margin-top: var(--space-md);
}

.about-intro__note {
  margin-top: 0;
  margin-bottom: var(--space-lg);
  font-size: 0.95rem;
}

.about-intro {
  display: grid;
  gap: var(--space-xl);
  align-items: start;
}

@media (min-width: 48rem) {
  .about-intro {
    grid-template-columns: minmax(12rem, 17rem) minmax(0, 1fr);
    gap: var(--space-2xl);
    align-items: center;
  }
}

.about-intro__figure {
  margin: 0;
}

.about-intro__caption {
  margin: var(--space-sm) 0 0;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text-muted);
  text-align: center;
  line-height: 1.35;
}

@media (min-width: 48rem) {
  .about-intro__caption {
    text-align: left;
  }
}

.about-intro__img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  width: 100%;
  max-width: 20rem;
  margin-inline: auto;
  object-fit: cover;
  aspect-ratio: 4 / 5;
}

@media (min-width: 48rem) {
  .about-intro__img {
    margin-inline: 0;
    max-width: none;
  }
}

.about-intro__prose p {
  margin: 0 0 var(--space-md);
}

.about-intro__prose p:last-child {
  margin-bottom: 0;
}

@media (prefers-reduced-motion: reduce) {
  .detail-hero__parallax {
    will-change: auto;
  }
}

.detail-block .card-head :is(h2, h3) {
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0;
  color: var(--color-accent);
}

.detail-block p {
  margin: 0;
  color: var(--color-text-muted);
}

main {
  overflow-x: clip;
}

.section {
  padding: var(--space-xl) var(--space-md);
}

main > section.section:nth-child(even) {
  background-color: var(--color-bg-alt);
}

.section--tight {
  padding-top: var(--space-lg);
}

.section-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

.hero {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--space-2xl) var(--space-md) calc(var(--space-xl) + 1.25rem);
  background:
    linear-gradient(165deg, var(--color-accent-soft) 0%, var(--color-bg) 48%, var(--color-bg-alt) 100%);
  border-bottom: 1px solid var(--color-border);
}

.hero-decor {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 90% 55% at 78% -15%, var(--color-accent-tint), transparent 52%),
    radial-gradient(ellipse 50% 40% at 12% 100%, rgba(159, 18, 57, 0.04), transparent 55%);
}

.hero .section-inner.hero-inner {
  position: relative;
  flex: 1 1 auto;
  align-self: stretch;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-logo-wrap {
  margin: 0 auto var(--space-md);
  width: 100%;
  max-width: 40rem;
}

.hero-logo {
  width: 100%;
  max-width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}

.hero-split {
  width: 100%;
  margin-top: 2rem;
  display: grid;
  gap: var(--space-xl);
  align-items: center;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
}

.hero-copy {
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
}

.hero-carousel {
  margin: 0;
  min-width: 0;
  width: 100%;
}

.hero-carousel#leistungen {
  scroll-margin-top: calc(var(--header-h) + 0.75rem);
}

.hero-carousel__heading {
  margin: 0 0 var(--space-md);
  font-size: clamp(1.2rem, 2.4vw, 1.55rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.2;
  color: var(--color-text);
}

.hero-carousel__viewport {
  position: relative;
  border-radius: calc(var(--radius) + 4px);
  overflow: hidden;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow);
  background: var(--color-surface);
}

.hero-carousel__track {
  position: relative;
  z-index: 0;
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  width: 400%;
  transition: transform 0.5s cubic-bezier(0.65, 0, 0.35, 1);
  will-change: transform;
}

@media (prefers-reduced-motion: reduce) {
  .hero-carousel__track {
    transition: none;
  }
}

.hero-carousel__slide {
  flex: 0 0 25%;
  min-width: 0;
}

.hero-carousel__card {
  position: relative;
  display: block;
  color: inherit;
}

.hero-carousel__media {
  position: relative;
  overflow: hidden;
  border-radius: inherit;
}

/* Vignette only on the photo — not over title / CTA */
.hero-carousel__media::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(to right, rgba(0, 0, 0, 0.22) 0%, rgba(0, 0, 0, 0) 12%),
    linear-gradient(to left, rgba(0, 0, 0, 0.22) 0%, rgba(0, 0, 0, 0) 12%),
    linear-gradient(to top, rgba(0, 0, 0, 0.28) 0%, rgba(0, 0, 0, 0) 36%);
}

.hero-carousel__img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
}

.hero-carousel__caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  padding: var(--space-lg) var(--space-lg);
  /* Space for dot indicators (bottom: 0.25rem + dot height) */
  padding-bottom: calc(var(--space-lg) + 1.5rem);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.55rem;
  color: #fff;
  background: linear-gradient(
    to top,
    rgba(20, 18, 24, 0.88) 0%,
    rgba(20, 18, 24, 0.35) 52%,
    transparent 100%
  );
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

.hero-carousel__title {
  font-size: clamp(1.45rem, 4.2vw, 2.35rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
  max-width: 95%;
  text-shadow:
    0 1px 2px rgba(0, 0, 0, 0.55),
    0 2px 14px rgba(0, 0, 0, 0.35);
}

.hero-carousel__more {
  font-size: clamp(1.05rem, 2.4vw, 1.45rem);
  font-weight: 700;
  letter-spacing: 0.03em;
  text-decoration: underline;
  text-underline-offset: 0.2em;
  text-decoration-thickness: 2px;
  color: #fff;
  opacity: 0.98;
  text-shadow:
    0 1px 2px rgba(0, 0, 0, 0.5),
    0 2px 10px rgba(0, 0, 0, 0.3);
}

.hero-carousel__more:hover {
  color: #fff;
  opacity: 1;
  text-decoration-thickness: 3px;
}

.hero-carousel__more:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.95);
  outline-offset: 3px;
  border-radius: 2px;
}

.hero-carousel__chrome {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}

.hero-carousel__chrome .hero-carousel__btn,
.hero-carousel__chrome .hero-carousel__dots,
.hero-carousel__chrome .hero-carousel__dot {
  pointer-events: auto;
}

.hero-carousel__btn {
  position: absolute;
  top: 0;
  bottom: 34%;
  width: 18%;
  min-width: 2.75rem;
  padding: 0;
  border: none;
  border-radius: 0;
  background: transparent;
  color: #fff;
  font-size: 1.65rem;
  line-height: 1;
  cursor: pointer;
  font-family: inherit;
}

/* Hit zone is only top 66% (see bottom: 34%); center chevrons on full image, not on that band */
.hero-carousel__btn > span {
  position: absolute;
  /* 50% of carousel height == (50/66)×100% of button height when bottom: 34% */
  top: calc(100% * 50 / 66);
  transform: translateY(-50%);
  display: block;
  transition: transform 0.22s ease, filter 0.25s ease, text-shadow 0.25s ease;
  text-shadow:
    0 0 1px rgba(0, 0, 0, 0.95),
    0 1px 2px rgba(0, 0, 0, 0.88),
    0 2px 5px rgba(0, 0, 0, 0.45);
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.55));
}

.hero-carousel__btn--prev {
  left: 0;
}

.hero-carousel__btn--prev > span {
  left: 0.35rem;
}

.hero-carousel__btn--next {
  right: 0;
}

.hero-carousel__btn--next > span {
  right: 0.35rem;
  left: auto;
}

.hero-carousel__btn:hover > span {
  transform: translateY(-50%) scale(1.06);
  text-shadow:
    0 0 1px rgba(0, 0, 0, 0.95),
    0 1px 2px rgba(0, 0, 0, 0.88),
    0 2px 6px rgba(0, 0, 0, 0.48);
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.6));
}

.hero-carousel__btn:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.95);
  outline-offset: 3px;
  border-radius: 2px;
}

.hero-carousel__dots {
  position: absolute;
  left: 50%;
  bottom: 0.25rem;
  z-index: 3;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  max-width: calc(100% - 5rem);
}

.hero-carousel__dot {
  width: 0.5rem;
  height: 0.5rem;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.65);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  font: inherit;
  transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.hero-carousel__dot:hover {
  background: rgba(255, 255, 255, 0.75);
}

.hero-carousel__dot.is-active {
  background: #fff;
  border-color: #fff;
  transform: scale(1.25);
}

.hero-carousel__dot:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

@media (max-width: 960px) {
  .hero-split {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }

  .hero-carousel {
    order: -1;
    max-width: 36rem;
    margin-inline: auto;
  }
}

.hero-badge {
  display: inline-block;
  margin: 0 0 var(--space-sm);
  padding: 0.35rem 0.75rem;
  max-width: min(100%, 22rem);
  font-size: clamp(0.65rem, 2.4vw, 0.75rem);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-accent);
  background: var(--color-surface);
  border: 1px solid color-mix(in srgb, var(--color-accent) 18%, var(--color-border));
  border-radius: 999px;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset;
  line-height: 1.35;
}

@supports not (color: color-mix(in srgb, white 50%, black)) {
  .hero-badge {
    border-color: var(--color-border);
  }
}

.hero h1 {
  font-size: clamp(1.85rem, 4.2vw, 2.75rem);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.035em;
  margin: 0 0 var(--space-md);
  max-width: 18ch;
}

.hero-lead {
  font-size: clamp(1.05rem, 1.6vw, 1.2rem);
  color: var(--color-text-muted);
  max-width: var(--max-width-prose);
  margin: 0 0 var(--space-lg);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.btn:focus-visible {
  outline-offset: 3px;
}

.btn--primary {
  background: var(--color-accent);
  color: #fff;
  box-shadow: 0 2px 12px rgba(159, 18, 57, 0.25);
}

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

@media (prefers-reduced-motion: no-preference) {
  .btn--primary {
    transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
  }

  .btn--primary:hover {
    box-shadow: 0 4px 18px rgba(159, 18, 57, 0.3);
  }

  .btn--primary:active {
    transform: scale(0.98);
  }
}

.btn--ghost {
  background: transparent;
  color: var(--color-accent);
  border: 2px solid var(--color-accent);
}

.btn--ghost:hover {
  background: var(--color-accent-soft);
  color: var(--color-accent-hover);
  border-color: var(--color-accent-hover);
}

.header-actions .btn--header-cta {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.2;
  border-radius: var(--radius-sm);
  background: var(--color-accent);
  color: #fff;
  text-decoration: none;
  box-shadow: 0 2px 10px rgba(159, 18, 57, 0.22);
  flex-shrink: 0;
}

.header-actions .btn--header-cta:hover {
  background: var(--color-accent-hover);
  color: #fff;
}

.btn--header-cta:focus-visible {
  outline-offset: 2px;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  align-items: center;
}

.hero-cta .btn--primary {
  min-height: 3rem;
  padding-inline: 1.65rem;
}

h2 {
  font-size: clamp(1.4rem, 2.6vw, 1.85rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  margin: 0 0 var(--space-md);
}

h3 {
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0 0 var(--space-sm);
}

.card > p {
  margin: 0;
}

.pillars {
  display: grid;
  gap: var(--space-md);
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.pillar {
  background: var(--color-surface);
  border-radius: var(--radius);
  padding: var(--space-lg);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.pillar-head {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
}

.pillar-icon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
}

.pillar-head h3 {
  margin: 0;
  color: var(--color-accent);
}

.pillar > p {
  margin: 0;
}

@media (prefers-reduced-motion: no-preference) {
  .pillar {
    transition: border-color 0.2s ease, box-shadow 0.25s ease, transform 0.25s ease;
  }

  .pillar:hover {
    border-color: rgba(159, 18, 57, 0.22);
    box-shadow: var(--shadow-hover);
    transform: translateY(-2px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .pillar:hover {
    border-color: var(--color-accent);
    box-shadow: var(--shadow-hover);
  }
}

.lead-muted {
  color: var(--color-text-muted);
  max-width: var(--max-width-prose);
  margin: 0 0 var(--space-lg);
}

.card-grid {
  display: grid;
  gap: var(--space-md);
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: var(--space-lg);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.card-head {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
}

.card-icon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
}

.card-head h3 {
  margin: 0;
}

@media (prefers-reduced-motion: no-preference) {
  .card {
    transition: border-color 0.2s ease, box-shadow 0.25s ease, transform 0.25s ease;
  }

  .card:hover {
    border-color: rgba(159, 18, 57, 0.2);
    box-shadow: var(--shadow-hover);
    transform: translateY(-2px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .card:hover {
    border-color: var(--color-accent);
    box-shadow: var(--shadow-hover);
  }
}

.card ul {
  margin: 0;
  padding-left: 1.2rem;
}

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

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: var(--space-md);
}

.steps li {
  position: relative;
  padding: var(--space-lg);
  padding-left: calc(var(--space-lg) + 2.5rem);
  background: var(--color-surface);
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
}

.steps li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: var(--space-lg);
  top: var(--space-lg);
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-accent-soft);
  color: var(--color-accent);
  font-weight: 700;
  font-size: 0.95rem;
  border-radius: 50%;
}

.faq details {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: var(--space-md) var(--space-lg);
  margin-bottom: var(--space-sm);
  transition: border-color 0.2s ease;
}

.faq details:hover {
  border-color: rgba(159, 18, 57, 0.15);
}

.faq summary {
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  position: relative;
  padding-left: 1.75rem;
  margin-bottom: 0;
  transition: margin-bottom 250ms ease;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::before {
  content: "";
  position: absolute;
  left: 0.1rem;
  top: 50%;
  width: 0.6rem;
  height: 0.6rem;
  margin-top: -0.4rem;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  transform-origin: 50% 50%;
  transition: transform 250ms ease;
  opacity: 0.65;
}

.faq details[open] summary {
  margin-bottom: var(--space-sm);
}

.faq details[open] summary::before {
  transform: rotate(225deg);
}

/* When JS drives the open/close animation, defer the chevron + margin
   visual state to the .is-open class so they animate in lockstep with the
   height transition, even while [open] is still set during the close. */
.faq.faq-anim details[open] summary {
  margin-bottom: 0;
}

.faq.faq-anim details[open] summary::before {
  transform: rotate(45deg);
}

.faq.faq-anim details.is-open summary {
  margin-bottom: var(--space-sm);
}

.faq.faq-anim details.is-open summary::before {
  transform: rotate(225deg);
}

.faq-body {
  /* No fixed overflow here; the script sets overflow:hidden inline only
     while a height animation is running, then clears it. */
}

.faq p {
  margin: 0;
  color: var(--color-text-muted);
  font-size: 0.98rem;
}

@media (prefers-reduced-motion: reduce) {
  .faq summary,
  .faq summary::before {
    transition: none;
  }
}

.contact-block {
  background: var(--color-accent-soft);
  border-radius: var(--radius);
  padding: var(--space-xl);
  text-align: center;
  border: 1px solid color-mix(in srgb, var(--color-accent) 12%, var(--color-border));
}

@supports not (color: color-mix(in srgb, white 50%, black)) {
  .contact-block {
    border-color: var(--color-border);
  }
}

.contact-block p {
  margin: 0 0 var(--space-md);
  max-width: var(--max-width-prose);
  margin-left: auto;
  margin-right: auto;
}

.contact-block__channels {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.65rem;
  margin: 0 0 var(--space-md);
}

.contact-block__channel {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--color-accent);
  text-decoration: none;
  text-align: left;
}

.contact-block__channel > span:not(.contact-block__channel-icon) {
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

.contact-block__channel-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-accent);
}

.contact-block__channel-icon svg {
  display: block;
}

.contact-block__channel:hover > span:not(.contact-block__channel-icon) {
  text-decoration-thickness: 0.1em;
}

.contact-block__channel:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
}

.contact-block__hook {
  margin: 0 0 var(--space-md);
  font-size: 1.15rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--color-text);
}

.contact-block__microcopy {
  margin: 0 auto var(--space-md);
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--color-text-muted);
}

.process-promise {
  margin: var(--space-lg) 0 var(--space-xl);
  padding: var(--space-lg);
  background: var(--color-surface);
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow);
}

.process-promise__title {
  margin: 0 0 var(--space-sm);
  font-size: 1.2rem;
  font-weight: 700;
}

.process-promise__lead {
  margin: 0 0 var(--space-lg);
  color: var(--color-text-muted);
  font-size: 0.98rem;
  line-height: 1.6;
}

.process-promise__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-lg);
}

.process-promise__card h4 {
  margin: 0 0 var(--space-sm);
  font-size: 1.02rem;
  font-weight: 650;
}

.process-promise__intro {
  margin: 0 0 var(--space-sm);
  font-size: 0.95rem;
  color: var(--color-text-muted);
  line-height: 1.55;
}

.process-promise__list {
  margin: 0;
  padding-left: 1.15rem;
  color: var(--color-text-muted);
  font-size: 0.95rem;
  line-height: 1.55;
}

.process-promise__list li + li {
  margin-top: 0.45rem;
}

@media (max-width: 800px) {
  .process-promise__grid {
    grid-template-columns: 1fr;
  }
}

/* Answer-first block (service detail pages) */
.section--answer-first {
  padding-top: 0;
}

.service-answer-first {
  margin: 0;
  padding: var(--space-lg);
  background: var(--color-surface);
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow);
}

.service-answer-first__title {
  margin: 0 0 var(--space-md);
  font-size: 1.2rem;
  font-weight: 700;
}

.service-answer-first__list {
  margin: 0;
  display: grid;
  gap: var(--space-md);
}

.service-answer-first__item dt {
  margin: 0 0 0.35rem;
  font-size: 0.92rem;
  font-weight: 650;
  color: var(--color-text);
}

.service-answer-first__item dd {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--color-text-muted);
}

/* Homepage entity / trust strip */
.section--entity .lead-muted {
  max-width: 52rem;
}

.entity-trust-list {
  margin: var(--space-md) 0 var(--space-sm);
  padding-left: 1.15rem;
  color: var(--color-text-muted);
  font-size: 0.95rem;
  line-height: 1.55;
}

.entity-trust-list li + li {
  margin-top: 0.35rem;
}

.entity-about-link-wrap {
  margin: var(--space-sm) 0 0;
  font-size: 0.98rem;
}

.entity-about-link-wrap a {
  font-weight: 600;
}

.fit-heading {
  margin: 0 0 var(--space-md);
  font-size: 1.35rem;
  font-weight: 700;
}

.fit-cols {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-lg);
  align-items: stretch;
}

.fit-col {
  display: flex;
  flex-direction: column;
  min-height: 0;
  background: var(--color-surface);
  border-radius: var(--radius);
  padding: var(--space-md) var(--space-lg);
  border: 1px solid var(--color-border);
}

.fit-col--yes {
  border-color: color-mix(in srgb, var(--color-accent) 22%, var(--color-border));
}

.fit-col h3 {
  margin: 0 0 var(--space-sm);
  font-size: 1.02rem;
  font-weight: 650;
}

.fit-list {
  margin: 0;
  padding-left: 1.15rem;
  color: var(--color-text-muted);
  font-size: 0.95rem;
  line-height: 1.55;
}

.fit-list li + li {
  margin-top: 0.4rem;
}

@media (max-width: 720px) {
  .fit-cols {
    gap: var(--space-md);
  }
}

@media (max-width: 399px) {
  .fit-cols {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .fit-col {
    display: block;
  }
}

.mobile-contact-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 160;
  box-sizing: border-box;
  align-items: stretch;
  justify-content: stretch;
  gap: 0.45rem;
  padding: 0.5rem 0.65rem calc(0.55rem + env(safe-area-inset-bottom, 0px));
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  box-shadow: 0 -6px 28px rgba(20, 18, 24, 0.1);
}

.mobile-contact-bar.is-visible {
  display: flex;
}

.mobile-contact-bar__btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0.35rem 0.4rem;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-weight: 650;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  color: var(--color-text);
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
}

.mobile-contact-bar__btn--call {
  color: var(--color-accent);
  background: var(--color-accent-soft);
  border-color: color-mix(in srgb, var(--color-accent) 25%, var(--color-border));
}

.mobile-contact-bar__btn:hover {
  color: var(--color-accent-hover);
  border-color: var(--color-accent);
}

body:has(.mobile-contact-bar.is-visible) {
  padding-bottom: 4.75rem;
}

.nav-drawer__contact {
  display: none;
}

.site-footer {
  background: var(--color-footer-bg);
  color: var(--color-footer-text);
  padding: var(--space-xl) var(--space-md);
  font-size: 0.95rem;
}

.site-footer a {
  color: var(--color-footer-link);
  transition: color 0.2s ease;
}

.site-footer a:hover {
  color: var(--color-footer-link-hover);
}

.site-footer :focus-visible {
  outline-color: #fff;
  outline-offset: 3px;
}

.site-footer .section-inner {
  max-width: var(--max-width);
}

.footer-grid {
  display: grid;
  gap: var(--space-lg);
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin-bottom: var(--space-lg);
}

.footer-legal-links {
  font-size: 0.9rem;
  margin: 0 0 var(--space-md);
}

.footer-legal-links a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer-note {
  font-size: 0.85rem;
  opacity: 0.88;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  padding-top: var(--space-md);
  margin: 0;
}

.impressum-content {
  margin: 0;
}

.impressum-content p {
  margin: 0.4rem 0;
}

.impressum-content p:first-child {
  margin-top: 0;
}

/* Mobile / tablet: slide-in navigation (burger) */
.nav-drawer-backdrop {
  display: none;
}

.nav-drawer {
  display: contents;
}

.nav-toggle {
  display: none;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  margin: 0;
  padding: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-surface);
  color: var(--color-text);
  cursor: pointer;
  box-shadow: none;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease;
}

.nav-toggle:hover {
  border-color: color-mix(in srgb, var(--color-accent) 35%, var(--color-border));
  color: var(--color-accent);
}

.nav-toggle:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
}

.nav-toggle__bars {
  position: relative;
  display: block;
  width: 1.25rem;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  transition:
    transform 0.2s ease,
    background 0.2s ease;
}

.nav-toggle__bars::before,
.nav-toggle__bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  transition:
    transform 0.2s ease,
    top 0.2s ease,
    opacity 0.2s ease;
}

.nav-toggle__bars::before {
  top: -0.4rem;
}

.nav-toggle__bars::after {
  top: 0.4rem;
}

.site-header.is-nav-open .nav-toggle__bars {
  background: transparent;
}

.site-header.is-nav-open .nav-toggle__bars::before {
  top: 0;
  transform: rotate(45deg);
}

.site-header.is-nav-open .nav-toggle__bars::after {
  top: 0;
  transform: rotate(-45deg);
}

@media (prefers-reduced-motion: reduce) {
  .nav-toggle__bars,
  .nav-toggle__bars::before,
  .nav-toggle__bars::after,
  .site-header.is-nav-open .nav-toggle__bars::before,
  .site-header.is-nav-open .nav-toggle__bars::after {
    transition: none;
  }
}

body.is-nav-open {
  overflow: hidden;
}

@media (max-width: 900px) {
  .nav-toggle {
    display: inline-flex;
    order: 4;
  }

  .header-actions .btn--header-cta {
    order: 2;
  }

  .header-actions .lang-switch-wrap {
    order: 3;
  }

  .nav-drawer-backdrop {
    display: block;
    position: fixed;
    z-index: 90;
    top: var(--header-h);
    left: 0;
    right: 0;
    height: calc(100vh - var(--header-h));
    min-height: calc(100vh - var(--header-h));
    margin: 0;
    padding: 0;
    border: none;
    background: rgba(15, 18, 22, 0.38);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition:
      opacity 0.22s ease,
      visibility 0.22s ease;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }

  .site-header.is-nav-open .nav-drawer-backdrop {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .nav-drawer {
    display: flex;
    flex-direction: column;
    position: fixed;
    z-index: 100;
    top: var(--header-h);
    left: 0;
    right: 0;
    height: calc(100vh - var(--header-h));
    min-height: calc(100vh - var(--header-h));
    width: 100%;
    max-width: 100%;
    padding: var(--space-lg) var(--space-md)
      calc(var(--space-xl) + env(safe-area-inset-bottom, 0px));
    background: var(--color-bg);
    border-top: 1px solid var(--color-border);
    box-shadow: 0 16px 48px rgba(15, 18, 22, 0.14);
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    /* clip-path avoids translateX off-screen; left 100% = hidden off to the right, opens R→L */
    clip-path: inset(0 0 0 100%);
    visibility: hidden;
    pointer-events: none;
    transition:
      clip-path 0.28s cubic-bezier(0.4, 0, 0.2, 1),
      visibility 0s linear 0.28s;
  }

  .site-header.is-nav-open .nav-drawer {
    clip-path: inset(0 0 0 0);
    visibility: visible;
    pointer-events: auto;
    transition:
      clip-path 0.28s cubic-bezier(0.4, 0, 0.2, 1),
      visibility 0s linear 0s;
  }

  @media (prefers-reduced-motion: reduce) {
    .nav-drawer {
      transition: none;
      clip-path: inset(0 0 0 100%);
    }

    .site-header.is-nav-open .nav-drawer {
      clip-path: inset(0 0 0 0);
    }

    .nav-drawer-backdrop {
      transition: none;
    }
  }

  .header-inner {
    flex-direction: row;
    align-items: center;
    flex-wrap: nowrap;
    gap: var(--space-sm);
  }

  .brand {
    min-width: 0;
    flex: 1 1 auto;
  }

  .brand-text {
    min-width: 0;
  }

  .brand-name,
  .brand-tag {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .header-actions {
    width: auto;
    flex: 0 0 auto;
    margin-left: auto;
    justify-content: flex-end;
    align-items: center;
    flex-wrap: nowrap;
    gap: var(--space-sm);
  }

  .site-nav {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    flex-wrap: nowrap;
    gap: 0;
  }

  .site-nav > a {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--color-border);
  }

  .site-nav > .nav-dropdown {
    border-bottom: 1px solid var(--color-border);
  }

  .nav-dropdown__summary {
    width: 100%;
    padding: 0.75rem 0;
    box-sizing: border-box;
  }

  .nav-dropdown__panel {
    position: static;
    margin: 0 0 var(--space-sm);
    padding-left: 0;
    padding-right: 0;
    box-shadow: none;
    border: none;
    border-radius: 0;
    background: transparent;
  }

  .nav-dropdown__panel a {
    padding-left: var(--space-sm);
  }

  .nav-drawer__contact {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.65rem;
    margin-top: var(--space-lg);
    padding-top: var(--space-lg);
    border-top: 1px solid var(--color-border);
    width: 100%;
    flex-shrink: 0;
  }

  .nav-drawer__contact-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-accent);
    text-decoration: none;
    word-break: break-word;
  }

  .nav-drawer__contact-link > span:not(.nav-drawer__contact-icon) {
    text-decoration: underline;
    text-underline-offset: 0.15em;
  }

  .nav-drawer__contact-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-accent);
  }

  .nav-drawer__contact-icon svg {
    display: block;
  }

  .nav-drawer__contact-link:hover > span:not(.nav-drawer__contact-icon) {
    text-decoration-thickness: 0.1em;
  }

  .nav-drawer__contact-link:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
  }
}

@media (max-width: 600px) {
  .header-actions .btn--header-cta {
    display: none;
  }
}
