/* §10 — News Ticker: pinned to the very top of the page, above the nav.
 * Height feeds the --tox-ticker-h variable that offsets the fixed nav + content. */
.tox-ticker {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10060; /* above the floating nav (10002) */
    height: 40px;
    display: flex;
    align-items: stretch;
    width: 100%;
    /* Match the header "Request onboarding" Top Bar: dark navy base + a diagonal
     * blue light-sheen overlay that sweeps across on hover (background-size grows). */
    background-color: #0F172A;
    background-image: linear-gradient(135deg, rgba(255, 255, 255, 0) 0%, rgba(29, 172, 228, 0.05) 25%, rgba(29, 172, 228, .5) 30%, rgba(29, 172, 228, 0.1) 40%, rgba(255, 255, 255, 0) 100%);
    background-size: 100% 100%;
    background-position: 0%;
    box-shadow: inset 0 -1px 0 0 rgba(255, 255, 255, 0.1);
    color: #e6edf7;
    /* Telex — a classic, evenly-weighted grotesque that reads like a newswire/teletype
     * ticker. Loaded via Google Fonts (enqueued in the plugin). */
    font-family: "Telex", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    font-size: 0.85rem;
    letter-spacing: 0.005em;
    overflow: hidden;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                background-size 1200ms cubic-bezier(0.147, 0.723, 0.068, 0.973);
}
/* Light sweep on hover — same easing/scale as the header Top Bar. */
.tox-ticker:hover {
    background-size: 300% 100%;
}
/* Collapsed (manual) OR scrolled-away: slide the bar out of view; nav returns
 * to the very top. Scroll-away is driven by JS (tox-ticker--scrolled). */
.tox-ticker.tox-ticker--collapsed,
.tox-ticker.tox-ticker--scrolled {
    transform: translateY(-100%);
}

/* Small tab that reappears (top-right) so the ticker can be re-opened. */
.tox-ticker-reopen {
    position: fixed;
    top: 0;
    right: 12px;
    z-index: 10061;
    width: 34px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-top: none;
    border-radius: 0 0 8px 8px;
    background: rgba(255, 255, 255, 0.95);
    border-color: rgba(0, 0, 0, 0.1);
    color: #334155;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}
.tox-ticker-reopen[hidden] { display: none; }
.tox-ticker-reopen:hover { background: #fff; color: #0f172a; }

/* Collapse toggle inside the bar (right side). */
.tox-ticker__toggle {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    border: none;
    background: transparent;
    color: #4B5563;
    cursor: pointer;
    transition: color 0.2s ease;
}
.tox-ticker__toggle:hover { color: #0f172a; }
.tox-ticker__label {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    padding: 0 1.1rem;
    background: #1dace4;
    color: #fff;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    font-size: 0.72rem;
    white-space: nowrap;
}
.tox-ticker__viewport {
    position: relative;
    flex: 1 1 auto;
    display: flex;
    align-items: center;      /* vertically centre the scrolling text in the 40px bar */
    overflow: hidden;
    -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 3%, #000 97%, transparent 100%);
            mask-image: linear-gradient(90deg, transparent 0, #000 3%, #000 97%, transparent 100%);
}
.tox-ticker__track {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    padding: 0;
    will-change: transform;
    animation: tox-ticker-scroll linear infinite;
}
/* Hover no longer hard-pauses the scroll — the speed is eased down to a stop
 * (ease-out) and back up to full (ease-in) in JS by ramping the animation's
 * playbackRate. See initTicker() in redesign-v2.js. */
.tox-ticker__item {
    color: #e6edf7;
    padding: 0 0.35rem;
}
/* Critical alert item — SOLID red pill, white bold text + warning icon (line
 * prefixed with "!"). `!important` so it can't be softened by the base item rule. */
.tox-ticker .tox-ticker__item--alert {
    display: inline-flex !important;
    align-items: center;
    gap: 0.4rem;
    margin: 0 0.4rem;
    padding: 0.15rem 0.7rem;
    color: #ffffff !important;
    font-weight: 800 !important;
    background: #dc2626 !important;
    border-radius: 6px;
    box-shadow: 0 1px 6px rgba(220, 38, 38, 0.45);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    font-size: 0.78rem;
    animation: tox-alert-pulse 1.4s ease-in-out infinite;
}
.tox-ticker .tox-ticker__item--alert svg { flex: 0 0 auto; stroke: #ffffff; }
@keyframes tox-alert-pulse {
    0%, 100% { background: #dc2626; box-shadow: 0 1px 6px rgba(220,38,38,0.45); }
    50%      { background: #ef4444; box-shadow: 0 1px 12px rgba(220,38,38,0.75); }
}
@media (prefers-reduced-motion: reduce) {
    .tox-ticker__item--alert { animation: none; }
}
.tox-ticker__sep {
    color: rgba(29, 172, 228, 0.85);
    padding: 0 0.9rem;
    font-weight: 700;
}
@keyframes tox-ticker-scroll {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); } /* track is duplicated -> seamless */
}
@media (prefers-reduced-motion: reduce) {
    .tox-ticker__track { animation: none; }
}

/* ===== Feedback R1 (2026-07-20) — retro dot-matrix ticker, corporate blues, calm alert ===== */
/* Doto (OFL) — self-hosted dot-matrix font, replaces the external Telex. */
@font-face {
    font-family: "Doto";
    src: url("fonts/doto-latin.woff2") format("woff2");
    font-weight: 100 900;
    font-display: swap;
}
.tox-ticker {
    font-family: "Doto", "Telex", monospace;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: 0.03em;
}
/* Label box: corporate brand gradient (#2B5CA8 -> #1DACE4) instead of #1dace4. */
.tox-ticker__label {
    background: linear-gradient(135deg, #2b5ca8 0%, #1dace4 100%);
    font-family: "Doto", monospace;
    font-weight: 900;
}
/* Separators in brand cyan instead of #1dace4. */
.tox-ticker__sep { color: #1dace4; }
/* System alert: red TEXT on a neutral background (was a solid red pill). Icon stays. */
.tox-ticker .tox-ticker__item--alert {
    background: #f1f5f9 !important;
    color: #b91c1c !important;
    box-shadow: none !important;
    animation: none !important;
    border-radius: 3px;
}
.tox-ticker .tox-ticker__item--alert svg { stroke: #dc2626 !important; }

/* ===== Alert pin mode (2026-08): banner FIXED on the alert message(s) ===== */
.tox-ticker--pinned .tox-ticker__track {
    animation: none !important;
    width: 100%;
    justify-content: center;
    gap: 10px;
}
.tox-ticker--pinned .tox-ticker__viewport {
    -webkit-mask-image: none;
            mask-image: none;
    justify-content: center;
}
.tox-ticker--pinned .tox-ticker__label { background: #dc2626; }
.tox-ticker__all {
    color: #ffffff;
    font-size: 0.8rem;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 2px;
    margin-left: 12px;
    white-space: nowrap;
}
.tox-ticker__all:hover { color: #ffffff; opacity: .85; }

/* Notification ticker (2026-09): NO red — both end-boxes are semi-transparent
   glass; Grandview font; "click here" links; band always visible. */
.tox-ticker__ann {
    flex: 0 0 auto; display: flex; align-items: center; align-self: stretch;
    font-size: .72rem; white-space: nowrap; padding: 0 1.1rem; text-decoration: none;
}
.tox-ticker__link { color: inherit; text-decoration: underline; text-underline-offset: 2px; font-weight: 700; }
.tox-ticker__link:hover { opacity: .85; }

/* Grandview across the whole notification band. */
.tox-ticker--notif,
.tox-ticker--notif .tox-ticker__item,
.tox-ticker--notif .tox-ticker__label,
.tox-ticker--notif .tox-ticker__ann,
.tox-ticker--notif .tox-ticker__sep,
.tox-ticker--notif .tox-ticker__link,
.tox-ticker--notif .tox-ticker__item--alert {
    font-family: "Grandview", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif !important;
    font-weight: 400 !important;
    letter-spacing: .02em;
}
/* Glass end-boxes (left "21X Alert" label + right "All announcements"). */
.tox-ticker--notif .tox-ticker__label,
.tox-ticker--notif .tox-ticker__ann {
    background: rgba(255, 255, 255, 0.10) !important;
    -webkit-backdrop-filter: blur(10px);
            backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.22) !important;
    color: #ffffff !important;
    font-weight: 500 !important;
    letter-spacing: .05em !important;
    text-transform: uppercase;
}
.tox-ticker--notif .tox-ticker__ann:hover { background: rgba(255, 255, 255, 0.20) !important; }
/* Active notification pill: glass too (no red). */
.tox-ticker--notif .tox-ticker__item--alert {
    background: rgba(255, 255, 255, 0.10) !important;
    color: #ffffff !important;
    border: 1px solid rgba(255, 255, 255, 0.20);
    box-shadow: none !important;
}
.tox-ticker--notif .tox-ticker__item--alert svg { stroke: #ffffff !important; }
/* Always visible: defeat the news scroll-away/collapse transforms. */
.tox-ticker--notif.tox-ticker--scrolled,
.tox-ticker--notif.tox-ticker--collapsed { transform: none !important; }

/* "click here" in the ticker picked up the theme link blue — dark blue on the dark
   band, barely visible (client 2026-09). Bright brand cyan, underlined, white on hover. */
.tox-ticker .tox-ticker__link,
.tox-ticker--notif .tox-ticker__link {
    color: #7FD3FF !important;
    font-weight: 600 !important;
    text-decoration: underline !important;
    text-decoration-color: rgba(127, 211, 255, .55) !important;
    text-underline-offset: 3px;
}
.tox-ticker .tox-ticker__link:hover { color: #ffffff !important; opacity: 1; }
