/* Product listings (shop, category, collection, search) for both designs. */

/* ---------- Shared: grid, filter options, chips, pager ---------- */
.be-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 40px 28px;
}

.be-grid > .be-pc {
  width: auto;
  min-width: 0;
}

.be-fgroup {
  border-top: 1px solid var(--be-line);
}

.be-fgroup:first-of-type {
  border-top: 0;
}

.be-fgroup__title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 14px 0;
  font-size: 14px;
  font-weight: 700;
  line-height: 20px;
  color: var(--be-ink);
  list-style: none;
  cursor: pointer;
}

.be-fgroup__title::-webkit-details-marker {
  display: none;
}

.be-fgroup__title svg {
  color: var(--be-coral-soft);
  transition: transform 0.2s ease;
}

.be-fgroup[open] > .be-fgroup__title svg {
  transform: rotate(180deg);
}

.be-fgroup__list {
  display: grid;
  gap: 2px;
  padding-bottom: 14px;
}

.be-fgroup__list.is-long {
  max-height: 264px;
  overflow-y: auto;
  scrollbar-width: thin;
}

.be-fopt {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 32px;
  padding: 4px 6px;
  border-radius: 10px;
  font-size: 13px;
  line-height: 18px;
  color: var(--be-ink-soft);
}

.be-fopt:hover {
  background: var(--be-blush);
}

.be-fopt__box {
  flex: 0 0 auto;
  width: 16px;
  height: 16px;
  border: 1.5px solid var(--be-blush-line);
  border-radius: 4px;
  background: var(--be-white);
  display: grid;
  place-items: center;
}

.be-fopt--radio .be-fopt__box {
  border-radius: 50%;
}

.be-fopt.is-on {
  color: var(--be-ink);
  font-weight: 600;
}

.be-fopt.is-on .be-fopt__box {
  border-color: var(--be-coral);
  background: var(--be-coral);
  box-shadow: inset 0 0 0 2.5px var(--be-white);
}

.be-fopt__label {
  flex: 1 1 auto;
  min-width: 0;
}

.be-fopt__count {
  font-size: 11px;
  color: var(--be-muted);
}

.be-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.be-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 0 10px 0 14px;
  border-radius: 999px;
  background: var(--be-blush);
  color: var(--be-coral);
  font-size: 12px;
  font-weight: 600;
}

.be-chip:hover {
  background: var(--be-blush-line);
}

.be-pager {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-top: 48px;
}

.be-pager__num,
.be-pager__step,
.be-pager__gap {
  min-width: 40px;
  height: 40px;
  padding: 0 6px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  color: var(--be-ink-soft);
}

.be-pager__num,
.be-pager__step {
  border: 1px solid var(--be-line);
  background: var(--be-white);
}

.be-pager a:hover {
  border-color: var(--be-coral-soft);
  color: var(--be-coral);
}

.be-pager__num.is-on {
  border-color: transparent;
  background: var(--be-coral-soft);
  color: var(--be-white);
}

.be-pager__step.is-off {
  opacity: 0.4;
}

.be-sec__sub {
  margin-top: 4px;
  font-size: 13px;
  color: var(--be-muted);
}

.be-bundles4__card {
  display: block;
  width: 100%;
}

.be-bundles4__img {
  display: block;
  aspect-ratio: 1;
  border-radius: 24px;
  overflow: hidden;
  background: var(--be-white);
}

.be-bundles4__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.be-bundles4__card:hover img {
  transform: scale(1.04);
}

.be-bundles4__title {
  display: block;
  margin-top: 10px;
  font-size: 14px;
  font-weight: 500;
  line-height: 22px;
  color: var(--be-ink-soft);
}

/* ---------- Desktop ---------- */
.be-plp__head {
  margin: 32px auto 0;
  max-width: 760px;
  text-align: center;
}

.be-plp__title {
  font-size: 28px;
  font-weight: 700;
  line-height: 36px;
  color: var(--be-ink);
}

.be-plp__sub {
  margin-top: 8px;
  color: var(--be-muted);
}

.be-plp__circles {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px 8px;
  margin-top: 32px;
}

.be-plp__circles .be-tile.is-active .be-tile__img {
  border: 2px solid var(--be-coral-soft);
}

.be-plp__circles .be-tile.is-active .be-tile__label {
  color: var(--be-coral);
  font-weight: 600;
}

.be-plp__pill {
  height: 36px;
  padding: 0 16px;
  border: 1.5px solid var(--be-line);
  border-radius: 999px;
  background: var(--be-white);
  font-size: 13px;
  font-weight: 600;
  line-height: 33px;
  color: var(--be-ink-soft);
}

.be-plp__pill.is-active {
  border-color: var(--be-coral-soft);
  background: var(--be-blush);
  color: var(--be-coral);
}

.be-plp__layout {
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
  gap: 40px;
  align-items: start;
  margin-top: 48px;
}

.be-filters {
  position: sticky;
  top: 24px;
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  padding: 8px 18px 12px;
  border: 1px solid var(--be-line);
  border-radius: 20px;
  background: var(--be-white);
  scrollbar-width: thin;
}

.be-filters__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid var(--be-line);
}

.be-filters__head h2 {
  font-size: 15px;
  font-weight: 700;
}

.be-filters__head a {
  font-size: 12px;
  font-weight: 600;
  color: var(--be-coral);
}

.be-plp__toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

.be-plp__count {
  font-size: 13px;
  color: var(--be-muted);
}

.be-sort {
  position: relative;
}

.be-sort > summary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 40px;
  padding: 0 14px 0 16px;
  border: 1px solid var(--be-line);
  border-radius: 999px;
  background: var(--be-white);
  font-size: 13px;
  color: var(--be-muted);
  list-style: none;
  cursor: pointer;
}

.be-sort > summary::-webkit-details-marker {
  display: none;
}

.be-sort > summary strong {
  font-weight: 600;
  color: var(--be-ink);
}

.be-sort__menu {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 20;
  min-width: 220px;
  padding: 8px;
  border: 1px solid var(--be-line);
  border-radius: 16px;
  background: var(--be-white);
  box-shadow: var(--be-shadow-soft);
}

.be-sort__menu a {
  display: block;
  padding: 9px 12px;
  border-radius: 10px;
  font-size: 13px;
  color: var(--be-ink-soft);
}

.be-sort__menu a:hover,
.be-sort__menu a.is-active {
  background: var(--be-blush);
  color: var(--be-coral);
  font-weight: 600;
}

.be-plp__empty {
  padding: 64px 24px;
}

.be-plp > .be-heart-sep {
  margin-top: 72px;
}

.be-plp > .be-heart-sep + .be-sec {
  margin-top: 40px;
}

.be-plp__about {
  max-width: 880px;
}

.be-similar {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
  margin-top: 20px;
}

.be-similar__card {
  display: flex;
  align-items: center;
  gap: 14px;
  height: 72px;
  padding: 0 16px 0 0;
  border: 1px solid var(--be-line);
  border-radius: 16px;
  background: var(--be-white);
  overflow: hidden;
  font-size: 14px;
  font-weight: 600;
  color: var(--be-ink);
  transition: border-color 0.15s ease;
}

.be-similar__card:hover {
  border-color: var(--be-coral-soft);
}

.be-similar__img {
  flex: 0 0 72px;
  height: 72px;
  background: var(--be-canvas);
}

.be-similar__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.be-similar__label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.be-d .be-bundles4 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
  margin-top: 20px;
}

@media (max-width: 1279px) {
  .be-plp__layout {
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 28px;
  }

  .be-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 32px 20px;
  }
}

@media (max-width: 1023px) {
  .be-similar,
  .be-d .be-bundles4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .be-grid {
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  }
}

/* ---------- Mobile ---------- */
.be-mplp {
  padding-top: 8px;
}

.be-mplp__search {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 48px;
  padding: 0 16px;
  border: 1px solid var(--be-line);
  border-radius: 999px;
  background: var(--be-white);
  box-shadow: 0 4px 14px rgba(90, 35, 51, 0.04);
  color: var(--be-muted);
}

.be-mplp__search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: 14px;
  color: var(--be-ink);
}

.be-mplp__search input::placeholder {
  color: #a48c85;
}

.be-mplp__toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin: 16px 0 12px;
}

.be-mplp__heading {
  min-width: 0;
}

.be-mplp__title {
  font-family: var(--be-font-display);
  font-size: 22px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--be-ink);
  overflow-wrap: anywhere;
}

.be-mplp__count {
  margin-top: 4px;
  font-size: 12px;
  color: #a48c85;
}

.be-mplp__toggles {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.be-mplp__chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 36px;
  padding: 0 12px;
  border: 1px solid var(--be-line);
  border-radius: 999px;
  background: var(--be-white);
  font-size: 12px;
  font-weight: 600;
  color: var(--be-ink);
}

.be-mplp__chip-count {
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--be-coral);
  color: var(--be-white);
  font-size: 10px;
  line-height: 18px;
  text-align: center;
}

.be-mplp__view {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 1px solid var(--be-line);
  border-radius: 12px;
  background: var(--be-white);
  color: #a48c85;
}

.be-mplp__view.is-on {
  border-color: transparent;
  background: var(--be-blush);
  color: var(--be-coral);
}

.be-mplp__pills {
  display: flex;
  gap: 8px;
  margin: 0 calc(-1 * var(--be-m-pad)) 16px;
  padding: 0 var(--be-m-pad);
  overflow-x: auto;
  scrollbar-width: none;
}

.be-mplp__pills::-webkit-scrollbar {
  display: none;
}

.be-mplp__pill {
  flex: 0 0 auto;
  height: 34px;
  padding: 0 14px;
  border: 1px solid var(--be-line);
  border-radius: 999px;
  background: var(--be-white);
  font-size: 12px;
  font-weight: 500;
  line-height: 32px;
  color: var(--be-ink-soft);
  white-space: nowrap;
}

.be-mplp__pill.is-on {
  border-color: transparent;
  background: var(--be-blush);
  color: var(--be-coral);
  font-weight: 600;
}

.be-chips--m {
  margin-bottom: 16px;
}

.be-m .be-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 12px;
}

@media (min-width: 600px) {
  .be-m .be-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.be-m .be-grid > .be-pc {
  width: auto;
}

.be-m .be-grid--list {
  grid-template-columns: 1fr;
  gap: 16px;
}

.be-m .be-grid--list > .be-pc {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  grid-template-rows: auto auto 1fr;
  column-gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--be-line);
}

.be-m .be-grid--list .be-pc__img {
  grid-row: 1 / span 3;
  border-radius: 16px;
}

.be-m .be-grid--list .be-pc__heart-form {
  left: 82px;
  right: auto;
}

.be-m .be-grid--list .be-pc__brand-row {
  margin-top: 0;
}

.be-m .be-grid--list .be-pc__name {
  min-height: 0;
}

.be-m .be-pager {
  margin-top: 32px;
  gap: 6px;
}

.be-m .be-pager__num,
.be-m .be-pager__step,
.be-m .be-pager__gap {
  min-width: 36px;
  height: 36px;
  font-size: 13px;
}

.be-mplp__empty {
  margin-top: 16px;
}

.be-m .be-rail .be-bundles4__card {
  width: 220px;
}

/* ---------- Bottom sheet (mobile filters) ---------- */
.be-sheet {
  width: 100%;
  max-width: 560px;
  max-height: 88vh;
  margin: auto auto 0;
  padding: 0;
  border: 0;
  border-radius: 28px 28px 0 0;
  background: var(--be-canvas);
  color: var(--be-ink);
  display: none;
  flex-direction: column;
}

.be-sheet[open] {
  display: flex;
  animation: be-sheet-in 0.24s ease-out;
}

.be-sheet::backdrop {
  background: rgba(58, 18, 30, 0.42);
}

@keyframes be-sheet-in {
  from {
    transform: translateY(40px);
    opacity: 0;
  }
}

.be-sheet__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 12px;
  border-bottom: 1px solid var(--be-line);
}

.be-sheet__head h2 {
  font-size: 18px;
  font-weight: 700;
}

.be-sheet__close {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--be-white);
}

.be-sheet__body {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 4px 24px 12px;
  overscroll-behavior: contain;
}

.be-sheet__foot {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 12px;
  padding: 12px 24px calc(12px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--be-line);
  background: var(--be-white);
}

.be-sheet__foot .be-btn {
  height: 48px;
  padding: 0 16px;
}
