/* =============================================
   BITRUNEX ADMIN PANEL — CORE CSS
   ============================================= */

:root {
    --bg-dark: #0f111a;
    --bg-panel: rgba(25, 28, 41, 0.6);
    --primary: #00F0FF;
    --primary-glow: rgba(0, 240, 255, 0.4);
    --secondary: #7B2CBF;
    --text-main: #FFFFFF;
    --text-muted: #8c93a1;
    --border: rgba(255, 255, 255, 0.08);
    --success: #00E676;
    --danger: #FF1744;
    --warning: #FFC400;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Glassmorphism */
.glass-panel {
    background: var(--bg-panel);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    border-radius: 16px;
}

/* Buttons */
.btn {
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 14px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
}

.btn-primary:hover {
    box-shadow: 0 0 15px var(--primary-glow);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-main);
}

.btn-outline:hover {
    background: rgba(255,255,255,0.05);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

/* Typography & Utils */
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.mt-2 { margin-top: 10px; }

/* ── LOGIN SCREEN ── */
.login-container {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 10;
}

.login-box {
    padding: 40px;
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.logo-icon {
    font-size: 48px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 10px;
}

.login-box h2 {
    font-size: 24px;
    letter-spacing: 2px;
    margin-bottom: 5px;
}

.login-box p {
    color: var(--text-muted);
    font-size: 14px;
    margin-bottom: 30px;
}

.btn-large {
    width: 100%;
    padding: 15px;
    font-size: 16px;
}

.login-note {
    margin-top: 20px;
    font-size: 12px;
    opacity: 0.6;
}

.error-msg {
    color: var(--danger);
    background: rgba(255, 23, 68, 0.1);
    padding: 10px;
    border-radius: 8px;
    margin-top: 15px;
    font-size: 13px;
    display: none;
}

/* ── DASHBOARD LAYOUT ── */
.dashboard-container {
    display: flex;
    height: 100vh;
}

.sidebar {
    width: 250px;
    display: flex;
    flex-direction: column;
    border-right: 1px solid var(--border);
    border-radius: 0;
}

.sidebar-logo {
    padding: 20px;
    font-size: 20px;
    font-weight: 800;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid var(--border);
}

.sidebar-logo i { color: var(--primary); }

.wallet-info {
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid var(--border);
}

.wallet-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    display: flex;
    align-items: center;
    justify-content: center;
}

.wallet-address {
    font-size: 14px;
    font-weight: 600;
}

.sidebar-nav {
    padding: 20px 10px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    flex: 1;
}

.nav-item {
    padding: 12px 15px;
    color: var(--text-muted);
    text-decoration: none;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.2s;
    font-weight: 500;
}

.nav-item:hover, .nav-item.active {
    color: var(--text-main);
    background: rgba(255,255,255,0.05);
}

.nav-item.active {
    border-left: 3px solid var(--primary);
    background: linear-gradient(90deg, rgba(0,240,255,0.1) 0%, transparent 100%);
}

.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.top-header {
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border);
    background: rgba(15, 17, 26, 0.8);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 10;
}

.status-indicator {
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.05);
    padding: 6px 12px;
    border-radius: 20px;
}

.sections {
    padding: 30px;
}

.content-section {
    display: none;
    animation: fadeIn 0.4s ease;
}

.content-section.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ── STATS GRID ── */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: rgba(0, 240, 255, 0.1);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.stat-info h3 {
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 500;
}

.stat-value {
    font-size: 24px;
    font-weight: 700;
    margin-top: 5px;
}

/* ── TABLES ── */
.table-container {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th, .data-table td {
    padding: 15px 20px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.data-table th {
    color: var(--text-muted);
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
}

.data-table tbody tr:hover {
    background: rgba(255,255,255,0.02);
}

.badge {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}
.badge-active { background: rgba(0,230,118,0.1); color: var(--success); }
.badge-inactive { background: rgba(255,23,68,0.1); color: var(--danger); }

/* ── MODALS ── */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(5px);
    z-index: 100;
    display: none;
    align-items: center;
    justify-content: center;
}

.modal-overlay.active { display: flex; }

.modal {
    width: 90%;
    max-width: 500px;
    padding: 25px;
    display: none;
}

.modal.active {
    display: block;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 200;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.btn-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 20px;
    cursor: pointer;
}

.form-group {
    margin-bottom: 15px;
}

.form-row {
    display: flex;
    gap: 15px;
}

.form-row .form-group {
    flex: 1;
}

label {
    display: block;
    margin-bottom: 8px;
    font-size: 13px;
    color: var(--text-muted);
}

input, select {
    width: 100%;
    padding: 12px;
    background: rgba(0,0,0,0.2);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: white;
    font-family: 'Outfit', sans-serif;
}

input:focus, select:focus {
    outline: none;
    border-color: var(--primary);
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 25px;
}

/* ── TOASTS ── */
#toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background: rgba(15, 17, 26, 0.9);
    border-left: 4px solid var(--primary);
    padding: 15px 20px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}
