<?php if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly ?>

<div class="overlay" id="overlay"></div>

<?php

$stored_response = get_option( 'unleash_ai_registration_response' );
if ( $stored_response ) {
    $stored_response = json_decode( $stored_response, true ); // Decode if needed
}
 //print_r($response_data);
        if($stored_response){
   
 // Display secret key and regeneration form
 echo '<div class="flexWrap47New fullFlexUnleash">';
    echo '<div class="wrap secretKetM loginButtonsKey" style="text-align:center;">';
    echo '<h2 style="margin-bottom:30px;">You have successfully logged in to the Unleash AI server and are ready to generate titles, descriptions, and alt text for your site.
</h2>';
	echo '<div class="centerButtonsKey buttonsKeyOny2Btns">';
    echo '<a href="admin.php?page=cg_meta_al_list"><button class="" id="">Generate Meta Tags</button></a>';
	echo '<a href="admin.php?page=cg_meta_al_altag"><button class="" id="copy-btn">Generate Alt Tags</button></a>';
   
	echo '</div>';
	echo '<p style="margin-top:30px;">If you encounter any issues with the plugin or have suggestions for improvement, please don’t hesitate to reach out to us at <a href="mailto:support@unleashai.co">support@unleashai.co</a>. Our team will respond to your queries as soon as possible. 




</p>';
    
	echo '</div></div>';

         } else { ?>
		 
		 		 <div class="flexWrap47New centeral">
<div class="secretKetM cRosspopup loginAreaMeta " style="width: 470px;   max-width: 100%;">
    <h2>Login with your UnleashAI’s credentials or   <span>sign up for a new account</span>   </h2>
    <span style="display:none;" class="m-2" id="error_message_show_login"></span>

   <input type="text" class="m-2 form-control" id="user_name_login" placeholder="User Name">
    <span style="display:none;" class="subscription_error" id="error_username_login"></span>
    
    <!--<input type="email" id="email_login" placeholder="Your Email">
    <span style="display:none;" class="subscription_error" id="error_email_login"></span>-->

    <input type="password" class="m-2 form-control" id="password_login" placeholder="">
    <span style="display:none;" class="subscription_error" id="error_password_login"></span>

    <button class="btn btn-primary m-2" onclick="submitLogin()">SIGN IN</button>
	<!--<button class="btn btn-primary m-2" onclick="window.location.href='https://unleashai.co/auth/login'">Login here</button>-->

    <span style="display:none;" id="message_show_login"></span>
	<div class="linksogin733">
                <ul>
                    <li><a target="_blank" href="https://unleashai.co/auth/reset_password_request">Forgot Password</a></li>
                    <li><a target="_blank" href="https://unleashai.co/auth/register/1">Create New Account</a></li> 
                </ul>
            </div>

 </div>   

 
</div>
		 
		 
		 
		<?php   
     
    } ?>

    <?php
       
        exit;
    ?>

</div>