* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.game-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 10px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Üst Kısım: Masa */
.table-area {
    width: 100%;
    padding: 10px 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.game-table {
    width: min(350px, 90vw);
    height: min(350px, 90vw);
    background: radial-gradient(circle, #8B4513 0%, #654321 100%);
    border-radius: 50%;
    position: relative;
    border: 8px solid #4a2c17;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.table-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(255, 255, 255, 0.9);
    border-radius: 15px;
    padding: 15px;
    text-align: center;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    min-width: 180px;
}

.round-info {
    font-size: 1.2rem;
    font-weight: bold;
    color: #333;
    margin-bottom: 8px;
}

.target-info {
    font-size: 1rem;
    color: #666;
    margin-bottom: 8px;
}

.guess-input-area {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 8px;
    gap: 8px;
}

.table-guess-input {
    width: 80px;
    padding: 8px;
    text-align: center;
    border: 2px solid #9c27b0;
    border-radius: 8px;
    font-size: 1rem;
    background: white;
}

.table-guess-input.invalid {
    border-color: #f44336;
}

.table-submit-btn {
    background: linear-gradient(135deg, #9c27b0 0%, #7b1fa2 100%);
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 8px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.table-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 10px rgba(156, 39, 176, 0.4);
}

.table-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Orta Kısım: Oyun Alanı */
.game-area {
    display: flex;
    flex: 1;
    gap: 20px;
    flex-wrap: wrap;
    padding: 20px 0;
}

.control-panel {
    flex: 1;
    min-width: 300px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
}

.game-log {
    background: #f5f5f5;
    border-radius: 15px;
    padding: 15px;
    max-height: 200px;
    overflow-y: auto;
    border: 2px solid #ddd;
}

.log-title {
    font-weight: bold;
    color: #333;
    margin-bottom: 10px;
}

.log-item {
    margin: 5px 0;
    padding: 5px;
    border-radius: 5px;
    font-size: 0.9rem;
}

.log-round {
    background: #e3f2fd;
    color: #1976d2;
}

.log-result {
    background: #e8f5e8;
    color: #2e7d32;
}

.log-elimination {
    background: #ffebee;
    color: #c62828;
}

/* Header */
.header {
    text-align: center;
    color: white;
    margin-bottom: 10px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.header h1 {
    font-size: clamp(1.2rem, 4vw, 2rem);
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

/* Oyuncu Stilleri */
.player {
    position: absolute;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.8rem;
    font-weight: bold;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 3px solid rgba(255, 255, 255, 0.3);
}

.player.human {
    background: linear-gradient(135deg, #2196F3 0%, #1976D2 100%);
}

#player-1.bot { background: linear-gradient(135deg, #FF5722 0%, #E64A19 100%); } /* Turuncu */
#player-2.bot { background: linear-gradient(135deg, #4CAF50 0%, #388E3C 100%); } /* Yeşil */
#player-3.bot { background: linear-gradient(135deg, #9C27B0 0%, #7B1FA2 100%); } /* Mor */
#player-4.bot { background: linear-gradient(135deg, #FFC107 0%, #FFA000 100%); } /* Altın */

.player.eliminated {
    opacity: 0.6;
    transform: scale(0.8);
}

.player.eliminated::after {
    content: '✗';
    position: absolute;
    font-size: 2rem;
    color: white;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.player.winner {
    animation: winner-pulse 1s infinite;
    box-shadow: 0 0 30px rgba(255, 215, 0, 0.8);
}

@keyframes winner-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.player-name {
    font-size: 0.7rem;
    margin-bottom: 2px;
}

.player-health {
    font-size: 0.6rem;
    opacity: 0.9;
}

.player-guess {
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 4px 8px;
    border-radius: 10px;
    font-size: 0.7rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.player-guess.show {
    opacity: 1;
}

/* Kurallar Kutusu */
.rules-box {
    position: fixed;
    top: 80px;
    right: 20px;
    width: 300px;
    max-height: calc(100vh - 120px);
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
    border-radius: 15px;
    padding: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    z-index: 99;
    overflow-y: auto;
}

.rules-title {
    font-weight: bold;
    color: #1976D2;
    margin-bottom: 10px;
    font-size: 1.1rem;
    text-align: center;
}

.rule-item {
    margin: 5px 0;
    font-size: 0.9rem;
    padding: 8px;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.rule-item.active {
    color: #1976D2;
    background-color: #e3f2fd;
    border-left: 4px solid #2196F3;
}

.rule-item.inactive {
    color: #9E9E9E;
    background-color: #F5F5F5;
    border-left: 4px solid #BDBDBD;
}

/* Kurallar Butonu */
.rules-toggle-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    font-size: 2rem;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #333;
}

.rules-toggle-btn:hover {
    background: rgba(255, 255, 255, 1);
}

/* Cihazı Döndür Mesajı */
#cihazi-dondur-mesaji {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    color: white;
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    z-index: 9999;
    font-size: 1.8em;
    padding: 20px;
    box-sizing: border-box;
}

#cihazi-dondur-mesaji p {
    margin: 10px 0;
    line-height: 1.4;
}

/* Oyun Bitti Overlay'i */
.game-over-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    display: none;
}

.game-over-content {
    background: white;
    border-radius: 20px;
    padding: 40px;
    text-align: center;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.game-over-button {
    display: block;
    width: 100%;
    padding: 15px;
    margin: 10px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 25px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.game-over-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}

/* Oyuncu Pozisyonları */
.player:nth-child(1) { top: -35px; left: 50%; transform: translateX(-50%); }
.player:nth-child(2) { top: 20%; right: -35px; }
.player:nth-child(3) { bottom: 20%; right: -35px; }
.player:nth-child(4) { bottom: -35px; left: 50%; transform: translateX(-50%); }
.player:nth-child(5) { top: 20%; left: -35px; }

/* Parlayan Daire Efekti */
.winner-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 4px solid gold;
    box-shadow: 0 0 20px gold;
    animation: ring-pulse 1.5s ease-in-out;
    pointer-events: none;
    z-index: 1;
}

@keyframes ring-pulse {
    0% { transform: scale(0.8); opacity: 0; }
    50% { transform: scale(1.2); opacity: 1; }
    100% { transform: scale(1.5); opacity: 0; }
}

@media (max-width: 600px) {
    #cihazi-dondur-mesaji { font-size: 1.4em; }
    .header h1 { font-size: 1.5rem; }
    .player { width: 55px; height: 55px; font-size: 0.7rem; }
    .player-name { font-size: 0.6rem; }
    .table-center { padding: 10px; min-width: 150px; }
    .table-guess-input { width: 70px; font-size: 0.9rem; }
    .table-submit-btn { padding: 6px 12px; font-size: 0.8rem; }
    .rules-box { width: 250px; }
}
