/* 
    VaultFlow Design System
    Focus: Modern Glassmorphism & High-Contrast Typography
    Font: Plus Jakarta Sans
*/

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;600;700;800&display=swap');

:root {
    /* Color Palette */
    --bg: #F4F7FE;
    --sidebar: #111C44;
    --sidebar-hover: rgba(255, 255, 255, 0.05);
    --primary: #4318FF;
    --primary-light: rgba(67, 24, 255, 0.1);
    --text: #1B2559;
    --muted: #A3AED0;
    --white: #FFFFFF;
    
    /* Transaction Colors */
    --green: #05CD99;
    --red: #EE5D50;
    --amber: #FFB547;
    
    /* Shadows */
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

* {
    box-sizing: border-box;
    transition: all 0.2s ease-in-out;
}

body {
    font-family: 'Plus Jakarta Sans', sans-serif;
    margin: 0;
    background-color: var(--bg);
    color: var(--text);
}

/* Layout Wrapper */
.app-wrapper {
    display: flex;
    min-height: 100vh;
}

/* --- Sidebar Navigation --- */
.sidebar {
    width: 280px;
    background: var(--sidebar);
    color: var(--white);
    padding: 40px 25px;
    position: fixed;
    height: 100vh;
}

.logo {
    font-size: 26px;
    font-weight: 800;
    margin-bottom: 50px;
    text-align: center;
    letter-spacing: -1px;
}

.logo span {
    color: var(--primary);
}

nav a {
    display: flex;
    align-items: center;
    color: var(--muted);
    text-decoration: none;
    margin-bottom: 10px;
    font-weight: 600;
    padding: 12px 20px;
    border-radius: 15px;
    font-size: 15px;
}

nav a.active {
    background: var(--primary-light);
    color: var(--white);
}

nav a:hover:not(.active) {
    background: var(--sidebar-hover);
    color: var(--white);
}

/* --- Main Content Area --- */
.main-content {
    flex: 1;
    margin-left: 280px; /* Offset for fixed sidebar */
    padding: 40px 50px;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 35px;
}

header h1 {
    font-weight: 700;
    font-size: 28px;
    margin: 0;
    letter-spacing: -0.5px;
}

/* --- Stats Grid --- */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    margin-bottom: 40px;
}

.stat-card {
    background: var(--white);
    padding: 25px;
    border-radius: 20px;
    box-shadow: var(--shadow);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.stat-card span {
    font-size: 14px;
    font-weight: 600;
    color: var(--muted);
    display: block;
    margin-bottom: 8px;
}

.stat-card h2 {
    margin: 0;
    font-size: 24px;
    font-weight: 800;
}

/* --- Data Table --- */
.data-card {
    background: var(--white);
    padding: 30px;
    border-radius: 25px;
    box-shadow: var(--shadow);
}

table {
    width: 100%;
    border-collapse: collapse;
}

th {
    text-align: left;
    padding: 15px;
    color: var(--muted);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 1px solid #F4F7FE;
}

td {
    padding: 18px 15px;
    border-bottom: 1px solid #F4F7FE;
    font-size: 14px;
    font-weight: 600;
}

/* Badges */
.badge {
    padding: 6px 12px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.badge-cashin { background: #E6FFF5; color: var(--green); }
.badge-cashout { background: #FFEFEF; color: var(--red); }
.badge-agentcommission { background: #FFF8E6; color: var(--amber); }

/* --- Forms & Inputs --- */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 13px;
    font-weight: 700;
    color: var(--text);
}

input, select {
    padding: 12px 16px;
    border: 1px solid #E0E5F2;
    border-radius: 12px;
    font-family: inherit;
    font-size: 14px;
    color: var(--text);
    outline: none;
}

input:focus {
    border-color: var(--primary);
}

.readonly {
    background: #F4F7FE;
    color: var(--muted);
    cursor: not-allowed;
}

/* --- Buttons --- */
.btn-primary {
    background: var(--primary);
    color: var(--white);
    border: none;
    padding: 14px 24px;
    border-radius: 16px;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    box-shadow: 0 4px 14px 0 rgba(67, 24, 255, 0.39);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(67, 24, 255, 0.23);
}

.btn-secondary {
    background: #F4F7FE;
    color: var(--primary);
    border: none;
    padding: 14px 24px;
    border-radius: 16px;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
}

.btn-secondary:hover {
    background: #E0E5F2;
}

/* --- Pagination --- */
.btn-page {
    padding: 8px 16px;
    border-radius: 10px;
    text-decoration: none;
    background: #F4F7FE;
    color: var(--text);
    font-weight: 700;
    margin: 0 4px;
    font-size: 13px;
}

.btn-page.active {
    background: var(--primary);
    color: var(--white);
}

/* --- Modal System --- */
.modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(17, 28, 68, 0.4);
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
}

.modal-box {
    background: var(--white);
    padding: 40px;
    border-radius: 30px;
    width: 100%;
    max-width: 550px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.modal-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 25px 0;
}

/* --- Alerts (Profile Success/Error) --- */
.alert {
    padding: 15px 20px;
    border-radius: 15px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 25px;
}

.alert-success { background: #E6FFF5; color: var(--green); }
.alert-error { background: #FFEFEF; color: var(--red); }

/* --- Mobile Responsiveness --- */
@media (max-width: 1024px) {
    .stats-grid { grid-template-columns: 1fr; }
    .sidebar { width: 80px; padding: 40px 10px; }
    .logo, nav a span { display: none; }
    .main-content { margin-left: 80px; }
    .modal-grid { grid-template-columns: 1fr; }
}