/* Orbit by KenanTech — shared styles */

:root {
  --mist: #F4F2FB;
  --surface: #FFFFFF;
  --ink: #211B3A;
  --ink-soft: #5B5476;
  --line: #E2DDF2;
  --lavender: #B9A2EE;
  --lavender-deep: #6A4FC9;
  --blush: #FF9DB1;
  --coral: #EF4444;
  --mint: #22C55E;
  --sky: #3B82F6;
  --amber: #F59E0B;
  --band: #211B3A;
  --band-ink: #F4F2FB;
  --band-soft: #B9B1D6;

  --font-display: "Unbounded", "Avenir Next", system-ui, sans-serif;
  --font-body: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif;

  --gutter: clamp(16px, 4vw, 40px);
  --max: 1160px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --mist: #15112A;
    --surface: #1F1938;
    --ink: #EEEAFB;
    --ink-soft: #ADA6C8;
    --line: #2F2850;
    --lavender-deep: #C4B1F5;
    --band: #0F0C20;
    --band-soft: #A49CC4;
    color-scheme: dark;
  }
}

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

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

body {
  margin: 0;
  background: var(--mist);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

a { color: var(--lavender-deep); text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }

:focus-visible {
  outline: 3px solid var(--lavender-deep);
  outline-offset: 3px;
  border-radius: 6px;
}

.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
}
.skip:focus {
  left: 16px;
  top: 12px;
  z-index: 100;
  background: var(--surface);
  padding: 8px 14px;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--mist) 86%, transparent);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled { border-bottom-color: var(--line); }

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
}
.brand img {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  box-shadow: 0 0 0 1px var(--line);
}
.brand-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.125rem;
  letter-spacing: -0.01em;
}
.brand-by {
  font-size: 0.8125rem;
  color: var(--ink-soft);
  margin-left: 2px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2.4vw, 28px);
  font-size: 0.9375rem;
}
.site-nav a {
  color: var(--ink);
  text-decoration: none;
}
.site-nav a:hover { color: var(--lavender-deep); }
.site-nav a[aria-current="page"] {
  color: var(--lavender-deep);
  font-weight: 600;
}

/* App Store button */
.store-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px 10px 14px;
  border-radius: 14px;
  background: #000;
  color: #fff;
  text-decoration: none;
  line-height: 1.1;
  transition: transform 0.15s ease;
}
.store-btn:hover { transform: translateY(-1px); }
.site-nav .store-btn,
.site-nav .store-btn:hover { color: #fff; }
.store-btn svg { width: 22px; height: 26px; flex: none; }
.store-btn small {
  display: block;
  font-size: 0.6875rem;
  opacity: 0.85;
}
.store-btn strong {
  display: block;
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.store-btn--compact {
  padding: 8px 14px;
  border-radius: 999px;
  gap: 6px;
  font-size: 0.875rem;
  font-weight: 600;
}
.store-btn--compact svg { width: 14px; height: 17px; }

@media (prefers-color-scheme: dark) {
  .store-btn { box-shadow: 0 0 0 1px #4A4268; }
}

@media (max-width: 720px) {
  .site-nav .nav-hide { display: none; }
  .brand-by { display: none; }
}

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

.site-footer {
  border-top: 1px solid var(--line);
  margin-top: clamp(64px, 10vw, 120px);
  padding: 40px 0 48px;
  font-size: 0.9375rem;
  color: var(--ink-soft);
}
.site-footer .wrap {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px 48px;
  align-items: start;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
}
.footer-links a { color: var(--ink); text-decoration: none; }
.footer-links a:hover { color: var(--lavender-deep); }
.footer-legal { margin: 8px 0 0; }

@media (max-width: 640px) {
  .site-footer .wrap { grid-template-columns: 1fr; }
}

/* ---------- Shared type ---------- */

.display {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.08;
  margin: 0;
}

.section-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.625rem, 3.2vw, 2.375rem);
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0 0 16px;
}

.lede {
  font-size: clamp(1.0625rem, 1.6vw, 1.25rem);
  color: var(--ink-soft);
  max-width: 34em;
  margin: 0;
}

/* ---------- Simple page head (support, legal) ---------- */

.page-head {
  padding: clamp(48px, 8vw, 96px) 0 clamp(32px, 5vw, 56px);
}
.page-head h1 {
  font-size: clamp(2rem, 5vw, 3.25rem);
  margin-bottom: 16px;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* ---------- Legal pages (Termly content is kept verbatim; these rules restyle it) ---------- */

.legal {
  max-width: 46rem;
  margin: 0 auto;
  padding-top: clamp(40px, 7vw, 88px);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--ink-soft);
  overflow-wrap: break-word;
}

.legal [data-custom-class],
.legal [data-custom-class] *,
.legal [style] {
  font-family: var(--font-body) !important;
  font-size: inherit !important;
  color: inherit !important;
}

.legal h1,
.legal [data-custom-class] h1 {
  font-family: var(--font-display) !important;
  font-weight: 600;
  font-size: clamp(2rem, 5vw, 3rem) !important;
  letter-spacing: -0.025em;
  line-height: 1.1;
  color: var(--ink) !important;
  text-transform: lowercase;
  margin: 0 0 12px;
}
.legal h1::first-letter { text-transform: uppercase; }

.legal h2,
.legal [data-custom-class] h2 {
  font-family: var(--font-body) !important;
  font-size: 1.0625rem !important;
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1.4;
  color: var(--ink) !important;
  margin: 48px 0 12px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.legal h3,
.legal [data-custom-class] h3 {
  font-family: var(--font-body) !important;
  font-size: 1rem !important;
  font-weight: 600;
  color: var(--ink) !important;
  margin: 28px 0 8px;
}

.legal strong { color: var(--ink) !important; }

.legal a,
.legal [data-custom-class] a,
.legal [data-custom-class='link'],
.legal [data-custom-class='link'] * {
  color: var(--lavender-deep) !important;
  word-break: break-word;
}

.legal .subtitle,
.legal [data-custom-class='subtitle'] {
  display: block;
  margin-bottom: 32px;
  font-size: 0.9375rem !important;
}

.legal p { margin: 0 0 14px; }
.legal ul,
.legal ol { padding-left: 1.4em; }
.legal li { margin-bottom: 6px; }
.legal .uppercase { text-transform: uppercase; }

.legal .toc {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 8px 24px;
}
.legal .toc a { text-decoration: none; }
.legal .toc a:hover { text-decoration: underline; }

.legal table {
  display: block;
  max-width: 100%;
  overflow-x: auto;
  border-collapse: collapse;
  margin: 16px 0;
}
.legal td,
.legal th,
.legal td[style],
.legal th[style] {
  border: 1px solid var(--line) !important;
  padding: 8px 12px;
  vertical-align: top;
  background: var(--surface) !important;
}

/* Termly's grey wordmark at the top of the export; the attribution line at the end stays */
.legal > span[style*="background: url(data:image/svg"] { display: none !important; }
