/* PWA Styles - Enhanced */

/* PWA Banner Container */
.pwa-banner {
  position: fixed;
  bottom: 90px;  /* Espaço para menu inferior (70px) + margem */
  left: 20px;
  right: 20px;
  background: linear-gradient(135deg, rgba(209, 18, 31, 0.95), rgba(255, 49, 49, 0.9));
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  padding: 16px;
  z-index: 10000;
  transform: translateY(200%);
  transition: transform 0.4s ease;
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.6),
    0 4px 16px rgba(209, 18, 31, 0.4);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.pwa-banner.show {
  transform: translateY(0);
}

/* Banner Content */
.pwa-banner-content {
  display: flex;
  align-items: center;
  gap: 12px;
  color: white;
}

.pwa-banner-icon {
  flex-shrink: 0;
}

.pwa-banner-text {
  flex: 1;
  min-width: 0;
}

.pwa-banner-title {
  font-weight: 600;
  font-size: 16px;
  margin-bottom: 4px;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.pwa-banner-subtitle {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.3;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.pwa-banner-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

/* PWA Buttons */
.pwa-btn {
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  padding: 8px 12px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.pwa-btn-primary {
  background: rgba(255, 255, 255, 0.15);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(10px);
}

.pwa-btn-primary:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(255, 255, 255, 0.2);
}

.pwa-btn-secondary {
  background: rgba(0, 0, 0, 0.2);
  color: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.pwa-btn-secondary:hover {
  background: rgba(0, 0, 0, 0.3);
  color: white;
}

/* Modal Styles */
.pwa-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.8);
  z-index: 10001;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.pwa-modal-overlay.show {
  opacity: 1;
  visibility: visible;
}

.pwa-modal {
  background: linear-gradient(135deg, #1a1a2e, #16213e);
  border-radius: 16px;
  max-width: 400px;
  width: 90%;
  max-height: 80vh;
  overflow: hidden;
  transform: scale(0.9);
  transition: transform 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.pwa-modal-overlay.show .pwa-modal {
  transform: scale(1);
}

.pwa-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.pwa-modal-title {
  color: white;
  font-size: 18px;
  font-weight: 600;
  margin: 0;
}

.pwa-modal-body {
  padding: 20px;
  color: white;
}

/* Instructions */
.pwa-instructions {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.pwa-step {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.pwa-step-number {
  background: linear-gradient(135deg, #d1121f, #ff3131);
  color: white;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
  flex-shrink: 0;
}

.pwa-step-text {
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.4;
  font-size: 14px;
}

/* Update Notification */
.pwa-update-notification {
  position: fixed;
  top: 20px;
  left: 20px;
  right: 20px;
  background: linear-gradient(135deg, #2196F3, #1976D2);
  color: white;
  padding: 16px;
  border-radius: 12px;
  z-index: 10002;
  transform: translateY(-200%);
  transition: transform 0.4s ease;
  box-shadow: 0 8px 32px rgba(33, 150, 243, 0.3);
}

.pwa-update-notification.show {
  transform: translateY(0);
}

/* Mobile Adjustments */
@media (max-width: 768px) {
  .pwa-banner {
    bottom: 80px;  /* Espaço menor no mobile */
    left: 10px;
    right: 10px;
    padding: 14px;
  }
  
  .pwa-banner-content {
    gap: 10px;
  }
  
  .pwa-banner-title {
    font-size: 15px;
  }
  
  .pwa-banner-subtitle {
    font-size: 12px;
  }
  
  .pwa-btn {
    font-size: 12px;
    padding: 6px 10px;
  }
  
  .pwa-modal {
    width: 95%;
  }
  
  .pwa-modal-header,
  .pwa-modal-body {
    padding: 16px;
  }
}