/* ═══════════════════════════════════════════════════════════════════════════
   MAGAZ — CYBER FUTURISTIC DESIGN SYSTEM  v3.0
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─── Variables ─────────────────────────────────────────────────────────── */
:root {
  --c-bg:        #040a1a;
  --c-bg2:       #060d20;
  --c-surface:   rgba(8, 20, 50, 0.85);
  --c-surface2:  rgba(12, 30, 70, 0.9);
  --c-border:    rgba(0, 200, 255, 0.18);
  --c-border-h:  rgba(0, 200, 255, 0.5);

  --c-cyan:      #00c8ff;
  --c-cyan-d:    #008ab5;
  --c-purple:    #a855f7;
  --c-purple-d:  #7c3aed;
  --c-magenta:   #f0abfc;
  --c-green:     #00ff88;
  --c-red:       #ff3860;
  --c-amber:     #fbbf24;
  --c-text:      #e2eeff;
  --c-muted:     #6b8cbe;

  --glow-cyan:   0 0 8px rgba(0,200,255,.6), 0 0 24px rgba(0,200,255,.3);
  --glow-purple: 0 0 8px rgba(168,85,247,.6), 0 0 24px rgba(168,85,247,.3);
  --glow-green:  0 0 8px rgba(0,255,136,.6), 0 0 24px rgba(0,255,136,.3);

  --radius:      0.5rem;
  --radius-lg:   1rem;
  --transition:  0.22s cubic-bezier(.4,0,.2,1);
  --font:        'Inter', -apple-system, sans-serif;
  --font-mono:   'JetBrains Mono', 'Fira Code', monospace;
}

/* ─── Reset ──────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--c-bg);
  color: var(--c-text);
  min-height: 100vh;
  display: flex; flex-direction: column;
  line-height: 1.6;
  overflow-x: hidden;
}

/* ─── Animated background grid ───────────────────────────────────────────── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,200,255,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,200,255,.04) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
  z-index: 0;
  animation: gridMove 20s linear infinite;
}
@keyframes gridMove {
  0%   { background-position: 0 0; }
  100% { background-position: 48px 48px; }
}

/* Floating orbs in the background */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(ellipse 600px 400px at 20% 30%, rgba(168,85,247,.08) 0%, transparent 70%),
    radial-gradient(ellipse 500px 300px at 80% 70%, rgba(0,200,255,.07) 0%, transparent 70%),
    radial-gradient(ellipse 400px 400px at 50% 50%, rgba(0,255,136,.04) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
  animation: orbPulse 8s ease-in-out infinite alternate;
}
@keyframes orbPulse {
  0%   { opacity: .7; transform: scale(1); }
  100% { opacity: 1;  transform: scale(1.05); }
}

/* Ensure content is above bg pseudo-elements */
nav, main, footer, .flash { position: relative; z-index: 1; }

a { color: var(--c-cyan); text-decoration: none; transition: color var(--transition); }
a:hover { color: #fff; text-decoration: none; }
img { display: block; max-width: 100%; }
button { cursor: pointer; font-family: inherit; }
input, select, textarea { 
  font: inherit; 
  background: var(--c-surface);
  color: var(--c-text);
}

/* ─── Layout ──────────────────────────────────────────────────────────────── */
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.25rem; }
.main { flex: 1; padding: 2rem 0; }
.center { text-align: center; }
.mt-2 { margin-top: .5rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.text-muted { color: var(--c-muted); font-size: .875rem; }

/* ─── Scrollbar ──────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--c-bg); }
::-webkit-scrollbar-thumb { background: var(--c-cyan-d); border-radius: 99px; }

/* ─── NAV ──────────────────────────────────────────────────────────────────── */
.nav {
  background: rgba(4, 10, 26, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--c-border);
  position: sticky; top: 0; z-index: 100;
  box-shadow: 0 2px 32px rgba(0,200,255,.07);
}
.nav__inner {
  display: flex; align-items: center; gap: 1.5rem;
  height: 64px;
}
.nav__logo {
  font-size: 1.4rem; font-weight: 800;
  background: linear-gradient(90deg, var(--c-cyan), var(--c-purple));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -.5px; flex-shrink: 0;
  filter: drop-shadow(0 0 8px rgba(0,200,255,.4));
  animation: logoPulse 4s ease-in-out infinite alternate;
}
@keyframes logoPulse {
  from { filter: drop-shadow(0 0 6px rgba(0,200,255,.3)); }
  to   { filter: drop-shadow(0 0 16px rgba(168,85,247,.6)); }
}
.nav__links { display: flex; align-items: center; gap: .5rem; margin-left: auto; }
.nav__link {
  color: var(--c-muted); font-weight: 500; font-size: .9rem;
  padding: .4rem .85rem; border-radius: var(--radius);
  border: 1px solid transparent;
  transition: all var(--transition); letter-spacing: .02em;
}
.nav__link:hover {
  color: var(--c-cyan);
  border-color: var(--c-border);
  background: rgba(0,200,255,.06);
  text-shadow: var(--glow-cyan);
}
.nav__link--admin { color: var(--c-amber); }
.nav__link--admin:hover { color: var(--c-amber); border-color: rgba(251,191,36,.3); background: rgba(251,191,36,.07); text-shadow: 0 0 8px rgba(251,191,36,.5); }

.nav__cart { position: relative; font-size: 1.25rem; padding: .3rem .6rem; }
.cart-badge {
  position: absolute; top: -5px; right: -6px;
  background: var(--c-cyan); color: #000;
  border-radius: 999px; font-size: .62rem; font-weight: 800;
  width: 18px; height: 18px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--glow-cyan);
  animation: badgePop .3s cubic-bezier(.34,1.56,.64,1);
}
@keyframes badgePop { from { transform: scale(0); } to { transform: scale(1); } }

/* ─── Dropdown ───────────────────────────────────────────────────────────── */
.nav__dropdown { position: relative; }
.nav__user-btn {
  background: rgba(0,200,255,.08);
  border: 1px solid var(--c-border);
  color: var(--c-text); font-size: .9rem; font-weight: 600;
  padding: .4rem .9rem; border-radius: var(--radius);
  transition: all var(--transition); letter-spacing: .03em;
}
.nav__user-btn:hover {
  background: rgba(0,200,255,.15);
  border-color: var(--c-cyan);
  box-shadow: var(--glow-cyan);
  color: var(--c-cyan);
}
.nav__dropdown-menu {
  display: none; position: absolute; right: 0; top: 100%;
  padding-top: 8px; background: transparent; z-index: 200;
}
.nav__dropdown-menu-inner {
  background: rgba(4,10,26,.95);
  backdrop-filter: blur(24px);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg);
  box-shadow: 0 16px 50px rgba(0,0,0,.5), var(--glow-cyan);
  min-width: 190px; overflow: hidden;
}
.nav__dropdown.open .nav__dropdown-menu { display: block; animation: dropIn .18s ease; }
@keyframes dropIn {
  from { opacity: 0; transform: translateY(-8px) scale(.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
.dropdown-item {
  display: block; padding: .7rem 1.1rem;
  color: var(--c-text); font-size: .88rem; font-weight: 500;
  transition: all var(--transition);
  border: none; background: none; width: 100%; text-align: left;
  border-left: 2px solid transparent;
}
.dropdown-item:hover {
  background: rgba(0,200,255,.07);
  border-left-color: var(--c-cyan);
  color: var(--c-cyan); padding-left: 1.3rem;
}
.dropdown-item--danger { color: var(--c-red); }
.dropdown-item--danger:hover { background: rgba(255,56,96,.07); border-left-color: var(--c-red); color: var(--c-red); }
.dropdown-divider { border: none; border-top: 1px solid var(--c-border); margin: .2rem 0; }

/* ─── Buttons ─────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .45rem;
  padding: .55rem 1.35rem; border-radius: var(--radius); font-weight: 700;
  font-size: .88rem; border: 1px solid transparent;
  transition: all var(--transition); cursor: pointer; line-height: 1;
  white-space: nowrap; letter-spacing: .04em; text-transform: uppercase;
  position: relative; overflow: hidden;
}
/* Shimmer effect on buttons */
.btn::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 60%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.12), transparent);
  transition: left .4s ease;
}
.btn:hover::before { left: 150%; }

.btn--primary {
  background: linear-gradient(135deg, var(--c-cyan), var(--c-purple));
  color: #000; border-color: transparent;
  box-shadow: 0 4px 15px rgba(0,200,255,.3);
  font-weight: 800;
}
.btn--primary:hover {
  box-shadow: 0 6px 25px rgba(0,200,255,.5), var(--glow-cyan);
  transform: translateY(-2px);
  color: #000;
}
.btn--outline {
  background: transparent;
  border-color: var(--c-cyan);
  color: var(--c-cyan);
}
.btn--outline:hover {
  background: rgba(0,200,255,.1);
  box-shadow: var(--glow-cyan);
  transform: translateY(-1px);
  color: var(--c-cyan);
}
.btn--danger  {
  background: linear-gradient(135deg, var(--c-red), #c0392b);
  color: #fff; border-color: transparent;
}
.btn--danger:hover { box-shadow: 0 6px 20px rgba(255,56,96,.4); transform: translateY(-1px); color: #fff; }
.btn--sm  { padding: .32rem .8rem; font-size: .78rem; }
.btn--lg  { padding: .85rem 2.25rem; font-size: .95rem; }
.btn--full { width: 100%; }
.btn-icon {
  background: none; border: 1px solid var(--c-border); padding: .3rem .5rem;
  font-size: 1rem; border-radius: var(--radius); transition: all var(--transition);
  color: var(--c-muted);
}
.btn-icon--danger { color: var(--c-red); border-color: rgba(255,56,96,.3); }
.btn-icon--danger:hover {
  background: rgba(255,56,96,.1);
  box-shadow: 0 0 8px rgba(255,56,96,.3);
  border-color: var(--c-red);
}

/* ─── Flash ───────────────────────────────────────────────────────────────── */
.flash {
  display: flex; align-items: center; justify-content: space-between;
  padding: .85rem 1.5rem; font-weight: 600; font-size: .88rem;
  border-left: 3px solid transparent;
  backdrop-filter: blur(12px);
  animation: flashIn .3s ease;
}
@keyframes flashIn { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }
.flash--success { background: rgba(0,255,136,.08); color: var(--c-green); border-color: var(--c-green); }
.flash--error   { background: rgba(255,56,96,.08);  color: var(--c-red);   border-color: var(--c-red); }
.flash--info    { background: rgba(0,200,255,.08);  color: var(--c-cyan);  border-color: var(--c-cyan); }
.flash__close { background: none; border: none; font-size: 1rem; cursor: pointer; opacity: .6; color: inherit; }
.flash__close:hover { opacity: 1; }

/* ─── Alerts ──────────────────────────────────────────────────────────────── */
.alert { padding: .75rem 1rem; border-radius: var(--radius); margin-bottom: 1rem; font-size: .9rem; }
.alert--error   { background: rgba(255,56,96,.1);  color: #ff6b6b; border: 1px solid rgba(255,56,96,.3); }
.alert--success { background: rgba(0,255,136,.1);  color: var(--c-green); border: 1px solid rgba(0,255,136,.3); }
.alert--info    { background: rgba(0,200,255,.1);  color: var(--c-cyan);  border: 1px solid rgba(0,200,255,.3); }

/* ─── Forms ───────────────────────────────────────────────────────────────── */
.form-group { margin-bottom: 1.1rem; }
.form-group--row   { display: flex; justify-content: flex-end; }
.form-group--check { display: flex; align-items: center; gap: .5rem; }
.form-label {
  display: block; font-size: .78rem; font-weight: 700;
  color: var(--c-cyan); margin-bottom: .35rem;
  letter-spacing: .08em; text-transform: uppercase;
}
.form-input {
  width: 100%;
  padding: .7rem 1rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  color: var(--c-text);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.form-input:focus {
  outline: none;
  border-color: var(--c-cyan);
  box-shadow: 0 0 10px rgba(0,200,255,.1);
  background: rgba(0, 0, 0, 0.4);
}
.form-input option,
select.form-input option {
  background: #1a1a2e;
  color: #fff;
}
.form-input::placeholder { color: var(--c-muted); opacity: .7; }
.form-input:disabled { opacity: .45; cursor: not-allowed; }
.form-input--sm { padding: .3rem .6rem; font-size: .8rem; width: auto; }
.form-textarea { resize: vertical; min-height: 100px; }
.form-hint { font-size: .75rem; color: var(--c-muted); margin-top: .3rem; }
.form-row { display: flex; gap: 1rem; }
.form-row > .form-group { flex: 1; }
.form-actions { display: flex; gap: .75rem; }
.link-sm { font-size: .85rem; color: var(--c-cyan); }
.link-sm:hover { color: #fff; }

/* ─── Cyber Card ─────────────────────────────────────────────────────────── */
.card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  backdrop-filter: blur(12px);
  position: relative;
  overflow: hidden;
}
.card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--c-cyan), var(--c-purple), transparent);
  animation: scanline 3s ease-in-out infinite;
}
@keyframes scanline {
  0%,100% { opacity: .4; }
  50%      { opacity: 1; }
}
.card__title { font-size: 1.05rem; font-weight: 700; margin-bottom: 1rem; color: var(--c-cyan); }

/* ─── Hero ────────────────────────────────────────────────────────────────── */
.hero {
  background:
    radial-gradient(ellipse 800px 500px at 50% 0%, rgba(168,85,247,.18) 0%, transparent 70%),
    linear-gradient(180deg, rgba(0,200,255,.05) 0%, transparent 100%),
    var(--c-bg2);
  border-bottom: 1px solid var(--c-border);
  padding: 5rem 0;
  position: relative; overflow: hidden;
}
/* Animated particles in hero */
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(2px 2px at 15% 25%, rgba(0,200,255,.6) 0%, transparent 100%),
    radial-gradient(2px 2px at 85% 15%, rgba(168,85,247,.6) 0%, transparent 100%),
    radial-gradient(1px 1px at 45% 65%, rgba(0,255,136,.6) 0%, transparent 100%),
    radial-gradient(2px 2px at 70% 80%, rgba(0,200,255,.4) 0%, transparent 100%),
    radial-gradient(1px 1px at 25% 75%, rgba(240,171,252,.5) 0%, transparent 100%),
    radial-gradient(2px 2px at 90% 50%, rgba(0,255,136,.4) 0%, transparent 100%);
  animation: particlesDrift 10s ease-in-out infinite alternate;
}
@keyframes particlesDrift {
  0%   { transform: translate(0,0); }
  100% { transform: translate(-20px, -15px); }
}
.hero::after {
  content: '';
  position: absolute; left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(0,200,255,.06) 0%, transparent 65%);
  animation: heroPulse 5s ease-in-out infinite;
}
@keyframes heroPulse {
  0%,100% { transform: translate(-50%,-50%) scale(1); opacity: .6;}
  50%      { transform: translate(-50%,-50%) scale(1.15); opacity: 1;}
}
.hero__inner {
  display: grid; grid-template-columns: 1fr auto;
  align-items: center; gap: 2rem;
  position: relative; z-index: 1;
}
.hero__title {
  font-size: clamp(2rem, 4.5vw, 3.4rem);
  font-weight: 900; line-height: 1.1; margin-bottom: 1.2rem;
  background: linear-gradient(120deg, #fff 0%, var(--c-cyan) 50%, var(--c-purple) 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: titleShimmer 6s linear infinite;
  background-size: 200% auto;
}
@keyframes titleShimmer {
  0%   { background-position: 0% center; }
  100% { background-position: 200% center; }
}
.hero__sub {
  font-size: 1.1rem; color: var(--c-muted); margin-bottom: 2rem;
  max-width: 480px; line-height: 1.7;
}
.hero__visual {
  font-size: 8rem;
  filter: drop-shadow(0 0 30px rgba(0,200,255,.5)) drop-shadow(0 0 60px rgba(168,85,247,.3));
  animation: float 4s ease-in-out infinite, glow 3s ease-in-out infinite alternate;
}
@keyframes float {
  0%,100% { transform: translateY(0) rotate(-3deg); }
  50%      { transform: translateY(-16px) rotate(3deg); }
}
@keyframes glow {
  from { filter: drop-shadow(0 0 20px rgba(0,200,255,.4)) drop-shadow(0 0 50px rgba(168,85,247,.2)); }
  to   { filter: drop-shadow(0 0 40px rgba(0,200,255,.7)) drop-shadow(0 0 80px rgba(168,85,247,.5)); }
}

/* ─── Section ─────────────────────────────────────────────────────────────── */
.section { padding: 3rem 0; }
.section__title {
  font-size: 1.6rem; font-weight: 800; margin-bottom: 1.5rem;
  background: linear-gradient(90deg, var(--c-cyan), var(--c-purple));
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  display: inline-block;
}

/* ─── Product Grid ────────────────────────────────────────────────────────── */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.25rem;
}
.product-card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex; flex-direction: column;
  transition: all var(--transition);
  position: relative;
  cursor: pointer;
}
.product-card::after {
  content: '';
  position: absolute; inset: 0;
  border-radius: var(--radius-lg);
  border: 1px solid transparent;
  background: linear-gradient(135deg, rgba(0,200,255,.2), rgba(168,85,247,.2)) border-box;
  -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: destination-out;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity var(--transition);
}
.product-card:hover {
  transform: translateY(-6px);
  border-color: rgba(0,200,255,.4);
  box-shadow: 0 16px 40px rgba(0,0,0,.4), 0 0 20px rgba(0,200,255,.15);
  text-decoration: none;
}
.product-card:hover::after { opacity: 1; }
.product-card__img-wrap { aspect-ratio: 4/3; overflow: hidden; background: rgba(0,200,255,.04); }
.product-card__img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.product-card:hover .product-card__img { transform: scale(1.08); }
.product-card__img-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  font-size: 3rem;
  background: radial-gradient(ellipse at center, rgba(0,200,255,.08), transparent);
}
.product-card__name-link {
  color: inherit;
  text-decoration: none;
}
.product-card__name-link::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: 1;
}
.product-card__footer {
  z-index: 2; /* keep above link if needed */
  position: relative;
}
.product-card__body { padding: 1rem; flex: 1; display: flex; flex-direction: column; }
.product-card__name { font-weight: 700; font-size: .95rem; color: var(--c-text); margin-bottom: .25rem; }
.product-card__cat  { font-size: .75rem; color: var(--c-muted); margin-bottom: auto; letter-spacing: .04em; }
.product-card__footer { display: flex; align-items: center; justify-content: space-between; margin-top: .75rem; }
.product-card__price {
  font-size: 1.1rem; font-weight: 800;
  color: var(--c-cyan);
  text-shadow: 0 0 12px rgba(0,200,255,.4);
}

/* ─── Badges ──────────────────────────────────────────────────────────────── */
.badge {
  display: inline-block; padding: .18rem .65rem;
  border-radius: 999px; font-size: .7rem; font-weight: 700;
  letter-spacing: .06em; text-transform: uppercase;
}
.badge--green { background: rgba(0,255,136,.12); color: var(--c-green); border: 1px solid rgba(0,255,136,.25); }
.badge--red   { background: rgba(255,56,96,.12);  color: var(--c-red);   border: 1px solid rgba(255,56,96,.25); }
.badge--blue  { background: rgba(0,200,255,.12);  color: var(--c-cyan);  border: 1px solid rgba(0,200,255,.25); }
.badge        { background: rgba(107,140,190,.12); color: var(--c-muted); }

/* ─── Catalog Layout ─────────────────────────────────────────────────────── */
.catalog-layout { display: grid; grid-template-columns: 220px 1fr; gap: 2rem; align-items: start; }
.catalog-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.25rem; }
.catalog-count  { color: var(--c-muted); font-size: .9rem; }
.page-title {
  font-size: 1.6rem; font-weight: 800;
  background: linear-gradient(90deg, #fff, var(--c-cyan));
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}

/* ─── Sidebar ─────────────────────────────────────────────────────────────── */
.sidebar {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  backdrop-filter: blur(12px);
}
.sidebar__title {
  font-size: .72rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: .1em;
  color: var(--c-cyan); margin-bottom: .75rem;
}
.sidebar__list  { list-style: none; }
.sidebar__link  {
  display: block; padding: .5rem .75rem;
  border-radius: var(--radius); color: var(--c-muted); font-size: .9rem;
  transition: all var(--transition);
  border-left: 2px solid transparent;
}
.sidebar__link:hover       { color: var(--c-cyan); background: rgba(0,200,255,.06); border-left-color: var(--c-cyan); }
.sidebar__link--active     { color: var(--c-cyan); background: rgba(0,200,255,.08); border-left-color: var(--c-cyan); font-weight: 700; }

/* ─── Product Detail ─────────────────────────────────────────────────────── */
.breadcrumb { font-size: .85rem; color: var(--c-muted); margin-bottom: 1.5rem; }
.breadcrumb a { color: var(--c-muted); }
.breadcrumb a:hover { color: var(--c-cyan); }
.product-detail { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: start; }
.product-detail__img { width: 100%; border-radius: var(--radius-lg); border: 1px solid var(--c-border); box-shadow: 0 0 30px rgba(0,200,255,.15); }
.product-detail__img-placeholder {
  aspect-ratio: 1; background: radial-gradient(ellipse at center, rgba(0,200,255,.08), transparent);
  border-radius: var(--radius-lg); display: flex; align-items: center; justify-content: center;
  font-size: 6rem; border: 1px solid var(--c-border);
}
.product-detail__cat  { font-size: .75rem; color: var(--c-muted); text-transform: uppercase; letter-spacing: .1em; margin-bottom: .5rem; }
.product-detail__name { font-size: 1.9rem; font-weight: 900; margin-bottom: .75rem; color: #fff; }
.product-detail__desc { color: var(--c-muted); margin-bottom: 1.25rem; line-height: 1.75; }
.product-detail__price {
  font-size: 2.2rem; font-weight: 900;
  background: linear-gradient(90deg, var(--c-cyan), var(--c-purple));
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  margin-bottom: .5rem;
}
.product-detail__stock { font-size: .9rem; margin-bottom: 1rem; color: var(--c-green); }
.product-detail__stock--out { color: var(--c-red); }
.qty-row {
  display: flex; align-items: center; gap: 1rem; margin-top: 1.5rem;
}
.qty-row .form-label { margin-bottom: 0; }
.qty-input { width: 100px; text-align: center; }

/* Custom number input spins for dark theme */
input[type="number"].qty-input::-webkit-inner-spin-button,
input[type="number"].qty-input::-webkit-outer-spin-button {
  filter: invert(1);
  opacity: 1;
}

/* ─── Auth ────────────────────────────────────────────────────────────────── */
.auth-wrap {
  display: flex; align-items: center; justify-content: center;
  min-height: calc(100vh - 200px); padding: 2rem 1rem;
}
.auth-card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  width: 100%; max-width: 440px;
  backdrop-filter: blur(20px);
  box-shadow: 0 24px 64px rgba(0,0,0,.4), 0 0 40px rgba(0,200,255,.08);
  position: relative; overflow: hidden;
}
.auth-card::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--c-purple), var(--c-cyan), var(--c-purple));
  background-size: 200% auto;
  animation: borderFlow 3s linear infinite;
}
@keyframes borderFlow {
  0%   { background-position: 200% center; }
  100% { background-position: 0% center; }
}
.auth-card__title { font-size: 1.6rem; font-weight: 900; margin-bottom: 1.5rem; color: #fff; }
.auth-card__desc  { color: var(--c-muted); margin-bottom: 1.25rem; font-size: .9rem; }
.auth-card__footer{ margin-top: 1.25rem; text-align: center; font-size: .875rem; color: var(--c-muted); }

/* ─── Cart ────────────────────────────────────────────────────────────────── */
.cart-layout { display: grid; grid-template-columns: 1fr 340px; gap: 2rem; align-items: start; margin-top: 1.5rem; }
.cart-item {
  display: flex; align-items: center; gap: 1rem;
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-radius: var(--radius-lg); padding: 1rem;
  margin-bottom: .75rem; backdrop-filter: blur(12px);
  transition: border-color var(--transition);
}
.cart-item:hover { border-color: rgba(0,200,255,.3); }
.cart-item__img-wrap { width: 76px; height: 76px; border-radius: var(--radius); overflow: hidden; flex-shrink: 0; background: rgba(0,200,255,.04); }
.cart-item__img { width: 100%; height: 100%; object-fit: cover; }
.cart-item__img-placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 2rem; }
.cart-item__info { flex: 1; min-width: 0; }
.cart-item__name { font-weight: 700; color: var(--c-text); }
.cart-item__price{ font-size: .85rem; color: var(--c-muted); }
.cart-item__actions { display: flex; align-items: center; gap: .5rem; }
.cart-item__subtotal { font-weight: 800; min-width: 90px; text-align: right; color: var(--c-cyan); }
.qty-form { display: flex; }
.cart-summary {
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-radius: var(--radius-lg); padding: 1.5rem;
  position: sticky; top: 80px; backdrop-filter: blur(12px);
}
.cart-summary__title { font-size: 1.1rem; font-weight: 800; margin-bottom: 1rem; color: var(--c-cyan); }
.cart-summary__row   { display: flex; justify-content: space-between; font-size: .9rem; color: var(--c-muted); margin-bottom: .5rem; }
.cart-summary__total { display: flex; justify-content: space-between; font-size: 1.1rem; margin-top: .75rem; color: #fff; }

/* ─── Checkout ────────────────────────────────────────────────────────────── */
.checkout-layout { display: grid; grid-template-columns: 1fr 360px; gap: 2rem; align-items: start; margin-top: 1.5rem; }
.checkout-section {
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-radius: var(--radius-lg); padding: 1.5rem; margin-bottom: 1.25rem;
  backdrop-filter: blur(12px);
}
.checkout-section__title { font-size: 1rem; font-weight: 700; margin-bottom: 1rem; color: var(--c-cyan); }
.checkout-summary {
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-radius: var(--radius-lg); padding: 1.5rem;
  position: sticky; top: 80px; backdrop-filter: blur(12px);
}
.checkout-summary__title { font-size: 1.05rem; font-weight: 800; margin-bottom: 1rem; color: var(--c-cyan); }
.checkout-summary__item { display: flex; justify-content: space-between; font-size: .9rem; margin-bottom: .5rem; color: var(--c-muted); }
.checkout-summary__item-name { max-width: 200px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.checkout-summary__total { display: flex; justify-content: space-between; font-size: 1rem; margin-top: .75rem; color: #fff; }

.addr-option {
  display: flex; align-items: flex-start; gap: .75rem;
  padding: .75rem; border: 1px solid var(--c-border);
  border-radius: var(--radius); margin-bottom: .5rem; cursor: pointer;
  transition: all var(--transition);
}
.addr-option:has(input:checked) {
  border-color: var(--c-cyan);
  background: rgba(0,200,255,.06);
  box-shadow: 0 0 12px rgba(0,200,255,.1);
}
.addr-option input[type=radio] { margin-top: 2px; accent-color: var(--c-cyan); }
.addr-option__label strong { display: block; margin-bottom: .15rem; color: var(--c-text); }

/* card preview */
.card-preview {
  background: linear-gradient(135deg, #0d0d2b, #1a0533, #0d2040);
  color: #fff; border-radius: 16px; padding: 1.5rem;
  margin-bottom: 1.25rem;
  box-shadow: 0 12px 40px rgba(0,0,0,.5), 0 0 30px rgba(168,85,247,.3);
  border: 1px solid rgba(168,85,247,.3);
  font-family: var(--font-mono);
  position: relative; overflow: hidden;
  animation: cardGlow 4s ease-in-out infinite alternate;
}
@keyframes cardGlow {
  from { box-shadow: 0 12px 40px rgba(0,0,0,.5), 0 0 20px rgba(0,200,255,.2); }
  to   { box-shadow: 0 12px 40px rgba(0,0,0,.5), 0 0 30px rgba(168,85,247,.4); }
}
.card-preview::before {
  content: '◈';
  position: absolute; top: 1rem; right: 1rem;
  font-size: 1.8rem; opacity: .3; color: var(--c-cyan);
}
.card-preview__number { font-size: 1.3rem; letter-spacing: .18em; margin-bottom: .75rem; }
.card-preview__meta   { display: flex; justify-content: space-between; font-size: .85rem; opacity: .7; }

/* ─── Account ─────────────────────────────────────────────────────────────── */
.account-layout { display: grid; grid-template-columns: 200px 1fr; gap: 2rem; align-items: start; }
.account-nav {
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-radius: var(--radius-lg); padding: 1rem;
  display: flex; flex-direction: column; gap: .2rem;
  backdrop-filter: blur(12px);
}
.account-nav__link {
  display: flex; align-items: center; gap: .5rem;
  padding: .65rem .9rem; border-radius: var(--radius);
  color: var(--c-muted); font-weight: 600; font-size: .88rem;
  transition: all var(--transition);
  border-left: 2px solid transparent;
}
.account-nav__link:hover {
  color: var(--c-cyan); background: rgba(0,200,255,.06);
  border-left-color: var(--c-cyan);
}
.account-content { min-width: 0; }

/* addresses */
.addr-list { display: flex; flex-direction: column; gap: .75rem; }
.addr-card {
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-radius: var(--radius-lg); padding: 1rem 1.25rem;
  display: flex; align-items: center; gap: 1rem;
  transition: border-color var(--transition);
}
.addr-card--default { border-color: rgba(0,200,255,.4); box-shadow: 0 0 12px rgba(0,200,255,.08); }
.addr-card__label { font-weight: 800; flex-shrink: 0; color: var(--c-cyan); }
.addr-card__text  { color: var(--c-muted); font-size: .9rem; flex: 1; }
.addr-card__del   { margin-left: auto; }

/* orders */
.orders-list { display: flex; flex-direction: column; gap: .75rem; }
.order-card {
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-radius: var(--radius-lg); padding: 1rem 1.5rem;
  display: flex; align-items: center; gap: 1.5rem;
  transition: all var(--transition);
}
.order-card:hover {
  border-color: rgba(0,200,255,.35);
  transform: translateX(4px);
  text-decoration: none;
  box-shadow: 0 4px 20px rgba(0,0,0,.3), 0 0 12px rgba(0,200,255,.1);
}
.order-card__id   { font-weight: 800; min-width: 60px; color: var(--c-cyan); }
.order-card__date { color: var(--c-muted); font-size: .85rem; }
.order-card__status { flex: 1; }
.order-card__total  { font-weight: 800; color: var(--c-text); }
.order-card__arrow  { color: var(--c-muted); }
.order-detail-header { display: flex; align-items: center; gap: 1rem; margin-bottom: .5rem; }

/* status badges */
.status-badge { display: inline-block; padding: .25rem .75rem; border-radius: 999px; font-size: .75rem; font-weight: 700; letter-spacing: .04em; }
.status-badge--pending   { background: rgba(251,191,36,.12);  color: var(--c-amber);   border: 1px solid rgba(251,191,36,.25); }
.status-badge--paid      { background: rgba(0,255,136,.12);   color: var(--c-green);   border: 1px solid rgba(0,255,136,.25); }
.status-badge--shipped   { background: rgba(0,200,255,.12);   color: var(--c-cyan);    border: 1px solid rgba(0,200,255,.25); }
.status-badge--done      { background: rgba(168,85,247,.12);  color: var(--c-purple);  border: 1px solid rgba(168,85,247,.25); }
.status-badge--cancelled { background: rgba(255,56,96,.12);   color: var(--c-red);     border: 1px solid rgba(255,56,96,.25); }

/* ─── Admin ───────────────────────────────────────────────────────────────── */
.admin-layout { display: grid; grid-template-columns: 200px 1fr; gap: 2rem; align-items: start; }
.admin-nav {
  background: rgba(0,10,30,.7);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg); padding: 1rem;
  display: flex; flex-direction: column; gap: .2rem;
  backdrop-filter: blur(16px);
}
.admin-nav__link {
  display: block; padding: .65rem .9rem; border-radius: var(--radius);
  color: var(--c-muted); font-size: .88rem; font-weight: 600;
  transition: all var(--transition);
  border-left: 2px solid transparent;
  letter-spacing: .02em;
}
.admin-nav__link:hover { color: var(--c-cyan); background: rgba(0,200,255,.06); border-left-color: var(--c-cyan); }
.admin-content { min-width: 0; }
.admin-page-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.25rem; }
.stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; }
.stat-card {
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-radius: var(--radius-lg); padding: 1.5rem; text-align: center;
  backdrop-filter: blur(12px);
  transition: all var(--transition);
}
.stat-card:hover { border-color: rgba(0,200,255,.35); transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0,0,0,.3), 0 0 16px rgba(0,200,255,.1); }
.stat-card__val   { font-size: 2.2rem; font-weight: 900; color: var(--c-cyan); text-shadow: var(--glow-cyan); }
.stat-card__label { font-size: .8rem; color: var(--c-muted); margin-top: .25rem; text-transform: uppercase; letter-spacing: .07em; }
.current-img { margin-bottom: .5rem; }
.inline-form { display: inline; }

/* ─── Table ───────────────────────────────────────────────────────────────── */
.table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.table th {
  text-align: left; padding: .65rem 1rem;
  border-bottom: 1px solid var(--c-border);
  font-weight: 700; color: var(--c-cyan);
  font-size: .72rem; text-transform: uppercase; letter-spacing: .09em;
}
.table td {
  padding: .65rem 1rem;
  border-bottom: 1px solid rgba(0,200,255,.07);
  vertical-align: middle;
  color: var(--c-text);
}
.table tr:last-child td { border-bottom: none; }
.table tr:hover td { background: rgba(0,200,255,.03); }
.table tfoot tr:hover td { background: none; }
.table-actions { display: flex; gap: .5rem; }

/* ─── Pagination ─────────────────────────────────────────────────────────── */
.pagination { display: flex; gap: .4rem; justify-content: center; margin-top: 2rem; flex-wrap: wrap; }
.pagination__btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: var(--radius);
  font-size: .88rem; font-weight: 700;
  border: 1px solid var(--c-border); color: var(--c-muted);
  transition: all var(--transition);
}
.pagination__btn:hover {
  border-color: var(--c-cyan); color: var(--c-cyan);
  background: rgba(0,200,255,.07);
  box-shadow: 0 0 8px rgba(0,200,255,.2);
}
.pagination__btn--active {
  background: linear-gradient(135deg, var(--c-cyan), var(--c-purple));
  color: #000; border-color: transparent;
  font-weight: 800;
  box-shadow: 0 0 12px rgba(0,200,255,.4);
}

/* ─── Empty state ─────────────────────────────────────────────────────────── */
.empty-state { text-align: center; padding: 4rem 1rem; }
.empty-state__icon { font-size: 3.5rem; margin-bottom: 1rem; animation: float 3s ease-in-out infinite; }
.empty-state__text { color: var(--c-muted); font-size: 1.05rem; }
.empty { text-align: center; padding: 2rem; color: var(--c-muted); }

/* ─── Footer ──────────────────────────────────────────────────────────────── */
.footer {
  background: rgba(4,10,26,.9);
  border-top: 1px solid var(--c-border);
  color: var(--c-muted); padding: 1.5rem 0;
  font-size: .85rem; text-align: center;
  margin-top: auto;
  backdrop-filter: blur(12px);
}

/* ─── Burger Menu Button (hidden on desktop) ──────────────────────────────── */
.nav__burger {
  display: none;
  background: none;
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  color: var(--c-text);
  font-size: 1.35rem;
  width: 40px; height: 40px;
  align-items: center; justify-content: center;
  cursor: pointer;
  transition: all var(--transition);
  flex-shrink: 0;
  margin-left: auto;
}
.nav__burger:hover {
  background: rgba(0,200,255,.1);
  border-color: var(--c-cyan);
  color: var(--c-cyan);
}
.nav__burger.open { border-color: var(--c-cyan); color: var(--c-cyan); background: rgba(0,200,255,.1); }

/* ─── Mobile Menu Overlay ─────────────────────────────────────────────────── */
.nav__mobile-overlay {
  display: none;
  position: fixed; inset: 0;
  background: rgba(0,0,0,.65);
  z-index: 98;
  backdrop-filter: blur(4px);
  animation: overlayIn .2s ease;
}
@keyframes overlayIn { from { opacity: 0; } to { opacity: 1; } }
.nav__mobile-overlay.open { display: block; }

/* ─── Mobile Menu Panel ───────────────────────────────────────────────────── */
.nav__mobile-menu {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: min(320px, 88vw);
  height: 100%;
  background: rgba(4,10,26,.97);
  border-right: 1px solid var(--c-border);
  z-index: 99;
  flex-direction: column;
  padding: 1.5rem 1rem;
  overflow-y: auto;
  transform: translateX(-100%);
  transition: transform .28s cubic-bezier(.4,0,.2,1);
  backdrop-filter: blur(24px);
}
.nav__mobile-menu.open {
  display: flex;
  transform: translateX(0);
  animation: slideInLeft .28s cubic-bezier(.4,0,.2,1);
}
@keyframes slideInLeft {
  from { transform: translateX(-100%); }
  to   { transform: translateX(0); }
}
.nav__mobile-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 1.5rem; padding-bottom: 1rem;
  border-bottom: 1px solid var(--c-border);
}
.nav__mobile-logo {
  font-size: 1.3rem; font-weight: 800;
  background: linear-gradient(90deg, var(--c-cyan), var(--c-purple));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
.nav__mobile-close {
  background: none; border: 1px solid var(--c-border);
  color: var(--c-muted); border-radius: var(--radius);
  width: 32px; height: 32px; font-size: 1.1rem;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: all var(--transition);
}
.nav__mobile-close:hover { color: var(--c-red); border-color: var(--c-red); }

.nav__mobile-links {
  display: flex; flex-direction: column; gap: .25rem; margin-bottom: 1.5rem;
}
.nav__mobile-link {
  display: flex; align-items: center; gap: .75rem;
  padding: .8rem 1rem; border-radius: var(--radius);
  color: var(--c-text); font-weight: 600; font-size: .95rem;
  border: 1px solid transparent;
  transition: all var(--transition);
}
.nav__mobile-link:hover {
  color: var(--c-cyan);
  background: rgba(0,200,255,.07);
  border-color: var(--c-border);
}
.nav__mobile-link .link-icon { font-size: 1.1rem; width: 24px; text-align: center; }
.nav__mobile-divider {
  border: none; border-top: 1px solid var(--c-border);
  margin: .75rem 0;
}
.nav__mobile-user {
  margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--c-border);
}
.nav__mobile-username {
  font-size: .8rem; color: var(--c-muted); margin-bottom: .5rem;
  text-transform: uppercase; letter-spacing: .06em;
}

/* ─── Bottom Navigation Bar (mobile only) ────────────────────────────────── */
.bottom-nav {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0;
  height: 60px;
  background: rgba(4,10,26,.96);
  border-top: 1px solid var(--c-border);
  z-index: 97;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding-bottom: env(safe-area-inset-bottom);
}
.bottom-nav__inner {
  display: flex; align-items: stretch;
  height: 100%;
}
.bottom-nav__item {
  flex: 1; display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: .2rem; color: var(--c-muted); font-size: .65rem;
  font-weight: 600; letter-spacing: .03em; text-transform: uppercase;
  border: none; background: none; cursor: pointer;
  transition: color var(--transition), background var(--transition);
  text-decoration: none; position: relative;
}
.bottom-nav__item:hover { color: var(--c-cyan); background: rgba(0,200,255,.06); }
.bottom-nav__item.active { color: var(--c-cyan); }
.bottom-nav__item.active::after {
  content: ''; display: block;
  position: absolute; top: 0; left: 20%; right: 20%;
  height: 2px;
  background: linear-gradient(90deg, var(--c-cyan), var(--c-purple));
  border-radius: 0 0 2px 2px;
}
.bottom-nav__icon { font-size: 1.3rem; line-height: 1; }
.bottom-nav__badge {
  position: absolute; top: 6px; left: 50%; margin-left: 2px;
  background: var(--c-cyan); color: #000;
  border-radius: 999px; font-size: .55rem; font-weight: 900;
  width: 15px; height: 15px;
  display: flex; align-items: center; justify-content: center;
}

.mobile-only-inline { display: none !important; }

/* ─── Responsive: Tablet (≤ 900px) ──────────────────────────────────────── */
@media (max-width: 900px) {
  .mobile-only-inline { display: inline-flex !important; }
  .catalog-layout { grid-template-columns: 1fr; }
  .sidebar { display: none; margin-bottom: 1.5rem; }
  .sidebar.sidebar--open { display: block; animation: dropIn .2s ease; }
  .cart-layout, .checkout-layout { grid-template-columns: 1fr; }
  .cart-summary, .checkout-summary { position: static; }
  .product-detail { grid-template-columns: 1fr; }
  .hero__inner { grid-template-columns: 1fr; }
  .hero__visual { display: none; }

  /* Account & Admin: switch to single column */
  .account-layout { grid-template-columns: 1fr; }
  .account-nav {
    flex-direction: row; flex-wrap: wrap;
    gap: .35rem; padding: .5rem;
  }
  .account-nav__link { padding: .4rem .75rem; font-size: .82rem; }

  .admin-layout { grid-template-columns: 1fr; }
  .admin-nav {
    flex-direction: row; flex-wrap: nowrap;
    overflow-x: auto; gap: .25rem;
    padding: .5rem; border-radius: var(--radius);
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .admin-nav::-webkit-scrollbar { display: none; }
  .admin-nav__link {
    flex-shrink: 0; padding: .45rem .8rem;
    font-size: .82rem; white-space: nowrap;
    border-left: none; border-bottom: 2px solid transparent;
  }
  .admin-nav__link:hover { border-left-color: transparent; border-bottom-color: var(--c-cyan); }

  /* Tables: horizontal scroll */
  .table-wrapper { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .table { min-width: 600px; }

  /* Stats grid */
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ─── Responsive: Mobile (≤ 640px) ──────────────────────────────────────── */
@media (max-width: 640px) {
  /* Nav: hide desktop links, show burger */
  .nav__links { display: none; }
  .nav__burger { display: flex; }

  /* Show bottom nav bar */
  .bottom-nav { display: block; }

  /* Add bottom padding so content is not hidden behind bottom nav */
  body { padding-bottom: 60px; }

  /* Main padding */
  .main { padding: 1.25rem 0; }

  /* Product grid: 2 columns */
  .product-grid { grid-template-columns: repeat(2, 1fr); gap: .75rem; }

  /* Product card adjustments */
  .product-card__img-wrap { height: 160px; }
  .product-card__body { padding: .65rem; }
  .product-card__name { font-size: .82rem; }
  .product-card__price { font-size: 1rem; }
  .btn--card-add { padding: .45rem; font-size: .78rem; width: 100%; }

  /* Product detail page */
  .product-detail { grid-template-columns: 1fr; gap: 1.25rem; }
  .product-gallery { border-radius: var(--radius); }

  /* Forms */
  .form-row { flex-direction: column; gap: 0; }
  .card { padding: 1.25rem; }

  /* Buttons */
  .nav__links .btn { display: none; }

  /* Stats grid: single column */
  .stats-grid { grid-template-columns: 1fr; }

  /* Cart/Checkout single column */
  .cart-layout, .checkout-layout { grid-template-columns: 1fr; gap: 1rem; }

  /* Hero */
  .hero__content h1 { font-size: 1.9rem; }
  .hero__subtitle { font-size: .9rem; }

  /* Search container: full width on mobile */
  .search-container {
    position: fixed; top: 64px; left: 0; right: 0;
    padding: .5rem .75rem; background: rgba(4,10,26,.98);
    border-bottom: 1px solid var(--c-border);
    margin: 0; display: none; z-index: 95;
  }
  .search-container.mobile-open { display: block; }
  .search-input { width: 100%; border-radius: var(--radius); }

  /* Admin table: allow horizontal scroll */
  .admin-content { overflow-x: hidden; }
  .table-wrapper { overflow-x: auto; border-radius: var(--radius); }
  .table { min-width: 520px; }

  /* Admin forms: one column */
  .admin-page-header { flex-direction: column; align-items: flex-start; gap: .75rem; }
  .admin-page-header .btn { width: 100%; justify-content: center; }

  /* Reduce modal width */
  .modal-box { width: 95vw; max-height: 92vh; }

  /* Flash messages */
  .flash { margin: 0; border-radius: 0; font-size: .9rem; }

  /* Order card: stack */
  .order-card {
    flex-direction: column; align-items: flex-start;
    gap: .4rem; padding: .85rem 1rem;
  }
  .order-card__arrow { display: none; }

  /* Bottom margin for toast so it doesn't overlap bottom nav */
  #toast-container { bottom: 70px; right: .75rem; left: .75rem; align-items: center; }
  .toast { min-width: unset; width: 100%; }

  /* Page title font */
  .page-title { font-size: 1.5rem; }

  /* Product attrs table */
  .attr-table { font-size: .85rem; }
}

/* ─── Responsive: Small Mobile (≤ 380px) ────────────────────────────────── */
@media (max-width: 380px) {
  .product-grid { grid-template-columns: 1fr; }
  .hero__content h1 { font-size: 1.6rem; }
}

/* ─── Touch device: larger tap targets ───────────────────────────────────── */
@media (hover: none) and (pointer: coarse) {
  .btn { padding: .7rem 1.35rem; }
  .btn--sm { padding: .5rem .9rem; min-height: 36px; }
  .nav__mobile-link { padding: 1rem 1rem; }
  .dropdown-item { padding: .9rem 1.1rem; }
  .bottom-nav__item { padding: .4rem 0; }
}



/* ==========================================================================
   Reviews & Ratings
   ========================================================================== */
.reviews-section {
  margin-top: 4rem;
  padding: 2rem;
  background: var(--surface-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  backdrop-filter: blur(10px);
}

.reviews-section h3 {
  margin-top: 0;
  color: var(--primary);
  text-shadow: 0 0 10px rgba(0, 243, 255, 0.3);
}

.review-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-top: 2rem;
}

.review-card {
  padding: 1.5rem;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-left: 3px solid var(--primary);
  border-radius: var(--radius);
}

.review-card__header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.review-card__author {
  font-weight: 600;
  color: var(--text-base);
}

.review-card__date {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.stars {
  color: #fbbf24;
  margin-bottom: 0.5rem;
  text-shadow: 0 0 5px rgba(251, 191, 36, 0.5);
}

.rating-select select {
  width: 150px;
}

/* ==========================================================================
   Live Search Dropdown
   ========================================================================== */
.search-container {
  position: relative;
  display: inline-block;
  margin-right: 1.5rem;
}

.search-input {
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border-color);
  color: var(--text-base);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  width: 200px;
  transition: all 0.3s ease;
}

.search-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 15px rgba(0, 243, 255, 0.2);
  width: 280px;
  background: rgba(0,0,0,0.5);
}

.search-results {
  position: absolute;
  top: calc(100% + 5px);
  left: 0;
  width: 100%;
  background: rgba(10, 10, 15, 0.95);
  border: 1px solid var(--primary);
  border-radius: var(--radius);
  max-height: 400px;
  overflow-y: auto;
  z-index: 1000;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.5);
  display: none;
  backdrop-filter: blur(10px);
}

.search-results.active {
  display: block;
}

.search-result-item {
  display: flex;
  align-items: center;
  padding: 0.75rem;
  border-bottom: 1px solid var(--border-color);
  text-decoration: none;
  color: var(--text-base);
  transition: background 0.2s;
}

.search-result-item:hover {
  background: rgba(0, 243, 255, 0.1);
}

.search-result-img {
  width: 40px;
  height: 40px;
  object-fit: contain;
  margin-right: 1rem;
  background: black;
  border-radius: 4px;
}

/* ==========================================================================
   Toasts & Notifications
   ========================================================================== */
#toast-container {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.toast {
  position: relative;
  min-width: 250px;
  padding: 1rem 1.5rem;
  border-radius: var(--radius);
  background: rgba(10, 10, 15, 0.95);
  backdrop-filter: blur(10px);
  color: white;
  border-left: 4px solid var(--primary);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
  transform: translateX(120%);
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s;
  overflow: hidden;
}

.toast::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; height: 3px;
  background: var(--primary);
  width: 100%;
  animation: toastProgress 5s linear forwards;
}

@keyframes toastProgress {
  to { width: 0; }
}

.toast.show {
  transform: translateX(0);
}

.toast.removing {
  transform: translateY(-20px);
  opacity: 0;
}

.toast.success { border-left-color: #10b981; }
.toast.success::after { background: #10b981; }
.toast.error { border-left-color: var(--danger); box-shadow: 0 0 15px rgba(255, 0, 85, 0.3); }
.toast.error::after { background: var(--danger); }

/* ==========================================================================
   Skeleton Loaders
   ========================================================================== */
.skeleton {
  background: linear-gradient(90deg, 
      rgba(255,255,255, 0.05) 0%, 
      rgba(255,255,255, 0.1) 50%, 
      rgba(255,255,255, 0.05) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite linear;
  border-radius: 4px;
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.product-img-wrapper.skeleton,
.product-card__img-wrap.skeleton {
  display: block; width: 100%; height: 100%;
}

/* Wishlist Button */
.btn-wishlist {
  background: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-base);
  padding: 0.5rem;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  font-size: 1.2rem;
  margin-left: 1rem;
}

.btn-wishlist:hover {
  background: rgba(255, 0, 85, 0.1);
  border-color: var(--danger);
  color: var(--danger);
  transform: scale(1.1);
}

.btn-wishlist.active {
  background: rgba(255, 0, 85, 0.2);
  border-color: var(--danger);
  color: var(--danger);
  box-shadow: 0 0 15px rgba(255, 0, 85, 0.4);
}

/* ==========================================================================
   Cart Drawer (Slide-out from Right)
   ========================================================================== */
.cart-overlay {
  position: fixed; inset: 0;
  background: rgba(0, 0, 0, 0.6); backdrop-filter: blur(4px);
  z-index: 9998; opacity: 0; pointer-events: none;
  transition: opacity 0.3s ease;
}
.cart-overlay.active { opacity: 1; pointer-events: auto; }

.cart-drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: 100%; max-width: 400px;
  background: var(--c-surface); border-left: 1px solid var(--c-border);
  z-index: 9999; transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1);
  display: flex; flex-direction: column;
  box-shadow: -10px 0 30px rgba(0,0,0,0.5); backdrop-filter: blur(15px);
}
.cart-drawer.open { transform: translateX(0); }

.cart-drawer__header {
  padding: 1.5rem; border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  display: flex; justify-content: space-between; align-items: center;
}
.cart-drawer__header h3 { margin: 0; color: var(--c-cyan); }
.cart-drawer__close {
  background: transparent; border: none; color: var(--c-muted);
  font-size: 1.5rem; cursor: pointer; transition: color 0.2s;
}
.cart-drawer__close:hover { color: var(--c-red); }

.cart-drawer__body { flex: 1; overflow-y: auto; padding: 1.5rem; }
.cart-drawer__footer {
  padding: 1.5rem; border-top: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(0, 0, 0, 0.2);
}
.cart-drawer__total {
  display: flex; justify-content: space-between; font-size: 1.25rem;
  font-weight: 700; margin-bottom: 1rem; color: var(--c-text);
}
.drawer-item {
  display: flex; gap: 1rem; margin-bottom: 1rem; padding-bottom: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.drawer-item__img {
  width: 70px; height: 70px; object-fit: cover; border-radius: var(--radius);
  background: rgba(255,255,255,0.05);
}
.drawer-item__info { flex: 1; display: flex; flex-direction: column; }
.drawer-item__name {
  font-weight: 600; font-size: 0.95rem; margin-bottom: 0.25rem; display: block;
  text-decoration: none; color: var(--c-text);
}
.drawer-item__price { color: var(--c-cyan); font-size: 0.9rem; margin-top: auto; }
.drawer-item__qty { font-size: 0.85rem; color: var(--c-muted); }
