.tab-content {
    padding-top: 1rem;
}

.tab-content.active {
    display: block !important;
}

.nav-link {
    cursor: pointer;
}

.nav-link.active {
    background-color: #0d6efd !important;
    color: white !important;
}

.race-status-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.25rem 0;
    border-bottom: 1px solid #dee2e6;
}

.race-status-item:last-child {
    border-bottom: none;
}

.status-label {
    font-weight: 500;
}

.status-value {
    color: #6c757d;
}

.status-value.success {
    color: #198754;
}

.status-value.warning {
    color: #ffc107;
}

.status-value.danger {
    color: #dc3545;
}

.table th {
    position: sticky;
    top: 0;
    background-color: white;
    z-index: 10;
}

.crew-sequence {
    font-weight: bold;
    color: #0d6efd;
}

.crew-status {
    font-size: 0.875rem;
}

.crew-status.accepted {
    color: #198754;
}

.crew-status.submitted {
    color: #ffc107;
}

.crew-status.withdrawn {
    color: #dc3545;
}

.event-count {
    font-weight: bold;
}

.loading-spinner {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.btn:disabled {
    opacity: 0.6;
}

.sortable {
    cursor: pointer;
    user-select: none;
    position: relative;
}

.sortable:hover {
    background-color: #f8f9fa;
}

.sort-arrow {
    margin-left: 0.5rem;
    font-size: 0.8rem;
    opacity: 0.3;
}

.sortable.sort-asc .sort-arrow::after {
    content: "▲";
    opacity: 1;
}

.sortable.sort-desc .sort-arrow::after {
    content: "▼";
    opacity: 1;
}

/* Event status highlighting */
.table-danger {
    background-color: #f8d7da !important;
    border-color: #dc3545;
}

.table-warning {
    background-color: #fff3cd !important;
    border-color: #ffc107;
}

.table-success {
    background-color: #d1e7dd !important;
    border-color: #198754;
}

/* Ensure text remains readable */
.table-danger td,
.table-warning td,
.table-success td {
    font-weight: 500;
}

.event-count {
    font-weight: bold;
    font-size: 1.1rem;
}

/* Clickable stat links */
.stat-link {
    text-decoration: none !important;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
}

.stat-link:link {
    text-decoration: none !important;
}

.stat-link:visited {
    text-decoration: none !important;
}

.stat-link:hover {
    text-decoration: none !important;
    transform: scale(1.05);
}

.stat-link:active {
    text-decoration: none !important;
}

.stat-link:focus {
    text-decoration: none !important;
}

/* Maintain Bootstrap color classes for stat links */
.stat-link.text-success:hover {
    color: #0a5d3a !important;
}

.stat-link.text-warning:hover {
    color: #997404 !important;
}

.stat-link.text-info:hover {
    color: #055160 !important;
}

.stat-link.text-secondary:hover {
    color: #3d4142 !important;
}

.stat-link.text-danger:hover {
    color: #842029 !important;
}

/* Default stat link hover for uncolored links */
.stat-link:not([class*="text-"]):hover {
    color: #0a58ca !important;
}