<!DOCTYPE html>
<html lang="<?php echo e(str_replace('_', '-', app()->getLocale())); ?>">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">

    <title><?php echo e(config('app.name', 'Laravel')); ?> - Authorization</title>

    <!-- Fonts -->
    <link rel="dns-prefetch" href="//fonts.gstatic.com">
    <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet" type="text/css">
    <link rel="stylesheet" href="https://use.typekit.net/yhq3afd.css">

    <!-- Styles -->
    <link href="<?php echo e(asset('css/app.css')); ?>" rel="stylesheet">

    <style>
        /* Replicating callback.vue design */
        body {
            margin: 0;
            font-family: 'proxima-nova', 'sans-serif';
        }

        .callback-page {
            background-color: #001633;
            width: 100%;
            min-height: 100vh;
            position: relative;
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 32px 0;
        }

        .callback-background {
            position: fixed;
            bottom: 0;
            right: 0;
            width: 100vw;
            height: 100vh;
            z-index: 1;
            background-image: url('/assets/img/login.jpg');
            background-repeat: no-repeat;
            background-size: cover;
            background-position: bottom right;
        }

        .callback-form-holder {
            position: relative;
            display: flex;
            width: calc(100% - 5.333vw);
            min-height: 400px;
            padding: 32px;
            flex-direction: column;
            justify-content: center;
            align-items: center;
            gap: 16px;
            border-radius: 8px;
            border: 1px solid #F2F3F5;
            background: #fff;
            z-index: 2;
            max-width: 500px;
        }

        .callback-form-holder h2 {
            color: #001633;
            font-size: 24px;
            font-weight: 600;
            margin: 0;
        }

        .callback-content {
            width: 100%;
            display: flex;
            flex-direction: column;
            gap: 16px;
        }

        .callback-state {
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 16px;
            padding: 24px;
            text-align: center;
        }

        .state-title {
            margin: 0;
            font-size: 18px;
            font-weight: 500;
            color: #001633;
        }

        .state-message {
            margin: 0;
            font-size: 14px;
            color: #667385;
            line-height: 1.5;
        }

        .state-icon {
            width: 48px;
            height: 48px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .state-icon svg {
            width: 24px;
            height: 24px;
        }

        .info-icon {
            background-color: #CCEBF8;
            color: #009ADE;
        }

        .scopes {
            background-color: #F3F7F9;
            border-radius: 8px;
            padding: 16px;
            margin: 16px 0;
        }

        .scopes p {
            margin: 0 0 12px 0;
            font-weight: 600;
            color: #001633;
        }

        .scopes ul {
            margin: 0;
            padding-left: 20px;
        }

        .scopes li {
            color: #667385;
            margin-bottom: 8px;
            text-align: left;
        }

        .auth-buttons {
            display: flex;
            gap: 12px;
            justify-content: center;
            flex-wrap: wrap;
            margin-top: 24px;
        }

        .btn {
            display: inline-flex;
            align-items: center;
            padding: 12px 20px;
            color: #fff;
            text-decoration: none;
            border-radius: 4px;
            font-weight: 500;
            transition: background-color 0.2s ease;
            border: none;
            cursor: pointer;
            font-size: 16px;
        }

        .btn-success {
            background-color: #16a34a;
        }

        .btn-success:hover {
            background-color: #15803d;
        }

        .btn-danger {
            background-color: #dc2626;
        }

        .btn-danger:hover {
            background-color: #b91c1c;
        }

        /* Responsive behavior */
        @media (max-width: 768px) {
            .callback-page {
                align-items: flex-start;
                justify-content: flex-start;
                padding: 20px;
            }

            .callback-form-holder {
                width: calc(100%);
                max-width: none;
                margin-top: 50px;
                padding: 12px;
            }

            .auth-buttons {
                flex-direction: column;
                align-items: center;
            }

            .btn {
                width: 100%;
                max-width: 200px;
            }
        }

        @media (min-width: 768px) {
            .callback-form-holder {
                position: fixed;
                top: 50%;
                left: 5%;
                transform: translateY(-50%);
                width: 500px;
                max-width: 500px;
            }
        }
    </style>
</head>
<body>
    <div class="callback-page">
        <div class="callback-background"></div>

        <div class="callback-form-holder">
            <h2>Authorization</h2>

            <div class="callback-content">
                <div class="callback-state">
                    <div class="state-icon info-icon">
                        <svg fill="none" viewBox="0 0 24 24" stroke="currentColor">
                            <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"/>
                        </svg>
                    </div>
                    <h3 class="state-title">Authorization Request</h3>
                    <p class="state-message">
                        <strong><?php echo e($client->name); ?></strong> is requesting permission to access your account.
                    </p>

                    <!-- Scope List -->
                    <?php if(count($scopes) > 0): ?>
                        <div class="scopes">
                            <p>This application will be able to:</p>
                            <ul>
                                <?php $__currentLoopData = $scopes; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $scope): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                    <li><?php echo e($scope->description); ?></li>
                                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                            </ul>
                        </div>
                    <?php endif; ?>

                    <!-- Authorization Buttons -->
                    <div class="auth-buttons">
                        <!-- Authorize Button -->
                        <form method="post" action="<?php echo e(route('passport.authorizations.approve')); ?>">
                            <?php echo csrf_field(); ?>
                            <input type="hidden" name="state" value="<?php echo e($request->state); ?>">
                            <input type="hidden" name="client_id" value="<?php echo e($client->id); ?>">
                            <input type="hidden" name="auth_token" value="<?php echo e($authToken); ?>">
                            <button type="submit" class="btn btn-success">Authorize</button>
                        </form>

                        <!-- Cancel Button -->
                        <form method="post" action="<?php echo e(route('passport.authorizations.deny')); ?>">
                            <?php echo csrf_field(); ?>
                            <?php echo method_field('DELETE'); ?>
                            <input type="hidden" name="state" value="<?php echo e($request->state); ?>">
                            <input type="hidden" name="client_id" value="<?php echo e($client->id); ?>">
                            <input type="hidden" name="auth_token" value="<?php echo e($authToken); ?>">
                            <button type="submit" class="btn btn-danger">Cancel</button>
                        </form>
                    </div>
                </div>
            </div>
        </div>
    </div>
</body>
</html>
<?php /**PATH /var/www/html/resources/views/vendor/passport/authorize.blade.php ENDPATH**/ ?>