@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}
 
body {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: 
        linear-gradient(rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.75)),
        url('../assets/img/banner-PeB.jpg') repeat center center;
    background-size: 400px;
    padding: 20px;
}

.container {
    position: relative;
    width: 100%;
    max-width: 450px;
    background: rgba(30, 30, 30, 0.9);
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    overflow: hidden;
    min-height: 650px;
    transition: min-height 0.5s ease;
}

.form-box {
    position: absolute;
    width: calc(100% - 80px);
    padding: 30px 40px;
    transition: transform 0.5s cubic-bezier(0.68, -0.55, 0.27, 1.55), opacity 0.4s ease-in-out;
    pointer-events: none;
    opacity: 0;
    z-index: 1;
}

.form-box.login {
    transform: translateX(0);
    opacity: 1;
    z-index: 2;
    pointer-events: auto;
}

.form-box.register {
    transform: translateX(100%);
}

.container.active .form-box.login {
    transform: translateX(-100%);
    opacity: 0;
    z-index: 1;
    pointer-events: none;
}

.container.active .form-box.register {
    transform: translateX(0);
    opacity: 1;
    z-index: 2;
    pointer-events: auto;
}

.container h1 {
    font-size: 32px;
    text-align: center;
    color: #fff;
    margin-bottom: 8px;
    font-weight: 700;
}

.subtitle {
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
    margin-bottom: 30px;
}

.register-link {
    font-size: 14px;
    text-align: center;
    margin-top: 25px;
    color: rgba(255, 255, 255, 0.7);
}

.register-link a.link-toggle {
    text-decoration: none;
    color: #00C853;
    font-weight: 600;
    transition: all 0.3s;
    position: relative;
    z-index: 10;
    cursor: pointer;
    display: inline-block;
    padding: 5px;
}

.register-link a.link-toggle:hover {
    color: #69F0AE;
    text-decoration: underline;
}

.input-box {
    position: relative;
    width: 100%;
    height: 55px;
    margin: 20px 0;
}

.input-box input {
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 40px;
    outline: none;
    font-size: 15px;
    color: #fff;
    padding: 0 50px 0 20px;
    transition: all 0.3s;
}

.input-box input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.input-box input:focus {
    border-color: #00C853;
    background: rgba(255, 255, 255, 0.08);
}

.input-box > i.bxs-envelope, 
.input-box > i.bxs-user, 
.input-box > i.bxl-whatsapp, 
.input-box > i.bxs-lock-alt {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 20px;
    color: rgba(255, 255, 255, 0.6);
    pointer-events: none;
}

.input-box:has(.btn-toggle-senha) input {
    padding-right: 55px;
}

.input-box:has(.btn-toggle-senha) > i.bxs-lock-alt {
    right: 55px;
}

.input-box input.input-invalido {
    border-color: #EF4444 !important;
    background-color: rgba(239, 68, 68, 0.1);
    animation: shake 0.4s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

.btn-toggle-senha {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    font-size: 18px;
    padding: 5px;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.btn-toggle-senha:hover {
    color: #fff;
}

.remember-forgot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 15px 0 25px;
    color: #fff;
    font-size: 13px;
}

.checkbox-container {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    user-select: none;
}

.checkbox-container input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #FFD424;
    cursor: pointer;
}

.checkbox-text {
    color: rgba(255, 255, 255, 0.8);
}

#esqueciSenha {
    color: rgba(255, 255, 255, 0.6);
    font-weight: 500;
    text-decoration: none;
    transition: color 0.3s;
}

#esqueciSenha:hover {
    color: #fff;
    text-decoration: underline;
}

.btn-submit {
    width: 100%;
    height: 55px;
    background: #00C853;
    border: none;
    border-radius: 40px;
    cursor: pointer;
    font-size: 16px;
    color: #fff;
    font-weight: 700;
    margin-top: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(0, 200, 83, 0.3);
}

.btn-submit:hover {
    background: #00E676;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 200, 83, 0.4);
}

.btn-submit:active {
    transform: translateY(0);
}

.btn-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.alert {
    padding: 15px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 14px;
    text-align: center;
    display: none;
    align-items: center;
    justify-content: center;
    gap: 8px;
    animation: slideDown 0.3s ease;
    word-wrap: break-word;
    white-space: normal;
    line-height: 1.5;
    width: 100%;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.alert.erro {
    display: flex;
    background: rgba(239, 68, 68, 0.25);
    border: 1px solid rgba(239, 68, 68, 0.6);
    color: #fecaca;
}

.alert.sucesso {
    display: flex;
    background: rgba(0, 200, 83, 0.25);
    border: 1px solid rgba(0, 200, 83, 0.6);
    color: #bbf7d0;
}

@media (max-width: 480px) {
    body { padding: 15px; }
    .container {
        padding: 30px 25px;
        border-radius: 15px;
        min-height: 600px;
    }
    .form-box {
        width: calc(100% - 50px);
        padding: 20px 25px;
    }
    .container h1 { font-size: 26px; }
    .input-box { height: 50px; margin: 15px 0; }
    .input-box input { font-size: 14px; padding: 0 45px 0 18px; }
    .btn-submit { height: 50px; font-size: 15px; }
    .remember-forgot { flex-direction: column; align-items: flex-start; gap: 12px; }
}