body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
    color: #333;
    line-height: 1.6;
}

header {
    background-color: #333;
    color: #fff;
    padding: 1rem 0;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

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

header p {
    margin: 0.5rem 0 0;
    font-size: 1rem;
    opacity: 0.8;
}

main {
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.game-container {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 20px;
    margin: 20px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.game-options {
    width: 100%;
    max-width: 500px;
    margin-bottom: 20px;
}

.mode-selector {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 15px;
}

.mode-button {
    background-color: #f0f0f0;
    border: 1px solid #ddd;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s;
    flex: 1;
    max-width: 200px;
}

.mode-button:hover {
    background-color: #e0e0e0;
}

.mode-button.active {
    background-color: #4CAF50;
    color: white;
    border-color: #4CAF50;
}

.difficulty-selector {
    text-align: center;
    margin-bottom: 15px;
}

.difficulty-selector p {
    margin: 0 0 10px;
    font-weight: bold;
}

.difficulty-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
}

.difficulty-button {
    background-color: #f0f0f0;
    border: 1px solid #ddd;
    padding: 8px 15px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s;
}

.difficulty-button:hover {
    background-color: #e0e0e0;
}

.difficulty-button.active {
    background-color: #2196F3;
    color: white;
    border-color: #2196F3;
}

.player-turn {
    text-align: center;
    font-size: 1.2rem;
    margin-bottom: 15px;
}

#current-player {
    font-weight: bold;
    color: #4CAF50;
}

.game-board {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3, 1fr);
    gap: 10px;
    width: 300px;
    height: 300px;
    margin: 0 auto 20px;
}

.cell {
    background-color: #f8f8f8;
    border: 2px solid #ddd;
    border-radius: 4px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 4rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
}

.cell:hover {
    background-color: #f0f0f0;
}

.cell.x {
    color: #4CAF50;
}

.cell.o {
    color: #2196F3;
}

.cell.winning {
    background-color: rgba(76, 175, 80, 0.2);
    border-color: #4CAF50;
}

.game-status {
    text-align: center;
    margin-bottom: 20px;
}

#status-message {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.control-button {
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s;
}

.control-button:hover {
    background-color: #45a049;
}

.score-board {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
    width: 100%;
    max-width: 500px;
}

.score-item {
    background-color: #f8f9fa;
    padding: 10px 20px;
    border-radius: 4px;
    text-align: center;
    flex: 1;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.player-label {
    display: block;
    font-weight: bold;
    margin-bottom: 5px;
    font-size: 1.2rem;
}

.score-value {
    font-size: 1.5rem;
    font-weight: bold;
}

.info-section {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 20px;
    margin: 20px 0;
}

.info-section h2 {
    color: #333;
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
}

.info-section h3 {
    color: #444;
    margin-top: 20px;
}

.info-section ul, .info-section ol {
    padding-left: 20px;
}

.info-section li {
    margin-bottom: 8px;
}

.note {
    background-color: #f8f9fa;
    border-left: 4px solid #2196F3;
    padding: 15px;
    margin-top: 20px;
    border-radius: 0 4px 4px 0;
}

.note h4 {
    margin-top: 0;
    color: #2196F3;
}

/* Ad Container Styling */
.ad-container {
    width: 100%;
    max-width: 800px;
    margin: 20px auto;
    padding: 15px;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    text-align: center;
    overflow: hidden;
    min-height: 100px;
}

.ad-bottom {
    margin-top: 30px;
    background-color: #f9f9f9;
    border-top: 3px solid #2196F3;
}

footer {
    text-align: center;
    padding: 1rem 0;
    background-color: #333;
    color: #fff;
    margin-top: 30px;
}

footer a {
    color: #fff;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

/* Animations */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.cell.winning {
    animation: pulse 1s infinite;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .game-board {
        width: 280px;
        height: 280px;
    }
    
    .cell {
        font-size: 3.5rem;
    }
    
    .mode-selector, .difficulty-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .mode-button, .difficulty-button {
        width: 100%;
        max-width: 200px;
    }
}

@media (max-width: 480px) {
    .game-board {
        width: 240px;
        height: 240px;
        gap: 5px;
    }
    
    .cell {
        font-size: 3rem;
    }
    
    .score-board {
        flex-direction: column;
        gap: 10px;
    }
    
    .score-item {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px;
    }
    
    .player-label {
        margin-bottom: 0;
        margin-right: 10px;
    }
} 
