:root {
    --primary: #0099CC;      
    --primary-dark: #010656;  
    --primary-light: #E6F4F9;  
    --secondary: #fff700;     
    --secondary-dark: #e6e200; 
    --success: #2E7D32;
    --success-dark: #1B5E20;
    --text-dark: #222222;     
    --text-light: #666666;    
    --text-muted: #999999;
    --bg-light: #F8F9FA;      
    --white: #FFFFFF;
    --shadow: 0 5px 20px rgba(0,0,0,0.08);
    --shadow-hover: 0 10px 30px rgba(0,0,0,0.12);
    --border-radius: 12px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
    background-color: var(--white);
}

/* ===== TOPBAR ===== */
.topbar {
    background: var(--primary-dark);
    color: white;
    font-size: 0.85rem;
    padding: 0.5rem 0;
}

.topbar-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.topbar-social {
    display: flex;
    gap: 1rem;
}

.topbar-social a {
    color: rgba(255,255,255,0.8);
    transition: color 0.3s;
    font-size: 0.9rem;
    text-decoration: none;
}

.topbar-social a:hover {
    color: var(--secondary);
}

.topbar-links {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.topbar-links a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: color 0.3s;
}

.topbar-links a:hover {
    color: var(--secondary);
}

.topbar-contact {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.topbar-contact span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.topbar-contact i {
    font-size: 0.8rem;
    color: var(--secondary);
}

/* ===== TOPBAR MOBILE ===== */
.topbar-mobile {
    display: none;
    background: var(--primary-dark);
    color: white;
    padding: 0.4rem 0;
    font-size: 0.7rem;
    text-align: center;
}

.topbar-mobile .contact-info {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.topbar-mobile a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
}

.topbar-mobile a:hover {
    color: var(--secondary);
}

/* ===== HEADER ===== */
.header {
    background: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

/* ===== LOGO ===== */
.logo {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
    flex-shrink: 0;
}

.logo-image {
    width: 180px;
    height: auto;
    max-height: 80px;
    object-fit: contain;
    display: block;
    transition: transform 0.3s ease;
}

.logo-image:hover {
    transform: scale(1.02);
}

/* ===== MENU DESKTOP ===== */
.nav-menu {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    flex-wrap: wrap;
}

.nav-menu .menu-links {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.nav-menu .menu-footer {
    display: none;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    transition: color 0.3s;
    padding: 0 !important;
    border-bottom: none !important;
    width: auto !important;
    display: inline-block !important;
}

.nav-menu a:hover {
    color: var(--primary);
}

.nav-menu a i {
    display: none !important;
}

/* ===== MENU DROPDOWN (DESKTOP) ===== */
.menu-item {
    position: relative;
}

.menu-toggle-link {
    display: inline-flex !important;
    align-items: center;
    gap: 0.35rem;
    cursor: pointer;
}

/* La flèche doit toujours être visible, même si les autres <i> sont masquées */
.menu-toggle-link .dropdown-arrow {
    display: inline-block !important;
    font-size: 0.65rem !important;
    margin-left: 0.25rem;
    color: var(--text-light);
    transition: transform 0.3s ease, color 0.3s ease;
}

/* Rotation + couleur au survol du parent */
.menu-item.has-dropdown:hover .dropdown-arrow {
    transform: rotate(180deg);
    color: var(--primary);
}

/* Sous-menu : liste verticale, propre et alignée */
.dropdown {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    display: flex;
    flex-direction: column;      /* ← garantit l'empilement vertical */
    min-width: 230px;
    background: var(--white);
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
    padding: 0.5rem 0 0 0.7rem;  /* petit padding pour un look plus aéré */
    list-style: none;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
    z-index: 1000;
    overflow: hidden;
    border-top: 3px solid var(--primary);   /* petit accent visuel */
}

.menu-item.has-dropdown:hover .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Chaque élément du sous-menu occupe toute la largeur */
.dropdown a {
    display: flex !important;
    align-items: center !important;
    gap: 0.7rem;
    padding: 0.7rem 1.1rem !important;
    width: 100% !important;
    color: var(--text-dark) !important;
    font-size: 0.9rem !important;
    font-weight: 500;
    text-decoration: none !important;
    border-bottom: none !important;
    transition: background 0.2s ease, color 0.2s ease, padding-left 0.2s ease;
    white-space: nowrap;
}

.dropdown a + a {
    border-top: 1px solid #f4f4f4;   /* séparation subtile entre les items */
}

.dropdown a:hover {
    background: var(--primary-light) !important;
    color: var(--primary) !important;
    padding-left: 1.4rem !important;   /* petit glissement à droite */
}

.dropdown a i {
    color: var(--primary);
    font-size: 0.85rem;
    width: 18px;
    text-align: center;
    display: inline-block !important;
}

/* Active dans le sous-menu */
.dropdown a.active {
    background: var(--primary-light) !important;
    color: var(--primary) !important;
    font-weight: 600;
}

.dropdown a.active::after {
    display: none !important;   /* pas de barre sous les items du sous-menu */
}

/* ===== BOUTONS ===== */
.btn-primary {
    background: var(--primary);
    color: white;
    padding: 0.6rem 1.2rem;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
    display: inline-block;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    color: white;
}

.btn-secondary {
    background: var(--secondary);
    color: var(--text-dark);
    padding: 0.6rem 1.2rem;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
    display: inline-block;
}

.btn-secondary:hover {
    background: var(--secondary-dark);
    transform: translateY(-2px);
    color: var(--text-dark);
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    padding: 0.6rem 1.2rem;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    border: 2px solid var(--primary);
    transition: all 0.3s;
}

.btn-outline:hover {
    background: var(--primary);
    color: white;
}

/* ===== SELECTEUR DE LANGUE ===== */
.lang-selector {
    display: flex;
    gap: 0.3rem;
    margin-left: 0.5rem;
}

.lang-selector a {
    text-decoration: none;
    font-weight: 500;
    padding: 0.3rem 0.6rem;
    border-radius: 5px;
    font-size: 0.85rem;
}

.lang-selector a.actif {
    background: var(--primary);
    color: white;
}

.lang-selector a:not(.actif) {
    color: var(--text-light);
}

.lang-selector a:not(.actif):hover {
    color: var(--primary);
}

/* ===== MENU TOGGLE ===== */
.menu-toggle {
    display: none;
    font-size: 1.6rem;
    cursor: pointer;
    color: var(--primary);
    background: none;
    border: none;
    padding: 0.4rem;
    z-index: 1001;
    position: relative;
    line-height: 1;
}

.nav-close-btn {
    display: none !important;
}

.nav-overlay {
    display: none !important;
}

/* ===== BREADCRUMB ===== */
.breadcrumb-area {
    padding: 8rem 0;
    background: var(--primary-light);
}

/* ===== FOOTER ===== */
.footer {
    background: var(--primary-dark);
    color: white;
    margin-top: 4rem;
    padding: 3rem 2rem 1rem;
}

.footer-container {
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.footer-section h3 {
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.footer-section p, .footer-section a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    line-height: 1.8;
}

.footer-section a:hover {
    color: var(--secondary);
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-links a {
    width: 35px;
    height: 35px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    color: white;
    text-decoration: none;
}

.social-links a:hover {
    background: var(--secondary);
    transform: translateY(-3px);
    color: var(--text-dark);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    margin-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 0.8rem;
}

/* ===== BACK TO TOP ===== */
.back-to-top-wrapper {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 999;
}

.back-to-top-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
}

.back-to-top-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-3px);
}

.back-to-top-btn svg {
    width: 20px;
    height: 20px;
}

/* ===== PRELOADER ===== */
#loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: white;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
}

#loading-center {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
}

#loading-center-absolute {
    position: relative;
}

.tp-preloader-logo {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tp-preloader-circle {
    position: relative;
}

.tp-preloader-circle svg {
    animation: tp-preloader-rotate 2s linear infinite;
}

.tp-preloader-circle svg circle:last-child {
    stroke-dasharray: 800;
    stroke-dashoffset: 800;
    animation: tp-preloader-dash 1.5s ease-in-out infinite;
}

@keyframes tp-preloader-rotate {
    100% {
        transform: rotate(360deg);
    }
}

@keyframes tp-preloader-dash {
    0% {
        stroke-dashoffset: 800;
    }
    50% {
        stroke-dashoffset: 200;
    }
    100% {
        stroke-dashoffset: 800;
    }
}

.tp-preloader-subtitle {
    text-align: center;
    margin-top: 1rem;
    font-size: 0.9rem;
    color: var(--text-muted);
    letter-spacing: 2px;
}

/* ===== ACTIVE MENU ===== */
.nav-menu a.active {
    color: var(--primary);
    position: relative;
}

.nav-menu a.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--primary);
    border-radius: 2px;
}

.nav-menu a.active-btn {
    background: var(--secondary-dark);
    color: var(--text-dark);
}

/* ===== CLASSES UTILITAIRES ===== */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section {
    padding: 4rem 0;
}

.section-title {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 2.5rem;
    color: var(--primary-dark);
}

.section-subtitle {
    text-align: center;
    color: var(--text-light);
    margin-bottom: 3rem;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.card {
    background: var(--white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s, box-shadow 0.3s;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.card-content {
    padding: 1.5rem;
}

.card-title {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--primary-dark);
}

/* ======================================== */
/* ===== RESPONSIVE ===== */
/* ======================================== */

/* Tablette */
@media (max-width: 1024px) {
    .logo-image {
        width: 140px;
        max-height: 65px;
    }
    
    .nav-menu {
        gap: 1rem;
    }
}

@media (max-width: 992px) {
    .logo-image {
        width: 120px;
        max-height: 55px;
    }
}

/* ===== MOBILE ===== */
@media (max-width: 768px) {
    /* Logo */
    .logo-image {
        width: 100px;
        max-height: 45px;
    }
    
    .logo {
        gap: 10px;
    }

    /* Topbar */
    .topbar {
        display: none !important;
    }

    .topbar-mobile {
        display: block !important;
    }

    /* Menu Toggle */
    .menu-toggle {
        display: block !important;
    }

    /* Overlay */
    .nav-overlay {
        display: none !important;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 999;
        opacity: 0;
        transition: opacity 0.3s ease;
    }

    .nav-overlay.active {
        display: block !important;
        opacity: 1;
    }

    /* Nav container */
    .nav-container {
        position: relative;
        padding: 0.8rem 1rem;
    }

    /* Menu mobile slide-in */
    .nav-menu {
        position: fixed !important;
        top: 0;
        right: -320px;
        width: 300px;
        height: 100vh;
        background: var(--white);
        flex-direction: column !important;
        padding: 1.5rem 1.5rem 1rem !important;
        gap: 0 !important;
        overflow-y: auto;
        overflow-x: hidden;
        z-index: 1000;
        transition: right 0.3s ease;
        box-shadow: -5px 0 30px rgba(0, 0, 0, 0.15);
        display: flex !important;
        align-items: stretch !important;
        padding-top: 4rem !important;
        margin: 0 !important;
        flex-wrap: nowrap !important;
    }

    .nav-menu.active {
        right: 0;
    }

    /* Liens du menu mobile */
    .nav-menu .menu-links {
        flex: 1;
        display: flex;
        flex-direction: column;
        gap: 0.2rem;
        overflow-y: auto;
    }

    .nav-menu .menu-links a {
        padding: 0.7rem 0.8rem !important;
        border-bottom: 1px solid #f0f0f0 !important;
        font-size: 0.95rem !important;
        width: 100% !important;
        display: block !important;
        color: var(--text-dark) !important;
        background: transparent !important;
        border-radius: 0 !important;
        text-decoration: none !important;
    }

    .nav-menu .menu-links a:last-child {
        border-bottom: none !important;
    }

    .nav-menu .menu-links a.active::after {
        bottom: 2px;
    }

    .nav-menu .menu-links a:hover {
        color: var(--primary) !important;
        background: var(--primary-light) !important;
        border-radius: 8px !important;
    }

    .nav-menu .menu-links a i {
        display: inline-block !important;
        width: 24px;
        margin-right: 0.5rem;
        text-align: center;
        color: var(--primary);
    }

    /* Sélecteur de langue mobile */
    .nav-menu .lang-selector {
        margin-left: 0 !important;
        padding: 0.7rem 0.8rem !important;
        border-bottom: 1px solid #f0f0f0 !important;
        display: flex !important;
        gap: 0.8rem !important;
        align-items: center;
    }

    .nav-menu .lang-selector a {
        border-bottom: none !important;
        padding: 0.3rem 0.8rem !important;
        width: auto !important;
        font-size: 0.85rem !important;
        border-radius: 5px !important;
    }

    .nav-menu .lang-selector a.actif {
        background: var(--primary);
        color: white !important;
    }

    .nav-menu .lang-selector a:hover {
        background: var(--primary-light) !important;
    }

    /* Pied du menu avec bouton Inscription */
    .nav-menu .menu-footer {
        margin-top: auto;
        padding-top: 0.8rem;
        border-top: 1px solid #f0f0f0;
        width: 100%;
        display: block !important;
    }

    .nav-menu .btn-secondary {
        display: block !important;
        width: 100% !important;
        text-align: center !important;
        padding: 0.8rem !important;
        background: var(--primary) !important;
        color: white !important;
        border-radius: 30px !important;
        font-weight: 600 !important;
        font-size: 0.95rem !important;
        border: none !important;
        cursor: pointer !important;
        transition: all 0.3s ease !important;
        text-decoration: none !important;
    }

    .nav-menu .btn-secondary:hover {
        background: var(--primary-dark) !important;
        transform: translateY(-2px);
        box-shadow: 0 4px 15px rgba(0, 153, 204, 0.3);
    }

    .nav-menu .btn-secondary i {
        margin-right: 0.5rem;
    }

    .btn-hero {
        font-size: 0.95rem !important;
        padding: 0.8rem 1.5rem !important;
        width: 100%;
        text-align: center;
    }

    .btn-hero {
            font-size: 0.85rem !important;
            padding: 0.7rem 1rem !important;
        }

    /* Bouton de fermeture */
    .nav-close-btn {
        position: absolute;
        top: 0.8rem;
        right: 0.8rem;
        font-size: 1.5rem;
        background: none;
        border: none;
        color: var(--text-dark);
        cursor: pointer;
        padding: 0.5rem;
        transition: transform 0.3s;
        z-index: 1001;
        display: block !important;
        line-height: 1;
    }

    .nav-close-btn:hover {
        transform: rotate(90deg);
    }

    /* Animation d'entrée des liens */
    .nav-menu.active .menu-links a {
        animation: slideInMenu 0.3s ease forwards;
        opacity: 0;
    }

    .nav-menu.active .menu-links a:nth-child(1) { animation-delay: 0.05s; }
    .nav-menu.active .menu-links a:nth-child(2) { animation-delay: 0.10s; }
    .nav-menu.active .menu-links a:nth-child(3) { animation-delay: 0.15s; }
    .nav-menu.active .menu-links a:nth-child(4) { animation-delay: 0.20s; }
    .nav-menu.active .menu-links a:nth-child(5) { animation-delay: 0.25s; }
    .nav-menu.active .menu-links a:nth-child(6) { animation-delay: 0.30s; }
    .nav-menu.active .menu-links a:nth-child(7) { animation-delay: 0.35s; }
    .nav-menu.active .lang-selector { animation-delay: 0.40s; }
    .nav-menu.active .menu-footer { animation-delay: 0.45s; }

    @keyframes slideInMenu {
        0% {
            opacity: 0;
            transform: translateX(20px);
        }
        100% {
            opacity: 1;
            transform: translateX(0);
        }
    }

    /* Empêcher le scroll horizontal */
    body.menu-open {
        overflow: hidden !important;
        position: fixed !important;
        width: 100% !important;
    }

    /* Active menu mobile */
    .nav-menu a.active::after {
        bottom: 2px;
    }

    .dropdown {
    position: static !important;
    display: flex !important;
    flex-direction: column !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
    box-shadow: none !important;
    background: var(--primary-light) !important;
    border-radius: 0 !important;
    border-top: none !important;
    padding: 0 !important;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
    margin-top: 0 !important;
    width: 100% !important;
}

.menu-item.has-dropdown.open .dropdown {
    max-height: 500px;
}

.dropdown a {
    padding: 0.6rem 0.8rem 0.6rem 2.5rem !important;
    font-size: 0.85rem !important;
    background: transparent !important;
    border-top: none !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05) !important;
}

.dropdown a:last-child {
    border-bottom: none !important;
}

.dropdown a:hover {
    background: rgba(0, 153, 204, 0.1) !important;
    padding-left: 2.7rem !important;
}

}

/* ===== DESKTOP (écrans > 768px) ===== */
@media (min-width: 769px) {
    .nav-menu {
        display: flex !important;
        position: static !important;
        width: auto !important;
        height: auto !important;
        background: transparent !important;
        flex-direction: row !important;
        padding: 0 !important;
        gap: 1.5rem !important;
        overflow-y: visible !important;
        box-shadow: none !important;
        transform: none !important;
        transition: none !important;
        align-items: center !important;
        flex-wrap: wrap !important;
        overflow-x: visible !important;
    }

    .nav-menu .menu-links {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        gap: 1.5rem !important;
        flex-wrap: wrap !important;
        flex: none !important;
    }

    .nav-menu .menu-footer {
        display: none !important;
    }

    .nav-menu a {
        padding: 0 !important;
        border-bottom: none !important;
        font-size: 0.95rem !important;
        width: auto !important;
        display: inline-block !important;
        color: var(--text-dark) !important;
        background: transparent !important;
    }

    .nav-menu a i {
        display: none !important;
    }

    .nav-menu .lang-selector {
        margin-left: 0.5rem !important;
        padding: 0 !important;
        border-bottom: none !important;
        display: flex !important;
        gap: 0.3rem !important;
    }

    .nav-menu .btn-secondary {
        margin-top: 0 !important;
        text-align: center !important;
        padding: 0.6rem 1.2rem !important;
        width: auto !important;
        display: inline-block !important;
    }

    .nav-close-btn {
        display: none !important;
    }

    .nav-overlay {
        display: none !important;
    }

    .menu-toggle {
        display: none !important;
    }

    .topbar-mobile {
        display: none !important;
    }

    .topbar {
        display: block !important;
    }
}

/* ===== TRÈS PETIT MOBILE ===== */
@media (max-width: 576px) {
    .logo-image {
        width: 80px;
        max-height: 38px;
    }
}

@media (max-width: 400px) {
    .logo-image {
        width: 65px;
        max-height: 32px;
    }
    
    .logo {
        gap: 8px;
    }
}

/* ===== BOUTONS DE LANGUE ===== */
.lang-selector {
    display: flex;
    gap: 0.3rem;
    align-items: center;
}

.lang-btn {
    background: none;
    border: none;
    padding: 0.3rem 0.6rem;
    border-radius: 5px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    color: var(--text-light);
    transition: all 0.3s;
    font-family: inherit;
}

.lang-btn:hover:not(:disabled) {
    color: var(--primary);
    background: var(--primary-light);
}

.lang-btn.actif {
    background: var(--primary);
    color: white;
}

.lang-btn:disabled {
    cursor: default;
    opacity: 0.8;
}

/* ===== BOUTON INSCRIPTION DESKTOP ===== */
.inscription-desktop {
    display: inline-block !important;
}

/* Cache le bouton inscription du footer sur desktop */
@media (min-width: 769px) {
    .menu-footer {
        display: none !important;
    }
}

/* Cache le bouton inscription desktop sur mobile */
@media (max-width: 768px) {
    .inscription-desktop {
        display: none !important;
    }
}

