/* ============================================================
   Secure Manager — محتوای غنی (.sm-prose)
   استفاده در سایت عمومی و داخل ویرایشگر پنل (WYSIWYG)
   ============================================================ */
.sm-prose{
  --sm-base:17px;
  --sm-o:var(--orange,#ff5a00);
  --sm-o2:var(--orange2,#ff7a18);
  --sm-panel:var(--panel,#07111a);
  --sm-panel2:var(--panel2,#091722);
  --sm-line:var(--line,#17232e);
  --sm-white:var(--white,#f4f5f6);
  --sm-muted:var(--muted,#a6adb5);
  direction:rtl;text-align:right;
  color:#d3d8de;
  font-family:'Vazirmatn','Vazir',Tahoma,Arial,sans-serif;
  font-size:var(--sm-base);font-weight:400;line-height:2.05;
  overflow-wrap:anywhere;word-break:normal;
}
.sm-prose::after{content:"";display:block;clear:both}
.sm-prose>*:first-child{margin-top:0}
.sm-prose p{margin:0 0 1.1em}
.sm-prose strong,.sm-prose b{color:var(--sm-white);font-weight:700}
.sm-prose em,.sm-prose i{font-style:italic}
.sm-prose u{text-underline-offset:.2em}
.sm-prose s{opacity:.8}
.sm-prose a{color:var(--sm-o2);text-decoration:underline;text-decoration-color:rgba(255,90,0,.45);text-underline-offset:.22em;transition:.2s}
.sm-prose a:hover{color:#fff;text-decoration-color:var(--sm-o)}

/* تیترها */
.sm-prose h2,.sm-prose h3,.sm-prose h4{color:var(--sm-white);font-weight:800;line-height:1.7;margin:1.8em 0 .6em;clear:both}
.sm-prose h2{font-size:1.65em;padding-right:.7em;position:relative}
.sm-prose h2::before{content:"";position:absolute;right:0;top:.28em;bottom:.28em;width:4px;border-radius:4px;background:linear-gradient(180deg,#ff5400,#ff9b50);box-shadow:0 0 12px rgba(255,90,0,.45)}
.sm-prose h3{font-size:1.32em}
.sm-prose h4{font-size:1.1em;color:var(--sm-o2)}

/* لیست‌ها */
.sm-prose ul,.sm-prose ol{margin:0 0 1.2em;padding:0 1.6em 0 0}
.sm-prose li{margin:.25em 0}
.sm-prose li>p{margin:0}
.sm-prose li::marker{color:var(--sm-o);font-weight:700}
.sm-prose ul ul,.sm-prose ol ol,.sm-prose ul ol,.sm-prose ol ul{margin:.3em 0}

/* نقل‌قول */
.sm-prose blockquote{margin:1.6em 0;padding:1em 1.4em;border-right:4px solid var(--sm-o);border-radius:14px;background:linear-gradient(270deg,rgba(255,90,0,.09),rgba(7,17,26,.6));color:#e4e8ec;font-size:1.04em}
.sm-prose blockquote>*:last-child{margin-bottom:0}
.sm-prose blockquote>p{margin-bottom:.6em}

/* جداکننده */
.sm-prose hr{border:0;height:1px;margin:2.4em 0;background:linear-gradient(90deg,transparent,rgba(255,90,0,.6),transparent)}

/* کد */
.sm-prose code{font-family:Consolas,'Courier New',monospace;font-size:.88em;background:rgba(255,255,255,.08);padding:.12em .45em;border-radius:6px;direction:ltr;unicode-bidi:isolate;color:#ffd2b3}
.sm-prose pre{direction:ltr;text-align:left;background:#02070c;border:1px solid var(--sm-line);border-radius:14px;padding:1.1em 1.3em;margin:1.5em 0;overflow:auto;line-height:1.8;font-size:.9em}
.sm-prose pre code{background:none;padding:0;color:#dfe6ec;font-size:1em;white-space:pre}

/* تصویر */
.sm-prose img{max-width:100%;height:auto;border-radius:14px}
.sm-prose figure.sm-img{display:table;margin:1.7em auto;max-width:100%;text-align:center}
.sm-prose figure.sm-img img{display:block;margin:0 auto;border:1px solid var(--sm-line);box-shadow:0 14px 40px rgba(0,0,0,.35)}
.sm-prose figure.sm-img figcaption{display:table-caption;caption-side:bottom;padding-top:.7em;font-size:.82em;line-height:1.8;color:var(--sm-muted);text-align:center}
.sm-prose .sm-align-center{display:table;margin-left:auto;margin-right:auto;float:none}
.sm-prose .sm-align-full{display:block!important;width:100%!important;max-width:100%!important;float:none;margin:1.7em 0}
.sm-prose .sm-align-full img{width:100%}
.sm-prose .sm-align-right{float:right;margin:.4em 0 1em 1.6em;max-width:50%}
.sm-prose .sm-align-left{float:left;margin:.4em 1.6em 1em 0;max-width:50%}
.sm-prose figure.sm-img[class*="sm-w-"]{display:block}
.sm-prose figure.sm-img[class*="sm-w-"] img{width:100%}
.sm-prose .sm-w-25{width:25%;max-width:25%}
.sm-prose .sm-w-50{width:50%;max-width:50%}
.sm-prose .sm-w-75{width:75%;max-width:75%}
.sm-prose .sm-w-100{width:100%;max-width:100%}
.sm-prose figure.sm-img[class*="sm-w-"].sm-align-center{margin-left:auto;margin-right:auto}

/* ویدیو */
.sm-prose .sm-embed{position:relative;aspect-ratio:16/9;margin:1.8em 0;border-radius:16px;overflow:hidden;border:1px solid rgba(255,90,0,.3);background:#02070c;box-shadow:0 18px 50px rgba(0,0,0,.4);clear:both}
.sm-prose .sm-embed iframe{position:absolute;inset:0;width:100%;height:100%;border:0}

/* جدول */
.sm-prose .sm-table-wrap{overflow-x:auto;margin:1.6em 0;border:1px solid var(--sm-line);border-radius:14px;background:var(--sm-panel);clear:both}
.sm-prose table.sm-table,.sm-prose table{width:100%;border-collapse:collapse;min-width:480px;font-size:.92em;line-height:1.8}
.sm-prose .sm-table th,.sm-prose .sm-table td{padding:.7em 1em;border:1px solid var(--sm-line);text-align:right;vertical-align:top;min-width:60px}
.sm-prose .sm-table th{background:var(--sm-panel2);color:var(--sm-o2);font-weight:700;border-bottom:2px solid rgba(255,90,0,.5)}
.sm-prose .sm-table tbody tr:nth-child(even) td{background:rgba(255,255,255,.02)}
.sm-prose .sm-table tr>*:first-child{border-right:0}
.sm-prose .sm-table tr>*:last-child{border-left:0}
.sm-prose .sm-table tr:first-child>*{border-top:0}
.sm-prose .sm-table tr:last-child>*{border-bottom:0}

/* باکس هشدار / نکته */
.sm-prose .sm-callout{--c:59,158,255;margin:1.6em 0;padding:1em 1.3em;border-radius:14px;border:1px solid rgba(var(--c),.35);border-right:4px solid rgb(var(--c));background:rgba(var(--c),.09);color:#e6eaee;clear:both}
.sm-prose .sm-callout>*:last-child{margin-bottom:0}
.sm-prose .sm-callout>*:first-child{margin-top:0}
.sm-prose .sm-callout-info{--c:59,158,255}
.sm-prose .sm-callout-warning{--c:255,176,32}
.sm-prose .sm-callout-success{--c:46,204,113}
.sm-prose .sm-callout-danger{--c:255,77,79}

/* ستون‌ها */
.sm-prose .sm-cols{display:grid;gap:1.6em;margin:1.6em 0;clear:both;align-items:start}
.sm-prose .sm-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}
.sm-prose .sm-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}
.sm-prose .sm-col{min-width:0;padding:.2em 0}
.sm-prose .sm-col>*:first-child{margin-top:0}
.sm-prose .sm-col>*:last-child{margin-bottom:0}

/* آکاردئون */
.sm-prose details.sm-details{margin:1.2em 0;border:1px solid var(--sm-line);border-radius:14px;background:var(--sm-panel);overflow:hidden;clear:both}
.sm-prose .sm-details>summary{cursor:pointer;padding:.85em 1.2em;font-weight:700;color:var(--sm-white);list-style:none;position:relative;padding-left:2.4em}
.sm-prose .sm-details>summary::-webkit-details-marker{display:none}
.sm-prose .sm-details>summary::after{content:"+";position:absolute;left:1em;top:50%;transform:translateY(-50%);color:var(--sm-o);font-size:1.3em;font-weight:400}
.sm-prose .sm-details[open]>summary::after{content:"−"}
.sm-prose .sm-details[open]>summary{border-bottom:1px solid var(--sm-line)}
.sm-prose .sm-details>div{padding:1em 1.2em}
.sm-prose .sm-details>div>*:last-child{margin-bottom:0}

/* دکمه */
.sm-prose a.sm-btn{display:inline-flex;align-items:center;justify-content:center;gap:10px;padding:.7em 1.8em;border-radius:11px;background:linear-gradient(120deg,#ff5400,#ff741b);color:#fff;font-size:.82em;font-weight:500;text-decoration:none;box-shadow:0 10px 30px rgba(255,75,0,.18);transition:.25s;margin:.3em 0}
.sm-prose a.sm-btn:hover{transform:translateY(-2px);box-shadow:0 0 27px rgba(255,78,0,.3);color:#fff}

/* اندازه‌ی متن (مطلق نسبت به پایه، بدون انباشت) */
.sm-prose .sm-fs-small{font-size:calc(var(--sm-base)*.82)}
.sm-prose .sm-fs-normal{font-size:var(--sm-base)}
.sm-prose .sm-fs-large{font-size:calc(var(--sm-base)*1.3)}
.sm-prose .sm-fs-xlarge{font-size:calc(var(--sm-base)*1.7);line-height:1.6}

/* ریسپانسیو */
@media(max-width:760px){
  .sm-prose{--sm-base:15.5px;line-height:2}
  .sm-prose .sm-cols-2,.sm-prose .sm-cols-3{grid-template-columns:1fr;gap:1em}
  .sm-prose .sm-align-right,.sm-prose .sm-align-left{float:none;display:table;margin:1.4em auto;max-width:100%}
  .sm-prose figure.sm-img[class*="sm-w-"]{width:100%;max-width:100%}
  .sm-prose h2{font-size:1.45em}
  .sm-prose blockquote{padding:.9em 1.1em}
}
