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

:root {
    --bg-color: #0a0a0a;
    --text-color: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --shadow-color: rgba(0, 0, 0, 0.8);
}

:root.light {
    --bg-color: #f5f5f5;
    --text-color: #0a0a0a;
    --text-secondary: rgba(0, 0, 0, 0.6);
    --shadow-color: rgba(255, 255, 255, 0.8);
}

body, html {
    height: 100%;
    width: 100%;
    overflow: hidden;
    font-family: 'Helvetica Neue Light', 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--bg-color);
}

#gameCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
    touch-action: none;
}

.overlay {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 10;
    color: var(--text-color);
    pointer-events: none;
    text-shadow: 0 2px 10px var(--shadow-color);
}

.title {
    font-size: 64px;
    margin-bottom: 20px;
    font-weight: 300;
    letter-spacing: 4px;
}

.subtitle {
    font-size: 20px;
    color: var(--text-secondary);
    font-weight: 300;
    letter-spacing: 1px;
}

.sim-refresh {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 100;
    background: transparent;
    border: none;
    color: var(--text-color);
    padding: 10px;
    cursor: pointer;
    transition: opacity 0.3s ease;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.sim-refresh:hover {
    opacity: 0.7;
}

.sim-refresh:active {
    opacity: 0.5;
    transform: rotate(180deg);
}

.sim-refresh .icon {
    width: 24px;
    height: 24px;
    transition: transform 0.3s ease;
}

.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 100;
    background: transparent;
    border: none;
    color: var(--text-color);
    padding: 10px;
    cursor: pointer;
    transition: opacity 0.3s ease;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.theme-toggle:hover {
    opacity: 0.7;
}

.theme-toggle:active {
    opacity: 0.5;
}

.theme-toggle .icon {
    width: 24px;
    height: 24px;
    transition: transform 0.3s ease;
}

.theme-toggle .moon {
    display: none;
}

:root.light .theme-toggle .sun {
    display: none;
}

:root.light .theme-toggle .moon {
    display: block;
}
