:root {
  --bg: #f7f7f5;
  --surface: #ffffff;
  --text: #1b1d21;
  --muted: #5d6470;
  --line: #e3e4e8;
  --accent: #1f6feb;
  --accent-ink: #ffffff;
  --warn: #b54708;
  --ok: #157f3c;
  --radius: 10px;
  --shadow: 0 1px 2px rgba(16, 24, 40, .06), 0 1px 3px rgba(16, 24, 40, .08);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--text);
  background: var(--bg);
}

* { box-sizing: border-box; }
body { margin: 0; line-height: 1.55; background: var(--bg); }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: clamp(1.7rem, 3.5vw, 2.4rem); letter-spacing: -.02em; }
h2 { font-size: 1.4rem; margin-top: 2.2em; }
h3 { font-size: 1.05rem; }
p { margin: 0 0 1em; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 16px; }

/* header / footer */
.site-header { background: var(--surface); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--text); }
.brand:hover { text-decoration: none; }
.brand svg { width: 26px; height: 26px; }
.nav { display: flex; gap: 20px; align-items: center; font-size: .95rem; }
.nav a { color: var(--muted); }
.nav a.cta { color: var(--accent-ink); background: var(--accent); padding: 7px 14px; border-radius: 8px; }
.plan-badge { font-size: .75rem; font-weight: 600; padding: 2px 8px; border-radius: 99px; background: #e8f0fe; color: var(--accent); text-transform: uppercase; }
.site-footer { margin-top: 64px; padding: 28px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: .9rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 8px 22px; justify-content: space-between; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.site-footer a { color: var(--muted); }

/* hero */
.hero { padding: 36px 0 18px; }
.hero p { color: var(--muted); font-size: 1.08rem; max-width: 680px; }

/* tool */
.tool { display: grid; grid-template-columns: 340px 1fr; gap: 20px; align-items: start; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; }
.field { margin-bottom: 16px; }
.field > label, .field > .label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 6px; }
textarea, select, input[type=text] {
  width: 100%; font: inherit; font-size: .92rem; color: var(--text); background: var(--surface);
  border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px;
}
textarea { min-height: 150px; resize: vertical; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .85rem; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.check { display: flex; gap: 6px; align-items: center; font-size: .9rem; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips label { display: inline-flex; gap: 5px; align-items: center; font-size: .85rem; border: 1px solid var(--line); padding: 4px 9px; border-radius: 99px; cursor: pointer; }
.chips label.disabled { opacity: .45; cursor: not-allowed; }
.file-drop { display: block; border: 1.5px dashed var(--line); border-radius: 8px; padding: 12px; text-align: center; color: var(--muted); font-size: .9rem; cursor: pointer; }
.file-drop:hover { border-color: var(--accent); color: var(--accent); }
.file-drop input { display: none; }

button, .btn {
  font: inherit; font-weight: 600; font-size: .92rem; border: 1px solid var(--line); background: var(--surface); color: var(--text);
  padding: 9px 14px; border-radius: 8px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
}
button.primary, .btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
button:disabled { opacity: .5; cursor: not-allowed; }
.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.actions .wide { grid-column: 1 / -1; }
.lock { font-size: .75rem; font-weight: 600; color: var(--warn); }

.status { font-size: .88rem; color: var(--muted); margin-bottom: 12px; min-height: 1.3em; }
.status.warn { color: var(--warn); }
.status a { font-weight: 600; }
.preview { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.label-card { border: 1px solid var(--line); border-radius: 8px; padding: 10px; text-align: center; background: #fff; cursor: pointer; }
.label-card canvas { max-width: 100%; height: auto; max-height: 90px; }
.label-card .t { font-size: .78rem; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.label-card.err { border-color: #f4b4a0; color: var(--warn); font-size: .8rem; cursor: default; }
.empty { color: var(--muted); text-align: center; padding: 48px 12px; }

/* content */
.content { max-width: 760px; }
.steps { padding-left: 1.2em; }
.steps li { margin-bottom: .4em; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; margin-bottom: 8px; }
.faq summary { font-weight: 600; cursor: pointer; }
.faq details p { margin: .6em 0 0; color: var(--muted); }

/* pricing */
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 24px; }
.plan { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; display: flex; flex-direction: column; box-shadow: var(--shadow); }
.plan.featured { border: 2px solid var(--accent); }
.plan .price { font-size: 2rem; font-weight: 700; margin: 6px 0 2px; }
.plan .price small { font-size: .95rem; color: var(--muted); font-weight: 500; }
.plan ul { padding: 0; list-style: none; margin: 16px 0 22px; flex: 1; }
.plan li { padding: 5px 0 5px 22px; position: relative; font-size: .93rem; }
.plan li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 700; }
.manage { margin-top: 28px; }
.manage .row input { max-width: 380px; }

.legal { max-width: 760px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; margin-top: 28px; }
.legal h2 { font-size: 1.15rem; margin-top: 1.6em; }
.legal .meta { color: var(--muted); font-size: .9rem; }

@media (max-width: 860px) {
  .tool { grid-template-columns: 1fr; }
  .plans { grid-template-columns: 1fr; }
  .nav a:not(.cta) { display: none; }
}
