/* ============================================================
 * sneaky-arcade.css — Sneaky Arcade page (/sneaky-arcade)
 * Phase 1: hero + free Daily Spin + coming-soon teasers.
 * ============================================================ */

.mm-arcade-hero { text-align: center; margin: 0 auto 20px; max-width: 680px; }
.mm-arcade-title { font-size: 2rem; margin: 0 0 6px; }
.mm-arcade-subtitle { color: var(--mm-text-muted, #9aa3c0); margin: 0 0 16px; }

/* Token balance pill (shared look with the rewards shop) */
.mm-arcade-balance {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 8px 18px; border-radius: 999px;
    background: linear-gradient(135deg, rgba(246, 201, 74, .16), rgba(246, 201, 74, .05));
    border: 1px solid rgba(246, 201, 74, .35);
    font-weight: 700; color: #f6c94a;
}
.mm-arcade-balance-num { font-size: 1.15rem; }
.mm-token-dot {
    width: 14px; height: 14px; border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, #ffe39a, #e0a92a);
    box-shadow: 0 0 8px rgba(246, 201, 74, .6);
}
.mm-arcade-guestnote { text-align: center; color: var(--mm-text-muted, #9aa3c0); }

.mm-arcade-section-title {
    font-size: 1.15rem; margin: 32px 0 12px; padding-bottom: 6px;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
}

/* ── Daily Spin card ── */
.mm-spin-card {
    max-width: 460px; margin: 0 auto;
    text-align: center;
    background: linear-gradient(180deg, rgba(255, 255, 255, .05), rgba(255, 255, 255, .02));
    border: 1px solid rgba(246, 201, 74, .25);
    border-radius: 18px;
    padding: 22px 22px 20px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, .35);
}
.mm-spin-head { display: flex; align-items: center; justify-content: center; gap: 10px; margin-bottom: 14px; }
.mm-arcade-game-title { font-size: 1.3rem; margin: 0; }
.mm-spin-free {
    font-size: .68rem; font-weight: 800; letter-spacing: .04em;
    padding: 2px 8px; border-radius: 999px;
    background: rgba(150, 255, 40, .14); border: 1px solid rgba(150, 255, 40, .4); color: #cdebac;
}

/* The reel — big number that cycles then lands */
.mm-spin-reel {
    display: flex; align-items: center; justify-content: center;
    height: 120px; margin: 6px auto 10px; max-width: 240px;
    border-radius: 14px;
    background:
        radial-gradient(120% 80% at 50% 15%, rgba(246, 201, 74, .2), rgba(255, 255, 255, 0) 60%),
        linear-gradient(180deg, rgba(0, 0, 0, .25), rgba(0, 0, 0, .4));
    border: 1px solid rgba(246, 201, 74, .3);
    overflow: hidden;
}
.mm-spin-reel-num {
    font-size: 3.2rem; font-weight: 900; color: #f6c94a;
    text-shadow: 0 0 14px rgba(246, 201, 74, .5);
    font-variant-numeric: tabular-nums;
}
.mm-spin-reel-num.mm-spin-spinning { animation: mm-spin-blur .25s linear infinite; }
@keyframes mm-spin-blur { 0%,100% { opacity: 1; } 50% { opacity: .55; } }
.mm-spin-reel-num.mm-spin-win { animation: mm-spin-pop .6s ease; }
@keyframes mm-spin-pop {
    0% { transform: scale(.6); } 55% { transform: scale(1.25); } 100% { transform: scale(1); }
}

.mm-spin-odds { font-size: .8rem; color: var(--mm-text-muted, #9aa3c0); margin: 0 0 16px; }
.mm-spin-odds strong { color: #f6c94a; }

.mm-arcade-btn {
    display: inline-block; width: 100%;
    padding: 12px 16px; border-radius: 12px;
    border: 1px solid transparent; font-weight: 800; font-size: 1rem;
    cursor: pointer; text-decoration: none;
    transition: filter .15s ease, transform .15s ease, opacity .15s ease;
}
.mm-arcade-btn-go { background: linear-gradient(135deg, #f6c94a, #e0a92a); color: #1a1726; }
.mm-arcade-btn-go:hover:not([disabled]) { filter: brightness(1.06); transform: translateY(-1px); }
.mm-arcade-btn[disabled] { opacity: .55; cursor: not-allowed; }

.mm-spin-status { min-height: 1.4em; margin-top: 12px; font-size: .9rem; color: #dff7c8; }
.mm-spin-status strong { color: #f6c94a; font-size: 1.05em; }

/* ── Coming soon ── */
.mm-arcade-soon-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 14px;
}
.mm-arcade-soon {
    display: flex; align-items: center; gap: 10px;
    padding: 16px; border-radius: 12px;
    background: rgba(255, 255, 255, .03);
    border: 1px dashed rgba(255, 255, 255, .14);
    color: var(--mm-text-muted, #9aa3c0); font-weight: 600;
}
.mm-arcade-soon-icon { font-size: 1.5rem; filter: grayscale(.3); }

/* ============================================================
 * Arcade scene background — placeholder gradient now. Drop in art with:
 *   body.mm-arcade-page { background-image: url(/imgs/arcade/bg-desktop.jpg); }
 *   @media (max-width:640px){ ...bg-mobile.jpg }  (background-size:cover; etc.)
 * ============================================================ */
body.mm-arcade-page .mm-arcade-scene {
    background-image:
        linear-gradient(rgba(18, 14, 30, .58), rgba(18, 14, 30, .80)),
        url(/imgs/arcade/bg-desktop.jpg);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding-top: 0;   /* trim the big default section padding so the sign sits higher */
}
@media (max-width: 640px) {
    body.mm-arcade-page .mm-arcade-scene {
        background-image:
            linear-gradient(rgba(18, 14, 30, .55), rgba(18, 14, 30, .80)),
            url(/imgs/arcade/bg-mobile.jpg);
    }
}

/* Marquee title banner */
.mm-arcade-marquee {
    position: relative;
    width: 280px; max-width: 72vw;
    margin: -16px auto 6px;   /* tuck the chains up near the nav */
}
.mm-arcade-marquee img {
    width: 100%; height: auto; display: block;
    filter: drop-shadow(0 6px 18px rgba(0, 0, 0, .5));
}
.mm-arcade-marquee .mm-arcade-title {
    /* 72% = vertical center of the banner window (measured from the art) */
    position: absolute; top: 72%; left: 50%;
    transform: translate(-50%, -50%);
    margin: 0; width: 72%; text-align: center;
    font-size: clamp(1rem, 3.8vw, 1.4rem); line-height: 1.05;
    color: #fff;
    text-shadow: 0 0 10px rgba(95, 224, 255, .75), 0 2px 4px rgba(0, 0, 0, .65);
}

/* ============================================================
 * Spinning wheel — canvas face + code-drawn bezel/pointer/hub placeholders.
 * To use generated art, hide the placeholders and position <img> overlays:
 *   .mm-wheel-pointer / .mm-wheel-hub  -> set background-image, or swap to <img>
 *   add a .mm-wheel-bezel <img> ring over .mm-wheel-canvas (transparent center)
 * ============================================================ */
.mm-wheel-wrap {
    position: relative;
    width: 360px; max-width: 86vw;
    aspect-ratio: 1 / 1;
    margin: 34px auto 16px;   /* clearance so the pointer clears the title + pill */
}
/* The rotating wheel face sits INSIDE the bezel ring (tune % to the art). */
.mm-wheel-canvas {
    position: absolute; top: 50%; left: 50%;
    width: 79%; height: 79%;
    transform: translate(-50%, -50%);
    display: block;
    border-radius: 50%;
    background: #221a3a;
    z-index: 1;
    transition: filter .2s ease;
}
.mm-wheel-bezel {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    z-index: 2; pointer-events: none;
    filter: drop-shadow(0 8px 26px rgba(0, 0, 0, .55));
}
.mm-wheel-hub {
    position: absolute; top: 50%; left: 50%;
    width: 17%; height: auto;
    transform: translate(-50%, -50%);
    z-index: 3; pointer-events: none;
    filter: drop-shadow(0 2px 5px rgba(0, 0, 0, .5));
}
.mm-wheel-pointer {
    position: absolute; top: -5%; left: 50%;
    width: 14%; height: auto;
    transform: translateX(-50%);
    z-index: 4; pointer-events: none;
    filter: drop-shadow(0 4px 5px rgba(0, 0, 0, .5));
}
.mm-wheel-wrap.mm-wheel-won .mm-wheel-canvas { filter: brightness(1.12) drop-shadow(0 0 18px rgba(246, 201, 74, .8)); }

/* Confetti burst on a win */
.mm-confetti {
    position: absolute; top: 8%; left: 50%;
    width: 9px; height: 14px; border-radius: 2px;
    pointer-events: none; z-index: 5;
    animation: mm-confetti-fall 1.5s cubic-bezier(.3, .6, .4, 1) forwards;
}
@keyframes mm-confetti-fall {
    0%   { opacity: 1; transform: translateY(0) rotate(0deg); }
    100% { opacity: 0; transform: translateY(220px) rotate(540deg); }
}
@media (prefers-reduced-motion: reduce) {
    .mm-confetti { display: none; }
}

/* ============================================================
 * Guess the Word — Wordle-style game card.
 * Tiles + keyboard are pure CSS (crisp letters). Header icon is an <img>
 * (/imgs/arcade/game-word.png, hidden via onerror if the art is missing).
 * The ornate frame is an absolutely-positioned OVERLAY drawn ON TOP of the card
 * (border-image 9-slice @86px, rendered 26px thick; pointer-events:none so the
 * board/keyboard underneath stay clickable). The dark card bg is rounded so its
 * corners tuck under the frame. If panel-frame.png is missing, the overlay just
 * shows nothing and the card stays a clean rounded dark panel.
 * ============================================================ */
/* The ornate frame is a CONSTANT-thickness border-image (asymmetric slice so the
 * corner gems render full, not the thin stretched look). border-image lives in the
 * border box, so content (in the padding box) is ALWAYS inside the frame — the
 * title/button can never be covered, at any card height. background-clip:padding-box
 * keeps the dark fill inside the frame (no slab behind it). */
.mm-word-card {
    box-sizing: border-box;
    position: relative;
    max-width: 460px; margin: 18px auto 0;
    background: linear-gradient(180deg, rgba(30, 22, 52, .98), rgba(16, 11, 28, 1));
    background-clip: padding-box;
    border-style: solid; border-color: transparent;
    border-width: 42px 34px;
    border-image: url(/imgs/arcade/panel-frame.png?v=1) 138 118 / 42px 34px stretch;
    padding: 10px 8px 12px;
    box-shadow: 0 14px 40px rgba(0, 0, 0, .5);
    text-align: center;
}
.mm-word-frame { display: none; } /* superseded by the card border-image */
.mm-word-inner { margin: 0; padding: 0; }
@media (max-width: 480px) {
    .mm-word-card { border-width: 30px 22px; border-image-width: 30px 22px; padding: 8px 6px 10px; }
}

/* Back link + centered balance on the game page */
.mm-arcade-back { max-width: 700px; margin: 0 auto 6px; }
.mm-arcade-back a { color: var(--mm-text-muted, #9aa3c0); text-decoration: none; font-weight: 600; }
.mm-arcade-back a:hover { color: #f6c94a; }
.mm-arcade-balance-wrap { display: flex; justify-content: center; margin: 6px 0 14px; }

/* Play / Play-again button under the board */
.mm-word-play { margin-top: 14px; }

/* ── Token games grid (hub) ── */
.mm-arcade-games-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px; max-width: 700px; margin: 0 auto;
}
.mm-arcade-tile {
    display: flex; flex-direction: column; align-items: center; text-align: center;
    gap: 6px; padding: 22px 16px 18px; border-radius: 16px;
    background: linear-gradient(180deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .02));
    border: 1px solid rgba(246, 201, 74, .3);
    color: #fff; text-decoration: none;
    transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
a.mm-arcade-tile:hover { transform: translateY(-3px); box-shadow: 0 10px 28px rgba(0, 0, 0, .4); border-color: rgba(246, 201, 74, .6); }
.mm-arcade-tile-icon { width: 72px; height: 72px; object-fit: contain; filter: drop-shadow(0 4px 8px rgba(0, 0, 0, .4)); }
.mm-arcade-tile-title { font-weight: 800; font-size: 1.05rem; }
.mm-arcade-tile-meta { font-size: .78rem; color: var(--mm-text-muted, #9aa3c0); }
.mm-arcade-tile-go {
    margin-top: 6px; font-weight: 800; font-size: .85rem; color: #1a1726;
    background: linear-gradient(135deg, #f6c94a, #e0a92a); padding: 6px 16px; border-radius: 999px;
}
.mm-arcade-tile-soon { opacity: .6; border-style: dashed; border-color: rgba(255, 255, 255, .14); }
.mm-arcade-tile-soon .mm-arcade-soon-icon { font-size: 2.6rem; filter: grayscale(.3); }
.mm-word-head { display: flex; align-items: center; gap: 12px; justify-content: center; margin-bottom: 14px; text-align: left; }
.mm-word-icon { width: 46px; height: 46px; object-fit: contain; flex: 0 0 auto; filter: drop-shadow(0 3px 6px rgba(0, 0, 0, .4)); }
.mm-word-head-text { display: flex; flex-direction: column; gap: 2px; }
.mm-word-meta { font-size: .74rem; color: var(--mm-text-muted, #9aa3c0); }
.mm-word-meta strong { color: #f6c94a; }

/* Board */
.mm-word-board { display: flex; flex-direction: column; gap: 6px; align-items: center; margin: 6px 0 12px; }
.mm-word-row { display: flex; gap: 6px; }
.mm-word-tile {
    width: 48px; height: 48px; border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.5rem; font-weight: 800; text-transform: uppercase; color: #fff;
    background: rgba(255, 255, 255, .04);
    border: 2px solid rgba(255, 255, 255, .14);
    transition: border-color .12s ease, transform .08s ease;
}
.mm-word-tile.mm-tile-filled { border-color: rgba(246, 201, 74, .5); }
.mm-word-tile.mm-tile-active { animation: mm-tile-pop .12s ease; }
@keyframes mm-tile-pop { 0% { transform: scale(.85); } 100% { transform: scale(1); } }

.mm-tile-correct { background: #2fb96a !important; border-color: #2fb96a !important; color: #10231a !important; box-shadow: 0 0 10px rgba(47, 185, 106, .5); }
.mm-tile-present { background: #e0a92a !important; border-color: #e0a92a !important; color: #241a07 !important; }
.mm-tile-absent  { background: rgba(40, 36, 58, .92) !important; border-color: rgba(255, 255, 255, .07) !important; color: #8b90a8 !important; }

.mm-tile-reveal { animation: mm-tile-flip .5s ease forwards; }
@keyframes mm-tile-flip {
    0%   { transform: rotateX(0); }
    50%  { transform: rotateX(90deg); }
    100% { transform: rotateX(0); }
}

.mm-word-shake { animation: mm-word-shake .4s ease; }
@keyframes mm-word-shake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-6px); } 40% { transform: translateX(6px); }
    60% { transform: translateX(-4px); } 80% { transform: translateX(4px); }
}

/* Status line */
.mm-word-status { min-height: 1.4em; font-size: .9rem; color: var(--mm-text-muted, #9aa3c0); margin-bottom: 10px; }
.mm-word-status strong { color: #f6c94a; }
.mm-word-status.mm-word-won { color: #bff0cf; }
.mm-word-status.mm-word-won strong { color: #56e08a; }
.mm-word-status.mm-word-lost { color: #f3c0c0; }
.mm-word-status.mm-word-lost strong { color: #ffd76a; }

/* On-screen keyboard */
.mm-word-keyboard { display: flex; flex-direction: column; gap: 6px; align-items: center; margin: 6px auto 0; max-width: 340px; }
.mm-key-row { display: flex; gap: 5px; justify-content: center; width: 100%; }
.mm-key {
    min-width: 28px; height: 46px; padding: 0 6px;
    border-radius: 7px; border: 1px solid rgba(255, 255, 255, .12);
    background: rgba(255, 255, 255, .07); color: #fff;
    font-weight: 700; font-size: .9rem; cursor: pointer; flex: 1 1 0;
    transition: filter .12s ease, transform .08s ease, background .15s ease;
}
.mm-key:hover { filter: brightness(1.15); }
.mm-key:active { transform: translateY(1px); }
.mm-key-wide { flex: 1.6 1 0; font-size: .74rem; min-width: 48px; }
.mm-key-correct { background: #2fb96a; border-color: #2fb96a; color: #10231a; }
.mm-key-present { background: #e0a92a; border-color: #e0a92a; color: #241a07; }
.mm-key-absent  { background: rgba(28, 25, 42, .95); border-color: rgba(255, 255, 255, .05); color: #6b7090; }

@media (max-width: 420px) {
    .mm-word-tile { width: 42px; height: 42px; font-size: 1.3rem; }
    .mm-key { height: 42px; }
}
@media (prefers-reduced-motion: reduce) {
    .mm-tile-reveal, .mm-tile-active, .mm-word-shake { animation: none !important; }
}

/* ============================================================
 * Word Scramble — reuses the word card/frame/keyboard/tiles; adds the jumbled
 * "scramble" strip, the wrong-guess chips, and an emoji header/tile icon.
 * ============================================================ */
.mm-scramble-emoji { font-size: 2.4rem; line-height: 1; flex: 0 0 auto; filter: drop-shadow(0 3px 6px rgba(0, 0, 0, .4)); }

.mm-scramble-strip { display: flex; gap: 8px; justify-content: center; margin: 8px 0 4px; flex-wrap: wrap; }
.mm-scramble-tile {
    width: 50px; height: 56px; border-radius: 9px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.7rem; font-weight: 900; text-transform: uppercase; color: #1a1726;
    background: linear-gradient(180deg, #ffe39a, #e0a92a);
    border: 2px solid #f6c94a;
    box-shadow: 0 3px 10px rgba(246, 201, 74, .35), inset 0 1px 0 rgba(255, 255, 255, .5);
}
.mm-scramble-tile-empty { background: rgba(255, 255, 255, .04); border-color: rgba(255, 255, 255, .12); box-shadow: none; color: transparent; }
.mm-scramble-hint { font-size: .78rem; color: var(--mm-text-muted, #9aa3c0); margin-bottom: 8px; letter-spacing: .03em; }
.mm-scramble-guess { margin: 0 0 8px; }

.mm-scramble-tries { display: flex; gap: 8px; justify-content: center; align-items: center; flex-wrap: wrap; min-height: 1.4em; margin-bottom: 6px; }
.mm-scramble-try {
    font-size: .82rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
    color: #c97e8e; text-decoration: line-through;
    background: rgba(236, 90, 158, .12); border: 1px solid rgba(236, 90, 158, .3);
    padding: 2px 9px; border-radius: 999px;
}
.mm-scramble-left { font-size: .76rem; color: var(--mm-text-muted, #9aa3c0); }

/* Emoji used as a tile icon on the hub grid */
.mm-arcade-tile-emoji { font-size: 3rem; line-height: 1; height: 72px; display: flex; align-items: center; filter: drop-shadow(0 4px 8px rgba(0, 0, 0, .4)); }

@media (max-width: 420px) {
    .mm-scramble-tile { width: 44px; height: 50px; font-size: 1.45rem; }
}
