/* The type and palette of nagel.se, with Kabelpost's blue as the accent. */
@font-face {
  font-family: InterVariable;
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/fonts/InterVariable.woff2") format("woff2");
}
@font-face {
  font-family: "Instrument Serif";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/InstrumentSerif-Regular.woff2") format("woff2");
}

:root {
  --paper: #f5f7f9;
  --ink: #0f141a;
  --ink2: #56606b;
  --ink3: #96a0aa;
  --rule: #dfe4ea;
  --accent: #0067c0;
  --serif: "Instrument Serif", Georgia, serif;
  --pad: clamp(1rem, 4vw, 3rem);
  font-family: InterVariable, system-ui, -apple-system, "Segoe UI", sans-serif;
  font-feature-settings: "cv11", "ss03";
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0d1117;
    --ink: #e6ebf0;
    --ink2: #9aa5b1;
    --ink3: #5d6874;
    --rule: #242c36;
    --accent: #6cb8f6;
  }
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); }
a { color: var(--accent); text-underline-offset: 0.15em; }
a:hover { text-decoration-thickness: 2px; }

.top, main, footer {
  max-width: 44rem;
  margin: 0 auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
}

.top {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  align-items: center;
  justify-content: space-between;
  padding-top: 1.5rem;
  padding-bottom: 1.5rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}
.top nav { display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; }
.top nav a { color: var(--ink2); text-decoration: none; }
.top nav a:hover, .top nav a[aria-current="page"] { color: var(--ink); }

main { padding-bottom: 3rem; }

h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.5rem, 8vw, 4rem);
  line-height: 1.05;
  letter-spacing: -0.01em;
  margin: 2rem 0 1rem;
}
h1 em { color: var(--ink2); }
h2 {
  font-size: 1.125rem;
  margin: 2.5rem 0 0.5rem;
}
.lead { font-size: 1.2rem; color: var(--ink2); margin: 0 0 2rem; }
.meta { color: var(--ink3); font-size: 0.9rem; }

.note {
  border-left: 3px solid var(--accent);
  padding: 0.25rem 0 0.25rem 1rem;
  color: var(--ink2);
  margin: 1.5rem 0;
}

ul { padding-left: 1.25rem; }
li { margin: 0.35rem 0; }
code {
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  font-size: 0.9em;
  background: var(--rule);
  border-radius: 4px;
  padding: 0.05em 0.3em;
  overflow-wrap: anywhere;
}

footer {
  border-top: 1px solid var(--rule);
  padding-top: 1.25rem;
  padding-bottom: 2rem;
  color: var(--ink3);
  font-size: 0.9rem;
}
