/* Scheme Junction - shared styles */
:root {
  --junction-purple: #6b35af;
  --junction-purple-dark: #5a2c91;
  --junction-navy: #0f172a;
  --junction-bg: #f8fafc;
  --junction-muted: #64748b;
  --junction-line: rgba(15, 23, 42, 0.08);
}

body {
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  background: var(--junction-bg);
  color: var(--junction-navy);
  margin: 0;
}

/* ---------- Navigation ---------- */
.navbar { backdrop-filter: blur(12px); background: rgba(255, 255, 255, 0.95); border-bottom: 1px solid var(--junction-line); padding: 0.8rem 0; }
.navbar-brand { font-weight: 800; font-size: 1.45rem; display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--junction-navy) !important; }
.brand-icon { height: 38px; width: auto; transition: transform 0.3s ease; }
.navbar-brand:hover .brand-icon { transform: scale(1.05); }
.nav-link { color: var(--junction-navy) !important; }
.nav-link.active { color: var(--junction-purple) !important; }

/* ---------- Footer ---------- */
.sj-footer { background: var(--junction-navy); color: #fff; padding: 60px 0 30px; margin-top: 4rem; }
.footer-link { color: #94a3b8; text-decoration: none; font-size: 0.9rem; }
.footer-link:hover { color: #fff !important; }

/* ---------- Buttons ---------- */
.btn-purple { background: var(--junction-purple); color: #fff; border-radius: 12px; padding: 12px 28px; font-weight: 600; border: none; text-decoration: none; display: inline-block; }
.btn-purple:hover { background: var(--junction-purple-dark); color: #fff; }

/* ---------- Page headers ---------- */
.sj-pagehead { padding: 3.5rem 0 2rem; text-align: center; }
.sj-pagehead h1 { font-weight: 800; }
.sj-main { padding-bottom: 2rem; }

/* ---------- Blog cards ---------- */
.sj-card { background: #fff; border: 1px solid var(--junction-line); border-radius: 20px; overflow: hidden; height: 100%; display: flex; flex-direction: column; transition: transform 0.25s ease, box-shadow 0.25s ease; text-decoration: none; color: inherit; }
.sj-card:hover { transform: translateY(-4px); box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08); color: inherit; }
.sj-card-img { aspect-ratio: 16 / 9; background: #f3e8ff; display: flex; align-items: center; justify-content: center; color: var(--junction-purple); font-size: 2.4rem; overflow: hidden; }
.sj-card-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sj-card-body { padding: 1.4rem 1.5rem 1.6rem; display: flex; flex-direction: column; flex: 1; }
.sj-card-body h2, .sj-card-body h3 { font-size: 1.15rem; font-weight: 800; line-height: 1.35; margin: 0.5rem 0; }
.sj-card-body p { color: var(--junction-muted); font-size: 0.92rem; margin-bottom: 1rem; }
.sj-card-meta { margin-top: auto; font-size: 0.78rem; color: var(--junction-muted); }
.sj-cat { display: inline-block; background: #f3e8ff; color: var(--junction-purple); font-weight: 700; font-size: 0.72rem; letter-spacing: 0.04em; text-transform: uppercase; padding: 4px 12px; border-radius: 999px; text-decoration: none; }
.sj-cat:hover { background: #e9d5ff; color: var(--junction-purple-dark); }
.sj-tabs { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-bottom: 2rem; }
.sj-tabs a { padding: 7px 16px; border-radius: 999px; border: 1px solid var(--junction-line); background: #fff; color: var(--junction-navy); text-decoration: none; font-size: 0.85rem; font-weight: 600; }
.sj-tabs a.active, .sj-tabs a:hover { background: var(--junction-purple); color: #fff; border-color: var(--junction-purple); }

/* ---------- Article ---------- */
.sj-crumbs { font-size: 0.82rem; color: var(--junction-muted); margin-bottom: 1rem; }
.sj-crumbs a { color: var(--junction-muted); text-decoration: none; }
.sj-crumbs a:hover { color: var(--junction-purple); }
.sj-article-card { background: #fff; border-radius: 24px; padding: 2.5rem; border: 1px solid var(--junction-line); box-shadow: 0 4px 20px rgba(15, 23, 42, 0.04); }
@media (max-width: 575px) { .sj-article-card { padding: 1.5rem 1.2rem; border-radius: 18px; } }
.sj-article-card h1 { font-weight: 800; font-size: clamp(1.7rem, 4vw, 2.4rem); line-height: 1.2; margin: 0.9rem 0 0.8rem; }
.sj-lead { font-size: 1.1rem; color: #334155; line-height: 1.6; }
.sj-meta { font-size: 0.84rem; color: var(--junction-muted); display: flex; flex-wrap: wrap; gap: 4px 14px; margin: 1rem 0 1.5rem; padding-bottom: 1.2rem; border-bottom: 1px solid var(--junction-line); }
.sj-cover { margin: 0 0 1.8rem; }
.sj-cover img { width: 100%; height: auto; border-radius: 16px; display: block; aspect-ratio: 16 / 9; object-fit: cover; }
.sj-article { line-height: 1.85; font-size: 1.04rem; color: #1e293b; }
.sj-article h2 { font-weight: 800; font-size: 1.5rem; margin: 2.2rem 0 0.8rem; color: var(--junction-navy); scroll-margin-top: 90px; }
.sj-article h3 { font-weight: 700; font-size: 1.22rem; margin: 1.8rem 0 0.6rem; color: var(--junction-purple); scroll-margin-top: 90px; }
.sj-article h4 { font-weight: 700; font-size: 1.05rem; margin: 1.4rem 0 0.5rem; }
.sj-article p, .sj-article ul, .sj-article ol { margin-bottom: 1.2rem; }
.sj-article li { margin-bottom: 0.4rem; }
.sj-article a { color: var(--junction-purple); text-underline-offset: 3px; }
.sj-article blockquote { border-left: 4px solid var(--junction-purple); background: #faf5ff; padding: 1rem 1.3rem; border-radius: 0 12px 12px 0; margin: 1.5rem 0; }
.sj-article blockquote p:last-child { margin-bottom: 0; }
.sj-article code { background: #f1f5f9; padding: 2px 6px; border-radius: 6px; font-size: 0.9em; }
.sj-article pre { background: #0f172a; color: #e2e8f0; padding: 1rem; border-radius: 12px; overflow-x: auto; }
.sj-article pre code { background: none; padding: 0; color: inherit; }
.sj-figure { margin: 1.8rem 0; }
.sj-figure img { width: 100%; height: auto; border-radius: 14px; display: block; }
.sj-figure figcaption { font-size: 0.82rem; color: var(--junction-muted); text-align: center; margin-top: 0.5rem; }
.sj-table { font-size: 0.93rem; }
.sj-table th { background: #f8fafc; }
.sj-callout { border-radius: 14px; padding: 1rem 1.3rem; margin: 1.6rem 0; border: 1px solid; }
.sj-callout > :last-child { margin-bottom: 0; }
.sj-callout-title { font-weight: 800; margin-bottom: 0.3rem; }
.sj-callout-tip, .sj-callout-info, .sj-callout-note { background: #f0f9ff; border-color: #bae6fd; }
.sj-callout-warning { background: #fffbeb; border-color: #fde68a; }
.sj-toc { background: #f8fafc; border: 1px solid var(--junction-line); border-radius: 14px; padding: 1rem 1.3rem; margin: 0 0 1.8rem; font-size: 0.92rem; }
.sj-toc strong { display: block; margin-bottom: 0.4rem; }
.sj-toc ol { margin: 0; padding-left: 1.2rem; }
.sj-toc li { margin-bottom: 0.25rem; }
.sj-toc a { color: var(--junction-navy); text-decoration: none; }
.sj-toc a:hover { color: var(--junction-purple); }
.sj-disclaimer { font-size: 0.82rem; color: var(--junction-muted); border-top: 1px solid var(--junction-line); margin-top: 2rem; padding-top: 1rem; }
.sj-sponsored-banner { background: #fff7ed; border: 1px solid #fed7aa; border-radius: 12px; padding: 0.7rem 1rem; font-size: 0.85rem; margin-bottom: 1.4rem; }
.sj-share { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 1.2rem; align-items: center; font-size: 0.85rem; color: var(--junction-muted); }
.sj-share a, .sj-share button { border: 1px solid var(--junction-line); background: #fff; color: var(--junction-navy); padding: 6px 14px; border-radius: 999px; text-decoration: none; font-weight: 600; font-size: 0.82rem; cursor: pointer; }
.sj-share a:hover, .sj-share button:hover { border-color: var(--junction-purple); color: var(--junction-purple); }
.sj-preview-bar { background: #fef3c7; border-bottom: 1px solid #fcd34d; padding: 8px 0; text-align: center; font-size: 0.85rem; font-weight: 600; }

/* ---------- Ads and sponsors (only drawn when switched on in the admin) ---------- */
.sj-ad { margin: 2rem 0; text-align: center; min-height: 100px; }
.sj-ad .sj-ad-label, .sj-sponsor .sj-ad-label { display: block; font-size: 10px; color: #94a3b8; text-transform: uppercase; letter-spacing: 1px; font-weight: 700; margin-bottom: 4px; }
.sj-ad-article_side { position: sticky; top: 90px; min-height: 300px; margin-top: 0; }
.sj-sponsor { background: #fff; border: 1px solid #e9d5ff; border-radius: 16px; padding: 1rem 1.3rem 1.2rem; margin: 2rem 0; }
.sj-sponsor-row { display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; }
.sj-sponsor-logo { height: 52px; width: auto; max-width: 110px; object-fit: contain; border-radius: 8px; }
.sj-sponsor-text { flex: 1; min-width: 200px; }
.sj-sponsor-text strong { display: block; font-size: 1rem; }
.sj-sponsor-text span { font-size: 0.88rem; color: var(--junction-muted); }

/* ---------- Pagination ---------- */
.sj-pager { display: flex; justify-content: center; gap: 8px; margin: 2.5rem 0 0; flex-wrap: wrap; }
.sj-pager a, .sj-pager span { padding: 8px 16px; border-radius: 10px; border: 1px solid var(--junction-line); background: #fff; text-decoration: none; color: var(--junction-navy); font-weight: 600; font-size: 0.9rem; }
.sj-pager .current { background: var(--junction-purple); color: #fff; border-color: var(--junction-purple); }

/* ---------- Misc ---------- */
.sj-empty { text-align: center; padding: 3rem 1rem; color: var(--junction-muted); }
.sj-info-box { background: #fff; border-radius: 24px; padding: 2.2rem; border: 1px solid var(--junction-line); }
.sj-skip { position: absolute; left: -999px; }
.sj-skip:focus { left: 8px; top: 8px; background: #fff; padding: 8px 12px; z-index: 9999; }
