@extends('layouts.auth')

@section('content')

    <div class="container d-flex justify-center align-items-center" style="height: 80vh">
        <div class="row justify-content-center">
            <div class="col-md-8 col-lg-6 col-xl-5">
                <div class="card overflow-hidden">
                    <div class="bg-primary-subtle">
                        <div class="row">
                            <div class="col-7">
                                <div class="p-4">
                                    <h5 class="text-dark">{{ __('Welcome Back') }}</h5>
                                    <p>
                                        <span>{{ __('Sign in to continue to') }} :</span><br>
                                        <span class="text-primary fw-bold">{{ settings("gym_name") ?? "System GYM" }}</span>
                                    </p>
                                </div>
                            </div>

                            <div class="col-5 align-self-end">
                                <img src="{{ asset("assets/images/profile-img-0.png") }}" alt="" class="img-fluid">
                            </div>
                        </div>
                    </div>
                    <div class="card-body pt-0">
                        <div class="auth-logo">
                            <a href="{{ route('dashboard.index') }}" class="auth-logo-light">
                                <div class="avatar-md profile-user-wid mb-4">
                                    <span class="avatar-title rounded-circle bg-light">
                                        <img src="{{ settingsImage('site_favicon', 'ico') }}" alt="site_favicon" class="rounded-circle" height="34">
                                    </span>
                                </div>
                            </a>

                            <a href="{{ route('dashboard.index') }}" class="auth-logo-dark">
                                <div class="avatar-md profile-user-wid mb-4">
                                    <span class="avatar-title rounded-circle bg-white border border-light">
                                        <img src="{{ settingsImage('site_favicon', 'ico') }}" alt="site_favicon" class="rounded-circle" height="50">
                                    </span>
                                </div>
                            </a>
                        </div>

                        <div class="p-2">
                            <form class="form-horizontal" method="POST" action="{{ route('login') }}">
                                @csrf

                                <div class="mb-3">
                                    <label class="form-label" for="usernameAuth">{{ __('Username || Email') }}</label>
                                    <input type="text" class="form-control @error('username') is-invalid @enderror" id="usernameAuth" name="username" placeholder="Enter username or email" value="{{ old('email') }}" autofocus>
                                </div>

                                <div class="mb-3">
                                    <label class="form-label">{{ __('Password') }}</label>
                                    <div class="input-group auth-pass-inputgroup">
                                        <input type="password" class="form-control @error('password') is-invalid @enderror" name="password" placeholder="Enter password" aria-label="Password" aria-describedby="password-addon">
                                        <button class="btn btn-light " type="button" id="password-addon"><i class="mdi mdi-eye-outline"></i></button>
                                    </div>
                                </div>

                                <div class="mt-3 d-grid">
                                    <button class="btn btn-primary waves-effect waves-light" type="submit">{{ __('Log In') }}</button>
                                </div>
                            </form>
                        </div>

                    </div>
                </div>

                <div class="mt-5 text-center">
                    <div>
                        <p>© <script>document.write(new Date().getFullYear())</script> {{ 'ss' }}. Crafted with <i class="mdi mdi-heart text-danger"></i> by Al-Qattam</p>
                    </div>
                </div>
            </div>
        </div>
    </div>




@endsection
