/* COLOSSUS — layout, HUD, login, pots, jackpots, buttons */
:root {
  --gold: #f6c453;
  --gold-dark: #a8741a;
  --stone: #2a2620;
  --ink: #f5ecd8;
  --muted: #b9ab8f;
  --fire: #ff6a2b;
  --water: #3aa8ff;
  --earth: #6fbf4a;
  --air: #d8f4ff;
  --cell: 140px;
  --rows: 4;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: #0b0907; color: var(--ink); font-family: Georgia, 'Times New Roman', serif; overflow: hidden; user-select: none; -webkit-user-select: none; }
#bg { position: fixed; inset: 0; background: #0b0907 url('../assets/backgrounds/temple.svg') center / cover no-repeat; }
.hidden { display: none !important; }
.screen { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; }

/* ---- buttons ---- */
.btn { font-family: inherit; font-weight: bold; color: #2b1a04; background: linear-gradient(#ffe29a, #f0b440 55%, #b77a18); border: 2px solid #5a3a08; border-radius: 10px; padding: 8px 14px; cursor: pointer; box-shadow: 0 3px 0 #4a2f06, 0 0 12px rgba(246,196,83,.25); }
.btn:active { transform: translateY(2px); box-shadow: 0 1px 0 #4a2f06; }
.btn:disabled { filter: grayscale(.8) brightness(.7); cursor: default; }
.btn-gold { font-size: 20px; padding: 10px 24px; }
.btn-round { width: 42px; height: 42px; border-radius: 50%; padding: 0; font-size: 24px; line-height: 1; }
.btn-small { font-size: 15px; padding: 7px 11px; min-width: 42px; }
.btn.on { background: linear-gradient(#bff7ff, #47c6ff 55%, #1872a8); }
.btn-dev { background: linear-gradient(#e7d0ff, #a46cf0 55%, #5a2aa8); color: #fff; border-color: #2d0f5e; }

/* ---- login ---- */
.login-card { width: 360px; max-width: calc(100vw - 32px); padding: 28px; background: rgba(20,16,12,.92); border: 2px solid var(--gold-dark); border-radius: 18px; display: flex; flex-direction: column; gap: 14px; box-shadow: 0 0 60px rgba(0,0,0,.8); position: relative; }
.login-logo { width: 100%; }
.login-card label { display: flex; flex-direction: column; gap: 6px; color: var(--muted); font-size: 14px; }
.login-card input { font: inherit; font-size: 17px; padding: 10px; border-radius: 8px; border: 1px solid #5a4a30; background: #120f0b; color: var(--ink); }
.login-error { color: #ff8a7a; min-height: 18px; font-size: 14px; }
.login-note { color: var(--muted); font-size: 12px; margin: 0; text-align: center; }

/* ---- stage (fixed design size, scaled by stage.js) ---- */
#stage { position: absolute; left: 50%; top: 50%; width: 1280px; height: 900px; transform-origin: center center; }
.top { height: 120px; display: flex; align-items: center; justify-content: space-between; padding: 0 30px; }
.logo { height: 100px; }
.jackpots { display: flex; gap: 10px; }
.plaque { position: relative; width: 210px; height: 63px; }
.plaque img { width: 100%; height: 100%; display: block; }
.plaque .amt { position: absolute; left: 50%; right: 4.5%; top: 18%; bottom: 20%; display: flex; align-items: center; justify-content: center; font-size: 22px; font-weight: bold; color: #fff3c8; text-shadow: 0 0 6px rgba(255,200,80,.8); }
.plaque.hit { animation: plaqueHit .4s ease-in-out 6 alternate; }
@keyframes plaqueHit { to { transform: scale(1.12); filter: brightness(1.6); } }

.middle { height: 660px; display: flex; align-items: flex-start; justify-content: center; gap: 18px; }
.machine { position: relative; display: flex; flex-direction: column; align-items: center; }
.pots-col { width: 190px; display: flex; flex-direction: column; gap: 26px; padding-top: 30px; }

/* ---- pots ---- */
.pot { position: relative; width: 170px; height: 204px; margin: 0 auto; }
.pot .liquid-wrap { position: absolute; left: 25%; right: 25%; top: 37.5%; bottom: 16.7%; border-radius: 12px; overflow: hidden; background: rgba(0,0,0,.55); }
.pot .liquid { position: absolute; left: 0; right: 0; bottom: 0; height: 0%; transition: height .6s cubic-bezier(.3,1.4,.5,1); }
.pot.fire  .liquid { background: linear-gradient(#ffd36b, #ff6a2b 50%, #a3200b); box-shadow: 0 0 20px #ff6a2b; }
.pot.water .liquid { background: linear-gradient(#b5ecff, #3aa8ff 50%, #0d3f8f); box-shadow: 0 0 20px #3aa8ff; }
.pot.earth .liquid { background: linear-gradient(#c9f28e, #6fbf4a 50%, #2f5a1a); box-shadow: 0 0 20px #6fbf4a; }
.pot.air   .liquid { background: linear-gradient(#ffffff, #bdefff 50%, #6aa9c4); box-shadow: 0 0 20px #d8f4ff; }
.pot .liquid::after { content: ''; position: absolute; left: -20%; right: -20%; top: -6px; height: 12px; border-radius: 50%; background: rgba(255,255,255,.35); animation: slosh 2.4s ease-in-out infinite; }
@keyframes slosh { 50% { transform: translateX(8%) scaleY(.6); } }
.pot img { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.pot .count { position: absolute; left: 0; right: 0; bottom: -24px; text-align: center; font-size: 15px; color: var(--muted); }
.pot.glow { animation: potGlow 1.2s ease-in-out infinite alternate; }
.pot.fire.glow { --g: var(--fire); } .pot.water.glow { --g: var(--water); } .pot.earth.glow { --g: var(--earth); } .pot.air.glow { --g: var(--air); }
@keyframes potGlow { from { filter: drop-shadow(0 0 4px var(--g)); } to { filter: drop-shadow(0 0 22px var(--g)) brightness(1.2); } }
.pot.pop { animation: potPop .9s ease-out; }
@keyframes potPop { 0% { transform: scale(1); } 30% { transform: scale(1.3) rotate(-4deg); filter: brightness(2.2); } 60% { transform: scale(.95) rotate(3deg); } 100% { transform: scale(1); } }
.pot .gain { position: absolute; left: 50%; top: 30%; transform: translateX(-50%); font-weight: bold; font-size: 22px; color: #fff; text-shadow: 0 0 8px #000; animation: gainUp 1s ease-out forwards; pointer-events: none; }
@keyframes gainUp { to { transform: translate(-50%, -60px); opacity: 0; } }

/* ---- HUD ---- */
.hud { position: absolute; left: 0; right: 0; bottom: 0; height: 120px; display: flex; align-items: center; justify-content: center; gap: 16px; padding: 0 30px; background: linear-gradient(rgba(0,0,0,0), rgba(0,0,0,.75) 35%); }
.hud-box { min-width: 170px; padding: 8px 16px; background: rgba(18,14,10,.88); border: 2px solid var(--gold-dark); border-radius: 12px; display: flex; flex-direction: column; align-items: center; }
.hud-box .lbl { font-size: 13px; color: var(--muted); text-transform: uppercase; letter-spacing: 2px; }
.hud-box .num { font-size: 28px; font-weight: bold; color: var(--gold); }
.bet-ctl { display: flex; align-items: center; gap: 12px; }
.win-box { min-width: 220px; }
.win-box.big .num { animation: winPulse .5s ease-in-out infinite alternate; }
@keyframes winPulse { to { transform: scale(1.15); color: #fff; } }
.hud-actions { display: flex; gap: 8px; }
.spin-btn { width: 130px; height: 130px; border-radius: 50%; font-size: 30px; margin-top: -40px; background: radial-gradient(circle at 40% 35%, #fff3c0, #f6c453 40%, #b0700f 80%); box-shadow: 0 6px 0 #4a2f06, 0 0 30px rgba(246,196,83,.6); }
.spin-btn.stop { background: radial-gradient(circle at 40% 35%, #ffd0c0, #ff6a4a 40%, #a0200f 80%); }

.message { position: absolute; left: 50%; top: 46%; transform: translate(-50%, -50%); padding: 14px 26px; background: rgba(0,0,0,.85); border: 2px solid var(--gold); border-radius: 12px; font-size: 22px; z-index: 50; }
.banner { position: absolute; left: 50%; top: 40%; transform: translate(-50%, -50%); z-index: 60; text-align: center; pointer-events: none; }
.banner img { width: 760px; animation: bannerIn .6s cubic-bezier(.2,1.6,.4,1); }
.banner .sub { font-size: 34px; font-weight: bold; color: #fff; text-shadow: 0 0 12px #000, 0 0 24px var(--gold); margin-top: 6px; }
.banner .big { font-size: 90px; font-weight: bold; color: var(--gold); text-shadow: 0 0 18px #000, 0 0 40px #ff9a2b; animation: bannerIn .6s cubic-bezier(.2,1.6,.4,1); }
@keyframes bannerIn { from { transform: scale(.2); opacity: 0; } }

/* modal (paytable etc.) */
.modal-back { position: fixed; inset: 0; background: rgba(0,0,0,.7); z-index: 1000; display: flex; align-items: center; justify-content: center; }
.modal { background: #15110c; border: 2px solid var(--gold-dark); border-radius: 14px; padding: 20px; max-width: min(900px, calc(100vw - 32px)); max-height: calc(100vh - 32px); overflow: auto; }
.modal h2 { margin: 0 0 12px; color: var(--gold); }
.pay-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.pay-item { display: flex; gap: 10px; align-items: center; background: #1d1811; border-radius: 10px; padding: 8px; }
.pay-item img { width: 64px; height: 64px; }
.pay-item div { font-size: 14px; line-height: 1.5; }
.modal p { color: var(--muted); line-height: 1.5; }
