

a { 
    padding: 0 0.01rem; /* "Link-Ttel in der Liste: Ausrichtung links" */
    margin-top: 1rem;
}


/* Globale Stile für Event-Liste */
.event-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(48%, 1fr));
    grid-gap: 20px;
    list-style-type: none;
    padding: 0;
}

.event-list-item {
    margin-bottom: 20px;
    padding: 5px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s;
}

.event-list-item:hover {
    transform: scale(1.01);
}

/* Titel (Links) und Tags bleiben unverändert oberhalb */
.event-title {
    font-size: 0.9em;
    margin-bottom: 0.5em;
    text-align: left;
    line-height: 1.2;
}

.event-title a {
    font-size: 1em;
    color: black;
    text-decoration: none;
    display: block;
}

.event-title a:hover {
    background-color: #e0e0e0;
}

.event-tags {
    font-size: 0.8em;
    color: #666;
    margin-bottom: -3rem;
    text-align: left;
}

/* Bild bleibt unverändert, Text fließt daneben */
.event-list-item img {
    width: 30%;
    margin-top: 40px; /* Abstand vom oberen Rand */
    margin-left: 0.1px;
    margin-right: 8px; /* Abstand zwischen Bild und Text */
    border-style: solid;
    border-width: 3px;
    border-color: white;
    height: auto; /* Auto für die Höhe, um das Seitenverhältnis zu wahren */
    float: left; /* Bild links vom Text positionieren */
}

/* Text wird auf gleiche Höhe wie Bildrand ausgerichtet */
.event-text {
    text-align: left;
    margin-top: 0; /* Text auf gleiche Höhe wie Bild bringen */
}

.event-text p {
    margin: 0;
    padding: 0;
    overflow: hidden; /* Verhindert, dass der Text unter das Bild rutscht */
}

/* Suchfeld und Sortierung */
.search-container {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
}

.search-container input[type="text"] {
    width: 40%;
    min-width: 10em;
    max-width: 20em;
    margin-right: 1em;
    box-sizing: border-box;
}

#searchInputTags {
    width: 40%;
    min-width: 10em;
    max-width: 20em;
    box-sizing: border-box;
}

.sort-container {
    margin-left: auto;
}

.search-filter-container {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 1em;
}

.filter-container,
.search-container,
.search-tags-container,
.sort-container {
    margin-right: 2em;
    margin-top: 1em;
}

.filter-container {
    display: inline-block;
    vertical-align: top;
    height: 1.4em;
    padding: 0 0.1em;
    margin-left: 5px;
}

.filter-container select {
    height: 100%;
}

/* Anpassung der Suchfeldbreite */
#searchInput,
#searchTagsInput {
    width: 12em;
}

footer {
    font-size: 0.8rem;
    margin: 1rem;
}

/* Optimierung für Tablets und kleinere Bildschirme */
@media (max-width: 768px) {
    body {
        background-color: tan;
        color: white;
        padding: 0.5rem;
    }

    .search-filter-container {
        flex-direction: column;
        align-items: flex-start;
    }

    .filter-container,
    .search-container,
    .search-tags-container {
        margin-right: 0;
        margin-left: 10px;
        margin-bottom: 0.5em;
    }

    .sort-container {
        text-align: center;
        margin-left: 10px;
        margin-bottom: 1em;
    }

    .event-list {
        grid-template-columns: 1fr;
    }

    .event-list-item img {
        width: 100%;
        margin-bottom: 1rem;
    }

    .event-text {
        width: 100%;
        margin-top: 0;
    }
}
