:root {
  --bg: #f6f7f9; --card: #fff; --ink: #16181d; --muted: #5d6470; --line: #e3e6eb;
  --accent: #0f766e; --accent-strong: #115e59; --accent-ink: #fff;
  --pos: #047857; --neg: #b91c1c; --ok-bg: #ecfdf5; --bad-bg: #fef2f2;
  --warn-bg: #fffbeb; --warn-line: #fcd34d;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1115; --card: #171a21; --ink: #e8eaee; --muted: #9aa2ae; --line: #2a2f39;
    --accent: #2dd4bf; --accent-strong: #5eead4; --accent-ink: #062b27;
    --pos: #34d399; --neg: #f87171; --ok-bg: #0c2a22; --bad-bg: #2d1416;
    --warn-bg: #241d0f; --warn-line: #78350f;
  }
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 system-ui, -apple-system, "Segoe UI", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif; }

.promo-bar { background: #111827; color: #f9fafb; text-align: center; padding: 8px 14px; font-size: 13px; display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 8px; border-bottom: 1px solid #374151; }
.promo-bar code { background: #1f2937; color: #34d399; padding: 2px 7px; border-radius: 4px; font-weight: 700; letter-spacing: 0.03em; }
.promo-bar a { color: #5eead4; font-weight: 700; text-decoration: none; }
.promo-bar a:hover { text-decoration: underline; }

.top { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); background: var(--card); position: sticky; top: 0; z-index: 10; }
.brand-wrap { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.brand { font-weight: 800; font-size: 17px; letter-spacing: -0.01em; }
.brand-badge { font-size: 11px; font-weight: 700; color: var(--accent); border: 1px solid var(--line); border-radius: 999px; padding: 2px 8px; }
.top-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.btn-top-cta { display: inline-flex; align-items: center; background: var(--accent); color: var(--accent-ink); text-decoration: none; font-weight: 700; font-size: 13px; padding: 7px 12px; border-radius: 8px; }
.btn-top-cta:hover { background: var(--accent-strong); }

.hero { max-width: 1080px; margin: 16px auto 0; padding: 0 16px; display: grid; gap: 14px; }
.hero-copy { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 20px; }
.eyebrow { margin: 0 0 6px; font-size: 11px; font-weight: 700; letter-spacing: 0.08em; color: var(--accent); text-transform: uppercase; }
.hero h1 { margin: 0 0 8px; font-size: clamp(22px, 3vw, 30px); line-height: 1.2; letter-spacing: -0.02em; }
.hero-sub { margin: 0; color: var(--muted); max-width: 78ch; font-size: 15px; }

.scenario-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.scenario-label { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; }
.scenario-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.scenario-pill { background: var(--card); color: var(--ink); border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 600; cursor: pointer; }
.scenario-pill:hover, .scenario-pill.active { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }

.roi-banner { background: var(--card); border: 1px solid var(--accent); border-radius: 14px; padding: 16px 18px; display: grid; gap: 12px; }
.roi-metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 680px) { .roi-metrics { grid-template-columns: minmax(0, 1fr); } }
.roi-stat { background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; gap: 2px; }
.roi-stat span { font-size: 12px; color: var(--muted); }
.roi-stat strong { font-size: 20px; font-variant-numeric: tabular-nums; }
.roi-note { margin: 0; font-size: 13.5px; color: var(--ink); }

.cta-group { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.btn-cta-primary, .btn-cta-secondary { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; border-radius: 9px; padding: 10px 16px; font-weight: 700; font-size: 14px; }
.btn-cta-primary { background: var(--accent); color: var(--accent-ink); }
.btn-cta-primary:hover { background: var(--accent-strong); }
.btn-cta-secondary { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.btn-cta-secondary:hover { border-color: var(--accent); color: var(--accent); }

main { max-width: 1080px; margin: 0 auto; padding: 16px; display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
main > section:nth-child(n+3) { grid-column: 1 / -1; }
@media (max-width: 820px) { main { grid-template-columns: minmax(0, 1fr); } }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 16px; min-width: 0; }
h2 { margin: 0 0 12px; font-size: 17px; }
h3 { margin: 0 0 8px; font-size: 15px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
label.full { margin-bottom: 12px; }
label small { font-size: 12px; }
input, select, textarea, button { font: inherit; color: var(--ink); }
input, select, textarea { background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; width: 100%; min-width: 0; }
textarea { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 13px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
button { background: var(--accent); color: var(--accent-ink); border: 0; border-radius: 8px; padding: 8px 14px; cursor: pointer; font-weight: 600; white-space: nowrap; }
button.secondary, .top button { background: transparent; color: var(--ink); border: 1px solid var(--line); }
button.btn-xs { padding: 4px 9px; font-size: 13px; }
.top select { width: auto; }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; margin: 10px 0; }
.row .grow { flex: 1 1 240px; }
.row input[type=file] { width: auto; flex: 1 1 200px; }

.kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-bottom: 12px; }
.kpi { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; }
.kpi span { font-size: 12px; color: var(--muted); }
.kpi b { font-size: 22px; font-variant-numeric: tabular-nums; }
.pos { color: var(--pos); } .neg { color: var(--neg); }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.breakdown td { padding: 6px 0; border-bottom: 1px solid var(--line); }
.breakdown td:last-child { text-align: right; }
.breakdown tr.strong td { font-weight: 700; }
.hint { color: var(--muted); font-size: 13px; margin: 10px 0 0; }
.scroll { overflow-x: auto; }
.data th, .data td { padding: 7px 10px; text-align: right; border-bottom: 1px solid var(--line); white-space: nowrap; }
.data th:first-child, .data td:first-child { text-align: left; }
.data th { font-size: 12px; color: var(--muted); font-weight: 600; }
.data tr.ok td { background: var(--ok-bg); } .data tr.bad td { background: var(--bad-bg); }

.export-drawer { margin-top: 14px; padding: 14px 16px; border-radius: 10px; border: 1px solid var(--accent); background: var(--ok-bg); display: grid; gap: 10px; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.drawer-copy { margin: 0; font-size: 13.5px; color: var(--ink); }

.peek-header { display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; gap: 12px; margin-bottom: 14px; }
.peek-header h2 { margin-bottom: 4px; }
.peek-header .hint { margin-top: 0; }
.peek-tabs { display: flex; flex-wrap: wrap; gap: 6px; }
.peek-tab { background: var(--bg); color: var(--ink); border: 1px solid var(--line); border-radius: 8px; padding: 7px 12px; font-size: 13px; }
.peek-tab.active { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.peek-grid, .tier-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; align-items: start; }
@media (max-width: 760px) { .peek-grid, .tier-grid { grid-template-columns: minmax(0, 1fr); } }
.check-list { margin: 0; padding-left: 18px; display: grid; gap: 6px; font-size: 14px; }
.code-box { margin: 0; padding: 12px; background: var(--bg); border: 1px solid var(--line); border-radius: 10px; overflow-x: auto; font-size: 12.5px; line-height: 1.5; }
.tier-card { border: 1px solid var(--line); border-radius: 10px; padding: 14px; background: var(--bg); }
.tier-card.tier-featured { border-color: var(--accent); }
.tier-badge { display: inline-block; font-size: 11px; font-weight: 800; color: var(--accent); margin-bottom: 6px; letter-spacing: 0.05em; }
.peek-footer { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 10px; }

.faq-list { display: grid; gap: 8px; }
.faq-list details { border: 1px solid var(--line); border-radius: 10px; padding: 10px 14px; background: var(--bg); }
.faq-list summary { cursor: pointer; font-weight: 700; font-size: 14px; }
.faq-list p { margin: 8px 0 0; font-size: 14px; color: var(--muted); }

.foot { max-width: 1080px; margin: 0 auto; padding: 8px 16px 36px; display: grid; gap: 12px; color: var(--muted); font-size: 13px; }
.foot-row { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; align-items: center; }
.foot a { color: var(--accent); font-weight: 600; text-decoration: none; }
.foot a:hover { text-decoration: underline; }
.foot-links { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; padding-top: 10px; border-top: 1px solid var(--line); }
