/* Smart Search - dientu179.vn v1.2 */

.ss-panel {
  position: fixed;
  z-index: 100000;
  display: none;
  max-height: 420px;
  overflow-y: auto;
  background: #fff;
  border: 1px solid #dfe3e8;
  border-radius: 8px;
  box-shadow: 0 10px 28px rgba(16, 24, 40, .16);
  -webkit-overflow-scrolling: touch;
}
.ss-panel.is-open { display: block; }

.ss-note {
  padding: 14px 16px;
  font-size: 13px;
  color: #6b7280;
}

.ss-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 12px;
  border-bottom: 1px solid #f1f2f4;
  text-decoration: none;
  color: #1f2328;
}
.ss-row:last-child { border-bottom: 0; }
.ss-row.is-active { background: #f3f7fd; }


.ss-row img,
.ss-noimg {
  flex: 0 0 46px;
  width: 46px;
  height: 46px;
  object-fit: contain;
  border-radius: 4px;
  background: #f5f6f7;
}

.ss-body {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ss-name {
  font-size: 13.5px;
  line-height: 1.35;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.ss-name mark {
  background: #fff1b8;
  color: inherit;
  padding: 0 1px;
}

.ss-code {
  font-size: 11.5px;
  color: #8a9099;
  letter-spacing: .02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

}
}
}
}

.ss-price {
  flex: 0 0 auto;
  text-align: right;
  font-size: 13.5px;
  font-weight: 600;
  color: #d0021b;
  white-space: nowrap;
}
.ss-price em {
  display: block;
  font-style: normal;
  font-size: 11px;
  font-weight: 400;
  color: #9aa0a6;
}

@media (max-width: 480px) {
  .ss-panel { max-height: 60vh; }
  .ss-row img, .ss-noimg { flex-basis: 40px; width: 40px; height: 40px; }
  .ss-name { font-size: 13px; }
}
/* dong Xem tat ca trong dropdown */
.ss-more {
  display: block;
  padding: 10px 12px;
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  color: #1a73e8;
  background: #f7f9fc;
  border-top: 1px solid #e6e9ed;
  text-decoration: none;
}
.ss-more:hover { background: #eef4fd; }
/* trang ket qua day du */
.ss-page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px 16px 48px;
}
.ss-page-title {
  font-size: 20px;
  font-weight: 600;
  margin: 0 0 18px;
  color: #1f2328;
}
.ss-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.ss-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 12px;
  border: 1px solid #e6e9ed;
  border-radius: 8px;
  background: #fff;
  text-decoration: none;
  color: #1f2328;
  transition: box-shadow .15s;
}
.ss-card:hover { box-shadow: 0 4px 14px rgba(16, 24, 40, .12); }
.ss-card img, .ss-card .ss-noimg {
  width: 100%;
  height: 150px;
  object-fit: contain;
  background: #f5f6f7;
  border-radius: 4px;
}
.ss-cname {
  font-size: 13.5px;
  line-height: 1.4;
  min-height: 38px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.ss-cname mark { background: #fff1b8; color: inherit; }
.ss-ccode {
  font-size: 11.5px;
  color: #8a9099;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ss-cprice {
  font-size: 15px;
  font-weight: 700;
  color: #d0021b;
}
.ss-cprice em {
  display: block;
  font-style: normal;
  font-size: 11px;
  font-weight: 400;
  color: #9aa0a6;
}
@media (max-width: 600px) {
  .ss-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .ss-card img, .ss-card .ss-noimg { height: 120px; }
}

@media (min-width: 601px) and (max-width: 1024px) {
  .ss-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.ss-pager {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin: 28px 0 0;
}
.ss-pager a, .ss-pager span {
  min-width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  border: 1px solid #e0e4e8;
  border-radius: 6px;
  font-size: 13.5px;
  color: #1f2328;
  text-decoration: none;
  background: #fff;
}
.ss-pager a:hover { border-color: #1a73e8; color: #1a73e8; }
.ss-pager .ss-cur { background: #1a73e8; border-color: #1a73e8; color: #fff; font-weight: 600; }
.ss-pager .ss-gap { border: 0; background: transparent; color: #9aa0a6; }

.ss-layout {
  display: grid;
  grid-template-columns: 236px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}
.ss-filters {
  border: 1px solid #e6e9ed;
  border-radius: 8px;
  background: #fff;
  padding: 4px 14px 14px;
  position: sticky;
  top: 12px;
}
.ss-fgroup { padding: 12px 0 4px; border-bottom: 1px solid #f1f2f4; }
.ss-fgroup:last-child { border-bottom: 0; }
.ss-fgroup h3 {
  font-size: 14px;
  font-weight: 600;
  margin: 0 0 8px;
  color: #1f2328;
}
.ss-fitem {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 0;
  font-size: 13px;
  color: #30353b;
  text-decoration: none;
  line-height: 1.35;
}
.ss-fitem i {
  flex: 0 0 15px;
  width: 15px;
  height: 15px;
  border: 1px solid #c3c9d0;
  border-radius: 3px;
  background: #fff;
}
.ss-fitem.on i { background: #1a73e8; border-color: #1a73e8; }
.ss-fitem.on { color: #1a73e8; font-weight: 600; }
.ss-fitem b { font-weight: 400; color: #9aa0a6; }
.ss-fitem:hover { color: #1a73e8; }
.ss-fclear {
  display: block;
  margin: 12px 0 0;
  font-size: 13px;
  color: #d0021b;
  text-decoration: none;
}
@media (max-width: 900px) {
  .ss-layout { grid-template-columns: 1fr; }
  .ss-filters { position: static; }
  .ss-fgroup { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
  .ss-fgroup h3 { width: 100%; margin-bottom: 4px; }
  .ss-fitem { border: 1px solid #e0e4e8; border-radius: 14px; padding: 5px 11px; }
  .ss-fitem i { display: none; }
}

/* bo cuc trang ket qua co bo loc */
.ss-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}
.ss-side {
  border: 1px solid #e6e9ed;
  border-radius: 8px;
  background: #fff;
  padding: 14px;
  position: sticky;
  top: 12px;
}
.ss-clear {
  display: inline-block;
  margin-bottom: 12px;
  font-size: 13px;
  color: #d0021b;
  text-decoration: none;
}
.ss-fgroup { margin-bottom: 16px; }
.ss-ftitle {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 8px;
  color: #1f2328;
}
.ss-fgroup ul {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 220px;
  overflow-y: auto;
}
.ss-fgroup li a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 2px;
  font-size: 13px;
  color: #3c4043;
  text-decoration: none;
}
.ss-fgroup li a i {
  flex: 0 0 15px;
  width: 15px;
  height: 15px;
  border: 1px solid #c3c8cd;
  border-radius: 3px;
}
.ss-fgroup li a.ss-on i { background: #1a73e8; border-color: #1a73e8; }
.ss-fgroup li a.ss-on span { color: #1a73e8; font-weight: 600; }
.ss-fgroup li a span {
  flex: 1 1 auto;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ss-fgroup li a b { font-weight: 400; font-size: 12px; color: #9aa0a6; }
@media (max-width: 1024px) {
  .ss-layout { grid-template-columns: minmax(0, 1fr); }
  .ss-side { position: static; }
  .ss-fgroup ul { max-height: 160px; }
}

/* anh san pham: vuong, nen trang, khong bop meo */
.ss-card img,
.ss-card .ss-noimg {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  background: #fff;
  padding: 6px;
  border-radius: 4px;
}
.ss-card .ss-cname,
.ss-card:visited .ss-cname { color: #1f2328; }
.ss-card:hover .ss-cname { color: #1a73e8; }
@media (max-width: 600px) {
  .ss-card img, .ss-card .ss-noimg { height: auto; }
}

/* ket qua goi y trong o tim kiem: anh nho, ten + SKU ben canh */
.ss-panel .ss-row img,
.ss-panel .ss-row .ss-noimg {
  flex: 0 0 52px;
  width: 52px;
  height: 52px;
  aspect-ratio: auto;
  object-fit: contain;
  background: #fff;
  padding: 0;
  border-radius: 4px;
}

/* o san pham trang ket qua: badge giam gia, gia gach, sao */
.ss-cimg {
  position: relative;
  display: block;
  width: 100%;
}
.ss-cbadge {
  position: absolute;
  top: 6px;
  left: 6px;
  background: #d0021b;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 3px;
}
.ss-cout {
  position: absolute;
  bottom: 6px;
  left: 6px;
  background: rgba(31, 35, 40, .75);
  color: #fff;
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 3px;
}
.ss-crow {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px;
}
.ss-crow .ss-cprice {
  font-size: 15px;
  font-weight: 700;
  color: #d0021b;
}
.ss-cold {
  font-size: 12px;
  color: #9aa0a6;
}
.ss-cpct {
  font-style: normal;
  font-size: 12px;
  color: #d0021b;
}
.ss-cstars {
  font-size: 13px;
  color: #f5a623;
  letter-spacing: 1px;
  line-height: 1;
}
