/* ======================= GLOBAL ======================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

::selection {
    background: #1e3a5f;
    color: white;
}

/* ======================= NAVBAR ======================= */
#navbar {
    background: transparent;
}

#navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.04);
}

#navbar.scrolled .logo-text { color: #0f172a; }
#navbar.scrolled .logo-text span { color: #d97706; }
#navbar.scrolled .logo-sub { color: #94a3b8; }
#navbar.scrolled .nav-link { color: #475569; }
#navbar.scrolled .nav-link:hover { color: #1e3a5f; }
#navbar.scrolled .burger-line { background: #0f172a; }

#navbar:not(.scrolled) .logo-text { color: white; }
#navbar:not(.scrolled) .logo-text span { color: #fbbf24; }
#navbar:not(.scrolled) .logo-sub { color: rgba(255, 255, 255, 0.5); }
#navbar:not(.scrolled) .nav-link { color: rgba(255, 255, 255, 0.8); }
#navbar:not(.scrolled) .nav-link:hover { color: white; }
#navbar:not(.scrolled) .burger-line { background: white; }

/* ======================= GLASS BADGES ======================= */
.glass-badge {
    transition: all 0.3s ease;
}

.glass-badge:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* ======================= HERO PARTICLES ======================= */
#particles .particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(217, 119, 6, 0.25);
    border-radius: 50%;
    animation: float-particle linear infinite;
}

@keyframes float-particle {
    0% { transform: translateY(100vh) scale(0); opacity: 0; }
    10% { opacity: 1; }
    90% { opacity: 1; }
    100% { transform: translateY(-10vh) scale(1); opacity: 0; }
}

/* ======================= MAGNETIC CARDS ======================= */
.magnetic-card {
    transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1), box-shadow 0.4s ease;
}

.magnetic-card:hover {
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.08);
}

/* ======================= BENTO CARDS ======================= */
.bento-card {
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
}

.bento-card:hover {
    transform: translateY(-6px);
}

/* ======================= GALLERY ======================= */
.gallery-item {
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
}

.gallery-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

/* ======================= TARIF CARDS ======================= */
.tarif-card {
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
}

/* ======================= BEFORE / AFTER SLIDER ======================= */
.ba-slider {
    position: relative;
    overflow: hidden;
    cursor: col-resize;
    -webkit-user-select: none;
    user-select: none;
    touch-action: none;
}

.ba-slider .ba-after {
    position: absolute;
    inset: 0;
}

.ba-slider .ba-after img,
.ba-slider .ba-before img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ba-slider .ba-before {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
    overflow: hidden;
    width: 50%;
    height: 100%;
}

.ba-slider .ba-before img {
    position: absolute;
    top: 0;
    left: 0;
}

.ba-slider .ba-handle {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 3px;
    background: white;
    z-index: 3;
    left: 50%;
    transform: translateX(-50%);
    box-shadow: 0 0 15px rgba(0,0,0,0.3);
}

.ba-slider .ba-handle-circle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: white;
    box-shadow: 0 4px 20px rgba(0,0,0,0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 4;
}

.ba-slider .ba-label {
    position: absolute;
    bottom: 20px;
    padding: 6px 16px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    z-index: 2;
    pointer-events: none;
    backdrop-filter: blur(4px);
}

.ba-label-before {
    left: 16px;
    background: rgba(239, 68, 68, 0.85);
    color: white;
}

.ba-label-after {
    right: 16px;
    background: rgba(34, 197, 94, 0.85);
    color: white;
}

/* ======================= DIAGNOSTIC OPTIONS ======================= */
.diag-option.selected {
    border-color: #d97706 !important;
    background: #fffbeb !important;
    box-shadow: 0 0 0 3px rgba(217, 119, 6, 0.1);
}

/* ======================= STICKY CTA ======================= */
.sticky-cta-pulse {
    animation: ctaPulse 3s ease-in-out infinite;
}

@keyframes ctaPulse {
    0%, 100% { box-shadow: 0 10px 40px rgba(249, 115, 22, 0.3); }
    50% { box-shadow: 0 10px 60px rgba(249, 115, 22, 0.5); }
}

.pb-safe {
    padding-bottom: max(16px, env(safe-area-inset-bottom));
}

/* ======================= REVIEW DOTS ======================= */
.review-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #d1d5db;
    transition: all 0.3s ease;
    cursor: pointer;
}

.review-dot.active {
    background: #d97706;
    width: 24px;
    border-radius: 4px;
}

/* ======================= MOBILE MENU ======================= */
#mobile-menu {
    background-color: #fdfbf7;
}

#navbar.menu-open {
    background: #fdfbf7 !important;
    border-bottom: 1px solid #e5e2dc;
}
#navbar.menu-open .logo-text { color: #0f172a !important; }
#navbar.menu-open .logo-text span { color: #d97706 !important; }
#navbar.menu-open .logo-sub { color: #94a3b8 !important; }
#navbar.menu-open .burger-line { background: #0f172a !important; }

/* ======================= SCROLLBAR ======================= */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* ======================= FOOTER ======================= */
footer {
    position: relative;
    z-index: 1;
}

/* ======================= RESPONSIVE ======================= */
@media (max-width: 640px) {
    #hero h1 { font-size: 2.25rem; }
    .tarif-card.md\:scale-105 { transform: scale(1); }
    .review-card { width: 300px !important; }
    .ba-slider { height: 300px !important; }
}

/* ======================= FEATURE CAROUSEL ======================= */
.carousel-label {
    background: transparent;
    cursor: pointer;
}

.carousel-label:hover {
    background: rgba(217, 119, 6, 0.04);
}

.carousel-label.active {
    background: rgba(217, 119, 6, 0.06);
    border-color: #d97706;
}

.carousel-slide {
    pointer-events: none;
}

.carousel-slide:first-child {
    pointer-events: auto;
}

/* ======================= COUNTER ======================= */
.count-up {
    display: inline-block;
}
