/* Bliss Field — New Year seasonal theme.
   Active only when <html data-season="newyear"> (set by season.js). Default page stays light (matches Alex's New Year header);
   the dark "winter night" palette is optional: <html data-night="1"> (?night=1). */
html[data-season="newyear"][data-night="1"] {
  --bg: #0e1211; --panel: #0e1211; --panel-2: #171e1c;
  --ink: #e6ecec; --muted: #8a9895; --line: #26302d; --line-dark: #e6ecec;
  --wine: #e6ecec; --wine-deep: #ffffff; --wine-soft: #171e1c; --good: #e6ecec; --danger: #e0644f;
  color-scheme: dark;
}
html[data-season="newyear"][data-night="1"], html[data-season="newyear"][data-night="1"] body, html[data-season="newyear"][data-night="1"] .app-shell, html[data-season="newyear"][data-night="1"] .main, html[data-season="newyear"][data-night="1"] .boot-screen, html[data-season="newyear"][data-night="1"] .loading { background: var(--bg) !important; color: var(--ink); }
html[data-season="newyear"][data-night="1"] .topbar,
html[data-season="newyear"][data-night="1"] .bottom-nav { background: rgba(14,18,17,.96) !important; border-color: var(--line) !important; }
html[data-season="newyear"][data-night="1"] .brand-home img { filter: invert(1) brightness(.92); }
html[data-season="newyear"][data-night="1"] .btn { background: var(--ink) !important; color: var(--bg) !important; border-color: var(--ink) !important; }
html[data-season="newyear"][data-night="1"] .btn.secondary { background: transparent !important; color: var(--ink) !important; border-color: var(--line) !important; }
html[data-season="newyear"][data-night="1"] .catalog-tools .btn { background: transparent !important; color: var(--ink) !important; border-bottom-color: var(--ink) !important; }
html[data-season="newyear"][data-night="1"] .cart-footer, html[data-season="newyear"][data-night="1"] .modal, html[data-season="newyear"][data-night="1"] .size-btn { background: var(--bg) !important; color: var(--ink); }
html[data-season="newyear"][data-night="1"] .size-btn.active { background: var(--ink) !important; color: var(--bg) !important; }
html[data-season="newyear"][data-night="1"] .toast { background: var(--ink) !important; color: var(--bg) !important; }
html[data-season="newyear"][data-night="1"] .input::placeholder { color: #55625f; }
/* winter night: the intro and the loaders are drawn black-on-white, so flip them to white riders on the night background */
html[data-season="newyear"][data-night="1"] .boot-visual { filter: invert(1); mix-blend-mode: lighten; }
html[data-season="newyear"][data-night="1"] .loading img,
html[data-season="newyear"][data-night="1"] .swipe-indicator img { filter: invert(1); }

/* catalog decorations */
html[data-season="newyear"] .main:has(.catalog-signature)::before {
  height: 52px; animation: ny-twinkle 2.4s steps(1) infinite;
  background: url(/assets/newyear/garland-winter-0.png?v=20261119-720) repeat-x 0 0 / 144px 52px;
}
@keyframes ny-twinkle { 0%, 100% { background-image: url(/assets/newyear/garland-winter-0.png?v=20261119-720); } 50% { background-image: url(/assets/newyear/garland-winter-1.png?v=20261119-720); } }
html[data-season="newyear"] .main:has(.catalog-signature) .product-card {
  border-image: url(/assets/newyear/card-frame-winter.png?v=20261119-720) 48 round !important;
}
/* falling pixel snow over the whole page (two slow layers, does not catch taps).
   Shown with html[data-snow="1"], which season.js sets for New Year (&snow=0 hides it). */
html[data-season="newyear"][data-snow="1"] body::after {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 40; image-rendering: pixelated;
  background:
    url(/assets/newyear/snow-near-light.png?v=20261119-730) 0 0 / 192px 192px,
    url(/assets/newyear/snow-far-light.png?v=20261119-730) 40px 70px / 128px 128px;
  animation: ny-snow 32s linear infinite; opacity: .6;
}
@keyframes ny-snow { from { background-position: 0 0, 40px 70px; } to { background-position: 60px 768px, 80px 582px; } }
@media (prefers-reduced-motion: reduce) { html[data-season="newyear"][data-snow="1"] body::after { animation: none; } }

html[data-season="newyear"][data-night="1"][data-snow="1"] body::after {
  background:
    url(/assets/newyear/snow-near.png?v=20261119-720) 0 0 / 192px 192px,
    url(/assets/newyear/snow-far.png?v=20261119-720) 40px 70px / 128px 128px;
}
/* the static New Year header (fallback before the canvas mounts) */
html[data-season="newyear"] img.catalog-signature-wordmark:not(.jungle-canvas) { content: url(/assets/wordmark-jungle-ny.png?v=20261119-750); }

/* 0.5.37 — winter night header = Alex's approved pixel wordmark (260×164 art drawn ×4 by jungle-header.js) */
html[data-season="newyear"][data-night="1"] .main:has(.catalog-signature) canvas.jungle-canvas.jungle-px { aspect-ratio: 260 / 164; image-rendering: pixelated; }
html[data-season="newyear"][data-night="1"] img.catalog-signature-wordmark:not(.jungle-canvas) { content: url(/assets/wordmark-pixel-night.png?v=20261119-1000); image-rendering: pixelated; }

/* 0.5.37 — intro film on app open (night jungle rider → «Поле блажи» end card), letterboxed on black */
html[data-season="newyear"][data-night="1"] .boot-screen.has-video { padding: 0; background: #000 !important; }
.boot-screen.has-video .boot-wordmark, .boot-screen.has-video .boot-line { display: none; }
.boot-video { position: fixed; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #000; }
