/* ========================= */
/* BASE */
/* ========================= */

html{
    scroll-behavior:smooth;
}

::selection{
    background:#C9A857;
    color:#000;
}

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}

body{
    background:#fff;
    font-family:Arial,sans-serif;
    color:#111;
    min-height:100vh;
    overflow:hidden;
    display:flex;
    justify-content:center;
    align-items:center;
    position:relative;
}

/* FONDO */

body::before{
    content:"";
    position:absolute;
    inset:0;
    background:radial-gradient(circle at top,rgba(201,168,87,0.08),transparent 40%);
    pointer-events:none;
}

/* ========================= */
/* CONTENEDOR */
/* ========================= */

.auth-container {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100vh; /* Usa height en lugar de min-height para pruebas */
    position: fixed; /* Esto la clava al centro de la "ventana", no del documento */
    top: 0;
    left: 0;
    z-index: 2;
}

/* ========================= */
/* CAJA */
/* ========================= */

.auth-box {
    width: 100%;
    max-width: 390px;
    padding: 42px;
    text-align: center;
    border: 1px solid rgba(0,0,0,0.06);
    border-radius: 32px;
    background: rgba(255, 255, 255, 0.78);
    backdrop-filter: blur(14px);
    box-shadow: 0 20px 50px rgba(0,0,0,0.05);
    transition: all 0.35s ease; /* Transición suave para cuando cambie de tamaño */
    
    /* Esto asegura que el contenido se apile bien */
    display: flex;
    flex-direction: column;
    gap: 0; 
}

/* ========================= */
/* TITULOS */
/* ========================= */

.auth-box h1{
    font-size:2rem;
    font-weight:700;
    letter-spacing:6px;
    margin-bottom:10px;
}

.auth-box p{
    color:#666;
    font-size:0.95rem;
    line-height:1.7;
    margin-bottom:30px;
}

/* ========================= */
/* FORM */
/* ========================= */

form{
    width:100%;
}

/* INPUTS */

.auth-box input{
    width:100%;
    padding:15px 18px;
    margin-bottom:14px;
    border:1px solid rgba(0,0,0,0.08);
    border-radius:16px;
    outline:none;
    background:#fff;
    font-size:0.92rem;
    transition:border 0.25s ease,box-shadow 0.25s ease,transform 0.25s ease;
}

/* FOCUS */

.auth-box input:focus{
    border-color:rgba(201,168,87,0.45);
    box-shadow:0 0 0 4px rgba(201,168,87,0.08);
    transform:translateY(-1px);
}

/* ========================= */
/* PASSWORD FIELD */
/* ========================= */

.password-field{
    position:relative;
    width:100%;
    margin-bottom:14px;
    display:flex;
}

.password-field input{
    width:100%;
    padding-right:50px;
    margin-bottom:0;
}

/* OJO */

.toggle-password{
    position:absolute;
    right:16px;
    top:0%;
    transform:translateY(-50%);
    cursor:pointer;
    font-size:1rem;
    color:#aaa;
    user-select:none;
    transition:color 0.25s ease;
    display:flex;
    align-items:center;
}

.toggle-password:hover{
    color:#C9A857;
}

/* ========================= */
/* BOTÓN */
/* ========================= */

.auth-box button{
    width:100%;
    padding:15px;
    margin-top:4px;
    border:1px solid rgba(201,168,87,0.35);
    border-radius:999px;
    background:rgba(201,168,87,0.08);
    backdrop-filter:blur(10px);
    cursor:pointer;
    font-size:0.88rem;
    font-weight:600;
    letter-spacing:1.5px;
    transition:transform 0.3s ease,background 0.3s ease,box-shadow 0.3s ease;
}

/* HOVER */

.auth-box button:hover{
    background:#C9A857;
    transform:translateY(-3px);
    box-shadow:0 12px 30px rgba(201,168,87,0.2);
}

/* ========================= */
/* 2FA BOX */
/* ========================= */

.auth-box{
    width:390px;
    padding:42px;
    text-align:center;
    border:1px solid rgba(0,0,0,0.06);
    border-radius:32px;
    background:rgba(255,255,255,0.78);
    backdrop-filter:blur(14px);
    box-shadow:0 20px 50px rgba(0,0,0,0.05);
    transition:transform 0.35s ease,opacity 0.35s ease;
}

#twoFABox h2 {
    font-size: 1.5rem;
    margin-top: 10px; /* Un poco de aire arriba */
    margin-bottom: 10px;
    letter-spacing: -1px;
}

#twoFABox p{
    margin-bottom:24px;
}

#twoFABox input,
#twoFABox button{
    width:100%;
}



/* ========================= */
/* DIVIDER */
/* ========================= */

.divider{
    margin:24px 0;
    font-size:0.8rem;
    color:#aaa;
    position:relative;
}

.divider::before,
.divider::after{
    content:"";
    position:absolute;
    top:50%;
    width:38%;
    height:1px;
    background:#eee;
}

.divider::before{
    left:0;
}

.divider::after{
    right:0;
}

/* ========================= */
/* GOOGLE BTN */
/* ========================= */

.google-btn{
    width:100%;
    padding:14px;
    border:1px solid rgba(0,0,0,0.08);
    border-radius:16px;
    background:#fff;
    cursor:pointer;
    display:flex;
    align-items:center;
    justify-content:center;
    gap:10px;
    font-size:0.9rem;
    transition:transform 0.25s ease,background 0.25s ease,border 0.25s ease;
}

/* HOVER */

.google-btn:hover{
    background:#fafafa;
    border-color:rgba(201,168,87,0.3);
    transform:translateY(-2px);
}

/* ICONO */

.google-btn img{
    width:18px;
    height:18px;
}

/* ========================= */
/* LINKS */
/* ========================= */

.auth-box span{
    display:block;
    margin-top:24px;
    color:#666;
    font-size:0.88rem;
    line-height:1.7;
}

.auth-box a{
    color:#C9A857;
    text-decoration:none;
    font-weight:600;
}

/* ========================= */
/* RECAPTCHA */
/* ========================= */

#recaptcha-container{
    margin-top:18px;
    display:flex;
    justify-content:center;
}

/* ========================= */
/* TRANSICIONES */
/* ========================= */

.fade-out{
    opacity:0;
    transform:translateY(-10px);
    transition:0.4s ease;
}

.fade-in{
    opacity:1;
    transform:translateY(0);
    transition:0.4s ease;
}

@keyframes fadeUp{
    from{
        opacity:0;
        transform:translateY(15px);
    }

    to{
        opacity:1;
        transform:translateY(0);
    }
}

/* ========================= */
/* RESPONSIVE */
/* ========================= */

@media (max-width:768px){

    body{
        overflow:auto;
    }

    .auth-container{
        padding:20px;
    }

    .auth-box{
        padding:34px 24px;
        border-radius:28px;
    }

    .auth-box h1{
        font-size:1.7rem;
        letter-spacing:5px;
    }

    .auth-box p{
        font-size:0.9rem;
    }

    #twoFABox h2{
        font-size:1.3rem;
    }
}

#recaptcha-container{
    position:absolute;
    left:-9999px;
}

.grecaptcha-badge{
    display:none !important;
}