/* momo 防詐騙宣導頁 - ECM 規格
   圖片路徑只寫檔名;所有檔案平放於 images/ */

/* ========== Design tokens ========== */
:root {
  --green: #1b4d51;
  --green-dark: #123a3d;
  --green-soft: #e4efee;
  --pink: #d6107f;
  --pink-dark: #b00c68;
  --pink-soft: #fde8f3;
  --yellow: #ffd400;
  --warn: #c0361e;
  --warn-soft: #fdeeea;
  --ok: #1d7a55;
  --ok-soft: #e5f5ee;
  --ink: #1c2a2b;
  --muted: #5a6b6c;
  --line: #d6e1e0;
  --bg: #f1f5f4;
  --card: #ffffff;
  --radius: 14px;
  --shadow: 0 2px 10px rgba(18, 58, 61, .08);
  --nav-h: 60px;
  --font: "Noto Sans TC", "微軟正黑體", "Microsoft JhengHei", "PingFang TC", Helvetica, Arial, sans-serif;

  /* 文字層級 */
  --fs-h2: 1.5rem;      /* 區塊標題 24 */
  --fs-h3: 1.1875rem;   /* 案例標題 19 */
  --fs-body: 1rem;      /* 內文 16 */
  --fs-small: .875rem;  /* 備註 14 */
}

@media (min-width: 768px) {
  :root { --fs-h2: 1.875rem; --fs-h3: 1.25rem; --nav-h: 64px; }
}

/* ========== Base ========== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: 1.75;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-align: left;
}
/* momo 網域預設置中,這裡強制內容區全部靠左(權重高於一般元素選擇器) */
main, .topbar .wrap, .wrap, .wrap *, .cta .wrap * { text-align: left; }
h1, h2, h3, h4, p, ul, ol, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }
img { max-width: 100%; height: auto; border: 0; vertical-align: top; }
a { color: var(--green); text-decoration-thickness: 1px; text-underline-offset: 3px; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; box-shadow: 0 0 0 5px var(--green); }
.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.icon { width: 1.5em; height: 1.5em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* ========== Top bar ========== */
.topbar { background: var(--green); }
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; height: 48px; }
.topbar a { display: block; line-height: 0; }
.topbar svg { width: 92px; height: 17px; fill: #fff; }
.topbar span { color: #bfd6d5; font-size: var(--fs-small); }
.in-app .topbar { display: none; }

/* ========== Hero ========== */
.hero { background: var(--green); }
.hero picture, .hero img { display: block; margin: 0 auto; width: 100%; }
.hero img { max-width: 640px; }
@media (min-width: 900px) {
  .hero img { max-width: 2000px; }
}

/* ========== Finder(快速找案例) ========== */
.finder { background: var(--green); color: #fff; padding: 32px 0 40px; }
.finder-head { text-align: left; margin-bottom: 20px; }
.finder-head .eyebrow { display: inline-block; background: var(--yellow); color: #3a3000; font-weight: 700; font-size: var(--fs-small); padding: 2px 12px; border-radius: 99px; margin-bottom: 8px; }
.finder-head h2 { font-size: var(--fs-h2); line-height: 1.35; font-weight: 800; }
.finder-head p { color: #cfe3e2; margin-top: 4px; }

.search { position: relative; max-width: 560px; margin: 0 auto 10px 0; }
.search input {
  width: 100%; height: 52px; border: 0; border-radius: 99px; padding: 0 20px 0 50px;
  font: inherit; font-size: 1rem; color: var(--ink); background: #fff;
}
.search input { padding-right: 96px; }
.search-btn { position: absolute; right: 6px; top: 6px; height: 40px; padding: 0 20px; border: 0; border-radius: 99px; background: var(--pink); color: #fff; font-weight: 800; font-size: 1rem; }
.search-btn:hover { background: var(--pink-dark); }
.search input::placeholder { color: #8a9a9b; }
.search .icon { position: absolute; left: 18px; top: 14px; width: 24px; height: 24px; color: var(--green); }
.chips { display: flex; flex-wrap: wrap; justify-content: flex-start; gap: 8px; margin-bottom: 24px; }
.chips button {
  border: 1px solid rgba(255, 255, 255, .4); background: transparent; color: #fff;
  border-radius: 99px; padding: 4px 14px; min-height: 36px; font-size: var(--fs-small);
}
.chips button:hover { background: rgba(255, 255, 255, .14); }

.finder-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.fcard {
  display: flex; flex-direction: column; gap: 4px; padding: 16px 14px;
  background: #fff; color: var(--ink); text-decoration: none; border-radius: var(--radius);
  border-bottom: 4px solid var(--yellow); min-height: 140px;
  transition: transform .15s, box-shadow .15s;
}
.fcard:hover { transform: translateY(-3px); box-shadow: 0 8px 18px rgba(0, 0, 0, .25); }
.fcard .ico { width: 44px; height: 44px; border-radius: 12px; background: var(--green-soft); color: var(--green); display: flex; align-items: center; justify-content: center; margin-bottom: 4px; }
.fcard .ico .icon { width: 26px; height: 26px; }
.fcard b { font-size: 1.0625rem; line-height: 1.4; }
.fcard small { color: var(--muted); font-size: var(--fs-small); line-height: 1.5; }
.fcard em { font-style: normal; margin-top: auto; padding-top: 6px; color: var(--pink); font-weight: 700; font-size: var(--fs-small); }
.finder-grid .fcard:last-child { grid-column: 1 / -1; }
@media (min-width: 900px) {
  .finder-grid { grid-template-columns: repeat(5, 1fr); gap: 16px; }
  .finder-grid .fcard:last-child { grid-column: auto; }
  .fcard { min-height: 170px; padding: 20px 18px; }
}

/* ========== 識破三步驟 + momo 絕對不會 ========== */
.guard { padding: 36px 0 8px; }
.sec-title { font-size: var(--fs-h2); font-weight: 800; line-height: 1.35; margin-bottom: 4px; color: var(--green); }
.sec-sub { color: var(--muted); margin-bottom: 18px; }
.steps { display: grid; gap: 12px; counter-reset: s; }
.steps li { position: relative; background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px 16px 16px 72px; counter-increment: s; }
.steps li::before {
  content: counter(s); position: absolute; left: 16px; top: 16px; width: 42px; height: 42px; border-radius: 50%;
  background: var(--pink); color: #fff; font-weight: 800; font-size: 1.375rem; display: flex; align-items: center; justify-content: center;
}
.steps b { display: block; font-size: var(--fs-h3); line-height: 1.4; margin-bottom: 2px; }
.steps span { color: var(--muted); font-size: .9375rem; line-height: 1.65; display: block; }
@media (min-width: 768px) {
  .steps { grid-template-columns: repeat(3, 1fr); gap: 16px; }
  .steps li { padding: 78px 20px 20px; }
  .steps li::before { left: 20px; top: 20px; }
}

.never { margin-top: 24px; background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.never h3 { background: var(--pink); color: #fff; font-size: var(--fs-h3); padding: 12px 18px; line-height: 1.4; }
.never ul { display: grid; padding: 6px 18px 10px; }
.never li { position: relative; padding: 10px 0 10px 32px; border-bottom: 1px dashed var(--line); line-height: 1.6; }
.never li:last-child { border-bottom: 0; }
.never li::before {
  content: "✕"; position: absolute; left: 0; top: 10px; width: 22px; height: 22px; border-radius: 50%;
  background: var(--pink-soft); color: var(--pink); font-size: .75rem; font-weight: 800; display: flex; align-items: center; justify-content: center;
}
@media (min-width: 768px) {
  .never ul { grid-template-columns: 1fr 1fr; column-gap: 32px; }
  .never li:nth-last-child(2):nth-child(odd) { border-bottom: 0; }
}

/* ========== 分類導覽(sticky) ========== */
.catnav { position: sticky; top: 0; z-index: 50; background: #fff; border-bottom: 1px solid var(--line); box-shadow: 0 2px 8px rgba(0, 0, 0, .06); margin-top: 32px; }
.catnav .wrap { display: flex; align-items: center; gap: 8px; height: var(--nav-h); overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.catnav .wrap::-webkit-scrollbar { display: none; }
.catnav a {
  flex: none; display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 14px;
  border-radius: 99px; background: var(--bg); color: var(--ink); text-decoration: none; font-weight: 600; font-size: .9375rem; white-space: nowrap;
}
.catnav a .icon { width: 18px; height: 18px; }
.catnav a.on { background: var(--green); color: #fff; }
.catnav .tools { margin-left: auto; flex: none; display: none; }
.catnav .tools button { border: 1px solid var(--line); background: #fff; border-radius: 99px; height: 40px; padding: 0 14px; font-size: var(--fs-small); }
@media (min-width: 900px) { .catnav .tools { display: block; } .catnav .wrap { overflow: visible; } }

/* ========== 分類區塊 ========== */
.cats { padding: 8px 0 24px; }
.cat { padding-top: 28px; scroll-margin-top: calc(var(--nav-h) + 4px); }
.cat-head { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.cat-head .ico { width: 52px; height: 52px; border-radius: 14px; background: var(--green); color: #fff; display: flex; align-items: center; justify-content: center; flex: none; }
.cat-head .ico .icon { width: 28px; height: 28px; }
.cat-head h2 { font-size: var(--fs-h2); line-height: 1.3; font-weight: 800; color: var(--green); }
.cat-head p { color: var(--muted); font-size: var(--fs-small); line-height: 1.5; }

.note-box { border-radius: var(--radius); padding: 14px 16px; margin-bottom: 14px; background: var(--ok-soft); border-left: 5px solid var(--ok); font-size: .9375rem; line-height: 1.7; }
.note-box b { color: var(--ok); }
.note-box ul { margin-top: 4px; }
.note-box li { padding-left: 1em; text-indent: -1em; }
.note-box li::before { content: "・"; }

/* ========== 案例卡片(手風琴) ========== */
.case { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 10px; border: 1px solid transparent; }
.case[open] { border-color: var(--green); }
.case > summary {
  list-style: none; display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; cursor: pointer; min-height: 72px; border-radius: var(--radius);
}
.case > summary::-webkit-details-marker { display: none; }
.case > summary:hover { background: #f7fbfa; }
.case .no { flex: none; width: 36px; height: 36px; border-radius: 10px; background: var(--green-soft); color: var(--green); font-weight: 800; font-size: .875rem; display: flex; align-items: center; justify-content: center; }
.case .main { flex: 1; min-width: 0; }
.case .title { display: block; font-size: var(--fs-h3); font-weight: 700; line-height: 1.4; }
.case .sum { display: block; color: var(--muted); font-size: .9375rem; line-height: 1.55; margin-top: 2px; }
.case .tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.tag { font-size: .8125rem; line-height: 1; padding: 5px 9px; border-radius: 6px; background: var(--warn-soft); color: var(--warn); font-weight: 600; }
.tag.g { background: var(--green-soft); color: var(--green); }
.chev { flex: none; width: 28px; height: 28px; position: relative; align-self: flex-start; margin-top: 2px; }
.chev::before, .chev::after { content: ""; position: absolute; left: 6px; top: 13px; width: 16px; height: 2.5px; background: var(--green); border-radius: 2px; transition: transform .2s; }
.chev::after { transform: rotate(90deg); }
.case[open] .chev::after { transform: rotate(0); }

.case-body { padding: 4px 16px 20px; border-top: 1px solid var(--line); margin: 0 16px; padding-left: 0; padding-right: 0; padding-top: 16px; }
.case-body > * + * { margin-top: 14px; }
.case-body .lead { font-size: var(--fs-body); }
.lbl { display: flex; align-items: center; gap: 8px; font-size: 1rem; font-weight: 800; line-height: 1.4; margin-bottom: 6px; }
.lbl::before { content: ""; width: 5px; height: 1.1em; border-radius: 3px; background: currentColor; }
.lbl.warn { color: var(--warn); }
.lbl.ok { color: var(--ok); }
.list li { position: relative; padding: 4px 0 4px 1.5em; line-height: 1.7; }
.list.warn li::before { content: "!"; position: absolute; left: 0; top: 7px; width: 1.05em; height: 1.05em; border-radius: 50%; background: var(--warn); color: #fff; font-size: .75rem; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.list.ok li::before { content: "✓"; position: absolute; left: 0; top: 7px; width: 1.05em; height: 1.05em; border-radius: 50%; background: var(--ok); color: #fff; font-size: .72rem; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.list.num { counter-reset: n; }
.list.num li { counter-increment: n; }
.list.num li::before { content: counter(n); position: absolute; left: 0; top: 7px; width: 1.2em; height: 1.2em; border-radius: 50%; background: var(--green); color: #fff; font-size: .75rem; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.box-warn { background: var(--warn-soft); border-radius: 10px; padding: 12px 14px; }
.box-ok { background: var(--ok-soft); border-radius: 10px; padding: 12px 14px; }
.kw { display: flex; flex-wrap: wrap; gap: 8px; }
.kw span { background: #fff; border: 1px solid #f0c3b9; color: var(--warn); border-radius: 99px; padding: 4px 12px; font-size: .9375rem; font-weight: 600; }
.url { font-family: Consolas, "Courier New", monospace; font-size: .875rem; word-break: break-all; background: #f3f5f5; padding: 2px 6px; border-radius: 4px; }
.compare { display: grid; gap: 8px; }
.compare > div { border-radius: 10px; padding: 10px 14px; font-size: .9375rem; line-height: 1.6; }
.compare .real { background: var(--ok-soft); }
.compare .fake { background: var(--warn-soft); }
.compare b { display: block; font-size: .8125rem; }
.compare .real b { color: var(--ok); }
.compare .fake b { color: var(--warn); }
@media (min-width: 768px) { .compare { grid-template-columns: 1fr 1fr; } }

/* 截圖:橫向捲動縮圖 */
.shots-title { font-size: .9375rem; font-weight: 700; color: var(--muted); display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; }
.shots-title small { font-weight: 400; font-size: .8125rem; }
.shots { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 10px; scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch; }
.shot { flex: none; width: 150px; scroll-snap-align: start; }
.shot button { display: block; width: 100%; height: 180px; padding: 0; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: #fff; position: relative; }
.shot img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.shot button::after { content: "＋"; position: absolute; right: 6px; bottom: 6px; width: 26px; height: 26px; border-radius: 50%; background: rgba(27, 77, 81, .85); color: #fff; font-size: 1rem; line-height: 26px; text-align: center; }
.shot figcaption { margin-top: 6px; font-size: .8125rem; line-height: 1.45; color: var(--muted); }
@media (min-width: 768px) { .shot { width: 190px; } .shot button { height: 230px; } }

/* 搜尋結果提示列 */
.result-bar { align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 20px; padding: 12px 16px; background: var(--yellow); color: #3a3000; border-radius: var(--radius); font-weight: 600; }
.result-bar b { font-size: 1.25rem; }
.result-bar button { border: 0; background: var(--green); color: #fff; border-radius: 99px; height: 40px; padding: 0 16px; font-size: var(--fs-small); font-weight: 700; }
.chips button.on { background: var(--yellow); color: #3a3000; border-color: var(--yellow); font-weight: 700; }

/* 搜尋無結果 */
.empty { display: none; text-align: left; padding: 40px 16px; background: #fff; border-radius: var(--radius); margin-top: 24px; }
.empty b { display: block; font-size: var(--fs-h3); margin-bottom: 4px; }
.is-hidden { display: none !important; }

/* ========== 頁尾 CTA ========== */
.cta { background: var(--green); color: #fff; padding: 36px 0 28px; margin-top: 16px; }
.cta h2 { font-size: var(--fs-h2); font-weight: 800; line-height: 1.35; text-align: left; }
.cta > .wrap > p { text-align: left; color: #cfe3e2; margin: 4px 0 20px; }
.cta-btns { display: grid; gap: 12px; max-width: 720px; margin: 0 auto 0 0; }
.btn { display: flex; align-items: center; justify-content: flex-start; text-align: left; gap: 10px; min-height: 60px; border-radius: 14px; font-weight: 800; font-size: 1.125rem; text-decoration: none; padding: 8px 16px; line-height: 1.35; }
.btn.pink { background: var(--pink); color: #fff; }
.btn.pink:hover { background: var(--pink-dark); }
.btn.ghost { background: #fff; color: var(--green); }
.btn small { display: block; font-weight: 400; font-size: .8125rem; }
@media (min-width: 768px) { .cta-btns { grid-template-columns: 1fr 1fr; } }
.official { max-width: 720px; margin: 24px auto 0 0; background: rgba(255, 255, 255, .1); border-radius: var(--radius); padding: 16px 18px; font-size: .9375rem; line-height: 1.7; }
.official b { display: block; margin-bottom: 4px; }
.official a { color: var(--yellow); word-break: break-all; }
.official li { padding: 2px 0; }
.date { text-align: left; color: #9fbdbc; font-size: var(--fs-small); margin-top: 20px; }

/* ========== Lightbox ========== */
.lb { position: fixed; inset: 0; z-index: 999; background: rgba(8, 20, 21, .94); display: none; flex-direction: column; }
.lb.open { display: flex; }
.lb-bar { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px; color: #fff; font-size: var(--fs-small); }
.lb-bar button { background: rgba(255, 255, 255, .15); border: 0; color: #fff; border-radius: 99px; height: 44px; padding: 0 18px; font-size: 1rem; }
.lb-stage { flex: 1; overflow: auto; display: flex; align-items: flex-start; justify-content: center; padding: 0 12px 12px; -webkit-overflow-scrolling: touch; }
.lb-stage img { max-width: 100%; height: auto; margin: auto 0; border-radius: 6px; background: #fff; }
.lb-cap { color: #dce9e8; text-align: center; font-size: var(--fs-small); padding: 0 16px 6px; }
.lb-nav { display: flex; gap: 12px; justify-content: center; padding: 8px 12px 16px; }
.lb-nav button { flex: 1; max-width: 160px; height: 46px; border-radius: 99px; border: 0; background: #fff; color: var(--green); font-weight: 700; }
.lb-nav button:disabled { opacity: .35; }

/* ========== 回頂端 ========== */
.gotop { position: fixed; right: 14px; bottom: 16px; z-index: 40; width: 48px; height: 48px; border: 0; border-radius: 50%; background: var(--pink); color: #fff; font-weight: 800; font-size: .75rem; box-shadow: 0 4px 12px rgba(0, 0, 0, .3); display: none; }
.gotop.show { display: block; }

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
@media print { .catnav, .gotop, .finder, .lb { display: none !important; } .case:not([open]) .case-body { display: block; } }
