/* JP Whyte mobile presentation repair — 2026-09-03
   Scoped overrides for the refreshed homepage and the three project pages. */

/* Homepage: a clean project-led hero with every caption contained by its image. */
.cinematic-hero .cinematic-grid{
  align-items:center;
}
.cinematic-hero .cinematic-proof{
  grid-template-columns:repeat(2,minmax(0,1fr));
}
.cinematic-showcase{
  min-height:0 !important;
  display:grid !important;
  grid-template-rows:minmax(330px,1fr) 178px;
  gap:1rem;
  perspective:none !important;
  transform-style:flat !important;
  opacity:1 !important;
  animation:none !important;
}
.hero-project-pair{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:1rem;
  min-width:0;
}
.hero-project{
  position:relative;
  display:block;
  min-width:0;
  min-height:0;
  overflow:hidden;
  border-radius:26px;
  background:#07152b;
  border:1px solid rgba(255,255,255,.22);
  box-shadow:0 24px 60px rgba(0,0,0,.28);
  isolation:isolate;
}
.hero-project-main{border-radius:34px}
.hero-project img{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
  transform:none !important;
  animation:none !important;
}
.hero-project:after{
  content:"";
  position:absolute;
  inset:25% 0 0;
  z-index:1;
  background:linear-gradient(180deg,transparent,rgba(3,12,25,.84));
  pointer-events:none;
}
.hero-project > span{
  position:absolute;
  left:1rem;
  right:1rem;
  bottom:1rem;
  z-index:2;
  color:#fff;
  line-height:1.12;
}
.hero-project small{
  display:block;
  margin-bottom:.3rem;
  color:#f5d889;
  font-size:.72rem;
  font-weight:900;
  letter-spacing:.1em;
  text-transform:uppercase;
}
.hero-project strong{
  display:block;
  color:#fff;
  font-size:clamp(1rem,2vw,1.45rem);
}
.hero-project:focus-visible{
  outline:3px solid #fff;
  outline-offset:3px;
}

/* Trust cards and pale-section labels must remain high contrast. */
.homepage-credentials .trust-item{
  background:#fff !important;
  border:1px solid #c9deed !important;
  box-shadow:0 12px 30px rgba(7,21,43,.08) !important;
}
.homepage-credentials .trust-item strong{
  color:#07152b !important;
  text-shadow:none !important;
}
.homepage-credentials .trust-item span{
  color:#44566b !important;
  text-shadow:none !important;
}
.project-proof-card .kicker,
.case-section .section-head .kicker,
.case-section .case-copy > .kicker{
  color:#075c9c !important;
  background:#eef8ff !important;
  border-color:#b9daf0 !important;
  text-shadow:none !important;
}

/* Comparison reveal: one source of truth for photo edge and handle. */
.case-before-after .ba-card.ba-slider-ready .ba-images figure:nth-child(2){
  clip-path:inset(0 0 0 var(--split,50%));
  -webkit-clip-path:inset(0 0 0 var(--split,50%));
  will-change:clip-path;
}
.case-before-after .ba-card.ba-slider-ready .ba-handle{
  left:var(--split,50%);
  transform:translateX(-1px);
  pointer-events:none;
}
.case-before-after .ba-card.ba-slider-ready .ba-range{
  inset:0 !important;
  width:100% !important;
  height:100% !important;
  margin:0 !important;
  touch-action:pan-y;
}

/* Project carousels: cards size to their content rather than the tallest item. */
.project-slider{
  align-items:start !important;
  grid-auto-columns:min(76vw,500px) !important;
  overscroll-behavior-inline:contain;
}
.project-slider figure{
  align-self:start !important;
  display:grid !important;
  grid-template-rows:auto auto !important;
  height:auto !important;
  min-height:0 !important;
  max-height:none !important;
}
.project-slider img{
  width:100% !important;
  height:auto !important;
  max-height:none !important;
  aspect-ratio:4/3 !important;
  object-fit:cover !important;
  object-position:center !important;
}
.project-slider img[width="1350"][height="1800"]{
  object-position:center 58% !important;
}
.project-slider figcaption{
  height:auto !important;
  min-height:0 !important;
  padding:1rem 1.1rem 1.15rem !important;
}

@media(max-width:760px){
  .cinematic-hero{
    padding:2.8rem 0 3.2rem !important;
  }
  .cinematic-hero .cinematic-copy h1{
    font-size:clamp(2.55rem,12vw,3.55rem) !important;
    line-height:.94 !important;
  }
  .cinematic-hero .cinematic-proof{
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
    gap:.65rem !important;
  }
  .cinematic-hero .cinematic-proof span{
    min-height:82px !important;
    padding:.8rem !important;
    border-radius:18px !important;
    font-size:.84rem;
  }
  .cinematic-showcase{
    grid-template-columns:1fr !important;
    grid-template-areas:none !important;
    grid-template-rows:250px 132px !important;
    gap:.75rem !important;
    margin-top:.4rem;
  }
  .hero-project-pair{gap:.75rem}
  .hero-project,
  .hero-project-main{border-radius:22px}
  .hero-project > span{left:.75rem;right:.75rem;bottom:.7rem}
  .hero-project small{font-size:.62rem;letter-spacing:.07em}
  .hero-project strong{font-size:.94rem}

  .homepage-credentials .grid-4{
    gap:.7rem !important;
  }
  .homepage-credentials .trust-item{
    min-height:0 !important;
    padding:1rem !important;
    border-radius:20px !important;
  }

  .project-slider{
    grid-auto-columns:min(82vw,360px) !important;
    gap:.8rem !important;
    padding-bottom:.7rem !important;
  }
  .project-slider img{
    aspect-ratio:4/3 !important;
  }
  .project-slider figcaption{
    font-size:.96rem;
    line-height:1.45;
  }
  .case-before-after .ba-images{
    height:clamp(250px,68vw,310px) !important;
    min-height:0 !important;
    max-height:310px !important;
  }
}

@media(max-width:430px){
  .cinematic-showcase{grid-template-rows:225px 118px !important}
  .cinematic-hero .cinematic-proof span{min-height:76px !important}
  .project-slider{grid-auto-columns:82vw !important}
}

@media(prefers-reduced-motion:no-preference) and (hover:hover){
  .hero-project img{transition:transform .45s ease !important}
  .hero-project:hover img{transform:scale(1.035) !important}
}
