/* Comic Neue - Regular */
@font-face {
  font-family: 'Comic Neue';
  font-style: normal;
  font-weight: 400;
  src: url('fonts/ComicNeue-Regular.ttf') format('truetype');
}

/* Comic Neue - Bold */
@font-face {
  font-family: 'Comic Neue';
  font-style: normal;
  font-weight: 700;
  src: url('fonts/ComicNeue-Bold.ttf') format('truetype');
}
/* 3. Und spezielle Zuweisungen für Überschriften etc. */
h1, h2, h6, .MenuBarHorizontal a {
    font-family: 'Comic Neue', sans-serif;
    font-weight: 700;
}
/* ==========================================================================
   1. GLOBALE STILE (Für alle Seiten gleich)
   ========================================================================== */
html, body {
    width: 100%;
    margin: 0;
    padding: 0;
    overflow-x: hidden; /* Das verhindert das seitliche Wackeln/Scrollen */
    background-color: #000; /* schwarz */
    font-family: 'Comic Neue', sans-serif; /* Primäre Schrift */    font-size: 15px;
    color: #333;
}

body {
	background-image: url(bilder/Hintergrund/hg_0.jpg);
	background-repeat: repeat;
}

#wrapper {
    max-width: 800px;
    width: 100%;
    margin: 0 auto;
    position: relative;
    background-color: white;
    min-height: 100vh; /* Mindestens so hoch wie der Bildschirm */
    display: flex;
    flex-direction: column; /* Stapelt Inhalt von oben nach unten */
}

/* ==========================================================================
   2. NAVIGATION (Farbstufen, Pfeile & Logik)
   ========================================================================== */

#navi { 
    background-color: #333; 
    width: 100%; 
    position: relative; 
    z-index: 1000; 
}

/* Der Mobile-Button */
.menu-button {
    display: none;
    width: 100%;
    padding: 15px;
    background: #444;
    color: white;
    border: none;
    font-size: 18px;
    cursor: pointer;
    text-align: left;
}

.MenuBarHorizontal {
    width: 100% !important;
    list-style: none;
    margin: 0; padding: 0;
    display: flex;
}

.MenuBarHorizontal li { 
    flex: 1; 
    position: relative; 
}

/* Ebene 1: Hauptmenü */
.MenuBarHorizontal a {
    display: block;
    padding: 12px 10px;
    color: white;
    text-decoration: none;
    background-color: #333;
    text-align: center;
    border-right: 1px solid #444;
    transition: background 0.3s;
}

/* Ebene 2: Untermenü (Dunkelgrau) */
.submenu {
    display: none; /* Versteckt das Menü standardmäßig */
    position: absolute;
    top: 100%; left: 0;
    list-style: none;
    padding: 0; margin: 0;
    min-width: 230px;
    background-color: #444; 
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.submenu a {
    text-align: left !important;
    background-color: #444 !important;
    border-bottom: 1px solid #555;
    border-right: none;
}

/* Ebene 3 & 4: (Graublau) */
.submenu .submenu {
    top: 0;
    left: 100%; 
    background-color: #4a5568; 
}

.submenu .submenu a {
    background-color: #4a5568 !important;
    border-bottom: 1px solid #5a6778;
}

/* --- LOGIK: EINBLENDEN BEIM HOVERN --- */
.MenuBarHorizontal li:hover > .submenu {
    display: block !important;
}

/* Hover-Effekt Gold-Orange */
.MenuBarHorizontal a:hover {
    background-color: #fbb03b !important;
    color: #333 !important;
}

/* --- Pfeil-Indikatoren --- */
.MenuBarHorizontal > li > a:not(:last-child):after {
    content: ' ▾';
    font-size: 10px;
    opacity: 0.7;
}

.submenu li > a:not(:last-child):after {
    content: ' ▸';
    float: right;
    margin-left: 10px;
}

/* --- Spezial: Zweispaltige Materialliste auf Desktop --- */
@media (min-width: 801px) {
    .submenu-material {
        min-width: 450px !important;
        column-count: 2;
        column-gap: 0;
    }
    .submenu-material li { break-inside: avoid; }
}

/* --- Mobile Optimierung --- */
@media (max-width: 800px) {
    .menu-button { display: block; }
    .MenuBarHorizontal {
        display: none;
        flex-direction: column;
    }

    .MenuBarHorizontal.mobile-open { display: flex; }
    .submenu, .submenu .submenu {
        position: static; 
        width: 100%;
        background-color: #444 !important;
    }
    .MenuBarHorizontal a { text-align: left; padding-left: 20px; border-right: none; }
    .submenu a { padding-left: 40px !important; }
    .submenu .submenu a { padding-left: 60px !important; }
    .MenuBarHorizontal a:after { content: '' !important; }
}
/* --- NEU: ZUM AUSKLAPPEN DER UNTERMENÜS --- */
    
    /* Versteckt Untermenüs auf Mobile standardmäßig */
    .MenuBarHorizontal .submenu {
        display: none !important; 
    }

    /* Zeigt das Untermenü nur, wenn das li die Klasse 'mobile-open' hat */
    .MenuBarHorizontal li.mobile-submenu-active > .submenu {
        display: block !important;
        position: static;
        width: 100%;
    }

    /* Kleiner Pfeil nach unten als Hinweis zum Klicken */
    .MenuBarHorizontal li > a:not(:last-child):after {
        content: ' ▾' !important;
        float: right;
    }
/* ==========================================================================
   3. STARTSEITE (Hero, Baum, Spalten)
   ========================================================================== */

.image-container { position: relative; width: 100%; line-height: 0; }
.image-container img { width: 100%; height: auto; display: block; }

.text {
    position: absolute;
    top: 5%; 
    left: 4%; 
    width: 60%;
    color: white;
    font-family: 'Comic Neue', sans-serif;
    font-weight: bold; /* Macht die Headline fett */
    font-size: 6vw;
    line-height: 1.1em;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8);
    z-index: 5;
    pointer-events: none;
}

@media (min-width: 800px) {
    .text { font-size: 48px; top: 20px; left: 20px; }
}

.tooltip {
    position: absolute;
    top: 20px; right: 20px;
    background-color: rgba(150, 0, 0, 0.85);
    color: #fff;
    padding: 15px;
    border-radius: 5px;
    display: none;
    z-index: 20;
    font-size: 14px;
    max-width: 250px;
    line-height: 1.4em;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

.custom-div {
    width: 100%; background-color: #fbb03b; color: #573d14;
    padding: 10px; box-sizing: border-box; text-align: center;
}

.custom-div h6 { font-family: 'Comic Neue', sans-serif; font-size: 26px; margin: 0; }
.custom-div p { margin: 5px 0 0 0; font-size: 14px; font-weight: bold; text-transform: uppercase; }

.container { display: flex; flex-wrap: wrap; width: 100%; }
.col { flex: 1; min-width: 250px; padding: 25px; box-sizing: border-box; }

.col-engagement { background-color: #99ff99; }
.col-aktuelles { background-color: #66ccff; }
.col-info { background-color: #ff9999; }

.col h2 { font-family: 'Comic Neue', sans-serif; font-size: 20px; border-bottom: 1px solid rgba(0,0,0,0.2); padding-bottom: 5px; margin-bottom: 15px; }

#footer {
    flex-shrink: 0; /* Verhindert, dass der Footer gestaucht wird */
    padding: 15px 20px;
    background-color: #fbb03b;
    text-align: center;
}

/* ==========================================================================
   4. FOLGESEITEN
   ========================================================================== */
.content-page { 
    background-color: white; 
    padding: 40px 30px; 
	box-sizing: border-box; /* Wichtig für die korrekte Breite */
    flex: 1 0 auto; /* Drückt den Footer nach unten */
	padding-bottom: 2px; /* Reduziert den Abstand zum Footer massiv */
}
.content-page h1 { 
    font-family: 'Comic Neue', sans-serif; 
    color: #333;
    font-size: 28px; 
	border-bottom: 3px solid #fbb03b; 
	display: inline-block; 
}
.content-text { font-family: 'Comic Neue', sans-serif; 
    font-size: 15px; line-height: 1.7; 
}
/* Macht alle Bilder innerhalb von Content-Seiten responsive */
.content-page img {
    max-width: 100%;
    height: auto;
    display: block; /* Verhindert kleine Abstände unter dem Bild */
    margin: 20px 0; /* Optional: Abstand oben und unten */
}
/* Das Kunstbild innerhalb des Grids */
.art-box {
    display: flex;
    justify-content: center;
    align-items: center;
    background: none !important; /* Kein grauer Hintergrund für das Bild */
    border: none !important;
}

.grid-art {
    max-width: 100%;
    height: auto;
    border: 5px solid white;
    box-shadow: 0 5px 7px rgba(0,0,0,0.3);
    transform: rotate(-2deg); /* Ein kleiner künstlerischer Akzent */
    display: block; /* Verhindert den vertikalen Abstand unter dem Bild */
    margin-bottom: 0;
}

/* --- Stile für Unterseiten & Listen --- */
.teacher-info {
    font-size: 1.2em;
    color: #4a5568;
    margin-bottom: 20px;
}

.material-list {
    list-style-type: none;
    padding: 0;
}

.material-list li {
    padding: 8px 0;
    border-bottom: 1px dotted #ccc;
}

.material-list li:before {
    content: "✓ ";
    color: #fbb03b;
    font-weight: bold;
}

/* Der schicke Download-Button */
.download-box {
    margin-top: 30px;
    padding: 20px;
    background-color: #f8f9fa;
    border-radius: 8px;
    text-align: center;
}

.download-btn {
    display: inline-block;
    padding: 12px 25px;
    background-color: #fbb03b;
    color: #333 !important;
    text-decoration: none;
    font-weight: bold;
    border-radius: 5px;
    transition: transform 0.2s;
}

.download-btn:hover {
    transform: scale(1.05);
    background-color: #e59f2d;
}

.back-link {
    display: inline-block;
    margin-top: 20px;
    color: #666;
    text-decoration: none;
}

/* Markierung für die aktuelle Seite im Menü */
.MenuBarHorizontal a.active {
    background-color: #fbb03b !important;
    color: #333 !important;
    font-weight: bold;
}

.leitziele-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 10px;
    margin-bottom: -10px; /* Zieht das untere Element leicht nach unten */
}

.leitziel-item {
    flex: 1 1 45%; /* Zweispaltig auf Desktop */
    display: flex;
    align-items: flex-start;
    margin-bottom: 10px;
    background: #fdfdfd;
    padding: 8px;
    border-radius: 5px;
}
.leitziel-info ul {
    margin: 2px 0 0 0;
    padding-left: 15px;
    list-style-type: disc;
}
.leitziel-info ul li {
    line-height: 1.2;    /* Verringert den Abstand zwischen den Zeilen */
    margin-bottom: 2px;  /* Minimaler Abstand zwischen den Punkten */
}

.leaf-icon {
    width: 30px;
    margin-right: 15px;
    margin-top: 3px;
}
.leitziel-item.art-box {
    margin-bottom: 0; /* Entfernt den unteren Außenabstand dieser speziellen Box */
    padding-bottom: 0; /* Entfernt den unteren Innenabstand dieser Box */
}
@media (max-width: 600px) {
    .leitziel-item { flex: 1 1 100%; } /* Einspaltig auf Mobile */
}

/* --- Bildergalerie für Standorte --- */
.image-gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 5px;
}

.gallery-item {
    flex: 1 1 230px; /* Bilder sind mindestens 300px breit und teilen sich den Platz */
    margin-bottom: 5px;
}

.gallery-item figure {
    margin: 0;
    padding: 0;
}

.gallery-item img {
    width: 100%;
    height: auto;
    border-radius: 4px; /* Etwas dezentere Rundung für den kompakten Look */
    box-shadow: 0 1px 4px rgba(0,0,0,0.1);
    display: block;
}

.gallery-item figcaption {
    margin-top: 5px;
    font-size: 13px;    /* Schrift etwas kleiner für die kompakte Ansicht */
    color: #555;
    text-align: center;
    line-height: 1.2;
}

/* Auf dem Handy sollen die Bilder vollflächig sein */
@media (max-width: 600px) {
    .gallery-item {
        flex: 1 1 100%;
    }
}

/* Sondergröße für das Hauptbild */
.gallery-item.featured {
    flex: 1 1 100%; /* Nimmt die volle Breite ein */
    margin-bottom: 15px;
}

.gallery-item.featured img {
    max-height: 450px; /* Verhindert, dass das Bild auf riesigen Monitoren zu hoch wird */
    object-fit: cover; /* Sorgt dafür, dass das Bild den Platz schön ausfüllt */
}

/* Verhindert, dass 2 Personen-Bilder größer werden als in einer 3er-Reihe */
.gallery-small .gallery-item {
    max-width: 240px; /* Gleiche Breite wie bei der Schulleitung */
    flex: 0 1 240px;  /* Verhindert das automatische Ausdehnen (grow) */
}

/* Auf mobilen Geräten (Handy) sollen sie trotzdem wieder die volle Breite nutzen */
@media (max-width: 600px) {
    .gallery-small .gallery-item {
        max-width: 100%;
        flex: 1 1 100%;
    }
}