/* Rich text styles for AI-generated HTML content (content_fa) */

.article-content {
  color: inherit;
  line-height: 1.85;
  font-size: 1.0625rem;
}

.article-content > *:first-child {
  margin-top: 0;
}

.article-content > *:last-child {
  margin-bottom: 0;
}

.article-content h2 {
  font-size: 1.5rem;
  color: #1e40af;
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.dark .article-content h2 {
  color: #93c5fd;
}

.article-content h3 {
  font-size: 1.25rem;
  color: #4338ca;
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.dark .article-content h3 {
  color: #a5b4fc;
}

.article-content h1,
.article-content h4,
.article-content h5,
.article-content h6 {
  font-weight: 700;
  line-height: 1.35;
  margin-top: 2rem;
  margin-bottom: 0.85rem;
  color: inherit;
}

.article-content h1 { font-size: 1.875rem; }
.article-content h4 { font-size: 1.125rem; }
.article-content h5 { font-size: 1rem; }
.article-content h6 { font-size: 0.9375rem; }

.article-content p {
  margin-bottom: 1.5rem;
}

.article-content ul,
.article-content ol {
  margin-bottom: 1.25rem;
  padding-right: 1.5rem;
  padding-left: 0;
}

.article-content ul {
  list-style-type: disc;
}

.article-content ol {
  list-style-type: decimal;
}

.article-content li {
  margin-bottom: 0.5rem;
}

.article-content li > ul,
.article-content li > ol {
  margin-top: 0.5rem;
  margin-bottom: 0;
}

.article-content a {
  color: #2563eb;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.15s ease;
}

.article-content a:hover {
  color: #1d4ed8;
}

.dark .article-content a {
  color: #60a5fa;
}

.dark .article-content a:hover {
  color: #93c5fd;
}

.article-content blockquote {
  border-right: 4px solid #3b82f6;
  border-left: none;
  padding: 0.75rem 1.25rem 0.75rem 0;
  margin: 1.5rem 0;
  font-style: italic;
  background-color: rgba(59, 130, 246, 0.06);
  border-radius: 0.5rem 0 0 0.5rem;
}

.dark .article-content blockquote {
  background-color: rgba(59, 130, 246, 0.12);
  border-right-color: #60a5fa;
}

.article-content strong,
.article-content b {
  font-weight: 700;
}

.article-content em,
.article-content i {
  font-style: italic;
}

.article-content code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.875em;
  background-color: rgba(15, 23, 42, 0.06);
  padding: 0.15rem 0.4rem;
  border-radius: 0.25rem;
}

.dark .article-content code {
  background-color: rgba(148, 163, 184, 0.15);
}

.article-content pre {
  overflow-x: auto;
  padding: 1rem 1.25rem;
  margin: 1.5rem 0;
  border-radius: 0.75rem;
  background-color: #0f172a;
  color: #e2e8f0;
  font-size: 0.875rem;
  line-height: 1.6;
}

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

.article-content img {
  max-width: 100%;
  height: auto;
  border-radius: 0.75rem;
  margin: 1.5rem auto;
}

.article-content hr {
  border: none;
  border-top: 1px solid rgba(148, 163, 184, 0.35);
  margin: 2rem 0;
}

.dark .article-content hr {
  border-top-color: rgba(148, 163, 184, 0.2);
}

.article-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.9375rem;
}

.article-content th,
.article-content td {
  border: 1px solid rgba(148, 163, 184, 0.35);
  padding: 0.65rem 0.85rem;
  text-align: right;
}

.dark .article-content th,
.dark .article-content td {
  border-color: rgba(148, 163, 184, 0.2);
}

.article-content th {
  font-weight: 600;
  background-color: rgba(15, 23, 42, 0.04);
}

.dark .article-content th {
  background-color: rgba(148, 163, 184, 0.08);
}
