/* =============================================
   LOHAS · vipstore.html · CSS
   --------------------------------------------
   風格：地圖探索風 (Airbnb-inspired) + 樂活棕色系
   --------------------------------------------
   結構：
   - .vs-shell           外層
   - .vs-subheader       頂部副標頭(膠囊搜尋 + icon 分類列)
   - .vs-layout          主版型：左卡片清單 / 右地圖
   - .vs-list-panel      左側商店街店家列表
   - .vs-place           單一店家卡(漸層 + logo + 評分浮層)
   - .vs-map-panel       右側地圖
   - .vs-store-pin       地圖上的 LOHAS 門市 marker(膠囊樣式)
   - .vs-pin-card        點 marker 後的浮層卡片
   - .vs-view-tabs       手機底部 FAB
   ============================================= */

/* ===== Shell ===== */
.vs-shell {
  margin-top: 70px;
  background: #fff;
}

/* ===== Subheader (膠囊搜尋 + 分類列) ===== */
.vs-subheader {
  background: #fff;
  border-bottom: 1px solid var(--lohas-bd);
  position: sticky;
  top: 70px;
  z-index: 60;
}
.vs-subheader-inner {
  max-width: 1480px;
  margin: 0 auto;
  padding: 18px 32px 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* 標題列 */
.vs-subheader-title {
  font-size: 13px;
  color: var(--text-sub);
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.vs-subheader-title > i:first-child {
  color: var(--lohas-brand);
  font-size: 18px;
}
.vs-subheader-title .accent {
  color: var(--lohas-brand);
  font-weight: 600;
  font-size: 17px;
  letter-spacing: 0.5px;
}
.vs-subheader-title b {
  color: var(--lohas-brand);
  font-weight: 600;
}

/* === KPI 三指標 (手機版顯示) === */
.vs-kpi {
  display: none;
}
.vs-kpi-cell {
  background: var(--bg-soft);
  border-radius: var(--r-md);
  padding: 10px 8px;
  text-align: center;
}
.vs-kpi-num {
  font-size: 20px;
  font-weight: 700;
  color: var(--lohas-brand);
  letter-spacing: -0.5px;
  line-height: 1;
}
.vs-kpi-lab {
  font-size: 10px;
  color: var(--text-sub);
  margin-top: 4px;
  letter-spacing: 0.5px;
}

/* === 膠囊搜尋列 === */
.vs-search {
  flex: 0 1 380px;
  position: relative;
  margin-left: auto;
}
.vs-search input {
  width: 100%;
  height: 44px;
  border: 1px solid var(--lohas-bd);
  border-radius: var(--r-pill);
  padding: 0 22px 0 48px;
  font-family: inherit;
  font-size: 14px;
  background: #fff;
  color: var(--text-main);
  letter-spacing: 0.3px;
  outline: none;
  transition: all 0.2s;
  box-shadow: 0 1px 2px rgba(80,66,45,0.04);
}
.vs-search input::placeholder {
  color: var(--text-muted);
}
.vs-search input:hover {
  box-shadow: 0 4px 14px rgba(80,66,45,0.10);
}
.vs-search input:focus {
  border-color: var(--lohas-brand);
  box-shadow: 0 4px 14px rgba(80,66,45,0.15);
}
.vs-search i {
  position: absolute;
  top: 50%;
  left: 20px;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 14px;
}

/* === 類別列 (icon + 文字 + 底線 active) === */
.vs-cats {
  display: flex;
  gap: 28px;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  padding: 0 2px;
  margin: 0 -2px;
}
.vs-cats::-webkit-scrollbar { display: none; }

.vs-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  background: none;
  border: 0;
  border-bottom: 2px solid transparent;
  padding: 4px 4px 14px;
  cursor: pointer;
  color: var(--text-muted);
  font-family: inherit;
  flex-shrink: 0;
  transition: color 0.15s, border-color 0.15s, opacity 0.15s;
  opacity: 0.85;
}
.vs-chip:hover {
  color: var(--text-main);
  opacity: 1;
}
.vs-chip.is-active {
  color: var(--text-main);
  border-bottom-color: var(--lohas-brand);
  opacity: 1;
}
.vs-chip i {
  font-size: 22px;
}
.vs-chip span {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.3px;
  white-space: nowrap;
}

/* ===== Layout (左卡列 / 右地圖) ===== */
.vs-layout {
  display: flex;
  height: calc(100vh - 70px - 138px);
  min-height: 600px;
}

/* ===== 左：商店街店家列表 ===== */
.vs-list-panel {
  flex: 0 0 58%;
  overflow-y: auto;
  padding: 28px 32px 80px;
  background: #fff;
}
.vs-list-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 22px;
  gap: 16px;
}
.vs-list-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-main);
  letter-spacing: -0.3px;
  margin-bottom: 4px;
}
.vs-list-sub {
  font-size: 13px;
  color: var(--text-sub);
  letter-spacing: 0.2px;
}
.vs-sort {
  background: none;
  border: 0;
  font-family: inherit;
  font-size: 13px;
  color: var(--text-sub);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 0;
  white-space: nowrap;
}
.vs-sort:hover { color: var(--text-main); }

.vs-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 24px 16px;
}
.vs-loading {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
  font-size: 14px;
  letter-spacing: 1px;
}

/* === 單一店家卡(漸層 + 中央 logo + 評分浮層) === */
.vs-place {
  cursor: pointer;
  transition: transform 0.2s;
}
.vs-place:hover { transform: translateY(-3px); }
.vs-place.is-active .vs-place-img {
  outline: 2px solid var(--lohas-brand);
  outline-offset: 2px;
}

.vs-place-img {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #CDBEA2, #765F4A);
}
.vs-place-img::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0) 60%, rgba(0,0,0,0.18) 100%);
  pointer-events: none;
}

/* 中央 logo */
.vs-place-img img {
  position: relative;
  z-index: 1;
  max-width: 62%;
  max-height: 62%;
  object-fit: contain;
  filter: drop-shadow(0 4px 14px rgba(0,0,0,0.18));
}
/* 沒 logo 時,顯示類別 icon 大字 */
.vs-place-img .vs-place-cat-icon {
  position: relative;
  z-index: 1;
  font-size: 56px;
  color: rgba(255,255,255,0.85);
  filter: drop-shadow(0 4px 14px rgba(0,0,0,0.2));
}

/* 漸層色組 (8 種大地色,依索引循環) */
.vs-place.p1 .vs-place-img { background: linear-gradient(135deg, #CDBEA2, #765F4A); }
.vs-place.p2 .vs-place-img { background: linear-gradient(135deg, #D6C8AC, #8B6F4E); }
.vs-place.p3 .vs-place-img { background: linear-gradient(135deg, #C4B59A, #6E5A40); }
.vs-place.p4 .vs-place-img { background: linear-gradient(135deg, #B8A082, #5D4B33); }
.vs-place.p5 .vs-place-img { background: linear-gradient(135deg, #DCC9AC, #927A56); }
.vs-place.p6 .vs-place-img { background: linear-gradient(135deg, #C9B695, #735C3F); }
.vs-place.p7 .vs-place-img { background: linear-gradient(135deg, #BCA88A, #5F4E36); }
.vs-place.p8 .vs-place-img { background: linear-gradient(135deg, #D2C0A0, #826A48); }

/* 愛心 (浮層) */
.vs-place-fav {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(80,66,45,0.5);
  border: 0;
  cursor: pointer;
  font-size: 13px;
  transition: all 0.15s;
}
.vs-place-fav:hover {
  background: #fff;
  transform: scale(1.08);
}
.vs-place-fav.is-on { color: var(--favorite); }

/* 類別 badge (浮層,左上) */
.vs-place-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  background: rgba(255,255,255,0.92);
  color: var(--lohas-brand);
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--r-pill);
  letter-spacing: 0.5px;
}

/* 卡片文字區 */
.vs-place-info {
  padding: 0 2px;
}
.vs-place-row1 {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 2px;
}
.vs-place-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.35;
  letter-spacing: 0.2px;
}
.vs-place-rating {
  font-size: 13px;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}
.vs-place-rating i {
  font-size: 11px;
  color: var(--lohas-brand);
}
.vs-place-intro {
  font-size: 13px;
  color: var(--text-sub);
  line-height: 1.5;
  margin-top: 4px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.vs-place-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
  font-size: 12px;
  color: var(--text-sub);
  flex-wrap: wrap;
}
.vs-place-meta > span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.vs-place-meta i { font-size: 10px; color: var(--text-muted); }
.vs-place-dist {
  color: var(--lohas-brand);
  font-weight: 500;
}

/* ===== 右：地圖 ===== */
.vs-map-panel {
  flex: 1;
  position: relative;
  background: var(--bg-soft);
}
#vs-map-canvas {
  position: absolute;
  inset: 0;
  z-index: 1;
}

/* === LOHAS 門市 pin (膠囊樣式) === */
.vs-store-pin-wrap {
  background: none !important;
  border: 0 !important;
}
.vs-store-pin {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #fff;
  border: 1px solid var(--lohas-bd);
  color: var(--text-main);
  padding: 6px 12px;
  border-radius: var(--r-pill);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.3px;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.15s;
  box-shadow: 0 2px 8px rgba(80,66,45,0.18);
  user-select: none;
}
.vs-store-pin:hover {
  transform: scale(1.06);
  z-index: 1000 !important;
  box-shadow: 0 6px 18px rgba(80,66,45,0.28);
}
.vs-store-pin i {
  font-size: 11px;
  color: var(--lohas-brand);
}
.vs-store-pin.is-highlight {
  background: var(--lohas-brand);
  border-color: var(--lohas-brand);
  color: #fff;
}
.vs-store-pin.is-highlight i { color: var(--collab-gold, #D4B068); }

/* 地圖工具列 (右上,獨立按鈕組) */
.vs-map-tools {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 400;
  display: flex;
  flex-direction: column;
  gap: 0;
  background: #fff;
  border: 1px solid var(--lohas-bd);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(80,66,45,0.12);
}
.vs-map-tool {
  width: 40px;
  height: 40px;
  background: #fff;
  border: 0;
  border-bottom: 1px solid var(--lohas-bd);
  color: var(--text-main);
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}
.vs-map-tool:last-child { border-bottom: 0; }
.vs-map-tool:hover { background: var(--bg-soft); }

/* 地圖底部計數 */
.vs-map-count {
  position: absolute;
  left: 16px;
  bottom: 16px;
  z-index: 400;
  background: #fff;
  padding: 10px 16px;
  border-radius: var(--r-pill);
  font-size: 12px;
  color: var(--text-sub);
  border: 1px solid var(--lohas-bd);
  box-shadow: 0 4px 14px rgba(80,66,45,0.10);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  letter-spacing: 0.3px;
}
.vs-map-count i {
  font-size: 8px;
  color: var(--lohas-brand);
}
.vs-map-count b {
  color: var(--text-main);
  font-weight: 600;
}

/* === 點 pin 後的門市彈出卡 (版本 B: 白底 + 縮圖列表) === */
.vs-pin-card {
  position: absolute;
  right: 16px;
  top: 16px;
  z-index: 500;
  background: #fff;
  width: 300px;
  max-height: calc(100% - 32px);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(80, 66, 45, 0.20);
  border: 0.5px solid var(--lohas-bd);
  display: none;
  flex-direction: column;
}
.vs-pin-card.is-show { display: flex; }

/* Header: icon + 名稱 + 地址 + 關閉 */
.vs-pin-card-h {
  padding: 16px 18px 14px;
  border-bottom: 0.5px solid var(--lohas-bd);
  display: flex;
  align-items: flex-start;
  gap: 12px;
  position: relative;
  flex-shrink: 0;
}
.vs-pin-card-h-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: linear-gradient(135deg, #CDBEA2, #765F4A);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}
.vs-pin-card-h-text {
  min-width: 0;
  flex: 1;
  padding-right: 28px;
}
.vs-pin-card-h-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-main);
  letter-spacing: -0.2px;
  margin-bottom: 3px;
}
.vs-pin-card-h-addr {
  font-size: 11px;
  color: var(--text-sub);
  letter-spacing: 0.3px;
  line-height: 1.5;
}
.vs-pin-card-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--bg-soft);
  color: var(--text-main);
  border: 0;
  cursor: pointer;
  font-size: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}
.vs-pin-card-close:hover { background: var(--lohas-bd); }

/* Stat 區 */
.vs-pin-card-stat {
  padding: 12px 18px;
  background: var(--bg-soft);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.vs-pin-card-stat-num {
  font-size: 22px;
  font-weight: 700;
  color: var(--lohas-brand);
  line-height: 1;
}
.vs-pin-card-stat-lab {
  font-size: 12px;
  color: var(--text-sub);
  letter-spacing: 0.3px;
}
.vs-pin-card-stat-lab b {
  color: var(--lohas-brand);
  font-weight: 600;
}

/* 商家列表 */
.vs-pin-card-list {
  list-style: none;
  margin: 0;
  padding: 6px 0;
  overflow-y: auto;
  flex: 1;
}
.vs-pin-card-li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 18px;
  cursor: pointer;
  transition: background 0.1s;
}
.vs-pin-card-li:hover { background: var(--bg-soft); }
.vs-pin-card-li-l {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}
.vs-pin-card-li-thumb {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  flex-shrink: 0;
}
/* 縮圖漸層 (沿用 8 色系統) */
.vs-pin-card-li-thumb.p1 { background: linear-gradient(135deg, #CDBEA2, #765F4A); }
.vs-pin-card-li-thumb.p2 { background: linear-gradient(135deg, #D6C8AC, #8B6F4E); }
.vs-pin-card-li-thumb.p3 { background: linear-gradient(135deg, #C4B59A, #6E5A40); }
.vs-pin-card-li-thumb.p4 { background: linear-gradient(135deg, #B8A082, #5D4B33); }
.vs-pin-card-li-thumb.p5 { background: linear-gradient(135deg, #DCC9AC, #927A56); }
.vs-pin-card-li-thumb.p6 { background: linear-gradient(135deg, #C9B695, #735C3F); }
.vs-pin-card-li-thumb.p7 { background: linear-gradient(135deg, #BCA88A, #5F4E36); }
.vs-pin-card-li-thumb.p8 { background: linear-gradient(135deg, #D2C0A0, #826A48); }

.vs-pin-card-li-text { min-width: 0; }
.vs-pin-card-li-name {
  font-size: 13px;
  color: var(--text-main);
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.vs-pin-card-li-cat {
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 0.3px;
  margin-top: 2px;
}
.vs-pin-card-li-arr {
  color: var(--text-muted);
  font-size: 10px;
  flex-shrink: 0;
}

/* Footer: 查看全部 */
.vs-pin-card-foot {
  padding: 10px 18px 14px;
  font-size: 12px;
  color: var(--lohas-brand);
  text-align: center;
  font-weight: 500;
  letter-spacing: 0.5px;
  cursor: pointer;
  border-top: 0.5px solid var(--lohas-bd);
  flex-shrink: 0;
  background: #fff;
}
.vs-pin-card-foot:hover { background: var(--bg-soft); }
.vs-pin-card-foot i {
  font-size: 9px;
  margin-left: 4px;
}

/* ===== 手機底部 TAB (樣式抄電腦版 .vs-view-switch) ===== */
.vs-view-tabs {
  display: none;
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 900;
  background: var(--bg-soft);
  border-radius: var(--r-pill);
  padding: 3px;
  box-shadow: 0 8px 24px rgba(80, 66, 45, 0.18);
}
.vs-view-tab {
  background: none;
  border: 0;
  font-family: inherit;
  font-size: 12px;
  font-weight: 500;
  padding: 7px 14px;
  border-radius: var(--r-pill);
  cursor: pointer;
  color: var(--text-sub);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  letter-spacing: 0.3px;
  transition: all 0.15s;
}
.vs-view-tab:hover {
  color: var(--text-main);
}
.vs-view-tab.is-active {
  background: #fff;
  color: var(--lohas-brand);
  box-shadow: 0 1px 3px rgba(80, 66, 45, 0.12);
}
.vs-view-tab i { font-size: 11px; }

/* ===== RWD: 平板 ===== */
@media (max-width: 1024px) {
  .vs-list-panel { flex: 0 0 50%; }
  .vs-list { grid-template-columns: repeat(2, 1fr); }
  .vs-search { flex: 0 1 280px; }
}

/* ===== RWD: 手機 ===== */
@media (max-width: 768px) {
  .vs-shell { margin-top: 60px; }
  .vs-subheader { top: 60px; }
  .vs-subheader-inner { padding: 14px 16px 0; gap: 14px; }
  .vs-subheader-title { font-size: 12px; gap: 6px; }
  .vs-subheader-title .accent { font-size: 17px; font-weight: 700; }
  .vs-subheader-desc { display: none; }  /* 手機版隱藏 inline 描述,用 KPI 取代 */

  /* 手機版啟用 KPI 三指標 */
  .vs-kpi {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }

  .vs-search {
    flex: 1 1 100%;
    margin-left: 0;
    order: 99;
  }
  .vs-search input { height: 40px; }
  .vs-cats { gap: 20px; }
  .vs-chip i { font-size: 20px; }

  /* === 手機版 layout: browse / map 各自全屏 === */
  .vs-layout[data-view="browse"] {
    display: block;
    height: auto;
    min-height: calc(100vh - 60px - 138px);
  }
  .vs-layout[data-view="map"] {
    display: block;
    height: calc(100vh - 60px - 138px);
    min-height: 500px;
  }

  /* 地圖 view 內部:單欄,先列表後地圖切換用 */
  .vs-map-view {
    display: flex;
    flex-direction: column;
    height: 100%;
    width: 100%;
  }
  .vs-list-panel,
  .vs-map-panel {
    flex: 1;
    width: 100%;
    height: 100%;
  }
  /* 手機地圖 view 直接顯示地圖 (預設,因為使用者切到地圖通常想看地圖) */
  .vs-map-view .vs-list-panel { display: none; }

  .vs-list { grid-template-columns: repeat(2, 1fr); gap: 16px 12px; }
  .vs-list-title { font-size: 18px; }
  .vs-place-name { font-size: 14px; }

  /* 底部 tabs 顯示 */
  .vs-view-tabs { display: block; }

  .vs-pin-card {
    right: 12px;
    left: 12px;
    width: auto;
  }
}

/* =============================================
   View Switch (browse / map)
   ============================================= */
.vs-view-switch {
  display: inline-flex;
  background: var(--bg-soft);
  border-radius: var(--r-pill);
  padding: 3px;
  margin-left: 10px;
  flex-shrink: 0;
}
.vs-view-btn {
  background: none;
  border: 0;
  font-family: inherit;
  font-size: 12px;
  font-weight: 500;
  padding: 7px 14px;
  border-radius: var(--r-pill);
  cursor: pointer;
  color: var(--text-sub);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  letter-spacing: 0.3px;
  transition: all 0.15s;
}
.vs-view-btn:hover {
  color: var(--text-main);
}
.vs-view-btn.is-active {
  background: #fff;
  color: var(--lohas-brand);
  box-shadow: 0 1px 3px rgba(80, 66, 45, 0.12);
}
.vs-view-btn i { font-size: 11px; }

/* === Layout view 切換邏輯 === */
.vs-layout[data-view="browse"] .vs-map-view { display: none; }
.vs-layout[data-view="map"]    .vs-browse   { display: none; }
.vs-layout[data-view="browse"] {
  display: block;
  height: auto;
  min-height: calc(100vh - 70px - 138px);
}
.vs-layout[data-view="map"] {
  display: block;
  height: calc(100vh - 70px - 138px);
  min-height: 600px;
}
.vs-map-view {
  display: flex;
  width: 100%;
  height: 100%;
}

/* =============================================
   Browse View (列表瀏覽,類別分區 + 橫向滑卡)
   ============================================= */
.vs-browse {
  background: #fff;
  padding-bottom: 80px;
}
.vs-browse-inner {
  max-width: 1480px;
  margin: 0 auto;
  padding: 28px 32px;
}
.vs-browse-loading {
  padding: 80px 20px;
  text-align: center;
}

/* 單一類別 section */
.vs-sec {
  margin-bottom: 44px;
}
.vs-sec-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 16px;
  padding: 0 2px;
  gap: 16px;
}
.vs-sec-l {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}
.vs-sec-eb {
  font-size: 11px;
  letter-spacing: 2.5px;
  color: var(--text-muted);
  font-weight: 500;
}
.vs-sec-h {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-main);
  letter-spacing: -0.2px;
}
.vs-sec-cnt {
  font-size: 13px;
  color: var(--text-sub);
}
.vs-sec-more {
  font-size: 13px;
  color: var(--lohas-brand);
  font-weight: 500;
  cursor: pointer;
  background: none;
  border: 0;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 8px 0;
  white-space: nowrap;
}
.vs-sec-more:hover { color: var(--lohas-hover); }
.vs-sec-more i { font-size: 11px; }

/* 橫向滑卡列 (全部模式) */
.vs-scroller {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  padding: 4px 2px 12px;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: var(--lohas-light) transparent;
}
.vs-scroller::-webkit-scrollbar { height: 6px; }
.vs-scroller::-webkit-scrollbar-thumb {
  background: var(--lohas-light);
  border-radius: var(--r-pill);
}
.vs-scroller::-webkit-scrollbar-track { background: transparent; }

.vs-scroller .vs-place {
  flex: 0 0 200px;
  scroll-snap-align: start;
}

/* 大網格 (單一類別模式) */
.vs-browse-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 24px 16px;
}

/* 「看更多分類」按鈕 (全部模式下方) */
.vs-browse-more {
  display: block;
  margin: 24px auto 0;
  background: none;
  border: 1px solid var(--lohas-bd);
  color: var(--lohas-brand);
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  padding: 12px 28px;
  border-radius: var(--r-pill);
  cursor: pointer;
  letter-spacing: 0.5px;
  transition: all 0.15s;
}
.vs-browse-more:hover {
  background: var(--lohas-brand);
  color: #fff;
  border-color: var(--lohas-brand);
}

/* =============================================
   詳情浮層 (點卡片開啟)
   ============================================= */
.vs-detail-ovl {
  position: fixed;
  inset: 0;
  background: rgba(45, 37, 32, 0.55);
  z-index: var(--z-modal);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  transition: opacity 0.2s;
}
.vs-detail-ovl.is-show {
  display: flex;
  opacity: 1;
}
.vs-detail-modal {
  background: #fff;
  border-radius: var(--r-lg);
  width: 100%;
  max-width: 540px;
  max-height: 90vh;
  overflow: hidden;
  box-shadow: var(--sh-modal);
  display: flex;
  flex-direction: column;
}
.vs-detail-img {
  position: relative;
  width: 100%;
  height: 200px;
  background: linear-gradient(135deg, #CDBEA2, #765F4A);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.vs-detail-img img {
  max-width: 60%;
  max-height: 75%;
  object-fit: contain;
  filter: drop-shadow(0 4px 14px rgba(0, 0, 0, 0.2));
}
.vs-detail-img .vs-detail-cat-icon {
  font-size: 64px;
  color: rgba(255, 255, 255, 0.85);
  filter: drop-shadow(0 4px 14px rgba(0, 0, 0, 0.2));
}
.vs-detail-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  border: 0;
  cursor: pointer;
  font-size: 14px;
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}
.vs-detail-close:hover {
  background: #fff;
  transform: scale(1.05);
}
.vs-detail-badge {
  position: absolute;
  top: 16px;
  left: 16px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--lohas-brand);
  font-size: 12px;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: var(--r-pill);
  letter-spacing: 0.5px;
}
.vs-detail-body {
  padding: 24px 28px 28px;
  overflow-y: auto;
}
.vs-detail-name {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 4px;
  letter-spacing: -0.2px;
}
.vs-detail-code {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 16px;
  letter-spacing: 0.5px;
}
.vs-detail-intro {
  font-size: 14px;
  color: var(--text-sub);
  line-height: 1.7;
  margin-bottom: 20px;
  white-space: pre-line;
}
.vs-detail-stores {
  border-top: 1px solid var(--lohas-bd);
  padding-top: 18px;
}
.vs-detail-stores-title {
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 1.5px;
  margin-bottom: 10px;
  font-weight: 500;
}
.vs-detail-stores-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}
.vs-detail-store-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-soft);
  color: var(--text-main);
  font-size: 13px;
  padding: 6px 12px;
  border-radius: var(--r-pill);
  border: 1px solid var(--lohas-bd);
}
.vs-detail-store-chip i {
  font-size: 10px;
  color: var(--lohas-brand);
}
.vs-detail-all-stores {
  background: var(--bg-soft);
  color: var(--text-sub);
  font-size: 13px;
  padding: 10px 16px;
  border-radius: var(--r-md);
  text-align: center;
  letter-spacing: 0.3px;
  margin-bottom: 20px;
}
.vs-detail-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.vs-detail-btn {
  flex: 1;
  min-width: 140px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: var(--r-pill);
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.5px;
  cursor: pointer;
  text-decoration: none;
  border: 1px solid transparent;
  transition: all 0.15s;
}
.vs-detail-btn--solid {
  background: var(--lohas-brand);
  color: #fff;
  border-color: var(--lohas-brand);
}
.vs-detail-btn--solid:hover {
  background: var(--lohas-hover);
  border-color: var(--lohas-hover);
}
.vs-detail-btn--ghost {
  background: transparent;
  color: var(--lohas-brand);
  border-color: var(--lohas-brand);
}
.vs-detail-btn--ghost:hover {
  background: var(--lohas-brand);
  color: #fff;
}

/* =============================================
   RWD: 手機版調整
   ============================================= */
@media (max-width: 768px) {
  .vs-view-switch { display: none; }  /* 手機用底部 tabs */

  .vs-browse-inner { padding: 20px 16px; }
  .vs-sec { margin-bottom: 32px; }
  .vs-sec-h { font-size: 17px; }
  .vs-scroller .vs-place { flex: 0 0 150px; }
  .vs-browse-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px 12px;
  }

  .vs-detail-ovl { align-items: flex-end; padding: 0; }
  .vs-detail-modal {
    max-width: 100%;
    max-height: 92vh;
    border-radius: var(--r-lg) var(--r-lg) 0 0;
  }
  .vs-detail-img { height: 160px; }
  .vs-detail-body { padding: 20px 20px 24px; }
  .vs-detail-name { font-size: 18px; }
}


/* =============================================
   浮動快速導引按鈕 (滾動 240px 後浮現)
   參考 market.html 同類元件,改用 vs- namespace
   ============================================= */
.vs-scroll-to-cta {
  position: fixed;
  right: 24px;
  bottom: 32px;
  z-index: 150;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--lohas-brand);
  color: #fff;
  padding: 12px 18px 12px 16px;
  border-radius: var(--r-pill);
  text-decoration: none;
  font-size: 12px;
  letter-spacing: 1px;
  font-weight: 600;
  box-shadow: 0 8px 24px rgba(80, 66, 45, 0.25);
  cursor: pointer;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease, background 0.2s ease;
}
.vs-scroll-to-cta.is-show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.vs-scroll-to-cta:hover {
  background: var(--lohas-hover);
  transform: translateY(-2px);
}
.vs-scroll-to-cta i {
  font-size: 11px;
  /* 上下擺動,引導下捲視覺 */
  animation: vsScrollHint 1.8s ease-in-out infinite;
}
.vs-scroll-label {
  white-space: nowrap;
}

/* 已捲到 CTA 後,變成「回到頂部」狀態 */
.vs-scroll-to-cta.is-at-bottom i {
  transform: rotate(180deg);
  animation: none;
}

@keyframes vsScrollHint {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(4px); }
}

/* 手機:縮成圓形 FAB, 隱藏文字, 避開底部 TAB */
@media (max-width: 768px) {
  .vs-scroll-to-cta {
    right: 16px;
    bottom: 80px; /* 避開底部 vs-view-tabs */
    width: 44px;
    height: 44px;
    padding: 0;
    border-radius: 50%;
    justify-content: center;
  }
  .vs-scroll-label { display: none; }
  .vs-scroll-to-cta i { font-size: 14px; }
}
