/* prodromus.app: the app's paper and ink (Shared/Palette.swift), its serif, and its wordmark. */

@font-face {
  font-family: "Cormorant Garamond";
  src: url("/fonts/cormorant-garamond-semibold.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}

:root {
  color-scheme: light dark;
  --paper: #f6f1e7;
  --paper-raised: #fcf9f2;
  --ink: #1e1b17;
  --ink-secondary: #6b6358;
  --ink-tertiary: #776d60;
  --rule: #dcd3c3;
  --serif: ui-serif, "New York", Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #12110f;
    --paper-raised: #1c1a17;
    --ink: #ece4d6;
    --ink-secondary: #a69d8f;
    --ink-tertiary: #827b72;
    --rule: #302c27;
  }
}

*, *::before, *::after { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.page {
  max-width: 38rem;
  margin: 0 auto;
  padding: 2.5rem 1.25rem 3rem;
}

/* The masthead: the app's icon and its wordmark, or the publisher's name. */
.masthead {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  margin-bottom: 2.75rem;
  color: inherit;
  text-decoration: none;
}
.masthead img {
  width: 3rem;
  height: 3rem;
  border-radius: 22.5%;
  box-shadow: 0 0 0 1px var(--rule);
}

.wordmark {
  font-family: "Cormorant Garamond", var(--serif);
  font-weight: 600;
  font-variant-caps: small-caps;
  letter-spacing: 0.08em;
  font-size: 1.75rem;
  line-height: 1;
}

h1 {
  font-size: 2rem;
  font-weight: 600;
  line-height: 1.2;
  margin: 0 0 0.5rem;
  text-wrap: balance;
}

/* Section heads in letter-spaced small capitals, as Settings sets them. */
h2 {
  font-family: var(--sans);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-secondary);
  margin: 2.75rem 0 0.75rem;
}

h3 {
  font-size: 1.1875rem;
  font-weight: 600;
  line-height: 1.35;
  margin: 2rem 0 0.375rem;
}

p, ul { margin: 0 0 1rem; }
ul { padding-left: 1.25rem; }
li { margin-bottom: 0.625rem; }
li::marker { color: var(--ink-tertiary); }

a {
  color: inherit;
  text-decoration-line: underline;
  text-decoration-color: var(--ink-tertiary);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}
a:hover { text-decoration-color: currentColor; }

.dateline {
  font-style: italic;
  color: var(--ink-secondary);
  margin-bottom: 2rem;
}

.lede {
  font-size: 1.25rem;
  line-height: 1.5;
}

/* The way to write to us, set apart. */
.contact {
  background: var(--paper-raised);
  border: 1px solid var(--rule);
  border-radius: 0.75rem;
  padding: 1.125rem 1.25rem;
  margin: 1.75rem 0 0.5rem;
}
.contact p:last-child { margin-bottom: 0; }
.contact .address {
  font-size: 1.25rem;
  font-weight: 600;
  overflow-wrap: anywhere;
}

/* Where to find a control in the app. */
.path {
  font-weight: 600;
  white-space: nowrap;
}

/* An app on the publisher's page. */
.app {
  display: flex;
  gap: 1.125rem;
  align-items: flex-start;
  margin-top: 1.5rem;
}
.app img {
  flex: none;
  width: 4.5rem;
  height: 4.5rem;
  border-radius: 22.5%;
  box-shadow: 0 0 0 1px var(--rule);
}
.app .wordmark { font-size: 1.625rem; display: block; margin: 0.25rem 0 0.5rem; }
.app p { margin-bottom: 0.5rem; }
.links {
  font-family: var(--sans);
  font-size: 0.9375rem;
}
.links a + a { margin-left: 1.125rem; }

footer {
  margin-top: 3.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--rule);
  font-family: var(--sans);
  font-size: 0.875rem;
  color: var(--ink-tertiary);
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
}
footer a { color: var(--ink-secondary); }
