﻿html,
body {
    width: 100%;
    min-height: 100%;
    margin: 0;
    padding: 0;
}

body {
    overflow-x: hidden;
    background-color: #061731;
    font-family: "Source Sans Pro", Arial, Helvetica, sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

.portal-login-page,
.portal-sistemas-page {
    width: 100%;
    min-height: 100vh;
    background-color: #061731;
    color: #061731;
    font-family: "Source Sans Pro", Arial, Helvetica, sans-serif;
}

.portal-login-page {
    padding: 56px 20px;
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.portal-login-card {
    width: min(460px, 94vw);
    background-color: #f3f3f3;
    border-radius: 12px;
    padding: 0 36px 38px;
    color: #061731;
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.25);
    overflow: hidden;
}

.portal-login-logo-area {
    margin: 0 -36px 28px;
    padding: 30px 30px 26px;
    background-color: #ffffff;
    border-bottom: 7px solid #de671f;
    text-align: center;
}

.portal-login-logo {
    width: 250px;
    max-width: 100%;
    height: auto;
    display: inline-block;
}

.portal-login-card h1 {
    margin: 0 0 8px;
    color: #061731;
    font-size: 30px;
    line-height: 1.2;
    font-weight: 800;
    text-align: center;
}

.portal-login-card p {
    margin: 0 0 26px;
    color: #444444;
    font-size: 16px;
    line-height: 1.4;
    text-align: center;
}

.portal-login-field {
    margin-bottom: 17px;
}

    .portal-login-field label {
        display: block;
        margin-bottom: 6px;
        color: #061731;
        font-size: 15px;
        font-weight: 800;
    }

.portal-login-input {
    width: 100%;
    min-height: 46px;
    padding: 11px 13px;
    border: 1px solid #c8c0b8;
    border-radius: 7px;
    background-color: #ffffff;
    color: #222222;
    font-size: 16px;
    outline: none;
}

    .portal-login-input:focus {
        border-color: #de671f;
        box-shadow: 0 0 0 3px rgba(222, 103, 31, 0.16);
    }

.portal-login-btn {
    width: 100%;
    min-height: 50px;
    margin-top: 8px;
    padding: 13px 20px;
    border: none;
    border-radius: 999px;
    background-color: #de671f;
    color: #ffffff;
    font-size: 17px;
    font-weight: 800;
    cursor: pointer;
}

    .portal-login-btn:hover {
        filter: brightness(1.05);
    }

.portal-login-message-error,
.portal-message-error {
    margin: 0 0 20px;
    padding: 13px 15px;
    border-radius: 8px;
    background-color: #f8d7da;
    color: #842029;
    border: 1px solid #f1aeb5;
    font-size: 14px;
    line-height: 1.35;
    font-weight: 700;
}

.portal-sistemas-page {
    padding: 42px 20px 70px;
}

.portal-sistemas-container {
    width: min(1180px, 96vw);
    margin: 0 auto;
}

.portal-sistemas-topo {
    margin-bottom: 28px;
    padding: 28px 32px;
    background-color: #f3f3f3;
    border-radius: 14px;
    display: flex;
    gap: 20px;
    align-items: flex-start;
    justify-content: space-between;
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

.portal-sistemas-logo {
    width: 260px;
    max-width: 100%;
    height: auto;
    display: block;
    margin-bottom: 22px;
}

.portal-sistemas-topo h1 {
    margin: 0 0 8px;
    color: #061731;
    font-size: 34px;
    line-height: 1.15;
    font-weight: 800;
}

.portal-sistemas-topo p {
    margin: 0;
    color: #555555;
    font-size: 17px;
    line-height: 1.4;
}

.portal-sair-btn {
    padding: 11px 20px;
    border: none;
    border-radius: 999px;
    background-color: #6c757d;
    color: #ffffff;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
}

    .portal-sair-btn:hover {
        filter: brightness(1.05);
    }

.portal-loading,
.portal-vazio {
    padding: 28px;
    background-color: #f3f3f3;
    border-radius: 14px;
    color: #061731;
    text-align: center;
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

    .portal-vazio h2 {
        margin: 0 0 10px;
        font-size: 26px;
        font-weight: 800;
    }

    .portal-vazio p {
        margin: 0;
        color: #555555;
        font-size: 16px;
    }

.portal-sistemas-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.portal-sistema-card {
    min-height: 150px;
    padding: 24px;
    background-color: #f3f3f3;
    color: #061731;
    border-radius: 14px;
    display: flex;
    gap: 18px;
    align-items: flex-start;
    text-decoration: none;
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

    .portal-sistema-card:hover {
        color: #061731;
        text-decoration: none;
        transform: translateY(-3px);
        box-shadow: 0 22px 48px rgba(0, 0, 0, 0.28);
    }

.portal-sistema-icone {
    width: 52px;
    min-width: 52px;
    height: 52px;
    border-radius: 14px;
    background-color: #de671f;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    line-height: 1;
    font-weight: 800;
}

.portal-logout-form {
    display: inline-flex;
    align-items: center;
    margin: 0;
    padding: 0;
}

.portal-sistema-card strong {
    display: block;
    margin: 0 0 8px;
    color: #061731;
    font-size: 21px;
    line-height: 1.2;
    font-weight: 800;
}

.portal-sistema-card span {
    display: block;
    color: #555555;
    font-size: 15px;
    line-height: 1.35;
}

@media screen and (max-width: 900px) {
    .portal-sistemas-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

h1:focus,
h1:focus-visible {
    outline: none !important;
}

@media screen and (max-width: 640px) {
    .portal-login-page,
    .portal-sistemas-page {
        padding: 28px 14px 50px;
    }

    .portal-login-card {
        padding: 0 24px 34px;
    }

    .portal-login-logo-area {
        margin: 0 -24px 24px;
        padding: 28px 20px 22px;
    }

    .portal-login-logo {
        width: 220px;
    }

    .portal-sistemas-topo {
        padding: 24px 22px;
        flex-direction: column;
    }

    .portal-sistemas-logo {
        width: 230px;
    }

    .portal-sistemas-topo h1 {
        font-size: 29px;
    }

    .portal-sistemas-grid {
        grid-template-columns: 1fr;
    }

    .portal-sair-btn {
        width: 100%;
    }
}
