
/*
 * Handball4all Team Widgets
 * Monochromes Design: Schwarz / Weiß / Grau
 * Das CSS wirkt ausschließlich auf die Widgets.
 */

.tsv-h4a-widget {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    font-family: inherit;
    color: #151515 !important;
}

/* Schwarzer Bereich des Widgets */
.tsv-h4a-games,
.tsv-h4a-table-wrap {
    background: #111114;
    padding: 12px;
    border-radius: 12px;
    box-sizing: border-box;
}

/* -------------------------
   SPIELE
   ------------------------- */

.tsv-h4a-games {
    display: grid;
    gap: 16px;
}

.tsv-h4a-game-card {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #d7d7d7;
    border-radius: 11px;
    background: #fff !important;
    color: #151515 !important;
    overflow: hidden;
    box-shadow: none;
}

.tsv-h4a-game-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 14px 18px;
    border-bottom: 1px solid #dedede;
    background: #fff !important;
}

.tsv-h4a-game-label {
    color: #151515 !important;
    font-size: 15px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .025em;
}

.tsv-h4a-meta {
    display: flex;
    align-items: center;
    gap: 14px;
    color: #555 !important;
    font-size: 14px;
    white-space: nowrap;
}

.tsv-h4a-match {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center;
    gap: 16px;
    padding: 27px 20px;
    background: #fff !important;
}

.tsv-h4a-team {
    min-width: 0;
    color: #151515 !important;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.25;
    text-align: center;
}

.tsv-h4a-team:first-child {
    text-align: right;
}

.tsv-h4a-team:last-child {
    text-align: left;
}

.tsv-h4a-score {
    min-width: 70px;
    color: #151515 !important;
    text-align: center;
    font-size: 27px;
    line-height: 1;
}

.tsv-h4a-score strong {
    color: #151515 !important;
    font-weight: 900;
}

.tsv-h4a-location {
    border-top: 1px solid #dedede;
    padding: 11px 18px 13px;
    background: #fff !important;
    color: #555 !important;
    font-size: 14px;
}

.tsv-h4a-pin {
    color: #333 !important;
    margin-right: 7px;
    font-size: 9px;
}

.tsv-h4a-empty,
.tsv-h4a-error {
    width: 100%;
    box-sizing: border-box;
    padding: 18px 20px;
    border: 1px solid #d7d7d7;
    border-radius: 11px;
    background: #fff !important;
    color: #333 !important;
}

.tsv-h4a-error {
    border-color: #777;
}

/* -------------------------
   TABELLE
   ------------------------- */

.tsv-h4a-table-wrap {
    border: 1px solid #333338;
    overflow: hidden;
}

.tsv-h4a-table-scroll {
    width: 100%;
    overflow-x: hidden;
}

.tsv-h4a-table {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100%;
    table-layout: fixed;
    border-collapse: collapse;
    background: #fff !important;
    color: #151515 !important;
    font-size: 14px;
}

/* Spalten: Platz | Mannschaft | Spiele | Punkte | Tore */
.tsv-h4a-table th:nth-child(1),
.tsv-h4a-table td:nth-child(1) {
    width: 9%;
}

.tsv-h4a-table th:nth-child(2),
.tsv-h4a-table td:nth-child(2) {
    width: 56%;
}

.tsv-h4a-table th:nth-child(3),
.tsv-h4a-table td:nth-child(3) {
    width: 11%;
}

.tsv-h4a-table th:nth-child(4),
.tsv-h4a-table td:nth-child(4) {
    width: 13%;
}

.tsv-h4a-table th:nth-child(5),
.tsv-h4a-table td:nth-child(5) {
    width: 11%;
}

.tsv-h4a-table th {
    background: #202024 !important;
    color: #fff !important;
    padding: 11px 8px;
    text-align: center !important;
    font-weight: 800;
    white-space: nowrap;
    border: 0;
}

.tsv-h4a-table th:nth-child(2),
.tsv-h4a-table td:nth-child(2) {
    text-align: left !important;
}

.tsv-h4a-table td {
    padding: 10px 8px;
    border-bottom: 1px solid #dedede;
    border-right: 1px solid #d8d8d8;
    background: #fff !important;
    color: #151515 !important;
    text-align: center !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tsv-h4a-table td:last-child {
    border-right: 0;
}

.tsv-h4a-table tbody tr:last-child td {
    border-bottom: 0;
}

/* Eigene Mannschaft: neutral grau */
.tsv-h4a-table tbody tr.tsv-h4a-highlight td {
    background: #eeeeee !important;
    color: #151515 !important;
    font-weight: 800;
}

/* Kein blauer Link-/Theme-Farbwert */
.tsv-h4a-widget a,
.tsv-h4a-widget a:visited,
.tsv-h4a-widget a:hover {
    color: inherit !important;
    text-decoration: none;
}

/* -------------------------
   MOBILE
   ------------------------- */

@media (max-width: 700px) {

    .tsv-h4a-games,
    .tsv-h4a-table-wrap {
        padding: 9px;
        border-radius: 11px;
    }

    .tsv-h4a-game-top {
        align-items: flex-start;
        flex-direction: column;
        gap: 6px;
    }

    .tsv-h4a-meta {
        flex-wrap: wrap;
        white-space: normal;
        gap: 6px 12px;
    }

    .tsv-h4a-match {
        grid-template-columns: 1fr;
        gap: 8px;
        padding: 20px 15px;
    }

    .tsv-h4a-team:first-child,
    .tsv-h4a-team:last-child {
        text-align: center;
    }

    .tsv-h4a-score {
        min-width: 0;
        order: 2;
    }

    .tsv-h4a-team:first-child {
        order: 1;
    }

    .tsv-h4a-team:last-child {
        order: 3;
    }

    .tsv-h4a-table {
        font-size: 13px;
    }

    .tsv-h4a-table th,
    .tsv-h4a-table td {
        padding: 9px 5px;
    }

    .tsv-h4a-table th:nth-child(1),
    .tsv-h4a-table td:nth-child(1) {
        width: 11%;
    }

    .tsv-h4a-table th:nth-child(2),
    .tsv-h4a-table td:nth-child(2) {
        width: 48%;
    }

    .tsv-h4a-table th:nth-child(3),
    .tsv-h4a-table td:nth-child(3) {
        width: 12%;
    }

    .tsv-h4a-table th:nth-child(4),
    .tsv-h4a-table td:nth-child(4) {
        width: 14%;
    }

    .tsv-h4a-table th:nth-child(5),
    .tsv-h4a-table td:nth-child(5) {
        width: 15%;
    }
}

/* -------------------------
   DARK MODE / TRANSPARENT
   ------------------------- */

.tsv-h4a-widget {
    background: transparent !important;
    color: #f5f5f5 !important;
}

.tsv-h4a-games,
.tsv-h4a-table-wrap {
    background: transparent !important;
    padding: 0;
    border-radius: 0;
}

.tsv-h4a-game-card {
    border-color: #3a3a3f;
    background: #151518 !important;
    color: #f5f5f5 !important;
}

.tsv-h4a-game-top,
.tsv-h4a-match,
.tsv-h4a-location {
    background: #151518 !important;
}

.tsv-h4a-game-top {
    border-bottom-color: #343439;
}

.tsv-h4a-game-label,
.tsv-h4a-team,
.tsv-h4a-score,
.tsv-h4a-score strong {
    color: #f5f5f5 !important;
}

.tsv-h4a-meta,
.tsv-h4a-location {
    color: #a9a9ae !important;
}

.tsv-h4a-location {
    border-top-color: #343439;
}

.tsv-h4a-pin {
    color: #bdbdc2 !important;
}

.tsv-h4a-empty,
.tsv-h4a-error {
    border-color: #3a3a3f;
    background: #151518 !important;
    color: #e7e7e7 !important;
}

.tsv-h4a-table-wrap {
    border-color: #3a3a3f;
    overflow: hidden;
}

.tsv-h4a-table {
    background: #151518 !important;
    color: #f5f5f5 !important;
}

.tsv-h4a-table th {
    background: #25252a !important;
    color: #fff !important;
}

.tsv-h4a-table td {
    border-bottom-color: #343439;
    border-right-color: #343439;
    background: #151518 !important;
    color: #e8e8e8 !important;
}

.tsv-h4a-table tbody tr.tsv-h4a-highlight td {
    background: #303035 !important;
    color: #fff !important;
}

@media (max-width: 700px) {
    .tsv-h4a-games,
    .tsv-h4a-table-wrap {
        padding: 0;
    }
}
