/*
 * ----------------------------------------------------
 * ASPEKTE EVENTS LISTE STYLES
 * ----------------------------------------------------
 */

/* CSS Variablen für einfache Farbanpassung */
:root {
    --gw-accent-primary: #c36;
    --gw-gradient-start: #aa3379; /* Ursprünglich Elementor Accent */
    --gw-gradient-end: #d20019;    /* Ursprünglich Elementor Global Color */
    --gw-button-text: #ffffff;
    --gw-fallback-bg: #eee;
}


/* WICHTIG: Höhere Spezifität, um Theme-Stile zu überschreiben */
.gw-events-container * {
      box-sizing: border-box; 
}

/* --- Globaler Container Padding --- */
.gw-events-container { 
    padding: 40px 0 80px 0; 
    list-style: none;
    margin: 0;
}

/* --- Event Item Trennlinie & Abstand --- */
.gw-event-item { 
    border-bottom: 2px solid #000; 
    padding: 30px 0; 
    margin-bottom: 0; 
}
.gw-event-item:first-child {
      padding-top: 0;
}
.gw-event-item:last-child {
    border-bottom: none;
}

/* --- Link Wrapper (Ausrichtung und Hover) --- */
.gw-item-link {
    display: flex;
    align-items: flex-start; 
    text-decoration: none !important; 
    color: #333 !important; 
    transition: none; 
}
.gw-item-link:hover {
    background-color: transparent; 
}

/* --- 1. Bild Spalte (Größe, Radius, Zoom-Effekt) --- */
.gw-image-col {
    flex: 0 0 300px; 
    max-width: 300px; 
    height: 200px; 
    overflow: hidden; 
    border-radius: 10px; 
    margin-right: 40px; 
    position: relative; 
}

/* Standard Bild-Stil */
.gw-image-col img {
    width: 100%;
    height: 100%;
    object-fit: cover; 
    display: block;
    transition: transform 0.4s ease-in-out; 
}

/* Zoom Effekt NUR beim Hover über das Bild */
.gw-image-col:hover img {
    transform: scale(1.05);
}

/* *** FALLBACK STYLING *** */
.gw-image-col.is-fallback {
    background-color: var(--gw-fallback-bg);
    /* Logo soll in der Mitte sein, daher Bild-Stil ändern */
    display: flex;
    justify-content: center;
    align-items: center;
}
.gw-image-col.is-fallback img {
    width: 50%; /* Logo kleiner anzeigen */
    height: auto;
    max-width: 150px;
    object-fit: contain;
    transform: none !important; /* Zoom entfernen */
}
.gw-image-col.is-fallback:hover img {
    transform: none; 
}
/* *** ENDE FALLBACK STYLING *** */


/* --- 2. Inhalts Spalte --- */
.gw-content-col {
    flex-grow: 1;
    padding-right: 40px; 
}
.gw-event-title { 
    margin: 0 0 5px 0; 
    font-size: 1.5em !important; 
    font-weight: 700 !important; 
    line-height: 1.3;
    color: #221a17 !important;
    transition: color 0.3s ease;
}
.gw-event-title:hover {
    background-image: linear-gradient(90deg, var(--e-global-color-accent) 0%, var(--e-global-color-58fb3b0) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    display: inline-block;
}


/* Ort (Icon Farbe, Text normal) */
.gw-event-location-main {
    margin: 0 0 10px 0; 
    font-size: 14px;
    color: #333; 
    font-weight: 500;
}
.gw-event-location-main i {
      color: var(--gw-accent-primary); 
      font-size: 1.3em; 
      margin-right: 5px;
      vertical-align: top; 
}

/* Beschreibung: Vollständig angezeigt */
.gw-event-description {
    margin: 0;
    font-size: 14px; 
    color: #777;
    line-height: 1.4;
    display: block; 
}

/* --- 3. Meta Spalte (Datum, Uhrzeit, Button) --- */
.gw-meta-col {
    flex: 0 0 180px; 
    max-width: 180px;
}

/* Icon und Text Styling */
.gw-event-meta {
    display: flex;
    margin: 5px 0; 
    color: #333;
    font-weight: 400;
    gap: 4px;
}
.gw-event-meta i {
    color: var(--gw-accent-primary); 
    margin-right: 10px; 
    font-size: 1.3em; 
}
.gw-event-meta .gw-meta-text {
    font-weight: 700; 
}

/* Button Style (Gilt für Event-Liste) */
.gw-meta-button {
    margin-top: 40px !important; 
    font-weight: 500;
    font-size: 0.9em;
}
.gw-meta-button .gw-button-text {
    padding: 8px 18px; 
    background-image: linear-gradient(90deg, var(--gw-gradient-start) 0%, var(--gw-gradient-end) 100%);
    color: var(--gw-button-text) !important; 
    border-radius: 60px; 
    transition: all 0.2s;
}
.gw-meta-button .gw-button-text:hover {
    opacity: 0.9; 
    transform: translateY(-1px);
}

/* Mobile-spezifische Ausblendungen auf Desktop */
.gw-location-mobile, .gw-button-mobile-wrapper { display: none !important; }
.gw-event-details { display: none !important; }


/* ----------------------------------------------------
 * NEUE REGELN FÜR DEN "ZUM AKTUELLEN PROGRAMM" BUTTON
 * ----------------------------------------------------
 */

/* 1. Positioniert den Wrapper-Container für "Zum aktuellen Programm" rechts oben */
.gw-archive-button-wrapper {
    display: flex;
    justify-content: flex-end; /* Schiebt den Button nach rechts */
    width: 100%;
    /* Abstand zur Event-Liste darunter */
    margin-bottom: 30px; 
    margin-top: -80px; 
    padding: 0; 
}

/* 2. Link-Wrapper für Transformationen */
.gw-archive-button-wrapper .gw-meta-button-link {
    display: block; 
    text-decoration: none; /* Link-Unterstreichung entfernen */
    color: inherit; 
    transition: transform 0.3s ease;
}

/* 3. **FEHLERBEHEBUNG**: Fügt die primären Button-Stile auf das span im Archiv-Wrapper hinzu,
      da es keine umgebende .gw-meta-button Klasse hat. */
.gw-archive-button-wrapper .gw-button-text {
    /* Basis-Stile vom .gw-meta-button .gw-button-text kopiert/erneut angewendet */
    padding: 8px 18px; 
    background-image: linear-gradient(90deg, var(--gw-gradient-start) 0%, var(--gw-gradient-end) 100%);
    color: var(--gw-button-text) !important; 
    border-radius: 60px; 
    transition: all 0.2s;
    font-weight: 500; /* Aus p.gw-meta-button */
    font-size: 0.9em; /* Aus p.gw-meta-button */
    white-space: nowrap; 
    display: inline-block; /* Wichtig, damit Padding/Form wirken */
}

/* 4. Hover-Effekt: Nachahmung des Hochgleitens des Event-Ansehen-Buttons */
.gw-archive-button-wrapper .gw-meta-button-link:hover {
    /* Führt die Verschiebung auf dem Link-Element aus, damit der gesamte Button gleitet */
    transform: translateY(-1px);
}
.gw-archive-button-wrapper .gw-meta-button-link:hover .gw-button-text {
    /* Passt nur die Opacity an, da die Verschiebung vom Elternelement übernommen wird */
    opacity: 0.9;
    transform: none; /* Verschiebung hier neutralisieren, da sie vom Elternelement kommt */
}


/* --- RESPONSIVE DESIGN (unter 800px) --- */
@media (max-width: 800px) {
    /* Archiv-Button soll auf Mobile ausgeblendet werden */
    .gw-archive-button-wrapper {
        margin-top: 40px;
		justify-content: flex-start;
    }
    
    .gw-meta-col {
         display: none; 
    }
    .gw-content-col {
         padding-right: 15px; 
    }
    .gw-event-details {
         display: block !important; 
    }
    
     .gw-image-col {
         flex: 0 0 100px; 
         max-width: 100px;
         height: 70px;
         margin-right: 15px;
         border-radius: 4px;
    }
    .gw-image-col:hover img {
         transform: none; 
    }
    .gw-button-mobile {
          display: inline-block;
          padding: 6px 14px; 
          background-image: linear-gradient(90deg, var(--gw-gradient-start) 0%, var(--gw-gradient-end) 100%);
          color: var(--gw-button-text) !important;
          border-radius: 60px;
          margin-top: 20px;
    }
    .gw-location-mobile, .gw-button-mobile-wrapper { display: block !important; }
    .gw-location-mobile i { vertical-align: top; }
    .gw-event-item { border-bottom: 0; }

}

/* --- RESPONSIVE DESIGN (unter 600px) --- */
@media (max-width: 600px) {
    .gw-event-item {
        padding: 20px 0;
    }
    .gw-item-link {
        flex-direction: column;
        align-items: flex-start;
    }
    .gw-image-col {
        flex: none;
        max-width: 100%;
        width: 100%;
        height: 250px; 
        margin-right: 0;
        margin-bottom: 10px;
    }
    .gw-content-col {
        width: 100%;
    }
    .gw-event-details {
          padding-top: 10px;
    }
}