* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    user-select: none;
}
body {
    background: #03050b;
    min-height: 100vh;
    min-width: 100vw;
    width: 100vw;
    height: 100vh;
    margin: 0;
    padding: 0;
    overflow: hidden;
    font-family: monospace;
}
.game-container {
    width: 100vw;
    height: 100vh;
    margin: 0;
    background: #03050b;
    border-radius: 0;
    overflow: hidden;
    box-shadow: none;
    display: flex;
    flex-direction: column;
}
.game-header {
    text-align: center;
    padding: 1rem 0 0.5rem;
    background: #0a0c16;
}
.glitch-title {
    font-size: clamp(1.6rem, 6vw, 2.8rem);
    font-weight: 900;
    background: linear-gradient(135deg, #ff6a6a, #ffb347, #ffff66, #6bff6b, #4d9eff, #c56aff);
    background-size: 300% auto;
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    animation: rainbow 2s linear infinite;
    letter-spacing: 3px;
    margin: 0;
}
@keyframes rainbow {
    0% { background-position: 0% 50%; }
    100% { background-position: 100% 50%; }
}
/* Ajout d'une marge visible autour du canvas */
.game-canvas-wrapper {
    position: relative;
    width: calc(100vw - 40px);
    height: calc(100vh - 40px);
    min-height: 0;
    background: #000;
    cursor: none;
    flex: 1 1 auto;
    margin: 20px;
    box-sizing: border-box;
    border-radius: 18px;
    box-shadow: 0 0 0 2px #222, 0 8px 32px #000a;
}
canvas {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: #000;
    border-radius: 16px;
}
.bottom-info {
    position: absolute;
    bottom: 15px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    pointer-events: none;
    z-index: 10;
}
.scores-panel {
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(6px);
    padding: 6px 15px;
    border-radius: 40px;
    font-weight: bold;
    color: #ffefcf;
    font-size: 1rem;
    pointer-events: auto;
    border: 1px solid #ffaa66;
}
.restart-btn {
    background: #ff9f4a;
    border: none;
    font-weight: bold;
    padding: 6px 16px;
    border-radius: 40px;
    cursor: pointer;
    font-family: monospace;
    font-size: 0.9rem;
    box-shadow: 0 2px 0 #9b4a00;
    pointer-events: auto;
    transition: 0.05s linear;
}
.restart-btn:active {
    transform: translateY(2px);
    box-shadow: none;
}
.effect-message {
    position: absolute;
    top: 100px;
    left: 0;
    right: 0;
    text-align: center;
    font-size: 1.2rem;
    font-weight: bold;
    color: #ffaa44;
    text-shadow: 0 0 5px black;
    pointer-events: none;
    z-index: 20;
    font-family: monospace;
}
@media (max-width: 700px) {
    .game-canvas-wrapper { height: 100vh; min-height: 0; }
    .scores-panel { font-size: 0.7rem; padding: 4px 10px; }
    .restart-btn { padding: 4px 12px; font-size: 0.7rem; }
    .effect-message { top: 70px; font-size: 1rem; }
}
