/* TipTap editor styles */

/* Editor content area */
.tiptap-editor-area .tiptap {
  min-height: 200px;
  padding: 0.75rem 1rem;
  outline: none;
  font-size: 0.875rem;
  line-height: 1.625;
}

/* Placeholder when editor is empty */
.tiptap-editor-area .tiptap p.is-editor-empty:first-child::before {
  content: "Start writing...";
  color: #9ca3af;
  float: left;
  height: 0;
  pointer-events: none;
}

/* Typography inside editor */
.tiptap-editor-area .tiptap h1 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 1rem 0 0.5rem;
  line-height: 1.3;
}

.tiptap-editor-area .tiptap h2 {
  font-size: 1.25rem;
  font-weight: 600;
  margin: 0.875rem 0 0.375rem;
  line-height: 1.3;
}

.tiptap-editor-area .tiptap h3 {
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0.75rem 0 0.375rem;
  line-height: 1.3;
}

.tiptap-editor-area .tiptap p {
  margin: 0.5rem 0;
}

.tiptap-editor-area .tiptap ul {
  list-style: disc;
  padding-left: 1.5rem;
  margin: 0.5rem 0;
}

.tiptap-editor-area .tiptap ol {
  list-style: decimal;
  padding-left: 1.5rem;
  margin: 0.5rem 0;
}

.tiptap-editor-area .tiptap li {
  margin: 0.25rem 0;
}

.tiptap-editor-area .tiptap blockquote {
  border-left: 3px solid #d1d5db;
  padding-left: 1rem;
  margin: 0.75rem 0;
  color: #6b7280;
  font-style: italic;
}

.tiptap-editor-area .tiptap pre {
  background: #1f2937;
  color: #e5e7eb;
  border-radius: 0.375rem;
  padding: 0.75rem 1rem;
  margin: 0.75rem 0;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.8125rem;
  overflow-x: auto;
}

.tiptap-editor-area .tiptap code {
  background: #f3f4f6;
  border-radius: 0.25rem;
  padding: 0.125rem 0.25rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.8125rem;
}

.tiptap-editor-area .tiptap pre code {
  background: none;
  padding: 0;
  border-radius: 0;
  color: inherit;
}

.tiptap-editor-area .tiptap a {
  color: #c8944a;
  text-decoration: underline;
  cursor: pointer;
}

.tiptap-editor-area .tiptap hr {
  border: none;
  border-top: 1px solid #e5e7eb;
  margin: 1rem 0;
}

.tiptap-editor-area .tiptap s {
  text-decoration: line-through;
}

/* Topic links in editor and rendered notes */
.tiptap-editor-area .tiptap a.topic-link,
.prose a.topic-link {
  color: #5c3a24;
  background: #c5c9be;
  border-radius: 0.25rem;
  padding: 0.125rem 0.375rem;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.875rem;
}

.tiptap-editor-area .tiptap a.topic-link:hover,
.prose a.topic-link:hover {
  background: #8a917e;
  color: #f0ebe0;
}
