﻿.pdf-wrapper {
    display: flex;
    gap: 20px;
    padding: 20px;
}


.pdf-list {
    list-style: none;
    padding: 0;
    margin: 0;
    max-height: 85vh;
    overflow-y: auto;
}

    .pdf-list li {
        display: flex;
        align-items: center;
        padding: 10px 12px;
        margin-bottom: 8px;
        border-radius: 6px;
        background: #f9f9f9;
        transition: all 0.2s ease;
    }

        .pdf-list li:hover {
            background: #eaf4ff;
            transform: scale(1.02);
            cursor: pointer;
        }

    .pdf-list i {
        color: #e74c3c;
        font-size: 20px;
        margin-right: 10px;
    }

    .pdf-list a {
        text-decoration: none;
        color: #333;
        font-weight: 600;
        display: block;
        width: 100%;
    }

        .pdf-list a:hover {
            color: #007bff;
        }

.pdf-wrapper {
    display: flex;
    gap: 20px;
    padding: 20px;
}
/* ===== CỘT TRÁI: DANH SÁCH PDF ===== */

.baocao-container {
    width: 80% !important;
}

.pdf-list {
    flex: 0 0 100%;
    list-style: none;
    padding: 0;
    margin: 0; /* border-right: 2px solid #eee; */
    max-height: 85vh;
    overflow-y: auto;
}

    .pdf-list li {
        display: flex;
        align-items: center;
        padding: 10px 12px;
        margin-bottom: 8px;
        border-radius: 6px;
        background: #f9f9f9;
        transition: all 0.2s ease;
    }

        .pdf-list li:hover {
            background: #eaf4ff;
            transform: scale(1.02);
            cursor: pointer;
        }

    .pdf-list i {
        color: #e74c3c;
        font-size: 20px;
        margin-right: 10px;
    }

    .pdf-list a {
        text-decoration: none;
        color: #333;
        font-weight: 600;
        display: block;
        width: 100%;
    }

        .pdf-list a:hover {
            color: #007bff;
        }

.detail-baocao-container {
    width: 80%;
    margin: 50px auto !important;
}

.pdf-viewer-area {
    flex: 1;
    display: flex;
    width: 50%;
    flex-direction: column;
}

#toolbar {
    text-align: center;
    background: #f7f7f7;
    padding: 10px;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    margin-bottom: 10px;
    position: sticky;
    top: 0;
    z-index: 100;
}

    #toolbar button {
        margin: 0 4px;
        background: #007bff;
        border: none;
        color: white;
        padding: 6px 10px;
        border-radius: 4px;
        cursor: pointer;
        transition: 0.2s;
    }

        #toolbar button:hover {
            background: #0056b3;
        }

#pdf-container {
    height: 85vh;
    overflow-y: auto;
    border: 1px solid #ccc;
    padding: 10px;
}

canvas {
    display: block;
    margin: 10px auto;
    box-shadow: 0 0 5px rgba(0,0,0,0.2);
}
@media (max-width: 768px) {
    .detail-baocao-container{
        width: 95% !important;
        margin-left:2.5%;
    }
    .pdf-wrapper {
        flex-direction: column;
        gap: 15px;
        padding: 10px;
    }

    /* danh sách pdf đưa lên trên */
    .pdf-list {
        flex: 0 0 auto;
        width: 100%;
        max-height: 250px;
        overflow-y: auto;
        order: 1;
        border: 1px solid #eee;
        border-radius: 8px;
        padding: 10px;
    }

        .pdf-list li {
            margin-bottom: 6px;
            padding: 8px 10px;
        }

    /* khu vực pdf viewer */
    .pdf-viewer-area {
        width: 100% !important;
        order: 2;
    }

    #toolbar {
        position: static; /* không cố định khi mobile */
        margin-bottom: 10px;
    }

    #pdf-container {
        height: 70vh !important;
    }

    .detail-baocao-container {
        width: 95% !important;
        margin: 20px auto !important;
    }

/*    .container {
        width: 100% !important;
        padding: 0 10px;
    }*/
}


/* ===========================================
   =======   SMALL MOBILE (max-width: 576px) =======
   =========================================== */
@media (max-width: 576px) {
    .pdf-list {
        max-height: 200px;
    }

    #pdf-container {
        height: 65vh !important;
        width: 100%;
    }

    #toolbar button {
        padding: 5px 8px;
        font-size: 12px;
    }

    canvas {
        width: 100% !important;
        height: auto !important;
    }
}
