/* sugar-rush-br: custom hero layer (projects/sugar-rush-br/custom/hero-patch.js). Loaded after site.css.
   Candy shop of the game: sky + pink hills (bg), glossy "jelly" buttons, candy wrappers for facts.
   Text colours: ink #2b1238 / muted #5a3b6b on light panels; pink #c0177a and violet #6a2fc4 for accents (≥ 5:1).
   Decorative colours (large shapes only, never text): mint #4fd17a, orange #ff8a3d, sky #6fb6ff, lemon #ffd23f. */
.hx { --hero-ink: #2b1238; --hero-muted: #5a3b6b; --hx-pink: #ff7ab8; --hx-rose: #c0177a; --hx-violet: #6a2fc4; --hx-lemon: #ffd23f;
  position: relative; isolation: isolate; overflow: hidden; border-bottom: 0;
  padding: clamp(28px, 5vw, 72px) 0 clamp(44px, 6vw, 92px);
  background: linear-gradient(180deg, #9fd3ff 0%, #cfe8ff 34%, #ffe3f0 70%, #ffc1dd 100%); }
.hx::before { display: none; }

/* Candy colours shared by grid cells, bars and wrappers */
.hx-cell--pink, .hx-bar--pink { --c1: #ffa6cf; --c2: #e0288f; }
.hx-cell--violet, .hx-bar--violet { --c1: #c3a2ff; --c2: #6a2fc4; }
.hx-cell--orange, .hx-bar--orange { --c1: #ffc08f; --c2: #ff6a1f; }
.hx-cell--mint, .hx-bar--mint { --c1: #9ff2bd; --c2: #25b45a; }
.hx-cell--sky, .hx-bar--sky { --c1: #b5dcff; --c2: #3d8fe8; }
.hx-cell--lemon, .hx-bar--lemon { --c1: #fff09a; --c2: #f0b400; }

/* ---------- Backdrop: candyland photo (home) or CSS hills + clouds ---------- */
.hx-scene { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.hx-scene__img { width: 100%; height: 100%; object-fit: cover; object-position: 60% 72%; }
.hx--home .hx-scene::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(255, 245, 250, .5) 0%, rgba(255, 245, 250, 0) 50%), linear-gradient(0deg, var(--bg) 0, rgba(255, 245, 250, 0) 16%); }
.hx-hill { position: absolute; bottom: -48%; border-radius: 50%; box-shadow: inset 0 18px 0 rgba(255, 255, 255, .55); }
.hx-hill--a { left: -12%; width: 70%; height: 80%; background: radial-gradient(ellipse at 50% 20%, #ffd3e8, #ff9ccb 70%); }
.hx-hill--b { right: -18%; width: 78%; height: 92%; background: radial-gradient(ellipse at 40% 18%, #ffc6e1, #ff7ab8 75%); }
.hx-cloud { position: absolute; width: 150px; height: 42px; border-radius: 999px; background: rgba(255, 255, 255, .9);
  box-shadow: 34px -16px 0 2px rgba(255, 255, 255, .9), 78px 2px 0 -4px rgba(255, 255, 255, .9); }
.hx-cloud--a { top: 10%; right: 30%; }
.hx-cloud--b { top: 22%; right: 3%; transform: scale(.7); opacity: .85; }

/* ---------- Layout: text on a light "cloud" panel, visual on the right ---------- */
.hx .hero__inner--split { grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr); gap: clamp(24px, 4vw, 56px); align-items: center; }
.hx .hero__text { position: relative; padding: clamp(20px, 3vw, 34px) clamp(18px, 3vw, 36px); border-radius: 32px;
  background: rgba(255, 255, 255, .84); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  box-shadow: 0 24px 60px -28px rgba(106, 47, 196, .45), inset 0 0 0 2px rgba(255, 255, 255, .95); }
.hx .hero__media.hx-visual { max-width: none; min-width: 0; }

/* Typography: two-line H1, the second line in a glossy candy gradient with a white outline */
.hx h1 { font-size: clamp(2rem, 3.9vw, 3.25rem); font-weight: 900; line-height: 1.04; letter-spacing: -.025em; margin-bottom: .45em; }
.hx h1.hx-h1--long { font-size: clamp(1.85rem, 2.9vw, 2.55rem); }
.hx h1 .hx-h1a { display: block; color: var(--hero-ink); }
.hx h1 em { display: block; font-style: normal; padding-bottom: .06em; color: var(--hx-rose);
  background: linear-gradient(92deg, #c0177a 0%, #a3149a 45%, #6a2fc4 100%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 2px 0 #fff) drop-shadow(0 -2px 0 #fff) drop-shadow(2px 0 0 #fff) drop-shadow(-2px 0 0 #fff) drop-shadow(0 8px 12px rgba(192, 23, 122, .22)); }
.hx .hero__lead { font-size: 1.05rem; color: var(--hero-muted); }
.hx .hero__note { color: var(--hero-muted); }
.hx .hero__summary { border-radius: 16px; background: #fff5fa; border: 2px dashed #f1cfe2; }

/* Badges: one line separated by candy dots */
.hx .badges { gap: 0; align-items: center; margin-bottom: 14px; }
.hx .badge { background: none; border: 0; padding: 0; min-height: 0; font-size: .84rem; font-weight: 800; color: var(--hero-muted); }
.hx .badge .icon { display: none; }
.hx .badge + .badge::before { content: ""; display: inline-block; width: 10px; height: 10px; margin: 0 10px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff 0 18%, var(--dot, #ff7ab8) 50%); }
.hx .badge:nth-child(3)::before { --dot: #4fd17a; }
.hx .badge:nth-child(4)::before { --dot: #6fb6ff; }

/* ---------- Jelly buttons (hero + header Play) ---------- */
.hx .btn, .header-play__btn { position: relative; overflow: hidden; border: 0; border-radius: 999px; font-weight: 850; color: #fff;
  background: linear-gradient(180deg, #d92a8c 0%, #c0177a 48%, #a01067 100%); text-shadow: 0 1px 0 rgba(0, 0, 0, .2);
  box-shadow: 0 6px 0 #7d0c50, 0 16px 26px -10px rgba(192, 23, 122, .6), inset 0 -3px 0 rgba(0, 0, 0, .12);
  transition: transform .15s ease, box-shadow .15s ease; }
.header-play__btn { box-shadow: 0 4px 0 #7d0c50, 0 10px 18px -10px rgba(192, 23, 122, .6); }
.hx .btn::before, .header-play__btn::before { content: ""; position: absolute; left: 14%; right: 14%; top: 4px; height: 40%; border-radius: 999px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .62), rgba(255, 255, 255, 0)); pointer-events: none; }
.hx .btn:hover, .header-play__btn:hover { filter: none; transform: translateY(-2px); box-shadow: 0 8px 0 #7d0c50, 0 20px 30px -10px rgba(192, 23, 122, .65); }
.hx .btn:active, .header-play__btn:active { transform: translateY(4px); box-shadow: 0 2px 0 #7d0c50; }
.hx .btn--ghost { color: #fff; background: linear-gradient(180deg, #7f45d8 0%, #6a2fc4 48%, #55209f 100%);
  box-shadow: 0 6px 0 #3b1475, 0 16px 26px -12px rgba(106, 47, 196, .6), inset 0 -3px 0 rgba(0, 0, 0, .12); }
.hx .btn--ghost:hover { background: linear-gradient(180deg, #7f45d8 0%, #6a2fc4 48%, #55209f 100%); box-shadow: 0 8px 0 #3b1475, 0 20px 30px -12px rgba(106, 47, 196, .6); }
.hx .btn--ghost:active { box-shadow: 0 2px 0 #3b1475; }
.hx .hero__actions { gap: 16px 14px; margin-bottom: 16px; }

/* ---------- Candy wrappers: facts (engine stats + the visual's wrappers) ---------- */
.hx .hero__stats, .hx-wrappers { display: flex; flex-wrap: wrap; gap: 12px 30px; list-style: none; margin: 22px 0 0; padding: 0 18px; max-width: none; }
.hx .stat, .hx-wrap { --w: #ff7ab8; --wl: #ffe3f0; position: relative; display: flex; flex-direction: column; justify-content: center; min-width: 0;
  padding: 7px 16px; border-radius: 14px; background: var(--wl); border: 2px solid var(--w); box-shadow: 0 6px 14px -8px rgba(43, 18, 56, .35); }
.hx .stat::before, .hx .stat::after, .hx-wrap::before, .hx-wrap::after { content: ""; position: absolute; top: 50%; width: 18px; height: 30px; background: var(--w); transform: translateY(-50%); }
.hx .stat::before, .hx-wrap::before { left: -18px; clip-path: polygon(100% 30%, 0 0, 35% 25%, 0 50%, 35% 75%, 0 100%, 100% 70%); }
.hx .stat::after, .hx-wrap::after { right: -18px; clip-path: polygon(0 30%, 100% 0, 65% 25%, 100% 50%, 65% 75%, 100% 100%, 0 70%); }
.hx .stat:nth-child(4n+2), .hx-wrap--1 { --w: #8a5ae0; --wl: #efe6ff; }
.hx .stat:nth-child(4n+3), .hx-wrap--2 { --w: #3fbf6d; --wl: #e2f8ea; }
.hx .stat:nth-child(4n+4), .hx-wrap--3 { --w: #f0b400; --wl: #fff4c7; }
.hx .stat__icon { display: none; }
.hx .stat dt, .hx-wrap span { font-size: .72rem; font-weight: 700; color: #5a3b6b; order: 0; line-height: 1.2; }
.hx .stat dd, .hx-wrap b { margin: 0; font-size: 1.02rem; font-weight: 900; color: #2b1238; line-height: 1.2; }

/* ---------- Home: candy grid 7×7 with doubling marks, floating key art ---------- */
.hx-candy { position: relative; margin: 0; padding: 0 0 6px; }
.hx-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; width: 82%; margin-left: auto; padding: 14px; border-radius: 28px;
  background: rgba(255, 255, 255, .58); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); transform: rotate(-3deg);
  box-shadow: inset 0 0 0 3px rgba(255, 255, 255, .9), 0 26px 50px -24px rgba(106, 47, 196, .5); }
.hx-cell { position: relative; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle at 34% 28%, #fff 0 9%, var(--c1) 36%, var(--c2) 100%);
  box-shadow: inset 0 -3px 5px rgba(0, 0, 0, .14), 0 2px 3px rgba(43, 18, 56, .12); }
.hx-cell.is-marked { background: radial-gradient(circle at 34% 28%, #fff 0 8%, var(--c2) 42%, color-mix(in srgb, var(--c2) 62%, #2b1238) 100%); box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--hx-rose), 0 6px 12px rgba(192, 23, 122, .35); z-index: 1; }
.hx-cell i { position: absolute; inset: 0; display: grid; place-items: center; font-style: normal; font-weight: 900; font-size: clamp(.62rem, 1.05vw, .9rem); color: #fff;
  text-shadow: 0 1px 2px rgba(43, 18, 56, .7), 0 0 4px rgba(43, 18, 56, .5); letter-spacing: -.02em; }
.hx-candy__key { position: absolute; left: -2%; top: 40%; width: 44%; z-index: 2; border-radius: 26px; border: 4px solid #fff; transform: rotate(4deg);
  box-shadow: 0 30px 50px -18px rgba(43, 18, 56, .55); transition: transform .3s ease; }
.hx-candy:hover .hx-candy__key { transform: rotate(2deg) translateY(-10px); }
.hx-candy .hx-wrappers { justify-content: flex-end; margin-top: 26px; padding-left: 46%; }
.hx-candy figcaption { margin-top: 12px; text-align: right; font-size: .78rem; font-weight: 700; color: #5a3b6b; }

/* ---------- Gumball machine (Demo pages) ---------- */
.hx-machine { position: relative; width: min(100%, 400px); margin: 0 auto; display: flex; flex-direction: column; align-items: center; }
.hx-dome { position: relative; width: 100%; aspect-ratio: 1; border-radius: 50%; overflow: hidden; background: #fff; border: 10px solid rgba(255, 255, 255, .92);
  box-shadow: 0 0 0 4px var(--hx-pink), 0 32px 60px -26px rgba(106, 47, 196, .6); }
.hx-dome__img { width: 100%; height: 100%; object-fit: cover; object-position: 42% 50%; }
.hx-dome__shine { position: absolute; inset: 0; border-radius: 50%; pointer-events: none;
  background: radial-gradient(ellipse 34% 22% at 30% 20%, rgba(255, 255, 255, .85), rgba(255, 255, 255, 0) 70%),
    radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0) 62%, rgba(255, 255, 255, .4) 70%, rgba(255, 255, 255, 0) 73%); }
.hx-machine__neck { width: 36%; height: 20px; margin-top: -6px; border-radius: 8px 8px 0 0; background: linear-gradient(180deg, #ffe680, #f0b400); box-shadow: inset 0 -4px 0 rgba(0, 0, 0, .12); }
.hx-machine__base { width: 76%; display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 16px 14px 20px;
  border-radius: 20px 20px 34px 34px; background: linear-gradient(180deg, #ff5aa8, #c0177a); box-shadow: 0 8px 0 #7d0c50, 0 26px 40px -18px rgba(192, 23, 122, .65); }
.hx-slot { width: 50px; height: 10px; border-radius: 999px; background: #5a0a39; box-shadow: inset 0 2px 3px rgba(0, 0, 0, .55), 0 1px 0 rgba(255, 255, 255, .35); }
.hx-coin { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 10px 20px; border-radius: 999px; text-align: center;
  font-weight: 900; color: #2b1238; text-decoration: none; background: radial-gradient(circle at 35% 25%, #fffbe0, #ffd23f 45%, #e8a800);
  box-shadow: 0 5px 0 #9c6f00, 0 12px 20px -8px rgba(0, 0, 0, .35); transition: transform .15s ease; }
.hx-coin:hover { transform: translateY(-2px); text-decoration: none; }
.hx-plates { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; list-style: none; padding: 0; margin: 20px 0 0; }
.hx-plates li { padding: 6px 14px; border-radius: 999px; background: #fff; border: 2px solid #f1cfe2; font-size: .86rem; color: #2b1238; }
.hx-plates b { color: var(--hx-rose); }

/* ---------- Night candy shop: Sugar Rush 1000 pages ---------- */
.hx--sr1000, .hx--sr1000demo { --hero-ink: #fff; --hero-muted: #efe2ff;
  background: radial-gradient(ellipse at 75% 15%, #7a3ad6 0%, rgba(122, 58, 214, 0) 55%), linear-gradient(180deg, #1b0b3a 0%, #34126c 55%, #5a24ad 100%); }
.hx--sr1000 .hx-scene::before, .hx--sr1000demo .hx-scene::before { content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle, #fff 0 1.2px, transparent 2px) 0 0 / 90px 70px, radial-gradient(circle, rgba(255, 255, 255, .7) 0 1px, transparent 1.6px) 40px 30px / 120px 90px; opacity: .55; }
.hx--sr1000 .hx-hill--a, .hx--sr1000demo .hx-hill--a { background: radial-gradient(ellipse at 50% 20%, #9b4fd6, #5a1f8f 75%); box-shadow: inset 0 16px 0 rgba(255, 255, 255, .18); }
.hx--sr1000 .hx-hill--b, .hx--sr1000demo .hx-hill--b { background: radial-gradient(ellipse at 40% 18%, #d0459b, #7d1b6a 75%); box-shadow: inset 0 16px 0 rgba(255, 255, 255, .18); }
.hx--sr1000 .hx-cloud, .hx--sr1000demo .hx-cloud { display: none; }
.hx--sr1000 .hero__text, .hx--sr1000demo .hero__text { background: rgba(27, 11, 58, .62); box-shadow: 0 24px 60px -28px rgba(0, 0, 0, .7), inset 0 0 0 2px rgba(255, 255, 255, .16); }
.hx--sr1000 h1 em, .hx--sr1000demo h1 em { background: linear-gradient(92deg, #ffd23f 0%, #ffa6cf 55%, #d9c2ff 100%); -webkit-background-clip: text; background-clip: text;
  filter: drop-shadow(0 2px 0 #2b1238) drop-shadow(0 -2px 0 #2b1238) drop-shadow(2px 0 0 #2b1238) drop-shadow(-2px 0 0 #2b1238); }
.hx--sr1000 .badge + .badge::before, .hx--sr1000demo .badge + .badge::before { --dot: #ffd23f; }
.hx--sr1000 .btn--ghost, .hx--sr1000demo .btn--ghost { box-shadow: 0 6px 0 #241050, 0 0 0 2px rgba(255, 255, 255, .5); }
.hx-night { position: relative; margin: 0; padding: 0 0 40px 30px; }
.hx-night__art { width: 100%; border-radius: 28px; border: 4px solid rgba(255, 255, 255, .85); box-shadow: 0 30px 60px -22px rgba(0, 0, 0, .7); }
.hx-bigx { position: absolute; left: -2%; bottom: 0; font-size: clamp(3.4rem, 8.4vw, 6.6rem); font-weight: 900; line-height: 1; letter-spacing: -.04em; color: #ffd23f;
  transform: rotate(-7deg); text-shadow: 0 3px 0 #fff, 0 -3px 0 #fff, 3px 0 0 #fff, -3px 0 0 #fff, 3px 3px 0 #fff, -3px -3px 0 #fff, 0 9px 0 #c0177a, 0 20px 30px rgba(0, 0, 0, .5); }
.hx-night .hx-wrappers { position: absolute; top: -14px; right: 4px; flex-direction: column; align-items: flex-end; gap: 10px; margin: 0; padding: 0 18px; }
.hx--sr1000demo .hx-dome { box-shadow: 0 0 0 4px #b48cff, 0 32px 60px -26px rgba(0, 0, 0, .7); background: #2b1238; }
.hx--sr1000demo .hx-dome__img { object-position: 50% 40%; }
.hx--sr1000demo .hx-machine__base { background: linear-gradient(180deg, #8a5ae0, #4a1c95); box-shadow: 0 8px 0 #2a0f5c, 0 26px 40px -18px rgba(0, 0, 0, .6); }
.hx--sr1000demo .hx-slot { background: #1b0b3a; }

/* ---------- Super Scatter: burst of rays, big star, ladder of instant prizes ---------- */
.hx--ss, .hx--ssdemo { background: linear-gradient(180deg, #ffeaa6 0%, #ffe0ef 62%, #ffc1dd 100%); }
.hx--ss .hx-cloud, .hx--ssdemo .hx-cloud { opacity: .6; }
.hx-star { position: relative; display: grid; place-items: center; width: 200px; aspect-ratio: 1; filter: drop-shadow(0 6px 0 #c0177a) drop-shadow(0 18px 22px rgba(192, 23, 122, .35)); }
.hx-star__shape { position: absolute; inset: 0; background: radial-gradient(circle at 42% 32%, #fffbe0 0%, #ffd23f 38%, #ff8a3d 100%);
  clip-path: polygon(50% 0%, 61.5% 34.5%, 98% 35.5%, 69% 57.5%, 79.5% 92%, 50% 71.5%, 20.5% 92%, 31% 57.5%, 2% 35.5%, 38.5% 34.5%); }
.hx-star__text { position: relative; margin-top: 12%; text-align: center; font-weight: 900; font-size: 1.2rem; line-height: 1; color: #a3106a; text-shadow: 0 2px 0 #fff; }
.hx-star__text b { display: block; font-size: .78em; color: #6a2fc4; }
.hx-burst { position: relative; margin: 0; display: flex; flex-direction: column; align-items: center; }
.hx-rays { position: absolute; left: 50%; top: 100px; z-index: -1; width: 620px; height: 620px; border-radius: 50%; transform: translate(-50%, -50%);
  background: repeating-conic-gradient(from 0deg, rgba(255, 210, 63, .7) 0 9deg, rgba(255, 255, 255, 0) 9deg 18deg);
  -webkit-mask-image: radial-gradient(circle, #000 18%, transparent 68%); mask-image: radial-gradient(circle, #000 18%, transparent 68%); }
.hx-steps { display: flex; align-items: flex-end; gap: 10px; width: 100%; max-width: 440px; list-style: none; margin: 16px 0 0; padding: 0; }
.hx-steps li { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 2px; text-align: center;
  height: calc(70px + var(--i) * 30px); padding: 8px 4px; border-radius: 18px 18px 8px 8px; background: linear-gradient(180deg, #fff, #ffe3f0);
  border: 3px solid #fff; box-shadow: 0 6px 0 #f19cc6, 0 16px 24px -12px rgba(192, 23, 122, .45); }
.hx-steps li:last-child { background: linear-gradient(180deg, #fff6c7, #ffd23f); box-shadow: 0 6px 0 #d79b00, 0 16px 24px -12px rgba(192, 23, 122, .45); }
.hx-steps b { font-size: clamp(.92rem, 1.6vw, 1.15rem); font-weight: 900; color: #a3106a; line-height: 1.1; }
.hx-steps span { font-size: .7rem; font-weight: 700; color: #5a3b6b; line-height: 1.15; }
.hx-burst .hx-wrappers { justify-content: center; }
.hx--ssdemo .hx-dome { display: grid; place-items: center; background: radial-gradient(circle, #fff6c7 0%, #ffd0e6 70%); }
.hx-dome__rays { position: absolute; inset: 0; background: repeating-conic-gradient(from 0deg, rgba(255, 210, 63, .6) 0 9deg, rgba(255, 255, 255, 0) 9deg 18deg); }
.hx-star--dome { width: 62%; }
.hx-star--dome .hx-star__text { font-size: clamp(1rem, 2.6vw, 1.6rem); }
.hx-star--corner { position: absolute; top: -12px; right: -10px; width: 112px; transform: rotate(14deg); z-index: 2; }
.hx-star--corner .hx-star__text { font-size: .74rem; }

/* ---------- Strategy: ladder of candy bars x2 → x128 ---------- */
.hx--strategies { background: linear-gradient(180deg, #d8c6ff 0%, #f0e6ff 34%, #ffe3f0 70%, #ffc1dd 100%); }
.hx-ladder { margin: 0; padding: 22px 22px 18px; border-radius: 30px; background: rgba(255, 255, 255, .74); box-shadow: inset 0 0 0 2px #fff, 0 24px 50px -26px rgba(106, 47, 196, .5); }
.hx-bars { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); align-items: end; gap: 8px; height: 250px; list-style: none; margin: 0; padding: 0; }
.hx-bars li { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; min-width: 0; }
.hx-bar { width: 100%; max-width: 46px; height: calc(12% + var(--i) * 13%); border-radius: 999px 999px 10px 10px;
  background: repeating-linear-gradient(135deg, var(--c2) 0 9px, var(--c1) 9px 18px); box-shadow: inset 0 -4px 0 rgba(0, 0, 0, .12), inset 7px 0 0 rgba(255, 255, 255, .35); }
.hx-bars b { margin-top: 6px; font-size: .9rem; font-weight: 900; color: #2b1238; }
.hx-ladder figcaption { margin-top: 12px; text-align: center; font-size: .9rem; font-weight: 700; color: #5a3b6b; }
.hx-note-card { margin: 14px 0 0; padding: 10px 16px; border-radius: 16px; background: #fff; border: 2px dashed #b48cff; font-size: .9rem; color: #2b1238; text-align: center; }
.hx-note-card b { color: var(--hx-violet); }

/* ---------- App: lollipop phone ---------- */
.hx--app { background: linear-gradient(180deg, #ffe4cc 0%, #fff0e4 34%, #ffe3f0 70%, #ffc1dd 100%); }
.hx-pop { position: relative; display: flex; flex-direction: column; align-items: center; }
.hx-pop__phone { position: relative; width: min(240px, 66%); aspect-ratio: 9 / 18; padding: 12px; border-radius: 46px;
  background: repeating-linear-gradient(45deg, #ff5aa8 0 14px, #fff 14px 28px); box-shadow: 0 32px 50px -22px rgba(43, 18, 56, .55), inset 0 0 0 3px rgba(255, 255, 255, .7); }
.hx-pop__screen { width: 100%; height: 100%; border-radius: 36px; overflow: hidden; background: #fff; box-shadow: 0 0 0 3px #fff; }
.hx-pop__img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; }
.hx-pop__notch { position: absolute; top: 20px; left: 50%; z-index: 2; width: 64px; height: 16px; border-radius: 999px; background: #2b1238; transform: translateX(-50%); }
.hx-pop__stick { width: 18px; height: 86px; margin-top: -2px; border-radius: 0 0 9px 9px; background: linear-gradient(90deg, #eadbc8, #fff 45%, #dccab3); box-shadow: 0 12px 20px -12px rgba(0, 0, 0, .35); }
.hx-sticker { position: absolute; right: 0; top: 12%; max-width: 170px; margin: 0; padding: 12px 16px; border-radius: 18px; transform: rotate(8deg);
  background: #ffd23f; color: #2b1238; font-size: .86rem; line-height: 1.25; text-align: center; box-shadow: 0 6px 0 #c99100, 0 16px 24px -12px rgba(0, 0, 0, .35); }
.hx-sticker b { display: block; font-size: 1.02rem; }

/* ---------- Casinos hub: three candy bars in twisted wrappers ---------- */
.hx--casino { background: linear-gradient(180deg, #c6f2da 0%, #e8fbf0 34%, #ffe3f0 70%, #ffc1dd 100%); }
.hx-candies { display: flex; flex-direction: column; gap: 18px; list-style: none; margin: 0; padding: 0 28px; }
.hx-candies li { --w1: #ff7ab8; --w2: #ffd3e8; }
.hx-candies li:nth-child(3n+2) { --w1: #6fb6ff; --w2: #d8ebff; }
.hx-candies li:nth-child(3n+3) { --w1: #4fd17a; --w2: #d6f6e2; }
.hx-candybar { position: relative; display: grid; grid-template-columns: 92px minmax(0, 1fr) 24px; align-items: center; gap: 14px; padding: 12px 18px; border-radius: 18px;
  color: #2b1238; text-decoration: none; border: 8px solid transparent;
  background: linear-gradient(#fff, #fff) padding-box, repeating-linear-gradient(-45deg, var(--w1) 0 8px, var(--w2) 8px 16px) border-box;
  box-shadow: 0 16px 28px -16px rgba(43, 18, 56, .45); transition: transform .2s ease; }
.hx-candybar::before, .hx-candybar::after { content: ""; position: absolute; top: 50%; width: 30px; height: 64px; background: var(--w1); transform: translateY(-50%); }
.hx-candybar::before { left: -36px; clip-path: polygon(100% 32%, 0 0, 40% 22%, 0 40%, 40% 60%, 0 80%, 40% 88%, 0 100%, 100% 68%); }
.hx-candybar::after { right: -36px; clip-path: polygon(0 32%, 100% 0, 60% 22%, 100% 40%, 60% 60%, 100% 80%, 60% 88%, 100% 100%, 0 68%); }
.hx-candybar:hover { transform: rotate(-1deg) scale(1.02); text-decoration: none; }
.hx-candybar__logo { display: grid; place-items: center; height: 48px; }
.hx-candybar__logo .hx-logo { max-height: 40px; max-width: 92px; width: auto; }
.hx-candybar__body { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; }
.hx-candybar__body strong { font-size: 1.02rem; }
.hx-candybar__body span { font-size: .84rem; color: #5a3b6b; }
.hx-candybar__body b { color: var(--hx-rose); }
.hx-candybar__go { font-size: 1.3rem; font-weight: 900; color: var(--hx-rose); }

/* ---------- Game + casino: one big wrapper ---------- */
.hx--operator { background: linear-gradient(180deg, #ffd8ea 0%, #fff0f7 40%, #ffe3f0 70%, #ffc1dd 100%); }
.hx-bigwrap { position: relative; margin: 0 40px; padding: 20px 22px; border-radius: 26px; border: 10px solid transparent;
  background: linear-gradient(#fff, #fff) padding-box, repeating-linear-gradient(-45deg, #ff7ab8 0 10px, #ffd3e8 10px 20px) border-box;
  box-shadow: 0 26px 50px -24px rgba(192, 23, 122, .5); }
.hx-bigwrap::before, .hx-bigwrap::after { content: ""; position: absolute; top: 50%; width: 40px; height: 110px; background: #ff7ab8; transform: translateY(-50%); }
.hx-bigwrap::before { left: -48px; clip-path: polygon(100% 30%, 0 0, 40% 20%, 0 38%, 40% 55%, 0 72%, 40% 86%, 0 100%, 100% 70%); }
.hx-bigwrap::after { right: -48px; clip-path: polygon(0 30%, 100% 0, 60% 20%, 100% 38%, 60% 55%, 100% 72%, 60% 86%, 100% 100%, 0 70%); }
.hx-bigwrap__brand { display: flex; align-items: center; justify-content: center; gap: 16px; padding-bottom: 16px; margin-bottom: 16px; border-bottom: 2px dashed #f1cfe2; }
.hx-bigwrap__brand .hx-logo { max-height: 52px; max-width: 150px; width: auto; }
.hx-bigwrap__x { font-size: 1.7rem; font-weight: 900; color: var(--hx-rose); }
.hx-bigwrap__game { width: 84px; height: 84px; border-radius: 20px; object-fit: cover; border: 3px solid #fff; box-shadow: 0 10px 20px -10px rgba(43, 18, 56, .5); }
.hx-bigwrap__rows { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 0; }
.hx-bigwrap__rows div { padding: 10px 12px; border-radius: 14px; background: #fff5fa; min-width: 0; }
.hx-bigwrap__rows dt { font-size: .74rem; font-weight: 700; color: #5a3b6b; }
.hx-bigwrap__rows dd { margin: 0; font-size: .94rem; font-weight: 850; color: #2b1238; line-height: 1.3; }
.hx-logo--mono { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--hx-rose); color: #fff; font-weight: 900; }

/* ---------- Series block on the home page (custom/series-patch.js) ---------- */
.sx-table .sx-original td { background: #fff5fa; }
.sx-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; list-style: none; margin: 22px 0 0; padding: 0; }
.sx-card { display: grid; grid-template-columns: 120px minmax(0, 1fr) 24px; align-items: center; gap: 16px; height: 100%; padding: 14px 18px 14px 14px; border-radius: 20px;
  background: var(--surface); border: 2px solid var(--line); color: var(--text); text-decoration: none; box-shadow: 0 10px 24px -18px rgba(43, 18, 56, .45); transition: transform .2s ease, border-color .2s ease; }
.sx-card:hover { transform: translateY(-2px); border-color: #ff7ab8; text-decoration: none; }
.sx-card__media { display: grid; place-items: center; height: 82px; border-radius: 14px; overflow: hidden; background: linear-gradient(135deg, #3a1677, #6a2fc4); }
.sx-card__media img { width: 100%; height: 100%; object-fit: cover; }
.sx-card--star .sx-card__media { background: radial-gradient(circle, #fff6c7, #ffd0e6); }
.sx-card__body { display: flex; flex-direction: column; min-width: 0; line-height: 1.35; }
.sx-card__body strong { color: var(--ink); font-size: 1.04rem; }
.sx-card__body span { font-size: .9rem; color: var(--muted); }
.sx-card__go { font-size: 1.3rem; font-weight: 900; color: var(--primary); }
.sx-star { display: grid; place-items: center; width: 74px; aspect-ratio: 1; text-align: center; font-weight: 900; font-size: .66rem; line-height: 1; color: #a3106a;
  background: radial-gradient(circle at 42% 32%, #fffbe0 0%, #ffd23f 38%, #ff8a3d 100%); padding-top: 10%;
  clip-path: polygon(50% 0%, 61.5% 34.5%, 98% 35.5%, 69% 57.5%, 79.5% 92%, 50% 71.5%, 20.5% 92%, 31% 57.5%, 2% 35.5%, 38.5% 34.5%); }
.sx-star b { display: block; color: #6a2fc4; }

/* ---------- Variant demo players (custom/player-patch.js) ---------- */
.vx-player { scroll-margin-top: calc(var(--header-h) + 60px); }
.vx-player .player__cover-img { width: 100%; height: 100%; object-fit: cover; }
.vx-cover-star { position: absolute; inset: 0; display: grid; place-items: center;
  background: repeating-conic-gradient(from 0deg, rgba(255, 210, 63, .55) 0 9deg, rgba(255, 255, 255, 0) 9deg 18deg), radial-gradient(circle, #fff6c7, #ffc1dd 75%); }
.vx-cover-star .sx-star { width: min(40%, 220px); font-size: clamp(.9rem, 2.4vw, 1.6rem); }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .hx .hero__inner--split { grid-template-columns: 1fr; }
  .hx .hero__text { border-radius: 26px; }
  .hx-candy { display: flex; flex-direction: column; align-items: center; }
  .hx-candy__key { position: relative; order: -1; left: auto; top: auto; width: 46%; max-width: 220px; margin-bottom: -16%; transform: rotate(-3deg); }
  .hx-candy:hover .hx-candy__key { transform: rotate(-3deg); }
  .hx-grid { width: 100%; max-width: 420px; margin: 0 auto; grid-template-columns: repeat(5, minmax(0, 1fr)); transform: none; padding-top: 18%; }
  .hx-cell:nth-child(n+26) { display: none; }
  .hx-cell i { font-size: .82rem; }
  .hx-candy .hx-wrappers { padding: 0 18px; justify-content: center; }
  .hx-candy figcaption { text-align: center; }
  .hx-night { padding: 0 0 30px; max-width: 460px; margin: 0 auto; }
  .hx-night { display: flex; flex-direction: column; }
  .hx-night .hx-wrappers { position: static; flex-direction: row; flex-wrap: wrap; justify-content: center; align-items: center; margin-top: 18px; }
  .hx-bigx { position: relative; left: auto; bottom: auto; align-self: flex-start; margin: -0.55em 0 0 4px; }
  .hx-machine { width: min(100%, 320px); }
  .hx-ladder { max-width: 460px; margin: 0 auto; }
  .hx-candies { max-width: 460px; margin: 0 auto; }
  .hx-bigwrap { max-width: 460px; margin: 0 auto; }
}
@media (max-width: 520px) {
  .hx h1 { font-size: clamp(1.75rem, 8.4vw, 2.2rem); }
  .hx .hero__lead { font-size: 1rem; }
  .hx .hero__stats { gap: 10px 30px; padding: 0 18px; }
  .hx .hero__stats .stat { flex: 0 1 auto; }
  .hx-bars { height: 190px; gap: 5px; }
  .hx-bars b { font-size: .74rem; }
  .hx-rays { width: 420px; height: 420px; }
  .hx-star { width: 160px; }
  .hx-steps { gap: 6px; }
  .hx-steps li { height: calc(66px + var(--i) * 22px); }
  .hx-pop__phone { width: min(200px, 60%); }
  .hx-sticker { right: -4px; max-width: 128px; font-size: .78rem; padding: 10px 12px; }
  .hx-candies { padding: 0 34px; }
  .hx-candybar { grid-template-columns: 64px minmax(0, 1fr) 18px; gap: 10px; padding: 10px 12px; }
  .hx-candybar__logo .hx-logo { max-width: 64px; max-height: 30px; }
  .hx-bigwrap { margin: 0 36px; padding: 16px 14px; }
  .hx-bigwrap__rows { grid-template-columns: 1fr; }
  .hx-bigwrap__game { width: 64px; height: 64px; }
  .sx-cards { grid-template-columns: 1fr; }
  .sx-card { grid-template-columns: 88px minmax(0, 1fr) 18px; gap: 12px; }
  .sx-card__media { height: 64px; }
}
@media (prefers-reduced-motion: reduce) {
  .hx .btn, .header-play__btn, .hx-coin, .hx-candybar, .sx-card, .hx-candy__key { transition: none; }
  .hx .btn:hover, .header-play__btn:hover, .hx-coin:hover, .hx-candybar:hover, .sx-card:hover { transform: none; }
  .hx-candy:hover .hx-candy__key { transform: rotate(4deg); }
}

/* ---------- Site logo (custom/logo-patch.js): candy mark + wordmark ---------- */
.logo { gap: 9px; }
.logo .logo__mark { width: 40px; height: 40px; border-radius: 0; filter: drop-shadow(0 3px 4px rgba(192, 23, 122, .25)); transition: transform .2s ease; }
.logo:hover .logo__mark { transform: rotate(-12deg) scale(1.06); }
.logo__word { display: inline-flex; align-items: center; gap: .28em; font-weight: 900; font-size: 1.22rem; line-height: 1; letter-spacing: -.035em; white-space: nowrap; }
.logo__sugar { color: #2b1238; }
.logo__rush { color: #c0177a; background: linear-gradient(92deg, #c0177a, #6a2fc4); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.logo__tag { margin-left: .1em; padding: .28em .55em .3em; border-radius: 999px; background: #ffd23f; color: #2b1238; font-size: .56em; letter-spacing: .02em; text-transform: lowercase;
  box-shadow: 0 2px 0 #c99100; transform: rotate(-6deg) translateY(-.25em); }
.logo:hover { text-decoration: none; }
.footer__brand .logo__word { font-size: 1.15rem; }
@media (max-width: 400px) {
  .logo .logo__mark { width: 34px; height: 34px; }
  .logo__word { font-size: 1.04rem; }
  .logo__tag { display: none; }
}
@media (prefers-reduced-motion: reduce) { .logo:hover .logo__mark { transform: none; } }
