/*
  The same palette as the app (src/Leanback/App.xaml). A rider arriving here from a store listing or
  from Settings ▸ PRIVACY POLICY should land somewhere that plainly belongs to the app they just
  left — the store review guidelines care that the policy is reachable, but a page that looks like a
  different product is exactly what makes people abandon a deletion request half way through.
*/
:root {
  --bg-deep: #02060a;
  --bg: #050b0f;
  --panel: #0a1218;
  --stroke: #26333b;
  --text: #e8f1f5;
  --muted: #8fa3ad;
  --balance: #ffa600;
  --safe: #3ddc84;
  --danger: #ff4d4d;
  --measure: 44rem;
}

* { box-sizing: border-box; }

html {
  /* The one hard requirement of a policy page: it has to be readable on the phone it opened on. */
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  padding: 0 1.25rem 5rem;
  background: radial-gradient(120% 80% at 50% 0%, #0b1a24 0%, var(--bg) 45%, var(--bg-deep) 100%);
  background-attachment: fixed;
  color: var(--text);
  font: 16px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.wrap { max-width: var(--measure); margin: 0 auto; }

/* --- header ---------------------------------------------------------------- */
header { padding: 2.5rem 0 1.5rem; }
header a { display: inline-block; }
header img { height: 26px; width: auto; display: block; }

nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  margin-top: 1.25rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--stroke);
  font-size: 0.8125rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
nav a { color: var(--muted); text-decoration: none; }
nav a:hover, nav a[aria-current="page"] { color: var(--balance); }

/* --- type ------------------------------------------------------------------ */
h1 { font-size: 2rem; line-height: 1.2; margin: 2rem 0 0.5rem; }
h2 {
  font-size: 0.9375rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--balance);
  margin: 2.5rem 0 0.75rem;
}
h3 { font-size: 1rem; margin: 1.5rem 0 0.5rem; }
p, li { color: #cddbe2; }
.lede { font-size: 1.0625rem; color: var(--text); }
.muted { color: var(--muted); font-size: 0.875rem; }
a { color: var(--balance); }
ul { padding-left: 1.25rem; }
li { margin: 0.35rem 0; }
code, .code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  background: var(--bg-deep);
  border: 1px solid var(--stroke);
  border-radius: 6px;
  padding: 0.1rem 0.35rem;
  font-size: 0.9em;
}

table { border-collapse: collapse; width: 100%; margin: 1rem 0; font-size: 0.9375rem; }
th, td { text-align: left; padding: 0.6rem 0.75rem; border-bottom: 1px solid var(--stroke); vertical-align: top; }
th { color: var(--muted); font-weight: 600; font-size: 0.8125rem; text-transform: uppercase; letter-spacing: 0.06em; }

/* --- panels ---------------------------------------------------------------- */
.panel {
  background: var(--panel);
  border: 1px solid var(--stroke);
  border-radius: 16px;
  padding: 1.5rem;
  margin: 1.5rem 0;
}
.panel.warn { border-color: rgba(255, 77, 77, 0.45); }
.panel h2:first-child, .panel h3:first-child { margin-top: 0; }

/* --- form ------------------------------------------------------------------ */
label { display: block; font-size: 0.8125rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin-bottom: 0.5rem; }
input[type="text"] {
  width: 100%;
  padding: 0.9rem 1rem;
  background: var(--bg-deep);
  border: 1px solid var(--stroke);
  border-radius: 12px;
  color: var(--text);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 1.0625rem;
  letter-spacing: 0.08em;
}
input[type="text"]:focus { outline: 2px solid var(--balance); outline-offset: 1px; }

.confirm { display: flex; gap: 0.75rem; align-items: flex-start; margin: 1.25rem 0; }
.confirm input { margin-top: 0.3rem; width: 1.1rem; height: 1.1rem; accent-color: var(--danger); flex: none; }
.confirm label { text-transform: none; letter-spacing: 0; font-size: 0.9375rem; color: #cddbe2; margin: 0; }

button {
  width: 100%;
  padding: 1rem;
  border: 0;
  border-radius: 12px;
  background: var(--danger);
  color: #fff;
  font-size: 0.9375rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
}
button:disabled { background: #2a3238; color: var(--muted); cursor: not-allowed; }

/* Assertive because it is announced by a live region: the result of a destructive, irreversible
   action is the one thing on this site nobody should have to hunt for. */
.result { margin-top: 1.25rem; padding: 1rem 1.25rem; border-radius: 12px; border: 1px solid var(--stroke); }
.result:empty { display: none; }
.result.ok { border-color: var(--safe); color: var(--safe); }
.result.bad { border-color: var(--danger); color: #ff8a8a; }
.result.busy { color: var(--muted); }

footer {
  margin-top: 4rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--stroke);
  color: var(--muted);
  font-size: 0.8125rem;
}
footer a { color: var(--muted); }
