/* Dashboard Custom Theme */
:root {
    --ds-surface: #0f172a;
    --ds-surface-alt: #111c44;
    --ds-primary: #2563eb;
    --ds-secondary: #7c3aed;
    --ds-success: #10b981;
    --ds-warning: #f59e0b;
    --ds-danger: #ef4444;
    --ds-muted: #94a3b8;
    --ds-border: rgba(255, 255, 255, 0.08);
}

body {
    background-color: #0a1121;
}

.preloader {
    background: radial-gradient(circle at top, rgba(37, 99, 235, 0.35), transparent 55%),
        radial-gradient(circle at 80% 20%, rgba(124, 58, 237, 0.25), transparent 45%),
        #050914 !important;
    color: #f8fafc;
    position: fixed;
    inset: 0;
    z-index: 9999;
    overflow: hidden;
}

.preloader img {
    filter: drop-shadow(0 12px 25px rgba(37, 99, 235, 0.35));
}

.preloader::before,
.preloader::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    background: rgba(37, 99, 235, 0.15);
    filter: blur(60px);
    animation: loaderFloat 6s ease-in-out infinite;
}

.preloader::before {
    width: 320px;
    height: 320px;
    top: -80px;
    right: 15%;
}

.preloader::after {
    width: 260px;
    height: 260px;
    bottom: -60px;
    left: 12%;
    animation-delay: 1.5s;
}

.loader-shell {
    position: relative;
    width: 190px;
    height: 190px;
    border-radius: 32px;
    background: linear-gradient(160deg, rgba(37, 99, 235, 0.25), rgba(124, 58, 237, 0.4));
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 20px 60px rgba(2, 6, 23, 0.65);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    backdrop-filter: blur(12px);
}

.loader-shell::before,
.loader-shell::after {
    content: "";
    position: absolute;
    inset: 14px;
    border-radius: 24px;
    border: 1px dashed rgba(255, 255, 255, 0.2);
    animation: loaderPulse 2.4s ease-in-out infinite;
}

.loader-shell::after {
    inset: 6px;
    border: 1px solid rgba(59, 130, 246, 0.3);
    animation-delay: 0.8s;
}

.loader-ring {
    position: absolute;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    border: 2px solid transparent;
    border-top-color: rgba(59, 130, 246, 0.9);
    border-right-color: rgba(129, 140, 248, 0.7);
    animation: loaderRotate 1.8s linear infinite;
}

.loader-logo {
    width: 120px;
    filter: drop-shadow(0 10px 35px rgba(15, 23, 42, 0.55));
}

.loader-text {
    font-size: 0.95rem;
    letter-spacing: 0.1rem;
    text-transform: uppercase;
    color: rgba(226, 232, 240, 0.85);
    margin: 0;
}

@keyframes loaderRotate {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

@keyframes loaderPulse {
    0% {
        opacity: 0.2;
        transform: scale(0.92);
    }
    50% {
        opacity: 0.7;
        transform: scale(1);
    }
    100% {
        opacity: 0.2;
        transform: scale(0.92);
    }
}

@keyframes loaderFloat {
    0% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-25px);
    }
    100% {
        transform: translateY(0px);
    }
}

.content-wrapper {
    background: radial-gradient(circle at top, rgba(37, 99, 235, 0.15), transparent 45%),
        radial-gradient(circle at 20% 20%, rgba(124, 58, 237, 0.15), transparent 35%),
        #0b1325;
}

.content-header {
    border-bottom: none;
}

.content-header h1 {
    color: #f8fafc;
    font-weight: 700;
}

.dashboard-hero {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.9), rgba(124, 58, 237, 0.9));
    border-radius: 24px;
    padding: 32px;
    color: white;
    box-shadow: 0 20px 50px rgba(21, 19, 61, 0.6);
    position: relative;
    overflow: hidden;
}

.dashboard-hero::after {
    content: "";
    position: absolute;
    right: -60px;
    top: -60px;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
}

.dashboard-hero small {
    text-transform: uppercase;
    letter-spacing: 4px;
    color: rgba(255, 255, 255, 0.75);
}

.dashboard-hero h2 {
    font-size: 2rem;
    font-weight: 700;
    margin: 12px 0 18px;
}

.dashboard-hero .hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(15, 23, 42, 0.25);
    border-radius: 999px;
    padding: 8px 18px;
    font-size: 0.85rem;
}

.stat-card {
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid var(--ds-border);
    border-radius: 18px;
    padding: 20px;
    color: #e2e8f0;
    box-shadow: 0 12px 30px rgba(2, 6, 23, 0.5);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.6);
}

.stat-card .label {
    font-size: 0.85rem;
    color: var(--ds-muted);
    letter-spacing: 0.4px;
    text-transform: uppercase;
}

.stat-card .value {
    font-size: 1.65rem;
    font-weight: 700;
    margin: 8px 0;
}

.stat-card .trend {
    font-size: 0.9rem;
}

.card.dashboard-panel {
    background: rgba(15, 23, 42, 0.9);
    border-radius: 20px;
    border: 1px solid var(--ds-border);
    color: #e2e8f0;
    box-shadow: 0 20px 60px rgba(2, 6, 23, 0.45);
}

.card.dashboard-panel .card-header {
    border: none;
    background: transparent;
    padding-bottom: 0;
}

.card.dashboard-panel .card-title {
    font-weight: 600;
    color: #f8fafc;
}

.chart-container {
    min-height: 320px;
}

.table-modern {
    background: rgba(15, 23, 42, 0.8);
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid var(--ds-border);
}

.table-modern table {
    margin-bottom: 0;
    color: #e2e8f0;
}

.table-modern thead {
    background: rgba(37, 99, 235, 0.15);
}

.table-modern th,
.table-modern td {
    border-color: rgba(148, 163, 184, 0.1) !important;
}

.badge-soft {
    padding: 0.4rem 0.85rem;
    border-radius: 999px;
    font-size: 0.85rem;
}

.badge-soft.success {
    background: rgba(34, 197, 94, 0.15);
    color: #4ade80;
}

.badge-soft.warning {
    background: rgba(234, 179, 8, 0.15);
    color: #facc15;
}

.badge-soft.danger {
    background: rgba(248, 113, 113, 0.15);
    color: #f87171;
}

.card-user-info {
    background: rgba(15, 23, 42, 0.85);
    border-radius: 20px;
    border: 1px solid var(--ds-border);
    color: #e2e8f0;
    box-shadow: 0 20px 60px rgba(2, 6, 23, 0.45);
    overflow: hidden;
}

.card-user-info .card-header {
    border: none;
    background: linear-gradient(120deg, rgba(16, 185, 129, 0.3), rgba(59, 130, 246, 0.45));
    color: #f8fafc;
}

.card-user-info .table {
    color: #e2e8f0;
}

.card-user-info .table td,
.card-user-info .table th {
    border-color: rgba(148, 163, 184, 0.15);
}

.transfer-box {
    background: rgba(37, 99, 235, 0.15);
    border-radius: 18px;
    padding: 24px;
    border: 1px dashed rgba(255, 255, 255, 0.1);
}

.transfer-box button {
    border-radius: 999px;
}

.action-btn-group .btn {
    border-radius: 999px;
    font-weight: 600;
    letter-spacing: 0.5px;
}

@media (max-width: 768px) {
    .dashboard-hero {
        padding: 24px;
    }
    .dashboard-hero h2 {
        font-size: 1.5rem;
    }
}

/* ---------------------------------------
   NAVBAR & SIDEBAR STYLING
--------------------------------------- */

.main-header.navbar {
    background: linear-gradient(90deg, #0f172a 0%, #111c44 35%, #1d4ed8 100%);
    border: none;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.45);
    padding: 0.35rem 1.5rem;
}

.main-header .navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.85);
    border-radius: 999px;
    transition: all 0.3s ease;
}

.main-header .navbar-nav .nav-link:hover {
    color: #f8fafc;
    background: rgba(255, 255, 255, 0.12);
}

.navbar-brand-badge {
    color: #e2e8f0;
    font-weight: 600;
    letter-spacing: 0.5px;
    background: rgba(15, 23, 42, 0.35);
    border-radius: 999px;
    padding: 0.25rem 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-left: 1rem;
}

.dropdown-menu.profile-dropdown {
    border-radius: 18px;
    border: 1px solid rgba(15, 23, 42, 0.05);
    box-shadow: 0 20px 45px rgba(15, 23, 42, 0.25);
    padding: 0.5rem 0.75rem 1rem;
}

.profile-dropdown .dropdown-header {
    font-weight: 600;
    color: #0f172a;
}

.main-sidebar.sidebar-red {
    background: linear-gradient(180deg, #0f172a 0%, #0b1325 100%);
    box-shadow: 10px 0 30px rgba(2, 6, 23, 0.6);
}

.main-sidebar .brand-link {
    background: rgba(15, 23, 42, 0.65);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.main-sidebar .user-panel {
    background: rgba(15, 23, 42, 0.35);
    border-radius: 14px;
    padding: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.nav-sidebar .nav-link {
    color: rgba(226, 232, 240, 0.8);
    border-radius: 10px;
    margin: 0.25rem 0.35rem;
    transition: all 0.3s ease;
}

.nav-sidebar .nav-link.active,
.nav-sidebar .nav-link:hover {
    background: linear-gradient(90deg, rgba(37, 99, 235, 0.35), rgba(59, 130, 246, 0.25));
    color: #f8fafc;
    box-shadow: inset 2px 0 0 #60a5fa;
    transform: translateX(3px);
}

.nav-sidebar .nav-header {
    color: #94a3b8;
    font-size: 0.8rem;
    letter-spacing: 0.35rem;
    text-transform: uppercase;
    margin: 1rem 0 0.25rem 0.75rem;
}

/* ---------------------------------------
   FOOTER
--------------------------------------- */

.dashboard-footer {
    background: rgba(15, 23, 42, 0.95);
    border-top: 1px solid var(--ds-border);
    color: #cbd5f5;
    padding: 0.85rem 1.75rem;
    box-shadow: 0 -12px 35px rgba(2, 6, 23, 0.45);
}

.dashboard-footer .footer-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.dashboard-footer .footer-title {
    font-weight: 600;
    letter-spacing: 0.08rem;
    text-transform: uppercase;
    display: block;
    margin-bottom: 0.15rem;
}

.dashboard-footer .footer-links {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.dashboard-footer .footer-pill {
    background: rgba(37, 99, 235, 0.15);
    border-radius: 999px;
    padding: 0.3rem 0.85rem;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05rem;
    color: #93c5fd;
}

.dashboard-footer .footer-link {
    color: #f8fafc;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    padding: 0.4rem 0.9rem;
    border-radius: 999px;
    background: linear-gradient(120deg, rgba(37, 99, 235, 0.7), rgba(124, 58, 237, 0.7));
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.45);
    transition: all 0.3s ease;
}

.dashboard-footer .footer-link:hover {
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 15px 30px rgba(15, 23, 42, 0.6);
}

@media (max-width: 576px) {
    .dashboard-footer .footer-content {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* ---------------------------------------
   AUTH PAGES CUSTOMIZATION
--------------------------------------- */

.login-page {
    background: radial-gradient(circle at top, rgba(37, 99, 235, 0.35), transparent 55%),
        rgba(2, 6, 23, 0.95);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
}

.login-box {
    width: 100%;
    max-width: 380px;
}

.card-login-modern {
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 24px;
    box-shadow: 0 30px 80px rgba(2, 6, 23, 0.8);
    backdrop-filter: blur(12px);
    color: #e2e8f0;
}

.card-login-modern .card-header {
    border-bottom: none;
    background: transparent;
}

.login-branding {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
}

.login-branding span {
    letter-spacing: 0.3rem;
    text-transform: uppercase;
    font-size: 0.85rem;
    color: rgba(226, 232, 240, 0.85);
}

.login-box-msg {
    color: rgba(226, 232, 240, 0.75);
    letter-spacing: 0.2px;
}

.card-login-modern .form-control {
    background: rgba(15, 23, 42, 0.65);
    border: 1px solid rgba(148, 163, 184, 0.25);
    color: #f8fafc;
    border-radius: 12px;
    padding: 0.75rem 1.25rem;
}

.card-login-modern .form-control:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.25);
}

.login-input-group .input-group-text {
    background: transparent;
    border: none;
    color: #94a3b8;
}

.btn-gradient-primary {
    background: linear-gradient(120deg, #2563eb, #7c3aed);
    border: none;
    border-radius: 999px;
    color: #fff;
    font-weight: 600;
    letter-spacing: 0.5px;
    padding: 0.65rem 1.25rem;
    transition: all 0.3s ease;
    width: 100%;
}

.btn-gradient-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(37, 99, 235, 0.4);
}

.login-shell {
    width: 100%;
    max-width: 920px;
    display: grid;
    gap: 1.75rem;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    align-items: stretch;
}

.login-hero-panel {
    background: linear-gradient(160deg, rgba(37, 99, 235, 0.95), rgba(124, 58, 237, 0.9));
    border-radius: 24px;
    padding: 2.5rem;
    box-shadow: 0 25px 60px rgba(15, 23, 42, 0.7);
    color: #f8fafc;
    position: relative;
    overflow: hidden;
}

.login-hero-panel::after {
    content: "";
    position: absolute;
    inset: 30px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 22px;
    pointer-events: none;
}

.login-hero-panel h2 {
    font-weight: 700;
    font-size: 1.95rem;
    margin-bottom: 0.9rem;
}

.login-hero-panel p {
    color: rgba(248, 250, 252, 0.85);
    margin-bottom: 1.25rem;
}

.login-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.35rem 0.95rem;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.35);
    font-size: 0.8rem;
    letter-spacing: 0.15rem;
    text-transform: uppercase;
}

.login-feature-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.login-feature-list li {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 0.5rem;
    color: rgba(248, 250, 252, 0.9);
}

.login-feature-list .icon {
    width: 28px;
    height: 28px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.35);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
}

.form-separator {
    text-align: center;
    margin: 1.25rem 0;
    color: rgba(226, 232, 240, 0.6);
    position: relative;
    font-size: 0.85rem;
    letter-spacing: 0.08rem;
}

.form-separator::before,
.form-separator::after {
    content: "";
    position: absolute;
    top: 50%;
    width: 30%;
    height: 1px;
    background: rgba(148, 163, 184, 0.3);
}

.form-separator::before {
    left: 0;
}

.form-separator::after {
    right: 0;
}

.auth-links a {
    color: #93c5fd;
    transition: color 0.2s ease;
}

.auth-links a:hover {
    color: #bfdbfe;
}
