/* ============================================================
   天成外匯中心 / TIN SHING FOREIGN CENTRE
   樣式表 — 單一檔案，無外部依賴（不需網絡即可顯示）
   修改品牌色：改下面的 :root 變數即可
   ============================================================ */

:root {
  --ink: #0b1b2b;
  --ink-soft: #3a4d61;
  --ink-mute: #6b7d8f;
  --paper: #fbfaf7;
  --paper-2: #f3f0e9;
  --navy: #0e2438;
  --navy-2: #14314a;
  --gold: #a8791f;
  --gold-lit: #c9a227;
  --gold-soft: #f1e7d2;
  --line: #e3ded4;
  --line-dark: rgba(255, 255, 255, 0.14);
  --ok: #2f7d5b;

  --max: 1180px;
  --serif: "Songti TC", "Noto Serif TC", "Source Han Serif TC", Georgia, "Times New Roman", serif;
  --sans: "PingFang HK", "PingFang TC", -apple-system, BlinkMacSystemFont, "Segoe UI",
    "Noto Sans TC", "Microsoft JhengHei", sans-serif;
  --mono: "SF Mono", ui-monospace, "Menlo", "Consolas", monospace;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(11, 27, 43, 0.04), 0 12px 32px -18px rgba(11, 27, 43, 0.28);
}

* { box-sizing: border-box; }

/* hidden 屬性一律優先，避免被 display 規則覆蓋 */
[hidden] { display: none !important; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  overflow-x: clip;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.72;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.28;
  letter-spacing: -0.01em;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

a { color: inherit; text-decoration: none; }
img, svg { max-width: 100%; }

::selection { background: var(--gold-soft); }

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- 版面容器 ---------- */
.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 24px;
}

.section { padding: 92px 0; }
.section--tight { padding: 64px 0; }
.section--paper2 { background: var(--paper-2); }
.section--line { border-top: 1px solid var(--line); }

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: #fff;
  padding: 12px 18px;
  z-index: 100;
}
.skip:focus { left: 12px; top: 12px; }

/* ---------- 小標題 / 標題 ---------- */
.eyebrow {
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: "";
  width: 26px;
  height: 1px;
  background: var(--gold);
  display: inline-block;
}
.section-head { max-width: 720px; margin-bottom: 48px; }
.section-head h2 { font-size: clamp(26px, 3.4vw, 38px); }
.section-head .lede { margin-top: 16px; color: var(--ink-soft); font-size: 17px; }

/* ---------- 按鈕 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 13px 24px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 600;
  border: 1px solid transparent;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
  white-space: nowrap;
}
.btn svg { width: 15px; height: 15px; }
.btn--gold { background: var(--gold); color: #fff; }
.btn--gold:hover { background: #93691a; transform: translateY(-1px); }
.btn--ghost { border-color: var(--line); color: var(--ink); background: #fff; }
.btn--ghost:hover { border-color: var(--ink); }
.btn--onDark { border-color: var(--line-dark); color: #fff; }
.btn--onDark:hover { border-color: rgba(255, 255, 255, 0.5); background: rgba(255, 255, 255, 0.06); }
.btn--block { width: 100%; }

/* ---------- 頁首 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(251, 250, 247, 0.88);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 74px;
}
.brand { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.brand__mark {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  background: var(--navy);
  color: var(--gold-lit);
  display: grid;
  place-items: center;
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.02em;
  flex-shrink: 0;
}
.brand__text { display: flex; flex-direction: column; line-height: 1.2; }
.brand__zh { font-family: var(--serif); font-size: 17px; font-weight: 600; letter-spacing: 0.04em; }
.brand__en {
  font-size: 9.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin-top: 3px;
}

.nav { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.nav a {
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 14.5px;
  color: var(--ink-soft);
  transition: color 0.15s ease, background 0.15s ease;
}
.nav a:hover { color: var(--ink); background: var(--paper-2); }
.nav a[aria-current="page"] { color: var(--ink); font-weight: 600; position: relative; }
.nav a[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 1px;
  height: 2px;
  background: var(--gold);
  border-radius: 2px;
}

.header-tools { display: flex; align-items: center; gap: 10px; margin-left: 6px; }
.lang-btn {
  font-family: var(--sans);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink-soft);
  cursor: pointer;
  min-width: 46px;
}
.lang-btn:hover { border-color: var(--ink-mute); color: var(--ink); }
.header-tel { display: inline-flex; align-items: center; gap: 7px; font-size: 14.5px; font-weight: 600; }
.header-tel svg { width: 15px; height: 15px; color: var(--gold); }

.nav-toggle {
  display: none;
  margin-left: auto;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 10px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
}
.nav-toggle span {
  display: block;
  width: 17px;
  height: 1.5px;
  background: var(--ink);
  position: relative;
}
.nav-toggle span::before,
.nav-toggle span::after {
  content: "";
  position: absolute;
  left: 0;
  width: 17px;
  height: 1.5px;
  background: var(--ink);
}
.nav-toggle span::before { top: -5.5px; }
.nav-toggle span::after { top: 5.5px; }

/* ---------- 首屏 ---------- */
.hero {
  position: relative;
  background: var(--navy);
  color: #fff;
  overflow: hidden;
  padding: 88px 0 96px;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(120% 90% at 18% 10%, #000 12%, transparent 68%);
  -webkit-mask-image: radial-gradient(120% 90% at 18% 10%, #000 12%, transparent 68%);
  pointer-events: none;
}
.hero::after {
  content: "";
  position: absolute;
  width: 620px;
  height: 620px;
  right: -180px;
  top: -260px;
  background: radial-gradient(circle, rgba(201, 162, 39, 0.22), transparent 62%);
  pointer-events: none;
}
.hero .wrap { position: relative; z-index: 1; }
.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 56px;
  align-items: center;
}
.hero .eyebrow { color: var(--gold-lit); }
.hero .eyebrow::before { background: var(--gold-lit); }
.hero h1 {
  font-size: clamp(32px, 5vw, 54px);
  letter-spacing: -0.015em;
  margin-bottom: 22px;
}
.hero h1 em {
  font-style: normal;
  color: var(--gold-lit);
  position: relative;
  white-space: nowrap;
}
.hero .lede {
  color: rgba(255, 255, 255, 0.78);
  font-size: 17px;
  max-width: 46ch;
  margin-bottom: 32px;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* 首屏右側資訊卡 */
.panel {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius);
  padding: 26px 26px 22px;
  backdrop-filter: blur(6px);
}
.panel__row {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 13px 0;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.16);
  font-size: 14.5px;
}
.panel__row:first-of-type { padding-top: 0; }
.panel__row:last-of-type { border-bottom: 0; padding-bottom: 0; }
.panel dt { color: rgba(255, 255, 255, 0.55); flex-shrink: 0; letter-spacing: 0.04em; }
.panel dd { margin: 0; text-align: right; color: #fff; }
.panel dt, .panel dd { margin: 0; }
.panel dl { margin: 0; }
.status-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #56c08d;
  margin-right: 7px;
  vertical-align: middle;
  box-shadow: 0 0 0 4px rgba(86, 192, 141, 0.16);
}

/* ---------- 牌價 ---------- */
.rates-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.rates-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 22px 26px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, #fff, #fdfcf9);
}
.rates-head h3 { font-size: 19px; }
.rates-meta {
  font-size: 12.5px;
  color: var(--ink-mute);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}
table.rates {
  width: 100%;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
}
table.rates th,
table.rates td {
  padding: 15px 26px;
  text-align: right;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
}
table.rates th {
  font-size: 11.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-mute);
  font-weight: 600;
  text-align: right;
  background: #fdfcf9;
}
table.rates th:first-child,
table.rates td:first-child { text-align: left; }
table.rates tbody tr:last-child td { border-bottom: 0; }
table.rates tbody tr:hover { background: #fbf8f1; }
.cur { display: flex; align-items: center; gap: 12px; }
.cur__code {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--ink);
  background: var(--paper-2);
  border-radius: 5px;
  padding: 3px 7px;
  min-width: 46px;
  text-align: center;
}
.cur__name { font-size: 14.5px; color: var(--ink-soft); }
.rate-num { font-weight: 600; letter-spacing: 0.01em; }
.rate-num--sell { color: var(--gold); }
.rates-note {
  padding: 16px 26px 20px;
  font-size: 12.5px;
  color: var(--ink-mute);
  line-height: 1.7;
  border-top: 1px dashed var(--line);
  background: #fdfcf9;
}

/* ---------- 服務卡 ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 28px 28px;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover {
  border-color: #cfc6b4;
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}
.card__no {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--gold);
  margin-bottom: 18px;
}
.card h3 { font-size: 21px; margin-bottom: 12px; }
.card p { color: var(--ink-soft); font-size: 15px; }
.card ul {
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
  font-size: 14px;
  color: var(--ink-mute);
}
.card li { padding: 7px 0 7px 18px; position: relative; border-top: 1px solid var(--line); }
.card li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 16px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--gold-lit);
}

/* ---------- 條列特點 ---------- */
.features {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
}
.feature h3 { font-size: 17px; margin-bottom: 8px; }
.feature p { font-size: 14.5px; color: var(--ink-soft); }
.feature__icon {
  width: 40px;
  height: 40px;
  border-radius: 9px;
  background: var(--gold-soft);
  color: var(--gold);
  display: grid;
  place-items: center;
  margin-bottom: 16px;
}
.feature__icon svg { width: 19px; height: 19px; }

/* ---------- 門店 ---------- */
.store {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}
.store-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px;
  box-shadow: var(--shadow);
}
.store-card dl { margin: 0; }
.store-card .panel__row { border-bottom: 1px solid var(--line); color: var(--ink); }
.store-card .panel__row:last-of-type { border-bottom: 0; }
.store-card dt { color: var(--ink-mute); }
.store-card dd { color: var(--ink); }
.hours { font-variant-numeric: tabular-nums; }
.map-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--gold);
  font-weight: 600;
  font-size: 14px;
  border-bottom: 1px solid rgba(168, 121, 31, 0.35);
  padding-bottom: 1px;
}
.map-link:hover { border-color: var(--gold); }

/* ---------- 合規帶 ---------- */
.band {
  background: var(--navy);
  color: #fff;
  padding: 56px 0;
}
.band-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 36px;
}
.band h3 {
  font-size: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
  color: #fff;
}
.band h3 svg { width: 17px; height: 17px; color: var(--gold-lit); flex-shrink: 0; }
.band p { color: rgba(255, 255, 255, 0.66); font-size: 14px; }

/* ---------- 內頁 ---------- */
.page-head {
  background: var(--navy);
  color: #fff;
  padding: 68px 0 64px;
  position: relative;
  overflow: hidden;
}
.page-head::after {
  content: "";
  position: absolute;
  width: 520px;
  height: 520px;
  right: -160px;
  top: -300px;
  background: radial-gradient(circle, rgba(201, 162, 39, 0.2), transparent 62%);
}
.page-head .wrap { position: relative; z-index: 1; }
.crumbs { font-size: 13px; color: rgba(255, 255, 255, 0.5); margin-bottom: 18px; letter-spacing: 0.04em; }
.crumbs a { color: rgba(255, 255, 255, 0.7); }
.crumbs a:hover { color: #fff; }
.page-head h1 { font-size: clamp(30px, 4.4vw, 44px); margin-bottom: 14px; }
.page-head p { color: rgba(255, 255, 255, 0.72); max-width: 62ch; font-size: 16.5px; }

.prose { max-width: 760px; }
.prose h2 { font-size: 25px; margin: 40px 0 14px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 18px; margin: 28px 0 10px; }
.prose p, .prose li { color: var(--ink-soft); font-size: 16px; }
.prose ul, .prose ol { padding-left: 22px; margin: 0 0 18px; }
.prose li { margin-bottom: 8px; }
.prose a:not(.btn) { color: var(--gold); border-bottom: 1px solid rgba(168, 121, 31, 0.35); }
.prose a:not(.btn):hover { border-color: var(--gold); }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 36px 0; }

.two-col {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 56px;
  align-items: start;
}
.aside-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
  position: sticky;
  top: 98px;
}
.aside-card h3 { font-size: 16px; margin-bottom: 14px; }
.aside-card p { font-size: 14px; color: var(--ink-soft); }

.info-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14.5px;
}
.info-table th,
.info-table td {
  text-align: left;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.info-table th { color: var(--ink-mute); font-weight: 500; width: 38%; }
.info-table td { color: var(--ink); }
.info-table tr:last-child th,
.info-table tr:last-child td { border-bottom: 0; }

/* FAQ */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  cursor: pointer;
  padding: 20px 40px 20px 0;
  font-size: 16.5px;
  font-weight: 600;
  list-style: none;
  position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 6px;
  top: 16px;
  font-size: 22px;
  color: var(--gold);
  font-weight: 400;
  transition: transform 0.2s ease;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 0 20px; color: var(--ink-soft); font-size: 15px; max-width: 70ch; }

/* ---------- CTA ---------- */
.cta {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-2) 100%);
  color: #fff;
  border-radius: var(--radius);
  padding: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}
.cta h2 { font-size: clamp(23px, 3vw, 30px); margin-bottom: 10px; }
.cta p { color: rgba(255, 255, 255, 0.7); font-size: 15.5px; max-width: 52ch; }

/* ---------- 頁尾 ---------- */
.site-footer {
  background: #08161f;
  color: rgba(255, 255, 255, 0.72);
  padding: 64px 0 0;
  font-size: 14px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1.6fr;
  gap: 44px;
  padding-bottom: 44px;
}
.footer-brand .brand__mark { background: rgba(255, 255, 255, 0.08); }
.footer-brand .brand__zh { color: #fff; }
.footer-brand .brand__en { color: rgba(255, 255, 255, 0.45); }
.footer-mission { margin-top: 18px; max-width: 34ch; color: rgba(255, 255, 255, 0.55); font-size: 13.5px; }
.site-footer h4 {
  font-family: var(--sans);
  font-size: 11.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.4);
  margin: 0 0 16px;
  font-weight: 600;
}
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 9px; }
.site-footer a:hover { color: #fff; }
.footer-legal { font-size: 13px; color: rgba(255, 255, 255, 0.55); line-height: 1.85; }
.footer-legal strong { color: rgba(255, 255, 255, 0.85); font-weight: 600; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 20px 0 26px;
  display: flex;
  flex-wrap: wrap;
  gap: 14px 26px;
  align-items: center;
  justify-content: space-between;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.42);
  letter-spacing: 0.02em;
}
.footer-bottom a:hover { color: rgba(255, 255, 255, 0.8); }

/* ---------- 語言切換：預設顯示中文 ---------- */
html[data-lang="en"] .t-zh { display: none !important; }
html:not([data-lang="en"]) .t-en { display: none !important; }

/* ---------- 進場動畫 ---------- */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 0.6s ease, transform 0.6s ease;
  }
  .reveal.is-in { opacity: 1; transform: none; }
}

/* ---------- 響應式 ---------- */
@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .panel { max-width: 460px; }
  .features { grid-template-columns: repeat(2, 1fr); }
  .cards { grid-template-columns: 1fr; }
  .two-col { grid-template-columns: 1fr; gap: 36px; }
  .aside-card { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-legal { grid-column: 1 / -1; }
}

@media (max-width: 1000px) {
  .nav {
    position: fixed;
    inset: 74px 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    padding: 12px 20px 20px;
    margin-left: 0;
    display: none;
    box-shadow: 0 20px 30px -24px rgba(0, 0, 0, 0.4);
  }
  .nav[data-open="true"] { display: flex; }
  .nav a { padding: 13px 12px; font-size: 16px; border-radius: 8px; }
  .nav a[aria-current="page"]::after { display: none; }
  .nav a[aria-current="page"] { background: var(--paper-2); }
  .nav-toggle { display: inline-flex; }
  .header-tel { display: none; }
  .header-inner { gap: 12px; }
  .header-tools { margin-left: 0; margin-right: 10px; }
  .nav-toggle { margin-left: 0; }

  .section { padding: 64px 0; }
  .hero { padding: 60px 0 72px; }
  .store { grid-template-columns: 1fr; gap: 24px; }
  .band-grid { grid-template-columns: 1fr; gap: 26px; }
  .cta { padding: 34px 26px; }
  .features { grid-template-columns: 1fr; gap: 22px; }
  .footer-grid { grid-template-columns: 1fr; gap: 34px; }
  table.rates th, table.rates td { padding: 13px 16px; }
  .rates-head, .rates-note { padding-left: 16px; padding-right: 16px; }
}

@media (max-width: 480px) {
  .wrap { padding: 0 18px; }
  .hero h1 { font-size: 30px; }
  .btn { width: 100%; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .cur { gap: 8px; }
  .cur__name { display: none; }
  table.rates th, table.rates td { padding: 12px 12px; font-size: 14px; }
  .brand__en { font-size: 8.5px; letter-spacing: 0.12em; }
}

/* ============================================================
   即時牌價（rates.js）
   ============================================================ */
.rates-title h3 { font-size: 19px; }
.rates-sub {
  margin: 5px 0 0;
  font-size: 12.5px;
  letter-spacing: 0.04em;
  color: var(--ink-mute);
}
.rates-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 7px;
}
.live-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 11px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-mute);
}
.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #b9b2a4;
  flex-shrink: 0;
}
.live-badge[data-live="true"] {
  color: #1f6b4a;
  border-color: rgba(47, 125, 91, 0.32);
  background: rgba(47, 125, 91, 0.07);
}
.live-badge[data-live="true"] .live-dot {
  background: #2f7d5b;
  box-shadow: 0 0 0 3px rgba(47, 125, 91, 0.14);
}
@media (prefers-reduced-motion: no-preference) {
  .live-badge[data-live="true"] .live-dot { animation: livePulse 2.6s ease-in-out infinite; }
  @keyframes livePulse {
    0%, 100% { box-shadow: 0 0 0 3px rgba(47, 125, 91, 0.14); }
    50% { box-shadow: 0 0 0 5px rgba(47, 125, 91, 0.04); }
  }
}
.rates-stamp {
  font-size: 12.5px;
  color: var(--ink-mute);
  font-variant-numeric: tabular-nums;
}
.rates-foot {
  padding: 0 26px;
  border-top: 1px solid var(--line);
  background: #fdfcf9;
}
.rates-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 15px 0;
  background: none;
  border: 0;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 600;
  color: var(--gold);
  cursor: pointer;
}
.rates-toggle:hover { color: #8b6418; }
.rates-chev {
  width: 14px;
  height: 14px;
  transition: transform 0.2s ease;
}
.rates-toggle[aria-expanded="true"] .rates-chev { transform: rotate(180deg); }
.rates tbody[hidden] { display: none; }
/* 錨點跳轉時避開固定的頁首 */
[id] { scroll-margin-top: 92px; }

@media (max-width: 640px) {
  .rates-meta { align-items: flex-start; flex-direction: row; flex-wrap: wrap; gap: 8px 12px; }
  .rates-head { align-items: flex-start; }
  .rates-foot { padding: 0 16px; }
}

/* ============================================================
   下載 App（download.html + 首頁 App 區塊）
   ============================================================ */
.app-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 64px;
  align-items: center;
}
.app-points {
  list-style: none;
  margin: 26px 0 0;
  padding: 0;
  font-size: 15px;
  color: var(--ink-soft);
}
.app-points li {
  position: relative;
  padding: 8px 0 8px 26px;
  border-top: 1px solid var(--line);
}
.app-points li:first-child { border-top: 0; }
.app-points li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 17px;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--gold-soft);
  border: 1px solid rgba(168, 121, 31, 0.45);
}

.qr-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 24px 22px;
  text-align: center;
  box-shadow: var(--shadow);
}
.qr-card img {
  width: 100%;
  max-width: 220px;
  height: auto;
  display: block;
  margin: 0 auto 18px;
  border-radius: 4px;
}
.qr-card__title {
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 6px;
}
.qr-card__hint {
  font-size: 12.5px;
  color: var(--ink-mute);
  margin: 0;
  line-height: 1.6;
}

/* 下載頁 */
.dl-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 56px;
  align-items: start;
}
.dl-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px;
  box-shadow: var(--shadow);
  margin-bottom: 18px;
}
.dl-card h2 {
  font-size: 23px;
  margin: 14px 0 10px;
}
.dl-card p { color: var(--ink-soft); font-size: 15px; }
.os-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--paper-2);
  color: var(--ink-soft);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.dl-actions { margin: 20px 0 14px; }
.dl-actions .btn { width: auto; }
.dl-note {
  font-size: 13px !important;
  color: var(--ink-mute) !important;
  background: var(--paper-2);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  line-height: 1.7;
}
.dl-fallback {
  font-size: 13.5px !important;
  color: #8a4b1e !important;
  background: #fdf3e6;
  border: 1px solid #f3dfc4;
  border-radius: var(--radius-sm);
  padding: 12px 14px;
}
.dl-wechat {
  display: none;
  background: #fdf6e8;
  border-color: #f0e0c2;
  padding: 18px 22px;
  gap: 14px;
  align-items: flex-start;
  font-size: 14px;
  color: #7a5a1e;
}
.dl-wechat svg { width: 18px; height: 18px; flex-shrink: 0; margin-top: 3px; }
.dl-wechat b { color: #5d4413; }
.dl-hint {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 18px 22px;
  margin-bottom: 18px;
  font-size: 14px;
  color: var(--ink-soft);
}
.dl-hint svg { width: 18px; height: 18px; flex-shrink: 0; margin-top: 3px; color: var(--gold); }
.dl-meta {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.dl-meta h3 {
  font-family: var(--sans);
  font-size: 11.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin: 0 0 12px;
  font-weight: 600;
}
.dl-meta table { width: 100%; border-collapse: collapse; font-size: 14px; }
.dl-meta th, .dl-meta td {
  text-align: left;
  padding: 9px 0;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.dl-meta th { color: var(--ink-mute); font-weight: 500; width: 42%; }
.dl-meta tr:last-child th, .dl-meta tr:last-child td { border-bottom: 0; }

.steps { padding-left: 0; list-style: none; counter-reset: step; }
.steps li {
  counter-increment: step;
  position: relative;
  padding: 14px 0 14px 44px;
  border-bottom: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 15px;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 12px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--paper-2);
  color: var(--gold);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  display: grid;
  place-items: center;
}
.steps li:last-child { border-bottom: 0; }

/* 依系統顯示對應區塊（無 JS 時全部顯示，不會空白） */
html[data-os="android"] [data-only-ios] { display: none !important; }
html[data-os="ios"] [data-only-android] { display: none !important; }
html[data-os="desktop"] [data-only-phone] { display: none !important; }

/* 主視覺的行動按鈕：每個系統只出現自己的一組 */
html[data-os="android"] [data-cta-ios],
html[data-os="android"] [data-cta-desktop] { display: none !important; }
html[data-os="ios"] [data-cta-android],
html[data-os="ios"] [data-cta-desktop] { display: none !important; }
html[data-os="desktop"] [data-cta-android],
html[data-os="desktop"] [data-cta-ios] { display: none !important; }
html[data-wechat="true"] [data-wechat-note] { display: flex; }
/* 手機在自己螢幕上掃自己的二維碼沒有意義，直接隱藏 */
html[data-os="android"] .dl-aside .qr-card,
html[data-os="ios"] .dl-aside .qr-card { display: none; }
html[data-os="android"] [data-only-desktop],
html[data-os="ios"] [data-only-desktop] { display: none !important; }

@media (max-width: 1024px) {
  .app-grid { grid-template-columns: 1fr; gap: 36px; }
  .qr-card { max-width: 320px; }
  .dl-grid { grid-template-columns: 1fr; gap: 32px; }
  .dl-grid .dl-aside { order: 2; }
}
@media (max-width: 480px) {
  .dl-actions .btn { width: 100%; }
}

/* ============================================================
   下載頁 v2（深色主視覺版）
   ============================================================ */
.dl-hero {
  position: relative;
  background: var(--navy);
  color: #fff;
  padding: 72px 0 80px;
  overflow: hidden;
}
.dl-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(110% 80% at 15% 5%, #000 10%, transparent 70%);
  -webkit-mask-image: radial-gradient(110% 80% at 15% 5%, #000 10%, transparent 70%);
  pointer-events: none;
}
.dl-hero::after {
  content: "";
  position: absolute;
  width: 560px;
  height: 560px;
  right: -170px;
  top: -240px;
  background: radial-gradient(circle, rgba(201, 162, 39, 0.2), transparent 62%);
  pointer-events: none;
}
.dl-hero .wrap { position: relative; z-index: 1; }
.dl-hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 268px;
  gap: 64px;
  align-items: center;
}

/* App 識別 */
.app-id { display: flex; align-items: center; gap: 16px; }
.app-icon {
  width: 74px;
  height: 74px;
  border-radius: 19px;
  background: linear-gradient(150deg, #1c3a55 0%, #0a1725 100%);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 14px 30px -14px rgba(0, 0, 0, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  display: grid;
  place-items: center;
  font-family: var(--serif);
  font-size: 24px;
  font-weight: 700;
  color: var(--gold-lit);
  letter-spacing: 0.02em;
  flex-shrink: 0;
}
.app-name {
  margin: 0;
  font-family: var(--serif);
  font-size: 19px;
  letter-spacing: 0.04em;
}
.app-sub {
  margin: 4px 0 0;
  font-size: 9.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}
.dl-hero h1 {
  font-size: clamp(29px, 4.4vw, 44px);
  margin: 28px 0 14px;
  letter-spacing: -0.01em;
}
.dl-hero__lede {
  color: rgba(255, 255, 255, 0.72);
  font-size: 16.5px;
  max-width: 50ch;
  margin: 0 0 24px;
}
.app-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.04);
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.82);
}
.dl-hero__cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
}
.btn--lg { padding: 16px 30px; font-size: 16px; }
.dl-hero__hint {
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.45);
  max-width: 22ch;
  line-height: 1.5;
}
.dl-hero__note {
  display: none;
  margin: 22px 0 0;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  background: rgba(201, 162, 39, 0.12);
  border: 1px solid rgba(201, 162, 39, 0.3);
  color: #f0d9a4;
  font-size: 13.5px;
  max-width: 52ch;
}
html[data-wechat="true"] .dl-hero__note { display: block; }

/* 二維碼 */
.dl-hero__qr {
  background: #fff;
  border-radius: 18px;
  padding: 20px 20px 22px;
  text-align: center;
  box-shadow: 0 26px 50px -26px rgba(0, 0, 0, 0.65);
}
.dl-hero__qr img {
  width: 100%;
  max-width: 200px;
  height: auto;
  display: block;
  margin: 0 auto 14px;
}
.dl-hero__qr p { margin: 0; }
.dl-hero__qr .qr-title {
  font-family: var(--serif);
  font-size: 15px;
  color: var(--ink);
  margin-bottom: 4px;
}
.dl-hero__qr .qr-hint {
  font-size: 12px;
  color: var(--ink-mute);
  line-height: 1.5;
}
html[data-os="android"] .dl-hero__qr,
html[data-os="ios"] .dl-hero__qr { display: none; }

/* 規格條 */
.spec-strip { margin-top: -46px; position: relative; z-index: 3; }
.spec-grid {
  margin: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.spec-cell { padding: 22px 26px; border-left: 1px solid var(--line); }
.spec-cell:first-child { border-left: 0; }
.spec-cell dt {
  font-family: var(--sans);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin: 0 0 7px;
}
.spec-cell dd {
  margin: 0;
  font-size: 16px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
}

/* 三步安裝 */
.step-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.step-cards li {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 24px 26px;
  overflow: hidden;
}
.step-cards li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, var(--gold-lit), rgba(201, 162, 39, 0));
}
.step-no {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.12em;
  color: var(--gold);
}
.step-cards h3 { font-size: 17px; margin: 12px 0 8px; }
.step-cards p { font-size: 14px; color: var(--ink-soft); margin: 0; line-height: 1.7; }

/* FAQ 兩欄 */
.faq-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 48px;
  border-top: 1px solid var(--line);
}
.faq-grid details { border-bottom: 1px solid var(--line); }
.faq-grid summary {
  cursor: pointer;
  padding: 18px 34px 18px 0;
  font-size: 15.5px;
  font-weight: 600;
  list-style: none;
  position: relative;
}
.faq-grid summary::-webkit-details-marker { display: none; }
.faq-grid summary::after {
  content: "+";
  position: absolute;
  right: 4px;
  top: 14px;
  font-size: 20px;
  color: var(--gold);
  font-weight: 400;
  transition: transform 0.2s ease;
}
.faq-grid details[open] summary::after { transform: rotate(45deg); }
.faq-grid details p { padding: 0 0 18px; color: var(--ink-soft); font-size: 14.5px; margin: 0; }

@media (max-width: 1024px) {
  .dl-hero__grid { grid-template-columns: 1fr; gap: 40px; }
  .dl-hero { padding: 56px 0 64px; }
  .spec-strip { margin-top: -28px; }
  .spec-grid { grid-template-columns: 1fr 1fr; }
  .spec-cell:nth-child(3) { border-left: 0; }
  .spec-cell:nth-child(n + 3) { border-top: 1px solid var(--line); }
  .step-cards { grid-template-columns: 1fr; gap: 14px; }
  .faq-grid { grid-template-columns: 1fr; gap: 0; }
}
@media (max-width: 640px) {
  .app-icon { width: 62px; height: 62px; border-radius: 16px; font-size: 20px; }
  .dl-hero__cta .btn { width: 100%; }
  .dl-hero__hint { max-width: none; }
  .spec-cell { padding: 18px 20px; }
}

/* 下載頁 v2：細節修正 */
.dl-crumb {
  margin: 0 0 24px;
  font-size: 12.5px;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.42);
}
.dl-crumb a { color: rgba(255, 255, 255, 0.68); }
.dl-crumb a:hover { color: #fff; }
.app-name { display: block; }
.app-sub { display: block; }
.dl-hero .dl-fallback {
  margin: 20px 0 0;
  max-width: 52ch;
  background: rgba(201, 162, 39, 0.12);
  border: 1px solid rgba(201, 162, 39, 0.3);
  color: #f0d9a4;
}
.dl-hero .dl-fallback a { color: #fff; border-bottom: 1px solid rgba(255, 255, 255, 0.5); }

/* 下載頁 v2：iOS 說明與 chip 收納 */
.dl-hero__sub {
  margin: 16px 0 0;
  max-width: 52ch;
  font-size: 13.5px;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.52);
}
html[data-os="ios"] .chip--android { display: none; }
@media (max-width: 640px) {
  .chip--date { display: none; }
}

/* 下載頁底部的橫幅 */
.cta--compact { padding: 38px 44px; }
.cta--compact h2 { font-size: 22px; }
@media (max-width: 640px) {
  .cta--compact { padding: 30px 26px; }
  .cta--compact h2 { font-size: 20px; }
}
