:root {
  --bg: #fbfbfe;
  --surface: #ffffff;
  --surface-2: #f3f2fd;
  --text: #17172b;
  --muted: #5d5d78;
  --line: #e4e3f1;
  --brand: #6247f2;
  --brand-2: #8b3df0;
  --brand-ink: #ffffff;
  --mint: #22c08e;
  --chat-bg: #eef0f7;
  --bubble-in: #ffffff;
  --bubble-out: #e6e2ff;
  --shadow: 0 20px 60px rgba(40, 30, 120, .14);
  --radius: 18px;
  --max: 1120px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f0f1a;
    --surface: #171726;
    --surface-2: #1f1d35;
    --text: #ecebfa;
    --muted: #a3a2c2;
    --line: #2c2b45;
    --brand: #8b7bff;
    --brand-2: #b07cff;
    --chat-bg: #12121f;
    --bubble-in: #1f1f33;
    --bubble-out: #2d2858;
    --shadow: 0 20px 60px rgba(0, 0, 0, .45);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0f0f1a; --surface: #171726; --surface-2: #1f1d35; --text: #ecebfa; --muted: #a3a2c2; --line: #2c2b45;
  --brand: #8b7bff; --brand-2: #b07cff; --chat-bg: #12121f; --bubble-in: #1f1f33; --bubble-out: #2d2858;
  --shadow: 0 20px 60px rgba(0, 0, 0, .45); color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.65 Inter, "Pretendard", -apple-system, BlinkMacSystemFont, "Segoe UI", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--brand); }
img, svg { display: block; max-width: 100%; }
.wrap { width: min(var(--max), 100% - 32px); margin-inline: auto; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--bg) 86%, transparent); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; gap: 24px; height: 64px; }
.brand { flex: none; display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 800; font-size: 20px; letter-spacing: -.02em; }
.brand img { width: 32px; height: 32px; }
.wordmark b { color: var(--brand); font-weight: inherit; }
.nav { display: flex; gap: 22px; margin-left: auto; }
.nav a { color: var(--muted); text-decoration: none; font-size: 15px; font-weight: 500; }
.nav a:hover { color: var(--text); }
.lang-switch { color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 600; padding: 6px 10px; border: 1px solid var(--line); border-radius: 9px; white-space: nowrap; }
.lang-switch:hover { color: var(--text); border-color: var(--muted); }
/* Korean reads better when words are not split across lines. */
html[lang="ko"] body { word-break: keep-all; }

.btn { white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 20px; border-radius: 12px; font-weight: 650; font-size: 15px; text-decoration: none; border: 1px solid transparent; cursor: pointer; transition: transform .15s, box-shadow .15s, background .15s; }
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: var(--brand-ink); box-shadow: 0 8px 24px color-mix(in srgb, var(--brand) 35%, transparent); }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--line); }
.btn-sm { padding: 8px 14px; font-size: 14px; }

/* Hero */
.hero { padding: 72px 0 56px; }
.hero .wrap { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; background: var(--surface-2); color: var(--brand); font-size: 13px; font-weight: 650; }
h1 { font-size: clamp(36px, 5.2vw, 58px); line-height: 1.08; letter-spacing: -.035em; margin: 18px 0 18px; }
h1 em { font-style: normal; background: linear-gradient(135deg, var(--brand), var(--brand-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { font-size: 19px; color: var(--muted); margin: 0 0 28px; max-width: 34em; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; }
.fineprint { margin-top: 18px; font-size: 13px; color: var(--muted); }

/* Chat mockup */
.mock { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow); overflow: hidden; }
.mock-top { display: flex; align-items: center; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.avatar { width: 38px; height: 38px; border-radius: 50%; background: linear-gradient(135deg, #ffb86b, #ff6b8b); flex: none; }
.mock-top b { display: block; font-size: 15px; }
.mock-top small { color: var(--muted); font-size: 12px; }
.mock-body { background: var(--chat-bg); padding: 20px 18px 24px; display: grid; gap: 14px; }
.msg { max-width: 74%; background: var(--bubble-in); border-radius: 16px; padding: 5px; box-shadow: 0 1px 2px rgba(0,0,0,.06); }
.msg.out { justify-self: end; background: var(--bubble-out); }
.msg p { margin: 6px 8px 4px; font-size: 14px; }
.msg .time { display: block; text-align: right; font-size: 11px; color: var(--muted); margin: 0 8px 2px; }
.album { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.media { position: relative; border-radius: 12px; overflow: hidden; aspect-ratio: 16 / 9; }
.media svg { width: 100%; height: 100%; }
.dur { position: absolute; left: 8px; top: 8px; background: rgba(0,0,0,.55); color: #fff; font-size: 11px; font-weight: 600; padding: 2px 7px; border-radius: 8px; }
.dl { position: absolute; right: 8px; top: 8px; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: rgba(15,23,35,.62); box-shadow: 0 2px 10px rgba(0,0,0,.35); font: 700 10px/1 system-ui, sans-serif; }
.dl svg { width: 17px; height: 17px; }
.dl.busy { background: #2784e6; }
.dl.done { background: #2e9e5b; }

/* Sections */
section { padding: 72px 0; scroll-margin-top: 64px; }
.section-head { text-align: center; max-width: 680px; margin: 0 auto 44px; }
h2 { font-size: clamp(28px, 3.6vw, 40px); letter-spacing: -.03em; line-height: 1.15; margin: 0 0 12px; }
.section-head p { color: var(--muted); font-size: 17px; margin: 0; }
.alt { background: var(--surface-2); }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.card h3 { margin: 14px 0 6px; font-size: 18px; letter-spacing: -.01em; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }
.icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-2); color: var(--brand); }
.icon svg { width: 22px; height: 22px; }

.steps { counter-reset: step; display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.step { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.step::before { counter-increment: step; content: counter(step); display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff; font-weight: 700; }
.step h3 { margin: 14px 0 6px; font-size: 18px; }
.step p { margin: 0; color: var(--muted); font-size: 15px; }

/* Pricing */
.billing-toggle { display: inline-flex; padding: 4px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); margin-top: 18px; }
.billing-toggle button { border: 0; background: transparent; color: var(--muted); font: inherit; font-size: 14px; font-weight: 600; padding: 8px 16px; border-radius: 9px; cursor: pointer; }
.billing-toggle button[aria-pressed="true"] { background: var(--surface-2); color: var(--text); }
.save { color: var(--mint); font-weight: 700; }
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 380px)); justify-content: center; gap: 20px; }
.plan { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 30px; display: flex; flex-direction: column; }
.plan.pro { border: 2px solid var(--brand); box-shadow: var(--shadow); position: relative; }
.badge { position: absolute; top: -13px; left: 30px; background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff; font-size: 12px; font-weight: 700; padding: 4px 12px; border-radius: 999px; }
.plan h3 { margin: 0; font-size: 20px; }
.price { font-size: 44px; font-weight: 800; letter-spacing: -.03em; margin: 12px 0 2px; }
.price small { font-size: 16px; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.plan .note { color: var(--muted); font-size: 14px; margin: 0 0 20px; min-height: 1.6em; }
.plan ul { list-style: none; padding: 0; margin: 0 0 26px; display: grid; gap: 10px; font-size: 15px; }
.plan li { display: flex; gap: 10px; align-items: flex-start; }
.plan li::before { content: ""; flex: none; width: 18px; height: 18px; margin-top: 3px; border-radius: 50%; background: var(--mint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12.5 4 4 8-8.5'/%3E%3C/svg%3E") center / 12px no-repeat; }
.plan li.off { color: var(--muted); }
.plan li.off::before { background: var(--line); }
.plan .btn { margin-top: auto; }
.mor { text-align: center; color: var(--muted); font-size: 14px; margin: 26px auto 0; max-width: 640px; }

/* FAQ */
.faq { max-width: 760px; margin: 0 auto; display: grid; gap: 12px; }
details { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 4px 20px; }
summary { cursor: pointer; font-weight: 650; padding: 14px 0; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; color: var(--brand); font-size: 22px; line-height: 1; }
details[open] summary::after { content: "–"; }
details p { margin: 0 0 16px; color: var(--muted); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 44px 0 36px; font-size: 14px; color: var(--muted); }
.footer-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 24px; margin-bottom: 26px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 20px; }
.footer-links a { color: var(--muted); text-decoration: none; }
.footer-links a:hover { color: var(--text); }
.disclaimer { font-size: 13px; margin: 0; }

/* Legal pages */
.legal { padding: 56px 0 72px; }
.legal .wrap { max-width: 760px; }
.legal h1 { font-size: clamp(32px, 4.4vw, 44px); margin-top: 0; }
.legal .updated { color: var(--muted); font-size: 14px; margin-bottom: 32px; }
.legal h2 { font-size: 22px; margin: 36px 0 10px; letter-spacing: -.01em; }
.legal p, .legal li { color: var(--muted); }
.legal strong { color: var(--text); }
.callout { background: var(--surface-2); border-radius: 14px; padding: 16px 20px; color: var(--text); }

@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 40px; }
  .grid-3, .steps { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .nav { display: none; }
  .lang-switch { margin-left: auto; padding: 5px 8px; font-size: 13px; }
  .site-header .wrap { gap: 10px; }
  .brand { font-size: 18px; gap: 8px; }
  .brand img { width: 28px; height: 28px; }
  .site-header .btn-sm { padding: 7px 11px; font-size: 13px; }
  .hero { padding-top: 44px; }
  .grid-3, .steps, .plans { grid-template-columns: 1fr; }
  section { padding: 56px 0; }
  .msg { max-width: 92%; }
}
