/* Пакет L «Зима 2026 · полировка» (2026-11-30). Надстройка над winter.css/winter.js: ничего внешнего, только свой арт /shop/winter/*.svg.
   Графит + фиолетовый + лёд, классическая тема. Анимации — только transform/opacity, всё отключается при prefers-reduced-motion
   и когда вкладка скрыта (счётчики стоят, пока вкладка не видна). Работает только при html.tf-winter (сезон активен). */

/* ---------- 0. исправление конфликта имён: welcome.css (экран приложения) тоже занимает .tfw-card / .tfw-head и давал окнам «Зимы»
   поля 30px, узкую шапку (шапка не тянулась на всю ширину) и подпрыгивание карточки при наведении ---------- */
.tfw-modal .tfw-card { padding: 0; align-items: stretch; text-align: left; transition: none; }
.tfw-modal .tfw-card:hover { transform: none; border-color: rgba(190, 210, 255, .16);
  box-shadow: 0 30px 90px rgba(0, 0, 0, .7), 0 0 0 1px rgba(124, 108, 255, .18), 0 0 80px -20px rgba(124, 108, 255, .5), inset 0 1px 0 rgba(220, 236, 255, .12); }

/* ---------- 1. шапка на логотипе: меньше и в уголке, чтобы не закрывала знак ---------- */
.tf-winter #homeBtn .tfw-hat { width: 25px; top: -9px; right: -6px; transform: rotate(14deg); animation: none; }
.tf-winter .logo.tfw-hat-host .tfw-hat { width: 24px; top: -12px; left: 24px; }

/* ---------- 2. главная (раздел «Друзья»): сезонная шапка ---------- */
.tfw2-hero { position: relative; display: grid; grid-template-columns: minmax(0, 1.15fr) auto minmax(0, 1fr); align-items: center; gap: 18px 26px; margin: 4px 0 18px; padding: 18px 22px; overflow: hidden;
  border-radius: 18px; border: 1px solid rgba(190, 210, 255, .16); color: #eceef5;
  background: linear-gradient(95deg, rgba(13, 12, 30, .95) 0%, rgba(17, 15, 38, .74) 40%, rgba(17, 15, 38, .08) 100%), url(/shop/winter/winter-hero.svg) right center / auto 100% no-repeat, #14122b;
  box-shadow: 0 16px 40px -22px rgba(0, 0, 0, .9), 0 0 0 1px rgba(124, 108, 255, .12), inset 0 1px 0 rgba(225, 238, 255, .14); }
.tfw2-hero::after { content: ''; position: absolute; left: 14px; right: 14px; top: 0; height: 2px; pointer-events: none; border-radius: 2px; background: linear-gradient(90deg, transparent, rgba(190, 215, 255, .75), rgba(167, 139, 250, .8), transparent); opacity: .8; }
.tfw2-hero.is-hidden { display: none; }
.tfw2-kick { display: inline-flex; align-items: center; gap: 7px; font-size: 11.5px; font-weight: 800; letter-spacing: 2.4px; text-transform: uppercase; color: #cfe2ff; }
.tfw2-kick svg { width: 15px; height: 15px; filter: drop-shadow(0 0 5px rgba(159, 200, 255, .8)); }
.tfw2-hero h2 { margin: 5px 0 11px; font-size: 22px; font-weight: 800; letter-spacing: -.2px; color: #fff; text-shadow: 0 2px 14px rgba(0, 0, 0, .55); }
.tfw2-cd { display: flex; gap: 8px; align-items: stretch; }
.tfw2-cd > span { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 56px; padding: 7px 8px 6px; border-radius: 12px; background: rgba(8, 8, 20, .58); border: 1px solid rgba(190, 210, 255, .16); box-shadow: inset 0 1px 0 rgba(235, 245, 255, .08); }
.tfw2-cd b { font-size: 24px; line-height: 1; font-weight: 800; font-variant-numeric: tabular-nums; background: linear-gradient(180deg, #fff, #b9cdfb); -webkit-background-clip: text; background-clip: text; color: transparent; }
.tfw2-cd i { margin-top: 4px; font-style: normal; font-size: 10.5px; letter-spacing: .6px; text-transform: uppercase; color: #9ba3be; }
.tfw2-adv { display: flex; align-items: center; gap: 13px; min-width: 190px; }
.tfw2-ring { position: relative; flex: 0 0 auto; width: 58px; height: 58px; }
.tfw2-ring svg { width: 58px; height: 58px; transform: rotate(-90deg); }
.tfw2-ring circle { fill: none; stroke-width: 5; }
.tfw2-ring .bg { stroke: rgba(190, 210, 255, .14); }
.tfw2-ring .fg { stroke: url(#tfw2g); stroke-linecap: round; transition: stroke-dashoffset .6s cubic-bezier(.2, .8, .2, 1); filter: drop-shadow(0 0 4px rgba(139, 108, 255, .7)); }
.tfw2-ring b { position: absolute; inset: 0; display: grid; place-items: center; font-size: 15px; font-weight: 800; color: #fff; }
.tfw2-ring b small { font-size: 10px; font-weight: 600; color: #9ba3be; margin-left: 1px; align-self: center; margin-top: 3px; }
.tfw2-adv-t { font-size: 13px; line-height: 1.35; color: #c3c9dc; }
.tfw2-adv-t b { display: block; color: #fff; font-size: 14px; margin-bottom: 2px; }
.tfw2-adv-t.is-today b { color: #ffe08a; }
.tfw2-acts { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.tfw2-btn { position: relative; display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 14px; border-radius: 11px; border: 1px solid rgba(190, 210, 255, .2); background: rgba(14, 14, 30, .62); color: #e9edf9; font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; transition: transform .15s ease, background .15s ease, border-color .15s ease, box-shadow .15s ease; }
.tfw2-btn:hover { transform: translateY(-1px); background: rgba(34, 30, 70, .8); border-color: rgba(190, 210, 255, .38); }
.tfw2-btn:focus-visible { outline: 2px solid #b9a4ff; outline-offset: 2px; }
.tfw2-btn svg { width: 16px; height: 16px; flex: 0 0 auto; }
.tfw2-btn.is-primary { border-color: rgba(190, 215, 255, .5); background: linear-gradient(180deg, #8f7bff, #6a58f0); color: #fff; box-shadow: inset 0 1px 0 rgba(235, 245, 255, .5), 0 8px 20px -8px rgba(124, 108, 255, .9); }
.tfw2-btn.is-primary:hover { background: linear-gradient(180deg, #9d8bff, #7664f5); }
.tfw2-dot { position: absolute; top: -4px; right: -4px; width: 10px; height: 10px; border-radius: 50%; background: #ff5c7a; box-shadow: 0 0 0 2px #14131f, 0 0 10px rgba(255, 80, 120, .8); }
.tfw2-x { position: absolute; top: 8px; right: 9px; width: 24px; height: 24px; border: 0; border-radius: 8px; background: transparent; color: #8f96b2; font-size: 17px; line-height: 1; cursor: pointer; opacity: .7; transition: opacity .15s, background .15s; }
.tfw2-x:hover { opacity: 1; background: rgba(255, 255, 255, .08); color: #fff; }
@media (max-width: 980px) {
  .tfw2-hero { grid-template-columns: 1fr auto; padding: 16px; gap: 14px; }
  .tfw2-acts { grid-column: 1 / -1; justify-content: flex-start; }
}
@media (max-width: 560px) {
  .tfw2-hero { grid-template-columns: 1fr; }
  .tfw2-cd > span { min-width: 0; flex: 1; }
  .tfw2-btn { flex: 1 1 auto; justify-content: center; }
}

/* ---------- 3. «Новости»: шапка канала с зимним небом ---------- */
.tf-winter:has(#newsBtn.active) #channelHeader {
  background: linear-gradient(90deg, rgba(20, 21, 30, .97) 0%, rgba(20, 21, 30, .72) 38%, rgba(20, 21, 30, 0) 100%), url(/shop/winter/winter-hero.svg) right 42% / 1100px auto no-repeat, var(--header, #1a1b23);
  box-shadow: inset 0 -1px 0 rgba(190, 210, 255, .12), inset 0 1px 0 rgba(225, 238, 255, .08); }
.tf-winter:has(#newsBtn.active) #channelTitle { text-shadow: 0 1px 10px rgba(0, 0, 0, .6); }

/* ---------- 4. экран входа: плашка сезона и выключатель снега ---------- */
.tfw2-chip { display: inline-flex; align-items: center; gap: 6px; margin: 0 0 16px 8px; padding: 6px 12px; border-radius: 999px; font-size: 12px; font-weight: 800; letter-spacing: 1.6px; text-transform: uppercase; color: #dbeaff; vertical-align: top;
  background: linear-gradient(90deg, rgba(94, 234, 212, .14), rgba(139, 108, 255, .28)); border: 1px solid rgba(180, 205, 255, .35); box-shadow: 0 0 18px -4px rgba(139, 108, 255, .6); }
.tfw2-chip svg { width: 13px; height: 13px; }
.tf-winter .login-card { box-shadow: 0 24px 70px -20px rgba(0, 0, 0, .75), 0 0 0 1px rgba(190, 210, 255, .1), 0 0 60px -26px rgba(139, 108, 255, .8), inset 0 1px 0 rgba(225, 238, 255, .18); }
.tfw2-snowbtn { position: fixed; right: 18px; bottom: 18px; z-index: 45; display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 14px 0 11px; border-radius: 19px; border: 1px solid rgba(190, 210, 255, .24); background: rgba(16, 15, 32, .78); color: #dbe6ff; font: inherit; font-size: 12.5px; font-weight: 700; cursor: pointer;
  transition: background .15s, border-color .15s, transform .15s; }
.tfw2-snowbtn:hover { background: rgba(38, 33, 78, .9); border-color: rgba(190, 210, 255, .45); transform: translateY(-1px); }
.tfw2-snowbtn:focus-visible { outline: 2px solid #b9a4ff; outline-offset: 2px; }
.tfw2-snowbtn svg { width: 17px; height: 17px; }
.tfw2-snowbtn .slash { opacity: 0; transition: opacity .15s; }
.tfw2-snowbtn[aria-pressed="false"] { color: #8f96b2; }
.tfw2-snowbtn[aria-pressed="false"] .slash { opacity: 1; }
.tfw2-snowbtn[hidden] { display: none; }
@media (max-width: 560px) { .tfw2-snowbtn span { display: none; } .tfw2-snowbtn { padding: 0 11px; } }

/* ---------- 5. заставка «Зима 2026»: обратный отсчёт, «Что нового», лёгкий снег ---------- */
.tfw2-sp-meta { display: flex; flex-wrap: wrap; gap: 8px; margin: -8px 0 20px; }
.tfw2-sp-pill { display: inline-flex; align-items: center; gap: 8px; padding: 7px 13px; border-radius: 999px; font-size: 13px; font-weight: 700; color: #e8efff; background: rgba(10, 10, 24, .55); border: 1px solid rgba(190, 210, 255, .24); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.tfw2-sp-pill svg { width: 15px; height: 15px; color: #ffe08a; }
.tfw2-sp-pill b { font-variant-numeric: tabular-nums; color: #fff; }
.tfw2-flakes { position: absolute; inset: 0; z-index: 1; overflow: hidden; pointer-events: none; }
.tfw2-flakes i { position: absolute; top: -12px; left: var(--x); width: var(--s); height: var(--s); border-radius: 50%; background: radial-gradient(circle, rgba(246, 250, 255, .95), rgba(214, 228, 255, .35) 60%, transparent 72%); opacity: 0; animation: tfw2Fall var(--d) linear var(--l) infinite; will-change: transform, opacity; }
@keyframes tfw2Fall { 0% { transform: translate3d(0, -4vh, 0); opacity: 0; } 8% { opacity: var(--o); } 100% { transform: translate3d(var(--w), 108vh, 0); opacity: var(--o); } }

/* ---------- 6. «Что нового» ---------- */
.tfw2-log .tfw-card { width: min(720px, 100%); }
.tfw2-log .tfw-head { min-height: 118px; }
.tfw2-log .tfw-head-art { background: url(/shop/winter/winter-hero.svg) right center / cover no-repeat; }
.tfw2-log-body { overflow-y: auto; padding: 8px 22px 22px; scrollbar-width: thin; scrollbar-color: rgba(139, 108, 255, .5) transparent; }
.tfw2-sec { margin: 18px 0 10px; display: flex; align-items: center; gap: 10px; font-size: 11.5px; font-weight: 800; letter-spacing: 2.2px; text-transform: uppercase; color: #9fc8ff; }
.tfw2-sec::after { content: ''; flex: 1; height: 1px; background: linear-gradient(90deg, rgba(159, 200, 255, .3), transparent); }
.tfw2-it { display: grid; grid-template-columns: 38px 1fr; gap: 13px; padding: 12px 12px; margin: 0 -12px; border-radius: 14px; transition: background .15s; }
.tfw2-it:hover { background: rgba(124, 108, 255, .08); }
.tfw2-ic { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; color: #d9e6ff; background: linear-gradient(145deg, rgba(139, 108, 255, .38), rgba(62, 90, 200, .2)); border: 1px solid rgba(190, 210, 255, .22); box-shadow: inset 0 1px 0 rgba(235, 245, 255, .22); }
.tfw2-ic svg { width: 20px; height: 20px; }
.tfw2-it h4 { margin: 1px 0 3px; font-size: 14.5px; font-weight: 700; color: #fff; display: flex; align-items: center; gap: 8px; }
.tfw2-it h4 em { font-style: normal; font-size: 10px; font-weight: 800; letter-spacing: .8px; text-transform: uppercase; padding: 2px 7px; border-radius: 99px; color: #1c1530; background: linear-gradient(90deg, #ffe08a, #ffc24a); }
.tfw2-it p { margin: 0; font-size: 13.5px; line-height: 1.5; color: #b5bcd2; }
.tfw2-it p a { color: #b9a4ff; text-decoration: underline; text-underline-offset: 2px; }
.tfw2-sign { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--tfw-line, rgba(200, 220, 255, .1)); font-size: 12px; color: #7f87a3; }
.tfw-set .tfw2-setrow { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0 2px; }
.tfw-set .tfw2-setrow span { font-size: 13px; color: #9aa3bd; }

/* ---------- 7. мелкая полировка зимних окон ---------- */
.tfw-door { transition: transform .18s cubic-bezier(.2, .9, .3, 1.2), box-shadow .18s ease, border-color .18s ease; }
.tfw-door.is-open:hover, .tfw-door.is-today:hover { transform: translateY(-2px); }
.tfw-modal.open .tfw-body { scrollbar-width: thin; scrollbar-color: rgba(139, 108, 255, .5) transparent; }
.tfw-empty { padding: 36px 12px; text-align: center; color: #9aa3bd; }

@media (prefers-reduced-motion: reduce) {
  .tfw2-flakes { display: none; }
  .tfw2-btn, .tfw2-snowbtn, .tfw-door { transition: none; }
  .tfw2-ring .fg { transition: none; }
}
