:root {
  --bg: #0f172a;
  --surface: #1e293b;
  --surface-alt: #334155;
  --surface-card: #1e293b;
  --border: #475569;
  --border-light: #64748b;
  --text: #f8fafc;
  --text-muted: #94a3b8;
  --primary: #38bdf8;
  --primary-hover: #0ea5e9;
  --accent: #34d399;
  --badge-bg: #0369a1;
  --badge-text: #e0f2fe;
  --badge-founder-bg: #854d0e;
  --badge-founder-text: #fef08a;
  --badge-free-bg: #334155;
  --badge-free-text: #cbd5e1;
  --container-max: 960px;
  --radius: 8px;
}

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

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Header & Nav */
.site-header {
  background-color: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  padding-top: 1rem;
  padding-bottom: 1rem;
  gap: 1rem;
}

.brand-link {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
}

.brand-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: -0.025em;
}

.brand-subtitle {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
}

.site-nav a {
  color: var(--text);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.site-nav a:hover,
.site-nav a:focus {
  background-color: var(--surface-alt);
  color: var(--primary);
}

/* Main Content */
.main-content {
  flex: 1;
  padding: 2.5rem 0;
}

.page-header {
  margin-bottom: 2.5rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 1.5rem;
}

.page-title {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 0.5rem;
  letter-spacing: -0.025em;
}

.page-subtitle {
  font-size: 1.1rem;
  color: var(--text-muted);
}

/* Sections */
.section {
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  margin-bottom: 2rem;
}

.section-title {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.section-subtitle {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  margin-top: 1.25rem;
  margin-bottom: 0.5rem;
}

p {
  margin-bottom: 1rem;
  color: var(--text);
}

p.muted {
  color: var(--text-muted);
  font-size: 0.95rem;
}

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

/* Bilingual text blocks */
.bilingual-block {
  margin-bottom: 1.25rem;
}

.bilingual-block:last-child {
  margin-bottom: 0;
}

.lang-en {
  margin-bottom: 0.5rem;
}

.lang-ja {
  color: var(--text-muted);
  font-size: 0.95rem;
}

li span.lang-en {
  display: block;
  margin-bottom: 0.25rem;
}

li span.lang-ja {
  display: block;
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* Lists */
ul, ol {
  margin-left: 1.5rem;
  margin-bottom: 1rem;
}

li {
  margin-bottom: 0.5rem;
}

/* Feature grid */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
  margin-top: 1.25rem;
}

.feature-card {
  background-color: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
}

.feature-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

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

.pricing-card {
  background-color: var(--surface-card);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  position: relative;
}

.pricing-card.featured {
  border-color: var(--primary);
  background-color: #1e293b;
}

.pricing-badge {
  display: inline-block;
  align-self: flex-start;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  margin-bottom: 0.75rem;
}

.pricing-badge.free {
  background-color: var(--badge-free-bg);
  color: var(--badge-free-text);
}

.pricing-badge.founder {
  background-color: var(--badge-founder-bg);
  color: var(--badge-founder-text);
}

.pricing-badge.pro {
  background-color: var(--badge-bg);
  color: var(--badge-text);
}

.tier-name {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 0.25rem;
}

.tier-price {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.tier-price-secondary {
  font-size: 1.25rem;
  color: var(--text-muted);
  margin-top: -0.25rem;
  margin-bottom: 0.75rem;
}

.tier-price-sub {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: normal;
}

.tier-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 1rem;
}

.tier-features {
  list-style: none;
  margin-left: 0;
  margin-bottom: 1.5rem;
  flex: 1;
}

.tier-features li {
  padding-left: 1.25rem;
  position: relative;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
}

.tier-features li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: bold;
}

.tier-notice {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: auto;
  border-top: 1px dashed var(--border);
  padding-top: 0.75rem;
}

/* Callout Box */
.callout {
  background-color: rgba(56, 189, 248, 0.08);
  border-left: 4px solid var(--primary);
  padding: 1rem 1.25rem;
  border-radius: 0 var(--radius) var(--radius) 0;
  margin: 1.25rem 0;
}

.callout.warning {
  background-color: rgba(234, 179, 8, 0.08);
  border-left-color: #eab308;
}

.callout-title {
  font-weight: 700;
  margin-bottom: 0.25rem;
  color: var(--primary);
}

.callout.warning .callout-title {
  color: #facc15;
}

/* Detail Box */
.detail-box {
  background-color: var(--surface-alt);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  margin: 1rem 0;
}

.detail-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
}

.detail-row:last-child {
  border-bottom: none;
}

.detail-label {
  font-weight: 600;
  color: var(--text-muted);
}

.detail-value {
  color: var(--text);
  font-weight: 500;
}

/* Links */
a.inline-link {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

a.inline-link:hover,
a.inline-link:focus {
  color: var(--primary-hover);
}

/* Plain text support email */
.support-email-text {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  background-color: var(--surface-alt);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.95em;
  color: var(--primary);
  word-break: break-all;
}

/* Footer */
.site-footer {
  background-color: var(--surface);
  border-top: 1px solid var(--border);
  padding: 2.5rem 0 1.5rem;
  margin-top: auto;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.footer-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary);
}

.footer-entity,
.footer-contact,
.footer-date {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--border);
}

.footer-nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.85rem;
}

.footer-nav a:hover,
.footer-nav a:focus {
  color: var(--primary);
}

.footer-legal {
  font-size: 0.8rem;
  color: var(--text-muted);
  padding-top: 0.5rem;
  border-top: 1px solid var(--border);
}

/* Responsive */
@media (max-width: 640px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
  }
  .site-nav {
    width: 100%;
    justify-content: flex-start;
  }
  .page-title {
    font-size: 1.6rem;
  }
  .section {
    padding: 1.25rem;
  }
}
