:root {
  --ink: #12333a;
  --deep: #075963;
  --sea: #49bcb0;
  --mint: #c9f7e8;
  --cream: #fff6db;
  --sun: #ffd660;
  --coral: #f37b70;
  --blue: #57b8ef;
  --paper: rgba(255, 255, 255, 0.74);
  --line: rgba(18, 51, 58, 0.14);
  --shadow: 0 28px 90px rgba(7, 89, 99, 0.22);
  --max: 1180px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  overflow-x: clip;
  font-family: "Nunito", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 12%, rgba(255, 214, 96, 0.68), transparent 18rem),
    radial-gradient(circle at 88% 8%, rgba(87, 184, 239, 0.36), transparent 22rem),
    linear-gradient(180deg, #eaffff 0%, #cbf6e7 52%, #52beb3 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  opacity: 0.28;
  background-image:
    linear-gradient(rgba(7, 89, 99, 0.11) 1px, transparent 1px),
    linear-gradient(90deg, rgba(7, 89, 99, 0.11) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: linear-gradient(180deg, black, transparent 72%);
}

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

a {
  color: inherit;
  text-decoration: none;
}

main {
  overflow-x: clip;
}

.hero-section,
.games-section,
.builder-section {
  min-height: 100svh;
  width: min(calc(100% - 2rem), var(--max));
  margin: 0 auto;
  padding-block: clamp(3rem, 6vw, 5rem) clamp(3rem, 7vw, 5rem);
}

.hero-section {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
  overflow: clip;
  clip-path: inset(0 0 8px 0);
}

.hero-copy,
.section-copy,
.builder-copy {
  min-width: 0;
}

.eyebrow {
  margin: 0 0 0.75rem;
  font-size: 0.78rem;
  font-weight: 1000;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(18, 51, 58, 0.68);
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Baloo 2", cursive;
  line-height: 0.92;
  color: var(--deep);
  text-wrap: balance;
}

h1 {
  max-width: 10ch;
  font-size: clamp(4.1rem, 8.7vw, 8rem);
  letter-spacing: -0.05em;
}

h2 {
  max-width: 12ch;
  font-size: clamp(3.1rem, 6vw, 5.7rem);
  letter-spacing: -0.045em;
}

h3 {
  font-size: clamp(1.5rem, 2.6vw, 2rem);
}

p {
  margin: 1rem 0 0;
  max-width: 42rem;
  font-size: clamp(1.05rem, 1.35vw, 1.22rem);
  line-height: 1.65;
  color: rgba(18, 51, 58, 0.82);
}

.locale-switch {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 1rem;
}

.locale-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 3.4rem;
  padding: 0.5rem 0.8rem;
  border: 1px solid rgba(18, 51, 58, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.6);
  font-size: 0.92rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: transform 180ms ease, background-color 180ms ease, border-color 180ms ease;
}

.locale-link:hover,
.locale-link:focus-visible {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.82);
  border-color: rgba(18, 51, 58, 0.24);
}

.locale-link[aria-current="page"] {
  background: var(--deep);
  border-color: var(--deep);
  color: white;
}

.store-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  margin-top: 0.65rem;
}

.store-actions a {
  display: inline-flex;
  align-items: center;
  min-height: 3.45rem;
  transition: transform 180ms ease, filter 180ms ease;
}

.store-actions a:hover,
.store-actions a:focus-visible {
  filter: saturate(1.08);
  transform: translateY(-2px) rotate(-1deg);
}

.store-actions img {
  width: auto;
  height: 3.45rem;
}

.store-actions .store-app-icon {
  width: 3.45rem;
  height: 3.45rem;
  flex: 0 0 auto;
  border: 2px solid rgba(255, 255, 255, 0.72);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.7);
  box-shadow: 0 0.75rem 1.5rem rgba(18, 51, 58, 0.14);
  object-fit: cover;
}

.store-soon {
  display: inline-flex;
  align-items: center;
  min-height: 3.45rem;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(18, 51, 58, 0.14);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.68);
  font-size: 0.98rem;
  font-weight: 900;
  line-height: 1.2;
  color: var(--deep);
}

.hero-app-icon {
  width: clamp(4.4rem, 7vw, 5.8rem);
  height: clamp(4.4rem, 7vw, 5.8rem);
  margin-top: 1.2rem;
  object-fit: contain;
  filter: drop-shadow(0 16px 34px rgba(7, 89, 99, 0.2));
}

.privacy-note {
  display: inline-flex;
  margin-top: 1.15rem;
  padding: 0.6rem 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.56);
  font-size: 0.95rem;
  font-weight: 1000;
}

.hero-stage {
  position: relative;
  isolation: isolate;
  min-height: min(72svh, 44rem);
  overflow: clip;
  border-radius: 3rem;
}

.hero-stage::before,
.hero-stage::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

.hero-stage::before {
  inset: 5% auto auto 12%;
  width: 23rem;
  height: 23rem;
  background: radial-gradient(circle, rgba(255, 214, 96, 0.76), transparent 70%);
}

.hero-stage::after {
  right: 3rem;
  bottom: 2rem;
  width: 26rem;
  height: 26rem;
  background: radial-gradient(circle, rgba(73, 188, 176, 0.44), transparent 68%);
}

.tablet-screen {
  position: absolute;
  margin: 0;
  overflow: hidden;
  aspect-ratio: 2064 / 2752;
  border: 10px solid #103f47;
  border-radius: 2rem;
  background: white;
  box-shadow: var(--shadow);
}

.tablet-screen img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

.tablet-showcase {
  z-index: 3;
  left: 50%;
  top: 50%;
  width: min(72%, 30rem);
  transform: translate(-50%, -50%) rotate(3deg);
  animation: float-b 6.8s ease-in-out infinite;
}

.privacy-page .hero-section {
  align-items: start;
}

.privacy-page .hero-copy {
  max-width: 46rem;
}

.privacy-page h1 {
  max-width: 8ch;
  font-size: clamp(2.3rem, 6vw, 3.6rem);
  line-height: 1;
}

.privacy-page h2 {
  max-width: none;
  font-size: clamp(1.15rem, 2.4vw, 1.5rem);
  line-height: 1.15;
  letter-spacing: -0.015em;
  text-wrap: auto;
}

.privacy-page p {
  max-width: 40rem;
}

.policy-block {
  margin-top: 2.25rem;
}

.policy-block h2 {
  margin-bottom: 0.7rem;
}

.policy-block p:first-of-type {
  margin-top: 0;
}

.games-section {
  display: grid;
  gap: clamp(1.5rem, 4vw, 2.5rem);
  align-content: center;
}

.section-copy {
  max-width: 56rem;
}

.personalized-copy {
  max-width: 54rem;
}

.personalized-layout {
  display: block;
}

.personalized-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.personal-game {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.9rem;
  align-content: start;
  min-height: 14rem;
  padding: clamp(1rem, 2vw, 1.25rem);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 2rem;
  background:
    radial-gradient(circle at top right, rgba(255, 214, 96, 0.28), transparent 34%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.68), rgba(255, 255, 255, 0.33));
  box-shadow: 0 18px 54px rgba(7, 89, 99, 0.1);
}

.personal-game:nth-child(odd) img {
  transform: rotate(1.5deg);
}

.personal-game:nth-child(even) img {
  transform: rotate(-1.5deg);
}

.personal-game-copy {
  min-width: 0;
}

.personal-game img {
  width: 100%;
  max-width: 100%;
  height: auto;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 1.35rem;
  box-shadow: 0 16px 34px rgba(7, 89, 99, 0.16);
}

.personal-game p {
  margin-top: 0.55rem;
  max-width: 18rem;
  font-size: 1rem;
  line-height: 1.48;
}

.builder-section {
  display: grid;
  grid-template-columns: minmax(16rem, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
}

.builder-photo {
  position: relative;
  overflow: hidden;
  min-height: min(66svh, 34rem);
  border: 12px solid rgba(255, 255, 255, 0.72);
  border-radius: 3rem;
  background: var(--cream);
  box-shadow: var(--shadow);
  transform: rotate(-2deg);
}

.builder-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, transparent 50%, rgba(18, 51, 58, 0.34)),
    radial-gradient(circle at 12% 8%, rgba(255, 214, 96, 0.45), transparent 15rem);
}

.builder-photo img {
  width: 100%;
  height: 100%;
  min-height: min(66svh, 34rem);
  object-fit: contain;
  object-position: center top;
}

.builder-copy {
  padding: clamp(1rem, 3vw, 2rem);
  border-radius: 3rem;
  background: rgba(255, 255, 255, 0.46);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.72);
}

.store-actions-bottom {
  margin-top: 2rem;
}

@keyframes float-a {
  0%,
  100% {
    translate: 0 0;
  }

  50% {
    translate: 0 -12px;
  }
}

@keyframes float-b {
  0%,
  100% {
    translate: 0 0;
  }

  50% {
    translate: 0 14px;
  }
}

@media (max-width: 920px) {
  .hero-section,
  .builder-section {
    grid-template-columns: 1fr;
  }

  .personalized-list {
    grid-template-columns: 1fr;
  }

  .games-section,
  .builder-section {
    min-height: auto;
    padding-block: 7rem 4rem;
  }

  .hero-section {
    min-height: 100svh;
    padding-block: 3rem 2rem;
  }

  h1,
  h2 {
    max-width: 12ch;
  }

  .hero-stage {
    min-height: 39rem;
  }

  .builder-photo {
    min-height: 28rem;
    transform: rotate(0);
  }

  .builder-photo img {
    min-height: 28rem;
  }

  .privacy-page .hero-stage {
    min-height: 20rem;
  }
}

@media (max-width: 620px) {
  .hero-section,
  .games-section,
  .builder-section {
    width: min(calc(100% - 1rem), var(--max));
    min-height: 100svh;
    padding-block: 2rem 1.5rem;
  }

  h1 {
    max-width: 11ch;
    font-size: clamp(2.75rem, 12.4vw, 3.2rem);
  }

  h2 {
    font-size: clamp(2.3rem, 11vw, 3.1rem);
  }

  p {
    font-size: 1rem;
    line-height: 1.5;
  }

  .store-actions {
    gap: 0.55rem;
    margin-top: 0.45rem;
  }

  .store-actions img {
    height: 2.68rem;
  }

  .store-actions .store-app-icon {
    width: 2.68rem;
    height: 2.68rem;
    border-radius: 0.78rem;
  }

  .hero-app-icon {
    width: 3.75rem;
    height: 3.75rem;
    margin-top: 0.7rem;
  }

  .privacy-note {
    margin-top: 0.55rem;
    font-size: 0.88rem;
  }

  .hero-stage {
    min-height: 16.5rem;
    border-radius: 2rem;
  }

  .tablet-screen {
    border-width: 7px;
    border-radius: 1.55rem;
  }

  .tablet-showcase {
    width: min(78%, 14rem);
  }

  .personalized-list {
    gap: 0.7rem;
  }

  .personal-game {
    grid-template-columns: 1fr;
    min-height: auto;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: 1.45rem;
  }

  .personal-game img {
    max-width: 100%;
    border-radius: 1rem;
  }

  .personal-game p {
    font-size: 0.96rem;
  }

  .builder-photo,
  .builder-photo img {
    min-height: 15rem;
  }

  .builder-photo {
    height: 15rem;
  }

  .builder-photo img {
    height: 100%;
    min-height: 0;
  }

  .builder-copy {
    padding: 1.2rem;
    border-radius: 2rem;
  }

  .privacy-page h1 {
    max-width: none;
    font-size: clamp(2rem, 10vw, 2.6rem);
  }

  .privacy-page h2 {
    max-width: none;
    font-size: clamp(1.05rem, 5.8vw, 1.3rem);
    line-height: 1.18;
  }

  .privacy-page .policy-block {
    margin-top: 1.7rem;
  }

  .privacy-page .hero-stage {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
