:root {
  color-scheme: light;
  --bg: #f5f5f7;
  --ink: #1d1d1f;
  --muted: #6e6e73;
  --line: #ececf0;
  --card: #ffffff;
  --spotify: #1db954;
  --spotify-hover: #1ed760;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family: "Trebuchet MS", "Lucida Sans Unicode", "Lucida Grande", Arial, sans-serif;
}

.page {
  max-width: 1280px;
  margin: 0 auto;
  padding: 1.25rem 16px 48px;
}

.page-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2.5rem;
}

.kicker {
  margin: 0 0 0.2rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

h1 {
  margin: 0 0 0.2rem;
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.subtitle {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
}

.btn-donate {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  flex-shrink: 0;
  padding: 0.6rem 1.25rem;
  background: linear-gradient(135deg, #f7931a, #e8820f);
  color: #1a0a00;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  letter-spacing: 0.01em;
}

.btn-donate:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(247, 147, 26, 0.4);
}

.album {
  background: linear-gradient(145deg, #ffffff 0%, #f6f8ff 100%);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 1.15rem 1.15rem 1rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.album-header {
  display: grid;
  grid-template-columns: minmax(120px, 180px) minmax(0, 1fr);
  gap: 1.1rem;
  align-items: center;
  margin-bottom: 1.1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--line);
}

.cover {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
  overflow: hidden;
  background: #e5e5ea;
}

.album-header .cover {
  max-width: 180px;
  justify-self: center;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.12);
}

.cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.cover-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #aeaeb2;
}

.album-title {
  margin: 0 0 0.35rem;
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.desc,
.count {
  margin: 0.25rem 0 0;
  font-size: 0.88rem;
  line-height: 1.45;
}

.desc {
  color: var(--muted);
}

.count {
  margin-top: 0.45rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #3a3a3c;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.action {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.48rem 0.95rem;
  border-radius: 980px;
  font-size: 0.86rem;
  font-weight: 600;
  text-decoration: none;
}

.action:active {
  transform: scale(0.97);
}

.action-listen {
  background: var(--spotify);
  color: #fff;
  border: 1px solid var(--spotify);
}

.action-listen:hover {
  background: var(--spotify-hover);
  border-color: var(--spotify-hover);
  color: #fff;
}

.action-download {
  background: #fff;
  color: var(--ink);
  border: 1px solid #d2d2d7;
}

.action-download:hover {
  background: #f5f5f7;
  border-color: #aeaeb2;
  color: var(--ink);
}

.book-list {
  margin: 0;
  padding: 0;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
}

.book-list li {
  display: grid;
  grid-template-columns: 2rem minmax(0, 1fr);
  gap: 0.55rem;
  align-items: start;
  padding: 0.85rem 0.95rem;
  border-bottom: 1px solid #f0f0f3;
}

.book-list li:last-child {
  border-bottom: none;
}

.index {
  font-size: 0.82rem;
  font-weight: 700;
  color: #aeaeb2;
  line-height: 1.45;
  padding-top: 0.1rem;
  text-align: right;
}

.book-title {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.3;
}

.book-title a,
.album-title a,
.back-link,
.breadcrumb a,
.pager a,
.related-list a {
  color: inherit;
  text-decoration: none;
}

.book-title a:hover,
.album-title a:hover,
.back-link:hover,
.breadcrumb a:hover,
.pager a:hover,
.related-list a:hover {
  text-decoration: underline;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
  margin: 0 0 1rem;
  font-size: 0.82rem;
  color: var(--muted);
}

.breadcrumb a {
  font-weight: 600;
}

.breadcrumb [aria-current="page"] {
  color: var(--ink);
  font-weight: 600;
}

.pager {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1.25rem;
  font-size: 0.9rem;
}

.pager div:last-child {
  text-align: right;
}

.donate {
  margin-top: 1.15rem;
  padding: 1rem 1.05rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}

.donate h2 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.donate p {
  margin: 0.45rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.45;
}

.donate .btn-donate {
  margin-top: 0.8rem;
}

.donate code {
  display: inline-block;
  margin-top: 0.75rem;
  padding: 0.2rem 0.45rem;
  background: var(--bg);
  border-radius: 6px;
  color: var(--ink);
  font-size: 0.92rem;
}

.meta-person {
  margin: 0.25rem 0 0;
  font-size: 0.88rem;
  color: var(--muted);
}

.book-page {
  background: linear-gradient(145deg, #ffffff 0%, #f6f8ff 100%);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 1.15rem;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.related {
  margin-top: 1.25rem;
}

.related-list {
  margin: 0.4rem 0 0;
  padding: 0;
  list-style: none;
}

.related-list a {
  color: inherit;
  font-weight: 600;
  text-decoration: none;
}

.related-list a:hover {
  text-decoration: underline;
}

.related-list li {
  margin: 0.35rem 0;
}

.book-list .actions {
  margin-top: 0.55rem;
}

.book-list .action {
  padding: 0.38rem 0.75rem;
  font-size: 0.8rem;
}

.standalone-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.standalone {
  display: grid;
  grid-template-columns: minmax(72px, 96px) minmax(0, 1fr);
  gap: 0.85rem;
  align-items: center;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.55rem;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.05);
}

.standalone .cover {
  max-width: 96px;
  justify-self: center;
  border-radius: 10px;
}

.section-title {
  margin: 0 0 1.25rem;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.empty {
  padding: 2.5rem 1rem;
  text-align: center;
  color: var(--muted);
}

.empty svg {
  display: block;
  margin: 0 auto 0.8rem;
}

@media (min-width: 1024px) {
  .page {
    padding: 1.25rem 28px 60px;
  }
}

@media (max-width: 640px) {
  .page-header {
    flex-direction: column;
    align-items: flex-start;
  }

  h1 {
    font-size: 1.55rem;
  }

  .album {
    padding: 0.9rem;
  }

  .album-header {
    grid-template-columns: 108px minmax(0, 1fr);
    gap: 0.75rem;
  }

  .album-title {
    font-size: 1.2rem;
  }

  .book-list li {
    grid-template-columns: 1.6rem minmax(0, 1fr);
    padding: 0.75rem 0.8rem;
  }
}

@media (max-width: 430px) {
  .album-header,
  .standalone {
    grid-template-columns: minmax(0, 1fr);
  }

  .album-header .cover,
  .standalone .cover {
    max-width: 160px;
  }

  .standalone .cover {
    aspect-ratio: 16 / 9;
    max-width: 100%;
  }
}
