/*
 * ============================================================
 *  ISHD Team Widget – Match / Nächstes Spiel Stylesheet
 *  Shortcode: [ishd_naechstes_spiel]
 *
 *  Datei ablegen unter:
 *  /wp-content/plugins/ishd-team-widget/match.css
 *
 *  Sektionen:
 *   1.  Karten-Wrapper (dark / light Theme)
 *   2.  Kein Spiel – Fallback
 *   3.  Hintergrund-Glows
 *   4.  "Nächstes Spiel" Label + Pulsierender Punkt
 *   5.  Matchup-Zeile (Flex-Layout)
 *   6.  Team-Blöcke & Logos
 *   7.  VS-Block
 *   8.  Meta-Bereich (Datum / Liga / Halle)
 *   9.  Responsive (max-width: 480px)
 *
 *  Farb-Variablen auf einen Blick:
 *   Akzentfarbe (orange) : #ff6a00
 *   Glow links           : #ff6600
 *   Glow rechts          : #0044ff
 *   Dark-Hintergrund     : #0d0d0f
 *   Light-Hintergrund    : #f4f6fb
 * ============================================================
 */


/* ============================================================
 *  1. KARTEN-WRAPPER
 * ============================================================ */

.ishd-upcoming-card {
    position: relative;
    overflow: hidden;
    border-radius: 12px;                /* ← Eckenradius anpassen */
    padding: 24px 24px 24px;
    margin: 0px 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
    text-align: center;
}

/* ── Dunkles Theme (Standard) ── */
.ishd-upcoming-card.ishd-dark {
    background: #1E4591;
    background-image:url("/wp-content/uploads/2026/03/matchday_bg.jpg");               /* ← Dunkler Hintergrund anpassen */
    color: #ffffff;
    /*border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.6);*/

/* ── Helles Theme  (dark="false") ── */
.ishd-upcoming-card.ishd-light {
    background: #f4f6fb;               /* ← Heller Hintergrund anpassen */
    color: #111111;
    border: 1px solid #dde2f0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}


/* ============================================================
 *  2. KEIN SPIEL – FALLBACK
 *  Wird angezeigt wenn kein kommendes Spiel gefunden wird.
 * ============================================================ */

.ishd-no-game {
    padding: 28px;
    text-align: center;
    font-size: 14px;
    border-radius: 10px;
    background: #0d0d0f;
    color: #888888;
    border: 1px solid rgba(255, 255, 255, 0.08);
}


/* ============================================================
 *  3. HINTERGRUND-GLOWS
 *  Zwei farbige Kreise hinter der Karte (links = orange, rechts = blau).
 *  Intensität: opacity anpassen.
 *  Farbe:      background der jeweiligen Klasse anpassen.
 * ============================================================ */

.ishd-upcoming-glow {
    position: absolute;
    width: 280px;
    height: 280px;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
    filter: blur(70px);                /* ← Unschärfe / Weichheit */
    opacity: 0.18;                     /* ← Gesamt-Intensität */
}

/* Linker Glow – orange/rot */
.ishd-glow-left {
    top: -60px;
    left: -80px;
    background: radial-gradient(circle, #ff6600, transparent 70%);
}

/* Rechter Glow – blau */
.ishd-glow-right {
    top: -60px;
    right: -80px;
    background: radial-gradient(circle, #0044ff, transparent 70%);
}

/* Helles Theme: Glows weniger intensiv */
.ishd-upcoming-card.ishd-light .ishd-glow-left  { opacity: 0.10; }
.ishd-upcoming-card.ishd-light .ishd-glow-right { opacity: 0.10; }


/* ============================================================
 *  4. "NÄCHSTES SPIEL" LABEL + PULSIERENDER PUNKT
 * ============================================================ */

.ishd-upcoming-label {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 28px;
    padding: 4px 14px;
    border-radius: 20px;
}

.ishd-dark  .ishd-upcoming-label {
    background: rgba(255, 255, 255, 0.06);
    color: #aaaaaa;
}
.ishd-light .ishd-upcoming-label {
    background: rgba(0, 0, 0, 0.06);
    color: #666666;
}

/* Pulsierender Punkt vor dem Label-Text */
.ishd-upcoming-dot {
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #ff6a00;               /* ← Punkt-Farbe anpassen */
    animation: ishd-pulse 2s infinite;
    flex-shrink: 0;
}

@keyframes ishd-pulse {
    0%, 100% { opacity: 1;   transform: scale(1);   }
    50%       { opacity: 0.4; transform: scale(0.8); }
}


/* ============================================================
 *  5. MATCHUP-ZEILE (Flex-Layout: Heim | VS | Gast)
 * ============================================================ */

.ishd-upcoming-matchup {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 28px;
}


/* ============================================================
 *  6. TEAM-BLÖCKE & LOGOS
 * ============================================================ */

.ishd-upcoming-team {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

/* Logo-Link: kein Unterstrich, Pointer */
.ishd-upcoming-logo-link {
    display: block;
    text-decoration: none;
    cursor: pointer;
}

/* Hover: Logo vergrößern + Glow */
.ishd-upcoming-logo-link:hover .ishd-upcoming-logo {
    transform: scale(1.06);
    filter: drop-shadow(0 0 14px rgba(255, 255, 255, 0.25));
}

/* Logo-Bild */
.ishd-upcoming-logo {
    width: 100px;                      /* ← Logo-Breite anpassen */
    height: 100px;                     /* ← Logo-Höhe anpassen  */
    object-fit: contain;
    transition: transform 0.25s ease, filter 0.25s ease;
    display: block;
}

/* Eigenes Team: permanenter oranger Glow */
.ishd-own-team .ishd-upcoming-logo {
    filter: drop-shadow(0 0 10px rgba(255, 106, 0, 0.5));
}

/* Teamname-Text */
.ishd-upcoming-teamname {
    font-size: 14px;                   /* ← Teamname-Größe anpassen */
    font-weight: 700;
    letter-spacing: 0.02em;
    line-height: 1.2;
    word-break: break-word;
}
.ishd-dark  .ishd-upcoming-teamname { color: #ffffff; }
.ishd-light .ishd-upcoming-teamname { color: #111111; }

/* "Heimspiel" / "Auswärts" Badge am eigenen Team */
.ishd-upcoming-own-badge {
    display: inline-block;
    margin-top: 5px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 2px 8px;
    border-radius: 10px;
    background: #ff6a00;               /* ← Badge-Farbe anpassen */
    color: #ffffff;
}


/* ============================================================
 *  7. VS-BLOCK
 *  Großes "VS" in der Mitte, klickbar als Link zum Spiel.
 * ============================================================ */

.ishd-upcoming-vs {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

/* VS ist ein Link zum ISHD-Spieldetail */
.ishd-upcoming-vs-link {
    text-decoration: none;
    display: block;
    line-height: 1;
}

/* Hover: VS leuchtet orange auf */
.ishd-upcoming-vs-link:hover .ishd-upcoming-vs-text {
    text-shadow: 0 0 24px rgba(255, 106, 0, 0.7);
    color: #ff6a00;                    /* ← Hover-Farbe anpassen */
}

/* VS-Text */
.ishd-upcoming-vs-text {
    font-size: 42px;                   /* ← VS-Schriftgröße anpassen */
    font-weight: 900;
    letter-spacing: -0.02em;
    line-height: 1;
    transition: color 0.2s ease, text-shadow 0.2s ease;
}
.ishd-dark  .ishd-upcoming-vs-text { color: rgba(255, 255, 255, 0.15); }
.ishd-light .ishd-upcoming-vs-text { color: rgba(0, 0, 0, 0.12); }

/* Vertikale Trennlinie unterhalb des VS */
.ishd-upcoming-vs::after {
    content: '';
    display: block;
    width: 1px;
    height: 60px;                      /* ← Linienlänge anpassen */
    background: linear-gradient(
        to bottom,
        transparent,
        rgba(255, 255, 255, 0.10),
        transparent
    );
}
.ishd-light .ishd-upcoming-vs::after {
    background: linear-gradient(
        to bottom,
        transparent,
        rgba(0, 0, 0, 0.10),
        transparent
    );
}


/* ============================================================
 *  8. META-BEREICH (Datum · Liga · Halle – nebeneinander)
 * ============================================================ */

/* Alle drei Elemente in einer Zeile, zentriert, mit Trennpunkten */
.ishd-upcoming-meta {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: row;               /* ← nebeneinander */
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 0;                            /* Abstand über Trennpunkte geregelt */
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
}
.ishd-light .ishd-upcoming-meta {
    border-top-color: rgba(0, 0, 0, 0.08);
}

/* Trennpunkt "·" zwischen den Elementen (außer vor dem ersten) */
.ishd-upcoming-date + .ishd-upcoming-liga::before,
.ishd-upcoming-liga + .ishd-upcoming-venue::before,
.ishd-upcoming-date + .ishd-upcoming-venue::before {
    content: '·';
    padding: 0 8px;
    opacity: 0.35;
    font-weight: 400;
}

/* Gemeinsame Basis für alle Meta-Elemente */
.ishd-upcoming-date,
.ishd-upcoming-liga,
.ishd-upcoming-venue {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    white-space: nowrap;
}

/* Farben dark / light */
.ishd-dark  .ishd-upcoming-date,
.ishd-dark  .ishd-upcoming-liga,
.ishd-dark  .ishd-upcoming-venue { color: #aaaaaa; }
.ishd-light .ishd-upcoming-date,
.ishd-light .ishd-upcoming-liga,
.ishd-light .ishd-upcoming-venue { color: #666666; }

/* Datum: etwas prominenter */
.ishd-upcoming-date {
    font-weight: 600;
    font-size: 12px;                   /* ← Datumsgröße anpassen */
}
.ishd-dark  .ishd-upcoming-date { color: #dddddd; }
.ishd-light .ishd-upcoming-date { color: #333333; }

/* Liga-Link */
.ishd-upcoming-liga a {
    text-decoration: none;
    font-weight: 600;
    color: #ff6a00;                    /* ← Liga-Link-Farbe anpassen */
}
.ishd-upcoming-liga a:hover {
    text-decoration: underline;
}

/* Warnungskommentar (z.B. "neue Uhrzeit") – bleibt in eigener Zeile */
.ishd-upcoming-comment {
    flex-basis: 100%;
    text-align: center;
    font-size: 11px;
    color: #ff8c42;
    margin-top: 6px;
}


/* ============================================================
 *  9. RESPONSIVE  (Smartphones ≤ 480px)
 *  Logos und VS werden verkleinert, Padding reduziert.
 *  Breakpoint: max-width anpassen
 * ============================================================ */

@media (max-width: 480px) {

    .ishd-upcoming-card {
        padding: 22px 14px 18px;
    }

    .ishd-upcoming-matchup {
        gap: 8px;
    }

    .ishd-upcoming-logo {
        width: 72px;                   /* ← Mobile Logo-Breite */
        height: 72px;                  /* ← Mobile Logo-Höhe  */
    }

    .ishd-upcoming-vs-text {
        font-size: 30px;               /* ← Mobile VS-Größe */
    }

    .ishd-upcoming-teamname {
        font-size: 12px;
    }

    /* Meta: auf sehr kleinen Screens umbrechen erlauben */
    .ishd-upcoming-meta {
        gap: 4px 0;
    }

    .ishd-upcoming-date,
    .ishd-upcoming-liga,
    .ishd-upcoming-venue {
        font-size: 11px;
        white-space: normal;
    }
}
