/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

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

/* Header */
.header {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 20px 0;
    color: white;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

.header h1 {
    text-align: center;
    margin-bottom: 15px;
    font-size: 2.5rem;
    font-weight: 700;
}

.progress-bar {
    background: rgba(255, 255, 255, 0.2);
    height: 8px;
    border-radius: 4px;
    margin: 15px 0;
    overflow: hidden;
}

.progress-fill {
    background: linear-gradient(90deg, #4CAF50, #45a049);
    height: 100%;
    width: 0%;
    transition: width 0.3s ease;
}

.stats {
    text-align: center;
    font-size: 1.1rem;
    font-weight: 500;
}

/* Navigation Tabs */
.nav-tabs {
    background: rgba(255, 255, 255, 0.05);
    padding: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-tabs .container {
    display: flex;
    overflow-x: auto;
}

.tab-btn {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.8);
    padding: 15px 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    font-size: 1rem;
    border-bottom: 3px solid transparent;
}

.tab-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.tab-btn.active {
    color: white;
    border-bottom-color: #4CAF50;
    background: rgba(255, 255, 255, 0.1);
}

.tab-btn i {
    margin-right: 8px;
}

/* Main Content */
.main-content {
    padding: 30px 0;
    min-height: calc(100vh - 200px);
}

.content-section {
    display: none;
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.content-section.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

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

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.section-header h2 {
    color: #333;
    font-size: 2rem;
    font-weight: 600;
}

.filters {
    display: flex;
    gap: 15px;
    align-items: center;
}

.filters select {
    padding: 8px 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 0.9rem;
    background: white;
}

/* Buttons */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
}

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

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
    transform: translateY(-2px);
}

.btn-success {
    background: #28a745;
    color: white;
}

.btn-success:hover {
    background: #218838;
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: #667eea;
    border: 2px solid #667eea;
}

.btn-outline:hover {
    background: #667eea;
    color: white;
}

/* Questions Grid */
.questions-grid {
    display: grid;
    gap: 20px;
}

.question-card {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 25px;
    border-left: 5px solid #667eea;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.question-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.question-number {
    background: #667eea;
    color: white;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.9rem;
    font-weight: 600;
}

.question-subject-badge {
    background: #e3f2fd;
    color: #1976d2;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
}

.question-text {
    font-size: 1.2rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 20px;
    line-height: 1.5;
}

.answer-options {
    display: grid;
    gap: 10px;
    margin-bottom: 20px;
}

.answer-option {
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 12px 15px;
    display: flex;
    align-items: center;
}

.answer-option.correct {
    border-color: #4CAF50;
    background: #e8f5e8;
}

.option-letter {
    background: #667eea;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.9rem;
    margin-right: 12px;
    flex-shrink: 0;
}

.answer-option.correct .option-letter {
    background: #4CAF50;
}

.correct-answer {
    background: #e8f5e8;
    border: 2px solid #4CAF50;
    border-radius: 8px;
    padding: 12px 15px;
    margin-bottom: 15px;
}

.correct-answer-label {
    color: #4CAF50;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 5px;
}

.explanation {
    background: #fff3e0;
    border: 2px solid #ff9800;
    border-radius: 8px;
    padding: 15px;
    margin-top: 15px;
}

.explanation-label {
    color: #f57c00;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
}

.explanation-label i {
    margin-right: 6px;
}

.explanation-text {
    color: #333;
    line-height: 1.6;
}

/* Results */
.results-container {
    text-align: center;
    padding: 40px;
}

.results-hidden {
    display: none;
}

.results-card {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 40px;
    max-width: 500px;
    margin: 0 auto;
}

.score-display {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    margin: 30px 0;
    flex-wrap: wrap;
}

.score-circle {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4CAF50, #45a049);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    font-weight: bold;
}

.score-details {
    text-align: left;
}

.score-details p {
    margin: 8px 0;
    font-size: 1.1rem;
}

/* Study Materials */
.study-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
}

.study-card {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 25px;
    border-left: 5px solid #667eea;
}

.study-card h3 {
    color: #333;
    margin-bottom: 20px;
    font-size: 1.3rem;
}

.study-card h3 i {
    margin-right: 10px;
    color: #667eea;
}

/* Coding Problems */
.coding-grid {
    display: grid;
    gap: 20px;
}

.coding-problem {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 25px;
    border-left: 5px solid #28a745;
}

.problem-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.problem-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #333;
}

.difficulty-badge {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
}

.difficulty-Easy { background: #d4edda; color: #155724; }
.difficulty-Medium { background: #fff3cd; color: #856404; }
.difficulty-Hard { background: #f8d7da; color: #721c24; }

.problem-description {
    margin: 15px 0;
    line-height: 1.6;
}

.problem-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.detail-item {
    background: white;
    padding: 10px 15px;
    border-radius: 8px;
    border-left: 3px solid #667eea;
}

.detail-label {
    font-weight: 600;
    color: #667eea;
    font-size: 0.9rem;
}

/* Schedule */
.schedule-grid {
    display: grid;
    gap: 15px;
}

.schedule-item {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 20px;
    border-left: 5px solid #ffc107;
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 20px;
    align-items: center;
}

.schedule-day {
    font-weight: 600;
    color: #333;
    font-size: 1.1rem;
    min-width: 80px;
}

.schedule-content {
    flex: 1;
}

.schedule-duration {
    background: #667eea;
    color: white;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.9rem;
    white-space: nowrap;
}

/* Cheat Sheet */
.cheatsheet-grid {
    display: grid;
    gap: 15px;
}

.cheat-item {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 20px;
    border-left: 5px solid #17a2b8;
}

.cheat-concept {
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
    font-size: 1.1rem;
}

.cheat-category {
    background: #e3f2fd;
    color: #1976d2;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.8rem;
    display: inline-block;
    margin-bottom: 10px;
}

.cheat-details {
    color: #666;
    line-height: 1.6;
}

/* Footer */
.footer {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    text-align: center;
    padding: 20px 0;
    backdrop-filter: blur(10px);
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .header h1 {
        font-size: 2rem;
    }
    
    .section-header {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }
    
    .quiz-controls {
        justify-content: center;
    }
    
    .score-display {
        flex-direction: column;
        gap: 20px;
    }
    
    .schedule-item {
        grid-template-columns: 1fr;
        gap: 10px;
        text-align: center;
    }
    
    .problem-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
}

@media (max-width: 480px) {
    .content-section {
        padding: 20px;
        margin: 10px;
        border-radius: 10px;
    }
    
    .quiz-card {
        padding: 20px;
    }
    
    .nav-tabs .container {
        padding: 0 10px;
    }
    
    .tab-btn {
        padding: 12px 15px;
        font-size: 0.9rem;
    }
}