/* Variables */
:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --accent-color: #ffc107;
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --success-color: #198754;
    --info-color: #0dcaf0;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --primary-gradient: linear-gradient(135deg, #0d6efd 0%, #0a58ca 100%);
    --box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

/* Global Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--dark-color);
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-color);
    text-decoration: underline;
}

.btn {
    font-weight: 600;
    padding: 12px 24px;
    border-radius: 50px;
    transition: var(--transition);
}

.btn-primary {
    background: var(--primary-gradient);
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #0a58ca 0%, #0a4ca0 100%);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(13, 110, 253, 0.3);
}

.btn-outline-light:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

/* Navigation */
.navbar {
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    transition: var(--transition);
    padding: 15px 0;
}

.navbar.scrolled {
    padding: 10px 0;
    background-color: rgba(0, 0, 0, 0.9);
}

.navbar-brand img {
    transition: var(--transition);
}

.navbar.scrolled .navbar-brand img {
    height: 30px;
}

.nav-link {
    font-weight: 500;
    margin: 0 10px;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 50%;
    background-color: var(--primary-color);
    transition: var(--transition);
}

.nav-link:hover::after, .nav-link.active::after {
    width: 80%;
    left: 10%;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('../images/hero/main-hero.jpg') center/cover no-repeat;
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(13, 110, 253, 0.8) 0%, rgba(10, 88, 202, 0.8) 100%);
    opacity: 0.7;
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-text {
    animation: fadeInUp 1s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-features i {
    font-size: 1.2rem;
}

/* Booking Widget */
.booking-widget {
    position: relative;
    z-index: 2;
    animation: fadeInRight 1s ease;
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.booking-header {
    border-top-left-radius: 15px;
    border-top-right-radius: 15px;
}

.booking-body {
    border-bottom-left-radius: 15px;
    border-bottom-right-radius: 15px;
}

.vehicle-options {
    display: flex;
    gap: 15px;
    margin-top: 10px;
}

.vehicle-option {
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
}

.vehicle-option img {
    height: 80px;
    width: auto;
    border-radius: 8px;
    margin-bottom: 5px;
    border: 2px solid transparent;
    transition: var(--transition);
}

.form-check-input:checked + .form-check-label .vehicle-option img {
    border-color: var(--primary-color);
}

.vehicle-option span {
    display: block;
    font-size: 0.9rem;
}

/* Services Section */
.service-card {
    border: none;
    border-radius: 15px;
    overflow: hidden; /* <-- CRUCIAL : Assure que rien ne dépasse de la carte, même l'image zoomée */
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column; /* Assure un bon alignement des éléments internes */
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--box-shadow);
}

.service-card .card-img-top {
    height: 200px;
    width: 100%;
    object-fit: cover;
    transition: transform 0.4s ease-in-out; /* Animation plus douce pour l'image */
    will-change: transform; /* Optimisation pour l'animation */
}

.service-card:hover .card-img-top {
    transform: scale(1.05); /* Le zoom est maintenant contenu dans la carte */
}

.service-card .card-body {
    flex-grow: 1; /* Permet au corps de la carte de remplir l'espace restant */
    display: flex;
    flex-direction: column;
}

.service-icon {
    width: 60px;
    height: 60px;
    background: var(--primary-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    margin-bottom: 15px;
    flex-shrink: 0; /* Empêche l'icône de rétrécir si le contenu est grand */
}

.service-card .card-title {
    margin-bottom: 1rem;
}

.service-card .card-text {
    flex-grow: 1; /* Fait en sorte que le texte prenne de la place, poussant le bouton vers le bas */
}

.service-card .btn {
    margin-top: auto; /* Pousse le bouton vers le bas de la carte */
    align-self: flex-start; /* Aligne le bouton à gauche */
}

/* Pricing Section */
.pricing-card {
    border: none;
    border-radius: 15px;
    overflow: hidden;
    transition: var(--transition);
    height: 100%;
    position: relative;
}

.pricing-card.featured {
    transform: scale(1.05);
    box-shadow: 0 15px 30px rgba(13, 110, 253, 0.2);
}

.pricing-card.featured::before {
    content: 'POPULAIRE';
    position: absolute;
    top: 20px;
    right: -30px;
    background: var(--accent-color);
    color: var(--dark-color);
    padding: 5px 40px;
    transform: rotate(45deg);
    font-size: 0.7rem;
    font-weight: 700;
    z-index: 1;
}

.pricing-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--box-shadow);
}

.pricing-header {
    background: var(--primary-gradient);
    color: white;
    padding: 30px 20px;
    text-align: center;
}

.pricing-price {
    font-size: 3rem;
    font-weight: 700;
}

.pricing-price span {
    font-size: 1rem;
    font-weight: 400;
}

.pricing-body {
    padding: 30px 20px;
}

.pricing-features {
    list-style: none;
    padding: 0;
    margin-bottom: 30px;
}

.pricing-features li {
    padding: 10px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.pricing-features li:last-child {
    border-bottom: none;
}

.pricing-features i {
    color: var(--success-color);
    margin-right: 10px;
}

/* Testimonials Section */
.testimonial-card {
    border: none;
    border-radius: 15px;
    padding: 30px;
    box-shadow: var(--box-shadow);
    height: 100%;
    position: relative;
}

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: 20px;
    left: 20px;
    font-size: 4rem;
    color: rgba(13, 110, 253, 0.1);
    font-family: Georgia, serif;
}

.testimonial-content {
    position: relative;
    z-index: 1;
    margin-bottom: 20px;
}

.testimonial-author {
    display: flex;
    align-items: center;
}

.testimonial-author img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    margin-right: 15px;
}

.testimonial-author .author-info h5 {
    margin-bottom: 0;
}

.testimonial-author .author-info .rating {
    color: var(--accent-color);
}

/* About Section */
.stat-item {
    text-align: center;
    padding: 20px;
}

/* Contact Section */
.contact-info {
    background: var(--primary-gradient);
    color: white;
    border-radius: 15px;
    padding: 30px;
    height: 100%;
}

.contact-info-item {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.contact-info-item:last-child {
    margin-bottom: 0;
}

.contact-info-item i {
    font-size: 1.5rem;
    margin-right: 15px;
}

/* FAQ Section */
.accordion-button:not(.collapsed) {
    background-color: rgba(13, 110, 253, 0.1);
    color: var(--primary-color);
}

.accordion-button:focus {
    box-shadow: none;
    border-color: rgba(0, 0, 0, 0.125);
}

/* Footer */
footer {
    background: linear-gradient(135deg, #212529 0%, #000000 100%);
}

footer a:hover {
    color: var(--primary-color);
    text-decoration: none;
}

.social-links a {
    display: inline-block;
    width: 40px;
    height: 40px;
    line-height: 40px;
    text-align: center;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    margin-right: 10px;
    transition: var(--transition);
}

.social-links a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

/* Sticky Booking Widget */
.sticky-booking-widget {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: var(--primary-gradient);
    color: white;
    padding: 15px 0;
    z-index: 1000;
    box-shadow: 0 -5px 15px rgba(0, 0, 0, 0.1);
    display: none;
    transform: translateY(100%);
    transition: var(--transition);
}

.sticky-booking-widget.show {
    transform: translateY(0);
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--primary-gradient);
    color: white;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(13, 110, 253, 0.3);
}

/* Animations */
.animate-in {
    animation: fadeInUp 0.6s ease forwards;
    opacity: 0;
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Focus styles for accessibility */
.btn:focus,
.form-control:focus,
.nav-link:focus {
    outline: 2px solid var(--accent-color);
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #0000ff;
        --accent-color: #ffff00;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Print styles */
@media print {
    .navbar,
    .sticky-booking-widget,
    .back-to-top,
    .btn {
        display: none !important;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.5;
    }
    
    h1, h2, h3 {
        page-break-after: avoid;
    }
    
    .service-card,
    .pricing-card,
    .testimonial-card {
        break-inside: avoid;
    }
}