/* Bahethat 2026, "pages A" overrides: the few pieces the page bundles do not cover for real data
   (artwork without a fixed ratio, items without an image, program travel, embedded PDF viewer, comment list).
   Loaded after the page bundle; design tokens only. */

/* Items without a featured image: a quiet plate with the brand mark. */
.cm-art.typo, .cm-img.typo, .nw-th.typo, .nw-img.typo, .nw-lead-img.typo, .ks-file-img.typo { display: grid; place-items: center; aspect-ratio: var(--ar, 4 / 3); background: var(--beige-100); color: var(--wine); }
.cm-art.typo .mark, .cm-img.typo .mark, .nw-th.typo .mark, .nw-img.typo .mark, .nw-lead-img.typo .mark, .ks-file-img.typo .mark { width: 28%; max-width: 56px; height: auto; opacity: .55; }
.nw-th.typo, .nw-img.typo, .nw-lead-img.typo { aspect-ratio: 1; }

/* Community page: the site's artwork is landscape; show it whole at its own ratio. */
.page-community .cm-prog .cm-img,
.page-community .cm-ev .cm-img,
.page-community .cm-ini .cm-img { aspect-ratio: var(--ar, 1); }
.page-community .cm-img img { height: 100%; object-fit: contain; background: var(--panel); }

/* About: a child page without a list. */
.page-about .ab-prose { margin-top: 20px; }

/* Program: «رحلة البرنامج». */
.grp-community .pa-travel { margin-top: clamp(32px, 3vw, 48px); }
.grp-community .pa-travel-list { display: grid; border-top: 1px solid var(--wine); margin-top: 12px; }
.grp-community .pa-stop { border-bottom: 1px solid var(--rule); }
.grp-community .pa-stop > summary { display: flex; align-items: flex-start; gap: 14px; min-height: 64px; padding: 16px 0; cursor: pointer; color: var(--wine); }
.grp-community .pa-stop > summary::-webkit-details-marker { display: none; }
.grp-community .pa-stop > summary .icon { flex: none; margin-top: 6px; transition: transform .2s var(--ease); }
.grp-community .pa-stop[open] > summary .icon { transform: rotate(180deg); }
.grp-community .pa-stop-n { flex: none; width: 2rem; color: var(--gold-ink); font-weight: 500; }
.grp-community .pa-stop-t { flex: 1; display: grid; gap: 4px; }
.grp-community .pa-stop-t b { font-weight: 500; font-size: 1.0625rem; line-height: 1.6; }
.grp-community .pa-stop-t .meta { color: var(--grey-ink); }
.grp-community .pa-stop-body { padding: 0 0 20px 0; padding-inline-start: 2rem; }
.grp-community .pa-footer { margin-top: 32px; }
.grp-community .cm-join-state.is-open .icon { color: var(--gold-ink); }
.grp-community .cm-join .cm-factlist { margin-block: 12px; }

/* Kashaf issue: the in-page PDF viewer fills the frame. */
.arc .ks-frame.pa-embed { display: block; padding: 0; }
.arc .ks-frame.pa-embed > *, .arc .ks-frame.pa-embed .wp-block-pdfemb-pdf-embedder-viewer { display: block; width: 100%; max-width: 100%; }
.arc .ks-viewer .prose { margin-bottom: 16px; }

/* News comments. */
.arc .pa-comments { display: grid; gap: 0; margin-bottom: 32px; }
.arc .pa-comments .children { margin-inline-start: clamp(16px, 3vw, 40px); border-inline-start: 2px solid var(--rule); padding-inline-start: 16px; }
.arc .pa-comment > article { padding-block: 16px; border-bottom: 1px solid var(--rule); }
.arc .pa-comment .meta { display: flex; flex-wrap: wrap; gap: 4px 12px; color: var(--grey-ink); font-size: .875rem; }
.arc .pa-comment .meta b { color: var(--wine); font-weight: 500; }
.arc .pa-comment-text { margin-top: 8px; line-height: 1.9; }
.arc .pa-reply a { display: inline-flex; align-items: center; min-height: 44px; color: var(--wine); text-decoration: underline; text-decoration-color: var(--gold); text-underline-offset: 4px; }
.arc #cancel-comment-reply-link { display: inline-flex; align-items: center; min-height: 44px; margin-inline-start: 12px; font-size: .875rem; }

@media (prefers-reduced-motion: reduce) {
  .grp-community .pa-stop > summary .icon { transition: none; }
}
