/* Trust Star legal pages. Colours follow the Android app (ui/theme/Tokens.kt). */

:root {
  --sky-top: #cfe6f6;
  --sky-bottom: #fbf7ec;
  --bg: #fbf7ec;
  --card: #ffffff;
  --outline: #e7dfcb;
  --ink: #15213f;
  --ink-muted: #5b6580;
  --primary: #1f7a4d;
  --primary-soft: #e3f2ea;
  --gold: #e0a526;
  --gold-deep: #b9791a;
  --todo-bg: #fff1c2;
  --todo-ink: #6b4a00;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --sky-top: #16223f;
    --sky-bottom: #0d1528;
    --bg: #0d1528;
    --card: #162038;
    --outline: #2a3856;
    --ink: #f2efe6;
    --ink-muted: #aeb7cc;
    --primary: #4cc488;
    --primary-soft: #183a2d;
    --todo-bg: #4a3a10;
    --todo-ink: #ffe08a;
    color-scheme: dark;
  }
}

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

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

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(180deg, var(--sky-top) 0, var(--sky-bottom) 360px) no-repeat, var(--bg);
  color: var(--ink);
  font-family: "Outfit", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.6;
}

a {
  color: var(--primary);
  text-underline-offset: 3px;
}

a:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
  border-radius: 4px;
}

.skip {
  position: absolute;
  left: -999px;
}

.skip:focus {
  left: 16px;
  top: 16px;
  background: var(--card);
  padding: 8px 12px;
  border-radius: 8px;
}

.wrap {
  max-width: 760px;
  margin: 0 auto;
  padding: 32px 16px 56px;
}

/* Header: the gold star and the app name, linking home */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
  font-size: 28px;
  letter-spacing: -0.01em;
}

.brand svg {
  width: 48px;
  height: 48px;
  flex: none;
  filter: drop-shadow(0 4px 10px rgba(224, 165, 38, 0.45));
}

.lead {
  color: var(--ink-muted);
  margin: 8px 0 28px;
  font-size: 18px;
}

/* Cards */
.card {
  background: var(--card);
  border: 1px solid var(--outline);
  border-radius: 24px;
  padding: 24px;
  margin-bottom: 16px;
  box-shadow: 0 8px 24px rgba(21, 33, 63, 0.06);
}

h1 {
  font-size: 34px;
  line-height: 1.15;
  margin: 24px 0 4px;
  letter-spacing: -0.01em;
}

h2 {
  font-size: 22px;
  line-height: 1.3;
  margin: 0 0 8px;
}

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

.meta {
  color: var(--ink-muted);
  margin: 0 0 24px;
}

ul {
  padding-left: 22px;
}

li {
  margin: 6px 0;
}

/* The short version box */
.summary {
  background: var(--primary-soft);
  border-color: transparent;
}

/* Data table */
.table-wrap {
  overflow-x: auto;
  margin: 12px 0;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 16px;
}

th,
td {
  text-align: left;
  vertical-align: top;
  padding: 10px 12px;
  border-bottom: 1px solid var(--outline);
}

th {
  font-weight: 700;
}

/* Index page links */
.links {
  display: grid;
  gap: 16px;
}

.links .card {
  margin-bottom: 0;
}

.link-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  text-decoration: none;
  color: var(--ink);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.link-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(21, 33, 63, 0.1);
}

.link-card h2 {
  margin: 0 0 4px;
}

.link-card p {
  margin: 0;
  color: var(--ink-muted);
}

.arrow {
  font-size: 26px;
  color: var(--primary);
  flex: none;
}

/* Something the developer must still fill in */
.todo {
  background: var(--todo-bg);
  color: var(--todo-ink);
  border-radius: 6px;
  padding: 0 6px;
  font-weight: 700;
}

footer {
  margin-top: 32px;
  color: var(--ink-muted);
  font-size: 15px;
  text-align: center;
}

footer a {
  margin: 0 8px;
}

@media (max-width: 480px) {
  body {
    font-size: 16px;
  }
  h1 {
    font-size: 28px;
  }
  .card {
    padding: 20px 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .link-card {
    transition: none;
  }
}
