/* ── Новогоднее оформление сайта 100DAYS (зима 2026/27, сделано 30.11.2026) ─────────────────────────
   Всё здесь действует только под <html data-season="newyear">. Атрибут ставит короткий скрипт в <head>
   (build.py SEASON_HEAD, такой же вставлен в telc.html): по дате Варшавы 01.12–14.01, если в нём A=1,
   или по ссылке с ?season=newyear (для показа; ?season=off выключает). Без сезона сайт не меняется.
   Гирлянда, снег, шары, сугроб, снежные шапки — assets/newyear.js; бобры в новогодних шапках —
   assets/bobr-ny/ (скрипт в <head> подменяет пути картинок, пока страница строится).
   Образец — новогодний кабинет ученика (TEACHER src/season/newyear.css). */

/* фон первого экрана: морозная лаванда со светом сверху, как в кабинете */
html[data-season="newyear"] .hero,
html[data-season="newyear"] .page-hero{
  background:
    radial-gradient(1100px 520px at 100% -8%, rgba(150,86,234,.17), rgba(150,86,234,0) 62%),
    radial-gradient(800px 480px at -12% 4%, rgba(255,138,30,.09), rgba(255,138,30,0) 60%),
    linear-gradient(180deg,#F1EAFE 0%,#F7F2FD 420px);
}
html[data-season="newyear"] .hero>.wrap,
html[data-season="newyear"] .page-hero>.wrap{position:relative;z-index:1}
/* лампочки гирлянды свисают на ~40px: первый экран чуть ниже, чтобы они не ложились на плашку над заголовком */
html[data-season="newyear"] .hero-v2{padding-top:calc(clamp(20px,3.5vw,48px) + 16px)}
html[data-season="newyear"] .page-hero{padding-top:calc(clamp(24px,4vw,48px) + 14px)}

/* ── гирлянда под шапкой: провод провисает, лампочки фирменных цветов мерцают ── */
.ny-garland{--ny-wire:#4A3A6B;position:absolute;left:0;right:0;top:calc(100% - 3px);height:0;overflow:visible;pointer-events:none;z-index:2}
.ny-garland svg{display:block;overflow:visible}
@keyframes ny-twinkle{0%,100%{opacity:.95}45%{opacity:.25}60%{opacity:1}}
.ny-glow{animation:ny-twinkle var(--d,3.2s) ease-in-out infinite;animation-delay:var(--dl,0s)}
@keyframes ny-bulb{0%,100%{opacity:1}45%{opacity:.72}60%{opacity:1}}
.ny-bulb{animation:ny-bulb var(--d,3.2s) ease-in-out infinite;animation-delay:var(--dl,0s)}
/* ленд TELC: шапка не липкая, гирлянда висит по верхнему краю страницы, логотип чуть ниже */
.ny-garland-top{top:0}
html[data-season="newyear"] .top{padding-top:38px}
html[data-season="newyear"] body>.hero{padding-top:calc(84px + 24px)}
@media (min-width:640px){html[data-season="newyear"] .top{padding-top:48px}}
@media (min-width:900px){html[data-season="newyear"] body>.hero{padding-top:calc(118px + 34px)}}
/* бобр над формой ленда: в шапке он ниже ростом, поэтому чуть крупнее (растёт вверх от низа) */
html[data-season="newyear"] .h-masc img{transform:scale(1.12);transform-origin:50% 100%}

/* ── ёлочные шары на нитках в первом экране: покачиваются ── */
.ny-baubles{position:absolute;top:0;left:0;width:0;height:0;pointer-events:none;z-index:2}
@keyframes ny-sway{0%,100%{transform:rotate(-5deg)}50%{transform:rotate(5deg)}}
.ny-hang{position:absolute;top:0;display:flex;flex-direction:column;align-items:center;transform-origin:50% 0;animation:ny-sway var(--d,4.6s) ease-in-out infinite;animation-delay:var(--dl,0s)}
.ny-hang i{display:block;width:1.5px;border-radius:1px;background:linear-gradient(rgba(74,58,107,.15),rgba(176,132,48,.85))}
.ny-hang img{display:block;max-width:none;height:auto;margin-top:-3px;filter:drop-shadow(0 10px 12px rgba(60,30,120,.28))}

/* ── сугроб по нижнему краю первого экрана, сливается со следующим блоком ── */
.ny-drift{position:absolute;left:0;right:0;bottom:-1px;height:clamp(44px,6vw,92px);pointer-events:none;z-index:0}
.ny-drift svg{display:block;width:100%;height:100%;overflow:visible}

/* ── снежная шапка на карточках (форма записи, цены, форматы) ── */
.ny-cap{position:absolute;left:10px;right:10px;top:-17px;height:34px;pointer-events:none;z-index:3;
  background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 56' preserveAspectRatio='none'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%23fff'/%3E%3Cstop offset='.58' stop-color='%23fff'/%3E%3Cstop offset='1' stop-color='%23E6DEFA'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath fill='url(%23g)' d='M0 36C0 22 8 15 20 15C34 15 38 7 58 7C78 7 82 14 100 13C120 12 126 3 150 3C174 3 178 12 198 12C216 12 222 6 242 6C264 6 268 14 288 13C308 12 316 4 338 4C360 4 366 12 382 13C394 14 400 22 400 34C400 40 396 44 388 44L352 44C345 44 344 47 344 50C344 55 335 55 335 50C335 47 333 44 326 44L262 44C256 44 255 46 255 48C255 51 249 51 249 48C249 46 247 44 242 44L168 44C160 44 159 47 159 51C159 57 149 57 149 51C149 47 147 44 140 44L80 44C74 44 73 46 73 48C73 51 67 51 67 48C67 46 65 44 60 44L12 44C4 44 0 41 0 36Z'/%3E%3C/svg%3E") 0 0/100% 100% no-repeat;
  filter:drop-shadow(0 2px 3px rgba(61,35,134,.18))}
html[data-season="newyear"] .pc .tag{z-index:4}

/* ── снег на крыше: подвал сайта, фиолетовые блоки призыва, финал ленда TELC ── */
.ny-roof{position:absolute;left:0;right:0;top:-1px;height:27px;pointer-events:none;z-index:1;
  background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 240 22'%3E%3Cpath fill='%23fff' d='M0 0H240V9C232 9 229 11 229 14C229 18 221 18 221 14C221 11 216 9 206 10C196 11 194 12 186 11C178 10 176 9 168 9C160 9 159 12 159 16C159 21 150 21 150 16C150 12 146 10 136 10C124 10 120 12 108 12C98 12 95 10 88 10C82 10 81 13 81 15C81 18 75 18 75 15C75 12 71 10 62 11C52 12 47 13 38 12C30 11 27 9 20 9C14 9 13 12 13 14C13 17 7 17 7 14C7 11 5 9 0 9Z'/%3E%3C/svg%3E") 0 0/290px 27px repeat-x;
  filter:drop-shadow(0 3px 4px rgba(20,8,50,.35))}
html[data-season="newyear"] .ftr{position:relative;padding-top:calc(clamp(48px,6vw,72px) + 14px);
  background-image:
    radial-gradient(circle,rgba(255,255,255,.5) 0 1px,transparent 1.6px),
    radial-gradient(circle,rgba(255,255,255,.28) 0 1.4px,transparent 2px),
    radial-gradient(circle,rgba(196,166,250,.35) 0 1px,transparent 1.6px);
  background-size:170px 130px,230px 190px,120px 150px;
  background-position:20px 40px,90px 10px,60px 80px}
html[data-season="newyear"] .cta>.ny-roof{z-index:2}

/* ── кнопки действия: редкий блик, как свет гирлянды по стеклу (наведение по-прежнему своё) ── */
@keyframes ny-sheen{0%,72%{transform:translateX(-130%) skewX(-18deg)}100%{transform:translateX(260%) skewX(-18deg)}}
/* блик держится внутри кнопки (на ленде TELC у .btn своей рамки нет — блик уезжал за край страницы); :where — чтобы
   не перебить кнопки, которым вёрстка задаёт своё положение */
html[data-season="newyear"] :where(.btn:not(.btn-ghost):not(.btn-tg):not(.btn-tgb):not(.btn-w)){position:relative;overflow:hidden;isolation:isolate}
html[data-season="newyear"] .btn:not(.btn-ghost):not(.btn-tg):not(.btn-tgb):not(.btn-w)::before{
  content:'';position:absolute;top:0;bottom:0;left:0;width:45%;pointer-events:none;z-index:1;
  background:linear-gradient(90deg,rgba(255,255,255,0),rgba(255,255,255,.38),rgba(255,255,255,0));
  animation:ny-sheen 6.5s cubic-bezier(.4,0,.2,1) infinite}

/* ── снег: один холст поверх страницы, без нажатий ── */
.ny-snow{position:fixed;inset:0;width:100%;height:100%;display:block;z-index:45;pointer-events:none}

/* бобр над формой первого экрана: в шапке он выше, чуть крупнее, чтобы лицо не пряталось за форму */
html[data-season="newyear"] .hf-bobr{width:min(184px,36%);top:-24px}
@media (max-width:600px){html[data-season="newyear"] .hf-bobr{width:134px;top:-12px}}

@media (prefers-reduced-motion:reduce){
  .ny-glow,.ny-bulb,.ny-hang,html[data-season="newyear"] .btn::before{animation:none!important}
}
@media print{.ny-garland,.ny-snow,.ny-baubles,.ny-drift,.ny-cap,.ny-roof{display:none!important}}
