:root {
  --primary: #ff4fa3;
  --primary-2: #ff86c6;
  --bg: #fff3fb;
  --bg-2: #fffdf7;
  --text: #101010;
  --muted: #5b5b5b;
  --border: rgba(16, 16, 16, 0.12);
  --motion-multiplier: 1;
  --tilt-multiplier: 1;
  --particle-opacity: 0.5;
  --kicker-duration: 2.6s;
  --glow-strength: 1;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.7;
  perspective: 1200px;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(circle at 14% 18%, rgba(255, 79, 163, 0.14) 0%, rgba(255, 79, 163, 0) 46%),
    radial-gradient(circle at 86% 22%, rgba(255, 217, 102, 0.14) 0%, rgba(255, 217, 102, 0) 52%),
    radial-gradient(circle at 18% 86%, rgba(137, 255, 214, 0.11) 0%, rgba(137, 255, 214, 0) 52%),
    radial-gradient(circle at 84% 84%, rgba(168, 155, 255, 0.11) 0%, rgba(168, 155, 255, 0) 56%),
    linear-gradient(
      120deg,
      rgba(255, 79, 163, 0.14) 0%,
      rgba(255, 217, 102, 0.12) 25%,
      rgba(137, 255, 214, 0.1) 50%,
      rgba(168, 155, 255, 0.11) 75%,
      rgba(255, 134, 198, 0.13) 100%
    );
  background-size: 160% 160%;
  opacity: 0.92;
  animation: dopamine-bg 14s ease-in-out infinite alternate;
}

@keyframes dopamine-bg {
  0% {
    filter: saturate(1.05) hue-rotate(0deg);
    transform: translate3d(0, 0, 0);
    background-position: 0% 30%;
  }
  50% {
    filter: saturate(1.18) hue-rotate(18deg);
    transform: translate3d(0, -6px, 0);
    background-position: 60% 40%;
  }
  100% {
    filter: saturate(1.1) hue-rotate(36deg);
    transform: translate3d(0, 0, 0);
    background-position: 100% 70%;
  }
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 12% 18%, rgba(255, 79, 163, 0.18) 0%, rgba(255, 79, 163, 0) 48%),
    radial-gradient(circle at 86% 22%, rgba(255, 217, 102, 0.22) 0%, rgba(255, 217, 102, 0) 52%),
    radial-gradient(circle at 62% 78%, rgba(255, 134, 198, 0.18) 0%, rgba(255, 134, 198, 0) 55%);
  pointer-events: none;
  z-index: 0;
}

.particle-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  opacity: var(--particle-opacity);
}

.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 4px;
  width: 100%;
  transform-origin: left center;
  transform: scaleX(0);
  background: linear-gradient(90deg, var(--primary) 0%, #ffd166 45%, var(--primary-2) 100%);
  z-index: 70;
}

.page-transition {
  position: fixed;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  pointer-events: none;
  z-index: 60;
}

.page-transition span {
  background: #101010;
  transform: scaleX(0);
  transform-origin: left center;
}

.page-transition.active span {
  animation: slider-wipe calc(0.9s * var(--motion-multiplier)) cubic-bezier(0.23, 1, 0.32, 1) both;
}

.page-transition.active span:nth-child(2) {
  animation-delay: 0.06s;
}

.page-transition.active span:nth-child(3) {
  animation-delay: 0.12s;
}

.page-transition.active span:nth-child(4) {
  animation-delay: 0.18s;
}

@keyframes slider-wipe {
  0% {
    transform: scaleX(0);
    transform-origin: left center;
  }
  45% {
    transform: scaleX(1);
    transform-origin: left center;
  }
  55% {
    transform: scaleX(1);
    transform-origin: right center;
  }
  100% {
    transform: scaleX(0);
    transform-origin: right center;
  }
}

.hero {
  min-height: 88vh;
  padding: 24px;
  background: radial-gradient(circle, rgba(255, 79, 163, 0.08) 0%, transparent 70%);
  position: relative;
  overflow: hidden;
}

.hero-glow-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.hero-glow {
  position: absolute;
  border-radius: 999px;
  mix-blend-mode: screen;
  filter: blur(28px);
  opacity: calc(0.3 + 0.26 * var(--glow-strength));
  will-change: transform;
}

.glow-a {
  width: 360px;
  height: 360px;
  left: 14%;
  top: 20%;
  background: radial-gradient(circle, rgba(255, 79, 163, 0.22) 0%, rgba(255, 79, 163, 0) 70%);
  animation: halo-drift-a 9s ease-in-out infinite alternate;
}

.glow-b {
  width: 280px;
  height: 280px;
  right: 14%;
  bottom: 12%;
  background: radial-gradient(circle, rgba(255, 217, 102, 0.32) 0%, rgba(255, 217, 102, 0) 72%);
  animation: halo-drift-b 12s ease-in-out infinite alternate;
}

.hero-ambient {
  position: absolute;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 134, 198, 0.18) 0%, rgba(255, 134, 198, 0) 70%);
  top: 20%;
  left: 58%;
  filter: blur(8px);
  pointer-events: none;
  animation: ambient-float 8s ease-in-out infinite alternate;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180' viewBox='0 0 180 180'%3E%3Crect width='180' height='180' fill='none'/%3E%3Cg opacity='0.22'%3E%3Cpath d='M34 44c6 0 9 4 9 9s-3 9-9 9-9-4-9-9 3-9 9-9z' fill='%23ff4fa3'/%3E%3Cpath d='M34 48c-4 0-5 4-5 5 0 1 1 5 5 5 4 0 5-4 5-5 0-1-1-5-5-5z' fill='%23ffffff' opacity='0.55'/%3E%3C/g%3E%3Cg opacity='0.26'%3E%3Cpath d='M128 34c6 0 10 3 10 8 0 5-4 8-10 8-6 0-10-3-10-8 0-5 4-8 10-8z' fill='%23ffd166'/%3E%3C/g%3E%3Cg opacity='0.22'%3E%3Cpath d='M120 118l4 9 9 4-9 4-4 9-4-9-9-4 9-4 4-9z' fill='%23ff86c6'/%3E%3C/g%3E%3Cg opacity='0.22'%3E%3Cpath d='M58 128c0-6 8-10 12-4 4-6 12-2 12 4 0 10-12 14-12 14s-12-4-12-14z' fill='%23ff4fa3'/%3E%3C/g%3E%3C/svg%3E"),
    radial-gradient(circle at 20% 20%, rgba(255, 79, 163, 0.06) 0%, rgba(255, 79, 163, 0) 48%),
    radial-gradient(circle at 80% 28%, rgba(255, 217, 102, 0.08) 0%, rgba(255, 217, 102, 0) 52%);
  background-repeat: repeat, no-repeat, no-repeat;
  background-size: 220px 220px, 100% 100%, 100% 100%;
  background-position: 0 0, center, center;
  pointer-events: none;
  mix-blend-mode: multiply;
  opacity: 0.85;
}

.top-nav,
.hero-content,
.section {
  position: relative;
  z-index: 1;
}

.top-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 72px;
  gap: 16px;
  flex-wrap: wrap;
}

.nav-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.music-toggle {
  border: 1px solid var(--text);
  background: rgba(255, 255, 255, 0.78);
  padding: 8px 12px;
  cursor: pointer;
  font-family: "Inter", sans-serif;
  font-size: 12px;
  border-radius: 999px;
}

.music-toggle[data-state="off"] {
  opacity: 0.72;
}

.motion-toggle {
  border: 1px solid var(--text);
  background: rgba(255, 255, 255, 0.78);
  padding: 8px 12px;
  cursor: pointer;
  font-family: "Inter", sans-serif;
  font-size: 12px;
  border-radius: 999px;
}

.brand {
  font-family: "Inter", sans-serif;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.nav-links {
  display: flex;
  gap: 16px;
}

.nav-links a {
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.nav-links a:hover {
  border-bottom-color: var(--primary);
}

.hero-content {
  max-width: 880px;
  padding-top: 48px;
  transform-style: preserve-3d;
}

.kicker {
  margin: 0;
  color: var(--primary);
  font-family: "Inter", sans-serif;
  font-weight: 700;
  animation: fade-breathe var(--kicker-duration) ease-in-out infinite;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(16, 16, 16, 0.12);
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(4px);
  font-size: 13px;
}

.badge::before {
  content: "✿";
  color: var(--primary);
}

.title {
  margin: 8px 0 16px;
  font-family: "Inter", sans-serif;
  font-weight: 800;
  letter-spacing: -0.05em;
  font-size: clamp(38px, 8vw, 96px);
  transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
  transform: translateZ(0);
}

.title .char {
  display: inline-block;
  opacity: 0;
  transform: translateY(16px);
  animation: title-char-in 0.6s cubic-bezier(0.23, 1, 0.32, 1) forwards;
  animation-delay: calc(var(--char-index, 0) * 60ms);
}

.title:hover {
  letter-spacing: -0.02em;
}

.subtitle {
  max-width: 620px;
  color: var(--muted);
  opacity: 0.94;
}

.section {
  padding: 40px 24px 64px;
}

.reveal {
  opacity: 0;
  transform: translateY(32px);
  filter: blur(6px);
  transition:
    opacity 0.7s ease,
    transform 0.7s ease,
    filter 0.7s ease;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}

.section-head h2 {
  margin: 0;
  font-family: "Inter", sans-serif;
  font-size: clamp(24px, 4vw, 40px);
  letter-spacing: -0.05em;
}

.section-head p {
  margin: 0;
  color: var(--muted);
}

.grid-12 {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 16px;
}

.card {
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(3px);
  padding: 24px;
  transform-style: preserve-3d;
  transition:
    transform 0.35s cubic-bezier(0.23, 1, 0.32, 1),
    box-shadow 0.35s cubic-bezier(0.23, 1, 0.32, 1);
  border-radius: 18px;
}

.stats-grid .stat-card {
  grid-column: span 3;
}

.fun-grid {
  margin-top: 18px;
  align-items: stretch;
}

.fun-card {
  grid-column: span 6;
  position: relative;
}

.extra-grid {
  margin-top: 16px;
  align-items: stretch;
}

.tiny-tag {
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(16, 16, 16, 0.12);
  background: rgba(255, 255, 255, 0.72);
}

.counter-card,
.daily-card {
  grid-column: span 6;
}

.message-card {
  grid-column: span 12;
}

.counter-line {
  margin: 0;
  font-size: 18px;
  line-height: 1.8;
}

.counter-num {
  font-family: "Inter", sans-serif;
  font-weight: 800;
  color: var(--primary);
  letter-spacing: -0.02em;
}

.message-form {
  display: grid;
  gap: 12px;
}

.field {
  display: grid;
  gap: 8px;
}

.field span {
  color: var(--muted);
  font-size: 13px;
}

.field input,
.field textarea {
  width: 100%;
  border-radius: 14px;
  border: 1px solid rgba(16, 16, 16, 0.12);
  padding: 10px 12px;
  font-family: inherit;
  background: rgba(255, 255, 255, 0.78);
  outline: none;
}

.field input:focus,
.field textarea:focus {
  border-color: rgba(255, 79, 163, 0.55);
  box-shadow: 0 0 0 4px rgba(255, 79, 163, 0.12);
}

.form-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.hint {
  color: var(--muted);
  font-size: 12px;
}

.message-list {
  margin-top: 12px;
  display: grid;
  gap: 10px;
}

.message-item {
  border: 1px solid rgba(16, 16, 16, 0.1);
  background: rgba(255, 255, 255, 0.66);
  border-radius: 16px;
  padding: 12px 14px;
}

.message-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 6px;
}

.message-body {
  margin: 0;
  line-height: 1.7;
}

.admin-modal {
  width: min(920px, calc(100% - 48px));
  border: 1px solid var(--border);
  padding: 24px;
  border-radius: 18px;
}

.admin-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin: 10px 0 14px;
}

.admin-list {
  display: grid;
  gap: 10px;
  max-height: min(62vh, 560px);
  overflow: auto;
  padding-right: 6px;
}

.fun-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.fun-head h3 {
  margin: 0;
  font-family: "Inter", sans-serif;
  letter-spacing: -0.03em;
}

.quote-text {
  margin: 0;
  font-size: 18px;
  line-height: 1.8;
}

.quote-text.pop {
  animation: quote-pop 360ms cubic-bezier(0.23, 1, 0.32, 1) both;
}

.quote-meta {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 13px;
}

@keyframes quote-pop {
  0% {
    opacity: 0;
    transform: translateY(6px);
    filter: blur(1px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

.carousel {
  position: relative;
  border-radius: 16px;
  border: 1px solid rgba(16, 16, 16, 0.1);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.72);
}

.carousel-track {
  display: flex;
  width: 100%;
  transform: translateX(0);
  transition: transform 520ms cubic-bezier(0.23, 1, 0.32, 1);
  will-change: transform;
}

.carousel-slide {
  flex: 0 0 100%;
  min-height: 210px;
  display: grid;
  place-items: end start;
  padding: 18px;
  position: relative;
}

.carousel-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--bg-img);
  transform: scale(1.02);
}

.carousel-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(16,16,16,0.16) 100%);
}

.carousel-caption {
  position: relative;
  z-index: 1;
  color: #fff;
  font-family: "Inter", sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
  text-shadow: 0 10px 18px rgba(0,0,0,0.22);
}

.carousel-actions {
  display: flex;
  gap: 8px;
}

.carousel-dots {
  position: absolute;
  left: 14px;
  bottom: 12px;
  display: flex;
  gap: 8px;
  z-index: 2;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.6);
}

.carousel-dot.active {
  background: #fff;
}

.stat-label {
  margin: 0 0 8px;
  color: var(--muted);
}

.stat-value {
  margin: 0;
  font-size: clamp(30px, 5vw, 56px);
  font-family: "Inter", sans-serif;
  font-weight: 700;
}

.archive {
  position: relative;
}

.filter-toggle {
  border: 1px solid var(--text);
  background: transparent;
  padding: 8px 16px;
  cursor: pointer;
}

.filter-drawer {
  position: absolute;
  top: 104px;
  right: 24px;
  width: min(280px, calc(100% - 48px));
  background: #fff;
  border: 1px solid var(--border);
  padding: 16px;
  transform: translateX(120%);
  transition: transform 0.3s ease;
}

.filter-drawer.open {
  transform: translateX(0);
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  border: 1px solid var(--border);
  background: transparent;
  padding: 8px 12px;
  cursor: pointer;
}

.chip.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.project-grid .card {
  grid-column: span 4;
  opacity: 0;
  transform: translateY(24px) scale(0.98);
}

.project-grid .card.card-ready {
  animation: card-stagger-in 0.55s cubic-bezier(0.23, 1, 0.32, 1) forwards;
  animation-delay: calc(var(--stagger, 0) * 80ms);
}

.project-grid .card:hover {
  transform: translateY(-8px);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.08);
}

.project-tag {
  display: inline-block;
  margin-bottom: 8px;
  color: var(--primary);
  font-family: "Inter", sans-serif;
  font-weight: 700;
}

.lab-grid .lab-card {
  grid-column: span 4;
}

.lab {
  min-height: 220vh;
}

.lab-pin-wrap {
  position: relative;
  height: 180vh;
}

.lab-pin {
  position: sticky;
  top: 12vh;
  overflow: hidden;
}

.lab-track {
  display: flex;
  gap: 16px;
  width: max-content;
  transform: translateX(0);
  will-change: transform;
}

.lab-card.wide {
  width: min(76vw, 680px);
  min-height: 260px;
}

.contact-ball {
  position: fixed;
  right: 24px;
  bottom: 24px;
  border: none;
  width: 112px;
  height: 112px;
  border-radius: 999px;
  color: #fff;
  background: radial-gradient(circle at 30% 30%, #ffd166 0%, var(--primary-2) 38%, var(--primary) 100%);
  font-family: "Inter", sans-serif;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease;
  z-index: 20;
  box-shadow: 0 16px 36px rgba(255, 79, 163, 0.24);
}

.contact-panel {
  position: fixed;
  right: 24px;
  bottom: 152px;
  width: 248px;
  background: #fff;
  border: 1px solid var(--border);
  padding: 16px;
  z-index: 19;
  border-radius: 18px;
  transform-origin: right bottom;
  box-shadow: 0 18px 42px rgba(255, 79, 163, 0.14);
}

.hidden {
  display: none;
}

.contact-panel:not(.hidden) {
  animation: panel-pop 420ms cubic-bezier(0.23, 1, 0.32, 1) both;
}

.contact-panel h3 {
  margin-top: 0;
}

.contact-panel::before {
  content: "";
  position: absolute;
  right: 46px;
  bottom: -10px;
  width: 18px;
  height: 18px;
  background: #fff;
  border-left: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  transform: rotate(45deg);
}

.contact-ball:active {
  transform: scale(0.96);
}

/* 点击水波纹 */
.ripple {
  position: relative;
  overflow: hidden;
}

.ripple::after {
  content: "";
  position: absolute;
  left: var(--rx, 50%);
  top: var(--ry, 50%);
  width: 12px;
  height: 12px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0.0) 70%);
  transform: translate(-50%, -50%) scale(0);
  opacity: 0;
  pointer-events: none;
  border-radius: 999px;
}

.ripple.rippling::after {
  animation: ripple-pop 520ms ease-out both;
}

@keyframes ripple-pop {
  0% {
    transform: translate(-50%, -50%) scale(0);
    opacity: 0;
  }
  12% {
    opacity: 0.9;
  }
  100% {
    transform: translate(-50%, -50%) scale(18);
    opacity: 0;
  }
}

/* 鼠标尾迹五彩小星星 */
.trail {
  position: fixed;
  left: 0;
  top: 0;
  width: 14px;
  height: 14px;
  pointer-events: none;
  z-index: 75;
  transform: translate(-50%, -50%) scale(1);
  opacity: 0.95;
  will-change: transform, opacity;
  filter: drop-shadow(0 14px 18px rgba(255, 79, 163, 0.12));
  animation: trail-fade 720ms ease-out forwards;
}

.trail.star {
  width: 16px;
  height: 16px;
  background:
    radial-gradient(circle at 30% 28%, rgba(255, 255, 255, 0.92) 0 4px, transparent 5px),
    linear-gradient(135deg, rgba(255, 255, 255, 0.0) 0%, rgba(255, 255, 255, 0.22) 40%, rgba(255, 255, 255, 0.0) 100%),
    var(--trail-color, rgba(255, 79, 163, 0.82));
  clip-path: polygon(
    50% 2%,
    62% 34%,
    98% 38%,
    70% 58%,
    78% 94%,
    50% 74%,
    22% 94%,
    30% 58%,
    2% 38%,
    38% 34%
  );
  filter:
    drop-shadow(0 10px 16px rgba(255, 79, 163, 0.14))
    drop-shadow(0 0 12px rgba(255, 217, 102, 0.12));
}

@keyframes trail-fade {
  0% {
    opacity: 0.95;
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -70%) scale(0.2);
  }
}

@keyframes panel-pop {
  0% {
    opacity: 0;
    transform: translateY(10px) scale(0.96);
    filter: blur(2px);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

.qr-placeholder {
  width: 128px;
  height: 128px;
  border: 1px dashed var(--border);
  display: grid;
  place-items: center;
  margin: 8px 0 16px;
}

.resume-link {
  color: var(--primary);
}

/* --- Hello Kitty 风格贴纸（纯 CSS，不涉及版权素材） --- */
.kitty-stickers {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.kitty-float {
  position: absolute;
  animation: kitty-float 6.2s ease-in-out infinite;
  transform: translateZ(0);
  opacity: 0.95;
  filter: drop-shadow(0 18px 24px rgba(0, 0, 0, 0.08));
}

.sticker-float {
  position: absolute;
  animation: kitty-float 6.2s ease-in-out infinite;
  opacity: 0.92;
  filter: drop-shadow(0 16px 22px rgba(0, 0, 0, 0.08));
}

.sticker-star {
  width: 44px;
  height: 44px;
  background:
    radial-gradient(circle at 30% 28%, rgba(255, 255, 255, 0.92) 0 10px, transparent 11px),
    linear-gradient(135deg, rgba(255,255,255,0.0) 0%, rgba(255,255,255,0.22) 42%, rgba(255,255,255,0.0) 100%),
    var(--sticker-color, rgba(255, 217, 102, 0.9));
  clip-path: polygon(
    50% 2%,
    62% 34%,
    98% 38%,
    70% 58%,
    78% 94%,
    50% 74%,
    22% 94%,
    30% 58%,
    2% 38%,
    38% 34%
  );
  border-radius: 10px;
}

.star-1 {
  left: clamp(22px, 10vw, 120px);
  bottom: clamp(38px, 9vh, 130px);
  animation-duration: 7.6s;
  --sticker-color: rgba(255, 217, 102, 0.9);
  transform: rotate(-10deg);
}

.star-2 {
  left: clamp(180px, 22vw, 360px);
  top: clamp(18px, 7vh, 94px);
  animation-duration: 6.4s;
  --sticker-color: rgba(255, 134, 198, 0.9);
  transform: rotate(14deg);
}

.star-3 {
  right: clamp(90px, 18vw, 320px);
  bottom: clamp(28px, 10vh, 160px);
  animation-duration: 8.2s;
  --sticker-color: rgba(255, 79, 163, 0.86);
  transform: rotate(6deg) scale(0.92);
}

.sticker-tape {
  width: 110px;
  height: 44px;
  border-radius: 14px;
  background:
    repeating-linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.65) 0 10px,
      rgba(255, 255, 255, 0.4) 10px 18px
    ),
    linear-gradient(135deg, rgba(255, 217, 102, 0.55) 0%, rgba(255, 79, 163, 0.28) 100%);
  border: 1px solid rgba(16, 16, 16, 0.1);
  backdrop-filter: blur(4px);
  transform: rotate(-9deg);
}

.tape-1 {
  left: clamp(12px, 4vw, 48px);
  top: clamp(120px, 20vh, 200px);
  animation-duration: 9.2s;
}

.sticker-cloud {
  width: 86px;
  height: 54px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid rgba(16, 16, 16, 0.1);
  position: relative;
}

.sticker-cloud::before,
.sticker-cloud::after {
  content: "";
  position: absolute;
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid rgba(16, 16, 16, 0.1);
  border-radius: 999px;
}

.sticker-cloud::before {
  width: 42px;
  height: 42px;
  left: 10px;
  top: -14px;
}

.sticker-cloud::after {
  width: 34px;
  height: 34px;
  right: 14px;
  top: -10px;
}

.cloud-1 {
  right: clamp(16px, 6vw, 90px);
  top: clamp(150px, 24vh, 240px);
  animation-duration: 8.8s;
  opacity: 0.84;
}

.sticker-spark {
  width: 36px;
  height: 36px;
  border-radius: 14px;
  background:
    conic-gradient(from 0deg, rgba(255, 79, 163, 0.0), rgba(255, 79, 163, 0.26), rgba(255, 79, 163, 0.0)),
    radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.9) 0 10px, transparent 11px),
    radial-gradient(circle at 64% 72%, rgba(255, 217, 102, 0.22) 0%, transparent 62%);
  border: 1px solid rgba(16, 16, 16, 0.08);
  backdrop-filter: blur(4px);
}

.spark-1 {
  left: clamp(120px, 18vw, 260px);
  bottom: clamp(14px, 6vh, 90px);
  animation-duration: 5.6s;
}

.kitty-a {
  left: clamp(10px, 6vw, 48px);
  top: clamp(18px, 7vh, 86px);
  animation-duration: 6.8s;
}

.kitty-b {
  right: clamp(10px, 6vw, 52px);
  top: clamp(22px, 8vh, 98px);
  animation-duration: 7.4s;
}

.kitty-c {
  right: clamp(18px, 8vw, 78px);
  bottom: clamp(24px, 10vh, 110px);
  animation-duration: 5.8s;
}

.kitty-head {
  width: 86px;
  height: 64px;
  border-radius: 18px 18px 22px 22px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(16, 16, 16, 0.12);
  position: relative;
}

.kitty-head::before,
.kitty-head::after {
  content: "";
  position: absolute;
  top: -10px;
  width: 26px;
  height: 22px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(16, 16, 16, 0.12);
  border-bottom: none;
  border-radius: 10px 10px 4px 4px;
}

.kitty-head::before {
  left: 8px;
  transform: rotate(-14deg);
}

.kitty-head::after {
  right: 8px;
  transform: rotate(14deg);
}

.kitty-head .face {
  display: none;
}

.kitty-head .dot {
  display: none;
}

.kitty-head:where(*) {
  background-image:
    radial-gradient(circle at 32% 54%, rgba(0, 0, 0, 0.72) 0 3px, transparent 4px),
    radial-gradient(circle at 68% 54%, rgba(0, 0, 0, 0.72) 0 3px, transparent 4px),
    radial-gradient(circle at 50% 60%, rgba(255, 217, 102, 0.92) 0 3px, transparent 4px),
    linear-gradient(transparent 0 0);
  background-repeat: no-repeat;
}

.kitty-bow {
  width: 64px;
  height: 46px;
  position: relative;
}

.kitty-bow::before,
.kitty-bow::after {
  content: "";
  position: absolute;
  top: 8px;
  width: 30px;
  height: 26px;
  background: rgba(255, 79, 163, 0.9);
  border: 1px solid rgba(16, 16, 16, 0.14);
  border-radius: 10px 18px 18px 10px;
}

.kitty-bow::before {
  left: 0;
  transform: rotate(-10deg);
}

.kitty-bow::after {
  right: 0;
  transform: rotate(10deg) scaleX(-1);
}

.kitty-bow {
  background:
    radial-gradient(circle at 50% 55%, rgba(255, 217, 102, 0.95) 0 7px, transparent 8px);
}

.kitty-sparkle {
  width: 54px;
  height: 54px;
  border-radius: 16px;
  background:
    radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.9) 0 10px, transparent 11px),
    conic-gradient(from 0deg, rgba(255, 79, 163, 0.0), rgba(255, 79, 163, 0.28), rgba(255, 79, 163, 0.0)),
    radial-gradient(circle at 60% 70%, rgba(255, 217, 102, 0.22) 0%, transparent 62%);
  border: 1px solid rgba(16, 16, 16, 0.1);
  backdrop-filter: blur(4px);
}

@keyframes kitty-float {
  0% {
    transform: translate3d(0, 0, 0) rotate(-1deg);
  }
  50% {
    transform: translate3d(0, -12px, 0) rotate(1.5deg);
  }
  100% {
    transform: translate3d(0, 0, 0) rotate(-1deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  .kitty-float {
    animation: none;
  }
}

.detail-modal {
  width: min(860px, calc(100% - 48px));
  border: 1px solid var(--border);
  padding: 24px;
}

.close-modal {
  float: right;
  border: none;
  background: transparent;
  font-size: 24px;
  cursor: pointer;
}

@keyframes ambient-float {
  0% {
    transform: translate(0, 0) scale(1);
  }
  100% {
    transform: translate(-28px, 22px) scale(1.08);
  }
}

@keyframes halo-drift-a {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  100% {
    transform: translate3d(22px, -16px, 0) scale(1.08);
  }
}

@keyframes halo-drift-b {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  100% {
    transform: translate3d(-26px, 20px, 0) scale(1.1);
  }
}

@keyframes fade-breathe {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.64;
  }
}

@keyframes card-stagger-in {
  0% {
    opacity: 0;
    transform: translateY(24px) scale(0.98);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes title-char-in {
  0% {
    opacity: 0;
    transform: translateY(16px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1000px) {
  .stats-grid .stat-card,
  .project-grid .card,
  .lab-grid .lab-card {
    grid-column: span 6;
  }

  .fun-card {
    grid-column: span 12;
  }

  .counter-card,
  .daily-card {
    grid-column: span 12;
  }

  .lab-card.wide {
    width: min(88vw, 620px);
  }
}

@media (max-width: 680px) {
  .top-nav {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .stats-grid .stat-card,
  .project-grid .card,
  .lab-grid .lab-card {
    grid-column: span 12;
  }

  .lab {
    min-height: 180vh;
  }

  .lab-pin-wrap {
    height: 150vh;
  }

  .contact-ball {
    width: 92px;
    height: 92px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .trail {
    display: none;
  }
  .contact-panel:not(.hidden) {
    animation: none;
  }
  .ripple.rippling::after {
    animation: none;
  }
  .quote-text.pop {
    animation: none;
  }
  .carousel-track {
    transition: none;
  }
  body::before {
    animation: none;
  }
}
