:root {
    --shadow-deal: 0 16px 60px rgba(18, 24, 40, 0.20), 0 0 32px rgba(18, 24, 40, 0.10);
    --deal-rainbow: linear-gradient(105deg, #c94d08 0%, #cf247b 32%, #9742bd 65%, #286dd3 100%);
    --deal-slide-duration: 480ms;
    --deal-slide-easing: cubic-bezier(.22, 1, .36, 1);
}
html[data-theme="dark"] {
    --shadow-deal: 0 18px 64px rgba(0, 0, 0, 0.58), 0 0 36px rgba(0, 0, 0, 0.30);
}

/* Scheduled deals share the navigation shell, semantic colors and button system. */
.deal-strip {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    padding: 6px 0;
    border: 0;
    border-radius: 0;
    background: var(--deal-strip-background, var(--deal-rainbow));
    color: var(--deal-strip-text, #ffffff);
    overflow: hidden;
    min-height: 36px;
    pointer-events: auto;
}
.deal-ticker-link { display: block; width: 100%; color: inherit; text-decoration: none; }
.deal-ticker-link:hover { color: inherit; text-decoration: none; }
.deal-ticker-link:focus-visible { outline: 2px solid currentColor; outline-offset: -3px; }
.site-header.site-header--deal { padding-top: 0; display: flow-root; }
.site-header--deal .site-header-inner { margin-top: 14px; }
.site-header--deal .deal-strip {
    height: 36px;
    min-height: 0;
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
    transition: height var(--deal-slide-duration) var(--deal-slide-easing), padding var(--deal-slide-duration) var(--deal-slide-easing), transform var(--deal-slide-duration) var(--deal-slide-easing), opacity var(--deal-slide-duration) ease, visibility 0s;
}
/* Keep the outgoing placements painted until their slide has finished. */
.site-header--deal .deal-strip[hidden], .deal-pill[hidden] { display: flex !important; }
.site-header--deal .deal-strip[hidden] {
    height: 0;
    padding-block: 0;
    opacity: 0;
    transform: translateY(-100%);
    visibility: hidden;
    transition-delay: 0s, 0s, 0s, 0s, var(--deal-slide-duration);
}
.deal-ticker { min-width: 0; width: 100%; overflow: hidden; font-size: .8125rem; font-weight: 800; }
.deal-ticker-track { display: flex; width: max-content; animation: deal-ticker 55s linear infinite; }
.deal-ticker-set { display: flex; flex: none; align-items: center; justify-content: space-around; gap: 20px; min-width: max(var(--nav-container), 100vw); padding-inline: 10px; }
.deal-ticker-item { display: inline-flex; flex: none; align-items: center; gap: 20px; white-space: nowrap; }
.deal-ticker-message { text-transform: uppercase; }
.deal-ticker-dot { opacity: .9; }
@keyframes deal-ticker { to { transform: translateX(-50%); } }
.deal-timer { display: inline-flex; flex: none; align-items: center; gap: 8px; white-space: nowrap; font-variant-numeric: tabular-nums; font-weight: 700; }
.deal-timer--ticker { gap: 5px; padding: 3px 8px; border-radius: var(--radius-control); background: rgba(255, 255, 255, .18); font-size: .75rem; }
.deal-timer--ticker svg { width: 13px; height: 13px; }
.deal-pill {
    position: fixed;
    left: 50%;
    bottom: max(16px, env(safe-area-inset-bottom));
    z-index: 19;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-grid);
    width: max-content;
    max-width: calc(100% - 24px);
    padding: 6px 6px 6px 18px;
    background: var(--surface-strong);
    color: var(--text);
    border: .5px solid var(--border);
    border-radius: var(--radius-pill);
    box-shadow: var(--shadow-deal);
    opacity: 0;
    transform: translate(-50%, calc(100% + 64px));
    visibility: hidden;
    pointer-events: none;
    transition: opacity var(--deal-slide-duration) ease, transform var(--deal-slide-duration) var(--deal-slide-easing), visibility 0s var(--deal-slide-duration);
}
.deal-pill.is-visible { opacity: 1; transform: translate(-50%, 0); visibility: visible; pointer-events: auto; transition-delay: 0s; }
@starting-style {
    .site-header--deal .deal-strip.is-visible { height: 0; padding-block: 0; opacity: 0; transform: translateY(-100%); }
    .deal-pill.is-visible { opacity: 0; transform: translate(-50%, calc(100% + 64px)); }
}
.deal-pill .deal-cta { min-width: 0; min-height: 48px; padding: 12px 26px; border-radius: var(--radius-pill); background: var(--deal-cta-background, var(--deal-rainbow)); color: var(--deal-cta-text, #ffffff); font-size: 1rem; font-weight: 800; line-height: 1.2; text-align: center; overflow-wrap: anywhere; box-shadow: inset 0 2px 3px rgba(255, 255, 255, .35), 0 4px 14px rgba(18, 24, 40, .12); }
.deal-pill .deal-cta:hover, .deal-pill .deal-cta:focus-visible { background: var(--deal-cta-background, var(--deal-rainbow)); color: var(--deal-cta-text, #ffffff); box-shadow: inset 0 2px 3px rgba(255, 255, 255, .35), 0 6px 20px rgba(18, 24, 40, .20); }
.deal-price-pair { display: inline-flex; align-items: baseline; justify-content: center; gap: 12px; white-space: nowrap; }
.deal-regular-price { font-size: clamp(1.5rem, 3.2vw, 2rem); color: var(--muted); font-weight: 500; }
.deal-preview-tools {
    position: fixed; left: 12px; bottom: 100px; z-index: 60;
    max-width: min(26rem, calc(100% - 24px)); padding: 12px;
    border: 1px solid var(--accent); border-radius: var(--radius-card); background: var(--surface-strong); box-shadow: var(--shadow-card);
    font: 12px/1.5 var(--font-body);
}
.deal-preview-tools strong { display: block; overflow-wrap: anywhere; }
.deal-preview-tools div { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 6px; }
@media (max-width: 600px) {
    .deal-ticker { font-size: .75rem; }
    .deal-ticker-set, .deal-ticker-item { gap: 16px; }
    .deal-pill { gap: 14px; padding: 5px 5px 5px 14px; }
    .deal-pill .deal-cta { min-height: 46px; padding: 12px 20px; font-size: .9375rem; }
    .deal-timer { gap: 6px; font-size: .875rem; }
    .deal-timer--ticker { gap: 5px; font-size: .75rem; }
}
@media (prefers-reduced-motion: reduce) {
    .deal-ticker-track { animation: none; width: 100%; }
    .deal-ticker-set { width: 100%; min-width: 0; justify-content: center; padding-inline: 16px; }
    .deal-ticker-item { max-width: 100%; min-width: 0; }
    .deal-ticker-message { overflow: hidden; text-overflow: ellipsis; }
    .deal-ticker-set[aria-hidden="true"], .deal-ticker-item[aria-hidden="true"] { display: none; }
    .site-header--deal .deal-strip, .deal-pill { transition: none; }
}
