<!DOCTYPE html>
<html lang="ru">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Защита паролем</title>
    <style>
        body {
            font-family: Arial, sans-serif;
            display: flex;
            justify-content: center;
            align-items: center;
            height: 100vh;
            background-color: #f4f4f4;
        }
        .container {
            text-align: center;
            padding: 20px;
            border: 1px solid #ccc;
            background-color: #fff;
            border-radius: 5px;
        }
        input[type="password"] {
            padding: 10px;
            margin: 10px 0;
            width: 200px;
        }
        button {
            padding: 10px 20px;
            cursor: pointer;
        }
    </style>
</head>
<body>

<div class="container">
    <h2>Введите пароль для доступа к скачиванию</h2>
    <input type="password" id="password" placeholder="Пароль">
    <button onclick="checkPassword()">Подтвердить</button>
    <p id="message" style="color: red;"></p>
</div>

<script>
    const correctPassword = "yourpassword"; // Замените на ваш пароль

    function checkPassword() {
        const inputPassword = document.getElementById("password").value;
        const message = document.getElementById("message");

        if (inputPassword === correctPassword) {
            message.style.color = "green";
            message.innerHTML = "Пароль верный! <a href='https://drive.google.com/file/d/1JMYVh1q4zAWcVEeURJhN3BGvcvJg72Gp/view?usp=sharing'>Скачать файл</a>"; // Замените 'file.zip' на имя вашего файла
        } else {
            message.innerHTML = "Неверный пароль. Попробуйте снова.";
        }
    }
</script>

</body>
</html>