/* Urban Sundari Modern Premium Enterprise Dashboard Style System */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Montserrat:wght@400;500;600;700;800&display=swap');

:root {
    --bg-primary: #0a0314;
    --bg-secondary: #120524;
    --bg-sidebar: #07020e;
    --bg-card: rgba(24, 8, 48, 0.55);
    --border-color: rgba(157, 78, 221, 0.25);
    
    --accent-indigo: #9d4edd;
    --accent-indigo-hover: #7b2cbf;
    
    --accent-emerald: #10b981;
    --accent-emerald-hover: #059669;
    
    --accent-cyan: #d8b4fe;
    --accent-cyan-hover: #bb96ff;
    
    --accent-amber: #ffca3a;
    --accent-amber-hover: #e0b020;
    
    --accent-rose: #ff595e;
    --accent-rose-hover: #e04a50;
    
    --text-primary: #ffffff;
    --text-muted: #dcd6e8;
    --text-highlight: #ffddff;
    
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

    /* ===== BOOTSTRAP 5 TABLE - COMPLETE DARK THEME OVERRIDE ===== */
    --bs-table-bg: rgba(18, 5, 36, 0.6);
    --bs-table-color: #ffffff;
    --bs-table-border-color: rgba(157, 78, 221, 0.15);
    --bs-table-striped-bg: rgba(157, 78, 221, 0.08);
    --bs-table-striped-color: #ffffff;
    --bs-table-active-bg: rgba(157, 78, 221, 0.2);
    --bs-table-active-color: #ffffff;
    --bs-table-hover-bg: rgba(157, 78, 221, 0.12);
    --bs-table-hover-color: #ffffff;
    --bs-body-color: #ffffff;
    --bs-body-bg: transparent;
}

/* =====================================================
   GLOBAL TABLE DARK THEME - NUCLEAR OVERRIDE
   Matches the purple dark theme across ALL tables
   ===================================================== */

/* Kill Bootstrap 5 striped white rows completely */
.table-striped > tbody > tr > * {
    --bs-table-color-type: #ffffff !important;
    --bs-table-bg-type: rgba(157, 78, 221, 0.08) !important;
    color: #ffffff !important;
    background-color: rgba(157, 78, 221, 0.08) !important;
}
.table-striped > tbody > tr:nth-of-type(even) > * {
    --bs-table-color-type: #ffffff !important;
    --bs-table-bg-type: rgba(18, 5, 36, 0.5) !important;
    color: #ffffff !important;
    background-color: rgba(18, 5, 36, 0.5) !important;
}

/* All table elements - base dark theme */
table,
.table,
table.dataTable {
    background-color: rgba(12, 3, 25, 0.7) !important;
    color: #ffffff !important;
    border-color: rgba(157, 78, 221, 0.15) !important;
}

/* All table rows */
.table tr,
.table tbody tr,
table.dataTable tr,
table.dataTable tbody tr {
    background-color: transparent !important;
    color: #ffffff !important;
}

/* All table cells - force white text on dark bg */
table td,
table th,
.table td,
.table th,
.table tbody td,
.table tbody th,
.table thead td,
.table thead th,
table.dataTable td,
table.dataTable th,
table.dataTable tbody td,
table.dataTable tbody th,
table.dataTable.display tbody td,
table.dataTable.display tbody th,
table.dataTable.display tbody tr.odd td,
table.dataTable.display tbody tr.even td,
table.dataTable.display tbody tr.odd th,
table.dataTable.display tbody tr.even th {
    color: #ffffff !important;
    background-color: transparent !important;
    border-color: rgba(157, 78, 221, 0.12) !important;
    padding: 0.85rem 1rem !important;
    vertical-align: middle !important;
}

/* Thead - slightly lighter purple tint */
.table thead th,
.table thead td,
table.dataTable thead th,
table.dataTable thead td {
    background-color: rgba(157, 78, 221, 0.18) !important;
    color: #f0d9ff !important;
    border-bottom: 2px solid rgba(157, 78, 221, 0.35) !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    font-size: 0.78rem !important;
    letter-spacing: 0.8px !important;
}

/* Odd rows - subtle purple tint */
.table-striped > tbody > tr:nth-of-type(odd) > *,
table.dataTable tbody tr.odd td,
table.dataTable.display tbody tr.odd td {
    color: #ffffff !important;
    background-color: rgba(157, 78, 221, 0.07) !important;
}

/* Even rows - deeper dark */
.table-striped > tbody > tr:nth-of-type(even) > *,
table.dataTable tbody tr.even td,
table.dataTable.display tbody tr.even td {
    color: #ffffff !important;
    background-color: rgba(8, 2, 18, 0.5) !important;
}

/* Hover effect */
.table-hover > tbody > tr:hover > *,
table.dataTable tbody tr:hover td,
table.dataTable.display tbody tr:hover td {
    color: #ffffff !important;
    background-color: rgba(157, 78, 221, 0.18) !important;
}

/* DataTables selected row */
table.dataTable tbody tr.selected > *,
table.dataTable tbody tr.selected td {
    color: #ffffff !important;
    background-color: rgba(157, 78, 221, 0.25) !important;
    box-shadow: none !important;
}

/* DataTables wrapper text - white on dark */
.dataTables_wrapper,
.dataTables_wrapper label,
.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_paginate,
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter {
    color: #dcd6e8 !important;
}

/* DataTables search & show entries inputs */
.dataTables_wrapper select,
.dataTables_wrapper input[type="search"],
.dataTables_wrapper input[type="text"] {
    background-color: rgba(18, 5, 36, 0.9) !important;
    color: #ffffff !important;
    border: 1px solid rgba(157, 78, 221, 0.3) !important;
    border-radius: 6px !important;
    padding: 4px 10px !important;
    outline: none !important;
}

/* Pagination buttons */
.dataTables_wrapper .dataTables_paginate .paginate_button {
    color: #dcd6e8 !important;
    border: 1px solid rgba(157, 78, 221, 0.2) !important;
    background-color: rgba(18, 5, 36, 0.6) !important;
    border-radius: 4px !important;
    margin: 2px !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
    color: #ffffff !important;
    background: rgba(157, 78, 221, 0.3) !important;
    border: 1px solid rgba(157, 78, 221, 0.5) !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
    color: #ffffff !important;
    background: var(--accent-indigo) !important;
    border: 1px solid var(--accent-indigo) !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled,
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover {
    color: rgba(255,255,255,0.3) !important;
}

/* Card Height Alignment Utility */
.row {
    display: flex;
    flex-wrap: wrap;
}
.row > [class*="col-"] {
    display: flex;
    flex-direction: column;
}
.card {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    height: 100%;
}
.card-body {
    flex: 1 1 auto;
}

/* Global Reset & Body */
body {
    font-family: 'Inter', sans-serif !important;
    background: radial-gradient(circle at 50% 50%, #15062c 0%, #06010d 100%) !important;
    color: var(--text-primary) !important;
    overflow-x: hidden;
}

.wrapper {
    background: transparent !important;
}

.main {
    background: transparent !important;
}

/* Custom Premium Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
    background: var(--accent-indigo);
    border-radius: 4px;
    opacity: 0.7;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--accent-indigo-hover);
}

/* Sidebar Navigation */
.sidebar, .sidebar-content {
    background: var(--bg-sidebar) !important;
    border-right: 1px solid var(--border-color) !important;
    box-shadow: 6px 0 30px rgba(0, 0, 0, 0.4) !important;
}

.sidebar-user {
    border-bottom: 1px solid var(--border-color) !important;
    background: rgba(10, 13, 24, 0.5) !important;
    padding: 1.5rem !important;
    text-align: center;
}

.sidebar-user img {
    max-height: 50px !important;
    width: auto !important;
    object-fit: contain !important;
    filter: drop-shadow(0 0 12px rgba(99, 102, 241, 0.35)) !important;
    transition: var(--transition);
}

.sidebar-user img:hover {
    transform: scale(1.05);
}

.sidebar-header {
    background: transparent !important;
    color: var(--text-highlight) !important;
    font-family: 'Montserrat', sans-serif !important;
    font-size: 0.75rem !important;
    text-transform: uppercase !important;
    letter-spacing: 2.5px !important;
    padding: 1.5rem 1.5rem .5rem !important;
    font-weight: 700 !important;
    opacity: 0.8;
}

/* Sidebar Links */
.sidebar-link, a.sidebar-link {
    background: transparent !important;
    color: var(--text-muted) !important;
    transition: var(--transition) !important;
    border-left: 4px solid transparent !important;
    font-weight: 500 !important;
    padding: 0.75rem 1.5rem !important;
}

.sidebar-link i, a.sidebar-link i {
    color: var(--accent-indigo) !important;
    opacity: 0.7;
    transition: var(--transition) !important;
}

/* Hover State */
.sidebar-link:hover, .sidebar-item:hover > .sidebar-link {
    color: var(--text-primary) !important;
    background: rgba(99, 102, 241, 0.05) !important;
    border-left: 4px solid rgba(99, 102, 241, 0.5) !important;
}

.sidebar-link:hover i, .sidebar-item:hover > .sidebar-link i {
    color: var(--text-primary) !important;
    opacity: 1;
    transform: scale(1.1) translateX(2px) !important;
}

/* Active Menu Item State */
.sidebar-item.active {
    border-left: 0 !important;
}

.sidebar-item.active > .sidebar-link, .sidebar-item.active > a.sidebar-link {
    color: var(--text-primary) !important;
    background: rgba(99, 102, 241, 0.12) !important;
    border-left: 4px solid var(--accent-indigo) !important;
    font-weight: 600 !important;
    box-shadow: inset 5px 0 15px rgba(99, 102, 241, 0.05) !important;
}

.sidebar-item.active > .sidebar-link i, .sidebar-item.active > a.sidebar-link i {
    color: var(--text-primary) !important;
    opacity: 1;
}

/* Dropdown Menu Item Styling */
.sidebar-dropdown .sidebar-link {
    padding-left: 3.5rem !important;
    border-left: none !important;
}
.sidebar-dropdown .sidebar-item.active .sidebar-link {
    border-left: none !important;
    background: transparent !important;
    color: var(--text-primary) !important;
}

/* Top Navigation Header */
.navbar-theme, .navbar {
    background: rgba(10, 13, 24, 0.8) !important;
    backdrop-filter: blur(12px) !important;
    border-bottom: 1px solid var(--border-color) !important;
}

.navbar-theme .hamburger, .navbar .hamburger {
    background: var(--text-primary) !important;
}

.navbar-theme .hamburger:before, .navbar-theme .hamburger:after,
.navbar .hamburger:before, .navbar .hamburger:after {
    background: var(--text-primary) !important;
}

.navbar-theme .nav-link i, .navbar .nav-link i {
    color: var(--text-muted) !important;
    transition: var(--transition);
}

.navbar-theme .nav-link i:hover, .navbar .nav-link i:hover {
    color: var(--text-primary) !important;
}

.navbar-theme .dropdown-menu, .navbar .dropdown-menu {
    background-color: var(--bg-sidebar) !important;
    border: 1px solid var(--border-color) !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5) !important;
    border-radius: 8px !important;
}

.navbar-theme .dropdown-item, .navbar .dropdown-item {
    color: var(--text-muted) !important;
    padding: 0.6rem 1.2rem !important;
    transition: var(--transition);
}

.navbar-theme .dropdown-item:hover, .navbar .dropdown-item:hover {
    background-color: rgba(99, 102, 241, 0.1) !important;
    color: var(--text-primary) !important;
}

/* Card Design System (Glassmorphic, Modern, Premium) */
.card {
    background: var(--bg-card) !important;
    backdrop-filter: blur(16px) !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-primary) !important;
    border-radius: 12px !important;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3) !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease !important;
}

.card:hover {
    transform: translateY(-4px);
    border-color: rgba(99, 102, 241, 0.35) !important;
    box-shadow: 0 12px 40px rgba(99, 102, 241, 0.12) !important;
}

.card-title, .card .card-header, .card-header {
    background: transparent !important;
    color: var(--text-primary) !important;
    font-family: 'Montserrat', sans-serif !important;
    font-weight: 600 !important;
    letter-spacing: 0.5px !important;
    border-bottom: 1px solid var(--border-color) !important;
    padding: 1.25rem 1.5rem !important;
}

.card-body {
    color: var(--text-muted) !important;
    padding: 1.5rem !important;
}

/* Dashboard Statistic Headings and Text Details */
.card-body h1.display-6 {
    font-family: 'Montserrat', sans-serif !important;
    font-weight: 700 !important;
    color: var(--text-primary) !important;
    letter-spacing: -0.5px;
    margin-top: 0.5rem;
}

/* Custom cards border rounded helpers */
.b1rem {
    border-radius: 12px !important;
}

/* Page Headers */
.header-title, .page-title, h1:not(.logo-text), h2:not(.logo-text) {
    color: var(--text-primary) !important;
    font-family: 'Montserrat', sans-serif !important;
    font-weight: 700 !important;
    letter-spacing: -0.5px;
}

/* Button UI (Modern Glassy Gradients & Shadows) */
.btn {
    border-radius: 8px !important;
    transition: var(--transition) !important;
    font-weight: 600 !important;
    letter-spacing: 0.5px;
}

.btn-primary, .btn-info {
    background: linear-gradient(135deg, var(--accent-indigo) 0%, #4338ca 100%) !important;
    border: none !important;
    color: #ffffff !important;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3) !important;
}
.btn-primary:hover, .btn-info:hover {
    background: linear-gradient(135deg, #4f46e5 0%, #3730a3 100%) !important;
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5) !important;
    transform: translateY(-2px) !important;
}

.btn-success {
    background: linear-gradient(135deg, var(--accent-emerald) 0%, #047857 100%) !important;
    border: none !important;
    color: #ffffff !important;
    box-shadow: 0 4px 14px rgba(16, 115, 81, 0.3) !important;
}
.btn-success:hover {
    background: linear-gradient(135deg, #059669 0%, #065f46 100%) !important;
    box-shadow: 0 6px 20px rgba(16, 115, 81, 0.5) !important;
    transform: translateY(-2px) !important;
}

.btn-danger {
    background: linear-gradient(135deg, var(--accent-rose) 0%, #be123c 100%) !important;
    border: none !important;
    color: #ffffff !important;
    box-shadow: 0 4px 14px rgba(239, 68, 68, 0.3) !important;
}
.btn-danger:hover {
    background: linear-gradient(135deg, #dc2626 0%, #9f1239 100%) !important;
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.5) !important;
    transform: translateY(-2px) !important;
}

.btn-warning {
    background: linear-gradient(135deg, var(--accent-amber) 0%, #b45309 100%) !important;
    border: none !important;
    color: #ffffff !important;
    box-shadow: 0 4px 14px rgba(245, 158, 11, 0.3) !important;
}
.btn-warning:hover {
    background: linear-gradient(135deg, #d97706 0%, #78350f 100%) !important;
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.5) !important;
    transform: translateY(-2px) !important;
}

.btn-secondary {
    background-color: rgba(255, 255, 255, 0.08) !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-primary) !important;
}
.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.15) !important;
    transform: translateY(-1px) !important;
}


/* Form Styling */
.form-control, .form-select {
    background-color: rgba(8, 11, 17, 0.85) !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-primary) !important;
    border-radius: 8px !important;
    padding: 0.75rem 1rem !important;
    transition: var(--transition) !important;
}
.form-control:focus, .form-select:focus {
    border-color: var(--accent-indigo) !important;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.25) !important;
    background-color: rgba(15, 22, 40, 0.95) !important;
}
.form-control::placeholder {
    color: #4b5563 !important;
}

/* Modern Badge Design */
.badge {
    padding: 0.5em 0.85em !important;
    font-weight: 600 !important;
    border-radius: 6px !important;
    font-size: 0.75rem !important;
}
.bg-success, .badge-success {
    background-color: rgba(16, 185, 129, 0.15) !important;
    border: 1px solid var(--accent-emerald) !important;
    color: var(--accent-emerald) !important;
}
.bg-danger, .badge-danger {
    background-color: rgba(239, 68, 68, 0.15) !important;
    border: 1px solid var(--accent-rose) !important;
    color: var(--accent-rose) !important;
}
.bg-warning, .badge-warning {
    background-color: rgba(245, 158, 11, 0.15) !important;
    border: 1px solid var(--accent-amber) !important;
    color: var(--accent-amber) !important;
}
.bg-primary, .badge-primary {
    background-color: rgba(99, 102, 241, 0.15) !important;
    border: 1px solid var(--accent-indigo) !important;
    color: var(--text-highlight) !important;
}
.text-primary {
    color: var(--accent-indigo) !important;
}

/* Footer Styling */
.footer {
    background: var(--bg-sidebar) !important;
    border-top: 1px solid var(--border-color) !important;
    padding: 1.5rem 0 !important;
}
.footer a {
    color: var(--text-muted) !important;
    text-decoration: none;
    transition: var(--transition);
}
.footer a:hover {
    color: var(--text-primary) !important;
}
.text-muted, .text-black {
    color: var(--text-muted) !important;
}

/* Auth Area Custom Styling */
.auth-color {
    background: linear-gradient(135deg, var(--accent-indigo) 0%, #4338ca 100%) !important;
    color: #ffffff !important;
    border: none !important;
}
.auth-color:hover {
    background: linear-gradient(135deg, #4f46e5 0%, #3730a3 100%) !important;
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5) !important;
}

/* Replace amateur purple color classes if any exist in DOM */
.card-footer[style*="background-color:#731aa5"],
.card-footer[style*="background-color: #731aa5"],
div[style*="background-color:#731aa5"],
div[style*="background-color: #731aa5"] {
    background: linear-gradient(135deg, var(--accent-indigo) 0%, #4338ca 100%) !important;
    background-color: transparent !important;
    color: #ffffff !important;
    border-radius: 0 0 12px 12px !important;
    border: none !important;
}

.card-footer[style*="background-color:#731aa5"] a,
.card-footer[style*="background-color: #731aa5"] a,
div[style*="background-color:#731aa5"] a,
div[style*="background-color: #731aa5"] a {
    color: #ffffff !important;
    font-weight: 600 !important;
}

.bg-white.border.rounded.px-2.py-1 {
    background-color: rgba(15, 22, 40, 0.6) !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-primary) !important;
}

/* Connect Wallet & Web3 Buttons Styles Override */
#web3LoginBtn, #connectWalletRegister {
    background: linear-gradient(135deg, var(--accent-indigo) 0%, #4338ca 100%) !important;
    color: #ffffff !important;
    border: none !important;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.35) !important;
    transition: var(--transition) !important;
}

#web3LoginBtn:hover, #connectWalletRegister:hover {
    background: linear-gradient(135deg, #4f46e5 0%, #3730a3 100%) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5) !important;
}

/* Gold Text Dynamic Overrides */
span[style*="color:#dfba6b"], span[style*="color: #dfba6b"],
span[style*="color:#bfa15f"], span[style*="color: #bfa15f"] {
    color: var(--accent-indigo) !important;
    background: linear-gradient(135deg, #a5b4fc 0%, var(--accent-indigo) 100%) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
}

/* Text Center Cards Layout Centering */
.card.text-center .card-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* Profile Info List inside Dashboard Profile Card */
.profile-info-list {
    width: 100%;
    margin-top: 1.25rem;
    margin-bottom: 1.25rem;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-color);
    padding: 0.5rem 1.25rem;
}

.profile-info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.85rem 0;
    border-bottom: 1px dashed rgba(223, 186, 107, 0.15);
}

.profile-info-item:last-child {
    border-bottom: none;
}

.profile-info-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.profile-info-label i {
    color: var(--accent-indigo);
    font-size: 0.85rem;
    width: 18px;
    text-align: center;
}

.profile-info-value {
    font-size: 0.85rem;
    color: var(--text-primary);
    font-weight: 600;
    text-align: right;
    max-width: 60%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Profile Header Card Layout Overhaul */
.profile-header-card {
    background: rgba(20, 22, 28, 0.85) !important;
    border: 1px solid var(--border-color) !important;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37) !important;
    backdrop-filter: blur(10px) !important;
    -webkit-backdrop-filter: blur(10px) !important;
}

@media (min-width: 992px) {
    .border-lg-end {
        border-right: 1px solid rgba(223, 186, 107, 0.15) !important;
    }
    .border-lg-start {
        border-left: 1px solid rgba(223, 186, 107, 0.15) !important;
    }
}

.avatar-sm {
    transition: var(--transition);
}

.avatar-sm:hover {
    transform: scale(1.08);
}

