/* =====================================================
   TechMart Cloud — Multi-tenant SaaS Design System
   ===================================================== */

:root {
  --bg-primary:    #0a0e1a;
  --bg-secondary:  #111827;
  --bg-tertiary:   #1a2236;
  --bg-elevated:   #1e2940;
  --bg-hover:      #243352;
  --border:        #2a3650;
  --border-light:  #3a4868;
  --text-primary:  #f1f5f9;
  --text-secondary:#cbd5e1;
  --text-muted:    #94a3b8;
  --text-faint:    #64748b;
  --accent:        #06b6d4;
  --accent-2:      #8b5cf6;
  --accent-glow:   rgba(6, 182, 212, 0.4);
  --success:       #10b981;
  --warning:       #f59e0b;
  --danger:        #ef4444;
  --info:          #3b82f6;
  --gradient:      linear-gradient(135deg, #06b6d4 0%, #8b5cf6 100%);
  --gradient-soft: linear-gradient(135deg, rgba(6,182,212,0.15), rgba(139,92,246,0.15));
  --shadow-sm:     0 1px 2px rgba(0,0,0,0.3);
  --shadow:        0 4px 12px rgba(0,0,0,0.4);
  --shadow-lg:     0 12px 32px rgba(0,0,0,0.5);
  --shadow-glow:   0 0 24px var(--accent-glow);
  --radius-sm:     8px;
  --radius:        12px;
  --radius-lg:     16px;
  --radius-xl:     24px;
  --transition:    0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="light"] {
  --bg-primary:    #f8fafc;
  --bg-secondary:  #ffffff;
  --bg-tertiary:   #f1f5f9;
  --bg-elevated:   #ffffff;
  --bg-hover:      #f1f5f9;
  --border:        #e2e8f0;
  --border-light:  #cbd5e1;
  --text-primary:  #0f172a;
  --text-secondary:#334155;
  --text-muted:    #64748b;
  --text-faint:    #94a3b8;
  --shadow-sm:     0 1px 2px rgba(0,0,0,0.06);
  --shadow:        0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg:     0 12px 32px rgba(0,0,0,0.12);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Cairo', 'Tajawal', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  direction: rtl;
  transition: background var(--transition), color var(--transition);
}
a { color: inherit; text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent); }
img { max-width: 100%; height: auto; display: block; }
ul { list-style: none; }
button { cursor: pointer; font-family: inherit; border: none; background: none; color: inherit; }
input, select, textarea { font-family: inherit; font-size: inherit; }

.container { width: 100%; max-width: 1320px; margin: 0 auto; padding: 0 24px; }

/* ===== Buttons ===== */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 18px; border-radius: var(--radius-sm);
  font-weight: 600; font-size: 14px;
  transition: all var(--transition); white-space: nowrap;
  border: 1px solid transparent;
}
.btn-primary { background: var(--gradient); color: #fff; box-shadow: var(--shadow); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: var(--shadow-glow); color: #fff; }
.btn-secondary { background: var(--bg-tertiary); color: var(--text-primary); border-color: var(--border); }
.btn-secondary:hover { background: var(--bg-hover); color: var(--text-primary); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-success { background: var(--success); color: #fff; }
.btn-warning { background: var(--warning); color: #1a1a1a; }
.btn-outline { background: transparent; color: var(--accent); border-color: var(--accent); }
.btn-outline:hover { background: var(--accent); color: #fff; }
.btn-sm { padding: 6px 12px; font-size: 13px; }
.btn-lg { padding: 14px 24px; font-size: 16px; }
.btn-block { width: 100%; justify-content: center; }

/* ===== Topbar ===== */
.topbar { background: var(--bg-secondary); border-bottom: 1px solid var(--border); font-size: 13px; padding: 8px 0; }
.topbar-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.topbar-info { display: flex; gap: 20px; color: var(--text-muted); flex-wrap: wrap; }
.topbar-info i { color: var(--accent); margin-left: 6px; }
.topbar-actions { display: flex; gap: 12px; align-items: center; }
.topbar-link { color: var(--text-secondary); padding: 4px 10px; border-radius: var(--radius-sm); transition: all var(--transition); }
.topbar-link:hover { color: var(--accent); background: var(--bg-hover); }
.demo-pill { background: var(--gradient-soft); color: var(--accent); padding: 4px 10px; border-radius: 12px; font-size: 12px; }

/* ===== Currency switcher ===== */
.currency-switcher {
  display: inline-flex; gap: 2px; background: var(--bg-tertiary); border-radius: 12px; padding: 2px;
}
.currency-option { padding: 4px 10px; font-size: 12px; font-weight: 600; border-radius: 10px; color: var(--text-muted); }
.currency-option.active { background: var(--gradient); color: #fff; }
.currency-option:hover { color: var(--text-primary); }

/* ===== Theme toggle ===== */
.theme-toggle {
  width: 36px; height: 36px; border-radius: 50%; background: var(--bg-tertiary);
  color: var(--text-secondary); display: grid; place-items: center; transition: all var(--transition);
}
.theme-toggle:hover { background: var(--bg-hover); color: var(--accent); }

/* ===== Header ===== */
.site-header { background: var(--bg-secondary); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 100; }
.header-inner { display: flex; justify-content: space-between; align-items: center; padding: 16px 0; gap: 24px; }
.logo { display: flex; align-items: center; gap: 12px; }
.logo-icon {
  width: 44px; height: 44px; border-radius: 12px;
  background: var(--gradient); display: grid; place-items: center;
  color: #fff; font-size: 22px; box-shadow: var(--shadow-glow);
}
.logo-text { display: flex; flex-direction: column; }
.logo-title { font-weight: 800; font-size: 18px; line-height: 1.2; }
.logo-tagline { font-size: 12px; color: var(--text-muted); }

.search-box { flex: 1; max-width: 480px; display: flex; align-items: center; gap: 8px; background: var(--bg-tertiary); border: 1px solid var(--border); border-radius: var(--radius); padding: 8px 14px; }
.search-box input { flex: 1; background: transparent; border: none; color: var(--text-primary); outline: none; font-size: 14px; }
.search-box .search-icon { color: var(--text-muted); }
.search-box button { background: var(--gradient); color: #fff; padding: 6px 16px; border-radius: var(--radius-sm); font-weight: 600; }
.search-box button:hover { transform: translateY(-1px); }

.mobile-menu-toggle { display: none; font-size: 22px; padding: 8px; color: var(--text-primary); }

/* ===== Navbar ===== */
.navbar { background: var(--bg-secondary); border-top: 1px solid var(--border); }
.navbar-inner { display: flex; align-items: center; }
.nav-categories { display: flex; align-items: center; gap: 4px; padding: 8px 0; flex-wrap: wrap; }
.nav-categories a {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px; border-radius: var(--radius-sm); font-size: 14px;
  color: var(--text-secondary); transition: all var(--transition); white-space: nowrap;
}
.nav-categories a:hover, .nav-categories a.active { background: var(--bg-hover); color: var(--accent); }
.nav-categories a i { font-size: 13px; }
.cat-count { background: var(--bg-tertiary); color: var(--text-muted); padding: 1px 8px; border-radius: 10px; font-size: 11px; margin-right: 4px; }
.nav-sep { margin-right: auto; }

/* ===== Hero ===== */
.hero { margin-bottom: 40px; }
.hero-slider {
  position: relative; height: 480px; border-radius: var(--radius-xl); overflow: hidden;
  background: var(--bg-tertiary);
}
.hero-slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.2s ease; }
.hero-slide.active { opacity: 1; }
.hero-slide-bg {
  position: absolute; inset: 0; background-size: cover; background-position: center;
  animation: kenBurns 8s ease-in-out infinite alternate;
}
@keyframes kenBurns { from { transform: scale(1); } to { transform: scale(1.06); } }
.hero-slide-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(10,14,26,0.95) 0%, rgba(10,14,26,0.7) 50%, rgba(10,14,26,0.3) 100%);
}
.hero-slide-content {
  position: relative; z-index: 2; height: 100%;
  display: flex; flex-direction: column; justify-content: center;
  max-width: 580px; padding: 0 24px;
}
.pos-right .hero-slide-content { align-items: flex-start; text-align: right; }
.pos-left .hero-slide-content { align-items: flex-end; text-align: left; }
.pos-center .hero-slide-content { align-items: center; text-align: center; }
.hero-slide-title { font-size: 42px; font-weight: 900; line-height: 1.15; margin-bottom: 16px; color: #fff; }
.hero-slide-subtitle { font-size: 18px; color: rgba(255,255,255,0.85); margin-bottom: 24px; }
.hero-slide-cta { animation: pulseGlow 2s ease-in-out infinite; }
@keyframes pulseGlow { 0%,100% { box-shadow: 0 0 20px var(--accent-glow); } 50% { box-shadow: 0 0 36px var(--accent-glow); } }

.hero-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(255,255,255,0.1); color: #fff;
  display: grid; place-items: center; backdrop-filter: blur(8px);
  transition: all var(--transition); z-index: 3;
}
.hero-arrow:hover { background: var(--accent); }
.hero-arrow-prev { right: 16px; }
.hero-arrow-next { left: 16px; }
.hero-dots { position: absolute; bottom: 24px; left: 50%; transform: translateX(-50%); display: flex; gap: 8px; z-index: 3; }
.hero-dot { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,0.4); transition: all var(--transition); }
.hero-dot.active { width: 28px; border-radius: 4px; background: var(--accent); }
.hero-progress { position: absolute; bottom: 0; left: 0; right: 0; height: 3px; background: rgba(255,255,255,0.1); z-index: 3; }
.hero-progress-bar { height: 100%; background: var(--accent); width: 0; }

.hero-stats-bar { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px,1fr)); gap: 16px; margin-top: 24px; padding: 24px; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-lg); }
.hero-stat { text-align: center; }
.hero-stat .num { font-size: 36px; font-weight: 900; background: var(--gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.hero-stat .label { color: var(--text-muted); font-size: 14px; margin-top: 4px; }

/* ===== Section title ===== */
.section-title { display: flex; justify-content: space-between; align-items: center; margin: 40px 0 20px; }
.section-title h2 { font-size: 26px; font-weight: 800; display: flex; align-items: center; gap: 12px; }
.section-title h2 i { color: var(--accent); }
.view-all { color: var(--accent); font-size: 14px; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }

/* ===== Categories grid ===== */
.categories-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px,1fr)); gap: 16px; }
.category-card {
  background: var(--bg-secondary); border: 1px solid var(--border);
  padding: 24px; border-radius: var(--radius); text-align: center;
  transition: all var(--transition);
}
.category-card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: var(--shadow-lg); }
.cat-icon {
  width: 56px; height: 56px; margin: 0 auto 12px;
  border-radius: 16px; background: var(--gradient-soft); color: var(--accent);
  display: grid; place-items: center; font-size: 24px;
}
.category-card h3 { font-size: 16px; margin-bottom: 4px; }
.cat-count-text { color: var(--text-muted); font-size: 13px; }

/* ===== Products grid ===== */
.products-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px,1fr)); gap: 20px; }
.product-card {
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden; transition: all var(--transition);
  display: flex; flex-direction: column;
}
.product-card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: var(--shadow-lg); }
.product-image {
  position: relative; aspect-ratio: 1; background: var(--bg-tertiary);
  display: grid; place-items: center; overflow: hidden;
}
.product-image svg { width: 80%; height: 80%; }
.product-badges { position: absolute; top: 8px; right: 8px; display: flex; flex-direction: column; gap: 4px; }
.badge { padding: 4px 8px; border-radius: 6px; font-size: 11px; font-weight: 700; color: #fff; }
.badge-featured { background: var(--accent); }
.badge-discount { background: var(--danger); }
.badge-stock-in { background: var(--success); }
.badge-stock-limited { background: var(--warning); color: #1a1a1a; }
.badge-stock-out { background: var(--text-faint); }
.product-info { padding: 16px; flex: 1; display: flex; flex-direction: column; }
.product-name { font-size: 15px; font-weight: 700; margin-bottom: 4px; line-height: 1.4; }
.product-brand { color: var(--text-muted); font-size: 12px; margin-bottom: 8px; }
.product-price { margin-top: auto; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.price-current { font-size: 18px; font-weight: 800; color: var(--accent); }
.price-old { font-size: 13px; color: var(--text-muted); text-decoration: line-through; }

/* ===== Panel ===== */
.panel { background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-lg); margin-bottom: 20px; overflow: hidden; }
.panel-header { padding: 16px 20px; border-bottom: 1px solid var(--border); background: var(--bg-tertiary); }
.panel-header h2 { font-size: 16px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.panel-header h2 i { color: var(--accent); }
.panel-body { padding: 20px; }

/* ===== Forms ===== */
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 13px; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; }
.form-control {
  width: 100%; padding: 10px 14px; background: var(--bg-tertiary);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  color: var(--text-primary); font-size: 14px; transition: all var(--transition);
  font-family: inherit;
}
.form-control:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-glow); }
.form-control::placeholder { color: var(--text-faint); }
textarea.form-control { resize: vertical; min-height: 80px; }
select.form-control { cursor: pointer; }
.form-hint { font-size: 12px; color: var(--text-muted); margin-top: 4px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-row-3 { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; }
.form-actions { display: flex; gap: 12px; margin-top: 20px; }
.required { color: var(--danger); }
.spec-row { display: grid; grid-template-columns: 1fr 1fr auto; gap: 8px; margin-bottom: 8px; }
.spec-row .remove-spec { padding: 8px 12px; background: var(--danger); color: #fff; border-radius: var(--radius-sm); }

/* ===== Tables ===== */
.table-wrap { overflow-x: auto; }
table.data-table { width: 100%; border-collapse: collapse; }
.data-table th, .data-table td { padding: 12px 14px; text-align: right; border-bottom: 1px solid var(--border); font-size: 14px; }
.data-table th { background: var(--bg-tertiary); font-weight: 700; color: var(--text-secondary); font-size: 13px; }
.data-table tr:hover { background: var(--bg-hover); }

/* ===== Status pills ===== */
.pill { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 12px; font-size: 12px; font-weight: 600; }
.pill-success { background: rgba(16,185,129,0.15); color: var(--success); }
.pill-warning { background: rgba(245,158,11,0.15); color: var(--warning); }
.pill-danger  { background: rgba(239,68,68,0.15); color: var(--danger); }
.pill-info    { background: rgba(59,130,246,0.15); color: var(--info); }
.pill-muted   { background: var(--bg-tertiary); color: var(--text-muted); }

/* ===== Stat cards ===== */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px,1fr)); gap: 16px; margin-bottom: 24px; }
.stat-card { background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 20px; transition: all var(--transition); }
.stat-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.stat-card-icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-size: 20px; margin-bottom: 12px; }
.stat-card-icon.bg-blue   { background: rgba(59,130,246,0.15); color: var(--info); }
.stat-card-icon.bg-green  { background: rgba(16,185,129,0.15); color: var(--success); }
.stat-card-icon.bg-purple { background: rgba(139,92,246,0.15); color: var(--accent-2); }
.stat-card-icon.bg-orange { background: rgba(245,158,11,0.15); color: var(--warning); }
.stat-card-icon.bg-red    { background: rgba(239,68,68,0.15); color: var(--danger); }
.stat-card-icon.bg-cyan   { background: rgba(6,182,212,0.15); color: var(--accent); }
.stat-card-value { font-size: 32px; font-weight: 900; line-height: 1.1; }
.stat-card-label { color: var(--text-muted); font-size: 13px; margin-top: 4px; }

/* ===== Admin layout ===== */
.admin-layout { display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; }
.admin-sidebar {
  background: var(--bg-secondary); border-left: 1px solid var(--border);
  padding: 20px 0; position: sticky; top: 0; height: 100vh; overflow-y: auto;
}
.admin-sidebar-logo { padding: 0 20px 20px; border-bottom: 1px solid var(--border); margin-bottom: 12px; display: flex; align-items: center; gap: 10px; }
.admin-sidebar-logo .logo-icon { width: 36px; height: 36px; font-size: 18px; border-radius: 10px; }
.admin-sidebar-logo .logo-title { font-size: 16px; font-weight: 800; }
.admin-nav a {
  display: flex; align-items: center; gap: 10px; padding: 10px 20px;
  color: var(--text-secondary); font-size: 14px; transition: all var(--transition);
  border-right: 3px solid transparent;
}
.admin-nav a:hover { background: var(--bg-hover); color: var(--accent); }
.admin-nav a.active { background: var(--gradient-soft); color: var(--accent); border-right-color: var(--accent); font-weight: 700; }
.admin-nav a i { width: 20px; text-align: center; }
.admin-nav .nav-section { padding: 12px 20px 6px; font-size: 11px; color: var(--text-faint); text-transform: uppercase; letter-spacing: 1px; }

.admin-main { padding: 24px; }
.admin-topbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; flex-wrap: wrap; gap: 12px; }
.admin-topbar h1 { font-size: 24px; font-weight: 800; display: flex; align-items: center; gap: 10px; }

/* ===== Login page ===== */
.admin-login-page { min-height: 100vh; display: grid; place-items: center; padding: 20px; background: linear-gradient(135deg, #0a0e1a 0%, #1a2236 100%); }
.login-card {
  background: var(--bg-secondary); border: 1px solid var(--border);
  padding: 40px; border-radius: var(--radius-xl); max-width: 440px; width: 100%;
  box-shadow: var(--shadow-lg);
}
.login-logo {
  width: 72px; height: 72px; border-radius: 20px; background: var(--gradient);
  display: grid; place-items: center; font-size: 32px; color: #fff;
  margin: 0 auto 20px; box-shadow: var(--shadow-glow);
}
.login-card h1 { text-align: center; font-size: 24px; margin-bottom: 8px; }
.login-card .sub { text-align: center; color: var(--text-muted); margin-bottom: 24px; }
.demo-hint {
  background: var(--gradient-soft); color: var(--accent);
  padding: 12px 16px; border-radius: var(--radius-sm); margin-bottom: 20px;
  display: flex; align-items: center; gap: 8px; font-size: 13px;
}
.demo-hint code { background: rgba(0,0,0,0.3); padding: 2px 8px; border-radius: 4px; }

/* ===== Flash messages ===== */
.flash-container { position: fixed; top: 20px; left: 20px; z-index: 9999; max-width: 360px; }
.flash {
  display: flex; align-items: center; gap: 10px;
  background: var(--bg-elevated); border: 1px solid var(--border);
  padding: 12px 16px; border-radius: var(--radius-sm); margin-bottom: 8px;
  box-shadow: var(--shadow-lg); animation: slideIn 0.3s ease;
}
@keyframes slideIn { from { transform: translateX(-100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
.flash-success { border-right: 4px solid var(--success); }
.flash-success i { color: var(--success); }
.flash-error { border-right: 4px solid var(--danger); }
.flash-error i { color: var(--danger); }
.flash-info { border-right: 4px solid var(--info); }
.flash-info i { color: var(--info); }
.flash-close { margin-right: auto; color: var(--text-muted); padding: 4px; }

/* ===== Footer ===== */
.site-footer { background: var(--bg-secondary); border-top: 1px solid var(--border); padding: 48px 0 0; margin-top: 60px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.5fr; gap: 32px; padding-bottom: 32px; }
.footer-col h4 { font-size: 14px; font-weight: 700; margin-bottom: 16px; color: var(--text-primary); }
.footer-about p { color: var(--text-muted); font-size: 13px; line-height: 1.7; margin: 12px 0; }
.footer-logo { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 18px; }
.footer-logo i { color: var(--accent); font-size: 22px; }
.footer-links li, .footer-contact li { margin-bottom: 8px; }
.footer-links a { color: var(--text-muted); font-size: 13px; display: inline-flex; align-items: center; gap: 6px; }
.footer-links a:hover { color: var(--accent); }
.footer-contact li { display: flex; align-items: flex-start; gap: 10px; color: var(--text-muted); font-size: 13px; }
.footer-contact i { color: var(--accent); margin-top: 4px; }
.footer-social { display: flex; gap: 10px; margin-top: 12px; }
.footer-social a { width: 36px; height: 36px; border-radius: 10px; background: var(--bg-tertiary); display: grid; place-items: center; color: var(--text-secondary); transition: all var(--transition); }
.footer-social a:hover { background: var(--gradient); color: #fff; transform: translateY(-2px); }
.footer-bottom { border-top: 1px solid var(--border); padding: 16px 0; text-align: center; color: var(--text-muted); font-size: 13px; }
.footer-tech { color: var(--text-faint); font-size: 12px; margin-top: 4px; }

/* ===== Features bar ===== */
.features-bar { background: var(--bg-secondary); border-top: 1px solid var(--border); padding: 32px 0; margin-top: 60px; }
.features-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 24px; }
.feature-item { display: flex; align-items: center; gap: 14px; }
.feature-item i { font-size: 28px; color: var(--accent); width: 44px; height: 44px; border-radius: 12px; background: var(--gradient-soft); display: grid; place-items: center; }
.feature-item h4 { font-size: 14px; font-weight: 700; }
.feature-item p { color: var(--text-muted); font-size: 12px; }

/* ===== Back to top ===== */
.back-to-top {
  position: fixed; bottom: 24px; left: 24px;
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--gradient); color: #fff; display: grid; place-items: center;
  box-shadow: var(--shadow-lg); opacity: 0; visibility: hidden;
  transition: all var(--transition); z-index: 90;
}
.back-to-top.show { opacity: 1; visibility: visible; }

/* ===== Page hero ===== */
.page-hero { background: var(--gradient-soft); border-bottom: 1px solid var(--border); padding: 48px 0; margin-bottom: 32px; text-align: center; }
.page-hero h1 { font-size: 36px; font-weight: 900; margin-bottom: 8px; }
.page-hero p { color: var(--text-muted); font-size: 16px; max-width: 600px; margin: 0 auto; }

/* ===== Empty state ===== */
.empty-state { text-align: center; padding: 60px 20px; color: var(--text-muted); }
.empty-state i { font-size: 48px; color: var(--text-faint); margin-bottom: 16px; }
.empty-state h3 { font-size: 18px; margin-bottom: 8px; color: var(--text-secondary); }

/* ===== Pagination ===== */
.pagination { display: flex; justify-content: center; gap: 6px; margin-top: 32px; flex-wrap: wrap; }
.pagination a, .pagination span {
  padding: 8px 14px; border-radius: var(--radius-sm); background: var(--bg-secondary);
  border: 1px solid var(--border); font-size: 14px; transition: all var(--transition);
}
.pagination a:hover { border-color: var(--accent); color: var(--accent); }
.pagination .current { background: var(--gradient); color: #fff; border-color: transparent; }

/* ===== Landing page ===== */
.landing-hero {
  position: relative; padding: 80px 0 100px; overflow: hidden;
  background: radial-gradient(ellipse at top right, rgba(6,182,212,0.15), transparent 60%),
              radial-gradient(ellipse at bottom left, rgba(139,92,246,0.15), transparent 60%);
}
.landing-hero-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.landing-hero h1 { font-size: 56px; font-weight: 900; line-height: 1.1; margin-bottom: 20px; }
.landing-hero h1 .gradient-text { background: var(--gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.landing-hero p.lead { font-size: 20px; color: var(--text-secondary); margin-bottom: 32px; }
.landing-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.landing-hero-visual { position: relative; }
.landing-mockup {
  background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-xl);
  padding: 24px; box-shadow: var(--shadow-lg); transform: perspective(1000px) rotateY(-8deg) rotateX(2deg);
}
.landing-mockup-bar { display: flex; gap: 6px; margin-bottom: 16px; }
.landing-mockup-bar span { width: 12px; height: 12px; border-radius: 50%; background: var(--border-light); }
.landing-mockup-bar span:first-child { background: #ef4444; }
.landing-mockup-bar span:nth-child(2) { background: #f59e0b; }
.landing-mockup-bar span:nth-child(3) { background: #10b981; }
.landing-mockup-content { background: var(--bg-tertiary); border-radius: var(--radius); padding: 20px; }
.landing-mockup-content .mock-line { height: 8px; border-radius: 4px; background: var(--border); margin-bottom: 10px; }
.landing-mockup-content .mock-line.short { width: 60%; }
.landing-mockup-content .mock-line.accent { background: var(--accent); width: 40%; }
.landing-mockup-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; margin-top: 16px; }
.landing-mockup-grid .mock-card { background: var(--bg-elevated); border-radius: 8px; padding: 10px; }
.landing-mockup-grid .mock-card .mock-line { margin-bottom: 6px; }

.landing-section { padding: 60px 0; }
.landing-section h2 { font-size: 36px; font-weight: 900; text-align: center; margin-bottom: 12px; }
.landing-section .sub { text-align: center; color: var(--text-muted); font-size: 16px; max-width: 600px; margin: 0 auto 40px; }

.features-showcase { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px,1fr)); gap: 24px; }
.feature-card {
  background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 28px; transition: all var(--transition);
}
.feature-card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: var(--shadow-lg); }
.feature-card .icon {
  width: 52px; height: 52px; border-radius: 14px; background: var(--gradient-soft);
  color: var(--accent); display: grid; place-items: center; font-size: 22px; margin-bottom: 16px;
}
.feature-card h3 { font-size: 18px; font-weight: 800; margin-bottom: 8px; }
.feature-card p { color: var(--text-muted); font-size: 14px; line-height: 1.7; }

.plans-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px,1fr)); gap: 24px; max-width: 1100px; margin: 0 auto; }
.plan-card {
  background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 32px; text-align: center; position: relative; transition: all var(--transition);
}
.plan-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.plan-card.featured { border-color: var(--accent); box-shadow: var(--shadow-glow); }
.plan-card.featured::before {
  content: 'الأكثر شعبية'; position: absolute; top: -12px; right: 50%; transform: translateX(50%);
  background: var(--gradient); color: #fff; font-size: 12px; font-weight: 700;
  padding: 4px 12px; border-radius: 12px;
}
.plan-name { font-size: 18px; font-weight: 800; margin-bottom: 8px; }
.plan-price { font-size: 48px; font-weight: 900; margin: 16px 0; }
.plan-price .currency { font-size: 20px; color: var(--text-muted); }
.plan-price .period { font-size: 14px; color: var(--text-muted); font-weight: 400; }
.plan-features { list-style: none; margin: 24px 0; text-align: right; }
.plan-features li { padding: 8px 0; color: var(--text-secondary); font-size: 14px; display: flex; align-items: center; gap: 8px; }
.plan-features li i { color: var(--success); }
.plan-features li.disabled { color: var(--text-faint); }
.plan-features li.disabled i { color: var(--text-faint); }

.stores-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px,1fr)); gap: 20px; }
.store-card {
  background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 24px; transition: all var(--transition);
}
.store-card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: var(--shadow-lg); }
.store-card .store-icon {
  width: 56px; height: 56px; border-radius: 14px; background: var(--gradient);
  color: #fff; display: grid; place-items: center; font-size: 24px; margin-bottom: 14px;
}
.store-card h3 { font-size: 18px; font-weight: 800; margin-bottom: 4px; }
.store-card .store-slug { color: var(--text-muted); font-size: 13px; margin-bottom: 12px; }
.store-card p { color: var(--text-secondary); font-size: 13px; line-height: 1.6; margin-bottom: 16px; }
.store-card .store-meta { display: flex; justify-content: space-between; color: var(--text-muted); font-size: 12px; padding-top: 12px; border-top: 1px solid var(--border); }

/* ===== Responsive ===== */
@media (max-width: 992px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .landing-hero-grid { grid-template-columns: 1fr; }
  .landing-hero h1 { font-size: 40px; }
  .features-grid { grid-template-columns: repeat(2,1fr); }
  .admin-layout { grid-template-columns: 1fr; }
  .admin-sidebar { position: static; height: auto; border-left: none; border-bottom: 1px solid var(--border); }
  .admin-nav { display: flex; overflow-x: auto; padding: 12px; }
  .admin-nav a { white-space: nowrap; border-right: none; border-bottom: 3px solid transparent; padding: 8px 14px; }
  .admin-nav a.active { border-bottom-color: var(--accent); }
  .admin-nav .nav-section { display: none; }
}
@media (max-width: 768px) {
  .search-box { display: none; }
  .mobile-menu-toggle { display: block; }
  .navbar-inner { overflow-x: auto; }
  .form-row, .form-row-3 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .features-grid { grid-template-columns: 1fr; }
  .hero-slider { height: 360px; }
  .hero-slide-title { font-size: 28px; }
  .hero-slide-subtitle { font-size: 14px; }
  .landing-hero h1 { font-size: 32px; }
  .section-title h2 { font-size: 22px; }
  .topbar-info { display: none; }
  .stats-grid { grid-template-columns: repeat(2,1fr); }
  .spec-row { grid-template-columns: 1fr; }
}
