/* ============================================================
   RXPlus HMS - Custom CSS Overrides
   File: assets/css/rxplus.css
   ============================================================ */

/* -- Global Root Theme Variables -- */
:root {
    --primary: #7b1fa2;
    --primary-hover: #6a1b9a;
    --primary-dark: #4a148c;
    --primary-light: #f3e8ff;
    --primary-rgb: 123, 31, 162;
    --secondary: #9c27b0;
    --secondary-rgb: 156, 39, 176;
    --bs-primary: #7b1fa2;
    --bs-primary-rgb: 123, 31, 162;
}

[data-theme-version="dark"] {
    --primary: #c084fc;
    --primary-hover: #d8b4fe;
    --primary-rgb: 192, 132, 252;
    --bs-primary: #c084fc;
    --bs-primary-rgb: 192, 132, 252;
}

/* -- Universal Active Tab State Guarantee (High-Contrast) -- */
.pharmacy-tab-link.active,
.nursing-tab-link.active,
.lab-tab-link.active,
.opd-tab-link.active {
    background: #7b1fa2 !important;
    background-color: #7b1fa2 !important;
    color: #ffffff !important;
    border-color: #7b1fa2 !important;
    box-shadow: 0 4px 15px rgba(123, 31, 162, 0.35) !important;
}
.pharmacy-tab-link.active *,
.pharmacy-tab-link.active i,
.pharmacy-tab-link.active span,
.nursing-tab-link.active *,
.nursing-tab-link.active i,
.nursing-tab-link.active span,
.lab-tab-link.active *,
.lab-tab-link.active i,
.lab-tab-link.active span,
.opd-tab-link.active *,
.opd-tab-link.active i,
.opd-tab-link.active span {
    color: #ffffff !important;
}

[data-theme-version="dark"] .pharmacy-tab-link.active,
[data-theme-version="dark"] .nursing-tab-link.active,
[data-theme-version="dark"] .lab-tab-link.active,
[data-theme-version="dark"] .opd-tab-link.active {
    background: linear-gradient(135deg, #9333ea 0%, #7c3aed 100%) !important;
    background-color: #9333ea !important;
    color: #ffffff !important;
    border-color: #a855f7 !important;
    box-shadow: 0 4px 18px rgba(147, 51, 234, 0.45) !important;
}
[data-theme-version="dark"] .pharmacy-tab-link.active *,
[data-theme-version="dark"] .pharmacy-tab-link.active i,
[data-theme-version="dark"] .pharmacy-tab-link.active span,
[data-theme-version="dark"] .nursing-tab-link.active *,
[data-theme-version="dark"] .nursing-tab-link.active i,
[data-theme-version="dark"] .nursing-tab-link.active span,
[data-theme-version="dark"] .lab-tab-link.active *,
[data-theme-version="dark"] .lab-tab-link.active i,
[data-theme-version="dark"] .lab-tab-link.active span,
[data-theme-version="dark"] .opd-tab-link.active *,
[data-theme-version="dark"] .opd-tab-link.active i,
[data-theme-version="dark"] .opd-tab-link.active span {
    color: #ffffff !important;
}

/* -- Payment Mode Buttons Guarantee -- */
.pay-mode-btn {
    border: 1.5px solid rgba(123, 31, 162, 0.3) !important;
    color: #7b1fa2 !important;
    background: #ffffff !important;
    border-radius: 8px !important;
    font-size: 0.78rem !important;
    font-weight: 600 !important;
    padding: 5px 12px !important;
    transition: all 0.2s ease !important;
}
.pay-mode-btn:hover {
    background: rgba(123, 31, 162, 0.08) !important;
    color: #6a1b9a !important;
    border-color: #7b1fa2 !important;
}
.pay-mode-btn.active {
    background: #7b1fa2 !important;
    background-color: #7b1fa2 !important;
    color: #ffffff !important;
    border-color: #7b1fa2 !important;
    box-shadow: 0 2px 8px rgba(123, 31, 162, 0.35) !important;
}
.pay-mode-btn.active *,
.pay-mode-btn.active i {
    color: #ffffff !important;
}

[data-theme-version="dark"] .pay-mode-btn {
    background: rgba(18, 9, 36, 0.8) !important;
    border-color: rgba(168, 85, 247, 0.35) !important;
    color: #c084fc !important;
}
[data-theme-version="dark"] .pay-mode-btn:hover {
    background: rgba(147, 51, 234, 0.2) !important;
    color: #ffffff !important;
}
[data-theme-version="dark"] .pay-mode-btn.active {
    background: linear-gradient(135deg, #9333ea 0%, #7c3aed 100%) !important;
    background-color: #9333ea !important;
    color: #ffffff !important;
    border-color: #a855f7 !important;
    box-shadow: 0 0 12px rgba(168, 85, 247, 0.4) !important;
}
[data-theme-version="dark"] .pay-mode-btn.active *,
[data-theme-version="dark"] .pay-mode-btn.active i {
    color: #ffffff !important;
}

/* -- Standard Nav-Tabs & Subtabs High-Contrast Styling -- */
.nav-tabs {
    border-bottom: 2px solid #e2e8f0;
}
.nav-tabs .nav-link {
    color: #64748b !important;
    font-weight: 600;
    border: 1px solid transparent;
    border-radius: 8px 8px 0 0;
    transition: all 0.2s ease;
}
.nav-tabs .nav-link:hover {
    color: #7b1fa2 !important;
    border-color: #e2e8f0 #e2e8f0 transparent;
}
.nav-tabs .nav-link.active,
.dzm-tabs .nav-link.active,
.custom-tab-1 .nav-tabs .nav-link.active {
    color: #7b1fa2 !important;
    background-color: #ffffff !important;
    border-color: #e2e8f0 #e2e8f0 #ffffff !important;
    border-bottom: 2px solid #7b1fa2 !important;
    font-weight: 700 !important;
}
.nav-tabs .nav-link.active *,
.nav-tabs .nav-link.active i,
.nav-tabs .nav-link.active span,
.dzm-tabs .nav-link.active *,
.dzm-tabs .nav-link.active i,
.dzm-tabs .nav-link.active span,
.custom-tab-1 .nav-tabs .nav-link.active *,
.custom-tab-1 .nav-tabs .nav-link.active i,
.custom-tab-1 .nav-tabs .nav-link.active span {
    color: #7b1fa2 !important;
}

[data-theme-version="dark"] .nav-tabs {
    border-bottom-color: rgba(168, 85, 247, 0.25) !important;
}
[data-theme-version="dark"] .nav-tabs .nav-link {
    color: #94a3b8 !important;
}
[data-theme-version="dark"] .nav-tabs .nav-link:hover {
    color: #f1f5f9 !important;
}
[data-theme-version="dark"] .nav-tabs .nav-link.active,
[data-theme-version="dark"] .dzm-tabs .nav-link.active,
[data-theme-version="dark"] .custom-tab-1 .nav-tabs .nav-link.active {
    color: #ffffff !important;
    background-color: rgba(28, 14, 56, 0.95) !important;
    border-color: rgba(168, 85, 247, 0.3) rgba(168, 85, 247, 0.3) transparent !important;
    border-bottom: 2px solid #c084fc !important;
}
[data-theme-version="dark"] .nav-tabs .nav-link.active *,
[data-theme-version="dark"] .nav-tabs .nav-link.active i,
[data-theme-version="dark"] .nav-tabs .nav-link.active span,
[data-theme-version="dark"] .dzm-tabs .nav-link.active *,
[data-theme-version="dark"] .dzm-tabs .nav-link.active i,
[data-theme-version="dark"] .dzm-tabs .nav-link.active span,
[data-theme-version="dark"] .custom-tab-1 .nav-tabs .nav-link.active *,
[data-theme-version="dark"] .custom-tab-1 .nav-tabs .nav-link.active i,
[data-theme-version="dark"] .custom-tab-1 .nav-tabs .nav-link.active span {
    color: #ffffff !important;
}

/* -- Brand Logo -- */
.rxplus-logo-abbr {
    font-size: 1.6rem;
    font-weight: 900;
    color: var(--primary);
    letter-spacing: 1px;
}
.rxplus-logo-full {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--bs-body-color);
    letter-spacing: 0.5px;
}
.rxplus-logo-full strong {
    color: var(--primary);
}

/* -- Facility Type Badge inside logo -- */
.facility-badge {
    font-size: 0.6rem;
    font-weight: 600;
    color: var(--primary);
    background: rgba(var(--bs-primary-rgb), 0.1);
    border-radius: 4px;
    padding: 1px 6px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    vertical-align: middle;
}

/* -- Sidebar footer module chip -- */
.deznav-footer {
    border-top: 1px solid rgba(var(--bs-primary-rgb), 0.1);
    padding-top: 12px !important;
}

/* -- Stat Cards premium glow on hover -- */
.card:hover {
    box-shadow: 0 8px 24px rgba(0,0,0,0.10) !important;
    transform: translateY(-2px);
    transition: all 0.25s ease;
}
.card {
    transition: all 0.25s ease;
}

/* -- Quick Action Buttons -- */
.btn-outline-primary:hover,
.btn-outline-success:hover,
.btn-outline-warning:hover,
.btn-outline-info:hover,
.btn-outline-secondary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    transition: all 0.2s ease;
}

/* -- Page Titles / Breadcrumbs Dark Mode Enhancement -- */
body[data-theme-version="dark"] .page-titles,
[data-theme-version="dark"] .page-titles {
    background: linear-gradient(135deg, rgba(28, 16, 56, 0.85) 0%, rgba(18, 9, 38, 0.95) 100%) !important;
    border: 1px solid rgba(168, 85, 247, 0.2) !important;
    backdrop-filter: blur(14px) !important;
    -webkit-backdrop-filter: blur(14px) !important;
    border-radius: 16px !important;
    padding: 14px 22px !important;
    margin-bottom: 22px !important;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.08) !important;
}

body[data-theme-version="dark"] .page-titles .breadcrumb li a,
[data-theme-version="dark"] .page-titles .breadcrumb li a {
    color: #94a3b8 !important;
    font-weight: 500;
}

body[data-theme-version="dark"] .page-titles .breadcrumb li.active,
body[data-theme-version="dark"] .page-titles .breadcrumb li.active a,
[data-theme-version="dark"] .page-titles .breadcrumb li.active,
[data-theme-version="dark"] .page-titles .breadcrumb li.active a {
    color: #c084fc !important;
    font-weight: 700;
}

body[data-theme-version="dark"] .page-titles .breadcrumb .breadcrumb-item + .breadcrumb-item:before,
[data-theme-version="dark"] .page-titles .breadcrumb .breadcrumb-item + .breadcrumb-item:before {
    color: rgba(168, 85, 247, 0.5) !important;
}

/* -- Module access grid items -- */
.list-group-item:hover {
    background: rgba(var(--bs-primary-rgb), 0.04);
}

/* -- Auth (Login) page brand -- */
.auth-rxplus-logo {
    font-size: 2.4rem;
    font-weight: 900;
    letter-spacing: 1px;
    text-decoration: none;
}
.auth-rxplus-logo .rx-part { color: var(--primary); }
.auth-rxplus-logo .plus-part { color: var(--bs-body-color); }

/* -- Badge light variants -- */
.badge-light-primary { background: rgba(var(--bs-primary-rgb),.12); color: var(--primary); }
.badge-light-success { background: rgba(34,197,94,.12); color: #16a34a; }
.badge-light-warning { background: rgba(249,115,22,.12); color: #d97706; }
.badge-light-danger  { background: rgba(239,68,68,.12);  color: #dc2626; }

/* -- Notification hover -- */
.hover-light:hover { background: rgba(0,0,0,0.04); }

/* -- Topnav: session info pill -- */
.header .badge {
    border-radius: 20px;
    font-weight: 500;
}

/* -- Responsive adjustments -- */
@media (max-width: 767px) {
    .rxplus-logo-full small.facility-badge { display: none; }
}

/* -- Scenic / Hospital background for auth pages -- */
body.auth-glass-bg {
    background: url('../images/hospital_bg.png') no-repeat center center fixed;
    background-size: cover;
    position: relative;
    z-index: 1;
}

body.auth-glass-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.45); /* Dark filter overlay */
    z-index: -1;
}

/* -- Text visibility overrides for auth labels -- */
body.auth-glass-bg label,
body.auth-glass-bg label strong {
    color: rgba(255, 255, 255, 0.95) !important;
}

body.auth-glass-bg .form-check-label {
    color: rgba(255, 255, 255, 0.85) !important;
}

body.auth-glass-bg .text-muted-white {
    color: rgba(255, 255, 255, 0.6) !important;
}

/* -- Hide template demo/style switcher & floating support widgets -- */
.sidebar-right-trigger,
.dz-demo-panel > .dz-demo-trigger,
.dz-theme-mode,
#DZScript,
.w3-global-support,
.dz-theme-demo,
[class*="dzSupportPanel"],
[id*="dzSupportPanel"] {
    display: none !important;
    visibility: hidden !important;
}

/* -- Preloader Safety Override --
   If JS fails to remove preloader, force-hide it via animation.
   The main-wrapper must always be visible. */
#preloader {
    animation: preloader-auto-dismiss 2s forwards;
    animation-delay: 1.5s;
}
@keyframes preloader-auto-dismiss {
    0%   { opacity: 1; pointer-events: all; }
    90%  { opacity: 0; }
    100% { opacity: 0; display: none; pointer-events: none; }
}

/* Ensure main wrapper is ALWAYS visible regardless of .show class */
#main-wrapper {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
}

/* ============================================================
   RXPlus Brand Logo & Nav-Header Theme Controls
   Single-Logo System for Full & Collapsed Modes
   ============================================================ */

/* -- Reset template filter -- */
.nav-header .brand-logo,
[data-bs-theme="dark"] .nav-header .brand-logo,
[data-theme-version="dark"] .nav-header .brand-logo {
    filter: none !important;
}

/* -- Brand Logo Container -- */
.nav-header .brand-logo {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    padding: 0 16px !important;
    text-decoration: none !important;
    height: 100% !important;
    transition: all 0.2s ease !important;
}

/* -- Single Logo Icon Sizing & Transitions -- */
.nav-header .logo-abbr,
.nav-header .rxplus-logo {
    height: 38px !important;
    width: 38px !important;
    max-width: 38px !important;
    max-height: 38px !important;
    object-fit: contain !important;
    flex-shrink: 0 !important;
    display: block !important;
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
}
.nav-header .brand-logo:hover .logo-abbr {
    transform: scale(1.06) !important;
}

/* -- Brand Title Typography (RxPlus HMS) -- */
.nav-header .brand-title {
    font-size: 1.45rem !important;
    font-weight: 800 !important;
    letter-spacing: 0.5px !important;
    white-space: nowrap !important;
    line-height: 1 !important;
    margin: 0 !important;
    margin-left: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    transition: color 0.2s ease !important;
}
.nav-header .brand-title .brand-sub {
    font-weight: 800 !important;
}

/* ============================================================
   1. LIGHT MODE (Default)
   ============================================================ */
.nav-header {
    background: #ffffff !important;
    border-bottom: 1px solid #eef2f6 !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02) !important;
}
.nav-header .logo-abbr,
.nav-header .rxplus-logo {
    filter: none !important;
}
.nav-header .brand-title {
    color: #0f172a !important; /* Bold, crisp dark slate */
}
.nav-header .brand-title .brand-sub {
    color: #7b1fa2 !important; /* Rich brand purple */
}
.nav-control .hamburger .line {
    background: #334155 !important;
}

/* ============================================================
   2. DARK MODE ([data-theme-version="dark"] / [data-bs-theme="dark"])
   ============================================================ */
[data-theme-version="dark"] .nav-header,
[data-bs-theme="dark"] .nav-header {
    background: #111428 !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07) !important;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25) !important;
}
[data-theme-version="dark"] .nav-header .logo-abbr,
[data-theme-version="dark"] .nav-header .rxplus-logo,
[data-bs-theme="dark"] .nav-header .logo-abbr,
[data-bs-theme="dark"] .nav-header .rxplus-logo {
    filter: drop-shadow(0 0 6px rgba(192, 132, 252, 0.45)) !important;
}
[data-theme-version="dark"] .nav-header .brand-title,
[data-bs-theme="dark"] .nav-header .brand-title {
    color: #ffffff !important;
}
[data-theme-version="dark"] .nav-header .brand-title .brand-sub,
[data-bs-theme="dark"] .nav-header .brand-title .brand-sub {
    color: #c084fc !important;
    text-shadow: 0 0 10px rgba(192, 132, 252, 0.5) !important;
}
[data-theme-version="dark"] .nav-control .hamburger .line,
[data-bs-theme="dark"] .nav-control .hamburger .line {
    background: #e2e8f0 !important;
}

/* ============================================================
   3. COLLAPSED / MINI SIDEBAR MODE
   Single centered logo in both Light and Dark modes
   ============================================================ */
#main-wrapper.menu-toggle .nav-header .brand-title,
[data-sidebar-style="mini"] .nav-header .brand-title,
[data-sidebar-style="compact"] .nav-header .brand-title,
[data-sidebar-style="icon-hover"] .nav-header .brand-title {
    display: none !important;
}

#main-wrapper.menu-toggle .nav-header .brand-logo,
[data-sidebar-style="mini"] .nav-header .brand-logo,
[data-sidebar-style="compact"] .nav-header .brand-logo,
[data-sidebar-style="icon-hover"] .nav-header .brand-logo {
    justify-content: center !important;
    padding: 0 !important;
    gap: 0 !important;
    width: 100% !important;
}

#main-wrapper.menu-toggle .nav-header .logo-abbr,
#main-wrapper.menu-toggle .nav-header .rxplus-logo,
[data-sidebar-style="mini"] .nav-header .logo-abbr,
[data-sidebar-style="mini"] .nav-header .rxplus-logo,
[data-sidebar-style="compact"] .nav-header .logo-abbr,
[data-sidebar-style="compact"] .nav-header .rxplus-logo,
[data-sidebar-style="icon-hover"] .nav-header .logo-abbr,
[data-sidebar-style="icon-hover"] .nav-header .rxplus-logo {
    margin: 0 auto !important;
    width: 38px !important;
    height: 38px !important;
    max-width: 38px !important;
    display: block !important;
}

/* ============================================================
   RXPlus Dashboard Redesign - Ultra-Elegant Light & Dark Theme
   ============================================================ */

/* -- Dashboard Hero Header -- */
.dash-hero-card {
    background: linear-gradient(135deg, #ffffff 0%, #faf8ff 50%, #f5f3ff 100%);
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 20px;
    padding: 24px 28px;
    box-shadow: 0 4px 25px -4px rgba(123, 31, 162, 0.05);
    position: relative;
    overflow: hidden;
    margin-bottom: 24px;
}
.dash-hero-card::after {
    content: '';
    position: absolute;
    top: -50px;
    right: -50px;
    width: 220px;
    height: 220px;
    background: radial-gradient(circle, rgba(123, 31, 162, 0.08) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}
.dash-hero-title {
    font-size: 1.65rem;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.5px;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.dash-hero-sub {
    color: #64748b;
    font-size: 0.92rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}
.dash-pulse-badge {
    background: rgba(16, 185, 129, 0.1);
    color: #059669;
    border: 1px solid rgba(16, 185, 129, 0.25);
    border-radius: 30px;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 6px 14px;
    display: inline-flex;
    align-items: center;
    gap: 7px;
}
.dash-pulse-dot {
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    animation: dashPulse 2s infinite;
}
@keyframes dashPulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* -- KPI Metric Cards -- */
.kpi-card {
    background: #ffffff;
    border: 1px solid rgba(226, 232, 240, 0.85);
    border-radius: 20px;
    padding: 22px;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.04);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}
.kpi-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px -4px rgba(123, 31, 162, 0.12);
    border-color: rgba(123, 31, 162, 0.3);
}
.kpi-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}
.kpi-icon-box {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 24px;
    flex-shrink: 0;
}
.kpi-icon-purple {
    background: linear-gradient(135deg, #9333ea 0%, #7c3aed 100%);
    box-shadow: 0 6px 16px rgba(147, 51, 234, 0.35);
}
.kpi-icon-emerald {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    box-shadow: 0 6px 16px rgba(16, 185, 129, 0.35);
}
.kpi-icon-amber {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    box-shadow: 0 6px 16px rgba(245, 158, 11, 0.35);
}
.kpi-icon-indigo {
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    box-shadow: 0 6px 16px rgba(99, 102, 241, 0.35);
}
.kpi-micro-badge {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
    letter-spacing: 0.3px;
}
.kpi-badge-purple { background: rgba(147, 51, 234, 0.1); color: #7c3aed; }
.kpi-badge-emerald { background: rgba(16, 185, 129, 0.1); color: #059669; }
.kpi-badge-amber { background: rgba(245, 158, 11, 0.1); color: #d97706; }
.kpi-badge-indigo { background: rgba(99, 102, 241, 0.1); color: #4f46e5; }

.kpi-hero-num {
    font-size: 2rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.1;
    letter-spacing: -0.5px;
    margin-bottom: 4px;
}
.kpi-hero-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
    margin-bottom: 0;
}
.kpi-footer-link {
    border-top: 1px solid #f1f5f9;
    padding-top: 14px;
    margin-top: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}
.kpi-footer-link i {
    transition: transform 0.2s ease;
}
.kpi-card:hover .kpi-footer-link i {
    transform: translateX(4px);
}

/* -- Quick Action Launchpad Tiles -- */
.action-tile-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 14px;
}
.action-tile {
    background: #ffffff;
    border: 1.5px solid rgba(226, 232, 240, 0.9);
    border-radius: 16px;
    padding: 14px 18px;
    display: flex;
    align-items: center;
    gap: 14px;
    text-decoration: none !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.02);
}
.action-tile:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px -3px rgba(15, 23, 42, 0.08);
    border-color: var(--tile-accent, #7b1fa2);
    text-decoration: none !important;
}
.action-tile-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
    transition: transform 0.25s ease;
}
.action-tile:hover .action-tile-icon {
    transform: scale(1.08);
}
.action-tile-title {
    font-size: 0.92rem;
    font-weight: 700;
    color: #0f172a;
    line-height: 1.2;
    margin-bottom: 2px;
}
.action-tile-desc {
    font-size: 0.75rem;
    font-weight: 500;
    color: #64748b;
    line-height: 1.2;
}

/* Color Themes for Action Tiles */
.tile-purple { --tile-accent: #7b1fa2; }
.tile-purple .action-tile-icon { background: rgba(123, 31, 162, 0.1); color: #7b1fa2; }

.tile-blue { --tile-accent: #2563eb; }
.tile-blue .action-tile-icon { background: rgba(37, 99, 235, 0.1); color: #2563eb; }

.tile-amber { --tile-accent: #ea580c; }
.tile-amber .action-tile-icon { background: rgba(234, 88, 12, 0.1); color: #ea580c; }

.tile-emerald { --tile-accent: #059669; }
.tile-emerald .action-tile-icon { background: rgba(5, 150, 105, 0.1); color: #059669; }

.tile-indigo { --tile-accent: #6366f1; }
.tile-indigo .action-tile-icon { background: rgba(99, 102, 241, 0.1); color: #6366f1; }

/* -- Section Card Container -- */
.dash-section-card {
    background: #ffffff;
    border: 1px solid rgba(226, 232, 240, 0.85);
    border-radius: 20px;
    box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.04);
    margin-bottom: 24px;
    overflow: hidden;
}
.dash-card-header {
    padding: 20px 24px;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.dash-card-header-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
}
.dash-card-body {
    padding: 24px;
}

/* -- Module Capabilities Grid -- */
.module-caps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
}
.module-caps-item {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #1e293b;
    transition: all 0.2s ease;
}
.module-caps-item:hover {
    background: #ffffff;
    border-color: #cbd5e1;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.05);
}
.module-caps-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: rgba(16, 185, 129, 0.12);
    color: #059669;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    flex-shrink: 0;
}

/* -- Executive Session Info Widget -- */
.user-profile-badge-box {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px;
    background: linear-gradient(135deg, rgba(123, 31, 162, 0.06) 0%, rgba(99, 102, 241, 0.06) 100%);
    border-radius: 16px;
    margin-bottom: 20px;
    border: 1px solid rgba(123, 31, 162, 0.12);
}
.user-avatar-gradient {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: linear-gradient(135deg, #7b1fa2 0%, #6366f1 100%);
    color: #ffffff;
    font-size: 1.15rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(123, 31, 162, 0.3);
    flex-shrink: 0;
}
.session-stat-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px dashed #e2e8f0;
    font-size: 0.85rem;
}
.session-stat-row:last-child {
    border-bottom: none;
}
.session-stat-label {
    color: #64748b;
    font-weight: 500;
}
.session-stat-val {
    color: #0f172a;
    font-weight: 600;
}

/* ============================================================
   Dark Mode Overrides for Dashboard
   ============================================================ */
[data-theme-version="dark"] .dash-hero-card {
    background: linear-gradient(135deg, #161933 0%, #1e1b4b 60%, #161933 100%);
    border-color: rgba(255, 255, 255, 0.08);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}
[data-theme-version="dark"] .dash-hero-title {
    color: #ffffff;
}
[data-theme-version="dark"] .dash-hero-sub {
    color: #94a3b8;
}
[data-theme-version="dark"] .kpi-card,
[data-theme-version="dark"] .dash-section-card,
[data-theme-version="dark"] .action-tile {
    background: #161933;
    border-color: rgba(255, 255, 255, 0.08);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}
[data-theme-version="dark"] .kpi-hero-num,
[data-theme-version="dark"] .action-tile-title,
[data-theme-version="dark"] .dash-card-header-title,
[data-theme-version="dark"] .session-stat-val {
    color: #ffffff;
}
[data-theme-version="dark"] .kpi-hero-label,
[data-theme-version="dark"] .action-tile-desc,
[data-theme-version="dark"] .session-stat-label {
    color: #94a3b8;
}
[data-theme-version="dark"] .dash-card-header,
[data-theme-version="dark"] .kpi-footer-link {
    border-color: rgba(255, 255, 255, 0.08);
}
[data-theme-version="dark"] .session-stat-row {
    border-color: rgba(255, 255, 255, 0.08);
}
[data-theme-version="dark"] .module-caps-item {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.08);
    color: #e2e8f0;
}
[data-theme-version="dark"] .module-caps-item:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(192, 132, 252, 0.4);
}
[data-theme-version="dark"] .user-profile-badge-box {
    background: rgba(168, 85, 247, 0.12);
    border-color: rgba(168, 85, 247, 0.25);
}


