/* =========================================================
   سپید۲۴ — مجله گردشگری + صفحه تکی بلاگ
   v1.0.0 — RTL · هماهنگ با تم فضایی
   ========================================================= */

:root {
  --sepm-ink: #1b2559;
  --sepm-muted: #5b6478;
  --sepm-line: #e8ecf4;
  --sepm-bg: #f4f7fd;
  --sepm-violet: #7c3aed;
  --sepm-indigo: #4338ca;
  --sepm-gold: #ffb703;
}

.sep-mag, .sep-post { background: var(--sepm-bg); }
/* خنثی‌کردن محدودیت عرض پیش‌فرض .site-main قالب Hello — بنر کهکشانی تمام‌عرض شود */
main.sep-mag, main.sep-post {
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
  width: 100% !important;
}

/* ---------- هیرو مجله ---------- */
.sep-mag-hero { padding: 34px 0 64px; }
.sep-mag-hero .spx-title { margin-bottom: 8px; }
.sep-mag-hero .spx-sub { margin-bottom: 20px; }

.sep-mag-search {
  position: relative; z-index: 3;
  display: flex; align-items: center; gap: 8px;
  max-width: 640px; margin: 18px 0 4px;
  background: rgba(255, 255, 255, .97);
  border: 1px solid rgba(255, 255, 255, .4);
  border-radius: 999px; padding: 7px 8px 7px 7px;
  box-shadow: 0 22px 50px rgba(4, 8, 28, .45);
}
.sep-ms-ico { font-size: 17px; padding-inline-start: 12px; }
.sep-mag-search input {
  flex: 1; min-width: 0; border: none; outline: none; background: transparent;
  font-family: inherit; font-size: 14px; color: var(--sepm-ink); padding: 9px 4px;
}
.sep-mag-search input::placeholder { color: #9aa4bd; }
.sep-mag-search button {
  border: none; cursor: pointer; font-family: inherit;
  background: linear-gradient(135deg, #4338ca, #7c3aed);
  color: #fff; font-weight: 800; font-size: 13.5px;
  padding: 10px 22px; border-radius: 999px;
  box-shadow: 0 8px 18px rgba(124, 58, 237, .4);
  transition: transform .15s ease, box-shadow .15s ease;
}
.sep-mag-search button:hover { transform: translateY(-1px); box-shadow: 0 12px 24px rgba(124, 58, 237, .5); }
.sep-mag-cats { margin-top: 16px; }
.sep-mag-cats .spx-hchip { text-decoration: none; transition: all .15s ease; }
.sep-mag-cats .spx-hchip:hover { background: rgba(124, 58, 237, .35); transform: translateY(-1px); }

/* ---------- گرید مجله ---------- */
.sep-mag-body {
  max-width: 1200px; margin: 0 auto; padding: 26px 16px 8px;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px;
}
.sep-mag-body-flat { padding: 18px 0 0; }

/* کارت ویژه (اولین مقاله) — تمام عرض */
.sep-mag-featured {
  grid-column: 1 / -1;
  display: grid; grid-template-columns: 1.25fr 1fr; gap: 0; overflow: hidden;
  background: #fff; border-radius: 22px; text-decoration: none;
  box-shadow: 0 14px 38px rgba(27, 37, 89, .1);
  border: 1px solid var(--sepm-line);
  transition: transform .2s ease, box-shadow .2s ease;
}
.sep-mag-featured:hover { transform: translateY(-4px); box-shadow: 0 22px 48px rgba(76, 29, 149, .18); }
.sep-mf-img { position: relative; min-height: 300px; display: block; }
.sep-mf-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sep-mf-ph { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 64px; background: linear-gradient(135deg, #171044, #4338ca); }
.sep-mf-badge {
  position: absolute; top: 14px; inset-inline-start: 14px;
  background: rgba(10, 14, 40, .72); color: #ffd35c; backdrop-filter: blur(4px);
  font-size: 12px; font-weight: 800; padding: 7px 14px; border-radius: 999px;
  border: 1px solid rgba(255, 211, 92, .4);
}
.sep-mf-body { padding: 26px 26px 22px; display: flex; flex-direction: column; gap: 10px; }
.sep-mcat {
  display: inline-block; width: fit-content;
  background: linear-gradient(135deg, rgba(67, 56, 202, .1), rgba(124, 58, 237, .12));
  color: var(--sepm-indigo); font-size: 11.5px; font-weight: 800;
  padding: 5px 12px; border-radius: 999px; border: 1px solid rgba(67, 56, 202, .18);
}
.sep-mtitle {
  font-size: clamp(17px, 2.2vw, 23px); font-weight: 900; color: var(--sepm-ink);
  line-height: 1.7; display: block;
}
.sep-mfeatured:hover .sep-mtitle, .sep-mag-featured:hover .sep-mtitle { color: var(--sepm-violet); }
.sep-mexcerpt { font-size: 13.5px; color: var(--sepm-muted); line-height: 2; display: block; }
.sep-mmeta { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: auto; padding-top: 10px; }
.sep-mmeta i, .sep-mmeta a { font-style: normal; font-size: 12px; color: #8a93ab; }
.sep-mmore { color: var(--sepm-violet); font-weight: 800; font-size: 13.5px; margin-top: 6px; }

/* کارت معمولی */
.sep-mag-card {
  display: flex; flex-direction: column; overflow: hidden;
  background: #fff; border-radius: 18px; text-decoration: none;
  border: 1px solid var(--sepm-line);
  box-shadow: 0 8px 24px rgba(27, 37, 89, .07);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.sep-mag-card:hover { transform: translateY(-4px); border-color: rgba(124, 58, 237, .45); box-shadow: 0 16px 36px rgba(124, 58, 237, .16); }
.sep-mc-img { position: relative; display: block; aspect-ratio: 16 / 9.5; overflow: hidden; }
.sep-mc-img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s ease; }
.sep-mag-card:hover .sep-mc-img img { transform: scale(1.06); }
.sep-mc-ph { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 42px; background: linear-gradient(135deg, #171044, #4338ca); }
.sep-mc-img .sep-mcat {
  position: absolute; bottom: 10px; inset-inline-start: 10px;
  background: rgba(255, 255, 255, .94); border-color: transparent;
}
.sep-mc-body { padding: 15px 16px 14px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.sep-mc-body .sep-mtitle { font-size: 15px; line-height: 1.75; }
.sep-mc-body .sep-mmeta { padding-top: 2px; border-top: 1px dashed var(--sepm-line); }
.sep-mread { color: var(--sepm-violet); font-weight: 800; margin-inline-start: auto; }
.sep-mag-empty { max-width: 1200px; margin: 0 auto; padding: 40px 16px 30px; color: var(--sepm-muted); font-size: 15px; text-align: center; }
.sep-mag-empty a { color: var(--sepm-violet); font-weight: 700; }

.sep-mag-intro { max-width: 860px; color: var(--sepm-muted); font-size: 14px; line-height: 2.1; padding-top: 8px; }

/* صفحه‌بندی */
.sep-mag-pager { max-width: 1200px; margin: 0 auto; padding: 8px 16px 34px; }
.sep-mag-pager .nav-links { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.sep-mag-pager .page-numbers {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 40px; height: 40px; padding: 0 14px; border-radius: 12px;
  background: #fff; border: 1px solid var(--sepm-line); color: var(--sepm-ink);
  font-weight: 700; font-size: 13.5px; text-decoration: none; transition: all .15s ease;
}
.sep-mag-pager .page-numbers.current { background: linear-gradient(135deg, #4338ca, #7c3aed); color: #fff; border-color: transparent; }
.sep-mag-pager .page-numbers:hover:not(.current) { border-color: var(--sepm-violet); color: var(--sepm-violet); }

/* ---------- صفحه تکی مقاله ---------- */
.sep-post-hero { padding: 34px 0 42px; }
.sep-post-title { max-width: 900px; margin-inline: auto; text-align: center; }
.sep-post-meta {
  display: flex; flex-wrap: wrap; gap: 8px 18px; justify-content: center;
  margin-top: 6px; font-size: 13px; color: rgba(255, 255, 255, .88);
  text-shadow: 0 1px 10px rgba(0, 0, 0, .4);
}
.sep-post-cat {
  color: #ffd35c; text-decoration: none; font-weight: 800;
  background: rgba(10, 14, 40, .5); padding: 4px 12px; border-radius: 999px;
}
.sep-post-cat:hover { color: #fff; }

.sep-post-thumb { margin-top: -34px; position: relative; z-index: 4; }
.sep-post-thumb img {
  width: 100%; max-height: 520px; object-fit: cover; display: block;
  border-radius: 22px; box-shadow: 0 26px 60px rgba(4, 8, 28, .35);
}

.sep-post-body {
  background: #fff; border-radius: 22px; border: 1px solid var(--sepm-line);
  box-shadow: 0 14px 38px rgba(27, 37, 89, .08);
  margin-top: 22px; padding: clamp(18px, 3.4vw, 40px);
}
.sep-post-content { color: #2a3352; font-size: 15.5px; line-height: 2.15; }
.sep-post-content p { margin: 0 0 16px; }
.sep-post-content h2 {
  font-size: clamp(18px, 2.4vw, 24px); font-weight: 900; color: var(--sepm-ink);
  margin: 30px 0 12px; padding-inline-start: 14px; position: relative;
}
.sep-post-content h2::before {
  content: ""; position: absolute; inset-inline-start: 0; top: 8px; bottom: 8px;
  width: 5px; border-radius: 999px;
  background: linear-gradient(180deg, #4338ca, #7c3aed);
}
.sep-post-content h3 { font-size: 17.5px; font-weight: 800; color: var(--sepm-ink); margin: 24px 0 10px; }
.sep-post-content a { color: var(--sepm-violet); }
.sep-post-content ul, .sep-post-content ol { padding-inline-start: 22px; margin: 0 0 16px; }
.sep-post-content li { margin-bottom: 7px; }
.sep-post-content img { max-width: 100%; height: auto; border-radius: 14px; }
.sep-post-content blockquote {
  border-inline-start: 4px solid var(--sepm-violet); background: #f7f4ff;
  margin: 18px 0; padding: 14px 18px; border-radius: 12px; color: #4c1d95;
}
.sep-post-content table { width: 100%; border-collapse: collapse; margin: 16px 0; }
.sep-post-content th, .sep-post-content td { border: 1px solid var(--sepm-line); padding: 9px 12px; font-size: 14px; }
.sep-post-content th { background: #f4f1ff; }
.sep-post-content figcaption { text-align: center; color: #8a93ab; font-size: 12.5px; margin-top: 8px; }

.sep-post-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; padding-top: 16px; border-top: 1px dashed var(--sepm-line); }
.sep-post-tags a {
  display: inline-block; background: #f4f2ff; border: 1px solid #e3dcfc; color: #5b21b6;
  font-size: 12px; font-weight: 700; padding: 6px 13px; border-radius: 999px; text-decoration: none;
}
.sep-post-tags a:hover { background: var(--sepm-violet); color: #fff; border-color: var(--sepm-violet); }

/* اشتراک‌گذاری */
.sep-share {
  display: flex; align-items: center; flex-wrap: wrap; gap: 9px;
  margin-top: 20px; padding: 14px 16px; border-radius: 14px;
  background: #f8f9fe; border: 1px solid var(--sepm-line);
}
.sep-share-label { font-size: 13px; font-weight: 800; color: var(--sepm-muted); margin-inline-end: 4px; }
.sep-share a, .sep-copy {
  display: inline-flex; align-items: center; gap: 5px;
  border: 1px solid var(--sepm-line); background: #fff; color: var(--sepm-ink);
  font-size: 12.5px; font-weight: 700; padding: 7px 14px; border-radius: 999px;
  text-decoration: none; cursor: pointer; font-family: inherit; transition: all .15s ease;
}
.sep-share a:hover, .sep-copy:hover { border-color: var(--sepm-violet); color: var(--sepm-violet); transform: translateY(-1px); }

/* جعبه نویسنده */
.sep-author {
  display: flex; gap: 14px; align-items: center;
  margin-top: 20px; padding: 16px 18px; border-radius: 16px;
  background: linear-gradient(135deg, rgba(67, 56, 202, .06), rgba(124, 58, 237, .08));
  border: 1px solid rgba(67, 56, 202, .15);
}
.sep-author-av img { width: 58px; height: 58px; border-radius: 50%; object-fit: cover; border: 3px solid #fff; box-shadow: 0 6px 16px rgba(67, 56, 202, .25); }
.sep-author b { font-size: 14.5px; color: var(--sepm-ink); }
.sep-author p { margin: 4px 0 0; font-size: 12.5px; color: var(--sepm-muted); line-height: 1.9; }

/* مرتبط‌ها */
.sep-related { padding: 34px 0 10px; }
.sep-related .spx-sec-head h2 { color: var(--sepm-ink); }

/* قبلی / بعدی */
.sep-postnav {
  display: flex; justify-content: space-between; gap: 12px; padding-top: 6px; padding-bottom: 40px;
}
.sep-pn { max-width: 48%; }
.sep-pn a {
  display: block; background: #fff; border: 1px solid var(--sepm-line); border-radius: 14px;
  padding: 13px 16px; text-decoration: none; color: var(--sepm-ink);
  font-size: 13.5px; font-weight: 700; line-height: 1.8;
  box-shadow: 0 6px 18px rgba(27, 37, 89, .06); transition: all .15s ease;
  overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
}
.sep-pn a:hover { border-color: var(--sepm-violet); color: var(--sepm-violet); transform: translateY(-2px); }

/* ---------- ریسپانسیو ---------- */
@media (max-width: 1024px) {
  .sep-mag-body { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .sep-mag-featured { grid-template-columns: 1fr; }
  .sep-mf-img { min-height: 210px; }
}
@media (max-width: 640px) {
  .sep-mag-body { grid-template-columns: 1fr; }
  .sep-mag-search { flex-wrap: nowrap; }
  .sep-postnav { flex-direction: column; }
  .sep-pn { max-width: 100%; }
}
