/*
 * SteadyCal — web
 *
 * Every colour here is copied from `src/theme/index.ts`, which took them from
 * the key art. The app and the site have to read as one product (HANDOVER §5),
 * so if the palette moves in the app it moves here too. There is deliberately no
 * build step: a policy page that needs compiling is a policy page that stops
 * being updated.
 */

:root {
  --ink: #0a0328;
  --surface: #120939;
  --surface-raised: #1c0e4e;
  --border: #2a1263;
  --text: #f4f1ff;
  --text-muted: #a99fd0;
  --text-faint: #6e62a0;
  --accent: #82e9c0;
  --accent-bright: #acf5cf;
  --accent-dim: #3e7f68;
  --aqua: #4cc9f0;

  --measure: 42rem;
  --radius: 14px;
}

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

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

body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font: 400 17px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Helvetica, Arial, sans-serif;
  overflow-wrap: break-word;
}

.wrap {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 2.5rem 1.25rem 5rem;
}

.wrap--wide {
  max-width: 58rem;
}

/* ---------- masthead ---------- */

header.site {
  border-bottom: 1px solid var(--border);
}

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

.brand {
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
  color: var(--text);
  text-decoration: none;
}

.brand span {
  color: var(--accent);
}

nav.site a {
  color: var(--text-muted);
  text-decoration: none;
  margin-left: 1.25rem;
  font-size: 0.95rem;
}

nav.site a:hover,
nav.site a:focus-visible {
  color: var(--accent);
}

/* ---------- type ---------- */

h1 {
  font-size: clamp(2rem, 6vw, 2.9rem);
  line-height: 1.12;
  letter-spacing: -0.025em;
  margin: 0 0 0.6rem;
}

h2 {
  font-size: 1.3rem;
  letter-spacing: -0.01em;
  margin: 2.75rem 0 0.75rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

h3 {
  font-size: 1.05rem;
  margin: 1.75rem 0 0.5rem;
  color: var(--accent-bright);
}

.lede {
  font-size: 1.15rem;
  color: var(--text-muted);
  margin: 0 0 2rem;
}

.updated {
  color: var(--text-faint);
  font-size: 0.9rem;
  margin: 0 0 2.5rem;
}

p,
li {
  color: var(--text-muted);
}

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

a {
  color: var(--accent);
}

a:hover,
a:focus-visible {
  color: var(--accent-bright);
}

ul {
  padding-left: 1.15rem;
}

li {
  margin-bottom: 0.5rem;
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.9em;
  background: var(--surface-raised);
  padding: 0.1em 0.4em;
  border-radius: 5px;
  color: var(--accent-bright);
}

/* ---------- table ---------- */

.scroller {
  overflow-x: auto;
  margin: 1.25rem 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

table {
  border-collapse: collapse;
  width: 100%;
  min-width: 34rem;
  font-size: 0.95rem;
}

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

th {
  background: var(--surface);
  color: var(--text);
  font-weight: 600;
  white-space: nowrap;
}

tr:last-child td {
  border-bottom: 0;
}

/* ---------- cards ---------- */

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

.card h3 {
  margin-top: 0;
}

.card :last-child {
  margin-bottom: 0;
}

.grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  margin: 2rem 0;
}

/* ---------- landing ---------- */

.hero {
  padding: 4rem 0 1rem;
  text-align: center;
}

.hero .lede {
  max-width: 34rem;
  margin-inline: auto;
}

.badge {
  display: inline-block;
  border: 1px solid var(--accent-dim);
  color: var(--accent);
  border-radius: 999px;
  padding: 0.3rem 0.9rem;
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.confirm-mark {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  display: grid;
  place-items: center;
  margin: 0 auto 1.5rem;
  color: var(--accent);
  font-size: 2rem;
  line-height: 1;
}

/* ---------- notices ---------- */

.notice {
  border-left: 3px solid var(--aqua);
  background: var(--surface);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1rem 1.25rem;
  margin: 1.75rem 0;
  font-size: 0.97rem;
}

/*
 * Unfilled placeholder. Loud on purpose: a privacy policy that ships with
 * "[your name here]" in it is worse than no policy, so this must be impossible
 * to miss on the rendered page rather than only in the source.
 */
.todo {
  background: #ffd166;
  color: #2a1263;
  font-weight: 700;
  padding: 0.1em 0.45em;
  border-radius: 5px;
}

/* ---------- footer ---------- */

footer.site {
  border-top: 1px solid var(--border);
  color: var(--text-faint);
  font-size: 0.9rem;
}

footer.site .wrap {
  padding-top: 2rem;
  padding-bottom: 3rem;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

footer.site a {
  color: var(--text-muted);
  text-decoration: none;
  margin-right: 1.25rem;
}

footer.site a:hover {
  color: var(--accent);
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}
