/* =========================================================
   FAGO – custom.css (KORRIGIERT + MODAL FIX)
   - Header sticky (Topbar scrollt weg)
   - Footer immer unten (nicht fixed)
   - Boxed Layout in Topbar/Header/Content
   - Hero full width
   - Menü Styling + Joomla-Fallback
   - Bootstrap Modal Backdrop Fullscreen Fix
   ========================================================= */

/* =========================================================
   CSS VARIABLES
   ========================================================= */
:root {
  --bg-white: #ffffff;
  --bg-red: #cc3333;
  --bg-grey: #f5f5f5;

  --text-black: #000000;
  --text-red: #cc3333;
--surface:#ffffff; /* innen */
  --border-red: #cc3333;
  --color-surface: #ffffff;
  --layout-max: 1900px;
  --gutter-x: 1.5rem;
}

/* =========================================================
   BASE / LAYOUT-GRUNDGERUEST
   ========================================================= */
html, body {
  height: 100%;
}

body {
  background: var(--bg-white);
  color: var(--text-black);
  overflow-x: hidden;

  /* Sticky-Footer (Footer unten bei wenig Inhalt, scrollt normal) */
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Links */
a,
a:hover,
a:active,
a:visited,
a:focus {
  color: var(--text-black);
  text-decoration: none;
}

/* =========================================================
   BOXED LAYOUT (gezielt, nicht global)
   ========================================================= */
.topbar .container-fluid,
.site-header .container-fluid,
.site-content > .container-fluid {
  max-width: var(--layout-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--gutter-x);
  padding-right: var(--gutter-x);
}

/* =========================================================
   TOPBAR (scrollt weg)
   ========================================================= */
.topbar {
  background: var(--bg-white);
  font-size: .9rem;
  padding: .35rem 0;
}

.topbar .container-fluid {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.topbar a.topbar-brand {
  color: var(--text-red);
  font-weight: 700;
}

.topbar a:not(.topbar-brand) {
  color: var(--text-red);
  opacity: .95;
}

.topbar a:not(.topbar-brand):hover {
  text-decoration: underline;
  opacity: 1;
}

/* =========================================================
   HEADER (STICKY)
   ========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 2000;
  background: var(--bg-white);
  border-bottom: 1px solid var(--border-red);
}

/* =========================================================
   MENU / NAVIGATION
   ========================================================= */
.main-nav.navbar {
  background: var(--bg-white);
}

/* Mobile Toggler */
.navbar-toggler {
  border: 1px solid rgba(0,0,0,.15);
  border-radius: 1px;
  padding: .35rem .55rem;
}

.navbar-toggler:focus {
  box-shadow: 0 0 0 .2rem rgba(204,51,51,.2);
}

/* Bootstrap Menü */
.main-nav .navbar-nav .nav-link {
  color: var(--text-black);
  font-weight: 600;
  padding: .75rem 1rem;
  border-radius: 1px;
  transition: background .15s ease, color .15s ease;
}

.main-nav .navbar-nav .nav-link:hover {
  background: rgba(204,51,51,.08);
  color: var(--text-red);
}

.main-nav .navbar-nav .active > .nav-link,
.main-nav .navbar-nav .nav-link.active,
.main-nav .navbar-nav .current > .nav-link {
  background: rgba(204,51,51,.14);
  color: var(--text-red);
  border-radius: 1px;
}

/* Joomla Menü Fallback (mod-menu) */
.main-nav .mod-menu a {
  display: inline-block;
  padding: .75rem 1rem;
  font-weight: 600;
  color: var(--text-black);
  border-radius: 1px;
}

.main-nav .mod-menu a:hover {
  background: rgba(204,51,51,.08);
  color: var(--text-red);
  border-radius: 1px;
}

.main-nav .mod-menu .active > a,
.main-nav .mod-menu a.active,
.main-nav .mod-menu .current > a {
  background: rgba(204,51,51,.14);
  color: var(--text-red);
  border-radius: 1px;
}

/* =========================================================
   OFFCANVAS (MOBILE MENU)
   ========================================================= */
/* =========================================================
   OFFCANVAS MENU – Premium + saubere Ausrichtung (mit/ohne Icons)
   ========================================================= */
/* =========================================================
   OFFCANVAS MENU – Vertikal & ruhig (EMPFOHLEN)
   ========================================================= */
/* =========================================================
   OFFCANVAS MENU – Glasoptik + volle Breite (FINAL)
   ========================================================= */

/* Panel – leicht durchscheinend */
.offcanvas {
  width: 320px;
  background: rgba(255,255,255,.88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);

  box-shadow: 0 30px 80px rgba(0,0,0,.25);
  border-right: 1px solid rgba(0,0,0,.08);
}

/* Header */
.offcanvas-header {
  padding: 1.25rem 1rem;
  border-bottom: 1px solid rgba(0,0,0,.08);
}

.offcanvas-title {
  color: var(--text-red);
  font-weight: 900;
  font-size: 1.1rem;
}

/* Body */
.offcanvas-body {
  padding: 1rem;
}

/* Liste */
.offcanvas-menu ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

/* Menüpunkt untereinander */
.offcanvas-menu li {
  margin-bottom: .75rem;
}

/* Link über volle Breite */
.offcanvas-menu a {
  display: flex;
  align-items: center;
  gap: .85rem;

  width: 100%;
  padding: 1rem 1.1rem;

  border-radius: 14px;
  background: rgba(255,255,255,.65);
  border: 1px solid rgba(0,0,0,.06);

  font-size: 1rem;
  font-weight: 800;
  color: var(--text-black);
  text-decoration: none;

  transition: background .15s ease, border-color .15s ease, transform .1s ease;
}

/* Icon */
.offcanvas-menu a i,
.offcanvas-menu a .bi {
  color: var(--text-red);
  font-size: 1.05rem;
  min-width: 1.3rem;
}

/* Hover */
.offcanvas-menu a:hover {
  background: rgba(204,51,51,.08);
  border-color: rgba(204,51,51,.35);
  transform: translateY(-1px);
}

/* Aktiver Punkt */
.offcanvas-menu .active > a,
.offcanvas-menu a.active,
.offcanvas-menu .current > a {
  background: rgba(204,51,51,.15);
  border-color: rgba(204,51,51,.55);
  color: var(--text-red);
}
.offcanvas-menu .active > a {
  box-shadow: 0 8px 25px rgba(204,51,51,.25);
}


/* =========================================================
   HERO (FULL WIDTH)
   ========================================================= */
.hero-wrap {
  background: var(--bg-white);
  padding: .1rem 0;
}

/* Hero bleibt full width */
.hero-wrap .container-fluid {
  max-width: none;
  padding-left: 0;
  padding-right: 0;
}

.hero-card {
  display: flex;
  min-height: 400px;
  border-radius: 5px;
  overflow: hidden;
  background: var(--bg-red);
  box-shadow: 0 18px 50px rgba(0,0,0,.1);
}
.hero-left a {
  color: #fff;
}
.hero-left {
  color: #fff;
}

.hero-left-inner {
  padding: 2rem;
}

.hero-video {
  position: relative;
  overflow: hidden;
}

.hero-video video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media (max-width: 991.98px) {
  .hero-card {
    flex-direction: column;
  }
  .hero-video {
    min-height: 260px;
  }
}

/* =========================================================
   MAIN CONTENT
   ========================================================= */
/* Hintergrund über ganze Breite */
.site-content {
  background: var(--bg-white);
  flex: 1; /* wichtig: drückt Footer nach unten */
}

/* =========================================================
   CARDS
   ========================================================= */
.neumorphism-card,
.nostyle-card {
  background: var(--bg-white);
  border-radius: 5px;
}

.neumorphism-card-body,
.nostyle-card-body {
  padding: 1rem;
  color: #333;
}

.card-header {
  background: linear-gradient(135deg, var(--bg-white), rgba(204,51,51,.65));
  color: #fff;
  font-weight: 600;
  border-bottom: none;
}

/* =========================================================
   FOOTER (IMMER UNTEN, NICHT FIXED)
   ========================================================= */
.footer {
  margin-top: auto; /* schiebt Footer bei wenig Content nach unten */

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;

  background: var(--bg-red);
  color: #fff;
  padding: .6rem 1rem;
  font-size: .8em;
}
.footer-left,
.footer-left a,
.footer-left a:visited,
.footer-left a:hover,
.footer-left a:focus,
.footer-left a:active,
.footer-left a i {
  color: var(--text-red); !important;
}
.footer-center,
.footer-center a,
.footer-center a:visited,
.footer-center a:hover,
.footer-center a:focus,
.footer-center a:active,
.footer-center a i {
  color: #fff !important;
}
@media (max-width: 991.98px) {
  .footer {
    flex-direction: column;
    text-align: center;
  }
}
@media (min-width: 992px) {
  .main-nav .navbar-nav .nav-link,
  .main-nav .mod-menu a {
    padding: .65rem .95rem;
    border-radius: 10px;
    font-weight: 800;
  }
}
/* Optional: kleinere Schrift auf sehr kleinen Screens */
@media (max-width: 380px) {
  .offcanvas {
    width: 290px;
  }
  .offcanvas-menu a {
    padding: .75rem .75rem;
  }
}

/* =========================================================
   BOOTSTRAP MODAL – BACKDROP FIX (FULLSCREEN)
   ========================================================= */
.modal-backdrop {
  position: fixed !important;
  inset: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
}

/* Optional: Backdrop-Opacity feinjustieren */
.modal-backdrop.show {
  opacity: .65;
}
/* =========================================================
   MODAL vs STICKY HEADER FIX
   ========================================================= */

/* Modal immer ganz oben */
.modal {
  z-index: 3000;
}

.modal-backdrop {
  z-index: 2990;
}

/* Header & Burger-Menü unter Modal halten */
.site-header {
  z-index: 2000;
}

.navbar-toggler {
  z-index: 1000;
}

/* Während Modal offen ist: Header nicht klickbar */
body.modal-open .site-header {
  pointer-events: none;
}
