:root {
  --bg: #0a0a0a;
  --bg-soft: #0f0f10;
  --surface: #141416;
  --surface-hi: #1a1a1c;
  --border: #232327;
  --border-hi: #34343a;
  --text: #f5f5f6;
  --text-muted: #a1a1aa;
  --text-faint: #71717a;
  --accent: #60a5fa;
  --accent-soft: rgba(96, 165, 250, 0.12);
  --accent-line: rgba(96, 165, 250, 0.3);
  --ok: #34d399;

  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
}

[data-theme="light"] {
  --bg: #ffffff;
  --bg-soft: #fafafa;
  --surface: #ffffff;
  --surface-hi: #f4f4f5;
  --border: #e4e4e7;
  --border-hi: #d4d4d8;
  --text: #0a0a0a;
  --text-muted: #52525b;
  --text-faint: #71717a;
  --accent: #2563eb;
  --accent-soft: rgba(37, 99, 235, 0.08);
  --accent-line: rgba(37, 99, 235, 0.3);
  --ok: #059669;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

::selection {
  background: var(--text);
  color: var(--bg);
}

a {
  color: inherit;
  text-decoration: none;
}

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

.grid-bg {
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(to right, var(--border) 1px, transparent 1px),
    linear-gradient(to bottom, var(--border) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 70% 50% at 15% 0%, black 0%, transparent 65%);
  -webkit-mask-image: radial-gradient(ellipse 70% 50% at 15% 0%, black 0%, transparent 65%);
  opacity: 0.45;
  pointer-events: none;
  z-index: -1;
}

nav {
  position: sticky;
  top: 0;
  z-index: 100;
  height: 64px;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(140%) blur(12px);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-left,
.nav-right,
.nav-links {
  display: flex;
  align-items: center;
}

.nav-left {
  min-width: 0;
}

.nav-right {
  gap: 16px;
}

.nav-links {
  gap: 18px;
  list-style: none;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.nav-links a {
  transition: color 0.15s;
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.01em;
  min-width: 0;
}

.logo-mark {
  width: 24px;
  height: 24px;
  color: var(--text);
  flex: 0 0 auto;
}

.app-icon {
  width: 28px;
  height: 28px;
  border: 1px solid var(--border-hi);
  border-radius: 7px;
  flex: 0 0 auto;
}

.logo-divider {
  color: var(--text-faint);
  font-family: var(--font-mono);
  font-size: 12px;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-muted);
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}

.theme-toggle:hover {
  border-color: var(--border-hi);
  color: var(--text);
}

.theme-toggle svg {
  width: 14px;
  height: 14px;
}

.theme-toggle .icon-sun,
.theme-toggle .icon-moon {
  display: none;
}

[data-theme="dark"] .theme-toggle .icon-sun {
  display: block;
}

[data-theme="light"] .theme-toggle .icon-moon {
  display: block;
}

main {
  position: relative;
}

.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 32px;
}

.container-narrow {
  max-width: 860px;
}

section {
  padding: 96px 0;
}

.divider {
  border-top: 1px solid var(--border);
  max-width: 1080px;
  margin: 0 auto;
}

.eyebrow,
.hero-eyebrow,
.meta-label,
.doc-updated {
  font-family: var(--font-mono);
  font-weight: 500;
  text-transform: uppercase;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.eyebrow::before {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  box-shadow: 0 0 0 3px var(--accent-soft);
}

h1,
h2,
h3 {
  color: var(--text);
  font-weight: 600;
  line-height: 1.15;
}

h1 {
  font-size: clamp(44px, 6.2vw, 78px);
  line-height: 1.02;
  letter-spacing: -0.035em;
  max-width: 900px;
}

h2 {
  font-size: clamp(30px, 3.6vw, 40px);
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}

h3 {
  font-size: 20px;
  letter-spacing: -0.015em;
}

p {
  color: var(--text-muted);
}

strong {
  color: var(--text);
  font-weight: 500;
}

.hero {
  min-height: calc(88vh - 64px);
  min-height: calc(88dvh - 64px);
  padding-top: 104px;
  padding-bottom: 72px;
  display: flex;
  align-items: center;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--text-faint);
  margin-bottom: 40px;
}

.hero-eyebrow-dot {
  width: 6px;
  height: 6px;
  background: var(--ok);
  border-radius: 50%;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--ok) 20%, transparent);
}

.muted {
  color: var(--text-muted);
}

.hero-prose {
  max-width: 640px;
  color: var(--text-muted);
  font-size: 18px;
  line-height: 1.7;
  margin-top: 40px;
  margin-bottom: 40px;
}

.hero-prose p + p {
  margin-top: 16px;
}

.hero-links,
.doc-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  font-size: 14px;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
  font-weight: 500;
  border-bottom: 1px solid var(--border-hi);
  padding-bottom: 4px;
  transition: border-color 0.15s, color 0.15s, gap 0.15s;
}

.text-link:hover {
  border-color: var(--text);
  gap: 12px;
}

.text-link.mono {
  font-family: var(--font-mono);
  color: var(--text-muted);
  font-weight: 400;
}

.text-link.mono:hover {
  color: var(--text);
}

.section-lead {
  max-width: 640px;
  color: var(--text-muted);
  font-size: 17px;
  line-height: 1.65;
}

.product-panel,
.legal-panel,
.question-list,
.price-panel {
  border: 1px solid var(--border);
  border-radius: 16px;
  background: linear-gradient(180deg, var(--surface), var(--bg-soft));
  overflow: hidden;
}

.product-panel {
  margin-top: 48px;
}

.product-panel-main {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 32px;
  padding: 32px;
  border-bottom: 1px solid var(--border);
}

.meta-label,
.doc-updated {
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--accent);
}

.product-panel h3 {
  font-size: clamp(28px, 4vw, 48px);
  line-height: 1.08;
  letter-spacing: -0.035em;
  margin-bottom: 16px;
}

.product-panel p {
  max-width: 680px;
  font-size: 17px;
  line-height: 1.7;
}

.principles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}

.principle {
  min-height: 170px;
  padding: 24px;
  border-right: 1px solid var(--border);
}

.principle:last-child {
  border-right: 0;
}

.principle-num {
  display: block;
  margin-bottom: 28px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.1em;
  color: var(--accent);
}

.principle h4 {
  margin-bottom: 8px;
  font-size: 17px;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.principle p {
  font-size: 13.5px;
  line-height: 1.6;
}

.mode-grid,
.gallery-grid,
.price-grid {
  display: grid;
  gap: 16px;
}

.mode-grid {
  grid-template-columns: repeat(2, 1fr);
  margin-top: 48px;
}

.mode {
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
}

.mode h3 {
  margin: 12px 0;
}

.mode ul,
.doc-content ul,
.doc-content ol,
.faq-answer ul {
  color: var(--text-muted);
  padding-left: 20px;
}

.mode li,
.doc-content li,
.faq-answer li {
  margin: 8px 0;
}

.gallery-grid {
  grid-template-columns: repeat(3, 1fr);
  margin-top: 48px;
}

.screenshot {
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
}

.screenshot img {
  width: 100%;
  border-radius: 10px;
  border: 1px solid var(--border);
}

.price-panel {
  margin-top: 48px;
}

.price-panel-main {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-bottom: 1px solid var(--border);
}

.price-item {
  padding: 28px 32px;
}

.price-item:first-child {
  border-right: 1px solid var(--border);
}

.price-label {
  margin-bottom: 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.price-value {
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.025em;
}

.price-note {
  padding: 24px 32px;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
}

.price-note p {
  max-width: 620px;
  font-size: 15px;
}

.store-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--accent-line);
  border-radius: 8px;
  background: var(--accent-soft);
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  transition: border-color 0.15s, background 0.15s;
}

.store-button:hover {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 16%, transparent);
}

.doc-hero {
  padding: 72px 0 56px;
}

.doc-hero h1 {
  margin-bottom: 28px;
}

.doc-updated {
  color: var(--text-faint);
  margin-bottom: 24px;
}

.doc-content {
  padding: 72px 0 96px;
}

.doc-content h2 {
  margin-top: 48px;
}

.doc-content h2:first-child {
  margin-top: 0;
}

.doc-content h3 {
  margin-top: 24px;
  margin-bottom: 8px;
  font-size: 17px;
}

.doc-content p,
.faq-answer {
  max-width: 760px;
  margin-bottom: 16px;
  color: var(--text-muted);
  font-size: 16px;
  line-height: 1.75;
}

.legal-panel {
  margin: 28px 0;
  padding: 24px;
}

.legal-panel h3 {
  margin: 0 0 14px;
}

.question-list {
  margin-top: 32px;
}

.faq-item {
  padding: 28px 32px;
  border-bottom: 1px solid var(--border);
}

.faq-item:last-child {
  border-bottom: 0;
}

.faq-question {
  margin-top: 0;
  margin-bottom: 12px;
  font-size: 20px;
  letter-spacing: -0.015em;
}

.contact-panel {
  margin-top: 48px;
  padding: 28px 32px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
}

.contact-panel h2,
.contact-panel h3 {
  margin-top: 0;
  margin-bottom: 10px;
}

footer {
  border-top: 1px solid var(--border);
  padding: 40px 0 56px;
}

.footer-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-left,
.footer-links {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: var(--text-muted);
}

.footer-left .logo-mark {
  width: 20px;
  height: 20px;
}

.footer-links {
  gap: 18px;
  font-family: var(--font-mono);
  font-size: 12px;
}

.footer-links a {
  color: var(--text-faint);
  transition: color 0.15s;
}

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

@media (max-width: 900px) {
  .nav-links {
    display: none;
  }

  .hero {
    min-height: calc(86vh - 64px);
    min-height: calc(86dvh - 64px);
    padding-top: 72px;
  }

  section {
    padding: 72px 0;
  }

  .container {
    padding: 0 20px;
  }

  nav {
    padding: 0 20px;
  }

  .product-panel-main,
  .price-panel-main,
  .mode-grid,
  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .principles {
    grid-template-columns: 1fr;
  }

  .principle,
  .price-item:first-child {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .principle:last-child {
    border-bottom: 0;
  }

  .price-note {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-inner {
    padding: 0 20px;
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 520px) {
  .logo span:not(.logo-divider) {
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .doc-hero {
    padding-top: 56px;
  }

  .faq-item,
  .price-item,
  .price-note,
  .product-panel-main {
    padding: 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
