body {
    font-family: Arial, sans-serif;
    background-color: #f7f7f7;
    margin: 0;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.form-container, .list-container {
    background-color: #fff;
    padding: 20px;
    margin-bottom: 30px;
    border-radius: 8px;
    width: 95%;
    max-width: 1000px;
    box-shadow: 0 0 8px rgba(0,0,0,0.1);
}

h1, h2 {
    margin-top: 0;
    text-align: center;
    color: #333;
}

/* Agrupamento dos campos principais em duas colunas */
.form-container form > div:not(.full-width):not(.date-group):not(.problema-container) {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px 30px;
    margin-bottom: 15px;
}

/* Deixa cada label e input verticalmente alinhados */
.form-container form > div:not(.full-width):not(.date-group):not(.problema-container) > div {
    display: flex;
    flex-direction: column;
}

form label {
    font-weight: bold;
    margin-bottom: 4px;
}

input[type="text"], input[type="date"], textarea {
    padding: 6px;
    border: 1px solid #ccc;
    border-radius: 4px;
    width: 100%;
}

textarea {
    resize: vertical;
    min-height: 60px;
}

/* Grupo das datas lado a lado */
.date-group {
    display: flex;
    gap: 30px;
    margin-bottom: 15px;
}

.date-group > div {
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Problema relatado ocupa 100% da largura */
.problema-container {
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
}

input[type="submit"] {
    background-color: #2a7de1;
    color: white;
    padding: 10px 18px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    margin-top: 10px;
}

input[type="submit"]:hover {
    background-color: #1e5fb8;
}

/* Tabela de itens */
.itens-table, table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    font-size: 14px;
}

.itens-table th, .itens-table td,
table th, table td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: left;
    vertical-align: top;
}

table thead {
    background-color: #f0f0f0;
}

table tbody tr:nth-child(even) {
    background-color: #f9f9f9;
}

/* Ações */
td a {
    color: #2a7de1;
    text-decoration: none;
    margin-right: 8px;
    font-weight: bold;
}

td a:hover {
    text-decoration: underline;
}

/* Para destacar o total */
td strong {
    color: #0a6d2c;
    font-weight: bold;
}

/* Responsivo simples */
@media (max-width: 768px) {
    .form-container, .list-container {
        width: 98%;
        padding: 15px;
    }

    table, .itens-table {
        font-size: 12px;
    }
  
    /* Para os campos em telas pequenas, tudo empilha */
    .form-container form > div:not(.full-width):not(.date-group):not(.problema-container) {
        grid-template-columns: 1fr;
    }

    .date-group {
        flex-direction: column;
        gap: 10px;
    }
}
