/* Cheekys Creations Holographic Overdrive Layer
   High sparkle / controlled DOM / mobile-safe / reduced-motion aware. */
:root {
  --cc-overdrive-pink: #E95A96;
  --cc-overdrive-ink: #12070D;
  --cc-overdrive-soft: #FFF4FA;
  --cc-overdrive-blush: #F9D2E7;
  --cc-overdrive-candy: #F49CC4;
  --cc-overdrive-wine: #5B253A;
}

/* Storewide gemstone atmosphere */
html { overflow-x: hidden; }
body[data-glitter-overdrive="true"] {
  background:
    radial-gradient(circle at 9% 8%, rgba(255,255,255,.88) 0 0.3rem, transparent .35rem),
    radial-gradient(circle at 91% 14%, rgba(249,183,217,.68) 0 0.28rem, transparent .34rem),
    radial-gradient(circle at 18% 88%, rgba(233,90,150,.26), transparent 34%),
    radial-gradient(circle at 82% 78%, rgba(255,244,250,.78), transparent 31%),
    linear-gradient(135deg, #fff3fa 0%, #ffe0f0 45%, #fff7fb 100%);
}

body[data-glitter-overdrive="true"] .page-shell {
  position: relative;
  isolation: isolate;
  background:
    radial-gradient(circle at top left, rgba(255,255,255,.72), transparent 30%),
    radial-gradient(circle at bottom right, rgba(233,90,150,.16), transparent 38%);
}

/* Fixed sparkle weather field. Pointer-events none means buttons remain clean. */
.sparkle-rain-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 90;
  overflow: hidden;
  mix-blend-mode: screen;
  opacity: .92;
  contain: layout style paint;
}

.twinkle-particle {
  position: absolute;
  top: -24px;
  width: var(--sparkle-size, 9px);
  height: var(--sparkle-size, 9px);
  left: var(--sparkle-left, 50%);
  opacity: 0;
  will-change: transform, opacity;
  transform: translate3d(0, -24px, 0) rotate(0deg) scale(.8);
  animation: cheekys-glitter-rain var(--sparkle-duration, 4s) linear forwards;
  filter: drop-shadow(0 0 7px rgba(233,90,150,.92));
}

.twinkle-particle::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--sparkle-color, #FFF4FA);
  clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
  transform: rotate(var(--sparkle-rotate, 0deg));
}

.twinkle-particle.is-dot::before { border-radius: 999px; clip-path: none; }
.twinkle-particle.is-diamond::before { clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%); }
.twinkle-particle.is-cross::before { clip-path: polygon(44% 0, 56% 0, 56% 39%, 100% 39%, 100% 61%, 56% 61%, 56% 100%, 44% 100%, 44% 61%, 0 61%, 0 39%, 44% 39%); }

@keyframes cheekys-glitter-rain {
  0% { opacity: 0; transform: translate3d(0, -24px, 0) rotate(0deg) scale(.55); }
  8% { opacity: var(--sparkle-opacity, .78); }
  50% { opacity: var(--sparkle-opacity, .86); transform: translate3d(var(--sparkle-drift, 18px), 52vh, 0) rotate(210deg) scale(1.16); }
  86% { opacity: var(--sparkle-opacity, .72); }
  100% { opacity: 0; transform: translate3d(calc(var(--sparkle-drift, 18px) * -1), 110vh, 0) rotate(430deg) scale(.8); }
}

/* Hyper-glitter text and rich CTA reward loop */
.glitter-overdrive,
body[data-glitter-overdrive="true"] .hero-title,
body[data-glitter-overdrive="true"] .sparkle-station-title,
body[data-glitter-overdrive="true"] .ornament-title,
body[data-glitter-overdrive="true"] .about-mega-title {
  background: linear-gradient(45deg, #FFF4FA 10%, #F9D2E7 25%, #E95A96 43%, #F49CC4 58%, #12070D 72%, #E95A96 100%);
  background-size: 420% 420%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: hyper-glitter 3.6s ease infinite;
  filter: drop-shadow(0 0 10px rgba(233,90,150,.42));
}

@keyframes hyper-glitter {
  0% { background-position: 0% 50%; filter: drop-shadow(0 0 5px rgba(233,90,150,.35)); }
  50% { background-position: 100% 50%; filter: drop-shadow(0 0 16px rgba(233,90,150,.64)); }
  100% { background-position: 0% 50%; filter: drop-shadow(0 0 5px rgba(233,90,150,.35)); }
}

body[data-glitter-overdrive="true"] .site-header {
  position: sticky;
  top: 0;
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(18,7,13,.12), 0 0 0 1px rgba(233,90,150,.12) inset;
}

body[data-glitter-overdrive="true"] .site-header::after,
body[data-glitter-overdrive="true"] .home-showcase::before,
body[data-glitter-overdrive="true"] .sparkle-station-shell::before,
body[data-glitter-overdrive="true"] .product-card::after,
body[data-glitter-overdrive="true"] .giving-org-card::after,
body[data-glitter-overdrive="true"] .hero-visual-card::after {
  content: "";
  position: absolute;
  inset: -60%;
  pointer-events: none;
  background:
    linear-gradient(115deg, transparent 0 32%, rgba(255,255,255,.36) 44%, rgba(233,90,150,.25) 50%, rgba(255,255,255,.34) 57%, transparent 70% 100%),
    radial-gradient(circle, rgba(255,255,255,.72) 0 1px, transparent 1.7px);
  background-size: 220% 220%, 34px 34px;
  animation: cheekys-surface-gloss 5.8s linear infinite;
  opacity: .48;
  transform: rotate(-9deg);
}

@keyframes cheekys-surface-gloss {
  0% { background-position: -90% -90%, 0 0; }
  100% { background-position: 160% 160%, 34px 34px; }
}

body[data-glitter-overdrive="true"] .home-showcase,
body[data-glitter-overdrive="true"] .about-hero,
body[data-glitter-overdrive="true"] .sparkle-station-shell,
body[data-glitter-overdrive="true"] .statement-main > section:first-child {
  position: relative;
  overflow: hidden;
  border-radius: clamp(26px, 5vw, 62px);
}

body[data-glitter-overdrive="true"] .home-showcase {
  min-height: min(980px, calc(100vh - 36px));
  display: flex;
  align-items: center;
  background:
    radial-gradient(circle at 22% 10%, rgba(255,255,255,.92), transparent 30%),
    radial-gradient(circle at 78% 22%, rgba(249,183,217,.72), transparent 26%),
    radial-gradient(circle at 54% 84%, rgba(233,90,150,.18), transparent 45%),
    linear-gradient(135deg, #fff7fb 0%, #ffdced 58%, #fff3fa 100%);
  box-shadow: 0 35px 90px rgba(18,7,13,.13), 0 0 0 3px rgba(18,7,13,.06) inset;
}

body[data-glitter-overdrive="true"] .cta-slab,
body[data-glitter-overdrive="true"] .ghost-slab,
body[data-glitter-overdrive="true"] button,
body[data-glitter-overdrive="true"] .language-switcher a {
  position: relative;
  overflow: hidden;
  transform: translateZ(0);
}

body[data-glitter-overdrive="true"] .cta-slab::after,
body[data-glitter-overdrive="true"] .ghost-slab::after,
body[data-glitter-overdrive="true"] button::after,
body[data-glitter-overdrive="true"] .language-switcher a::after {
  content: "";
  position: absolute;
  inset: -150% -40%;
  background: linear-gradient(115deg, transparent 35%, rgba(255,255,255,.78), rgba(249,183,217,.62), transparent 64%);
  transform: translateX(-62%) rotate(10deg);
  transition: transform .65s ease;
  pointer-events: none;
}

body[data-glitter-overdrive="true"] .cta-slab:hover::after,
body[data-glitter-overdrive="true"] .ghost-slab:hover::after,
body[data-glitter-overdrive="true"] button:hover::after,
body[data-glitter-overdrive="true"] .language-switcher a:hover::after {
  transform: translateX(62%) rotate(10deg);
}

/* Big candy-shell card treatment */
body[data-glitter-overdrive="true"] .product-card,
body[data-glitter-overdrive="true"] .step-box,
body[data-glitter-overdrive="true"] .info-card,
body[data-glitter-overdrive="true"] .giving-org-card,
body[data-glitter-overdrive="true"] .policy-card,
body[data-glitter-overdrive="true"] .help-card {
  position: relative;
  overflow: hidden;
  background-image:
    radial-gradient(circle at 16% 12%, rgba(255,255,255,.82), transparent 24%),
    linear-gradient(145deg, rgba(255,255,255,.94), rgba(255,228,241,.82));
}

body[data-glitter-overdrive="true"] .sparkle-impact-lane,
body[data-glitter-overdrive="true"] .giving-orgs-grid,
body[data-glitter-overdrive="true"] .dark-band {
  position: relative;
  overflow: hidden;
}

/* Floating edge sparkles without extra DOM */
body[data-glitter-overdrive="true"] .page-shell::before,
body[data-glitter-overdrive="true"] .page-shell::after {
  content: "✦   ✧   ✦   ✧   ✦";
  position: fixed;
  pointer-events: none;
  z-index: 1;
  color: rgba(233,90,150,.22);
  font-size: clamp(1.1rem, 2vw, 2.4rem);
  letter-spacing: 1.9rem;
  animation: cheekys-edge-float 9s ease-in-out infinite;
}
body[data-glitter-overdrive="true"] .page-shell::before { top: 18%; left: -2rem; transform: rotate(-90deg); }
body[data-glitter-overdrive="true"] .page-shell::after { bottom: 16%; right: -2rem; transform: rotate(90deg); animation-delay: -4s; }

@keyframes cheekys-edge-float {
  0%, 100% { opacity: .3; translate: 0 0; }
  50% { opacity: .72; translate: 0 -14px; }
}

/* Keep PWA install tray above sparkle weather. */
.pwa-install-tray { z-index: 120; }
.mobile-quickbar { z-index: 110; }

/* Mobile: keep the magic, reduce density, protect tapping and readability. */
@media (max-width: 760px) {
  .sparkle-rain-container { opacity: .72; }
  body[data-glitter-overdrive="true"] .home-showcase { min-height: auto; border-radius: 28px; }
  body[data-glitter-overdrive="true"] .hero-title,
  body[data-glitter-overdrive="true"] .sparkle-station-title,
  body[data-glitter-overdrive="true"] .about-mega-title { filter: drop-shadow(0 0 6px rgba(233,90,150,.34)); }
  body[data-glitter-overdrive="true"] .page-shell::before,
  body[data-glitter-overdrive="true"] .page-shell::after { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .sparkle-rain-container { display: none !important; }
  .glitter-overdrive,
  body[data-glitter-overdrive="true"] .hero-title,
  body[data-glitter-overdrive="true"] .sparkle-station-title,
  body[data-glitter-overdrive="true"] .ornament-title,
  body[data-glitter-overdrive="true"] .about-mega-title,
  body[data-glitter-overdrive="true"] .site-header::after,
  body[data-glitter-overdrive="true"] .home-showcase::before,
  body[data-glitter-overdrive="true"] .sparkle-station-shell::before,
  body[data-glitter-overdrive="true"] .product-card::after,
  body[data-glitter-overdrive="true"] .giving-org-card::after,
  body[data-glitter-overdrive="true"] .hero-visual-card::after {
    animation: none !important;
  }
}

.hero-overdrive-note { margin: .75rem auto 0; max-width: 760px; font-weight: 900; color: #BC5989; text-align: center; letter-spacing: .01em; }
