/* Subject Page Styles */
.subject-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    padding: 30px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.subject-title {
    display: flex;
    align-items: center;
}

.subject-title i {
    font-size: 32px;
    margin-right: 16px;
    color: #495057;
}

.subject-title h1 {
    font-size: 36px;
    font-weight: 600;
    color: #212529;
}

.subject-actions {
    display: flex;
    gap: 20px;
    align-items: center;
}

.sort-controls, .filter-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sort-controls label, .filter-controls label {
    font-size: 14px;
    font-weight: 500;
    color: #495057;
}

.sort-controls select, .filter-controls select {
    padding: 8px 12px;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    background: #ffffff;
    font-size: 14px;
    color: #495057;
    cursor: pointer;
}

/* Domains Grid */
.domains-section, .categories-section, .lessons-section {
    margin-bottom: 50px;
}

.domains-section h2, .categories-section h2, .lessons-section h2 {
    font-size: 28px;
    font-weight: 600;
    margin-bottom: 30px;
    color: #212529;
}

.domains-grid, .categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
}

.domain-card, .category-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 1px solid #e9ecef;
}

.domain-card:hover, .category-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.domain-card h3, .category-card h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 12px;
    color: #212529;
}

.domain-card p, .category-card p {
    color: #6c757d;
    margin-bottom: 16px;
    line-height: 1.5;
}

.domain-stats, .category-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    color: #6c757d;
}

.domain-stats i, .category-stats i {
    margin-right: 6px;
}

/* Lessons Grid */
.lessons-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 25px;
}

.lesson-card {
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 1px solid #e9ecef;
}

.lesson-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.lesson-header {
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
}

.lesson-type {
    display: inline-flex;
    align-items: center;
    padding: 4px 8px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 12px;
}

.lesson-type.text {
    background: #e3f2fd;
    color: #1976d2;
}

.lesson-type.video {
    background: #fce4ec;
    color: #c2185b;
}

.lesson-type.audio {
    background: #f3e5f5;
    color: #7b1fa2;
}

.lesson-type.presentation {
    background: #e8f5e8;
    color: #388e3c;
}

.lesson-type i {
    margin-right: 4px;
}

.lesson-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #212529;
}

.lesson-description {
    color: #6c757d;
    font-size: 14px;
    line-height: 1.5;
}

.lesson-footer {
    padding: 16px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.lesson-rating {
    display: flex;
    align-items: center;
    gap: 8px;
}

.stars {
    display: flex;
    gap: 2px;
}

.star {
    color: #ffc107;
    font-size: 14px;
}

.star.empty {
    color: #dee2e6;
}

.rating-value {
    font-size: 14px;
    font-weight: 500;
    color: #495057;
}

.lesson-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 12px;
    color: #6c757d;
}

.lesson-authors {
    display: flex;
    align-items: center;
    gap: 4px;
}

.lesson-date {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Creator Tools */
.creator-tools {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white !important;
    border-radius: 6px;
}

.creator-tools:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%) !important;
    color: white !important;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: #ffffff;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
}

.modal-header h3 {
    font-size: 20px;
    font-weight: 600;
    color: #212529;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: #6c757d;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    color: #495057;
}

.modal-body {
    padding: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 500;
    color: #495057;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    font-size: 14px;
    color: #495057;
    background: #ffffff;
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.form-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 30px;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

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

.btn-primary:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
}

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

.btn-secondary:hover {
    background: #5a6268;
}

/* Breadcrumb Navigation */
.breadcrumb {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
    padding: 15px 20px;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.breadcrumb-item {
    display: flex;
    align-items: center;
    color: #6c757d;
    text-decoration: none;
    font-size: 14px;
}

.breadcrumb-item:hover {
    color: #495057;
}

.breadcrumb-item.active {
    color: #212529;
    font-weight: 500;
}

.breadcrumb-separator {
    margin: 0 8px;
    color: #dee2e6;
}

/* Responsive Design */
@media (max-width: 768px) {
    .subject-header {
        flex-direction: column;
        gap: 20px;
        align-items: flex-start;
    }
    
    .subject-actions {
        flex-direction: column;
        gap: 15px;
        width: 100%;
    }
    
    .domains-grid, .categories-grid {
        grid-template-columns: 1fr;
    }
    
    .lessons-grid {
        grid-template-columns: 1fr;
    }
    
    .lesson-footer {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }
}