/* Gilanijan Design System — lightweight */
:root{
  --gj-primary:#0b5e2e;
  --gj-primary-2:#087f43;
  --gj-danger:#b42318;
  --gj-text:#1e2925;
  --gj-muted:#6c7974;
  --gj-border:#e4ebe7;
  --gj-card:#fff;
  --gj-radius:12px;
  --gj-shadow:0 6px 20px rgba(11,94,46,.08);
  --gj-shadow-hover:0 12px 28px rgba(11,94,46,.14);
}
.news-card{transition:transform .2s ease, box-shadow .2s ease;position:relative;overflow:hidden}
.news-card:hover{transform:translateY(-4px);box-shadow:var(--gj-shadow-hover)}
.news-card .news-card-img{overflow:hidden}
.news-card .news-card-img img{transition:transform .35s ease}
.news-card:hover .news-card-img img{transform:scale(1.05)}
.gj-badge-breaking{position:absolute;top:10px;right:10px;z-index:2;background:var(--gj-danger);color:#fff;font-size:11px;font-weight:800;padding:4px 10px;border-radius:999px;box-shadow:0 2px 8px rgba(180,35,24,.35)}
.gj-read-progress{position:fixed;top:0;right:0;left:0;height:3px;z-index:9999;background:transparent;pointer-events:none}
.gj-read-progress > span{display:block;height:100%;width:0;background:linear-gradient(90deg,var(--gj-primary),var(--gj-primary-2));transition:width .05s linear}
.related-cards{display:grid;grid-template-columns:repeat(auto-fill,minmax(160px,1fr));gap:12px;margin-top:12px}
.related-card{background:var(--gj-card);border:1px solid var(--gj-border);border-radius:var(--gj-radius);overflow:hidden;text-decoration:none;color:inherit;transition:transform .2s,box-shadow .2s}
.related-card:hover{transform:translateY(-3px);box-shadow:var(--gj-shadow)}
.related-card img{width:100%;height:110px;object-fit:cover;display:block}
.related-card .rc-title{padding:10px;font-size:13px;font-weight:700;line-height:1.5}
.article-breaking-banner{display:inline-flex;align-items:center;gap:6px;background:#fdecec;color:var(--gj-danger);font-weight:800;padding:6px 12px;border-radius:999px;margin-bottom:10px;font-size:13px}

/* —— Typography —— */
body{font-family:Vazir,Tahoma,Arial,sans-serif;color:var(--gj-text);line-height:1.85}
.article-header h1,.single-article h1{font-weight:800;line-height:1.45;font-size:clamp(1.35rem,2.5vw,1.9rem)}
.article-content{font-size:1.05rem;line-height:2;font-weight:400}
.article-content p{margin:0 0 1.1em}
@media(max-width:640px){
  .article-header h1{font-size:1.45rem}
  .article-content{font-size:1.0625rem;line-height:2}
}

/* —— Dark mode palette —— */
html.dark-mode,html.dark,[data-theme=dark]{
  --gj-text:#e8eeea;--gj-muted:#9aaba3;--gj-border:#2a3a33;--gj-card:#15201b;
  --gj-shadow:0 6px 20px rgba(0,0,0,.35);--gj-shadow-hover:0 12px 28px rgba(0,0,0,.45);
  color-scheme:dark;
}
html.dark-mode body,html.dark body,[data-theme=dark] body{background:#0d1511;color:var(--gj-text)}
html.dark-mode .news-card,html.dark .news-card,[data-theme=dark] .news-card,
html.dark-mode .related-card,html.dark .related-card{background:var(--gj-card);border-color:var(--gj-border)}
html.dark-mode .top-bar,html.dark .main-nav,html.dark .breaking-ticker{filter:none}
html.dark-mode a{color:#8fd4a8}

/* —— Header layers —— */
.gj-header-weather{font-size:12px;opacity:.9;white-space:nowrap}
.gj-header-links{display:flex;flex-wrap:wrap;gap:8px;justify-content:center;padding:6px 0;font-size:13px}
.gj-header-links a{color:inherit;text-decoration:none;padding:4px 8px;border-radius:6px}
.gj-header-links a:hover{background:rgba(11,94,46,.1)}

/* —— Pulse / weather / stats —— */
.gj-pulse-box{background:linear-gradient(135deg,#f4f9f6,#eaf4ee);border:1px solid var(--gj-border);border-radius:16px;padding:16px;margin:1rem 0 1.5rem}
html.dark-mode .gj-pulse-box{background:linear-gradient(135deg,#15201b,#1a2a22)}
.gj-pulse-box h2{margin:0 0 12px;font-size:1.15rem}
.gj-stat-card{background:#fff;border:1px solid var(--gj-border);border-radius:12px;padding:14px;text-align:center}
html.dark-mode .gj-stat-card{background:#1a2a22}
.gj-stat-card b{display:block;font-size:1.5rem;color:var(--gj-primary)}
.gj-city-chips{display:flex;flex-wrap:wrap;gap:8px}
.gj-chip{display:inline-flex;gap:6px;align-items:center;background:#fff;border:1px solid var(--gj-border);border-radius:999px;padding:6px 12px;text-decoration:none;color:inherit;font-size:13px}
.gj-chip em{background:var(--gj-primary);color:#fff;border-radius:999px;padding:1px 7px;font-style:normal;font-size:11px}
.gj-weather-row{display:grid;grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:10px}
.gj-weather-card{background:#fff;border:1px solid var(--gj-border);border-radius:12px;padding:12px;text-align:center}
html.dark-mode .gj-weather-card{background:#1a2a22}
.gj-weather-card .ic{font-size:1.6rem}
.gj-weather-card .tmp{font-size:1.3rem;font-weight:800;color:var(--gj-primary)}

/* —— Share —— */

/* —— Skeleton —— */
.gj-skel{background:linear-gradient(90deg,#eee 25%,#f5f5f5 37%,#eee 63%);background-size:400% 100%;animation:gjskel 1.2s ease infinite;border-radius:8px}
@keyframes gjskel{0%{background-position:100% 0}100%{background-position:0 0}}
.gj-skel-card{height:220px;margin-bottom:12px}

/* —— Timeline dossier —— */
.gj-timeline{border-right:3px solid #cfe0d6;padding-right:16px;margin-top:1rem}
.gj-tl-item{margin:0 0 16px;position:relative}
.gj-tl-time{font-size:12px;color:var(--gj-muted);margin-bottom:4px}
.gj-tl-card{display:block;background:#fff;border:1px solid var(--gj-border);border-radius:12px;padding:12px;text-decoration:none;color:inherit}
html.dark-mode .gj-tl-card{background:#1a2a22}
.gj-btn{background:var(--gj-primary);color:#fff;border:0;padding:10px 16px;border-radius:8px;cursor:pointer;font-family:inherit}
.gj-live-viewers{font-size:13px;color:var(--gj-muted)}
.gj-follow-tag{border:1px dashed var(--gj-primary);background:transparent;color:var(--gj-primary);padding:4px 10px;border-radius:999px;cursor:pointer;font-size:12px;font-family:inherit;margin:4px}

/* search suggest */
.gj-suggest{position:absolute;right:0;left:0;top:100%;background:#fff;border:1px solid var(--gj-border);border-radius:10px;box-shadow:var(--gj-shadow);z-index:50;max-height:320px;overflow:auto;display:none}
html.dark-mode .gj-suggest{background:#15201b}
.gj-suggest a{display:block;padding:8px 12px;text-decoration:none;color:inherit;font-size:13px;border-bottom:1px solid var(--gj-border)}
.gj-suggest a:hover{background:#f4f9f6}
.gj-suggest .sec{padding:6px 12px;font-size:11px;color:var(--gj-muted);font-weight:700}
.search-box{position:relative}

/* DARK FIX 2 */
html.dark .gj-pulse-box,html.dark-mode .gj-pulse-box{background:#15201b!important;border-color:#2a3a33!important;color:#e8f0ec!important}
html.dark .gj-stat-card,html.dark .gj-weather-card,html.dark .gj-chip,html.dark .related-card,html.dark .gj-tl-card{background:#1a2420!important;color:#e8f0ec!important;border-color:#2a3a33!important}
html.dark .gj-stat-card b,html.dark .gj-weather-card .tmp{color:#3ecf8e!important}
html.dark .gj-suggest{background:#15201b!important;border-color:#2a3a33!important}
html.dark .gj-suggest a{color:#e8f0ec!important;border-color:#2a3a33!important}
html.dark .gj-suggest a:hover{background:#1a2a22!important}
html.dark .gj-suggest .sec{color:#9bb0a6!important}

/* —— Engagement: ذخیره خبر و صفحات شخصی —— */
.gj-eng-actions{
  display:flex;
  flex-wrap:wrap;
  gap:.6rem;
  align-items:center;
  margin:1.25rem 0 1.5rem;
  padding:1rem;
  background:linear-gradient(135deg,#f3faf6,#ffffff);
  border:1px solid #d5e8dc;
  border-radius:14px;
}
.gj-save-btn{
  display:inline-flex;
  align-items:center;
  gap:.45rem;
  padding:.65rem 1.15rem;
  border:none;
  border-radius:999px;
  background:linear-gradient(135deg,#0b5e2e,#148a45);
  color:#fff;
  font-weight:700;
  font-size:.95rem;
  cursor:pointer;
  box-shadow:0 6px 16px rgba(11,94,46,.28);
  transition:transform .15s ease, box-shadow .15s ease, background .2s ease;
}
.gj-save-btn:hover{ transform:translateY(-1px); box-shadow:0 8px 20px rgba(11,94,46,.35); }
.gj-save-btn:disabled{ opacity:.7; cursor:wait; }
.gj-save-btn.is-saved{
  background:linear-gradient(135deg,#b45309,#d97706);
  box-shadow:0 6px 16px rgba(180,83,9,.25);
}
.gj-save-btn .gj-save-icon{ font-size:1.1rem; line-height:1; }
.gj-eng-link{
  display:inline-flex;
  align-items:center;
  padding:.55rem .95rem;
  border-radius:999px;
  background:#fff;
  border:1px solid #cfe0d6;
  color:#0b5e2e;
  text-decoration:none;
  font-size:.88rem;
  font-weight:600;
  transition:background .15s,border-color .15s;
}
.gj-eng-link:hover{ background:#e8f5ee; border-color:#0b5e2e; }

.gj-eng-page{ padding:1.5rem 1rem 2.5rem; max-width:1100px; margin:0 auto; }
.gj-eng-page-head{ margin-bottom:1.5rem; }
.gj-eng-page-head .category-title{ margin:0 0 .5rem; color:#0b5e2e; font-size:1.55rem; }
.gj-eng-lead{ color:#64748b; margin:0 0 1rem; line-height:1.8; }
.gj-eng-tabs{
  display:flex;
  flex-wrap:wrap;
  gap:.45rem;
  margin-top:.75rem;
}
.gj-eng-tabs a{
  padding:.5rem 1rem;
  border-radius:999px;
  background:#f1f5f4;
  color:#334155;
  text-decoration:none;
  font-size:.88rem;
  font-weight:600;
  border:1px solid transparent;
}
.gj-eng-tabs a.is-active,
.gj-eng-tabs a:hover{
  background:#0b5e2e;
  color:#fff;
}
.gj-eng-grid{ margin-top:.5rem; }
.gj-eng-meta-extra{ font-size:.78rem; color:#94a3b8; margin-top:.35rem; }
.gj-empty-state{
  padding:2.5rem 1.25rem;
  text-align:center;
  background:#f8faf9;
  border:1px dashed #c5d8cc;
  border-radius:16px;
  color:#64748b;
}
.news-card-link{ display:flex; flex-direction:column; height:100%; color:inherit; text-decoration:none; }
.news-card-link:hover h3{ color:#0b5e2e; }

html.dark-mode .gj-eng-actions,
html.dark .gj-eng-actions,
body.dark-mode .gj-eng-actions{
  background:linear-gradient(135deg,#1a2e24,#16251e);
  border-color:#2d4a3a;
}
html.dark-mode .gj-eng-link,
html.dark .gj-eng-link,
body.dark-mode .gj-eng-link{
  background:#1e2f28;
  border-color:#3d5c4a;
  color:#a7f3c0;
}
html.dark-mode .gj-eng-tabs a,
html.dark .gj-eng-tabs a{ background:#1e2f28; color:#cbd5e1; }
html.dark-mode .gj-empty-state,
html.dark .gj-empty-state{
  background:#15231c;
  border-color:#2d4a3a;
  color:#94a3b8;
}
@media (max-width:640px){
  .gj-save-btn{ width:100%; justify-content:center; }
  .gj-eng-actions{ padding:.85rem; }
}
