.rich-text p { margin: 0 0 0.7em; }
.rich-text p:last-child { margin-bottom: 0; }
.rich-text ul,
.rich-text ol { margin: 0.45em 0 0.45em 1.2em; padding: 0; }
.rich-text li { margin: 0.15em 0; }
.rich-text a { color: #6d4dff; text-decoration: underline; }
.rich-text h2,
.rich-text h3,
.rich-text h4 { margin: 0.8em 0 0.4em; font-weight: 700; color: #24165f; line-height: 1.3; }
.rich-text h2 { font-size: 1.2em; }
.rich-text h3 { font-size: 1.08em; }
.rich-text blockquote {
  margin: 0.6em 0;
  padding: 0.35em 0.8em;
  border-left: 3px solid #6d4dff;
  color: #475569;
}
.rich-text table { width: 100%; border-collapse: collapse; margin: 0.7em 0; }
.rich-text th,
.rich-text td { border: 1px solid #e2e8f0; padding: 0.4em 0.6em; text-align: left; }
.rich-text th { background: #f8fafc; font-weight: 600; }
.rich-text-inline p { display: inline; margin: 0; }
.rich-text sub,
.rich-text sup { font-size: 0.75em; }

/* Keep TinyMCE usable with Tailwind's preflight resets. */
.tox-tinymce {
  border: 1px solid #e2e8f0 !important;
  border-radius: 0.5rem !important;
  width: 100% !important;
  z-index: 20;
}
.tox .tox-editor-header,
.tox .tox-toolbar,
.tox .tox-toolbar__primary,
.tox .tox-menubar {
  background: #f8fafc !important;
}
.tox .tox-tbtn,
.tox .tox-tbtn--select,
.tox button {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: transparent !important;
  background-image: none !important;
  border: 0 !important;
  box-shadow: none !important;
  color: #334155 !important;
  padding: 0 !important;
  margin: 0 !important;
  min-width: 34px !important;
  height: 34px !important;
  cursor: pointer !important;
}
.tox .tox-tbtn:hover,
.tox .tox-tbtn--enabled {
  background: #e2e8f0 !important;
}
.tox .tox-tbtn svg {
  display: block !important;
  width: 20px !important;
  height: 20px !important;
  fill: currentColor !important;
}
.tox .tox-tbtn svg path {
  fill: currentColor !important;
}
.tox .tox-split-button {
  display: inline-flex !important;
}
.tox .tox-toolbar__group {
  display: flex !important;
  align-items: center !important;
}
