:root {
  --bg: #f7f7f8;
  --bg-elevated: #ffffff;
  --text: #16171a;
  --text-muted: #5b5d66;
  --border: #e6e6ea;
  --accent: #4f6df5;
  --accent-2: #7c5cff;
  --accent-contrast: #ffffff;
  --code-bg: #101116;
  --shadow: 0 20px 50px -20px rgba(20, 20, 40, 0.25);
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 8px;
  --max-width: 1080px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b0c10;
    --bg-elevated: #15161c;
    --text: #f2f2f5;
    --text-muted: #9a9ca8;
    --border: #24252d;
    --shadow: 0 20px 60px -20px rgba(0, 0, 0, 0.6);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Sans",
    "Hiragino Kaku Gothic ProN", "Noto Sans JP", sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  word-break: keep-all;
  overflow-wrap: break-word;
}

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

a { color: inherit; }

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Header ---------- */
header.site {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: saturate(180%) blur(14px);
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  border-bottom: 1px solid var(--border);
}

header.site .wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
  text-decoration: none;
  margin-right: auto;
}

.brand img { width: 30px; height: 30px; border-radius: 8px; }

nav.primary {
  display: flex;
  align-items: center;
  gap: 4px;
}

nav.primary a {
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.92rem;
  font-weight: 500;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  transition: color 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}

nav.primary a:hover { color: var(--text); background: var(--bg-elevated); }
nav.primary a.current { color: var(--text); }

.lang-switch {
  margin-left: 8px;
  padding-left: 12px;
  border-left: 1px solid var(--border);
}

.lang-switch a {
  font-size: 0.85rem;
  opacity: 0.8;
}
.lang-switch a:hover { opacity: 1; }

/* ---------- Hero ---------- */
.hero {
  padding: 96px 0 72px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: -40% -10% auto -10%;
  height: 480px;
  background: radial-gradient(60% 60% at 50% 30%, color-mix(in srgb, var(--accent) 22%, transparent), transparent 70%);
  z-index: -1;
  pointer-events: none;
}

.hero .icon {
  width: 96px;
  height: 96px;
  border-radius: 24px;
  box-shadow: var(--shadow);
  margin: 0 auto 28px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  border-radius: 999px;
  padding: 6px 14px;
  margin-bottom: 20px;
}

h1.headline {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0 0 18px;
  line-height: 1.15;
}

h1.headline .gradient {
  background: linear-gradient(100deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.subhead {
  font-size: clamp(1.02rem, 2vw, 1.2rem);
  color: var(--text-muted);
  max-width: 640px;
  margin: 0 auto 36px;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, border-color .15s ease;
}

.btn:active { transform: translateY(1px); }

.btn-primary {
  background: linear-gradient(100deg, var(--accent), var(--accent-2));
  color: #fff;
  box-shadow: 0 10px 30px -10px color-mix(in srgb, var(--accent) 60%, transparent);
}
.btn-primary:hover { box-shadow: 0 14px 34px -8px color-mix(in srgb, var(--accent) 70%, transparent); }

.btn-secondary {
  background: var(--bg-elevated);
  color: var(--text);
  border-color: var(--border);
}
.btn-secondary:hover { border-color: color-mix(in srgb, var(--accent) 40%, var(--border)); }

.platform-row {
  margin-top: 28px;
  display: flex;
  gap: 22px;
  justify-content: center;
  flex-wrap: wrap;
  color: var(--text-muted);
  font-size: 0.85rem;
}
.platform-row span { display: inline-flex; align-items: center; gap: 6px; }
.platform-row svg { width: 16px; height: 16px; color: var(--accent); }

/* ---------- Screenshot showcase ---------- */
.showcase {
  padding: 20px 0 80px;
}

.showcase figure {
  margin: 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  background: var(--bg-elevated);
}

.showcase figcaption {
  padding: 14px 20px;
  font-size: 0.88rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  text-align: center;
}

/* ---------- Sections ---------- */
section.section { padding: 72px 0; }
section.section.alt { background: var(--bg-elevated); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }

.section-head {
  text-align: center;
  max-width: 620px;
  margin: 0 auto 48px;
}

.section-head h2 {
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  letter-spacing: -0.02em;
  margin: 0 0 12px;
  font-weight: 800;
}

.section-head p { color: var(--text-muted); margin: 0; }

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.feature-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 26px;
}

.icon-box {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  color: var(--accent);
  margin-bottom: 16px;
}
.icon-box svg { width: 22px; height: 22px; }

.feature-card h3 {
  font-size: 1.05rem;
  margin: 0 0 8px;
  font-weight: 700;
}

.feature-card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.92rem;
}

/* ---------- Pricing ---------- */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  max-width: 760px;
  margin: 0 auto;
}

.price-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
}

.price-card.pro {
  border-color: color-mix(in srgb, var(--accent) 50%, var(--border));
  box-shadow: var(--shadow);
  position: relative;
}

.price-card .badge {
  position: absolute;
  top: -12px;
  right: 24px;
  background: linear-gradient(100deg, var(--accent), var(--accent-2));
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 999px;
}

.price-card h3 { margin: 0 0 4px; font-size: 1.2rem; font-weight: 800; }
.price-card .price { font-size: 1.9rem; font-weight: 800; margin: 12px 0 20px; }
.price-card .price small { font-size: 0.9rem; color: var(--text-muted); font-weight: 500; }

.price-card ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.price-card li { display: flex; gap: 10px; font-size: 0.92rem; color: var(--text-muted); }
.price-card li::before { content: "✓"; color: var(--accent); font-weight: 700; }

/* ---------- Download ---------- */
.download-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.download-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 22px;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 14px;
  transition: border-color .15s ease, transform .15s ease;
}
.download-card:hover { border-color: color-mix(in srgb, var(--accent) 50%, var(--border)); transform: translateY(-2px); }
.download-card.is-pending { cursor: default; }
.download-card.is-pending:hover { border-color: var(--border); transform: none; }
.download-card.is-pending .glyph { opacity: 0.7; }
.download-card.is-pending span { color: var(--accent); font-weight: 600; }
.download-card .glyph {
  width: 42px; height: 42px; border-radius: 11px;
  display: flex; align-items: center; justify-content: center;
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  font-size: 1.3rem; flex-shrink: 0;
}
.download-card strong { display: block; font-size: 0.98rem; }
.download-card span { display: block; font-size: 0.82rem; color: var(--text-muted); margin-top: 2px; }

/* ---------- Content pages (privacy / support) ---------- */
.page-hero {
  padding: 64px 0 24px;
  text-align: center;
}
.page-hero h1 { font-size: clamp(1.8rem, 4vw, 2.4rem); font-weight: 800; letter-spacing: -0.02em; margin: 0 0 10px; }
.page-hero p { color: var(--text-muted); margin: 0; }

.content {
  max-width: 720px;
  margin: 0 auto;
  padding: 24px 24px 96px;
}

.content h2 { font-size: 1.25rem; margin: 40px 0 12px; font-weight: 700; }
.content h2:first-child { margin-top: 0; }
.content p, .content li { color: var(--text-muted); font-size: 0.96rem; }
.content ul { padding-left: 1.2em; }
.content .updated { font-size: 0.85rem; color: var(--text-muted); text-align: center; margin-bottom: 8px; }

/* ---------- Support form ---------- */
.support-form {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  max-width: 560px;
  margin: 0 auto;
  box-shadow: var(--shadow);
}

.field { margin-bottom: 18px; }
.field label { display: block; font-size: 0.88rem; font-weight: 600; margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%;
  padding: 11px 13px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 0.95rem;
  font-family: inherit;
  resize: vertical;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent);
}

.support-form .btn { width: 100%; justify-content: center; margin-top: 6px; }
.support-note { font-size: 0.82rem; color: var(--text-muted); margin-top: 14px; text-align: center; }

/* ---------- Footer ---------- */
footer.site {
  border-top: 1px solid var(--border);
  padding: 40px 0;
  color: var(--text-muted);
  font-size: 0.85rem;
}
footer.site .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  align-items: center;
  justify-content: space-between;
}
footer.site nav { display: flex; gap: 18px; flex-wrap: wrap; }
footer.site a { text-decoration: none; color: var(--text-muted); }
footer.site a:hover { color: var(--text); }

@media (max-width: 640px) {
  nav.primary a.nav-link { display: none; }
  .lang-switch { margin-left: auto; padding-left: 0; border-left: none; }
}
