/* ==========================================
   BREADCRUMB STYLES - ARCY
   ========================================== */

.breadcrumb-container {
    position: relative;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 999999 !important; /* Z-INDEX ABUSÉ COMME DEMANDÉ */
    padding: 1.5rem 0 1rem 0;
    background: transparent;
    margin-bottom: 0;
    margin-top: 80px; /* Espacement depuis la top bar */
    pointer-events: auto; /* S'assurer que les événements de clic passent */
}

.breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    font-size: 0.875rem;
    color: var(--text-secondary, #6B7280);
    font-family: 'Glacial Indifference', sans-serif;
    pointer-events: auto; /* S'assurer que les événements de clic passent */
    z-index: 999999 !important; /* Z-INDEX ABUSÉ */
    position: relative !important;
}

.breadcrumb-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    pointer-events: auto; /* S'assurer que les événements de clic passent */
    z-index: 999999 !important; /* Z-INDEX ABUSÉ */
    position: relative !important;
}

.breadcrumb-link {
    color: var(--text-secondary, #6B7280);
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.375rem;
    padding: 0.5rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    cursor: pointer !important; /* Forcer le curseur pointer */
    position: relative !important;
    background-color: transparent;
    border: 1px solid transparent;
    pointer-events: auto !important; /* Forcer les événements de clic */
    z-index: 1000000 !important; /* Z-INDEX ULTRA ABUSÉ POUR L'ICÔNE MAISON */
}

.breadcrumb-link:hover {
    color: var(--primary-color, #3B82F6);
    background-color: var(--background-hover, rgba(59, 130, 246, 0.1));
    border-color: var(--primary-color, rgba(59, 130, 246, 0.2));
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(59, 130, 246, 0.15);
}

.breadcrumb-link:active {
    color: var(--primary-color, #3B82F6);
    transform: translateY(0);
}

.breadcrumb-link svg {
    width: 1.125rem;
    height: 1.125rem;
    stroke-width: 1.5;
    transition: all 0.3s ease;
    pointer-events: none; /* Empêcher les événements sur le SVG pour qu'ils passent au lien parent */
    z-index: 1000001 !important; /* ENCORE PLUS ABUSÉ */
}

.breadcrumb-link:hover svg {
    stroke-width: 2;
    transform: scale(1.1);
}

.breadcrumb-separator {
    color: var(--text-muted, #9CA3AF);
    font-size: 0.875rem;
    margin: 0 0.375rem;
    font-weight: 400;
    pointer-events: none; /* Pas besoin d'événements sur le séparateur */
}

.breadcrumb-current {
    color: var(--text-primary, #1F2937);
    font-weight: 500;
    font-size: 0.875rem;
    padding: 0.25rem 0;
    cursor: default;
    pointer-events: none; /* Pas besoin d'événements sur l'élément courant */
}

/* CORRECTION CRITIQUE POUR LE LOGO ARCY QUI DÉBORDE */
.site-logo {
    height: 300px !important;
    display: flex !important;
    align-items: center !important;
    position: relative !important;
    transition: none !important;
    max-width: none !important; /* SUPPRIMER LA LIMITE DE LARGEUR */
    z-index: 50 !important; /* BEAUCOUP MOINS QUE LES BREADCRUMBS */
}

.logo-primary,
.logo-secondary {
    position: absolute !important;
    width: auto !important;
    transition: opacity 0.3s ease !important;
    left: 50% !important;
    transform: translateX(-37%) !important;
    max-width: none !important; /* SUPPRIMER LA LIMITE DE TAILLE */
    z-index: 51 !important; /* MOINS QUE LES BREADCRUMBS */
    pointer-events: none !important; /* EMPÊCHER LES CLICS SUR LE LOGO */
}

.logo-primary {
    height: 270px !important;
}

.logo-secondary {
    height: 37px !important;
    opacity: 0 !important;
    transform: translateX(-0%) !important;
}

/* CORRECTION SPÉCIFIQUE POUR LE LOGO SECONDAIRE AU SCROLL */
.top-bar.scrolled .logo-primary {
    opacity: 0 !important;
    z-index: 51 !important;
    pointer-events: none !important;
}

.top-bar.scrolled .logo-secondary {
    opacity: 1 !important;
    z-index: 51 !important;
    pointer-events: none !important;
    height: 37px !important;
    max-width: none !important;
}

/* Limiter strictement la zone du logo */
.logo-cell {
    width: auto !important;
    height: 70px !important; /* HAUTEUR DE LA TOP-BAR */
    position: relative !important;
    flex-shrink: 0 !important;
    box-sizing: border-box !important;
    z-index: 50 !important; /* MOINS QUE LES BREADCRUMBS */
}

/* Responsive design */
@media (max-width: 768px) {
    .breadcrumb-container {
        margin-top: 70px; /* Ajustement pour mobile */
        padding: 1rem 0 0.5rem 0;
        z-index: 999999 !important; /* Z-INDEX ABUSÉ POUR MOBILE */
    }
    
    .breadcrumb {
        padding: 0 1rem;
        font-size: 0.8125rem;
        z-index: 999999 !important;
    }
    
    .breadcrumb-link {
        padding: 0.375rem;
        cursor: pointer !important; /* Forcer le curseur pointer sur mobile aussi */
        z-index: 1000000 !important; /* Z-INDEX ABUSÉ MOBILE */
    }
    
    .breadcrumb-link svg {
        width: 1rem;
        height: 1rem;
    }
    
    .breadcrumb-current {
        font-size: 0.8125rem;
    }
    
    .breadcrumb-separator {
        margin: 0 0.25rem;
    }
    
    /* LOGO ENCORE PLUS LIMITÉ SUR MOBILE */
    .site-logo {
        height: 60px !important;
    }
    
    .logo-cell {
        height: 60px !important;
    }
    
    .logo-primary {
        height: 270px !important; /* CORRECTION: même taille que index.html */
    }
    
    .logo-secondary {
        height: 37px !important; /* CORRECTION: même taille que index.html */
    }
}

@media (max-width: 480px) {
    .breadcrumb-container {
        margin-top: 60px;
        z-index: 999999 !important; /* Z-INDEX ABUSÉ PETIT MOBILE */
    }
    
    .breadcrumb {
        padding: 0 1rem;
        gap: 0.375rem;
        z-index: 999999 !important;
    }
    
    .breadcrumb-item {
        gap: 0.375rem;
        z-index: 999999 !important;
    }
    
    .breadcrumb-separator {
        margin: 0 0.125rem;
    }
    
    .breadcrumb-link {
        padding: 0.25rem;
        cursor: pointer !important; /* Forcer le curseur pointer sur petit mobile aussi */
        z-index: 1000000 !important; /* Z-INDEX ABUSÉ PETIT MOBILE */
    }
    
    .breadcrumb-link svg {
        width: 0.875rem;
        height: 0.875rem;
    }
}

/* Ajustement pour que la hero section suivante soit bien espacée */
.breadcrumb-container + .hero-intro-section {
    margin-top: 0 !important;
    padding-top: 1rem !important;
}

/* Thème sombre */
[data-theme="dark"] .breadcrumb-link {
    color: var(--text-secondary-dark, #9CA3AF);
}

[data-theme="dark"] .breadcrumb-link:hover {
    color: var(--primary-color-dark, #60A5FA);
    background-color: var(--background-hover-dark, rgba(96, 165, 250, 0.1));
    border-color: rgba(96, 165, 250, 0.3);
    box-shadow: 0 4px 8px rgba(96, 165, 250, 0.2);
}

[data-theme="dark"] .breadcrumb-current {
    color: var(--text-primary-dark, #F3F4F6);
}

[data-theme="dark"] .breadcrumb-separator {
    color: var(--text-muted-dark, #6B7280);
}

/* Mode blanc - Améliorations */
[data-theme="light"] .breadcrumb-link,
:root:not([data-theme="dark"]) .breadcrumb-link {
    color: #6B7280;
}

[data-theme="light"] .breadcrumb-link:hover,
:root:not([data-theme="dark"]) .breadcrumb-link:hover {
    color: #2563EB;
    background-color: rgba(37, 99, 235, 0.08);
    border-color: rgba(37, 99, 235, 0.2);
    box-shadow: 0 4px 8px rgba(37, 99, 235, 0.12);
}

[data-theme="light"] .breadcrumb-current,
:root:not([data-theme="dark"]) .breadcrumb-current {
    color: #1F2937;
}

[data-theme="light"] .breadcrumb-separator,
:root:not([data-theme="dark"]) .breadcrumb-separator {
    color: #9CA3AF;
}

/* Correction spécifique pour les overlays qui pourraient bloquer les clics */
.breadcrumb-container {
    position: relative !important;
}

.breadcrumb-link {
    position: relative !important;
    z-index: 1000000 !important; /* Z-INDEX ABUSÉ COMME DEMANDÉ */
}

/* S'assurer qu'aucun élément ne bloque les breadcrumbs */
.hero-mobile-background {
    z-index: -1 !important;
}

.mobile-nav-overlay {
    z-index: 50 !important; /* Moins que les breadcrumbs */
    pointer-events: none !important; /* CRITIQUE : Empêcher complètement les événements de clic */
    display: none !important; /* Masquer complètement si pas utilisé */
}

/* Styles explicites pour les overlays problématiques */
.top-bar .mobile-nav-overlay {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    background: transparent !important;
    pointer-events: none !important; /* CRITIQUE : Aucun événement de clic */
    z-index: -1 !important; /* Derrière tout */
    display: none !important; /* Masquer par défaut */
}

/* S'assurer que les breadcrumbs sont toujours au-dessus */
.breadcrumb-container,
.breadcrumb,
.breadcrumb-item,
.breadcrumb-link {
    position: relative !important;
    z-index: 1000000 !important; /* Z-INDEX ULTRA ABUSÉ */
}

/* Force les breadcrumbs à être cliquables même s'il y a des overlays */
.breadcrumb-link {
    pointer-events: all !important;
    cursor: pointer !important;
    user-select: none !important;
}

/* CORRECTION CRITIQUE : Limiter la zone cliquable du menu-toggle */
.menu-toggle {
    width: 40px !important;
    height: 40px !important;
    overflow: hidden !important; /* Empêcher le débordement */
    position: relative !important;
    z-index: 2001 !important;
    pointer-events: auto !important;
    /* Créer un conteneur strict */
    box-sizing: border-box !important;
    border: none !important;
    margin: 0 !important;
    padding: 8px !important;
}

/* S'assurer que le menu-toggle ne déborde jamais */
.menu-toggle::before,
.menu-toggle::after {
    display: none !important; /* Supprimer tout pseudo-élément qui pourrait déborder */
}

/* Limiter strictement la zone du menu-cell */
.menu-cell {
    width: 40px !important;
    height: 40px !important;
    overflow: hidden !important;
    position: relative !important;
    flex-shrink: 0 !important;
    box-sizing: border-box !important;
}

/* Limiter la zone de la top-bar-left */
.top-bar-left {
    position: relative !important;
    z-index: 100 !important; /* Moins que les breadcrumbs */
    overflow: visible !important;
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
}

/* Correction pour mobile spécifiquement */
@media (max-width: 768px) {
    .mobile-nav-overlay {
        display: none !important;
        pointer-events: none !important;
        z-index: -10 !important;
    }
    
    .breadcrumb-link {
        z-index: 1000000 !important; /* Z-INDEX ABUSÉ MOBILE */
        pointer-events: all !important;
        touch-action: manipulation !important; /* Pour mobile */
    }
    
    /* Limiter encore plus strictement sur mobile */
    .menu-toggle {
        width: 40px !important;
        height: 40px !important;
        max-width: 40px !important;
        max-height: 40px !important;
        overflow: hidden !important;
        position: relative !important;
    }
    
    .menu-cell {
        width: 40px !important;
        height: 40px !important;
        max-width: 40px !important;
        max-height: 40px !important;
        overflow: hidden !important;
    }
}

/* Correction finale : Assurer que rien ne déborde de la top-bar */
.top-bar {
    overflow: visible !important; /* Permettre aux breadcrumbs d'être visibles */
}

.top-bar * {
    box-sizing: border-box !important;
}

/* CORRECTION SPÉCIFIQUE POUR LE LOGO ARCY QUI DÉBORDE */
.top-bar .site-logo,
.top-bar .logo-primary,
.top-bar .logo-secondary,
.top-bar .logo-cell,
.top-bar.scrolled .logo-primary,
.top-bar.scrolled .logo-secondary {
    z-index: 50 !important; /* BEAUCOUP MOINS QUE LES BREADCRUMBS */
    pointer-events: none !important; /* EMPÊCHER TOUS LES CLICS SUR LE LOGO */
    /* SUPPRIMER overflow: hidden pour que les logos restent visibles */
}

/* Créer une zone de sécurité pour les breadcrumbs */
.breadcrumb-safe-zone {
    position: relative !important;
    z-index: 1000000 !important; /* Z-index maximum */
    pointer-events: auto !important;
} 