/* Shared by every page on mappsocial.mx. System fonts only: a privacy page
   should not call a third-party font server. */

:root {
  color-scheme: light dark;
  --bg: #ffffff;
  --surface: #fbf7f4;
  --text: #1f1a17;
  --muted: #5e5650;
  --line: #e8e2dd;
  --brand: #f06220;
  --link: #b2440e;
  --button: #c2470f;
  --button-text: #ffffff;
  --focus: #1f1a17;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #15110f;
    --surface: #1e1916;
    --text: #f3eeea;
    --muted: #b5aba4;
    --line: #3a322d;
    --link: #ff9a66;
    --button: #ff9a66;
    --button-text: #15110f;
    --focus: #f3eeea;
  }
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family:
    system-ui,
    -apple-system,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: 1.0625rem;
  line-height: 1.65;
  border-top: 4px solid var(--brand);
}

.wrap {
  max-width: 44rem;
  margin: 0 auto;
  padding-left: 16px;
  padding-right: 16px;
}

/* Header */

.site-header {
  border-bottom: 1px solid var(--line);
}

.site-header .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
  font-weight: 700;
  font-size: 1.25rem;
  text-decoration: none;
}

.brand svg {
  width: 26px;
  height: 26px;
  fill: var(--brand);
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
  font-size: 0.9375rem;
}

.site-nav a {
  color: var(--muted);
  text-decoration: none;
}

.site-nav a:hover {
  color: var(--text);
  text-decoration: underline;
}

.site-nav a[aria-current='page'] {
  color: var(--text);
  font-weight: 600;
}

/* Document */

main {
  padding-top: 40px;
  padding-bottom: 64px;
}

h1 {
  font-size: clamp(1.75rem, 1.2rem + 2.4vw, 2.375rem);
  line-height: 1.15;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.updated {
  color: var(--muted);
  font-size: 0.9375rem;
  margin: 0 0 28px;
}

.lead {
  font-size: 1.1875rem;
}

h2 {
  font-size: 1.375rem;
  line-height: 1.3;
  margin: 48px 0 12px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  scroll-margin-top: 16px;
  text-wrap: balance;
}

h3 {
  font-size: 1.0625rem;
  margin: 28px 0 8px;
}

p,
ul,
ol {
  margin: 0 0 16px;
}

ul,
ol {
  padding-left: 1.4em;
}

li {
  margin-bottom: 6px;
}

li > ul {
  margin-top: 6px;
}

a {
  color: var(--link);
  text-underline-offset: 0.15em;
  overflow-wrap: anywhere;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

strong {
  font-weight: 650;
}

.summary {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--brand);
  border-radius: 8px;
  padding: 16px 20px;
  margin: 0 0 32px;
}

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

.toc {
  margin: 0 0 8px;
}

.toc h2 {
  border-top: 0;
  margin-top: 0;
  padding-top: 0;
  font-size: 1rem;
  color: var(--muted);
}

.toc ol {
  columns: 2 16rem;
  column-gap: 32px;
  font-size: 0.9375rem;
}

.toc li {
  break-inside: avoid;
}

.data-list {
  list-style: none;
  padding: 0;
}

.data-list > li {
  padding: 12px 0;
  margin: 0;
  border-bottom: 1px solid var(--line);
}

.data-list > li:first-child {
  border-top: 1px solid var(--line);
}

.data-list strong {
  display: block;
}

/* Home: the app's launch screen. Colours sampled from
   apps/mobile/assets/splash-gradient.jpg; the same in light and dark. */

.home-page {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
  border-top: 0;
  color: #ffffff;
  background:
    radial-gradient(90% 45% at 0% 100%, #fafeff 0%, rgba(250, 254, 255, 0) 70%),
    linear-gradient(
      160deg,
      #fe1290 0%,
      #fd2e40 28%,
      #fb4629 42%,
      #e87c17 55%,
      #c2b822 70%,
      #6cc51f 85%,
      #1ecb4f 100%
    );
}

.home {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: 100%;
  padding-top: 48px;
  padding-bottom: 22vh;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
}

.home svg {
  width: 96px;
  height: auto;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.15));
}

.home h1 {
  margin: 16px 0 4px;
  font-size: 2.75rem;
  font-weight: 800;
}

.home p {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 600;
}

/* The bottom of the gradient is light, so the footer reads in dark text. */
.home-page .site-footer {
  border-top: 0;
  color: #1f1a17;
  text-align: center;
}

.home-page .site-footer a {
  color: #1f1a17;
}

/* Deletion request form */

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 20px;
  margin: 0 0 24px;
}

.field {
  margin: 0 0 16px;
}

.field label {
  display: block;
  font-weight: 600;
  margin-bottom: 4px;
}

.field .hint {
  display: block;
  color: var(--muted);
  font-size: 0.9375rem;
  margin-bottom: 6px;
}

.field input,
.field textarea {
  width: 100%;
  font: inherit;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--muted);
  border-radius: 8px;
  padding: 10px 12px;
}

.field textarea {
  min-height: 5.5em;
  resize: vertical;
}

.field input[aria-invalid='true'] {
  border-color: #c62828;
  border-width: 2px;
}

.error {
  color: #c62828;
  font-size: 0.9375rem;
  margin: 6px 0 0;
}

@media (prefers-color-scheme: dark) {
  .field input[aria-invalid='true'] {
    border-color: #ff8a80;
  }

  .error {
    color: #ff8a80;
  }
}

.button {
  display: inline-block;
  font: inherit;
  font-weight: 600;
  color: var(--button-text);
  background: var(--button);
  border: 0;
  border-radius: 999px;
  padding: 12px 22px;
  cursor: pointer;
  text-decoration: none;
}

.button:hover {
  filter: brightness(1.08);
}

.note {
  color: var(--muted);
  font-size: 0.9375rem;
}

.mono {
  font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  font-size: 0.9375rem;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

/* Footer */

.site-footer {
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.9375rem;
}

.site-footer .wrap {
  padding-top: 24px;
  padding-bottom: 40px;
}

.site-footer p {
  margin: 0 0 6px;
}

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

@media print {
  body {
    border-top: 0;
    font-size: 11pt;
  }

  .site-header nav,
  .toc,
  .card {
    display: none;
  }

  a {
    color: inherit;
  }
}
