/* Galaxy Assault - Playmix Games */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;700;900&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: 'Outfit', sans-serif;
    background: #030712;
    color: #fff;
    overflow-x: hidden;
}

#game-wrapper {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 100vh;
    background: radial-gradient(ellipse at top, #0f172a 0%, #030712 80%);
    overflow: hidden;
}

#game-canvas {
    display: block;
    cursor: crosshair;
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 4px;
    box-shadow: 0 0 40px rgba(59, 130, 246, 0.15);
    background: #030712;
    touch-action: none;
    margin-top: 60px;
    margin-bottom: 60px; /* Space for bottom ad (50px banner + 10px gap) */
}

/* ─── HUD ─────────────────────────────────────────── */
#ui-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    flex-direction: column;
    background: rgba(3, 7, 18, 0.9);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid rgba(59, 130, 246, 0.2);
}

#score-board {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    padding: 8px 16px;
}

/* Enemy kill progress strip */
#enemy-bar-track {
    width: 100%;
    height: 4px;
    background: rgba(255,255,255,0.1);
}

#enemy-progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #f43f5e, #facc15, #4ade80);
    transition: width 0.3s ease;
    box-shadow: 0 0 8px rgba(250,204,21,0.6);
}

/* Urgency pulse on kill-pill */
#enemies-pill.urgent {
    animation: killUrgent 0.5s infinite alternate;
    border-left-color: #ff0040 !important;
}
@keyframes killUrgent {
    from { background: rgba(0,0,0,0.5); box-shadow: none; }
    to   { background: rgba(244,63,94,0.45); box-shadow: 0 0 10px rgba(244,63,94,0.7); }
}

.hud-item {
    font-size: 0.85rem;
    font-weight: 700;
    padding: 5px 12px;
    border-radius: 20px;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    gap: 6px;
    color: white;
    letter-spacing: 0.3px;
}

.highlight-pill.yellow { border-left: 3px solid #facc15; }
.highlight-pill.blue   { border-left: 3px solid #3b82f6; }
.highlight-pill.red    { border-left: 3px solid #f43f5e; }
.highlight-pill.green  { border-left: 3px solid #4ade80; }

.highlight-pill.red.urgent {
    animation: urgentFlash 0.8s infinite alternate;
}
@keyframes urgentFlash {
    from { background: rgba(0,0,0,0.5); }
    to   { background: rgba(244,63,94,0.35); }
}

/* ─── OVERLAYS ─────────────────────────────────────── */
.overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 5000;
    backdrop-filter: blur(14px);
}

.overlay.hidden { display: none !important; }

.overlay-box {
    background: linear-gradient(145deg, #0f172a, #1e1b4b);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 20px;
    padding: 36px 32px;
    text-align: center;
    max-width: 400px;
    width: 92%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7), 0 0 40px rgba(59, 130, 246, 0.1);
    color: white;
}

.pmg-btn {
    background: linear-gradient(90deg, #3b82f6, #8b5cf6);
    color: #fff;
    border: none;
    padding: 13px 36px;
    font-size: 1.05rem;
    font-weight: 900;
    border-radius: 30px;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(59, 130, 246, 0.4);
    transition: transform 0.2s, box-shadow 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-family: 'Outfit', sans-serif;
}
.pmg-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(59, 130, 246, 0.6);
}
.pmg-btn.hidden { display: none !important; }

/* ─── INFO SECTIONS ────────────────────────────────── */
.game-info {
    background: #070d1a;
    padding: 40px 20px;
    border-top: 1px solid rgba(255,255,255,0.06);
}

.info-container {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    max-width: 900px;
    margin: 0 auto;
}

.info-card {
    flex: 1 1 280px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 16px;
    padding: 24px;
}

.info-card h2 {
    font-size: 1.15rem;
    font-weight: 900;
    color: #60a5fa;
    margin-bottom: 14px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.info-content p { color: #94a3b8; line-height: 1.7; margin-bottom: 10px; font-size: 0.92rem; }
.info-content ul { padding-left: 18px; color: #94a3b8; }
.info-content ul li { margin-bottom: 8px; line-height: 1.6; font-size: 0.92rem; }
.info-content strong { color: #e2e8f0; }

/* ─── Responsive ─────────────────────────────────── */
@media (max-width: 600px) {
    #game-canvas { margin-top: 52px; }
    .hud-item { font-size: 0.75rem; padding: 4px 8px; }
    .pmg-btn { padding: 11px 26px; font-size: 0.95rem; }
}
