/* Enhanced Copy Button Styles */
.copy-button-container {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 10;
}

.copy-button {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 500;
  color: #374151;
  transition: all 0.2s ease;
  backdrop-filter: blur(4px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.copy-button:hover {
  background: #f9fafb;
  border-color: #4f46e5;
  color: #4f46e5;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.copy-button:active {
  transform: translateY(0);
}

.copy-button svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.copy-button.copy-success {
  background: #10b981;
  color: white;
  border-color: #10b981;
}

.copy-button.copy-error {
  background: #ef4444;
  color: white;
  border-color: #ef4444;
}

/* Notification System */
.copy-notifications-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1000;
  pointer-events: none;
}

.copy-notification {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 12px 16px;
  margin-bottom: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transform: translateX(100%);
  opacity: 0;
  transition: all 0.3s ease;
  pointer-events: auto;
  max-width: 300px;
}

.copy-notification.show {
  transform: translateX(0);
  opacity: 1;
}

.copy-notification-success {
  border-left: 4px solid #10b981;
}

.copy-notification-error {
  border-left: 4px solid #ef4444;
}

.notification-content {
  display: flex;
  align-items: center;
  gap: 8px;
}

.notification-icon {
  font-size: 16px;
  font-weight: bold;
}

.notification-message {
  font-size: 14px;
  color: #374151;
}

/* Note-specific styling */
.therapy-note {
  position: relative;
  padding: 20px;
  margin: 16px 0;
  background: #f8fafc;
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  font-family: "Courier New", "Monaco", monospace;
  font-size: 14px;
  line-height: 1.6;
  white-space: pre-wrap;
  word-wrap: break-word;
}

.therapy-note::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #4f46e5, #06b6d4);
  border-radius: 8px 8px 0 0;
}

/* Botpress message styling */
.bp-message.therapy-note {
  background: #f0f9ff;
  border: 2px solid #0ea5e9;
}

.bp-message.therapy-note::before {
  background: linear-gradient(90deg, #0ea5e9, #06b6d4);
}

/* Mobile responsiveness */
@media (max-width: 768px) {
  .copy-button {
    padding: 6px 10px;
    font-size: 11px;
  }

  .copy-button svg {
    width: 12px;
    height: 12px;
  }

  .copy-notifications-container {
    top: 10px;
    right: 10px;
    left: 10px;
  }

  .copy-notification {
    max-width: none;
  }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  .copy-button {
    border-width: 2px;
    font-weight: 600;
  }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
  .copy-button,
  .copy-notification {
    transition: none;
  }

  .copy-button:hover {
    transform: none;
  }
}

/* Print styles */
@media print {
  .copy-button-container,
  .copy-notifications-container {
    display: none !important;
  }
}
