/* =========================================================================
   Projects & Designs page — uses the site's blueprint tokens (style.css)
   ========================================================================= */
.pf-section[hidden], .pf-lb[hidden] { display: none !important; }

/* ---------- Hero ---------- */
.pf-hero {
    background: var(--navy);
    background-image:
        linear-gradient(rgba(111,183,224,.12) 1px, transparent 1px),
        linear-gradient(90deg, rgba(111,183,224,.12) 1px, transparent 1px);
    background-size: 44px 44px;
    color: #fff;
    padding: 84px 0 72px;
    position: relative;
    overflow: hidden;
}
.pf-hero::after {
    content: ""; position: absolute; right: -120px; bottom: -160px; width: 460px; height: 460px;
    border: 1px solid rgba(111,183,224,.35); border-radius: 50%;
    box-shadow: 0 0 0 40px rgba(111,183,224,.05), 0 0 0 90px rgba(111,183,224,.03);
}
.pf-hero .container { position: relative; z-index: 1; }
.pf-hero .eyebrow { color: var(--cyan); }
.pf-hero h1 { color: #fff; font-size: clamp(2rem, 5vw, 3.4rem); font-weight: 700; max-width: 760px; margin-bottom: 18px; }
.pf-lead { max-width: 600px; color: rgba(255,255,255,.8); font-size: 1.08rem; margin-bottom: 36px; }
.pf-stats { display: flex; flex-wrap: wrap; gap: 14px 44px; padding-top: 26px; border-top: 1px solid rgba(255,255,255,.18); max-width: 620px; }
.pf-stats div { display: flex; flex-direction: column; }
.pf-stats b { font-family: var(--font-display); font-size: 2.2rem; line-height: 1; color: #fff; }
.pf-stats span { font-family: var(--font-mono); font-size: .7rem; letter-spacing: .1em; text-transform: uppercase; color: var(--cyan); margin-top: 8px; }

/* ---------- Filter bar ---------- */
.pf-filter {
    position: sticky; top: var(--pf-hdr, 74px); z-index: 20;
    background: rgba(255,255,255,.96); backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--concrete-mid);
}
.pf-filter .container { display: flex; gap: 10px; padding-top: 12px; padding-bottom: 12px; overflow-x: auto; scrollbar-width: none; }
.pf-filter .container::-webkit-scrollbar { display: none; }
.pf-chip {
    flex: 0 0 auto; font: 600 .84rem/1 var(--font-body); color: var(--navy);
    background: #fff; border: 1px solid var(--concrete-mid); border-radius: 999px;
    padding: 11px 18px; cursor: pointer; transition: all .2s;
}
.pf-chip em { font-style: normal; font-family: var(--font-mono); font-size: .72rem; opacity: .6; margin-left: 4px; }
.pf-chip:hover { border-color: var(--navy); }
.pf-chip.active { background: var(--navy); border-color: var(--navy); color: #fff; }
.pf-chip.active em { opacity: .8; }

/* ---------- Completed project cases ---------- */
.pf-cases { display: flex; flex-direction: column; gap: 28px; }
.pf-case {
    display: grid; grid-template-columns: 1.05fr 1fr; gap: 0;
    background: #fff; border: 1px solid var(--concrete-mid); border-radius: 10px; overflow: hidden;
    box-shadow: 0 10px 30px rgba(11,42,80,.06);
}
.pf-case.flip .pf-case-media { order: 2; }
.pf-case-media { position: relative; background: var(--navy); min-height: 340px; display: flex; flex-direction: column; }
.pf-media-main { position: relative; flex: 1; display: block; min-height: 300px; overflow: hidden; }
.pf-media-main img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.pf-media-main:hover img { transform: scale(1.04); }
.pf-zoom {
    position: absolute; right: 14px; bottom: 14px; width: 38px; height: 38px; border-radius: 50%;
    background: rgba(255,255,255,.92); color: var(--navy); display: grid; place-items: center; font-size: 1.1rem;
}
.pf-thumbs { display: flex; gap: 2px; background: var(--navy); }
.pf-thumbs a { flex: 1; height: 78px; overflow: hidden; }
.pf-thumbs img { width: 100%; height: 100%; object-fit: cover; opacity: .85; transition: opacity .2s; }
.pf-thumbs a:hover img { opacity: 1; }

.pf-blueprint {
    flex: 1; min-height: 340px; position: relative; display: grid; place-items: center; color: var(--cyan);
    background-color: var(--navy);
    background-image:
        linear-gradient(rgba(111,183,224,.16) 1px, transparent 1px),
        linear-gradient(90deg, rgba(111,183,224,.16) 1px, transparent 1px),
        linear-gradient(rgba(111,183,224,.07) 1px, transparent 1px),
        linear-gradient(90deg, rgba(111,183,224,.07) 1px, transparent 1px);
    background-size: 56px 56px, 56px 56px, 14px 14px, 14px 14px;
}
.pf-blueprint svg { width: 62%; max-width: 300px; height: auto; }
.pf-bp-no { position: absolute; left: 18px; bottom: 16px; font-family: var(--font-mono); font-size: .7rem; letter-spacing: .16em; color: rgba(255,255,255,.7); }

.pf-case-body { padding: 38px 40px; display: flex; flex-direction: column; justify-content: center; }
.pf-case-no { font-family: var(--font-mono); font-size: .78rem; letter-spacing: .14em; color: var(--orange); margin-bottom: 10px; }
.pf-case-body h3 { font-size: clamp(1.3rem, 2.4vw, 1.75rem); font-weight: 700; color: var(--navy); margin-bottom: 8px; }
.pf-client { font-weight: 600; color: var(--steel); margin-bottom: 16px; }
.pf-case-body p { color: #3b434d; font-size: .98rem; }
.pf-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 0; background: var(--concrete); border: 1px solid var(--concrete-mid); border-radius: 8px; overflow: hidden; margin: 8px 0 18px; }
.pf-facts div { padding: 12px 14px; box-shadow: 0 0 0 .5px var(--concrete-mid); }
.pf-facts dt { font-family: var(--font-mono); font-size: .64rem; letter-spacing: .1em; text-transform: uppercase; color: var(--steel); margin-bottom: 3px; }
.pf-facts dd { margin: 0; font-weight: 600; color: var(--navy); font-size: .92rem; }
.pf-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.pf-tags li { font-size: .74rem; font-weight: 600; color: var(--navy); background: rgba(11,42,80,.07); border-radius: 999px; padding: 6px 12px; }

/* ---------- Design masonry ---------- */
.pf-masonry { column-count: var(--cols, 3); column-gap: 22px; }
.pf-tile { break-inside: avoid; margin: 0 0 22px; border-radius: 10px; overflow: hidden; background: var(--navy); box-shadow: 0 8px 24px rgba(11,42,80,.12); }
.pf-tile > a { position: relative; display: block; }
.pf-tile img { width: 100%; height: auto; display: block; transition: transform .6s ease; }
.pf-tile:hover img { transform: scale(1.05); }
.pf-tile figcaption {
    position: absolute; inset: auto 0 0 0; padding: 60px 18px 16px; color: #fff;
    background: linear-gradient(to top, rgba(9,26,44,.92), rgba(9,26,44,.55) 55%, transparent);
    display: flex; flex-direction: column; gap: 4px;
    transform: translateY(0); 
}
.pf-cap-sec { font-family: var(--font-mono); font-size: .64rem; letter-spacing: .14em; text-transform: uppercase; color: var(--cyan); }
.pf-tile figcaption strong { font-family: var(--font-display); font-size: 1.02rem; line-height: 1.25; }
.pf-tile figcaption small { font-size: .8rem; color: rgba(255,255,255,.78); line-height: 1.4; max-height: 0; opacity: 0; overflow: hidden; transition: max-height .35s ease, opacity .35s ease; }
.pf-tile:hover figcaption small, .pf-tile:focus-within figcaption small { max-height: 90px; opacity: 1; }
.pf-more { position: absolute; top: 12px; right: 12px; background: rgba(255,255,255,.92); color: var(--navy); font-size: .72rem; font-weight: 700; padding: 5px 10px; border-radius: 999px; }
@media (hover: none) { .pf-tile figcaption small { max-height: 90px; opacity: 1; } }

/* ---------- CTA ---------- */
.pf-cta { background: var(--navy-deep); color: #fff; padding: 64px 0; }
.pf-cta .container { display: flex; align-items: center; justify-content: space-between; gap: 28px; flex-wrap: wrap; }
.pf-cta h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); margin-bottom: 8px; }
.pf-cta p { color: rgba(255,255,255,.75); margin: 0; max-width: 520px; }
.pf-cta-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- Lightbox ---------- */
body.pf-lock { overflow: hidden; }
.pf-lb { position: fixed; inset: 0; z-index: 1000; background: rgba(6,16,28,.94); display: flex; align-items: center; justify-content: center; padding: 56px 70px; }
.pf-lb figure { margin: 0; max-width: 100%; max-height: 100%; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.pf-lb img { max-width: 100%; max-height: calc(100vh - 190px); width: auto; height: auto; object-fit: contain; border-radius: 4px; background: #fff; }
.pf-lb figcaption { color: #fff; text-align: center; display: flex; flex-direction: column; gap: 4px; max-width: 720px; }
.pf-lb figcaption strong { font-family: var(--font-display); font-size: 1.1rem; }
.pf-lb figcaption span { color: rgba(255,255,255,.75); font-size: .9rem; }
.pf-lb figcaption em { font-style: normal; font-family: var(--font-mono); font-size: .72rem; color: var(--cyan); letter-spacing: .1em; }
.pf-lb button { position: absolute; background: rgba(255,255,255,.1); color: #fff; border: 0; cursor: pointer; width: 46px; height: 46px; border-radius: 50%; font-size: 1.8rem; line-height: 1; transition: background .2s; }
.pf-lb button:hover { background: var(--orange); }
.pf-lb-close { top: 16px; right: 16px; }
.pf-lb-nav { top: 50%; margin-top: -23px; }
.pf-lb-nav.prev { left: 14px; }
.pf-lb-nav.next { right: 14px; }
.pf-lb.single .pf-lb-nav { display: none; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
    .pf-masonry { column-count: 2; }
    .pf-case, .pf-case.flip { grid-template-columns: 1fr; }
    .pf-case.flip .pf-case-media { order: 0; }
    .pf-case-media, .pf-blueprint { min-height: 260px; }
    .pf-media-main { min-height: 260px; }
}
@media (max-width: 600px) {
    .pf-hero { padding: 56px 0 48px; }
    .pf-masonry { column-count: 1; }
    .pf-case-body { padding: 26px 22px; }
    .pf-lb { padding: 56px 12px 20px; }
    .pf-lb-nav { top: auto; bottom: 14px; margin: 0; }
    .pf-lb-nav.prev { left: 14px; } .pf-lb-nav.next { right: 14px; }
    .pf-lb img { max-height: calc(100vh - 230px); }
    .pf-cta-actions .btn { width: 100%; justify-content: center; }
}
