/* ═════════════════════════════════════════════════════════════════════════════
   Seasonal themes
   ─────────────────────────────────────────────────────────────────────────────
   Loaded ONLY when a seasonal theme is selected (Visual Editor → Seasonal Theme).
   With "Off" this file is not requested at all, so the default look is untouched.

   How it fits together
   • layouts/master.njk maps the editor choice to a slug and puts it on <html>:
       <html data-season="autumn" data-season-tint>
     (data-season-tint is present when "Tint backgrounds & surfaces" is on).
   • Everything here is scoped to html[data-season="…"], so themes cannot leak
     into each other or into the default look. Switching themes swaps one
     attribute; nothing accumulates.
   • A theme is a set of DESIGN TOKENS. The base design system already reads:
       --cl-accent / --cl-accent-rgb      accent fills, borders, links
       --cl-accent-ink                    text on accent fills   (default #04121a)
       --cl-hero-glow                     hero radial glow       (default #00c3ff)
       --cl-grad-from / --cl-grad-to      headline gradients     (default #02afff → #0066ff)
       --cl-bar-from / --cl-bar-to        footer link bar        (default #075ea5 → #00d9ff)
       --cl-brand-fixed                   legal pages accent     (default #11c8ff)
       --cl-brand-fixed-rgb, --cl-season-placeholder  (defaults 17,200,255 / theme colour)
       --cl-mix-partner                   colour mixed into accent gradients (default #7c5cff)
       --cl-light-*                       light-mode hero/offer accent mixes (default blues)
       --cl-background-*, --cl-surface*, --cl-elevated, --cl-snow, --cl-border-rgb
     Each of those falls back to the original value when a theme doesn't set it.
   • --ss-* tokens are seasonal-only (decorations, secondary accent, details).

   Adding a theme later (e.g. Valentine's Day)
     1. schema.json → components["seasonal-theme"].properties.theme.options
     2. layouts/master.njk → seasonalRegistry  (label → slug)
     3. here → copy one palette block below and set its tokens
     4. components/seasonal-theme.njk → SEASONS registry (decoration recipe)
   ═════════════════════════════════════════════════════════════════════════════ */


/* ── 1. Palettes ─────────────────────────────────────────────────────────────
   Accent tokens apply in both colour schemes. Light mode gets a deeper accent so
   it stays readable on light surfaces (≥ 4.5:1) with white ink. */

/* Autumn — amber, burnt sienna, warm umber */
html[data-season="autumn"] {
  --cl-brand-fixed-rgb: var(--cl-accent-rgb);
  --cl-season-placeholder: var(--cl-accent);
  --cl-mix-partner: var(--ss-accent-2);
  --cl-accent: #e8913a;
  --cl-accent-rgb: 232, 145, 58;
  --cl-accent-ink: #1c1006;
  --cl-hero-glow: #7f3415;
  --cl-grad-from: #f6b26b;
  --cl-grad-to: #c2531d;
  --cl-bar-from: #9a3412;
  --cl-bar-to: #f0a24a;
  --cl-brand-fixed: var(--cl-accent);
  --ss-accent-2: #c2531d;
  --ss-accent-2-rgb: 194, 83, 29;
  --ss-glow-rgb: 232, 145, 58;
}
html[data-season="autumn"][data-bs-theme="light"] {
  --cl-light-glow-mix: var(--cl-accent);
  --cl-light-mix: var(--cl-accent);
  --cl-light-deep: #7c2d12;
  --cl-light-text-mix: #7c2d12;
  --cl-accent: #b45309;
  --cl-accent-rgb: 180, 83, 9;
  --cl-accent-ink: #ffffff;
  --cl-hero-glow: #f8c99a;
  --cl-grad-from: #c2410c;
  --cl-grad-to: #92400e;
}
html[data-season="autumn"][data-season-tint][data-bs-theme="dark"] {
  --cl-background-primary: #0e0b09;
  --cl-background-primary-rgb: 14, 11, 9;
  --cl-background-secondary: #1e1813;
  --cl-background-secondary-rgb: 30, 24, 19;
  --cl-surface: 22, 17, 13;
  --cl-surface-2: 31, 25, 19;
  --cl-elevated: 18, 14, 11;
  --cl-border-rgb: 255, 232, 205;
  --cl-border: rgba(255, 232, 205, 0.07);
  --cl-snow: 255, 246, 236;
  --cl-ink-rgb: 255, 246, 236;
  background-color: #0e0b09;
}

/* Halloween — pumpkin orange on pitch black, witch purple, a drop of potion green */
html[data-season="halloween"] {
  --cl-brand-fixed-rgb: var(--cl-accent-rgb);
  --cl-season-placeholder: var(--cl-accent);
  --cl-mix-partner: var(--ss-accent-2);
  --cl-accent: #ff7a1a;
  --cl-accent-rgb: 255, 122, 26;
  --cl-accent-ink: #1a0800;
  --cl-hero-glow: #6b2a0c;
  --cl-grad-from: #ffc46b;
  --cl-grad-to: #ff6a00;
  --cl-bar-from: #7b2fbe;
  --cl-bar-to: #ff7a1a;
  --cl-brand-fixed: var(--cl-accent);
  --ss-accent-2: #9d4edd;
  --ss-accent-2-rgb: 157, 78, 221;
  --ss-glow-rgb: 255, 106, 0;
  --ss-potion: #8fd14f;
  --ss-potion-rgb: 143, 209, 79;
}
html[data-season="halloween"][data-bs-theme="light"] {
  --cl-light-glow-mix: var(--cl-accent);
  --cl-light-mix: var(--cl-accent);
  --cl-light-deep: #4c1d95;
  --cl-light-text-mix: #4c1d95;
  --cl-accent: #c2410c;
  --cl-accent-rgb: 194, 65, 12;
  --cl-accent-ink: #ffffff;
  --cl-hero-glow: #fed7aa;
  --cl-grad-from: #6d28d9;
  --cl-grad-to: #c2410c;
}
html[data-season="halloween"][data-season-tint][data-bs-theme="dark"] {
  --cl-background-primary: #08060a;
  --cl-background-primary-rgb: 8, 6, 10;
  --cl-background-secondary: #130e17;
  --cl-background-secondary-rgb: 19, 14, 23;
  --cl-surface: 15, 11, 18;
  --cl-surface-2: 24, 17, 28;
  --cl-elevated: 14, 10, 17;
  --cl-border-rgb: 255, 190, 140;
  --cl-border: rgba(255, 190, 140, 0.07);
  --cl-snow: 255, 244, 233;
  --cl-ink-rgb: 255, 244, 233;
  background-color: #08060a;
}

/* Black Friday — true black, signal yellow, a touch of urgent red */
html[data-season="black-friday"] {
  --cl-brand-fixed-rgb: var(--cl-accent-rgb);
  --cl-season-placeholder: var(--cl-accent);
  --cl-mix-partner: var(--ss-accent-2);
  --cl-accent: #ffd400;
  --cl-accent-rgb: 255, 212, 0;
  --cl-accent-ink: #0a0a0a;
  --cl-hero-glow: #3d3200;
  --cl-grad-from: #fff0a3;
  --cl-grad-to: #ffb800;
  --cl-bar-from: #ff3b30;
  --cl-bar-to: #ffd400;
  --cl-brand-fixed: var(--cl-accent);
  --ss-accent-2: #ff3b30;
  --ss-accent-2-rgb: 255, 59, 48;
  --ss-glow-rgb: 255, 212, 0;
}
/* Black Friday on the Chrome design (2026-11-18): the page goes a step blacker and
   neutral (no blue cast). Dark: the 10% accent is price-tag yellow. Light: the accent
   is black (black buttons on light grey). Only the tokens of layouts/master.njk are
   swapped, so every component follows without its own CSS. */
html[data-season="black-friday"]:not([data-bs-theme="light"]) {
  --base: #060606;
  --surface: #111111;
  --raised: #191919;
  --text: #f4f4f4;
  --muted: #a6a6a6;
  --border: #242424;
  --border-strong: #3a3a3a;
  --accent: #ffd23f;
  --accent-ink: #0b0b0b;
  --accent-rgb: 255, 210, 63;
  --base-rgb: 6, 6, 6;
  --surface-rgb: 17, 17, 17;
  --text-rgb: 244, 244, 244;
  --edge-accent: inset 0 1px 0 rgba(255, 255, 255, 0.55), inset 0 -1px 0 rgba(60, 44, 0, 0.25);
}
html[data-season="black-friday"][data-bs-theme="light"] {
  --base: #efefef;
  --surface: #ffffff;
  --raised: #e6e6e6;
  --text: #111111;
  --muted: #565656;
  --border: #d6d6d6;
  --border-strong: #ababab;
  --accent: #111111;
  --accent-ink: #ffffff;
  --accent-rgb: 17, 17, 17;
  --base-rgb: 239, 239, 239;
  --surface-rgb: 255, 255, 255;
  --text-rgb: 17, 17, 17;
  --edge-accent: inset 0 1px 0 rgba(255, 255, 255, 0.22), inset 0 -1px 0 rgba(0, 0, 0, 0.3);
}
html[data-season="black-friday"] {
  --bf-tag: #0b0b0b;
  --bf-tag-ink: #ffffff;
  --bf-dot: #ffd23f;
}
/* Calmer glows (2026-11-21): bright yellow made the soft accent glows loud.
   Globe rim + halo use a dim gold (dark) / grey (light) instead of the accent; the footer
   spotlight goes neutral; highlighted cards (SALE, MOST POPULAR…) keep their hairline
   but lose the blurred glow underneath. */
html[data-season="black-friday"]:not([data-bs-theme="light"]) { --globe-accent: #8f7630; }
html[data-season="black-friday"][data-bs-theme="light"] { --globe-accent: #6b6b6b; }
html[data-season="black-friday"] body .footer-spotlight ellipse { fill: #8c8c8c; } /* body: beats the shared seasonal fill further down */
html[data-season="black-friday"] .product-card.pc-hl {
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent) 22%, transparent);
}
/* The hero's rotating word drops its ice-blue for the season: yellow on dark, plain
   chrome-black on light. */
html[data-season="black-friday"]:not([data-bs-theme="light"]) .hero-content h1 .hero-rotator-word > span {
  background: linear-gradient(100deg, #fff0b0 0%, #ffd23f 50%, #f5b700 100%);
  -webkit-background-clip: text; background-clip: text;
}
html[data-season="black-friday"][data-bs-theme="light"] .hero-content h1 .hero-rotator-word > span {
  background: linear-gradient(100deg, #000000 0%, #3a3a3a 100%);
  -webkit-background-clip: text; background-clip: text;
}
html[data-season="black-friday"][data-bs-theme="light"] {
  --cl-light-glow-mix: var(--cl-accent);
  --cl-light-mix: var(--cl-accent);
  --cl-light-deep: #1f1f1f;
  --cl-light-text-mix: #1f1f1f;
  --cl-accent: #a16207;
  --cl-accent-rgb: 161, 98, 7;
  --cl-accent-ink: #ffffff;
  --cl-hero-glow: #fde68a;
  --cl-grad-from: #111111;
  --cl-grad-to: #a16207;
}
html[data-season="black-friday"][data-season-tint][data-bs-theme="dark"] {
  --cl-background-primary: #050505;
  --cl-background-primary-rgb: 5, 5, 5;
  --cl-background-secondary: #141414;
  --cl-background-secondary-rgb: 20, 20, 20;
  --cl-surface: 13, 13, 13;
  --cl-surface-2: 21, 21, 21;
  --cl-elevated: 10, 10, 10;
  --cl-border-rgb: 255, 255, 255;
  --cl-border: rgba(255, 255, 255, 0.08);
  --cl-snow: 255, 255, 255;
  --cl-ink-rgb: 255, 255, 255;
  background-color: #050505;
}

/* Christmas on the Chrome design (2026-11-29): "spruce night".
   Dark: the graphite page takes a faint evergreen cast, the chrome stays frost-silver and the
   10% accent is bauble red with dark ink (the same rule as the default ice-blue: a bright accent
   with dark ink is the only way to keep both the price text and the button text AA on a dark page).
   Light: cool snow-white page, cranberry accent with white ink.
   Measured: dark accent #f5525a = 5.4:1 on surface, ink 5.9:1; light #b3202a = 6.7:1 on white,
   white ink 6.7:1; muted text 7.8:1 (dark) / 6.5:1 (light).
   Only master.njk tokens are swapped, so every component follows without its own CSS. */
html[data-season="christmas"]:not([data-bs-theme="light"]) {
  --accent: #f5525a;
  --accent-ink: #1c0306;
  --accent-rgb: 245, 82, 90;
  --edge-accent: inset 0 1px 0 rgba(255, 255, 255, 0.45), inset 0 -1px 0 rgba(60, 0, 6, 0.28);
  --globe-accent: #8fa9b8;
  --xm-snow: 239, 245, 241;
  --xm-snow-a: 0.85;
}
html[data-season="christmas"][data-season-tint]:not([data-bs-theme="light"]) {
  --base: #070f0c;
  --surface: #0e1713;
  --raised: #15201b;
  --text: #eff5f1;
  --muted: #9caea5;
  --border: #1d2a24;
  --border-strong: #34453d;
  --base-rgb: 7, 15, 12;
  --surface-rgb: 14, 23, 19;
  --text-rgb: 239, 245, 241;
  --chrome: linear-gradient(180deg, #ffffff 0%, #dbe3df 46%, #9aa6a1 100%);
  --chrome-line: linear-gradient(90deg, transparent, #6c7a74 18%, #eff5f1 50%, #6c7a74 82%, transparent);
}
html[data-season="christmas"][data-bs-theme="light"] {
  --base: #f1f4f2;
  --surface: #ffffff;
  --raised: #e5ebe7;
  --text: #0e1813;
  --muted: #4d5b54;
  --border: #d3dcd7;
  --border-strong: #aab6b0;
  --accent: #b3202a;
  --accent-ink: #ffffff;
  --accent-rgb: 179, 32, 42;
  --base-rgb: 241, 244, 242;
  --surface-rgb: 255, 255, 255;
  --text-rgb: 14, 24, 19;
  --edge-accent: inset 0 1px 0 rgba(255, 255, 255, 0.26), inset 0 -1px 0 rgba(40, 0, 4, 0.3);
  --globe-accent: #6f7d77;
  --xm-snow: 104, 128, 150;
  --xm-snow-a: 0.5;
}

/* Christmas Eve & Day — candlelight, champagne gold, cream, deep evergreen */
html[data-season="christmas-eve-and-day"] {
  --cl-brand-fixed-rgb: var(--cl-accent-rgb);
  --cl-season-placeholder: var(--cl-accent);
  --cl-mix-partner: var(--ss-accent-2);
  --cl-accent: #e9c77b;
  --cl-accent-rgb: 233, 199, 123;
  --cl-accent-ink: #1e1408;
  --cl-hero-glow: #8a5a1c;
  --cl-grad-from: #fbe9bf;
  --cl-grad-to: #d4a04c;
  --cl-bar-from: #1f4a36;
  --cl-bar-to: #e9c77b;
  --cl-brand-fixed: var(--cl-accent);
  --ss-accent-2: #1f4a36;
  --ss-accent-2-rgb: 31, 74, 54;
  --ss-glow-rgb: 255, 196, 112;
}
html[data-season="christmas-eve-and-day"][data-bs-theme="light"] {
  --cl-light-glow-mix: var(--cl-accent);
  --cl-light-mix: var(--cl-accent);
  --cl-light-deep: #1f4a36;
  --cl-light-text-mix: #1f4a36;
  --cl-accent: #8a6418;
  --cl-accent-rgb: 138, 100, 24;
  --cl-accent-ink: #ffffff;
  --cl-hero-glow: #f6e3b8;
  --cl-grad-from: #1f4a36;
  --cl-grad-to: #8a6418;
}
html[data-season="christmas-eve-and-day"][data-season-tint][data-bs-theme="dark"] {
  --cl-background-primary: #0f0b08;
  --cl-background-primary-rgb: 15, 11, 8;
  --cl-background-secondary: #1f1912;
  --cl-background-secondary-rgb: 31, 25, 18;
  --cl-surface: 24, 19, 14;
  --cl-surface-2: 33, 26, 19;
  --cl-elevated: 20, 16, 12;
  --cl-border-rgb: 255, 240, 214;
  --cl-border: rgba(255, 240, 214, 0.08);
  --cl-snow: 251, 243, 228;
  --cl-ink-rgb: 251, 243, 228;
  background-color: #0f0b08;
}

/* New Year's Eve — midnight navy, champagne gold, silver */
html[data-season="new-years-eve"] {
  --cl-brand-fixed-rgb: var(--cl-accent-rgb);
  --cl-season-placeholder: var(--cl-accent);
  --cl-mix-partner: var(--ss-accent-2);
  --cl-accent: #f2cc6b;
  --cl-accent-rgb: 242, 204, 107;
  --cl-accent-ink: #14100a;
  --cl-hero-glow: #23336b;
  --cl-grad-from: #fdf1c7;
  --cl-grad-to: #c9d1e0;
  --cl-bar-from: #c9d1e0;
  --cl-bar-to: #f2cc6b;
  --cl-brand-fixed: var(--cl-accent);
  --ss-accent-2: #c9d1e0;
  --ss-accent-2-rgb: 201, 209, 224;
  --ss-glow-rgb: 120, 140, 255;
}
html[data-season="new-years-eve"][data-bs-theme="light"] {
  --cl-light-glow-mix: var(--cl-accent);
  --cl-light-mix: var(--cl-accent);
  --cl-light-deep: #1e2a4a;
  --cl-light-text-mix: #1e2a4a;
  --cl-accent: #8a6a12;
  --cl-accent-rgb: 138, 106, 18;
  --cl-accent-ink: #ffffff;
  --cl-hero-glow: #d9def5;
  --cl-grad-from: #1e293b;
  --cl-grad-to: #8a6a12;
}
html[data-season="new-years-eve"][data-season-tint][data-bs-theme="dark"] {
  --cl-background-primary: #060914;
  --cl-background-primary-rgb: 6, 9, 20;
  --cl-background-secondary: #121829;
  --cl-background-secondary-rgb: 18, 24, 41;
  --cl-surface: 12, 17, 32;
  --cl-surface-2: 18, 25, 44;
  --cl-elevated: 10, 14, 27;
  --cl-border-rgb: 200, 214, 255;
  --cl-border: rgba(200, 214, 255, 0.08);
  --cl-snow: 245, 247, 255;
  --cl-ink-rgb: 245, 247, 255;
  background-color: #060914;
}


/* ── 2. Shared seasonal details (any active theme) ───────────────────────────
   Narrow selectors only: things that carried hardcoded brand colours, plus one
   or two small finishing touches that read the active theme's tokens. */

/* Decorative SVG spotlights in the footer and product grid had a hardcoded fill. */
html[data-season] .footer-spotlight ellipse,
html[data-season] .products-spotlight ellipse {
  fill: var(--cl-accent);
}

/* A whisper of the season's glow at the top of the page (behind content). */
html[data-season][data-season-tint][data-bs-theme="dark"] body {
  background-image: radial-gradient(1200px 520px at 50% -180px, rgba(var(--ss-glow-rgb), 0.10), transparent 70%);
  background-repeat: no-repeat;
}

/* Selection colour follows the theme. */
html[data-season] ::selection {
  background: rgba(var(--cl-accent-rgb), 0.35);
  color: inherit;
}


/* ── 3. Theme signatures ─────────────────────────────────────────────────────
   One or two distinctive, restrained details per theme. Decorations that move
   (leaves, snow, stars…) live in components/seasonal-theme.njk. */

/* The floating navbar's hairline border takes the season's colour (border-color
   only, so its rounded corners, shadow and scroll states stay exactly as they are). */
html[data-season="autumn"] .main-header .header-container        { border-color: rgba(var(--cl-accent-rgb), 0.24); }
html[data-season="halloween"] .main-header .header-container     { border-color: rgba(var(--cl-accent-rgb), 0.26); }
html[data-season="black-friday"]:not([data-bs-theme="light"]) .main-header .header-container { border-color: rgba(var(--accent-rgb), 0.30); }
html[data-season="christmas-eve-and-day"] .main-header .header-container { border-color: rgba(var(--cl-accent-rgb), 0.28); }
html[data-season="new-years-eve"] .main-header .header-container { border-color: rgba(var(--ss-accent-2-rgb), 0.30); }

/* Halloween: product cards take a pumpkin edge and a faint purple shadow on hover;
   scrollbars and the hero eyebrow pick up the palette. */
html[data-season="halloween"] .product-card:hover {
  border-color: rgba(var(--cl-accent-rgb), 0.38) !important;
  box-shadow: 0 18px 40px -18px rgba(var(--ss-accent-2-rgb), 0.5);
}
html[data-season="halloween"] { scrollbar-color: rgba(var(--cl-accent-rgb), 0.35) transparent; }
html[data-season="halloween"]::-webkit-scrollbar-thumb { background: rgba(var(--cl-accent-rgb), 0.35); }

/* Black Friday: the price on a product page reads tighter and bolder. */
html[data-season="black-friday"] .pp-price {
  font-weight: 600;
}

/* Christmas Eve & Day: candlelit — buttons on accent carry a soft warm halo. */
html[data-season="christmas-eve-and-day"] .pf-btn-buy::before,
html[data-season="christmas-eve-and-day"] .checkout-btn {
  box-shadow: 0 8px 26px -10px rgba(var(--ss-glow-rgb), 0.55);
}

/* New Year's Eve: headline accents shimmer once, gently, as the page loads. */
html[data-season="new-years-eve"] .hero-content h1 span {
  background-size: 200% 100% !important;
  animation: ss-shimmer 3.5s ease-out 0.4s 1 both;
}
@keyframes ss-shimmer { from { background-position: 100% 0; } to { background-position: 0 0; } }
@media (prefers-reduced-motion: reduce) {
  html[data-season="new-years-eve"] .hero-content h1 span { animation: none; }
}


/* ── 4. Decoration layer (markup from components/seasonal-theme.njk) ─────────
   Fixed, pointer-events: none, above page content but below the navbar,
   drawers and popups. Particles are few and low-contrast by design. */

.ss-layer {
  position: fixed;
  inset: 0;
  z-index: 990;
  pointer-events: none;
  overflow: hidden;
  contain: strict;
}
.ss-layer > * { position: absolute; pointer-events: none; will-change: transform, opacity; }

/* Falling things (leaves, snow) */
.ss-fall {
  top: -40px;
  animation: ss-fall var(--d, 18s) linear var(--delay, 0s) infinite;
}
.ss-fall > i {
  display: block;
  width: 100%;
  height: 100%;
  animation: ss-sway var(--sw, 4s) ease-in-out infinite alternate;
}
@keyframes ss-fall {
  0%   { transform: translate3d(0, -5vh, 0); opacity: 0; }
  8%   { opacity: var(--o, 0.5); }
  92%  { opacity: var(--o, 0.5); }
  100% { transform: translate3d(var(--dx, 0px), 108vh, 0); opacity: 0; }
}
@keyframes ss-sway {
  from { transform: translateX(calc(var(--sx, 18px) * -1)) rotate(calc(var(--r, 40deg) * -1)); }
  to   { transform: translateX(var(--sx, 18px)) rotate(var(--r, 40deg)); }
}

/* Rising things (candlelight bokeh) */
.ss-rise {
  bottom: -60px;
  border-radius: 50%;
  animation: ss-rise var(--d, 22s) linear var(--delay, 0s) infinite;
}
@keyframes ss-rise {
  0%   { transform: translate3d(0, 0, 0) scale(0.8); opacity: 0; }
  12%  { opacity: var(--o, 0.4); }
  60%  { opacity: calc(var(--o, 0.4) * 0.7); }
  100% { transform: translate3d(var(--dx, 0px), -112vh, 0) scale(1.1); opacity: 0; }
}

/* Twinkling points (stars) */
.ss-star {
  width: var(--s, 2px);
  height: var(--s, 2px);
  border-radius: 50%;
  background: rgb(var(--ss-accent-2-rgb, 255, 255, 255));
  box-shadow: 0 0 6px rgba(var(--ss-accent-2-rgb, 255, 255, 255), 0.8);
  animation: ss-twinkle var(--d, 4s) ease-in-out var(--delay, 0s) infinite;
}
@keyframes ss-twinkle {
  0%, 100% { opacity: 0.1; transform: scale(0.7); }
  50%      { opacity: var(--o, 0.7); transform: scale(1); }
}

/* Firework burst (New Year's Eve) */
.ss-burst { width: 0; height: 0; }
.ss-burst > i {
  position: absolute;
  left: 0; top: 0;
  width: 3px; height: 3px;
  border-radius: 50%;
  background: var(--c, #f2cc6b);
  box-shadow: 0 0 6px var(--c, #f2cc6b);
  opacity: 0;
  animation: ss-spark 1.6s cubic-bezier(0.16, 1, 0.3, 1) var(--delay, 0s) forwards;
}
@keyframes ss-spark {
  0%   { transform: translate(0, 0) scale(1); opacity: 0; }
  10%  { opacity: 0.9; }
  100% { transform: translate(var(--tx), var(--ty)) scale(0.4); opacity: 0; }
}

/* Halloween harvest moon (top right, faint craters) and drifting bats */
.ss-moon {
  top: calc(var(--announcement-offset, 0px) + 150px);
  right: -34px;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 38%, rgba(180, 150, 120, 0.35) 0 9%, transparent 10%),
    radial-gradient(circle at 62% 64%, rgba(180, 150, 120, 0.3) 0 7%, transparent 8%),
    radial-gradient(circle at 66% 30%, rgba(180, 150, 120, 0.25) 0 5%, transparent 6%),
    radial-gradient(circle at 40% 40%, #fff6e4, #ffdcaa 70%, #f4b878);
  opacity: 0.2;
  box-shadow: 0 0 90px 24px rgba(255, 210, 150, 0.12);
}
.ss-bat {
  top: var(--y, 20vh);
  left: -60px;
  color: rgba(var(--ss-accent-2-rgb), 0.5);
  animation: ss-fly var(--d, 16s) linear var(--delay, 0s) infinite;
}
.ss-bat svg { width: var(--s, 26px); height: auto; display: block; animation: ss-flap 0.5s ease-in-out infinite alternate; transform-origin: center; }
@keyframes ss-fly {
  0%   { transform: translate3d(0, 0, 0); opacity: 0; }
  6%   { opacity: 1; }
  50%  { transform: translate3d(55vw, -6vh, 0); }
  94%  { opacity: 1; }
  100% { transform: translate3d(112vw, 4vh, 0); opacity: 0; }
}
@keyframes ss-flap { from { transform: scaleY(1); } to { transform: scaleY(0.55); } }

/* Black Friday: a slow glint sweeping across the top edge */
.ss-glint {
  top: 0;
  left: -30%;
  width: 30%;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(var(--cl-accent-rgb), 0.9), transparent);
  animation: ss-glint 7s ease-in-out infinite;
}
@keyframes ss-glint { 0% { transform: translateX(0); } 60%, 100% { transform: translateX(450%); } }

/* Christmas Eve & Day: candle warmth rising from the bottom edge */
.ss-warmth {
  left: 0; right: 0; bottom: 0;
  height: 32vh;
  background: radial-gradient(70% 100% at 50% 100%, rgba(var(--ss-glow-rgb), 0.10), transparent 70%);
  animation: ss-flicker 5s ease-in-out infinite alternate;
}
@keyframes ss-flicker { 0% { opacity: 0.75; } 40% { opacity: 1; } 70% { opacity: 0.85; } 100% { opacity: 0.95; } }

/* ── Corner & hanging pieces ────────────────────────────────────────────────
   Anchored just below the announcement bar, tucked into the page corners so
   they frame the content without covering it. Drawn in rgba(--cl-snow) so they
   adapt to light and dark mode. */
.ss-corner {
  top: var(--announcement-offset, 0px);
  opacity: var(--o, 1);
  line-height: 0;
}
.ss-corner.is-left  { left: 0; }
.ss-corner.is-right { right: 0; transform: scaleX(-1); }
.ss-corner.is-tr    { right: 0; }   /* drawn for the right corner already: no mirroring */
.ss-corner svg { display: block; }
.ss-sway { transform-origin: 100% 0; animation: ss-sway-corner 7s ease-in-out infinite alternate; }
@keyframes ss-sway-corner   { from { transform: rotate(-1.5deg); } to { transform: rotate(1.5deg); } }

/* Halloween cobwebs + spider on its thread */
.ss-web { color: rgba(var(--cl-snow), 0.16); }
.ss-spider {
  top: var(--announcement-offset, 0px);
  right: var(--x, 64px);
  width: 1px;
  height: 34px;
  border-left: 1px solid rgba(var(--cl-snow), 0.2);
  animation: ss-spider-drop 18s ease-in-out infinite;
}
.ss-spider svg {
  position: absolute;
  left: -8px;
  bottom: -18px;
  width: 16px;
  height: auto;
  color: rgba(var(--cl-snow), 0.5);
  transform-origin: 50% 0;
  animation: ss-spider-wiggle 2.6s ease-in-out infinite alternate;
}
@keyframes ss-spider-drop {
  0%, 14%   { height: 34px; }
  42%, 64%  { height: var(--drop, 22vh); }
  88%, 100% { height: 34px; }
}
@keyframes ss-spider-wiggle { from { transform: rotate(-7deg); } to { transform: rotate(7deg); } }

/* Halloween jack-o'-lanterns, bottom-left, with a candle flicker inside */
.ss-pumpkins {
  left: 14px;
  bottom: 8px;
  display: flex;
  align-items: flex-end;
  gap: 2px;
  opacity: 0.78;
}
.ss-pumpkin { display: block; width: 46px; line-height: 0; }
.ss-pumpkin.is-small { width: 32px; }
.ss-pumpkin svg { width: 100%; height: auto; display: block; }
.ss-face { animation: ss-candle 3.2s ease-in-out infinite; }
.ss-pumpkin.is-small .ss-face { animation-delay: -1.4s; }
@keyframes ss-candle { 0%, 100% { opacity: 0.95; } 30% { opacity: 0.6; } 45% { opacity: 1; } 70% { opacity: 0.75; } }

/* Halloween: an occasional small ghost rising out of the fog, then fading */
.ss-ghost {
  bottom: 30px;
  color: rgba(var(--cl-snow), 0.16);
  animation: ss-ghost 10s ease-in-out forwards;
}
.ss-ghost svg { width: var(--s, 26px); height: auto; display: block; animation: ss-ghost-sway 2.6s ease-in-out infinite alternate; }
@keyframes ss-ghost {
  0%   { transform: translate3d(0, 0, 0); opacity: 0; }
  20%  { opacity: 1; }
  75%  { opacity: 0.8; }
  100% { transform: translate3d(var(--dx, 0), -34vh, 0); opacity: 0; }
}
@keyframes ss-ghost-sway { from { transform: translateX(-4px) rotate(-4deg); } to { transform: translateX(4px) rotate(4deg); } }

/* Halloween graveyard: a low silhouette of tombstones, a bare tree and a fence */
.ss-grave {
  right: 0;
  bottom: 0;
  width: 300px;
  line-height: 0;
  color: rgba(var(--ss-accent-2-rgb), 0.12);
}
.ss-grave svg { width: 100%; height: auto; display: block; }
.ss-grave .ss-eyes { fill: var(--cl-accent); animation: ss-blink 7s steps(1) infinite; }
@keyframes ss-blink { 0%, 92%, 100% { opacity: 0.8; } 93%, 96% { opacity: 0; } }

/* Halloween: a witch on a broom crossing the moon now and then */
.ss-witch {
  top: calc(var(--announcement-offset, 0px) + 96px);
  left: -90px;
  color: rgba(var(--cl-snow), 0.2);
  animation: ss-witch 14s linear forwards;
}
.ss-witch svg { width: 78px; height: auto; display: block; }
@keyframes ss-witch {
  0%   { transform: translate3d(0, 30px, 0) rotate(-6deg); opacity: 0; }
  8%   { opacity: 1; }
  92%  { opacity: 1; }
  100% { transform: translate3d(calc(100vw + 180px), -40px, 0) rotate(-6deg); opacity: 0; }
}

/* Halloween: a second, shorter spider on the left */
.ss-spider.is-left { right: auto; left: var(--x, 180px); animation-duration: 23s; animation-delay: -9s; }

/* Halloween ground fog drifting along the bottom edge */
.ss-fog {
  left: -20vw;
  bottom: -60px;
  width: 80vw;
  height: 160px;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(var(--ss-accent-2-rgb), 0.12), transparent);
  filter: blur(12px);
  animation: ss-fog var(--d, 48s) ease-in-out infinite alternate;
}
.ss-fog.is-2 { left: auto; right: -20vw; width: 70vw; animation-direction: alternate-reverse; }
@keyframes ss-fog { from { transform: translateX(0); } to { transform: translateX(30vw); } }

/* Autumn wind gust: a few leaves crossing the page sideways */
.ss-gust {
  left: -40px;
  opacity: 0;
  animation: ss-gust 8s cubic-bezier(0.4, 0, 0.6, 1) var(--delay, 0s) forwards;
}
.ss-gust > i { display: block; width: 100%; height: 100%; animation: ss-sway 1.2s ease-in-out infinite alternate; --sx: 6px; --r: 140deg; }
@keyframes ss-gust {
  0%   { transform: translate3d(0, 0, 0); opacity: 0; }
  10%  { opacity: var(--o, 0.45); }
  50%  { transform: translate3d(55vw, -8vh, 0); }
  90%  { opacity: var(--o, 0.45); }
  100% { transform: translate3d(110vw, 6vh, 0); opacity: 0; }
}

/* Anything hanging on a string (tags, baubles, streamers) swings gently */
.ss-hang {
  top: var(--announcement-offset, 0px);
  line-height: 0;
  color: rgba(var(--cl-snow), 0.3);
  transform-origin: 50% 0;
  animation: ss-swing var(--d, 6s) ease-in-out var(--delay, 0s) infinite alternate;
}
.ss-hang.is-left  { left: var(--x, 40px); }
.ss-hang.is-right { right: var(--x, 40px); }
.ss-hang svg { display: block; }
@keyframes ss-swing { from { transform: rotate(-3.5deg); } to { transform: rotate(3.5deg); } }
html[data-season="black-friday"] .ss-hang { opacity: 0.75; }
html[data-season="new-years-eve"] .ss-hang { opacity: 0.6; }

/* Christmas Eve & Day: warm fairy-light garlands draped over the corners */
.ss-garland { color: rgba(var(--cl-snow), 0.22); }
.ss-garland.is-right { transform: scaleX(-1); }
.ss-bulb { animation: ss-bulb 3s ease-in-out var(--delay, 0s) infinite; }
@keyframes ss-bulb { 0%, 100% { opacity: 0.55; } 50% { opacity: 1; } }

/* Small screens: lighter still. */
@media (max-width: 640px) {
  .ss-layer .ss-optional { display: none; }
  .ss-web svg { width: 96px; height: 96px; }
  .ss-pumpkin { width: 34px; }
  .ss-grave { width: 190px; }
  .ss-moon { display: none; }
  .ss-spider { right: 28px; }
}

/* Reduced motion: no movement at all. Static, subtle accents only. */
@media (prefers-reduced-motion: reduce) {
  .ss-fall, .ss-rise, .ss-bat, .ss-burst, .ss-glint, .ss-gust, .ss-ghost, .ss-witch { display: none; }
  .ss-star, .ss-warmth, .ss-sway, .ss-spider, .ss-spider svg, .ss-face, .ss-fog, .ss-hang, .ss-bulb, .ss-grave .ss-eyes { animation: none; }
  .ss-star { opacity: calc(var(--o, 0.7) * 0.6); }
}

/* Light colour scheme: decorations step back further. */
html[data-bs-theme="light"] .ss-layer { opacity: 0.6; }
html[data-bs-theme="light"] .ss-moon { display: none; }


/* ── 5. Christmas on Chrome (2026-11-29) ─────────────────────────────────────
   One moment on the hero (snow behind the copy + a gift tag hanging from the key, both drawn
   by components/seasonal-theme.njk), then quiet details: a snowflake in the short separators,
   hairline highlights instead of glows, frost instead of ice-blue light. */

/* No coloured glow from the top of the page. */
html[data-season="christmas"][data-season-tint][data-bs-theme] body { background-image: none; }

/* Hero: the dot grid gives way to the snow canvas; the ice-blue light becomes a faint frost
   light behind the key and a little evergreen low on the left. */
html[data-season="christmas"] .hero-wrap:not(.has-bg)::after,
html[data-season="christmas"] .hero-dots-spot { display: none; }
html[data-season="christmas"] .hero-wrap:not(.has-bg)::before {
  background:
    radial-gradient(40% 55% at 76% 40%, rgba(214, 232, 245, 0.06), transparent 72%),
    radial-gradient(30% 34% at 8% 62%, rgba(31, 107, 74, 0.13), transparent 72%);
}
html[data-season="christmas"][data-bs-theme="light"] .hero-wrap:not(.has-bg)::before {
  background:
    radial-gradient(40% 55% at 76% 40%, rgba(120, 160, 190, 0.10), transparent 72%),
    radial-gradient(30% 34% at 8% 62%, rgba(31, 107, 74, 0.07), transparent 72%);
}
/* custom.css paints the light hero section solid (it hid the dark radial); here it must stay
   see-through or the snow behind it would only show at the edges. */
html[data-season="christmas"][data-bs-theme="light"] .hero-wrap .hero-section { background: transparent !important; }
.xm-snow {
  position: absolute; inset: 0; z-index: -1;
  width: 100%; height: 100%;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 72%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 0%, #000 72%, transparent 100%);
  opacity: 0; transition: opacity 1.2s ease;
}
.xm-snow.is-on { opacity: 1; }

/* The rotating word: a red glass bauble, lit from the top-left. */
html[data-season="christmas"]:not([data-bs-theme="light"]) .hero-content h1 .hero-rotator-word > span {
  background: linear-gradient(100deg, #ffb8bb 0%, #ff5f67 42%, #e3333d 100%);
  -webkit-background-clip: text; background-clip: text;
}
html[data-season="christmas"][data-bs-theme="light"] .hero-content h1 .hero-rotator-word > span {
  background: linear-gradient(100deg, #d4343d 0%, #a01822 60%, #7a1018 100%);
  -webkit-background-clip: text; background-clip: text;
}

/* Gift tag on the key. Anchored on the shaft (the key image is 1200×943, so % stays put at
   every size); it swings around that point (transform set by the script). */
html[data-season="christmas"] a.hero-visual { position: relative; transition: transform 0.18s cubic-bezier(0.22, 1, 0.36, 1); }
html[data-season="christmas"] a.hero-visual:active img,
html[data-season="christmas"] a.hero-visual.is-pressed img { transform: none; }
html[data-season="christmas"] a.hero-visual:active,
html[data-season="christmas"] a.hero-visual.is-pressed { transform: scale(0.97); }
.xm-tag {
  position: absolute;
  left: 58.2%; top: 41.4%;
  width: 15%;
  margin-left: -7.5%;
  transform-origin: 50% 0;
  pointer-events: none;
  filter: drop-shadow(0 10px 12px rgba(0, 0, 0, 0.28));
  opacity: 0;
  transition: opacity 0.6s ease 0.3s;
}
.xm-tag.is-on { opacity: 1; }
.xm-tag svg { display: block; width: 100%; height: auto; overflow: visible; }
[data-bs-theme="light"] .xm-tag { filter: drop-shadow(0 8px 10px rgba(14, 24, 19, 0.16)); }

/* Short separators: the line parts for a small snowflake. */
html[data-season="christmas"] .separator-line-short {
  position: relative;
  background: linear-gradient(90deg, transparent, var(--border) 18%, var(--border) calc(50% - 18px), transparent calc(50% - 18px), transparent calc(50% + 18px), var(--border) calc(50% + 18px), var(--border) 82%, transparent);
}
html[data-season="christmas"] .separator-line-short::after {
  content: '';
  position: absolute; left: 50%; top: 50%;
  width: 16px; height: 16px;
  margin: -8px 0 0 -8px;
  background: var(--muted);
  opacity: 0.7;
  -webkit-mask: var(--xm-flake) center / contain no-repeat;
  mask: var(--xm-flake) center / contain no-repeat;
}
html[data-season="christmas"] {
  --xm-flake: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.3' stroke-linecap='round'%3E%3Cg id='a'%3E%3Cpath d='M12 12V2.6M12 6.4 9.7 4.3M12 6.4l2.3-2.1M12 9.4l-1.5-1.3M12 9.4l1.5-1.3'/%3E%3C/g%3E%3Cuse href='%23a' transform='rotate(60 12 12)'/%3E%3Cuse href='%23a' transform='rotate(120 12 12)'/%3E%3Cuse href='%23a' transform='rotate(180 12 12)'/%3E%3Cuse href='%23a' transform='rotate(240 12 12)'/%3E%3Cuse href='%23a' transform='rotate(300 12 12)'/%3E%3C/svg%3E");
}

/* Highlighted cards (SALE, MOST POPULAR…) keep a hairline, no blurred glow; the footer light goes neutral. */
html[data-season="christmas"] .product-card.pc-hl { box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent) 24%, transparent); }
html[data-season="christmas"] body .footer-spotlight ellipse { fill: #8c9a93; }

@media (prefers-reduced-motion: reduce) {
  .xm-snow, .xm-tag { transition: none; }
}
