/* public/assets/css/style.css */

:root {
    /* Strict Branding Palette */
    --primary-color: #47556E;
    /* Slate Blue */
    --secondary-color: #0C121D;
    /* Dark Navy/Black - Accent */
    --accent-color: #0C121D;
    --text-color: #0C121D;
    --text-light: #64748B;
    --bg-color: #FFFFFF;
    --white: #FFFFFF;

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #47556E 0%, #2D3748 100%);

    /* Typography */
    --font-main: 'Barlow', sans-serif;

    /* Spacing & Layout */
    --container-width: 1280px;
    --header-height: 90px;
    --radius-sm: 4px;
    --radius-md: 6px;
    --radius-lg: 10px;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Reset & Base */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-main);
    color: var(--text-color);
    background-color: var(--bg-color);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    position: relative;
    width: 100%;
    max-width: 100vw;
    margin: 0;
    padding: 0;
}

/* Smooth content transitions */
main {
    opacity: 1;
    transition: opacity 0.2s ease-in-out;
    will-change: opacity;
}

html {
    overflow-x: hidden;
    max-width: 100vw;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
}

/* Typography Utilities */
h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--primary-color);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 {
    font-size: 3.5rem;
    letter-spacing: -0.02em;
}

h2 {
    font-size: 2.5rem;
    letter-spacing: -0.01em;
}

h3 {
    font-size: 1.5rem;
}

.text-gold {
    color: var(--secondary-color);
}

.text-center {
    text-align: center;
}

.mb-lg {
    margin-bottom: 3rem;
}

/* Header & Nav - Apple Style */
.site-header {
    background-color: rgba(255, 255, 255, 0.98);
    /* Less transparent for clarity */
    backdrop-filter: blur(10px);
    height: 120px;
    /* Increased height for bigger logo */
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.08);
    /* Softer shadow */
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.site-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo a {
    display: flex;
    align-items: center;
}

.logo img {
    height: 100px;
    /* Enlarged Logo */
    width: auto;
    border-radius: 50%;
    object-fit: contain;
}

.main-nav ul {
    display: flex;
    gap: 32px;
    align-items: center;
}

.header-contact {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-left: 24px;
    border-left: 1px solid #e2e8f0;
    /* Divider like OG */
}

.contact-icon svg {
    width: 32px;
    height: 32px;
    color: var(--primary-color);
}

.contact-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
    line-height: 1.2;
}

.contact-label {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--primary-color);
}

.contact-phone {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-light);
    /* Or maybe darker */
}



.main-nav a {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 0.9rem;
    position: relative;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 8px 0;
}

.main-nav a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--secondary-color);
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.main-nav a:hover::after,
.main-nav a.active::after {
    width: 100%;
}

.main-nav a:hover,
.main-nav a.active {
    color: var(--secondary-color);
}

/* Mega Menu Styles */
.main-nav .has-megamenu {
    position: relative;
}

.main-nav .has-megamenu>a {
    display: flex;
    align-items: center;
    gap: 6px;
}

.main-nav .dropdown-arrow {
    width: 14px;
    height: 14px;
    transition: transform 0.3s ease;
}

.main-nav .has-megamenu:hover .dropdown-arrow {
    transform: rotate(180deg);
}

.main-nav .megamenu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-10px);
    background: white;
    min-width: 900px;
    padding: 32px;
    margin-top: 8px;
    border-radius: var(--radius-md);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 100;
}

.main-nav .has-megamenu:hover .megamenu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.main-nav .megamenu-content {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 32px;
}

.main-nav .megamenu-column {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.main-nav .megamenu-title {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary-color);
    width: 100%;
    text-align: left;
}

.main-nav .megamenu-title a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.2s ease;
}

.main-nav .megamenu-title a:hover {
    color: var(--secondary-color);
}

.main-nav .megamenu-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
}

.main-nav .megamenu-list li {
    margin: 0;
    width: 100%;
}

.main-nav .megamenu-list a {
    display: block;
    padding: 8px 0;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-color);
    text-transform: none;
    letter-spacing: 0;
    transition: all 0.2s ease;
    text-align: left;
}

.main-nav .megamenu-list a::after {
    display: none;
}

.main-nav .megamenu-list a:hover {
    color: var(--primary-color);
    padding-left: 12px;
}

/* Nouveau Badge - for new menu items */
.nouveau-badge {
    display: inline-block;
    background: #131466;
    color: white;
    font-size: 0.55rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 7px;
    border-radius: 10px;
    line-height: 1;
    vertical-align: middle;
    animation: pulse-badge 2s ease-in-out infinite;
}

@keyframes pulse-badge {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(19, 20, 102, 0.4);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 8px 2px rgba(19, 20, 102, 0.3);
    }
}

/* Mobile nouveau badge adjustments */
.mobile-nav .nouveau-badge {
    font-size: 0.5rem;
    padding: 2px 6px;
}

/* Hero Slider - Polished */
.hero-slider {
    position: relative;
    height: 750px;
    /* Slightly more compact */
    overflow: hidden;
    background: var(--primary-color);
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1.2s cubic-bezier(0.4, 0, 0.2, 1);
    /* Smoother transition */
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    z-index: 1;
}

/* Fix for Flexbox Container Shrinking */
.slide .container {
    width: 100%;
}

.slide.active {
    opacity: 1;
    z-index: 2;
}

.slide::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, rgba(15, 23, 42, 0.8) 0%, rgba(15, 23, 42, 0.4) 60%, transparent 100%);
    /* Gradient overlay for text readability */
    z-index: 1;
}

.slide-content {
    position: relative;
    z-index: 3;
    max-width: 700px;
    /* Constrain width for better readability */
    padding: 0 24px;
    margin-left: 0;
    /* Strict left alignment */
    width: 100%;
    transform: translateY(30px);
    opacity: 0;
    transition: all 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) 0.4s;
    /* Pop effect */
}

.slide.active .slide-content {
    transform: translateY(0);
    opacity: 1;
}

.slide h1 {
    color: var(--white);
    font-size: 3.5rem;
    /* Reduced from 4.5rem for elegance */
    line-height: 1.1;
    margin-bottom: 24px;
    text-transform: uppercase;
    font-weight: 800;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.slide p {
    font-size: 1.25rem;
    color: #f1f5f9;
    margin-bottom: 40px;
    max-width: 600px;
    line-height: 1.6;
    font-weight: 400;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

.slide-subtitle {
    display: inline-block;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 10px 20px;
    border-radius: 4px;
    color: var(--white);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 24px;
    font-size: 0.85rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 16px 36px;
    background: #131466;
    /* Updated primary blue */
    color: var(--white);
    font-weight: 700;
    border-radius: var(--radius-sm);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.9rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2);
    background: #0a0b4d;
    /* Darker shade for hover */
}

/* ... existing code ... */

.advantage-card h3 {
    font-size: 1.25rem;
    /* Increased size */
    font-weight: 700;
    /* Bolder */
    color: var(--primary-color);
    margin-bottom: 12px;
}

/* ... existing code ... */

.services-section .section-title {
    color: #FFFFFF !important;
    /* Force white */
}

/* ... existing code ... */

/* Floating Icon - Centered Overlap */
.service-icon {
    width: 60px;
    height: 60px;
    background: #131466;
    /* Updated primary blue */
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translateX(-50%);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    color: var(--white);
    transition: all 0.4s ease;
    z-index: 2;
    border: none;
    /* Remove border */
}

.btn-outline {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    color: var(--white);
}

.btn-outline:hover {
    background: var(--white);
    color: var(--primary-color);
    border-color: var(--white);
}

/* Section Styling */
section {
    padding: 70px 0;
}

.services-section .section-title {
    color: #FFFFFF !important;
    /* Force white */
}

.section-title span {
    display: block;
    color: var(--secondary-color);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.1em;
    margin-bottom: 12px;
}

/* Cards */
.card {
    background: var(--white);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-hover);
    border-color: var(--secondary-color);
}

.card-body {
    padding: 32px;
}

.card h3 {
    font-size: 1.25rem;
    margin-bottom: 16px;
}

.card p {
    color: var(--text-light);
    margin-bottom: 24px;
    font-size: 0.95rem;
}

.card-link {
    color: var(--secondary-color);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.card-link:hover {
    gap: 12px;
}

/* Forms */
.form-wrapper {
    background: var(--white);
    padding: 48px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--primary-color);
    font-size: 0.9rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #E2E8F0;
    border-radius: var(--radius-sm);
    font-family: var(--font-main);
    font-size: 1rem;
    transition: all 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(12, 18, 29, 0.1);
}

/* Footer */
.site-footer {
    background-color: #111827;
    color: var(--white);
    padding: 0;
    margin-top: 0;
}

.footer-col h3 {
    color: var(--white);
    font-size: 1.1rem;
    margin-bottom: 24px;
}

.footer-col p,
.footer-col a {
    color: #94A3B8;
    margin-bottom: 12px;
    display: block;
}

.footer-col a:hover {
    color: var(--white);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    margin-top: 64px;
    padding-top: 32px;
    color: #64748B;
    font-size: 0.9rem;
}

/* About Section Styles */
.section-subtitle {
    display: inline-block;
    color: #0054ff;
    font-weight: 800;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 16px;
    position: relative;
    padding-left: 0;
}

/* "Popping" effect for subtitle */
.section-subtitle::before {
    content: '';
    display: inline-block;
    width: 24px;
    height: 3px;
    background: #0054ff;
    /* Gold/Accent */
    vertical-align: middle;
    margin-right: 12px;
    border-radius: 2px;
}

.section-title-left {
    font-size: 2.25rem;
    line-height: 1.2;
    margin-bottom: 24px;
    color: #000000;
    font-weight: 800;
}

.btn-text {
    display: inline-block;
    color: var(--secondary-color);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.9rem;
    margin-top: 16px;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

.btn-text:hover {
    border-bottom-color: var(--secondary-color);
    transform: translateX(5px);
}

/* Collage Grid */
.about-collage {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    height: 500px;
}

.collage-col {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.collage-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    transition: transform 0.4s ease;
}

.collage-img:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.collage-img.tall {
    height: 100%;
}

/* Advantages Section */
.advantages-section {
    background-color: #F8FAFC;
    padding: 10px 0 50px 0;
}

.advantages-section .section-header {
    margin-bottom: 40px;
}

.advantages-section .section-subtitle {
    margin-bottom: 12px;
}

.advantages-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 30px;
}

@media (max-width: 992px) {
    .advantages-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .advantages-grid {
        grid-template-columns: 1fr;
    }
}

.advantage-header {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    padding-right: 20px;
}

.advantage-card {
    background: var(--white);
    padding: 40px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.03);
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.advantage-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
    border-color: rgba(12, 18, 29, 0.1);
}

.advantage-icon {
    width: 48px;
    height: 48px;
    margin-bottom: 24px;
    color: var(--primary-color);
}

.advantage-card h3 {
    font-size: 1.35rem;
    /* Increased size as requested */
    font-weight: 700;
    color: #000000;
    /* Black color */
    margin-bottom: 12px;
}

.advantage-card p {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 0;
}

/* Services Section (Dark Theme) */
.services-section {
    background-color: #111827;
    /* Darker Navy */
    color: var(--white);
    overflow: hidden;
    /* Hide scrollbar overflow */
}

.services-section .section-title {
    color: #FFFFFF !important;
    /* Force white */
}

/* Fix for "Nos Formations" Subtitle - White with Dash */
.services-section .section-subtitle {
    color: var(--white) !important;
    position: relative;
    display: inline-block;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 16px;
}

.services-section .section-subtitle::before {
    background: #F59E0B;
    /* Gold for visibility on dark bg */
}

.services-carousel-wrapper {
    margin: 0 -24px;
    /* Bleed to edges on mobile */
    padding: 0 24px;
}

.services-carousel {
    display: flex;
    gap: 30px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 40px;
    /* Space for scrollbar/shadow */
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    /* Firefox */
    scroll-behavior: smooth;
}

.services-carousel::-webkit-scrollbar {
    display: none;
    /* Chrome/Safari */
}

/* Service Card - OG Design (Dark, Centered Icon, Uppercase) */
.service-card {
    /* Show 3 items: (100% - (2 * gap)) / 3 */
    flex: 0 0 calc((100% - 60px) / 3);
    max-width: calc((100% - 60px) / 3);
    scroll-snap-align: start;
    background: #111827;
    /* Dark Background */
    border-radius: var(--radius-md);
    overflow: visible;
    /* Allow icon overlap */
    position: relative;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
    margin-top: 30px;
    /* Space for top icon overlap */
}

/* Responsive: 2 items on tablet */
@media (max-width: 992px) {
    .service-card {
        flex: 0 0 calc((100% - 30px) / 2);
    }
}

/* Responsive: 1 item on mobile */
@media (max-width: 768px) {
    .service-card {
        flex: 0 0 100%;
        max-width: 100%;
        min-width: 100%;
        /* Force single column */
    }
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: #F59E0B;
    /* Gold border on hover */
}

/* ... existing code ... */
.service-img {
    height: 200px;
    width: 100%;
    object-fit: cover;
}

.service-content {
    padding: 30px;
    padding-top: 50px;
    /* Space for icon */
    text-align: center;
}

.service-content h3 {
    color: var(--white);
    font-size: 1.1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 16px;
}

.service-content p {
    color: #94A3B8;
    font-size: 0.9rem;
    margin-bottom: 24px;
}



/* Custom About Section Layout - Desktop First */
.about-custom-row {
    display: flex;
    flex-wrap: wrap;
    gap: 60px;
    align-items: center;
}

.about-col-text {
    flex: 1;
    min-width: 300px;
}

.about-col-img {
    flex: 1;
    min-width: 300px;
}

/* About Collage */
.about-collage {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    height: 500px;
    /* Restored fixed height for desktop collage effect */
}

/* =========================================
   RESPONSIVE & MOBILE STLES
   ========================================= */

/* Utilities for visibility */
.d-none {
    display: none !important;
}

@media (min-width: 992px) {
    .d-lg-block {
        display: block !important;
    }

    .d-lg-flex {
        display: flex !important;
    }

    .d-lg-none {
        display: none !important;
    }
}

/* Mobile Menu Toggle (Hamburger) */
.mobile-menu-toggle {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1001;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    /* Updated for outline style box if needed, currently cleaner bars */
    width: 44px;
    height: 44px;
    border: 1px solid var(--primary-color);
    border-radius: var(--radius-sm);
}

.mobile-menu-toggle .bar {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--primary-color);
    transition: all 0.3s ease;
}

/* Menu Overlay */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: #111827;
    /* Dark Theme */
    z-index: 2000;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding: 80px 24px 40px;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-menu-overlay.active {
    transform: translateX(0);
}

/* Close Button (X) */
.mobile-menu-close {
    position: absolute;
    top: 24px;
    right: 24px;
    background: transparent;
    border: none;
    color: var(--white);
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
}

/* Mobile Nav Links */
.mobile-nav ul {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.mobile-nav a {
    color: var(--white);
    font-size: 1.25rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 16px;
    display: block;
}

.mobile-nav a:hover {
    color: #F59E0B;
    border-color: #F59E0B;
}

/* Mobile Submenu Styles */
.mobile-nav .has-submenu>.submenu-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

.mobile-nav .submenu-arrow {
    width: 20px;
    height: 20px;
    transition: transform 0.3s ease;
}

.mobile-nav .has-submenu.active .submenu-arrow {
    transform: rotate(180deg);
}

.mobile-nav .submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    padding-left: 20px;
}

.mobile-nav .has-submenu.active .submenu {
    max-height: 500px;
    margin-top: 16px;
}

.mobile-nav .submenu li {
    margin-bottom: 16px;
}

.mobile-nav .submenu a {
    font-size: 1rem;
    font-weight: 500;
    text-transform: none;
    letter-spacing: 0;
    border-bottom: none;
    padding-bottom: 0;
    color: rgba(255, 255, 255, 0.8);
}

.mobile-nav .submenu a:hover {
    color: #F59E0B;
}

.mobile-contact-info .btn-outline-white {
    border: 1px solid rgba(255, 255, 255, 0.5);
    color: var(--white);
    padding: 12px;
    text-align: center;
    text-decoration: none;
    display: block;
    border-radius: var(--radius-sm);
    font-weight: 700;
}

/* General Mobile Tuning */
@media (max-width: 992px) {

    /* Typography */
    h1 {
        font-size: 2.5rem;
        /* Smaller H1 */
    }

    /* Mega Menu - Hide on tablet/mobile (use mobile menu instead) */
    .main-nav .megamenu {
        display: none;
    }
}

@media (max-width: 576px) {

    /* Very Small Screens */
    h1 {
        font-size: 1.8rem;
    }

    .hero-slider {
        height: 600px;
        /* Taller for text wrapping */
    }

    .advantages-grid {
        grid-template-columns: 1fr;
    }

    .form-wrapper {
        padding: 24px;
    }

    /* Mobile Hero Buttons - Inline Grid */
    .hero-btn-group {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 12px;
        width: 100%;
        margin-top: 16px;
    }

    .hero-btn-group .btn,
    .hero-btn-group .btn-outline {
        width: 100%;
        padding: 12px 10px;
        /* Smaller padding to fit text */
        font-size: 0.8rem;
        /* Smaller font for single line */
        white-space: nowrap;
        /* Force one line */
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

/* Default Desktop Group */
.hero-btn-group {
    display: flex;
    gap: 20px;
}



.service-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.service-card:hover .service-img img {
    transform: scale(1.1);
}

.service-content {
    padding: 40px 30px 30px;
    position: relative;
    background: #111827;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Floating Icon - Centered Overlap */
.service-icon {
    width: 60px;
    height: 60px;
    background: #131466;
    /* Updated primary blue */
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translateX(-50%);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    color: var(--white);
    transition: all 0.4s ease;
    z-index: 2;
    border: none;
    /* Remove border */
}

.service-icon svg {
    width: 32px;
    height: 32px;
}

.service-card:hover .service-icon {
    background: var(--white);
    color: #0C121D;
}

.service-content h3 {
    font-size: 1.1rem;
    font-size: 0.9rem;
    margin-bottom: 25px;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.6;
    text-align: center;
}

/* PLUS + Button */
.service-link {
    display: inline-block;
    font-weight: 800;
    text-transform: uppercase;
    font-size: 0.8rem;
    color: var(--white);
    letter-spacing: 1px;
    transition: all 0.3s ease;
    margin-top: auto;
    background: #0C121D;
    padding: 10px 20px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.service-link:hover {
    background: var(--white);
    color: #0C121D;
}

/* Services Navigation Dots */
.services-nav {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
}

.services-dot {
    width: 12px;
    height: 12px;
    background-color: rgba(255, 255, 255, 0.3);
    border-radius: 0;
    /* Square dots */
    cursor: pointer;
    transition: all 0.3s ease;
}

.services-dot.active {
    background-color: var(--secondary-color);
    /* Blue/Accent */
    transform: scale(1.2);
}

/* Slider Navigation (Hero) */
.slider-nav {
    position: absolute;
    bottom: 60px;
    left: 0;
    width: 100%;
    z-index: 10;
}

.nav-dots {
    display: flex;
    gap: 12px;
}

.dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.4);
    background: transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.dot:hover {
    border-color: var(--white);
    background: rgba(255, 255, 255, 0.2);
}

.dot.active {
    background: var(--white);
    border-color: var(--white);
    transform: scale(1.2);
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* Testimonials Section */
.testimonial-card {
    transition: all 0.3s ease;
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

/* --- Redesigned Testimonials Section (OG Style) --- */
.testimonials-section {
    padding: 100px 0;
    background: var(--white);
    overflow: hidden;
}

.testi-container {
    display: flex;
    gap: 60px;
    align-items: center;
}

@media (max-width: 992px) {
    .testi-container {
        flex-direction: column;
        gap: 40px;
    }

    /* Fix: Force 50/50 grid on mobile (same as services carousel) */
    .testi-left {
        height: auto;
        grid-template-columns: 1fr 1fr;
        /* Explicit 50/50 */
        gap: 15px;
    }

    .testi-img-tall {
        height: 100%;
        /* Let it fill the grid cell naturally */
        min-height: 300px;
        object-fit: cover;
    }

    .testi-col-stacked {
        min-width: 0;
        /* Prevent overflow */
    }

    /* Reduce font and icon size in dark card for mobile */
    .testi-card-dark {
        padding: 12px !important;
    }

    .testi-card-logo {
        height: 35px !important;
        margin-bottom: 10px !important;
    }

    .testi-card-dark h3 {
        font-size: 0.75rem !important;
        line-height: 1.5 !important;
        letter-spacing: 0 !important;
    }
}

/* Left Column: Collage + Dark Card */
/* Left Column: Grid Layout (1-2-3 Structure) */
.testi-left {
    flex: 1;
    min-width: 0;
    position: relative;
    /* Main Grid: 2 Columns */
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    height: 480px;
    /* Taller */
}

/* Col 1: Stacked (Img + Dark Card) */
.testi-col-stacked {
    display: flex;
    flex-direction: column;
    gap: 20px;
    height: 100%;
}

.testi-img-top {
    flex: 1;
    width: 100%;
    object-fit: cover;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-md);
    height: 50%;
    /* Force half height */
}

.testi-card-dark {
    flex: 1;
    background: #111827;
    /* Dark Navy */
    color: var(--white);
    padding: 30px;
    border-radius: var(--radius-sm);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    /* Align Left */
    position: relative;
    overflow: hidden;
    height: 50%;
    /* Force half height */
}

.testi-card-logo {
    display: block;
    width: auto;
    height: 60px;
    /* Logo height constraint - enlarged */
    margin-bottom: 20px;
}

.testi-card-dark h3 {
    color: var(--white);
    font-size: 1.1rem;
    line-height: 1.4;
    text-transform: uppercase;
    font-weight: 800;
    margin-bottom: 0;
    letter-spacing: 0.5px;
}

/* Col 2: Tall Image */
.testi-img-tall {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-md);
}

/* --- Footer Spacer --- */
.footer-spacer {
    height: 60px;
    /* Space between content and footer */
    background: transparent;
}

/* --- Redesigned Footer (3 Sections) --- */
.site-footer {
    color: #fff;
    font-size: 0.9rem;
}

/* 1. Contact Bar (#111827) */
.footer-contact-bar {
    background: #111827;
    padding: 30px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-contact-wrapper {
    display: grid;
    grid-template-columns: 1fr auto 1fr auto 1fr;
    align-items: center;
    gap: 30px;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
}

.footer-contact-item {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #9CA3AF;
    font-size: 0.9rem;
}

.footer-contact-item strong {
    color: #fff;
    font-weight: 700;
}

.footer-sep {
    width: 1px;
    height: 50px;
    background: rgba(255, 255, 255, 0.15);
}

.footer-icon {
    color: var(--white);
    width: 28px;
    height: 28px;
    flex-shrink: 0;
}

/* 2. Main Footer Content (#111827) */
.footer-main {
    background: #111827;
    /* Same as contact bar */
    padding: 60px 0 50px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    /* Brand is wider */
    gap: 50px;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
}

/* 3-column footer layout */
.footer-grid-3col {
    grid-template-columns: 2fr 1fr 1.5fr;
}

/* Desktop: Show simple links, hide accordion */
.footer-formations-desktop {
    display: block;
}

.footer-formations-mobile {
    display: none;
}

/* Mobile Footer Accordion Styles */
.footer-acc-category {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-acc-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    cursor: pointer;
    color: #9CA3AF;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.footer-acc-header:hover {
    color: #fff;
}

.footer-acc-icon {
    font-size: 1.2rem;
    font-weight: 300;
    color: #9CA3AF;
}

.footer-acc-submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-acc-category.open .footer-acc-submenu {
    padding-bottom: 10px;
}

.footer-acc-submenu li {
    padding: 6px 0 6px 15px;
}

.footer-acc-submenu a {
    color: #6B7280;
    font-size: 0.85rem;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-acc-submenu a:hover {
    color: #fff;
}

.footer-col h3.footer-title {
    color: #fff;
    font-size: 1rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 25px;
    letter-spacing: 1px;
}

.footer-desc {
    color: #9CA3AF;
    line-height: 1.6;
    margin-bottom: 0;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: #9CA3AF;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--white);
}

/* 3. Copyright Bar (#051F44) */
.footer-copyright {
    background: #051F44;
    /* Deep Blue from screenshot */
    padding: 25px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-copy-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-copy-text {
    color: #9CA3AF;
    font-size: 0.85rem;
}

.footer-copy-logo {
    color: #fff;
}

.footer-socials {
    display: flex;
    gap: 10px;
}

.footer-social-icon {
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.footer-social-icon:hover {
    background: var(--primary-color);
}

.footer-social-icon svg {
    width: 18px;
    height: 18px;
}

/* --- Emergency Fixes for Footer Gaps --- */
body {
    background-color: #FFFFFF;
    /* Changed to white to remove dark footer gap */
    margin: 0;
    padding: 0;
}

main {
    background-color: #FFFFFF;
    /* Keep main content white */
}

.site-footer {
    margin-top: 80px !important;
    /* White space separation */
}

.testimonials {
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
}

/* Ensure no elements between sections */
.footer-spacer {
    display: none !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Responsive Footer */
@media (max-width: 992px) {
    .footer-contact-wrapper {
        grid-template-columns: 1fr;
        gap: 20px;
        text-align: center;
    }

    .footer-sep {
        display: none;
    }

    .footer-contact-item {
        justify-content: center;
        flex-direction: column;
        gap: 8px;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 40px;
    }

    /* 3-column becomes 2-column on tablet */
    .footer-grid-3col {
        grid-template-columns: 1fr 1fr;
    }

    .footer-formations-col {
        grid-column: span 2;
    }

    .footer-contact-item {
        flex-direction: column;
    }

    /* Switch to accordion on mobile */
    .footer-formations-desktop {
        display: none;
    }

    .footer-formations-mobile {
        display: block;
    }
}

@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .footer-grid-3col {
        grid-template-columns: 1fr;
    }

    .footer-formations-col {
        grid-column: span 1;
    }

    /* Add visual separation between sections */
    .footer-col {
        padding-bottom: 30px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .footer-col:last-child {
        border-bottom: none;
        padding-bottom: 0;
    }

    .footer-copy-wrapper {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
}

/* Right Column: Content + Slider */
.testi-right {
    flex: 1;
    min-width: 0;
    position: relative;
    padding-right: 40px;
    /* Space for nav */
}

.testi-slider-wrapper {
    position: relative;
    overflow: hidden;
    min-height: 300px;
    /* Reserve space */
}

.testi-slide {
    display: none;
    /* Hidden by default */
    animation: fadeIn 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.testi-slide.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.testi-quote {
    font-size: 1.1rem;
    color: var(--text-light);
    line-height: 1.8;
    margin-bottom: 30px;
    font-weight: 400;
}

.testi-rating {
    color: var(--primary-color);
    /* Dark stars as per screenshot? Or check styling. OG screenshot shows dark stars. */
    color: #111827;
    margin-bottom: 15px;
    font-size: 1.2rem;
    letter-spacing: 2px;
}

.testi-author {
    font-weight: 800;
    text-transform: uppercase;
    color: var(--primary-color);
    font-size: 0.9rem;
    letter-spacing: 1px;
}

/* Vertical Navigation */
.testi-nav {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.testi-dot {
    width: 10px;
    height: 10px;
    background: #E2E8F0;
    border-radius: 0;
    /* Square/Rect */
    cursor: pointer;
    transition: all 0.3s ease;
}

.testi-dot.active {
    background: #111827;
    /* Dark active dot */
    transform: scale(1.2);
}

/* --- Page Hero Section --- */
.page-hero {
    background: linear-gradient(rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.2)), url('../images/formations/title-bg.jpg');
    background-size: cover;
    background-position: center;
    padding: 100px 0;
    color: #fff;
    position: relative;
    display: flex;
    align-items: center;
    text-align: left;
    /* Ensure text aligns left by default */
}

.page-hero .container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    /* Align flex items (hero-content) to the start */
    width: 100%;
}

.hero-content {
    text-align: left !important;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
}

.hero-title {
    font-size: 3rem;
    font-weight: 800;
    text-transform: uppercase;
    margin: 0 0 15px 0;
    /* Removing auto margins if any */
    letter-spacing: 1px;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.breadcrumbs {
    font-size: 0.8rem;
    color: #ffffff;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.9;
}

.breadcrumbs a {
    color: #fff;
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumbs a:hover {
    color: var(--secondary-color);
}

.breadcrumbs .separator {
    margin: 0 8px;
    color: #fff;
}

.breadcrumbs .current {
    color: #fff;
    text-decoration: none;
}

/* --- Course Grid Section --- */
.course-grid-section {
    background-color: #fff;
    padding: 80px 0;
}

.course-card {
    background: #fff;
    border-radius: var(--radius-sm);
    overflow: hidden;
    /* Subtle shadow like OG */
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin-bottom: 30px;
    border: 1px solid rgba(0, 0, 0, 0.03);
    /* Very faint border */
    display: flex;
    flex-direction: column;
}

.course-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    border-color: rgba(0, 0, 0, 0.05);
}

.course-image {
    height: 220px;
    overflow: hidden;
    background: #f3f4f6;
    position: relative;
    flex-shrink: 0;
}

.course-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.course-card:hover .course-image img {
    transform: scale(1.08);
}

.course-content {
    padding: 25px;
    /* Ample padding like OG */
    background: #fff;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.course-category {
    display: block;
    font-size: 0.7rem;
    /* Small */
    font-weight: 700;
    text-transform: uppercase;
    color: #9CA3AF;
    /* Gray text */
    margin-bottom: 10px;
    letter-spacing: 1px;
    line-height: 1;
}

.course-title {
    font-size: 1.15rem;
    font-weight: 800;
    /* Bold */
    line-height: 1.3;
    margin: 0;
    color: #111827;
    /* Black */
}

.course-title a {
    color: #111827;
    text-decoration: none;
    transition: color 0.2s ease;
}

/* Hover States for Card Content */
.course-card:hover .course-content {
    background-color: #131466;
    /* Dark Blue from screenshot */
    transition: background-color 0.3s ease;
}

.course-card:hover .course-category {
    color: rgba(255, 255, 255, 0.7);
    /* Lighter white/gray */
}

.course-card:hover .course-title,
.course-card:hover .course-title a {
    color: #ffffff;
    /* White text */
}

/* --- Sidebar Styling --- */
.sidebar {
    position: sticky;
    top: 120px;
    /* Account for header */
    z-index: 10;
}

.sidebar-widget {
    background: #fff;
    border: none;
    /* Remove border for cleaner look */
    border-radius: var(--radius-md);
    /* Slightly larger radius */
    padding: 0;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    /* Modern shadow */
}

.sidebar-nav {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* Category Headers */
.sidebar-nav .sidebar-category {
    border-bottom: 1px solid #e5e7eb;
}

.sidebar-nav .sidebar-category:last-child {
    border-bottom: none;
}

.sidebar-nav .category-title {
    display: block;
    padding: 16px 20px;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.95rem;
    background-color: #f8fafc;
    border-left: 4px solid var(--primary-color);
    transition: all 0.2s ease;
}

.sidebar-nav .category-title:hover,
.sidebar-nav .category-title.active {
    background-color: var(--primary-color);
    color: white;
}

/* Submenu Items */
.sidebar-nav .sidebar-submenu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-nav .sidebar-submenu li {
    border-bottom: 1px solid #F3F4F6;
}

.sidebar-nav .sidebar-submenu li:last-child {
    border-bottom: none;
}

.sidebar-nav .sidebar-submenu a {
    display: block;
    padding: 14px 20px 14px 32px;
    color: #4B5563;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
    border-left: 4px solid transparent;
    font-size: 0.9rem;
}

.sidebar-nav .sidebar-submenu a:hover,
.sidebar-nav .sidebar-submenu a.active {
    background-color: #F8FAFC;
    color: var(--primary-color);
    border-left-color: var(--secondary-color);
    padding-left: 36px;
}

/* --- Main Content Area --- */
.page-content {
    background-color: #F9FAFB;
    /* Light grey background for the whole section as per reference */
    padding-top: 30px;
    /* Reduced from 60px */
    padding-bottom: 30px;
    /* Reduced from 60px */
}

.formation-presentation {
    background: #fff;
    padding: 40px;
    border-radius: var(--radius-md);
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
}

.intro-text p {
    color: #374151;
    /* Darker text for readability */
    line-height: 1.8;
    margin-bottom: 24px;
    font-size: 1rem;
}

/* Add proper spacing between sections in formation pages */
.formation-presentation h4 {
    margin-top: 40px !important;
    margin-bottom: 20px !important;
}

.formation-presentation h4:first-of-type {
    margin-top: 30px !important;
}

/* --- Accordion (Kept for compatibility) --- */
.accordion-item,
.accordion-header {
    border: none;
}

.accordion-header {
    width: 100%;
    text-align: left;
    background: #fff;
    border: none;
    padding: 20px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    font-weight: 700;
    color: #111827;
    font-size: 1rem;
    transition: background-color 0.2s ease;
}

.accordion-header:hover {
    background-color: #F9FAFB;
}

.accordion-header[aria-expanded="true"] {
    color: var(--primary-color);
    background-color: #F3F4F6;
}

.accordion-header .icon {
    font-weight: 400;
    font-size: 1.2rem;
    color: #9CA3AF;
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
    background: #fff;
}

.accordion-content .inner-content {
    padding: 24px;
    color: #4B5563;
    line-height: 1.7;
    border-top: 1px solid #F3F4F6;
}

.accordion-content p {
    margin-bottom: 16px;
}

.accordion-content h5 {
    color: #111827;
    font-weight: 700;
    margin-top: 20px;
    color: #4B5563;
}

.custom-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--secondary-color);
    font-weight: bold;
}

@media (max-width: 991px) {
    .content-wrapper {
        padding-right: 0;
    }

    .sidebar {
        margin-top: 40px;
    }
}

/* --- MINIMAL GRID SYSTEM (Fix for missing Bootstrap) --- */
.row {
    display: flex;
    flex-wrap: wrap;
    margin-right: -15px;
    margin-left: -15px;
}

[class*="col-"] {
    position: relative;
    width: 100%;
    padding-right: 15px;
    padding-left: 15px;
}

.order-1 {
    order: 1;
}

.order-2 {
    order: 2;
}

@media (min-width: 768px) {
    .col-md-6 {
        flex: 0 0 50%;
        max-width: 50%;
    }
}

@media (min-width: 992px) {
    .col-lg-4 {
        flex: 0 0 33.333333%;
        max-width: 33.333333%;
    }

    .col-lg-8 {
        flex: 0 0 66.666667%;
        max-width: 66.666667%;
    }

    .order-lg-1 {
        order: 1;
    }

    .order-lg-2 {
        order: 2;
    }
}

/* =========================================
   CUSTOM LAYOUT UTILITIES (Mobile-First) - RESTORED
   ========================================= */

/* 1. Mobile Default (Stacked) */
.split-layout {
    display: flex;
    flex-direction: column;
    /* Stack by default */
    gap: 40px;
    width: 100%;
}

.split-col-text-wide,
.split-col-stats,
.split-col-half {
    width: 100%;
    flex: auto;
}

.grid-3-cols,
.grid-4-cols {
    display: grid;
    grid-template-columns: 1fr;
    /* 1 Column by default */
    gap: 30px;
}

/* 2. Desktop Overrides (Min-Width 992px) - STRICT SIDE-BY-SIDE */
@media (min-width: 992px) {
    .split-layout {
        flex-direction: row;
        /* Force side-by-side */
        align-items: center;
        gap: 60px;
    }

    .split-col-text-wide {
        flex: 1.5;
        width: auto;
    }

    .split-col-stats {
        flex: 1;
        width: auto;
    }

    .split-col-half {
        flex: 1;
        width: 50%;
        /* Force half width */
    }

    /* Grids */
    .grid-3-cols {
        grid-template-columns: repeat(3, 1fr);
    }

    .grid-4-cols {
        grid-template-columns: repeat(4, 1fr);
    }

    /* Re-apply Ordering */
    .order-1-desktop {
        order: 1;
    }

    .order-2-desktop {
        order: 2;
    }
}

/* Base Helpers */
.stats-card {
    width: 100%;
    max-width: 500px;
    /* Prevent infinite stretch */
    margin: 0 auto;
}


/* ===================================
   QUI SOMMES NOUS PAGE RESPONSIVE
   =================================== */

@media (max-width: 768px) {

    /* Two column grids become single column */
    section[style*="grid-template-columns: 2fr 1fr"],
    section[style*="grid-template-columns: 1fr 1fr"],
    div[style*="grid-template-columns: 2fr 1fr"],
    div[style*="grid-template-columns: 1fr 1fr"] {
        display: block !important;
    }

    /* Reorder facility sections on mobile */
    div[style*="order: 2"] {
        order: 0 !important;
        margin-bottom: 30px;
    }

    div[style*="order: 1"] {
        order: 0 !important;
    }

    /* Stats card full width on mobile */
    div[style*="font-size: 4rem"] {
        font-size: 3rem !important;
    }

    /* Reduce padding on mobile */
    .content-wrapper[style*="padding: 50px"] {
        padding: 30px 20px !important;
    }

    /* Images full width */
    img[style*="height: 400px"] {
        height: 250px !important;
    }
}


/* ===================================
   BACK TO TOP BUTTON
   =================================== */

.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: #131466;
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    box-shadow: 0 4px 12px rgba(19, 20, 102, 0.3);
}

.back-to-top:hover {
    background: #0f1052;
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(19, 20, 102, 0.4);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top svg {
    width: 24px;
    height: 24px;
}

@media (max-width: 768px) {
    .back-to-top {
        width: 45px;
        height: 45px;
        bottom: 20px;
        right: 20px;
    }

    .back-to-top svg {
        width: 20px;
        height: 20px;
    }
}


/* ===================================
   PAGE TRANSITIONS & SCROLL ANIMATIONS
   =================================== */

/* Scroll-triggered animations - subtle and fast */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease-out, transform 0.4s ease-out;
}

.animate-on-scroll.animate-in {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger animation for cards in grids */
.advantage-card.animate-on-scroll,
.service-card.animate-on-scroll,
.course-card.animate-on-scroll {
    transition-delay: calc(var(--animation-order, 0) * 0.08s);
}

/* Smooth hover transitions for interactive elements */
.btn,
.card,
.course-card,
.service-card,
.advantage-card,
.testimonial-card {
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

/* Link transitions */
.main-nav a,
.footer-links a,
.sidebar-nav a {
    transition: color 0.2s ease;
}

/* Smooth scroll behavior */
html {
    scroll-behavior: smooth;
}

/* Card hover lift effect - faster */
.card:hover,
.course-card:hover,
.service-card:hover,
.advantage-card:hover {
    transform: translateY(-5px);
    transition: transform 0.25s ease;
}

/* Button press effect */
.btn:active {
    transform: scale(0.98);
}

/* Image zoom on hover - smoother */
.course-image img,
.service-img img {
    transition: transform 0.4s ease;
}

.course-card:hover .course-image img,
.service-card:hover .service-img img {
    transform: scale(1.05);
}

/* Mobile menu transitions */
.mobile-menu-overlay {
    transition: transform 0.3s ease;
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    main {
        transition: none !important;
    }

    .animate-on-scroll {
        opacity: 1 !important;
        transform: none !important;
    }
}


/* Preheader Styles */
.preheader {
    background: #111827;
    color: white;
    padding: 10px 0;
    font-size: 0.9rem;
}

@media (max-width: 991px) {
    .preheader {
        display: none;
    }
}


/* Mobile padding for formation pages */
@media (max-width: 767px) {
    .formation-presentation {
        padding: 25px 20px !important;
    }

    .content-wrapper {
        padding: 25px 20px !important;
    }

    .intro-text {
        padding: 0 !important;
    }

    .intro-text p,
    .intro-text ul,
    .intro-text h2,
    .intro-text h3,
    .intro-text h4 {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
}


/* Mobile Hero Slider Fixes */
@media (max-width: 767px) {
    .hero-slider {
        height: 600px;
    }

    .slide-content {
        padding: 30px 20px;
        max-width: 100%;
    }

    .slide-subtitle {
        font-size: 0.75rem;
        padding: 6px 14px;
        margin-bottom: 12px;
    }

    .slide-content h1 {
        font-size: 34px !important;
        line-height: 40px !important;
        margin-bottom: 16px !important;
        font-weight: 800 !important;
        color: #ffffff !important;
    }

    .slide-content p {
        font-size: 0.95rem !important;
        line-height: 1.5 !important;
        margin-bottom: 24px !important;
    }

    .hero-btn-group {
        flex-direction: column;
        gap: 12px;
        width: 100%;
    }

    .hero-btn-group .btn {
        width: 100%;
        padding: 14px 20px;
        font-size: 0.95rem;
        text-align: center;
        justify-content: center;
    }

    /* Slider Navigation - Bottom Left */
    .slider-nav {
        bottom: 20px;
        left: 0;
        right: auto;
        width: auto;
    }

    .nav-dots {
        justify-content: flex-start;
        padding-left: 20px;
    }

    .nav-dots .dot {
        width: 12px;
        height: 12px;
    }
}

@media (max-width: 480px) {
    .hero-slider {
        height: 550px;
    }

    .slide-content h1 {
        font-size: 1.75rem !important;
    }

    .slide-content p {
        font-size: 0.9rem !important;
    }
}


/* Mobile spacing fixes for advantages and testimonials sections */
@media (max-width: 767px) {

    /* Reduce space between "Les Avantages" title and images */
    .advantages-section .section-header,
    .section-header {
        margin-bottom: 20px !important;
    }

    .advantages-section .section-title {
        margin-bottom: 10px !important;
        font-size: 26px !important;
        line-height: 36px !important;
        font-weight: 700 !important;
        color: rgb(12, 18, 29) !important;
    }

    .advantages-section .section-subtitle {
        margin-bottom: 8px !important;
    }

    /* Reduce space between testimonials and footer */
    .testimonials-section {
        padding-bottom: 40px !important;
    }

    .site-footer {
        margin-top: 0 !important;
    }

    /* Reduce internal spacing in advantages section */
    .advantages-section {
        padding: 20px 0 30px !important;
    }

    .advantages-grid {
        margin-top: 15px !important;
    }

    /* Reduce space between hero slider and advantages */
    .hero-slider+.advantages-section {
        margin-top: -20px !important;
    }

    /* Mobile font fix for "Bienvenue chez BLOOM FORMA SECUR..." */
    .section-title-left {
        font-size: 26px !important;
        line-height: 36px !important;
        font-weight: 700 !important;
    }
}