/* Museum Survey - Frontend Styles */

.museum-survey-wrapper {
  max-width: 800px;
  margin: 0 auto;
}

/* Survey Messages */
.museum-survey-message {
  padding: 30px;
  border-radius: 8px;
  text-align: center;
  animation: fadeIn 0.5s;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.survey-success {
  background: #d4edda;
  border: 2px solid #28a745;
  color: #155724;
}

.survey-success h3 {
  margin-top: 0;
  color: #155724;
  font-size: 24px;
}

.survey-error {
  background: #f8d7da;
  border: 2px solid #dc3545;
  color: #721c24;
}

.survey-error h3 {
  margin-top: 0;
  color: #721c24;
  font-size: 24px;
}

/* Prize Message */
.survey-prize {
  margin-top: 20px;
  padding: 20px;
  background: #fff3cd;
  border: 2px solid #ffc107;
  border-radius: 8px;
  color: #856404;
}

.prize-icon {
  font-size: 48px;
  margin: 10px 0;
}

.survey-prize p {
  margin: 10px 0;
  font-size: 18px;
  font-weight: bold;
}

/* Loading State */
.survey-loading {
  text-align: center;
  padding: 40px;
  font-size: 18px;
  color: #666;
}

.survey-loading:after {
  content: "...";
  animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {
  0%,
  20% {
    content: ".";
  }
  40% {
    content: "..";
  }
  60%,
  100% {
    content: "...";
  }
}

/* Retry Button */
.survey-retry {
  margin-top: 15px;
  padding: 10px 30px;
  background: #007bff;
  color: white;
  border: none;
  border-radius: 5px;
  font-size: 16px;
  cursor: pointer;
  transition: background 0.3s;
}

.survey-retry:hover {
  background: #0056b3;
}

/* Survey.js Custom Styling */
.sv-root-modern {
  --primary-color: #0066cc;
  --secondary-color: #f5f5f5;
  --error-color: #dc3545;
}

/* Responsive */
@media (max-width: 768px) {
  .museum-survey-wrapper {
    padding: 10px;
    margin: 20px auto;
  }

  .museum-survey-message {
    padding: 20px;
  }

  .survey-success h3,
  .survey-error h3 {
    font-size: 20px;
  }

  .survey-prize p {
    font-size: 16px;
  }
}

/* Survey Form Styling */
.survey-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.survey-page {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.survey-element {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.survey-question-title {
  font-weight: 600;
  font-size: 16px;
  color: #333;
  margin-bottom: 5px;
}

.survey-required {
  color: #dc3545;
}

.survey-element-description {
  font-size: 14px;
  color: #666;
  margin-bottom: 5px;
}

.survey-input-text,
.survey-textarea {
  padding: 10px 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
  font-family: inherit;
  transition: border-color 0.3s;
}

.survey-input-text:focus,
.survey-textarea:focus {
  outline: none;
  border-color: #0066cc;
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.survey-textarea {
  resize: vertical;
  min-height: 100px;
}

.survey-rating {
  display: flex;
  gap: 15px;
  margin-top: 10px;
}

.survey-rating-item {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 8px 12px;
  border-radius: 4px;
  border: 1px solid #ddd;
  transition: all 0.2s;
}

.survey-rating-item:hover {
  border-color: #0066cc;
  background-color: #f0f5ff;
}

.survey-rating-item input[type="radio"] {
  cursor: pointer;
}

.survey-rating-item input[type="radio"]:checked + .survey-rating-value {
  color: #0066cc;
  font-weight: 600;
}

.survey-rating-value {
  font-weight: 500;
  color: #333;
}

.survey-button-submit {
  padding: 12px 30px;
  background-color: #0066cc;
  color: white;
  border: none;
  border-radius: 4px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.3s;
  align-self: flex-start;
  margin-top: 10px;
}

.survey-button-submit:hover {
  background-color: #0052a3;
}

.survey-button-submit:active {
  transform: scale(0.98);
}

.survey-loading {
  text-align: center;
  padding: 40px;
  font-size: 18px;
  color: #666;
}
