/* 브랜드·카테고리 탐색 · 연관 레일 · 자주 본 브랜드 */

/* ── 상세 탐색 pills ── */
.mall-local-discovery {
  margin: 1.25rem 0 0;
  padding: 0;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
  overflow: visible;
}

.m-detail__body .mall-local-discovery {
  margin: 18px 0 4px;
}

/* PC 상세 — 히어로 아래 패널 (overflow clip 없음 → pill 호버 시 상단 kicker 유지) */
#mallWrap #productDetailView .mall-local-discovery,
.product-detail-root > .mall-local-discovery {
  margin-top: clamp(18px, 2.5vw, 24px);
  padding: clamp(14px, 2vw, 18px);
  border: 1px solid var(--editorial-line, var(--mall-card-border, rgba(64, 70, 80, 0.09)));
  border-radius: 0;
  background: #fff;
  box-shadow: none;
}

.mall-local-discovery__pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: stretch;
}

.mall-local-discovery__pill {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 3px;
  margin: 0;
  padding: 10px 14px;
  min-height: 52px;
  border: 1px solid rgba(53, 58, 66, 0.14);
  border-radius: 0;
  cursor: pointer;
  text-align: left;
  color: var(--mall-charcoal-deep, #353a42);
  background: #fff;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    background-color 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.mall-local-discovery__pill:hover {
  border-color: rgba(53, 58, 66, 0.28);
  box-shadow: 0 4px 14px rgba(15, 22, 18, 0.07);
}

.mall-local-discovery__pill:active {
  box-shadow: 0 1px 4px rgba(15, 22, 18, 0.05);
}

.mall-local-discovery__pill-kicker {
  flex: 0 0 auto;
  font-size: 0.5625rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  line-height: 1.2;
  color: rgba(53, 58, 66, 0.48);
}

.mall-local-discovery__pill-label {
  flex: 0 0 auto;
  font-size: 0.8125rem;
  font-weight: 700;
  line-height: 1.25;
}

.mall-local-discovery__pill--brand {
  background: linear-gradient(135deg, #fff 0%, rgba(250, 250, 249, 0.92) 100%);
}

.mall-local-discovery__pill--brand:hover {
  background: #fff;
}

.mall-local-discovery__pill--category {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(245, 245, 244, 0.95) 100%);
}

.mall-local-discovery__pill--category:hover {
  background: #fff;
}

/* ── 상세 연관 레일 ── */
.detail-buy .mall-local-discovery {
  margin-top: 1rem;
}

.mall-local-discovery__related {
  margin-top: 1.125rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(53, 58, 66, 0.08);
  overflow: hidden;
}

/* ── 카탈로그 자주 본 브랜드 (캐러셀 트랙) ── */
.mall-local-brand-chips {
  margin: 0 0 12px;
  padding: 0;
}

.mall-local-brand-chips__chip {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
  width: min(248px, 84%);
  max-width: 248px;
  margin: 0;
  padding: 10px 12px 10px 10px;
  border: 1px solid var(--editorial-line, rgba(53, 58, 66, 0.12));
  border-radius: 0;
  scroll-snap-align: start;
  cursor: pointer;
  text-align: left;
  color: inherit;
  background: #fff;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    background-color 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.mall-local-brand-chips__chip:hover {
  border-color: rgba(53, 58, 66, 0.22);
  box-shadow: 0 4px 14px rgba(15, 22, 18, 0.06);
}

.mall-local-brand-chips__chip--warm {
  border-color: rgba(154, 92, 69, 0.18);
  background: linear-gradient(135deg, #fff 0%, rgba(250, 247, 244, 0.92) 100%);
}

.mall-local-brand-chips__chip--warm .mall-local-brand-chips__meta {
  color: var(--mall-accent-deal, #9a5c45);
  font-weight: 600;
}

.mall-local-brand-chips__mark {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--editorial-line, rgba(53, 58, 66, 0.1));
  border-radius: 0;
  background: #fafaf9;
  overflow: hidden;
}

.mall-local-brand-chips__logo {
  display: block;
  max-width: 36px;
  max-height: 28px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.mall-local-brand-chips__mark--initial {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: rgba(53, 58, 66, 0.5);
}

.mall-local-brand-chips__copy {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.mall-local-brand-chips__kicker {
  font-size: 0.5625rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  line-height: 1.2;
  color: rgba(53, 58, 66, 0.45);
}

.mall-local-brand-chips__name {
  font-size: 0.8125rem;
  font-weight: 700;
  line-height: 1.25;
  color: var(--mall-charcoal-deep, #353a42);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mall-local-brand-chips__meta {
  font-size: 0.6875rem;
  font-weight: 500;
  line-height: 1.3;
  color: var(--editorial-muted, rgba(53, 58, 66, 0.62));
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mall-local-brand-chips__chev {
  flex: 0 0 auto;
  font-size: 1.125rem;
  line-height: 1;
  font-weight: 600;
  color: #353a42;
  opacity: 0.4;
}

.m-catalog .mall-local-brand-chips {
  margin: 0 16px 12px;
}

#mallWrap .products--premium .mall-local-brand-chips {
  margin-bottom: 0;
}
