/*
Theme Name: CARTRUCK TW
Theme URI: https://cartruck.tw
Author: CARTRUCK Team
Author URI: https://cartruck.tw
Description: 綜合電商主題 — 為 WooCommerce 設計，提供商品列表、商品詳情、購物車、結帳、會員中心的完整 UI 覆寫。需安裝 WooCommerce 外掛。
Version: 1.0.1
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
License: GPL v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: cartruck
Tags: woocommerce, ecommerce, shop, custom-colors, custom-menu, featured-images, threaded-comments, translation-ready

CARTRUCK TW WordPress Theme, (C) 2026
*/

/* === Design Tokens — 信任藍 / 簡潔現代 (與原型一致) === */
:root {
  /* 主色：信任藍 trust blue */
  --brand-50:  oklch(0.97 0.02 248);
  --brand-100: oklch(0.93 0.05 248);
  --brand-200: oklch(0.85 0.09 248);
  --brand-300: oklch(0.74 0.13 248);
  --brand-500: oklch(0.55 0.17 248);
  --brand-600: oklch(0.48 0.17 248);
  --brand-700: oklch(0.40 0.15 248);
  --brand-900: oklch(0.22 0.08 248);

  /* 中性色：冷灰基底 */
  --ink-50:   oklch(0.985 0.003 248);
  --ink-100:  oklch(0.96 0.005 248);
  --ink-200:  oklch(0.92 0.005 248);
  --ink-300:  oklch(0.82 0.005 248);
  --ink-400:  oklch(0.68 0.01 248);
  --ink-500:  oklch(0.55 0.01 248);
  --ink-700:  oklch(0.38 0.01 248);
  --ink-800:  oklch(0.28 0.01 248);
  --ink-900:  oklch(0.18 0.01 248);

  --hot:     oklch(0.65 0.20 28);     /* 限時/特賣 紅 */
  --hot-bg:  oklch(0.96 0.04 28);
  --success: oklch(0.62 0.16 155);
  --warning: oklch(0.78 0.16 75);
  --info:    oklch(0.65 0.13 220);

  --r-sm: 4px;
  --r-md: 8px;
  --r-lg: 12px;
  --r-full: 999px;

  --shadow-xs: 0 1px 2px rgba(0,0,0,0.04);
  --shadow-sm: 0 2px 6px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 12px 32px rgba(0,0,0,0.12);

  --header-h: 64px;
  --topbar-h: 32px;

  --font-sans: "Noto Sans TC", -apple-system, "PingFang TC", "Microsoft JhengHei", sans-serif;
  --font-mono: "JetBrains Mono", "Roboto Mono", Menlo, monospace;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-sans);
  font-size: 14px;
  color: var(--ink-900);
  background: var(--ink-100);
  line-height: 1.6;
}
.num { font-family: var(--font-mono); font-feature-settings: "tnum"; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
img { max-width: 100%; display: block; }

.container { max-width: 1280px; margin: 0 auto; padding: 0 16px; }

/* === Header（白底，與原型一致）=== */
.ct-topbar {
  background: var(--ink-900);
  color: var(--ink-300);
  font-size: 12px;
  height: var(--topbar-h);
  display: flex;
  align-items: center;
}
.ct-topbar .container { display: flex; align-items: center; gap: 16px; width: 100%; }
.ct-topbar a { color: var(--ink-300); padding: 0 4px; cursor: pointer; }
.ct-topbar a:hover { color: #fff; }
.ct-topbar .seller-link { color: var(--brand-300); font-weight: 500; display: inline-flex; align-items: center; gap: 5px; }
.ct-topbar .sep { color: var(--ink-700); }
.ct-topbar .right { margin-left: auto; display: flex; gap: 10px; align-items: center; }

.ct-header {
  background: #fff;
  color: var(--ink-900);
  box-shadow: var(--shadow-xs);
}
.ct-header .ct-header-main {
  display: flex;
  align-items: center;
  gap: 32px;
  height: calc(var(--header-h) + 24px);
}
.ct-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--brand-700);
  white-space: nowrap;
}
.ct-logo-mark {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--brand-500), var(--brand-700));
  color: #fff;
  border-radius: var(--r-md);
  display: grid;
  place-items: center;
}
.ct-logo .tw { color: var(--brand-500); margin-left: 4px; }
.ct-logo-img { height: 38px !important; width: auto !important; max-height: 38px; display: block; }
.ct-footer .ct-logo-img { height: 34px !important; max-height: 34px; }

/* Visa Acceptance 金流外掛的 visa-acceptance-payment-gateway-blocks.css 有一條裸的 `.woocommerce{display:grid}`:
   商品頁 body 帶 woocommerce class → 整頁變成單欄 grid,欄寬被 800px 商品圖撐開,手機整頁破版(2026-10-24 查到);
   各頁 WC 短碼外層 div.woocommerce 也會中。提高權重還原成 WC 預設的 block。 */
body.woocommerce, div.woocommerce { display: block; }

/* ============== 會員中心 My Account(App 式自訂外殼) ============== */
.woocommerce-account .woocommerce { display: block; max-width: 1040px; margin: 20px auto 48px; }
.ctma { max-width: 1040px; margin: 0 auto; }
/* 蓋掉 WC 外掛預設的兩欄浮動版面(float:right; width:68%) */
.woocommerce-account .woocommerce-MyAccount-content,
.woocommerce-account .woocommerce-MyAccount-navigation { float: none !important; width: 100% !important; }
.ctma-hero { display: flex; align-items: center; gap: 16px; background: linear-gradient(125deg, var(--brand-600, #2563eb), var(--brand-800, #1e3a8a)); color: #fff; padding: 22px 26px; border-radius: 16px; box-shadow: 0 6px 20px rgba(29, 78, 216, .22); }
.ctma-avatar { width: 58px; height: 58px; border-radius: 50%; background: rgba(255,255,255,.22); display: grid; place-items: center; font-size: 25px; font-weight: 700; flex: 0 0 auto; }
.ctma-who { flex: 1; min-width: 0; }
.ctma-name { font-size: 19px; font-weight: 700; }
.ctma-chips { display: flex; gap: 8px; margin-top: 7px; flex-wrap: wrap; }
.ctma-chip { background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.3); padding: 2px 11px; border-radius: 20px; font-size: 12px; }
.ctma-chip-tier { background: #fff; color: var(--brand-700); font-weight: 700; border-color: #fff; }
.ctma-hero-actions { display: flex; flex-direction: column; gap: 8px; align-items: flex-end; flex: 0 0 auto; }
.ctma-shop { color: #fff; font-size: 13px; opacity: .92; white-space: nowrap; }
.ctma-shop:hover { opacity: 1; color: #fff; text-decoration: underline; }
.ctma-backend { background: #fff; color: var(--brand-700, #1d4ed8); font-weight: 700; font-size: 13px; padding: 7px 14px; border-radius: 20px; white-space: nowrap; box-shadow: 0 2px 8px rgba(0,0,0,.14); transition: transform .15s, box-shadow .15s; }
.ctma-mystore { color: #fff; font-weight: 700; font-size: 13px; padding: 6px 14px; border-radius: 20px; white-space: nowrap; border: 1.5px solid rgba(255,255,255,.85); background: rgba(255,255,255,.12); transition: background .15s; }
.ctma-mystore:hover { color: #fff; background: rgba(255,255,255,.24); }
.ctma-backend:hover { color: var(--brand-800, #1e3a8a); transform: translateY(-1px); box-shadow: 0 4px 13px rgba(0,0,0,.2); }
/* 橫向頁籤 */
.ctma-tabs { display: flex; gap: 8px; margin: 16px 0 18px; overflow-x: auto; padding-bottom: 4px; -webkit-overflow-scrolling: touch; scrollbar-width: thin; }
.ctma-tab { display: flex; flex-direction: column; align-items: center; gap: 5px; min-width: 86px; padding: 12px 10px; background: #fff; border: 1px solid var(--ink-200); border-radius: 12px; color: var(--ink-700); font-size: 12.5px; white-space: nowrap; transition: border-color .15s, box-shadow .15s, transform .15s; flex: 0 0 auto; }
.ctma-tab .ic { font-size: 21px; line-height: 1; }
.ctma-tab:hover { border-color: var(--brand-400, #60a5fa); transform: translateY(-1px); box-shadow: 0 3px 10px rgba(0,0,0,.06); color: var(--brand-700); }
.ctma-tab.is-active { background: var(--brand-600, #2563eb); border-color: var(--brand-600, #2563eb); color: #fff; font-weight: 600; box-shadow: 0 4px 12px rgba(37, 99, 235, .3); }
.ctma-tab-out { border-style: dashed; color: var(--ink-500); }
/* 內容區 */
.ctma-body { background: #fff; border: 1px solid var(--ink-200); border-radius: 14px; padding: 24px 26px; min-height: 320px; }
.ctma-body > p:first-child { margin-top: 0; }

/* 會員卡 */
.ct-acc-hero { display: flex; align-items: center; gap: 16px; background: linear-gradient(135deg, var(--brand-500), var(--brand-700)); color: #fff; padding: 22px 24px; border-radius: var(--r-md); margin-bottom: 16px; }
.ct-acc-avatar { width: 56px; height: 56px; border-radius: 50%; background: rgba(255,255,255,.22); display: grid; place-items: center; font-size: 24px; font-weight: 700; flex: 0 0 auto; }
.ct-acc-hero-info { flex: 1; }
.ct-acc-name { font-size: 18px; font-weight: 600; }
.ct-acc-meta { font-size: 12px; opacity: .9; margin-top: 4px; display: flex; gap: 6px; flex-wrap: wrap; }
.ct-acc-tier { background: rgba(255,255,255,.25); padding: 1px 8px; border-radius: 20px; font-weight: 600; }
.ct-acc-hero-link { color: #fff; font-size: 13px; opacity: .92; white-space: nowrap; }
.ct-acc-hero-link:hover { opacity: 1; text-decoration: underline; }

/* 訂單統計 */
.ct-acc-stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; margin-bottom: 18px; }
.ct-acc-stat { background: #fff; border: 1px solid var(--ink-200); border-radius: var(--r-md); padding: 16px 8px; text-align: center; color: var(--ink-900); transition: border-color .15s; }
.ct-acc-stat:hover { border-color: var(--brand-400, #60a5fa); }
.ct-acc-stat .n { display: block; font-size: 26px; font-weight: 700; color: var(--brand-600); }
.ct-acc-stat .l { display: block; font-size: 12px; color: var(--ink-600); margin-top: 4px; }

/* 快捷功能 */
.ct-acc-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 24px; }
.ct-acc-actions a { display: flex; align-items: center; gap: 10px; background: #fff; border: 1px solid var(--ink-200); border-radius: var(--r-md); padding: 14px 16px; color: var(--ink-800); font-size: 14px; transition: border-color .15s, background .15s; }
.ct-acc-actions a:hover { border-color: var(--brand-400, #60a5fa); background: var(--brand-50); }
.ct-acc-actions a span { font-size: 20px; }

/* 最近訂單 */
.ct-acc-recent h3 { font-size: 16px; font-weight: 600; margin: 0 0 12px; }
.ct-acc-orders { width: 100%; border-collapse: collapse; font-size: 14px; }
.ct-acc-orders td { padding: 12px 8px; border-bottom: 1px solid var(--ink-100); }
.ct-acc-orders .o-id { font-weight: 600; }
.ct-acc-orders .o-date { color: var(--ink-500); }
.ct-acc-orders .st { font-size: 12px; padding: 2px 10px; border-radius: 20px; background: var(--ink-100); color: var(--ink-700); }
.ct-acc-orders .st-completed { background: #dcfce7; color: #166534; }
.ct-acc-orders .st-processing { background: var(--brand-50); color: var(--brand-700); }
.ct-acc-orders .st-shipping { background: #e0f2fe; color: #075985; }
.ct-acc-orders .st-returning { background: #f3e8ff; color: #7c3aed; }
.ct-acc-orders .o-act a { color: var(--brand-600); }
.ct-acc-empty { padding: 28px; text-align: center; color: var(--ink-500); border: 1px dashed var(--ink-200); border-radius: var(--r-md); }

/* 會員等級價標籤 */
.ct-tier-tag { display: inline-block; font-size: 11px; background: var(--brand-50); color: var(--brand-700); border: 1px solid var(--brand-200); padding: 1px 8px; border-radius: 20px; margin-left: 6px; vertical-align: middle; font-weight: 600; }
.price ins { text-decoration: none; color: var(--brand-700); font-weight: 700; }
.price del { color: var(--ink-400, #94a3b8); font-weight: 400; }

/* 常購收藏 ♥ */
.woocommerce ul.products li.product { position: relative; }
.ct-fav { background: rgba(255,255,255,.92); border: 1px solid var(--ink-200); border-radius: 50%; width: 34px; height: 34px;
  cursor: pointer; color: var(--ink-400, #94a3b8); font-size: 17px; line-height: 1; padding: 0; display: inline-flex; align-items: center; justify-content: center;
  transition: color .15s, border-color .15s, background .15s; }
li.product .ct-fav { position: absolute; top: 10px; right: 10px; z-index: 3; }
.ct-fav.is-active { color: #e0245e; border-color: #f3b6c6; }
.ct-fav:hover { color: #e0245e; border-color: #e0245e; }
.ct-fav.ct-loading { opacity: .45; }
.ct-fav-line { margin: 14px 0; }
.ct-fav-line .ct-fav { width: auto; height: auto; border-radius: var(--r-md); padding: 9px 18px; gap: 8px; font-size: 14px; }
/* 常購清單 */
.ct-fav-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.ct-fav-card { border: 1px solid var(--ink-200); border-radius: var(--r-md); padding: 12px; display: flex; flex-direction: column; }
.ct-fav-thumb img { width: 100%; height: auto; border-radius: 4px; }
.ct-fav-name { font-size: 13px; color: var(--ink-800); margin: 8px 0 4px; line-height: 1.4; min-height: 2.6em; }
.ct-fav-price { font-size: 14px; margin-bottom: 10px; }
.ct-fav-act { display: flex; gap: 8px; align-items: center; margin-top: auto; }
.ct-fav-act .button { flex: 1; text-align: center; padding: 9px !important; font-size: 13px !important; }
.ct-fav-remove { width: 34px; height: 34px; flex: 0 0 auto; border-radius: 6px; color: var(--ink-500) !important; border-color: var(--ink-300) !important; font-size: 16px; }
.ct-fav-remove:hover { color: #d33 !important; border-color: #d33 !important; }
@media (max-width: 820px) { .ct-fav-grid { grid-template-columns: repeat(2, 1fr); } }

/* 帳戶詳細資料 — 公司資料 / 多筆欄位 */
.ct-acc-hr { border: 0; border-top: 1px solid var(--ink-200); margin: 26px 0; }
.ct-acc-h { font-size: 15px; font-weight: 600; margin: 0 0 14px; display: flex; align-items: center; gap: 12px; }
.ct-rep-add { font-size: 12px; color: var(--brand-600); background: var(--brand-50); border: 1px solid var(--brand-200); border-radius: 20px; padding: 3px 12px; cursor: pointer; font-weight: 500; }
.ct-rep-add:hover { background: var(--brand-100, #dbeafe); }
.ct-rep-row { display: flex; gap: 8px; margin-bottom: 8px; align-items: center; }
.ct-rep-row input { flex: 1; border: 1px solid var(--ink-300); border-radius: 4px; padding: 9px 11px; font-size: 14px; min-width: 0; }
.ct-rep-addr input:nth-child(3) { flex: 2.6; }
.ct-rep-del { flex: 0 0 auto; width: 36px; height: 36px; border: 1px solid var(--ink-300); background: #fff; border-radius: 6px; color: var(--ink-500); cursor: pointer; font-size: 18px; line-height: 1; }
.ct-rep-del:hover { color: #d33; border-color: #d33; }
.woocommerce-EditAccountForm .woocommerce-form-row label { display: block; font-size: 13px; color: var(--ink-700); margin-bottom: 6px; }
.woocommerce-EditAccountForm input.input-text, .woocommerce-EditAccountForm input[type="email"], .woocommerce-EditAccountForm input[type="password"] { border: 1px solid var(--ink-300); border-radius: 4px; padding: 10px 12px; font-size: 15px; width: 100%; max-width: 480px; box-sizing: border-box; }
.woocommerce-EditAccountForm input[disabled] { background: var(--ink-50); color: var(--ink-500); }
/* 變更密碼:預設收合,點按鈕才展開 */
.woocommerce-EditAccountForm fieldset { display: none; border: 1px solid var(--ink-200); border-radius: var(--r-md); padding: 14px 18px; margin-top: 8px; max-width: 480px; }
.woocommerce-EditAccountForm fieldset.ct-pw-open { display: block; }
.woocommerce-EditAccountForm fieldset legend { font-size: 14px; font-weight: 600; padding: 0 6px; }
.ct-pw-toggle { display: inline-flex; align-items: center; gap: 6px; background: #fff; border: 1px solid var(--ink-300); border-radius: var(--r-md); padding: 10px 18px; font-size: 14px; color: var(--ink-800); cursor: pointer; margin-top: 8px; }
.ct-pw-toggle:hover { border-color: var(--ink-900); }

/* 帳號表單(發票資訊等) */
.ct-acc-form .ct-field { margin-bottom: 16px; }
.ct-acc-form .ct-field label { display: block; font-size: 13px; color: var(--ink-700); margin-bottom: 6px; }
.ct-acc-form input[type="text"], .ct-acc-form select { width: 100%; max-width: 420px; box-sizing: border-box; border: 1px solid var(--ink-300); border-radius: 4px; padding: 10px 12px; font-size: 15px; font-family: inherit; }
.ct-acc-btn, .woocommerce-account .button { background: var(--ink-900) !important; color: #fff !important; border: 0 !important; border-radius: 4px !important; padding: 12px 28px !important; cursor: pointer; }
.ct-acc-btn:hover, .woocommerce-account .button:hover { background: var(--brand-700) !important; }

@media (max-width: 820px) {
  .ct-acc-stats { grid-template-columns: repeat(2, 1fr); }
  .ct-acc-actions { grid-template-columns: repeat(2, 1fr); }
}

/* ---- 會員中心 行動版(2026-10-24):≤640 App 式排版;只寫在 media query 內,桌機不受影響 ---- */
@media (max-width: 640px) {
  .woocommerce-account .woocommerce { margin: 12px auto 32px; }
  /* 個人資訊卡:頭像+名稱一列,動作鈕整排在下方 */
  .ctma-hero { flex-wrap: wrap; gap: 12px; padding: 16px; border-radius: 14px; }
  .ctma-avatar { width: 48px; height: 48px; font-size: 20px; }
  .ctma-name { font-size: 17px; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .ctma-chips { gap: 6px; margin-top: 5px; }
  .ctma-chip { font-size: 11.5px; padding: 1px 9px; }
  .ctma-hero-actions { flex: 1 1 100%; flex-direction: row; flex-wrap: wrap; align-items: stretch; gap: 8px; padding-top: 12px; border-top: 1px solid rgba(255,255,255,.2); }
  .ctma-hero-actions > a { flex: 1 1 auto; display: flex; align-items: center; justify-content: center; min-height: 38px; padding: 6px 12px; box-sizing: border-box; text-align: center; font-size: 13px; border-radius: 20px; }
  .ctma-shop { display: flex; opacity: 1; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.35); }
  .ctma-shop:hover { text-decoration: none; }
  .ctma-backend:hover { transform: none; }
  /* 頁籤:精簡圖示列,可橫向滑動,右緣淡出提示還有更多 */
  .ctma-tabs { gap: 6px; margin: 12px -16px 12px; padding: 2px 16px 6px; scroll-padding-inline: 16px; scrollbar-width: none;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
  .ctma-tabs::-webkit-scrollbar { display: none; }
  .ctma-tab { min-width: 64px; padding: 9px 6px 8px; gap: 4px; font-size: 11.5px; border-radius: 10px; }
  .ctma-tab .ic { font-size: 19px; }
  .ctma-tab:hover { transform: none; box-shadow: none; }
  .ctma-tab.is-active { box-shadow: 0 3px 8px rgba(0,0,0,.14); }
  /* 內容區 */
  .ctma-body { padding: 16px 14px; border-radius: 12px; min-height: 0; }
  .ctma-body h2, .ctma-body h3 { font-size: 16px; }

  /* 控制台:訂單狀態一排五格(蝦皮式狀態列) */
  .ct-acc-stats { grid-template-columns: repeat(5, 1fr); gap: 6px; margin-bottom: 18px; }
  .ct-acc-stat { padding: 12px 2px 10px; border-radius: 10px; }
  .ct-acc-stat .n { font-size: 20px; line-height: 1.1; }
  .ct-acc-stat .l { font-size: 11px; margin-top: 4px; white-space: nowrap; }
  .ct-acc-actions { grid-template-columns: 1fr 1fr; gap: 8px; }
  .ct-acc-actions a { padding: 12px; font-size: 13px; }
  /* 最近訂單:表格轉卡片列 */
  .ct-acc-orders, .ct-acc-orders tbody { display: block; }
  .ct-acc-orders tr { display: grid; grid-template-columns: 1fr auto; grid-template-areas: "id st" "date total" "act act"; gap: 4px 10px; padding: 12px 0; border-bottom: 1px solid var(--ink-100); }
  .ct-acc-orders tr:last-child { border-bottom: 0; }
  .ct-acc-orders td { padding: 0; border: 0; }
  .ct-acc-orders .o-id { grid-area: id; }
  .ct-acc-orders .o-status { grid-area: st; text-align: right; }
  .ct-acc-orders .o-date { grid-area: date; font-size: 12.5px; }
  .ct-acc-orders .o-total { grid-area: total; text-align: right; font-weight: 700; }
  .ct-acc-orders .o-act { grid-area: act; }
  .ct-acc-orders .st { white-space: nowrap; }
  .ct-acc-orders .o-act a { display: block; text-align: center; margin-top: 6px; padding: 8px; border: 1px solid var(--ink-200); border-radius: 8px; font-size: 13px; }

  /* 我的訂單 */
  .ctma-body .ctmo-tabs { margin: 0 -14px 14px; padding: 0 14px; scrollbar-width: none; }
  .ctma-body .ctmo-tabs::-webkit-scrollbar { display: none; }
  .ctma-body .ctmo-tab { padding: 10px 10px; font-size: 13.5px; }
  .ctmo-wrap .ctmo-card-head { gap: 4px 10px; }
  .ctmo-wrap .ctmo-order-no { flex: 1 1 auto; font-size: 13.5px; }
  .ctmo-wrap .ctmo-badge { order: 2; }
  .ctmo-wrap .ctmo-order-date { order: 3; flex: 1 1 100%; font-size: 12px; }
  .ctmo-wrap .ctmo-total { display: flex; justify-content: space-between; align-items: baseline; }
  .ctmo-wrap .ctmo-btn { min-height: 40px; display: inline-flex; align-items: center; justify-content: center; box-sizing: border-box; }

  /* 訂單明細(會員中心與訪客訂單查詢頁共用) */
  .ctmo-vo .ctmo-vo-head { flex-direction: column; gap: 2px; margin-bottom: 12px; }
  .ctmo-vo .ctmo-vo-card { padding: 14px; border-radius: 10px; }
  .ctmo-vo .ctmo-pstep .dot { width: 24px; height: 24px; font-size: 12px; }
  .ctmo-vo .ctmo-pstep::before { top: 12px; }
  .ctmo-vo .ctmo-pstep .lbl { font-size: 11px; line-height: 1.3; padding: 0 2px; }
  .ctmo-vo .ctmo-vo-item { display: grid; grid-template-columns: 56px 1fr auto; grid-template-areas: "th nm nm" "th qt sub" "th rd rd"; gap: 4px 10px; align-items: start; padding: 12px 0; }
  .ctmo-vo .ctmo-vo-thumb { grid-area: th; }
  .ctmo-vo .ctmo-vo-iname { grid-area: nm; }
  .ctmo-vo .ctmo-vo-iqty { grid-area: qt; font-size: 12.5px; }
  .ctmo-vo .ctmo-vo-isub { grid-area: sub; min-width: 0; }
  .ctmo-vo .ctmo-vo-readd { grid-area: rd; justify-self: start; margin: 4px 0 0; padding: 6px 12px; }
  .ctmo-vo .ctmo-vo-trow { justify-content: space-between; }
  .ctmo-vo .ctmo-vo-trow .v { min-width: 0; }
  .ctmo-vo .ctmo-vo-grid { gap: 12px; margin-bottom: 12px; }
  .ctmo-vo .ctmo-vo-info .k { display: block; margin: 0 0 1px; font-size: 12px; }
  .ctmo-vo .ctmo-vo-foot .ctmo-btn, body .ctoe-btns .ctoe-btn { min-height: 42px; display: inline-flex; align-items: center; justify-content: center; box-sizing: border-box; }
  body .ctoe-card { padding: 14px; }
  body .ctoe-row input, body .ctoe-row select { font-size: 16px; padding: 10px; }
  body .ctoe-save { width: 100%; padding: 12px; font-size: 15px; }

  /* 表單:16px 防 iOS 自動放大、按鈕滿版好按 */
  .ctma-body input[type="text"], .ctma-body input[type="email"], .ctma-body input[type="tel"], .ctma-body input[type="password"],
  .ctma-body input[type="number"], .ctma-body select, .ctma-body textarea { font-size: 16px !important; max-width: 100% !important; }
  .ctma-body .button, .ctma-body button[type="submit"], .ctad-save, .ctaf-save, .ct-acc-btn { width: 100%; text-align: center; }
  .ctma-body .ctaf-actions { flex-direction: column-reverse; align-items: stretch; gap: 12px; text-align: center; }
  .ctma-body .ctmf-title { font-size: 18px; }
  .ctma-body .ctmf-card { padding: 16px 14px; }
  .woocommerce-EditAccountForm fieldset { padding: 12px 14px; }
  .ct-pw-toggle { width: 100%; justify-content: center; }
  .ct-rep-row { flex-wrap: wrap; }
  .ct-rep-row input { flex: 1 1 140px; }

  /* 常用地址/超商/定位點 */
  .ctma-body .ctad-h { font-size: 17px; }
  .ctma-body .ctad-card { padding: 14px; border-radius: 10px; }
  .ctma-body .ctad-card-h { flex-wrap: wrap; gap: 8px; }
  .ctma-body .ctad-row { position: relative; padding: 10px 44px 10px 0; margin-bottom: 0; border-bottom: 1px dashed var(--ink-200, #e5e7eb); }
  .ctma-body .ctad-row .w-xs { flex: 0 0 96px; }
  .ctma-body .ctad-row .w-s { flex: 1 1 120px; }
  .ctma-body .ctad-row .w-l { flex: 1 1 140px; }
  .ctma-body .ctad-row .ctad-del { position: absolute; top: 10px; right: 0; height: 40px; width: 36px; }
  .ctma-body .ctad-cvs-one .lb { flex: 1 1 100%; text-align: left; padding: 5px 10px; }
  .ctma-body .ctad-cvs-one .w-s { flex: 1 1 140px; }
  .ctma-body .ctad-cvs-one .w-xs { flex: 0 0 104px; }
  #ctad-map { height: 240px !important; }
  .ctma-body table.ctad-ship, .ctma-body table.ctad-ship tbody, .ctma-body table.ctad-ship tr, .ctma-body table.ctad-ship td { display: block; width: auto !important; }
  .ctma-body table.ctad-ship tr { padding: 10px 0; border-bottom: 1px dashed var(--ink-200, #e5e7eb); }
  .ctma-body table.ctad-ship td { padding: 1px 0; border: 0; }

  /* 常購清單 / 通知 */
  .ct-fav-grid { gap: 10px; }
  .ct-fav-card { padding: 8px; }
  .ct-fav-act .button { width: auto; padding: 8px 4px !important; font-size: 12.5px !important; }
  .ctma-body .ct-notipage-tab { font-size: 14px; }
}
@media (max-width: 360px) {
  .ct-acc-stats { gap: 4px; }
  .ct-acc-stat .n { font-size: 18px; }
  .ct-acc-stat .l { font-size: 10.5px; }
  .ctma-tab { min-width: 58px; }
}

/* 搜尋 */
.ct-search-wrap { flex: 1; max-width: 640px; }
.ct-search {
  display: flex;
  align-items: center;
  border: 2px solid var(--brand-500);
  border-radius: var(--r-md);
  background: #fff;
  overflow: hidden;
}
.ct-search input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 14px;
  padding: 10px 14px;
  background: transparent;
  font-family: inherit;
}
.ct-search button {
  padding: 10px 20px;
  background: var(--brand-500);
  color: #fff;
  font-weight: 500;
  display: grid;
  place-items: center;
}
.ct-search button:hover { background: var(--brand-600); }
.ct-hotwords { display: flex; align-items: center; gap: 12px; margin-top: 6px; font-size: 11px; color: var(--ink-500); flex-wrap: wrap; }
.ct-hotwords a { color: var(--ink-700); cursor: pointer; }
.ct-hotwords a:hover { color: var(--brand-500); }

/* 右側動作 icon */
.ct-header-actions { display: flex; align-items: center; gap: 6px; }
.ct-iconbtn {
  position: relative;
  padding: 10px;
  border-radius: var(--r-md);
  color: var(--ink-700);
  display: grid;
  place-items: center;
}
.ct-iconbtn:hover { background: var(--ink-100); }
.ct-iconbtn .dot { position: absolute; top: 6px; right: 6px; width: 8px; height: 8px; border-radius: 50%; background: var(--hot); }
.ct-cart-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 18px;
  height: 18px;
  background: var(--hot);
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  border-radius: 9px;
  padding: 0 4px;
  display: grid;
  place-items: center;
}
.ct-member {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px 6px 6px;
  border: 1px solid var(--ink-200);
  border-radius: var(--r-md);
  font-size: 13px;
  color: var(--ink-900);
}
.ct-member:hover { border-color: var(--brand-500); }
.ct-member .av {
  width: 28px; height: 28px; border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-300), var(--brand-600));
  color: #fff; display: grid; place-items: center; font-size: 12px; font-weight: 600;
}
.ct-member .av.has-img { overflow: hidden; background: var(--ink-200); }   /* 2026-11-01 會員頭貼 */
.ct-member .av img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; display: block; }

/* 分類列 */
.ct-catbar { border-top: 1px solid var(--ink-200); border-bottom: 1px solid var(--ink-200); background: #fff; }
.ct-catbar .container { display: flex; align-items: center; gap: 4px; height: 44px; overflow-x: auto; }
.ct-catbar { position: relative; }
.ct-catbar-all {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 600; color: var(--brand-700);
  padding: 8px 12px; white-space: nowrap;
  border: 0; background: none; cursor: pointer; font-family: inherit;
}
.ct-catbar-all:hover, .ct-catbar-all[aria-expanded="true"] { color: var(--brand-500); }

/* 所有分類:縱向樹狀面板 */
.ct-allcat-panel {
  position: fixed; z-index: 1000; width: 232px;
  background: #fff; border: 1px solid var(--ink-200); border-radius: var(--r-md);
  box-shadow: 0 14px 36px rgba(0,0,0,.16); padding: 6px;
}
.ct-allcat-panel[hidden] { display: none; }
.ct-allcat-list { list-style: none; margin: 0; padding: 0; }
.ct-allcat-item { position: relative; }
.ct-allcat-parent {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px; border-radius: var(--r-md);
  font-size: 14px; font-weight: 600; color: var(--ink-800);
}
.ct-allcat-parent .em { font-size: 16px; line-height: 1; }
.ct-allcat-parent .ar { margin-left: auto; color: var(--ink-400); font-size: 16px; }
.ct-allcat-item:hover > .ct-allcat-parent { background: var(--brand-50); color: var(--brand-700); }
.ct-allcat-sub {
  display: none; position: absolute; left: 100%; top: -6px; margin-left: 5px;
  min-width: 430px; max-width: 560px;
  background: #fff; border: 1px solid var(--ink-200); border-radius: var(--r-md);
  box-shadow: 0 14px 36px rgba(0,0,0,.16); padding: 13px 15px;
}
.ct-allcat-item:hover > .ct-allcat-sub { display: block; }
.ct-allcat-sub .sub-head { display: block; font-size: 13px; font-weight: 700; color: var(--brand-700); margin: 0 0 9px; }
.ct-allcat-sub .sub-links { display: grid; grid-template-columns: repeat(2, 1fr); gap: 3px 16px; }
.ct-allcat-sub .sub-links a { font-size: 13px; color: var(--ink-700); padding: 5px 7px; border-radius: 6px; }
.ct-allcat-sub .sub-links a small { color: var(--ink-400); }
.ct-allcat-sub .sub-links a:hover { background: var(--ink-100); color: var(--brand-600); }
.ct-catbar .vline { width: 1px; height: 18px; background: var(--ink-200); margin: 0 8px; flex-shrink: 0; }
.ct-catbar a.ct-catlink {
  padding: 8px 12px; font-size: 13px; color: var(--ink-700);
  border-radius: var(--r-md); display: inline-flex; align-items: center; gap: 6px;
  white-space: nowrap;
}
.ct-catbar a.ct-catlink:hover { background: var(--ink-100); color: var(--brand-600); }
.ct-catbar a.ct-catlink .em { font-size: 14px; }

/* === 首頁 Hero === */
.ct-hero { display: grid; grid-template-columns: 1fr; gap: 12px; margin-top: 16px; }
.ct-hero-stage { position: relative; border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 16 / 5.5; }
.ct-hero-slide {
  position: absolute; inset: 0; display: flex; align-items: center; padding: 0 56px;
  opacity: 0; transition: opacity .6s ease; color: #fff;
}
.ct-hero-slide.is-active { opacity: 1; }
.ct-hero-slide.tone-brand { background: linear-gradient(135deg, var(--brand-500), var(--brand-700)); }
.ct-hero-slide.tone-hot   { background: linear-gradient(135deg, oklch(0.65 0.20 28), oklch(0.50 0.18 18)); }
.ct-hero-slide.tone-ink   { background: linear-gradient(135deg, var(--ink-900), var(--ink-700)); }
.ct-hero-kicker { font-size: 12px; opacity: 0.8; letter-spacing: 0.2em; margin-bottom: 12px; }
.ct-hero-h { font-size: 40px; font-weight: 700; letter-spacing: -0.02em; margin-bottom: 12px; }
.ct-hero-sub { font-size: 15px; opacity: 0.9; margin-bottom: 24px; }
.ct-hero-btn { background: #fff; color: var(--ink-900); padding: 12px 24px; border-radius: var(--r-md); font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
.ct-hero-glyph { position: absolute; right: 56px; font-size: 160px; opacity: 0.15; pointer-events: none; }
.ct-hero-dots { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); display: flex; gap: 6px; }
.ct-hero-dots button { width: 8px; height: 8px; border-radius: 4px; background: rgba(255,255,255,0.5); transition: all .3s ease; }
.ct-hero-dots button.is-active { width: 24px; background: #fff; }
.ct-hero-side { display: grid; grid-template-rows: 1fr 1fr; gap: 12px; }
/* 輪播大圖 行動版(2026-10-24 修:桌機 16:5.5 在手機只剩約 120px 高,40px 標題被切、副標與按鈕擠出框外)→ 平板 16:7、手機 16:9 並等比縮字 */
@media (max-width: 1024px) {
  .ct-hero-stage { aspect-ratio: 16 / 7; }
  .ct-hero-slide { padding: 0 36px; }
  .ct-hero-h { font-size: 30px; }
  .ct-hero-glyph { right: 32px; font-size: 120px; }
}
@media (max-width: 768px) {
  .ct-hero { margin-top: 12px; }
  .ct-hero-stage { aspect-ratio: 16 / 9; }
  .ct-hero-slide { padding: 0 20px 18px; }
  .ct-hero-slide > div:first-child { max-width: 82%; min-width: 0; }
  .ct-hero-kicker { font-size: 10px; letter-spacing: .12em; margin-bottom: 6px; }
  .ct-hero-h { font-size: 22px; line-height: 1.3; margin-bottom: 6px; overflow-wrap: anywhere; }
  .ct-hero-sub { font-size: 12.5px; line-height: 1.45; margin-bottom: 12px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .ct-hero-btn { padding: 8px 14px; font-size: 13px; }
  .ct-hero-glyph { right: 12px; font-size: 84px; }
  .ct-hero-dots { bottom: 9px; }
  .ct-hero-dots button { width: 6px; height: 6px; } .ct-hero-dots button.is-active { width: 18px; }
}
@media (max-width: 380px) { .ct-hero-h { font-size: 20px; } .ct-hero-slide { padding: 0 16px 18px; } }
.ct-sidecard {
  padding: 20px; display: flex; align-items: center; gap: 16px;
  border-radius: var(--r-lg); background: #fff; box-shadow: var(--shadow-sm);
}
.ct-sidecard.tone-brand { background: var(--brand-50); }
.ct-sidecard.tone-hot   { background: var(--hot-bg); }
.ct-sidecard-ic { width: 48px; height: 48px; border-radius: var(--r-md); color: #fff; display: grid; place-items: center; flex-shrink: 0; }
.ct-sidecard.tone-brand .ct-sidecard-ic { background: var(--brand-500); }
.ct-sidecard.tone-hot   .ct-sidecard-ic { background: var(--hot); }
.ct-sidecard-t { font-size: 14px; font-weight: 600; }
.ct-sidecard-d { font-size: 12px; }
.ct-sidecard.tone-brand .ct-sidecard-d { color: var(--brand-700); }
.ct-sidecard.tone-hot   .ct-sidecard-d { color: var(--hot); }

/* === 首頁分類九宮格 === */
.ct-home-cats { margin-top: 24px; padding: 20px 24px; }
.ct-home-cats-grid { display: grid; grid-template-columns: repeat(10, 1fr); gap: 8px; }
.ct-home-cat { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 12px; border-radius: var(--r-md); }
.ct-home-cat:hover { background: var(--ink-100); }
.ct-home-cat .tile { width: 56px; height: 56px; border-radius: var(--r-lg); background: var(--brand-50); display: grid; place-items: center; font-size: 26px; overflow: hidden; }
.ct-home-cat .tile img { width: 100%; height: 100%; object-fit: cover; }
.ct-home-cat .nm { font-size: 12px; color: var(--ink-700); text-align: center; }
/* 平台分類格 行動版(2026-10-24 修:原本只有桌機 10 欄,手機被撐出畫面右邊、名稱斷成三行)→ 平板 6 欄、手機 4 欄換行,名稱最多兩行 */
@media (max-width: 1024px) { .ct-home-cats-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
@media (max-width: 768px) {
  .ct-home-cats { margin-top: 16px; padding: 14px 10px; }
  .ct-home-cats-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px 4px; }
  .ct-home-cat { padding: 6px 2px; gap: 6px; min-width: 0; }
  .ct-home-cat .tile { width: 48px; height: 48px; font-size: 22px; }
  .ct-home-cat .nm { font-size: 11.5px; line-height: 1.35; width: 100%; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; word-break: keep-all; overflow-wrap: anywhere; }
}
@media (max-width: 360px) { .ct-home-cat .tile { width: 42px; height: 42px; font-size: 20px; } .ct-home-cat .nm { font-size: 11px; } }

/* === 分類頁:小分類導覽區(商品上方) === */
.ct-subcat-nav { margin: 4px 0 22px; padding: 16px 18px; background: var(--ink-50, #f8fafc); border: 1px solid var(--ink-200); border-radius: var(--r-md); }
.ct-subcat-head { font-size: 14px; font-weight: 700; color: var(--ink-800); margin: 0 0 12px; }
.ct-subcat-chips { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; }
.ct-subcat-chip {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 13px; border: 1px solid var(--ink-200); border-radius: var(--r-md);
  background: #fff; transition: border-color .15s, box-shadow .15s, transform .15s;
}
.ct-subcat-chip .em {
  width: 40px; height: 40px; flex: 0 0 auto;
  display: grid; place-items: center; font-size: 20px; line-height: 1;
  background: var(--brand-50); border-radius: var(--r-lg);
}
.ct-subcat-chip .bd { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ct-subcat-chip .nm { font-size: 14px; font-weight: 600; color: var(--ink-800); line-height: 1.3; }
.ct-subcat-chip .ct { font-size: 12px; color: var(--ink-400); }
.ct-subcat-chip:hover { border-color: var(--brand-300); box-shadow: 0 4px 14px rgba(0,0,0,.07); transform: translateY(-1px); }
.ct-subcat-chip:hover .nm { color: var(--brand-700); }

/* === 限時搶購 === */
.ct-flash { margin-top: 24px; padding: 24px; }
.ct-flash-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.ct-flash-head-l { display: flex; align-items: center; gap: 12px; color: var(--hot); }
.ct-flash-head-l h2 { font-size: 20px; font-weight: 700; color: var(--ink-900); margin: 0; }
.ct-countdown { display: flex; align-items: center; gap: 4px; margin-left: 8px; }
.ct-countdown .lbl { font-size: 13px; color: var(--ink-500); }
.ct-countdown .seg { background: var(--ink-900); color: #fff; padding: 3px 8px; border-radius: 4px; font-size: 13px; font-weight: 600; min-width: 28px; text-align: center; }
.ct-countdown .colon { color: var(--ink-400); }
.ct-seemore { color: var(--brand-500); font-size: 13px; display: inline-flex; align-items: center; gap: 4px; }

/* === 推薦分頁 === */
.ct-tabs { display: flex; align-items: center; border-bottom: 2px solid var(--ink-200); margin: 24px 0 16px; }
.ct-tab { padding: 12px 20px; font-size: 15px; font-weight: 600; color: var(--ink-700); margin-bottom: -2px; border-bottom: 2px solid transparent; }
.ct-tab.is-active { color: var(--brand-500); border-bottom-color: var(--brand-500); }
.ct-tabpanel { display: none; }
.ct-tabpanel.is-active { display: block; }

/* WooCommerce 商品卡：折扣標籤 + 已售/評分 */
.woocommerce ul.products li.product { position: relative; }

/* === Buttons === */
.ct-btn,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce .button,
.woocommerce-page button.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 500;
  border-radius: var(--r-md);
  border: none;
  cursor: pointer;
  transition: all 120ms ease;
  text-decoration: none;
}
.ct-btn-primary,
.woocommerce button.button.alt,
.woocommerce a.button.alt,
.woocommerce #respond input#submit.alt,
.woocommerce #respond input#submit,
.woocommerce .checkout-button,
.woocommerce .single_add_to_cart_button {
  background: var(--brand-500) !important;
  color: white !important;
}
.ct-btn-primary:hover,
.woocommerce button.button.alt:hover,
.woocommerce .single_add_to_cart_button:hover {
  background: var(--brand-600) !important;
}
.ct-btn-secondary {
  background: white;
  color: var(--ink-900);
  border: 1px solid var(--ink-300);
}
.ct-btn-secondary:hover { border-color: var(--brand-500); color: var(--brand-500); }

/* === Cards / Products === */
.ct-card {
  background: white;
  border-radius: var(--r-md);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

/* WooCommerce 商品列表 — 緊湊 Grid 排列 */
.woocommerce ul.products,
.woocommerce-page ul.products {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(175px, 1fr));
  gap: 12px;
  margin: 0 0 24px !important;
}
.woocommerce ul.products::before,
.woocommerce ul.products::after { content: none !important; display: none !important; }
.woocommerce ul.products li.product,
.woocommerce-page ul.products li.product {
  width: auto !important;
  margin: 0 !important;
  float: none !important;
  background: white;
  border-radius: var(--r-md);
  box-shadow: var(--shadow-sm);
  padding: 9px;
  transition: transform 160ms ease, box-shadow 160ms ease;
  display: flex;            /* 2026-11-06 直排:加入購物車鈕固定貼卡片底部,同一排的按鈕對齊 */
  flex-direction: column;
}
.woocommerce ul.products li.product > .button,
.woocommerce ul.products li.product > .added_to_cart { margin-top: auto !important; align-self: flex-start; }
.woocommerce ul.products li.product > .button { margin-bottom: 0 !important; }
/* 已售/評分列:固定一行高(沒有資料也占位);已售靠右 */
.ct-loop-meta { display: flex; justify-content: space-between; align-items: center; gap: 8px; min-height: 16px; line-height: 16px; margin: 6px 0 10px; font-size: 11px; color: var(--ink-500); }
.ct-loop-meta .ct-loop-sold { margin-left: auto; }
.woocommerce ul.products li.product:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-size: 13px;
  font-weight: 400;
  color: var(--ink-900);
  line-height: 1.4;
  padding: 0 !important;   /* 2026-11-06 原本 padding 8px:被兩行截掉的第三行會露在下方留白裡、疊到價格 → 改用 margin */
  margin: 8px 0 !important;
  min-height: 2.8em;       /* 一律兩行高:一行標題的卡片價格也對齊 */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.woocommerce ul.products li.product .price {
  color: var(--brand-500) !important;
  font-family: var(--font-mono);
  font-weight: 700 !important;
  font-size: 18px !important;
}
.woocommerce ul.products li.product .price del {
  color: var(--ink-500);
  font-size: 12px;
  font-weight: 400 !important;
  margin-right: 6px;
}
.woocommerce ul.products li.product .onsale,
.woocommerce span.onsale {
  background: var(--hot) !important;
  color: white !important;
  border-radius: var(--r-sm) !important;
  font-size: 11px !important;
  font-weight: 600 !important;
  padding: 3px 6px !important;
  min-height: auto !important;
  line-height: 1.2 !important;
  top: 8px !important;
  right: 8px !important;
  left: auto !important;
  margin: 0 !important;
  position: absolute !important;
}

/* 單一商品頁 */
.woocommerce div.product .product_title {
  font-size: 22px;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: 12px;
}
.woocommerce div.product p.price,
.woocommerce div.product span.price {
  color: var(--brand-500) !important;
  font-family: var(--font-mono);
  font-size: 28px !important;
  font-weight: 700 !important;
}

/* 購物車 / 結帳 */
.woocommerce table.shop_table,
.woocommerce-page table.shop_table {
  border-radius: var(--r-md);
  border-collapse: separate;
  background: white;
  box-shadow: var(--shadow-sm);
  border: none;
}
.woocommerce table.shop_table th {
  background: var(--ink-50);
  color: var(--ink-700);
  font-weight: 500;
  font-size: 13px;
}
.woocommerce-cart .cart-collaterals .cart_totals,
.woocommerce-checkout #order_review_heading,
.woocommerce-checkout #order_review {
  background: white;
  padding: 20px;
  border-radius: var(--r-md);
  box-shadow: var(--shadow-sm);
}

/* ---- 購物車 行動版(2026-10-24):≤768 品項改卡片(圖左、名稱、單價、數量、小計);只寫在 media query 內 ---- */
@media (max-width: 768px) {
  body.woocommerce-cart main.ct-main .container > .ct-card { padding: 16px 12px !important; }
  .woocommerce-cart table.shop_table.cart { box-shadow: none; background: transparent; }
  .woocommerce-cart table.shop_table_responsive.cart thead { display: none; }
  .woocommerce-cart table.shop_table_responsive.cart tbody,
  .woocommerce-cart table.shop_table_responsive.cart tr.ctmv-ghead { display: block; }
  .woocommerce-cart table.shop_table_responsive.cart tr.ctmv-ghead td { border-radius: 10px 10px 0 0; }
  .woocommerce-cart table.shop_table_responsive.cart tr.cart_item {
    display: grid; grid-template-columns: 76px minmax(0, 1fr) auto; grid-template-areas: "th nm rm" "th pr pr" "th qt sub";
    gap: 4px 10px; align-items: center; padding: 12px; background: #fff; border-bottom: 1px solid var(--ink-100); }
  .woocommerce-cart table.shop_table_responsive.cart tr.cart_item td { display: block !important; padding: 0 !important; border: 0 !important; text-align: left !important; background: none !important; }
  .woocommerce-cart table.shop_table_responsive.cart tr.cart_item td::before { display: none !important; content: none !important; }
  .woocommerce-cart table.shop_table_responsive.cart td.product-thumbnail { grid-area: th; align-self: start; }
  .woocommerce-cart table.shop_table_responsive.cart td.product-thumbnail img { width: 76px !important; height: 76px; object-fit: cover; border-radius: 8px; border: 1px solid var(--ink-100); display: block; max-width: none; }
  .woocommerce-cart table.shop_table_responsive.cart td.product-name { grid-area: nm; font-size: 13.5px; line-height: 1.45; align-self: start; }
  .woocommerce-cart table.shop_table_responsive.cart td.product-name > a { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; color: var(--ink-900); }
  .woocommerce-cart table.shop_table_responsive.cart td.product-name dl.variation { margin: 3px 0 0; font-size: 12px; color: var(--ink-500); }
  .woocommerce-cart table.shop_table_responsive.cart td.product-remove { grid-area: rm; align-self: start; }
  .woocommerce-cart table.shop_table_responsive.cart td.product-remove a.remove { display: inline-flex !important; width: 32px; height: 32px; margin: -6px -6px 0 0; align-items: center; justify-content: center; border-radius: 50%; color: var(--ink-400, #9ca3af) !important; background: none !important; }
  .woocommerce-cart table.shop_table_responsive.cart td.product-price { grid-area: pr; font-size: 12.5px; color: var(--ink-500); }
  .woocommerce-cart table.shop_table_responsive.cart td.product-price::after { content: " / 件"; }
  .woocommerce-cart table.shop_table_responsive.cart td.product-quantity { grid-area: qt; }
  .woocommerce-cart table.shop_table_responsive.cart td.product-quantity .quantity button { width: 36px !important; height: 34px !important; }
  .woocommerce-cart table.shop_table_responsive.cart td.product-quantity .quantity input.qty { height: 34px !important; font-size: 16px; }
  .woocommerce-cart table.shop_table_responsive.cart td.product-subtotal { grid-area: sub; text-align: right !important; font-size: 15px; }
  /* 優惠券+更新列 */
  .woocommerce-cart table.shop_table_responsive.cart tr:last-child { display: block; }
  .woocommerce-cart table.shop_table_responsive.cart td.actions { display: block; padding: 14px 0 0 !important; background: none; border: 0; }
  .woocommerce-cart table.shop_table_responsive.cart td.actions::before { display: none !important; }
  .woocommerce-cart table.cart td.actions .coupon { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 0 0 10px; float: none; }
  .woocommerce-cart table.cart td.actions .coupon select { flex: 1 1 100%; width: 100%; font-size: 16px; }
  .woocommerce-cart table.cart td.actions .coupon .input-text { flex: 1 1 auto; width: auto !important; min-width: 0; font-size: 16px; padding: 10px 12px; margin: 0 !important; }
  .woocommerce-cart table.cart td.actions .coupon .button { flex: 0 0 auto; width: auto !important; margin: 0 !important; }
  .woocommerce-cart table.cart td.actions > .button[name="update_cart"] { width: 100%; }
  /* 購物車總計:運送方式改成左對齊選單 */
  .woocommerce-cart .cart-collaterals .cart_totals { width: 100%; float: none; padding: 16px 14px; }
  .woocommerce-cart .cart_totals h2 { font-size: 17px; margin: 0 0 10px; }
  .woocommerce-cart .cart_totals table.shop_table_responsive tr { display: block; }
  .woocommerce-cart .cart_totals table.shop_table_responsive tr:not(.woocommerce-shipping-totals) { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
  .woocommerce-cart .cart_totals table.shop_table_responsive tr:not(.woocommerce-shipping-totals) th { display: block; border: 0; padding: 10px 0; background: none; }
  .woocommerce-cart .cart_totals table.shop_table_responsive tr:not(.woocommerce-shipping-totals) td { display: block; border: 0; padding: 10px 0; text-align: right !important; }
  .woocommerce-cart .cart_totals table.shop_table_responsive tr td::before { display: none !important; }
  .woocommerce-cart .cart_totals tr.woocommerce-shipping-totals { border-top: 1px solid var(--ink-100); border-bottom: 1px solid var(--ink-100); padding: 10px 0; }
  .woocommerce-cart .cart_totals tr.woocommerce-shipping-totals th { display: block; width: auto !important; text-align: left; padding: 0 0 6px; border: 0; background: none; font-size: 13px; color: var(--ink-700); }
  .woocommerce-cart .cart_totals tr.woocommerce-shipping-totals td { display: block; text-align: left !important; padding: 0 !important; border: 0; }
  .woocommerce ul#shipping_method { margin: 0; padding: 0; }
  .woocommerce ul#shipping_method li { display: flex; align-items: flex-start; gap: 8px; text-align: left; margin: 0; padding: 9px 0; border-bottom: 1px dashed var(--ink-100); line-height: 1.45; font-size: 13.5px; }
  .woocommerce ul#shipping_method li:last-child { border-bottom: 0; }
  .woocommerce ul#shipping_method li input { margin: 3px 0 0 !important; flex: 0 0 auto; width: 18px; height: 18px; }
  .woocommerce ul#shipping_method li label { flex: 1; margin: 0; }
  .woocommerce-cart .cart_totals .woocommerce-shipping-destination,
  .woocommerce-cart .cart_totals .woocommerce-shipping-contents { text-align: left; font-size: 12px; color: var(--ink-500); margin: 6px 0 0; }
  .woocommerce-cart .cart_totals .woocommerce-shipping-calculator { text-align: left; }
  .woocommerce-cart .cart_totals tr.order-total th, .woocommerce-cart .cart_totals tr.order-total td { font-size: 16px; padding-top: 14px !important; }
  .woocommerce-cart .wc-proceed-to-checkout { padding: 12px 0 0; }
  .woocommerce-cart .wc-proceed-to-checkout a.checkout-button { display: block; width: 100%; padding: 15px !important; font-size: 16px !important; margin: 0 0 8px; }
}

/* ---- 購物車 桌機版重構(2026-10-25,使用者:「購物車重構一下」):左＝各賣場一張卡(店名列＋品項列)、右＝黏住的總計欄;只寫在 ≥769 ---- */
@media (min-width: 769px) {
  .ct-cart-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 24px; align-items: start; }
  .ct-cart-side { position: sticky; top: 16px; }
  .woocommerce-cart .ct-cart-side .cart-collaterals { width: 100%; }
  .woocommerce-cart .ct-cart-side .cart-collaterals .cart_totals { width: 100%; float: none; padding: 18px 18px 16px; border: 1px solid var(--ink-100); box-shadow: none; }
  /* 品項:表格改成卡片列 */
  .woocommerce-cart table.shop_table.cart { box-shadow: none; background: transparent; border: 0; border-radius: 0; }
  .woocommerce-cart table.shop_table.cart thead { display: none; }
  .woocommerce-cart table.shop_table.cart tbody { display: block; }
  .woocommerce-cart table.shop_table.cart tr.ctmv-ghead { display: block; }
  .woocommerce-cart table.shop_table.cart tr.ctmv-ghead:not(:first-child) { margin-top: 16px; }
  .woocommerce-cart table.shop_table.cart tr.ctmv-ghead td { display: block; padding: 12px 16px !important; background: var(--ink-50); border: 1px solid var(--ink-100) !important; border-bottom: 0 !important; border-top-width: 1px !important; border-radius: 10px 10px 0 0; }
  .woocommerce-cart .ctmv-gname { font-size: 15px; }
  .woocommerce-cart table.shop_table.cart tr.cart_item { display: grid; grid-template-columns: 72px minmax(0, 1fr) 96px 124px 104px 28px; grid-template-areas: "th nm pr qt sub rm"; align-items: center; column-gap: 16px; padding: 14px 16px; background: #fff; border: 1px solid var(--ink-100); border-top: 0; }
  .woocommerce-cart table.shop_table.cart tr.cart_item td { display: block; padding: 0 !important; border: 0 !important; background: none !important; text-align: left; }
  .woocommerce-cart table.shop_table.cart td.product-thumbnail { grid-area: th; }
  .woocommerce-cart table.shop_table.cart td.product-thumbnail img { width: 72px !important; height: 72px; object-fit: cover; border-radius: 8px; border: 1px solid var(--ink-100); display: block; max-width: none; }
  .woocommerce-cart table.shop_table.cart td.product-name { grid-area: nm; font-size: 14px; line-height: 1.5; min-width: 0; }
  .woocommerce-cart table.shop_table.cart td.product-name > a { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; color: var(--ink-900); }
  .woocommerce-cart table.shop_table.cart td.product-name dl.variation { margin: 4px 0 0; font-size: 12.5px; color: var(--ink-500); }
  .woocommerce-cart table.shop_table.cart td.product-price { grid-area: pr; text-align: right !important; font-size: 13px; color: var(--ink-500); }
  .woocommerce-cart table.shop_table.cart td.product-price::after { content: " / 件"; }
  .woocommerce-cart table.shop_table.cart td.product-quantity { grid-area: qt; justify-self: center; }
  .woocommerce-cart table.shop_table.cart td.product-subtotal { grid-area: sub; text-align: right !important; font-size: 15px; }
  .woocommerce-cart table.shop_table.cart td.product-remove { grid-area: rm; text-align: right !important; }
  .woocommerce-cart table.shop_table.cart td.product-remove a.remove { display: inline-flex !important; width: 28px; height: 28px; align-items: center; justify-content: center; border-radius: 50%; color: var(--ink-400, #9ca3af) !important; background: none !important; font-size: 18px !important; }
  .woocommerce-cart table.shop_table.cart td.product-remove a.remove:hover { background: var(--ink-50) !important; color: var(--ink-900) !important; }
  .woocommerce-cart .ct-ib-need { display: flex; width: max-content; }
  /* 每張賣場卡的最後一列收圓角:下一列是店名列或優惠券列 */
  .woocommerce-cart table.shop_table.cart tr.cart_item:has(+ tr.ctmv-ghead), .woocommerce-cart table.shop_table.cart tr.cart_item:has(+ tr:not(.cart_item):not(.ctmv-ghead)) { border-radius: 0 0 10px 10px; }
  /* 優惠券／更新購物車列 */
  .woocommerce-cart table.shop_table.cart tr:last-child { display: block; }
  .woocommerce-cart table.shop_table.cart td.actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 16px 0 0 !important; border: 0 !important; background: none; }
  .woocommerce-cart table.shop_table.cart td.actions .coupon { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; float: none; margin: 0; }
  .woocommerce-cart table.shop_table.cart td.actions .coupon .input-text { width: 200px !important; margin: 0 !important; padding: 8px 12px; }
  .woocommerce-cart table.shop_table.cart td.actions > .button[name="update_cart"] { margin-left: auto; }
  /* 右欄總計:直排(同手機版),運送方式選單不擠 */
  .woocommerce-cart .ct-cart-side .cart_totals h2 { font-size: 17px; margin: 0 0 8px; }
  .woocommerce-cart .ct-cart-side .cart_totals table.shop_table { box-shadow: none; border-radius: 0; }
  .woocommerce-cart .ct-cart-side .cart_totals table tr { display: block; }
  .woocommerce-cart .ct-cart-side .cart_totals table tr:not(.woocommerce-shipping-totals) { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
  .woocommerce-cart .ct-cart-side .cart_totals table tr:not(.woocommerce-shipping-totals) th { display: block; border: 0; padding: 10px 0; background: none; width: auto; }
  .woocommerce-cart .ct-cart-side .cart_totals table tr:not(.woocommerce-shipping-totals) td { display: block; border: 0; padding: 10px 0; text-align: right !important; }
  .woocommerce-cart .ct-cart-side .cart_totals tr.woocommerce-shipping-totals { border-top: 1px solid var(--ink-100); padding: 10px 0; }
  .woocommerce-cart .ct-cart-side .cart_totals tr.woocommerce-shipping-totals th { display: block; width: auto !important; text-align: left; padding: 0 0 6px; border: 0; background: none; font-size: 13px; color: var(--ink-700); }
  .woocommerce-cart .ct-cart-side .cart_totals tr.woocommerce-shipping-totals td { display: block; text-align: left !important; padding: 0 !important; border: 0; }
  .woocommerce-cart .ct-cart-side ul#shipping_method { margin: 0; padding: 0; }
  .woocommerce-cart .ct-cart-side ul#shipping_method li { display: flex; align-items: flex-start; gap: 8px; margin: 0; padding: 6px 0; line-height: 1.45; font-size: 13px; }
  .woocommerce-cart .ct-cart-side ul#shipping_method li input { margin: 2px 0 0 !important; flex: 0 0 auto; }
  .woocommerce-cart .ct-cart-side ul#shipping_method li label { flex: 1; margin: 0; }
  .woocommerce-cart .ct-cart-side .woocommerce-shipping-destination, .woocommerce-cart .ct-cart-side .woocommerce-shipping-contents { font-size: 12px; color: var(--ink-500); margin: 6px 0 0; }
  .woocommerce-cart .ct-cart-side .cart_totals tr.order-total { border-top: 1px solid var(--ink-100); }
  .woocommerce-cart .ct-cart-side .cart_totals tr.order-total th, .woocommerce-cart .ct-cart-side .cart_totals tr.order-total td { font-size: 17px; padding-top: 14px !important; }
  .woocommerce-cart .ct-cart-side .wc-proceed-to-checkout { padding: 12px 0 0; }
  .woocommerce-cart .ct-cart-side .wc-proceed-to-checkout a.checkout-button { display: block; width: 100%; padding: 14px !important; font-size: 16px !important; margin: 0 0 8px; }
}
@media (min-width: 769px) and (max-width: 1080px) {
  .ct-cart-layout { grid-template-columns: minmax(0, 1fr) 300px; gap: 18px; }
  .woocommerce-cart table.shop_table.cart tr.cart_item { grid-template-columns: 60px minmax(0, 1fr) 112px 88px 24px; grid-template-areas: "th nm qt sub rm"; column-gap: 12px; }
  .woocommerce-cart table.shop_table.cart td.product-price { display: none !important; }
  .woocommerce-cart table.shop_table.cart td.product-thumbnail img { width: 60px !important; height: 60px; }
}

/* ---- 商品頁 行動版(2026-10-24):≤768;只寫在 media query 內 ---- */
@media (max-width: 768px) {
  .single-product main.ct-main .container { padding-left: 12px; padding-right: 12px; }
  .woocommerce div.product div.images, .woocommerce div.product div.summary { width: 100% !important; float: none !important; margin-bottom: 16px; }
  .woocommerce div.product div.images .flex-control-thumbs { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin-top: 8px; }
  .woocommerce div.product div.images .flex-control-thumbs::-webkit-scrollbar { display: none; }
  .woocommerce div.product div.images .flex-control-thumbs li { flex: 0 0 56px; width: 56px !important; float: none !important; margin: 0 !important; }
  .woocommerce div.product div.images .flex-control-thumbs li img { border-radius: 6px; border: 1px solid var(--ink-100); }
  .woocommerce div.product .product_title { font-size: 18px; line-height: 1.45; margin-bottom: 8px; }
  .woocommerce div.product p.price, .woocommerce div.product span.price { font-size: 24px !important; }
  /* 規格選擇 */
  .woocommerce div.product form.cart table.variations, .woocommerce div.product form.cart table.variations tbody,
  .woocommerce div.product form.cart table.variations tr, .woocommerce div.product form.cart table.variations th,
  .woocommerce div.product form.cart table.variations td { display: block; width: 100%; padding: 0; text-align: left; }
  .woocommerce div.product form.cart table.variations th { margin: 4px 0 6px; font-size: 13px; }
  .woocommerce div.product form.cart table.variations td { margin-bottom: 10px; }
  .woocommerce div.product form.cart table.variations select { width: 100%; font-size: 16px; min-height: 42px; }
  /* 數量+加入購物車同一列、加購安裝整行 */
  .woocommerce div.product form.cart .woocommerce-variation-add-to-cart,
  .woocommerce div.product form.cart:not(.variations_form) { display: flex; flex-wrap: wrap; align-items: stretch; gap: 10px; }
  .woocommerce div.product form.cart .quantity { flex: 0 0 auto; margin: 0 !important; }
  .woocommerce div.product form.cart .quantity button { width: 38px !important; height: 44px !important; }
  .woocommerce div.product form.cart .quantity input.qty { height: 44px !important; font-size: 16px; }
  .woocommerce div.product form.cart .single_add_to_cart_button { flex: 1 1 auto; min-height: 46px; margin: 0 !important; font-size: 16px !important; float: none !important; }
  .woocommerce div.product form.cart .ct-ib-addon { flex: 1 1 100%; }
  .woocommerce div.product form.cart .ct-ib-addon-link { display: block; text-align: center; padding: 11px; }
  /* 頁籤:可橫向滑動的底線頁籤 */
  .woocommerce div.product .woocommerce-tabs { clear: both; }
  .woocommerce div.product .woocommerce-tabs ul.tabs { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; padding: 0 !important; margin: 0 0 14px !important; border-bottom: 1px solid var(--ink-200); }
  .woocommerce div.product .woocommerce-tabs ul.tabs::-webkit-scrollbar { display: none; }
  .woocommerce div.product .woocommerce-tabs ul.tabs::before, .woocommerce div.product .woocommerce-tabs ul.tabs li::before, .woocommerce div.product .woocommerce-tabs ul.tabs li::after { display: none !important; }
  .woocommerce div.product .woocommerce-tabs ul.tabs li { flex: 0 0 auto; margin: 0 !important; padding: 0 !important; border: 0 !important; border-radius: 0 !important; background: none !important; }
  .woocommerce div.product .woocommerce-tabs ul.tabs li a { display: block; padding: 10px 12px !important; font-size: 14.5px; white-space: nowrap; color: var(--ink-500); border-bottom: 2px solid transparent; margin-bottom: -1px; }
  .woocommerce div.product .woocommerce-tabs ul.tabs li.active a { color: var(--ink-900); font-weight: 700; border-bottom-color: var(--brand-500); }
  .woocommerce div.product .woocommerce-tabs .panel { font-size: 14px; line-height: 1.7; overflow-wrap: anywhere; }
  .woocommerce div.product .woocommerce-tabs .panel h2 { font-size: 17px; }
  .woocommerce div.product .woocommerce-tabs .panel img { max-width: 100%; height: auto; }
  .woocommerce div.product .woocommerce-tabs .panel table { display: block; overflow-x: auto; max-width: 100%; }
  /* 相關商品/追加銷售:兩欄 */
  .woocommerce .related ul.products, .woocommerce .upsells ul.products { display: grid !important; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .woocommerce .related ul.products li.product, .woocommerce .upsells ul.products li.product { width: auto !important; float: none !important; margin: 0 !important; }
  .woocommerce .related > h2, .woocommerce .upsells > h2 { font-size: 17px; }
  /* 底部購買列 */
  .ct-pbar { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 9995; gap: 8px; align-items: stretch; background: #fff; border-top: 1px solid var(--ink-200); box-shadow: 0 -4px 14px rgba(0,0,0,.08); padding: 8px 12px calc(8px + env(safe-area-inset-bottom, 0px)); transition: transform .2s ease; }
  .ct-pbar.is-off { transform: translateY(110%); }
  .ct-pbar-chat { flex: 0 0 64px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; background: none; border: 1px solid var(--ink-200); border-radius: 10px; color: var(--ink-700); font-size: 11px; cursor: pointer; }
  .ct-pbar-buy { flex: 1 1 auto; min-height: 46px; border: 0; border-radius: 10px; background: var(--brand-500); color: #fff; font-size: 16px; font-weight: 700; cursor: pointer; }
  .ct-pbar-buy[disabled] { background: var(--ink-300); }
  body.ct-has-pbar { padding-bottom: 70px; }
  body.ct-has-pbar #ctcw-btn { display: none !important; } /* 聊聊已在購買列 */
  body.ct-has-pbar #ctis-fab { bottom: calc(80px + env(safe-area-inset-bottom, 0px)) !important; }
}
@media (min-width: 769px) { .ct-pbar { display: none !important; } }

/* Form fields */
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select {
  padding: 10px 14px;
  border: 1px solid var(--ink-300);
  border-radius: var(--r-md);
  font-size: 14px;
  font-family: inherit;
}
.woocommerce form .form-row input.input-text:focus,
.woocommerce form .form-row textarea:focus {
  border-color: var(--brand-500);
  outline: 2px solid var(--brand-100);
}

/* Footer */
.ct-footer {
  background: white;
  border-top: 1px solid var(--ink-200);
  padding: 48px 0 24px;
  margin-top: 48px;
}
.ct-footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr;
  gap: 32px;
}
.ct-footer h4 {
  font-size: 13px;
  font-weight: 600;
  margin: 0 0 16px;
  color: var(--ink-900);
}
.ct-footer ul { list-style: none; padding: 0; margin: 0; }
.ct-footer li { font-size: 13px; color: var(--ink-700); padding: 4px 0; }
.ct-footer li a:hover { color: var(--brand-500); }
.ct-footer-bottom {
  border-top: 1px solid var(--ink-200);
  margin-top: 32px;
  padding-top: 24px;
  text-align: center;
  font-size: 12px;
  color: var(--ink-500);
}

/* Responsive */
@media (max-width: 768px) {
  .ct-topbar { display: none; }
  /* 頁尾連結 行動版(2026-10-24 修:原本手機整塊 .ct-footer-grid 藏掉,商城與店家頁底部只剩版權列,使用者以為選單跑掉)→ 商標一列、連結兩欄、公司資訊一列 */
  .ct-footer { padding: 28px 0 calc(16px + env(safe-area-inset-bottom, 0px)); margin-top: 32px; }
  .ct-footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 16px; }
  .ct-footer-grid > div:first-child, .ct-footer-grid > div:last-child { grid-column: 1 / -1; }
  .ct-footer h4 { margin-bottom: 8px; }
  .ct-footer li { padding: 5px 0; overflow-wrap: anywhere; }
  .ct-footer-bottom { margin-top: 20px; padding-top: 14px; }
  .ct-header { padding: 8px 0; height: auto; }
  /* 2026-10-22 修:桌機 .ct-header-main 是固定高度,手機換行後溢出被分類列蓋住;
     手機改自動高度、三段排版=商標+動作鈕一列、搜尋列整行第二列(order 要下在 flex 子項 .ct-search-wrap,不是內層表單) */
  .ct-header .ct-header-main { height: auto; flex-wrap: wrap; gap: 8px 10px; padding: 2px 16px 6px; box-sizing: border-box; } /* 左右 16px 別歸零(會讓商標與搜尋框貼齊螢幕邊緣) */
  .ct-search { box-sizing: border-box; width: 100%; }
  .ct-logo { order: 1; flex: 1 1 auto; min-width: 0; }
  .ct-logo-img { height: 32px !important; max-height: 32px; }
  .ct-header-actions { order: 2; margin-left: auto; gap: 2px; }
  .ct-iconbtn { padding: 8px; }
  .ct-member { padding: 4px 8px 4px 4px; font-size: 12px; gap: 6px; }
  .ct-member .av { width: 24px; height: 24px; font-size: 11px; }
  .ct-search-wrap { order: 3; flex: 1 1 100%; max-width: none; }
  .ct-search input { font-size: 16px; padding: 9px 12px; } /* 16px 防 iOS 聚焦縮放 */
  .ct-search button { padding: 9px 16px; }
  .ct-hotwords { display: none; }
}
@media (max-width: 480px) {
  /* 窄手機:會員中心只留頭像圓鈕,讓商標與動作鈕同一列 */
  .ct-logo span { font-size: 18px; }
  .ct-header-actions { gap: 0; }
  .ct-iconbtn { padding: 7px; }
  .ct-member { padding: 3px; border-radius: 50%; border-color: transparent; gap: 0; }
  .ct-member > span:not(.av) { display: none; }
  .ct-member .av { width: 30px; height: 30px; font-size: 12px; }
}

/* ============================================================
   品牌官網 — Editorial 編輯式留白（與商城共用 token）
   ============================================================ */
html { scroll-behavior: smooth; }
.serif { font-family: "Noto Serif TC", "Songti TC", serif; }
/* body 前綴提高權重：Elementor kit CSS 較晚載入且把 body 背景設成灰色,官網頁一律壓回白底 */
body.ct-official { background: #fff; color: var(--ink-900); }
.ct-official [id^="off-"] { scroll-margin-top: 100px; }
.off-wrap { max-width: 1280px; margin: 0 auto; padding: 0 60px; }
.off-imgph {
  background: repeating-linear-gradient(45deg, var(--ink-100) 0 8px, var(--ink-50) 8px 16px);
  display: grid; place-items: center; color: var(--ink-500);
  font-family: var(--font-mono); font-size: 12px; border-radius: 2px; margin-top: 64px;
}
.off-ic { width: 26px; height: 26px; }

/* Header */
.off-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,0.92); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--ink-200);
}
.off-header-inner { height: 84px; display: flex; align-items: center; justify-content: space-between; }
.off-logo { display: inline-flex; align-items: center; gap: 10px; }
.off-logo-img { height: 36px; width: auto; display: block; }
.off-logo .serif { font-size: 26px; font-weight: 600; letter-spacing: 0.04em; color: var(--ink-900); }
.off-logo-sub { font-size: 13px; color: var(--ink-500); }
.off-tw { font-size: 12px; color: var(--brand-600); letter-spacing: 0.1em; }
.off-nav { display: flex; gap: 30px; }
.off-nav a { font-size: 14px; color: var(--ink-700); letter-spacing: 0.02em; }
.off-nav a:hover { color: var(--ink-900); }
.off-header-right { display: flex; align-items: center; gap: 28px; }
.off-toggle { display: inline-flex; gap: 22px; }
.off-toggle a { font-size: 13px; letter-spacing: 0.04em; color: var(--ink-400); padding-bottom: 6px; position: relative; }
.off-toggle a.is-active { color: var(--ink-900); font-weight: 600; }
.off-toggle a.is-active::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1.5px; background: var(--brand-600); }
.off-enter { font-size: 13px; color: var(--ink-900); border-bottom: 1px solid var(--ink-900); padding-bottom: 2px; white-space: nowrap; }

/* Hero */
.off-hero { padding-top: 96px; }
.off-kicker { font-size: 12px; letter-spacing: 0.22em; color: var(--ink-500); text-transform: uppercase; }
.off-hero-h { font-size: 88px; font-weight: 400; line-height: 1.08; letter-spacing: 0.01em; margin: 28px 0 0; }
.off-hero-row { display: flex; justify-content: space-between; align-items: flex-end; margin-top: 48px; gap: 64px; }
.off-lead { font-size: 18px; line-height: 1.9; color: var(--ink-700); max-width: 540px; font-weight: 300; }
.off-textlink { font-size: 14px; color: var(--ink-900); white-space: nowrap; border-bottom: 1px solid var(--ink-900); padding-bottom: 4px; display: inline-flex; align-items: center; gap: 8px; }
.off-textlink .off-ic { width: 14px; height: 14px; }

/* Stats */
.off-stats { display: grid; grid-template-columns: repeat(4,1fr); border-top: 1px solid var(--ink-200); border-bottom: 1px solid var(--ink-200); }
.off-stat { padding: 40px 0; }
.off-stat + .off-stat { border-left: 1px solid var(--ink-200); padding-left: 40px; }
.off-stat-n { font-size: 52px; font-weight: 400; letter-spacing: -0.01em; }
.off-stat-n span { font-size: 22px; color: var(--brand-600); margin-left: 2px; }
.off-stat-l { font-size: 14px; color: var(--ink-500); margin-top: 10px; letter-spacing: 0.04em; }

/* Section heads */
.off-secnum { display: flex; align-items: baseline; gap: 14px; }
.off-num { font-size: 13px; color: var(--brand-600); }
.off-row-between { display: flex; justify-content: space-between; align-items: baseline; }
.off-2col { display: grid; gap: 88px; margin-top: 44px; align-items: start; }
.off-h2 { font-size: 40px; font-weight: 400; line-height: 1.4; }
.off-h2-lg { font-size: 44px; font-weight: 400; line-height: 1.3; }
.off-body { font-size: 16px; line-height: 2; color: var(--ink-700); font-weight: 300; }
.off-miles { margin-top: 40px; }
.off-mile { display: flex; gap: 28px; padding: 20px 0; border-top: 1px solid var(--ink-200); }
.off-year { font-size: 14px; color: var(--brand-600); width: 52px; flex-shrink: 0; }
.off-mile span:last-child { font-size: 15px; line-height: 1.7; color: var(--ink-700); }

/* News */
.off-news { margin-top: 36px; }
.off-news-row { display: grid; grid-template-columns: 130px 90px 1fr 24px; gap: 28px; align-items: center; padding: 26px 0; border-top: 1px solid var(--ink-200); }
.off-news-row:hover { background: var(--ink-50); }
.off-news-row:hover .off-news-title { color: var(--brand-700); }
.off-news-date { font-size: 13px; color: var(--ink-500); }
.off-news-tag { font-size: 12px; color: var(--brand-700); letter-spacing: 0.06em; }
.off-news-title { font-size: 19px; color: var(--ink-900); line-height: 1.5; }
.off-news-row .off-ic { width: 16px; height: 16px; }

/* Services */
.off-svc { display: grid; grid-template-columns: repeat(4,1fr); margin-top: 40px; }
.off-svc-item { padding: 32px 28px 32px 0; border-top: 1.5px solid var(--ink-900); }
.off-svc-t { font-size: 22px; font-weight: 500; margin: 20px 0 12px; }
.off-svc-d { font-size: 14px; line-height: 1.8; color: var(--ink-500); font-weight: 300; }
.off-cta-row { margin-top: 44px; display: flex; gap: 16px; flex-wrap: wrap; }
.off-btn-dark { font-size: 14px; color: #fff; background: var(--ink-900); padding: 14px 28px; border-radius: 2px; }
.off-btn-line { font-size: 14px; color: var(--ink-900); border: 1px solid var(--ink-900); padding: 14px 28px; border-radius: 2px; }

/* Catalog */
.off-catalog-lead { font-size: 24px; font-weight: 400; margin: 20px 0 40px; max-width: 620px; line-height: 1.5; }
.off-catgrid { display: grid; grid-template-columns: repeat(5,1fr); border-top: 1px solid var(--ink-200); border-left: 1px solid var(--ink-200); }
.off-cat { padding: 30px 24px; border-right: 1px solid var(--ink-200); border-bottom: 1px solid var(--ink-200); display: flex; flex-direction: column; gap: 16px; min-height: 132px; justify-content: space-between; }
.off-cat:hover { background: var(--ink-50); }
.off-cat-ic { width: 44px; height: 44px; border-radius: 50%; background: var(--brand-50); color: var(--brand-700); display: grid; place-items: center; font-size: 18px; font-weight: 600; }
.off-cat-name { font-size: 15px; color: var(--ink-900); display: flex; align-items: center; justify-content: space-between; }
.off-cat-name .off-ic { width: 13px; height: 13px; }
.off-cat-code { font-size: 12px; color: var(--brand-600); letter-spacing: 0.1em; }

/* Clients / 合作實績 */
.off-clients { display: grid; grid-template-columns: repeat(4,1fr); }
.off-client { padding: 28px 28px 28px 0; border-top: 1px solid var(--ink-200); }
.off-client-t { font-size: 16px; font-weight: 600; color: var(--ink-900); margin: 0 0 10px; }
.off-client-d { font-size: 14px; line-height: 1.7; color: var(--ink-500); font-weight: 300; margin: 0; }
.off-clients-note { font-size: 13px; color: var(--ink-400); margin-top: 28px; letter-spacing: 0.02em; }

/* 車輛管理系統 — 深色橫幅 + 客戶登入 */
.off-login { font-size: 13px; color: var(--ink-500); white-space: nowrap; }
.off-login:hover { color: var(--ink-900); }
.off-vms { background: var(--ink-900); color: #fff; margin-top: 8px; }
.off-vms .off-kicker { color: rgba(255,255,255,0.55); }
.off-vms-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 64px; margin-top: 28px; align-items: center; }
.off-vms-num { font-size: 13px; color: var(--brand-300); }
.off-vms-h { color: #fff; font-size: 40px; line-height: 1.35; margin: 12px 0 20px; }
.off-vms-lead { font-size: 16px; line-height: 1.9; color: rgba(255,255,255,0.75); max-width: 520px; font-weight: 300; }
.off-vms-cta { display: flex; gap: 16px; margin-top: 32px; flex-wrap: wrap; }
.off-btn-white { font-size: 14px; color: var(--ink-900); background: #fff; padding: 14px 28px; border-radius: 2px; font-weight: 500; display: inline-flex; align-items: center; gap: 8px; }
.off-btn-ghostw { font-size: 14px; color: #fff; border: 1px solid rgba(255,255,255,0.5); padding: 14px 28px; border-radius: 2px; }
.off-vms-note { font-size: 12.5px; color: rgba(255,255,255,0.45); margin-top: 16px; }
.off-feats { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid rgba(255,255,255,0.15); border-left: 1px solid rgba(255,255,255,0.15); }
.off-feat { padding: 22px 20px; border-right: 1px solid rgba(255,255,255,0.15); border-bottom: 1px solid rgba(255,255,255,0.15); display: flex; align-items: center; gap: 12px; font-size: 14.5px; color: rgba(255,255,255,0.9); }
.off-feat .off-ic { width: 16px; height: 16px; color: var(--brand-300); flex-shrink: 0; }

/* Contact */
.off-contact-list { display: flex; flex-direction: column; gap: 18px; }
.off-contact-item { font-size: 15px; color: var(--ink-700); border-top: 1px solid var(--ink-200); padding-top: 16px; }

/* Footer */
.off-footer { background: #fff; border-top: 1px solid var(--ink-200); }
.off-footer-inner { padding: 48px 60px; display: flex; justify-content: space-between; align-items: center; }
.off-footer .off-logo .serif { font-size: 20px; }
.off-footer .off-logo-sub { font-size: 11px; }
.off-footer .off-logo-img { height: 28px; }
.off-footer-links { display: flex; gap: 28px; font-size: 13px; color: var(--ink-500); flex-wrap: wrap; }
.off-footer-links a:hover { color: var(--brand-600); }
.off-footer-line { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--ink-500); line-height: 1.5; flex: 0 0 auto; }
.off-footer-line img { width: 56px; height: 56px; border: 1px solid var(--ink-200); border-radius: 4px; background: #fff; padding: 3px; box-sizing: border-box; }
.off-footer-line:hover { color: var(--brand-600); }
.off-copy { font-size: 12px; color: var(--ink-400); }

/* 商城頂列的「品牌官網 / 購物商城」切換 */
.ct-mode-toggle { display: inline-flex; gap: 16px; align-items: center; }
.ct-mode-toggle a { color: rgba(255,255,255,0.55); padding: 0 0 4px; position: relative; }
.ct-mode-toggle a.is-active { color: #fff; font-weight: 600; }
.ct-mode-toggle a.is-active::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1.5px; background: var(--brand-300); }

@media (max-width: 900px) {
  .off-wrap { padding: 0 24px; }
  .off-footer-inner { padding: 36px 24px; }
  .off-nav { display: none; }
  .off-hero-h { font-size: 52px; }
  .off-hero-row { flex-direction: column; align-items: flex-start; gap: 28px; }
  .off-2col { grid-template-columns: 1fr !important; gap: 28px; }
  .off-stats, .off-svc { grid-template-columns: 1fr; }
  .off-clients { grid-template-columns: 1fr 1fr; }
  .off-vms-grid { grid-template-columns: 1fr; gap: 36px; }
  .off-stat + .off-stat { border-left: none; padding-left: 0; border-top: 1px solid var(--ink-200); }
  .off-svc-item { border-top: 1.5px solid var(--ink-900); }
  .off-catgrid { grid-template-columns: repeat(2,1fr); }
  .off-news-row { grid-template-columns: 1fr; gap: 6px; }
  .off-news-row .off-ic { display: none; }
  .off-footer-inner { flex-direction: column; gap: 16px; align-items: flex-start; }
}

/* ============================================
   多頁官網（首頁區塊卡 / 子頁 / 型錄翻書 / 頁底導覽）
   ============================================ */

/* 導覽 active */
.off-nav a.is-active { color: var(--ink-900); font-weight: 600; border-bottom: 1.5px solid var(--brand-500); padding-bottom: 3px; }

/* 子頁標題 */
.off-pagehead-h { font-size: 60px; font-weight: 400; line-height: 1.18; letter-spacing: 0.01em; margin: 24px 0 0; font-family: "Noto Serif TC", serif; }

/* 首頁：區塊導引卡 */
.off-secgrid { display: grid; grid-template-columns: repeat(3,1fr); border-top: 1px solid var(--ink-200); border-left: 1px solid var(--ink-200); margin-top: 32px; }
.off-seccard { padding: 36px 32px; border-right: 1px solid var(--ink-200); border-bottom: 1px solid var(--ink-200); display: flex; flex-direction: column; gap: 16px; min-height: 220px; justify-content: space-between; transition: background .15s ease; }
.off-seccard:hover { background: var(--ink-50); }
.off-seccard-k { font-size: 12px; color: var(--brand-600); letter-spacing: 0.1em; display: block; }
.off-seccard-t { font-size: 28px; font-weight: 400; color: var(--ink-900); margin: 16px 0 12px; }
.off-seccard-d { font-size: 14px; line-height: 1.8; color: var(--ink-500); font-weight: 300; margin: 0; }
.off-seccard-arrow { color: var(--ink-900); }
.off-seccard-arrow .off-ic { width: 18px; height: 18px; }
.off-seccard:hover .off-seccard-arrow { transform: translateX(4px); }
.off-seccard-arrow { transition: transform .2s ease; }

/* 頁底：上一頁 / 下一頁 */
.off-pagenav { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; border-top: 1px solid var(--ink-200); padding-top: 28px; padding-bottom: 56px; }
.off-pagenav-a { display: inline-flex; align-items: center; gap: 10px; font-size: 16px; color: var(--ink-900); }
.off-pagenav-a:hover { color: var(--brand-700); }
.off-pagenav-a .off-ic { width: 16px; height: 16px; }
.off-pagenav-next { margin-left: auto; }

/* CTA 深色橫幅（型錄 / 合作實績共用） */
.off-ctaband { margin-top: 8px; margin-bottom: 56px; }
.off-ctaband-inner { padding-top: 56px; padding-bottom: 56px; display: flex; justify-content: space-between; align-items: center; gap: 32px; flex-wrap: wrap; }

/* 型錄：翻書清單 — 4 列封面（點封面才在燈箱開整本） */
.off-books { display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px 24px; }
.off-book { border-top: 1.5px solid var(--ink-900); padding-top: 16px; }
.off-book-head { display: flex; flex-direction: column; gap: 4px; }
.off-book-head-l { display: flex; align-items: baseline; gap: 10px; }
.off-book-t { font-size: 18px; font-weight: 500; color: var(--ink-900); margin: 0; line-height: 1.4; }
.off-book-meta { font-size: 11px; color: var(--ink-500); letter-spacing: 0.04em; }
.off-book-lock { font-size: 10.5px; color: var(--ink-700); letter-spacing: 0.06em; border: 1px solid var(--ink-300); padding: 1px 6px; white-space: nowrap; align-self: center; } /* 會員限定型錄(只有登入的人看得到這個標) */
.off-book-stage { margin-top: 14px; background: var(--ink-50); border: 1px solid var(--ink-200); border-radius: 2px; padding: 10px; min-height: 220px; display: grid; place-items: center; }
.off-book-stage img { max-width: 100%; height: auto; cursor: pointer; display: block; }
.off-book-stage .df-container, .off-book-stage ._df_book, .off-book-stage .dflip-container,
.off-book-stage .fb3d-thumbnail-lightbox-mode, .off-book-stage [class*="thumbnail"] { margin: 0 auto; max-width: 100%; cursor: pointer; }
.off-book-fallback { min-height: 200px; display: grid; place-items: center; text-align: center; color: var(--ink-500); font-size: 13px; line-height: 1.8; }
/* 型錄頁 Elementor 容器版書櫃：容器掛 class off-books-el，直接子元素（各 [ct_catalog_book] 短碼元件）成為格子。
   !important 是為了壓過 Elementor .e-con 的 flex/gap 內建樣式；斷點與 .off-books 一致。 */
.off-books-el { box-sizing: border-box; display: grid !important; grid-template-columns: repeat(4, 1fr) !important; gap: 40px 24px !important; max-width: 1280px !important; margin: 0 auto !important; padding: 48px 60px 72px !important; }
.off-books-el .elementor-widget-shortcode, .off-books-el .elementor-widget-container { height: 100%; }
/* 2026-11-03 起 Elementor 只放一個 [ct_catalog_books] 元件:元件外框與 .ct-books-auto 都 display:contents,每本型錄照樣是 .off-books-el 的格子 */
.off-books-el .elementor-element:has(.ct-books-auto), .off-books-el .elementor-element:has(.ct-books-auto) .elementor-widget-container,
.off-books-el .elementor-shortcode:has(.ct-books-auto), .off-books-el .ct-books-auto { display: contents !important; }
.off-books-empty { grid-column: 1 / -1; color: var(--ink-500); font-size: 14px; text-align: center; padding: 24px 0; }
@media (min-width: 901px) and (max-width: 1180px) { .off-books-el { grid-template-columns: repeat(3, 1fr) !important; } }
@media (max-width: 900px) { .off-books-el { grid-template-columns: repeat(2, 1fr) !important; padding-left: 24px !important; padding-right: 24px !important; } }
@media (max-width: 480px) { .off-books-el { grid-template-columns: 1fr !important; } }
/* 禁止下載型錄：隱藏 3D FlipBook 工具列的「下載(cmdSave)」按鈕 */
.cmd.cmdSave, a.cmdSave, .cmdSave,
li:has(> .cmdSave), li:has(> a.cmdSave) { display: none !important; }

/* 聯絡：資訊格 */
.off-contact-grid { display: flex; flex-direction: column; }
.off-contact-row { border-top: 1px solid var(--ink-200); padding: 16px 0; }
.off-contact-k { font-size: 11px; color: var(--brand-600); letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 6px; }
.off-contact-v { font-size: 15px; color: var(--ink-800); }
.off-contact-link { font-size: 14px; color: var(--ink-900); display: inline-flex; align-items: center; gap: 6px; }
.off-contact-link:hover { color: var(--brand-700); }

/* 聯絡：快速詢問表單 */
.off-inquiry .off-form { max-width: 640px; }
.off-form .off-field { margin: 0 0 20px; }
.off-form .off-field label { display: block; font-size: 13px; color: var(--ink-700); margin-bottom: 8px; letter-spacing: 0.02em; }
.off-form .off-field .req { color: var(--brand-600); }
.off-form input[type="text"], .off-form input[type="email"], .off-form textarea {
  width: 100%; box-sizing: border-box; font-family: inherit; font-size: 15px; color: var(--ink-900);
  background: #fff; border: 1px solid var(--ink-300); border-radius: 2px; padding: 12px 14px; }
.off-form input[type="text"]:focus, .off-form input[type="email"]:focus, .off-form textarea:focus {
  outline: none; border-color: var(--ink-900); }
.off-form textarea { min-height: 140px; resize: vertical; }
.off-form input[type="file"] { font-size: 14px; color: var(--ink-700); padding: 8px 0; width: 100%; }
.off-form .off-field-hint { display: block; margin-top: 6px; font-size: 12px; color: var(--ink-500); }
/* 聯絡表單：拖曳 / 貼上 上傳區 */
.off-dz-hidden { position: absolute !important; width: 1px; height: 1px; opacity: 0; overflow: hidden; padding: 0 !important; margin: -1px; }
.off-dropzone { border: 1.5px dashed var(--ink-300); border-radius: 4px; padding: 24px 16px; text-align: center; cursor: pointer; background: var(--ink-50); transition: border-color .2s, background .2s; }
.off-dropzone:hover, .off-dropzone.is-over { border-color: var(--ink-900); background: #fff; }
.off-dz-text { font-size: 13px; color: var(--ink-500); }
.off-dz-text b { color: var(--ink-800); font-weight: 600; }
.off-dz-preview:not(:empty) { margin-top: 14px; display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap; }
.off-dz-preview img { max-width: 130px; max-height: 130px; border: 1px solid var(--ink-200); border-radius: 4px; }
.off-dz-name { font-size: 12px; color: var(--ink-700); }
.off-dz-clear { font-size: 12px; color: var(--brand-600); text-decoration: underline; cursor: pointer; }
.off-form .off-submit { margin: 6px 0 0; }
.off-form .wpcf7-submit {
  background: var(--ink-900); color: #fff; border: 0; border-radius: 2px;
  padding: 14px 34px; font-size: 15px; letter-spacing: 0.05em; cursor: pointer; transition: background .2s; }
.off-form .wpcf7-submit:hover { background: var(--brand-700); }
.off-form .wpcf7-spinner { margin: 0 0 0 10px; }
.off-form .wpcf7-not-valid-tip { color: #d33; font-size: 12px; margin-top: 6px; }
.off-form .wpcf7-response-output { margin: 18px 0 0 !important; padding: 12px 14px !important; font-size: 14px; border-radius: 2px; }

/* 聯絡：地圖 */
.off-map { width: 100%; height: 380px; border: 0; border-radius: 2px; display: block; background: var(--ink-50); }
/* 聯絡：官方 LINE QR */
.off-line-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.off-line-qr { width: 112px; height: 112px; flex: 0 0 auto; border: 1px solid var(--ink-200); border-radius: 4px; background: #fff; padding: 4px; box-sizing: border-box; }

/* 官網手機選單（漢堡） */
.off-burger { display: none; }
.off-mnav { display: none; }
@media (max-width: 1080px) {
  .off-nav { display: none; }
  .off-header-right { display: none; }
  .off-burger { display: flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 42px; height: 42px; margin-left: auto; padding: 0; background: none; border: 0; cursor: pointer; }
  .off-burger span { display: block; width: 24px; height: 2px; background: var(--ink-900); transition: transform .25s, opacity .2s; }
  .off-burger.is-active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .off-burger.is-active span:nth-child(2) { opacity: 0; }
  .off-burger.is-active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .off-header-inner { flex-wrap: nowrap; }
  .off-mnav.is-open { display: block; }
  .off-mnav-inner { display: flex; flex-direction: column; padding-top: 6px; padding-bottom: 18px; }
  .off-mnav a { padding: 14px 2px; font-size: 16px; color: var(--ink-900); border-bottom: 1px solid var(--ink-100); }
  .off-mnav a.is-active { color: var(--brand-600); }
  .off-mnav-sep { height: 6px; }
  .off-mnav-cta { color: var(--brand-700) !important; font-weight: 600; border-bottom: 0 !important; }
}
@media (max-width: 900px) {
  .off-pagehead-h { font-size: 40px; }
  .off-secgrid { grid-template-columns: 1fr; }
  .off-ctaband-inner { flex-direction: column; align-items: flex-start; }
  .off-books { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 480px) {
  .off-books { grid-template-columns: 1fr; }
}
@media (min-width: 901px) and (max-width: 1180px) {
  .off-secgrid { grid-template-columns: repeat(2,1fr); }
  .off-books { grid-template-columns: repeat(3,1fr); }
}

/* 頂部通知下拉 */
.ct-noti-wrap { position: relative; display: inline-block; }
.ct-noti-panel { position: absolute; right: 0; top: calc(100% + 10px); width: 290px; background: #fff; border: 1px solid var(--ink-200); border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,.12); display: none; z-index: 99; padding: 6px; }
.ct-noti-panel.open { display: block; }
.ct-noti-title { display: block; font-size: 13px; font-weight: 700; color: var(--ink-900); padding: 8px 10px; border-bottom: 1px solid var(--ink-100); }
.ct-noti-wrap .ct-iconbtn { position: relative; }
.ct-noti-badge { position: absolute; top: -5px; right: -5px; min-width: 16px; height: 16px; padding: 0 4px; background: #ef4444; color: #fff; font-size: 10px; font-weight: 700; line-height: 16px; text-align: center; border-radius: 9px; box-sizing: border-box; }
.ct-noti-tabs { display: flex; border-bottom: 1px solid var(--ink-100); margin-bottom: 4px; }
.ct-noti-tab { flex: 1; background: none; border: 0; padding: 9px 4px; font-size: 13px; font-weight: 600; color: var(--ink-500); cursor: pointer; border-bottom: 2px solid transparent; }
.ct-noti-tab.on { color: var(--brand-700); border-bottom-color: var(--brand-600); }
.ct-noti-item .m { display: block; font-size: 12px; color: var(--ink-700); margin-top: 2px; line-height: 1.4; overflow: hidden; text-overflow: ellipsis; }
.ct-noti-item { display: block; padding: 9px 10px; border-radius: 8px; }
.ct-noti-item:hover { background: var(--brand-50); }
.ct-noti-item .t { display: block; font-size: 13px; color: var(--ink-800); font-weight: 500; }
.ct-noti-item .d { display: block; font-size: 11px; color: var(--ink-500); margin-top: 2px; }
.ct-noti-empty { display: block; padding: 16px 10px; font-size: 12.5px; color: var(--ink-500); text-align: center; }
.ct-noti-all { display: block; text-align: center; font-size: 12px; color: var(--brand-600); padding: 8px 0 6px; border-top: 1px solid var(--ink-100); }

/* 商城公告列 */
.ct-annbar { font-size: 13px; transition: background .45s ease, color .45s ease; }
.ct-annbar .container { display: flex; align-items: center; gap: 8px; padding-top: 8px; padding-bottom: 8px; }
.ct-ann-track { position: relative; flex: 1; height: 20px; overflow: hidden; }
.ct-ann-item { position: absolute; inset: 0; display: flex; align-items: center; opacity: 0; transition: opacity .45s ease; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ct-ann-item.on { opacity: 1; }
.ct-ann-item a, .ct-ann-item span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ct-ann-nav { background: none; border: 0; cursor: pointer; font-size: 20px; line-height: 1; color: inherit; opacity: .55; padding: 0 6px; flex: 0 0 auto; }
.ct-ann-nav:hover { opacity: 1; }
.ct-ann-dots { display: flex; gap: 5px; align-items: center; flex: 0 0 auto; }
.ct-ann-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; opacity: .3; cursor: pointer; padding: 0; border: 0; }
.ct-ann-dot.on { opacity: .9; }
.ct-annbar a { text-decoration: underline; }
.ct-annbar .x { margin-left: auto; font-size: 16px; opacity: .6; padding: 0 4px; }
.ct-annbar .x:hover { opacity: 1; }
/* 公告列 行動版(2026-10-24 修:桌機固定 20px 單行,手機長公告被截成「…」看不完)→ 自動換行最多三行;多則疊在同一格(高度取最長)免得輪播時跳動;箭頭收起只留圓點 */
@media (max-width: 768px) {
  .ct-annbar { font-size: 12.5px; }
  .ct-annbar .container { align-items: flex-start; gap: 6px; padding-top: 7px; padding-bottom: 7px; }
  .ct-annbar .ic { line-height: 1.5; flex: 0 0 auto; }
  .ct-ann-track { height: auto; display: grid; min-width: 0; }
  .ct-ann-item { position: static; grid-area: 1 / 1; white-space: normal; line-height: 1.5; align-items: flex-start; visibility: hidden; }
  .ct-ann-item.on { visibility: visible; }
  .ct-ann-item a, .ct-ann-item span { white-space: normal; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
  .ct-ann-nav { display: none; }
  .ct-ann-dots { align-self: center; }
}
.ct-annbar.tone-blue { background: var(--brand-50); color: var(--brand-700); border-bottom: 1px solid var(--brand-100); }
.ct-annbar.tone-orange { background: #fff7ed; color: #c2410c; border-bottom: 1px solid #fed7aa; }
.ct-annbar.tone-red { background: #fef2f2; color: #b91c1c; border-bottom: 1px solid #fecaca; }

/* 商品影片(單一商品頁) */
.ct-pvideo-sec { margin: 34px 0; }
.ct-pvideo-h { font-size: 18px; font-weight: 700; color: var(--ink-900, #1f2937); margin: 0 0 14px; }
.ct-pvideo { position: relative; width: 100%; max-width: 760px; aspect-ratio: 16/9; background: #000; border-radius: 12px; overflow: hidden; }
.ct-pvideo iframe, .ct-pvideo video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.ct-pvideo-link a { display: inline-block; padding: 10px 18px; background: var(--brand-600, #2563eb); color: #fff; border-radius: 8px; font-weight: 600; }

/* ===== 店家頁(Dokan store 覆寫,dokan/store.php)===== */
.ct-store { display: flex; flex-direction: column; gap: 16px; margin-bottom: 28px; }
.ct-store-head { background: var(--ink-900); border-radius: var(--r-lg); overflow: hidden; color: #fff; }
.ct-store-banner img { width: 100%; height: 220px; object-fit: cover; display: block; }
.ct-store-id { display: flex; align-items: center; gap: 16px; padding: 18px 24px; flex-wrap: wrap; }
.ct-store-logo { width: 64px; height: 64px; border-radius: 50%; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.25); display: flex; align-items: center; justify-content: center; overflow: hidden; flex: 0 0 auto; }
.ct-store-logo img { width: 100%; height: 100%; object-fit: cover; }
.ct-store-meta { flex: 1; min-width: 220px; }
.ct-store-name { font-size: 21px; font-weight: 700; margin: 0 0 6px; color: #fff; }
.ct-store-stats { display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: 13px; color: rgba(255,255,255,.72); }
.ct-store-stats b { color: #fff; font-weight: 700; }
.ct-store-chatbtn { display: inline-flex; align-items: center; gap: 7px; padding: 10px 22px; border: 0; border-radius: 10px; background: var(--brand-500); color: #fff; font-size: 14px; font-weight: 600; cursor: pointer; }
.ct-store-chatbtn:hover { background: var(--brand-600); }
.ct-store-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.ct-store-tagline { font-size: 13.5px; color: rgba(255,255,255,.82); margin: -2px 0 6px; }
.ct-store-sharebtn { display: inline-flex; align-items: center; gap: 7px; padding: 9px 20px; border: 1px solid rgba(255,255,255,.4); border-radius: 10px; background: transparent; color: #fff; font-size: 14px; font-weight: 600; cursor: pointer; }
.ct-store-sharebtn:hover { background: rgba(255,255,255,.1); }
/* 賣場橫幅配色(頁框設定 head.style;is-dark＝原本樣式) */
.ct-store-head.is-light { background: #fff; color: var(--ink-900); border: 1px solid var(--ink-200); }
.ct-store-head.is-light .ct-store-name, .ct-store-head.is-light .ct-store-stats b { color: var(--ink-900); }
.ct-store-head.is-light .ct-store-stats, .ct-store-head.is-light .ct-store-tagline { color: var(--ink-500); }
.ct-store-head.is-light .ct-store-logo { background: var(--ink-50); border-color: var(--ink-200); color: var(--ink-500); }
.ct-store-head.is-light .ct-store-sharebtn { border-color: var(--ink-300, #d4d4d4); color: var(--ink-700); }
.ct-store-head.is-light .ct-store-sharebtn:hover { background: var(--ink-50); }
.ct-store-head.is-brand { background: linear-gradient(125deg, var(--brand-600), var(--brand-800, var(--brand-700))); }
.ct-store-head.is-brand .ct-store-chatbtn { background: #fff; color: var(--brand-700); }
/* 賣場橫幅:自訂物件(標籤列/自訂文字/社群連結/自訂按鈕) */
.ct-store-badges { display: flex; flex-wrap: wrap; gap: 6px; margin: 2px 0 6px; }
.ct-store-badge { font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 6px; background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.25); }
.ct-store-text { font-size: 13.5px; line-height: 1.7; color: rgba(255,255,255,.82); white-space: pre-line; margin: 2px 0 6px; }
.ct-store-links { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 2px; }
.ct-store-link { font-size: 12px; font-weight: 600; padding: 4px 11px; border-radius: 6px; border: 1px solid rgba(255,255,255,.35); color: inherit; text-decoration: none; }
.ct-store-link:hover { background: rgba(255,255,255,.1); color: inherit; }
.ct-store-cbtn { display: inline-flex; align-items: center; gap: 7px; padding: 9px 20px; border-radius: 10px; font-size: 14px; font-weight: 600; text-decoration: none; border: 1px solid transparent; }
.ct-store-cbtn.solid { background: var(--brand-500); color: #fff; }
.ct-store-cbtn.outline { border-color: rgba(255,255,255,.4); color: #fff; }
.ct-store-cbtn:hover { opacity: .9; }
.ct-store-head.is-light .ct-store-badge { background: var(--ink-50); border-color: var(--ink-200); color: var(--ink-700); }
.ct-store-head.is-light .ct-store-text { color: var(--ink-600, #555); }
.ct-store-head.is-light .ct-store-link, .ct-store-head.is-light .ct-store-cbtn.outline { border-color: var(--ink-300, #d4d4d4); color: var(--ink-700); }
/* 賣場橫幅:排版 */
.ct-store-head.lay-center .ct-store-id { flex-direction: column; text-align: center; }
.ct-store-head.lay-center .ct-store-meta { min-width: 0; width: 100%; }
.ct-store-head.lay-center .ct-store-stats, .ct-store-head.lay-center .ct-store-badges, .ct-store-head.lay-center .ct-store-links, .ct-store-head.lay-center .ct-store-actions { justify-content: center; }
.ct-store-head.has-overlay { position: relative; background-image: linear-gradient(90deg, rgba(0,0,0,.72), rgba(0,0,0,.35)), var(--sh-img); background-size: cover; background-position: center; color: #fff; border: 0; }
.ct-store-head.has-overlay .ct-store-id { min-height: 220px; align-content: flex-end; }
.ct-store-head.has-overlay.bh-sm .ct-store-id { min-height: 150px; }
.ct-store-head.has-overlay.bh-lg .ct-store-id { min-height: 320px; }
.ct-store-head.has-overlay.lay-overlay .ct-store-id { align-items: flex-end; }
.ct-store-head.has-overlay .ct-store-name, .ct-store-head.has-overlay .ct-store-stats b { color: #fff; }
.ct-store-head.has-overlay .ct-store-stats, .ct-store-head.has-overlay .ct-store-tagline, .ct-store-head.has-overlay .ct-store-text { color: rgba(255,255,255,.85); }
.ct-store-head.bh-sm .ct-store-banner img { height: 140px; }
.ct-store-head.bh-lg .ct-store-banner img { height: 320px; }
.ct-store-head.logo-square .ct-store-logo { border-radius: 14px; }
.ct-store-head.logo-sm .ct-store-logo { width: 48px; height: 48px; }
.ct-store-head.logo-lg .ct-store-logo { width: 88px; height: 88px; }
.ct-store-head.pad-compact .ct-store-id { padding: 12px 18px; }
.ct-store-head.pad-roomy .ct-store-id { padding: 30px 34px; }
/* 賣場橫幅:自訂顏色(style=custom,變數印在 section 上) */
.ct-store-head.is-custom { background-color: var(--sh-bg); background-image: linear-gradient(125deg, var(--sh-bg), var(--sh-bg2)); color: var(--sh-fg); }
.ct-store-head.is-custom.has-overlay { background-image: linear-gradient(90deg, color-mix(in srgb, var(--sh-bg) 85%, transparent), color-mix(in srgb, var(--sh-bg2) 40%, transparent)), var(--sh-img); }
.ct-store-head.is-custom .ct-store-name, .ct-store-head.is-custom .ct-store-stats b { color: var(--sh-fg); }
.ct-store-head.is-custom .ct-store-stats, .ct-store-head.is-custom .ct-store-tagline, .ct-store-head.is-custom .ct-store-text { color: color-mix(in srgb, var(--sh-fg) 78%, transparent); }
.ct-store-head.is-custom .ct-store-logo { background: color-mix(in srgb, var(--sh-fg) 12%, transparent); border-color: color-mix(in srgb, var(--sh-fg) 28%, transparent); color: var(--sh-fg); }
.ct-store-head.is-custom .ct-store-badge { background: color-mix(in srgb, var(--sh-fg) 12%, transparent); border-color: color-mix(in srgb, var(--sh-fg) 28%, transparent); color: var(--sh-fg); }
.ct-store-head.is-custom .ct-store-link, .ct-store-head.is-custom .ct-store-sharebtn, .ct-store-head.is-custom .ct-store-cbtn.outline { border-color: color-mix(in srgb, var(--sh-fg) 40%, transparent); color: var(--sh-fg); }
.ct-store-head.is-custom .ct-store-chatbtn, .ct-store-head.is-custom .ct-store-cbtn.solid { background: var(--sh-btn, var(--brand-500)); color: var(--sh-btnfg); }
/* 賣場分類:深色系(頁框 cats.tone=dark) */
.ct-store-cats.is-dark { background: var(--ink-900, #111827); border-color: var(--ink-900, #111827); color: #fff; }
.ct-store-cats.is-dark .ct-store-cats-head { color: rgba(255,255,255,.6); }
.ct-store-cats.is-dark .ct-store-chip { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.18); color: rgba(255,255,255,.88); }
.ct-store-cats.is-dark .ct-store-chip:hover { border-color: rgba(255,255,255,.45); color: #fff; }
.ct-store-cats.is-dark .ct-store-chip.is-active { background: var(--brand-500); border-color: var(--brand-500); color: #fff; }
.ct-store-cats.is-dark .ct-store-chiprow.sub { border-top-color: rgba(255,255,255,.15); }
/* 分享面板 */
.ct-share-pop { position: absolute; right: 0; top: calc(100% + 8px); z-index: 50; width: 300px; max-width: calc(100vw - 32px); background: #fff; color: var(--ink-900); border: 1px solid var(--ink-200); border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,.16); padding: 14px; text-align: left; }
.ct-share-h { font-size: 13px; font-weight: 700; margin-bottom: 10px; }
.ct-share-url { display: flex; gap: 6px; }
.ct-share-url input { flex: 1; min-width: 0; height: 36px; border: 1px solid var(--ink-200); border-radius: 8px; padding: 0 10px; font-size: 13px; color: var(--ink-700); background: var(--ink-50); }
.ct-share-url button { height: 36px; padding: 0 14px; border: 0; border-radius: 8px; background: var(--brand-600); color: #fff; font-weight: 600; cursor: pointer; white-space: nowrap; }
.ct-share-links { display: flex; gap: 8px; margin-top: 10px; }
.ct-share-links a { flex: 1; text-align: center; padding: 8px 0; border: 1px solid var(--ink-200); border-radius: 8px; font-size: 13px; color: var(--ink-700); text-decoration: none; }
.ct-share-links a:hover { border-color: var(--brand-300); color: var(--brand-700); }
.ct-store-cats { padding: 16px 20px; }
.ct-store-cats-head { font-size: 13px; font-weight: 700; color: var(--ink-500); letter-spacing: .05em; margin-bottom: 10px; }
.ct-store-chiprow { display: flex; flex-wrap: wrap; gap: 8px; }
.ct-store-chiprow.sub { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--ink-200); }
.ct-store-chip { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border: 1px solid var(--ink-200); border-radius: 999px; background: #fff; font-size: 13.5px; color: var(--ink-700); text-decoration: none; line-height: 1.4; }
.ct-store-chip .em { font-size: 15px; }
.ct-store-chip .ct { font-size: 12px; opacity: .6; }
.ct-store-chip:hover { border-color: var(--brand-300); color: var(--brand-700); }
.ct-store-chip.is-active { background: var(--brand-600); border-color: var(--brand-600); color: #fff; }
.ct-store-chip.is-active .ct { opacity: .8; }
.ct-store-chip.sm { padding: 5px 12px; font-size: 12.5px; }
.ct-store-loop-head { font-size: 17px; font-weight: 700; color: var(--ink-900); margin: 4px 0 14px; }
.ct-store-empty { background: var(--ink-50); border: 1px dashed var(--ink-200); border-radius: var(--r-md); padding: 40px; text-align: center; color: var(--ink-500); }
.ct-store .dokan-pagination-container { text-align: center; margin: 24px 0 8px; }
.ct-store .dokan-pagination { display: inline-flex; gap: 6px; list-style: none; margin: 0; padding: 0; }
.ct-store .dokan-pagination li a, .ct-store .dokan-pagination li span { display: inline-block; min-width: 36px; padding: 8px 10px; border: 1px solid var(--ink-200); border-radius: var(--r-sm); text-align: center; font-size: 14px; color: var(--ink-700); text-decoration: none; background: #fff; }
.ct-store .dokan-pagination li.active a, .ct-store .dokan-pagination li a:hover { background: var(--brand-600); border-color: var(--brand-600); color: #fff; }
@media (max-width: 640px) {
  .ct-store-banner img { height: 130px; }
  .ct-store-id { padding: 14px 16px; }
  .ct-store-actions { width: 100%; }
}

/* ===== 賣場佈置(店家頁組件,cartruck-store-design.php)===== */
.ct-sd { display: flex; flex-direction: column; gap: 16px; }
.ct-sd-previewbar { background: var(--warning); color: #3a2a00; border-radius: var(--r-md); padding: 10px 16px; font-size: 13.5px; font-weight: 600; }
.ct-sd-hero { position: relative; border-radius: var(--r-lg); overflow: hidden; background: var(--ink-100); }
.ct-sd-slide { display: none; }
.ct-sd-slide.is-active { display: block; }
.ct-sd-slide img { width: 100%; max-height: 340px; object-fit: cover; display: block; }
.ct-sd-dots { position: absolute; left: 0; right: 0; bottom: 12px; display: flex; justify-content: center; gap: 8px; }
.ct-sd-dots button { width: 9px; height: 9px; border-radius: 50%; border: 0; padding: 0; background: rgba(255,255,255,.55); cursor: pointer; }
.ct-sd-dots button.is-active { background: #fff; width: 22px; border-radius: 5px; }
.ct-sd-img img { width: 100%; display: block; border-radius: var(--r-lg); }
.ct-sd-video .ct-pvideo { margin: 0 auto; }
.ct-sd-text { padding: 20px 24px; }
.ct-sd-text-body { font-size: 14px; color: var(--ink-700); line-height: 1.9; }
.ct-sd-row { background: #fff; border: 1px solid var(--ink-100); border-radius: var(--r-lg); padding: 18px 20px 8px; }
.ct-sd-row-h { font-size: 17px; font-weight: 700; color: var(--ink-900); margin-bottom: 14px; }
@media (max-width: 640px) { .ct-sd-slide img { max-height: 180px; } }

/* ===== 商品頁賣家資訊卡(cartruck-product-vendor.php)===== */
/* 單品頁是 WooCommerce 原生 float 版型(圖左/摘要右),不 clear 會被吸上去擠在摘要旁邊 */
.ct-pvendor {
  clear: both;
  display: flex; align-items: center; gap: 18px;
  background: #fff; border: 1px solid var(--ink-100); border-radius: var(--r-lg);
  padding: 16px 20px; margin: 32px 0 24px;
}
.ct-pvendor-logo {
  flex: 0 0 auto; width: 56px; height: 56px; border-radius: 50%; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  background: var(--ink-50); border: 1px solid var(--ink-100); color: var(--ink-400);
}
.ct-pvendor-logo img { width: 100%; height: 100%; object-fit: cover; }
.ct-pvendor-id { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ct-pvendor-label { font-size: 11px; color: var(--ink-400); letter-spacing: .08em; }
.ct-pvendor-name {
  font-size: 17px; font-weight: 700; color: var(--ink-900); text-decoration: none;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ct-pvendor-name:hover { color: var(--brand-600); }
.ct-pvendor-since { font-size: 12px; color: var(--ink-400); }
.ct-pvendor-actions { display: flex; gap: 8px; margin-left: 4px; }
.ct-pvendor-btn {
  display: inline-flex; align-items: center; gap: 6px; cursor: pointer;
  padding: 8px 14px; border-radius: var(--r-sm); font-size: 13.5px; font-weight: 600;
  text-decoration: none; border: 1px solid var(--brand-600); background: #fff; color: var(--brand-600);
}
.ct-pvendor-btn:hover { background: var(--brand-600); color: #fff; }
.ct-pvendor-btn.visit { border-color: var(--ink-200); color: var(--ink-700); }
.ct-pvendor-btn.visit:hover { background: var(--ink-900); border-color: var(--ink-900); color: #fff; }
.ct-pvendor-stats { display: flex; gap: 28px; margin-left: auto; padding-left: 24px; border-left: 1px solid var(--ink-100); }
.ct-pvendor-stat { display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 76px; }
.ct-pvendor-stat b { font-size: 18px; font-weight: 700; color: var(--ink-900); font-variant-numeric: tabular-nums; }
.ct-pvendor-stat b i { font-style: normal; color: var(--warning); }
.ct-pvendor-stat span { font-size: 12px; color: var(--ink-500); white-space: nowrap; }
@media (max-width: 860px) {
  .ct-pvendor { flex-wrap: wrap; gap: 12px 16px; }
  .ct-pvendor-actions { margin-left: auto; }
  .ct-pvendor-stats { margin-left: 0; padding-left: 0; border-left: 0; width: 100%; justify-content: space-around;
    padding-top: 12px; border-top: 1px solid var(--ink-100); }
}

/* ============================================
   官網主選單：一層子選單（2026-10-03）
   外觀→選單把項目拖到父項底下 → 桌機下拉（hover / 點擊）、手機群組（固定展開）
   ============================================ */
.off-nav-dd { position: relative; }
.off-nav-dd-btn { font: inherit; font-size: 14px; color: var(--ink-700); letter-spacing: 0.02em; background: none; border: 0; padding: 0; cursor: pointer; display: inline-flex; align-items: center; gap: 5px; line-height: inherit; }
.off-nav-dd-btn:hover, .off-nav-dd:hover > .off-nav-dd-btn, .off-nav-dd.is-open > .off-nav-dd-btn { color: var(--ink-900); }
.off-nav-dd-btn:focus-visible { outline: 2px solid var(--brand-500); outline-offset: 4px; }
.off-nav-dd-ic { width: 14px; height: 14px; transition: transform .2s; }
.off-nav-dd:hover > .off-nav-dd-btn .off-nav-dd-ic, .off-nav-dd.is-open > .off-nav-dd-btn .off-nav-dd-ic, .off-nav-dd:focus-within > .off-nav-dd-btn .off-nav-dd-ic { transform: rotate(180deg); }
.off-nav-dd.is-active > .off-nav-dd-btn { color: var(--ink-900); font-weight: 600; border-bottom: 1.5px solid var(--brand-500); padding-bottom: 3px; }
.off-nav-dd-menu { position: absolute; top: 100%; left: -20px; padding-top: 18px; display: none; z-index: 60; }
.off-nav-dd:hover > .off-nav-dd-menu, .off-nav-dd.is-open > .off-nav-dd-menu, .off-nav-dd:focus-within > .off-nav-dd-menu { display: block; }
.off-nav-dd-in { min-width: 220px; background: #fff; border: 1px solid var(--ink-200); box-shadow: 0 12px 32px rgba(0,0,0,0.08); padding: 8px 0; }
.off-nav .off-nav-dd-in a { display: block; padding: 11px 20px; font-size: 14px; color: var(--ink-700); border-bottom: 0; white-space: nowrap; }
.off-nav .off-nav-dd-in a:hover { background: var(--ink-50); color: var(--ink-900); }
.off-nav .off-nav-dd-in a.is-active { color: var(--ink-900); font-weight: 600; border-bottom: 0; padding-bottom: 11px; box-shadow: inset 2px 0 0 var(--brand-500); }
@media (prefers-reduced-motion: reduce) { .off-nav-dd-ic { transition: none; } }
@media (max-width: 1080px) {
  .off-mnav-group { display: flex; flex-direction: column; border-bottom: 1px solid var(--ink-100); padding-bottom: 6px; }
  .off-mnav-group-t { display: block; padding: 16px 2px 4px; font-size: 12px; letter-spacing: 0.14em; color: var(--ink-500); }
  .off-mnav-group.is-active .off-mnav-group-t { color: var(--brand-600); }
  .off-mnav .off-mnav-group a { padding: 11px 2px 11px 14px; border-bottom: 0; font-size: 16px; }
}


/* ===== 獨立賣場模式(mu-plugins/cartruck-store-independent.php;2026-10-22)===== */
.ct-indie-top { background: var(--ink-900); color: var(--ink-300); font-size: 12px; }
.ct-indie-top .container { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 30px; }
.ct-indie-top a { color: var(--ink-300); padding: 0 4px; } .ct-indie-top a:hover { color: #fff; } .ct-indie-top .sep { color: var(--ink-700); margin: 0 4px; }
.ct-indie-top-l { color: var(--ink-200); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ct-indie-top-r { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.ct-indie-head { background: #fff; border-bottom: 1px solid var(--ink-200); }
.ct-indie-main { display: flex; align-items: center; gap: 24px; padding: 14px 0; }
.ct-indie-brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink-900); min-width: 0; }
.ct-indie-logo { width: 48px; height: 48px; border-radius: 50%; background: var(--ink-100); border: 1px solid var(--ink-200); display: inline-flex; align-items: center; justify-content: center; overflow: hidden; flex: 0 0 48px; color: var(--brand-600); }
.ct-indie-logo img { width: 100%; height: 100%; object-fit: cover; }
.ct-indie-name { font-size: 20px; font-weight: 800; letter-spacing: .02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ct-indie-search { flex: 1; display: flex; max-width: 620px; border: 2px solid var(--brand-600); border-radius: 6px; overflow: hidden; background: #fff; }
.ct-indie-search input { flex: 1; border: 0; padding: 0 14px; height: 42px; font-size: 15px; outline: none; min-width: 0; }
.ct-indie-search button { border: 0; background: var(--brand-600); color: #fff; width: 56px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.ct-indie-search button:hover { background: var(--brand-700); }
.ct-indie-actions { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.ct-indie-ib { position: relative; display: inline-flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 10px; border: 0; background: transparent; color: var(--ink-700); text-decoration: none; cursor: pointer; border-radius: 6px; font: inherit; }
.ct-indie-ib:hover { background: var(--ink-100); color: var(--ink-900); }
.ct-indie-ib .lb { font-size: 11px; }
.ct-indie-badge { position: absolute; top: 2px; right: 4px; min-width: 18px; height: 18px; border-radius: 9px; background: #d63a2f; color: #fff; font-size: 11px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; padding: 0 5px; }
.ct-indie-cats { border-top: 1px solid var(--ink-200); background: #fff; }
.ct-indie-cats .container { display: flex; gap: 8px; overflow-x: auto; padding: 8px 0; scrollbar-width: none; }
.ct-indie-chip { white-space: nowrap; font-size: 13px; padding: 6px 12px; border-radius: 999px; background: var(--ink-100); color: var(--ink-700); text-decoration: none; }
.ct-indie-chip:hover { background: var(--brand-100); color: var(--brand-700); }
.ct-indie-notice { background: var(--brand-50); border-top: 1px solid var(--brand-100); color: var(--brand-700); font-size: 13px; }
.ct-indie-notice .container { display: flex; align-items: center; gap: 8px; min-height: 34px; }
.ct-indie-foot { background: var(--ink-50); border-top: 1px solid var(--ink-200); margin-top: 48px; padding: 36px 0 24px; color: var(--ink-700); font-size: 13px; }
.ct-indie-foot-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 28px; }
.ct-indie-foot-name { font-size: 17px; font-weight: 800; color: var(--ink-900); margin-bottom: 6px; }
.ct-indie-foot-sub { margin: 2px 0; } .ct-indie-foot-sub a { color: var(--brand-600); text-decoration: none; }
.ct-indie-foot-txt { margin-top: 10px; line-height: 1.7; color: var(--ink-500); white-space: normal; }
.ct-indie-foot h4 { font-size: 13px; margin: 0 0 10px; color: var(--ink-900); }
.ct-indie-foot ul { list-style: none; margin: 0; padding: 0; } .ct-indie-foot li { margin: 6px 0; } .ct-indie-foot li a { color: var(--ink-700); text-decoration: none; } .ct-indie-foot li a:hover { color: var(--brand-600); }
.ct-indie-foot-bottom { border-top: 1px solid var(--ink-200); margin-top: 24px; padding-top: 14px; font-size: 12px; color: var(--ink-500); text-align: center; }
.ct-indie-foot-bottom a { color: var(--ink-700); }
@media (max-width: 782px) {
  .ct-indie-top-l { display: none; }
  .ct-indie-main { flex-wrap: wrap; gap: 10px 12px; padding: 10px 0; }
  .ct-indie-brand { order: 1; flex: 1; } .ct-indie-actions { order: 2; margin-left: 0; } .ct-indie-search { order: 3; flex: 1 1 100%; max-width: none; }
  .ct-indie-name { font-size: 17px; } .ct-indie-logo { width: 40px; height: 40px; flex-basis: 40px; }
  .ct-indie-ib { padding: 4px 6px; } .ct-indie-ib .lb { display: none; }
  .ct-indie-foot-grid { grid-template-columns: 1fr; gap: 18px; }
}
.ct-indie .product_meta .posted_in, .ct-indie .product_meta .tagged_as { display: none; } /* 獨立賣場:商品頁不露平台分類/標籤連結 */

/* 商品頁賣家資訊卡 — 獨立賣場模式:標頭改「關於 店名」+ 標語(cartruck-product-vendor.php) */
.ct-pvendor-label.is-indie { font-size: 16px; font-weight: 800; color: var(--ink-900); letter-spacing: 0; text-decoration: none; }
.ct-pvendor-label.is-indie:hover { color: var(--brand-600); }
.ct-pvendor-tagline { font-size: 13px; color: var(--ink-500); }
