/* （2026-07-03 死規則清除：selector-item／box-style-selector，markup 已於 07-02 移除） */

/* 3. 按鈕整形：強制正圓 */
.qty-btn {
  /* 強制固定尺寸，這是圓形的關鍵 */
  width: 32px !important; 
  height: 32px !important;
  min-width: 32px; /* 防止被擠壓 */
  
  /* 移除瀏覽器預設樣式 */
  padding: 0;
  margin: 0;
  border: 1px solid #dcdcdc; /* 淺灰色細邊框 */
  border-radius: 50%; /* 50% 才是正圓 */
  background: #fff;
  
  /* 內容置中 (讓 + - 號絕對置中) */
  display: flex;
  align-items: center;
  justify-content: center;
  
  /* 文字樣式 */
  color: #5a665e;
  font-size: 18px; /* 符號大小 */
  font-weight: 400;
  line-height: 1;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 5px rgba(0,0,0,0.03); /* 極淡的陰影增加立體感 */
}

.qty-btn:hover {
  border-color: #8fb79c;
  color: #2f4b3c;
  background: #f4f8f6;
}

.qty-btn:active {
  transform: scale(0.92); /* 點擊時微縮 */
}

/* =========================================
   3. 禮盒款式選擇按鈕 (Red/Gold Selector)
   ========================================= */
/* 這是 JS 產生的按鈕樣式，請直接加在 CSS 檔案裡 */


/* C4：[style*=…] 攻擊舊世代 inline style 的三個規則已移除（JS 早已改 class 控制）*/

/* 定義動畫 */
@keyframes fadeInDown {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}


/* =========================================
   2026 Giftbox purchase flow redesign
   ========================================= */
#giftboxCard.hh-giftbox-section {
  width: min(1120px, calc(100% - 32px));
  margin: clamp(32px, 6vw, 72px) auto;
  padding: 0;
  background: transparent;
}

/* =========================================
   Responsive overrides
   ========================================= */
@media (max-width: 640px) {
  #giftboxCard.hh-giftbox-section {
    width: 100%;
    margin: 32px 0;
  }
}

/* ============================================================
   Giftbox Redesign 2.0 — gb-* components
   ============================================================ */

/* ── Hero ─────────────────────────────────────────────────── */
.gb-hero {
  display: flex;
  align-items: flex-end;
  min-height: 72vw;
  max-height: 520px;
  background: url('/images/gb-hero-bg.webp') center center / cover no-repeat;
  padding: 36px 28px;
  position: relative;
  overflow: hidden;
}

/* dark gradient overlay so text stays readable */
.gb-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  /* 2026-08-05 可讀性收斂：中段 0.35→0.55、頂段 0.05→0.18——
     照片是淺金禮盒，標題/副標落在中段，原強度白字實測近乎消失 */
  background: linear-gradient(
    to top,
    rgba(10, 20, 10, 0.78) 0%,
    rgba(10, 20, 10, 0.55) 55%,
    rgba(10, 20, 10, 0.18) 100%
  );
  pointer-events: none;
}

.gb-hero-content {
  position: relative;
  z-index: 1;
  max-width: 420px;
}

.gb-hero-eyebrow {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.92);
  text-transform: uppercase;
  margin: 0 0 10px;
}

.gb-hero-title {
  font-size: clamp(24px, 6vw, 36px);
  font-weight: 800;
  color: #fff;
  line-height: 1.15;
  margin: 0 0 8px;
}

.gb-hero-subtitle {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.95);
  margin: 0 0 22px;
  line-height: 1.6;
}

/* .gb-hero-cta 已於 2026-08-06 隨 hero C 整顆移除（實心白膠囊＋與選擇架構打架） */

.gb-hero-tags {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.88);
  margin: 0;
  letter-spacing: 0.02em;
}

.gb-hero-media {
  display: none;
}

/* ── 三步驟 ───────────────────────────────────────────────── */
.gb-steps-section {
  background: #fff;
  margin: 0;
  padding: 32px 24px;
  border-bottom: 1px solid #efefef;
}


.gb-steps {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 0;
}

.gb-step-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 120px;
}



.gb-step-name {
  font-size: 13px;
  font-weight: 700;
  color: #1e2e1c;
  margin: 0 0 3px;
}

.gb-step-desc {
  font-size: 12px; /* 11 → 12（中文小字提階） */
  color: #5b6e56; /* #7a907a 對比 ~3.6 → ≥5 */
  margin: 0;
  line-height: 1.4;
}

.gb-step-line {
  flex: 1;
  height: 2px;
  border-top: 2px dashed #c8d8c4;
  margin-top: 23px;
  max-width: 40px;
  align-self: flex-start;
}

/* ── 選茶 Section ─────────────────────────────────────────── */
.gb-select-section {
  padding: 28px 24px 20px;
  background: #fafaf8;
  border-top: 1px solid #efefef;
}

.gb-select-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}


.gb-select-title {
  font-size: 20px;
  font-weight: 800;
  color: #1e2e1c;
  margin: 0 0 3px;
}

.gb-select-sub {
  font-size: 12px;
  color: #7a907a;
  margin: 0;
}

.gb-same-btn {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 8px 13px;
  border: 1.5px solid #4a6e3f;
  border-radius: 99px;
  background: transparent;
  color: #3d6142;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.18s, color 0.18s;
  margin-top: 4px;
}

.gb-same-btn:hover {
  background: #3d6142;
  color: #fff;
}

/* STEP 02 collapse */
.gb-step2-collapsed,
.gb-step3-collapsed {
  display: none;
}

#gbStep2:not(.gb-step2-collapsed),
#gbStep3:not(.gb-step3-collapsed) {
  animation: gbFadeSlideIn 0.3s ease both;
}

@keyframes gbFadeSlideIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── 確認卡 ────────────────────────────────────────────────── */
.gb-confirm-card {
  margin-top: 20px;
  background: #f7f9f5;
  border: 1px solid #e0e8d8;
  border-radius: 16px;
  padding: 20px;
}

.gb-confirm-title {
  font-size: 14px;
  font-weight: 700;
  color: #2d4a22;
  margin: 0 0 14px;
}

.gb-confirm-rows { display: flex; flex-direction: column; gap: 10px; }

.gb-confirm-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.gb-confirm-edit-btn {
  flex-shrink: 0;
  margin-left: auto;
  background: none;
  border: none;
  padding: 2px 4px;
  cursor: pointer;
  color: #a0b89a;
  font-size: 15px;
  line-height: 1;
  transition: color 0.15s;
}
.gb-confirm-edit-btn:hover { color: #3d6142; }

.gb-confirm-row-label {
  font-size: 11px;
  color: #8a9e80;
  font-weight: 600;
  flex-shrink: 0;
  padding-top: 2px;
  width: 52px;
}

.gb-confirm-row-content { flex: 1; min-width: 0; }

.gb-confirm-row-name {
  font-size: 13px;
  font-weight: 600;
  color: #2a3a28;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}

.gb-confirm-row-price {
  font-size: 12px;
  color: #5a7a50;
  display: block;
  margin-top: 1px;
}

.gb-confirm-divider {
  height: 1px;
  background: #d8e4d0;
  margin: 14px 0;
}

/* 🎁 檔期禮盒折扣（2026-08-13）：折扣列＋合計的原價刪除線。
   ⚠️ 折後價只是顯示——購物車存的仍是原價，實際折抵由後端在結帳時算。 */
.gb-confirm-row-promo {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 8px;
  padding: 6px 10px;
  border-radius: 8px;
  background: #f6ecdc;
  color: #8a5a1e;
  font-size: 12px;
  font-weight: 700;
}

.gb-confirm-row-promo .gb-promo-off {
  white-space: nowrap;
}

.gb-confirm-total-was {
  font-size: 13px;
  font-weight: 600;
  color: #8a9e80;
  text-decoration: line-through;
  margin-right: 6px;
}

.gb-confirm-total-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  font-size: 13px;
  color: #4a6e3f;
}

.gb-confirm-total-row strong {
  font-size: 18px;
  font-weight: 800;
  color: #2d4a22;
}

.gb-confirm-qty-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.gb-confirm-qty-label {
  font-size: 13px;
  color: #4a6e3f;
  font-weight: 600;
}

.gb-qty-ctrl {
  display: flex;
  align-items: center;
  gap: 0;
  border: 1.5px solid #c8d8c0;
  border-radius: 99px;
  overflow: hidden;
}

.gb-qty-btn {
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  font-size: 18px;
  color: #3d6142;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}

.gb-qty-btn:hover { background: #eef4ea; }

.gb-qty-val {
  min-width: 32px;
  text-align: center;
  font-size: 15px;
  font-weight: 700;
  color: #2d4a22;
}

.gb-confirm-cta {
  width: 100%;
  padding: 14px;
  background: #3d6142;
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background 0.2s, transform 0.15s;
}

.gb-confirm-cta:hover { background: #2d4a30; }
.gb-confirm-cta:active { transform: scale(0.98); }
.gb-confirm-cta i { font-size: 18px; }

/* ── 搜尋框 ───────────────────────────────────────────────── */
.gb-search-row {
  margin-bottom: 10px;
}

/* 極簡底線搜尋 */
.gb-search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  border: none;
  border-bottom: 1.5px solid #d0deca;
  border-radius: 0;
  padding: 6px 0;
  transition: border-color 0.2s;
}
.gb-search-box:focus-within {
  border-color: #3d6142;
}
.gb-search-box i {
  color: #a0b89a;
  font-size: 14px;
  flex-shrink: 0;
}
.gb-search-input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 14px;
  color: #1e2e1c;
  border-radius: 0;
  -webkit-appearance: none;
  appearance: none;
}
/* Override store.css .section input[type="text"] which applies border-radius/background */
.hh-giftbox-section .gb-search-row .gb-search-input {
  border-radius: 0 !important;
  border: none !important;
  background: transparent !important;
  box-shadow: none;
  height: auto;
  padding: 0 !important;
}
.gb-search-input::placeholder {
  color: #b8cbb4;
}

/* 速選展開列表 */
.gb-quick-select-row {
  margin: 10px 0 12px;
}
.gb-quick-select-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  color: #4a6e3f;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  font-weight: 500;
  transition: color 0.15s;
}
.gb-quick-select-btn:hover { color: #2d4a30; }
.gb-quick-select-btn i {
  font-size: 12px;
  transition: transform 0.2s;
}
.gb-quick-select-btn.is-open i { transform: rotate(180deg); }

.gb-quick-list {
  display: none;
  margin-top: 8px;
  background: #fff;
  border: 1px solid #dce8d6;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}
.gb-quick-list.is-open { display: block; }
.gb-quick-list-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 16px;
  font-size: 13px;
  color: #2a3e2a;
  cursor: pointer;
  border-bottom: 1px solid #f0f5ee;
  transition: background 0.12s;
}
.gb-quick-list-item:last-child { border-bottom: none; }
.gb-quick-list-item:hover { background: #f5faf3; }
.gb-quick-list-item.is-selected {
  background: #eef7ea;
  color: #3d6142;
  font-weight: 600;
}
.gb-quick-list-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.gb-quick-list-price {
  font-size: 12px;
  color: #7a9a7a;
  margin-left: 8px;
  flex-shrink: 0;
}
.gb-quick-list-item.is-selected .gb-quick-list-price { color: #3d6142; }

/* 售完狀態 */
.gb-quick-list-item.is-soldout {
  cursor: default;
  color: #b0bdb0;
}
.gb-quick-list-item.is-soldout:hover { background: transparent; }
.gb-quick-list-item.is-soldout .gb-quick-list-name { color: #b8c4b8; }
.gb-quick-soldout-badge {
  flex-shrink: 0;
  margin-left: 8px;
  font-size: 10px;
  font-weight: 600;
  color: #b0a8a4;
  background: #f3efed;
  border: 1px solid #e6deda;
  border-radius: 5px;
  padding: 2px 7px;
  letter-spacing: 0.5px;
}

.gb-search-clear {
  background: none;
  border: none;
  color: #86a87c;
  cursor: pointer;
  padding: 0;
  display: flex;
  font-size: 14px;
}

/* ── 茶款卡片 ──────────────────────────────────────────────── */
.gb-tea-cards {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 8px;
  scrollbar-width: none;
}

.gb-tea-cards::-webkit-scrollbar {
  display: none;
}

.gb-tea-card {
  flex: 0 0 148px;
  scroll-snap-align: start;
  background: #fff;
  border-radius: 16px;
  border: 2px solid transparent;
  overflow: hidden;
  cursor: pointer;
  position: relative;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
  box-shadow: 0 2px 10px rgba(0,0,0,0.07);
}

.gb-tea-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0,0,0,0.11);
}

.gb-tea-card.is-selected {
  border-color: #3d6142;
}

.gb-tea-card.is-unavailable {
  opacity: 0.45;
  cursor: not-allowed;
}

.gb-card-check-circle {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #3d6142;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  opacity: 0;
  transform: scale(0.6);
  transition: opacity 0.2s, transform 0.2s;
  z-index: 2;
}

.gb-tea-card.is-selected .gb-card-check-circle {
  opacity: 1;
  transform: scale(1);
}

.gb-card-img-wrap {
  width: 100%;
  height: 110px;
  overflow: hidden;
  background: #eef4ea;
}

.gb-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gb-card-img-ph {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: #86a87c;
}

.gb-card-body {
  padding: 10px 10px 12px;
}

.gb-card-name {
  font-size: 13px;
  font-weight: 700;
  color: #1e2e1c;
  margin: 0 0 4px;
  line-height: 1.3;
}

.gb-card-desc {
  font-size: 11px;
  color: #7a907a;
  margin: 0;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ── 空狀態 ───────────────────────────────────────────────── */
.gb-empty-state {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 24px 0;
  color: #86a87c;
  font-size: 13px;
}
/* CSS display: flex 會覆蓋 HTML hidden attribute，需要顯式補回 */
.gb-empty-state[hidden] { display: none !important; }

/* 卡片價格 */
.gb-card-price {
  margin: 5px 0 0;
  font-size: 12px;
  font-weight: 700;
  color: #3d6142;
}
.gb-card-price .gb-card-price-x2 {
  font-size: 11px; /* 10 → 11（計價資訊，不能低於中文小字底線） */
  font-weight: 600;
  color: #8a5b16; /* 橘 #e67e22 對比 2.85＋脫離品牌盤 → 深琥珀 ≥5 */
  margin-left: 3px;
}

.gb-clear-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: #8a9e80;
  background: none;
  border: 1px solid #d4ddd0;
  border-radius: 99px;
  padding: 5px 12px;
  cursor: pointer;
  transition: color 0.18s, border-color 0.18s;
  white-space: nowrap;
}

.gb-clear-btn:hover {
  color: #3d6142;
  border-color: #86a87c;
}

/* ── Product showcase ───────────────────────────────────────── */
.gb-showcase-wrap {
  margin-bottom: 20px;
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  background: #f5f0eb;
}

.gb-showcase-track {
  display: flex;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.gb-showcase-slide {
  flex: 0 0 100%;
  width: 100%;
}

.gb-showcase-slide img {
  width: 100%;
  display: block;
  aspect-ratio: 4/3;
  object-fit: cover;
}

/* 示意圖聲明（2026-07-11 業主要求）：成品展示照片下方的免責小字 */
.gb-showcase-note {
  margin: 8px 2px 0;
  font-size: 11px;
  letter-spacing: 0.04em;
  color: #75705f; /* #9a927f 對比 ~3.3 → ≥4.5（免責也要讀得到） */
  text-align: center;
}

.gb-showcase-dots {
  position: absolute;
  bottom: 10px;
  left: 0; right: 0;
  display: flex;
  justify-content: center;
  gap: 6px;
}

.gb-showcase-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255,255,255,0.5);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background 0.2s, transform 0.2s;
}

.gb-showcase-dot.active {
  background: #fff;
  transform: scale(1.3);
}

/* ── Box style selector ─────────────────────────────────────── */

.gb-box-style-btns {
  display: flex;
  gap: 10px;
}

.gb-box-style-btn {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 2px solid transparent;
  background: #f5f5f3;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}

.gb-box-style-btn.active {
  border-color: var(--btn-color, #3d5a3e);
  background: #fff;
}

.gb-box-style-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  flex-shrink: 0;
}

.gb-box-style-name {
  font-size: 12px;
  font-weight: 600;
  color: #3a3a38;
  flex: 1;
  text-align: left;
}

.gb-box-style-price {
  font-size: 11px;
  color: #8a9e80;
}

body.giftbox-page {
  padding-bottom: calc(80px + env(safe-area-inset-bottom)) !important;
  overflow-x: hidden;
  overflow-y: auto !important;
}

/* ── 推薦搭配 Section ────────────────────────────────────────── */
.gb-recommend-section {
  padding: 28px 20px 20px;
  background: #f9faf7;
  border-bottom: 1px solid #e8efe4;
}
.gb-recommend-header { margin-bottom: 14px; }
.gb-recommend-title {
  font-size: 18px;
  font-weight: 800;
  color: #1e2e1c;
  margin: 0 0 4px;
}
.gb-recommend-sub {
  font-size: 13px;
  color: #6b8c6e;
  margin: 0;
}

/* 預算 chips */
.gb-budget-chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 14px;
  -webkit-overflow-scrolling: touch;
}
.gb-budget-chips::-webkit-scrollbar { display: none; }
.gb-budget-chip {
  flex-shrink: 0;
  padding: 5px 14px;
  border-radius: 20px;
  border: 1.5px solid #c8dfc0;
  background: #fff;
  font-size: 12px;
  color: #4a6e3f;
  cursor: pointer;
  transition: all 0.15s;
}
.gb-budget-chip.active {
  background: #3d6142;
  border-color: #3d6142;
  color: #fff;
}
.gb-budget-chip:hover:not(.active) { background: #eef5ea; }

/* 推薦卡片滑動列 */
.gb-recommend-cards {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 4px;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x mandatory;
}
.gb-recommend-cards::-webkit-scrollbar { display: none; }

.gb-rec-card {
  flex: 0 0 175px;
  scroll-snap-align: start;
  background: #fff;
  border-radius: 16px;
  border: 1.5px solid #e0ead9;
  padding: 14px;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.gb-rec-card:hover {
  border-color: #3d6142;
  box-shadow: 0 4px 14px rgba(61,97,66,0.12);
}
.gb-rec-card.is-applied {
  border-color: #3d6142;
  background: #f2f8f0;
}

.gb-rec-tag {
  display: inline-block;
  align-self: flex-start;
  font-size: 10px;
  font-weight: 700;
  color: #fff;
  padding: 2px 8px;
  border-radius: 10px;
  margin-bottom: 8px;
  letter-spacing: 0.3px;
}
.gb-rec-name {
  font-size: 14px;
  font-weight: 800;
  color: #1e2e1c;
  margin: 0 0 6px;
}
.gb-rec-teas {
  font-size: 12px;
  color: #5a7a5e;
  margin: 0 0 8px;
  line-height: 1.6;
  flex: 1;
}
.gb-rec-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.gb-rec-box-label {
  font-size: 12px; /* 11 → 12 */
  color: #5b6e56; /* 對比 2.66 → ≥5 */
}
.gb-rec-price {
  font-size: 13px;
  font-weight: 700;
  color: #3d6142;
}
/* 2026-07-03 綠鈕減重：6 張推薦卡各一顆實心深綠太重 → 細金線 ghost（同精選卡語彙） */
.gb-rec-apply-btn {
  width: 100%;
  padding: 8px 0;
  border-radius: 999px;
  border: 1px solid rgba(148, 114, 62, 0.5);
  background: #fff;
  color: #2f4b3c;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s, transform 0.15s;
  letter-spacing: 0.3px;
}
.gb-rec-apply-btn:hover { background: #faf5ea; }
.gb-rec-apply-btn:active { transform: scale(0.97); }
.gb-rec-card.is-applied .gb-rec-apply-btn { background: #efe9da; border-color: rgba(148, 114, 62, 0.3); color: #8a8375; }

.gb-rec-empty {
  padding: 20px 0;
  color: #5b6e56;
  font-size: 13px;
}

/* 「改用另一種盒型」切換鈕：配不出來時給的出口（本頁尺規＝框類 10px、非膠囊） */
.gb-budget-switch {
  display: inline-block;
  margin-left: 6px;
  padding: 11px 14px;
  min-height: 44px;
  border: 1px solid rgba(148, 114, 62, 0.42);
  border-radius: 10px;
  background: #fffdf7;
  color: #7a6234;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.gb-budget-switch:active { transform: scale(0.98); }

/* 依預算隨機搭配 */
.gb-random-section {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid #e8efe4;
}
.gb-random-input-row {
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1.5px solid #d0deca;
  padding-bottom: 8px;
  margin-bottom: 14px;
  transition: border-color 0.2s;
}
.gb-random-input-row:focus-within { border-color: #3d6142; }
.gb-random-prefix {
  font-size: 14px;
  font-weight: 700;
  color: #5a7a5e;
  white-space: nowrap;
}
.gb-random-input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 15px;
  color: #1e2e1c;
  min-width: 0;
  -moz-appearance: textfield;
}
.gb-random-input::-webkit-outer-spin-button,
.gb-random-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.gb-random-input::placeholder { color: #b0c8aa; font-size: 14px; }
.gb-random-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 6px 14px;
  border-radius: 20px;
  border: 1.5px solid #3d6142;
  background: #3d6142;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background 0.15s;
}
.gb-random-btn:hover { background: #2d4a30; border-color: #2d4a30; }
.gb-random-cards {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 4px;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x mandatory;
}
.gb-random-cards::-webkit-scrollbar { display: none; }
.gb-random-cards[hidden] { display: none !important; }


/* ── Portfolio Section ──────────────────────────────────────── */
.gb-portfolio-section {
  padding: 48px 20px 40px;
  background: #fafaf8;
  border-top: 1px solid #efefef;
}
.gb-portfolio-eyebrow {
  font-size: 10px; font-weight: 700; letter-spacing: 0.2em;
  color: #4a6e3f; margin: 0 0 8px; text-transform: uppercase; /* 對比 2.54 → 5.9 */
}
.gb-portfolio-title {
  font-size: 22px; font-weight: 800; color: #1e2e1c; margin: 0 0 8px;
}
.gb-portfolio-sub {
  font-size: 13px; color: #5b6e56; margin: 0 0 28px; line-height: 1.6;
}
.gb-portfolio-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3px;
  margin: 0 -20px 32px;
}
.gb-portfolio-card {
  position: relative; aspect-ratio: 1/1; overflow: hidden;
  cursor: pointer; background: #e8ede4;
}
.gb-portfolio-card img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.4s ease;
  display: block;
}
.gb-portfolio-card:hover img { transform: scale(1.05); }
.gb-portfolio-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.72) 0%, transparent 55%);
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 14px; opacity: 0; transition: opacity 0.3s;
}
.gb-portfolio-card:hover .gb-portfolio-overlay,
.gb-portfolio-card:first-child .gb-portfolio-overlay { opacity: 1; }
/* 觸控裝置沒有 hover＝第 2、3 張卡的說明永遠隱形（2026-08-05 修）：常駐顯示 */
@media (hover: none) {
  .gb-portfolio-card .gb-portfolio-overlay { opacity: 1; }
}
.gb-portfolio-tag {
  font-size: 9px; font-weight: 700; letter-spacing: 0.12em;
  color: rgba(255,255,255,0.7); text-transform: uppercase; margin-bottom: 4px;
}
.gb-portfolio-client {
  font-size: 13px; font-weight: 700; color: #fff; margin: 0 0 2px;
}
.gb-portfolio-project {
  font-size: 11px; color: rgba(255,255,255,0.75); margin: 0;
}
/* First card spans full width */
.gb-portfolio-card:first-child {
  grid-column: 1 / -1; aspect-ratio: 16/9;
}
.gb-portfolio-cta-wrap {
  text-align: center; padding-top: 8px;
}
.gb-portfolio-cta-text {
  font-size: 13px; color: #5b6e56; margin: 0 0 14px;
}
.gb-portfolio-cta-btn {
  display: inline-flex; align-items: center; gap: 7px;
  background: #2d4a22; color: #fff;
  padding: 13px 28px; border-radius: 99px;
  font-size: 14px; font-weight: 700; text-decoration: none;
  transition: background 0.2s, transform 0.15s;
}
.gb-portfolio-cta-btn:hover { background: #1e3318; transform: translateY(-2px); }
.gb-portfolio-cta-btn i { font-size: 17px; }

/* ── Lightbox ────────────────────────────────────────────────── */
.gb-lightbox {
  position: fixed; inset: 0; z-index: var(--z-lightbox, 9500);
  background: rgba(0,0,0,0.92);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 0.25s;
}
.gb-lightbox.is-open { opacity: 1; pointer-events: all; }
.gb-lightbox-img-wrap { max-width: 92vw; max-height: 85vh; }
.gb-lightbox-img { max-width: 100%; max-height: 85vh; object-fit: contain; border-radius: 8px; }
.gb-lightbox-close {
  position: absolute; top: 16px; right: 16px;
  width: 44px; height: 44px; border-radius: 50%; border: none;
  background: rgba(255,255,255,0.15); color: #fff; font-size: 20px;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.gb-lightbox-prev, .gb-lightbox-next {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 44px; height: 44px; border-radius: 50%; border: none;
  background: rgba(255,255,255,0.15); color: #fff; font-size: 20px;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: background 0.2s;
}
.gb-lightbox-prev { left: 12px; }
.gb-lightbox-next { right: 12px; }
.gb-lightbox-prev:hover, .gb-lightbox-next:hover { background: rgba(255,255,255,0.3); }
.gb-lightbox-caption {
  position: absolute; bottom: 20px; left: 0; right: 0;
  text-align: center; color: rgba(255,255,255,0.7); font-size: 13px;
}

/* ── Giftbox page: hide site header, remove gap ── */
.giftbox-page .giftbox-hidden-header { display: none !important; }
.giftbox-page #giftboxCard { margin-top: 0 !important; }

/* ── 禮盒進度側欄已移除（2026-08-05 業主拍板，markup/JS 同步刪）── */

/* ═══ 觸控目標批次修（2026-07-04 健檢 backlog：透明熱區擴到 ≥44px，視覺不變）═══ */
.gb-confirm-edit-btn, .gb-search-clear, .gb-quick-select-btn { position: relative; }
.gb-confirm-edit-btn::after, .gb-search-clear::after, .gb-quick-select-btn::after {
  content: ""; position: absolute; inset: -12px;
}
.gb-budget-chip { min-height: 44px; }
.gb-qty-btn { min-width: 44px; min-height: 44px; }
.gb-showcase-dot { position: relative; }
.gb-showcase-dot::after { content: ""; position: absolute; inset: -14px; border-radius: 50%; }


/* ═══════════════════════════════════════════════════════════════
   🎁 禮盒頁全頁重設計（2026-08-06 業主自 _giftbox-redesign-mock.html 拍板）
   字級對齊首頁階梯 A 案（區塊標題 20/700 襯線・卡標 15/800・內文 14・註記 12）、
   gutter 20、框類圓角 10。此層＝重設計的單一真相，改禮盒頁版面優先改這裡，
   勿回上方舊規則加碼（同權重後載者勝）。
   ═══════════════════════════════════════════════════════════════ */

/* ── 共用區段標頭 ── */
.gb-sec-eyebrow {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 12.5px;
  letter-spacing: 0.24em;
  color: #8a6a33;
  text-transform: uppercase;
  margin: 0 0 5px;
}
.gb-sec-title {
  font-family: var(--font-serif, 'Noto Serif TC'), serif;
  font-weight: 700;
  font-size: 20px;
  color: #1e2e1c;
  margin: 0 0 4px;
  line-height: 1.35;
}
.gb-sec-desc { font-size: 14px; color: #4c5346; line-height: 1.7; margin: 0; }

/* ── ① Hero：收斂高度＋襯線大標＋價格錨點 ── */
.gb-hero { min-height: 0; height: clamp(260px, 76vw, 310px); padding: 24px 20px 20px; }
.gb-hero-eyebrow {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 12.5px;
  letter-spacing: 0.22em;
  color: #e6cf9a;
}
.gb-hero-title {
  font-family: var(--font-serif, 'Noto Serif TC'), serif;
  font-size: clamp(25px, 6.8vw, 30px);
  font-weight: 900;
}
.gb-hero-subtitle { margin-bottom: 16px; }
/* hero C（2026-08-06 業主拍板）：CTA 膠囊移除，改「組合價 × 賣點」一行金字收尾。
   ⚠️ 分隔點「・」由 CSS 產生：價格在型錄載入前是 [hidden]，寫死在 HTML 會冒出孤兒點。 */
.gb-hero-meta {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 6px;
  margin: 0; font-size: 12.5px; letter-spacing: 0.04em; line-height: 1.7;
}
.gb-hero-price { color: #e6cf9a; font-weight: 700; }
.gb-hero-price[hidden] { display: none; }
.gb-hero-tags { font-size: 12.5px; color: rgba(255, 255, 255, 0.9); margin: 0; letter-spacing: 0.04em; }
.gb-hero-price:not([hidden]) + .gb-hero-tags::before { content: '・'; color: rgba(230, 207, 154, 0.7); margin-right: 5px; }

/* ── ② 步驟硬幣（icon+01 小字退役） ── */
.gb-steps-section { padding: 22px 20px 20px; }
.gb-step-coin {
  width: 34px; height: 34px; border-radius: 50%;
  margin: 0 auto 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 800;
  background: #eef3ea; color: #4a6e3f; border: 1.5px solid #d9e4d3;
  transition: background 0.2s, color 0.2s;
}
.gb-step-item.is-on .gb-step-coin { background: #2f4b33; color: #fff; border-color: #2f4b33; }
.gb-step-name { font-size: 14px; }
.gb-step-line { margin-top: 16px; }

/* ── ③ 三種開始方式 ── */
.gb-paths-section { background: #fff; padding: 24px 20px 26px; border-top: 1px solid #efefef; }
.gb-paths-section .gb-sec-desc { margin-bottom: 14px; }
.gb-path {
  display: flex; align-items: center; gap: 13px;
  width: 100%; text-align: left;
  border: 1px solid rgba(47, 75, 51, 0.16); border-radius: 10px;
  background: #fff; padding: 14px 15px; margin-bottom: 10px;
  position: relative; cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}
.gb-path:last-child { margin-bottom: 0; }
.gb-path:active { transform: scale(0.99); }
.gb-path:hover { border-color: rgba(148, 114, 62, 0.5); box-shadow: 0 4px 14px rgba(61, 97, 66, 0.1); }
.gb-path-ic {
  width: 42px; height: 42px; border-radius: 10px; flex: 0 0 42px;
  background: #eef3ea; color: #3d6142;
  display: flex; align-items: center; justify-content: center; font-size: 21px;
}
.gb-path-tt { flex: 1; min-width: 0; }
.gb-path-tt b { display: block; font-size: 16px; font-weight: 800; color: #1e2e1c; }
.gb-path-tt span { display: block; font-size: 12.5px; color: #5b6e56; margin-top: 2px; }
.gb-path-go { color: #8a6a33; font-size: 19px; flex: 0 0 auto; }
.gb-path.is-hot { border-color: rgba(168, 137, 79, 0.4); background: linear-gradient(135deg, #fffdf6, #fbf6ea); }
.gb-path-badge {
  position: absolute; top: -8px; left: 14px;
  background: #8a6a33; color: #fff;
  font-size: 10.5px; font-weight: 800; letter-spacing: 0.08em;
  border-radius: 999px; padding: 2px 9px;
}

/* ── ④ 精選組合＝米金 tint 區 ── */
.gb-recommend-section {
  background: linear-gradient(180deg, #f6f1e4, #f8f6ef);
  border-top: 1px solid rgba(168, 137, 79, 0.35);
  border-bottom: none;
  padding: 28px 20px 26px;
}
.gb-recommend-title {
  font-family: var(--font-serif, 'Noto Serif TC'), serif;
  font-size: 20px; font-weight: 700;
}
.gb-recommend-sub { font-size: 14px; color: #5b6e56; }
.gb-budget-chip { font-size: 14px; font-weight: 600; padding: 8px 15px; border-width: 1px; border-color: rgba(47, 75, 51, 0.18); color: #4c5346; }
.gb-budget-chip.active { background: #2f4b33; border-color: #2f4b33; }
.gb-rec-card { flex: 0 0 236px; border-radius: 10px; border: 1px solid rgba(168, 137, 79, 0.35); }
.gb-rec-name {
  font-family: var(--font-serif, 'Noto Serif TC'), serif;
  font-size: 17px; font-weight: 700;
}
.gb-rec-thumbs { display: flex; gap: 7px; margin: 0 0 9px; }
.gb-rec-thumbs i {
  flex: 1; aspect-ratio: 4/3; border-radius: 8px;
  background: #e8ede4 center/cover no-repeat; overflow: hidden;
}
.gb-rec-teas { font-size: 13px; color: #4c5346; }
.gb-rec-price { font-size: 17px; font-weight: 800; color: #2f4b33; }
.gb-rec-apply-btn { font-size: 14px; padding: 10px 0; }

/* 隨機搭配＝區尾一列（虛線金框） */
.gb-random-section { margin-top: 16px; padding-top: 0; border-top: none; }
.gb-random-input-row {
  display: flex; align-items: center; gap: 10px;
  background: #fff; border: 1px dashed rgba(168, 137, 79, 0.45); border-radius: 10px;
  padding: 12px 14px; border-bottom: 1px dashed rgba(168, 137, 79, 0.45);
}
.gb-random-label { font-size: 13px; font-weight: 600; color: #4c5346; flex: 0 0 auto; }
.gb-random-prefix { color: #6b7364; }

/* ── ⑤ 自選工作區（白底＋硬幣標頭＋狀態 chip） ── */
.gb-manual-head { background: #fff; padding: 28px 20px 0; border-top: 1px solid #efefef; }
.gb-select-section { background: #fff; padding: 22px 20px 20px; border-top: none; }
.gb-select-titlerow { display: flex; align-items: center; gap: 10px; }
.gb-select-coin {
  width: 30px; height: 30px; border-radius: 50%; flex: 0 0 30px;
  background: #2f4b33; color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 13.5px; font-weight: 800;
}
.gb-select-title {
  font-family: var(--font-serif, 'Noto Serif TC'), serif;
  font-size: 18px; font-weight: 700; margin: 0; flex: 1; min-width: 0;
}
.gb-select-state {
  flex: 0 0 auto;
  font-size: 12px; font-weight: 700;
  border-radius: 999px; padding: 4px 10px;
  background: #f2f2ee; color: #6d7264;
}
.gb-select-state[data-state="picked"] { background: rgba(47, 75, 51, 0.1); color: #2f4b33; }
.gb-select-sub { margin: 4px 0 0 40px; font-size: 13px; }

/* 茶卡：升到首頁型錄規格 */
.gb-tea-card { flex: 0 0 164px; border-radius: 10px; }
.gb-card-name { font-size: 15px; font-weight: 800; }
.gb-card-desc { font-size: 12.5px; }
.gb-card-price { font-size: 16px; font-weight: 800; color: #1e2e1c; margin-top: 7px; }
.gb-card-sold {
  position: absolute; top: 8px; right: 8px; z-index: 2;
  font-size: 11px; font-weight: 700; color: #8a4a3a;
  border: 1px solid #c9a79b; border-radius: 999px;
  padding: 2px 8px; background: #fff;
}
.gb-tea-card.is-unavailable { opacity: 0.55; }

/* 盒款卡 */
.gb-box-style-btn { border-radius: 10px; }
.gb-box-style-name { font-size: 14.5px; font-weight: 800; }
.gb-box-style-price { font-size: 12.5px; color: #6b7364; }

/* 三款盒型（2026-08-06 大罐禮盒上線）：原本 flex:1 三等分＝390px 下每格只剩 ~113px，
   中文盒名被擠成一字一行、價格被切掉（實測）。改成橫向捲動的固定寬卡，
   名稱與價格上下排＝再多一款盒型也不會爆。 */
.gb-box-style-btns {
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 2px;
}
.gb-box-style-btns::-webkit-scrollbar { height: 0; }
.gb-box-style-btn {
  flex: 0 0 auto;
  min-width: 132px;
  align-items: center;
  gap: 9px;
  padding: 11px 13px;
}
.gb-box-style-tt { display: flex; flex-direction: column; text-align: left; min-width: 0; }
.gb-box-style-name { display: block; line-height: 1.35; white-space: nowrap; }
.gb-box-style-price { display: block; margin-top: 1px; }

/* 確認卡 */
.gb-confirm-card { background: #f8f6ef; border: 1px solid rgba(168, 137, 79, 0.35); border-radius: 10px; }
.gb-confirm-title { font-family: var(--font-serif, 'Noto Serif TC'), serif; font-size: 17px; font-weight: 700; }
.gb-confirm-row-name { font-size: 14px; }
.gb-confirm-total-row strong {
  font-family: var(--font-serif, 'Noto Serif TC'), serif;
  font-size: 24px; font-weight: 900; color: #2f4b33;
}
.gb-confirm-cta { width: 100%; font-size: 16px; font-weight: 700; padding: 15px 0; border-radius: 999px; }

/* ── ⑥ 企業作品＝深墨綠識別帶 ── */
.gb-portfolio-section {
  background-color: #20331f; /* gradient 的 solid fallback（亦讓對比掃描器讀得到深底） */
  background-image: linear-gradient(170deg, #243a28, #1b2c1f);
  border-top: none;
  padding: 38px 20px 36px;
}
.gb-portfolio-eyebrow { color: #cbb27c; }
.gb-portfolio-title {
  font-family: var(--font-serif, 'Noto Serif TC'), serif;
  font-size: 20px; font-weight: 700; color: #f8f4e8;
}
.gb-portfolio-sub { color: rgba(244, 239, 226, 0.78); }
.gb-portfolio-grid { margin: 0 0 22px; gap: 8px; }
.gb-portfolio-card { border-radius: 10px; }
.gb-portfolio-cta-text { color: rgba(244, 239, 226, 0.78); }
.gb-portfolio-cta-btn {
  background: transparent;
  border: 1px solid rgba(203, 178, 124, 0.6);
  color: #e6d3a0;
}
.gb-portfolio-cta-btn:hover { background: rgba(203, 178, 124, 0.12); transform: translateY(-2px); }

/* ── ⑦ 安心列 ── */
.gb-assure {
  background: #f8f6ef;
  padding: 22px 20px 28px;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
  text-align: center;
}
.gb-assure div b { display: block; font-size: 13px; font-weight: 700; color: #2f4b33; }
.gb-assure div span { display: block; font-size: 11.5px; color: #6b7364; margin-top: 2px; }

/* STEP 2 標頭：「與第一款相同」鈕改排到標題列下（與標題並排會把 18px 襯線標題擠到折行） */
#gbStep2 .gb-select-header { flex-direction: column; align-items: stretch; gap: 10px; }
#gbStep2 .gb-same-btn { align-self: flex-start; margin-left: 40px; }

/* 對比補刀（2026-08-06 複測殘留）：
   tag 白字壓 JS inline tagColor 差一點點（4.27–4.32）＝疊一層 12% 黑紗把底壓深；
   其餘三個是舊灰綠字色的漏網。 */
.gb-rec-tag { background-image: linear-gradient(rgba(0, 0, 0, 0.14), rgba(0, 0, 0, 0.14)); }
.gb-select-state { color: #62675a; }
.gb-select-sub { color: #5b6e56; }
.gb-card-desc { color: #5b6e56; }

/* 隨機搭配鈕熱區 44px（guardian 審查：原 padding 高約 29px） */
.gb-random-btn { min-height: 44px; }

/* ── 盒型（尺寸）切換列（2026-08-07）──────────────────────────────
   放在「自己挑兩款茶」標頭下、選茶之前：茶池跟著盒型走，選在後面等於白工。
   語彙同本頁：框類 10px、無膠囊。只有一種尺寸時 JS 不渲染（hidden）。 */
.gb-size-switch {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 14px 0 0;
}
.gb-size-switch[hidden] { display: none; }
.gb-size-label {
  flex: 0 0 100%;
  font-size: 12.5px;
  font-weight: 700;
  color: #5b6e56;
  letter-spacing: 0.04em;
}
.gb-size-chip {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1px;
  background: #fff;
  border: 1px solid rgba(47, 75, 51, 0.2);
  border-radius: 10px;
  padding: 10px 13px;
  font-family: inherit;
  cursor: pointer;
  min-height: 44px;
  transition: border-color 0.15s, background 0.15s;
}
.gb-size-chip b { font-size: 14.5px; font-weight: 800; color: #1e2e1c; white-space: nowrap; }
.gb-size-chip span { font-size: 12px; color: #6b7364; }
.gb-size-chip.is-on {
  border-color: rgba(168, 137, 79, 0.6);
  background: linear-gradient(135deg, #fffdf6, #fbf6ea);
}
.gb-size-chip.is-on b { color: #6b5320; }
