/* ============================================
   CSS RESET & BASE STYLES - MOBILE FIRST
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

:root {
    --primary: #7c3aed;
    --primary-dark: #5b21b6;
    --primary-light: #a78bfa;
    --secondary: #06b6d4;
    --accent: #f59e0b;
    --success: #10b981;
    --danger: #ef4444;
    --bg-dark: #0a0c10;
    --bg-card: #111827;
    --bg-card-hover: #1e293b;
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --border-color: #1f2937;
    --border-light: #334155;
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    --shadow-glow: 0 0 40px rgba(124, 58, 237, 0.15);
    --radius: 16px;
    --radius-sm: 10px;
    --radius-xs: 8px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --safe-bottom: env(safe-area-inset-bottom, 0px);
}

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    overflow-x: hidden;
    min-height: 100vh;
    min-height: 100dvh;
    padding-bottom: calc(80px + var(--safe-bottom));
}

/* ============================================
   LOADING SCREEN
   ============================================ */
#loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-dark);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    flex-direction: column;
    gap: 20px;
    transition: opacity 0.5s ease;
}

#loading.hidden {
    opacity: 0;
    pointer-events: none;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 3px solid var(--border-color);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.spinner-text {
    color: var(--text-secondary);
    font-size: 13px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ============================================
   SCROLLBAR
   ============================================ */
::-webkit-scrollbar {
    width: 4px;
    height: 4px;
}
::-webkit-scrollbar-track { background: var(--bg-dark); }
::-webkit-scrollbar-thumb { background: var(--border-light); border-radius: 10px; }

/* ============================================
   SIDEBAR - MOBILE OPTIMIZED
   ============================================ */
.sidebar {
    position: fixed;
    top: 0;
    left: -100%;
    width: 85%;
    max-width: 320px;
    height: 100%;
    background: rgba(17, 24, 39, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 1000;
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 16px;
    overflow-y: auto;
    border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.sidebar.open {
    left: 0;
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.sidebar-logo {
    font-size: 22px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sidebar-logo span {
    background: linear-gradient(135deg, var(--accent), var(--danger));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.close-sidebar {
    background: rgba(255, 255, 255, 0.05);
    border: none;
    color: var(--text-secondary);
    font-size: 24px;
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.close-sidebar:active {
    transform: scale(0.9);
}

.sidebar-user {
    text-align: center;
    padding: 16px;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.1), rgba(6, 182, 212, 0.05));
    border-radius: var(--radius-sm);
    margin-bottom: 16px;
    border: 1px solid rgba(124, 58, 237, 0.1);
}

.sidebar-user-icon {
    font-size: 48px;
    margin-bottom: 4px;
}

.sidebar-user-name {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
}

.sidebar-user-email {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 2px;
    word-break: break-all;
}

.sidebar-menu {
    list-style: none;
}

.sidebar-menu li {
    margin-bottom: 4px;
}

.sidebar-menu a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: transparent;
    border-radius: var(--radius-xs);
    color: var(--text-secondary);
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition);
    font-size: 15px;
}

.sidebar-menu a:active {
    transform: scale(0.97);
}

.sidebar-menu a:hover {
    background: rgba(124, 58, 237, 0.08);
    color: var(--text-primary);
}

.sidebar-menu a.active {
    background: rgba(124, 58, 237, 0.15);
    color: var(--primary-light);
}

.sidebar-menu .menu-icon {
    font-size: 18px;
    width: 24px;
    flex-shrink: 0;
    text-align: center;
}

.dropdown-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: var(--radius-xs);
    cursor: pointer;
    color: var(--text-secondary);
    transition: var(--transition);
    font-size: 15px;
}

.dropdown-header:active {
    transform: scale(0.97);
}

.dropdown-header .menu-icon {
    font-size: 18px;
    width: 24px;
    flex-shrink: 0;
    text-align: center;
}

.dropdown-header .menu-text { flex: 1; }
.dropdown-arrow { transition: transform 0.3s ease; color: var(--text-muted); }
.dropdown-arrow.open { transform: rotate(180deg); }

.dropdown-items {
    display: none;
    padding-left: 16px;
    margin-top: 4px;
}

.dropdown-items.show {
    display: block;
    animation: fadeIn 0.2s ease;
}

.dropdown-items a {
    display: block;
    padding: 8px 14px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 13px;
    cursor: pointer;
    transition: var(--transition);
    border-radius: var(--radius-xs);
}

.dropdown-items a:active {
    transform: scale(0.97);
}

.dropdown-items a:hover {
    color: var(--primary-light);
    background: rgba(124, 58, 237, 0.05);
}

.sidebar-footer {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.sidebar-menu a.logout-btn {
    color: var(--danger);
}

.sidebar-menu a.logout-btn:hover {
    background: rgba(239, 68, 68, 0.1);
}

/* ============================================
   OVERLAY
   ============================================ */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 999;
    display: none;
}

.overlay.active {
    display: block;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ============================================
   HEADER - MOBILE OPTIMIZED
   ============================================ */
.header {
    background: rgba(17, 24, 39, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 10px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    position: sticky;
    top: 0;
    z-index: 100;
    min-height: 56px;
}

.menu-btn {
    background: none;
    border: none;
    color: var(--primary-light);
    font-size: 22px;
    cursor: pointer;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.menu-btn:active {
    transform: scale(0.9);
}

.logo {
    font-size: 18px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.logo span {
    background: linear-gradient(135deg, var(--accent), var(--danger));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.header-actions {
    display: flex;
    gap: 6px;
    align-items: center;
}

/* ============================================
   BUTTONS - TOUCH FRIENDLY
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 12px 20px;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition);
    min-height: 44px;
    min-width: 44px;
    touch-action: manipulation;
    user-select: none;
    -webkit-user-select: none;
}

.btn:active {
    transform: scale(0.95);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    box-shadow: 0 4px 15px rgba(124, 58, 237, 0.3);
}

.btn-primary:active {
    box-shadow: 0 2px 8px rgba(124, 58, 237, 0.2);
}

.btn-success {
    background: linear-gradient(135deg, var(--success), #059669);
    color: white;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

.btn-danger {
    background: linear-gradient(135deg, var(--danger), #dc2626);
    color: white;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

.btn-warning {
    background: linear-gradient(135deg, var(--accent), #d97706);
    color: white;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}

.btn-info {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-sm {
    padding: 8px 14px;
    font-size: 12px;
    min-height: 36px;
    min-width: 36px;
}

.btn-block {
    width: 100%;
    justify-content: center;
}

/* ============================================
   BACK BUTTON
   ============================================ */
.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    min-height: 36px;
}

.back-btn:active {
    transform: scale(0.95);
}

.back-btn .arrow {
    font-size: 14px;
}

/* ============================================
   HEADER BUTTONS
   ============================================ */
.header-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    min-height: 32px;
}

.header-btn:active {
    transform: scale(0.95);
}

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

/* ============================================
   BALANCE CARD
   ============================================ */
.balance-card {
    background: linear-gradient(135deg, rgba(17, 24, 39, 0.95), rgba(124, 58, 237, 0.08));
    margin: 12px 16px;
    padding: 16px 20px;
    border-radius: var(--radius);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid rgba(124, 58, 237, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: var(--shadow-glow);
}

.balance-info h3 {
    font-size: 11px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.balance-info p {
    font-size: 24px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--accent), var(--danger));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.add-funds-btn {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border: none;
    padding: 10px 18px;
    border-radius: 50px;
    color: white;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 20px rgba(124, 58, 237, 0.3);
    min-height: 44px;
    white-space: nowrap;
}

.add-funds-btn:active {
    transform: scale(0.95);
}

/* ============================================
   STATS ROW
   ============================================ */
.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    padding: 0 16px 12px;
}

.stat-box {
    background: rgba(17, 24, 39, 0.8);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 12px 8px;
    border-radius: var(--radius-sm);
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: var(--transition);
}

.stat-box:active {
    transform: scale(0.97);
}

.stat-number {
    font-size: 20px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 9px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 2px;
}

/* ============================================
   PRODUCTS GRID
   ============================================ */
.products-grid {
    padding: 0 16px 16px;
    display: grid;
    gap: 12px;
}

.product-card {
    background: rgba(17, 24, 39, 0.9);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: var(--transition);
}

.product-card:active {
    transform: scale(0.98);
}

.product-image {
    width: 100%;
    height: 140px;
    background-size: cover;
    background-position: center;
    background-color: var(--bg-card);
    position: relative;
}

.product-image::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to top, var(--bg-card), transparent);
}

.stock-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 4px 12px;
    border-radius: 50px;
    font-size: 11px;
    font-weight: 600;
    z-index: 1;
}

.stock-badge.out {
    background: rgba(239, 68, 68, 0.9);
}

.product-info {
    padding: 14px;
}

.product-title {
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 2px;
    color: var(--text-primary);
}

.product-price {
    font-size: 16px;
    font-weight: 800;
    color: var(--success);
    margin-bottom: 2px;
}

.product-stock {
    font-size: 11px;
    color: var(--accent);
    margin-bottom: 10px;
}

.view-accounts-btn {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border: none;
    padding: 12px;
    border-radius: var(--radius-sm);
    font-weight: 700;
    cursor: pointer;
    width: 100%;
    transition: var(--transition);
    min-height: 44px;
}

.view-accounts-btn:active {
    transform: scale(0.97);
}

.out-of-stock-btn {
    background: rgba(239, 68, 68, 0.8);
    color: white;
    padding: 12px;
    border-radius: var(--radius-sm);
    text-align: center;
    font-weight: 700;
    opacity: 0.6;
}

/* ============================================
   MODALS
   ============================================ */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 2000;
    justify-content: center;
    align-items: center;
    padding: 16px;
}

.modal.show {
    display: flex;
    animation: modalIn 0.25s ease;
}

@keyframes modalIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

.modal-content {
    background: rgba(17, 24, 39, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 20px;
    border-radius: var(--radius);
    max-width: 100%;
    width: 100%;
    max-height: 85vh;
    overflow-y: auto;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
}

.modal-content h3 {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 16px;
    font-size: 20px;
    font-weight: 800;
}

.modal-content input,
.modal-content select,
.modal-content textarea {
    width: 100%;
    padding: 12px 14px;
    margin: 6px 0;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xs);
    color: var(--text-primary);
    font-size: 14px;
    transition: var(--transition);
    min-height: 44px;
}

.modal-content input:focus,
.modal-content select:focus,
.modal-content textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.15);
}

.modal-content textarea {
    min-height: 80px;
    resize: vertical;
}

.account-entry {
    background: rgba(255, 255, 255, 0.03);
    padding: 14px;
    border-radius: var(--radius-xs);
    margin-bottom: 10px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.confirm-pay {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    width: 100%;
    transition: var(--transition);
    min-height: 48px;
    box-shadow: 0 4px 20px rgba(124, 58, 237, 0.3);
}

.confirm-pay:active {
    transform: scale(0.97);
}

.confirm-pay:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.cancel-pay {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    width: 100%;
    transition: var(--transition);
    min-height: 48px;
}

.cancel-pay:active {
    transform: scale(0.97);
}

/* ============================================
   TOAST
   ============================================ */
.toast {
    position: fixed;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    max-width: 92%;
    padding: 14px 24px;
    border-radius: var(--radius-sm);
    text-align: center;
    z-index: 3000;
    animation: toastSlideUp 0.4s ease;
    color: white;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    font-weight: 600;
    font-size: 14px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.toast.error {
    background: linear-gradient(135deg, var(--danger), #dc2626);
}
.toast.success {
    background: linear-gradient(135deg, var(--success), #059669);
}

@keyframes toastSlideUp {
    from { transform: translate(-50%, 100px); opacity: 0; }
    to { transform: translate(-50%, 0); opacity: 1; }
}

/* ============================================
   WHATSAPP FLOAT
   ============================================ */
.whatsapp-float {
    position: fixed;
    bottom: 20px;
    right: 16px;
    background: linear-gradient(135deg, #25D366, #128C7E);
    color: white;
    border-radius: 50%;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    cursor: pointer;
    box-shadow: 0 4px 24px rgba(37, 211, 102, 0.3);
    transition: var(--transition);
    z-index: 1000;
    text-decoration: none;
}

.whatsapp-float:active {
    transform: scale(0.9);
}

/* ============================================
   DEPOSIT
   ============================================ */
.deposit-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.deposit-amount-input {
    font-size: 24px;
    text-align: center;
    padding: 16px !important;
    font-weight: 700;
}

.deposit-buttons {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.quick-amount {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 12px;
    border-radius: var(--radius-xs);
    color: var(--primary-light);
    font-weight: 700;
    cursor: pointer;
    text-align: center;
    transition: var(--transition);
    min-height: 44px;
}

.quick-amount:active {
    transform: scale(0.95);
}

.min-amount-note {
    background: rgba(245, 158, 11, 0.1);
    padding: 10px;
    border-radius: var(--radius-xs);
    font-size: 12px;
    color: var(--accent);
    text-align: center;
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
    background: rgba(17, 24, 39, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding: 20px 16px;
    text-align: center;
    margin-top: 12px;
}

.footer-logo {
    font-size: 20px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 8px;
}

.footer-contact-item {
    font-size: 12px;
    color: var(--text-secondary);
    margin: 2px 0;
}

.footer-copyright {
    font-size: 10px;
    color: var(--text-muted);
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* ============================================
   ADMIN - MOBILE OPTIMIZED
   ============================================ */
.admin-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    padding: 12px;
}

.stat-card {
    background: rgba(17, 24, 39, 0.8);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 12px;
    border-radius: var(--radius-sm);
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.stat-card h3 {
    font-size: 10px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.stat-card p {
    font-size: 18px;
    font-weight: 800;
    color: var(--text-primary);
}

.admin-section {
    background: rgba(17, 24, 39, 0.8);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    margin: 12px;
    padding: 16px;
    border-radius: var(--radius);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.admin-section h3 {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 12px;
}

.admin-item {
    background: rgba(255, 255, 255, 0.03);
    padding: 12px 14px;
    border-radius: var(--radius-xs);
    margin-bottom: 8px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.admin-item .info {
    flex: 1;
    font-size: 13px;
}

.admin-item .info strong {
    color: var(--text-primary);
    font-size: 14px;
}

.admin-item .actions {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.admin-item .actions .btn,
.admin-item .actions button {
    flex: 1;
    min-width: 60px;
    justify-content: center;
    font-size: 11px;
    padding: 8px 12px;
    min-height: 36px;
}

.search-box {
    width: 100%;
    padding: 12px 14px;
    margin-bottom: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xs);
    color: white;
    font-size: 14px;
    min-height: 44px;
}

.search-box:focus {
    outline: none;
    border-color: var(--primary);
}

/* ============================================
   SUPPORT - MOBILE OPTIMIZED
   ============================================ */
.support-message {
    padding: 12px 14px;
    border-radius: 14px;
    margin-bottom: 8px;
    max-width: 90%;
    word-wrap: break-word;
    animation: messageIn 0.25s ease;
    font-size: 14px;
}

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

.support-message.user {
    background: rgba(255, 255, 255, 0.08);
    margin-left: auto;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.support-message.support {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    margin-right: auto;
    color: white;
}

.support-input-area {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    padding: 8px 0;
    position: sticky;
    bottom: 0;
    background: var(--bg-dark);
}

.support-input-area input {
    flex: 1;
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xs);
    color: white;
    font-size: 14px;
    min-height: 44px;
}

.support-input-area input:focus {
    outline: none;
    border-color: var(--primary);
}

.support-send-btn {
    padding: 12px 20px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border: none;
    border-radius: var(--radius-xs);
    color: white;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    min-height: 44px;
    min-width: 60px;
}

.support-send-btn:active {
    transform: scale(0.95);
}

/* ============================================
   AUTH PAGES - MOBILE OPTIMIZED
   ============================================ */
.auth-container {
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: var(--bg-dark);
    padding: 16px;
}

.auth-box {
    background: rgba(17, 24, 39, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 28px 20px;
    border-radius: var(--radius);
    width: 100%;
    max-width: 400px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.auth-box .logo-small {
    font-size: 26px;
    font-weight: 800;
    text-align: center;
    margin-bottom: 20px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.auth-box h2 {
    font-size: 22px;
    margin-bottom: 2px;
}

.auth-box .subtitle {
    color: var(--text-secondary);
    font-size: 13px;
    margin-bottom: 16px;
}

.auth-box input {
    width: 100%;
    padding: 14px 16px;
    margin: 6px 0;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xs);
    color: var(--text-primary);
    font-size: 14px;
    transition: var(--transition);
    min-height: 48px;
}

.auth-box input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.15);
}

.auth-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border: none;
    border-radius: var(--radius-xs);
    color: white;
    font-weight: 700;
    font-size: 16px;
    cursor: pointer;
    margin-top: 10px;
    transition: var(--transition);
    min-height: 48px;
}

.auth-btn:active {
    transform: scale(0.97);
}

.auth-links {
    text-align: center;
    margin-top: 16px;
    font-size: 14px;
    color: var(--text-secondary);
}

.auth-links a {
    color: var(--primary-light);
    cursor: pointer;
    text-decoration: none;
    font-weight: 600;
}

/* ============================================
   LANDING - MOBILE OPTIMIZED
   ============================================ */
.landing-container {
    min-height: 100vh;
    min-height: 100dvh;
    background: var(--bg-dark);
    position: relative;
}

.landing-content {
    text-align: center;
    max-width: 100%;
    padding: 40px 20px;
}

.logo-large {
    font-size: 40px;
    font-weight: 900;
    margin-bottom: 12px;
    background: linear-gradient(135deg, var(--primary), var(--secondary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.landing-tagline {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 12px;
    color: var(--text-primary);
    line-height: 1.2;
}

.landing-desc {
    font-size: 15px;
    color: var(--text-secondary);
    margin-bottom: 30px;
    max-width: 100%;
    line-height: 1.7;
}

.landing-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 40px;
}

.landing-buttons .btn {
    width: 100%;
    padding: 14px;
    font-size: 16px;
}

.section-title {
    font-size: 24px;
    font-weight: 800;
    margin: 30px 0 20px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.features-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

.feature-card {
    background: rgba(17, 24, 39, 0.8);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 20px;
    border-radius: var(--radius);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.feature-icon {
    font-size: 32px;
    margin-bottom: 8px;
}

.feature-title {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 4px;
    color: var(--text-primary);
}

.feature-text {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.cta-section {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.1), rgba(6, 182, 212, 0.05));
    border-radius: var(--radius);
    padding: 30px 20px;
    margin-top: 30px;
    border: 1px solid rgba(124, 58, 237, 0.1);
}

.cta-title {
    font-size: 22px;
    font-weight: 800;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.cta-text {
    color: var(--text-secondary);
    margin-bottom: 16px;
    font-size: 14px;
}

/* ============================================
   ANIMATED BACKGROUND
   ============================================ */
.animated-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.animated-bg .orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.08;
    animation: orbFloat 20s ease-in-out infinite;
}

.animated-bg .orb:nth-child(1) {
    width: 300px;
    height: 300px;
    background: var(--primary);
    top: -20%;
    right: -20%;
}

.animated-bg .orb:nth-child(2) {
    width: 200px;
    height: 200px;
    background: var(--secondary);
    bottom: -20%;
    left: -20%;
    animation-delay: -7s;
}

.animated-bg .orb:nth-child(3) {
    width: 150px;
    height: 150px;
    background: var(--accent);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation-delay: -14s;
}

@keyframes orbFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(30px, -30px) scale(1.1); }
    66% { transform: translate(-20px, 20px) scale(0.9); }
}

/* ============================================
   BADGES & STATUS
   ============================================ */
.badge {
    padding: 2px 10px;
    border-radius: 50px;
    font-size: 9px;
    font-weight: 700;
    display: inline-block;
}

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

.badge-user {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
}

.order-status,
.transaction-status {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 50px;
    font-size: 9px;
    font-weight: 700;
}

.status-completed,
.status-success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.status-failed {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

.status-pending {
    background: rgba(245, 158, 11, 0.15);
    color: var(--accent);
}

/* ============================================
   QUANTITY SELECTOR
   ============================================ */
.quantity-selector {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 12px 0;
    justify-content: center;
}

.quantity-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--primary-light);
    width: 40px;
    height: 40px;
    border-radius: var(--radius-xs);
    cursor: pointer;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.quantity-btn:active {
    transform: scale(0.9);
}

.quantity-input {
    width: 56px;
    text-align: center;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xs);
    color: white;
    padding: 8px;
    font-size: 16px;
    font-weight: 700;
    min-height: 40px;
}

.total-price {
    font-size: 18px;
    color: var(--success);
    font-weight: 700;
    text-align: center;
    margin-top: 10px;
}

.max-warning {
    color: var(--accent);
    font-size: 11px;
    text-align: center;
}

/* ============================================
   RESPONSIVE - TABLET & DESKTOP
   ============================================ */
@media (min-width: 768px) {
    body {
        padding-bottom: 0;
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
        max-width: 900px;
        margin: 0 auto;
    }
    
    .admin-stats {
        grid-template-columns: repeat(4, 1fr);
        gap: 12px;
        padding: 16px;
    }
    
    .stats-row {
        grid-template-columns: repeat(4, 1fr);
        max-width: 600px;
        margin: 0 auto;
    }
    
    .balance-card {
        max-width: 600px;
        margin: 16px auto 0;
    }
    
    .admin-section {
        max-width: 900px;
        margin: 16px auto;
    }
    
    .admin-item {
        flex-direction: row;
        align-items: center;
    }
    
    .admin-item .actions {
        flex-wrap: nowrap;
    }
    
    .landing-content {
        max-width: 900px;
        margin: 0 auto;
        padding: 60px 40px;
    }
    
    .landing-buttons {
        flex-direction: row;
        justify-content: center;
    }
    
    .landing-buttons .btn {
        width: auto;
        padding: 14px 36px;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
    
    .deposit-container {
        max-width: 400px;
        margin: 0 auto;
    }
    
    .logo-large {
        font-size: 56px;
    }
    
    .landing-tagline {
        font-size: 40px;
    }
    
    .support-container {
        max-width: 600px;
        margin: 0 auto;
    }
    
    .whatsapp-float {
        width: 60px;
        height: 60px;
        font-size: 30px;
        bottom: 30px;
        right: 30px;
    }
}

@media (min-width: 1024px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
        max-width: 1100px;
    }
    
    .features-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .admin-stats {
        grid-template-columns: repeat(6, 1fr);
    }
    
    .landing-tagline {
        font-size: 48px;
    }
    
    .logo-large {
        font-size: 64px;
    }
}

/* ============================================
   PRINT
   ============================================ */
@media print {
    .sidebar, .header, .whatsapp-float, .back-btn, .menu-btn, .add-funds-btn, .animated-bg {
        display: none !important;
    }
    .modal {
        position: static;
        background: white;
        display: block !important;
    }
    body { background: white; color: black; }
}