/* ============================================
   Le Maître Barbier - Styles complémentaires
   ============================================ */

/* Scrollbar personnalisée */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #f1f1f1; }
::-webkit-scrollbar-thumb { background: #758661; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #5c6c4c; }

/* Effet parallax */
.parallax {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

@media (max-width: 768px) {
    .parallax {
        background-attachment: scroll;
    }
}

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

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

.animate-fade-in {
    animation: fadeIn 0.4s ease-out forwards;
}

.animate-slide-down {
    animation: slideDown 0.3s ease-out forwards;
}

/* Délais d'animation pour les éléments en séquence */
.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }

/* Toast / Notification */
.toast {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    padding: 1rem 1.5rem;
    border-radius: 0.5rem;
    color: #fff;
    font-size: 0.875rem;
    font-weight: 500;
    z-index: 9999;
    animation: slideUp 0.3s ease-out, fadeOut 0.3s ease-in 3.7s forwards;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    max-width: 400px;
}

.toast-success { background-color: #48543d; }
.toast-error { background-color: #dc2626; }
.toast-info { background-color: #2d3b2e; }

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

@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

/* Spinner de chargement */
.spinner {
    display: inline-block;
    width: 2rem;
    height: 2rem;
    border: 3px solid #ccd2c2;
    border-top-color: #5c6c4c;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* Bouton désactivé */
button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Fix select sur mobile */
select {
    -webkit-appearance: menulist;
    appearance: menulist;
    font-size: 16px; /* Empêche le zoom auto sur iOS */
}

/* Focus visible pour accessibilité */
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid #758661;
    outline-offset: 2px;
}

/* Transition douce sur les liens de navigation */
nav a {
    position: relative;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background-color: #5c6c4c;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

nav a:hover::after {
    width: 80%;
}

/* Style des cartes de services */
.service-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

/* Style pour les items de prestation */
.service-item {
    transition: background-color 0.2s ease;
    padding: 0.5rem;
    border-radius: 0.375rem;
}

.service-item:hover {
    background-color: #f5f7f2;
}

/* Overlay pour les modals */
.modal-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.2s ease-out;
}

.modal-content {
    background: white;
    border-radius: 1rem;
    padding: 2rem;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    animation: fadeInUp 0.3s ease-out;
}
