/* ============================================================
   Feedback widget — standalone, no build step required.
   Mirrors icapital-website-frontend's Feedback.js: floating
   button -> dialog with name/message/attachment -> submit.
   ============================================================ */

.feedback-widget-fab {
  position: fixed;
  left: 16px;
  bottom: 16px;
  z-index: 40;
  border: 0;
  border-radius: 999px;
  background: var(--navy, #0d2440);
  color: #fff;
  cursor: pointer;
  box-shadow: var(--sh-md, 0 8px 24px -8px rgba(13, 36, 64, .12));
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px 12px 14px;
  font-family: var(--sans, sans-serif);
}

.feedback-widget-fab:hover {
  background: var(--navy-2, #123153);
}

.feedback-widget-fab__icon {
  font-size: 1.2rem;
  line-height: 1;
}

.feedback-widget-fab__label {
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
}

@media (max-width: 480px) {
  .feedback-widget-fab {
    left: 10px;
    bottom: 10px;
    padding: 10px 14px 10px 12px;
  }
  .feedback-widget-fab__label { display: none; }
}

.feedback-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 70;
  background: rgba(8, 26, 48, .45);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  font-family: var(--sans, sans-serif);
}

.feedback-modal {
  background: var(--paper, #fff);
  border-radius: var(--r, 12px);
  box-shadow: var(--sh-lg, 0 20px 48px -12px rgba(13, 36, 64, .3));
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
}

.feedback-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background: var(--paper-2, #f7f8fa);
  border-bottom: 1px solid var(--rule, #e3e8ef);
  border-radius: var(--r, 12px) var(--r, 12px) 0 0;
  font-weight: 700;
  color: var(--ink, #1f2b3d);
  text-transform: uppercase;
  font-size: 0.95rem;
  letter-spacing: .03em;
}

.feedback-modal__header-close {
  appearance: none;
  border: 0;
  background: none;
  cursor: pointer;
  font-size: 1.4rem;
  line-height: 1;
  color: var(--faint, #8a97a9);
  padding: 4px;
}

.feedback-modal__header-close:hover {
  color: var(--ink, #1f2b3d);
}

.feedback-modal__body {
  padding: 20px;
}

.feedback-modal__desc {
  font-size: 0.85rem;
  color: var(--muted, #5c6b80);
  margin: 0 0 16px;
}

.feedback-modal__field {
  margin-bottom: 14px;
}

.feedback-modal__field label {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ink, #1f2b3d);
  margin-bottom: 4px;
}

.feedback-modal__field input[type="text"],
.feedback-modal__field textarea {
  width: 100%;
  box-sizing: border-box;
  font-family: inherit;
  font-size: 0.9rem;
  padding: 8px 10px;
  border: 1px solid var(--rule, #e3e8ef);
  border-radius: var(--r-sm, 8px);
  color: var(--ink, #1f2b3d);
  background: var(--paper, #fff);
}

.feedback-modal__field input[disabled] {
  background: var(--paper-3, #f0f2f6);
  color: var(--muted, #5c6b80);
}

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

.feedback-modal__field--file {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.feedback-modal__file-btn {
  appearance: none;
  border: 1px solid var(--navy, #0d2440);
  background: none;
  color: var(--navy, #0d2440);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--r-sm, 8px);
  cursor: pointer;
}

.feedback-modal__file-name {
  font-size: 0.78rem;
  color: var(--muted, #5c6b80);
}

.feedback-modal__error {
  font-size: 0.78rem;
  color: var(--red, #c8102e);
  margin-top: 4px;
}

.feedback-modal__note {
  font-size: 0.85rem;
  min-height: 1.2em;
  margin-top: 8px;
}

.feedback-modal__note.is-error { color: var(--red, #c8102e); }
.feedback-modal__note.is-success { color: #1e7e34; }

.feedback-modal__footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 0 20px 20px;
}

.feedback-modal__btn {
  appearance: none;
  border: 0;
  font-weight: 700;
  letter-spacing: .03em;
  padding: 9px 22px;
  border-radius: var(--r-sm, 8px);
  cursor: pointer;
}

.feedback-modal__btn--cancel {
  background: var(--paper-3, #f0f2f6);
  color: var(--ink, #1f2b3d);
}

.feedback-modal__btn--submit {
  background: var(--rw-blue, #1976d2);
  color: #fff;
}

.feedback-modal__btn:disabled {
  opacity: .6;
  cursor: default;
}

@media (max-width: 480px) {
  .feedback-modal__body,
  .feedback-modal__footer {
    padding-left: 14px;
    padding-right: 14px;
  }
}
