/*
 * VZR Christmas v2 (refreshed): stat panels. Gaming clock = the LIVE dial in winter colours (xmas2-charts.js adds the wreath and
 * recolours the bars), week heat = candy canes. Sits inside the live .g2-activity panels. Needs xmas2-charts.js.
 */
body.xmas2 .xm-sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); border: 0; white-space: nowrap; }
body.xmas2 .xm-note { margin: 0; color: #d6e4f6; text-align: center; font: 12.5px/1.4 var(--g2-ui, Georgia, serif); }

/* ---------- gaming clock: the live dial, winter colours ---------- */
body.g2.xmas2 .g2-dial-svg { width: min(92%, 390px); margin: 6px 0 2px; }
body.g2.xmas2 #g2dHub stop:nth-child(1) { stop-color: #1f3278; }
body.g2.xmas2 #g2dHub stop:nth-child(2) { stop-color: #0a1038; }
body.g2.xmas2 #g2dGold stop:nth-child(1) { stop-color: #ffffff; }
body.g2.xmas2 #g2dGold stop:nth-child(2) { stop-color: #86b6ee; }
body.g2.xmas2 .g2-dial-svg circle[fill="url(#g2dHub)"] { stroke: url(#xm-stripes); stroke-width: 5.5; }
body.g2.xmas2 .g2-dial-num { fill: #eaf4ff; }
body.g2.xmas2 .g2-dial-svg circle[stroke="rgba(22,13,40,.85)"] { stroke: rgba(8, 14, 54, .9); }
body.g2.xmas2 .g2-dial-svg line[stroke^="rgba(255,2"] { stroke: rgba(196, 226, 255, .75); }
body.g2.xmas2 .g2-hub-kicker { fill: #ffd6dc; }
body.g2.xmas2 .g2-hub-main { fill: #ffffff; }
body.g2.xmas2 .g2-hub-colon { fill: #dcecff; }
body.g2.xmas2 .g2-hub-zone { fill: #bfe3ff; }
body.g2.xmas2 .g2-hub-sub { fill: #dfe9fb; }
body.g2.xmas2 .g2-dial-svg[data-period="night"] .g2-hub-tag { fill: #9fd4ff; }
body.g2.xmas2 .g2-dial-svg[data-period="day"] .g2-hub-tag { fill: #ffd98a; }
body.g2.xmas2 .g2-prime-arc { stroke: #ffd54a; filter: drop-shadow(0 0 4px rgba(255, 213, 74, .85)); }
body.g2.xmas2 .g2-hour.is-peak .g2-bar { filter: drop-shadow(0 0 6px rgba(255, 255, 255, .95)); }
body.g2.xmas2 .g2-sun { filter: drop-shadow(0 0 8px rgba(255, 213, 74, .95)); }
body.g2.xmas2 .xm-wreath { filter: drop-shadow(0 3px 4px rgba(0, 0, 0, .55)); pointer-events: none; }
body.g2.xmas2 .g2-sw.is-day { background: linear-gradient(135deg, #ff6b7e, #b0182f); }
body.g2.xmas2 .g2-sw.is-night { background: linear-gradient(135deg, #b8f0ff, #3a8fe0); }
body.g2.xmas2 .g2-sw.is-prime { background: #fff1c9; box-shadow: 0 0 6px rgba(255, 213, 74, .9); }
body.g2.xmas2 .g2-note { color: #d6e4f6; }
/* ---------- Candy canes (Week Heat) ---------- */
body.xmas2 .xm-canes { flex: 1 1 auto; display: flex; flex-direction: column; justify-content: center; gap: 12px; min-height: 0; }
body.xmas2 .xm-scene { position: relative; display: flex; align-items: flex-end; width: 100%; max-width: 600px; height: 300px; margin: 0 auto; padding: 0 4px; }
body.xmas2 .xm-scene::after {      /* the snow floor the canes stand on */
  content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 36px; z-index: 0;
  border-radius: 26px 26px 14px 14px / 14px 14px 14px 14px;
  background: linear-gradient(#f6faff, #c7dbf6);
  box-shadow: 0 -4px 14px rgba(170, 210, 255, .25), inset 0 2px 0 #fff;
}
body.xmas2 .xm-tree { position: relative; z-index: 1; flex: 0 0 clamp(70px, 24%, 140px); margin-bottom: 16px; }
body.xmas2 .xm-tree-svg { display: block; width: 100%; height: auto; overflow: visible; filter: drop-shadow(0 6px 8px rgba(0, 0, 0, .45)); }
body.xmas2 .xm-lights .l { fill: #ffd54a; animation: xm-bulb 1.7s ease-in-out infinite alternate; }
body.xmas2 .xm-lights .l1 { fill: #ff5468; animation-delay: -.5s; }
body.xmas2 .xm-lights .l2 { fill: #5ab8ff; animation-delay: -1s; }
body.xmas2 .xm-lights .l3 { fill: #fff3a8; animation-delay: -1.4s; }
@keyframes xm-bulb { from { opacity: .35; } to { opacity: 1; } }
body.xmas2 .xm-star { transform-box: fill-box; transform-origin: 50% 55%; animation: xm-star 3s ease-in-out infinite; }
body.xmas2 .xm-canes-row { position: relative; z-index: 1; flex: 1 1 auto; display: flex; align-items: flex-end; height: 100%; margin-left: 4px; }
body.xmas2 .xm-cane {
  position: relative; flex: 1 1 0; min-width: 0; max-width: 56px; height: 100%; padding: 0; border: 0; background: none;
  display: flex; flex-direction: column; justify-content: flex-end; color: inherit; cursor: pointer; -webkit-tap-highlight-color: transparent;
}
body.xmas2 .xm-cane-svg { display: block; width: 100%; height: calc(100% - 34px); overflow: visible; transition: transform .2s ease, filter .2s ease; }
body.xmas2 .xm-cane-part { stroke-dasharray: 100; animation: xm-grow .95s cubic-bezier(.22, .9, .3, 1) both; animation-delay: calc(var(--i, 0) * 85ms); }
body.xmas2 .xm-cane-val { animation: xm-pop .5s ease-out both; animation-delay: calc(var(--i, 0) * 85ms + 650ms); }
@keyframes xm-grow { from { stroke-dashoffset: 100; } to { stroke-dashoffset: 0; } }
@keyframes xm-pop { from { opacity: 0; } to { opacity: 1; } }
body.xmas2 .xm-cane-star { transform-box: fill-box; transform-origin: 50% 50%; animation: xm-twinkle 2.2s ease-in-out infinite; }
body.xmas2 .xm-cane.is-peak .xm-cane-svg { filter: drop-shadow(0 0 7px rgba(255, 207, 96, .75)); }
body.xmas2 .xm-cane:hover .xm-cane-svg, body.xmas2 .xm-cane:focus-visible .xm-cane-svg { transform: translateY(-5px); filter: drop-shadow(0 0 8px rgba(255, 255, 255, .6)); }
body.xmas2 .xm-cane:focus-visible { outline: 2px solid var(--xm-gold-hi); outline-offset: 0; border-radius: 8px; }
body.xmas2 .xm-cane-day {
  position: relative; z-index: 2; display: block; height: 34px; line-height: 34px; text-align: center;
  color: #1c2a55; font: 800 12.5px var(--xm-font-ui); letter-spacing: .03em;
}
body.xmas2 .xm-cane.is-peak .xm-cane-day { color: #8d1124; }
body.xmas2 .xm-cane:hover, body.xmas2 .xm-cane:focus-visible { z-index: 6; }

/* ---------- additions for the refreshed layout ---------- */
body.xmas2 .xm-canes-panel .g2-chart { justify-content: flex-start; gap: 10px; }
body.xmas2 .xm-scene { height: 270px; }

body.xmas2 .xm-treasury {
  display: flex; align-items: center; gap: 12px; width: 100%; box-sizing: border-box; padding: 8px 14px; border-radius: 12px;
  background: linear-gradient(90deg, rgba(227, 32, 63, .22), rgba(110, 160, 240, .12));
  border: 1px solid rgba(190, 220, 255, .28);
}
body.xmas2 .xm-gift svg { display: block; width: 32px; height: 32px; filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .6)); }
body.xmas2 .xm-treasury b { font: 800 30px/1 var(--g2-serif, Georgia, serif); color: #fff1c6; text-shadow: 0 2px 2px #000; font-variant-numeric: tabular-nums; }
body.xmas2 .xm-treasury-text { display: flex; flex-direction: column; gap: 2px; font: 800 12px/1.2 var(--g2-ui, sans-serif); letter-spacing: .08em; text-transform: uppercase; color: #dbe8fb; }
body.xmas2 .xm-treasury-text em { font: 700 12px/1.2 var(--g2-ui, sans-serif); font-style: normal; letter-spacing: .02em; text-transform: none; color: #aebfdc; }

@media (max-width: 760px) {
  body.xmas2 .xm-scene { height: min(270px, calc(46px + (100vw - 126px) * .64)); }
  body.xmas2 .xm-tree { flex-basis: 66px; }
}
@media (prefers-reduced-motion: reduce) {
}
html.g2-calm body.xmas2 .xm-cane-star, html.g2-calm body.xmas2 .xm-lights .l, html.g2-calm body.xmas2 .xm-star { animation: none; }