.rich-content {
    min-width: 0;
    max-width: 100%;
    overflow-wrap: anywhere;
}

.rich-content h2,
.rich-content h3,
.rich-content h4 {
    color: #111827;
    font-weight: 700;
    line-height: 1.35;
}

.rich-content h2 {
    margin: 1.6em 0 0.65em;
    font-size: clamp(1.35rem, 3vw, 1.8rem);
}

.rich-content h3 {
    margin: 1.4em 0 0.6em;
    font-size: clamp(1.2rem, 2.4vw, 1.5rem);
}

.rich-content h4 {
    margin: 1.2em 0 0.55em;
    font-size: clamp(1.05rem, 2vw, 1.25rem);
}

.rich-content p {
    margin: 0 0 1em;
}

.rich-content ul,
.rich-content ol {
    margin: 0 0 1em 1.4rem;
    padding-left: 0.7rem;
}

.rich-content ul { list-style: disc; }
.rich-content ol { list-style: decimal; }
.rich-content li { margin: 0.3em 0; }

.rich-content blockquote {
    margin: 1.25em 0;
    padding: 0.75rem 1rem;
    border-left: 4px solid var(--color-primary, #2563eb);
    border-radius: 0 0.5rem 0.5rem 0;
    background: #f8fafc;
    color: #475569;
}

.rich-content a {
    color: var(--color-primary-700, #1d4ed8);
    text-decoration: underline;
    text-underline-offset: 0.15em;
}

/* Editor artik icerige gorsel de ekleyebiliyor. */
.rich-content img {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 1.25em 0;
    border-radius: 0.5rem;
}

.rich-content table {
    display: block;
    width: 100%;
    max-width: 100%;
    margin: 1.25rem 0;
    overflow-x: auto;
    border: 1px solid #cbd5e1;
    border-radius: 0.65rem;
    border-collapse: collapse;
    background: #fff;
    font-size: 0.92em;
    font-variant-numeric: tabular-nums;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-inline: contain;
}

.rich-content caption {
    padding: 0.7rem 0.8rem;
    color: #334155;
    font-weight: 700;
    text-align: left;
}

.rich-content th,
.rich-content td {
    min-width: 7rem;
    max-width: 28rem;
    padding: 0.65rem 0.75rem;
    border: 1px solid #cbd5e1;
    color: #1f2937;
    text-align: left;
    vertical-align: top;
    white-space: normal;
    overflow-wrap: anywhere;
}

.rich-content th {
    background: #f1f5f9;
    color: #0f172a;
    font-weight: 700;
}

.rich-content tbody tr:nth-child(even) td {
    background: #f8fafc;
}

.rich-content [style="text-align:left"] { text-align: left; }
.rich-content [style="text-align:center"] { text-align: center; }
.rich-content [style="text-align:right"] { text-align: right; }
.rich-content [style="text-align:justify"] { text-align: justify; }

@media (max-width: 639px) {
    .rich-content table {
        margin-inline: 0;
        font-size: 0.875rem;
    }

    .rich-content th,
    .rich-content td {
        min-width: 8rem;
        padding: 0.6rem;
    }
}
