* { box-sizing: border-box; margin: 0; padding: 0; }
body {
    background: radial-gradient(circle at center, #1a1a2e 0%, #0f0f1a 100%);
    color: white;
    font-family: 'Inter', sans-serif;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.container {
    display: flex;
    gap: 30px;
    max-width: 1300px;
    width: 100%;
    flex-wrap: wrap;
    align-items: flex-start;
}

.glass-panel, .glass-board {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
    border-radius: 15px;
    padding: 20px;
}

.sidebar { flex: 1; min-width: 260px; max-width: 320px; }
.board-wrapper { flex: 2; display: flex; justify-content: center; min-width: 450px;}
.sidebar-right { flex: 1; min-width: 260px; max-width: 320px; height: 600px; display: flex; flex-direction: column;}

h1, h2 { font-size: 22px; margin-bottom: 20px; text-transform: uppercase; letter-spacing: 2px;}
.neon-text { color: #ff00fc; text-shadow: 0 0 10px #ff00fc; }

.top-dashboard { display: flex; justify-content: space-between; margin-bottom: 15px; font-size: 14px;}
.score-board { display: flex; flex-direction: column; gap: 5px; font-weight: bold;}
.p1-score { color: #00f3ff; }
.p2-score { color: #ff00fc; }
.timer-box { font-family: monospace; font-size: 18px; color: #ffeb3b; background: rgba(0,0,0,0.3); padding: 5px 10px; border-radius: 5px;}

.status-box {
    background: rgba(0, 243, 255, 0.1);
    border-left: 4px solid #00f3ff;
    padding: 10px;
    margin-bottom: 20px;
    font-weight: bold;
    transition: 0.3s;
}

.control-group { margin-bottom: 15px; }
.control-group label { display: block; margin-bottom: 5px; font-size: 14px; color: #aaa;}
input[type="number"], .glass-select {
    width: 100%; padding: 8px; background: rgba(0,0,0,0.4); border: 1px solid #444; color: white; border-radius: 5px; cursor: pointer;
}

.switch-group { display: flex; justify-content: space-between; align-items: center; }
.switch { position: relative; display: inline-block; width: 50px; height: 24px; }
.switch input { opacity: 0; width: 0; height: 0; }
.slider { position: absolute; cursor: pointer; top: 0; left: 0; right: 0; bottom: 0; background-color: #333; transition: .4s; border-radius: 24px; }
.slider:before { position: absolute; content: ""; height: 18px; width: 18px; left: 3px; bottom: 3px; background-color: white; transition: .4s; border-radius: 50%; }
input:checked + .slider { background-color: #ff00fc; }
input:checked + .slider:before { transform: translateX(26px); }

.stats-box { margin-top: 30px; text-align: center; background: rgba(0,0,0,0.3); padding: 15px; border-radius: 10px;}
.stats-box h2 { font-size: 32px; margin-top: 10px; }

.glass-btn { width: 100%; padding: 12px; margin-top: 15px; background: transparent; border: 1px solid #00f3ff; color: #00f3ff; font-weight: bold; cursor: pointer; border-radius: 5px; transition: 0.3s; }
.glass-btn:hover { background: #00f3ff; color: #000; box-shadow: 0 0 15px #00f3ff; }

.glass-btn-danger { width: 100%; padding: 8px; margin-top: 10px; background: transparent; border: 1px solid #ff4444; color: #ff4444; font-size: 12px; cursor: pointer; border-radius: 5px; transition: 0.3s; }
.glass-btn-danger:hover { background: #ff4444; color: #000; }

.log-container { flex: 1; background: rgba(0,0,0,0.4); border-radius: 5px; padding: 10px; overflow-y: auto; font-family: monospace; font-size: 12px; display: flex; flex-direction: column; gap: 8px;}
.log-item { border-bottom: 1px solid rgba(255,255,255,0.05); padding-bottom: 5px; word-wrap: break-word;}

.glass-board {
    display: grid;
    grid-template-columns: repeat(7, 60px);
    grid-template-rows: repeat(6, 60px);
    gap: 10px;
    background: rgba(30, 30, 50, 0.6);
}

.cell {
    width: 60px; height: 60px;
    background: #0f0f1a;
    border-radius: 50%;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.8);
    cursor: pointer;
    transition: background 0.3s;
}
.cell:hover { background: rgba(255,255,255,0.05); }

.cell.player {
    background: #00f3ff;
    box-shadow: 0 0 15px #00f3ff, inset 0 0 10px rgba(255,255,255,0.5);
    animation: dropInBounce 0.6s cubic-bezier(0.28, 0.84, 0.42, 1) forwards;
}
.cell.ai {
    background: #ff00fc;
    box-shadow: 0 0 15px #ff00fc, inset 0 0 10px rgba(255,255,255,0.5);
    animation: dropInBounce 0.6s cubic-bezier(0.28, 0.84, 0.42, 1) forwards;
}

.win-pulse {
    animation: winnerPulse 1s infinite alternate;
}

@keyframes dropInBounce {
    0% { transform: translateY(-400px); opacity: 0; }
    50% { transform: translateY(0); opacity: 1; }
    70% { transform: translateY(-25px); }
    85% { transform: translateY(0); }
    95% { transform: translateY(-8px); }
    100% { transform: translateY(0); }
}

@keyframes winnerPulse {
    0% { transform: scale(1); filter: brightness(1); }
    100% { transform: scale(1.15); filter: brightness(1.5); }
}

@media (max-width: 1000px) {
    .container { flex-direction: column; align-items: center;}
    .sidebar, .sidebar-right, .board-wrapper { width: 100%; max-width: 500px; }
    .sidebar-right { height: 250px; }
}

/* ... Biarkan CSS lama kamu di atas, tambahkan ini di baris paling bawah ... */

/* DUAL COUNTER STYLE */
.counter-compare { display: flex; justify-content: space-around; margin-top: 10px; margin-bottom: 15px; font-size: 14px;}
.neon-cyan { color: #00f3ff; font-weight: bold; font-size: 24px; text-shadow: 0 0 10px #00f3ff;}
.neon-magenta { color: #ff00fc; font-weight: bold; font-size: 24px; text-shadow: 0 0 10px #ff00fc;}

.glass-btn-tree { width: 100%; padding: 8px; background: rgba(255,255,255,0.1); border: 1px solid #fff; color: #fff; font-size: 14px; cursor: pointer; border-radius: 5px; transition: 0.3s; font-weight: bold;}
.glass-btn-tree:hover { background: #fff; color: #000; box-shadow: 0 0 15px #fff; }

/* MODAL GAME TREE */
.modal { display: none; position: fixed; z-index: 100; left: 0; top: 0; width: 100%; height: 100%; background-color: rgba(0,0,0,0.8); backdrop-filter: blur(10px); }
.modal-content { margin: 2% auto; padding: 20px; width: 95%; max-width: 1200px; max-height: 90vh; overflow: auto; position: relative; background: #0f0f1a;}
.close-btn { color: #aaa; float: right; font-size: 32px; font-weight: bold; cursor: pointer; position: absolute; right: 20px; top: 10px;}
.close-btn:hover { color: #fff; }

/* PRUNING HIGHLIGHT ANIMATION (SYARAT BONUS NO 10) */
.pruned-highlight {
    animation: pruneFlash 1.2s ease-out;
}

@keyframes pruneFlash {
    0% { box-shadow: 0 0 20px #ff4444, inset 0 0 20px #ff4444; background: rgba(255, 68, 68, 0.6); }
    100% { box-shadow: inset 0 0 10px rgba(0,0,0,0.8); background: #0f0f1a; }
}