@font-face {
  font-family: "IRANYekanX";
  src: url("/IRANYekanXVF.woff2") format("woff2-variations");
  font-style: normal;
  font-weight: 100 1000;
  font-display: swap;
}

:root {
  --background: #f7f8fa;
  --surface: #ffffff;
  --text: #17212b;
  --muted: #6c7885;
  --line: #e4e8ec;
  --primary: #126b5b;
  --primary-hover: #0b5447;
  font-family: "IRANYekanX", Tahoma, sans-serif;
  color: var(--text);
  background: var(--background);
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: var(--background); color: var(--text); line-height: 1.8; }
a { color: inherit; }
button, input, select { font: inherit; }
.source-filter { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; }
.source-filter select { padding: 8px 12px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); color: var(--text); }
.source-filter select:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.site-header { height: 72px; display: flex; align-items: center; border-bottom: 1px solid var(--line); background: var(--surface); }
.site-header, .page-shell { padding-right: max(24px, calc((100% - 1080px) / 2)); padding-left: max(24px, calc((100% - 1080px) / 2)); }
.brand { color: var(--primary); font-size: 1.45rem; font-weight: 800; text-decoration: none; }
.page-shell { padding-top: 44px; padding-bottom: 64px; }
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
h1, h2, p { margin-top: 0; }
.page-heading h1 { margin-bottom: 2px; font-size: clamp(1.65rem, 4vw, 2.2rem); }
.page-heading p { margin-bottom: 0; color: var(--muted); font-size: 0.9rem; }
.search { display: flex; width: min(420px, 100%); }
.search input { min-width: 0; flex: 1; height: 46px; padding: 0 14px; border: 1px solid var(--line); border-radius: 0 9px 9px 0; background: var(--surface); color: var(--text); outline: none; }
.search input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(18, 107, 91, 0.1); }
.search button { height: 46px; padding: 0 20px; border: 0; border-radius: 9px 0 0 9px; background: var(--primary); color: white; cursor: pointer; }
.search button:hover { background: var(--primary-hover); }
.news-list { display: grid; gap: 14px; }
.news-item { display: grid; grid-template-columns: 190px minmax(0, 1fr); min-height: 155px; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.news-image { width: 100%; height: 100%; min-height: 155px; object-fit: cover; background: #e9edef; }
.news-image.empty { display: grid; place-items: center; color: var(--muted); font-size: 0.8rem; }
.news-content { min-width: 0; padding: 18px 20px; }
.news-date { display: block; margin-bottom: 5px; color: var(--muted); font-size: 0.78rem; }
.news-title { margin-bottom: 7px; font-size: 1.05rem; line-height: 1.65; }
.news-title a { text-decoration: none; }
.news-title a:hover { color: var(--primary); }
.news-lead { margin-bottom: 0; color: var(--muted); font-size: 0.88rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pagination { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 30px; }
.page-link { min-width: 39px; height: 39px; display: grid; place-items: center; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--text); text-decoration: none; }
.page-link:hover { border-color: var(--primary); color: var(--primary); }
.page-link.current { border-color: var(--primary); background: var(--primary); color: white; pointer-events: none; }
.page-link.disabled { opacity: 0.45; pointer-events: none; }
.ellipsis { padding: 0 5px; color: var(--muted); }
.message { padding: 32px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--muted); text-align: center; }
.article-shell { width: calc(100% - 48px); max-width: 900px; margin: 0 auto; padding-top: 34px; padding-bottom: 70px; }
.back-link { display: inline-block; margin-bottom: 20px; color: var(--primary); text-decoration: none; }
.article-detail { overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.article-cover { display: block; width: 100%; max-height: 480px; object-fit: cover; background: #e9edef; }
.article-inner { padding: clamp(24px, 5vw, 48px); }
.article-date { color: var(--muted); font-size: 0.84rem; }
.article-detail h1 { margin: 10px 0 18px; font-size: clamp(1.55rem, 4vw, 2.35rem); line-height: 1.55; }
.article-lead { padding: 15px 18px; border-right: 3px solid var(--primary); background: #f3f8f6; font-size: 1.02rem; font-weight: 550; }
.article-body { margin-top: 28px; white-space: pre-wrap; font-size: 1rem; line-height: 2.15; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

@media (max-width: 700px) {
  .site-header, .page-shell { padding-right: 16px; padding-left: 16px; }
  .page-shell { padding-top: 28px; }
  .page-heading { align-items: stretch; flex-direction: column; }
  .search { width: 100%; }
  .news-item { grid-template-columns: 1fr; }
  .news-image { height: 200px; min-height: 0; }
  .article-shell { width: calc(100% - 32px); padding-top: 22px; }
  .article-inner { padding: 22px; }
}
