/* ─────────────────────────────────────────
   WEBCRAFT BUILDER — style.css
   System-aware theme (light/dark)
───────────────────────────────────────── */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:       #ffffff;
  --bg2:      #f8f9fa;
  --bg3:      #f1f3f5;
  --bg4:      #e9ecef;
  --border:   #dee2e6;
  --border2:  #ced4da;
  --text:     #212529;
  --text2:    #495057;
  --text3:    #868e96;
  --accent:   #2563eb;
  --accent2:  #1d4ed8;
  --accent-bg:#eff6ff;
  --red:      #dc2626;
  --red-bg:   #fef2f2;
  --green:    #16a34a;
  --r:        6px;
  --r2:       10px;
  --sidebar-w: 220px;
  --rpanel-w:  240px;
  --topbar-h:  48px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg:       #0d0f12;
    --bg2:      #13161b;
    --bg3:      #1a1e26;
    --bg4:      #222733;
    --border:   rgba(255,255,255,0.08);
    --border2:  rgba(255,255,255,0.15);
    --text:     #e8eaf0;
    --text2:    #8b92a5;
    --text3:    #555e72;
    --accent:   #4f8ef7;
    --accent2:  #2563eb;
    --accent-bg:rgba(79,142,247,0.1);
    --red:      #ef4444;
    --red-bg:   rgba(239,68,68,0.1);
    --green:    #22c55e;
  }
}

html, body {
  height: 100%;
  font-family: 'DM Sans', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow: hidden;
}

/* ── SCROLLBARS ── */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--bg4); border-radius: 3px; }

/* ─────────────────────────────────────────
   TOPBAR
───────────────────────────────────────── */
#topbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--topbar-h);
  background: var(--bg2);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 14px;
  z-index: 200;
  gap: 12px;
}

.tb-left  { display: flex; align-items: center; gap: 10px; min-width: 200px; }
.tb-right { display: flex; align-items: center; gap: 6px; justify-content: flex-end; min-width: 200px; }

.logo {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.4px;
  color: var(--text);
  white-space: nowrap;
}
.logo span { color: var(--accent); }

.tb-divider {
  width: 1px;
  height: 18px;
  background: var(--border);
}

.site-title-input {
  font-size: 13px;
  font-family: inherit;
  font-weight: 500;
  color: var(--text2);
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--r);
  padding: 3px 8px;
  outline: none;
  width: 160px;
  transition: border-color .15s, background .15s;
}
.site-title-input:hover { border-color: var(--border); }
.site-title-input:focus { border-color: var(--accent); background: var(--bg3); color: var(--text); }

.tb-center {
  display: flex;
  align-items: center;
  gap: 3px;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 3px;
}
.vbtn {
  padding: 4px 14px;
  font-size: 12px;
  font-family: inherit;
  border-radius: 4px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text3);
  cursor: pointer;
  transition: all .15s;
}
.vbtn:hover { color: var(--text2); }
.vbtn.active {
  background: var(--bg);
  color: var(--text);
  border-color: var(--border);
}

.tbtn {
  padding: 6px 12px;
  font-size: 12px;
  font-family: inherit;
  border-radius: var(--r);
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text2);
  cursor: pointer;
  transition: all .15s;
  white-space: nowrap;
}
.tbtn:hover { background: var(--bg3); color: var(--text); }
.tbtn-export {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  font-weight: 500;
}
.tbtn-export:hover { background: var(--accent2); border-color: var(--accent2); }

/* ─────────────────────────────────────────
   APP SHELL
───────────────────────────────────────── */
#app {
  display: flex;
  height: 100vh;
  padding-top: var(--topbar-h);
}

/* ─────────────────────────────────────────
   LEFT SIDEBAR
───────────────────────────────────────── */
#sidebar-left {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: var(--bg2);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.stabs {
  display: flex;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.stab {
  flex: 1;
  padding: 10px 4px;
  font-size: 12px;
  font-family: inherit;
  font-weight: 500;
  text-align: center;
  border: none;
  background: transparent;
  color: var(--text3);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all .15s;
}
.stab:hover { color: var(--text2); }
.stab.active { color: var(--accent); border-bottom-color: var(--accent); }

.tab-content {
  display: none;
  flex-direction: column;
  flex: 1;
  overflow-y: auto;
  padding: 12px 10px;
}
.tab-content.active { display: flex; }

.block-section-label {
  font-size: 10px;
  font-weight: 600;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: .7px;
  margin: 8px 2px 6px;
}
.block-section-label:first-child { margin-top: 0; }

.block-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px;
  margin-bottom: 4px;
}

.block-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 8px 4px;
  border-radius: var(--r);
  border: 1px solid var(--border);
  background: var(--bg3);
  cursor: grab;
  font-size: 10px;
  color: var(--text2);
  transition: all .15s;
  user-select: none;
}
.block-item:hover {
  border-color: var(--accent);
  background: var(--accent-bg);
  color: var(--accent);
  transform: translateY(-1px);
}
.block-item:active { cursor: grabbing; }

.block-thumb {
  width: 36px;
  height: 24px;
  border-radius: 4px;
  background: var(--bg4);
  position: relative;
  overflow: hidden;
}
.bt-nav   { background: linear-gradient(to bottom, var(--accent) 40%, var(--bg4) 40%); opacity: .5; }
.bt-hero  { background: var(--bg4); }
.bt-hero::before { content: ''; position: absolute; left: 6px; top: 5px; width: 24px; height: 4px; background: var(--text3); border-radius: 2px; }
.bt-hero::after  { content: ''; position: absolute; left: 10px; top: 12px; width: 16px; height: 3px; background: var(--accent); border-radius: 1px; opacity: .6; }
.bt-feat  { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 2px; padding: 4px; }
.bt-feat::before,.bt-feat::after { content: ''; background: var(--text3); border-radius: 1px; opacity: .4; }
.bt-cta   { background: var(--accent); opacity: .3; }
.bt-footer{ background: linear-gradient(to bottom, var(--bg4) 60%, var(--text3) 60%); opacity: .4; }
.bt-text  { padding: 4px 3px; display: flex; flex-direction: column; gap: 2px; justify-content: center; }
.bt-text::before,.bt-text::after { content: ''; display: block; height: 2px; background: var(--text3); border-radius: 1px; opacity: .5; }
.bt-text::before { width: 100%; }
.bt-text::after  { width: 70%; }
.bt-btn   { border: 2px solid var(--accent); border-radius: 3px; opacity: .5; }
.bt-img   { background: var(--bg4); display: flex; align-items: center; justify-content: center; }
.bt-img::after { content: '⬛'; font-size: 12px; opacity: .2; }
.bt-vid   { background: var(--bg4); display: flex; align-items: center; justify-content: center; }
.bt-vid::after { content: '▶'; font-size: 10px; opacity: .3; }
.bt-form  { padding: 3px; display: flex; flex-direction: column; gap: 2px; }
.bt-form::before,.bt-form::after { content: ''; display: block; height: 4px; border: 1px solid var(--text3); border-radius: 1px; opacity: .4; }
.bt-news  { padding: 4px 3px; display: flex; flex-direction: column; gap: 3px; }
.bt-news::before { content: ''; display: block; height: 8px; border: 1px solid var(--text3); border-radius: 1px; opacity: .4; }
.bt-news::after  { content: ''; display: block; height: 5px; background: var(--accent); border-radius: 1px; opacity: .4; width: 60%; align-self: center; }
.bt-prod  { background: var(--bg4); display: grid; grid-template-columns: 1fr 1fr; gap: 2px; padding: 3px; }
.bt-prod::before,.bt-prod::after { content: ''; background: var(--text3); border-radius: 1px; opacity: .3; }
.bt-cart  { padding: 4px; position: relative; }
.bt-cart::before { content: '🛒'; position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); font-size: 14px; opacity: .4; }

/* LAYERS */
.layers-hint {
  font-size: 10px;
  color: var(--text3);
  text-align: center;
  padding: 10px 8px 6px;
  flex-shrink: 0;
}
#layers-list {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 4px 0;
}
.layer-row {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  border-radius: var(--r);
  cursor: pointer;
  transition: all .12s;
  border: 1px solid transparent;
}
.layer-row:hover { background: var(--bg3); }
.layer-row.active {
  background: var(--accent-bg);
  border-color: var(--accent);
}
.layer-color { width: 8px; height: 8px; border-radius: 2px; flex-shrink: 0; }
.layer-label { font-size: 12px; color: var(--text2); flex: 1; }
.layer-row.active .layer-label { color: var(--accent); }
.layer-handle { color: var(--text3); font-size: 11px; cursor: grab; }

/* ─────────────────────────────────────────
   CANVAS
───────────────────────────────────────── */
#canvas-area {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg3);
}

.canvas-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  background: var(--bg2);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.ct-info  { font-size: 11px; font-family: 'DM Mono', monospace; color: var(--text3); }
.ct-sep   { flex: 1; }
.ct-hint  { font-size: 11px; color: var(--text3); }

#canvas-scroll {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 28px 24px;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

#canvas-drop {
  width: 100%;
  max-width: 960px;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  gap: 0;
  transition: max-width .3s ease;
  position: relative;
}

#canvas-drop.drag-over {
  outline: 2px dashed var(--accent);
  outline-offset: 6px;
  border-radius: var(--r2);
}

/* empty state */
.canvas-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 32px;
  text-align: center;
  pointer-events: none;
}
.empty-icon  { font-size: 40px; opacity: .2; margin-bottom: 16px; }
.empty-title { font-size: 18px; font-weight: 600; color: var(--text3); margin-bottom: 6px; }
.empty-sub   { font-size: 13px; color: var(--text3); opacity: .7; }

/* ── CANVAS SECTIONS ── */
.c-section {
  position: relative;
  cursor: pointer;
  outline: 2px solid transparent;
  transition: outline-color .1s;
}
.c-section:hover  { outline-color: rgba(79,142,247,.4); }
.c-section.selected { outline-color: var(--accent); }

.sec-controls {
  display: none;
  position: absolute;
  top: 6px;
  right: 8px;
  gap: 4px;
  z-index: 50;
}
.c-section:hover .sec-controls,
.c-section.selected .sec-controls { display: flex; }

.sc-btn {
  font-size: 11px;
  padding: 3px 9px;
  border-radius: 5px;
  border: 1px solid var(--border2);
  background: var(--bg2);
  color: var(--text2);
  cursor: pointer;
  font-family: inherit;
  transition: all .12s;
  backdrop-filter: blur(4px);
}
.sc-btn:hover  { background: var(--bg3); color: var(--text); }
.sc-del        { color: var(--red) !important; }
.sc-del:hover  { background: var(--red-bg) !important; }

.sec-tag {
  display: none;
  position: absolute;
  top: 6px;
  left: 8px;
  font-size: 9px;
  font-family: 'DM Mono', monospace;
  padding: 2px 7px;
  border-radius: 4px;
  background: var(--accent);
  color: #fff;
  z-index: 50;
  letter-spacing: .3px;
}
.c-section.selected .sec-tag { display: block; }

/* drag-reorder ghost */
.c-section.dragging { opacity: .35; }
.drop-indicator {
  height: 3px;
  background: var(--accent);
  border-radius: 2px;
  margin: 0;
  pointer-events: none;
}

/* ─────────────────────────────────────────
   SECTION TEMPLATES (rendered HTML)
───────────────────────────────────────── */

/* NAV */
.wc-nav {
  background: #0f172a;
  padding: 0 32px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.wc-nav-logo { color: #fff; font-size: 16px; font-weight: 700; }
.wc-nav-links { display: flex; gap: 24px; }
.wc-nav-link  { color: rgba(255,255,255,.55); font-size: 13px; cursor: pointer; }
.wc-nav-cta   { background: #2563eb; color: #fff; padding: 7px 18px; border-radius: 7px; font-size: 13px; cursor: pointer; border: none; font-family: inherit; }

/* HERO */
.wc-hero {
  background: #fff;
  padding: 80px 48px 72px;
  text-align: center;
}
.wc-hero-tag  { display: inline-block; font-size: 11px; color: #2563eb; font-weight: 600; letter-spacing: .6px; text-transform: uppercase; background: #eff6ff; padding: 4px 14px; border-radius: 20px; margin-bottom: 18px; }
.wc-hero-h1   { font-size: 42px; font-weight: 700; color: #0f172a; line-height: 1.15; letter-spacing: -1px; margin-bottom: 16px; }
.wc-hero-sub  { font-size: 15px; color: #64748b; max-width: 520px; margin: 0 auto 28px; line-height: 1.7; }
.wc-hero-btns { display: flex; gap: 10px; justify-content: center; }
.wc-btn-p     { background: #0f172a; color: #fff; padding: 11px 24px; border-radius: 8px; font-size: 14px; cursor: pointer; border: none; font-family: inherit; font-weight: 500; }
.wc-btn-s     { background: transparent; color: #0f172a; padding: 11px 24px; border-radius: 8px; font-size: 14px; cursor: pointer; border: 1.5px solid #e2e8f0; font-family: inherit; }

/* FEATURES */
.wc-features  { background: #f8fafc; padding: 64px 48px; }
.wc-feat-hd   { text-align: center; margin-bottom: 40px; }
.wc-feat-eye  { font-size: 11px; color: #2563eb; font-weight: 600; letter-spacing: .6px; text-transform: uppercase; margin-bottom: 8px; }
.wc-feat-h2   { font-size: 28px; font-weight: 700; color: #0f172a; letter-spacing: -.5px; }
.wc-feat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.wc-feat-card { background: #fff; border-radius: 10px; padding: 22px; border: 1px solid #f1f5f9; }
.wc-feat-ico  { width: 40px; height: 40px; border-radius: 8px; display: flex; align-items: center; justify-content: center; margin-bottom: 12px; font-size: 20px; }
.wc-feat-name { font-size: 14px; font-weight: 600; color: #0f172a; margin-bottom: 6px; }
.wc-feat-desc { font-size: 13px; color: #64748b; line-height: 1.6; }

/* CTA */
.wc-cta      { background: #0f172a; padding: 72px 48px; text-align: center; }
.wc-cta-h2   { font-size: 32px; font-weight: 700; color: #fff; letter-spacing: -.6px; margin-bottom: 10px; }
.wc-cta-sub  { font-size: 15px; color: rgba(255,255,255,.45); margin-bottom: 28px; }
.wc-cta-btn  { background: #2563eb; color: #fff; padding: 12px 28px; border-radius: 8px; font-size: 14px; cursor: pointer; border: none; font-family: inherit; font-weight: 500; }

/* FOOTER */
.wc-footer       { background: #0f172a; padding: 24px 32px; display: flex; align-items: center; justify-content: space-between; border-top: 1px solid rgba(255,255,255,.07); }
.wc-footer-logo  { font-size: 14px; font-weight: 700; color: rgba(255,255,255,.35); }
.wc-footer-links { display: flex; gap: 16px; }
.wc-footer-link  { font-size: 12px; color: rgba(255,255,255,.25); cursor: pointer; }
.wc-footer-copy  { font-size: 12px; color: rgba(255,255,255,.2); }

/* TEXT BLOCK */
.wc-text { background: #fff; padding: 40px 48px; }
.wc-text h2 { font-size: 26px; font-weight: 700; color: #0f172a; margin-bottom: 12px; letter-spacing: -.4px; }
.wc-text p  { font-size: 15px; color: #64748b; line-height: 1.8; max-width: 660px; }

/* BUTTON BLOCK */
.wc-button-block { background: #fff; padding: 32px 48px; display: flex; gap: 10px; }
.wc-button-block button { padding: 11px 24px; border-radius: 8px; font-size: 14px; cursor: pointer; font-family: inherit; font-weight: 500; border: none; }

/* IMAGE BLOCK */
.wc-image { background: #fff; padding: 32px 48px; }
.wc-image-placeholder { background: #f1f5f9; border-radius: 10px; height: 280px; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #94a3b8; gap: 8px; border: 2px dashed #e2e8f0; }
.wc-image-placeholder span { font-size: 40px; }
.wc-image-placeholder p { font-size: 13px; }

/* VIDEO BLOCK */
.wc-video { background: #fff; padding: 32px 48px; }
.wc-video-placeholder { background: #0f172a; border-radius: 10px; height: 280px; display: flex; flex-direction: column; align-items: center; justify-content: center; color: rgba(255,255,255,.4); gap: 8px; }
.wc-video-placeholder span { font-size: 48px; opacity: .5; }
.wc-video-placeholder p { font-size: 13px; }

/* CONTACT FORM */
.wc-form { background: #fff; padding: 64px 48px; }
.wc-form-inner { max-width: 540px; margin: 0 auto; }
.wc-form h2 { font-size: 28px; font-weight: 700; color: #0f172a; margin-bottom: 6px; }
.wc-form p  { color: #64748b; font-size: 14px; margin-bottom: 28px; }
.wc-field { margin-bottom: 16px; }
.wc-field label { display: block; font-size: 13px; font-weight: 500; color: #374151; margin-bottom: 6px; }
.wc-field input, .wc-field textarea {
  width: 100%; padding: 10px 14px; border-radius: 7px;
  border: 1px solid #e2e8f0; font-size: 14px; font-family: inherit;
  color: #0f172a; outline: none; transition: border-color .15s;
}
.wc-field input:focus, .wc-field textarea:focus { border-color: #2563eb; }
.wc-field textarea { height: 120px; resize: vertical; }
.wc-form-btn { background: #2563eb; color: #fff; padding: 11px 24px; border-radius: 8px; font-size: 14px; border: none; font-family: inherit; font-weight: 500; cursor: pointer; }

/* NEWSLETTER */
.wc-newsletter { background: #eff6ff; padding: 64px 48px; text-align: center; }
.wc-newsletter h2 { font-size: 26px; font-weight: 700; color: #0f172a; margin-bottom: 8px; }
.wc-newsletter p  { color: #64748b; font-size: 14px; margin-bottom: 24px; }
.wc-newsletter-form { display: flex; gap: 8px; max-width: 440px; margin: 0 auto; }
.wc-newsletter input { flex: 1; padding: 10px 16px; border-radius: 8px; border: 1px solid #bfdbfe; font-size: 14px; font-family: inherit; outline: none; }
.wc-newsletter button { background: #2563eb; color: #fff; padding: 10px 20px; border-radius: 8px; font-size: 14px; border: none; font-family: inherit; font-weight: 500; cursor: pointer; white-space: nowrap; }

/* PRODUCT */
.wc-product { background: #fff; padding: 48px; }
.wc-product-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.wc-product-card { border-radius: 10px; border: 1px solid #f1f5f9; overflow: hidden; }
.wc-product-img  { background: #f8fafc; height: 180px; display: flex; align-items: center; justify-content: center; color: #94a3b8; font-size: 32px; }
.wc-product-info { padding: 16px; }
.wc-product-name { font-size: 14px; font-weight: 600; color: #0f172a; margin-bottom: 4px; }
.wc-product-price{ font-size: 16px; font-weight: 700; color: #2563eb; margin-bottom: 12px; }
.wc-product-btn  { width: 100%; padding: 9px; background: #0f172a; color: #fff; border: none; border-radius: 7px; font-size: 13px; font-family: inherit; cursor: pointer; }

/* CART */
.wc-cart { background: #fff; padding: 48px; }
.wc-cart h2 { font-size: 22px; font-weight: 700; color: #0f172a; margin-bottom: 20px; }
.wc-cart-item { display: flex; align-items: center; gap: 16px; padding: 16px 0; border-bottom: 1px solid #f1f5f9; }
.wc-cart-thumb { width: 60px; height: 60px; background: #f8fafc; border-radius: 8px; display: flex; align-items: center; justify-content: center; color: #94a3b8; font-size: 20px; flex-shrink: 0; }
.wc-cart-info  { flex: 1; }
.wc-cart-name  { font-size: 14px; font-weight: 600; color: #0f172a; }
.wc-cart-qty   { font-size: 12px; color: #94a3b8; margin-top: 2px; }
.wc-cart-price { font-size: 15px; font-weight: 700; color: #0f172a; }
.wc-cart-total { display: flex; justify-content: space-between; align-items: center; padding: 20px 0 0; }
.wc-cart-total span { font-size: 16px; font-weight: 700; color: #0f172a; }
.wc-checkout-btn { background: #2563eb; color: #fff; padding: 11px 28px; border-radius: 8px; font-size: 14px; border: none; font-family: inherit; font-weight: 500; cursor: pointer; }

/* ─────────────────────────────────────────
   RIGHT PANEL
───────────────────────────────────────── */
#sidebar-right {
  width: var(--rpanel-w);
  flex-shrink: 0;
  background: var(--bg2);
  border-left: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.rp-empty {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 12px;
  color: var(--text3);
  line-height: 1.7;
}

.rp-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
#rp-section-name {
  font-size: 12px;
  font-family: 'DM Mono', monospace;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: .4px;
}
.rp-header-actions { display: flex; gap: 4px; }
.rp-icon-btn {
  width: 24px; height: 24px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 5px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text3);
  cursor: pointer;
  font-size: 12px;
  transition: all .12s;
}
.rp-icon-btn:hover { background: var(--bg3); color: var(--text); }
.rp-del:hover { background: var(--red-bg) !important; color: var(--red) !important; }

.rp-scroll {
  flex: 1;
  overflow-y: auto;
  padding: 12px;
}

.prop-group { margin-bottom: 18px; }
.prop-group-title {
  font-size: 10px;
  font-weight: 600;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: .7px;
  margin-bottom: 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
}

.prop-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
  gap: 6px;
}
.prop-row label {
  font-size: 11px;
  color: var(--text3);
  flex-shrink: 0;
  width: 68px;
}

.prop-input {
  flex: 1;
  font-size: 11px;
  font-family: 'DM Mono', monospace;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 4px 8px;
  color: var(--text);
  outline: none;
  transition: border-color .12s;
  min-width: 0;
}
.prop-input:focus { border-color: var(--accent); }
.prop-short { max-width: 72px; }
.prop-color {
  width: 36px;
  height: 28px;
  padding: 2px 3px;
  border-radius: 5px;
  cursor: pointer;
  flex: none;
}

/* align buttons */
.align-btns { display: flex; gap: 3px; }
.align-btn {
  width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 5px;
  border: 1px solid var(--border);
  background: var(--bg3);
  cursor: pointer;
  color: var(--text3);
  transition: all .12s;
}
.align-btn svg { fill: currentColor; }
.align-btn:hover { border-color: var(--accent); color: var(--accent); }
.align-btn.active { background: var(--accent-bg); border-color: var(--accent); color: var(--accent); }

/* slider */
.slider-wrap { display: flex; align-items: center; gap: 6px; flex: 1; }
.prop-slider { flex: 1; accent-color: var(--accent); cursor: pointer; }
.slider-val { font-size: 10px; color: var(--text3); min-width: 28px; font-family: 'DM Mono', monospace; }

/* font picker */
.font-picker-wrap { flex: 1; position: relative; }
.font-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-radius: var(--r);
  max-height: 180px;
  overflow-y: auto;
  z-index: 300;
  box-shadow: 0 8px 24px rgba(0,0,0,.15);
}
.font-dropdown.open { display: block; }
.font-option {
  padding: 7px 10px;
  font-size: 12px;
  color: var(--text2);
  cursor: pointer;
  transition: background .1s;
}
.font-option:hover { background: var(--bg3); color: var(--text); }

/* rp actions */
.rp-action {
  width: 100%;
  padding: 8px;
  margin-bottom: 5px;
  font-size: 12px;
  font-family: inherit;
  border-radius: var(--r);
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text2);
  cursor: pointer;
  text-align: left;
  transition: all .15s;
}
.rp-action:hover { background: var(--bg3); color: var(--text); }
.rp-action-danger { color: var(--red) !important; border-color: var(--red) !important; }
.rp-action-danger:hover { background: var(--red-bg) !important; }

/* ─────────────────────────────────────────
   EXPORT MODAL
───────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.55);
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-box {
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-radius: var(--r2);
  width: 780px;
  max-width: 100%;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 32px 80px rgba(0,0,0,.4);
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.modal-title { font-size: 16px; font-weight: 600; }
.modal-close {
  width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--r);
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text2);
  cursor: pointer;
  font-size: 13px;
  transition: all .12s;
}
.modal-close:hover { background: var(--red-bg); color: var(--red); }

.export-tabs {
  display: flex;
  gap: 4px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.etab {
  padding: 5px 16px;
  font-size: 12px;
  font-family: 'DM Mono', monospace;
  border-radius: 5px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text3);
  cursor: pointer;
  transition: all .12s;
}
.etab:hover  { color: var(--text); }
.etab.active { background: var(--accent); color: #fff; border-color: var(--accent); }

.code-wrap {
  flex: 1;
  overflow: auto;
  background: var(--bg);
  margin: 0;
}
.code-wrap pre {
  padding: 20px;
  font-size: 12px;
  line-height: 1.7;
  font-family: 'DM Mono', monospace;
  color: var(--text2);
  white-space: pre;
  tab-size: 2;
}
.code-wrap code { font-family: inherit; }

.modal-actions {
  display: flex;
  gap: 8px;
  padding: 14px 16px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}
.mbtn {
  flex: 1;
  padding: 9px;
  font-size: 13px;
  font-family: inherit;
  font-weight: 500;
  border-radius: var(--r);
  cursor: pointer;
  transition: all .15s;
}
.mbtn-copy { background: transparent; border: 1px solid var(--border2); color: var(--text2); }
.mbtn-copy:hover { background: var(--bg3); color: var(--text); }
.mbtn-zip  { background: var(--accent); border: none; color: #fff; }
.mbtn-zip:hover { background: var(--accent2); }

/* ─────────────────────────────────────────
   TOAST
───────────────────────────────────────── */
#toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg4);
  color: var(--text);
  padding: 9px 18px;
  border-radius: var(--r);
  font-size: 12px;
  font-family: 'DM Mono', monospace;
  border: 1px solid var(--border2);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s;
  z-index: 999;
  white-space: nowrap;
}
#toast.show { opacity: 1; }

/* ─────────────────────────────────────────
   RESPONSIVE
───────────────────────────────────────── */
@media (max-width: 900px) {
  :root { --rpanel-w: 200px; }
}
@media (max-width: 700px) {
  #sidebar-right { display: none; }
  :root { --sidebar-w: 180px; }
}
@media (max-width: 520px) {
  #sidebar-left { display: none; }
}

/* ─────────────────────────────────────────
   INLINE EDITING
───────────────────────────────────────── */
.wc-editable {
  cursor: text !important;
  transition: outline .1s;
}
.wc-editable:hover {
  outline: 1.5px dashed rgba(37, 99, 235, 0.45);
  outline-offset: 2px;
  border-radius: 3px;
}
.wc-editing {
  outline: 2px solid #2563eb !important;
  outline-offset: 3px;
  border-radius: 3px;
  background: rgba(37,99,235,.04) !important;
}

/* ─────────────────────────────────────────
   BLOCK THUMB ICONS — new blocks
───────────────────────────────────────── */
.bt-pricing  { background: linear-gradient(135deg,#8b5cf6 0%,#7c3aed 100%); }
.bt-test     { background: linear-gradient(135deg,#06b6d4 0%,#0891b2 100%); }
.bt-stats    { background: linear-gradient(135deg,#f59e0b 0%,#d97706 100%); }
.bt-team     { background: linear-gradient(135deg,#22c55e 0%,#16a34a 100%); }
.bt-blog     { background: linear-gradient(135deg,#4f8ef7 0%,#2563eb 100%); }
.bt-faq      { background: linear-gradient(135deg,#e879f9 0%,#c026d3 100%); }
.bt-gallery  { background: linear-gradient(135deg,#22c55e 0%,#059669 100%); }
.bt-timeline { background: linear-gradient(135deg,#8b5cf6 0%,#6d28d9 100%); }
.bt-steps    { background: linear-gradient(135deg,#4f8ef7 0%,#1d4ed8 100%); }
.bt-logobar  { background: linear-gradient(135deg,#94a3b8 0%,#64748b 100%); }
.bt-social   { background: linear-gradient(135deg,#06b6d4 0%,#0e7490 100%); }
.bt-divider  { background: linear-gradient(135deg,#94a3b8 0%,#475569 100%); }

/* ─────────────────────────────────────────
   PRICING
───────────────────────────────────────── */
.wc-pricing { background: #f8fafc; padding: 64px 48px; }
.wc-pricing-hd { text-align: center; margin-bottom: 40px; }
.wc-pricing-eye { font-size: 11px; color: #2563eb; font-weight: 600; letter-spacing: .6px; text-transform: uppercase; margin-bottom: 8px; }
.wc-pricing-h2 { font-size: 28px; font-weight: 700; color: #0f172a; letter-spacing: -.5px; margin-bottom: 8px; }
.wc-pricing-sub { font-size: 14px; color: #64748b; }
.wc-pricing-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; align-items: start; }
.wc-pricing-card { background: #fff; border-radius: 14px; padding: 28px; border: 1px solid #f1f5f9; position: relative; }
.wc-pricing-featured { border: 2px solid #2563eb; box-shadow: 0 4px 24px rgba(37,99,235,.12); }
.wc-pricing-badge { display: inline-block; font-size: 10px; font-weight: 700; color: #2563eb; background: #eff6ff; padding: 3px 10px; border-radius: 20px; letter-spacing: .4px; text-transform: uppercase; margin-bottom: 12px; }
.wc-pricing-tier { font-size: 13px; font-weight: 600; color: #64748b; margin-bottom: 8px; text-transform: uppercase; letter-spacing: .4px; }
.wc-pricing-price { font-size: 40px; font-weight: 800; color: #0f172a; letter-spacing: -1px; margin-bottom: 20px; }
.wc-pricing-price span { font-size: 16px; font-weight: 400; color: #94a3b8; }
.wc-pricing-list { list-style: none; margin-bottom: 24px; display: flex; flex-direction: column; gap: 10px; }
.wc-pricing-list li { font-size: 13px; color: #374151; }
.wc-pricing-no { color: #94a3b8; }
.wc-pricing-btn { width: 100%; padding: 11px; border-radius: 8px; font-size: 13px; font-family: inherit; font-weight: 600; cursor: pointer; border: none; transition: all .15s; }
.wc-pricing-btn-primary { background: #2563eb; color: #fff; }
.wc-pricing-btn-primary:hover { background: #1d4ed8; }
.wc-pricing-btn-outline { background: transparent; color: #0f172a; border: 1.5px solid #e2e8f0 !important; }
.wc-pricing-btn-outline:hover { border-color: #2563eb !important; color: #2563eb; }

/* ─────────────────────────────────────────
   TESTIMONIALS
───────────────────────────────────────── */
.wc-testimonials { background: #fff; padding: 64px 48px; }
.wc-test-hd { text-align: center; margin-bottom: 40px; }
.wc-test-eye { font-size: 11px; color: #2563eb; font-weight: 600; letter-spacing: .6px; text-transform: uppercase; margin-bottom: 8px; }
.wc-test-h2 { font-size: 28px; font-weight: 700; color: #0f172a; letter-spacing: -.5px; }
.wc-test-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.wc-test-card { background: #f8fafc; border-radius: 14px; padding: 24px; border: 1px solid #f1f5f9; display: flex; flex-direction: column; gap: 14px; }
.wc-test-stars { color: #f59e0b; font-size: 16px; letter-spacing: 2px; }
.wc-test-quote { font-size: 14px; color: #374151; line-height: 1.7; flex: 1; font-style: italic; }
.wc-test-author { display: flex; align-items: center; gap: 12px; }
.wc-test-avatar { width: 38px; height: 38px; border-radius: 50%; background: #2563eb; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; flex-shrink: 0; }
.wc-test-name { font-size: 13px; font-weight: 600; color: #0f172a; }
.wc-test-role { font-size: 12px; color: #94a3b8; margin-top: 2px; }

/* ─────────────────────────────────────────
   STATS
───────────────────────────────────────── */
.wc-stats { background: #0f172a; padding: 56px 48px; }
.wc-stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.wc-stats-item { text-align: center; }
.wc-stats-num { font-size: 42px; font-weight: 800; color: #fff; letter-spacing: -1px; margin-bottom: 6px; }
.wc-stats-label { font-size: 13px; color: rgba(255,255,255,.45); text-transform: uppercase; letter-spacing: .5px; }

/* ─────────────────────────────────────────
   TEAM
───────────────────────────────────────── */
.wc-team { background: #fff; padding: 64px 48px; }
.wc-team-hd { text-align: center; margin-bottom: 40px; }
.wc-team-eye { font-size: 11px; color: #2563eb; font-weight: 600; letter-spacing: .6px; text-transform: uppercase; margin-bottom: 8px; }
.wc-team-h2 { font-size: 28px; font-weight: 700; color: #0f172a; letter-spacing: -.5px; }
.wc-team-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.wc-team-card { text-align: center; }
.wc-team-avatar { width: 72px; height: 72px; background: #f1f5f9; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 28px; margin: 0 auto 12px; }
.wc-team-name { font-size: 15px; font-weight: 700; color: #0f172a; margin-bottom: 4px; }
.wc-team-role { font-size: 12px; color: #2563eb; font-weight: 600; text-transform: uppercase; letter-spacing: .4px; margin-bottom: 8px; }
.wc-team-bio { font-size: 13px; color: #64748b; line-height: 1.6; }

/* ─────────────────────────────────────────
   BLOG CARDS
───────────────────────────────────────── */
.wc-blog { background: #f8fafc; padding: 64px 48px; }
.wc-blog-hd { text-align: center; margin-bottom: 40px; }
.wc-blog-eye { font-size: 11px; color: #2563eb; font-weight: 600; letter-spacing: .6px; text-transform: uppercase; margin-bottom: 8px; }
.wc-blog-h2 { font-size: 28px; font-weight: 700; color: #0f172a; letter-spacing: -.5px; }
.wc-blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.wc-blog-card { background: #fff; border-radius: 14px; overflow: hidden; border: 1px solid #f1f5f9; }
.wc-blog-img { background: #f1f5f9; height: 160px; display: flex; align-items: center; justify-content: center; font-size: 36px; color: #94a3b8; }
.wc-blog-body { padding: 20px; }
.wc-blog-tag { display: inline-block; font-size: 10px; font-weight: 700; color: #2563eb; background: #eff6ff; padding: 3px 10px; border-radius: 20px; text-transform: uppercase; letter-spacing: .4px; margin-bottom: 10px; }
.wc-blog-title { font-size: 15px; font-weight: 700; color: #0f172a; margin-bottom: 8px; line-height: 1.4; }
.wc-blog-excerpt { font-size: 13px; color: #64748b; line-height: 1.6; margin-bottom: 12px; }
.wc-blog-meta { font-size: 11px; color: #94a3b8; }

/* ─────────────────────────────────────────
   FAQ
───────────────────────────────────────── */
.wc-faq { background: #fff; padding: 64px 48px; }
.wc-faq-hd { text-align: center; margin-bottom: 40px; }
.wc-faq-eye { font-size: 11px; color: #2563eb; font-weight: 600; letter-spacing: .6px; text-transform: uppercase; margin-bottom: 8px; }
.wc-faq-h2 { font-size: 28px; font-weight: 700; color: #0f172a; letter-spacing: -.5px; }
.wc-faq-list { max-width: 720px; margin: 0 auto; display: flex; flex-direction: column; gap: 0; }
.wc-faq-item { border-bottom: 1px solid #f1f5f9; padding: 20px 0; }
.wc-faq-item:first-child { border-top: 1px solid #f1f5f9; }
.wc-faq-q { font-size: 15px; font-weight: 600; color: #0f172a; margin-bottom: 8px; cursor: default; }
.wc-faq-a { font-size: 14px; color: #64748b; line-height: 1.7; }

/* ─────────────────────────────────────────
   GALLERY
───────────────────────────────────────── */
.wc-gallery { background: #fff; padding: 64px 48px; }
.wc-gallery-hd { text-align: center; margin-bottom: 32px; }
.wc-gallery-eye { font-size: 11px; color: #2563eb; font-weight: 600; letter-spacing: .6px; text-transform: uppercase; margin-bottom: 8px; }
.wc-gallery-h2 { font-size: 28px; font-weight: 700; color: #0f172a; letter-spacing: -.5px; }
.wc-gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 180px; gap: 12px; }
.wc-gallery-item { background: #f1f5f9; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 32px; color: #94a3b8; cursor: pointer; transition: opacity .2s; }
.wc-gallery-item:hover { opacity: .85; }
.wc-gallery-tall { grid-row: span 2; }
.wc-gallery-wide { grid-column: span 2; }

/* ─────────────────────────────────────────
   TIMELINE
───────────────────────────────────────── */
.wc-timeline { background: #f8fafc; padding: 64px 48px; }
.wc-timeline-hd { text-align: center; margin-bottom: 40px; }
.wc-timeline-eye { font-size: 11px; color: #2563eb; font-weight: 600; letter-spacing: .6px; text-transform: uppercase; margin-bottom: 8px; }
.wc-timeline-h2 { font-size: 28px; font-weight: 700; color: #0f172a; letter-spacing: -.5px; }
.wc-timeline-list { max-width: 680px; margin: 0 auto; display: flex; flex-direction: column; gap: 0; }
.wc-timeline-item { display: flex; gap: 20px; padding-bottom: 32px; position: relative; }
.wc-timeline-item:last-child { padding-bottom: 0; }
.wc-timeline-item:not(:last-child)::before { content: ''; position: absolute; left: 9px; top: 20px; width: 2px; height: calc(100% - 12px); background: #e2e8f0; }
.wc-timeline-dot { width: 20px; height: 20px; border-radius: 50%; background: #e2e8f0; border: 3px solid #fff; box-shadow: 0 0 0 2px #e2e8f0; flex-shrink: 0; margin-top: 2px; }
.wc-timeline-dot-active { background: #2563eb; box-shadow: 0 0 0 2px #bfdbfe; }
.wc-timeline-content { flex: 1; }
.wc-timeline-year { font-size: 11px; font-weight: 700; color: #2563eb; text-transform: uppercase; letter-spacing: .5px; margin-bottom: 4px; }
.wc-timeline-title { font-size: 16px; font-weight: 700; color: #0f172a; margin-bottom: 6px; }
.wc-timeline-desc { font-size: 13px; color: #64748b; line-height: 1.65; }

/* ─────────────────────────────────────────
   STEPS
───────────────────────────────────────── */
.wc-steps { background: #fff; padding: 64px 48px; }
.wc-steps-hd { text-align: center; margin-bottom: 40px; }
.wc-steps-eye { font-size: 11px; color: #2563eb; font-weight: 600; letter-spacing: .6px; text-transform: uppercase; margin-bottom: 8px; }
.wc-steps-h2 { font-size: 28px; font-weight: 700; color: #0f172a; letter-spacing: -.5px; }
.wc-steps-grid { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; align-items: start; gap: 12px; }
.wc-steps-item { text-align: center; padding: 0 8px; }
.wc-steps-num { font-size: 36px; font-weight: 800; color: #eff6ff; background: #2563eb; width: 56px; height: 56px; border-radius: 14px; display: flex; align-items: center; justify-content: center; margin: 0 auto 14px; font-size: 20px; }
.wc-steps-title { font-size: 15px; font-weight: 700; color: #0f172a; margin-bottom: 8px; }
.wc-steps-desc { font-size: 13px; color: #64748b; line-height: 1.6; }
.wc-steps-connector { font-size: 22px; color: #e2e8f0; padding-top: 16px; align-self: start; }

/* ─────────────────────────────────────────
   LOGO BAR
───────────────────────────────────────── */
.wc-logobar { background: #fff; padding: 40px 48px; border-top: 1px solid #f1f5f9; border-bottom: 1px solid #f1f5f9; text-align: center; }
.wc-logobar-label { font-size: 11px; color: #94a3b8; text-transform: uppercase; letter-spacing: .6px; font-weight: 600; margin-bottom: 20px; }
.wc-logobar-logos { display: flex; align-items: center; justify-content: center; gap: 40px; flex-wrap: wrap; }
.wc-logobar-item { font-size: 14px; font-weight: 700; color: #cbd5e1; letter-spacing: .2px; transition: color .2s; cursor: default; }
.wc-logobar-item:hover { color: #94a3b8; }

/* ─────────────────────────────────────────
   SOCIAL LINKS
───────────────────────────────────────── */
.wc-social { background: #f8fafc; padding: 40px 48px; text-align: center; }
.wc-social-label { font-size: 12px; color: #94a3b8; text-transform: uppercase; letter-spacing: .6px; font-weight: 600; margin-bottom: 16px; }
.wc-social-links { display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap; }
.wc-social-btn { display: inline-flex; align-items: center; gap: 6px; padding: 9px 18px; border-radius: 8px; font-size: 13px; font-weight: 600; color: #374151; background: #fff; border: 1px solid #e2e8f0; text-decoration: none; transition: all .15s; }
.wc-social-btn:hover { border-color: #2563eb; color: #2563eb; }

/* ─────────────────────────────────────────
   DIVIDER / SPACER
───────────────────────────────────────── */
.wc-divider { padding: 24px 48px; background: #fff; }
.wc-divider-line { border-top: 1px solid #e2e8f0; }
