* {
    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;
    color: #333;
}

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

header {
    text-align: center;
    margin-bottom: 2rem;
    color: white;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

header p {
    font-size: 1.2rem;
    opacity: 0.9;
}

.card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 8px 32px rgba(0,0,0,0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.2);
}

.input-section {
    display: flex;
    justify-content: center;
    margin-bottom: 2rem;
}

.input-group {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
}

#stockInput {
    flex: 1;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    text-transform: uppercase;
    transition: border-color 0.3s ease;
}

#stockInput:focus {
    outline: none;
    border-color: #667eea;
}

#startGame {
    padding: 12px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease;
}

#startGame:hover {
    transform: translateY(-2px);
}

#startGame:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.error-message {
    color: #e74c3c;
    font-weight: 500;
    display: none;
    margin-top: 0.5rem;
}

.error-message.show {
    display: block;
}

.loading-message {
    color: #667eea;
    font-weight: 500;
    display: none;
    margin-top: 0.5rem;
}

.loading-message.show {
    display: block;
}

.game-section {
    display: grid;
    gap: 2rem;
}

.game-info {
    display: flex;
    justify-content: center;
}

.info-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
    text-align: center;
    min-width: 300px;
}

.info-card h3 {
    font-size: 1.5rem;
    color: #667eea;
    margin-bottom: 0.5rem;
}

.info-card p {
    margin: 0.5rem 0;
    font-size: 1.1rem;
}

#score {
    font-weight: bold;
    color: #27ae60;
}

.chart-container {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 8px 32px rgba(0,0,0,0.1);
    height: 400px;
}

#stockChart {
    max-height: 100%;
}

.prediction-section,
.result-section {
    display: flex;
    justify-content: center;
}

.prediction-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 1.5rem;
}

.predict-btn {
    padding: 16px 32px;
    border: none;
    border-radius: 12px;
    font-size: 1.2rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 120px;
}

.predict-btn.up {
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
    color: white;
}

.predict-btn.down {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
}

.predict-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.next-btn,
.end-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    margin: 0.5rem;
    transition: all 0.3s ease;
}

.next-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.end-btn {
    background: #95a5a6;
    color: white;
}

.next-btn:hover,
.end-btn:hover {
    transform: translateY(-2px);
}

#resultTitle.correct {
    color: #27ae60;
}

#resultTitle.incorrect {
    color: #e74c3c;
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .card {
        padding: 1.5rem;
    }
    
    .input-group {
        flex-direction: column;
    }
    
    .prediction-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .predict-btn {
        width: 100%;
        max-width: 200px;
    }
    
    .chart-container {
        height: 300px;
        padding: 1rem;
    }
}