:root {
  --primary-color: #9334ea;
  --text-color: #ffffff;
  --background-color: #ffffff;
  --card-radius: 20px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
  background-color: var(--background-color);
  min-height: 100vh;
}

.app {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Updated Header Styles */
header {
  background-color: var(--primary-color);
  color: var(--text-color);
  padding: 16px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position: relative;
  border-radius: 0 0 20px 20px;
}

.logo {
  font-size: 1.6rem;
  letter-spacing: -0.5px;
  font-weight: 500;
}

.balance {
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 20px;
  padding: 3px 19px;
  position: relative;
}

.balance-label {
  position: absolute;
  top: -10px;
  left: 6px;
  background: var(--primary-color);
  padding: 0 8px;
  font-size: 0.85rem;
  color: rgb(255, 255, 255);
}

.balance-value {
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.5px;
}

/* Main Content Styles */
main {
  flex: 1;
  padding: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  max-width: 450px;
  margin: 0 auto;
}

/* Updated Loading Styles */
.loading-container {
  display: flex;
  align-items: center;
  gap: 15px;
  margin: 10px 0;
  align-self: flex-start;
  width: 100%;
  max-width: 500px;
  padding-left: 20px;
  margin-bottom: 10px;
}

.loading-text {
  font-size: 0.9rem;
  color: var(--primary-color);
  margin: 0;
  text-align: left;
  font-weight: bold;
}

.loading-spinner {
  width: 30px;
  height: 30px;
  border: 3px solid #f3f3f3;
  border-top: 3px solid var(--primary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

.establishment-container {
  width: 100%;
  max-width: 500px;
  overflow: hidden;
  border-radius: var(--card-radius);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  margin-bottom: 20px;
}

#establishment-image {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.2s ease;
}

/* Feedback Container Styles */
.feedback-container {
  width: 100%;
  max-width: 500px;
  display: none;
  flex-direction: column;
  align-items: center;
  margin-top: 10px;
}

.establishment-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 20px;
}

.establishment-price {
  font-size: 1.8rem;
  color: var(--primary-color);
  font-weight: bold;
}

.establishment-name {
  font-size: 1.5rem;
  color: var(--primary-color);
  margin: 5px 0;
}

.establishment-rating {
  color: var(--primary-color);
  font-size: 1.2rem;
}

.feedback-questions {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 20px;
}

.feedback-question {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.feedback-question p {
  text-align: center;
  margin-bottom: 10px;
  font-weight: bold;
}

.rating-stars {
  display: flex;
  gap: 10px;
  margin-bottom: 5px;
}

.star {
  font-size: 2rem;
  color: #ccc;
  cursor: pointer;
}

.star.active {
  color: var(--primary-color);
}

.rating-labels {
  display: flex;
  justify-content: space-between;
  width: 100%;
  font-size: 0.8rem;
  color: #666;
}

.price-options {
  display: flex;
  gap: 20px;
}

.price-option {
  width: 60px;
  height: 40px;
  background-color: #f0f0f0;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 8px;
  cursor: pointer;
  font-weight: bold;
  color: #666;
}

.price-option.active {
  background-color: var(--primary-color);
  color: white;
}

.submit-feedback {
  background-color: #ccc;
  color: white;
  border: none;
  border-radius: 8px;
  padding: 15px 0;
  width: 100%;
  font-size: 1rem;
  font-weight: bold;
  cursor: pointer;
  margin-top: 10px;
  margin-bottom: 6rem;
}

.submit-feedback.active {
  background-color: var(--primary-color);
}

/* Footer Styles */
footer {
  display: flex;
  justify-content: space-between;
  padding: 10px 70px;
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: white;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
  z-index: 1000;
  border-top: solid 1px rgba(142, 142, 142, 0.656);

}

.footer-button {
  width: 60px;
  height: 60px;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
}

.icon {
  width: 40px;
  height: 40px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 2rem;
  color: var(--primary-color);
}

/* Animation for establishment selection */
@keyframes flash {
  0% {
    opacity: 1;
  }

  50% {
    opacity: 0.5;
  }

  100% {
    opacity: 1;
  }
}

.flashing {
  animation: flash 0.2s infinite;
}

@keyframes zoom {
  0% {
    transform: scale(1);
  }

  50% {
    transform: scale(0.95);
  }

  100% {
    transform: scale(1);
  }
}

.zooming {
  animation: zoom 0.3s infinite;
}

.selected {
  transform: scale(1.05);
  box-shadow: 0 0 20px rgba(142, 68, 173, 0.6);
}

/* Modal de Parabéns */
.congratulations-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--primary-color);
  z-index: 1000;
  overflow: auto;
}

.modal-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  height: 100%;
  text-align: center;
  color: white;
}

.success-icon {
  width: 80px;
  height: 80px;
  background-color: white;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 30px;
}

.checkmark {
  color: var(--primary-color);
  font-size: 2.5rem;
  font-weight: bold;
}

.modal-content h1 {
  font-size: 3rem;
  margin-bottom: 30px;
}

.modal-message {
  font-size: 1.2rem;
  margin-bottom: 30px;
  padding: 0 20px;
  line-height: 1.4;
}

.modal-instruction {
  font-size: 1.2rem;
  margin-bottom: 40px;
  padding: 0 20px;
  line-height: 1.4;
}

.watch-video-btn {
  background-color: white;
  color: var(--primary-color);
  border: none;
  border-radius: 30px;
  padding: 15px 40px;
  font-size: 1.2rem;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
}

.watch-video-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.3);
}