/*
   STUDENT COUNSEL PORTAL - UI SYSTEM
   Consistent with https://studentcounsel.co.in brand palette:
   Deep Blue (#136c96), Gold (#e3a830), Clean Light Surfaces (#f8fafc / #ffffff)
   Mobile-first, Non-Tech Friendly, High Readability
*/

:root {
    --sc-primary: #136c96;
    --sc-primary-dark: #0e5375;
    --sc-primary-light: #1c88bd;
    --sc-primary-soft: rgba(19, 108, 150, 0.08);
    --sc-gold: #e3a830;
    --sc-gold-dark: #c9911d;
    --sc-gold-soft: rgba(227, 168, 48, 0.14);

    --sc-bg: #f1f5f9;
    --sc-surface: #ffffff;
    --sc-surface-alt: #f8fafc;
    --sc-border: #e2e8f0;
    --sc-border-strong: #cbd5e1;

    --sc-text: #0f172a;
    --sc-text-body: #334155;
    --sc-text-muted: #64748b;

    --sc-green: #15803d;
    --sc-green-bg: #dcfce7;
    --sc-amber: #b45309;
    --sc-amber-bg: #fef3c7;
    --sc-red: #b91c1c;
    --sc-red-bg: #fee2e2;
    --sc-blue: #1d4ed8;
    --sc-blue-bg: #dbeafe;

    --sc-radius-sm: 8px;
    --sc-radius-md: 12px;
    --sc-radius-lg: 16px;
    --sc-shadow: 0 4px 18px rgba(15, 23, 42, 0.05);
    --sc-shadow-lg: 0 18px 42px rgba(15, 23, 42, 0.14);

    --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

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

body {
    font-family: var(--font-body);
    background-color: var(--sc-bg);
    color: var(--sc-text-body);
    line-height: 1.5;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    color: var(--sc-text);
    font-weight: 600;
    line-height: 1.25;
}

a {
    color: var(--sc-primary);
    text-decoration: none;
}

.hidden {
    display: none !important;
}

/* Top Portal Navbar */
.portal-header {
    background: #ffffff;
    border-bottom: 2px solid var(--sc-border);
    position: sticky;
    top: 0;
    z-index: 900;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
}

.portal-header-inner {
    max-width: 1380px;
    margin: 0 auto;
    padding: 10px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.portal-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.portal-brand img {
    width: 42px;
    height: 42px;
    object-fit: contain;
    border-radius: 8px;
}

.portal-brand-text {
    display: flex;
    flex-direction: column;
}

.portal-brand-title {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--sc-primary);
}

.portal-brand-title span {
    color: var(--sc-gold);
}

.portal-role-tag {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--sc-text-muted);
}

.portal-user-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.user-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--sc-surface-alt);
    border: 1px solid var(--sc-border);
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.85rem;
    color: var(--sc-text);
    font-weight: 500;
}

/* Main Container */
.portal-container {
    max-width: 1380px;
    margin: 0 auto;
    padding: 18px 16px 64px;
}

/* Buttons (Large Touch Targets for Non-Tech Users & Mobile) */
.p-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 40px;
    padding: 8px 16px;
    border-radius: var(--sc-radius-sm);
    font-family: var(--font-heading);
    font-size: 0.92rem;
    font-weight: 600;
    cursor: pointer;
    border: 1.5px solid transparent;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.p-btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.p-btn-sm {
    min-height: 34px;
    padding: 5px 11px;
    font-size: 0.82rem;
}

.p-btn-lg {
    min-height: 46px;
    padding: 11px 22px;
    font-size: 1rem;
}

.p-btn-primary {
    background: var(--sc-primary);
    color: #ffffff;
}
.p-btn-primary:hover:not(:disabled) {
    background: var(--sc-primary-dark);
}

.p-btn-gold {
    background: var(--sc-gold);
    color: #0f172a;
}
.p-btn-gold:hover:not(:disabled) {
    background: var(--sc-gold-dark);
    color: #ffffff;
}

.p-btn-outline {
    background: #ffffff;
    border-color: var(--sc-border-strong);
    color: var(--sc-text);
}
.p-btn-outline:hover:not(:disabled) {
    border-color: var(--sc-primary);
    color: var(--sc-primary);
}

.p-btn-success {
    background: var(--sc-green);
    color: #ffffff;
}
.p-btn-success:hover:not(:disabled) {
    background: #166534;
}

.p-btn-danger {
    background: var(--sc-red);
    color: #ffffff;
}
.p-btn-danger:hover:not(:disabled) {
    background: #991b1b;
}

.p-btn-danger-outline {
    background: #ffffff;
    border-color: #fca5a5;
    color: var(--sc-red);
}
.p-btn-danger-outline:hover:not(:disabled) {
    background: var(--sc-red-bg);
}

/* Status Badges */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
    white-space: nowrap;
}

.badge-green {
    background: var(--sc-green-bg);
    color: var(--sc-green);
}
.badge-amber {
    background: var(--sc-amber-bg);
    color: var(--sc-amber);
}
.badge-red {
    background: var(--sc-red-bg);
    color: var(--sc-red);
}
.badge-blue {
    background: var(--sc-blue-bg);
    color: var(--sc-blue);
}
.badge-gray {
    background: #e2e8f0;
    color: #475569;
}

/* Portal Navigation Tabs */
.portal-tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 4px 2px 12px;
    margin-bottom: 16px;
    scrollbar-width: none;
}

.portal-tabs::-webkit-scrollbar {
    display: none;
}

.tab-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: #ffffff;
    border: 1.5px solid var(--sc-border);
    border-radius: 999px;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.92rem;
    color: var(--sc-text-body);
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.18s ease;
}

.tab-pill:hover {
    border-color: var(--sc-primary);
    color: var(--sc-primary);
}

.tab-pill.active {
    background: var(--sc-primary);
    border-color: var(--sc-primary);
    color: #ffffff;
    box-shadow: 0 6px 16px rgba(19, 108, 150, 0.22);
}

.tab-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    border-radius: 999px;
    font-size: 0.75rem;
    background: var(--sc-gold);
    color: #0f172a;
}

/* Cards & Surfaces */
.p-card {
    background: var(--sc-surface);
    border: 1px solid var(--sc-border);
    border-radius: var(--sc-radius-md);
    padding: 18px;
    box-shadow: var(--sc-shadow);
    margin-bottom: 16px;
}

.p-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    padding-bottom: 12px;
    margin-bottom: 14px;
    border-bottom: 1px solid var(--sc-border);
}

.kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(175px, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}

.kpi-card {
    background: #ffffff;
    border: 1px solid var(--sc-border);
    border-left: 4px solid var(--sc-primary);
    border-radius: var(--sc-radius-md);
    padding: 14px 16px;
    box-shadow: var(--sc-shadow);
}

.kpi-card.gold {
    border-left-color: var(--sc-gold);
}
.kpi-card.green {
    border-left-color: var(--sc-green);
}
.kpi-card.amber {
    border-left-color: #d97706;
}
.kpi-card.red {
    border-left-color: var(--sc-red);
}

.kpi-label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--sc-text-muted);
    margin-bottom: 4px;
}

.kpi-value {
    font-family: var(--font-heading);
    font-size: 1.7rem;
    font-weight: 700;
    color: var(--sc-text);
}

/* Banners & Alerts */
.p-alert {
    padding: 12px 16px;
    border-radius: var(--sc-radius-sm);
    font-size: 0.9rem;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 14px;
}

.p-alert-info {
    background: var(--sc-primary-soft);
    border: 1px solid rgba(19, 108, 150, 0.25);
    color: var(--sc-primary-dark);
}

.p-alert-warn {
    background: var(--sc-amber-bg);
    border: 1px solid #fcd34d;
    color: #92400e;
}

.p-alert-success {
    background: var(--sc-green-bg);
    border: 1px solid #86efac;
    color: #166534;
}

.p-alert-error {
    background: var(--sc-red-bg);
    border: 1px solid #fca5a5;
    color: #991b1b;
}

/* Forms */
.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
}

.form-field {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-bottom: 10px;
}

.form-field label {
    font-size: 0.83rem;
    font-weight: 600;
    color: var(--sc-text);
}

.form-control {
    width: 100%;
    min-height: 42px;
    padding: 9px 12px;
    border: 1.5px solid var(--sc-border-strong);
    border-radius: var(--sc-radius-sm);
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--sc-text);
    background: #ffffff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--sc-primary);
    box-shadow: 0 0 0 3px rgba(19, 108, 150, 0.14);
}

textarea.form-control {
    min-height: 82px;
    resize: vertical;
}

/* Filter Panel */
.filter-bar {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
    gap: 10px;
    padding: 14px;
    background: var(--sc-surface-alt);
    border: 1px solid var(--sc-border);
    border-radius: var(--sc-radius-sm);
    margin-bottom: 14px;
}

.filter-actions {
    display: flex;
    gap: 8px;
    align-items: flex-end;
    flex-wrap: wrap;
}

/* Responsive Data Table (Desktop) + Mobile Cards */
.table-wrap {
    width: 100%;
    overflow-x: auto;
    border: 1px solid var(--sc-border);
    border-radius: var(--sc-radius-sm);
    background: #ffffff;
}

.p-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
}

.p-table th {
    background: var(--sc-surface-alt);
    color: var(--sc-text);
    font-family: var(--font-heading);
    font-weight: 600;
    text-align: left;
    padding: 11px 12px;
    border-bottom: 2px solid var(--sc-border);
    white-space: nowrap;
}

.p-table td {
    padding: 11px 12px;
    border-bottom: 1px solid var(--sc-border);
    vertical-align: middle;
}

.p-table tbody tr:hover {
    background: #f8fafc;
}

.mobile-card-list {
    display: none;
}

@media (max-width: 820px) {
    .desktop-table-wrap {
        display: none;
    }
    .mobile-card-list {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }
}

.student-mobile-card {
    background: #ffffff;
    border: 1px solid var(--sc-border);
    border-radius: var(--sc-radius-md);
    padding: 14px;
    box-shadow: var(--sc-shadow);
}

.student-mobile-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 8px;
}

.student-mobile-meta {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    font-size: 0.84rem;
    margin-bottom: 10px;
}

/* Progress Bar */
.progress-track {
    width: 100%;
    height: 10px;
    background: #e2e8f0;
    border-radius: 999px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--sc-primary) 0%, #16a34a 100%);
    border-radius: 999px;
    transition: width 0.3s ease;
}

/* Counseling Board Card & Checkboxes */
.board-card {
    background: #ffffff;
    border: 1.5px solid var(--sc-border);
    border-radius: var(--sc-radius-md);
    padding: 16px;
    margin-bottom: 14px;
}

.board-card-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.checkpoint-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 11px 12px;
    border: 1px solid var(--sc-border);
    border-radius: var(--sc-radius-sm);
    margin-bottom: 8px;
    background: var(--sc-surface-alt);
    flex-wrap: wrap;
}

.checkpoint-row.done {
    background: #f0fdf4;
    border-color: #bbf7d0;
}

.checkpoint-row.pending-admin {
    background: #fffbeb;
    border-color: #fde68a;
}

.checkpoint-main {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    flex: 1;
    min-width: 220px;
}

.checkpoint-check {
    width: 22px;
    height: 22px;
    accent-color: var(--sc-primary);
    cursor: pointer;
    margin-top: 2px;
    flex-shrink: 0;
}

/* Document Checklist Grid */
.doc-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
    gap: 12px;
}

.doc-card {
    background: #ffffff;
    border: 1.5px solid var(--sc-border);
    border-radius: var(--sc-radius-md);
    padding: 14px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 10px;
}

.doc-card.verified {
    border-color: #86efac;
    background: #f0fdf4;
}

.doc-card.rejected {
    border-color: #fca5a5;
    background: #fef2f2;
}

.doc-card.uploaded {
    border-color: #93c5fd;
    background: #eff6ff;
}

.doc-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* Pagination */
.pagination-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 14px;
}

/* Modals */
.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px;
}

.modal-box {
    width: 100%;
    max-width: 960px;
    max-height: 92vh;
    background: #ffffff;
    border-radius: var(--sc-radius-lg);
    box-shadow: var(--sc-shadow-lg);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.modal-box > form {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

.modal-box.modal-sm {
    max-width: 520px;
}

.modal-head {
    padding: 14px 20px;
    background: var(--sc-primary);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-shrink: 0;
}

.modal-head h3 {
    color: #ffffff;
    font-size: 1.12rem;
}

.modal-close {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.18);
    color: #ffffff;
    font-size: 1.2rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.modal-body {
    padding: 18px 20px;
    overflow-y: auto;
    flex: 1;
    min-height: 0;
    -webkit-overflow-scrolling: touch;
}

.modal-foot {
    padding: 12px 20px;
    background: var(--sc-surface-alt);
    border-top: 1px solid var(--sc-border);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
    flex-shrink: 0;
}

/* Login Page Specific Layout */
.auth-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: radial-gradient(circle at top right, rgba(19, 108, 150, 0.12), transparent 55%),
                radial-gradient(circle at bottom left, rgba(227, 168, 48, 0.12), transparent 50%),
                #f8fafc;
}

.auth-main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
}

.auth-card {
    width: 100%;
    max-width: 470px;
    background: #ffffff;
    border: 1px solid var(--sc-border);
    border-top: 5px solid var(--sc-primary);
    border-radius: var(--sc-radius-lg);
    padding: 28px 26px;
    box-shadow: var(--sc-shadow-lg);
}

.auth-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    background: var(--sc-surface-alt);
    padding: 5px;
    border-radius: var(--sc-radius-sm);
    margin-bottom: 20px;
}

.auth-tab-btn {
    padding: 10px 8px;
    border: none;
    border-radius: 6px;
    background: transparent;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--sc-text-muted);
    cursor: pointer;
}

.auth-tab-btn.active {
    background: #ffffff;
    color: var(--sc-primary);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

/* Toast Notifications */
.toast-stack {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 3000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 380px;
    width: calc(100vw - 32px);
}

.toast-item {
    padding: 12px 16px;
    border-radius: var(--sc-radius-sm);
    background: #0f172a;
    color: #ffffff;
    font-size: 0.9rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.22);
    display: flex;
    align-items: center;
    gap: 10px;
    animation: fadeInToast 0.22s ease;
}

.toast-item.success {
    background: #15803d;
}
.toast-item.error {
    background: #b91c1c;
}
.toast-item.warn {
    background: #b45309;
}

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

/* Board Checklist Box in Student Creation Modal */
.board-selector-box {
    max-height: 220px;
    overflow-y: auto;
    border: 1.5px solid var(--sc-border);
    border-radius: var(--sc-radius-sm);
    padding: 10px;
    background: var(--sc-surface-alt);
}

.board-check-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 4px;
    font-size: 0.88rem;
    cursor: pointer;
}

/* Read-only Key/Value Grid */
.kv-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 10px;
}

.kv-item {
    padding: 10px 12px;
    background: var(--sc-surface-alt);
    border: 1px solid var(--sc-border);
    border-radius: var(--sc-radius-sm);
}

.kv-label {
    font-size: 0.76rem;
    font-weight: 600;
    color: var(--sc-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 2px;
}

.kv-val {
    font-size: 0.96rem;
    font-weight: 600;
    color: var(--sc-text);
    word-break: break-word;
}

/* Enhanced Document Preview Modal & Zoom Toolbar */
.modal-doc-preview-box {
    width: 96vw;
    max-width: 1140px;
    background: var(--sc-surface);
    border-radius: var(--sc-radius);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.doc-zoom-toolbar {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    background: #f1f5f9;
    padding: 8px 14px;
    border-bottom: 1px solid var(--sc-border);
}

.doc-zoom-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 6px 12px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    color: #334155;
    font-size: 0.84rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease;
    user-select: none;
}

.doc-zoom-btn:hover {
    background: #e2e8f0;
    color: #0f172a;
    border-color: #94a3b8;
}

.doc-zoom-btn:active {
    transform: scale(0.96);
}

.zoom-level-badge {
    display: inline-block;
    padding: 4px 10px;
    background: #e0f2fe;
    color: #0369a1;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 700;
    min-width: 54px;
    text-align: center;
}

.doc-preview-viewport {
    width: 100%;
    height: 72vh;
    min-height: 480px;
    background: #0f172a;
    overflow: auto;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.doc-preview-viewport::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}
.doc-preview-viewport::-webkit-scrollbar-thumb {
    background: #475569;
    border-radius: 6px;
}

.preview-frame {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 6px;
    background: #ffffff;
}

.preview-img {
    max-width: 95%;
    max-height: 95%;
    margin: auto;
    display: block;
    border-radius: 4px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    user-select: none;
    -webkit-user-drag: none;
}

@media (max-width: 600px) {
    .portal-header-inner {
        padding: 10px 12px;
    }
    .p-card {
        padding: 14px;
    }
    .modal-body {
        padding: 14px;
    }
    .kpi-value {
        font-size: 1.45rem;
    }
}


/* At-a-glance Progress Table Cells */
.mini-progress-track {
    width: 100%;
    min-width: 120px;
    height: 8px;
    background: #e2e8f0;
    border-radius: 999px;
    overflow: hidden;
    margin: 5px 0;
}

.mini-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--sc-primary) 0%, #16a34a 100%);
    border-radius: 999px;
    transition: width 0.3s ease;
}

.mini-progress-fill.docs {
    background: linear-gradient(90deg, #0284c7 0%, #0ea5e9 100%);
}

.status-note-line {
    font-size: 0.77rem;
    line-height: 1.35;
    color: var(--sc-text-muted);
    margin-top: 2px;
}

.status-note-line strong {
    color: var(--sc-text-body);
}

/* Employee To-Do List */
.todo-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    border: 1.5px solid var(--sc-border);
    border-radius: var(--sc-radius-sm);
    background: #ffffff;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.todo-row.todo-done {
    background: #f8fafc;
    border-color: var(--sc-border);
    opacity: 0.78;
}

.todo-row.todo-done .todo-title-text {
    text-decoration: line-through;
    color: var(--sc-text-muted);
}

.todo-main {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    flex: 1;
    min-width: 220px;
}

.alt-contact-hint {
    font-size: 0.78rem;
    color: var(--sc-primary-dark);
    background: var(--sc-primary-soft);
    padding: 6px 10px;
    border-radius: 6px;
    margin: 2px 0 8px;
    font-weight: 500;
}

/* Checkpoint Attached Documents (Requirement 11) */
.checkpoint-docs-box {
    margin-top: 8px;
    padding: 8px 10px;
    background: #f8fafc;
    border: 1px dashed var(--sc-border);
    border-radius: var(--sc-radius-sm);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.checkpoint-docs-empty {
    font-size: 0.78rem;
    color: var(--sc-text-muted);
    font-style: italic;
}

.cp-doc-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.78rem;
    background: #ffffff;
    border: 1px solid var(--sc-border);
    border-radius: 999px;
    padding: 3px 10px;
    color: var(--sc-text);
    text-decoration: none;
    transition: all 0.15s ease;
}

.cp-doc-badge:hover {
    border-color: var(--sc-primary);
    background: var(--sc-primary-soft);
    color: var(--sc-primary-dark);
}

.cp-doc-badge i.del-icon {
    color: #ef4444;
    cursor: pointer;
    margin-left: 4px;
}

.cp-doc-badge i.del-icon:hover {
    color: #b91c1c;
}

/* Notice Board (Requirement 7) */
.notice-card {
    background: #ffffff;
    border: 1.5px solid var(--sc-border);
    border-left: 5px solid var(--sc-primary);
    border-radius: var(--sc-radius-md);
    padding: 16px;
    margin-bottom: 14px;
    box-shadow: var(--sc-shadow);
    transition: transform 0.15s ease;
}

.notice-card.urgent {
    border-left-color: #ef4444;
    background: #fffdfd;
}

.notice-card.important {
    border-left-color: #f59e0b;
    background: #fffdf7;
}

.notice-card.pinned {
    box-shadow: 0 4px 14px rgba(30, 58, 138, 0.12);
}

.notice-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.notice-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--sc-text);
    display: flex;
    align-items: center;
    gap: 8px;
}

.notice-body {
    font-size: 0.9rem;
    color: var(--sc-text-body);
    line-height: 1.55;
    white-space: pre-wrap;
    margin-bottom: 8px;
}

.notice-meta {
    font-size: 0.78rem;
    color: var(--sc-text-muted);
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    align-items: center;
}

/* Counseling Schedule (Requirement 6) */
.schedule-item-card {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    padding: 14px 16px;
    background: #ffffff;
    border: 1.5px solid var(--sc-border);
    border-radius: var(--sc-radius-md);
    margin-bottom: 12px;
}

.schedule-date-badge {
    background: var(--sc-primary-soft);
    color: var(--sc-primary-dark);
    border: 1.5px solid var(--sc-primary);
    border-radius: var(--sc-radius-sm);
    padding: 8px 12px;
    text-align: center;
    min-width: 90px;
}

.schedule-date-badge.is-today {
    background: #fef2f2;
    color: #dc2626;
    border-color: #ef4444;
    animation: pulse 2s infinite;
}

.schedule-content {
    flex: 1;
}

.schedule-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--sc-text);
    margin-bottom: 4px;
}

.schedule-desc {
    font-size: 0.86rem;
    color: var(--sc-text-body);
    line-height: 1.45;
}

/* Correction Requests (Requirement 12) */
.correction-request-card {
    background: #ffffff;
    border: 1.5px solid var(--sc-border);
    border-radius: var(--sc-radius-md);
    padding: 14px;
    margin-bottom: 10px;
}

.correction-request-card.pending {
    border-left: 4px solid var(--sc-amber);
}

.correction-request-card.resolved {
    border-left: 4px solid var(--sc-green);
    background: #f8fafc;
}

/* Due Date Alert / Reminder Popup Modal (Requirements 6 & 14) */
.alert-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    padding: 20px;
}

.alert-popup-box {
    background: #ffffff;
    border-radius: var(--sc-radius-md);
    width: 100%;
    max-width: 520px;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
    border: 2px solid #ef4444;
}

.alert-popup-head {
    padding: 16px 20px;
    background: #fef2f2;
    border-bottom: 1.5px solid #fee2e2;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.alert-popup-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: #991b1b;
    display: flex;
    align-items: center;
    gap: 8px;
}

.alert-popup-body {
    padding: 18px 20px;
}

.alert-popup-footer {
    padding: 12px 20px;
    background: #f8fafc;
    border-top: 1px solid var(--sc-border);
    display: flex;
    justify-content: flex-end;
}
