/* Seasons Page Container */
.seasons-page {
    background: #FFF;
    padding: 2.5rem;
    padding-top: 4rem; /* tighter top spacing */
    position: relative;
    z-index: 1;
}

/* Content Wrapper using relative width and side padding */
.content-wrapper {
    position: relative;
    width: 90%;
    max-width: 100%;
    margin: 0 auto;
    padding: 0 1.25rem;
}

/* Page Header */
.page-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin: 0 auto;
    width: 100%;
}

/* Header Left Section */
.header-left {
    display: flex;
    flex-direction: column; /* title above filters */
    align-items: flex-start;
    gap: 0.5rem;
}

/* Right: Special Exits Box */
.special-exits {
    width: 17.5rem;
    border: 0.125rem solid #4CAF50;
    padding: 0.625rem;
    background-color: #FFF;
    text-align: center;
    font-size: 0.875rem;
    border-radius: 0.5rem;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.1);
}

    .special-exits h4 {
        margin: 0;
        text-align: center;
        font-size: 1rem;
        font-weight: 600;
        color: #181D27;
    }

    .special-exits hr {
        border-top: 0.0625rem solid #4CAF50;
        margin: 0.3125rem 0;
    }

    .special-exits p {
        margin: 0.3125rem 0;
        font-size: 0.875rem;
        color: #535862;
    }

    .special-exits strong {
        color: firebrick;
    }

/* Page Title (match rest of site) */
.page-title {
    font-size: 2rem;
    font-weight: 700;
    color: #181D27;
    line-height: 1.2;
    margin: 0 0 .25rem 0;
}

/* Filters row (dropdowns + toggles) */
.dropdown-section {
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    align-items: flex-end;
    gap: 1rem;
    flex: 1 0 0;
}

/* Stacked label + control */
.control-group {
    display: flex;
    flex-direction: column;
    gap: .25rem;
}

/* Small label styling (not a title) */
.field-label {
    font-size: 0.875rem;
    line-height: 1rem;
    font-weight: 600;
    color: #535862;
    margin: 0;
}

/* Dropdown Button Styles */
.seasons-dropdown .seasons-dropdown-toggle {
    display: flex;
    padding: 0.625rem 1rem;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    border-radius: 0.5rem;
    border: 0.0625rem solid var(--Gray-300, #D5D7DA);
    background: var(--White, #FFF);
    box-shadow: 0 0.0625rem 0.125rem rgba(10, 13, 18, 0.05);
}

    .seasons-dropdown .seasons-dropdown-toggle::after {
        content: '\25BC';
        margin-left: 0.5rem;
        font-size: 0.75rem;
        line-height: 1;
    }

.seasons-dropdown.show .seasons-dropdown-toggle::after {
    content: '\25B2';
}

/* Shared segmented switch styling (both toggles) */
.segmented-switch {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    border-radius: 999px;
    padding: 0.25rem;
    background: #fff;
    border: 1px solid var(--Gray-300, #D5D7DA);
    box-shadow: 0 1px 2px rgba(10,13,18,0.06);
    user-select: none;
}

    .segmented-switch .seg-btn {
        border: 0;
        background: transparent;
        padding: 0.5rem 0.9rem;
        font-size: 0.95rem;
        line-height: 1;
        border-radius: 999px;
        cursor: pointer;
        color: #535862;
        transition: background-color .15s ease, color .15s ease, box-shadow .15s ease;
    }

        .segmented-switch .seg-btn:hover {
            background: rgba(0,0,0,0.04);
        }

        .segmented-switch .seg-btn.active {
            background: #181D27;
            color: #fff;
            box-shadow: 0 1px 2px rgba(0,0,0,0.15);
        }

    .segmented-switch .seg-info {
        border: 0;
        background: transparent;
        width: 28px;
        height: 28px;
        border-radius: 50%;
        font-weight: 700;
        font-family: system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, 'Helvetica Neue', Arial, 'Noto Sans';
        cursor: help;
        color: #535862;
    }

        .segmented-switch .seg-info:hover {
            background: rgba(0,0,0,0.04);
        }

/* Score Table Container */
.score-table {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin: 1.5rem 0 2.5rem;
    width: 100%;
    border-radius: 0.75rem;
    border: 0.0625rem solid var(--Gray-200, #E9EAEB);
    background: var(--White, #FFF);
    box-shadow: 0 0.0625rem 0.1875rem rgba(10, 13, 18, 0.10), 0 0.0625rem 0.125rem rgba(10, 13, 18, 0.06);
}

/* Card Header */
.card-header {
    width: 100%;
    background: var(--White, #FFF);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}

.card-header-content {
    display: flex;
    padding: 1.0rem 1.5rem 0.9rem 1.5rem;
    align-items: center;
    gap: 0.5rem;
    align-self: stretch;
}

.card-season {
    color: var(--Gray-900, #181D27);
    font-family: 'Inter', sans-serif;
    font-size: 1.125rem;
    font-weight: 500;
    line-height: 1.75rem;
}

.card-episode {
    color: #535862;
    font-family: 'Inter', sans-serif;
    font-size: 0.875rem;
    font-weight: 400;
    line-height: 1.25rem;
}

/* Table Container */
.table-container {
    width: 100%;
}

/* Top + Bottom synced scrollbars (Top shows a real scrollbar) */
.table-scroll-wrapper {
    position: relative;
}

.table-scroll-top {
    overflow-x: scroll; /* force scrollbar */
    overflow-y: hidden;
    min-height: 22px; /* enough height so bar is visible on Windows */
    height: 22px;
    background: #FAFAFA;
    border: 1px solid #E9EAEB;
    border-radius: 6px;
    margin-bottom: 6px;
    position: relative;
    scrollbar-gutter: stable; /* keep space for scrollbar when not scrolling */
}

    .table-scroll-top .scroll-spacer {
        height: 1px;
    }
    /* provides scrollable content */
    .table-scroll-top .scroll-hint {
        display: none; /* shown via JS only when overflow exists */
        position: absolute;
        right: 10px;
        top: 2px;
        font-size: 12px;
        color: #6B7280;
        pointer-events: none;
    }

.table-scroll {
    overflow-x: auto;
    scrollbar-gutter: stable;
}

/* Make the top scrollbar look like a standard Windows scrollbar (Chromium/Edge) */
.table-scroll-top::-webkit-scrollbar {
    height: 14px;
}

.table-scroll-top::-webkit-scrollbar-track {
    background: #EEE;
    border-radius: 7px;
}

.table-scroll-top::-webkit-scrollbar-thumb {
    background: #C3C7CF;
    border-radius: 7px;
}

    .table-scroll-top::-webkit-scrollbar-thumb:hover {
        background: #A9AFB8;
    }

/* Firefox */
.table-scroll-top {
    scrollbar-width: thin;
    scrollbar-color: #C3C7CF #EEE;
}

/* Table Styles */
.table {
    width: 100%;
    border-collapse: collapse;
    table-layout: auto;
    font-family: 'Inter', sans-serif;
    background: var(--White, #FFF);
}

    .table thead tr {
        background: var(--Gray-50, #FAFAFA);
    }

    .table thead th {
        border: 0.0625rem solid var(--Gray-200, #E9EAEB);
        text-align: center;
        font-size: 0.8rem;
        font-weight: 600;
        line-height: 1.2rem;
        padding: 0.9rem 1rem;
        white-space: normal; /* allow wrapping when showing full titles */
        color: var(--Gray-600, #535862);
    }

    /* Table row styling */
    .table tbody tr {
        border-bottom: 0.0625rem solid var(--Gray-200, #E9EAEB);
    }

    .table tbody td {
        text-align: center;
        font-size: 0.95rem;
        font-weight: 500;
        line-height: 1.35rem;
        padding: 0.9rem 1rem;
        color: var(--Gray-700, #3A3F47);
        white-space: normal;
    }

        /* Player Cell Styling */
        .table tbody td.player-cell {
            border: none;
            text-align: left;
            padding: 0.6rem 0.75rem;
            background: transparent;
            /* default accent (overridden per-row via --player-accent) */
            --player-accent: #181D27;
        }

.player-cell {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

    .player-cell img {
        width: 2.25rem;
        height: 2.25rem;
        border-radius: 50%;
        border: 2px solid var(--player-accent, #D5D7DA); /* visible ring */
    }

.player-name {
    font-weight: 700;
    color: var(--player-accent, #181D27); /* name follows avatar ring */
}

/* Hover effect for table rows */
.table tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.03);
}

/* Placement Column */
.table tbody td.placement-cell {
    text-align: center;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.35rem;
    padding: 0.9rem 1rem;
    color: var(--Gray-700, #3A3F47);
    white-space: normal;
}

/* Column Highlighting */
.highlight-col {
    background-color: rgba(0, 0, 0, 0.03) !important;
    transition: background-color 0.3s ease;
}

/* Responsive adjustments for smaller screens */
@media (max-width: 768px) {
    .page-title {
        font-size: 1.5rem;
    }

    .special-exits {
        width: 100%;
        max-width: 17.5rem;
    }

    .card-header-content {
        flex-direction: column;
        align-items: flex-start;
    }

    .dropdown-section {
        flex-direction: column;
        gap: 0.625rem;
        align-items: stretch;
    }

    .segmented-switch {
        width: 100%;
        justify-content: flex-start;
    }
}

.hero-banner {
    width: 100%;
    overflow: hidden;
    position: relative;
    z-index: 1;
}

    .hero-banner img {
        width: 100%;
        object-fit: cover;
        display: block;
    }

.placement-cell {
    position: relative;
}

.special-exit-label {
    position: absolute;
    top: 0.25rem;
    left: 0.25rem;
    color: firebrick;
    font-weight: bold;
    font-size: 0.75rem;
    z-index: 2;
}
