/* =============================================
   ACCUEIL — SODA MARKETPLACE
   ============================================= */

/* --- Block 1 --- */

:root {

    --primary: #3BAA36;
    --secondary: #1E88D9;
    --accent: #F4C20D;

    --kente-orange: #D97904;
    --kente-red: #C7372F;
    --kente-green-dark: #146A3A;

    --text-dark: #222222;
    --text-light: #FFFFFF;

    --bg-main: #FFFFFF;
    --bg-soft: #F5F5F5;
    --border-soft: #E0E0E0;
}

/* --- 1. CORE VARIABLES & RESET --- */
:root {
    --color-primary: #1E88D9;
    /* Indigo vibrant */
    --color-primary-dark: #F4C20D;
    --color-text-main: #04070c;
    --color-text-muted: #64748b;
    --color-bg: #EAF6EA;
    --color-surface: #ffffff;

    --ease-out-expo: cubic-bezier(0.19, 1, 0.22, 1);
    --ease-elastic: cubic-bezier(0.34, 1.56, 0.64, 1);

    --container-width: 1200px;
    --radius-xl: 32px;
    --radius-full: 10px;
}

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--color-bg);
    color: var(--color-text-main);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* --- 2. UTILS & TYPOGRAPHY --- */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 2;
}

/* Masquage accessibilité */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

/* --- 3. PRELOADER (PREMIUM) --- */
.preloader {
    position: fixed;
    inset: 0;
    background: #ffffff;
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    transform-origin: top;
}

.spinner-premium {
    position: relative;
    width: 80px;
    height: 80px;
}

.spinner-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 3px solid transparent;
    border-top-color: var(--color-primary);
    /* Blue */
    animation: spin 1.5s linear infinite;
}

.spinner-ring.ring-2 {
    inset: 10px;
    border-top-color: var(--color-primary-dark);
    /* Yellow */
    animation: spin 2s linear infinite reverse;
}

.spinner-core {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 12px;
    height: 12px;
    background: #3BAA36;
    /* Green */
    border-radius: 50%;
    box-shadow: 0 0 15px rgba(59, 170, 54, 0.6);
    animation: pulse-core 2s ease-in-out infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes pulse-core {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }

    50% {
        transform: translate(-50%, -50%) scale(1.5);
        opacity: 0.6;
    }
}

/* --- REMOVED OLD HERO STYLES for Redesign --- */
/* --- 4. HERO SECTION LAYOUT (New Premium Styles) --- */
.hero-new {
    position: relative;
    height: 100vh;
    overflow: hidden;
    display: flex;
    align-items: center;
}

.glass-panel {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.text-gradient-premium {
    background: linear-gradient(135deg, #FFFFFF 0%, #E0E0E0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.btn-premium-cta {
    background: linear-gradient(90deg, #3BAA36 0%, #449836 100%);
    box-shadow: 0 0 20px rgba(59, 170, 54, 0.4);
    transition: all 0.3s ease;
}

.btn-premium-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px rgba(59, 170, 54, 0.6);
}


/* --- Block 2 --- */

    .premium-showcase-26 {
        background-color: #fafafa;
        background-image: radial-gradient(#e5e7eb 1px, transparent 1px);
        background-size: 24px 24px;
    }

    /* Responsive Mobile Images integration */
    @media (max-width: 767px) {
        .ps-text-block[data-index="0"]::after {
            content: "";
            display: block;
            width: 100%;
            height: 260px;
            margin-top: 2.5rem;
            border-radius: 1.5rem;
            background: url('https://images.unsplash.com/photo-1531545514251-b159ce8d1822?ixlib=rb-4.0.3&auto=format&fit=crop&w=800&q=80') center/cover;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
        }

        .ps-text-block[data-index="1"]::after {
            content: "";
            display: block;
            width: 100%;
            height: 260px;
            margin-top: 2.5rem;
            border-radius: 1.5rem;
            background: url('https://images.unsplash.com/photo-1586528116311-ad8ed7c1590f?ixlib=rb-4.0.3&auto=format&fit=crop&w=800&q=80') center/cover;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
        }

        .ps-text-block[data-index="2"]::after {
            content: "";
            display: block;
            width: 100%;
            height: 260px;
            margin-top: 2.5rem;
            border-radius: 1.5rem;
            background: url('https://images.unsplash.com/photo-1573164713988-8665fc963095?ixlib=rb-4.0.3&auto=format&fit=crop&w=800&q=80') center/cover;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
        }
    }


/* --- Block 3 --- */

/* ----------------------------------
VARIABLES & SETUP
---------------------------------- */
:root {
    --primary: #3BAA36;
    --secondary: #1E88D9;
    --accent: #F4C20D;
    --kente-red: #C7372F;
    --bg-section: #F8FAFC;
    --card-bg: #FFFFFF;
    --text-main: #0F172A;
    --card-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.08);
    --hover-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.15);
}

.category-section {
    position: relative;
    padding: 100px 0;
    background: var(--bg-section);
    font-family: 'Inter', sans-serif;
    overflow: hidden;
}

/* Texture de fond */
.noise-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.05'/%3E%3C/svg%3E");
    pointer-events: none;
}

/* ----------------------------------
HEADER
---------------------------------- */
.header-content {
    text-align: center;
    margin-bottom: 50px;
    position: relative;
    z-index: 2;
}

.eyebrow {
    color: var(--primary);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 10px;
    display: inline-block;
    background: rgba(59, 170, 54, 0.08);
    padding: 5px 15px;
    border-radius: 20px;
}

.category-title {
    font-size: 3rem;
    color: var(--text-main);
    font-weight: 900;
    margin: 0;
    letter-spacing: -1px;
}

/* ----------------------------------
CAROUSEL CONTAINER
---------------------------------- */
.carousel-container {
    position: relative;
    width: 100%;
    /* Padding pour ne pas couper les ombres */
    padding: 20px 0;
}

/* La Track scrollable (Le cœur du système) */
.carousel-track {
    display: flex;
    gap: 24px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    /* Snap natif */
    scroll-behavior: smooth;
    padding: 0 5vw;
    /* Espace sur les côtés */

    /* Cacher la barre de scroll */
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.carousel-track::-webkit-scrollbar {
    display: none;
}

/* ----------------------------------
LES CARTES (CARD DESIGN)
---------------------------------- */
.cat-card {
    position: relative;
    min-width: 220px;
    height: 280px;
    background: var(--card-bg);
    border-radius: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    scroll-snap-align: center;
    /* Centre la carte au stop */

    /* Style */
    border: 1px solid rgba(255, 255, 255, 0.8);
    box-shadow: var(--card-shadow);
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    overflow: hidden;

    /* Initial State pour l'animation d'entrée */
    opacity: 0;
    transform: translateY(50px);
}

/* Forme colorée en fond (Blob) */
.cat-blob {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at center, var(--bg-blob, #eee) 0%, transparent 60%);
    opacity: 0;
    transition: opacity 0.5s ease;
    z-index: 0;
}

.cat-icon {
    font-size: 42px;
    margin-bottom: 20px;
    position: relative;
    z-index: 2;
    transition: transform 0.4s ease;

    /* Cercle de l'icône */
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
    color: var(--icon-color, #333);
}

.cat-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-main);
    z-index: 2;
}

.cat-count {
    font-size: 13px;
    color: #888;
    margin-top: 5px;
    font-weight: 500;
    z-index: 2;
    transition: color 0.3s;
}

/* --- AUTO COLORATION INTELLIGENTE --- */
/* On cycle à travers tes couleurs pour chaque carte */
.cat-card:nth-child(4n+1) {
    --icon-color: var(--primary);
    --bg-blob: rgba(59, 170, 54, 0.15);
}

.cat-card:nth-child(4n+2) {
    --icon-color: var(--secondary);
    --bg-blob: rgba(30, 136, 217, 0.15);
}

.cat-card:nth-child(4n+3) {
    --icon-color: var(--accent);
    --bg-blob: rgba(244, 194, 13, 0.15);
}

.cat-card:nth-child(4n+4) {
    --icon-color: var(--kente-red);
    --bg-blob: rgba(199, 55, 47, 0.15);
}

/* --- HOVER EFFECTS --- */
.cat-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: var(--hover-shadow);
}

.cat-card:hover .cat-blob {
    opacity: 1;
}

.cat-card:hover .cat-icon {
    transform: scale(1.1) rotate(-5deg);
    background: #fff;
}

.cat-card:hover .cat-count {
    color: var(--icon-color);
}

/* ----------------------------------
NAVIGATION BUTTONS
---------------------------------- */
.nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: none;
    background: #fff;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: var(--text-main);
    transition: all 0.3s ease;
}

.nav-btn:hover {
    background: var(--text-main);
    color: #fff;
    transform: translateY(-50%) scale(1.1);
}

.btn-left {
    left: 5%;
}

.btn-right {
    right: 5%;
}

/* Hide buttons on mobile (touch is better) */
@media(max-width: 768px) {
    .nav-btn {
        display: none;
    }

}


@media(max-width: 768px) {
    .carousel-track {
        padding: 0 20px;
        gap: 15px;
    }

    .cat-card {
        min-width: 160px;
        height: 220px;
    }

    .cat-icon {
        width: 60px;
        height: 60px;
        font-size: 30px;
    }

    .category-title {
        font-size: 2rem;
    }
}

/* ----------------------------------
PROGRESS BAR
---------------------------------- */
.scroll-progress {
    width: 200px;
    height: 4px;
    background: #E2E8F0;
    margin: 30px auto 0;
    border-radius: 2px;
    overflow: hidden;
}

.scroll-bar {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    transition: width 0.1s linear;
}

/* ----------------------------------
ANIMATION D'ENTREE (CINEMATIC)
---------------------------------- */
.cat-card.visible {
    animation: popIn 0.8s cubic-bezier(0.17, 0.67, 0.45, 1.2) forwards;
}

@keyframes popIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Stagger delay (automatique via CSS) */
.cat-card:nth-child(1) {
    animation-delay: 0.1s;
}

.cat-card:nth-child(2) {
    animation-delay: 0.2s;
}

.cat-card:nth-child(3) {
    animation-delay: 0.3s;
}

.cat-card:nth-child(4) {
    animation-delay: 0.4s;
}

.cat-card:nth-child(5) {
    animation-delay: 0.5s;
}

/* Et ainsi de suite... */


/* --- Block 4 --- */

    [x-cloak] {
        display: none !important;
    }


/* --- Block 5 --- */

                /* Hide Scrollbar for Horizontal swipe Area */
                .hide-scrollbars::-webkit-scrollbar {
                    display: none;
                }

                .hide-scrollbars {
                    -ms-overflow-style: none;
                    scrollbar-width: none;
                    mask-image: linear-gradient(to right, black 85%, transparent 100%);
                    -webkit-mask-image: linear-gradient(to right, black 85%, transparent 100%);
                }

                @media (min-width: 768px) {
                    .hide-scrollbars {
                        mask-image: none;
                        -webkit-mask-image: none;
                    }
                }
            

/* --- Block 6 --- */

:root {
    --primary: #3BAA36;
    --secondary: #1E88D9;
    --text: #222;
    --muted: rgba(34, 34, 34, .65);
    --bg: #F0F6FC;
}

* {
    box-sizing: border-box;
    font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial;
}

/* hide by default on desktop */
.soda-benefits {
    display: none;
}

.soda-benefits {
    padding: clamp(56px, 8vw, 120px) 6vw;
    background: var(--bg);
    overflow: hidden;
    position: relative;
}

.soda-benefits__inner {
    max-width: 1400px;
    margin: 0 auto;
}

.soda-benefits__header {
    max-width: 720px;
    margin-bottom: 56px;
}

.soda-benefits__header h2 {
    margin: 0 0 12px;
    font-size: clamp(26px, 4vw, 46px);
    font-weight: 900;
    letter-spacing: -0.025em;
    color: var(--text);
}

.soda-benefits__header p {
    margin: 0;
    font-size: 16px;
    color: var(--muted);
    line-height: 1.6;
}

.soda-benefits__scroller-wrap {
    position: relative;
}

.soda-benefits__scroller {
    display: flex;
    gap: 28px;
    will-change: transform;
    /* on mobile it will be horizontally scrollable */
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.soda-benefits__scroller::-webkit-scrollbar {
    display: none;
}

.soda-benefits__card {
    flex: 0 0 85%;
    min-width: 280px;
    max-width: 640px;
    padding: 22px;
    display: flex;
    gap: 20px;
    border-radius: 18px;
    position: relative;

    background:
        radial-gradient(120% 120% at 0% 0%, rgba(255, 255, 255, .95), rgba(255, 255, 255, .75)),
        linear-gradient(180deg, #ffffff, #f2f6f4);

    box-shadow:
        0 30px 70px rgba(0, 0, 0, .08),
        inset 0 1px 0 rgba(255, 255, 255, .7);

    transition:
        transform .45s cubic-bezier(.2, .9, .2, 1),
        box-shadow .45s ease,
        background .45s ease;
}

.soda-benefits__card::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(120deg,
            transparent,
            rgba(30, 136, 217, .06),
            rgba(59, 170, 54, .06),
            transparent);
    opacity: 0;
    transition: opacity .45s ease;
}

.soda-benefits__card:active,
.soda-benefits__card:hover {
    transform: translateY(-6px) scale(1.01);
    box-shadow: 0 40px 90px rgba(0, 0, 0, .12);
}

.soda-benefits__card:active::after,
.soda-benefits__card:hover::after {
    opacity: 1;
}

.soda-benefits__icon {
    width: 64px;
    height: 64px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;

    background:
        linear-gradient(135deg,
            rgba(59, 170, 54, .14),
            rgba(30, 136, 217, .14));

    box-shadow:
        inset 0 0 0 1px rgba(255, 255, 255, .6),
        0 8px 24px rgba(0, 0, 0, .06);
}

.soda-benefits__icon i {
    width: 36px;
    height: 36px;
    display: inline-block;
    stroke-width: 2.3;
    color: var(--secondary);
    transition: transform .36s ease, color .36s ease;
}

.soda-benefits__card:active .soda-benefits__icon i,
.soda-benefits__card:hover .soda-benefits__icon i {
    color: var(--primary);
    transform: scale(1.08);
}

.soda-benefits__card h3 {
    margin: 0 0 6px;
    font-size: 16px;
    font-weight: 800;
    color: var(--text);
}

.soda-benefits__card p {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: var(--muted);
}

.soda-benefits__progress {
    margin-top: 22px;
    height: 6px;
    max-width: 620px;
    background: rgba(0, 0, 0, .06);
    border-radius: 999px;
    overflow: hidden;
}

.soda-benefits__progress span {
    display: block;
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    transition: width .12s linear;
}

/* Mobile reveal (ensures display:block only on mobile widths) */
@media (max-width:900px) {
    .soda-benefits {
        display: block;
        padding: 40px 6vw;
    }

    .soda-benefits__card {
        flex: 0 0 85%;
        padding: 20px;
        border-radius: 16px;
    }
}

/* Accessibility: reduce motion */
@media (prefers-reduced-motion: reduce) {

    .soda-benefits__card,
    .soda-benefits__icon i {
        transition: none !important;
    }
}


/* --- Block 7 --- */

            /* Premium Feature Masonry */
            .masonry-card {
                will-change: transform, opacity;
                box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.1), 0 0 0 2px rgba(255, 255, 255, 0.7) inset;
                backdrop-filter: blur(24px);
                -webkit-backdrop-filter: blur(24px);
                background: rgba(255, 255, 255, 0.75);
                transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.5s;
            }

            .masonry-card:hover {
                transform: translateY(-8px);
                box-shadow: 0 40px 80px -20px rgba(0, 0, 0, 0.15), 0 0 0 2px rgba(255, 255, 255, 0.9) inset;
            }

            @media (min-width: 768px) {
                .offset-card {
                    margin-top: 5rem;
                    /* Stagger the second column for masonry effect */
                }
            }

            @supports (animation-timeline: view()) {
                .masonry-card {
                    animation: masonry-fade-in linear both;
                    animation-timeline: view();
                    animation-range: entry 5% cover 25%;
                }

                @keyframes masonry-fade-in {
                    0% {
                        opacity: 0;
                        transform: translateY(60px);
                    }

                    100% {
                        opacity: 1;
                        transform: translateY(0);
                    }
                }
            }
        

/* --- Block 8 --- */

/* ----------------------------- */
/* CTA AFRIK7 – ULTRA PREMIUM    */
/* ----------------------------- */

:root {
    --green: #2dec1b;
    --blue: #4dc0ff;
    --dark: #0d0d0d;
}

/* Wrapper */
.cta-wrapper {
    margin: 40px 0 100px;
    padding: 0 10px;
}

/* Box principale */
.cta-box {
    position: relative;
    overflow: hidden;
    border-radius: 22px;
    padding: 48px 50px;
    background: linear-gradient(110deg, var(--green) 0%, var(--blue) 100%);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 32px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    transform: translateY(0);
    transition: transform .35s ease, box-shadow .35s ease;
    isolation: isolate;
}

/* Halo animé */
.cta-box::before {
    content: "";
    position: absolute;
    top: -40%;
    left: -20%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.22), transparent 60%);
    animation: halo 8s infinite linear;
    z-index: -1;
    transform: rotate(0deg);
}

@keyframes halo {
    to {
        transform: rotate(360deg);
    }
}

/* Hover flottant */
.cta-box:hover {
    transform: translateY(-6px);
    box-shadow: 0 26px 40px rgba(0, 0, 0, 0.25);
}

/* Texte */
.cta1-text-title {
    font-weight: 900;
    font-size: 28px;
    color: #000;
    line-height: 1.2;
}

.cta1-text-sub {
    margin-top: 10px;
    color: rgba(0, 0, 0, 0.65);
    font-size: 16px;
    font-weight: 500;
}

/* Boutons */
.cta-actions {
    display: flex;
    gap: 18px;
    flex-shrink: 0;
}

.btn1 {
    padding: 14px 26px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.25s ease;
    font-size: 16px;
    border: none;
    letter-spacing: 0.3px;
}

.btn1-primary {
    background: #ffffff;
    color: #000;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
}

.btn1-primary:hover {
    transform: translateY(-3px) scale(1.04);
    background: #f5f5f5;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18);
}

.btn1-ghost {
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1);
}

.btn1-ghost:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-3px) scale(1.04);
}

/* Responsive */
@media(max-width:850px) {
    .cta-box {
        flex-direction: column;
        text-align: center;
        padding: 38px 26px;
    }

    .cta-actions {
        flex-wrap: wrap;
        justify-content: center;
    }

    .cta1-text-title {
        font-size: 24px;
    }
}
