:root {
  --bg: #f6f7f9;
  --panel: #ffffff;
  --ink: #161b26;
  --ink-2: #444d5e;
  --muted: #7a8394;
  --line: #e6e8ee;
  --line-2: #d5d9e1;
  --hover: #f2f4f7;
  --brand: #0c1e3a;
  --accent: #2f6fed;
  --accent-ink: #1f57c9;
  --accent-soft: #edf3ff;
  --ok: #12804c;
  --ok-soft: #e7f6ee;
  --warn: #8f5d00;
  --warn-soft: #fff6df;
  --err: #c0362c;
  --err-soft: #fdeeec;
  --radius: 8px;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
  font-size: 14px;
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 21px; margin: 0 0 4px; letter-spacing: -.015em; font-weight: 650; }
h2 { font-size: 16px; margin: 0 0 6px; font-weight: 650; }
h3 { font-size: 14px; margin: 0 0 12px; font-weight: 650; }
h4 { font-size: 12.5px; margin: 16px 0 8px; font-weight: 600; color: var(--ink-2); }
p { margin: 0 0 8px; }
code, .mono, pre { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12.5px; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.pad { padding: 20px; }
.right { text-align: right; }
.nowrap { white-space: nowrap; }
.grow { flex: 1; }
.spacer { flex: 1; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.boot { padding: 40px; color: var(--muted); }
[hidden] { display: none !important; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; font: inherit; font-weight: 500; padding: 7px 13px; border-radius: 6px; border: 1px solid var(--line-2);
  background: #fff; color: var(--ink); cursor: pointer; white-space: nowrap; text-decoration: none !important; line-height: 1.3; transition: background .12s, border-color .12s; }
.btn:hover { background: var(--hover); }
.btn:focus-visible, .icon-btn:focus-visible, .seg button:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.btn:disabled, .btn.disabled { opacity: .5; cursor: not-allowed; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-ink); border-color: var(--accent-ink); }
.btn-ghost { background: transparent; border-color: transparent; color: var(--ink-2); }
.btn-ghost:hover { background: var(--hover); }
.btn-danger { background: var(--err); border-color: var(--err); color: #fff; }
.btn-danger-ghost { background: transparent; border-color: transparent; color: var(--err); }
.btn-danger-ghost:hover { background: var(--err-soft); }
.btn-sm { padding: 5px 10px; font-size: 13px; }
.btn-block { width: 100%; padding: 10px; }
.icon-btn { border: 0; background: transparent; cursor: pointer; font-size: 14px; padding: 3px 7px; border-radius: 5px; color: var(--ink-2); line-height: 1.2; }
.icon-btn:hover { background: var(--hover); color: var(--ink); }
.icon-btn.danger:hover { background: var(--err-soft); color: var(--err); }
.icon-btn:disabled { opacity: .3; cursor: default; }

/* inputs */
.inp { width: 100%; font: inherit; padding: 8px 10px; border: 1px solid var(--line-2); border-radius: 6px; background: #fff; color: var(--ink); transition: border-color .12s; }
.inp:hover { border-color: #c2c8d2; }
.inp:focus { outline: none; border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.inp:disabled { background: #f3f5f8; color: var(--muted); }
.inp-sm { padding: 6px 8px; font-size: 13px; }
.inp.inline { width: auto; display: inline-block; }
textarea.inp { resize: vertical; line-height: 1.45; }
select.inp { appearance: none; -webkit-appearance: none; padding-right: 28px;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%237a8394' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 10px center; }
.fld { display: flex; flex-direction: column; gap: 6px; margin: 0 0 14px; }
.fld-label { font-weight: 600; font-size: 12.5px; color: var(--ink-2); }
.fld-hint { display: block; font-size: 12px; color: var(--muted); font-weight: 400; line-height: 1.4; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.three { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.checks { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.check { display: inline-flex; gap: 7px; align-items: center; font-weight: 400; cursor: pointer; }
.check input { accent-color: var(--accent); }
.color-row { display: flex; gap: 6px; align-items: center; }
.color-row .inp { width: 92px; }
.swatch { width: 30px; height: 30px; padding: 0; border: 1px solid var(--line-2); border-radius: 6px; background: none; cursor: pointer; flex: none; }
.swatch::-webkit-color-swatch-wrapper { padding: 3px; }
.swatch::-webkit-color-swatch { border: 0; border-radius: 3px; }
.range-row { display: flex; align-items: center; gap: 10px; }
.range-row input { flex: 1; accent-color: var(--accent); }
.range-val { width: 38px; text-align: right; color: var(--ink-2); }

.toggle { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; margin: 0 0 12px; font-weight: 500; }
.toggle input { position: absolute; opacity: 0; width: 0; height: 0; }
.toggle .switch { flex: none; width: 30px; height: 18px; border-radius: 9px; background: #cfd5df; position: relative; transition: background .15s; margin-top: 1px; }
.toggle .switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: #fff; transition: transform .15s; }
.toggle input:checked + .switch { background: var(--accent); }
.toggle input:checked + .switch::after { transform: translateX(12px); }
.toggle input:focus-visible + .switch { outline: 2px solid var(--accent); outline-offset: 2px; }
.toggles { margin: 4px 0 8px; }

/* segmented control */
.seg { display: inline-flex; border: 1px solid var(--line-2); border-radius: 6px; overflow: hidden; background: #fff; }
.seg button { border: 0; border-left: 1px solid var(--line-2); background: transparent; padding: 6px 12px; font: inherit; cursor: pointer; color: var(--ink-2); white-space: nowrap; }
.seg button:first-child { border-left: 0; }
.seg button:hover { background: var(--hover); }
.seg button.on { background: var(--accent-soft); color: var(--accent-ink); font-weight: 600; }
.seg-fill { display: flex; width: 100%; }
.seg-fill button { flex: 1; padding: 6px 6px; }
.seg-sm button { font-size: 12.5px; padding: 4px 8px; }

/* badges */
.badge { display: inline-block; font-size: 11.5px; font-weight: 600; padding: 2px 8px; border-radius: 10px; background: #eef1f5; color: var(--ink-2); text-transform: capitalize; white-space: nowrap; }
.badge-published { background: var(--ok-soft); color: var(--ok); }
.badge-draft { background: #eef1f5; color: var(--ink-2); }
.badge-changes { background: var(--warn-soft); color: var(--warn); text-transform: none; }
.badge-archived { background: #f1f1f1; color: #888; }
.badge-error { background: var(--err-soft); color: var(--err); }
.chip { font-size: 11px; padding: 1px 7px; border-radius: 9px; background: #eef1f5; color: var(--ink-2); }
.chip-req { background: var(--err-soft); color: var(--err); }
.chip-logic { background: var(--accent-soft); color: var(--accent-ink); }

/* top bar */
.topbar { display: flex; align-items: center; gap: 6px; height: 52px; padding: 0 16px; background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.brand { display: flex; align-items: center; gap: 8px; color: var(--ink); font-weight: 700; font-size: 15px; text-decoration: none !important; letter-spacing: -.01em; }
.brand img { width: 22px; height: 22px; }
.ws-switch { width: auto; max-width: 220px; font: inherit; border: 1px solid var(--line-2); border-radius: 6px; padding: 5px 28px 5px 9px; color: var(--ink); appearance: none; -webkit-appearance: none;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%237a8394' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 9px center; }
.topnav { display: flex; gap: 2px; margin-left: 14px; height: 100%; }
.topnav a { display: flex; align-items: center; color: var(--muted); padding: 0 10px; text-decoration: none; font-weight: 500; position: relative; }
.topnav a:hover { color: var(--ink); }
.topnav a.on { color: var(--ink); }
.topnav a.on::after { content: ""; position: absolute; left: 10px; right: 10px; bottom: -1px; height: 2px; background: var(--ink); border-radius: 2px 2px 0 0; }
.who { color: var(--muted); font-size: 13px; }

/* pages */
.page { max-width: 1120px; margin: 0 auto; padding: 32px 24px 64px; }
.page.narrow { max-width: 760px; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin: 0 0 20px; flex-wrap: wrap; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; margin: 0 0 16px; }
.empty { text-align: center; padding: 56px 20px; background: var(--panel); border: 1px dashed var(--line-2); border-radius: var(--radius); }
.empty.small { padding: 28px 20px; }
.empty h2 { margin-bottom: 8px; }
.empty p { color: var(--muted); }
.search { width: 220px; }

/* form list */
.form-list { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.form-row { display: grid; grid-template-columns: minmax(200px, 2.4fr) 1fr 0.8fr 1.1fr 340px; gap: 12px; align-items: center; padding: 13px 18px; border-top: 1px solid var(--line); }
.form-row:first-child { border-top: 0; }
.form-row:not(.form-row-head):hover { background: #fafbfc; }
.form-row-head { background: #fafbfc; font-size: 11.5px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; padding: 9px 18px; }
.form-name { font-weight: 600; font-size: 14.5px; color: var(--ink); }
.num { font-weight: 600; font-variant-numeric: tabular-nums; }
.row-actions { display: flex; gap: 4px; justify-content: flex-end; }

/* templates */
.tpl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 8px; }
.tpl { text-align: left; display: flex; flex-direction: column; gap: 4px; padding: 12px 13px; border: 1px solid var(--line-2); border-radius: 8px; background: #fff; font: inherit; cursor: pointer; color: var(--ink-2); line-height: 1.4; }
.tpl b { color: var(--ink); font-weight: 600; }
.tpl:hover { border-color: #b9c1cd; }
.tpl.on { border-color: var(--accent); background: var(--accent-soft); box-shadow: inset 0 0 0 1px var(--accent); }
.tpl-count { font-size: 11.5px; color: var(--muted); margin-top: 2px; }

/* tables */
.tbl-wrap { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: auto; }
.tbl { width: 100%; border-collapse: collapse; }
.tbl th, .tbl td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl th { font-size: 11.5px; font-weight: 600; color: var(--muted); background: #fafbfc; white-space: nowrap; position: sticky; top: 0; text-transform: uppercase; letter-spacing: .03em; }
.tbl th.sortable { cursor: pointer; user-select: none; }
.tbl th.sortable:hover { color: var(--ink); }
.tbl tr.clickable { cursor: pointer; }
.tbl tr.clickable:hover td { background: #f8faff; }
.tbl-resp td { max-width: 320px; }
.pager { display: flex; gap: 8px; justify-content: flex-end; align-items: center; padding: 12px 0; }

/* auth */
.auth-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; background: var(--bg); }
.auth-card { width: 100%; max-width: 380px; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 32px 28px; }
.auth-brand { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 16px; margin-bottom: 22px; }
.auth-brand img { width: 26px; height: 26px; }
.auth-card h1 { margin-bottom: 18px; }
.auth-switch { margin-top: 16px; text-align: center; font-size: 13px; }
.form-error { background: var(--err-soft); color: var(--err); padding: 9px 12px; border-radius: 6px; margin: 0 0 14px; }
.grid-form { display: grid; grid-template-columns: 1.4fr 1fr 1.3fr .8fr auto; gap: 8px; }

/* modal + toast */
.modal-overlay { position: fixed; inset: 0; background: rgba(15, 23, 42, .4); display: flex; align-items: flex-start; justify-content: center; padding: 8vh 16px 16px; z-index: 50; overflow: auto; }
.modal { background: #fff; border-radius: 10px; width: 100%; max-width: 480px; border: 1px solid var(--line); }
.modal-wide { max-width: 760px; }
.modal-head { display: flex; justify-content: space-between; align-items: center; padding: 15px 20px; border-bottom: 1px solid var(--line); }
.modal-head h2 { margin: 0; }
.modal-body { padding: 18px 20px; max-height: 70vh; overflow: auto; }
.modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 20px; border-top: 1px solid var(--line); }
.toasts { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; z-index: 60; }
.toast { background: #161b26; color: #fff; padding: 9px 15px; border-radius: 7px; transition: opacity .3s, transform .3s; font-size: 13.5px; }
.toast-err { background: var(--err); }
.toast.out { opacity: 0; transform: translateY(6px); }
.problems { margin: 0; padding-left: 18px; }
.problems li { margin: 4px 0; }
.adv { margin: 8px 0 12px; }
.adv summary { cursor: pointer; color: var(--ink-2); font-weight: 500; margin-bottom: 10px; }
.code { background: #0f1729; color: #d6e2ff; padding: 14px; border-radius: 8px; overflow: auto; white-space: pre-wrap; word-break: break-all; max-height: 420px; margin: 0 0 10px; }
.resp-dl { display: grid; grid-template-columns: 220px 1fr; gap: 8px 16px; margin: 12px 0 20px; }
.resp-dl dt { font-weight: 600; color: var(--ink-2); }
.resp-dl dd { margin: 0; white-space: pre-wrap; }
.note { background: var(--accent-soft); border-radius: 6px; padding: 10px 12px; margin: 0 0 12px; font-size: 13px; line-height: 1.6; }
.warn-box { background: var(--warn-soft); color: #5c4200; border-radius: 6px; padding: 10px 12px; margin-top: 12px; font-size: 13px; }
.warn-box ul { margin: 6px 0 0; padding-left: 18px; }
.warn-inline { background: var(--warn-soft); color: #5c4200; border-radius: 6px; padding: 8px 10px; margin: -6px 0 12px; font-size: 12.5px; }
.ok-box { background: var(--ok-soft); color: #0d5c37; border-radius: 6px; padding: 8px 10px; margin-top: 8px; }
.err-box { background: var(--err-soft); color: var(--err); border-radius: 6px; padding: 8px 10px; margin: 8px 0; }
.ok-box pre, .err-box pre { margin: 6px 0 0; white-space: pre-wrap; font-size: 12px; max-height: 120px; overflow: auto; }

/* ---------------- editor ---------------- */
.ed { display: flex; flex-direction: column; height: 100vh; }
.ed-top { display: flex; align-items: center; gap: 8px; padding: 9px 14px; background: #fff; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.ed-back { color: var(--ink-2); font-weight: 500; padding: 6px 8px; border-radius: 6px; }
.ed-back:hover { background: var(--hover); text-decoration: none; }
.ed-name { font: inherit; font-size: 15px; font-weight: 600; border: 1px solid transparent; border-radius: 6px; padding: 5px 8px; min-width: 160px; max-width: 360px; width: auto; background: transparent; color: var(--ink); }
.ed-name:hover { border-color: var(--line-2); }
.ed-name:focus { outline: none; border-color: var(--accent); background: #fff; }
.ed-savestate { font-size: 12.5px; }
.ed-body { flex: 1; display: flex; min-height: 0; }
.ed-side { width: 212px; flex: none; background: #fff; border-right: 1px solid var(--line); overflow-y: auto; display: flex; flex-direction: column; }
.side-title { font-weight: 650; padding: 14px 14px 4px; font-size: 13px; }
.pal-group { padding: 2px 8px 4px; }
.pal-head { font-size: 10.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 8px 6px 4px; font-weight: 600; }
.pal-item { display: flex; align-items: center; gap: 9px; width: 100%; border: 0; background: transparent; padding: 6px 8px; border-radius: 6px; font: inherit; cursor: pointer; color: var(--ink); text-align: left; }
.pal-item:hover { background: var(--accent-soft); color: var(--accent-ink); }
.ico { width: 20px; height: 20px; border-radius: 5px; border: 1px solid var(--line-2); flex: none; position: relative; background: #fff; }
.ico::after { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 700; color: var(--ink-2); }
.ico-text::after { content: "Aa"; } .ico-textarea::after { content: "¶"; } .ico-email::after { content: "@"; } .ico-phone::after { content: "☎"; }
.ico-number::after { content: "#"; } .ico-date::after { content: "▦"; } .ico-time::after { content: "◷"; } .ico-choice::after { content: "◉"; }
.ico-select::after { content: "▾"; } .ico-checkbox::after { content: "☑"; } .ico-rating::after { content: "★"; } .ico-nps::after { content: "10"; }
.ico-file::after { content: "⇪"; } .ico-html::after { content: "T"; } .ico-hidden::after { content: "◌"; } .ico-submit::after { content: "↵"; }
.ed-nav { display: flex; flex-direction: column; padding: 10px 8px 16px; border-top: 1px solid var(--line); margin-top: auto; gap: 1px; }
.ed-side > .ed-nav:first-child { margin-top: 0; border-top: 0; }
.ed-nav button { display: flex; justify-content: space-between; align-items: center; border: 0; background: transparent; padding: 7px 10px; border-radius: 6px; font: inherit; text-align: left; cursor: pointer; color: var(--ink-2); }
.ed-nav button:hover { background: var(--hover); color: var(--ink); }
.ed-nav button.on { background: var(--accent-soft); color: var(--accent-ink); font-weight: 600; }
.ed-nav .count { font-size: 11px; background: #eef1f5; color: var(--ink-2); padding: 1px 7px; border-radius: 9px; font-weight: 600; }
.ed-main { flex: 1; min-width: 0; overflow: auto; }

.build { display: flex; height: 100%; }
.canvas-scroll { flex: 1; overflow-y: auto; padding: 28px 24px 80px; }
.canvas { max-width: 660px; margin: 0 auto; }
.cv-form { background: var(--cv-surface, #fff); color: var(--cv-text, var(--ink)); border: 1px solid var(--line); border-radius: 10px; padding: 26px; }
.cv-logo { display: block; max-width: 180px; max-height: 52px; margin: 0 auto 14px; }
.cv-logo-left { margin-left: 0; }
.cv-title { font-size: 20px; font-weight: 700; letter-spacing: -.01em; margin: 0 0 4px; }
.cv-desc { color: color-mix(in srgb, var(--cv-text, #161b26) 60%, transparent); margin: 0 0 6px; white-space: pre-line; }
.cv-title-center { text-align: center; }
.cv-title + .cv-page, .cv-desc + .cv-page { margin-top: 16px; }
.cv-page { margin-bottom: 14px; }
.cv-page + .cv-page { border-top: 1.5px dashed var(--line-2); padding-top: 14px; }
.cv-page-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.cv-page-name { font: inherit; font-weight: 600; border: 1px solid transparent; background: transparent; border-radius: 5px; padding: 3px 6px; color: var(--muted); }
.cv-page-name:hover { border-color: var(--line-2); }
.cv-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 6px; }
.cv-grid > * { grid-column: span 2; }
.cv-grid > .cv-field.half { grid-column: span 1; }
.cv-empty { border: 1px dashed var(--line-2); border-radius: 8px; padding: 22px; text-align: center; color: var(--muted); }
.cv-field { position: relative; border: 1px solid transparent; border-radius: 8px; padding: 10px 12px 12px; margin: 2px 0; cursor: pointer; transition: border-color .1s, background .1s; min-width: 0; }
.cv-field:hover { border-color: var(--line-2); }
.cv-field.sel { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.cv-field.over { box-shadow: inset 0 3px 0 var(--accent); }
.cv-field.dim { opacity: .65; }
.cv-field.dim .cv-label { font-style: italic; }
.cv-field-head { display: flex; align-items: baseline; gap: 8px; margin-bottom: 7px; }
.drag { color: #b5bdca; cursor: grab; font-size: 12px; letter-spacing: -2px; }
.cv-label { font-weight: 600; font-size: 14px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.cv-label .req { color: var(--err); margin-left: 2px; }
.cv-meta { color: var(--muted); font-size: 11px; }
.cv-type { font-size: 11px; color: var(--muted); background: #f1f3f6; padding: 1px 7px; border-radius: 9px; white-space: nowrap; }
.cv-badges { display: flex; gap: 5px; margin-top: 8px; flex-wrap: wrap; }
.cv-tools { position: absolute; top: -14px; right: 8px; background: #fff; border: 1px solid var(--line-2); border-radius: 7px; display: flex; z-index: 2; }
.cv-drop-end { height: 14px; border-radius: 6px; }
.cv-drop-end.over { background: var(--accent-soft); height: 36px; }
.cv-add-page { margin-top: 8px; }
.pv { border: 1px solid color-mix(in srgb, var(--cv-text, #161b26) 20%, transparent); border-radius: var(--cv-radius, 6px); padding: 8px 10px; min-height: 36px; color: var(--muted); background: var(--cv-surface, #fff); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pv-has { color: var(--cv-text, var(--ink)); }
.cv-fields-filled .pv { background: color-mix(in srgb, var(--cv-text, #161b26) 5%, var(--cv-surface, #fff)); border-color: transparent; }
.cv-fields-underline .pv { border-width: 0 0 1.5px; border-radius: 0; padding-left: 0; background: transparent; }
.pv-area { min-height: 64px; white-space: normal; }
.pv-select::after { content: " ▾"; float: right; }
.pv-file { border-style: dashed; text-align: center; white-space: normal; }
.pv-file b { color: var(--cv-accent, var(--accent)); }
.pv-hidden { background: #f6f7f9; border-style: dashed; }
.pv-opts { display: flex; flex-direction: column; gap: 5px; }
.pv-opts.pv-grid { display: grid; grid-template-columns: 1fr 1fr; }
.pv-opts.pv-inline { flex-direction: row; flex-wrap: wrap; }
.pv-opt { display: flex; align-items: center; gap: 8px; padding: 6px 10px; border: 1px solid color-mix(in srgb, var(--cv-text, #161b26) 18%, transparent); border-radius: var(--cv-radius, 6px); font-size: 13px; min-width: 0; }
.cv-fields-underline .pv-opt { border: 0; padding: 3px 0; }
.pv-opt img { width: 20px; height: 20px; object-fit: contain; }
.pv-radio, .pv-box { width: 13px; height: 13px; border: 1.5px solid #aab3c2; border-radius: 50%; flex: none; }
.pv-box { border-radius: 3px; }
.pv-scale { display: flex; gap: 4px; flex-wrap: wrap; }
.pv-scale span { border: 1px solid color-mix(in srgb, var(--cv-text, #161b26) 18%, transparent); border-radius: min(var(--cv-radius, 6px), 6px); padding: 4px 0; font-size: 12px; color: var(--ink-2); min-width: 26px; text-align: center; }
.pv-nps span { flex: 1; min-width: 0; }
.pv-scale-labels { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted); margin-top: 4px; }
.pv-stars { font-size: 22px; letter-spacing: 2px; color: #cfd5df; line-height: 1; }
.pv-submit { display: inline-block; background: var(--cv-btn, #0c1e3a); color: var(--cv-btn-color, #fff); padding: 9px 22px; border-radius: var(--cv-radius, 6px); font-weight: 600; }
.pv-html { font-size: 13.5px; color: var(--ink-2); }
.pv-html p { margin: 0; }

.inspector { width: 320px; flex: none; background: #fff; border-left: 1px solid var(--line); overflow-y: auto; padding: 18px 18px 40px; }
.insp-empty p { margin-top: 4px; }

.opt-list { display: flex; flex-direction: column; gap: 5px; margin-bottom: 6px; }
.opt-row { display: grid; gap: 5px; align-items: center; }
.opt-row .icon-btn { font-size: 11.5px; padding: 3px 4px; }

.panel { max-width: 980px; margin: 0 auto; padding: 24px 24px 80px; }
.panel-wide { max-width: none; }
.panel-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.panel-head p { max-width: 640px; }
.rules { display: flex; flex-direction: column; gap: 4px; }
.rule.off { opacity: .6; }
.rule-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.rule-head .toggle { margin: 0; }
.wf-name { max-width: 260px; font-weight: 600; }
.rule-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.rule-col { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.rule-col > .cond-row { width: 100%; }
.rule-col.wide { min-width: 0; }
.rule-cols:has(.wide) { grid-template-columns: minmax(260px, .9fr) 1.4fr; }
.rule-label { font-weight: 600; color: var(--ink-2); font-size: 13px; }
.cond-row { display: grid; grid-template-columns: 1.3fr 1fr 1fr 28px; gap: 6px; align-items: center; }
.wa { width: 100%; border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px 4px; background: #fbfcfd; }
.wa-head { display: flex; align-items: center; margin-bottom: 10px; }
.wa-result { width: 100%; margin-bottom: 10px; }
.wa .row { margin-bottom: 8px; }

.copy-block { margin-bottom: 12px; }
.copy-row { display: flex; gap: 6px; margin-bottom: 8px; }
.prefill-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0 12px; }
.json-ed { min-height: 70vh; font-size: 12.5px; line-height: 1.5; tab-size: 2; }

/* ---------------- design tab ---------------- */
.design { display: grid; grid-template-columns: 370px 1fr; height: 100%; min-height: 0; }
.dz-controls { background: #fff; border-right: 1px solid var(--line); overflow-y: auto; }
.dz-section { padding: 18px 18px 8px; border-bottom: 1px solid var(--line); }
.dz-section:last-child { border-bottom: 0; padding-bottom: 28px; }
.dz-section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.dz-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 12px; }
.dz-row-stack { flex-direction: column; align-items: stretch; gap: 6px; }
.dz-label { font-size: 13px; color: var(--ink-2); font-weight: 500; }
.dz-preview { display: flex; flex-direction: column; min-width: 0; background: #eceef2; }
.dz-bar { display: flex; align-items: center; gap: 10px; padding: 9px 14px; background: #fff; border-bottom: 1px solid var(--line); }
.dz-bar .seg { width: auto; }
.dz-stage { flex: 1; min-height: 0; overflow: auto; padding: 18px; display: flex; justify-content: center; }
.dz-device { width: 100%; height: 100%; min-height: 560px; background: #fff; border: 1px solid var(--line-2); border-radius: 8px; overflow: hidden; transition: width .2s; }
.dz-mobile { width: 390px; max-width: 100%; border-radius: 22px; border-width: 6px; border-color: #1c2230; }
.dz-frame { width: 100%; height: 100%; border: 0; display: block; background: #fff; }
.theme-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 0 0 12px; }
.theme-card { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.theme-swatch { display: block; width: 100%; aspect-ratio: 4 / 3; border: 1px solid var(--line-2); border-radius: 7px; padding: 10px; cursor: pointer; transition: border-color .12s; }
.theme-swatch:hover { border-color: #aeb7c4; }
.theme-card.on .theme-swatch { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.ts-card { height: 100%; padding: 7px; display: flex; flex-direction: column; gap: 5px; align-items: flex-start; }
.ts-title { font-size: 15px; font-weight: 700; line-height: 1; }
.ts-line { height: 6px; width: 85%; }
.ts-btn { height: 9px; width: 42%; margin-top: auto; }
.theme-meta { display: flex; align-items: center; justify-content: space-between; gap: 2px; min-width: 0; }
.theme-name { font-size: 12px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.theme-tools { display: flex; flex: none; }
.theme-tools .icon-btn { font-size: 12px; padding: 1px 4px; }

@media (max-width: 1100px) {
  .inspector { width: 280px; }
  .ed-side { width: 190px; }
  .design { grid-template-columns: 320px 1fr; }
}
@media (max-width: 860px) {
  .topbar { flex-wrap: wrap; height: auto; padding: 10px 16px; gap: 10px; }
  .page { padding: 20px 16px 48px; }
  .search { width: 100%; }
  .form-row { grid-template-columns: 1fr auto; }
  .form-row > :nth-child(3), .form-row > :nth-child(4), .form-row-head { display: none; }
  .row-actions { grid-column: 1 / -1; justify-content: flex-start; flex-wrap: wrap; }
  .grid-form, .rule-cols, .rule-cols:has(.wide), .three { grid-template-columns: 1fr; }
  .ed { height: auto; min-height: 100vh; }
  .ed-body { flex-direction: column; }
  .ed-side { width: auto; border-right: 0; border-bottom: 1px solid var(--line); }
  .palette { display: flex; flex-wrap: wrap; }
  .pal-group { display: flex; flex-wrap: wrap; align-items: center; }
  .ed-nav { flex-direction: row; overflow-x: auto; margin-top: 0; }
  .build { flex-direction: column; height: auto; }
  .inspector { width: auto; border-left: 0; border-top: 1px solid var(--line); }
  .canvas-scroll { padding: 16px; }
  .resp-dl { grid-template-columns: 1fr; }
  .cond-row { grid-template-columns: 1fr 1fr; }
  .design { grid-template-columns: 1fr; height: auto; }
  .dz-controls { border-right: 0; border-bottom: 1px solid var(--line); }
  .dz-device { min-height: 640px; }
}


/* ================= v2 components ================= */
.ic { display: inline-flex; align-items: center; justify-content: center; flex: none; line-height: 0; }
.ic svg { display: block; }
.btn .ic { margin: 0 -1px; }
.linkish { border: 0; background: none; padding: 0; font: inherit; color: var(--accent-ink); cursor: pointer; text-align: left; }
.linkish:hover { text-decoration: underline; }

/* header */
.brand span { font-weight: 700; }
.topbar-slash { color: #c9ced8; font-size: 20px; font-weight: 300; margin: 0 2px 0 6px; }
.avatar { display: inline-grid; place-content: center; width: 26px; height: 26px; border-radius: 50%; color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .02em; flex: none; }
.avatar-sq { border-radius: 6px; width: 22px; height: 22px; font-size: 10.5px; }
.ws-btn { display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 8px 0 6px; border: 1px solid transparent; border-radius: 7px; background: transparent; font: inherit; font-weight: 600; color: var(--ink); cursor: pointer; max-width: 260px; }
.ws-btn:hover, .ws-btn[aria-expanded=true] { background: var(--hover); border-color: var(--line); }
.ws-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ws-chev { color: var(--muted); }
.user-btn { border: 0; background: none; padding: 3px; border-radius: 50%; cursor: pointer; }
.user-btn:hover .avatar, .user-btn[aria-expanded=true] .avatar { outline: 2px solid var(--line-2); outline-offset: 1px; }
.user-btn:focus-visible, .ws-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* popover menus */
.pop { position: absolute; z-index: 70; min-width: 200px; background: #fff; border: 1px solid var(--line-2); border-radius: 10px; padding: 6px; }
.pop-label { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 6px 8px 4px; }
.pop-sep { height: 1px; background: var(--line); margin: 6px -6px; }
.pop-item { display: flex; align-items: center; gap: 10px; width: 100%; border: 0; background: transparent; padding: 7px 8px; border-radius: 6px; font: inherit; color: var(--ink); cursor: pointer; text-align: left; }
.pop-item:hover, .pop-item:focus-visible { background: var(--hover); outline: none; }
.pop-item .ic { color: var(--muted); }
.pop-item.danger { color: var(--err); }
.pop-item-text { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.pop-item-text > span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pop-hint { font-size: 11.5px; color: var(--muted); }
.pop-check { color: var(--accent) !important; }
.ic-space { width: 16px; flex: none; }
.pop-user { display: flex; gap: 10px; align-items: center; padding: 6px 8px; }
.pop-user .avatar { width: 32px; height: 32px; font-size: 12px; }
.pop-user div { display: flex; flex-direction: column; min-width: 0; }
.pop-user span { font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; }

/* custom native controls (admin-wide) */
input[type=checkbox]:not([role=switch]), input[type=radio] { appearance: none; -webkit-appearance: none; width: 16px; height: 16px; margin: 0; flex: none; border: 1.5px solid #b6bdc9; background: #fff; display: inline-grid; place-content: center; cursor: pointer; transition: border-color .12s, background .12s; vertical-align: middle; }
input[type=checkbox]:not([role=switch]) { border-radius: 4px; }
input[type=radio] { border-radius: 50%; }
input[type=checkbox]:not([role=switch]):hover, input[type=radio]:hover { border-color: #8d96a6; }
input[type=checkbox]:not([role=switch]):checked { background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='8' viewBox='0 0 10 8'%3E%3Cpath d='M1 4.2 3.7 6.8 9 1.2' fill='none' stroke='white' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center no-repeat; border-color: var(--accent); }
input[type=radio]:checked { border-color: var(--accent); background: radial-gradient(var(--accent) 0 3.5px, #fff 4px); }
input[type=checkbox]:focus-visible, input[type=radio]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
input[type=range] { -webkit-appearance: none; appearance: none; height: 4px; border-radius: 2px; background: var(--line-2); cursor: pointer; }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 1.5px solid var(--accent); }
input[type=range]::-moz-range-thumb { width: 14px; height: 14px; border-radius: 50%; background: #fff; border: 1.5px solid var(--accent); }
input[type=range]:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.check-sm { font-size: 12px; color: var(--ink-2); gap: 6px; }
.check-sm input { width: 14px; height: 14px; }
.toggle-text { display: flex; flex-direction: column; gap: 1px; }
.toggle-sm { margin: 0; align-items: center; }
.toggle-sm .switch { width: 26px; height: 15px; }
.toggle-sm .switch::after { width: 11px; height: 11px; }
.toggle-sm input:checked + .switch::after { transform: translateX(11px); }

/* image field + picker */
.img-field { display: grid; grid-template-columns: 34px 1fr auto auto; gap: 6px; align-items: center; }
.img-thumb { width: 34px; height: 34px; border: 1px solid var(--line-2); border-radius: 6px; display: grid; place-content: center; overflow: hidden; color: var(--muted); background: #f7f8fa; }
.img-thumb img { width: 100%; height: 100%; object-fit: cover; }
.picker { display: flex; flex-direction: column; gap: 12px; }
.picker-tabs { align-self: flex-start; }
.icon-groups { max-height: 46vh; overflow: auto; display: flex; flex-direction: column; gap: 12px; padding-right: 2px; }
.icon-group-title { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: 6px; }
.icon-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; }
.icon-cell { aspect-ratio: 1; display: grid; place-content: center; border: 1px solid transparent; border-radius: 7px; background: transparent; color: var(--ink-2); cursor: pointer; }
.icon-cell:hover { background: var(--hover); color: var(--ink); }
.icon-cell.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-ink); }

/* options editor */
.opt-head { display: flex; justify-content: space-between; align-items: center; }
.opt-list .opt-row { grid-template-columns: 30px 1fr 26px; }
.opt-list.with-values .opt-row { grid-template-columns: 30px 1fr 1fr 26px; }
.opt-vis { width: 30px; height: 30px; padding: 0; border: 1px solid var(--line-2); border-radius: 6px; background: #fff; display: grid; place-content: center; cursor: pointer; color: var(--ink-2); }
.opt-vis:hover { border-color: var(--accent); color: var(--accent-ink); }
.ov { display: grid; place-content: center; line-height: 0; }
.ov-img img { width: 26px; height: 26px; object-fit: cover; border-radius: 4px; }
.ov-empty { color: #b6bdc9; }
.pv-opt .ov { color: var(--cv-accent, var(--accent)); }
.pv-opt .ov-img img { width: 18px; height: 18px; }
.pv-opts.pv-tiles { display: grid; grid-template-columns: repeat(3, 1fr); }
.pv-tiles .pv-opt { flex-direction: column; justify-content: center; padding: 12px 6px; text-align: center; }
.pv-tiles .pv-radio, .pv-tiles .pv-box { display: none; }
.pv-tiles .ov svg { width: 24px; height: 24px; }

/* inspector hierarchy */
.inspector { padding: 0 0 40px; }
.insp-head { position: sticky; top: 0; z-index: 3; display: flex; align-items: center; gap: 10px; padding: 14px 16px; background: #fff; border-bottom: 1px solid var(--line); margin: 0; }
.insp-head-text { flex: 1; min-width: 0; }
.insp-title { font-weight: 650; font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.insp-sub { display: flex; align-items: center; gap: 5px; font-size: 12px; color: var(--muted); margin-top: 1px; }
.insp-sub .dot { color: #c9ced8; }
.insp-sub .lock { color: var(--ok); display: inline-flex; }
.insp-head-actions { display: flex; gap: 2px; }
.ico-lg { width: 32px; height: 32px; border-radius: 8px; background: var(--accent-soft); border-color: transparent; }
.ico-lg::after { font-size: 13px; color: var(--accent-ink); }
.insp-sec { border-bottom: 1px solid var(--line); padding: 14px 16px 4px; }
.insp-sec:last-child { border-bottom: 0; }
.insp-sec-title { display: flex; align-items: baseline; justify-content: space-between; font-size: 11px; font-weight: 650; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); margin: 0 0 12px; list-style: none; }
details.insp-sec > summary { cursor: pointer; }
details.insp-sec > summary::-webkit-details-marker { display: none; }
details.insp-sec > summary::after { content: ""; width: 7px; height: 7px; border-right: 1.5px solid var(--muted); border-bottom: 1.5px solid var(--muted); transform: rotate(-45deg); margin-right: 3px; transition: transform .15s; align-self: center; }
details.insp-sec[open] > summary::after { transform: rotate(45deg); }
details.insp-sec:not([open]) { padding-bottom: 2px; }
.insp-sec-hint { text-transform: none; letter-spacing: 0; font-weight: 400; }
.insp-empty { padding: 40px 22px; text-align: center; }
.insp-empty-ico, .lg-empty-ico { width: 44px; height: 44px; border-radius: 12px; background: var(--accent-soft); color: var(--accent-ink); display: grid; place-content: center; margin: 0 auto 12px; }
.insp-logic { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; margin: 2px 0 12px; padding-top: 10px; border-top: 1px dashed var(--line); }
.insp-rules { margin: 0; padding: 0 0 0 16px; font-size: 12.5px; line-height: 1.5; }

/* logic editor */
.lg-list { display: flex; flex-direction: column; gap: 12px; }
.lg-rule { background: #fff; border: 1px solid var(--line); border-radius: 10px; transition: border-color .3s; }
.lg-rule.focus { border-color: var(--accent); }
.lg-rule.off { opacity: .55; }
.lg-head { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.lg-num { width: 22px; height: 22px; border-radius: 6px; background: #f1f3f6; color: var(--ink-2); font-size: 12px; font-weight: 650; display: grid; place-content: center; flex: none; }
.lg-summary { flex: 1; margin: 0; color: var(--ink); font-weight: 500; line-height: 1.4; }
.lg-tools { display: flex; align-items: center; gap: 2px; }
.lg-tools .toggle-sm { margin-right: 6px; }
.lg-body { display: grid; grid-template-columns: 1fr 28px 1fr; gap: 10px; padding: 14px; align-items: start; }
.lg-arrow { align-self: center; color: #b6bdc9; font-size: 18px; text-align: center; }
.lg-block { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.lg-block-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 26px; }
.lg-tag { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; padding: 3px 8px; border-radius: 5px; }
.lg-tag-when { background: #fff4e5; color: #9a5b00; }
.lg-tag-then { background: var(--ok-soft); color: var(--ok); }
.lg-row { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .9fr) minmax(0, 1fr) 26px; gap: 6px; align-items: center; }
.lg-then .lg-row { grid-template-columns: minmax(0, .9fr) minmax(0, 1.25fr) minmax(0, .8fr) 26px; }
.lg-novalue { display: block; }
.lg-conn { font-size: 11px; font-weight: 650; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding-left: 10px; position: relative; }
.lg-add { align-self: flex-start; display: inline-flex; align-items: center; gap: 5px; border: 1px dashed var(--line-2); background: transparent; color: var(--ink-2); font: inherit; font-size: 12.5px; padding: 5px 10px; border-radius: 6px; cursor: pointer; }
.lg-add:hover { border-color: var(--accent); color: var(--accent-ink); }
.lg-empty { text-align: center; padding: 40px 20px; background: #fff; border: 1px dashed var(--line-2); border-radius: 10px; }
.lg-starters { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; max-width: 720px; margin: 18px auto 0; }
.lg-starter { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; text-align: left; padding: 14px; border: 1px solid var(--line-2); border-radius: 9px; background: #fff; font: inherit; cursor: pointer; color: var(--ink-2); }
.lg-starter .ic { color: var(--accent-ink); margin-bottom: 4px; }
.lg-starter b { color: var(--ink); }
.lg-starter:hover { border-color: var(--accent); }
.rule .lg-row { width: 100%; }

/* create form modal */
.newform { display: grid; grid-template-columns: 250px 1fr; gap: 20px; min-height: 420px; }
.newform-left { display: flex; flex-direction: column; gap: 8px; }
.tpl-list { display: flex; flex-direction: column; gap: 4px; }
.tpl-item { display: flex; gap: 10px; align-items: flex-start; text-align: left; padding: 10px; border: 1px solid transparent; border-radius: 8px; background: transparent; font: inherit; cursor: pointer; color: var(--ink-2); }
.tpl-item:hover { background: var(--hover); }
.tpl-item.on { background: var(--accent-soft); border-color: color-mix(in srgb, var(--accent) 35%, transparent); }
.tpl-ico { width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--line-2); background: #fff; display: grid; place-content: center; color: var(--ink-2); flex: none; }
.tpl-item.on .tpl-ico { color: var(--accent-ink); border-color: color-mix(in srgb, var(--accent) 40%, transparent); }
.tpl-text { display: flex; flex-direction: column; gap: 1px; font-size: 12.5px; line-height: 1.4; }
.tpl-text b { color: var(--ink); font-size: 13.5px; font-weight: 600; }
.newform-right { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.tpl-preview { background: #f3f4f7; border: 1px solid var(--line); border-radius: 10px; padding: 14px 18px 18px; max-height: 300px; overflow: hidden; position: relative; }
.tpl-preview::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 40px; background: linear-gradient(transparent, #f3f4f7); }
.tpl-preview-label { font-size: 11px; font-weight: 650; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); margin-bottom: 10px; }
.tp { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 18px; }
.tp-title { font-weight: 700; font-size: 15px; text-align: center; }
.tp-desc { font-size: 11.5px; color: var(--muted); text-align: center; margin-top: 3px; }
.tp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 10px; margin-top: 14px; }
.tp-field { grid-column: span 2; min-width: 0; }
.tp-field.half { grid-column: span 1; }
.tp-label { font-size: 11px; font-weight: 600; margin-bottom: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tp-label em { color: var(--err); font-style: normal; margin-left: 2px; }
.tp-input { height: 24px; border: 1px solid var(--line-2); border-radius: 5px; font-size: 10px; color: var(--muted); display: flex; align-items: center; justify-content: center; }
.tp-area { height: 44px; }
.tp-file { border-style: dashed; }
.tp-opts { display: flex; flex-direction: column; gap: 4px; }
.tp-opts.grid { display: grid; grid-template-columns: 1fr 1fr; }
.tp-opts.inline { flex-direction: row; flex-wrap: wrap; }
.tp-opt { display: flex; align-items: center; gap: 6px; border: 1px solid var(--line-2); border-radius: 5px; padding: 3px 7px; font-size: 10.5px; white-space: nowrap; overflow: hidden; }
.tp-opt i { width: 8px; height: 8px; border: 1.2px solid #aab3c2; border-radius: 50%; flex: none; }
.tp-stars { color: #cfd5df; letter-spacing: 2px; }
.tp-nps { display: flex; gap: 3px; }
.tp-nps span { flex: 1; border: 1px solid var(--line-2); border-radius: 3px; font-size: 9px; text-align: center; padding: 2px 0; }
.tp-btn { display: inline-block; margin-top: 14px; background: #0c1e3a; color: #fff; font-size: 11px; font-weight: 600; padding: 6px 14px; border-radius: 5px; }

/* design tab additions */
.dz-group-title { font-size: 11px; font-weight: 650; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); margin: 14px 0 8px; }
.dz-section h3 + .dz-group-title { margin-top: 0; }
.dz-section-head + .dz-group-title { margin-top: 4px; }
.pair-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-bottom: 6px; }
.pair { display: flex; flex-direction: column; gap: 3px; text-align: left; padding: 10px 11px; border: 1px solid var(--line-2); border-radius: 8px; background: #fff; cursor: pointer; min-width: 0; }
.pair:hover { border-color: #aeb7c4; }
.pair.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.pair-h { font-size: 17px; font-weight: 600; color: var(--ink); line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pair-b { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

@media (max-width: 860px) {
  .newform { grid-template-columns: 1fr; }
  .lg-body { grid-template-columns: 1fr; }
  .lg-arrow { transform: rotate(90deg); }
  .lg-row, .lg-then .lg-row { grid-template-columns: 1fr 1fr; }
  .topbar-slash, .ws-name { display: none; }
}

/* ================= v3: editor chrome, share, polish ================= */
.ed-top { display: block; padding: 0; gap: 0; }
.ed-row { display: flex; align-items: center; gap: 8px; padding: 9px 14px 8px; flex-wrap: wrap; }
.ed-back { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); font-weight: 500; padding: 5px 8px 5px 4px; }
.ed-back .ic { transform: rotate(90deg); }
.ed-back:hover { color: var(--ink); }
.ed-crumb-sep { color: #c9ced8; font-size: 18px; font-weight: 300; }
.ed-name { min-width: 0; max-width: 420px; }
.ed-tabs { display: flex; gap: 2px; padding: 0 10px; overflow-x: auto; scrollbar-width: none; }
.ed-tabs::-webkit-scrollbar { display: none; }
.ed-tabs button { position: relative; display: inline-flex; align-items: center; gap: 7px; border: 0; background: transparent; font: inherit; font-weight: 500; color: var(--muted); padding: 9px 10px 11px; cursor: pointer; white-space: nowrap; border-radius: 6px 6px 0 0; }
.ed-tabs button:hover { color: var(--ink); background: var(--hover); }
.ed-tabs button.on { color: var(--ink); }
.ed-tabs button.on::after { content: ""; position: absolute; left: 8px; right: 8px; bottom: 0; height: 2px; border-radius: 2px 2px 0 0; background: var(--accent); }
.ed-tabs button.on .ic { color: var(--accent); }
.ed-tabs .count { font-size: 11px; background: #eef1f5; color: var(--ink-2); padding: 0 6px; border-radius: 9px; font-weight: 600; line-height: 17px; }
.ed-side { width: 236px; padding-bottom: 20px; }
.side-title { font-size: 11px; font-weight: 650; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); padding: 16px 14px 2px; }
.pal-group { padding: 2px 10px; }
.pal-head { padding: 10px 4px 6px; }
.pal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.pal-item { flex-direction: column; align-items: flex-start; gap: 6px; padding: 9px 9px 8px; border: 1px solid var(--line); border-radius: 8px; background: #fff; font-size: 12.5px; line-height: 1.2; }
.pal-item:hover { border-color: color-mix(in srgb, var(--accent) 45%, transparent); background: var(--accent-soft); }
.pal-ico { width: 26px; height: 26px; border-radius: 7px; background: #f3f5f8; color: var(--ink-2); display: grid; place-content: center; }
.pal-item:hover .pal-ico { background: #fff; color: var(--accent-ink); }

.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; flex-wrap: wrap; }
.card-head h3 { margin: 0; }
.share-methods { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-bottom: 16px; }
.share-method { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; text-align: left; padding: 14px 16px; border: 1px solid var(--line-2); border-radius: 10px; background: #fff; font: inherit; color: var(--muted); cursor: pointer; transition: border-color .12s; }
.share-method b { color: var(--ink); font-size: 14px; }
.share-method:hover { border-color: #b3bcc9; }
.share-method.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.share-ico { width: 34px; height: 34px; border-radius: 9px; background: #f3f5f8; color: var(--ink-2); display: grid; place-content: center; margin-bottom: 6px; }
.share-method.on .share-ico { background: var(--accent-soft); color: var(--accent-ink); }
.big-copy { display: flex; gap: 8px; margin-bottom: 10px; }
.big-copy .inp { font-size: 14px; padding: 10px 12px; }
.code-wrap { position: relative; }
.code-wrap .code { padding-top: 46px; }
.code-copy { position: absolute; top: 8px; right: 8px; background: rgba(255,255,255,.08); color: #e5ecff; border-color: rgba(255,255,255,.18); }
.code-copy:hover { background: rgba(255,255,255,.16); }
.explain { border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px 6px; margin: 0 0 14px; background: #fbfcfd; }
.explain-steps { list-style: none; margin: 0 0 8px; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.explain-steps li { display: flex; gap: 10px; align-items: flex-start; }
.explain-steps li > div { display: flex; flex-direction: column; gap: 2px; font-size: 12.5px; color: var(--ink-2); line-height: 1.45; }
.explain-steps b { color: var(--ink); font-size: 13px; }
.explain-ico { width: 28px; height: 28px; border-radius: 8px; background: var(--accent-soft); color: var(--accent-ink); display: grid; place-content: center; flex: none; }
.pv-tiles.pv-cards-sm .pv-opt { flex-direction: row; justify-content: flex-start; text-align: left; }
.pv-tiles.pv-cards-sm .ov svg { width: 18px; height: 18px; }

/* page + dashboard polish */
.page-head h1 { font-size: 22px; }
.form-row .form-name { display: inline-block; }
.form-row .form-name:hover { color: var(--accent-ink); text-decoration: none; }
.card h3 { font-size: 14.5px; }
.btn-primary .ic { color: #fff; }

@media (max-width: 860px) {
  .share-methods, .explain-steps { grid-template-columns: 1fr; }
  .ed-side { width: auto; }
  .pal-grid { grid-template-columns: repeat(3, 1fr); }
  .big-copy { flex-direction: column; }
}

/* ================= v4: build palette + canvas cards ================= */
.tone-blue   { --tone: #2f6fed; --tone-soft: #edf3ff; }
.tone-violet { --tone: #7048e8; --tone-soft: #f3efff; }
.tone-teal   { --tone: #0c8a7c; --tone-soft: #e6f6f3; }
.tone-amber  { --tone: #c26a00; --tone-soft: #fff4e2; }
.tone-slate  { --tone: #4f5b6d; --tone-soft: #f0f2f5; }

.ed-side { width: 264px; padding: 0 0 16px; background: #fbfbfc; }
.pal-top { position: sticky; top: 0; z-index: 2; background: #fbfbfc; padding: 14px 14px 10px; border-bottom: 1px solid var(--line); }
.pal-title { font-weight: 650; font-size: 13.5px; margin: 0 0 10px; }
.pal-search-wrap { display: flex; align-items: center; gap: 7px; height: 34px; padding: 0 10px; border: 1px solid var(--line-2); border-radius: 8px; background: #fff; color: var(--muted); transition: border-color .12s; }
.pal-search-wrap:focus-within { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.pal-search { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font: inherit; color: var(--ink); }
.pal-list { padding: 4px 8px 0; }
.pal-group { padding: 0; }
.pal-head { font-size: 10.5px; font-weight: 650; text-transform: uppercase; letter-spacing: .08em; color: #8a93a3; padding: 14px 8px 6px; }
.pal-item { display: flex; flex-direction: row; align-items: center; gap: 11px; width: 100%; padding: 7px 8px; border: 1px solid transparent; border-radius: 9px; background: transparent; font: inherit; color: var(--ink); cursor: grab; text-align: left; transition: background .12s, border-color .12s, transform .08s; }
.pal-item:hover { background: #fff; border-color: var(--line); }
.pal-item:active { cursor: grabbing; transform: scale(.99); }
.pal-item:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.pal-ico { width: 32px; height: 32px; border-radius: 9px; display: grid; place-content: center; flex: none; background: var(--tone-soft); color: var(--tone); border: 0; }
.pal-item:hover .pal-ico { background: var(--tone-soft); color: var(--tone); }
.pal-text { display: flex; flex-direction: column; min-width: 0; flex: 1; line-height: 1.25; }
.pal-name { font-weight: 550; font-size: 13.5px; }
.pal-hint { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pal-add { width: 24px; height: 24px; border-radius: 6px; display: grid; place-content: center; color: var(--muted); opacity: 0; transition: opacity .12s, background .12s; }
.pal-item:hover .pal-add { opacity: 1; background: var(--hover); color: var(--ink); }
.pal-empty { color: var(--muted); font-size: 12.5px; padding: 16px 10px; }
.pal-tip { font-size: 11.5px; color: var(--muted); margin: 14px 16px 0; line-height: 1.45; }

/* canvas */
.canvas-scroll { background: radial-gradient(circle at 1px 1px, #e3e6ec 1px, transparent 0) 0 0 / 18px 18px, var(--bg); }
.cv-form { padding: 30px 30px 26px; border-radius: 12px; }
.cv-grid { row-gap: 2px; }
.cv-field { padding: 12px 14px 14px; border-radius: 10px; border: 1px solid transparent; transition: border-color .12s, background .12s, opacity .12s; }
.cv-field:hover { border-color: color-mix(in srgb, var(--cv-text, #161b26) 14%, transparent); background: color-mix(in srgb, var(--cv-text, #161b26) 2.5%, transparent); }
.cv-field.sel { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 4%, transparent); box-shadow: inset 0 0 0 1px var(--accent); }
.cv-field.dragging { opacity: .35; }
.cv-field.over { box-shadow: inset 0 3px 0 0 var(--accent); }
.dragging-new .cv-drop-end { height: 40px; border: 1.5px dashed var(--line-2); margin-top: 6px; }
.dragging-new .cv-drop-end.over { border-color: var(--accent); background: var(--accent-soft); }
.cv-field.dim { opacity: .72; }
.cv-field.dim .cv-label { font-style: normal; }
.cv-field-head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; min-height: 22px; }
.cv-grip { color: color-mix(in srgb, var(--cv-text, #161b26) 30%, transparent); cursor: grab; margin-left: -6px; opacity: 0; transition: opacity .12s; display: inline-flex; }
.cv-field:hover .cv-grip, .cv-field.sel .cv-grip { opacity: 1; }
.cv-label { font-weight: 600; font-size: 14px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cv-label .req { color: var(--err); margin-left: 3px; }
.cv-type { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 500; color: var(--tone); background: var(--tone-soft); padding: 2px 8px 2px 6px; border-radius: 999px; white-space: nowrap; }
.cv-type .cv-id { display: none; color: inherit; opacity: .75; font-size: 10.5px; }
.cv-field:hover .cv-type .cv-id, .cv-field.sel .cv-type .cv-id { display: inline; }
.cv-field:hover .cv-type .cv-type-name::after, .cv-field.sel .cv-type .cv-type-name::after { content: " ·"; }
.cv-help { font-size: 12.5px; color: color-mix(in srgb, var(--cv-text, #161b26) 55%, transparent); margin: -4px 0 8px; }
.cv-flags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.cv-flag { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 500; color: var(--ink-2); background: #f1f3f6; padding: 2px 8px 2px 6px; border-radius: 999px; }
.cv-flag-logic { background: #fff4e5; color: #9a5b00; }
.cv-tools { position: absolute; top: -15px; right: 10px; display: flex; align-items: center; gap: 1px; padding: 2px; background: #fff; border: 1px solid var(--line-2); border-radius: 8px; opacity: 0; transform: translateY(2px); pointer-events: none; transition: opacity .12s, transform .12s; z-index: 3; }
.cv-field:hover .cv-tools, .cv-field.sel .cv-tools, .cv-field:focus-within .cv-tools { opacity: 1; transform: none; pointer-events: auto; }
.cv-tool { width: 28px; height: 26px; border: 0; border-radius: 6px; background: transparent; color: var(--ink-2); display: grid; place-content: center; cursor: pointer; }
.cv-tool:hover { background: var(--hover); color: var(--ink); }
.cv-tool.danger:hover { background: var(--err-soft); color: var(--err); }
.cv-tool-sep { width: 1px; height: 16px; background: var(--line); margin: 0 2px; }
.cv-page-head { margin: 0 0 8px; }
.cv-page-name { font-size: 11.5px; font-weight: 650; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.cv-add-page { display: flex; align-items: center; justify-content: center; gap: 6px; width: 100%; margin-top: 10px; padding: 10px; border: 1.5px dashed var(--line-2); border-radius: 10px; background: transparent; font: inherit; font-weight: 500; color: var(--muted); cursor: pointer; transition: border-color .12s, color .12s, background .12s; }
.cv-add-page:hover { border-color: var(--accent); color: var(--accent-ink); background: var(--accent-soft); }
.cv-empty { padding: 28px; border-radius: 10px; border: 1.5px dashed var(--line-2); }
.wash-row { display: grid; grid-template-columns: repeat(8, 1fr); gap: 6px; }
.wash { aspect-ratio: 1; border-radius: 8px; border: 1px solid var(--line-2); cursor: pointer; background-size: cover; padding: 0; }
.wash:hover { border-color: #9aa4b4; }
.wash.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent), 0 0 0 2px #fff inset; }
.wash-none { background: #fff linear-gradient(135deg, transparent 46%, #d5d9e1 46%, #d5d9e1 54%, transparent 54%); }
.theme-swatch { background-size: cover; }

/* ================= v5: zapier guide, partials ================= */
.zap { border: 1px solid #ffd8c2; background: #fffaf6; border-radius: 10px; margin: 0 0 14px; }
.zap[open] { padding-bottom: 6px; }
.zap-head { display: flex; align-items: center; gap: 10px; padding: 11px 12px; cursor: pointer; list-style: none; }
.zap-head::-webkit-details-marker { display: none; }
.zap-head::after { content: ""; width: 7px; height: 7px; border-right: 1.5px solid #c2611e; border-bottom: 1.5px solid #c2611e; transform: rotate(-45deg); margin-left: auto; transition: transform .15s; }
.zap[open] > .zap-head::after { transform: rotate(45deg); }
.zap-logo { width: 30px; height: 30px; border-radius: 8px; background: #ff5a1f; color: #fff; display: grid; place-content: center; flex: none; }
.zap-title { display: flex; flex-direction: column; line-height: 1.3; }
.zap-title span { font-size: 12px; color: #9a5b33; }
.zap-steps { list-style: none; margin: 0; padding: 4px 14px 0; display: flex; flex-direction: column; gap: 12px; }
.zap-step { display: flex; gap: 11px; }
.zap-num { width: 22px; height: 22px; border-radius: 50%; background: #fff; border: 1px solid #ffc6a6; color: #c2611e; font-size: 11.5px; font-weight: 700; display: grid; place-content: center; flex: none; margin-top: 1px; }
.zap-step-body { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; min-width: 0; font-size: 13px; color: var(--ink-2); }
.zap-step-body b { color: var(--ink); }
.zap-step-body p { margin: 0; line-height: 1.5; }
.zap-step-body code { background: #fff; border: 1px solid var(--line); border-radius: 4px; padding: 0 4px; font-size: 11.5px; }
.zap-fields { width: 100%; }
.zap-chips { display: flex; flex-wrap: wrap; gap: 5px; }
.zap-chip { font-size: 11.5px; padding: 2px 8px; border-radius: 999px; background: #fff; border: 1px solid var(--line-2); color: var(--ink-2); white-space: nowrap; }
.zap-chip-main { border-color: #ffc6a6; color: #8a3f10; }
.zap-meta { margin: 8px 0 0; font-size: 12px; }
.zap-foot { margin: 10px 14px 6px; }

.seg-count { margin-left: 6px; font-size: 11px; padding: 0 6px; border-radius: 9px; background: #eef1f5; color: var(--ink-2); font-weight: 600; }
.seg button.on .seg-count { background: #fff; color: var(--accent-ink); }
.partial-stats { display: flex; gap: 22px; padding: 12px 14px; border-bottom: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.partial-stats b { color: var(--ink); font-size: 15px; margin-right: 2px; }
.progress-cell { display: flex; align-items: center; gap: 8px; min-width: 110px; }
.progress-bar { flex: 1; height: 6px; border-radius: 3px; background: #eef1f5; overflow: hidden; }
.progress-bar i { display: block; height: 100%; background: var(--accent); border-radius: 3px; }

/* ================= v6: single-row editor header ================= */
.ed-top { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 16px; height: 58px; padding: 0 12px 0 8px; background: #fff; border-bottom: 1px solid var(--line); flex-wrap: nowrap; }
.ed-left { display: flex; align-items: center; gap: 4px; min-width: 0; }
.ed-back { width: 34px; height: 34px; padding: 0; justify-content: center; border-radius: 8px; color: var(--muted); }
.ed-back:hover { background: var(--hover); color: var(--ink); }
.ed-titlebox { display: flex; flex-direction: column; min-width: 0; gap: 1px; }
.ed-name { font-size: 14.5px; font-weight: 650; padding: 1px 6px; height: 26px; max-width: 100%; }
.ed-meta { display: flex; align-items: center; gap: 8px; padding-left: 7px; min-width: 0; }
.ed-meta .badge { font-size: 10.5px; padding: 1px 7px; }
.ed-savestate { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.ed-savestate i { width: 6px; height: 6px; border-radius: 50%; background: var(--ok); transition: background .2s; }
.ed-savestate[data-state=saving] i { background: #e0a100; animation: rf-pulse 1s ease-in-out infinite; }
.ed-savestate[data-state=unsaved] i { background: #b6bdc9; }
@keyframes rf-pulse { 50% { opacity: .35; } }
.ed-nav2 { display: flex; gap: 2px; padding: 3px; border-radius: 10px; background: #f2f4f7; border: 1px solid var(--line); }
.ed-nav2 button { display: inline-flex; align-items: center; gap: 7px; height: 32px; padding: 0 13px; border: 0; border-radius: 7px; background: transparent; font: inherit; font-weight: 550; color: var(--ink-2); cursor: pointer; white-space: nowrap; transition: background .12s, color .12s; }
.ed-nav2 button .ic { color: var(--muted); transition: color .12s; }
.ed-nav2 button:hover { color: var(--ink); }
.ed-nav2 button:hover .ic { color: var(--ink-2); }
.ed-nav2 button.on { background: #fff; color: var(--ink); box-shadow: 0 0 0 1px var(--line-2); }
.ed-nav2 button.on .ic { color: var(--accent); }
.ed-nav2 button:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.ed-nav2 .count { font-size: 10.5px; line-height: 16px; padding: 0 6px; border-radius: 8px; background: #e6e9ef; color: var(--ink-2); font-weight: 650; }
.ed-nav2 button.on .count { background: var(--accent-soft); color: var(--accent-ink); }
.ed-right { display: flex; align-items: center; justify-content: flex-end; gap: 4px; min-width: 0; }
.ed-gear, .ed-more { width: 34px; height: 34px; display: grid; place-content: center; border-radius: 8px; padding: 0; color: var(--ink-2); }
.ed-gear.on { background: var(--accent-soft); color: var(--accent-ink); }
.ed-divider { width: 1px; height: 22px; background: var(--line); margin: 0 6px; }
.ed-publish { min-width: 112px; }
.ed-publish .pub-dot { display: none; width: 6px; height: 6px; border-radius: 50%; background: #fff; }
.ed-publish.has-changes .pub-dot { display: inline-block; }
.ed-publish:not(.has-changes) { background: #fff; color: var(--ok); border-color: var(--line-2); }
.ed-publish:not(.has-changes):hover { background: var(--ok-soft); }
.panel-head .seg { flex-wrap: nowrap; }

@media (max-width: 1180px) {
  .ed-nav2 button { padding: 0 10px; }
  .ed-nav2 button:not(.on) > .nav-label { display: none; }
  .ed-nav2 button:not(.on) { gap: 0; }
  .ed-nav2 button .count { margin-left: 5px; }
}
@media (max-width: 860px) {
  .ed-top { grid-template-columns: minmax(0, 1fr) auto; height: auto; padding: 8px; row-gap: 8px; }
  .ed-nav2 { grid-column: 1 / -1; grid-row: 2; overflow-x: auto; justify-content: space-between; }
  .hide-sm { display: none; }
  .ed-publish { min-width: 0; }
}

.toolbar { display: flex; align-items: center; gap: 8px; margin: 0 0 12px; flex-wrap: wrap; }
.search-wrap { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 10px; border: 1px solid var(--line-2); border-radius: 7px; background: #fff; color: var(--muted); }
.search-wrap:focus-within { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.search-wrap .inp, .toolbar-search { border: 0 !important; box-shadow: none !important; padding: 0 !important; width: 200px; background: transparent; }
.empty-state { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding: 48px 20px; }
.empty-state b { font-size: 14.5px; }
.empty-state p { color: var(--muted); max-width: 420px; margin: 0 0 8px; }
.empty-ico { width: 44px; height: 44px; border-radius: 12px; background: #f1f3f6; color: var(--ink-2); display: grid; place-content: center; margin-bottom: 6px; }
.panel-head { margin-bottom: 14px; }
