/* ══════════════════════════════════════════════════════════════════════════
   Construction & Real Estate — page styles.

   Loaded only by templates/industry-construction-body.php, so every selector
   here is safe from the other 19 industry pages and the rest of the site. The
   design system (tokens, .eyebrow, .sec-h, .sec-sub, .btn, .grid-bg, the .rv
   scroll reveal, nav and footer) comes from partials/style.php unchanged.

   Green is an accent only: #32b46f for fills and hairlines, #14855a where it
   carries small text (4.6:1 on white), #1c9558 for large text (3.8:1).
   ══════════════════════════════════════════════════════════════════════════ */

/* ── shared ── */
#cx-hero,#cx-problem,#cx-erp,#cx-outcomes,#cx-why,#cx-faq,#cx-cta{position:relative}
.cx-plate{
 font-family:var(--font);font-size:12px;font-weight:600;
 text-transform:uppercase;letter-spacing:.12em;color:var(--g400);
}
.cx-shot-empty{
 display:flex;align-items:center;justify-content:center;
 background:linear-gradient(145deg,#f4f5f4 0%,#e9ebe9 60%,#e4e7e5 100%);
}
.cx-ok{color:#14855a}
.cx-warn{color:#b0611a}

/* ══════════ 01 · HERO ══════════ */
#cx-hero{padding-top:9.5rem;overflow:hidden}
.cx-hero-grid{
 display:grid;grid-template-columns:minmax(0,1.05fr) minmax(0,.95fr);
 gap:4rem;align-items:center;max-width:1240px;margin:0 auto;
}
.cx-h1{
 font-family:var(--font);font-size:clamp(38px,5.4vw,66px);font-weight:800;
 letter-spacing:-.03em;line-height:1.05;color:var(--black);
 margin:1.1rem 0 1.35rem;text-wrap:balance;
}
.cx-lead{
 font-family:var(--font);font-size:17px;line-height:1.7;color:var(--g500);
 max-width:33rem;margin:0 0 2.25rem;
}
.cx-hero-cta{display:flex;gap:12px;flex-wrap:wrap}

.cx-hero-visual{position:relative}
.cx-shot{
 position:relative;overflow:hidden;border-radius:22px;
 aspect-ratio:4/3;background:var(--bg);
 border:1px solid var(--border);
 /* its own stacking context, or Safari lets the image bleed past the radius */
 isolation:isolate;
}
.cx-shot img{width:100%;height:100%;object-fit:cover;display:block}

/* readouts float over the image corners; they are content, not chrome */
.cx-float{
 position:absolute;z-index:2;min-width:150px;
 background:rgba(255,255,255,.92);backdrop-filter:blur(8px);
 border:1px solid var(--border);border-radius:14px;
 padding:12px 14px;box-shadow:0 14px 34px rgba(16,32,48,.10);
 animation:cx-bob 7s ease-in-out infinite alternate;
}
.cx-float-a{top:8%;left:-6%}
.cx-float-b{bottom:16%;left:-9%;animation-delay:-2.4s}
.cx-float-c{top:26%;right:-7%;animation-delay:-4.8s}
.cx-float-k{font-family:var(--font);font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.09em;color:var(--g400)}
.cx-float-v{font-family:var(--font);font-size:24px;font-weight:800;letter-spacing:-.03em;color:var(--black);line-height:1.1;margin-top:3px}
.cx-float-v span{font-size:14px;font-weight:700;margin-left:1px}
.cx-float-sub{font-family:var(--font);font-size:11.5px;font-weight:500;color:var(--g500);margin-top:3px}
.cx-float-bar{height:5px;border-radius:5px;background:#e8ece9;margin-top:9px;overflow:hidden}
.cx-float-bar i{display:block;height:100%;border-radius:5px;background:#32b46f}
@keyframes cx-bob{from{transform:translateY(-5px)}to{transform:translateY(5px)}}

/* the dashboard is built, not photographed: stays sharp and always on-brand */
.cx-dash{
 position:relative;z-index:1;border-radius:18px;overflow:hidden;
 background:#0a1310;border:1px solid rgba(255,255,255,.09);
 box-shadow:0 30px 70px rgba(4,18,12,.28);
}
.cx-dash-top{
 display:flex;align-items:center;gap:7px;
 padding:12px 16px;border-bottom:1px solid rgba(255,255,255,.07);
}
.cx-dot{width:8px;height:8px;border-radius:50%;background:rgba(255,255,255,.18)}
.cx-dash-title{
 margin-left:8px;font-family:var(--font);font-size:11.5px;font-weight:600;
 letter-spacing:.04em;color:rgba(255,255,255,.55);
}
.cx-dash-body{padding:16px}
.cx-dash-kpis{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin-bottom:16px}
.cx-kpi{background:rgba(255,255,255,.04);border:1px solid rgba(255,255,255,.07);border-radius:11px;padding:10px 12px}
.cx-kpi span{display:block;font-family:var(--font);font-size:10px;font-weight:600;text-transform:uppercase;letter-spacing:.08em;color:#8fa79a}
.cx-kpi b{display:block;font-family:var(--font);font-size:20px;font-weight:800;letter-spacing:-.03em;color:#fff;margin-top:3px}
.cx-kpi b.cx-ok{color:#5fd394}
.cx-kpi b.cx-warn{color:#e8a33d}
.cx-dash-rows{display:flex;flex-direction:column;gap:11px;margin-bottom:16px}
.cx-row{display:flex;align-items:center;gap:12px;font-family:var(--font);font-size:12.5px;color:#c6d5cd}
.cx-row span{width:132px;flex:none}
.cx-row i{flex:1;height:6px;border-radius:6px;background:rgba(255,255,255,.08);overflow:hidden}
.cx-row em{display:block;height:100%;border-radius:6px;background:#32b46f}
.cx-row em.cx-bar-warn{background:#e8a33d}
.cx-row b{width:38px;text-align:right;font-weight:700;color:#fff}
.cx-dash-foot{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}
.cx-chip{background:rgba(50,180,111,.08);border:1px solid rgba(50,180,111,.18);border-radius:10px;padding:9px 11px}
.cx-chip span{display:block;font-family:var(--font);font-size:9.5px;font-weight:700;text-transform:uppercase;letter-spacing:.08em;color:#5fd394}
.cx-chip b{display:block;font-family:var(--font);font-size:11.5px;font-weight:600;color:#dbe7e1;margin-top:3px}

/* ══════════ 05 · WHY DRAWLEAD ══════════ */
.cx-why-grid{
 display:grid;grid-template-columns:minmax(0,.95fr) minmax(0,1.05fr);
 gap:4rem;align-items:start;max-width:1180px;margin:0 auto;
}
.cx-why-h{
 font-family:var(--font);font-size:clamp(32px,4.2vw,52px);font-weight:800;
 letter-spacing:-.03em;line-height:1.08;color:var(--black);margin:1.1rem 0 1.1rem;
}
.cx-why-p{font-family:var(--font);font-size:16px;line-height:1.7;color:var(--g500);margin:0 0 2rem;max-width:30rem}
.cx-why-statement{
 font-family:var(--font);font-size:clamp(20px,2.1vw,26px);font-weight:700;
 letter-spacing:-.02em;line-height:1.35;color:var(--black);margin:0;
 padding-left:1.25rem;border-left:3px solid #32b46f;max-width:26rem;
}
.cx-why-right{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.cx-why-card{
 background:var(--white);border:1px solid var(--border);border-radius:16px;
 padding:1.5rem 1.4rem;
 transition:border-color .3s ease,transform .3s cubic-bezier(.2,.7,.2,1);
}
/* alternating lift, so the column reads as two staggered runs rather than a grid */
.cx-offset{transform:translateY(22px)}
.cx-why-card:hover{border-color:#32b46f;transform:translateY(-4px)}
.cx-offset:hover{transform:translateY(18px)}
.cx-why-card h3{font-family:var(--font);font-size:15.5px;font-weight:700;letter-spacing:-.01em;color:var(--black);margin:0 0 .45rem}
.cx-why-card p{font-family:var(--font);font-size:13.5px;line-height:1.6;color:var(--g500);margin:0}

/* ══════════ 06 · FAQ ══════════ */
.cx-faq-list{max-width:900px;margin:0 auto;border-top:1px solid var(--border)}
.cx-faq-item{border-bottom:1px solid var(--border)}
.cx-faq-h{margin:0}
.cx-faq-q{
 width:100%;display:flex;align-items:center;justify-content:space-between;gap:1.5rem;
 background:none;border:0;cursor:pointer;text-align:left;
 padding:1.45rem 0;
 font-family:var(--font);font-size:17px;font-weight:700;letter-spacing:-.015em;color:var(--black);
 transition:color .2s ease;
}
.cx-faq-q:hover{color:#14855a}
.cx-faq-ico{position:relative;width:16px;height:16px;flex:none}
.cx-faq-ico::before,.cx-faq-ico::after{
 content:'';position:absolute;left:50%;top:50%;background:#32b46f;border-radius:2px;
 transform:translate(-50%,-50%);transition:transform .3s cubic-bezier(.2,.7,.2,1),opacity .3s ease;
}
.cx-faq-ico::before{width:16px;height:2px}
.cx-faq-ico::after{width:2px;height:16px}
.is-open .cx-faq-ico::after{transform:translate(-50%,-50%) rotate(90deg);opacity:0}
/* 0fr -> 1fr needs no measured height, so it cannot drift when the copy rewraps */
.cx-faq-a{display:grid;grid-template-rows:0fr;transition:grid-template-rows .32s cubic-bezier(.2,.7,.2,1)}
.cx-faq-a > p{overflow:hidden;margin:0;font-family:var(--font);font-size:15px;line-height:1.7;color:var(--g500);max-width:64ch}
.is-open .cx-faq-a{grid-template-rows:1fr}
.is-open .cx-faq-a > p{padding-bottom:1.5rem}

/* ══════════ 07 · FINAL CTA ══════════ */
#cx-cta{overflow:hidden;background:var(--bg)}
#cx-cta > *:not(.grid-bg):not(.cx-glow){position:relative;z-index:1}
#cx-cta .grid-bg{z-index:0}
.cx-cta-inner{max-width:1080px;margin:0 auto;text-align:center}
.cx-cta-h{
 font-family:var(--font);font-size:clamp(34px,5vw,62px);font-weight:800;
 letter-spacing:-.03em;line-height:1.06;color:var(--black);margin:0 0 1.1rem;text-wrap:balance;
}
.cx-cta-p{font-family:var(--font);font-size:17px;line-height:1.7;color:var(--g500);margin:0 auto 2.25rem;max-width:40rem}
.cx-cta-btn{margin-bottom:3.25rem}
.cx-cta-shot{
 position:relative;overflow:hidden;border-radius:24px;isolation:isolate;
 aspect-ratio:21/9;border:1px solid var(--border);background:var(--white);
}
/* keeps the placeholder tint: .cx-shot-empty is declared earlier, so the plain
   white above would otherwise win on source order */
.cx-cta-shot.cx-shot-empty{background:linear-gradient(145deg,#f4f5f4 0%,#e9ebe9 60%,#e4e7e5 100%)}
.cx-cta-shot img{width:100%;height:100%;object-fit:cover;display:block}

/* cursor glow, same contract as the About Us hero: JS writes only --cx-x/--cx-y */
.cx-glow{
 --cx-w:560px;--cx-h:440px;--cx-x:50%;--cx-y:50%;
 position:absolute;inset:0;z-index:0;pointer-events:none;overflow:hidden;
 opacity:0;transition:opacity .45s ease;
}
.cx-glow.is-on{opacity:1}
.cx-glow-blob{
 position:absolute;top:0;left:0;width:var(--cx-w);height:var(--cx-h);border-radius:50%;
 transform:translate3d(calc(var(--cx-x) - var(--cx-w) / 2),calc(var(--cx-y) - var(--cx-h) / 2),0);
 background:radial-gradient(circle at 50% 50%,rgba(50,180,111,.38) 0%,rgba(50,180,111,.18) 40%,rgba(50,180,111,0) 70%);
 filter:blur(54px);will-change:transform;
}
.cx-glow-lines{
 position:absolute;inset:0;
 background-image:
  linear-gradient(rgba(50,180,111,.5) 1px,transparent 1px),
  linear-gradient(90deg,rgba(50,180,111,.5) 1px,transparent 1px);
 background-size:68px 68px;
 -webkit-mask-image:radial-gradient(circle at 50% 50%,#000 0%,rgba(0,0,0,.45) 38%,transparent 68%);
 mask-image:radial-gradient(circle at 50% 50%,#000 0%,rgba(0,0,0,.45) 38%,transparent 68%);
 -webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;
 -webkit-mask-size:var(--cx-w) var(--cx-h);mask-size:var(--cx-w) var(--cx-h);
 -webkit-mask-position:calc(var(--cx-x) - var(--cx-w) / 2) calc(var(--cx-y) - var(--cx-h) / 2);
 mask-position:calc(var(--cx-x) - var(--cx-w) / 2) calc(var(--cx-y) - var(--cx-h) / 2);
}

/* ══════════ responsive ══════════ */
@media(max-width:1100px){
 .cx-hero-grid{grid-template-columns:1fr;gap:3rem}
 .cx-lead{max-width:none}
 .cx-float-a{left:2%}
 .cx-float-b{left:1%}
 .cx-float-c{right:2%}
 .cx-why-grid{grid-template-columns:1fr;gap:2.5rem}
}
@media(max-width:900px){
}
@media(max-width:768px){
 #cx-hero{padding-top:7.5rem}
 .cx-why-right{grid-template-columns:1fr}
 .cx-offset{transform:none}
 .cx-offset:hover{transform:translateY(-4px)}
 .cx-faq-q{font-size:15.5px;padding:1.25rem 0}
 .cx-cta-shot{aspect-ratio:16/10}
 .cx-glow{--cx-w:380px;--cx-h:320px}
 .cx-float{min-width:126px;padding:10px 11px}
 .cx-float-v{font-size:20px}
}
@media(max-width:560px){
 .cx-float-c{display:none}
 .cx-dash-kpis,.cx-dash-foot{grid-template-columns:1fr 1fr}
 .cx-row span{width:96px}
}
@media(prefers-reduced-motion:reduce){
 .cx-float{animation:none}
}

/* ══════════ pinned horizontal runs ══════════
   Shared by the problem cards, the solution cards and the outcomes. The wrapper
   is given its height by JS (pin height + the track's horizontal overflow); the
   pin sticks centred in the viewport and the track slides inside it.

   Everything below .cx-hx-on is the pinned state, and the JS only adds that class
   on a wide viewport with motion allowed. Without it — no JS, an error, reduced
   motion, or a phone — these rules never apply and the track is a plain swipe
   row, which is why the defaults here are the unpinned ones. */
.cx-hx{position:relative;width:100%}
.cx-hx-track{
 display:flex;gap:20px;padding:6px 2px 14px;
 overflow-x:auto;scroll-snap-type:x proximity;-webkit-overflow-scrolling:touch;
 scrollbar-width:none;
}
.cx-hx-track::-webkit-scrollbar{display:none}
.cx-hx-on{--cx-pin-h:clamp(340px,54vh,460px)}
.cx-hx-on .cx-hx-pin{
 position:sticky;top:calc((100vh - var(--cx-pin-h)) / 2);
 height:var(--cx-pin-h);display:flex;align-items:center;overflow:hidden;
}
.cx-hx-on .cx-hx-track{
 width:max-content;flex:none;overflow:visible;
 will-change:transform;padding-bottom:6px;
}

/* ══════════ dark statement cards ══════════ */
.cx-card{
 flex:0 0 340px;width:340px;scroll-snap-align:start;
 display:flex;flex-direction:column;
 min-height:300px;padding:1.9rem 1.8rem 1.75rem;
 background:#141517;border:1px solid rgba(255,255,255,.07);border-radius:26px;
 transition:transform .35s cubic-bezier(.2,.7,.2,1),border-color .35s ease,box-shadow .35s ease;
}
.cx-card:hover{
 transform:translateY(-5px);border-color:rgba(50,180,111,.38);
 box-shadow:0 24px 50px rgba(6,20,14,.3);
}
.cx-card-n{
 font-family:var(--font);font-size:12px;font-weight:700;letter-spacing:.08em;
 color:rgba(255,255,255,.34);margin-bottom:1.35rem;
}
/* the headline carries the accent, with the icon sitting inline after it */
.cx-card-t{
 font-family:var(--font);font-size:clamp(21px,1.7vw,26px);font-weight:600;
 letter-spacing:-.02em;line-height:1.28;color:#fff;margin:0 0 .9rem;
}
.cx-card-t em{font-style:normal;color:#5fd394}
.cx-ic{
 display:inline-flex;align-items:center;justify-content:center;
 width:1.5em;height:1.5em;margin-left:.35em;vertical-align:-.3em;
 border:1px solid rgba(50,180,111,.4);border-radius:7px;color:#5fd394;
}
.cx-ic svg{width:.95em;height:.95em;display:block}
/* #9aa6a0 on #141517 is 6.4:1 */
.cx-card-d{
 font-family:var(--font);font-size:14px;line-height:1.65;color:#9aa6a0;
 margin:0;
}
.cx-card-sol .cx-card-t em{color:#7adfa8}

/* outcomes keep the light treatment; only the mechanism is shared */
.cx-out{
 flex:0 0 384px;width:384px;scroll-snap-align:start;
 background:var(--white);border:1px solid var(--border);border-radius:20px;
 padding:2rem 1.9rem;transition:border-color .3s ease;
}
.cx-out:hover{border-color:#32b46f}
.cx-out-n{
 font-family:var(--font);font-size:34px;font-weight:800;letter-spacing:-.04em;
 color:#1c9558;line-height:1;display:block;margin-bottom:1.1rem;
}
.cx-out-t{font-family:var(--font);font-size:20px;font-weight:700;letter-spacing:-.02em;color:var(--black);margin:0 0 .55rem}
.cx-out-d{font-family:var(--font);font-size:14.5px;line-height:1.65;color:var(--g500);margin:0}

/* the built dashboard now leads its section rather than being flanked */
.cx-dash{max-width:900px;margin:0 auto 2.75rem}

@media(max-width:900px){
 .cx-hx{height:auto !important}
 .cx-hx-track{transform:none !important}
}
@media(max-width:768px){
 .cx-card{flex-basis:288px;width:288px;min-height:0;padding:1.6rem 1.5rem 1.5rem}
 .cx-out{flex-basis:288px;width:288px}
 .cx-dash{margin-bottom:2rem}
}
