/* ============================================================
   Purple Window Cleaning — Home page sections
   Loaded in addition to main.css only on the Home template.
   ============================================================ */

/* ---------- hero ---------- */
.hero{position:relative;min-height:100svh;display:flex;align-items:center;overflow:hidden}
.hero__media{position:absolute;inset:0;width:100%;height:100%}
.hero__slide{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;opacity:0;transition:opacity 1.8s ease}
.hero__slide.is-active{opacity:1}
.hero__scrim{position:absolute;inset:0;background:linear-gradient(180deg,rgba(42,15,69,.75) 0%,rgba(42,15,69,.5) 40%,rgba(42,15,69,.72) 100%)}
.hero__inner{position:relative;z-index:2;width:100%;display:flex;flex-direction:column;align-items:center;text-align:center;padding-top:96px;padding-bottom:40px}
.hero__brand{display:flex;flex-direction:column;align-items:center}
.hero__lockup{width:clamp(260px,38vw,400px);height:auto;display:block}
.hero__title{max-width:40ch;margin-top:20px;color:#fff;font-weight:700;font-size:clamp(26px,3.6vw,46px);line-height:1.15;letter-spacing:-.02em}
.hero__sub{max-width:52ch;margin-top:16px;color:rgba(255,255,255,.9);font-size:16px;line-height:1.5;font-weight:400}
.hero__sub strong{font-weight:700;color:#fff}
.hero .btn{display:inline-flex;margin-top:24px;margin-inline:auto;align-self:center}

/* hero intro — pure CSS, fill-mode holds the visible end state (can't strand at opacity:0) */
.hero__brand,.hero__title,.hero__sub,.hero .btn{animation:heroIn .8s ease both}
.hero__title{animation-delay:.08s}
.hero__sub{animation-delay:.16s}
.hero .btn{animation-delay:.24s}
@keyframes heroIn{from{opacity:0;transform:translateY(22px)}to{opacity:1;transform:none}}

/* keep the whole hero column on the first screen on shorter viewports */
@media(max-height:780px){
  .hero__inner{padding-top:82px;padding-bottom:30px}
  .hero__lockup{width:clamp(230px,33vw,330px)}
  .hero__title{margin-top:14px;font-size:clamp(23px,3vw,36px);line-height:1.12}
  .hero__sub{margin-top:10px;font-size:15px;line-height:1.45}
  .hero .btn{margin-top:18px}
}

/* ---------- stats strip ---------- */
.stats{background:var(--purple);color:#fff}
.stats__grid{display:grid;grid-template-columns:repeat(3,1fr)}
.stat{display:flex;flex-direction:column;gap:6px;padding:40px 24px;border-left:1px solid rgba(255,255,255,.18)}
.stat:first-child{border-left:0;padding-left:0}
.stat__big{font-size:clamp(34px,4vw,52px);font-weight:800;line-height:1;letter-spacing:-.02em}
.stat .accent,.stats .accent{color:#E9D9FA}
.stat__label{font-size:15px;color:rgba(255,255,255,.85);font-weight:500}

/* ---------- residential offer promo ---------- */
/* padding-bottom:0 — the Services section below supplies the bottom gap, so the
   space under the card matches the space above it (no doubled section padding). */
.promo-wrap{background:#fff;padding-bottom:0}
.promo{position:relative;border-radius:28px;overflow:hidden;isolation:isolate;min-height:clamp(300px,32vw,400px);display:flex;align-items:center;justify-content:center;padding:clamp(36px,4.5vw,58px) var(--pad)}
.promo__bg{position:absolute;inset:0;background:center/cover no-repeat;z-index:-2}
.promo__scrim{position:absolute;inset:0;z-index:-1;background:linear-gradient(155deg,rgba(42,15,69,.9) 0%,rgba(78,31,125,.86) 46%,rgba(107,47,163,.78) 100%)}
.promo__inner{position:relative;z-index:1;display:flex;flex-direction:column;align-items:center;text-align:center;gap:clamp(13px,2vw,20px);width:100%;max-width:680px}
.promo__lockup{width:clamp(165px,20vw,220px);height:auto}
.promo__offer{display:flex;flex-direction:column;align-items:center;line-height:.96}
.promo__pct{color:#fff;font-weight:800;font-size:clamp(42px,6.2vw,82px);letter-spacing:-.02em;line-height:.9}
.promo__line{margin-top:7px;display:inline-flex;flex-wrap:wrap;justify-content:center;align-items:center;gap:.32em;color:#fff;font-weight:800;font-size:clamp(15px,2.2vw,27px);letter-spacing:.02em;text-transform:uppercase}
.promo__hl{background:rgba(167,124,224,.55);color:#fff;padding:.04em .3em;border-radius:6px}
.promo__script{margin-top:2px;font-family:"Segoe Script","Brush Script MT","Snell Roundhand",cursive;font-style:italic;font-weight:600;color:#fff;font-size:clamp(30px,4.6vw,58px);line-height:1}
.promo__btn{display:inline-flex;align-items:center;gap:12px;color:#fff;font-weight:700;font-size:clamp(12px,1.3vw,14px);letter-spacing:.14em;text-transform:uppercase;padding:14px 32px;border:2px solid rgba(255,255,255,.7);border-radius:999px;transition:.25s var(--ease)}
.promo__btn svg{width:20px;height:20px;flex:0 0 auto}
.promo__btn:hover{background:#fff;color:var(--purple);border-color:#fff;transform:translateY(-2px)}

/* ---------- services ---------- */
.services{background:#fff}
.sec-head{display:flex;justify-content:space-between;align-items:flex-end;gap:32px;margin-bottom:56px}
.svc-group{margin-top:44px}
.svc-cat{font-size:20px;font-weight:700;margin-bottom:22px;display:flex;align-items:baseline;gap:12px}
.svc-cat .accent{font-size:15px;font-weight:700}
.svc-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:20px}
.svc-card{position:relative;display:flex;flex-direction:column;justify-content:flex-end;min-height:400px;border-radius:16px;overflow:hidden;isolation:isolate}
.svc-card__img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;z-index:-2;transition:transform .6s var(--ease)}
.svc-card:hover .svc-card__img{transform:scale(1.06)}
.svc-card__scrim{position:absolute;inset:0;z-index:-1;background:linear-gradient(to top,rgba(20,10,32,.92) 0%,rgba(20,10,32,.72) 38%,rgba(20,10,32,.28) 68%,rgba(20,10,32,.15) 100%)}
.svc-card__body{padding:26px 24px;color:#fff}
.svc-card__body h4{font-size:18px;font-weight:700;line-height:1.28;margin-bottom:10px}
.svc-card__body p{font-size:14px;color:rgba(255,255,255,.85);line-height:1.55}
.svc-card__btn{position:absolute;top:18px;right:18px;z-index:2;width:44px;height:44px;border-radius:999px;border:0;cursor:pointer;background:var(--purple);color:#fff;display:grid;place-items:center;transition:.25s var(--ease)}
.svc-card__btn svg{width:20px;height:20px}
.svc-card__btn:hover{background:#fff;color:var(--purple);transform:translateX(3px)}

/* ---------- who we serve ---------- */
.serve{background:var(--bg)}
.serve__head{display:flex;justify-content:space-between;align-items:flex-end;gap:32px;margin-bottom:48px}
.serve__grid{display:grid;grid-template-columns:repeat(3,1fr);border-top:1px solid var(--line);border-left:1px solid var(--line)}
.serve-card{padding:38px 34px;border-right:1px solid var(--line);border-bottom:1px solid var(--line);background:#fff;display:flex;flex-direction:column;transition:.3s var(--ease)}
.serve-card:hover{box-shadow:0 20px 40px rgba(20,18,26,.07);z-index:1}
.serve-card__img{aspect-ratio:16/11;border-radius:8px;overflow:hidden;margin-bottom:24px;order:-1}
.serve-card__img img{width:100%;height:100%;object-fit:cover;transition:.5s var(--ease)}
.serve-card:hover .serve-card__img img{transform:scale(1.05)}
.serve-card h3{font-size:20px;font-weight:700;line-height:1.25;margin-bottom:12px}
.serve-card p{font-size:15px;color:var(--muted);line-height:1.55;flex:1;margin-bottom:22px}
.serve-card--cta{background:var(--purple);color:#fff;justify-content:center}
.serve-card--cta h3,.serve-card--cta p{color:#fff}
.serve-card--cta .serve-card__img{display:none}

/* ---------- gallery ---------- */
.atwork{background:#fff}
.gallery{margin-top:52px;display:grid;grid-template-columns:repeat(4,1fr);grid-auto-rows:220px;gap:16px;grid-auto-flow:dense}
.gallery__item{overflow:hidden;border-radius:10px}
.gallery__item img{width:100%;height:100%;object-fit:cover;transition:.6s var(--ease)}
.gallery__item:hover img{transform:scale(1.06)}
.gallery__item--tall{grid-row:span 2}
.gallery__item--wide{grid-column:span 2}

/* ---------- why ---------- */
.why{background:var(--bg)}
.why-grid{margin-top:52px;display:grid;grid-template-columns:repeat(4,1fr);gap:28px}
.why-item{background:#fff;border:1px solid var(--line);border-radius:14px;padding:32px 28px}
.why-item__ico{width:52px;height:52px;background:var(--tint);border-radius:12px;display:grid;place-items:center;color:var(--purple);margin-bottom:22px}
.why-item__ico svg{width:26px;height:26px}
.why-item h3{font-size:18px;font-weight:700;line-height:1.3;margin-bottom:12px}
.why-item p{font-size:14.5px;color:var(--muted);line-height:1.55}

/* ---------- process ---------- */
.process{display:grid;grid-template-columns:1fr 1fr}
.process__left{position:relative;min-height:520px;display:flex;align-items:center;overflow:hidden;background:var(--purple)}
.process__left-media{position:absolute;inset:0;opacity:.28;mix-blend-mode:luminosity}
.process__left-media img{width:100%;height:100%;object-fit:cover}
.process__left-inner{position:relative;z-index:2;padding:64px var(--pad);color:#fff;max-width:520px;margin-left:auto}
.process__title{font-size:clamp(30px,3.4vw,44px);font-weight:300;line-height:1.1;margin-bottom:16px}
.process__title strong{font-weight:700}
.process__left-inner p{color:rgba(255,255,255,.9);margin-bottom:30px;font-size:18px}
.process__right{padding:40px var(--pad)}
.step{display:grid;grid-template-columns:120px 1fr;gap:20px;padding:34px 0;border-bottom:1px solid var(--line)}
.process__right .step:last-child{border-bottom:0}
.step__n{color:var(--faint);font-size:17px;font-weight:500}
.step h3{font-size:20px;font-weight:700;margin-bottom:8px}
.step p{color:var(--muted);font-size:15px;line-height:1.55}

/* ---------- safety ---------- */
.safety{background:#fff}
.safety-grid{margin-top:48px;display:grid;grid-template-columns:repeat(2,1fr);gap:20px}
.safety-item{display:flex;align-items:center;gap:16px;background:var(--bg);border-radius:12px;padding:24px 28px;font-size:18px;font-weight:600}
.safety-item svg{width:26px;height:26px;flex:0 0 auto;color:var(--purple)}

/* ---------- service area ---------- */
.area{background:var(--bg)}
.area__grid{display:grid;grid-template-columns:1.1fr .9fr;gap:64px;align-items:stretch}
.area__map svg{width:100%;height:auto}
.area__map{height:100%}
.area__map img{width:100%;height:100%;min-height:340px;object-fit:cover;border-radius:16px;display:block}
.boroughs{margin-top:26px}
.boroughs li{font-size:clamp(26px,3vw,40px);font-weight:700;line-height:1.5;color:var(--ink);border-bottom:1px solid var(--line);padding:10px 0;transition:.25s var(--ease)}
.boroughs li:hover{color:var(--purple);padding-left:12px}

/* ---------- CTA ---------- */
.cta{position:relative;background:var(--purple-deep);color:#fff;padding-block:clamp(64px,8vw,110px);overflow:hidden}
/* parallax facade photo — oversized top/bottom so it can translate without gaps */
.cta__bg{position:absolute;left:0;right:0;top:-16%;height:132%;background:center/cover no-repeat;z-index:0;will-change:transform}
/* purple wash: keeps brand tone + text contrast (darker over the left text column) */
.cta::before{content:"";position:absolute;inset:0;z-index:1;pointer-events:none;background:linear-gradient(105deg,rgba(58,15,95,.93) 0%,rgba(74,20,120,.84) 46%,rgba(107,47,163,.62) 100%)}
.cta__grid{position:relative;z-index:2;display:grid;grid-template-columns:1fr 1fr;gap:56px;align-items:start}
.cta__title{font-size:clamp(30px,3.6vw,48px);font-weight:600;line-height:1.1}
.cta__hl{color:#E9D9FA}
.cta__sub{margin-top:20px;color:rgba(255,255,255,.9);font-size:18px;max-width:44ch}
.cta__contacts{margin-top:34px;display:flex;flex-direction:column;gap:16px}
.cta__contacts li{display:flex;flex-direction:column;gap:2px}
.cta__contacts span{font-size:12px;text-transform:uppercase;letter-spacing:.1em;color:rgba(255,255,255,.6)}
.cta__contacts a,.cta__contacts li{font-size:17px;font-weight:500}
.cta__form{background:#fff;border-radius:16px;padding:34px}
/* embedded estimate funnel (iframe) — the white card lives inside the frame.
   min-width:0 stops the iframe grid item from blowing out past its 1fr column. */
.cta__frame{display:block;width:100%;max-width:100%;min-width:0;border:0;background:transparent;height:760px;transition:height .25s ease}
.cta__grid > *{min-width:0}
.field{margin-bottom:16px}
.field label{display:block;font-size:13px;font-weight:600;color:var(--ink);margin-bottom:7px}
.field--row{display:grid;grid-template-columns:1fr 1fr;gap:14px}
.field input,.field select,.field textarea{width:100%;font-family:inherit;font-size:15px;color:var(--ink);border:1px solid var(--line);border-radius:8px;padding:12px 14px;background:#fff;transition:.2s}
.field input:focus,.field select:focus,.field textarea:focus{outline:none;border-color:var(--purple)}
.cta__form .btn{margin-top:8px}

/* ---------- faq ---------- */
.faq{background:#fff}
.faq-list{margin-top:44px;border-top:1px solid var(--line)}
.faq-item{border-bottom:1px solid var(--line)}
.faq-item summary{list-style:none;cursor:pointer;display:flex;justify-content:space-between;align-items:center;gap:20px;padding:26px 0;font-size:19px;font-weight:600}
.faq-item summary::-webkit-details-marker{display:none}
.faq-ico{position:relative;width:20px;height:20px;flex:0 0 auto}
.faq-ico::before,.faq-ico::after{content:"";position:absolute;background:var(--purple);transition:.25s var(--ease)}
.faq-ico::before{top:9px;left:0;width:20px;height:2px}
.faq-ico::after{left:9px;top:0;width:2px;height:20px}
.faq-item[open] .faq-ico::after{transform:rotate(90deg);opacity:0}
.faq-item p{padding:0 0 28px;max-width:80ch;color:var(--muted);font-size:16px;line-height:1.6}

/* ---------- responsive ---------- */
@media(max-width:980px){
  .svc-grid{grid-template-columns:repeat(2,1fr)}
  .serve__grid{grid-template-columns:repeat(2,1fr)}
  .why-grid{grid-template-columns:repeat(2,1fr)}
  .process{grid-template-columns:1fr}
  .area__grid,.cta__grid{grid-template-columns:1fr;gap:36px}
  .gallery{grid-template-columns:repeat(2,1fr)}
}
@media(max-width:767px){
  /* service cards + gallery become full-bleed horizontal scroll carousels */
  .svc-grid{display:flex;gap:16px;overflow-x:auto;scroll-snap-type:x mandatory;-webkit-overflow-scrolling:touch;scrollbar-width:none;margin-inline:calc(-1 * var(--pad));padding-inline:var(--pad);scroll-padding-inline:var(--pad)}
  .svc-grid::-webkit-scrollbar{display:none}
  .svc-card{flex:0 0 80%;scroll-snap-align:start;min-height:360px}

  /* gallery IS the .container here, so it already spans full viewport width
     with --pad gutters — no negative-margin bleed (that would shift it left
     and clip the right edge). Cards overflow-scroll off the true screen edges. */
  .gallery{display:flex;grid-auto-rows:auto;gap:14px;overflow-x:auto;scroll-snap-type:x mandatory;-webkit-overflow-scrolling:touch;scrollbar-width:none;scroll-padding-inline:var(--pad)}
  .gallery::-webkit-scrollbar{display:none}
  .gallery__item{flex:0 0 78%;scroll-snap-align:start;aspect-ratio:3/4;grid-row:auto;grid-column:auto}
  .gallery__item img{width:100%;height:100%;object-fit:cover}
}
@media(max-width:620px){
  .stats__grid{grid-template-columns:1fr}
  .stat{border-left:0;border-top:1px solid rgba(255,255,255,.18);padding-left:0}
  .stat:first-child{border-top:0}
  .serve__grid,.why-grid,.safety-grid{grid-template-columns:1fr}
  .sec-head,.serve__head{flex-direction:column;align-items:flex-start;gap:22px}
  .field--row{grid-template-columns:1fr}
  .step{grid-template-columns:1fr;gap:6px}
}
