/* ================= BASIC ================= */
* {
  box-sizing: border-box;
}

body {
  background: #fff;
  color: #222;
}

/* ================= TOP BAR ================= */
.bc-topbar {
  width: 100%;
  margin: 0;
  border-radius: 0 !important;   /* ตัดมุมโค้ง */
  box-shadow: none;              /* ถ้ามีเงา */
  background: #000;              /* ธีมดำ */
  color: #ffd400;                /* เหลือง */
}

/* ================= LOGO ================= */
.bc-logo {
  font-size: 28px;
  font-weight: 800;
  text-decoration: none;
  color: #000;
}
.bc-logo span {
  color: #f7f305;
}

/* ================= SEARCH ================= */
.bc-search {
  position: relative;
}
.bc-search i {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: #999;
}
.bc-search input {
  width: 100%;
  height: 44px;
  padding-left: 44px;
  border-radius: 999px;
  border: 1px solid #ddd;
}

/* ================= ICON ================= */
.bc-icons a {
  font-size: 18px;
  color: #333;
  margin-left: 16px;
}

/* ================= NAV ================= */
.bc-nav {
  border-top: 1px solid #eee;
  background: #fff;
  padding: 10px 0;
}
.bc-nav a {
  text-decoration: none;
  color: #333;
  font-size: 14px;
}
.bc-nav a.active {
  color: #f7f305;
  font-weight: 600;
}

/* ================= CATEGORY DROPDOWN ================= */
.bc-category {
  position: relative;
}
.bc-category button {
  background: #f3f5f7;
  border: none;
  padding: 10px 16px;
  border-radius: 999px;
  font-weight: 500;
}
.bc-category-dropdown {
  display: none;
  position: absolute;
  top: 48px;
  left: 0;
  width: 260px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 8px 30px rgba(224, 1, 1, 0.15);
  padding: 10px;
  z-index: 999;
}
.bc-category-dropdown a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border-radius: 6px;
}
.bc-category-dropdown a:hover {
  background: #f3f5f7;
}
.bc-category:hover .bc-category-dropdown {
  display: block;
}

/* ================= HERO ================= */
.hero-frame {
  width: 100%;
  height: 420px;
  background: #f3f5f7;
  border: 2px dashed #ccc;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-frame img {
  width: 100%;
  height: 420px;
  object-fit: cover;
  border-radius: 16px;
}

/* ================= PLACEHOLDER ================= */
.img-placeholder,
.promo-placeholder {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #f3f5f7;
  border: 2px dashed #ccc;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #999;
}

/* ================= PROMO BOX ================= */
.promo-box {
  border-radius: 12px;
}

/* ================= HORIZONTAL PRODUCT SCROLL ================= */
.product-scroll-wrapper {
  position: relative;
}

/* แถวเลื่อน */
.product-scroll {
  display: flex;
  gap: 16px;
  overflow-x: hidden; /* ซ่อน scrollbar */
  scroll-behavior: smooth;
  cursor: grab;
  padding: 4px 2px 14px;
}
.product-scroll:active {
  cursor: grabbing;
}

/* ================= PRODUCT CARD ================= */
.product-card {
  flex: 0 0 220px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 4px 12px rgba(0,0,0,.08);
  padding: 12px;
  display: flex;
  flex-direction: column;
}

/* รูป */
.product-img {
  width: 100%;
  height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.product-img img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

/* ข้อมูล */
.product-body {
  margin-top: 8px;
}
.product-name {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  height: 36px;
  overflow: hidden;
}
.product-price {
  color: #fc0303;
  font-weight: 700;
  margin: 6px 0;
}

/* ================= SCROLL BUTTON ================= */
.scroll-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: #797979;
  box-shadow: 0 4px 10px rgba(0,0,0,.15);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.scroll-btn:hover {
  background: #f7f305;
  color: #fff;
}

/* ===== FIX DROPDOWN PROFILE MOBILE ===== */
@media (max-width: 768px) {

  .bc-user-dropdown {
    position: fixed !important;
    top: 60px !important;
    right: 10px !important;
    left: 10px !important;
    width: auto !important;
    max-width: none !important;
    transform: none !important;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,.15);
    z-index: 1055;
  }

}

/* ===== FIX PROFILE DROPDOWN MOBILE ===== */
@media (max-width: 991.98px) {

  .dropdown-menu {
    position: fixed !important;
    top: 64px !important;
    right: 12px !important;
    left: 12px !important;
    width: auto !important;
    max-width: none !important;
    transform: none !important;
    border-radius: 14px;
    box-shadow: 0 10px 30px rgba(0,0,0,.15);
    z-index: 1055;
  }

}

/* ===============================
   CATEGORY SIDEBAR (ONLY)
   =============================== */

.category-sidebar {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* ซ่อน radio จริง */
.category-sidebar input[type="radio"] {
  display: none;
}

/* กล่องหมวด */
.category-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: #f8f9fa;
  border-radius: 10px;
  cursor: pointer;
  font-size: 14px;
  color: #222;
  transition: all .2s ease;
}

/* hover */
.category-item:hover {
  background: #ffcc00;
  color: #000;
}

/* icon ซ้าย */
.category-item::before {
  content: "\f07b"; /* folder */
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  width: 28px;
  height: 28px;
  background: #fff;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #555;
  flex-shrink: 0;
}

/* active (เลือกหมวดอยู่) */
.category-item:has(input[type="radio"]:checked),
.category-item.active {
  background: #ffcc00;
  color: #000;
  font-weight: 600;
}

/* icon ตอน active */
.category-item:has(input[type="radio"]:checked)::before,
.category-item.active::before {
  background: #000;
  color: #ffcc00;
}

.social {
  display: flex;
  gap: 14px;
  margin-top: 14px;
}

.social a {
  width: 36px;
  height: 36px;
  background: #1a1a1a;
  color: #ffcc00;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 16px;
  transition: all .2s ease;
}

.social a:hover {
  background: #ffcc00;
  color: #000;
}