/* ===== Container & Grid ===== */
.projekte-container {
    max-width: 1400px;
    margin: 0 auto;
}

.projekte-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
    gap: 28px;
    justify-items: center;
}

/* ===== Projekte Item ===== */
.projekte-item {
    position: relative;
    overflow: hidden;
}

.projekte-image img {
    width: 100%;
    display: block;
    border-radius: 0;
}

/* ===== Overlay ===== */
.projekte-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(211,211,211,0.8);
    color: #000;
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    padding: 15px;
    box-sizing: border-box;
}

.projekte-item:hover .projekte-overlay {
    opacity: 1;
}

/* Overlay Inhalte */
.projekte-overlay a.projekte-overlay-title {
    font-size: 20px;
    font-weight: bold;
    color: #000;
    margin-bottom: 18px;
    text-decoration: none;
}

.projekte-overlay .projekte-overlay-kategorie-datum {
    font-size: 14px;
    margin-bottom: 8px;
}

.projekte-overlay .projekte-overlay-kategorie-datum span {
    margin-right: 5px;
}

.projekte-overlay .projekte-overlay-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.projekte-overlay .hashtag {
    background: #000;
    color: #fff;
    padding: 2px 6px;
    border-radius: 0;
    font-size: 12px;
}

/* ===== Filter Menu ===== */
.projekte-filter-menu {
    display: flex;
    justify-content: flex-end; /* Desktop rechts */
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.projekte-filter-menu button {
    padding: 10px 15px;
    background: #fff;
    border: none;
    box-shadow: none;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s ease;
    color: #000;
    border-radius: 0;
}

.projekte-filter-menu button:hover,
.projekte-filter-menu button.active {
    background: #d3d3d3;
}

/* ===== Sticky Mobile Filter ===== */
@media (max-width: 767px) {
    .projekte-filter-menu {
        justify-content: center;
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .projekte-filter-menu.sticky {
        position: fixed;
        top: 0; left: 0; right: 0;
        background: #fff;
        padding: 15px 0;
        z-index: 999;
    }
    .projekte-filter-menu button {
        font-size: 16px;
        padding: 6px 10px;
        flex-shrink: 0;
    }
    .projekte-grid {
        grid-template-columns: 1fr;
        gap: 18px;
        max-width: 100%;
    }
}

/* ===== Projekt-Single Card ===== */
.projekte-single-wrapper {
    max-width: 900px;
    margin: 50px auto;
    padding: 20px;
}

.projekte-single-card,
.projekte-single-container {
    background: #fff;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    padding: 25px;
    border-radius: 0;
    box-sizing: border-box;
}

.projekte-single-container {
    max-width: 1000px;
    margin: 50px auto;
}

/* Titel & Meta */
.projekte-single-title {
    font-size: 32px;
    font-weight: bold;
    margin-bottom: 15px;
}

.projekte-single-meta {
    font-size: 14px;
    color: #A3A3A3;
    margin-bottom: 5px;
}

.projekte-single-hashtags .hashtag {
    display: inline-block;
    background: #000;
    color: #fff;
    padding: 3px 8px;
    margin-bottom: 10px;
    border-radius: 0;
    font-size: 12px;
}

/* Bilder Diashow */
.projekte-single-bilder {
    position: relative;
    margin-bottom: 20px;
    max-width: 900px;
}

.projekte-single-bilder img {
    width: 100%;
    height: auto;
    display: block;
}

.slide-prev, .slide-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.5);
    color: #fff;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    font-size: 18px;
    z-index: 10;
}

.slide-prev { left: 10px; }
.slide-next { right: 10px; }

/* Beschreibung & Info */
.projekte-single-description {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 15px;
}

.projekte-single-info div {
    font-size: 14px;
    margin-bottom: 5px;
}

/* Navigation vorher/nächster */
.projekte-single-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 30px;
}

.projekte-single-navigation a {
    text-decoration: none;
    font-size: 30px;
    font-weight: bold;
    color: #000;
}

.projekte-single-navigation a:hover {
    color: #d3d3d3;
}

/* ===== Responsive ===== */
@media(max-width:1024px) {
    .projekte-single-title { font-size: 28px; }
}

@media(max-width:767px){
    .projekte-single-title { font-size: 22px; }
    .projekte-single-bilder img { max-width: 100%; height: auto; }
}

/* ===== Projekt-Single Container Mobile wie Aktuelles ===== */
@media (max-width: 767px) {
    .projekte-single-wrapper {
        width: 100%;
        padding: 0;
        margin: 10px 0px 0px 0px;
    }

    .projekte-single-container {
        max-width: calc(100% - 10px); /* 5px links + 5px rechts */
        margin: 5px 5px 5px 5px;       /* 5px oben, rechts, unten, links */
        padding: 15px;                 /* optionales Padding */
        box-sizing: border-box;
    }
}
