/* ============================================= */
/* Smart Inventory - Style Invoice Tracker       */
/* ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=IBM+Plex+Sans:wght@300;400;500;600;700&display=swap');

:root {
    --bg-main: #F8FAFC;
    --bg-card: #FFFFFF;
    --bg-card-hover: #f1f5f9;
    --bg-input: #FFFFFF;
    --bg-secondary: #f1f5f9;
    --text-primary: #0F172A;
    --text-secondary: #475569;
    --text-muted: #94A3B8;
    --border: #E2E8F0;
    --border-subtle: #f1f5f9;
    --border-focus: #94A3B8;
    --accent-blue: #2563EB;
    --accent-gold: #F5A623;
    --accent-gold-hover: #e09400;
    --accent-green: #10B981;
    --accent-red: #DC2626;
    --accent-orange: #f59e0b;
    --accent-purple: #8b5cf6;
    --accent-teal: #14b8a6;
    --sidebar-bg: #FFFFFF;
    --sidebar-text: #475569;
    --sidebar-active: #DBEAFE;
    --shadow-sm: 0 1px 2px 0 rgba(0,0,0,0.05);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1);
    --shadow-xl: 0 25px 50px -12px rgba(0,0,0,0.25);
    --radius: 8px;
    --radius-lg: 12px;
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'IBM Plex Sans', sans-serif;
    --transition: all 0.2s ease;
}

[data-theme="dark"] {
    --bg-main: #0f172a;
    --bg-card: #1e293b;
    --bg-card-hover: #334155;
    --bg-input: #1e293b;
    --bg-secondary: #1e293b;
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --border: rgba(255,255,255,0.08);
    --border-subtle: rgba(255,255,255,0.04);
    --border-focus: rgba(255,255,255,0.2);
    --accent-blue: #3b82f6;
    --accent-green: #22c55e;
    --accent-red: #ef4444;
    --sidebar-bg: #1e293b;
    --sidebar-text: #94a3b8;
    --sidebar-active: rgba(59,130,246,0.15);
    --shadow-sm: 0 1px 2px 0 rgba(0,0,0,0.3);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.4);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.5);
    --shadow-xl: 0 25px 50px -12px rgba(0,0,0,0.6);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: var(--font-body);
    background: var(--bg-main);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    transition: var(--transition);
    font-size: 14px;
    line-height: 1.6;
}
h1, h2, h3, h4, h5, h6 { font-family: var(--font-heading); }

::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--bg-main); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ============ PRELOADER ============ */
.preloader {
    position: fixed; inset: 0; z-index: 9999;
    display: flex; align-items: center; justify-content: center;
    background: #0f172a; transition: opacity 0.6s;
}
.preloader.hidden { opacity: 0; pointer-events: none; }
.preloader-inner { text-align: center; }
.preloader-rings { position: relative; width: 160px; height: 160px; margin: 0 auto 28px; }
.ring { position: absolute; border-radius: 50%; border: 3px solid transparent; }
.ring-1 { inset: 0; border-top-color: #C42127; animation: spin 1s linear infinite; }
.ring-2 { inset: 12px; border-top-color: #C42127; animation: spin 1.2s linear infinite reverse; }
.ring-3 { inset: 24px; border-top-color: #C42127; animation: spin 1.5s linear infinite; }
.preloader-logo { position: absolute; inset: 34px; display: flex; align-items: center; justify-content: center; }
.preloader-logo img { width: 100%; height: 100%; object-fit: contain; }
.preloader-title { display: block; font-size: 26px; font-weight: 800; color: #FFFFFF; font-family: 'Outfit', sans-serif; letter-spacing: 0.5px; }
.preloader-subtitle { display: block; font-size: 14px; color: #C42127; margin-top: 6px; font-weight: 600; }
.preloader-bar { width: 220px; height: 4px; margin: 28px auto 0; background: rgba(255,255,255,0.1); border-radius: 4px; overflow: hidden; }
.preloader-bar-fill { height: 100%; background: #FFFFFF; border-radius: 4px; animation: preloaderFill 2s ease-in-out forwards; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes preloaderFill { 0%{width:0} 50%{width:70%} 100%{width:100%} }
@keyframes fadeIn { from{opacity:0;transform:translateY(8px)} to{opacity:1;transform:translateY(0)} }
@keyframes slideUp { from{opacity:0;transform:translateY(16px)} to{opacity:1;transform:translateY(0)} }

/* ============ AUTH PAGES ============ */
.auth-page { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.auth-image { position: relative; overflow: hidden; }
.auth-image img { width: 100%; height: 100%; object-fit: cover; }
.auth-image-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(180deg, rgba(26,30,42,0.3) 0%, rgba(21,24,39,0.85) 100%);
    display: flex; flex-direction: column; justify-content: flex-end; padding: 56px;
}
.auth-image-overlay h2 { font-size: 32px; font-weight: 700; color: #fff; margin-bottom: 10px; }
.auth-image-overlay p { font-size: 16px; color: rgba(255,255,255,0.7); line-height: 1.6; max-width: 400px; }
.auth-form-side {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    padding: 48px; background: var(--bg-main); min-height: 100vh; overflow-y: auto;
}
.auth-card { width: 100%; max-width: 420px; animation: fadeIn 0.5s ease; }
.auth-logo { display: flex; flex-direction: column; align-items: center; gap: 8px; margin-bottom: 36px; }
.auth-logo img { width: 280px; height: auto; object-fit: contain; }
.auth-logo span { font-size: 12px; color: var(--text-muted); letter-spacing: 2px; text-transform: uppercase; }
.auth-header { text-align: center; margin-bottom: 32px; }
.auth-header h1 { font-size: 28px; font-weight: 700; margin-bottom: 8px; }
.auth-header p { font-size: 15px; color: var(--text-secondary); }
.auth-footer { margin-top: 36px; text-align: center; font-size: 13px; color: var(--text-muted); }
.auth-footer a { color: var(--accent-gold); text-decoration: none; font-weight: 600; }
.auth-footer a:hover { text-decoration: underline; }
.auth-theme-toggle {
    position: fixed; top: 24px; right: 24px; z-index: 10;
    width: 42px; height: 42px; border-radius: var(--radius);
    border: 1px solid var(--border); background: var(--bg-card);
    color: var(--text-secondary); cursor: pointer;
    display: flex; align-items: center; justify-content: center; transition: all 0.2s; font-size: 16px;
}
.auth-theme-toggle:hover { border-color: var(--accent-gold); color: var(--accent-gold); }
.security-section { text-align: center; margin-top: 24px; }
.security-badge { display: inline-flex; align-items: center; gap: 6px; color: var(--accent-green); font-size: 13px; font-weight: 500; margin-bottom: 10px; }
.security-items { display: flex; justify-content: center; gap: 16px; flex-wrap: wrap; }
.security-item { display: flex; align-items: center; gap: 5px; font-size: 12px; color: var(--text-muted); }
.security-item i { color: var(--accent-green); font-size: 8px; }

/* ============ FORMS ============ */
.form-group { margin-bottom: 20px; }
.form-label { display: block; font-size: 13px; font-weight: 600; color: var(--text-secondary); margin-bottom: 8px; text-transform: uppercase; letter-spacing: 0.05em; }
.form-input {
    width: 100%; padding: 0.75rem 1rem;
    border: 2px solid var(--border); border-radius: var(--radius);
    background: var(--bg-input); color: var(--text-primary);
    font-size: 0.875rem; font-family: var(--font-body); transition: var(--transition); outline: none;
}
.form-input:focus { border-color: var(--accent-blue); box-shadow: 0 0 0 4px rgba(37,99,235,0.1); }
.form-input::placeholder { color: var(--text-muted); }
.form-select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23636b83' d='M6 8L1 3h10z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 40px; }
textarea.form-input { min-height: 90px; resize: vertical; }
.input-wrapper { position: relative; }
.input-icon { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--text-muted); cursor: pointer; background: none; border: none; padding: 4px; font-size: 15px; }
.input-icon:hover { color: var(--text-secondary); }
.form-options { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.form-options label { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--text-secondary); cursor: pointer; }
.form-options a { font-size: 14px; color: var(--accent-gold); font-weight: 600; text-decoration: none; }
.form-options a:hover { text-decoration: underline; }

/* ============ BUTTONS ============ */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 0.625rem 1.25rem; border-radius: var(--radius); border: none;
    font-size: 0.875rem; font-weight: 600; font-family: var(--font-heading);
    cursor: pointer; transition: var(--transition); text-decoration: none;
}
.btn-primary { background: #C42127; color: #fff; }
.btn-primary:hover { background: #a81b20; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(196,33,39,0.25); }
.btn-blue { background: var(--accent-blue); color: #fff; }
.btn-blue:hover { background: #1d4ed8; transform: translateY(-1px); }
.btn-secondary { background: var(--bg-card); color: var(--text-primary); border: 2px solid var(--border); }
.btn-secondary:hover { background: var(--bg-secondary); border-color: var(--text-muted); }
.btn-danger { background: var(--accent-red); color: #fff; }
.btn-danger:hover { background: #b91c1c; }
.btn-success { background: var(--accent-green); color: #fff; }
.btn-success:hover { background: #059669; }
.btn-purple { background: #7c3aed; color: #fff; }
.btn-purple:hover { background: #6d28d9; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(124,58,237,.25); }
.btn-gold { background: #f59e0b; color: #fff; }
.btn-gold:hover { background: #d97706; transform: translateY(-1px); }
.btn-sm { padding: 0.375rem 0.75rem; font-size: 0.8rem; }
.btn-block { width: 100%; padding: 0.875rem; font-size: 1rem; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; }
.btn-icon { padding: 0.625rem; border-radius: var(--radius); background: var(--bg-card); border: 2px solid var(--border); color: var(--text-secondary); cursor: pointer; transition: var(--transition); }
.btn-icon:hover { border-color: var(--accent-blue); color: var(--accent-blue); }
.btn-outline-gold { background: transparent; color: #C42127; border: 2px solid #C42127; }
.btn-outline-gold:hover { background: #C42127; color: #fff; }
.btn-view { padding: 5px 14px; border-radius: var(--radius); border: none; font-size: 0.75rem; font-weight: 600; background: var(--accent-blue); color: #fff; cursor: pointer; }
.btn-view:hover { background: #1d4ed8; }

/* ============ ADMIN LAYOUT ============ */
.app-layout { display: flex; min-height: 100vh; }
.sidebar {
    width: 68px; background: var(--sidebar-bg); border-right: 1px solid var(--border);
    display: flex; flex-direction: column; position: fixed; top: 0; left: 0; bottom: 0;
    z-index: 40; transition: width 0.3s; overflow: hidden;
}
.sidebar:hover, .sidebar.expanded, .sidebar.pinned { width: 260px; }
.sidebar-header { min-height: 80px; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 16px 12px 8px; border-bottom: 1px solid var(--border); overflow: hidden; white-space: nowrap; flex-shrink: 0; position: relative; }
.sidebar-header img { width: 44px; height: 44px; object-fit: contain; flex-shrink: 0; transition: var(--transition); }
.sidebar:hover .sidebar-header img, .sidebar.pinned .sidebar-header img { width: 120px; height: auto; }
.sidebar-header .brand { opacity: 0; transition: opacity 0.2s; text-align: center; width: 100%; }
.sidebar:hover .sidebar-header .brand, .sidebar.expanded .sidebar-header .brand, .sidebar.pinned .sidebar-header .brand { opacity: 1; }
.sidebar-header h1 { font-size: 13px; font-weight: 700; color: var(--text-primary); font-family: var(--font-heading); margin-top: 6px; }
.sidebar-header p { font-size: 10px; color: var(--text-muted); }
.sidebar-nav { flex: 1; overflow-y: scroll; overflow-x: hidden; padding: 14px 10px; scrollbar-width: thin; scrollbar-color: var(--border) transparent; }
.sidebar-nav::-webkit-scrollbar { width: 6px; }
.sidebar-nav::-webkit-scrollbar-track { background: transparent; }
.sidebar-nav::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
.sidebar-nav::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }
.sidebar-nav ul { list-style: none; }
.nav-item {
    display: flex; align-items: center; gap: 14px;
    padding: 10px 14px; border-radius: var(--radius);
    color: var(--sidebar-text); font-size: 0.875rem;
    cursor: pointer; transition: var(--transition); margin-bottom: 2px;
    text-decoration: none; white-space: nowrap; overflow: hidden; position: relative;
}
.nav-item:hover { color: var(--text-primary); background: var(--bg-secondary); }
.nav-item.active { color: var(--accent-blue); background: var(--sidebar-active); font-weight: 600; }
.nav-item.active::before { content: ''; position: absolute; left: 0; top: 4px; bottom: 4px; width: 3px; background: var(--accent-blue); border-radius: 0 2px 2px 0; }
.nav-item i { width: 20px; text-align: center; flex-shrink: 0; font-size: 15px; }
.nav-item span { opacity: 0; transition: opacity 0.2s; }
.sidebar:hover .nav-item span, .sidebar.expanded .nav-item span, .sidebar.pinned .nav-item span { opacity: 1; }
.sidebar-user { padding: 14px; border-top: 1px solid var(--border); white-space: nowrap; overflow: hidden; flex-shrink: 0; }
.user-info { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.user-avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--accent-gold); color: #000; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 14px; flex-shrink: 0; }
.user-name { font-size: 14px; font-weight: 500; color: #e8eaf0; }
.user-email { font-size: 12px; color: var(--sidebar-text); overflow: hidden; text-overflow: ellipsis; }
.user-details { opacity: 0; transition: opacity 0.2s; }
.sidebar:hover .user-details, .sidebar.expanded .user-details, .sidebar.pinned .user-details { opacity: 1; }
.logout-btn { display: flex; align-items: center; gap: 8px; width: 100%; padding: 8px 14px; border-radius: var(--radius); border: none; background: transparent; color: var(--sidebar-text); font-size: 14px; cursor: pointer; transition: all 0.2s; font-family: inherit; }
.logout-btn:hover { background: rgba(239,68,68,0.08); color: #f87171; }

.main-content { flex: 1; margin-left: 68px; transition: margin-left 0.3s; min-width: 0; }
.app-layout.sidebar-pinned .main-content { margin-left: 260px; }
.pin-btn { background: none; border: none; color: var(--text-muted); cursor: pointer; font-size: 14px; opacity: 0; transition: var(--transition); padding: 4px; margin-left: auto; flex-shrink: 0; position: absolute; top: 12px; right: 8px; }
.sidebar:hover .pin-btn, .sidebar.pinned .pin-btn { opacity: 1; }
.pin-btn:hover { color: var(--accent-blue); }
.sidebar.pinned .pin-btn { color: var(--accent-blue); }
.header { height: 68px; background: var(--bg-card); border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; padding: 0 28px; position: sticky; top: 0; z-index: 30; box-shadow: var(--shadow-sm); }
.header-left { display: flex; align-items: center; gap: 16px; }
.header-title { font-size: 20px; font-weight: 700; }
.header-actions { display: flex; align-items: center; gap: 10px; }
.menu-toggle { display: none; background: none; border: none; font-size: 20px; color: var(--text-primary); cursor: pointer; }
.page-content { padding: 28px; }

/* ============ STAT CARDS (NO colored borders) ============ */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 18px; margin-bottom: 28px; }
.stat-card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); padding: 1.5rem;
    box-shadow: var(--shadow-sm); transition: var(--transition);
}
.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.stat-card .stat-icon { font-size: 1.25rem; margin-bottom: 0.75rem; }
.stat-card .stat-value { font-size: 1.75rem; font-weight: 700; margin-bottom: 4px; line-height: 1.1; font-family: var(--font-heading); }
.stat-card .stat-label { font-size: 0.75rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.06em; }

/* ============ CARDS (NO colored borders) ============ */
.card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); overflow: hidden; transition: var(--transition);
}
.card:hover { box-shadow: var(--shadow-md); }
.card-header { padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; }
.card-header h3 { font-size: 0.95rem; font-weight: 600; display: flex; align-items: center; gap: 10px; font-family: var(--font-heading); }
.card-body { padding: 1.5rem; }

/* ============ TABLE ============ */
.table-container { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
thead th { padding: 12px 18px; text-align: left; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); background: var(--bg-main); border-bottom: 1px solid var(--border); }
tbody td { padding: 12px 18px; font-size: 14px; border-bottom: 1px solid var(--border); }
tbody tr { transition: background 0.15s; }
tbody tr:hover { background: var(--bg-card-hover); }

/* ============ BADGES ============ */
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 4px 12px; border-radius: 4px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; }
.badge-success { background: rgba(34,197,94,0.12); color: var(--accent-green); }
.badge-warning { background: rgba(245,158,11,0.12); color: var(--accent-orange); }
.badge-danger { background: rgba(239,68,68,0.12); color: var(--accent-red); }
.badge-info { background: rgba(59,130,246,0.12); color: var(--accent-blue); }
.badge-secondary { background: var(--bg-main); color: var(--text-secondary); }
.badge-gold { background: rgba(245,166,35,0.12); color: var(--accent-gold); }

/* ============ MODAL ============ */
.modal-overlay { position: fixed; inset: 0; z-index: 50; background: rgba(0,0,0,0.5); display: flex; align-items: center; justify-content: center; padding: 16px; animation: fadeIn 0.2s; backdrop-filter: blur(4px); }
.modal-overlay.hidden { display: none; }
.modal { background: var(--bg-card); border-radius: var(--radius-lg); width: 100%; max-width: 580px; max-height: 90vh; overflow-y: auto; box-shadow: var(--shadow-xl); border: 1px solid var(--border); animation: slideUp 0.3s ease; }
.modal-header { padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; }
.modal-header h3 { font-size: 1.1rem; font-weight: 600; font-family: var(--font-heading); }
.modal-close { background: none; border: none; font-size: 20px; color: var(--text-muted); cursor: pointer; padding: 4px; border-radius: var(--radius); }
.modal-close:hover { color: var(--accent-red); }
.modal-body { padding: 1.5rem; }
.modal-footer { padding: 1rem 1.5rem; border-top: 1px solid var(--border); display: flex; justify-content: flex-end; gap: 12px; }

/* ============ TOAST ============ */
.toast-container { position: fixed; top: 24px; right: 24px; z-index: 100; display: flex; flex-direction: column; gap: 10px; }
.toast { padding: 14px 22px; border-radius: var(--radius); font-size: 14px; font-weight: 500; display: flex; align-items: center; gap: 10px; min-width: 300px; box-shadow: var(--shadow-lg); animation: slideUp 0.3s; }
.toast-success { background: #065f46; color: #6ee7b7; border: 1px solid #10b981; }
.toast-error { background: #7f1d1d; color: #fca5a5; border: 1px solid #ef4444; }
.toast-info { background: #1e3a5f; color: #93c5fd; border: 1px solid #3b82f6; }
.error-alert { display: flex; align-items: center; gap: 10px; padding: 14px 18px; margin-bottom: 18px; background: rgba(239,68,68,0.06); border: 1px solid rgba(239,68,68,0.18); border-radius: var(--radius); color: var(--accent-red); font-size: 14px; }

/* ============ FILTERS ============ */
.filters-bar { display: flex; gap: 12px; margin-bottom: 24px; flex-wrap: wrap; align-items: center; }
.filters-bar .form-input, .filters-bar .form-select { max-width: 220px; padding: 10px 14px; font-size: 14px; }
.search-input { flex: 1; min-width: 200px; }

.empty-state { text-align: center; padding: 64px 20px; }
.empty-state i { font-size: 52px; color: var(--text-muted); margin-bottom: 18px; display: block; }
.empty-state h3 { font-size: 18px; margin-bottom: 8px; }
.empty-state p { color: var(--text-secondary); font-size: 14px; }

/* ============ STORE (always light) ============ */
.store-page { background: #f0f2f5; min-height: 100vh; color: #1a1d23; }
.store-topbar { background: #fff; border-bottom: 1px solid #e2e5ed; padding: 14px 28px; display: flex; align-items: center; justify-content: space-between; position: sticky; top: 0; z-index: 30; box-shadow: 0 1px 3px rgba(0,0,0,0.04); }
.store-topbar .logo-zone { display: flex; align-items: center; gap: 12px; }
.store-topbar .logo-zone img { height: 40px; }
.store-topbar .logo-zone h2 { font-size: 18px; font-weight: 700; color: #1a1d23; }
.store-topbar .right-zone { display: flex; align-items: center; gap: 14px; }
.cart-badge { display: flex; align-items: center; gap: 8px; padding: 10px 20px; background: #F5A623; color: #000; border-radius: var(--radius); font-weight: 600; font-size: 14px; cursor: pointer; border: none; transition: all 0.2s; }
.cart-badge:hover { background: #e09400; }
.store-hero-section { text-align: center; padding: 48px 24px 28px; }
.store-hero-section h1 { font-size: 30px; font-weight: 700; color: #1a1d23; margin-bottom: 8px; }
.store-hero-section p { font-size: 16px; color: #5a6178; }
.store-body { max-width: 1200px; margin: 0 auto; padding: 0 28px 56px; }
.store-filters-bar { display: flex; gap: 14px; margin-bottom: 28px; flex-wrap: wrap; }
.store-filters-bar input, .store-filters-bar select { padding: 12px 18px; border: 1px solid #d1d5db; border-radius: var(--radius); font-size: 15px; background: #fff; color: #1a1d23; outline: none; font-family: inherit; }
.store-filters-bar input:focus, .store-filters-bar select:focus { border-color: #F5A623; box-shadow: 0 0 0 3px rgba(245,166,35,0.1); }
.store-filters-bar input { flex: 1; min-width: 220px; }
.store-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 18px; }
.store-product-card { background: #fff; border: 1px solid #e2e5ed; border-radius: var(--radius); overflow: hidden; transition: transform 0.2s, box-shadow 0.2s; box-shadow: 0 1px 3px rgba(0,0,0,0.04); }
.store-product-card:hover { transform: translateY(-3px); box-shadow: 0 8px 28px rgba(0,0,0,0.1); }
.store-product-card .card-inner { padding: 20px; }
.store-product-card h3 { font-size: 16px; font-weight: 600; color: #1a1d23; margin-bottom: 6px; }
.store-product-card .sku { font-size: 12px; color: #9199af; margin-bottom: 10px; }
.store-product-card .price { font-size: 24px; font-weight: 700; color: #F5A623; margin-bottom: 6px; }
.store-product-card .stock-info { font-size: 13px; color: #5a6178; margin-bottom: 14px; }
.qty-ctrl { display: flex; align-items: center; gap: 10px; justify-content: center; }
.qty-btn { width: 34px; height: 34px; border-radius: var(--radius); border: 1px solid #d1d5db; background: #fff; color: #1a1d23; cursor: pointer; display: flex; align-items: center; justify-content: center; font-size: 18px; font-weight: 700; transition: all 0.15s; }
.qty-btn:hover { background: #F5A623; color: #000; border-color: #F5A623; }

/* ============ CHECKOUT ============ */
.checkout-page { background: #f0f2f5; min-height: 100vh; color: #1a1d23; }
.checkout-stepper { display: flex; align-items: center; justify-content: center; padding: 28px 16px 10px; max-width: 500px; margin: 0 auto; }
.step-item { display: flex; align-items: center; gap: 8px; }
.step-circle { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; border: 2px solid #d1d5db; color: #9199af; background: #fff; transition: all 0.3s; }
.step-circle.active, .step-circle.done { background: #F5A623; border-color: #F5A623; color: #000; }
.step-label { font-size: 12px; color: #9199af; font-weight: 600; }
.step-label.active { color: #1a1d23; }
.step-line { width: 52px; height: 2px; background: #d1d5db; margin: 0 6px; }
.step-line.done { background: #F5A623; }
.checkout-body { max-width: 960px; margin: 0 auto; padding: 28px; }
.checkout-layout { display: grid; grid-template-columns: 1fr 360px; gap: 28px; }
.ck-card { background: #fff; border: 1px solid #e2e5ed; border-radius: var(--radius); padding: 28px; box-shadow: 0 1px 4px rgba(0,0,0,0.04); }
.ck-card h3 { font-size: 17px; font-weight: 700; color: #1a1d23; margin-bottom: 18px; }
.cart-line { display: flex; align-items: center; gap: 14px; padding: 16px 0; border-bottom: 1px solid #f0f0f0; }
.cart-line:last-child { border-bottom: none; }
.cart-line .item-info { flex: 1; }
.cart-line .item-info h4 { font-size: 15px; font-weight: 600; color: #1a1d23; }
.cart-line .item-info p { font-size: 12px; color: #9199af; }
.cart-line .item-price { font-size: 16px; font-weight: 700; color: #1a1d23; white-space: nowrap; }
.summary-row { display: flex; justify-content: space-between; padding: 10px 0; font-size: 14px; color: #5a6178; }
.summary-row.total { border-top: 2px solid #1a1d23; padding-top: 14px; margin-top: 10px; font-size: 20px; font-weight: 700; color: #1a1d23; }

/* ============ CONFIRM ============ */
.confirm-page { background: #f0f2f5; min-height: 100vh; color: #1a1d23; display: flex; flex-direction: column; }
.confirm-box { max-width: 480px; margin: 56px auto; text-align: center; padding: 52px 36px; background: #fff; border-radius: var(--radius); box-shadow: 0 4px 24px rgba(0,0,0,0.06); }
.confirm-check { width: 80px; height: 80px; margin: 0 auto 28px; border-radius: 50%; border: 3px solid #F5A623; display: flex; align-items: center; justify-content: center; }
.confirm-check i { font-size: 32px; color: #F5A623; }
.confirm-box h2 { font-size: 26px; font-weight: 700; margin-bottom: 10px; }
.confirm-box .ref-label { font-size: 15px; color: #5a6178; }
.confirm-box .ref-value { font-size: 20px; font-weight: 700; color: #F5A623; letter-spacing: 1px; }

/* ============ TRACKING ============ */
.track-wrapper { max-width: 720px; margin: 0 auto; padding: 36px 24px; }
.timeline { position: relative; padding-left: 36px; }
.timeline::before { content: ''; position: absolute; left: 10px; top: 0; bottom: 0; width: 2px; background: var(--border); }
.tl-item { position: relative; margin-bottom: 22px; animation: fadeIn 0.3s ease; }
.tl-dot { position: absolute; left: -36px; top: 2px; width: 22px; height: 22px; border-radius: 50%; background: var(--bg-card); border: 2px solid var(--border); display: flex; align-items: center; justify-content: center; }
.tl-dot.active { background: #F5A623; border-color: #F5A623; }
.tl-dot.active i { color: #000; font-size: 9px; }
.tl-dot.cancel { background: #ef4444; border-color: #ef4444; }
.tl-dot.cancel i { color: #fff; }
.tl-content h4 { font-size: 14px; font-weight: 600; margin-bottom: 3px; }
.tl-content p { font-size: 13px; color: var(--text-secondary); }
.tl-content time { font-size: 12px; color: var(--text-muted); }

/* ============ COMMENTS ============ */
.comment-list { margin-top: 12px; }
.comment-item { padding: 14px; margin-bottom: 10px; background: var(--bg-main); border-radius: var(--radius); border-left: 3px solid var(--accent-gold); }
.comment-meta { display: flex; justify-content: space-between; margin-bottom: 6px; }
.comment-author { font-size: 13px; font-weight: 600; color: var(--accent-gold); }
.comment-date { font-size: 11px; color: var(--text-muted); }
.comment-text { font-size: 14px; color: var(--text-primary); line-height: 1.6; }

/* ============ PERMISSIONS ============ */
.perm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; margin-top: 14px; }
.perm-module { background: var(--bg-main); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px; }
.perm-module h4 { font-size: 12px; font-weight: 700; text-transform: uppercase; color: var(--accent-gold); margin-bottom: 10px; letter-spacing: 0.05em; }
.perm-module label { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-secondary); margin-bottom: 6px; cursor: pointer; }
.perm-module input[type="checkbox"] { accent-color: var(--accent-gold); width: 16px; height: 16px; }

/* ============ RESPONSIVE ============ */
@media (max-width: 1024px) { .auth-page { grid-template-columns: 1fr; } .auth-image { display: none; } .checkout-layout { grid-template-columns: 1fr; } }
@media (max-width: 768px) { .sidebar { transform: translateX(-100%); width: 250px; } .sidebar.mobile-open { transform: translateX(0); } .sidebar.mobile-open .nav-item span, .sidebar.mobile-open .user-details, .sidebar.mobile-open .sidebar-header .brand { opacity: 1; } .main-content { margin-left: 0; } .menu-toggle { display: block; } .stats-grid { grid-template-columns: repeat(2, 1fr); } .store-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); } .store-filters-bar { flex-direction: column; } }
@media (max-width: 480px) { .stats-grid { grid-template-columns: 1fr; } .page-content { padding: 18px; } .step-label { display: none; } }

/* ============ UTILITIES ============ */
.flex { display: flex; } .flex-col { flex-direction: column; } .items-center { align-items: center; }
.justify-between { justify-content: space-between; } .gap-2 { gap: 8px; } .gap-3 { gap: 12px; }
.gap-4 { gap: 16px; } .mb-2 { margin-bottom: 10px; } .mb-4 { margin-bottom: 18px; }
.mb-6 { margin-bottom: 28px; } .mt-4 { margin-top: 18px; } .text-center { text-align: center; }
.text-sm { font-size: 14px; } .text-xs { font-size: 12px; } .font-bold { font-weight: 700; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hidden { display: none !important; } .w-full { width: 100%; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media(max-width:640px) { .grid-2 { grid-template-columns: 1fr; } }
.text-gold { color: #F5A623; }
.text-green { color: #22c55e; }
.text-red { color: #ef4444; }
.text-blue { color: #3b82f6; }


/* Toggle switch */
.switch { position:relative;display:inline-block;width:44px;height:24px; }
.switch input { opacity:0;width:0;height:0; }
.slider { position:absolute;cursor:pointer;inset:0;background:#ccc;border-radius:24px;transition:.3s; }
.slider::before { content:'';position:absolute;height:18px;width:18px;left:3px;bottom:3px;background:#fff;border-radius:50%;transition:.3s; }
.switch input:checked + .slider { background:#F5A623; }
.switch input:checked + .slider::before { transform:translateX(20px); }

/* Export button group */
.btn-group-export { display:flex;gap:4px; }
.btn-group-export .btn { font-size:12px;padding:6px 12px; }

/* Filters wrap */
.filters-bar.flex-wrap { flex-wrap:wrap; }
.filters-bar .form-input { min-width:130px; }

/* Autocomplete dropdown */
.autocomplete-dropdown { position:absolute;z-index:999;background:var(--card-bg);border:1px solid var(--border-color);border-radius:6px;max-height:180px;overflow:auto;width:100%;box-shadow:0 4px 12px rgba(0,0,0,0.15); }
.autocomplete-item:hover { background:var(--hover-bg); }

/* Supplier orders */
.btn-lg { padding:14px 32px;font-size:16px; }
.comment-item { padding:14px 18px;margin-bottom:10px;background:var(--bg-main);border-radius:var(--radius);border-left:3px solid var(--accent-gold); }
.comment-meta { display:flex;justify-content:space-between;align-items:center;margin-bottom:6px;flex-wrap:wrap;gap:4px; }
.comment-author { font-weight:600;font-size:13px; }
.comment-date { font-size:11px;color:var(--text-muted); }
.comment-text { font-size:13px;color:var(--text-secondary);line-height:1.6; }
.comment-actions { margin-top:6px;display:flex;gap:6px;justify-content:flex-end; }
.comment-actions .btn-sm { font-size:11px;padding:3px 8px; }

/* Store page fix */
.store-page { min-height:100vh; }

/* Process flow */
.process-flow { display:flex;align-items:center;justify-content:center;padding:16px 8px;overflow-x:auto; }
.flow-step { display:flex;flex-direction:column;align-items:center;gap:6px;flex-shrink:0; }
.flow-dot { width:36px;height:36px;min-width:36px;min-height:36px;border-radius:50%;background:var(--border-color);display:flex;align-items:center;justify-content:center;font-size:14px;color:#fff;transition:all .3s; }
.flow-step.active .flow-dot { background:#F5A623; }
.flow-step.current .flow-dot { background:#3b82f6;box-shadow:0 0 0 4px rgba(59,130,246,0.3); }
.flow-step span { font-size:10px;color:var(--text-muted);white-space:nowrap;max-width:70px;text-align:center; }
.flow-step.active span { color:var(--text-primary);font-weight:600; }
.flow-line { width:32px;height:3px;min-width:32px;background:var(--border-color);margin:0 2px;margin-bottom:22px;flex-shrink:0; }
.flow-line.active { background:#F5A623; }

/* Dropzone */
.dropzone { border:2px dashed var(--border-color);border-radius:8px;padding:20px;text-align:center;cursor:pointer;transition:all .2s;color:var(--text-muted);display:flex;flex-direction:column;align-items:center;gap:8px; }
.dropzone:hover { border-color:#F5A623;background:rgba(245,166,35,0.05);color:var(--text-primary); }
.dropzone i { font-size:24px;color:#F5A623; }
.dropzone span { font-size:13px; }

/* Badge info and purple */
.badge-info { background:#0ea5e920;color:#0ea5e9; }
.badge-purple { background:#8b5cf620;color:#8b5cf6; }

/* Skeleton loading */
.skeleton { animation: skeleton-pulse 1.5s ease-in-out infinite; background: linear-gradient(90deg, var(--border-color) 25%, transparent 50%, var(--border-color) 75%); background-size: 200% 100%; border-radius: 6px; }
@keyframes skeleton-pulse { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.skel-card { background:var(--card-bg);border-radius:8px;padding:20px;margin-bottom:16px; }
.skel-line { height:14px;margin-bottom:10px;border-radius:4px; }
.skel-line.w50 { width:50%; }
.skel-line.w75 { width:75%; }
.skel-line.w100 { width:100%; }
.skel-block { height:120px;border-radius:8px;margin-bottom:16px; }
.skel-stat { height:80px;border-radius:8px; }
input[type="date"].form-input { min-width:140px;font-size:13px; }

/* Grid 3 columns */
.grid-3 { display:grid;grid-template-columns:repeat(3,1fr);gap:12px; }
@media (max-width: 768px) { .grid-3 { grid-template-columns:1fr; } }

/* Button gold */
.btn-gold { background:#C42127;color:#fff;font-weight:600; }
.btn-gold:hover { background:#a81b20; }

/* Portal Header/Footer */
.portal-header { background:#1a1d23;padding:20px 32px;display:flex;align-items:center;justify-content:space-between; }
.portal-header img { height:48px;object-fit:contain; }
.portal-header .portal-title { color:#F5A623;font-size:16px;font-weight:600; }
.portal-footer { background:#1a1d23;padding:24px 32px;margin-top:32px;color:#9ca3af;font-size:12px; }
.portal-footer a { color:#F5A623;text-decoration:none; }
.portal-footer .pf-row { display:flex;justify-content:space-between;align-items:center;flex-wrap:wrap;gap:12px; }
.portal-footer .pf-info { line-height:1.8; }


/* Dropzone */
.dropzone { padding: 1.5rem; text-align: center; border: 2px dashed var(--border); border-radius: var(--radius-lg); cursor: pointer; transition: var(--transition); background: var(--bg-secondary); }
.dropzone:hover { border-color: var(--accent-blue); background: rgba(37,99,235,0.04); }
.dropzone i { font-size: 1.5rem; color: var(--text-muted); }
.dropzone p { font-size: 0.8rem; color: var(--text-muted); margin-top: 0.5rem; }
