:root {
  --bg: #ffffff;
  --surface: #f5f6f5;
  --surface-2: #ececec;
  --text: #111311;
  --text-muted: #666d66;
  --text-faint: #9aa19a;
  --border: #e6e9e6;
  --accent: #16a34a;
  --accent-soft: #e9f7ee;
  --accent-ink: #14532d;
  --ink: #111311;
  --ink-text: #ffffff;
  --radius: 16px;
  --radius-lg: 24px;
  --maxw: 1040px;
  --maxw-text: 680px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f110f;
    --surface: #171a17;
    --surface-2: #22261f;
    --text: #eef1ee;
    --text-muted: #9aa39a;
    --text-faint: #6b736b;
    --border: #262b26;
    --accent: #4ade80;
    --accent-soft: #16241b;
    --accent-ink: #bbf7d0;
    --ink: #f2f4f2;
    --ink-text: #0f110f;
  }
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

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

/* ---------- header ---------- */
.site-head {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 14px 0;
}
.site-head .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand {
  display: inline-flex;
  align-items: center;
  color: var(--text);
  text-decoration: none;
  line-height: 0;
}
.brand-mark {
  height: 22px;
  width: auto;
  aspect-ratio: 3793 / 943;
  display: block;
}
.nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 15px;
}
.nav a {
  color: var(--text-muted);
  text-decoration: none;
}
.nav a:hover { color: var(--text); }
.nav .btn { padding: 9px 16px; font-size: 14px; }
@media (max-width: 640px) {
  .nav { gap: 14px; }
  .nav a.nav-link { display: none; }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--ink);
  color: var(--ink-text);
  padding: 14px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 16px;
  text-decoration: none;
  line-height: 1.2;
  transition: opacity .15s ease, transform .15s ease;
}
.btn:hover { opacity: .88; }
.btn:active { transform: scale(.98); }
.btn[aria-disabled="true"] {
  background: var(--surface);
  color: var(--text-muted);
  border: 1px solid var(--border);
  cursor: default;
  pointer-events: none;
}
.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-note {
  display: block;
  margin-top: 12px;
  font-size: 14px;
  color: var(--text-muted);
}

/* ---------- landing sections ---------- */
.section { padding: 96px 0; }
.section + .section { border-top: 1px solid var(--border); }
.section-head { max-width: 40em; margin: 0 auto 48px; text-align: center; }
.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}
h2.title {
  font-size: 36px;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 14px;
}
.section-head p {
  font-size: 18px;
  color: var(--text-muted);
  margin: 0;
}

/* hero */
.hero {
  padding: 88px 0 40px;
  text-align: center;
}
.hero h1 {
  font-size: 56px;
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin: 0 auto 20px;
  max-width: 14em;
}
.hero p.lead {
  font-size: 20px;
  color: var(--text-muted);
  margin: 0 auto 32px;
  max-width: 32em;
}
.hero-cta { display: flex; flex-direction: column; align-items: center; }
.hero-visual {
  margin: 64px auto 0;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 28px;
}

/* how it works */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.step {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 28px 28px 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: hidden;
}
.step .num {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  color: var(--accent);
}
.step h3 {
  font-size: 22px;
  letter-spacing: -0.01em;
  margin: 0;
  line-height: 1.25;
}
.step p {
  margin: 0 0 12px;
  font-size: 15.5px;
  color: var(--text-muted);
  line-height: 1.55;
}
.step .shot {
  margin-top: auto;
  padding-top: 0;
  background: var(--bg);
  border: 1px solid var(--border);
  border-bottom: 0;
  border-radius: 18px 18px 0 0;
  padding: 18px 18px 0;
  margin-top: 22px;
  min-height: 190px;
  box-shadow: 0 -1px 0 var(--border);
}

/* features */
.features {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
.feature {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
}
.feature h3 {
  font-size: 20px;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}
.feature p {
  margin: 0;
  font-size: 15.5px;
  color: var(--text-muted);
  line-height: 1.55;
}
.feature .demo { margin-bottom: 20px; }

/* personality chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: 999px;
  background: var(--surface);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.2;
}
.chip.on { background: var(--ink); color: var(--ink-text); }
.chip.add { background: var(--accent-soft); color: var(--accent); border: 1px solid transparent; }

/* FAQ */
.faq { max-width: var(--maxw-text); margin: 0 auto; }
.faq details {
  border-bottom: 1px solid var(--border);
  padding: 4px 0;
}
.faq summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 18px 0;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  flex: 0 0 auto;
  width: 28px; height: 28px;
  border-radius: 50%;
  border: 1px solid var(--border);
  display: inline-flex; align-items: center; justify-content: center;
  font-weight: 400;
  color: var(--text-muted);
  transition: transform .2s ease;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p {
  margin: 0 0 20px;
  color: var(--text-muted);
  font-size: 16px;
  max-width: 38em;
}
.faq a { color: var(--accent); }

/* closing CTA */
.cta {
  text-align: center;
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 72px 24px;
}
.cta h2 {
  font-size: 34px;
  letter-spacing: -0.02em;
  margin: 0 0 10px;
}
.cta p { color: var(--text-muted); margin: 0 0 28px; }

/* ---------- CSS phone mock ---------- */
.phone {
  width: 300px;
  flex: 0 0 auto;
  background: var(--bg);
  border: 1px solid var(--border);
  border-bottom: 0;
  border-radius: 40px 40px 0 0;
  padding: 14px 14px 0;
  box-shadow: 0 30px 60px -30px rgba(0,0,0,.25), 0 0 0 6px var(--surface);
  text-align: left;
  overflow: hidden;
  height: 560px;
  position: relative;
}
.phone::before {
  content: "";
  display: block;
  width: 90px; height: 26px;
  background: var(--ink);
  border-radius: 999px;
  margin: 2px auto 12px;
}
.phone::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 70px;
  background: linear-gradient(to bottom, transparent, var(--bg));
  pointer-events: none;
}
.app-title { font-size: 22px; font-weight: 700; letter-spacing: -0.02em; margin: 4px 6px 12px; }
.post { padding: 0 4px; }
.post-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--surface-2);
  display: inline-flex; align-items: center; justify-content: center; font-size: 16px;
}
.avatar.lg { width: 44px; height: 44px; font-size: 20px; }
.post-head .who { line-height: 1.2; }
.post-head .who b { display: block; font-size: 14px; }
.post-head .who span { font-size: 12px; color: var(--text-faint); }
.photo {
  border-radius: 16px;
  height: 150px;
  background: linear-gradient(135deg, #cfe8d7, #9fcfb0 55%, #6fb88b);
  display: flex; align-items: flex-end; justify-content: flex-end;
  padding: 8px;
}
.photo.warm { background: linear-gradient(135deg, #f6e7cf, #e6c79a 55%, #cfa06a); }
.photo.p-samoyed { background: url(/assets/photo-samoyed.jpg) center 30% / cover no-repeat; }
.photo.p-cat { background: url(/assets/photo-cat.jpg) center 35% / cover no-repeat; }
.photo.p-golden { background: url(/assets/photo-golden.jpg) center 40% / cover no-repeat; }
.photo.sm { height: 96px; }
.photo .count {
  background: rgba(0,0,0,.55); color: #fff; font-size: 11px; font-weight: 600;
  padding: 3px 8px; border-radius: 999px;
}
.caption { font-size: 14px; margin: 10px 2px 8px; line-height: 1.4; }
.tags { display: flex; gap: 6px; margin: 0 0 10px; flex-wrap: wrap; }
.tag {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--surface); border-radius: 999px;
  padding: 5px 10px 5px 6px; font-size: 12px; font-weight: 600;
}
.tag i {
  width: 16px; height: 16px; border-radius: 50%; background: var(--surface-2); display: inline-block;
}
.tag.more { padding: 5px 10px; color: var(--text-muted); }
.apt {
  background: var(--accent-soft);
  color: var(--accent-ink);
  border-radius: 14px;
  padding: 11px 13px;
  font-size: 14px;
  line-height: 1.45;
  position: relative;
}
.apt .label {
  display: inline-block;
  font-size: 10px; font-weight: 800; letter-spacing: .08em;
  color: var(--accent);
  margin-bottom: 4px;
}
.meta-row { display: flex; gap: 16px; font-size: 13px; color: var(--text-muted); margin: 10px 2px 16px; }
.comment { font-size: 13px; line-height: 1.4; margin: 0 2px 8px; color: var(--text-muted); }
.comment b { color: var(--text); margin-right: 4px; }

/* small UI bits reused in steps */
.field {
  background: var(--surface); border-radius: 12px; padding: 10px 12px;
  font-size: 13px; margin-bottom: 10px;
}
.field small { display: block; font-size: 10px; letter-spacing: .06em; color: var(--text-faint); text-transform: uppercase; margin-bottom: 3px; }
.field.cursor::after { content: ""; display: inline-block; width: 1px; height: 13px; background: var(--accent); margin-left: 2px; vertical-align: -2px; }
.dark-btn {
  background: var(--ink); color: var(--ink-text); text-align: center;
  border-radius: 999px; padding: 11px; font-size: 13px; font-weight: 600; margin-top: 12px;
}
.badge-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.badge {
  aspect-ratio: 1; border-radius: 14px; background: var(--surface);
  display: flex; flex-direction: column; align-items: center; justify-content: flex-start;
  padding: 16% 8px 0;
  font-size: 11px; font-weight: 600; line-height: 1.2; text-align: center;
}
.badge i {
  width: 28px; height: 28px; border-radius: 50%; background: var(--surface-2); display: flex;
  align-items: center; justify-content: center; font-style: normal; font-size: 16px; flex: 0 0 auto;
}
.badge span {
  display: flex; align-items: center; justify-content: center;
  height: 2.4em; margin-top: 8px;
}
.badge.new { background: var(--accent-soft); color: var(--accent); }
.badge.new i { background: transparent; color: var(--accent); font-weight: 700; }

/* ---------- document pages ---------- */
.doc { padding: 48px 0 80px; max-width: var(--maxw-text); }
.doc h1 {
  font-size: 32px;
  letter-spacing: -0.02em;
  margin: 0 0 6px;
}
.doc .meta {
  color: var(--text-muted);
  font-size: 14px;
  margin: 0 0 36px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}
.doc h2 { font-size: 20px; margin: 40px 0 10px; letter-spacing: -0.01em; }
.doc h3 { font-size: 16px; margin: 24px 0 6px; }
.doc p, .doc li { font-size: 16px; }
.doc ul { padding-left: 22px; }
.doc li { margin-bottom: 6px; }
.doc a { color: var(--accent); }

.callout {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 16px 18px;
  margin: 20px 0;
  font-size: 15px;
  color: var(--text-muted);
}
.callout strong { color: var(--text); }

table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 15px;
}
th, td {
  text-align: left;
  padding: 10px 12px;
  border: 1px solid var(--border);
  vertical-align: top;
}
th { background: var(--surface); font-weight: 600; }

/* centered notice pages */
.notice {
  min-height: 72vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 48px 20px;
}
.notice h1 { font-size: 30px; margin: 0 0 12px; letter-spacing: -0.02em; }
.notice p { color: var(--text-muted); margin: 0 auto 26px; max-width: 26em; }

/* ---------- footer ---------- */
.site-foot {
  border-top: 1px solid var(--border);
  padding: 36px 0 48px;
  font-size: 14px;
  color: var(--text-muted);
}
.site-foot .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 14px 24px;
}
.site-foot .links { display: flex; flex-wrap: wrap; gap: 18px; }
.site-foot a { color: var(--text-muted); text-decoration: none; }
.site-foot a:hover { color: var(--text); }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .steps { grid-template-columns: 1fr; }
  .step { flex-direction: column; }
  .features { grid-template-columns: 1fr; }
  .hero-visual .phone:nth-child(2) { display: none; }
}
@media (max-width: 640px) {
  .section { padding: 64px 0; }
  .hero { padding: 56px 0 24px; }
  .hero h1 { font-size: 38px; }
  .hero p.lead { font-size: 17px; }
  h2.title { font-size: 28px; }
  .cta { padding: 48px 20px; }
  .cta h2 { font-size: 26px; }
  .phone { width: 280px; height: 500px; }
  .hero-visual { margin-top: 44px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
