:root {
    --neon-cyan: #00f3ff;
    --neon-pink: #ff00ff;
    --neon-green: #0aff00;
    --bg-color: #050505;
}

body {
    margin: 0;
    padding: 0;
    overflow: hidden;
    background-color: var(--bg-color);
    font-family: 'Rajdhani', sans-serif;
    color: white;
}

#canvas-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

#ui-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    pointer-events: none; /* 让鼠标事件穿透到 Canvas */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 50px;
}

/* 允许 UI 元素接收点击 */
#ui-container > * {
    pointer-events: auto;
}

h1.glitch {
    font-family: 'Press Start 2P', cursive;
    font-size: 3rem;
    color: white;
    text-transform: uppercase;
    position: relative;
    text-shadow: 
        2px 2px var(--neon-pink),
        -2px -2px var(--neon-cyan);
    animation: glitch-anim 2s infinite linear alternate-reverse;
    margin-bottom: 10px;
}

@keyframes glitch-anim {
    0% { clip-path: inset(10% 0 80% 0); transform: translate(-2px, 2px); }
    20% { clip-path: inset(80% 0 10% 0); transform: translate(2px, -2px); }
    40% { clip-path: inset(40% 0 50% 0); transform: translate(-2px, 2px); }
    60% { clip-path: inset(10% 0 60% 0); transform: translate(2px, -2px); }
    80% { clip-path: inset(70% 0 20% 0); transform: translate(-2px, 2px); }
    100% { clip-path: inset(20% 0 70% 0); transform: translate(2px, -2px); }
}

.subtitle {
    color: var(--neon-green);
    font-size: 1.2rem;
    letter-spacing: 4px;
    margin-bottom: 40px;
    text-shadow: 0 0 10px var(--neon-green);
}

.controls {
    position: fixed;
    left: 50%;
    bottom: 30px;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    background: rgba(0, 0, 0, 0.7);
    padding: 16px 20px;
    border: 1px solid var(--neon-cyan);
    box-shadow: 0 0 20px rgba(0, 243, 255, 0.2);
    backdrop-filter: blur(5px);
    z-index: 10;
}

input {
    background: transparent;
    border: none;
    border-bottom: 2px solid var(--neon-pink);
    color: white;
    font-family: 'Rajdhani', sans-serif;
    font-size: 1.2rem;
    padding: 5px 10px;
    width: 200px;
    outline: none;
}

button {
    background: var(--neon-cyan);
    color: black;
    border: none;
    padding: 10px 20px;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 0 10px var(--neon-cyan);
}

button:hover {
    background: white;
    box-shadow: 0 0 20px white;
    transform: scale(1.05);
}

.instructions {
    position: absolute;
    bottom: 30px;
    left: 30px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    line-height: 1.6;
    border-left: 2px solid var(--neon-pink);
    padding-left: 15px;
}

@media (max-width: 600px) {
    h1.glitch { font-size: 1.5rem; }
    .controls { flex-direction: column; }
}
