/* THE MAIN BAR */
.news-ticker {
    margin-left: 75px;
    margin-top:20px;
    display: flex;
    align-items: center;
    background: none;
    height: 50px;
    overflow: hidden;
    width: 70em;
    height: 3em;
    font-family: 'Jost', sans-serif;
}

/* THE RED STATIC BOX */
.ticker-title {
    background: #f13939;
    color: white;
    padding: 0 40px;
    height: 100%;
    width: 2.9em;
    display: flex;
    align-items: center;
    font-size: 15px;
    font-family: 'Franklin Gothic Medium', 'Arial Narrow', Arial, sans-serif;
    position: relative;
    z-index: 10;
    white-space: nowrap;
}

/* THE WHITE PULSE ON THE RED BOX */
.ticker-title::before {
    content: '';
    position: absolute;
    left: 15px;
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
    animation: pulse-ring 1.5s infinite;
}

/* THE SCROLLING AREA */
.ticker-content {
    flex-grow: 1;
    overflow: hidden;
}

.ticker-text {
    display: flex;
    white-space: nowrap;
    animation: ticker-scroll 25s linear infinite;
    font-weight: 900
}

/* INDIVIDUAL ITEM (IMAGE + TEXT) */
.ticker-item {
    display: flex;
    align-items: center;
    margin-right: 80px; /* Space between news groups */
}

.ticker-img {
    width: 75px;
    height: 55px;
    object-fit: cover;
    margin-right: 15px;
    border: 1px solid #ffcc00;
    border-radius: 4px;
}

.ticker-item span {
    color: white;
    font-size: 14px;
    text-transform: uppercase;
}

/* ANIMATIONS */
@keyframes ticker-scroll {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

@keyframes pulse-ring {
    0% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(255, 255, 255, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0); }
}

/* --- MOBILE RESPONSIVE TICKER --- */
@media screen and (max-width: 1024px) {
    .news-ticker {
        margin-left: 0;         /* Remove desktop offset */
        margin-top: 10px;
        width: 100%;            /* Ensure it spans full screen width */
        height: 50px;           /* Standardize height */
        border-top: 1px solid rgba(255,255,255,0.1);
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }

    .ticker-title {
        padding: 0 15px 0 35px; /* Reduce padding for smaller screens */
        font-size: 12px;        /* Smaller "BREAKING" text */
        width: auto;            /* Let it shrink to text size */
    }

    .ticker-title::before {
        left: 10px;             /* Shift the pulse dot slightly */
        width: 6px;
        height: 6px;
    }

    .ticker-img {
        width: 50px;            /* Smaller images for mobile */
        height: 35px;
        margin-right: 10px;
    }

    .ticker-item {
        margin-right: 40px;     /* Reduce gap between news items */
    }

    .ticker-item span {
        font-size: 11px;        /* More readable size for small displays */
        letter-spacing: 0.5px;
    }

    /* Adjust animation speed for mobile */
    /* Since the screen is narrower, the text travels less distance; 
       speeding it up slightly keeps it feeling "urgent" */
    .ticker-text {
        animation: ticker-scroll 18s linear infinite;
    }
}