* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  background: #fff7fb;
  color: #3b2430;
}

.song-header {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 18px 18px 14px;
  background: rgba(255, 247, 251, 0.96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(215, 128, 166, 0.25);
}

.song-title-row {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  margin-bottom: 12px;
}

.song-header h1 {
  margin: 0;
  text-align: center;
  font-size: 26px;
  color: #c94f8a;
}

.back-home-button {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 15px;
  border-radius: 999px;
  text-decoration: none;
  color: #c94f8a;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.02em;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(201, 79, 138, 0.28);
  box-shadow: 0 8px 22px rgba(201, 79, 138, 0.12);
  backdrop-filter: blur(10px);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.back-home-button:hover {
  transform: translateY(-50%) translateY(-1px);
  color: white;
  background: #c94f8a;
  box-shadow: 0 10px 26px rgba(201, 79, 138, 0.24);
}

.back-home-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(201, 79, 138, 0.12);
  font-size: 13px;
  line-height: 1;
}

.back-home-button:hover .back-home-icon {
  background: rgba(255, 255, 255, 0.22);
}

.search-box {
  max-width: 720px;
  margin: 0 auto;
}

.search-box input {
  width: 100%;
  padding: 13px 18px;
  border: 1px solid rgba(201, 79, 138, 0.35);
  border-radius: 999px;
  outline: none;
  font-size: 16px;
  background: white;
  color: #3b2430;
  box-shadow: 0 6px 18px rgba(201, 79, 138, 0.08);
}

.search-box input:focus {
  border-color: #c94f8a;
  box-shadow: 0 8px 24px rgba(201, 79, 138, 0.18);
}

.song-page {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 14px;
  max-width: 900px;
  margin: 0 auto;
  padding: 18px 16px 80px;
}

.letter-index {
  position: sticky;
  top: 110px;
  align-self: start;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: 8px;
}

.letter-button {
  width: 36px;
  height: 28px;
  border: none;
  border-radius: 999px;
  background: transparent;
  color: #b36a8c;
  font-size: 14px;
  cursor: pointer;
  transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.letter-button:hover {
  background: rgba(201, 79, 138, 0.1);
}

.letter-button.active {
  transform: scale(1.35);
  background: #c94f8a;
  color: white;
  font-weight: 700;
}

.song-list {
  min-width: 0;
}

.song-group {
  scroll-margin-top: 125px;
  margin-bottom: 28px;
}

.group-title {
  margin: 0 0 10px;
  padding-left: 4px;
  font-size: 28px;
  color: #c94f8a;
}

.songs {
  list-style: none;
  margin: 0;
  padding: 0;
  background: white;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 8px 28px rgba(201, 79, 138, 0.08);
  border: 1px solid rgba(201, 79, 138, 0.12);
}

.song-item {
  border-bottom: 1px solid rgba(201, 79, 138, 0.1);
}

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

.song-item a {
  display: block;
  padding: 16px 18px;
  text-decoration: none;
  color: #3b2430;
  font-size: 17px;
  transition: background 0.16s ease, color 0.16s ease, padding-left 0.16s ease;
}

.song-item a:hover {
  background: #fff0f7;
  color: #c94f8a;
  padding-left: 24px;
}

.empty-result {
  margin-top: 40px;
  padding: 30px;
  text-align: center;
  color: #9b6b7f;
  background: white;
  border-radius: 18px;
  border: 1px solid rgba(201, 79, 138, 0.12);
}

@media (max-width: 600px) {
  .song-page {
    grid-template-columns: 42px 1fr;
    padding-left: 10px;
    padding-right: 10px;
  }

  .song-header h1 {
    font-size: 22px;
  }

  .song-title-row {
    justify-content: flex-start;
    padding-top: 46px;
  }

  .back-home-button {
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    padding: 8px 14px;
    font-size: 13px;
  }

  .back-home-button:hover {
    transform: translateX(-50%) translateY(-1px);
  }

  .letter-button {
    width: 30px;
    height: 25px;
    font-size: 13px;
  }

  .letter-button.active {
    transform: scale(1.25);
  }

  .song-item a {
    font-size: 16px;
    padding: 15px;
  }
}