/* Christmas decoration (HcXmas::active(): first Advent Sunday to 2. 1.). Shared by the landing page and the Companion app.
   Purely cosmetic: remove the <link> and the site is back to normal. */

/* ---------- string of lights hanging under a fixed bar ---------- */
.xmas-garland { position: absolute; left: 0; right: 0; top: 100%; height: 30px; overflow: hidden; pointer-events: none; display: flex; z-index: 3; }
.xmas-garland .xg {
  flex: none; position: relative; width: 72px; height: 26px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='72' height='26' viewBox='0 0 72 26'%3E%3Cpath d='M0 1 Q36 24 72 1' fill='none' stroke='%232a5a34' stroke-width='2'/%3E%3C/svg%3E") no-repeat 0 0;
}
.xmas-garland .xg i {
  position: absolute; left: 50%; top: 11px; width: 8px; height: 13px; margin-left: -4px; border-radius: 40% 40% 50% 50%;
  background: var(--xc, #ff4d6d); box-shadow: 0 0 10px 2px var(--xc, #ff4d6d); animation: xg-twinkle 2.4s ease-in-out infinite;
}
.xmas-garland .xg i::before { content: ""; position: absolute; left: 1px; top: -4px; width: 6px; height: 5px; background: #2a3a30; border-radius: 1px; }
.xmas-garland .xg:nth-child(5n+1) i { --xc: #ff4d6d; animation-delay: 0s; }
.xmas-garland .xg:nth-child(5n+2) i { --xc: #ffd23f; animation-delay: .5s; }
.xmas-garland .xg:nth-child(5n+3) i { --xc: #4dd2ff; animation-delay: 1s; }
.xmas-garland .xg:nth-child(5n+4) i { --xc: #7dff8a; animation-delay: 1.5s; }
.xmas-garland .xg:nth-child(5n+5) i { --xc: #c07bff; animation-delay: 2s; }
@keyframes xg-twinkle { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .45; transform: scale(.82); } }

/* ---------- snow drift edge (top of the footer, bottom of cards) ---------- */
.xmas-drift { position: relative; }
.xmas-drift::before {
  content: ""; position: absolute; left: 0; right: 0; top: -13px; height: 14px; pointer-events: none;
  background: radial-gradient(circle at 14px 14px, #f4f8ff 13px, transparent 14px) repeat-x; background-size: 34px 14px;
  filter: drop-shadow(0 -2px 6px rgba(160, 200, 255, .25)); opacity: .92;
}

/* ---------- hero chip ---------- */
.xmas-chip { border-color: rgba(125, 255, 138, .35) !important; background: linear-gradient(90deg, rgba(198, 40, 40, .22), rgba(47, 107, 58, .25)) !important; }
.xmas-chip i { color: #bfe9ff; }

/* ---------- hero floaters (3D with a flat emoji fallback) ---------- */
.xmas-floater { font-size: 3rem; line-height: 1; display: grid; place-items: center; width: 100%; height: 100%; filter: drop-shadow(0 4px 10px rgba(0, 0, 0, .5)); }

/* ---------- village promo (landing page) ---------- */
.xv-wrap { display: grid; gap: 1.75rem; align-items: center; }
@media (min-width: 1024px) { .xv-wrap { grid-template-columns: 2fr 3fr; gap: 2.5rem; } }
.xv-eyebrow { display: inline-flex; align-items: center; gap: .5rem; padding: .35rem .9rem; border-radius: 999px; font-size: .8rem; font-weight: 600; color: #bfe9ff; border: 1px solid rgba(160, 215, 255, .35); background: rgba(120, 190, 255, .09); }
.xv-card { margin-top: 1.25rem; padding: 1rem 1.1rem; border-radius: 1rem; background: rgba(255, 255, 255, .045); border: 1px solid rgba(255, 255, 255, .1); }
.xv-bar { height: 10px; border-radius: 999px; background: rgba(255, 255, 255, .09); overflow: hidden; margin: .6rem 0 .45rem; }
.xv-bar > span { display: block; height: 100%; width: 0; border-radius: 999px; background: linear-gradient(90deg, #7ad7ff, #f4f8ff 55%, #ffd23f); transition: width 1s ease; box-shadow: 0 0 14px rgba(160, 220, 255, .6); }
.xv-row { display: flex; justify-content: space-between; gap: .75rem; font-size: .85rem; color: #aab4c6; }
.xv-row b { color: #fff; font-weight: 600; }
.xv-top { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .8rem; }
.xv-top span { display: inline-flex; align-items: center; gap: .35rem; padding: .22rem .6rem; border-radius: 999px; font-size: .75rem; font-weight: 600; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .1); color: #e5e7eb; }
.xv-top span i { color: #bfe9ff; }
.xv-stage {
  position: relative; width: 100%; aspect-ratio: 16 / 10; min-height: 260px; border-radius: 1.25rem; overflow: hidden;
  border: 1px solid rgba(160, 215, 255, .22); box-shadow: 0 30px 80px -30px rgba(40, 90, 160, .6);
  background: radial-gradient(ellipse at 50% 0%, rgba(40, 70, 130, .55), transparent 70%), linear-gradient(180deg, #0c1428, #0a0c12);
}
.xv-stage > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .75; }
.xv-stage.is-fx-ready > img { visibility: hidden; }
.xv-stage .fx3d { position: absolute; inset: 0; }
.xv-hint { position: absolute; left: 0; right: 0; bottom: .6rem; text-align: center; font-size: .72rem; color: rgba(255, 255, 255, .55); pointer-events: none; text-shadow: 0 1px 6px #000; }

/* ---------- Companion app ---------- */
.app-hero.xmas-on, .ex-hero.xmas-on { position: relative; }
.app-hero.xmas-on, .ex-hero.xmas-on { overflow: hidden; padding-top: 2.1rem; }
.app-hero.xmas-on .xmas-garland, .ex-hero.xmas-on .xmas-garland { top: -1px; }
.xmas .ex-card { position: relative; }
.xmas .ex-card::after {
  content: ""; position: absolute; left: 10px; right: 10px; top: -5px; height: 9px; pointer-events: none; z-index: 1;
  background: radial-gradient(circle at 9px 9px, #f4f8ff 8px, transparent 9px) repeat-x; background-size: 22px 9px; opacity: .85; border-radius: 6px;
}
@media (prefers-reduced-motion: reduce) { .xmas-garland .xg i { animation: none; } }

/* ---------- village: fullscreen ---------- */
.fx3d-fs {
  position: absolute; right: .6rem; top: .6rem; z-index: 5; width: 2.2rem; height: 2.2rem; display: grid; place-items: center; cursor: pointer;
  border-radius: .7rem; border: 1px solid rgba(190, 225, 255, .35); background: rgba(8, 14, 28, .55); color: #e7f3ff; font-size: 1rem;
  backdrop-filter: blur(4px); transition: background .2s, transform .2s;
}
.fx3d-fs:hover { background: rgba(30, 60, 110, .7); transform: scale(1.06); }
.fx3d-fs:focus-visible { outline: 2px solid #ffd23f; outline-offset: 2px; }
.is-fs { position: fixed !important; inset: 0 !important; z-index: 2147483000 !important; width: 100vw !important; height: 100vh !important; height: 100dvh !important; max-width: none !important; max-height: none !important; aspect-ratio: auto !important; margin: 0 !important; border-radius: 0 !important; border: 0 !important; }
.is-fs .fx3d { position: absolute; inset: 0; width: 100%; height: 100%; }
.fx3d-fs-lock, .fx3d-fs-lock body { overflow: hidden !important; }
.is-fs .xv-hint { display: none; }
.is-fs .fx3d-fs { right: 1rem; top: 1rem; }
.ex-xv-donors li.is-me { background: rgba(255, 210, 63, .12); border-radius: .5rem; }
.ex-xv-today b { color: #ffe27a; }
.fx3d-host.is-fx-ready > .fx3d-fs { visibility: visible !important; }
