@font-face {
  font-family: "DM Sans";
  src: url("assets/dm-sans.woff2") format("woff2");
  font-display: swap;
  font-weight: 100 1000;
}

:root {
  --cream: #fdf5e9;
  --paper: #fffbf6;
  --ink: #401d49;
  --dim: #634d64;
  --berry: #a42f63;
  --violet: #672c83;
  --lavender: #f1e6f6;
  --gold: #ffd370;
  --plum-deep: #411944;
  --plum-light: #63295d;
  --card-border: #54203c19;
  --motion-ease: cubic-bezier(.2, .75, .45, 1);
  --gutter: clamp(1.25rem, 4.4vw, 4rem);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font: 400 1rem/1.6 "DM Sans", "Trebuchet MS", sans-serif;
}
img { display: block; width: 100%; height: auto; }
a { color: inherit; }
button { font: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid #a42f63; outline-offset: 5px; }
.contact :focus-visible { outline-color: var(--gold); }

.shell { width: min(calc(100% - 2 * var(--gutter)), 76rem); margin-inline: auto; }
.skip-link {
  position: absolute;
  z-index: 10;
  inset: .7rem auto auto .7rem;
  transform: translateY(-180%);
  padding: .6rem 1rem;
  border-radius: .6rem;
  background: var(--ink);
  color: white;
}
.skip-link:focus { transform: translateY(0); }

.site-header { border-bottom: 1px solid #eddfd1; background: var(--cream); }
.site-header__inner, .site-footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.2rem;
  min-height: 5.5rem;
}
.wordmark { display: inline-block; flex: none; width: 11.75rem; }
.wordmark--footer { width: 8.85rem; }
.site-nav { display: flex; align-items: center; gap: clamp(1rem, 2.5vw, 2.4rem); }
.site-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  font-weight: 720;
  font-size: .95rem;
  text-decoration: none;
}
.site-nav a:hover { color: var(--berry); }
.site-nav .nav-contact {
  padding: .45rem 1.1rem;
  border: 1px solid #d6b7cb;
  border-radius: 99px;
}
.site-nav .nav-contact:hover { background: #f9e6ef; }

@media (min-width: 48.0625rem) {
  .site-header { position: sticky; z-index: 5; top: 0; }
  main section[id] { scroll-margin-top: 5.5rem; }
}

.hero {
  padding-block: clamp(3.25rem, 6vw, 6rem) clamp(4rem, 6.6vw, 6.65rem);
  background: radial-gradient(ellipse at 80% 45%, #ffe6b5 0%, transparent 61%), var(--cream);
}
.hero__inner, .rhythm__inner {
  display: grid;
  grid-template-columns: minmax(0, .83fr) minmax(0, 1.17fr);
  align-items: center;
  gap: clamp(2.3rem, 5.3vw, 5.25rem);
}
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { font-weight: 900; letter-spacing: -.047em; word-spacing: .03em; }
.hero h1 { font-size: clamp(2.83rem, 5.15vw, 5rem); line-height: 1; }
.hero h1 span { display: block; color: var(--berry); }
.hero__copy > p {
  max-width: 25rem;
  margin-block: 1.45rem 1.7rem;
  color: var(--dim);
  font-size: clamp(1.08rem, 1.55vw, 1.3rem);
  line-height: 1.52;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; align-items: center; }
.button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: .7rem;
  min-height: 3.2rem;
  padding: .66rem 1.15rem;
  border: 1px solid transparent;
  border-radius: 99px;
  cursor: pointer;
  font-size: .96rem;
  font-weight: 790;
  text-decoration: none;
  transition: background-color 120ms ease, box-shadow 120ms ease;
}
.button--primary { background: var(--violet); color: white; box-shadow: 0 3px 0 #482053; }
.button--primary:hover { background: #55206e; }
.button--primary:active { box-shadow: 0 1px 0 #482053; }
.button span, .text-link span { font-size: 1.06em; }
.text-link {
  display: inline-flex;
  align-items: center;
  gap: .32rem;
  min-height: 2.75rem;
  color: var(--violet);
  font-weight: 780;
  text-underline-offset: .21rem;
}
.text-link:hover { color: var(--berry); }
.hero__art { position: relative; isolation: isolate; }
.hero__art::before {
  position: absolute;
  z-index: -1;
  inset: .8rem -.7rem -.78rem .9rem;
  border-radius: 2.18rem;
  background: #f5bd58;
  content: "";
}
.hero__art img {
  border: .38rem solid #fffcf5;
  border-radius: 2.18rem;
  box-shadow: 0 10px 30px #99572c24;
  background: #ecc8a7;
}
.hero__spark {
  position: absolute;
  top: -.66rem;
  right: -.45rem;
  width: 2.65rem;
  aspect-ratio: 1;
  background: #ffd262;
  clip-path: polygon(50% 0%, 63% 33%, 100% 37%, 72% 60%, 81% 98%, 50% 78%, 19% 98%, 28% 60%, 0% 37%, 37% 33%);
  transform: rotate(14deg);
}
.hero__note {
  position: absolute;
  bottom: .95rem;
  left: -.82rem;
  display: grid;
  width: 2.55rem;
  aspect-ratio: 1;
  place-items: center;
  border: 2px solid #fffaf5;
  border-radius: .8rem;
  background: #ecc4ec;
  color: #592370;
  box-shadow: 0 3px 0 #b67cc5;
  font-size: 1.5rem;
  font-weight: 900;
  line-height: 1;
  transform: rotate(-11deg);
}

h2 { font-size: clamp(2.32rem, 4.6vw, 4.15rem); line-height: 1.02; }
.cast { padding-block: clamp(3.55rem, 6.1vw, 6.2rem); background: var(--paper); }
.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: .9rem 2rem;
  margin-bottom: clamp(1.5rem, 2.9vw, 2.5rem);
}
.section-heading p, .rhythm__copy > p, .contact p {
  max-width: 28rem;
  color: var(--dim);
  font-size: clamp(1rem, 1.45vw, 1.16rem);
  line-height: 1.55;
}
.cast-list {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: clamp(.7rem, 1.45vw, 1.3rem);
  margin: 0;
  padding: 0;
  list-style: none;
}
.cast-card {
  overflow: hidden;
  border: 1px solid var(--card-border);
  border-radius: 1.45rem;
  background: var(--card);
}
.cast-card img { aspect-ratio: 1; background: #e5d9d2; }
.cast-card__copy { padding: .95rem 1.05rem 1.08rem; }
.cast-card :is(h2, h3) { font-size: clamp(1.45rem, 2.45vw, 2.14rem); line-height: 1.06; }
.cast-card p { margin-top: .28rem; color: #523a53; font-size: .96rem; font-weight: 650; line-height: 1.35; }
.cast-card .cast-card__description { margin-top: .65rem; font-weight: 430; line-height: 1.48; }
.cast__link { margin-top: 1.15rem; }
.cast-card--lila { --card: #f8dce8; }
.cast-card--tambo { --card: #e2edce; }
.cast-card--pipo { --card: #dcecf8; }
.cast-card--rulo { --card: #fae6c5; }
.cast-card--miga { --card: #eee1f7; }

.rhythm {
  padding-block: clamp(3.65rem, 6.4vw, 6.5rem);
  background: radial-gradient(ellipse at 19% 65%, #f9ddf0 0%, transparent 52%), var(--lavender);
}
.rhythm__inner { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); }
.rhythm__art img {
  border: .33rem solid #fffaf5;
  border-radius: 1.9rem;
  background: #b7deeb;
  box-shadow: 0 5px 0 #d7b7e4;
}
.rhythm__copy > p { margin-block: .95rem 1.45rem; }
.game {
  position: relative;
  max-width: 28rem;
  padding: clamp(.82rem, 2vw, 1.15rem);
  border: 1px solid #ddc5e7;
  border-radius: 1.28rem;
  background: #fdf8fc;
  box-shadow: 0 4px 0 #e5d0eb;
}
.game__sequence {
  display: flex;
  flex-wrap: wrap;
  gap: .55rem;
  margin: 0 0 .9rem;
  padding: 0;
  list-style: none;
}
.game__sequence li {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .36rem .75rem;
  border: 1px solid #dec9e9;
  border-radius: .65rem;
  background: #fffafc;
  font-weight: 740;
}
.game__sequence li[data-done] { border-color: #96ad79; background: #e3efcf; }
.game__sequence li[aria-current] { border-color: var(--violet); box-shadow: inset 0 -2px 0 var(--violet); }
.game__step { color: var(--violet); }
.game__pads { display: flex; flex-wrap: wrap; gap: .65rem; }
.pad {
  min-width: 6rem;
  min-height: 2.85rem;
  padding: .45rem .9rem;
  border: 1px solid #634663;
  border-radius: .75rem;
  color: var(--ink);
  cursor: pointer;
  font-weight: 780;
}
.pad--clap { background: #ffdb86; }
.pad--drum { background: #f8cedd; }
.pad:hover { border-color: var(--violet); box-shadow: 0 3px 0 #724687; }
.pad:active { box-shadow: none; }
.game__status { margin-top: .6rem; color: var(--dim); font-size: .95rem; font-weight: 650; }
.game__status[data-result="retry"] { color: #9a244f; }
.game__status[data-result="success"] { color: #325233; }
.game__status:empty { margin: 0; }
.game__status:not(:empty) + .button { margin-top: .75rem; }
.game__celebration {
  position: absolute;
  right: 1rem;
  bottom: .9rem;
  width: 3.3rem;
  height: 2.9rem;
  pointer-events: none;
}
.celebration__paw {
  position: absolute;
  left: .25rem;
  bottom: .05rem;
  width: 1.8rem;
  height: 1.75rem;
  color: #c64680;
  transform: rotate(-14deg);
}
.celebration__paw::before, .celebration__paw::after {
  position: absolute;
  background: currentColor;
  content: "";
}
.celebration__paw::before { left: .43rem; bottom: .08rem; width: .94rem; height: .74rem; border-radius: 56% 56% 41% 41%; }
.celebration__paw::after {
  left: .01rem;
  bottom: .55rem;
  width: .38rem;
  height: .45rem;
  border-radius: 50%;
  box-shadow: .39rem -.39rem currentColor, .89rem -.43rem currentColor, 1.35rem -.06rem currentColor;
}
.celebration__note {
  position: absolute;
  right: .08rem;
  top: .44rem;
  color: #a0620a;
  font-size: 1.23rem;
  font-weight: 900;
  line-height: 1;
  opacity: 0;
}
.celebration__note--second { right: 1.3rem; top: -.14rem; color: var(--violet); font-size: .96rem; }
.rhythm__copy .rhythm__offline { font-weight: 700; }

.contact {
  padding-block: clamp(3.4rem, 5.7vw, 5.65rem);
  background: radial-gradient(ellipse at 87% 100%, var(--plum-light), transparent 62%), var(--plum-deep);
  color: #fff8ed;
}
.contact__inner { display: flex; align-items: center; justify-content: space-between; gap: 1.55rem; }
.contact__intro { display: flex; align-items: center; gap: clamp(1rem, 2.3vw, 1.6rem); }
.contact__avatar {
  flex: none;
  width: clamp(4.25rem, 8vw, 6.2rem);
  border: 3px solid #eab9e0;
  border-radius: 1.3rem;
  box-shadow: 0 5px 0 #2f1837;
}
.contact p { margin-top: .75rem; color: #f4e3f2; }
.button--contact { background: var(--gold); color: var(--ink); overflow-wrap: anywhere; }
.button--contact:hover { background: #ffdf99; }
.social { margin-top: 1.85rem; }
.social h3 { font-size: 1.2rem; letter-spacing: -.02em; }
.social__list { display: flex; flex-wrap: wrap; gap: .55rem; margin: .72rem 0 0; padding: 0; list-style: none; }
.social__link { padding: .53rem .92rem; min-height: 2.75rem; border-color: #dcb4d6; }
.social__link:hover { background: #fff8ed; color: var(--ink); }
.site-footer__inner { min-height: 5.15rem; }
.site-footer p { color: var(--dim); font-size: .9rem; }
.footer-link { color: var(--dim); font-size: .95rem; text-underline-offset: .22em; }

.feature { padding-block: clamp(2.8rem, 5.2vw, 5rem); background: var(--lavender); }
.feature__inner { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); align-items: center; gap: clamp(1.25rem, 5vw, 4.8rem); }
.feature__image { display: block; }
.feature__image img, .detail-hero__img { border: .3rem solid var(--paper); border-radius: 1.75rem; box-shadow: 0 4px 0 #d9bbdf; }
.feature__label { margin-bottom: .65rem; color: var(--violet); font-size: .94rem; font-weight: 800; }
.feature h2 + p { max-width: 28rem; margin: .7rem 0 .65rem; color: var(--dim); }
.feature__inner .text-link { margin-top: .2rem; }

.page-top { padding-block: clamp(2.6rem, 6vw, 5.2rem); }
.page-top h1 { max-width: 48rem; font-size: clamp(3.1rem, 7vw, 5.5rem); line-height: 1; }
.page-top .lead { max-width: 40rem; margin-top: 1rem; color: var(--dim); font-size: clamp(1.07rem, 1.75vw, 1.28rem); }
.release-status { margin-top: .78rem; color: var(--violet); font-weight: 750; }
.page-top .button { margin-top: 1.25rem; }
.breadcrumb { display: inline-flex; align-items: center; gap: .4rem; margin-bottom: 1rem; min-height: 2.75rem; color: var(--violet); font-weight: 750; text-underline-offset: .19em; }
.detail-hero { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); align-items: center; gap: clamp(1.5rem, 5vw, 4.75rem); }
.page-section { padding-block: clamp(2.5rem, 6vw, 5rem); background: var(--paper); }
.page-section--tint { background: var(--lavender); }
.reading { max-width: 49rem; }
.reading h2 { font-size: clamp(2rem, 4.1vw, 3.3rem); }
.reading h2 + *, .reading h3 + * { margin-top: .86rem; }
.reading p + p { margin-top: .8rem; }
.reading .button, .reading .text-link { margin-top: 1rem; }
.reading ol { padding-left: 1.35rem; }
.reading li + li { margin-top: .5rem; }
.lyric-lines { padding: clamp(1rem, 3vw, 2rem); border: 1px solid #dec9e9; border-radius: 1.2rem; background: var(--paper); }
.lyric-lines p { font-size: clamp(1.04rem, 2.1vw, 1.36rem); }
.credit-list { display: grid; grid-template-columns: max-content 1fr; gap: .55rem 1rem; margin: 1rem 0 0; }
.credit-list dt { font-weight: 800; }
.credit-list dd { margin: 0; color: var(--dim); }
.site-nav a[aria-current="page"] { color: var(--berry); text-decoration: underline; text-underline-offset: .27em; }

@media (max-width: 62rem) {
  .hero__inner { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); }
  .section-heading { align-items: start; flex-direction: column; }
  .cast-card__copy { padding-inline: .75rem; }
}

@media (max-width: 48rem) {
  .site-header__inner {
    flex-wrap: wrap;
    justify-content: center;
    gap: .45rem 1.25rem;
    padding-block: .85rem .55rem;
  }
  .wordmark { width: 10.15rem; }
  .wordmark--footer { width: 8rem; }
  .site-nav { flex-wrap: wrap; justify-content: center; gap: 0 clamp(.65rem, 3vw, 1.6rem); }
  .site-nav a { font-size: .89rem; }
  .site-nav .nav-contact { padding-inline: .8rem; }
  .hero__inner, .rhythm__inner { grid-template-columns: 1fr; gap: 2rem; }
  .hero h1 { font-size: clamp(2.68rem, 8.85vw, 4.65rem); }
  .feature__inner, .detail-hero { grid-template-columns: 1fr; }
  .detail-hero__img { margin-top: .55rem; }
  .hero__art::before { inset: .65rem -.45rem -.5rem .65rem; }
  .hero__art::before, .hero__art img { border-radius: 1.65rem; }
  .hero__spark { right: -.23rem; width: 2.05rem; }
  .hero__note { left: -.35rem; bottom: .6rem; width: 2.05rem; font-size: 1.2rem; }
  .cast-list { grid-template-columns: repeat(auto-fit, minmax(min(100%, 8.2rem), 1fr)); }
  .rhythm__copy { grid-row: 1; }
  .contact__inner { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 30rem) {
  .site-header__inner { flex-direction: column; }
  .site-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; }
  .site-nav .nav-contact { justify-self: center; }
  .cast-list { --card-gap: .7rem; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--card-gap); }
  .cast-card:last-child { grid-column: 1 / -1; justify-self: center; width: calc((100% - var(--card-gap)) / 2); }
  .contact__intro { align-items: flex-start; flex-direction: column; }
  .site-footer__inner { align-items: flex-start; flex-direction: column; gap: .75rem; padding-block: 1.3rem; }
  .credit-list { grid-template-columns: 1fr; gap: .22rem; }
  .credit-list dd + dt { margin-top: .45rem; }
}

@media print {
  .site-header, .site-footer, .skip-link, .button, .text-link, .breadcrumb { display: none !important; }
  body, .page-section { background: white !important; color: black !important; }
  .shell { width: 100%; }
  .page-top, .page-section { padding-block: .55cm; }
  .page-top h1 { font-size: 29pt; }
  .reading h2 { font-size: 19pt; }
}

@keyframes appear {
  from { opacity: .65; transform: translateY(.85rem); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes sway {
  50% { translate: 0 -.37rem; rotate: 9deg; }
}

@keyframes mark-beat {
  55% { transform: scale(1.06); }
}

@keyframes celebrate {
  from { opacity: 0; translate: 0 .35rem; scale: .82; }
  35% { opacity: 1; scale: 1.08; }
  to { opacity: 1; translate: 0 0; scale: 1; }
}

@keyframes rise-note {
  from { opacity: 0; transform: translateY(.3rem); }
  25%, 65% { opacity: 1; }
  to { opacity: 0; transform: translateY(-.48rem) rotate(9deg); }
}

@media (prefers-reduced-motion: no-preference) {
  .hero__copy { animation: appear .55s var(--motion-ease) both; }
  .hero__art { animation: appear .7s .08s var(--motion-ease) both; }
  .hero__spark { animation: sway 1.65s .35s ease-in-out 2; }
  .hero__note { animation: sway 1.65s .75s ease-in-out 2; }
  .cast-card { transition: transform 180ms var(--motion-ease), box-shadow 180ms var(--motion-ease); }
  .button { transition: background-color 120ms ease, box-shadow 120ms ease, transform 160ms var(--motion-ease); }
  .game__sequence li[data-done] { animation: mark-beat .28s ease-out; }
  .game__celebration .celebration__paw { animation: celebrate .36s var(--motion-ease) both; }
  .game__celebration .celebration__note { animation: rise-note 1s var(--motion-ease) both; }
  .game__celebration .celebration__note--second { animation-delay: .12s; }

  @media (hover: hover) {
    .cast-card:hover { transform: translateY(-.25rem); box-shadow: 0 .6rem 1.4rem #401d4922; }
    .button:hover { transform: translateY(-2px); }
  }

  @supports (animation-timeline: view()) {
    .section-heading, .cast-list, .rhythm__art, .contact__inner {
      animation: appear linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 38%;
    }
  }
}

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