/* Christmas look (CHG-060, CHG-061), loaded only while the "Kerstthema" switch of the Tips page is on (seasonal.php).
   Scoped to .kgt-xmas: the body of the Tips page, or the Tips band on the home page. Pine green, cranberry and the
   brand's sun gold; snow falling over the whole page, a string of lights over the featured articles, a star before
   the section titles. */
.kgt-xmas {
  --xm-pine: #173D33;
  --xm-pine-deep: #102B24;
  --xm-berry: #A61E33;
  --xm-snow: #F6F1E8;
  --xm-gold: var(--kgt-field-sun);
  --xm-star: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 1.5l2.9 6.6 7.1.6-5.4 4.7 1.6 7-6.2-3.7-6.2 3.7 1.6-7L2 8.7l7.1-.6z'/%3E%3C/svg%3E");
  /* Snowflakes: a white core with a soft blue-grey edge, so they show on the pine bands and on the light ones. Tile
     sizes 180, 240 and 360px all repeat every 720px, so each fall loops without a seam and the flakes never line up.
     Far: many small flakes. Near: fewer, larger ones. */
  --xm-far:
    radial-gradient(circle at 31px 47px, rgba(255, 255, 255, .9) 0 1px, rgba(150, 175, 190, .45) 1.6px, transparent 2.4px),
    radial-gradient(circle at 137px 121px, rgba(255, 255, 255, .85) 0 1px, rgba(150, 175, 190, .4) 1.6px, transparent 2.4px),
    radial-gradient(circle at 211px 29px, rgba(255, 255, 255, .85) 0 1.2px, rgba(150, 175, 190, .4) 1.8px, transparent 2.6px),
    radial-gradient(circle at 167px 197px, rgba(255, 255, 255, .9) 0 1px, rgba(150, 175, 190, .45) 1.6px, transparent 2.4px),
    radial-gradient(circle at 97px 317px, rgba(255, 255, 255, .8) 0 1.2px, rgba(150, 175, 190, .4) 1.8px, transparent 2.6px),
    radial-gradient(circle at 301px 233px, rgba(255, 255, 255, .85) 0 1px, rgba(150, 175, 190, .4) 1.6px, transparent 2.4px);
  --xm-near:
    radial-gradient(circle at 73px 163px, rgba(255, 255, 255, .95) 0 2.2px, rgba(150, 175, 190, .5) 3px, transparent 4px),
    radial-gradient(circle at 263px 251px, rgba(255, 255, 255, .95) 0 2.8px, rgba(150, 175, 190, .5) 3.6px, transparent 4.6px),
    radial-gradient(circle at 331px 89px, rgba(255, 255, 255, .9) 0 2.4px, rgba(150, 175, 190, .45) 3.2px, transparent 4.2px),
    radial-gradient(circle at 151px 41px, rgba(255, 255, 255, .9) 0 2px, rgba(150, 175, 190, .45) 2.8px, transparent 3.8px);
}

/* Snow: two layers that fall at different speeds and sway a little sideways (transform only, so it stays on the
   compositor). Over the whole Tips page as one fixed layer that never takes a click, under the header and the
   newsletter card; on the home page inside the Christmas band. */
.kgt-snow { position: fixed; inset: 0; z-index: 45; overflow: clip; pointer-events: none; }
.kgt-xmas-band { position: relative; overflow: clip; }
.kgt-snow::before, .kgt-snow::after, .kgt-xmas-band::before, .kgt-xmas-band::after {
  content: ""; position: absolute; left: -40px; right: -40px; top: -720px; bottom: 0; z-index: 1; pointer-events: none;
  will-change: transform; animation: kgt-xmas-far 26s linear infinite;
  background-image: var(--xm-far);
  background-size: 180px 180px, 180px 180px, 240px 240px, 240px 240px, 360px 360px, 360px 360px;
  background-position: 0 0, 0 0, 57px 0, 57px 0, 131px 0, 131px 0;
}
.kgt-snow::after, .kgt-xmas-band::after {
  animation: kgt-xmas-near 15s linear infinite;
  background-image: var(--xm-near);
  background-size: 240px 240px, 360px 360px, 360px 360px, 180px 180px;
  background-position: 0 0, 131px 0, 131px 0, 90px 0;
}
@keyframes kgt-xmas-far { 0% { transform: translate3d(0, 0, 0); } 50% { transform: translate3d(16px, 360px, 0); } 100% { transform: translate3d(0, 720px, 0); } }
@keyframes kgt-xmas-near { 0% { transform: translate3d(0, 0, 0); } 50% { transform: translate3d(-24px, 360px, 0); } 100% { transform: translate3d(0, 720px, 0); } }
/* Visitors who asked their device for less motion get no snow: still dots would only look like dirt on the screen. */
@media (prefers-reduced-motion: reduce) { .kgt-snow, .kgt-xmas-band::before, .kgt-xmas-band::after { display: none; } }

/* Hero: a pine shade instead of the navy one. */
body.kgt-xmas .kgt-hero::after { background: linear-gradient(90deg, rgba(16, 43, 36, .84) 0%, rgba(16, 43, 36, .48) 45%, rgba(16, 43, 36, .1) 100%), linear-gradient(0deg, rgba(16, 43, 36, .62) 0%, rgba(16, 43, 36, 0) 45%); }
@media (max-width: 767px) { body.kgt-xmas .kgt-hero::after { background: linear-gradient(0deg, rgba(16, 43, 36, .88) 0%, rgba(16, 43, 36, .38) 60%, rgba(16, 43, 36, .16) 100%); } }

/* Sticky jump chips */
body.kgt-xmas .kgt-jump__chip { background: var(--xm-snow); }
body.kgt-xmas .kgt-jump__chip:hover { background: #EBDFCB; }
body.kgt-xmas .kgt-jump__chip[aria-current="true"] { background: var(--xm-berry); color: #fff; }

/* Featured articles on a pine band, under a string of lights */
.kgt-xmas .kgt-feat { position: relative; background: var(--xm-pine); color: #fff; padding-top: calc(clamp(48px, 7vw, 104px) + 28px); }
.kgt-xmas .kgt-feat::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 40px; pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='40' viewBox='0 0 160 40'%3E%3Cpath d='M0 6Q40 22 80 6T160 6' fill='none' stroke='%23E6EDE9' stroke-opacity='.4' stroke-width='1.5'/%3E%3Cg fill='%23C9C2A8'%3E%3Crect x='17' y='11' width='3' height='4' rx='.5'/%3E%3Crect x='57' y='11' width='3' height='4' rx='.5'/%3E%3Crect x='97' y='11' width='3' height='4' rx='.5'/%3E%3Crect x='137' y='11' width='3' height='4' rx='.5'/%3E%3C/g%3E%3Cellipse cx='18.5' cy='20.5' rx='4' ry='6' fill='%23E0485D'/%3E%3Cellipse cx='58.5' cy='20.5' rx='4' ry='6' fill='%23F6D575'/%3E%3Cellipse cx='98.5' cy='20.5' rx='4' ry='6' fill='%2374D19C'/%3E%3Cellipse cx='138.5' cy='20.5' rx='4' ry='6' fill='%23FFF4D6'/%3E%3C/svg%3E") repeat-x 0 0 / 160px 40px;
}
.kgt-xmas .kgt-feat__title { color: #fff; }
.kgt-xmas .kgt-feat__text { color: rgba(255, 255, 255, .88); }
.kgt-xmas .kgt-feat .kgt-link { color: var(--xm-gold); }

/* Article cards (the featured band and the groups of the Tips page): warm snow, cranberry labels; white on the
   snow-coloured band so the cards keep their edge. */
.kgt-xmas .kgt-feat__card { background: var(--xm-snow); }
.kgt-xmas .kgt-section-sand .kgt-feat__card { background: #fff; }
.kgt-xmas .kgt-feat__pic { background: #E4DCCD; }
.kgt-xmas :is(.kgt-feat__place, .kgt-feat__more) { color: var(--xm-berry); }
.kgt-xmas :is(.kgt-feat, .kgt-section-navy) .kgt-feat__card:focus-visible { outline-color: var(--xm-gold); }
.kgt-xmas .kgt-feat__card:focus-visible { outline-color: var(--xm-berry); }

/* Section titles get a star: gold on the dark bands, cranberry on the light ones */
.kgt-xmas :is(.kgt-feat__title, .kgt-section .kgt-h2):not(.kgt-split)::before,
.kgt-xmas :is(.kgt-feat__title, .kgt-section .kgt-h2) .kgt-line:first-child > span::before {
  content: ""; display: inline-block; width: .62em; height: .62em; margin-right: .32em; vertical-align: .06em;
  background: var(--xm-berry); -webkit-mask: var(--xm-star) center / contain no-repeat; mask: var(--xm-star) center / contain no-repeat;
}
.kgt-xmas :is(.kgt-feat, .kgt-section-navy) :is(.kgt-feat__title, .kgt-h2):not(.kgt-split)::before,
.kgt-xmas :is(.kgt-feat, .kgt-section-navy) :is(.kgt-feat__title, .kgt-h2) .kgt-line:first-child > span::before { background: var(--xm-gold); }

/* The groups: pine instead of navy, warm snow instead of the cool sand */
body.kgt-xmas .kgt-section-navy { background: var(--xm-pine-deep); }
body.kgt-xmas .kgt-section-sand { background-color: var(--xm-snow); }

/* Home page: the Tips section as one pine band, flush with the section above. */
.kgt-tips:has(.kgt-xmas-band) { padding-top: 0; }
