:root {
  --primary: #5b5cf0;
  --secondary: #16c79a;
  --dark: #101828;
  --muted: #667085;
  --card-border: rgba(15, 23, 42, 0.08);
}

body {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--dark);
  background-color: #ffffff;
  background-image:
    linear-gradient(rgba(91, 92, 240, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(91, 92, 240, 0.05) 1px, transparent 1px);
  background-size: 28px 28px;
}

a {
  text-decoration: none;
}

.top-strip {
  background: linear-gradient(90deg, #0f172a, #1e293b);
  color: #fff;
  font-size: 0.92rem;
}

.main-navbar {
  top: 0;
  z-index: 1040;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

.navbar-brand {
  font-weight: 800;
  letter-spacing: 0.4px;
  color: var(--primary) !important;
  font-size: 1.55rem;
}

.search-box {
  width: 100%;
  max-width: 520px;
  position: relative;
}

.search-box input {
  border-radius: 50px;
  padding: 0.9rem 1rem 0.9rem 2.9rem;
  border: 1px solid #d0d5dd;
  box-shadow: none;
}

.search-box .search-icon {
  position: absolute;
  top: 50%;
  left: 16px;
  transform: translateY(-50%);
  color: #98a2b3;
  font-size: 1rem;
}

.icon-pill {
  border: 1px solid rgba(15, 23, 42, 0.08);
  padding: 0.65rem 0.9rem;
  border-radius: 999px;
  background: #fff;
  font-weight: 600;
  color: var(--dark);
}

.category-sticky-bar {
  position: sticky;
  top: 83px;
  z-index: 1030;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

.category-scroll {
  overflow-x: auto;
  white-space: nowrap;
  padding: 0.85rem 0;
  scrollbar-width: thin;
}

.category-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.62rem 1rem;
  border-radius: 999px;
  background: #f3f4f6;
  color: #344054;
  font-weight: 600;
  border: 1px solid transparent;
  transition: 0.2s ease;
}

.category-chip:hover,
.category-chip.active {
  background: rgba(91, 92, 240, 0.1);
  color: var(--primary);
  border-color: rgba(91, 92, 240, 0.15);
}

.custom-breadcrumb .breadcrumb-item a {
  color: var(--muted);
}

.custom-breadcrumb .breadcrumb-item.active {
  color: var(--dark);
  font-weight: 600;
}

.product-detail-card,
.content-card,
.product-card,
.cart-summary,
.gallery-card,
.product-info-card {
  border: 1px solid var(--card-border);
  border-radius: 1.25rem;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px);
}

.product-detail-card {
  padding: 1.5rem;
}

.gallery-card,
.product-info-card,
.content-card {
  padding: 1.5rem;
}

.main-image-wrap {
  position: relative;
}

.zoom-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 2;
  background: rgba(255,255,255,0.86);
  color: var(--dark);
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  border: 1px solid rgba(15, 23, 42, 0.08);
}

.main-product-image {
  min-height: 520px;
  border-radius: 1.2rem;
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 2rem;
  font-weight: 800;
  text-align: center;
}

.image-overlay-circle {
  position: absolute;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: rgba(255,255,255,0.12);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.image-overlay-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.08) 1px, transparent 1px);
  background-size: 26px 26px;
}

.product-text {
  position: relative;
  z-index: 1;
}

.thumb-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.9rem;
}

.thumb-card {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 1rem;
  background: #fff;
  padding: 0.35rem;
  transition: 0.2s ease;
}

.thumb-card.active,
.thumb-card:hover {
  border-color: var(--primary);
  box-shadow: 0 10px 25px rgba(91, 92, 240, 0.12);
}

.thumb-bg {
  min-height: 84px;
  border-radius: 0.8rem;
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 700;
}

.zoom-note {
  padding: 1rem;
  border-radius: 1rem;
  background: #f8fafc;
  color: var(--muted);
  font-size: 0.92rem;
}

.tag {
  display: inline-block;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
}

.tag-b2b {
  background: #e8f0ff;
  color: #2449d8;
}

.tag-b2c {
  background: #eafbf6;
  color: #0f8c67;
}

.tag-sale {
  background: #fff1f2;
  color: #be123c;
}

.product-title {
  font-size: 2.1rem;
  line-height: 1.1;
  font-weight: 800;
  margin-bottom: 1rem;
}

.product-summary {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.7;
}

.rating {
  color: #f59e0b;
  font-size: 0.95rem;
}

.divider-dot {
  width: 6px;
  height: 6px;
  background: #cbd5e1;
  border-radius: 50%;
}

.stock {
  font-weight: 700;
  font-size: 0.92rem;
}

.in-stock {
  color: #0f8c67;
}

.price-wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.8rem;
}

.price {
  font-weight: 800;
  font-size: 2rem;
}

.old-price {
  color: #98a2b3;
  text-decoration: line-through;
  font-size: 1.1rem;
}

.discount-pill {
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  background: #eef2ff;
  color: var(--primary);
  font-size: 0.86rem;
  font-weight: 700;
}

.feature-points {
  display: grid;
  gap: 0.8rem;
}

.feature-point {
  padding: 0.85rem 1rem;
  border-radius: 1rem;
  background: #f8fafc;
  border: 1px solid rgba(15, 23, 42, 0.06);
  font-weight: 500;
}

.meta-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.meta-box {
  padding: 1rem;
  border-radius: 1rem;
  background: #f8fafc;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

.meta-box small {
  display: block;
  color: var(--muted);
  margin-bottom: 0.25rem;
}

.meta-box strong {
  display: block;
  font-size: 0.98rem;
}

.variant-card {
  padding: 1rem;
  border-radius: 1rem;
  background: #f8fafc;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

.variant-title {
  font-weight: 700;
  margin-bottom: 0.85rem;
}

.color-swatches {
  display: flex;
  gap: 0.8rem;
}

.swatch {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 3px solid transparent;
}

.swatch.active {
  box-shadow: 0 0 0 3px rgba(91, 92, 240, 0.18);
  border-color: #fff;
}

.swatch-dark { background: #111827; }
.swatch-light { background: #e5e7eb; }
.swatch-blue { background: #2563eb; }

.action-row {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.qty-box {
  display: flex;
  align-items: center;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 999px;
  overflow: hidden;
  background: #fff;
}

.qty-box button {
  width: 44px;
  height: 52px;
  border: none;
  background: #fff;
  font-weight: 700;
}

.qty-box input {
  width: 54px;
  text-align: center;
  border: none;
  outline: none;
  font-weight: 700;
}

.secondary-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.secondary-link {
  color: var(--dark);
  font-weight: 600;
}

.quote-box {
  padding: 1.25rem;
  border-radius: 1.25rem;
  background: linear-gradient(135deg, #f8fafc, #eef2ff);
  border: 1px solid rgba(15, 23, 42, 0.08);
}

.quote-box-header p {
  color: var(--muted);
}

.quote-form .form-control,
.offcanvas .form-control {
  border-radius: 0.9rem;
  min-height: 48px;
}

.product-tabs .nav-link {
  border: none;
  border-radius: 999px;
  padding: 0.85rem 1.2rem;
  color: var(--dark);
  font-weight: 700;
  background: #f3f4f6;
  margin-right: 0.75rem;
}

.product-tabs .nav-link.active {
  background: var(--primary);
  color: #fff;
}

.section-heading,
.section-title {
  font-weight: 800;
  margin-bottom: 0.75rem;
}

.section-subtitle {
  color: var(--muted);
}

.info-mini-card {
  border-radius: 1rem;
  padding: 1.2rem;
  background: #f8fafc;
  border: 1px solid rgba(15, 23, 42, 0.06);
  height: 100%;
}

.mini-list {
  margin: 0;
  padding-left: 1rem;
  color: var(--muted);
}

.specs-table {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 1rem;
  overflow: hidden;
}

.spec-row {
  display: grid;
  grid-template-columns: 260px 1fr;
}

.spec-row:not(:last-child) {
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

.spec-label,
.spec-value {
  padding: 1rem 1.2rem;
}

.spec-label {
  background: #f8fafc;
  font-weight: 700;
}

.review-summary {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 2rem;
  padding: 1.5rem;
  border-radius: 1.2rem;
  background: #f8fafc;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

.review-score {
  text-align: center;
}

.review-score h2 {
  font-size: 3rem;
  font-weight: 800;
  margin-bottom: 0.3rem;
}

.review-bars {
  display: grid;
  gap: 0.9rem;
}

.bar-row {
  display: grid;
  grid-template-columns: 40px 1fr 50px;
  align-items: center;
  gap: 1rem;
}

.bar {
  height: 10px;
  border-radius: 999px;
  background: #e5e7eb;
  overflow: hidden;
}

.fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #5b5cf0, #16c79a);
}

.w-90 { width: 90%; }
.w-70 { width: 70%; }
.w-25 { width: 25%; }
.w-10 { width: 10%; }
.w-5 { width: 5%; }

.review-list {
  display: grid;
  gap: 1rem;
}

.review-card {
  padding: 1.25rem;
  border-radius: 1rem;
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

.product-card {
  overflow: hidden;
  transition: all 0.25s ease;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 50px rgba(2, 6, 23, 0.08);
}

.product-image {
  height: 200px;
  display: grid;
  place-items: center;
  font-size: 2rem;
  font-weight: 700;
  color: #fff;
}

.product-card .card-body {
  padding: 1.2rem;
}

.product-gradient-1 {
  background: linear-gradient(135deg, #5b5cf0, #7c3aed);
}

.product-gradient-2 {
  background: linear-gradient(135deg, #16c79a, #0ea5e9);
}

.product-gradient-3 {
  background: linear-gradient(135deg, #f97316, #ef4444);
}

.product-gradient-4 {
  background: linear-gradient(135deg, #ec4899, #8b5cf6);
}

.small-muted {
  color: var(--muted);
  font-size: 0.92rem;
}

.btn-primary {
  background: var(--primary);
  border-color: var(--primary);
}

.btn-primary:hover {
  background: #4a4ad8;
  border-color: #4a4ad8;
}

.btn-outline-dark:hover,
.btn-dark:hover {
  background: var(--dark);
}

.offcanvas {
  border-left: 1px solid rgba(15, 23, 42, 0.08);
}

.cart-item {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  padding: 0.9rem 0;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

.cart-thumb {
  width: 58px;
  height: 58px;
  border-radius: 0.9rem;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 1.2rem;
}

.cart-summary {
  padding: 1rem;
  background: #f8fafc;
}

footer {
  background: #0b1220;
  color: rgba(255, 255, 255, 0.82);
}

footer a {
  color: rgba(255, 255, 255, 0.74);
}

footer a:hover {
  color: #fff;
}

.footer-title {
  font-weight: 700;
  margin-bottom: 1rem;
  color: #fff;
}

.footer-line {
  border-color: rgba(255, 255, 255, 0.1);
}

@media (max-width: 991.98px) {
  .category-sticky-bar {
    top: 72px;
  }

  .main-product-image {
    min-height: 420px;
  }

  .meta-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .action-row {
    flex-wrap: wrap;
  }

  .review-summary {
    grid-template-columns: 1fr;
  }

  .spec-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 575.98px) {
  .product-title {
    font-size: 1.7rem;
  }

  .thumb-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .meta-grid {
    grid-template-columns: 1fr;
  }

  .price {
    font-size: 1.7rem;
  }
}