* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 1200px;
    width: 100%;
    padding: 40px;
    text-align: center;
}

header h1 {
    color: #667eea;
    font-size: 2.5em;
    margin-bottom: 10px;
}

.subtitle {
    color: #666;
    font-size: 1.1em;
    margin-bottom: 30px;
}

.hidden {
    display: none !important;
}

/* Mode Selection */
.mode-selection {
    margin-top: 40px;
}

.mode-selection h2 {
    color: #333;
    margin-bottom: 30px;
    font-size: 1.5em;
}

.mode-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.mode-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 20px 40px;
    font-size: 1.2em;
    border-radius: 10px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    font-weight: bold;
}

.mode-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.4);
}

.mode-btn:active {
    transform: translateY(0);
}

/* Game Screen */
.game-screen {
    margin-top: 30px;
}

.game-info {
    margin-bottom: 30px;
}

.instruction {
    font-size: 1.3em;
    color: #333;
    margin-bottom: 10px;
    font-weight: bold;
}

.step-info {
    color: #666;
    font-size: 1em;
}

.numbers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 10px;
    max-height: 400px;
    overflow-y: auto;
    padding: 20px;
    background: #f5f5f5;
    border-radius: 10px;
    margin-bottom: 30px;
}

.number-item {
    background: white;
    padding: 15px;
    border-radius: 8px;
    font-size: 1.5em;
    font-weight: bold;
    color: #667eea;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s;
}

.number-item:hover {
    transform: scale(1.05);
}

.button-container {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.action-btn {
    flex: 1;
    max-width: 300px;
    padding: 25px;
    border: none;
    border-radius: 10px;
    font-size: 1.5em;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    position: relative;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.yes-btn {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
}

.yes-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(255, 107, 107, 0.4);
}

.no-btn {
    background: linear-gradient(135deg, #4ecdc4 0%, #44a08d 100%);
}

.no-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(78, 205, 196, 0.4);
}

.action-btn:active {
    transform: translateY(0);
}

.btn-shortcut {
    background: rgba(255, 255, 255, 0.3);
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.7em;
}

/* Result Screen */
.result-screen {
    margin-top: 40px;
}

.result-content {
    padding: 40px;
}

.result-content h2 {
    color: #667eea;
    font-size: 2em;
    margin-bottom: 30px;
}

.result-text {
    font-size: 1.3em;
    color: #333;
    line-height: 1.8;
    margin-bottom: 30px;
}

.result-number {
    display: inline-block;
    font-size: 2em;
    color: #ff6b6b;
    font-weight: bold;
    margin: 10px 0;
    padding: 10px 20px;
    background: #fff5f5;
    border-radius: 10px;
}

.result-buttons {
    margin-top: 30px;
}

.result-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 1.2em;
    border-radius: 10px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    font-weight: bold;
}

.result-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.4);
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 20px;
    }

    header h1 {
        font-size: 2em;
    }

    .numbers-grid {
        grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
        gap: 8px;
        max-height: 300px;
    }

    .number-item {
        padding: 10px;
        font-size: 1.2em;
    }

    .button-container {
        flex-direction: column;
    }

    .action-btn {
        max-width: 100%;
    }

    .mode-buttons {
        flex-direction: column;
    }

    .mode-btn {
        width: 100%;
    }
}

/* Scrollbar Styling */
.numbers-grid::-webkit-scrollbar {
    width: 10px;
}

.numbers-grid::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.numbers-grid::-webkit-scrollbar-thumb {
    background: #667eea;
    border-radius: 10px;
}

.numbers-grid::-webkit-scrollbar-thumb:hover {
    background: #5568d3;
}

