/* Catholic Healthcare | Jemalong — Lead Capture Page
   Figma HPBOIsKY5je02wBLZbTBT6. Desktop is designed at 1469 wide with 120px
   gutters (1229 content); the mobile layout (designed at 375) takes over
   below 900px. Shared by landing-page/ (A) and split-test-b/ (B): keep the
   two copies identical. */

/* ---- Fonts (self-hosted, Google Fonts variable files, latin subset) --- */

@font-face {
  font-family: "Roboto";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("../assets/8ac80aacb27c59d2.woff2") format("woff2");
}

@font-face {
  font-family: "Roboto Slab";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../assets/a0f39819a4f6d450.woff2") format("woff2");
}

/* ---- Tokens ------------------------------------------------------------ */

:root {
  --navy: #003f72;
  --blue: #0073cf;
  --sand: #e0ded8;
  --mist: #f7f7f5;
  --white: #fff;

  --font-body: "Roboto", Arial, sans-serif;
  --font-display: "Roboto Slab", Georgia, serif;

  --gutter: 120px;
  --content: 1229px;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
}

/* ---- Base -------------------------------------------------------------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 18px;
  font-weight: 400;
  line-height: 1.2;
  color: var(--navy);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
p,
ul {
  margin: 0;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

strong {
  font-weight: 700;
}

[id] {
  scroll-margin-top: 20px;
}

.container {
  width: 100%;
  max-width: calc(var(--content) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.mobile-only {
  display: none;
}

/* ---- Type -------------------------------------------------------------- */

/* Text stacks: Figma's auto-layout columns with a 20px gap. Its zero-height
   divider lines add a second gap before buttons; .push stands in for them. */
.stack {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
}

.push {
  margin-top: 20px;
}

.eyebrow {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 500;
  line-height: 1.2;
  text-decoration: underline;
  text-underline-position: from-font;
  text-box: trim-both cap alphabetic;
}

.eyebrow--plain {
  text-decoration: none;
}

.title {
  max-width: 397px;
  font-family: var(--font-display);
  font-size: 40px;
  font-weight: 400;
  line-height: 1.1;
}

.title--villas {
  max-width: 431px;
}

.light,
.details,
.bullets,
.tour-note {
  font-weight: 300;
}

.details span {
  display: block;
}

.bullets {
  padding-left: 0;
  list-style: none;
}

/* Figma sets these as a small text bullet, not the browser's larger disc. */
.bullets li {
  position: relative;
  padding-left: 14px;
}

.bullets li::before {
  content: "\2022";
  position: absolute;
  left: 1px;
}

.price {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
}

/* ---- Buttons ----------------------------------------------------------- */

/* 43px tall like the Figma's cap-trimmed 15px-padded pills. Press feedback
   uses `scale` so it composes with the sticky CTA's translate. */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12.5px 15px;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 500;
  line-height: 1;
  text-align: center;
  text-decoration: none;
  border: 0;
  border-radius: 70px;
  cursor: pointer;
  transition: scale 160ms var(--ease-out), background-color 150ms ease;
}

.button:active {
  scale: 0.97;
}

.button:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
}

.button--blue {
  color: var(--white);
  background: var(--blue);
}

.button--white {
  color: var(--navy);
  background: var(--white);
}

.button--navy {
  color: var(--white);
  background: var(--navy);
}

.hero .button:focus-visible,
.register .button:focus-visible {
  outline-color: var(--white);
}

@media (hover: hover) and (pointer: fine) {
  .button--blue:hover {
    background: #0066b8;
  }

  .button--white:hover {
    background: #eceae5;
  }

  .button--navy:hover {
    background: #00335d;
  }
}

/* ---- Hero -------------------------------------------------------------- */

.hero {
  position: relative;
  min-height: max(640px, 53vw);
  color: var(--white);
  background: var(--navy);
}

.hero__media,
.hero__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

/* The hero grows with the viewport (53vw = the Figma's 779/1469), so on wide
   screens and when zoomed out the photo keeps the designed crop instead of
   losing the couple's heads off the top. Narrower desktops crop the sides. */
.hero__media img {
  object-fit: cover;
  object-position: 65% 100%;
}

/* Split test B darkens the top-left behind the card. */
.hero--b .hero__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(141deg, rgb(0 0 0 / 0.3) 19%, rgb(102 102 102 / 0) 70%);
}

.hero__inner {
  position: relative;
  padding-top: 128px;
  padding-bottom: 80px;
}

.brand {
  position: absolute;
  top: 0;
  left: var(--gutter);
  width: 208px;
  height: auto;
}

.hero__card {
  width: 606px;
  max-width: 100%;
  padding: 37px 39px 37px 30px;
  background: rgb(0 63 114 / 0.7);
  border-radius: 10px;
}

.hero--b .hero__card {
  width: 626px;
  padding-right: 0;
}

.hero__card .hero__text {
  max-width: 537px;
}

.hero__title {
  font-family: var(--font-display);
  font-size: 60px;
  font-weight: 400;
  line-height: 1.1;
}

.hero__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

/* ---- At a glance strip -------------------------------------------------- */

.usps {
  background: var(--sand);
}

.usps__list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 10px 20px;
  padding: 41px var(--gutter);
  font-weight: 700;
  list-style: none;
}

.usps__list li {
  display: flex;
  align-items: center;
  gap: 20px;
}

.usps__list li + li::before {
  content: "";
  width: 7px;
  height: 7px;
  background: url("../assets/33824ec4d58fbac4.svg") center / contain no-repeat;
}

/* ---- Image + text splits ----------------------------------------------- */

.split {
  padding-block: 100px;
}

.split--white {
  background: var(--white);
}

.split--sand {
  background: var(--sand);
}

.split--why {
  padding-block: 80px;
}

.split__inner {
  display: grid;
  grid-template-columns: minmax(0, 606px) minmax(0, 555px);
  justify-content: space-between;
  align-items: center;
  gap: 40px;
}

/* Figma's text column starts 69px after the image and is 500 wide; only
   the When/Where lines run to 515. */
:where(.split__text > *) {
  max-width: 500px;
}

:where(.split__text) > .details {
  max-width: 515px;
}

.split__media {
  position: relative;
  aspect-ratio: 606 / 402;
  overflow: hidden;
  border-radius: 10px;
}

.split__media img:not(.villa__plan):not(.map__pin) {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.villa__photo {
  object-position: 23% 50%;
}

.villa__plan {
  position: absolute;
  right: 3.47%;
  bottom: 4.98%;
  width: 25.08%;
  height: auto;
  border-radius: 10px;
}

.map__pin {
  position: absolute;
  top: 32.6%;
  left: 65.4%;
  width: 31.54px;
  height: auto;
}

/* ---- Life at Jemalong --------------------------------------------------- */

.life {
  padding: 80px 0 100px;
  background: var(--mist);
}

.life__intro .title {
  max-width: 500px;
}

.life__text {
  max-width: 445px;
}

.features {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 20px;
  margin: 58px 0 0;
  padding: 0;
  list-style: none;
}

.feature {
  position: relative;
  min-height: 188px;
  padding: 124px 18px 18px;
  font-family: var(--font-display);
  font-weight: 700;
  background: var(--white);
  border-radius: 10px;
}

.feature span {
  display: block;
  max-width: 145px;
}

/* The Material Symbols glyphs keep their 50px icon-box offsets from Figma. */
.feature__icon {
  --x: 0px;
  --y: 0px;
  position: absolute;
  top: calc(28px + var(--y));
  left: calc(18px + var(--x));
}

.feature__icon--family { --x: 2.086px; --y: 4.167px; }
.feature__icon--gardens { --x: 10.417px; --y: 4.167px; }
.feature__icon--garage { --x: 2.031px; --y: 4.167px; }
.feature__icon--dog { --x: 8.333px; --y: 4.167px; }
.feature__icon--account { --x: 4.167px; --y: 4.167px; }
.feature__icon--heart { --x: 8.333px; --y: 8.333px; }

.features-dots {
  display: none;
}

/* ---- Moving with confidence --------------------------------------------- */

.confidence {
  padding: 80px 0 100px;
  background: var(--mist);
}

.confidence__inner {
  display: grid;
  grid-template-columns: minmax(0, 397px) minmax(0, 812px);
  justify-content: space-between;
  align-items: start;
  gap: 20px;
}

.confidence__card {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 4px;
  padding: 30px;
  background: var(--white);
  border-radius: 10px;
}

.confidence__title {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--blue);
}

/* ---- Trusted ------------------------------------------------------------ */

.trusted {
  position: relative;
  color: var(--white);
  background: var(--navy);
}

.trusted__media,
.trusted__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.trusted__media img {
  object-fit: cover;
}

.trusted__inner {
  position: relative;
  display: flex;
  justify-content: flex-end;
  padding-block: 100px;
}

.trusted__card {
  width: 605px;
  max-width: 100%;
  padding: 33px 36px 34px;
  background: var(--blue);
  border-radius: 10px;
}

/* ---- Register (form section) ------------------------------------------ */

.register {
  color: var(--white);
  background: var(--blue);
}

.register__inner {
  display: grid;
  grid-template-columns: minmax(0, 500px) minmax(0, 604px);
  justify-content: space-between;
  gap: 40px;
  padding-top: 78px;
  padding-bottom: 39px;
}

.register__intro {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding-top: 2px;
}

.register__title {
  max-width: 397px;
  font-family: var(--font-display);
  font-size: 40px;
  font-weight: 400;
  line-height: 1.1;
}

/* The Figma separates the two lines with an empty paragraph. */
.register__text p + p {
  margin-top: 1.2em;
}

.register__form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px 20px;
  align-content: start;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.field__label {
  font-family: var(--font-display);
  font-weight: 700;
}

.field__input {
  width: 100%;
  height: 40px;
  padding: 0 10px;
  font-family: var(--font-body);
  font-size: 18px;
  font-weight: 300;
  color: var(--navy);
  background: var(--white);
  border: 0;
  border-radius: 5px;
  appearance: none;
}

/* Figma uses navy at 20%; lifted for older readers. */
.field__input::placeholder {
  color: var(--navy);
  opacity: 0.45;
}

.field__input:focus-visible {
  outline: 3px solid var(--navy);
  outline-offset: 2px;
}

.check {
  grid-column: 1 / -1;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 8px;
  cursor: pointer;
}

.check__box {
  flex: none;
  width: 20px;
  height: 20px;
  margin: 1px 0 0;
  background: var(--white) center / 14px no-repeat;
  border-radius: 5px;
  appearance: none;
  cursor: pointer;
  transition: background-color 150ms ease;
}

.check__box:checked {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='M2.5 7.5l3 3 6-7' fill='none' stroke='%23003f72' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

.check__box:focus-visible {
  outline: 3px solid var(--navy);
  outline-offset: 2px;
}

.register__submit {
  grid-column: 1 / -1;
  justify-self: start;
  margin-top: 25px;
}

.register__privacy {
  grid-column: 1 / -1;
  max-width: 601px;
  margin-top: 9px;
  font-size: 14px;
  font-style: italic;
}

/* ---- Footer ------------------------------------------------------------- */

.footer {
  color: var(--white);
  background: var(--navy);
}

.footer__inner {
  display: grid;
  grid-template-columns: minmax(0, 500px) minmax(0, 605px);
  justify-content: space-between;
  gap: 40px;
  padding-top: 60px;
}

.footer__logo {
  align-self: end;
  width: 312px;
  height: auto;
}

.footer__text {
  padding-bottom: 73px;
}

.footer__call {
  font-family: var(--font-display);
  line-height: 1.1;
}

.footer__call a {
  text-decoration: none;
}

.footer__legal {
  margin-top: 40px;
  font-size: 14px;
  font-weight: 300;
}

.footer__legal p + p {
  margin-top: 1.2em;
}

.footer__legal a {
  text-decoration-skip-ink: none;
  overflow-wrap: anywhere;
}

/* ---- Sticky mobile CTA ---------------------------------------------------- */

.sticky-cta {
  display: none;
}

/* ---- Tablet ------------------------------------------------------------ */

@media (max-width: 1199px) {
  :root {
    --gutter: 60px;
  }

  .features {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* ---- Mobile ------------------------------------------------------------ */

@media (max-width: 899px) {
  :root {
    --gutter: 30px;
  }

  body {
    font-size: 16px;
  }

  .desktop-only {
    display: none;
  }

  .mobile-only {
    display: inline;
  }

  .title {
    max-width: 314px;
    font-size: 30px;
  }

  .life__intro .title,
  .title--villas {
    max-width: 314px;
  }

  .details strong {
    display: block;
  }

  .price {
    font-size: 20px;
  }

  /* Hero: photo on top, copy on solid navy underneath. */
  .hero {
    min-height: 0;
  }

  .hero__media {
    position: relative;
    display: block;
    height: auto;
    aspect-ratio: 375 / 352;
    max-height: 520px;
  }

  /* Tablets hit the max-height and crop: keep the heads, lose the grass. */
  .hero__media img {
    object-position: 60% 0;
  }

  .hero__inner {
    position: static;
    padding-top: 25px;
    padding-bottom: 30px;
  }

  .hero__card,
  .hero--b .hero__card {
    width: auto;
    padding: 0;
    background: none;
    border-radius: 0;
  }

  .hero__title {
    font-size: 30px;
  }

  .hero__text {
    font-size: 16px;
  }

  .hero__ctas {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
    margin-top: 0;
  }

  .usps__list {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding: 33px var(--gutter) 35px;
    font-size: 18px;
  }

  .usps__list li {
    position: relative;
    padding-left: 26px;
  }

  .usps__list li::before,
  .usps__list li + li::before {
    content: "";
    position: absolute;
    top: 7px;
    left: 0;
    width: 7px;
    height: 7px;
    background: url("../assets/33824ec4d58fbac4.svg") center / contain no-repeat;
  }

  .split,
  .split--why {
    padding-block: 30px 44px;
  }

  .split--why {
    padding-top: 37px;
  }

  .split__inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 30px;
  }

  .split__media {
    aspect-ratio: 317 / 211;
  }

  .villa__photo {
    object-position: 50% 50%;
  }

  .villa__plan {
    right: 3.15%;
    bottom: 4.74%;
    width: 32.8%;
  }

  .map__pin {
    top: 24.9%;
    left: 64.9%;
    width: 25.8px;
  }

  .tour-note {
    font-size: 18px;
  }

  .button--villas {
    color: var(--white);
    background: var(--blue);
  }

  /* Features become a two-up swipe carousel with page dots. */
  .life {
    padding: 38px 0 54px;
  }

  .life__text {
    font-weight: 300;
  }

  .features {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: calc((100% - 20px) / 2);
    margin-top: 46px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }

  .features::-webkit-scrollbar {
    display: none;
  }

  .features:focus-visible {
    outline: 3px solid var(--blue);
    outline-offset: 4px;
  }

  .feature {
    padding: 124px 16px 16px;
    font-size: 18px;
    scroll-snap-align: start;
  }

  .feature span {
    max-width: 112px;
  }

  .feature__icon {
    top: calc(26px + var(--y));
    left: calc(16px + var(--x));
  }

  .features-dots {
    display: flex;
    justify-content: center;
    gap: 5px;
    margin-top: 58px;
  }

  .features-dots span {
    width: 10px;
    height: 10px;
    background: var(--blue);
    border-radius: 50%;
    opacity: 0.1;
    transition: opacity 200ms ease;
  }

  .features-dots .is-active {
    opacity: 1;
  }

  .confidence {
    padding: 38px 0;
  }

  .confidence__inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }

  .confidence__text {
    max-width: 314px;
  }

  .confidence__card {
    gap: 10px;
    margin-top: 0;
    padding: 20px 28px 24px 20px;
  }

  .confidence__card p {
    font-size: 16px;
  }

  .trusted__inner {
    align-items: flex-end;
    min-height: 798px;
    padding-block: 30px;
  }

  .trusted__card {
    width: 100%;
    min-height: 416px;
    padding: 21px 29px 30px 20px;
    font-size: 18px;
  }

  .register__inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 43px;
    padding-top: 39px;
    padding-bottom: 37px;
  }

  .register__intro {
    padding-top: 0;
  }

  .register__title {
    max-width: 314px;
    font-size: 30px;
  }

  .register__text {
    font-size: 18px;
  }

  .register__form {
    grid-template-columns: minmax(0, 1fr);
    gap: 21px;
  }

  .field {
    gap: 7px;
  }

  .check {
    margin-top: 8px;
    gap: 13px;
  }

  .register__submit {
    justify-self: stretch;
    margin-top: 7px;
  }

  .register__privacy {
    margin-top: 6px;
    font-size: 16px;
    font-style: normal;
  }

  .footer__inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
    padding-top: 38px;
  }

  .footer__text {
    order: -1;
    padding-bottom: 0;
  }

  .footer__logo {
    width: min(315px, 100%);
    margin-top: 118px;
  }

  /* Shows once the hero is gone, except while the form is on screen
     (main.js); hidden without JS. The Figma rests it above the footer logo. */
  .sticky-cta {
    position: fixed;
    bottom: 16px;
    left: 50%;
    z-index: 10;
    display: flex;
    width: min(315px, calc(100% - 2 * var(--gutter)));
    box-shadow: 0 6px 20px rgb(0 31 57 / 0.25);
    visibility: hidden;
    translate: -50% calc(100% + 24px);
    transition: translate 300ms var(--ease-out), scale 160ms var(--ease-out), visibility 0s linear 300ms;
  }

  .sticky-cta.is-visible {
    visibility: visible;
    translate: -50% 0;
    transition: translate 300ms var(--ease-out), scale 160ms var(--ease-out), visibility 0s;
  }
}

@media (prefers-reduced-motion: reduce) {
  .button,
  .check__box,
  .features-dots span {
    transition: none;
  }

  .button:active {
    scale: none;
  }

  .sticky-cta,
  .sticky-cta.is-visible {
    translate: -50% 0;
    opacity: 0;
    transition: opacity 150ms ease, visibility 0s linear 150ms;
  }

  .sticky-cta.is-visible {
    opacity: 1;
    transition: opacity 150ms ease;
  }
}
