<!DOCTYPE html>
<html lang="es">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=768, initial-scale=1.0">
    <title>App Mantenimiento - Login</title>
    <link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css" rel="stylesheet">
    <style>
        :root {
            --primary: #1a3a5c;
            --primary-dark: #0f2840;
            --primary-light: #2d5a8a;
            --accent: #e91e63;
            --success: #10b981;
            --gray-50: #f8fafc;
            --gray-100: #f1f5f9;
            --gray-200: #e2e8f0;
            --gray-300: #cbd5e1;
            --gray-400: #94a3b8;
            --gray-500: #64748b;
            --gray-600: #475569;
            --gray-800: #1e293b;
            --white: #ffffff;
            --radius: 16px;
            --radius-sm: 12px;
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        body {
            font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', Roboto, sans-serif;
            background: var(--gray-50);
            min-height: 100vh;
            -webkit-font-smoothing: antialiased;
        }

        .tablet-frame {
            max-width: 768px;
            margin: 0 auto;
            min-height: 100vh;
            display: flex;
            flex-direction: column;
        }

        /* Header decorativo */
        .login-header {
            background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
            padding: 60px 40px 80px;
            text-align: center;
            position: relative;
            overflow: hidden;
        }

        .login-header::before {
            content: '';
            position: absolute;
            top: -50%;
            right: -20%;
            width: 300px;
            height: 300px;
            background: rgba(255,255,255,0.05);
            border-radius: 50%;
        }

        .login-header::after {
            content: '';
            position: absolute;
            bottom: -30%;
            left: -10%;
            width: 200px;
            height: 200px;
            background: rgba(233, 30, 99, 0.1);
            border-radius: 50%;
        }

        .header-content {
            position: relative;
            z-index: 1;
        }

        .logo-icon {
            width: 80px;
            height: 80px;
            background: rgba(255,255,255,0.15);
            border-radius: 20px;
            display: flex;
            align-items: center;
            justify-content: center;
            margin: 0 auto 20px;
        }

        .logo-icon i {
            font-size: 2.25rem;
            color: #fff;
        }

        .login-title {
            font-size: 1.75rem;
            font-weight: 700;
            color: #fff;
            margin-bottom: 8px;
        }

        .login-subtitle {
            color: rgba(255,255,255,0.7);
            font-size: 0.95rem;
        }

        /* Form Container */
        .login-form-container {
            flex: 1;
            background: var(--white);
            border-radius: 32px 32px 0 0;
            margin-top: -30px;
            padding: 40px 32px;
            position: relative;
        }

        .welcome-text {
            text-align: center;
            margin-bottom: 32px;
        }

        .welcome-text h2 {
            font-size: 1.5rem;
            font-weight: 700;
            color: var(--gray-800);
            margin-bottom: 8px;
        }

        .welcome-text p {
            color: var(--gray-500);
            font-size: 0.95rem;
        }

        /* Form Groups */
        .form-group {
            margin-bottom: 24px;
        }

        .form-label {
            display: block;
            font-size: 0.85rem;
            font-weight: 600;
            color: var(--gray-600);
            margin-bottom: 10px;
        }

        .input-container {
            position: relative;
        }

        .input-icon {
            position: absolute;
            left: 16px;
            top: 50%;
            transform: translateY(-50%);
            color: var(--gray-400);
            font-size: 1.1rem;
        }

        .form-input {
            width: 100%;
            padding: 16px 16px 16px 50px;
            border: 2px solid var(--gray-200);
            border-radius: var(--radius-sm);
            font-size: 1rem;
            font-family: inherit;
            transition: all 0.2s;
            background: var(--gray-50);
        }

        .form-input:focus {
            outline: none;
            border-color: var(--primary);
            background: var(--white);
            box-shadow: 0 0 0 4px rgba(26, 58, 92, 0.1);
        }

        .form-input::placeholder {
            color: var(--gray-400);
        }

        .password-toggle {
            position: absolute;
            right: 16px;
            top: 50%;
            transform: translateY(-50%);
            background: none;
            border: none;
            color: var(--gray-400);
            cursor: pointer;
            padding: 4px;
        }

        /* Remember & Forgot */
        .form-options {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 32px;
        }

        .remember-check {
            display: flex;
            align-items: center;
            gap: 10px;
            cursor: pointer;
        }

        .remember-check input {
            width: 20px;
            height: 20px;
            accent-color: var(--primary);
        }

        .remember-check span {
            font-size: 0.9rem;
            color: var(--gray-600);
        }

        .forgot-link {
            color: var(--accent);
            font-size: 0.9rem;
            font-weight: 600;
            text-decoration: none;
        }

        /* Login Button */
        .btn-login {
            width: 100%;
            padding: 18px;
            background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
            border: none;
            border-radius: var(--radius-sm);
            color: var(--white);
            font-size: 1.05rem;
            font-weight: 600;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 10px;
            transition: all 0.3s;
            box-shadow: 0 4px 15px rgba(26, 58, 92, 0.3);
            text-decoration: none;
        }

        .btn-login:hover {
            transform: translateY(-2px);
            box-shadow: 0 6px 20px rgba(26, 58, 92, 0.4);
        }

        .btn-login:active {
            transform: translateY(0);
        }

        /* Biometric Option */
        .biometric-section {
            text-align: center;
            margin-top: 32px;
            padding-top: 32px;
            border-top: 1px solid var(--gray-200);
        }

        .biometric-text {
            color: var(--gray-500);
            font-size: 0.9rem;
            margin-bottom: 20px;
        }

        .biometric-buttons {
            display: flex;
            justify-content: center;
            gap: 20px;
        }

        .btn-biometric {
            width: 70px;
            height: 70px;
            border-radius: 50%;
            border: 2px solid var(--gray-200);
            background: var(--white);
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 1.75rem;
            color: var(--gray-600);
            cursor: pointer;
            transition: all 0.2s;
        }

        .btn-biometric:hover {
            border-color: var(--primary);
            color: var(--primary);
            background: rgba(26, 58, 92, 0.05);
        }

        /* Footer */
        .login-footer {
            text-align: center;
            padding: 24px;
            color: var(--gray-400);
            font-size: 0.8rem;
        }

        .login-footer a {
            color: var(--gray-500);
            text-decoration: none;
        }

        /* Error State */
        .form-input.error {
            border-color: #ef4444;
        }

        .error-message {
            color: #ef4444;
            font-size: 0.8rem;
            margin-top: 8px;
            display: flex;
            align-items: center;
            gap: 6px;
        }

        @media (max-width: 480px) {
            .login-header {
                padding: 40px 24px 60px;
            }

            .login-form-container {
                padding: 32px 20px;
            }

            .logo-icon {
                width: 64px;
                height: 64px;
            }

            .logo-icon i {
                font-size: 1.75rem;
            }

            .login-title {
                font-size: 1.5rem;
            }
        }
    </style>
</head>
<body>
    <div class="tablet-frame">
        <!-- Header -->
        <div class="login-header">
            <div class="header-content">
                <div class="logo-icon">
                    <i class="fas fa-tools"></i>
                </div>
                <h1 class="login-title">Mantenimiento</h1>
                <p class="login-subtitle">Sistema de Peajes</p>
            </div>
        </div>

        <!-- Form Container -->
        <div class="login-form-container">
            <div class="welcome-text">
                <h2>Bienvenido</h2>
                <p>Ingresa tus credenciales para continuar</p>
            </div>

            <form action="01-listado-mantenimientos.html">
                <div class="form-group">
                    <label class="form-label">Cédula</label>
                    <div class="input-container">
                        <i class="fas fa-id-card input-icon"></i>
                        <input type="text" class="form-input" placeholder="Ingresa tu número de cédula"
                               inputmode="numeric" pattern="[0-9]*" maxlength="10">
                    </div>
                </div>

                <div class="form-group">
                    <label class="form-label">Contraseña</label>
                    <div class="input-container">
                        <i class="fas fa-lock input-icon"></i>
                        <input type="password" class="form-input" placeholder="Ingresa tu contraseña" id="password">
                        <button type="button" class="password-toggle" onclick="togglePassword()">
                            <i class="fas fa-eye" id="toggleIcon"></i>
                        </button>
                    </div>
                </div>

                <div class="form-options">
                    <label class="remember-check">
                        <input type="checkbox">
                        <span>Recordarme</span>
                    </label>
                    <a href="#" class="forgot-link">¿Olvidaste tu contraseña?</a>
                </div>

                <a href="01-listado-mantenimientos.html" class="btn-login">
                    <i class="fas fa-sign-in-alt"></i>
                    Iniciar Sesión
                </a>
            </form>

            <!-- Biometric Login -->
            <div class="biometric-section">
                <p class="biometric-text">O ingresa con biometría</p>
                <div class="biometric-buttons">
                    <button class="btn-biometric" title="Face ID">
                        <i class="fas fa-smile"></i>
                    </button>
                    <button class="btn-biometric" title="Touch ID">
                        <i class="fas fa-fingerprint"></i>
                    </button>
                </div>
            </div>

            <!-- Footer -->
            <div class="login-footer">
                <p>© 2026 MACROGRAM. Todos los derechos reservados.</p>
                <p style="margin-top: 8px;">
                    <a href="#">Términos de uso</a> · <a href="#">Política de privacidad</a>
                </p>
            </div>
        </div>
    </div>

    <script>
        function togglePassword() {
            const password = document.getElementById('password');
            const icon = document.getElementById('toggleIcon');

            if (password.type === 'password') {
                password.type = 'text';
                icon.classList.remove('fa-eye');
                icon.classList.add('fa-eye-slash');
            } else {
                password.type = 'password';
                icon.classList.remove('fa-eye-slash');
                icon.classList.add('fa-eye');
            }
        }
    </script>
</body>
</html>
