/* 🏠 IT Games Core - Shared Base Styles */

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

body,
html {
    width: 100%;
    height: 100%;
    overflow: hidden;
    font-family: 'Comfortaa', sans-serif;
    background-color: var(--bg-color, #f4f4f4);
}

#game-container {
    position: relative;
    width: 100%;
    height: 100%;
    background: #fff;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

canvas {
    width: 100%;
    flex: 1;
    display: block;
    cursor: grab;
}

canvas:active {
    cursor: grabbing;
}

/* 📊 Topbar Overlay */
.game-overlay {
    position: relative;
    width: 100%;
    padding-top: calc(env(safe-area-inset-top, 0px) + 10px);
    background: #ffffff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-left: 20px;
    padding-right: 20px;
    padding-bottom: 10px;
    z-index: 1000;
}

#game-reset-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--primary);
    padding: 8px;
    border-radius: 50%;
    margin-right: -8px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

#game-reset-btn:hover {
    background: rgba(0, 0, 0, 0.05);
    transform: rotate(45deg);
}

#game-reset-btn svg {
    display: block;
}

.stats-section {
    font-family: 'Comfortaa', sans-serif;
    color: var(--primary);
    font-weight: 700;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.stat-item {
    background: rgba(71, 28, 168, 0.08);
    /* Using primary color with alpha is better done via JS or fallback */
    padding: 6px 12px;
    border-radius: 12px;
    font-size: 13px;
    white-space: nowrap;
}

@media (max-width: 400px) {
    .stats-section {
        gap: 8px;
    }
}