        body {
            margin: 0;
            padding: 0;
            height: 100vh;
            font-family: 'Helvetica Neue', Arial, 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', Meiryo, sans-serif;
            background-color: rgb(0, 0, 0);
            color: #ecf0f1;
            overflow: hidden;
            cursor: pointer;
            user-select: none;
            -webkit-user-select: none;
            transition: background-color 0.1s;
        }

        body::after {
            content: "";
            position: absolute;
            top: 0; left: 0; width: 100%; height: 100%;
            background-color: rgba(255, 0, 0, 0.4);
            opacity: 0;
            pointer-events: none;
            transition: opacity 0.1s ease-out;
            z-index: 100;
        }

        body.flash-error::after {
            opacity: 1;
            transition: none;
        }

        h1, h2, label, li, p {
            text-shadow: 0 2px 4px rgba(0,0,0,0.8);
        }

        #top-ui {
            text-align: center;
            position: absolute;
            top: 5%;
            width: 100%;
            z-index: 10;
            pointer-events: none;
        }

        h1 { margin: 0; font-size: 2rem; }

        #mode-switch {
            display: flex;
            justify-content: center;
            gap: 15px;
            margin-top: 15px;
            pointer-events: auto;
        }
        .mode-btn {
            padding: 8px 24px;
            background-color: transparent;
            color: #7f8c8d;
            border: 2px solid #7f8c8d;
            border-radius: 20px;
            cursor: pointer;
            font-size: 1rem;
            font-weight: bold;
            transition: all 0.2s;
            outline: none;
            box-shadow: 0 2px 4px rgba(0,0,0,0.5);
        }
        .mode-btn.active {
            background-color: #f1c40f;
            color: #2c3e50;
            border-color: #f1c40f;
            text-shadow: none;
        }

        #center-ui {
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            text-align: center;
            z-index: 10;
            pointer-events: none;
        }

        #start-btn {
            pointer-events: auto;
            padding: 15px 40px;
            font-size: 1.5rem;
            font-weight: bold;
            color: #fff;
            background-color: #3498db;
            border: none;
            border-radius: 8px;
            cursor: pointer;
            transition: transform 0.1s, background-color 0.2s;
            box-shadow: 0 6px 12px rgba(0,0,0,0.5);
        }
        #start-btn:hover { background-color: #2980b9; transform: scale(1.05); }

        #result { font-size: 1.5rem; display: none; margin-bottom: 20px;}
        .score { font-size: 3.5rem; font-weight: bold; color: #f1c40f; text-shadow: 0 4px 8px rgba(0,0,0,0.9); }

        #bottom-ui {
            position: absolute;
            bottom: 10%;
            width: 100%;
            text-align: center;
            pointer-events: none;
            z-index: 10;
            transition: opacity 0.3s;
        }
        #instruction-text {
            font-size: 1.1rem;
            color: #bdc3c7;
            margin: 0;
            font-weight: normal;
            letter-spacing: 0.05em;
        }

        #hamburger-btn {
            position: absolute;
            top: 15px;
            left: 20px;
            font-size: 2rem;
            cursor: pointer;
            z-index: 20; 
            pointer-events: auto;
            color: #fff;
            text-shadow: 0 2px 4px rgba(0,0,0,0.8);
            transition: transform 0.2s;
        }

        #settings-container {
            position: absolute;
            left: -300px;
            top: 0;
            height: 100vh;
            width: 250px;
            background-color: rgba(0, 0, 0, 0.85);
            padding: 70px 20px 20px 20px;
            box-sizing: border-box;
            z-index: 15;
            pointer-events: auto; 
            cursor: default;
            transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
            overflow-y: auto;
            border-right: 1px solid #34495e;
        }
        
        #settings-container.open { left: 0; }

        #settings-container h2 {
            margin: 0 0 15px 0;
            font-size: 1.2rem;
            border-bottom: 1px solid #7f8c8d;
            padding-bottom: 5px;
            text-align: center;
        }

        .setting-group { margin-bottom: 25px; }
        .setting-group label { display: block; margin-bottom: 5px; font-size: 0.9rem; }
        
        input[type="range"] { width: 100%; cursor: pointer; margin-bottom: 10px; }

        .color-preview {
            width: 100%; height: 30px;
            border-radius: 4px;
            border: 2px solid #fff;
            box-sizing: border-box; margin-top: 5px;
        }

        #history-container {
            position: absolute;
            right: 20px;
            top: 50%;
            transform: translateY(-50%);
            background-color: rgba(0, 0, 0, 0.6);
            padding: 15px;
            border-radius: 8px;
            z-index: 10;
            pointer-events: none;
            width: 150px;
        }

        #history-container h2 { margin: 0 0 10px 0; font-size: 1.2rem; border-bottom: 1px solid #7f8c8d; padding-bottom: 5px; text-align: center; }
        #history-list { list-style: none; padding: 0; margin: 0; font-size: 1.1rem; line-height: 1.8; font-family: monospace; }

        #target-circle {
            width: 80vmin;
            height: 80vmin;
            background-color: rgb(241, 196, 15);
            border-radius: 50%;
            position: absolute;
            top: 60%;
            left: 50%;
            transform: translate(-50%, -50%);
            box-shadow: 0 10px 30px rgba(0,0,0,0.5);
            display: none;
            z-index: 5;
            pointer-events: none;
        }
