/* The Prompter — legal pages (Terms, Privacy).
   Deliberately plainer than the app: these are read, not played. Same palette,
   same type, less decoration. */

:root {
  color-scheme: light;
  --ink: #1c1917;
  --ink-soft: #57534e;
  --cream: #f7f1e6;
  --paper: #fffcf6;
  --surface: #ffffff;
  --line: #e2d3ba;
  --line-soft: #efe3cf;
  --danger: #e58a79;
  --season: #f6c6d6;
  --season-ink: #8a6f7a;
  /* Same one-family approach as the app: headings and body share Bricolage
     Grotesque, so the legal pages match the tool they belong to. */
  --font-sans: "Bricolage Grotesque", "Space Grotesk", system-ui, -apple-system, sans-serif;
  --font-display: "Bricolage Grotesque", "Space Grotesk", system-ui, sans-serif;
}

/* The same warm-dark palette as the app, so a link from a dark app into Terms
   does not flash back to paper. theme.js writes the resolved choice to
   <html data-theme>, which also covers a manual Light/Dark override. These
   pages have no seasonal data attribute, so the winter accent is the neutral
   choice. */
:root[data-theme="dark"] {
  color-scheme: dark;
  --ink: #ece5d8;
  --ink-soft: #b3aa9c;
  --cream: #14171b;
  --paper: #20252b;
  --surface: #20252b;
  --line: #3a424c;
  --line-soft: #2f363f;
  --danger: #f08b78;
  --season: #33495e;
  --season-ink: #a9c9e0;
}

* { box-sizing: border-box; }

html, body { margin: 0; height: 100%; }

body {
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.page {
  max-width: 720px;
  margin: 0 auto;
  padding: 34px 22px 90px;
}

/* ---------- Header ---------- */
.legal-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 26px;
}

.brand-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 18px;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.back {
  margin-left: auto;
  font-size: 12px;
  color: var(--ink-soft);
  text-decoration: none;
  border-bottom: 1px dotted var(--line);
  white-space: nowrap;
}
.back:hover { color: var(--ink); border-bottom-style: solid; }

/* ---------- Type ---------- */
h1 {
  font-size: 26px;
  letter-spacing: -0.02em;
  margin: 0 0 4px;
}
.subtitle { color: var(--ink-soft); font-size: 13px; margin: 0 0 8px; }
.updated { font-size: 11px; color: var(--ink-soft); margin: 0 0 30px; }

h2 {
  font-size: 15px;
  font-weight: 700;
  margin: 30px 0 8px;
  padding-bottom: 5px;
  border-bottom: 1px solid var(--line-soft);
}
h2:first-of-type { margin-top: 0; }

p { margin: 0 0 12px; }
ul { margin: 0 0 12px; padding-left: 20px; }
li { margin: 5px 0; }

a { color: var(--ink); text-decoration-color: var(--line); }
a:hover { text-decoration-color: var(--ink); }

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px 15px;
  margin: 0 0 20px;
}
.card p:last-child { margin-bottom: 0; }
.card .label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--season-ink);
  margin-bottom: 5px;
}

/* Contact handles. The Discord blurple is the brand colour; everything else on
   these pages stays in the app's own palette. */
.contact-line { margin: 14px 0 4px; }

.contact {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 13px 6px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
}
.contact-logo { width: 17px; height: 17px; display: block; flex: 0 0 auto; }
.contact.discord { border-color: #5865f2; color: #5865f2; }
.contact.discord:hover { background: #5865f2; color: #fff; }
.contact.discord:hover .contact-logo { color: #fff; }
.contact.discord:focus-visible { outline: 3px solid #5865f2; outline-offset: 2px; }

/* ---------- Credits ---------- */
.role {
  display: flex;
  gap: 16px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px 16px;
  margin: 0 0 12px;
}
.role-label {
  flex: 0 0 84px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--season-ink);
  padding-top: 3px;
}
.role-body { min-width: 0; flex: 1 1 auto; }
.role-name { font-size: 16px; font-weight: 700; margin-bottom: 3px; }
.role-note { font-size: 14px; color: var(--ink-soft); margin: 0; }
.role-body .contact-line { margin: 10px 0 0; }

@media (max-width: 560px) {
  .role { flex-direction: column; gap: 6px; }
  .role-label { flex: none; }
}

/* Small display-font text: the odd quiet line that wants a voice just above
   the body copy. */
.display {
  font-family: var(--font-display);
  font-size: 13px;
  line-height: 1.7;
  letter-spacing: 0.01em;
}

.note {
  font-size: 13px;
  color: var(--ink-soft);
  border-left: 3px solid var(--line);
  padding: 2px 0 2px 12px;
  margin: 0 0 20px;
}

.foot {
  margin-top: 40px;
  padding-top: 16px;
  border-top: 1px dashed var(--line-soft);
  font-size: 12px;
  color: var(--ink-soft);
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}
.foot a { color: var(--ink-soft); }

@media (max-width: 560px) {
  .page { padding: 22px 16px 70px; }
  h1 { font-size: 21px; }
  .back { display: none; }
}

/* ---------- Status page ---------- */
.status-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: var(--ink-soft);
  margin: 0 0 22px;
}
.status-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0 0 4px;
}
.status-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 12px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px 14px;
}
.status-row .dot {
  width: 10px;
  height: 10px;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: var(--line-soft);
}
.status-row .dot.online { background: #b7d8a8; }
.status-row .dot.offline { background: var(--danger); }
.status-name {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1 1 auto;
}
.status-model { font-weight: 700; font-size: 14px; }
.status-provider {
  font-size: 11px;
  color: var(--ink-soft);
  letter-spacing: 0.02em;
}
.status-time {
  flex: 0 0 auto;
  font-size: 13px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}
.status-row.is-down .status-time { color: var(--danger); }
/* The online dot is the one literal colour on these pages; on the dark paper the
   light spring green is too pale, so it gets a deeper one. Declared after the
   base rule because the palette block above cannot win on source order alone. */
:root[data-theme="dark"] .status-row .dot.online { background: #6f9d65; }
/* A long error message gets its own line under the name. */
.status-time.is-error {
  flex: 1 1 100%;
  font-size: 11.5px;
  font-weight: 400;
  text-align: right;
}
