/* 尺度：介紹、服務條款、隱私權政策共用的樣式。
   格式刻意和其他作品不同：頂部是三頁切換的分頁；介紹頁是產品形銷頁；
   條款與政策是「規格表 + 量尺導覽」，深淺色跟隨系統。 */
:root {
  --bg: #f6f3ec; --paper: #fffdf8; --ink: #1d1b18; --muted: #6f695e; --line: #e3dccd; --soft: #efe9dc;
  --accent: #e8602c; --accent-deep: #c4471a; --accent-soft: #fde7dc; --on-accent: #ffffff; --ok: #2f7d4f;
  --mono: ui-monospace, "SF Mono", "Roboto Mono", Menlo, Consolas, monospace;
  --shadow: 0 1px 2px rgba(40, 30, 10, .05), 0 10px 30px rgba(40, 30, 10, .07);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #141317; --paper: #1d1c21; --ink: #f1eee8; --muted: #a49e94; --line: #34313a; --soft: #26242b;
    --accent: #ff7a45; --accent-deep: #ff9a70; --accent-soft: #3a251c; --on-accent: #1d1b18; --ok: #4cc27c;
    --shadow: 0 1px 2px rgba(0, 0, 0, .35), 0 10px 30px rgba(0, 0, 0, .3);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 130px; }
body {
  margin: 0; background: var(--bg); color: var(--ink); font-size: 16.5px; line-height: 1.8;
  font-family: system-ui, -apple-system, "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
  -webkit-text-size-adjust: 100%;
}
a { color: var(--accent-deep); text-underline-offset: 3px; }
img { max-width: 100%; height: auto; }
code { font-family: var(--mono); font-size: .85em; background: var(--soft); padding: 1px 6px; border-radius: 6px; overflow-wrap: anywhere; }
.in { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); }
.skip { position: absolute; left: -999px; top: 8px; z-index: 50; background: var(--ink); color: var(--bg); padding: 8px 14px; border-radius: 8px; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* ---------- site header: brand + three-page tabs ---------- */
.site-head { position: sticky; top: 0; z-index: 30; background: var(--bg); border-bottom: 1px solid var(--line); }
.site-head .in { display: flex; align-items: center; gap: 16px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 900; font-size: 20px; letter-spacing: 4px; }
.brand img { width: 32px; height: 32px; }
.tabs { margin-left: auto; display: flex; background: var(--soft); border-radius: 12px; padding: 4px; gap: 2px; }
.tabs a { padding: 6px 14px; border-radius: 9px; color: var(--muted); text-decoration: none; font-weight: 700; font-size: 15px; white-space: nowrap; }
.tabs a:hover { color: var(--ink); }
.tabs a[aria-current="page"] { background: var(--paper); color: var(--ink); box-shadow: var(--shadow); }

/* a strip of ruler ticks used as a divider */
.ticks { height: 14px; background:
  repeating-linear-gradient(90deg, var(--line) 0 1px, transparent 1px 10px) bottom / 100% 7px no-repeat,
  repeating-linear-gradient(90deg, var(--muted) 0 1px, transparent 1px 50px) bottom / 100% 14px no-repeat; opacity: .8; }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; gap: 8px; border: 0; border-radius: 999px; padding: 11px 20px; font: inherit; font-weight: 800; text-decoration: none; cursor: pointer; }
.btn.solid { background: var(--accent); color: var(--on-accent); }
.btn.line { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 2px var(--line); }
.chip { display: inline-block; font-size: 13px; font-weight: 800; padding: 2px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-deep); }

/* ============================================================ landing page */
.landing section { padding-block: 56px; }
.landing h2 { font-size: clamp(26px, 4vw, 34px); line-height: 1.3; margin: 0 0 8px; }
.landing .sub { color: var(--muted); margin: 0 0 24px; font-size: 17px; }

.hero { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.landing section.hero { padding-block: 48px 24px; }
.hero h1 { font-size: clamp(36px, 6.4vw, 60px); line-height: 1.15; margin: 14px 0 0; font-weight: 900; letter-spacing: -.5px; }
.hero h1 .mark { display: block; color: var(--accent); }
.hero .ruler-line { display: block; width: min(420px, 100%); height: 18px; margin: 14px 0 18px; }
.hero .lead { font-size: 18.5px; color: var(--muted); margin: 0 0 22px; max-width: 34em; }
.hero .cta { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.hero .state { font-size: 14px; color: var(--muted); }
.phone { position: relative; justify-self: center; width: min(300px, 80vw); aspect-ratio: 500 / 1083; border-radius: 40px; padding: 10px; background: #1d1b18; box-shadow: 0 30px 60px -20px rgba(40, 30, 10, .45); }
.phone img { display: block; width: 100%; height: 100%; border-radius: 31px; object-fit: cover; background: var(--soft); }

.try { display: grid; grid-template-columns: auto 1fr; gap: 28px; align-items: center; background: var(--paper); border-radius: 28px; box-shadow: var(--shadow); padding: 28px; margin: 8px 0 0; }
.try .press { width: 150px; height: 150px; border-radius: 50%; border: 0; font: inherit; font-size: 21px; font-weight: 900; color: #fff; cursor: pointer;
  background: radial-gradient(circle at 35% 30%, #f6a27f, var(--accent)); box-shadow: 0 16px 36px -14px var(--accent); touch-action: manipulation; -webkit-user-select: none; user-select: none; }
.try .press.running { animation: breathe 2s ease-in-out infinite; }
@keyframes breathe { 50% { transform: scale(1.06); } }
.try h2 { font-size: 26px; margin: 4px 0; }
.try h2 b { color: var(--accent); }
.try .out { margin: 8px 0 0; min-height: 3.6em; font-weight: 700; }
.try .out strong { font-size: 30px; font-family: var(--mono); margin-right: 8px; }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; counter-reset: step; border-top: 2px solid var(--ink); }
.steps li { list-style: none; padding: 18px 20px 4px 0; position: relative; counter-increment: step; }
.steps li::before { content: counter(step) " cm"; position: absolute; top: -30px; left: 0; font-family: var(--mono); font-size: 13px; color: var(--muted); }
.steps li::after { content: ""; position: absolute; top: -2px; left: 0; width: 2px; height: 14px; background: var(--ink); }
.steps b { display: block; font-size: 19px; margin-bottom: 4px; }
.steps ol, .steps { margin: 30px 0 0; padding: 0; }

.showcase { display: grid; grid-template-columns: 260px 1fr; gap: 36px; align-items: center; }
.showcase .phone { width: 260px; justify-self: start; }
.shot-tabs { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.shot-tabs button { width: 100%; text-align: left; border: 0; background: transparent; font: inherit; color: var(--ink); padding: 12px 16px; border-radius: 14px; cursor: pointer; display: grid; gap: 2px; }
.shot-tabs button b { font-size: 17px; }
.shot-tabs button span { color: var(--muted); font-size: 15px; }
.shot-tabs button[aria-selected="true"] { background: var(--paper); box-shadow: var(--shadow); }
.shot-tabs button[aria-selected="true"] b { color: var(--accent-deep); }

.groups { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.group { background: var(--paper); border-radius: 20px; padding: 18px 20px; box-shadow: var(--shadow); }
.group h3 { margin: 0 0 8px; font-size: 15px; color: var(--muted); letter-spacing: 1px; }
.group ul { list-style: none; padding: 0; margin: 0; }
.group li { padding: 6px 0; border-top: 1px dashed var(--line); }
.group li:first-child { border-top: 0; }
.group li b { margin-right: 6px; }
.group li span { color: var(--muted); font-size: 15px; }

.gauge { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin: 8px 0 16px; }
.gauge div { background: var(--paper); border-radius: 14px; padding: 12px 10px 10px; box-shadow: var(--shadow); text-align: center; }
.gauge b { display: block; font-size: 17px; }
.gauge i { display: block; height: 8px; border-radius: 4px; background: var(--accent); margin: 8px auto 6px; opacity: .85; }
.gauge .w1 i { width: 90%; } .gauge .w2 i { width: 74%; } .gauge .w3 i { width: 58%; } .gauge .w4 i { width: 42%; } .gauge .w5 i { width: 26%; }
.gauge span { font-size: 13px; color: var(--muted); }

.modes { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 32px; padding: 0; margin: 0; list-style: none; }
.modes li { display: grid; grid-template-columns: 34px 1fr; gap: 4px 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.modes .ic { font-size: 24px; grid-row: span 2; }
.modes span { color: var(--muted); font-size: 15px; }

.plans { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: stretch; }
.plan { background: var(--paper); border-radius: 24px; padding: 24px; box-shadow: var(--shadow); display: flex; flex-direction: column; }
.plan.plus { box-shadow: inset 0 0 0 2px var(--accent), var(--shadow); }
.plan h3 { margin: 0; font-size: 20px; }
.plan .price { font-size: 36px; font-weight: 900; font-family: var(--mono); margin: 6px 0 2px; }
.plan .price small { font-size: 15px; font-family: inherit; color: var(--muted); font-weight: 700; }
.plan ul { list-style: none; padding: 0; margin: 14px 0 0; }
.plan li { padding: 7px 0 7px 26px; position: relative; border-top: 1px solid var(--line); }
.plan li::before { content: "✓"; position: absolute; left: 2px; color: var(--ok); font-weight: 900; }
.plan li.no::before { content: "·"; color: var(--muted); }
.fineprint { color: var(--muted); font-size: 14.5px; margin-top: 16px; }

.qa { border-top: 1px solid var(--line); }
.qa details { border-bottom: 1px solid var(--line); padding: 4px 0; }
.qa summary { cursor: pointer; list-style: none; padding: 14px 32px 14px 0; font-weight: 800; position: relative; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after { content: "+"; position: absolute; right: 4px; top: 10px; font-size: 22px; color: var(--accent); font-weight: 400; }
.qa details[open] summary::after { content: "−"; }
.qa details p { margin: 0 0 14px; color: var(--muted); }

.closing { text-align: center; }
.closing p { color: var(--muted); }
.closing .cta { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 14px; }

/* ============================================================ legal documents */
.doc-top { padding-block: 40px 8px; }
.eyebrow { font-family: var(--mono); font-size: 13px; color: var(--muted); letter-spacing: 1px; margin: 0; }
.doc-top h1 { font-size: clamp(32px, 5vw, 46px); margin: 6px 0 8px; line-height: 1.2; }
.doc-top .lead { font-size: 18px; color: var(--muted); margin: 0 0 14px; max-width: 40em; }
.stamp { display: inline-flex; flex-wrap: wrap; gap: 6px 14px; font-family: var(--mono); font-size: 13px; color: var(--muted); border: 1px dashed var(--line); border-radius: 10px; padding: 6px 12px; margin: 0; }
.notice { margin: 18px 0 0; background: var(--accent-soft); border-radius: 14px; padding: 12px 16px; font-size: 15.5px; }

.spec { margin: 24px 0 0; background: var(--paper); border-radius: 20px; box-shadow: var(--shadow); overflow: hidden; }
.spec caption { text-align: left; font-weight: 900; padding: 14px 18px 6px; font-size: 15px; letter-spacing: 1px; color: var(--muted); }
.spec table { width: 100%; border-collapse: collapse; }
.spec th, .spec td { text-align: left; vertical-align: top; padding: 10px 18px; border-top: 1px solid var(--line); font-size: 15.5px; }
.spec th { width: 34%; font-weight: 800; white-space: nowrap; }

.doc-body { display: grid; grid-template-columns: 230px 1fr; gap: 40px; padding-block: 28px 60px; }
.rail { position: sticky; top: 88px; align-self: start; max-height: calc(100vh - 110px); overflow: auto; }
.rail ol { list-style: none; margin: 0; padding: 0 0 0 18px; border-left: 2px solid var(--ink); }
.rail li { position: relative; }
.rail li::before { content: ""; position: absolute; left: -18px; top: 15px; width: 8px; height: 2px; background: var(--muted); }
.rail li:nth-child(5n)::before { width: 14px; background: var(--ink); }
.rail a { display: block; padding: 5px 6px; color: var(--muted); text-decoration: none; font-size: 14.5px; line-height: 1.5; border-radius: 8px; }
.rail a .n { font-family: var(--mono); font-size: 12.5px; margin-right: 6px; }
.rail a:hover { color: var(--ink); }
.rail a.on { color: var(--accent-deep); font-weight: 800; }
.rail li.on::before { background: var(--accent); width: 14px; }

.clauses { min-width: 0; counter-reset: clause; }
.clause { counter-increment: clause; padding: 6px 0 26px; border-bottom: 1px solid var(--line); margin-bottom: 22px; }
.clause:last-child { border-bottom: 0; }
.clause h2 { font-size: 23px; line-height: 1.4; margin: 0 0 10px; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; }
.clause h2 .no { font-family: var(--mono); font-size: 14px; font-weight: 700; color: var(--accent-deep); }
.clause h3 { font-size: 17px; margin: 18px 0 4px; }
.clause p { margin: 8px 0; }
.items { counter-reset: item; list-style: none; padding: 0; margin: 8px 0; }
.items > li { counter-increment: item; position: relative; padding-left: 46px; margin: 8px 0; }
.items > li::before { content: counter(clause) "." counter(item); position: absolute; left: 0; top: 1px; font-family: var(--mono); font-size: 13.5px; color: var(--muted); }
.clause ul:not(.items) { padding-left: 1.3em; }
.table-wrap { overflow-x: auto; margin: 10px 0; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); }
.table-wrap table { border-collapse: collapse; width: 100%; min-width: 520px; font-size: 15px; }
.table-wrap th, .table-wrap td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.table-wrap th { background: var(--soft); font-size: 14px; }
.table-wrap tr:last-child td { border-bottom: 0; }
.mail { display: inline-block; font-family: var(--mono); font-weight: 700; background: var(--paper); box-shadow: var(--shadow); padding: 8px 14px; border-radius: 10px; text-decoration: none; }
.en { background: var(--paper); border-radius: 20px; padding: 18px 22px; box-shadow: var(--shadow); margin-top: 10px; }
.en h2 { font-size: 20px; margin: 0 0 6px; }
.en ul { padding-left: 1.2em; }

/* ---------- footer ---------- */
.site-foot { border-top: 1px solid var(--line); padding: 22px 0 34px; color: var(--muted); font-size: 14px; }
.site-foot .in { display: flex; flex-wrap: wrap; gap: 8px 20px; justify-content: space-between; }
.site-foot nav { display: flex; gap: 16px; flex-wrap: wrap; }
.site-foot a { color: var(--muted); }

/* ---------- narrow screens ---------- */
@media (max-width: 860px) {
  .hero, .showcase, .plans { grid-template-columns: 1fr; }
  .hero .phone { order: -1; width: min(220px, 60vw); }
  .showcase .phone { justify-self: center; width: min(240px, 66vw); }
  .groups { grid-template-columns: 1fr 1fr; }
  .doc-body { grid-template-columns: 1fr; gap: 10px; padding-block-start: 8px; }
  /* the rail becomes a horizontal strip of chapters under the header */
  .rail { top: 64px; z-index: 20; max-height: none; overflow-x: auto; overflow-y: hidden; background: var(--bg); margin: 0 -20px; padding: 8px 20px; border-bottom: 1px solid var(--line); scrollbar-width: none; }
  .rail::-webkit-scrollbar { display: none; }
  .rail ol { display: flex; border-left: 0; padding: 0; gap: 6px; }
  .rail li::before { display: none; }
  .rail a { white-space: nowrap; background: var(--paper); box-shadow: var(--shadow); padding: 4px 12px; border-radius: 999px; }
  .rail a .t { display: none; }
  .rail a .n { margin: 0; font-size: 13px; }
  .rail a.on { background: var(--accent); color: var(--on-accent); }
  html { scroll-padding-top: 130px; }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  .site-head .in { flex-wrap: wrap; gap: 6px 10px; padding-top: 8px; padding-bottom: 8px; }
  .tabs { margin-left: 0; width: 100%; }
  .tabs a { flex: 1; text-align: center; padding: 6px 4px; font-size: 14px; }
  .rail { top: 102px; }
  html { scroll-padding-top: 160px; }
  .landing section { padding-block: 40px; }
  .try { grid-template-columns: 1fr; text-align: center; padding: 22px 18px; }
  .try .press { margin: 0 auto; }
  .steps { grid-template-columns: 1fr; border-top: 0; border-left: 2px solid var(--ink); margin-left: 8px; }
  .steps li { padding: 0 0 18px 22px; }
  .steps li::before { position: static; display: block; }
  .steps li::after { top: 10px; left: -2px; width: 14px; height: 2px; }
  .groups, .modes { grid-template-columns: 1fr; }
  .gauge { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; }
  .gauge div { padding: 10px 2px 8px; }
  .gauge b { font-size: 14px; }
  .gauge span { font-size: 11.5px; }
  .spec th { white-space: normal; width: 38%; }
  .items > li { padding-left: 40px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .try .press.running { animation: none; }
}
