/* ==========================================================================
   effects.css — overlays: tooltip, win callout, avatar, toast, rules sheet
   ========================================================================== */

#fxCv{position:fixed;inset:0;z-index:20;pointer-events:none;}

/* --------------------------- BET TOOLTIP -------------------------------- */
#tip{
  position:fixed;z-index:22;pointer-events:none;
  left:0;top:0;
  transform:translate(-50%,-105%) scale(.85);
  opacity:0;
  padding:8px 14px;border-radius:10px;
  background:rgba(5, 18, 12, 0.92);
  border:1.5px solid rgba(246,207,110,.7);
  backdrop-filter:blur(10px);
  -webkit-backdrop-filter:blur(10px);
  box-shadow:0 12px 28px rgba(0,0,0,.7), 0 0 16px rgba(246,207,110,.25);
  font-family:var(--font-ui);
  text-align:center;
  line-height:1.3;
  color:var(--cream);
  transition:opacity .18s ease, transform .24s var(--ease-pop);
}
#tip.on{opacity:1;transform:translate(-50%,-118%) scale(1);}
#tip .tip-bet{
  font-size:12px;font-weight:900;letter-spacing:.08em;
  color:var(--gold);
  text-transform:uppercase;
  margin-bottom:2px;
}
#tip .tip-name{
  font-family:var(--font-board);
  font-size:15px;font-weight:700;letter-spacing:.04em;
  color:#ffffff;
  text-shadow:0 1px 3px rgba(0,0,0,.6);
}
#tip .tip-pays{
  font-size:12px;font-weight:800;letter-spacing:.06em;
  color:#5ce49a;
  margin-top:2px;
}
#tip .tip-limits{
  font-size:10px;font-weight:700;letter-spacing:.04em;
  color:var(--cream-dim);
  margin-top:3px;
  border-top:1px solid rgba(255,255,255,.14);
  padding-top:3px;
}

/* --------------------------- WIN CALLOUT -------------------------------- */
#callout{
  position:absolute;left:50%;top:50%;z-index:21;
  pointer-events:none;text-align:center;line-height:1;
  transform:translate(-50%,-50%) scale(.4);opacity:0;
}
#callout .big{
  display:block;
  font-family:var(--font-board);font-weight:700;
  font-size:100px;letter-spacing:-.01em;
  background:linear-gradient(180deg,#fff8de,var(--gold) 46%,var(--gold-mid));
  -webkit-background-clip:text;background-clip:text;color:transparent;
  filter:drop-shadow(0 5px 0 rgba(0,0,0,.5)) drop-shadow(0 14px 26px rgba(0,0,0,.5));
}
#callout .amt{
  display:block;margin-top:12px;
  font-size:40px;font-weight:900;color:var(--cream);
  text-shadow:0 3px 10px rgba(0,0,0,.75);
}
#callout.show{animation:calloutIn 1.9s var(--ease-cam) forwards;}
@keyframes calloutIn{
  0%  {opacity:0;transform:translate(-50%,-50%) scale(.4)}
  18% {opacity:1;transform:translate(-50%,-50%) scale(1.12)}
  28% {transform:translate(-50%,-50%) scale(1)}
  76% {opacity:1;transform:translate(-50%,-58%) scale(1)}
  100%{opacity:0;transform:translate(-50%,-80%) scale(.9)}
}

/* ------------------------------ TOAST ----------------------------------- */
#toast{
  position:fixed;left:50%;bottom:calc(env(safe-area-inset-bottom) + 104px);
  z-index:24;pointer-events:none;
  transform:translate(-50%,10px);opacity:0;
  padding:8px 16px;border-radius:var(--r-pill);
  background:rgba(0,0,0,.76);
  border:1px solid rgba(255,255,255,.18);
  backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px);
  font-size:12px;font-weight:800;color:var(--cream);
  transition:opacity .2s ease, transform .2s ease;
}
#toast.on{opacity:1;transform:translate(-50%,0);}

/* --------------------------- RULES SHEET -------------------------------- */
#sheet{
  position:fixed;inset:0;z-index:9000;
  display:grid;place-items:center;
  padding:16px;
  background:rgba(0,4,2,.78);
  backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px);
  animation:fadeIn .2s ease;
  overflow-y:auto;
}
#sheet[hidden]{display:none;}
@keyframes fadeIn{from{opacity:0}to{opacity:1}}

.sheetCard.mathModal{
  width:100%;max-width:480px;
  max-height:90vh;
  display:flex;flex-direction:column;
  padding:0;border-radius:20px;
  background:linear-gradient(180deg, rgba(20,58,40,.98) 0%, rgba(6,28,18,.99) 100%);
  border:2px solid rgba(246,207,110,.4);
  box-shadow:0 24px 60px rgba(0,0,0,.85), 0 0 30px rgba(246,207,110,.12), inset 0 1px 0 rgba(255,255,255,.25);
  animation:sheetIn .28s cubic-bezier(.16,1,.3,1);
  overflow:hidden;
}
@keyframes sheetIn{from{transform:translateY(16px) scale(.95);opacity:0}to{transform:none;opacity:1}}

/* Header & Tabs */
.sheetHeader{
  display:flex;align-items:center;justify-content:space-between;
  padding:12px 16px;
  background:rgba(0,0,0,.45);
  border-bottom:1px solid rgba(255,255,255,.12);
}
.sheetTabs{
  display:flex;align-items:center;gap:6px;flex:1;
}
.sheetTab{
  display:flex;align-items:center;gap:6px;
  padding:8px 12px;border-radius:10px;
  background:transparent;
  border:1px solid transparent;
  color:rgba(255,255,255,.7);
  font-size:12px;font-weight:800;letter-spacing:.03em;
  cursor:pointer;transition:all .15s ease;
  white-space:nowrap;
}
.sheetTab i, .sheetTab svg{width:15px;height:15px;stroke-width:2.2;}
.sheetTab:hover{
  background:rgba(255,255,255,.08);
  color:#fff;
}
.sheetTab.active{
  background:linear-gradient(180deg, rgba(246,207,110,.25), rgba(246,207,110,.08));
  border-color:rgba(246,207,110,.6);
  color:var(--gold);
  box-shadow:0 2px 8px rgba(0,0,0,.4), inset 0 1px 0 rgba(255,255,255,.2);
}
.sheetCloseX{
  width:32px;height:32px;border-radius:50%;
  display:grid;place-items:center;
  background:rgba(255,255,255,.08);
  border:1px solid rgba(255,255,255,.15);
  color:rgba(255,255,255,.8);font-size:20px;line-height:1;
  cursor:pointer;transition:all .15s ease;
}
.sheetCloseX:hover{background:rgba(255,255,255,.2);color:#fff;}

/* Tab Panes */
.tabPane{
  padding:16px;overflow-y:auto;flex:1;
  display:flex;flex-direction:column;gap:14px;
}
.tabPane[hidden]{display:none !important;}

/* Hero RTP Banner */
.mathHeroBanner{
  display:flex;align-items:center;justify-content:space-between;
  padding:12px 14px;border-radius:12px;
  background:linear-gradient(135deg, rgba(31,168,100,.25), rgba(6,91,51,.35));
  border:1px solid rgba(92,228,154,.4);
}
.mathHeroRtp{display:flex;flex-direction:column;gap:2px;}
.mathHeroLbl{font-size:10px;font-weight:900;letter-spacing:.1em;color:#5ce49a;}
.mathHeroVal{font-family:var(--font-board);font-size:20px;font-weight:900;color:#fff;}
.mathHeroVal small{font-family:var(--font-ui);font-size:11px;font-weight:700;color:var(--cream-dim);margin-left:4px;}
.mathHeroTag{
  font-size:10px;font-weight:900;letter-spacing:.08em;
  padding:4px 8px;border-radius:6px;
  background:rgba(246,207,110,.2);border:1px solid rgba(246,207,110,.5);
  color:var(--gold);text-transform:uppercase;
}

/* Paytable */
.mathTableWrap{
  border-radius:12px;overflow:hidden;
  border:1px solid rgba(255,255,255,.14);
  background:rgba(0,0,0,.35);
}
.mathTable{
  width:100%;border-collapse:collapse;text-align:left;font-size:12px;
}
.mathTable th{
  padding:8px 10px;background:rgba(0,0,0,.5);
  color:rgba(255,255,255,.6);font-size:10px;font-weight:800;letter-spacing:.08em;
  text-transform:uppercase;border-bottom:1px solid rgba(255,255,255,.12);
}
.mathTable td{
  padding:8px 10px;border-bottom:1px solid rgba(255,255,255,.07);
  color:#ffffff;font-size:12px;
}
.mathTable tr:last-child td{border-bottom:0;}
.mathTable tr.highlightRow{background:rgba(31,168,100,.1);}
.goldPay{color:var(--gold);font-weight:800;}
.highRtp{color:#5ce49a;}

/* Notes */
.mathNotes{display:flex;flex-direction:column;gap:8px;}
.mathNoteItem{
  padding:10px 12px;border-radius:10px;
  background:rgba(0,0,0,.3);border:1px solid rgba(255,255,255,.08);
  font-size:11px;line-height:1.45;color:var(--cream-dim);
}
.mathNoteItem p{margin:4px 0 0;}
.noteBadge{
  font-size:9px;font-weight:900;letter-spacing:.1em;
  color:var(--gold);text-transform:uppercase;
}

/* Tab 2: Live RTP Grid */
.rtpGrid{
  display:grid;grid-template-columns:1fr 1fr;gap:10px;
}
.rtpCard{
  padding:10px 12px;border-radius:12px;
  background:rgba(0,0,0,.4);border:1px solid rgba(255,255,255,.12);
  display:flex;flex-direction:column;gap:3px;
}
.rtpCardLbl{font-size:9px;font-weight:900;letter-spacing:.08em;color:rgba(255,255,255,.6);text-transform:uppercase;}
.rtpCardVal{font-family:var(--font-board);font-size:22px;font-weight:900;color:#fff;}
.rtpCardVal.gold{color:var(--gold);}
.rtpCardVal.green{color:#5ce49a;}
.rtpCardSub{font-size:10px;font-weight:700;color:var(--cream-dim);}

/* Hit Rate Bar */
.hitRateBar{
  padding:10px 12px;border-radius:12px;
  background:rgba(0,0,0,.35);border:1px solid rgba(255,255,255,.1);
  display:flex;flex-direction:column;gap:6px;
}
.hitRateHeader{
  display:flex;justify-content:space-between;align-items:center;
  font-size:10px;font-weight:800;color:rgba(255,255,255,.7);letter-spacing:.08em;
}
.hitRateTrack{
  width:100%;height:8px;border-radius:4px;
  background:rgba(255,255,255,.12);overflow:hidden;
}
.hitRateFill{
  height:100%;background:linear-gradient(90deg, #1fa864, #5ce49a);
  border-radius:4px;transition:width .4s ease;
}

/* Hot / Cold Pockets */
.hotColdSection{
  display:grid;grid-template-columns:1fr 1fr;gap:10px;
}
.hotBox, .coldBox{
  padding:10px 12px;border-radius:12px;
  background:rgba(0,0,0,.35);border:1px solid rgba(255,255,255,.1);
  display:flex;flex-direction:column;gap:6px;
}
.hotTitle{
  display:flex;align-items:center;gap:4px;
  font-size:10px;font-weight:900;letter-spacing:.08em;color:#ff858e;
}
.hotTitle svg, .hotTitle i{width:13px;height:13px;}
.coldTitle{
  display:flex;align-items:center;gap:4px;
  font-size:10px;font-weight:900;letter-spacing:.08em;color:#85d2ff;
}
.coldTitle svg, .coldTitle i{width:13px;height:13px;}
.hotPocketsList, .coldPocketsList{
  display:flex;align-items:center;gap:6px;
}
.pocketBadge{
  width:26px;height:26px;border-radius:6px;
  display:grid;place-items:center;font-size:12px;font-weight:900;color:#fff;
  border:1px solid rgba(255,255,255,.3);
}
.pocketBadge.c-red{background:#e23a46;}
.pocketBadge.c-black{background:#2b3238;}
.pocketBadge.c-green{background:#1fa864;}
.pocketTag.none{font-size:11px;color:rgba(255,255,255,.4);}

.rtpActions{display:flex;justify-content:flex-end;}
.btnSecondary{
  padding:6px 12px;border-radius:8px;
  background:rgba(255,255,255,.08);border:1px solid rgba(255,255,255,.15);
  color:rgba(255,255,255,.8);font-size:11px;font-weight:800;cursor:pointer;
  transition:all .15s ease;
}
.btnSecondary:hover{background:rgba(255,255,255,.16);color:#fff;}

/* Tab 3: Provably Fair Form */
.pfInfoBox{
  padding:10px 12px;border-radius:10px;
  background:rgba(0,0,0,.35);border:1px solid rgba(255,255,255,.1);
  font-size:11px;line-height:1.45;color:var(--cream-dim);
}
.pfFormGroup{
  display:flex;flex-direction:column;gap:5px;
}
.pfFormGroup label{
  font-size:10px;font-weight:800;letter-spacing:.05em;color:rgba(255,255,255,.7);text-transform:uppercase;
}
.pfInputWrap, .pfInputGroup{
  display:flex;align-items:center;gap:6px;
}
.pfInput{
  width:100%;height:36px;padding:0 10px;border-radius:8px;
  background:rgba(0,0,0,.5);border:1px solid rgba(255,255,255,.18);
  color:#fff;font-size:11px;outline:none;
}
.pfInput.mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;}
.pfInput:focus{border-color:var(--gold);}
.pfBadge{
  padding:4px 8px;border-radius:6px;background:rgba(31,168,100,.3);
  border:1px solid #1fa864;color:#5ce49a;font-size:9px;font-weight:900;text-transform:uppercase;
  white-space:nowrap;
}
.pfBtn{
  height:36px;padding:0 12px;border-radius:8px;
  background:rgba(255,255,255,.1);border:1px solid rgba(255,255,255,.2);
  color:#fff;font-size:11px;font-weight:800;cursor:pointer;white-space:nowrap;
}
.pfBtn:hover{background:rgba(255,255,255,.18);}

/* Verifier Box */
.pfVerifierBox{
  padding:12px;border-radius:12px;
  background:rgba(0,0,0,.45);border:1px solid rgba(246,207,110,.3);
  display:flex;flex-direction:column;gap:8px;
}
.pfVerifierTitle{
  display:flex;align-items:center;gap:6px;
  font-size:11px;font-weight:900;letter-spacing:.08em;color:var(--gold);text-transform:uppercase;
}
.pfVerifierTitle svg, .pfVerifierTitle i{width:14px;height:14px;}
.pfVerifierGrid{
  display:flex;flex-wrap:wrap;gap:6px;
}
.vInput{flex:1;min-width:120px;}
.pfBtnPrimary{
  height:36px;padding:0 14px;border-radius:8px;
  background:linear-gradient(180deg,#3fcb86,#0d7d4c);
  border:none;color:#042a17;font-size:12px;font-weight:900;cursor:pointer;
}
.vResultBox{
  padding:8px 10px;border-radius:8px;
  background:rgba(20,58,40,.8);border:1px solid rgba(92,228,154,.4);
  display:flex;flex-direction:column;gap:4px;font-size:11px;
}
.vResultItem{display:flex;align-items:center;gap:8px;}
.vResultNum{font-family:var(--font-board);font-size:16px;color:#5ce49a;}
.vResultCode{
  font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;
  font-size:10px;color:rgba(255,255,255,.8);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
}

/* Modal Footer */
.sheetFooter{
  display:flex;align-items:center;gap:10px;
  padding:12px 16px;background:rgba(0,0,0,.45);
  border-top:1px solid rgba(255,255,255,.12);
}
.sheetFooterSound{
  flex:1;height:42px;border-radius:var(--r-pill);
  background:rgba(0,0,0,.45);border:1.5px solid rgba(255,255,255,.2);
  color:var(--cream);font-size:13px;font-weight:800;cursor:pointer;
}
.sheetFooterClose{
  flex:1;height:42px;border-radius:var(--r-pill);
  background:linear-gradient(180deg,#3fcb86,#0d7d4c);
  border:none;color:#042a17;font-size:14px;font-weight:900;letter-spacing:.05em;
  box-shadow:0 4px 0 rgba(3,52,31,.9), inset 0 2px 0 rgba(255,255,255,.45);
  cursor:pointer;
}

/* Upper HUD RTP Button */
.topHudRtpBtn{
  display:flex !important;flex-direction:column;align-items:center;justify-content:center;gap:2px;
  border-color:rgba(246,207,110,.5) !important;
}
.topHudRtpBtn .rtpTag{
  font-size:10px;font-weight:900;letter-spacing:.1em;
  color:var(--gold);line-height:1;text-shadow:0 1px 2px rgba(0,0,0,.8);
}
.topHudRtpBtn .rtpVal{
  font-family:var(--font-board);font-size:16px;font-weight:900;
  color:#ffffff;line-height:1;letter-spacing:.02em;
}
.topHudRtpBtn.hotRtp{
  border-color:rgba(92,228,154,.8) !important;
  background:linear-gradient(180deg, rgba(31,168,100,.9), rgba(6,91,51,.98)) !important;
}
.topHudRtpBtn.hotRtp .rtpVal{color:#5ce49a;}
.topHudRtpBtn.coldRtp{
  border-color:rgba(255,140,150,.6) !important;
}

/* ==================== AAA CASINO SPLASH SCREEN ==================== */
#splash{
  position:fixed;inset:0;z-index:9999;
  display:flex;align-items:center;justify-content:center;
  background:#020b06;
  transition:opacity .65s cubic-bezier(.4,0,.2,1), transform .65s cubic-bezier(.4,0,.2,1), visibility .65s;
  user-select:none;
}
#splash.splash-out{
  opacity:0;transform:scale(1.05);
  pointer-events:none;
  visibility:hidden;
}

.splash-bg{
  position:absolute;inset:0;overflow:hidden;
  background:
    radial-gradient(ellipse at 50% 36%, #0d4629 0%, #062315 45%, #020b06 85%),
    #020b06;
}
.splash-glow{
  position:absolute;left:50%;top:38%;transform:translate(-50%,-50%);
  width:540px;height:540px;
  background:radial-gradient(circle, rgba(246,207,110,.25) 0%, rgba(13,119,69,.18) 42%, transparent 72%);
  pointer-events:none;
  animation:pulseGlow 3.5s ease-in-out infinite alternate;
}
@keyframes pulseGlow{
  0%  {transform:translate(-50%,-50%) scale(.85);opacity:.75;}
  100%{transform:translate(-50%,-50%) scale(1.18);opacity:1;}
}
.splash-pattern{
  position:absolute;inset:0;opacity:.16;pointer-events:none;
  background-image:radial-gradient(rgba(246,207,110,.45) 1.2px, transparent 1.2px);
  background-size:22px 22px;
}

.splash-content{
  position:relative;z-index:2;
  display:flex;flex-direction:column;align-items:center;
  width:92%;max-width:390px;
  text-align:center;
  padding:20px 16px;
  animation:splashContentIn .6s cubic-bezier(.2,1.2,.4,1);
}
@keyframes splashContentIn{
  from{opacity:0;transform:scale(.9) translateY(15px);}
  to  {opacity:1;transform:none;}
}

.splash-wheel-container{
  position:relative;width:170px;height:170px;
  margin-bottom:20px;
  display:grid;place-items:center;
}
.splash-wheel-glow{
  position:absolute;inset:-18px;border-radius:50%;
  background:radial-gradient(circle, rgba(246,207,110,.42) 0%, rgba(13,119,69,.25) 45%, transparent 72%);
  animation:wheelGlowPulse 2.8s ease-in-out infinite alternate;
  pointer-events:none;
}
@keyframes wheelGlowPulse{
  0%  {transform:scale(.92);opacity:.65;}
  100%{transform:scale(1.15);opacity:1;}
}

.splash-wheel-svg{
  position:relative;z-index:2;
  width:170px;height:170px;
  border-radius:50%;
  box-shadow:0 14px 34px rgba(0,0,0,.85), 0 0 24px rgba(246,207,110,.35), inset 0 2px 6px rgba(255,255,255,.2);
  filter:drop-shadow(0 8px 18px rgba(0,0,0,.9));
}

/* Static Bowl */
.splash-wheel-bowl{
  transform-origin:100px 100px;
}

/* Spinning Rotor */
.splash-wheel-rotor{
  transform-origin:100px 100px;
  animation:spinSplashRotor 5.5s linear infinite;
}
@keyframes spinSplashRotor{
  from{transform:rotate(0deg);}
  to  {transform:rotate(360deg);}
}

/* Orbiting Ivory Ball in Opposite Direction */
.splash-wheel-ball-orbit{
  transform-origin:100px 100px;
  animation:orbitSplashBall 1.75s linear infinite;
}
@keyframes orbitSplashBall{
  from{transform:rotate(360deg);}
  to  {transform:rotate(0deg);}
}

.crest-stars{position:absolute;inset:-16px;pointer-events:none;}
.c-spark{
  position:absolute;color:var(--gold);font-size:16px;
  text-shadow:0 0 8px var(--gold);
  animation:sparkle 1.8s ease-in-out infinite alternate;
}
.c-spark.s1{top:4px;left:10px;animation-delay:0s;}
.c-spark.s2{top:8px;right:8px;animation-delay:.45s;}
.c-spark.s3{bottom:10px;left:12px;animation-delay:.9s;}
.c-spark.s4{bottom:6px;right:14px;animation-delay:1.35s;}
@keyframes sparkle{
  0%  {transform:scale(.7) rotate(0deg);opacity:.4;}
  100%{transform:scale(1.3) rotate(25deg);opacity:1;filter:drop-shadow(0 0 6px #fff);}
}

.splash-loader{
  width:100%;margin-top:20px;
}
.splash-bar-track{
  width:100%;height:12px;border-radius:999px;
  background:rgba(0,0,0,.8);
  border:1.5px solid rgba(246,207,110,.55);
  padding:2px;
  box-shadow:inset 0 2px 6px rgba(0,0,0,.85), 0 0 14px rgba(246,207,110,.2);
  overflow:hidden;
  position:relative;
}
.splash-bar-fill{
  height:100%;width:0%;border-radius:999px;
  background:linear-gradient(90deg, #d9a12a 0%, #f6cf6e 50%, #fffdf4 100%);
  box-shadow:0 0 12px rgba(246,207,110,.9);
  position:relative;
  transition:width .25s ease-out;
}
.splash-bar-glint{
  position:absolute;top:0;bottom:0;width:35px;
  background:linear-gradient(90deg, transparent, rgba(255,255,255,.85), transparent);
  animation:glintMove 1.5s infinite linear;
}
@keyframes glintMove{
  0%  {left:-40px;}
  100%{left:100%;}
}

.splash-status-row{
  display:flex;justify-content:space-between;align-items:center;
  margin-top:10px;padding:0 2px;
  font-size:11.5px;font-weight:800;letter-spacing:.04em;
  color:var(--cream-dim);
}
.splash-pct{
  font-family:var(--font-board);font-size:14px;font-weight:900;
  color:var(--gold);text-shadow:0 1px 4px rgba(0,0,0,.8);
}

/* ----------------- DESKTOP KEYBOARD SHORTCUTS ----------------- */
.shortcutsGrid{
  display:grid;grid-template-columns:1fr;gap:10px;
}
@media (min-width:480px){
  .shortcutsGrid{grid-template-columns:1fr 1fr;gap:12px;}
}
.shortcutItem{
  display:flex;align-items:center;gap:10px;
  background:rgba(0,0,0,.45);
  border:1px solid rgba(255,255,255,.12);
  border-radius:10px;padding:10px 14px;
}
.shortcutItem kbd{
  display:inline-block;padding:3px 8px;border-radius:6px;
  background:linear-gradient(180deg, #333a41, #16191c);
  border:1.5px solid rgba(246,207,110,.6);
  color:var(--gold);font-family:monospace;font-size:12px;font-weight:900;
  box-shadow:0 3px 0 rgba(0,0,0,.7), 0 0 6px rgba(246,207,110,.2);
  line-height:1;user-select:none;
}
.shortcutItem span{
  font-size:13px;font-weight:700;color:var(--cream);letter-spacing:.02em;
}

@media (prefers-reduced-motion:reduce){
  #callout.show,.chip,.chip.win,.cell.hot,.hchip,.sheetCard{animation-duration:1ms;}
}
