/*
PEP 723 Widget Styles
*/

.pep723-container {
  padding: 16px;
  font-family: var(--jp-ui-font-family);
  height: 100%;
  overflow-y: auto;
  box-sizing: border-box;
}

.pep723-error {
  background: var(--jp-error-color3);
  border: 1px solid var(--jp-error-color1);
  border-radius: 4px;
  padding: 16px;
  margin: 16px 0;
}

.pep723-error .error-icon {
  font-size: 24px;
  margin-bottom: 8px;
}

.pep723-error h3 {
  color: var(--jp-error-color1);
  margin: 0 0 8px;
}

.pep723-error .error-help {
  margin-top: 16px;
  font-size: 0.9em;
}

.pep723-init {
  background: var(--jp-info-color3);
  border: 1px solid var(--jp-info-color2);
  border-radius: 4px;
  padding: 16px;
  margin: 16px 0;
}

.pep723-init .init-icon {
  font-size: 24px;
  margin-bottom: 8px;
}

.pep723-init h3 {
  color: var(--jp-info-color1);
  margin: 0 0 8px;
}

.pep723-init .init-help {
  margin: 16px 0;
  font-size: 0.9em;
}

.init-btn {
  padding: 12px 24px;
  background: var(--jp-brand-color1);
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
  transition: background-color 0.2s;
  margin: 16px 0 8px;
}

.init-btn:disabled {
  background: var(--jp-layout-color3);
  cursor: not-allowed;
}

.init-btn:hover:not(:disabled) {
  background: var(--jp-brand-color0);
}

.notebook-info {
  background: var(--jp-layout-color2);
  padding: 12px;
  border-radius: 4px;
  margin: 16px 0;
}

.metadata-section {
  margin: 16px 0;
}

.current-metadata pre {
  background: var(--jp-layout-color1);
  border: 1px solid var(--jp-border-color1);
  border-radius: 4px;
  padding: 12px;
  overflow-x: auto;
  font-family: var(--jp-code-font-family);
}

.dependency-form {
  background: var(--jp-layout-color2);
  padding: 16px;
  border-radius: 4px;
  margin: 16px 0;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.dependency-input {
  padding: 8px 12px;
  border: 1px solid var(--jp-border-color1);
  border-radius: 4px;
  font-size: 14px;
  background: var(--jp-input-background);
  color: var(--jp-ui-font-color1);
}

.dependency-input:focus {
  outline: none;
  border-color: var(--jp-brand-color1);
  box-shadow: 0 0 0 2px var(--jp-brand-color3);
}

.add-dependency-btn {
  padding: 8px 16px;
  background: var(--jp-brand-color1);
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  transition: background-color 0.2s;
}

.add-dependency-btn:disabled {
  background: var(--jp-layout-color3);
  cursor: not-allowed;
}

.add-dependency-btn:hover:not(:disabled) {
  background: var(--jp-brand-color0);
}

.status-message {
  padding: 8px;
  border-radius: 4px;
  font-size: 14px;
  min-height: 20px;
}

.status-message.success {
  background: var(--jp-success-color3);
  color: var(--jp-success-color1);
  border: 1px solid var(--jp-success-color2);
}

.status-message.error {
  background: var(--jp-error-color3);
  color: var(--jp-error-color1);
  border: 1px solid var(--jp-error-color2);
}

.status-message.loading {
  background: var(--jp-info-color3);
  color: var(--jp-info-color1);
  border: 1px solid var(--jp-info-color2);
}

.tree-section {
  margin: 16px 0;
}

.tree-content {
  background: var(--jp-layout-color1);
  border: 1px solid var(--jp-border-color1);
  border-radius: 4px;
  padding: 12px;
  max-height: 300px;
  overflow-y: auto;
  font-family: var(--jp-code-font-family);
}

.tree-content pre {
  margin: 0;
  white-space: pre-wrap;
  word-wrap: break-word;
}

.tree-content.unlocked {
  color: var(--jp-ui-font-color2);
  background: var(--jp-layout-color2);
}

.tree-content.unlocked pre {
  color: var(--jp-ui-font-color2);
}

.lock-btn {
  margin-top: 8px;
  padding: 6px 12px;
  border: 1px solid var(--jp-border-color1);
  border-radius: 4px;
  font-size: 12px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.lock-btn.lock {
  background: var(--jp-success-color3);
  color: var(--jp-success-color1);
  border-color: var(--jp-success-color2);
}

.lock-btn.lock:hover {
  background: var(--jp-success-color2);
}

.lock-btn.unlock {
  background: var(--jp-warn-color3);
  color: var(--jp-warn-color1);
  border-color: var(--jp-warn-color2);
}

.lock-btn.unlock:hover {
  background: var(--jp-warn-color2);
}
