/* Finzy legal & support pages — shared stylesheet */

:root {
  --bg: #ffffff;
  --text: #1a1a1a;
  --muted: #666666;
  --rule: #e5e5e5;
  --accent: #0A7075;
  --brand: #024143;
  --brand-mint: #7EDDB4;
  --surface: #fafafa;
  --warn-bg: #fff8e7;
  --warn-line: #f59e0b;
  --good-bg: #f0fdf4;
  --good-line: #16a34a;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e0f13;
    --text: #ececf0;
    --muted: #9a9aa5;
    --rule: #26272e;
    --accent: #2E9A9E;
    --brand: #2E9A9E;
    --brand-mint: #7EDDB4;
    --surface: #16171d;
    --warn-bg: #2a2113;
    --warn-line: #f59e0b;
    --good-bg: #0f2a24;
    --good-line: #7EDDB4;
  }
}

* { box-sizing: border-box; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  max-width: 760px;
  margin: 48px auto;
  padding: 0 24px 64px;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: center;
  padding-bottom: 18px;
  margin-bottom: 32px;
  border-bottom: 1px solid var(--rule);
  font-size: 15px;
}

.site-nav .brand {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 700;
  font-size: 17px;
  letter-spacing: -0.01em;
  color: var(--brand);
  margin-right: auto;
}

.site-nav .brand:hover { text-decoration: none; }

.site-nav .brand img {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  display: block;
}

/* Four links plus the wordmark cannot share one row on a phone. Rather than
   letting the last link strand itself under the brand, give the brand its own
   row so the links stay together as one group. */
@media (max-width: 460px) {
  .site-nav {
    gap: 14px;
    font-size: 14px;
  }

  .site-nav .brand {
    flex: 1 0 100%;
    margin-right: 0;
    margin-bottom: 2px;
  }
}

.masthead {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 8px;
}

.masthead img {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  display: block;
}

.masthead h1 {
  color: var(--brand);
  margin: 0;
}

h1 {
  font-size: 32px;
  font-weight: 700;
  margin: 0 0 4px;
  letter-spacing: -0.02em;
}

.last-updated {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 40px;
}

h2 {
  font-size: 18px;
  font-weight: 700;
  margin-top: 40px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 8px;
}

h3 {
  font-size: 16px;
  font-weight: 700;
  margin-top: 24px;
  margin-bottom: 8px;
}

p { margin: 0 0 14px; }

ul {
  margin: 0 0 14px;
  padding-left: 24px;
}

li { margin-bottom: 6px; }

.callout {
  background: var(--warn-bg);
  border-left: 4px solid var(--warn-line);
  border-radius: 6px;
  padding: 14px 18px;
  margin: 16px 0;
  font-size: 15px;
}

.callout.good {
  background: var(--good-bg);
  border-left-color: var(--good-line);
}

.table-wrap {
  overflow-x: auto;
  margin: 16px 0 20px;
}

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

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

th {
  font-weight: 700;
  background: var(--surface);
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover { text-decoration: underline; }

.cards {
  display: grid;
  /* 260px so the four cards settle into 2x2 inside the 760px body rather than
     leaving one stranded on a row of its own. */
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin: 28px 0 8px;
}

.card {
  display: block;
  border: 1px solid var(--rule);
  border-radius: 12px;
  padding: 18px 20px;
  color: var(--text);
  background: var(--surface);
}

.card:hover {
  border-color: var(--accent);
  text-decoration: none;
}

.card strong {
  display: block;
  color: var(--brand);
  font-size: 17px;
  margin-bottom: 4px;
}

.card span {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

footer {
  margin-top: 48px;
  padding-top: 20px;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 14px;
}

footer a { color: var(--muted); }

/* Store buttons — get.html */

.store-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 32px 0 8px;
}

/* The official store badges carry their own artwork and outline, so the link
   is just the image — no card around it. Both badges render at the same size,
   which Apple's guidelines require when they appear together. */
.store-btn {
  display: block;
  line-height: 0;
}

.store-btn:hover {
  opacity: 0.85;
  text-decoration: none;
}

.store-btn img {
  display: block;
  width: 220px;
  max-width: 100%;
  height: auto;
}

/* Only shown once the redirect is actually under way. */
.redirect-note { display: none; color: var(--muted); font-size: 14px; margin-top: 18px; }
.redirecting .redirect-note { display: block; }
