/* News Ticker 2: announcement marquee with trust badges (Theme Settings > Header > Newsticker Style). */

/* Bar: gradient built from the Customize Color announcement background. The ID keeps it above the theme ticker background in theme-colors.css. */
#navbar_top .newsticker-2-bar {
    position: relative;
    overflow: hidden;
    padding: 0;
    background: linear-gradient(90deg,
        color-mix(in srgb, var(--store-ticker-bg, #0d4f44) 78%, #000000) 0%,
        color-mix(in srgb, var(--store-ticker-bg, #0d4f44) 90%, #000000) 45%,
        var(--store-ticker-bg, #0d4f44) 55%,
        color-mix(in srgb, var(--store-ticker-bg, #0d4f44) 88%, #000000) 70%,
        color-mix(in srgb, var(--store-ticker-bg, #0d4f44) 76%, #000000) 100%) !important;
    color: var(--store-ticker-text, #ffffff);
    border-bottom: 0;
}

/* Lighter diagonal sheen in the middle of the bar. */
#navbar_top .newsticker-2-bar::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 42%;
    width: 18%;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.07) 50%, rgba(255, 255, 255, 0) 100%);
    transform: skewX(-28deg);
    pointer-events: none;
}

#navbar_top .newsticker-2-bar > .container {
    position: relative;
    z-index: 1;
}

.newsticker-2-inner {
    display: flex;
    align-items: center;
    height: 42px;
    min-width: 0;
}

/* Left: truck icon + scrolling announcement. Takes the space left of the badges. */
.newsticker-2-announcement {
    display: flex;
    flex: 1 1 auto;
    align-items: center;
    gap: 10px;
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
}

.newsticker-2-bar .newsticker-2-truck {
    flex: 0 0 auto;
    font-size: 18px;
    line-height: 1;
    color: var(--store-ticker-text, #ffffff);
}

.newsticker-2-bar .newsticker-2-marquee {
    display: block;
    flex: 1 1 auto;
    min-width: 0;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.4;
    color: var(--store-ticker-text, #ffffff);
}

/* Right: trust badges separated by thin dividers. */
.newsticker-2-badges {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    white-space: nowrap;
}

.newsticker-2-bar .newsticker-2-badge {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-left: 16px;
    padding-left: 16px;
    font-size: 13.5px;
    font-weight: 500;
    line-height: 1;
    color: var(--store-ticker-text, #ffffff);
}

.newsticker-2-badge::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 0;
    width: 1px;
    height: 18px;
    background: color-mix(in srgb, var(--store-ticker-text, #ffffff) 35%, transparent);
    transform: translateY(-50%);
}

.newsticker-2-bar .newsticker-2-badge i {
    font-size: 16px;
    line-height: 1;
}

/* Tablet: smaller text, then icon-only badges. */
@media (max-width: 1199.98px) {
    .newsticker-2-bar .newsticker-2-marquee {
        font-size: 14px;
    }
    .newsticker-2-bar .newsticker-2-badge {
        margin-left: 12px;
        padding-left: 12px;
        font-size: 12.5px;
    }
}

@media (max-width: 991.98px) {
    .newsticker-2-bar .newsticker-2-badge {
        margin-left: 10px;
        padding-left: 10px;
    }
    .newsticker-2-badge .newsticker-2-badge-text {
        display: none;
    }
    .newsticker-2-bar .newsticker-2-badge i {
        font-size: 15px;
    }
}

/* Mobile: announcement only, full width. */
@media (max-width: 767px) {
    .newsticker-2-inner {
        height: 36px;
    }
    .newsticker-2-announcement {
        gap: 8px;
    }
    .newsticker-2-bar .newsticker-2-truck {
        font-size: 15px;
    }
    .newsticker-2-bar .newsticker-2-marquee {
        font-size: 13px;
    }
    .newsticker-2-badges {
        display: none;
    }
}
