
::-webkit-scrollbar {
    height: 8px;
    width: 7px;
}
::-webkit-scrollbar-thumb {
    background: #aaa;
}

body {
    line-height: initial;
    background-color: #FFFFFF;
    padding-bottom: 0;
}

label {
    font-weight: initial;
}

/* === Keyframes === */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes dotFade {
    0% { opacity: 1; }
    50% { opacity: 0.2; }
    100% { opacity: 1; }
}

/* === Animações de entrada === */
.animate-fade-in-up {
    opacity: 0;
    animation: fadeInUp 0.5s ease 0.2s forwards;
}

.animate-fade-in-up-delay {
    opacity: 0;
    animation: fadeInUp 0.5s ease 0.4s forwards;
}

/* === Loading spinner (blockUI) === */
.loading {
    position: relative;
    width: 48px;
    height: 48px;
    margin: 40px auto;
}

.loading .dot {
    position: absolute;
    width: 10px;
    height: 10px;
    background: var(--cor-primaria);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    margin: -5px 0 0 -5px;
    opacity: 1;
    animation: dotFade 1.2s linear infinite;
}

.loading .dot:nth-child(1) { transform: rotate(0deg) translate(20px); animation-delay: 0s; }
.loading .dot:nth-child(2) { transform: rotate(45deg) translate(20px); animation-delay: 0.15s; }
.loading .dot:nth-child(3) { transform: rotate(90deg) translate(20px); animation-delay: 0.3s; }
.loading .dot:nth-child(4) { transform: rotate(135deg) translate(20px); animation-delay: 0.45s; }
.loading .dot:nth-child(5) { transform: rotate(180deg) translate(20px); animation-delay: 0.6s; }
.loading .dot:nth-child(6) { transform: rotate(225deg) translate(20px); animation-delay: 0.75s; }
.loading .dot:nth-child(7) { transform: rotate(270deg) translate(20px); animation-delay: 0.9s; }
.loading .dot:nth-child(8) { transform: rotate(315deg) translate(20px); animation-delay: 1.05s; }

/* === InputBox + AnimatedLabel === */
.inputBox {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    margin-top: 16px;
}

.inputBox input,
.inputBox select {
    background-color: transparent;
    width: 100%;
    outline: none;
    font-size: 1rem;
    color: #374151;
    padding: 8px 12px;
    z-index: 1;
    border-radius: 6px;
    border: 1px solid #d1d5db;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.inputBox input:focus,
.inputBox select:focus {
    border-color: var(--cor-primaria);
}

.inputBox input.ui-state-error,
.inputBox select.ui-state-error {
    border-color: #f35f63 !important;
    transition: border-color 0.2s ease;
}

.inputBox input.ui-state-error:focus,
.inputBox select.ui-state-error:focus {
    border-color: #fbbabc !important;
}

.inputBox label {
    color: #374151;
    font-size: 0.875rem;
}

.inputBox:hover {
    cursor: text;
}

.inputBox.animatedLabel input:focus + label,
.inputBox.animatedLabel select:focus + label {
    color: var(--cor-primaria);
}

.inputBox.animatedLabel input:focus + label,
.inputBox.animatedLabel input:hover + label,
.inputBox.animatedLabel input:-webkit-autofill + label,
.inputBox.animatedLabel input:-webkit-autofill:focus + label,
.inputBox.animatedLabel input:-webkit-autofill:hover + label,
.inputBox.animatedLabel input:-webkit-autofill:active + label,
.inputBox.animatedLabel input:not(:placeholder-shown) + label,
.inputBox.animatedLabel select:focus + label,
.inputBox.animatedLabel select:hover + label,
.inputBox.animatedLabel select:-webkit-autofill + label,
.inputBox.animatedLabel select:-webkit-autofill:focus + label,
.inputBox.animatedLabel select:-webkit-autofill:hover + label,
.inputBox.animatedLabel select:-webkit-autofill:active + label,
.inputBox.animatedLabel select:not(:placeholder-shown) + label {
    top: -10px;
    left: 6px;
    font-size: 0.875rem;
    background-color: #fff;
}

.inputBox.animatedLabel input:-webkit-autofill,
.inputBox.animatedLabel input:-webkit-autofill:focus,
.inputBox.animatedLabel input:-webkit-autofill:hover,
.inputBox.animatedLabel input:-webkit-autofill:active,
.inputBox.animatedLabel select:-webkit-autofill,
.inputBox.animatedLabel select:-webkit-autofill:focus,
.inputBox.animatedLabel select:-webkit-autofill:hover,
.inputBox.animatedLabel select:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px #fff inset !important;
    box-shadow: 0 0 0 1000px #fff inset !important;
    -webkit-text-fill-color: #374151 !important;
    color: #374151 !important;
    transition: background-color 5000s ease-in-out 0s;
}

.inputBox.animatedLabel label {
    position: absolute;
    top: 8px;
    left: 12px;
    font-size: 1rem;
    color: #5e646c;
    transition: all 0.2s ease;
    pointer-events: none;
    z-index: 1;
}

.inputBox .ui-message-error {
    background-color: transparent;
    border: none;
    font-size: 1.4em;
    margin: 5px 0 0 0;
    padding: 0;
    display: flex;
    color: #f35f63;
}

/* === Divider (hr + span posicionado) === */
.login-divider {
    position: relative;
    width: 100%;
}

.login-divider hr {
    border: none;
    height: 1px;
    background-color: #e5e7eb;
}

.login-divider span {
    position: absolute;
    top: -0.8rem;
    left: 50%;
    transform: translateX(-50%);
    background-color: #fff;
    padding: 0 0.5rem;
    color: #6b7280;
    font-size: 0.875rem;
}

/* === Google icon (background-image) === */
.google-icon {
    background: url("https://developers.google.com/identity/images/g-logo.png") transparent no-repeat;
    height: 16px;
    width: 16px;
    background-size: cover;
    display: inline-block;
    vertical-align: middle;
}

/* === PrimeFaces commandButton reset === */
.login-btn span.ui-button-text {
    padding: 0;
}

.login-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background-color: #d1d5db;
    color: #4b5563;
    box-shadow: none;
}

.login-btn:disabled:hover {
    background-color: #d1d5db;
    transform: none;
}

/* === Footer (border-image gradiente) === */
.footer {
    font-family: ui-sans-serif, system-ui;
    width: 100%;
    border-top: 6px solid;
    border-image: linear-gradient(to right, var(--cor-terciaria), var(--cor-primaria)) 1;
    left: 0;
    position: initial;
    padding: 0;
}

/* === Link (text-decoration transition) === */
.link,
.link span {
    text-decoration: underline;
    text-decoration-color: transparent;
    font-size: 0.875rem;
    line-height: 1.25rem;
    transition: all 0.3s ease;
    color: var(--cor-link);
    background: transparent;
    border: none;
}

.link:hover,
.link span:hover {
    text-decoration-color: var(--cor-link);
}

/* === Utilitário: text-gray (componentes compartilhados) === */
.text-gray {
    color: #6b7280;
}

/* === Stepper === */
#stepper .steps {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 16px;
}

#stepper .steps hr {
    flex: 1;
    border: none;
    height: 4px;
    border-radius: 8px;
    background-color: #dedede;
}

#stepper .steps hr.active {
    background-color: var(--cor-primaria);
}

#stepper .stepTitle {
    font-size: 1rem;
    color: #242424;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#stepper .stepTitle .stepBox {
    display: none;
}

#stepper .stepTitle .stepBox span {
    font-size: 1.25rem;
    transition: all .3s;
    color: var(--cor-link);
}

#stepper .stepTitle .stepBox#stepTitle2:hover {
    cursor: pointer;
    opacity: .8;
}

/* === Step Content Wrapper (transição entre steps) === */
.step-content-wrapper {
    position: relative;
    min-height: 0;
    transition: height .4s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

/* === Step panels (animação entrada/saída) === */
#pngStep1,
#pngStep2 {
    display: none;
    opacity: 0;
    transform: translateX(50px);
    transition: opacity .4s ease, transform .4s ease;
}

#pngStep1.active,
#pngStep2.active {
    display: block;
    opacity: 1;
    transform: translateX(0);
}

#pngStep1.leaving,
#pngStep2.leaving {
    opacity: 0;
    transform: translateX(-50px);
    position: absolute;
    width: 100%;
}

/* === Check Password (validação de força) === */
.checkPassword {
    margin: .5rem 0;
}

.checkPassword #progressBar {
    width: 100%;
    background: #e5e7eb;
    height: 4px;
    border-radius: 5px;
    position: relative;
    transition: height .3s, border-radius .3s, background .3s;
}

.checkPassword #progressBar #progressBarFill {
    background: #ff1414;
    height: 100%;
    border-radius: 5px;
    width: 0;
    transition: width .3s, background .3s, border-radius .3s;
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.checkPassword #progressBar #progressBarFill #progressBarText {
    font-size: .85rem;
    font-weight: bold;
    margin-right: 8px;
    color: #fff;
    display: none;
    transition: color .3s;
}

.checkPassword #requirements {
    height: 0;
    overflow: hidden;
    transition: height .3s;
    border-radius: 5px;
    margin-top: .5rem;
}

.checkPassword #requirements #requirementsContent {
    display: none;
    flex-direction: column;
    gap: .5rem;
    padding: .5rem .75rem;
}

.checkPassword #requirements #requirementsContent span {
    font-size: .85rem;
    color: #606367;
    display: flex;
    align-items: center;
    gap: .5rem;
}

.checkPassword #requirements #requirementsContent span .icon {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: .5rem;
    transition: background-color .3s, color .3s;
    background-color: #e8210d;
}

.checkPassword #requirements #requirementsContent span .icon i.fa {
    color: #fff;
}

.checkPassword #requirements #requirementsContent span.active .icon {
    background-color: #059505;
    color: #fff;
}

/* === Check Equality (validação senhas iguais) === */
.checkEquality {
    margin-top: 5px;
}

.checkEquality #equality #equalityContent {
    font-size: .85rem;
    color: #606367;
    display: flex;
    align-items: center;
    gap: .5rem;
}

.checkEquality #equality #equalityContent .icon {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: .5rem;
    transition: background-color .3s, color .3s;
    background-color: #e8210d;
}

.checkEquality #equality #equalityContent .icon i.fa {
    color: #fff;
}

.checkEquality #equality #equalityContent span {
    flex: 1;
}

.checkEquality #equality #equalityContent.active .icon {
    background-color: #059505;
    color: #fff;
}

/* === Growl (PrimeFaces toast) === */
@keyframes growlFadeIn {
    0% {
        opacity: 0;
        transform: translateY(-30px) scale(0.95);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.ui-growl .ui-growl-item-container {
    border-radius: 4px;
    opacity: 1;
    animation: growlFadeIn .5s cubic-bezier(0.4, 0, 0.2, 1);
}

.ui-growl .ui-growl-item-container .ui-growl-image {
    display: none;
}

.ui-growl .ui-growl-item-container .ui-growl-message {
    font-family: ui-sans-serif, system-ui;
    width: 100%;
    padding: 0;
    margin: 0;
    font-size: .875rem;
    line-height: 1.25rem;
    font-weight: 800;
}

.ui-growl .ui-growl-item-container .ui-growl-message .ui-growl-title {
    font-weight: 700;
    font-size: 1rem;
    padding-bottom: 0;
    margin-bottom: 0;
}

.ui-growl .ui-growl-item-container.ui-growl-info {
    color: #fff;
    background-color: var(--cor-confirmar);
    border: none;
}

.ui-growl .ui-growl-item-container.ui-growl-warn {
    color: #fff;
    background-color: var(--cor-alerta);
    border: none;
}

.ui-growl .ui-growl-item-container.ui-growl-error,
.ui-growl .ui-growl-item-container.ui-growl-fatal {
    color: #fff;
    background-color: var(--cor-erro);
    border: none;
}

.ui-growl .ui-growl-item-container .ui-icon-closethick {
    font-family: "Material Design Icons";
    font-size: 18px;
    font-style: normal;
    font-weight: normal;
    font-variant: normal;
    text-transform: none;
    line-height: 1;
    display: inline-block;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-indent: 0 !important;
    text-align: center;
    background: 0;
    position: absolute;
    top: 5px;
    right: 5px;
}

.ui-growl .ui-growl-item-container .ui-icon-closethick:before {
    content: "\F0156";
}

.ui-growl .ui-growl-item-container .ui-icon-closethick:hover {
    opacity: .5;
}

.ui-growl .ui-growl-item-container.ui-shadow {
    -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.25);
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.25);
}

/* === Header (border-image gradiente — não pode ser Tailwind inline) === */
.header {
    border-top: 6px solid;
    border-image: linear-gradient(to right, var(--cor-primaria), var(--cor-terciaria)) 1;
}

/* === Botão overlay (commandButton invisível cobrindo parent) === */
.btn-overlay {
    position: relative;
}

.btn-overlay button {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: none;
    border: none;
    cursor: pointer;
}

.btn-overlay button .ui-button-text {
    padding: 0;
}

.btn-overlay:has(button:disabled) {
    opacity: 0.6;
    cursor: not-allowed;
    background-color: #d1d5db !important;
    color: #4b5563 !important;
}

.ui-dialog.dialog70 {
    width: 70% !important;
}

@media screen and (max-width: 640px) {
    .ui-dialog.dialog70 {
        width: 100% !important;
    }
}

.ui-widget-overlay {
    background: #000;
    opacity: 0.3;
    transition: opacity .15s linear;
}

/* === DataTable em lista/cards (seleção empresa) === */
.selecaoTable .ui-datatable-tablewrapper {
    border: none !important;
    border-radius: 0 !important;
}

.selecaoTable thead {
    display: none;
}

.selecaoTable tbody tr {
    border: 1px solid rgba(135, 135, 135, 0.2);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    flex-wrap: wrap;
    height: 107px;
    padding: 12px 16px;
    margin-bottom: 16px;
    transition: all 0.2s ease;
}

.selecaoTable tbody tr:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.selecaoTable tbody tr td {
    border: none;
    flex: 3 1px;
    padding: 0 !important;
    margin: 0;
}

.selecaoTable tbody tr td:last-child {
    flex: 1 100%;
    justify-content: center;
    display: flex;
    flex-direction: column;
    align-items: end;
}

@media (max-width: 640px) {
    .selecaoTable tbody tr {
        height: auto;
        gap: 5px;
    }
    .selecaoTable tbody tr td {
        flex: 1;
        text-align: right;
    }
    .selecaoTable tbody tr td .ui-column-title {
        font-size: 1em;
        font-weight: bold;
        text-transform: uppercase;
        padding: 0 !important;
        margin: 0 !important;
        min-width: initial !important;
        float: left;
        text-align: left;
        color: var(--cor-primaria);
    }
    .selecaoTable tbody tr td:last-child {
        flex: 1;
    }
    .selecaoTable tbody tr td:last-child a {
        width: 100%;
        text-align: center;
        margin-top: 15px;
    }
    .ui-datatable-reflow .ui-reflow-label,
    .ui-datatable-reflow .ui-reflow-dropdown {
        display: none;
    }
}
