/* ==========================================================================
   FinT Universal Light & Night Mode Stylesheet
   Seamless, crisp, high-contrast Day Mode across all Student & Staff / ERP screens.
   ========================================================================== */

/* ── Root & Base Transitions ── */
html.light-mode,
body.light-mode {
    background-color: #f8fafc !important; /* slate-50 */
    color: #0f172a !important; /* slate-900 */
}

/* ── Container & Panel Backgrounds ── */
.light-mode .bg-slate-955,
.light-mode .bg-slate-950,
.light-mode .bg-slate-950\/95,
.light-mode .bg-slate-950\/90,
.light-mode .bg-slate-950\/85,
.light-mode .bg-slate-950\/80,
.light-mode .bg-slate-950\/70,
.light-mode .bg-slate-950\/60,
.light-mode .bg-slate-950\/50,
.light-mode .bg-slate-950\/40,
.light-mode .bg-slate-950\/30,
.light-mode .bg-slate-950\/20,
.light-mode .bg-slate-950\/10 {
    background-color: #f8fafc !important;
}

/* Modal Backdrops & Overlays (soft darkened blur overlay in Day Mode) */
.light-mode .fixed.inset-0.bg-slate-950\/80,
.light-mode .fixed.inset-0.bg-slate-950\/70,
.light-mode .fixed.inset-0[class*="backdrop-blur"],
.light-mode [id*="modal"].fixed.inset-0 {
    background-color: rgba(15, 23, 42, 0.45) !important;
}

.light-mode .bg-slate-900,
.light-mode .bg-slate-900\/95,
.light-mode .bg-slate-900\/90,
.light-mode .bg-slate-900\/85,
.light-mode .bg-slate-900\/80,
.light-mode .bg-slate-900\/70,
.light-mode .bg-slate-900\/60,
.light-mode .bg-slate-900\/50,
.light-mode .bg-slate-900\/40,
.light-mode .bg-slate-850,
.light-mode .bg-slate-850\/50,
.light-mode .bg-slate-800\/40,
.light-mode .bg-slate-800\/50,
.light-mode .bg-slate-800\/60 {
    background-color: #ffffff !important;
    border-color: #e2e8f0 !important;
    box-shadow: 0 4px 14px -2px rgba(27, 70, 138, 0.06), 0 1px 3px rgba(0, 0, 0, 0.03) !important;
}

.light-mode .bg-slate-850,
.light-mode .bg-slate-800 {
    background-color: #f1f5f9 !important; /* slate-100 */
}

.light-mode .bg-slate-750,
.light-mode .bg-slate-700 {
    background-color: #e2e8f0 !important; /* slate-200 */
}

.light-mode .bg-slate-800\/30 {
    background-color: #f8fafc !important;
}

/* ── Borders ── */
.light-mode .border-slate-950,
.light-mode .border-slate-900,
.light-mode .border-slate-850,
.light-mode .border-slate-800,
.light-mode .border-slate-750,
.light-mode .border-slate-700,
.light-mode .border-slate-600,
.light-mode .border-slate-800\/40,
.light-mode .border-slate-800\/50,
.light-mode .border-slate-800\/60,
.light-mode .border-slate-800\/80,
.light-mode .border-slate-700\/50,
.light-mode .border-slate-700\/80 {
    border-color: #e2e8f0 !important; /* slate-200 */
}

/* ── Typography / Text Colors (High Contrast & Zero Eye Strain in Day Mode) ── */
.light-mode .text-white,
.light-mode .text-white\/90,
.light-mode .text-white\/80,
.light-mode .text-white\/70,
.light-mode .text-slate-100,
.light-mode .text-slate-200,
.light-mode .text-slate-300,
.light-mode .text-slate-350,
.light-mode .text-slate-355,
.light-mode .text-gray-100,
.light-mode .text-gray-200,
.light-mode .text-gray-300 {
    color: #0f172a !important; /* slate-900 */
}

.light-mode .text-white\/60,
.light-mode .text-white\/50,
.light-mode .text-white\/40,
.light-mode .text-slate-400,
.light-mode .text-slate-400\/80,
.light-mode .text-slate-400\/90,
.light-mode .text-gray-400,
.light-mode .text-gray-500 {
    color: #475569 !important; /* slate-600 */
}

.light-mode .text-slate-500,
.light-mode .text-slate-500\/80 {
    color: #64748b !important; /* slate-500 */
}

.light-mode .text-slate-600,
.light-mode .text-gray-600 {
    color: #334155 !important; /* slate-700 */
}

/* Ensure white text inside active buttons and dark pill badges stays crisp white */
.light-mode button[type="submit"],
.light-mode button[type="submit"] *,
.light-mode .btn-primary,
.light-mode .btn-primary *,
.light-mode #auth-submit-btn,
.light-mode #auth-submit-btn *,
.light-mode .auth-tab-active,
.light-mode .auth-tab-active *,
.light-mode .tab-active,
.light-mode .tab-active *,
.light-mode .subtab-active,
.light-mode .subtab-active *,
.light-mode #btn-login,
.light-mode #btn-login *,
.light-mode #la-open,
.light-mode #la-open *,
.light-mode .dash-join,
.light-mode .dash-join *,
.light-mode button.bg-blue-600,
.light-mode button.bg-blue-600 *,
.light-mode button.bg-emerald-600,
.light-mode button.bg-emerald-600 *,
.light-mode button.bg-indigo-600,
.light-mode button.bg-indigo-600 *,
.light-mode button.bg-lime-600,
.light-mode button.bg-lime-600 *,
.light-mode button.bg-amber-600,
.light-mode button.bg-amber-600 *,
.light-mode button.bg-rose-600,
.light-mode button.bg-rose-600 * {
    color: #ffffff !important;
}

/* ── Headers, Sidebars & Sticky Bars ── */
.light-mode header,
.light-mode nav,
.light-mode aside,
.light-mode #app-header,
.light-mode #sidebar,
.light-mode #admin-sidebar {
    background-color: #ffffff !important;
    border-color: #e2e8f0 !important;
}

/* ── Navigation Tabs & Sidebars ── */
.light-mode .border-b.border-slate-800,
.light-mode .border-r.border-slate-800 {
    border-color: #e2e8f0 !important;
}

.light-mode #admin-nav a,
.light-mode #admin-nav button {
    color: #475569 !important;
}
.light-mode #admin-nav a:hover,
.light-mode #admin-nav button:hover {
    background-color: #f1f5f9 !important;
    color: #1b468a !important;
}
.light-mode #admin-nav a:hover i,
.light-mode #admin-nav button:hover i {
    color: #1b468a !important;
}

.light-mode #admin-nav p {
    color: #94a3b8 !important;
}

/* ── Gateway & Login Screens in Day Mode (FinT Staff Console & Student Portal) ── */
.light-mode #view-gateway,
.light-mode #otp-verification-gate,
.light-mode body:has(#gate-login),
.light-mode body:has(#view-gateway) {
    background: radial-gradient(ellipse at 50% 20%, #f4f8ff 0%, #e6effc 50%, #d8e5f8 100%) !important;
    background-color: #e8f0fc !important;
}

/* Hide background emerald / teal glow blur spheres in Light Mode */
.light-mode #view-gateway .bg-emerald-500\/5,
.light-mode #otp-verification-gate .bg-teal-500\/5 {
    display: none !important;
}

/* ── Elevated Card Surface in Day Mode ── */
.light-mode #view-gateway .bg-slate-900\/80,
.light-mode #otp-verification-gate .bg-slate-900\/80,
.light-mode #gate-login,
.light-mode #gate-otp,
.light-mode #gate-email-verify,
.light-mode #gate-mfa {
    background-color: #ffffff !important;
    background: #ffffff !important;
    border: 1px solid rgba(27, 70, 138, 0.08) !important;
    border-radius: 1.5rem !important;
    box-shadow: 0 20px 50px -10px rgba(27, 70, 138, 0.12), 0 1px 3px rgba(0, 0, 0, 0.03), 0 0 0 1px rgba(27, 70, 138, 0.05) !important;
}

/* ── Harmonized Toggle Switch Control (Zero Eye Strain) ── */
.btn-student-theme-toggle,
#btn-theme-toggle {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    cursor: pointer !important;
    user-select: none !important;
}

/* Day Mode Floating Switch */
.light-mode .btn-student-theme-toggle,
.light-mode #btn-theme-toggle {
    background: rgba(255, 255, 255, 0.88) !important;
    background-color: rgba(255, 255, 255, 0.88) !important;
    backdrop-filter: blur(14px) !important;
    -webkit-backdrop-filter: blur(14px) !important;
    border: 1px solid rgba(27, 70, 138, 0.14) !important;
    color: #1b468a !important;
    font-weight: 700 !important;
    box-shadow: 0 4px 14px -2px rgba(27, 70, 138, 0.08), 0 1px 2px rgba(0, 0, 0, 0.02) !important;
}

.light-mode .btn-student-theme-toggle:hover,
.light-mode #btn-theme-toggle:hover {
    background: #ffffff !important;
    background-color: #ffffff !important;
    color: #0f2b57 !important;
    border-color: rgba(27, 70, 138, 0.25) !important;
    box-shadow: 0 8px 22px -2px rgba(27, 70, 138, 0.16) !important;
    transform: translateY(-1px);
}

.light-mode .btn-student-theme-toggle .theme-toggle-icon,
.light-mode .btn-student-theme-toggle i {
    color: #1b468a !important;
}

/* Night Mode Floating Switch */
.dark-mode .btn-student-theme-toggle,
:not(.light-mode) .btn-student-theme-toggle {
    background: rgba(15, 23, 42, 0.82) !important;
    backdrop-filter: blur(14px) !important;
    -webkit-backdrop-filter: blur(14px) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    color: #e2e8f0 !important;
    box-shadow: 0 4px 14px -2px rgba(0, 0, 0, 0.35) !important;
}

.dark-mode .btn-student-theme-toggle:hover,
:not(.light-mode) .btn-student-theme-toggle:hover {
    background: rgba(30, 41, 59, 0.95) !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
    color: #ffffff !important;
    box-shadow: 0 8px 22px -2px rgba(0, 0, 0, 0.45) !important;
    transform: translateY(-1px);
}

/* ── Auth Tabs Harmonization (Sign In / Register) ── */
.light-mode #auth-tabs {
    background-color: #f1f5f9 !important;
    border: 1px solid #e2e8f0 !important;
}

.light-mode .auth-tab-active,
.light-mode #tab-login.bg-blue-600,
.light-mode #tab-register.bg-blue-600 {
    background-color: #1b468a !important;
    color: #ffffff !important;
    font-weight: 700 !important;
    box-shadow: 0 2px 8px rgba(27, 70, 138, 0.2) !important;
}

.light-mode .auth-tab-inactive,
.light-mode #auth-tabs button:not(.auth-tab-active):not(.bg-blue-600) {
    color: #64748b !important;
    background-color: transparent !important;
}

.light-mode .auth-tab-inactive:hover,
.light-mode #auth-tabs button:not(.auth-tab-active):not(.bg-blue-600):hover {
    color: #1b468a !important;
    background-color: rgba(27, 70, 138, 0.05) !important;
}

/* ── Login Gate Typography & Accent Text in Day Mode ── */
.light-mode #view-gateway h1,
.light-mode #otp-verification-gate h1,
.light-mode #gate-login h1,
.light-mode #view-gateway h2,
.light-mode #gate-login h2 {
    color: #1b468a !important;
    font-weight: 800 !important;
    letter-spacing: -0.025em !important;
}

.light-mode #view-gateway p,
.light-mode #otp-verification-gate p,
.light-mode #gate-login p {
    color: #5b7aa8 !important;
}

.light-mode #view-gateway label,
.light-mode #otp-verification-gate label,
.light-mode #gate-login label {
    color: #1b468a !important;
    font-weight: 700 !important;
    letter-spacing: 0.04em !important;
}

.light-mode #btn-forgot-token,
.light-mode #forgot-pass-btn {
    color: #1b468a !important;
    font-weight: 700 !important;
}

.light-mode #btn-forgot-token:hover,
.light-mode #forgot-pass-btn:hover {
    color: #0f2b57 !important;
    text-decoration: underline !important;
}

.light-mode #btn-back-to-login,
.light-mode #btn-return-login {
    color: #1b468a !important;
    font-weight: 700 !important;
}

.light-mode #btn-toggle-eye-login,
.light-mode #btn-toggle-eye-update,
.light-mode #btn-toggle-eye {
    color: #8da4cb !important;
}

.light-mode #btn-toggle-eye-login:hover,
.light-mode #btn-toggle-eye-update:hover,
.light-mode #btn-toggle-eye:hover {
    color: #1b468a !important;
}

.light-mode #view-gateway input,
.light-mode #otp-verification-gate input,
.light-mode #gate-login input {
    background-color: #ffffff !important;
    border-color: #cbd5e1 !important;
    color: #0f172a !important;
}

.light-mode #view-gateway input:focus,
.light-mode #otp-verification-gate input:focus,
.light-mode #gate-login input:focus {
    border-color: #1b468a !important;
    box-shadow: 0 0 0 3px rgba(27, 70, 138, 0.15) !important;
}

/* ── Primary Action & Submit Buttons in Day Mode (#1b468a with White Text) ── */
.light-mode button[type="submit"],
.light-mode .btn-primary,
.light-mode button.bg-emerald-600:not(.btn-keep-emerald),
.light-mode button.bg-blue-600:not(.btn-keep-blue),
.light-mode button.bg-indigo-600,
.light-mode a.bg-emerald-600,
.light-mode a.bg-blue-600,
.light-mode #btn-login,
.light-mode #auth-submit-btn,
.light-mode #btn-update-pass,
.light-mode #btn-recover,
.light-mode #btn-submit-ledger,
.light-mode #btn-add-fee-item,
.light-mode #btn-rcpt-query,
.light-mode #btn-add-ledger-row,
.light-mode #btn-check-verify,
.light-mode #btn-post-notice,
.light-mode #btn-save-class,
.light-mode #btn-save-subject,
.light-mode #btn-save-batch,
.light-mode #btn-save-program,
.light-mode #btn-save-lead,
.light-mode #btn-create-lead,
.light-mode #btn-save-attendance,
.light-mode #btn-save-lesson,
.light-mode #btn-save-question,
.light-mode #btn-save-profile,
.light-mode #la-open,
.light-mode button.bg-lime-600,
.light-mode button.bg-amber-600,
.light-mode button.bg-rose-600,
.light-mode .dash-join,
.light-mode a[onclick*="Financials"],
.light-mode button[onclick*="Financials"] {
    background-color: #1b468a !important;
    color: #ffffff !important;
    font-weight: 700 !important;
    box-shadow: 0 4px 14px -1px rgba(27, 70, 138, 0.32) !important;
    border: none !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.light-mode button[type="submit"]:hover,
.light-mode .btn-primary:hover,
.light-mode button.bg-emerald-600:not(.btn-keep-emerald):hover,
.light-mode button.bg-blue-600:not(.btn-keep-blue):hover,
.light-mode button.bg-indigo-600:hover,
.light-mode button.bg-lime-600:hover,
.light-mode button.bg-amber-600:hover,
.light-mode button.bg-rose-600:hover,
.light-mode a.bg-emerald-600:hover,
.light-mode a.bg-blue-600:hover,
.light-mode #btn-login:hover,
.light-mode #auth-submit-btn:hover,
.light-mode #btn-update-pass:hover,
.light-mode #btn-recover:hover,
.light-mode #btn-submit-ledger:hover,
.light-mode #btn-add-fee-item:hover,
.light-mode #btn-rcpt-query:hover,
.light-mode #btn-add-ledger-row:hover,
.light-mode #btn-check-verify:hover,
.light-mode #btn-post-notice:hover,
.light-mode #la-open:hover,
.light-mode .dash-join:hover,
.light-mode a[onclick*="Financials"]:hover,
.light-mode button[onclick*="Financials"]:hover {
    background-color: #15376d !important;
    color: #ffffff !important;
    box-shadow: 0 6px 18px -1px rgba(27, 70, 138, 0.42) !important;
    transform: translateY(-1px);
}

.light-mode button[type="submit"]:active,
.light-mode .btn-primary:active,
.light-mode #btn-login:active,
.light-mode #auth-submit-btn:active,
.light-mode #btn-update-pass:active,
.light-mode #btn-recover:active,
.light-mode #btn-submit-ledger:active,
.light-mode #la-open:active,
.light-mode .dash-join:active {
    background-color: #0f2b57 !important;
    transform: translateY(0);
}

/* ── Universal Module Tabs & Sub-Tabs in Day Mode ── */
.light-mode button[id^="btn-fin-"].bg-emerald-600,
.light-mode button[id^="btn-ledger-"].bg-emerald-600,
.light-mode button[id^="btn-tab-"].bg-emerald-600,
.light-mode button[id^="tab-"].bg-blue-600,
.light-mode button[id^="tab-"].bg-emerald-600,
.light-mode button[id^="tab-"].bg-purple-600,
.light-mode button[id^="tab-"].bg-rose-600,
.light-mode button[id^="tab-"].subtab-active,
.light-mode button[id^="tab-"].tab-active,
.light-mode button.subtab-active,
.light-mode button.tab-active,
.light-mode .subtab-active,
.light-mode .tab-active {
    background-color: #1b468a !important;
    color: #ffffff !important;
    font-weight: 700 !important;
    box-shadow: 0 2px 8px rgba(27, 70, 138, 0.22) !important;
}

.light-mode button[id^="btn-fin-"]:not(.bg-emerald-600),
.light-mode button[id^="btn-ledger-"]:not(.bg-emerald-600),
.light-mode button[id^="btn-tab-"]:not(.bg-emerald-600),
.light-mode button[id^="tab-"]:not(.bg-blue-600):not(.bg-emerald-600):not(.bg-purple-600):not(.bg-rose-600):not(.subtab-active):not(.tab-active) {
    color: #475569 !important;
    background-color: transparent !important;
    font-weight: 600 !important;
    box-shadow: none !important;
}

.light-mode button[id^="btn-fin-"]:not(.bg-emerald-600):hover,
.light-mode button[id^="btn-ledger-"]:not(.bg-emerald-600):hover,
.light-mode button[id^="btn-tab-"]:not(.bg-emerald-600):hover,
.light-mode button[id^="tab-"]:not(.bg-blue-600):not(.bg-emerald-600):not(.bg-purple-600):not(.bg-rose-600):not(.subtab-active):not(.tab-active):hover {
    color: #1b468a !important;
    background-color: #f1f5f9 !important;
}

/* ── Cards, Modals, Workspace & Shadows ── */
.light-mode #quiz-modal,
.light-mode #quiz-item-review,
.light-mode #review-modal,
.light-mode #idcard-crop-modal,
.light-mode #asg-submit-modal,
.light-mode #lesson-video-modal,
.light-mode #proctor-warning-modal,
.light-mode #sync-student-modal,
.light-mode .modal-content,
.light-mode .fixed.inset-0 > div,
.light-mode [class*="fixed"][class*="inset-0"] > div,
.light-mode div[id*="modal"] > div,
.light-mode div[id$="-modal"] > div.bg-slate-900,
.light-mode div[id$="-modal"] .bg-slate-900,
.light-mode .bg-slate-900.border.border-slate-800 {
    background-color: #ffffff !important;
    border-color: #e2e8f0 !important;
    box-shadow: 0 20px 45px -10px rgba(15, 35, 80, 0.18) !important;
    border-radius: 1.25rem !important;
}

/* Modal Headers & Footers across all Modals & Dialogs */
.light-mode .fixed.inset-0 header,
.light-mode .fixed.inset-0 footer,
.light-mode div[id*="modal"] header,
.light-mode div[id*="modal"] footer,
.light-mode .modal-content header,
.light-mode .modal-content footer,
.light-mode .modal-footer {
    background-color: #f8fafc !important;
    border-color: #e2e8f0 !important;
    color: #0f172a !important;
}

.light-mode div[id*="modal"] h1,
.light-mode div[id*="modal"] h2,
.light-mode div[id*="modal"] h3,
.light-mode .modal-content h1,
.light-mode .modal-content h2,
.light-mode .modal-content h3 {
    color: #1b468a !important;
    font-weight: 800 !important;
}

/* Modal Empty States, Dropzones & Dashed Containers */
.light-mode .border-dashed,
.light-mode [class*="border-dashed"] {
    border-color: #cbd5e1 !important;
}
.light-mode div.border-dashed,
.light-mode [id*="dropzone"].border-dashed,
.light-mode div[class*="border-dashed"]:not(button):not(span),
.light-mode .sync-empty-student {
    background-color: #f8fafc !important;
    color: #475569 !important;
}
.light-mode div.border-dashed i,
.light-mode [id*="dropzone"] i,
.light-mode .sync-empty-student i {
    color: #1b468a !important;
}
.light-mode .sync-empty-student span.font-bold {
    color: #1e293b !important;
}

/* Student / COA Search Dropdown Lists in Day Mode */
.light-mode #sync-student-results-list,
.light-mode #coa-search-dropdown,
.light-mode .student-search-results,
.light-mode .search-results-list {
    background-color: #ffffff !important;
    border-color: #e2e8f0 !important;
}

.light-mode .btn-select-student-row {
    background-color: #ffffff !important;
    border-color: #f1f5f9 !important;
}
.light-mode .btn-select-student-row:hover {
    background-color: #f1f5f9 !important;
    border-color: #cbd5e1 !important;
}
.light-mode .btn-select-student-row .font-bold,
.light-mode .btn-select-student-row .text-white,
.light-mode .btn-select-student-row .student-name {
    color: #0f172a !important;
}
.light-mode .btn-select-student-row:hover .font-bold,
.light-mode .btn-select-student-row:hover .student-name {
    color: #1b468a !important;
}
.light-mode .btn-select-student-row .student-sid-badge,
.light-mode .btn-select-student-row span.bg-slate-800 {
    background-color: #eff6ff !important;
    color: #1d4ed8 !important;
    border: 1px solid #bfdbfe !important;
}

/* Secondary Cancel / Dismiss Modal Buttons */
.light-mode #btn-sync-modal-cancel,
.light-mode .btn-modal-cancel {
    background-color: #ffffff !important;
    border: 1px solid #cbd5e1 !important;
    color: #334155 !important;
}
.light-mode #btn-sync-modal-cancel:hover,
.light-mode .btn-modal-cancel:hover {
    background-color: #f1f5f9 !important;
    color: #0f172a !important;
}

/* Disabled Buttons & Controls in Light Mode - Clean Slate, Zero Dark Patch */
.light-mode button:disabled,
.light-mode button[disabled] {
    background-color: #f1f5f9 !important;
    border-color: #e2e8f0 !important;
    color: #94a3b8 !important;
    cursor: not-allowed !important;
    box-shadow: none !important;
}
.light-mode button:disabled *,
.light-mode button[disabled] * {
    color: #94a3b8 !important;
}

.light-mode .shadow-2xl,
.light-mode .shadow-xl,
.light-mode .shadow-lg,
.light-mode .shadow-md {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05) !important;
}

/* ── Form Controls & Inputs ── */
.light-mode input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="color"]),
.light-mode select,
.light-mode textarea {
    background-color: #ffffff !important;
    color: #0f172a !important;
    border-color: #cbd5e1 !important;
}

.light-mode input:disabled,
.light-mode select:disabled,
.light-mode textarea:disabled {
    background-color: #f1f5f9 !important;
    color: #94a3b8 !important;
    border-color: #e2e8f0 !important;
}

.light-mode input::placeholder,
.light-mode textarea::placeholder {
    color: #94a3b8 !important;
}

.light-mode input:focus,
.light-mode select:focus,
.light-mode textarea:focus {
    border-color: #1b468a !important;
    box-shadow: 0 0 0 3px rgba(27, 70, 138, 0.15) !important;
}

/* ── Button Overrides for Light Mode ── */
.light-mode button.bg-slate-950,
.light-mode a.bg-slate-950 {
    background-color: #ffffff !important;
    border-color: #cbd5e1 !important;
    color: #334155 !important;
}

.light-mode button.bg-slate-950:hover,
.light-mode a.bg-slate-950:hover {
    background-color: #f1f5f9 !important;
    color: #0f172a !important;
}

.light-mode button.bg-slate-850,
.light-mode button.bg-slate-800,
.light-mode a.bg-slate-800 {
    background-color: #f1f5f9 !important;
    color: #1e293b !important;
    border-color: #cbd5e1 !important;
}

.light-mode button.bg-slate-850:hover,
.light-mode button.bg-slate-800:hover,
.light-mode a.bg-slate-800:hover {
    background-color: #e2e8f0 !important;
    color: #0f172a !important;
}

.light-mode .pay-amt-btn {
    background-color: #f1f5f9 !important;
    color: #1e293b !important;
    border-color: #cbd5e1 !important;
}

.light-mode .pay-amt-btn:hover {
    background-color: #e2e8f0 !important;
    color: #0f172a !important;
}

.light-mode .pay-amt-btn[class*="bg-blue-600"],
.light-mode .pay-amt-btn.active {
    background-color: #dbeafe !important;
    color: #1d4ed8 !important;
    border-color: #3b82f6 !important;
}

/* ── Remove Dark Tailwind Slate Gradients in Day Mode ── */
.light-mode [class*="bg-gradient-to"][class*="from-slate-"],
.light-mode [class*="bg-gradient-to"][class*="to-slate-"],
.light-mode .from-slate-900,
.light-mode .from-slate-950,
.light-mode .to-slate-900,
.light-mode .to-slate-950 {
    background-image: none !important;
}

/* ── Color Status Cards & Badges in Light Mode ── */
.light-mode .bg-blue-950,
.light-mode .bg-blue-900,
.light-mode .bg-blue-950\/80,
.light-mode .bg-blue-950\/60,
.light-mode .bg-blue-950\/50,
.light-mode .bg-blue-950\/40,
.light-mode .bg-blue-950\/30,
.light-mode .bg-blue-950\/20,
.light-mode .bg-blue-900\/60,
.light-mode .bg-blue-900\/50,
.light-mode .bg-blue-900\/40,
.light-mode .bg-blue-900\/30,
.light-mode .bg-blue-900\/20 {
    background-color: #eff6ff !important; /* blue-50 */
    border-color: #bfdbfe !important; /* blue-200 */
    color: #1d4ed8 !important; /* blue-700 */
}

.light-mode .bg-sky-950,
.light-mode .bg-sky-900,
.light-mode .bg-sky-950\/80,
.light-mode .bg-sky-950\/60,
.light-mode .bg-sky-950\/50,
.light-mode .bg-sky-950\/40,
.light-mode .bg-sky-950\/30,
.light-mode .bg-sky-950\/20,
.light-mode .bg-sky-900\/60,
.light-mode .bg-sky-900\/50,
.light-mode .bg-sky-900\/40,
.light-mode .bg-sky-900\/30,
.light-mode .bg-sky-900\/20 {
    background-color: #f0f9ff !important; /* sky-50 */
    border-color: #bae6fd !important; /* sky-200 */
    color: #0369a1 !important; /* sky-700 */
}

.light-mode .bg-indigo-950,
.light-mode .bg-indigo-900,
.light-mode .bg-indigo-950\/80,
.light-mode .bg-indigo-950\/60,
.light-mode .bg-indigo-950\/50,
.light-mode .bg-indigo-950\/40,
.light-mode .bg-indigo-950\/30,
.light-mode .bg-indigo-950\/20,
.light-mode .bg-indigo-900\/60,
.light-mode .bg-indigo-900\/50,
.light-mode .bg-indigo-900\/40,
.light-mode .bg-indigo-900\/30,
.light-mode .bg-indigo-900\/20 {
    background-color: #eef2ff !important; /* indigo-50 */
    border-color: #c7d2fe !important; /* indigo-200 */
    color: #4338ca !important; /* indigo-700 */
}

.light-mode .bg-emerald-950,
.light-mode .bg-emerald-900,
.light-mode .bg-emerald-950\/80,
.light-mode .bg-emerald-950\/60,
.light-mode .bg-emerald-950\/50,
.light-mode .bg-emerald-950\/40,
.light-mode .bg-emerald-950\/30,
.light-mode .bg-emerald-950\/20,
.light-mode .bg-emerald-900\/60,
.light-mode .bg-emerald-900\/50,
.light-mode .bg-emerald-900\/40,
.light-mode .bg-emerald-900\/30,
.light-mode .bg-emerald-900\/20 {
    background-color: #ecfdf5 !important; /* emerald-50 */
    border-color: #a7f3d0 !important; /* emerald-200 */
    color: #047857 !important; /* emerald-700 */
}

.light-mode .bg-teal-950,
.light-mode .bg-teal-900,
.light-mode .bg-teal-950\/80,
.light-mode .bg-teal-950\/60,
.light-mode .bg-teal-950\/50,
.light-mode .bg-teal-950\/40,
.light-mode .bg-teal-950\/30,
.light-mode .bg-teal-950\/20,
.light-mode .bg-cyan-950,
.light-mode .bg-cyan-900,
.light-mode .bg-cyan-950\/80,
.light-mode .bg-cyan-950\/60,
.light-mode .bg-cyan-950\/50,
.light-mode .bg-cyan-950\/40,
.light-mode .bg-cyan-950\/30,
.light-mode .bg-cyan-950\/20 {
    background-color: #f0fdfa !important; /* teal/cyan-50 */
    border-color: #99f6e4 !important; /* teal-200 */
    color: #0f766e !important; /* teal-700 */
}

.light-mode .bg-amber-950,
.light-mode .bg-amber-900,
.light-mode .bg-amber-950\/80,
.light-mode .bg-amber-950\/60,
.light-mode .bg-amber-950\/50,
.light-mode .bg-amber-950\/40,
.light-mode .bg-amber-950\/30,
.light-mode .bg-amber-950\/20,
.light-mode .bg-amber-900\/60,
.light-mode .bg-amber-900\/50,
.light-mode .bg-amber-900\/40,
.light-mode .bg-amber-900\/30,
.light-mode .bg-amber-900\/20 {
    background-color: #fffbeb !important; /* amber-50 */
    border-color: #fde68a !important; /* amber-200 */
    color: #b45309 !important; /* amber-700 */
}

.light-mode .bg-rose-950,
.light-mode .bg-rose-900,
.light-mode .bg-rose-950\/80,
.light-mode .bg-rose-950\/60,
.light-mode .bg-rose-950\/50,
.light-mode .bg-rose-950\/40,
.light-mode .bg-rose-950\/30,
.light-mode .bg-rose-950\/20,
.light-mode .bg-rose-900\/60,
.light-mode .bg-rose-900\/50,
.light-mode .bg-rose-900\/40,
.light-mode .bg-rose-900\/30,
.light-mode .bg-rose-900\/20 {
    background-color: #fff1f2 !important; /* rose-50 */
    border-color: #fecdd3 !important; /* rose-200 */
    color: #be123c !important; /* rose-700 */
}

.light-mode .bg-purple-950,
.light-mode .bg-purple-900,
.light-mode .bg-purple-950\/80,
.light-mode .bg-purple-950\/60,
.light-mode .bg-purple-950\/50,
.light-mode .bg-purple-950\/40,
.light-mode .bg-purple-950\/30,
.light-mode .bg-purple-950\/20,
.light-mode .bg-purple-900\/60,
.light-mode .bg-purple-900\/50,
.light-mode .bg-purple-900\/40,
.light-mode .bg-purple-900\/30,
.light-mode .bg-purple-900\/20 {
    background-color: #faf5ff !important; /* purple-50 */
    border-color: #e9d5ff !important; /* purple-200 */
    color: #7e22ce !important; /* purple-700 */
}

/* Dark pill borders mapped to soft tints in Day Mode */
.light-mode .border-blue-900,
.light-mode .border-blue-800,
.light-mode .border-blue-900\/50,
.light-mode .border-blue-800\/40 {
    border-color: #bfdbfe !important;
}

.light-mode .border-emerald-900,
.light-mode .border-emerald-800,
.light-mode .border-emerald-900\/50,
.light-mode .border-emerald-800\/40 {
    border-color: #a7f3d0 !important;
}

.light-mode .border-amber-900,
.light-mode .border-amber-800,
.light-mode .border-amber-900\/50,
.light-mode .border-amber-800\/40 {
    border-color: #fde68a !important;
}

.light-mode .border-rose-900,
.light-mode .border-rose-800,
.light-mode .border-rose-900\/50,
.light-mode .border-rose-800\/40 {
    border-color: #fecdd3 !important;
}

.light-mode .border-purple-900,
.light-mode .border-purple-800,
.light-mode .border-purple-900\/50,
.light-mode .border-purple-800\/40 {
    border-color: #e9d5ff !important;
}

.light-mode .border-indigo-900,
.light-mode .border-indigo-800,
.light-mode .border-indigo-900\/50,
.light-mode .border-indigo-800\/40 {
    border-color: #c7d2fe !important;
}

.light-mode .border-sky-900,
.light-mode .border-sky-800,
.light-mode .border-sky-900\/50,
.light-mode .border-sky-800\/40 {
    border-color: #bae6fd !important;
}

/* Light mode text accents for tables, metrics & staff dashboards */
.light-mode .text-sky-300,
.light-mode .text-sky-400,
.light-mode .text-sky-500,
.light-mode td .text-sky-400,
.light-mode th .text-sky-400,
.light-mode span .text-sky-400,
.light-mode p .text-sky-400,
.light-mode b .text-sky-400,
.light-mode i.text-sky-400 {
    color: #1b468a !important;
}

.light-mode .text-blue-300,
.light-mode .text-blue-400,
.light-mode .text-blue-500,
.light-mode td .text-blue-400,
.light-mode th .text-blue-400,
.light-mode span .text-blue-400,
.light-mode p .text-blue-400,
.light-mode b .text-blue-400,
.light-mode i.text-blue-400 {
    color: #1b468a !important;
}

.light-mode .text-lime-300,
.light-mode .text-lime-400,
.light-mode .text-lime-500,
.light-mode td .text-lime-400,
.light-mode th .text-lime-400,
.light-mode span .text-lime-400,
.light-mode p .text-lime-400,
.light-mode b .text-lime-400,
.light-mode i.text-lime-400 {
    color: #15803d !important;
}

.light-mode .text-emerald-300,
.light-mode .text-emerald-400,
.light-mode .text-emerald-500,
.light-mode td .text-emerald-400,
.light-mode th .text-emerald-400,
.light-mode span .text-emerald-400,
.light-mode p .text-emerald-400,
.light-mode b .text-emerald-400,
.light-mode i.text-emerald-400,
.light-mode h3.text-emerald-400 {
    color: #059669 !important;
}

.light-mode .text-teal-300,
.light-mode .text-teal-400,
.light-mode .text-teal-500,
.light-mode td .text-teal-400,
.light-mode th .text-teal-400,
.light-mode span .text-teal-400,
.light-mode p .text-teal-400,
.light-mode b .text-teal-400,
.light-mode i.text-teal-400 {
    color: #0f766e !important;
}

.light-mode .text-cyan-300,
.light-mode .text-cyan-400,
.light-mode .text-cyan-500,
.light-mode td .text-cyan-400,
.light-mode th .text-cyan-400,
.light-mode span .text-cyan-400,
.light-mode p .text-cyan-400,
.light-mode b .text-cyan-400,
.light-mode i.text-cyan-400 {
    color: #0284c7 !important;
}

.light-mode .text-purple-300,
.light-mode .text-purple-400,
.light-mode .text-purple-500,
.light-mode .text-violet-300,
.light-mode .text-violet-400,
.light-mode td .text-purple-400,
.light-mode th .text-purple-400,
.light-mode span .text-purple-400,
.light-mode p .text-purple-400,
.light-mode b .text-purple-400,
.light-mode i.text-purple-400,
.light-mode h3.text-purple-400 {
    color: #7e22ce !important;
}

/* High contrast golden-amber for yellow/gold elements */
.light-mode .text-yellow-200,
.light-mode .text-yellow-300,
.light-mode .text-yellow-400,
.light-mode .text-yellow-500,
.light-mode .text-yellow-600,
.light-mode .text-amber-200,
.light-mode .text-amber-300,
.light-mode .text-amber-400,
.light-mode .text-amber-500,
.light-mode td .text-amber-400,
.light-mode th .text-amber-400,
.light-mode td .text-yellow-400,
.light-mode th .text-yellow-400,
.light-mode span .text-amber-400,
.light-mode span .text-yellow-400,
.light-mode p .text-amber-400,
.light-mode p .text-yellow-400,
.light-mode b .text-amber-400,
.light-mode b .text-yellow-400,
.light-mode i.text-amber-400,
.light-mode i.text-yellow-400,
.light-mode h3.text-amber-400 {
    color: #b45309 !important;
}

.light-mode .text-rose-300,
.light-mode .text-rose-400,
.light-mode .text-rose-500,
.light-mode td .text-rose-400,
.light-mode th .text-rose-400,
.light-mode span .text-rose-400,
.light-mode p .text-rose-400,
.light-mode b .text-rose-400,
.light-mode i.text-rose-400 {
    color: #be123c !important;
}

.light-mode .text-pink-300,
.light-mode .text-pink-400,
.light-mode .text-pink-500,
.light-mode td .text-pink-400,
.light-mode th .text-pink-400,
.light-mode span .text-pink-400,
.light-mode p .text-pink-400,
.light-mode b .text-pink-400,
.light-mode i.text-pink-400 {
    color: #be185d !important;
}

.light-mode .text-orange-300,
.light-mode .text-orange-400,
.light-mode .text-orange-500,
.light-mode td .text-orange-400,
.light-mode th .text-orange-400,
.light-mode span .text-orange-400,
.light-mode p .text-orange-400,
.light-mode b .text-orange-400,
.light-mode i.text-orange-400 {
    color: #c2410c !important;
}

/* ── Staff Dashboards & Workspaces in Day Mode ── */
.light-mode .bg-slate-950\/60,
.light-mode .bg-slate-950\/50 {
    background-color: #f8fafc !important;
    border-color: #e2e8f0 !important;
    color: #0f172a !important;
}

.light-mode .lh-go {
    background-color: #ffffff !important;
    border-color: #e2e8f0 !important;
    box-shadow: 0 4px 14px -2px rgba(27, 70, 138, 0.06), 0 1px 3px rgba(0, 0, 0, 0.03) !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.light-mode .lh-go:hover {
    background-color: #f8fafc !important;
    border-color: #1b468a !important;
    box-shadow: 0 8px 20px -2px rgba(27, 70, 138, 0.12) !important;
    transform: translateY(-2px);
}

.light-mode .lh-go .text-white {
    color: #1b468a !important;
    font-weight: 700 !important;
}

.light-mode .lh-assign,
.light-mode .dash-tt-open {
    color: #1b468a !important;
    font-weight: 700 !important;
}

.light-mode .lh-assign:hover,
.light-mode .dash-tt-open:hover {
    color: #15376d !important;
    text-decoration: underline !important;
}

.light-mode #btn-reset-as-filters {
    background-color: #f1f5f9 !important;
    color: #334155 !important;
    border: 1px solid #cbd5e1 !important;
}

.light-mode #btn-reset-as-filters:hover {
    background-color: #e2e8f0 !important;
    color: #0f172a !important;
}

/* ── Notification Dropdown & Badges ── */
.light-mode #notif-panel,
.light-mode #notif-panel-erp,
.light-mode .notif-dropdown,
.light-mode .fint-notif-menu {
    background-color: #ffffff !important;
    border-color: #e2e8f0 !important;
    color: #0f172a !important;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1) !important;
}

/* ── Test Screen & Exhibit Panes ── */
.light-mode #quiz-case-pane {
    background-color: #ffffff !important;
    border-color: #e2e8f0 !important;
}

.light-mode #btn-quiz-next {
    background-color: #004b87 !important;
    color: #ffffff !important;
}
.light-mode #btn-quiz-next:hover {
    background-color: #003366 !important;
}

/* ── Scrollbars in Light Mode ── */
.light-mode ::-webkit-scrollbar-thumb {
    background: #cbd5e1 !important;
}
.light-mode ::-webkit-scrollbar-track {
    background: #f8fafc !important;
}

/* ── Review Modal & Sidebar ── */
.light-mode .review-tab-btn.bg-slate-800\/50 {
    background-color: #eff6ff !important;
    color: #1d4ed8 !important;
}

.light-mode .review-tab-btn:hover {
    background-color: #f1f5f9 !important;
}

/* ── Tables & Data Grids in ERP ── */
.light-mode table,
.light-mode .table-responsive table {
    background-color: #ffffff !important;
}

/* Ensure Dark Mode sort headers have a smooth dark hover */
.th-sort-rcpt {
    transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1) !important;
    cursor: pointer !important;
}

:not(.light-mode) .th-sort-rcpt:hover {
    background-color: rgba(30, 41, 59, 0.7) !important;
}

:not(.light-mode) .th-sort-rcpt.th-sort-active {
    background-color: rgba(30, 41, 59, 0.9) !important;
}

/* Day Mode Table Headers (Crisp, Unified & Harmonious) */
.light-mode table thead,
.light-mode table thead tr:first-child,
.light-mode table thead th {
    background-color: #f8fafc !important; /* clean slate-50 base */
    border-color: #e2e8f0 !important;
    color: #475569 !important;
    font-weight: 700 !important;
}

/* Day Mode Table Header Hover State - Smooth Soft Tint, Zero Pitch Black */
.light-mode table thead th:hover,
.light-mode table thead th:active,
.light-mode table thead th:focus,
.light-mode table thead .th-sort-rcpt:hover,
.light-mode table thead .th-sort-rcpt:active,
.light-mode table thead .th-sort-rcpt:focus,
.light-mode table thead th[class*="hover:bg-slate-"]:hover {
    background-color: #f1f5f9 !important; /* soft slate-100 hover */
    color: #1b468a !important; /* FinT Navy hover */
}

.light-mode table thead th:hover .sort-icon i,
.light-mode table thead .th-sort-rcpt:hover .sort-icon i {
    color: #1b468a !important;
}

/* Day Mode Active Sorted Column Header - Premium FinT Blue Brand Tint */
.light-mode table thead th.th-sort-active,
.light-mode table thead th.text-sky-300,
.light-mode table thead .th-sort-rcpt.th-sort-active {
    background-color: #edf4fe !important; /* subtle blue-50 accent */
    color: #1b468a !important;
    font-weight: 800 !important;
}

.light-mode table thead th.th-sort-active *,
.light-mode table thead th.text-sky-300 * {
    color: #1b468a !important;
}

.light-mode table thead th.th-sort-active .sort-icon i,
.light-mode table thead th.text-sky-300 .sort-icon i {
    color: #1b468a !important;
}

/* Header Filter Row (e.g., in Online Receipts, Ledger, etc.) */
.light-mode table thead tr.bg-slate-900\/95,
.light-mode table thead tr[class*="bg-slate-900"],
.light-mode table thead tr[class*="bg-slate-950"],
.light-mode table thead .table-filter-row,
.light-mode .table-filter-row {
    background-color: #f1f5f9 !important; /* soft contrast slate-100 strip */
    border-color: #e2e8f0 !important;
    color: #475569 !important;
}

.light-mode table thead tr.bg-slate-900\/95 th,
.light-mode table thead tr[class*="bg-slate-900"] th,
.light-mode table thead tr[class*="bg-slate-950"] th,
.light-mode table thead .table-filter-row th,
.light-mode .table-filter-row th {
    background-color: #f1f5f9 !important;
    border-color: #e2e8f0 !important;
    color: #475569 !important;
}

/* Table Filter Row Inputs, Selects & Action Buttons */
.light-mode table thead input,
.light-mode table thead select,
.light-mode .table-filter-row input,
.light-mode .table-filter-row select {
    background-color: #ffffff !important;
    border: 1px solid #cbd5e1 !important;
    color: #0f172a !important;
    border-radius: 0.5rem !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04) !important;
}

.light-mode table thead input::placeholder,
.light-mode .table-filter-row input::placeholder {
    color: #94a3b8 !important;
}

.light-mode table thead input:focus,
.light-mode table thead select:focus,
.light-mode .table-filter-row input:focus,
.light-mode .table-filter-row select:focus {
    border-color: #1b468a !important;
    box-shadow: 0 0 0 2px rgba(27, 70, 138, 0.15) !important;
    outline: none !important;
}

.light-mode table thead button,
.light-mode table thead button.bg-slate-800,
.light-mode .table-filter-row button,
.light-mode .table-filter-row button.bg-slate-800 {
    background-color: #ffffff !important;
    border: 1px solid #cbd5e1 !important;
    color: #475569 !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04) !important;
}

.light-mode table thead button:hover,
.light-mode table thead button.bg-slate-800:hover,
.light-mode .table-filter-row button:hover,
.light-mode .table-filter-row button.bg-slate-800:hover {
    background-color: #e2e8f0 !important;
    color: #0f172a !important;
}

/* Table Body Rows & Cells */
.light-mode table tbody {
    background-color: #ffffff !important;
    border-color: #e2e8f0 !important;
    color: #334155 !important;
}

.light-mode table tbody tr {
    background-color: #ffffff !important;
    border-color: #f1f5f9 !important;
}

.light-mode table tbody tr:hover {
    background-color: #f8fafc !important;
}

.light-mode table tbody td {
    border-color: #f1f5f9 !important;
    color: #334155 !important;
}

.light-mode table tbody td .text-white {
    color: #0f172a !important;
}

/* ==========================================================================
   Universal Mobile & Responsive Design System
   Guarantees fluid responsiveness across Mobile, Tablet, and Desktop browsers.
   ========================================================================== */

/* ── Fluid Container & Layout Protections ── */
html, body {
    max-width: 100vw;
    overflow-x: hidden;
}

/* ── Responsive Horizontal Scrolling for Tabs & Subtabs ── */
@media (max-width: 768px) {
    #auth-tabs,
    .tab-container,
    .subtab-container,
    nav[id*="tab"],
    div[id*="-tabs"],
    div[id^="tab-container"],
    .overflow-tabs {
        display: flex !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        padding-bottom: 2px !important;
        scrollbar-width: none !important;
    }

    #auth-tabs::-webkit-scrollbar,
    .tab-container::-webkit-scrollbar,
    .subtab-container::-webkit-scrollbar {
        display: none !important;
    }

    #auth-tabs button,
    .tab-container button,
    .subtab-container button,
    button[id^="btn-tab-"],
    button[id^="tab-"],
    button[id^="btn-fin-"],
    button[id^="btn-ledger-"] {
        flex-shrink: 0 !important;
        white-space: nowrap !important;
    }
}

/* ── Responsive Modals & Floating Dialogs ── */
@media (max-width: 640px) {
    div[id$="-modal"] > div,
    div[id$="-modal"] .bg-slate-900,
    .modal-content {
        max-width: calc(100vw - 1.25rem) !important;
        max-height: calc(100vh - 2rem) !important;
        overflow-y: auto !important;
        margin: auto !important;
        padding: 1rem !important;
        border-radius: 1rem !important;
    }

    #gate-login,
    #view-gateway,
    #otp-verification-gate {
        padding: 1.25rem !important;
        border-radius: 1.25rem !important;
    }
}

/* ── Responsive Data Tables ── */
.table-responsive,
.overflow-x-auto {
    width: 100% !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
}

@media (max-width: 768px) {
    table {
        min-width: 100% !important;
    }
    
    table th, table td {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
        font-size: 0.75rem !important;
    }
}

/* ── Touch Target & Button Ergonomics on Mobile ── */
@media (max-width: 768px) {
    button, 
    input[type="button"], 
    input[type="submit"], 
    .btn-student-theme-toggle {
        min-height: 38px;
        touch-action: manipulation;
    }

    input:not([type="checkbox"]):not([type="radio"]), 
    select, 
    textarea {
        font-size: 14px !important;
        min-height: 38px;
    }
}

/* ==========================================================================
   FinT TinyMCE Content & CBE Exam Exhibit / Scenario Styling
   ========================================================================== */

.tinymce-content {
    color: #e2e8f0;
    line-height: 1.7;
    font-size: 0.875rem; /* 14px */
}

/* Neutralize invisible black/dark text pasted from Word / web */
.tinymce-content [style*="color: rgb(0, 0, 0)"],
.tinymce-content [style*="color: #000"],
.tinymce-content [style*="color: #000000"],
.tinymce-content [style*="color: black"],
.tinymce-content [style*="color: #111"],
.tinymce-content [style*="color: #222"],
.tinymce-content [style*="color: #333"] {
    color: inherit !important;
}

/* Headings & Section Labels (e.g. "Additional information") */
.tinymce-content h1, 
.tinymce-content h2, 
.tinymce-content h3, 
.tinymce-content h4, 
.tinymce-content h5, 
.tinymce-content h6 {
    color: #60a5fa !important; /* blue-400 */
    font-weight: 700 !important;
    margin-top: 1.25rem !important;
    margin-bottom: 0.625rem !important;
    font-size: 0.95rem !important;
    letter-spacing: 0.025em !important;
    display: block !important;
}

.tinymce-content p > strong:only-child,
.tinymce-content strong:has(+ br) {
    color: #93c5fd !important; /* blue-300 */
    display: inline-block !important;
    margin-top: 1.25rem !important;
    margin-bottom: 0.5rem !important;
    font-size: 0.9rem !important;
    letter-spacing: 0.025em !important;
    font-weight: 700 !important;
}

/* Ordered & Unordered Lists (e.g. "1. Land and buildings... 2. Closing inventory...") */
.tinymce-content ol {
    list-style: decimal outside !important;
    margin: 0.75rem 0 1rem 1.5rem !important;
    padding-left: 0.5rem !important;
    display: block !important;
}

.tinymce-content ul {
    list-style: disc outside !important;
    margin: 0.75rem 0 1rem 1.5rem !important;
    padding-left: 0.5rem !important;
    display: block !important;
}

.tinymce-content li {
    margin-bottom: 0.625rem !important;
    line-height: 1.65 !important;
    color: #cbd5e1 !important; /* slate-300 */
    padding-left: 0.25rem !important;
}

/* Beautiful CBE Matrix & Financial Tables */
.tinymce-content table {
    width: 100% !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    margin: 1.25rem 0 !important;
    background: rgba(15, 23, 42, 0.7) !important;
    border: 1px solid #334155 !important;
    border-radius: 0.75rem !important;
    overflow: hidden !important;
    font-size: 0.8125rem !important;
}

.tinymce-content th {
    background: #1e293b !important;
    color: #93c5fd !important;
    font-weight: 700 !important;
    padding: 0.75rem 1rem !important;
    border-bottom: 1px solid #334155 !important;
    border-right: 1px solid #334155 !important;
    text-align: left !important;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace !important;
    font-size: 0.75rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.05em !important;
}

.tinymce-content th:last-child {
    border-right: none !important;
}

.tinymce-content td {
    padding: 0.625rem 1rem !important;
    border-bottom: 1px solid rgba(51, 65, 85, 0.6) !important;
    border-right: 1px solid rgba(51, 65, 85, 0.6) !important;
    color: #f1f5f9 !important;
    line-height: 1.5 !important;
}

.tinymce-content td:last-child {
    border-right: none !important;
}

.tinymce-content tr:last-child td {
    border-bottom: none !important;
}

.tinymce-content tr:nth-child(even) td {
    background: rgba(30, 41, 59, 0.35) !important;
}

.tinymce-content tr:hover td {
    background: rgba(51, 65, 85, 0.45) !important;
}

/* Light mode overrides for tinymce-content */
.light-mode .tinymce-content {
    color: #0f172a !important;
}
.light-mode .tinymce-content li {
    color: #334155 !important;
}
.light-mode .tinymce-content h1,
.light-mode .tinymce-content h2,
.light-mode .tinymce-content h3,
.light-mode .tinymce-content h4,
.light-mode .tinymce-content h5,
.light-mode .tinymce-content h6,
.light-mode .tinymce-content p > strong:only-child {
    color: #1d4ed8 !important; /* blue-700 */
}
.light-mode .tinymce-content table {
    background: #ffffff !important;
    border-color: #cbd5e1 !important;
}
.light-mode .tinymce-content th {
    background: #f1f5f9 !important;
    color: #1e40af !important;
    border-color: #cbd5e1 !important;
}
.light-mode .tinymce-content td {
    border-color: #e2e8f0 !important;
    color: #0f172a !important;
}
.light-mode .tinymce-content tr:nth-child(even) td {
    background: #f8fafc !important;
}


