* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    background-color: #ffffff;
    color: #333;
    overflow-x: hidden;
    padding: 10px;
}

.grid {
    display: grid;
    grid-template-columns: 1fr;
    grid-template-areas:
        "header"
        "nav"
        "article"
        "aside"
        "footer";
    gap: 20px;
    max-width: 1200px;
    margin: auto;
}

header {
    grid-area: header;
    background-color: #004080;
    color: white;
    padding: 20px;
    text-align: center;
}

nav {
    grid-area: nav;
    background-color: #e6f0ff;
    padding: 10px;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

article {
    grid-area: article;
    padding: 10px;
    background-color: #f9f9f9;
    border-radius: 5px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

aside {
    grid-area: aside;
    background-color: #f1f1f1;
    padding: 10px;
    max-width: 100%;
    overflow: hidden;
    border-radius: 5px;
}

aside iframe {
    width: 100%;
    height: 220px;
    border: none;
    display: block;
    overflow: hidden;
    border-radius: 5px;
}

footer {
    grid-area: footer;
    background-color: #ddd;
    text-align: center;
    padding: 10px;
    font-size: 0.9em;
    border-radius: 5px;
}

.nav1 {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 0;
    justify-content: center;
}

.nav1 li {
    margin: 5px;
}

.nav1 a {
    text-decoration: none;
    padding: 8px 12px;
    background-color: #0073e6;
    color: white;
    border-radius: 5px;
    transition: background-color 0.3s;
}

.nav1 a:hover {
    background-color: #005bb5;
}

.galeria {
    text-align: center;
    margin-top: 20px;
}

.galeria img {
    width: 100%;
    max-width: 600px;
    height: auto;
    object-fit: contain;
    border: 1px solid #ccc;
    border-radius: 8px;
}

#tabelaContainer {
    margin: 20px 0;
    overflow-x: auto;
    background-color: white;
    padding: 15px;
    border-radius: 5px;
    box-shadow: 0 0 5px rgba(0,0,0,0.05);
}

table {
    width: 100%;
    border-collapse: collapse;
    margin: 10px 0;
    font-size: 0.9em;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
}

table thead tr {
    background-color: #004080;
    color: #ffffff;
    text-align: left;
}

table th,
table td {
    padding: 12px 15px;
    border: 1px solid #dddddd;
}

table tbody tr {
    border-bottom: 1px solid #dddddd;
}

table tbody tr:hover {
    background-color: #f5f5f5;
    cursor: pointer;
}

table tbody tr:nth-child(even) {
    background-color: #f3f3f3;
}

table tbody tr:last-child {
    border-bottom: 2px solid #004080;
}

.controls {
    margin: 20px 0;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 5px;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: center;
}

.controls button {
    background-color: #004080;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.controls button:hover {
    background-color: #002b56;
}

.controls select {
    padding: 8px 15px;
    border-radius: 5px;
    border: 1px solid #ccc;
    background-color: white;
}

.summary {
    margin-top: 30px;
    padding: 20px;
    background-color: #e9ecef;
    border-radius: 5px;
}

.summary h3 {
    margin-top: 0;
    color: #004080;
}

.summary p {
    font-size: 1.1em;
    margin: 10px 0;
}

.summary span {
    font-weight: bold;
    color: #004080;
}

@media (min-width: 768px) {
    .grid {
        grid-template-columns: 3fr 1fr;
        grid-template-areas:
            "header header"
            "nav nav"
            "article aside"
            "footer footer";
    }

    aside {
        max-width: 100%;
    }
}

@media (max-width: 768px) {
    table {
        font-size: 0.8em;
    }
    
    table th,
    table td {
        padding: 8px 10px;
    }
    
    .controls {
        flex-direction: column;
        align-items: flex-start;
    }
}


