/* Liahona Connect — shared site styles.
   Mirrors the app's palette (constants/theme.ts) and its quiet, accessible feel:
   plain words, generous targets, AA contrast, light + dark. */

:root {
  --primary: #3b82f6;
  --primary-dark: #1d4ed8;
  --bg: #f3f4f6;
  --surface: #ffffff;
  --border: #e5e7eb;
  --text: #111827;
  --text-secondary: #4b5563;
  /* Inline links in body copy. --primary (#3b82f6) is only 3.1:1 on white, so the
     darker shade carries text-sized links. */
  --link: #1d4ed8;
  --going: #047857;
  --radius: 16px;
  --maxw: 720px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111827;
    --surface: #1f2937;
    --border: #374151;
    --text: #f9fafb;
    --text-secondary: #cbd5e1;
    /* The light-mode link inverted: a dark blue on a dark card is unreadable. */
    --link: #93c5fd;
  }
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  font-size: 17px;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 24px 20px 64px;
}

header.site {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px;
  max-width: var(--maxw);
  margin: 0 auto;
}

header.site a.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
  font-weight: 800;
  font-size: 18px;
}

.compass {
  width: 36px;
  height: 36px;
  /* The header mark is the real app icon — round the square art like an
     app-icon chip so it reads as the same brand as the phone. */
  border-radius: 9px;
  flex: none;
}

h1 { font-size: 30px; line-height: 1.25; margin: 8px 0 6px; }
h2 { font-size: 21px; margin: 32px 0 8px; }
p { margin: 0 0 14px; }
.lede { font-size: 19px; color: var(--text-secondary); }
.muted { color: var(--text-secondary); }
.small { font-size: 14px; }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  margin: 18px 0;
}

.code-box {
  border: 2px dashed var(--primary);
  border-radius: var(--radius);
  padding: 18px 14px;
  text-align: center;
  background: var(--surface);
  margin: 18px 0;
}

.code {
  font-size: clamp(20px, 6vw, 30px);
  font-weight: 900;
  letter-spacing: 1px;
  word-break: break-word;
  margin: 0;
}

a.btn, button.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 22px;
  border-radius: 12px;
  border: 0;
  background: var(--primary);
  color: #fff;
  font-size: 17px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  width: 100%;
  margin-bottom: 12px;
  font-family: inherit;
}

a.btn:hover, button.btn:hover { background: var(--primary-dark); }

a.btn.secondary, button.btn.secondary {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
}

/* Body-copy links had NO rule, so every one of them fell back to the browser default
   #0000EE — 1.56:1 against the dark card, failing AA badly on the privacy and
   account-deletion pages a reviewer reads. .btn and footer.site a override this. */
a:not(.btn) { color: var(--link); }

a:focus-visible, button:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
}

ol.steps { padding-left: 22px; margin: 0; }
ol.steps li { margin-bottom: 10px; }

/* ol too — the update page's steps are numbered, and unnumbered steps read as a
   list of options rather than an order to follow. */
ul.plain, ol.plain { padding-left: 22px; }
ul.plain li, ol.plain li { margin-bottom: 8px; }

footer.site {
  border-top: 1px solid var(--border);
  margin-top: 40px;
  padding: 22px 20px 40px;
  max-width: var(--maxw);
  margin-left: auto;
  margin-right: auto;
  color: var(--text-secondary);
  font-size: 14px;
}

footer.site a { color: var(--text-secondary); }

.badges {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin: 8px 0 4px;
}

.badge {
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
}
