/*
 * Hand-written overrides for the Makeen site. site.css is a compiled export that gets overwritten,
 * so changes that must survive live here (loaded after site.css in app/Views/site/layout.php).
 */

/* Home search box: rounded corners. No overflow:hidden (it would clip the dropdowns), so the
   cells that paint a background (the first select's hover, the submit button) round their own corners. */
#search {
    border-radius: 14px;
}

#search > [data-hero-select="status"] {
    border-start-start-radius: 14px;
    border-start-end-radius: 14px;
}

#search > button[type="submit"] {
    border-end-start-radius: 14px;
    border-end-end-radius: 14px;
}

@media (min-width: 1024px) {
    #search > [data-hero-select="status"] {
        border-start-end-radius: 0;
        border-end-start-radius: 14px;
    }

    #search > button[type="submit"] {
        border-start-end-radius: 14px;
        border-end-start-radius: 0;
    }
}

/* Home stats title ("من سبع وحدات سنوياً إلى شركة مدرجة"): one line from tablets up (was capped at max-w-3xl). */
#stats-title {
    max-width: none;
}

@media (min-width: 768px) {
    #stats-title {
        white-space: nowrap;
    }
}

/* Project page "Other advantages" on phones: one per row, round outlined icon beside the label, hairlines between rows. */
@media (max-width: 767.98px) {
    #advantages ul {
        grid-template-columns: 1fr;
        row-gap: 0;
        margin-top: 2.5rem;
    }

    #advantages li {
        flex-direction: row;
        align-items: center;
        gap: 1.25rem;
        padding-block: 1.25rem;
        border-top: 1px solid rgb(246 242 236 / 0.14);
    }

    #advantages li:last-child {
        border-bottom: 1px solid rgb(246 242 236 / 0.14);
    }

    #advantages li > span[aria-hidden="true"] {
        width: 3.25rem;
        height: 3.25rem;
        border-radius: 9999px;
        border-color: rgb(246 242 236 / 0.3);
        background: transparent;
    }

    #advantages li > span[aria-hidden="true"] svg {
        width: 24px;
        height: 24px;
    }
}

/* Home stats: the labels under the figures were too small (text-sm / Arabic text-base). */
html[lang="ar"] section[aria-labelledby="stats-title"] p.display + p {
    margin-top: 1rem;
    font-size: 1rem;
    line-height: 1.5;
    color: rgb(246 242 236 / 0.75);
}

html[lang="ar"] section[aria-labelledby="stats-title"] p.display + p {
    font-size: 1.2rem;
}

@media (min-width: 1024px) {
    html[lang="ar"] section[aria-labelledby="stats-title"] p.display + p {
        font-size: 1.125rem;
    }

    html[lang="ar"] section[aria-labelledby="stats-title"] p.display + p {
        font-size: 1.4rem;
    }
}

/* Home media section: a news item's title sits below the section title (h2, 3rem), so it is a step smaller. */
[data-mpanel-text] > span.display {
    font-size: clamp(1.4rem, min(2.4vw, 4svh), 2.125rem);
}

/* ---------------------------------------------------------------------------------------------------------------
 * One heading scale on every page. The views were exported with many slightly different sizes per section;
 * these rules make every section title the same size, and every subheading the same (smaller) size.
 *   Section title (h2): 30px → 36px (md) → 48px (lg)
 *   Subheading (h3, .section-subtitle): 24px → 30px (lg)
 * Left alone: page hero h1s, small eyebrow-style h2s (no .display), card titles that clamp to N lines or truncate,
 * and the full-screen featured-project names.
 * ------------------------------------------------------------------------------------------------------------- */
#main section h2.display:not(.sr-only) {
    font-size: 1.875rem;
    line-height: 1.15;
}

html[lang="ar"] #main section h2.display:not(.sr-only) {
    line-height: 1.4;
}

#main .section-subtitle,
#main section h3.display:not([class*="line-clamp"]):not(.truncate):not([id^="featured-"]) {
    font-size: 1.5rem;
    line-height: 1.25;
}

html[lang="ar"] #main .section-subtitle,
html[lang="ar"] #main section h3.display:not([class*="line-clamp"]):not(.truncate):not([id^="featured-"]) {
    line-height: 1.45;
}

@media (min-width: 768px) {
    #main section h2.display:not(.sr-only) {
        font-size: 2.25rem;
    }
}

@media (min-width: 1024px) {
    #main section h2.display:not(.sr-only) {
        font-size: 3rem;
    }

    #main .section-subtitle,
    #main section h3.display:not([class*="line-clamp"]):not(.truncate):not([id^="featured-"]) {
        font-size: 1.875rem;
    }
}

/* Body copy that was set at 1.05rem (descriptions, intros, leads) is 1.19rem. Same breakpoints as the
   compiled utilities they replace (md = 48rem, lg = 64rem). Unlayered, so these win over site.css's utilities layer. */
html[lang="ar"] .text-\[1\.05rem\],
html[lang="ar"] .\[html\[lang\=ar\]_\&\]\:text-\[1\.05rem\] {
    font-size: 1.19rem;
}

@media (min-width: 48rem) {
    html[lang="ar"] .md\:text-\[1\.05rem\] {
        font-size: 1.19rem;
    }
}

@media (min-width: 64rem) {
    html[lang="ar"] .lg\:text-\[1\.05rem\] {
        font-size: 1.19rem;
    }
}

/* Small text was too small (footer especially): Tailwind's text-sm token .875rem → .999rem, site-wide.
   Unlayered :root beats site.css's @layer theme. Line height stays text-sm's ratio. */
html[lang="ar"] {
    --text-sm: .999rem;
}

/* Footer links and contact lines (0.95rem) stay a step above text-sm. */
html[lang="ar"] footer .text-\[0\.95rem\] {
    font-size: 1.07rem;
}

/* Home timeline: the year markers under the progress line read too small (text-sm). */
html[lang="ar"] [data-timeline] [data-year] {
    font-size: 1.15rem;
}

@media (min-width: 1024px) {
    html[lang="ar"] [data-timeline] [data-year] {
        font-size: 1.4rem;
    }
}

/* Home search dropdowns: the options, the search-in-list field (0.9rem, built in js/pages/home-v2.js)
   and the chosen value shown in each field (0.95rem) were too small. */
html[lang="ar"] [data-hero-select] [role="option"],
html[lang="ar"] [data-hero-select] input[role="combobox"],
html[lang="ar"] [data-hero-select] > button {
    font-size: 1.1rem;
}

/* About › Products: rounded image cards and filter buttons. The card already clips (overflow-hidden). */
[data-product-tile] > button,
[data-product-tile] > button > span.theme-dark {
    border-radius: 14px;
}

button[data-tab][aria-pressed] {
    border-radius: 12px;
}

/* About › Board: the member card's text was too small (0.9rem labels, 0.95rem list, 1rem bio). */
html[lang="ar"] [data-board] p.kashida,
html[lang="ar"] [data-board] h4.kashida {
    font-size: 1.1rem;
}

html[lang="ar"] [data-board] p.leading-relaxed {
    font-size: 1.15rem;
}

html[lang="ar"] [data-board] li.leading-relaxed {
    font-size: 1.1rem;
}

/* …and the same in the member dialog (js/pages/about.js appends it to <body>, outside [data-board]). */
html[lang="ar"] [aria-labelledby="ir-member-name"] .kashida,
html[lang="ar"] [aria-labelledby="ir-member-name"] li.leading-relaxed {
    font-size: 1.1rem;
}

/* About › Intro ("عن مكين", "رؤيتنا", "رسالتنا"): the vision/mission panel titles are h3 but stand level with the
   "عن مكين" h2, so they take the section-title size, not the subheading one. Their text was too small too. */
#main#main [data-intro] h3.display {
    font-size: 1.875rem;
    line-height: 1.15;
}

html[lang="ar"] #main#main [data-intro] h3.display {
    line-height: 1.4;
}

html[lang="ar"] [data-intro] p.kashida.leading-relaxed {
    font-size: 1.2rem;
}

html[lang="ar"] [data-intro] p.max-w-xl.leading-relaxed:not(.kashida) {
    font-size: 1.1rem;
}

@media (min-width: 768px) {
    #main#main [data-intro] h3.display {
        font-size: 2.25rem;
    }

    html[lang="ar"] [data-intro] p.kashida.leading-relaxed {
        font-size: 1.4rem;
    }

    html[lang="ar"] [data-intro] p.max-w-xl.leading-relaxed:not(.kashida) {
        font-size: 1.25rem;
    }
}

@media (min-width: 1024px) {
    #main#main [data-intro] h3.display {
        font-size: 3rem;
    }
}

/* The active filter's gold fill is its own layer (moved between buttons by js/pages/about.js): round it too,
   1px less than the button so it sits flush inside the border. */
[data-tab-fill] {
    border-radius: 11px;
}

/* About › Awards: rounded logo plate, and the "read the news" link as a round arrow button inside it. */
[data-award-plate] {
    border-radius: 12px;
}

/* A pill with the label and the arrow, centred on the plate's bottom edge. */
.award-go {
    position: absolute;
    inset-block-end: 0.75rem;
    left: 50%;
    transform: translateX(-50%);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    background: var(--color-forest-deep, #243026);
    color: #f6f2ec;
    font-size: 0.95rem;
    font-weight: 500;
    line-height: 1.2;
    box-shadow: 0 8px 18px -8px rgb(11 16 12 / 0.5);
    transition: background-color 0.3s ease, color 0.3s ease, transform 0.5s var(--ease-cinema, ease);
}

html[lang="ar"] .award-go {
    font-size: 1.05rem;
}

.group:hover .award-go,
.group:focus-visible .award-go {
    background: var(--color-clay, #c89764);
    color: #243026;
    transform: translateX(-50%) scale(1.05);
}

/* Projects / units filter panel (fieldset[data-group], built in js/pages/projects.js): text was too small. */
html[lang="ar"] fieldset[data-group] legend {
    font-size: 0.8rem;
}

html[lang="ar"] fieldset[data-group] legend {
    font-size: 1.1rem;
}

html[lang="ar"] fieldset[data-group] label,
html[lang="ar"] label[class~="text-[0.92rem]"]:has(> input[type="checkbox"]) {
    font-size: 1.08rem;
    padding-block: 0.45rem;
}

html[lang="ar"] fieldset[data-group] label .tabular-nums,
html[lang="ar"] label[class~="text-[0.92rem]"]:has(> input[type="checkbox"]) .tabular-nums {
    font-size: 0.95rem;
}

html[lang="ar"] fieldset[data-group] label > span.border,
html[lang="ar"] label[class~="text-[0.92rem]"]:has(> input[type="checkbox"]) > span.border {
    width: 20px;
    height: 20px;
}

html[lang="ar"] fieldset[data-group] ul {
    max-height: 19rem;
}

/* Projects cards: the type line ("أدوار") and the location line ("الشرقية") were too small. */
html[lang="ar"] p[data-line][class~="text-[0.72rem]"] {
    font-size: 0.82rem;
}

html[lang="ar"] p[data-line][class~="text-[0.72rem]"] {
    font-size: 1.05rem;
}

html[lang="ar"] p[data-line][class~="text-sm"][class~="flex"] {
    font-size: 1.1rem;
}

html[lang="ar"] p[data-line][class~="text-sm"][class~="flex"] svg {
    width: 18px;
    height: 18px;
}

/* Projects catalogue (grid + list views): status tags, location / type lines and the "view project" link. */
html[lang="ar"] [data-catalogue] li[class~="text-[0.7rem]"] {
    font-size: 0.8rem;
}

html[lang="ar"] [data-catalogue] li[class~="text-[0.7rem]"] {
    font-size: 1rem;
}

html[lang="ar"] [data-catalogue] p[class~="text-sm"][class~="text-ink/60"] {
    font-size: 1.1rem;
}

html[lang="ar"] [data-catalogue] p[class~="text-sm"][class~="text-ink/50"] {
    font-size: 1.05rem;
}

html[lang="ar"] [data-catalogue] p[class~="text-sm"] svg {
    width: 18px;
    height: 18px;
}

html[lang="ar"] [data-catalogue] .link-arrow {
    font-size: 1.05rem;
}

/* With the pill at the bottom, the logo centres in the space above it instead of the whole plate. */
[data-award-plate]:has(.award-go) > img {
    inset-block-end: 3.25rem;
    max-height: 52%;
}

/* Project page › Units (list, grid and plan views, [data-pd-units]): the many tiny sizes (0.6–0.74rem labels,
   text-xs specs, text-sm figures) get a readable floor; the Arabic variants a step above. */
html[lang="ar"] [data-pd-units] :is([class~="text-[0.6rem]"], [class~="text-[0.62rem]"], [class~="text-[0.66rem]"], [class~="text-[0.68rem]"], [class~="text-[0.72rem]"], [class~="text-[0.74rem]"]) {
    font-size: 0.82rem;
}

html[lang="ar"] [data-pd-units] [class~="text-xs"] {
    font-size: 0.92rem;
}

html[lang="ar"] [data-pd-units] [class~="text-sm"],
html[lang="ar"] [data-pd-units] [class~="text-[0.92rem]"] {
    font-size: 1.08rem;
}

html[lang="ar"] [data-pd-units] [class*="_&]:text-[0.8rem]"] {
    font-size: 1.02rem;
}

html[lang="ar"] [data-pd-units] :is([class*="_&]:text-[0.85rem]"], [class*="_&]:text-[0.9rem]"], [class*="_&]:text-[0.92rem]"]) {
    font-size: 1.1rem;
}

/* Unit page › details: labels (الغرف، الدور، المميزات…) and feature chips were too small; the three actions sit on
   one row from tablets up instead of wrapping the third. */
html[lang="ar"] section[aria-labelledby="unit-details"] [class~="text-[0.75rem]"] {
    font-size: 0.85rem;
}

html[lang="ar"] section[aria-labelledby="unit-details"] [class*="_&]:text-[0.9rem]"] {
    font-size: 1.08rem;
}

html[lang="ar"] section[aria-labelledby="unit-details"] li[class~="text-sm"] {
    font-size: 1.1rem;
}

html[lang="ar"] section[aria-labelledby="unit-details"] li[class~="text-sm"] svg {
    width: 18px;
    height: 18px;
}

@media (min-width: 640px) {
    html[lang="ar"] section[aria-labelledby="unit-details"] div.grid:has(> [data-register]) {
        grid-template-columns: none;
        grid-auto-flow: column;
        grid-auto-columns: minmax(0, 1fr);
    }

    html[lang="ar"] section[aria-labelledby="unit-details"] div.grid:has(> [data-register]) > .btn {
        padding-inline: 1rem;
        white-space: nowrap;
    }
}

/* Unit drawer (js/unit-drawer.js, [data-drawer-body]): fact values, labels, badges and captions were too small. */
html[lang="ar"] [data-drawer-body] [class~="text-[0.95rem]"] {
    font-size: 1.15rem;
}

html[lang="ar"] [data-drawer-body] [class~="text-[0.75rem]"],
html[lang="ar"] [data-drawer-body] [class~="text-[0.72rem]"] {
    font-size: 0.85rem;
}

html[lang="ar"] [data-drawer-body] [class*="_&]:text-[0.9rem]"],
html[lang="ar"] [data-drawer-body] [class*="_&]:text-[0.85rem]"] {
    font-size: 1.05rem;
}

html[lang="ar"] [data-drawer-body] [class~="text-[0.85rem]"],
html[lang="ar"] [data-drawer-body] [class~="text-sm"] {
    font-size: 1.05rem;
}

/* Unit drawer header: the close button sits in the far corner, a little apart from the prev / next arrows,
   without a border or divider. */
[data-drawer-close] {
    margin-inline-start: 0.75rem;
}

/* Project page, "Virtual tour & Location" cards (partials/project/tour-location.php): both buttons on one row
   from desktop width; tighter padding and tracking so the longer pair fits half the container. */
@media (min-width: 1024px) {
    .pd-tl-btns {
        flex-wrap: nowrap;
    }

    .pd-tl-btns .btn {
        flex: 0 1 auto;
        min-width: 0;
        padding-inline: 1.25rem;
        letter-spacing: .12em;
    }
}

/* Footer › "Apartments" links: they inherit the body size, which reads large in the Latin face. English only. */
html:not([lang="ar"]) nav[aria-labelledby="footer-apartments"] a.rounded-full {
    font-size: 0.875rem;
    padding: 0.4rem 0.9rem;
}

/* Project page section tabs (Project Units, Project Information…): text-lg / lg:text-xl read large in the Latin face.
   English only. */
html:not([lang="ar"]) [data-pd-nav-link] {
    font-size: 1rem;
}

@media (min-width: 1024px) {
    html:not([lang="ar"]) [data-pd-nav-link] {
        font-size: 1.0625rem;
    }
}

/* Project page hero: the location line (lg:text-[2.6rem]) competed with the project name; it steps down, and the
   large name is capped a little lower. */
section[aria-labelledby="pd-title"] p[class~="lg:text-[2.6rem]"] {
    font-size: 1.25rem;
}

@media (min-width: 640px) {
    section[aria-labelledby="pd-title"] p[class~="lg:text-[2.6rem]"] {
        font-size: 1.4rem;
    }
}

@media (min-width: 1024px) {
    section[aria-labelledby="pd-title"] p[class~="lg:text-[2.6rem]"] {
        font-size: 1.6rem;
    }

    #pd-title[class~="lg:text-[min(7.5rem,14svh)]"] {
        font-size: min(6rem, 12svh);
    }
}

/* Project units › plan view legend (Sale 47, Rent 0…) and its hint: large in the Latin face. English only. */
html:not([lang="ar"]) [data-pd-units] [class~="lg:text-[1.05rem]"][class~="font-medium"] {
    font-size: 0.9rem;
}

html:not([lang="ar"]) [data-pd-units] [class~="max-w-xl"][class~="text-base"] {
    font-size: 0.9rem;
}

html:not([lang="ar"]) [data-pd-units] [class~="lg:text-[1.05rem]"][class~="font-medium"] > span[class~="h-[18px]"] {
    width: 15px;
    height: 15px;
}

/* Projects page status chips and the Filters button: sentence case instead of spaced capitals. English only. */
html:not([lang="ar"]) [data-catalogue] :is(button[data-status], [data-open-filters]) {
    text-transform: none;
    letter-spacing: normal;
    font-size: 0.875rem;
}

/* Unit drawer actions: Register interest and View unit details share one row (they wrapped in English, whose
   spaced capitals are wider). Three actions (with the virtual tour) may still wrap. */
[data-drawer-actions]:not(:has(> :nth-child(3))) {
    flex-wrap: nowrap;
}

[data-drawer-actions] > .btn {
    min-width: 0;
    white-space: nowrap;
    padding-inline: 1rem;
}

html:not([lang="ar"]) [data-drawer-actions] > .btn {
    letter-spacing: 0.08em;
}

/* Fact values break between words only ("Apartment|s" was split mid-word). */
[data-drawer-body] .break-words {
    overflow-wrap: normal;
    word-break: normal;
}

/* Unit page: the photos now follow the details, so "similar units" (designed to continue the light details section)
   gets its own top space after the dark gallery. */
[data-unit-photos] + section[aria-labelledby="unit-related"] {
    padding-top: 5rem;
}

/* Unit page › similar units: the card titles are cards, not section subheadings, so they sit below the shared h3
   size. English only (the Latin face runs long: "Apartment 135 m² in Al-Mashreqiyah Neighborhood"). */
html:not([lang="ar"]) #main#main section[aria-labelledby="unit-related"] h3.display {
    font-size: 1.25rem;
    line-height: 1.3;
}

@media (min-width: 1024px) {
    html:not([lang="ar"]) #main#main section[aria-labelledby="unit-related"] h3.display {
        font-size: 1.375rem;
    }
}

/* Register-interest form: the "أرغب في" toggle (بيع / تأجير) is rounded like the fields below it. */
div:has(> label[data-segment]) {
    border-radius: 12px;
    overflow: hidden;
}

/* News page: rounded toolbar (tabs, search, view switcher) and cards in every view. */
[data-news-tabs],
[data-news-views],
:has(> input[data-news-q]) {
    border-radius: 12px;
    overflow: hidden;
}

/* grid view: the whole card; masonry: the card and its picture; magazine: the picture */
[data-news-list] li > a.bg-white {
    border-radius: 14px;
    overflow: hidden;
}

[data-news-list] li > a.bg-white.p-3 > span:first-child {
    border-radius: 10px;
}

[data-news-list] li > a.grid > span[class~="aspect-[16/10]"] {
    border-radius: 14px;
}

/* News toolbar text (Arabic only): tabs, their counts, the search field and the results line. */
html[lang="ar"] [data-news-tabs] > button {
    font-size: 1.08rem;
    height: 2.5rem;
}

html[lang="ar"] [data-news-tabs] > button [class~="text-[0.75rem]"] {
    font-size: 0.9rem;
}

html[lang="ar"] input[data-news-q] {
    font-size: 1.05rem;
}

html[lang="ar"] [data-news-results] {
    font-size: 1.05rem;
}

/* News article: rounded photo-gallery tiles. */
[data-gallery] .group.overflow-hidden {
    border-radius: 14px;
}

/* News article header (Arabic only): the back link and the خبر / مدونة tag above the title were small. */
html[lang="ar"] div:has(+ #story-title) .link-arrow {
    font-size: 1.1rem;
}

html[lang="ar"] div:has(+ #story-title) [class*="_&]:text-[0.9rem]"] {
    font-size: 1.05rem;
}

/* News grid: rows were spaced twice the columns (gap-y-12 vs gap-x-6); now even. */
[data-news-list] > ul[class~="gap-y-12"] {
    row-gap: 1.5rem;
}

/* News toolbar: the same pill shape as the projects page's view switcher: fully rounded groups with a little
   inner space, and a round highlight on the active tab / view. */
[data-news-tabs],
[data-news-views],
:has(> input[data-news-q]) {
    border-radius: 9999px;
}

[data-news-tabs],
[data-news-views] {
    padding: 4px;
    gap: 2px;
}

[data-news-tabs] > button,
[data-news-views] > button,
[data-news-tabs] [data-pill],
[data-news-views] [data-pill] {
    border-radius: 9999px;
}

[data-news-tabs] > button,
[data-news-views] > button {
    overflow: hidden;
}

:has(> input[data-news-q]) {
    padding-inline: 1rem;
}

/* Phones: hero text no longer fades out while scrolling (home, project page and the inner-page heroes). The scripts
   still set the inline styles; these win with !important below 768px only. */
@media (max-width: 767.98px) {
    [data-pd-fade],
    [data-pd-cue],
    [data-page-hero-copy],
    [data-page-hero-text] {
        opacity: 1 !important;
    }

    /* home: the title stays; the line that would replace it is not shown, so the two never overlap */
    [data-hero-title] {
        opacity: 1 !important;
        visibility: visible !important;
        transform: none !important;
    }

    [data-hero-side] {
        display: none !important;
    }
}

/* Project hero › "All projects" back link: it faded into light skies (ivory/75 on the photo). Full ivory on a soft
   dark, blurred pill so it reads over any picture. */
section[aria-labelledby="pd-title"] a.link-arrow {
    color: #f6f2ec;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    background: rgb(20 28 22 / 0.42);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    text-shadow: 0 1px 8px rgb(0 0 0 / 0.35);
    transition: background-color 0.3s ease;
}

section[aria-labelledby="pd-title"] a.link-arrow:hover {
    background: rgb(20 28 22 / 0.62);
}

/* News toolbar: the tabs and the view switcher stand exactly as tall as the search field (h-11 = 44px):
   1px border + 3px inner space + 36px buttons. */
[data-news-tabs],
[data-news-views] {
    padding: 3px;
}

[data-news-views] > button {
    width: 2.5rem;
    height: 2.25rem;
}

[data-news-tabs] > button,
html[lang="ar"] [data-news-tabs] > button {
    height: 2.25rem;
}

/* Phone menu (English): the top row matches the Arabic one: close at the far left, the theme button beside it,
   the logo on the right. */
html:not([lang="ar"]) [data-mobile-menu] > div:first-child,
html:not([lang="ar"]) [data-mobile-menu] > div:first-child > div {
    flex-direction: row-reverse;
}

/* Phones › inner-page heroes (News, Contact, FAQs…): the title ran under the fixed bottom bar. The text keeps clear
   of the bar, and the title comes down a size so three-line Arabic titles fit. */
@media (max-width: 767.98px) {
    [data-page-hero] [data-page-hero-text] {
        padding-bottom: calc(env(safe-area-inset-bottom) + 7rem);
    }

    [data-page-hero] h1.display {
        font-size: clamp(2rem, 10.5vw, 2.75rem);
    }
}

/* Phones › unit page facts: the two-column cards were too padded for their values ("الدور / الأول" wrapped).
   Tighter padding, gap and icon; the value one step smaller. */
@media (max-width: 639.98px) {
    section[aria-labelledby="unit-details"] .grid.grid-cols-2.gap-3 {
        gap: 0.5rem;
    }

    section[aria-labelledby="unit-details"] .grid.grid-cols-2.gap-3 > div.p-4 {
        padding: 0.75rem;
        gap: 0.6rem;
    }

    section[aria-labelledby="unit-details"] .grid.grid-cols-2.gap-3 > div.p-4 > [class~="size-11"] {
        width: 2.25rem;
        height: 2.25rem;
    }

    section[aria-labelledby="unit-details"] .grid.grid-cols-2.gap-3 > div.p-4 [class~="text-2xl"] {
        font-size: 1.3rem;
    }

    section[aria-labelledby="unit-details"] .grid.grid-cols-2.gap-3 > div[class~="p-6"] {
        padding: 1.25rem;
    }
}

/* Phone menu top row: with the phone and WhatsApp buttons added the close button was squeezed (22×40). Buttons keep
   their 40px; the gaps tighten and the logo gives way a little on the narrowest phones. */
[data-mobile-menu] > div:first-child > div {
    gap: 0.375rem;
}

[data-mobile-menu] > div:first-child > div > * {
    flex-shrink: 0;
}

[data-mobile-menu] > div:first-child > img {
    min-width: 0;
    flex-shrink: 1;
    max-width: 92px;
    width: 100%;
}

/* Home › certifications band ("الشهادات والاعتمادات"): more room above and below (was py-14). */
section[aria-labelledby="partners-title"] > div.bg-forest-deep {
    padding-block: 5rem;
}

@media (min-width: 1024px) {
    section[aria-labelledby="partners-title"] > div.bg-forest-deep {
        padding-block: 7rem;
    }
}
