/* Selector accesible de valoración del formulario de reseñas. */
#post-product-comment-modal .product-cover {
  display: block;
  width: 100%;
  height: auto;
  min-height: 0;
  margin: 0;
}

#post-product-comment-modal .product-cover img,
#post-product-comment-modal .product-cover .js-qv-product-cover {
  display: block;
  width: 100% !important;
  height: auto !important;
  min-height: 0;
  object-fit: contain;
}

#post-product-comment-form .accessible-review-rating {
  display: flex !important;
  flex-flow: row wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 2px;
  width: 100%;
  min-width: 0;
  margin: 0 0 16px;
  padding: 0;
  border: 0;
}

#post-product-comment-form .accessible-review-rating legend {
  flex: 0 0 100%;
  width: 100%;
  margin: 0 0 8px;
  padding: 0;
  color: #1f1d1a;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
}

#post-product-comment-form .accessible-review-rating-option {
  position: relative;
  display: block;
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  margin: 0;
  padding: 0;
}

/* El radio permanece enfocable y operable, pero queda oculto visualmente. */
#post-product-comment-form .accessible-review-rating-option > input[type="radio"] {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  margin: -1px !important;
  padding: 0 !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

#post-product-comment-form .accessible-review-rating-option > label {
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 44px;
  height: 44px;
  margin: 0;
  padding: 0;
  color: #5d6a70;
  background: transparent;
  border: 2px solid transparent;
  border-radius: 3px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 32px;
  line-height: 1;
  cursor: pointer;
}

/* Pinta la estrella elegida y todas las anteriores. */
#post-product-comment-form .accessible-review-rating-option:has(input:checked) > label,
#post-product-comment-form .accessible-review-rating-option:has(~ .accessible-review-rating-option input:checked) > label {
  color: #a44728;
  background: #f7eee8;
}

/* Previsualiza la puntuación al pasar el ratón. */
#post-product-comment-form .accessible-review-rating:has(.accessible-review-rating-option:hover)
  .accessible-review-rating-option > label {
  color: #5d6a70;
  background: transparent;
}
#post-product-comment-form .accessible-review-rating-option:hover > label,
#post-product-comment-form .accessible-review-rating-option:has(~ .accessible-review-rating-option:hover) > label {
  color: #8f351c !important;
  background: #f7eee8 !important;
}

#post-product-comment-form .accessible-review-rating-option > input[type="radio"]:focus-visible + label {
  outline: 3px solid #111 !important;
  outline-offset: 2px;
}

@media (forced-colors: active) {
  #post-product-comment-form .accessible-review-rating-option:has(input:checked) > label,
  #post-product-comment-form .accessible-review-rating-option:has(~ .accessible-review-rating-option input:checked) > label {
    color: Highlight;
  }
  #post-product-comment-form .accessible-review-rating-option > input[type="radio"]:focus-visible + label {
    outline-color: Highlight !important;
  }
}
