/* 汐止濟德宮官網 — 共用設計系統
   配色沿用 LIFF 表單：赤陶橘 + 米白 + 墨棕，與 LINE 圖文選單同一視覺語言 */
:root {
  --clay: #b5663f;
  --clay-d: #8f4f30;
  --clay-deep: #6e3a22;
  --cream: #f7efe4;
  --cream-2: #fffdfa;
  --ink: #3a2b22;
  --ink-soft: #6f5d4f;
  --ink-faint: #a08a78;
  --gold: #c9962e;
  --line: #e2d6c6;
  --radius: 16px;
  --shadow: 0 2px 14px rgba(150, 90, 50, .10);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: -apple-system, "PingFang TC", "Noto Sans TC", "Helvetica Neue", sans-serif;
  background: var(--cream);
  color: var(--ink);
  line-height: 1.85;
  -webkit-text-size-adjust: 100%;
}
h1, h2, h3, .serif {
  font-family: "Noto Serif TC", "PingFang TC", serif;
  letter-spacing: .06em;
  color: var(--clay-deep);
}
a { color: var(--clay-d); }
img, svg { max-width: 100%; }

/* ── 頂欄 ── */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(247, 239, 228, .96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
  transition: transform .3s ease;
}
.topbar.hide { transform: translateY(-100%); }
.topbar-in {
  max-width: 960px; margin: 0 auto; padding: 10px 16px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-mark {
  width: 40px; height: 40px; border-radius: 10px; background: var(--clay);
  display: flex; align-items: center; justify-content: center; flex: 0 0 auto;
}
.brand-name { font-family: "Noto Serif TC", serif; font-size: 19px; font-weight: 700; color: var(--clay-deep); letter-spacing: .12em; }
.brand-sub { display: block; font-size: 10.5px; color: var(--ink-faint); letter-spacing: .28em; font-weight: 400; }
.nav-btn {
  border: 1px solid var(--line); background: var(--cream-2); border-radius: 10px;
  padding: 8px 12px; font-size: 14px; color: var(--clay-d); font-weight: 600; cursor: pointer;
}
.topbar-right { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.topbar-social { display: flex; align-items: center; gap: 8px; }
.topbar-social a { color: var(--ink-soft); display: inline-flex; line-height: 0; }
.topbar-social a:hover { color: var(--clay); }
@media (max-width: 420px) {
  .topbar-right { gap: 6px; }
  .topbar-social { gap: 5px; }
  .topbar-social svg { width: 18px; height: 18px; }
}

/* 手機（<820px）：點「☰ 選單」滿版展開 —— 城崎「山ノ帳」(shinzan-kinosaki.jp) 路線
   （2026-07-31 由 3×3 直書格子改版，Lasek 指定）：
   進場動態、慢速曲線 cubic-bezier(.19,1,.22,1) 取自城崎；清單結構（整寬分隔線、
   左對齊文字、最右側箭頭、大行距留白）取自上方落語協会 kamigatarakugo.jp。
   不做城崎的「置底」區塊（地址/SNS/次要連結）。
   9 大類為主，有子項者最右帶 ⌄，點一下子項在該類正下方展開（沿用既有手風琴 JS），
   再點同一個收合、點另一個切換；無子項的（首頁/顯靈錄/光明燈牆/志工招募）帶 › 直接導頁。
   ⚠️ 進場用 animation 不用 transition：overlay 是從 display:none 切進來的，
   transition 不會觸發，animation 對「新顯示的元素」才會跑。
   ⚠️ 2026-07-31 二修（Lasek）：深底米白字 → **米白底深赤陶字**（明暗對調，和紙感），
   行距加大到日站的 1.5em 級距，文字左對齊、箭頭右對齊。 */
.nav-links { display: none; }
.nav-links.open {
  display: flex; flex-direction: column; align-items: center;
  position: fixed; inset: 0; z-index: 49;
  background: var(--cream); direction: ltr;
  padding: 92px 24px 64px; overflow-x: hidden; overflow-y: auto;
  animation: navOverlayIn .5s ease both;
}
@keyframes navOverlayIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes navItemIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* 大類列：整寬一列一項、**文字靠左、箭頭靠右**（flex space-between），
   行距比照日站 1.5em 級距留白；每列下方整寬細分隔線 */
.nav-links.open > a,
.nav-links.open .nav-group-title {
  writing-mode: horizontal-tb; text-orientation: initial; direction: ltr;
  font-family: "Noto Serif TC", "PingFang TC", serif;
  color: var(--clay-deep); text-decoration: none; font-weight: 600;
  font-size: clamp(19px, 4.8vw, 22px); letter-spacing: .1em;
  width: 100%; max-width: 420px; box-sizing: border-box;
  display: flex; align-items: center; justify-content: space-between;
  flex-shrink: 0;
  height: auto; padding: 26px 4px 24px; margin: 0; line-height: 1.4;
  border-bottom: 1px solid var(--line);
  text-align: left; white-space: nowrap;
  animation: navItemIn 1.1s cubic-bezier(.19, 1, .22, 1) both;
  animation-delay: var(--nav-d, 0s);
}
/* 手機選單不列「首頁」（2026-07-31 Lasek：點左上角廟名 logo 即回首頁，.brand 本來就連 index.html
   且開選單時有 z-index:51 浮在 overlay 上點得到）。桌機直書選單不受影響，仍有首頁 */
.nav-links.open > a[href$="index.html"] { display: none; }
/* 清單最上緣補一條，整體才像一張完整的表（首頁拿掉後，新廟建設＝第一列） */
.nav-links.open .nav-group-title[href$="fund.html"] { border-top: 1px solid var(--line); }
/* 手機選單刻意「不標示目前所在分類」（2026-07-31 Lasek）：全站色票裡金色只留給
   新廟建設的「募款中」標籤，選單文字一律同色，版面最乾淨。
   桌機直書選單仍保留 .active 金色，兩邊刻意不同。 */
.nav-links.open > a.active,
.nav-links.open .nav-group-title.active { color: var(--clay-deep); }

/* 箭頭一律靠右（margin-left:auto 把偽元素推到最右）：
   有子項的大類 ⌄（展開轉 180°）；沒子項的直接導頁用 ›（比照日站每列都有箭頭） */
.nav-links.open .nav-group-title::after,
.nav-links.open > a::after {
  margin-left: auto; padding-left: 12px; font-size: .78em;
  color: var(--ink-faint); transition: transform .28s ease;
}
.nav-links.open .nav-group-title::after { content: "⌄"; }
.nav-links.open > a::after { content: "›"; }
.nav-links.open .nav-group.open .nav-group-title::after { transform: rotate(180deg); }

/* 分組容器攤平（display:contents）：標題與子目錄帶各自成為 flex 項目 */
.nav-links.open .nav-group { display: contents; }

/* 新廟建設＝全站重點：金色粗體 + 右邊金色「募款中」小標。
   （2026-07-31 定案：手機選單不標示所在分類，金色就完全空出來只代表這一件事，不再撞色）
   ⚠️ 這排是 flex（文字靠左、::after 箭頭 margin-left:auto 靠右），偽元素預設依文件順序
   排成 ::before → 文字 → ::after，所以標籤要用 order 擠到文字右邊、箭頭左邊。 */
.nav-links.open .nav-group-title[href$="fund.html"] { color: var(--gold); font-weight: 700; }
.nav-links.open .nav-group-title[href$="fund.html"]::before {
  content: "募款中"; order: 1;
  margin-left: 10px; padding: 3px 9px 4px;
  background: var(--gold); color: var(--cream);
  font-size: 11px; font-weight: 600; letter-spacing: .08em; line-height: 1;
  border-radius: 999px; white-space: nowrap;
}
.nav-links.open .nav-group-title[href$="fund.html"]::after { order: 2; }

/* 單欄排列順序（flex order）＋逐項淡入延遲（每項錯開 .05s，比對 href 免改 145 頁 HTML）：
   新廟建設 → 最新消息 → 關於濟德宮 → 奉祀神明 → 信眾服務 → 顯靈錄 → 光明燈牆 → 志工招募 */
.nav-links.open .nav-group-title[href$="fund.html"]    { order: 20; --nav-d: .05s; }
.nav-links.open .nav-group-title[href$="news.html"]    { order: 30; --nav-d: .10s; }
.nav-links.open .nav-group-title[href$="history.html"] { order: 40; --nav-d: .15s; }
.nav-links.open .nav-group-title[href$="deities.html"] { order: 50; --nav-d: .20s; }
.nav-links.open .nav-group-title[href$="visit.html"]   { order: 60; --nav-d: .25s; }
.nav-links.open > a[href$="miracles.html"]             { order: 70; --nav-d: .30s; }
.nav-links.open > a[href$="lanterns.html"]             { order: 80; --nav-d: .35s; }
.nav-links.open > a[href^="https://docs.google.com"]   { order: 90; --nav-d: .40s; }

/* 子目錄帶：緊貼所屬大類正下方（order = 該類 +5），收合時 0 高不佔位，
   .nav-group.open 時展開；跟著大類一起靠左排 */
/* ⚠️ flex-shrink:0 是必要的：overlay 是 flex column，真機扣掉 Safari 上下工具列後
   可視高度只剩 ~660px，內容一超出，flex 子項預設會被「壓扁」而不是讓容器捲動
   → 子目錄那排高度被壓到一半、文字被 overflow:hidden 切掉（2026-07-31 真機回報的 bug）。
   釘住高度後改由 .nav-links.open 的 overflow-y:auto 接手捲動，才是對的行為。 */
.nav-links.open .nav-group-items {
  width: 100%; max-width: 420px; box-sizing: border-box;
  display: flex; flex-wrap: wrap;
  justify-content: flex-start; align-items: center;
  flex-shrink: 0;
  gap: 4px clamp(16px, 5vw, 26px);
  max-height: 0; overflow: hidden; transition: max-height .32s ease;
}
/* 子目錄展開時自己也帶一條底線，收合時不留線（max-height 0 仍會畫 border） */
.nav-links.open .nav-group.open .nav-group-items {
  max-height: 260px; padding: 14px 4px 18px;
  border-bottom: 1px solid var(--line);
}
.nav-links.open .nav-group-title[href$="fund.html"]    + .nav-group-items { order: 25; }
.nav-links.open .nav-group-title[href$="news.html"]    + .nav-group-items { order: 35; }
.nav-links.open .nav-group-title[href$="history.html"] + .nav-group-items { order: 45; }
.nav-links.open .nav-group-title[href$="deities.html"] + .nav-group-items { order: 55; }
.nav-links.open .nav-group-title[href$="visit.html"]   + .nav-group-items { order: 65; }
.nav-links.open .nav-group-items a {
  writing-mode: horizontal-tb; text-orientation: initial; direction: ltr;
  font-family: "Noto Serif TC", "PingFang TC", serif;
  color: var(--ink-soft); text-decoration: none; font-weight: 500;
  font-size: clamp(15px, 4vw, 17px); letter-spacing: .1em;
  padding: 8px 2px; line-height: 1.5;
}

/* 3×3 版遺留的排間分隔線：各頁 JS 仍會注入 .nav-sep，城崎路線不需要，一律不顯示
   （留著這條規則就不必動 145 頁的內嵌腳本） */
.nav-sep,
.nav-links.open .nav-sep { display: none; }

/* 動效偏好：使用者要求減少動態時，選單直接顯示不做淡入 */
@media (prefers-reduced-motion: reduce) {
  .nav-links.open,
  .nav-links.open > a,
  .nav-links.open .nav-group-title { animation: none; }
}

/* 選單專屬的關閉按鈕：固定右上角，觸控目標 ≥44px（米白底版＝深赤陶描邊深色 ✕） */
.nav-close {
  display: none;
}
body.nav-open .nav-close {
  display: flex;
}
.nav-close {
  position: fixed; top: 14px; right: 16px; z-index: 51;
  width: 44px; height: 44px; align-items: center; justify-content: center;
  border-radius: 50%; border: 1.5px solid rgba(110, 58, 34, .35);
  background: rgba(255, 255, 255, .5); color: var(--clay-deep);
  font-size: 20px; line-height: 1; cursor: pointer;
}
/* 極窄螢幕（iPhone SE/mini 級距）稍微收行距，但仍維持日站的留白感（不夠放就讓它捲） */
@media (max-width: 420px) {
  .nav-links.open { padding: 82px 18px 40px; }
  .nav-links.open > a,
  .nav-links.open .nav-group-title {
    padding: 22px 2px 20px;
    font-size: clamp(18px, 4.8vw, 21px);
  }
  .nav-links.open .nav-group-items a { font-size: clamp(14px, 3.8vw, 15px); }
}
body.nav-open { overflow: hidden; }
/* 選單改米白底後，topbar 與 overlay 同色即可（原本深底時的反白覆蓋全部拿掉） */
body.nav-open .topbar { background: var(--cream); border-bottom-color: transparent; backdrop-filter: none; }
/* 選單展開時把廟名浮到 overlay 之上（.brand 與 .nav-links 是 topbar-in 的兄弟節點，
   overlay z-index 49 在同一個堆疊脈絡裡會蓋住廟名；比照城崎「開選單仍看得到 header」） */
body.nav-open .brand { position: relative; z-index: 51; }

/* 桌機（≥820px）：topbar 單列 — brand 左、直書選單置中、社群圖標最右；
   主選單文字直書（復古楹聯/籤筒感），首頁在最左（由左至右讀，對齊武德宮排法），9 項並排絕不換行；
   各項固定同高、置頂對齊，文字用 justify 撐滿高度（2 字項會上下分開，屬預期效果）；
   下拉子選單維持橫書面板 */
@media (min-width: 820px) {
  .nav-btn { display: none; }
  .nav-close { display: none !important; }
  .nav-sep { display: none !important; }
  .nav-links,
  .nav-links.open {
    display: flex; position: static; inset: auto; background: none;
    flex-direction: row; flex-wrap: nowrap; justify-content: center; align-items: flex-start;
    direction: ltr; gap: 34px; flex: 1 1 auto; margin: 0; padding: 4px 8px 0; overflow: visible;
  }
  .nav-links > a,
  .nav-links.open > a,
  .nav-drop-btn {
    writing-mode: vertical-rl; text-orientation: mixed; direction: ltr;
    flex: 0 0 auto; display: inline-block;
    padding: 16px 4px; font-size: 16px; font-weight: 600; letter-spacing: normal;
    line-height: 1.15; height: 132px; white-space: nowrap;
    text-align: justify; text-align-last: justify;
    color: var(--ink-soft); background: none; border: none; border-right: none;
    font-family: "Noto Serif TC", "PingFang TC", serif; cursor: pointer; border-radius: 8px;
    text-decoration: none;
  }
  .nav-links > a.active,
  .nav-links.open > a.active,
  .nav-drop-btn.active { color: var(--clay-d); background: rgba(181, 102, 63, .1); }
  .nav-links > a.nav-gold,
  .nav-links.open > a.nav-gold { color: var(--gold); font-weight: 700; }
  .nav-links > a.nav-gold.active,
  .nav-links.open > a.nav-gold.active { background: rgba(201, 150, 46, .14); }
  .nav-drop.nav-gold > .nav-drop-btn { color: var(--gold); font-weight: 700; }
  .nav-drop.nav-gold > .nav-drop-btn.active { background: rgba(201, 150, 46, .14); }
  /* 新廟建設移到首頁之前（order:-1，其餘主選單項預設 order:0） */
  .nav-drop.nav-gold { order: -1; }
  body.nav-open .topbar { background: rgba(247, 239, 228, .96); border-bottom-color: var(--line); backdrop-filter: blur(8px); }
  body.nav-open .brand-name { color: var(--clay-deep); }
  body.nav-open .brand-sub { color: var(--ink-faint); }

  /* 有子目錄的主選單 hover / 點按下拉（橫書面板），手機則改用 .nav-group 分組直行 */
  .nav-drop { display: inline-block; position: relative; }
  .nav-group { display: none; }
  /* 面板貼齊主項底部（top:100% 無 margin 空隙），視覺間距用透明 ::before 橋接層補，
     游標從主項移到面板的路徑永遠落在觸發區內；顯示/隱藏交給 JS（hover intent） */
  .nav-drop-menu {
    display: none; position: absolute; top: 100%; left: 50%; transform: translateX(-50%);
    margin-top: 6px; min-width: 132px; padding: 6px;
    background: var(--cream-2); border: 1px solid var(--line); border-radius: 10px;
    box-shadow: var(--shadow); z-index: 60;
    writing-mode: horizontal-tb;
  }
  .nav-drop-menu::before {
    content: ""; position: absolute; left: -10px; right: -10px; top: -10px; height: 12px;
  }
  .nav-drop-item {
    display: block; padding: 8px 12px; font-size: 13.5px; font-weight: 600; letter-spacing: .1em;
    writing-mode: horizontal-tb; text-orientation: initial;
    color: var(--ink-soft); text-decoration: none; white-space: nowrap; border-radius: 8px;
  }
  .nav-drop-item.active { color: var(--clay-d); background: rgba(181, 102, 63, .1); }
  .nav-drop.open .nav-drop-menu { display: block; }
}
@media (max-width: 819.98px) {
  .nav-drop { display: none; }
}

/* 各頁錨點目標：避免被 sticky 頂欄蓋住（桌機頂欄因直書選單較高，v2.5 選單加高後同步校準） */
[id] { scroll-margin-top: 96px; }
@media (min-width: 820px) {
  [id] { scroll-margin-top: 189px; }
}

/* ── 版面 ── */
.wrap { max-width: 960px; margin: 0 auto; padding: 0 16px; }
.section { padding: 44px 0 12px; }
.section-head { margin-bottom: 18px; }
.section-head h2 { font-size: 24px; margin: 0 0 4px; }
.section-head p { margin: 0; color: var(--ink-soft); font-size: 14.5px; }
.kicker { font-size: 12.5px; letter-spacing: .3em; color: var(--gold); font-weight: 700; margin-bottom: 6px; }

.card {
  background: var(--cream-2); border-radius: var(--radius);
  padding: 20px 18px; box-shadow: var(--shadow); border: 1px solid rgba(226, 214, 198, .6);
}
.grid { display: grid; gap: 14px; }
@media (min-width: 680px) {
  .grid-2 { grid-template-columns: 1fr 1fr; }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
}

/* ── Hero ── */
.hero { background: var(--clay); color: var(--cream); overflow: hidden; }
.hero-in {
  max-width: 960px; margin: 0 auto; padding: 40px 20px 0;
  display: flex; flex-direction: column; align-items: center; text-align: center;
}
.hero h1 { color: var(--cream); font-size: 34px; margin: 10px 0 2px; letter-spacing: .18em; }
.hero .hero-sub { color: rgba(247, 239, 228, .85); font-size: 15px; letter-spacing: .1em; margin: 0 0 6px; }
.hero .hero-tag { font-size: 12.5px; letter-spacing: .34em; color: var(--gold); font-weight: 700; }
.hero-art { width: min(440px, 88%); margin-top: 18px; display: block; }
.hero-cta { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; margin: 22px 0 34px; }

/* ── Hero 滿版照片版（首頁專用，不影響 fund.html 沿用的 .hero 插畫版） ── */
.hero--photo {
  position: relative;
  background: var(--clay) url("hero_night.webp") center / cover no-repeat;
}
.hero--photo::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(20, 12, 8, .78), rgba(20, 12, 8, .38) 55%, rgba(20, 12, 8, .30));
}
.hero--photo .hero-in {
  position: relative; z-index: 1;
  min-height: 68vh; justify-content: center;
  padding-top: 20px;
}
.hero--photo .hero-tag,
.hero--photo h1,
.hero--photo .hero-sub {
  text-shadow: 0 2px 10px rgba(0, 0, 0, .45);
}
@media (min-width: 820px) {
  .hero--photo .hero-in { min-height: 75vh; }
}
@media (max-width: 819.98px) {
  .hero--photo .hero-in { min-height: 58vh; }
}

.btn {
  display: inline-block; text-decoration: none; text-align: center;
  padding: 13px 22px; border-radius: 12px; font-size: 15.5px; font-weight: 700;
  border: none; cursor: pointer;
}
.btn-solid { background: var(--cream); color: var(--clay-d); }
.btn-ghost { background: transparent; color: var(--cream); border: 1.5px solid rgba(247, 239, 228, .7); }
.btn-clay { background: var(--clay); color: #fff; }
.btn-clay:active { background: var(--clay-d); }
.btn-line { background: #06c755; color: #fff; }
.btn-block { display: block; width: 100%; }

/* ── 資訊條 ── */
.info-strip { margin-top: -1px; background: var(--clay-deep); color: var(--cream); font-size: 13.5px; }
.info-strip .wrap { display: flex; flex-wrap: wrap; gap: 4px 22px; padding: 10px 16px; justify-content: center; }
.info-strip span { white-space: nowrap; opacity: .92; }

/* ── 卡片內元素 ── */
.feature-icon {
  width: 52px; height: 52px; border-radius: 14px; background: var(--clay);
  display: flex; align-items: center; justify-content: center; margin-bottom: 10px;
}
.card h3 { font-size: 18px; margin: 0 0 6px; }
.card p { font-size: 14.5px; color: var(--ink-soft); margin: 0; }
.card .more { display: inline-block; margin-top: 10px; font-size: 14px; font-weight: 700; text-decoration: none; }

/* ── 表格 ── */
.tbl-scroll { overflow-x: auto; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 14.5px; background: var(--cream-2); border-radius: 12px; overflow: hidden; }
.tbl th { background: var(--clay); color: var(--cream); text-align: left; padding: 10px 12px; font-weight: 600; white-space: nowrap; }
.tbl td { padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.tbl tr:last-child td { border-bottom: none; }

/* ── 時間軸（廟史） ── */
.timeline { position: relative; margin: 8px 0 0; padding-left: 26px; }
.timeline::before {
  content: ""; position: absolute; left: 8px; top: 6px; bottom: 6px;
  width: 2px; background: var(--line);
}
.tl-item { position: relative; padding: 0 0 26px; }
.tl-item::before {
  content: ""; position: absolute; left: -24px; top: 8px; width: 12px; height: 12px;
  border-radius: 50%; background: var(--clay); border: 3px solid var(--cream);
  box-shadow: 0 0 0 2px var(--clay);
}
.tl-item.gold::before { background: var(--gold); box-shadow: 0 0 0 2px var(--gold); }
.tl-year { font-family: "Noto Serif TC", serif; font-size: 17px; font-weight: 700; color: var(--clay-d); }
.tl-item h3 { font-size: 16.5px; margin: 2px 0 4px; }
.tl-item p { margin: 0; font-size: 14.5px; color: var(--ink-soft); }

/* ── 神明卡 ── */
.deity-card { display: flex; flex-direction: column; }
.deity-head { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.deity-head .feature-icon { margin: 0; }
.deity-title h3 { margin: 0; font-size: 19px; }
.deity-title .pos { font-size: 12.5px; color: var(--ink-faint); }
.deity-duty { font-size: 13px; color: var(--gold); font-weight: 700; margin-bottom: 6px; letter-spacing: .05em; }

/* ── 募款頁 ── */
.progress-box { text-align: center; }
.progress-num { font-family: "Noto Serif TC", serif; font-size: 42px; font-weight: 700; color: var(--clay-d); line-height: 1.2; }
.progress-num small { font-size: 15px; color: var(--ink-faint); font-weight: 400; }
.progress-bar { height: 14px; background: #eadfce; border-radius: 99px; overflow: hidden; margin: 14px 0 6px; }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--clay), var(--gold)); border-radius: 99px; }
.bank-box { border: 1.5px dashed var(--clay); border-radius: 12px; padding: 14px 16px; background: #faf3ea; font-size: 15px; }
.bank-box b { color: var(--clay-d); }

/* ── 燈牆 ── */
.lantern-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.lantern {
  background: linear-gradient(180deg, #fff6e6, #ffe9c4);
  border: 1px solid #eed9ae; border-radius: 12px; padding: 12px 6px 10px;
  text-align: center; box-shadow: 0 1px 8px rgba(201, 150, 46, .18);
}
.lantern .flame { font-size: 22px; display: block; animation: flicker 2.4s ease-in-out infinite; }
.lantern .lname { font-family: "Noto Serif TC", serif; font-size: 15px; font-weight: 700; color: var(--clay-deep); display: block; margin-top: 4px; }
.lantern .ltype { font-size: 11px; color: var(--ink-faint); }
@keyframes flicker { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: .78; transform: scale(.94); } }

/* ── 顯靈錄 ── */
.story-card { border-left: 4px solid var(--gold); }
.story-meta { font-size: 12.5px; color: var(--ink-faint); margin-top: 10px; }
.empty-state { text-align: center; padding: 36px 16px; color: var(--ink-soft); }
.empty-state .big { font-size: 40px; display: block; margin-bottom: 8px; }

/* ── 最新消息列表（分類 tabs + 卡片列表） ── */
.news-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 18px; }
.news-tab {
  border: 1px solid var(--line); background: var(--cream-2); border-radius: 99px;
  padding: 8px 16px; font-size: 13.5px; font-weight: 700; color: var(--ink-soft); cursor: pointer;
}
.news-tab.active { background: var(--clay); border-color: var(--clay); color: #fff; }
.news-list { display: flex; flex-direction: column; gap: 14px; }
.news-item-date { font-size: 12.5px; color: var(--ink-faint); margin-left: 8px; }
.news-empty { text-align: center; padding: 30px 16px; color: var(--ink-soft); }

/* 麵包屑（消息內頁） */
.breadcrumb { font-size: 13px; color: var(--ink-faint); margin-bottom: 14px; }
.breadcrumb a { color: var(--ink-faint); text-decoration: none; }
.breadcrumb a:hover { color: var(--clay-d); }

/* ── 消息內頁兩欄版型：桌機左側分類側欄 + 右側內文欄（縮窄集中）；
   手機側欄收成內文上方一排分類 chips、「最新消息」小清單隱藏 ── */
.article-layout { display: block; }
.article-side { margin-bottom: 18px; }
.side-title { font-size: 12.5px; letter-spacing: .24em; color: var(--gold); font-weight: 700; margin-bottom: 8px; }
.side-cats { display: flex; flex-wrap: wrap; gap: 8px; }
.side-cats a {
  border: 1px solid var(--line); background: var(--cream-2); border-radius: 99px;
  padding: 6px 14px; font-size: 13px; font-weight: 700; color: var(--ink-soft); text-decoration: none;
}
.side-cats a.active { background: var(--clay); border-color: var(--clay); color: #fff; }
.side-latest { display: none; }
@media (min-width: 820px) {
  .article-layout { display: grid; grid-template-columns: 192px minmax(0, 1fr); gap: 28px; align-items: start; }
  .article-side { position: sticky; top: 189px; margin: 0; }
  .side-cats { display: block; }
  .side-cats a {
    display: block; border: none; background: none; border-radius: 8px;
    padding: 8px 12px; font-size: 14px;
  }
  .side-cats a:hover { background: rgba(181, 102, 63, .07); }
  .side-cats a.active { background: rgba(181, 102, 63, .1); color: var(--clay-d); }
  .side-latest { display: block; margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--line); }
  .side-latest a {
    display: block; padding: 6px 12px; font-size: 13px; line-height: 1.6;
    color: var(--ink-soft); text-decoration: none; border-radius: 8px;
  }
  .side-latest a:hover { color: var(--clay-d); background: rgba(181, 102, 63, .07); }
  .article-main { max-width: 680px; }
}

/* ── 最新消息內頁內文（參考武德宮文章頁排版：字不大、行距鬆、段距大） ── */
.article-body { font-size: 16px; letter-spacing: 1px; line-height: 2.1; }
.article-body p { margin: 0 0 30px; }
.article-body p:last-child { margin-bottom: 0; }
.article-body img { display: block; width: 100%; border-radius: 12px; margin: 20px 0 30px; }

/* ── v2.4 照片區塊（石柱廟景/委員照片/相簿/內文圖） ── */
.content-img { display: block; width: 100%; border-radius: 12px; margin: 16px 0 4px; }
.figure-cap { font-size: 12.5px; color: var(--ink-faint); margin: 2px 0 12px; }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
.photo-grid-lg { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.photo-card { display: block; text-decoration: none; }
.photo-card img { width: 100%; border-radius: 12px; display: block; box-shadow: var(--shadow); }
.photo-card .pname { font-size: 13.5px; margin-top: 6px; color: var(--ink-soft); font-weight: 600; text-align: center; }
.album-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.album-card {
  display: block; text-decoration: none; background: var(--cream-2); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow); border: 1px solid rgba(226, 214, 198, .6);
}
.album-card img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block; }
.album-card .a-body { padding: 10px 14px 14px; }
.album-card .a-title { font-family: "Noto Serif TC", "PingFang TC", serif; font-size: 15px; font-weight: 700; color: var(--clay-deep); line-height: 1.5; }
.album-card .a-date { font-size: 12.5px; color: var(--ink-faint); margin-top: 2px; }

/* ── 提示/註記 ── */
.note { font-size: 12.5px; color: var(--ink-faint); margin-top: 8px; }
.badge { display: inline-block; font-size: 11.5px; background: #f3e6d2; color: var(--clay-d); border-radius: 99px; padding: 2px 10px; font-weight: 700; letter-spacing: .05em; vertical-align: middle; }
/* 消息分類四色（淺色底＋同系深色字，對比足夠且與米白赤陶配色和諧）：
   活動快訊=赤陶橘、重建新廟=金、廟宇公告=墨棕、新聞報導=深青 */
.badge-activity { background: rgba(181, 102, 63, .16); color: var(--clay-d); }
.badge-rebuild { background: rgba(201, 150, 46, .2); color: #8a6413; }
.badge-notice { background: rgba(111, 93, 79, .16); color: var(--ink-soft); }
.badge-media { background: rgba(74, 122, 111, .16); color: #3d6559; }

/* ── 首頁最新消息：左輪播圖 + 右列表兩欄 ── */
.news-flex { display: flex; flex-direction: column; gap: 16px; }
.news-carousel {
  position: relative; overflow: hidden; border-radius: var(--radius);
  box-shadow: var(--shadow); border: 1px solid rgba(226, 214, 198, .6);
  aspect-ratio: 16 / 9; background: var(--clay-deep);
}
.news-carousel .nc-slide {
  position: absolute; inset: 0; display: block;
  opacity: 0; transition: opacity .8s ease;
}
.news-carousel .nc-slide.active { opacity: 1; z-index: 1; }
.news-carousel img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nc-cap {
  position: absolute; left: 10px; bottom: 10px; z-index: 2;
  background: rgba(58, 43, 34, .64); color: var(--cream);
  font-size: 13px; line-height: 1; padding: 6px 10px; border-radius: 8px;
}
.nc-dots { position: absolute; left: 0; right: 0; bottom: 10px; z-index: 2; display: flex; justify-content: center; gap: 6px; }
.nc-dots button {
  width: 7px; height: 7px; padding: 0; border: none; border-radius: 50%;
  background: var(--cream); opacity: .75; cursor: pointer;
}
.nc-dots button.active { background: var(--clay); opacity: 1; }
@media (min-width: 820px) {
  .news-flex { flex-direction: row; align-items: flex-start; gap: 24px; }
  .news-carousel { flex: 0 0 44%; aspect-ratio: 16 / 10.6; }
  .news-flex .news-brief { flex: 1; }
}

/* ── 首頁最新消息（緊湊列表：日期＋分類標籤＋標題） ── */
.news-brief { padding: 4px 0; }
.news-brief a {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 13px 18px; text-decoration: none;
  border-bottom: 1px solid var(--line);
}
.news-brief a:last-child { border-bottom: none; }
.news-brief .nb-date { font-size: 13px; color: var(--ink-faint); flex: 0 0 auto; }
.news-brief .nb-title { font-size: 15px; font-weight: 600; color: var(--ink); line-height: 1.6; }
.news-brief a:hover .nb-title { color: var(--clay-d); }
/* 手機：標題一律換到第二行（第一行固定＝日期＋分類標籤），五則格式統一不參差 */
@media (max-width: 819.98px) {
  .news-brief a { row-gap: 2px; }
  .news-brief .nb-title { flex-basis: 100%; }
}

/* ── CTA 區 ── */
.cta-band { background: var(--clay); border-radius: var(--radius); color: var(--cream); padding: 26px 20px; text-align: center; }
.cta-band h2 { color: var(--cream); font-size: 21px; margin: 0 0 6px; }
.cta-band p { color: rgba(247, 239, 228, .85); font-size: 14px; margin: 0 0 16px; }

/* ── 頁尾 ── */
footer { margin-top: 56px; background: var(--clay-deep); color: rgba(247, 239, 228, .85); font-size: 13.5px; }
footer .wrap { padding: 30px 16px 34px; }
footer .f-name { font-family: "Noto Serif TC", serif; font-size: 17px; color: var(--cream); letter-spacing: .12em; margin-bottom: 8px; }
footer a { color: var(--gold); text-decoration: none; }
footer .f-links { margin: 12px 0; display: flex; flex-wrap: wrap; gap: 6px 16px; }
footer .f-links a { color: rgba(247, 239, 228, .85); }
footer .f-copy { margin-top: 14px; font-size: 12px; opacity: .6; }

/* ══════════════════════════════════════════════════════════════════════
   官網 v3 首頁改版（僅 index.html 使用，全部新增 class，不影響其他 144 頁）
   ══════════════════════════════════════════════════════════════════════ */

/* ── 色塊分區：既有四色系（赤陶橘/金/墨棕/深青）淺 tint，區塊間留白拉開 ── */
.v3-zone { padding: 58px 0; }
.v3-zone-ink { background: rgba(58, 43, 34, .05); }
.v3-zone-gold { background: rgba(201, 150, 46, .09); }
.v3-zone-clay { background: rgba(181, 102, 63, .10); }
.v3-zone-teal { background: rgba(74, 122, 111, .08); }
.v3-zone-plain { background: var(--cream-2); }

.v3-quote {
  font-family: "Noto Serif TC", serif; font-size: 14.5px; letter-spacing: .1em;
  color: var(--gold); font-weight: 700; margin: 0 0 10px;
}

/* ── 認識濟德宮：直書短文版面（城崎溫泉 深山 Concept 區參考）──
   淡底色塊＋角落雲紋線稿裝飾；桌機直書（vertical-rl 由右至左），
   標題欄 auto 高度＝單一長欄；內文欄固定 height 讓 vertical-rl 自動換欄（多欄由右至左流動）；
   手機高度不足，改橫書置中，見下方 @media (max-width: 819.98px) */
.v3-about-verse {
  position: relative; overflow: hidden;
  background: var(--cream-2);
  background-image:
    radial-gradient(circle at 15% 20%, rgba(181, 102, 63, .05), transparent 60%),
    radial-gradient(circle at 85% 80%, rgba(201, 150, 46, .05), transparent 55%);
  padding: 68px 16px;
}
/* 水波紋裝飾（潮水返腳意象，使用者 Illustrator 描線 river.svg，顏色透明度已內建）：
   僅桌機顯示，見下方 @media (min-width:820px)；
   注意 river.svg 圖樣在 viewBox 內有留白（左約 16%、上約 34%），定位值已含此偏移 */
.v3-verse-river {
  display: none; position: absolute; pointer-events: none; z-index: 0;
  background: url("river.svg") no-repeat center / contain;
}
.v3-verse-in {
  display: flex; flex-direction: row-reverse; align-items: flex-start; justify-content: center;
  gap: clamp(36px, 6vw, 72px);
  min-height: 380px;
}
.v3-verse-title {
  writing-mode: vertical-rl; text-orientation: mixed;
  flex: 0 0 auto;
  font-family: "Noto Serif TC", serif; font-weight: 700; color: var(--ink);
  font-size: clamp(26px, 3.4vw, 38px); letter-spacing: .16em; line-height: 1.8;
  margin: 0;
}
/* 內文：每句一個直書欄（手動分欄），各欄齊頭向上對齊；
   欄距（column-gap）比照參考圖加寬 */
.v3-verse-body {
  display: flex; flex-direction: row-reverse; align-items: flex-start;
  gap: clamp(30px, 3.6vw, 52px);
  flex: 0 0 auto;
}
.v3-verse-body p {
  writing-mode: vertical-rl; text-orientation: mixed;
  flex: 0 0 auto; margin: 0; height: 380px;
  font-size: 15.5px; letter-spacing: .06em; line-height: 2;
  font-family: "Noto Serif TC", "Songti TC", serif; font-weight: 500;
  color: var(--ink-soft);
}
/* 桌機直書（比照城崎深山 Concept 區的散文鬆度）：
   行距＝直行間的水平間距（line-height 2→2.5）、
   字距＝直書時字與字的垂直間距（內文 .06em→.35em，大標略加 .16em→.2em）、
   內文字級 15.5px→16.5px；
   大標第二行退兩字（padding-top 2.4em＝2 字 × 1.2em 含 .2em 字距的字距節距），「媽」對齊首行「返」；
   基底值留給手機橫書，此處只覆蓋 ≥820px */
@media (min-width: 820px) {
  .v3-verse-body p { line-height: 2.5; letter-spacing: .35em; font-size: 16.5px; }
  /* 第一句不設高＝完整一直行不折行；其餘句維持 380px 現狀 */
  .v3-verse-body p:first-child { height: auto; }
  .v3-verse-title { letter-spacing: .2em; }
  .v3-verse-title-l2 { padding-top: 2.4em; }

  /* 水波紋裝飾三顆（river.svg）：大小微錯落（170/165/150），高度依 216.7:108.56 比例 */
  .v3-verse-river { display: block; }
  .v3-verse-river-a { top: 45px; right: 130px; width: 170px; height: 85px; }
  .v3-verse-river-b { left: 34px; top: 361px; width: 165px; height: 83px; }
  .v3-verse-river-c { left: 166px; top: 472px; width: 150px; height: 75px; }
}

/* 手機：標題維持橫排大字置中；內文改直書（每句一直行、右起左讀、頂端對齊、置中，迷你版桌機） */
@media (max-width: 819.98px) {
  .v3-about-verse { padding: 48px 22px; }
  .v3-verse-in {
    flex-direction: column; align-items: center; text-align: center;
    min-height: 0; gap: 24px;
  }
  /* 標題：橫書大字置中（不動） */
  .v3-verse-title {
    writing-mode: horizontal-tb; text-orientation: initial;
    height: auto; width: 100%;
    font-size: 24px; line-height: 1.6; letter-spacing: .08em; max-width: 320px;
  }
  /* 內文：直書分欄，句子高矮不一自然對齊頂端；overflow-x 保險（真的過寬可捲不破版） */
  .v3-verse-body {
    display: flex; flex-direction: row-reverse; flex-wrap: nowrap;
    justify-content: center; align-items: flex-start;
    gap: clamp(14px, 4vw, 22px);
    max-width: 100%; width: 100%; margin: 0 auto; text-align: initial;
    overflow-x: auto;
  }
  .v3-verse-body p {
    writing-mode: vertical-rl; text-orientation: mixed;
    height: auto; flex: 0 0 auto; margin: 0; padding-top: 0;
    font-size: 15px; letter-spacing: .08em; line-height: 2;
    font-family: "Noto Serif TC", "Songti TC", serif; font-weight: 500;
    color: var(--ink-soft);
  }
}

/* ── 白天燈籠照：滿版帶（full-bleed），置於直書短文之後、六尊圖示格之前 ── */
.v3-about-photo-full {
  display: block; width: 100vw; margin-left: calc(50% - 50vw); margin-right: calc(50% - 50vw);
  height: 52vh; min-height: 280px; max-height: 560px;
  object-fit: cover;
}

.v3-deity-mini-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-top: 18px; }
@media (min-width: 680px) { .v3-deity-mini-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 960px) { .v3-deity-mini-grid { grid-template-columns: repeat(6, 1fr); } }
.v3-deity-mini {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  text-decoration: none; padding: 16px 8px; border-radius: 12px;
  background: var(--cream-2); border: 1px solid rgba(226, 214, 198, .6);
  transition: transform .2s ease, box-shadow .2s ease;
}
.v3-deity-mini:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.v3-deity-mini .feature-icon { width: 42px; height: 42px; border-radius: 12px; margin: 0 auto 8px; }
.v3-deity-mini h3 { margin: 0 0 3px; font-size: 14px; color: var(--clay-deep); }
.v3-deity-mini .deity-duty { font-size: 11px; margin: 0; color: var(--gold); font-weight: 700; }

/* ── 數位服務放大卡（本站重點區，視覺份量高於信眾服務） ── */
.v3-card-feature { padding: 30px 24px; text-align: center; border-top: 4px solid transparent; }
.v3-card-feature .feature-icon { width: 68px; height: 68px; border-radius: 18px; margin: 0 auto 16px; }
.v3-card-feature h3 { font-size: 20px; }
.v3-card-feature p { font-size: 15px; }
.v3-card-feature .more { font-size: 15px; }
.v3-card-feature:nth-child(1) { border-top-color: var(--clay); }
.v3-card-feature:nth-child(2) { border-top-color: var(--gold); }
.v3-card-feature:nth-child(3) { border-top-color: #4a7a6f; }

/* ── 信眾服務圖示化：只留 SVG 圖示＋主題名稱 ── */
.v3-svc-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-top: 4px; }
@media (min-width: 680px) { .v3-svc-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 960px) { .v3-svc-grid { grid-template-columns: repeat(6, 1fr); } }
.v3-svc-item {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  text-decoration: none; padding: 22px 10px;
}
.v3-svc-item .feature-icon { margin: 0 auto 10px; }
.v3-svc-item h3 { margin: 0; font-size: 15px; color: var(--ink); }
.v3-svc-item:hover h3 { color: var(--clay-d); }

/* ── 色彩加強波（v3 Phase 2 修訂）：數位服務深青底、CTA 深青深底、慶典四卡、信眾服務六圖示四色輪替 ── */

/* 1. 數位服務區：深青系底色（比既有淺 tint 更明顯），卡片維持白底，kicker/標題/連結強調色改深青 */
.v3-zone-teal-strong {
  background: rgba(74, 122, 111, .22);
  border-top: 1px solid rgba(74, 122, 111, .3);
  border-bottom: 1px solid rgba(74, 122, 111, .3);
}
.v3-zone-teal-strong .kicker { color: #2f5850; }
.v3-zone-teal-strong .section-head h2 { color: #23433c; }
.v3-zone-teal-strong .v3-card-feature .more { color: #2f5850; }

/* 2. AI 廟公結尾 CTA 帶：深青深底＋米白字（沿用 .cta-band 既有文字色），按鈕改深青字搭配 */
.cta-band.v3-cta-teal { background: #2f4f47; }
.cta-band.v3-cta-teal .btn-solid { color: #2f4f47; }

/* 3. 年度慶典四卡：套用消息標籤四色系統（裝飾輪替，非分類），頂部色帶＋標題同色 */
.v3-fest-card { border-top: 4px solid transparent; }
.v3-fest-card:nth-child(1) { border-top-color: var(--clay); }
.v3-fest-card:nth-child(1) h3 { color: var(--clay-d); }
.v3-fest-card:nth-child(2) { border-top-color: var(--gold); }
.v3-fest-card:nth-child(2) h3 { color: #8a6413; }
.v3-fest-card:nth-child(3) { border-top-color: var(--ink-soft); }
.v3-fest-card:nth-child(3) h3 { color: var(--ink-soft); }
.v3-fest-card:nth-child(4) { border-top-color: #4a7a6f; }
.v3-fest-card:nth-child(4) h3 { color: #3d6559; }

/* 4. 信眾服務六圖示：圖示圓底四色淺 tint 輪替（橘→金→墨棕→深青→橘→金），金底圖示線條改深色維持對比 */
.v3-svc-grid .v3-svc-item:nth-child(1) .feature-icon { background: var(--clay); }
.v3-svc-grid .v3-svc-item:nth-child(2) .feature-icon { background: var(--gold); }
.v3-svc-grid .v3-svc-item:nth-child(3) .feature-icon { background: var(--ink-soft); }
.v3-svc-grid .v3-svc-item:nth-child(4) .feature-icon { background: #4a7a6f; }
.v3-svc-grid .v3-svc-item:nth-child(5) .feature-icon { background: var(--clay); }
.v3-svc-grid .v3-svc-item:nth-child(6) .feature-icon { background: var(--gold); }
.v3-svc-grid .v3-svc-item:nth-child(2) svg,
.v3-svc-grid .v3-svc-item:nth-child(6) svg { stroke: #3a2b22; }
.v3-svc-grid .v3-svc-item:nth-child(6) svg circle { fill: #3a2b22; }

/* ── 滾動顯示動效（故宮式）：進場 fade + 輕移，一次觸發；尊重 prefers-reduced-motion ── */
.v3-reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
.v3-reveal.v3-in { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .v3-reveal { opacity: 1; transform: none; transition: none; }
}

/* ══════════════════════════════════════════════════════════════════════
   建廟推廣滿版照片區（.fund-band）：index.html 首頁區塊 + fund.html 頁首共用，
   全部新增 class，武德宮風格滿版照片壓深色漸層、文字疊圖上
   ══════════════════════════════════════════════════════════════════════ */
.fund-band {
  position: relative;
  min-height: 620px;
  display: flex;
  align-items: center;
  background: url("home/carousel_newtemple_aerial.jpg") center 30% / cover no-repeat;
  overflow: hidden;
}
.fund-band::before {
  content: "";
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(30, 20, 14, .92) 0%, rgba(30, 20, 14, .82) 34%, rgba(43, 28, 18, .45) 62%, rgba(43, 28, 18, .18) 100%),
    linear-gradient(0deg, rgba(30, 20, 14, .55) 0%, rgba(30, 20, 14, 0) 35%);
}
.fund-band .inner {
  position: relative;
  width: min(1120px, 92%);
  margin: 0 auto;
  padding: 72px 0;
  color: var(--cream);
}
.fund-band h1, .fund-band h2 {
  color: var(--cream); font-size: clamp(28px, 4vw, 42px); line-height: 1.35;
  margin: 0 0 10px; font-weight: 800; letter-spacing: .04em;
}
.fund-band .hero-tag {
  color: var(--gold); letter-spacing: 6px; font-size: clamp(16px, 2vw, 20px);
  font-weight: 700; margin-bottom: 14px; text-shadow: 0 2px 10px rgba(0, 0, 0, .45);
}
.fund-band h1 { text-shadow: 0 2px 10px rgba(0, 0, 0, .45); }
.fund-band .motto { color: var(--gold); font-size: clamp(16px, 2vw, 20px); letter-spacing: 6px; margin-bottom: 26px; }
.fund-band p.lead { max-width: 34em; font-size: 16px; line-height: 2.05; margin: 0 0 30px; color: rgba(247, 239, 228, .92); }
.fund-band .fund-links { display: flex; flex-direction: column; gap: 12px; margin-bottom: 34px; }
.fund-band .fund-links a {
  color: var(--gold); text-decoration: underline; text-underline-offset: 6px;
  font-size: 17px; font-weight: 700; width: fit-content;
}
.fund-band .fund-cta { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.fund-band .fund-cta .btn-gold {
  display: inline-block; background: var(--gold); color: #2a1c10;
  padding: 14px 30px; border-radius: 999px; font-weight: 800; font-size: 16px; text-decoration: none;
}
.fund-band .fund-cta .btn-ghost {
  display: inline-block; border: 1.5px solid rgba(247, 239, 228, .75); color: var(--cream); background: transparent;
  padding: 13px 28px; border-radius: 999px; font-weight: 700; font-size: 15px; text-decoration: none;
}
.fund-band .hero-cta { justify-content: flex-start; }
.fund-band .fund-progress { max-width: 460px; margin-top: 34px; }
.fund-band .fund-progress .nums { display: flex; justify-content: space-between; font-size: 13px; color: rgba(247, 239, 228, .85); margin-bottom: 8px; }
.fund-band .fund-progress .bar { height: 8px; border-radius: 999px; background: rgba(247, 239, 228, .25); overflow: hidden; }
.fund-band .fund-progress .bar i { display: block; height: 100%; width: 54%; background: var(--gold); border-radius: 999px; }
.fund-band .fund-progress .note { color: rgba(247, 239, 228, .65); margin-top: 8px; }

@media (max-width: 819.98px) {
  /* 手機改「圖完整置頂 + 文字區實色深底」：圖高 = 100vw × 844/1500 ≈ 56.27vw */
  .fund-band {
    min-height: 0;
    background-size: 100% auto;
    background-position: top center;
    background-color: #241811;
  }
  .fund-band::before {
    background: linear-gradient(180deg,
      rgba(36, 24, 17, .10) 0%,
      rgba(36, 24, 17, .10) 42vw,
      rgba(36, 24, 17, .92) 56.27vw,
      #241811 58vw);
  }
  .fund-band .inner { padding: calc(56.27vw + 8px) 0 48px; }
  .fund-band p.lead { font-size: 15px; }
}

/* ── 慶典行事曆（calendar.html） ── */
.cal-card { padding: 18px 16px 22px; }
.cal-nav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.cal-nav .cal-label { font-family: "Noto Serif TC", "PingFang TC", serif; font-weight: 700; font-size: 17px; color: var(--clay-deep); }
.cal-btn {
  background: var(--clay); color: #fff; border: none; width: 36px; height: 36px;
  border-radius: 10px; font-size: 19px; line-height: 1; cursor: pointer;
}
.cal-btn:active { background: var(--clay-d); }
.cal-weekdays {
  display: grid; grid-template-columns: repeat(7, 1fr); text-align: center;
  font-size: 12.5px; color: var(--ink-faint); font-weight: 700; margin-bottom: 4px;
}
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-cell {
  position: relative; aspect-ratio: 1 / 1; display: flex; flex-direction: column;
  align-items: center; justify-content: center; border-radius: 10px; font-size: 13.5px;
  color: var(--ink); background: var(--cream);
}
.cal-cell.cal-empty { background: transparent; }
.cal-daynum { line-height: 1; }
.cal-cell.cal-today { background: rgba(201, 150, 46, .16); box-shadow: inset 0 0 0 1.5px var(--gold); font-weight: 700; }
.cal-cell.cal-has-event { background: rgba(181, 102, 63, .10); font-weight: 700; }
.cal-cell.cal-clickable { cursor: pointer; }
.cal-dots { display: flex; gap: 3px; margin-top: 2px; }
.cal-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; }
.cal-dot-festival { background: var(--clay); }
.cal-dot-fahui { background: var(--gold); }
.cal-dot-today { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--gold); }
.cal-legend { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-top: 14px; font-size: 12.5px; color: var(--ink-soft); }
.cal-legend span { display: flex; align-items: center; gap: 5px; }

.cal-month-group { margin-bottom: 22px; }
.cal-month-group h3 { font-size: 16px; margin: 0 0 10px; color: var(--clay-deep); }
.cal-event-row {
  background: var(--cream-2); border: 1px solid rgba(226, 214, 198, .6); border-radius: 12px;
  padding: 14px 16px; margin-bottom: 10px; box-shadow: var(--shadow);
}
.cal-event-row .cer-top { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; margin-bottom: 4px; }
.cal-event-row .cer-name {
  font-family: "Noto Serif TC", "PingFang TC", serif; font-weight: 700; font-size: 15.5px;
  color: var(--ink); width: 100%;
}
.cal-event-row .cer-date { font-weight: 700; color: var(--clay-d); font-size: 14.5px; }
.cal-event-row .cer-lunar { font-size: 12.5px; color: var(--ink-faint); }
.cal-event-row p { margin: 4px 0 8px; font-size: 14px; color: var(--ink-soft); }
.btn-ics {
  display: inline-flex; align-items: center; gap: 5px; background: transparent;
  border: 1.5px solid var(--clay); color: var(--clay-d); font-size: 12.5px; font-weight: 700;
  padding: 6px 12px; border-radius: 999px; cursor: pointer;
}
.btn-ics:active { background: rgba(181, 102, 63, .12); }

/* ── fund.html #origin 緣起圖文並排（僅此頁用，scoped class） ── */
.origin-figure { margin: 0 0 14px; }
.origin-figure img { width: 100%; display: block; }
@media (min-width: 820px) {
  .origin-figure { float: left; width: 50%; padding-right: 26px; margin: 0 0 12px; }
  /* 抵銷 .content-img 全站共用的 margin-top（16px），讓圖頂對齊右側首段文字頂 */
  .origin-figure .content-img { margin-top: 0; }
  /* 三個金標若落在 float 環繞窄欄中，置中效果會與其餘兩個不一致，強制整排置中 */
  .origin-figure ~ h3 { clear: left; }
}
.section-head .more { font-weight: 700; text-decoration: none; }
