/* «Улучшить с Nexo» в редакторе публикаций */
.nexo-label-row{ display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:8px; }
.nexo-label-row label{ margin:0 !important; }
.ed-nexo{
  display:inline-flex; align-items:center; gap:7px; padding:.35rem .9rem .35rem .65rem;
  border-radius:999px; cursor:pointer; font:600 .8rem var(--font-body);
  color:var(--white); background:linear-gradient(120deg, rgba(232,52,42,.22), rgba(232,52,42,.08));
  border:1px solid rgba(232,52,42,.45); transition:border-color .15s ease, background-color .15s ease, transform .15s ease;
}
.ed-nexo:hover:not(:disabled){ border-color:var(--red-hi); transform:translateY(-1px); }
.ed-nexo:disabled{ opacity:.6; cursor:progress; }
.ed-nexo-mark{ width:16px; height:16px; color:var(--red-hi); display:inline-flex; flex-shrink:0; }
.ed-nexo-mark svg{ width:100%; height:100%; }

.nexo-undo{
  display:flex; align-items:center; gap:10px; flex-wrap:wrap; margin-top:10px; padding:10px 14px;
  border-radius:12px; border:1px solid rgba(232,52,42,.3); background:rgba(232,52,42,.07);
  font-size:.83rem; color:var(--grey);
}
.nexo-undo[hidden]{ display:none; }
.nexo-undo.dim{ opacity:.7; }
.nexo-undo button{
  margin-left:auto; background:none; border:0; cursor:pointer; color:var(--red-hi);
  font:600 .82rem var(--font-body); text-decoration:underline; text-underline-offset:3px;
}

.nexo-imp-back{
  position:fixed; inset:0; z-index:600; display:grid; place-items:center; padding:20px;
  background:rgba(5,5,6,.72); backdrop-filter:blur(6px); -webkit-backdrop-filter:blur(6px);
}
.nexo-imp-back[hidden]{ display:none; }
.nexo-imp{
  width:min(760px, 100%); max-height:calc(100vh - 40px); display:flex; flex-direction:column;
  border-radius:22px; background:var(--surface); border:1px solid var(--border); overflow:hidden;
  box-shadow:0 40px 90px -40px rgba(0,0,0,.9); animation:nexo-imp-pop .2s ease;
}
@keyframes nexo-imp-pop{ from{ opacity:0; transform:translateY(10px) scale(.98); } }
.nexo-imp-head{
  display:flex; align-items:center; gap:12px; padding:18px 20px;
  border-bottom:1px solid var(--border-soft);
  background:radial-gradient(120% 140% at 0% 0%, rgba(232,52,42,.14), transparent 60%);
}
.nexo-imp-logo{ width:30px; height:30px; color:var(--red-hi); flex-shrink:0; }
.nexo-imp-logo svg{ width:100%; height:100%; }
.nexo-imp-head b{ display:block; font-family:var(--font-display); font-weight:700; font-size:.98rem; color:var(--white); }
.nexo-imp-head div > span{ display:block; font-family:var(--font-mono); font-size:.72rem; color:var(--grey-dim); margin-top:2px; }
.nexo-imp-x{
  margin-left:auto; width:34px; height:34px; border-radius:50%; cursor:pointer; flex-shrink:0;
  background:transparent; border:1px solid var(--border); color:var(--grey); font-size:1.15rem; line-height:1;
}
.nexo-imp-x:hover{ color:var(--white); border-color:var(--grey-dim); }

.nexo-imp-loading{ padding:46px 30px 40px; text-align:center; }
.nexo-imp-loading b{ display:block; font-family:var(--font-display); font-weight:700; font-size:1.05rem; color:var(--white); margin-top:18px; }
.nexo-imp-loading p{ margin:8px 0 0; font-size:.88rem; color:var(--grey); min-height:1.4em; }
.nexo-imp-orb{
  position:relative; width:64px; height:64px; margin:0 auto; color:var(--red-hi);
  animation:nexo-imp-pulse 1.6s ease-in-out infinite;
}
.nexo-imp-orb svg{ width:100%; height:100%; }
.nexo-imp-orb::before{
  content:""; position:absolute; inset:-26px; border-radius:50%; z-index:-1;
  background:radial-gradient(circle, rgba(232,52,42,.32), transparent 65%);
}
.nexo-imp-orb.err{ animation:none; opacity:.6; }
@keyframes nexo-imp-pulse{ 50%{ transform:scale(1.08) rotate(30deg); } }
.nexo-imp-progress{ width:200px; height:4px; margin:22px auto 0; border-radius:99px; background:var(--surface-2); overflow:hidden; }
.nexo-imp-progress i{ display:block; width:40%; height:100%; border-radius:99px; background:var(--red); animation:nexo-imp-bar 1.4s ease-in-out infinite; }
@keyframes nexo-imp-bar{ 0%{ transform:translateX(-100%); } 100%{ transform:translateX(250%); } }

.nexo-imp-body{ padding:18px 20px 6px; overflow-y:auto; }
.nexo-imp-label{ font-family:var(--font-mono); font-size:.7rem; color:var(--grey-dim); text-transform:uppercase; letter-spacing:.04em; }
.nexo-imp-title{ font-family:var(--font-display); font-weight:700; font-size:1.1rem; color:var(--white); margin:6px 0 16px; line-height:1.35; }
.nexo-imp-tabs{ display:inline-flex; gap:4px; padding:3px; border:1px solid var(--border); border-radius:999px; margin-bottom:12px; }
.nexo-imp-tabs button{ padding:.35rem .9rem; border-radius:999px; border:0; background:transparent; color:var(--grey); font:600 .78rem var(--font-body); cursor:pointer; }
.nexo-imp-tabs button.on{ background:var(--red); color:#120503; }
.nexo-imp-view{
  border:1px solid var(--border); border-radius:14px; background:var(--black); padding:16px 18px;
  max-height:46vh; overflow-y:auto;
}
.nexo-imp-view .post-body{ font-size:.92rem; }
.nexo-imp-markup{
  margin:0; white-space:pre-wrap; word-break:break-word; font-family:var(--font-mono); font-size:.8rem;
  line-height:1.6; color:var(--grey);
}
.nexo-imp-tips{
  margin:14px 0 8px; padding:12px 14px; border-radius:12px; border:1px solid rgba(245,197,66,.35); background:rgba(245,197,66,.07);
}
.nexo-imp-tips b{ display:block; font-size:.84rem; color:var(--white); margin-bottom:6px; }
.nexo-imp-tips ul{ list-style:disc; margin:0 0 6px; padding-left:18px; font-size:.84rem; color:var(--grey); }
.nexo-imp-tips li{ margin:2px 0; }
.nexo-imp-tips span{ font-size:.75rem; color:var(--grey-dim); }
.nexo-imp-actions{ display:flex; gap:10px; align-items:center; flex-wrap:wrap; padding:14px 20px 18px; border-top:1px solid var(--border-soft); }
.nexo-imp-loading .nexo-imp-actions{ border-top:0; padding:22px 0 0; }

.nexo-imp-flash{
  position:fixed; left:50%; bottom:28px; transform:translateX(-50%); z-index:700; max-width:calc(100vw - 32px);
  padding:11px 18px; border-radius:12px; background:var(--surface-2); border:1px solid var(--border);
  color:var(--white); font-size:.86rem; box-shadow:0 18px 40px -20px rgba(0,0,0,.8);
}
.nexo-imp-flash[hidden]{ display:none; }

@media (max-width: 620px){
  .nexo-imp-back{ padding:0; align-items:end; }
  .nexo-imp{ border-radius:22px 22px 0 0; max-height:94vh; }
  .nexo-imp-actions .btn{ flex:1; justify-content:center; }
  .nexo-imp-actions > span{ display:none; }
}
