body[data-page="activities"] { background: #eff6f6; }
.activity-center { --activity-gutter: clamp(14px, 4vw, 24px); max-width: 820px; margin-inline: auto; }
.activity-hero {
  position: relative; isolation: isolate; display: flex; align-items: center; overflow: hidden;
  min-height: 138px; padding: calc(16px + env(safe-area-inset-top, 0px)) var(--activity-gutter) 18px;
  background: linear-gradient(110deg, #063e4c, #057c78); color: #fff;
}
.activity-heading { display: grid; justify-items: start; gap: 8px; max-width: 68%; }
.activity-hero h1 { font-size: var(--type-page); line-height: 1.2; overflow-wrap: anywhere; }
.activity-tasks {
  display: inline-flex; align-items: center; gap: 7px; min-height: 40px; padding: 6px 12px;
  border: 1px solid #ffffff63; border-radius: 9px; background: #ffffff12; color: white; font-weight: 650; font-size: .875rem;
}
.activity-tasks:hover { background: #ffffff24; }
.activity-tasks .icon { width: 16px; height: 16px; flex: none; }
.activity-hero-art, .activity-illustration {
  --image: url("./photos/activities-reference.png");
  --image-width: 1199;
  --image-height: 1312;
  aspect-ratio: var(--crop-width) / var(--crop-height);
  background: var(--image) no-repeat;
  background-size: calc(var(--image-width) * 100% / var(--crop-width)) calc(var(--image-height) * 100% / var(--crop-height));
  background-position: calc(var(--crop-x) * 100% / (var(--image-width) - var(--crop-width)))
    calc(var(--crop-y) * 100% / (var(--image-height) - var(--crop-height)));
}
.activity-hero-art {
  /* Header gift, confetti, and coins. */
  --crop-x: 602;
  --crop-y: 77;
  --crop-width: 442;
  --crop-height: 133;
  position: absolute;
  z-index: -1;
  inset: auto var(--activity-gutter) 0 auto;
  width: clamp(120px, 44%, 282px);
  mask-image: linear-gradient(to right, transparent, #000 24% 89%, transparent), linear-gradient(to bottom, transparent, #000 24%);
  mask-composite: intersect;
}

.activity-banners { display: grid; gap: 12px; padding: 16px var(--activity-gutter) 24px; }
.activity-banner {
  --activity-tint: #e8f4f6; display: grid; align-items: center; grid-template-areas: "copy art" "action art";
  grid-template-columns: minmax(0, 1fr) clamp(72px, 25%, 116px); gap: 4px 14px;
  min-width: 0; padding: 15px 16px 10px; border: 1px solid #d8e6e7; border-radius: var(--card-radius); background: white; color: #103d45;
}
.activity-banner[data-activity="welcome"] { --activity-tint: #fff1e0; }
.activity-banner[data-activity="games"] { --activity-tint: #f0edf8; }
.activity-copy { grid-area: copy; min-width: 0; }
.activity-copy h2 { font-size: clamp(1.0625rem, 3.6vw, 1.375rem); line-height: 1.3; overflow-wrap: anywhere; }
.activity-copy p { max-width: 38ch; margin-top: 4px; color: #526b71; font-size: .875rem; line-height: 1.5; overflow-wrap: anywhere; }
.activity-illustration, .activity-managed-image { grid-area: art; justify-self: center; width: 100%; border-radius: 12px; }
.activity-illustration { background-color: var(--activity-tint); }
.activity-managed-image { max-height: 108px; object-fit: contain; }
.activity-banner-no-image { grid-template-areas: "copy" "action"; grid-template-columns: minmax(0, 1fr); }
.activity-banner[data-activity="welcome"] .activity-illustration {
  --crop-x: 578;
  --crop-y: 238;
  --crop-width: 242;
  --crop-height: 167;
}
.activity-banner[data-activity="results"] .activity-illustration {
  --image: url("./photos/results-reference.png");
  --image-width: 977;
  --image-height: 1609;
  --crop-x: 625;
  --crop-y: 615;
  --crop-width: 262;
  --crop-height: 174;
}
.activity-banner[data-activity="games"] .activity-illustration {
  --image: url("./photos/home-reference.png");
  --image-width: 887;
  --image-height: 1774;
  --crop-x: 47;
  --crop-y: 1204;
  --crop-width: 137;
  --crop-height: 101;

}
.activity-action {
  grid-area: action; justify-self: start; display: inline-flex; align-items: center; gap: 4px;
  min-height: 40px; color: #006960; font-size: .875rem; line-height: 1.35; font-weight: 700; overflow-wrap: anywhere;
}
.activity-action:hover { text-decoration: underline; }
.activity-action .icon { width: 15px; height: 15px; flex: none; }
@media (max-width: 1023px) {
  body[data-page="activities"] .container { width: 100%; margin-top: 0; }
}
@media (min-width: 1024px) {
  .activity-center { max-width: none; }
  .activity-hero { min-height: 160px; padding: 22px 28px; border-radius: var(--card-radius); }
  .activity-hero h1 { font-size: clamp(2rem, 3vw, 2.75rem); }
  .activity-hero-art { right: 5%; width: 36%; }
  .activity-banners { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; padding: 18px 0; }
  .activity-banner { min-height: 150px; padding: 18px; grid-template-rows: 1fr auto; }
}
