/* Laning Phase Styles */

.laning-container {
    padding: 0 var(--spacing-lg);
}

/* Lane Tabs */
.lane-tabs {
    display: flex;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-xl);
    justify-content: space-between;
    align-items: center;
}

.lane-tabs-left,
.lane-tabs-right {
    display: flex;
    gap: var(--spacing-sm);
}

.lane-tab {
    background: rgba(30, 35, 50, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 12px 20px;
    color: var(--text-muted);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
    height: 46px;
}

.lane-tab:hover {
    background: rgba(30, 35, 50, 0.8);
    border-color: rgba(255, 255, 255, 0.15);
}

.lane-tab.active {
    background: rgba(239, 68, 68, 0.2);
    border-color: #ef4444;
    color: var(--text-primary);
}

.lane-tab-icon {
    width: 22px;
    height: 22px;
    object-fit: contain;
}

.lane-tab-label {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Lane Content */
.lane-content {
    position: relative;
}

.lane-matchup {
    display: none;
}

.lane-matchup.active {
    display: block;
}

/* Matchup Header */
.matchup-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-xl);
    background: rgba(30, 35, 50, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    margin-bottom: var(--spacing-lg);
}

.matchup-player {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    flex: 1;
}

.matchup-player.blue {
    justify-content: flex-start;
}

.matchup-player.red {
    justify-content: flex-end;
}

.player-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid rgba(255, 255, 255, 0.1);
}

.player-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.09);
}

.player-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.matchup-player.blue .player-details {
    align-items: flex-start;
}

.matchup-player.red .player-details {
    align-items: flex-end;
}

.player-champion {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
}

.player-name {
    font-size: 14px;
    color: var(--text-muted);
}

/* VS Section - Reorganized */
.matchup-vs {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-md);
    padding: 0 var(--spacing-lg);
    flex: 1;
}

.matchup-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-md);
    width: 100%;
}

.time-buttons-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-sm);
}

.vs-label {
    font-size: 12px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.time-buttons {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.content-type-tab {
    background: rgba(30, 35, 50, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 12px 20px;
    color: var(--text-muted);
    font-family: var(--font-family);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    text-transform: uppercase;
    height: 46px;
    display: flex;
    align-items: center;
}

.content-type-tab:hover {
    background: rgba(30, 35, 50, 0.8);
    border-color: rgba(255, 255, 255, 0.2);
    color: var(--text-primary);
}

.content-type-tab.active {
    background: rgba(239, 68, 68, 0.2);
    border-color: #ef4444;
    color: #ef4444;
    font-weight: 700;
}

.time-btn {
    background: rgba(30, 35, 50, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 8px 16px;
    color: var(--text-muted);
    font-family: var(--font-family);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    text-transform: uppercase;
}

.time-btn:hover {
    background: rgba(30, 35, 50, 0.8);
    border-color: rgba(255, 255, 255, 0.2);
    color: var(--text-primary);
}

.time-btn.active {
    background: rgba(239, 68, 68, 0.2);
    border-color: #ef4444;
    color: #ef4444;
    font-weight: 700;
}

.vs-time {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
}



/* Matchup Stats */
.matchup-stats {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xl);
}

/* Time Slider */
.time-slider-container {
    background: rgba(30, 35, 50, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: var(--spacing-lg);
}

.time-slider-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-md);
}

.time-slider-label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.time-slider-value {
    font-size: 14px;
    font-weight: 700;
    color: #ef4444;
}

.time-slider {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.1);
    outline: none;
    -webkit-appearance: none;
    margin: var(--spacing-sm) 0;
}

.time-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #ef4444;
    cursor: pointer;
    transition: all 0.2s;
}

.time-slider::-webkit-slider-thumb:hover {
    background: #dc2626;
    transform: scale(1.1);
}

.time-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #ef4444;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}

.time-slider::-moz-range-thumb:hover {
    background: #dc2626;
    transform: scale(1.1);
}

.time-slider-marks {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--text-muted);
    margin-top: var(--spacing-sm);
}

/* Stats Grid */
.stats-grid {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.stat-comparison {
    background: rgba(30, 35, 50, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    padding: var(--spacing-md);
}

.stat-top-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-sm);
    gap: var(--spacing-md);
}

.stat-label-center {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    flex: 1;
    text-align: center;
}

.stat-left-group,
.stat-right-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.stat-value-box {
    font-size: 13px;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 6px;
    white-space: nowrap;
}

.stat-value-box.blue-bg {
    background: rgba(96, 165, 250, 0.2);
    color: #60a5fa;
}

.stat-value-box.red-bg {
    background: rgba(248, 113, 113, 0.2);
    color: #f87171;
}

.stat-value-box.left {
    margin-right: auto;
}

.stat-value-box.right {
    margin-left: auto;
}

.stat-bar {
    width: 100%;
    height: 20px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    position: relative;
}

.stat-bar-fill {
    height: 100%;
    transition: width 0.3s ease;
}

.stat-bar-fill.blue {
    background: linear-gradient(90deg, #4a90e2, #60a5fa);
}

.stat-bar-fill.red {
    background: linear-gradient(90deg, #f87171, #e74c3c);
}

.stat-diff {
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    margin-top: var(--spacing-sm);
}

.stat-diff.blue-ahead {
    color: #60a5fa;
}

.stat-diff.red-ahead {
    color: #f87171;
}


/* Stat Advantage Badge - same style as stat-value-box but gray */
.stat-advantage-badge {
    font-size: 13px;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 6px;
    white-space: nowrap;
    background: rgba(107, 114, 128, 0.2);
    color: #9ca3af;
}


/* Stat Advantage Badge - same style as stat-value-box but gray */
.stat-advantage-badge {
    font-size: 13px;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 6px;
    white-space: nowrap;
    background: rgba(107, 114, 128, 0.2);
    color: #9ca3af;
}

/* Content Panels System */
.matchup-content {
    margin-top: var(--spacing-lg);
}

.content-panel {
    display: none;
}

.content-panel.active {
    display: block;
}

/* Rating Comparison Styles */
.rating-grid {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.rating-comparison {
    background: rgba(30, 35, 50, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    padding: var(--spacing-md);
}

.rating-top-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-sm);
    gap: var(--spacing-md);
}

.rating-label-center {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    flex: 1;
    text-align: center;
}

.rating-bar {
    width: 100%;
    height: 20px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    position: relative;
    justify-content: center;
}

.rating-bar-fill {
    height: 100%;
    transition: width 0.3s ease;
}

.rating-bar-fill.blue {
    background: linear-gradient(90deg, #4a90e2, #60a5fa);
    /* Blue bar extends from center to left */
    order: -1;
    border-radius: 10px 0 0 10px;
    /* Rounded left corners only */
}

.rating-bar-fill.red {
    background: linear-gradient(90deg, #f87171, #e74c3c);
    /* Red bar extends from center to right */
    border-radius: 0 10px 10px 0;
    /* Rounded right corners only */
}

.rating-loading {
    text-align: center;
    padding: var(--spacing-2xl);
    color: var(--text-muted);
    font-size: 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-md);
}

.rating-loading .spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top-color: #ef4444;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Timeline Slider Container */
.timeline-slider-container {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 16px;
    max-width: 600px;
    /* Wider slider */
}

/* Play/Pause Button */
.timeline-play-btn {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border: none;
    background: rgba(239, 68, 68, 0.1);
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ef4444;
    transition: all 0.2s;
}

.timeline-play-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    transform: scale(1.05);
}

.timeline-play-btn.playing {
    background: rgba(239, 68, 68, 0.15);
}

/* Slider Wrapper */
.timeline-slider-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column-reverse;
    /* Slider on bottom, display on top */
    gap: 8px;
}

/* Value Display */
.timeline-value-display {
    font-size: 14px;
    color: var(--text-muted);
    text-align: center;
    /* Center the minute display */
}

.timeline-minute {
    color: #fff;
    font-weight: 600;
    font-size: 15px;
}

/* Timeline Slider */
.timeline-slider {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 3px;
    outline: none;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
}

.timeline-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    background: #ef4444;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.4);
}

.timeline-slider::-webkit-slider-thumb:hover {
    transform: scale(1.15);
    box-shadow: 0 3px 10px rgba(239, 68, 68, 0.6);
}

.timeline-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    background: #ef4444;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.4);
}

.timeline-slider::-moz-range-thumb:hover {
    transform: scale(1.15);
    box-shadow: 0 3px 10px rgba(239, 68, 68, 0.6);
}

/* Expandable Stat Sections */
.stat-label-center-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: center;
}

.expand-arrow {
    color: var(--text-muted);
    transition: transform 0.3s ease, color 0.2s;
    flex-shrink: 0;
}

.stat-top-row.clickable {
    cursor: pointer;
}

.stat-top-row.clickable:hover .expand-arrow {
    color: #ef4444;
}

.stat-chart-container {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
    margin-top: 0;
}

.stat-comparison.expanded .stat-chart-container {
    max-height: 300px;
    margin-top: var(--spacing-md);
}

.stat-chart {
    padding: var(--spacing-md);
    background: rgba(30, 35, 50, 0.4);
    border-radius: 8px;
    min-height: 250px;
}

/* Timeline Pre-fetch Progress Overlay */
.timeline-prefetch-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #0f1423;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    transition: opacity 0.3s;
}

/* Make laning panel relative for overlay positioning */
[data-tab-panel="laning"] {
    position: relative;
    min-height: 400px;
}

.timeline-prefetch-content {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-md);
}

.timeline-prefetch-text {
    color: var(--text-primary);
    font-size: 16px;
    font-weight: 500;
}

.timeline-prefetch-progress {
    width: 300px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #ef4444, #f97316);
    transition: width 0.3s ease;
    border-radius: 4px;
}

.progress-text {
    color: var(--text-muted);
    font-size: 14px;
    text-align: center;
}

/* Expandable Stat Sections */
.stat-label-center-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: center;
}

.expand-arrow {
    color: var(--text-muted);
    transition: transform 0.3s ease, color 0.2s;
    flex-shrink: 0;
}

.stat-top-row.clickable {
    cursor: pointer;
}

.stat-top-row.clickable:hover .expand-arrow {
    color: #ef4444;
}

.stat-chart-container {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
    margin-top: 0;
}

.stat-comparison.expanded .stat-chart-container {
    max-height: 300px;
    margin-top: var(--spacing-md);
}

.stat-chart {
    padding: var(--spacing-md);
    background: rgba(30, 35, 50, 0.4);
    border-radius: 8px;
    min-height: 250px;
}

/* Expandable Stat Sections */
.stat-label-center-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: center;
}

.expand-arrow {
    color: var(--text-muted);
    transition: transform 0.3s ease, color 0.2s;
    flex-shrink: 0;
}

.stat-top-row.clickable {
    cursor: pointer;
}

.stat-top-row.clickable:hover .expand-arrow {
    color: #ef4444;
}

.stat-chart-container {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
    margin-top: 0;
}

.stat-comparison.expanded .stat-chart-container {
    max-height: 300px;
    margin-top: var(--spacing-md);
}

.stat-chart {
    padding: var(--spacing-md);
    background: rgba(30, 35, 50, 0.4);
    border-radius: 8px;
    min-height: 250px;
}

/* Expandable Stat Sections */
.stat-label-center-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: center;
}

.expand-arrow {
    color: var(--text-muted);
    transition: transform 0.3s ease, color 0.2s;
    flex-shrink: 0;
}

.stat-top-row.clickable {
    cursor: pointer;
}

.stat-top-row.clickable:hover .expand-arrow {
    color: #ef4444;
}

.stat-chart-container {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
    margin-top: 0;
}

.stat-comparison.expanded .stat-chart-container {
    max-height: 300px;
    margin-top: var(--spacing-md);
}

.stat-chart {
    padding: var(--spacing-md);
    background: rgba(30, 35, 50, 0.4);
    border-radius: 8px;
    min-height: 250px;
}