/*
 * Project pages (single-properties.php, -resale.php, -assignment.php): the head of the page - logo, title, summary,
 * key facts, incentives. Owner, 2026-11-16: "the UI of how this information is shown is very messy, fix it" (desktop
 * and phone, light and dark). Colours are tokens only (tools/theme/site-tokens.py --check); dark mode remaps them.
 * Checked by tools/tests/project-page-test.js.
 */

/* ── The head: the logo is a column of its own, its top on the title's top; the text column starts at one left edge ── */
.excerpt-top.card-property-responsive { align-items: flex-start !important; justify-content: flex-start !important; gap: 24px; text-align: left; }
.excerpt-top > img { flex: 0 0 auto; margin: 0 !important; max-width: 200px; max-height: 200px; object-fit: contain; }
.excerpt-top > .container-fluid { flex: 1 1 auto; min-width: 0; padding-left: 0; padding-right: 0; }
.excerpt-top h1 { margin-top: 0 !important; }
.excerpt-top .show-on-sm { padding: 0; }
/* up to 1300px the logo sits above the title, on the same left edge (it was centred, with the text centred under it) */
.excerpt-top .show-on-sm img { display: block; max-width: 200px; max-height: 120px; width: auto; margin: 0 0 16px !important; object-fit: contain; }
@media (max-width: 1300px) { .excerpt-top.card-property-responsive { flex-direction: column; } }

/* the assignment page's project name under the title: a deeper orange (the light one was 3.0:1 on the grey card) */
.card-property-responsive .project-title { color: var(--fg-orange-31); }

/* ── Key facts: balanced rows (inc/helper.php hlr_project_facts sets --c2 .. --c10 for the item count) ──────────────
 * The strip measures its own width: room for N boxes of at least 118px (10px apart) uses --cN; the boxes of a shorter
 * last row stretch, so every row spans the full width. Below 374px (a phone) the boxes are rows: icon left of the text. */
.characteristics-cnt.hlr-facts { container: hlrfacts / inline-size; margin-top: 16px; }
.hlr-facts .hlr-facts-list { --cols: var(--c2, 2); display: flex; flex-wrap: wrap; gap: 10px; margin: 0; padding: 0; list-style: none; }
.hlr-facts .hlr-facts-list > li { flex: 1 1 calc((100% - (var(--cols) - 1) * 10px) / var(--cols) - 1px); min-width: 0; margin: 0;
    display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 6px; padding: 12px 8px; text-align: center; }
.hlr-facts .hlr-fact-i { display: flex; align-items: center; justify-content: center; height: 30px; flex: 0 0 auto; }
.hlr-facts .hlr-fact-i i { font-size: 28px; margin: 0; line-height: 1; }
.hlr-facts .hlr-fact-i img, .hlr-facts .hlr-fact-i svg { height: 30px; width: auto; margin: 0; }
.hlr-facts .hlr-fact-i > div { display: flex; margin: 0; }
.hlr-facts .hlr-fact-t { font-size: 14px; line-height: 1.3; min-width: 0; }
.hlr-facts .hlr-fact-t span[style] { font-size: 13px !important; }
@container hlrfacts (min-width: 374px) { .hlr-facts .hlr-facts-list { --cols: var(--c3); } }
@container hlrfacts (min-width: 502px) { .hlr-facts .hlr-facts-list { --cols: var(--c4); } }
@container hlrfacts (min-width: 630px) { .hlr-facts .hlr-facts-list { --cols: var(--c5); } }
@container hlrfacts (min-width: 758px) { .hlr-facts .hlr-facts-list { --cols: var(--c6); } }
@container hlrfacts (min-width: 886px) { .hlr-facts .hlr-facts-list { --cols: var(--c7); } }
@container hlrfacts (min-width: 1014px) { .hlr-facts .hlr-facts-list { --cols: var(--c8); } }
@container hlrfacts (min-width: 1142px) { .hlr-facts .hlr-facts-list { --cols: var(--c9); } }
@container hlrfacts (min-width: 1270px) { .hlr-facts .hlr-facts-list { --cols: var(--c10); } }
@container hlrfacts (max-width: 373.98px) {
    .hlr-facts .hlr-facts-list { gap: 8px; }
    .hlr-facts .hlr-facts-list > li { flex-basis: calc((100% - (var(--cols) - 1) * 8px) / var(--cols) - 1px); flex-direction: row; align-items: center;
        gap: 7px; padding: 9px 8px; text-align: left; }
    .hlr-facts .hlr-fact-i { width: 20px; height: 20px; }
    .hlr-facts .hlr-fact-i i { font-size: 18px; }
    .hlr-facts .hlr-fact-i img, .hlr-facts .hlr-fact-i svg { height: 20px; }
    .hlr-facts .hlr-fact-t { font-size: 13px; }
}

/* ── Incentives (template-parts/components/properties/project-incentives.php): one aligned list, check marks ────────── */
.hlr-incentives { margin: 20px 0 6px; padding: 14px 16px; border: 1px solid var(--line-line); border-radius: 8px; }
.hlr-incentives-h { margin: 0 0 10px; font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--fg-ink-soft); }
.hlr-incentives-list { display: grid; grid-template-columns: 1fr; gap: 8px 24px; margin: 0; padding: 0; list-style: none; }
.hlr-incentives-list li { display: flex; align-items: flex-start; gap: 10px; margin: 0; font-size: 15px; font-weight: 600; line-height: 1.35; color: var(--fg-ink); }
.hlr-incentives-list li i { flex: 0 0 16px; margin-top: 2px; font-size: 15px; text-align: center; color: var(--fg-green-24); }
@media (min-width: 576px) { .hlr-incentives-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 992px) { .hlr-incentives-list { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ── Phone: the card's inner padding was 16px + 15px + 15px on each side of a 390px screen ───────────────────────── */
@media (max-width: 575.98px) {
    .excerpt-top .show-on-sm img { max-height: 100px; }
    .hlr-incentives { padding: 12px 14px; }
    .hlr-incentives-list li { font-size: 14px; }
}
