/**
 * AG Carrosserie - Styles personnalisés
 * 
 * Note: Ce fichier complète TailwindCSS (chargé via CDN)
 * On garde ici uniquement les personnalisations spécifiques
 */


/* =====================================================
   VARIABLES CSS
===================================================== */

:root {
    --color-primary: #1e3a5f;
    --color-secondary: #e53935;
    --color-accent: #f5c518;
    --color-dark: #1a1a2e;
    --color-gray: #f8f9fa;
}


/* =====================================================
   TYPOGRAPHIE
===================================================== */

body {
    font-family: 'Poppins', system-ui, -apple-system, sans-serif;
    line-height: 1.6;
}


/* =====================================================
   NAVIGATION
===================================================== */

.nav-link {
    position: relative;
    transition: color 0.2s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-secondary);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}


/* Menu mobile */

.mobile-menu {
    transform: translateX(-100%);
    transition: transform 0.3s ease;
}

.mobile-menu.open {
    transform: translateX(0);
}


/* =====================================================
   HERO
===================================================== */

.hero-gradient {
    background: linear-gradient(135deg, var(--color-primary) 0%, #2d5a87 100%);
}

.hero-overlay {
    background: linear-gradient(to right, rgba(30, 58, 95, 0.95) 0%, rgba(30, 58, 95, 0.7) 100%);
}


/* =====================================================
   CARTES
===================================================== */

.card-hover {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}


/* Service cards */

.service-card {
    transition: all 0.3s ease;
}

.service-card:hover {
    transform: scale(1.03);
}

.service-card:hover .service-icon {
    transform: scale(1.1);
}

.service-icon {
    transition: transform 0.3s ease;
}


/* =====================================================
   GALERIE
===================================================== */

.gallery-item {
    overflow: hidden;
}

.gallery-item img {
    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-overlay {
    opacity: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, transparent 100%);
    transition: opacity 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}


/* Lightbox */

.lightbox {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.lightbox.open {
    opacity: 1;
    pointer-events: auto;
}


/* Filtres galerie */

.filter-btn {
    transition: all 0.2s ease;
}

.filter-btn.active {
    background-color: var(--color-primary);
    color: white;
}


/* =====================================================
   VÉHICULES
===================================================== */

.vehicle-card {
    transition: all 0.3s ease;
}

.vehicle-card:hover {
    transform: translateY(-5px);
}

.vehicle-badge {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%,
    100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}


/* Prix */

.price-tag {
    clip-path: polygon(0 0, 100% 0, 100% 80%, 50% 100%, 0 80%);
}


/* =====================================================
   FORMULAIRES
===================================================== */

.form-input {
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-input:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(30, 58, 95, 0.1);
    outline: none;
}

.form-input.error {
    border-color: #ef4444;
}


/* Upload zone */

.upload-zone {
    border: 2px dashed #cbd5e1;
    transition: all 0.2s ease;
}

.upload-zone:hover,
.upload-zone.dragover {
    border-color: var(--color-primary);
    background-color: #f1f5f9;
}


/* =====================================================
   BOUTONS
===================================================== */

.btn {
    transition: all 0.2s ease;
}

.btn:active {
    transform: scale(0.98);
}

.btn-primary {
    background-color: var(--color-primary);
}

.btn-primary:hover {
    background-color: #2d5a87;
}

.btn-secondary {
    background-color: var(--color-secondary);
}

.btn-secondary:hover {
    background-color: #c62828;
}


/* =====================================================
   FAQ ACCORDION
===================================================== */

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-item.open .faq-answer {
    max-height: 500px;
}

.faq-toggle-icon {
    transition: transform 0.3s ease;
}

.faq-item.open .faq-toggle-icon {
    transform: rotate(180deg);
}


/* =====================================================
   ANIMATIONS
===================================================== */

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

.fade-in {
    animation: fadeIn 0.6s ease forwards;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.slide-in {
    animation: slideIn 0.4s ease forwards;
}


/* Scroll animations */

[data-animate] {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

[data-animate].visible {
    opacity: 1;
    transform: translateY(0);
}


/* =====================================================
   LOADER
===================================================== */

.loader {
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--color-primary);
    border-radius: 50%;
    width: 24px;
    height: 24px;
    animation: spin 1s linear infinite;
}

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


/* =====================================================
   SCROLL TO TOP
===================================================== */

.scroll-to-top {
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

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


/* =====================================================
   UTILITAIRES
===================================================== */

.text-balance {
    text-wrap: balance;
}

.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}


/* =====================================================
   RESPONSIVE
===================================================== */

@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }
    .section-title {
        font-size: 1.75rem;
    }
}


/* =====================================================
   PRINT
===================================================== */

@media print {
    .no-print {
        display: none !important;
    }
    body {
        font-size: 12pt;
    }
    a[href]:after {
        content: " (" attr(href) ")";
    }
}