/* unified-sections.css - CSS unifié pour toutes les sections économiques */

/* ============================================
   1. FONDAMENTAUX & CLASSES UTILITAIRES
   ============================================ */

/* Classes utilitaires globales */
.max-w-800 { max-width: 800px; }
.opacity-90 { opacity: 0.9; }
.opacity-80 { opacity: 0.8; }
.opacity-70 { opacity: 0.7; }
.z-1 { z-index: 1; }
.z-2 { z-index: 2; }
.w-30 { width: 30%; }
.h-50 { height: 50%; }

/* Effet de levage */
.hover-lift {
    transition: all 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* ============================================
   2. STRUCTURE COMMUNE DES SECTIONS
   ============================================ */

.commerce-local-section,
.entrepreneurship-section,
.investment-opportunities-section {
    background-color: #f8f9fa;
    position: relative;
    overflow: hidden;
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
}

/* Labels de section */
.commerce-local-section .section-label {
    background: linear-gradient(135deg, #4caf50 0%, #2e7d32 100%);
}

.entrepreneurship-section .section-label {
    background: linear-gradient(135deg, #9c27b0 0%, #7b1fa2 100%);
}

.investment-opportunities-section .section-label {
    background: linear-gradient(135deg, #0d47a1 0%, #1565c0 100%);
}

/* Style commun des labels */
.commerce-local-section .section-label,
.entrepreneurship-section .section-label,
.investment-opportunities-section .section-label {
    display: inline-block;
    padding: 8px 20px;
    color: white;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
}

/* ============================================
   3. COMPOSANTS COMMUNS
   ============================================ */

/* Cercle de statistiques */
.stat-circle {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 140px;
    height: 140px;
    border-radius: 50%;
    border: 3px dashed;
    background-color: white;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.stat-circle .display-4 {
    line-height: 1;
    margin-bottom: 5px;
}

.stat-circle small {
    font-size: 0.85rem;
    opacity: 0.9;
}

/* Cartes d'éléments (commerce, programme, secteur) */
.commerce-item,
.product-item,
.program-item,
.opportunity-item,
.sector-item,
.sector-focus-item {
    position: relative;
    animation: fadeInUp 0.6s ease-out forwards;
}

.commerce-details,
.product-details,
.program-details,
.opportunity-details,
.sector-details,
.sector-focus-details {
    border: 1px solid rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    background-color: #f8f9fa;
}

.commerce-details:hover,
.product-details:hover,
.program-details:hover,
.opportunity-details:hover,
.sector-details:hover,
.sector-focus-details:hover {
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

/* En-têtes avec icônes numérotées */
.stat-number,
.category-icon,
.sector-icon,
.focus-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    color: white;
    font-weight: bold;
    font-size: 1rem;
    flex-shrink: 0;
}

.stat-header,
.category-header,
.sector-header,
.focus-header {
    position: relative;
}

/* Barres de progression */
.progress-tracking {
    border: 1px solid rgba(33, 150, 243, 0.1);
    animation: fadeInUp 0.6s ease-out forwards;
    animation-delay: 0.3s;
}

.progress-item {
    position: relative;
}

.progress-item .progress {
    border-radius: 4px;
    overflow: hidden;
    background-color: rgba(0, 0, 0, 0.05);
}

.progress-bar {
    border-radius: 4px;
    transition: width 1s ease-in-out;
}

/* Conteneurs d'images */
.commerce-image-container,
.entrepreneurship-image-container,
.investment-image-container {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.commerce-image-container:hover,
.entrepreneurship-image-container:hover,
.investment-image-container:hover {
    transform: scale(1.01);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.commerce-image-container img,
.entrepreneurship-image-container img,
.investment-image-container img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.commerce-image-container:hover img,
.entrepreneurship-image-container:hover img,
.investment-image-container:hover img {
    transform: scale(1.05);
}

/* Overlay d'image */
.image-overlay {
    background: linear-gradient(transparent 40%, rgba(0, 0, 0, 0.7) 100%);
}

/* Groupes de badges */
.product-badges,
.program-badges,
.sector-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/* Cartes d'impact */
.impact-economic,
.impact-entrepreneurial,
.impact-investment {
    border: 1px solid rgba(156, 39, 176, 0.1);
    animation: fadeInUp 0.6s ease-out forwards;
    animation-delay: 0.4s;
}

.impact-item {
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

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

.impact-icon {
    transition: transform 0.3s ease;
}

.impact-item:hover .impact-icon {
    transform: scale(1.2);
}

/* ============================================
   4. COMPOSANTS CTA & BOUTONS
   ============================================ */

/* CTA d'investissement */
.investment-cta {
    border: 1px solid rgba(255, 152, 0, 0.1);
    position: relative;
    overflow: hidden;
    animation: fadeInUp 0.6s ease-out forwards;
    animation-delay: 0.5s;
}

.investment-cta::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: pulse 4s infinite alternate;
}

@keyframes pulse {
    0% { transform: scale(0.8); opacity: 0.5; }
    100% { transform: scale(1.2); opacity: 0.8; }
}

/* Boutons CTA */
.cta-buttons .btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.cta-buttons .btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.cta-buttons .btn:hover::before {
    width: 300px;
    height: 300px;
}

/* ============================================
   5. TABLEAUX SYNTHÉTIQUES
   ============================================ */

.commerce-summary-card,
.entrepreneurship-summary-card,
.investment-summary-card {
    border: 1px solid rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.commerce-summary-card:hover,
.entrepreneurship-summary-card:hover,
.investment-summary-card:hover {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1) !important;
}

.table-commerce-summary,
.table-entrepreneurship-summary,
.table-investment-summary {
    margin-bottom: 0;
}

.table-commerce-summary thead th,
.table-entrepreneurship-summary thead th,
.table-investment-summary thead th {
    background-color: #f8f9fa;
    border-bottom: 2px solid #e9ecef;
    font-weight: 600;
    color: #495057;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

.table-commerce-summary tbody td,
.table-entrepreneurship-summary tbody td,
.table-investment-summary tbody td {
    vertical-align: middle;
    padding: 1.25rem 1rem;
    border-bottom: 1px solid #e9ecef;
    transition: background-color 0.2s ease;
}

.table-commerce-summary tbody tr:hover td {
    background-color: rgba(76, 175, 80, 0.03);
}

.table-entrepreneurship-summary tbody tr:hover td {
    background-color: rgba(156, 39, 176, 0.03);
}

.table-investment-summary tbody tr:hover td {
    background-color: rgba(13, 71, 161, 0.03);
}

/* Badges dans les tableaux */
.table-commerce-summary .badge,
.table-entrepreneurship-summary .badge,
.table-investment-summary .badge {
    font-size: 0.75rem;
    padding: 4px 10px;
    border-radius: 20px;
    font-weight: 500;
}

/* Légende */
.legend-color {
    flex-shrink: 0;
    width: 12px;
    height: 12px;
    border-radius: 2px;
}

/* ============================================
   6. SYSTÈME DE BADGES UNIFIÉ
   ============================================ */

/* Badge de base */
.sector-badge,
.commerce-badge,
.product-badge,
.program-badge,
.opportunity-badge,
.trend-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.trend-badge {
    font-size: 0.8rem;
    font-weight: 500;
}

/* Effet hover unifié pour tous les badges */
.sector-badge:hover,
.commerce-badge:hover,
.product-badge:hover,
.program-badge:hover,
.opportunity-badge:hover,
.trend-badge:hover,
.badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

/* Effet de brillance pour sector-badge */
.sector-badge::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        to right,
        transparent 0%,
        rgba(255, 255, 255, 0.2) 50%,
        transparent 100%
    );
    transform: rotate(30deg);
    opacity: 0;
    transition: opacity 0.3s, transform 0.6s;
}

.sector-badge:hover::after {
    opacity: 1;
    transform: rotate(30deg) translate(20%, 20%);
}

/* ============================================
   7. COULEURS THÉMATIQUES
   ============================================ */

/* Vert - Agriculture, Commerce, Succès */
.text-success { color: #4caf50 !important; }
.bg-success { background-color: #4caf50 !important; }
.bg-success-light { background-color: rgba(76, 175, 80, 0.1) !important; }

/* Orange - Énergies, Avertissements */
.text-warning { color: #ff9800 !important; }
.bg-warning { background-color: #ff9800 !important; }
.bg-warning-light { background-color: rgba(255, 152, 0, 0.1) !important; }

/* Violet - Entrepreneuriat, Jeunesse */
.text-purple { color: #9c27b0 !important; }
.bg-purple { background-color: #9c27b0 !important; }
.bg-purple-light { background-color: rgba(156, 39, 176, 0.1) !important; }

/* Bleu - Tourisme, Information */
.text-info { color: #2196f3 !important; }
.bg-info { background-color: #2196f3 !important; }
.bg-info-light { background-color: rgba(33, 150, 243, 0.1) !important; }

/* Rouge - Mines, Danger */
.text-danger { color: #dc3545 !important; }
.bg-danger { background-color: #dc3545 !important; }
.bg-danger-light { background-color: rgba(220, 53, 69, 0.1) !important; }

/* Bleu foncé - Investissement */
.text-primary { color: #0d47a1 !important; }
.bg-primary { background-color: #0d47a1 !important; }
.bg-primary-light { background-color: rgba(13, 71, 161, 0.1) !important; }

/* ============================================
   8. ALERTES & NOTIFICATIONS
   ============================================ */

.alert {
    border: 1px solid transparent;
    border-radius: 10px;
    padding: 1.25rem;
}

.alert-success {
    background-color: rgba(76, 175, 80, 0.08);
    border-color: rgba(76, 175, 80, 0.2);
    color: #2e7d32;
}

.alert-success .alert-heading {
    color: #2e7d32;
}

.alert-purple {
    background-color: rgba(156, 39, 176, 0.08);
    border-color: rgba(156, 39, 176, 0.2);
    color: #7b1fa2;
    border-radius: 10px;
    padding: 1.25rem;
}

.alert-purple .alert-heading {
    color: #7b1fa2;
}

/* ============================================
   9. ANIMATIONS
   ============================================ */

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Délais d'animation */
.commerce-item:nth-child(1),
.program-item:nth-child(1),
.sector-item:nth-child(1) { 
    animation-delay: 0.1s; 
}

.commerce-item:nth-child(2),
.program-item:nth-child(2),
.sector-item:nth-child(2),
.sector-focus-item { 
    animation-delay: 0.2s; 
}

/* ============================================
   10. RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 992px) {
    .commerce-local-section .display-5,
    .entrepreneurship-section .display-5,
    .investment-opportunities-section .display-5 {
        font-size: 2.5rem;
    }
    
    .stat-circle {
        width: 120px;
        height: 120px;
    }
    
    .stat-circle .display-4 {
        font-size: 2.5rem;
    }
}

@media (max-width: 768px) {
    .commerce-local-section .section-label,
    .entrepreneurship-section .section-label,
    .investment-opportunities-section .section-label {
        font-size: 0.8rem;
        padding: 6px 16px;
    }
    
    .commerce-local-section .display-5,
    .entrepreneurship-section .display-5,
    .investment-opportunities-section .display-5 {
        font-size: 2rem;
    }
    
    .commerce-details,
    .product-details,
    .program-details,
    .opportunity-details,
    .sector-details,
    .sector-focus-details {
        padding: 1.5rem !important;
    }
    
    .table-responsive {
        font-size: 0.9rem;
    }
    
    .product-badges,
    .program-badges,
    .sector-badges {
        justify-content: center;
    }
}

@media (max-width: 576px) {
    .stat-circle {
        width: 100px;
        height: 100px;
        margin-top: 1rem;
    }
    
    .stat-circle .display-4 {
        font-size: 2rem;
    }
    
    .cta-buttons .btn {
        width: 100%;
        margin-bottom: 10px;
    }
    
    .impact-item {
        margin-bottom: 10px;
    }
    
    .sector-badge,
    .commerce-badge,
    .product-badge,
    .program-badge,
    .opportunity-badge {
        font-size: 0.65rem;
        padding: 2px 8px;
    }
}

/* ============================================
   11. STYLES SPÉCIFIQUES POUR SECTOR-BADGE
   ============================================ */

/* Dégradés pour sector-badge */
.sector-badge.bg-success {
    background: linear-gradient(135deg, #4caf50 0%, #388e3c 100%) !important;
    color: white;
    border: 1px solid rgba(56, 142, 60, 0.3);
}

.sector-badge.bg-info {
    background: linear-gradient(135deg, #2196f3 0%, #1976d2 100%) !important;
    color: white;
    border: 1px solid rgba(25, 118, 210, 0.3);
}

.sector-badge.bg-danger {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%) !important;
    color: white;
    border: 1px solid rgba(200, 35, 51, 0.3);
}

.sector-badge.bg-warning {
    background: linear-gradient(135deg, #ff9800 0%, #f57c00 100%) !important;
    color: white;
    border: 1px solid rgba(245, 124, 0, 0.3);
}

.sector-badge.bg-purple {
    background: linear-gradient(135deg, #9c27b0 0%, #7b1fa2 100%) !important;
    color: white;
    border: 1px solid rgba(123, 31, 162, 0.3);
}

/* Animation spécifique pour sector-badge */
@keyframes badge-fadeIn {
    from {
        opacity: 0;
        transform: scale(0.8) translateY(10px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.sector-badge.animated {
    animation: badge-fadeIn 0.5s ease-out forwards;
}