/* XMODEL — home page styles. Page-local only; the design system lives in xm.css (frozen).
   Owns: band backgrounds + drift, hero video box, the featured product cards, the motion
   tabs, the paint-room stagger, tier cards, how-it-works, inquiry layout, FAQ, and the
   tap-target lifts needed to clear 44px without touching xm.css. */

/* ---------------------------------------------------------------- 1. bands */
.band { isolation: isolate; }
.band > .wrap { position: relative; z-index: 1; }
/* a band background paints at -2 so .grid-horizon (-1, from xm.css) stays above it
   and the band content (z-index 1) stays above both */
.band::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background-repeat: no-repeat;
  background-size: cover;
  background-position: 50% 50%;
  pointer-events: none;
}

.band-build::before {
  background-image:
    radial-gradient(120% 80% at 12% 0%, rgba(138, 92, 255, .18), transparent 62%),
    radial-gradient(90% 70% at 96% 10%, rgba(0, 229, 255, .12), transparent 60%),
    linear-gradient(180deg, rgba(8, 6, 15, .2), rgba(8, 6, 15, .9));
}

.band-motion::before {
  background-image:
    radial-gradient(110% 70% at 88% 4%, rgba(255, 46, 136, .16), transparent 62%),
    linear-gradient(180deg, rgba(15, 10, 30, .55), rgba(8, 6, 15, .95));
}

/* paint room: real backdrop image under an ink wash, drifting slowly */
.band-paint::before {
  background-image:
    linear-gradient(180deg, rgba(8, 6, 15, .93), rgba(8, 6, 15, .97)),
    url("/assets/img/brand/xmodel-backdrop-02.webp");
  background-size: cover, 118% auto;
  background-position: 50% 50%, 50% 38%;
  animation: band-drift 46s ease-in-out infinite alternate;
}

.band-tiers::before {
  background-image:
    linear-gradient(180deg, rgba(8, 6, 15, .9), rgba(8, 6, 15, .97)),
    url("/assets/img/brand/xmodel-backdrop-03.webp");
  background-size: cover, 116% auto;
  background-position: 50% 50%, 62% 46%;
  animation: band-drift 58s ease-in-out infinite alternate-reverse;
}

.band-how::before {
  background-image: linear-gradient(180deg, rgba(15, 10, 30, .6), rgba(8, 6, 15, .95));
}

.band-inquire::before {
  background-image:
    radial-gradient(100% 80% at 4% 100%, rgba(255, 46, 136, .16), transparent 60%),
    linear-gradient(180deg, rgba(8, 6, 15, .8), rgba(15, 10, 30, .95));
}

.band-discreet::before {
  background-image: linear-gradient(96deg, rgba(138, 92, 255, .14), rgba(0, 229, 255, .1));
}

/* the film band keeps a quiet wash so the film itself is the bright thing */
.band-film::before {
  background-image:
    radial-gradient(100% 70% at 10% 0%, rgba(0, 229, 255, .13), transparent 62%),
    radial-gradient(90% 70% at 94% 100%, rgba(255, 46, 136, .12), transparent 60%),
    linear-gradient(180deg, rgba(8, 6, 15, .8), rgba(15, 10, 30, .95));
}

@keyframes band-drift {
  from { background-position: 50% 50%, 50% 34%; }
  to   { background-position: 50% 50%, 50% 62%; }
}

/* ------------------------------------------------------- 2. band furniture */
.band-head { display: grid; gap: 12px; max-width: 74ch; }
.band-head .eyebrow { margin: 0; }
.band-head h2 { margin: 0; }
.band-head .lead { margin: 0; }
.band .hr { margin-block: clamp(22px, 3.4vw, 38px); }

.center-cta {
  margin-top: clamp(20px, 3vw, 34px);
  display: flex;
  justify-content: center;
}

.small { font-size: 12px; letter-spacing: .1em; }

/* the hero text sits above the .scanlines::before overlay (z-index 1 in xm.css) */
.hero .wrap { position: relative; z-index: 2; }
.hero-eyebrow { margin: 0 0 2px; }

/* ------------------------------------------------------------- 3. hero image */
/* The hero is the client's chosen pose, outpainted to a portrait canvas:
   /assets/img/hero/hero-electric-dream-9x16.webp (1080 x 1920, exact 9:16).
   The panel is 9:16 at every width and the still fills it with object-fit:cover,
   so the two ratios cancel — nothing is cropped and her head stays whole from
   320 px up. object-position only matters if a future asset is not exactly 9:16;
   it leans high so the head is what survives such a crop. */
.hv {
  position: relative;
  aspect-ratio: 9 / 16;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: #05040C;
  box-shadow: var(--shadow), 0 0 34px rgba(255, 46, 136, .18);
}
.hv-img {
  display: block;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 38%;
}
.hv::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: var(--r);
  pointer-events: none;
  background: linear-gradient(180deg, rgba(0, 229, 255, .1), transparent 34%, rgba(255, 46, 136, .12));
  mix-blend-mode: screen;
}
/* Tablet and below (xm.css drops the two-column wrap under 1040): the wrap is a
   single column, so the panel becomes a stacked row. Its width is driven by the
   height cap rather than the other way round, so the 9:16 ratio is never clamped:
   85vh tall, capped by what the column can hold. */
@media (max-width: 1039px) {
  .hv {
    grid-area: auto;
    width: min(100%, calc(85vh * 9 / 16), 520px);
    height: auto;
    max-width: none;
    justify-self: center;
  }
}
/* Phone: the hero is the portrait itself. The panel breaks out of the wrap gutter
   to run edge to edge; the copy stacks under it, off her face. */
@media (max-width: 767px) {
  .hero .wrap {
    grid-template-areas: "video" "eyebrow" "h1" "sub" "cta" "facts";
    padding-block: 92px 52px;
  }
  .hv {
    grid-area: video;
    width: auto;
    height: auto;
    max-width: none;
    justify-self: stretch;
    margin-inline: calc(-1 * var(--gutter));
    border: 0;
    border-radius: 0;
  }
}
/* Desktop: the tall portrait panel beside the text column. Width comes from the
   height cap (88vh) through the 9:16 ratio, then a hard 480 px ceiling so the
   headline column keeps room at 2560. The hero itself stops holding an aspect
   ratio — a portrait hero is taller than the old 1600/880 frame. */
@media (min-width: 1040px) {
  .hero { aspect-ratio: auto; }
  .hv {
    width: min(38vw, calc(88vh * 9 / 16), 480px);
    height: auto;
    max-width: none;
  }
}

/* ------------------------------------------------ 3b. the welcome film */
.film {
  /* The film is a player card, not a wall. Two caps decide its width and whichever
     bites first wins: a card ceiling, so on a 2560 monitor it reads as something you
     watch instead of a page-wide slab, and a height budget through the 16:9 ratio,
     because the film's height is decided by its width and on a short window a
     full-width frame is taller than the screen and can never all be seen. Centred,
     so the shrinking looks deliberate rather than accidental.
     --film-chrome is the band's own furniture around the card — eyebrow, headline,
     lead, the rule over it and the caption underneath, including the 12px gap. It is
     measured, not guessed: 386px worst case at 320px wide where the caption wraps to
     two lines, 331px at 390, 350-360px from 1280 up; 396 leaves 10px of slack at the
     worst width for a longer headline or a taller font stack. The card ceiling stops
     biting below ~1066px of height, and the height budget stops biting below 820px of
     column; at 820 the frame is 461px tall, so the two caps cross over cleanly.
     The svh line wins where the browser knows it — mobile URL bars make vh lie. */
  --film-card: 820px;
  --film-chrome: 396px;
  max-width: min(var(--film-card), calc((100vh - var(--film-chrome)) * 16 / 9));
  max-width: min(var(--film-card), calc((100svh - var(--film-chrome)) * 16 / 9));
  margin-block: 0;
  margin-inline: auto;
  display: grid;
  gap: 12px;
}

/* the film is the only 16:9 object on the page; it takes the panel treatment
   the portrait hero uses — same border, radius, shadow — in landscape */
.film-video {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  /* the plate is a fixed 16:9 and the poster is 1376x768, so nothing is cropped today;
     cover is the guarantee that a later poster at another ratio fills the plate instead
     of letterboxing inside it at 390px */
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: #05040C;
  box-shadow: var(--shadow), 0 0 34px rgba(0, 229, 255, .16);
}

.film figcaption { color: var(--muted); }

/* ------------------------------------------------- 4. what we build — cards */
.hud {
  display: block;
  width: 96px;
  height: auto;
  color: var(--cyan);
  filter: drop-shadow(0 0 8px rgba(0, 229, 255, .45));
}
.card:nth-child(2n) .hud { color: var(--magenta); filter: drop-shadow(0 0 8px rgba(255, 46, 136, .45)); }
.card:nth-child(3n) .hud { color: var(--violet); filter: drop-shadow(0 0 8px rgba(138, 92, 255, .45)); }
.card .pad > p { color: var(--muted); }
.card .pad > p.mono { color: var(--chrome); }

/* ------------------------------------------------------ 5. the line — pcards */
/* six featured bodies: three across on desktop, two on tablet, one on phone.
   minmax(0, 1fr) keeps a long code line or a wide spec row from pushing the
   track past the wrap and putting a scrollbar on the page. */
.featured { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 640px) { .featured { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1040px) { .featured { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.pcard {
  display: grid;
  gap: 0;
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
  background: rgba(15, 10, 30, .7);
  transition: transform var(--t), border-color var(--t), box-shadow var(--t);
}
.pcard:hover { transform: translateY(-4px); border-color: rgba(255, 46, 136, .42); box-shadow: var(--shadow); }
.pcard .pad { padding: clamp(16px, 2vw, 22px); display: grid; gap: 10px; align-content: start; }
.pcard h3 { font-family: var(--f-display); font-size: 19px; letter-spacing: .03em; margin: 0; }
.pcard h3 a { color: inherit; text-decoration: none; display: inline-block; padding-block: 12px; }
.pcard h3 a:hover { color: var(--cyan); }
.pcard .code { color: var(--chrome); font-family: var(--f-mono); font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase; }
.pcard .price {
  font-family: var(--f-display);
  font-size: clamp(20px, 2.4vw, 26px);
  color: var(--text);
  letter-spacing: .02em;
}
.pcard .quick {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
}
.pcard .quick b { color: var(--chrome); font-weight: 400; }
.pcard .row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.pcard .row .btn { flex: 1 1 auto; }

/* --------------------------------------------------- 6. movement — the tabs */
.motion-layout {
  display: grid;
  gap: clamp(20px, 3vw, 40px);
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
}
@media (min-width: 1000px) {
  .motion-layout { grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); }
}

.tabbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: clamp(14px, 2vw, 20px);
}
.tab {
  min-height: 44px;
  padding: 10px 16px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: rgba(8, 6, 15, .5);
  color: var(--chrome);
  font-family: var(--f-mono);
  font-size: 12.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color var(--t), border-color var(--t), box-shadow var(--t), background var(--t);
}
.tab:hover { color: var(--text); border-color: rgba(0, 229, 255, .45); }
.tab[aria-selected="true"] {
  color: #0A0714;
  background: var(--grad-neon);
  border-color: transparent;
  box-shadow: var(--glow-magenta);
}

.panel {
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: linear-gradient(180deg, rgba(23, 16, 51, .72), rgba(8, 6, 15, .88));
  padding: clamp(16px, 2vw, 26px);
  display: grid;
  gap: 10px;
  animation: panel-in 260ms cubic-bezier(.2, .7, .2, 1) both;
}
.panel[hidden] { display: none; }
.panel h3 { margin: 0; }
.panel > p { color: var(--muted); }
.panel .detail { color: var(--chrome); font-size: 15.5px; }
.panel .carry {
  margin: 4px 0 0;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--cyan);
}
@keyframes panel-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.motion-fig { margin: 0; display: grid; gap: 10px; }
.motion-fig img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: #05040C;
}
.motion-fig figcaption { color: var(--muted); font-size: 14px; }

.band-motion .pulse-line { margin-block: clamp(30px, 4vw, 52px); }

.statband { text-align: center; }
.stat {
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: rgba(8, 6, 15, .55);
  padding: clamp(14px, 2vw, 22px);
  display: grid;
  gap: 6px;
}
.stat b {
  font-family: var(--f-display);
  font-size: clamp(26px, 3.6vw, 42px);
  font-weight: 400;
  letter-spacing: .02em;
  color: var(--text);
  text-shadow: 0 0 22px rgba(0, 229, 255, .35);
}
.stat span {
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---------------------------------------------------------- 7. paint room */
/* six tiles: two rows of three on a desktop, two columns below 720px, one below 480px.
   The track floor is minmax(0, 1fr) rather than auto so a long caption or a wide source
   image can never push a column past its share and give the page a horizontal scroll at
   360px. Tiles keep a 4:5 plate whatever the source ratio is, so the mosaic stays even
   when the bench-test pair is dropped in at its own size. */
.paint-grid {
  display: grid;
  gap: clamp(14px, 2vw, 26px);
  grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 480px) { .paint-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 720px) { .paint-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.paint-grid figure { margin: 0; display: grid; gap: 8px; }
.paint-grid img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: #05040C;
  transition: transform var(--t), box-shadow var(--t);
}
.paint-grid figure:hover img { transform: translateY(-4px); box-shadow: 0 0 30px rgba(255, 46, 136, .3); }
.paint-grid figcaption { color: var(--muted); font-size: 13.5px; letter-spacing: .04em; }

/* ------------------------------------------------------ 8. price and tiers */
.card.tier { border-top-width: 2px; }
.card.tier .price-line { margin: 0; font-size: clamp(21px, 2.6vw, 29px); }
.card.tier p { color: var(--muted); }
.card.tier .count { color: var(--chrome); font-family: var(--f-mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; }
.score-signal { border-top-color: rgba(168, 240, 212, .6); }
.score-signature { border-top-color: rgba(0, 229, 255, .6); }
.score-chrome { border-top-color: rgba(255, 46, 136, .6); }
.score-signal:hover { border-color: rgba(168, 240, 212, .45); }
.score-signature:hover { border-color: rgba(0, 229, 255, .5); }
.score-chrome:hover { border-color: rgba(255, 46, 136, .5); }
.card.tier .btn { margin-top: 4px; }

.tick { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.tick li { position: relative; padding-left: 18px; color: var(--muted); font-size: 15px; }
.tick li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: .58em;
  width: 6px;
  height: 6px;
  background: var(--cyan);
  box-shadow: 0 0 8px rgba(0, 229, 255, .7);
}
.tick li b { color: var(--text); font-weight: 600; }

.tier-note {
  margin: clamp(20px, 3vw, 32px) 0 0;
  padding: 14px 18px;
  border-left: 2px solid var(--magenta);
  background: rgba(255, 46, 136, .07);
  color: var(--amber);
  font-family: var(--f-mono);
  font-size: 13px;
  letter-spacing: .06em;
}

/* --------------------------------------------------------- 9. how it works */
.how-layout { display: grid; gap: clamp(22px, 3vw, 40px); grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1000px) { .how-layout { grid-template-columns: minmax(0, 1.5fr) minmax(0, .8fr); } }

.side-card {
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: linear-gradient(180deg, rgba(23, 16, 51, .7), rgba(8, 6, 15, .9));
  padding: clamp(16px, 2vw, 24px);
  display: grid;
  gap: 12px;
  align-self: start;
}
.side-card h3 { margin: 0; font-family: var(--f-display); font-size: 18px; letter-spacing: .03em; }
.side-card .mono { color: var(--chrome); }

.steps .step:last-child { padding-bottom: 4px; }
.step h3 { margin: 0 0 6px; }
.step p { margin: 0; }

/* ------------------------------------------------------ 10. discreet band */
.discreet {
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: rgba(8, 6, 15, .62);
  padding: clamp(20px, 3vw, 36px);
  display: grid;
  gap: 14px;
}
.discreet h2 { margin: 0; }
.discreet .lead { margin: 0; max-width: 62ch; }
.discreet .tick { margin-top: 4px; }

/* ------------------------------------------------------ 11. inquire block */
.inquire-layout { display: grid; gap: clamp(22px, 3vw, 42px); grid-template-columns: minmax(0, 1fr); }
@media (min-width: 960px) { .inquire-layout { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); } }
.inquire-layout .sent,
.inquire-layout .failed { margin-top: 14px; }

.chk { min-height: 44px; }

/* --------------------------------------------------------------- 12. FAQ */
.faq details { border-color: var(--line); }
.faq summary { font-size: 16px; }
.faq .a { line-height: 1.6; }
.faq .a a { color: var(--cyan); }

/* --------------------------------------------- 13. no-JS / crawler fallback */
.nslist { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.nslist a {
  color: var(--chrome);
  font-family: var(--f-mono);
  font-size: 12.5px;
  letter-spacing: .06em;
  text-decoration: none;
}
.nslist a:hover { color: var(--cyan); }

/* ----------------------------------------------------------- 14. focus/a11y */
.pcard:focus-within { border-color: rgba(0, 229, 255, .45); }
.slider:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; }

/* smaller phones: keep the hero facts and the card grids clear of the gutter */
@media (max-width: 420px) {
  .statband .stat { padding: 12px; }
  .pcard .row .btn { flex: 1 1 100%; }
}
