@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  --background: hsl(210, 20%, 98%);
  --foreground: hsl(220, 30%, 15%);
  --card: hsl(0, 0%, 100%);
  --card-foreground: hsl(220, 30%, 15%);
  --popover: hsl(0, 0%, 100%);
  --popover-foreground: hsl(220, 30%, 15%);
  --primary: hsl(221, 83%, 53%);
  --primary-foreground: hsl(0, 0%, 100%);
  --secondary: hsl(214, 32%, 91%);
  --secondary-foreground: hsl(220, 30%, 25%);
  --muted: hsl(210, 20%, 96%);
  --muted-foreground: hsl(215, 16%, 47%);
  --accent: hsl(221, 83%, 96%);
  --accent-foreground: hsl(221, 83%, 40%);
  --destructive: hsl(0, 84%, 60%);
  --destructive-foreground: hsl(0, 0%, 100%);
  --success: hsl(142, 71%, 45%);
  --success-foreground: hsl(0, 0%, 100%);
  --warning: hsl(38, 92%, 50%);
  --warning-foreground: hsl(0, 0%, 100%);
  --info: hsl(199, 89%, 48%);
  --info-foreground: hsl(0, 0%, 100%);
  --border: hsl(214, 32%, 91%);
  --input: hsl(214, 32%, 91%);
  --ring: hsl(221, 83%, 53%);
  --radius: 0.75rem;
  --sidebar-background: hsl(0, 0%, 100%);
  --sidebar-foreground: hsl(220, 15%, 40%);
  --sidebar-primary: hsl(221, 83%, 53%);
  --sidebar-accent: hsl(221, 83%, 96%);
  --sidebar-accent-foreground: hsl(221, 83%, 53%);
  --sidebar-border: hsl(220, 20%, 94%);
  --sidebar-muted: hsl(220, 15%, 60%);
  --gradient-primary: linear-gradient(135deg, hsl(221, 83%, 53%), hsl(240, 80%, 62%));
  --gradient-hero: linear-gradient(135deg, hsl(221, 83%, 53%), hsl(199, 89%, 48%));
  --gradient-card: linear-gradient(135deg, hsl(221, 83%, 96%), hsl(0, 0%, 100%));
  --shadow-card: 0 1px 3px hsla(220, 30%, 15%, 0.06), 0 1px 2px hsla(220, 30%, 15%, 0.04);
  --shadow-card-hover: 0 10px 25px -5px hsla(221, 83%, 53%, 0.1), 0 8px 10px -6px hsla(220, 30%, 15%, 0.05);
  --shadow-lg: 0 10px 25px -5px hsla(221, 83%, 53%, 0.1), 0 8px 10px -6px hsla(220, 30%, 15%, 0.05);
  --font-display: 'Plus Jakarta Sans', sans-serif;
  --font-body: 'Inter', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; border: 0 solid var(--border); }
html { line-height: 1.5; -webkit-text-size-adjust: 100%; }
body { font-family: var(--font-body); background: var(--background); color: var(--foreground); min-height: 100vh; }
h1, h2, h3, h4, h5, h6 { font-family: var(--font-display); }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button, input, select, textarea { font-family: inherit; font-size: inherit; }
button { cursor: pointer; }
table { border-collapse: collapse; width: 100%; }

/* ═══════ Utilities ═══════ */
.font-display { font-family: var(--font-display); }
.font-body { font-family: var(--font-body); }
.text-gradient { background: var(--gradient-primary); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.bg-gradient-primary { background: var(--gradient-primary); }
.bg-gradient-hero { background: var(--gradient-hero); }
.bg-gradient-card { background: var(--gradient-card); }
.shadow-card { box-shadow: var(--shadow-card); }
.shadow-card-hover { box-shadow: var(--shadow-card-hover); }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.line-clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ═══════ Layout ═══════ */
.dashboard-layout { display: flex; min-height: 100vh; width: 100%; background: var(--background); }
.main-content { flex: 1; display: flex; flex-direction: column; min-width: 0; }

/* ═══════ Sidebar ═══════ */
.sidebar {
  height: 100vh; position: sticky; top: 0; display: flex; flex-direction: column;
  background: var(--sidebar-background); border-right: 1px solid var(--sidebar-border);
  width: 250px; transition: width 0.3s ease;
}
.sidebar.collapsed { width: 68px; }
.sidebar-logo {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 16px; height: 64px; border-bottom: 1px solid var(--sidebar-border);
}
.sidebar-logo-icon {
  width: 32px; height: 32px; border-radius: 12px; background: var(--gradient-primary);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.sidebar-logo-icon span { color: var(--primary-foreground); font-family: var(--font-display); font-weight: 700; font-size: 14px; }
.sidebar-logo-text { font-family: var(--font-display); font-weight: 700; color: var(--foreground); font-size: 18px; letter-spacing: -0.02em; margin-left: 10px; }
.sidebar.collapsed .sidebar-logo-text,
.sidebar.collapsed .sidebar-group-label,
.sidebar.collapsed .nav-item-text,
.sidebar.collapsed .user-info,
.sidebar.collapsed .logout-btn { display: none; }
.sidebar.collapsed .sidebar-logo-icon { margin: 0 auto; }

.sidebar-toggle {
  position: absolute; right: -12px; top: 80px; z-index: 50;
  width: 24px; height: 24px; border-radius: 50%;
  background: var(--card); border: 1px solid var(--border);
  box-shadow: var(--shadow-card); display: flex; align-items: center; justify-content: center;
  color: var(--foreground); font-size: 12px; transition: background 0.2s;
}
.sidebar-toggle:hover { background: var(--muted); }

.sidebar-nav { flex: 1; overflow-y: auto; padding: 20px 0; }
.sidebar-group { margin-bottom: 20px; }
.sidebar-group-label {
  padding: 0 20px; margin-bottom: 8px; font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.08em; color: var(--sidebar-muted);
}
.sidebar-group nav { padding: 0 12px; display: flex; flex-direction: column; gap: 4px; }

.nav-item {
  display: flex; align-items: center; gap: 12px; padding: 10px 12px;
  border-radius: 12px; font-size: 13px; font-weight: 500;
  color: var(--sidebar-foreground); transition: all 0.2s; text-decoration: none;
}
.nav-item:hover { background: hsla(221, 83%, 96%, 0.5); color: var(--sidebar-accent-foreground); }
.nav-item.active {
  background: var(--sidebar-accent); color: var(--sidebar-accent-foreground);
  box-shadow: 0 1px 2px hsla(220, 30%, 15%, 0.05);
}
.nav-item i, .nav-item .lucide { font-size: 18px; flex-shrink: 0; stroke-width: 1.8; width: 18px; height: 18px; }
.sidebar.collapsed .nav-item { justify-content: center; padding: 10px; }

.sidebar-user {
  border-top: 1px solid var(--sidebar-border); padding: 12px;
  display: flex; align-items: center; gap: 12px;
}
.sidebar.collapsed .sidebar-user { justify-content: center; }
.user-avatar {
  width: 36px; height: 36px; border-radius: 50%; background: var(--gradient-primary);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.user-avatar span { color: var(--primary-foreground); font-weight: 600; font-size: 14px; }
.user-info { flex: 1; min-width: 0; }
.user-info .name { font-size: 14px; font-weight: 500; color: var(--foreground); }
.user-info .role { font-size: 12px; color: var(--sidebar-muted); }
.logout-btn {
  color: var(--sidebar-muted); background: none; padding: 4px;
  border-radius: 6px; transition: color 0.2s; display: flex; align-items: center;
}
.logout-btn:hover { color: var(--foreground); }

/* ═══════ Header ═══════ */
.app-header {
  height: 64px; border-bottom: 1px solid var(--border);
  background: hsla(0, 0%, 100%, 0.8); backdrop-filter: blur(12px);
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; justify-content: space-between; padding: 0 24px;
}
.app-header h1 { font-family: var(--font-display); font-size: 20px; font-weight: 700; color: var(--foreground); }
.app-header .subtitle { font-size: 12px; color: var(--muted-foreground); }
.header-actions { display: flex; align-items: center; gap: 12px; }
.header-search {
  position: relative; width: 256px;
}
.header-search input {
  width: 100%; height: 36px; padding: 0 12px 0 36px;
  background: hsla(210, 20%, 96%, 0.5); border: none; border-radius: 8px;
  font-size: 14px; color: var(--foreground); outline: none;
}
.header-search i, .header-search .lucide { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted-foreground); pointer-events: none; }
.icon-btn {
  position: relative; background: none; padding: 8px; border-radius: 8px;
  color: var(--muted-foreground); transition: all 0.2s; display: flex; align-items: center;
}
.icon-btn:hover { background: var(--muted); color: var(--foreground); }
.notification-dot {
  position: absolute; top: 6px; right: 6px; width: 8px; height: 8px;
  border-radius: 50%; background: var(--destructive);
}
.header-avatar {
  width: 32px; height: 32px; border-radius: 50%; background: var(--gradient-primary);
  display: flex; align-items: center; justify-content: center; margin-left: 4px;
}
.header-avatar span { color: var(--primary-foreground); font-weight: 600; font-size: 12px; }

/* ═══════ Buttons ═══════ */
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 16px; border-radius: 8px; font-size: 14px; font-weight: 500;
  transition: all 0.2s; border: none; cursor: pointer; text-decoration: none;
  white-space: nowrap;
}
.btn-sm { padding: 6px 12px; font-size: 13px; }
.btn-lg { padding: 12px 32px; font-size: 16px; font-weight: 600; }
.btn-primary { background: var(--gradient-primary); color: var(--primary-foreground); box-shadow: 0 4px 12px hsla(221, 83%, 53%, 0.3); }
.btn-primary:hover { opacity: 0.9; }
.btn-outline { background: transparent; border: 1px solid var(--border); color: var(--foreground); }
.btn-outline:hover { background: var(--muted); }
.btn-ghost { background: transparent; color: var(--muted-foreground); }
.btn-ghost:hover { background: var(--muted); color: var(--foreground); }
.btn-icon { padding: 8px; }
.btn-icon.sm { padding: 4px; width: 32px; height: 32px; }
.btn-rounded { border-radius: 9999px; }

/* ═══════ Cards ═══════ */
.card {
  background: var(--card); border-radius: 12px; padding: 20px;
  box-shadow: var(--shadow-card); border: 1px solid var(--border);
}
.card:hover { box-shadow: var(--shadow-card-hover); }
.card-title { font-family: var(--font-display); font-weight: 600; color: var(--foreground); margin-bottom: 4px; }
.card-subtitle { font-size: 12px; color: var(--muted-foreground); margin-bottom: 16px; }

/* ═══════ Stat Card ═══════ */
.stat-card {
  background: var(--card); border-radius: 12px; padding: 20px;
  box-shadow: var(--shadow-card); border: 1px solid var(--border);
  transition: box-shadow 0.3s;
}
.stat-card:hover { box-shadow: var(--shadow-card-hover); }
.stat-card-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.stat-card-title { font-size: 14px; color: var(--muted-foreground); font-weight: 500; }
.stat-card-icon {
  width: 40px; height: 40px; border-radius: 8px; background: var(--accent);
  display: flex; align-items: center; justify-content: center;
}
.stat-card-icon i, .stat-card-icon .lucide { color: var(--primary); }
.stat-card-value { font-family: var(--font-display); font-size: 24px; font-weight: 700; color: var(--foreground); }
.stat-card-change { font-size: 12px; font-weight: 500; margin-top: 4px; }
.stat-card-change.up { color: var(--success); }
.stat-card-change.down { color: var(--destructive); }

/* ═══════ Data Table ═══════ */
.data-table {
  background: var(--card); border-radius: 12px;
  box-shadow: var(--shadow-card); border: 1px solid var(--border); overflow: hidden;
}
.data-table table { width: 100%; }
.data-table thead tr { border-bottom: 1px solid var(--border); background: hsla(210, 20%, 96%, 0.5); }
.data-table th {
  text-align: left; padding: 12px 20px; font-size: 12px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted-foreground);
}
.data-table tbody tr { border-bottom: 1px solid var(--border); transition: background 0.2s; }
.data-table tbody tr:last-child { border-bottom: none; }
.data-table tbody tr:hover { background: hsla(210, 20%, 96%, 0.3); }
.data-table td { padding: 14px 20px; font-size: 14px; color: var(--foreground); }
.data-table .font-medium { font-weight: 500; }
.data-table .text-muted { color: var(--muted-foreground); }

/* ═══════ Badges ═══════ */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 10px; border-radius: 9999px; font-size: 12px; font-weight: 500;
}
.badge-active, .badge-approved { background: hsla(142, 71%, 45%, 0.1); color: var(--success); }
.badge-pending { background: hsla(38, 92%, 50%, 0.1); color: var(--warning); }
.badge-inactive { background: var(--muted); color: var(--muted-foreground); }
.badge-rejected { background: hsla(0, 84%, 60%, 0.1); color: var(--destructive); }
.badge-primary { background: hsla(221, 83%, 53%, 0.1); color: var(--primary); }
.badge-info { background: hsla(199, 89%, 48%, 0.1); color: var(--info); }
.badge-success { background: hsla(142, 71%, 45%, 0.1); color: var(--success); }
.badge-warning { background: hsla(38, 92%, 50%, 0.1); color: var(--warning); }
.badge-destructive { background: hsla(0, 84%, 60%, 0.1); color: var(--destructive); }
.badge-accent { background: var(--accent); color: var(--accent-foreground); font-size: 12px; font-weight: 500; }

/* ═══════ Form Elements ═══════ */
.form-group { margin-bottom: 16px; }
.form-label { display: block; font-size: 14px; font-weight: 600; color: var(--foreground); margin-bottom: 8px; }
.form-input {
  width: 100%; height: 48px; padding: 0 16px;
  background: var(--card); border: 1px solid var(--border); border-radius: 12px;
  font-size: 14px; color: var(--foreground); outline: none; transition: all 0.2s;
}
.form-input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px hsla(221, 83%, 53%, 0.1); }
.form-input.with-icon { padding-left: 44px; }
.form-input-wrapper { position: relative; }
.form-input-wrapper i,
.form-input-wrapper .input-icon {
  position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
  color: var(--muted-foreground); width: 16px; height: 16px;
}
.form-input-wrapper .input-right {
  position: absolute; right: 16px; top: 50%; transform: translateY(-50%);
  color: var(--muted-foreground); background: none; border: none; cursor: pointer;
  padding: 4px; display: flex;
}
.form-input-wrapper .input-right:hover { color: var(--foreground); }

/* ═══════ Switch Toggle ═══════ */
.switch {
  position: relative; width: 44px; height: 24px; cursor: pointer;
}
.switch input { opacity: 0; width: 0; height: 0; }
.switch-slider {
  position: absolute; inset: 0; background: var(--muted);
  border-radius: 12px; transition: background 0.3s;
}
.switch-slider::before {
  content: ''; position: absolute; width: 18px; height: 18px;
  left: 3px; bottom: 3px; background: white; border-radius: 50%;
  transition: transform 0.3s;
}
.switch input:checked + .switch-slider { background: var(--primary); }
.switch input:checked + .switch-slider::before { transform: translateX(20px); }

/* ═══════ Separator ═══════ */
.separator { height: 1px; background: var(--border); margin: 24px 0; }
.separator.vertical { width: 1px; height: auto; margin: 0 12px; }

/* ═══════ Grid System ═══════ */
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.gap-4 { gap: 16px; }
.gap-6 { gap: 24px; }
.flex-1 { flex: 1; }
.min-w-0 { min-width: 0; }
.flex-shrink-0 { flex-shrink: 0; }
.w-full { width: 100%; }

/* ═══════ Spacing ═══════ */
.p-4 { padding: 16px; }
.p-5 { padding: 20px; }
.p-6 { padding: 24px; }
.px-5 { padding-left: 20px; padding-right: 20px; }
.py-3 { padding-top: 12px; padding-bottom: 12px; }
.mb-1 { margin-bottom: 4px; }
.mb-2 { margin-bottom: 8px; }
.mb-3 { margin-bottom: 12px; }
.mb-4 { margin-bottom: 16px; }
.mt-1 { margin-top: 4px; }
.mt-2 { margin-top: 8px; }
.mt-4 { margin-top: 16px; }
.space-y-3 > * + * { margin-top: 12px; }
.space-y-4 > * + * { margin-top: 16px; }
.space-y-6 > * + * { margin-top: 24px; }

/* ═══════ Text ═══════ */
.text-xs { font-size: 12px; }
.text-sm { font-size: 14px; }
.text-lg { font-size: 18px; }
.text-xl { font-size: 20px; }
.text-2xl { font-size: 24px; }
.text-3xl { font-size: 30px; }
.text-4xl { font-size: 36px; }
.text-5xl { font-size: 48px; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.font-extrabold { font-weight: 800; }
.text-foreground { color: var(--foreground); }
.text-muted-foreground { color: var(--muted-foreground); }
.text-primary { color: var(--primary); }
.text-primary-foreground { color: var(--primary-foreground); }
.text-success { color: var(--success); }
.text-destructive { color: var(--destructive); }
.text-warning { color: var(--warning); }
.text-info { color: var(--info); }
.text-center { text-align: center; }
.uppercase { text-transform: uppercase; }
.tracking-wider { letter-spacing: 0.05em; }
.tracking-widest { letter-spacing: 0.08em; }
.leading-tight { line-height: 1.1; }
.leading-relaxed { line-height: 1.6; }
.font-mono { font-family: 'SF Mono', 'Fira Code', monospace; }

/* ═══════ Borders & Radius ═══════ */
.rounded-lg { border-radius: 8px; }
.rounded-xl { border-radius: 12px; }
.rounded-2xl { border-radius: 16px; }
.rounded-3xl { border-radius: 24px; }
.rounded-full { border-radius: 9999px; }
.border { border: 1px solid var(--border); }
.border-b { border-bottom: 1px solid var(--border); }
.border-t { border-top: 1px solid var(--border); }

/* ═══════ Page Content ═══════ */
.page-content { padding: 24px; }
.page-content .space-y-4 > * + * { margin-top: 16px; }
.page-content .space-y-6 > * + * { margin-top: 24px; }

.toolbar {
  display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; align-items: center;
}
.search-box { position: relative; flex: 1; max-width: 400px; }
.search-box input {
  width: 100%; height: 40px; padding: 0 12px 0 36px;
  background: var(--card); border: 1px solid var(--border); border-radius: 8px;
  font-size: 14px; color: var(--foreground); outline: none;
}
.search-box i {
  position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
  color: var(--muted-foreground);
}
.toolbar-actions { display: flex; gap: 8px; }

/* ═══════ Product Cards ═══════ */
.product-card {
  background: var(--card); border-radius: 12px; box-shadow: var(--shadow-card);
  border: 1px solid var(--border); overflow: hidden; transition: box-shadow 0.3s;
}
.product-card:hover { box-shadow: var(--shadow-card-hover); }
.product-image {
  height: 144px; background: var(--gradient-card);
  display: flex; align-items: center; justify-content: center;
}
.product-image i, .product-image .lucide { color: hsla(221, 83%, 53%, 0.3); }
.product-body { padding: 16px; }

/* ═══════ Scan Area ═══════ */
.scan-area {
  background: var(--card); border-radius: 12px; padding: 32px;
  box-shadow: var(--shadow-card); border: 1px solid var(--border); text-align: center;
}
.scan-icon {
  width: 80px; height: 80px; border-radius: 16px; background: var(--accent);
  display: flex; align-items: center; justify-content: center; margin: 0 auto 16px;
}

/* ═══════ Chart Placeholder ═══════ */
.chart-container { width: 100%; position: relative; }
.chart-bars { display: flex; align-items: flex-end; gap: 6px; height: 260px; padding: 0 20px 30px; }
.chart-bar {
  flex: 1; background: var(--primary); border-radius: 4px 4px 0 0;
  transition: height 0.5s ease; min-width: 20px; position: relative;
}
.chart-bar.secondary { background: var(--info); }
.chart-bar-label {
  position: absolute; bottom: -24px; left: 50%; transform: translateX(-50%);
  font-size: 11px; color: var(--muted-foreground); white-space: nowrap;
}
.chart-line-container { height: 260px; position: relative; padding: 0 20px; }
.chart-donut {
  width: 180px; height: 180px; border-radius: 50%; margin: 0 auto;
  background: conic-gradient(
    var(--primary) 0% 48%,
    var(--info) 48% 81%,
    var(--muted) 81% 100%
  );
  position: relative; display: flex; align-items: center; justify-content: center;
}
.chart-donut::after {
  content: ''; width: 110px; height: 110px; border-radius: 50%;
  background: var(--card); position: absolute;
}
.chart-legend { display: flex; flex-direction: column; gap: 8px; margin-top: 16px; }
.chart-legend-item { display: flex; align-items: center; gap: 8px; font-size: 12px; }
.chart-legend-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }

/* ═══════ Landing Page ═══════ */
.landing-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  border-bottom: 1px solid hsla(0, 0%, 100%, 0.1);
  background: hsla(0, 0%, 100%, 0.05); backdrop-filter: blur(24px);
}
.landing-nav-inner {
  max-width: 1280px; margin: 0 auto; display: flex; align-items: center;
  justify-content: space-between; padding: 0 24px; height: 64px;
}
.nav-links { display: flex; align-items: center; gap: 32px; font-size: 14px; font-weight: 500; color: var(--muted-foreground); }
.nav-links a:hover { color: var(--primary); }

.hero-section {
  position: relative; min-height: 92vh; display: flex; align-items: center;
  overflow: hidden; padding-top: 64px;
}
.hero-bg {
  position: absolute; inset: 0; background: var(--gradient-primary); opacity: 0.08;
}
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to right, var(--background), hsla(210, 20%, 98%, 0.85), hsla(210, 20%, 98%, 0.6));
}
.hero-inner { position: relative; z-index: 10; max-width: 1280px; margin: 0 auto; padding: 0 24px; width: 100%; }
.hero-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 16px;
  border-radius: 9999px; background: hsla(221, 83%, 53%, 0.1);
  border: 1px solid hsla(221, 83%, 53%, 0.2); font-size: 14px; font-weight: 500;
  color: var(--primary); margin-bottom: 32px;
}
.hero-title {
  font-family: var(--font-display); font-size: 60px; font-weight: 800;
  color: var(--foreground); line-height: 1.1; letter-spacing: -0.02em; margin-bottom: 16px;
}
.hero-desc { font-size: 18px; color: var(--muted-foreground); max-width: 512px; line-height: 1.6; margin-bottom: 32px; }
.hero-actions { display: flex; gap: 16px; margin-bottom: 32px; }
.hero-trust { display: flex; gap: 24px; font-size: 14px; color: var(--muted-foreground); }
.hero-trust span { display: flex; align-items: center; gap: 6px; }

.hero-preview {
  background: hsla(0, 0%, 100%, 0.9); backdrop-filter: blur(24px);
  border-radius: 16px; border: 1px solid var(--border); box-shadow: 0 20px 60px hsla(220, 30%, 15%, 0.1);
  overflow: hidden; padding: 6px;
}
.hero-preview-inner { border-radius: 12px; background: hsla(210, 20%, 96%, 0.3); padding: 20px; }
.hero-stat-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-bottom: 12px; }
.hero-stat-card {
  background: var(--card); border-radius: 12px; padding: 14px; border: 1px solid var(--border);
}
.hero-stat-label { font-size: 11px; color: var(--muted-foreground); margin-bottom: 8px; }
.hero-stat-value { font-family: var(--font-display); font-size: 18px; font-weight: 700; color: var(--foreground); }
.hero-stat-trend { font-size: 10px; color: var(--success); font-weight: 500; }
.hero-chart {
  background: var(--card); border-radius: 12px; height: 128px; border: 1px solid var(--border);
  display: flex; align-items: flex-end; justify-content: center; padding: 16px;
}
.hero-chart-bar { width: 12px; border-radius: 2px; background: hsla(221, 83%, 53%, 0.7); margin: 0 3px; }

.stats-section { padding: 64px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--card); }
.stats-grid { max-width: 1280px; margin: 0 auto; padding: 0 24px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.stat-item { text-align: center; }
.stat-value { font-family: var(--font-display); font-size: 36px; font-weight: 800; }
.stat-label { font-size: 14px; color: var(--muted-foreground); margin-top: 4px; }

.section { padding: 96px 0; }
.section-inner { max-width: 1280px; margin: 0 auto; padding: 0 24px; }
.section-header { text-align: center; margin-bottom: 64px; }
.section-badge {
  display: inline-flex; align-items: center; gap: 8px; padding: 4px 12px;
  border-radius: 9999px; background: var(--accent); font-size: 12px; font-weight: 500;
  color: var(--accent-foreground); margin-bottom: 16px;
}
.section-title { font-family: var(--font-display); font-size: 36px; font-weight: 700; color: var(--foreground); margin-bottom: 16px; }
.section-desc { color: var(--muted-foreground); max-width: 560px; margin: 0 auto; }

.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.feature-card {
  background: var(--card); border-radius: 16px; padding: 24px; border: 1px solid var(--border);
  transition: all 0.3s;
}
.feature-card:hover { border-color: hsla(221, 83%, 53%, 0.3); box-shadow: var(--shadow-lg); }
.feature-icon {
  width: 48px; height: 48px; border-radius: 12px; background: var(--accent);
  display: flex; align-items: center; justify-content: center; margin-bottom: 16px;
  transition: background 0.3s;
}
.feature-card:hover .feature-icon { background: hsla(221, 83%, 53%, 0.1); }
.feature-icon i, .feature-icon .lucide { color: var(--primary); }
.feature-title { font-family: var(--font-display); font-weight: 600; font-size: 18px; color: var(--foreground); margin-bottom: 8px; }
.feature-desc { font-size: 14px; color: var(--muted-foreground); line-height: 1.6; }

.events-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.event-card {
  background: var(--background); border-radius: 16px; border: 1px solid var(--border);
  overflow: hidden; transition: all 0.3s;
}
.event-card:hover { border-color: hsla(221, 83%, 53%, 0.3); box-shadow: var(--shadow-lg); }
.event-bar { height: 6px; background: var(--gradient-primary); }
.event-body { padding: 20px; }
.event-status { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.event-status-dot { width: 8px; height: 8px; border-radius: 50%; }
.event-status-text { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted-foreground); }
.event-name { font-family: var(--font-display); font-weight: 700; color: var(--foreground); margin-bottom: 12px; transition: color 0.3s; }
.event-card:hover .event-name { color: var(--primary); }
.event-meta { display: flex; flex-direction: column; gap: 8px; font-size: 14px; color: var(--muted-foreground); }
.event-meta span { display: flex; align-items: center; gap: 8px; }

.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.news-card {
  background: var(--card); border-radius: 16px; border: 1px solid var(--border);
  overflow: hidden; transition: all 0.3s; cursor: pointer;
}
.news-card:hover { border-color: hsla(221, 83%, 53%, 0.2); box-shadow: var(--shadow-lg); }
.news-image {
  height: 144px; background: hsla(221, 83%, 96%, 0.5);
  display: flex; align-items: center; justify-content: center; font-size: 48px;
  transition: background 0.3s;
}
.news-card:hover .news-image { background: hsla(221, 83%, 53%, 0.05); }
.news-body { padding: 20px; }
.news-meta { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.news-category {
  padding: 2px 10px; border-radius: 9999px; background: hsla(221, 83%, 53%, 0.1);
  font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--primary);
}
.news-date { font-size: 11px; color: var(--muted-foreground); }
.news-title {
  font-family: var(--font-display); font-weight: 600; font-size: 14px;
  color: var(--foreground); line-height: 1.4; transition: color 0.3s;
}
.news-card:hover .news-title { color: var(--primary); }
.news-link { display: inline-flex; align-items: center; gap: 4px; margin-top: 12px; font-size: 12px; font-weight: 500; color: var(--primary); }

.roles-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.role-card {
  background: var(--background); border-radius: 16px; padding: 24px; border: 1px solid var(--border);
  transition: all 0.3s;
}
.role-card:hover { border-color: hsla(221, 83%, 53%, 0.3); box-shadow: var(--shadow-lg); }
.role-icon {
  width: 44px; height: 44px; border-radius: 12px; background: var(--gradient-primary);
  display: flex; align-items: center; justify-content: center; margin-bottom: 16px;
}
.role-icon i, .role-icon .lucide { color: var(--primary-foreground); }
.role-title { font-family: var(--font-display); font-weight: 700; color: var(--foreground); margin-bottom: 12px; }
.role-list { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.role-list li { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted-foreground); }

.testimonials-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.testimonial-card { background: var(--card); border-radius: 16px; padding: 24px; border: 1px solid var(--border); }
.testimonial-stars { display: flex; gap: 2px; margin-bottom: 16px; color: var(--warning); }
.testimonial-text { font-size: 14px; color: var(--foreground); line-height: 1.6; margin-bottom: 16px; }
.testimonial-author { display: flex; align-items: center; gap: 12px; }
.testimonial-avatar {
  width: 40px; height: 40px; border-radius: 50%; background: var(--gradient-primary);
  display: flex; align-items: center; justify-content: center;
}
.testimonial-avatar span { color: var(--primary-foreground); font-weight: 700; font-size: 12px; }
.testimonial-name { font-size: 14px; font-weight: 600; color: var(--foreground); }
.testimonial-role { font-size: 12px; color: var(--muted-foreground); }

.cta-section { padding: 96px 0; }
.cta-card {
  max-width: 896px; margin: 0 auto; background: var(--gradient-primary);
  border-radius: 24px; padding: 64px; text-align: center; position: relative; overflow: hidden;
}
.cta-card::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(circle at 30% 50%, hsla(0, 0%, 100%, 0.1), transparent);
}
.cta-title { font-family: var(--font-display); font-size: 36px; font-weight: 700; color: var(--primary-foreground); margin-bottom: 16px; position: relative; z-index: 1; }
.cta-desc { color: hsla(0, 0%, 100%, 0.8); margin-bottom: 32px; max-width: 512px; margin-left: auto; margin-right: auto; position: relative; z-index: 1; }

.landing-footer {
  border-top: 1px solid var(--border); background: var(--card); padding: 48px 0;
}
.footer-inner {
  max-width: 1280px; margin: 0 auto; padding: 0 24px;
  display: flex; justify-content: space-between; align-items: center;
}
.footer-links { display: flex; gap: 24px; font-size: 14px; color: var(--muted-foreground); }
.footer-links a:hover { color: var(--foreground); }

.floating-cta {
  position: fixed; bottom: 24px; right: 24px; z-index: 50;
}

/* ═══════ Auth Pages ═══════ */
.auth-layout { min-height: 100vh; display: flex; }
.auth-visual {
  display: none; width: 50%; position: relative; overflow: hidden;
}
@media (min-width: 1024px) { .auth-visual { display: flex; } }
.auth-visual-bg {
  position: absolute; inset: 0;
  background: linear-gradient(to bottom right, hsla(221, 83%, 53%, 0.9), hsla(221, 83%, 53%, 0.8), hsla(199, 89%, 48%, 0.7));
}
.auth-visual-grid {
  position: absolute; inset: 0; opacity: 0.1;
  background-image: radial-gradient(circle at 1px 1px, hsla(0, 0%, 100%, 0.3) 1px, transparent 0);
  background-size: 40px 40px;
}
.auth-visual-content {
  position: relative; z-index: 10; display: flex; flex-direction: column;
  justify-content: space-between; padding: 40px; width: 100%;
}
.auth-visual h2 {
  font-family: var(--font-display); font-size: 48px; font-weight: 700;
  color: var(--primary-foreground); line-height: 1.1; margin-bottom: 20px;
}
.auth-visual p { color: hsla(0, 0%, 100%, 0.7); line-height: 1.6; font-size: 16px; }
.auth-stats { display: flex; gap: 40px; }
.auth-stat-value { font-family: var(--font-display); font-size: 24px; font-weight: 700; color: var(--primary-foreground); }
.auth-stat-label { font-size: 12px; color: hsla(0, 0%, 100%, 0.5); margin-top: 2px; }

.auth-form-side {
  flex: 1; display: flex; align-items: center; justify-content: center; padding: 24px 40px;
}
.auth-form { width: 100%; max-width: 460px; }
.auth-form h1 { font-family: var(--font-display); font-size: 30px; font-weight: 700; color: var(--foreground); margin-bottom: 4px; }
.auth-form .auth-subtitle { color: var(--muted-foreground); margin-bottom: 32px; }

.role-selector { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-bottom: 24px; }
.role-option {
  position: relative; display: flex; align-items: center; gap: 12px;
  padding: 14px; border-radius: 16px; border: 2px solid var(--border);
  background: var(--card); cursor: pointer; text-align: left; transition: all 0.2s;
}
.role-option:hover { border-color: hsla(221, 83%, 53%, 0.3); box-shadow: 0 2px 8px hsla(0, 0%, 0%, 0.05); }
.role-option.active { border-color: var(--primary); background: var(--accent); box-shadow: 0 2px 8px hsla(221, 83%, 53%, 0.15); }
.role-option-icon {
  width: 36px; height: 36px; border-radius: 12px; display: flex; align-items: center;
  justify-content: center; flex-shrink: 0; background: var(--muted);
}
.role-option.active .role-option-icon { background: var(--gradient-primary); box-shadow: 0 2px 8px hsla(221, 83%, 53%, 0.3); }
.role-option-icon i, .role-option-icon .lucide { width: 16px; height: 16px; }
.role-option .role-label { font-size: 14px; font-weight: 600; color: var(--foreground); }
.role-option.active .role-label { color: var(--primary); }
.role-option .role-desc { font-size: 11px; color: var(--muted-foreground); }
.role-check {
  position: absolute; top: 8px; right: 8px; width: 20px; height: 20px;
  border-radius: 50%; background: var(--primary); display: none;
  align-items: center; justify-content: center;
}
.role-option.active .role-check { display: flex; }

.divider { position: relative; margin: 32px 0; }
.divider::before { content: ''; position: absolute; inset: 0; top: 50%; height: 1px; background: var(--border); }
.divider span {
  position: relative; background: var(--background); padding: 0 16px;
  font-size: 12px; color: var(--muted-foreground); display: block; width: fit-content; margin: 0 auto;
}

.social-btns { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-bottom: 32px; }
.social-btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; border-radius: 12px; border: 1px solid var(--border);
  background: transparent; font-size: 14px; font-weight: 500; color: var(--foreground);
  cursor: pointer; transition: background 0.2s;
}
.social-btn:hover { background: var(--muted); }
.social-btn svg { width: 16px; height: 16px; }

/* ═══════ Register page role selector ═══════ */
.register-roles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 16px; }
.register-role-option {
  display: flex; flex-direction: column; align-items: center; padding: 12px;
  border-radius: 12px; border: 2px solid var(--border); background: var(--card);
  cursor: pointer; text-align: center; transition: all 0.2s;
}
.register-role-option:hover { border-color: hsla(221, 83%, 53%, 0.3); }
.register-role-option.active { border-color: var(--primary); background: var(--accent); }
.register-role-option .role-label { font-size: 14px; font-weight: 600; }
.register-role-option.active .role-label { color: var(--primary); }
.register-role-option .role-desc { font-size: 10px; color: var(--muted-foreground); margin-top: 2px; }

/* ═══════ Bookmark Item ═══════ */
.bookmark-item {
  background: var(--card); border-radius: 12px; padding: 16px;
  box-shadow: var(--shadow-card); border: 1px solid var(--border);
  display: flex; align-items: center; gap: 16px; transition: box-shadow 0.3s;
}
.bookmark-item:hover { box-shadow: var(--shadow-card-hover); }
.bookmark-icon {
  width: 40px; height: 40px; border-radius: 8px; background: var(--accent);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.bookmark-icon i, .bookmark-icon .lucide { color: var(--primary); }

/* ═══════ Activity Item ═══════ */
.activity-item {
  display: flex; align-items: center; gap: 12px; padding: 8px;
  border-radius: 8px; transition: background 0.2s;
}
.activity-item:hover { background: hsla(210, 20%, 96%, 0.5); }
.activity-avatar {
  width: 36px; height: 36px; border-radius: 50%; background: var(--accent);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.activity-avatar span { color: var(--primary); font-weight: 600; font-size: 12px; }

/* ═══════ Stall Preview ═══════ */
.stall-preview {
  width: 100%; aspect-ratio: 1; border-radius: 12px; background: var(--gradient-primary);
  display: flex; align-items: center; justify-content: center;
}
.stall-preview span { font-family: var(--font-display); font-size: 48px; font-weight: 700; color: var(--primary-foreground); }

/* ═══════ QR Badge Preview ═══════ */
.qr-badge {
  width: 192px; height: 192px; border-radius: 16px; background: var(--gradient-primary);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
}
.qr-badge-id { color: var(--primary-foreground); font-family: monospace; font-size: 14px; font-weight: 700; margin-top: 8px; }

/* ═══════ Settings Card ═══════ */
.settings-card {
  background: var(--card); border-radius: 12px; padding: 24px;
  box-shadow: var(--shadow-card); border: 1px solid var(--border);
}
.settings-header { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; }
.settings-header i, .settings-header .lucide { color: var(--primary); }
.settings-header h3 { font-family: var(--font-display); font-weight: 600; color: var(--foreground); }
.settings-row {
  display: flex; align-items: center; justify-content: space-between; padding: 12px 0;
}
.settings-row span { font-size: 14px; color: var(--foreground); }
.settings-form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.settings-input {
  width: 100%; height: 40px; padding: 0 12px;
  background: hsla(210, 20%, 96%, 0.5); border: 1px solid var(--border);
  border-radius: 8px; font-size: 14px; color: var(--foreground); outline: none;
}

/* ═══════ Scan Log ═══════ */
.scan-log-item {
  display: flex; align-items: center; padding: 12px 20px; gap: 16px;
  border-bottom: 1px solid var(--border);
}
.scan-log-item:last-child { border-bottom: none; }

/* ═══════ Animations ═══════ */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.animate-fade-in { animation: fadeIn 0.5s ease-out forwards; }
.animate-slide-up { animation: slideUp 0.5s ease-out forwards; }

/* ═══════ Responsive ═══════ */
@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-preview { display: none; }
  .hero-title { font-size: 42px; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .events-grid { grid-template-columns: repeat(2, 1fr); }
  .news-grid { grid-template-columns: repeat(2, 1fr); }
  .roles-grid { grid-template-columns: repeat(2, 1fr); }
  .testimonials-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .feature-grid, .events-grid, .news-grid, .roles-grid { grid-template-columns: 1fr; }
  .hero-title { font-size: 32px; }
  .section-title { font-size: 28px; }
  .toolbar { flex-direction: column; }
  .search-box { max-width: 100%; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .header-search { display: none; }
  .sidebar { display: none; }
  .settings-form-grid { grid-template-columns: 1fr; }
  .social-btns { grid-template-columns: 1fr; }
  .role-selector { grid-template-columns: 1fr; }
  .register-roles { grid-template-columns: 1fr; }
  .auth-stats { flex-direction: column; gap: 16px; }
  .footer-inner { flex-direction: column; gap: 16px; text-align: center; }
}
