/* Palette and square corners come from the app's default theme (src/renderer/theme.js). */
:root {
  color-scheme: dark;
  --bg: #111111;
  --panel: #161616;
  --raised: #292929;
  --text: #dedede;
  --strong: #f5f5f5;
  --muted: #a0a0a0;
  --line: #2f2f2f;
  --line-strong: #414141;
  --accent: #80ffd4;
  --tc: #ff7b50;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --gutter: 22px;
}

html[data-ui="en"] [data-lang="zh-Hant"],
html[data-ui="zh-Hant"] [data-lang="en"] { display: none !important; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 72px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
  overflow-wrap: anywhere;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 var(--gutter); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Header */
header.site { position: sticky; top: 0; z-index: 10; background: rgba(17, 17, 17, .92); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
header.site .wrap { display: flex; align-items: center; gap: 22px; height: 58px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--strong); font-weight: 700; letter-spacing: .01em; white-space: nowrap; }
.brand small { font-size: 12px; font-weight: 600; letter-spacing: .12em; color: var(--muted); }
nav.links { display: flex; gap: 20px; margin-left: auto; }
nav.links a { color: var(--muted); text-decoration: none; font-size: 14px; }
nav.links a:hover { color: var(--strong); }
.lang { display: flex; border: 1px solid var(--line-strong); }
.lang button { appearance: none; border: 0; background: none; color: var(--muted); font: inherit; font-size: 13px; padding: 4px 9px; cursor: pointer; }
.lang button[aria-pressed="true"] { background: var(--raised); color: var(--strong); }

/* Hero */
.hero { padding: 72px 0 0; }
.eyebrow { margin: 0 0 16px; color: var(--tc); font-size: 14px; font-weight: 600; }
h1 { margin: 0 0 18px; color: var(--strong); font-size: clamp(36px, 6.2vw, 68px); line-height: 1.08; letter-spacing: -.025em; font-weight: 700; max-width: 16em; }
.lead { margin: 0 0 26px; max-width: 42em; font-size: clamp(17px, 2vw, 19px); color: var(--text); }
.cta { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; }
.btn { display: inline-block; padding: 11px 20px; border: 1px solid var(--line-strong); color: var(--strong); text-decoration: none; font-weight: 600; font-size: 15px; text-align: center; cursor: pointer; }
.btn:hover { background: var(--raised); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #000; }
.btn.primary:hover { background: #a6ffe1; }
.btn.off { background: none; border-color: var(--line); color: var(--muted); cursor: default; }
.needs { margin: 0; color: var(--muted); font-size: 14px; }

/* Console illustration */
.console { margin-top: 48px; background: var(--panel); border: 1px solid var(--line-strong); }
.console-bar { padding: 7px 0; text-align: center; background: var(--raised); color: var(--strong); font-size: 14px; }
.console-body { padding: 22px 24px 8px; display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 8px 24px; }
.clock { color: var(--tc); font-size: clamp(42px, 12.2vw, 138px); font-weight: 300; line-height: 1; font-variant-numeric: tabular-nums; letter-spacing: -.01em; white-space: nowrap; }
.next { min-width: 150px; padding-bottom: 8px; }
.next span { display: block; color: var(--muted); font-size: 13px; }
.next b { display: block; color: var(--strong); font: 500 19px/1.35 var(--mono); }
.deck { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; padding: 14px 24px 22px; }
.col { border: 1px solid var(--line-strong); background: #1b1b1b; opacity: .62; transition: opacity .08s linear; }
.col .name { padding: 3px 0; text-align: center; font-size: 13px; background: var(--raised); color: var(--text); }
.col .thumb { aspect-ratio: 16 / 9; }
.col .tag { padding: 4px 2px; text-align: center; font: 500 clamp(9.5px, 1.4vw, 14px)/1.4 var(--mono); color: var(--muted); white-space: nowrap; overflow: hidden; }
.col.live { opacity: 1; border-color: var(--accent); }
.col.live .name { background: var(--accent); color: #000; font-weight: 600; }
.col.live .tag { color: var(--strong); }
.t1 { background: linear-gradient(120deg, #2a1f8f, #4a35d0); }
.t2 { background: linear-gradient(120deg, #8a2346, #d0436a); }
.t3 { background: linear-gradient(120deg, #2f5a8a, #5a93d6); }
.t4 { background: linear-gradient(120deg, #8a6a3c, #dcae68); }
.caption { margin: 8px 0 0; color: var(--muted); font-size: 13px; }

/* Sections */
section.block { padding: 88px 0 0; }
h2 { margin: 0 0 10px; color: var(--strong); font-size: clamp(27px, 3.8vw, 38px); line-height: 1.2; letter-spacing: -.015em; font-weight: 700; }
.sub { margin: 0 0 34px; color: var(--muted); max-width: 44em; }
h3 { margin: 0 0 6px; color: var(--strong); font-size: 18px; font-weight: 600; }

ol.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line-strong); counter-reset: s; }
ol.steps li { counter-increment: s; padding: 18px 26px 0 0; }
ol.steps li::before { content: "0" counter(s); display: block; margin-bottom: 10px; color: var(--tc); font: 500 15px var(--mono); }
ol.steps p { margin: 0; color: var(--muted); }
code { font-family: var(--mono); font-size: .92em; color: var(--strong); }

.feature { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 44px; align-items: center; padding: 36px 0; border-top: 1px solid var(--line); }
.feature:first-of-type { border-top: 0; padding-top: 0; }
.feature img { border: 1px solid var(--line-strong); }
.feature.flip > :first-child { order: 2; }
.feature p { margin: 0 0 10px; color: var(--muted); }
.shots-note { margin: 6px 0 0; color: var(--muted); font-size: 13px; }

ul.rules { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 48px; }
ul.rules li { padding: 14px 0; border-top: 1px solid var(--line); }
ul.rules b { display: block; color: var(--strong); font-weight: 600; }
ul.rules span { color: var(--muted); }

/* Selling points */
.points { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; border-top: 1px solid var(--line-strong); padding-top: 24px; }
.points .big { margin-bottom: 12px; color: var(--tc); font-size: clamp(38px, 4.4vw, 52px); font-weight: 300; line-height: 1.05; font-variant-numeric: tabular-nums; white-space: nowrap; }
.points p { margin: 0; color: var(--muted); }

/* Comparison */
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
table.compare { width: 100%; border-collapse: collapse; table-layout: fixed; }
table.compare th, table.compare td { padding: 13px 18px; border-top: 1px solid var(--line); text-align: left; vertical-align: top; font-size: 15px; font-weight: 400; }
table.compare th:first-child, table.compare td:first-child { padding-left: 0; }
table.compare thead th { border-top: 0; border-bottom: 1px solid var(--line-strong); color: var(--muted); font-weight: 600; }
table.compare tbody th { color: var(--text); font-weight: 600; }
table.compare td { color: var(--muted); }
table.compare .us { background: var(--panel); color: var(--strong); }
table.compare thead .us { color: var(--accent); }

.shots { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 14px; margin-top: 34px; align-items: start; }
.shots img, img.wide { border: 1px solid var(--line-strong); }
img.wide { width: 100%; margin-bottom: 18px; }

/* Pricing */
.plans { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--line-strong); border: 1px solid var(--line-strong); }
.plan { display: flex; flex-direction: column; padding: 22px 20px; background: var(--panel); }
.plan h3 { margin-bottom: 14px; }
.price { color: var(--strong); font-size: 34px; font-weight: 300; line-height: 1.1; font-variant-numeric: tabular-nums; white-space: nowrap; }
.price small { font-size: 15px; color: var(--muted); }
.was { min-height: 22px; margin: 4px 0 14px; color: var(--muted); font-size: 13px; }
.plan ul { flex: 1; margin: 0 0 20px; padding: 0; list-style: none; color: var(--muted); font-size: 15px; }
.plan li { padding: 3px 0; }
.plan .btn { width: 100%; }
.fine { margin: 16px 0 0; color: var(--muted); font-size: 14px; max-width: 58em; }

/* Download and requirements */
.dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: var(--line-strong); border: 1px solid var(--line-strong); }
.dl > div { padding: 20px; background: var(--panel); }
.dl p { margin: 0 0 14px; color: var(--muted); font-size: 15px; }
dl.req { display: grid; grid-template-columns: 170px minmax(0, 1fr); margin: 26px 0 0; }
dl.req dt, dl.req dd { margin: 0; padding: 11px 0; border-top: 1px solid var(--line); }
dl.req dt { color: var(--strong); font-weight: 600; font-size: 15px; }
dl.req dd { color: var(--muted); font-size: 15px; }

/* FAQ */
details { border-top: 1px solid var(--line); }
details:last-of-type { border-bottom: 1px solid var(--line); }
summary { padding: 15px 0; color: var(--strong); font-weight: 600; cursor: pointer; }
details p { margin: 0 0 16px; max-width: 46em; color: var(--muted); }

.todo { color: #000 !important; background: var(--tc); padding: 0 6px; text-decoration: none; }

/* Legal pages */
.legal { padding: 56px 0 0; max-width: 760px; }
.legal h1 { font-size: clamp(30px, 5vw, 42px); margin-bottom: 6px; }
.legal .updated { margin: 0 0 30px; color: var(--muted); font-size: 14px; }
.legal h2 { font-size: 20px; margin: 30px 0 8px; letter-spacing: 0; }
.legal p, .legal li { color: var(--text); }
.legal ul { padding-left: 20px; }

/* Footer */
footer.site { margin-top: 96px; padding: 30px 0 40px; border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }
footer .row { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-bottom: 12px; }
footer a { text-decoration: none; }
footer a:hover { color: var(--strong); }
footer p { margin: 0 0 6px; }

@media (max-width: 960px) {
  .points, .plans { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .feature, .feature.flip { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .feature.flip > :first-child { order: 0; }
}
@media (max-width: 680px) {
  :root { --gutter: 16px; }
  nav.links { display: none; }
  .lang { margin-left: auto; }
  .hero { padding-top: 44px; }
  .console-body { padding: 16px 14px 6px; }
  .deck { padding: 12px 14px 16px; gap: 5px; }
  .col .name { font-size: 11px; }
  ol.steps, ul.rules, .plans, .dl, .shots, .points { grid-template-columns: minmax(0, 1fr); }
  .points { gap: 24px; }
  /* The table reflows: each row label sits above its two values. */
  table.compare, table.compare thead, table.compare tbody { display: block; }
  table.compare tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  table.compare thead th:first-child { display: none; }
  table.compare tbody th { grid-column: 1 / 3; padding: 14px 0 6px; }
  table.compare td { border-top: 0; padding: 8px 10px; font-size: 14px; }
  table.compare td:first-of-type { padding-left: 0; }
  table.compare thead th { padding: 8px 10px; font-size: 14px; }
  table.compare thead th:nth-child(2) { padding-left: 0; }
  ol.steps li { padding-right: 0; padding-bottom: 8px; }
  dl.req { grid-template-columns: minmax(0, 1fr); }
  dl.req dd { border-top: 0; padding-top: 0; }
  section.block { padding-top: 64px; }
}
