/**
 * UMOA Premium Design System - Mobile First
 * Design "Premium-Utilitaire" avec identité africaine authentique
 * 
 * @package UMOA
 * @version 1.0
 */

/* ============================================================================
   IMPORT POLICE MODERNE
   ============================================================================ */
/* Note: Les polices Inter et Poppins sont déjà importées dans main.css */
/* Ce fichier utilise les variables de police existantes */

/* ============================================================================
   VARIABLES DESIGN SYSTEM PREMIUM
   ============================================================================ */
:root {
    /* Palette de Couleurs Premium */
    --umoa-purple: #7B2CBF;           /* Violet UMOA - Accent principal */
    --umoa-purple-light: #9D4EDD;     /* Violet clair */
    --umoa-purple-dark: #5A189A;      /* Violet foncé */
    
    --background-off-white: #F8F9FA;  /* Blanc cassé - Fond principal */
    --text-anthracite: #2D3436;       /* Gris anthracite - Titres */
    --emerald-green: #10B981;         /* Vert émeraude - Prix & Succès */
    --terracotta-orange: #D97706;      /* Orange terreux - Badges promotion */
    
    /* Couleurs de base */
    --white: #FFFFFF;
    --black: #000000;
    --gray-50: #F9FAFB;
    --gray-100: #F3F4F6;
    --gray-200: #E5E7EB;
    --gray-300: #D1D5DB;
    --gray-400: #9CA3AF;
    --gray-500: #6B7280;
    --gray-600: #4B5563;
    --gray-700: #374151;
    --gray-800: #1F2937;
    --gray-900: #111827;
    
    /* Typographie - Utilise les polices déjà chargées */
    /* Note: Les polices Inter et Poppins sont importées dans main.css */
    --font-weight-normal: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
    
    /* Espacements */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-2xl: 48px;
    
    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-2xl: 24px;
    --radius-full: 9999px;
    
    /* Ombres Premium */
    --shadow-soft: 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-medium: 0 4px 16px rgba(0, 0, 0, 0.08);
    --shadow-large: 0 8px 24px rgba(0, 0, 0, 0.12);
    
    /* Transitions */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: 300ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================================================
   BASE - FOND & TYPOGRAPHIE
   ============================================================================ */
/* Note: Le background du body est géré dans main.css avec fallback */
/* Les styles de typographie premium s'appliquent via les classes spécifiques */

/* ============================================================================
   BANNIÈRE HERO - PREMIUM
   ============================================================================ */
.hero-slider {
    position: relative;
    width: 100%;
    height: 300px;
    overflow: hidden;
    margin-bottom: var(--spacing-lg);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-large);
    background: var(--white);
}

.slider-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.6s ease-in-out;
    z-index: 1;
    border-radius: var(--radius-2xl);
    overflow: hidden;
}

.slide.active {
    opacity: 1;
    z-index: 2;
}

.slide-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Overlay dégradé pour lisibilité du texte */
.slide-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4); /* Overlay noir - couleur unie */
    z-index: 1;
}

.slide-content {
    position: relative;
    z-index: 3;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
    padding: var(--spacing-lg);
}

.slide-title {
    font-size: 1.5rem;
    font-weight: var(--font-weight-bold);
    margin: 0 0 var(--spacing-sm) 0;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.5);
}

.slide-description {
    font-size: 0.875rem;
    margin: 0 0 var(--spacing-md) 0;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
    opacity: 0.95;
}

/* Bouton Explorer */
.btn-explorer {
    background: var(--umoa-purple);
    color: var(--white);
    padding: var(--spacing-sm) var(--spacing-lg);
    border-radius: var(--radius-full);
    font-weight: var(--font-weight-semibold);
    font-size: 0.875rem;
    border: none;
    cursor: pointer;
    transition: all var(--transition-normal);
    box-shadow: var(--shadow-medium);
    text-decoration: none;
    display: inline-block;
}

.btn-explorer:hover {
    background: var(--umoa-purple-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-large);
}

.btn-explorer:active {
    transform: translateY(0);
}

/* ============================================================================
   SECTION CATÉGORIES - CERCLES PASTELS
   ============================================================================ */
.categories-section {
    padding: var(--spacing-xl) 0;
    background: var(--background-off-white);
}

.section-title {
    font-size: 1.5rem;
    font-weight: var(--font-weight-bold);
    color: var(--text-anthracite);
    margin: 0 0 var(--spacing-lg) 0;
    position: relative;
    padding-bottom: var(--spacing-sm);
}

/* Barre d'accentuation colorée sous le titre */
.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--umoa-purple);
    border-radius: var(--radius-full);
}

.categories-scroll-container {
    display: flex;
    gap: var(--spacing-md);
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    padding: var(--spacing-sm) 0;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE/Edge */
}

.categories-scroll-container::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
}

.category-card {
    background: var(--white);
    border-radius: var(--radius-full);
    padding: var(--spacing-md);
    text-align: center;
    text-decoration: none;
    color: var(--text-anthracite);
    transition: all var(--transition-normal);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-sm);
    min-width: 100px;
    flex-shrink: 0;
    position: relative;
    border: 1px solid var(--gray-200);
    box-shadow: var(--shadow-soft);
}

/* Fond pastel pour l'icône de catégorie */
.category-icon {
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-full);
    margin-bottom: var(--spacing-xs);
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

/* Couleurs pastel pour chaque catégorie - Design System Unifié */
.category-icon.mode {
    background: rgba(16, 185, 129, 0.15); /* Vert pastel - couleur unie */
}

.category-icon.epices {
    background: rgba(217, 119, 6, 0.15); /* Orange pastel - couleur unie */
}

.category-icon.artisanat {
    background: rgba(139, 69, 19, 0.15); /* Marron pastel - couleur unie */
}

.category-icon.deco {
    background: rgba(59, 130, 246, 0.15); /* Bleu pastel - couleur unie */
}

.category-icon.default {
    background: rgba(123, 44, 191, 0.15); /* Violet UMOA pastel - couleur unie */
}

.category-icon img,
.category-emoji {
    width: 32px;
    height: 32px;
    font-size: 2rem;
}

.category-name {
    font-size: 0.75rem;
    font-weight: var(--font-weight-medium);
    margin: 0;
    color: var(--text-anthracite);
    text-transform: none;
    letter-spacing: 0;
}

.category-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-medium);
    border-color: var(--umoa-purple-light);
}

.category-card:hover .category-icon {
    transform: scale(1.1);
}

/* ============================================================================
   CARTE PRODUIT - PREMIUM
   ============================================================================ */
.product-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    transition: all var(--transition-normal);
    position: relative;
    min-width: 240px;
    flex-shrink: 0;
    border: 1px solid #EEE;
    display: flex;
    flex-direction: column;
    height: auto;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-medium);
    border-color: var(--umoa-purple-light);
}

.product-link {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    flex: 1;
    width: 100%;
    height: 100%;
}

.product-image {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: var(--gray-100);
    flex-shrink: 0;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-normal);
    display: block;
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

/* Badge promotion - Orange terreux */
.product-badge {
    position: absolute;
    top: var(--spacing-sm);
    right: var(--spacing-sm);
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: var(--font-weight-bold);
    background: var(--terracotta-orange);
    color: var(--white);
    backdrop-filter: blur(8px);
    box-shadow: var(--shadow-medium);
    z-index: 10;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.product-info {
    padding: var(--spacing-md);
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xs);
}

.product-name {
    font-size: 0.875rem;
    font-weight: var(--font-weight-semibold);
    margin: 0 0 var(--spacing-xs) 0;
    color: var(--text-anthracite);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 2.8em;
}

/* Prix - Vert émeraude */
.product-price-value {
    font-size: 1.125rem;
    font-weight: var(--font-weight-bold);
    color: var(--emerald-green);
    margin: var(--spacing-xs) 0;
    flex-shrink: 0;
}

.product-price-display {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: var(--spacing-sm) 0;
    gap: var(--spacing-sm);
}

/* Bouton Ajouter au Panier - Design System Unifié */
.btn-add-cart,
button.btn-add-cart,
a.btn-add-cart,
.product-card .btn-add-cart,
.product-card-modern .btn-add-cart,
.article-card .btn-add-cart {
    background: #7B2CBF !important; /* Violet UMOA - couleur unie */
    color: #FFFFFF !important; /* Texte blanc */
    padding: 12px 16px;
    border-radius: 12px; /* Arrondi moderne */
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 600;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    border: none;
    cursor: pointer;
    text-align: center;
    display: inline-block;
    box-shadow: 0 2px 4px rgba(123, 44, 191, 0.2);
}

.btn-add-cart:hover {
    background: #9D4EDD !important; /* Violet UMOA clair au survol */
    transform: scale(1.02);
    box-shadow: 0 4px 8px rgba(123, 44, 191, 0.3);
}

.btn-add-cart:active {
    background: #5A189A !important; /* Violet UMOA foncé au clic */
    transform: scale(0.98);
}

/* ============================================================================
   MICRO-MOTIFS AFRICAINS (FILIGRANE)
   ============================================================================ */
.hero-slider::before,
.categories-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(123, 44, 191, 0.01); /* Filigrane violet UMOA très subtil - couleur unie */
    pointer-events: none;
    z-index: 0;
    opacity: 0.3;
}

/* Motif géométrique subtil */
.category-card::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(
        circle,
        rgba(123, 44, 191, 0.03) 0%,
        transparent 70%
    );
    pointer-events: none;
    z-index: 0;
}

/* ============================================================================
   BOUTON WHATSAPP - OPTIMISÉ
   ============================================================================ */
.whatsapp-float {
    position: fixed;
    bottom: calc(64px + var(--spacing-md) + env(safe-area-inset-bottom, 0px));
    right: var(--spacing-md);
    width: 52px;
    height: 52px;
    background: #25d366;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    box-shadow: var(--shadow-large);
    z-index: 10001;
    transition: all var(--transition-normal);
    text-decoration: none;
    pointer-events: auto;
    touch-action: manipulation;
    -webkit-tap-highlight-color: rgba(37, 211, 102, 0.3);
    cursor: pointer;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.5);
}

.whatsapp-float:active {
    transform: scale(0.95);
    background: #1ea952;
}

.whatsapp-float svg {
    width: 28px;
    height: 28px;
}

/* ============================================================================
   NAVIGATION BOTTOM - ÉPURÉE
   ============================================================================ */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--white);
    border-top: 1px solid var(--gray-200);
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important; /* Centre verticalement */
    justify-content: space-around;
    padding: 0 !important;
    padding-top: 0 !important;
    padding-bottom: calc(var(--spacing-sm) + env(safe-area-inset-bottom, 0px));
    z-index: 999;
    box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.04);
    height: 65px !important; /* Hauteur idéale pour icône + petit texte */
    line-height: normal !important;
}

.nav-item {
    display: flex !important;
    flex-direction: column !important; /* Met l'icône au-dessus du texte */
    align-items: center !important;    /* Centre horizontalement l'icône et le texte */
    justify-content: center !important; /* Centre l'ensemble verticalement */
    height: 100% !important; /* Oblige l'élément à occuper toute la hauteur pour se centrer */
    gap: 4px !important; /* Espace entre l'icône et le texte */
    text-decoration: none;
    color: var(--gray-500);
    transition: all var(--transition-fast);
    padding: 0 !important;
    padding-top: 0 !important;
    margin: 0 !important;
    margin-top: 0 !important;
    border-radius: var(--radius-md);
    flex: 1;
    max-width: 80px;
    line-height: 1 !important;
    vertical-align: middle !important;
}

.nav-item svg,
.nav-item .nav-icon {
    width: 20px; /* Taille standard pour ne pas déborder */
    height: 20px;
    stroke-width: 1.5;
    transition: all var(--transition-fast);
    margin: 0 !important;
    padding: 0 !important;
    display: block;
    line-height: 1 !important;
}

.nav-item.active {
    color: var(--umoa-purple);
}

.nav-item.active svg,
.nav-item.active .nav-icon {
    stroke-width: 2;
    transform: scale(1.1);
}

.nav-label {
    font-size: 0.6875rem;
    font-weight: var(--font-weight-medium);
    text-align: center;
}

/* ============================================================================
   RESPONSIVE - MOBILE FIRST
   ============================================================================ */
@media (max-width: 480px) {
    .hero-slider {
        height: 250px;
        margin-bottom: var(--spacing-md);
    }
    
    .slide-title {
        font-size: 1.25rem;
    }
    
    .slide-description {
        font-size: 0.8125rem;
    }
    
    .section-title {
        font-size: 1.25rem;
    }
    
    .category-card {
        min-width: 70px; /* Réduit pour afficher au moins 4 catégories */
        padding: var(--spacing-sm) var(--spacing-xs);
        gap: var(--spacing-xs);
    }
    
    .category-icon {
        width: 36px;
        height: 36px;
    }
    
    .category-emoji {
        font-size: 1.125rem;
    }
    
    .category-name {
        font-size: 0.625rem;
        line-height: 1.1;
    }
    
    .categories-scroll-container {
        gap: var(--spacing-xs);
    }
    
    .product-card {
        min-width: 220px;
    }
    
    .product-name {
        font-size: 0.8125rem;
    }
    
    .product-price-value {
        font-size: 1rem;
    }
    
    .whatsapp-float {
        width: 48px;
        height: 48px;
        bottom: calc(64px + var(--spacing-sm) + env(safe-area-inset-bottom, 0px));
        z-index: 10001;
        pointer-events: auto;
        touch-action: manipulation;
        -webkit-tap-highlight-color: rgba(37, 211, 102, 0.3);
    }
    
    .whatsapp-float svg {
        width: 24px;
        height: 24px;
    }
}

/* ============================================================================
   ANIMATIONS
   ============================================================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.product-card,
.category-card {
    animation: fadeInUp 0.4s ease-out;
}

