/* OmranTheme 8.0.9 — article containment on phones, tablets and desktops.
   These rules affect presentation only, never stored article content. */
body.single .post-content-body,
body.single .alomran-page-content,
body.single .alomran-single {
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
}

/* Progressive fallback when JavaScript is unavailable. Native table children
   remain table rows/cells; do not turn poems or data rows into cards. */
body.alomran-site.single .post-content-body table {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    table-layout: auto;
    box-sizing: border-box;
}
body.alomran-site.single .post-content-body table[style] {
    min-width: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
}
body.alomran-site.single .post-content-body table :is(td, th) {
    max-width: none;
    white-space: normal;
    overflow-wrap: normal;
    word-break: normal;
    vertical-align: top;
    box-sizing: border-box;
}
body.alomran-site.single .post-content-body table :is(td, th) :is(p, div) {
    max-width: 100%;
    margin-inline: 0;
    padding-inline: 0;
}

.post-content-body .alomran-table-frame {
    clear: both;
    min-width: 0;
    max-width: 100%;
    margin-block: 1.25em;
}
.post-content-body .alomran-table-scroll {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0 !important;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    box-sizing: border-box;
    scrollbar-width: auto;
}
.post-content-body .alomran-table-scroll:focus-visible {
    outline: 2px solid var(--alomran-green, #284a31);
    outline-offset: 3px;
}
body.alomran-site.single .post-content-body .alomran-table-scroll > table {
    display: table;
    width: 100% !important;
    min-width: max(100%, var(--alomran-table-min-width, 16rem)) !important;
    max-width: none !important;
    table-layout: auto !important;
    overflow: visible;
    margin-inline: 0;
    margin-block: 0;
}
body.alomran-site.single .post-content-body .alomran-table-scroll > table :is(td, th) {
    /* Legacy Word widths otherwise squeeze cells or outrank the new layout. */
    width: auto !important;
    max-width: none !important;
    min-width: 0;
}
body.alomran-site.single .post-content-body .alomran-table-scroll > table table {
    display: table;
    width: auto;
    max-width: 100%;
}
.post-content-body .alomran-table-hint {
    margin: 0 0 0.45rem;
    padding: 0;
    font-size: 0.82em;
    color: var(--alomran-text-muted, #59645d);
    text-align: start;
    line-height: 1.65;
}
.post-content-body .alomran-table-hint[hidden] { display: none; }

body.single .post-content-body :is(img, video, .wp-caption, figure) {
    max-width: 100%;
    box-sizing: border-box;
}
body.single .post-content-body :is(img, video) { height: auto; }
body.single .post-content-body :is(img, video)[style] {
    max-width: 100% !important;
    height: auto !important;
}
body.single .post-content-body iframe { max-width: 100%; }
body.single .post-content-body iframe[style] { max-width: 100% !important; }
body.single .post-content-body iframe:is([src*="youtube.com/embed/"], [src*="youtube-nocookie.com/embed/"], [src*="player.vimeo.com/"]) {
    width: 100%;
    aspect-ratio: 16 / 9;
    height: auto !important;
}

/* Long code scrolls locally; Arabic prose and mixed-direction links do not
   impose an unbreakable minimum width on the article column. */
body.single .post-content-body pre {
    unicode-bidi: isolate;
    text-align: start;
    white-space: pre;
    overflow: auto;
    max-width: 100%;
    min-width: 0;
    padding: 1rem;
    box-sizing: border-box;
    background: #f3f5f3;
    border: 1px solid var(--alomran-border-soft, #dce3dd);
    border-radius: 6px;
    font-size: 0.85em;
}
body.single .post-content-body pre:has(> code):not([dir]) {
    direction: ltr;
    text-align: left;
}
body.single .post-content-body pre code {
    white-space: inherit;
    overflow-wrap: normal;
    word-break: normal;
}
body.single .post-content-body a,
body.single .post-content-body :not(pre) > code {
    overflow-wrap: anywhere;
}
body.single .post-content-body .wp-block-table {
    max-width: 100%;
    margin-inline: 0;
}

@media (max-width: 767px) {
    body.single .post-content-body :is(img.alignleft, img.alignright, .wp-caption.alignleft, .wp-caption.alignright) {
        float: none;
        margin-inline: auto;
        display: block;
    }
    body.alomran-site.single .post-content-body table :is(td, th) {
        padding-inline: 0.5rem;
    }
}
@media print {
    .post-content-body .alomran-table-hint { display: none; }
    .post-content-body .alomran-table-scroll { overflow: visible; }
    body.alomran-site.single .post-content-body .alomran-table-scroll > table {
        min-width: 0 !important;
        width: 100% !important;
    }
    body.single .post-content-body pre { white-space: pre-wrap; overflow-wrap: anywhere; }
}
