/* ==========================================================================
   UNIFIED HEADER - Watts Else?
   Style uniforme pour tous les headers de page
   ========================================================================== */

/* --------------------------------------------------------------------------
   BASE : Fond Midnight Blue uniforme
   -------------------------------------------------------------------------- */
.unified-header {
    background: linear-gradient(135deg, #0F172A 0%, #1E293B 100%);
    position: relative;
    overflow: hidden;
}

/* Pattern de fond subtil (texture tech) */
.unified-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: radial-gradient(circle at 1px 1px, rgba(255,255,255,0.03) 1px, transparent 0);
    background-size: 24px 24px;
    pointer-events: none;
    z-index: 1;
}

/* --------------------------------------------------------------------------
   GLOW : Lueur colorée par section
   -------------------------------------------------------------------------- */
.unified-header .glow {
    position: absolute;
    width: 50vw;
    height: 50vw;
    max-width: 600px;
    max-height: 600px;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.3;
    pointer-events: none;
    z-index: 2;
    top: -30%;
    right: -15%;
}

/* Couleurs par section */
.glow-yellow { background: #FFD500; }
.glow-green { background: #10B981; }
.glow-cyan { background: #06B6D4; }
.glow-orange { background: #F59E0B; }
.glow-violet { background: #8B5CF6; }
.glow-pink { background: #EC4899; }
.glow-blue { background: #3B82F6; }
.glow-teal { background: #2A9D8F; }

/* --------------------------------------------------------------------------
   CONTENU : Structure standard
   -------------------------------------------------------------------------- */
.unified-header .header-content {
    position: relative;
    z-index: 10;
}

/* Titre avec mot en couleur */
.unified-header h1 {
    color: white;
}

.text-accent-yellow { color: #FFD500; }
.text-accent-green { color: #10B981; }
.text-accent-cyan { color: #06B6D4; }
.text-accent-orange { color: #F59E0B; }
.text-accent-violet { color: #8B5CF6; }
.text-accent-pink { color: #EC4899; }
.text-accent-blue { color: #3B82F6; }
.text-accent-teal { color: #2A9D8F; }

/* Dégradé sur texte */
.text-gradient-yellow {
    background: linear-gradient(135deg, #FFD500, #FFA500);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-gradient-green {
    background: linear-gradient(135deg, #10B981, #2DD4BF);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* --------------------------------------------------------------------------
   STATS FLOATING : Modern Minimalist Dashboard Design
   Clean white cards with subtle shadows - SaaS-style
   -------------------------------------------------------------------------- */
.floating-stats {
    position: relative;
    z-index: 20;
    margin-top: -4rem;
    padding: 0 1rem;
}

.floating-stats-inner {
    max-width: 72rem;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    padding: 0;
    background: transparent;
}

@media (min-width: 640px) {
    .floating-stats-inner {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.25rem;
    }
}

@media (min-width: 768px) {
    .floating-stats-inner {
        grid-template-columns: repeat(4, 1fr);
        gap: 1.5rem;
    }
}

/* Individual Stat Card - Clean White Design */
.floating-stat {
    text-align: center;
    padding: 2rem 1.5rem;
    position: relative;

    /* Clean white background */
    background: #ffffff;

    /* Subtle rounded corners */
    border-radius: 0.75rem;

    /* Very subtle drop shadow */
    box-shadow:
        0 1px 3px 0 rgba(0, 0, 0, 0.05),
        0 1px 2px 0 rgba(0, 0, 0, 0.03);

    border: 1px solid rgba(226, 232, 240, 0.8);

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

.floating-stat:hover {
    box-shadow:
        0 4px 6px -1px rgba(0, 0, 0, 0.08),
        0 2px 4px -1px rgba(0, 0, 0, 0.05);
    transform: translateY(-2px);
    border-color: rgba(203, 213, 225, 0.9);
}

/* Make button variant clickable */
.floating-stat.cursor-pointer:hover {
    border-color: rgba(59, 130, 246, 0.2);
}

/* Card 4: AI Card with Purple Border */
.floating-stat.floating-stat-ai {
    background: #ffffff;
    border: 2px solid #a855f7;
    box-shadow:
        0 1px 3px 0 rgba(168, 85, 247, 0.1),
        0 1px 2px 0 rgba(168, 85, 247, 0.06);
}

.floating-stat.floating-stat-ai:hover {
    box-shadow:
        0 4px 6px -1px rgba(168, 85, 247, 0.15),
        0 2px 4px -1px rgba(168, 85, 247, 0.1);
    border-color: #9333ea;
}

/* Icon Container - Elegant Light Style */
.stat-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 0.375rem;
    margin-bottom: 0.75rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.stat-icon i {
    font-size: 0.875rem;
    position: relative;
    z-index: 1;
}

.floating-stat:hover .stat-icon {
    transform: translateY(-2px);
}

/* Orange gradient icon (Sujets Brûlants) */
.bg-gradient-to-br.from-amber-400 {
    background: linear-gradient(135deg, #fef3c7 0%, #fed7aa 100%);
    color: #ea580c;
    border: 1px solid #fdba74;
    box-shadow:
        0 1px 3px 0 rgba(251, 146, 60, 0.15),
        0 0 0 1px rgba(251, 146, 60, 0.05);
}

.floating-stat:hover .bg-gradient-to-br.from-amber-400 {
    background: linear-gradient(135deg, #fed7aa 0%, #fdba74 100%);
    box-shadow:
        0 4px 6px -1px rgba(251, 146, 60, 0.2),
        0 2px 4px -1px rgba(251, 146, 60, 0.1);
}

/* Blue gradient icon (Sources) */
.bg-gradient-to-br.from-blue-400 {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    color: #2563eb;
    border: 1px solid #93c5fd;
    box-shadow:
        0 1px 3px 0 rgba(59, 130, 246, 0.15),
        0 0 0 1px rgba(59, 130, 246, 0.05);
}

.floating-stat:hover .bg-gradient-to-br.from-blue-400 {
    background: linear-gradient(135deg, #bfdbfe 0%, #93c5fd 100%);
    box-shadow:
        0 4px 6px -1px rgba(59, 130, 246, 0.2),
        0 2px 4px -1px rgba(59, 130, 246, 0.1);
}

/* Green gradient icon (Fréquence) */
.bg-gradient-to-br.from-emerald-400 {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    color: #059669;
    border: 1px solid #6ee7b7;
    box-shadow:
        0 1px 3px 0 rgba(16, 185, 129, 0.15),
        0 0 0 1px rgba(16, 185, 129, 0.05);
}

.floating-stat:hover .bg-gradient-to-br.from-emerald-400 {
    background: linear-gradient(135deg, #a7f3d0 0%, #6ee7b7 100%);
    box-shadow:
        0 4px 6px -1px rgba(16, 185, 129, 0.2),
        0 2px 4px -1px rgba(16, 185, 129, 0.1);
}

/* Neutral gray icon for AI card */
.stat-icon-neutral {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    color: #374151;
    border: 1px solid #d1d5db;
    box-shadow:
        0 1px 3px 0 rgba(55, 65, 81, 0.15),
        0 0 0 1px rgba(55, 65, 81, 0.05);
}

.floating-stat:hover .stat-icon-neutral {
    background: linear-gradient(135deg, #e5e7eb 0%, #d1d5db 100%);
    box-shadow:
        0 4px 6px -1px rgba(55, 65, 81, 0.2),
        0 2px 4px -1px rgba(55, 65, 81, 0.1);
}

/* Stat Value - Large Bold Number */
.floating-stat-value {
    font-size: 2.25rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.02em;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    margin-top: 0.5rem;
    color: #0f172a;
    transition: all 0.3s ease;
}

/* Stat Label - Small Uppercase Gray Text */
.floating-stat-label {
    font-size: 0.625rem;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-top: 0.5rem;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* AI Card Specific Labels */
.floating-stat-label-ai {
    font-size: 0.75rem;
    font-weight: 700;
    color: #0f172a;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 0.75rem;
    margin-bottom: 0.25rem;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.floating-stat-sublabel {
    font-size: 0.625rem;
    font-weight: 500;
    color: #64748b;
    letter-spacing: 0.02em;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Remove old visualization styles */
.mini-sparkline,
.mini-progress-ring {
    display: none;
}

/* --------------------------------------------------------------------------
   COURBE DE TRANSITION
   -------------------------------------------------------------------------- */
.header-curve {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3rem;
    background: #F8FAFC;
    border-radius: 2rem 2rem 0 0;
    transform: translateY(50%);
    z-index: 5;
}

/* --------------------------------------------------------------------------
   BARRE DE RECHERCHE UNIFIÉE
   -------------------------------------------------------------------------- */
.unified-search-wrapper {
    position: relative;
    max-width: 48rem;
    margin: 0 auto;
}

.unified-search-wrapper input {
    width: 100%;
    padding: 1.25rem 4rem 1.25rem 3.5rem;
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 1rem;
    font-size: 1rem;
    color: #0F172A;
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.2);
}

.unified-search-wrapper input:focus {
    outline: none;
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.2), 0 0 0 3px rgba(42, 157, 143, 0.2);
}

.unified-search-wrapper .search-icon {
    position: absolute;
    left: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    color: #64748B;
}

.unified-search-wrapper .search-btn {
    position: absolute;
    right: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}

.unified-search-wrapper .search-btn:hover {
    filter: brightness(1.1);
}

/* --------------------------------------------------------------------------
   ANIMATIONS
   -------------------------------------------------------------------------- */
.fade-up {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.6s ease forwards;
}

.fade-up-1 { animation-delay: 0.1s; }
.fade-up-2 { animation-delay: 0.2s; }
.fade-up-3 { animation-delay: 0.3s; }

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