/* Modal Overlay */
.modalOverlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--ifm-background-color);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  z-index: 10000;
  padding: 2rem 1rem;
  overflow-y: auto;
  animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* Modal Content */
.modalContent {
  background: var(--ifm-background-color);
  border: 1px solid var(--ifm-color-emphasis-200);
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
  max-width: 900px;
  width: 100%;
  max-height: calc(100vh - 4rem);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: slideUp 0.3s ease;
  position: relative;
  z-index: 1;
}

@keyframes slideUp {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Modal Header */
.modalHeader {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem;
  border-bottom: 1px solid var(--ifm-color-emphasis-200);
}

.modalTitle {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--ifm-heading-color);
}

.closeButton {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem;
  background: transparent;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  color: var(--ifm-color-emphasis-600);
  transition: all 0.15s ease;
}

.closeButton:hover {
  background: var(--ifm-color-emphasis-100);
  color: var(--ifm-color-emphasis-900);
}

/* Modal Body */
.modalBody {
  padding: 1.5rem;
  overflow-y: auto;
  flex: 1;
}

/* Troubleshoot Section */
.troubleshootSection {
  margin-bottom: 2rem;
}

.troubleshootTitle {
  margin: 0 0 0.75rem 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--ifm-heading-color);
}

.troubleshootDescription {
  margin: 0 0 1rem 0;
  font-size: 0.875rem;
  color: var(--ifm-color-emphasis-700);
  line-height: 1.6;
}

/* Prompt Wrapper */
.promptWrapper {
  border: 1px solid var(--ifm-color-emphasis-300);
  border-radius: 8px;
  overflow: hidden;
  background: var(--ifm-color-emphasis-100);
}

.promptLabel {
  padding: 0.5rem 0.75rem;
  background: var(--ifm-color-emphasis-200);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--ifm-color-emphasis-700);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.promptContent {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 0.75rem;
  background: var(--ifm-background-color);
  gap: 0.75rem;
}

.promptText {
  flex: 1;
  font-family: var(--ifm-font-family-monospace);
  font-size: 0.8125rem;
  color: var(--ifm-font-color-base);
  white-space: pre-wrap;
  word-break: break-word;
  line-height: 1.6;
  margin: 0;
}

.copyPromptButton {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem;
  border: 1px solid var(--ifm-color-emphasis-300);
  border-radius: 4px;
  background: var(--ifm-background-color);
  color: var(--ifm-font-color-base);
  cursor: pointer;
  transition: all 0.2s;
  font-size: 0.875rem;
  line-height: 1;
}

.copyPromptButton:hover {
  background: var(--ifm-color-emphasis-100);
  border-color: var(--ifm-color-primary);
}

.copyPromptButton:active {
  transform: scale(0.95);
}

/* IDE Selector Section */
.ideSelectorSection {
  border-top: 1px solid var(--ifm-color-emphasis-200);
  padding-top: 1.5rem;
}

/* Responsive */
@media (max-width: 768px) {
  .modalOverlay {
    padding: 1rem 0.5rem;
  }

  .modalContent {
    max-width: 100%;
    max-height: calc(100vh - 2rem);
    border-radius: 12px;
  }

  .modalHeader {
    padding: 1rem;
  }

  .modalTitle {
    font-size: 1.125rem;
  }

  .modalBody {
    padding: 1rem;
  }

  .promptContent {
    flex-direction: column;
    align-items: stretch;
  }

  .copyPromptButton {
    align-self: flex-end;
  }
}

