/* The site's only stylesheet: no web fonts, no scripts, nothing fetched from anywhere else. The colours are the app's
   own light and dark themes (shared/src/commonMain/composeResources/files/themes). */
:root {
  color-scheme: light dark;
  --background: #faf8f5;
  --surface: #ffffff;
  --raised: #f2eee8;
  --border: #e2dcd2;
  --text: #1c1b1f;
  --text-secondary: #4a4950;
  --primary: #a65f00;
  --on-primary: #ffffff;
}

@media (prefers-color-scheme: dark) {
  :root {
    --background: #121316;
    --surface: #18191d;
    --raised: #202127;
    --border: #2b2c33;
    --text: #ececef;
    --text-secondary: #b4b5bc;
    --primary: #f4a640;
    --on-primary: #121316;
  }
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font: 1rem/1.6 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

a {
  color: var(--primary);
  text-underline-offset: 0.15em;
}

a:hover {
  text-decoration-thickness: 2px;
}

:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
  border-radius: 2px;
}

.page {
  max-width: 44rem;
  margin: 0 auto;
  padding: 0 1rem;
}

header.site {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  padding-top: 1.25rem;
  padding-bottom: 1.25rem;
}

header.site .brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--text);
  font-weight: 700;
  font-size: 1.125rem;
  text-decoration: none;
}

header.site .brand img {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.6rem;
}

header.site nav {
  display: flex;
  gap: 1.25rem;
}

header.site nav a {
  display: inline-block;
  padding: 0.5rem 0;
  color: var(--text-secondary);
}

header.site nav a[aria-current="page"] {
  color: var(--text);
  font-weight: 600;
}

main {
  padding-bottom: 2rem;
}

h1 {
  margin: 1rem 0 0.5rem;
  font-size: 2rem;
  line-height: 1.2;
}

h2 {
  margin: 2.25rem 0 0.5rem;
  font-size: 1.375rem;
  line-height: 1.3;
}

h3 {
  margin: 1.5rem 0 0.25rem;
  font-size: 1.0625rem;
}

p,
ul,
ol {
  margin: 0.5rem 0 1rem;
}

li {
  margin: 0.25rem 0;
}

.lead {
  color: var(--text-secondary);
  font-size: 1.1875rem;
}

.meta {
  color: var(--text-secondary);
  font-size: 0.9375rem;
}

.summary {
  margin: 1.5rem 0;
  padding: 0.25rem 1.25rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
}

.summary h2 {
  margin-top: 1rem;
}

table {
  width: 100%;
  margin: 0.5rem 0 1.5rem;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

th,
td {
  padding: 0.6rem 0.75rem;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--text-secondary);
  font-weight: 600;
}

.scroll {
  overflow-x: auto;
}

details {
  margin: 0.5rem 0;
  padding: 0.25rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
}

summary {
  padding: 0.5rem 0;
  font-weight: 600;
  cursor: pointer;
}

details[open] summary {
  margin-bottom: 0.25rem;
}

code {
  padding: 0.1rem 0.35rem;
  background: var(--raised);
  border-radius: 0.3rem;
  font: 0.9em ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

footer.site {
  padding-top: 1.5rem;
  padding-bottom: 2.5rem;
  border-top: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 0.875rem;
}

footer.site p {
  margin: 0.5rem 0;
}

@media (max-width: 30rem) {
  h1 {
    font-size: 1.625rem;
  }
}
