/* ===== HAVEZ LEVAGE — Central Stylesheet ===== */
/* Consolidé depuis header.php, footer.php, home.php, contact.php, service-detail.php, parc-materiel.php */

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Barlow Condensed', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}
nav a, nav button, .mobile-menu-link {
    font-family: 'Barlow Condensed', sans-serif;
    letter-spacing: 0.05em;
}

/* --- Utilities --- */
[x-cloak] { display: none !important; }

/* --- Preloader Animations --- */
@keyframes glowPulse {
    0%, 100% { transform: scale(1); opacity: 0.6; }
    50%       { transform: scale(1.2); opacity: 1; }
}
@keyframes spinSlow {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}
@keyframes logoReveal {
    from { opacity: 0; transform: translateY(16px) scale(0.95); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* --- Scroll Reveal --- */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}
.reveal-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}
.delay-100 { transition-delay: 100ms; }
.delay-200 { transition-delay: 200ms; }
.delay-300 { transition-delay: 300ms; }
.delay-400 { transition-delay: 400ms; }

/* --- Nav Link Animation --- */
.nav-link.active-page::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #D32F2F, #FFFFFF);
    border-radius: 2px 2px 0 0;
}
.nav-link::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #D32F2F, #FFFFFF);
    border-radius: 2px 2px 0 0;
    transition: transform 0.3s ease;
}
.nav-link:hover::before {
    transform: translateX(-50%) scaleX(1);
}
.nav-link.active-page::before {
    display: none;
}

/* --- Ticker Scrolling Animation --- */
@keyframes tickerScroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}
.ticker-wrap {
    flex-shrink: 0;
}
.ticker:hover {
    animation-play-state: paused !important;
}

/* --- 3D Service Card Effect --- */
.service-card {
    perspective: 1000px;
}
.service-card:hover {
    transform: translateY(-8px) rotateX(2deg);
}

/* --- Stats Gradient Shift --- */
@keyframes gradient-shift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* --- Technical Grid Patterns (shared SVG defs) --- */
.tech-grid-pattern {
    opacity: 0.05;
    pointer-events: none;
}

/* --- Buttons & Links --- */
.btn-primary {
    display: inline-flex;
    align-items: center;
    background: #D32F2F;
    color: white;
    font-weight: 700;
    text-transform: uppercase;
    padding: 1rem 2.5rem;
    transition: all 0.3s;
}
.btn-primary:hover {
    background: #1F2937;
}

/* --- Service Nav Sidebar --- */
.service-nav-link {
    display: block;
    padding: 0.75rem 1rem;
    border-radius: 0.375rem;
    transition: all 0.2s;
    font-weight: 700;
    font-size: 1.125rem;
}

/* --- Sticky Sidebar (desktop uniquement : sur mobile la colonne s'empile
       au-dessus du contenu et le sticky la ferait flotter par-dessus) --- */
@media (min-width: 768px) {
    .sticky-sidebar {
        position: sticky;
        top: 100px;
        align-self: start;
    }
}

/* --- Service Detail Layout --- */
.service-detail-main h2 {
    font-size: 1.875rem;
    font-weight: 700;
    color: #1F2937;
    margin-bottom: 1.5rem;
}
.service-detail-main h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1F2937;
    margin-bottom: 1rem;
}

/* --- Parc Matériel --- */
.machine-card {
    transition: all 0.3s ease;
}
.machine-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px -12px rgba(0,0,0,0.15);
}

/* --- Print --- */
@media print {
    #preloader, #scroll-to-top, .sticky { display: none !important; }
    body { overflow: visible !important; }
}

/* ============================================================
   Polices hébergées en local (RGPD) — remplacent Google Fonts
   ============================================================ */
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/inter-v20-latin-regular.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 500; font-display: swap; src: url('../fonts/inter-v20-latin-500.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 600; font-display: swap; src: url('../fonts/inter-v20-latin-600.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 700; font-display: swap; src: url('../fonts/inter-v20-latin-700.woff2') format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/barlow-condensed-v13-latin-regular.woff2') format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-style: normal; font-weight: 600; font-display: swap; src: url('../fonts/barlow-condensed-v13-latin-600.woff2') format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-style: normal; font-weight: 700; font-display: swap; src: url('../fonts/barlow-condensed-v13-latin-700.woff2') format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-style: normal; font-weight: 800; font-display: swap; src: url('../fonts/barlow-condensed-v13-latin-800.woff2') format('woff2'); }

/* Champ leurre des formulaires : hors de l'écran plutôt que display:none,
   que les robots repèrent trop facilement. */
.champ-leurre {
    position: absolute;
    left: -9999px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
}
