/* Cmd-R site. Colors come from the app icon; one bold moment (the panel typing), the rest quiet. */
:root {
  --ink: #1e1b4b;
  --ink-soft: #4b4975;
  --accent: #4338ca;
  --accent-2: #6366f1;
  --mist: #f4f4fb;
  --paper: #ffffff;
  --line: #dddcf0;
  --key: #f7f7fd;
  --key-edge: #c9c8e6;
  --panel: #1b1a3d;
  --panel-ink: #eceaff;
  --panel-soft: #a9a7d6;
  --panel-line: #2f2d5e;
  --panel-select: #4338ca;
  --code-bg: #1b1a3d;
  --code-ink: #e6e4ff;
  --display: "Bricolage Grotesque", system-ui, sans-serif;
  --body: "Atkinson Hyperlegible", system-ui, sans-serif;
  --code: ui-monospace, "SF Mono", Menlo, monospace;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #e9e8ff;
    --ink-soft: #b4b2dc;
    --accent: #a5b4fc;
    --accent-2: #818cf8;
    --mist: #0f0e24;
    --paper: #18173a;
    --line: #2c2a58;
    --key: #24224d;
    --key-edge: #3a3870;
    --panel: #0a0a1c;
    --panel-line: #24224a;
    --code-bg: #0a0a1c;
  }
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--mist);
  color: var(--ink);
  font: 18px/1.6 var(--body);
}

a { color: var(--accent); text-underline-offset: 0.18em; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--accent-2); outline-offset: 3px; border-radius: 4px; }
code { font-family: var(--code); font-size: 0.9em; }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 24px; }
.prose { max-width: 38rem; }

header.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0;
}
.brand { display: flex; flex-shrink: 0; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font: 600 20px/1 var(--display); }
.brand img { width: 32px; height: 32px; border-radius: 8px; }
header.top nav { display: flex; gap: 20px; }
header.top nav a { color: var(--ink-soft); text-decoration: none; white-space: nowrap; }
header.top nav a:hover { color: var(--ink); }

/* Keycaps, used in the headline and the keys list. */
kbd {
  display: inline-block;
  min-width: 1.9em;
  padding: 0.08em 0.45em 0.14em;
  border: 1px solid var(--key-edge);
  border-bottom-width: 3px;
  border-radius: 0.4em;
  background: var(--key);
  color: var(--ink);
  font: 600 0.85em/1.4 var(--code);
  text-align: center;
  white-space: nowrap;
}

/* Hero */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 48px;
  align-items: end;
  padding: 56px 0 40px;
}
h1 {
  margin: 0 0 24px;
  font: 800 clamp(48px, 8.5vw, 104px)/0.98 var(--display);
  letter-spacing: -0.035em;
  color: var(--accent);
}
h1 kbd { font-size: 0.62em; vertical-align: 0.12em; border-radius: 0.22em; border-bottom-width: 0.11em; padding: 0.02em 0.28em 0.08em; }
h1 .return { transform-origin: 50% 100%; }
.js h1 .return { animation: press 520ms ease 1900ms both; }
@keyframes press {
  0%, 100% { transform: none; }
  35% { transform: translateY(0.07em); border-bottom-width: 0.03em; }
}
.lede { margin: 0; max-width: 33rem; font-size: 21px; color: var(--ink-soft); }

.download {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 28px;
}
.download h2 { margin: 0 0 4px; font: 700 22px/1.2 var(--display); }
.download .meta { margin: 0 0 20px; color: var(--ink-soft); font-size: 15px; }
.button {
  display: block;
  padding: 16px 20px;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  text-align: center;
  text-decoration: none;
  font: 700 19px/1.2 var(--display);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .button { color: #121037; }
  :root:not([data-theme="light"]) .button.is-pending { color: var(--ink-soft); }
}
.button:hover { background: var(--accent-2); }
.button.is-pending, .button.is-pending:hover { background: var(--line); color: var(--ink-soft); cursor: default; }
.download .small { margin: 16px 0 0; font-size: 15px; color: var(--ink-soft); }

/* The panel demo: what you see after pressing ⌘R. */
.demo { margin: 0 0 72px; }
.panel {
  max-width: 760px;
  margin: 0 auto;
  border-radius: 18px;
  background: var(--panel);
  color: var(--panel-ink);
  box-shadow: 0 30px 60px -30px rgba(30, 27, 75, 0.55), 0 0 0 1px var(--panel-line);
  overflow: hidden;
}
.panel .field {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 22px;
  border-bottom: 1px solid var(--panel-line);
  font: 24px/1.3 var(--code);
}
.panel .field svg { flex-shrink: 0; width: 24px; height: 24px; color: var(--panel-soft); }
.panel .typed { min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.panel .caret { display: inline-block; width: 2px; height: 1.1em; margin-left: 1px; vertical-align: -0.15em; background: var(--accent-2); }
.js .panel .caret { animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.panel ul { margin: 0; padding: 8px; list-style: none; min-height: 206px; }
.panel li { display: flex; align-items: center; gap: 14px; padding: 10px 14px; border-radius: 10px; }
.panel li.selected { background: var(--panel-select); }
.panel li .icon { flex-shrink: 0; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; background: var(--panel-line); font-size: 17px; }
.panel li.selected .icon { background: rgba(255, 255, 255, 0.16); }
.panel li .text { min-width: 0; flex: 1; }
.panel li .title { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.panel li .sub { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; color: var(--panel-soft); font-size: 14px; }
.panel li.selected .sub { color: #d6d4ff; }
.panel li .hint { flex-shrink: 0; color: var(--panel-soft); font: 14px var(--code); }
.panel li.selected .hint { color: #fff; }
.panel .foot { display: flex; gap: 18px; flex-wrap: wrap; padding: 10px 22px; border-top: 1px solid var(--panel-line); color: var(--panel-soft); font-size: 13px; }
.demo figcaption { margin: 14px auto 0; max-width: 760px; color: var(--ink-soft); font-size: 15px; text-align: center; }

/* Sections */
section { padding: 64px 0; border-top: 1px solid var(--line); }
h2.section { margin: 0 0 12px; font: 700 clamp(30px, 4vw, 42px)/1.1 var(--display); letter-spacing: -0.02em; }
h3 { margin: 0 0 6px; font: 700 21px/1.25 var(--display); }

.ways { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; margin-top: 36px; }
.ways p { margin: 0; color: var(--ink-soft); }

/* What you can type: the example is the heading. */
.types { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 36px 0 0; padding: 0; list-style: none; }
.types li { min-width: 0; padding: 20px 22px; border: 1px solid var(--line); border-radius: 16px; background: var(--paper); }
.types .ex { display: block; margin: 0 0 6px; overflow-wrap: anywhere; color: var(--accent); font: 600 17px/1.45 var(--code); }
.types p { margin: 0; color: var(--ink-soft); font-size: 16px; }

.keys { margin: 32px 0 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 48px; max-width: 54rem; }
.keys div { display: grid; grid-template-columns: 7.5rem 1fr; gap: 16px; align-items: baseline; padding: 12px 0; border-bottom: 1px solid var(--line); }
.keys dt { white-space: nowrap; }
.keys dd { margin: 0; color: var(--ink-soft); }

.words { display: flex; flex-wrap: wrap; gap: 10px; margin: 28px 0 0; padding: 0; list-style: none; max-width: 50rem; }
.words li { padding: 6px 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); font: 15px/1.4 var(--code); }

.privacy {
  margin: 8px 0 64px;
  padding: 56px clamp(24px, 6vw, 72px);
  border: 0;
  border-radius: 28px;
  background: var(--accent);
  color: #fff;
}
.privacy + section { border-top: 0; }
.privacy h2.section { color: #fff; }
.privacy p { max-width: 40rem; font-size: 20px; }
.privacy .promise { font: 700 clamp(24px, 3vw, 32px)/1.3 var(--display); max-width: 34rem; }
.privacy a { color: #fff; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .privacy { background: #2e2a8a; }
}

/* Verify: a real sequence, so it's numbered. */
.steps { counter-reset: step; margin: 32px 0 0; padding: 0; list-style: none; max-width: 46rem; }
.steps > li { counter-increment: step; position: relative; min-width: 0; padding: 0 0 32px 56px; }
.steps > li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--paper);
  border: 2px solid var(--accent-2);
  color: var(--accent);
  font: 700 17px/32px var(--display);
  text-align: center;
}
.steps p { margin: 4px 0 10px; color: var(--ink-soft); }
pre {
  margin: 0 0 10px;
  padding: 14px 16px;
  overflow-x: auto;
  border-radius: 10px;
  background: var(--code-bg);
  color: var(--code-ink);
  font: 14px/1.55 var(--code);
}
pre code { font-size: inherit; }
.expect { font-size: 15px; overflow-wrap: anywhere; }
.facts { margin: 24px 0 0; display: grid; grid-template-columns: max-content 1fr; gap: 6px 20px; max-width: 46rem; }
.facts dt { color: var(--ink-soft); }
.facts dd { margin: 0; word-break: break-all; }
.facts dd.mono { font: 14px/1.6 var(--code); }
section.first { border-top: 0; padding-top: 24px; }

footer { padding: 40px 0 56px; border-top: 1px solid var(--line); color: var(--ink-soft); font-size: 15px; }
footer a { color: var(--ink-soft); }

@media (prefers-reduced-motion: reduce) {
  .js h1 .return, .js .panel .caret { animation: none; }
}

@media (max-width: 820px) {
  .hero { grid-template-columns: minmax(0, 1fr); gap: 32px; padding-top: 24px; }
  .ways, .types, .keys { grid-template-columns: minmax(0, 1fr); }
  .ways { gap: 28px; }
  .facts { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .facts dd { margin-bottom: 10px; }
}
/* Phones: shorter links on one line, a smaller panel. */
@media (max-width: 560px) {
  header.top nav .long { display: none; }
  header.top nav { gap: 16px; }
  .panel .field { padding: 14px 16px; font-size: 18px; }
  .panel li { padding: 9px 10px; }
  .panel li .hint, .panel .foot .optional { display: none; }
  .keys div { grid-template-columns: 6rem 1fr; }
}
@media (max-width: 420px) {
  .wrap { padding: 0 16px; }
  header.top nav .optional { display: none; }
}
