/* ============================================
   POULAIN TERRASSEMENT — Custom Styles
   DARK FUTURISTE — Glassmorphism + Glow
   Bleu #3b82f6 / Cyan #06b6d4
   Typo : Outfit (titres) + Rubik (corps)
   ============================================ */

/* --- Selection --- */
::selection {
    background: rgba(59, 130, 246, 0.3);
    color: #fff;
}

/* --- Glassmorphism --- */
.glass {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.glass-light {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

/* --- Animations fade-in --- */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger delays for siblings */
.fade-in:nth-child(1) { transition-delay: 0s; }
.fade-in:nth-child(2) { transition-delay: 0.1s; }
.fade-in:nth-child(3) { transition-delay: 0.2s; }
.fade-in:nth-child(4) { transition-delay: 0.3s; }
.fade-in:nth-child(5) { transition-delay: 0.4s; }
.fade-in:nth-child(6) { transition-delay: 0.5s; }

/* --- Hero overlay — dégradé futuriste --- */
.hero-overlay {
    background: linear-gradient(135deg, rgba(5, 5, 7, 0.92) 0%, rgba(9, 9, 11, 0.85) 40%, rgba(59, 130, 246, 0.15) 100%);
}

/* --- Pulse glow pour boutons --- */
@keyframes pulse-glow {
    0%, 100% { box-shadow: 0 0 20px rgba(59, 130, 246, 0.4), 0 0 40px rgba(59, 130, 246, 0.1); }
    50% { box-shadow: 0 0 30px rgba(59, 130, 246, 0.6), 0 0 60px rgba(59, 130, 246, 0.2); }
}

/* --- Bouton appel mobile pulse --- */
@keyframes pulse-call {
    0% { box-shadow: 0 0 15px rgba(59, 130, 246, 0.5); }
    50% { box-shadow: 0 0 30px rgba(59, 130, 246, 0.8), 0 0 50px rgba(6, 182, 212, 0.3); }
    100% { box-shadow: 0 0 15px rgba(59, 130, 246, 0.5); }
}

.mobile-call-btn {
    animation: pulse-call 2s infinite;
}

/* --- Card hover avec glow --- */
.card-hover {
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease, border-color 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(59, 130, 246, 0.15), 0 0 30px rgba(59, 130, 246, 0.08);
    border-color: rgba(59, 130, 246, 0.4);
}

/* --- Galerie hover effect --- */
.galerie-item img {
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.galerie-item:hover img {
    transform: scale(1.08);
}

.galerie-item .overlay-content {
    opacity: 0;
    transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.galerie-item:hover .overlay-content {
    opacity: 1;
}

/* --- Gradient border pseudo-element --- */
.gradient-border {
    position: relative;
}

.gradient-border::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.3), rgba(6, 182, 212, 0.3));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

/* --- Burger animation --- */
.burger-line {
    transition: all 0.3s ease;
}

.burger-active .burger-line:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.burger-active .burger-line:nth-child(2) {
    opacity: 0;
}

.burger-active .burger-line:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* --- Header scrolled --- */
.header-scrolled {
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5), 0 0 15px rgba(59, 130, 246, 0.05) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
}

/* --- Notification slide-in --- */
@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* --- Orbe lumineuse (fond décoratif) --- */
.orbe {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    opacity: 0.15;
}

/* --- Scroll-driven reveal (modern browsers) --- */
@supports (animation-timeline: view()) {
    .reveal-scroll {
        animation: revealScroll linear both;
        animation-timeline: view();
        animation-range: entry 0% entry 100%;
    }

    @keyframes revealScroll {
        from { opacity: 0; translate: 0 40px; }
        to { opacity: 1; translate: 0 0; }
    }
}

/* --- Respect reduced motion --- */
@media (prefers-reduced-motion: reduce) {
    .fade-in {
        opacity: 1;
        transform: none;
        transition: none;
    }
    .mobile-call-btn {
        animation: none;
    }
    .galerie-item img,
    .galerie-item .overlay-content,
    .card-hover {
        transition: none;
    }
}

/* --- Mobile : réduction des effets GPU --- */
@media (max-width: 768px) {
    .orbe {
        display: none;
    }
    .glass,
    .glass-light {
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
    }
}
