/* Headlines Slider CSS - Vertical scrolling */
.headlines-slider {
    position: relative;
    /* flexible width to fill space between contact and social icons */
    flex: 1 1 auto;
    width: auto;
    height: 42px;
    overflow: hidden;
    background: transparent;
    border-radius: 20px;
    padding: 0 10px;
    display: flex;
    align-items: center; /* center label and track */
    justify-content: flex-start;
    margin-left: 0;
    margin-right: 0;
    gap: 15px;
}

.headlines-slider::before {
    display: none; /* Gradient overlay kaldırıldı */
}

.headlines-label {
    position: relative;
    z-index: 5;
    color: white;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    background: rgba(255, 185, 0, 0.25);
    border-radius: 12px;
    border: 1px solid rgba(255, 185, 0, 0.4);
    min-width: 60px;
    text-align: center;
    flex-shrink: 0;
    height: 42px;
    padding: 0 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Track: allow full height of content; container clips */
.headlines-track {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    animation: none; /* JS controls animation */
    width: 100%;
    height: 100%; /* match slider height so only one row is visible */
    flex: 0 0 auto;
    min-width: 0;
    will-change: transform;
    overflow: hidden; /* clip to container so partial rows are hidden */
    justify-content: flex-start;
    transform: translate3d(0,0,0);
}

/* Each item should be an exact row matching the slider height */
.headlines-track > .headline-item {
    flex: 0 0 auto;
    width: 100%;
    height: 42px;
}

.headline-item {
    height: 100%;
    box-sizing: border-box;
    overflow: hidden;
    position: relative;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.headline-item a {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    color: white;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.3s ease;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    position: relative;
    height: 100%; /* fill the row */
    padding: 0;
    width: 100%;
    gap: 8px;
    min-width: 0;
}

.headline-item a:hover {
        margin-left: 5px;
        margin-right: 5px;
}

.headline-item a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: #ffd700;
    transition: width 0.3s ease;
}

.headline-item a:hover::after {
    width: 100%;
}

.headline-title {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
    min-width: 0;
}

.headline-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 10px;
    height: 22px;
    line-height: 1;
    padding: 0 8px;
    border-radius: 12px;
    font-weight: 700;
    text-transform: uppercase;
    flex-shrink: 0;
}

.headline-badge.blog {
    background: rgba(255, 185, 0, 0.25);
    border: 1px solid rgba(255, 185, 0, 0.4);
}

.headline-badge.news {
    background: rgba(52, 152, 219, 0.25);
    border: 1px solid rgba(52, 152, 219, 0.4);
}

/* Pixel-perfect step animation to avoid subpixel bleed */
@keyframes slideHeadlinesStep40 {
    0% { transform: translateY(0); }
    6.66% { transform: translateY(0); }         /* 2s bekle */
    10% { transform: translateY(-40px); }       /* 1s kay */
    16.66% { transform: translateY(-40px); }    /* 2s bekle */
    20% { transform: translateY(-80px); }
    26.66% { transform: translateY(-80px); }
    30% { transform: translateY(-120px); }
    36.66% { transform: translateY(-120px); }
    40% { transform: translateY(-160px); }
    46.66% { transform: translateY(-160px); }
    50% { transform: translateY(-200px); }
    56.66% { transform: translateY(-200px); }
    60% { transform: translateY(-240px); }
    66.66% { transform: translateY(-240px); }
    70% { transform: translateY(-280px); }
    76.66% { transform: translateY(-280px); }
    80% { transform: translateY(-320px); }
    86.66% { transform: translateY(-320px); }
    90% { transform: translateY(-360px); }
    96.66% { transform: translateY(-360px); }
    100% { transform: translateY(-360px); }
}

.headlines-slider:hover .headlines-track {
    animation-play-state: paused;
}

/* If JS takes over, disable the CSS animation to avoid conflicts */
.headlines-track.js-enabled {
    animation: none;
}

/* Responsive */
@media (max-width: 768px) {
    .headlines-slider {
        height: 35px;
        gap: 12px;
    }
    
    .headlines-label {
        height: 42px;
        padding: 0 10px;
        font-size: 11px;
        min-width: 50px;
    }
    
    .headlines-track > .headline-item {
        height: 35px;
    }
    
    .headline-item a {
        font-size: 12px;
        gap: 6px;
    }
    
    .headline-badge {
        font-size: 9px;
        height: 18px;
        padding: 0 6px;
    }
}

@media (max-width: 480px) {
    .headlines-slider {
        height: 42px;
        gap: 10px;
    }
    
    .headlines-label {
        height: 30px;
        padding: 0 8px;
        font-size: 10px;
        min-width: 45px;
    }
    
    .headlines-track > .headline-item {
        height: 30px;
    }
    
    .headline-item a {
        font-size: 10px;
        gap: 5px;
    }
    
    .headline-badge {
        font-size: 8px;
        height: 16px;
        padding: 0 5px;
    }
}