/* =========================================
   HOME.CSS – Startseite
   Intro, Ankündigungen-Feed, Kalender
========================================= */

/* ================================
   INTRO
=============================== */
.home-intro {
    max-width: 900px;
    margin: 0 auto;
    text-align: left;
}

    .home-intro h1 {
        text-align: center;
        font-weight: 800;
        margin: 18px 0;
    }

    .home-intro p {
        line-height: 1.8;
        margin: 0 0 14px;
        color: #222;
    }

/* Intro mit Bild links / Text rechts */
.home-intro-layout {
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 40px;
    align-items: start;
    max-width: 1100px;
}

.home-intro-image img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 6px;
}

.home-intro-text h1 {
    text-align: left;
    margin-top: 0;
}

/* ================================
   LINKS / BUTTONS
=============================== */
.home-links {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    margin: 18px 0 10px;
}

.home-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 14px;
    border: 1px solid #ddd;
    border-radius: 8px;
    text-decoration: none;
    color: #111;
    font-weight: 700;
    background: #fff;
}

    .home-btn:hover {
        background: #f6f6f6;
    }

/* Discord CTA Button */
.home-cta {
    display: flex;
    justify-content: flex-start;
    margin-top: 18px;
}

.home-cta-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 18px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 900;
    color: #fff;
    background: linear-gradient(90deg,#5865F2,#1a73e8);
    box-shadow: 0 18px 45px rgba(26,115,232,.18);
}

    .home-cta-btn:hover {
        filter: brightness(1.05);
    }

/* ================================
   SECTIONS
=============================== */
.home-section {
    margin-top: 36px;
}

    .home-section h2 {
        text-align: center;
        font-weight: 800;
        margin-bottom: 18px;
    }

.home-muted {
    text-align: center;
    color: #666;
}

/* ================================
   ANKÜNDIGUNGEN – Social Feed / Posts
=============================== */
.post-feed {
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.post {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 14px;
    padding: 16px 18px;
    box-shadow: 0 10px 30px rgba(0,0,0,.04);
}

/* Post Meta – einheitlich für alle Post-Typen */
.post-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.post-date {
    font-size: 12px;
    color: #6b7280;
    background: #f3f4f6;
    padding: 4px 10px;
    border-radius: 999px;
}

.post-title {
    font-weight: 900;
    font-size: 18px;
    margin-bottom: 8px;
}

.post-text {
    color: #222;
    line-height: 1.75;
    white-space: pre-line;
}

/* Magische Posts (mit Glow-Effekt) */
.post-magic {
    position: relative;
    background: #fff;
    border-radius: 16px;
    padding: 16px 18px;
    border: 1px solid rgba(0,0,0,.06);
    box-shadow: 0 18px 55px rgba(0,0,0,.08);
    overflow: hidden;
}

    .post-magic::before {
        content: "";
        position: absolute;
        inset: -2px;
        background: linear-gradient(120deg,#2fb7b7,#1a73e8,#b04bff,#2fb7b7);
        opacity: .22;
        filter: blur(18px);
        z-index: 0;
    }

    .post-magic > * {
        position: relative;
        z-index: 1;
    }

.post-badge {
    font-size: 12px;
    font-weight: 900;
    color: #111;
    background: rgba(255,255,255,.9);
    padding: 4px 10px;
    border-radius: 999px;
    border: 1px solid rgba(0,0,0,.06);
}

.post-media {
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(0,0,0,.06);
    background: #f3f3f3;
    margin-bottom: 12px;
}

    .post-media img {
        width: 100%;
        height: 320px;
        object-fit: cover;
        display: block;
    }

/* ================================
   KALENDER (Card + Header + Glow)
=============================== */
.cal-head {
    max-width: 1100px;
    margin: 0 auto 12px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
}

    .cal-head h2 {
        margin: 0;
        font-weight: 900;
    }

/* Kalender-Öffnen-Button – einheitlich mit calendar-open */
.cal-open,
.calendar-open {
    text-decoration: none;
    font-weight: 800;
    font-size: 13px;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid #ddd;
    color: #111;
    background: #fff;
}

.cal-open:hover,
.calendar-open:hover {
    background: #f6f6f6;
}

.cal-wrap {
    max-width: 1100px;
    margin: 0 auto;
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid #e7e7e7;
    background: #fff;
    box-shadow: 0 18px 50px rgba(0,0,0,.08);
    position: relative;
}

    /* Glow / Akzent-Streifen */
    .cal-wrap::before {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 8px;
        background: linear-gradient(90deg, #2fb7b7, #1a73e8, #2fb7b7);
        opacity: .9;
        z-index: 1;
    }

/* Iframe sauber „unter“ dem Glow */
.cal-iframe {
    position: relative;
    z-index: 0;
    width: 100%;
    height: 680px;
    border: 0;
    display: block;
}

/* Magischer Kalender */
.calendar-magic {
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid rgba(0,0,0,.08);
    box-shadow: 0 22px 70px rgba(0,0,0,.10);
    position: relative;
}

    .calendar-magic::before {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 10px;
        background: linear-gradient(90deg,#2fb7b7,#1a73e8,#b04bff);
        z-index: 2;
    }

.calendar-head {
    position: relative;
    z-index: 3;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px 12px;
    background: rgba(255,255,255,.9);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid rgba(0,0,0,.06);
}

.calendar-title {
    font-weight: 900;
}

/* FALLBACK (für ältere Views mit calendar-wrap) */
.calendar-wrap {
    border: 1px solid #eee;
    border-radius: 14px;
    overflow: hidden;
    background: #fff;
}

/* ================================
   UPCOMING STREAMS – Karte wie Ankündigungen/Kalender
=============================== */
.home-streams-card {
    max-width: 720px;
    margin: 0 auto;
    position: relative;
    background: rgba(255, 255, 255, 0.92);
    border-radius: 18px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 18px 55px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.home-streams-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 6px;
    background: linear-gradient(90deg, #2fb7b7, #1a73e8, #2fb7b7);
    opacity: 0.95;
    z-index: 1;
}

.home-streams-title {
    margin: 0;
    padding: 20px 24px 16px;
    font-family: "Space Grotesk", sans-serif;
    font-weight: 800;
    font-size: 1.5rem;
    color: #0f2230;
    text-align: center;
}

.home-upcoming-list {
    padding: 0 20px 20px;
    margin: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.home-upcoming-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 14px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.home-upcoming-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.home-upcoming-date {
    font-size: 13px;
    font-weight: 700;
    color: #1a73e8;
    background: rgba(26, 115, 232, 0.1);
    padding: 6px 12px;
    border-radius: 999px;
    white-space: nowrap;
}

.home-upcoming-title {
    font-family: "Space Grotesk", sans-serif;
    font-size: 17px;
    font-weight: 700;
    color: #111827;
    text-align: right;
    flex: 1;
    margin-left: 12px;
}

.home-streams-empty {
    padding: 24px 20px;
    margin: 0;
    text-align: center;
    color: #6b7280;
    line-height: 1.6;
}

.home-upcoming-actions {
    display: flex;
    justify-content: center;
    padding: 16px 20px 24px;
}

.home-streams-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 800;
    font-size: 15px;
    color: #fff;
    background: linear-gradient(135deg, #2fb7b7, #1a73e8);
    box-shadow: 0 10px 28px rgba(26, 115, 232, 0.25);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.home-streams-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 36px rgba(26, 115, 232, 0.35);
}

/* ================================
   RESPONSIVE
=============================== */
@media (max-width: 1100px) {
    .cal-head,
    .cal-wrap {
        max-width: 900px;
    }
}

@media (max-width: 900px) {
    .home-intro-layout {
        grid-template-columns: 1fr;
    }

    .home-intro-text h1 {
        text-align: center;
    }

    .home-cta {
        justify-content: center;
    }
}

@media (max-width: 650px) {
    .home-intro {
        padding: 0 8px;
    }

    /* Intro-Bild auf Mobilgeräten größer: volle Breite, mind. Höhe */
    .home-intro-image {
        max-width: 100%;
        min-height: 360px;
    }

    .home-intro-image img {
        width: 100%;
        min-height: 360px;
        object-fit: cover;
        object-position: center top;
    }

    /* Ankündigungs-Bilder in Posts auf Mobilgeräten größer */
    .post-media img {
        min-height: 340px;
        height: auto;
        max-height: 480px;
    }

    .post {
        padding: 14px;
    }

    .cal-head {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .cal-iframe {
        height: 620px;
    }

    .calendar-head {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .home-streams-card {
        margin-left: 8px;
        margin-right: 8px;
    }

    .home-upcoming-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .home-upcoming-title {
        text-align: left;
        margin-left: 0;
    }
}
