/* =========================================================================
   MishiLand Magazine v11.0 — بلوک‌های جدید مجله (mlg3-*)
   فقط روی صفحات مجله لود می‌شود (آرشیو راهنما / تک‌مقاله / آرشیو موضوع).
   رنگ‌ها هم‌راستا با پالت برند (copper/saffron) در mishiland-app.css است،
   اما این فایل کاملاً مستقل و بدون وابستگی به کلاس‌های WoodMart نوشته شده.
   ========================================================================= */

:root {
  --mlg3-copper: #a66731;
  --mlg3-copper-dark: #8a5426;
  --mlg3-gold: #cfa35a;
  --mlg3-ink: #1f2937;
  --mlg3-muted: #6b7280;
  --mlg3-line: #ece7df;
  --mlg3-paper: #fbf7f0;
  --mlg3-white: #ffffff;
}

/* ---------- فهرست مطالب (TOC) ---------- */
.mlg3-toc {
  display: block;
  background: var(--mlg3-white);
  border: 1px solid var(--mlg3-line);
  border-radius: 14px;
  padding: 14px 16px;
  margin-bottom: 16px;
  font-size: 13.5px;
}
.mlg3-toc strong { display: block; color: var(--mlg3-ink); margin-bottom: 8px; font-size: 14.5px; }
.mlg3-toc ol { list-style: none; margin: 0; padding: 0; counter-reset: mlg3-toc-counter; }
.mlg3-toc li { counter-increment: mlg3-toc-counter; margin-bottom: 6px; line-height: 1.7; }
.mlg3-toc li a {
  color: var(--mlg3-muted);
  text-decoration: none;
}
.mlg3-toc li a::before {
  content: counter(mlg3-toc-counter) ". ";
  color: var(--mlg3-copper);
  font-weight: 700;
}
.mlg3-toc li a:hover { color: var(--mlg3-copper); text-decoration: underline; }
.mlg3-toc li.mlg3-toc__sub { padding-inline-start: 16px; font-size: 12.5px; }

/* ---------- کادر Pillar/Cluster ---------- */
.mlg3-cluster-box {
  display: block;
  background: var(--mlg3-paper);
  border: 1px solid #eadbc6;
  border-radius: 14px;
  padding: 14px 16px;
  margin-bottom: 16px;
  font-size: 13.5px;
}
.mlg3-cluster-box strong { display: block; color: var(--mlg3-ink); margin-bottom: 8px; }
.mlg3-cluster-box ul { list-style: none; margin: 0; padding: 0; }
.mlg3-cluster-box li { margin-bottom: 6px; }
.mlg3-cluster-box li a { color: var(--mlg3-copper); text-decoration: none; }
.mlg3-cluster-box li a:hover { text-decoration: underline; }
.mlg3-cluster-box--child { display: flex; flex-direction: column; gap: 4px; }
.mlg3-cluster-box--child span { color: var(--mlg3-muted); font-size: 12px; }
.mlg3-cluster-box--child a { color: var(--mlg3-copper); font-weight: 800; text-decoration: none; }
.mlg3-cluster-box--child a:hover { text-decoration: underline; }

/* ---------- FAQ ---------- */
.mlg3-faq {
  margin-top: 34px;
  padding-top: 26px;
  border-top: 1px solid var(--mlg3-line);
}
.mlg3-faq h2 { font-size: 22px; color: var(--mlg3-ink); margin: 0 0 14px; }
.mlg3-faq__item {
  background: var(--mlg3-paper);
  border: 1px solid #eee2d0;
  border-radius: 12px;
  padding: 12px 16px;
  margin-bottom: 10px;
}
.mlg3-faq__item summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--mlg3-ink);
  font-size: 15px;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.mlg3-faq__item summary::-webkit-details-marker { display: none; }
.mlg3-faq__item summary::after {
  content: "+";
  font-size: 20px;
  color: var(--mlg3-copper);
  flex-shrink: 0;
}
.mlg3-faq__item[open] summary::after { content: "−"; }
.mlg3-faq__answer { margin-top: 10px; color: var(--mlg3-muted); font-size: 14px; line-height: 2; }
.mlg3-faq__answer p:last-child { margin-bottom: 0; }

/* ---------- مقالات مرتبط ---------- */
.mlg3-related { margin-top: 34px; padding-top: 26px; border-top: 1px solid var(--mlg3-line); }
.mlg3-related h2 { font-size: 22px; color: var(--mlg3-ink); margin: 0 0 14px; }
.mlg3-related__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 14px; }
.mlg3-related__card {
  display: block;
  border: 1px solid var(--mlg3-line);
  border-radius: 14px;
  overflow: hidden;
  text-decoration: none;
  background: var(--mlg3-white);
  transition: box-shadow .2s ease, transform .2s ease;
}
.mlg3-related__card:hover { box-shadow: 0 8px 20px rgba(17,24,39,.08); transform: translateY(-2px); }
.mlg3-related__card img { width: 100%; height: 110px; object-fit: cover; display: block; }
.mlg3-related__placeholder {
  display: flex; align-items: center; justify-content: center;
  height: 110px; background: var(--mlg3-paper); color: var(--mlg3-copper); font-size: 12.5px; font-weight: 700;
}
.mlg3-related__card strong { display: block; padding: 10px 12px; font-size: 13.5px; line-height: 1.7; color: var(--mlg3-ink); }

/* ---------- لینک‌های پیشنهادی ---------- */
.mlg3-suggested { margin-top: 22px; background: var(--mlg3-paper); border: 1px solid #eadbc6; border-radius: 14px; padding: 14px 16px; }
.mlg3-suggested strong { display: block; margin-bottom: 8px; color: var(--mlg3-ink); font-size: 14.5px; }
.mlg3-suggested ul { list-style: none; margin: 0; padding: 0; }
.mlg3-suggested li { margin-bottom: 6px; }
.mlg3-suggested li a { color: var(--mlg3-copper); text-decoration: none; font-size: 13.5px; }
.mlg3-suggested li a:hover { text-decoration: underline; }

/* ---------- هاب راهنماهای جامع (صفحه آرشیو مجله) ---------- */
.mlg3-hub { max-width: 1100px; margin: 0 auto 28px; padding: 0 24px; }
.mlg3-hub h2 { font-size: 20px; color: var(--mlg3-ink); margin: 0 0 12px; }
.mlg3-hub__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.mlg3-hub__card {
  display: block;
  background: linear-gradient(160deg, #1f2733, #14181f);
  border-radius: 16px;
  overflow: hidden;
  text-decoration: none;
  color: #fff;
  position: relative;
  min-height: 120px;
}
.mlg3-hub__card img { width: 100%; height: 90px; object-fit: cover; opacity: .55; }
.mlg3-hub__card strong { display: block; padding: 12px 14px; font-size: 14px; line-height: 1.7; }

/* ---------- متادیتای کارت آرشیو (موضوع + تاریخ) ---------- */
.mlg3-card-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--mlg3-muted);
  margin-bottom: 4px;
}
.mlg3-card-topic {
  color: var(--mlg3-copper);
  font-weight: 800;
  text-decoration: none;
  background: var(--mlg3-paper);
  border-radius: 999px;
  padding: 2px 10px;
}
.mlg3-card-topic:hover { text-decoration: underline; }

@media (max-width: 600px) {
  .mlg3-hub, .mlg3-related__grid { padding-inline: 14px; }
  .mlg3-hub__grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
}
