/* ── Theme Variables ── */
:root {
  color-scheme: dark;
  --bg:         #0f1923;
  --bg-alt:     #0d151f;
  --surface:    #1a2634;
  --surface-2:  #111d28;
  --border:     #243040;
  --text:       #e8eaed;
  --text-muted: #9aa0a6;
  --text-faint: #5f6368;
  --accent:     #4285f4;
  --accent-hov: #5a9cf8;
  --hero-grad:  linear-gradient(160deg, #1a2a3a 0%, #0f1923 60%);
  --shadow-sm:  0 2px 8px rgba(0,0,0,0.3);
  --shadow-md:  0 6px 24px rgba(0,0,0,0.45);
  --header-bg:  rgba(13, 21, 31, 0.92);
  --badge-bg:   rgba(66,133,244,0.15);
  --badge-border: rgba(66,133,244,0.3);
  --glow:       rgba(66,133,244,0.12);
}

[data-theme="light"] {
  color-scheme: light;
  --bg:         #ffffff;
  --bg-alt:     #f8f9fa;
  --surface:    #ffffff;
  --surface-2:  #f1f3f4;
  --border:     #e0e0e0;
  --text:       #202124;
  --text-muted: #5f6368;
  --text-faint: #9aa0a6;
  --accent:     #1a73e8;
  --accent-hov: #1557b0;
  --hero-grad:  linear-gradient(160deg, #e8f0fe 0%, #ffffff 60%);
  --shadow-sm:  0 2px 8px rgba(0,0,0,0.07);
  --shadow-md:  0 6px 24px rgba(0,0,0,0.1);
  --header-bg:  rgba(255, 255, 255, 0.92);
  --badge-bg:   rgba(26,115,232,0.1);
  --badge-border: rgba(26,115,232,0.25);
  --glow:       rgba(26,115,232,0.08);
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

/* ── Base ── */
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, sans-serif;
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.65;
  transition: background-color 0.25s ease, color 0.25s ease;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.container {
  max-width: 1020px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Header ── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--header-bg);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  transition: background 0.25s, border-color 0.25s;
}

.header-inner {
  display: flex;
  align-items: center;
  height: 62px;
  gap: 12px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
  flex-shrink: 0;
  transition: opacity 0.15s;
}
.logo:hover { opacity: 0.8; }
.logo-icon { font-size: 1.35rem; line-height: 1; }
.logo-img { width: 32px; height: 32px; display: block; flex-shrink: 0; }

.site-nav { margin-left: auto; }
.site-nav ul { list-style: none; display: flex; align-items: center; gap: 2px; }
.site-nav a {
  display: block;
  padding: 6px 11px;
  font-size: 0.85rem;
  color: var(--text-muted);
  border-radius: 7px;
  transition: color 0.15s, background 0.15s;
  white-space: nowrap;
}
.site-nav a:hover { color: var(--text); background: var(--surface); }
.site-nav a[aria-current="page"] { color: var(--accent); background: var(--badge-bg); font-weight: 600; }
.site-nav .nav-download {
  background: var(--accent);
  color: #ffffff !important;
  font-weight: 600;
  margin-left: 4px;
}
.site-nav .nav-download:hover { background: var(--accent-hov); }

.header-actions { display: flex; align-items: center; gap: 8px; }

.theme-toggle, .menu-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  flex-shrink: 0;
}
.theme-toggle:hover, .menu-toggle:hover {
  background: var(--surface);
  color: var(--text);
}

.icon-sun, .icon-moon { display: none; pointer-events: none; }
[data-theme="dark"]  .icon-sun  { display: block; }
[data-theme="light"] .icon-moon { display: block; }

.menu-toggle { display: none; }

/* ── Buttons ── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--accent);
  color: #ffffff;
  padding: 13px 30px;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.2s, transform 0.12s, box-shadow 0.2s;
  box-shadow: var(--shadow-sm);
  white-space: nowrap;
}
.btn-primary:hover {
  background: var(--accent-hov);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  color: #ffffff;
}
.btn-primary:active { transform: translateY(0); }

.btn-sm { padding: 8px 20px; font-size: 0.875rem; }

/* ── Hero ── */
.hero {
  padding: 96px 0 80px;
  text-align: center;
  background: var(--hero-grad);
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 50% at 50% 0%, var(--glow) 0%, transparent 70%);
  pointer-events: none;
}
.hero-badge {
  display: inline-block;
  background: var(--badge-bg);
  color: var(--accent);
  border: 1px solid var(--badge-border);
  border-radius: 100px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  padding: 4px 14px;
  margin-bottom: 22px;
}
.hero h1 {
  font-size: clamp(2.2rem, 6vw, 3.5rem);
  font-weight: 800;
  color: var(--text);
  margin-bottom: 20px;
  letter-spacing: -0.02em;
  line-height: 1.15;
}
.hero .tagline {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 40px;
  line-height: 1.7;
}
.hero .tagline strong { color: var(--text); font-weight: 600; }

/* ── Section commons ── */
section { padding: 72px 0; }
.section-alt { background: var(--surface-2); }

h2 {
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.015em;
  line-height: 1.25;
}
.section-sub {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-top: 12px;
  margin-bottom: 48px;
  max-width: 580px;
}
.text-center { text-align: center; }
.text-center .section-sub { margin-left: auto; margin-right: auto; }

/* ── Feature section ── */
.feature-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: start;
}
.feature-text h2 { margin-bottom: 18px; }
.feature-text p {
  color: var(--text-muted);
  margin-bottom: 14px;
  font-size: 1.02rem;
  line-height: 1.7;
}
.feature-text strong { color: var(--text); }

.feature-steps { display: flex; flex-direction: column; gap: 16px; }

.feature-img img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  display: block;
  object-fit: cover;
}

.feature-img--portrait {
  display: flex;
  justify-content: center;
}
.feature-img--portrait img {
  width: auto;
  max-height: 480px;
  object-fit: contain;
}

.feature-img--pair {
  display: flex;
  gap: 8px;
  align-items: flex-start;
}
.feature-img--pair img {
  flex: 1;
  width: 0;
  min-width: 0;
  max-height: 480px;
  object-fit: contain;
}
.step {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 16px 18px;
  background: var(--surface);
  border-radius: 12px;
  border: 1px solid var(--border);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.step:hover { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.step-num {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 0.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
}
.step h3 { font-size: 0.92rem; font-weight: 600; color: var(--text); margin-bottom: 4px; }
.step p   { font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; }

/* ── CTA Banner ── */
.cta-banner { padding: 44px 0; text-align: center; }

/* ── Use Cases ── */
.use-cases { text-align: center; }
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  text-align: left;
}
.card {
  padding: 28px 26px;
  background: var(--surface);
  border-radius: 16px;
  border: 1px solid var(--border);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s;
}
.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  border-color: rgba(66,133,244,0.3);
}
.card-icon { display: flex; align-items: center; justify-content: center; width: 56px; height: 56px; border-radius: 14px; background: rgba(66,133,244,0.12); color: var(--accent); margin: 0 auto 16px; }
.card-img {
  width: calc(100% + 52px);
  margin: -28px -26px 20px;
  height: 180px;
  object-fit: cover;
  border-radius: 16px 16px 0 0;
  display: block;
}
.card h3 { font-size: 1.08rem; font-weight: 600; color: var(--text); margin-bottom: 10px; }
.card p  { font-size: 0.9rem; color: var(--text-muted); line-height: 1.6; }

/* ── Video ── */
.video-section { text-align: center; }
.video-section h2 { margin-bottom: 10px; }
.video-wrapper {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  margin-top: 40px;
}
.video-wrapper iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  border: none;
}

/* ── Contact ── */
.contact { text-align: center; }
.contact h2 { margin-bottom: 14px; }
.contact p { font-size: 1.05rem; color: var(--text-muted); }
.contact a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.15s;
}
.contact a:hover { color: var(--accent-hov); }

/* ── Footer ── */
footer {
  padding: 40px 0;
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
}
.footer-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 16px;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 24px;
  margin-bottom: 16px;
}
.footer-links a {
  color: var(--text-muted);
  font-size: 0.875rem;
  transition: color 0.15s;
}
.footer-links a:hover { color: var(--text); }
.copyright { font-size: 0.8rem; color: var(--text-faint); }

/* ── Inner pages ── */
.page { padding: 64px 0 80px; min-height: 60vh; }
.page h1 {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-weight: 700;
  color: var(--text);
  margin-bottom: 40px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}
.page-content h2 {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text);
  margin: 32px 0 12px;
}
.page-content h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin: 24px 0 8px;
}
.page-content p  { color: var(--text-muted); margin-bottom: 16px; }
.page-content ul,
.page-content ol { color: var(--text-muted); padding-left: 24px; margin-bottom: 16px; }
.page-content li { margin-bottom: 8px; }
.page-content a  { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.page-content strong { color: var(--text); }
.page-content em { color: var(--text-muted); font-style: italic; }

/* ── Responsive ── */
@media (max-width: 860px) {
  .site-nav {
    display: none;
    position: absolute;
    top: 62px;
    left: 0;
    right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 12px 20px 16px;
    box-shadow: var(--shadow-md);
  }
  .site-nav.nav-open { display: block; }
  .site-nav ul { flex-direction: column; align-items: flex-start; gap: 2px; }
  .site-nav a  { padding: 9px 12px; font-size: 0.95rem; width: 100%; }
  .site-nav .nav-download { margin-left: 0; margin-top: 4px; }
  .menu-toggle { display: flex; }
  .feature-inner { grid-template-columns: 1fr; gap: 40px; }
  .cards { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  .hero { padding: 72px 0 56px; }
  section { padding: 56px 0; }
  .footer-top { flex-direction: column; align-items: flex-start; }
}
