/* VisionPlayer — support & legal site
   Zero-dependency, system-font, auto light/dark. */

:root {
  --bg: #ffffff;
  --bg-elevated: #f5f5f7;
  --text: #1d1d1f;
  --text-muted: #6e6e73;
  --border: rgba(0, 0, 0, 0.08);
  --accent: #0071e3;
  --accent-hover: #0077ed;
  --card: #ffffff;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 8px 24px rgba(0, 0, 0, 0.06);
  --hero-gradient: linear-gradient(180deg, #f5f5f7 0%, #ffffff 100%);
  --code-bg: #f5f5f7;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #000000;
    --bg-elevated: #1c1c1e;
    --text: #f5f5f7;
    --text-muted: #a1a1a6;
    --border: rgba(255, 255, 255, 0.12);
    --accent: #2997ff;
    --accent-hover: #47a7ff;
    --card: #1c1c1e;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px rgba(0, 0, 0, 0.4);
    --hero-gradient: linear-gradient(180deg, #1c1c1e 0%, #000000 100%);
    --code-bg: #1c1c1e;
  }
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text",
    "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ---------- Navigation ---------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border);
}

@media (prefers-color-scheme: dark) {
  .nav {
    background: rgba(0, 0, 0, 0.72);
  }
}

.nav-inner {
  max-width: 980px;
  margin: 0 auto;
  padding: 0 22px;
  height: 52px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav-brand {
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-brand img {
  height: 22px;
  width: auto;
  vertical-align: middle;
}

.nav-links {
  margin-left: auto;
  display: flex;
  gap: 22px;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.15s ease;
}

.nav-links a:hover {
  color: var(--text);
}

.nav-links a.active {
  color: var(--text);
  font-weight: 500;
}

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

.container {
  max-width: 820px;
  margin: 0 auto;
  padding: 40px 22px 80px;
}

.container-wide {
  max-width: 980px;
}

/* ---------- Hero ---------- */

.hero {
  background: var(--hero-gradient);
  padding: 80px 22px 60px;
  text-align: center;
  border-bottom: 1px solid var(--border);
}

.hero-logo {
  width: 96px;
  height: 96px;
  margin: 0 auto 24px;
  display: block;
  border-radius: 22px;
  box-shadow: var(--shadow);
}

.hero h1 {
  font-size: 48px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
  line-height: 1.08;
}

.hero p {
  font-size: 21px;
  color: var(--text-muted);
  margin: 0 auto;
  max-width: 620px;
  line-height: 1.4;
}

/* ---------- Typography ---------- */

h1, h2, h3, h4 {
  color: var(--text);
  letter-spacing: -0.01em;
}

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

h2 {
  font-size: 28px;
  font-weight: 600;
  margin: 48px 0 16px;
  padding-top: 16px;
}

h3 {
  font-size: 20px;
  font-weight: 600;
  margin: 32px 0 12px;
}

p {
  margin: 0 0 16px;
}

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

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

.subtitle {
  color: var(--text-muted);
  font-size: 19px;
  margin: 8px 0 0;
}

.meta {
  color: var(--text-muted);
  font-size: 14px;
  margin: 4px 0 32px;
}

ul, ol {
  padding-left: 22px;
  margin: 0 0 16px;
}

li {
  margin-bottom: 8px;
}

hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 40px 0;
}

code {
  font-family: "SF Mono", ui-monospace, Menlo, Consolas, monospace;
  font-size: 0.9em;
  background: var(--code-bg);
  padding: 2px 6px;
  border-radius: 4px;
}

/* ---------- Cards ---------- */

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin: 40px 0;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 28px;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  text-decoration: none;
  color: inherit;
  display: block;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.06), 0 16px 32px rgba(0, 0, 0, 0.08);
  text-decoration: none;
}

@media (prefers-color-scheme: dark) {
  .card:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4), 0 16px 32px rgba(0, 0, 0, 0.5);
  }
}

.card h3 {
  margin: 0 0 8px;
  font-size: 20px;
}

.card p {
  color: var(--text-muted);
  margin: 0;
  font-size: 15px;
}

.card-arrow {
  color: var(--accent);
  font-weight: 500;
  margin-top: 12px;
  display: inline-block;
  font-size: 14px;
}

/* ---------- Callouts ---------- */

.callout {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px 24px;
  margin: 24px 0;
}

.callout p:last-child {
  margin-bottom: 0;
}

.callout-title {
  font-weight: 600;
  margin: 0 0 6px;
  display: block;
}

/* ---------- Table of contents ---------- */

.toc {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px 24px;
  margin: 32px 0;
}

.toc-title {
  font-weight: 600;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin: 0 0 12px;
}

.toc ol {
  margin: 0;
  padding-left: 22px;
  font-size: 15px;
}

.toc li {
  margin-bottom: 4px;
}

/* ---------- FAQ ---------- */

.faq details {
  border-bottom: 1px solid var(--border);
  padding: 20px 0;
}

.faq details:first-of-type {
  border-top: 1px solid var(--border);
}

.faq summary {
  font-weight: 500;
  cursor: pointer;
  font-size: 17px;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "+";
  color: var(--text-muted);
  font-size: 24px;
  font-weight: 300;
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.faq details[open] summary::after {
  content: "–";
}

.faq details[open] summary {
  margin-bottom: 12px;
}

.faq details p {
  margin: 0;
  color: var(--text-muted);
  font-size: 16px;
}

.faq details ul {
  color: var(--text-muted);
  font-size: 16px;
}

/* ---------- Button ---------- */

.button {
  display: inline-block;
  background: var(--accent);
  color: #ffffff !important;
  padding: 12px 22px;
  border-radius: 980px;
  font-size: 16px;
  font-weight: 500;
  text-decoration: none;
  transition: background 0.15s ease;
}

.button:hover {
  background: var(--accent-hover);
  text-decoration: none;
}

.button-secondary {
  background: var(--bg-elevated);
  color: var(--text) !important;
  border: 1px solid var(--border);
}

.button-secondary:hover {
  background: var(--border);
}

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

.footer {
  border-top: 1px solid var(--border);
  padding: 32px 22px;
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
}

.footer a {
  color: var(--text-muted);
  margin: 0 10px;
}

.footer a:hover {
  color: var(--text);
}

.footer-brand {
  margin-bottom: 8px;
  color: var(--text);
  font-weight: 500;
}

/* ---------- Responsive ---------- */

@media (max-width: 640px) {
  .hero {
    padding: 60px 22px 40px;
  }

  .hero h1 {
    font-size: 34px;
  }

  .hero p {
    font-size: 18px;
  }

  h1 {
    font-size: 30px;
  }

  h2 {
    font-size: 24px;
  }

  .nav-inner {
    height: 48px;
    gap: 16px;
  }

  .nav-links {
    gap: 16px;
  }

  .container {
    padding: 32px 22px 60px;
  }
}
