/*
 * Edge website. Same design language as the app: black and white only, Archivo,
 * square corners, text glyphs instead of icons. Light mode is the dark design inverted.
 */

@font-face {
  font-family: 'Archivo';
  src: url('fonts/archivo-400Regular.woff') format('woff');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'Archivo';
  src: url('fonts/archivo-600SemiBold.woff') format('woff');
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: 'Archivo';
  src: url('fonts/archivo-800ExtraBold.woff') format('woff');
  font-weight: 800;
  font-display: swap;
}

:root {
  color-scheme: dark light;
  --fg-rgb: 255, 255, 255;
  --bg: #000;
  --fg: #fff;
  /* Secondary text stays at 65% or more so it keeps 7:1+ contrast. */
  --fg-secondary: rgba(var(--fg-rgb), 0.68);
  --fg-hint: rgba(var(--fg-rgb), 0.6);
  --line: rgba(var(--fg-rgb), 0.35);
  --line-soft: rgba(var(--fg-rgb), 0.16);
  --gutter: 24px;
  --measure: 40rem;
}

@media (prefers-color-scheme: light) {
  :root {
    --fg-rgb: 0, 0, 0;
    --bg: #fff;
    --fg: #000;
  }
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: 'Archivo', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

/* ---------- Links and focus ---------- */

a {
  color: inherit;
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}
a:hover {
  text-decoration-thickness: 2.5px;
}
:focus-visible {
  outline: 3px solid var(--fg);
  outline-offset: 3px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -100px;
  padding: 10px 14px;
  background: var(--fg);
  color: var(--bg);
  font-weight: 600;
  text-decoration: none;
  z-index: 10;
}
.skip-link:focus {
  top: 12px;
}

/* ---------- Layout ---------- */

.wrap {
  width: 100%;
  max-width: calc(var(--measure) + 2 * var(--gutter));
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  text-decoration: none;
}
.brand img {
  width: 30px;
  height: 30px;
}

.site-nav ul {
  display: flex;
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.site-nav a {
  font-size: 0.9375rem;
  color: var(--fg-secondary);
  text-decoration: none;
  /* At least a 44px tall tap target. */
  display: inline-block;
  padding: 11px 0;
}
.site-nav a:hover,
.site-nav a[aria-current='page'] {
  color: var(--fg);
}
.site-nav a[aria-current='page'] {
  font-weight: 600;
}

main {
  padding-bottom: 64px;
}

/* ---------- Type ---------- */

h1 {
  margin: 40px 0 8px;
  font-size: clamp(2.5rem, 9vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1;
}

h2 {
  margin: 48px 0 8px;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

h3 {
  margin: 28px 0 4px;
  font-size: 1.0625rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

p,
ul,
ol {
  margin: 0 0 14px;
}
ul,
ol {
  padding-left: 1.25em;
}
li {
  margin-bottom: 6px;
}

strong {
  font-weight: 600;
}

.subtitle {
  margin: 0;
  font-size: 1.0625rem;
  color: var(--fg-secondary);
}

.label {
  display: block;
  margin: 0 0 6px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-hint);
}

/* ---------- Buttons ---------- */

.cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  margin-top: 28px;
}

/* The app's primary button: filled, flush-left label, trailing arrow pushed right. */
.button {
  display: inline-flex;
  justify-content: space-between;
  align-items: center;
  gap: 32px;
  min-width: 220px;
  min-height: 48px;
  padding: 14px 16px;
  background: var(--fg);
  color: var(--bg);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
}
.button:hover {
  opacity: 0.85;
}

/* ---------- Policy and support pages ---------- */

.page-intro {
  padding-bottom: 8px;
}

.summary {
  margin: 28px 0 8px;
  padding: 18px 20px;
  border: 1px solid var(--line);
}
.summary p:last-child,
.summary ul:last-child {
  margin-bottom: 0;
}

.updated {
  margin-top: 12px;
  font-size: 0.875rem;
  color: var(--fg-hint);
}

details {
  border-top: 1px solid var(--line-soft);
}
details:last-of-type {
  border-bottom: 1px solid var(--line-soft);
}
summary {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}
summary::-webkit-details-marker {
  display: none;
}
summary::after {
  content: '+';
  flex-shrink: 0;
  color: var(--fg-secondary);
}
details[open] summary::after {
  content: '−';
}
details > div {
  padding: 0 0 16px;
  color: var(--fg-secondary);
}
details > div strong {
  color: var(--fg);
}

.contact-email {
  font-size: 1.375rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  word-break: break-word;
}

kbd,
.path {
  font-family: inherit;
  font-weight: 600;
  color: var(--fg);
}

/* ---------- Footer ---------- */

.site-footer {
  padding: 28px 0 40px;
  border-top: 1px solid var(--line-soft);
  font-size: 0.875rem;
  color: var(--fg-hint);
}
.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
}
.site-footer ul {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.site-footer li {
  margin: 0;
}
.site-footer a {
  text-decoration: none;
}
.site-footer a:hover {
  color: var(--fg);
  text-decoration: underline;
}

@media (max-width: 420px) {
  .site-nav ul {
    gap: 14px;
  }
  .button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
  }
}
