/* Layout: a client book. Left-aligned reading column; the only ornament is the manila hang tag,
   the tag merchants already tie to every piece they sell, used here for what the system writes about a customer. */
:root {
  --paper: #f2f3f0;
  --sheet: #ffffff;
  --ink: #1a1a1f;
  --muted: #5f616a;
  --rule: #d9dbd6;
  --accent: #7b2433;
  --accent-soft: #f3e3e5;
  --tag: #efe3cc;
  --tag-ink: #3b2f22;
  --display: "Noto Serif TC", "Songti TC", "PMingLiU", serif;
  --body: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", system-ui, sans-serif;
  --hand: "LXGW WenKai TC", "Kaiti TC", "DFKai-SB", "BiauKai", serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #131316; --sheet: #1c1c21; --ink: #ececef; --muted: #a0a1aa; --rule: #2e2f36;
    --accent: #e3909a; --accent-soft: #3a2329; --tag: #2b261f; --tag-ink: #eadcc6;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #131316; --sheet: #1c1c21; --ink: #ececef; --muted: #a0a1aa; --rule: #2e2f36;
  --accent: #e3909a; --accent-soft: #3a2329; --tag: #2b261f; --tag-ink: #eadcc6;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--body); font-size: 16px; line-height: 1.8; }
.wrap { max-width: 1040px; margin: 0 auto; padding-inline: 16px; }
.read { max-width: 40em; }
a { color: var(--accent); }
a:focus-visible, .btn:focus-visible, summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* Navigation */
nav.site { border-bottom: 1px solid var(--rule); background: var(--paper); }
nav.site .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 22px; padding-block: 14px; }
nav.site .mark { font-family: var(--display); font-weight: 900; font-size: 22px; color: var(--ink); text-decoration: none; margin-right: auto; }
nav.site .mark span { font-family: var(--body); font-weight: 400; font-size: 13px; color: var(--muted); margin-left: 8px; }
nav.site a.page { color: var(--muted); text-decoration: none; font-size: 15px; }
nav.site a.page:hover, nav.site a.page[aria-current="page"] { color: var(--ink); text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 6px; }

/* Type scale: 15 / 17 / 20 / 26 / 34 / 48 */
h1, h2, h3 { font-family: var(--display); text-wrap: balance; margin: 0; }
h1 { font-size: clamp(34px, 6.4vw, 54px); line-height: 1.22; font-weight: 900; letter-spacing: 0.01em; }
h2 { font-size: clamp(24px, 3.6vw, 32px); line-height: 1.35; font-weight: 700; }
h3 { font-size: 19px; line-height: 1.45; font-weight: 700; }
p { margin: 0; }
.lead { font-size: 18px; color: var(--muted); }
.muted { color: var(--muted); }
.small { font-size: 14px; color: var(--muted); }

section { padding-block: 64px; border-top: 1px solid var(--rule); }
.stack { display: grid; gap: 16px; }
.stack-lg { display: grid; gap: 28px; }

/* Hero */
.hero { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 48px; align-items: center; padding-block: 56px 72px; }
.hero > * { min-width: 0; }
@media (max-width: 820px) { .hero { grid-template-columns: 1fr; gap: 40px; padding-block: 40px 56px; } }
.page-head { padding-block: 56px 40px; display: grid; gap: 16px; }

/* Buttons */
.actions { display: flex; flex-wrap: wrap; gap: 12px 20px; align-items: center; }
.btn { display: inline-block; background: var(--accent); color: var(--sheet); text-decoration: none; font-weight: 700; padding: 12px 22px; border-radius: 6px; }
.btn:hover { filter: brightness(1.08); }
.email { font-family: var(--display); font-size: 20px; user-select: all; }

/* The hang tag: the page's one signature object */
.tag {
  position: relative;
  background: var(--tag);
  color: var(--tag-ink);
  padding: 18px 22px 18px 48px;
  clip-path: polygon(18px 0, 100% 0, 100% 100%, 18px 100%, 0 calc(100% - 18px), 0 18px);
  max-width: 420px;
}
.tag::before {
  content: "";
  position: absolute; left: 16px; top: 50%;
  width: 12px; height: 12px; margin-top: -6px;
  border-radius: 50%;
  background: var(--paper);
  box-shadow: inset 0 0 0 2px var(--tag-ink);
  opacity: 0.55;
}
.tag .label { font-size: 13px; opacity: 0.75; }
.tag .hand { font-family: var(--hand); font-size: 20px; line-height: 1.55; }
.tag dl { display: grid; grid-template-columns: 4.5em 1fr; gap: 4px 12px; margin: 6px 0 0; font-size: 15px; }
.tag dt { opacity: 0.7; }
.tag dd { margin: 0; font-family: var(--hand); font-size: 17px; min-width: 0; }
.tilt { transform: rotate(-2deg); }
.demo-note { font-size: 13px; color: var(--muted); margin-top: 10px; }

/* Phone mock: a generic chat, not any app's real interface */
.phone { background: var(--sheet); border: 1px solid var(--rule); border-radius: 28px; padding: 18px 14px 22px; max-width: 360px; box-shadow: 0 30px 60px -40px rgba(20, 20, 30, 0.45); }
.phone .bar { text-align: center; font-size: 13px; color: var(--muted); padding-bottom: 12px; border-bottom: 1px solid var(--rule); margin-bottom: 14px; }
.chat { display: grid; gap: 10px; font-size: 15px; }
.msg { max-width: 82%; padding: 9px 13px; border-radius: 16px; line-height: 1.6; }
.msg.them { background: var(--paper); justify-self: start; border-bottom-left-radius: 4px; }
.msg.us { background: var(--accent-soft); justify-self: end; border-bottom-right-radius: 4px; }
.gap-mark { justify-self: center; font-size: 12px; color: var(--muted); padding: 2px 10px; border: 1px dashed var(--rule); border-radius: 999px; }
.hero-visual { display: grid; justify-items: center; position: relative; }
.hero-visual .tag { margin-top: -28px; margin-left: 40px; box-shadow: none; }
@media (max-width: 820px) { .hero-visual .tag { margin-left: 0; } }

/* Approval card mock */
.approval { background: var(--sheet); border: 1px solid var(--rule); border-radius: 12px; padding: 20px; max-width: 460px; display: grid; gap: 12px; }
.approval .head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px; font-size: 14px; color: var(--muted); }
.approval .reason { font-weight: 700; color: var(--accent); }
.approval .draft { background: var(--paper); border-radius: 8px; padding: 12px 14px; font-size: 15px; }
.approval .buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.approval .buttons span { border: 1px solid var(--rule); border-radius: 6px; padding: 6px 14px; font-size: 14px; }
.approval .buttons span:first-child { background: var(--accent); color: var(--sheet); border-color: var(--accent); }

.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; align-items: center; }
.split > * { min-width: 0; }
@media (max-width: 820px) { .split { grid-template-columns: 1fr; gap: 32px; } }

/* Numbered flow: a real sequence */
ol.flow { list-style: none; margin: 0; padding: 0; counter-reset: step; display: grid; }
ol.flow li { counter-increment: step; display: grid; grid-template-columns: 2.6em 1fr; gap: 14px; padding-block: 16px; border-bottom: 1px solid var(--rule); }
ol.flow li:last-child { border-bottom: 0; }
ol.flow li::before { content: counter(step); font-family: var(--display); font-size: 26px; font-weight: 900; color: var(--accent); line-height: 1.2; }
ol.flow li > div { min-width: 0; display: grid; gap: 4px; }
ol.flow .when { font-size: 13px; color: var(--muted); }

/* Proof figures */
.proof { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 32px; }
.proof > div { min-width: 0; display: grid; gap: 8px; align-content: start; }
.figure { font-family: var(--display); font-weight: 900; font-size: 48px; line-height: 1; color: var(--accent); font-variant-numeric: tabular-nums; }

/* Fit columns */
.fit { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px; }
.fit > div { min-width: 0; display: grid; gap: 12px; align-content: start; }
@media (max-width: 680px) { .fit { grid-template-columns: 1fr; } }
ul.plain { margin: 0; padding-left: 20px; display: grid; gap: 8px; }

/* Reasons as small hang tags */
.reasons { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; padding: 0; list-style: none; }
.reasons li { background: var(--tag); color: var(--tag-ink); font-family: var(--hand); font-size: 17px; padding: 4px 14px 4px 22px; clip-path: polygon(10px 0, 100% 0, 100% 100%, 10px 100%, 0 50%); }

/* Cadence scale, 0 to 90 days */
.scale { display: grid; gap: 14px; }
.scale .axis { position: relative; height: 22px; margin-left: 8.5em; border-bottom: 1px solid var(--rule); font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.scale .axis span { position: absolute; bottom: 4px; transform: translateX(-50%); }
.scale .axis span:first-child { transform: none; }
.scale .axis span:last-child { transform: translateX(-100%); }
.scale .row { display: grid; grid-template-columns: 8em 1fr; gap: 0.5em; align-items: center; }
.scale .row > * { min-width: 0; }
.scale .name { font-weight: 700; font-size: 15px; }
.scale .track { position: relative; height: 26px; background: var(--sheet); border: 1px solid var(--rule); border-radius: 4px; }
.scale .bar { position: absolute; top: 4px; bottom: 4px; background: var(--accent); border-radius: 3px; min-width: 6px; }
.scale .bar.trigger { background: repeating-linear-gradient(90deg, var(--accent) 0 6px, transparent 6px 10px); }
@media (max-width: 560px) {
  .scale .row { grid-template-columns: 1fr; gap: 4px; }
  .scale .axis { margin-left: 0; }
}

/* Cases */
.case { display: grid; grid-template-columns: minmax(0, 11em) minmax(0, 1fr); gap: 12px 32px; padding-block: 28px; border-bottom: 1px solid var(--rule); }
.case:last-of-type { border-bottom: 0; }
.case > div { min-width: 0; display: grid; gap: 8px; align-content: start; }
@media (max-width: 600px) { .case { grid-template-columns: 1fr; } }
.answer { border-left: 3px solid var(--accent); padding-left: 14px; }

/* FAQ */
details { border-bottom: 1px solid var(--rule); padding-block: 14px; }
details:first-of-type { border-top: 1px solid var(--rule); }
summary { cursor: pointer; font-weight: 700; font-size: 17px; list-style-position: outside; }
details p { margin-top: 8px; color: var(--muted); max-width: 40em; }

/* Closing call to action */
.closing { background: var(--sheet); border: 1px solid var(--rule); border-radius: 12px; padding: 32px 28px; display: grid; gap: 14px; margin-block: 64px 0; }

footer { border-top: 1px solid var(--rule); margin-top: 64px; padding-block: 28px 48px; color: var(--muted); font-size: 14px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 8px 24px; }

@media (prefers-reduced-motion: no-preference) {
  .hero-visual .tag { animation: swing 1.4s ease-out 0.3s both; transform-origin: 0 50%; }
  @keyframes swing { 0% { transform: rotate(-9deg); } 60% { transform: rotate(1deg); } 100% { transform: rotate(-2deg); } }
}

.approval .status { font-size: 13px; color: var(--accent); }
@media (prefers-reduced-motion: no-preference) {
  .approval.play .small { animation: rise 0.5s ease-out 0.2s both; }
  .approval.play .draft { animation: rise 0.6s ease-out 0.8s both; }
  .approval.play .buttons span:first-child { animation: press 0.5s ease-in-out 2.2s both; }
  .approval.play .status { animation: rise 0.5s ease-out 2.8s both; }
  @keyframes rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
  @keyframes press { 0%, 100% { transform: none; } 40% { transform: scale(0.94); filter: brightness(0.85); } }
}

.compare { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; }
.compare .col { min-width: 0; background: var(--sheet); border: 1px solid var(--rule); border-radius: 12px; padding: 22px; display: grid; gap: 12px; align-content: start; }
.compare .col.on { border-color: var(--accent); }
.compare .col:not(.on) { color: var(--muted); }
@media (max-width: 680px) { .compare { grid-template-columns: 1fr; } }
ul.timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
ul.timeline li { display: grid; grid-template-columns: 5.5em 1fr; gap: 10px; }
ul.timeline li > * { min-width: 0; }
ul.timeline b { font-weight: 700; font-variant-numeric: tabular-nums; }
.compare .col.on b { color: var(--accent); }

.polish { display: grid; gap: 12px; max-width: 460px; }
.polish > div { border-radius: 10px; padding: 14px 16px; display: grid; gap: 4px; }
.polish .before { background: var(--sheet); border: 1px dashed var(--rule); color: var(--muted); }
.polish .after { background: var(--accent-soft); }
.polish .label { font-size: 13px; color: var(--muted); }
