/* aloud.world — shared stylesheet for the public pages (landing, privacy,
   terms, support). Tokens mirror the app brand in static/styles.css:
   warm vellum paper, deep ink, gold accent. Dark mode is a warm inversion
   of the same system, driven by prefers-color-scheme only. */

:root {
  --bg: #f5efe2;
  --surface: #fbf6ea;
  --ink: #1c1a16;
  --ink-dim: #5a534b;
  --ink-faint: #9b9180;
  --gold: #a07820;          /* gold-deep from the app — link-safe contrast on vellum */
  --gold-bright: #c89427;
  --line: rgba(28, 26, 22, 0.12);
  --line-strong: rgba(28, 26, 22, 0.25);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #171512;
    --surface: #1f1c18;
    --ink: #ece4d2;
    --ink-dim: #b3a892;
    --ink-faint: #7d7462;
    --gold: #d9a832;
    --gold-bright: #e4b84a;
    --line: rgba(236, 228, 210, 0.14);
    --line-strong: rgba(236, 228, 210, 0.28);
  }
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Charter, 'Iowan Old Style', Georgia, 'Times New Roman', serif;
  font-size: 1.0625rem;
  line-height: 1.65;
}

/* ---- The mark: ALOUD mirrored across a centerline, quoting the app's
        across-the-table layout (the far half of the screen is rotated 180°
        so the person opposite reads their side upright). ---- */

.mark {
  display: inline-block;
  text-align: center;
  text-decoration: none;
  color: inherit;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  line-height: 1;
}
.mark .flip {
  display: block;
  transform: rotate(180deg);
  opacity: 0.22;
  font-weight: 800;
  letter-spacing: 0.32em;
  margin-right: -0.32em; /* re-center: letter-spacing trails the last glyph */
}
.mark .line {
  display: block;
  height: 1px;
  background: var(--line-strong);
  margin: 0.45em 0;
}
.mark .word {
  display: block;
  font-weight: 800;
  letter-spacing: 0.32em;
  margin-right: -0.32em;
}

/* ---- Document pages ---- */

.page {
  max-width: 42rem;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

.page-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 3.5rem;
}
.page-head .mark { font-size: 0.9375rem; }

.page-nav {
  display: flex;
  gap: 1.25rem;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 0.8125rem;
  font-weight: 600;
}
.page-nav a {
  color: var(--ink-dim);
  text-decoration: none;
}
.page-nav a:hover, .page-nav a[aria-current="page"] { color: var(--gold); }

.eyebrow {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 0.75rem;
}

h1 {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.015em;
  line-height: 1.15;
  margin: 0 0 0.5rem;
}

.doc-meta {
  color: var(--ink-faint);
  font-size: 0.9375rem;
  margin: 0 0 2.5rem;
}

h2 {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 1.1875rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 2.5rem 0 0.75rem;
}

p, ul, ol { margin: 0 0 1rem; }
ul, ol { padding-left: 1.375rem; }
li { margin-bottom: 0.375rem; }

a { color: var(--gold); }
a:hover { color: var(--gold-bright); }

strong { font-weight: 700; }

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

.callout {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 1rem 1.25rem;
  margin: 0 0 1rem;
}

hr {
  border: none;
  border-top: 1px solid var(--line);
  margin: 3rem 0 1.5rem;
}

.page-foot {
  color: var(--ink-faint);
  font-size: 0.875rem;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}
.page-foot a { color: var(--ink-dim); text-decoration: none; }
.page-foot a:hover { color: var(--gold); }
.page-foot .links { display: flex; flex-wrap: wrap; gap: 1.25rem; margin-bottom: 0.75rem; }

/* ---- Landing ---- */

.hero {
  min-height: 88vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 1.5rem 2rem;
}
.hero .mark { font-size: clamp(2rem, 8vw, 3.25rem); }
.hero .tagline {
  font-style: italic;
  color: var(--ink-dim);
  font-size: 1.125rem;
  margin: 2rem 0 0.75rem;
}
.hero .blurb {
  max-width: 34rem;
  color: var(--ink-dim);
  margin: 0 auto;
}
.hero .status {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  margin-top: 2.5rem;
}
.hero-foot {
  text-align: center;
  padding: 0 1.5rem 2.5rem;
}
.hero-foot .links { justify-content: center; }

@media (max-width: 480px) {
  .page-head { flex-direction: column; align-items: flex-start; gap: 1.25rem; }
  h1 { font-size: 1.625rem; }
}
