/* Russian Roulette (comic toy) — hot pink x mustard party accent */
body[data-theme] {
    --color-primary-gradient: linear-gradient(135deg, #ec4899 0%, #f59e0b 100%);
    --shadow-glow: 0 0 25px rgba(236, 72, 153, 0.45);
    --shadow-glow-lg: 0 0 40px rgba(236, 72, 153, 0.55);
    --accent-blue: #ec4899;
}

.emoji-icon { font-size: 20px; }
.btn-add-item {
    display: flex; align-items: center; justify-content: center; gap: 6px;
    margin-top: 8px; padding: 9px; border-radius: var(--radius-sm);
    border: 1px dashed var(--color-border); background: transparent;
    color: var(--text-secondary); font-size: 0.82rem; font-weight: 600; cursor: pointer;
    transition: var(--transition-fast); width: 100%;
}
.btn-add-item:hover { border-color: var(--accent-blue); color: var(--accent-blue); background: rgba(236, 72, 153, 0.08); }

/* ---------- Gun stage ---------- */
.gun-stage { flex-direction: column; gap: 40px; }
.gun-stage { background: radial-gradient(circle at 52% 45%, rgba(244,114,182,.17), transparent 38%), radial-gradient(circle at 75% 20%, rgba(250,204,21,.13), transparent 28%); }

.gun-rig {
    position: relative;
    width: min(90vw, 340px);
    height: 170px;
}

.gun-body {
    position: absolute;
    inset: 0;
}
.gun-body::before { content: ''; position: absolute; left: 17%; top: 24px; width: 58px; height: 22px; border-radius: 50%; background: rgba(255,255,255,.32); filter: blur(4px); }

.gun-barrel {
    position: absolute;
    right: 10px; top: 42px;
    width: 46%; height: 36px;
    background: linear-gradient(180deg, #f9a8d4, #ec4899);
    border: 3px solid #9d174d;
    border-radius: 8px 18px 18px 8px;
    box-shadow: inset 0 -4px 6px rgba(0,0,0,0.15);
}
.gun-barrel::after {
    content: '';
    position: absolute; right: -4px; top: 50%; transform: translateY(-50%);
    width: 14px; height: 42px;
    background: #831843; border-radius: 4px;
}
.gun-barrel::before { content: ''; position: absolute; left: 8px; right: 22px; top: 6px; height: 5px; border-radius: 50%; background: rgba(255,255,255,.35); }

.gun-grip {
    position: absolute;
    left: 22%; bottom: -6px;
    width: 20%; height: 92px;
    background: linear-gradient(180deg, #fbcfe8, #f472b6);
    border: 3px solid #9d174d;
    border-radius: 14px;
    transform: rotate(20deg);
    transform-origin: top center;
    box-shadow: inset 0 -4px 6px rgba(0,0,0,0.15);
}

.gun-cylinder {
    position: absolute;
    left: 34%; top: 6px;
    width: 92px; height: 92px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, #fbcfe8, #db2777 75%);
    border: 4px solid #831843;
    box-shadow: 0 6px 14px rgba(0,0,0,0.25), inset 0 0 0 3px rgba(255,255,255,0.25);
    transition: transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.gun-cylinder::before { content: ''; position: absolute; inset: 8px; border-radius: 50%; border: 2px dashed rgba(255,255,255,.36); }
.gun-cylinder::after { content: '★'; position: absolute; inset: 0; display: grid; place-items: center; color: #ffe4a3; font-size: 22px; text-shadow: 0 2px 0 #9d174d; }
.chamber {
    position: absolute;
    width: 17px; height: 17px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, #4a044e, #1e0a2e 70%);
    box-shadow: inset 0 2px 3px rgba(0,0,0,0.7);
}
.c0 { left: 37px; top: 6px; }
.c1 { left: 64px; top: 22px; }
.c2 { left: 64px; top: 53px; }
.c3 { left: 37px; top: 69px; }
.c4 { left: 11px; top: 53px; }
.c5 { left: 11px; top: 22px; }

.bang-flag {
    position: absolute;
    right: -6px; top: 8px;
    width: 108px; height: 56px;
    background: linear-gradient(135deg, #fde047, #facc15);
    border: 3px solid #78350f;
    clip-path: polygon(0 0, 82% 0, 100% 50%, 82% 100%, 0 100%);
    display: flex; align-items: center; justify-content: center;
    transform: scale(0) rotate(-25deg);
    transform-origin: 0% 50%;
    opacity: 0;
    z-index: 6;
    transition: transform 0.4s cubic-bezier(0.34, 1.8, 0.64, 1), opacity 0.15s ease;
}
.bang-flag::after {
    content: '';
    position: absolute; left: -16px; top: 50%; transform: translateY(-50%);
    width: 20px; height: 6px; background: #78350f; border-radius: 2px;
}
.bang-flag span {
    font-family: var(--font-display); font-weight: 900; font-size: 1.1rem; color: #9a3412;
    letter-spacing: -0.02em; transform: translateX(-6px);
}
.bang-flag { box-shadow: 7px 8px 0 rgba(120,53,15,.2), inset 0 3px 0 rgba(255,255,255,.5); }
.bang-flag.popped {
    opacity: 1;
    animation: flagPop 0.7s cubic-bezier(0.34, 1.8, 0.64, 1);
}
@keyframes flagPop {
    0% { transform: scale(0) rotate(-25deg); opacity: 0; }
    55% { transform: scale(1.15) rotate(10deg); opacity: 1; }
    75% { transform: scale(0.95) rotate(-6deg); }
    100% { transform: scale(1) rotate(0deg); }
}

/* A visibly toy-like carnival launcher, never a realistic weapon treatment. */
.gun-stage { background: radial-gradient(circle at 17% 19%, rgba(255,255,255,.7) 0 3px, transparent 4px) 0 0 / 42px 42px, radial-gradient(ellipse at 50% 91%, rgba(202,90,152,.18), transparent 40%), linear-gradient(180deg, #ccecf7, #f5d6eb); }
.gun-rig { filter: drop-shadow(0 16px 10px rgba(109,38,93,.2)); }
.gun-body::after { content: ''; position: absolute; left: 18px; top: 34px; width: 42px; height: 42px; border-radius: 50%; background: radial-gradient(circle at 32% 28%, #fff5b2 0 10%, #f4bb32 13% 61%, #bd6b11 64%); border: 3px solid #91411e; box-shadow: 0 4px 0 rgba(110,51,18,.22); }
.gun-barrel { background: linear-gradient(180deg, #ffcfde, #ef6eac 55%, #c8377a); box-shadow: inset 0 5px 0 rgba(255,255,255,.45), inset 0 -5px 7px rgba(124,24,71,.2), 0 5px 0 rgba(128,28,77,.22); }
.gun-cylinder { background: radial-gradient(circle at 34% 25%, #ffe6ef 0 7%, #f78dbc 40%, #cc397d 76%); }
.chamber { border: 2px solid rgba(255,230,184,.28); }

/* ---------- Carnival popper: an original front-facing toy silhouette ---------- */
.gun-stage { gap: 26px; padding-top: 8px; }
.gun-rig { width: min(92vw, 430px); height: 250px; }
.gun-body { filter: drop-shadow(0 18px 13px rgba(91,42,80,.24)); }
.gun-body::before {
    left: 50%; top: 32px; width: 222px; height: 160px;
    transform: translateX(-50%); border-radius: 48% 48% 34% 34%;
    background: linear-gradient(145deg, #ffd661, #f49c34 46%, #da6438 100%);
    border: 5px solid #8d3d2c;
    box-shadow: inset 10px 8px 0 rgba(255,255,255,.36), inset -12px -10px 0 rgba(130,47,37,.18), 0 9px 0 rgba(126,48,35,.25);
    filter: none;
}
.gun-body::after {
    left: 50%; top: 44px; width: 178px; height: 137px;
    transform: translateX(-50%); border-radius: 48% 48% 38% 38%;
    background: radial-gradient(circle at 35% 19%, rgba(255,255,255,.58) 0 5%, transparent 6%), linear-gradient(145deg, #43c7d6, #2383b9 62%, #1a578f);
    border: 5px solid #174b76;
    box-shadow: inset 8px 7px 0 rgba(255,255,255,.18), inset -10px -10px 0 rgba(4,61,112,.18);
}
.gun-barrel {
    z-index: 3;
    right: auto; left: 50%; top: 12px;
    width: 86px; height: 71px;
    transform: translateX(-50%);
    border: 5px solid #8d3d2c;
    border-radius: 38px 38px 23px 23px;
    background: linear-gradient(145deg, #ffe990, #f6ae38 58%, #db672d);
    box-shadow: inset 8px 6px 0 rgba(255,255,255,.45), inset -7px -9px 0 rgba(132,46,25,.18), 0 6px 0 rgba(126,48,35,.25);
}
.gun-barrel::before { left: 13px; right: 13px; top: 10px; height: 8px; background: rgba(255,255,255,.52); }
.gun-barrel::after { display: none; }
.gun-muzzle {
    position: absolute; left: 50%; bottom: -18px; width: 55px; height: 31px;
    transform: translateX(-50%); border-radius: 0 0 18px 18px;
    background: radial-gradient(ellipse at 50% 8%, #29354d 0 29%, #18243a 32% 45%, #f2b64a 48% 63%, #9d452d 66%);
    border: 4px solid #8d3d2c; box-shadow: inset 0 5px 0 rgba(255,255,255,.18), 0 4px 0 rgba(117,49,33,.22);
}
.gun-sight {
    position: absolute; z-index: 5; left: 50%; top: 0; width: 37px; height: 27px;
    transform: translateX(-50%); border: 5px solid #8d3d2c; border-bottom: 0;
    border-radius: 20px 20px 0 0; background: #ef7b43;
    box-shadow: inset 5px 4px 0 rgba(255,255,255,.27);
}
.gun-cylinder {
    z-index: 4; left: calc(50% - 61px); top: 53px; width: 122px; height: 122px;
    transform: none;
    border: 6px solid #8d3d2c;
    background: radial-gradient(circle at 34% 24%, #fff1bf 0 6%, #fbcb58 35%, #e7773b 72%);
    box-shadow: 0 9px 0 rgba(126,48,35,.3), 0 15px 20px rgba(64,34,61,.22), inset 7px 7px 0 rgba(255,255,255,.4), inset -8px -9px 0 rgba(142,53,36,.18);
}
.gun-cylinder::before { inset: 11px; border: 3px dashed rgba(151,69,37,.45); }
.gun-cylinder::after { font-size: 25px; color: #fff4ad; text-shadow: 0 3px 0 #a7472d; }
.chamber { width: 20px; height: 20px; border: 3px solid rgba(255,245,192,.7); background: radial-gradient(circle at 35% 30%, #405273, #17233c 68%); box-shadow: inset 0 3px 4px rgba(0,0,0,.55), 0 2px 0 rgba(132,51,31,.24); }
.c0 { left: 47px; top: 7px; }.c1 { left: 81px; top: 27px; }.c2 { left: 81px; top: 67px; }.c3 { left: 47px; top: 89px; }.c4 { left: 10px; top: 67px; }.c5 { left: 10px; top: 27px; }
.gun-grip {
    z-index: 2; left: 50%; bottom: -3px; width: 88px; height: 91px;
    transform: translateX(-50%); border: 5px solid #174b76; border-radius: 20px 20px 31px 31px;
    background: linear-gradient(90deg, #1f6b9f, #49c4d4 42%, #207db1);
    box-shadow: inset 8px 5px 0 rgba(255,255,255,.22), inset -9px -7px 0 rgba(8,66,117,.22), 0 8px 0 rgba(22,64,103,.22);
}
.grip-grooves { position: absolute; inset: 22px 17px 14px; border-radius: 12px; background: repeating-linear-gradient(135deg, rgba(6,57,104,.32) 0 4px, rgba(255,255,255,.17) 4px 8px); }
.gun-logo { position: absolute; z-index: 6; left: calc(50% + 72px); top: 117px; color: #fff9cf; font-family: var(--font-display); font-size: 18px; font-weight: 900; font-style: italic; transform: rotate(-12deg); text-shadow: 0 3px 0 #b64c33, 2px 0 0 #b64c33, -2px 0 0 #b64c33; }
.gun-bolt { position: absolute; z-index: 6; top: 151px; width: 17px; height: 17px; border-radius: 50%; background: radial-gradient(circle at 32% 28%, #fff9b0, #eab23e 64%, #a96118); border: 2px solid #94432c; box-shadow: 0 2px 0 rgba(112,45,24,.24); }.gun-bolt-left { left: calc(50% - 91px); }.gun-bolt-right { right: calc(50% - 91px); }
.bang-flag { z-index: 10; right: calc(50% - 204px); top: 18px; border-width: 4px; background: repeating-linear-gradient(135deg, #ffed6e 0 9px, #ffd84a 9px 18px); box-shadow: 7px 8px 0 rgba(120,53,15,.2), inset 0 4px 0 rgba(255,255,255,.62); }
.trigger-btn { border: 3px solid rgba(255,255,255,.58); box-shadow: inset 0 4px 0 rgba(255,255,255,.24), var(--shadow-glow-lg), 0 9px 0 rgba(145,50,86,.25); }

@media (max-width: 640px) {
    .gun-rig { height: 232px; transform: scale(.88); transform-origin: center bottom; margin: -14px 0; }
    .bang-flag { right: calc(50% - 182px); }
}

@media (prefers-reduced-motion: reduce) {
    .gun-cylinder, .bang-flag, .trigger-btn { transition: none; animation: none; }
}

.trigger-btn {
    position: relative;
    display: flex; align-items: center; gap: 10px;
    padding: 18px 40px;
    font-family: var(--font-display); font-size: 1.1rem; font-weight: 800;
    color: #fff;
    background: var(--color-primary-gradient);
    border: none; border-radius: 50px;
    cursor: pointer;
    box-shadow: var(--shadow-glow-lg), 0 10px 0 rgba(0,0,0,0.18);
    transition: transform 0.1s ease;
    animation: triggerPulse 1.8s ease-in-out infinite;
}
.trigger-btn .material-symbols-outlined { font-size: 26px; }
.trigger-btn:hover { transform: translateY(-2px); }
.trigger-btn:active { transform: translateY(4px); box-shadow: var(--shadow-glow), 0 4px 0 rgba(0,0,0,0.18); }
.trigger-btn:disabled { opacity: 0.5; cursor: not-allowed; animation: none; box-shadow: none; }
@keyframes triggerPulse {
    0%, 100% { box-shadow: var(--shadow-glow-lg), 0 10px 0 rgba(0,0,0,0.18); }
    50% { box-shadow: 0 0 46px color-mix(in srgb, var(--accent-blue) 65%, transparent), 0 10px 0 rgba(0,0,0,0.18); }
}

@media (max-width: 640px) {
    .gun-rig { height: 140px; }
    .gun-cylinder { width: 76px; height: 76px; }
    .trigger-btn { padding: 16px 30px; font-size: 1rem; }
}

/* Keep the detailed toy proportions intact on narrow screens. */
@media (max-width: 640px) {
    .gun-rig { height: 232px; transform: scale(.88); transform-origin: center bottom; margin: -14px 0; }
    .gun-cylinder { left: calc(50% - 61px); top: 53px; width: 122px; height: 122px; }
    .bang-flag { right: calc(50% - 182px); }
}
.game-help { margin: 0 0 28px; padding: 26px; }.game-help h2 { font-family: var(--font-display); font-size: 1.3rem; margin-bottom: 16px; }.game-help-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }.game-help article { padding: 16px; border: 1px solid var(--color-border-subtle); border-radius: var(--radius-md); background: var(--color-surface-hover); }.game-help h3 { color: var(--accent-blue); font-family: var(--font-display); font-size: 1rem; margin-bottom: 7px; }.game-help p { color: var(--text-secondary); font-size: .88rem; line-height: 1.75; }@media (max-width:720px){.game-help{padding:20px 16px}.game-help-grid{grid-template-columns:1fr}}
