/* Dedicated mobile-first refinements layered on top of the premium desktop design. */
:root {
  --mobile-safe-bottom: max(10px, env(safe-area-inset-bottom));
}

html { scroll-padding-top: 118px; }
section[id], #ueber-uns { scroll-margin-top: 118px; }

a, button { -webkit-tap-highlight-color: transparent; }

.topbar-call {
  min-height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  color: #fff;
  text-decoration: none;
  line-height: 1.1;
}
.topbar-24 {
  padding-left: .65rem;
  margin-left: .1rem;
  border-left: 1px solid rgba(255,255,255,.4);
  opacity: .92;
}

.nav-call-mobile {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #f14951, #bf151e);
  color: #fff;
  box-shadow: 0 8px 22px rgba(216,41,50,.3);
  text-decoration: none;
}

.mobile-hero-emergency {
  display: flex;
  align-items: center;
  gap: .8rem;
  margin-bottom: 1.25rem;
  padding: .85rem 1rem;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 1rem;
  background: linear-gradient(135deg, rgba(240,72,80,.98), rgba(187,24,33,.96));
  color: #fff;
  text-decoration: none;
  box-shadow: 0 16px 34px rgba(151,13,21,.25);
}
.mobile-hero-emergency-icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(255,255,255,.16);
  flex: 0 0 auto;
}
.mobile-hero-emergency small,
.mobile-hero-emergency strong { display:block; }
.mobile-hero-emergency small { color: rgba(255,255,255,.78); font-size: .72rem; }
.mobile-hero-emergency strong { font-size: 1rem; }

.mobile-action-strip {
  background: #f7fbfa;
  border-bottom: 1px solid var(--border);
  padding: .25rem 0 1rem;
}
.mobile-action-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: .55rem;
}
.mobile-action-grid a {
  min-height: 82px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .35rem;
  border: 1px solid var(--border);
  border-radius: .95rem;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  text-align: center;
  box-shadow: var(--shadow-sm);
  padding: .6rem .35rem;
}
.mobile-action-grid a:first-child {
  color: #fff;
  background: linear-gradient(145deg, #e83b44, #bb1821);
  border-color: transparent;
}
.mobile-action-grid i { font-size: 1.15rem; color: var(--teal-700); }
.mobile-action-grid a:first-child i { color:#fff; }
.mobile-action-grid strong { display:block; font-size: .78rem; }
.mobile-action-grid small { display:block; color: var(--muted); font-size: .65rem; line-height:1.15; }
.mobile-action-grid a:first-child small { color: rgba(255,255,255,.78); }

.mobile-emergency-dock {
  position: fixed;
  z-index: 1060;
  left: 10px;
  right: 10px;
  bottom: var(--mobile-safe-bottom);
  min-height: 64px;
  display: grid;
  grid-template-columns: minmax(0,1fr) 70px;
  gap: 7px;
  padding: 6px;
  border-radius: 1.1rem;
  background: rgba(6,39,44,.94);
  box-shadow: 0 18px 48px rgba(0,0,0,.30);
  border: 1px solid rgba(255,255,255,.14);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}
.mobile-emergency-call {
  display: flex;
  align-items: center;
  gap: .7rem;
  padding: .65rem .85rem;
  border-radius: .85rem;
  background: linear-gradient(135deg, #f14951, #bd151e);
  color: #fff;
  text-decoration: none;
  min-width: 0;
}
.mobile-emergency-call .dock-icon {
  width: 38px;
  height: 38px;
  display:grid;
  place-items:center;
  border-radius: 50%;
  background: rgba(255,255,255,.15);
  flex: 0 0 auto;
}
.mobile-emergency-call small,
.mobile-emergency-call strong { display:block; line-height:1.05; }
.mobile-emergency-call small { font-size:.68rem; color:rgba(255,255,255,.76); text-transform:uppercase; letter-spacing:.06em; }
.mobile-emergency-call strong { font-size:1.03rem; margin-top:.15rem; white-space:nowrap; }
.mobile-route {
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:.15rem;
  border-radius:.85rem;
  background:rgba(255,255,255,.1);
  color:#fff;
  text-decoration:none;
  font-size:1.1rem;
}
.mobile-route small { font-size:.66rem; color:rgba(255,255,255,.72); }

@media (max-width: 991.98px) {
  body { padding-bottom: 92px; }
  .emergency-topbar { position: relative; z-index: 1042; }
  .premium-nav { top: 0; }
  .premium-nav .container { min-height: 68px; }
  .navbar-toggler { width: 42px; height: 42px; padding: .45rem; border-color: rgba(255,255,255,.16); border-radius: .75rem; }
  .brand-mark { width: 40px; height: 40px; }
  .brand-copy small { font-size: .68rem; }
  .brand-name { font-size: 1rem !important; }

  .offcanvas-lg.offcanvas-end { width: min(88vw, 380px); background: linear-gradient(160deg, #06272c, #0c3b40) !important; }
  .offcanvas-body { display: flex; flex-direction: column; padding: 1rem 1.25rem 2rem; }
  .offcanvas-header { border-bottom: 1px solid rgba(255,255,255,.1); padding: 1.2rem 1.25rem; }
  .offcanvas-kicker { color:#89d8cc; font-size:.72rem; letter-spacing:.12em; text-transform:uppercase; font-weight:800; }
  .mobile-menu-emergency { padding: 1rem; margin: .15rem 0 1rem; border-radius: 1rem; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.11); }
  .mobile-menu-emergency span, .mobile-menu-emergency strong { display:block; }
  .mobile-menu-emergency span { color:#ffb6ba; font-size:.75rem; text-transform:uppercase; letter-spacing:.08em; font-weight:800; }
  .mobile-menu-emergency strong { margin:.2rem 0 .8rem; }
  .offcanvas .navbar-nav { width:100%; gap:.15rem; }
  .offcanvas .nav-link { min-height: 48px; display:flex; align-items:center; padding:.8rem .9rem; border-radius:.75rem; border-bottom:1px solid rgba(255,255,255,.06); }
  .offcanvas .nav-link:hover, .offcanvas .nav-link:focus { background:rgba(255,255,255,.07); }
  .offcanvas .nav-emergency { background:rgba(216,41,50,.12); color:#ffb3b7 !important; }

  .hero-section .row { --bs-gutter-y: 1.75rem; }
  .hero-content .min-vh-75 { min-height: auto; }
  .hero-title { max-width: 760px; }
  .hero-image-card { max-width: 640px; margin-inline:auto; }

  .quick-facts-section .row { --bs-gutter-y: .65rem; }
  .quick-card { align-items:center; padding: 1rem; }
  .quick-card p { font-size: .88rem; }

  .section { padding: 4.5rem 0; }
  .emergency-panel > .row > [class*="col-"] { width: 100%; }
  .emergency-title { font-size: clamp(3rem, 11vw, 4.7rem); }
}

@media (max-width: 767.98px) {
  html { scroll-padding-top: 104px; }
  section[id], #ueber-uns { scroll-margin-top: 104px; }
  .container { --bs-gutter-x: 1.6rem; }

  .hero-section { background: radial-gradient(circle at 95% 8%, rgba(30,151,140,.32), transparent 27%), linear-gradient(155deg, #06272c 0%, #093d42 100%); }
  .hero-content > .row { padding-top: 1.5rem !important; padding-bottom: 2.5rem !important; }
  .hero-title { font-size: clamp(2.45rem, 11.5vw, 3.8rem); line-height: 1.02; margin-bottom: 1rem !important; }
  .hero-lead { font-size: 1.02rem; margin-bottom: 1.15rem !important; }
  .hero-section .eyebrow { font-size:.64rem; letter-spacing:.13em; }
  .hero-section .btn { min-height: 50px; border-radius: .9rem; font-size: .95rem; }
  .hero-trust { margin-top: 1rem !important; }
  .hero-trust .col-sm-4 { width: 100%; }
  .trust-item { min-height: 48px; padding:.55rem .7rem; border-radius:.75rem; background:rgba(255,255,255,.055); border:1px solid rgba(255,255,255,.08); }
  .trust-item span br { display:none; }
  .hero-image-card { padding:.55rem; border-radius:1.25rem; }
  .hero-placeholder { min-height: 280px; border-radius:.95rem; }
  .availability-badge { width:100px; height:100px; right:10px; bottom:12px; border-width:3px; }
  .availability-badge strong { font-size:1.55rem; }

  .quick-facts-section .container { padding-top: .85rem !important; padding-bottom:.85rem !important; }
  .quick-card { border-radius:.9rem; box-shadow:none; }
  .icon-circle { width:42px; height:42px; flex-basis:42px; }

  .section-heading { margin-bottom: .4rem; }
  .section-heading h2 { font-size: clamp(2rem, 9vw, 2.75rem); line-height:1.02; }
  .section-note { font-size:.9rem; }
  .section { padding: 3.6rem 0; }
  .section-soft { background: #f2f8f7; }

  .service-card { min-height:64px; padding:.85rem; border-radius:.85rem; box-shadow:none; }
  .service-card i { width:38px; height:38px; min-width:38px; }
  .service-card span { font-size:.9rem; line-height:1.25; }
  .service-card:hover { transform:none; }

  .content-card { padding: 1.15rem; border-radius:1rem; box-shadow:none; }
  .content-card h2.h2 { font-size:1.75rem; }
  .content-card .row { --bs-gutter-y: 1.25rem; }
  .info-line { margin-bottom:.9rem; font-size:.9rem; }
  .image-placeholder { min-height:220px; }

  .emergency-section { padding-top:3rem; padding-bottom:3rem; }
  .emergency-panel { padding:1rem; border-left-width:5px; border-radius:1rem; box-shadow:none; }
  .emergency-title { font-size: clamp(3.2rem, 16vw, 4.5rem); margin-top:.35rem; }
  .emergency-call-card { position:relative; padding:1rem; border-radius:.9rem; }
  .emergency-call-card::after { content:'Tippen zum Anrufen'; position:absolute; right:.85rem; top:.75rem; font-size:.6rem; color:rgba(255,255,255,.7); text-transform:uppercase; letter-spacing:.04em; }
  .emergency-call-card strong { font-size:1.5rem; }
  .emergency-list-card, .mini-info-card { padding:1rem; border-radius:.9rem; }
  .emergency-list li { padding:.62rem 0 .62rem 1.4rem; font-size:.88rem; }
  .mini-info-card li { margin-bottom:.45rem; font-size:.86rem; }

  .first-aid-step { grid-template-columns:36px 1fr; gap:.65rem; padding:.8rem 0; font-size:.88rem; }
  .first-aid-step > span { width:32px; height:32px; }
  .first-aid-step ul { padding-left:1rem; }
  .callout-box { font-size:.9rem; }

  #aktuelles .content-card ul { padding-left:1.15rem; }
  #aktuelles .content-card li, #aktuelles .content-card p { font-size:.9rem; }

  .site-footer .container { padding-top:2.25rem !important; padding-bottom:2rem !important; }
  .footer-emergency { margin-top:.35rem; }
  .footer-emergency a { font-size:1.35rem; }
}

@media (max-width: 575.98px) {
  .emergency-topbar { font-size:.72rem; }
  .topbar-call { min-height: 35px; gap:.38rem; }
  .topbar-24 { padding-left:.45rem; }
  .premium-nav .container { min-height:62px; }
  .navbar-brand { max-width: calc(100% - 98px); }
  .brand-copy small { display:block; max-width:150px; overflow:hidden; white-space:nowrap; text-overflow:ellipsis; }

  .mobile-hero-emergency { margin-top:.15rem; }
  .hero-section .d-flex.flex-wrap.gap-3 { display:grid !important; grid-template-columns:1fr; gap:.6rem !important; }
  .hero-image-card { margin-top:.35rem; }
  .hero-placeholder { min-height:235px; }
  .availability-badge { width:88px; height:88px; }
  .availability-badge strong { font-size:1.35rem; }
  .availability-badge span { font-size:.6rem; }

  .mobile-action-grid { gap:.4rem; }
  .mobile-action-grid a { min-height:76px; border-radius:.8rem; }
  .mobile-action-grid strong { font-size:.72rem; }
  .mobile-action-grid small { font-size:.59rem; }

  .section { padding:3rem 0; }
  .section-heading h2 { font-size:2rem; }
  .content-card h2.h2 { font-size:1.55rem; }
  .image-placeholder { min-height:185px; }

  .emergency-panel { margin-left:-.1rem; margin-right:-.1rem; }
  .emergency-title { font-size:3.55rem; }
  .emergency-call-card strong { font-size:1.35rem; }
  .emergency-call-card::after { display:none; }

  .mobile-emergency-dock { left:7px; right:7px; grid-template-columns:minmax(0,1fr) 62px; }
  .mobile-emergency-call { padding:.58rem .7rem; gap:.55rem; }
  .mobile-emergency-call .dock-icon { width:34px; height:34px; }
  .mobile-emergency-call strong { font-size:.95rem; }

  .site-footer .col-6 { width:100%; }
}

@media (max-width: 370px) {
  .topbar-24 { display:none; }
  .brand-copy small { max-width:125px; }
  .hero-title { font-size:2.25rem; }
  .mobile-action-grid { grid-template-columns:1fr; }
  .mobile-action-grid a { min-height:58px; flex-direction:row; text-align:left; justify-content:flex-start; padding:.6rem .8rem; }
  .mobile-action-grid i { width:26px; text-align:center; }
  .mobile-action-grid small { font-size:.64rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior:auto !important; transition:none !important; animation:none !important; }
}

/* ============================================================
   Mobile navigation V2 — robust dedicated offcanvas drawer
   ============================================================ */
@media (max-width: 991.98px) {
  .mobile-nav-drawer {
    --bs-offcanvas-width: min(92vw, 410px);
    --bs-offcanvas-zindex: 1095;
    width: var(--bs-offcanvas-width) !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    color: #fff;
    background:
      radial-gradient(circle at 90% 5%, rgba(29,151,140,.28), transparent 30%),
      linear-gradient(165deg, #06272c 0%, #08353a 55%, #0b4246 100%) !important;
    border-left: 1px solid rgba(255,255,255,.10) !important;
    box-shadow: -24px 0 70px rgba(0,0,0,.34);
    overflow: hidden;
  }

  .offcanvas-backdrop {
    --bs-backdrop-zindex: 1085;
    z-index: 1085 !important;
    background-color: #021417;
  }
  .offcanvas-backdrop.show { opacity: .72; }

  .mobile-nav-header {
    flex: 0 0 auto;
    min-height: 108px;
    padding: calc(1.2rem + env(safe-area-inset-top)) 1.25rem 1.2rem;
    border-bottom: 1px solid rgba(255,255,255,.10);
    background: rgba(7,47,53,.88);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
  }

  .mobile-nav-mark {
    width: 46px;
    height: 46px;
    flex: 0 0 46px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,.18);
    background: rgba(255,255,255,.07);
    color: #a5e2d8;
    font-size: 1.3rem;
  }

  .mobile-nav-header .offcanvas-title {
    color: #fff;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(1.25rem, 5.8vw, 1.7rem);
    line-height: 1.08;
  }

  .mobile-nav-close {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    padding: .75rem;
    margin: 0;
    border-radius: 50%;
    background-color: rgba(255,255,255,.08);
    opacity: .95;
  }

  .mobile-nav-body {
    min-height: 0;
    height: calc(100dvh - 108px);
    display: flex !important;
    flex-direction: column;
    gap: 1rem;
    padding: 1rem 1rem calc(1.15rem + env(safe-area-inset-bottom));
    overflow-y: auto !important;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }

  .mobile-menu-emergency-call {
    display: flex;
    align-items: center;
    gap: .8rem;
    padding: .85rem .9rem;
    min-height: 74px;
    border-radius: 1rem;
    color: #fff;
    text-decoration: none;
    background: linear-gradient(135deg, #f04a52 0%, #d92731 52%, #b8131c 100%);
    border: 1px solid rgba(255,255,255,.18);
    box-shadow: 0 16px 34px rgba(151,13,21,.28);
  }

  .mobile-menu-emergency-icon {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: rgba(255,255,255,.15);
    font-size: 1.15rem;
  }
  .mobile-menu-emergency-call small,
  .mobile-menu-emergency-call strong { display: block; line-height: 1.1; }
  .mobile-menu-emergency-call small { color: rgba(255,255,255,.78); font-size: .67rem; letter-spacing: .04em; text-transform: uppercase; }
  .mobile-menu-emergency-call strong { margin-top: .25rem; color: #fff; font-size: 1.2rem; }

  .mobile-menu-links {
    display: grid;
    gap: .4rem;
  }

  .mobile-menu-link {
    min-height: 56px;
    display: flex;
    align-items: center;
    gap: .8rem;
    padding: .65rem .8rem;
    border-radius: .85rem;
    color: rgba(255,255,255,.92) !important;
    text-decoration: none;
    font-weight: 700;
    background: rgba(255,255,255,.045);
    border: 1px solid rgba(255,255,255,.07);
  }

  .mobile-menu-link:active,
  .mobile-menu-link:focus,
  .mobile-menu-link:hover {
    color: #fff !important;
    background: rgba(255,255,255,.09);
  }

  .mobile-menu-link-icon {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    display: grid;
    place-items: center;
    border-radius: .7rem;
    background: rgba(126,214,202,.12);
    color: #9fe0d6;
  }

  .mobile-menu-link-emergency {
    color: #fff !important;
    background: rgba(216,41,50,.15);
    border-color: rgba(255,129,136,.18);
  }
  .mobile-menu-link-emergency .mobile-menu-link-icon {
    color: #ffb8bc;
    background: rgba(216,41,50,.20);
  }

  .mobile-menu-info {
    display: grid;
    gap: .55rem;
    padding: .85rem;
    border-radius: .95rem;
    background: rgba(255,255,255,.045);
    border: 1px solid rgba(255,255,255,.07);
  }
  .mobile-menu-info > div {
    display: flex;
    align-items: flex-start;
    gap: .7rem;
    color: #fff;
  }
  .mobile-menu-info i { color: #8ed9ce; margin-top: .05rem; }
  .mobile-menu-info small,
  .mobile-menu-info strong { display: block; }
  .mobile-menu-info small { color: rgba(255,255,255,.55); font-size: .67rem; text-transform: uppercase; letter-spacing: .05em; }
  .mobile-menu-info strong { margin-top: .05rem; color: rgba(255,255,255,.88); font-size: .82rem; }

  .mobile-menu-route {
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: .85rem;
    color: #fff;
    font-weight: 700;
    border: 1px solid rgba(255,255,255,.18);
    background: rgba(255,255,255,.07);
  }
  .mobile-menu-route:hover,
  .mobile-menu-route:focus { color: #fff; background: rgba(255,255,255,.11); }

  /* The fixed emergency dock must never sit on top of the open menu. */
  body.mobile-menu-open .mobile-emergency-dock { opacity: 0; visibility: hidden; pointer-events: none; transform: translateY(18px); }
  .mobile-emergency-dock { transition: opacity .18s ease, visibility .18s ease, transform .18s ease; }
}

/* V4 — mobile location map */
@media (max-width: 991.98px) {
  .location-shell { border-radius: 1.2rem; }
  .location-map-link { min-height: 430px; }
}
@media (max-width: 767.98px) {
  #standort { scroll-margin-top: 104px; }
  .location-heading { margin-bottom: .35rem; }
  .location-shell {
    margin-left: -.15rem;
    margin-right: -.15rem;
    box-shadow: none;
    border-radius: 1.05rem;
  }
  .location-info {
    padding: 1.25rem;
  }
  .location-title {
    font-size: 2rem;
    margin-bottom: 1.15rem;
  }
  .location-detail {
    grid-template-columns: 40px minmax(0, 1fr);
    gap: .7rem;
    padding: .75rem 0;
  }
  .location-detail-icon { width: 38px; height: 38px; }
  .location-detail strong { font-size: .9rem; }
  .location-route-btn {
    align-self: stretch;
    width: 100%;
    margin-top: 1.15rem;
    min-height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  .location-map-link {
    min-height: 0;
    height: auto;
  }
  .location-map-link picture,
  .location-map-img {
    height: auto;
  }
  .location-map-img {
    object-fit: contain;
    width: 100%;
  }
  .location-map-badge {
    left: .8rem;
    top: .8rem;
    padding: .62rem .72rem;
    border-radius: .8rem;
  }
}


/* V5 — mobile emergency steps + FAQ */
@media (max-width: 991.98px) {
  #faq { scroll-margin-top: 104px; }
  .notfall-steps-section { padding-top:.85rem; }
  .notfall-steps-grid { grid-template-columns:1fr; }
  .notfall-step { min-height:86px; }
  .faq-intro { position:static; }
}
@media (max-width: 767.98px) {
  .notfall-steps-shell { padding:1rem; border-radius:1rem; box-shadow:none; }
  .notfall-steps-title { font-size:2rem; }
  .notfall-step { grid-template-columns:44px 1fr; padding:.85rem; }
  .notfall-step > i { width:44px; height:44px; font-size:1.05rem; }
  .notfall-step strong { font-size:.92rem; }
  .notfall-step small { font-size:.78rem; }
  .faq-section .row { --bs-gutter-y:1.6rem; }
  .faq-intro h2 { font-size:2rem; }
  .faq-call-btn { width:100%; min-height:52px; display:inline-flex; align-items:center; justify-content:center; }
  .premium-accordion .accordion-button { padding:1rem; font-size:.92rem; line-height:1.35; }
  .premium-accordion .accordion-button::after { width:2rem; height:2rem; flex:0 0 2rem; }
  .premium-accordion .accordion-body { padding:0 1rem 1rem; font-size:.9rem; }
}


/* V6.8 real-photo mobile sizing */
@media (max-width: 767.98px) {
  .hero-image-card { overflow: visible; }
  .hero-photo { min-height: 280px; }
}
@media (max-width: 390px) {
  .hero-photo { min-height: 235px; }
}
