/* Premium Dashboard Styles - Navy/Gold/Emerald Theme */

/* Base body for sidebar pages */
body.sidebar-page {
    background: #0A1628;
    color: #B8B4AC;
    font-family: 'Inter', sans-serif;
    opacity: 1;
}

/* Tailwind utility classes for sidebar layout */
.fixed { position: fixed; }
.inset-0 { inset: 0; }
.left-0 { left: 0; }
.top-0 { top: 0; }
.h-full { height: 100%; }
.w-64 { width: 16rem; }
.z-40 { z-index: 40; }
.z-50 { z-index: 50; }
.transform { transform: var(--tw-transform, none); }
.-translate-x-full { transform: translateX(-100%); }
.transition-transform { transition: transform 0.3s ease-in-out; }
.duration-300 { transition-duration: 300ms; }
.ease-in-out { transition-timing-function: ease-in-out; }
.overflow-hidden { overflow: hidden; }
.sm-show { display: none; }

@media (min-width: 640px) {
    .sm-show { display: block; }
}

@media (min-width: 1024px) {
    .lg\:translate-x-0 { transform: translateX(0); }
    .lg\:hidden { display: none !important; }
}

/* Main content area */
.lg\:ml-64 {
    min-height: 100vh;
}

@media (min-width: 1024px) {
    .lg\:ml-64 {
        margin-left: 16rem;
    }
}

/* Dashboard Header */
.dashboard-header {
    background: rgba(13,27,42,0.8);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(197,165,90,0.08);
    padding: 16px 24px;
    position: sticky;
    top: 0;
    z-index: 30;
}

.dashboard-header h1 {
    font-family: 'Playfair Display', serif;
    color: #FFFFFF;
    font-weight: 700;
}

.dashboard-header p {
    color: rgba(184,180,172,0.6);
}

/* Header action buttons */
.header-action-btn {
    padding: 8px;
    color: rgba(184,180,172,0.5);
    background: rgba(22,37,68,0.4);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s;
}

.header-action-btn:hover {
    color: #C5A55A;
    background: rgba(197,165,90,0.08);
    border-color: rgba(197,165,90,0.15);
}

/* Dashboard Cards */
.dash-card {
    background: rgba(22,37,68,0.3);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 16px;
    padding: 24px;
    transition: all 0.3s;
}

.dash-card:hover {
    border-color: rgba(197,165,90,0.12);
    background: rgba(22,37,68,0.4);
}

/* Stat Cards */
.stat-card {
    background: rgba(22,37,68,0.3);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 16px;
    padding: 24px;
    transition: all 0.3s;
}

.stat-card:hover {
    border-color: rgba(197,165,90,0.12);
    transform: translateY(-2px);
}

.stat-card .stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-card .stat-value {
    font-size: 2rem;
    font-weight: 800;
    color: #FFFFFF;
    font-family: 'Inter', sans-serif;
}

.stat-card .stat-label {
    font-size: 0.875rem;
    color: rgba(184,180,172,0.6);
    font-weight: 500;
}

.stat-card .stat-badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 50px;
}

/* Welcome Banner */
.welcome-banner {
    background: linear-gradient(135deg, rgba(197,165,90,0.15) 0%, rgba(16,185,129,0.1) 100%);
    border: 1px solid rgba(197,165,90,0.15);
    border-radius: 16px;
    padding: 32px;
}

.welcome-banner h2 {
    font-family: 'Playfair Display', serif;
    color: #FFFFFF;
    font-weight: 700;
}

.welcome-banner p {
    color: rgba(184,180,172,0.7);
}

.welcome-banner .btn-primary {
    background: linear-gradient(135deg, #C5A55A 0%, #D4B96E 50%, #A68B42 100%);
    color: #0A1628;
    padding: 10px 20px;
    border-radius: 10px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
}

.welcome-banner .btn-secondary {
    background: rgba(255,255,255,0.08);
    color: #FFFFFF;
    padding: 10px 20px;
    border-radius: 10px;
    font-weight: 500;
    border: 1px solid rgba(255,255,255,0.1);
    cursor: pointer;
    transition: all 0.3s;
}

/* Quick Actions */
.quick-action-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 16px;
    background: rgba(22,37,68,0.4);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
    text-decoration: none;
}

.quick-action-btn:hover {
    background: rgba(197,165,90,0.08);
    border-color: rgba(197,165,90,0.15);
    transform: translateY(-2px);
}

.quick-action-btn .icon-wrap {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
}

.quick-action-btn .action-title {
    font-weight: 600;
    color: #FFFFFF;
    font-size: 0.875rem;
    margin-bottom: 4px;
}

.quick-action-btn .action-desc {
    font-size: 0.75rem;
    color: rgba(184,180,172,0.5);
}

/* Table styles */
.premium-table {
    width: 100%;
    border-collapse: collapse;
}

.premium-table th {
    padding: 12px 16px;
    font-size: 0.75rem;
    font-weight: 600;
    color: rgba(197,165,90,0.6);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    text-align: left;
    border-bottom: 1px solid rgba(197,165,90,0.08);
}

.premium-table td {
    padding: 16px;
    color: rgba(184,180,172,0.8);
    border-bottom: 1px solid rgba(255,255,255,0.03);
}

.premium-table tr:hover td {
    background: rgba(197,165,90,0.03);
}

/* Badge styles */
.badge-gold {
    background: rgba(197,165,90,0.12);
    color: #C5A55A;
    border: 1px solid rgba(197,165,90,0.2);
}

.badge-emerald {
    background: rgba(16,185,129,0.12);
    color: #10B981;
    border: 1px solid rgba(16,185,129,0.2);
}

.badge-blue {
    background: rgba(59,130,246,0.12);
    color: #3B82F6;
    border: 1px solid rgba(59,130,246,0.2);
}

.badge-red {
    background: rgba(239,68,68,0.12);
    color: #EF4444;
    border: 1px solid rgba(239,68,68,0.2);
}

.badge-purple {
    background: rgba(168,85,247,0.12);
    color: #A855F7;
    border: 1px solid rgba(168,85,247,0.2);
}

/* Section headers */
.section-header {
    font-family: 'Playfair Display', serif;
    font-size: 1.125rem;
    font-weight: 600;
    color: #FFFFFF;
}

.section-subheader {
    font-size: 0.875rem;
    color: rgba(184,180,172,0.5);
}

/* Gold button */
.btn-gold {
    background: linear-gradient(135deg, #C5A55A 0%, #D4B96E 50%, #A68B42 100%);
    color: #0A1628;
    padding: 10px 20px;
    border-radius: 10px;
    font-weight: 700;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Inter', sans-serif;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.btn-gold:hover {
    box-shadow: 0 4px 15px rgba(197,165,90,0.3);
}

/* Ghost button */
.btn-ghost {
    background: rgba(22,37,68,0.4);
    color: rgba(184,180,172,0.8);
    padding: 10px 20px;
    border-radius: 10px;
    font-weight: 500;
    border: 1px solid rgba(255,255,255,0.08);
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Inter', sans-serif;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.btn-ghost:hover {
    border-color: rgba(197,165,90,0.2);
    color: #C5A55A;
}

/* Form inputs */
.premium-input {
    width: 100%;
    padding: 12px 16px;
    background: rgba(22,37,68,0.6);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    color: #FFFFFF;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    transition: all 0.3s;
    outline: none;
}

.premium-input::placeholder {
    color: rgba(184,180,172,0.4);
}

.premium-input:focus {
    border-color: #C5A55A;
    box-shadow: 0 0 0 3px rgba(197,165,90,0.1);
}

/* Modal styles */
.premium-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(10,22,40,0.7);
    backdrop-filter: blur(8px);
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.premium-modal {
    background: linear-gradient(180deg, #111D2E 0%, #0D1B2A 100%);
    border: 1px solid rgba(197,165,90,0.1);
    border-radius: 20px;
    max-width: 640px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
}

.premium-modal-header {
    background: linear-gradient(135deg, rgba(197,165,90,0.12) 0%, rgba(197,165,90,0.05) 100%);
    border-bottom: 1px solid rgba(197,165,90,0.1);
    padding: 20px 24px;
    border-radius: 20px 20px 0 0;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: rgba(22,37,68,0.3);
}

::-webkit-scrollbar-thumb {
    background: rgba(197,165,90,0.2);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(197,165,90,0.4);
}

/* Mobile menu button */
#mobile-menu-btn {
    display: none;
    padding: 8px;
    color: rgba(184,180,172,0.6);
    background: rgba(22,37,68,0.4);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 10px;
    cursor: pointer;
}

@media (max-width: 1023px) {
    #mobile-menu-btn {
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

/* Animations */
@keyframes spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.animate-fade-in { animation: fadeIn 0.5s ease-out forwards; }

/* Notification badge */
.notification-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 20px;
    height: 20px;
    background: #EF4444;
    color: white;
    font-size: 0.65rem;
    font-weight: 700;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 48px 24px;
}

.empty-state .icon-wrap {
    width: 64px;
    height: 64px;
    background: rgba(22,37,68,0.6);
    border: 1px solid rgba(197,165,90,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.empty-state h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.25rem;
    font-weight: 600;
    color: #FFFFFF;
    margin-bottom: 8px;
}

.empty-state p {
    color: rgba(184,180,172,0.5);
    margin-bottom: 24px;
}

/* Hidden class override */
.hidden {
    display: none !important;
}

/* ===== Light Mode Overrides for Dashboard/Sidebar Pages ===== */

body.sidebar-page.light-mode {
    background: #F5F3EF;
    color: #2D3748;
}

/* Dashboard header light mode */
body.light-mode .dashboard-header {
    background: rgba(255, 255, 255, 0.9);
    border-bottom-color: rgba(10, 22, 40, 0.08);
}

body.light-mode .dashboard-header h1 {
    color: #0A1628;
}

body.light-mode .dashboard-header p {
    color: #64748B;
}

/* Header action buttons light mode */
body.light-mode .header-action-btn {
    color: #64748B;
    background: rgba(10, 22, 40, 0.04);
    border-color: rgba(10, 22, 40, 0.08);
}

body.light-mode .header-action-btn:hover {
    color: #8B7332;
    background: rgba(139, 115, 50, 0.08);
    border-color: rgba(139, 115, 50, 0.15);
}

/* Dashboard cards light mode */
body.light-mode .dash-card {
    background: #FFFFFF;
    border-color: rgba(10, 22, 40, 0.08);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

body.light-mode .dash-card:hover {
    border-color: rgba(139, 115, 50, 0.2);
    background: #FFFFFF;
}

/* Stat cards light mode */
body.light-mode .stat-card {
    background: #FFFFFF;
    border-color: rgba(10, 22, 40, 0.08);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

body.light-mode .stat-card:hover {
    border-color: rgba(139, 115, 50, 0.2);
}

body.light-mode .stat-card .stat-value {
    color: #0A1628;
}

body.light-mode .stat-card .stat-label {
    color: #64748B;
}

/* Welcome banner light mode */
body.light-mode .welcome-banner {
    background: linear-gradient(135deg, rgba(139, 115, 50, 0.08) 0%, rgba(0, 168, 107, 0.06) 100%);
    border-color: rgba(139, 115, 50, 0.15);
}

body.light-mode .welcome-banner h2 {
    color: #0A1628;
}

body.light-mode .welcome-banner p {
    color: #4A5568;
}

body.light-mode .welcome-banner .btn-secondary {
    background: rgba(10, 22, 40, 0.06);
    color: #1A2940;
    border-color: rgba(10, 22, 40, 0.12);
}

/* Quick actions light mode */
body.light-mode .quick-action-btn {
    background: #FFFFFF;
    border-color: rgba(10, 22, 40, 0.08);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

body.light-mode .quick-action-btn:hover {
    background: rgba(139, 115, 50, 0.04);
    border-color: rgba(139, 115, 50, 0.2);
}

body.light-mode .quick-action-btn .action-title {
    color: #0A1628;
}

body.light-mode .quick-action-btn .action-desc {
    color: #64748B;
}

/* Table light mode */
body.light-mode .premium-table th {
    color: #8B7332;
    border-bottom-color: rgba(10, 22, 40, 0.08);
}

body.light-mode .premium-table td {
    color: #2D3748;
    border-bottom-color: rgba(10, 22, 40, 0.04);
}

body.light-mode .premium-table tr:hover td {
    background: rgba(139, 115, 50, 0.04);
}

/* Section headers light mode */
body.light-mode .section-header {
    color: #0A1628;
}

body.light-mode .section-subheader {
    color: #64748B;
}

/* Ghost button light mode */
body.light-mode .btn-ghost {
    background: rgba(10, 22, 40, 0.04);
    color: #4A5568;
    border-color: rgba(10, 22, 40, 0.08);
}

body.light-mode .btn-ghost:hover {
    border-color: rgba(139, 115, 50, 0.2);
    color: #8B7332;
}

/* Form inputs light mode */
body.light-mode .premium-input {
    background: #FFFFFF;
    border-color: rgba(10, 22, 40, 0.12);
    color: #1A2940;
}

body.light-mode .premium-input::placeholder {
    color: #94A3B8;
}

body.light-mode .premium-input:focus {
    border-color: #8B7332;
    box-shadow: 0 0 0 3px rgba(139, 115, 50, 0.1);
}

/* Modal light mode */
body.light-mode .premium-modal {
    background: #FFFFFF;
    border-color: rgba(10, 22, 40, 0.1);
}

body.light-mode .premium-modal-header {
    background: linear-gradient(135deg, rgba(139, 115, 50, 0.06) 0%, rgba(139, 115, 50, 0.02) 100%);
    border-bottom-color: rgba(10, 22, 40, 0.08);
}

/* Empty state light mode */
body.light-mode .empty-state .icon-wrap {
    background: rgba(10, 22, 40, 0.04);
    border-color: rgba(139, 115, 50, 0.1);
}

body.light-mode .empty-state h3 {
    color: #0A1628;
}

body.light-mode .empty-state p {
    color: #64748B;
}

/* Scrollbar light mode */
body.light-mode ::-webkit-scrollbar-track {
    background: #F5F3EF;
}

body.light-mode ::-webkit-scrollbar-thumb {
    background: #D1CCC4;
}

body.light-mode ::-webkit-scrollbar-thumb:hover {
    background: #8B7332;
}

/* Force inline style overrides for sidebar pages in light mode */
body.light-mode [style*="color:#FFFFFF"],
body.light-mode [style*="color: #FFFFFF"],
body.light-mode [style*="color:white"],
body.light-mode [style*="color: white"] {
    color: #0A1628 !important;
}

body.light-mode [style*="color:rgba(184,180,172"],
body.light-mode [style*="color: rgba(184,180,172"],
body.light-mode [style*="color:#B8B4AC"],
body.light-mode [style*="color: #B8B4AC"] {
    color: #4A5568 !important;
}

body.light-mode [style*="background:rgba(22,37,68"],
body.light-mode [style*="background: rgba(22,37,68"] {
    background: rgba(10, 22, 40, 0.03) !important;
}

body.light-mode [style*="background:rgba(13,27,42"],
body.light-mode [style*="background: rgba(13,27,42"] {
    background: rgba(10, 22, 40, 0.02) !important;
}

body.light-mode [style*="background:#0A1628"],
body.light-mode [style*="background: #0A1628"] {
    background: #F5F3EF !important;
}

body.light-mode [style*="background:linear-gradient(180deg,#111D2E"],
body.light-mode [style*="background:linear-gradient(135deg,rgba(197,165,90,0.08)"] {
    background: rgba(139, 115, 50, 0.04) !important;
}

body.light-mode [style*="color:#C5A55A"],
body.light-mode [style*="color: #C5A55A"] {
    color: #8B7332 !important;
}

body.light-mode [style*="color:#00A86B"],
body.light-mode [style*="color: #00A86B"] {
    color: #007A4D !important;
}

/* Notification badge stays red in both modes */
body.light-mode .notification-badge {
    background: #EF4444;
    color: white !important;
}
