/* ── hero ── */
.np3-hero {
  position: relative;
  overflow: hidden;
  padding: 152px 0 56px;
  border-radius: 0 0 24px 24px;
  background: #000;
  color: #FFF;
  transition: border-bottom-right-radius .2s ease-in-out;
}

/* layers: the photo, its left fade over it, the copy and the plans on top */
.np3-hero__photo {
  position: absolute;
  z-index: 0;
  top: 0;
  left: calc(50% - 860px);
  width: 1720px;
  height: 752px;
  pointer-events: none;
}

.np3-hero__photo img {
  display: block;
  width: 100%;
  height: 100%;
}

/* fade.left: anchored to the screen edge, not to the centred photo */
.np3-hero::before {
  content: '';
  position: absolute;
  z-index: 1;
  top: 0;
  left: 0;
  width: 1157px;
  height: 752px;
  background: linear-gradient(94.76deg, #000 207px, rgba(0, 0, 0, 0) 1139px) 0 0 / 1157px 786px no-repeat;
  pointer-events: none;
}

.np3-hero__content,
.np3-plans {
  position: relative;
  z-index: 2;
}

.np3-hero__header {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 760px;
  max-width: 100%;
}

.np3-hero__title {
  font-size: 48px;
  font-style: italic;
  font-weight: 900;
  line-height: 48px;
  text-transform: uppercase;
  color: #FFF;
}

.np3-hero__title .green { color: var(--np3-green); }

.np3-hero__lead {
  width: 521px;
  max-width: 100%;
  font-size: 18px;
  font-weight: 500;
  line-height: 26px;
  color: #FFF;
}

.np3-hero__lead b,
.np3-hero__lead strong {
  font-weight: 700;
}

/* ── carousel.switcher: only while the row scrolls ── */
.np3-switch {
  display: none;
  align-items: center;
  gap: 24px;
  width: 360px;
  max-width: 100%;
  margin-top: 40px;
}

.np3-switch__side {
  display: flex;
  flex: 1 0 0;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}

.np3-switch__side--next { justify-content: flex-end; }

.np3-switch__side:disabled { cursor: default; }

.np3-switch__arrow {
  flex: none;
  display: block;
  width: 32px;
  height: 32px;
  color: var(--np3-green);
  transition: opacity .2s ease-in-out;
}

.np3-switch__arrow svg {
  display: block;
  width: 100%;
  height: 100%;
}

.np3-switch__side:disabled .np3-switch__arrow { opacity: .3; }

.np3-switch__label {
  overflow: hidden;
  font-size: 16px;
  font-weight: 900;
  line-height: 24px;
  letter-spacing: .48px;
  text-transform: uppercase;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #FAFAF7;
}

.np3-switch__side:disabled .np3-switch__label { visibility: hidden; }

.np3-switch__dots {
  display: flex;
  flex: none;
  align-items: center;
  gap: 8px;
}

.np3-switch__dot {
  display: block;
  width: 5px;
  height: 5px;
  padding: 0;
  border: 0;
  border-radius: 2.5px;
  background: #FAFAF7;
  cursor: pointer;
  transition: width .2s ease-in-out, height .2s ease-in-out, background-color .2s ease-in-out;
}

.np3-switch__dot.is-active {
  width: 12px;
  height: 12px;
  border-radius: 6px;
  background: var(--np3-green);
}

.np3-switch__side:focus-visible,
.np3-switch__dot:focus-visible {
  outline: 2px solid var(--np3-green);
  outline-offset: 2px;
}

/* ── plans: the row of fixed 290px cards; it swipes inside the rounded panel when it does not fit ── */
.np3-plans {
  --np3-pl: 44px;
  --np3-inset: 0px;

  position: relative;
  width: min(1410px, 100% - 2 * var(--np3-gutter));
  margin: 66px auto 0;
}

.np3-plans__viewport {
  overflow-x: auto;
  overflow-y: hidden;
  border-radius: 24px;
  scroll-snap-type: x mandatory;
  scroll-padding-left: var(--np3-pl);
  scrollbar-width: none;
  overscroll-behavior-x: contain;
}

.np3-plans__viewport::-webkit-scrollbar { display: none; }

.np3-plans__track {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 290px);
  grid-template-rows: repeat(8, auto);
  column-gap: 54px;
  width: max-content;
  padding: 43px 44px 54px var(--np3-pl);
}

/* plans.bg: the glass panel */
.np3-plans__bg {
  position: absolute;
  z-index: 0;
  top: 11px;
  right: var(--np3-inset);
  bottom: 0;
  left: var(--np3-inset);
  border-radius: 24px;
  background: rgba(250, 250, 247, .1);
  -webkit-backdrop-filter: blur(50px);
          backdrop-filter: blur(50px);
}

/* plans.backdrop: white from BETTER to ZEN, from inside the card art down */
.np3-plans__backdrop {
  position: relative;
  z-index: 0;
  grid-column: 2 / 5;
  grid-row: 3 / 9;
  margin: 111px -28px -38px;
  border-radius: 24px;
  background: #FFF;
}

/* ── plans.card: its eight rows sit on the track's rows (subgrid), so a longer text in one card moves the
   same row of every card ── */
.np3card {
  position: relative;
  z-index: 1;
  display: grid;
  grid-row: 1 / span 8;
  grid-template-rows: subgrid;
  justify-items: center;
  align-content: start;
  width: 290px;
  text-align: center;
  scroll-snap-align: start;
}

.np3card--good   { grid-column: 1; }
.np3card--better { grid-column: 2; }
.np3card--best   { grid-column: 3; }
.np3card--zen    { grid-column: 4; }

.np3card__badge {
  position: absolute;
  top: -42px;
  left: calc(50% + .5px);
  padding: 7px 18px;
  border-radius: 24px;
  background: var(--np3-green-dark);
  transform: translateX(-50%);
  font-size: 11px;
  font-weight: 700;
  line-height: 10px;
  letter-spacing: 1.21px;
  text-transform: uppercase;
  white-space: nowrap;
  color: #FFF;
}

.np3card__name {
  font-size: 28px;
  font-weight: 900;
  line-height: 22px;
  letter-spacing: 1px;
  white-space: nowrap;
  color: #FFF;
}

.np3card__tagline {
  width: 100%;
  margin-top: 16px;
  font-size: 14px;
  font-weight: 700;
  line-height: 18px;
  text-transform: uppercase;
  text-wrap: balance;
  text-box: trim-both cap alphabetic;
  color: #FFF;
}

.np3card__tline { display: block; }
.np3card__tline:first-child { color: var(--np3-green); }

.np3card__visual {
  position: relative;
  width: 244px;
  margin-top: 28px;
  padding-bottom: 8px;
}

.np3card__art {
  position: relative;
  display: block;
  width: 244px;
  height: 160px;
}

/* the four card images share one frame */
.np3card__art img {
  position: absolute;
  top: -15.3px;
  left: 2.4px;
  display: block;
  width: 240.6px;
  max-width: none;
  height: 201px;
}

.np3card__play {
  position: absolute;
  top: 88.9px;
  left: 207.7px;
  z-index: 2;
  display: block;
  width: 40px;
  height: 40px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
}

button.np3card__play { cursor: pointer; }

.np3card__play:focus-visible {
  outline: 2px solid var(--np3-green);
  outline-offset: 2px;
}

.np3card__play svg {
  display: block;
  width: 100%;
  height: 100%;
}

/* plan.price */
.np3card__price {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  font-style: italic;
  text-transform: uppercase;
  white-space: nowrap;
  color: #000;
}

.np3card--good .np3card__price { color: #FAFAF7; }

.np3card__amount {
  font-size: 26px;
  font-weight: 900;
  line-height: 48px;
  text-box: trim-both cap alphabetic;
}

.np3card__period {
  font-size: 10px;
  font-weight: 800;
  line-height: 14px;
  text-box: trim-both cap alphabetic;
}

/* proof */
.np3card__proof {
  width: 278px;
  margin-top: 22px;
  font-size: 14px;
  font-weight: 700;
  line-height: 18px;
  text-transform: uppercase;
  text-wrap: balance;
  text-box: trim-both cap alphabetic;
  color: #000;
}

.np3card--good .np3card__proof { color: #FFF; }

.np3card__cline--accent { color: var(--np3-green-dark); }
.np3card__cline + .np3card__cline::before { content: ' '; }

.np3card__cta {
  width: 100%;
  margin-top: 28px;
}

/* plan.you-get, three lines: "you get: everything in" · the plan · "+ the benefit group:" */
.np3card__gets {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  width: 100%;
  margin-top: 16px;
  padding: 12px 0 4px;
  font-size: 13px;
  font-weight: 800;
  line-height: 18px;
  letter-spacing: .52px;
  text-transform: uppercase;
  color: var(--np3-anthracite);
}

.np3card__gline { display: block; }

.np3card__gline:first-child {
  font-weight: 700;
  color: var(--np3-rich-beige);
}

.np3card__gets .green { color: var(--np3-green-dark); }

.np3card__gline:first-child > .green {
  display: block;
  margin-top: 2px;
  font-weight: 900;
}

.np3card--good .np3card__gets { color: #FAFAF7; }
.np3card--good .np3card__gline:first-child { color: var(--np3-beige); }

/* plans.feature */
.np3card__features {
  display: flex;
  flex-direction: column;
  gap: 2px;
  width: 100%;
  margin-top: 16px;
  text-align: left;
}

.np3card__feature {
  display: flex;
  align-items: flex-start;
  gap: 4px;
  padding: 8px 4px 8px 8px;
  border-radius: 10px;
}

.np3card__bullet {
  flex: none;
  display: block;
  width: 20px;
  height: 20px;
  color: var(--np3-green-dark);
}

.np3card__bullet svg {
  display: block;
  width: 100%;
  height: 100%;
}

.np3card__feature-body {
  display: flex;
  flex: 1 0 0;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  font-weight: 500;
  line-height: 20px;
  overflow-wrap: break-word;
}

.np3card__feature-title {
  font-size: 16px;
  color: #000;
}

.np3card__feature-sub {
  font-size: 14px;
  color: var(--np3-rich-beige);
}

.np3card--good .np3card__feature-title { color: #FAFAF7; }
.np3card--good .np3card__feature-sub   { color: var(--np3-beige); }

/* browsers without text-box trimming: the same trim as margins (Nunito: ascent 1.011, descent .353, cap .705) */
@supports not (text-box: trim-both cap alphabetic) {
  .np3 .np3card__tagline,
  .np3 .np3card__proof { margin-bottom: -4.39px; }
  .np3card__tagline { margin-top: 12.26px; }
  .np3card__proof   { margin-top: 18.26px; }
  .np3card__amount  { margin: -14.23px 0 -15.45px; }
  .np3card__period  { margin: -3.24px 0 -3.71px; }
}

/* the row fits from 1490px; below it swipes with the switcher */
@media (max-width: 1489px) {
  .np3-switch { display: flex; }
  .np3-plans  { margin-top: 40px; }
}

@media (max-width: 1439px) {
  .np3-hero__title {
    font-size: 40px;
    line-height: 42px;
  }
}

@media (min-width: 1721px) {
  .np3-hero__photo img {
    -webkit-mask-image: linear-gradient(to left, transparent, #000 160px);
            mask-image: linear-gradient(to left, transparent, #000 160px);
  }
}

/* ── mobile: the full-bleed swipe row ── */
@media (max-width: 999px) {
  /* the right corner rounds once the row is swiped to its end (the row runs on past the screen edge) */
  .np3-hero {
    padding: 149px 0 24px;
    border-bottom-right-radius: 0;
  }

  .np3-hero.is-end {
    border-bottom-right-radius: 24px;
  }

  .np3-hero__photo {
    top: -62px;
    left: calc(50% - 512px);
    width: 1024px;
    height: 540px;
  }

  .np3-hero::before {
    top: -201px;
    width: 219px;
    height: 888px;
    background: linear-gradient(90.8deg, rgba(0, 0, 0, .7) 39.3px, rgba(0, 0, 0, 0) 216.4px);
  }

  .np3-hero__content {
    padding: 0 16px;
  }

  .np3-hero__header {
    gap: 10px;
    width: auto;
  }

  .np3-hero__title {
    max-width: 286px;
    font-size: 24px;
    line-height: 24px;
  }

  .np3-hero__lead {
    width: auto;
    font-size: 16px;
    line-height: 24px;
  }

  .np3-switch {
    display: flex;
    margin-top: 20px;
    padding-bottom: 5px;
  }

  .np3-plans {
    --np3-pl: min(49px, (100vw - 290px) / 2);
    --np3-inset: clamp(8px, (100vw - 360px) / 10 + 8px, 16px);

    width: 100%;
    margin-top: 0;
  }

  .np3-plans__viewport {
    border-radius: 0;
  }

  .np3-plans__track {
    padding: 42px calc(var(--np3-inset) + 44px) 54px var(--np3-pl);
  }

  .np3-plans__bg {
    top: 14px;
  }
}

/* phones: the arrows-only switcher in the middle (tablets keep the plan names on the left, like desktop) */
@media (max-width: 599px) {
  .np3-switch {
    gap: 16px;
    width: auto;
    justify-content: center;
  }

  .np3-switch__side { flex: none; }
  .np3-switch__label { display: none; }
}
