/* Home Page Styles for ZAIRIDES Website */

/* Navigation Styles - Adaptive header */
nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 19px 5%; /* Reduced by 20% from 24px */
    backdrop-filter: blur(10px);
    z-index: 1000;
    transition: background-color var(--transition-medium), border-color var(--transition-medium);
}

/* Light mode nav - White background */
body:not(.dark-mode) nav {
    background: rgba(255, 255, 255, 0.95);
    border-bottom: 1px solid var(--pearl-mid);
}

/* Dark mode nav - Dark background */
body.dark-mode nav {
    background: rgba(10, 10, 10, 0.95);
    border-bottom: 1px solid rgba(220, 38, 38, 0.1);
}

.nav-container {
    max-width: var(--container-max-width);
    margin: 0 auto;
    padding: 0 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-right {
    display: flex;
    align-items: center; /* Alignement horizontal sur desktop */
    gap: 15px; /* Espace entre nav-links et theme switcher */
}

.logo {
    display: flex;
    align-items: center;
    gap: 3px;  /* Réduit encore (6px → 3px) */
    text-decoration: none;
    outline: none;
}

.logo:focus,
.logo:active {
    outline: none;
    box-shadow: none;
}

.logo-icon {
    width: 75px;  /* Agrandi de 1.5x (50px → 75px) */
    height: 75px; /* Agrandi de 1.5x (50px → 75px) */
    transition: all 0.3s ease;
}

.logo-text {
    font-family: 'Audiowide', var(--font-family);
    font-size: 26px;  /* Augmenté de 2pt (24px → 26px) */
    font-weight: 400;  /* Audiowide n'a qu'un seul poids */
    color: var(--red-dark); /* Darker red for light mode */
    letter-spacing: 3px;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

body.dark-mode .logo-text {
    color: var(--red-light); /* Lighter red for dark mode */
}

/* Responsive mobile - logo réduit uniformisé */
@media (max-width: 968px) {
    .logo {
        gap: 4px;
        margin-left: -0.5rem;
    }

    .logo-icon {
        width: 45px !important;
        height: 45px !important;
    }

    .logo-text {
        font-size: 16px !important;
        letter-spacing: 2px;
    }

    .nav-container {
        padding-left: 0.5rem !important;
        padding-right: 1rem !important;
    }

    .nav-right .nav-links {
        display: none;
    }

    .nav-right .nav-theme-switcher {
        display: none;
    }
}

.nav-links {
    display: flex;
    gap: 30px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-links a {
    color: var(--text-secondary); /* Adaptive color for light mode */
    text-decoration: none;
    font-weight: var(--font-weight-medium);
    font-size: 15px;
    transition: all var(--transition-fast);
    position: relative;
    letter-spacing: 0.5px;
}

body.dark-mode .nav-links a {
    color: #a1a1aa; /* Light gray for dark mode */
}

.nav-links a:hover {
    color: var(--red-dark); /* Darker red for light mode */
}

body.dark-mode .nav-links a:hover {
    color: var(--red-light); /* Lighter red for dark mode */
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--red-mid);
    transition: width var(--transition-fast);
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

/* Remove contact button - not in the original design */

/* Theme switcher dans la navigation */
.nav-theme-switcher {
    display: flex;
    align-items: center;
    gap: 6px; /* Espace entre les boutons */
}

.nav-theme-btn {
    width: 32px; /* Slightly larger for better touch */
    height: 32px;
    border-radius: 18px;
    border: 1px solid rgba(0,0,0,0.1); /* Subtle border */
    background: rgba(255,255,255,0.8); /* Light background */
    font-size: 14px; /* Larger emoji */
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.8;
    position: relative;
    backdrop-filter: blur(10px); /* Glass effect */
}

.nav-theme-btn:hover {
    opacity: 1;
    background: rgba(220, 38, 38, 0.1); /* Red tint on hover */
    border-color: rgba(220, 38, 38, 0.2);
    transform: scale(1.05); /* Slight scale effect */
}

body.dark-mode .nav-theme-btn {
    background: rgba(30, 30, 33, 0.8); /* Dark background */
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .nav-theme-btn:hover {
    background: rgba(220, 38, 38, 0.15); /* Red tint on hover dark */
    border-color: rgba(220, 38, 38, 0.3);
}

.nav-theme-btn.active {
    opacity: 1;
    background: rgba(220, 38, 38, 0.15); /* Active state */
    border-color: rgba(220, 38, 38, 0.3);
    transform: scale(0.95); /* Pressed effect */
}

body.dark-mode .nav-theme-btn.active {
    background: rgba(220, 38, 38, 0.2); /* Dark active state */
    border-color: rgba(220, 38, 38, 0.4);
}

.nav-theme-btn:not(.active) {
    filter: grayscale(100%) brightness(0.8);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 80px 5% 40px; /* Mobile-First: padding ultra réduit */
    position: relative;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        linear-gradient(rgba(220, 38, 38, 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(220, 38, 38, 0.06) 1px, transparent 1px);
    background-size: 15px 15px;
    pointer-events: none;
    z-index: 0;
}

body.dark-mode .hero::after {
    background-image:
        linear-gradient(rgba(239, 68, 68, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(239, 68, 68, 0.05) 1px, transparent 1px);
    background-size: 20px 20px;
}

.hero-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr; /* Mobile-First: 1 colonne */
    gap: 20px; /* Mobile-First: gap minimal */
    align-items: center;
    position: relative;
    z-index: 1;
}

.minimal-badge {
    display: inline-block;
    padding: 8px 20px;
    background: var(--red-dark);
    color: white;
    font-size: 11px;
    font-weight: var(--font-weight-semibold);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 20px; /* Mobile-First: marge réduite */
    align-self: flex-start;
    transition: background-color var(--transition-fast);
}

.hero-text {
    max-width: 600px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.hero-text h1 {
    font-size: clamp(37px, 3.9vw, 56px); /* Reduced by 23% total */
    font-weight: var(--font-weight-light);
    letter-spacing: -1px;
    color: var(--text-primary);
    margin-bottom: 16px; /* Mobile-First: espacement réduit */
    line-height: 1.2;
    text-align: justify;
    transition: color var(--transition-medium);
}

.hero-text h1 span {
    font-weight: var(--font-weight-bold);
    color: var(--red-dark);
}

.hero-text p {
    font-size: 20px;
    color: var(--text-secondary);
    margin-bottom: 24px; /* Mobile-First: espacement réduit */
    line-height: 1.6;
    font-weight: var(--font-weight-regular);
    text-align: justify;
}

/* Hero 3D Visualization */
.hero-visual {
    width: 100%;
    height: 100%;
    min-height: 500px;
    position: relative;
}

#hero-3d-container {
    width: 100%;
    height: 600px;
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(220, 38, 38, 0.03) 0%, rgba(239, 68, 68, 0.05) 100%);
    border: 1px solid rgba(220, 38, 38, 0.1);
    transition: all var(--transition-medium);
}

body.dark-mode #hero-3d-container {
    background: linear-gradient(135deg, rgba(220, 38, 38, 0.05) 0%, rgba(239, 68, 68, 0.08) 100%);
    border-color: rgba(239, 68, 68, 0.2);
}

#hero-3d-container canvas {
    display: block;
    width: 100% !important;
    height: 100% !important;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: flex-start;
}

.btn-primary {
    padding: 18px 48px;
    background: var(--red-dark);
    color: white;
    border: none;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.btn-primary:hover {
    background: var(--red-darkest);
    transform: translateY(-2px);
}

.btn-secondary {
    padding: 18px 48px;
    background: transparent;
    color: var(--red-dark);
    border: 2px solid var(--red-dark);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.btn-secondary:hover {
    background: var(--red-dark);
    color: white;
    text-align: left;
    transition: color var(--transition-medium);
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: flex-start;
    flex-wrap: wrap;
}

.btn-primary {
    padding: 18px 48px;
    background: var(--red-dark);
    color: white;
    border: none;
    font-size: 15px;
    font-weight: var(--font-weight-semibold);
    cursor: pointer;
    transition: all var(--transition-fast);
    text-decoration: none;
    display: inline-block;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.btn-primary:hover {
    background: var(--red-darkest);
    transform: translateY(-2px);
}

.btn-secondary {
    padding: 18px 48px;
    background: transparent;
    color: var(--red-dark);
    border: 2px solid var(--red-dark);
    font-size: 15px;
    font-weight: var(--font-weight-semibold);
    cursor: pointer;
    transition: all var(--transition-fast);
    text-decoration: none;
    display: inline-block;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.btn-secondary:hover {
    background: var(--red-dark);
    color: white;
}

/* Analytics Showcase Section - BEM Structure */
.analytics {
    padding: var(--section-padding);
    background: linear-gradient(180deg, #fafafa 0%, white 50%, #fafafa 100%);
    position: relative;
    transition: background var(--transition-medium);
    overflow: hidden;
}

.analytics::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(220, 38, 38, 0.02) 0%, transparent 70%);
    pointer-events: none;
}

body.dark-mode .analytics {
    background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-secondary) 50%, var(--bg-primary) 100%);
}

.analytics__container {
    max-width: var(--container-max-width);
    margin: 0 auto;
}

/* Carousel Component - BEM Structure */
.carousel {
    margin-top: 60px;
    position: relative;
}

.carousel__main {
    position: relative;
}

.carousel__container {
    position: relative;
    width: 100%;
    /* Mobile-First: hauteur dynamique basée sur le contenu */
    min-height: 400px; /* Mobile: hauteur minimale */
    height: auto; /* Mobile: s'adapte au contenu */
    overflow: hidden;
    background: white;
    border-radius: 12px; /* Mobile-First: border-radius réduit */
    box-shadow: 0 15px 40px rgba(0,0,0,0.06); /* Mobile-First: ombre réduite */
    border: 1px solid rgba(220, 38, 38, 0.05);
    transition: all var(--transition-medium);
}

body.dark-mode .carousel__container {
    background: var(--bg-card);
    border: 1px solid rgba(220, 38, 38, 0.15);
    box-shadow: 0 20px 60px rgba(220, 38, 38, 0.15);
}

.carousel__container:hover {
    box-shadow: 0 25px 70px rgba(0,0,0,0.12);
    transform: translateY(-2px);
}

body.dark-mode .carousel__container:hover {
    box-shadow: 0 25px 70px rgba(220, 38, 38, 0.2);
}

/* Modern CSS - Container Queries Implementation */
.carousel__container {
    container-type: inline-size;
    container-name: carousel;
}

.carousel__slides {
    position: relative; /* Mobile-First: position relative pour s'adapter au contenu */
    width: 400%; /* 4 slides x 100% */
    min-height: 100%; /* Mobile-First: hauteur minimale */
    display: flex;
    transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    will-change: transform; /* Optimisation GPU */
    /* Assurer une base stable pour les transitions */
    transform: translate3d(0, 0, 0);
    backface-visibility: hidden;
}

/* States for transition control */
.carousel__slides.no-transition {
    transition: none !important;
}

.carousel__slides.smooth-transition {
    transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94) !important;
}

/* Container Queries - Responsive moderne basé sur la taille du container */
@container carousel (min-width: 600px) {
    .slide__content {
        grid-template-columns: 1.2fr 0.8fr;
        gap: 25px;
    }

    .chart__title {
        font-size: 20px;
    }
}

@container carousel (min-width: 800px) {
    .slide__content {
        grid-template-columns: 1.5fr 1fr;
        gap: 35px;
    }

    .chart__container {
        height: 320px;
    }

    .chart__title {
        font-size: 22px;
    }
}

/* Container Query pour Services Grid */
@container (min-width: 500px) {
    .service__card {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
    }
}

.carousel__slide {
    width: 25%; /* 4 slides = 25% each (100/4) */
    min-height: 400px; /* Mobile-First: hauteur minimale */
    height: auto; /* Mobile-First: s'adapte au contenu */
    display: flex;
    align-items: stretch; /* Mobile-First: étire le contenu */
    justify-content: center;
    padding: 0; /* Réduit à 0 pour éliminer l'espace entre slides */
    box-sizing: border-box;
    flex-shrink: 0; /* Empêche la compression des slides */
    backface-visibility: hidden; /* Optimisation GPU */
    transform: translateZ(0); /* Force layer creation */
}

.slide__content {
    display: grid;
    grid-template-columns: 1fr; /* Mobile-First: 1 colonne par défaut */
    gap: 10px; /* Mobile-First: gap minimal pour réduire l'espace */
    width: 100%;
    min-height: 100%; /* Mobile-First: hauteur minimale */
    height: auto; /* Mobile-First: s'adapte au contenu */
    padding: 15px 20px 60px 20px; /* Mobile-First: padding avec espace en bas pour carousel */
    align-items: start; /* Mobile-First: alignement en haut pour éviter la superposition */
    align-content: start; /* Mobile-First: alignement du contenu grid */
    box-sizing: border-box;
    background: linear-gradient(135deg, transparent, rgba(220, 38, 38, 0.02));
    overflow-y: visible; /* Mobile-First: pas de scroll forcé */
}

/* Chart Component - BEM Structure */
.chart {
    position: relative;
}

.chart__description {
    /* Mobile-First: styles de base pour la description */
    margin-bottom: 40px; /* Mobile-First: réduit l'espace excessif */
    padding: 0; /* Mobile-First: pas de padding supplémentaire */
}

.chart__title {
    font-size: 18px; /* Mobile-First: taille mobile optimale */
    font-weight: var(--font-weight-semibold);
    color: var(--text-primary);
    margin-bottom: 12px; /* Mobile-First: espacement compact */
    margin-top: 0; /* Mobile-First: pas de marge négative */
    transition: color var(--transition-medium);
    position: relative;
    padding-left: 16px; /* Mobile-First: padding réduit */
    line-height: 1.3; /* Mobile-First: lisibilité mobile */
}

.chart__title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 24px;
    background: var(--red-dark);
    border-radius: 2px;
}

.chart__container {
    position: relative;
    width: 100%;
    height: 200px; /* Mobile-First: hauteur mobile optimale */
    padding: 10px; /* Mobile-First: padding mobile */
    box-sizing: border-box;
    background: rgba(255,255,255,0.5);
    border-radius: 8px; /* Mobile-First: border-radius réduit */
    border: 1px solid rgba(220, 38, 38, 0.05);
}

body.dark-mode .chart__container {
    background: rgba(30,30,33,0.3);
    border-color: rgba(220, 38, 38, 0.1);
}

.chart__description h4 {
    font-size: 16px; /* Mobile-First: taille mobile optimale */
    font-weight: var(--font-weight-semibold);
    color: var(--red-dark);
    margin-bottom: 10px; /* Mobile-First: espacement compact */
}

.chart__description p {
    color: var(--text-secondary);
    font-size: 14px; /* Mobile-First: taille mobile lisible */
    line-height: 1.5; /* Mobile-First: line-height mobile optimal */
    margin-bottom: 16px; /* Mobile-First: espacement compact */
    transition: color var(--transition-medium);
}

.metric-highlight {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px; /* Mobile-First: gap réduit */
    padding: 12px 16px; /* Mobile-First: padding compact */
    background: linear-gradient(135deg, rgba(220, 38, 38, 0.05), rgba(220, 38, 38, 0.02));
    border-radius: 8px; /* Mobile-First: border-radius réduit */
    border-left: 3px solid var(--red-dark);
    font-size: 13px; /* Mobile-First: texte compact */
}

.metric-value {
    font-size: 36px;
    font-weight: var(--font-weight-bold);
    color: var(--red-dark);
    font-family: var(--font-family);
}

.metric-desc {
    font-size: 14px;
    color: black;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: var(--font-weight-medium);
}

body.dark-mode .metric-desc {
    color: white;
}

.carousel-indicators {
    position: absolute;
    bottom: 10px; /* Mobile-First: position plus basse */
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px; /* Mobile-First: gap réduit */
    z-index: 20; /* Mobile-First: z-index plus élevé */
}

.carousel-dot {
    width: 8px; /* Mobile-First: taille mobile optimale */
    height: 8px; /* Mobile-First: taille mobile optimale */
    border-radius: 50%;
    background: rgba(113, 113, 122, 0.3);
    cursor: pointer;
    border: 2px solid transparent;
    transition: all var(--transition-fast);
}

.carousel-dot.active {
    background: var(--red-dark);
    transform: scale(1.3);
    border-color: var(--red-light);
}

.carousel-dot:hover {
    background: var(--red-mid);
    transform: scale(1.15);
}

/* Services Section */
.services {
    padding: var(--section-padding);
    background: var(--bg-primary);
    position: relative;
    transition: background-color var(--transition-medium);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 40px;
    max-width: var(--container-max-width);
    margin: 0 auto;
    align-items: stretch;
}

.service-card {
    padding: 24px 20px; /* Mobile-First: padding ultra réduit */
    background: var(--bg-card);
    border: 1px solid var(--pearl-mid);
    transition: all var(--transition-fast), background-color var(--transition-medium);
    min-height: 100%;
    display: flex;
    flex-direction: column;
}

.service-card:hover {
    border-color: var(--red-light);
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(220, 38, 38, 0.08);
}

.service-number {
    font-size: 48px;
    font-weight: var(--font-weight-bold);
    color: var(--red-light);
    margin-bottom: 24px;
    font-family: var(--font-family);
}

.service-card h3 {
    font-size: 22px;
    font-weight: var(--font-weight-semibold);
    margin-bottom: 16px;
    color: var(--text-primary);
    letter-spacing: -0.5px;
    transition: color var(--transition-medium);
    min-height: 2.5em;
    display: flex;
    align-items: center;
}

.service-card p {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 24px;
    transition: color var(--transition-medium);
    flex: 1;
}

.service-features {
    list-style: none;
    margin-top: auto;
}

.service-features li {
    padding: 12px 0;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid var(--pearl-light);
    transition: color var(--transition-medium);
}

.service-features li::before {
    content: '→';
    color: var(--red-mid);
    font-weight: var(--font-weight-semibold);
}

/* Philosophy Section */
.philosophy {
    padding: var(--section-padding);
    background: var(--bg-primary);
    transition: background-color var(--transition-medium);
}

.philosophy-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    max-width: var(--container-max-width);
    margin: 60px auto 0;
}

.philosophy-card {
    text-align: center;
}

.philosophy-icon {
    width: 80px;
    height: 80px;
    background: var(--red-dark);
    margin: 0 auto 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 36px;
    font-weight: var(--font-weight-bold);
    font-family: var(--font-family);
    border-radius: 8px;
    transition: background-color var(--transition-fast);
}

.philosophy-card:hover .philosophy-icon {
    background: var(--red-light);
}

.philosophy-card h4 {
    font-size: 18px;
    font-weight: var(--font-weight-semibold);
    color: var(--text-primary);
    margin-bottom: 12px;
    letter-spacing: 0.5px;
    transition: color var(--transition-medium);
}

.philosophy-card p {
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.6;
    transition: color var(--transition-medium);
}

/* Technologies Section */
.technologies {
    padding: var(--section-padding);
    background: var(--red-dark);
    color: white;
}

.technologies .section-header {
    text-align: center;
    margin-bottom: 60px;
}

.technologies .section-title {
    color: white;
}

.technologies .section-subtitle {
    color: white !important;
}

body.dark-mode .technologies .section-subtitle {
    color: white !important;
}

.tech-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 1px;
    background: var(--red-darkest);
    max-width: var(--container-medium-width);
    margin: 0 auto;
    border-radius: 8px;
    overflow: hidden;
}

.tech-item {
    background: var(--red-dark);
    padding: 20px; /* Mobile-First: padding réduit */
    display: flex;
    align-items: start;
    gap: 24px;
    transition: background-color var(--transition-fast);
}

.tech-item:hover {
    background: var(--red-mid);
}

.tech-number {
    width: 40px;
    height: 40px;
    background: var(--bg-primary);
    color: var(--red-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: var(--font-weight-bold);
    flex-shrink: 0;
    font-family: var(--font-family);
    border-radius: 4px;
}

.tech-content h4 {
    font-size: 20px;
    font-weight: var(--font-weight-semibold);
    margin-bottom: 12px;
    color: white;
    letter-spacing: 0.5px;
}

.tech-content p {
    color: var(--pearl-dark);
    font-size: 15px;
    line-height: 1.6;
}

/* Performance Metrics */
.performance-metrics {
    padding: var(--section-padding);
    background: var(--bg-card);
    transition: background-color var(--transition-medium);
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1px;
    background: var(--pearl-mid);
    max-width: var(--container-medium-width);
    margin: 0 auto;
    border-radius: 8px;
    overflow: hidden;
}

.metric-item {
    background: var(--bg-card);
    padding: 30px 20px; /* Mobile-First: padding ultra réduit */
    text-align: center;
    transition: all var(--transition-fast);
}

.metric-item:hover {
    background: var(--bg-secondary);
    transform: translateY(-2px);
}

.metric-number {
    font-size: 48px;
    font-weight: var(--font-weight-bold);
    color: var(--red-dark);
    margin-bottom: 12px;
    font-family: var(--font-family);
}

.metric-label {
    font-size: 13px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: var(--font-weight-semibold);
    transition: color var(--transition-medium);
}

/* Contact Section */
.contact {
    padding: var(--section-padding);
    background: var(--bg-primary);
    transition: background-color var(--transition-medium);
}

.contact-container {
    max-width: var(--container-medium-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 100px;
    align-items: center;
}

.contact-info h2 {
    font-size: 48px;
    font-weight: var(--font-weight-semibold);
    margin-bottom: 24px;
    color: var(--text-primary);
    letter-spacing: -0.5px;
    transition: color var(--transition-medium);
}

.contact-info h2 span {
    font-weight: var(--font-weight-bold);
    color: var(--red-dark);
}

.contact-info p {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 48px;
    line-height: 1.7;
    font-weight: var(--font-weight-regular);
    transition: color var(--transition-medium);
}

.contact-details {
    border-top: 1px solid var(--pearl-mid);
    padding-top: 32px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.contact-icon {
    width: 40px;
    height: 40px;
    background: var(--red-dark);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: var(--font-weight-bold);
    font-family: var(--font-family);
    border-radius: 6px;
}

.contact-text {
    color: var(--text-primary);
    font-size: 16px;
    transition: color var(--transition-medium);
}

.contact-form {
    background: var(--bg-card);
    border: 1px solid var(--pearl-mid);
    padding: 30px; /* Mobile-First: padding ultra réduit */
    border-radius: 8px;
    transition: all var(--transition-medium);
}

.form-group {
    margin-bottom: 32px;
}

.form-group label {
    display: block;
    margin-bottom: 12px;
    color: var(--text-primary);
    font-weight: var(--font-weight-semibold);
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: color var(--transition-medium);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 16px 0;
    border: none;
    border-bottom: 1px solid var(--pearl-mid);
    font-size: 16px;
    transition: all var(--transition-fast);
    font-family: var(--font-family);
    background: transparent;
    color: var(--text-primary);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-bottom-color: var(--red-mid);
}

.form-group input.error,
.form-group textarea.error {
    border-bottom-color: var(--red-light);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.submit-btn {
    width: 100%;
    padding: 18px;
    background: var(--red-dark);
    color: white;
    border: none;
    font-size: 14px;
    font-weight: var(--font-weight-semibold);
    cursor: pointer;
    transition: all var(--transition-fast);
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 4px;
}

.submit-btn:hover {
    background: var(--red-darkest);
    transform: translateY(-2px);
}

/* Recommendations Section */
.recommendations {
    padding: 80px 5%;
    background: var(--bg-secondary);
}

.recommendations-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin: 60px auto;
    max-width: var(--container-max-width);
}

.recommendation-category {
    background: var(--bg-primary);
    border-radius: 16px;
    padding: 40px;
    border: 1px solid var(--pearl-mid);
    transition: all var(--transition-base);
}

.recommendation-category:hover {
    box-shadow: 0 10px 40px rgba(153, 27, 27, 0.05);
    transform: translateY(-2px);
}

.category-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
}

.category-icon {
    font-size: 48px;
    background: linear-gradient(135deg, var(--red-dark), var(--red-darker));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.category-header h3 {
    font-size: 24px;
    font-weight: var(--font-weight-semibold);
    color: var(--text-primary);
}

.recommendation-items {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.recommendation-item {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    padding: 20px;
    background: var(--bg-secondary);
    border-radius: 12px;
    transition: all var(--transition-fast);
}

.recommendation-item:hover {
    background: var(--pearl-light);
    transform: translateX(5px);
}

.rec-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: var(--red-dark);
    color: white;
    border-radius: 50%;
    font-weight: var(--font-weight-bold);
    flex-shrink: 0;
}

.rec-content h4 {
    font-size: 16px;
    font-weight: var(--font-weight-semibold);
    color: var(--text-primary);
    margin-bottom: 8px;
}

.rec-content p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.action-plan {
    margin-top: 60px;
    padding: 40px;
    background: var(--bg-primary);
    border-radius: 16px;
    border: 1px solid var(--red-light);
}

.action-plan h3 {
    font-size: 28px;
    font-weight: var(--font-weight-light);
    color: var(--text-primary);
    margin-bottom: 40px;
    text-align: center;
}

.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--red-light);
    transform: translateX(-50%);
}

.timeline-item {
    display: flex;
    gap: 40px;
    margin-bottom: 40px;
    position: relative;
}

.timeline-item:nth-child(even) {
    flex-direction: row-reverse;
}

.timeline-marker {
    background: var(--red-dark);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: var(--font-weight-semibold);
    font-size: 14px;
    white-space: nowrap;
    height: fit-content;
}

.timeline-content {
    flex: 1;
    padding: 20px;
    background: var(--bg-secondary);
    border-radius: 12px;
    border: 1px solid var(--pearl-mid);
}

.timeline-content h4 {
    font-size: 18px;
    font-weight: var(--font-weight-semibold);
    color: var(--text-primary);
    margin-bottom: 10px;
}

.timeline-content p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Dark mode adjustments for recommendations */
body.dark-mode .recommendation-category {
    background: var(--bg-primary);
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .recommendation-item {
    background: var(--bg-secondary);
}

body.dark-mode .recommendation-item:hover {
    background: rgba(239, 68, 68, 0.05);
}

body.dark-mode .action-plan {
    background: var(--bg-primary);
    border-color: rgba(239, 68, 68, 0.3);
}

body.dark-mode .timeline::before {
    background: rgba(239, 68, 68, 0.3);
}

body.dark-mode .timeline-content {
    background: var(--bg-secondary);
    border-color: rgba(255, 255, 255, 0.1);
}

/* Tech number in dark mode - white background */
body.dark-mode .tech-number {
    background: white;
    color: var(--red-dark);
}

/* Footer */
footer {
    padding: 60px 5%;
    background: var(--text-primary);
    color: var(--pearl-dark);
    text-align: center;
    border-top: 1px solid var(--red-darkest);
}

.footer-content {
    max-width: var(--container-medium-width);
    margin: 0 auto;
}

.footer-text {
    font-size: 14px;
    letter-spacing: 1px;
}

body.dark-mode .footer-text {
    color: black;
}

/* Theme Switcher Styles - REMOVED DUPLICATED BOTTOM THEME SWITCHER
   The floating theme switcher (top-right) is now the only theme switcher.
   This eliminates duplication and improves user experience. */

/* Responsive Design */
@media (max-width: 968px) {
    .nav-links {
        display: none;
    }

    /* Navigation mobile avec theme switcher */
    .nav-right {
        justify-content: flex-end; /* Aligner le theme switcher à droite */
    }

    .nav-theme-switcher {
        gap: 4px; /* Réduire l'espace sur mobile */
    }

    .nav-theme-btn {
        width: 28px; /* Plus petit sur mobile */
        height: 28px;
        font-size: 12px;
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: left;
    }

    .hero-visual {
        display: none;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .philosophy-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .tech-grid {
        grid-template-columns: 1fr;
    }

    .metrics-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .contact-container {
        grid-template-columns: 1fr;
        gap: 60px;
    }

    .slide__content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

/* ===== MOBILE-FIRST MEDIA QUERIES ===== */

/* Large Mobile (480px+) */
@media (min-width: 480px) {
    /* Hero Progressive Enhancement */
    .hero {
        padding: 100px 5% 50px; /* Augmentation progressive */
    }

    .hero-content {
        gap: 30px; /* Plus d'espace */
    }

    .minimal-badge {
        margin-bottom: 24px;
    }

    .hero-text {
        margin-bottom: 18px;
    }

    .hero-description {
        margin-bottom: 28px;
    }

    /* Carousel Progressive Enhancement */
    .carousel__container {
        min-height: 450px; /* Plus de hauteur sur large mobile */
        border-radius: 14px;
        box-shadow: 0 18px 45px rgba(0,0,0,0.07);
    }

    .carousel__slide {
        min-height: 450px; /* S'adapte au container */
    }

    .slide__content {
        gap: 12px; /* Large mobile: gap réduit */
        padding: 18px 25px 55px 25px; /* Espace bas optimisé */
    }

    .chart__title {
        font-size: 20px; /* Plus grand sur large mobile */
        margin-bottom: 14px;
        padding-left: 18px;
    }

    .chart__container {
        height: 220px; /* Plus haut sur large mobile */
        padding: 12px;
        border-radius: 10px;
    }

    .chart__description h4 {
        font-size: 17px; /* Progression des tailles */
    }

    .chart__description p {
        font-size: 15px; /* Progression des tailles */
    }

    .carousel-dot {
        width: 9px; /* Légèrement plus grand */
        height: 9px;
    }

    /* Cards Progressive Enhancement - Large Mobile */
    .service-card {
        padding: 28px 24px; /* Légère augmentation */
    }

    .tech-item {
        padding: 24px; /* Progression douce */
    }

    .metric-item {
        padding: 35px 24px; /* Progression douce */
    }

    .contact-form {
        padding: 35px; /* Progression douce */
    }
}

/* Tablet (768px+) */
@media (min-width: 768px) {
    /* Hero Tablet Enhancement */
    .hero {
        padding: 120px 5% 60px; /* Tablet: padding augmenté */
    }

    .hero-content {
        gap: 40px; /* Plus d'espace sur tablet */
    }

    .minimal-badge {
        margin-bottom: 30px;
    }

    .hero-text {
        margin-bottom: 20px;
    }

    .hero-description {
        margin-bottom: 32px;
    }

    /* Variables de section adaptées */
    :root {
        --section-padding: var(--section-padding-tablet);
    }

    /* Carousel Tablet Enhancement */
    .carousel__container {
        min-height: 500px; /* Plus de hauteur sur tablet */
        border-radius: 16px;
        box-shadow: 0 20px 60px rgba(0,0,0,0.08);
    }

    .carousel__slide {
        min-height: 500px; /* S'adapte au container */
    }

    .slide__content {
        gap: 15px; /* Tablet: gap optimisé */
        padding: 20px 40px 45px 40px; /* Tablet: espace bas optimisé */
        align-items: center; /* Centrage vertical sur tablet+ */
    }

    .chart__title {
        font-size: 22px;
        margin-bottom: 15px;
        padding-left: 20px;
    }

    .chart__container {
        height: 250px; /* Format 16/9 pour tablet */
        padding: 15px;
        border-radius: 12px;
    }

    .chart__description {
        margin-bottom: 25px; /* Tablet: espace réduit et optimisé */
    }

    .chart__description h4 {
        font-size: 18px; /* Taille tablet */
        margin-bottom: 12px;
    }

    .chart__description p {
        font-size: 16px; /* Taille tablet */
        line-height: 1.6;
        margin-bottom: 18px;
    }

    .metric-highlight {
        padding: 14px 18px; /* Taille tablet */
        border-radius: 10px;
        font-size: 14px;
    }

    .carousel-indicators {
        bottom: 15px; /* Position tablet */
        gap: 10px;
    }

    .carousel-dot {
        width: 10px; /* Taille tablet */
        height: 10px;
    }

    /* Cards Progressive Enhancement - Tablet */
    .service-card {
        padding: 32px 28px; /* Tablet: augmentation modérée */
    }

    .tech-item {
        padding: 28px; /* Tablet: espace confortable */
    }

    .metric-item {
        padding: 40px 28px; /* Tablet: plus d'espace */
    }

    .contact-form {
        padding: 40px; /* Tablet: espace généreux */
    }
}

/* Desktop (1024px+) */
@media (min-width: 1024px) {
    /* Hero Desktop Enhancement */
    .hero {
        padding: 140px 5% 70px; /* Desktop: retour padding généreux */
    }

    .hero-content {
        gap: 50px; /* Desktop: espace confortable */
    }

    .minimal-badge {
        margin-bottom: 35px;
    }

    .hero-text {
        margin-bottom: 24px;
    }

    .hero-description {
        margin-bottom: 40px;
    }

    /* Variables de section desktop */
    :root {
        --section-padding: var(--section-padding-desktop);
    }

    /* Carousel Desktop Enhancement */
    .carousel__container {
        min-height: 550px; /* Plus de hauteur sur desktop */
    }

    .carousel__slide {
        min-height: 550px; /* S'adapte au container */
    }

    .slide__content {
        gap: 25px; /* Desktop: gap réduit pour espacement harmonieux */
        padding: 25px 50px 40px 50px; /* Desktop: espace bas contrôlé */
    }

    .chart__title {
        font-size: 24px;
        padding-left: 20px;
    }

    .chart__container {
        height: 320px; /* Plus haut sur desktop */
    }

    .chart__description {
        margin-bottom: 20px; /* Desktop: espace optimisé avant 2 colonnes */
    }

    /* Cards Progressive Enhancement - Desktop */
    .service-card {
        padding: 36px 32px; /* Desktop: espace généreux */
    }

    .tech-item {
        padding: 32px; /* Desktop: espace confortable */
    }

    .metric-item {
        padding: 45px 32px; /* Desktop: espace optimal */
    }

    .contact-form {
        padding: 45px; /* Desktop: espace premium */
    }
}

/* Large Desktop (1200px+) */
@media (min-width: 1200px) {
    /* Hero Large Desktop - Layout 2 colonnes */
    .hero {
        padding: 160px 5% 80px; /* Large Desktop: padding maximal */
    }

    .hero-content {
        grid-template-columns: 1fr 1fr; /* Activation 2 colonnes */
        gap: 60px; /* Large Desktop: gap maximal */
    }

    .hero-visual {
        display: block; /* Réactiver la visualisation 3D sur grand écran */
    }

    .minimal-badge {
        margin-bottom: 40px;
    }

    .hero-text {
        margin-bottom: 28px;
    }

    .hero-description {
        margin-bottom: 48px;
    }

    /* Variables de section XL */
    :root {
        --section-padding: var(--section-padding-xl);
    }

    /* Carousel Large Desktop Enhancement */
    .carousel__container {
        min-height: 600px; /* Hauteur maximale desktop */
        /* Retour au padding-bottom pour layout 2 colonnes */
        padding-bottom: 50px; /* Espace fixe en bas pour 2 colonnes */
    }

    .carousel__slide {
        min-height: 600px; /* S'adapte au container */
    }

    .slide__content {
        grid-template-columns: 1.5fr 1fr; /* Retour aux 2 colonnes sur grand écran */
        gap: 35px; /* Large Desktop: gap optimal pour 2 colonnes */
        padding: 25px 60px 35px 60px; /* Large Desktop: espace bas minimal */
        align-items: center; /* Centrage vertical en 2 colonnes */
    }

    .chart__title {
        font-size: 24px;
        margin-bottom: 15px;
    }

    .chart__container {
        height: 350px; /* Hauteur desktop complète */
    }

    .chart__description {
        margin-bottom: 15px; /* Large Desktop: espace minimal car 2 colonnes */
    }

    .carousel-indicators {
        bottom: 20px; /* Position desktop originale */
        gap: 12px; /* Espacement desktop */
    }

    .carousel-dot {
        width: 12px; /* Taille desktop */
        height: 12px;
    }

    /* Cards Progressive Enhancement - Large Desktop */
    .service-card {
        padding: 40px 36px; /* Large Desktop: espace maximal */
    }

    .tech-item {
        padding: 36px; /* Large Desktop: espace premium */
    }

    .metric-item {
        padding: 50px 36px; /* Large Desktop: espace luxueux */
    }

    .contact-form {
        padding: 50px; /* Large Desktop: espace premium */
    }
}

/* ===== Fin de la Refonte Responsive Mobile-First ===== */

/* Nettoyage effectué - tous les styles intégrés dans la logique Mobile-First ci-dessus */
    }

}

/* Section supprimée - styles intégrés dans Mobile-First base et 480px+ */

/* Floating Theme Switcher - Below header */
.floating-theme-switcher {
    display: none; /* Masqué - theme switcher intégré dans nav */
    position: fixed;
    top: 95px; /* Adjusted for smaller header */
    right: 40px;
    flex-direction: row; /* Horizontal layout */
    gap: 6px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 30px;
    padding: 6px;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.1);
    z-index: 999;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body.dark-mode .floating-theme-switcher {
    background: rgba(39, 39, 42, 0.95);
    border-color: rgba(220, 38, 38, 0.1);
    box-shadow: 0 3px 15px rgba(220, 38, 38, 0.15);
}

.floating-theme-switcher:hover {
    transform: scale(1.02);
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.15);
}

body.dark-mode .floating-theme-switcher:hover {
    box-shadow: 0 3px 15px rgba(220, 38, 38, 0.25);
}

.floating-theme-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid transparent;
    background: transparent;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.floating-theme-btn:hover {
    background: rgba(0, 0, 0, 0.05);
    transform: rotate(15deg) scale(1.1);
}

body.dark-mode .floating-theme-btn:hover {
    background: rgba(220, 38, 38, 0.1);
}

.floating-theme-btn.active {
    background: var(--red-dark);
    color: white;
    border-color: var(--red-dark);
    animation: pulse-glow 2s infinite;
}

body.dark-mode .floating-theme-btn.active {
    background: var(--red-light);
    border-color: var(--red-light);
    animation: pulse-glow-dark 2s infinite;
}

@keyframes pulse-glow {
    0% {
        box-shadow: 0 0 0 0 rgba(220, 38, 38, 0.4);
    }
    50% {
        box-shadow: 0 0 0 6px rgba(220, 38, 38, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(220, 38, 38, 0);
    }
}

@keyframes pulse-glow-dark {
    0% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
    }
    50% {
        box-shadow: 0 0 0 6px rgba(239, 68, 68, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
    }
}

/* Responsive adjustments for floating switcher */
@media (max-width: 768px) {
    .floating-theme-switcher {
        top: 85px; /* Adjusted for smaller header */
        right: 20px;
        padding: 5px;
    }

    .floating-theme-btn {
        width: 30px;
        height: 30px;
        font-size: 15px;
    }
}