body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.header {
    background-color: #333;
    color: white;
    padding: 1rem;
    text-align: center;
}

.pdf-list {
    background-color: #e2e2e2;
    padding: 1rem;
    border-bottom: 1px solid #ccc;
}

.pdf-list ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}

.pdf-list li {
    margin: 0 10px;
}

.pdf-list a {
    text-decoration: none;
    color: #007bff;
    padding: 8px 15px;
    border: 1px solid #007bff;
    border-radius: 5px;
    transition: background-color 0.3s, color 0.3s;
}

.pdf-list a:hover {
    background-color: #007bff;
    color: white;
}

.pdf-viewer-container {
    flex-grow: 1; /* Allows the container to take up remaining vertical space */
    padding: 20px;
    box-sizing: border-box;
    display: flex; /* Use flex to make the iframe fill the container */
    justify-content: center;
    align-items: center;
}

#pdfFrame {
    width: 100%;
    height: 100%; /* Make iframe fill its parent container */
    border: 1px solid #ccc;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

html, body {
    height: 100%; /* Important: Make html and body take full viewport height */
    margin: 0;
    padding: 0;
    overflow: hidden; /* Prevent extra scrollbars on the main page */
}

body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
    display: flex; /* Make body a flex container */
    flex-direction: column; /* Stack children vertically */
}

.header {
    background-color: white;
    color: #333;
    padding: 1rem;
    text-align: center;
    flex-shrink: 0; /* Prevent header from shrinking */
}

.pdf-list {
    background-color: #e2e2e2;
    padding: 1rem;
    border-bottom: 1px solid #ccc;
    flex-shrink: 0; /* Prevent list from shrinking */
}

.pdf-list ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}

.pdf-list li {
    margin: 0 10px;
}

.pdf-list a {
    text-decoration: none;
    color: #007bff;
    padding: 8px 15px;
    border: 1px solid #007bff;
    border-radius: 5px;
    transition: background-color 0.3s, color 0.3s;
}

.pdf-list a:hover {
    background-color: #007bff;
    color: white;
}

.pdf-viewer-container {
    flex-grow: 1; /* This is the key: allows the container to take all available vertical space */
    padding: 20px; /* Add some padding around the iframe */
    box-sizing: border-box; /* Include padding in the element's total width and height */
    display: flex; /* Make this a flex container too */
    justify-content: center; /* Center horizontally if content doesn't fill */
    align-items: center; /* Center vertically if content doesn't fill */
}

#pdfFrame {
    width: 100%; /* Make iframe fill its parent container's width */
    height: 100%; /* Make iframe fill its parent container's height */
    border: 1px solid #ccc;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.header {
    background-color: white;
    color: #333;
    padding: 1rem;
    text-align: center; /* This will center the text if no logo, or center within the remaining space if logo is present */
    flex-shrink: 0;

    /* New Flexbox properties for header */
    display: flex; /* Make header a flex container */
    align-items: center; /* Vertically align items in the center */
    justify-content: center; /* Center content by default */
    position: relative; /* Needed for absolute positioning of logo if desired for more control */
}

.header-logo {
    /* Style for your logo */
    height: 50px; /* Adjust as needed for your logo's height */
    margin-right: 20px; /* Space between logo and title */
    /* If you want the logo to be fixed on the far left, you could use absolute positioning: */
    /* position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%); */
}

.header h1 {
    margin: 0; /* Remove default margin from h1 */
    /* If logo is absolutely positioned and you want h1 truly centered in the remaining space: */
    /* flex-grow: 1;
    text-align: center; */
}


.pdf-viewer-container {
    flex-grow: 1;
    padding: 1px;
    box-sizing: border-box;
    display: flex;
    justify-content: center;
    align-items: center;
}

#pdfFrame {
    width: 100%;
    height: 100%;
    border: 1px solid #ccc;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    background-color: white; /* Add this line */
}