:root {
    --primary: #3498db;
    --secondary: #e74c3c;
    --danger: #e74c3c;
    --warning: #f39c12;
    --info: #9b59b6;
    --light: #f8f9fa;
    --dark: #343a40;
    --gray: #6c757d;
    --success: #28a745;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
}

/* Header Styles */
header {
    background: linear-gradient(135deg, var(--warning), #e67e22);
    color: white;
    padding: 30px 0;
    text-align: center;
    border-radius: 0 0 15px 15px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

header h1 {
    font-size: 2.2rem;
    margin-bottom: 10px;
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* Card Styles */
.card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    padding: 30px;
    margin-bottom: 25px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
}

.card h2 {
    color: var(--warning);
    margin-bottom: 20px;
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
}

/* Button Styles */
.btn {
    display: inline-block;
    padding: 12px 25px;
    background-color: var(--primary);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
    transition: all 0.3s ease;
    text-decoration: none;
    margin: 5px;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.btn-primary {
    background-color: var(--warning);
}

.btn-primary:hover {
    background-color: #e67e22;
}

.btn-secondary {
    background-color: var(--gray);
}

.btn-secondary:hover {
    background-color: #5a6268;
}

.btn-success {
    background-color: var(--success);
}

.btn-success:hover {
    background-color: #218838;
}

.btn-danger {
    background-color: var(--danger);
}

.btn-danger:hover {
    background-color: #c82333;
}

.btn-group {
    text-align: center;
    margin-top: 20px;
}

/* Instructions Styles */
.instructions-content ol {
    margin-left: 20px;
    margin-bottom: 25px;
}

.instructions-content li {
    margin-bottom: 10px;
    padding-left: 10px;
}

/* Test Container Styles */
.test-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.test-info {
    display: flex;
    gap: 20px;
    align-items: center;
}

.timer {
    background-color: var(--warning);
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 1.1rem;
}

.question-counter {
    background-color: var(--info);
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: bold;
}

/* Question Styles */
.question {
    margin-bottom: 25px;
    padding: 20px;
    border-left: 4px solid var(--warning);
    background-color: #f8f9fa;
    border-radius: 8px;
}

.question-number {
    font-weight: bold;
    color: var(--warning);
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.question-text {
    font-size: 1.1rem;
    margin-bottom: 15px;
    line-height: 1.5;
}

.options {
    display: grid;
    gap: 10px;
}

.option {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    background-color: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.option:hover {
    background-color: #e9ecef;
    border-color: var(--warning);
}

.option.selected {
    background-color: var(--warning);
    color: white;
    border-color: var(--warning);
}

.option-label {
    font-weight: bold;
    margin-right: 10px;
    min-width: 30px;
}

/* Navigation Buttons */
.navigation-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 25px;
}

/* Results Styles */
.result-content {
    text-align: center;
}

.score-display {
    margin-bottom: 30px;
}

.score-circle {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--warning), var(--info));
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin: 0 auto 20px;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.score-circle span {
    font-size: 2.5rem;
    font-weight: bold;
}

.score-circle small {
    font-size: 0.9rem;
    opacity: 0.9;
}

.result-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    margin: 25px 0;
}

.stat-item {
    background-color: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    text-align: center;
}

.stat-label {
    display: block;
    font-size: 0.9rem;
    color: var(--gray);
    margin-bottom: 5px;
}

.stat-value {
    display: block;
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--warning);
}

.mastery-level {
    margin: 25px 0;
    text-align: left;
}

.mastery-text {
    font-size: 1.2rem;
    font-weight: bold;
    margin: 10px 0;
    padding: 8px 15px;
    border-radius: 20px;
    display: inline-block;
}

.progress-bar {
    height: 12px;
    background-color: #e9ecef;
    border-radius: 6px;
    margin: 15px 0;
    overflow: hidden;
}

.progress {
    height: 100%;
    background: linear-gradient(90deg, var(--danger), var(--warning), var(--success));
    border-radius: 6px;
    transition: width 0.5s ease;
}

.recommendation {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    text-align: left;
}

.recommendation h4 {
    color: var(--warning);
    margin-bottom: 10px;
}

.competency-analysis {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    text-align: left;
}

.competency-analysis h4 {
    color: var(--warning);
    margin-bottom: 15px;
}

.competency-item {
    margin-bottom: 15px;
    padding: 10px;
    border-left: 3px solid var(--info);
    background-color: white;
    border-radius: 0 5px 5px 0;
}

.competency-name {
    font-weight: bold;
    color: var(--dark);
    margin-bottom: 5px;
}

.competency-description {
    font-size: 0.9rem;
    color: var(--gray);
}

.competency-progress {
    height: 6px;
    background-color: #e9ecef;
    border-radius: 3px;
    margin-top: 5px;
    overflow: hidden;
}

.competency-progress-bar {
    height: 100%;
    background-color: var(--warning);
    border-radius: 3px;
}

/* Review Styles */
.review-question {
    margin-bottom: 25px;
    padding: 20px;
    border-radius: 8px;
    background-color: #f8f9fa;
}

.review-question.correct {
    border-left: 4px solid var(--success);
}

.review-question.incorrect {
    border-left: 4px solid var(--danger);
}

.review-answer {
    margin-top: 10px;
    padding: 10px;
    border-radius: 6px;
}

.review-answer.correct {
    background-color: #d4edda;
    color: #155724;
}

.review-answer.incorrect {
    background-color: #f8d7da;
    color: #721c24;
}

.review-answer.user-answer {
    background-color: #fff3cd;
    color: #856404;
    margin-top: 5px;
}

.solution-steps {
    background-color: #e8f4f8;
    padding: 15px;
    border-radius: 6px;
    margin-top: 10px;
}

.solution-steps h4 {
    color: var(--info);
    margin-bottom: 10px;
}

.step {
    margin-bottom: 8px;
    padding-left: 15px;
    position: relative;
}

.step:before {
    content: "•";
    color: var(--info);
    position: absolute;
    left: 5px;
}

/* Footer Styles */
footer {
    text-align: center;
    margin-top: 40px;
    padding: 20px;
    color: var(--gray);
    border-top: 1px solid #dee2e6;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    header h1 {
        font-size: 1.8rem;
    }
    
    .test-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .test-info {
        justify-content: center;
    }
    
    .navigation-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    .btn {
        width: 100%;
        margin: 5px 0;
    }
    
    .result-stats {
        grid-template-columns: 1fr;
    }
    
    .score-circle {
        width: 120px;
        height: 120px;
    }
    
    .score-circle span {
        font-size: 2rem;
    }
}