:root {
  --bg: #F6F5F2;
  --card: #FFFFFF;
  --primary: #2F5D50;
  --accent: #2F5D50;
  --reject: #B04A41;
  --text: #1F2421;
  --muted: #5F6B66;
  --border: #E4E2DC;
  --ink: #1F2421;
  --ink-contrast: #FFFFFF;
  --radius: 24px;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #151816;
    --card: #1F2421;
    --primary: #3D7A68;
    --accent: #8CC7B4;
    --reject: #D9766D;
    --text: #ECEBE7;
    --muted: #A4ADA8;
    --border: #2E3530;
    --ink: #ECEBE7;
    --ink-contrast: #151816;
  }
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
}

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

img { max-width: 100%; }

.wrap {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 20px;
}

.legal-wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 20px;
}

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

h1 { font-size: 32px; margin: 32px 0 16px; }
h2 { font-size: 22px; margin: 36px 0 12px; }
h3 { font-size: 18px; margin: 24px 0 8px; }
p { margin: 0 0 16px; }
ul, ol { margin: 0 0 16px; padding-left: 22px; }
li { margin-bottom: 6px; }

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

/* Header */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 18px 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 18px;
  color: var(--text);
  text-decoration: none;
}

.brand img { width: 28px; height: 28px; }

.site-nav a {
  margin-left: 16px;
  font-size: 15px;
  color: var(--muted);
  text-decoration: none;
}

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

/* Hero */
.hero {
  display: grid;
  gap: 40px;
  padding: 32px 0 48px;
}

.hero-lead {
  font-size: 18px;
  color: var(--muted);
  max-width: 520px;
}

.store-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.btn-store {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  min-width: 180px;
  padding: 10px 18px;
  border-radius: 14px;
  background: var(--ink);
  color: var(--ink-contrast);
  text-decoration: none;
  line-height: 1.25;
}

.btn-store strong { font-size: 17px; font-weight: 600; }
.btn-store small { font-size: 12px; opacity: 0.8; }

.btn-primary {
  display: inline-block;
  padding: 12px 22px;
  border-radius: 14px;
  background: var(--primary);
  color: #FFFFFF;
  font-weight: 600;
  text-decoration: none;
}

.btn-secondary {
  display: inline-block;
  padding: 12px 22px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text);
  font-weight: 600;
  text-decoration: none;
}

/* Sections and cards */
section.block { padding: 32px 0; }

.card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
}

.grid { display: grid; gap: 16px; }

.steps { counter-reset: step; }

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary);
  color: #FFFFFF;
  font-weight: 600;
  margin-bottom: 12px;
}

/* Chips */
.chip {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
}

.chip-approve {
  background: rgba(47, 93, 80, 0.14);
  color: var(--primary);
}

.chip-reject {
  background: rgba(176, 74, 65, 0.14);
  color: var(--reject);
}

/* Phone mock */
.phone-wrap {
  display: flex;
  justify-content: center;
}

.phone {
  width: 280px;
  height: 560px;
  padding: 12px;
  border-radius: 44px;
  background: #1D201E;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.18);
}

.phone-screen {
  height: 100%;
  border-radius: 34px;
  background: var(--bg);
  padding: 44px 14px 16px;
  overflow: hidden;
}

.phone-title {
  font-size: 13px;
  color: var(--muted);
  text-align: center;
  margin: 0 0 14px;
}

.approval-card {
  background: var(--card);
  border-radius: 24px;
  padding: 18px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.approval-kicker {
  font-size: 12px;
  color: var(--muted);
  margin: 0 0 12px;
}

.product {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.product-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: linear-gradient(135deg, #E9E7E1, #C9C6BD);
  flex-shrink: 0;
}

.product-name { font-weight: 600; font-size: 16px; line-height: 1.3; }
.product-price { font-weight: 600; color: var(--primary); font-size: 15px; }

.approval-reason {
  font-size: 14px;
  color: var(--muted);
  background: var(--bg);
  border-radius: 12px;
  padding: 10px 12px;
  margin: 0 0 14px;
}

.vote-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.avatars { display: flex; align-items: center; }

.avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--primary);
  color: #FFFFFF;
  font-size: 11px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-right: -6px;
  border: 2px solid var(--card);
}

.avatar-2 { background: var(--reject); }
.avatar-3 { background: #7A8A84; }

/* FAQ */
details.faq {
  background: var(--card);
  border-radius: 16px;
  padding: 16px 20px;
  margin-bottom: 12px;
}

details.faq summary {
  cursor: pointer;
  font-weight: 600;
  list-style-position: outside;
}

details.faq p {
  margin: 12px 0 0;
  color: var(--muted);
}

/* Legal pages */
.legal h2 { margin-top: 32px; }
.legal .meta { color: var(--muted); font-size: 14px; margin-bottom: 24px; }

.notice {
  background: var(--card);
  border-left: 4px solid var(--primary);
  border-radius: 12px;
  padding: 14px 16px;
  margin: 0 0 24px;
}

/* Footer */
.site-footer {
  margin-top: 48px;
  border-top: 1px solid var(--border);
  padding: 28px 0 40px;
  font-size: 14px;
  color: var(--muted);
}

.site-footer nav a {
  display: inline-block;
  margin: 0 16px 8px 0;
  color: var(--muted);
}

/* Join and delete pages */
.code-display {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 48px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-align: center;
  word-break: break-all;
  margin: 24px 0;
  color: var(--primary);
}

.center { text-align: center; }

.actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: stretch;
  margin-top: 24px;
}

.actions .btn-primary,
.actions .btn-secondary { text-align: center; }

.steps-list { padding-left: 22px; }

.hidden { display: none !important; }

@media (min-width: 640px) {
  h1 { font-size: 44px; }
  .actions { flex-direction: row; justify-content: center; }
  .actions .btn-primary,
  .actions .btn-secondary { min-width: 200px; }
  .features { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 900px) {
  .hero {
    grid-template-columns: 1.1fr 0.9fr;
    align-items: center;
    padding: 64px 0 56px;
  }
  .hero h1 { font-size: 52px; }
}
