/* Praznični režim on all pages except the home page (generated by prototypes/praznicna-na-sajtu/build_common.py
   from holiday-v1.css): falling snow, snow drift on the menu, spinning snowflakes instead of petals. */

/* Falling snow over the page (created by holiday-v1.js) */
.hd-snow { position: fixed; inset: 0; pointer-events: none; z-index: 60; overflow: hidden; }
.hd-snow i { position: absolute; top: -10px; border-radius: 50%; background: #fff; box-shadow: 0 0 3px 1px rgba(160, 90, 200, .45); animation: hd-fall linear infinite; }
@keyframes hd-fall { to { transform: translate3d(var(--dx, 30px), 105vh, 0); } }

/* Snow caps (generated by prototypes/praznicna-na-sajtu/snow_caps.py)
   Drift lying on the menu and on the benefits block: rounded ends of fixed size + stretching lumpy middle. */
.nav, .benefits { position: relative; }
.nav::after, .benefits::after {
  content: ""; position: absolute; top: -27px; left: 16px; right: 16px; height: 36px; z-index: 3; pointer-events: none;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 46 36'%3E%3Cdefs%3E%3ClinearGradient id='g' gradientUnits='userSpaceOnUse' x1='0' y1='0' x2='0' y2='36'%3E%3Cstop offset='0' stop-color='%23ffffff'/%3E%3Cstop offset='.5' stop-color='%23ffffff'/%3E%3Cstop offset='.82' stop-color='%23eef0fb'/%3E%3Cstop offset='1' stop-color='%23d9dcf2'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath d='M46 11C33 11 22 12 14 16C6 20 2.5 25 5 28.5C7 31 11 31 16 31L46 31Z' fill='url%28%23g%29'/%3E%3Cellipse cx='30' cy='14' rx='9' ry='2.2' fill='%23fff' opacity='.9'/%3E%3C/svg%3E") left top / 46px 36px no-repeat,
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 46 36'%3E%3Cdefs%3E%3ClinearGradient id='g' gradientUnits='userSpaceOnUse' x1='0' y1='0' x2='0' y2='36'%3E%3Cstop offset='0' stop-color='%23ffffff'/%3E%3Cstop offset='.5' stop-color='%23ffffff'/%3E%3Cstop offset='.82' stop-color='%23eef0fb'/%3E%3Cstop offset='1' stop-color='%23d9dcf2'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cg transform='translate%2846 0%29 scale%28-1 1%29'%3E%3Cpath d='M46 11C33 11 22 12 14 16C6 20 2.5 25 5 28.5C7 31 11 31 16 31L46 31Z' fill='url%28%23g%29'/%3E%3Cellipse cx='30' cy='14' rx='9' ry='2.2' fill='%23fff' opacity='.9'/%3E%3C/g%3E%3C/svg%3E") right top / 46px 36px no-repeat,
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 600 36' preserveAspectRatio='none'%3E%3Cdefs%3E%3ClinearGradient id='g' gradientUnits='userSpaceOnUse' x1='0' y1='0' x2='0' y2='36'%3E%3Cstop offset='0' stop-color='%23ffffff'/%3E%3Cstop offset='.5' stop-color='%23ffffff'/%3E%3Cstop offset='.82' stop-color='%23eef0fb'/%3E%3Cstop offset='1' stop-color='%23d9dcf2'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath d='M0 11C22 11 30 6 56 6C80 6 88 9.5 112 9.5C138 9.5 146 3 176 3C204 3 210 8 234 8C258 8 266 4.5 292 4.5C318 4.5 326 9 350 9C374 9 384 2.5 414 2.5C442 2.5 448 7.5 472 7.5C496 7.5 506 5 530 5.5C556 6 580 11 600 11L600 31L520 31C511 31 510 35 504 35C498 35 497 31 488 31L360 31C351 31 350 35.5 343 35.5C336 35.5 335 31 326 31L190 31C182 31 181 34 176 34C171 34 170 31 162 31L90 31C82 31 81 35 75 35C69 35 68 31 60 31L0 31Z' fill='url%28%23g%29'/%3E%3Cg fill='%23fff'%3E%3Ccircle cx='140' cy='8' r='1.2'/%3E%3Ccircle cx='300' cy='8' r='1.1'/%3E%3Ccircle cx='450' cy='7' r='1.2'/%3E%3C/g%3E%3Cg fill='%23c3c8e8' opacity='.55'%3E%3Ccircle cx='220' cy='20' r='1'/%3E%3Ccircle cx='395' cy='19' r='1'/%3E%3Ccircle cx='70' cy='21' r='.9'/%3E%3C/g%3E%3C/svg%3E") center top / calc(100% - 90px) 36px no-repeat;
  filter: drop-shadow(0 3px 3px rgba(106, 34, 168, .14)) drop-shadow(0 0 5px rgba(255, 255, 255, .6));
}
.benefits::after { left: 18px; right: 18px; }

/* Petals become snowflakes (generated by prototypes/praznicna-na-sajtu/snowflakes.py):
   three crystal shapes, every second one turns the other way, different speeds */
:is(.hero, .page-hero, .contact-top) .petal { background: none; border-radius: 0; width: 38px; height: 38px; opacity: .95;
  filter: drop-shadow(0 2px 4px rgba(106, 34, 168, .35)) drop-shadow(0 0 6px rgba(255, 255, 255, .6)); animation: hd-spin 16s linear infinite; }
:is(.hero, .page-hero, .contact-top) .petal::before { content: ""; position: absolute; inset: 0; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-50 -50 100 100'%3E%3Cg fill='none' stroke='%23fff' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cg id='a'%3E%3Cpath d='M0 0V-44M0-14l-9-9M0-14l9-9M0-26l-7-7M0-26l7-7M0-36l-5-5M0-36l5-5'/%3E%3C/g%3E%3Cuse href='%23a' transform='rotate(60)'/%3E%3Cuse href='%23a' transform='rotate(120)'/%3E%3Cuse href='%23a' transform='rotate(180)'/%3E%3Cuse href='%23a' transform='rotate(240)'/%3E%3Cuse href='%23a' transform='rotate(300)'/%3E%3C/g%3E%3C/svg%3E") center / contain no-repeat; }
:is(.hero, .page-hero, .contact-top) .petal:nth-of-type(3n+2)::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-50 -50 100 100'%3E%3Cg fill='none' stroke='%23fff' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cg id='a'%3E%3Cpath d='M0 -6V-36M0-20l-10-8M0-20l10-8'/%3E%3Ccircle cx='0' cy='-41' r='4.5' fill='%23fff' stroke='none'/%3E%3C/g%3E%3Cuse href='%23a' transform='rotate(60)'/%3E%3Cuse href='%23a' transform='rotate(120)'/%3E%3Cuse href='%23a' transform='rotate(180)'/%3E%3Cuse href='%23a' transform='rotate(240)'/%3E%3Cuse href='%23a' transform='rotate(300)'/%3E%3Ccircle r='6' fill='%23fff' stroke='none'/%3E%3C/g%3E%3C/svg%3E"); }
:is(.hero, .page-hero, .contact-top) .petal:nth-of-type(3n)::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-50 -50 100 100'%3E%3Cg fill='none' stroke='%23fff' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cg id='a'%3E%3Cpath d='M0-12V-44M0-44l-6-6M0-44l6-6M0-30l-8-4M0-30l8-4'/%3E%3C/g%3E%3Cuse href='%23a' transform='rotate(60)'/%3E%3Cuse href='%23a' transform='rotate(120)'/%3E%3Cuse href='%23a' transform='rotate(180)'/%3E%3Cuse href='%23a' transform='rotate(240)'/%3E%3Cuse href='%23a' transform='rotate(300)'/%3E%3Cpath d='M0-13L11.3-6.5V6.5L0 13L-11.3 6.5V-6.5Z' fill='rgba(255,255,255,.55)'/%3E%3C/g%3E%3C/svg%3E"); }
:is(.hero, .page-hero, .contact-top) .petal:nth-of-type(even) { animation-name: hd-spin-back; animation-duration: 21s; }
:is(.hero, .page-hero, .contact-top) .petal:nth-of-type(4n+1) { animation-duration: 12s; }
@keyframes hd-spin { to { rotate: 360deg; } }
@keyframes hd-spin-back { to { rotate: -360deg; } }

@media (max-width: 860px) { :is(.hero, .page-hero, .contact-top) .petal { width: 26px; height: 26px; } }
@media (prefers-reduced-motion: reduce) { .hd-snow { display: none; } :is(.hero, .page-hero, .contact-top) .petal { animation: none; } }
