.content-html * {
    max-width: 100%;
}

/* Css for content */
/* Ảnh trong nội dung CKEditor */
.content-html img,
.content-html .ratio {
    height: auto;
    display: block;
    margin: 1rem auto;
    border: 1px solid rgba(255, 255, 255, .10);
    border-radius: 12px;
    box-shadow: 0 8px 22px rgba(0, 0, 0, .35);
}

.content-html img {
    max-width: 80%;
}

.content-html .ratio {
    max-width: 60%;
}

/* Tiêu đề có underline đẹp */
.section-bg>h2,
.content-html h2 {
    position: relative;
    display: inline-block;
}

.section-bg>h2::after,
.content-html h2::after {
    content: "";
    display: block;
    height: 3px;
    width: 140px;
    margin: .6rem auto 0;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--accent-color), rgba(255, 255, 255, 0));
    opacity: .95;
}

/* Heading phụ h3 kẻ mảnh */
.content-html h3 {
    border-bottom: 1px solid rgba(255, 255, 255, .12);
    padding-bottom: .35rem;
    margin-bottom: .75rem;
}

/* ============ Bảng CKEditor: nền sáng, chữ tối ============ */
.content-html table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: #FFFFFF !important;
    color: #2B1D14 !important;
    border: 1px solid rgba(0, 0, 0, .12);
    border-radius: 12px;
    overflow: hidden;
    margin: 1rem 0;
}

.content-html thead th {
    background: #F6EFE7 !important;
    color: #2B1D14 !important;
    font-weight: 700;
    padding: .9rem 1rem;
    border-bottom: 1px solid rgba(0, 0, 0, .12);
    white-space: nowrap;
}

.content-html tbody td {
    color: #2B1D14 !important;
    background: #FFFFFF !important;
    padding: .8rem 1rem;
    border-top: 1px solid rgba(0, 0, 0, .08);
    vertical-align: top;
}

.content-html tbody tr:nth-child(even) td {
    background: #FAF7F2 !important;
}

.content-html tbody tr:hover td {
    background: #F3EEE6 !important;
}

.content-html table a {
    color: #8B4513 !important;
    text-decoration-color: rgba(139, 69, 19, .45);
}

.content-html table a:hover {
    color: #4B2A0F !important;
    text-decoration-color: currentColor;
}

.content-html table td *,
.content-html table th * {
    color: inherit !important;
    background: transparent !important;
}

@media (max-width:768px) {
    .content-html table {
        display: block;
        overflow-x: auto;
    }
}
