/* ===== Fonts nhúng ===== */
@font-face {
    font-family: '85 NTD Gilroy';
    src: url('Fonts/85 NTD Gilroy Bold.otf') format('opentype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'SVN-Bebas Neue Pro Expanded';
    src: url('Fonts/SVN-Bebas Neue Pro Expanded Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'SVN-Bebas Neue Pro Expanded';
    src: url('Fonts/SVN-Bebas Neue Pro Expanded Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* ===== Màn hình load dữ liệu (sách đỏ lật trang + %) ===== */
#loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    z-index: 999;
}

.book {
    position: relative;
    width: 140px;
    height: 105px;
    transform-style: preserve-3d;
    perspective: 800px;
    animation: bookBob 2.8s ease-in-out infinite;
}

@keyframes bookBob {
    0%, 100% { transform: translateY(0) rotateX(2deg); }
    50% { transform: translateY(-10px) rotateX(-2deg); }
}

.book::before {
    content: "";
    position: absolute;
    left: 0;
    width: 50%;
    height: 100%;
    background: linear-gradient(100deg, #8f1220 0%, #c21f30 55%, #a51826 100%);
    border-radius: 6px 0 0 6px;
    box-shadow: inset -6px 0 8px rgba(0, 0, 0, 0.35), -3px 3px 8px rgba(0, 0, 0, 0.25);
    z-index: 1;
}

.book::after {
    content: "";
    position: absolute;
    right: 0;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, #c21f30 0%, #a51826 55%, #7c0f1b 100%);
    border-radius: 0 6px 6px 0;
    box-shadow: inset 6px 0 8px rgba(0, 0, 0, 0.35), 3px 3px 8px rgba(0, 0, 0, 0.25);
    z-index: 1;
}

.book-page {
    position: absolute;
    left: 50%;
    top: 0;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, #ffffff 0%, #f7f1e6 55%, #ece3d3 100%);
    border-radius: 0 5px 5px 0;
    transform-origin: left center;
    box-shadow: inset -3px 0 4px rgba(0, 0, 0, 0.06), 1px 0 3px rgba(0, 0, 0, 0.15);
    will-change: transform;
}

.book-page::after {
    content: "";
    position: absolute;
    right: 0;
    top: 0;
    width: 6px;
    height: 100%;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.18));
    border-radius: 0 5px 5px 0;
}

.book-page.p1 { animation: bookFlip 1.9s cubic-bezier(0.45, 0.05, 0.55, 0.95) infinite; z-index: 4; }
.book-page.p2 { animation: bookFlip 1.9s cubic-bezier(0.45, 0.05, 0.55, 0.95) infinite 0.45s; z-index: 3; }
.book-page.p3 { animation: bookFlip 1.9s cubic-bezier(0.45, 0.05, 0.55, 0.95) infinite 0.9s; z-index: 2; }

@keyframes bookFlip {
    0%   { transform: rotateY(0deg); }
    40%  { transform: rotateY(-135deg); }
    55%  { transform: rotateY(-180deg); }
    100% { transform: rotateY(-180deg); }
}

.loader-text {
    font-family: "85 NTD Gilroy", "Times New Roman", sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: #be1e2d;
    letter-spacing: 1px;
}

.loader-pct {
    font-family: "SVN-Bebas Neue Pro Expanded", "85 NTD Gilroy", sans-serif;
    font-size: 36px;
    font-weight: 700;
    color: #be1e2d;
}

/* ===== Reset & Shell ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    width: 100%;
    height: 100%;
    overflow: hidden;
}

body {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    font-family: "85 NTD Gilroy", "Times New Roman", "Arial", sans-serif;
}
img {
    image-rendering: auto; /* Chống răng cưa khi phóng ảnh */
}

#main-container {
    position: relative;
    width: 1200px;
    height: 680px;
    overflow: hidden;
    background: #ffffff;
}

/* ===== Screen chung ===== */
.screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 1200px;
    height: 680px;
    overflow: hidden;
    visibility: hidden;
    opacity: 0;
}

.screen.screen-active {
    visibility: visible;
    opacity: 1;
}

.screen .bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ===== Screen 1: Mở đầu ===== */
#screen1 .s1-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0 90px;
    text-align: center;
    transform: translateY(-28px);
}

.s1-logo {
    width: 258px;
    height: auto;
    margin-bottom: 30px;
    visibility: hidden;
    opacity: 0;
}

.s1-title {
    color: #ffde17;
    font-family: "85 NTD Gilroy", "Times New Roman", sans-serif;
    font-weight: 700;
    font-size: 36px;
    line-height: 1.5;
    text-transform: uppercase;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.4);
    letter-spacing: 1px;
    visibility: hidden;
    opacity: 0;
}

/* ===== Screen 2: Slider ===== */
#screen2 .slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

#screen2 .slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    visibility: hidden;
}

#screen2 .slide.slide-active {
    opacity: 1;
    visibility: visible;
}

/* ===== Screen 3: Menu chọn nhanh ===== */
#screen3 .s3-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 60px 60px;
    text-align: center;
}

.s3-logo {
    width: 150px;
    height: auto;
    margin-bottom: 20px;
}

.s3-title {
    color: #ffde17;
    font-family: "85 NTD Gilroy", "Times New Roman", sans-serif;
    font-weight: 700;
    font-size: 24px;
    line-height: 1.5;
    text-transform: uppercase;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.4);
    letter-spacing: 1px;
    margin-bottom: 60px;
}

/* ===== Nút bấm chung (menu-btn) ===== */
.menu-buttons {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
}

.menu-btn {
    height: 88px;
    width: auto;
    cursor: pointer;
    filter: drop-shadow(1px 2px 3px rgba(0, 0, 0, 0.25));
}

.menu-btn:hover {
    transform: scale(1.06);
}

#screen3 .menu-buttons .menu-btn {
    height: 160px;
    gap: 18px;
}

#screen3 .menu-buttons {
    gap: 34px;
}

/* ===== Screen 4: Menu chính + Nền (pageX.html cung cấp menu phụ + nội dung) ===== */
#s4-view {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding-top: 165px;
    z-index: 4;
}

.s4-page {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: stretch;
    padding: 0 22px 22px 0;
}

#screen4 .s4-header {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 130px;
    display: flex;
    align-items: center;
    justify-content: space-evenly;
    padding: 0 20px;
    z-index: 5;
}

.home-btn {
    height: 100px;
    width: auto;
    cursor: pointer;
    transition: transform 0.25s ease;
    filter: drop-shadow(1px 2px 3px rgba(0, 0, 0, 0.35));
}

.home-btn:hover {
    transform: scale(1.08);
}

#screen4 .s4-header .menu-buttons {
    gap: 25px;
    transform: translateX(50px);
}

#screen4 .s4-header .menu-btn {
    height: 145px;
}

.menu-btn.menu-active {
    cursor: default;
}

/* ---- Menu phụ bên trái ---- */
.sub-menu {
    position: relative;
    width: 175px;
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
    gap: 8px;
    flex-shrink: 0;
}

.sub-btn {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    cursor: pointer;
    user-select: none;
}

.sub-btn .connector {
    width: 50px;
    height: 3px;
    background: #be1e2d;
    flex-shrink: 0;
}

.sub-btn .circle {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #be1e2d;
    color: #fff;
    font-family: "SVN-Bebas Neue Pro Expanded", "85 NTD Gilroy", sans-serif;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: transform 0.25s ease, background 0.25s ease;
}

.sub-btn:hover .circle {
    transform: scale(1.12);
    background: #ffde17;
    color: #be1e2d;
}

.sub-btn.sub-active .connector {
    background: #ffde17;
}

.sub-btn.sub-active .circle {
    background: #ffde17;
    color: #ed1c24;
}

/* ---- Tooltip custom cho menu phụ ---- */
.sub-btn::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 94px;
    transform: translateY(-50%);
    border: 6px solid transparent;
    border-right-color: #ed1c24;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    z-index: 20;
}

.sub-btn::after {
    content: attr(data-title);
    position: absolute;
    top: 50%;
    left: 100px;
    transform: translateY(-50%);
    background: #ed1c24;
    color: #fff;
    font-family: "85 NTD Gilroy", "Times New Roman", sans-serif;
    font-size: 14px;
    font-weight: 700;
    padding: 6px 12px;
    border-radius: 6px;
    width: max-content;
    max-width: 500px;
    white-space: normal;
    overflow-wrap: break-word;
    line-height: 1.35;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.3);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    pointer-events: none;
    z-index: 20;
}

.sub-btn:hover::before,
.sub-btn:hover::after {
    opacity: 1;
    visibility: visible;
}

/* ---- Modal ---- */
#modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    visibility: hidden;
    opacity: 0;
    z-index: 50;
}

.modal-box {
    position: relative;
    width: 80%;
    max-height: 80%;
    background: #fff;
    color: #7a0c12;
    border: 0;
    border-top: 8px solid #ed1c24;
    border-bottom: 8px solid #ed1c24;
    border-radius: 12px;
    padding: 32px 32px;
    overflow-y: auto;
    overflow-x: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
    padding-left: 0px;
}

.modal-close {
    position: absolute;
    top: 10px;
    right: 18px;
    font-size: 28px;
    line-height: 1;
    color: #666;
    cursor: pointer;
    transition: color 0.2s ease, transform 0.2s ease;
}

.modal-close:hover {
    color: #ed1c24;
    transform: scale(1.15);
}

.modal-box h2 {
    color: #ed1c24;
    font-size: 22px;
    margin-bottom: 12px;
    padding-right: 30px;
}

.modal-box p,
.modal-box li {
    color: #7a0c12;
}

.modal-link {
    color: #000;
    text-decoration: underline;
    cursor: pointer;
    font-weight: 700;
}

.modal-link:hover {
    color: #e90b21;
}

/* ---- Modal dạng ảnh (chỉ có nút X) ---- */
.modal-box.modal-image {
    width: auto;
    max-width: 80vw;
    max-height: 90vh;
    background: transparent;
    border: 0;
    border-radius: 0;
    padding: 0;
    box-shadow: none;
    overflow: visible;
}

.modal-box.modal-image .modal-body {
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 0;
}

.modal-box.modal-image .modal-img-full {
    max-width: 80vw;
    max-height: 90vh;
    width: auto;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

.modal-box.modal-image .modal-close {
    top: -16px;
    right: -16px;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #ed1c24;
    color: #fff;
    font-size: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.4);
}

/* ---- Div Box nội dung ---- */
#page-content {
    opacity: 0;
    visibility: hidden;
}

.content-box {
    flex: 1;
    background: #ffffff;
    border: 0;
    border-top: 8px solid #ed1c24;
    border-bottom: 8px solid #ed1c24;
    border-radius: 12px;
    padding: 36px 32px;
    color: #7a0c12;
    font-size: 18px;
    line-height: 1.65;
    overflow-y: auto;
    overflow-x: hidden;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.2);
    max-width: 83%;
}

/* Ô connector + circle bám dính, nội dung cách ra bên phải
   (tự thêm trong pageX_Y.html: <div class="content-indicator">...</div> + <div class="content-body">...) */
.content-box:has(> .content-indicator),
.modal-body:has(> .content-indicator) {
    display: flex;
    align-items: flex-start;
    padding-left: 0;
}

.content-box:has(> .content-indicator) .content-indicator,
.modal-body:has(> .content-indicator) .content-indicator {
    position: sticky;
    top: 0;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 0;
    margin: 4px 16px 4px 0;
}

.content-box:has(> .content-indicator) .content-indicator .connector,
.modal-body:has(> .content-indicator) .content-indicator .connector {
    width: 20px;
    height: 3px;
    background: #be1e2d;
}

.content-box:has(> .content-indicator) .content-indicator .circle,
.modal-body:has(> .content-indicator) .content-indicator .circle {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #be1e2d;
    color: #fff;
    font-family: "SVN-Bebas Neue Pro Expanded", "85 NTD Gilroy", sans-serif;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.content-box:has(> .content-indicator) .content-body,
.modal-body:has(> .content-indicator) .content-body {
    flex: 1;
    min-width: 0;
    font-family: "SVN-Bebas Neue Pro Expanded", "85 NTD Gilroy", sans-serif;
    font-weight: 400;
    color: #000000;
    line-height: 1.3;
}

.modal-body:has(> .content-indicator) .content-body p,
.modal-body:has(> .content-indicator) .content-body li,
.modal-body:has(> .content-indicator) .content-body ul {
    color: #000000;
}

.content-box:has(> .content-indicator) .content-body h2,
.content-box:has(> .content-indicator) .content-body h3,
.content-box:has(> .content-indicator) .content-body strong,
.content-box:has(> .content-indicator) .content-body b,
.modal-body:has(> .content-indicator) .content-body h2,
.modal-body:has(> .content-indicator) .content-body h3,
.modal-body:has(> .content-indicator) .content-body strong,
.modal-body:has(> .content-indicator) .content-body b {
    font-weight: 700;
}

.content-box h2,
.modal-body h2 {
    color: #ed1c24;
    font-size: 22px;
    letter-spacing: 0;
    line-height: 1.3;
    font-family: 'SVN-Bebas Neue Pro Expanded';
    text-align: left;
}

.content-box h3,
.modal-body h3 {
    color: #ed1c24;
    font-size: 20px;
    margin: 6px 0 10px;
}

.content-box p,
.modal-body p {
    margin-bottom: 8px;
    text-align: justify;
}

.content-box ul,
.modal-body ul {
    padding-left: 22px;
    margin-bottom: 8px;
}

.content-box li,
.modal-body li {
    margin-bottom: 4px;
    text-align: justify;
}

/* ---- Phụ lục 1,2 (nằm cuối menu phụ của page5) ---- */
.pl-btn::before,
.pl-btn::after {
    display: none;
}

.pl-btn .connector {
    width: 25px;
}

.pl-top-btn .connector {
    width: 45px;
}

.pl-btn .pl-label {
    background: #be1e2d;
    color: #fff;
    font-family: "SVN-Bebas Neue Pro Expanded", "85 NTD Gilroy", sans-serif;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.3;
    text-align: center;
    padding: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.pl-btn:hover .pl-label {
    background: #ffde17;
    color: #ed1c24;
}

.pl-btn.sub-active .connector {
    background: #ffde17;
}

.pl-btn.sub-active .pl-label {
    background: #ffde17;
    color: #ed1c24;
}

/* ---- Trang Phụ lục: sub-menu icon + title ---- */
.pl-title {
    color: #ed1c24;
    font-size: 26px;
    text-align: center;
    margin-bottom: 18px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.pl-sub-menu {
    width: 250px;
    align-items: flex-start;
}

.pl-sub-item {
    display: flex;
    align-items: center;
    gap: 6px;
    width: max-content;
    max-width: 90%;
    padding: 4px;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.pl-sub-item img {
    width: 34px;
    height: 34px;
    object-fit: contain;
    flex-shrink: 0;
}

.pl-sub-item span {
    color: #7a0c12;
    font-family: "SVN-Bebas Neue Pro Expanded", "85 NTD Gilroy", sans-serif;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.3;
    text-transform: uppercase;
}

.pl-sub-item:hover {
    transform: scale(1.03);
}

.pl-sub-item.sub-active span {
    color: #ed1c24;
}

/* ---- Phụ lục: 2 cột nội dung vừa khít content-box, mỗi cột tự scroll Y ---- */
#page-content:has(.pl-columns) {
    display: flex;
    flex-direction: column;
}

.pl-columns {
    display: flex;
    gap: 24px;
    flex: 1;
    min-height: 0;
}

.pl-col {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.pl-col:first-child {
    flex: 2;
}

.pl-col:last-child {
    flex: 3;
}

.content-box h3.pl-col-title {
    color: #2b3990;
    font-family: "85 NTD Gilroy", "Times New Roman", sans-serif;
    font-size: 16px;
    line-height: 1.3;
    text-transform: uppercase;
    font-weight: 700;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 2px solid #ed1c24;
}

.pl-col-body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 8px;
    color: #000000;
    font-family: "SVN-Bebas Neue Pro";
    line-height: 1.3;
    font-size: 18px;
}

.pl-col-body::-webkit-scrollbar {
    width: 6px;
}

.pl-col-body::-webkit-scrollbar-track {
    background: transparent;
}

.pl-col-body::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.18);
    border-radius: 3px;
}

.pl-col-body:hover::-webkit-scrollbar-thumb {
    background: rgba(237, 28, 36, 0.55);
}

/* Scrollbar cho content-box — mảnh, đẹp, chỉ hiện khi hover */
.content-box {
    scrollbar-width: thin;
    scrollbar-color: transparent transparent;
}

.content-box:hover {
    scrollbar-color: #ffde17 transparent;
}

.content-box::-webkit-scrollbar {
    width: 6px;
}

.content-box::-webkit-scrollbar-track {
    background: transparent;
}

.content-box::-webkit-scrollbar-thumb {
    background: transparent;
    border-radius: 3px;
}

.content-box:hover::-webkit-scrollbar-thumb {
    background: #ffde17;
}

.content-box:hover::-webkit-scrollbar-thumb:hover {
    background: #ffde17;
}

/* ===== RESPONSIVE MOBILE (≤768px) — bản PC không bị ảnh hưởng ===== */
@media (max-width: 768px) {
    html,
    body {
        overflow: auto;
        height: auto;
    }

    body {
        align-items: stretch;
    }

    #main-container {
        width: 100%;
        height: 100vh;
        min-height: 480px;
    }

    .screen {
        width: 100%;
        height: 100%;
    }

    .menu-buttons, #screen4 .s4-header .menu-buttons {
        transform: none;
    }


    /* ---- Screen 1 ---- */
    #screen1 .s1-content {
        padding: 0 18px;
        transform: translateY(-10px);
    }

    .s1-logo {
        width: 120px;
        margin-bottom: 16px;
    }

    .s1-title {
        font-size: 15px;
        line-height: 1.45;
        letter-spacing: 0.4px;
    }

    /* ---- Screen 3: 5 nút chia 2 nút/hàng ---- */
    #screen3 .s3-content {
        padding: 20px 16px 28px;
    }

    .s3-logo {
        width: 84px;
        margin-bottom: 12px;
    }

    .s3-title {
        font-size: 14px;
        line-height: 1.45;
        margin-bottom: 24px;
        letter-spacing: 0.4px;
    }

    #screen3 .menu-buttons {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 14px;
        width: 100%;
        max-width: 100%;
    }

    #screen3 .menu-buttons .menu-btn {
        height: auto;
        width: min(150px, calc((100% - 28px) / 3));
    }

    /* ---- Screen 4: header gọn: home trên, menu chính dưới ---- */
    #screen4 .s4-header {
        height: auto;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 6px;
        padding: 8px;
        overflow: visible;
    }

    #screen4 .s4-header .home-btn {
        width: 84px;
        height: 76px;
        object-fit: contain;
        flex-shrink: 0;
    }

    #screen4 .s4-header .menu-btn {
        width: 68px;
        height: 60px;
        object-fit: contain;
        flex-shrink: 0;
    }

    #screen4 .s4-header .menu-buttons {
        gap: 0;
        flex-wrap: wrap;
        justify-content: center;
    }

    #s4-view {
        padding-top: 170px;
    }

    /* ---- Screen 4: sub-menu circles dàn ngang, content dưới ---- */
    .s4-page {
        flex-direction: column;
        align-items: stretch;
        padding: 0 12px 12px;
    }

    .sub-menu {
        flex-direction: row;
        justify-content: center;
        width: 100%;
        gap: 10px;
        margin-bottom: 10px;
    }

    .sub-btn {
        width: auto;
    }

    .sub-btn .connector {
        display: none;
    }

    .sub-btn .circle {
        width: 34px;
        height: 34px;
        font-size: 17px;
    }

    .sub-btn::before,
    .sub-btn::after {
        display: none;
    }

    .content-box {
        max-width: 100%;
        border-top-width: 4px;
        border-bottom-width: 4px;
        padding: 20px 16px;
        font-size: 15px;
        line-height: 1.55;
    }

.content-box:has(> .content-indicator),
.modal-body:has(> .content-indicator) {
        padding-left: 0;
    }

    .content-box:has(> .content-indicator) .content-indicator,
    .modal-body:has(> .content-indicator) .content-indicator {
        top: 12px;
        gap: 0;
        margin: 2px 8px 2px 0;
    }

    .content-box:has(> .content-indicator) .content-indicator .connector,
    .modal-body:has(> .content-indicator) .content-indicator .connector {
        width: 20px;
    }

    .content-box:has(> .content-indicator) .content-indicator .circle,
    .modal-body:has(> .content-indicator) .content-indicator .circle {
        width: 30px;
        height: 30px;
        font-size: 15px;
    }

    .content-box h2,
    .modal-body h2 {
        font-size: 18px;
        margin-bottom: 10px;
    }

    .modal-box.modal-image {
        max-width: 95vw;
        max-height: 100vh;
    }

    .modal-box.modal-image .modal-img-full {
        max-width: 95vw;
        max-height: 100vh;
    }

    .modal-box.modal-image .modal-close {
        top: -44px;
        right: 8px;
    }

    .content-box h3,
    .modal-body h3 {
        font-size: 16px;
    }

    .pl-title {
        font-size: 17px;
        margin-bottom: 12px;
    }

    .pl-sub-menu {
        width: 100%;
        align-items: flex-start;
    }

    .pl-sub-item {
        flex-direction: column;
        width: auto;
        padding: 4px;
    }

    .pl-sub-item img {
        width: 30px;
        height: 30px;
    }

    .pl-sub-item span {
        display: none;
    }

    /* ---- Modal ---- */
    .modal-box {
        width: 92%;
        max-height: 82%;
        padding: 18px 16px;
        border-top-width: 4px;
        border-bottom-width: 4px;
        padding-left: 0px;
    }

    .pl-columns {
        flex-direction: column;
        gap: 14px;
    }

    .pl-col {
        flex: none;
    }

    .pl-col:first-child,
    .pl-col:last-child {
        flex: none;
    }

    .pl-col-body {
        overflow: visible;
        flex: none;
        padding-right: 0;
        font-size: 16px;
    }

    .content-box h3.pl-col-title {
        font-size: 14px;
    }
}

ol {
    padding-left: 15px;
}
ol > li {
    padding-left: 5px;
}

ol li::marker {
        font-weight: bold;
    }

ol.chapter-list {
    list-style: none;
    counter-reset: item;
    /* Tạo khoảng trống bên trái để số đếm có chỗ đứng tự nhiên */
    padding-left: 25px; 
}

ol.chapter-list > li {
    counter-increment: item;
    margin-bottom: 8px;
    /* Đẩy phần nội dung chữ cái ra một chút cho thoáng nếu cần */
    position: relative; 
}

ol.chapter-list > li::before {
    content: var(--section) "." counter(item) ". ";
    font-weight: bold;
    
    /* Đẩy số đếm lệch ra phía ngoài bên trái đúng chuẩn thẻ li thực tế */
    position: absolute;
    left: -25px; 
    text-align: right; /* Căn phải cho các số thẳng hàng đẹp mắt */
    padding-right: 5px; /* Tạo khoảng hở giữa số và nội dung */
}

.content-box h2 img,
.modal-body h2 img {
    width: 22px;
    height: 22px;
    margin-right: 12px;
}
.red {
    color:#ed1c24;
    font-weight: 700;
}
.float-right {
    float: right;
    max-width: 50%;
    margin-left: 30px;
}
.pl-columns .pl-col-body ol {padding-left: 20px;}