<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Login - MCP Gateway</title>
    <link rel="stylesheet" href="{{ url_for('static', path='/style.css') }}">
    <style>
        .oauth-providers {
            margin: 20px 0;
            padding: 20px 0;
            border-top: 1px solid #e0e0e0;
            border-bottom: 1px solid #e0e0e0;
        }
        
        .oauth-button {
            display: block;
            width: 100%;
            padding: 12px;
            margin: 10px 0;
            border: 1px solid #ddd;
            border-radius: 5px;
            background: white;
            color: #333;
            text-decoration: none;
            text-align: center;
            font-size: 14px;
            transition: all 0.3s ease;
            cursor: pointer;
        }
        
        .oauth-button:hover {
            background: #f8f9fa;
            border-color: #007bff;
            transform: translateY(-1px);
            box-shadow: 0 2px 4px rgba(0,0,0,0.1);
        }
        
        .oauth-button.cognito {
            background: linear-gradient(45deg, #ff6b35, #f7931e);
            color: white;
            border: none;
        }
        
        .oauth-button.github {
            background: #24292e;
            color: white;
            border: none;
        }
        
        .oauth-button.google {
            background: white;
            color: #757575;
            border: 1px solid #dadce0;
        }
        
        .login-subtitle {
            text-align: center;
            color: #666;
            margin-bottom: 20px;
            font-size: 14px;
        }
    </style>
</head>
<body class="login-body">

    <div class="login-container">
        <div class="login-header">
             <img src="{{ url_for('static', path='/logo.png') }}" alt="MCP Gateway Logo" height="40" style="margin-bottom: 15px;">
            <h2>Welcome to MCP Gateway</h2>
            <p class="login-subtitle">Choose your preferred login method</p>
        </div>

        {% if error %}
        <p class="error-message">{{ error }}</p>
        {% endif %}

        <!-- OAuth2 Providers Section -->
        <div class="oauth-providers">
            {% for provider in oauth_providers %}
            <a href="/auth/{{ provider.name }}" class="oauth-button {{ provider.name }}">
                <strong>Continue with {{ provider.display_name }}</strong>
            </a>
            {% endfor %}
        </div>
    </div>

</body>
</html> 