/* ==========================================================================
   العاصمة — the archives (a section, a tag, all the news, a search)
   The prototype draws no archive page, so these are its own rules for the
   pieces an archive is built from, as they stand in article.html (the
   head), jerusalem.html (the log) and home.html (the most read) — copied,
   not changed.
   ========================================================================== */

/* article.html — the head */
.a-head { padding-block: var(--s-7) var(--s-6); }
.a-head__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--col-gap); }
.a-head__main { grid-column: 1 / span 9; display: grid; gap: var(--s-4); }
.a-head nav a { min-height: 44px; display: inline-flex; align-items: center; }
.a-head__side { grid-column: 10 / span 3; align-self: end; display: grid; gap: var(--s-4); }
.a-head .hl-1 { font-size: clamp(2rem, 1.1rem + 2.9vw, 3.5rem); }
.times { display: grid; gap: 2px; font-size: var(--t-meta); color: var(--ink-3); }
.times b { color: var(--ink); font-weight: 700; font-variant-numeric: tabular-nums; }

/* jerusalem.html — «سجل المدار» */
.feed-wrap { display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); gap: var(--s-7); }
.feed { display: grid; }
.feed article { display: grid; grid-template-columns: 88px minmax(0, 1fr) 150px; gap: var(--s-4); padding-block: var(--s-4); border-top: 1px solid var(--rule); align-items: start; }
.feed article .when { font-size: .86rem; font-weight: 800; text-align: end; line-height: 1.8; font-variant-numeric: tabular-nums; }
.feed article .when small { display: block; color: var(--ink-3); font-weight: 400; font-size: .8rem; }
.feed article h3 { font-size: var(--t-3); font-weight: 700; line-height: 1.45; margin-block: 6px; }
.feed article p { color: var(--ink-2); font-size: var(--t-sm); }
.feed article .frame { aspect-ratio: 3 / 2; }
.feed__status { font-size: var(--t-sm); color: var(--ink-3); padding-block: 10px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* home.html — «الأكثر مشاهدة» */
.mostread__head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: var(--s-2); }
.mostread__head h2 { font-size: var(--fs-h4); font-weight: 800; }

@media (max-width: 1100px) {
  .a-head__main, .a-head__side { grid-column: 1 / -1; }
  .feed-wrap { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .feed article { grid-template-columns: 64px minmax(0, 1fr); }
  .feed article .frame { display: none; }
}
@media (max-width: 560px) {
  .a-head { padding-top: var(--s-5); }
}

/* ── an archive with nothing beside it: the list takes the row ── */
.feed-wrap:not(:has(> aside)) { grid-template-columns: minmax(0, 1fr); }
