/* Public compliance pages (SMS opt-in, Privacy, Terms). Reuses the portal design
   tokens (--bg, --text, --primary…) from portal.css for a consistent look, with
   prose styling tuned for long-form legal copy. */

.legal-root {
  min-height: 100vh;
  background: var(--bg, #0b0c11);
  color: var(--text, #f3f4f8);
  font-family: var(--font-ui, "Inter", system-ui, sans-serif);
  display: flex;
  flex-direction: column;
}

.legal-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 24px;
  border-bottom: 1px solid var(--line, rgba(255, 255, 255, 0.09));
  position: sticky;
  top: 0;
  background: color-mix(in srgb, var(--bg, #0b0c11) 88%, transparent);
  backdrop-filter: blur(10px);
  z-index: 5;
}
.legal-bar img { height: 30px; width: auto; }
.legal-bar nav { display: flex; gap: 20px; flex-wrap: wrap; }
.legal-bar nav a {
  color: var(--muted, #a3a8b5);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
}
.legal-bar nav a:hover { color: var(--text, #f3f4f8); }
.legal-bar nav a.on { color: var(--primary-2, #fb923c); }

.legal-wrap { flex: 1; width: 100%; max-width: 820px; margin: 0 auto; padding: 44px 24px 80px; }

.legal-wrap h1 { font-size: 32px; font-weight: 800; letter-spacing: -0.02em; margin: 0 0 6px; }
.legal-wrap .updated { color: var(--faint, #6c7280); font-size: 13px; margin: 0 0 30px; }
.legal-wrap h2 {
  font-size: 19px; font-weight: 700; margin: 34px 0 10px;
  padding-top: 20px; border-top: 1px solid var(--line, rgba(255, 255, 255, 0.09));
}
.legal-wrap h2:first-of-type { border-top: none; padding-top: 0; }
.legal-wrap p, .legal-wrap li { color: var(--muted, #a3a8b5); font-size: 15px; line-height: 1.7; }
.legal-wrap p { margin: 0 0 12px; }
.legal-wrap ul { margin: 0 0 12px; padding-left: 20px; }
.legal-wrap li { margin: 0 0 6px; }
.legal-wrap strong { color: var(--text, #f3f4f8); font-weight: 600; }
.legal-wrap a { color: var(--primary-2, #fb923c); }

/* Callout box for the mandatory SMS disclosures — makes them easy for a reviewer to find. */
.legal-callout {
  border: 1px solid var(--line-2, rgba(255, 255, 255, 0.15));
  background: var(--surface, rgba(255, 255, 255, 0.04));
  border-radius: var(--radius-sm, 13px);
  padding: 16px 18px;
  margin: 8px 0 18px;
}
.legal-callout p:last-child { margin-bottom: 0; }

.legal-foot {
  border-top: 1px solid var(--line, rgba(255, 255, 255, 0.09));
  padding: 22px 24px;
  text-align: center;
  color: var(--faint, #6c7280);
  font-size: 13px;
}
.legal-foot a { color: var(--muted, #a3a8b5); text-decoration: none; margin: 0 10px; }
.legal-foot a:hover { color: var(--text, #f3f4f8); }

/* SMS opt-in form */
.optin-card {
  border: 1px solid var(--line, rgba(255, 255, 255, 0.09));
  background: var(--surface, rgba(255, 255, 255, 0.04));
  border-radius: var(--radius-sm, 13px);
  padding: 22px;
  margin-top: 22px;
}
.optin-field { margin-bottom: 16px; }
.optin-field label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 7px; color: var(--text, #f3f4f8); }
.optin-input {
  width: 100%;
  background: var(--ink, #121319);
  border: 1px solid var(--line-2, rgba(255, 255, 255, 0.15));
  border-radius: 10px;
  padding: 13px 14px;
  color: var(--text, #f3f4f8);
  font-size: 15px;
  font-family: inherit;
}
.optin-input:focus { outline: 2px solid var(--primary, #f97316); outline-offset: 1px; border-color: transparent; }

.optin-consent { display: flex; gap: 11px; align-items: flex-start; margin: 6px 0 4px; }
.optin-consent input { margin-top: 3px; width: 18px; height: 18px; flex: none; accent-color: var(--primary, #f97316); }
.optin-consent label { font-size: 13.5px; line-height: 1.6; color: var(--muted, #a3a8b5); }

.optin-submit {
  width: 100%;
  margin-top: 18px;
  background: var(--primary, #f97316);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 14px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
}
.optin-submit:disabled { opacity: 0.5; cursor: not-allowed; }

.optin-fine { font-size: 12.5px; color: var(--faint, #6c7280); line-height: 1.6; margin-top: 14px; }
.optin-done {
  border: 1px solid color-mix(in srgb, var(--green, #34d399) 45%, transparent);
  background: color-mix(in srgb, var(--green, #34d399) 12%, transparent);
  color: #a7f3d0;
  border-radius: var(--radius-sm, 13px);
  padding: 18px 20px;
  margin-top: 22px;
  font-size: 14.5px;
  line-height: 1.6;
}
