/**
 * @file
 * Styles for the content rating form - Using main.css for page-opinion styling.
 */

/* Hidden rating container for functionality */
.rating-container.d-none {
  display: none !important;
}

/* Rating stats integration */
.rating-stats {
  background: var();
  padding: 10px 15px;
  margin-bottom: 15px;
  border-radius: 4px;
}

.rating-stats p {
  margin: 5px 0;
  font-size: 0.9em;
}

.rating-stats strong {
  color: var(--gray-500);;
}

/* Rating message styling */
.rating-message {
  padding: 12px 15px;
  border-radius: 6px;
  margin-bottom: 15px;
  animation: slideInFromTop 0.5s ease-out;
  font-weight: 500;
}

.rating-already-voted {
  background: #d4edda;
  border: 1px solid #c3e6cb;
  color: #155724;
}

/* Star rating display */
.rating-stars-display {
  text-align: center;
  margin-bottom: 15px;
}

.stars-container {
  display: inline-block;
  margin-bottom: 10px;
}

.star {
  font-size: 1.5em;
  color: #ffc107;
  margin: 0 2px;
}

.star-empty {
  color: #e9ecef;
}

.rating-summary {
  font-size: 0.9em;
  color: #6c757d;
}

.star-rating-text {
  font-weight: 500;
}

/* Debug info styling */
.rating-debug-info {
  background: #f0f0f0;
  padding: 8px;
  margin: 8px 0;
  font-size: 12px;
  border-left: 3px solid #007cba;
}

.rating-debug-info strong {
  color: #007cba;
}

/* Ajax throbber styling */
.ajax-progress {
  display: inline-block;
  padding: 1px 13px 1px 0;
}

.ajax-progress .throbber {
  display: inline-block;
  width: 15px;
  height: 15px;
  margin: 1px;
  border: 2px solid transparent;
  border-radius: 50%;
  border-top-color: #007bff;
  animation: spin 1s ease-in-out infinite;
}

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

/* Loading state */
.rating-form-updating {
  opacity: 0.7;
  pointer-events: none;
  position: relative;
}

.rating-form-updating::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 20px;
  height: 20px;
  border: 2px solid #28a745;
  border-top: 2px solid transparent;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  z-index: 10;
}

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

/* Form details styling */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.footer-form {
  animation: fadeInUp 0.3s ease-out;
}

.footer-form .form-check-input:checked + label {
  background-color: #1b8354;
  color: #ffffff;
  border-radius: 4px;
  padding: 2px 8px;
}

.footer-form .gender-options label {
  margin: 0 10px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.footer-form .gender-options label:hover {
  background-color: transparent;
}

.footer-form .gender-options label.selected {
  background-color: transparent;

}

.footer-form textarea.focused {
  border-color: #2196f3;
  box-shadow: 0 0 0 0.2rem rgba(33, 150, 243, 0.25);
}

/* Validation errors styling */
.validation-errors {
  animation: fadeInUp 0.3s ease-out;
}

.validation-errors ul {
  padding-left: 1.5rem;
}

.validation-errors li {
  margin: 0.25rem 0;
}
.footer-form .form-heading span{
  color:var(--gray-500);
}
.page-opinion .gender-options input[type="radio"] {
    width: 24px;
    height: 24px;
    cursor: pointer;
}
.gender-selection{
  margin-top: 32px;
  margin-bottom: 32px;
}
.footer-form .form-check-input {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  width: 24px;
  height: 24px;
  border: 1px solid var(--gray-500);
  background-color: var(--white);;
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  cursor: pointer;
  flex-shrink: 0;
  margin-top: 0;
}

.footer-form .form-check-input[type="radio"] {
  border-radius: 50%;
}

.footer-form .form-check-input:checked[type="checkbox"] {
  border-color: #1b8354;
  background-color: #1b8354;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='M6 10l3 3 6-6'/%3E%3C/svg%3E");
}

.footer-form .form-check-input:checked[type="radio"] {
  border-color: #1b8354;
  background-color: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle fill='%231b8354' cx='10' cy='10' r='6'/%3E%3C/svg%3E");
} 