:root {
    --fin-bg: #0a0c10;
    --fin-panel: #131722;
    --fin-border: #1e222d;
    --fin-gold: #ffd700;
    --fin-green: #089981;
    --fin-red: #f23645;
    --fin-blue: #2962ff;
}

/* --- STRUCTURE GLOBALE ET HOVER --- */
.etea-ticker-cyber-container {
    background: var(--fin-bg); border: 1px solid var(--fin-border);
    height: 36px; display: flex; align-items: center; overflow: hidden;
    font-family: 'Share Tech Mono', monospace; position: relative; border-radius: 4px;
    justify-content: space-between; flex-wrap: nowrap !important;
}

.etea-ticker-label {
    flex: 0 0 auto; background: var(--fin-gold); color: #000; font-weight: bold;
    padding: 0 15px; height: 100%; display: flex; align-items: center;
    font-size: 10px; letter-spacing: 1px; white-space: nowrap; z-index: 10;
}

.etea-ticker-static-section {
    flex: 0 0 25%; /* Prend 20% de l'espace, ne rétrécit pas trop */
    display: flex; 
    align-items: center; 
    height: 100%;
    padding: 0 5px; 
    border-right: 1px solid var(--fin-border); 
    white-space: nowrap; 
    justify-content: center;
    overflow: hidden;
}

.etea-ticker-content { 
    flex: 1; /* Partage l'espace restant équitablement */
    position: relative; 
    height: 100%; 
    min-width: 0; /* Important pour que l'ellipsis (tronquage) fonctionne */
    overflow: hidden; 
    border-right: 1px solid var(--fin-border);
}
.etea-ticker-earnings { border-right: 1px solid var(--fin-border); }
.etea-ticker-performers { 
    flex: 1.2 !important; /* On lui donne un peu plus de place qu'aux earnings */
    min-width: 0 !important; /* SUPPRIMER les 400px qui cassent tout */
    border-right: none; /* Dernière section, pas de bordure à droite */
}
.etea-ticker-mobile { display: none; } 

/* --- ANIMATION ET TAILLE DES ITEMS --- */
.etea-ticker-item {
    position: absolute; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%;
    display: flex; 
    align-items: center; 
    opacity: 0;
    box-sizing: border-box; /* CRUCIAL : Pour que le padding soit inclus dans les 100% de largeur */
    transform: translate3d(0, 100%, 0); /* On commence bien en dessous */
    transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.23, 1, 0.32, 1), background 0.3s ease;
    visibility: hidden; 
    padding: 0 15px; 
    justify-content: flex-start;
    backface-visibility: hidden;
    will-change: transform, opacity;
}
.etea-ticker-item.active { opacity: 1; transform: translate3d(0, 0, 0); visibility: visible; }
.etea-ticker-item.active:hover { 
    background: rgba(255, 215, 0, 0.1) !important; 
    cursor: pointer;
}
.etea-ticker-item.exit { opacity: 0; transform: translate3d(0, -15px, 0); }

/* --- EFFETS HOVER --- */
.etea-ticker-item:hover { background: rgba(255, 215, 0, 0.08) !important; }
.etea-ticker-anchor:hover .etea-ticker-text { color: #fff; transform: translateX(5px); }
.etea-ticker-anchor .etea-ticker-text { transition: all 0.3s ease; }
.etea-ticker-item:hover .etea-mini-logo { box-shadow: 0 0 10px rgba(255, 255, 255, 0.5); transform: scale(1.1); }
.etea-mini-logo { transition: transform 0.3s ease, box-shadow 0.3s ease; }
.etea-ticker-item:hover .etea-ticker-tag { filter: brightness(1.2); }

/* INDICATEURS ET COULEURS DYNAMIQUES */
.etea-dir-bullish { color: var(--fin-green); font-weight: bold; }
.etea-dir-bearish { color: var(--fin-red); font-weight: bold; }
.etea-val-pos { color: var(--fin-green) !important; font-weight: bold; }
.etea-val-neg { color: var(--fin-red) !important; font-weight: bold; }
.bullish { color: var(--fin-green); font-weight: bold; }
.bearish { color: var(--fin-red); font-weight: bold; }

/* Correction de l'alignement du texte dans le hover */
.etea-ticker-anchor { 
    text-decoration: none; 
    display: flex; 
    align-items: center; 
    width: 100%; 
    height: 100%;
    color: inherit;
}

.etea-ticker-tag { font-size: 8px; font-weight: bold; padding: 2px 6px; border-radius: 2px; margin-right: 12px; text-transform: uppercase; flex-shrink: 0; }
.etea-ticker-tag.pos { background: var(--fin-green); color: #fff; }
.etea-ticker-tag.neg { background: var(--fin-red); color: #fff; }
.etea-ticker-tag.neutral { background: var(--fin-blue); color: #fff; }

.etea-ticker-body { display: flex; align-items: center; gap: 10px; overflow: hidden; justify-content: flex-start; width: 100%; padding-left: 5px; }
.etea-mini-logo { width: 20px; height: 20px; border-radius: 50%; background: #fff; padding: 2px; flex-shrink: 0; }
.etea-ticker-text { 
    color: #d1d4dc; 
    font-size: 11px; 
    white-space: nowrap; 
    overflow: hidden; 
    text-overflow: ellipsis; /* Affiche ... si le texte est trop long pour sa colonne */
    display: block;
}

.etea-ticker-cyber-container p {
    margin: 0 !important;
    padding: 0 !important;
    display: contents !important; /* Très important : annule l'effet de bloc du <p> */
}

.etea-ticker-upgrade-btn {
    flex: 0 0 auto !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    background: var(--fin-gold) !important;
    color: #000 !important;
    text-decoration: none !important;
    font-size: 10px !important;
    font-weight: 900 !important;
    padding: 0 15px !important;
    height: 100% !important;
    z-index: 1000 !important;
    white-space: nowrap;
}

/* Classe d'alerte Live Radar */
.pos-glow {
    color: var(--fin-green) !important;
    text-shadow: 0 0 8px rgba(8, 153, 129, 0.6);
    font-weight: bold;
    animation: etea-pulse-glow 2s infinite ease-in-out;
}

@keyframes etea-pulse-glow {
    0%, 100% { 
        opacity: 1; 
        text-shadow: 0 0 8px rgba(8, 153, 129, 0.6);
    }
    50% { 
        opacity: 0.8; 
        text-shadow: 0 0 15px rgba(8, 153, 129, 1);
        transform: scale(1.02);
    }
}

/* Badge spécifique pour le Radar */
.etea-ticker-tag.radar-live {
    background: var(--fin-blue);
    box-shadow: 0 0 10px rgba(41, 98, 255, 0.5);
    animation: radarBlink 1.5s infinite;
}

@keyframes radarBlink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Tickers masqués pour les Guests */
.etea-ticker-text strong.is-masked {
    letter-spacing: 2px;
    color: var(--fin-text-muted);
}

/* Style pour le badge "LOCKED" */
.etea-ticker-tag.locked {
    background: #343a40; /* Gris foncé type terminal */
    color: #adb5bd;
    border: 1px solid #495057;
}

/* Animation discrète pour le cadenas */
.etea-lock-icon-anim {
    display: inline-block;
    margin-right: 3px;
    font-size: 10px;
    vertical-align: middle;
}

/* Texte flouté pour les données verrouillées (optionnel mais très pro) */
.etea-ticker-text.is-blurred {
    filter: blur(3px);
    opacity: 0.7;
    user-select: none;
}

/* RESPONSIVE */
@media (max-width: 1200px) { .etea-ticker-text { font-size: 10px; } }

@media (max-width: 768px) {
    .etea-ticker-label { display: none; }
    .etea-ticker-static-section { padding: 0 5px; border-right: none; min-width: auto; flex: 0 0 auto; }
    .etea-mood-wrapper { display: none !important; }
    .etea-ticker-earnings, .etea-ticker-performers { display: none !important; }
    .etea-ticker-mobile { display: block !important; flex: 1; }
    .etea-ticker-item { padding: 0 5px; }
    .etea-ticker-tag { margin-right: 8px; font-size: 7px; padding: 2px 4px; }
}
@media (max-width: 480px) {
    .etea-ticker-upgrade-btn { padding: 0 8px !important; font-size: 9px !important; }
}
