/* ============================================================================
   Fraley Tutors Student Portal - Styles
   ============================================================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #1a3461 0%, #00b3a4 100%);
    min-height: 100vh;
    padding: 20px;
    color: #333;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
}

/* ============================================================================
   Header
   ============================================================================ */

header {
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.header-content {
    display: flex;
    align-items: center;
    gap: 20px;
}

.logo {
    max-width: 120px;
    height: auto;
    flex-shrink: 0;
}

.header-text {
    text-align: left;
}

header h1 {
    color: #00b3a4;
    font-size: 2.2em;
    margin-bottom: 5px;
}

.subtitle {
    color: #666;
    font-size: 1.05em;
}

.header-actions {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 14px;
    flex-shrink: 0;
}

.user-email {
    font-size: 13px;
    color: #666;
}

.nav-link {
    display: inline-block;
    padding: 8px 18px;
    border: 2px solid #00b3a4;
    border-radius: 8px;
    color: #00b3a4;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.2s, color 0.2s;
    white-space: nowrap;
}

.nav-link:hover {
    background: #00b3a4;
    color: white;
}

.logout-btn {
    padding: 8px 18px;
    background: transparent;
    border: 2px solid #00b3a4;
    border-radius: 8px;
    color: #00b3a4;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.logout-btn:hover {
    background: #00b3a4;
    color: white;
}

/* ============================================================================
   States
   ============================================================================ */

.loading, .empty-state, .error-state {
    background: white;
    border-radius: 15px;
    padding: 60px 30px;
    text-align: center;
    color: #666;
    font-size: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.empty-state p {
    color: #666;
    margin-bottom: 8px;
}

.empty-state .empty-hint {
    font-size: 14px;
    color: #999;
}

.error-state p {
    color: #c0392b;
}

/* ============================================================================
   Assignment Cards
   ============================================================================ */

#assignmentsList {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.assignment-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

/* Lesson tag on assignment cards (links assignment back to its originating lesson) */
.assignment-lesson-tag {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    background: #e6faf9;
    border: 1px solid #8dd5d0;
    border-radius: 8px;
    padding: 7px 12px;
    font-size: 13px;
    color: #0d6b65;
    margin-bottom: 14px;
}

.assignment-lesson-tag-icon {
    flex-shrink: 0;
}

.assignment-lesson-view-link {
    margin-left: auto;
    font-size: 13px;
    font-weight: 600;
    color: #0d6b65;
    text-decoration: none;
    white-space: nowrap;
}

.assignment-lesson-view-link:hover {
    text-decoration: underline;
}

.assignment-header {
    padding: 24px 28px 20px;
    border-bottom: 1px solid #f0f0f0;
}

.assignment-title-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 10px;
}

.assignment-title {
    font-size: 1.35em;
    color: #333;
    font-weight: 700;
    flex: 1;
}

.assignment-status {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: capitalize;
    white-space: nowrap;
    flex-shrink: 0;
    margin-top: 3px;
}

.assignment-status.active {
    background: #e8f5e9;
    color: #2e7d32;
}

.assignment-status.completed {
    background: #e3f2fd;
    color: #1565c0;
}

.assignment-status.archived {
    background: #f5f5f5;
    color: #757575;
}

.assignment-meta {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    font-size: 13px;
    color: #888;
    margin-bottom: 12px;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

.meta-due {
    color: #e67e22;
    font-weight: 600;
}

.assignment-notes {
    font-size: 14px;
    color: #555;
    background: #f5fafa;
    border-left: 3px solid #00b3a4;
    padding: 10px 14px;
    border-radius: 0 8px 8px 0;
    margin-top: 12px;
    line-height: 1.5;
}

/* Lesson resource links */
.lesson-links {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.lesson-links-label {
    font-size: 13px;
    color: #888;
    font-weight: 500;
}

.lesson-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 12px;
    background: #e8faf9;
    border: 1px solid #8dd0cb;
    border-radius: 20px;
    color: #00b3a4;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s;
}

.lesson-link::before {
    content: '↗';
    font-size: 11px;
}

.lesson-link:hover {
    background: #00b3a4;
    border-color: #00b3a4;
    color: white;
}

/* ============================================================================
   Question Cards within Assignment
   ============================================================================ */

.assignment-questions {
    padding: 20px 28px 24px;
}

.questions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 14px;
}

.portal-q-card {
    border: 1.5px solid #e0e0e0;
    border-radius: 10px;
    padding: 14px;
    background: #fafafa;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.portal-q-card:hover {
    border-color: #00b3a4;
    box-shadow: 0 3px 12px rgba(0, 179, 164, 0.15);
}

.portal-q-missing {
    color: #999;
    font-size: 13px;
    font-style: italic;
    border-style: dashed;
}

.portal-q-top {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.portal-q-num {
    font-family: 'Courier New', monospace;
    background: #00b3a4;
    color: white;
    padding: 2px 8px;
    border-radius: 5px;
    font-size: 12px;
    font-weight: 700;
    flex-shrink: 0;
}

.portal-q-meta {
    font-size: 11px;
    color: #888;
    flex: 1;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.portal-q-marks {
    font-size: 12px;
    color: #1a3461;
    font-weight: 600;
    flex-shrink: 0;
}

.portal-q-topic {
    font-size: 12px;
    color: #555;
    line-height: 1.3;
}

.portal-q-image {
    border-radius: 6px;
    overflow: hidden;
    background: #f0f0f0;
    flex-shrink: 0;
}

.portal-q-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* Student submission photo toggle */
.portal-q-submission-wrap {
    margin-top: 6px;
}

.portal-q-submission-toggle {
    background: none;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    padding: 3px 10px;
    font-size: 12px;
    color: #4b5563;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.portal-q-submission-toggle:hover {
    background: #f3f4f6;
}

.portal-q-submission-img {
    margin-top: 6px;
    border-radius: 6px;
    overflow: hidden;
    border: 1px solid #e5e7eb;
}

.portal-q-submission-img img {
    width: 100%;
    height: auto;
    display: block;
}

/* Submission status badge */
.q-sub-status {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 20px;
    align-self: flex-start;
}

.q-sub-pending {
    background: #f0f0f0;
    color: #999;
}

.q-sub-correct {
    background: #e8f5e9;
    color: #2e7d32;
}

.q-sub-incorrect {
    background: #fdecea;
    color: #c62828;
}

/* Submitted count in assignment meta */
.meta-submitted {
    color: #2e7d32;
    font-weight: 600;
}

/* Question selection checkbox */
.portal-q-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: auto;
    flex-wrap: wrap;
}

.q-help-btn {
    display: inline-flex;
    align-items: center;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: 600;
    color: #6366f1;
    background: #eef2ff;
    border: 1.5px solid #c7d2fe;
    border-radius: 7px;
    cursor: pointer;
    line-height: 1.5;
    transition: background 0.15s, color 0.15s;
    white-space: nowrap;
}

.q-help-btn:hover {
    background: #e0e7ff;
    color: #4338ca;
}

.portal-q-select-label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    color: #00b3a4;
    padding: 6px 8px;
    border: 1.5px solid #8dd0cb;
    border-radius: 7px;
    background: #e8faf9;
    transition: background 0.15s, border-color 0.15s;
    user-select: none;
}

.portal-q-select-label:hover {
    background: #ccecea;
    border-color: #00b3a4;
}

.portal-q-select-label input[type="checkbox"] {
    accent-color: #00b3a4;
    width: 15px;
    height: 15px;
    flex-shrink: 0;
    cursor: pointer;
}

/* Submit bar — appears at bottom of assignment when questions selected */
.portal-submit-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 16px;
    padding: 12px 18px;
    background: #00b3a4;
    border-radius: 10px;
    gap: 12px;
    flex-wrap: wrap;
}

.portal-submit-count {
    color: rgba(255,255,255,0.9);
    font-size: 14px;
    font-weight: 500;
}

.portal-submit-btn {
    display: inline-block;
    padding: 9px 22px;
    background: white;
    color: #00b3a4;
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
    transition: background 0.15s, color 0.15s;
}

.portal-submit-btn:hover {
    background: #e8faf9;
}

/* View assignment button */
.assignment-view-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 16px;
    background: #e8f5f4;
    border: 1.5px solid #00b3a4;
    border-radius: 8px;
    color: #00796b;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s;
}

.assignment-view-btn:hover {
    background: #d0eeec;
}

/* Assignment view modal */
.assignment-view-modal-box {
    max-width: 800px;
    width: 95%;
}

.av-question {
    padding: 20px 24px;
    border-bottom: 1px solid #f0f0f0;
}

.av-question:last-child {
    border-bottom: none;
}

.av-question-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px;
    flex-wrap: wrap;
}

.av-question-num {
    font-size: 1.1em;
    font-weight: 700;
    color: #1a3461;
}

.av-question-meta {
    font-size: 13px;
    color: #888;
}

.av-question-marks {
    font-size: 12px;
    color: #00796b;
    background: #e8f5f4;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 600;
}

.av-question-topic {
    font-size: 13px;
    color: #666;
    margin-bottom: 12px;
}

.av-question-image {
    border-radius: 8px;
    overflow: hidden;
    background: #f8f8f8;
}

.av-question-image img {
    width: 100%;
    height: auto;
    display: block;
    cursor: pointer;
    transition: opacity 0.15s;
}

.av-question-image img:hover {
    opacity: 0.85;
}

/* Lightbox — full-screen image viewer */
.image-lightbox {
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: rgba(0, 0, 0, 0.88);
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-close {
    position: absolute;
    top: 16px;
    right: 20px;
    background: none;
    border: none;
    color: #fff;
    font-size: 36px;
    cursor: pointer;
    z-index: 10001;
    line-height: 1;
    padding: 4px 10px;
    opacity: 0.8;
    transition: opacity 0.15s;
}

.lightbox-close:hover {
    opacity: 1;
}

.lightbox-img-wrap {
    max-width: 94vw;
    max-height: 92vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.lightbox-img-wrap img {
    max-width: 100%;
    max-height: 88vh;
    object-fit: contain;
    border-radius: 6px;
    box-shadow: 0 4px 40px rgba(0, 0, 0, 0.5);
    background: #fff;
}

/* Clickable question thumbnails in assignment cards */
.portal-q-image img.lightbox-trigger {
    cursor: pointer;
    transition: opacity 0.15s;
}

.portal-q-image img.lightbox-trigger:hover {
    opacity: 0.8;
}

.av-missing {
    color: #999;
    font-style: italic;
}

.portal-submit-all-btn {
    display: inline-block;
    padding: 9px 22px;
    background: #00b3a4;
    color: white;
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
    transition: background 0.15s;
}

.portal-submit-all-btn:hover {
    background: #009688;
}

/* ============================================================================
   Login Overlay
   ============================================================================ */

.login-overlay {
    position: fixed;
    inset: 0;
    background: linear-gradient(135deg, #1a3461 0%, #00b3a4 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.login-box {
    background: white;
    border-radius: 20px;
    padding: 50px 40px;
    width: 100%;
    max-width: 420px;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.login-logo {
    max-width: 120px;
    height: auto;
    margin-bottom: 20px;
}

.login-box h2 {
    color: #00b3a4;
    font-size: 1.8em;
    margin-bottom: 6px;
}

.login-subtitle {
    color: #888;
    font-size: 0.95em;
    margin-bottom: 30px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.login-form input {
    padding: 14px 18px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 15px;
    transition: border-color 0.2s;
    outline: none;
}

.login-form input:focus {
    border-color: #00b3a4;
}

.login-form button {
    padding: 14px;
    background: #00b3a4;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.login-form button:hover:not(:disabled) {
    background: #009d8f;
}

.login-form button:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.login-error {
    color: #c0392b;
    font-size: 14px;
    min-height: 18px;
}

/* ============================================================================
   Portal Sections
   ============================================================================ */

.portal-section {
    margin-bottom: 40px;
}

.section-title {
    font-size: 1.2em;
    font-weight: 700;
    color: white;
    margin-bottom: 16px;
    padding-left: 4px;
    letter-spacing: 0.01em;
}

/* ============================================================================
   Lesson Cards
   ============================================================================ */

.lesson-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 16px;
    overflow: hidden;
}

/* Clickable toggle header */
.lesson-card-toggle-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px 22px;
    cursor: pointer;
    user-select: none;
}

.lesson-card-toggle-header:hover {
    background: rgba(0, 179, 164, 0.03);
}

.lesson-card-header-inner {
    flex: 1;
    min-width: 0;
}

.lesson-card-chevron {
    flex-shrink: 0;
    font-size: 11px;
    color: #bbb;
    transition: transform 0.2s;
}

/* Collapsible body */
.lesson-card-body {
    padding: 0 22px 20px;
    border-top: 1px solid #f3f4f6;
}

/* Header row (date + subject + tutor inline) */
.lesson-card-header {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.lesson-header-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.lesson-date {
    font-size: 0.85em;
    font-weight: 700;
    color: white;
    background: #00b3a4;
    border-radius: 8px;
    padding: 4px 10px;
    white-space: nowrap;
    flex-shrink: 0;
}

.lesson-subject {
    font-size: 1.0em;
    font-weight: 700;
    color: #333;
}

.lesson-tutor-inline {
    font-size: 12px;
    color: #999;
}

/* Summary badges in the toggle header */
.lesson-header-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
}

.lesson-header-badge {
    font-size: 12px;
    font-weight: 600;
    border-radius: 10px;
    padding: 3px 9px;
    white-space: nowrap;
}

.lesson-header-badge-correct {
    background: #dcfce7;
    color: #16a34a;
    border: 1px solid #bbf7d0;
}

.lesson-header-badge-practised {
    background: #eff6ff;
    color: #3b82f6;
    border: 1px solid #bfdbfe;
}

.lesson-header-badge-topics {
    background: #e8f5e9;
    color: #2e7d32;
    border: 1px solid #a5d6a7;
    cursor: default;
}

/* Body content */
.lesson-notes {
    font-size: 14px;
    color: #555;
    background: #f5fafa;
    border-left: 3px solid #00b3a4;
    padding: 10px 14px;
    border-radius: 0 8px 8px 0;
    margin: 12px 0;
    line-height: 1.55;
    white-space: pre-wrap;
}

.lesson-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.lesson-resource-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 14px;
    background: #e8f7f6;
    color: #00b3a4;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s;
}

.lesson-resource-link:hover {
    background: #ccebe9;
}

/* Completed questions section */
.lesson-completed-section {
    margin-top: 16px;
    border-top: 1px solid #dcfce7;
    padding-top: 12px;
}

.lesson-completed-toggle {
    background: none;
    border: 1px solid #bbf7d0;
    border-radius: 10px;
    padding: 5px 12px;
    font-size: 13px;
    font-weight: 600;
    color: #16a34a;
    cursor: pointer;
    transition: background 0.15s;
}

.lesson-completed-toggle:hover,
.lesson-completed-toggle.open {
    background: #f0fdf4;
}

.lesson-completed-label {
    font-size: 13px;
    font-weight: 600;
    color: #16a34a;
    margin-bottom: 8px;
}

.lesson-completed-detail {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 10px;
}

.lesson-completed-q-card {
    position: relative;
    border-radius: 8px;
    border: 2px solid #16a34a;
    overflow: hidden;
    background: #f0fdf4;
    display: flex;
    flex-direction: column;
}

/* Image-first layout */
.lesson-completed-img-wrap {
    position: relative;
}

.lesson-completed-img-wrap img {
    width: 100%;
    height: auto;
    display: block;
}

.lesson-completed-img-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 6px;
    background: linear-gradient(to bottom, rgba(0,0,0,0.55) 0%, transparent 100%);
}

.lesson-completed-qnum-lbl {
    font-size: 11px;
    font-weight: 700;
    color: white;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

.lesson-completed-check-lbl {
    font-size: 11px;
    font-weight: 700;
    color: white;
    background: #16a34a;
    border-radius: 10px;
    padding: 1px 6px;
}

/* No-image text layout */
.lesson-completed-noimg {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 10px;
}

.lesson-completed-marks-lbl {
    font-size: 11px;
    color: #1a3461;
    font-weight: 600;
}

.lesson-completed-topic-lbl {
    font-size: 11px;
    color: #555;
    padding: 0 10px 8px;
    line-height: 1.3;
}

/* Clickable thumbnail (closed assignment) */
.lesson-completed-q-card-clickable {
    cursor: pointer;
    transition: box-shadow 0.15s, transform 0.1s;
}
.lesson-completed-q-card-clickable:hover {
    box-shadow: 0 4px 12px rgba(22, 163, 74, 0.3);
    transform: translateY(-2px);
}

/* Go to Assignments link (open assignments in lesson card) */
.lesson-completed-assignments-link {
    display: inline-block;
    margin-top: 10px;
    font-size: 13px;
    font-weight: 600;
    color: #00b3a4;
    text-decoration: none;
}
.lesson-completed-assignments-link:hover {
    text-decoration: underline;
}

/* Per-assignment action row in lesson cards */
.lesson-assignment-action-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 8px 0;
    border-top: 1px solid #f3f4f6;
    margin-top: 6px;
}
.lesson-assignment-action-title {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.lesson-assignment-action-link {
    font-size: 12px;
    font-weight: 600;
    color: #00b3a4;
    text-decoration: none;
    white-space: nowrap;
}
.lesson-assignment-action-link:hover { text-decoration: underline; }
.lesson-assignment-summary-btn {
    background: none;
    border: none;
    padding: 0;
    font-size: 12px;
    font-weight: 600;
    color: #6366f1;
    cursor: pointer;
    white-space: nowrap;
}
.lesson-assignment-summary-btn:hover { text-decoration: underline; }

/* Assignment summary modal — wide variant */
.modal-box-wide {
    max-width: 680px;
    width: 95%;
}

/* Assignment summary modal — per-question cards */
.asummary-q-card {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 14px 16px;
    margin-bottom: 16px;
    background: #fff;
}
.asummary-q-header {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
}
.asummary-qnum {
    font-size: 13px;
    font-weight: 700;
    background: #f3f4f6;
    border-radius: 4px;
    padding: 2px 7px;
    color: #374151;
}
.asummary-marks { font-size: 12px; color: #9ca3af; }
.asummary-topic { font-size: 12px; color: #6b7280; }
.asummary-badge {
    font-size: 11px;
    font-weight: 700;
    border-radius: 12px;
    padding: 2px 8px;
    margin-left: auto;
}
.asummary-badge-correct   { background: #dcfce7; color: #16a34a; }
.asummary-badge-incorrect { background: #fee2e2; color: #dc2626; }
.asummary-badge-pending   { background: #f3f4f6; color: #9ca3af; }
.asummary-question-img-wrap { margin-bottom: 10px; }
.asummary-question-img {
    max-width: 100%;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
}
.asummary-section { margin-top: 10px; }
.asummary-section-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #9ca3af;
    margin: 0 0 4px;
}
.asummary-submission-img {
    max-width: 100%;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
}
.asummary-answer-text,
.asummary-feedback-text {
    font-size: 13px;
    color: #374151;
    margin: 0;
    white-space: pre-wrap;
}
.asummary-section-answer { background: #f0fdf4; border-radius: 6px; padding: 8px 10px; }
.asummary-correct-text {
    font-size: 13px;
    font-weight: 600;
    color: #16a34a;
    margin: 0;
}
.asummary-loading, .asummary-error {
    font-size: 14px;
    color: #9ca3af;
    text-align: center;
    padding: 24px 0;
}

/* Question group labels in assignment cards */
.q-group-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #9ca3af;
    padding: 4px 0 6px;
    grid-column: 1 / -1;
}

.q-group-label-retry {
    color: #f59e0b;
    margin-top: 8px;
}

/* Attempt count badge on incorrect questions */
.q-attempt-badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    background: #fef3c7;
    color: #d97706;
    border: 1px solid #fde68a;
    border-radius: 8px;
    padding: 2px 7px;
    margin-left: 6px;
    vertical-align: middle;
}

/* Legacy — retained for any page still using old class */
.lesson-questions-count {
    font-size: 13px;
    color: #00b3a4;
    margin-top: 10px;
    margin-bottom: 0;
}

/* Highlight a lesson card when navigated to via anchor link from assignments page */
@keyframes lessonHighlight {
    0%   { box-shadow: 0 0 0 3px #00b3a488; }
    70%  { box-shadow: 0 0 0 6px #00b3a444; }
    100% { box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1); }
}

.lesson-card-highlight {
    animation: lessonHighlight 1.6s ease-out forwards;
}

/* ============================================================================
   Curriculum Sheet
   ============================================================================ */

.curriculum-org-banner {
    background: #e6faf9;
    border: 1px solid #8dd5d0;
    border-radius: 10px;
    padding: 10px 16px;
    margin-bottom: 16px;
    font-size: 13px;
    color: #0d6b65;
}

.curriculum-org-banner a {
    color: #0d7870;
    font-weight: 600;
    text-decoration: none;
    margin-left: 4px;
}

.curriculum-org-banner a:hover { text-decoration: underline; }

/* Learning page tabs */
.learning-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
}
.learning-tab {
    flex: 1;
    padding: 12px 20px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    background: white;
    color: #666;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
}
.learning-tab:hover {
    border-color: #00b3a4;
    color: #00b3a4;
}
.learning-tab.active {
    background: #00b3a4;
    border-color: #00b3a4;
    color: white;
}

.curriculum-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    overflow: hidden;
}

.curriculum-subject-header {
    background: linear-gradient(135deg, #1a3461 0%, #00b3a4 100%);
    color: white;
    padding: 16px 22px;
    font-size: 1.05em;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    user-select: none;
}

.subject-toggle {
    font-size: 12px;
    color: rgba(255,255,255,0.65);
    transition: transform 0.2s;
    flex-shrink: 0;
}

.subject-toggle.open {
    transform: rotate(90deg);
}

.curriculum-topics {
    padding: 8px 0;
    display: none;
}

.curriculum-topics.open {
    display: block;
}

.curriculum-topic {
    border-bottom: 1px solid #f5f5f5;
}

.curriculum-topic:last-child {
    border-bottom: none;
}

.topic-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 22px 8px;
    font-size: 14px;
    font-weight: 700;
    color: #444;
    cursor: pointer;
    user-select: none;
}

.topic-toggle {
    font-size: 11px;
    color: #aaa;
    transition: transform 0.2s;
    flex-shrink: 0;
}

.topic-toggle.open {
    transform: rotate(90deg);
}

.curriculum-subtopics {
    padding: 0 22px 10px 36px;
    display: none;
}

.curriculum-subtopics.open {
    display: block;
}

.subtopic-row {
    display: flex;
    align-items: baseline;
    gap: 10px;
    padding: 4px 0;
    font-size: 13px;
    flex-wrap: wrap;
}

.subtopic-name {
    color: #555;
    flex: 1;
    min-width: 0;
}

.subtopic-covered-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-weight: 600;
    color: #2e7d32;
    background: #e8f5e9;
    border-radius: 12px;
    padding: 2px 8px;
    white-space: nowrap;
    flex-shrink: 0;
}

.subtopic-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    align-items: center;
    flex-shrink: 0;
}

.subtopic-lesson-tag {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 11px;
    font-weight: 600;
    color: #2e7d32;
    background: #e8f5e9;
    border: 1px solid #a5d6a7;
    border-radius: 10px;
    padding: 2px 9px;
    white-space: nowrap;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.15s, color 0.15s, box-shadow 0.15s;
}

.subtopic-lesson-tag:hover {
    background: #c8e6c9;
    color: #1b5e20;
    box-shadow: 0 1px 4px rgba(46, 125, 50, 0.2);
}

/* ============================================================================
   Q&A Assignment "Ask for help" button
   ============================================================================ */

.assignment-ask-help-row {
    margin-top: 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.qa-assignment-ask-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 16px;
    background: #fff8e1;
    border: 1.5px solid #f9a825;
    border-radius: 20px;
    color: #e65100;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
}

.qa-assignment-ask-btn::before {
    content: '?';
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    background: #f9a825;
    color: white;
    border-radius: 50%;
    font-size: 11px;
    font-weight: 700;
    flex-shrink: 0;
}

.qa-assignment-ask-btn:hover {
    background: #fff3cd;
    border-color: #e65100;
}

/* ============================================================================
   Q&A Section
   ============================================================================ */

.qa-section-header {
    margin-bottom: 16px;
}

.qa-new-btn {
    padding: 10px 22px;
    background: #00b3a4;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.qa-new-btn:hover {
    background: #009d8f;
}

/* ============================================================================
   Help Post Cards (student view)
   ============================================================================ */

.help-post-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    padding: 22px 26px;
    margin-bottom: 16px;
    border-left: 4px solid #ccc;
}

.help-post-card.open {
    border-left-color: #f9a825;
}

.help-post-card.answered {
    border-left-color: #4caf50;
}

.help-post-card.closed {
    border-left-color: #bbb;
    opacity: 0.75;
}

.help-post-top {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.help-status {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.help-status.open {
    background: #fff3cd;
    color: #856404;
}

.help-status.answered {
    background: #e8f5e9;
    color: #2e7d32;
}

.help-status.closed {
    background: #f0f0f0;
    color: #888;
}

.help-post-actions {
    margin-top: 12px;
    display: flex;
    justify-content: flex-end;
}

.help-close-btn {
    padding: 6px 14px;
    background: white;
    color: #999;
    border: 1.5px solid #ddd;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s;
}

.help-close-btn:hover {
    border-color: #bbb;
    color: #555;
}

.help-answer-type {
    font-size: 12px;
    color: #888;
    background: #f5f5f5;
    padding: 3px 10px;
    border-radius: 20px;
}

.help-post-date {
    font-size: 12px;
    color: #aaa;
    margin-left: auto;
}

.help-post-subject {
    font-size: 13px;
    font-weight: 600;
    color: #00b3a4;
    margin-bottom: 4px;
}

.help-post-assignment {
    font-size: 13px;
    color: #e65100;
    margin-bottom: 8px;
    font-style: italic;
}

.help-post-text {
    font-size: 14px;
    color: #444;
    line-height: 1.55;
    white-space: pre-wrap;
    margin-bottom: 10px;
}

.help-img-wrap {
    border-radius: 8px;
    overflow: hidden;
    background: #f0f0f0;
    margin-bottom: 10px;
    display: inline-block;
    max-width: 100%;
}

.help-img {
    max-width: 100%;
    height: auto;
    display: block;
}

.help-responses {
    margin-top: 16px;
    border-top: 1px solid #f0f0f0;
    padding-top: 14px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.help-response {
    background: #f5fafa;
    border-left: 3px solid #00b3a4;
    border-radius: 0 8px 8px 0;
    padding: 12px 14px;
}

.help-response-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px;
}

.help-response-label {
    font-size: 12px;
    font-weight: 700;
    color: #00b3a4;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.help-response-date {
    font-size: 12px;
    color: #aaa;
}

.help-response-text {
    font-size: 14px;
    color: #444;
    line-height: 1.55;
    white-space: pre-wrap;
}

/* ============================================================================
   Q&A Modal Overlay and Box
   ============================================================================ */

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9000;
    padding: 20px;
}

.modal-box {
    background: white;
    border-radius: 16px;
    width: 100%;
    max-width: 560px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
}

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

.modal-header h3 {
    font-size: 1.15em;
    color: #333;
    font-weight: 700;
}

.modal-close {
    background: none;
    border: none;
    font-size: 22px;
    color: #aaa;
    cursor: pointer;
    line-height: 1;
    padding: 2px 6px;
    border-radius: 4px;
}

.modal-close:hover {
    color: #555;
    background: #f5f5f5;
}

.modal-body {
    padding: 20px 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 16px 24px;
    border-top: 1px solid #f0f0f0;
}

.modal-cancel {
    padding: 10px 20px;
    background: white;
    border: 1.5px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #555;
    cursor: pointer;
    transition: border-color 0.2s;
}

.modal-cancel:hover {
    border-color: #bbb;
}

.modal-save {
    padding: 10px 24px;
    background: #00b3a4;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.modal-save:hover:not(:disabled) {
    background: #009d8f;
}

.modal-save:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.modal-error {
    color: #c0392b;
    font-size: 13px;
    min-height: 18px;
}

/* ============================================================================
   Q&A Modal Form Elements
   ============================================================================ */

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 13px;
    font-weight: 600;
    color: #555;
}

.form-hint {
    font-weight: 400;
    color: #aaa;
}

.form-group select,
.form-group textarea {
    padding: 10px 12px;
    border: 1.5px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    color: #333;
    transition: border-color 0.2s;
    outline: none;
    resize: vertical;
}

.form-group select:focus,
.form-group textarea:focus {
    border-color: #00b3a4;
}

.qa-linked-assignment {
    background: #fff8e1;
    border: 1px solid #f9a825;
    border-radius: 8px;
    padding: 10px 14px;
    font-size: 13px;
    color: #e65100;
    font-weight: 500;
}

.qa-question-preview {
    margin-top: 10px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    background: #fafafa;
}

.qa-question-preview img {
    display: block;
    max-width: 100%;
    max-height: 300px;
    object-fit: contain;
    margin: 0 auto;
}

.qa-answer-type-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.qa-type-option {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 14px;
    border: 1.5px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}

.qa-type-option:has(input:checked) {
    border-color: #00b3a4;
    background: #e8faf9;
}

.qa-type-option input[type="radio"] {
    margin-top: 2px;
    accent-color: #00b3a4;
    flex-shrink: 0;
}

.qa-type-label {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.qa-type-label strong {
    font-size: 14px;
    color: #333;
}

.qa-type-label small {
    font-size: 12px;
    color: #888;
}

.qa-symbol-toggle {
    align-self: flex-start;
    padding: 5px 12px;
    background: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 13px;
    color: #555;
    cursor: pointer;
    transition: background 0.2s;
    margin-top: 4px;
}

.qa-symbol-toggle:hover {
    background: #ebebeb;
}

.qa-symbol-keyboard {
    background: #fafafa;
    border: 1px solid #e8e8e8;
    border-radius: 8px;
    padding: 12px;
    margin-top: 4px;
}

.qa-symbol-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.qa-sym {
    padding: 6px 10px;
    background: white;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
    min-width: 36px;
    text-align: center;
}

.qa-sym:hover {
    background: #00b3a4;
    border-color: #00b3a4;
    color: white;
}

.qa-sym-hint {
    font-size: 12px;
    color: #aaa;
}

.qa-upload-btn {
    align-self: flex-start;
    padding: 8px 16px;
    background: #f5f5f5;
    border: 1.5px solid #ddd;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #555;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
}

.qa-upload-btn:hover {
    background: #ebebeb;
    border-color: #bbb;
}

.qa-image-previews {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 6px;
}

.qa-preview-item {
    position: relative;
    display: inline-block;
}

.qa-preview-img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #ddd;
    display: block;
}

.qa-preview-remove {
    position: absolute;
    top: -6px;
    right: -6px;
    width: 20px;
    height: 20px;
    background: #e53935;
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 14px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.qa-anon-label {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    cursor: pointer;
    font-weight: 400 !important;
    color: #555 !important;
}

.qa-anon-label input[type="checkbox"] {
    margin-top: 2px;
    accent-color: #00b3a4;
    width: 15px;
    height: 15px;
    flex-shrink: 0;
}

/* ============================================================================
   Hub Navigation Grid
   ============================================================================ */

.hub-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.hub-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    padding: 32px 28px;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: transform 0.15s, box-shadow 0.15s;
}

.hub-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.16);
}

.hub-card-icon {
    font-size: 2.4em;
    line-height: 1;
}

.hub-card-title {
    font-size: 1.2em;
    font-weight: 700;
    color: #333;
}

.hub-card-desc {
    font-size: 13px;
    color: #888;
    line-height: 1.5;
}

/* ============================================================================
   Guide Accordion (portal-help.html)
   ============================================================================ */

.guide-intro {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    padding: 24px 28px;
    margin-bottom: 24px;
    font-size: 14px;
    color: #555;
    line-height: 1.65;
}

.guide-intro p + p {
    margin-top: 10px;
}

.guide-section {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    margin-bottom: 10px;
    overflow: hidden;
}

.guide-section-header {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px 22px;
    cursor: pointer;
    user-select: none;
    transition: background 0.15s;
}

.guide-section-header:hover {
    background: #f9fffe;
}

.guide-section-icon {
    font-size: 1.4em;
    flex-shrink: 0;
    line-height: 1;
}

.guide-section-title {
    font-size: 1.0em;
    font-weight: 700;
    color: #333;
    flex: 1;
}

.guide-section-chevron {
    font-size: 11px;
    color: #bbb;
    transition: transform 0.2s;
    flex-shrink: 0;
}

.guide-section-chevron.open {
    transform: rotate(90deg);
}

.guide-section-body {
    display: none;
    padding: 0 22px 22px;
    border-top: 1px solid #f3f4f6;
}

.guide-section-body.open {
    display: block;
}

.guide-section-body p {
    font-size: 14px;
    color: #555;
    line-height: 1.65;
    margin-top: 14px;
}

.guide-steps {
    margin-top: 14px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.guide-step {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.guide-step-num {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    background: #00b3a4;
    color: white;
    border-radius: 50%;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 1px;
}

.guide-step-text {
    font-size: 14px;
    color: #444;
    line-height: 1.6;
    flex: 1;
}

.guide-step-text strong {
    color: #333;
}

.guide-note {
    background: #e8faf9;
    border-left: 3px solid #00b3a4;
    border-radius: 0 8px 8px 0;
    padding: 10px 14px;
    margin-top: 14px;
    font-size: 13px;
    color: #0d5e58;
    line-height: 1.55;
}

.guide-note strong {
    font-weight: 700;
}

/* ============================================================================
   Responsive
   ============================================================================ */

@media (max-width: 680px) {
    body {
        padding: 12px;
    }

    header {
        padding: 20px;
    }

    header h1 {
        font-size: 1.6em;
    }

    .header-content {
        flex-wrap: wrap;
    }

    .header-actions {
        margin-left: 0;
        width: 100%;
    }

    .assignment-header {
        padding: 18px 20px 16px;
    }

    .assignment-questions {
        padding: 16px 20px 20px;
    }

    .questions-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    }

    .hub-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================================================
   Feedback button (View feedback — on graded question cards)
   ============================================================================ */

.q-feedback-btn {
    display: inline-block;
    margin-top: 4px;
    padding: 2px 8px;
    font-size: 11px;
    font-weight: 600;
    color: #009d94;
    background: #e6faf9;
    border: 1px solid #8dd5d0;
    border-radius: 8px;
    cursor: pointer;
    line-height: 1.6;
    transition: background 0.15s, color 0.15s;
}

.q-feedback-btn:hover {
    background: #ccecea;
    color: #0d6b65;
}

.q-feedback-btn-sm {
    display: block;
    width: calc(100% - 12px);
    margin: 6px;
    text-align: center;
}

/* ============================================================================
   Gemini Feedback Modal
   ============================================================================ */

.feedback-question-title {
    font-size: 14px;
    font-weight: 700;
    color: #374151;
    margin-bottom: 14px;
}

.feedback-attempt {
    border-radius: 10px;
    border: 1px solid #e5e7eb;
    padding: 14px 16px;
    margin-bottom: 12px;
    background: #fafafa;
}

.feedback-attempt.feedback-correct {
    border-color: #bbf7d0;
    background: #f0fdf4;
}

.feedback-attempt.feedback-incorrect {
    border-color: #fecaca;
    background: #fff5f5;
}

.feedback-attempt-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.feedback-attempt-num {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
}

.feedback-badge {
    font-size: 11px;
    font-weight: 700;
    border-radius: 8px;
    padding: 2px 8px;
}

.feedback-badge-correct {
    background: #dcfce7;
    color: #15803d;
    border: 1px solid #86efac;
}

.feedback-badge-incorrect {
    background: #fee2e2;
    color: #b91c1c;
    border: 1px solid #fca5a5;
}

.feedback-section {
    margin-top: 8px;
}

.feedback-section-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #9ca3af;
    margin-bottom: 3px;
}

.feedback-section-content {
    font-size: 13px;
    color: #374151;
    white-space: pre-wrap;
    word-break: break-word;
    line-height: 1.55;
}

.feedback-empty {
    font-size: 14px;
    color: #9ca3af;
    text-align: center;
    padding: 20px 0;
}

.feedback-section-markscheme {
    border-top: 1px solid #bbf7d0;
    margin-top: 10px;
    padding-top: 8px;
}
.feedback-section-markscheme .feedback-section-label {
    color: #15803d;
}
.feedback-section-markscheme .feedback-section-content {
    font-weight: 600;
    color: #166534;
}

/* ── Assignment sections: before due / past due ─────────────────────── */
.assignments-section {
    margin-bottom: 24px;
}
.assignments-section-heading {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 8px 0 6px;
    margin: 0 0 8px;
    border-bottom: 2px solid #e5e7eb;
}
.assignments-section-before-due {
    color: #1a3461;
}
.assignments-section-past-due {
    color: #dc2626;
    border-bottom-color: #fecaca;
}

/* ── Lesson assignment section ──────────────────────────────────────── */
.lesson-assignment-section {
    margin-top: 12px;
    padding-top: 8px;
    border-top: 1px solid #f3f4f6;
}
.lesson-assignment-complete-badge {
    font-size: 12px;
    font-weight: 600;
    color: #16a34a;
    background: #dcfce7;
    padding: 2px 8px;
    border-radius: 4px;
    white-space: nowrap;
}
