:root {
  --primary: #F76700;
  --artist: #bbbbbb;
  --surface-dark: #181818;
  --surface-light: #f1f1f1;
  --text-primary: #f1f1f1;
  --text-secondary: rgba(255, 255, 255, 0.7);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
@font-face {
        font-family: 'Onest';
        src: url('../fonts/Onest-Regular.ttf') format('truetype');
        font-weight: 400;
        font-style: normal;
        font-display: swap;
    }
@font-face {
        font-family: 'Montserrat';
        src: url('../fonts/Montserrat-Regular.ttf') format('truetype');
        font-weight: 400;
        font-style: normal;
        font-display: swap;
    }
@font-face {
        font-family: 'Poppins';
        src: url('../fonts/Poppins-Regular.ttf') format('truetype');
        font-weight: 400;
        font-style: normal;
        font-display: swap;
    }
html {
  background: #181818;
}
body {
  min-height: 100vh;
  background: var(--surface-dark);
  color: var(--text-primary);
  font-family: 'Onest', system-ui, sans-serif;
  display: flex;
  flex-direction: column;
}

.app-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.header-controls {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  padding: 1rem;
  background: rgba(24, 24, 24, 0.8);
  backdrop-filter: blur(10px);
  z-index: 1000;
}

.player {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  margin-top: 4rem;
  width: 100%;
}

/* Ajustes Mobile - Retrato */
@media screen and (max-width: 767px) {
  .player {
    gap: 2rem;
  }

  .cover-wrapper {
    width: min(80vw, 350px);
  }

  .info-wrapper {
    width: 100%;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
  }
}

/* Ajustes Mobile - Paisagem */
@media screen and (orientation: landscape) and (max-height: 600px) {
  .player {
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    padding: 1rem;
  }

  .cover-wrapper {
    width: min(60vh, 250px);
    flex-shrink: 0;
  }

  .info-wrapper {
    flex: 0 1 400px;
    text-align: left;
  }
}

/* Remove duplicação do .cover-wrapper */
.cover-wrapper {
  margin: 0 auto;
}

.cover-container {
  aspect-ratio: 1;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  position: relative;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  overflow: hidden; /* Importante: força o border-radius nos filhos */
}

.cover-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: all 0.3s ease;
  /*border-radius: 12px;*/
}

.no-cover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-secondary);
}

.info-wrapper {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1rem;
  text-align: center;
  margin: 0;
}

@media (min-width: 768px) {
  .info-wrapper {
    text-align: left;
  }
}

.info-wrapper h1 {
  font-size: clamp(1.5rem, 5vw, 2rem);
  color: var(--text-primary);
  font-family: 'Onest', system-ui, sans-serif;
  letter-spacing: .07rem;
}

.info-wrapper p {
  font-size: clamp(1.2rem, 3vw, 1.25rem);
  color: var(--artist);
  letter-spacing: .05rem;
}

.controls-wrapper {
  margin-top: 2rem;
}

audio {
  width: 100%;
  height: 40px;
  border-radius: 20px;
  background: transparent;
}

audio::-webkit-media-controls-panel {
  background: rgba(255, 255, 255, 0.05);
}

audio::-webkit-media-controls-play-button,
audio::-webkit-media-controls-mute-button {
  border-radius: 50%;
  background: var(--primary);
}

.player.loading {
  opacity: 0.7;
  transition: opacity 0.3s ease;
}

/* Adicione os estilos do menu e controles */
.header-controls {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
}

.icon-button {
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
  padding: 0.5rem;
  transition: color 0.3s ease;
}

.icon-button:hover {
  color: var(--primary);
}

.player-controls {
  display: flex;
  gap: 1.2rem;
  justify-content: center;
  margin: 1rem 0;
}

.control-button {
  background: var(--primary);
  border: none;
  color: white;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: transform 0.2s ease;
}

.control-button:hover {
  transform: scale(1.1);
}

.material-icons {
  font-size: 1.5rem;
}
.control-button {
  background: var(--primary);
  border: none;
  color: white;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: transform 0.2s ease;
}

.control-button:hover {
  transform: scale(1.1);
}

.material-icons {
  font-size: 1.5rem;
}

/* Desktop/PC - Telas grandes */
@media screen and (min-width: 1024px) {
  .player {
    flex-direction: row;
    gap: 3rem;
    padding: 2rem;
    justify-content: center;
    align-items: center;
  }

  .cover-wrapper {
    width: 350px;  /* Tamanho fixo para desktop */
    margin: 0;
  }

  .cover-container {
    width: 100%;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
    transform: translateZ(0);
    will-change: transform;
  }

  .info-wrapper {
    flex: 0 1 500px;
    text-align: left;
    padding-left: 2rem;
  }
}

/* Modal styles */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(24,24,24,0.85);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
}

.modal-box {
  background: var(--surface-dark);
  color: var(--text-primary);
  border-radius: 16px;
  max-width: 95vw;
  max-height: 90vh;
  width: 400px;
  padding: 2rem 1.5rem 1.5rem 1.5rem;
  box-shadow: 0 8px 32px rgba(0,0,0,0.5);
  position: relative;
  outline: none;
  overflow-y: auto;
}

.modal-close {
  position: absolute;
  top: 0.5rem;
  right: 1rem;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 2rem;
  cursor: pointer;
}

.modal-loading, .modal-error {
  text-align: center;
  padding: 2rem 0;
  color: var(--primary);
}
