*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  height: 100%;
  font-size: 18px;
}

body {
  color: var(--aero-fg);
  background: #dff5ff;
  overflow: hidden;
  font-family: "Itim", "Segoe UI", "Noto Sans", sans-serif;
}

.aero-ui-shell,
.aero-ui-shell button,
.aero-ui-shell input,
.aero-ui-shell textarea,
.aero-ui-shell select {
  font-family: "Itim", "Segoe UI", "Noto Sans", sans-serif;
}

.aero-ui-shell {
  height: 100vh;
}

.site-layout {
  grid-template-columns: 560px 1fr;
  height: 100%;
  min-height: 0;
}

.site-sidebar {
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow: hidden;
  min-height: 0;
  height: 100%;
}

.site-sidebar .aero-card {
  margin-bottom: 0;
}

.timeline-panel {
  display: flex;
  flex: 1;
  min-height: 0;
  max-height: 100%;
  padding: 12px;
  overflow: auto;
  overscroll-behavior: contain;
}

.timeline-wrap {
  display: block;
  width: 100%;
  overflow: visible;
  border-radius: 14px;
}

.timeline-wrap iframe {
  display: block;
  width: 100% !important;
  max-width: none !important;
}

.timeline-wrap::after {
  content: "";
  display: block;
  height: 10px;
}

.site-main {
  background: transparent;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  padding: 20px;
  overflow: hidden;
  min-height: 0;
  height: 100%;
}

.site-shell {
  display: flex;
  flex-direction: column;
  gap: 14px;
  height: 100%;
  min-height: 0;
}

.site-header {
  display: flex;
  align-items: flex-start;
  max-width: 620px;
}

.site-wordmark-bubble {
  display: inline-grid;
  place-items: center;
  padding: 20px 30px;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 999px;
  background:
    radial-gradient(circle at 30% 24%, rgba(255, 255, 255, 0.96), rgba(255, 255, 255, 0.48) 28%, rgba(255, 255, 255, 0.16) 55%, rgba(255, 255, 255, 0.2) 100%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.52), rgba(122, 215, 255, 0.18) 42%, rgba(0, 137, 220, 0.3) 100%);
  box-shadow:
    inset 0 2px 4px rgba(255, 255, 255, 0.92),
    inset 0 -10px 18px rgba(24, 115, 175, 0.16),
    0 10px 26px rgba(0, 46, 76, 0.24);
  cursor: pointer;
  user-select: none;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  transition: box-shadow 140ms ease, opacity 180ms ease;
  will-change: transform;
}

.site-wordmark-bubble:hover {
  box-shadow:
    inset 0 2px 4px rgba(255, 255, 255, 0.98),
    inset 0 -10px 18px rgba(24, 115, 175, 0.2),
    0 14px 34px rgba(0, 46, 76, 0.3);
}

.site-wordmark {
  margin: 0;
  font-size: clamp(2.75rem, 5vw, 4.8rem);
  line-height: 0.95;
  font-weight: 400;
  color: #194461;
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.92),
    0 10px 22px rgba(120, 46, 90, 0.18);
}

.cursor-tooltip {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 20;
  padding: 8px 12px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.78);
  color: #194461;
  font-size: 0.9rem;
  line-height: 1.1;
  white-space: nowrap;
  box-shadow: 0 10px 24px rgba(0, 46, 76, 0.16);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  opacity: 0;
  transform: translate3d(0, 0, 0);
  pointer-events: none;
  transition: opacity 140ms ease, transform 140ms ease;
}

.cursor-tooltip.is-visible {
  opacity: 1;
}

.ui-hidden .site-layout {
  opacity: 0;
  pointer-events: none;
}

.stage-frame {
  flex: 1;
  min-height: 0;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 32px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.06)),
    linear-gradient(135deg, rgba(119, 219, 255, 0.14), rgba(11, 85, 126, 0.08));
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.72),
    0 24px 46px rgba(3, 41, 62, 0.12);
}

.bubble-stage {
  position: relative;
  height: 100%;
  min-height: 0;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0.06)),
    linear-gradient(135deg, rgba(80, 188, 239, 0.16), rgba(7, 86, 126, 0.08));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.65),
    0 18px 42px rgba(3, 41, 62, 0.14);
  overflow: hidden;
}

.bubble-stage::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.3), transparent 38%),
    radial-gradient(circle at bottom right, rgba(255, 255, 255, 0.18), transparent 30%);
  pointer-events: none;
}

.hbc-water-fish {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.fish-swimmer {
  position: absolute;
  top: 0;
  left: 0;
  width: auto;
  height: auto;
  opacity: 1;
  clip-path: inset(50% 0 0 0);
  transform-origin: top left;
  will-change: transform, opacity;
  filter: drop-shadow(0 6px 12px rgba(0, 42, 73, 0.12));
}

.bubble-button {
  position: absolute;
  display: grid;
  place-items: center;
  width: 210px;
  height: 210px;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 999px;
  background:
    radial-gradient(circle at 30% 24%, rgba(255, 255, 255, 0.96), rgba(255, 255, 255, 0.48) 28%, rgba(255, 255, 255, 0.16) 55%, rgba(255, 255, 255, 0.2) 100%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.52), rgba(122, 215, 255, 0.18) 42%, rgba(0, 137, 220, 0.3) 100%);
  box-shadow:
    inset 0 2px 4px rgba(255, 255, 255, 0.92),
    inset 0 -10px 18px rgba(24, 115, 175, 0.16),
    0 10px 26px rgba(0, 46, 76, 0.24);
  color: #194461;
  font: inherit;
  font-size: 1.9rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
  cursor: grab;
  user-select: none;
  touch-action: none;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  transition: box-shadow 140ms ease;
  will-change: transform;
  opacity: 0;
}

.bubble-button:hover {
  box-shadow:
    inset 0 2px 4px rgba(255, 255, 255, 0.98),
    inset 0 -10px 18px rgba(24, 115, 175, 0.2),
    0 14px 34px rgba(0, 46, 76, 0.3);
}

.bubble-button:active,
.bubble-button.is-dragging {
  cursor: grabbing;
  box-shadow:
    inset 0 2px 6px rgba(255, 255, 255, 0.98),
    inset 0 -12px 24px rgba(24, 115, 175, 0.24),
    0 18px 38px rgba(0, 46, 76, 0.32);
}

.bubble-button span {
  pointer-events: none;
}

.bubble-button.is-ready {
  opacity: 1;
}

@media (max-width: 900px) {
  .site-layout {
    grid-template-columns: 1fr;
  }

  .site-main {
    padding: 16px;
  }

  .site-shell {
    height: 100%;
  }

  .bubble-stage {
    min-height: 0;
  }
}
