:root {
  --cream: #fefaf7;
  --cream-2: #f7f1ec;
  --ink: #020208;
  --pink: #fd0260;
  --cyan: #0accf6;
  --night: #000003;
  --shadow: 0 8px 24px rgba(0, 0, 0, .15);
  --font-display: "Archivo Black", "Arial Black", sans-serif;
  --font-body: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-hand: "Kalam", "Comic Sans MS", cursive;
  --gutter: 64px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--cream);
  color: #000;
  font-family: var(--font-body);
  font-weight: 600;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
h1, h2, h3, p, ol { margin: 0; padding: 0; }
a { color: inherit; text-decoration: none; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  height: 48px;
  padding: 12px 24px;
  border-radius: 100px;
  font-size: 16px;
  line-height: 20px;
  font-weight: 600;
  white-space: nowrap;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  transition: background-color .2s, color .2s, border-color .2s, transform .15s ease-out, box-shadow .2s;
}
.btn img { width: 18px; height: 24px; transition: transform .2s ease-out; }
.btn:hover img { transform: translateX(4px); }
.btn:active { transform: translateY(1px) scale(.97); transition-duration: .06s; }
.btn:focus-visible { outline: 3px solid var(--cyan); outline-offset: 2px; }

.btn--outline { border: 2px solid var(--ink); color: #000; }
.btn--outline:hover { background: var(--ink); color: var(--cream); transform: translateY(-2px); box-shadow: 0 6px 16px rgba(2, 2, 8, .2); }
.btn--outline:active { background: #26262e; border-color: #26262e; box-shadow: none; transform: translateY(1px) scale(.97); }

.btn--primary { background: var(--pink); color: var(--cream); padding-right: 20px; }
/* light sweep across the button on hover */
.btn--primary::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .35) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform .6s ease-out;
}
.btn--primary:hover { background: #ff1a70; transform: translateY(-2px); box-shadow: 0 8px 22px rgba(253, 2, 96, .4); }
.btn--primary:hover::before { transform: translateX(120%); }
.btn--primary:active { background: #d4004f; box-shadow: 0 2px 8px rgba(253, 2, 96, .35); transform: translateY(1px) scale(.97); }

.btn--big { height: 56px; font-size: 20px; line-height: 24px; }

/* click ripple (added by main.js) */
.ripple {
  position: absolute;
  z-index: -1;
  border-radius: 50%;
  background: rgba(255, 255, 255, .45);
  transform: scale(0);
  animation: ripple .55s ease-out forwards;
  pointer-events: none;
}
.btn--outline .ripple { background: rgba(254, 250, 247, .35); }
@keyframes ripple { to { transform: scale(1); opacity: 0; } }

.logo { display: inline-block; border-radius: 6px; transition: transform .2s ease-out, opacity .2s; }
.logo:hover { transform: scale(1.04); }
.logo:active { transform: scale(.97); opacity: .85; }
.logo:focus-visible { outline: 3px solid var(--cyan); outline-offset: 4px; }

/* ---------- Header ---------- */
.header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
  padding: 10px var(--gutter);
  background: var(--cream);
}
.logo img { width: 186px; height: 34px; }
.auth { display: flex; gap: 10px; }

/* ---------- Hero ---------- */
.eyebrow {
  font-size: 14px;
  line-height: 28px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
}
.hero {
  position: relative;
  margin-top: -58px;
  height: clamp(560px, 48.9vw, 939px);
}
.hero__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 27%;
  background: linear-gradient(to bottom, rgba(254, 249, 241, 0), var(--cream));
}
.hero__content {
  position: absolute;
  z-index: 1;
  left: var(--gutter);
  top: clamp(180px, 13.1vw, 252px);
  width: 445px;
}
.hero__title {
  margin-top: 8px;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(64px, 5vw, 96px);
  line-height: 1;
  letter-spacing: -2px;
  color: var(--ink);
}
.hero__lead { margin-top: 12px; font-size: 24px; line-height: 1.3; }
.hero__cta { margin-top: 32px; width: 100%; }

/* ---------- Tiles ---------- */
.tile {
  position: relative;
  overflow: hidden;
  border-radius: 16px;
  background: linear-gradient(to bottom, var(--cream), var(--cream-2));
  box-shadow: var(--shadow);
  transition: transform .25s ease-out, box-shadow .25s ease-out;
}
.tile:hover { transform: translateY(-6px); box-shadow: 0 16px 36px rgba(0, 0, 0, .18); }
.tile:active { transform: translateY(-2px) scale(.985); box-shadow: 0 6px 18px rgba(0, 0, 0, .16); transition-duration: .08s; }

/* ---------- Benefits ---------- */
.benefits {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 380px));
  justify-content: center;
  gap: 24px;
  margin: -52px auto 0;
  padding: 0 var(--gutter);
}
.benefit {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  height: 260px;
  padding: 12px 22px;
  text-align: center;
}
.benefit h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 24px;
  line-height: 28px;
  letter-spacing: -1px;
  color: var(--ink);
}
.benefit p { margin-top: 8px; font-size: 20px; line-height: 24px; }
.benefit__icon {
  position: relative;
  flex: none;
  width: 100px;
  height: 100px;
  overflow: hidden;
}
.benefit__icon::before {
  content: "";
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: 441.38%;
  height: 300.29%;
  background: url("assets/benefit-icons.png") 0 0 / 100% 100% no-repeat;
}
/* Icon drifts with scroll position (--p: -1 below centre .. 1 above, set by main.js) */
.benefit__icon {
  translate: 0 calc(var(--p, 0) * -14px);
  rotate: calc(var(--p, 0) * 10deg);
  transition: scale .3s cubic-bezier(.34, 1.56, .64, 1);
}
.benefit:hover .benefit__icon { scale: 1.12; }
.benefit:active .benefit__icon { scale: .95; }

/* Scroll reveal: cards rise in one after another, and fall back when scrolled away */
.js .benefit {
  --d: calc(var(--i, 0) * 90ms);
  transition:
    opacity .6s ease-out var(--d),
    translate .7s cubic-bezier(.22, 1, .36, 1) var(--d),
    scale .7s cubic-bezier(.22, 1, .36, 1) var(--d),
    transform .25s ease-out,
    box-shadow .25s ease-out;
}
.js .benefit:not(.is-visible) { opacity: 0; translate: 0 48px; scale: .94; }

/* ---------- How it works ---------- */
.how {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  margin: 39px auto 0;
  padding: 0 var(--gutter) 54px;
}
.how__title {
  position: relative;
  flex: none;
  width: 348px;
  height: 281px;
}
.how__title h2 {
  position: absolute;
  left: 50%;
  top: 46px;
  width: max-content;
  font-family: var(--font-hand);
  font-weight: 700;
  font-size: 77.7px;
  line-height: 69.3px;
  transform: translateX(-50%) rotate(-8.05deg);
}
.how__title img {
  position: absolute;
  left: 41px;
  top: 116px;
  width: 279px;
  height: 139px;
  object-fit: cover;
  transform: rotate(6.95deg);
}
.how__cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 380px));
  gap: 24px;
  list-style: none;
}
.step {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 8px;
  height: 260px;
  padding: 24px 22px;
}
.step__num {
  position: absolute;
  left: 24px;
  top: 24px;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--cyan);
  font-size: 26px;
  line-height: 26px;
  font-weight: 800;
  transition: background-color .2s, scale .3s cubic-bezier(.34, 1.56, .64, 1);
}
.step:hover .step__num { background: var(--pink); color: var(--cream); scale: 1.1; }
.step__img { transition: rotate .35s cubic-bezier(.34, 1.56, .64, 1), scale .35s cubic-bezier(.34, 1.56, .64, 1); }
.step:hover .step__img { rotate: -6deg; scale: 1.08; }
.step__img {
  position: absolute;
  right: 14px;
  top: 8px;
  width: 139px;
  height: 139px;
}
.step h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 32px;
  line-height: 36px;
  letter-spacing: -1px;
  color: var(--ink);
}
.step p { font-size: 20px; line-height: 24px; max-width: 290px; }

/* ---------- Reach ---------- */
.reach {
  position: relative;
  overflow: hidden;
  height: max(600px, 43vw);
  max-height: 825px;
  background: var(--night);
  color: var(--cream);
}
.reach__map {
  position: absolute;
  left: 16%;
  top: -22%;
  width: 84%;
  height: 146.7%;
  object-fit: cover;
}
.reach::before, .reach::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}
/* left text fade + right edge fade */
.reach::before {
  background:
    linear-gradient(to right, var(--night) 18.6%, rgba(0, 0, 3, 0) 34.5%),
    linear-gradient(to right, var(--night), rgba(0, 0, 3, 0) 40.6%),
    linear-gradient(to left, rgba(0, 0, 3, .67), rgba(0, 0, 3, 0) 22%);
}
/* bottom fade */
.reach::after {
  background: linear-gradient(to top, var(--night) 9%, rgba(0, 0, 3, 0) 43%);
}
.reach__content {
  position: absolute;
  z-index: 1;
  left: var(--gutter);
  top: 50%;
  width: 403px;
  transform: translateY(-50%);
}
.reach__title {
  margin-top: 8px;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 68px;
  line-height: 1.2;
  letter-spacing: -2px;
  color: #fdf9f6;
}
.reach__title span { display: block; color: var(--pink); }
.reach__lead { margin-top: 12px; font-size: 24px; line-height: 1.3; }
.reach__cta { margin-top: 32px; width: 365px; }

br.d { display: inline; }

/* ---------- Laptop ---------- */
@media (max-width: 1440px) {
  .how { flex-direction: column; gap: 8px; }
}
@media (max-width: 1100px) {
  :root { --gutter: 32px; }
  .benefits { grid-template-columns: repeat(2, minmax(0, 380px)); }
  .how__cards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .step p { font-size: 17px; line-height: 22px; }
  .step__img { width: 110px; height: 110px; }
}

/* ---------- Tablet / Mobile ---------- */
@media (max-width: 767px) {
  :root { --gutter: 12px; }
  br.d { display: none; }

  .header { height: 52px; }
  .logo img { width: 124px; height: 22px; }
  .auth { gap: 8px; }
  .btn { height: 32px; padding: 6px 14px; font-size: 14px; }
  .btn--primary { padding-right: 8px; }
  .btn--big { height: 52px; padding: 12px 20px 12px 24px; font-size: 16px; line-height: 24px; }

  .hero { margin-top: -42px; height: 464px; }
  .hero::after { height: 28.4%; }
  .hero::before {
    content: "";
    position: absolute;
    z-index: 1;
    left: 0;
    top: 22px;
    width: 276px;
    height: 420px;
    background: linear-gradient(to right, rgba(254, 250, 247, .43) 54.3%, rgba(254, 249, 241, 0));
  }
  .hero__content { top: 122px; width: 280px; }
  .hero__content::before {
    content: "";
    position: absolute;
    z-index: -1;
    left: -123px;
    top: -91px;
    width: 424px;
    height: 387px;
    background: url("assets/hero-glow.svg") center / 100% 100% no-repeat;
  }
  .eyebrow { font-size: 12px; line-height: 20px; letter-spacing: 2px; }
  .hero__title { font-size: 32px; }
  .hero__lead { font-size: 14px; }
  .hero__cta { margin-top: 24px; width: 198px; }

  .benefits {
    grid-template-columns: 1fr;
    gap: 8px;
    max-width: 375px;
    margin-top: -22px;
  }
  .benefit {
    flex-direction: row;
    gap: 12px;
    height: auto;
    min-height: 88px;
    padding: 12px;
    text-align: left;
  }
  .benefit > div { flex: 1; }
  .benefit h2 { font-size: 16px; line-height: 1.2; }
  .benefit p { font-size: 14px; line-height: 1.3; }
  .benefit__icon { width: 64px; height: 64px; }

  .how { margin-top: 24px; padding-bottom: 40px; gap: 0; }
  .how__title { width: 264px; height: 144px; margin-bottom: -8px; }
  .how__title h2 {
    top: 36px;
    font-size: 40px;
    line-height: 48.7px;
    transform: translateX(-50%) rotate(-7.93deg);
  }
  .how__title img { left: 57px; top: 32px; width: 201px; height: 100px; }
  .how__cards { grid-template-columns: 1fr; gap: 8px; width: 100%; max-width: 375px; }
  .step { height: 140px; padding: 24px 12px; }
  .step__num { left: 12px; top: 12px; width: 40px; height: 40px; font-size: 20px; }
  .step__img { right: 13px; top: 6px; width: 90px; height: 90px; }
  .step h3 { font-size: 24px; line-height: 1.2; }
  .step p { font-size: 14px; line-height: 1.3; max-width: none; }

  .reach { height: auto; max-height: none; padding: 236px 16px 32px; }
  .reach__map {
    left: 50%;
    top: -50px;
    width: 462px;
    height: 347px;
    transform: translateX(-50%);
  }
  .reach::before {
    background: linear-gradient(to bottom, rgba(0, 0, 3, 0) 188px, var(--night) 295px);
  }
  .reach::after {
    background: linear-gradient(45deg, var(--night) 30%, rgba(0, 0, 3, 0) 60%) 0 0 / 300px 460px no-repeat;
  }
  .reach__content { position: relative; left: 0; top: 0; width: 100%; transform: none; }
  .reach__title { margin-top: 4px; font-size: 24px; letter-spacing: -1px; }
  .reach__title span { display: inline; }
  .reach__lead { margin-top: 8px; font-size: 14px; max-width: 280px; }
  .reach__cta { margin-top: 24px; width: 240px; }
}

@media (min-width: 768px) and (max-width: 1100px) {
  .hero__title { font-size: 64px; }
  .reach__map { left: 25%; width: 100%; top: -10%; height: 120%; }
}

/* ---------- Footer ---------- */
.footer {
  background: var(--night);
  color: rgba(254, 250, 247, .72);
  font-size: 16px;
  line-height: 1.5;
}
.footer__inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 48px;
  max-width: 1792px;
  margin: 0 auto;
  padding: 72px var(--gutter) 56px;
  border-top: 1px solid rgba(254, 250, 247, .12);
}
.footer__brand p { max-width: 340px; margin-top: 16px; }
.footer__cta { display: flex; gap: 10px; margin-top: 24px; }
.btn--light { border-color: var(--cream); color: var(--cream); }
.btn--light:hover { background: var(--cream); color: var(--ink); box-shadow: 0 6px 16px rgba(254, 250, 247, .15); }
.btn--light:active { background: #e9e3de; border-color: #e9e3de; }
.btn--light .ripple { background: rgba(2, 2, 8, .2); }
.footer__heading {
  margin-bottom: 16px;
  font-size: 14px;
  line-height: 28px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--cream);
}
.footer__contacts { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.footer__link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--cream);
  border-radius: 6px;
  transition: color .2s;
}
.footer__link svg { flex: none; color: var(--cyan); transition: transform .25s cubic-bezier(.34, 1.56, .64, 1), color .2s; }
.footer__link:hover { color: var(--pink); }
.footer__link:hover svg { color: var(--pink); transform: scale(1.15) rotate(-8deg); }
.footer__link:active { opacity: .7; }
.footer__company { font-style: normal; }
.footer__company strong { display: block; margin-bottom: 4px; color: var(--cream); font-weight: 700; }
.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  max-width: 1792px;
  margin: 0 auto;
  padding: 20px var(--gutter) 28px;
  border-top: 1px solid rgba(254, 250, 247, .12);
  font-size: 14px;
}
.footer__top { color: var(--cream); border-radius: 6px; transition: color .2s; }
.footer__top span { display: inline-block; transition: transform .2s ease-out; }
.footer__top:hover { color: var(--pink); }
.footer__top:hover span { transform: translateY(-3px); }
.footer__link:focus-visible, .footer__top:focus-visible { outline: 3px solid var(--cyan); outline-offset: 3px; }
html { scroll-behavior: smooth; }

@media (max-width: 1100px) {
  .footer__inner { grid-template-columns: 1fr 1fr; }
  .footer__brand { grid-column: 1 / -1; }
}
@media (max-width: 767px) {
  .footer { font-size: 14px; }
  .footer__inner { grid-template-columns: 1fr; gap: 32px; padding: 40px 16px 32px; }
  .footer__heading { font-size: 12px; letter-spacing: 2px; margin-bottom: 8px; }
  .footer__cta .btn { height: 40px; padding: 8px 18px; }
  .footer__cta .btn--primary { padding-right: 12px; }
  .footer__bottom { flex-direction: column-reverse; align-items: flex-start; padding: 16px 16px 24px; }
}

/* Hover lifts only where a real pointer exists, so taps don't leave cards stuck "hovered" */
@media (hover: none) {
  .tile:hover, .btn:hover { transform: none; }
  .btn--primary:hover::before { transform: translateX(-120%); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before { transition: none !important; animation: none !important; }
  .js .benefit:not(.is-visible) { opacity: 1; translate: none; scale: none; }
  .benefit__icon { translate: none; rotate: none; }
  html { scroll-behavior: auto; }
}
