/* Shared look of the static pages teachers.html and press.html (#402) and
   watch.html (#540): the
   game's jelly look (index.css "Jelly look" and "Jelly Home") in plain CSS.
   Fonts are the game's own files, copied to public/fonts/. Only transform
   moves, and nothing moves under prefers-reduced-motion. */
@font-face { font-family: 'Fredoka'; font-style: normal; font-weight: 300 700; font-display: swap; src: url('fonts/fredoka-latin.woff2') format('woff2'); }
@font-face { font-family: 'Nunito'; font-style: normal; font-weight: 200 1000; font-display: swap; src: url('fonts/nunito-latin.woff2') format('woff2'); }

:root {
  color-scheme: light;
  --cream: #FFF8DA;
  --panel: #FFFBEA;
  --ink: #3C3550;
  --text: #55545A;
  --soft: #6B6377;
  --pink: #D63A55;
  --pink-base: #A82A43;
  --link: #B42D47;
  --teal: #0F766E;
  --teal-base: #0B5A54;
  --rim: #e9e3ec;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  color: var(--text);
  font: 17px/1.55 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif;
  background-color: var(--cream);
  background-image:
    radial-gradient(55% 48% at 50% 20%, rgba(255, 255, 255, 0.8) 0%, rgba(255, 255, 255, 0) 70%),
    radial-gradient(40% 40% at 8% 100%, rgba(255, 214, 222, 0.45) 0%, rgba(255, 214, 222, 0) 70%),
    radial-gradient(35% 40% at 100% 10%, rgba(190, 242, 226, 0.4) 0%, rgba(190, 242, 226, 0) 70%);
  background-attachment: fixed;
}
h1, h2, h3 { font-family: 'Fredoka', 'Nunito', system-ui, sans-serif; color: var(--ink); line-height: 1.15; margin: 0; }
h1 { font-size: clamp(2rem, 5vw, 2.9rem); font-weight: 600; letter-spacing: -0.01em; }
h2 { font-size: 1.5rem; font-weight: 600; margin-bottom: 12px; }
h3 { font-size: 1.15rem; font-weight: 600; }
p { margin: 0 0 10px; }
a { color: var(--link); font-weight: 700; text-underline-offset: 3px; overflow-wrap: anywhere; }
/* The outline follows each element's own radius, so pills stay round. Only
   plain text links get a soft corner. */
a:focus-visible, button:focus-visible { outline: 3px solid var(--pink); outline-offset: 3px; }
:is(p, dd, footer, ul:not(.links) li) a:not([class]):focus-visible { border-radius: 4px; }
img { max-width: 100%; height: auto; display: block; }
strong { color: var(--ink); }

.wrap { position: relative; max-width: 1120px; margin: 0 auto; padding: 24px 16px 40px; }

/* The logo artwork without the transparent padding around it (same crop as
   shareCard.js: x 66, y 125, w 379, h 215 of the 511x488 file). */
.logo { --s: 0.42; display: block; width: calc(379px * var(--s)); height: calc(215px * var(--s)); overflow: hidden; flex: none; }
.logo img { max-width: none; width: calc(511px * var(--s)); margin: calc(-125px * var(--s)) 0 0 calc(-66px * var(--s)); }

.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.top-links { display: flex; gap: 6px 18px; flex-wrap: wrap; font-size: 15px; }
.top-links a { display: inline-flex; align-items: center; min-height: 40px; color: var(--text); text-decoration: none; }
.top-links a:hover { color: var(--link); text-decoration: underline; }

.badge {
  display: inline-block; padding: 5px 14px; border-radius: 999px; margin-bottom: 12px;
  font: 600 15px/1.3 'Fredoka', 'Nunito', sans-serif; color: var(--teal-base);
  background: #DDF8EA; box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.9), 0 2px 6px -1px rgba(70, 40, 55, 0.14);
}
.lead { font-size: 1.15rem; max-width: 40em; margin: 12px 0 18px; }

/* Cards: glossy with a white rim. */
.card {
  background-color: var(--panel);
  background-image: radial-gradient(120% 60% at 0% 0%, rgba(255, 255, 255, 0.85) 0%, rgba(255, 255, 255, 0) 60%);
  border-radius: 26px;
  padding: 20px 20px 16px;
  box-shadow: inset 0 3px 0 rgba(255, 255, 255, 0.95), 0 14px 30px -16px rgba(70, 40, 55, 0.3), 0 0 0 1px rgba(233, 227, 236, 0.7);
}
.grid { display: grid; gap: 18px; }
@media (min-width: 900px) { .grid-2 { grid-template-columns: 1fr 1fr; } }

/* Squishy buttons: a fill standing on a darker base that sinks when pressed. */
.jelly-btn {
  --fill: #fff; --base: var(--rim); --lift: 5px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 10px 26px; border: 0; border-radius: 999px; cursor: pointer;
  font: 600 1.15rem/1.1 'Fredoka', 'Nunito', sans-serif; text-decoration: none; color: var(--text);
  background-color: var(--fill);
  background-image: linear-gradient(180deg, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0.06) 45%, rgba(255, 255, 255, 0) 55%, rgba(0, 0, 0, 0.03) 100%);
  box-shadow: 0 var(--lift) 0 var(--base), 0 calc(var(--lift) + 5px) 14px -5px rgba(70, 40, 55, 0.28), inset 0 2px 0 rgba(255, 255, 255, 0.55), inset 0 -3px 0 rgba(0, 0, 0, 0.06);
  transition: transform 120ms cubic-bezier(0.23, 1, 0.32, 1);
}
.jelly-btn:active { transform: translateY(3px); }
.jelly-primary { --fill: var(--pink); --base: var(--pink-base); color: #fff; text-shadow: 0 1px 1px rgba(110, 20, 40, 0.45); }
.jelly-teal { --fill: var(--teal); --base: var(--teal-base); color: #fff; }
.actions { display: flex; flex-wrap: wrap; gap: 14px 16px; align-items: center; margin-bottom: 8px; }

/* Bubbles drifting behind the page. */
.bubbles { position: fixed; inset: 0; overflow: hidden; pointer-events: none; z-index: -1; }
.bubble {
  position: absolute; border-radius: 50%;
  background: radial-gradient(circle at 32% 30%, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.35) 22%, rgba(255, 170, 185, 0.16) 60%, rgba(255, 170, 185, 0.05) 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.6);
  animation: drift 16s ease-in-out infinite alternate;
}
.bubble.teal { background: radial-gradient(circle at 32% 30%, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.35) 22%, rgba(110, 231, 210, 0.18) 60%, rgba(110, 231, 210, 0.05) 100%); animation-duration: 21s; }
@keyframes drift { from { transform: translate3d(0, 0, 0) scale(1); } to { transform: translate3d(18px, -26px, 0) scale(1.06); } }

footer { margin-top: 26px; text-align: center; font-size: 15px; color: var(--soft); }
footer p { margin: 4px 0; }

@media (prefers-reduced-motion: reduce) {
  .bubble { animation: none; }
  .jelly-btn { transition: none; }
  .jelly-btn:active { transform: none; }
}
