/* ==========================================================================
   KADOSHI WEB RÁDIO - STYLES (v33.0 - STABLE CLEAN PLAY BUTTON)
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Alata&family=Roboto:wght@400;500;700&display=swap');

:root {
  --azul-escuro: #1d2654;
  --azul: #0071bb;
  --bege: #e7e7e7;
  --cinza: #7A838B;
  --branco: #ffffff;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  width: 100%;
  height: 100%;
  background-color: #0c1022;
  font-family: 'Roboto', sans-serif;
  color: #333333;
}

body {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  overflow-x: hidden;
}

/* App Viewport Container */
#app-container {
  width: 100%;
  max-width: 480px;
  min-height: 100vh;
  background-color: var(--bege);
  position: relative;
  box-shadow: 0 0 50px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
}

/* CustomAppBar (Fine-tuned Height 350px) */
.custom-app-bar {
  position: relative;
  width: 100%;
  height: 350px;
  background-color: var(--azul-escuro);
  background-image: url('../imgs/background.jpg');
  background-size: cover;
  background-position: center;
  border-bottom-left-radius: 24px;
  border-bottom-right-radius: 24px;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
  padding: 22px;
}

.custom-app-bar .logo-img {
  width: 280px;
  height: 140px;
  object-fit: contain;
}

/* Glassmorphic Capsule Website Button (Similar to AO VIVO badge) */
.header-website-btn {
  position: absolute;
  top: 18px;
  right: 18px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #ffffff;
  padding: 5px 14px;
  border-radius: 14px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  transition: all 0.25s ease;
  z-index: 10;
}

.header-website-btn:hover {
  background: rgba(255, 255, 255, 0.32);
  border-color: rgba(255, 255, 255, 0.6);
  transform: translateY(-1px) scale(1.03);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

.header-website-btn:active {
  transform: translateY(0) scale(0.96);
}

/* Main Body Area */
.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 40px 20px 100px;
  text-align: center;
}

.now-playing-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
}

.now-playing-label {
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--azul);
  font-weight: 700;
}

.now-playing-title {
  font-family: 'Alata', 'Roboto', sans-serif;
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--azul-escuro);
  line-height: 1.35;
  max-width: 360px;
}

/* Live Badge Row */
.radio-status {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 0.95rem;
  color: var(--cinza);
  font-weight: 500;
  margin-top: 12px;
}

/* Live Badge Default State (Secondary Gray) */
.live-badge-box {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(122, 131, 139, 0.15);
  border: 1px solid rgba(122, 131, 139, 0.3);
  color: var(--cinza);
  padding: 4px 12px;
  border-radius: 14px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  transition: all 0.3s ease;
}

.live-dot {
  width: 8px;
  height: 8px;
  background-color: var(--cinza);
  border-radius: 50%;
  transition: all 0.3s ease;
}

/* Active Live State (Solid Red background, White text, Calm 2.4s Scale Pulse) */
.live-badge-box.is-live {
  background: #e53935;
  border-color: #d32f2f;
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(229, 57, 53, 0.35);
  animation: pulse-scale-badge 2.4s ease-in-out infinite;
}

.live-badge-box.is-live .live-dot {
  background-color: #ffffff;
  box-shadow: 0 0 6px #ffffff;
}

/* Calm breathing scale pulse animation (2.4 seconds duration) */
@keyframes pulse-scale-badge {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 4px 14px rgba(229, 57, 53, 0.35);
  }
  35%, 65% {
    transform: scale(1.07);
    box-shadow: 0 6px 18px rgba(229, 57, 53, 0.55);
  }
}

.status-divider {
  color: var(--cinza);
  font-weight: 700;
}

/* Version Tag */
.app-version-tag {
  margin-top: 16px;
  font-size: 0.75rem;
  color: var(--cinza);
  opacity: 0.75;
  font-weight: 500;
  letter-spacing: 0.5px;
  background: rgba(0, 0, 0, 0.04);
  padding: 3px 10px;
  border-radius: 10px;
}

/* AudioPlayerWidget (Height 75px) */
.audio-player-widget {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 480px;
  height: 75px;
  background: var(--branco);
  border-top-left-radius: 16px;
  border-top-right-radius: 16px;
  box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  padding: 0 20px;
  z-index: 1000;
}

.player-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Stable Clean Floating Play Circle Container */
.play-btn-translate {
  transform: translateY(-16px);
  width: 110px;
  height: 110px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: relative;
  z-index: 1001;
  margin-left: 4px;
}

.play-circle {
  width: 110px;
  height: 110px;
  background: var(--branco);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: none;
  border: none;
}

.play-circle.disabled {
  pointer-events: none;
  opacity: 0.9;
}

/* Spinner Loader (Thicker 6.5px border matching Play icon stroke) */
.spinner {
  width: 74px;
  height: 74px;
  border: 6.5px solid rgba(0, 113, 187, 0.18);
  border-top-color: var(--azul);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* Action Buttons Row */
.actions-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-right: 27px;
}

.action-btn {
  width: 60px;
  height: 40px;
  background: rgba(0, 113, 187, 0.1);
  border: none;
  border-radius: 4px;
  color: var(--azul);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.action-btn:hover {
  background: rgba(0, 113, 187, 0.2);
}

.action-btn:active {
  transform: scale(0.95);
}

/* Modal Bottom Sheet */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 2000;
  justify-content: center;
  align-items: flex-end;
}

.modal-overlay.active {
  display: flex !important;
}

.sheet-content {
  width: 100%;
  max-width: 480px;
  background: var(--branco);
  border-top-left-radius: 16px;
  border-top-right-radius: 16px;
  padding: 8px 0 32px;
  animation: slideUp 0.22s ease-out;
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.sheet-handle {
  width: 40px;
  height: 4px;
  background: #bdbdbd;
  border-radius: 2px;
  margin: 8px auto 16px;
}

.sheet-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: rgba(0, 0, 0, 0.54);
  font-size: 16px;
  padding-bottom: 16px;
}

.sheet-option {
  padding: 16px 24px;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  font-size: 16px;
  color: #212121;
  cursor: pointer;
}

.sheet-option:hover {
  background: var(--bege);
  color: var(--azul);
}

/* Toast Notification - SLIDING FROM TOP WITH ACTION ICONS */
.flutter-snackbar {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(-30px);
  width: calc(100% - 32px);
  max-width: 440px;
  background: var(--azul);
  color: white;
  padding: 14px 18px;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 500;
  opacity: 0;
  pointer-events: none;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 3000;
}

.flutter-snackbar.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.snackbar-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}