:root {
    --primary: #3498db;
    --primary-dark: #2980b9;
    --accent: #2ecc71;
    --success: #27ae60;
    --error: #e74c3c;
    --light: #f9f9f9;
    --dark: #2c3e50;
    --gray: #95a5a6;
    --bg-light: #ffffff;
    --text-dark: #34495e;
    --border-radius: 10px;
    --box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Poppins', sans-serif;
    background: #f5f7fa;
    color: var(--text-dark);
    min-height: 100vh;
    padding: 2rem;
    line-height: 1.6;
    display: flex;
    justify-content: center;
    align-items: center;
}

.quiz-container {
    max-width: 800px;
    width: 100%;
    background: var(--bg-light);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
}

.quiz-header {
    text-align: center;
    padding: 2rem;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
}

.quiz-badge {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.5rem 1.25rem;
    border-radius: 50px;
    font-size: 0.85rem;
    display: inline-block;
    margin-bottom: 1rem;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.quiz-title {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.quiz-description {
    opacity: 0.9;
    font-weight: 400;
}

.quiz-content {
    padding: 2rem;
}

.quiz-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    align-items: center;
}

.quiz-timer {
    background: #f0f3f6;
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--dark);
}

.timer-icon {
    color: var(--primary);
}

.time-critical {
    color: var(--error);
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.7; }
    100% { opacity: 1; }
}

.progress-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.progress-text {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--dark);
}

.progress-bar {
    height: 6px;
    background: #f0f3f6;
    border-radius: 3px;
    width: 120px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--primary-dark));
    width: 0%;
    transition: var(--transition);
}

.question-card {
    margin-bottom: 1.5rem;
    animation: fadeIn 0.5s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.question-text {
    font-size: 1.2rem;
    font-weight: 500;
    margin-bottom: 1.5rem;
    color: var(--dark);
    line-height: 1.5;
}

.options {
    display: grid;
    gap: 0.8rem;
}

.option {
    padding: 1rem 1.25rem;
    background: #f8fafc;
    border-radius: var(--border-radius);
    border: 1px solid #e2e8f0;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    font-size: 0.95rem;
    font-weight: 400;
}

.option:hover {
    background: #f1f5f9;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.option input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.option.selected {
    border-color: var(--primary);
    background: rgba(52, 152, 219, 0.08);
}

.option.correct {
    border-color: var(--success);
    background: rgba(39, 174, 96, 0.1);
    animation: correctPulse 0.5s;
}

@keyframes correctPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.02); }
    100% { transform: scale(1); }
}

.option.incorrect {
    border-color: var(--error);
    background: rgba(231, 76, 60, 0.1);
    animation: shake 0.5s;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-3px); }
    75% { transform: translateX(3px); }
}

.quiz-footer {
    display: flex;
    justify-content: space-between;
    margin-top: 1.5rem;
}

.btn {
    padding: 0.8rem 1.5rem;
    border-radius: 50px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.btn-primary {
    background: linear-gradient(90deg, var(--primary), var(--primary-dark));
    color: white;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.4);
}

.btn-secondary {
    background: white;
    color: var(--primary);
    border: 1px solid var(--primary);
}

.btn-secondary:hover {
    background: #f8fafc;
}

.result-container {
    text-align: center;
    padding: 2rem;
    display: none;
    animation: fadeIn 0.5s ease-out;
}

.result-badge {
    width: 90px;
    height: 90px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 2.2rem;
    box-shadow: 0 6px 18px rgba(52, 152, 219, 0.3);
}

.result-title {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    color: var(--dark);
    font-weight: 600;
}

.result-score {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--dark);
}

.result-message {
    margin-bottom: 1.5rem;
    line-height: 1.6;
    color: var(--dark);
    opacity: 0.9;
}

.geography-tip {
    background: #f8fafc;
    padding: 1rem;
    border-radius: var(--border-radius);
    margin-top: 1.5rem;
    text-align: left;
    border-left: 4px solid var(--accent);
}

.geography-tip h4 {
    color: var(--accent);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
}

.geography-tip p {
    font-size: 0.95rem;
    color: var(--dark);
    opacity: 0.9;
}

@media (max-width: 768px) {
    body {
        padding: 1rem;
    }
    
    .quiz-header {
        padding: 1.5rem;
    }
    
    .quiz-title {
        font-size: 1.75rem;
    }
    
    .quiz-content {
        padding: 1.5rem;
    }
    
    .quiz-meta {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .progress-bar {
        width: 100%;
    }
    
    .quiz-footer {
        flex-direction: column-reverse;
        gap: 1rem;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
}