.feedback-modal-backdrop {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 12500;
  background: rgba(10, 23, 30, 0.48);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: clamp(14px, 3vw, 30px);
}

.feedback-modal-backdrop.is-open {
  display: flex;
}

.feedback-modal {
  width: min(520px, 96vw);
  background: radial-gradient(circle at 0 0, #0f172a 0%, #020617 55%, #020617 100%);
  border: 1px solid rgba(148, 163, 184, 0.4);
  border-radius: 18px;
  box-shadow:
    0 26px 80px rgba(15, 23, 42, 0.75),
    inset 0 0 0 1px rgba(255, 255, 255, 0.03);
  color: #e5e7eb;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
}

.feedback-modal-header {
  padding: 16px clamp(18px, 3vw, 22px);
  border-bottom: 1px solid rgba(148, 163, 184, 0.3);
}

.feedback-modal-header-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.feedback-modal-badge {
  margin: 0;
}

.feedback-modal-close {
  border: none;
  background: rgba(15, 23, 42, 0.65);
  color: #9ca3af;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  cursor: pointer;
  transition: background 180ms ease, color 180ms ease, transform 200ms ease;
}

.feedback-modal-close:hover {
  background: rgba(15, 23, 42, 0.85);
  color: #e5e7eb;
}

.feedback-modal-close:active {
  transform: translateY(1px);
}

.feedback-modal-title {
  margin: 0px 0 0;
  font-size: 20px;
  letter-spacing: 0.01em;
}

.feedback-helper {
  margin: 8px 0 0;
  color: #9ca3af;
  font-size: 13px;
  line-height: 1.45;
}

.feedback-modal-body {
  padding: clamp(16px, 3vw, 22px);
  font-size: 14px;
  line-height: 1.5;
  color: #cbd5e1;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.feedback-body-views,
.feedback-header-views {
  position: relative;
}

.feedback-header-views {
  min-height: 110px;
}

.feedback-view {
  transition: opacity 200ms ease-out, transform 200ms ease-out;
}

.feedback-view[aria-hidden="true"] {
  opacity: 0;
  transform: translateY(8px);
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.feedback-view[aria-hidden="false"] {
  opacity: 1;
  transform: translateY(0);
  position: relative;
  display: contents;
}

.feedback-modal-body .feedback-view {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.feedback-form-fields {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.feedback-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.feedback-label {
  font-size: 13px;
  font-weight: 600;
  color: #e5e7eb;
  letter-spacing: 0.01em;
}

.feedback-input,
.feedback-textarea {
  max-width: 100%;
  padding: 11px 12px;
  border-radius: 10px;
  border: 1px solid #4b5563;
  background: #020617;
  color: #e5e7eb;
  font-size: 14px;
  transition: border 140ms ease, box-shadow 140ms ease;
}

.feedback-score-scale {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.feedback-score-options {
  display: grid;
  grid-template-columns: repeat(11, minmax(0, 1fr));
  gap: 8px;
}

.feedback-score-option {
  border-radius: 10px;
  border: 1px solid #3b4456;
  background: linear-gradient(180deg, #0b1220, #040814);
  color: #e5e7eb;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  transition: border 150ms ease, box-shadow 150ms ease, background 150ms ease, transform 120ms ease;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02);
}

.feedback-score-option:hover {
  border-color: #6b7280;
  box-shadow:
    0 0 0 1px rgba(226, 232, 240, 0.08),
    0 12px 30px rgba(3, 7, 18, 0.6),
    0 0 0 6px rgba(34, 211, 238, 0.1);
}

.feedback-score-option:active {
  transform: translateY(1px);
}

.feedback-score-option:focus-visible {
  outline: 2px solid #22d3ee;
  outline-offset: 2px;
  box-shadow:
    0 0 0 1px rgba(34, 211, 238, 0.4),
    0 0 0 6px rgba(34, 211, 238, 0.14);
}

.feedback-score-option.is-selected {
  border-color: #22d3ee;
  background: linear-gradient(180deg, rgba(34, 211, 238, 0.2), rgba(34, 211, 238, 0.08));
  color: #e0f2fe;
  box-shadow:
    0 0 0 1px rgba(34, 211, 238, 0.55),
    0 18px 40px rgba(34, 211, 238, 0.12);
}

.feedback-score-hints {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 4px;
}

.feedback-score-hint {
  color: #9ca3af;
  font-size: 10px;
  letter-spacing: 0.5px;
  line-height: 1.4;
  opacity: 0.92;
  display: inline-flex;
  align-items: center;
}

.feedback-score-hint-left {
  text-align: left;
}

.feedback-score-hint-right {
  text-align: right;
}

.feedback-score-hints .feedback-score-hint + .feedback-score-hint {
  margin-left: auto;
}

@media (max-width: 480px) {
  .feedback-score-options {
    grid-template-columns: repeat(auto-fit, minmax(44px, 1fr));
  }
}

.feedback-input:focus,
.feedback-textarea:focus {
  outline: none;
  border-color: rgba(56, 189, 248, 0.6);
  box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.25);
}

.feedback-textarea {
  min-height: 96px;
  resize: vertical;
}

.feedback-error {
  color: #f97373;
  font-size: 11px;
  margin-top: 6px;
}

.feedback-inline-hint {
  color: #9ca3af;
  font-size: 12px;
}

.feedback-alert {
  display: none;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(248, 113, 113, 0.4);
  background: rgba(248, 113, 113, 0.08);
  color: #fecdd3;
  font-size: 13px;
  line-height: 1.45;
}

.feedback-alert.is-visible {
  display: block;
}

.feedback-modal-footer {
  padding: 12px clamp(18px, 3vw, 22px) 16px;
  border-top: 1px solid rgba(148, 163, 184, 0.28);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.65), rgba(2, 6, 23, 0.85));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.feedback-actions {
  display: flex;
  gap: 10px;
}

.feedback-submit-btn {
  position: relative;
}

.feedback-spinner {
  display: none;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(226, 232, 240, 0.4);
  border-top-color: #e2e8f0;
  border-radius: 50%;
  animation: feedback-spin 0.9s linear infinite;
}

.feedback-submit-btn.is-loading .feedback-spinner {
  display: inline-flex;
}

.feedback-submit-btn.is-loading .feedback-submit-icon {
  display: none;
}

.feedback-success-footer {
  justify-content: flex-end;
}

.feedback-body-views {
  min-height: 230px;
}

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

body.feedback-modal-open {
  overflow: hidden;
}