/* AG Carrosserie - Styles personnalisés */


/* Général */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    overflow-x: hidden;
}


/* Navigation */

.nav-link {
    @apply text-gray-700 hover: text-primary font-medium transition duration-200 relative;
}

.nav-link.active {
    @apply text-primary font-semibold;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: currentColor;
}


/* Animations */

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

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

@keyframes pulse {
    0%,
    100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

.slide-in-right {
    animation: slideInRight 0.6s ease-out;
}


/* Boutons */

button,
.btn {
    transition: all 0.3s ease;
}

button:hover,
.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

button:active,
.btn:active {
    transform: translateY(0);
}


/* Cards */

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

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


/* Images */

img {
    max-width: 100%;
    height: auto;
}


/* Smooth scrolling */

html {
    scroll-behavior: smooth;
}


/* Back to top button */

#back-to-top {
    transition: all 0.3s ease;
}

#back-to-top.visible {
    opacity: 1 !important;
    visibility: visible !important;
}


/* Forms */

input:focus,
textarea:focus,
select:focus {
    outline: none;
}

input[type="file"] {
    cursor: pointer;
}


/* Loading spinner */

.spinner {
    border: 3px solid rgba(0, 0, 0, 0.1);
    border-left-color: #1e40af;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}


/* Tooltips */

[data-tooltip] {
    position: relative;
}

[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}

[data-tooltip]:hover::after {
    opacity: 1;
}


/* Responsive adjustments */

@media (max-width: 768px) {
    .nav-link::after {
        display: none;
    }
}


/* Print styles */

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


/* Custom scrollbar */

::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #1e40af;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #1e3a8a;
}


/* Galerie - Effet hover avant/après */

.avant-image,
.apres-image {
    transition: opacity 0.5s ease;
}


/* Admin styles */

.admin-sidebar {
    transition: transform 0.3s ease;
}

.admin-sidebar.hidden {
    transform: translateX(-100%);
}

@media (max-width: 1024px) {
    .admin-sidebar {
        position: fixed;
        left: 0;
        top: 0;
        height: 100vh;
        z-index: 1000;
        background: white;
        transform: translateX(-100%);
    }
    .admin-sidebar.visible {
        transform: translateX(0);
    }
}


/* Badge status */

.badge {
    @apply inline-block px-3 py-1 rounded-full text-xs font-semibold;
}

.badge-nouveau {
    @apply bg-blue-100 text-blue-800;
}

.badge-en-cours {
    @apply bg-yellow-100 text-yellow-800;
}

.badge-traite {
    @apply bg-green-100 text-green-800;
}

.badge-refuse {
    @apply bg-red-100 text-red-800;
}

.badge-lu {
    @apply bg-gray-100 text-gray-800;
}


/* Table responsive */

@media (max-width: 768px) {
    .table-responsive {
        overflow-x: auto;
    }
    .table-responsive table {
        min-width: 600px;
    }
}


/* Utility classes */

.text-shadow {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.box-shadow-lg {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.glass-effect {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}


/* Gradient text */

.gradient-text {
    background: linear-gradient(to right, #1e40af, #dc2626);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}