/* Mochimochi — Gashapon de premios */
.mm-machine__body { overflow: visible; }
.mm-knob { cursor: pointer; }
.mm-knob:hover { filter: brightness(1.05); }
.mm-knob:focus-visible { outline: 4px solid var(--g-sky) !important; outline-offset: 4px; }
.mm-knob-hint { position: absolute; right: -6px; top: -34px; padding: 5px 11px; border-radius: 999px; background: var(--c2-ink); color: #fff; font-family: var(--mm-display); font-size: 12px; line-height: 1.2; white-space: nowrap; pointer-events: none; z-index: 5; animation: mmHint 1.8s ease-in-out infinite; }
.mm-knob-hint::after { content: ""; position: absolute; right: 26px; bottom: -6px; border: 6px solid transparent; border-bottom: 0; border-top-color: var(--c2-ink); }
.mm-knob-hint.is-wait { background: var(--c2-muted); animation: none; }
.mm-knob-hint:empty { display: none; }
@keyframes mmHint { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
@media (prefers-reduced-motion: reduce) { .mm-knob-hint { animation: none; } }

/* Tarjeta del premio */
.mm-gm { position: fixed; inset: 0; z-index: 100000; display: grid; place-items: center; padding: 16px; opacity: 0; transition: opacity .25s; }
.mm-gm.is-open { opacity: 1; }
.mm-gm__back { position: absolute; inset: 0; background: rgba(59, 42, 74, .55); backdrop-filter: blur(3px); }
.mm-gm__card { position: relative; width: min(420px, 100%); padding: 56px 26px 24px; border-radius: 28px; background: #fff; border: 4px solid var(--c2-ink); box-shadow: 0 10px 0 var(--c); text-align: center; color: var(--c2-ink); transform: translateY(20px) scale(.96); transition: transform .3s cubic-bezier(.3,1.4,.5,1); }
.mm-gm.is-open .mm-gm__card { transform: none; }
.mm-gm__x { position: absolute; top: 10px; right: 12px; width: 36px; height: 36px; min-height: 0 !important; padding: 0 !important; border-radius: 50% !important; border: 0 !important; background: var(--c2-soft) !important; color: var(--c2-ink) !important; font-size: 22px; line-height: 1; cursor: pointer; box-shadow: none !important; }
.mm-gm__ball { position: absolute; left: 50%; top: -44px; width: 84px; height: 84px; margin-left: -42px; border-radius: 50%; border: 4px solid var(--c2-ink); background: linear-gradient(var(--c, #ff7eb3) 50%, #fff 50%); box-shadow: inset 0 -4px 0 rgba(0,0,0,.06); }
.mm-gm__ball::after { content: ""; position: absolute; left: -4px; right: -4px; top: calc(50% - 2px); height: 4px; background: var(--c2-ink); }
.mm-gm__ball--pop { animation: mmPop .6s cubic-bezier(.3,1.6,.5,1) both; }
@keyframes mmPop { 0% { transform: scale(.3) rotate(-30deg); } 100% { transform: scale(1) rotate(0); } }
.mm-gm__eyebrow { margin: 0 0 4px; font-family: var(--mm-display); color: var(--c2-red-dark); font-size: 14px; letter-spacing: .04em; }
.mm-gm__card h3 { margin: 0 0 8px; font-family: var(--mm-display); font-weight: 400; font-size: 26px; line-height: 1.15; color: var(--c2-ink); }
.mm-gm__card p { margin: 0 0 12px; color: var(--c2-muted); }
.mm-gm__code { margin: 14px auto 10px; padding: 12px; border-radius: 16px; border: 3px dashed var(--c); background: var(--c2-soft); }
.mm-gm__code small { display: block; font-size: 12px; color: var(--c2-muted); }
.mm-gm__code b { font-size: 26px; letter-spacing: .08em; font-family: ui-monospace, Menlo, Consolas, monospace; }
.mm-gm__small { font-size: 13px; }
.mm-gm__acts { display: grid; gap: 8px; margin-top: 16px; }
.mm-gm__btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 20px; border-radius: 999px !important; background: var(--c2-red) !important; color: #fff !important; font-family: var(--mm-display); font-size: 16px; text-decoration: none !important; border: 0 !important; box-shadow: 0 4px 0 var(--c2-red-dark) !important; cursor: pointer; }
.mm-gm__btn--ghost { background: transparent !important; color: var(--c2-ink) !important; box-shadow: none !important; border: 2px solid var(--c2-line) !important; }

/* Piel Pirata: cofres del tesoro */
.mm-chests { position: absolute; left: 4%; right: 10%; bottom: -4%; z-index: 6; display: flex; justify-content: center; gap: 4%; }
.mm-chests .mm-chests__hint { left: 50%; right: auto; top: -30px; transform: translateX(-50%); animation: none; background: var(--c2-ink); color: var(--c2-yellow); font-size: 15px; padding: 5px 14px; }
.mm-chests .mm-chests__hint::after { right: auto; left: 50%; margin-left: -6px; }
.mm-chest { width: 25%; max-width: 120px; aspect-ratio: 80 / 66; padding: 0 !important; min-height: 0 !important; border: 0 !important; background: none !important; box-shadow: none !important; cursor: pointer; transition: transform .2s, opacity .3s, filter .3s; filter: drop-shadow(0 8px 6px rgba(43, 29, 14, .35)); }
.mm-chest svg { width: 100%; height: 100%; display: block; overflow: visible; }
.mm-chest:hover { transform: translateY(-6px) rotate(-2deg); }
.mm-chest:focus-visible { outline: 4px solid var(--c2-yellow) !important; outline-offset: 4px; border-radius: 12px; }
.mm-chest__lid { transform-box: fill-box; transform-origin: 50% 100%; transition: transform .45s cubic-bezier(.3,1.5,.5,1); }
.mm-chest__glow { fill: var(--loot, #ffe58a); opacity: 0; transform-box: fill-box; transform-origin: center; transform: scale(.3); transition: opacity .4s, transform .5s; }
.mm-chest.is-shake { animation: mmShake .5s ease-in-out; }
.mm-chest.is-open .mm-chest__lid { transform: translateY(-12px) rotate(-14deg); }
.mm-chest.is-open .mm-chest__glow { opacity: .85; transform: scale(1); }
.mm-chest.is-open { transform: translateY(-8px) scale(1.08); }
.mm-chest.is-dim { opacity: .45; filter: grayscale(.6); }
@keyframes mmShake { 0%, 100% { transform: rotate(0); } 20% { transform: rotate(-7deg); } 40% { transform: rotate(6deg); } 60% { transform: rotate(-4deg); } 80% { transform: rotate(3deg); } }
@media (prefers-reduced-motion: reduce) { .mm-chest, .mm-chest__lid, .mm-chest.is-shake { animation: none; transition: none; } }
@media (max-width: 899px) { .mm-chests { bottom: -10%; } .mm-chests .mm-chests__hint { font-size: 13px; } }

/* Tarjeta con estética pirata */
.mm-gm--pirata .mm-gm__card { background: #fbf1da; border-color: var(--c2-ink); border-radius: 18px; }
.mm-gm--pirata .mm-gm__ball { border-radius: 14px; background: linear-gradient(#a0692f 45%, #8a5a2b 45%); }
.mm-gm--pirata .mm-gm__ball::after { top: 42%; background: #c48a1c; }
.mm-gm--pirata .mm-gm__eyebrow { font-size: 18px; color: var(--c2-red-dark); }
.mm-gm--pirata .mm-gm__card h3 { font-size: 32px; }
.mm-gm--pirata .mm-gm__code { background: #f1e3c2; }
.mm-gm--pirata .mm-gm__btn { background: var(--p-navy, #13233d) !important; color: var(--c2-yellow) !important; box-shadow: 0 4px 0 #0a1424 !important; font-size: 19px; }
.mm-gm--pirata .mm-gm__btn--ghost { background: transparent !important; color: var(--c2-ink) !important; box-shadow: none !important; border-color: var(--c2-line) !important; }
.mm-gm--pirata .mm-gm__x { background: #f1e3c2 !important; }
