/* Markdown Content Styling */
.prose {
    line-height: 1.75;
    color: #374151;
}

.prose h1,
.prose h2,
.prose h3,
.prose h4,
.prose h5,
.prose h6 {
    color: #111827;
    font-weight: 700;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.prose h1 {
    font-size: 2.25rem;
    line-height: 1.111;
}

.prose h2 {
    font-size: 1.875rem;
    line-height: 1.2;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 0.5rem;
}

.prose h3 {
    font-size: 1.5rem;
    line-height: 1.333;
}

.prose h4 {
    font-size: 1.25rem;
    line-height: 1.4;
}

.prose h5 {
    font-size: 1.125rem;
    line-height: 1.556;
}

.prose h6 {
    font-size: 1rem;
    line-height: 1.75;
}

.prose p {
    margin-top: 1.25rem;
    margin-bottom: 1.25rem;
}

.prose strong {
    color: #111827;
    font-weight: 600;
}

.prose em {
    color: #374151;
    font-style: italic;
}

.prose code {
    color: #dc2626;
    background-color: #f3f4f6;
    padding: 0.125rem 0.375rem;
    border-radius: 0.375rem;
    font-size: 0.875em;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
}

.prose pre {
    background-color: #1f2937;
    color: #f9fafb;
    padding: 1.25rem;
    border-radius: 0.5rem;
    overflow-x: auto;
    margin-top: 1.75rem;
    margin-bottom: 1.75rem;
}

.prose pre code {
    background-color: transparent;
    color: inherit;
    padding: 0;
    border-radius: 0;
    font-size: inherit;
}

.prose blockquote {
    border-left: 4px solid #8b5cf6;
    background-color: #f8fafc;
    padding: 1rem 1.5rem;
    margin: 1.75rem 0;
    font-style: italic;
    color: #475569;
}

.prose blockquote p {
    margin: 0;
}

.prose ul,
.prose ol {
    margin-top: 1.25rem;
    margin-bottom: 1.25rem;
    padding-left: 1.625rem;
}

.prose ul {
    list-style-type: disc;
}

.prose ol {
    list-style-type: decimal;
}

.prose li {
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
}

.prose li>p {
    margin-top: 0.75rem;
    margin-bottom: 0.75rem;
}

.prose a {
    color: #8b5cf6;
    text-decoration: underline;
    font-weight: 500;
}

.prose a:hover {
    color: #7c3aed;
}

.prose table {
    width: 100%;
    table-layout: auto;
    text-align: left;
    margin-top: 2rem;
    margin-bottom: 2rem;
    border-collapse: collapse;
}

.prose thead {
    border-bottom: 1px solid #d1d5db;
}

.prose thead th {
    color: #111827;
    font-weight: 600;
    vertical-align: bottom;
    padding-bottom: 0.5rem;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
}

.prose tbody tr {
    border-bottom: 1px solid #e5e7eb;
}

.prose tbody tr:last-child {
    border-bottom-width: 0;
}

.prose tbody td {
    vertical-align: baseline;
    padding: 0.5rem;
}

.prose hr {
    border: none;
    border-top: 1px solid #e5e7eb;
    margin-top: 3rem;
    margin-bottom: 3rem;
}

.prose img {
    margin-top: 2rem;
    margin-bottom: 2rem;
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
}

.prose figure {
    margin-top: 2rem;
    margin-bottom: 2rem;
}

.prose figcaption {
    color: #6b7280;
    font-size: 0.875rem;
    line-height: 1.429;
    margin-top: 0.75rem;
    text-align: center;
}

/* Syntax highlighting for code blocks */
.prose .codehilite {
    background-color: #1f2937;
    border-radius: 0.5rem;
    padding: 1.25rem;
    overflow-x: auto;
    margin: 1.75rem 0;
}

.prose .codehilite pre {
    background-color: transparent;
    color: #f9fafb;
    padding: 0;
    margin: 0;
    border-radius: 0;
}

/* Table of Contents styling */
.prose .toc {
    background-color: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    padding: 1.5rem;
    margin: 2rem 0;
}

.prose .toc ul {
    margin: 0;
    padding-left: 1rem;
}

.prose .toc>ul {
    padding-left: 0;
}

.prose .toc li {
    margin: 0.25rem 0;
}

.prose .toc a {
    text-decoration: none;
    color: #475569;
    font-weight: 500;
}

.prose .toc a:hover {
    color: #8b5cf6;
}

/* Responsive adjustments */
@media (max-width: 640px) {
    .prose h1 {
        font-size: 1.875rem;
    }

    .prose h2 {
        font-size: 1.5rem;
    }

    .prose h3 {
        font-size: 1.25rem;
    }

    .prose pre {
        padding: 1rem;
        margin: 1.25rem 0;
    }

    .prose blockquote {
        padding: 0.75rem 1rem;
        margin: 1.25rem 0;
    }

    .prose table {
        font-size: 0.875rem;
    }
}