/* ==========================================================================
   Sbiz — giao diện sàn TMĐT 2026 (sbiz.com.vn#2)
   Lớp giao diện mới đặt SAU style.css của mẫu cũ: ghi đè màu, chữ, khung trang.
   Không đổi logic: giữ nguyên id/class mà JS cũ dùng (btn_fav, add_cart, offcanvas…).
   ========================================================================== */

:root {
  --sb-primary: #0a63d8;
  --sb-primary-600: #0752b5;
  --sb-primary-50: #e9f2ff;
  --sb-brand: #00aeef;
  --sb-accent: #ff5b1f;
  --sb-accent-600: #e84a10;
  --sb-accent-50: #fff1ea;
  --sb-ink: #0f172a;
  --sb-ink-2: #334155;
  --sb-muted: #64748b;
  --sb-line: #e5e9f0;
  --sb-bg: #f3f6fa;
  --sb-card: #ffffff;
  --sb-success: #12a150;
  --sb-star: #f5a524;
  --sb-navy: #0b1f3a;
  --sb-radius: 14px;
  --sb-radius-sm: 10px;
  --sb-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 4px 16px rgba(15, 23, 42, .06);
  --sb-shadow-hover: 0 6px 24px rgba(15, 23, 42, .12);
  --sb-container: 1240px;
  --sb-font: "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

/* ---------- Nền chung ---------- */
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--sb-font) !important;
  background: var(--sb-bg) !important;
  color: var(--sb-ink);
  font-size: 15px;
  line-height: 1.55;
  padding-top: 0 !important;
}
h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 {
  font-family: var(--sb-font) !important;
  color: var(--sb-ink);
  line-height: 1.35;
  letter-spacing: -.01em;
}
a { color: var(--sb-primary); }
a:hover, a:focus { color: var(--sb-primary-600); }
p { color: var(--sb-ink-2); }
.btn, .form-control, input, select, textarea, button { font-family: var(--sb-font) !important; }
#preloader { display: none !important; }

/* Khung trang: bỏ khoảng trống chừa cho header/footer cố định của mẫu cũ */
.page-content-wrapper {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  padding-top: 0 !important;
  padding-bottom: 24px;
}
@media (max-width: 991.98px) {
  .page-content-wrapper { padding-bottom: 84px; }
}
@media (min-width: 992px) {
  .container { max-width: var(--sb-container) !important; }
  .page-content-wrapper .container,
  .sb-header .container,
  .sb-footer .container { padding-left: 16px; padding-right: 16px; }
}

/* Nút */
.btn { border-radius: 10px; font-weight: 600; }
.btn-primary, .btn-success {
  background: var(--sb-primary) !important;
  border-color: var(--sb-primary) !important;
  color: #fff !important;
}
.btn-primary:hover, .btn-success:hover { background: var(--sb-primary-600) !important; border-color: var(--sb-primary-600) !important; }
.btn-warning, .btn-danger {
  background: var(--sb-accent) !important;
  border-color: var(--sb-accent) !important;
  color: #fff !important;
}
.btn-warning:hover, .btn-danger:hover { background: var(--sb-accent-600) !important; border-color: var(--sb-accent-600) !important; }
.sb-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 20px; border-radius: 12px; border: 0;
  font-weight: 600; font-size: 15px; line-height: 1.3; text-decoration: none; cursor: pointer;
  transition: background .15s, transform .15s;
}
.sb-btn--accent { background: var(--sb-accent); color: #fff; }
.sb-btn--accent:hover { background: var(--sb-accent-600); color: #fff; }
.sb-btn--light { background: #fff; color: var(--sb-ink); }
.sb-btn--light:hover { background: var(--sb-primary-50); color: var(--sb-primary); }

/* ==========================================================================
   HEADER
   ========================================================================== */
.sb-header {
  position: sticky; top: 0; z-index: 1030;
  background: #fff;
  box-shadow: 0 1px 0 var(--sb-line);
}
.sb-topbar {
  background: var(--sb-navy);
  color: #cbd5e1;
  font-size: 13px;
  line-height: 1.4;
}
.sb-topbar .container { display: flex; justify-content: space-between; align-items: center; height: 34px; }
.sb-topbar a { color: #e2e8f0; text-decoration: none; }
.sb-topbar a:hover { color: #fff; }
.sb-topbar__group { display: flex; gap: 18px; align-items: center; }
.sb-topbar__group i { margin-right: 6px; opacity: .8; }

.sb-mainbar .container {
  display: flex; align-items: center; gap: 24px;
  min-height: 76px;
}
.sb-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; flex-shrink: 0; }
.sb-logo img { width: 44px; height: 44px; object-fit: contain; }
.sb-logo__text { display: flex; flex-direction: column; line-height: 1.2; }
.sb-logo__name { font-size: 26px; font-weight: 800; color: var(--sb-primary); letter-spacing: -.02em; line-height: 1.2; }
.sb-logo__tag { font-size: 11.5px; color: var(--sb-muted); font-weight: 500; line-height: 1.3; }
.sb-logo:hover .sb-logo__name { color: var(--sb-primary-600); }

.sb-search { flex: 1; min-width: 0; }
.sb-search form {
  display: flex; align-items: stretch;
  border: 2px solid var(--sb-primary);
  border-radius: 12px; overflow: hidden; background: #fff;
  height: 46px;
}
.sb-search input {
  flex: 1; min-width: 0; border: 0 !important; outline: 0; box-shadow: none !important;
  padding: 0 16px; font-size: 15px; color: var(--sb-ink); background: transparent;
  height: 100%; line-height: 1.4;
}
.sb-search input::placeholder { color: #94a3b8; }
.sb-search button {
  border: 0; background: var(--sb-primary); color: #fff;
  padding: 0 22px; font-weight: 600; font-size: 15px; display: flex; align-items: center; gap: 8px;
  line-height: 1.3;
}
.sb-search button:hover { background: var(--sb-primary-600); }
.sb-search__hot { display: flex; gap: 14px; margin-top: 6px; font-size: 12.5px; line-height: 1.4; overflow: hidden; white-space: nowrap; }
.sb-search__hot a { color: var(--sb-muted); text-decoration: none; }
.sb-search__hot a:hover { color: var(--sb-primary); }

.sb-actions { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.sb-action {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center;
  min-width: 64px; height: 52px; padding: 4px 6px; border-radius: 12px;
  color: var(--sb-ink-2) !important; text-decoration: none; font-size: 12px; font-weight: 500; line-height: 1.3;
  background: transparent; border: 0;
}
.sb-action:hover { background: var(--sb-primary-50); color: var(--sb-primary) !important; }
.sb-action i { font-size: 22px; line-height: 1.1; margin-bottom: 3px; }
.sb-action sup, .sb-action .count_cart, .sb-action .count_notify {
  position: absolute; top: 2px; left: 50%; margin-left: 4px;
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: var(--sb-accent); color: #fff; font-size: 11px; font-weight: 700; line-height: 18px; text-align: center;
  border: 2px solid #fff; box-sizing: content-box;
}
.sb-burger { display: none; }

.sb-catnav { border-top: 1px solid var(--sb-line); }
.sb-catnav .container { display: flex; align-items: center; gap: 4px; height: 46px; overflow-x: auto; scrollbar-width: none; -webkit-mask-image: linear-gradient(90deg, #000 92%, transparent); mask-image: linear-gradient(90deg, #000 92%, transparent); }
.sb-catnav .container::-webkit-scrollbar { display: none; }
.sb-catnav a {
  white-space: nowrap; padding: 0 12px; height: 34px; display: flex; align-items: center; border-radius: 8px;
  color: var(--sb-ink-2); text-decoration: none; font-size: 14px; font-weight: 500; line-height: 1.4;
}
.sb-catnav a:hover { background: var(--sb-primary-50); color: var(--sb-primary); }
.sb-catnav a.sb-catnav__all { background: var(--sb-primary); color: #fff; gap: 8px; font-weight: 600; margin-right: 8px; }
.sb-catnav a.sb-catnav__all:hover { background: var(--sb-primary-600); color: #fff; }
.sb-catnav a.sb-catnav__hot { color: var(--sb-accent); font-weight: 600; }

/* Dropdown giỏ hàng + thông báo (giữ module cũ, đổi giao diện) */
.sb-header .dropdown-menu {
  border: 0; border-radius: var(--sb-radius); box-shadow: var(--sb-shadow-hover);
  padding: 14px; min-width: 340px; max-width: 92vw; margin-top: 6px !important;
}
.sb-header .card_dropdown_title, .sb-header .notification_dropdown .title {
  font-weight: 700; font-size: 15px; color: var(--sb-ink); display: flex; justify-content: space-between; line-height: 1.4;
}

/* Back + tiêu đề trang trên điện thoại */
.sb-pagebar { display: none; }

@media (max-width: 991.98px) {
  .sb-topbar, .sb-catnav, .sb-search__hot, .sb-action__label, .sb-action--wish, .sb-action--account { display: none !important; }
  .sb-mainbar .container { flex-wrap: wrap; gap: 10px 8px; min-height: 0; padding-top: 10px; padding-bottom: 10px; }
  .sb-logo img { width: 34px; height: 34px; }
  .sb-logo__name { font-size: 22px; }
  .sb-logo__tag { display: none; }
  .sb-actions { margin-left: auto; gap: 2px; }
  .sb-action { min-width: 42px; height: 42px; }
  .sb-action i { font-size: 22px; margin: 0; }
  .sb-action sup, .sb-action .count_cart, .sb-action .count_notify { top: 0; }
  .sb-burger { display: flex; }
  .sb-search { order: 3; flex: 0 0 100%; }
  .sb-search form { height: 42px; border-width: 1.5px; }
  .sb-search button { padding: 0 14px; }
  .sb-search button span { display: none; }
  .sb-header--sub .sb-search { display: none; }
  .sb-header--sub .sb-logo { display: none; }
  .sb-header--sub .sb-pagebar { display: flex; align-items: center; gap: 8px; min-width: 0; flex: 1; }
  .sb-pagebar a { width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; border-radius: 10px; color: var(--sb-ink); }
  .sb-pagebar a:hover { background: var(--sb-primary-50); }
  .sb-pagebar h1 { font-size: 16px; font-weight: 600; margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.5; padding: 2px 0; }
  .sb-header .dropdown-menu { min-width: 300px; }
}

/* Offcanvas menu (điện thoại) */
.suha-offcanvas-wrap { background: #fff !important; }
.suha-offcanvas-wrap .btn-close { filter: none !important; opacity: .7; }
.suha-offcanvas-wrap .sidenav-profile { background: linear-gradient(135deg, var(--sb-primary), var(--sb-brand)) !important; }
.suha-offcanvas-wrap .sidenav-nav li a { color: var(--sb-ink-2) !important; font-weight: 500; line-height: 1.4; }
.suha-offcanvas-wrap .sidenav-nav li a i { color: var(--sb-primary) !important; }
.suha-offcanvas-wrap .sidenav-nav li a:hover { color: var(--sb-primary) !important; }

/* Ẩn header/footer mẫu cũ nếu trang nào còn gọi */
.header-area { display: none !important; }

/* ==========================================================================
   KHỐI NỘI DUNG CHUNG
   ========================================================================== */
.sb-section { margin-top: 20px; }
.sb-box {
  background: var(--sb-card); border-radius: var(--sb-radius); box-shadow: var(--sb-shadow);
  padding: 20px;
}
.sb-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.sb-head h2 { font-size: 20px; font-weight: 700; margin: 0; display: flex; align-items: center; gap: 10px; line-height: 1.4; padding-top: 2px; }
.sb-head h2 .sb-head__icon { width: 30px; height: 30px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; font-size: 15px; color: #fff; background: var(--sb-primary); }
.sb-head h2 .sb-head__icon--accent { background: var(--sb-accent); }
.sb-head h2 .sb-head__icon--green { background: var(--sb-success); }
.sb-head h2 .sb-head__icon--violet { background: #7c3aed; }
.sb-more { font-size: 14px; font-weight: 600; color: var(--sb-primary); text-decoration: none; white-space: nowrap; line-height: 1.4; }
.sb-more:hover { text-decoration: underline; }
@media (max-width: 767.98px) {
  .sb-section { margin-top: 12px; }
  .sb-box { padding: 14px 12px; border-radius: 12px; }
  .sb-head { margin-bottom: 12px; }
  .sb-head h2 { font-size: 17px; }
  .sb-head h2 .sb-head__icon { width: 26px; height: 26px; font-size: 13px; }
}

/* ---------- Lưới sản phẩm ---------- */
.sb-grid { display: grid; gap: 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 576px) { .sb-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 768px) { .sb-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .sb-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
.sb-grid--5 { }
@media (min-width: 1200px) { .sb-grid--5 { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
@media (max-width: 767.98px) {
  .sb-grid { gap: 10px; }
  .sb-grid--limit-m > *:nth-child(n+9) { display: none; }
}
/* Thẻ cũ bọc trong col-*: trong lưới mới thì bỏ chiều rộng cột */
.sb-grid > [class*="col-"] { width: auto !important; max-width: none !important; flex: none !important; padding: 0 !important; margin: 0 !important; }

/* ---------- Thẻ sản phẩm ---------- */
.product-card, .sb-card {
  position: relative; height: 100%;
  background: var(--sb-card) !important; border: 1px solid var(--sb-line) !important; border-radius: var(--sb-radius) !important;
  box-shadow: none !important; overflow: hidden;
  transition: box-shadow .2s, transform .2s, border-color .2s;
}
.product-card:hover, .sb-card:hover { box-shadow: var(--sb-shadow-hover) !important; transform: translateY(-2px); border-color: transparent !important; }
.product-card .card-body { padding: 0 !important; display: flex; flex-direction: column; height: 100%; }
.product-card .product-thumbnail {
  position: relative; display: block; aspect-ratio: 1 / 1; background: #fff; overflow: hidden;
  margin: 0 !important; height: auto !important;
}
.product-card .product-thumbnail img {
  width: 100% !important; height: 100% !important; max-height: none !important; object-fit: contain; display: block;
  transition: transform .35s;
}
.product-card:hover .product-thumbnail img { transform: scale(1.04); }
.product-card .badge_top, .product-card .badge_bottom, .product-card .badge_left_bottom {
  position: absolute; z-index: 2; font-size: 11.5px; font-weight: 700; line-height: 1.5;
  padding: 2px 8px; border-radius: 6px; color: #fff; letter-spacing: .01em;
}
.product-card .badge_top { top: 8px; left: 8px; background: var(--sb-accent) !important; }
.product-card .badge_bottom { bottom: 8px; right: 8px; left: auto; top: auto; background: var(--sb-primary) !important; }
.product-card .badge_left_bottom { bottom: 8px; left: 8px; top: auto; background: var(--sb-success) !important; }
.product-card .wishlist-btn {
  position: absolute; z-index: 3; top: 8px; right: 8px; left: auto !important;
  width: 32px; height: 32px; border-radius: 50%; background: rgba(255,255,255,.92);
  display: flex; align-items: center; justify-content: center; box-shadow: 0 1px 4px rgba(15,23,42,.12);
  color: #ef4444 !important; font-size: 15px;
}
.product-card .product-title-wrapper { padding: 10px 12px 0; margin: 0 !important; }
.product-card .product-title {
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  font-size: 14px !important; font-weight: 500 !important; line-height: 1.45 !important; color: var(--sb-ink) !important;
  min-height: calc(1.45em * 2); padding-top: 1px; text-decoration: none;
}
.product-card .product-title:hover { color: var(--sb-primary) !important; }
.product-card .product-rating { padding: 0 12px; margin: 6px 0 0 !important; font-size: 11px; line-height: 1.4; display: flex; align-items: center; gap: 1px; }
.product-card .product-rating i { color: inherit; }
.product-card .product-sold-qty { padding: 0 12px; margin: 2px 0 0 !important; font-size: 12px !important; line-height: 1.4; color: var(--sb-muted) !important; }
.product-card .price_product {
  margin-top: auto; padding: 8px 12px 12px; display: flex; align-items: flex-end; justify-content: space-between; gap: 6px;
}
.product-card .sale-price {
  margin: 0 !important; color: var(--sb-accent) !important; font-weight: 700 !important; font-size: 16px !important; line-height: 1.35 !important;
  display: flex; flex-direction: column;
}
.product-card .sale-price span {
  color: #94a3b8 !important; font-size: 12px !important; font-weight: 400 !important; text-decoration: line-through; margin: 0 !important; line-height: 1.4;
}
.product-card .btn-add-cart {
  position: static !important; flex-shrink: 0;
  width: 34px; height: 34px; padding: 0 !important; border-radius: 10px !important;
  background: var(--sb-primary-50) !important; border: 0 !important; color: var(--sb-primary) !important;
  display: flex; align-items: center; justify-content: center; font-size: 15px;
}
.product-card .btn-add-cart:hover { background: var(--sb-primary) !important; color: #fff !important; }
@media (max-width: 575.98px) {
  .product-card .product-title-wrapper { padding: 8px 10px 0; }
  .product-card .product-title { font-size: 13.5px !important; }
  .product-card .product-rating, .product-card .product-sold-qty { padding: 0 10px; }
  .product-card .price_product { padding: 6px 10px 10px; }
  .product-card .sale-price { font-size: 15px !important; }
  .product-card .btn-add-cart { width: 30px; height: 30px; font-size: 13px; }
}

/* ==========================================================================
   TRANG CHỦ
   ========================================================================== */
.sb-hero { display: grid; gap: 16px; grid-template-columns: 250px minmax(0, 1fr) 280px; margin-top: 16px; }
.sb-hero__cats { background: #fff; border-radius: var(--sb-radius); box-shadow: var(--sb-shadow); padding: 8px; }
.sb-hero__cats h2 { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--sb-muted); margin: 6px 10px 4px; line-height: 1.6; }
.sb-hero__cats ul { list-style: none; margin: 0; padding: 0; }
.sb-hero__cats a {
  display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 10px;
  color: var(--sb-ink-2); text-decoration: none; font-size: 14px; font-weight: 500; line-height: 1.4;
}
.sb-hero__cats a:hover { background: var(--sb-primary-50); color: var(--sb-primary); }
.sb-hero__cats img { width: 26px; height: 26px; border-radius: 7px; object-fit: cover; background: var(--sb-bg); flex-shrink: 0; }
.sb-hero__cats .sb-hero__all { color: var(--sb-primary); font-weight: 600; }

.sb-slider { position: relative; border-radius: var(--sb-radius); overflow: hidden; background: linear-gradient(135deg, #0a63d8 0%, #00aeef 100%); min-height: 100%; }
.sb-slider__track { display: flex; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; scroll-behavior: smooth; }
.sb-slider__track::-webkit-scrollbar { display: none; }
.sb-slide { flex: 0 0 100%; scroll-snap-align: start; position: relative; display: block; }
.sb-slide img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sb-slide--intro { display: flex; flex-direction: column; justify-content: center; padding: 40px 48px; color: #fff; }
.sb-slide--intro .sb-eyebrow { display: inline-block; align-self: flex-start; background: rgba(255,255,255,.18); padding: 4px 12px; border-radius: 99px; font-size: 13px; font-weight: 600; margin-bottom: 14px; line-height: 1.5; }
.sb-slide--intro h1, .sb-slide--intro .sb-slide__title { color: #fff; font-size: 38px; font-weight: 800; line-height: 1.3; margin: 0 0 12px; max-width: 560px; padding-top: 4px; }
.sb-slide--intro p { color: rgba(255,255,255,.9); font-size: 16px; margin: 0 0 22px; max-width: 520px; line-height: 1.6; }
.sb-slide--intro .sb-slide__cta { display: flex; gap: 10px; flex-wrap: wrap; }
.sb-slide--intro { background: linear-gradient(135deg, #0a63d8 0%, #00aeef 100%); }
.sb-slide--intro::after { content: ""; position: absolute; right: -60px; top: -60px; width: 320px; height: 320px; border-radius: 50%; background: rgba(255,255,255,.10); pointer-events: none; }
.sb-slide--intro::before { content: ""; position: absolute; right: 80px; bottom: -90px; width: 220px; height: 220px; border-radius: 50%; background: rgba(255,255,255,.08); pointer-events: none; }
.sb-slide--point { background: linear-gradient(135deg, #7c3aed 0%, #db2777 100%); }
.sb-slide--store { background: linear-gradient(135deg, #0b1f3a 0%, #0e7490 100%); }
.sb-slider__dots { position: absolute; bottom: 14px; left: 0; right: 0; display: flex; justify-content: center; gap: 6px; }
.sb-slider__dots button { width: 8px; height: 8px; border-radius: 4px; border: 0; padding: 0; background: rgba(255,255,255,.55); transition: width .2s; }
.sb-slider__dots button.is-active { width: 24px; background: #fff; }
.sb-slider__nav { position: absolute; top: 50%; transform: translateY(-50%); width: 38px; height: 38px; border-radius: 50%; border: 0; background: rgba(255,255,255,.9); color: var(--sb-ink); display: flex; align-items: center; justify-content: center; box-shadow: var(--sb-shadow); opacity: 0; transition: opacity .2s; }
.sb-slider:hover .sb-slider__nav { opacity: 1; }
.sb-slider__nav--prev { left: 12px; }
.sb-slider__nav--next { right: 12px; }

.sb-promos { display: grid; gap: 16px; grid-template-rows: 1fr 1fr; }
.sb-promo {
  border-radius: var(--sb-radius); padding: 22px; color: #fff; text-decoration: none; display: flex; flex-direction: column; justify-content: space-between;
  position: relative; overflow: hidden; min-height: 150px;
}
.sb-promo::after { content: ""; position: absolute; right: -30px; bottom: -30px; width: 130px; height: 130px; border-radius: 50%; background: rgba(255,255,255,.14); }
.sb-promo h3 { color: #fff; font-size: 19px; font-weight: 700; margin: 0 0 6px; line-height: 1.35; padding-top: 2px; }
.sb-promo p { color: rgba(255,255,255,.92); font-size: 13.5px; margin: 0; line-height: 1.5; }
.sb-promo span { font-weight: 600; font-size: 14px; line-height: 1.4; margin-top: 12px; position: relative; z-index: 1; }
.sb-promo--accent { background: linear-gradient(135deg, #ff7a2f, #ff3d5a); }
.sb-promo--green { background: linear-gradient(135deg, #10b981, #0e9f6e); }
.sb-promo:hover { color: #fff; filter: brightness(1.05); }

.sb-trust { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; background: #fff; border-radius: var(--sb-radius); box-shadow: var(--sb-shadow); margin-top: 16px; }
.sb-trust__item { display: flex; align-items: center; gap: 12px; padding: 16px 18px; }
.sb-trust__item + .sb-trust__item { border-left: 1px solid var(--sb-line); }
.sb-trust__item i { width: 42px; height: 42px; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: var(--sb-primary-50); color: var(--sb-primary); font-size: 18px; flex-shrink: 0; }
.sb-trust__item b { display: block; font-size: 14.5px; color: var(--sb-ink); line-height: 1.4; }
.sb-trust__item small { display: block; font-size: 12.5px; color: var(--sb-muted); line-height: 1.4; }

@media (max-width: 1199.98px) {
  .sb-hero { grid-template-columns: 230px minmax(0, 1fr); }
  .sb-promos { display: none; }
}
@media (max-width: 991.98px) {
  .sb-hero { grid-template-columns: minmax(0, 1fr); margin-top: 10px; gap: 10px; }
  .sb-hero__cats { display: none; }
  .sb-slider { aspect-ratio: 2 / 1; min-height: 0; }
  .sb-slide--intro { padding: 20px; }
  .sb-slide--intro .sb-eyebrow { font-size: 11.5px; margin-bottom: 8px; }
  .sb-slide--intro h1, .sb-slide--intro .sb-slide__title { font-size: 22px; margin-bottom: 6px; }
  .sb-slide--intro p { font-size: 13px; margin-bottom: 12px; }
  .sb-slide--intro .sb-btn { height: 36px; padding: 0 14px; font-size: 13.5px; }
  .sb-slider__nav { display: none; }
  .sb-trust { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 10px; }
  .sb-trust__item { padding: 12px; gap: 10px; }
  .sb-trust__item:nth-child(3) { border-left: 0; }
  .sb-trust__item:nth-child(n+3) { border-top: 1px solid var(--sb-line); }
  .sb-trust__item i { width: 34px; height: 34px; font-size: 15px; border-radius: 10px; }
  .sb-trust__item b { font-size: 13px; }
  .sb-trust__item small { font-size: 11.5px; }
}
@media (max-width: 575.98px) {
  .sb-slide--intro h1, .sb-slide--intro .sb-slide__title { font-size: 19px; }
  .sb-slide--intro p { display: none; }
}

/* Danh mục dạng biểu tượng */
.sb-cats { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 8px; }
.sb-cat { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 10px 4px; border-radius: 12px; text-decoration: none; text-align: center; }
.sb-cat:hover { background: var(--sb-primary-50); }
.sb-cat__img { width: 64px; height: 64px; border-radius: 18px; background: var(--sb-bg); overflow: hidden; display: flex; align-items: center; justify-content: center; }
.sb-cat__img img { width: 100%; height: 100%; object-fit: cover; }
.sb-cat span { font-size: 13px; color: var(--sb-ink-2); font-weight: 500; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; padding-top: 1px; }
@media (max-width: 1199.98px) { .sb-cats { grid-template-columns: repeat(8, minmax(0, 1fr)); } }
@media (max-width: 991.98px) {
  .sb-cats { display: grid; grid-auto-flow: column; grid-template-rows: repeat(2, auto); grid-template-columns: none; grid-auto-columns: 76px; overflow-x: auto; scrollbar-width: none; gap: 4px; padding-bottom: 2px; }
  .sb-cats::-webkit-scrollbar { display: none; }
  .sb-cat { padding: 6px 2px; gap: 6px; }
  .sb-cat__img { width: 52px; height: 52px; border-radius: 15px; }
  .sb-cat span { font-size: 12px; }
}

/* Flash sale */
.sb-flash { background: linear-gradient(135deg, #fff4ee 0%, #ffffff 60%); }
.sb-flash .sb-head h2 { color: var(--sb-accent); }
.sb-timer { display: inline-flex; gap: 4px; align-items: center; margin-left: 6px; list-style: none; padding: 0 !important; margin-bottom: 0; }
.sb-timer li { background: var(--sb-ink); color: #fff; border-radius: 6px; font-size: 13px; font-weight: 700; padding: 2px 6px; line-height: 1.5; min-width: 30px; text-align: center; }
.sb-timer li span { color: #fff; }
.sb-timer li.sb-timer__more { display: none; }
.sb-hscroll { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 5 * 14px) / 6); gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: thin; padding-bottom: 6px; }
.sb-hscroll > * { scroll-snap-align: start; }
@media (max-width: 1199.98px) { .sb-hscroll { grid-auto-columns: calc((100% - 3 * 14px) / 4); } }
@media (max-width: 767.98px) { .sb-hscroll { grid-auto-columns: 42%; gap: 10px; scrollbar-width: none; } .sb-hscroll::-webkit-scrollbar { display: none; } }
.sb-flashcard { display: flex; flex-direction: column; text-decoration: none; background: #fff; border: 1px solid var(--sb-line); border-radius: var(--sb-radius); overflow: hidden; }
.sb-flashcard:hover { box-shadow: var(--sb-shadow-hover); }
.sb-flashcard__img { aspect-ratio: 1/1; position: relative; background: #fff; }
.sb-flashcard__img img { width: 100%; height: 100%; object-fit: contain; }
.sb-flashcard__body { padding: 10px 12px 12px; }
.sb-flashcard__name { font-size: 13.5px; color: var(--sb-ink); line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: calc(1.45em * 2); padding-top: 1px; }
.sb-flashcard__price { color: var(--sb-accent); font-weight: 700; font-size: 16px; line-height: 1.4; margin-top: 4px; }
.sb-flashcard__old { color: #94a3b8; font-size: 12px; text-decoration: line-through; line-height: 1.4; }
.sb-bar { position: relative; height: 18px; border-radius: 9px; background: #ffd9c7; overflow: hidden; margin-top: 8px; }
.sb-bar i { position: absolute; inset: 0 auto 0 0; background: linear-gradient(90deg, #ff7a2f, #ff3d5a); border-radius: 9px; }
.sb-bar b { position: relative; display: block; text-align: center; font-size: 11px; color: #fff; line-height: 18px; font-weight: 700; text-shadow: 0 0 2px rgba(0,0,0,.25); }

/* Gian hàng / rao vặt dùng thẻ cũ trong lưới mới */
.sb-grid .card { height: 100%; }

/* Tin tức */
.sb-news { display: grid; gap: 16px; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.sb-news__item { text-decoration: none; display: flex; flex-direction: column; gap: 10px; }
.sb-news__img { aspect-ratio: 16 / 10; border-radius: 12px; overflow: hidden; background: var(--sb-bg); }
.sb-news__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.sb-news__item:hover .sb-news__img img { transform: scale(1.04); }
.sb-news__cat { font-size: 12px; font-weight: 600; color: var(--sb-primary); text-transform: uppercase; letter-spacing: .03em; line-height: 1.5; }
.sb-news__title { font-size: 15px; font-weight: 600; color: var(--sb-ink); line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; padding-top: 1px; }
.sb-news__item:hover .sb-news__title { color: var(--sb-primary); }
@media (max-width: 991.98px) { .sb-news { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; } .sb-news__title { font-size: 13.5px; } }

/* Đối tác */
.sb-partners { display: grid; grid-auto-flow: column; grid-auto-columns: 160px; gap: 12px; overflow-x: auto; scrollbar-width: none; }
.sb-partners::-webkit-scrollbar { display: none; }
.sb-partner { display: flex; flex-direction: column; align-items: center; gap: 8px; text-decoration: none; padding: 12px; border: 1px solid var(--sb-line); border-radius: 12px; background: #fff; }
.sb-partner img { width: 100%; aspect-ratio: 3/2; object-fit: contain; }
.sb-partner span { font-size: 13px; color: var(--sb-ink-2); line-height: 1.4; text-align: center; }

/* Băng mời mở gian hàng */
.sb-cta {
  display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
  border-radius: var(--sb-radius); padding: 28px 32px; color: #fff;
  background: radial-gradient(circle at 85% 20%, rgba(255,255,255,.18) 0, transparent 40%), linear-gradient(120deg, var(--sb-navy) 0%, #0a63d8 100%);
}
.sb-cta h2 { color: #fff; font-size: 24px; font-weight: 800; margin: 0 0 6px; line-height: 1.35; padding-top: 2px; }
.sb-cta p { color: rgba(255,255,255,.85); margin: 0; font-size: 15px; }
@media (max-width: 767.98px) { .sb-cta { padding: 20px; } .sb-cta h2 { font-size: 19px; } .sb-cta p { font-size: 13.5px; } }

/* ==========================================================================
   DANH MỤC / TÌM KIẾM
   ========================================================================== */
.sb-crumb { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 13px; color: var(--sb-muted); margin: 16px 0 10px; list-style: none; padding: 0; line-height: 1.5; }
.sb-crumb a { color: var(--sb-muted); text-decoration: none; }
.sb-crumb a:hover { color: var(--sb-primary); }
.sb-crumb li + li::before { content: "›"; margin-right: 6px; color: #94a3b8; }
.sb-listing { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 20px; align-items: start; }
.sb-listing__title { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.sb-listing__title h1 { font-size: 24px; font-weight: 800; margin: 0; line-height: 1.35; padding-top: 2px; }
.sb-listing__title span { color: var(--sb-muted); font-size: 14px; }
.sb-side { position: sticky; top: 170px; display: flex; flex-direction: column; gap: 16px; }
.sb-side .sb-box { padding: 16px; }
.sb-side h3 { font-size: 15px; font-weight: 700; margin: 0 0 10px; line-height: 1.4; }
.sb-side__cats { list-style: none; margin: 0; padding: 0; max-height: 360px; overflow: auto; }
.sb-side__cats a { display: block; padding: 6px 8px; border-radius: 8px; color: var(--sb-ink-2); text-decoration: none; font-size: 14px; line-height: 1.45; }
.sb-side__cats a:hover, .sb-side__cats a.is-active { background: var(--sb-primary-50); color: var(--sb-primary); font-weight: 600; }

/* Bộ lọc offcanvas cũ: trên máy tính hiện thành cột trái cố định */
@media (min-width: 992px) {
  .sb-side .suha-filter-offcanvas-wrap {
    position: static !important; visibility: visible !important; transform: none !important;
    width: auto !important; height: auto !important; z-index: auto !important; border: 0 !important; background: transparent !important;
  }
  .sb-side .suha-filter-offcanvas-wrap .btn-close { display: none; }
  .sb-side .suha-filter-offcanvas-wrap .offcanvas-body { padding: 0 !important; overflow: visible; }
  .sb-side .suha-filter-offcanvas-wrap .container { padding: 0 !important; }
  .sb-side .suha-filter-offcanvas-wrap .row { margin: 0; }
  .sb-side .suha-filter-offcanvas-wrap .row > * { padding: 0; }
  .sb-listing .filter_bar .filter-option { display: none !important; }
}
.suha-filter-offcanvas-wrap .widget-title { font-size: 15px !important; font-weight: 700 !important; color: var(--sb-ink) !important; line-height: 1.4; }
.suha-filter-offcanvas-wrap .form-check-label { font-size: 14px; color: var(--sb-ink-2); line-height: 1.5; }
.suha-filter-offcanvas-wrap .form-check-input:checked { background-color: var(--sb-primary); border-color: var(--sb-primary); }
.suha-filter-offcanvas-wrap .toogle_btn { color: var(--sb-primary); font-size: 13.5px; font-weight: 600; margin-top: 4px; cursor: pointer; }

/* Thanh sắp xếp */
.sb-listing .filter_bar, .top-products-area .filter_bar {
  background: #fff !important; border-radius: 12px !important; box-shadow: var(--sb-shadow);
  padding: 10px 12px !important; margin: 0 0 14px !important;
}
.filter_bar .option {
  border-radius: 8px !important; background: var(--sb-bg) !important; color: var(--sb-ink-2) !important;
  font-weight: 500; font-size: 14px !important; height: 36px !important; line-height: 1.4 !important;
}
.filter_bar .option.active { background: var(--sb-primary) !important; color: #fff !important; }
.filter_bar .filter-option { width: 40px; height: 36px; justify-content: center; border-radius: 8px; background: var(--sb-primary-50); color: var(--sb-primary); }
.sb-chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin-bottom: 14px; padding-bottom: 2px; }
.sb-chips::-webkit-scrollbar { display: none; }
.sb-chips a { flex-shrink: 0; padding: 7px 14px; border-radius: 99px; background: #fff; border: 1px solid var(--sb-line); color: var(--sb-ink-2); font-size: 13.5px; text-decoration: none; line-height: 1.4; font-weight: 500; }
.sb-chips a:hover { border-color: var(--sb-primary); color: var(--sb-primary); }
.sb-empty { background: #fff; border-radius: var(--sb-radius); padding: 48px 20px; text-align: center; color: var(--sb-muted); }
.sb-empty i { font-size: 40px; color: #cbd5e1; display: block; margin-bottom: 12px; }
#endProduct .btn { background: #fff !important; color: var(--sb-muted) !important; border: 1px solid var(--sb-line) !important; }
@media (max-width: 991.98px) {
  .sb-listing { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .sb-listing .sb-side { position: static; display: contents; }
  .sb-listing .sb-side__catbox { display: none; }
  .sb-listing .sb-side__filter { display: contents; }
  .sb-crumb { margin: 10px 0 6px; }
  .sb-listing__title h1 { font-size: 19px; }
}

/* ==========================================================================
   CHI TIẾT SẢN PHẨM (ghi đè giao diện cũ, không đổi cấu trúc Vue)
   ========================================================================== */
.sb-product-page .page-content-wrapper { padding-top: 16px !important; }
.sb-product-page .product-slide-wrapper, .sb-product-page .product-description,
.sb-product-page .p-specification, .sb-product-page .selection-panel,
.sb-product-page .rating-and-review-wrapper, .sb-product-page .related-product-wrapper,
.sb-product-page .shop, .sb-product-page .product-title-meta-data, .sb-product-page .product-detail {
  border-radius: var(--sb-radius) !important;
}
.sb-product-page .sale-price, .sb-product-page .show_price { color: var(--sb-accent) !important; font-weight: 700 !important; }
.sb-product-page .real-price { color: #94a3b8 !important; }
.sb-product-page .sale-percent { background: var(--sb-accent) !important; color: #fff !important; border-radius: 6px; }
.sb-product-page .bg-white { border-radius: var(--sb-radius); }
.sb-product-page .product-variation__tick, .sb-product-page .active .product-variation__tick { background: var(--sb-primary) !important; }

/* ==========================================================================
   FOOTER
   ========================================================================== */
.sb-footer { background: var(--sb-navy); color: #94a3b8; margin-top: 32px; font-size: 14px; }
.sb-footer a { color: #cbd5e1; text-decoration: none; }
.sb-footer a:hover { color: #fff; }
.sb-footer__grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 32px; padding: 40px 0 28px; }
.sb-footer h3 { color: #fff; font-size: 15px; font-weight: 700; margin: 0 0 14px; line-height: 1.4; }
.sb-footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 9px; }
.sb-footer li { line-height: 1.5; }
.sb-footer__brand p { color: #94a3b8; line-height: 1.65; margin: 0 0 6px; font-size: 13.5px; }
.sb-footer__brand .sb-logo__name { color: #fff; }
.sb-footer__brand .sb-logo { margin-bottom: 14px; }
.sb-footer__brand b { color: #e2e8f0; font-weight: 600; }
.sb-footer__bottom { border-top: 1px solid rgba(255,255,255,.1); padding: 16px 0; font-size: 13px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; line-height: 1.5; }
@media (max-width: 991.98px) {
  .sb-footer { margin-top: 20px; padding-bottom: 70px; }
  .sb-footer__grid { grid-template-columns: 1fr 1fr; gap: 24px 16px; padding: 28px 0 18px; }
  .sb-footer__brand { grid-column: 1 / -1; }
}

/* Thanh điều hướng dưới (điện thoại) */
.sb-tabbar { display: none; }
@media (max-width: 991.98px) {
  .sb-tabbar {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 1030;
    background: rgba(255,255,255,.97); backdrop-filter: saturate(180%) blur(12px); -webkit-backdrop-filter: saturate(180%) blur(12px);
    border-top: 1px solid var(--sb-line);
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  }
  .sb-tabbar a {
    flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; position: relative;
    color: var(--sb-muted); text-decoration: none; font-size: 11px; font-weight: 500; line-height: 1.4; padding: 4px 0;
  }
  .sb-tabbar a i { font-size: 21px; line-height: 1.1; }
  .sb-tabbar a.is-active { color: var(--sb-primary); font-weight: 600; }
  .sb-tabbar sup { position: absolute; top: 0; left: 50%; margin-left: 4px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: var(--sb-accent); color: #fff; font-size: 10.5px; font-weight: 700; line-height: 17px; text-align: center; }
}
.footer-nav-area { display: none !important; }

/* Giỏ hàng, tài khoản…: trang chưa làm lại vẫn hưởng màu mới */
.cart-wrapper-area .card, .checkout-wrapper-area .card, .profile-wrapper-area .card, .order-wrapper-area .card { border-radius: var(--sb-radius) !important; border: 0; box-shadow: var(--sb-shadow); }
.section-heading h6 { font-size: 18px !important; font-weight: 700 !important; line-height: 1.4; color: var(--sb-ink) !important; }

/* Rao vặt (module cũ .post trong lưới mới) */
.sb-ads { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 767.98px) { .sb-ads { grid-template-columns: minmax(0, 1fr); } }
@media (min-width: 1200px) { .sb-ads { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.sb-ads .card { border: 1px solid var(--sb-line); border-radius: 12px; box-shadow: none; overflow: hidden; }
.sb-ads .post { display: flex; gap: 12px; padding: 10px; }
.sb-ads .post > a { flex-shrink: 0; }
.sb-ads .post img { width: 76px; height: 76px; object-fit: cover; border-radius: 8px; }
.sb-ads .post-content { flex: 1; min-width: 0; font-size: 12.5px; color: var(--sb-muted); }
.sb-ads .post-content a { text-decoration: none; }
.sb-ads .post-content h2 { font-size: 14px; font-weight: 600; line-height: 1.45; margin: 0 0 4px; color: var(--sb-ink); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; padding-top: 1px; height: auto; white-space: normal; }
.sb-ads .post-content .price { color: var(--sb-accent); font-weight: 700; font-size: 15px; margin: 0; }
.sb-slide--intro > * { position: relative; z-index: 1; }
.product-card .price_product { height: auto !important; min-height: 0 !important; }
.product-card .price_product .price-product-text { width: auto !important; min-width: 0; margin: 0 !important; }
.product-card .product-title-wrapper { min-height: 0 !important; }
@media (max-width: 575.98px) {
  .sb-trust__item small { display: none; }
  .sb-trust__item { padding: 10px; gap: 8px; }
  .sb-trust__item b { font-size: 12.5px; }
  .sb-trust__item i { width: 30px; height: 30px; font-size: 13px; }
  .product-card .product-title { font-size: 13px !important; }
  .product-card .sale-price { font-size: 14.5px !important; }
}
.sb-product-page .product-title-meta-data { border-top-left-radius: 18px !important; border-top-right-radius: 18px; margin-top: -18px; }
.sb-product-page .product-title-meta-data::after { display: none !important; }
.sb-product-page .badge.bg-danger, .sb-product-page .badge-danger { background: var(--sb-accent) !important; }

/* Trang sản phẩm — máy tính */
.sb-product-page .product-desktop { padding-top: 20px !important; }
.sb-product-page .product-desktop > .row { border-radius: var(--sb-radius); box-shadow: var(--sb-shadow); padding: 24px !important; }
.sb-product-page .product-desktop .card { border: 0; }
.sb-product-page .product-desktop .card-img { border-radius: 12px; }
.sb-product-page .product-desktop #p_name { font-size: 26px; font-weight: 700; line-height: 1.4; padding-top: 2px; margin-bottom: 10px !important; }
.sb-product-page .product_vendor_package, .sb-product-page .product_evc_voucher {
  border-radius: 6px; padding: 3px 10px; font-size: 13px; font-weight: 600; line-height: 1.5; display: inline-block;
}
.sb-product-page .product_vendor_package { background: var(--sb-primary) !important; color: #fff !important; }
.sb-product-page .product_evc_voucher { background: var(--sb-success) !important; color: #fff !important; }
.sb-product-page .product-desktop .product-price { background: linear-gradient(90deg, #fff4ee, #fff) !important; border-radius: 12px; padding: 14px 20px !important; margin: 14px 0 !important; }
.sb-product-page .product-desktop .product-price .sale-price { font-size: 30px !important; line-height: 1.35; }
.sb-product-page .product-desktop .quantity-button-handler { border-radius: 10px !important; width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; }
.sb-product-page .product-desktop .cart-quantity-input { border-radius: 10px !important; height: 40px; }
.sb-product-page #add_product, .sb-product-page .buy_now { height: 48px; padding: 0 28px; font-size: 16px; border-radius: 12px; }
.sb-product-page #add_product { background: var(--sb-accent-50) !important; color: var(--sb-accent) !important; border: 1.5px solid var(--sb-accent) !important; }
.sb-product-page #add_product:hover { background: #ffe3d6 !important; }
.sb-product-page .product-desktop .row.mt-4 { border-radius: var(--sb-radius); box-shadow: var(--sb-shadow); }
.sb-product-page .product-desktop .row.mt-4 h6 { font-size: 18px; font-weight: 700; line-height: 1.4; }
.sb-product-page .shop { border-radius: var(--sb-radius) !important; box-shadow: var(--sb-shadow); }

/* Trang 404 */
.sb-404 { text-align: center; padding: 48px 20px; }
.sb-404__code { font-size: 88px; font-weight: 800; line-height: 1.2; color: var(--sb-primary); letter-spacing: -.03em; }
.sb-404 h1 { font-size: 26px; font-weight: 700; margin: 8px 0; }
.sb-404 p { color: var(--sb-muted); margin-bottom: 20px; }
.sb-404__search { display: flex; gap: 8px; max-width: 520px; margin: 0 auto; }
.sb-404__search input { flex: 1; min-width: 0; height: 44px; border: 1.5px solid var(--sb-line); border-radius: 12px; padding: 0 14px; font-size: 15px; }
