@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700;900&family=Share+Tech+Mono&display=swap');

html, body { height:100%; }

#game-wrapper {
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 480px;
    height: 854px;
    box-sizing: border-box;
    aspect-ratio: 9 / 16;
    overflow: hidden;
    border: 2px solid #f0f;
    display: block;
    touch-action: none;
}
#game-wrapper canvas { width:100%; height:100%; display:block; }

.hud-fixed {
    position: relative;
    left: 50%;
    right: 50%;
    bottom: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    justify-content: center;
    gap: 12px;
    padding: 10px;
    z-index: 1000;
}

@media (max-width: 768px) {
    .hud-fixed button, .hud-fixed .btn {
        transform: scale(0.9);
    }
}

:root {
    --bg: #090009;
    --neon-blue: #00ffff;
    --neon-pink: #ff00ff;
    --neon-yellow: #ffff00;
    --ui-bg: rgba(10, 10, 18, 0.95);
}

body {
    margin: 0;
    background-color: #000;
    background-image: url('images/bg3.png');
    color: #fff;
    font-family: 'Orbitron', sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100dvh;
    width: 100vw;
    overflow: hidden;
    user-select: none;
}

h2.subtitle{
    width: 100%;
    text-align: center;
    margin-top: 0px;
    margin-bottom: -1%;
}
h2 {
    text-shadow: 0 0 10px var(--neon-pink);
    margin-bottom: 0px;
}

.menu-info {
    font-size: 20px;
    font-weight: bold;
    margin: 0px;
    margin-bottom: 5px;
    color: #ff0;
    text-shadow: #ff0 0 0 10px;
}

.shop-grid {
    margin-top: 5px;
}
.shop-actions {
    margin-top: -20px;
}

.scanlines {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.06), rgba(0, 255, 0, 0.02), rgba(0, 0, 255, 0.06));
    background-size: 100% 2px, 3px 100%;
    pointer-events: none;
    z-index: 10;
}


canvas {
    background: var(--bg);
    display: block;
    cursor: crosshair;
    width: 100%;
    height: 100%;
}

.joystick-base {
    position: absolute;
    width: 120px; height: 120px;
    border-radius: 50%;
    background: radial-gradient(circle at 50% 50%, rgba(255,0,255,0.25) 0%, rgba(160,0,120,0.15) 60%, rgba(0,0,0,0) 75%);
    border: 2px solid #f0f;
    box-shadow: 0 0 18px rgba(255,0,255,0.35), inset 0 0 22px rgba(255,0,255,0.35);
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 8;
    opacity: 0.55;
    backdrop-filter: blur(4px);
}
.joystick-stick {
    position: absolute;
    width: 60px; height: 60px;
    border-radius: 50%;
    background: radial-gradient(circle at 40% 40%, rgba(255,255,255,0.85) 0%, rgba(255,0,255,0.85) 70%, rgba(255,0,255,0.5) 100%);
    border: 2px solid #faf;
    box-shadow: 0 0 25px rgba(255,0,255,0.65), inset 0 0 25px rgba(255,180,255,0.6);
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 9;
    opacity: 0.65;
}
.joystick-hidden { display:none; }

@media (max-width: 600px) {
    body {
        align-items: center;
    }
}

#bottom-controls {
    position: absolute;
    left: 0; right: 0; bottom: 12px;
    width: 100%; height: 0;
    pointer-events: none;
}
.bottom-center {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    pointer-events: all;
}
.corner-btn {
    position: absolute;
    bottom: 0;
    pointer-events: all;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 50px;
    padding: 0;
    box-sizing: border-box;
    cursor: pointer;
    transition: transform 120ms ease, box-shadow 120ms ease, border-color 120ms ease;
}
.corner-btn.left { left: 5px; }
.corner-btn.right { right: 5px; }

#ui-layer {
    position: absolute;
    font-weight: bold;
    top: 0; left: 0; width: 100%; height: 100%;
    pointer-events: none;
}

#pause-btn, #restart-btn { line-height:50px; }
.corner-btn svg { width: 48px; height: 48px; display:block; pointer-events:none; }
.corner-btn svg path { stroke-width: 2.25; }
.control-btn.secondary-btn {
    padding: 0 !important;
    line-height: 50px !important;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    box-sizing: border-box;
}
.control-btn svg { width: 48px; height: 48px; display:block; pointer-events:none; }
.control-btn svg path { stroke-width: 2.25; }
#player-aura {
    position: absolute;
    width: 76px;
    height: 76px;
    left: 0; top: 0;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    pointer-events: none;
    mix-blend-mode: screen;
    background: radial-gradient(circle at 50% 50%, rgba(255,255,255,0.18) 0%, var(--aura-color, #ff00ff) 48%, rgba(0,0,0,0) 75%);
    box-shadow: 0 0 10px var(--aura-color, #ff00ff), 0 0 20px rgba(255,255,255,0.18);
    animation: auraPulse 2.4s ease-in-out infinite;
    z-index: 1;
    opacity: 0; 
    transition: opacity 120ms linear;
    filter: blur(2px);
    animation-play-state: paused; 
}
#player-aura.active { opacity: 0.9; animation-play-state: running; transform: translate(-50%, -50%) scale(1.02); }
@keyframes auraPulse {
    0% { transform: translate(-50%, -50%) scale(0.90); }
    50% { transform: translate(-50%, -50%) scale(1.03); }
    100% { transform: translate(-50%, -50%) scale(0.90); }
}


#start-screen::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('images/star.png');
    background-repeat: repeat;
    background-size: 64px 64px;
    opacity: 1;
    animation: menuStarsScroll 24s linear infinite;
    pointer-events: none;
}
@keyframes menuStarsScroll { 0% { background-position: 0 0; } 100% { background-position: 0 512px; } }

.hud-top {
    position: sticky;
    display: flex;
    justify-content: space-between;
    padding: 20px;
    font-size: 18px;
    text-shadow: 0 0 10px var(--neon-blue);
}

.neon-text { 
    color: var(--neon-blue); 
    margin-bottom: 10px;
}

#high-score {
    margin-bottom: 8px;
}
#high-score .record-label { color: #ffff00; }
#high-score .record-value { color: #00ffff; }

#boss-warning {
    position: absolute;
    top: 30%; width: 100%;
    text-align: center;
    font-size: 28px;
    color: #f00;
    background: rgba(0,0,0,0.7);
    padding: 10px 0;
    animation: flash 0.5s infinite;
    z-index: 5;
}
@keyframes flash { 0% {opacity:1;} 50% {opacity:0;} 100% {opacity:1;} }

#powerup-warning {
    position: absolute;
    top: 30%; width: 100%;
    text-align: center;
    font-size: 26px;
    color: #0ff;
    background: rgba(0,0,0,0.7);
    padding: 10px 0;
    animation: flash 0.5s infinite;
    z-index: 6;
}

.modal {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: var(--ui-bg);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    pointer-events: all;
    backdrop-filter: blur(5px);
    padding: 12px 8px;
    box-sizing: border-box;
    overflow-y: auto;
}
.modal#start-screen {
    overflow: hidden;       
    overscroll-behavior: none; 
    touch-action: none;       
}
.hidden { display: none !important; }
.modal#game-over h2 { margin-top:0; }
.modal#game-over p { margin:6px 0; font-weight:700; }
.reset-modal.hidden { display: none !important; }
.reset-modal {
        position: absolute;
        top: 0; left: 0; width: 100%; height: 100%;
        background: rgba(10,10,18,0.85);
        display: flex;
        align-items: center;
        justify-content: center;
        z-index: 20;
    backdrop-filter: blur(3px);
    pointer-events: all;
}
.reset-dialog {
        width: 88%; max-width: 360px;
        background: #0b0b12;
        border: 2px solid #f0f;
        box-shadow: 0 0 25px rgba(255,0,255,0.25);
        padding: 16px 18px;
        animation: pop-in 180ms ease-out;
}
.reset-dialog h4 { 
    margin: 0 0 8px 0; 
    color: #f0f; 
    font-size: 18px; 
}
.reset-dialog p { 
    margin: 0 0 12px 0; 
    font-size: 14px;
    font-weight: bold; 
    color: #FFF; 
}
.reset-actions { 
    display: flex; 
    gap: 12px; 
    justify-content: flex-end; }
@keyframes pop-in {
    0% { transform: scale(0.9); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

h1 { 
    font-size: 40px; 
    margin: 0; 
    margin-top: 120px;
    letter-spacing: 2px;
    text-shadow: #f0f 0 0 10px; 
}
.subtitle { 
    color: #00ffff; 
    margin-bottom: 40px; 
    font-size: 14px; 
    letter-spacing: 4px; }

.shop-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin-bottom: 8px;
    width: 88%;
    max-width: 520px;
}
.shop-item {
    background: rgba(255,255,255,0.06);
    border: 1px solid #f0f;
    padding: 10px 12px;
    cursor: pointer;
    width: 100%;
    text-align: left;
    box-sizing: border-box;
}
.shop-item:hover { 
    border-color: var(--neon-blue); 
    box-shadow: 0 0 15px var(--neon-blue); 
}
.shop-item.disabled {
    opacity: 0.45;
    pointer-events: none;
    filter: grayscale(0.4);
    box-shadow: none;
    border-color: #555;
}
.shop-label { 
    font-size: 13px;
    margin-bottom: 2px; 
    color: #f0f; 
    font-weight: 700;
}
.shop-level { 
    font-size: 11px; 
    color: #0ff; 
    margin-bottom: 2px; 
}
.shop-cost { 
    font-size: 13px; 
    color: var(--neon-yellow); 
}
.shop-actions {
    width: 88%; 
    max-width: 360px; 
    display: flex; 
    justify-content: center; 
}
.game-over-actions { 
    margin-top:10px; 
}

.mega-btn {
    background: var(--neon-pink);
    border: none;
    color: white;
    padding: 20px 40px;
    font-family: 'Orbitron';
    font-weight: 900;
    font-size: 20px;
    cursor: pointer;
    clip-path: polygon(10% 0, 100% 0, 100% 70%, 90% 100%, 0 100%, 0 30%);
    transition: transform 0.1s;
}
.mega-btn:hover { 
    transform: scale(1.05);
    box-shadow: 0 0 50px var(--neon-pink); }
.secondary-btn {
    background: transparent;
    border: 1px solid #ff0;
    color: #ff0;
    padding: 15px 20px;
    cursor: pointer;
    margin-top: 25px;
    margin-bottom: -8px;
    font-family: 'Orbitron';
    transition: transform 120ms ease, box-shadow 120ms ease, border-color 120ms ease;
}
.secondary-btn:hover { 
    border-color: #ffa; 
    color: #ffa; 
    box-shadow: 0 0 15px #0ff;
    transform: scale(1.03);
}

.corner-btn.secondary-btn {
    padding: 0 !important;
    line-height: 50px !important;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    box-sizing: border-box;
}

.corner-btn svg { width: 48px; height: 48px; display:block; pointer-events:none; }
.corner-btn svg path { stroke-width: 2; }

.corner-btn:hover {
    border-color: #ffa;
    box-shadow: 0 0 18px var(--neon-blue);
    transform: scale(1.08);
}

h4 {
    text-align: center;
}
.controls-panel {
    border: 2px solid #f0f;
    padding: 8px 12px;
    width: 88%;
    max-width: 380px;
    margin-top: 15px;
    margin-bottom: 20%;
    color: #fff;
    display: grid;
    grid-template-columns: 1fr auto 1fr auto 1fr;
    gap: 4px;
}
h4 {
    grid-column: 1 / -1;
    margin-top: -5px;
    margin-bottom: -8px; 
    color: #f0f; 
    font-size: 16px;
}
.control-item {
    margin-bottom: 0px;
}
.control-headers, .control-item {
    display: contents;
}
.control-cell {
    text-align: center;
    padding: 1px 0;
    margin-bottom: 0px;
}
.control-cell.header {
    font-weight: bold;
    color: #f0f;
}
.control-cell.keyboard, .control-cell.mobile, .control-cell.action, .separator {
    margin: -1px;
}
.control-cell.keyboard, .control-cell.mobile {
    color: #0ff;
    font-family: monospace;
    font-size: 18px;
}
.control-cell.action {
    color: #fff;
    font-family: monospace;
    font-size: 18px;
}
.separator {
    text-align: center;
    color: #ff0;
    font-family: 'Orbitron', monospace;
    font-size: 18px;
}

.ult-glow {
    position:absolute;
    width:40px; height:40px;
    left:0; top:0;
    transform:translate(-50%, -50%);
    border-radius:50%;
    pointer-events:none;
    box-shadow:0 0 10px currentColor, 0 0 28px currentColor inset, 0 0 55px currentColor, 0 0 95px currentColor;
    animation:ultPulse 1.4s ease-in-out infinite;
    opacity:0.85;
    display:none;
}
.ult-glow.charged { display:block; }
.ult-lydia { color:#f0f; }
.ult-cybil { color:#0ff; }
.ult-sofia { color:#ff0; }
@keyframes ultPulse {
    0% { transform:translate(-50%, -50%) scale(0.9); opacity:0.6; }
    50% { transform:translate(-50%, -50%) scale(1.05); opacity:1; }
    100% { transform:translate(-50%, -50%) scale(0.9); opacity:0.6; }
}

.cards-container {
    display: flex;
    flex-direction: column; 
    gap: 12px;
    align-items: center;
    width: 100%;
    padding: 0 10px;
    box-sizing: border-box;
}
.card {
    background: #111;
    border: 1px solid #f0f;
    padding: 15px;
    width: 88%;
    max-width: 360px;
    cursor: pointer;
    position: relative;
    transition: 0.2s;
}
.card.lydia {
    background: linear-gradient(to right, #880088, #111);
}
.card.sofia {
    background: linear-gradient(to right, #888800, #111);
    border-color: #ff0;
}
.card.cybil {
    background: linear-gradient(to right, #008888, #111);
    border-color: #0ff;
}
.card .card-cost { position: absolute; right: 10px; top: 10px; }
.card:hover {
    z-index: 2; 
    border-color: #fff; 
}
.card h3 { 
    font-size: 15px; 
    color: #fff; 
    margin: 0 0 5px 0; 
    text-shadow: 0 0 20px #000;
}
.card .trait { 
    font-size: 16px; 
    color: #fff; 
    margin-bottom: 5px; 
    text-shadow: 0 0 20px #000;
}
.card .stats { 
    font-size: 15px; 
    color: #0f0; 
    text-shadow: 0 0 20px #000;
}
.card .card-skin {
    position: absolute;
    right: 165px;
    top: 50%;
    transform: translateY(-50%);
    width: 60px;
    height: auto;
    opacity: 0.4;
    z-index: 0;
}

.glitch-text { 
    position: relative; 
    margin-top: 16%;
    margin-bottom: 1%;
}
.glitch-text::before, .glitch-text::after {
    content: attr(data-text);
    position: absolute; left: 0; width: 100%; height: 100%; background: var(--ui-bg);
}
.glitch-text::before { left: 2px; text-shadow: -1px 0 #f00; clip: rect(24px, 550px, 90px, 0); animation: glitch-anim-2 3s infinite linear alternate-reverse; }
.glitch-text::after { left: -2px; text-shadow: -1px 0 #00f; clip: rect(85px, 550px, 140px, 0); animation: glitch-anim 2.5s infinite linear alternate-reverse; }
@keyframes glitch-anim { 0% { clip: rect(13px, 9999px, 12px, 0); } 100% { clip: rect(66px, 9999px, 80px, 0); } }

@media (max-width: 480px) {
    html { -webkit-text-size-adjust: 115%; text-size-adjust: 115%; }
    .hud-top { font-size: 20px; }
    .menu-info { font-size: 20px; }
    .shop-label { font-size: 14px; }
    .shop-level { font-size: 12px; }
    .shop-cost { font-size: 14px; }
    .control-cell.keyboard, .control-cell.mobile, .control-cell.action { font-size: 15px; }
    .card h3 { font-size: 14px; }
    .card .trait { font-size: 15px; }
    .card .stats { font-size: 14px; }
    #boss-warning { font-size: 28px; }
    #powerup-warning { font-size: 28px; }
}

.launch-row { 
    position: relative; 
    width: 100%; 
    display: flex; 
    justify-content: center; 
    align-items: center; }
.launch-row .mega-btn { 
    margin: 0 auto; 
}
.icon-btn { position: absolute; display:flex; align-items:center; justify-content:center; width:48px; height:48px; border:1px solid #ff0; background:transparent; color:#ff0; cursor:pointer; }
.icon-btn.right { left: calc(50% + 155px); }
.icon-btn.left { left: calc(50% - 193px); }
.icon-btn svg { width: 28px; height: 28px; }
.icon-btn:hover { border-color: #ffa; color: #ffa; box-shadow: 0 0 18px #0ff; transform: scale(1.08); }

.scale-labels { font-size: 11px; color: #aaa; letter-spacing: 2px; margin-top: 4px; text-align:center; }

#accessibility-modal .reset-dialog { text-align: center; }
#accessibility-modal .acc-row { text-align: center; }
#accessibility-modal .acc-row .segmented { justify-content: center; }
#accessibility-modal input[type="range"] { width: 70%; margin: 0 auto; display: block; }
#accessibility-modal .reset-actions { justify-content: center; }
#accessibility-modal .value-row { font-size: 12px; color: #0ff; margin-top: 4px; }
.secondary-btn.selected { border-color: #0ff; color: #0ff; box-shadow: 0 0 10px #0ff; }

#accessibility-modal .reset-dialog { max-width: 420px; }
#accessibility-modal .acc-row { margin-bottom: 10px; }
#accessibility-modal .acc-label { display: block; margin-bottom: 8px; color: #0ff; }
#accessibility-modal .segmented { 
    margin-top: -20px;
    margin-bottom: 20px;
    display: flex; gap: 8px; }
#accessibility-modal .segmented { 
    display: flex; gap: 8px; }

#skins-modal .reset-dialog { max-width: 420px; text-align: center; }
.skins-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; width: 88%; max-width: 420px; margin: 10px auto; }
.skin-card { background: rgba(255,255,255,0.06); border: 1px solid #f0f; padding: 8px; box-sizing: border-box; display: flex; flex-direction: column; gap: 6px; }
.skin-card:hover { border-color: var(--neon-blue); box-shadow: 0 0 15px var(--neon-blue); }
.skin-card { cursor: pointer; }
.skin-card.selected { border-color: var(--neon-blue); box-shadow: 0 0 18px var(--neon-blue), 0 0 30px rgba(0,255,255,0.35); }
.skin-card img { width: 100%; display: block; aspect-ratio: 1 / 1; object-fit: contain; max-height: 96px; }
.skin-name { font-size: 12px; margin-top: 6px; color: #f0f; font-weight: 700; text-align: center; }
.skin-cost { font-size: 11px; color: var(--neon-yellow); text-align: center; }
#skin-status-row { text-align: center; }
.skin-perk { font-family: 'Orbitron', monospace; font-weight: 600; font-size: 12px; letter-spacing: 0.5px; margin-top: 2px; margin-bottom: 6px; color: var(--neon-blue); text-align: center; }
#skins-modal .reset-actions { justify-content: center; }

.armament-card {
    background: rgba(255,255,255,0.06);
    border: 1px solid #f0f;
    padding: 8px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    transition: transform 120ms ease, box-shadow 120ms ease, border-color 120ms ease;
    box-shadow: none;
}
.armament-card img { width: 100%; display: block; aspect-ratio: 1 / 1; object-fit: contain; max-height: 96px; }
.armament-card .skin-name { font-size: 12px; margin-top: 6px; color: #f0f; font-weight: 700; text-align: center; }
.armament-card .skin-cost { font-size: 11px; color: var(--neon-yellow); text-align: center; font-weight: 700; }
.armament-card:hover { border-color: var(--neon-blue); box-shadow: 0 0 15px var(--neon-blue); }
.armament-card.selected { border-color: var(--neon-blue); box-shadow: 0 0 18px var(--neon-blue), 0 0 30px rgba(0,255,255,0.35); }
.armament-card.disabled { opacity: 0.66; }
.armament-card.disabled:hover { box-shadow: none !important; border-color: #f0f; cursor: not-allowed; transform: none !important; }

.new-unlock {
    animation: newUnlockAnim 680ms ease-in-out 0s 1 forwards;
}
@keyframes newUnlockAnim {
    0% { transform: scale(1); }
    40% { transform: scale(1.12); }
    100% { transform: scale(1); }
}

#splash-screen { position: absolute; top:0; left:0; width:100%; height:100%;}
#splash-screen::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('images/star.png');
    background-repeat: repeat;
    background-size: 64px 64px;
    opacity: 1;
    animation: menuStarsScroll 24s linear infinite;
    pointer-events: none;
}
#splash-dialog { text-align: center; max-width: 420px; }
#splash-dialog { min-height: 100%; padding-top: 22px; padding-bottom: 22px; }
#splash-dialog .glitch-text { margin-top: 70%; }
#splash-dialog .subtitle { margin-top: 2px; margin-bottom: 18px; color: #00ffff; font-size: 14px; letter-spacing: 3px; }
#splash-dialog .reset-actions { justify-content: center; }
#splash-play-btn { padding: 22px 48px; }
#splash-play-btn:hover { box-shadow: 0 0 50px var(--neon-pink); transform: scale(1.05); }

#splash-dialog::before,
#splash-dialog::after {
    content: '';
    position: absolute;
    left: 12px; right: 12px;
    height: 3px;
    background: linear-gradient(90deg, rgba(255,0,255,0) 0%, rgba(255,0,255,0.9) 50%, rgba(255,0,255,0) 100%);
    box-shadow: 0 0 12px rgba(0, 255, 255,0.75), 0 0 24px rgba(255,0,255,0.35);
}
#splash-dialog::before { top: 250px; }
#splash-dialog::after { bottom: 350px; }

#game-over::before,
#game-over::after {
    content: '';
    position: absolute;
    left: 12px; right: 12px;
    height: 3px;
    background: linear-gradient(90deg, rgba(255,0,255,0) 0%, rgba(0, 255,255,0.9) 50%, rgba(255,0,255,0) 100%);
    box-shadow: 0 0 12px rgba(255, 0, 255,0.75), 0 0 24px rgba(255,0,255,0.35);
}
#game-over::before { top: 250px; }
#game-over::after { bottom: 250px; }

#splash-dialog.closing {
    animation: splashClose 220ms ease-out forwards;
}

#accessibility-modal .reset-dialog.closing,
#skins-modal .reset-dialog.closing {
    animation: splashClose 220ms ease-out forwards;
}

#reset-cancel-btn {
    margin-bottom: 0;
    margin-right: auto;
}

#reset-confirm .reset-dialog.closing {
    animation: splashClose 220ms ease-out forwards;
}

#draft-screen.closing,
#game-over.closing {
    animation: splashClose 220ms ease-out forwards;
}
@keyframes splashClose {
    0% { transform: scaleY(1); opacity: 1; }
    100% { transform: scaleY(1.5); opacity: 0; }
}

@media (pointer: coarse) {
    .icon-btn, .corner-btn { width: 60px; height: 60px; line-height: 60px; }
    .control-btn { width: 56px; height: 56px; }
    .mega-btn { padding: 24px 46px; }
    .secondary-btn { padding: 18px 24px; }
    .shop-item, .card { padding: 14px; }
}

@media (max-width: 480px) {
    .icon-btn.right { left: calc(50% + 130px); }
}

#accessibility-modal input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    height: 6px;
    border-radius: 3px;
    background: linear-gradient(to right, var(--neon-blue) 0%, var(--neon-blue) var(--fill, 0%), rgba(255,255,255,0.08) var(--fill, 0%), rgba(255,255,255,0.08) 100%),
                repeating-linear-gradient(to right, rgba(255,255,255,0.35) 0, rgba(255,255,255,0.35) 1px, transparent 1px, transparent calc(25% - 1px));
    box-shadow: none;
}

#accessibility-modal input[type="range"]:hover {
    box-shadow: none;
}

#accessibility-modal input[type="range"]::-webkit-slider-runnable-track {
    height: 6px;
    border-radius: 3px;
    background: linear-gradient(to right, #ffff00 0%, #ffff00 var(--fill, 0%), rgba(255,255,255,0.08) var(--fill, 0%), rgba(255,255,255,0.08) 100%),
                repeating-linear-gradient(to right, rgba(255,255,255,0.35) 0, rgba(255,255,255,0.35) 1px, transparent 1px, transparent calc(25% - 1px));
    box-shadow: none;
}
#accessibility-modal input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px; height: 18px;
    border-radius: 50%;
    background: var(--neon-pink);
    border: 2px solid #fff;
    margin-top: -6px; 
    box-shadow: 0 0 8px rgba(255,0,255,0.4);
}
#accessibility-modal input[type="range"]::-webkit-slider-thumb:hover {
    box-shadow: 0 0 8px rgba(255,0,255,0.4);
}

#accessibility-modal input[type="range"]::-moz-range-track {
    height: 6px;
    border-radius: 3px;
    background: linear-gradient(to right, #ffff00 0%, #ffff00 var(--fill, 0%), rgba(255,255,255,0.08) var(--fill, 0%), rgba(255,255,255,0.08) 100%),
                repeating-linear-gradient(to right, rgba(255,255,255,0.35) 0, rgba(255,255,255,0.35) 1px, transparent 1px, transparent calc(25% - 1px));
    box-shadow: none;
}
#accessibility-modal input[type="range"]::-moz-range-progress {
    height: 6px;
    border-radius: 3px;
    background: #ffff00;
}
#accessibility-modal input[type="range"]::-moz-range-thumb {
    width: 18px; height: 18px;
    border-radius: 50%;
    background: var(--neon-pink);
    border: 2px solid #fff;
}

#accessibility-modal input[type="range"]::-ms-track {
    height: 6px;
    border-radius: 3px;
    background: transparent;
    color: transparent;
    border: none;
}
#accessibility-modal input[type="range"]::-ms-fill-lower {
    background: #ffff00;
    border-radius: 3px;
}
#accessibility-modal input[type="range"]::-ms-fill-upper {
    background: rgba(255,255,255,0.08);
    border-radius: 3px;
}

#accessibility-modal input[type="range"] { cursor: pointer; }

#accessibility-modal input[type="range"]::-webkit-slider-thumb:hover {
    box-shadow: 0 0 14px rgba(255,0,255,0.65), 0 0 22px rgba(255,0,255,0.35);
    transform: scale(1.12);
}
#accessibility-modal input[type="range"]:hover::-webkit-slider-runnable-track {
    background-image: repeating-linear-gradient(to right, rgba(255,255,0,0.65) 0, rgba(255,255,0,0.65) 1px, transparent 1px, transparent calc(25% - 1px));
}

#accessibility-modal input[type="range"]::-moz-range-thumb:hover {
    box-shadow: 0 0 14px rgba(255,0,255,0.65), 0 0 22px rgba(255,0,255,0.35);
    transform: scale(1.12);
}
#accessibility-modal input[type="range"]:hover::-moz-range-track {
    background-image: repeating-linear-gradient(to right, rgba(255,255,0,0.65) 0, rgba(255,255,0,0.65) 1px, transparent 1px, transparent calc(25% - 1px));
}

#accessibility-modal input[type="range"]:focus-visible {
    outline: 2px solid var(--neon-blue);
    outline-offset: 4px;
}

.player-shield-ring {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 120px;
    height: 120px;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    pointer-events: none;
    z-index: 2;
    opacity: 0.85;
    background: radial-gradient(circle at 50% 50%, #ff00ff 0%, #ffff00 60%, #00ffff 100%);
    box-shadow: 0 0 32px #ff00ff, 0 0 32px #ffff00, 0 0 32px #00ffff;
    mix-blend-mode: screen;
    animation: shieldPulse 1.8s infinite;
}
@keyframes shieldPulse {
    0% { transform: translate(-50%, -50%) scale(1.0); }
    50% { transform: translate(-50%, -50%) scale(1.08); }
    100% { transform: translate(-50%, -50%) scale(1.0); }
}

.enemy-timewarp {
    filter: drop-shadow(0 0 16px #ff00ff) drop-shadow(0 0 12px #00ffff) drop-shadow(0 0 8px #ffff00);
    animation: timeWarpGlow 1.2s infinite alternate;
}
@keyframes timeWarpGlow {
    0% { filter: drop-shadow(0 0 16px #ff00ff) drop-shadow(0 0 12px #00ffff) drop-shadow(0 0 8px #ffff00); }
    100% { filter: drop-shadow(0 0 24px #ff00ff) drop-shadow(0 0 18px #00ffff) drop-shadow(0 0 12px #ffff00); }
}