/* Pretty Keys landing page. Keycap metrics, colors and roles come from the app's KeycapView.swift, Palette.swift and Preferences.swift. Sizes are in points at medium, multiplied by --u. */

/* Optional, with a preload in each page's head: the text never swaps after first paint, so a late font can't move the page. */
@font-face {
  font-family: "Newsreader";
  src: url("/pretty-keys/assets/newsreader.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: optional;
}
@font-face {
  font-family: "Newsreader";
  src: url("/pretty-keys/assets/newsreader-italic.woff2") format("woff2");
  font-weight: 200 800;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Fragment Mono";
  src: url("/pretty-keys/assets/fragment-mono.woff2") format("woff2");
  font-display: swap;
}

/* Registered so a key's colors can animate, and so scripts can read --u in pixels. */
@property --u {
  syntax: "<length>";
  inherits: true;
  initial-value: 1px;
}
@property --top {
  syntax: "<color>";
  inherits: true;
  initial-value: #3a3a3d;
}
@property --bot {
  syntax: "<color>";
  inherits: true;
  initial-value: #313134;
}
@property --lipc {
  syntax: "<color>";
  inherits: true;
  initial-value: #222224;
}
@property --solid {
  syntax: "<color>";
  inherits: true;
  initial-value: #333336;
}
@property --fg {
  syntax: "<color>";
  inherits: true;
  initial-value: #e6e6e8;
}
@property --glow {
  syntax: "<color>";
  inherits: true;
  initial-value: transparent;
}
@property --glow-c {
  syntax: "<color>";
  inherits: true;
  initial-value: #6c52ff;
}

:root {
  color-scheme: dark light;
  --key-font:
    -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto,
    "Helvetica Neue", sans-serif;
  --text-font: "Newsreader", Georgia, "Times New Roman", serif;
  --mono-font: "Fragment Mono", ui-monospace, Menlo, Consolas, monospace;
  --u: 1px;
  --lip: 3;
  --r: 6;
  --br: 10;
  --gutter: clamp(16px, 4vw, 56px);
  --grad: linear-gradient(135deg, #6a4fd8 0%, #1f8a8a 52%, #cfa877 100%);
  --grad-tight: linear-gradient(135deg, #6a4fd8 24%, #1f8a8a 52%, #cfa877 78%);

  /* The page in Dark mode, with the app's Dark defaults. */
  --page: #1b1b1f;
  --page-2: #232328;
  --ink: #e9e8e4;
  --title: #fff;
  --ink-2: #a9a8a6;
  --rule: #38383f;
  --link: #ffc267;
  --warn-bg: #33241f;
  --warn-rule: #7c4a3c;

  --key-top: #3a3a3d;
  --key-bot: #313134;
  --key-lip: #222224;
  --key-solid: #333336;
  --key-fg: #e6e6e8;
  --key-edge: 0.07;
  --key-glow: transparent;
  --mod-top: #2b2b2e;
  --mod-bot: #252527;
  --mod-lip: #19191b;
  --mod-solid: #272729;
  --mod-fg: #e6e6e8;
  --mod-edge: 0.07;
  --mod-glow: transparent;
  --esc-top: #5c3b38;
  --esc-bot: #50332f;
  --esc-lip: #392421;
  --esc-solid: #533531;
  --esc-fg: #e6e6e8;
  --esc-edge: 0.07;
  --esc-glow: transparent;
  --pat-top: #474263;
  --pat-bot: #3d3957;
  --pat-lip: #2c2942;
  --pat-solid: #3f3b59;
  --pat-fg: #e6e6e8;
  --pat-edge: 0.07;
  --pat-glow: transparent;
  --bar-solid: #141416;
  --bar-fg: #e6e6e8;
}

/* The page in Classic mode, with the app's Classic defaults. Escape uses the Accent color, shown as the default macOS blue. */
@media (prefers-color-scheme: light) {
  :root {
    --page: #efeeea;
    --page-2: #e6e5e0;
    --ink: #1d1d1f;
    --title: #1d1d1f;
    --ink-2: #57565a;
    --rule: #cfcec9;
    --link: #1c44c4;
    --warn-bg: #f8e6df;
    --warn-rule: #c98a74;

    --key-top: #f7f7f7;
    --key-bot: #cdcdcd;
    --key-lip: #9d9d9d;
    --key-solid: #d6d6d6;
    --key-fg: #1d1d1f;
    --key-edge: 0.7;
    --key-glow: transparent;
    --mod-top: #696969;
    --mod-bot: #4f4f4f;
    --mod-lip: #383838;
    --mod-solid: #4a4a4a;
    --mod-fg: #ffffff;
    --mod-edge: 0.18;
    --mod-glow: transparent;
    --esc-top: #1a87ff;
    --esc-bot: #007aff;
    --esc-lip: #0062cc;
    --esc-solid: #007aff;
    --esc-fg: #ffffff;
    --esc-edge: 0.24;
    --esc-glow: rgb(0 122 255 / 0.6);
    --pat-top: #7b63ff;
    --pat-bot: #6c52ff;
    --pat-lip: #5642cc;
    --pat-solid: #6c52ff;
    --pat-fg: #ffffff;
    --pat-edge: 0.24;
    --pat-glow: rgb(108 82 255 / 0.6);
    --bar-solid: #1a1a1a;
    --bar-fg: #ffffff;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font: 400 clamp(18px, 0.4vw + 16.6px, 21px) / 1.5 var(--text-font);
  font-optical-sizing: auto;
  overflow-x: clip;
}
img,
svg {
  display: block;
  max-width: 100%;
}
a {
  color: var(--link);
  text-underline-offset: 0.16em;
  text-decoration-thickness: 1px;
}
a:hover {
  text-decoration-thickness: 2px;
}
:focus-visible {
  outline: 3px solid var(--link);
  outline-offset: 3px;
  border-radius: 4px;
}
p {
  margin: 0 0 1em;
}
h3 {
  font: 500 clamp(26px, 1.6vw + 20px, 36px) / 1.12 var(--text-font);
  letter-spacing: -0.012em;
  margin: 2em 0 0.5em;
  text-wrap: balance;
}
h4 {
  font: 400 13px/1.4 var(--mono-font);
  letter-spacing: 0.02em;
  margin: 2em 0 0.6em;
  color: var(--ink-2);
}
ul,
ol {
  margin: 0 0 1em;
  padding-left: 1.2em;
}
li {
  margin-bottom: 0.45em;
}
strong {
  font-weight: 600;
}
.sr {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
.skip {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 50;
  padding: 10px 14px;
  background: var(--ink);
  color: var(--page);
  border-radius: 8px;
  font: 500 15px var(--key-font);
}
.skip:focus {
  top: 12px;
}
html:not(.js) .jsonly {
  display: none;
}
/* With motion on, the script replaces the settled keys and types the title. If it never runs, they show anyway. */
@keyframes settled {
  to {
    visibility: visible;
  }
}
.motion .herocap:not(.typed) .herobar,
.motion .stack.live > .bar:not(.line) {
  visibility: hidden;
  animation: settled 0s 1.5s forwards;
}

/* Keycaps */
.bar {
  display: inline-flex;
  align-items: flex-start;
  gap: calc(14 * var(--u));
  padding: calc(5 * var(--u));
  border-radius: calc(var(--br) * var(--u));
  background: var(--bar-solid);
  box-shadow: 0 calc(2 * var(--u)) calc(12 * var(--u)) rgb(0 0 0 / 0.3);
  white-space: nowrap;
  max-width: 100%;
  vertical-align: top;
}
.entry {
  display: inline-flex;
  align-items: center;
  gap: calc(4 * var(--u));
}
.cap {
  --top: var(--key-top);
  --bot: var(--key-bot);
  --lipc: var(--key-lip);
  --solid: var(--key-solid);
  --fg: var(--key-fg);
  --edge: var(--key-edge);
  --glow: var(--key-glow);
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  height: calc((40 - var(--lip)) * var(--u));
  min-width: calc(36 * var(--u));
  margin-bottom: calc(var(--lip) * var(--u));
  padding: 0 calc(10 * var(--u));
  border: max(0.8px, calc(0.8 * var(--u))) solid transparent;
  border-radius: calc(var(--r) * var(--u));
  color: var(--fg);
  font: 400 calc(19 * var(--u)) / 1 var(--key-font);
  white-space: nowrap;
  background:
    linear-gradient(var(--top), var(--bot)) padding-box,
    linear-gradient(
        rgb(255 255 255 / var(--edge)),
        rgb(255 255 255 / calc(var(--edge) * 0.45))
      )
      border-box,
    linear-gradient(var(--top), var(--bot)) border-box;
  box-shadow:
    0 calc(var(--lip) * var(--u)) 0 var(--lipc),
    0 0 calc(10 * var(--u)) var(--glow);
}
.cap.mod {
  --top: var(--mod-top);
  --bot: var(--mod-bot);
  --lipc: var(--mod-lip);
  --solid: var(--mod-solid);
  --fg: var(--mod-fg);
  --edge: var(--mod-edge);
  --glow: var(--mod-glow);
}
.cap.esc {
  --top: var(--esc-top);
  --bot: var(--esc-bot);
  --lipc: var(--esc-lip);
  --solid: var(--esc-solid);
  --fg: var(--esc-fg);
  --edge: var(--esc-edge);
  --glow: var(--esc-glow);
}
.cap.pat {
  --top: var(--pat-top);
  --bot: var(--pat-bot);
  --lipc: var(--pat-lip);
  --solid: var(--pat-solid);
  --fg: var(--pat-fg);
  --edge: var(--pat-edge);
  --glow: var(--pat-glow);
}
.cap.lbl {
  font: 500 calc(14 * var(--u)) / 1 var(--key-font);
}
.cap.ico {
  padding: 0;
}
.cap.wide {
  min-width: calc(46 * var(--u));
}
.cap .lg {
  font: 500 calc(13 * var(--u)) / 1 var(--key-font);
  opacity: 0.65;
  margin-right: calc(6 * var(--u));
}
.cap .lb {
  font: 600 calc(15 * var(--u)) / 1 var(--key-font);
}
.cap .led {
  position: absolute;
  top: calc(5 * var(--u));
  left: calc(6 * var(--u));
  width: calc(5 * var(--u));
  height: calc(5 * var(--u));
  border-radius: 50%;
  background: #62e01a;
  box-shadow: 0 0 calc(3 * var(--u)) #62e01a;
}
.cap .led.off {
  background: rgb(0 0 0 / 0.35);
  box-shadow: none;
}
.i {
  width: calc(18 * var(--u));
  height: calc(18 * var(--u));
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.cc {
  font: 400 calc(15 * var(--u)) / 1 var(--key-font);
  color: var(--bar-fg);
  opacity: 0.8;
  padding: 0 calc(4 * var(--u));
  align-self: center;
  white-space: nowrap;
}
.cn {
  font: 600 calc(15 * var(--u)) / 1 var(--key-font);
  font-variant-numeric: tabular-nums;
  color: var(--bar-fg);
  opacity: 0.8;
  align-self: center;
  white-space: nowrap;
}

/* A key pressed down: its face drops onto its lip. */
.cap.down {
  transform: translateY(calc(var(--lip) * var(--u)));
  box-shadow:
    0 0 0 var(--lipc),
    0 0 calc(10 * var(--u)) var(--glow);
}
.pressable .cap {
  transition:
    transform 0.09s ease-out,
    box-shadow 0.09s ease-out;
}

/* Keys as buttons */
button.cap {
  appearance: none;
  cursor: pointer;
}
button.cap[aria-pressed="true"] {
  --top: #7b63ff;
  --bot: #6c52ff;
  --lipc: #5642cc;
  --solid: #6c52ff;
  --fg: #fff;
  --edge: 0.24;
  --glow: rgb(108 82 255 / 0.6);
  color: #fff;
}
.bar button.cap:focus-visible {
  outline-color: #fff;
}

/* Lines of keys. A live stack reserves its full height up front, and each line keeps one fixed place in the layout and travels by transform, so keys coming and going can never move anything else. */
.stack {
  --pitch: calc(55 * var(--u));
  display: flex;
  flex-direction: column;
  gap: calc(5 * var(--u));
  align-items: center;
  max-width: 100%;
}
.stack.right {
  --ax: 100%;
  --tx: -100%;
  align-items: flex-end;
}
.stack.left {
  --ax: 0%;
  --tx: 0%;
  align-items: flex-start;
}
.stack.live {
  position: relative;
  justify-content: flex-end;
  width: 100%;
  height: calc(var(--lines, 1) * var(--pitch) - 5 * var(--u));
}
.stack.timers {
  --pitch: calc(62 * var(--u));
}
.line {
  position: absolute;
  bottom: 0;
  left: var(--ax, 50%);
  width: max-content;
  max-width: none;
  transform: translate(
    var(--tx, -50%),
    calc(var(--slot, 0) * var(--pitch) * -1)
  );
  transition:
    transform 0.3s cubic-bezier(0.2, 1.25, 0.4, 1),
    opacity 0.18s linear,
    scale 0.18s linear;
}
.line.gone {
  opacity: 0;
  scale: 0.97;
}
html:not(.motion) .line {
  transition: none;
}
.tline {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: calc(3 * var(--u));
}
.tbar {
  height: calc(3 * var(--u));
  border-radius: calc(2 * var(--u));
  background: #ffac24;
  transform-origin: 0 50%;
}

[data-style="soft"] {
  --lip: 2;
  --r: 10;
  --br: 14;
}
[data-style="flat"] {
  --lip: 0;
  --r: 6;
  --br: 10;
}
[data-style="glass"] {
  --lip: 0;
  --r: 7;
  --br: 11;
}
[data-style="outline"] {
  --lip: 0;
  --r: 6;
  --br: 10;
}
[data-style="skeuomorph"] {
  --lip: 3;
  --r: 6;
  --br: 10;
}
[data-style="flat"] .cap,
.cap[data-style="flat"] {
  background: var(--solid);
  box-shadow: none;
  border-color: transparent;
}
[data-style="glass"] .cap,
.cap[data-style="glass"] {
  background:
    linear-gradient(
      rgb(255 255 255 / 0.16),
      rgb(255 255 255 / 0.02) 50%,
      transparent 50%
    ),
    color-mix(in srgb, var(--solid) 62%, transparent);
  background-clip: border-box;
  border-color: rgb(255 255 255 / 0.3);
  box-shadow: none;
}
[data-style="outline"] .cap,
.cap[data-style="outline"] {
  background: transparent;
  border: calc(1.2 * var(--u)) solid var(--solid);
  box-shadow: none;
  color: var(--bar-fg);
}
[data-style="glass"].bar,
[data-style="glass"] .bar,
.bar[data-bar="glass"] {
  background: color-mix(in srgb, var(--bar-solid) 48%, transparent);
  box-shadow:
    inset 0 0 0 max(0.8px, calc(0.8 * var(--u))) rgb(255 255 255 / 0.2),
    0 calc(2 * var(--u)) calc(12 * var(--u)) rgb(0 0 0 / 0.3);
}
[data-style="outline"].bar,
[data-style="outline"] .bar,
.bar[data-bar="outline"] {
  background: color-mix(in srgb, var(--bar-solid) 92%, transparent);
}
.bar[data-bar="soft"] {
  --br: 14;
}
.bar[data-bar="glass"] {
  --br: 11;
}

/* Color sets, for keys drawn in a look other than the page's own. Values are the app's. */
.darkset {
  --key-top: #3a3a3d;
  --key-bot: #313134;
  --key-lip: #222224;
  --key-solid: #333336;
  --key-fg: #e6e6e8;
  --key-edge: 0.07;
  --key-glow: transparent;
  --mod-top: #2b2b2e;
  --mod-bot: #252527;
  --mod-lip: #19191b;
  --mod-solid: #272729;
  --mod-fg: #e6e6e8;
  --mod-edge: 0.07;
  --mod-glow: transparent;
  --esc-top: #5c3b38;
  --esc-bot: #50332f;
  --esc-lip: #392421;
  --esc-solid: #533531;
  --esc-fg: #e6e6e8;
  --esc-edge: 0.07;
  --esc-glow: transparent;
  --pat-top: #474263;
  --pat-bot: #3d3957;
  --pat-lip: #2c2942;
  --pat-solid: #3f3b59;
  --pat-fg: #e6e6e8;
  --pat-edge: 0.07;
  --pat-glow: transparent;
  --bar-solid: #141416;
  --bar-fg: #e6e6e8;
}
.classic {
  --key-top: #f7f7f7;
  --key-bot: #cdcdcd;
  --key-lip: #9d9d9d;
  --key-solid: #d6d6d6;
  --key-fg: #1d1d1f;
  --key-edge: 0.7;
  --key-glow: transparent;
  --mod-top: #696969;
  --mod-bot: #4f4f4f;
  --mod-lip: #383838;
  --mod-solid: #4a4a4a;
  --mod-fg: #fff;
  --mod-edge: 0.18;
  --mod-glow: transparent;
  --esc-top: #1a87ff;
  --esc-bot: #007aff;
  --esc-lip: #0062cc;
  --esc-solid: #007aff;
  --esc-fg: #fff;
  --esc-edge: 0.24;
  --esc-glow: rgb(0 122 255 / 0.6);
  --pat-top: #7b63ff;
  --pat-bot: #6c52ff;
  --pat-lip: #5642cc;
  --pat-solid: #6c52ff;
  --pat-fg: #fff;
  --pat-edge: 0.24;
  --pat-glow: rgb(108 82 255 / 0.6);
  --bar-solid: #1a1a1a;
  --bar-fg: #fff;
}
.vivid {
  --key-top: #ffb43a;
  --key-bot: #ffac24;
  --key-lip: #cc8a1d;
  --key-solid: #ffac24;
  --key-fg: #fff;
  --key-edge: 0.24;
  --key-glow: rgb(255 172 36 / 0.6);
  --mod-top: #7b63ff;
  --mod-bot: #6c52ff;
  --mod-lip: #5642cc;
  --mod-solid: #6c52ff;
  --mod-fg: #fff;
  --mod-edge: 0.24;
  --mod-glow: rgb(108 82 255 / 0.6);
  --esc-top: #ff5050;
  --esc-bot: #ff3d3d;
  --esc-lip: #cc3131;
  --esc-solid: #ff3d3d;
  --esc-fg: #fff;
  --esc-edge: 0.24;
  --esc-glow: rgb(255 61 61 / 0.6);
  --pat-top: #1ad8a9;
  --pat-bot: #00d3a0;
  --pat-lip: #00a980;
  --pat-solid: #00d3a0;
  --pat-fg: #fff;
  --pat-edge: 0.24;
  --pat-glow: rgb(0 211 160 / 0.6);
  --bar-solid: #1a1a1a;
  --bar-fg: #fff;
}

/* One palette color on one key, whatever its role. */
.cap[class*=" p-"] {
  --top: var(--p-top);
  --bot: var(--p-bot);
  --lipc: var(--p-lip);
  --solid: var(--p-solid);
  --fg: var(--p-fg);
  --edge: var(--p-edge);
  --glow: var(--p-glow);
}
.p-snow {
  --p-top: #fff;
  --p-bot: #ededed;
  --p-lip: #c4c4c4;
  --p-solid: #efefef;
  --p-fg: #1d1d1f;
  --p-edge: 0.9;
  --p-glow: transparent;
}
.p-aluminum {
  --p-top: #f7f7f7;
  --p-bot: #cdcdcd;
  --p-lip: #9d9d9d;
  --p-solid: #d6d6d6;
  --p-fg: #1d1d1f;
  --p-edge: 0.7;
  --p-glow: transparent;
}
.p-silver {
  --p-top: #d2d2d2;
  --p-bot: #989898;
  --p-lip: #757575;
  --p-solid: #aaa;
  --p-fg: #1d1d1f;
  --p-edge: 0.35;
  --p-glow: transparent;
}
.p-graphite {
  --p-top: #696969;
  --p-bot: #4f4f4f;
  --p-lip: #383838;
  --p-solid: #4a4a4a;
  --p-fg: #fff;
  --p-edge: 0.18;
  --p-glow: transparent;
}
.p-midnight {
  --p-top: #272727;
  --p-bot: #181818;
  --p-lip: #0e0e0e;
  --p-solid: #1a1a1a;
  --p-fg: #fff;
  --p-edge: 0.1;
  --p-glow: transparent;
}
.p-dusk {
  --p-top: #474263;
  --p-bot: #3d3957;
  --p-lip: #2c2942;
  --p-solid: #3f3b59;
  --p-fg: #e6e6e8;
  --p-edge: 0.07;
  --p-glow: transparent;
}
.p-ember {
  --p-top: #5c3b38;
  --p-bot: #50332f;
  --p-lip: #392421;
  --p-solid: #533531;
  --p-fg: #e6e6e8;
  --p-edge: 0.07;
  --p-glow: transparent;
}
.p-mint {
  --p-top: #1ad7aa;
  --p-bot: #00d3a0;
  --p-lip: #00a980;
  --p-solid: #00d3a0;
  --p-fg: #fff;
  --p-edge: 0.24;
  --p-glow: rgb(0 211 160 / 0.6);
}
.p-lime {
  --p-top: #6ed51a;
  --p-bot: #5ed000;
  --p-lip: #4ba600;
  --p-solid: #5ed000;
  --p-fg: #fff;
  --p-edge: 0.24;
  --p-glow: rgb(94 208 0 / 0.6);
}
.p-cobalt {
  --p-top: #527bf6;
  --p-bot: #3f6cf5;
  --p-lip: #3256c4;
  --p-solid: #3f6cf5;
  --p-fg: #fff;
  --p-edge: 0.24;
  --p-glow: rgb(63 108 245 / 0.6);
}
.p-violet {
  --p-top: #7b63ff;
  --p-bot: #6c52ff;
  --p-lip: #5642cc;
  --p-solid: #6c52ff;
  --p-fg: #fff;
  --p-edge: 0.24;
  --p-glow: rgb(108 82 255 / 0.6);
}
.p-amber {
  --p-top: #ffb43a;
  --p-bot: #ffac24;
  --p-lip: #cc8a1d;
  --p-solid: #ffac24;
  --p-fg: #fff;
  --p-edge: 0.24;
  --p-glow: rgb(255 172 36 / 0.6);
}
.p-tangerine {
  --p-top: #ff7533;
  --p-bot: #ff661c;
  --p-lip: #cc5216;
  --p-solid: #ff661c;
  --p-fg: #fff;
  --p-edge: 0.24;
  --p-glow: rgb(255 102 28 / 0.6);
}
.p-coral {
  --p-top: #ff5050;
  --p-bot: #ff3d3d;
  --p-lip: #cc3131;
  --p-solid: #ff3d3d;
  --p-fg: #fff;
  --p-edge: 0.24;
  --p-glow: rgb(255 61 61 / 0.6);
}
.p-magenta {
  --p-top: #f847da;
  --p-bot: #f733d6;
  --p-lip: #c629ab;
  --p-solid: #f733d6;
  --p-fg: #fff;
  --p-edge: 0.24;
  --p-glow: rgb(247 51 214 / 0.6);
}
.b-midnight {
  --bar-solid: #1a1a1a;
  --bar-fg: #fff;
}
.b-pitch {
  --bar-solid: #141416;
  --bar-fg: #e6e6e8;
}
.b-slate {
  --bar-solid: #6e6e6e;
  --bar-fg: #fff;
}
.b-graphite {
  --bar-solid: #4a4a4a;
  --bar-fg: #fff;
}
.b-snow {
  --bar-solid: #efefef;
  --bar-fg: #1d1d1f;
}

/* Keys whose colors change while they're on screen. */
.morph .cap {
  transition:
    --top 0.3s linear var(--d, 0s),
    --bot 0.3s linear var(--d, 0s),
    --lipc 0.3s linear var(--d, 0s),
    --solid 0.3s linear var(--d, 0s),
    --fg 0.3s linear var(--d, 0s),
    --glow 0.3s linear var(--d, 0s);
}
.morph .bar {
  transition: background-color 0.3s linear;
}

/* Keycaps in running text */
kbd {
  display: inline-block;
  padding: 0.04em 0.38em 0.08em;
  margin: 0 0.04em;
  border-radius: 0.28em;
  font: 400 0.8em/1.25 var(--key-font);
  white-space: nowrap;
  color: var(--key-fg);
  background: linear-gradient(var(--key-top), var(--key-bot));
  box-shadow: 0 0.12em 0 var(--key-lip);
  vertical-align: 0.06em;
}
kbd.p {
  background: linear-gradient(var(--pat-top), var(--pat-bot));
  box-shadow: 0 0.12em 0 var(--pat-lip);
  color: var(--pat-fg);
}
.tag {
  display: inline-block;
  padding: 0.15em 0.5em 0.2em;
  border-radius: 0.35em;
  font: 600 11px/1.3 var(--key-font);
  letter-spacing: 0.02em;
  vertical-align: 0.2em;
  white-space: nowrap;
}
.tag.pro {
  background: #6c52ff;
  color: #fff;
  box-shadow: 0 2px 0 #5642cc;
}
.tag.free {
  background: var(--page-2);
  color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--rule);
}
h3 .tag {
  vertical-align: 0.5em;
  margin-left: 0.25em;
}

/* Page frame */
.wrap {
  width: 100%;
  max-width: 1480px;
  margin-inline: auto;
  padding-inline: clamp(16px, 4vw, 56px);
}
.sec {
  position: relative;
  padding-block: clamp(72px, 9vw, 140px);
}
.sec.tight {
  padding-block: clamp(48px, 5.4vw, 84px);
}
.prose {
  max-width: 34em;
}
.lede {
  font-size: 1.28em;
  line-height: 1.34;
  letter-spacing: -0.006em;
}
.twocol {
  columns: 2 22em;
  column-gap: clamp(32px, 5vw, 72px);
}
.twocol > * {
  break-inside: avoid-column;
}
.twocol h3:first-child {
  margin-top: 0;
}

/* Big section headings on the landing page */
.big {
  margin: 0 0 0.42em;
  font: 400 clamp(42px, 5.8vw, 92px) / 1.02 var(--text-font);
  letter-spacing: -0.024em;
  text-wrap: balance;
}
.mid {
  margin: 0 0 0.5em;
  font: 400 clamp(33px, 3.5vw, 54px) / 1.06 var(--text-font);
  letter-spacing: -0.018em;
  text-wrap: balance;
}
.mid .tag,
.big .tag {
  font-size: 13px;
  vertical-align: 0.9em;
  margin-left: 0.3em;
  letter-spacing: 0.02em;
}
.center {
  text-align: center;
}
.note {
  margin: 0;
  font: 400 13px/1.5 var(--mono-font);
  color: var(--ink-2);
}

.top {
  position: absolute;
  inset: 0 0 auto;
  z-index: 5;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 6px 20px;
  padding: 16px clamp(16px, 4vw, 56px);
  font: 500 14px/1.3 var(--key-font);
}
.top a {
  color: var(--ink);
  text-decoration: none;
  opacity: 0.86;
}
.top a:hover {
  opacity: 1;
  text-decoration: underline;
}
.top nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.top li {
  margin: 0;
}

/* First screen: the title and its text on the page, the live keys on a bloom of the color backdrop. */
.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  align-items: center;
  min-height: 100svh;
  padding: 88px var(--gutter) 56px;
  overflow: clip;
}
.hero::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0 0 0 24%;
  background: var(--grad-tight);
  -webkit-mask-image: radial-gradient(
    ellipse 52% 50% at 57% 50%,
    #000 40%,
    rgb(0 0 0 / 0.8) 58%,
    rgb(0 0 0 / 0.42) 74%,
    rgb(0 0 0 / 0.12) 90%,
    transparent 100%
  );
  mask-image: radial-gradient(
    ellipse 52% 50% at 57% 50%,
    #000 40%,
    rgb(0 0 0 / 0.8) 58%,
    rgb(0 0 0 / 0.42) 74%,
    rgb(0 0 0 / 0.12) 90%,
    transparent 100%
  );
}
.heroin {
  width: 100%;
  max-width: 1240px;
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(0, 33rem) minmax(0, 1fr);
  grid-template-areas:
    "title live"
    "text live";
  column-gap: clamp(32px, 4.5vw, 72px);
  align-items: start;
  align-content: center;
}
.herocap {
  grid-area: title;
  margin: 0;
  line-height: 1;
  font-weight: 400;
  --hu: clamp(40px, 5.1vw, 76px);
}
.herobar {
  display: inline-flex;
  padding: calc(var(--hu) * 0.125);
  border-radius: calc(var(--hu) * 0.25);
  background: var(--bar-solid);
  box-shadow: 0 calc(var(--hu) * 0.05) calc(var(--hu) * 0.3) rgb(0 0 0 / 0.34);
  max-width: 100%;
}
.herokey {
  display: inline-flex;
  align-items: center;
  height: calc(var(--hu) * 0.925 + var(--hu) * 0.5);
  margin-bottom: calc(var(--hu) * 0.075);
  padding: 0 calc(var(--hu) * 0.3) calc(var(--hu) * 0.05);
  min-width: calc(var(--hu) * 0.9);
  border-radius: calc(var(--hu) * 0.15);
  color: #fff;
  font: 400 var(--hu) / 1 var(--key-font);
  letter-spacing: -0.03em;
  white-space: pre;
  background: linear-gradient(#7b63ff, #6c52ff);
  box-shadow:
    0 calc(var(--hu) * 0.075) 0 #5642cc,
    inset 0 0 0 max(1px, calc(var(--hu) * 0.02)) rgb(255 255 255 / 0.24);
}
.herotext {
  grid-area: text;
  margin-top: clamp(20px, 2.6vw, 34px);
}
.heroline {
  margin: 0 0 0.4em;
  font: 400 clamp(30px, 3.1vw, 50px) / 1.08 var(--text-font);
  letter-spacing: -0.016em;
  text-wrap: balance;
}
.herosub {
  margin: 0 0 1em;
  max-width: 31em;
}
.status {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
  margin: 0;
}
.statuscap {
  display: inline-flex;
  padding: 5px;
  border-radius: 10px;
  background: var(--bar-solid);
}
.statuscap span,
.statuscap a {
  display: inline-flex;
  align-items: center;
  min-height: 37px;
  padding: 0 14px;
  margin-bottom: 3px;
  border-radius: 6px;
  font: 500 15px/1.2 var(--key-font);
  color: var(--pat-fg);
  background: linear-gradient(var(--pat-top), var(--pat-bot));
  box-shadow: 0 3px 0 var(--pat-lip);
  text-decoration: none;
}
.statusnote {
  font: 400 13px/1.45 var(--mono-font);
}
.herolive {
  grid-area: live;
  align-self: center;
  min-width: 0;
  --u: clamp(0.96px, 0.09vw + 0.45px, 2.2px);
}

/* A short label on the product's own dark bar, so it reads on any color. */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 28px;
  max-width: 100%;
  padding: 3px 10px;
  border-radius: 8px;
  background: #141416;
  color: #e6e6e8;
  font: 400 12.5px/1.35 var(--mono-font);
}
.chip .tag {
  flex: none;
  min-width: 3.3em;
  text-align: center;
  vertical-align: 0;
}
.chip .tag.free {
  background: #2c2c30;
  color: #e6e6e8;
  box-shadow: none;
}
#hero-keys {
  --lines: 4;
}
.herochip {
  margin: calc(14 * var(--u)) 0 0;
  white-space: nowrap;
}

@media (max-width: 899px) {
  .hero {
    align-items: start;
    min-height: 0;
    padding-top: 96px;
    padding-bottom: 40px;
  }
  .hero::before {
    inset: 0;
    -webkit-mask-image: radial-gradient(
      ellipse 130% 250px at 50% 285px,
      #000 30%,
      rgb(0 0 0 / 0.66) 58%,
      rgb(0 0 0 / 0.2) 84%,
      transparent 100%
    );
    mask-image: radial-gradient(
      ellipse 130% 250px at 50% 285px,
      #000 30%,
      rgb(0 0 0 / 0.66) 58%,
      rgb(0 0 0 / 0.2) 84%,
      transparent 100%
    );
  }
  .heroin {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "title"
      "live"
      "text";
  }
  #hero-keys {
    --lines: 3;
  }
  .herolive {
    margin-top: 18px;
    --u: clamp(0.94px, 0.2vw + 0.3px, 1.45px);
  }
}

/* The promise */
.promise {
  padding-top: clamp(64px, 7vw, 110px);
}
.ask {
  --u: clamp(1.9px, 0.133vw + 1.7px, 4.2px);
  margin: clamp(10px, 2vw, 28px) auto clamp(32px, 4vw, 60px);
  text-align: center;
}
.askq {
  margin: 0 0 0.6em;
  min-height: 1.2em;
  font: italic 400 clamp(23px, 2.4vw, 38px) / 1.2 var(--text-font);
  color: var(--ink-2);
  transition: opacity 0.2s linear;
}
.promisecopy {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 56px);
  max-width: 56em;
  margin: 0 auto;
}
.promisecopy p {
  margin: 0;
  font-size: 1.12em;
  line-height: 1.4;
}
.promise .note {
  max-width: 56em;
  margin: clamp(20px, 2.4vw, 32px) auto 0;
}
@media (max-width: 760px) {
  .promisecopy {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Key combos */
.rows {
  display: grid;
  gap: clamp(52px, 6vw, 96px);
  margin-top: clamp(44px, 5vw, 80px);
}
.row {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: clamp(20px, 4vw, 72px);
  align-items: center;
}
.row h3 {
  margin: 0 0 0.35em;
}
.row p {
  margin: 0;
}
.demo {
  container-type: inline-size;
  min-width: 0;
}
.demo > .stack {
  --u: clamp(1.1px, calc(100cqw / 330), 2.5px);
}
@media (max-width: 899px) {
  .row {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Every key on the board */
.wall {
  --u: clamp(0.92px, 0.1vw + 0.8px, 2.1px);
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: calc(14 * var(--u)) calc(16 * var(--u));
  margin-top: clamp(28px, 3.4vw, 52px);
}
.wall .cap:hover {
  transform: translateY(calc(var(--lip) * var(--u)));
  box-shadow:
    0 0 0 var(--lipc),
    0 0 calc(10 * var(--u)) var(--glow);
}

/* A full-bleed band of the color backdrop. The color stays put in the viewport while the keys travel over it, and each end dissolves into the page. */
.band {
  position: relative;
  isolation: isolate;
  color: #fff;
  padding-block: clamp(150px, 22vh, 260px);
}
.bandbg {
  position: absolute;
  inset: 0;
  z-index: -2;
  overflow: clip;
}
.bandbg > div {
  position: sticky;
  top: 0;
  height: 100lvh;
  background:
    linear-gradient(
      90deg,
      rgb(9 8 32 / 0.2),
      rgb(9 8 32 / 0.08) 52%,
      transparent 74%
    ),
    var(--grad);
}
@media (max-width: 899px) {
  .bandbg > div {
    background:
      linear-gradient(rgb(9 8 32 / 0.14) 0 0),
      var(--grad) 0 0 / 100% 135%;
  }
}
.band::before,
.band::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  z-index: -1;
  height: clamp(130px, 20vh, 230px);
  pointer-events: none;
}
.band::before {
  top: 0;
  background: linear-gradient(
    var(--page) 0%,
    color-mix(in srgb, var(--page) 72%, transparent) 34%,
    color-mix(in srgb, var(--page) 30%, transparent) 66%,
    transparent 100%
  );
}
.band::after {
  bottom: 0;
  background: linear-gradient(
    transparent 0%,
    color-mix(in srgb, var(--page) 30%, transparent) 34%,
    color-mix(in srgb, var(--page) 72%, transparent) 66%,
    var(--page) 100%
  );
}
.band a {
  color: #fff;
}
.band :focus-visible {
  outline-color: #fff;
}
.band .lede {
  max-width: 30em;
  font-size: clamp(24px, 1.2vw + 18px, 31px);
  line-height: 1.26;
}
.bandsec {
  scroll-margin-top: 36px;
}
.bandsec + .bandsec {
  margin-top: clamp(96px, 11vw, 180px);
}

/* Colors */
.looks {
  --u: clamp(1.02px, 0.06vw + 0.9px, 1.9px);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(28px, 3vw, 52px);
  margin-top: clamp(32px, 4vw, 60px);
}
.look h3 {
  margin: 0 0 0.5em;
  color: #fff;
}
.look .chip {
  margin-top: calc(10 * var(--u));
}
.look .stack {
  align-items: flex-start;
}
@media (max-width: 899px) {
  .looks {
    grid-template-columns: minmax(0, 1fr);
    --u: clamp(1px, 0.2vw + 0.5px, 1.5px);
  }
}

/* Mixer */
.mixer {
  --u: clamp(1px, 0.04vw + 0.9px, 1.2px);
  margin-top: clamp(40px, 5vw, 76px);
}
.mixer h3 {
  margin: 0 0 0.6em;
  color: #fff;
}
.mixroles {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 14px;
}
.mixcolors {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 16px;
}
.mixcolor {
  padding: 0;
}
.mixcolor[aria-pressed="true"] {
  outline: 3px solid #fff;
  outline-offset: 2px;
}
.mixfoot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 12px;
  margin: 0;
}

/* Styles */
.stylestage {
  --u: clamp(1.02px, 0.1vw + 0.72px, 2.5px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: calc(14 * var(--u));
  margin-top: clamp(28px, 3.4vw, 52px);
}
.stylerow {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: calc(14 * var(--u));
}
.stylepick {
  display: flex;
  justify-content: center;
  margin-top: clamp(28px, 3.4vw, 48px);
}
.stylepick .bar {
  --u: clamp(0.84px, 0.08vw + 0.6px, 1.35px);
  flex-wrap: wrap;
  justify-content: center;
  gap: calc(4 * var(--u));
  white-space: normal;
}
.styleread {
  margin-top: clamp(20px, 2.4vw, 34px);
  text-align: center;
}
.stylechip {
  display: flex;
  align-items: flex-start;
  width: min(100%, 48em);
  min-height: 46px;
  margin-inline: auto;
  padding-block: 6px;
  text-align: left;
}
@media (max-width: 560px) {
  .stylechip {
    min-height: 64px;
  }
}
.styleread b {
  display: block;
  margin-bottom: 0.3em;
  font: 500 clamp(32px, 3.4vw, 54px) / 1.1 var(--text-font);
  letter-spacing: -0.012em;
}

/* The five, written out */
.stylelist {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: clamp(28px, 3vw, 44px);
  list-style: none;
  padding: 0;
  margin: 0;
}
.stylelist li {
  margin: 0;
}
.stylelist h3 {
  margin: 0 0 0.3em;
  font-size: clamp(24px, 1vw + 19px, 30px);
}
.stylelist p {
  margin: 0;
  font-size: 0.95em;
}
@media (max-width: 1099px) {
  .stylelist {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 14em), 1fr));
  }
}
.specimen {
  --u: 1.3px;
  margin-bottom: 14px;
}

/* Sizes */
.sizes {
  --u: 1px;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: clamp(20px, 3vw, 44px);
  margin: 24px 0 8px;
}
.sizes > div {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-start;
}
.sizes small {
  font: 400 12px/1.3 var(--mono-font);
  color: var(--ink-2);
}

/* Custom keys */
.patternstop {
  text-align: center;
}
.patternstop .lede {
  max-width: 30em;
  margin-inline: auto;
}
.merge {
  --u: clamp(1.7px, 0.19vw + 1.2px, 3.5px);
  position: relative;
  isolation: isolate;
  transition: --glow-c 0.5s linear;
  margin: clamp(16px, 2vw, 32px) 0 clamp(40px, 5vw, 80px);
  padding-block: clamp(36px, 5vw, 76px);
  text-align: center;
}
.merge::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: -12% 0;
  background: radial-gradient(
    48% 50% at 50% 50%,
    color-mix(in srgb, var(--glow-c) 46%, transparent),
    color-mix(in srgb, var(--glow-c) 24%, transparent) 46%,
    color-mix(in srgb, var(--glow-c) 8%, transparent) 76%,
    transparent 100%
  );
}
.mergebox {
  position: relative;
  height: calc(50 * var(--u));
}
.mergebox .stack {
  position: absolute;
  inset: 0;
}
.mergeraw {
  transition:
    opacity 0.16s linear,
    scale 0.16s ease-in;
}
.mergeraw.squeeze {
  opacity: 0;
  scale: 0.72 1;
}
.mergesay {
  margin: 0 0 0.7em;
  min-height: 1.2em;
  font: italic 400 clamp(23px, 2.4vw, 38px) / 1.2 var(--text-font);
}
.kinds {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(32px, 5vw, 80px);
}
.kinds h3 {
  margin: 0 0 0.4em;
}
.kinds .bar {
  --u: clamp(1.02px, 0.05vw + 0.9px, 1.5px);
  margin-bottom: 18px;
  max-width: none;
}
.compare-scene {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(24px, 4vw, 64px);
  margin-top: clamp(24px, 3vw, 44px);
}
.lane {
  min-width: 0;
}
.lane h4 {
  margin: 0 0 10px;
  color: var(--ink-2);
}
.lane h4 .tag {
  margin-left: 0.5em;
  vertical-align: 0;
}
.lane .stack {
  --u: clamp(0.84px, calc(100cqw / 300), 1.5px);
}
.lanebox {
  container-type: inline-size;
}
@media (max-width: 760px) {
  .kinds,
  .compare-scene {
    grid-template-columns: minmax(0, 1fr);
  }
}
details.more {
  margin-top: clamp(28px, 3vw, 44px);
  border-top: 1px solid var(--rule);
  padding-top: 14px;
}
details.more summary {
  cursor: pointer;
  font: 500 clamp(20px, 0.8vw + 16px, 25px) / 1.25 var(--text-font);
}
details.more .inner {
  padding-top: 18px;
}

/* Tables and lists of patterns */
.tablewrap {
  overflow-x: auto;
}
table {
  border-collapse: collapse;
  width: 100%;
}
caption {
  text-align: left;
  font: 400 13px/1.5 var(--mono-font);
  color: var(--ink-2);
  padding-bottom: 10px;
}
th,
td {
  text-align: left;
  vertical-align: top;
  padding: 0.55em 0.8em 0.55em 0;
  border-top: 1px solid var(--rule);
  font-weight: 400;
}
thead th {
  font: 600 14px/1.3 var(--key-font);
  border-top: 0;
}
tbody th {
  font-weight: 500;
}
.ptable td:first-child,
.ptable th:first-child {
  white-space: nowrap;
}
.plist {
  list-style: none;
  padding: 0;
  margin: 0 0 1em;
  columns: 3 14em;
  column-gap: 28px;
  font-size: 0.92em;
}
.plist li {
  break-inside: avoid;
  margin: 0;
  padding: 0.28em 0;
  display: flex;
  gap: 0.6em;
  align-items: baseline;
}
.plist kbd {
  flex: none;
}
.compare td,
.compare th {
  min-width: 7em;
}
@media (max-width: 640px) {
  .compare td,
  .compare th {
    min-width: 0;
    font-size: 0.86em;
    padding-right: 0.5em;
    overflow-wrap: anywhere;
  }
  .ptable thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }
  .ptable tr {
    display: grid;
    grid-template-columns: auto 1fr;
  }
  .ptable td {
    border-top: 1px solid var(--rule);
  }
}
.compare td:nth-child(2),
.compare td:nth-child(3) {
  font-size: 0.94em;
}

/* Try it */
.trysec {
  isolation: isolate;
  overflow: clip;
}
.trysec::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  background: var(--grad-tight);
  -webkit-mask-image: radial-gradient(
    ellipse 62% 38% at 50% 55%,
    #000 34%,
    rgb(0 0 0 / 0.66) 60%,
    rgb(0 0 0 / 0.2) 84%,
    transparent 100%
  );
  mask-image: radial-gradient(
    ellipse 62% 38% at 50% 55%,
    #000 34%,
    rgb(0 0 0 / 0.66) 60%,
    rgb(0 0 0 / 0.2) 84%,
    transparent 100%
  );
}
.trytop {
  max-width: 44em;
  margin: 0 auto;
  text-align: center;
}
.trytop p {
  margin-bottom: 0;
}
.tryout {
  container-type: inline-size;
  margin: clamp(24px, 3vw, 44px) auto clamp(16px, 2vw, 28px);
  max-width: 980px;
}
.tryout .stack {
  --u: clamp(1px, calc(100cqw / 520), 1.9px);
}
.trybox {
  max-width: 640px;
  margin: 0 auto;
}
.trybox label {
  display: flex;
  width: fit-content;
  margin: 0 auto 10px;
  font: 500 14px/1.35 var(--key-font);
  text-align: center;
}
.trybox input {
  width: 100%;
  height: 56px;
  padding: 0 18px;
  border: 1px solid rgb(255 255 255 / 0.14);
  border-radius: 12px;
  font: 400 19px/1.2 var(--key-font);
  color: #e6e6e8;
  background: linear-gradient(#2e2e31, #272729);
  box-shadow:
    0 4px 0 #161618,
    0 8px 24px rgb(0 0 0 / 0.28);
  caret-color: #ffac24;
}
.trybox input:focus-visible {
  outline-color: #fff;
}
.trypick {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 14px;
  margin: 16px auto 0;
}
.trypick .bar {
  --u: 0.92px;
  gap: calc(4 * var(--u));
  flex-wrap: wrap;
  white-space: normal;
}
.trynote {
  max-width: 44em;
  margin: 16px auto 0;
  text-align: center;
  color: var(--ink);
}

/* Transitions */
.trans {
  --u: clamp(1.3px, 0.14vw + 1.05px, 2.5px);
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: clamp(20px, 2.4vw, 40px);
  margin: clamp(28px, 3.4vw, 52px) 0 0;
  padding: 0;
  list-style: none;
}
.trans li {
  margin: 0;
}
.tv {
  display: flex;
  align-items: center;
  height: calc(70 * var(--u));
  perspective: 400px;
}
.trans h3 {
  margin: 0.2em 0 0.3em;
  font-size: clamp(22px, 0.6vw + 18px, 26px);
}
.trans h3 .tag {
  vertical-align: 0.2em;
}
.trans p {
  margin: 0;
  font-size: 0.92em;
}
@media (max-width: 1099px) {
  .trans {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 15em), 1fr));
  }
}

/* Who it's for */
.who {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 19em), 1fr));
  gap: clamp(32px, 4vw, 64px) clamp(28px, 3.4vw, 56px);
  margin-top: clamp(24px, 3vw, 40px);
}
.who h3 {
  margin: 0 0 0.3em;
}
.who p {
  margin: 0;
}
.whokeys {
  --u: 1.25px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

/* For Mac: the bottom-left keys of a Mac keyboard on a bloom of the color backdrop. Self-contained, to rewrite when other operating systems arrive. */
.macsec {
  isolation: isolate;
  overflow: clip;
}
.macsec .duo {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}
.mackeys {
  position: relative;
  container-type: inline-size;
}
.mackeys::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: -55% -8%;
  background: var(--grad-tight);
  -webkit-mask-image: radial-gradient(
    closest-side,
    #000 34%,
    rgb(0 0 0 / 0.66) 60%,
    rgb(0 0 0 / 0.2) 84%,
    transparent 100%
  );
  mask-image: radial-gradient(
    closest-side,
    #000 34%,
    rgb(0 0 0 / 0.66) 60%,
    rgb(0 0 0 / 0.2) 84%,
    transparent 100%
  );
}
.mackeys .bar {
  --u: clamp(1.1px, calc(100cqw / 232), 2.9px);
  gap: calc(4 * var(--u));
  max-width: none;
}
.mackeys .cap {
  flex-direction: column;
  gap: calc(5 * var(--u));
  width: calc(50 * var(--u));
  height: calc((52 - var(--lip)) * var(--u));
  transition:
    transform 0.09s ease-out,
    box-shadow 0.09s ease-out;
}
.mackeys .cap:first-child {
  width: calc(44 * var(--u));
}
.mackeys .cap:last-child {
  width: calc(64 * var(--u));
}
.mackeys small {
  font: 400 calc(8.5 * var(--u)) / 1 var(--key-font);
}
.mackeys .cap:hover {
  transform: translateY(calc(var(--lip) * var(--u)));
  box-shadow:
    0 0 0 var(--lipc),
    0 0 calc(10 * var(--u)) var(--glow);
}
/* Now and then a hand rolls across the keys. .motion is only set when Reduce Motion is off. */
@keyframes macpress {
  0%,
  5%,
  100% {
    transform: none;
    box-shadow:
      0 calc(var(--lip) * var(--u)) 0 var(--lipc),
      0 0 calc(10 * var(--u)) var(--glow);
  }
  2% {
    transform: translateY(calc(var(--lip) * var(--u)));
    box-shadow:
      0 0 0 var(--lipc),
      0 0 calc(10 * var(--u)) var(--glow);
  }
}
.motion .mackeys .cap:not(:hover) {
  animation: macpress 7s ease-out infinite;
  animation-delay: calc(var(--i) * 0.13s);
}
.macsec .macfacts {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: clamp(44px, 5vw, 80px);
  padding-top: 18px;
  border-top: 1px solid var(--rule);
}
@media (max-width: 899px) {
  .macsec .duo,
  .macsec .macfacts {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Practical sections: text beside a scene that needs no frame */
.duo {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr);
  gap: clamp(28px, 5vw, 88px);
  align-items: center;
}
.duo.flip > :first-child {
  order: 2;
}
.scene {
  margin: 0;
  min-width: 0;
}
.scene figcaption {
  margin-top: 14px;
  font: 400 13px/1.5 var(--mono-font);
  color: var(--ink-2);
}
.duo p:last-child {
  margin-bottom: 0;
}
.duo h3 {
  margin: 1.3em 0 0.35em;
  font-size: clamp(23px, 0.9vw + 18px, 29px);
}
@media (max-width: 899px) {
  .duo {
    grid-template-columns: minmax(0, 1fr);
  }
  .duo.flip > :first-child {
    order: 0;
  }
}

/* Display modes and history */
.lanes {
  display: grid;
  grid-template-columns: repeat(var(--cols, 2), minmax(0, 1fr));
  gap: clamp(16px, 2vw, 32px);
}
.lanes .stack {
  --u: clamp(0.8px, calc(100cqw / 250), 1.5px);
}
.lanes.three .stack {
  --u: clamp(0.74px, calc(100cqw / 190), 1.3px);
}

/* Position and displays */
.desk {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  container-type: inline-size;
}
.screen {
  position: relative;
  flex: 3;
  aspect-ratio: 16 / 10;
  border-radius: 8px;
  box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--ink) 26%, transparent);
  overflow: hidden;
  min-width: 0;
}
.screen.b {
  flex: 2;
}
.pos {
  --u: clamp(0.56px, calc(100cqw / 640), 1.05px);
  position: absolute;
  width: max-content;
  left: 50%;
  bottom: 4%;
  transform: translateX(-50%);
}
.motion .pos {
  left: 0;
  top: 0;
  bottom: auto;
}
.pointer {
  position: absolute;
  left: 0;
  top: 0;
  width: 18px;
  height: 18px;
  z-index: 3;
  pointer-events: none;
}
.posread {
  margin: 14px 0 0;
  min-height: 4.5em;
  font: 400 13px/1.5 var(--mono-font);
  color: var(--ink-2);
}

/* Hot key */
.hk {
  --u: clamp(1.2px, 0.12vw + 1px, 2.2px);
}
.hkword {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: calc(16 * var(--u)) 0 4px;
  font: 500 clamp(26px, 1.6vw + 20px, 38px) / 1.12 var(--text-font);
}
.hkdetail {
  margin: 0 0 calc(16 * var(--u));
  min-height: 6.2em;
  max-width: 28em;
  color: var(--ink-2);
}
@media (max-width: 420px) {
  .hkword {
    min-height: 2.3em;
  }
}
.mbicon {
  position: relative;
  flex: none;
  width: 26px;
  height: 19px;
  border-radius: 4px;
  box-shadow: inset 0 0 0 1.6px currentColor;
}
.mbicon::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 9px;
  height: 1.6px;
  transform: translate(-50%, 2px);
  background: currentColor;
}
.mbicon.off {
  opacity: 0.42;
}

/* Settings */
.tour {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 20em), 1fr));
  gap: clamp(20px, 2.6vw, 40px) clamp(28px, 4vw, 64px);
  margin: 0;
}
.tour dt {
  font: 500 clamp(22px, 0.6vw + 18px, 26px) / 1.2 var(--text-font);
  margin-bottom: 0.25em;
}
.tour dd {
  margin: 0;
}

/* Pricing */
.pricing {
  isolation: isolate;
  overflow: clip;
}
.pricing::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0 0 auto;
  height: 760px;
  background: var(--grad);
  opacity: 0.5;
  -webkit-mask-image: radial-gradient(
    ellipse 72% 50% at 50% 50%,
    #000 10%,
    rgb(0 0 0 / 0.5) 50%,
    rgb(0 0 0 / 0.14) 80%,
    transparent 100%
  );
  mask-image: radial-gradient(
    ellipse 72% 50% at 50% 50%,
    #000 10%,
    rgb(0 0 0 / 0.5) 50%,
    rgb(0 0 0 / 0.14) 80%,
    transparent 100%
  );
}
.prices {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 19em), 1fr));
  gap: clamp(32px, 5vw, 80px);
  margin-bottom: clamp(44px, 5vw, 80px);
}
.price h3 {
  margin: 0.7em 0 0.25em;
}
.price p {
  margin: 0;
}
.pricekey {
  --u: clamp(1.9px, 0.2vw + 1.5px, 3px);
}

/* FAQ */
.faq {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 clamp(32px, 5vw, 72px);
  align-items: start;
}
.faq details {
  border-top: 1px solid var(--rule);
}
.faq summary {
  cursor: pointer;
  padding: 0.7em 0;
  font: 500 clamp(20px, 0.6vw + 17px, 24px) / 1.2 var(--text-font);
}
.faq details p {
  margin-bottom: 0.9em;
}
@media (max-width: 760px) {
  .faq {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Privacy */
.warn {
  padding: 16px 18px;
  margin: 1.6em 0;
  border-radius: 10px;
  background: var(--warn-bg);
  box-shadow: inset 0 0 0 1px var(--warn-rule);
}
.warn p:last-child {
  margin: 0;
}
.memory {
  --u: clamp(1px, 0.08vw + 0.9px, 1.7px);
}
.memory h3,
.stores h3 {
  margin: 0 0 0.3em;
  font-size: clamp(22px, 0.6vw + 18px, 26px);
}
.memory h3 {
  margin-bottom: 0.9em;
}
.stores {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 44px);
  margin-top: clamp(24px, 3vw, 40px);
  padding-top: 18px;
  border-top: 1px solid var(--rule);
}
.stores p {
  margin: 0;
  font-size: 0.95em;
}

/* Footer */
footer {
  padding: 48px clamp(16px, 4vw, 56px) 64px;
  border-top: 1px solid var(--rule);
  font: 400 13px/1.6 var(--mono-font);
  color: var(--ink-2);
}
footer p {
  margin: 0 0 6px;
}

/* Reading pages: privacy policy and support */
.doc .top {
  position: static;
}
.doc .top a[aria-current="page"] {
  opacity: 1;
  text-decoration: underline;
}
.dochead {
  padding-block: clamp(24px, 4vw, 56px) clamp(32px, 4vw, 56px);
}
.dochead h1 {
  margin: 0 0 clamp(20px, 3vw, 36px);
  font: 400 clamp(44px, 5.8vw, 84px) / 1.04 var(--text-font);
  letter-spacing: -0.02em;
  color: var(--title);
}
.docback {
  margin-bottom: clamp(20px, 3vw, 32px);
  font: 500 15px/1.3 var(--key-font);
}
.docdate {
  margin: 0;
  font: 400 14px/1.5 var(--mono-font);
  color: var(--ink-2);
}
.docbody {
  padding-block: clamp(32px, 5vw, 64px) clamp(56px, 8vw, 110px);
  border-top: 1px solid var(--rule);
}
.docbody h2 {
  font: 500 clamp(28px, 1.8vw + 21px, 38px) / 1.12 var(--text-font);
  letter-spacing: -0.012em;
  margin: 1.8em 0 0.5em;
  text-wrap: balance;
}
.docbody h3 {
  font: 500 clamp(21px, 0.6vw + 19px, 25px) / 1.2 var(--text-font);
  letter-spacing: -0.006em;
  margin: 1.6em 0 0.4em;
}
.docbody a {
  overflow-wrap: anywhere;
}
.docbody code {
  font: 400 0.82em/1.4 var(--mono-font);
  overflow-wrap: anywhere;
}
.doctoc {
  margin-bottom: clamp(32px, 5vw, 56px);
  padding-bottom: clamp(24px, 4vw, 40px);
  border-bottom: 1px solid var(--rule);
}
.doctoc ul {
  columns: 2 12em;
  margin: 0;
  padding: 0;
  list-style: none;
}
.doctoc li {
  margin-bottom: 0.3em;
}

/* The page's own little overlay, which counts your scrolling. Fixed to one spot, and it only ever grows to the right. */
.ownlay {
  --u: 0.86px;
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 20;
  width: 110px;
  pointer-events: none;
  display: none;
}
.motion .ownlay {
  display: block;
}
@media (max-width: 899px) {
  .motion .ownlay {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
@media print {
  .ownlay {
    display: none;
  }
}
