@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500;600&family=Inter:wght@400;500;600;700&family=Space+Grotesk:wght@500;600;700&display=swap');

.sr-richtext {
    --sr-text: #eceef2;
    --sr-muted: #8b93a1;
    --sr-accent: #38C6A8;
    --sr-line: rgba(255, 255, 255, 0.08);
    --sr-card: #16191f;
    --sr-heading: #fff;
    --sr-strong: #fff;
    font-family: Inter, ui-sans-serif, system-ui, sans-serif;
    font-size: 17px;
    line-height: 1.7;
    color: var(--sr-text);
    letter-spacing: -0.011em;
}
html[data-editor-theme="light"] .sr-richtext,
.sr-richtext.is-light {
    --sr-text: #0E1520;
    --sr-muted: #5C6470;
    --sr-accent: #03c3b1;
    --sr-line: #E2E8F0;
    --sr-card: #F5F7FA;
    --sr-heading: #0E1520;
    --sr-strong: #0E1520;
}
html[data-editor-theme="light"],
html[data-editor-theme="light"] body.sr-richtext {
    background: #fff;
    color: #0E1520;
}
html[data-editor-theme="dark"],
html[data-editor-theme="dark"] body.sr-richtext {
    background: #050f1a;
    color: #eceef2;
}
html[data-editor-theme] body.sr-richtext {
    box-sizing: border-box;
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 18px 20px 28px;
    min-height: 100%;
}
.sr-richtext > *:first-child { margin-top: 0; }
.sr-richtext > *:last-child { margin-bottom: 0; }
.sr-richtext h1, .sr-richtext h2, .sr-richtext h3, .sr-richtext h4, .sr-richtext h5, .sr-richtext h6 {
    font-family: "Space Grotesk", ui-sans-serif, system-ui, sans-serif;
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.15;
    color: var(--sr-heading);
    margin: 1.2em 0 0.45em;
}
.sr-richtext h1 { font-size: 2.25rem; }
.sr-richtext h2 { font-size: 1.75rem; }
.sr-richtext h3 { font-size: 1.35rem; }
.sr-richtext h4 { font-size: 1.15rem; }
.sr-richtext p { margin: 0 0 1.15em; }
.sr-richtext a { color: var(--sr-accent); text-decoration: underline; text-underline-offset: 3px; }
.sr-richtext a:hover { filter: brightness(1.08); }
.sr-richtext strong, .sr-richtext b { font-weight: 650; color: var(--sr-strong); }
.sr-richtext em, .sr-richtext i { font-style: italic; }
.sr-richtext ul, .sr-richtext ol { margin: 0 0 1em; padding-left: 1.35em; }
.sr-richtext li { margin: 0.25em 0; }
.sr-richtext blockquote {
    margin: 1.25em 0;
    padding: 0.15em 0 0.15em 1em;
    border-left: 3px solid var(--sr-accent);
    color: var(--sr-muted);
}
.sr-richtext hr { border: 0; border-top: 1px solid var(--sr-line); margin: 1.75em 0; }
.sr-richtext img, .sr-richtext figure img {
    max-width: 100%;
    height: auto;
    border-radius: 16px;
    display: block;
    margin: 1.25em 0;
}
.sr-richtext figure { margin: 1.25em 0; }
.sr-richtext figcaption { font-size: 13px; color: var(--sr-muted); margin-top: -0.5em; }
.sr-richtext code, .sr-richtext pre {
    font-family: "IBM Plex Mono", ui-monospace, monospace;
}
.sr-richtext code {
    font-size: 0.92em;
    padding: 0.12em 0.35em;
    border-radius: 6px;
    background: var(--sr-card);
}
.sr-richtext pre {
    padding: 1em 1.1em;
    border-radius: 12px;
    background: var(--sr-card);
    overflow: auto;
}
.sr-richtext table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.25em 0;
}
.sr-richtext th, .sr-richtext td {
    border: 1px solid var(--sr-line);
    padding: 0.55em 0.7em;
    text-align: left;
}
.sr-richtext th { font-weight: 600; }
