body {
    font-family: Arial, Helvetica, sans-serif;
    margin: 0;
    background: radial-gradient(ellipse at top left, #112d40 0, #07111a 55%);
    min-height: 100vh;
    color-scheme: dark;
    color: #f1f5f9;
}

.container {
    max-width: 1500px;
    margin: 0 auto;
    padding: 20px;
}

.topo {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

h1 {
    margin: 0;
    font-size: 28px;
}

.subtitulo {
    color: #94b0c5;
    margin-top: 6px;
    font-size: 14px;
}

.acoes-topo {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.botao-topo {
    background: #2563eb;
    color: #fff;
    text-decoration: none;
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.botao-topo.secundario {
    background: #132330;
}

.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.card {
    background: #0e1c28;
    border: 1px solid #263e50;
    border-radius: 16px;
    padding: 18px;
    box-shadow: 0 2px 8px rgba(0,0,0,.16);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
    cursor: pointer;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(0,0,0,.28);
}

.card.ativo {
    outline: 2px solid #4da3ff;
    outline-offset: 0;
}

.card .icone {
    font-size: 26px;
    line-height: 1;
    margin-bottom: 8px;
}

.card h2 {
    margin: 0 0 8px 0;
    font-size: 15px;
    color: #94b0c5;
}

.card .numero {
    font-size: 32px;
    font-weight: bold;
}

.ok { border-left: 6px solid #2dd4a0; }
.atrasado { border-left: 6px solid #fb923c; }
.sem-status { border-left: 6px solid #94a3b8; }
.erro { border-left: 6px solid #fb7185; }
.total { border-left: 6px solid #4da3ff; }

.filtros {
    background: #0e1c28;
    padding: 15px;
    border: 1px solid #263e50;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,.16);
    margin-bottom: 20px;
}

.filtros form {
    display: grid;
    grid-template-columns: 1fr 220px 140px 140px 160px;
    gap: 10px;
}

.filtros input,
.filtros select,
.filtros button,
.filtros a {
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid #263e50;
    font-size: 14px;
    text-decoration: none;
    box-sizing: border-box;
}

.filtros button {
    background: #2563eb;
    color: #fff;
    border: none;
    cursor: pointer;
}

.filtros a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #132330;
    color: #c9def0;
}

.tabela-box {
    background: #0e1c28;
    border: 1px solid #263e50;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,.16);
    overflow: hidden;
}

table {
    width: 100%;
    border-collapse: collapse;
    min-width: 1200px;
}

th, td {
    padding: 12px 10px;
    border-bottom: 1px solid #263e50;
    text-align: left;
    vertical-align: top;
    font-size: 14px;
}

th {
    background: #0b1823;
    position: sticky;
    top: 0;
    z-index: 1;
}

.status-badge {
    display: inline-block;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: bold;
    color: #fff;
}

.status-ok { background: #153b36; color: #45e0b0; }
.status-atrasado { background: #713b1c; color: #ffdfb5; }
.status-sem-status { background: #263544; color: #cbd5e1; }
.status-erro { background: #402430; color: #fda4af; }

.linha-ok td { background: #0e2028; }
.linha-atrasado td { background: #3a271e; border-bottom-color: #65432e; }
.linha-sem-status td { background: #0b1823; }
.linha-erro td { background: #281e29; }

.mensagem {
    max-width: 380px;
    white-space: normal;
    word-break: break-word;
}

.rodape {
    margin-top: 12px;
    color: #94b0c5;
    font-size: 13px;
}

.filtros input,
.filtros select {
    background: #081620;
    color: #f1f5f9;
}

.filtros input {
    flex: 1 1 320px;
    min-width: 0;
}

.filtros input::placeholder {
    color: #94b0c5;
    opacity: 1;
}

th {
    color: #94b0c5;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible {
    outline: 2px solid #4da3ff;
    outline-offset: 3px;
}

.botao-topo:hover,
.filtros button:hover {
    background: #1d4ed8;
}

.botao-topo.secundario:hover,
.filtros a:hover {
    background: #1b3345;
}

tbody tr:hover > td {
    background: #182e3c;
}

.linha-atrasado td:first-child {
    box-shadow: inset 4px 0 #fb923c;
}

.linha-atrasado td:nth-child(7) {
    color: #ffbd80;
    font-weight: bold;
}

.linha-atrasado .botao-verificar {
    background: #4a2f1c;
    border-color: #b6753d;
    color: #ffdfb5;
}

tbody tr.linha-atrasado:hover > td {
    background: #4b3224;
}

@media (max-width: 900px) {
    .filtros form {
        grid-template-columns: 1fr;
    }

    .acoes-topo {
        width: 100%;
    }

    .botao-topo {
        width: 100%;
    }
}