/* Identidad Convierta: Navy profundo #0A0F1D, Navy primario #1E2A4A, Magenta #D6156C (hover #C81264), Inter */
:root {
  --bg: #F8F9FA; --panel: #fff; --tx: #3B4558; --mu: #64748B; --bd: #E2E8F0;
  --ac: #D6156C; --ac-d: #C81264; --navy: #1E2A4A; --navy-deep: #0A0F1D;
  --ok: #1a8f48; --warn: #c27a00; --bad: #d93025;
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0; display: grid; grid-template-columns: 400px 1fr; background: var(--bg); color: var(--tx);
  font: 14px/1.5 Inter, "Segoe UI", Roboto, system-ui, sans-serif;
}
.panel { background: var(--panel); border-right: 1px solid var(--bd); overflow-y: auto; display: flex; flex-direction: column; }
.panel > * { flex-shrink: 0; }
.panel-head {
  padding: 22px 22px 20px; color: #fff; position: relative; overflow: hidden;
  background: radial-gradient(120% 140% at 100% 0%, #D6156C40 0%, transparent 55%), var(--navy-deep);
  border-left: 4px solid var(--ac);
}
.panel-head .logo { display: block; width: 150px; height: auto; margin-bottom: 16px; }
.panel-head h1 { margin: 0; font-size: 1.25rem; color: #fff; letter-spacing: -.01em; }
.panel-head p { margin: 4px 0 0; color: #ffffffb3; }
.step { padding: 16px 22px; border-bottom: 1px solid var(--bd); display: grid; gap: 10px; }
.step h2 { margin: 0; font-size: .95rem; display: flex; align-items: center; gap: 8px; color: var(--navy); }
.step h2 span { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--navy); color: #fff; font-size: .75rem; }
label { display: grid; gap: 4px; font-weight: 600; font-size: .85rem; }
input:not([type=radio]):not([type=checkbox]):not([type=color]), textarea {
  font: inherit; font-weight: 400; padding: 9px 11px; border: 1px solid var(--bd); border-radius: 8px; background: #fbfbfd; width: 100%;
}
textarea { resize: vertical; min-height: 220px; font-family: ui-monospace, Consolas, monospace; font-size: 12.5px; line-height: 1.55; }
input:focus, textarea:focus { outline: none; border-color: var(--ac); box-shadow: 0 0 0 3px #D6156C22; background: #fff; }
.row { display: flex; gap: 14px; align-items: end; }
.row-between { display: flex; justify-content: space-between; gap: 10px; align-items: center; }
.hint { color: var(--mu); }
.link { background: none; border: none; color: var(--ac); font-weight: 700; cursor: pointer; padding: 0; white-space: nowrap; font: inherit; font-weight: 700; }
.help summary { cursor: pointer; color: var(--mu); font-size: .85rem; }
.help ul { margin: 8px 0 0; padding-left: 18px; color: var(--mu); font-size: .82rem; display: grid; gap: 4px; }
code { background: #f0f1f5; padding: 0 4px; border-radius: 4px; font-size: .9em; }
.drop {
  border: 2px dashed var(--bd); border-radius: 12px; padding: 18px; text-align: center; cursor: pointer;
  display: grid; gap: 4px; font-weight: 400; transition: border-color .15s, background .15s;
}
.drop strong { color: var(--navy); }
.drop small { color: var(--mu); }
.drop.over, .drop:hover { border-color: var(--ac); background: #fdf2f7; }
.thumbs { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.thumbs li { display: grid; grid-template-columns: 64px 1fr auto; gap: 10px; align-items: center; padding: 6px; border: 1px solid var(--bd); border-radius: 10px; }
.thumbs img { width: 64px; height: 48px; object-fit: cover; border-radius: 6px; }
.thumbs .tag { font-size: .7rem; font-weight: 700; color: var(--ac); text-transform: uppercase; letter-spacing: .04em; }
.thumbs input { padding: 6px 8px !important; font-size: .8rem; }
.thumbs .acts { display: flex; flex-direction: column; gap: 2px; }
.thumbs button { border: none; background: #f0f1f5; border-radius: 6px; cursor: pointer; padding: 3px 7px; font-size: .78rem; }
.thumbs button:hover { background: #e3e6ec; }
.seg { display: inline-flex; background: #eef0f4; padding: 3px; border-radius: 9px; gap: 2px; width: fit-content; }
.seg label { display: block; cursor: pointer; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label:has(input:checked) { background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.12); color: var(--navy); }
.seg label { padding: 6px 14px; border-radius: 7px; color: var(--mu); font-size: .85rem; }
.seg input:focus-visible + * , .seg label:has(input:focus-visible) { outline: 2px solid var(--ac); }
.color input { width: 48px; height: 36px; border: 1px solid var(--bd); border-radius: 8px; padding: 2px; background: #fff; }
.check { display: flex; align-items: center; gap: 8px; font-weight: 500; }
.checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 5px; font-size: .84rem; }
.checks li { display: flex; gap: 8px; align-items: flex-start; }
.checks .i { flex: none; width: 18px; text-align: center; font-weight: 800; }
.checks .ok .i { color: var(--ok); } .checks .warn .i { color: var(--warn); } .checks .bad .i { color: var(--bad); }
.panel-foot { position: sticky; bottom: 0; background: var(--panel); padding: 14px 22px; border-top: 1px solid var(--bd); margin-top: auto; }
.primary {
  width: 100%; background: var(--ac); color: #fff; border: none; border-radius: 999px; padding: 13px; font: inherit; font-weight: 700;
  font-size: 1rem; cursor: pointer; box-shadow: 0 8px 20px -10px var(--ac); transition: background .15s, transform .15s;
}
.primary:hover { background: var(--ac-d); transform: translateY(-1px); }
.primary:disabled { opacity: .5; cursor: not-allowed; }
.stage { display: flex; flex-direction: column; min-width: 0; height: 100vh; }
.toolbar { display: flex; justify-content: space-between; align-items: center; padding: 10px 18px; border-bottom: 1px solid var(--bd); background: var(--panel); }
.muted { color: var(--mu); font-size: .85rem; }
.frame-wrap { flex: 1; display: flex; justify-content: center; padding: 18px; overflow: auto; }
#preview { width: 100%; height: 100%; border: 1px solid var(--bd); border-radius: 10px; background: #fff; box-shadow: 0 10px 30px -15px rgba(0,0,0,.25); transition: width .25s; }
.frame-wrap.mobile #preview { width: 390px; max-height: 844px; }
@media (max-width: 900px) {
  body { grid-template-columns: 1fr; }
  .stage { height: 80vh; }
}
