@charset "UTF-8";

/* ==============================================
   Race Table Common
   ============================================== */
.race-table-container {
    margin: 2em 0;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.race-table-info {
    width: 100%;
    border-collapse: collapse;
    min-width: 500px;
    /* Force scroll on small screens */
}

.race-table-info th,
.race-table-info td {
    padding: 12px 15px;
    border-bottom: 1px solid #eee;
    text-align: left;
    vertical-align: middle;
}

.race-table-info th {
    background-color: #f8f9fa;
    color: #333;
    font-weight: bold;
    border-bottom: 2px solid #ddd;
    white-space: nowrap;
}

.race-table-info tbody tr:last-child td {
    border-bottom: none;
}

.race-table-info tbody tr:hover {
    background-color: #fcfcfc;
}

/* ==============================================
   Race Matrix (Post-Event)
   ============================================== */
.race-matrix .active-race-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    background-color: #e9ecef;
    color: #495057;
    font-size: 0.85em;
    margin-right: 5px;
    margin-bottom: 2px;
    border: 1px solid #dee2e6;
}

/* Badge variants can be added dynamically or cyclically if needed */
.race-matrix .active-race-badge.is-primary {
    background-color: #cff4fc;
    color: #055160;
    border-color: #bcdff1;
}

.race-matrix .active-race-badge.is-secondary {
    background-color: #d1e7dd;
    color: #0f5132;
    border-color: #badbcc;
}

.weather-icon-text {
    /* Adjust if you add icons later */
}

/* Header Styling for Sections */
.race-section-title {
    margin-top: 0;
    margin-bottom: 0;
    padding: 15px 20px;
    background-color: #f0f8ff;
    border-bottom: 1px solid #cceeff;
    color: #005c99;
    font-size: 1.2em;
}

.race-schedule-section {
    border: 1px solid #cceeff;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 2em;
}

/* ==============================================
   Race Timeline
   ============================================== */
.race-timeline-section {
    margin-top: 2em;
}

.race-timeline-container {
    background: #fff;
    padding: 15px;
    border-radius: 5px;
    border: 1px solid #ddd;
}

.timeline-date-header {
    background: #f8f9fa;
    padding: 8px 15px;
    margin: 0 -15px 15px;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
    font-size: 1.1em;
    font-weight: bold;
    color: #333;
}

.timeline-date-header:first-child {
    margin-top: -15px;
    border-top: none;
    border-radius: 5px 5px 0 0;
}

.race-timeline {
    list-style: none;
    padding: 0;
    margin: 0;
    position: relative;
    padding-left: 20px;
    /* Adjust for line */
}

.race-timeline::before {
    content: '';
    position: absolute;
    top: 5px;
    bottom: 5px;
    left: 27px;
    /* 20px + 7px */
    width: 2px;
    background: #e9ecef;
}

.timeline-item {
    position: relative;
    padding-left: 30px;
    margin-bottom: 20px;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 1px;
    top: 5px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid #6c757d;
    z-index: 1;
}

.timeline-time {
    font-weight: bold;
    font-size: 1.1em;
    color: #495057;
    margin-bottom: 4px;
}

.timeline-content {
    background: #f8f9fa;
    padding: 10px 15px;
    border-radius: 4px;
    border: 1px solid #eee;
}

.timeline-title {
    font-weight: bold;
    color: #333;
}

.timeline-note {
    font-size: 0.85em;
    color: #666;
    margin-top: 4px;
}

/* Critical item emphasis */
.timeline-item.timeline-critical::before {
    border-color: #e03e2d;
    background: #e03e2d;
}

.timeline-item.timeline-critical .timeline-time {
    color: #e03e2d;
}

.timeline-item.timeline-critical .timeline-content {
    background: #fff0f0;
    border-color: #f5c6cb;
}

.timeline-item.timeline-critical .timeline-title {
    color: #c82333;
}