:root {
    --neon-green: #00ff80;
    --deep-purple: #1a0b2e;
    --gold: #ffcc00;
    --glass: rgba(255, 255, 255, 0.1);
}

* {
    margin: 0; padding: 0; box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

body {
    background: #050505;
    height: 100vh;
    display: flex; align-items: center; justify-content: center;
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    overflow: hidden;
}

/* App Wrapper: Meniru Frame HP di Desktop */
#app-wrapper {
    width: 100%; height: 100%;
    max-width: 430px; /* iPhone 15 Pro Max Width */
    max-height: 932px;
    background: var(--deep-purple);
    position: relative;
    overflow: hidden;
    box-shadow: 0 0 50px rgba(0,0,0,0.8), 0 0 20px rgba(0, 255, 128, 0.1);
}

#game-container { width: 100%; height: 100%; position: relative; }

canvas { width: 100%; height: 100%; display: block; }

/* UI Screens */
.ui-screen {
    position: absolute; inset: 0;
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    background: var(--deep-purple);
    z-index: 10;
    transition: opacity 0.5s ease, visibility 0.5s;
    visibility: hidden; opacity: 0;
}

.ui-screen.active { visibility: visible; opacity: 1; }

/* Rune Loader Visual */
.rune-loader {
    position: relative; width: 150px; height: 150px;
    margin-bottom: 20px;
}

.rune-loader svg { transform: rotate(-90deg); }

.rune-bg { fill: none; stroke: rgba(255,255,255,0.05); stroke-width: 5; }

.rune-fill {
    fill: none; stroke: var(--neon-green); stroke-width: 5;
    stroke-dasharray: 283; /* 2 * PI * R (45) */
    stroke-dashoffset: 283;
    transition: stroke-dashoffset 0.1s linear;
    filter: drop-shadow(0 0 8px var(--neon-green));
}

#load-pct {
    position: absolute; top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.5rem; font-weight: bold; color: white;
}

.hidden { display: none !important; }