/* Reset und Basis-Stile */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
}

body {
  font-family: 'Inter', Arial, sans-serif;
  background-color: #1a1a1a;
  color: #fff;
  line-height: 1.6;
}

/* Container */
.page-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Header */
header {
  background-color: #2c2c2c;
  padding: 15px;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.nav-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 100%;
  margin: 0 auto;
}

.logo {
  width: 80px;
  height: auto;
  margin-bottom: 10px;
}

.hamburger {
  display: block;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
}

nav ul {
  display: none;
  flex-direction: column;
  list-style: none;
  width: 100%;
  background-color: #2c2c2c;
  padding: 10px;
}

nav ul.active {
  display: flex;
}

nav ul li {
  margin: 10px 0;
}

nav ul li a {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
  font-size: 1rem;
}

nav ul li a:hover {
  color: #007BFF;
}

.search-form {
  width: 100%;
  margin-top: 10px;
}

.search-bar {
  width: 100%;
  padding: 10px;
  border-radius: 8px;
  border: none;
  background-color: #3a3a3a;
  color: #fff;
  font-size: 0.9rem;
}

/* Main */
main {
  flex: 1;
  padding: 15px;
  max-width: 100%;
  margin: 0 auto;
}

/* Homepage */
.homepage {
  text-align: center;
}

.homepage h1 {
  font-size: 1.5rem;
  margin-bottom: 20px;
}

.section {
  margin-bottom: 30px;
}

.section h2 {
  font-size: 1.25rem;
  margin-bottom: 15px;
}

/* Songs Page */
.songs-page {
  text-align: center;
}

.songs-page h1 {
  font-size: 1.5rem;
  margin-bottom: 20px;
}

.filter-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}

.filter-form select {
  padding: 10px;
  background-color: #3a3a3a;
  border: none;
  border-radius: 8px;
  color: #fff;
  font-size: 0.9rem;
}

/* Albums Page */
.albums-page {
  text-align: center;
}

.albums-page h1 {
  font-size: 1.5rem;
  margin-bottom: 20px;
}

/* Projects Page */
.projects-page {
  text-align: center;
}

.projects-page h1 {
  font-size: 1.5rem;
  margin-bottom: 20px;
}

/* Search Page */
.search-page {
  text-align: center;
}

.search-page h1 {
  font-size: 1.5rem;
  margin-bottom: 20px;
}

.search-form-page {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}

.search-bar-page {
  width: 100%;
  padding: 10px;
  border-radius: 8px;
  border: none;
  background-color: #3a3a3a;
  color: #fff;
  font-size: 1rem;
}

.search-form-page button {
  padding: 10px;
  background-color: #007BFF;
  border: none;
  border-radius: 8px;
  color: #fff;
  cursor: pointer;
  font-size: 1rem;
}

.search-form-page button:hover {
  background-color: #0056b3;
}

/* Legal Pages */
.legal-page {
  text-align: left;
}

.legal-page h1 {
  font-size: 1.5rem;
  margin-bottom: 15px;
}

.legal-page h2 {
  font-size: 1.25rem;
  margin: 15px 0 10px;
}

.legal-page p {
  margin-bottom: 10px;
}

/* Song Grid */
.song-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.song-card {
  background-color: #3a3a3a;
  border-radius: 8px;
  padding: 8px;
  cursor: pointer;
  transition: transform 0.3s ease, background-color 0.3s ease;
  opacity: 0;
  animation: fadeIn 0.5s ease forwards;
}

.song-card:hover {
  background-color: #4a4a4a;
  transform: translateY(-3px);
}

.song-card.active {
  background-color: #007BFF;
  transform: scale(1.03);
  box-shadow: 0 0 10px rgba(0, 123, 255, 0.5);
}

.song-cover {
  width: 100%;
  aspect-ratio: 1/1;
  object-fit: contain;
  background-color: #2c2c2c;
  border-radius: 5px;
  margin-bottom: 6px;
}

.song-title {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 4px;
}

.song-context {
  font-size: 0.8rem;
  color: #bbb;
}

/* Album Grid */
.album-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* Zwei Spalten für Mobile; für einspaltig: grid-template-columns: 1fr */
  gap: 10px;
}

.album-card {
  background-color: #3a3a3a;
  border-radius: 8px;
  padding: 8px;
  cursor: pointer;
  transition: transform 0.3s ease, background-color 0.3s ease;
  opacity: 0;
  animation: fadeIn 0.5s ease forwards;
}

.album-card:hover {
  background-color: #4a4a4a;
  transform: translateY(-3px);
}

.album-cover {
  width: 100%;
  aspect-ratio: 1/1;
  object-fit: contain;
  background-color: #2c2c2c;
  border-radius: 5px;
  margin-bottom: 6px;
}

.album-title {
  display: block;
  font-size: 0.9rem;
}

/* Project Grid */
.project-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* Zwei Spalten für Mobile; für einspaltig: grid-template-columns: 1fr */
  gap: 10px;
}

.project-card {
  background-color: #3a3a3a;
  border-radius: 8px;
  padding: 8px;
  cursor: pointer;
  transition: transform 0.3s ease, background-color 0.3s ease;
  opacity: 0;
  animation: fadeIn 0.5s ease forwards;
}

.project-card:hover {
  background-color: #4a4a4a;
  transform: translateY(-3px);
}

.project-cover {
  width: 100%;
  aspect-ratio: 1/1;
  object-fit: contain;
  background-color: #2c2c2c;
  border-radius: 5px;
  margin-bottom: 6px;
}

.project-title {
  display: block;
  font-size: 0.9rem;
}

/* Song Sublist (Akkordeon) */
.song-sublist {
  background-color: #2c2c2c;
  border-radius: 5px;
  padding: 8px;
}

.song-sublist .song-card {
  margin: 4px 0;
  padding: 6px;
  background-color: #4a4a4a;
}

/* Fade-In Animation */
@keyframes fadeIn {
  to { opacity: 1; }
}

/* See More Link */
.see-more {
  display: inline-block;
  margin-top: 12px;
  color: #007BFF;
  text-decoration: none;
  font-weight: 500;
}

.see-more:hover {
  color: #0056b3;
}

/* Paginierung */
.pagination {
  margin-top: 15px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
}

.page-link {
  color: #fff;
  text-decoration: none;
  padding: 6px 10px;
  background-color: #3a3a3a;
  border-radius: 8px;
  transition: background-color 0.3s ease;
}

.page-link:hover {
  background-color: #007BFF;
}

/* Globaler Player */
.global-player {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: #2c2c2c;
  padding: 8px;
  z-index: 1000;
}

.player-content {
  display: flex;
  align-items: center;
  max-width: 100%;
  margin: 0 auto;
  gap: 8px;
}

.player-cover {
  width: 36px;
  height: 36px;
  object-fit: contain;
  background-color: #2c2c2c;
  border-radius: 5px;
  flex-shrink: 0;
}

.player-info {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

#player-title {
  font-size: 0.85rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.progress-bar {
  width: 100%;
  height: 4px;
  background: #4a4a4a;
  border-radius: 5px;
  outline: none;
  -webkit-appearance: none;
}

.progress-bar::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 8px;
  height: 8px;
  background: #007BFF;
  border-radius: 50%;
  cursor: pointer;
}

.progress-bar::-moz-range-thumb {
  width: 8px;
  height: 8px;
  background: #007BFF;
  border-radius: 50%;
  cursor: pointer;
}

.player-controls {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.player-controls button {
  padding: 6px;
  background-color: #3a3a3a;
  border: none;
  border-radius: 5px;
  color: #fff;
  cursor: pointer;
  font-size: 0.85rem;
  min-width: 36px;
}

.player-controls button:hover {
  background-color: #007BFF;
}

.player-controls audio {
  display: none;
}

/* Footer */
footer {
  background-color: #2c2c2c;
  padding: 12px;
  text-align: center;
  margin-top: 70px;
}

footer p {
  font-size: 0.8rem;
}

.footer-btn {
  color: #007BFF;
  text-decoration: none;
  margin-left: 6px;
}

.footer-btn:hover {
  color: #0056b3;
}

/* Tablet-Stile */
@media (min-width: 768px) {
  .nav-container {
    flex-direction: row;
    justify-content: space-between;
  }

  .logo {
    width: 100px;
    margin-bottom: 0;
  }

  .hamburger {
    display: none;
  }

  nav ul {
    display: flex;
    flex-direction: row;
    background: none;
    padding: 0;
  }

  nav ul li {
    margin: 0 15px;
  }

  .search-form {
    width: auto;
    margin-top: 0;
  }

  .search-bar {
    width: 200px;
  }

  main {
    padding: 20px;
  }

  .homepage h1, .songs-page h1, .albums-page h1, .projects-page h1, .search-page h1 {
    font-size: 2rem;
  }

  .section h2 {
    font-size: 1.5rem;
  }

  .song-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .album-grid, .project-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .song-cover, .album-cover, .project-cover {
    aspect-ratio: 1/1;
  }

  .song-title, .album-title, .project-title {
    font-size: 1rem;
  }

  .song-context {
    font-size: 0.85rem;
  }

  .filter-form {
    flex-direction: row;
    gap: 15px;
  }

  .filter-form select {
    width: 200px;
  }

  .search-form-page {
    flex-direction: row;
  }

  .search-bar-page {
    width: 300px;
  }

  .player-content {
    gap: 15px;
  }

  .player-cover {
    width: 50px;
    height: 50px;
  }

  #player-title {
    font-size: 1rem;
  }

  .progress-bar {
    height: 5px;
  }
}

/* Desktop-Stile */
@media (min-width: 1024px) {
  .nav-container {
    max-width: 1200px;
  }

  main {
    max-width: 1200px;
  }

  .song-grid, .album-grid, .project-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .song-cover, .album-cover, .project-cover {
    aspect-ratio: 1/1;
  }

  .song-title, .album-title, .project-title {
    font-size: 1.1rem;
  }

  .song-context {
    font-size: 0.9rem;
  }

  .player-content {
    gap: 20px;
  }

  .player-cover {
    width: 60px;
    height: 60px;
  }

  #player-title {
    font-size: 1.1rem;
  }

  .player-controls button {
    padding: 10px;
    font-size: 1rem;
  }
}