:root {
  --bg-app: #f4f7f6;
  --bg-sidebar: #0f172a;
  --bg-card: #ffffff;
  --color-border: #e2e8f0;
  --text: #1e293b;
  --muted: #64748b;
  --accent: #2563eb;
  --accent2: #4f46e5;
  --success: #10b981;
  --danger: #ef4444;
}
* { box-sizing: border-box; margin: 0; padding: 0; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; }
body { background: var(--bg-app); color: var(--text); display: flex; min-height: 100vh; overflow-x: hidden; }
.auth-screen { position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; background: var(--bg-app); display: flex; align-items: center; justify-content: center; z-index: 100; }
.auth-box { background: var(--bg-card); padding: 40px; border-radius: 8px; box-shadow: 0 4px 12px rgba(0,0,0,0.05); width: 360px; }
.auth-logo { font-size: 24px; font-weight: 700; margin-bottom: 24px; text-align: center; color: var(--accent); }
input[type="text"], input[type="email"], input[type="password"] { width: 100%; padding: 12px; border: 1px solid var(--color-border); border-radius: 6px; margin-bottom: 16px; outline: none; font-size: 14px; }
input:focus { border-color: var(--accent); }
.btn-primary { background: var(--accent); color: white; border: none; padding: 12px; border-radius: 6px; font-size: 14px; font-weight: 600; cursor: pointer; width: 100%; transition: opacity 0.2s; }
.btn-primary:hover { opacity: 0.9; }
.auth-error { background: #fee2e2; color: var(--danger); padding: 10px; border-radius: 6px; font-size: 13px; text-align: center; margin-top: 12px; }
.hidden { display: none !important; }
.dashboard { display: flex; width: 100%; }
.sidebar { width: 240px; background: var(--bg-sidebar); color: white; padding: 24px 16px; display: flex; flex-direction: column; height: 100vh; position: fixed; }
.sidebar-logo { font-size: 20px; font-weight: 700; margin-bottom: 40px; color: var(--accent); }
.nav-link { display: flex; align-items: center; gap: 12px; color: #94a3b8; text-decoration: none; padding: 12px; border-radius: 6px; font-size: 14px; font-weight: 500; cursor: pointer; margin-bottom: 8px; }
.nav-link:hover, .nav-link.active { background: #1e293b; color: white; }
.nav-icon { width: 18px; height: 18px; stroke: currentColor; }
.app-content { margin-left: 240px; flex: 1; min-height: 100vh; display: flex; flex-direction: column; }
.topbar { background: var(--bg-card); padding: 16px 32px; border-bottom: 1px solid var(--color-border); display: flex; justify-content: space-between; align-items: center; }
.menu-toggle { display: none; }
.user-menu { display: flex; align-items: center; gap: 10px; cursor: pointer; }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--accent); color: white; display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 14px; }
.main { padding: 32px; width: 100%; max-width: 1200px; margin: 0 auto; }
.stores-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 24px; }
.store-card { background: var(--bg-card); border-radius: 8px; border: 1px solid var(--color-border); padding: 20px; cursor: pointer; transition: transform 0.2s, box-shadow 0.2s; }
.store-card:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.02); }
.store-card-name { font-weight: 600; font-size: 16px; margin-bottom: 4px; }
.store-card-domain { color: var(--muted); font-size: 13px; }
.store-card-badges { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0; }
.badge { background: #f1f5f9; color: var(--muted); font-size: 11px; padding: 4px 8px; border-radius: 4px; font-weight: 500; }
.badge.country { background: #dbeafe; color: var(--accent); }
.badge.theme { background: #fef3c7; color: #d97706; }
.store-card-stats { display: flex; justify-content: space-between; background: #f8fafc; padding: 12px; border-radius: 6px; margin-top: 14px; }
.stat-box { display: flex; flex-direction: column; gap: 2px; }
.stat-lbl { font-size: 11px; color: var(--muted); }
.stat-val { font-size: 14px; font-weight: 600; }
.modal { position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; background: rgba(15,23,42,0.4); display: flex; align-items: center; justify-content: center; z-index: 1000; }
.modal-content { background: var(--bg-card); padding: 32px; border-radius: 8px; width: 440px; box-shadow: 0 20px 25px -5px rgba(0,0,0,0.1); }
.modal-actions { display: flex; justify-content: flex-end; gap: 12px; margin-top: 16px; }
.btn-secondary { background: #f1f5f9; color: var(--text); border: none; padding: 10px 16px; border-radius: 6px; font-weight: 500; cursor: pointer; }
.btn-sm { padding: 4px 8px; font-size: 12px; border: none; border-radius: 4px; font-weight: 500; cursor: pointer; }
.btn-secondary-sm { background: #f1f5f9; color: var(--text); }
.btn-danger-sm { background: #fee2e2; color: var(--danger); }
.detail-panel { position: fixed; top: 0; right: 0; width: 50%; height: 100vh; background: var(--bg-card); box-shadow: -10px 0 30px rgba(0,0,0,0.05); z-index: 500; display: flex; flex-direction: column; padding: 32px; overflow-y: auto; }
.detail-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 24px; padding-bottom: 16px; border-bottom: 1px solid var(--color-border); }
.detail-name { font-size: 22px; font-weight: 700; margin-bottom: 4px; }
.store-ad-btn { text-decoration: none; color: var(--accent); font-size: 13px; font-weight: 600; }
.detail-hero { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 24px; }
.hero-card { background: #f8fafc; padding: 16px; border-radius: 8px; text-align: center; }
.hero-card .label { font-size: 11px; color: var(--muted); margin-bottom: 4px; text-transform: uppercase; letter-spacing: 0.5px; }
.hero-card .value { font-size: 20px; font-weight: 700; }
.detail-grid { display: flex; flex-direction: column; gap: 24px; }
.detail-card { background: var(--bg-card); border: 1px solid var(--color-border); border-radius: 8px; padding: 20px; }
.detail-card h3 { font-size: 14px; color: var(--muted); margin-bottom: 16px; text-transform: uppercase; letter-spacing: 0.5px; }
.info-row { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid #f1f5f9; font-size: 14px; }
.info-row:last-child { border-bottom: none; }
.info-row .key { color: var(--muted); }
.info-row .val { font-weight: 500; }
.product-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid #f1f5f9; }
.product-img-sm { width: 40px; height: 40px; border-radius: 4px; object-fit: cover; }
.product-info-sm { flex: 1; min-width: 0; }
.product-title-sm { font-weight: 500; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.product-meta-sm { font-size: 11px; color: var(--muted); }
.product-price-sm, .product-orders-sm, .product-revenue-sm, .product-daily-sm { font-size: 12px; font-weight: 500; text-align: right; width: 60px; }
.admin-table, .history-table { width: 100%; border-collapse: collapse; margin-top: 12px; }
.admin-table th, .admin-table td, .history-table th, .history-table td { text-align: left; padding: 12px; font-size: 13px; border-bottom: 1px solid var(--color-border); }
.admin-table th, .history-table th { background: #f8fafc; color: var(--muted); font-weight: 500; }
.checkbox-label { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; margin-bottom: 16px; color: var(--muted); }
