.facts, .review-dialog { -webkit-tap-highlight-color: transparent; }
.rating-trigger {
  align-self: stretch; flex: 1; display: flex; flex-direction: column; align-items: center;
  gap: inherit; padding: 0 3px; border: 0; border-radius: 10px; background: transparent;
  font: inherit; cursor: pointer; touch-action: manipulation;
}
.rating-trigger:disabled { cursor: default; opacity: 1; }
.rating-trigger:focus-visible { outline: 2px solid #087af0; outline-offset: -2px; }

.review-dialog {
  width: min(calc(100% - 24px), 450px); max-height: calc(100% - 24px);
  padding: 0; border: 0; border-radius: 22px; color: #17191d; background: #fff;
  box-shadow: 0 16px 64px #1018283d;
}
.review-dialog::backdrop { background: #10182880; }
html:has(.review-dialog[open]) { overflow: hidden; }
.review-panel { position: relative; padding: clamp(18px, 6vw, 28px); }
.review-close {
  position: absolute; top: 12px; right: 12px; width: 44px; height: 44px;
  padding: 0; border: 0; border-radius: 50%; background: transparent; color: #494e58;
  font-size: 28px; cursor: pointer;
}
.review-form, .review-success { display: grid; gap: 14px; }
.review-form[hidden], .review-success[hidden] { display: none; }
.review-success p { padding-inline-end: 44px; }
.review-code-hint { color: #5e6673; font-size: 12px; line-height: 1.45; }
.review-score { min-width: 0; margin: 0; padding: 0; border: 0; }
.review-score legend, .review-field { padding: 0; font-size: 14px; font-weight: 650; }
.review-score legend { min-height: 34px; }
.review-score legend:focus { outline: none; }
.review-stars {
  display: flex; justify-content: center; align-items: center;
  gap: clamp(4px, 1.6vw, 8px); min-height: 56px; margin-top: 5px;
}
.review-stars label {
  position: relative; display: grid; place-items: center;
  flex: 0 1 48px; min-width: 0; height: 48px;
  border-radius: 9px; color: #737985; cursor: pointer; touch-action: manipulation;
}
.review-stars input {
  position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: inherit;
}
.review-stars svg {
  width: min(100%, 38px); height: 38px; fill: none; stroke: currentColor; stroke-width: 1.6;
  stroke-linejoin: round; pointer-events: none;
}
.review-stars label:has(input:checked) svg, .review-stars label:has(~ label input:checked) svg { fill: currentColor; }
.review-stars label:has(input:focus-visible), .review-dialog button:focus-visible {
  outline: 2px solid #087af0; outline-offset: 2px;
}
/* WebKit can propagate focus-visible during programmatic focus/restore after a tap. */
html[data-review-pointer] :is(.facts, .rating-trigger, .review-dialog button):focus-visible,
html[data-review-pointer] .review-stars label:has(input:focus-visible) { outline: none; }
.review-field { display: grid; gap: 6px; transition: color 180ms ease; }
.review-field:focus-within { color: #234f85; }
.review-field :is(input, textarea) {
  width: 100%; padding: 10px 12px; border: 1px solid #c9ced7; border-radius: 10px;
  background: #f9fafc; color: #17191d; caret-color: #234f85;
  font-family: inherit; font-size: 16px; font-weight: 400; line-height: 1.4;
  box-shadow: 0 0 0 0 #487bbd00, 0 2px 8px -4px #305c9300, inset 0 1px 2px #182c4a08;
  transition: background-color 180ms ease, border-color 180ms ease,
    box-shadow 240ms cubic-bezier(.2,.75,.25,1);
}
.review-field :is(input, textarea):focus {
  outline: none;
  background-color: #fff; border-color: #5076aa;
  box-shadow: 0 0 0 3px #487bbd24, 0 6px 16px -5px #305c9340, inset 0 1px 2px #182c4a00;
}
@media (prefers-reduced-motion: reduce) {
  .review-field, .review-field :is(input, textarea) { transition: none; }
}
@media (forced-colors: active) {
  .review-field :is(input, textarea):focus { outline: 2px solid Highlight; outline-offset: 2px; }
}
.review-field textarea { resize: none; min-height: 75px; }
.review-action {
  min-height: 44px; padding: 10px 20px; border: 0; border-radius: 100px;
  background: #0969cc; color: #fff; font: inherit; font-weight: 700; cursor: pointer;
}
@media (hover:hover) and (pointer:fine) { .review-action:hover { background: #075ab0; } }
.review-action:disabled { opacity: .65; cursor: wait; }
.review-error { color: #9f1f24; font-size: 14px; }
.review-error:empty { margin-top: -14px; }
