/* ─────────────────────────────────────────────────────────────
   مقاله‌ها — روی همان توکن‌های landing.css سوار می‌شود.
   هیچ رنگ یا اندازهٔ پایه‌ای اینجا بازتعریف نمی‌شود؛ عوض‌کردن
   توکن برند در landing.css باید خودکار به این صفحه هم برسد.
   ───────────────────────────────────────────────────────────── */

/* ─── سربرگ مقاله ───
   padding-block و نه padding: این عنصر هم‌زمان .lp-container است و
   نوشتن padding کوتاه، فاصلهٔ افقی ۲۶px کانتینر را صفر می‌کرد. */
.art-head{padding-block:26px 0}
.art-crumbs{display:flex;align-items:center;gap:8px;flex-wrap:wrap;font-size:12px;color:var(--muted);margin-bottom:22px}
.art-crumbs a{color:var(--muted);transition:color .15s}
.art-crumbs a:hover{color:var(--grn-d)}
.art-crumbs span.sep{opacity:.5}
.art-crumbs [aria-current]{color:var(--grn-d);font-weight:700}

.art-preview-note{display:flex;align-items:flex-start;gap:9px;margin-bottom:16px;padding:10px 14px;
    font-size:12px;font-weight:700;line-height:1.9;color:var(--gold-d);
    background:var(--gold-s);border:1px dashed var(--gold-l);border-radius:10px}
.art-preview-note svg.ic{width:16px;height:16px;flex:0 0 auto;margin-top:.3em}
.art-preview-note span{min-width:0}

.art-cat{display:inline-flex;align-items:center;gap:7px;font-size:11px;font-weight:800;letter-spacing:.02em;
    padding:5px 13px;border-radius:99px;color:var(--grn);background:var(--grn-s);border:1px solid var(--grn-l)}

.art-title{font-family:var(--fd);font-weight:400;font-size:clamp(29px,4.2vw,46px);line-height:1.35;
    color:var(--grn-d);margin:16px 0 0;letter-spacing:-.01em;max-width:900px}
.art-lead{font-size:17px;line-height:1.95;color:var(--muted);max-width:760px;margin-top:14px;margin-bottom:0}

.art-meta{display:flex;align-items:center;gap:8px 18px;flex-wrap:wrap;margin:22px 0 0;
    padding-block:14px;border-top:1px dashed var(--line);border-bottom:1px dashed var(--line);font-size:12.5px;color:var(--muted)}
.art-meta i{display:inline-flex;align-items:center;gap:6px;font-style:normal}
.art-meta svg.ic{width:15px;height:15px;color:var(--gold-d)}
.art-meta b{color:var(--grn-d);font-weight:700}

/* سالِ گذشته — فقط وقتی مقاله از سال جاری عقب‌تر است نمایش داده می‌شود. */
.art-year-note{display:flex;align-items:flex-start;gap:11px;margin-top:16px;padding:13px 16px;
    border-radius:12px;background:var(--gold-s);border:1px solid var(--gold-l);color:#5c4a1f;
    font-size:13px;line-height:1.95}
.art-year-note > svg.ic{width:17px;height:17px;flex:0 0 auto;margin-top:.32em;color:var(--gold-d)}
.art-year-note > div{min-width:0}
.art-year-note b{display:block;color:var(--gold-d);font-weight:800;margin-bottom:2px}
.art-year-note p{margin:0}
.art-year-note a{color:var(--gold-d);font-weight:700;border-bottom:1px solid var(--gold-l)}
.art-year-note a:hover{border-bottom-color:var(--gold-d)}
.dot-sep{display:inline-block;width:4px;height:4px;border-radius:50%;background:var(--line3)}

/* ─── تصویر شاخص ─── */
.art-cover{margin:26px 0 0;border-radius:18px;overflow:hidden;border:1px solid var(--line);
    box-shadow:var(--sh-3);background:var(--card)}
.art-cover img{display:block;width:100%;height:auto;aspect-ratio:16/9;object-fit:cover}

/* ─── چیدمان: فهرست چسبان + متن ─── */
.art-layout{display:grid;grid-template-columns:236px minmax(0,1fr);gap:36px;align-items:start;
    padding-block:34px 8px}
.art-side{position:sticky;top:96px}
.art-toc{background:linear-gradient(180deg,var(--card),var(--card2));border:1px solid var(--line);
    border-radius:15px;padding:16px 18px;box-shadow:var(--sh-1)}
.art-toc h2{font-family:var(--ff);font-size:11.5px;font-weight:800;letter-spacing:.04em;color:var(--faint);
    margin:0 0 12px}
.art-toc ol{list-style:none;margin:0;padding:0;counter-reset:toc;display:grid;gap:2px}
.art-toc li{counter-increment:toc}
.art-toc a{display:block;font-size:12.5px;font-weight:600;color:var(--muted);padding:7px 10px;border-radius:8px;
    line-height:1.7;transition:.15s}
.art-toc a::before{content:counter(toc) ". ";color:var(--gold-d);font-weight:800}
.art-toc a:hover{background:var(--grn-s);color:var(--grn-d)}

.art-side-note{margin-top:14px;padding:14px 16px;border-radius:14px;background:var(--grn-dd);color:#cfe0d6;
    font-size:11.5px;line-height:1.9;position:relative;overflow:hidden}
.art-side-note::after{content:"";position:absolute;inset-inline:0;bottom:0;height:3px;
    background:linear-gradient(90deg,transparent,var(--gold-b),transparent)}
.art-side-note b{display:block;color:#fff;font-family:var(--fd);font-weight:400;font-size:16px;margin-bottom:6px}
.art-side-note a{color:var(--gold-b);font-weight:700;border-bottom:1px solid rgba(240,200,106,.4)}

/* ─── بدنهٔ مقاله ─── */
.art-body{font-size:16px;line-height:2.05;color:var(--ink);max-width:800px}
.art-body > * + *{margin-top:18px}
.art-body h2{font-family:var(--fd);font-weight:400;font-size:clamp(22px,2.6vw,29px);line-height:1.5;
    color:var(--grn-d);margin:44px 0 0;padding-top:22px;border-top:1px solid var(--line2);scroll-margin-top:100px}
.art-body h2:first-child{margin-top:0;padding-top:0;border-top:0}
.art-body h2::before{content:"";display:inline-block;width:9px;height:9px;border-radius:50%;
    background:var(--gold-b);box-shadow:0 0 0 4px rgba(169,118,9,.14);margin-inline-end:12px;vertical-align:middle}
.art-body h3{font-size:16.5px;font-weight:800;color:var(--grn-d);margin:30px 0 0;line-height:1.75}
.art-body p{margin:0}
.art-body strong{color:var(--grn-d);font-weight:800}
/* لینکِ درون متن. دکمه‌های داخل مقاله از این قاعده مستثنا هستند: دکمه هم
   <a> است و اگر رنگ لینک و خطِ طلاییِ زیرش را بگیرد، متنش روی قرمز تیره
   می‌شود و زیرش یک خط زرد می‌افتد؛ همان دکمهٔ خرابی که دیده شد. */
.art-body a:not(.btn){color:var(--grn);font-weight:700;border-bottom:1.5px solid var(--gold-l);transition:.15s}
.art-body a:not(.btn):hover{color:var(--grn-d);border-bottom-color:var(--gold)}
.art-body ul,.art-body ol{margin:0;padding-inline-start:0;list-style:none;display:grid;gap:9px}
.art-body ul li{position:relative;padding-inline-start:26px}
.art-body ul li::before{content:"";position:absolute;inset-inline-start:4px;top:.82em;width:7px;height:7px;
    border-radius:2px;background:var(--gold-b);transform:rotate(45deg)}
.art-body ol{counter-reset:art-ol}
.art-body ol li{position:relative;padding-inline-start:32px;counter-increment:art-ol}
.art-body ol li::before{content:counter(art-ol);position:absolute;inset-inline-start:0;top:.28em;width:22px;height:22px;
    display:grid;place-items:center;border-radius:7px;background:var(--grn-s);color:var(--grn);
    font-size:11.5px;font-weight:800;font-family:var(--ff)}
.art-body blockquote{margin:26px 0;padding:18px 22px;border-radius:14px;
    border-inline-start:4px solid var(--gold-b);background:var(--gold-s);color:#5c4a1f;font-size:14.5px;line-height:2}
.art-body blockquote p{margin:0}
.art-body code{background:var(--bg3);border:1px solid var(--line);border-radius:6px;padding:1px 6px;
    font:12.5px/1.8 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;direction:ltr;unicode-bidi:isolate}
.art-body hr{border:0;border-top:1px dashed var(--line);margin:30px 0}

/* A table wider than the article scrolls sideways instead of squeezing: data cells stay on one line. */
.art-table-scroll{overflow-x:auto;-webkit-overflow-scrolling:touch}
.art-body > .art-table-scroll th,.art-body > .art-table-scroll td,.art-table th,.art-table td{white-space:nowrap}

/* جدول سادهٔ Markdown داخل متن.
   فقط فرزند مستقیم: جدول‌های داخل :::calc و :::legal-table استایل خودشان را دارند. */
.art-body > .art-table-scroll{margin:26px 0;background:var(--card);border:1px solid var(--line);border-radius:14px;
    box-shadow:var(--sh-1)}
.art-body > .art-table-scroll > table{width:100%;border-collapse:collapse;font-size:13.5px}
.art-body > .art-table-scroll > table thead th{font-size:11.5px;font-weight:800;color:var(--faint);background:var(--card2);
    text-align:start;padding:11px 16px;border-bottom:1px solid var(--line2)}
.art-body > .art-table-scroll > table tbody td{padding:11px 16px;border-bottom:1px solid var(--line2);color:var(--ink)}
.art-body > .art-table-scroll > table tbody tr:last-child td{border-bottom:0}
.art-body > .art-table-scroll > table tbody tr:hover{background:var(--bg2)}

/* ─── جدول تولیدشده از دادهٔ قانونی ─── */
.art-table-wrap{margin:26px 0;border:1px solid var(--line);border-radius:15px;overflow:hidden;background:var(--card);
    box-shadow:var(--sh-2)}
.art-table-head{display:flex;align-items:center;gap:10px;padding:13px 18px;background:var(--grn-dd);color:#eaf3ee;flex-wrap:wrap}
.art-table-head svg.ic{width:17px;height:17px;color:var(--gold-b)}
.art-table-head b{font-family:var(--fd);font-weight:400;font-size:16px}
.art-table-head span{margin-inline-start:auto;font-size:11px;color:#a6c1b6}
.art-table{width:100%;border-collapse:collapse;font-size:13.5px}
.art-table th,.art-table td{padding:12px 18px;text-align:start;border-bottom:1px solid var(--line2)}
.art-table thead th{font-size:11.5px;font-weight:800;color:var(--faint);background:var(--card2);letter-spacing:.02em}
.art-table tbody tr:last-child td{border-bottom:0}
.art-table tbody tr:hover{background:var(--bg2)}
.art-table td.val{font-weight:800;color:var(--grn-d);font-variant-numeric:tabular-nums;white-space:nowrap}
.art-table td.src{font-size:11.5px;color:var(--faint);line-height:1.8}
.art-table-note{padding:12px 18px;background:var(--card2);border-top:1px dashed var(--line);font-size:11.5px;color:var(--faint)}
.art-table-note p{margin:0}

/* ─── کال‌اوت‌ها ─── */
.art-callout{display:flex;gap:14px;margin:26px 0;padding:16px 18px;border-radius:14px;border:1px solid var(--line);
    background:var(--card);font-size:14px;line-height:1.95;box-shadow:var(--sh-1)}
.art-callout .a-ic{flex:0 0 auto;width:36px;height:36px;border-radius:11px;display:grid;place-items:center;
    background:var(--blu-s);color:var(--blu)}
.art-callout .a-ic svg.ic{width:19px;height:19px}
.art-callout h4{margin:0 0 4px;font-size:13.5px;font-weight:800;color:var(--grn-d)}
.art-callout .a-body p{margin:0;color:var(--muted)}
.art-callout .a-body > * + *{margin-top:8px}
.art-callout.warn{background:var(--red-s);border-color:var(--red-l)}
.art-callout.warn .a-ic{background:#f6d9d1;color:var(--red)}
.art-callout.warn h4{color:var(--red)}
.art-callout.warn .a-body p{color:#7c3226}
.art-callout.tip{background:var(--grn-s);border-color:var(--grn-l)}
.art-callout.tip .a-ic{background:#d3e6db;color:var(--grn)}
.art-callout.tip h4{color:var(--grn)}
.art-callout.tip .a-body p{color:#2c5147}

/* ─── گام‌ها ─── */
.art-steps{margin:26px 0;padding:18px 20px;border-radius:15px;border:1px solid var(--line);
    background:linear-gradient(180deg,var(--card),var(--card2));box-shadow:var(--sh-1)}
.art-steps ol{margin:0}

/* ─── جعبهٔ محاسبه ─── */
.art-calc{margin:26px 0;border:1px solid var(--line);border-radius:15px;overflow:hidden;background:var(--card);
    box-shadow:var(--sh-2)}
.art-calc-h{display:flex;align-items:center;gap:9px;padding:12px 18px;border-bottom:1px solid var(--line2);
    background:var(--card2);font-size:12.5px;font-weight:800;color:var(--grn-d)}
.art-calc-h svg.ic{width:16px;height:16px;color:var(--gold-d)}
.art-calc-b{padding:6px 18px 14px}
.art-calc-b table{width:100%;border-collapse:collapse;margin:0}
.art-calc-b thead{display:none}
.art-calc-b td{padding:10px 0;border-bottom:1px dashed var(--line2);font-size:13px;color:var(--muted)}
.art-calc-b td:last-child{text-align:end;font-weight:800;color:var(--grn-d);font-variant-numeric:tabular-nums;white-space:nowrap}
.art-calc-b tr:last-child td{border-bottom:0;padding-top:14px}
.art-calc-b tr:last-child td:first-child{font-weight:800;color:var(--grn-d)}
.art-calc-b tr:last-child td:last-child{font-size:16px;color:var(--gold-d)}

/* ─── تصویر داخل متن ─── */
.art-figure{margin:30px 0;border:1px solid var(--line);border-radius:15px;overflow:hidden;background:var(--card);
    box-shadow:var(--sh-2)}
.art-figure img{display:block;width:100%;height:auto}
.art-figure figcaption{font-size:11.5px;color:var(--faint);padding:9px 16px;border-top:1px solid var(--line2);background:var(--card2)}

/* ─── فراخوان داخل مقاله ─── */
.art-cta{display:flex;align-items:center;gap:18px;flex-wrap:wrap;margin:30px 0;padding:20px 22px;border-radius:16px;
    background:var(--grn-dd);color:#eaf3ee;position:relative;overflow:hidden}
.art-cta::after{content:"";position:absolute;inset-inline:0;bottom:0;height:3px;
    background:linear-gradient(90deg,transparent,var(--gold-b),transparent)}
.art-cta-copy{flex:1 1 260px;min-width:0}
.art-cta b{display:block;font-family:var(--fd);font-weight:400;font-size:19px;color:#fff;margin-bottom:4px}
.art-cta-body p{margin:0;font-size:13.5px;line-height:1.95;color:#b9cec2}

/* دکمهٔ فراخوان داخل مقاله.
   رنگ، وزن و اندازه صریح نوشته شده‌اند تا از کارت ارث نبرد: روی زمینهٔ سبز تیره،
   هر رنگی که به ارث برسد یا محو می‌شود یا با متن روشن یکی می‌شود و دکمه خالی به نظر
   می‌رسد. flex:0 0 auto هم مانع می‌شود در ردیفِ flex به عرض صفر فشرده شود. */
.art-cta-btn{flex:0 0 auto;display:inline-flex;align-items:center;justify-content:center;gap:8px;
    padding:11px 20px;border-radius:11px;border:1px solid rgba(255,255,255,.18);
    background:var(--red);color:#fff;font:800 13.5px/1.15 var(--ff);white-space:nowrap;
    box-shadow:0 12px 24px -12px rgba(178,58,40,.85);transition:.2s}
.art-cta-btn:hover{filter:brightness(.94);transform:translateY(-1px)}
.art-cta-btn svg.ic{width:15px;height:15px;stroke-width:2.2;color:currentColor}

/* ─── برچسب‌ها ─── */
.art-tags{display:flex;gap:8px;flex-wrap:wrap;margin-top:34px;padding-top:22px;border-top:1px solid var(--line2)}
.art-tag{font-size:11.5px;font-weight:700;color:var(--muted);background:var(--bg3);border:1px solid var(--line);
    padding:6px 12px;border-radius:99px}

/* ─── جعبهٔ نویسنده ─── */
.art-author{display:flex;gap:16px;align-items:flex-start;margin:36px 0 0;padding:20px 22px;border-radius:16px;
    background:linear-gradient(180deg,var(--card),var(--card2));border:1px solid var(--line);box-shadow:var(--sh-1)}
.art-author .av{flex:0 0 auto;width:54px;height:54px;border-radius:16px;display:grid;place-items:center;
    background:linear-gradient(140deg,#0e3830,#1a5a4b);color:var(--gold-b);font-family:var(--fd);font-size:23px;
    border:1px solid rgba(255,255,255,.14)}
.art-author h3{margin:0;font-size:14px;font-weight:800;color:var(--grn-d)}
.art-author p{margin:6px 0 0;font-size:12.5px;color:var(--muted);line-height:1.9}

/* ─── بخش مقالات در صفحهٔ اصلی ─── */
.home-articles-more{display:flex;justify-content:center;margin-top:26px}
.home-articles-more .btn svg.ic{transform:scaleX(-1)}

/* ─── کارت پیش‌نویس (فقط نمایش محلی) ─── */
.art-card.is-draft{border-style:dashed;border-color:var(--gold-l);background:var(--gold-s)}
.art-card.is-draft .cc{color:var(--gold-d)}
.art-year-drafts{margin-bottom:38px}

/* ─── مقالات مرتبط ─── */
.art-related{padding-block:44px 0}
.art-related > h2{margin:0 0 6px;font-family:var(--fd);font-weight:400;
    font-size:clamp(22px,2.6vw,30px);color:var(--grn-d);line-height:1.4}
.art-related > p{margin:0 0 24px;color:var(--muted);font-size:13.5px}
.art-related .art-cards{margin-top:0}

/* ─── فهرست مقاله‌ها ─── */
.art-list{padding-block:38px 10px}
.art-year + .art-year{margin-top:44px}
.art-year-head{display:flex;align-items:baseline;gap:12px;flex-wrap:wrap;margin-bottom:18px;
    padding-bottom:12px;border-bottom:1px dashed var(--line)}
.art-year-head h2{margin:0;font-family:var(--fd);font-weight:400;font-size:clamp(21px,2.4vw,27px);color:var(--grn-d)}
.art-year-head span{font-size:11.5px;color:var(--faint);font-weight:700}

.art-cards{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}
.art-card{display:flex;flex-direction:column;gap:10px;padding:18px;border-radius:15px;background:var(--card);
    border:1px solid var(--line);box-shadow:var(--sh-1);transition:.2s cubic-bezier(.2,.9,.3,1.1);height:100%}
.art-card:hover{transform:translateY(-3px);border-color:var(--grn-l);box-shadow:var(--sh-2)}
.art-card .cc{font-size:10.5px;font-weight:800;color:var(--gold-d)}
.art-card h3{margin:0;font-size:14px;font-weight:800;color:var(--grn-d);line-height:1.75}
.art-card p{margin:0;font-size:12px;color:var(--muted);line-height:1.85}
.art-card .cm{margin-top:auto;font-size:10.5px;color:var(--faint);display:flex;gap:8px;align-items:center;flex-wrap:wrap}

.art-empty{display:flex;gap:16px;align-items:flex-start;padding:24px;border-radius:16px;
    background:var(--card);border:1px dashed var(--line3)}
.art-empty .a-ic{flex:0 0 auto;width:44px;height:44px;border-radius:13px;display:grid;place-items:center;
    background:var(--gold-s);color:var(--gold-d)}
.art-empty .a-ic svg.ic{width:21px;height:21px}
.art-empty h2{margin:0 0 6px;font-size:16px;font-weight:800;color:var(--grn-d)}
.art-empty p{margin:0 0 14px;font-size:13px;color:var(--muted);line-height:1.9}

/* ─── ۴۰۴ ─── */
.art-not-found{max-width:640px;padding-block:26px 10px}
.nf-code{display:block;font-family:var(--fd);font-size:clamp(46px,9vw,84px);line-height:1;
    color:var(--gold-l);letter-spacing:-.03em;margin-bottom:8px}
.nf-actions{display:flex;gap:12px;flex-wrap:wrap;margin-top:24px}

/* ─── پاسخ‌گو ─── */
@media (max-width:980px){
    .art-layout{grid-template-columns:minmax(0,1fr);gap:26px}
    .art-side{position:static;order:-1}
    .art-toc ol{grid-template-columns:1fr 1fr}
    .art-cards{grid-template-columns:1fr}
    .art-cta{flex-direction:column;align-items:flex-start}
    .art-cta-copy{flex:0 0 auto}   /* in a column the 260px basis would become a minimum height */
}
@media (max-width:640px){
    .art-toc ol{grid-template-columns:1fr}
    .art-body{font-size:15px;line-height:2}
    .art-table th,.art-table td{padding:10px 13px}
    .art-cover{margin-top:20px;border-radius:14px}
    .art-meta{gap:6px 12px;font-size:11.5px}
    .art-body > .art-table-scroll > table{font-size:12.5px}
    .art-body > .art-table-scroll > table thead th,.art-body > .art-table-scroll > table tbody td{padding:9px 11px}
}
