@charset "UTF-8";

/* RESET BÁSICO */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Galano Grotesque Semi Bold', 'Galano Grotesque', Arial, Helvetica, sans-serif;
  font-weight: 600;
}

html, body {
  height: 100%;
  font-family: 'Galano Grotesque Semi Bold', 'Galano Grotesque', Arial, Helvetica, sans-serif;
  color: #fff;
  font-weight: 600;
}

/* DEFINIÇÃO DA FONTE PERSONALIZADA */
@font-face {
  font-family: 'Galano Grotesque Semi Bold';
  font-style: normal;
  font-weight: 600;
  src: url('/static/fonts/galano-grotesque-semi-bold.otf') format('opentype');
  font-display: swap;
}

@font-face {
  font-family: 'Galano Grotesque';
  font-style: normal;
  font-weight: 600;
  src: url('/static/fonts/galano-grotesque-semi-bold.otf') format('opentype');
  font-display: swap;
}

/* FUNDO DESFOCADO */
.bg {
  position: fixed;
  inset: 0;
  background: url("/static/img/fundo.png") center/cover no-repeat;
  filter: blur(12px);
  transform: scale(1.1);
  z-index: -1;
}

/* HEADER */
header {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 16px 40px;
  background: rgba(0, 0, 0, 0.65);
}

/* LOGO */
.logo {
  position: absolute;
  left: 40px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo img {
  height: 38px;
  width: auto;
  object-fit: contain;
}

.logo span {
  font-size: 18px;
}

/* MENU */
nav {
  display: flex;
  gap: 40px;
}

nav a {
  color: #fff;
  text-decoration: none;
  font-size: 15px;
  opacity: 0.85;
  cursor: pointer;
  letter-spacing: 0.3px;
}

nav a:hover {
  opacity: 1;
}

/* HERO */
.hero {
  text-align: center;
  margin-top: 120px;
  padding: 0 20px;
}

.hero h1 {
  font-size: 42px;
  margin-bottom: 20px;
  letter-spacing: -0.5px;
}

.hero h1 span {
  color: #ff9800;
}

.hero input {
  width: 100%;
  max-width: 520px;
  padding: 14px 18px;
  border-radius: 10px;
  border: none;
  outline: none;
  font-size: 15px;
  margin-bottom: 25px;
  opacity: 0.9;
}

/* PREVIEW DA MÚSICA */
.preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.preview img {
  width: 240px;
  height: 240px;
  object-fit: cover;
  border-radius: 14px;
  border: 4px solid green;
  box-shadow: 0 0 25px rgba(0, 0, 0, 0.7);
  transition: border 0.2s ease;
}

.preview #title {
  font-size: 16px;
  max-width: 300px;
  text-align: center;
}

/* SELECT DE GRAVE */
select {
  padding: 10px 16px;
  border-radius: 8px;
  border: none;
  outline: none;
  font-size: 14px;
  margin-bottom: 20px;
  cursor: pointer;
  opacity: 0.9;
}

/* BOTÃO BAIXAR */
.hero button {
  padding: 14px 28px;
  border-radius: 10px;
  border: none;
  font-size: 15px;
  cursor: pointer;
  background: #ff9800;
  color: #000;
  transition: all 0.3s ease;
  letter-spacing: 0.3px;
}

.hero button:hover:not(:disabled) {
  background: #ffa726;
  transform: translateY(-2px);
}

.hero button:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  background: #ff9800;
}

/* SPINNER DE LOADING */
.spinner {
  width: 40px;
  height: 40px;
  margin: 0 auto;
  border: 4px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top-color: #ff9800;
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* MENSAGEM DE SUCESSO */
.success-message {
  color: #2ecc71;
  margin-bottom: 15px;
  font-size: 16px;
}

/* BOTÕES DE RESULTADO */
.result-buttons {
  display: flex;
  gap: 15px;
  justify-content: center;
}

.download-btn, .copy-btn {
  padding: 12px 24px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.3s ease;
  letter-spacing: 0.3px;
}

.download-btn {
  background: #2ecc71;
  color: #000;
}

.copy-btn {
  background: #3498db;
  color: #000;
}

.download-btn:hover {
  background: #27ae60;
  transform: translateY(-2px);
}

.copy-btn:hover {
  background: #2980b9;
  transform: translateY(-2px);
}

/* NOTIFICAÇÃO */
.notification {
  position: fixed;
  bottom: -100px;
  left: 50%;
  transform: translateX(-50%);
  color: white;
  padding: 15px 25px;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  z-index: 10000;
  transition: bottom 0.5s ease;
  min-width: 300px;
  text-align: center;
  animation: slideUp 0.5s ease forwards;
  letter-spacing: 0.3px;
}

.notification.success {
  background-color: #2ecc71;
}

.notification.error {
  background-color: #e74c3c;
}

.notification.info {
  background-color: #3498db;
}

.notification.warning {
  background-color: #f39c12;
}

@keyframes slideUp {
  from {
    bottom: -100px;
    opacity: 0;
  }
  to {
    bottom: 20px;
    opacity: 1;
  }
}

@keyframes slideDown {
  from {
    bottom: 20px;
    opacity: 1;
  }
  to {
    bottom: -100px;
    opacity: 0;
  }
}

/* MAIS OUVIDAS */
.popular {
  margin: 100px auto;
  max-width: 700px;
  padding: 0 20px;
}

.popular h2 {
  font-size: 26px;
  margin-bottom: 20px;
  text-align: center;
}

.pop-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 15px;
  border-bottom: 1px solid rgba(255,255,255,0.15);
  cursor: pointer;
  transition: background 0.2s ease;
  border-radius: 8px;
  margin-bottom: 8px;
}

.pop-item:hover {
  background: rgba(255, 255, 255, 0.1);
}

.pop-info {
  display: flex;
  align-items: center;
  gap: 15px;
}

.pop-thumb {
  width: 50px;
  height: 50px;
  border-radius: 6px;
  object-fit: cover;
}

.pop-item span {
  font-size: 15px;
  flex-grow: 1;
  text-align: left;
}

.pop-play {
  color: #ff9800;
  font-size: 18px;
}

/* PLACEHOLDER DOS INPUTS */
::placeholder {
  opacity: 0.7;
}

/* OPTIONS DO SELECT */
option {
  font-weight: 600;
}

/* RESPONSIVO */
@media (max-width: 768px) {
  .logo {
    left: 20px;
  }

  nav {
    gap: 20px;
  }

  .hero h1 {
    font-size: 32px;
  }

  .preview img {
    width: 200px;
    height: 200px;
  }
  
  .result-buttons {
    flex-direction: column;
  }
  
  .notification {
    min-width: 250px;
    padding: 12px 20px;
    font-size: 14px;
    left: 10px;
    right: 10px;
    transform: none;
    margin: 0 auto;
    width: calc(100% - 20px);
  }
}

/* MELHORIAS DE LEGIBILIDADE */
body {
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ESTILO PARA A MODAL DE CÓPIA MANUAL */
#setradioText {
  font-family: 'Galano Grotesque Semi Bold', 'Galano Grotesque', Arial, sans-serif;
  font-weight: 600;
  resize: none;
}

button {
  font-family: 'Galano Grotesque Semi Bold', 'Galano Grotesque', Arial, sans-serif;
  font-weight: 600;
}

/* Estilos para a preview quando está vazia */
.preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  min-height: 280px;
  justify-content: center;
}

.preview img {
  width: 240px;
  height: 240px;
  object-fit: cover;
  border-radius: 14px;
  border: 4px solid green;
  box-shadow: 0 0 25px rgba(0, 0, 0, 0.7);
  transition: border 0.2s ease, opacity 0.3s ease;
  opacity: 0;
  animation: fadeIn 0.5s ease forwards;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.preview #title {
  font-size: 16px;
  max-width: 300px;
  text-align: center;
  opacity: 0;
  animation: fadeIn 0.5s ease 0.2s forwards;
}

/* Quando a preview está escondida */
.preview.hidden {
  display: none;
}

/* Estilo para thumbnails das músicas populares */
.pop-thumb {
  width: 50px;
  height: 50px;
  border-radius: 6px;
  object-fit: cover;
  transition: transform 0.2s ease;
}

.pop-thumb:hover {
  transform: scale(1.05);
}

/* Estilos para thumbnails das músicas populares */
.pop-thumb {
  width: 50px;
  height: 50px;
  border-radius: 6px;
  object-fit: cover; /* Padrão para thumbnails do YouTube */
  transition: transform 0.2s ease;
  background-color: #2c3e50; /* Cor de fundo para fallback */
}

/* Quando usar a logo como fallback */
.pop-thumb[src*="logo.png"] {
  object-fit: contain;
  background-color: transparent;
  padding: 5px;
}

.pop-thumb:hover {
  transform: scale(1.05);
}