* {
            box-sizing: border-box;
            user-select: none;
        }
        body {
            background: #2a2a2a;
            display: flex;
            justify-content: center;
            align-items: center;
            min-height: 100vh;
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            margin: 0;
            padding: 20px;
        }
        .game-container {
            background: #1e1e1e;
            border-radius: 20px;
            padding: 15px;
            box-shadow: 0 10px 30px rgba(0,0,0,0.7);
        }
        #hex-board {
            display: block;
            width: 100%;
            height: auto;
            background: #2d2d2d;
            border-radius: 15px;
            box-shadow: inset 0 0 0 2px #4a4a4a;
        }
        .controls {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-top: 25px;
            color: #ddd;
            gap: 20px;
            flex-wrap: wrap;
        }
        .mode-selector {
            display: flex;
            gap: 15px;
            background: #333;
            padding: 10px 15px;
            border-radius: 40px;
        }
        .mode-btn {
            background: transparent;
            border: none;
            color: #aaa;
            font-size: 16px;
            padding: 8px 18px;
            border-radius: 30px;
            cursor: pointer;
            transition: all 0.2s;
            font-weight: 600;
        }
        .mode-btn.active {
            background: #ffd966;
            color: #1e1e1e;
            box-shadow: 0 0 10px #ffb347;
        }
        .turn-indicator {
            font-size: 20px;
            font-weight: bold;
            background: #333;
            padding: 10px 25px;
            border-radius: 40px;
            border-left: 5px solid #ffd966;
        }
        .reset-btn, .ai-btn, .color-btn {
            background: #ffd966;
            border: none;
            color: #1e1e1e;
            font-size: 18px;
            padding: 10px 30px;
            border-radius: 40px;
            font-weight: bold;
            cursor: pointer;
            transition: 0.2s;
            box-shadow: 0 4px 0 #b38f40;
        }
        .ai-btn.active {
            background: #6bff6b;
            box-shadow: 0 4px 0 #2b8f2b;
        }
        .color-btn {
            background: #b58863;
            box-shadow: 0 4px 0 #6b4f3a;
            padding: 8px 20px;
            font-size: 16px;
        }
        .color-btn.active {
            background: #ffd966;
            box-shadow: 0 4px 0 #b38f40;
        }
        .reset-btn:active, .ai-btn:active, .color-btn:active {
            transform: translateY(4px);
            box-shadow: none;
        }
        .hex {
            stroke: #3a3a3a;
            stroke-width: 1.5;
            transition: all 0.15s;
            cursor: pointer;
            filter: drop-shadow(0 2px 2px rgba(0,0,0,0.5));
        }
        .hex:hover {
            filter: brightness(1.2) drop-shadow(0 0 5px gold);
        }
        .hex1 { fill: #f0d9b5; }
        .hex2 { fill: #b58863; }
        .hex3 { fill: #8b5a2b; }
        .hex.selected {
            filter: brightness(1.4) drop-shadow(0 0 8px white);
            stroke: white;
            stroke-width: 2.5;
        }
        .hex.move {
            stroke: #ffff00 !important;
            stroke-width: 4;
            filter: drop-shadow(0 0 8px yellow);
        }
        .hex.capture {
            stroke: #ff00ff !important;
            stroke-width: 4;
            filter: drop-shadow(0 0 8px magenta);
        }
        .hex.ally {
            stroke: #00ffff !important;
            stroke-width: 4;
            filter: drop-shadow(0 0 8px cyan);
        }
        .piece-text {
            font-size: 22px;
            font-weight: bold;
            text-anchor: middle;
            dominant-baseline: middle;
            pointer-events: none;
            filter: drop-shadow(0 2px 2px black);
        }
        .white-piece { fill: #ffffff; }
        .black-piece { fill: #222222; }
        .grey-piece { fill: #888; }
        .red-piece { fill: #ff4d4d; }
        .blue-piece { fill: #4da6ff; }
        .green-piece { fill: #6bff6b; }
        .yellow-piece { fill: #ffff99; }
        .darkred-piece { fill: #8b0000; }
        .lightblue-piece { fill: #add8e6; }
        .lightgreen-piece { fill: #90ee90; }
        .color-panel {
            display: flex;
            gap: 10px;
            margin-left: 10px;
        }