@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
    /* Color Palette */
    --primary-hue: 250;
    --primary: hsl(var(--primary-hue), 85%, 60%);
    --primary-hover: hsl(var(--primary-hue), 85%, 50%);
    --primary-light: hsl(var(--primary-hue), 85%, 95%);
    --primary-glow: hsla(var(--primary-hue), 85%, 60%, 0.15);
    
    --secondary-hue: 190;
    --secondary: hsl(var(--secondary-hue), 90%, 50%);
    --secondary-hover: hsl(var(--secondary-hue), 90%, 40%);
    
    --bg-dark: #0f1016;
    --bg-card-dark: rgba(22, 24, 35, 0.7);
    --border-dark: rgba(255, 255, 255, 0.08);
    
    --bg-light: #f5f6fa;
    --bg-card-light: rgba(255, 255, 255, 0.85);
    --border-light: rgba(0, 0, 0, 0.06);

    /* Context Colors */
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --info: #3b82f6;

    /* Theme-dependent settings (defaults to Dark Mode for premium feel) */
    --background: var(--bg-dark);
    --card-bg: var(--bg-card-dark);
    --border-color: var(--border-dark);
    --text-primary: #f3f4f6;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;
    --glass-blur: 16px;
    --shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    
    /* Layout Constants */
    --sidebar-width: 260px;
    --header-height: 70px;
    --border-radius-sm: 8px;
    --border-radius-md: 14px;
    --border-radius-lg: 24px;
    --font-sans: 'Inter', sans-serif;
    --font-heading: 'Outfit', sans-serif;
}

/* Light Theme overrides */
[data-theme="light"] {
    --background: var(--bg-light);
    --card-bg: var(--bg-card-light);
    --border-color: var(--border-light);
    --text-primary: #1f2937;
    --text-secondary: #4b5563;
    --text-muted: #9ca3af;
    --shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.08);
    --primary-light: hsl(var(--primary-hue), 85%, 90%);
}

/* Global Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--font-sans);
}

body {
    background-color: var(--background);
    color: var(--text-primary);
    overflow-x: hidden;
    min-height: 100vh;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: var(--background);
}
::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 600;
    letter-spacing: -0.02em;
}

/* Glassmorphism Cards */
.glass-card {
    background: var(--card-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s ease, border-color 0.3s ease;
}

.glass-card:hover {
    border-color: rgba(255, 255, 255, 0.15);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    font-family: var(--font-sans);
    font-weight: 500;
    font-size: 0.95rem;
    border-radius: var(--border-radius-sm);
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), hsl(var(--primary-hue), 85%, 50%));
    color: #ffffff;
    box-shadow: 0 4px 14px 0 var(--primary-glow);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px 0 var(--primary-glow);
}
.btn-primary:active {
    transform: translateY(0);
}

.btn-secondary {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}
.btn-secondary:hover {
    background: var(--border-color);
}

.btn-danger {
    background: var(--danger);
    color: #ffffff;
}
.btn-danger:hover {
    background: #dc2626;
    transform: translateY(-1px);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.85rem;
    border-radius: var(--border-radius-sm);
}

/* Text Inputs & Form Controls */
.form-group {
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-secondary);
    letter-spacing: 0.01em;
}

.form-input {
    width: 100%;
    padding: 12px 16px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: all 0.25s ease;
}

[data-theme="light"] .form-input {
    background: rgba(255, 255, 255, 0.5);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%239ca3af'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 16px;
    padding-right: 40px;
}

/* Auth Page Layout */
.auth-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: radial-gradient(circle at 10% 20%, rgba(98, 76, 245, 0.15) 0%, transparent 45%),
                radial-gradient(circle at 90% 80%, rgba(30, 200, 245, 0.1) 0%, transparent 45%),
                var(--background);
    transition: background-color 0.3s ease;
}

.auth-card {
    width: 100%;
    max-width: 440px;
    padding: 40px;
    position: relative;
    overflow: hidden;
}

.auth-header {
    text-align: center;
    margin-bottom: 30px;
}

.auth-header h1 {
    font-size: 2rem;
    margin-bottom: 8px;
    background: linear-gradient(135deg, #fff 30%, var(--text-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

[data-theme="light"] .auth-header h1 {
    background: linear-gradient(135deg, var(--primary) 30%, #1f2937);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.auth-header p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.auth-logo {
    width: 60px;
    height: 60px;
    margin: 0 auto 16px auto;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: var(--border-radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 20px rgba(98, 76, 245, 0.3);
}

.auth-logo svg {
    width: 32px;
    height: 32px;
    color: white;
}

/* Dashboard Base Layout */
.dashboard-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    border-right: 1px solid var(--border-color);
    background: var(--card-bg);
    backdrop-filter: blur(var(--glass-blur));
    display: flex;
    flex-direction: column;
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    z-index: 100;
}

.sidebar-logo {
    height: var(--header-height);
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 24px;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-logo svg {
    width: 28px;
    height: 28px;
    color: var(--primary);
}

.sidebar-logo span {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.sidebar-menu {
    list-style: none;
    padding: 24px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-grow: 1;
}

.sidebar-item a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    border-radius: var(--border-radius-sm);
    transition: all 0.2s ease;
}

.sidebar-item a svg {
    width: 20px;
    height: 20px;
    transition: transform 0.2s ease;
}

.sidebar-item a:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.04);
}

.sidebar-item a:hover svg {
    transform: translateX(2px);
}

[data-theme="light"] .sidebar-item a:hover {
    background: rgba(0, 0, 0, 0.03);
}

.sidebar-item.active a {
    color: white;
    background: var(--primary);
    box-shadow: 0 4px 12px var(--primary-glow);
}

.sidebar-footer {
    padding: 16px;
    border-top: 1px solid var(--border-color);
}

/* Main Content Area */
.main-content {
    margin-left: var(--sidebar-width);
    flex-grow: 1;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    min-width: 0; /* Prevents flex children blowout and horizontal cutoff */
}

/* Header */
.dashboard-header {
    height: var(--header-height);
    border-bottom: 1px solid var(--border-color);
    background: var(--card-bg);
    backdrop-filter: blur(var(--glass-blur));
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
    position: sticky;
    top: 0;
    z-index: 90;
}

.header-title h2 {
    font-size: 1.35rem;
}

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

.theme-toggle {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-secondary);
    padding: 6px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.theme-toggle:hover {
    color: var(--text-primary);
    background: var(--border-color);
}

.user-profile-summary {
    display: flex;
    align-items: center;
    gap: 12px;
}

.avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.95rem;
    border: 2px solid var(--border-color);
}

.user-details {
    display: flex;
    flex-direction: column;
}

.user-name {
    font-size: 0.9rem;
    font-weight: 600;
}

.user-role {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Dashboard Main View Container */
.dashboard-view {
    padding: 32px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 32px;
}

/* Metrics Row */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
}

.metric-card {
    padding: 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.metric-info {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.metric-label {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.metric-value {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 700;
}

.metric-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--border-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
}

.metric-icon.blue {
    background: rgba(59, 130, 246, 0.15);
    color: var(--info);
}

.metric-icon.green {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.metric-icon.yellow {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.metric-icon.purple {
    background: rgba(98, 76, 245, 0.15);
    color: var(--primary);
}

/* Data Tables */
.table-container {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.95rem;
}

.data-table th {
    padding: 16px 24px;
    border-bottom: 2px solid var(--border-color);
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.data-table td {
    padding: 16px 24px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-primary);
    vertical-align: middle;
}

.data-table tbody tr {
    transition: background-color 0.2s ease;
}

.data-table tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.02);
}

[data-theme="light"] .data-table tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.01);
}

/* Status Badges */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.badge-success {
    background: rgba(16, 185, 129, 0.12);
    color: #10b981;
}

.badge-danger {
    background: rgba(239, 68, 68, 0.12);
    color: #ef4444;
}

.badge-warning {
    background: rgba(245, 158, 11, 0.12);
    color: #f59e0b;
}

.badge-info {
    background: rgba(59, 130, 246, 0.12);
    color: #3b82f6;
}

/* Cards & Content Layout */
.dashboard-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 32px;
}

@media (max-width: 1024px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

.card-header {
    padding: 24px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.card-title h3 {
    font-size: 1.1rem;
}

.card-body {
    padding: 24px;
}

/* Actions Column / Flex aligners */
.actions-cell {
    display: flex;
    gap: 8px;
}

/* Dialog / Modal Styling (Custom glass modal) */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.modal.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.9);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal.active .modal-content {
    transform: scale(1);
}

/* Notification Toast */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 2000;
}

.toast {
    padding: 16px 24px;
    border-radius: var(--border-radius-sm);
    color: white;
    font-weight: 500;
    font-size: 0.9rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 12px;
    animation: slideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.toast-success {
    background: var(--success);
}

.toast-error {
    background: var(--danger);
}

@keyframes slideIn {
    from {
        transform: translateY(100%) scale(0.9);
        opacity: 0;
    }
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

/* Tab controls */
.tabs-header {
    display: flex;
    gap: 8px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0px;
}

.tab-btn {
    background: none;
    border: none;
    padding: 12px 20px;
    font-family: var(--font-sans);
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    position: relative;
    transition: color 0.2s ease;
}

.tab-btn:hover {
    color: var(--text-primary);
}

.tab-btn.active {
    color: var(--primary);
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary);
    border-radius: 2px;
}

.tab-pane {
    display: none;
    animation: fadeIn 0.4s ease;
}

.tab-pane.active {
    display: block;
}

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

/* Custom visual list elements */
.grade-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 0;
    border-bottom: 1px solid var(--border-color);
}
.grade-item:last-child {
    border-bottom: none;
}

/* Animations helper */
.animate-delay-1 { animation-delay: 0.1s; }
.animate-delay-2 { animation-delay: 0.2s; }
.animate-delay-3 { animation-delay: 0.3s; }

/* Course Layouts */
.courses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.course-card {
    padding: 24px;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.course-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 12px;
}

.course-code {
    font-weight: 700;
    color: var(--primary);
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.course-body {
    flex-grow: 1;
    margin-bottom: 20px;
}

.course-title {
    font-size: 1.15rem;
    margin-bottom: 8px;
}

.course-desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.course-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-color);
    padding-top: 16px;
    margin-top: auto;
}

.enrolled-badge {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* Printing styles */
@media print {
    /* Hide layout structures */
    .sidebar,
    .dashboard-header,
    .btn,
    .theme-toggle,
    .form-group,
    .actions-cell,
    .toast-container,
    .modal,
    .metrics-grid,
    #studentSearch,
    #addStudentBtn,
    .card-header button,
    #logoutBtn,
    .sidebar-footer {
        display: none !important;
    }

    body {
        background: white !important;
        color: black !important;
        font-size: 12pt !important;
    }

    .main-content {
        margin-left: 0 !important;
        padding: 0 !important;
    }

    .dashboard-view {
        padding: 20px !important;
    }

    .glass-card {
        border: 1px solid #ddd !important;
        box-shadow: none !important;
        background: transparent !important;
        backdrop-filter: none !important;
        margin-bottom: 20px !important;
        page-break-inside: avoid !important;
    }

    .card-header {
        border-bottom: 2px solid #333 !important;
        background: transparent !important;
        color: black !important;
        padding: 10px 0 !important;
    }

    .card-title h3 {
        font-size: 1.4rem !important;
        color: black !important;
    }

    .data-table {
        width: 100% !important;
        border: 1px solid #ddd !important;
    }

    .data-table th {
        background: #f3f4f6 !important;
        color: black !important;
        border-bottom: 2px solid #aaa !important;
        font-size: 10pt !important;
    }

    .data-table td {
        color: black !important;
        border-bottom: 1px solid #ddd !important;
        font-size: 10pt !important;
    }

    .badge {
        border: 1px solid #ccc !important;
        background: transparent !important;
        color: black !important;
        padding: 2px 6px !important;
    }
    
    .transcript-watermark {
        color: rgba(239, 68, 68, 0.08) !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }
    
    .gold-seal {
        background: radial-gradient(circle, #f59e0b 0%, #d97706 70%, #b45309 100%) !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }
}

/* Academic Progress Bar */
.progress-track {
    width: 100%;
    background: var(--border-color);
    border-radius: 10px;
    height: 8px;
    overflow: hidden;
    position: relative;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary) 0%, var(--primary-glow) 100%);
    border-radius: 10px;
    transition: width 0.4s ease-out;
}

/* Eligibility Badges */
.eligible-badge {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 6px 12px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.ineligible-badge {
    background: rgba(245, 158, 11, 0.15);
    color: #f59e0b;
    border: 1px solid rgba(245, 158, 11, 0.3);
    padding: 6px 12px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* Status specific CSS colors */
.status-badge {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    display: inline-block;
    text-align: center;
}
.status-not-started { background: rgba(100, 116, 139, 0.12) !important; color: #64748b !important; }
.status-in-progress { background: rgba(59, 130, 246, 0.12) !important; color: #3b82f6 !important; }
.status-exam-registered { background: rgba(147, 51, 234, 0.12) !important; color: #9333ea !important; }
.status-exam-completed { background: rgba(236, 72, 153, 0.12) !important; color: #ec4899 !important; }
.status-competent { background: rgba(16, 185, 129, 0.12) !important; color: #10b981 !important; }
.status-not-yet-competent { background: rgba(239, 68, 68, 0.12) !important; color: #ef4444 !important; }

/* Fees Management Statuses */
.status-active { background: rgba(16, 185, 129, 0.15) !important; color: #10b981 !important; border: 1px solid rgba(16, 185, 129, 0.3); }
.status-due-today { background: rgba(245, 158, 11, 0.15) !important; color: #f59e0b !important; border: 1px solid rgba(245, 158, 11, 0.3); }
.status-grace-period { background: rgba(59, 130, 246, 0.15) !important; color: #3b82f6 !important; border: 1px solid rgba(59, 130, 246, 0.3); }
.status-overdue { background: rgba(249, 115, 22, 0.15) !important; color: #f97316 !important; border: 1px solid rgba(249, 115, 22, 0.3); }
.status-suspended { background: rgba(239, 68, 68, 0.15) !important; color: #ef4444 !important; border: 1px solid rgba(239, 68, 68, 0.3); }
.status-graduated { background: rgba(168, 85, 247, 0.15) !important; color: #a855f7 !important; border: 1px solid rgba(168, 85, 247, 0.3); }
.status-discontinued { background: rgba(100, 116, 139, 0.15) !important; color: #64748b !important; border: 1px solid rgba(100, 116, 139, 0.3); }

/* Ledger debit/credit formatting */
.ledger-debit {
    color: var(--text-primary) !important;
    font-weight: 500;
}
.ledger-credit {
    color: #10b981 !important;
    font-weight: 600;
}
.ledger-balance {
    font-weight: 600;
    color: var(--primary) !important;
}

/* Header Notifications Bell */
.notification-bell {
    position: relative;
    cursor: pointer;
    color: var(--text-secondary);
    padding: 6px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}
.notification-bell:hover {
    color: var(--text-primary);
    background: var(--border-color);
}
.notification-badge {
    position: absolute;
    top: 2px;
    right: 2px;
    background: var(--danger);
    color: white;
    font-size: 0.7rem;
    font-weight: 700;
    border-radius: 50%;
    min-width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2px;
}
.notification-dropdown {
    position: absolute;
    top: 55px;
    right: 20px;
    width: 320px;
    background: var(--card-bg);
    backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    box-shadow: var(--shadow);
    z-index: 1000;
    display: none;
    flex-direction: column;
    max-height: 400px;
    overflow-y: auto;
}
.notification-dropdown.active {
    display: flex;
}
.notification-header {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
    font-weight: 600;
    font-size: 0.9rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.notification-item {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    gap: 4px;
    transition: background 0.2s ease;
}
.notification-item:hover {
    background: rgba(255, 255, 255, 0.02);
}
.notification-item-title {
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--text-primary);
}
.notification-item-msg {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.4;
}
.notification-item-date {
    font-size: 0.7rem;
    color: var(--text-muted);
}
.notification-item.critical {
    border-left: 3px solid var(--danger);
}
.notification-item.warning {
    border-left: 3px solid var(--warning);
}
.notification-item.info {
    border-left: 3px solid var(--info);
}

/* Unit Selection Grid in Modals */
.unit-selection-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
    margin-top: 8px;
    max-height: 150px;
    overflow-y: auto;
    border: 1px solid var(--border-color);
    padding: 12px;
    border-radius: var(--border-radius-sm);
    background: rgba(255, 255, 255, 0.02);
}

.unit-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    cursor: pointer;
    user-select: none;
    color: var(--text-primary);
}

.unit-checkbox-label input {
    cursor: pointer;
}

/* CSV Upload card design */
.csv-upload-area {
    border: 2px dashed var(--border-color);
    padding: 24px;
    border-radius: var(--border-radius-sm);
    text-align: center;
    background: rgba(255,255,255,0.01);
    transition: all 0.2s ease;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.csv-upload-area:hover {
    border-color: var(--primary);
    background: rgba(98, 76, 245, 0.02);
}

/* Transcripts styling */
.transcript-watermark {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-45deg);
    font-size: 80pt;
    font-weight: 900;
    color: rgba(239, 68, 68, 0.06);
    pointer-events: none;
    white-space: nowrap;
    z-index: 0;
    letter-spacing: 10px;
    text-transform: uppercase;
}

.gold-seal {
    width: 64px;
    height: 64px;
    background: radial-gradient(circle, #f59e0b 0%, #d97706 70%, #b45309 100%);
    border: 3px double #fef08a;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15), inset 0 2px 4px rgba(255,255,255,0.3);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fef08a;
    font-weight: bold;
    font-size: 0.8rem;
    text-align: center;
    line-height: 1.1;
    text-transform: uppercase;
    font-family: 'Georgia', serif;
}

.gold-seal::before {
    content: '';
    position: absolute;
    border: 1px dashed #fef08a;
    width: 54px;
    height: 54px;
    border-radius: 50%;
}

/* Responsive Grid Classes */
.settings-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 16px;
}
@media (max-width: 1200px) {
    .settings-grid {
        grid-template-columns: 1fr 1fr;
    }
}
@media (max-width: 800px) {
    .settings-grid {
        grid-template-columns: 1fr;
    }
}

.form-row-2 {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 12px;
}
@media (max-width: 800px) {
    .form-row-2 {
        grid-template-columns: 1fr;
    }
}

.balance-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}
@media (max-width: 800px) {
    .balance-grid {
        grid-template-columns: 1fr;
    }
}

/* Global Mobile/Tablet Responsiveness Overrides */
@media (max-width: 1024px) {
    .dashboard-container {
        flex-direction: column;
    }
    
    .sidebar {
        position: relative;
        width: 100%;
        height: auto;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }
    
    .sidebar-logo {
        height: 60px;
    }
    
    .sidebar-menu {
        flex-direction: row;
        flex-wrap: wrap;
        padding: 12px 16px;
        gap: 6px;
    }
    
    .sidebar-item a {
        padding: 8px 12px;
        font-size: 0.85rem;
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .dashboard-header {
        padding: 0 16px;
        height: 60px;
    }
    
    .dashboard-view {
        padding: 16px;
        gap: 20px;
    }
    
    .metrics-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .modal-content {
        width: 95%;
        margin: 10px;
    }
}
