/*!***********************************************************************************************************************************************************************************************************************************************************************************!*\
  !*** css ./node_modules/next/dist/build/webpack/loaders/css-loader/src/index.js??ruleSet[1].rules[14].oneOf[10].use[2]!./node_modules/next/dist/build/webpack/loaders/postcss-loader/src/index.js??ruleSet[1].rules[14].oneOf[10].use[3]!./app/components/TipTap/core/Viewer.css ***!
  \***********************************************************************************************************************************************************************************************************************************************************************************/
/* Styles for TipTap Viewer component */
.tiptap-viewer {
  /* Ensure proper styling for read-only content */
  max-width: none !important;
}

.article-viewer {
  max-width: none !important;
}

.tiptap-viewer .ProseMirror {
  outline: none;
}

.tiptap-viewer .node-readonly {
  /* Styles for read-only nodes */
}

.tiptap-viewer .node-editable {
  /* This should not apply in viewer mode */
  display: none;
}

/* Chess board specific viewer styling */
.tiptap-viewer .chess-board-wrapper {
  /* Ensure clean chess board presentation in viewer */
  border: none !important;
  background: transparent !important;
}

.tiptap-viewer .chess-board-wrapper .group:hover {
  /* Remove hover effects and controls in viewer */
  border-color: transparent !important;
}

.tiptap-viewer .chess-board-wrapper .opacity-0 {
  /* Hide editor controls completely in viewer */
  display: none !important;
}

.tiptap-viewer [data-type="chessboard"] {
  /* Clean up any residual editor styling */
  border: none !important;
  padding: 0 !important;
  background: transparent !important;
}

.tiptap-viewer [data-type="chessboard"] .border-dashed {
  /* Remove dashed borders in viewer */
  border-style: solid !important;
  border-color: transparent !important;
}

/* Hide TipTap node selection styling in viewer mode */
.tiptap-viewer .ProseMirror-selectednode {
  outline: none !important;
  border: none !important;
  background: transparent !important;
}

.tiptap-viewer .node-view-wrapper.ProseMirror-selectednode {
  outline: none !important;
  border: none !important;
  background: transparent !important;
}

/* Remove hover effects in viewer */
.tiptap-viewer .group:hover {
  border-color: transparent !important;
  background: transparent !important;
}

/* Preserve paywall gradient on hover */
.tiptap-viewer .paywall-block.group:hover {
  background: linear-gradient(to bottom, rgb(168 85 247 / 0.05), rgb(168 85 247 / 0.1), rgb(168 85 247 / 0.05)) !important;
  border-color: rgb(168 85 247 / 0.2) !important;
}

/* Ensure no editor controls appear in viewer */
.tiptap-viewer .absolute.opacity-0 {
  display: none !important;
}

.tiptap-viewer .absolute.top-2.right-2 {
  display: none !important;
}

/* Editor mode: Prevent double borders on chess board components */
.node-editable .ProseMirror-selectednode {
  outline: none !important;
  box-shadow: none !important;
}

.node-editable [data-type="chessboard"] .ProseMirror-selectednode {
  border: none !important;
  outline: none !important;
}

/* Drag Handle Styling */
.drag-handle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  font-size: 1.125rem;
  line-height: 1;
  color: hsl(var(--muted-foreground));
  -webkit-user-select: none;
     -moz-user-select: none;
          user-select: none;
  cursor: grab;
  transition: all 150ms ease-in-out;
}

.drag-handle:hover {
  color: hsl(var(--foreground));
  background-color: hsl(var(--accent));
}

.drag-handle:active {
  cursor: grabbing !important;
}

/* Ensure tippy container for drag handle is visible */
.tippy-box[data-theme~='drag-handle'] {
  background-color: transparent;
  box-shadow: none;
}

.tippy-box[data-theme~='drag-handle'] .tippy-content {
  padding: 0;
}

/* Article content styling - Optimized Typography */
.article-content {
  line-height: 1.7;
  font-family: var(--font-sans);
  font-size: 1rem;
  color: hsl(var(--foreground));
}

/* Headings - Use Inter font family */
.article-content h1,
.article-content h2,
.article-content h3,
.article-content h4,
.article-content h5,
.article-content h6 {
  font-family: var(--font-heading);
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  font-weight: 600;
  line-height: 1.3;
  color: hsl(var(--foreground));
  letter-spacing: -0.02em;
}

.article-content h1 {
  font-size: 1.875rem; /* 30px */
  font-weight: 700;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

.article-content h2 {
  font-size: 1.5rem; /* 24px */
  font-weight: 600;
}

.article-content h3 {
  font-size: 1.25rem; /* 20px */
  font-weight: 600;
}

.article-content h4 {
  font-size: 1.125rem; /* 18px */
  font-weight: 600;
}

.article-content h5 {
  font-size: 1rem; /* 16px */
  font-weight: 600;
}

.article-content h6 {
  font-size: 0.875rem; /* 14px */
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Body text */
.article-content p {
  margin-bottom: 1rem;
  line-height: 1.7;
  font-size: 1rem;
}

/* First paragraph after heading - tighter spacing */
.article-content h1 + p,
.article-content h2 + p,
.article-content h3 + p,
.article-content h4 + p,
.article-content h5 + p,
.article-content h6 + p {
  margin-top: 0.5rem;
}

/* Lists - Optimized spacing */
.article-content ul,
.article-content ol {
  margin-bottom: 1rem;
  padding-left: 1.75rem;
  line-height: 1.7;
  font-size: 1rem;
}

/* No spacing between consecutive list items */
.article-content li {
  margin-top: 0;
  margin-bottom: 0;
  font-size: 1rem;
}

/* More spacing for nested lists */
.article-content li > ul,
.article-content li > ol {
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

.article-content blockquote {
  border-left: 4px solid hsl(var(--primary));
  padding-left: 1rem;
  margin: 1.5rem 0;
  font-style: italic;
  color: hsl(var(--muted-foreground));
}

.article-content hr {
  margin: 2rem 0;
  border: none;
  border-top: 1px solid hsl(var(--border));
}

.article-content a {
  color: hsl(var(--primary));
  text-decoration: underline;
  text-underline-offset: 2px;
}

.article-content a:hover {
  color: hsl(var(--primary) / 0.8);
}

.article-content code {
  background-color: hsl(var(--muted));
  padding: 0.125rem 0.25rem;
  border-radius: 0.25rem;
  font-size: 0.875em;
}

.article-content pre {
  background-color: hsl(var(--muted));
  padding: 1rem;
  border-radius: 0.5rem;
  overflow-x: auto;
  margin: 1rem 0;
}

.article-content pre code {
  background-color: transparent;
  padding: 0;
}

.article-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
}

.article-content th,
.article-content td {
  border: 1px solid hsl(var(--border));
  padding: 0.5rem;
  text-align: left;
}

.article-content th {
  background-color: hsl(var(--muted));
  font-weight: 600;
}
