/* ============================================
   TIMELINE SLIDER
   ============================================ */

.timeline-container {
    background: white;
    padding: 20px 20px 20px 20px;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.timeline-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0px;
}

.date-range {
    font-size: 18px;
    font-weight: bold;
    color: #667eea;
}

.race-count {
    background: #667eea;
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 14px;
}

/* Preset duration buttons */
.preset-buttons {
    display: flex;
    gap: 8px;
    margin-bottom: 15px;
    align-items: center;
}

.preset-btn {
    padding: 6px 12px;
    border: 2px solid rgba(102, 126, 234, 0.3);
    background: rgba(255,255,255,0.95);
    color: #667eea;
    border-radius: 16px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    transition: all 0.2s;
}

.preset-btn:hover {
    background: white;
    border-color: #667eea;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(102, 126, 234, 0.2);
}

.preset-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: #667eea;
}

/* Timeline slider track and handle */
.timeline-slider {
    position: relative;
    height: 50px;
    margin-bottom: 5px;
    padding: 0 12px;
}

.timeline-track {
    position: absolute;
    top: 20px;
    left: 12px;
    right: 12px;
    height: 8px;
    background: linear-gradient(to right, #e8e8e8, #d0d0d0);
    border-radius: 4px;
    border: 1px solid #c0c0c0;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.1);
    z-index: 0;
}

.range-highlight {
    position: absolute;
    top: 20px;
    height: 8px;
    background: linear-gradient(to right, rgba(102, 126, 234, 0.5), rgba(118, 75, 162, 0.5));
    border-radius: 4px;
    pointer-events: none;
    transition: left 0.1s ease, width 0.1s ease;
    border: 1px solid rgba(102, 126, 234, 0.6);
    z-index: 1;
}

.slider-input {
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    width: calc(100% - 24px);
    margin: 0 12px;
    height: 8px;
    -webkit-appearance: none;
    appearance: none;
    background: transparent;
    border-radius: 4px;
    outline: none;
    cursor: pointer;
    z-index: 2;
}

.slider-input::-webkit-slider-track {
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
}

.slider-input::-moz-range-track {
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
}

.slider-input::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    background: white;
    border: 3px solid #667eea;
    border-radius: 50%;
    cursor: grab;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
    transition: transform 0.2s;
}

.slider-input::-webkit-slider-thumb:hover {
    transform: scale(1.15);
    border-width: 4px;
}

.slider-input::-webkit-slider-thumb:active {
    cursor: grabbing;
    transform: scale(1.1);
}

.slider-input::-moz-range-thumb {
    width: 24px;
    height: 24px;
    background: white;
    border: 3px solid #667eea;
    border-radius: 50%;
    cursor: grab;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
    transition: transform 0.2s;
}

.slider-input::-moz-range-thumb:hover {
    transform: scale(1.15);
    border-width: 4px;
}

.slider-input::-moz-range-thumb:active {
    cursor: grabbing;
}

/* Month labels */
.month-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
    padding: 0 12px;
    font-size: 12px;
    color: #666;
    position: relative;
    min-height: 20px;
}

.month-labels span {
    white-space: nowrap;
}
