:root {
  --bg: #101012;
  --bg-elevated: #1a1a1f;
  --bg-elevated-2: #232329;
  --border: rgba(255, 255, 255, 0.09);
  --text: #f3f3f6;
  --text-muted: #9b9ba6;
  --accent: #7b68ee;
  --accent-bright: #9b8bff;
  --accent-dark: #5b46c9;
  --accent-soft: rgba(123, 104, 238, 0.16);
  --font-sans: "Inter", "Noto Sans JP", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-display: "Space Grotesk", var(--font-sans);
  --max-width: 1120px;
  --radius: 16px;
  --shadow-glow: 0 20px 60px -20px rgba(123, 104, 238, 0.45);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-display);
  color: var(--text);
}

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

a {
  color: var(--accent-bright);
}

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

/* ---------- Header ---------- */
.app-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  background: rgba(16, 16, 18, 0.75);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.app-header__logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.app-header__logo img {
  height: 34px;
  width: 34px;
}

.app-header__logo span {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
  color: var(--text);
  letter-spacing: -0.01em;
}

.app-header__logo span em {
  font-style: normal;
  color: var(--accent-bright);
}

.menu-button {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 16px;
  font-size: 14px;
  font-family: var(--font-sans);
  color: var(--text);
  cursor: pointer;
}

.menu-button:hover {
  border-color: var(--accent);
  color: var(--accent-bright);
}

.menu-button__bars {
  display: inline-flex;
  flex-direction: column;
  gap: 3px;
}

.menu-button__bars span {
  width: 18px;
  height: 2px;
  background: currentColor;
  display: block;
}

/* ---------- Nav drawer ---------- */
.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 200;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.nav-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(320px, 85vw);
  background: var(--bg-elevated);
  border-left: 1px solid var(--border);
  z-index: 201;
  transform: translateX(100%);
  transition: transform 0.25s ease;
  display: flex;
  flex-direction: column;
  padding: 20px;
}

body.nav-open .nav-overlay {
  opacity: 1;
  pointer-events: auto;
}

body.nav-open .nav-drawer {
  transform: translateX(0);
}

.nav-drawer__close {
  align-self: flex-end;
  background: none;
  border: none;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  color: var(--text-muted);
  padding: 8px;
}

.nav-drawer__list {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
}

.nav-drawer__list li + li {
  border-top: 1px solid var(--border);
}

.nav-drawer__list a {
  display: block;
  padding: 16px 8px;
  text-decoration: none;
  color: var(--text);
  font-size: 16px;
}

.nav-drawer__list a:hover {
  color: var(--accent-bright);
}

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

.app-hero::before {
  content: "";
  position: absolute;
  top: -220px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 560px;
  background: radial-gradient(closest-side, var(--accent-soft), transparent);
  z-index: 0;
}

.app-hero > * {
  position: relative;
  z-index: 1;
}

.app-hero__eyebrow {
  display: inline-block;
  padding: 7px 18px;
  border-radius: 999px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--accent-bright);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.06em;
  margin-bottom: 24px;
}

.app-hero h1 {
  font-size: clamp(36px, 6vw, 64px);
  font-weight: 700;
  margin: 0 0 20px;
  letter-spacing: -0.02em;
}

.app-hero h1 em {
  font-style: normal;
  background: linear-gradient(100deg, var(--accent-bright), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.app-hero p {
  max-width: 640px;
  margin: 0 auto;
  color: var(--text-muted);
  font-size: clamp(16px, 2.2vw, 19px);
}

.app-hero__actions {
  margin-top: 36px;
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

.app-hero__shot {
  margin: 56px auto 0;
  max-width: 980px;
}

.app-hero__shot img {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-glow);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 13px 30px;
  border-radius: 10px;
  background: linear-gradient(100deg, var(--accent), var(--accent-dark));
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  box-shadow: 0 10px 30px -10px rgba(123, 104, 238, 0.6);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  border: none;
  cursor: pointer;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 34px -8px rgba(123, 104, 238, 0.75);
}

.btn-outline {
  background: transparent;
  border: 1.5px solid var(--border);
  color: var(--text);
  box-shadow: none;
}

.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent-bright);
  transform: translateY(-2px);
}

.btn[disabled] {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

/* ---------- Sections ---------- */
.section {
  padding: 88px 0;
  border-top: 1px solid var(--border);
}

.section-eyebrow {
  display: block;
  text-align: center;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--accent-bright);
  margin-bottom: 10px;
}

.section h2 {
  font-size: clamp(26px, 3.4vw, 36px);
  text-align: center;
  margin: 0 0 16px;
  letter-spacing: -0.01em;
}

.section-lead {
  max-width: 680px;
  margin: 0 auto 48px;
  text-align: center;
  color: var(--text-muted);
}

/* ---------- Feature grid ---------- */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
  max-width: 1080px;
  margin: 0 auto;
}

.feature-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
}

.feature-card__shot {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #000;
  border-bottom: 1px solid var(--border);
}

.feature-card__shot--pending {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(160deg, var(--bg-elevated-2), var(--bg-elevated));
}

.feature-card__shot--pending span {
  color: var(--text-muted);
  font-size: 13px;
  letter-spacing: 0.04em;
}

.feature-card__shot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  border-radius: 0;
  border: none;
}

.feature-card__body {
  padding: 22px 24px 26px;
}

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

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

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

.pricing-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
}

.pricing-card--highlight {
  border-color: var(--accent);
  background: linear-gradient(160deg, var(--bg-elevated-2), var(--bg-elevated));
  box-shadow: var(--shadow-glow);
}

.pricing-card__badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--accent-bright);
  background: var(--accent-soft);
  padding: 4px 12px;
  border-radius: 999px;
  margin-bottom: 12px;
}

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

.pricing-card .price {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 700;
  color: var(--text);
  margin: 10px 0;
}

.pricing-card .price small {
  font-size: 13px;
  font-weight: 400;
  color: var(--text-muted);
}

.pricing-card ul {
  text-align: left;
  padding-left: 20px;
  font-size: 14px;
  color: var(--text-muted);
  margin: 16px 0 0;
}

.pricing-note {
  max-width: 680px;
  margin: 0 auto;
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
}

/* ---------- Steps (how to buy) ---------- */
.buy-steps {
  max-width: 1080px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 56px;
}

.buy-step {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 40px;
  align-items: center;
}

.buy-step:nth-child(even) .buy-step__text {
  order: 2;
}

.buy-step__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent-bright);
  font-family: var(--font-display);
  font-weight: 700;
  margin-bottom: 16px;
}

.buy-step__text h3 {
  font-size: 20px;
  margin: 0 0 10px;
}

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

.buy-step__shot img,
.buy-step__shot-row {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: 0 20px 50px -25px rgba(0, 0, 0, 0.6);
}

.buy-step__shot-row {
  display: flex;
  overflow: hidden;
}

.buy-step__shot-row img {
  border-radius: 0;
  border: none;
  box-shadow: none;
  flex: 1;
  object-fit: cover;
}

.buy-step__shot-row img + img {
  border-left: 1px solid var(--border);
}

@media (max-width: 780px) {
  .buy-step {
    grid-template-columns: 1fr;
  }

  .buy-step:nth-child(even) .buy-step__text {
    order: 0;
  }
}

/* ---------- Legal ---------- */
table.legal-table {
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  border-collapse: collapse;
}

table.legal-table th,
table.legal-table td {
  text-align: left;
  padding: 14px 12px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

table.legal-table th {
  width: 30%;
  color: var(--text-muted);
  font-weight: 500;
  white-space: nowrap;
}

/* ---------- Footer ---------- */
.app-footer {
  background: #0a0a0b;
  color: var(--text-muted);
  padding: 40px 24px 24px;
  font-size: 14px;
  border-top: 1px solid var(--border);
}

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

.app-footer .container {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  justify-content: space-between;
}

.app-footer__brand {
  display: flex;
  flex-direction: column;
}

.app-footer__brand-lockup {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.app-footer__brand-lockup img {
  height: 28px;
  width: 28px;
}

.app-footer__brand-lockup span {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 16px;
  color: var(--text);
}

.app-footer__links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.app-footer__links li {
  margin-bottom: 8px;
}

@media (max-width: 640px) {
  .app-hero {
    padding: 72px 16px 48px;
  }

  .section {
    padding: 56px 0;
  }
}

/* ===== 購入・復旧ページ用（サンクスページ / ライセンス再送） ===== */
.form-panel {
  max-width: 560px;
  margin: 0 auto;
  padding: 32px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: left;
}

.form-panel label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  font-size: 0.95rem;
}

.form-panel input[type="email"] {
  width: 100%;
  padding: 13px 15px;
  margin-bottom: 18px;
  font-family: inherit;
  font-size: 1rem;
  color: var(--text);
  background: var(--bg-elevated-2);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.form-panel input[type="email"]:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.form-panel .btn {
  width: 100%;
}

/* 発行されたライセンスキーの表示枠。選択してコピーしやすいよう等幅・大きめにする */
.license-key {
  margin: 24px auto;
  padding: 20px;
  max-width: 560px;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 1.35rem;
  letter-spacing: 0.06em;
  word-break: break-all;
  text-align: center;
  color: var(--accent-bright);
  background: var(--bg-elevated-2);
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  user-select: all;
}

.status-message {
  max-width: 560px;
  margin: 18px auto 0;
  padding: 14px 18px;
  border-radius: 10px;
  font-size: 0.95rem;
  line-height: 1.7;
  background: var(--bg-elevated-2);
  border: 1px solid var(--border);
}

.status-message--error {
  border-color: rgba(255, 120, 120, 0.5);
  color: #ffb3b3;
}

.status-message--ok {
  border-color: rgba(123, 104, 238, 0.6);
}

.next-steps {
  max-width: 560px;
  margin: 28px auto 0;
  padding-left: 1.3em;
  text-align: left;
  line-height: 1.9;
  color: var(--text-muted);
}

/* 料金カードの補足。Web購入は買い切りのみで、他プランはアプリ内購入である旨を示す */
.pricing-card__note {
  margin: 18px 0 0;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.pricing-card .btn {
  width: 100%;
  margin-top: 18px;
}
