/* ============================================================
   A-Z Pflege — Design Tokens (warm wohnzimmer, petrol accent)
   ============================================================ */

/* Lokale Schriften (DSGVO-konform, keine Google-Fonts-Verbindung) */
@font-face {
  font-family: 'Fraunces';
  font-style: italic;
  font-weight: 400 600;
  font-display: swap;
  src: url('fonts/Fraunces-latin-ext-italic-400600.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Fraunces';
  font-style: italic;
  font-weight: 400 600;
  font-display: swap;
  src: url('fonts/Fraunces-latin-italic-400600.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url('fonts/Fraunces-latin-ext-normal-400600.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url('fonts/Fraunces-latin-normal-400600.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/Inter-latin-ext-normal-400.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/Inter-latin-normal-400.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('fonts/Inter-latin-ext-normal-500.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('fonts/Inter-latin-normal-500.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('fonts/Inter-latin-ext-normal-600.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('fonts/Inter-latin-normal-600.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --primary: #1F5F5B;
  --primary-hover: #174845;
  --primary-soft: #E4EFEE;
  --primary-deep: #0F3937;

  --bg: #F5EDE0;
  --bg-alt: #EBE1D0;
  --card: #FBF6EC;
  --border: #E0D4BE;
  --border-soft: #EADFC8;

  --accent-warm: #C08456;
  --accent-warm-soft: #F4E4D4;

  --text: #2B2420;
  --text-muted: #7A6F66;
  --text-on-primary: #FBF6EC;

  --danger: #B04A3C;
  --danger-soft: #F5E4E1;
  --success: #5B7F4A;

  --shadow-sm: 0 1px 2px rgba(43, 36, 32, 0.04), 0 2px 6px rgba(43, 36, 32, 0.05);
  --shadow-md: 0 6px 18px rgba(43, 36, 32, 0.08);
  --shadow-lg: 0 20px 40px rgba(43, 36, 32, 0.12);
  --shadow-xl: 0 32px 64px rgba(43, 36, 32, 0.16);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;

  --serif: 'Fraunces', 'Lora', Georgia, serif;
  --sans: 'Inter', 'DM Sans', system-ui, sans-serif;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --container: 1240px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 110px;
  font-size: 18px;
}

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: -0.015em;
  line-height: 1.15;
  color: var(--text);
  font-variation-settings: 'SOFT' 30, 'opsz' 96;
}
h1 { font-size: clamp(40px, 5.2vw, 56px); }
h2 { font-size: clamp(30px, 3.8vw, 40px); }
h3 { font-size: clamp(22px, 2vw, 28px); }
h4 { font-size: 22px; }
p  { color: var(--text); }
a  { color: inherit; text-decoration: none; }
button { font-family: inherit; border: none; cursor: pointer; background: none; color: inherit; }
img { max-width: 100%; display: block; }

::selection { background: var(--primary); color: var(--text-on-primary); }

:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 3px;
  border-radius: 4px;
}

.container {
  width: min(var(--container), 100% - 48px);
  margin-inline: auto;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--primary);
}
.eyebrow::before {
  content: '';
  width: 26px; height: 1.5px;
  background: var(--primary);
}

.accent-serif {
  font-style: italic;
  color: var(--primary);
  font-variation-settings: 'SOFT' 100, 'WONK' 1, 'opsz' 144;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 28px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 500;
  font-family: var(--sans);
  transition: all 0.25s var(--ease);
  cursor: pointer;
  white-space: nowrap;
  line-height: 1;
  min-height: 48px;
}
.btn-primary {
  background: var(--primary);
  color: var(--text-on-primary);
  box-shadow: 0 4px 12px -2px rgba(0, 106, 110, 0.35);
}
.btn-primary:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 10px 24px -6px rgba(0, 106, 110, 0.45);
}
.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--text);
}
.btn-outline:hover {
  background: var(--text);
  color: var(--bg);
  transform: translateY(-2px);
}
.btn-ghost {
  color: var(--primary);
  padding: 10px 0;
  min-height: 0;
}
.btn-ghost:hover { color: var(--primary-hover); }

.btn .arrow {
  display: inline-block;
  transition: transform 0.25s var(--ease);
}
.btn:hover .arrow { transform: translateX(4px); }

/* ---------- Navigation ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 18px 0;
  transition: all 0.3s var(--ease);
  background: transparent;
}
.nav.scrolled {
  background: rgba(245, 237, 224, 0.92);
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
  padding: 12px 0;
  box-shadow: 0 1px 0 var(--border);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}
.logo img {
  height: 60px;
  width: auto;
}
.nav.scrolled .logo img { height: 52px; transition: height 0.3s var(--ease); }
.nav-menu {
  display: flex;
  list-style: none;
  gap: 8px;
  font-size: 15px;
  margin: 0 auto;
}
.nav-menu > li { position: relative; }
.nav-menu > li > a,
.nav-menu > li > button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  border-radius: 8px;
  color: var(--text);
  transition: all 0.2s var(--ease);
  font-weight: 700;
  font-family: var(--sans);
  font-size: inherit;
  line-height: 1;
  background: transparent;
  border: 0;
  cursor: pointer;
  letter-spacing: -0.005em;
}
.nav-menu > li > a:hover,
.nav-menu > li > button:hover {
  color: var(--primary);
  background: rgba(0, 106, 110, 0.06);
}
.nav-menu > li > a.active { color: var(--primary); }
.nav-menu .chev {
  width: 10px; height: 10px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg) translate(-2px, -2px);
  transition: transform 0.2s var(--ease);
}
.dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px;
  box-shadow: var(--shadow-lg);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px 20px;
  min-width: 420px;
  opacity: 0;
  pointer-events: none;
  transition: all 0.2s var(--ease);
  z-index: 10;
}
.nav-menu > li:hover > .dropdown,
.nav-menu > li:focus-within > .dropdown {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}
.dropdown a {
  display: block;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 14.5px;
  color: var(--text);
  transition: all 0.2s var(--ease);
}
.dropdown a:hover {
  background: var(--primary-soft);
  color: var(--primary);
}
.dropdown a small {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}
.nav-actions {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-shrink: 0;
}
.nav-phone {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  transition: color 0.2s;
}
.nav-phone:hover { color: var(--primary); }
.nav-phone:hover .ring-anim { animation: pulseOnce 0.6s ease; }
.nav-phone svg { color: var(--primary); }

.nav-burger {
  display: none;
  width: 44px; height: 44px;
  border-radius: 8px;
  place-items: center;
  background: var(--card);
  border: 1px solid var(--border);
}

@keyframes pulseOnce {
  0%,100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}

/* ---------- Footer ---------- */
.footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding: 80px 0 30px;
  margin-top: 60px;
}
.footer-top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 50px;
  border-bottom: 1px solid var(--border);
}
.footer-brand img { height: 72px; margin-bottom: 20px; }
.footer-brand p {
  font-size: 15px;
  color: var(--text-muted);
  margin-bottom: 20px;
  max-width: 300px;
}
.footer-contact-line {
  font-size: 14.5px;
  color: var(--text);
  line-height: 2;
}
.footer-contact-line a:hover { color: var(--primary); }
.footer-col h4 {
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--primary);
  font-weight: 600;
  margin-bottom: 20px;
}
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 10px; }
.footer-col a {
  font-size: 14.5px;
  color: var(--text);
  transition: all 0.2s var(--ease);
  display: inline-block;
}
.footer-col a:hover { color: var(--primary); padding-left: 4px; }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 30px;
  font-size: 13px;
  color: var(--text-muted);
  flex-wrap: wrap;
  gap: 16px;
}
.footer-social { display: flex; gap: 8px; }
.footer-social a {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--card);
  display: grid;
  place-items: center;
  transition: all 0.2s var(--ease);
  border: 1px solid var(--border);
}
.footer-social a:hover {
  background: var(--primary);
  color: var(--text-on-primary);
  border-color: var(--primary);
  transform: translateY(-2px);
}

/* ---------- Reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.reveal.in { opacity: 1; transform: translateY(0); }
.reveal.d1 { transition-delay: 0.08s; }
.reveal.d2 { transition-delay: 0.16s; }
.reveal.d3 { transition-delay: 0.24s; }
.reveal.d4 { transition-delay: 0.32s; }
.reveal.d5 { transition-delay: 0.40s; }

/* ---------- Floating Call ---------- */
.floating-call {
  position: fixed;
  bottom: 24px; right: 24px;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--primary);
  color: var(--text-on-primary);
  display: grid; place-items: center;
  box-shadow: 0 10px 28px -6px rgba(0, 106, 110, 0.5);
  z-index: 90;
  transition: all 0.3s var(--ease);
  opacity: 0; transform: translateY(80px);
  pointer-events: none;
}
.floating-call.show { opacity: 1; transform: translateY(0); pointer-events: auto; }
.floating-call:hover { background: var(--primary-hover); transform: scale(1.08); }
.floating-call::before {
  content: '';
  position: absolute; inset: 0;
  border-radius: 50%;
  border: 2px solid var(--primary);
  opacity: 0;
  animation: ring10s 10s ease-out infinite;
}
@keyframes ring10s {
  0%, 90%, 100% { transform: scale(1); opacity: 0; }
  92% { transform: scale(1); opacity: 0.7; }
  98% { transform: scale(1.8); opacity: 0; }
}

/* ---------- Mobile Bottom Bar ---------- */
.mobile-bar {
  display: none;
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: var(--card);
  border-top: 1px solid var(--border);
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  z-index: 95;
  gap: 10px;
}
.mobile-bar .btn { flex: 1; justify-content: center; padding: 12px; font-size: 14px; }
.mobile-bar .tel-btn {
  background: var(--card);
  border: 1.5px solid var(--primary);
  color: var(--primary);
}

/* ---------- Reduce motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- Responsive base ---------- */
@media (max-width: 1024px) {
  .nav-menu { display: none; }
  .nav-burger { display: grid; }
  .nav-phone .phone-text { display: none; }
  .footer-top { grid-template-columns: 1fr 1fr; gap: 32px; }
  .mobile-bar { display: flex; }
  .floating-call { bottom: 80px; }
  html { scroll-padding-top: 90px; }

  /* ----- Mobile Burger-Menu (Overlay) ----- */
  body.nav-open { overflow: hidden; }
  body.nav-open .nav {
    background: rgba(245, 237, 224, 0.98);
    backdrop-filter: blur(18px) saturate(1.2);
    -webkit-backdrop-filter: blur(18px) saturate(1.2);
  }
  body.nav-open .nav-menu {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 82px;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg);
    padding: 20px 24px 120px;
    gap: 4px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    z-index: 99;
    border-top: 1px solid var(--border);
    animation: nav-slide-in 0.25s var(--ease);
  }
  body.nav-open.nav.scrolled .nav-menu,
  body.nav-open .nav.scrolled ~ * .nav-menu {
    top: 76px;
  }
  .nav-menu > li {
    width: 100%;
    border-bottom: 1px solid var(--border);
  }
  .nav-menu > li:last-child { border-bottom: none; }
  .nav-menu > li > a,
  .nav-menu > li > button {
    display: flex;
    width: 100%;
    padding: 16px 8px;
    font-size: 17px;
    font-weight: 600;
    justify-content: flex-start;
    align-items: center;
    gap: 10px;
    min-height: 52px;
  }
  .nav-menu > li > button .chev {
    margin-left: auto;
    transition: transform 0.25s var(--ease);
  }
  .nav-menu > li.open > button .chev {
    transform: rotate(225deg) translate(-2px, -2px);
  }

  /* Dropdown auf Mobile: als ausklappbare Liste */
  .nav-menu .dropdown {
    position: static;
    display: none;
    grid-template-columns: 1fr;
    min-width: 0;
    opacity: 1;
    pointer-events: auto;
    transform: none;
    box-shadow: none;
    border: none;
    padding: 4px 0 12px 16px;
    background: transparent;
    margin: 0;
  }
  .nav-menu > li.open .dropdown {
    display: grid;
  }
  .nav-menu .dropdown a {
    padding: 12px 10px;
    font-size: 15px;
    min-height: 44px;
  }
  .nav-menu .dropdown a small {
    display: none;
  }

  /* Burger-Button: bei offenem Menue als X */
  .nav-burger {
    position: relative;
    z-index: 101;
    transition: transform 0.2s var(--ease);
  }
  body.nav-open .nav-burger svg line:nth-child(1) {
    transform: rotate(45deg) translate(3px, -3px);
    transform-origin: center;
    transition: transform 0.25s var(--ease);
  }
  body.nav-open .nav-burger svg line:nth-child(2) {
    opacity: 0;
    transition: opacity 0.15s var(--ease);
  }
  body.nav-open .nav-burger svg line:nth-child(3) {
    transform: rotate(-45deg) translate(3px, 3px);
    transform-origin: center;
    transition: transform 0.25s var(--ease);
  }

  @keyframes nav-slide-in {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
  }
}

@media (max-width: 640px) {
  html { font-size: 17px; }
  .container { width: min(var(--container), 100% - 32px); }
  .footer-top { grid-template-columns: 1fr; }

  /* Touch-Targets global mind. 44px fuer Interaktion */
  .btn { min-height: 48px; padding: 14px 22px; }
  .btn-ghost { min-height: 0; }
  .footer-col a { display: inline-block; padding: 4px 0; }

  /* Buttons duerfen bei schmalem Content umbrechen */
  .btn { white-space: normal; text-align: center; }

  /* Nav-Höhe reduziert auf Mobile */
  body.nav-open .nav-menu { top: 74px; }

  /* ----- Overrides fuer Inline-Styles in HTML (Mobile) ----- */
  /* Formular-Wrapper mit padding:56px werden auf Mobile kompakter */
  .form-wrap[style*="padding:56px"] {
    padding: 28px 20px !important;
  }
  /* 2-Spalten-Grids innerhalb von Multi-Step-Formularen werden 1-spaltig */
  .form-step > div[style*="grid-template-columns:1fr 1fr"],
  .two-col div[style*="grid-template-columns:1fr 1fr"] {
    grid-template-columns: 1fr !important;
  }
  /* 3-Spalten-Info-Grid unter dem Pflege-Anfrage-Formular */
  div[style*="grid-template-columns:repeat(3,1fr)"] {
    grid-template-columns: 1fr !important;
  }
  /* Kontakt-Formular 2-Spalten Telefon/E-Mail auf Mobile 1-spaltig */
  form#contactForm > div[style*="grid-template-columns:1fr 1fr"] {
    grid-template-columns: 1fr !important;
  }

  /* Page-Hero Padding reduzieren auf schmalen Screens */
  .page-hero { padding: 120px 0 40px; }

  /* Final-CTA Padding reduzieren */
  .final-cta-inner { padding: 40px 24px !important; }

  /* Hero-CTAs duerfen umbrechen */
  .hero-ctas { flex-wrap: wrap; }
  .hero-ctas .btn { flex: 1 1 auto; min-width: 0; }

  /* Stats-Grid auf sehr kleinen Screens 1-spaltig */
  .stats-grid { gap: 24px; }
}

/* Zwischen-Breakpoint fuer sehr kleine Smartphones */
@media (max-width: 380px) {
  html { font-size: 16px; }
  .container { width: min(var(--container), 100% - 24px); }
  .stats-grid { grid-template-columns: 1fr; gap: 20px; }
  body.nav-open .nav-menu { padding: 16px 16px 120px; }
  .nav-menu > li > a,
  .nav-menu > li > button { padding: 14px 6px; font-size: 16px; }
  h1 { font-size: clamp(32px, 7vw, 40px); }
  h2 { font-size: clamp(26px, 6vw, 32px); }
}
