/* ============ 基础 ============ */
* { margin: 0; padding: 0; box-sizing: border-box; }
:root {
  --bg: #fff8ef;
  --ink: #3a2e26;
  --amber: #f5a623;
  --amber-deep: #e8850c;
  --green: #7fae8f;
  --cream: #fffdf8;
  --shadow: 0 20px 60px rgba(120, 80, 20, .15);
  --radius: 24px;
}
html { scroll-behavior: smooth; }
body {
  font-family: 'Noto Sans SC', sans-serif;
  background: var(--bg);
  color: var(--ink);
  overflow-x: hidden;
  cursor: none;
}
a { cursor: none; }
img { display: block; max-width: 100%; }
h1, h2, .loader-text, .nav-logo { font-family: 'ZCOOL KuaiLe', 'Noto Sans SC', cursive; }

@media (hover: none) { body, a { cursor: auto; } #cursor, #cursor-dot { display: none !important; } }

/* ============ 加载动画 ============ */
#loader {
  position: fixed; inset: 0; z-index: 1000;
  background: linear-gradient(135deg, #fff3dc, #ffe6c2);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px;
  transition: opacity .6s ease, visibility .6s;
}
#loader.hide { opacity: 0; visibility: hidden; }
.loader-paw { font-size: 64px; animation: pawRun .7s ease-in-out infinite alternate; }
@keyframes pawRun {
  0% { transform: translateY(0) rotate(-8deg) scale(1); }
  100% { transform: translateY(-24px) rotate(8deg) scale(1.15); }
}
.loader-text { font-size: 22px; color: var(--amber-deep); letter-spacing: 2px; }
.loader-bar { width: 220px; height: 8px; border-radius: 99px; background: #ffe0b0; overflow: hidden; }
.loader-bar span { display: block; height: 100%; width: 40%; border-radius: 99px;
  background: linear-gradient(90deg, var(--amber), var(--amber-deep));
  animation: barSlide 1.1s ease-in-out infinite; }
@keyframes barSlide { 0% { transform: translateX(-120%); } 100% { transform: translateX(320%); } }

/* ============ 粒子背景 ============ */
#particles { position: fixed; inset: 0; z-index: 0; pointer-events: none; }

/* ============ 自定义光标 ============ */
#cursor {
  position: fixed; z-index: 999; width: 36px; height: 36px;
  border: 2px solid var(--amber); border-radius: 50%;
  pointer-events: none; transform: translate(-50%, -50%);
  transition: width .25s, height .25s, border-color .25s, background .25s;
}
#cursor.hovering { width: 56px; height: 56px; background: rgba(245,166,35,.15); border-color: var(--amber-deep); }
#cursor-dot {
  position: fixed; z-index: 999; width: 8px; height: 8px;
  background: var(--amber-deep); border-radius: 50%;
  pointer-events: none; transform: translate(-50%, -50%);
}
.cursor-paw {
  position: fixed; z-index: 998; pointer-events: none; font-size: 18px;
  animation: pawFade .9s ease-out forwards;
}
@keyframes pawFade {
  0% { opacity: .9; transform: translate(-50%, -50%) scale(.6) rotate(0deg); }
  100% { opacity: 0; transform: translate(-50%, -140%) scale(1.2) rotate(25deg); }
}

/* ============ 导航 ============ */
#nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 5vw;
  transition: background .4s, box-shadow .4s, padding .4s;
}
#nav.scrolled {
  background: rgba(255, 250, 240, .85);
  backdrop-filter: blur(14px);
  box-shadow: 0 6px 30px rgba(120, 80, 20, .1);
  padding: 12px 5vw;
}
.nav-logo { font-size: 24px; color: var(--amber-deep); }
.nav-links { display: flex; gap: 28px; }
.nav-links a {
  color: var(--ink); text-decoration: none; font-weight: 500; font-size: 15px;
  position: relative; transition: color .3s;
}
.nav-links a::after {
  content: ''; position: absolute; left: 0; bottom: -6px; width: 0; height: 3px;
  background: var(--amber); border-radius: 99px; transition: width .3s;
}
.nav-links a:hover { color: var(--amber-deep); }
.nav-links a:hover::after { width: 100%; }
/* 汉堡按钮（桌面隐藏） */
.nav-toggle {
  display: none; flex-direction: column; justify-content: center; gap: 5px;
  width: 44px; height: 44px; padding: 10px; border: none; border-radius: 12px;
  background: rgba(255,255,255,.6); backdrop-filter: blur(8px);
}
.nav-toggle span {
  display: block; height: 3px; border-radius: 99px; background: var(--amber-deep);
  transition: transform .3s, opacity .3s, width .3s;
}
.nav-toggle span:nth-child(2) { width: 70%; margin-left: auto; }
.nav-toggle.active span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ============ 英雄区 ============ */
#hero {
  position: relative; z-index: 1; min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  text-align: center; overflow: hidden;
}
.hero-blob {
  position: absolute; border-radius: 50%; filter: blur(70px); opacity: .55;
  animation: blobFloat 10s ease-in-out infinite alternate;
}
.blob-1 { width: 480px; height: 480px; background: #ffd8a1; top: -120px; left: -100px; }
.blob-2 { width: 420px; height: 420px; background: #cfe8d5; bottom: -140px; right: -80px; animation-delay: -4s; }
.blob-3 { width: 300px; height: 300px; background: #ffe9c9; top: 40%; left: 60%; animation-delay: -7s; }
@keyframes blobFloat {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(60px, -50px) scale(1.15); }
}
.hero-content { position: relative; z-index: 2; padding: 0 20px; }
.hero-tag {
  display: inline-block; padding: 8px 22px; border-radius: 99px;
  background: rgba(255,255,255,.7); backdrop-filter: blur(8px);
  border: 1px solid #ffdca8; color: var(--amber-deep); font-weight: 600;
  margin-bottom: 26px; animation: fadeUp .8s .3s both;
}
.hero-title { font-size: clamp(44px, 8.5vw, 96px); line-height: 1.15; color: var(--ink); }
.hero-title .char {
  display: inline-block; opacity: 0; transform: translateY(60px) rotate(10deg);
  animation: charIn .7s cubic-bezier(.2,.9,.3,1.4) forwards;
}
.hero-title .char:nth-child(1) { animation-delay: .45s; }
.hero-title .char:nth-child(2) { animation-delay: .55s; }
.hero-title .char:nth-child(3) { animation-delay: .65s; }
.hero-title .char:nth-child(4) { animation-delay: .75s; }
.hero-title .char:nth-child(5) { animation-delay: .85s; }
.hero-title .char:nth-child(6) { animation-delay: 1.05s; }
.hero-title .char:nth-child(7) { animation-delay: 1.15s; }
.hero-title .char:nth-child(8) { animation-delay: 1.25s; }
.hero-title .char:nth-child(9) { animation-delay: 1.35s; }
.hero-title .char:nth-child(10) { animation-delay: 1.45s; }
@keyframes charIn { to { opacity: 1; transform: translateY(0) rotate(0); } }
.gradient-text {
  background: linear-gradient(90deg, var(--amber), var(--amber-deep), #d96a1e);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
#typewriter {
  margin: 24px auto 0; min-height: 1.8em; font-size: clamp(16px, 2.4vw, 22px);
  color: #7a6a58; max-width: 640px;
}
#typewriter .caret { display: inline-block; width: 2px; height: 1.1em; background: var(--amber-deep);
  vertical-align: text-bottom; margin-left: 3px; animation: blink .8s step-end infinite; }
@keyframes blink { 50% { opacity: 0; } }
.hero-btns { margin-top: 38px; display: flex; gap: 18px; justify-content: center; flex-wrap: wrap; animation: fadeUp .8s 1.6s both; }
.btn {
  padding: 15px 34px; border-radius: 99px; text-decoration: none; font-weight: 700; font-size: 16px;
  transition: transform .3s, box-shadow .3s;
}
.btn-primary {
  background: linear-gradient(135deg, var(--amber), var(--amber-deep));
  color: #fff; box-shadow: 0 12px 30px rgba(232,133,12,.35);
}
.btn-primary:hover { transform: translateY(-4px) scale(1.03); box-shadow: 0 18px 40px rgba(232,133,12,.45); }
.btn-ghost {
  background: rgba(255,255,255,.7); color: var(--ink); border: 2px solid #ffdca8;
  backdrop-filter: blur(8px);
}
.btn-ghost:hover { transform: translateY(-4px); border-color: var(--amber); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }

.scroll-hint {
  position: absolute; bottom: 30px; left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  color: #a08c74; font-size: 13px; animation: fadeUp 1s 2s both;
}
.mouse { width: 24px; height: 38px; border: 2px solid #c9b49a; border-radius: 14px; position: relative; }
.wheel { position: absolute; left: 50%; top: 7px; width: 4px; height: 8px; margin-left: -2px;
  background: var(--amber-deep); border-radius: 99px; animation: wheelMove 1.4s ease infinite; }
@keyframes wheelMove { 0% { opacity: 1; top: 7px; } 100% { opacity: 0; top: 20px; } }

.floating-paws { position: absolute; inset: 0; pointer-events: none; z-index: 1; }
.fpaw { position: absolute; top: -50px; opacity: 0; animation: pawFall 9s linear infinite; animation-delay: var(--d); }
@keyframes pawFall {
  0% { opacity: 0; transform: translateY(0) rotate(0deg); }
  10% { opacity: .7; }
  90% { opacity: .5; }
  100% { opacity: 0; transform: translateY(110vh) rotate(340deg); }
}

/* ============ 跑马灯 ============ */
.marquee-band {
  position: relative; z-index: 2;
  background: linear-gradient(90deg, var(--amber), var(--amber-deep));
  transform: rotate(-1.5deg) scale(1.02);
  padding: 14px 0; overflow: hidden; box-shadow: var(--shadow);
}
.marquee-track { display: flex; gap: 48px; width: max-content; animation: marquee 22s linear infinite; }
.marquee-track span {
  color: #fff; font-family: 'ZCOOL KuaiLe', cursive; font-size: 22px; white-space: nowrap;
  text-shadow: 0 2px 8px rgba(0,0,0,.15);
}
@keyframes marquee { to { transform: translateX(-50%); } }
.marquee-band:hover .marquee-track { animation-play-state: paused; }

/* ============ 通用 section ============ */
.section { position: relative; z-index: 1; max-width: 1180px; margin: 0 auto; padding: 110px 24px 60px; }
.section-title {
  text-align: center; font-size: clamp(34px, 5vw, 52px); color: var(--ink);
  margin-bottom: 60px; position: relative;
}
.section-title small {
  display: block; font-family: 'Noto Sans SC', sans-serif; font-weight: 400;
  font-size: 17px; color: #a08c74; margin-top: 10px; letter-spacing: 4px;
}
.section-title::after {
  content: '🐾'; display: block; font-size: 22px; margin-top: 12px;
}

/* ============ 档案区 ============ */
.about-grid { display: grid; grid-template-columns: 340px 1fr; gap: 48px; align-items: start; }
@media (max-width: 860px) { .about-grid { grid-template-columns: 1fr; } }
.about-card {
  background: var(--cream); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 28px; text-align: center; border: 1px solid #ffedd0;
  transition: transform .4s;
}
.about-card:hover { transform: translateY(-8px) rotate(-1deg); }
.profile-photo {
  border-radius: 20px; overflow: hidden; aspect-ratio: 3/4; margin-bottom: 18px;
  box-shadow: 0 10px 26px rgba(120,80,20,.18);
}
.profile-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s; }
.about-card:hover .profile-photo img { transform: scale(1.08); }
.profile-name { font-size: 26px; font-weight: 900; }
.gender { color: #ff7fa5; }
.profile-breed { color: #a08c74; margin-top: 6px; font-size: 14px; }
.info-list { list-style: none; display: flex; flex-direction: column; gap: 14px; margin-bottom: 36px; }
.info-list li {
  display: flex; gap: 18px; padding: 16px 22px;
  background: var(--cream); border-radius: 16px; border: 1px solid #ffedd0;
  transition: transform .3s, box-shadow .3s;
}
.info-list li:hover { transform: translateX(8px); box-shadow: var(--shadow); }
.info-list b { color: var(--amber-deep); min-width: 56px; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.stat {
  background: linear-gradient(150deg, #fff3dc, #ffe3ba);
  border-radius: 18px; padding: 22px 12px; text-align: center;
  transition: transform .3s;
}
.stat:hover { transform: translateY(-6px); }
.stat-num { font-size: clamp(26px, 4vw, 40px); font-weight: 900; color: var(--amber-deep); }
.stat-label { font-size: 13px; color: #8a7660; margin-top: 4px; }

/* ============ 写真集 ============ */
.gallery { columns: 3 260px; column-gap: 20px; }
.g-item {
  break-inside: avoid; margin-bottom: 20px; position: relative;
  border-radius: var(--radius); overflow: hidden; cursor: none;
  box-shadow: 0 10px 30px rgba(120,80,20,.14);
}
.g-item img { width: 100%; transition: transform .6s cubic-bezier(.2,.7,.3,1); }
.g-item::after {
  content: attr(data-cap);
  position: absolute; inset: 0; display: flex; align-items: flex-end; padding: 22px;
  background: linear-gradient(transparent 40%, rgba(40,25,10,.75));
  color: #fff; font-weight: 600; font-size: 17px;
  opacity: 0; transition: opacity .4s;
}
.g-item:hover img { transform: scale(1.08) rotate(.5deg); }
.g-item:hover::after { opacity: 1; }
.g-item figcaption {
  position: absolute; top: 14px; left: 14px; z-index: 2;
  background: rgba(255,255,255,.85); backdrop-filter: blur(6px);
  padding: 6px 14px; border-radius: 99px; font-size: 13px; font-weight: 700;
  color: var(--amber-deep); transform: translateY(-6px); opacity: 0; transition: .4s;
}
.g-item:hover figcaption { transform: translateY(0); opacity: 1; }

/* ============ 表情包区 ============ */
.memes-section {
  background: linear-gradient(160deg, #3a2e26, #5a4330);
  border-radius: 48px; color: #fff;
}
.memes-section .section-title { color: #fff; }
.memes-section .section-title small { color: #cdb79c; }
.meme-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 26px; }
.meme-card {
  position: relative; border-radius: 20px; overflow: hidden;
  transform: rotate(var(--r)); transition: transform .4s cubic-bezier(.2,.9,.3,1.4), box-shadow .4s;
  box-shadow: 0 16px 40px rgba(0,0,0,.35);
}
.meme-card:hover { transform: rotate(0) scale(1.06); z-index: 2; box-shadow: 0 24px 60px rgba(0,0,0,.5); }
.meme-card img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.meme-label {
  position: absolute; bottom: 12px; left: 12px; right: 12px;
  background: rgba(0,0,0,.55); backdrop-filter: blur(6px);
  border-radius: 12px; padding: 8px; text-align: center; font-weight: 700; font-size: 14px;
}
.meme-tip { text-align: center; margin-top: 40px; color: #cdb79c; }

/* ============ 页脚 ============ */
#footer { position: relative; z-index: 1; text-align: center; padding: 80px 20px 50px; color: #8a7660; }
.footer-paws { font-size: 26px; letter-spacing: 14px; margin-bottom: 16px; animation: pawBounce 2s ease infinite; }
@keyframes pawBounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
#footer b { color: var(--amber-deep); }
.footer-sub { font-size: 13px; margin-top: 10px; opacity: .7; }

/* ============ 灯箱 ============ */
#lightbox {
  position: fixed; inset: 0; z-index: 500; background: rgba(20,12,4,.92);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden; transition: .35s;
}
#lightbox.open { opacity: 1; visibility: visible; }
#lightbox figure { max-width: 86vw; max-height: 84vh; text-align: center; }
#lightbox img {
  max-width: 86vw; max-height: 76vh; object-fit: contain; border-radius: 14px;
  transform: scale(.9); transition: transform .35s;
  box-shadow: 0 30px 90px rgba(0,0,0,.6);
}
#lightbox.open img { transform: scale(1); }
#lightbox figcaption { color: #ffe3ba; margin-top: 18px; font-size: 18px; font-weight: 600; }
#lightbox button {
  position: fixed; z-index: 501; border: none; cursor: none;
  width: 52px; height: 52px; border-radius: 50%; font-size: 24px;
  background: rgba(255,255,255,.12); color: #fff; transition: background .3s, transform .3s;
}
#lightbox button:hover { background: rgba(255,255,255,.28); transform: scale(1.1); }
.lb-close { top: 26px; right: 30px; }
.lb-prev { left: 26px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 26px; top: 50%; transform: translateY(-50%); }
@media (max-width: 640px) { .lb-prev { left: 10px; } .lb-next { right: 10px; } }

/* ============ 爱心特效 ============ */
#fx-layer { position: fixed; inset: 0; z-index: 400; pointer-events: none; }
.click-heart {
  position: fixed; font-size: 22px; pointer-events: none;
  animation: heartFly 1s ease-out forwards;
}
@keyframes heartFly {
  0% { opacity: 1; transform: translate(-50%, -50%) scale(.5); }
  100% { opacity: 0; transform: translate(calc(-50% + var(--dx)), calc(-50% - 90px)) scale(1.4) rotate(var(--rot)); }
}

/* ============ 滚动显现 ============ */
.reveal { opacity: 0; transform: translateY(46px); transition: opacity .8s ease, transform .8s cubic-bezier(.2,.7,.3,1); }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ============ 响应式：平板 ============ */
@media (max-width: 1024px) {
  .gallery { columns: 2; }
  .section { padding: 90px 20px 50px; }
}

/* ============ 响应式：手机 ============ */
@media (max-width: 860px) {
  .about-grid { grid-template-columns: 1fr; gap: 32px; }
  .about-card { max-width: 420px; margin: 0 auto; }
  .profile-photo { aspect-ratio: 4/3; }
}

@media (max-width: 768px) {
  #nav { padding: 12px 5vw; }
  .nav-toggle { display: flex; }
  .nav-links {
    position: fixed; top: 68px; right: 5vw;
    flex-direction: column; gap: 0; min-width: 160px;
    background: rgba(255, 250, 240, .96); backdrop-filter: blur(16px);
    border-radius: 18px; box-shadow: var(--shadow);
    border: 1px solid #ffedd0; overflow: hidden;
    opacity: 0; visibility: hidden; transform: translateY(-12px) scale(.96);
    transition: .3s;
  }
  .nav-links.open { opacity: 1; visibility: visible; transform: translateY(0) scale(1); }
  .nav-links a { padding: 15px 22px; font-size: 16px; border-bottom: 1px solid #ffedd0; }
  .nav-links a:last-child { border-bottom: none; }
  .nav-links a::after { display: none; }
  .nav-links a:active { background: #fff3dc; }

  .hero-blob { filter: blur(50px); }
  .blob-1 { width: 320px; height: 320px; }
  .blob-2 { width: 280px; height: 280px; }
  .blob-3 { width: 220px; height: 220px; }
  .hero-tag { font-size: 14px; padding: 7px 16px; }
  #typewriter { font-size: 15px; padding: 0 10px; }
  .hero-btns { gap: 12px; }
  .btn { padding: 13px 24px; font-size: 15px; }

  .section { padding: 70px 18px 40px; }
  .section-title { margin-bottom: 40px; }
  .section-title small { font-size: 14px; letter-spacing: 2px; }

  .info-list li { flex-direction: column; gap: 4px; padding: 14px 18px; }
  .info-list b { font-size: 13px; }
  .stats { gap: 10px; }
  .stat { padding: 16px 8px; }

  .gallery { columns: 2; column-gap: 14px; }
  .g-item { margin-bottom: 14px; border-radius: 18px; }

  .memes-section { border-radius: 30px; max-width: calc(100% - 24px); margin-left: auto; margin-right: auto; }
  .meme-row { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .meme-label { font-size: 12px; padding: 6px; }

  .marquee-track span { font-size: 17px; }
  .marquee-track { gap: 30px; }

  #lightbox button { width: 44px; height: 44px; font-size: 20px; }
  .lb-close { top: 14px; right: 14px; }
  #lightbox figcaption { font-size: 15px; margin-top: 12px; }

  #footer { padding: 60px 18px 40px; }
}

/* ============ 响应式：小屏手机 ============ */
@media (max-width: 480px) {
  .gallery { columns: 1; }
  .hero-btns { flex-direction: column; align-items: stretch; padding: 0 12px; }
  .btn { text-align: center; }
  .stats { grid-template-columns: 1fr; }
  .stat { display: flex; align-items: baseline; justify-content: center; gap: 10px; padding: 14px; }
  .stat-num { font-size: 30px; }
  .meme-row { grid-template-columns: 1fr; }
  .scroll-hint { display: none; }
  .section-title { font-size: 30px; }
}

/* ============ 触控设备：无 hover，常驻显示标签 ============ */
@media (hover: none) {
  .g-item figcaption { opacity: 1; transform: translateY(0); font-size: 12px; padding: 5px 11px; }
  .g-item::after { opacity: 0; }
  .g-item:active::after { opacity: 1; }
  .meme-card { transform: rotate(0); }
  .btn-primary:hover, .btn-ghost:hover, .stat:hover, .info-list li:hover { transform: none; }
  #lightbox button:hover { transform: translateY(-50%); }
}

/* ============ 无障碍：降低动效 ============ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
  .reveal { opacity: 1; transform: none; }
  .hero-title .char { opacity: 1; transform: none; }
}
