/* 1. Die Custom Font aus dem Unterordner laden */
@font-face {
    font-family: 'FetteUNZFraktur';
    src: url('../fonts/FetteUNZFraktur.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

.navbar-brand.fraktur {
    font-family: 'FetteUNZFraktur', serif;
    font-size: 3em;
    line-height: 0.7em;

}
.navbar2{
    backdrop-filter: blur(10px); /* Edler Milchglas-Effekt an den Rändern */
    background: linear-gradient(to bottom,  rgba(33,37,41,1) 0%,rgba(255,255,255,0.7) 100%);
    border-radius: 0 0 16px 16px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15), 0 5px 15px rgba(0, 0, 0, 0.1);

}

/* Haupt-Layout, das verhindert, dass das Handy scrollt */
body {
    overflow: hidden;
    height: 100vh;
    margin: 0;
    display: flex; /* Legt Sidebar und Content nebeneinander */
    background-color: #f8f9fa;
}

/* Der Hauptcontainer, der jetzt alles umschließt */
.wrapper {
  position: relative;
  height: 100vh;
  width: 100vw;
  overflow: hidden;
  display: flex;
}

/* DIE DREIDIMENSIONAL DIAGONALE HINTERGRUND-EBENE */
.app-bg-container {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: -1; /* Liegt hinter dem Content */
  background-color: #111111; /* Dunkle Basis für den Tint */
  pointer-events: none; /* Klicks gehen durch den Hintergrund durch */
}

/* Ebene 1: Das obere Hintergrundbild mit 0.5 Opacity (Tint) */
.app-bg-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 75%; /* Geht bis knapp über die Mitte */
  background-size: cover;
  background-position: center;
  opacity: 0.45; /* Dein gewünschter Tint-Wert */
  transition: background-image 0.5s ease-in-out; /* Weicher Wechsel bei Tab-Änderung */
}

/* Ebene 2: Der hintere diagonale Layer (Dunkel-Beige/Goldton) */
.app-bg-diagonal-back {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 35%; /* Leicht höher als der vordere, um den "Doppel-Layer"-Effekt zu erzeugen */
  background-color: #d1c2a5; /* Dunklerer Sand/Beigeton aus dem Flyer */
  /* Diagonaler Schnitt von links oben nach rechts unten */
  clip-path: polygon(0 15%, 100% 0, 100% 100%, 0 100%);
}

/* Ebene 3: Der vordere diagonale Layer (Hell-Beige) */
.app-bg-diagonal-front {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 30%;
  background-color: #f1ebd9; /* Hellerer Haupt-Beigeton aus dem Flyer */
  /* Leicht versetzter diagonaler Schnitt für die 3D-Kante */
  clip-path: polygon(0 20%, 100% 0, 100% 100%, 0 100%);
}

.content-card-panel {
  backdrop-filter: blur(10px); /* Edler Milchglas-Effekt an den Rändern */
    background-color: rgba(255, 255, 255, 0.7) !important; /* Basis-Dunkelheit hinter dem Bild */
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15), 0 5px 15px rgba(0, 0, 0, 0.1);
  flex-grow: 1;
}

/* UNSERE NEUE FLEXIBLE SIDEBAR */
.sidebar-container {
    width: 65px; /* Eingefalteter Standard-Zustand */
    height: 100vh;
    background-color: #212529;
    transition: width 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    /* display: flex; */
    flex-direction: column;
    justify-content: space-between;
    z-index: 1030;
    overflow: hidden; /* Verhindert das Herausragen der Texte im schmalen Zustand */
    border-right: 1px solid #2b3035;
    flex-shrink: 0; /* Verhindert, dass die Sidebar schrumpft */
}

/* Der Zustand, wenn die Sidebar ausgeklappt ist */
.sidebar-container.expanded {
    width: 280px; /* Breite im geöffneten Zustand */
}

/* Header-Bereich mit Schließen-Icon */
.sidebar-header {
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    border-bottom: 1px solid #2b3035;
}

/* Im schmalen Zustand zentrieren wir das Menü-Icon und verstecken den Titel/Schließen-Button */
.sidebar-container:not(.expanded) .sidebar-header {
    justify-content: center;
    padding: 0;
}
.sidebar-container:not(.expanded) .sidebar-header h5,
.sidebar-container:not(.expanded) .sidebar-header .btn-close {
    display: none !important;
}

/* Verstecken der Texte in den Links im schmalen Zustand */
.sidebar-container:not(.expanded) .sidebar-link span {
    display: none !important;
}

/* Links im schmalen Zustand perfekt zentrieren */
.sidebar-container:not(.expanded) .sidebar-link {
    justify-content: center;
    padding: 12px 0;
}

/* Styling für die Sidebar-Links */
.sidebar-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 20px;
    color: #adb5bd;
    text-decoration: none;
    border-radius: 8px;
    transition: background 0.2s, color 0.2s;
    white-space: nowrap; /* Verhindert Zeilenumbruch beim Aufklappen */
}

.sidebar-link i {
    font-size: 1.25rem;
    min-width: 24px;
    text-align: center;
}

.sidebar-link:hover, .sidebar-link.active {
    background-color: #ffc107;
    color: #212529 !important;
    font-weight: bold;
}

/* Im schmalen Zustand die Sprachauswahl verstecken */
.sidebar-container:not(.expanded) .sidebar-footer {
    display: none !important;
}

/* DER MAIN-CONTENT BEREICH NEBEN DER SIDEBAR */
.app-content {
    flex-grow: 1;
    height: 100vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 54px 20px 20px 20px;
}

/* Custom Card Styling mit anpassbarer Bild-Opacity */
.bg-card-custom {
    position: relative;
    min-height: 140px;
    border: 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, box-shadow 0.2s;
    text-shadow: 0 0 1px rgba(0, 0, 0, 1), 0 0 2px rgba(0, 0, 0, 1), 0 0 3px rgba(0, 0, 0, 1), 0 0 4px rgba(0, 0, 0, 1), 0 0 5px rgba(0, 0, 0, 1);
}

/* Der Trick für die Opacity: Das Bild liegt auf einem Pseudo-Element im Hintergrund */
.bg-card-custom::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-image: var(--bg-img);
    background-size: cover;
    background-position: center;
    /* HIER DIE DECKKRAFT ANPASSEN (0.0 bis 1.0) */
    opacity: 0.5; 
    z-index: 1;
}
.bg-card-custom:hover::before  {
    opacity: 1;
    box-shadow: 0 0px 50px rgba(255, 255, 255, 1);
    transition: opacity 0.3s ease-in-out, box-shadow 0.3s ease-in-out; 
}
.bg-card-custom:hover {
    box-shadow: 0 0px 20px rgba(255, 255, 255, 0.5) !important;
    transition: box-shadow 0.3s ease-in-out; 
}

/* Sorgt dafür, dass der Text ÜBER dem Hintergrundbild liegt */
.bg-card-custom .card-body {
    position: relative;
    z-index: 2;
}

/* Leichter interaktiver Effekt beim Antippen/Hovern */
.bg-card-custom:active, .bg-card-custom:hover {
    transform: scale(0.98);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.home-event-item {
    padding: 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.home-event-item:last-child {
    border-bottom: none;
}

.home-event-info {
    flex: 1;
}

.home-event-link:hover {
    text-decoration: underline;
}
.no-text-shadow {
    text-shadow: none !important;
}

/* Responsive: Bei schmalen Bildschirmen Events oben anzeigen */
@media (max-width: 992px) {
    .event-box-row .order-lg-1 {
        order: -1 !important;
    }
    
    .event-box-row .order-lg-2 {
        order: 0 !important;
    }
}