/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

/* Markdown Content Styling for Dark Theme */
.markdown-content {
  font-size: 1.125rem;
  line-height: 1.8;
  color: #e5e7eb;
}

/* Headings */
.markdown-content h1 {
  font-size: 2.5rem;
  font-weight: 700;
  color: #ffffff;
  margin-top: 3rem;
  margin-bottom: 1.5rem;
  line-height: 1.2;
}

.markdown-content h2 {
  font-size: 2rem;
  font-weight: 700;
  color: #ffffff;
  margin-top: 3rem;
  margin-bottom: 1rem;
  line-height: 1.3;
}

.markdown-content h3 {
  font-size: 1.5rem;
  font-weight: 600;
  color: #ffffff;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.markdown-content h4 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #ffffff;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
  line-height: 1.4;
}

.markdown-content h5,
.markdown-content h6 {
  font-size: 1.125rem;
  font-weight: 600;
  color: #ffffff;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
  line-height: 1.4;
}

/* Paragraphs */
.markdown-content p {
  margin-bottom: 1.5rem;
  color: #d1d5db;
}

/* Links */
.markdown-content a {
  color: #60a5fa;
  text-decoration: none;
}

.markdown-content a:hover {
  text-decoration: underline;
  color: #93c5fd;
}

/* Strong and emphasis */
.markdown-content strong {
  font-weight: 600;
  color: #ffffff;
}

.markdown-content em {
  font-style: italic;
  color: #f3f4f6;
}

/* Lists */
.markdown-content ul,
.markdown-content ol {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}

.markdown-content li {
  margin-bottom: 0.5rem;
  color: #d1d5db;
}

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

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

/* Nested lists */
.markdown-content ul ul,
.markdown-content ol ol,
.markdown-content ul ol,
.markdown-content ol ul {
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

/* Blockquotes */
.markdown-content blockquote {
  border-left: 4px solid #6b7280;
  padding-left: 1.5rem;
  margin: 2rem 0;
  font-style: italic;
  color: #9ca3af;
  background-color: #374151;
  padding: 1.5rem;
  border-radius: 0 0.5rem 0.5rem 0;
}

.markdown-content blockquote p {
  margin-bottom: 0;
}

/* Code */
.markdown-content code {
  background-color: #374151;
  color: #f9fafb;
  padding: 0.25rem 0.5rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
}

.markdown-content pre {
  background-color: #1f2937;
  color: #f9fafb;
  padding: 1.5rem;
  border-radius: 0.5rem;
  overflow-x: auto;
  margin: 1.5rem 0;
  border: 1px solid #374151;
}

.markdown-content pre code {
  background-color: transparent;
  padding: 0;
  border-radius: 0;
  font-size: 0.875rem;
}

/* Tables */
.markdown-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
  border: 1px solid #4b5563;
}

.markdown-content th,
.markdown-content td {
  border: 1px solid #4b5563;
  padding: 0.75rem;
  text-align: left;
}

.markdown-content th {
  background-color: #374151;
  font-weight: 600;
  color: #ffffff;
}

.markdown-content td {
  color: #d1d5db;
}

/* Horizontal rules */
.markdown-content hr {
  border: none;
  border-top: 1px solid #4b5563;
  margin: 3rem 0;
}

/* Images */
.markdown-content img {
  max-width: 100%;
  height: auto;
  border-radius: 0.5rem;
  margin: 2rem 0;
}

/* First paragraph after heading should have no top margin */
.markdown-content h1 + p,
.markdown-content h2 + p,
.markdown-content h3 + p,
.markdown-content h4 + p,
.markdown-content h5 + p,
.markdown-content h6 + p {
  margin-top: 0;
}

/* Remove top margin from first element */
.markdown-content > *:first-child {
  margin-top: 0;
}

/* Remove bottom margin from last element */
.markdown-content > *:last-child {
  margin-bottom: 0;
}