<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover">
    <meta name="theme-color" content="#0a8f86">
    <meta name="mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
    <meta name="apple-mobile-web-app-title" content="Just Exam League">
    <title>Student Login | Just Exam League</title>

    <link rel="icon" href="<?php echo e(asset('public/frontend/images/logo.png')); ?>">
    <link rel="apple-touch-icon" sizes="180x180" href="<?php echo e(asset('public/frontend/images/apple-touch-icon.png')); ?>">
    <link rel="manifest" href="<?php echo e(asset('public/site.webmanifest')); ?>">
    <link rel="preconnect" href="https://fonts.googleapis.com">
    <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
    <link href="https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800&family=Manrope:wght@400;500;600;700&display=swap" rel="stylesheet">
    <link rel="stylesheet" href="<?php echo e(asset('public/frontend/css/entry.css')); ?>">
</head>
<body class="jel-entry-page jel-student-login-page">
    <?php ($studentLoginAction = $loginActionUrl ?? route('login.studentpostLogin')); ?>
    <main class="jel-entry-shell jel-auth-shell">
        <section class="jel-auth-grid">
            <div class="jel-auth-copy">
                <a class="jel-auth-brand" href="<?php echo e(route('welcome')); ?>">
                    <img src="<?php echo e($brandImageUrl); ?>" alt="Just Exam League">
                    <span>Just Exam League</span>
                </a>

                <span class="jel-entry-kicker">Student Access</span>
                <h1>Login karke competition dashboard open kijiye.</h1>
                <p class="jel-entry-lead">
                    Mobile number ya email se sign in kijiye, wallet, competition join status, answer sheet aur result sab ek jagah milega.
                </p>

                <div class="jel-entry-stats jel-entry-stats-compact">
                    <?php $__currentLoopData = $loginStats; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $stat): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                        <article class="jel-entry-stat-card">
                            <strong><?php echo e(number_format((int) $stat['value'])); ?></strong>
                            <span><?php echo e($stat['label']); ?></span>
                        </article>
                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                </div>

                <?php if(!empty($secureEntryMode)): ?>
                    <div class="jel-auth-support">
                        <article class="jel-auth-step">
                            <strong>Temporary secure URL</strong>
                            <span>Yeh student login URL roughly <?php echo e($tokenTtlMinutes ?? 5); ?> minute ke liye valid rahega aur refresh/back par naya URL generate hoga.</span>
                        </article>
                        <article class="jel-auth-step">
                            <strong>One active browser entry</strong>
                            <span>Ek browser ke liye sirf ek active secure student login URL valid rahega.</span>
                        </article>
                    </div>
                <?php endif; ?>
            </div>

            <section class="jel-auth-card">
                <div class="jel-auth-card-header">
                    <h2>Student Login</h2>
                    <p>
                        Secure access for exam participation and result tracking.
                        <?php if(!empty($secureEntryMode)): ?>
                            Temporary protected student access active hai.
                        <?php endif; ?>
                    </p>
                </div>

                <?php if(Session::has('sucmessage')): ?>
                    <div class="jel-entry-alert jel-entry-alert-success">
                        <?php echo e(Session::get('sucmessage')); ?>

                    </div>
                <?php endif; ?>

                <?php if(Session::has('message')): ?>
                    <div class="jel-entry-alert jel-entry-alert-danger">
                        <?php echo e(Session::get('message')); ?>

                    </div>
                <?php endif; ?>

                <form class="jel-auth-form" action="<?php echo e($studentLoginAction); ?>" method="post">
                    <?php echo csrf_field(); ?>

                    <label class="jel-entry-field">
                        <span>Mobile Number or Email</span>
                        <input
                            type="text"
                            name="email"
                            maxlength="190"
                            value="<?php echo e(old('email')); ?>"
                            placeholder="Enter your mobile number or email"
                            required
                        >
                        <?php $__errorArgs = ['email'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?>
                            <small class="jel-entry-error"><?php echo e($message); ?></small>
                        <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?>
                    </label>

                    <label class="jel-entry-field">
                        <span>Password</span>
                        <div class="jel-password-field">
                            <input
                                type="password"
                                name="password"
                                id="password"
                                maxlength="50"
                                placeholder="Enter your password"
                                required
                            >
                            <button class="jel-password-toggle" id="passwordToggle" type="button" aria-label="Show password">
                                Show
                            </button>
                        </div>
                        <?php $__errorArgs = ['password'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?>
                            <small class="jel-entry-error"><?php echo e($message); ?></small>
                        <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?>
                    </label>

                    <div class="jel-auth-meta">
                        <label class="jel-remember-check">
                            <input type="checkbox" name="remember" value="1" <?php if((string) old('remember', '1') === '1'): echo 'checked'; endif; ?>>
                            <span>Remember me</span>
                        </label>

                        <a class="jel-auth-link" href="<?php echo e(route('admin.forgotpassword')); ?>">Forgot password?</a>
                    </div>

                    <button class="jel-entry-button jel-entry-button-primary jel-entry-button-block" type="submit">
                        Login Now
                    </button>
                </form>

                <div class="jel-auth-footer">
                    <span>New student?</span>
                    <a href="<?php echo e(route('admin.registration')); ?>">Create account</a>
                </div>

                <?php if(!empty($secureEntryMode) && !empty($tokenRefreshUrl)): ?>
                    <div class="jel-auth-footer">
                        <span>URL expire ho gaya?</span>
                        <a href="<?php echo e($tokenRefreshUrl); ?>">Generate fresh secure login URL</a>
                    </div>
                <?php endif; ?>
            </section>
        </section>
    </main>

    <script>
        const passwordField = document.getElementById('password');
        const passwordToggle = document.getElementById('passwordToggle');

        if (passwordField && passwordToggle) {
            passwordToggle.addEventListener('click', function () {
                const isPassword = passwordField.getAttribute('type') === 'password';
                passwordField.setAttribute('type', isPassword ? 'text' : 'password');
                passwordToggle.textContent = isPassword ? 'Hide' : 'Show';
                passwordToggle.setAttribute('aria-label', isPassword ? 'Hide password' : 'Show password');
            });
        }
    </script>
    <?php echo $__env->make('include.pwa-register', array_diff_key(get_defined_vars(), ['__data' => 1, '__path' => 1]))->render(); ?>
</body>
</html>
<?php /**PATH C:\xampp\htdocs\examproject\examproject_new\resources\views/auth/studentslogin.blade.php ENDPATH**/ ?>