/* The app's own colours (Packages/DesignSystem, Media.xcassets): the app is
   dark only, so dark is the default here and light is the page's own. */
:root {
  --bg: #141013;
  --surface: #1c161a;
  --text: #f7f1ee;
  --text-2: #a89fa1;
  --rule: rgba(255, 255, 255, 0.1);
  --accent: #f5333f;
  --link: #ff6b73;
  --serif: ui-serif, "New York", Georgia, "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #faf6f4;
    --surface: #f1ebe8;
    --text: #1a1416;
    --text-2: #5f5658;
    --rule: rgba(0, 0, 0, 0.1);
    --link: #c41f2b;
  }
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 var(--sans);
}

a { color: var(--link); text-underline-offset: 0.15em; }
a:hover { text-decoration-thickness: 2px; }

.bar, .doc, footer, .hero {
  max-width: 44rem;
  margin: 0 auto;
  padding-left: 16px;
  padding-right: 16px;
}

.bar {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--rule);
}

.brand {
  font: 600 22px/1 var(--serif);
  color: var(--text);
  text-decoration: none;
}
.brand::after { content: "."; color: var(--accent); }

nav { display: flex; gap: 20px; }
nav a { color: var(--text-2); text-decoration: none; font-size: 15px; }
nav a:hover, nav a[aria-current="page"] { color: var(--text); }

.doc { padding-top: 32px; padding-bottom: 48px; }

h1 {
  font: 600 clamp(32px, 7vw, 44px)/1.15 var(--serif);
  margin: 0 0 8px;
}

h2 {
  font: 600 22px/1.3 var(--serif);
  margin: 40px 0 8px;
}

.updated { color: var(--text-2); font-size: 15px; margin: 0 0 32px; }

p, ul { margin: 0 0 16px; }
ul { padding-left: 22px; }
li { margin-bottom: 8px; }
li ul { margin-top: 8px; }

code {
  font: 0.9em var(--mono);
  background: var(--surface);
  padding: 1px 5px;
  border-radius: 4px;
}

a { overflow-wrap: anywhere; }

footer {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  padding-top: 20px;
  padding-bottom: 40px;
  border-top: 1px solid var(--rule);
  color: var(--text-2);
  font-size: 15px;
}

.hero { padding-top: 72px; padding-bottom: 72px; }
.hero h1 { font-size: clamp(40px, 10vw, 64px); }
.hero h1 span { color: var(--accent); }
.lede { font-size: 20px; color: var(--text-2); max-width: 32rem; margin-bottom: 32px; }
