/* assets/css/modals/modal-register.css (Reconstruido) */

.modal--register .modal__content {
    background: #1f2937;
    border: 2px solid #a78bfa;
    box-shadow: 0 0 25px rgba(167, 139, 250, 0.5);
    display: flex;
    max-width: 450px;
    width: 95vw;
    height: auto;
    max-height: 95vh;
    padding: 0;
    overflow: hidden;
    flex-direction: column; /* Vista por defecto para móvil vertical */
}

.register-visual-col, .register-form-col {
    display: flex;
    flex-direction: column;
    justify-content: flex-start; 
    overflow-y: auto;
}

.register-visual-col {
    display: none; /* Oculto por defecto, solo visible en horizontal */
    padding: 20px;
    text-align: center;
    color: #e5e7eb;
    background: linear-gradient(145deg, #4c1d95, #2c1255);
    justify-content: center; 
}

.register-form-col {
    padding: 20px;
    background-color: rgba(0,0,0,0.2);
}

.register-title {
    color: #c4b5fd;
    font-size: 1.8rem;
    margin: 0 0 10px 0;
}

.register-subtitle {
    font-size: 1rem;
    opacity: 0.9;
    line-height: 1.6;
}

.form-col-title {
    text-align: center;
    color: #c4b5fd;
    font-size: clamp(1.2rem, 3vh, 1.5rem);
    margin: 0 0 20px 0;
    font-weight: bold;
    flex-shrink: 0; 
}

.form-feedback {
    background-color: #ef4444;
    color: white;
    padding: 10px 15px;
    border-radius: 6px;
    margin-bottom: 15px;
    font-size: 0.9em;
    text-align: center;
}
.form-feedback.success { background-color: #22c55e; }

.budi-auth-form .form-grid {
    display: grid;
    gap: 0;
}

.budi-auth-form .form-group {
    position: relative;
}

.budi-auth-form .form-icon {
    position: absolute;
    top: 50%;
    left: 15px;
    transform: translateY(-50%);
    color: #8b5cf6;
    pointer-events: none;
    width: 20px;
    height: 20px;
}

.budi-auth-form input {
    width: 100%;
    background-color: #374151;
    border: 1px solid #4b5563;
    color: #e5e7eb;
    padding: 12px 15px 12px 50px;
    box-sizing: border-box;
    font-size: 1em;
    transition: border-color 0.3s;
    border-radius: 0;
    border-width: 0 1px 1px 0;
}
.budi-auth-form input:focus {
    outline: none;
    border-color: #a78bfa;
}
.budi-auth-form input::placeholder {
    color: #9ca3af;
    opacity: 1;
    font-size: 0.9em;
}

.password-toggle {
    position: absolute;
    top: 50%;
    right: 12px;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    width: 24px;
    height: 24px;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%239ca3af"><path d="M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5C21.27 7.61 17 4.5 12 4.5zm0 12c-2.48 0-4.5-2.02-4.5-4.5S9.52 7.5 12 7.5s4.5 2.02 4.5 4.5-2.02 4.5-4.5 4.5zm0-7C10.62 9.5 9.5 10.62 9.5 12s1.12 2.5 2.5 2.5 2.5-1.12 2.5-2.5S13.38 9.5 12 9.5z"/></svg>');
    background-size: contain;
    background-repeat: no-repeat;
}
.password-toggle.is-showing {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%239ca3af"><path d="M12 7c2.76 0 5 2.24 5 5 0 .65-.13 1.26-.36 1.83l2.92 2.92c1.51-1.26 2.7-2.89 3.43-4.75-1.73-4.39-6-7.5-11-7.5-1.4 0-2.74.25-3.98.7l2.16 2.16C10.74 7.13 11.35 7 12 7zM2 4.27l2.28 2.28.46.46C3.08 8.3 1.78 10.02 1 12c1.73 4.39 6 7.5 11 7.5 1.55 0 3.03-.3 4.38-.84l.42.42L19.73 22 21 20.73 3.27 3 2 4.27zM7.53 9.8l1.55 1.55c-.05.21-.08.43-.08.65 0 1.66 1.34 3 3 3 .22 0 .44-.03.65-.08l1.55 1.55c-.67.33-1.41.53-2.2.53-2.48 0-4.5-2.02-4.5-4.5 0-.79.2-1.53.53-2.2zm4.31-.78l3.15 3.15.02-.16c0-1.66-1.34-3-3-3l-.17.01z"/></svg>');
}

.form-group-terms {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 15px;
}
.form-group-terms input[type="checkbox"] { width: auto; }
.form-group-terms label { font-size: 0.8em; color: #d1d5db; }
.form-group-terms label a { color: #a78bfa; }

.form-footer { margin-top: 20px; text-align: center; }
.form-footer .btn { width: 100%; font-size: 1.1em; }
.switch-form-text { margin-top: 15px; font-size: 0.8em; color: #9ca3af; }
.btn-text-switch { background: none; border: none; color: #a78bfa; text-decoration: underline; font-weight: bold; cursor: pointer; padding: 0; }

.lost-password-wrapper {
    margin: 15px 0 0 0;
    padding: 0;
}

/* ======================================================================== */
/* INICIO DE LA MODIFICACIÓN */
/* ======================================================================== */
.register-visual-footer {
    margin-top: 20px;
    width: 100%;
    max-width: 250px;
}
/* ======================================================================== */
/* FIN DE LA MODIFICACIÓN */
/* ======================================================================== */


/* --- PRIORIDAD: VISTA MÓVIL HORIZONTAL Y ESCRITORIO --- */
@media (orientation: landscape) {
    .modal--register .modal__content {
        flex-direction: row;
        align-items: stretch;
        max-width: 900px;
        width: 90vw;
        height: 85vh;
        max-height: 650px;
    }
    .register-visual-col {
        display: flex;
        flex: 0 0 30%;
    }
    .register-form-col { 
        flex: 1 1 70%; 
        min-height: 0;
    }
    .budi-auth-form .form-grid {
        grid-template-columns: 1fr 1fr;
    }
    .form-group-full { grid-column: 1 / -1; }
}

/* Reglas específicas para pantallas horizontales de poca altura (móviles) */
@media (orientation: landscape) and (max-height: 550px) {
    .register-form-col { padding: 20px; }
    .budi-auth-form .form-grid {
        gap: 0;
    }
    .budi-auth-form .form-group input {
        border-radius: 0;
        border-width: 0 1px 1px 0;
    }
    .form-grid .form-group:nth-child(2n+1) input { border-left-width: 1px; } 
    .form-grid .form-group:first-child input, .form-grid .form-group:nth-child(2) input { border-top-width: 1px; } 
    
    .form-grid .form-group:first-child input { border-top-left-radius: 6px; }
    .form-grid .form-group:nth-child(2) input { border-top-right-radius: 6px; }
    .form-grid .form-group:nth-last-child(2) input { border-bottom-left-radius: 6px; }
    .form-grid .form-group:last-child input { border-bottom-right-radius: 6px; }
    .form-group.form-group-full input { border-radius: 6px; border-width: 1px; }
}