.tieng-anh hr {
    margin-bottom: 10px;
}

.tieng-anh h3 {
    line-height: 1.5em;
    position: relative;
    margin-bottom: 20px;
    font-size: 1.3em;
    text-transform: none;
    color: #000;
    left: 0;
    border: 0;
}

.tieng-anh a {
    color: green !important;
    /* font-weight: bold; */
}

.tieng-anh p {
    margin: 0 0.2em 1em;
    padding: 0;
    /* text-align: justify; */
    color: #000;
    line-height: 30px;
}

.tieng-anh ul,
ol {
    padding-left: 20px;
    list-style: auto;
    margin: 20px;
    font-size: 18px;
}

.tieng-anh h2 {
    line-height: 1.5em;
    position: relative;
    font-size: 1.7em;
    font-weight: 400;
    left: 0;
    margin-bottom: 20px;
}

.tieng-anh pre {
    display: block;
    padding: 9.5px;
    margin: 0 0 10px;
    font-size: 13px;
    line-height: 1.42857143;
    color: #333;
    word-break: break-all;
    word-wrap: break-word;
    background-color: #f5f5f5;
    border: 1px solid #ccc;
    border-radius: 4px;
    white-space: pre-wrap;
    /* Since CSS 2.1 */
    white-space: -moz-pre-wrap;
    /* Mozilla, since 1999 */
    white-space: -pre-wrap;
    /* Opera 4-6 */
    white-space: -o-pre-wrap;
    /* Opera 7 */
    word-wrap: break-word;
    padding: 2px;
    border: 1px solid #888;
}

#toggleSidebar {
    /* Vị trí cố định bên dưới góc phải */
    position: fixed;
    right: 16px;
    bottom: 220px;
    z-index: 50;
    width: 48px;
    height: 48px;
    background-color: #2563eb;
    /* Màu xanh */
    color: white;
    border-radius: 50%;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s, transform 0.3s ease;
}

/* Hiệu ứng hover */
#toggleSidebar:hover {
    background-color: #1d4ed8;
    /* Tông xanh đậm hơn khi hover */
    transform: scale(1.1);
}

/* Hiển thị nút chỉ trên mobile và tablet */
@media (min-width: 1025px) {
    #toggleSidebar {
        display: none;
    }
}

#right-content .tabs {
    margin-top: 10px !important;
}

/* Mobile and tablet styles */
#leftSidebar {
    width: 350px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* Mobile and tablet styles */
@media (max-width: 1024px) {
    #leftSidebar {
        transform: translateX(-100%);
        position: fixed;
        top: 0;
        left: 0;
        width: 80%;
        max-width: 380px;
        height: 100vh;
        z-index: 9999;
        background-color: #f9fafb;
        /* Màu nền nhẹ nhàng */
        box-shadow: 2px 0 8px rgba(0, 0, 0, 0.1);
        /* Hiệu ứng đổ bóng */
        padding: 16px;
        border-right: 1px solid #e5e7eb;
        overflow-y: auto;
    }

    /* Hiển thị sidebar khi có lớp 'show-sidebar' */
    #leftSidebar.show-sidebar {
        transform: translateX(0);
    }
}

/* Desktop styles */
@media (min-width: 1025px) {
    #leftSidebar {
        position: sticky;
        top: 16px;
        height: calc(100vh - 32px);
        /* Dưới desktop, giữ khoảng cách nhỏ */
        overflow-y: auto;
        background-color: white;
        border: 1px solid #e5e7eb;
        border-radius: 8px;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
        padding: 24px;
    }
}

/* Scrollbar styles */
#leftSidebar::-webkit-scrollbar {
    width: 8px;
}

#leftSidebar::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
}

#leftSidebar::-webkit-scrollbar-track {
    background: transparent;
}

#leftSidebar {
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.2) transparent;
}


/* Mặc định cho màn hình lớn */
.sidebar-container {
    grid-column: span 1;
    /* Tương ứng với col-span-1 */
}

/* Cho màn hình nhỏ */
@media (max-width: 768px) {
    .sidebar-container {
        grid-column: span 3;
        /* Tương ứng với col-span-3 */
    }
}

/* Tùy chỉnh khung chọn */
.select2-container .select2-selection--single {
    height: 40px;
    /* Chiều cao tổng thể */
    line-height: 40px;
    border: 1px solid #cbd5e0;
    /* Màu viền */
    border-radius: 8px;
    /* Bo góc */
    padding: 0 10px;
    /* Khoảng cách nội dung */
    transition: border-color 0.3s, box-shadow 0.3s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    /* Hiệu ứng bóng */
}

/* Hover và focus */
.select2-container .select2-selection--single:hover,
.select2-container--default .select2-selection--single:focus {
    border-color: #2563eb;
    /* Màu xanh nhấn */
    box-shadow: 0 0 5px rgba(37, 99, 235, 0.5);
    /* Hiệu ứng focus */
}

/* Mũi tên thả xuống */
.select2-container .select2-selection--single .select2-selection__arrow {
    top: 50%;
    transform: translateY(-50%);
    right: 10px;
    height: 16px;
    width: 16px;
    background-color: #2563eb;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 10px;
}

/* Tùy chỉnh danh sách thả xuống */
.select2-dropdown {
    border-radius: 8px;
    border: 1px solid #cbd5e0;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    margin-top: 5px;
    overflow: hidden;
}

/* Các mục trong danh sách */
.select2-results__option {
    padding: 10px 15px;
    font-size: 14px;
    color: #2d3748;
    /* Màu văn bản */
}

/* Hover các mục */
.select2-results__option--highlighted {
    background-color: #2563eb;
    color: white;
}

/* Nhóm (optgroup) */
.select2-results__group {
    padding: 10px 15px;
    font-size: 14px;
    font-weight: bold;
    color: #4a5568;
    /* Màu nhấn */
    background-color: #f7fafc;
    /* Màu nền */
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 35px !important;
}

.select2-container--default .select2-selection--single .select2-selection__arrow b {
    border-color: #fff transparent transparent transparent;
    color: #ffffff;
}

.select2-container--default.select2-container--open .select2-selection--single .select2-selection__arrow b {
    border-color: transparent transparent #fff transparent;
}

.select2-selection__clear {
    margin-top: -3px;
    margin-right: 20px !important;
}

.select2-results__options::-webkit-scrollbar {
    display: none;
    /* Ẩn scrollbar trên các trình duyệt Webkit */
}

.select2-results__options {
    -ms-overflow-style: none;
    /* Ẩn scrollbar trên IE và Edge */
    scrollbar-width: none;
    /* Ẩn scrollbar trên Firefox */
}

#previewPopupContent ul::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

#previewPopupContent ul::-webkit-scrollbar-thumb {
    background: #a0aec0;
    /* Màu xám nhạt */
    border-radius: 3px;
}

#previewPopupContent ul::-webkit-scrollbar-thumb:hover {
    background: #718096;
    /* Màu xám đậm hơn khi hover */
}

/* Mask nội dung đáp án */
.masked {
    color: transparent;
    text-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
    /* Hiệu ứng giả */
    cursor: pointer;
}

.masked:hover {
    color: inherit;
    /* Hiển thị lại nội dung khi hover */
    text-shadow: none;
    /* Loại bỏ hiệu ứng */
}

/* Hiệu ứng nhấp nháy cho vòng tròn live stream */
.live-stream-indicator {
    margin-top: 3px;
    width: 12px;
    height: 12px;
    background-color: red;
    border-radius: 50%;
    /* margin-left: 8px; */
    animation: blink 1s infinite;
}

/* Tạo hiệu ứng nhấp nháy */
@keyframes blink {
    0% {
        opacity: 1;
        background-color: red;
    }

    50% {
        opacity: 0.6;
        background-color: orange;
    }

    100% {
        opacity: 1;
        background-color: red;
    }
}

.active-link {
    font-weight: bold;
    color: #1d4ed8;
    border: 2px solid #1d4ed8;
    outline: none; /* Bỏ viền khi focus */
}

.active-link:focus-visible {
    outline: none; /* Loại bỏ hiệu ứng focus-visible */
    box-shadow: none; /* Đảm bảo không có hiệu ứng shadow */
}