
.races-container {
    background: linear-gradient(135deg, var(--bs-gray-50) 0%, var(--bs-body-bg) 100%);
    min-height: 90vh;
    padding: 3rem 0;
}

.races-header {
    text-align: center;
    margin-bottom: 3rem;
}

.races-icon {
    font-size: 3rem;
    color: #D10000;
    margin-bottom: 1rem;
    animation: heartbeat 2s ease-in-out infinite;
}

@keyframes heartbeat {
    0%, 50%, 100% { transform: scale(1); }
    25%, 75% { transform: scale(1.1); }
}

.races-title {
    color: var(--bs-body-color);
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.races-subtitle {
    color: var(--bs-secondary-color);
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto;
}

.races-filters {
    margin-bottom: 3rem;
}

.search-box {
    position: relative;
    max-width: 500px;
    margin: 0 auto;
}

.search-box i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--bs-secondary-color);
    z-index: 2;
}

.search-box .form-control {
    padding-left: 3rem;
    border-radius: 25px;
    border: 2px solid var(--bs-border-color);
    transition: all 0.3s ease;
}

.search-box .form-control:focus {
    border-color: #0047FF;
    box-shadow: 0 0 0 0.2rem rgba(0, 71, 255, 0.25);
}

.races-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.race-card {
    background: var(--bs-body-bg);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    border: 1px solid var(--bs-border-color);
    transition: all 0.4s ease;
    position: relative;
}

.race-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.race-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(135deg, #0047FF 0%, #D10000 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.race-card:hover::before {
    opacity: 1;
}

.race-image {
    position: relative;
    height: 250px;
    overflow: hidden;
}

.race-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.race-card:hover .race-image img {
    transform: scale(1.05);
}

.race-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 71, 255, 0.8) 0%, rgba(209, 0, 0, 0.8) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.race-card:hover .race-overlay {
    opacity: 1;
}

.race-btn {
    border-radius: 25px;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    border: 2px solid white;
    background: white;
    color: #0047FF;
    text-decoration: none;
    transition: all 0.3s ease;
}

.race-btn:hover {
    background: transparent;
    color: white;
    border-color: white;
    text-decoration: none;
}

.race-content {
    padding: 1.5rem;
}

.race-name {
    color: var(--bs-body-color);
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.race-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.race-category,
.race-status {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.85rem;
    font-weight: 500;
}

.race-category {
    background: rgba(0, 71, 255, 0.1);
    color: #0047FF;
    border: 1px solid rgba(0, 71, 255, 0.2);
}

.race-status.active {
    background: rgba(40, 167, 69, 0.1);
    color: #28a745;
    border: 1px solid rgba(40, 167, 69, 0.2);
}

.race-status.upcoming {
    background: rgba(255, 193, 7, 0.1);
    color: #ffc107;
    border: 1px solid rgba(255, 193, 7, 0.2);
}

.race-description {
    color: var(--bs-secondary-color);
    line-height: 1.6;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.race-characteristics {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.characteristic {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--bs-secondary-color);
    font-size: 0.9rem;
}

.characteristic i {
    color: #D10000;
    font-size: 1rem;
}

/* Carte "Bientôt disponible" */
.race-card.coming-soon {
    border: 2px dashed var(--bs-border-color);
    background: rgba(var(--bs-secondary-color), 0.05);
}

.coming-soon-placeholder {
    height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(0, 71, 255, 0.1) 0%, rgba(209, 0, 0, 0.1) 100%);
}

.coming-soon-placeholder i {
    font-size: 4rem;
    color: var(--bs-secondary-color);
    opacity: 0.5;
}

.race-action {
    margin-top: 1rem;
}

/* Mode sombre */
[data-bs-theme="dark"] .race-card {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

[data-bs-theme="dark"] .race-card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

[data-bs-theme="dark"] .search-box .form-control:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 71, 255, 0.4);
}

/* Responsive */
@media (max-width: 768px) {
    .races-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .races-title {
        font-size: 2rem;
    }
    
    .race-card {
        margin: 0 1rem;
    }
    
    .race-content {
        padding: 1rem;
    }
    
    .race-characteristics {
        flex-direction: column;
        gap: 0.5rem;
    }
}

@media (max-width: 480px) {
    .races-container {
        padding: 2rem 0;
    }
    
    .races-grid {
        gap: 1rem;
    }
    
    .race-card {
        margin: 0 0.5rem;
        border-radius: 15px;
    }
    
    .race-image {
        height: 200px;
    }
    
    .race-name {
        font-size: 1.2rem;
    }
    
    .race-meta {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .race-btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
}

/* Animation d'entrée */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.race-card {
    animation: fadeInUp 0.6s ease-out;
}

.race-card:nth-child(1) { animation-delay: 0.1s; }
.race-card:nth-child(2) { animation-delay: 0.2s; }
.race-card:nth-child(3) { animation-delay: 0.3s; }
.race-card:nth-child(4) { animation-delay: 0.4s; }
.race-card:nth-child(5) { animation-delay: 0.5s; }
.race-card:nth-child(6) { animation-delay: 0.6s; }