/**
 * Feedback Integration Styles
 *
 * Styles for integrating FeedbackVote components into settings pages.
 */

/* Setting with Feedback Container */
.prorank-setting-with-feedback {
  display: flex;
  align-items: flex-start;
  gap: var(--pr-spacing-medium, 16px);
  margin-bottom: var(--pr-spacing-large, 24px);
}

/* Ensure the setting control takes full width */
.prorank-setting-with-feedback > .components-base-control {
  flex: 1;
}

/* Align feedback component */
.prorank-setting-with-feedback .prorank-feedback-vote {
  flex-shrink: 0;
  margin-top: var(--pr-spacing-small, 8px);
}

/* For inline feedback (small screens) */
@media (width <= 782px) {
  .prorank-setting-with-feedback {
    flex-direction: column;
    align-items: flex-start;
  }

  .prorank-setting-with-feedback .prorank-feedback-vote {
    margin-top: var(--pr-spacing-medium, 16px);
    align-self: flex-start;
  }
}

/* Section-level Feedback */
.prorank-section-feedback {
  margin-top: var(--pr-spacing-xlarge, 32px);
  padding-top: var(--pr-spacing-large, 24px);
  border-top: 1px solid var(--pr-border-light, #e0e0e0);
}

.prorank-section-feedback .prorank-feedback-vote {
  margin: 0 auto;
}

/* Panel Body with Feedback */
.components-panel__body .prorank-feedback-vote {
  margin-top: var(--pr-spacing-medium, 16px);
  margin-bottom: var(--pr-spacing-small, 8px);
}

/* Feedback after help text */
.prorank-help-with-feedback {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: var(--pr-spacing-xsmall, 4px);
}

.prorank-help-with-feedback .components-base-control__help {
  flex: 1;
  margin-right: var(--pr-spacing-medium, 16px);
}

/* Tab panel feedback */
.prorank-tab-feedback {
  position: absolute;
  top: var(--pr-spacing-small, 8px);
  right: var(--pr-spacing-small, 8px);
}

/* Dark mode support */
.prorank-dark-theme .prorank-section-feedback {
  border-top-color: var(--pr-gray-700, #3f3f46);
}

/* High contrast mode */
@media (prefers-contrast: high) {
  .prorank-section-feedback {
    border-top-width: 2px;
  }
}
