/* Step 2 設計衝刺共用樣式（定稿後刪） */

.dbar {
  position: sticky; top: 0; z-index: 50;
  display: flex; gap: 16px; align-items: center;
  background: rgba(29, 29, 31, 0.92);
  backdrop-filter: saturate(180%) blur(20px);
  color: #f5f5f7; font-size: 13px; padding: 10px 20px;
}
.dbar a { color: #f5f5f7; }
.dbar span { color: #a1a1a6; }
.dbar-btn { margin-left: auto; font-family: inherit; font-size: 13px; cursor: pointer;
            background: rgba(255,255,255,0.14); color: #f5f5f7; border: 0;
            border-radius: 100px; padding: 6px 14px; }
.dbar-btn:hover { background: rgba(255,255,255,0.26); }
.dbar-btn.on { background: var(--blue); color: #fff; }

/* 區塊代號模式 */
body.mark [data-sec] { outline: 1px dashed rgba(0,113,227,0.55); outline-offset: 5px;
                       position: relative; cursor: copy; }
body.mark [data-sec]:hover { outline-style: solid; outline-color: var(--blue);
                             background: rgba(0,113,227,0.035); }
/* 標在區塊「內側」左上角，才不會被上方工具列擋掉 */
body.mark [data-sec]::before {
  content: attr(data-sec); position: absolute; top: 0; left: 0; z-index: 30;
  background: var(--blue); color: #fff; font-size: 11px; font-weight: 600;
  letter-spacing: 0.03em; padding: 3px 8px; border-radius: 0 0 6px 0;
  white-space: nowrap; pointer-events: none;
  box-shadow: 0 1px 6px rgba(0,0,0,0.18);
}
body.mark { padding-top: 6px; }
/* 上面那條會把 position 改成 relative，這兩塊本來就有自己的定位，要還原 */
body.mark .lb-side { position: sticky; }
body.mark .lb-bar, body.mark .la-bar { position: fixed; }

.dtoast { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(12px);
          background: rgba(29,29,31,0.94); color: #fff; font-size: 14px; padding: 11px 20px;
          border-radius: 100px; z-index: 200; opacity: 0; pointer-events: none;
          transition: opacity 0.2s ease, transform 0.2s ease; backdrop-filter: blur(12px); }
.dtoast.on { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── 頁頭（2.4 第一段，Tesla 風）：markup 在 partials/_nav.html ──
   高 56px、白底、捲動時黏在頂端。中間的字 14px／500，滑過出淺灰底（圓角 4px），
   轉場只變顏色。不要在 .nv 加 z-index 以外的堆疊屬性：手機面板（91）要爬得出去。 */
/* 🔴 .nv 不准加 backdrop-filter／transform／filter：那三個會讓裡面 position:fixed 的
   手機面板改成貼著頁頭（56px 高）定位，打開 Menu 整頁被推歪、面板看不到（10-03 實測踩到） */
.nv { position: sticky; top: 0; z-index: 40; background: #fff; }
.nv-in { max-width: 1440px; margin: 0 auto; height: 56px; padding: 0 32px;
         display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; }
.nv-brand { display: inline-flex; align-items: center; }
.nv-brand img { display: block; height: 24px; width: auto; }
.nv-brand:hover { text-decoration: none; }
.nv-menu ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; justify-content: center; }
.nv-menu a { display: block; font-size: 14px; font-weight: 500; color: var(--ink);
             padding: 6px 16px; border-radius: 4px; transition: background-color var(--ease); }
.nv-menu a:hover { text-decoration: none; background: rgba(0, 0, 0, 0.05); }
.nv-right { justify-self: end; display: flex; align-items: center; gap: 8px; }

/* 手機：只剩 logo 與 Menu（灰底、圓角 4px），面板從右邊滑出 */
.nv-burger { display: none; font-family: inherit; font-size: 14px; font-weight: 500; color: var(--ink);
             background: rgba(0, 0, 0, 0.05); border: 0; border-radius: 4px; padding: 6px 16px;
             cursor: pointer; transition: background-color var(--ease); }
.nv-burger:hover { background: rgba(0, 0, 0, 0.09); }
.nv-scrim { position: fixed; inset: 0; z-index: 90; background: rgba(0, 0, 0, 0.2);
            -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
            opacity: 0; visibility: hidden; transition: opacity var(--ease), visibility var(--ease); }
.nv-panel { position: fixed; top: 0; right: 0; bottom: 0; z-index: 91; width: min(86vw, 311px);
            background: #fff; transform: translateX(100%); overflow-y: auto;
            transition: transform 0.4s cubic-bezier(0.5, 0, 0, 0.75);
            display: flex; flex-direction: column;
            padding: 16px 24px calc(24px + env(safe-area-inset-bottom)); }
body.navopen { overflow: hidden; }
body.navopen .nv-scrim { opacity: 1; visibility: visible; }
body.navopen .nv-panel { transform: none; }
.nv-close { align-self: flex-end; width: 32px; height: 32px; flex: none; border: 0; border-radius: 4px;
            background: transparent; color: var(--ink); font-size: 16px; cursor: pointer; }
.nv-close:hover { background: rgba(0, 0, 0, 0.05); }
.nv-panel ul { list-style: none; margin: 24px 0 0; padding: 0; }
.nv-panel li a { display: block; font-size: 16px; font-weight: 500; color: var(--ink);
                 padding: 12px 16px; border-radius: 4px; transition: background-color var(--ease); }
.nv-panel li a:hover { text-decoration: none; background: rgba(0, 0, 0, 0.05); }

@media (max-width: 1023px) {
  .nv-in { grid-template-columns: 1fr auto; padding: 0 16px; }
  .nv-menu { display: none; }
  .nv-burger { display: block; }
}

/* ── 頁尾（2.4 第一段，Tesla 風）：一行置中的小字連結 ── */
.ft { padding: 40px 16px 48px; }
.ft-row { list-style: none; margin: 0 auto; padding: 0; max-width: 1040px;
          display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 24px;
          font-size: 12px; color: var(--muted); }
.ft-row a { color: var(--muted); }
.ft-row a:hover { color: var(--ink); }

/* 規格標籤：Built Up : 46,349 sqft */
.spec-k { color: var(--muted); }
.spec-v { color: var(--ink); font-weight: 600; }

.badge {
  display: inline-block; font-size: 12px; font-weight: 600; letter-spacing: 0.02em;
  padding: 3px 9px; border-radius: 100px;
}
/* 成交狀態各自一個顏色：出租藍、出售綠、已成交灰 */
.badge-rent { background: #e8f2ff; color: #0060c0; }
.badge-sale { background: #e3f6e9; color: #197f45; }
.badge-off { background: #efeff2; color: #6e6e73; }
/* 產業類別（Industrial / Commercial / Residential / Land）用中性白，跟成交狀態分開 */
.badge-cat { background: rgba(255, 255, 255, 0.94); backdrop-filter: blur(10px); color: var(--ink); }

:root {
  --wa: #25d366;       /* WhatsApp 官方青綠 */
  --wa-dark: #1eb955;
}

/* WhatsApp 鍵：全站唯一的綠色（09-27 拍板），形狀跟主要按鈕一樣（圓角 4px、字重 500） */
.wa {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--wa); color: #fff; font-weight: 500; font-size: 14px;
  min-height: 40px; padding: 0 24px; border-radius: 4px;
  transition: background-color var(--ease);
}
.wa:hover { text-decoration: none; background: var(--wa-dark); }
.ico { flex: none; }
.wa-ghost {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; color: var(--body); font-weight: 500; font-size: 14px;
  min-height: 40px; padding: 0 24px; border-radius: 4px; background: var(--surface);
  transition: background-color var(--ease);
}
.wa-ghost:hover { text-decoration: none; background: #e8e8e8; }

/* 圓形圖示鍵。padding: 0 一定要在 .wa 後面，否則 .icobtn.wa 會被 .wa 的 padding 撐成橢圓 */
.icobtn { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px;
          padding: 0; border-radius: 4px; border: 0; background: var(--surface);
          color: var(--ink); flex: none; transition: background-color var(--ease); }
.icobtn:hover { text-decoration: none; background: #e8e8e8; }
.icobtn.wa { background: var(--wa); border-color: var(--wa); color: #fff; }
.icobtn.wa:hover { background: var(--wa-dark); border-color: var(--wa-dark); }

/* ── 卡片滾輪：首頁 H5（行為在 static/js/rail.js）──
   整條滿版跨出內容欄，左右內距剛好等於內容欄的邊界 → 第一張跟上面的標題切齊，
   旁邊那張露出一角；捲動時前一張會留在邊緣當半張。一次翻一張，滑鼠可拖。
   --inset 就是「畫面邊緣到內容欄」的距離，跟 .b-wrap 用同一組數字算出來，
   不用 vw（避開捲軸誤差）。⚠️ gap 的數字跟 rail.js 的 GAP 要一致。 */
.b-rail-wrap { position: relative; --inset: calc((100% - min(100% - 56px, 1124px)) / 2); }
.b-rail { display: flex; align-items: stretch; gap: 22px; overflow-x: auto;
          scroll-snap-type: x mandatory; scroll-behavior: smooth;
          padding: 4px var(--inset) 22px; scroll-padding-left: var(--inset);
          margin-top: -4px; scrollbar-width: none;
          -webkit-user-select: none; user-select: none; }
.b-rail::-webkit-scrollbar { display: none; }
.b-rail > * { flex: 0 0 360px; scroll-snap-align: start; }
.b-rail.drag { scroll-snap-type: none; scroll-behavior: auto; cursor: grabbing; }

/* 箭頭配色照抄 apple.com/my/store 的 .paddlenav-arrow：淺灰半透明底、無邊框無陰影 */
.b-arrow { position: absolute; top: 50%; transform: translateY(calc(-50% - 9px));
           z-index: 5; width: 49px; height: 49px; border: 0; border-radius: 50%; padding: 0;
           background: rgba(210, 210, 215, 0.64); color: rgba(0, 0, 0, 0.56);
           cursor: pointer; display: flex; align-items: center; justify-content: center;
           transition: background 0.2s ease, color 0.2s ease, opacity 0.2s ease; }
.b-arrow:hover { background: rgba(198, 198, 204, 0.82); color: rgba(0, 0, 0, 0.76); }
.b-arrow[disabled] { opacity: 0; pointer-events: none; }
/* 圓心對準卡片之間的縫：右邊是第三、四張的縫，左邊是（滑動後）半張與第二張的縫。
   縫的中心距內容欄邊界 11px（gap 22 的一半），再扣掉半顆按鈕 24.5px（49 的一半） */
.b-arrow.prev { left: max(10px, calc(var(--inset) - 35.5px)); }
.b-arrow.next { right: max(10px, calc(var(--inset) - 35.5px)); }

@media (max-width: 900px) {
  .b-arrow { display: none; }
  .b-rail > * { flex: 0 0 78%; }
}

/* ── 房源卡片（partials/_card.html）：列表頁、首頁滾輪、REN 個人頁、類似房源共用 ──
   2.4 第二段照 Tesla Inventory：1px 淺灰框、圓角 8px、沒有陰影；
   滑過只把框線加深，不浮起、照片不放大（轉場只變顏色）。 */
.b-card { position: relative; display: flex; flex-direction: column; background: #fff;
          border: 1px solid var(--card-line); border-radius: 8px; overflow: hidden;
          transition: border-color var(--ease); }
.b-card:hover { border-color: var(--line2); }
.b-card .stretch { position: absolute; inset: 0; z-index: 1; -webkit-user-drag: none; }
.b-card .shot { position: relative; aspect-ratio: 16 / 10; background: var(--surface); overflow: hidden; }
.b-card .shot img { width: 100%; height: 100%; object-fit: cover; display: block; -webkit-user-drag: none; }
/* 照片左上角唯一一個標：灰白底、12px／500（Tesla 的 Reduced 標同一種） */
.b-card .tag { position: absolute; top: 12px; left: 12px; font-size: 12px; font-weight: 500;
               line-height: 1; color: var(--ink); background: rgba(244, 244, 244, 0.94);
               padding: 6px 8px; border-radius: 4px; }

/* 還沒搬真照片的房源（partials/_noshot.html）。卡片、相簿、類似房源共用一份。
   底色比 --surface 再深一點點，看起來才像「刻意留白」而不是圖沒載出來。 */
.noshot { width: 100%; height: 100%; min-height: 100%; display: flex; flex-direction: column;
          align-items: center; justify-content: center; gap: 9px; text-align: center;
          background: #f0f0f3; color: #a1a1a8; }
.noshot span { font-size: 13px; letter-spacing: 0.01em; }
.noshot svg { opacity: 0.75; }
/* 相簿那塊比較大，圖示跟著放大才不會空得莫名其妙 */
.lb-gal .noshot { gap: 14px; }
.lb-gal .noshot svg { width: 44px; height: 44px; }
.lb-gal .noshot span { font-size: 15px; }
.b-card .pad { padding: 16px 20px 20px; display: flex; flex-direction: column; flex: 1; }
.b-card h3 { margin: 0; font-size: 17px; font-weight: 500; color: var(--ink); line-height: 1.4;
             display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.b-card .price { margin: 4px 0 0; font-size: 15px; font-weight: 500; color: var(--ink); }
.b-card .price span { font-weight: 400; color: var(--muted); margin-left: 2px; }
.b-card .where { margin: 4px 0 0; font-size: 14px; color: var(--muted);
                 white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* 最下面一排規格：小圖示加 12px 字，推到卡片底部讓同一排的卡切齊 */
.b-card .specs { list-style: none; margin: auto 0 0; padding: 16px 0 0;
                 display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12px; color: var(--body); }
.b-card .specs li { display: inline-flex; align-items: center; gap: 6px; }
.b-card .specs .ico { color: var(--muted); }

/* ══ /property/ 列表頁（partials/_inventory.html，2.4 第二段，照 Tesla Inventory）══
   電腦：左邊 320px 篩選欄黏在頁頭（56px）下面、自己捲；右邊網格一排三張。
   1023 以下：篩選欄只剩標題、All／Rent／Buy 與一顆 Filters，其餘變成右邊滑出的面板。
   ⚠️ .iv-side 不准加 transform／filter／backdrop-filter：手機面板是 position:fixed，
      祖先有那三個就會改成貼著它定位（頁頭 10-03 踩過同一個坑）。 */
.iv { max-width: 1440px; margin: 0 auto; padding: 0 32px;
      display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 0 40px; align-items: start; }
.iv-side { position: sticky; top: 56px; max-height: calc(100vh - 56px); overflow-y: auto;
           padding: 32px 4px 48px 0; scrollbar-width: thin; }
.iv-title { margin: 0 0 20px; font-size: 24px; font-weight: 500; line-height: 1.3; color: var(--ink); }

/* All／Rent／Buy：灰底一條、選中的那格白底（Tesla 的 New／Used） */
.iv-seg { display: flex; padding: 4px; border-radius: 4px; background: rgba(0, 0, 0, 0.05); }
.iv-seg label { flex: 1; position: relative; cursor: pointer; }
.iv-seg input { position: absolute; opacity: 0; pointer-events: none; }
.iv-seg span { display: block; text-align: center; font-size: 14px; font-weight: 500; line-height: 32px;
               color: var(--body); border-radius: 4px; transition: background-color var(--ease), color var(--ease); }
.iv-seg input:checked + span { background: #fff; color: var(--ink); }
.iv-seg input:focus-visible + span { outline: 2px solid var(--blue); outline-offset: -2px; }

.iv-open { display: none; }
.iv-panel-head, .iv-panel-foot, .iv-scrim { display: none; }

.iv-search { position: relative; margin: 24px 0 8px; }
.iv-search input { width: 100%; font-family: inherit; font-size: 14px; color: var(--ink);
                   background: #fff; border: 1px solid var(--line2); border-radius: 4px;
                   height: 40px; padding: 0 36px 0 38px; appearance: none; -webkit-appearance: none; }
.iv-search input::-webkit-search-cancel-button { display: none; }
.iv-search input::placeholder { color: var(--faint); }
.iv-search input:focus { outline: none; border-color: var(--ink); }
.iv-search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
                 pointer-events: none; color: var(--muted); }
.iv-search .x { position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
                width: 32px; height: 32px; border: 0; border-radius: 4px; background: none;
                color: var(--muted); font-size: 14px; cursor: pointer; display: none; }
.iv-search .x:hover { background: rgba(0, 0, 0, 0.05); color: var(--ink); }
.iv-search.has .x { display: block; }

/* 每組篩選可以收起來（<details>），單選用圓點 */
.iv-group { border-bottom: 1px solid var(--line); padding: 4px 0 12px; }
.iv-group summary { list-style: none; cursor: pointer; display: flex; align-items: center;
                    justify-content: space-between; padding: 12px 0 8px;
                    font-size: 14px; font-weight: 500; color: var(--ink); }
.iv-group summary::-webkit-details-marker { display: none; }
.iv-group summary::after { content: ""; width: 7px; height: 7px; margin-right: 4px;
                           border: solid var(--muted); border-width: 0 1.5px 1.5px 0;
                           transform: rotate(-135deg) translateY(-2px); transition: transform var(--ease); }
.iv-group:not([open]) summary::after { transform: rotate(45deg) translateY(-2px); }
.iv-opt { display: flex; align-items: center; gap: 12px; padding: 6px 0; cursor: pointer;
          font-size: 14px; color: var(--body); }
.iv-opt input { appearance: none; -webkit-appearance: none; flex: none; margin: 0; cursor: pointer;
                width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--line2);
                transition: border-color var(--ease); }
.iv-opt:hover input { border-color: var(--muted); }
.iv-opt input:checked { border: 5px solid var(--ink); }
.iv-opt input:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.iv-opt span { flex: 1; }
.iv-opt em { font-style: normal; font-size: 12px; color: var(--faint); }
.iv-opt input:checked ~ span { color: var(--ink); }
.iv-select { display: block; width: 100%; height: 40px; margin: 4px 0 4px; padding: 0 32px 0 12px;
             font-family: inherit; font-size: 14px; color: var(--ink); background-color: #fff;
             border: 1px solid var(--line2); border-radius: 4px; cursor: pointer; appearance: none;
             background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='none' stroke='%235c5e62' stroke-width='1.5' d='M1 1l4 4 4-4'/%3E%3C/svg%3E");
             background-repeat: no-repeat; background-position: right 12px center; }
.iv-select:hover, .iv-select:focus { outline: none; border-color: var(--ink); }
.iv-clear { display: inline-block; margin: 16px 0 0; font-size: 14px; color: var(--ink);
            text-decoration: underline; text-underline-offset: 3px; }

.iv-main { min-width: 0; padding: 32px 0 96px; }
.iv-meta { display: flex; align-items: center; gap: 16px; min-height: 31px; margin: 0 0 20px;
           scroll-margin-top: 80px; }
.iv-count { margin: 0; font-size: 14px; color: var(--muted); }
.iv-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.iv-main .pl-empty { padding: 72px 0; }
.iv-main .pl-empty h2 { font-size: 20px; font-weight: 500; }
.iv-main .pl-empty.compact { padding: 0 0 8px; justify-content: flex-start; }
.iv-main .pl-nearby { margin-top: 40px; }
.iv-main .pl-nearby .iv-grid { margin-top: 20px; }
.iv-main .pl-pages { margin: 48px 0 0; }

@media (max-width: 1279px) { .iv-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

@media (max-width: 1023px) {
  .iv { display: block; padding: 0 16px; }
  .iv-side { position: static; max-height: none; overflow: visible; padding: 24px 0 0;
             display: grid; grid-template-columns: 1fr auto; gap: 16px 8px; align-items: center; }
  .iv-title { grid-column: 1 / -1; margin: 0; font-size: 22px; }
  .iv-open { display: block; height: 40px; padding: 0 16px; font-family: inherit; font-size: 14px;
             font-weight: 500; color: var(--ink); background: rgba(0, 0, 0, 0.05); border: 0;
             border-radius: 4px; cursor: pointer; white-space: nowrap; }
  .iv-scrim { display: block; position: fixed; inset: 0; z-index: 90; background: rgba(0, 0, 0, 0.2);
              -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
              opacity: 0; visibility: hidden; transition: opacity var(--ease), visibility var(--ease); }
  .iv-panel { position: fixed; top: 0; right: 0; bottom: 0; z-index: 91; width: min(92vw, 360px);
              background: #fff; transform: translateX(100%); overflow-y: auto;
              transition: transform 0.4s cubic-bezier(0.5, 0, 0, 0.75);
              display: flex; flex-direction: column; padding: 16px 24px 0; }
  body.ivopen { overflow: hidden; }
  body.ivopen .iv-scrim { opacity: 1; visibility: visible; }
  body.ivopen .iv-panel { transform: none; }
  .iv-panel-head { display: flex; align-items: center; justify-content: space-between;
                   font-size: 17px; font-weight: 500; color: var(--ink); }
  .iv-search { margin-top: 16px; }
  .iv-panel-foot { display: block; position: sticky; bottom: 0; margin: auto -24px 0; padding: 16px 24px;
                   padding-bottom: calc(16px + env(safe-area-inset-bottom)); background: #fff;
                   border-top: 1px solid var(--line); }
  .iv-panel-foot .btn { width: 100%; }
  .iv-main { padding-top: 20px; }
}
@media (max-width: 640px) {
  .iv-grid { grid-template-columns: 1fr; gap: 16px; }
}

/* ══ 列表頁 /property/ 還在用的幾塊（partials/_inventory.html）══
   2.5 拆掉分類 hub 與 _listing_browser.html，只用在那邊的篩選列、搜尋框、See all、網格一起刪了。 */
/* 換頁 / 換篩選時整區淡一下，讓人知道在動 */
#plResults { transition: opacity 0.15s ease; }
#plResults.busy { opacity: 0.4; pointer-events: none; }

/* ── 空狀態 ── */
.pl-empty { padding: 72px 0 120px; text-align: center; }
.pl-empty h2 { margin: 0 0 10px; font-size: 22px; font-weight: 600; color: var(--ink); }
.pl-empty p { margin: 0 0 26px; font-size: 16px; color: var(--muted); }

/* ── L4c 鄰近房源：本鎮少於 8 筆時接在下面 ── */
.pl-empty.compact { padding: 24px 0 0; display: flex; flex-wrap: wrap; align-items: center;
                    justify-content: center; gap: 12px 20px; }
.pl-empty.compact h2 { margin: 0; font-size: 16px; }
.pl-nearby { margin: 40px 0 0; padding: 28px 0 0; border-top: 1px solid rgba(0, 0, 0, 0.08); }
.pl-nearby-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 16px; }
.pl-nearby-head h2 { margin: 0; font-size: 18px; font-weight: 600; color: var(--ink); }
.pl-nearby-head a { margin-left: auto; display: inline-flex; align-items: center; gap: 2px;
                    font-size: 14px; white-space: nowrap; }
@media (max-width: 640px) { .pl-nearby-head a { margin-left: 0; } }

/* ── L5 分頁 ── */
.pl-pages { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center;
            margin: 0 0 96px; }
.pl-pages a, .pl-pages span { min-width: 40px; height: 40px; display: inline-flex;
                              align-items: center; justify-content: center; padding: 0 12px;
                              border-radius: 4px; font-size: 14px; color: var(--body); }
.pl-pages a:hover { text-decoration: none; background: rgba(0, 0, 0, 0.05); }
.pl-pages .on { background: var(--ink); color: #fff; font-weight: 500; }
.pl-pages .gap { color: var(--muted); min-width: 20px; padding: 0; }

/* ══ 置中大標題區（原本是分類 hub 的 C2，2.5 拆 hub 後只剩 Insights 列表在用）══
   走 apple.com 產品頁那種開場：白底、一個大標題置中、留白拉開。
   ⚠️ 刻意不放照片：首頁 H2 已經是深色大圖主視覺，這裡再來一張兩頁會長得一樣，
      而且商業與豪宅手上沒有對應的實景照——寧可三頁一致留白，也不借別條線的照片。 */
.hb-hero { text-align: center; padding: 92px 0 40px; }
.hb-hero .kind { font-size: 13px; font-weight: 600; letter-spacing: 0.08em;
                 text-transform: uppercase; color: var(--blue); margin: 0 0 18px; }
/* text-wrap: balance ＝ 瀏覽器自己把幾行的長度湊平，不會出現「最後一行只有一個字」。
   大標題換行的位置就是版面的一部分，這一行省掉手動塞 <br>（Henry 2026-07-29 嫌排版）*/
.hb-hero h1 { margin: 0 auto; max-width: 13em; font-weight: 700;
              font-size: clamp(36px, 6.2vw, 72px); line-height: 1.04;
              letter-spacing: -0.035em; color: var(--ink); text-wrap: balance; }
/* max-width 33em → 38em（2026-09-14）：工業頁第二句寬 747px，33em 只有 676px，
   桌面上被折成兩行。38em 讓第二句在桌面是一排，手機照樣自然折行 */
.hb-hero .sub { margin: 24px auto 0; max-width: 38em; line-height: 1.5;
                font-size: clamp(17px, 2vw, 21px); color: var(--muted); text-wrap: balance; }

@media (max-width: 640px) {
  .hb-hero { padding: 52px 0 28px; }
}

/* ══ 版面元件：首頁、內容頁共用 ══
   原本住在 home.html 的 <style> 裡，Step 4 起內容頁也要用同一套版型 → 搬到這裡。
   ⚠️ 只搬「不只首頁會用」的那幾塊；首頁專屬的（.b-hero、.b-rail、.b-cats…）留在 home.html。 */
.b-wrap { max-width: 1180px; margin: 0 auto; padding: 0 28px; }
.b-section { padding: 104px 0 0; }
.b-eyebrow { font-size: 13px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
             color: var(--muted); margin: 0 0 10px; }
.b-h2 { margin: 0 0 8px; font-size: clamp(26px, 3.4vw, 38px); font-weight: 700; letter-spacing: -0.025em;
        color: var(--ink); }
.b-lede { margin: 0 0 40px; font-size: 18px; color: var(--muted); max-width: 34em; }

/* 四項檢查面板（淺灰圓角、四欄編號 01–04）。
   原本是首頁 H6，2026-07-28 搬去三個分類 hub——每條線各查四項，欄位就是那四個。
   裡面那句要維持同一行，不套 .b-lede 的 34em 上限 */
.b-verify { background: var(--surface); border-radius: 22px; padding: 72px 56px; margin-top: 104px; }
.b-verify .b-lede { max-width: none; }
.b-verify .items { display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px; margin-top: 44px; }
/* About A4b 的六條規矩：3×2。四欄裝六條會留兩個洞，三欄剛好排滿兩排。
   直向 gap 拉大一點，不然兩排會黏成一團看不出分行 */
.b-verify .items.six { grid-template-columns: repeat(3, 1fr); gap: 44px 40px; }
/* 面板裡沒有 01–04 四欄、直接接一顆按鈕時（W5）：
   .b-verify p 的 margin 是 0，按鈕會黏在上一段字下面 → 這裡補回距離（Henry 2026-07-29）*/
.b-verify .more { margin-top: 34px; }
.b-verify .n { font-size: 13px; font-weight: 600; color: var(--blue); letter-spacing: 0.06em; }
.b-verify h3 { margin: 10px 0 8px; font-size: 19px; font-weight: 600; color: var(--ink); }
.b-verify p { margin: 0; font-size: 15px; color: var(--muted); }

/* About A3 一封署名的信。刻意不做小標、不做欄位、不做面板——
   整頁只有這一段是散文，讀者一眼就知道換人在說話了。
   40em ≈ 一行 75 個字元，散文讀起來最舒服的寬度（.b-lede 那個 34em 是給副標用的，太窄） */
/* ⚠️ 這一欄要**置中**不能靠左：上面 .hb-hero 是置中的，信一靠左右邊就空一大塊，
   讀起來像跑版（Henry 2026-07-30 在 .ag-card 點過同一件事）。 */
.ab-letter { margin: 80px auto 0; max-width: 40em; }
.ab-letter p { margin: 0 0 22px; font-size: 19px; line-height: 1.72; color: var(--body); }
/* 開場那一段放大半級：它是整封信的鉤子，也接住 H1 讓出來的份量 */
.ab-letter p:first-child { font-size: 21px; line-height: 1.62; color: var(--ink); }
/* 署名。細線＋靠右，讓它讀起來是信末不是又一段內文 */
.ab-letter .sig { margin: 34px 0 0; padding-top: 22px; border-top: 1px solid #ededf0;
                  text-align: right; font-size: 15px; color: var(--muted); }
.ab-letter .sig b { font-weight: 600; color: var(--ink); }

/* 人＋話：左邊一條直幅照，右邊文字。
   align-items: stretch + 照片 height:100% → 照片高度跟著右邊文字走，兩欄自然齊底 */
.b-about { display: grid; grid-template-columns: 0.62fr 1fr; gap: 44px; align-items: stretch;
           margin-top: 104px; }
/* align-self: start ＋ aspect-ratio：不讓照片被原始比例（854×1280）撐到比文字高一大截 */
.b-about .shot { align-self: start; aspect-ratio: 3 / 4; border-radius: 18px; overflow: hidden;
                 background: var(--surface); }
/* object-position 往上拉，臉才不會被裁掉 */
.b-about .shot img { width: 100%; height: 100%; object-fit: cover; object-position: center 18%;
                     display: block; }
.b-about .say { display: flex; flex-direction: column; justify-content: center; }
.b-about .say p { margin: 0 0 18px; font-size: 18px; line-height: 1.65; color: var(--body); }
.b-about .say p:last-of-type { margin-bottom: 0; }
.b-about .sign { display: flex; align-items: center; gap: 12px;
                 border-top: 1px solid #ededf0; margin-top: 30px; padding-top: 24px; }
.b-about .sign .nm { flex: 1; }
.b-about .sign .nm b { display: block; font-size: 17px; font-weight: 600; color: var(--ink);
                       letter-spacing: -0.015em; }
.b-about .sign .nm span { font-size: 14px; color: var(--muted); }
.b-about .links { display: flex; gap: 22px; margin-top: 22px; }
.b-about .links a { font-size: 15px; font-weight: 600; color: var(--blue); }

/* About A5 的短名片版（2026-08-12 自我介紹搬去名片頁後）。
   文字只剩兩句，照片還照 0.62fr／3:4 走的話會比文字高一大截 → 照片收成 300px 並垂直置中。 */
.b-about.card { grid-template-columns: 300px 1fr; gap: 48px; align-items: center; }
/* 名字是進名片頁的連結。h2 預設繼承 --ink，連結要看得出可以點，但不要整個變藍：
   hover 才轉藍，跟 .b-about.card .b-h2 a { color: inherit; }
.b-about.card .b-h2 a:hover { color: var(--blue); text-decoration: none; }

/* 置中的結尾 CTA */
.b-cta { text-align: center; padding: 112px 0 96px; }
.b-cta h2 { margin: 0 0 10px; font-size: clamp(26px, 3.4vw, 38px); font-weight: 700;
            letter-spacing: -0.025em; color: var(--ink); }
.b-cta p { margin: 0 0 32px; font-size: 18px; color: var(--muted); }
.b-cta .who { margin-top: 26px; font-size: 14px; color: var(--muted); }
.b-cta .btns { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

@media (max-width: 900px) {
  .b-section { padding-top: 72px; }
  .b-verify { padding: 44px 28px; }
  .b-verify .items { grid-template-columns: 1fr 1fr; gap: 28px; }
  /* 六條規矩在手機收成**單欄**，不跟上面的四項檢查一樣排兩欄：
     兩欄在 375px 只剩 117px 可用，規矩的內文比四項檢查長一倍，會擠成細長條。
     單欄剛好變回一張編號清單，本來就是這一區的體裁。 */
  .b-verify .items.six { grid-template-columns: 1fr; gap: 30px; }
  /* 手機的信：字級收一級，署名改靠左（靠右在窄欄會像跑版） */
  .ab-letter { margin-top: 56px; }
  .ab-letter p { font-size: 17px; }
  .ab-letter p:first-child { font-size: 19px; }
  .ab-letter .sig { text-align: left; }
  .b-cta .btns { flex-direction: column; align-items: stretch; }
  /* 手機：照片在上、文字在下。直幅照片在手機會太高，收成 4:3 的橫幅 */
  .b-about { grid-template-columns: 1fr; gap: 26px; margin-top: 72px; }
  .b-about.card { grid-template-columns: 1fr; gap: 26px; }
  .b-about .shot { aspect-ratio: 4 / 3; }
  /* 手機一行放不下「姓名＋REN＋公司＋兩顆鍵」，讓按鍵自己換一行 */
  .b-about .sign { flex-wrap: wrap; gap: 16px 12px; }
  .b-about .sign .nm { flex: 1 0 100%; }
  .b-about .say p { font-size: 17px; }
}


/* ══════════════════════════════════════════════════════════════════
   Step 4 批次 2：麵包屑、About、Agent 名片頁、Insights
   ══════════════════════════════════════════════════════════════════ */

/* 麵包屑（partials/_crumbs.html）。房源單頁自己有一份 .lb-crumb 的變體，
   那頁的殼比較窄，兩者長得一樣但落點不同，先不合併。 */
.crumb { padding: 26px 0 0; font-size: 13px; color: var(--muted); }
.crumb a { color: var(--muted); }
.crumb a:hover { color: var(--blue); }
.crumb span { margin: 0 6px; color: #c7c7cc; }
.crumb .here { margin: 0; color: var(--ink); }

/* About A4／名片頁 G3 的三欄連結。刻意不做成卡片：
   About 已經有 .b-verify 的灰面板和 .b-about 的照片區，再來一組卡片會太吵。 */
            margin-top: 34px; border-top: 1px solid #e5e5ea; }
               font-size: 19px; font-weight: 600; letter-spacing: -0.015em; color: var(--blue); }

/* G2 名片本體。跟 .b-about 同一個骨架（照片 30%／文字 70%），
   但照片小一點、按鈕直接放進來——名片頁的人要的就是聯絡方式，不用捲。 */
.ag-card { display: grid; grid-template-columns: 300px 1fr; gap: 48px;
           align-items: center; padding: 48px 0 8px; }
.ag-card .shot { aspect-ratio: 3 / 4; border-radius: 20px; overflow: hidden; background: #f5f5f7; }
.ag-card .shot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ag-card h1 { margin: 12px 0 6px; font-size: clamp(32px, 4.6vw, 48px); font-weight: 700;
              letter-spacing: -0.03em; color: var(--ink); }
.ag-card .cred { margin: 0 0 20px; font-size: 15px; color: var(--muted); }
/* ⚠️ 上限原本是 30em（≈570px），但這一欄實際有 776px 寬（1180 − 56 padding − 300 照片
   − 48 gap）→ 句子被提早折行，右邊空一大塊。Henry 2026-07-30：「Section 空間用完它」。
   36em ≈ 684px，一行約 90 個字元，短介紹段可以，長文才需要收窄（見 .ar）。 */
.ag-card .intro { margin: 0 0 14px; font-size: 19px; line-height: 1.55; color: var(--ink); max-width: 36em; }
/* 執業身分：法律事實不是故事，所以字級收小、顏色轉灰，跟上面那段拉開。
   ⚠️ 上限要留寬——34em 剛好把公司名的 "Sdn Bhd" 擠到第二行，明明還有空間。 */
.ag-card .lic { margin: 0 0 28px; font-size: 14px; line-height: 1.6; color: var(--muted); max-width: 46em; }
.ag-card .btns { display: flex; gap: 12px; flex-wrap: wrap; }
/* G3 的副標同樣不套 .b-lede 的 34em 上限（跟 .pl-rail-head 一樣的理由）：
   34em 會把一句話折成三行、右邊空一大半。Henry 2026-07-30 又點一次。 */
.ag-mine .b-lede { max-width: 56em; }
/* About A5 的同一句。⚠️ 選擇器要寫到 .say 這一層：
   `.b-about .say p` 是 (0,2,1)，只寫 `.b-about .lic` (0,2,0) 會被它的 font-size 蓋掉 */
.b-about .say .lic { margin-top: 22px; font-size: 14px; line-height: 1.6; color: var(--muted); }

/* Insights 卡片。原本鎖在 home.html 的 <style> 裡（H7），
   /insights/ 列表頁用同一組，所以搬到這裡共用。 */
.b-posts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.b-post { display: flex; flex-direction: column; background: #fff; border: 1px solid #e5e5ea;
          border-radius: 18px; padding: 26px; transition: border-color 0.25s ease,
          box-shadow 0.25s ease, transform 0.25s ease; }
.b-post:hover { text-decoration: none; border-color: #d8d8dd; transform: translateY(-2px);
                box-shadow: 0 12px 28px rgba(0,0,0,0.08); }
.b-post .kind { font-size: 12px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase;
                color: var(--blue); }
.b-post h3 { margin: 13px 0 10px; font-size: 19px; font-weight: 600; line-height: 1.34;
             letter-spacing: -0.015em; color: var(--ink); }
.b-post p { margin: 0 0 22px; font-size: 15px; line-height: 1.6; color: var(--muted); }
.b-post .meta { margin-top: auto; font-size: 13px; color: var(--muted); }
.b-more { margin-top: 32px; }
.b-more a { font-size: 15px; font-weight: 600; color: var(--blue); }

/* 單篇文章。窄欄（約 34em）是刻意的——長文一行超過 90 個字元就很難讀完一整篇。 */
.ar { max-width: 720px; margin: 0 auto; padding: 8px 0 0; }
.ar h1 { margin: 14px 0 0; font-size: clamp(30px, 4.4vw, 46px); font-weight: 700;
         line-height: 1.12; letter-spacing: -0.03em; color: var(--ink); text-wrap: balance; }
.ar .meta { margin: 18px 0 0; font-size: 14px; color: var(--muted); }
/* 開頭那段直球答案：AEO 的精選摘要抓的就是它，所以視覺上也要是全篇最先讀到的東西 */
.ar .answer { margin: 30px 0 0; padding: 22px 26px; background: #f5f5f7; border-radius: 14px;
              font-size: 18px; line-height: 1.6; color: var(--ink); }
.ar h2 { margin: 46px 0 14px; font-size: clamp(22px, 2.8vw, 28px); font-weight: 600;
         letter-spacing: -0.02em; color: var(--ink); }
.ar p { margin: 0 0 18px; font-size: 17px; line-height: 1.7; color: #3a3a3c; }
.ar .src { margin-top: 52px; padding-top: 26px; border-top: 1px solid #e5e5ea; }
.ar .src h2 { margin: 0 0 12px; font-size: 17px; }
.ar .src ul { margin: 0; padding-left: 18px; }
.ar .src li { font-size: 15px; line-height: 1.7; color: var(--muted); }

@media (max-width: 900px) {
        .ag-card { grid-template-columns: 1fr; gap: 26px; padding-top: 30px; }
  /* 手機的直幅照太高，收成 4:3（跟 .b-about 同一個處理） */
  .ag-card .shot { aspect-ratio: 4 / 3; }
  .ag-card .btns { flex-direction: column; align-items: stretch; }
  .b-posts { grid-template-columns: 1fr; gap: 14px; }
}

/* ══ 房源詳情頁（property_detail.html，2.4 第三段）══
   Henry 10-03 在代號模式指定的排法：
     P2 照片整排在最上面，貼滿螢幕寬；照片一張張並排（3:2，不裁成超寬），左右換
     P3 標題整排；底下兩欄：左邊規格、描述，右邊 400px 大數字加聯絡區（夠高的螢幕黏著不動）
   1023 以下：一欄，照片一次一張可滑，順序 照片、標題、大數字、聯絡區、規格、描述。 */
/* P2 相簿（Henry 10-03）：左邊 70% 封面，右邊 30% 上下兩張；第 4 張以後藏起來，按 View all 看 */
.pd-gal { position: relative; height: clamp(320px, 60vh, 640px); background: var(--surface); }
.pd-gal .noshot { height: 100%; }
.pd-track { display: grid; height: 100%; gap: 8px;
            grid-template-columns: 7fr 3fr; grid-template-rows: repeat(2, minmax(0, 1fr)); }
.pd-track img { width: 100%; height: 100%; min-height: 0; object-fit: cover; display: block;
                cursor: zoom-in; -webkit-user-drag: none; }
.pd-track img:first-child { grid-row: 1 / 3; }
.pd-track img:nth-child(n+4) { display: none; }
/* 張數不夠時：一張就整排，兩張就右邊那張佔滿高 */
.pd-track.n1 { grid-template-columns: 1fr; }
.pd-track.n2 img:nth-child(2) { grid-row: 1 / 3; }
.pd-all { position: absolute; right: 16px; bottom: 16px; z-index: 2; height: 32px; padding: 0 12px;
          border: 0; border-radius: 4px; cursor: pointer; font-family: inherit; font-size: 12px; font-weight: 500;
          color: var(--ink); background: rgba(244, 244, 244, 0.94); transition: background-color var(--ease); }
.pd-all:hover { background: #fff; }
.pd-count { display: none; position: absolute; right: 16px; bottom: 16px; z-index: 2; font-size: 12px; font-weight: 500;
            color: var(--ink); background: rgba(244, 244, 244, 0.94); padding: 6px 8px; border-radius: 4px; }

.pd { max-width: 1200px; margin: 0 auto; padding: 0 32px; }
.pd-head { padding: 32px 0 0; }
.pd-kind { margin: 0 0 8px; font-size: 12px; font-weight: 500; color: var(--muted); }
/* 標題用完整排的寬度才折行（Henry 10-03：不要 balance 平均切、不要限寬） */
.pd-head h1 { margin: 0; font-size: 32px; font-weight: 500; line-height: 1.25; color: var(--ink);
              scroll-margin-top: 80px; }
.pd-where { margin: 8px 0 0; font-size: 15px; color: var(--muted); }

.pd-body { display: grid; grid-template-columns: minmax(0, 1fr) 400px; grid-template-areas: "main side";
           gap: 0 64px; align-items: start; padding: 32px 0 64px; }
.pd-side { grid-area: side; }
.pd-main { grid-area: main; min-width: 0; }
.pd-main > .pd-sec:first-of-type { margin-top: 0; }
/* 🔴 右欄不黏著（2.5，Henry 10-03）。試過 P3b 加 P7 整欄 sticky：描述一捲完右欄就突然被帶走，
   「黏到一半就沒有了，看了頭暈」→ 整個拿掉，連原本「視窗高 760 以上才黏」那條也一起拿掉。
   聯絡方式靠底部固定列 P8（價錢加 WhatsApp）一直看得到。 */

/* 三個大數字：數字大、單位小、說明在下（Model Y 的 5.6 s、661 km） */
.pd-big { list-style: none; margin: 0 0 24px; padding: 0; display: flex; justify-content: center; }
.pd-big li { flex: 1; text-align: center; padding: 0 8px; }
.pd-big b { display: block; font-size: 24px; font-weight: 500; line-height: 1.2; color: var(--ink); white-space: nowrap; }
.pd-big small { font-size: 14px; font-weight: 400; margin-left: 3px; }
.pd-big span { display: block; margin-top: 4px; font-size: 12px; color: var(--muted); }

/* 灰底聯絡區，裡面的 REN 小卡白底 */
.pd-box { margin: 0; padding: 24px; background: var(--surface); border-radius: 8px; }
.pd-price { margin: 0; font-size: 24px; font-weight: 500; line-height: 1.25; color: var(--ink); }
.pd-price span { font-size: 14px; font-weight: 400; color: var(--muted); margin-left: 4px; }
.pd-psf { margin: 4px 0 0; font-size: 14px; color: var(--muted); }
.pd-full { width: 100%; margin-top: 20px; }
.pd-two { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
/* 只有 Call 或只有 Email 一顆時撐滿整排（2.5：名片沒有回退，Email 常常是空的）*/
.pd-two.one { grid-template-columns: 1fr; }
.pd-btn-w { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px;
            border-radius: 4px; background: #fff; color: var(--ink); font-size: 14px; font-weight: 500;
            transition: background-color var(--ease); }
.pd-btn-w:hover { text-decoration: none; background: #fafafa; }
/* 2.6 留電話表單：灰底聯絡區裡一塊白底，跟 REN 小卡同一個樣子 */
.pd-ask { margin-top: 16px; padding: 16px; background: #fff; border-radius: 8px; }
.pd-ask h3 { margin: 0 0 12px; font-size: 15px; font-weight: 500; color: var(--ink); }
.pd-ask-f { display: block; margin-top: 8px; font-size: 12px; color: var(--muted); }
.pd-ask-f input { display: block; width: 100%; margin-top: 4px; padding: 10px 12px; border: 1px solid var(--line2);
                  border-radius: 4px; font: inherit; font-size: 16px; color: var(--ink); background: #fff; }
.pd-ask-f input:focus { outline: none; border-color: var(--ink); }
.pd-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.pd-ask-go { width: 100%; margin-top: 12px; }
/* 4.4：Send 下面一行小字，講電話給誰加 Privacy Notice 連結；送出後收起來（上面那句 Sent 已經講了） */
.pd-ask-note { margin: 8px 0 0; font-size: 12px; line-height: 1.5; color: var(--muted); }
.pd-ask-note a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.pd-ask.done .pd-ask-note { display: none; }
.pd-ask-msg { margin: 8px 0 0; font-size: 14px; line-height: 1.5; color: var(--ink); }
.pd-ask-msg:empty { display: none; }
.pd-ask.bad .pd-ask-msg { color: #b3261e; }
/* 送出了：欄位與按鍵收起，只留標題與那一句 */
.pd-ask.done .pd-ask-f, .pd-ask.done .pd-ask-go { display: none; }
.pd-ren { display: flex; align-items: center; gap: 12px; margin-top: 16px; padding: 16px;
          background: #fff; border-radius: 8px; }
.pd-ren img { width: 48px; height: 48px; flex: none; border-radius: 50%; object-fit: cover;
              object-position: center 18%; background: var(--surface); }
.pd-ren b { display: block; font-size: 15px; font-weight: 500; color: var(--ink); }
.pd-ren span { display: block; font-size: 12px; line-height: 1.5; color: var(--muted); }
/* P9b 分享列（Henry 10-19）：留電話表單下面，四顆一排平分。手機（pointer: coarse）第四顆換成系統分享 */
.pd-share { margin-top: 16px; }
.pd-share > p:first-child { margin: 0 0 8px; font-size: 12px; color: var(--muted); }
.pd-share-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.pd-share-row .pd-btn-w { border: 0; padding: 0; font: inherit; cursor: pointer; }
.pd-share-copy { display: inline-flex; }
.pd-share-sys, .pd-share.sys .pd-share-copy { display: none; }
.pd-share.sys .pd-share-sys { display: inline-flex; }
.pd-share-msg { margin: 8px 0 0; font-size: 12px; color: var(--ink); overflow-wrap: anywhere; user-select: all; }
.pd-share-msg:empty { display: none; }

.pd-sec { margin: 40px 0 0; }
.pd-sec h2 { margin: 0 0 8px; font-size: 17px; font-weight: 500; color: var(--ink); }
/* 規格：標題在上、數值在下，兩欄（Henry 2026-07-28：長值自己往下折，不會撞在一起） */
.pd-tbl { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 0 32px; }
.pd-tbl div { padding: 12px 0; border-bottom: 1px solid var(--line); min-width: 0; }
.pd-tbl .k { display: block; font-size: 12px; line-height: 1.4; color: var(--muted); }
.pd-tbl .v { display: block; margin-top: 2px; font-size: 15px; line-height: 1.4; font-weight: 500;
             color: var(--ink); overflow-wrap: anywhere; }
.pd-tbl .n { display: block; margin-top: 4px; font-size: 12px; line-height: 1.45; color: var(--muted); }
/* 描述照原樣呈現：幾個空行就是幾個空行（2026-08-21） */
.pd-desc { font-size: 15px; line-height: 1.7; white-space: pre-wrap; overflow-wrap: anywhere; }

.pd-sim { max-width: 1200px; margin: 0 auto; padding: 48px 32px 32px; border-top: 1px solid var(--line); }
.pd-sim h2 { margin: 0 0 24px; font-size: 24px; font-weight: 500; color: var(--ink); }

/* 底部固定列：左標題、右價錢加 WhatsApp。頁尾要讓出它的高度 */
.pd-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: #fff;
          border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); }
.pd-bar-in { max-width: 1440px; margin: 0 auto; height: 72px; padding: 0 32px;
             display: flex; align-items: center; gap: 16px; }
.pd-bar-t { flex: 1; min-width: 0; }
.pd-bar-t b, .pd-bar-t span { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pd-bar-t b { font-size: 15px; font-weight: 500; color: var(--ink); }
.pd-bar-t span { font-size: 12px; color: var(--muted); }
.pd-bar-p { margin: 0; font-size: 17px; font-weight: 500; color: var(--ink); white-space: nowrap; }
.pd-bar-p span { font-size: 12px; font-weight: 400; color: var(--muted); margin-left: 3px; }
.pd-bar-call { display: none; }
body:has(.pd-bar) .ft { padding-bottom: calc(48px + 72px + env(safe-area-inset-bottom)); }

/* 標題捲出畫面後的細列：深灰半透明加模糊、白字（Tesla Model Y 頁）。
   它自己沒有 position:fixed 的子元素，所以可以用 backdrop-filter（.nv 不行，見上面） */
.pd-thin { position: fixed; top: 0; left: 0; right: 0; z-index: 45; height: 48px;
           background: rgba(23, 26, 32, 0.78); -webkit-backdrop-filter: blur(24px); backdrop-filter: blur(24px);
           color: #fff; transform: translateY(-100%); transition: transform var(--ease); }
.pd-thin-in { max-width: 1440px; height: 100%; margin: 0 auto; padding: 0 32px;
              display: flex; align-items: center; gap: 24px; }
.pd-thin b { flex: 1; min-width: 0; font-size: 14px; font-weight: 500;
             white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pd-thin span { font-size: 14px; white-space: nowrap; color: rgba(255, 255, 255, 0.8); }
body.pd-thin-on .pd-thin { transform: none; }
body.pd-thin-on .nv { visibility: hidden; }


/* 大圖瀏覽 */
.lbx { position: fixed; inset: 0; z-index: 100; background: rgba(23, 26, 32, 0.97);
       display: none; align-items: center; justify-content: center; }
.lbx.on { display: flex; }
.lbx img { max-width: 92vw; max-height: 84vh; object-fit: contain; user-select: none; -webkit-user-drag: none; }
.lbx .x, .lbx .arw { position: absolute; border: 0; border-radius: 4px; cursor: pointer; color: #fff;
                     background: rgba(255, 255, 255, 0.12); display: flex; align-items: center;
                     justify-content: center; transition: background-color var(--ease); }
.lbx .x:hover, .lbx .arw:hover { background: rgba(255, 255, 255, 0.24); }
.lbx .x { top: 16px; right: 16px; width: 40px; height: 40px; font-size: 16px; }
.lbx .arw { top: 50%; transform: translateY(-50%); width: 44px; height: 44px; }
.lbx .arw.p { left: 16px; }
.lbx .arw.n { right: 16px; }
.lbx .cnt { position: absolute; bottom: 24px; left: 50%; transform: translateX(-50%);
            color: rgba(255, 255, 255, 0.72); font-size: 14px; }
body.locked { overflow: hidden; }

/* 410 那一頁（2.5b）：房源自己收回或到期太久。名片與房源格沿用 REN 個人頁的 .ag-* */
.gn-head { padding-bottom: 32px; }
.gn-head h1 { margin: 0; font-size: 32px; line-height: 1.2; font-weight: 500; color: var(--ink); }
.gn-head p { margin: 8px 0 0; font-size: 16px; color: var(--muted); }
.gn-head .btn-2 { margin-top: 20px; }
.gn .ag-card { padding-top: 32px; border-top: 1px solid var(--line); }
.gn .ag-card h2 { margin: 0; font-size: 24px; line-height: 1.2; font-weight: 500; color: var(--ink); }
.gn .ag-by { margin: 0 0 4px; font-size: 14px; color: var(--muted); }

@media (max-width: 1023px) {
  /* 手機：一次一張，用手滑 */
  .pd-gal { height: auto; aspect-ratio: 4 / 3; }
  .pd-track { display: flex; gap: 0; overflow-x: auto; scroll-snap-type: x mandatory;
              scrollbar-width: none; overscroll-behavior-x: contain; }
  .pd-track::-webkit-scrollbar { display: none; }
  .pd-track img, .pd-track img:nth-child(n+4) { display: block; flex: 0 0 100%; scroll-snap-align: start; }
  .pd-all { display: none; }
  .pd-count { display: block; }
  .pd { padding: 0 16px; }
  .pd-head { padding-top: 24px; }
  .pd-head h1 { font-size: 24px; }
  .pd-body { display: block; padding: 24px 0 48px; }
  .pd-main { margin-top: 40px; }
  .pd-tbl { grid-template-columns: 1fr 1fr; gap: 0 16px; }
  .pd-sim { padding: 48px 16px 24px; }
  .pd-bar-in { padding: 0 16px; gap: 8px; }
  .pd-bar-t { display: none; }
  .pd-bar-p { flex: 1; }
  .pd-bar-call { display: inline-flex; }
  .pd-thin-in { padding: 0 16px; }
}

/* ══ 首頁（home.html，2.4 第四段）══
   H2 滿版大圖貼到螢幕邊（不再是 aboveLot 的圓角框）；H5 Tesla 首頁那種橫向大卡；
   H3 三張分類大卡；H6 About 小段。內容欄 1200px，跟詳情頁同寬。
   漸層只准墊在照片上的白字底下（第 3.3 節）。 */
.hm-wrap { max-width: 1200px; margin: 0 auto; padding: 0 32px; }
.hm-sec { padding-top: 80px; }
.hm-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.hm-head h2 { margin: 0; font-size: 24px; font-weight: 500; color: var(--ink); }
.hm-head a { display: inline-flex; align-items: center; gap: 2px; font-size: 14px; font-weight: 500; white-space: nowrap; }

.hm-hero { position: relative; height: min(78vh, 660px); min-height: 440px; overflow: hidden; background: var(--ink); }
.hm-slide { position: absolute; inset: 0; opacity: 0; transition: opacity 0.9s ease; }
.hm-slide.on { opacity: 1; }
.hm-slide img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
/* 4.17：首頁大圖底部是淺色地毯，副標吃不到對比，整張先壓一層薄的再往下加深 */
.hm-slide .shade { position: absolute; inset: 0;
                   background: linear-gradient(180deg, rgba(23,26,32,0.08) 0%, rgba(23,26,32,0.18) 40%, rgba(23,26,32,0.78) 100%); }
.hm-copy { position: absolute; left: 0; right: 0; bottom: 0; padding: 0 24px 64px; text-align: center; color: #fff; }
.hm-copy h1, .hm-copy h2 { margin: 0; font-size: clamp(36px, 5vw, 48px); font-weight: 500; line-height: 1.15; }
.hm-copy p { margin: 12px auto 0; max-width: 36em; font-size: 16px; color: rgba(255, 255, 255, 0.82); }
.hm-btns { display: flex; justify-content: center; gap: 16px; margin-top: 32px; }
.hm-btns a { min-width: 220px; }
.btn-2.hm-light { background: rgba(255, 255, 255, 0.92); color: var(--ink); }
.btn-2.hm-light:hover { background: #fff; }
.hm-go { display: inline-block; margin-top: 16px; font-size: 14px; color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.hm-dots { position: absolute; bottom: 20px; left: 0; right: 0; z-index: 2; display: flex; justify-content: center; gap: 8px; }
.hm-dots button { width: 8px; height: 8px; padding: 0; border: 0; border-radius: 50%; cursor: pointer; background: rgba(255,255,255,0.45); }
.hm-dots button.on { background: #fff; }

/* H5 橫向大卡：沿用 .b-rail 的捲動與箭頭（rail.js），只換卡片與內距。
   --inset 跟 .hm-wrap 同一組數字，第一張才會跟上面的標題切齊 */
.hm-rail { --inset: calc((100% - min(100% - 64px, 1136px)) / 2); }
.hm-rail .b-rail > * { flex: 0 0 min(560px, 82vw); }
.hm-card { position: relative; display: block; aspect-ratio: 4 / 3; border-radius: 8px; overflow: hidden;
           background: var(--surface); color: #fff; -webkit-user-drag: none; }
.hm-card:hover { text-decoration: none; }
.hm-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; -webkit-user-drag: none; }
.hm-card .shade { position: absolute; inset: 0;
                  background: linear-gradient(180deg, rgba(23,26,32,0) 45%, rgba(23,26,32,0.75) 100%); }
.hm-tag { position: absolute; top: 16px; left: 16px; font-size: 12px; font-weight: 500; line-height: 1;
          color: var(--ink); background: rgba(244, 244, 244, 0.94); padding: 6px 8px; border-radius: 4px; }
.hm-card-t { position: absolute; left: 24px; right: 24px; bottom: 20px; }
.hm-card-t h3 { margin: 0; font-size: 20px; font-weight: 500; line-height: 1.3;
                display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.hm-card-t p { margin: 4px 0 0; font-size: 14px; font-weight: 500; }
.hm-card-t p span { font-weight: 400; color: rgba(255, 255, 255, 0.8); margin-left: 8px; }

/* H3 分類大卡：有照片就鋪滿配白字，還沒有房源就是灰底深字 */
.hm-cats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.hm-cat { position: relative; display: block; aspect-ratio: 4 / 5; border-radius: 8px; overflow: hidden;
          background: var(--surface); color: #fff; }
.hm-cat:hover { text-decoration: none; }
.hm-cat img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hm-cat .shade { position: absolute; inset: 0;
                 background: linear-gradient(180deg, rgba(23,26,32,0) 45%, rgba(23,26,32,0.72) 100%); }
.hm-cat-t { position: absolute; left: 24px; right: 24px; bottom: 24px; }
.hm-cat-t h3 { margin: 0; font-size: 24px; font-weight: 500; }
.hm-cat-t span { display: inline-flex; align-items: center; gap: 2px; margin-top: 8px; font-size: 14px; font-weight: 500; }
.hm-cat.blank { color: var(--ink); }

.hm-about { padding-bottom: 32px; max-width: 760px; text-align: center; }
.hm-about h2 { margin: 0 0 16px; font-size: 24px; font-weight: 500; color: var(--ink); }
.hm-about p { margin: 0 0 24px; font-size: 16px; line-height: 1.7; }

@media (max-width: 1023px) {
  .hm-wrap { padding: 0 16px; }
  .hm-sec { padding-top: 56px; }
  .hm-rail { --inset: 16px; }
  .hm-cats { grid-template-columns: 1fr; gap: 16px; }
  .hm-cat { aspect-ratio: 16 / 9; }
}
@media (max-width: 640px) {
  .hm-copy { padding-bottom: 40px; }
  .hm-btns { flex-direction: column; align-items: center; gap: 8px; }
  .hm-btns a { width: 100%; max-width: 320px; }
  .hm-card { aspect-ratio: 3 / 4; }
}

/* ── REN 個人頁 `.ag-*`（2.4 第五段）── */
.ag { max-width: 1200px; margin: 0 auto; padding: 48px 24px 80px; }
.ag-card { display: flex; align-items: center; gap: 32px; padding-bottom: 40px; border-bottom: 1px solid var(--line); }
.ag-card img { width: 120px; height: 120px; flex: none; border-radius: 50%; object-fit: cover; background: var(--surface); }
.ag-card h1 { margin: 0; font-size: 32px; line-height: 1.2; font-weight: 500; color: var(--ink); }
.ag-cred { margin: 8px 0 0; font-size: 14px; color: var(--muted); }
.ag-tel { margin: 4px 0 0; font-size: 14px; color: var(--muted); }
.ag-btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.ag-btns .wa, .ag-btns .btn-2 { min-height: 40px; padding: 0 24px; }
.ag-list { padding-top: 40px; }
.ag-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.ag-head h2 { margin: 0; font-size: 24px; font-weight: 500; color: var(--ink); }
.ag-head h2 span { margin-left: 6px; font-size: 16px; font-weight: 400; color: var(--muted); }
.ag-head a { display: inline-flex; align-items: center; gap: 2px; font-size: 14px; font-weight: 500; white-space: nowrap; }
.ag-none { margin: 0; padding: 32px; border-radius: 8px; background: var(--surface); font-size: 16px; color: var(--muted); text-align: center; }

/* ── 關於頁 `.ab-*`（2.4 第五段）── */
.ab { max-width: 720px; margin: 0 auto; padding: 64px 24px 80px; }
.ab h1 { margin: 0 0 16px; font-size: 40px; line-height: 1.15; font-weight: 500; color: var(--ink); }
.ab-lede { margin: 0; font-size: 18px; line-height: 1.6; }
.ab-sec { margin-top: 48px; }
.ab-sec h2 { margin: 0 0 12px; font-size: 20px; font-weight: 500; color: var(--ink); }
.ab-sec p { margin: 0 0 12px; font-size: 16px; line-height: 1.7; }
/* 4.4 條款兩頁（/terms/、/privacy/）共用 `.ab`：日期一行、條列、段首粗體 */
.ab-date { margin: 12px 0 0; font-size: 14px; color: var(--muted); }
.ab-sec ul { margin: 0 0 12px; padding-left: 20px; }
.ab-sec li { margin: 0 0 6px; font-size: 16px; line-height: 1.7; }
.ab-sec p b { font-weight: 500; color: var(--ink); }
.ab-out { font-weight: 500; text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 1023px) {
  .ag { padding: 32px 16px 64px; }
  .ab { padding: 40px 16px 64px; }
}
@media (max-width: 599px) {
  .ag-card { flex-direction: column; align-items: flex-start; gap: 16px; }
  .ag-card img { width: 88px; height: 88px; }
  .ag-card h1 { font-size: 28px; }
  .ag-card > div { width: 100%; }
  .ag-btns a { flex: 1 1 0; padding: 0 12px; white-space: nowrap; }
  /* 手機：WhatsApp 自己一整排，Call、Email 在下面對分（跟房源頁同一個排法，2.5 加 Email 後） */
  .ag-btns .wa { flex-basis: 100%; }
  .ab h1 { font-size: 32px; }
    }
/* 房源頁名片的名字連到 REN 個人頁：淡底線讓人看得出能點 */
.pd-ren b a { color: inherit; text-decoration: underline; text-decoration-color: #c9cacc; text-underline-offset: 3px; }
.pd-ren b a:hover { text-decoration-color: currentColor; }

/* ── Find Agent 總表 `.fa-*`（4.50，2026-11-12）──
   版寬跟 REN 個人頁 `.ag` 一樣 1200。搜尋框沿用列表頁 `.iv-search`，地區選項沿用 `.iv-opt` 圓點；
   卡片照房源卡片 `.b-card`：1px 淺灰框、圓角 8px、沒有陰影，滑過只加深框線。
   欄數：1280 以上四欄、1024 到 1279 三欄、600 到 1023 兩欄、手機一欄（頭像在左）。 */
.fa { max-width: 1200px; margin: 0 auto; padding: 48px 24px 80px; }
.fa-head h1 { margin: 0; font-size: 32px; line-height: 1.2; font-weight: 500; color: var(--ink); }
.fa-lede { margin: 8px 0 0; font-size: 16px; color: var(--muted); }
.fa-bar { display: flex; align-items: center; gap: 8px; margin: 24px 0 0; }
.fa-bar .fa-search { flex: 0 1 420px; margin: 0; }
.fa-area { position: relative; flex: 0 0 220px; }
.fa-area summary { list-style: none; display: flex; align-items: center; height: 40px; padding: 0 32px 0 12px;
                   font-size: 14px; color: var(--ink); background: #fff; border: 1px solid var(--line2);
                   border-radius: 4px; cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
                   background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='none' stroke='%235c5e62' stroke-width='1.5' d='M1 1l4 4 4-4'/%3E%3C/svg%3E");
                   background-repeat: no-repeat; background-position: right 12px center; }
.fa-area summary::-webkit-details-marker { display: none; }
.fa-area summary:hover, .fa-area[open] summary { border-color: var(--ink); }
.fa-pop { position: absolute; top: calc(100% + 4px); left: 0; z-index: 20; min-width: 100%; max-height: 320px;
          overflow-y: auto; padding: 8px 16px; background: #fff; border: 1px solid var(--card-line); border-radius: 8px;
          box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08); }
.fa-pop .iv-opt { white-space: nowrap; }
.fa-go { min-height: 40px; padding: 0 24px; flex: none; }
.fa-list { padding-top: 32px; }
.fa-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.fa-card { position: relative; display: flex; flex-direction: column; padding: 24px 20px 20px; background: #fff;
           border: 1px solid var(--card-line); border-radius: 8px; transition: border-color var(--ease); }
.fa-card:hover { border-color: var(--line2); }
.fa-card .stretch { position: absolute; inset: 0; z-index: 1; -webkit-user-drag: none; }
.fa-face { width: 88px; height: 88px; border-radius: 50%; object-fit: cover; object-position: center 18%;
           background: var(--surface); }
.fa-body { margin: 16px 0 20px; }
.fa-body h2 { margin: 0; font-size: 17px; line-height: 1.4; font-weight: 500; color: var(--ink); }
.fa-cred { margin: 4px 0 0; font-size: 13px; line-height: 1.5; color: var(--muted); }
/* REN 號、公司名、E 號各一行（Henry 11-13） */
.fa-cred span, .fa-n span { display: block; }
.fa-n { margin: 12px 0 0; font-size: 14px; font-weight: 500; color: var(--ink); }
.fa-wa { position: relative; z-index: 2; margin-top: auto; width: 100%; }
.fa-none { margin: 0; padding: 32px; border-radius: 8px; background: var(--surface); text-align: center; }
.fa-none p { margin: 0; font-size: 16px; color: var(--muted); }
.fa-none a { display: inline-block; margin-top: 12px; font-size: 14px; color: var(--ink);
             text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 1279px) { .fa-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 1023px) {
  .fa { padding: 32px 16px 64px; }
  .fa-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
}
@media (max-width: 599px) {
  .fa-head h1 { font-size: 28px; }
  .fa-bar { flex-wrap: wrap; }
  .fa-bar .fa-search { flex: 1 1 100%; }
  .fa-area { flex: 1 1 0; min-width: 0; }
  .fa-grid { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  /* 手機一欄：頭像在左、字在右，WhatsApp 一整排在下面 */
  .fa-card { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 0 16px; align-items: start; padding: 16px; }
  .fa-face { width: 64px; height: 64px; }
  .fa-body { margin: 0; }
  .fa-wa { grid-column: 1 / -1; margin-top: 16px; }
}
/* 4.50：個人頁頂端的麵包屑，.ag 已有上內距，不再多推 */
.ag > .crumb { padding: 0 0 24px; }
