@font-face {
  font-family: OpenSans;
  src: url("assets/fonts/open-sans-800.ttf") format("truetype");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}
:root { color-scheme: dark; font-family: OpenSans, Arial, sans-serif; background: #080520; color: #fff; }
* { box-sizing: border-box; }
body { margin: 0; min-width: 280px; }
[hidden] { display: none !important; }
button { font: inherit; cursor: pointer; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid #ffffac; outline-offset: 4px; }
.game {
  position: relative; isolation: isolate; display: grid; place-items: center;
  min-height: 100svh; padding: 12px 14px 29px; overflow: hidden;
  background: #100d49 url("assets/images/page-bg.webp") center / cover;
}
.game-content { position: relative; z-index: 1; display: grid; justify-items: center; gap: 14px; width: 100%; }
.logo { position: relative; width: min(47vh, 360px, 58vw); line-height: 0; margin: 0 0 -2px; }
.logo img { display: block; width: 100%; height: auto; filter: drop-shadow(0 3px 7px #02021d90); }
.logo::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(110deg, transparent 30%, #ffffff99 48%, transparent 62%);
  mask-image: url("assets/images/logo.webp"); mask-size: 100% 100%;
  opacity: 0; animation: logo-shine 7s ease-in-out infinite;
}
@keyframes logo-shine { 5% { opacity: .75; } 13% { opacity: 0; } }
.board {
  position: relative; width: min(94vw, 98vh, 880px); aspect-ratio: 5 / 2.95;
  filter: drop-shadow(0 0 12px #fcce2980);
}
.board::after { content: ""; position: absolute; inset: 0; background: url("assets/images/frame.webp") center / 100% 100%; pointer-events: none; }
.reels {
  position: absolute; inset: 4% 4.6%; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr));
  background: linear-gradient(#1b1433, #201578 47%, #1a1331 86%);
}
.reel { position: relative; overflow: hidden; min-width: 0; }
.faces, .strip { position: absolute; inset: 0; display: grid; grid-template-rows: repeat(3, minmax(0, 1fr)); }
.symbol { display: grid; place-items: center; min-height: 0; padding: 3%; }
.symbol img { width: 87%; height: 87%; object-fit: contain; }
.strip { display: none; grid-template-rows: none; grid-auto-rows: 33.333333%; }
.reel.rolling .faces { visibility: hidden; }
.reel.rolling .strip { display: grid; animation: spin-strip .75s linear infinite; filter: blur(1px); }
.reel.anticipating { box-shadow: inset 0 0 20px #30abff, inset 0 0 3px 2px #e9faff; }
.reel.anticipating .strip { animation-duration: 1.05s; }
.reel.settled .faces { animation: land .24s ease-out; }
@keyframes spin-strip { to { transform: translateY(-300%); } }
@keyframes land { 40% { transform: translateY(4%); } }
.game[data-phase="won"] .symbol:nth-child(2) img { animation: winner-flip 1.2s ease-in-out infinite; }
@keyframes winner-flip { 50% { transform: perspective(500px) rotateY(25deg) scale(1.12); filter: drop-shadow(0 0 9px #ffe870); } }
.winning-line { position: absolute; left: 0; right: 0; top: 50%; height: 2px; opacity: 0; background: #ffe974; box-shadow: 0 0 10px 2px #ffc90c; pointer-events: none; }
.game[data-phase="won"] .winning-line { animation: line-flash .6s ease-out 2; }
.game[data-phase="final"] .logo, .game[data-phase="final"] .board, .game[data-phase="final"] .spin-controls { visibility: hidden; }
@keyframes line-flash { 40% { opacity: .8; } }
.spin-controls { display: grid; justify-items: center; gap: 8px; margin-top: 10px; }
.action {
  position: relative; z-index: 1; display: inline-flex; align-items: center; justify-content: center;
  min-width: 222px; max-width: 100%; min-height: 62px; padding: 10px 28px;
  border: 3px solid #ffdf29; border-radius: 15px; color: #fff;
  background: linear-gradient(#59bf4a, #019a2b 16%, #013d1d 46%, #00662b 77%, #038c22 89%, #ddab04 98%);
  box-shadow: inset 0 0 0 3px #063f20, 0 0 0 2px #c67d02, 0 0 13px #ffdb3d55;
  font-size: clamp(23px, 2.8vw, 32px); font-weight: 800; line-height: 1.16; text-transform: uppercase;
  text-shadow: 0 2px 2px #002b16, 2px 0 #002b16, -2px 0 #002b16;
  overflow-wrap: anywhere;
}
.action:disabled { cursor: default; opacity: .7; }
.action:not(:disabled) { animation: action-pulse 2.5s ease-in-out infinite; }
.action:not(:disabled):active { transform: scale(.97); }
@keyframes action-pulse { 50% { filter: brightness(1.12); } }
.status { margin: 0; min-height: 17px; text-align: center; font-size: 11px; color: #d5e3ff; text-shadow: 0 2px 3px #000; }
.sound-button {
  position: absolute; z-index: 4; top: max(12px, env(safe-area-inset-top)); right: max(14px, env(safe-area-inset-right));
  display: grid; place-items: center; width: 38px; height: 38px; padding: 7px;
  border: 1px solid #d6c89099; border-radius: 50%; background: #08072799; color: #ffde67;
}
.sound-button svg { width: 100%; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; stroke-linecap: round; }
#sound[aria-pressed="true"] .sound-off, #sound[aria-pressed="false"] .sound-on { display: none; }
footer { position: absolute; z-index: 1; left: 10px; right: 10px; bottom: max(7px, env(safe-area-inset-bottom)); color: #d8d9f6; text-align: center; font: 10px/1.3 Arial,sans-serif; }
.decorations { position: absolute; z-index: 0; left: max(0px, calc(50% - 650px)); bottom: 0; width: 400px; height: 100%; pointer-events: none; }
.deco { position: absolute; display: block; width: 93px; height: 93px; object-fit: contain; animation: decoration-float 5s ease-in-out infinite; }
.deco.coin { width: 175px; height: 175px; left: 112px; top: 40%; }
.coin img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.coin .spark { inset: -11%; width: 122%; height: 122%; mix-blend-mode: screen; animation: lightning 3s ease-in-out infinite; }
.deco.bar { left: 34px; top: 28%; transform: rotate(6deg); }
.deco.cherries { left: 101px; top: 13%; }
.deco.grapes { left: 267px; top: 58%; }
.deco.bell { left: 44px; top: 67%; width: 118px; height: 118px; }
.deco.seven { left: 183px; top: 72%; width: 105px; height: 105px; }
.deco.orange { left: 293px; top: 78%; }
.deco.lemon { left: 199px; top: 24%; }
.deco.plums { left: 246px; top: 85%; width: 73px; height: 73px; }
.deco.melon { left: 16px; top: 42%; }
@keyframes decoration-float { 50% { translate: 3px -6px; } }
.bolt { position: absolute; z-index: -1; background-position: center; background-repeat: no-repeat; background-size: contain; mix-blend-mode: screen; animation: lightning 4s linear infinite; }
.bolt-left { left: 25px; top: -6%; width: 235px; height: 75%; background-image: url("assets/images/lightning-up.webp"); }
.bolt-right { left: 95px; bottom: -4%; width: 320px; height: 80%; background-image: url("assets/images/lightning-down.webp"); }
.background-light { position: absolute; z-index: 0; right: -2%; bottom: -10%; width: 48%; height: 112%; background: url("assets/images/left-person-effect.webp") center / contain no-repeat; mix-blend-mode: screen; animation: lightning 4s ease-in-out infinite; }
@keyframes lightning { 0%, 42%, 48%, 57%, 100% { opacity: 1; } 46%, 55% { opacity: .2; } 50% { opacity: .7; } }
#coins { position: absolute; z-index: 3; inset: 0; overflow: hidden; pointer-events: none; }
.rain-coin { position: absolute; top: -40px; width: var(--size); aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #fff9a8, #ffcd13 43%, #9a4300 90%); box-shadow: inset 0 0 0 2px #f9d25e; animation: coin-fall var(--duration) linear forwards; }
@keyframes coin-fall { to { transform: translate(35px, 112vh) rotate(520deg); } }
.offer {
  position: fixed; inset: 0; margin: auto; width: min(100%, 740px); max-width: 100%; max-height: calc(100dvh - 24px);
  padding: 18px 15px 20px; border: 0; background: none; color: white; text-align: center; overflow-x: hidden;
}
.offer::backdrop { background: #01000ac9; }
.offer-glow { position: absolute; z-index: -1; inset: 0; background: url("assets/images/flare-3.webp") center / 100% 100% no-repeat; mix-blend-mode: screen; }
.offer-content { position: relative; display: grid; gap: 11px; justify-items: center; }
.offer-logo { width: min(54vw, 340px); height: auto; }
.offer h2 { margin: 2px 0 0; max-width: 100%; font-size: clamp(20px, 3.3vw, 28px); line-height: 1.18; text-transform: uppercase; text-shadow: 0 0 3px #0067ff, 1px 1px #0067ff, -1px -1px #0067ff; overflow-wrap: anywhere; }
.offer-label { margin: 0; max-width: 550px; font-size: clamp(13px, 2vw, 16px); line-height: 1.5; color: #f2f2ff; }
.offer-amount { display: block; max-width: 100%; font-size: clamp(33px, 8vw, 61px); line-height: 1.15; color: #ffe84d; text-shadow: 0 3px #a15d0b, 0 0 12px #007bff; overflow-wrap: anywhere; }
.offer-amount.with-bonus { font-size: clamp(28px, 7vw, 54px); text-transform: uppercase; text-align: center; }
.offer-amount.with-bonus span { white-space: nowrap; }
.offer-extra { margin: 0 0 7px; font-size: clamp(13px, 2vw, 17px); line-height: 1.4; }
.offer-extra b { color: #ffed7b; }
[data-pwa-help], [data-pwa-inapp] { margin: 0; max-width: 440px; font: 14px/1.4 Arial,sans-serif; color: #fffbd2; }
@media (max-width: 991px) {
  .game { padding: 36px 12px 32px; background-image: url("assets/images/page-bg-mobile.webp"); }
  .game-content { gap: clamp(14px, 3.4vh, 33px); }
  .logo { width: min(86vw, 330px, 45svh); }
  .board { width: min(90vw, 54svh, 470px); aspect-ratio: 1; }
  .board::after { background-image: url("assets/images/frame-mobile.webp"); }
  .reels { inset: 1.3% 1.8%; grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .reel:nth-child(n+4) { display: none; }
  .spin-controls { margin-top: 3px; }
  .action { min-height: 57px; min-width: min(230px, 76vw); font-size: clamp(20px, 6vw, 27px); }
  .decorations { left: calc(50% - 230px); width: 290px; height: 54%; opacity: .9; }
  .deco { width: 65px; height: 65px; }
  .deco.coin { width: 105px; height: 105px; left: 91px; top: 42%; }
  .deco.bar { left: 23px; top: 21%; }
  .deco.cherries { left: 79px; top: 7%; }
  .deco.grapes { left: 184px; top: 53%; }
  .deco.bell { left: 35px; top: 62%; width: 77px; height: 77px; }
  .deco.seven { left: 139px; top: 67%; width: 70px; height: 70px; }
  .deco.orange { left: 216px; top: 76%; }
  .deco.lemon { left: 159px; top: 22%; }
  .deco.plums { left: 177px; top: 82%; width: 48px; height: 48px; }
  .deco.melon { left: 13px; top: 41%; }
  .bolt-left { width: 180px; left: 20px; }
  .bolt-right { width: 220px; left: 64px; }
  .background-light { right: -10%; width: 64%; bottom: -17%; }
  .sound-button { top: 10px; right: 10px; width: 33px; height: 33px; }
}
@media (max-height: 510px) and (min-width: 700px) {
  .game-content { gap: 7px; }
  .logo { width: min(30vh, 220px); }
  .board { width: min(74vh, 470px); aspect-ratio: 5 / 3; }
  .reels { inset: 4% 4.6%; grid-template-columns: repeat(5,minmax(0,1fr)); }
  .reel:nth-child(n+4) { display: block; }
  .board::after { background-image: url("assets/images/frame.webp"); }
  .action { min-height: 41px; font-size: 20px; }
  .spin-controls { margin-top: 0; }
  .status { font-size: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

