/**
 * /assets/breaking-news.css v3.0
 * Cintillo "Última Hora" — estilo editorial, rojo periódico clásico.
 * Inspirado en TV news internacional (Reuters, AFP), no alerta chillona.
 */

.wh-breaking {
    position: sticky;
    top: 0;
    z-index: 998;
    background: #8B0000;
    color: #fff;
    border-top: 1px solid rgba(255,255,255,0.08);
    box-shadow: 0 2px 12px rgba(139, 0, 0, 0.25);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.wh-breaking-inner {
    display: flex;
    align-items: stretch;  /* el bloque del label ocupa toda la altura */
    max-width: 1280px;
    margin: 0 auto;
    color: #fff !important;
    text-decoration: none !important;
    min-height: 44px;
}

/* Pill/bloque del label "ÚLTIMA HORA" — más oscuro a la izquierda */
.wh-breaking-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0 20px;
    background: #5C0000;  /* rojo más profundo aún */
    font-size: 12px !important;
    font-weight: 800 !important;
    text-transform: uppercase;
    letter-spacing: 2px;  /* spacing generoso, tipo news ticker */
    white-space: nowrap;
    flex-shrink: 0;
    position: relative;
}

/* Cuña/flecha sutil después del label (crea separación tipo broadcast) */
.wh-breaking-label::after {
    content: '';
    position: absolute;
    right: -8px;
    top: 0;
    bottom: 0;
    width: 0;
    height: 0;
    border-top: 22px solid transparent;
    border-bottom: 22px solid transparent;
    border-left: 8px solid #5C0000;
    z-index: 1;
}

/* Punto rojo pequeño y discreto, no agresivo */
.wh-breaking-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #fff;
    flex-shrink: 0;
    opacity: 0.9;
    animation: wh-breaking-breathe 2.4s ease-in-out infinite;
}

@keyframes wh-breaking-breathe {
    0%, 100% { opacity: 0.4; transform: scale(1); }
    50%      { opacity: 1;   transform: scale(1.15); }
}

/* Titular de la noticia */
.wh-breaking-title {
    display: flex;
    align-items: center;
    padding: 10px 20px 10px 28px;  /* padding extra izq por la cuña */
    font-size: 15px !important;
    font-weight: 500 !important;
    line-height: 1.35;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    flex: 1;
    min-width: 0;  /* permite al flex item encogerse correctamente */
}

/* Modo link: hover subraya título y el bloque se ilumina ligeramente */
a.wh-breaking-inner:hover .wh-breaking-title {
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

a.wh-breaking-inner:hover .wh-breaking-label {
    background: #4A0000;
}

/* Modo texto libre: cursor normal */
.wh-breaking-static {
    cursor: default;
    user-select: text;
}

/* Responsive mobile */
@media (max-width: 640px) {
    .wh-breaking-label {
        padding: 0 14px;
        font-size: 10px !important;
        letter-spacing: 1.5px;
    }
    .wh-breaking-title {
        font-size: 13px !important;
        padding: 8px 14px 8px 22px;
    }
    .wh-breaking-label::after {
        border-top-width: 18px;
        border-bottom-width: 18px;
    }
}
