/* ============================================================
   F-News Ticker – Frontend Styles
   ============================================================ */

.fnews-ticker {
    --fnews-bg:  #cc0000;
    --fnews-lbg: #900000;
    --fnews-tc:  #ffffff;

    display: flex;
    align-items: stretch;
    overflow: hidden;
    background: var(--fnews-bg);
    color: var(--fnews-tc);
    font-family: inherit;
    font-size: 0.92rem;
    line-height: 1;
    border-radius: 3px;
    min-height: 38px;
    box-shadow: 0 2px 6px rgba(0,0,0,.18);
    position: relative;
    width: 100%;
}

/* Label */
.fnews-ticker__label {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    padding: 0 14px;
    background: var(--fnews-lbg);
    font-weight: 700;
    font-size: 0.82rem;
    letter-spacing: .06em;
    text-transform: uppercase;
    white-space: nowrap;
    color: var(--fnews-tc);
    z-index: 2;
    /* Kleines Dreieck rechts */
    clip-path: polygon(0 0, calc(100% - 8px) 0, 100% 50%, calc(100% - 8px) 100%, 0 100%);
    padding-right: 22px;
}

/* Scrollfenster */
.fnews-ticker__window {
    flex: 1;
    overflow: hidden;
    display: flex;
    align-items: center;
    /* Fade-out links und rechts */
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 2%, black 98%, transparent 100%);
    mask-image: linear-gradient(to right, transparent 0%, black 2%, black 98%, transparent 100%);
}

/* Laufende Spur */
.fnews-ticker__track {
    display: flex;
    align-items: center;
    white-space: nowrap;
    animation: fnews-scroll linear infinite;
    animation-duration: 30s; /* wird inline überschrieben */
    will-change: transform;
}

.fnews-ticker__track:hover {
    animation-play-state: paused;
}

@keyframes fnews-scroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* Einzelner Eintrag */
.fnews-ticker__item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0 4px;
}

.fnews-ticker__item a {
    color: var(--fnews-tc) !important;
    text-decoration: none !important;
    font-weight: 500;
    transition: opacity .15s;
}

.fnews-ticker__item a:hover {
    opacity: .75;
    text-decoration: underline !important;
}

/* Datum */
.fnews-ticker__date {
    font-size: 0.78rem;
    opacity: .75;
    font-style: italic;
}

/* Trennzeichen */
.fnews-ticker__sep {
    margin: 0 10px;
    opacity: .5;
    font-size: 0.75rem;
    letter-spacing: .1em;
}

/* Leer-Zustand */
.fnews-ticker--empty {
    justify-content: center;
    padding: 8px 16px;
    font-size: 0.85rem;
    opacity: .7;
}

/* ---- Responsive ---- */
@media (max-width: 480px) {
    .fnews-ticker {
        font-size: 0.85rem;
        min-height: 34px;
    }
    .fnews-ticker__label {
        font-size: 0.75rem;
        padding: 0 10px 0 10px;
        padding-right: 18px;
    }
}
