:root {
    --jz-brand-red: #d90429;
    --jz-brand-red-light: rgba(217, 4, 41, 0.08);
    --jz-bg-card: #ffffff;
    --jz-text-primary: #0f172a;
    --jz-text-secondary: #475569;
    --jz-text-muted: #64748b;
    --jz-border-color: #e2e8f0;
}

.table-wrapper {
    position: relative;
    max-height: 750px;
    overflow-y: auto;
    border-radius: 12px;
    border: 1px solid var(--jz-border-color);
    background: var(--jz-bg-card);
    margin-bottom: 20px;
}

.schedule-table {
    width: 100% !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    text-align: left;
    font-family: inherit;
    margin: 0 !important;
}

.schedule-table thead th {
    position: sticky;
    top: 0;
    z-index: 10;
    background: #f1f5f9;
    color: var(--jz-text-secondary);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 14px 18px;
    border-bottom: 2px solid var(--jz-border-color);
}

.schedule-table tbody tr.schedule-row {
    transition: background-color 0.2s ease;
}

.schedule-table tbody tr.schedule-row:nth-child(even) {
    background-color: #f8fafc;
}

.schedule-table tbody tr.schedule-row:hover {
    background-color: #f1f5f9;
}

.schedule-table tbody tr.schedule-row.is-past {
    opacity: 0.65;
    font-style: italic;
}

.schedule-table td {
    padding: 14px 18px;
    border-bottom: 1px solid var(--jz-border-color);
    font-size: 0.95rem;
    vertical-align: middle;
}

/* Refined Month Divider Bar */
tr.month-divider-row {
    background: #475569 !important;
}

tr.month-divider-row td {
    color: #ffffff !important;
    font-size: 0.82rem !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.08em !important;
    padding: 9px 18px !important;
    border-bottom: none !important;
}

.date-cell {
    white-space: nowrap;
    font-weight: 600;
}

.date-cell .time-sub {
    display: block;
    font-size: 0.82rem;
    font-weight: 500;
    color: var(--jz-text-muted);
    margin-top: 2px;
}

strong.team-highlight {
    color: #b91c1c !important;
    font-weight: 700 !important;
    background: transparent !important;
    padding: 0 !important;
}

.league-prefix {
    display: block;
    font-size: 0.78rem;
    font-weight: 700;
    color: #475569;
    margin-bottom: 4px;
}

.vs-divider {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 700;
    color: #64748b;
    background: #e2e8f0;
    padding: 1px 7px;
    border-radius: 4px;
    margin: 0 6px;
    text-transform: uppercase;
    vertical-align: middle;
    line-height: 1.4;
}

.category-badge {
    display: inline-block;
    padding: 3px 8px;
    background: #e2e8f0;
    color: #334155;
    border-radius: 16px;
    font-size: 0.78rem;
    font-weight: 600;
}

.location-cell {
    color: var(--jz-text-secondary);
}

.location-cell.has-location::before {
    content: "📍 ";
    margin-right: 4px;
}

/* Subtle Info Button */
.btn-info {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 12px;
    background-color: #eff6ff !important;
    color: #1d4ed8 !important;
    border: 1px solid #bfdbfe;
    border-radius: 6px;
    text-decoration: none !important;
    font-weight: 600;
    font-size: 0.82rem;
    transition: all 0.2s ease;
}

.btn-info:hover {
    background-color: #dbeafe !important;
    color: #1e40af !important;
    border-color: #93c5fd;
    transform: translateY(-1px);
}

.schedule-sub-actions {
    display: flex;
    gap: 12px;
    margin-top: 16px;
    flex-wrap: wrap;
}

.btn-sub {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none !important;
    color: #fff !important;
    transition: all 0.2s ease;
}

.btn-sub-primary { background: #0078d4; }
.btn-sub-secondary { background: #28a745; }
.btn-sub:hover { opacity: 0.9; transform: translateY(-1px); }

@media (max-width: 768px) {
    .table-wrapper {
        max-height: none;
        border: none;
        background: transparent;
        overflow: visible;
    }

    .schedule-table, .schedule-table tbody {
        display: block;
    }

    .schedule-table thead {
        display: none;
    }

    .schedule-table tbody tr.schedule-row {
        display: block;
        background: #ffffff !important;
        margin-bottom: 16px;
        border-radius: 12px;
        padding: 16px;
        box-shadow: 0 4px 12px rgba(0,0,0,0.06);
        border: 1px solid var(--jz-border-color);
    }

    .schedule-table td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px 0;
        border-bottom: 1px solid #f1f5f9;
        text-align: right;
    }

    .schedule-table td.event-cell {
        display: block !important;
        text-align: left !important;
        padding: 12px 0 !important;
        line-height: 1.6;
    }

    .schedule-table td.event-cell::before {
        display: block !important;
        margin-bottom: 6px !important;
    }

    .schedule-table td:last-child {
        border-bottom: none;
    }

    .schedule-table td::before {
        content: attr(data-label);
        font-weight: 700;
        color: var(--jz-text-muted);
        font-size: 0.8rem;
        text-transform: uppercase;
        text-align: left;
        margin-right: 16px;
        flex-shrink: 0;
    }

    .date-cell .time-sub {
        display: inline;
        margin-left: 6px;
        margin-top: 0;
    }

    tr.month-divider-row {
        display: block;
        margin: 20px 0 10px 0;
        border-radius: 6px;
    }

    tr.month-divider-row td {
        display: block;
        text-align: center !important;
    }

    tr.month-divider-row td::before {
        display: none !important;
    }
}
