:root {
  color-scheme:light;
  --chrome:linear-gradient(#f8f8fa,#ededf0);
  --chrome-ink:#5b5b60;
  --sidebar:#f5f7fa;
  --app-detail:#fff;
  --app-chrome:#f4f4f4;
  --app-muted:#666c75;
  --selected-secondary:#536278;
  --divider:#0000000d;
  --key-surface:linear-gradient(#fff,#f1f2f4);
  /* Keystroke shadows keep the same six layers so presses interpolate smoothly. */
  --key-shadow:inset 0 1px 0 #fff,0 0 0 .5px #0000001c,0 3px 0 #d5d8de,0 4px 3px #0000001c,0 12px 24px -6px #1c273d2e,0 26px 44px -14px #1c273d38;
  --key-pressed:linear-gradient(#ecf3ff,#dce9fc);
  --key-pressed-ink:#175fae;
  --key-pressed-shadow:inset 0 1px 2px #325c8b1a,0 0 0 .5px #2a5a9a29,0 1px 0 #b7c9e0,0 1px 2px #0000001a,0 7px 16px -6px #1c3d6e2e,0 18px 34px -14px #1c3d6e30;
  --kbd-shadow:inset 0 1px 0 #fff,0 0 0 .5px #00000024,0 1.5px 0 #d3d6dc,0 2px 4px -1px #0000002e;
  --receipt:#f6f7f9;
  --receipt-ink:#41464e;
  --scroll-thumb:#97a0ad;
  --file-fill:#f7f8fa;
  --file-stroke:#a8b0bd;
  --file-ink:#68788c;

  --surface:#f5f5f7;
  --paper:#fff;
  --card:#edf0f4;
  --ink:#1d1d1f;
  --muted:#626268;
  --blue:#2e82ff;
  --blue-text:#1268e8;
  --selected:#c9dffd;
  --line:#dce1e8;
  --font:-apple-system,BlinkMacSystemFont,"PingFang SC","Hiragino Sans GB",sans-serif;
  --ease:cubic-bezier(.16,1,.3,1);
  /* QuickPasteList selectionSpring: interactiveSpring(response:.26, dampingFraction:.72), sampled until settled. */
  --spring:linear(0,.0238,.0847,.1697,.268,.3716,.4741,.5714,.6605,.7397,.8082,.866,.9136,.9516,.981,1.003,1.0186,1.029,1.0351,1.038,1.0383,1.0368,1.0341,1.0306,1.0267,1.0227,1.0188,1.0152,1.0119,1.009,1.0065,1.0044,1.0028,1.0014,1.0004,.9996,.9991,.9988,.9986,.9985,.9985,.9986,.9987,.9989,.999,.9992,.9993,.9995,1);
  --spring-duration:.46s;
  --shadow:0 2px 5px #00000018,0 18px 38px -14px #18202c50;
  --window-shadow:0 1px 3px #00000020,0 14px 32px -16px #1c273d40;
  --content:1320px;
}

:root[data-theme="dark"] {
  color-scheme:dark;
  --surface:#141518;
  --paper:#191a1d;
  --card:#2d3239;
  --ink:#f3f3f5;
  --muted:#b0b4bd;
  --blue:#69a8ff;
  --blue-text:#91bcff;
  --selected:#24466f;
  --selected-secondary:#b0b7c1;
  --line:#35383f;
  --chrome:linear-gradient(#2c2e33,#24262b);
  --chrome-ink:#d4d6dd;
  --sidebar:#202328;
  --app-detail:#202328;
  --app-chrome:#202328;
  --app-muted:#b0b7c1;
  --divider:#ffffff12;
  --shadow:0 0 0 1px #ffffff16,0 2px 5px #00000050,0 18px 38px -14px #000000bb;
  --window-shadow:0 0 0 1px #ffffff14,0 2px 4px #00000045,0 14px 32px -16px #000000bb;
  --key-surface:linear-gradient(#3d4047,#2e3036);
  --key-shadow:inset 0 1px 0 #ffffff1c,0 0 0 .5px #ffffff12,0 3px 0 #1b1d22,0 4px 3px #00000080,0 12px 26px -6px #0000009c,0 26px 46px -14px #000000b0;
  --key-pressed:linear-gradient(#294a71,#233d5b);
  --key-pressed-ink:#c2dcff;
  --key-pressed-shadow:inset 0 1px 2px #00000030,0 0 0 .5px #7fb2ff26,0 1px 0 #152b45,0 1px 2px #00000070,0 7px 18px -6px #00000090,0 18px 34px -14px #000000a0;
  --kbd-shadow:inset 0 1px 0 #ffffff17,0 0 0 .5px #ffffff12,0 1.5px 0 #1b1d22,0 2px 4px -1px #00000080;
  --receipt:#303339;
  --receipt-ink:#d6dbe4;
  --scroll-thumb:#757e8d;
  --file-fill:#2d3239;
  --file-stroke:#939dab;
  --file-ink:#b0bfd2;
}

@media(prefers-color-scheme:dark) {
  :root:not([data-theme]) {
  color-scheme:dark;
  --surface:#141518;
  --paper:#191a1d;
  --card:#2d3239;
  --ink:#f3f3f5;
  --muted:#b0b4bd;
  --blue:#69a8ff;
  --blue-text:#91bcff;
  --selected:#24466f;
  --selected-secondary:#b0b7c1;
  --line:#35383f;
  --chrome:linear-gradient(#2c2e33,#24262b);
  --chrome-ink:#d4d6dd;
  --sidebar:#202328;
  --app-detail:#202328;
  --app-chrome:#202328;
  --app-muted:#b0b7c1;
  --divider:#ffffff12;
  --shadow:0 0 0 1px #ffffff16,0 2px 5px #00000050,0 18px 38px -14px #000000bb;
  --window-shadow:0 0 0 1px #ffffff14,0 2px 4px #00000045,0 14px 32px -16px #000000bb;
  --key-surface:linear-gradient(#3d4047,#2e3036);
  --key-shadow:inset 0 1px 0 #ffffff1c,0 0 0 .5px #ffffff12,0 3px 0 #1b1d22,0 4px 3px #00000080,0 12px 26px -6px #0000009c,0 26px 46px -14px #000000b0;
  --key-pressed:linear-gradient(#294a71,#233d5b);
  --key-pressed-ink:#c2dcff;
  --key-pressed-shadow:inset 0 1px 2px #00000030,0 0 0 .5px #7fb2ff26,0 1px 0 #152b45,0 1px 2px #00000070,0 7px 18px -6px #00000090,0 18px 34px -14px #000000a0;
  --kbd-shadow:inset 0 1px 0 #ffffff17,0 0 0 .5px #ffffff12,0 1.5px 0 #1b1d22,0 2px 4px -1px #00000080;
  --receipt:#303339;
  --receipt-ink:#d6dbe4;
  --scroll-thumb:#757e8d;
  --file-fill:#2d3239;
  --file-stroke:#939dab;
  --file-ink:#b0bfd2;
  }
}

* {
  box-sizing:border-box;
}

[hidden] {
  display:none!important;
}

html {
  scroll-behavior:smooth;
  scroll-padding-top:100px;
}

body {
  margin:0;
  color:var(--ink);
  background:var(--surface);
  font-family:var(--font);
  font-weight:400;
  font-synthesis:none;
}

summary {
  font:inherit;
}

a,summary {
  -webkit-tap-highlight-color:transparent;
}

a {
  color:inherit;
  text-decoration:none;
}

a:focus-visible,summary:focus-visible {
  outline:none;
  background-color:var(--app-selected, var(--selected));
  text-decoration:underline;
  text-underline-offset:.2em;
}

summary {
  touch-action:manipulation;
}

img {
  display:block;
  max-width:100%;
  height:auto;
}

svg.icon {
  width:20px;
  height:20px;
  flex:none;
  fill:none;
  stroke:currentColor;
  stroke-width:1.65;
  stroke-linecap:round;
  stroke-linejoin:round;
}

.svg-library {
  width:0;
  height:0;
  position:absolute;
  overflow:hidden;
}

.skip-link {
  position:fixed;
  left:16px;
  top:-80px;
  padding:12px 20px;
  background:var(--paper);
  z-index:100;
}

.skip-link:focus {
  top:16px;
}

.site-header {
  height:80px;
  position:absolute;
  inset:0 0 auto;
  z-index:20;
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:0 4.5%;
  gap:20px;
}

.brand {
  display:inline-flex;
  align-items:center;
  gap:10px;
  font-size:22px;
  font-weight:600;
  letter-spacing:-.035em;
  white-space:nowrap;
}

.brand-symbol {
  width:30px;
  height:30px;
  object-fit:contain;
  border-radius:22%;
}

.hero {
  /* One unit is one native point: the demo stays at the real panel size until the first screen runs out of room. */
  --u:clamp(.62px,min(calc((100svh - 160px) / 750),calc(49vw / 700)),1px);
  --popup-left:calc(150 * var(--u));
  --hud-x:calc(380 * var(--u));
  height:100svh;
  min-height:640px;
  max-height:1080px;
  position:relative;
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  column-gap:clamp(40px,4.5vw,88px);
  align-items:center;
  padding:100px max(5%,calc((100vw - 1360px) / 2)) 56px;
  overflow:clip;
  isolation:isolate;
  background:var(--paper);
}

.hero-copy {
  z-index:2;
  max-width:580px;
  padding-bottom:8px;
}

h1,h2,h3,p {
  margin:0;
}

h1 {
  font-size:clamp(42px,4.6vw,76px);
  font-weight:600;
  line-height:1.2;
  letter-spacing:-.035em;
  text-wrap:balance;
}

h1 span {
  color:var(--ink);
}

.hero-description {
  margin-top:28px;
  max-width:26em;
  color:var(--muted);
  font-size:20px;
  line-height:1.75;
  text-wrap:pretty;
}

.hero-demo {
  width:calc(700 * var(--u));
  min-width:0;
}

.hero-shortcut {
  position:relative;
  left:var(--hud-x);
  width:max-content;
  max-width:100%;
  margin:12px 0 0;
  transform:translateX(-50%);
  text-align:center;
  text-wrap:balance;
  color:var(--muted);
  font-size:15px;
  line-height:2.1;
}

.hero-shortcut kbd {
  display:inline-grid;
  place-items:center;
  min-width:26px;
  height:26px;
  margin:0 2px;
  padding:0 7px;
  border-radius:6px;
  background:var(--key-surface);
  box-shadow:var(--kbd-shadow);
  color:var(--ink);
  font:500 13px/1 var(--font);
  vertical-align:1px;
}

.hero-download {
  margin-top:44px;
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  gap:14px;
}

.download-button {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  min-height:58px;
  padding:0 32px 0 26px;
  border-radius:999px;
  background:#0071e3;
  color:#fff;
  font-size:18px;
  font-weight:500;
  line-height:1.2;
  box-shadow:0 1px 2px #0040801f,0 12px 26px -12px #0071e3b3;
  transition:background .2s,transform .2s var(--ease),box-shadow .2s;
}

.download-button .icon {
  width:22px;
  height:22px;
  stroke-width:1.9;
}

.download-button:hover {
  background:#0077ed;
  transform:translateY(-1px);
  box-shadow:0 1px 2px #0040801f,0 16px 30px -12px #0071e3c4;
}
.download-button:active { transform:none; }
.download-button:focus-visible { outline:3px solid var(--blue-text); outline-offset:4px; }
.download-button[aria-busy="true"] { cursor:progress; }

.hero-download p {
  color:var(--muted);
  font-size:13px;
  line-height:1.6;
}

/* The stage is drawn in native points (--u), so the whole scene scales as one piece. */
.demo-stage {
  position:relative;
  width:calc(700 * var(--u));
  height:calc(690 * var(--u));
  isolation:isolate;
  pointer-events:none;
  user-select:none;
  scroll-margin-top:110px;
}

.writing-window {
  position:absolute;
  left:0;
  right:0;
  top:calc(56 * var(--u));
  height:calc(614 * var(--u));
  border-radius:max(10px,calc(12 * var(--u)));
  background:var(--paper);
  box-shadow:var(--window-shadow);
  overflow:hidden;
}

.window-topline {
  height:calc(44 * var(--u));
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:0 calc(18 * var(--u));
  color:var(--chrome-ink);
  font-size:max(11px,calc(12 * var(--u)));
  border-bottom:1px solid var(--divider);
  background:var(--chrome);
}

.traffic-lights {
  display:inline-flex;
  align-items:center;
  gap:6px;
}

.traffic-lights i {
  display:block;
  width:9px;
  height:9px;
  border-radius:50%;
  background:#d3dae3;
  box-shadow:inset 0 0 0 .5px #00000026;
}

.traffic-lights i:first-child {
  background:#ff5f57;
}

.traffic-lights i:nth-child(2) {
  background:#febc2e;
}

.traffic-lights i:nth-child(3) {
  background:#28c840;
}

.writing-window .traffic-lights { gap:calc(8 * var(--u)); }
.writing-window .traffic-lights i { width:calc(12 * var(--u)); height:calc(12 * var(--u)); }

.writing-content {
  padding:calc(40 * var(--u)) calc(44 * var(--u));
}

.writing-content h2 {
  font-size:calc(26 * var(--u));
  font-weight:600;
  line-height:1.4;
}

.writing-content>p {
  margin-top:calc(16 * var(--u));
  color:var(--muted);
  font-size:max(12px,calc(15 * var(--u)));
  line-height:1.9;
}

.pasted-content {
  margin-top:calc(22 * var(--u));
  min-height:calc(32 * var(--u));
  display:flex;
  align-items:center;
  gap:calc(6 * var(--u));
  color:var(--ink);
  font-size:max(13px,calc(17 * var(--u)));
  line-height:1.6;
  overflow-wrap:anywhere;
}

.pasted-content img {
  width:calc(300 * var(--u));
  max-height:calc(210 * var(--u));
  object-fit:contain;
  object-position:left;
  border-radius:calc(6 * var(--u));
}

.caret {
  display:inline-block;
  flex:none;
  width:2px;
  height:1.35em;
  background:var(--blue);
  animation:blink 1s steps(1) infinite;
}

/* Matches QuickPastePanelController: 460 wide, 44/40 header and footer, 88/180 rows. */
.quick-popup {
  position:absolute;
  left:var(--popup-left);
  top:0;
  width:calc(460 * var(--u));
  border-radius:calc(18 * var(--u));
  background:var(--sidebar);
  box-shadow:var(--shadow);
  transition:transform .22s ease-out,opacity .18s ease-out;
  z-index:3;
}

.popup-heading,.popup-footer {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  padding:0 calc(20 * var(--u));
  color:var(--muted);
  font-size:max(11px,calc(11 * var(--u)));
  white-space:nowrap;
}

.popup-heading {
  height:calc(44 * var(--u));
}

.popup-heading span:last-child {
  font-variant-numeric:tabular-nums;
}

.popup-footer {
  height:calc(40 * var(--u));
}

/* Three layers like QuickPasteList: card fills, one sliding highlight, then row content. */
.quick-list {
  position:relative;
  isolation:isolate;
  display:flex;
  flex-direction:column;
  gap:calc(6 * var(--u));
  max-height:calc(474 * var(--u));
  padding:calc(6 * var(--u)) calc(16 * var(--u));
  overflow-y:auto;
  scrollbar-width:none;
}

.quick-highlight {
  --row-y:0;
  --row-height:88;
  position:absolute;
  top:calc(6 * var(--u));
  left:calc(16 * var(--u));
  right:calc(16 * var(--u));
  z-index:-1;
  height:calc(var(--row-height) * var(--u));
  border-radius:calc(12 * var(--u));
  background:var(--selected);
  transform:translateY(calc(var(--row-y) * var(--u)));
  transition:transform var(--spring-duration) var(--spring),height var(--spring-duration) var(--spring);
}

/* Wrapping to the other end of the list snaps, as in the app. */
.quick-highlight.snap {
  transition:none;
}

.quick-item {
  position:relative;
  flex:none;
  width:100%;
  height:calc(88 * var(--u));
  border-radius:calc(12 * var(--u));
  font-size:max(12px,calc(14 * var(--u)));
  line-height:1.45;
  overflow-wrap:anywhere;
}

.quick-item::before {
  content:"";
  position:absolute;
  inset:0;
  z-index:-2;
  border-radius:inherit;
  background:var(--card);
}

.quick-item::before,
.quick-content {
  transform:scale(.94);
  transition:transform var(--spring-duration) var(--spring);
}

.quick-item.selected::before,
.quick-item.selected .quick-content {
  transform:none;
}

.quick-content {
  display:flex;
  align-items:center;
  width:100%;
  height:100%;
  padding:0 calc(12 * var(--u));
}

.quick-item.quick-image {
  height:calc(180 * var(--u));
}

.quick-image .quick-content {
  justify-content:center;
  padding:calc(9 * var(--u)) calc(12 * var(--u));
}

.quick-image img {
  max-width:100%;
  height:100%;
  width:auto;
  object-fit:contain;
  border-radius:calc(6 * var(--u));
}

.sample-link {
  text-decoration:underline;
  text-underline-offset:3px;
  overflow-wrap:anywhere;
}

.paste-receipt {
  position:absolute;
  right:calc(28 * var(--u));
  top:calc(124 * var(--u));
  display:flex;
  align-items:center;
  gap:8px;
  background:var(--receipt);
  color:var(--receipt-ink);
  border-radius:9px;
  padding:8px 12px;
  font-size:12px;
  box-shadow:0 2px 7px #00000018;
  opacity:0;
  transform:translateY(3px);
  transition:opacity .18s ease-out,transform .18s ease-out;
  z-index:4;
}

.paste-receipt .icon {
  width:16px;
  height:16px;
}

/* Keystrokes float below the panel and only appear while the shortcut is in use. */
.key-hud {
  position:absolute;
  left:var(--hud-x);
  top:calc(590 * var(--u));
  z-index:5;
  display:flex;
  align-items:center;
  gap:calc(12 * var(--u));
  opacity:0;
  transform:translate(-50%,calc(12 * var(--u))) scale(.97);
  transition:opacity .26s ease-out,transform .4s var(--ease);
}

.key-hud.visible {
  opacity:1;
  transform:translate(-50%,0);
}

.keycap {
  width:calc(58 * var(--u));
  height:calc(58 * var(--u));
  display:grid;
  place-items:center;
  border-radius:calc(12 * var(--u));
  background:var(--key-surface);
  box-shadow:var(--key-shadow);
  color:var(--ink);
  transition:transform .16s ease-out,box-shadow .16s ease-out,color .16s ease-out,opacity .22s ease-out;
}

.keycap.pressed {
  background:var(--key-pressed);
  color:var(--key-pressed-ink);
  transform:translateY(calc(3 * var(--u)));
  box-shadow:var(--key-pressed-shadow);
}

.key-symbol {
  font-size:calc(24 * var(--u));
  font-weight:500;
  line-height:1;
}

.key-join {
  color:var(--muted);
  font-size:calc(20 * var(--u));
  transition:opacity .22s ease-out;
}

.key-hud:not(.chord) .key-join,
.key-hud:not(.chord) .letter-key {
  opacity:0;
}

.key-hud:not(.chord) .letter-key {
  transform:translateY(calc(6 * var(--u))) scale(.94);
}

.demo-stage[data-phase="pasted"] .quick-popup {
  transform:translateY(-3px) scale(.99);
  opacity:0;
}

.demo-stage[data-phase="pasted"] .paste-receipt {
  opacity:1;
  transform:translateY(0);
}

.demo-stage[data-phase="armed"] .quick-popup {
  opacity:0;
  transform:translateY(5px) scale(.99);
}

.history-story {
  height:auto;
  min-height:0;
  position:relative;
  background:var(--surface);
  --progress:0;
}

.history-sticky {
  position:relative;
  top:0;
  height:auto;
  min-height:0;
  max-height:none;
  padding:112px 5% 120px;
  overflow:clip;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:48px;
}

.history-heading {
  width:100%;
  max-width:1100px;
  display:block;
  justify-content:space-between;
  align-items:flex-end;
  padding:0;
  gap:40px;
  text-align:center;
}

.history-heading h2 {
  font-size:clamp(32px,3.5vw,50px);
  font-weight:600;
  line-height:1.22;
  letter-spacing:-.035em;
}
.history-heading p {
  font-size:17px;
  line-height:1.8;
  color:var(--muted);
  margin-top:18px;
}

.history-window {
  pointer-events:none;
  user-select:none;
  position:relative;
  --app-surface:var(--sidebar);
  --app-paper:var(--app-detail);
  --app-card:var(--card);
  --app-ink:var(--ink);
  --app-secondary:var(--app-muted);
  --app-selected:var(--selected);
  --app-selected-secondary:var(--selected-secondary);
  width:min(100%,1100px);
  height:auto;
  aspect-ratio:4 / 3;
  min-height:390px;
  flex:none;
  border-radius:12px;
  background:var(--app-paper);
  color:var(--app-ink);
  box-shadow:var(--window-shadow);
  overflow:hidden;
  transform:none;
  transform-origin:center;
  transition:background .3s,color .3s;
}

.history-cursor {
  position:absolute;
  top:0;
  left:0;
  width:28px;
  height:34px;
  pointer-events:none;
  z-index:5;
  opacity:0;
  transition:transform .7s var(--ease),opacity .2s;
}

.history-cursor.visible { opacity:1; }
.history-cursor svg {
  position:relative;
  width:100%;
  height:100%;
  fill:#202328;
  stroke:#fff;
  stroke-width:1.8;
  stroke-linejoin:round;
  filter:drop-shadow(0 2px 3px #0003);
  transform-origin:3px 2px;
  transition:transform .12s;
}
.history-cursor.clicking svg { transform:scale(.85); }

@media (prefers-reduced-motion:reduce) {
  .history-cursor { display:none; }
}

.app-titlebar {
  height:32px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:0 15px;
  background:var(--app-chrome);
  font-size:12px;
  font-weight:500;
}

.app-titlebar>.traffic-lights {
  width:58px;
}

.app-body {
  height:calc(100% - 32px);
  display:grid;
  grid-template-columns:39% 61%;
  background:var(--app-chrome);
}

.app-sidebar {
  background:var(--app-surface);
  padding:10px 8px;
  margin:0 0 8px 8px;
  border-radius:12px;
  overflow:auto;
  scrollbar-width:thin;
}

.sidebar-title {
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin:0 8px 8px;
  min-height:30px;
}

.sidebar-title strong {
  font-size:16px;
  font-weight:500;
}

.sidebar-actions { display:flex; align-items:center; gap:20px; }
.sidebar-actions .icon { width:18px; height:18px; }
.source-app-icon { width:14px; height:14px; flex:none; object-fit:contain; }
.source-label { display:inline-flex; align-items:center; gap:5px; white-space:nowrap; }

.demo-search {
  color:var(--app-secondary);
  margin:0 8px;
  font-size:13px;
  height:36px;
  display:flex;
  align-items:center;
  gap:9px;
  background:var(--app-card);
  padding:0 12px;
  border-radius:9px;
}

.demo-search>.icon {
  color:var(--app-secondary);
  width:16px;
}

.filter-bar {
  display:flex;
  align-items:center;
  justify-content:space-between;
  font-size:11px;
  color:var(--app-secondary);
  margin:8px 8px 7px;
}

.filter-bar>span:first-child {
  background:var(--app-card);
  border-radius:20px;
  padding:5px 12px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  width:116px;
  height:28px;
  color:var(--app-ink);
}

.filter-bar .icon { width:12px; height:12px; }

.history-items {
  display:flex;
  flex-direction:column;
  gap:7px;
}

.history-item {
  border:0;
  text-align:left;
  border-radius:12px;
  background:var(--app-card);
  color:var(--app-ink);
  padding:22px 12px 8px;
  display:flex;
  flex-direction:column;
  gap:12px;
  width:100%;
  flex:none;
  transition:background .2s;
}

.history-item.selected {
  background:var(--app-selected);
}

.item-title {
  font-size:13.5px;
  line-height:1.5;
  overflow-wrap:anywhere;
}

.item-meta {
  display:flex;
  justify-content:space-between;
  font-size:11px;
  color:var(--app-secondary);
  gap:5px;
}

.history-item.selected .item-meta {
  color:var(--app-selected-secondary);
}

.item-meta>span {
  display:flex;
  align-items:center;
  gap:5px;
}

.item-meta .icon {
  height:12px;
  width:12px;
}

.history-image > img {
  height:132px;
  width:100%;
  object-fit:contain;
}

.history-image {
  gap:6px;
  padding-top:18px;
}

.app-detail {
  background:var(--app-paper);
  display:flex;
  flex-direction:column;
  min-width:0;
  min-height:0;
}

.detail-meta {
  padding:20px 20px 12px;
  display:flex;
  justify-content:flex-end;
  gap:9px;
  font-size:12px;
  color:var(--app-secondary);
  align-items:center;
}

.detail-canvas {
  flex:1;
  min-height:0;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:15px 30px;
  overflow:auto;
}

.preview-text {
  font-size:14px;
  font-weight:400;
  line-height:1.6;
  letter-spacing:-.025em;
}

.preview-link {
  font-size:14px;
  text-decoration:underline;
  text-underline-offset:5px;
  overflow-wrap:anywhere;
  color:var(--app-ink);
}

.detail-canvas>img {
  height:100%;
  width:100%;
  object-fit:contain;
  border-radius:5px;
}

.detail-toolbar {
  display:flex;
  justify-content:flex-end;
  align-items:center;
  padding:10px 16px;
  border-top:1px solid var(--app-card);
  font-size:11px;
  color:var(--app-secondary);
}

.reading-section {
  padding:112px 5% 120px;
  background:var(--paper);
}

.reading-heading {
  display:block;
  align-items:flex-end;
  justify-content:space-between;
  gap:32px;
  max-width:1100px;
  margin:0 auto 56px;
  text-align:center;
}

.reading-heading h2 {
  font-size:clamp(32px,3.5vw,50px);
  font-weight:600;
  line-height:1.25;
  letter-spacing:-.035em;
}

.reading-grid {
  display:grid;
  grid-template-columns:1.15fr 1fr;
  gap:28px;
  max-width:1100px;
  margin:auto;
}

.reading-example {
  margin:0;
  min-width:0;
}

.reading-window {
  background:var(--app-detail);
  border-radius:12px;
  overflow:hidden;
  box-shadow:var(--window-shadow);
}

.reading-titlebar {
  height:32px;
  padding:0 16px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  background:var(--app-chrome);
  font-size:12px;
  font-weight:500;
}

.reading-meta {
  display:flex;
  justify-content:flex-end;
  align-items:center;
  gap:9px;
  padding:20px 20px 12px;
  font-size:11px;
  line-height:1.5;
  color:var(--muted);
}

.reading-body {
  height:490px;
  position:relative;
  min-width:0;
}

.reading-text-scroll {
  height:100%;
  overflow-y:auto;
  overflow-x:hidden;
  scrollbar-width:none;
  scroll-behavior:auto;
  overflow-anchor:none;
  border-radius:2px;
}

.reading-text-scroll::-webkit-scrollbar {
  display:none;
}

.reading-text-scroll:focus-visible {
  outline:none;
  background:var(--selected);
}

.reading-document {
  max-width:65ch;
  margin:auto;
  padding:8px 32px 28px;
  font-size:14px;
  line-height:1.65;
  overflow-wrap:anywhere;
}

.reading-document p+p {
  margin-top:22px;
}

.reading-scroll-track {
  position:absolute;
  top:10px;
  right:7px;
  bottom:10px;
  width:5px;
  border-radius:4px;
  background:var(--card);
  pointer-events:none;
}

.reading-scroll-track span {
  display:block;
  width:100%;
  min-height:28px;
  height:24%;
  background:var(--scroll-thumb);
  border-radius:4px;
}

.reading-image-canvas {
  display:flex;
  align-items:center;
  justify-content:center;
  padding:8px 28px 22px;
}

.reading-image-canvas img {
  width:100%;
  height:100%;
  object-fit:contain;
  object-position:center;
}

.reading-footer {
  height:63px;
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:12px;
  padding:10px 16px;
  border-top:1px solid var(--card);
  color:var(--muted);
  font-size:11px;
}

.reading-copy {
  display:inline-flex;
  align-items:center;
  gap:7px;
  padding:0 16px;
  height:42px;
  border-radius:24px;
  background:var(--selected);
  color:var(--ink);
  font-size:15px;
}

.reading-copy .icon {
  width:24px;
  height:24px;
}

.local-section {
  min-height:0;
  position:relative;
  display:block;
  grid-template-columns:1fr 1fr;
  align-items:center;
  padding:120px 6%;
  gap:70px;
  background:var(--surface);
  color:var(--ink);
  overflow:clip;
  text-align:center;
}

.local-copy h2 {
  font-size:clamp(32px,3.5vw,50px);
  font-weight:600;
  line-height:1.27;
  letter-spacing:-.035em;
}
.local-copy p {
  font-size:17px;
  line-height:1.9;
  color:var(--muted);
  margin-top:20px;
}

.questions {
  display:grid;
  grid-template-columns:1fr 1.6fr;
  max-width:var(--content);
  margin:auto;
  padding:100px 8%;
  gap:70px;
  background:var(--paper);
}

.questions h2 {
  font-size:34px;
  font-weight:600;
  letter-spacing:-.035em;
}

.question-list details {
  border-bottom:1px solid var(--line);
}

.question-list details:first-child {
  border-top:1px solid var(--line);
}

.question-list summary {
  list-style:none;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:20px;
  cursor:pointer;
  padding:24px 0;
  font-size:15px;
}

.question-list summary::-webkit-details-marker {
  display:none;
}

.question-list summary>.icon {
  width:17px;
  height:17px;
  color:var(--muted);
  transition:transform .3s;
}

.question-list details[open] summary>.icon {
  transform:rotate(180deg);
}

.question-list details p {
  font-size:14px;
  line-height:1.9;
  color:var(--muted);
  padding:0 30px 25px 0;
  max-width:65ch;
}

.site-footer {
  margin:0 4.5%;
  padding:28px 0 35px;
  border-top:1px solid var(--line);
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:20px;
}

.site-footer>.brand {
  font-size:18px;
}

.site-footer>.brand .brand-symbol {
  width:23px;
  height:23px;
}

.site-footer>a:last-child {
  font-size:11px;
  color:var(--muted);
}

.site-footer>a:last-child {
  display:flex;
  align-items:center;
  gap:8px;
}

.site-footer>a:last-child>.icon {
  transform:rotate(180deg);
  width:13px;
  height:13px;
}

.noscript-note {
  padding:20px;
  background:var(--paper);
  color:var(--ink);
  font-size:14px;
  text-align:center;
}

@keyframes blink {
  50% {
    opacity:0;
  }
}

@keyframes keytap {
  0%,100% {
    transform:translateY(0);
  }
  30%,55% {
    transform:translateY(calc(3 * var(--u)));
    background:var(--key-pressed);
    color:var(--key-pressed-ink);
    box-shadow:var(--key-pressed-shadow);
  }
}

@keyframes keyswap {
  from {
    opacity:.15;
    transform:translateY(calc(-4 * var(--u)));
  }
}

@keyframes inserted {
  from {
    opacity:0;
    transform:translateY(2px);
    filter:none;
  }
  to {
    opacity:1;
    transform:translateY(0);
    filter:none;
  }
}

.letter-key.tapping {
  animation:keytap .32s var(--ease);
}

.letter-key.swapped .key-symbol {
  animation:keyswap .24s var(--ease);
}

.pasted-content.inserted {
  animation:inserted .22s var(--ease);
}

@media(max-width:1100px) {
  .history-heading {
    gap:20px;
  }
  .history-heading p {
    font-size:12px;
  }
  .history-heading h2 {
    font-size:32px;
  }
  .questions {
    gap:50px;
    padding-left:7%;
    padding-right:7%;
  }
}

@media(max-width:760px) {
  html {
    scroll-padding-top:30px;
  }
  .site-header {
    height:74px;
    padding:0 6%;
  }
  .brand {
    font-size:20px;
    gap:8px;
  }
  .brand-symbol {
    width:27px;
    height:27px;
  }
  .history-heading {
    padding:0 3px;
    display:block;
  }
  .history-heading h2 {
    font-size:32px;
  }
  .history-heading p {
    font-size:12px;
    margin-top:13px;
    line-height:1.7;
  }
  .history-heading p br {
    display:none;
  }
  .app-titlebar {
    height:34px;
  }
  .app-body {
    height:calc(100% - 34px);
    grid-template-columns:1fr;
    grid-template-rows:159px minmax(0,1fr);
  }
  .app-sidebar {
    padding:10px 12px;
    overflow:hidden;
  }
  .sidebar-title {
    display:none;
  }
  .sidebar-title strong {
    font-size:12px;
  }

  .demo-search {
    padding:0 10px;
    height:32px;
    gap:8px;
    border-radius:7px;
  }
  .demo-search>.icon {
    width:12px;
  }
  .filter-bar {
    display:none;
  }
  .filter-bar>span:first-child {
    padding:4px 7px;
  }
  .filter-bar>span:last-child {
    display:none;
  }
  .history-items {
    flex-direction:row;
    gap:8px;
    margin-top:10px;
    height:97px;
    overflow-x:auto;
    scrollbar-width:thin;
  }
  .history-item {
    padding:10px;
    gap:8px;
    border-radius:8px;
    width:148px;
    height:85px;
    justify-content:space-between;
  }
  .item-title {
    font-size:12px;
    line-height:1.45;
    overflow:hidden;
    display:-webkit-box;
    -webkit-line-clamp:2;
    -webkit-box-orient:vertical;
  }
  .item-meta {
    font-size:11px;
  }
  .item-meta>span:last-child {
    display:none;
  }
  .item-meta>span:first-child {
    gap:4px;
  }
  .item-meta .icon {
    width:10px;
    height:10px;
  }
  .history-image > img {
    height:40px;
  }
  .detail-meta {
    padding:12px 16px;
    gap:12px;
    font-size:11px;
  }
  .detail-canvas {
    padding:10px 18px;
  }

  .preview-link {
    font-size:13px;
    line-height:1.8;
  }
  .detail-toolbar {
    padding:12px;
    justify-content:flex-end;
  }

  .local-copy {
    order:1;
    padding-top:30px;
  }
  .local-copy h2 {
    font-size:40px;
  }
  .local-copy p {
    font-size:13px;
    margin-top:23px;
  }

  .questions {
    grid-template-columns:1fr;
    padding:90px 8%;
    gap:32px;
  }
  .questions h2 {
    font-size:30px;
  }
  .question-list summary {
    font-size:13px;
    padding:22px 0;
  }
  .question-list details p {
    font-size:12px;
    padding-right:10px;
  }
  .site-footer {
    margin:0 6%;
    padding:24px 0 30px;
    flex-wrap:wrap;
    row-gap:20px;
  }
  .site-footer>.brand {
    font-size:17px;
  }
  .site-footer>a:last-child {
    font-size:11px;
  }
}

@media(max-width:370px) {
  .history-heading h2 {
    font-size:28px;
  }

  .local-copy h2 {
    font-size:35px;
  }
}

@media(prefers-reduced-motion:reduce) {
  html {
    scroll-behavior:auto;
  }
  *,*::before,*::after {
    animation:none!important;
    transition:none!important;
  }
  .caret {
    opacity:1;
  }
  .quick-item::before,
  .quick-content {
    transform:none;
  }
}

@media(max-width:900px) {
  .reading-section { padding:85px 7%; }
  .reading-heading { display:block; margin-bottom:34px; }

  .reading-grid { grid-template-columns:1fr; gap:42px; max-width:620px; }
  .reading-heading { max-width:620px; }
}

@media(max-width:760px) {
  .reading-section { padding:80px 6%; }
  .reading-heading h2 { font-size:34px; }

  .reading-meta { padding:17px 16px 13px; font-size:11px; }
  .reading-body { height:410px; }
  .reading-document { padding:8px 22px 24px; font-size:14px; }
  .reading-document p+p { margin-top:20px; }
  .reading-image-canvas { padding:6px 20px 20px; }
}

::selection { background:var(--selected); color:var(--ink); }
@media(max-width:760px) {
  .history-sticky { padding:72px 5%; gap:32px; }
  .history-window { aspect-ratio:auto; height:540px; min-height:0; transform:none; }
  .history-heading p { font-size:15px; }
  .reading-section { padding:72px 5%; }
  .reading-heading { margin-bottom:32px; }
  .local-section { padding:80px 6%; }
  .local-copy p { font-size:15px; }
}

.window-topline, .reading-titlebar, .app-titlebar {
  display:grid;
  grid-template-columns:1fr auto 1fr;
}
.window-topline > span:last-child, .reading-titlebar > span:last-child, .app-titlebar > span:last-child { grid-column:2; }

/* Product details share the native app's quiet hierarchy. */
#detail-date { white-space:nowrap; }
.preview-file { display:flex; align-items:flex-start; gap:12px; max-width:100%; text-align:left; }
.preview-file > div { min-width:0; }
.file-document { width:32px; height:32px; flex:none; margin:0; fill:var(--file-fill); stroke:var(--file-stroke); stroke-width:1.2; stroke-linejoin:round; }
.preview-file p { font-size:14px; font-weight:500; }
.preview-file span { display:block; overflow-wrap:anywhere; margin-top:6px; color:var(--app-muted); font-size:12px; }
@media(max-width:760px) {
  .detail-toolbar { justify-content:flex-end; }
  .detail-meta { gap:7px; }
}

.header-controls { display:flex; align-items:center; gap:30px; }
.appearance-control {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:44px;
  height:44px;
  padding:0;
  color:var(--muted);
  background:transparent;
  border:0;
  border-radius:50%;
  cursor:pointer;
  touch-action:manipulation;
}
.appearance-control .icon { width:20px; height:20px; }
.appearance-control:hover { color:var(--ink); background:var(--card); }
.appearance-control:focus-visible { outline:2px solid var(--blue-text); outline-offset:2px; }
@media(max-width:760px) {
  .header-controls { gap:0; }
}

/* Below two comfortable columns, the copy sits above a centered demo that scales with width. */
@media(max-width:1079px) {
  .hero {
    --u:clamp(.6px,calc((100vw - 64px) / 470),1px);
    --popup-left:calc(50% - 230 * var(--u));
    --hud-x:50%;
    height:auto;
    min-height:0;
    max-height:none;
    grid-template-columns:minmax(0,1fr);
    justify-items:center;
    row-gap:64px;
    padding:136px 6% 80px;
  }
  .hero-copy {
    max-width:640px;
    text-align:center;
  }
  .hero-description {
    margin-left:auto;
    margin-right:auto;
    text-wrap:balance;
  }
  .hero-download {
    align-items:center;
  }
  .hero-demo {
    width:min(100%,calc(700 * var(--u)));
  }
  .demo-stage {
    width:100%;
  }
}

@media(max-width:760px) {
  .hero {
    row-gap:44px;
    padding:120px 6% 64px;
  }
  .hero-copy h1 {
    font-size:clamp(37px,8.5vw,58px);
    line-height:1.24;
  }
  .hero-description {
    margin-top:20px;
    font-size:16px;
    line-height:1.8;
  }
  .hero-shortcut {
    font-size:14px;
  }
  .hero-download {
    margin-top:32px;
  }
  .download-button {
    min-height:54px;
    font-size:17px;
  }
  .demo-stage {
    scroll-margin-top:30px;
  }
}

@media(max-width:370px) {
  .hero {
    padding-top:110px;
  }
  .hero-copy h1 {
    font-size:35px;
  }
  .hero-description {
    font-size:15px;
  }
}
