/* Leap RockIt — shared styles. Plain CSS, no build step. */
:root {
  --cream: #FAF6F0;
  --paper: #FFFDF9;
  --mint: #BCE3CC;
  --mint-deep: #8FCBA8;
  --peach: #F9C0B0;
  --butter: #FBE5A2;
  --sky: #C6DCF0;
  --lilac: #DCD3F0;
  --coral: #E38B74;
  --coral-deep: #C96A53;
  --ink: #2E3440;
  --ink-soft: #545B69;
  --line: #E9E0D3;
  --radius: 28px;
  --shadow: 0 18px 36px -16px rgba(46, 52, 64, .16), 0 6px 0 0 var(--line);
  --display: "Fredoka", ui-rounded, system-ui, sans-serif;
  --body: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--cream); color: var(--ink);
  font: 500 17px/1.65 var(--body); overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
::selection { background: var(--butter); }
:focus-visible { outline: 3px solid var(--coral); outline-offset: 3px; border-radius: 10px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 12px; z-index: 100; }
.skip:focus { left: 12px; }

h1, h2, h3, h4 { font-family: var(--display); font-weight: 700; line-height: 1.08; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(2.6rem, 6.4vw, 5.2rem); }
h2 { font-size: clamp(2rem, 4.2vw, 3.2rem); }
h3 { font-size: 1.45rem; }
p { margin: 0 0 1em; }
.lede { font-size: clamp(1.08rem, 1.6vw, 1.3rem); color: var(--ink-soft); max-width: 36em; }
.wrap { width: min(1160px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 32px); margin-inline: auto; }
.coral { color: var(--coral); }
.center { text-align: center; }
.center .lede { margin-inline: auto; }

/* ---------- soft background blobs ---------- */
.blobs { position: fixed; inset: 0; pointer-events: none; z-index: -1; overflow: hidden; }
.blobs i { position: absolute; width: 42vmax; height: 42vmax; border-radius: 50%; filter: blur(70px); opacity: .42; animation: drift 26s ease-in-out infinite alternate; }
.blobs i:nth-child(1) { background: var(--mint); top: -18vmax; left: -14vmax; }
.blobs i:nth-child(2) { background: var(--peach); top: 30%; right: -18vmax; animation-delay: -8s; }
.blobs i:nth-child(3) { background: var(--butter); bottom: -20vmax; left: 20%; animation-delay: -15s; }
.blobs i:nth-child(4) { background: var(--sky); top: 55%; left: -16vmax; width: 30vmax; height: 30vmax; animation-delay: -4s; }
@keyframes drift { to { transform: translate(6vmax, -4vmax) scale(1.08); } }

/* ---------- header ---------- */
.site-head { position: sticky; top: 0; z-index: 50; padding: 12px 0; transition: padding .25s; }
.site-head .bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: rgba(255, 253, 249, .86); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border: 2.5px solid var(--line); border-radius: 999px; padding: 8px 10px 8px 10px;
  box-shadow: 0 10px 30px -18px rgba(46, 52, 64, .35);
}
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--display); font-weight: 700; font-size: 1.4rem; line-height: 1; white-space: nowrap; }
.brand img.logo-h { height: 48px; width: auto; transition: transform .5s cubic-bezier(.3,1.6,.5,1); }
.brand:hover img.logo-h { transform: translateY(-3px) rotate(-3deg); }
.site-head .bar { padding-left: 18px; }
.brand .r { color: var(--coral); }
.nav { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav a { display: block; text-decoration: none; font-weight: 700; font-size: .95rem; padding: 9px 16px; border-radius: 999px; transition: background .2s; }
.nav a:hover { background: var(--butter); }
.nav a[aria-current="page"] { background: var(--mint); }
@media (max-width: 640px) {
  .brand img.logo-h { height: 38px; }
  .nav a { padding: 8px 10px; font-size: .86rem; }
  .nav .hide-sm { display: none; }
}

/* ---------- buttons, stickers ---------- */
.btn {
  --bg: var(--coral); --fg: #fff; --edge: var(--coral-deep);
  display: inline-flex; align-items: center; gap: 10px; text-decoration: none; cursor: pointer;
  font: 700 1.08rem/1 var(--display); letter-spacing: .01em; color: var(--fg); background: var(--bg);
  padding: 16px 26px; border-radius: 999px; border: 2.5px solid var(--ink);
  box-shadow: 0 5px 0 0 var(--ink); transform: translateY(0); transition: transform .15s, box-shadow .15s;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 7px 0 0 var(--ink); }
.btn:active { transform: translateY(4px); box-shadow: 0 1px 0 0 var(--ink); }
.btn.alt { --bg: var(--paper); --fg: var(--ink); }
.btn.mint { --bg: var(--mint); --fg: var(--ink); }
.btn svg { width: 20px; height: 20px; }
.btns { display: flex; flex-wrap: wrap; gap: 14px; }

.sticker {
  display: inline-flex; align-items: center; gap: 8px; font: 700 .92rem/1 var(--display); letter-spacing: .04em; text-transform: uppercase;
  background: var(--butter); border: 2px solid rgba(46,52,64,.16); padding: 9px 16px; border-radius: 999px; transform: rotate(-2deg);
}
.sticker .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--coral); animation: pulse 2s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(1.5); opacity: .6; } }

/* ---------- cards ---------- */
.card { background: var(--paper); border: 2.5px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: clamp(22px, 3vw, 36px); }
.tint-mint { background: #E8F5EC; } .tint-peach { background: #FDEAE3; } .tint-butter { background: #FEF6DA; } .tint-sky { background: #E7F0F9; } .tint-lilac { background: #EFEAF8; }

section { padding: clamp(56px, 9vw, 110px) 0; position: relative; }
.eyebrow { font: 700 .85rem/1 var(--display); letter-spacing: .14em; text-transform: uppercase; color: var(--coral-deep); margin-bottom: 14px; display: block; }

/* ---------- home hero ---------- */
.hero { padding: 10px 0 0; }
.hero-frame {
  position: relative; border-radius: 40px; overflow: hidden; border: 3px solid var(--ink);
  box-shadow: 0 8px 0 0 var(--ink), 0 30px 60px -30px rgba(46,52,64,.5);
  min-height: min(76vh, 660px); display: grid; grid-template-columns: 1fr 1fr; align-items: center;
  background: radial-gradient(circle at 78% 42%, #FFFDF6 0, rgba(255,253,246,0) 38%), linear-gradient(160deg, #DDF1E5 0%, #E7F0F9 40%, #FDEAE3 75%, #FEF4D6 100%);
}
.hero-sky { position: absolute; inset: 0; pointer-events: none; }
.hero-sky i { position: absolute; width: 14px; height: 14px; background: var(--butter); clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%); animation: twinkle 3.2s ease-in-out infinite; }
.hero-sky i:nth-child(1) { left: 6%; top: 12%; } .hero-sky i:nth-child(2) { left: 44%; top: 8%; width: 10px; height: 10px; background: var(--sky); animation-delay: -1s; }
.hero-sky i:nth-child(3) { left: 92%; top: 14%; animation-delay: -2s; } .hero-sky i:nth-child(4) { left: 52%; top: 86%; width: 10px; height: 10px; background: var(--peach); animation-delay: -.5s; }
.hero-sky i:nth-child(5) { left: 88%; top: 82%; width: 9px; height: 9px; background: var(--mint); animation-delay: -1.6s; } .hero-sky i:nth-child(6) { left: 34%; top: 90%; width: 8px; height: 8px; animation-delay: -2.4s; }
.hero-sky i:nth-child(7) { left: 62%; top: 20%; width: 8px; height: 8px; background: var(--coral); animation-delay: -.8s; } .hero-sky i:nth-child(8) { left: 4%; top: 80%; width: 9px; height: 9px; background: var(--sky); animation-delay: -2.8s; }
@keyframes twinkle { 0%, 100% { transform: scale(1) rotate(0); opacity: 1; } 50% { transform: scale(.4) rotate(45deg); opacity: .5; } }
.hero-logo { order: 2; position: relative; display: grid; place-items: center; padding: 30px 30px 30px 0; }
.hero-logo img { width: 100%; max-width: 500px; filter: drop-shadow(0 14px 18px rgba(46,52,64,.12)); }
.hero-copy { order: 1; position: relative; padding: clamp(28px, 5vw, 72px); }
.hero-copy h1 { margin-top: 18px; }
.hero-copy h1 .wob { display: inline-block; animation: wob 3.2s ease-in-out infinite; color: var(--coral); }
@keyframes wob { 0%,100% { transform: rotate(-3deg) translateY(0); } 50% { transform: rotate(3deg) translateY(-6px); } }
.hero-copy .lede { color: var(--ink); }
@media (max-width: 860px) {
  .hero-frame { grid-template-columns: 1fr; min-height: 0; }
  .hero-logo { order: 1; padding: 28px 28px 0; } .hero-logo img { max-width: 340px; }
  .hero-copy { order: 2; padding-top: 8px; text-align: center; } .hero-copy .btns { justify-content: center; }
}

/* ---------- marquee ---------- */
.marquee { overflow: hidden; background: var(--ink); color: var(--cream); padding: 16px 0; transform: rotate(-1.2deg); margin: 46px -10px 0; border-block: 3px solid var(--ink); }
.marquee .track { display: flex; gap: 40px; width: max-content; animation: scroll 38s linear infinite; font: 700 1.3rem/1 var(--display); white-space: nowrap; }
.marquee .track span { display: inline-flex; align-items: center; gap: 40px; }
.marquee .track span::after { content: "✦"; color: var(--butter); }
@keyframes scroll { to { transform: translateX(-50%); } }

/* ---------- featured game ---------- */
.feature { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(24px, 4vw, 56px); align-items: center; }
.feature .art { position: relative; border-radius: 32px; overflow: hidden; border: 3px solid var(--ink); box-shadow: 0 8px 0 0 var(--ink); transform: rotate(-1.5deg); transition: transform .4s; }
.feature .art:hover { transform: rotate(0) scale(1.01); }
.feature .art .logo { position: absolute; left: 50%; top: 4%; width: 52%; transform: translateX(-50%); filter: drop-shadow(0 6px 0 rgba(46,52,64,.25)); }
.feature .appicon { width: 84px; height: 84px; border-radius: 22px; border: 2.5px solid var(--ink); box-shadow: 0 4px 0 0 var(--ink); margin-bottom: 18px; }
.ticks { list-style: none; padding: 0; margin: 0 0 26px; display: grid; gap: 10px; }
.ticks li { display: flex; gap: 12px; align-items: flex-start; }
.ticks li::before { content: ""; flex: none; width: 24px; height: 24px; margin-top: 2px; border-radius: 50%; background: var(--mint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-9' fill='none' stroke='%232E3440' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/16px no-repeat; border: 2px solid rgba(46,52,64,.15); }
@media (max-width: 860px) { .feature { grid-template-columns: 1fr; } }

/* ---------- promise grid ---------- */
.grid { display: grid; gap: 24px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.promise { text-align: center; transition: transform .3s cubic-bezier(.3,1.6,.5,1); }
.promise:hover { transform: translateY(-6px) rotate(-1deg); }
.promise img { width: 150px; height: 150px; object-fit: contain; margin: -6px auto 12px; }
.promise p { color: var(--ink-soft); margin: 0; }

/* ---------- split ---------- */
.split { display: grid; grid-template-columns: 300px 1fr; gap: clamp(24px, 5vw, 64px); align-items: center; }
.split > img { width: 100%; max-width: 300px; margin-inline: auto; animation: bob 4s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-10px) rotate(2deg); } }
.split-sm { grid-template-columns: 240px 1fr; }
@media (max-width: 760px) { .split, .split-sm { grid-template-columns: 1fr; text-align: center; } .split > img { max-width: 220px; } .split .btns { justify-content: center; } }

.facts { display: grid; grid-template-columns: auto 1fr; gap: 6px 20px; margin: 18px 0 0; font-size: .97rem; }
.facts dt { font-weight: 800; }
.facts dd { margin: 0; color: var(--ink-soft); }
@media (max-width: 760px) { .facts { text-align: left; } }

/* ---------- game page ---------- */
.game-hero { position: relative; border-radius: 40px; overflow: hidden; border: 3px solid var(--ink); box-shadow: 0 8px 0 0 var(--ink); }
.game-hero > img.bg { width: 100%; aspect-ratio: 16/9; object-fit: cover; min-height: 340px; }
.game-hero .logo { position: absolute; left: 0; right: 0; margin-inline: auto; top: 5%; width: min(52%, 560px); filter: drop-shadow(0 8px 0 rgba(46,52,64,.25)); animation: wob 5s ease-in-out infinite; }
.game-intro { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: end; margin-top: 36px; }
@media (max-width: 760px) { .game-intro { grid-template-columns: 1fr; } }
.steps { counter-reset: s; display: grid; gap: 22px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.step { position: relative; padding-top: 44px; }
.step::before { counter-increment: s; content: counter(s); position: absolute; top: -22px; left: 26px; width: 54px; height: 54px; display: grid; place-items: center; border-radius: 50%; background: var(--butter); border: 2.5px solid var(--ink); box-shadow: 0 4px 0 0 var(--ink); font: 700 1.5rem/1 var(--display); }
.step p { color: var(--ink-soft); margin: 0; }
.shots { display: flex; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 8px 4px 26px; scrollbar-width: thin; }
.shots figure { flex: none; width: min(560px, 84vw); margin: 0; scroll-snap-align: center; }
.shots img { border-radius: 22px; border: 3px solid var(--ink); box-shadow: 0 6px 0 0 var(--ink); aspect-ratio: 1400/647; object-fit: cover; background: var(--line); }
.shots figcaption { font: 600 .92rem/1.4 var(--display); color: var(--ink-soft); margin-top: 12px; padding-left: 6px; }
.cast { display: flex; justify-content: center; align-items: flex-end; flex-wrap: wrap; gap: 8px 4px; }
.cast img { height: 150px; width: auto; transition: transform .3s cubic-bezier(.3,1.6,.5,1); }
.cast img:hover { transform: translateY(-14px) rotate(-6deg); }
@media (max-width: 640px) { .cast img { height: 96px; } }
.worlds { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 0; margin: 0; }
.worlds li { padding: 8px 16px; border-radius: 999px; font: 700 .95rem/1 var(--display); border: 2px solid rgba(46,52,64,.14); }
.store { display: inline-flex; align-items: center; gap: 12px; background: var(--ink); color: #fff; padding: 12px 22px; border-radius: 16px; text-decoration: none; font-weight: 700; line-height: 1.15; }
.store small { display: block; font-size: .74rem; font-weight: 600; opacity: .8; }
.store svg { width: 26px; height: 26px; }

/* ---------- prose pages (support, privacy, terms) ---------- */
.page-head { padding: clamp(40px, 7vw, 80px) 0 20px; }
.page-head .split { grid-template-columns: 1fr 220px; }
.page-head .split > img { max-width: 220px; }
@media (max-width: 760px) { .page-head .split { grid-template-columns: 1fr; } .page-head .split > img { order: -1; max-width: 160px; } }
.prose { padding-top: 10px; }
.prose h2 { font-size: 1.7rem; margin-top: 2em; }
.prose h3 { font-size: 1.2rem; margin-top: 1.6em; }
.prose ul { padding-left: 1.2em; }
.prose li { margin-bottom: .4em; }
.prose a { color: var(--coral-deep); font-weight: 700; text-underline-offset: 3px; }
.prose .card { margin: 24px 0; }
.updated { font-weight: 700; color: var(--ink-soft); font-size: .95rem; }
.contact-card { display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.contact-card .mail { font: 700 clamp(1.2rem, 3vw, 1.7rem)/1.2 var(--display); text-decoration: none; word-break: break-all; }
details { background: var(--paper); border: 2.5px solid var(--line); border-radius: 22px; margin: 12px 0; box-shadow: 0 4px 0 0 var(--line); }
summary { cursor: pointer; list-style: none; padding: 18px 56px 18px 22px; font: 700 1.1rem/1.3 var(--display); position: relative; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 18px; top: 50%; transform: translateY(-50%); width: 30px; height: 30px; border-radius: 50%; background: var(--butter); display: grid; place-items: center; font-size: 1.3rem; transition: transform .25s; }
details[open] summary::after { transform: translateY(-50%) rotate(45deg); background: var(--mint); }
details > div { padding: 0 22px 18px; color: var(--ink-soft); }
details > div p:last-child { margin: 0; }
.toc { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; }
.toc a { display: block; text-decoration: none; padding: 7px 14px; border-radius: 999px; background: var(--paper); border: 2px solid var(--line); font-weight: 700; font-size: .9rem; color: var(--ink); }
.toc a:hover { background: var(--butter); }

/* ---------- footer ---------- */
.site-foot { margin-top: 40px; padding: 60px 0 40px; background: var(--ink); color: #E9E4DA; border-radius: 40px 40px 0 0; position: relative; }
.site-foot .peek { position: absolute; top: -78px; right: 9%; width: 120px; }
.site-foot .cols { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 30px; }
.site-foot h4 { font-size: 1rem; letter-spacing: .1em; text-transform: uppercase; color: var(--butter); margin-bottom: 12px; }
.site-foot ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.site-foot a { text-decoration: none; opacity: .9; }
.site-foot a:hover { opacity: 1; text-decoration: underline; text-underline-offset: 3px; }
.site-foot .brand { color: #fff; margin-bottom: 14px; }
.site-foot .brand img.logo-h { height: 56px; }
.site-foot .fine { font-size: .8rem; }
.site-foot .legal { border-top: 1px solid rgba(255,255,255,.14); margin-top: 40px; padding-top: 22px; font-size: .88rem; opacity: .75; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
@media (max-width: 760px) { .site-foot .cols { grid-template-columns: 1fr 1fr; } .site-foot .cols > div:first-child { grid-column: 1 / -1; } .site-foot .peek { width: 90px; top: -60px; } }

/* ---------- reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.8,.2,1); }
.reveal.in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

/* ---------- 404 ---------- */
.lost { min-height: 70vh; display: grid; place-items: center; text-align: center; }
.lost img { width: 260px; margin: 0 auto 10px; animation: bob 4s ease-in-out infinite; }

/* ---------- confetti from the logo ---------- */
.spark { position: fixed; width: 10px; height: 10px; border-radius: 3px; pointer-events: none; z-index: 200; animation: spark 1s ease-out forwards; }
@keyframes spark { to { transform: translate(var(--dx), var(--dy)) rotate(540deg); opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- brand page ---------- */
.concepts { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
@media (max-width: 900px) { .concepts { grid-template-columns: 1fr; } }
.concept h2 { font-size: 2rem; }
.stage { border-radius: 22px; padding: 18px; margin: 16px 0; border: 2.5px solid var(--line); display: grid; place-items: center; }
.stage.light { background: var(--cream); }
.stage.dark { background: radial-gradient(circle at 50% 40%, #33416A, #1C2540 80%); border-color: #1C2540; }
.stage img { width: 100%; max-width: 420px; }
.variants { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 18px; }
.variants figure { margin: 0; background: var(--cream); border: 2px solid var(--line); border-radius: 18px; padding: 16px; display: flex; flex-direction: column; justify-content: center; gap: 10px; }
.variants figure.on-dark { background: #26324F; border-color: #26324F; color: #E9E4DA; }
.variants img { width: 100%; max-height: 120px; object-fit: contain; }
.variants img.mark-only { max-height: 100px; }
.variants figcaption { font: 600 .85rem/1 var(--display); opacity: .7; text-align: center; }
.swatches { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; }
.swatches div { background: var(--c); border: 2px solid rgba(46,52,64,.12); border-radius: 18px; padding: 44px 14px 12px; }
.swatches b { display: block; font-family: var(--display); }
.swatches span { font-size: .85rem; opacity: .8; }

.downloads { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.downloads figure { align-items: center; }
.downloads .btn { padding: 10px 18px; font-size: .92rem; box-shadow: 0 3px 0 0 var(--ink); }
.downloads .on-dark .btn { --bg: var(--cream); }
