/* 毛伴 MAOPAL 產品官網
   品牌色:松綠 #14503A、金盞橘 #E0A23C、奶油白 #FCF9F1、米紙色 #F1EBDD、墨黑 #14241C
   70% 專業科技感、30% 溫暖:平面卡片、細框線,少量陰影只給手機外框
   排版與動效一律用下方變數,不寫零散數值 */

/* ---------- 字型 ----------
   中文用系統字(蘋果 PingFang TC、Android Noto Sans TC、Windows 微軟正黑體),不載入中文網路字型;
   英數用自託管的 Inter 子集(只含 Latin-1),首次與回訪看到同一種字體,後備字已調整字寬減少換字跳動 */
@font-face {
  font-family: "Inter";
  src: url("/fonts/inter-sub.woff2") format("woff2");
  font-weight: 400 700; font-style: normal; font-display: swap;
  unicode-range: U+0020-00FF, U+2013, U+20AC, U+2212;
}
@font-face {
  font-family: "Inter Fallback";
  src: local("Arial"), local("Helvetica Neue"), local("Roboto");
  size-adjust: 107%; ascent-override: 90%; descent-override: 22%; line-gap-override: 0%;
  unicode-range: U+0020-00FF, U+2013, U+20AC, U+2212;
}

:root {
  --pine: #14503A;
  --pine-deep: #0E3D2C;
  --pine-tint: #E2ECE5;
  --marigold: #E0A23C;
  --marigold-tint: #F7E8C9;
  --marigold-ink: #6E4B0E;
  --cream: #FCF9F1;
  --paper: #F1EBDD;
  --ink: #14241C;
  --text: #24342B;
  --muted: #536158;
  --surface: #FFFFFF;
  --line: rgba(20, 36, 28, .12);
  --line-strong: rgba(20, 36, 28, .22);

  --font: "Inter", "Inter Fallback", "PingFang TC", "Noto Sans TC", "Microsoft JhengHei", "Heiti TC", sans-serif;

  /* 字級階層:1.25 倍左右的刻度,手機到桌面平滑放大 */
  --fs-xs: 13px;                               /* 標籤、表頭、頁尾小標 */
  --fs-sm: 14px;                               /* 註解、說明小字 */
  --fs-body-sm: 16px;                          /* 卡片內文,手機不小於 16px */
  --fs-body: 16px;                             /* 內文 */
  --fs-lead: clamp(16px, 1.25vw, 18px);        /* 導言 */
  --fs-h4: 17px;                               /* 小卡標題 */
  --fs-h3: clamp(18px, 1.5vw, 21px);           /* 卡片標題 */
  --fs-h2: clamp(28px, 2.8vw, 36px);           /* 區塊標題 */
  --fs-h1: clamp(34px, 4.4vw, 56px);           /* 頁面大標,手機約桌面 0.6 倍 */
  --fs-price: clamp(38px, 4.2vw, 48px);
  /* 行高:中文內文 1.7、標題 1.25 至 1.4 */
  --lh-body: 1.7;
  --lh-ui: 1.5;
  --lh-h1: 1.3;
  --lh-h2: 1.35;
  --lh-h3: 1.4;
  /* 每行字數:中文約 25 至 35 字 */
  --measure: 34em;
  --measure-narrow: 30em;
  /* 間距刻度 */
  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px; --s-5: 20px; --s-6: 24px; --s-7: 32px; --s-8: 40px;
  --s-head: clamp(36px, 4.6vw, 56px);          /* 區塊標題到內容 */
  --pad: clamp(64px, 8.6vw, 120px);            /* 區段上下 */

  /* 動效:全站同一組時間與曲線,只動 transform 與 opacity */
  --ease: cubic-bezier(.33, 1, .68, 1);
  --dur-fast: 160ms;                           /* 滑過、按下 */
  --dur-ui: 240ms;                             /* 選單、展開 */
  --dur-enter: 720ms;                          /* 首屏進場 */
  --enter-y: 14px;                             /* 手機位移,桌面 20px */
  --stagger: 50ms;

  --gutter: clamp(16px, 4.4vw, 40px);
  --max: 1200px;
  --header: 68px;
  --r-card: 18px;
  --r-panel: 28px;
  --phone-w: min(260px, 70vw);
  --shadow-card: 0 1px 2px rgba(20, 36, 28, .06), 0 6px 18px rgba(20, 36, 28, .06);
  --shadow-phone: 0 18px 40px rgba(20, 36, 28, .16), 0 2px 6px rgba(20, 36, 28, .08);
}
@media (min-width: 960px) { :root { --phone-w: 280px; --fs-body: 17px; --lh-h1: 1.25; --enter-y: 20px; } }

*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%; text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
  scroll-padding-top: calc(var(--header) + 16px);
  background: var(--cream);
}
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background: var(--cream);
  color: var(--text);
  font: 400 var(--fs-body)/var(--lh-body) var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
  /* 中文斷行:標點不落行首;中英文之間自動留空(支援的瀏覽器);行首與連續全形標點擠壓 */
  line-break: strict;
  overflow-wrap: break-word;
  text-autospace: normal;
  text-spacing-trim: normal;
  font-variant-numeric: proportional-nums;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
::selection { background: var(--pine-tint); color: var(--ink); }
.band-pine ::selection { background: var(--marigold); color: var(--ink); }
:focus-visible { outline: 2px solid var(--pine); outline-offset: 3px; border-radius: 6px; }
button { font: inherit; color: inherit; }
p { margin: 0; text-wrap: pretty; }
h1, h2, h3, h4 { margin: 0; color: var(--ink); text-wrap: balance; }
/* 標題行首若是全形標點就擠掉半格,視覺上貼齊左邊 */
h1, h2, h3 { text-spacing-trim: trim-start; }
ul { margin: 0; padding: 0; }
li { list-style: none; }

.wrap { width: 100%; max-width: calc(var(--max) + var(--gutter) * 2); margin: 0 auto; padding: 0 max(var(--gutter), env(safe-area-inset-right)) 0 max(var(--gutter), env(safe-area-inset-left)); }
.nw { display: inline-block; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--pine); color: #fff; padding: 10px 16px; border-radius: 10px; text-decoration: none; }
.skip:focus { top: 12px; }
.centered { text-align: center; }

/* ---------- 字級 ---------- */
.display { color: var(--ink); font-weight: 700; letter-spacing: 0; }
.h-xl { font-size: var(--fs-h1); line-height: var(--lh-h1); }
.h-lg { font-size: var(--fs-h2); line-height: var(--lh-h2); }
.lead { font-size: var(--fs-lead); line-height: 1.75; color: var(--muted); max-width: var(--measure); }
.small { font-size: var(--fs-sm); line-height: var(--lh-body); color: var(--muted); max-width: 40em; }
.eyebrow {
  display: block;
  font: 600 var(--fs-xs)/1.4 var(--font); letter-spacing: .08em; text-transform: uppercase; color: var(--pine);
}
.eyebrow::before { content: ""; display: inline-block; vertical-align: middle; width: 18px; height: 2px; margin: -2px 10px 0 0; border-radius: 2px; background: var(--marigold); }

/* ---------- 按鈕 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 24px;
  border-radius: 12px; border: 1.5px solid transparent;
  font: 600 var(--fs-body)/1.2 var(--font);
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color var(--dur-fast) ease, border-color var(--dur-fast) ease, color var(--dur-fast) ease, transform var(--dur-fast) var(--ease);
  -webkit-tap-highlight-color: transparent;
}
@media (min-width: 960px) { .btn { font-size: 16px; } }
.btn:active { transform: scale(.98); }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn-sm { min-height: 44px; padding: 0 18px; font-size: 15px; border-radius: 10px; }
.btn-ink, .btn-primary { background: var(--pine); color: #fff; }
.btn-ghost { border-color: var(--line-strong); color: var(--pine); background: transparent; }
@media (hover: hover) and (pointer: fine) {
  .btn-ink:hover, .btn-primary:hover { background: var(--pine-deep); }
  .btn-ghost:hover { border-color: var(--pine); background: rgba(20, 80, 58, .04); }
}
.btns { display: flex; flex-wrap: wrap; gap: var(--s-3); }
.textlink {
  color: var(--pine); font-weight: 600;
  text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px;
  text-decoration-color: rgba(20, 80, 58, .35);
  transition: text-decoration-color var(--dur-fast) ease;
}
.textlink svg { display: inline-block; width: 16px; height: 16px; margin-left: 4px; vertical-align: -3px; }
@media (hover: hover) and (pointer: fine) {
  .textlink:hover { text-decoration-color: currentColor; }
}

/* ---------- 頁首 ---------- */
.top { position: sticky; top: 0; z-index: 50; background: rgba(252, 249, 241, .96); border-bottom: 1px solid var(--line); }
.top .wrap { height: var(--header); display: flex; align-items: center; gap: var(--s-6); }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; margin-right: auto; color: var(--ink); min-height: 44px; }
.brand img { width: 36px; height: 36px; border-radius: 10px; }
.brand b { display: block; font: 700 18px/1 var(--font); letter-spacing: .04em; }
.brand small { display: block; font: 600 12px/1 var(--font); letter-spacing: .18em; color: var(--muted); margin-top: 5px; }
.nav { display: flex; gap: var(--s-1); }
.nav a { text-decoration: none; font-size: 15px; font-weight: 400; padding: 10px 14px; border-radius: 10px; color: var(--text); transition: color var(--dur-fast) ease, background-color var(--dur-fast) ease; }
.nav a[aria-current="page"] { color: var(--pine); background: var(--pine-tint); }
@media (hover: hover) and (pointer: fine) { .nav a:hover { color: var(--pine); } }
.menu-btn { display: none; width: 44px; height: 44px; border: 0; background: transparent; border-radius: 10px; cursor: pointer; position: relative; margin-right: -8px; }
.menu-btn span { position: absolute; left: 12px; right: 12px; height: 2px; background: var(--ink); border-radius: 2px; transition: transform var(--dur-ui) var(--ease); }
.menu-btn span:first-child { top: 17px; }
.menu-btn span:last-child { top: 25px; }
.menu-btn[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
.menu-btn[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }
.panel {
  position: fixed; inset: var(--header) 0 auto 0; z-index: 49;
  background: var(--cream); color: var(--ink);
  padding: var(--s-1) var(--gutter) var(--s-6);
  border-bottom: 1px solid var(--line);
  display: grid;
  opacity: 0; transform: translateY(-6px); pointer-events: none;
  transition: opacity var(--dur-ui) var(--ease), transform var(--dur-ui) var(--ease);
}
.panel.open { opacity: 1; transform: none; pointer-events: auto; }
/* 收起時真的移除,選單連結不能被 Tab 鍵或螢幕閱讀器選到 */
.panel[hidden] { display: none; }
.panel a:not(.btn) { text-decoration: none; font-size: 18px; line-height: var(--lh-ui); padding: 14px 2px; border-bottom: 1px solid var(--line); }
.panel a[aria-current="page"] { color: var(--pine); font-weight: 600; }
.panel .btn { margin-top: 18px; }
@media (max-width: 899px) {
  .nav, .top .desk { display: none; }
  .menu-btn { display: block; }
}
@media (min-width: 900px) { .panel { display: none; } }

/* ---------- 區段 ---------- */
.section { padding: var(--pad) 0; }
.section.flush-top { padding-top: 0; }
.band-paper { background: var(--paper); }
.head { max-width: 760px; margin: 0 0 var(--s-head); }
.head .lead { margin-top: 18px; }
.head .eyebrow { margin-bottom: var(--s-4); }
.more { margin-top: 28px; }
.after-btns { margin-top: var(--s-5); }

/* ---------- 手機外框:全站同一個尺寸 ---------- */
.phone {
  position: relative; width: var(--phone-w); flex: none;
  padding: 7px; border-radius: 42px;
  background: var(--ink);
  box-shadow: inset 0 0 0 1px #2E3E35, var(--shadow-phone);
}
.phone .scr { position: relative; border-radius: 35px; overflow: hidden; aspect-ratio: 780 / 1688; background: var(--cream); }
.phone .scr img { width: 100%; height: 100%; object-fit: cover; }

/* 浮動小卡:手機旁的一則重點,內容取自同一張截圖 */
.float {
  position: absolute; z-index: 2;
  display: flex; gap: var(--s-3); align-items: flex-start;
  width: max-content; max-width: 250px;
  padding: 14px 16px; border-radius: 16px;
  background: var(--surface); border: 1px solid var(--line);
  box-shadow: var(--shadow-card);
  font-size: var(--fs-sm); line-height: var(--lh-ui);
}
.float .fi { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: var(--pine-tint); color: var(--pine); }
.float .fi.warm { background: var(--marigold-tint); color: var(--marigold-ink); }
.float .fi svg { width: 18px; height: 18px; }
.float b { display: block; color: var(--ink); font-weight: 600; font-size: var(--fs-sm); }
.float small { display: block; color: var(--muted); font-size: var(--fs-xs); margin-top: 2px; }

/* 產品展示舞台:米紙底圓角,手機置中 */
.stage {
  position: relative; display: flex; justify-content: center; align-items: center;
  padding: clamp(28px, 4vw, 48px) 16px;
  border-radius: var(--r-panel); background: var(--paper);
}
.band-paper .stage { background: var(--cream); }
.stage .float { left: clamp(8px, 2vw, 20px); bottom: clamp(20px, 6%, 56px); }
.stage .float + .float { left: auto; right: clamp(8px, 2vw, 20px); bottom: auto; top: clamp(28px, 12%, 88px); }
@media (max-width: 559px) {
  .stage .float { max-width: 210px; padding: 12px 14px; }
  .stage .float + .float { display: none; }
}

/* ---------- 左右展示(首頁核心功能、功能頁各區共用) ---------- */
.show { display: grid; gap: clamp(32px, 5vw, 48px); align-items: center; }
.show-copy .eyebrow { margin-bottom: var(--s-4); }
.show-copy .lead { margin-top: 18px; }
.show-copy .note { margin-top: 22px; }
.show-copy .more { margin-top: var(--s-6); }
.show + .show { margin-top: var(--pad); }
@media (min-width: 960px) {
  .show { grid-template-columns: minmax(0, 1fr) minmax(0, 500px); gap: clamp(48px, 6vw, 96px); }
  .show.flip { grid-template-columns: minmax(0, 500px) minmax(0, 1fr); }
  .show.flip .show-media { order: -1; }
  .show.wide { grid-template-columns: minmax(0, 1fr) minmax(0, 440px); align-items: start; }
  .show.wide.flip { grid-template-columns: minmax(0, 440px) minmax(0, 1fr); }
  .show.wide .show-media { position: sticky; top: calc(var(--header) + 32px); }
}

/* ---------- 卡片 ---------- */
.cards { display: grid; gap: var(--s-4); }
@media (min-width: 720px) { .cards.two { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 720px) { .cards.three { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 900px) { .cards.three { gap: var(--s-5); } }
.card, .cards > li {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card);
  padding: 28px 26px 30px;
  transition: border-color var(--dur-ui) ease;
}
@media (min-width: 720px) and (max-width: 959px) { .card, .cards > li { padding: 24px 20px 26px; } }
/* 卡片不能點,滑過只淡淡加深框線,不浮起來假裝可以點 */
@media (hover: hover) and (pointer: fine) { .card:hover, .cards > li:hover { border-color: rgba(20, 80, 58, .35); } }
.card .ci { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--pine-tint); color: var(--pine); margin-bottom: var(--s-5); }
.card .ci svg { width: 22px; height: 22px; }
.card h3, .cards > li h3 { font-size: var(--fs-h3); line-height: var(--lh-h3); font-weight: 700; }
.card p, .cards > li p { margin-top: var(--s-2); color: var(--muted); font-size: var(--fs-body-sm); line-height: var(--lh-body); max-width: var(--measure-narrow); }

/* ---------- 功能清單 ---------- */
.feats { display: grid; gap: var(--s-3); margin-top: var(--s-7); }
@media (min-width: 640px) { .feats.cols { grid-template-columns: 1fr 1fr; } }
.feat {
  display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: var(--s-1) 14px; align-content: start;
  padding: 18px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line);
}
.band-paper .feat { background: var(--cream); }
.feat .fi { grid-row: span 3; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: var(--pine-tint); color: var(--pine); }
.feat .fi svg { width: 20px; height: 20px; }
.feat h3 { font-size: var(--fs-h4); line-height: var(--lh-ui); font-weight: 700; display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-1) var(--s-2); }
.feat p { color: var(--muted); font-size: var(--fs-body-sm); line-height: var(--lh-body); }
.feat .meta { font-size: var(--fs-sm); line-height: var(--lh-ui); color: var(--pine); margin-top: 2px; }

/* 狀態標籤:免費、Plus、合作診所、尚未開放 */
.badge { display: inline-flex; align-items: center; font: 600 12px/1 var(--font); letter-spacing: .02em; padding: 5px 8px; border-radius: 6px; white-space: nowrap; }
.b-free { background: var(--pine-tint); color: var(--pine); }
.b-plus { background: var(--marigold-tint); color: var(--marigold-ink); }
.b-clinic { background: #E4E9EE; color: #2F4656; }
.b-soon { background: transparent; color: var(--muted); box-shadow: inset 0 0 0 1px var(--line-strong); }

/* 提醒、聲明 */
.note {
  display: flex; gap: var(--s-3); align-items: flex-start;
  padding: 16px 18px; border-radius: 16px;
  background: var(--marigold-tint); color: var(--marigold-ink);
  font-size: var(--fs-body-sm); line-height: var(--lh-body);
}
.note > span { max-width: 36em; }
.note svg { width: 20px; height: 20px; flex: none; margin-top: 2px; }
.note b { font-weight: 700; }
.note.quiet { background: var(--paper); color: var(--text); }
.band-paper .note.quiet { background: var(--cream); }

/* ---------- 首頁主視覺 ---------- */
.hero { padding: clamp(40px, 6vw, 88px) 0 var(--pad); }
.hero-split { display: grid; gap: clamp(40px, 5vw, 64px); align-items: center; }
.hero-copy { display: grid; justify-items: start; }
.soon { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-sm); line-height: 1.4; color: var(--muted); padding: 7px 12px; border-radius: 999px; background: var(--paper); }
.soon svg { width: 14px; height: 14px; }
.soon span { margin-left: var(--s-1); }
.hero h1 { margin-top: 22px; }
.hero .lead { margin-top: 22px; max-width: 30em; }
.hero .btns { margin-top: 34px; }
.hero-visual { position: relative; width: min(100%, 540px); aspect-ratio: 540 / 600; justify-self: center; }
.hero-photo { position: absolute; left: 0; top: 13%; width: 62%; margin: 0; }
.hero-photo img { width: 100%; aspect-ratio: 420 / 359; object-fit: cover; border-radius: 22px; }
.hero-visual .phone { position: absolute; right: 0; top: 0; width: 52%; padding: 6px; border-radius: 36px; }
.hero-visual .phone .scr { border-radius: 30px; }
.hero-visual .float { left: 3%; bottom: 9%; }
@media (min-width: 960px) {
  .hero-split { grid-template-columns: minmax(0, 1fr) minmax(0, 540px); }
  .hero-visual .phone { width: 280px; }
}
@media (max-width: 479px) {
  .hero-visual .float { left: 0; bottom: 4%; max-width: 200px; padding: 10px 12px; gap: 10px; }
  .hero-visual .float .fi { width: 30px; height: 30px; }
}

/* ---------- 首頁:品牌價值 ---------- */
.value-head { display: grid; gap: var(--s-5); margin-bottom: var(--s-head); }
@media (min-width: 960px) { .value-head { grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 72px; align-items: end; } }

/* ---------- 首頁:為什麼選擇毛伴(松綠底) ---------- */
.band-pine { background: var(--pine); color: #E6EFE9; }
.band-pine h2, .band-pine h3 { color: #fff; }
.band-pine :focus-visible { outline-color: var(--marigold); }
.why { display: grid; gap: 0; margin-top: var(--s-head); border-top: 1px solid rgba(255, 255, 255, .18); }
.why li { padding: 28px 0; border-bottom: 1px solid rgba(255, 255, 255, .18); display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: var(--s-1) 18px; }
.why .ci { grid-row: span 2; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: rgba(255, 255, 255, .1); color: var(--marigold); }
.why .ci svg { width: 22px; height: 22px; }
.why h3 { font-size: var(--fs-h3); line-height: var(--lh-h3); font-weight: 700; }
.why p { color: #C9D9CF; font-size: var(--fs-body-sm); max-width: var(--measure-narrow); }
@media (min-width: 900px) {
  .why { grid-template-columns: repeat(3, 1fr); border-top: 0; gap: var(--s-5); }
  .why li { display: block; padding: 32px 28px 34px; border: 1px solid rgba(255, 255, 255, .18); border-radius: var(--r-card); }
  .why .ci { margin-bottom: 22px; }
  .why p { margin-top: var(--s-2); }
}

/* ---------- 首頁:社群 ---------- */
.mini { display: grid; gap: 14px; margin-top: 28px; }
.mini li { display: grid; grid-template-columns: 36px minmax(0, 1fr); gap: 2px 14px; align-items: start; }
.mini .fi { grid-row: span 2; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--surface); color: var(--pine); border: 1px solid var(--line); }
.mini .fi svg { width: 18px; height: 18px; }
.mini h3 { font-size: var(--fs-h4); font-weight: 700; line-height: var(--lh-ui); }
.mini p { color: var(--muted); font-size: var(--fs-body-sm); }

/* ---------- 會員方案 ---------- */
.plans { display: grid; gap: var(--s-5); }
@media (min-width: 860px) { .plans { grid-template-columns: 1fr 1fr; } }
.plan { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); padding: 30px 28px 32px; display: grid; align-content: start; }
.plan.plus { border: 1.5px solid var(--pine); }
.plan h3 { font-size: var(--fs-h3); line-height: var(--lh-h3); font-weight: 700; display: flex; align-items: center; gap: 10px; }
.plan .price { font: 700 var(--fs-price)/1.05 var(--font); letter-spacing: -.02em; color: var(--ink); margin-top: var(--s-4); font-variant-numeric: tabular-nums lining-nums; }
.plan .price small { font-size: var(--fs-body); font-weight: 400; letter-spacing: 0; color: var(--muted); margin-left: 6px; }
.plan .sub { color: var(--muted); font-size: var(--fs-body-sm); margin-top: var(--s-2); }
.yearly { display: flex; flex-wrap: wrap; gap: var(--s-1) var(--s-2); align-items: baseline; }
.plan .cancel { display: flex; gap: var(--s-2); align-items: flex-start; color: var(--pine); }
.plan .cancel svg { width: 18px; height: 18px; flex: none; margin-top: 4px; stroke-width: 2; }
.yearly b { font-weight: 700; color: var(--ink); font-size: var(--fs-h4); font-variant-numeric: tabular-nums lining-nums; }
.plan ul { margin-top: var(--s-6); padding-top: var(--s-5); border-top: 1px solid var(--line); display: grid; gap: 10px; }
.plan li { display: grid; grid-template-columns: 18px minmax(0, 1fr); gap: 10px; font-size: var(--fs-body-sm); line-height: 1.65; color: var(--text); }
.plan li svg { width: 18px; height: 18px; margin-top: 4px; color: var(--pine); stroke-width: 2; }
.table-sheet { margin-top: clamp(40px, 5vw, 64px); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); padding: var(--s-2) clamp(16px, 3vw, 32px) var(--s-1); overflow-x: auto; }
.compare { width: 100%; border-collapse: collapse; font-size: var(--fs-body-sm); line-height: var(--lh-ui); }
.compare caption { text-align: left; padding: 18px 0 var(--s-2); font-size: var(--fs-h3); line-height: var(--lh-h3); font-weight: 700; color: var(--ink); }
.compare th, .compare td { padding: 14px 12px 14px 0; text-align: left; border-top: 1px solid var(--line); vertical-align: top; }
.compare thead th { font-size: var(--fs-xs); color: var(--muted); font-weight: 600; letter-spacing: .04em; }
.compare td { width: 26%; font-variant-numeric: tabular-nums; color: var(--muted); }
.compare td.p { color: var(--pine); font-weight: 600; }
.compare th[scope="row"] { font-weight: 400; color: var(--text); }
.compare svg { width: 18px; height: 18px; vertical-align: -3px; stroke-width: 2; }
.compare .no { color: #6F7A73; }
@media (max-width: 559px) { .compare th, .compare td { padding: 13px 8px 13px 0; } .compare td { width: 28%; } }
#plans .small { margin-top: var(--s-5); }

/* ---------- 常見問題 ---------- */
.narrow-sheet { max-width: 860px; margin: 0 auto; }
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; padding: 22px 44px 22px 0; position: relative;
  font-size: var(--fs-h4); line-height: var(--lh-ui); font-weight: 600; color: var(--ink);
  -webkit-tap-highlight-color: transparent;
}
@media (min-width: 960px) { .faq summary { font-size: 18px; } }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: 8px; top: 50%; width: 9px; height: 9px; margin-top: -7px;
  border-right: 2px solid var(--pine); border-bottom: 2px solid var(--pine);
  transform: rotate(45deg); transition: transform var(--dur-ui) var(--ease);
}
.faq details[open] summary::after { transform: translateY(4px) rotate(-135deg); }
.faq .ans { padding: 0 44px 24px 0; color: var(--muted); display: grid; gap: var(--s-3); }
.faq .ans p { max-width: var(--measure); }

/* ---------- 最終行動區、404 ---------- */
.cta-panel {
  display: grid; justify-items: center; text-align: center;
  padding: clamp(48px, 7vw, 88px) clamp(20px, 5vw, 64px);
  border-radius: var(--r-panel); background: var(--paper);
}
.cta-panel .mascot { width: clamp(120px, 14vw, 156px); margin-bottom: var(--s-5); }
.cta-panel .lead { margin-top: 18px; max-width: 30em; }
.cta-panel .btns { margin-top: var(--s-7); justify-content: center; }
.mailbox { margin-top: var(--s-5); font-size: var(--fs-sm); color: var(--muted); max-width: 32em; }
.mailbox a { color: var(--pine); overflow-wrap: anywhere; }
.notify-in { display: grid; justify-items: center; text-align: center; max-width: 680px; margin: 0 auto; }
.notify .mascot { width: clamp(150px, 18vw, 200px); margin-bottom: var(--s-6); }
.notify .lead { margin-top: 18px; max-width: 30em; }
.notify .btns { margin-top: 30px; justify-content: center; }
.nf { padding-top: clamp(56px, 8vw, 96px); }

/* ---------- 子頁主視覺 ---------- */
.page-hero { padding: clamp(56px, 8vw, 104px) 0 clamp(48px, 6vw, 80px); }
.page-hero .wrap { display: grid; justify-items: start; }
.page-hero .lead { margin-top: var(--s-5); }
.page-hero .btns { margin-top: var(--s-7); }
.page-hero.compact { padding-bottom: clamp(32px, 4vw, 48px); }
.page-hero.centered .wrap { justify-items: center; }
.page-hero.centered .lead { margin-inline: auto; max-width: 30em; }
.page-hero.centered .btns, .page-hero.centered .jump { justify-content: center; }
.jump { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-top: 36px; }
.jump a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; font-size: var(--fs-sm); font-weight: 400; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line-strong); color: var(--text); transition: border-color var(--dur-fast) ease, color var(--dur-fast) ease; }
@media (hover: hover) and (pointer: fine) { .jump a:hover { border-color: var(--pine); color: var(--pine); } }

/* ---------- 功能頁:完整功能總覽 ---------- */
.legend { display: flex; flex-wrap: wrap; gap: 10px 18px; margin: 0 0 28px; font-size: var(--fs-sm); color: var(--muted); }
.legend li { display: inline-flex; align-items: center; gap: var(--s-2); }
.overview { columns: 1; column-gap: var(--s-4); }
@media (min-width: 720px) { .overview { columns: 2; } }
@media (min-width: 1080px) { .overview { columns: 3; } }
.ov { break-inside: avoid; margin-bottom: var(--s-4); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); padding: 24px 22px 14px; }
.ov h3 { font-size: var(--fs-h4); line-height: var(--lh-ui); font-weight: 700; display: flex; align-items: center; gap: 10px; padding-bottom: var(--s-3); }
.ov h3 svg { width: 20px; height: 20px; color: var(--pine); }
.ov li { display: flex; justify-content: space-between; align-items: flex-start; gap: var(--s-3); padding: 11px 0; border-top: 1px solid var(--line); font-size: var(--fs-body-sm); line-height: var(--lh-ui); }
.ov li > span:first-child { min-width: 0; }
.ov li small { display: block; color: var(--muted); font-size: var(--fs-xs); margin-top: 2px; }
.ov .bs { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: var(--s-1); flex: none; max-width: 52%; }
.ov li.off > span:first-child { color: var(--muted); }

/* ---------- 給動物醫院頁 ---------- */
.split { display: grid; gap: 44px; align-items: center; }
.split .lead { margin-top: var(--s-4); }
.split-media { display: flex; justify-content: center; }
.flow { margin-top: 28px; display: grid; }
.flow li { padding: 18px 0; border-top: 1px solid var(--line); }
.flow li:last-child { border-bottom: 1px solid var(--line); }
.flow h3 { font-size: var(--fs-h4); font-weight: 700; line-height: var(--lh-ui); }
.flow p { margin-top: var(--s-1); color: var(--muted); font-size: var(--fs-body-sm); max-width: var(--measure); }
@media (min-width: 960px) { .split { grid-template-columns: minmax(0, 1fr) 320px; gap: clamp(48px, 7vw, 104px); } }

/* 法律頁:標題與內文同一欄,行長約 36 字 */
.legal { max-width: 38em; margin: 0 auto; width: 100%; }
.legal-hero .legal .lead { margin-top: var(--s-4); }
.legal h2 { font-size: var(--fs-h3); line-height: var(--lh-h3); margin: 40px 0 var(--s-3); }
.legal h2:first-child { margin-top: 0; }
.legal p, .legal li { color: var(--text); line-height: 1.8; }
.toc { margin-top: var(--s-6); padding: var(--s-4) var(--s-5); border-radius: 16px; background: var(--paper); }
.toc ol { margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 8.5em), 1fr)); gap: 0 var(--s-4); }
.legal .toc li { list-style: none; }
.toc a { display: flex; align-items: center; min-height: 44px; text-wrap: balance; line-height: var(--lh-ui); font-size: var(--fs-sm); color: var(--pine); text-decoration: none; }
@media (hover: hover) and (pointer: fine) { .toc a:hover { text-decoration: underline; text-underline-offset: 4px; } }
.legal p + p, .legal ul + p { margin-top: var(--s-3); }
.legal ul { padding-left: 1.2em; margin: 10px 0; display: grid; gap: var(--s-2); }
.legal li { list-style: disc; }
.legal li::marker { color: var(--muted); }
.legal b { font-weight: 600; color: var(--ink); }

/* ---------- 頁尾 ---------- */
.foot { border-top: 1px solid var(--line); background: var(--cream); color: var(--muted); padding: 64px 0 36px; font-size: var(--fs-body-sm); }
.foot-grid { display: grid; gap: 36px; }
.foot .brand { margin-bottom: 14px; }
.foot .foot-h { margin: 0 0 var(--s-2); font-size: var(--fs-xs); line-height: var(--lh-ui); letter-spacing: .1em; color: var(--ink); font-weight: 700; }
.foot ul { display: grid; }
.foot ul a { display: inline-flex; align-items: center; min-height: 40px; overflow-wrap: anywhere; }
.foot a { text-decoration: none; transition: color var(--dur-fast) ease; }
@media (hover: hover) and (pointer: fine) { .foot a:hover { color: var(--pine); } }
.foot .legal-row { margin-top: 48px; padding-top: 22px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: var(--s-2) var(--s-6); justify-content: space-between; font-size: var(--fs-xs); }
@media (min-width: 800px) { .foot-grid { grid-template-columns: 1.6fr 1fr 1fr 1fr; } }
@media (max-width: 799px) { .foot ul a { min-height: 44px; } }

/* AI 共同開發醫院(給動物醫院頁) */
.aip-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); gap: var(--s-3); }
.aip-list li { border-radius: 16px; background: var(--paper); padding: 16px 18px; display: grid; gap: var(--s-1); min-width: 0; color: var(--ink); }
.aip-list li b { font-size: var(--fs-h4); overflow-wrap: anywhere; }
.aip-list li span { font-size: var(--fs-sm); color: var(--pine); }
#faq + #notify { padding-top: 0; }

/* ---------- 動效:只有首屏一處,只播一次 ----------
   頁首大標逐行淡入上移(交錯 50ms),同一區的導言、按鈕、圖只淡入不位移;其餘區塊一律靜止。
   漸進增強:預設一律可見,動畫結束狀態就是原本樣子;關閉 JS 時沒有動畫;減少動態時全部停用 */
@media (prefers-reduced-motion: no-preference) {
  .js .rise { animation: fade var(--dur-enter) var(--ease) both; animation-delay: calc(var(--i, 0) * var(--stagger) + 40ms); }
  .js .line.rise { display: inline-block; animation-name: rise; }
  @keyframes fade { from { opacity: 0; } }
  @keyframes rise { from { opacity: 0; transform: translateY(var(--enter-y)); } }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: 1ms !important; transition-delay: 0ms !important; scroll-behavior: auto !important; }
}
