/* Seasonal themes (Polish holidays and customs), same palettes as Leave Hub. html[data-season] is set by js/seasons.js.
   Each occasion gives a few colours; the app's accent, soft tints, buttons, tabs and the sign-in panel are derived from them.
   --sa accent, --sb darker accent, --st text on the accent, --sat accent as text on light surfaces, --g1/--g2 background glow (r,g,b). */
html[data-season="newyear"] { --sa: #e8c681; --sb: #b98424; --st: #241a05; --sat: #8f6414; --g1: 232, 198, 129; --g2: 22, 197, 173; }
html[data-season="threekings"] { --sa: #b79cff; --sb: #6a48c8; --st: #ffffff; --sat: #5b3ab5; --g1: 154, 123, 255; --g2: 242, 193, 78; }
html[data-season="fatthursday"] { --sa: #ff9ec4; --sb: #c2417b; --st: #3a0a1e; --sat: #a8336b; --g1: 255, 158, 196; --g2: 242, 193, 78; }
html[data-season="valentines"] { --sa: #ff6b81; --sb: #c9304a; --st: #ffffff; --sat: #b32a42; --g1: 255, 107, 129; --g2: 255, 143, 179; }
html[data-season="womensday"] { --sa: #ff8fb3; --sb: #c13f82; --st: #3a0a22; --sat: #a8336f; --g1: 255, 143, 179; --g2: 88, 194, 125; }
html[data-season="easter"] { --sa: #4fb98a; --sb: #26805a; --st: #ffffff; --sat: #1f6f4e; --g1: 245, 160, 200; --g2: 120, 205, 160; }
html[data-season="mayday"], html[data-season="independence"], html[data-season="armyday"] { --sa: #ef4b55; --sb: #c9202f; --st: #ffffff; --sat: #b01c29; --g1: 229, 72, 77; --g2: 220, 225, 230; }
html[data-season="childrensday"] { --sa: #ffc145; --sb: #d96d0a; --st: #ffffff; --sat: #b35608; --g1: 111, 195, 255; --g2: 255, 193, 69; }
html[data-season="corpuschristi"] { --sa: #7fd18a; --sb: #2e8a4c; --st: #ffffff; --sat: #26773f; --g1: 127, 209, 138; --g2: 255, 143, 179; }
html[data-season="halloween"] { --sa: #ff8a2a; --sb: #cf5c06; --st: #ffffff; --sat: #b34f05; --g1: 141, 108, 255; --g2: 255, 138, 42; }
html[data-season="allsaints"] { --sa: #e8b96a; --sb: #8f6420; --st: #ffffff; --sat: #7d5618; --g1: 232, 185, 106; --g2: 120, 90, 160; }
html[data-season="nicholas"], html[data-season="christmas"] { --sa: #e0483f; --sb: #b82a2a; --st: #ffffff; --sat: #a82424; --g1: 224, 72, 63; --g2: 60, 170, 110; }

/* the app's accent follows the occasion (light theme here, dark below) */
html[data-season] { --accent: var(--sb); --accent-hover: color-mix(in srgb, var(--sb) 84%, #000); --accent-soft: color-mix(in srgb, var(--sa) 16%, var(--surface)); --accent-ink: var(--sat); --accent-fg: var(--st); }
html[data-season][data-theme="dark"] { --accent: var(--sa); --accent-hover: color-mix(in srgb, var(--sa) 86%, #fff); --accent-soft: color-mix(in srgb, var(--sa) 18%, var(--surface)); --accent-ink: var(--sa); --accent-fg: var(--st); }
@media (prefers-color-scheme: dark) {
  html[data-season]:not([data-theme="light"]) { --accent: var(--sa); --accent-hover: color-mix(in srgb, var(--sa) 86%, #fff); --accent-soft: color-mix(in srgb, var(--sa) 18%, var(--surface)); --accent-ink: var(--sa); --accent-fg: var(--st); }
}
/* light accents carry dark text, so the light-theme accent for yellow occasions stays readable */
html[data-season="newyear"][data-theme="dark"], html[data-season="fatthursday"][data-theme="dark"], html[data-season="womensday"][data-theme="dark"], html[data-season="childrensday"][data-theme="dark"], html[data-season="corpuschristi"][data-theme="dark"] { --accent-fg: var(--st); }

/* background glow */
html[data-season] body { background-attachment: fixed; background-image: radial-gradient(56rem 28rem at 88% -7rem, rgba(var(--g1), 0.11), transparent 70%), radial-gradient(48rem 26rem at 6% 108%, rgba(var(--g2), 0.09), transparent 70%); }
html[data-season][data-theme="dark"] body { background-image: radial-gradient(56rem 28rem at 88% -7rem, rgba(var(--g1), 0.16), transparent 70%), radial-gradient(48rem 26rem at 6% 108%, rgba(var(--g2), 0.11), transparent 70%); }
@media (prefers-color-scheme: dark) {
  html[data-season]:not([data-theme="light"]) body { background-image: radial-gradient(56rem 28rem at 88% -7rem, rgba(var(--g1), 0.16), transparent 70%), radial-gradient(48rem 26rem at 6% 108%, rgba(var(--g2), 0.11), transparent 70%); }
}

/* thin decoration along the top edge of the window */
html[data-season] body::before { content: ""; position: fixed; top: 0; left: 0; right: 0; height: 3px; background: linear-gradient(90deg, transparent, var(--sa), var(--sb), var(--sa), transparent); pointer-events: none; z-index: 120; }
html[data-season="mayday"] body::before, html[data-season="independence"] body::before, html[data-season="armyday"] body::before { height: 6px; background: linear-gradient(#ffffff 0 50%, #dc143c 50% 100%); }
html[data-season="easter"] body::before { height: 4px; background: linear-gradient(90deg, #a8e6cf, #ffd3e0, #d4c4fb, #fff2b3, #a8e6cf, #ffd3e0, #d4c4fb); }
html[data-season="allsaints"] body::before { display: none; }
/* string lights under the top bar (and above the sign-in form) */
html[data-season="christmas"], html[data-season="nicholas"] {
  --lights: radial-gradient(circle at 12px 9px, #ff5a4f 0 3px, transparent 4px) 0 0 / 96px 18px repeat-x, radial-gradient(circle at 36px 9px, #ffd24d 0 3px, transparent 4px) 0 0 / 96px 18px repeat-x,
    radial-gradient(circle at 60px 9px, #4de08a 0 3px, transparent 4px) 0 0 / 96px 18px repeat-x, radial-gradient(circle at 84px 9px, #4da6ff 0 3px, transparent 4px) 0 0 / 96px 18px repeat-x, linear-gradient(#6b7280, #6b7280) 0 9px / 100% 1px no-repeat;
}
.topbar { position: relative; }
html[data-season="christmas"] .topbar::after, html[data-season="nicholas"] .topbar::after, html[data-season="christmas"] .auth-wrap::before, html[data-season="nicholas"] .auth-wrap::before {
  content: ""; position: absolute; left: 0; right: 0; top: 100%; height: 18px; background: var(--lights); pointer-events: none; z-index: 5; filter: drop-shadow(0 0 4px rgba(255, 220, 150, 0.65)); animation: season-twinkle 2.4s ease-in-out infinite alternate;
}
html[data-season="christmas"] .auth-wrap::before, html[data-season="nicholas"] .auth-wrap::before { top: 0; }
@keyframes season-twinkle { from { opacity: 0.65; } to { opacity: 1; } }

/* particles layer */
.seasonal-canvas { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 3; }

/* greeting in the top bar and on the sign-in panel: plain text, the pictures are part of the backgrounds (no frames, no cards) */
.season-greeting { font-size: 0.8125rem; font-weight: 500; color: var(--accent-ink); white-space: nowrap; }
@media (max-width: 1500px) { .season-greeting { display: none; } }
.season-postcard { display: grid; gap: 0.375rem; margin-top: 1.25rem; }
.season-postcard small { font-size: 0.6875rem; letter-spacing: 0.16em; text-transform: uppercase; font-weight: 600; color: var(--sa); }
.season-postcard b { font-size: 1.5rem; font-weight: 600; letter-spacing: -0.02em; line-height: 1.2; }
@media (min-width: 62rem) {
  .auth-hero::after { content: ""; position: absolute; right: 2rem; bottom: 4.5rem; width: 25rem; max-width: 70%; height: min(46vh, 25rem); pointer-events: none; background-repeat: no-repeat; filter: drop-shadow(0 14px 24px rgba(0, 0, 0, 0.5)); }
  html[data-season="christmas"] .auth-hero::after, html[data-season="nicholas"] .auth-hero::after { background-image: url(/seasonal/christmas-tree.webp), url(/seasonal/christmas-branch.webp); background-position: right bottom, 0 100%; background-size: auto 100%, 11rem auto; }
  html[data-season="easter"] .auth-hero::after { background-image: url(/seasonal/easter-left.webp), url(/seasonal/easter-right.webp); background-position: right bottom, 2rem 100%; background-size: auto 78%, auto 42%; }
  html[data-season="halloween"] .auth-hero::after { height: min(26vh, 13rem); background-image: url(/seasonal/halloween-left.webp); background-position: right bottom; background-size: contain; }
}
/* illustrations at the bottom of the sidebar (from Leave Hub), only on screens tall enough */
@media (min-width: 861px) { .sidebar { position: relative; } } /* (≤860 px the sidebar is the fixed off-canvas drawer) */
html[data-season="halloween"] { --deco-img: url(/seasonal/halloween-left.webp); --deco-w: 10.7rem; --deco-h: 5.4rem; }
html[data-season="easter"] { --deco-img: url(/seasonal/easter-left.webp); --deco-w: 8.8rem; --deco-h: 8.8rem; }
html[data-season="christmas"], html[data-season="nicholas"] { --deco-img: url(/seasonal/christmas-tree.webp); --deco-w: 5.9rem; --deco-h: 9rem; }
html[data-season="halloween"] .sidebar::after, html[data-season="easter"] .sidebar::after, html[data-season="christmas"] .sidebar::after, html[data-season="nicholas"] .sidebar::after {
  content: ""; position: absolute; left: 0.75rem; bottom: 4.5rem; width: var(--deco-w); height: var(--deco-h); background: var(--deco-img) left bottom / contain no-repeat; filter: drop-shadow(0 8px 10px rgba(0, 0, 0, 0.25)); pointer-events: none;
}
html[data-season="christmas"] .sidebar::before { content: ""; position: absolute; left: 6.5rem; bottom: 4.5rem; width: 5rem; height: 1.8rem; background: url(/seasonal/christmas-branch.webp) left bottom / contain no-repeat; filter: drop-shadow(0 6px 8px rgba(0, 0, 0, 0.25)); pointer-events: none; }
html[data-season="easter"] .sidebar::before { content: ""; position: absolute; left: 8rem; bottom: 4.5rem; width: 3.6rem; height: 3.1rem; background: url(/seasonal/easter-right.webp) left bottom / contain no-repeat; filter: drop-shadow(0 6px 8px rgba(0, 0, 0, 0.25)); pointer-events: none; }
@media (max-height: 960px) { html[data-season] .sidebar::after, html[data-season] .sidebar::before { display: none !important; } }
@media (max-width: 860px) { .season-badge { display: none; } }
@media (prefers-reduced-motion: reduce) { html[data-season] .topbar::after, html[data-season] .auth-wrap::before { animation: none !important; } }
@media print { .seasonal-canvas, .season-badge, html[data-season] .sidebar::after, html[data-season] .sidebar::before, html[data-season] body::before { display: none !important; } }
