/* Base styles for all screen sizes */

@import url('fonts/Serif/cmun-serif.css');

body {
    font-family: 'Computer Modern Serif';
}

h1, h2 {
    font-size: 24px;
    font-weight: bold;
    margin: 20px 0;
    text-align: center;
}
figcaption {
    text-align: center;
}
.content {
    width: 50%;
    padding: 20px;
    border-radius: 10px;
    text-align: justify;
    margin: 20px auto; /* Center horizontally */
}

.content img {
    display: block;
    margin: 0 auto;
    max-width: 100%;
    max-height: 550px;
    overflow-y: auto;
}

/* Media query for small screens (e.g., cellphones) */
@media screen and (max-width: 768px) {
    h1, h2 {
        font-size: 20px; /* Smaller font size */
        margin: 10px 0; /* Smaller top and bottom margins */
    }

    .content {
        width: 90%; /* Wider content on small screens */
        padding: 10px; /* Smaller padding */
        margin: 10px auto; /* Center horizontally */
    }
}

pre {
    white-space: pre-wrap;       /* CSS 3 */
    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;       /* Internet Explorer 5.5+ */
    overflow-x: auto;
}

code {
    white-space: pre-wrap;
    word-wrap: break-word;
    overflow-wrap: break-word;
}
figcaption {
    text-align: center;
    font-style: italic;
    color: #666666; /* A medium gray color */
}
table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
    overflow-x: auto;
    display: block;
}

@media screen and (max-width: 768px) {
    table {
        font-size: 14px; /* Smaller font size on mobile */
    }
}

th, td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: left;
    word-wrap: break-word;
    max-width: 200px; /* Adjust this value as needed */
}

th {
    background-color: #f2f2f2;
}

/* For very small screens, make the table scrollable horizontally */
@media screen and (max-width: 480px) {
    table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
    
    th, td {
        white-space: normal;
    }
}
