:root {
    /* Brand Colors */
    --primary: #123157;
    /* Navy Blue */
    --primary-light: #4da9e4;
    /* Sky Blue */
    --accent: #d65c4e;
    /* Orange/Red */
    --accent-hover: #b94538;

    /* Backgrounds */
    --bg-dark: #0f172a;
    --bg-light: #f8fafc;
    --white: #ffffff;

    /* Text */
    --text-main: #1e293b;
    --text-muted: #64748b;
    --text-light: #f8fafc;

    /* Glassmorphism */
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.2);
    --glass-shadow: 0 8px 32px 0 rgba(18, 49, 87, 0.1);

    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.3;
    }

    50% {
        transform: scale(1.1);
        opacity: 0.4;
    }
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Outfit", sans-serif;
    background: var(--bg-light);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Typography Utility */
h1,
h2,
h3,
h4 {
    color: var(--primary);
    font-weight: 700;
}

.text-white {
    color: white !important;
}

.text-accent {
    color: var(--accent) !important;
}

.text-center {
    text-align: center;
}

/* Sections */
/* Sections */
section {
    padding: 4rem 5% 4rem;
    position: relative;
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 1rem;
}

.section-subtitle {
    text-align: center;
    font-size: 1.2rem;
    color: var(--text-muted);
    max-width: 700px;
    margin: 0 auto 3rem;
}

/* Glass & Cards */
.glass {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    border-radius: 16px;
}

/* Layout Elements */
header {
    position: absolute;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 0.5rem 5%;
    background: rgba(18, 49, 87, 0.9);
    backdrop-filter: blur(5px);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 65px;
    width: auto;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 1.5rem;
}

nav a {
    text-decoration: none;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 600;
    font-size: 1.1rem;
    transition: var(--transition);
}

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

/* Hero */
.hero {
    background: radial-gradient(circle at top right, #1e4b8a, var(--primary)), url("https://www.transparenttextures.com/patterns/cubes.png");
    background-blend-mode: overlay;
    padding-top: 8rem;
    min-height: 80vh;
    display: flex;
    align-items: center;
    color: white;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 4rem;
    max-width: 1400px;
    margin: 0 auto;
}

.hero h1 {
    font-size: clamp(3rem, 6vw, 4.5rem);
    color: white;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    opacity: 0.9;
}

.hero-visual {
    position: relative;
    display: flex;
    justify-content: center;
}

.hero-image {
    width: 100%;
    max-width: 450px;
    border-radius: 30px;
    z-index: 2;
    box-shadow: 20px 20px 60px rgba(0, 0, 0, 0.3);
}

.hero-blob {
    position: absolute;
    width: 120%;
    height: 120%;
    background: radial-gradient(circle, var(--primary-light), transparent 70%);
    filter: blur(50px);
    opacity: 0.3;
    top: -10%;
    z-index: 1;
    animation: pulse 6s infinite;
}

/* Bilan Section */
.bilan-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
}

.stat-card {
    background: white;
    padding: 2.5rem;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    border-top: 5px solid var(--primary-light);
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-10px);
}

.stat-number {
    font-size: 3rem;
    font-weight: 800;
    color: var(--primary);
    display: block;
}

.stat-label {
    color: var(--text-muted);
    font-weight: 600;
}

.before-after {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-top: 2rem;
}

.ba-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
}

.colistiers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1.5rem;
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.colistier-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.colistier-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.colistier-card img {
    width: 100%;
    height: 150px;
    /* Small height for mosaic view, allowing all 47 to fit elegantly */
    object-fit: cover;
    object-position: center 10%;
    /* Focus on the head/face */
    filter: grayscale(10%);
    transition: var(--transition);
}




.ba-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.ba-label {
    position: absolute;
    bottom: 10px;
    left: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.8rem;
}

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

.news-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
}

.news-card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.news-img {
    height: 200px;
    background: #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.news-content {
    padding: 1.5rem;
}

.news-date {
    color: var(--accent);
    font-weight: 600;
    font-size: 0.85rem;
}

/* Agenda */
.agenda-list {
    max-width: 800px;
    margin: 0 auto;
}

.event-item {
    display: grid;
    grid-template-columns: 100px 1fr 150px;
    align-items: center;
    background: white;
    padding: 1.5rem;
    border-radius: 16px;
    margin-bottom: 1rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.02);
    border-left: 6px solid var(--accent);
}

.event-date {
    text-align: center;
}

.event-day {
    font-size: 1.8rem;
    font-weight: 800;
    line-height: 1;
}

.event-month {
    font-size: 0.9rem;
    text-transform: uppercase;
    color: var(--text-muted);
}

/* Forms */
.form-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 3rem;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group {
    margin-bottom: 1.2rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    font-size: 0.9rem;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
select,
textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s;
}

input:focus {
    border-color: var(--primary-light);
}

.checkbox-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 0.8rem;
    margin-top: 1rem;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

/* Chatbot Section */
.chatbot-section {
    background: #f1f5f9;
}

.chatbot-wrapper {
    max-width: 800px;
    margin: 0 auto;
    height: 600px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 24px;
    box-shadow: 0 20px 50px rgba(18, 49, 87, 0.15);
}

.chat-header {
    background: var(--primary);
    color: white;
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-messages {
    flex: 1;
    background: white;
    padding: 2rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.msg {
    max-width: 80%;
    padding: 1rem 1.2rem;
    border-radius: 18px;
    font-size: 0.95rem;
}

.msg.bot {
    background: #f1f5f9;
    align-self: flex-start;
    border-bottom-left-radius: 4px;
}

.msg.user {
    background: var(--primary);
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 4px;
    box-shadow: 0 4px 10px rgba(30, 75, 138, 0.2);
}

.suggestions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 1rem;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
}

.suggestion-btn {
    background: white;
    border: 1px solid var(--primary-light);
    color: var(--primary);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.suggestion-btn:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(30, 75, 138, 0.2);
}

.chat-input-area {
    display: flex;
    gap: 10px;
    padding: 1rem !important;
    /* Override inline styles if any */
    background: white;
    border-top: 1px solid #e2e8f0;
}

.chat-input-area input {
    flex: 1;
    border-radius: 50px;
    padding: 0.8rem 1.2rem;
    border: 1px solid #cbd5e1;
}

.chat-input-area input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(30, 75, 138, 0.1);
}

.chat-input-area button {
    border-radius: 50px;
    padding: 0 1.5rem;
}

/* Footer */
footer {
    background: var(--primary);
    color: white;
    padding: 4rem 5% 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-logo {
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: 0.2s;
}

.footer-links a:hover {
    color: white;
}

.legal-bar {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 2rem;
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    border-radius: 10px;
    font-weight: 700;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
    border: none;
}

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

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

.btn-ghost {
    background: transparent;
    border: 2px solid white;
    color: white;
}

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

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

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 6px;
    z-index: 1001;
}

.menu-toggle .bar {
    width: 30px;
    height: 3px;
    background-color: white;
    border-radius: 2px;
    transition: var(--transition);
}

/* Mobile Nav Styles */
@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }

    nav ul {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--primary);
        padding: 2rem;
        gap: 1.5rem;
        text-align: center;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
        opacity: 0;
        transition: opacity 0.3s ease, transform 0.3s ease;
        transform: translateY(-10px);
    }

    nav ul.active {
        display: flex;
        opacity: 1;
        transform: translateY(0);
    }

    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-visual {
        order: -1;
    }

    .grid-2 {
        grid-template-columns: 1fr;
    }

    .event-item {
        grid-template-columns: 80px 1fr;
    }

    .event-item .btn {
        grid-column: 1 / span 2;
        margin-top: 1rem;
    }
}

/* Interactive Map Placeholder */
.map-placeholder {
    width: 100%;
    height: 500px;
    background: #e2e8f0;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
}

.map-point {
    position: absolute;
    width: 15px;
    height: 15px;
    background: var(--accent);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px var(--accent);
}

.map-point:hover::after {
    content: attr(data-title);
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary);
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.8rem;
    white-space: nowrap;
}

/* FAQ */
.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background: white;
    margin-bottom: 1rem;
    border-radius: 12px;
    padding: 1rem 1.5rem;
    cursor: pointer;
}

.faq-item h4 {
    margin: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-answer {
    margin-top: 1rem;
    display: none;
    color: var(--text-muted);
}

.faq-item.active .faq-answer {
    display: block;
}

/* New Project Cards */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.project-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.project-card h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.4rem;
}

.project-card li {
    margin-bottom: 0.8rem;
    position: relative;
    list-style: none;
}

.project-card li::before {
    content: "•";
    color: var(--accent);
    font-weight: bold;
    display: inline-block;
    width: 1em;
    margin-left: -1em;
}

/* Agent Section Styles */
.agent-stats div {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.agent-content ul {
    list-style: none;
}

.agent-content li {
    margin-bottom: 0.8rem;
    padding-left: 0.5rem;
}

/* Animations */
.hero h1 {
    animation: fadeIn 1s ease-out;
}

.hero p {
    animation: fadeIn 1s ease-out 0.2s backwards;
}

.cta-group {
    animation: fadeIn 1s ease-out 0.4s backwards;
}

/* Comparison Slider Styles */
.comparison-container {
    max-width: 900px;
    margin: 0 auto;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
    border: 4px solid white;
}

.comparison-slider {
    position: relative;
    width: 100%;
    height: 500px;
    overflow: hidden;
    /* Ensure images don't get selected while dragging */
    user-select: none;
}

.img-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.img-wrapper img {
    display: block;
    width: 100%;
    /* Force image to be full width of container, clipping handled by wrapper width */
    height: 100%;
    object-fit: cover;
    pointer-events: none;
    max-width: none;
    /* Important to prevent image resizing when wrapper shrinks */
}

/* Fix for the 'after' image to stay static while wrapper clips it */
.img-wrapper.after img {
    width: 900px;
    /* Max width of container */
}

/* Re-thinking the CSS for the slider to be responsive without complex JS */
/* We will use the common approach:
   Container: relative
   Img1 (Before): absolute, w:100%, h:100%
   Div (AfterWrapper): absolute, w:50%, h:100%, overflow:hidden, z-index:2
   Img2 (After): absolute, w: (ContainerWidth), h:100% -> This needs to be set dynamically or roughly large enough
*/

.img-wrapper.before {
    z-index: 1;
    /* Bottom Layer */
}

.img-wrapper.after {
    z-index: 2;
    /* Top Layer */
    width: 50%;
    /* Initial state */
    border-right: 2px solid white;
    background: white;
    /* Fallback */
}

.handle {
    position: absolute;
    top: 0;
    left: 50%;
    /* Initial state matching after width */
    bottom: 0;
    width: 4px;
    background: white;
    z-index: 3;
    cursor: col-resize;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.handle-circle {
    width: 40px;
    height: 40px;
    background: var(--accent);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.8rem;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
    border: 2px solid white;
}

.label {
    position: absolute;
    top: 20px;
    padding: 0.5rem 1rem;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    font-weight: bold;
    border-radius: 4px;
    backdrop-filter: blur(4px);
    z-index: 10;
}

.before-label {
    right: 20px;
}

.after-label {
    left: 20px;
}

@media (max-width: 900px) {
    .img-wrapper.after img {
        width: 95vw;
    }

    /* Valid approximation for responsive */
}

/* Responsive height for slider */
@media (max-width: 768px) {

    .comparison-slider,
    .map-placeholder {
        height: 300px;
    }
}

.hero-image {
    animation: slideInRight 1s ease-out 0.5s backwards;
}

/* Enhanced Typography */
body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Carousel Styles */
.carousel-container {
    position: relative;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto;
    overflow: hidden;
    padding-bottom: 0;
}

.carousel-track {
    position: relative;
    /* We will simply use absolute positioning for slides or flex.
       Easier approach with vanilla JS: absolute positioning active class. */
    height: auto;
    width: 100%;
}

.carousel-slide {
    display: none;
    min-height: 85vh;
    /* Match hero height */
    width: 100%;
    position: relative;
    background-size: cover;
    background-position: center;
    animation: fadeIn 0.8s ease-out;
    padding: 8rem 5% 4rem;
    align-items: center;
    justify-content: center;
}

.carousel-slide.active {
    display: flex;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    z-index: 1001;
    /* Ensure arrows are above slides */
    transition: var(--transition);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
}

.carousel-btn.prev {
    left: 20px;
}

.carousel-btn.next {
    right: 20px;
}

.carousel-btn:hover {
    background: var(--primary);
    transform: translateY(-50%) scale(1.1);
}

/* Comparison Carousel & Slider Styles */
.comparison-carousel {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
    overflow: hidden;
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    background: #f1f5f9;
}

.comparison-slide {
    display: none;
    width: 100%;
    animation: fadeInSlide 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.comparison-slide.active {
    display: block;
}

@keyframes fadeInSlide {
    from {
        opacity: 0;
        transform: scale(0.99);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Luxury Portfolio Slider */
.portfolio-slider {
    position: relative;
    max-width: 1300px;
    margin: 3rem auto;
    padding: 0 50px;
}

.portfolio-viewport {
    overflow: hidden;
    width: 100%;
}

.portfolio-track {
    display: flex;
    transition: transform 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

.portfolio-slide {
    display: flex;
    flex: 0 0 100%;
    gap: 30px;
    padding: 10px 0;
}

.portfolio-item {
    flex: 0 0 calc(33.333% - 20px);
    position: relative;
    overflow: hidden;
    background: white;
}

.portfolio-item img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    display: block;
    filter: grayscale(10%);
    transition: transform 1.2s cubic-bezier(0.2, 1, 0.3, 1);
}

.portfolio-item:hover img {
    transform: scale(1.08);
}

.portfolio-info {
    padding: 1.5rem 0;
    text-align: left;
}

.portfolio-info h4 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.portfolio-info .job {
    margin: 0.3rem 0;
    font-size: 0.85rem;
    color: var(--gray);
    font-weight: 500;
}

.portfolio-info .sector {
    font-size: 0.75rem;
    color: var(--primary);
    font-style: italic;
    opacity: 0.8;
}

/* Portfolio Navigation */
.portfolio-prev,
.portfolio-next {
    position: absolute;
    top: 40%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--dark);
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 10;
    padding: 15px;
    transition: all 0.3s ease;
    opacity: 0.5;
}

.portfolio-prev:hover,
.portfolio-next:hover {
    opacity: 1;
    color: var(--primary);
}

.portfolio-prev {
    left: 0;
}

.portfolio-next {
    right: 0;
}

.portfolio-dots {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 2rem;
}

.portfolio-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #ccc;
    cursor: pointer;
    transition: all 0.3s ease;
}

.portfolio-dot.active {
    background: var(--primary);
    transform: scale(1.5);
}

@media (max-width: 992px) {
    .portfolio-slide {
        gap: 15px;
    }

    .portfolio-item {
        flex: 0 0 calc(50% - 7.5px);
    }

    .portfolio-item:nth-child(3) {
        display: none;
    }
}

@media (max-width: 576px) {
    .portfolio-item {
        flex: 0 0 100%;
    }

    .portfolio-item:nth-child(2) {
        display: none;
    }
}

.comparison-container {
    width: 100%;
    aspect-ratio: 16 / 9;
    position: relative;
    user-select: none;
}

.comparison-slider {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    cursor: ew-resize;
}

.img-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.img-wrapper.after {
    width: 50%;
    z-index: 2;
    border-right: 3px solid white;
}

.handle {
    position: absolute;
    top: 0;
    left: 50%;
    width: 4px;
    height: 100%;
    background: white;
    z-index: 5;
    transform: translateX(-50%);
    pointer-events: none;
}

.handle-circle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 48px;
    height: 48px;
    background: var(--primary);
    color: white;
    border: 4px solid white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.75rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.comp-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    color: var(--primary);
    font-size: 1.2rem;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
}

.comp-btn:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-50%) scale(1.1);
}

.comp-prev {
    left: 20px;
}

.comp-next {
    right: 20px;
}

.comp-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 10;
}

.comp-dot {
    width: 10px;
    height: 10px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
}

.comp-dot.active {
    background: white;
    transform: scale(1.3);
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

@media (max-width: 768px) {
    .comp-btn {
        width: 40px;
        height: 40px;
    }

    .handle-circle {
        width: 40px;
        height: 40px;
    }
}


.colistier-info {
    padding: 1rem;
    text-align: center;
}

.colistier-info h4 {
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 0.2rem;
}

.colistier-info .job {
    font-size: 0.7rem;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.colistier-info .sector {
    font-size: 0.7rem;
    color: var(--accent);
    font-weight: 700;
    margin-top: 0.3rem;
}

.colistier-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

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

.colistier-card:hover img {
    filter: grayscale(0%);
    transform: scale(1.05);
}


/* WhatsApp Box Style */
.btn-whatsapp-box {
    border: 3px solid #25d366 !important;
    border-radius: 8px !important;
    /* Square-ish look */
    background: transparent !important;
    color: #25d366 !important;
    font-weight: 800 !important;
    padding: 0.8rem 1.5rem !important;
    transition: var(--transition) !important;
}

.btn-whatsapp-box:hover {
    background: #25d366 !important;
    color: white !important;
    box-shadow: 0 0 20px rgba(37, 211, 102, 0.4);
}

/* Mobile Menu Animation */
.menu-toggle.open .bar:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.menu-toggle.open .bar:nth-child(2) {
    opacity: 0;
}

.menu-toggle.open .bar:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

/* Additional Responsiveness */
@media (max-width: 768px) {
    .carousel-slide {
        padding-top: 6rem;
        text-align: center;
    }

    .cta-group {
        flex-direction: column;
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }

    .cta-group .btn {
        width: 100%;
        margin-right: 0 !important;
        margin-bottom: 0.5rem;
    }

    .hero h1 {
        font-size: 2.2rem !important;
    }

    .bilan-grid {
        grid-template-columns: 1fr;
    }

    .news-grid {
        grid-template-columns: 1fr;
    }

    .faq-container {
        padding: 0 1rem;
    }

    .chatbot-wrapper {
        height: 70vh;
        margin: 0 5%;
    }

    .msg {
        max-width: 95%;
    }

    .form-container {
        padding: 1.5rem;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }

    .legal-bar {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .carousel-btn {
        width: 45px;
        height: 45px;
        font-size: 1.2rem;
    }

    .carousel-btn.prev {
        left: 10px;
    }

    .carousel-btn.next {
        right: 10px;
    }

    .logo img {
        height: 50px;
    }
}

/* PDF/Flipbook Modal */
.pdf-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    z-index: 9999;
}

.pdf-modal-view {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 20px;
}

.pdf-modal-content {
    position: relative;
    width: 95%;
    max-width: 1500px;
    height: 92vh;
    background: #111;
    border-radius: 16px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    animation: modalPulse 0.5s ease;
}

@keyframes modalPulse {
    from {
        opacity: 0;
        transform: scale(0.95);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.close-pdf {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 45px;
    font-weight: 300;
    color: white;
    cursor: pointer;
    z-index: 10001;
    line-height: 1;
    transition: transform 0.3s;
}

.close-pdf:hover {
    transform: scale(1.15);
    color: var(--primary);
}

.modal-open {
    overflow: hidden;
}

@media (max-width: 768px) {
    .pdf-modal-content {
        height: 85vh;
        width: 100%;
    }
}