/* BSP UX Polish v1.0 */

/* --- Footer: logo tối nền navy -> chip trắng để đọc được --- */
footer.site .logo-custom{background:#fff;padding:8px 14px;border-radius:10px;display:inline-flex}
footer.site .logo-custom img{height:34px;margin:0}

/* --- Ảnh card đồng đều: không cắt sản phẩm, nền trắng --- */
.acard .imgwrap{background:#fff;border-radius:10px;border:1px solid var(--line,#e8e4dc);aspect-ratio:4/3}
.acard .imgwrap img,.acard img{object-fit:contain;padding:10px;box-sizing:border-box}
.acard{transition:transform .15s ease,box-shadow .15s ease}
.acard:hover{transform:translateY(-2px)}
.acard h2 a,.acard h3 a{text-decoration:none}
.acard:hover h2 a,.acard:hover h3 a{text-decoration:underline}
.acard p{display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.crow img,.lead img,.feat img{object-fit:contain;background:#fff}

/* --- Trang chủ: nhịp section gọn hơn, tiêu đề dễ quét --- */
.catblock{margin-top:36px;padding-top:18px}
.catblock .cat-title{font-size:clamp(22px,2.6vw,30px)}
.catblock .cat-title a{text-decoration:none}
.catblock .subs{font-size:14px}
.carousel{scroll-padding-left:4px;-webkit-overflow-scrolling:touch}
.carousel::-webkit-scrollbar{height:6px}
.carousel::-webkit-scrollbar-thumb{background:#c9c4b8;border-radius:6px}
.latest .it .h:hover,.clist .ci-title:hover{color:var(--gold,#f59e0b)}
.wrap + footer.site,.catblock:last-child{margin-bottom:40px}

/* --- Danh mục: hero gọn, subnav dạng chip cuộn ngang --- */
.cat-hero{padding:6px 0 4px}
.cat-hero h1{font-size:clamp(28px,4vw,40px);margin-bottom:8px}
.cat-hero .cat-intro{max-width:78ch;font-size:16px;line-height:1.55}
.cat-subnav{display:flex;gap:8px;flex-wrap:nowrap;overflow-x:auto;padding:6px 0 10px;margin-top:10px;scrollbar-width:thin}
.cat-subnav a{flex:0 0 auto;padding:7px 14px;border:1px solid var(--line,#e0dbd0);border-radius:999px;background:#fff;font-size:14px;font-weight:600;text-decoration:none;white-space:nowrap}
.cat-subnav a:hover{background:var(--navy,#07385b);color:#fff;border-color:var(--navy,#07385b)}
.breadcrumb-wrap{padding-top:12px}

/* --- Bài viết: thẻ sản phẩm gọn, nút mua rõ, sidebar dính --- */
.prod{padding:18px 20px;border-radius:12px;transition:box-shadow .15s ease}
.prod:hover{box-shadow:0 4px 18px rgba(7,56,91,.09)}
.prod-top{grid-template-columns:130px 1fr auto;gap:18px;align-items:center}
.prod .p-img{aspect-ratio:1;border-radius:8px}
.prod h3{font-size:clamp(17px,1.6vw,20px);line-height:1.25}
.prod h3 a{text-decoration:none}
.prod a[class*="btn"],.prod .p-cta a{white-space:nowrap}
@media(min-width:981px){
  .pf-article aside,.pf-article [class*="sidebar"]{position:sticky;top:76px;align-self:start}
}
.pf-article table{font-size:14px}
.pf-article table tr:hover td{background:rgba(245,158,11,.06)}

/* --- Mobile --- */
@media(max-width:640px){
  .prod-top{grid-template-columns:96px 1fr;gap:12px}
  .prod-top > :last-child{grid-column:1 / -1}
  .prod-top > :last-child a{display:block;text-align:center;padding:12px;font-size:16px}
  .prod .p-desc{font-size:14px}
  .card-grid{grid-template-columns:1fr;gap:18px}
  .catblock{margin-top:26px}
  .acard .imgwrap{aspect-ratio:16/10}
  .cat-subnav{margin-right:-16px;padding-right:16px}
}
@media(max-width:980px) and (min-width:641px){
  .card-grid{grid-template-columns:repeat(2,1fr)}
}

/* --- Bảng so sánh: mobile không cắt cột, cuộn ngang mượt --- */
@media(max-width:700px){
  .compare-table{display:block;overflow-x:auto;-webkit-overflow-scrolling:touch;white-space:nowrap;max-width:100%}
  .compare-table td:nth-child(2),.compare-table th:nth-child(2){white-space:normal;min-width:200px}
  .compare-table td:first-child,.compare-table th:first-child{position:sticky;left:0;background:#fff;z-index:1}
  .compare-table th:first-child{background:var(--navy,#07385b)}
}
