:root {
  /* IBM Plex Mono remains sparingly used as a small annotation texture while letting Rubik Bubbles and Nunito Sans carry the identity. */
  --aero-lagoon: #7FE8FF;
  --glass-cyan: #D9FBFF;
  --deep-pool: #083A4A;
  --lime-reflection: #B8FF4D;
  --coral-compile: #FF6B7A;
  --soft-chrome: #E7EEF5;
  --bubble-violet: #A98BFF;
  --white-glint: #FFFFFF;
  --display: "Rubik Bubbles", "Cooper Black", "Arial Rounded MT Bold", system-ui, sans-serif;
  --body: "Nunito Sans", "Inter", "Segoe UI", system-ui, sans-serif;
  --mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  font-family: var(--body);
  color: var(--deep-pool);
  background:
    radial-gradient(circle at 20% 10%, rgba(255,255,255,.95), transparent 18%),
    radial-gradient(circle at 80% 0%, rgba(184,255,77,.52), transparent 22%),
    linear-gradient(135deg, var(--aero-lagoon), var(--glass-cyan) 45%, var(--bubble-violet));
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(circle, rgba(255,255,255,.62) 0 2px, transparent 3px),
    linear-gradient(115deg, transparent 0 42%, rgba(255,255,255,.22) 43% 46%, transparent 47%);
  background-size: 86px 86px, 260px 260px;
  animation: bubbleDrift 22s linear infinite;
  z-index: 1;
}

.aero-story { position: relative; z-index: 2; }

.scene {
  min-height: 100vh;
  position: relative;
  overflow: hidden;
  padding: clamp(24px, 4vw, 64px);
}

.aero-workbench {
  background:
    radial-gradient(ellipse at 50% 0%, rgba(255,255,255,.76), transparent 42%),
    radial-gradient(circle at 12% 78%, rgba(169,139,255,.46), transparent 22%),
    radial-gradient(circle at 88% 72%, rgba(184,255,77,.38), transparent 24%),
    linear-gradient(180deg, #D9FBFF 0%, #7FE8FF 48%, #61c8df 100%);
}

.water-surface {
  position: absolute;
  inset: -20% -10%;
  background: repeating-radial-gradient(ellipse at 50% 10%, rgba(255,255,255,.2) 0 2px, transparent 3px 42px);
  filter: blur(.4px);
  transform: rotate(-8deg);
  animation: shimmer 8s ease-in-out infinite alternate;
}

.glass-window {
  border: 1px solid rgba(255,255,255,.78);
  background:
    linear-gradient(145deg, rgba(255,255,255,.62), rgba(217,251,255,.22) 42%, rgba(169,139,255,.18)),
    radial-gradient(circle at 18% 8%, rgba(255,255,255,.9), transparent 28%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.9), inset 0 -18px 38px rgba(8,58,74,.08), 0 24px 70px rgba(8,58,74,.25);
  backdrop-filter: blur(18px) saturate(1.45);
  border-radius: 34px;
}

.glass-titlebar {
  width: min(880px, 92vw);
  margin: 0 auto;
  padding: 18px clamp(22px, 4vw, 48px) 30px;
  text-align: center;
  border-radius: 44px 44px 58px 58px;
  transform: rotate(-1.5deg);
  z-index: 5;
  position: relative;
}

.traffic-bubbles { display: flex; gap: 10px; position: absolute; left: 28px; top: 22px; }
.traffic-bubbles span, .window-rim i {
  width: 16px; height: 16px; border-radius: 50%; display: block;
  background: radial-gradient(circle at 35% 25%, var(--white-glint), var(--coral-compile));
  box-shadow: inset -2px -3px 6px rgba(8,58,74,.2);
}
.traffic-bubbles span:nth-child(2), .window-rim i:nth-of-type(1) { background: radial-gradient(circle at 35% 25%, var(--white-glint), var(--lime-reflection)); }
.traffic-bubbles span:nth-child(3), .window-rim i:nth-of-type(2) { background: radial-gradient(circle at 35% 25%, var(--white-glint), var(--aero-lagoon)); }

h1, h2, .juggle-orb, .mini-orb, .settled-orb { font-family: var(--display); font-weight: 900; }
h1 { margin: 20px 0 4px; font-size: clamp(4rem, 14vw, 11rem); line-height: .82; letter-spacing: -.06em; color: var(--white-glint); text-shadow: 0 5px 0 rgba(8,58,74,.18), 0 0 24px rgba(127,232,255,.9); }
h1 span { color: var(--deep-pool); text-shadow: 0 2px 0 rgba(255,255,255,.8); }
h2 { font-size: clamp(2rem, 5vw, 4.4rem); line-height: .9; margin: 0 0 14px; letter-spacing: -.04em; }
p { font-size: clamp(1rem, 1.45vw, 1.25rem); line-height: 1.55; }
.title-caption { max-width: 650px; margin: 0 auto; color: rgba(8,58,74,.82); font-weight: 800; }
.mono-tag { font-family: var(--mono); font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; }

.throw-path { position: absolute; inset: 10vh 0 0; width: 100%; height: 74vh; pointer-events: none; z-index: 3; }
.path-line { fill: none; stroke: rgba(255,255,255,.78); stroke-width: 8; stroke-linecap: round; stroke-dasharray: 18 26; filter: drop-shadow(0 0 10px rgba(255,255,255,.9)); animation: dashSwim 5s linear infinite; }
.line-b { stroke: rgba(184,255,77,.62); animation-duration: 6.4s; }
.line-c { stroke: rgba(169,139,255,.58); animation-duration: 7.2s; }

.orb-field { position: absolute; inset: 0; z-index: 7; pointer-events: none; }
.juggle-orb {
  position: absolute;
  left: var(--x); top: var(--y);
  width: clamp(88px, 10vw, 140px); height: clamp(88px, 10vw, 140px);
  border-radius: 50%; border: 0; color: var(--deep-pool); cursor: pointer; pointer-events: auto;
  background:
    radial-gradient(circle at 28% 22%, var(--white-glint) 0 12%, rgba(255,255,255,.65) 13% 23%, transparent 24%),
    radial-gradient(circle at 64% 78%, rgba(8,58,74,.18), transparent 30%),
    radial-gradient(circle at 42% 38%, var(--orb), var(--glass-cyan) 72%);
  box-shadow: inset -14px -20px 26px rgba(8,58,74,.18), inset 10px 12px 22px rgba(255,255,255,.7), 0 22px 44px rgba(8,58,74,.26), 0 0 34px color-mix(in srgb, var(--orb), white 35%);
  transform: translate(-50%, -50%);
  animation: juggle 6.8s cubic-bezier(.55,-.25,.35,1.25) infinite var(--delay), orbPulse 2.8s ease-in-out infinite;
}
.juggle-orb:hover, .juggle-orb.active { scale: 1.12; filter: saturate(1.25); }

.code-pane { position: absolute; left: 7vw; bottom: 8vh; width: min(420px, 38vw); padding: 18px; z-index: 4; transform: rotate(3deg); }
.shell-bubble { position: absolute; right: 7vw; top: 39vh; width: min(360px, 35vw); padding: 18px; z-index: 4; border-radius: 46px; transform: rotate(-4deg); }
.window-rim { display: flex; align-items: center; gap: 8px; font-family: var(--mono); font-size: .78rem; color: var(--deep-pool); margin-bottom: 14px; }
.window-rim span { margin-right: auto; }
pre { margin: 0; white-space: pre-wrap; font: 700 .95rem/1.55 var(--mono); color: rgba(8,58,74,.86); }
.liquid-progress { height: 24px; border-radius: 99px; overflow: hidden; background: rgba(255,255,255,.5); box-shadow: inset 0 2px 8px rgba(8,58,74,.16); }
.liquid-progress span { display: block; height: 100%; width: 72%; border-radius: inherit; background: linear-gradient(90deg, var(--lime-reflection), var(--aero-lagoon), var(--bubble-violet)); animation: liquid 3s ease-in-out infinite alternate; }

.catcher-cursor { position: absolute; left: 50%; bottom: 11vh; width: 76px; height: 92px; z-index: 8; filter: drop-shadow(0 18px 18px rgba(8,58,74,.28)); animation: catchBob 2.2s ease-in-out infinite; }
.catcher-cursor::before { content: ""; position: absolute; width: 0; height: 0; border-left: 24px solid var(--white-glint); border-top: 38px solid transparent; border-bottom: 12px solid transparent; transform: rotate(-18deg); }
.catcher-cursor span { position: absolute; left: 25px; top: 40px; width: 34px; height: 28px; border-radius: 18px; background: var(--white-glint); border: 2px solid rgba(8,58,74,.2); }
.catcher-cursor.catch { animation: catchSnap .42s ease; }

.micro-scene { position: fixed; right: clamp(18px, 5vw, 70px); bottom: clamp(18px, 5vw, 70px); width: min(390px, calc(100vw - 36px)); padding: 26px; border-radius: 32px; z-index: 20; transform: translateY(24px) scale(.92); opacity: 0; pointer-events: none; transition: .38s cubic-bezier(.34,1.56,.64,1); }
.micro-scene.open { opacity: 1; pointer-events: auto; transform: translateY(0) scale(1); }
.micro-close { position: absolute; right: 14px; top: 10px; border: 0; border-radius: 50%; width: 34px; height: 34px; background: var(--coral-compile); color: var(--white-glint); font-size: 1.4rem; cursor: pointer; }

.refraction-ring { position: absolute; border: 2px solid rgba(255,255,255,.52); border-radius: 50%; box-shadow: inset 0 0 28px rgba(255,255,255,.36), 0 0 24px rgba(127,232,255,.34); animation: ringFloat 7s ease-in-out infinite; }
.ring-one { width: 220px; height: 220px; left: 8%; top: 16%; }
.ring-two { width: 340px; height: 340px; right: 6%; top: 10%; animation-delay: -2s; }
.ring-three { width: 180px; height: 180px; left: 48%; bottom: 9%; animation-delay: -4s; }

.throw-ritual { background: linear-gradient(180deg, #7FE8FF, #D9FBFF 58%, #E7EEF5); display: flex; align-items: center; }
.section-bubble { position: absolute; top: 38px; left: 50%; transform: translateX(-50%); }
.bubble-note { display: inline-block; padding: 10px 18px; border-radius: 99px; font-family: var(--mono); font-size: .76rem; text-transform: uppercase; letter-spacing: .12em; color: var(--deep-pool); background: rgba(255,255,255,.6); box-shadow: inset 0 1px 0 var(--white-glint), 0 10px 24px rgba(8,58,74,.14); }
.horizontal-lagoon { display: flex; gap: clamp(18px, 3vw, 36px); width: max-content; padding: 12vh 8vw; transform: translateX(var(--lagoon-shift, 0px)); transition: transform .2s ease-out; }
.ritual-orb { width: min(440px, 78vw); min-height: 340px; flex: 0 0 auto; padding: 34px; border-radius: 42px 70px 38px 58px; transform: rotate(var(--rot, -2deg)); }
.ritual-orb:nth-child(even) { --rot: 2deg; margin-top: 70px; }
.mini-orb { display: grid; place-items: center; width: 92px; height: 92px; margin-bottom: 28px; border-radius: 50%; background: radial-gradient(circle at 30% 22%, white, var(--glass-cyan) 28%, var(--bubble-violet)); box-shadow: inset -10px -12px 18px rgba(8,58,74,.18), 0 14px 25px rgba(8,58,74,.2); }

.build-room { background: radial-gradient(circle at 30% 20%, rgba(255,255,255,.55), transparent 30%), linear-gradient(180deg, #D9FBFF, #7FE8FF 44%, #083A4A); display: grid; place-items: center; }
.main-room { width: min(920px, 90vw); min-height: 520px; padding: clamp(22px, 4vw, 46px); }
.liquid-tabs { display: flex; flex-wrap: wrap; gap: 12px; margin: 26px 0; }
.liquid-tab { border: 1px solid rgba(255,255,255,.8); border-radius: 99px; padding: 13px 20px; color: var(--deep-pool); font-weight: 900; background: linear-gradient(180deg, rgba(255,255,255,.82), rgba(217,251,255,.38)); box-shadow: inset 0 1px 0 white, 0 10px 20px rgba(8,58,74,.14); cursor: pointer; transition: transform .22s ease, background .22s ease; }
.liquid-tab:hover, .liquid-tab.active { transform: translateY(-5px) scale(1.04); background: linear-gradient(180deg, var(--white-glint), var(--lime-reflection)); }
.tab-content { max-width: 620px; transition: opacity .24s ease, transform .24s ease; }
.tab-content.swap { opacity: 0; transform: scale(.96); }
.bubble-cluster span { position: absolute; display: grid; place-items: center; border-radius: 50%; width: 82px; height: 82px; background: radial-gradient(circle at 30% 25%, white, rgba(217,251,255,.7) 30%, rgba(127,232,255,.38)); box-shadow: inset -8px -10px 16px rgba(8,58,74,.15), 0 14px 30px rgba(8,58,74,.18); font-family: var(--mono); font-weight: 900; animation: bubbleRise 9s ease-in-out infinite; }
.bubble-cluster span:nth-child(1) { left: 12%; bottom: 16%; }
.bubble-cluster span:nth-child(2) { right: 14%; bottom: 20%; animation-delay: -2s; }
.bubble-cluster span:nth-child(3) { left: 20%; top: 22%; animation-delay: -4s; }
.bubble-cluster span:nth-child(4) { right: 22%; top: 18%; animation-delay: -6s; }
.bubble-cluster span:nth-child(5) { left: 48%; bottom: 8%; animation-delay: -8s; }

.sandbox { background: radial-gradient(circle at 50% 36%, rgba(255,255,255,.58), transparent 28%), linear-gradient(180deg, #083A4A, #7FE8FF); display: grid; place-items: center; }
.constellation { position: absolute; inset: 0; }
.settled-orb { position: absolute; display: grid; place-items: center; width: clamp(84px, 9vw, 124px); height: clamp(84px, 9vw, 124px); border-radius: 50%; color: var(--deep-pool); background: radial-gradient(circle at 28% 22%, var(--white-glint), var(--glass-cyan) 30%, var(--bubble-violet)); box-shadow: inset -12px -16px 20px rgba(8,58,74,.16), 0 18px 30px rgba(8,58,74,.18); animation: settled 5s ease-in-out infinite; }
.settled-orb:nth-child(1) { left: 14%; top: 25%; background: radial-gradient(circle at 28% 22%, white, #B8FF4D); }
.settled-orb:nth-child(2) { right: 16%; top: 20%; background: radial-gradient(circle at 28% 22%, white, #7FE8FF); animation-delay: -1s; }
.settled-orb:nth-child(3) { left: 28%; bottom: 18%; background: radial-gradient(circle at 28% 22%, white, #A98BFF); animation-delay: -2s; }
.settled-orb:nth-child(4) { right: 30%; bottom: 22%; background: radial-gradient(circle at 28% 22%, white, #FF6B7A); animation-delay: -3s; }
.settled-orb:nth-child(5) { left: 50%; top: 13%; background: radial-gradient(circle at 28% 22%, white, #D9FBFF); animation-delay: -4s; }
.calm-panel { width: min(760px, 90vw); padding: clamp(28px, 5vw, 56px); text-align: center; z-index: 2; }

@keyframes bubbleDrift { to { background-position: 80px -172px, 260px 260px; } }
@keyframes shimmer { from { transform: rotate(-8deg) translateY(-1%); } to { transform: rotate(-6deg) translateY(2%); } }
@keyframes dashSwim { to { stroke-dashoffset: -88; } }
@keyframes juggle { 0%,100% { transform: translate(-50%, -50%) translateY(0) rotate(-6deg); } 25% { transform: translate(-50%, -50%) translate(34px,-112px) rotate(10deg); } 50% { transform: translate(-50%, -50%) translate(72px,12px) rotate(-4deg); } 75% { transform: translate(-50%, -50%) translate(-22px,76px) rotate(12deg); } }
@keyframes orbPulse { 50% { box-shadow: inset -14px -20px 26px rgba(8,58,74,.18), inset 10px 12px 22px rgba(255,255,255,.7), 0 28px 54px rgba(8,58,74,.32), 0 0 54px color-mix(in srgb, var(--orb), white 45%); } }
@keyframes catchBob { 50% { transform: translateY(14px) rotate(4deg); } }
@keyframes catchSnap { 50% { transform: translateY(-24px) scale(1.14) rotate(-8deg); } }
@keyframes ringFloat { 50% { transform: translateY(24px) scale(1.06); opacity: .62; } }
@keyframes liquid { to { width: 94%; filter: hue-rotate(20deg); } }
@keyframes bubbleRise { 50% { transform: translateY(-34px) scale(1.08); } }
@keyframes settled { 50% { transform: translateY(-16px); } }

@media (max-width: 820px) {
  .code-pane, .shell-bubble { position: relative; left: auto; right: auto; top: auto; bottom: auto; width: 88vw; margin: 18px auto; }
  .code-pane { margin-top: 36vh; }
  .juggle-orb { width: 82px; height: 82px; font-size: .9rem; }
  .horizontal-lagoon { flex-direction: column; width: 100%; padding: 14vh 0 4vh; transform: none !important; }
  .ritual-orb { width: 100%; margin-top: 0 !important; }
  .bubble-cluster span { opacity: .55; }
}
