/* ===============================
   GLOBAL
   =============================== */

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: #f5f5f5;
}

/* Abstand unter Navbar */
.page-wrapper {
    padding-top: 80px;
    width: 100%;
}

/* Standard-Seiten d�rfen Container nutzen */
.container {
    max-width: 1140px;
}

/* �berschriften */
h1 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

/* Runden */
.round-block {
    margin: 2rem 0;
}

.round-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    padding-left: 10px;
    border-left: 6px solid #1f4e79;
}
/* ===============================
   BREITER CONTAINER (SPIELPLAN + TABELLE)
   =============================== */

.container {
    max-width: 1400px; /* vorher ~1140px */
}
/* =========================
   LIGATABELLE
   ========================= */

.league-table-wrapper {
    background: #ffffff;
    border-radius: 4px;
    padding: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.league-header {
    margin-bottom: 12px;
}

.league-title {
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 2px;
}

.league-subtitle {
    font-size: 0.9rem;
    color: #666;
}

/* Tabelle */

.league-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

    .league-table thead tr {
        background: #4a4a4a;
        color: #ffffff;
    }

    .league-table th {
        padding: 6px 8px;
        font-weight: 600;
        text-align: center;
    }

    .league-table td {
        padding: 6px 8px;
        border-bottom: 1px solid #e0e0e0;
        text-align: center;
    }

    .league-table tbody tr:nth-child(even) {
        background: #f7f7f7;
    }

    .league-table tbody tr:hover {
        background: #eef3f9;
    }

/* Spalten */

.col-rank {
    width: 40px;
}

.col-team {
    text-align: left;
}

.col-small {
    width: 55px;
}

.col-goals {
    width: 80px;
}

/* Team-Zelle */

.team-cell {
    display: flex;
    align-items: center;
    gap: 8px;
}

.team-logo {
    height: 22px;
    width: auto;
}

/* Punkte & Diff */

.points {
    font-weight: 700;
}

.diff-plus {
    color: #0a7a0a;
    font-weight: 600;
}

.diff-minus {
    color: #c00000;
    font-weight: 600;
}

/* Responsive */

@media (max-width: 768px) {
    .league-table {
        font-size: 0.85rem;
    }

    .league-title {
        font-size: 1.3rem;
    }
}
.form-check-input {
    transform: scale(1.25);
}

.kader-row {
    padding: .3rem 0;
}

.modal-footer {
    z-index: 10;
}

/* ===============================
   MOBILE OPTIMIERUNGEN
   =============================== */

/* Buttons mindestens 44px für Touch */
@media (max-width: 768px) {

    /* Allgemeine Touch-Targets */
    .btn {
        min-height: 44px;
        min-width: 44px;
    }

    /* Startseite - Karten früher stapeln */
    .col-lg-4 {
        margin-bottom: 1rem;
    }

    /* MatchCard auf Mobile */
    .matchcard-mobile .row > [class*="col-3"],
    .matchcard-mobile .row > [class*="col-6"] {
        width: 100% !important;
        flex: 0 0 100% !important;
        max-width: 100% !important;
    }

    /* Kader-Modal 2 Spalten nebeneinander aber schmaler */
    .modal-dialog {
        margin: 0.5rem;
        max-width: calc(100% - 1rem);
    }

    .modal-body .col-6 {
        padding-left: 4px;
        padding-right: 4px;
    }

    .modal-body h5 {
        font-size: 1rem;
    }

    /* Kader Items kleiner */
    .kader-item,
    .aufstellung-item {
        padding: 0.4rem !important;
        font-size: 0.85rem;
    }

    .kader-item .btn,
    .aufstellung-item .btn {
        padding: 0.25rem 0.5rem;
        min-width: 36px;
        min-height: 36px;
    }

    /* Header-Felder in MatchCard */
    .matchcard-header .row > div {
        margin-bottom: 0.5rem;
    }

    /* Score kleiner */
    .matchcard-score input {
        width: 50px !important;
        font-size: 1.8rem !important;
        height: 50px !important;
    }

    /* Logos kleiner */
    .matchcard-logo {
        height: 50px !important;
    }

    /* Tabellen responsive */
    .table-responsive-mobile {
        display: block;
        width: 100%;
        overflow-x: auto;
    }

    /* Navbar Brand kürzer */
    .navbar-brand {
        font-size: 0.9rem;
        max-width: 200px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    /* Form Controls */
    .form-control,
    .form-select {
        font-size: 16px; /* verhindert Zoom auf iOS */
    }
}

/* Extra kleine Bildschirme */
@media (max-width: 480px) {

    /* Kader Modal - 1 Spalte statt 2 */
    .modal-body .col-6 {
        width: 100% !important;
        flex: 0 0 100% !important;
        max-width: 100% !important;
    }

    .modal-body .col-6:first-child {
        margin-bottom: 1rem;
        border-bottom: 1px solid #ddd;
        padding-bottom: 1rem;
    }

    /* Kader/Aufstellung Boxen kleiner */
    .modal-body .border.rounded {
        min-height: 200px !important;
        max-height: 250px !important;
    }

    /* Letzte Ergebnisse - 1 pro Zeile */
    .letzte-ergebnisse .col-md-6 {
        width: 100%;
    }
}

/* ===============================
   DASHBOARD
   =============================== */

/* --- Hero Header --- */
.dashboard-hero {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    color: #fff;
    padding: 2rem 1.5rem;
    border-radius: 16px;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.dashboard-hero-logo {
    height: 100px;
    filter: drop-shadow(0 2px 8px rgba(255, 255, 255, 0.2));
}

.dashboard-hero-title {
    font-size: 1.8rem;
    font-weight: 800;
    margin: 0;
    letter-spacing: -0.02em;
    color: #fff;
}

.dashboard-saison-badge {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.78rem;
    font-weight: 400;
    letter-spacing: 0.03em;
}

/* --- Stat Cards --- */
.dashboard-stat-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: #fff;
    border-radius: 12px;
    padding: 1.2rem 1rem;
    border-left: 4px solid transparent;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    height: 100%;
}

.dashboard-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

.dashboard-stat-icon {
    font-size: 1.8rem;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    flex-shrink: 0;
}

.dashboard-stat-content {
    min-width: 0;
}

.dashboard-stat-number {
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.1;
}

.dashboard-stat-label {
    font-size: 0.78rem;
    color: #6b7280;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* Stat card color variants */
.stat-blue {
    border-left-color: #1a73e8;
}

.stat-blue .dashboard-stat-icon {
    background: rgba(26, 115, 232, 0.1);
    color: #1a73e8;
}

.stat-blue .dashboard-stat-number {
    color: #1a73e8;
}

.stat-green {
    border-left-color: #0d8a3f;
}

.stat-green .dashboard-stat-icon {
    background: rgba(13, 138, 63, 0.1);
    color: #0d8a3f;
}

.stat-green .dashboard-stat-number {
    color: #0d8a3f;
}

.stat-orange {
    border-left-color: #e8710a;
}

.stat-orange .dashboard-stat-icon {
    background: rgba(232, 113, 10, 0.1);
    color: #e8710a;
}

.stat-orange .dashboard-stat-number {
    color: #e8710a;
}

.stat-red {
    border-left-color: #d93025;
}

.stat-red .dashboard-stat-icon {
    background: rgba(217, 48, 37, 0.1);
    color: #d93025;
}

.stat-red .dashboard-stat-number {
    color: #d93025;
}

.stat-purple {
    border-left-color: #7b1fa2;
}

.stat-purple .dashboard-stat-icon {
    background: rgba(123, 31, 162, 0.1);
    color: #7b1fa2;
}

.stat-purple .dashboard-stat-number {
    color: #7b1fa2;
}

/* --- Dashboard Cards (Widget) --- */
.dashboard-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    overflow: hidden;
    transition: box-shadow 0.2s ease;
}

.dashboard-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.dashboard-card-header {
    padding: 0.85rem 1.2rem;
    font-weight: 700;
    font-size: 0.95rem;
    color: #fff;
    letter-spacing: 0.01em;
}

.header-blue {
    background: linear-gradient(135deg, #1a73e8, #4285f4);
}

.header-green {
    background: linear-gradient(135deg, #0d8a3f, #34a853);
}

.header-orange {
    background: linear-gradient(135deg, #e8710a, #fbbc04);
}

.header-dark {
    background: linear-gradient(135deg, #202124, #3c4043);
}

.dashboard-card-body {
    padding: 1rem;
}

.dashboard-card-body.p-0 {
    padding: 0;
}

/* Responsive border: nur ab lg sichtbar */
@media (min-width: 992px) {
    .border-end-lg {
        border-right: 1px solid #dee2e6 !important;
    }
}

.dashboard-card-footer {
    padding: 0.75rem 1.2rem;
    background: #fafafa;
    border-top: 1px solid #f0f0f0;
    text-align: center;
}

/* --- Dashboard Match Items --- */
.dashboard-match-item {
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.15s ease;
}

.dashboard-match-item:last-child {
    border-bottom: none;
}

.dashboard-match-item:hover {
    background: #f8f9fa;
}

/* --- Dashboard Team Names & Logos --- */
.dashboard-team-name {
    font-size: 0.85rem;
    line-height: 1.2;
    word-wrap: break-word;
    white-space: normal;
}

.dashboard-team-logo {
    border-radius: 4px;
}

/* --- Dashboard Table --- */
.dashboard-table thead {
    background: #f8f9fa;
}

.dashboard-table thead th {
    font-weight: 600;
    font-size: 0.78rem;
    text-transform: uppercase;
    color: #6b7280;
    letter-spacing: 0.04em;
    padding: 0.6rem 0.5rem;
    border-bottom: 2px solid #e5e7eb;
}

.dashboard-table-row {
    transition: background 0.15s ease;
}

.dashboard-table-row:hover {
    background: #f0f7ff;
}

.dashboard-table-row td {
    padding: 0.55rem 0.5rem;
    vertical-align: middle;
}

/* --- Result Cards --- */
.dashboard-result-card {
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 1rem;
    height: 100%;
    background: #fafafa;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    min-height: 120px;
}

.dashboard-result-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    background: #fff;
}

.dashboard-result-team {
    font-size: 0.72rem;
    line-height: 1.2;
    word-wrap: break-word;
    white-space: normal;
    max-height: 2.4em;
    overflow: hidden;
    color: #374151;
}

.dashboard-score {
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #0d8a3f, #34a853);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.dashboard-score-upcoming {
    font-size: 1.1rem;
    font-weight: 700;
    color: #0d6efd;
}

/* --- Dashboard Responsive --- */
@media (max-width: 768px) {
    .dashboard-hero {
        padding: 1.5rem 1rem;
        border-radius: 12px;
    }

    .dashboard-hero-logo {
        height: 70px;
    }

    .dashboard-hero-title {
        font-size: 1.3rem;
    }

    .dashboard-stat-number {
        font-size: 1.3rem;
    }

    .dashboard-stat-icon {
        font-size: 1.4rem;
        width: 40px;
        height: 40px;
    }

    .dashboard-team-name {
        font-size: 0.8rem;
    }

    .dashboard-result-team {
        font-size: 0.68rem;
    }
}

@media (max-width: 480px) {
    .dashboard-hero-title {
        font-size: 1.1rem;
    }

    .dashboard-hero-logo {
        height: 56px;
    }

    .dashboard-stat-card {
        padding: 0.9rem 0.8rem;
        gap: 0.7rem;
    }

    .dashboard-stat-number {
        font-size: 1.1rem;
    }

    .dashboard-stat-label {
        font-size: 0.7rem;
    }
}

/* ===============================
   TABELLE (VOLLANSICHT)
   =============================== */

.tabelle-leader {
    background: linear-gradient(90deg, rgba(245, 175, 25, 0.06), transparent) !important;
}

.tabelle-punkte {
    display: inline-block;
    background: linear-gradient(135deg, #0d8a3f, #34a853);
    color: #fff;
    font-weight: 800;
    font-size: 0.9rem;
    min-width: 34px;
    padding: 0.15rem 0.5rem;
    border-radius: 8px;
    text-align: center;
}

.tabelle-full td {
    padding: 0.65rem 0.5rem;
    vertical-align: middle;
}

@media (max-width: 768px) {
    .tabelle-full {
        font-size: 0.82rem;
    }

    .tabelle-punkte {
        font-size: 0.8rem;
        min-width: 28px;
        padding: 0.1rem 0.35rem;
    }
}

/* ===============================
   TORSCHÜTZINNEN EXPAND/COLLAPSE
   =============================== */

.torschuetzinnen-hidden {
    display: none;
}

.btn-expand i {
    transition: transform 0.3s ease;
}

.btn-expand.expanded i {
    transform: rotate(180deg);
}

/* ===============================
   MATCHCARD MODERN
   =============================== */

.header-red {
    background: linear-gradient(135deg, #c62828, #ef5350);
}

/* Score Header */
.mc-score-header {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    color: #fff;
    border-radius: 12px;
    padding: 1rem 1.2rem;
    margin-bottom: 0.75rem;
}

.mc-score-input {
    width: 52px;
    height: 52px;
    font-size: 1.8rem;
    font-weight: 800;
    border: none;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    text-align: center;
    padding: 0;
    background: #fff;
    color: #1a1a2e;
}

.mc-score-input:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.4), 0 2px 8px rgba(0, 0, 0, 0.15);
}

.mc-team-name {
    font-size: 0.82rem;
    font-weight: 700;
    color: #fff;
}

.mc-meta {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.6);
}

.mc-meta a {
    color: rgba(255, 255, 255, 0.8);
}

.mc-meta a:hover {
    color: #fff;
}

/* MatchCard inner cards */
.mc .dashboard-card {
    border-radius: 10px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

.mc .dashboard-card-header {
    padding: 0.5rem 0.8rem;
    font-size: 0.82rem;
}

.mc .dashboard-card-body {
    padding: 0.5rem 0.6rem;
}

.mc .dashboard-card-footer {
    padding: 0.4rem 0.8rem;
}

/* Kader rows modern */
.mc .kader-row {
    padding: 5px 4px;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    font-size: 0.8rem;
    transition: background 0.15s ease;
    border-radius: 4px;
}

.mc .kader-row:last-child {
    border-bottom: none;
}

.mc .kader-row:hover {
    background: #f0f7ff;
}

/* Tor/Karte rows */
.mc .tor-row {
    padding: 3px 2px;
    cursor: pointer;
    font-size: 0.78rem;
    border-radius: 4px;
    transition: background 0.15s ease;
}

.mc .tor-row:hover {
    background: #f0fff0;
}

.mc .section-badge {
    font-size: 0.6rem;
    padding: 2px 6px;
    border-radius: 10px;
}

.mc .karte-mini {
    font-size: 0.5rem;
    padding: 1px 4px;
    vertical-align: middle;
    border-radius: 4px;
}

.mc .tor-mini {
    font-size: 0.55rem;
    vertical-align: middle;
}

.mc .wechsel-mini {
    font-size: 0.55rem;
    padding: 1px 4px;
    vertical-align: middle;
    border-radius: 4px;
}

/* Trainer selects */
.mc-trainer-select {
    font-size: 0.72rem;
    padding: 2px 6px;
    max-width: 150px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 6px;
}

.mc-trainer-select option {
    color: #333;
    background: #fff;
}

/* Date/Time inputs in header */
.mc-datetime-input {
    font-size: 0.75rem;
    padding: 3px 8px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 6px;
}

.mc-datetime-input:focus {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
    color: #fff;
    outline: none;
}

/* Save button gradient */
.mc-btn-save {
    background: linear-gradient(135deg, #1a73e8, #4285f4);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 6px 24px;
    font-size: 0.85rem;
    font-weight: 600;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.mc-btn-save:hover {
    box-shadow: 0 4px 12px rgba(26, 115, 232, 0.3);
    transform: translateY(-1px);
    color: #fff;
}

/* Top bar */
.mc-topbar {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 6px 10px;
    margin-bottom: 0.75rem;
}
