/* =====================================================
   CLIENT PORTAL — PREMIUM DARK THEME V2
   Design: Glassmorphism + Purple-Blue Gradients
   Font: Inter (Google Fonts)
   Mobile-first responsive
   ===================================================== */

/* ===== CSS RESET & VARIABLES ===== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-primary: #0f0f23;
    --bg-secondary: #1a1a2e;
    --bg-card: rgba(26, 26, 46, 0.8);
    --bg-glass: rgba(255, 255, 255, 0.03);
    --bg-hover: rgba(99, 102, 241, 0.08);

    --text-primary: #e2e8f0;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;

    --accent: #6366f1;
    --accent-light: #818cf8;
    --accent-dark: #4f46e5;
    --accent-glow: rgba(99, 102, 241, 0.4);

    --success: #22c55e;
    --warning: #f59e0b;
    --danger: #ef4444;
    --info: #3b82f6;

    --border: rgba(99, 102, 241, 0.15);
    --border-hover: rgba(99, 102, 241, 0.3);

    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 16px;

    --shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.4);
    --shadow-glow: 0 0 20px var(--accent-glow);

    --sidebar-width: 260px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== BASE ===== */
html {
    font-size: 14px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    overflow-x: hidden;
}

a {
    color: var(--accent-light);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--accent);
}

/* ===== SIDEBAR ===== */
.sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    background: linear-gradient(180deg, var(--bg-secondary) 0%, rgba(15, 15, 35, 0.95) 100%);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    z-index: 100;
    transition: var(--transition);
    backdrop-filter: blur(20px);
}

.sidebar-header {
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--accent), #8b5cf6);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    box-shadow: var(--shadow-glow);
}

.logo-text {
    font-size: 16px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--accent-light), #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sidebar-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 20px;
    cursor: pointer;
    padding: 4px;
}

.sidebar-nav {
    flex: 1;
    padding: 16px 12px;
    overflow-y: auto;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
    margin-bottom: 4px;
    position: relative;
    overflow: hidden;
}

.nav-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 0;
    height: 100%;
    background: linear-gradient(90deg, var(--accent), transparent);
    opacity: 0;
    transition: var(--transition);
    border-radius: var(--radius-sm);
}

.nav-item:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
}

.nav-item:hover::before {
    width: 3px;
    opacity: 1;
}

.nav-item.active {
    color: var(--accent-light);
    background: rgba(99, 102, 241, 0.12);
}

.nav-item.active::before {
    width: 3px;
    opacity: 1;
}

.nav-icon {
    font-size: 18px;
    width: 24px;
    text-align: center;
    flex-shrink: 0;
}

.sidebar-footer {
    padding: 16px;
    border-top: 1px solid var(--border);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    margin-bottom: 8px;
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--accent), #8b5cf6);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    color: #fff;
    flex-shrink: 0;
}

.user-details {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.user-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.user-role {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.logout-btn {
    color: var(--danger) !important;
    opacity: 0.7;
}

.logout-btn:hover {
    opacity: 1;
    background: rgba(239, 68, 68, 0.1) !important;
}

/* ===== MAIN CONTENT ===== */
.main-content {
    margin-left: var(--sidebar-width);
    flex: 1;
    min-height: 100vh;
    padding: 0;
    width: calc(100% - var(--sidebar-width));
}

.content-header {
    padding: 24px 32px;
    border-bottom: 1px solid var(--border);
    background: var(--bg-glass);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 50;
}

.page-title {
    font-size: 22px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--text-primary), var(--accent-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.content-body {
    padding: 32px;
    animation: fadeIn 0.3s ease;
}

/* ===== CARDS ===== */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    backdrop-filter: blur(10px);
    transition: var(--transition);
}

.card:hover {
    border-color: var(--border-hover);
    box-shadow: var(--shadow);
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border);
}

.card-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

/* ===== STATS GRID ===== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 32px;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    position: relative;
    overflow: hidden;
    transition: var(--transition);
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent), #8b5cf6);
    opacity: 0;
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow);
    border-color: var(--border-hover);
}

.stat-card:hover::before {
    opacity: 1;
}

.stat-icon {
    font-size: 28px;
    margin-bottom: 12px;
}

.stat-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.stat-label {
    font-size: 13px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ===== TABLES ===== */
.table-wrapper {
    overflow-x: auto;
    border-radius: var(--radius);
    -webkit-overflow-scrolling: touch;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th {
    padding: 14px 16px;
    text-align: left;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-muted);
    background: rgba(99, 102, 241, 0.05);
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
}

td {
    padding: 14px 16px;
    font-size: 13px;
    color: var(--text-secondary);
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    vertical-align: middle;
}

tr {
    transition: var(--transition);
}

tr:hover td {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.key-display {
    font-family: 'Fira Code', 'Courier New', monospace;
    color: var(--accent-light);
    font-size: 12px;
    letter-spacing: 1px;
    cursor: pointer;
    padding: 4px 8px;
    background: rgba(99, 102, 241, 0.08);
    border-radius: 6px;
    border: 1px solid rgba(99, 102, 241, 0.15);
    display: inline-block;
}

.key-display:hover {
    background: rgba(99, 102, 241, 0.15);
    box-shadow: 0 0 8px var(--accent-glow);
}

/* ===== BADGES ===== */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border: none;
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(rgba(255, 255, 255, 0.1), transparent);
    opacity: 0;
    transition: var(--transition);
}

.btn:hover::after {
    opacity: 1;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    color: #fff;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
    color: #fff;
}

.btn-success {
    background: linear-gradient(135deg, var(--success), #16a34a);
    color: #fff;
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
}

.btn-success:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(34, 197, 94, 0.4);
    color: #fff;
}

.btn-danger {
    background: linear-gradient(135deg, var(--danger), #dc2626);
    color: #fff;
}

.btn-outline {
    background: transparent;
    color: var(--accent-light);
    border: 1px solid var(--border);
}

.btn-outline:hover {
    background: var(--bg-hover);
    border-color: var(--accent);
    color: var(--accent-light);
}

.btn-sm {
    padding: 6px 14px;
    font-size: 12px;
}

.btn-lg {
    padding: 14px 28px;
    font-size: 16px;
}

.btn-block {
    width: 100%;
    justify-content: center;
}

.btn-glow:hover {
    box-shadow: 0 6px 24px rgba(99, 102, 241, 0.5);
}

/* ===== FORMS ===== */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-label-icon {
    font-size: 14px;
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-glass);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 14px;
    transition: var(--transition);
    outline: none;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
    background: rgba(99, 102, 241, 0.03);
}

.form-input::placeholder {
    color: var(--text-muted);
}

.form-select option {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.form-textarea {
    min-height: 100px;
    resize: vertical;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.form-hint {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* Password toggle */
.input-password-wrapper {
    position: relative;
}

.input-password-wrapper .form-input {
    padding-right: 48px;
}

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    font-size: 16px;
    padding: 4px;
    opacity: 0.6;
    transition: opacity 0.2s;
}

.password-toggle:hover {
    opacity: 1;
}

/* ===== ALERTS ===== */
.alert {
    padding: 14px 20px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.alert-success {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: #6ee7b7;
}

.alert-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #fca5a5;
}

.alert-warning {
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.3);
    color: #fcd34d;
}

.alert-info {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: #93c5fd;
}

.alert-close {
    background: none;
    border: none;
    color: inherit;
    font-size: 18px;
    cursor: pointer;
    opacity: 0.6;
    padding: 0 4px;
    margin-left: auto;
}

.alert-close:hover {
    opacity: 1;
}

/* ===== AUTH PAGES — Premium Redesign ===== */
.auth-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    min-height: -webkit-fill-available;
    background: #0a0a1a;
    padding: 16px;
    position: relative;
    overflow: hidden;
}

.auth-page .sidebar {
    display: none;
}

.auth-page .main-content {
    margin-left: 0;
    width: 100%;
}

/* Animated background orbs */
.auth-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.auth-bg-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.4;
    animation: orbFloat 20s ease-in-out infinite;
}

.auth-bg-orb-1 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, #6366f1 0%, transparent 70%);
    top: -10%;
    right: -5%;
    animation-duration: 18s;
}

.auth-bg-orb-2 {
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, #8b5cf6 0%, transparent 70%);
    bottom: -10%;
    left: -5%;
    animation-duration: 22s;
    animation-delay: -5s;
}

.auth-bg-orb-3 {
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, #ec4899 0%, transparent 70%);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation-duration: 25s;
    animation-delay: -10s;
}

@keyframes orbFloat {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    25% {
        transform: translate(30px, -40px) scale(1.05);
    }

    50% {
        transform: translate(-20px, 20px) scale(0.95);
    }

    75% {
        transform: translate(15px, 30px) scale(1.02);
    }
}

.auth-container {
    width: 100%;
    max-width: 440px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.auth-card {
    background: rgba(20, 20, 40, 0.85);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 24px;
    padding: 40px 36px;
    backdrop-filter: blur(40px);
    -webkit-backdrop-filter: blur(40px);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.4),
        0 0 60px rgba(99, 102, 241, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
    animation: cardAppear 0.5s ease-out;
}

@keyframes cardAppear {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #6366f1, #8b5cf6, #ec4899, #6366f1);
    background-size: 300% 100%;
    animation: gradientSlide 4s ease infinite;
}

@keyframes gradientSlide {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.auth-logo {
    text-align: center;
    margin-bottom: 32px;
}

.auth-logo-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
    animation: iconPulse 3s ease-in-out infinite;
}

@keyframes iconPulse {

    0%,
    100% {
        box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
    }

    50% {
        box-shadow: 0 4px 30px rgba(99, 102, 241, 0.6);
    }
}

.auth-logo h1 {
    font-size: 24px;
    font-weight: 800;
    background: linear-gradient(135deg, #e2e8f0, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 6px;
}

.auth-logo h2 {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
}

.auth-logo p {
    color: var(--text-muted);
    font-size: 14px;
    margin-top: 4px;
}

.auth-card .form-input {
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(99, 102, 241, 0.15);
    border-radius: 12px;
    font-size: 15px;
}

.auth-card .form-input:focus {
    border-color: #6366f1;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.15);
    background: rgba(99, 102, 241, 0.04);
}

.auth-card .btn-primary {
    padding: 14px 24px;
    font-size: 15px;
    border-radius: 12px;
    margin-top: 8px;
}

.auth-card .btn-outline {
    padding: 12px 24px;
    font-size: 14px;
    border-radius: 12px;
    border-color: rgba(99, 102, 241, 0.25);
}

.auth-card .btn-outline:hover {
    background: rgba(99, 102, 241, 0.1);
    border-color: rgba(99, 102, 241, 0.4);
}

.auth-divider {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 24px 0;
    color: var(--text-muted);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.2), transparent);
}

.auth-footer {
    text-align: center;
    margin-top: 20px;
    font-size: 14px;
    color: var(--text-muted);
}

.auth-footer a {
    color: var(--accent-light);
    font-weight: 500;
}

.auth-footer a:hover {
    color: #a78bfa;
}

.auth-trust {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 24px;
    flex-wrap: wrap;
}

.auth-trust span {
    font-size: 12px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 4px;
    opacity: 0.7;
}

/* ===== DUAL AUTH LAYOUT (Login + Register side by side) ===== */
.auth-dual-container {
    width: 100%;
    max-width: 920px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
    padding: 16px;
}

.auth-dual-header {
    text-align: center;
    margin-bottom: 32px;
    animation: cardAppear 0.4s ease-out;
}

.auth-dual-header .auth-logo-icon {
    margin: 0 auto 16px;
}

.auth-dual-header h1 {
    font-size: 28px;
    font-weight: 800;
    background: linear-gradient(135deg, #e2e8f0, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 8px;
}

.auth-dual-header p {
    color: var(--text-muted);
    font-size: 14px;
}

.auth-dual-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    align-items: start;
}

.auth-dual-cards .auth-card {
    max-width: none;
    animation: cardAppear 0.5s ease-out backwards;
}

.auth-dual-cards .auth-card:nth-child(2) {
    animation-delay: 0.1s;
}

.auth-card-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border);
}

.auth-card-label-icon {
    font-size: 22px;
}

/* ===== PRODUCT CARDS ===== */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 24px;
}

.product-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 0;
    overflow: hidden;
    transition: var(--transition);
    position: relative;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-glow);
    border-color: var(--accent);
}

.product-card-header {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(139, 92, 246, 0.1));
    padding: 28px 24px;
    text-align: center;
    border-bottom: 1px solid var(--border);
}

.product-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.product-price {
    font-size: 32px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--accent-light), #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.product-price small {
    font-size: 14px;
    font-weight: 400;
    -webkit-text-fill-color: var(--text-muted);
}

.product-card-body {
    padding: 24px;
}

.product-features {
    list-style: none;
    margin-bottom: 24px;
}

.product-features li {
    padding: 8px 0;
    color: var(--text-secondary);
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.product-features li::before {
    content: '✓';
    color: var(--success);
    font-weight: 700;
}

.product-card-body .btn {
    width: 100%;
}

/* ===== BANK INFO ===== */
.bank-info {
    background: rgba(245, 158, 11, 0.05);
    border: 1px solid rgba(245, 158, 11, 0.2);
    border-radius: var(--radius);
    padding: 24px;
    margin: 20px 0;
}

.bank-info h4 {
    color: #fbbf24;
    margin-bottom: 16px;
    font-size: 15px;
}

.bank-detail {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid rgba(245, 158, 11, 0.1);
    font-size: 14px;
}

.bank-detail:last-child {
    border-bottom: none;
}

.bank-detail .label {
    color: var(--text-muted);
}

.bank-detail .value {
    color: var(--text-primary);
    font-weight: 600;
}

.bank-detail .value.highlight {
    color: #fbbf24;
    font-family: monospace;
    letter-spacing: 1px;
}

/* ===== MODAL ===== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    transform: scale(0.9) translateY(20px);
    transition: var(--transition);
}

.modal-overlay.active .modal {
    transform: scale(1) translateY(0);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.modal-title {
    font-size: 18px;
    font-weight: 700;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 24px;
    cursor: pointer;
    padding: 4px;
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 24px;
}

/* ===== EMPTY STATE ===== */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.empty-state .icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.empty-state h3 {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.empty-state p {
    font-size: 14px;
    margin-bottom: 20px;
}

/* ===== COPY TOOLTIP ===== */
.copy-tooltip {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: var(--success);
    color: #fff;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 600;
    z-index: 9999;
    animation: slideUp 0.3s ease, fadeOut 0.3s ease 1.5s forwards;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateY(-10px);
    }
}

/* ===== ACTION BAR ===== */
.action-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 12px;
}

/* ===== ORDER DETAIL ===== */
.order-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.detail-item {
    margin-bottom: 16px;
}

.detail-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.detail-value {
    font-size: 15px;
    color: var(--text-primary);
    font-weight: 500;
}

/* ==========================================================
   RESPONSIVE BREAKPOINTS
   ========================================================== */

/* ===== iPad Landscape / Small Desktop (1024px) ===== */
@media (max-width: 1024px) {
    .sidebar {
        width: 220px;
    }

    .main-content {
        margin-left: 220px;
        width: calc(100% - 220px);
    }

    .content-body {
        padding: 24px;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ===== Tablet / iPad Portrait (768px) ===== */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        width: 280px;
        position: fixed;
        z-index: 200;
    }

    .sidebar.open {
        transform: translateX(0);
        box-shadow: 4px 0 24px rgba(0, 0, 0, 0.5);
    }

    .sidebar-toggle {
        display: block;
    }

    .main-content {
        margin-left: 0;
        width: 100%;
    }

    .content-header {
        padding: 16px 20px;
    }

    .page-title {
        font-size: 18px;
    }

    .content-body {
        padding: 20px 16px;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }

    .stat-card {
        padding: 16px;
    }

    .stat-value {
        font-size: 22px;
    }

    .stat-label {
        font-size: 11px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .order-detail-grid {
        grid-template-columns: 1fr;
    }

    .products-grid {
        grid-template-columns: 1fr;
    }

    .table-wrapper {
        margin: 0 -16px;
        border-radius: 0;
    }

    th,
    td {
        padding: 10px 12px;
        font-size: 12px;
    }

    .mobile-toggle {
        display: block;
        position: fixed;
        bottom: 20px;
        left: 20px;
        z-index: 201;
        width: 48px;
        height: 48px;
        border-radius: 50%;
        background: linear-gradient(135deg, var(--accent), var(--accent-dark));
        border: none;
        color: #fff;
        font-size: 20px;
        cursor: pointer;
        box-shadow: var(--shadow-glow);
    }

    .auth-card {
        padding: 36px 28px;
    }

    .auth-dual-cards {
        grid-template-columns: 1fr;
    }

    .auth-dual-header h1 {
        font-size: 22px;
    }

    .auth-bg-orb-1 {
        width: 250px;
        height: 250px;
    }

    .auth-bg-orb-2 {
        width: 200px;
        height: 200px;
    }

    .auth-bg-orb-3 {
        width: 150px;
        height: 150px;
    }

    .modal {
        max-width: 90%;
        padding: 24px;
    }

    .bank-detail {
        flex-direction: column;
        gap: 4px;
    }
}

/* ===== Mobile (480px) ===== */
@media (max-width: 480px) {
    html {
        font-size: 13px;
    }

    .content-header {
        padding: 14px 16px;
    }

    .content-body {
        padding: 16px 12px;
    }

    .stats-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .stat-card {
        padding: 14px;
        display: flex;
        align-items: center;
        gap: 12px;
    }

    .stat-icon {
        font-size: 24px;
        margin-bottom: 0;
    }

    .stat-value {
        font-size: 20px;
        margin-bottom: 0;
    }

    .card {
        padding: 16px;
        border-radius: 12px;
    }

    .card-header {
        margin-bottom: 14px;
        padding-bottom: 12px;
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .auth-container {
        max-width: 100%;
    }

    .auth-card {
        padding: 28px 20px;
        border-radius: 20px;
    }

    .auth-logo-icon {
        width: 52px;
        height: 52px;
        border-radius: 14px;
    }

    .auth-logo-icon svg {
        width: 26px;
        height: 26px;
    }

    .auth-logo h1 {
        font-size: 20px;
    }

    .auth-logo p {
        font-size: 13px;
    }

    .auth-card .form-input {
        padding: 12px 14px;
        font-size: 16px;
    }

    /* 16px prevents iOS zoom */
    .auth-card .btn-primary {
        padding: 13px 20px;
        font-size: 14px;
    }

    .auth-trust {
        gap: 12px;
    }

    .auth-trust span {
        font-size: 11px;
    }

    .auth-bg-orb-1 {
        width: 180px;
        height: 180px;
    }

    .auth-bg-orb-2 {
        width: 140px;
        height: 140px;
    }

    .auth-bg-orb-3 {
        width: 100px;
        height: 100px;
    }

    th,
    td {
        padding: 8px 10px;
        font-size: 11px;
    }

    .key-display {
        font-size: 10px;
        letter-spacing: 0.5px;
        padding: 3px 6px;
        max-width: 100px;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .badge {
        padding: 3px 8px;
        font-size: 10px;
    }

    .btn {
        padding: 8px 14px;
        font-size: 13px;
    }

    .btn-sm {
        padding: 5px 10px;
        font-size: 11px;
    }

    .action-bar {
        flex-direction: column;
        align-items: stretch;
    }

    .modal {
        width: 95%;
        padding: 20px;
        border-radius: 16px;
    }
}

/* ===== Very small phones (360px) ===== */
@media (max-width: 360px) {
    .auth-card {
        padding: 24px 16px;
    }

    .auth-logo h1 {
        font-size: 18px;
    }

    .form-row {
        gap: 8px;
    }

    .auth-trust {
        flex-direction: column;
        align-items: center;
        gap: 6px;
    }
}

@media (min-width: 769px) {
    .mobile-toggle {
        display: none;
    }
}

/* ===== ANIMATIONS ===== */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.stat-card,
.product-card,
.card {
    animation: fadeIn 0.4s ease backwards;
}

.stat-card:nth-child(2),
.product-card:nth-child(2) {
    animation-delay: 0.1s;
}

.stat-card:nth-child(3),
.product-card:nth-child(3) {
    animation-delay: 0.2s;
}

.stat-card:nth-child(4),
.product-card:nth-child(4) {
    animation-delay: 0.3s;
}

/* ===== LANDING PAGE ===== */
.landing-hero {
    text-align: center;
    padding: 80px 20px;
    background: radial-gradient(ellipse at center, rgba(99, 102, 241, 0.15) 0%, transparent 70%);
}

.landing-hero h1 {
    font-size: 48px;
    font-weight: 800;
    margin-bottom: 16px;
    background: linear-gradient(135deg, var(--text-primary), var(--accent-light), #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}

.landing-hero p {
    font-size: 18px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 32px;
}

.landing-products {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px 80px;
}

.landing-products h2 {
    text-align: center;
    font-size: 28px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 40px;
}

/* ===== Safe area (notched iPhones) ===== */
@supports (padding: env(safe-area-inset-bottom)) {
    .auth-page {
        padding-bottom: calc(16px + env(safe-area-inset-bottom));
    }

    .mobile-toggle {
        bottom: calc(20px + env(safe-area-inset-bottom));
    }
}