/* Blockivator Color Sort — toy-block workshop landing */

:root {
  --sky-top: #ffd6b8;
  --sky-mid: #f7c4d8;
  --sky-deep: #8ec8e8;
  --ink: #2a1f4a;
  --mute: rgba(42, 31, 74, 0.72);
  --cream: #fff8ef;
  --yellow: #ffd12a;
  --yellow-deep: #e8a800;
  --teal: #2eb8a8;
  --teal-deep: #1a8f84;
  --fox: #8b5cf6;
  --orange: #f28e6b;
  --display: "Fredoka", "Nunito", "Avenir Next", system-ui, sans-serif;
  --body: "Nunito", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --shell: 72rem;
  --radius: 1.35rem;
  --stud: radial-gradient(circle at 50% 40%, rgba(255, 255, 255, 0.55) 0 28%, transparent 30%);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100%;
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.65;
  background:
    linear-gradient(180deg, var(--sky-top) 0%, var(--sky-mid) 38%, var(--sky-deep) 100%);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--teal-deep);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.12;
}

.shell {
  width: min(100% - 2rem, var(--shell));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: 50%;
  top: -4rem;
  transform: translateX(-50%);
  z-index: 100;
  padding: 0.55rem 1rem;
  background: var(--yellow);
  color: var(--ink);
  font-weight: 800;
  border-radius: 999px;
}

.skip-link:focus {
  top: 0.5rem;
}

/* —— Top nav —— */
.top {
  position: fixed;
  inset: 0 0 auto;
  z-index: 40;
  padding: 0.85rem 0;
  background: linear-gradient(180deg, rgba(42, 31, 74, 0.45), transparent);
  border-bottom: 1px solid transparent;
  transition: background 0.35s ease, backdrop-filter 0.35s ease, border-color 0.35s ease;
}

.top.is-solid {
  background: rgba(255, 248, 239, 0.88);
  backdrop-filter: blur(14px);
  border-bottom-color: rgba(42, 31, 74, 0.08);
}

.top.is-solid .mark,
.top.is-solid .top__nav a {
  color: var(--ink);
}

.top__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.mark {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: #fff;
  text-decoration: none;
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.15rem;
  text-shadow: 0 1px 8px rgba(42, 31, 74, 0.35);
}

.mark img {
  border-radius: 12px;
  box-shadow: 0 4px 0 rgba(42, 31, 74, 0.25), 0 0 0 2px rgba(255, 255, 255, 0.55);
}

.top__nav {
  display: flex;
  align-items: center;
  gap: 1.1rem;
}

.top__nav a {
  color: rgba(255, 255, 255, 0.95);
  font-weight: 800;
  font-size: 0.95rem;
  text-decoration: none;
  text-shadow: 0 1px 6px rgba(42, 31, 74, 0.35);
}

.top__cta {
  padding: 0.45rem 0.95rem;
  background: var(--yellow);
  color: var(--ink) !important;
  border-radius: 999px;
  box-shadow: 0 3px 0 var(--yellow-deep);
  text-shadow: none !important;
}

.top__cta:hover {
  text-decoration: none;
  transform: translateY(1px);
  box-shadow: 0 2px 0 var(--yellow-deep);
}

@media (max-width: 640px) {
  .top__nav a:not(.top__cta) {
    display: none;
  }
}

/* —— Hero (full-bleed art) —— */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: end;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 35%;
  animation: hero-drift 18s ease-in-out infinite alternate;
}

.hero__veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(42, 31, 74, 0.28) 0%, transparent 32%),
    linear-gradient(0deg, rgba(42, 31, 74, 0.72) 0%, rgba(42, 31, 74, 0.35) 42%, transparent 70%);
}

.hero__stage {
  position: relative;
  z-index: 1;
  padding: 6.5rem 0 3.5rem;
}

.hero__copy {
  max-width: 28rem;
  color: #fff;
}

.brand-lock {
  margin: 0 0 0.35rem;
  font-family: var(--display);
  font-size: clamp(2.4rem, 8vw, 3.75rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.03em;
  text-shadow:
    0 2px 0 rgba(42, 31, 74, 0.35),
    0 8px 24px rgba(42, 31, 74, 0.45);
}

.hero h1 {
  display: inline-block;
  margin: 0 0 0.85rem;
  padding: 0.2rem 0.75rem 0.35rem;
  font-size: clamp(1.35rem, 4vw, 1.85rem);
  color: var(--ink);
  background: var(--yellow);
  border-radius: 0.85rem;
  box-shadow: 0 4px 0 var(--yellow-deep);
}

.hero__lede {
  margin: 0 0 1.5rem;
  font-size: 1.08rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.94);
  text-shadow: 0 2px 12px rgba(42, 31, 74, 0.55);
  max-width: 22rem;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* —— Buttons —— */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.7rem 1.15rem;
  border-radius: 1.1rem;
  font-weight: 800;
  text-decoration: none !important;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn span {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.btn small {
  font-size: 0.68rem;
  font-weight: 700;
  opacity: 0.75;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.btn--yellow {
  background: var(--yellow);
  color: var(--ink);
  box-shadow: 0 5px 0 var(--yellow-deep);
}

.btn--teal {
  background: var(--teal);
  color: #fff;
  box-shadow: 0 5px 0 var(--teal-deep);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(8px);
  cursor: default;
}

.btn--yellow:hover,
.btn--teal:hover {
  transform: translateY(2px);
  box-shadow: 0 3px 0 var(--yellow-deep);
}

.btn--teal:hover {
  box-shadow: 0 3px 0 var(--teal-deep);
}

/* —— Features —— */
.features {
  position: relative;
  padding: 4.5rem 0 3.5rem;
  background:
    radial-gradient(circle at 12% 18%, rgba(255, 209, 42, 0.22), transparent 40%),
    radial-gradient(circle at 88% 10%, rgba(46, 184, 168, 0.18), transparent 42%),
    var(--cream);
}

.kicker {
  margin: 0 0 0.4rem;
  font-family: var(--display);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--teal-deep);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.section-title {
  margin: 0 0 2rem;
  font-size: clamp(1.75rem, 4vw, 2.45rem);
  max-width: 18ch;
}

.features__grid {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 840px) {
  .features__grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.75rem;
  }
}

.feature {
  padding: 0;
}

.feature__media {
  margin-bottom: 1rem;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 10px 0 rgba(42, 31, 74, 0.12);
  background: #dfefff;
}

.feature__media img {
  width: 100%;
  height: 12.5rem;
  object-fit: cover;
}

.feature__media--boosters {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.55rem;
  padding: 0.85rem;
  background:
    linear-gradient(145deg, #1a1440, #2d2460);
  box-shadow: 0 10px 0 rgba(42, 31, 74, 0.22);
}

.feature__media--boosters img {
  height: auto;
  aspect-ratio: 1;
  border-radius: 1rem;
  object-fit: cover;
}

.feature h3 {
  margin-bottom: 0.35rem;
  font-size: 1.25rem;
}

.feature p {
  margin: 0;
  color: var(--mute);
  font-weight: 700;
}

/* —— How to play —— */
.path {
  padding: 4rem 0;
  background:
    linear-gradient(180deg, #e8f6ff 0%, #f3e9ff 100%);
}

.path__grid {
  display: grid;
  gap: 2rem;
}

@media (min-width: 860px) {
  .path__grid {
    grid-template-columns: 0.9fr 1.1fr;
    align-items: center;
    gap: 3rem;
  }
}

.path__copy h2 {
  margin: 0 0 0.75rem;
  font-size: clamp(1.7rem, 3.5vw, 2.3rem);
}

.path__copy p {
  margin: 0;
  color: var(--mute);
  font-weight: 700;
  max-width: 32ch;
}

.path__beats {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1rem;
}

.path__beats li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1rem;
  align-items: start;
  padding: 1rem 1.15rem;
  background: rgba(255, 255, 255, 0.72);
  border-radius: var(--radius);
  box-shadow: 0 6px 0 rgba(42, 31, 74, 0.08);
}

.path__num {
  display: grid;
  place-items: center;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 0.85rem;
  background: var(--fox);
  color: #fff;
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.15rem;
  box-shadow: 0 3px 0 #6d3fd1;
}

.path__beats h3 {
  margin-bottom: 0.2rem;
  font-size: 1.1rem;
}

.path__beats p {
  margin: 0;
  color: var(--mute);
  font-weight: 700;
  font-size: 0.95rem;
}

/* —— Close CTA —— */
.close {
  padding: 4.5rem 0;
  background:
    radial-gradient(ellipse 70% 80% at 50% 0%, rgba(255, 209, 42, 0.35), transparent 55%),
    linear-gradient(180deg, #5b3fa8 0%, #3d2a7a 100%);
  color: #fff;
  text-align: center;
}

.close__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
}

.close__icon {
  border-radius: 1.4rem;
  box-shadow: 0 8px 0 rgba(0, 0, 0, 0.25), 0 0 0 3px rgba(255, 255, 255, 0.35);
  animation: bob 3.2s ease-in-out infinite;
}

.close h2 {
  font-size: clamp(1.9rem, 4vw, 2.6rem);
}

.close p {
  margin: 0 0 0.5rem;
  max-width: 28rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.85);
}

/* —— Footer —— */
.foot {
  padding: 2rem 0 2.5rem;
  background: #2a1f4a;
  color: rgba(255, 255, 255, 0.78);
}

.foot__inner {
  display: grid;
  gap: 1rem;
}

.foot__brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  color: #fff;
  font-family: var(--display);
  font-weight: 700;
}

.foot__brand img {
  border-radius: 8px;
}

.foot__by {
  font-family: var(--body);
  font-weight: 700;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.55);
}

.foot__links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.25rem;
}

.foot__links a {
  color: #ffd12a;
  font-weight: 800;
  font-size: 0.92rem;
}

.foot__note {
  margin: 0;
  font-size: 0.85rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.45);
}

/* —— Motion —— */
.motion-rise {
  opacity: 0;
  transform: translateY(18px);
  animation: rise 0.7s ease forwards;
}

.motion-rise--2 { animation-delay: 0.12s; }
.motion-rise--3 { animation-delay: 0.24s; }
.motion-rise--4 { animation-delay: 0.36s; }

.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}

.reveal.is-in {
  opacity: 1;
  transform: none;
}

@keyframes rise {
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes hero-drift {
  from { transform: scale(1.04) translateY(0); }
  to { transform: scale(1.1) translateY(-1.5%); }
}

@keyframes bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@media (prefers-reduced-motion: reduce) {
  .motion-rise,
  .reveal,
  .hero__bg img,
  .close__icon {
    animation: none !important;
    transition: none !important;
    opacity: 1;
    transform: none;
  }
}
