/* Puffball — shared site styles (tokens, base, inflatable button, beach footer). Page-specific styles live in each page. */
/* ===== Puffball tokens (Day theme) — from design-system/tokens.json ===== */
:root {
  --bg: #8EDBFF; --stripe: rgba(255,255,255,.28);
  --surface: #FFFFFF; --raised: #F1F5FF; --well: #DDE6FA; --surface-lip: #A9BAE3;
  --ink: #14205A; --ink-2: #33407A; --ink-3: #4E5A88;
  --volt: #B8F23A; --volt-lip: #6DA312; --on-volt: #1B2A00;
  --aqua: #33E1EE; --aqua-lip: #0FA4BC; --on-aqua: #00313A;
  --gold: #FFC93C; --gold-lip: #D29500; --on-gold: #3A2500;
  --pop: #FF5FD2; --pop-lip: #C02C9E; --on-pop: #3D0030;
  --red: #FF4D5E; --red-lip: #C2253A; --blue: #3D8BFF; --blue-lip: #1F57CC;
  --pitch: #3FAE4F; --pitch-stripe: #37A047; --turf: #1F6B33; --chalk: #F4FFF2;
  --focus: #1F57CC;
  --gloss: inset 0 3px 0 rgba(255,255,255,.45);
  --shade: rgba(20,32,90,.22);
  --display: "Fredoka", "Rubik", system-ui, sans-serif;
  --body: "Rubik", system-ui, sans-serif;
  --ease-pop: linear(0, 0.23 8%, 0.61 16%, 0.88 24%, 1.02 31%, 1.06 38%, 1.04 48%, 1 62%, 0.995 80%, 1);
  --ease-boing: linear(0, 0.36 9%, 0.83 18%, 1.12 27%, 1.16 33%, 1.06 43%, 0.97 53%, 0.99 66%, 1.01 78%, 1);
  --ease-snap: cubic-bezier(.2,0,0,1);
  --ease-glide: cubic-bezier(.22,1,.36,1);
}
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; }
body {
  min-height: 100svh; display: flex; flex-direction: column;
  font: 500 17px/1.5 var(--body); color: var(--ink-2);
  background-color: var(--bg);
  background-image:
    radial-gradient(ellipse 70% 55% at 85% -5%, rgba(255,255,255,.75), transparent 60%),
    repeating-linear-gradient(115deg, var(--stripe) 0 56px, transparent 56px 112px);
  overflow-x: hidden;
}
a { color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 12px; }

.skip { position: absolute; top: -60px; inset-inline-start: 16px; z-index: 50; padding: 10px 18px; border-radius: 999px;
  background: var(--ink); color: #fff; font: 700 16px/1 var(--display); text-decoration: none; transition: top .2s; }
.skip:focus { top: 16px; }

/* ===== Clouds ===== */
.sky { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 0; }
.cloud { position: absolute; width: var(--w); height: calc(var(--w) * .34); top: var(--t); left: -30%;
  background: #fff; border-radius: 999px; opacity: .9; filter: drop-shadow(0 6px 0 rgba(169,186,227,.55));
  animation: drift var(--d) linear infinite; animation-delay: var(--delay); }
.cloud::before, .cloud::after { content: ""; position: absolute; background: #fff; border-radius: 50%; }
.cloud::before { width: 46%; height: 135%; left: 16%; bottom: 20%; }
.cloud::after  { width: 34%; height: 105%; left: 50%; bottom: 25%; }
@keyframes drift { to { transform: translateX(170vw); } }

/* ===== Inflatable button (design-system Button) ===== */
.btn {
  --h: 84px; --lip: 8px; --face: var(--volt); --lipc: var(--volt-lip); --fg: var(--on-volt);
  position: relative; isolation: isolate; display: inline-flex; align-items: center; justify-content: center; gap: 14px;
  height: var(--h); padding: 0 clamp(36px, 5vw, 54px); border: 0; border-radius: 999px; cursor: pointer; text-decoration: none;
  font: 700 clamp(26px, 3.4vw, 32px)/1 var(--display); color: var(--fg); text-shadow: 0 1px 0 rgba(255,255,255,.45);
  background: linear-gradient(180deg, color-mix(in srgb, var(--face) 78%, #fff), var(--face) 55%, color-mix(in srgb, var(--face) 92%, #000));
  box-shadow: var(--gloss), 0 var(--lip) 0 var(--lipc), 0 calc(var(--lip) + 12px) 24px var(--shade);
  -webkit-tap-highlight-color: transparent; user-select: none;
  transition: transform .32s var(--ease-pop), box-shadow .32s var(--ease-pop);
}
.btn::after { content: ""; position: absolute; z-index: -1; left: 11%; top: 10%; width: 32%; height: 28%; border-radius: 999px; background: rgba(255,255,255,.42); }
.btn svg { width: 1em; height: 1em; }
.btn .label { position: relative; }
@media (hover: hover) {
  .btn:hover { transform: translateY(-3px) scale(1.04); box-shadow: var(--gloss), 0 calc(var(--lip) + 3px) 0 var(--lipc), 0 calc(var(--lip) + 18px) 28px var(--shade); }
  .btn:hover svg { animation: nudge .6s var(--ease-pop) infinite alternate; }
}
@keyframes nudge { to { transform: translateX(4px); } }
.btn:active, .btn.is-pressed { transform: translateY(calc(var(--lip) - 1px)) scale(1.04, .93);
  box-shadow: var(--gloss), 0 1px 0 var(--lipc), 0 4px 8px var(--shade); transition-duration: 80ms; transition-timing-function: var(--ease-snap); }
@keyframes rise { from { transform: translateY(14px) scale(.92); opacity: 0; } }

/* ===== Turf strip: grass edge above the beach footer on inner pages ===== */
.turf-strip { position: relative; z-index: 1; flex: none; height: 72px; margin-top: 48px; background-color: var(--pitch);
  background-image: repeating-linear-gradient(90deg, var(--pitch) 0 64px, var(--pitch-stripe) 64px 128px); }
.turf-strip::before { content: ""; position: absolute; inset: -10px 0 auto; height: 14px; background: var(--chalk); border-radius: 14px 14px 0 0; opacity: .9; }

/* ===== Footer: the beach. Sand meets the pitch, the sea laps at the bottom ===== */
footer { position: relative; z-index: 2; flex: none; margin-top: -26px; color: var(--ink-2); }
.shore { display: block; width: 100%; height: 30px; }
.sand { position: relative; background-color: #F7DFA8; padding: 18px 16px 40px; overflow: hidden;
  background-image:
    radial-gradient(circle at 20% 30%, rgba(201,150,62,.18) 0 1.5px, transparent 2px),
    radial-gradient(circle at 70% 60%, rgba(201,150,62,.14) 0 1.2px, transparent 1.7px),
    radial-gradient(circle at 45% 85%, rgba(255,255,255,.5) 0 1.4px, transparent 2px);
  background-size: 26px 26px, 34px 34px, 30px 30px; }
.cols { position: relative; z-index: 1; max-width: 1120px; margin: 0 auto; display: grid;
  grid-template-columns: 1.3fr repeat(3, 1fr); gap: 28px 32px; align-items: start; }
.brand img { display: block; width: auto; height: 92px; max-width: 100%; filter: drop-shadow(0 6px 0 rgba(201,150,62,.25)); }
.group h2 { margin: 6px 0 14px; font: 700 20px/1.2 var(--display); color: var(--ink); }
.group ul { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; margin: 0; padding: 0; list-style: none; }
.pill { display: inline-flex; align-items: center; gap: 9px; height: 44px; padding: 0 7px 0 16px; border-radius: 999px; text-decoration: none; white-space: nowrap;
  background: #FFFDF6; color: var(--ink); font: 600 16px/1 var(--display);
  box-shadow: inset 0 3px 0 #fff, 0 4px 0 #D9B56C, 0 10px 14px rgba(150,105,30,.18);
  transition: transform .32s var(--ease-pop), box-shadow .32s var(--ease-pop); }
[dir="rtl"] .pill { padding: 0 7px 0 16px; }
.pill .ic { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; flex: none;
  background: var(--c); color: var(--on, #fff); box-shadow: inset 0 -3px 0 var(--cl), inset 0 2px 0 rgba(255,255,255,.4); transition: transform .4s var(--ease-boing); }
.pill .ic svg { width: 17px; height: 17px; }
@media (hover: hover) {
  .pill:hover { transform: translateY(-3px); box-shadow: inset 0 3px 0 #fff, 0 7px 0 #D9B56C, 0 14px 18px rgba(150,105,30,.2); }
  .pill:hover .ic { transform: rotate(-12deg) scale(1.12); }
}
.pill:active { transform: translateY(3px) scale(1.03, .95); box-shadow: inset 0 3px 0 #fff, 0 1px 0 #D9B56C; transition-duration: 80ms; }
.group ul.social { flex-direction: row; }
.social { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; padding: 0; list-style: none; }
.soc { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; color: #fff; text-decoration: none;
  background: var(--c); box-shadow: inset 0 3px 0 rgba(255,255,255,.4), 0 4px 0 var(--cl), 0 10px 14px rgba(150,105,30,.2);
  transition: transform .4s var(--ease-boing), box-shadow .32s var(--ease-pop); }
.soc svg { width: 24px; height: 24px; }
@media (hover: hover) { .soc:hover { transform: translateY(-4px) rotate(-8deg) scale(1.08); } }
.soc:active { transform: translateY(3px) scale(.95); box-shadow: inset 0 3px 0 rgba(255,255,255,.4), 0 1px 0 var(--cl); transition-duration: 80ms; }
/* beach props */
.prop { position: absolute; z-index: 0; pointer-events: none; }
.prop.star { width: 58px; bottom: 24px; inset-inline-start: calc(50% - 640px); transform: rotate(-14deg); }
.prop.shell { width: 42px; top: 30px; inset-inline-end: calc(50% - 630px); transform: rotate(12deg); }
.prop.bball { width: 64px; bottom: 26px; inset-inline-end: calc(50% - 650px); animation: bob 3.2s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-6px) rotate(8deg); } }
/* the sea */
.sea { position: relative; background: linear-gradient(180deg, #0E86B4, #08577F 70%); color: #fff;
  padding: 34px 16px calc(18px + env(safe-area-inset-bottom)); }
.waves { position: absolute; left: 0; right: 0; top: -22px; height: 34px; overflow: hidden; }
.waves i { position: absolute; inset: 0 -200px 0 0; background-repeat: repeat-x; background-size: 200px 34px; }
.waves i:nth-child(1) { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 34'%3E%3Cpath d='M0 22 Q25 6 50 22 T100 22 T150 22 T200 22 V34 H0Z' fill='%2333E1EE' opacity='.55'/%3E%3C/svg%3E"); animation: surf 9s linear infinite; }
.waves i:nth-child(2) { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 34'%3E%3Cpath d='M0 26 Q25 12 50 26 T100 26 T150 26 T200 26 V34 H0Z' fill='%230E86B4'/%3E%3Cpath d='M0 26 Q25 12 50 26 T100 26 T150 26 T200 26' fill='none' stroke='%23FFFFFF' stroke-width='3' stroke-linecap='round' opacity='.8'/%3E%3C/svg%3E"); animation: surf 6s linear infinite reverse; }
@keyframes surf { to { transform: translateX(-200px); } }
.bottom { max-width: 1120px; margin: 0 auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 24px;
  font: 500 15px/1.5 var(--body); color: #fff; }
.bottom p { margin: 0; }
.bottom a { color: #fff; text-decoration: none; background-image: linear-gradient(currentColor, currentColor); background-size: 0% 2px;
  background-repeat: no-repeat; background-position: 100% 100%; transition: background-size .3s var(--ease-glide); }
.bottom a:hover { background-size: 100% 2px; }

@media (max-width: 1300px) { .prop.bball, .prop.shell { display: none; } .prop.star { inset-inline-start: 12px; } }
@media (max-width: 860px) {
  .cols { grid-template-columns: 1fr 1fr; }
  .brand { grid-column: 1 / -1; display: flex; justify-content: center; }
  .brand img { height: 78px; }
  .group.follow { grid-column: 1 / -1; display: flex; flex-direction: column; align-items: center; }
  .group.follow h2 { text-align: center; }
  .bottom { justify-content: center; text-align: center; }
  .prop.shell, .prop.bball { display: none; }
  .prop.star { inset-inline-start: 12px; bottom: 14px; width: 44px; }
}
@media (max-width: 380px) { .pill { font-size: 15px; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 120ms !important; }
  .cloud { display: none; }
}

/* ===== Inner-page top bar ===== */
.topbar { position: relative; z-index: 3; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  max-width: 1120px; width: 100%; margin: 0 auto; padding: 18px 16px 0; }
.topbar .home img { display: block; height: 64px; width: auto; transition: transform .4s var(--ease-boing); }
.topbar .home:hover img { transform: rotate(-3deg) scale(1.04); }
.btn.btn--m { --h: 52px; --lip: 5px; font-size: 20px; padding: 0 22px; gap: 10px; }
.btn.btn--l { --h: 62px; --lip: 6px; font-size: 23px; padding: 0 30px; }
.btn.is-loading { color: transparent; text-shadow: none; pointer-events: none; }
.btn.is-loading::before { content: ""; position: absolute; left: 50%; top: 50%; width: 20px; height: 20px; margin: -10px 0 0 -10px;
  border-radius: 50%; background: var(--on-volt); animation: hop .6s var(--ease-snap) infinite alternate; }
@keyframes hop { from { transform: translateY(7px) scale(1.15, .85); } to { transform: translateY(-9px) scale(.95, 1.05); } }
@media (max-width: 520px) {
  .topbar .home img { height: 48px; }
  .btn.btn--m { --h: 46px; font-size: 18px; padding: 0 16px; }
}
.group h2 .group-link { color: inherit; text-decoration: none; background-image: linear-gradient(currentColor, currentColor);
  background-size: 0% 3px; background-repeat: no-repeat; background-position: 100% 100%; transition: background-size .3s var(--ease-glide); }
.group h2 .group-link:hover { background-size: 100% 3px; }
