.tiptap-toolbar {
  display: flex;
  gap: 2px;
  padding: 4px;
  border: 1px solid #ddd;
  border-bottom: none;
  border-radius: 4px 4px 0 0;
  background: #f9f9f9;
}

.tiptap-toolbar-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: none;
  border-radius: 4px;
  background: transparent;
  cursor: pointer;
  color: #333;
}

.tiptap-toolbar-button:hover {
  background: #e0e0e0;
}

.tiptap-toolbar-separator {
  width: 1px;
  margin: 4px;
  background: #ddd;
}

.tiptap-editor {
  border: 1px solid #ddd;
  border-radius: 0 0 4px 4px;
}

.tiptap-editor .ProseMirror {
  min-height: 200px;
  padding: 12px;
  outline: none;
}

.tiptap-link-modal {
  /* Preflight zeroes every margin, taking the UA's `dialog { margin: auto }`
     centering with it — restore it so the modal centers on the viewport. */
  margin: auto;
  min-width: 20rem;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 16px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  background: var(--color-background, #fff);
  color: var(--color-foreground, inherit);
}

.tiptap-link-modal::backdrop {
  background: rgba(0, 0, 0, 0.4);
}

.tiptap-link-modal-content {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tiptap-link-modal-content input[type="url"] {
  padding: 6px 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.tiptap-link-modal-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

/* Prose styling for rendered content */
.prosemirror-content h1,
.tiptap-editor .ProseMirror h1 { font-size: 2em; font-weight: bold; margin: 0.67em 0; }

.prosemirror-content h2,
.tiptap-editor .ProseMirror h2 { font-size: 1.5em; font-weight: bold; margin: 0.75em 0; }

.prosemirror-content h3,
.tiptap-editor .ProseMirror h3 { font-size: 1.17em; font-weight: bold; margin: 0.83em 0; }

.prosemirror-content p,
.tiptap-editor .ProseMirror p { margin: 1em 0; }

.prosemirror-content ul,
.tiptap-editor .ProseMirror ul { list-style: disc; padding-left: 1.5em; }

.prosemirror-content ol,
.tiptap-editor .ProseMirror ol { list-style: decimal; padding-left: 1.5em; }

.prosemirror-content blockquote,
.tiptap-editor .ProseMirror blockquote { border-left: 3px solid #ddd; padding-left: 1em; margin-left: 0; color: #666; }

.prosemirror-content code,
.tiptap-editor .ProseMirror code { background: #f4f4f4; padding: 2px 4px; border-radius: 3px; font-family: monospace; }

.prosemirror-content img,
.tiptap-editor .ProseMirror img { max-width: 100%; height: auto; }

.prosemirror-content hr,
.tiptap-editor .ProseMirror hr { border: none; border-top: 1px solid #ddd; margin: 1em 0; }
