/* ==========================================================================
   FONTS
   ========================================================================== */
@font-face { font-family: 'Nexa'; src: url('fonts/Nexa-Light.otf') format('opentype'); font-weight: 300; font-style: normal; }
@font-face { font-family: 'Nexa'; src: url('fonts/Nexa-Bold.otf') format('opentype'); font-weight: 700; font-style: normal; }
@font-face { font-family: 'LinLibertine'; src: url('fonts/LinLibertine-serif-regular.ttf') format('truetype'); font-weight: 400; font-style: normal; }
@font-face { font-family: 'LinLibertine'; src: url('fonts/LinLibertine-serif-semibold.ttf') format('truetype'); font-weight: 600; font-style: normal; }
@font-face { font-family: 'LinLibertine'; src: url('fonts/LinLibertine-serif-bold.ttf') format('truetype'); font-weight: 700; font-style: normal; }

/* ==========================================================================
   BASE & VARIABLEN
   ========================================================================== */
:root {
    --color-1: #000000; /* Tiefschwarz (Hintergrund Navigation/Footer) */
    --color-2: #c8a153; /* Goldgelb (Primärer Akzent, Headlines, Hover-Linien) */
    --color-3: #9b1b22; /* Weinrot (Sekundärer Akzent) */
    --color-4: #e0e0e0; /* Helles Grau für den Sponsoren-Hintergrund */
    --text-light: #ffffff;
    --text-dark: #222222;
    
    --font-text: 'BasicFont', sans-serif;
    --font-heading: 'HeadlineFont', serif;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    font-family: var(--font-text);
    font-size: 21px;
    line-height: 1.4;
    color: var(--text-dark);
    background-color: #f4f4f4;
}

.main-wrapper {
    width: 80%; /* 80% der Fensterbreite */
    max-width: 1440px;
    margin: 0 auto;
    /* padding: 0 20px; wurde entfernt */
    box-sizing: border-box;
}

h3 {
    line-height: 1.1;
}

h4 {
    line-height: 1.1;
}

#lightbox-caption strong {
    font-family: var(--font-text) !important;
    font-weight: 700 !important; /* Erzwingt die Nexa-Bold */
    font-style: normal;
}

/* ==========================================================================
   HEADER (Originaler Desktop-Fluss)
   ========================================================================== */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 120px;
    background-color: rgba(0, 0, 0, 0); 
    z-index: 1000;
    transition: background-color 0.4s ease, height 0.4s ease;
    will-change: background-color, height;
}

.main-header.scrolled {
    background-color: var(--color-1);
    height: 80px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.header-flex-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    
    width: 80%;
    max-width: 1440px;
    margin: 0 auto;
}

.main-navigation ul {
    list-style: none;
    margin: 0;
    padding: 0;
    line-height: 120px; 
    text-align: left;
    transition: line-height 0.4s ease;
    will-change: line-height;
    display: block; 
}

.main-header.scrolled .main-navigation ul {
    line-height: 80px; 
}

.main-navigation li {
    display: inline-block;
    margin-right: 25px;
}

.main-navigation a {
    text-decoration: none;
    color: var(--text-light);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 23px;
    position: relative;
    display: inline-block;
    transition: color 0.3s ease;
}

.main-navigation a::after {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    margin-top: 18px; 
    width: 100%;
    height: 2px; 
    background-color: var(--color-2); 
    transform: scaleX(0);
    transform-origin: center center;
    transition: transform 0.3s ease;
}

.main-navigation a:hover::after {
    transform: scaleX(1);
}

.main-navigation a:hover {
    color: var(--color-2);
}

.burger-menu-btn {
    display: none; 
}

.main-logo-link {
    display: flex;         
    align-items: center; 
    justify-content: center;
    height: 100%; 
    cursor: pointer;
}

.main-logo {
    display: block;
    height: 60px;
    width: auto;
    transition: height 0.4s ease;
    will-change: height;
}

.main-header.scrolled .main-logo {
    height: 40px; 
}

/* ==========================================================================
   RESPONSIVE NAVIGATION & BURGER MENU (Aktiv ab < 1600px)
   ========================================================================== */
@media screen and (max-width: 1599px) {
    
    .main-header {
        height: 80px !important; 
        background-color: var(--color-1) !important; 
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    }

    .header-flex-container {
        display: flex !important;
        justify-content: space-between;
        align-items: center;
    }

    .main-logo-link {
        height: 60px;
        display: flex;
        align-items: center;
        position: relative;
        order: 2; /* Zwingt das Logo nach ganz rechts */
    }

    .main-logo {
        position: relative !important;
        top: 0 !important; 
        right: 0 !important;
        height: 30px !important; 
    }

    .burger-menu-btn {
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 6px; 
        height: 60px; 
        width: 40px;
        background: transparent;
        border: none;
        cursor: pointer;
        padding: 0;
        z-index: 1020;
        order: 1;
    }

    .burger-line {
        display: block;
        width: 32px;
        height: 3px;
        background-color: var(--text-light); 
        border-radius: 2px;
        transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.3s ease;
        transform-origin: center center;
    }

    .burger-menu-btn.menu-open .burger-line:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }

    .burger-menu-btn.menu-open .burger-line:nth-child(2) {
        opacity: 0;
        transform: scaleX(0);
    }

    .burger-menu-btn.menu-open .burger-line:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }

    .main-navigation {
        position: fixed;
        top: 80px; 
        left: 0;
        width: 100%;
        height: calc(100vh - 80px); 
        background-color: var(--color-1); 
        z-index: 1010;
        transform: translateX(-100%);
        transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
        overflow-y: auto; 
    }

    .main-navigation.menu-active {
        transform: translateX(0);
    }

    .main-navigation ul {
        display: flex;
        flex-direction: column;
        width: 100%; /* NEU: Nimmt die volle Bildschirmbreite ein */
        max-width: none;
        margin: 0;    
        line-height: 28px !important; 
        padding: 0; 
        box-sizing: border-box;
    }

    .main-navigation li {
        display: block;
        width: 100%; /* Zeile geht über die gesamte Breite */
        margin-right: 0;
        margin-bottom: 0; /* Abstände auf 0, damit die Balken nahtlos aneinandergrenzen */
        padding-bottom: 0; 
        border-bottom: 1px solid rgba(255, 255, 255, 0.1); 
        transition: background-color 0.3s ease; /* Weicher Übergang für den gesamten Balken */
    }
    
    .main-navigation li:last-child {
        border-bottom: none;
    }

    /* Hover-Effekt liegt jetzt auf der gesamten Zeile (li) */
    .main-navigation li:hover,
    .main-navigation li:active {
        background-color: var(--color-2); /* Goldener Hintergrund über volle Breite */
    }

    .main-navigation a {
        font-size: 20px; 
        width: 80%; /* NEU: Hält den Text exakt in der 80%-Spur des Contents */
        max-width: 1440px;
        margin: 0 auto; /* Zentriert den 80%-Bereich im 100%-Balken */
        display: block;
        padding: 16px 0; /* Abstand oben und unten, damit der Balken hoch genug ist */
        transition: color 0.3s ease;
    }

    .main-navigation a::after {
        display: none !important;
    }
    
    /* Ändert die Schriftfarbe auf Schwarz, wenn die Zeile gehovert wird */
    .main-navigation li:hover a,
    .main-navigation li:active a {
        color: var(--color-1); 
    }
}

@media screen and (max-width: 767px) {
    .main-navigation a {
        width: 90%;
    }
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.section-hero {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    color: var(--text-light);
    overflow: hidden; 
}

.parallax-bg {
    position: absolute;
    inset: -5%; 
    background-image: url('graphics/meinmaturaball-ballwebseite-hak-has-htl-bulme-background.webp');
    background-size: cover;
    background-position: center;
    z-index: 0;
    will-change: transform, filter; 
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to right, rgba(0,0,0,0.4) 0%, rgba(0,0,0,0.1) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    box-sizing: border-box;
    margin-top: 50px;
}

.section-hero h1 {
    font-size: 26px;
    font-weight: 300;
    margin: 0 0 0 0;
    color: var(--color-2);
    text-transform: uppercase;
}

.section-hero h2 {
    font-family: var(--font-heading);
    font-size: 112px;
    line-height: 1.1;
    font-weight: 700;
    margin: 10px 0 10px 0;
    color: var(--color-2);
}

.hero-subheadline {
    font-size: 52px;
    line-height: 1.1;
    font-weight: 300;
    margin: 0;
    max-width: 1100px; 
    color: var(--color-2);
}

.section-hero h3 {
    font-size: 52px;
    font-weight: 700;
    margin: 40px 0 0 0;
    color: var(--text-light);
}

.section-hero h1, 
.section-hero h2, 
.section-hero h3, 
.hero-subheadline {
    text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.5);
}

/* ==========================================================================
   HERO SCROLL INDICATOR
   ========================================================================== */
.hero-scroll-indicator {
    position: absolute;
    bottom: 30px;        
    left: 50%;
    transform: translateX(-50%); 
    width: 40px;        
    height: auto;
    z-index: 3;
    transition: opacity 0.3s ease;
}

.hero-scroll-indicator:hover {
    opacity: 0.8;
}

.hero-scroll-indicator .scroll-arrow {
    transform-origin: center;
    will-change: transform;
    animation: bounceArrow 1.2s cubic-bezier(0.45, 0, 0.55, 1) infinite;
}

@keyframes bounceArrow {
    0%, 100% {
        transform: translateY(-3px);
    }
    50% {
        transform: translateY(12px); 
    }
}

@media screen and (max-width: 767px) {
    .hero-scroll-indicator {
        bottom: 30px;
        width: 32px; 
    }
}

/* ==========================================================================
   GLOBAL SECTION CONTENT STYLES (Übergreifend für alle Module)
   ========================================================================== */
.section-content {
    padding: 120px 0;
    background-color: #ffffff;
}

.section-content h3 {
    font-family: var(--font-heading);
    font-size: 48px;
    color: var(--color-2);
    margin-top: 0;
    margin-bottom: 20px; /* Globaler Standard-Abstand */
}

.section-content h4 {
    font-family: var(--font-heading);
    font-size: 32px;
    color: var(--color-2);
    margin-top: 0;
    margin-bottom: 10px; /* Globaler Standard-Abstand */
    letter-spacing: 0.5px;
}

.section-content p {
    margin: 0 0 30px 0;
}

/* ==========================================================================
   MODUL: PROGRAMM & ABLAUFPLAN
   ========================================================================== */

/* Das zweispaltige Layout */
.module-programm-flex-container {
    display: flex;
    justify-content: space-between;
    gap: 80px; 
    flex-wrap: wrap; 
}

/* Linke Spalte (Texte) */
.module-programm-info {
    flex: 1;
    min-width: 320px;
}

/* Überschreibt nur den spezifischen Abstand nach unten */
.module-programm-info h3 {
    margin-bottom: 25px;
}

.module-programm-info p {
    margin-bottom: 40px;
}

/* Sub-Headlines in der linken Spalte */
.module-programm-info-block h4 {
    margin-bottom: 6px;
}

.module-programm-info-block p {
    margin-bottom: 30px;
}

.module-programm-info-block small {
    font-size: 16px;
    opacity: 0.35;
    display: block;
    margin-top: 5px;
}

/* Rechte Spalte (Ablaufplan / Timeline) */
.module-programm-timeline {
    flex: 1;
    min-width: 320px;
    max-width: 500px; 
}

/* Überschreibt nur den spezifischen Abstand nach unten */
.module-programm-timeline h3 {
    margin-bottom: 35px;
}

/* Der Container für die Linie */
.module-programm-timeline-list {
    position: relative;
    padding-left: 28px; 
}

/* Die durchgehende vertikale Linie */
.module-programm-timeline-list::before {
    content: '';
    position: absolute;
    top: 10px;
    bottom: 10px;
    left: 0;
    width: 2px;
    background-color: var(--color-2); 
}

/* Die einzelnen Programmpunkte */
.module-programm-timeline-item {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 30px;
}

.module-programm-timeline-item:last-child {
    margin-bottom: 0;
}

/* Die runden, neutralen Marker */
.module-programm-timeline-item::before {
    content: '';
    position: absolute;
    left: -35px; 
    top: 6px;        
    width: 12px;
    height: 12px;
    background-color: #ffffff;
    border: 2px solid var(--color-2); 
    border-radius: 50%; 
    z-index: 1;
}

.module-programm-timeline-event {
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--color-1);
    padding-right: 20px;
}

.module-programm-timeline-time {
    white-space: nowrap; 
    font-weight: 300;
    color: var(--text-dark);
}

/* ==========================================================================
   MOBILE ANPASSUNGEN (PROGRAMM)
   ========================================================================== */
@media screen and (max-width: 991px) {
    .module-programm-flex-container {
        flex-direction: column;
        gap: 50px;
    }
    
    .module-programm-timeline {
        max-width: 100%; 
    }
}

@media screen and (max-width: 480px) {
    .module-programm-timeline-item {
        flex-direction: column;
        gap: 5px;
    }
    
    .module-programm-timeline-time {
        font-weight: 700;
        color: var(--color-2);
    }
}

/* ==========================================================================
   MODUL: MATURANTEN (Großes 2-spaltiges Grid)
   ========================================================================== */
.module-maturanten {
    background-color: var(--color-2); 
    color: var(--color-1);
}

.module-maturanten-header {
    text-align: center;
    margin-bottom: 60px;
}

.module-maturanten-header h3 {
    color: var(--color-1);
}

.module-maturanten-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr); 
    gap: 40px;
    max-width: none;
    margin: 0 auto; 
}

.module-maturanten-item {
    text-align: center;
}

.module-maturanten-item img {
    width: 100%;
    height: auto;
    object-fit: cover; /* Sorgt dafür, dass die Bilder das Seitenverhältnis halten */
    aspect-ratio: 16 / 9; /* Empfehlung: Einheitliches Format für alle Bilder */
    border-radius: 12px;
    display: block;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.module-maturanten-item img:hover {
    transform: scale(1.02);
    box-shadow: 0 5px 15px rgba(0,0,0,0.4);
}

.module-maturanten-item h4 {
    margin-top: 20px;
    font-family: var(--font-text);
    font-size: 24px; /* Etwas größer für bessere Lesbarkeit */
    color: var(--color-1);
    font-weight: 700;
}

/* RESPONSIVE: Bleibt 2-spaltig, wird auf Mobile 1-spaltig */
@media screen and (max-width: 767px) {
    .module-maturanten-grid {
        grid-template-columns: repeat(1, 1fr); 
        gap: 40px;
    }
}

/* ==========================================================================
   MODUL: LOCATION
   ========================================================================== */
.module-location-flex-container {
    display: flex;
    justify-content: space-between;
    align-items: center; /* Zentriert Bild und Text vertikal zueinander */
    gap: 60px;
    flex-wrap: wrap;
}

.module-location-image {
    flex: 1;
}

.module-location-image img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    display: block;
    cursor: zoom-in; /* Signalisiert die Lightbox-Funktion */
    transition: transform 0.3s ease;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.module-location-image img:hover {
    transform: scale(1.02);
    box-shadow: 0 5px 15px rgba(0,0,0,0.4);
}

.module-location-info {
    flex: 1;
    min-width: 300px;
}

.module-location-info h4 {
    margin-bottom: 10px;
}

.module-location-info p {
    line-height: 1.6;
    margin-bottom: 20px;
}

.module-location-link {
    display: inline-block;
    color: var(--color-2);
    font-weight: 700;
    text-decoration: none;
    font-family: var(--font-heading);
    font-size: 20px;
    transition: opacity 0.3s ease;
}

.module-location-link:hover {
    opacity: 0.7;
}

/* Responsive Anpassung */
@media screen and (max-width: 767px) {
    .module-location-flex-container {
        flex-direction: column;
        gap: 30px;
    }
}

/* ==========================================================================
   MODUL: SPONSOREN
   ========================================================================== */
.module-sponsoren {
    background-color: var(--color-4);
}

.module-sponsoren-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 4-spaltig */
    gap: 20px;
    margin-top: 40px;
}

.module-sponsoren-item {
    background-color: #ffffff; /* Weiße Box */
    padding: 15px;
    display: flex;
    justify-content: center;
    align-items: center; /* Vertikal & Horizontal zentriert */
    border-radius: 8px;
    transition: transform 0.3s ease, filter 0.3s ease;
    filter: grayscale(100%); /* Standard: Graustufen */
}

.module-sponsoren-item img {
    max-width: 100%;
    max-height: 160px;
    object-fit: contain;
}

/* Hover-Effekt: 5% größer und Farbe */
.module-sponsoren-item:hover {
    transform: scale(1.05); /* 5% größer */
    filter: grayscale(0%);  /* Farbe beim Hover */
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

/* RESPONSIVE ANPASSUNG */
@media screen and (max-width: 991px) {
    .module-sponsoren-grid {
        grid-template-columns: repeat(2, 1fr); /* 2-spaltig bei Tablets */
    }
}

@media screen and (max-width: 767px) {
    .module-sponsoren-item img {
	  max-height: 90px;
	}
}

@media screen and (max-width: 480px) {
    .module-sponsoren-grid {
        grid-template-columns: repeat(1, 1fr); /* 1-spaltig bei Mobile */
    }
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.section-footer {
    background-color: var(--color-1);
    color: var(--text-light);
    padding: 80px 0;
    font-size: 18px;
    line-height: 1.3;
    min-height: 240px;
}

.section-footer .footer-flex-container {
    display: flex;
    justify-content: space-between;
    align-items: flex-end; 
    flex-wrap: wrap; 
    gap: 40px;
}

.footer-column {
    flex: 1;
    min-width: 280px; 
}

.footer-left p {
    margin: 0;
}

.footer-left .committee-name {
    font-weight: 700;
    margin-bottom: 8px;
    font-family: var(--font-heading);
    font-size: 24px;
    color: var(--color-2);
}

.footer-mail {
    color: var(--text-light);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-mail:hover {
    color: var(--color-2);
}

.footer-right {
    text-align: right;
}

.agency-link {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 700;
    position: relative;
    transition: color 0.3s ease;
}

.agency-link:hover {
    color: var(--color-2);
}

@media screen and (max-width: 767px) {
	
	.section-footer {
    font-size: 16px;
	}

    .section-footer .footer-flex-container {
        flex-direction: column;
        align-items: flex-start; 
        gap: 30px;
    }
    
    .footer-right {
        text-align: left; 
        width: 100%;
        border-top: 1px solid rgba(255, 255, 255, 0.25);
        padding-top: 20px;
    }
}

/* ==========================================================================
   COOKIE BAR
   ========================================================================== */
#cookie_bar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    color: var(--text-light);
    padding: 20px 0;
    z-index: 2000;
    box-shadow: 0 -4px 12px rgba(0,0,0,0.5);
    border-top: 1px solid rgba(200, 161, 83, 0.2); /* Dezent goldene Trennlinie */
}

.cookie_inner {
    width: 80%;
    max-width: 1440px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 30px;
    box-sizing: border-box;
}

.cookie_inner p {
    color: rgba(255, 255, 255, 0.8);
    margin: 0;
    font-size: 16px;
    line-height: 1.4;
}

.cookie_inner a {
    color: var(--color-2);
    text-decoration: underline;
    transition: opacity 0.3s ease;
}

.cookie_inner a:hover {
    opacity: 0.8;
}

#cookie_bar_button {
    background-color: var(--text-light);
    color: var(--color-1);
    border: none;
    padding: 12px 24px;
    font-family: var(--font-text);
    font-weight: 700;
    font-size: 16px;
    cursor: pointer;
    border-radius: 6px;
    white-space: nowrap;
    transition: background-color 0.3s ease, color 0.3s ease;
}

#cookie_bar_button:hover {
    background-color: var(--color-2);
    color: var(--color-1);
}

/* ==========================================================================
   RESPONSIVE STYLES
   ========================================================================== */
@media screen and (max-width: 1599px) {
    body { font-size: 20px; }
    .section-content { padding: 100px 0; }
    .section-hero h1 { font-size: 24px; }
    .section-hero h2 { font-size: 96px; }
    .hero-subheadline { font-size: 46px; }
    .section-hero h3 { font-size: 46px; }
    .section-content h3 { font-size: 42px; }
    .section-content h4 { font-size: 28px; }
	.cookie_inner p { font-size: 15px; }
    #cookie_bar_button { font-size: 15px; padding: 10px 20px; }
}

@media screen and (max-width: 1024px) {
    body { font-size: 19px; }
    .section-content { padding: 90px 0; }
    .section-hero h1 { font-size: 20px; }
    .section-hero h2 { font-size: 72px; }
    .hero-subheadline { font-size: 36px; }
    .section-hero h3 { font-size: 36px; }
    .section-content h3 { font-size: 36px; }
    .section-content h4 { font-size: 25px; }
}

@media screen and (max-width: 767px) {
    .main-wrapper { width: 90%; }
    body { font-size: 18px; }
    .section-content { padding: 76px 0; }
    .section-hero h1 { font-size: 16px; }
    .section-hero h2 { font-size: 48px; }
    .hero-subheadline { font-size: 26px; }
	.hero-content { margin-top: 0px; }
    .section-hero h3 { font-size: 30px; margin: 20px 0 0 0;}
    .section-content h3 { font-size: 30px; }
    .section-content h4 { font-size: 22px; }
	.cookie_inner { width: 90%; flex-direction: column; text-align: center; gap: 15px; }
    .cookie_inner p { font-size: 14px; }
    #cookie_bar_button { width: 100%; font-size: 15px; padding: 12px; }
}