/* ============================================
   PLAYERS PAGE - ROSTER LIST
   ============================================ */

:root {
    --predators-gold: #FFB81C;
    --predators-navy: #041E42;
}

.page-players {
    background: #EDEEF0;
    min-height: 100vh;
}

/* ============================================
   PAGE HEADER
   ============================================ */

.players-page-header {
    background: #041E42;
    color: white;
    padding: 24px 24px 20px;
}

.players-header-content {
    max-width: 1400px;
    margin: 0 auto;
}

.players-page-header h1 {
    font-size: 32px;
    font-weight: 900;
    margin: 0 0 8px 0;
}

.season-subtitle {
    font-size: var(--font-size-base);
    opacity: 0.9;
    margin: 0;
    line-height: var(--line-height-normal);
}

/* ============================================
   ROSTER CONTAINER
   ============================================ */

.roster-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 32px 24px;
}

/* ============================================
   ROSTER ANALYTICS GRID - 4 CARD DASHBOARD
   ============================================ */

.team-stats-overview {
    margin-bottom: 28px;
}

.roster-analytics-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.analytics-card {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.analytics-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
}

.analytics-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 16px;
    background: #041E42;
    color: #ffffff;
}

.analytics-icon {
    font-size: 18px;
}

.analytics-title {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.analytics-card-body {
    padding: 16px;
}

/* Donut Chart Card */
.donut-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
}

.donut-container {
    width: 100px;
    height: 100px;
}

.donut-chart {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.donut-segment {
    transition: stroke-dasharray 0.5s ease;
}

.donut-total {
    font-size: 20px;
    font-weight: 900;
    fill: #1f2937;
    transform: rotate(90deg);
    transform-origin: 50px 50px;
}

.donut-label {
    font-size: 8px;
    fill: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transform: rotate(90deg);
    transform-origin: 50px 50px;
}

.donut-legend {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-weight: 600;
    color: #4b5563;
}

.legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.legend-dot.forward { background: #3b82f6; }
.legend-dot.defense { background: #ef4444; }
.legend-dot.goalie { background: #22c55e; }

/* Stats Body */
.stats-body {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.stat-row-item {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 8px 0;
    border-bottom: 1px solid #f3f4f6;
}

.stat-row-item:last-child {
    border-bottom: none;
}

.stat-row-item.range {
    padding: 4px 0;
}

.stat-row-label {
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
}

.stat-row-value {
    font-size: 18px;
    font-weight: 800;
    color: #1f2937;
}

.stat-row-value.small {
    font-size: 14px;
    font-weight: 600;
}

/* Country Flags */
.country-flags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 8px 0;
    justify-content: center;
}

.country-flag-item {
    display: flex;
    align-items: center;
    gap: 4px;
    background: #f3f4f6;
    padding: 4px 8px;
    border-radius: 6px;
}

.flag-emoji {
    font-size: 16px;
}

.flag-count {
    font-size: 12px;
    font-weight: 700;
    color: #4b5563;
}

.country-more {
    font-size: 11px;
    font-weight: 600;
    color: #9ca3af;
    padding: 4px 8px;
    background: #f9fafb;
    border-radius: 6px;
}

/* Handedness Card */
.handedness-body {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding-top: 20px;
}

.handedness-bar-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.handedness-bar {
    display: flex;
    height: 16px;
    border-radius: 8px;
    overflow: hidden;
    background: #f3f4f6;
}

.handedness-left {
    background: linear-gradient(90deg, #FFB81C, #fcd34d);
    transition: width 0.5s ease;
}

.handedness-right {
    background: linear-gradient(90deg, #041E42, #1e3a5f);
    transition: width 0.5s ease;
}

.handedness-labels {
    display: flex;
    justify-content: space-between;
}

.hand-label {
    display: flex;
    align-items: center;
    gap: 6px;
}

.hand-label.left {
    color: #b45309;
}

.hand-label.right {
    color: #041E42;
}

.hand-side {
    font-size: 14px;
    font-weight: 800;
}

.hand-count {
    font-size: 18px;
    font-weight: 900;
}

.handedness-summary {
    display: flex;
    justify-content: space-between;
    padding-top: 8px;
    border-top: 1px solid #f3f4f6;
}

.hand-pct {
    font-size: 12px;
    font-weight: 600;
}

.hand-pct.left {
    color: #b45309;
}

.hand-pct.right {
    color: #041E42;
}

/* Handedness Breakdown by Position */
.handedness-breakdown {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-top: 12px;
    border-top: 1px solid #f3f4f6;
    margin-top: 4px;
}

.breakdown-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.breakdown-label {
    font-size: 11px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.breakdown-value {
    font-size: 12px;
    font-weight: 700;
    color: #1f2937;
}

/* ============================================
   ANALYTICS GRID RESPONSIVE
   ============================================ */

@media (max-width: 1200px) {
    .roster-analytics-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .team-stats-overview {
        margin-bottom: 20px;
    }

    .roster-analytics-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .analytics-card-header {
        padding: 12px 14px;
    }

    .analytics-icon {
        font-size: 16px;
    }

    .analytics-title {
        font-size: 11px;
    }

    .analytics-card-body {
        padding: 14px;
    }

    .donut-container {
        width: 90px;
        height: 90px;
    }

    .stat-row-value {
        font-size: 16px;
    }

    .hand-count {
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .roster-analytics-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .analytics-card-body {
        padding: 16px;
    }

    .donut-card {
        flex-direction: row;
        justify-content: space-around;
    }

    .donut-legend {
        flex-direction: column;
        gap: 8px;
    }

    .handedness-body {
        padding-top: 12px;
    }
}

.roster-section {
    margin-bottom: 48px;
}

/* ============================================
   ROSTER CONTROLS - FILTERS & SEARCH
   ============================================ */

.roster-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

/* Position Filter Tabs */
.position-filter-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.filter-tab {
    padding: 10px 20px;
    background: #ffffff;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
    cursor: pointer;
    transition: all 0.2s ease;
}

.filter-tab:hover {
    border-color: #d1d5db;
    color: #374151;
}

.filter-tab.active {
    background: #041E42;
    border-color: #041E42;
    color: #ffffff;
}

/* Player Search */
.player-search-wrapper {
    position: relative;
    flex: 0 0 auto;
}

.player-search-input {
    width: 240px;
    padding: 10px 16px 10px 42px;
    background: #ffffff;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
    color: #374151;
    transition: all 0.2s ease;
}

.player-search-input:focus {
    outline: none;
    border-color: #FFB81C;
    box-shadow: 0 0 0 3px rgba(255, 184, 28, 0.15);
}

.player-search-input::placeholder {
    color: #9ca3af;
}

.player-search-wrapper .search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #9ca3af;
    pointer-events: none;
}

/* Responsive controls */
@media (max-width: 768px) {
    .roster-controls {
        flex-direction: column;
        align-items: stretch;
    }

    .position-filter-tabs {
        justify-content: center;
        order: 2;
    }

    .filter-tab {
        padding: 8px 14px;
        font-size: 12px;
    }

    .player-search-wrapper {
        order: 1;
        width: 100%;
    }

    .player-search-input {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .position-filter-tabs {
        width: 100%;
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 6px;
    }

    .filter-tab {
        padding: 8px 4px;
        font-size: 11px;
        text-align: center;
    }
}

/* No results message */
.no-results-message {
    text-align: center;
    padding: 48px 20px;
    background: #ffffff;
    border-radius: 12px;
}

.no-results-message p {
    color: #6b7280;
    font-size: 16px;
    margin: 0;
}

/* Mobile-optimized roster container */
@media (max-width: 768px) {
    .roster-container {
        padding: 20px 16px;
    }

    .section-heading {
        font-size: 20px;
        margin-bottom: 16px;
        padding-bottom: 10px;
    }

    .roster-with-sidebar {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .roster-sidebar {
        position: static;
        order: -1; /* Move spotlight above table on mobile */
    }
}

@media (max-width: 480px) {
    .roster-container {
        padding: 16px 12px;
    }

    .section-heading {
        font-size: 18px;
        margin-bottom: 14px;
        padding-bottom: 8px;
    }

    .roster-with-sidebar {
        gap: 16px;
    }
}

/* Touch-friendly interactions on mobile */
@media (hover: none) and (pointer: coarse) {
    .stat-block:hover,
    .stat-inline:hover {
        transform: none; /* Disable hover transforms on touch devices */
    }

    .stat-block:active {
        background: rgba(255, 255, 255, 0.1);
        transform: scale(0.98);
    }

    .stat-inline:active {
        background: rgba(255, 255, 255, 0.08);
    }
}

.section-heading {
    font-size: 24px;
    font-weight: 800;
    color: #48494A;
    margin: 0 0 20px 0;
    padding-bottom: 12px;
    border-bottom: 3px solid var(--predators-gold);
}

/* ============================================
   ROSTER TABLE
   ============================================ */

.roster-with-sidebar {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 24px;
    align-items: start;
}

.roster-table-wrapper {
    background: #FFFFFF;
    border-radius: 12px;
    overflow-x: auto;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.roster-sidebar {
    position: sticky;
    top: 20px;
}

.roster-card {
    background: #FFFFFF;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border-top: 4px solid var(--predators-gold);
    overflow: hidden;
}

.roster-card-title {
    font-size: 18px;
    font-weight: 800;
    color: #48494A;
    margin: 0 0 16px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--predators-gold);
}

/* ============================================
   PLAYER SPOTLIGHT - 6 CATEGORIES GRID
   ============================================ */

.spotlight-grid-header {
    padding: 14px 16px;
    background: #041E42;
    border-radius: 12px 12px 0 0;
    margin: -20px -20px 16px -20px;
}

.spotlight-grid-title {
    font-size: 12px;
    font-weight: 700;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.spotlight-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.spotlight-mini-card {
    background: #f9fafb;
    border-radius: 10px;
    padding: 12px;
    text-align: center;
    transition: all 0.2s ease;
    border: 1px solid #f3f4f6;
}

.spotlight-mini-card:hover {
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.spotlight-mini-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    margin-bottom: 10px;
}

.mini-icon {
    font-size: 14px;
}

.mini-title {
    font-size: 10px;
    font-weight: 700;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.spotlight-mini-photo {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: 3px solid var(--predators-gold);
    object-fit: cover;
    margin-bottom: 8px;
}

.spotlight-mini-info {
    margin-bottom: 6px;
}

.mini-name {
    font-size: 12px;
    font-weight: 700;
    color: #1f2937;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mini-position {
    font-size: 10px;
    color: #9ca3af;
    font-weight: 500;
}

.spotlight-mini-stat {
    font-size: 14px;
    font-weight: 800;
    color: #041E42;
    background: linear-gradient(135deg, rgba(255, 184, 28, 0.15), rgba(255, 184, 28, 0.05));
    padding: 4px 10px;
    border-radius: 12px;
    display: inline-block;
}

/* Legacy spotlight styles (kept for compatibility) */
.spotlight-header {
    margin-bottom: 16px;
}

.spotlight-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #FFB81C 0%, #e5a519 100%);
    color: #041E42;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(255, 184, 28, 0.3);
}

.badge-emoji {
    font-size: 18px;
}

.spotlight-player-card {
    text-align: center;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 2px solid #EDEEF0;
}

.spotlight-headshot {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 4px solid var(--predators-gold);
    margin: 0 auto 12px;
    object-fit: cover;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.spotlight-player-info {
    margin-top: 12px;
}

.spotlight-name {
    font-size: 20px;
    font-weight: 900;
    color: #041E42;
    margin: 0 0 4px 0;
    line-height: 1.2;
}

.spotlight-position {
    font-size: 13px;
    color: #6b7280;
    font-weight: 600;
    margin-bottom: 8px;
}

.spotlight-subtitle {
    font-size: 14px;
    font-weight: 700;
    color: #FFB81C;
    margin: 8px 0 4px;
}

.spotlight-description {
    font-size: 12px;
    color: #9ca3af;
    font-style: italic;
}

.spotlight-stats {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.stat-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    background: #f9fafb;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.stat-row:hover {
    background: #f3f4f6;
    transform: translateX(4px);
}

.stat-icon {
    font-size: 24px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    border-radius: 8px;
    flex-shrink: 0;
}

.stat-info {
    flex: 1;
    text-align: left;
}

.stat-info .stat-label {
    font-size: 11px;
    font-weight: 600;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}

.stat-info .stat-value {
    font-size: 14px;
    font-weight: 700;
    color: #041E42;
    line-height: 1.2;
}

.fun-facts-section {
    margin-top: 20px;
}

.fun-facts-title {
    font-size: 14px;
    font-weight: 700;
    color: #48494A;
    margin: 0 0 12px 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.fun-fact-item {
    background: #EDEEF0;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 10px;
    border-left: 3px solid var(--predators-gold);
}

.fun-fact-item:last-child {
    margin-bottom: 0;
}

.fun-fact-label {
    font-size: 11px;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 700;
    margin-bottom: 4px;
}

.fun-fact-value {
    font-size: 13px;
    color: #48494A;
    font-weight: 600;
    line-height: 1.4;
}

/* ============================================
   SPOTLIGHT GRID RESPONSIVE
   ============================================ */

@media (max-width: 1024px) {
    .spotlight-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .roster-sidebar {
        order: -1;
    }

    .spotlight-grid-header {
        margin: -16px -16px 14px -16px;
        padding: 12px 14px;
    }

    .spotlight-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 10px;
    }

    .spotlight-mini-card {
        padding: 10px;
    }

    .spotlight-mini-photo {
        width: 48px;
        height: 48px;
    }

    .mini-name {
        font-size: 11px;
    }

    .spotlight-mini-stat {
        font-size: 12px;
        padding: 3px 8px;
    }
}

@media (max-width: 480px) {
    .spotlight-grid-header {
        margin: -16px -16px 12px -16px;
        padding: 10px 12px;
    }

    .spotlight-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .spotlight-mini-card {
        padding: 10px 8px;
    }

    .spotlight-mini-photo {
        width: 44px;
        height: 44px;
        border-width: 2px;
    }

    .mini-title {
        font-size: 9px;
    }

    .mini-name {
        font-size: 10px;
    }

    .mini-position {
        font-size: 9px;
    }

    .spotlight-mini-stat {
        font-size: 11px;
    }
}

.roster-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 900px;
}

.roster-table thead {
    background: #041E42;
    position: sticky;
    top: 0;
    z-index: 10;
}

.roster-table th {
    color: white;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    padding: 8px 6px;
    text-align: center;
    background: #041E42;
    border-right: 1px solid #1E1F21;
    cursor: pointer;
    user-select: none;
}

.roster-table th:last-child {
    border-right: none;
}

.roster-table th.text-center {
    text-align: center;
}

.roster-table th.text-left {
    text-align: left;
}

.roster-table th:hover {
    background: #1E1F21;
}

/* Sortable column indicators */
.roster-table th.sortable {
    cursor: pointer;
    user-select: none;
}

.roster-table th.sortable::after {
    content: ' ⇅';
    opacity: 0.4;
    font-size: 10px;
}

.roster-table th.sortable:hover::after {
    opacity: 0.7;
}

.roster-table th.sorted-asc::after {
    content: ' ▲';
    opacity: 1;
}

.roster-table th.sorted-desc::after {
    content: ' ▼';
    opacity: 1;
}

.roster-table tbody tr {
    border-bottom: 1px solid #1E1F21;
    transition: background 0.2s ease;
}

.roster-table tbody tr:hover {
    background: #EDEEF0;
}

/* Section headers removed to match stats page */

.roster-table td {
    padding: 6px 6px;
    font-size: 12px;
    color: #48494A;
    text-align: center;
    border-right: 1px solid #1E1F21;
}

.roster-table td:last-child {
    border-right: none;
}

.roster-table td.text-center {
    text-align: center;
}

/* Player Name Cell with Headshot (matching stats page) */
.player-name-cell {
    display: flex;
    align-items: center;
    text-align: left;
    gap: 8px;
    max-width: 180px;
    min-width: 180px;
}

.player-headshot-small,
.player-headshot-tiny {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 1px solid #ddd;
    object-fit: cover;
    background: white;
    flex-shrink: 0;
}

.player-info-wrapper {
    display: flex;
    flex-direction: column;
    min-width: 0;
    flex: 1;
    overflow: hidden;
}

.player-name,
.player-name-text {
    font-weight: 600;
    color: #48494A;
    font-size: 12px;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.player-number,
.player-number-inline {
    font-size: 10px;
    color: #9CA3AF;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Position Badge */
.position-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 700;
    text-align: center;
}

.position-badge.forward {
    background: rgba(59, 130, 246, 0.15);
    color: #1e40af;
}

.position-badge.defense {
    background: rgba(239, 68, 68, 0.15);
    color: #991b1b;
}

.position-badge.goalie {
    background: rgba(34, 197, 94, 0.15);
    color: #15803d;
}

/* Shoots/Catches */
.shoots-catches {
    font-weight: 600;
}

/* Country Flag */
.country-flag {
    width: 24px;
    height: 18px;
    object-fit: cover;
    border-radius: 2px;
    margin-right: 6px;
    vertical-align: middle;
}

/* Section Icon */
.section-icon {
    font-size: 20px;
    margin-right: 8px;
}

/* ============================================
   LOADING & ERROR STATES
   ============================================ */

.loading-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    gap: 16px;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--predators-gold);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-spinner p {
    color: #6b7280;
    font-size: 14px;
}

.error-message {
    text-align: center;
    padding: 60px 20px;
    color: #6b7280;
    font-size: 16px;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 1024px) {
    .roster-with-sidebar {
        grid-template-columns: 1fr;
    }

    .roster-sidebar {
        position: static;
    }

    .roster-table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .roster-table {
        min-width: 900px;
    }
}

@media (max-width: 768px) {
    .players-page-header {
        padding: 20px 16px 16px;
    }

    .players-page-header h1 {
        font-size: 24px;
    }

    .roster-container {
        padding: 24px 16px;
    }

    .section-heading {
        font-size: 20px;
    }

    .roster-table th,
    .roster-table td {
        padding: 12px 8px;
        font-size: 14px;
    }

    .player-headshot-small {
        width: 40px;
        height: 40px;
    }

    .player-name-cell {
        gap: 8px;
    }

    .player-name {
        font-size: 15px;
    }

    /* Enable horizontal scroll for tables on tablets/landscape */
    .roster-table-wrapper {
        position: relative;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    /* Visual indicator for horizontal scrolling */
    /* Scroll indicator removed - was creating persistent white bar */
    /* .roster-table-wrapper::after {
        content: '';
        position: absolute;
        top: 0;
        right: 0;
        bottom: 0;
        width: 40px;
        background: linear-gradient(to left, rgba(255, 255, 255, 0.95), transparent);
        pointer-events: none;
        z-index: 5;
    } */

    /* Make first column (Player name) sticky for tablets/landscape */
    .roster-table th:first-child,
    .roster-table td:first-child {
        position: sticky;
        left: 0;
        z-index: 10;
        background-color: #ffffff;
        box-shadow: 2px 0 4px rgba(0, 0, 0, 0.1);
    }

    .roster-table thead th:first-child {
        z-index: 11;
        background-color: #041E42;
    }

    .roster-table tbody tr.section-header td:first-child {
        background-color: #EDEEF0;
    }
}

@media (max-width: 480px) {
    /* Hide table on mobile, show cards */
    .roster-table-wrapper {
        display: none;
    }

    /* Mobile Player Cards Grid */
    .mobile-player-cards {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .mobile-player-card {
        background: #ffffff;
        border-radius: 12px;
        padding: 16px;
        display: flex;
        align-items: center;
        gap: 14px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
        transition: all 0.2s ease;
    }

    .mobile-player-card:active {
        transform: scale(0.98);
        box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
    }

    .mobile-player-card .player-headshot {
        width: 64px;
        height: 64px;
        border-radius: 50%;
        border: 3px solid var(--predators-gold);
        object-fit: cover;
        flex-shrink: 0;
    }

    .mobile-player-card .player-details {
        flex: 1;
        min-width: 0;
    }

    .mobile-player-card .player-name-row {
        display: flex;
        align-items: baseline;
        gap: 8px;
        margin-bottom: 4px;
    }

    .mobile-player-card .player-name {
        font-size: 16px;
        font-weight: 700;
        color: #041E42;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .mobile-player-card .player-number {
        font-size: 14px;
        font-weight: 600;
        color: #6b7280;
    }

    .mobile-player-card .player-meta {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        margin-bottom: 8px;
    }

    .mobile-player-card .position-pill {
        padding: 3px 10px;
        border-radius: 12px;
        font-size: 11px;
        font-weight: 700;
        text-transform: uppercase;
    }

    .mobile-player-card .position-pill.forward {
        background: rgba(59, 130, 246, 0.15);
        color: #1e40af;
    }

    .mobile-player-card .position-pill.defense {
        background: rgba(239, 68, 68, 0.15);
        color: #991b1b;
    }

    .mobile-player-card .position-pill.goalie {
        background: rgba(34, 197, 94, 0.15);
        color: #15803d;
    }

    .mobile-player-card .player-info-text {
        font-size: 12px;
        color: #6b7280;
    }

    .mobile-player-card .player-stats-row {
        display: flex;
        gap: 16px;
    }

    .mobile-player-card .stat-item {
        text-align: center;
    }

    .mobile-player-card .stat-value {
        font-size: 16px;
        font-weight: 800;
        color: #041E42;
        line-height: 1;
    }

    .mobile-player-card .stat-label {
        font-size: 9px;
        color: #9ca3af;
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }

    /* Position group headers on mobile */
    .mobile-position-header {
        font-size: 16px;
        font-weight: 800;
        color: #48494A;
        padding: 12px 0 8px;
        margin-top: 8px;
        border-bottom: 2px solid var(--predators-gold);
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .mobile-position-header:first-child {
        margin-top: 0;
    }

    .mobile-position-count {
        font-size: 12px;
        font-weight: 600;
        color: #6b7280;
        background: #EDEEF0;
        padding: 2px 8px;
        border-radius: 10px;
    }
}

/* Desktop: Show table, hide mobile cards */
@media (min-width: 481px) {
    .mobile-player-cards {
        display: none !important;
    }

    #mobile-cards-container {
        display: none !important;
    }
}

/* Mobile: Show cards container */
@media (max-width: 480px) {
    #mobile-cards-container {
        display: block;
    }
}
