:root {
            --bg-color: #121212;
            --surface-color: #1e1e1e;
            --board-border: #333;
            --square-dark: #2c2c2c;
            --square-light: #424242;
            --highlight: #4caf50;
            --text-color: #e0e0e0;
            --piece-red: #e53935;
            --piece-white: #f5f5f5;
            --shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
        }

        body {
            margin: 0;
            padding: 0;
            background-color: var(--bg-color);
            color: var(--text-color);
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            min-height: 100vh;
        }

        h1 {
            margin-bottom: 3px;
            font-weight: 200;
            letter-spacing: 2px;
        }

        .status-bar {
            margin-bottom: 20px;
            display: flex;
            gap: 20px;
            font-size: 1.2rem;
            background: var(--surface-color);
            padding: 10px 20px;
            border-radius: 8px;
            box-shadow: var(--shadow);
        }

        #turn-indicator {
            font-weight: bold;
            color: var(--highlight);
        }

        .game-container {
            position: relative;
            padding: 10px;
            background: var(--surface-color);
            border-radius: 4px;
            box-shadow: var(--shadow);
        }

        #board {
            display: grid;
            grid-template-columns: repeat(8, 60px);
            grid-template-rows: repeat(8, 60px);
            border: 4px solid var(--board-border);
            user-select: none;
        }

        .square {
            width: 60px;
            height: 60px;
            display: flex;
            justify-content: center;
            align-items: center;
        }

        .square.light {
            background-color: var(--square-light);
        }

        .square.dark {
            background-color: var(--square-dark);
        }

        .square.highlight {
            background-color: rgba(76, 175, 80, 0.3);
            cursor: pointer;
            position: relative;
        }
        
        .square.highlight::after {
            content: '';
            width: 15px;
            height: 15px;
            background-color: var(--highlight);
            border-radius: 50%;
            opacity: 0.6;
        }

        .piece {
            width: 45px;
            height: 45px;
            border-radius: 50%;
            box-shadow: inset 0 3px 3px rgba(255,255,255,0.2), 
                        inset 0 -3px 3px rgba(0,0,0,0.2),
                        0 2px 5px rgba(0,0,0,0.7);
            position: relative;
            transition: transform 0.2s;
            cursor: pointer;
        }

        .piece.red {
            background: radial-gradient(circle at 50% 40%, #ff6f60, var(--piece-red));
            border: 2px solid #b71c1c;
        }

        .piece.white {
            background: radial-gradient(circle at 50% 40%, #ffffff, var(--piece-white));
            border: 2px solid #bdbdbd;
        }

        .piece.king::after {
            content: '♔';
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            font-size: 24px;
            color: rgba(0,0,0,0.6);
        }

        .piece.selected {
            transform: scale(1.1);
            box-shadow: 0 0 10px var(--highlight);
            z-index: 10;
        }

        button {
            margin-top: 20px;
            padding: 10px 25px;
            background-color: var(--surface-color);
            color: var(--text-color);
            border: 1px solid var(--board-border);
            border-radius: 4px;
            cursor: pointer;
            font-size: 1rem;
            transition: background 0.2s;
        }

        button:hover {
            background-color: #333;
        }

        .title-container {
            display: flex;
    align-items: flex-end;
    justify-content: space-between;
    width: 488px;
            margin-bottom: 10px;
        }

        .title-container h1 {
            margin-bottom: 0;
        }

        .title-container button {
            margin-top: 0;
            font-size: 0.9rem;
            padding: 8px 15px;
        }

        @media (max-width: 550px) {
    .title-container {
        width: calc(88vw + 8px);
    }
            #board {
                grid-template-columns: repeat(8, 11vw);
                grid-template-rows: repeat(8, 11vw);
            }
            .square {
                width: 11vw;
                height: 11vw;
            }
            .piece {
                width: 8vw;
                height: 8vw;
            }
        }