/* ==========================================================================
   "Meet NexVue" — homepage showcase section (below banner carousel)
   Headline + scroll-scrubbed lens animation (floating lens, royal-blue silk,
   lenses rising from below) + asymmetric photo mosaic with staggered reveal.
   ========================================================================== */

.meet-nexvue {
  position: relative;
  background: #ffffff;
  padding: 88px 0 90px;
  overflow: hidden;
}
/* overflow:hidden would break position:sticky inside the section; clip doesn't */
@supports (overflow: clip) {
  .meet-nexvue { overflow: clip; }
}

/* ---- Heading ---- */
.mn-head {
  position: relative;
  z-index: 3;
  text-align: center;
  max-width: 760px;
  margin: 0 auto;
}
.mn-eyebrow {
  color: var(--color-accent);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  margin: 0 0 14px;
}
.mn-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.8rem, 9vw, 6.4rem);
  line-height: 0.98;
  letter-spacing: -2.5px;
  color: var(--color-header);
  margin: 0;
}
.mn-title span {
  color: var(--color-primary);
  background: linear-gradient(100deg, var(--color-primary) 10%, var(--color-accent) 90%);
  -webkit-background-clip: text;
  background-clip: text;
}
@supports ((-webkit-background-clip: text) or (background-clip: text)) {
  .mn-title span {
    color: transparent;
    -webkit-text-fill-color: transparent;
  }
}
.mn-sub {
  margin: 18px auto 0;
  color: var(--color-ink-muted);
  font-size: 1.04rem;
  max-width: 46ch;
  position: relative;
  z-index: 3;
}

/* ---- Scroll-scrubbed lens animation (driven by js/meet-nexvue.js + GSAP ScrollTrigger) ----
   .la-scroller provides the scroll distance; .la-sticky pins the stage while the
   timeline is scrubbed. Final-state transforms live here so the composition is
   still correct without JS / with reduced motion. */
.la-scroller {
  --la-top: 0px;                       /* sticky header height, set by JS */
  --la-h: calc(100vh - var(--la-top));
  --hero-w: min(86vw, 1180px, calc(var(--la-h) * 1.25));
  --cam-end: 0.72;
  --sec-w: clamp(88px, 9vw, 140px);
  position: relative;
  height: 360vh;
  margin-top: 26px;
  background: #ffffff;
}
@supports (height: 100svh) {
  .la-scroller { --la-h: calc(100svh - var(--la-top)); }
}
.la-sticky {
  position: sticky;
  top: var(--la-top);
  height: var(--la-h);
  overflow: hidden;
  background: #ffffff;
}
.la-world {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: scale(var(--cam-end));
  will-change: transform;
}
.la-hero {
  position: relative;
  width: var(--hero-w);
  aspect-ratio: 3 / 2;
  flex: 0 0 auto;
}
.la-hero::after {
  /* soft contact shadow under the floating composition */
  content: '';
  position: absolute;
  left: 22%;
  right: 22%;
  bottom: -2%;
  height: 9%;
  background: radial-gradient(ellipse at center, rgba(16, 52, 140, 0.22), rgba(16, 52, 140, 0) 70%);
  filter: blur(6px);
  z-index: 0;
  pointer-events: none;
}
.la-silk-wrap,
.la-lens-wrap {
  position: absolute;
  inset: 0;
  transform-origin: 50.26% 42%;        /* the lens centre inside the source render */
  will-change: transform, opacity;
}
.la-silk-wrap { z-index: 1; }
.la-lens-wrap { z-index: 2; }
.la-silk,
.la-lens {
  display: block;
  width: 100%;
  height: auto;
  user-select: none;
  -webkit-user-drag: none;
  pointer-events: none;
}
.la-lens { filter: drop-shadow(0 22px 26px rgba(12, 44, 130, 0.16)); }
/* clean lens (no silk seen through the glass) used while the lens floats alone;
   it sits exactly over the silk-wrapped lens and cross-fades out as the silk arrives */
.la-lens-clean {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.la-sec {
  position: absolute;
  width: var(--sec-w);
  z-index: 3;
  will-change: transform, opacity;
}
.la-sec-in { position: relative; }
.la-sec img {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 16px 18px rgba(12, 44, 130, 0.18));
  pointer-events: none;
}

/* ---- Feature call-outs: dot on the lens, hairline, two-line label ----
   .la-tag is a zero-size anchor sitting on the lens; the line and text hang off it.
   Desktop: lenses in two side columns, labels point inward (la-c-l / la-c-r).
   Tablet & mobile: lenses in a top and bottom row, labels point toward the
   centre (la-r-t / la-r-b). */
.la-tag {
  position: absolute;
  left: var(--dx, 50%);
  top: var(--dy, 50%);
  width: 0;
  height: 0;
  z-index: 4;
  pointer-events: none;
  --line: 50px;
}
.la-tag-dot {
  position: absolute;
  left: -4px;
  top: -4px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 0 0 2px rgba(26, 111, 209, 0.55), 0 0 12px 2px rgba(79, 195, 247, 0.85);
}
.la-tag-line {
  position: absolute;
  background: rgba(10, 26, 61, 0.42);
}
.la-tag-txt {
  position: absolute;
  width: max-content;
  max-width: 175px;
  font-family: var(--font-display);
  line-height: 1.25;
}
.la-tag-txt b {
  display: block;
  font-weight: 600;
  font-size: 0.68rem;
  letter-spacing: 1.9px;
  text-transform: uppercase;
  color: var(--color-header);
}
.la-tag-txt small {
  display: block;
  margin-top: 3px;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.58rem;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--color-ink-muted);
}

/* Desktop: two columns of four lenses, labels pointing inward */
.la-sec-ar           { left: 3.5%;  top: 4%; }
.la-sec-uv           { left: 1.5%;  top: 28%; }
.la-sec-bluelight    { left: 3.5%;  top: 52%; }
.la-sec-highindex    { left: 1.5%;  top: 76%; }
.la-sec-photochromic { right: 3.5%; top: 4%; }
.la-sec-polarized    { right: 1.5%; top: 28%; }
.la-sec-impact       { right: 3.5%; top: 52%; }
.la-sec-progressive  { right: 1.5%; top: 76%; }

.la-c-l .la-tag { --dx: 64%; --dy: 50%; }
.la-c-l .la-tag-line { left: 7px; top: 0; width: var(--line); height: 1px; transform-origin: left center; }
.la-c-l .la-tag-txt  { left: calc(var(--line) + 15px); top: 0; transform: translateY(-50%); text-align: left; }
.la-c-r .la-tag { --dx: 36%; --dy: 50%; }
.la-c-r .la-tag-line { right: 7px; top: 0; width: var(--line); height: 1px; transform-origin: right center; }
.la-c-r .la-tag-txt  { right: calc(var(--line) + 15px); top: 0; transform: translateY(-50%); text-align: right; }

/* Tablet: four lenses across the top, four across the bottom */
@media (max-width: 1024px) {
  .la-scroller { --hero-w: min(100vw, calc(var(--la-h) * 1.25)); --cam-end: 0.86; --sec-w: clamp(84px, 14vw, 150px); height: 340vh; }
  .la-sec-ar, .la-sec-photochromic, .la-sec-uv, .la-sec-polarized,
  .la-sec-bluelight, .la-sec-impact, .la-sec-highindex, .la-sec-progressive { left: auto; right: auto; top: auto; bottom: auto; }
  .la-sec-ar           { left: 4%;  top: 3%; }
  .la-sec-uv           { left: 28%; top: 5%; }
  .la-sec-polarized    { left: 52%; top: 3%; }
  .la-sec-bluelight    { left: 76%; top: 5%; }
  .la-sec-photochromic { left: 4%;  bottom: 5%; }
  .la-sec-impact       { left: 28%; bottom: 3%; }
  .la-sec-highindex    { left: 52%; bottom: 5%; }
  .la-sec-progressive  { left: 76%; bottom: 3%; }

  /* anchor sits on the lens edge facing the centre; the dot is placed back on the glass */
  .la-tag { --reach: calc(var(--sec-w) * 0.3); }
  .la-r-t .la-tag { --dx: 50%; --dy: 100%; }
  .la-r-b .la-tag { --dx: 50%; --dy: 0%; }
  .la-r-t .la-tag-dot { top: calc(var(--reach) * -1 - 4px); }
  .la-r-b .la-tag-dot { top: calc(var(--reach) - 4px); }
  .la-r-t .la-tag-line, .la-r-b .la-tag-line { left: 0; right: auto; width: 1px; height: calc(var(--reach) + 6px); }
  .la-r-t .la-tag-line { top: calc(var(--reach) * -1 + 4px); bottom: auto; transform-origin: center top; }
  .la-r-b .la-tag-line { top: -6px; bottom: auto; transform-origin: center bottom; }
  .la-r-t .la-tag-txt, .la-r-b .la-tag-txt { left: 0; right: auto; transform: translateX(-50%); text-align: center; max-width: 21vw; }
  .la-r-t .la-tag-txt { top: 12px; bottom: auto; }
  .la-r-b .la-tag-txt { bottom: 12px; top: auto; }
}

/* Mobile: recomposed — wider hero (silk runs off both sides), three lenses top, three bottom */
@media (max-width: 700px) {
  .la-scroller { --hero-w: 150vw; --cam-end: 0.8; --sec-w: 24vw; height: 300vh; margin-top: 14px; }
  .la-sec-bluelight,
  .la-sec-photochromic { display: none; }
  .la-sec-ar           { left: 5%;  top: 2.5%; }
  .la-sec-uv           { left: 38%; top: 4%; }
  .la-sec-polarized    { left: 71%; top: 2.5%; }
  .la-sec-impact       { left: 5%;  bottom: 2.5%; top: auto; }
  .la-sec-highindex    { left: 38%; bottom: 4%; top: auto; }
  .la-sec-progressive  { left: 71%; bottom: 2.5%; top: auto; }
  .la-tag-dot { left: -3px; top: -3px; width: 6px; height: 6px; }
  .la-r-t .la-tag-txt, .la-r-b .la-tag-txt { max-width: 31vw; }
  .la-r-t .la-tag-txt { top: 9px; }
  .la-r-b .la-tag-txt { bottom: 9px; }
  .la-tag-txt b { font-size: 0.56rem; letter-spacing: 1.1px; }
  .la-tag-txt small { font-size: 0.5rem; letter-spacing: 0.9px; margin-top: 2px; }
}

/* Reduced motion / no JS: a static final composition, no tall scroll track */
.la-static.la-scroller { height: auto; }
.la-static .la-sticky { position: relative; top: 0; height: min(var(--la-h), 760px); }

/* ---- Asymmetric photo mosaic ---- */
.mn-mosaic {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 22px;
  margin-top: 56px;
}
.mn-tile {
  min-width: 0;
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  opacity: 0;
  transform: translateY(40px) scale(0.97);
  transition: opacity 0.75s cubic-bezier(.2,.7,.3,1), transform 0.75s cubic-bezier(.2,.7,.3,1), box-shadow 0.25s ease, scale 0.25s ease;
  box-shadow: 0 10px 30px rgba(10,26,61,0.08);
  will-change: transform;
}
.mn-tile.in-view { opacity: 1; transform: translateY(var(--mn-parallax, 0px)) scale(1); }
.mn-tile:hover { box-shadow: 0 18px 44px rgba(10,26,61,0.16); scale: 1.015; }
.mn-tile .image-placeholder {
  min-height: 0;
  height: 100%;
  margin: 0;
  border-radius: 0;
}

.mn-tile-1 { grid-column: 1 / 5; aspect-ratio: 3 / 4; align-self: start; }
.mn-tile-2 { grid-column: 9 / 13; aspect-ratio: 3 / 4; align-self: start; }
.mn-tile-3 { grid-column: 1 / 6; aspect-ratio: 4 / 5; margin-top: 60px; }
.mn-tile-4 { grid-column: 6 / 9; aspect-ratio: 3 / 4; margin-top: 60px; }
.mn-tile-5 { grid-column: 9 / 13; aspect-ratio: 4 / 3; margin-top: 60px; align-self: start; }

.mn-tile-1 .image-placeholder { background: linear-gradient(145deg, #0a1a3d, #123268); color: rgba(255,255,255,0.75); border: none; }
.mn-tile-2 .image-placeholder { background: linear-gradient(145deg, #eef3f8, #dce6f0); color: var(--color-ink-muted); border: none; }
.mn-tile-3 .image-placeholder,
.mn-tile-4 .image-placeholder,
.mn-tile-5 .image-placeholder { background: var(--color-surface); border: none; color: var(--color-ink-muted); }

/* Photo tiles: lifestyle image on top, short description underneath */
.mn-tile.mn-tile-photo {
  aspect-ratio: auto;
  align-self: start;
  background: #ffffff;
  border: 1px solid var(--color-border);
}
.mn-tile-photo img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 900 / 1130;
  object-fit: cover;
}
.mn-tile-cap { padding: 20px 22px 24px; }
.mn-tile-cap h3 {
  font-family: var(--font-display);
  font-size: 1.08rem;
  font-weight: 600;
  color: var(--color-header);
  margin: 0 0 8px;
}
.mn-tile-cap p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.65;
  color: var(--color-ink-muted);
}

/* Wordmark badge overlaid on one tile, echoing the reference's inline
   brand reveal among the photo grid */
.mn-tile-badge {
  position: absolute;
  right: 16px;
  bottom: 14px;
  z-index: 2;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -0.5px;
  color: var(--color-header);
}

@media (max-width: 900px) {
  .mn-mosaic { grid-template-columns: repeat(6, 1fr); gap: 16px; margin-top: 40px; }
  .mn-tile-1 { grid-column: 1 / 4; }
  .mn-tile-2 { grid-column: 4 / 7; }
  .mn-tile-3 { grid-column: 1 / 4; margin-top: 30px; }
  .mn-tile-4 { grid-column: 4 / 7; margin-top: 30px; }
  .mn-tile-5 { grid-column: 1 / 7; margin-top: 16px; aspect-ratio: 16/9; }
}

@media (max-width: 560px) {
  .meet-nexvue { padding: 60px 0 60px; }
  .mn-title { letter-spacing: -1px; }
  .mn-mosaic { grid-template-columns: 1fr; gap: 16px; margin-top: 28px; }
  .mn-tile-1, .mn-tile-2, .mn-tile-3, .mn-tile-4, .mn-tile-5 { grid-column: 1 / 2; margin-top: 0; aspect-ratio: 4/3; }
  .mn-tile.mn-tile-photo { aspect-ratio: auto; }
  .mn-tile-cap { padding: 16px 18px 20px; }
}
