/* ===== 主题变量 ===== */
:root {
  --color-primary: #ff6b9e;
  --color-primary-light: #ff8fab;
  --color-primary-dark: #e85a8d;
  --color-secondary: #ffd6e0;
  --color-secondary-light: #ffe4ec;
  --color-bg: #fff5f8;
  --color-bg-white: #ffffff;
  --color-text: #553344;
  --color-text-light: #886677;
  --color-text-lighter: #aa8899;
  --color-border: #ffe4ec;

  --gradient-banner: linear-gradient(135deg, #ffd6e0 0%, #fff5f8 40%, #ffe4ec 100%);
  --gradient-button: linear-gradient(135deg, #ff6b9e 0%, #ff8fab 100%);
  --gradient-button-hover: linear-gradient(135deg, #ff8fab 0%, #ffb3c6 100%);
  --gradient-card: linear-gradient(145deg, #ffffff 0%, #fff5f8 100%);
  --gradient-avatar: linear-gradient(135deg, #ff6b9e, #ffd6e0, #ff8fab);

  --radius-sm: 12px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --radius-full: 999px;

  --shadow-sm: 0 2px 8px rgba(255, 107, 158, 0.1);
  --shadow-md: 0 4px 20px rgba(255, 107, 158, 0.12);
  --shadow-lg: 0 8px 32px rgba(255, 107, 158, 0.18);
  --shadow-hover: 0 12px 40px rgba(255, 107, 158, 0.25);

  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;
  --transition-bounce: 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ===== 重置样式 ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei",
    "Helvetica Neue", Helvetica, Arial, sans-serif;
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.7;
  font-size: 16px;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  display: block;
}

button {
  border: none;
  background: none;
  cursor: pointer;
  font-family: inherit;
  color: inherit;
}

input,
textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

/* ===== 加载动画 ===== */
.loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--gradient-banner);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

.loading-overlay.hidden {
  opacity: 0;
  visibility: hidden;
}

.loading-content {
  text-align: center;
}

.loading-kitty {
  font-size: 64px;
  animation: kittyBounce 1s ease-in-out infinite;
}

@keyframes kittyBounce {
  0%, 100% {
    transform: translateY(0) scale(1);
  }
  50% {
    transform: translateY(-20px) scale(1.1);
  }
}

.loading-text {
  margin-top: 20px;
  font-size: 18px;
  color: var(--color-primary);
  font-weight: 600;
}

.loading-bar {
  width: 200px;
  height: 8px;
  background: var(--color-secondary-light);
  border-radius: var(--radius-full);
  margin-top: 16px;
  overflow: hidden;
}

.loading-progress {
  height: 100%;
  width: 0%;
  background: var(--gradient-button);
  border-radius: var(--radius-full);
  animation: loadingProgress 2s ease forwards;
}

@keyframes loadingProgress {
  0% { width: 0%; }
  100% { width: 100%; }
}

/* ===== 导航栏 ===== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 245, 248, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--color-border);
  transition: var(--transition-normal);
}

.navbar.scrolled {
  box-shadow: var(--shadow-sm);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 20px;
  font-weight: 700;
  color: var(--color-primary);
}

.logo-icon {
  font-size: 28px;
  animation: logoSpin 3s ease-in-out infinite;
}

@keyframes logoSpin {
  0%, 100% { transform: rotate(-5deg); }
  50% { transform: rotate(5deg); }
}

.nav-menu {
  display: flex;
  gap: 8px;
}

.nav-link {
  padding: 8px 20px;
  border-radius: var(--radius-full);
  font-size: 15px;
  font-weight: 500;
  color: var(--color-text-light);
  transition: var(--transition-normal);
  position: relative;
}

.nav-link:hover {
  color: var(--color-primary);
  background: var(--color-secondary-light);
}

.nav-link.active {
  color: var(--color-primary);
  background: var(--color-secondary);
  font-weight: 600;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  width: 24px;
  height: 3px;
  background: var(--color-primary);
  border-radius: 3px;
  transition: var(--transition-normal);
}

.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* ===== 主内容区 ===== */
.main-content {
  padding-top: 70px;
}

.page {
  display: block;
  width: 100%;
}

.section-animate {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.section-animate.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== 首页 Hero ===== */
.hero-banner {
  position: relative;
  min-height: 500px;
  background: var(--gradient-banner);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 80px 24px 100px;
}

.hero-decor {
  position: absolute;
  font-size: 40px;
  opacity: 0.6;
  animation: float 4s ease-in-out infinite;
}

.hero-decor-1 {
  top: 60px;
  left: 10%;
  animation-delay: 0s;
}

.hero-decor-2 {
  top: 100px;
  right: 15%;
  animation-delay: 0.5s;
  font-size: 32px;
}

.hero-decor-3 {
  bottom: 140px;
  left: 15%;
  animation-delay: 1s;
  font-size: 36px;
}

.hero-decor-4 {
  bottom: 120px;
  right: 10%;
  animation-delay: 1.5s;
}

.hero-decor-5 {
  top: 180px;
  left: 25%;
  animation-delay: 2s;
  font-size: 28px;
}

@keyframes float {
  0%, 100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-15px) rotate(5deg);
  }
}

.hero-content {
  text-align: center;
  position: relative;
  z-index: 2;
}

.hero-title {
  font-size: 48px;
  font-weight: 800;
  color: var(--color-primary);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.title-icon {
  animation: titleIconBounce 2s ease-in-out infinite;
}

.title-icon:last-child {
  animation-delay: 1s;
}

@keyframes titleIconBounce {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-8px) rotate(10deg); }
}

.hero-subtitle {
  font-size: 22px;
  color: var(--color-text-light);
  margin-bottom: 12px;
  font-weight: 500;
}

.hero-slogan {
  font-size: 16px;
  color: var(--color-text-lighter);
}

.hero-wave {
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 60px;
  background: var(--color-bg);
  clip-path: ellipse(60% 100% at 50% 100%);
}

/* ===== 统计数据 ===== */
.stats-section {
  max-width: 1000px;
  margin: -40px auto 0;
  padding: 0 24px;
  position: relative;
  z-index: 10;
}

.stats-card {
  background: var(--color-bg-white);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  padding: 40px 32px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.stat-item {
  text-align: center;
}

.stat-icon {
  font-size: 36px;
  margin-bottom: 8px;
}

.stat-number {
  font-size: 36px;
  font-weight: 800;
  color: var(--color-primary);
  line-height: 1.2;
}

.stat-label {
  font-size: 14px;
  color: var(--color-text-light);
  margin-top: 4px;
}

/* ===== 通用区块 ===== */
.section-header {
  text-align: center;
  margin-bottom: 40px;
}

.section-title {
  font-size: 28px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 12px;
}

.title-underline {
  width: 60px;
  height: 4px;
  background: var(--gradient-button);
  border-radius: var(--radius-full);
  margin: 0 auto;
}

.welcome-section,
.quick-nav-section {
  max-width: 1000px;
  margin: 80px auto;
  padding: 0 24px;
}

/* ===== 欢迎卡片 ===== */
.welcome-card {
  background: var(--gradient-card);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  padding: 48px;
  display: flex;
  align-items: flex-start;
  gap: 32px;
  border: 1px solid var(--color-border);
}

.welcome-avatar {
  flex-shrink: 0;
  width: 100px;
  height: 100px;
  background: var(--gradient-button);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  box-shadow: var(--shadow-md);
}

.welcome-text p {
  margin-bottom: 12px;
  color: var(--color-text);
  line-height: 1.9;
}

.welcome-sign {
  margin-top: 20px !important;
  text-align: right;
  color: var(--color-primary) !important;
  font-weight: 600;
  font-style: italic;
}

/* ===== 快速导航 ===== */
.quick-nav-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}

.quick-nav-card {
  background: var(--color-bg-white);
  border-radius: var(--radius-lg);
  padding: 28px 16px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition-bounce);
  box-shadow: var(--shadow-sm);
  border: 2px solid transparent;
}

.quick-nav-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: var(--shadow-hover);
  border-color: var(--color-secondary);
}

.quick-nav-icon {
  font-size: 40px;
  margin-bottom: 12px;
}

.quick-nav-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 4px;
}

.quick-nav-desc {
  font-size: 13px;
  color: var(--color-text-lighter);
}

/* ===== 页面头部 ===== */
.page-header {
  text-align: center;
  padding: 60px 24px 40px;
  background: var(--gradient-banner);
  position: relative;
  overflow: hidden;
}

.page-header::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40px;
  background: var(--color-bg);
  clip-path: ellipse(60% 100% at 50% 100%);
}

.page-title {
  font-size: 36px;
  font-weight: 800;
  color: var(--color-primary);
  margin-bottom: 8px;
  position: relative;
  z-index: 1;
}

.page-subtitle {
  font-size: 16px;
  color: var(--color-text-light);
  position: relative;
  z-index: 1;
}

/* ===== 相册 ===== */
.gallery-grid {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 24px 80px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.gallery-item {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 1;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-bounce);
}

.gallery-item:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: var(--shadow-hover);
}

.gallery-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition-slow);
}

.gallery-item:hover .gallery-img {
  transform: scale(1.1);
}

.gallery-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 30px 16px 16px;
  background: linear-gradient(to top, rgba(255, 107, 158, 0.8), transparent);
  opacity: 0;
  transition: var(--transition-normal);
}

.gallery-item:hover .gallery-overlay {
  opacity: 1;
}

.gallery-caption {
  color: white;
  font-size: 14px;
  font-weight: 600;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

/* ===== 心情日志 ===== */
.diary-timeline {
  max-width: 800px;
  margin: 0 auto;
  padding: 40px 24px 80px;
  position: relative;
}

.diary-timeline::before {
  content: '';
  position: absolute;
  left: 100px;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--color-secondary);
  border-radius: var(--radius-full);
}

.timeline-item {
  display: flex;
  gap: 30px;
  margin-bottom: 40px;
  position: relative;
}

.timeline-item:last-child {
  margin-bottom: 0;
}

.timeline-dot {
  position: absolute;
  left: 94px;
  top: 20px;
  width: 15px;
  height: 15px;
  background: var(--color-primary);
  border-radius: 50%;
  box-shadow: 0 0 0 4px var(--color-secondary-light);
  z-index: 1;
}

.timeline-date {
  flex-shrink: 0;
  width: 70px;
  text-align: right;
  padding-top: 12px;
}

.date-day {
  display: block;
  font-size: 28px;
  font-weight: 800;
  color: var(--color-primary);
  line-height: 1;
}

.date-month {
  display: block;
  font-size: 12px;
  color: var(--color-text-lighter);
  margin-top: 4px;
}

.timeline-card {
  flex: 1;
  background: var(--color-bg-white);
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
  transition: var(--transition-normal);
}

.timeline-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateX(4px);
}

.diary-mood {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 12px;
}

.diary-content p {
  margin-bottom: 8px;
  color: var(--color-text);
  line-height: 1.9;
  font-size: 15px;
}

.diary-tags {
  margin-top: 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  display: inline-block;
  padding: 4px 12px;
  background: var(--color-secondary-light);
  color: var(--color-primary);
  font-size: 12px;
  border-radius: var(--radius-full);
  font-weight: 500;
}

/* ===== 音乐小屋 ===== */
.music-player-card {
  max-width: 600px;
  margin: 40px auto 0;
  padding: 0 24px;
}

.music-player-card > div {
  background: var(--gradient-card);
  border-radius: var(--radius-xl);
  padding: 40px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  gap: 32px;
}

.music-cover {
  flex-shrink: 0;
  width: 160px;
  height: 160px;
  position: relative;
}

.cover-disc {
  width: 100%;
  height: 100%;
  background: var(--gradient-button);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 64px;
  box-shadow: var(--shadow-lg);
  animation: discSpin 8s linear infinite;
  animation-play-state: paused;
}

.cover-disc.playing {
  animation-play-state: running;
}

@keyframes discSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.cover-glow {
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  border-radius: 50%;
  background: var(--color-secondary);
  opacity: 0.4;
  filter: blur(20px);
  z-index: -1;
}

.music-info {
  flex: 1;
}

.music-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 4px;
}

.music-artist {
  font-size: 14px;
  color: var(--color-text-light);
  margin-bottom: 20px;
}

.music-progress {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.progress-bar {
  flex: 1;
  height: 6px;
  background: var(--color-secondary-light);
  border-radius: var(--radius-full);
  cursor: pointer;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  width: 0%;
  background: var(--gradient-button);
  border-radius: var(--radius-full);
  transition: width 0.1s linear;
}

.time-current,
.time-total {
  font-size: 12px;
  color: var(--color-text-lighter);
  min-width: 36px;
}

.music-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
}

.control-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--color-secondary-light);
  color: var(--color-primary);
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-normal);
}

.control-btn:hover {
  background: var(--color-secondary);
  transform: scale(1.1);
}

.control-btn.play-btn {
  width: 56px;
  height: 56px;
  background: var(--gradient-button);
  color: white;
  font-size: 20px;
  box-shadow: var(--shadow-md);
}

.control-btn.play-btn:hover {
  transform: scale(1.15);
  box-shadow: var(--shadow-lg);
}

/* 歌单 */
.playlist-section {
  max-width: 600px;
  margin: 48px auto 0;
  padding: 0 24px;
}

.playlist-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 16px;
  padding-left: 8px;
}

.playlist {
  background: var(--color-bg-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
  overflow: hidden;
}

.playlist-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  cursor: pointer;
  transition: var(--transition-fast);
  border-bottom: 1px solid var(--color-border);
}

.playlist-item:last-child {
  border-bottom: none;
}

.playlist-item:hover {
  background: var(--color-secondary-light);
}

.playlist-item.active {
  background: var(--color-secondary-light);
}

.playlist-item.active .playlist-name {
  color: var(--color-primary);
  font-weight: 600;
}

.playlist-index {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text-lighter);
  min-width: 28px;
}

.playlist-item.active .playlist-index {
  color: var(--color-primary);
}

.playlist-info {
  flex: 1;
}

.playlist-name {
  font-size: 15px;
  color: var(--color-text);
  font-weight: 500;
}

.playlist-artist {
  font-size: 12px;
  color: var(--color-text-lighter);
  margin-top: 2px;
}

.playlist-duration {
  font-size: 13px;
  color: var(--color-text-lighter);
}

.music-quote {
  max-width: 600px;
  margin: 48px auto 80px;
  padding: 0 24px;
  text-align: center;
}

.music-quote p {
  color: var(--color-text-light);
  font-size: 15px;
  font-style: italic;
}

/* ===== 关于我 ===== */
.about-card {
  max-width: 600px;
  margin: 40px auto 80px;
  padding: 0 24px;
}

.about-card > div {
  background: var(--color-bg-white);
  border-radius: var(--radius-xl);
  padding: 48px 40px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--color-border);
  text-align: center;
}

.about-avatar {
  position: relative;
  width: 140px;
  height: 140px;
  margin: 0 auto 24px;
}

.avatar-ring {
  position: absolute;
  top: -6px;
  left: -6px;
  right: -6px;
  bottom: -6px;
  border-radius: 50%;
  background: var(--gradient-avatar);
  animation: ringRotate 3s linear infinite;
}

@keyframes ringRotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.avatar-inner {
  position: relative;
  width: 100%;
  height: 100%;
  background: var(--color-secondary-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 64px;
  border: 6px solid var(--color-bg-white);
}

.about-name {
  font-size: 28px;
  font-weight: 800;
  color: var(--color-primary);
  margin-bottom: 8px;
}

.about-tagline {
  font-size: 15px;
  color: var(--color-text-light);
  margin-bottom: 32px;
}

.about-info {
  text-align: left;
  margin-bottom: 32px;
}

.info-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px dashed var(--color-border);
}

.info-row:last-child {
  border-bottom: none;
}

.info-icon {
  font-size: 20px;
  flex-shrink: 0;
}

.info-label {
  font-size: 14px;
  color: var(--color-text-light);
  min-width: 80px;
  flex-shrink: 0;
  font-weight: 500;
}

.info-value {
  font-size: 15px;
  color: var(--color-text);
  flex: 1;
}

.about-motto {
  background: var(--color-secondary-light);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 32px;
}

.motto-label {
  font-size: 13px;
  color: var(--color-primary);
  margin-bottom: 8px;
  font-weight: 600;
}

.motto-text {
  font-size: 18px;
  color: var(--color-text);
  font-weight: 600;
  font-style: italic;
}

.about-social {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.social-btn {
  padding: 10px 24px;
  background: var(--gradient-button);
  color: white;
  border-radius: var(--radius-full);
  font-size: 14px;
  font-weight: 500;
  transition: var(--transition-normal);
  box-shadow: var(--shadow-sm);
}

.social-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* ===== 留言板 ===== */
.guestbook-form {
  max-width: 700px;
  margin: 40px auto 0;
  padding: 0 24px;
}

.form-card {
  background: var(--color-bg-white);
  border-radius: var(--radius-xl);
  padding: 32px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--color-border);
}

.form-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 24px;
}

.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 8px;
}

.form-input,
.form-textarea {
  width: 100%;
  padding: 14px 18px;
  border: 2px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-bg);
  font-size: 15px;
  transition: var(--transition-fast);
  outline: none;
  resize: vertical;
}

.form-input:focus,
.form-textarea:focus {
  border-color: var(--color-primary);
  background: var(--color-bg-white);
  box-shadow: 0 0 0 4px rgba(255, 107, 158, 0.1);
}

.form-textarea {
  min-height: 120px;
  line-height: 1.7;
}

.submit-btn {
  width: 100%;
  padding: 14px 32px;
  background: var(--gradient-button);
  color: white;
  border-radius: var(--radius-md);
  font-size: 16px;
  font-weight: 600;
  transition: var(--transition-normal);
  box-shadow: var(--shadow-sm);
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  background: var(--gradient-button-hover);
}

.submit-btn:active {
  transform: translateY(0);
}

.messages-section {
  max-width: 700px;
  margin: 48px auto 80px;
  padding: 0 24px;
}

.messages-header {
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.messages-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--color-primary);
}

.messages-count {
  display: inline-block;
  min-width: 28px;
  height: 28px;
  padding: 0 8px;
  background: var(--color-secondary);
  color: var(--color-primary);
  font-size: 13px;
  font-weight: 600;
  border-radius: var(--radius-full);
  line-height: 28px;
  text-align: center;
  vertical-align: middle;
  margin-left: 4px;
}

.messages-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.empty-state {
  text-align: center;
  padding: 60px 20px;
  background: var(--color-bg-white);
  border-radius: var(--radius-lg);
  border: 2px dashed var(--color-border);
}

.empty-icon {
  font-size: 56px;
  margin-bottom: 16px;
  opacity: 0.6;
}

.empty-text {
  color: var(--color-text-lighter);
  font-size: 15px;
}

.message-item {
  background: var(--color-bg-white);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
  animation: messageSlideIn 0.3s ease;
}

@keyframes messageSlideIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.message-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.message-author {
  display: flex;
  align-items: center;
  gap: 10px;
}

.message-avatar {
  width: 36px;
  height: 36px;
  background: var(--gradient-button);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 16px;
  font-weight: 600;
}

.message-nickname {
  font-size: 15px;
  font-weight: 600;
  color: var(--color-primary);
}

.message-time {
  font-size: 12px;
  color: var(--color-text-lighter);
}

.message-content {
  font-size: 15px;
  color: var(--color-text);
  line-height: 1.8;
  word-break: break-word;
}

/* ===== 页脚 ===== */
.footer {
  background: var(--color-secondary-light);
  padding: 40px 24px;
  text-align: center;
  margin-top: 40px;
}

.footer-text {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 8px;
}

.footer-copyright {
  font-size: 13px;
  color: var(--color-text-light);
}

/* ===== 回到顶部 ===== */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 48px;
  height: 48px;
  background: var(--gradient-button);
  border-radius: 50%;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: var(--transition-normal);
  z-index: 999;
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  transform: translateY(-4px) scale(1.1);
  box-shadow: var(--shadow-lg);
}

/* ===== 响应式设计 ===== */
@media (max-width: 1024px) {
  .hero-title {
    font-size: 38px;
  }

  .stats-card {
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
  }

  .quick-nav-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .nav-menu {
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    background: rgba(255, 245, 248, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 20px;
    gap: 4px;
    box-shadow: var(--shadow-lg);
    transform: translateY(-120%);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-normal);
  }

  .nav-menu.open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  .nav-link {
    display: block;
    padding: 12px 20px;
    text-align: center;
  }

  .nav-toggle {
    display: flex;
  }

  .hero-banner {
    min-height: 400px;
    padding: 60px 20px 80px;
  }

  .hero-title {
    font-size: 28px;
    flex-direction: column;
    gap: 8px;
  }

  .hero-subtitle {
    font-size: 18px;
  }

  .hero-decor {
    font-size: 28px;
  }

  .stats-card {
    grid-template-columns: repeat(2, 1fr);
    padding: 28px 20px;
    gap: 24px;
  }

  .stat-number {
    font-size: 28px;
  }

  .stat-label {
    font-size: 13px;
  }

  .section-title {
    font-size: 24px;
  }

  .welcome-card {
    flex-direction: column;
    padding: 32px 24px;
    text-align: center;
  }

  .welcome-avatar {
    margin: 0 auto;
  }

  .welcome-sign {
    text-align: center !important;
  }

  .quick-nav-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .quick-nav-card {
    padding: 20px 12px;
  }

  .quick-nav-icon {
    font-size: 32px;
  }

  .page-title {
    font-size: 28px;
  }

  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 24px 16px 60px;
  }

  .diary-timeline::before {
    left: 20px;
  }

  .timeline-dot {
    left: 14px;
  }

  .timeline-date {
    display: none;
  }

  .timeline-item {
    padding-left: 50px;
    gap: 0;
  }

  .timeline-card {
    padding: 18px 20px;
  }

  .music-player-card > div {
    flex-direction: column;
    text-align: center;
    padding: 32px 24px;
  }

  .music-cover {
    width: 120px;
    height: 120px;
  }

  .cover-disc {
    font-size: 48px;
  }

  .playlist-item {
    padding: 14px 16px;
  }

  .about-card > div {
    padding: 32px 24px;
  }

  .about-avatar {
    width: 110px;
    height: 110px;
  }

  .avatar-inner {
    font-size: 48px;
  }

  .about-name {
    font-size: 24px;
  }

  .info-row {
    flex-wrap: wrap;
    gap: 8px;
  }

  .info-label {
    min-width: 70px;
  }

  .form-card {
    padding: 24px;
  }

  .message-item {
    padding: 16px 18px;
  }

  .back-to-top {
    bottom: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
  }
}

@media (max-width: 480px) {
  .stats-card {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .stat-item {
    padding: 8px;
  }

  .stat-icon {
    font-size: 28px;
  }

  .stat-number {
    font-size: 24px;
  }

  .quick-nav-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .hero-title {
    font-size: 24px;
  }
}
/* 加载动画Kitty图片样式 */
.loading-kitty img {
  width: 75px;
  height: auto;
  object-fit: contain;
  /* 继承原有弹跳动画，和加载动画同步 */
  animation: var(--transition-bounce);
}
.title-icon {
  display: inline-block;
  margin: 0 12px; /* 左右留白，数值越大间隔越宽 */
}
.about-card {
    text-align: center;
    margin: 0 auto;
    width: 100%;
}
.about-info {
    margin: 0 auto;
    display: inline-block;
    text-align: left; /* 文字内容内部左对齐，整体块居中 */
}