/* NST Genuine — Premium Tech Shop Theme (desktop + mobile) */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@500;600&family=Outfit:wght@500;600;700;800&display=swap');

:root {
  --nst-navy: #0f2744;
  --nst-navy-mid: #1e3a5f;
  --nst-orange: #e67e22;
  --nst-orange-soft: #f39c12;
  --nst-cyan: #00d4aa;
  --font-display: 'Outfit', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 8px 32px rgba(15, 39, 68, 0.08);
  --shadow-lg: 0 20px 50px rgba(15, 39, 68, 0.15);
  --nav-h: 64px;
  --bottom-nav-h: 64px;
  --bg: #eef2f7;
  --bg-elevated: #ffffff;
  --text: #0f172a;
  --text-muted: #64748b;
  --border: rgba(15, 39, 68, 0.1);
  --glass: rgba(255, 255, 255, 0.82);
  --hero-bg: linear-gradient(135deg, #0a1628 0%, #0f2744 45%, #1a3a5c 100%);
  --grid-line: rgba(255, 255, 255, 0.04);
  --card-hover: translateY(-6px);
  --in-stock: #10b981;
  --low-stock: #f59e0b;
  --out-stock: #94a3b8;
}

[data-theme="dark"] {
  --bg: #060d18;
  --bg-elevated: #0f1c2e;
  --text: #e8edf4;
  --text-muted: #94a3b8;
  --border: rgba(255, 255, 255, 0.08);
  --glass: rgba(15, 28, 46, 0.88);
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.5);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

body.shop-premium {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  padding-bottom: calc(var(--bottom-nav-h) + 1rem);
}

@media (min-width: 992px) {
  body.shop-premium { padding-bottom: 0; }
}

.shop-premium h1, .shop-premium h2, .shop-premium h3,
.shop-premium h4, .shop-premium h5, .shop-premium .section-title {
  font-family: var(--font-display);
  letter-spacing: -0.02em;
}

.shop-premium .font-mono { font-family: var(--font-mono); }

/* —— Nav —— */
.shop-nav-premium {
  background: var(--glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  min-height: var(--nav-h);
  transition: box-shadow 0.25s ease;
}
.shop-nav-premium.scrolled { box-shadow: var(--shadow); }
.shop-nav-premium .navbar-brand span {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
}
.shop-nav-premium .nav-link.shop {
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.9rem;
  padding: 0.4rem 0.65rem !important;
  border-radius: 8px;
  transition: color 0.2s, background 0.2s;
}
.shop-nav-premium .nav-link.shop:hover,
.shop-nav-premium .nav-link.shop.active {
  color: var(--nst-orange);
  background: rgba(230, 126, 34, 0.08);
}
.shop-search-wrap {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.15rem 0.15rem 0.15rem 1rem;
  max-width: 280px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.shop-search-wrap:focus-within {
  border-color: var(--nst-orange);
  box-shadow: 0 0 0 3px rgba(230, 126, 34, 0.15);
}
.shop-search-wrap input {
  border: none;
  background: transparent;
  box-shadow: none !important;
  font-size: 0.875rem;
}
.shop-search-wrap input:focus { outline: none; }
.shop-search-wrap .btn-search {
  border-radius: 999px;
  background: var(--nst-navy);
  color: #fff;
  border: none;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
}
[data-theme="dark"] .shop-search-wrap .btn-search {
  background: var(--nst-orange);
}
.btn-theme-toggle {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color 0.2s;
}
.btn-theme-toggle:hover { border-color: var(--nst-orange); }

/* —— Hero —— */
.hero-premium {
  position: relative;
  background: var(--hero-bg);
  color: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  padding: 3rem 1.5rem;
  margin-bottom: 2rem;
}
@media (min-width: 768px) { .hero-premium { padding: 4.5rem 2.5rem; } }
.hero-premium::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
}
.hero-premium::after {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 60%;
  height: 150%;
  background: radial-gradient(ellipse, rgba(230, 126, 34, 0.18) 0%, transparent 70%);
  pointer-events: none;
}
.hero-premium .hero-inner { position: relative; z-index: 1; }
.hero-premium h1 {
  font-size: clamp(1.75rem, 5vw, 2.75rem);
  font-weight: 800;
  line-height: 1.15;
}
.hero-premium .hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--nst-cyan);
  margin-bottom: 1rem;
}
.hero-premium .hero-tag::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--nst-cyan);
  box-shadow: 0 0 12px var(--nst-cyan);
  animation: pulse-dot 2s ease infinite;
}
@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}
.hero-search-mega {
  max-width: 640px;
  margin: 1.75rem auto 0;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 16px;
  padding: 0.5rem;
  backdrop-filter: blur(8px);
}
.hero-search-mega input {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 1rem;
  padding: 0.65rem 1rem;
}
.hero-search-mega input::placeholder { color: rgba(255,255,255,0.5); }
.hero-search-mega input:focus { outline: none; box-shadow: none; }
.hero-search-mega .btn-hero-search {
  background: linear-gradient(135deg, var(--nst-orange), var(--nst-orange-soft));
  border: none;
  color: #fff;
  font-weight: 600;
  border-radius: 12px;
  padding: 0.65rem 1.5rem;
  white-space: nowrap;
}
.hero-search-mega kbd {
  font-size: 0.65rem;
  opacity: 0.5;
  background: rgba(255,255,255,0.1);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
}

/* —— Stats strip —— */
.stats-strip {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}
@media (min-width: 768px) {
  .stats-strip { grid-template-columns: repeat(4, 1fr); }
}
.stat-card-premium {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  text-align: center;
  transition: transform 0.2s, box-shadow 0.2s;
}
.stat-card-premium:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}
.stat-card-premium .stat-num {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--nst-orange);
  line-height: 1;
}
.stat-card-premium .stat-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.35rem;
}

/* —— Brand wall —— */
.brand-wall {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  justify-content: center;
}
.brand-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 1.1rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 999px;
  text-decoration: none;
  color: var(--text);
  font-weight: 600;
  font-size: 0.85rem;
  transition: all 0.2s;
}
.brand-chip:hover {
  border-color: var(--nst-orange);
  color: var(--nst-orange);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(230, 126, 34, 0.15);
}
.brand-chip .brand-letter {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--nst-navy);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}
[data-theme="dark"] .brand-chip .brand-letter {
  background: var(--nst-orange);
}

/* —— Feature cards —— */
.feature-grid .feature-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  height: 100%;
  transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
}
.feature-grid .feature-card:hover {
  transform: var(--card-hover);
  box-shadow: var(--shadow-lg);
  border-color: rgba(230, 126, 34, 0.3);
}
.feature-grid .feature-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--nst-navy), var(--nst-navy-mid));
  color: var(--nst-orange);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 1rem;
}

/* —— Product cards —— */
.product-card-premium {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  height: 100%;
  display: flex;
  flex-direction: column;
  transition: transform 0.25s, box-shadow 0.25s;
}
.product-card-premium:hover {
  transform: var(--card-hover);
  box-shadow: var(--shadow-lg);
}
.product-card-premium .card-img-wrap {
  position: relative;
  background: #fff;
  height: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
[data-theme="dark"] .product-card-premium .card-img-wrap {
  background: #0a1420;
}
.product-card-premium .card-img-wrap img {
  max-height: 100%;
  max-width: 100%;
  object-fit: contain;
  padding: 12px;
  transition: transform 0.35s ease;
}
.product-card-premium:hover .card-img-wrap img { transform: scale(1.05); }
.stock-dot {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  box-shadow: 0 0 8px currentColor;
}
.stock-dot.in { color: var(--in-stock); background: var(--in-stock); }
.stock-dot.low { color: var(--low-stock); background: var(--low-stock); }
.stock-dot.out { color: var(--out-stock); background: var(--out-stock); }
.product-card-premium .card-body-premium {
  padding: 1rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.product-card-premium .sku-line {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}
.product-card-premium .price-premium {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--nst-orange);
}
.car-badge-premium {
  font-size: 0.68rem;
  font-weight: 600;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  background: rgba(15, 39, 68, 0.06);
  color: var(--nst-navy-mid);
  border: 1px solid var(--border);
}
[data-theme="dark"] .car-badge-premium {
  background: rgba(230, 126, 34, 0.1);
  color: var(--nst-orange-soft);
}
.btn-nst-primary {
  background: linear-gradient(135deg, var(--nst-orange), var(--nst-orange-soft));
  border: none;
  color: #fff;
  font-weight: 600;
  border-radius: 10px;
  transition: transform 0.15s, box-shadow 0.15s;
}
.btn-nst-primary:hover {
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(230, 126, 34, 0.35);
}
.btn-nst-outline {
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  color: var(--text);
  font-weight: 600;
  border-radius: 10px;
}
.btn-nst-outline:hover {
  border-color: var(--nst-orange);
  color: var(--nst-orange);
}

/* —— Catalog layout —— */
.catalog-layout {
  display: grid;
  gap: 1.5rem;
}
@media (min-width: 992px) {
  .catalog-layout {
    grid-template-columns: 260px 1fr;
    align-items: start;
  }
}
.catalog-sidebar {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  position: sticky;
  top: calc(var(--nav-h) + 1rem);
}
@media (max-width: 991px) {
  .catalog-sidebar { position: static; }
}
.catalog-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}
.view-toggle .btn {
  border-radius: 8px;
  padding: 0.35rem 0.65rem;
}
.view-toggle .btn.active {
  background: var(--nst-navy);
  color: #fff;
  border-color: var(--nst-navy);
}
[data-theme="dark"] .view-toggle .btn.active {
  background: var(--nst-orange);
  border-color: var(--nst-orange);
}

/* List view */
.catalog-grid.list-view .catalog-col { width: 100%; max-width: 100%; flex: 0 0 100%; }
.catalog-grid.list-view .product-card-premium {
  flex-direction: row;
  max-height: 140px;
}
.catalog-grid.list-view .card-img-wrap {
  width: 140px;
  min-width: 140px;
  height: auto;
}

/* Skeleton */
.skeleton {
  background: linear-gradient(90deg,
    var(--border) 25%,
    rgba(255,255,255,0.4) 50%,
    var(--border) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.2s ease infinite;
  border-radius: var(--radius-sm);
}
@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.skeleton-card { height: 280px; }

/* —— Product detail —— */
.product-detail-premium .gallery-main {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  min-height: 360px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}
.product-detail-premium .spec-chip {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  padding: 0.4rem 0.75rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
.nav-tabs-premium {
  border-bottom: 1px solid var(--border);
  gap: 0.25rem;
}
.nav-tabs-premium .nav-link {
  border: none;
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.75rem 1.25rem;
  border-radius: 10px 10px 0 0;
}
.nav-tabs-premium .nav-link.active {
  color: var(--nst-orange);
  background: var(--bg-elevated);
  border-bottom: 2px solid var(--nst-orange);
}

/* —— VIN scanner UI —— */
.vin-panel {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  position: relative;
  overflow: hidden;
}
.vin-input-cells {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  justify-content: center;
  margin: 1.5rem 0;
}
.vin-input-cells input {
  width: 2rem;
  height: 2.5rem;
  text-align: center;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--bg);
  color: var(--text);
  text-transform: uppercase;
}
@media (min-width: 576px) {
  .vin-input-cells input { width: 2.25rem; }
}
.vin-hidden-input { position: absolute; opacity: 0; pointer-events: none; height: 0; }
.vin-stepper {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}
.vin-step {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}
.vin-step.active { color: var(--nst-orange); }
.vin-step.done { color: var(--in-stock); }
.vin-step-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid currentColor;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
}
.vin-scan-line {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--nst-cyan), transparent);
  animation: scan 2s ease-in-out infinite;
  opacity: 0;
}
.vin-panel.scanning .vin-scan-line { opacity: 1; }
@keyframes scan {
  0%, 100% { top: 20%; }
  50% { top: 80%; }
}

/* —— Mobile bottom nav —— */
.shop-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--bottom-nav-h);
  background: var(--glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 1040;
  padding-bottom: env(safe-area-inset-bottom, 0);
}
@media (min-width: 992px) { .shop-bottom-nav { display: none; } }
.shop-bottom-nav a {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.65rem;
  font-weight: 600;
  padding: 0.35rem 0.5rem;
  border-radius: 10px;
  min-width: 56px;
  position: relative;
}
.shop-bottom-nav a i { font-size: 1.25rem; }
.shop-bottom-nav a.active {
  color: var(--nst-orange);
}
.shop-bottom-nav .nav-badge {
  position: absolute;
  top: 0;
  right: 4px;
  font-size: 0.6rem;
  background: var(--nst-orange);
  color: #fff;
  border-radius: 999px;
  min-width: 16px;
  height: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* —— Footer —— */
.shop-footer-premium {
  background: var(--nst-navy);
  color: rgba(255, 255, 255, 0.85);
  margin-top: 3rem;
  padding: 3rem 0 1.5rem;
}
.shop-footer-premium a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
}
.shop-footer-premium a:hover { color: var(--nst-orange); }
.shop-footer-premium h6 {
  color: #fff;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1rem;
}

/* —— Toast —— */
.nst-toast {
  position: fixed;
  bottom: calc(var(--bottom-nav-h) + 1rem);
  right: 1rem;
  z-index: 9999;
  background: var(--bg-elevated);
  border: 1px solid var(--nst-orange);
  border-radius: 12px;
  padding: 0.85rem 1.25rem;
  box-shadow: var(--shadow-lg);
  animation: slideUp 0.3s ease;
}
@media (min-width: 992px) {
  .nst-toast { bottom: 1.5rem; }
}
@keyframes slideUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* —— WhatsApp FAB —— */
.wa-fab {
  position: fixed;
  bottom: calc(var(--bottom-nav-h) + 1rem);
  right: 1rem;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #25D366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.45);
  z-index: 1035;
  border: none;
  transition: transform 0.2s;
}
@media (min-width: 992px) {
  .wa-fab { bottom: 1.5rem; }
}
.wa-fab:hover { transform: scale(1.08); color: #fff; }

/* —— Premium surfaces for inner pages —— */
.surface-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}
.shop-premium .form-control,
.shop-premium .form-select {
  background: var(--bg-elevated);
  border-color: var(--border);
  color: var(--text);
  border-radius: var(--radius-sm);
}
.shop-premium .form-control:focus,
.shop-premium .form-select:focus {
  border-color: var(--nst-orange);
  box-shadow: 0 0 0 3px rgba(230, 126, 34, 0.12);
}
.shop-premium .table {
  color: var(--text);
  --bs-table-bg: transparent;
}
.shop-premium .alert { border-radius: var(--radius-sm); }

/* Pagination */
.shop-premium .pagination .page-link {
  border-color: var(--border);
  color: var(--text);
  background: var(--bg-elevated);
  border-radius: 8px !important;
  margin: 0 2px;
}
.shop-premium .pagination .page-item.active .page-link {
  background: var(--nst-navy);
  border-color: var(--nst-navy);
}
[data-theme="dark"] .shop-premium .pagination .page-item.active .page-link {
  background: var(--nst-orange);
  border-color: var(--nst-orange);
}

/* FAQ accordion */
.faq-premium .accordion-button {
  background: var(--bg-elevated);
  color: var(--text);
  box-shadow: none;
}
.faq-premium .accordion-button:not(.collapsed) {
  color: var(--nst-orange);
  background: var(--bg-elevated);
}
.faq-premium .accordion-button:focus {
  box-shadow: 0 0 0 3px rgba(230, 126, 34, 0.12);
}

/* CTA band */
.cta-premium {
  background: linear-gradient(135deg, rgba(15, 39, 68, 0.04), rgba(230, 126, 34, 0.06));
}
[data-theme="dark"] .cta-premium {
  background: linear-gradient(135deg, rgba(15, 39, 68, 0.5), rgba(230, 126, 34, 0.08));
}