* {
    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;
    padding-bottom: 70px; /* Space for footer */
}

.quiz-container {
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 700px;
    width: 100%;
    padding: 40px;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- Sections --- */
.registration-section, .welcome-section, .quiz-section, .results-section {
    text-align: center;
}

.registration-content h1, .welcome-content h1 {
    font-size: 32px;
    color: #333;
    margin-bottom: 10px;
}

.registration-content p, .welcome-content p {
    font-size: 16px;
    color: #666;
    margin-bottom: 30px;
}

.quiz-info {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 30px;
}

.info-box {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.info-number {
    font-size: 28px;
    font-weight: bold;
    color: #667eea;
}

.info-label {
    font-size: 12px;
    color: #999;
    text-transform: uppercase;
    margin-top: 5px;
}

/* --- Registration Form --- */
.registration-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    text-align: left;
}

.form-group label {
    font-size: 14px;
    font-weight: 600;
    color: #555;
    margin-bottom: 8px;
    display: block;
}

.form-group input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* --- Welcome & Result Info --- */
.student-info-display, .student-result-info {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
    text-align: left;
    border-left: 5px solid #667eea;
}

.student-info-display p, .student-result-info p {
    font-size: 16px;
    color: #333;
    margin: 10px 0;
}

.student-info-display strong, .student-result-info strong {
    color: #555;
}

/* --- Quiz Elements --- */
.progress-container { margin-bottom: 30px; }
.progress-bar { width: 100%; height: 8px; background: #e0e0e0; border-radius: 10px; overflow: hidden; }
.progress-fill { height: 100%; background: linear-gradient(90deg, #667eea, #764ba2); transition: width 0.3s ease; }
.progress-text { text-align: center; margin-top: 10px; font-size: 14px; color: #999; }
.quiz-header h2 { font-size: 22px; color: #333; line-height: 1.6; margin-bottom: 30px; }
.options { display: flex; flex-direction: column; gap: 12px; margin-bottom: 30px; }
.option { padding: 16px; border: 2px solid #ddd; border-radius: 10px; background: #f9f9f9; cursor: pointer; transition: all 0.3s ease; font-size: 16px; text-align: left; }
.option:hover { border-color: #764ba2; background: #f0f0ff; }
.option.selected { border-color: #667eea; background: #e8eaff; font-weight: 500; }
.quiz-navigation { display: flex; gap: 15px; justify-content: space-between; }

/* --- Results --- */
.congratulations { margin-bottom: 20px; }
#emoji { font-size: 50px; display: block; margin-bottom: 10px; }
.congratulations h1 { font-size: 32px; }
.score-display { margin-bottom: 20px; }
.final-score-box { display: inline-flex; align-items: baseline; gap: 8px; background: linear-gradient(135deg, #667eea, #764ba2); color: white; padding: 20px 40px; border-radius: 12px; }
.score-number { font-size: 48px; font-weight: bold; }
.score-label { font-size: 24px; }
.score-percentage { margin-bottom: 20px; }
.score-percentage h3 { font-size: 36px; color: #667eea; margin-bottom: 5px; }
.score-percentage p { font-size: 16px; color: #666; }
.score-details { display: flex; gap: 20px; margin-bottom: 30px; justify-content: center; }
.detail-box { display: flex; align-items: center; gap: 12px; padding: 15px 25px; border-radius: 10px; min-width: 150px; }
.correct-detail { background: #e8f5e9; }
.incorrect-detail { background: #ffebee; }
.detail-icon { font-size: 24px; }
.detail-label { display: block; font-size: 12px; color: #666; text-transform: uppercase; }
.detail-value { display: block; font-size: 20px; font-weight: bold; color: #333; }
.review-section { background: #f5f5f5; border-radius: 10px; padding: 20px; margin-bottom: 30px; text-align: left; }
.review-section h3 { color: #333; margin-bottom: 15px; text-align: center; }
.review-list { display: flex; flex-direction: column; gap: 12px; }
.review-item { background: white; padding: 15px; border-radius: 8px; border-left: 4px solid #ddd; }
.review-item.correct-review { border-left-color: #4caf50; }
.review-item.incorrect-review { border-left-color: #f44336; }
.review-q { font-size: 14px; font-weight: bold; color: #555; margin-bottom: 8px; }
.review-answer { font-size: 14px; color: #333; margin-bottom: 5px; }
.review-correct { font-size: 13px; color: #2e7d32; font-weight: bold; }
.review-incorrect { font-size: 13px; color: #c62828; font-weight: bold; }

/* --- Buttons --- */
.btn { padding: 12px 24px; border: none; border-radius: 8px; font-size: 16px; cursor: pointer; transition: all 0.3s ease; font-weight: 500; width: 100%; }
.btn-primary { background: linear-gradient(135deg, #667eea, #764ba2); color: white; }
.btn-primary:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3); }
.btn-secondary { background: #f0f0f0; color: #333; border: 2px solid #ddd; }
.btn-secondary:hover:not(:disabled) { background: #e8e8e8; }
.btn:disabled { background: #ccc !important; cursor: not-allowed; opacity: 0.6; transform: none; box-shadow: none; }
.action-buttons, .action-buttons-welcome, .quiz-navigation { display: flex; gap: 15px; }

/* --- Footer --- */
#page-footer { position: fixed; bottom: 0; left: 0; width: 100%; background: rgba(0, 0, 0, 0.4); padding: 12px 0; text-align: center; color: white; font-size: 14px; z-index: 1000; }
#page-footer p { margin: 0; letter-spacing: 0.5px; }

/* Responsive */
@media (max-width: 600px) {
    body { padding: 15px; padding-bottom: 70px; }
    .quiz-container { padding: 20px; }
    .registration-content h1, .welcome-content h1 { font-size: 26px; }
    .action-buttons, .action-buttons-welcome, .quiz-navigation { flex-direction: column; }
    .score-details { flex-direction: column; }
}
