- 4
- 2
Этот сайт представляет собой форму регистрации. Она включает поля для ввода номера телефона, имени и пароля, а также кнопку для переключения видимости пароля. Страница также предлагает альтернативные способы регистрации через социальные сети (Facebook, Google, Apple) и содержит ссылки на условия использования и политику конфиденциальности. Дизайн выполнен в темных тонах с синими акцентами.
(Ссылки на Facebook, Google, Apple не работают)
(Ссылки на Facebook, Google, Apple не работают)
Sait:
<!DOCTYPE html>
<html lang="ru">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Telegram Style Registration</title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}
body {
background: linear-gradient(135deg, #0e0e0e 0%, #1c1c1c 100%);
color: #e1e1e1;
min-height: 100vh;
display: flex;
justify-content: center;
align-items: center;
padding: 20px;
position: relative;
overflow-x: hidden;
}
/* Анимированный фон */
body::before {
content: '';
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: radial-gradient(circle at center, rgba(0, 136, 204, 0.1) 0%, rgba(0, 0, 0, 0) 70%);
z-index: -1;
}
.telegram-logo {
position: absolute;
top: 30px;
left: 50%;
transform: translateX(-50%);
font-size: 2.5rem;
color: #0088cc;
}
.container {
background: rgba(30, 30, 30, 0.9);
border-radius: 16px;
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
width: 100%;
max-width: 450px;
padding: 40px 30px;
position: relative;
overflow: hidden;
border: 1px solid rgba(255, 255, 255, 0.08);
}
.container::before {
content: '';
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 4px;
background: linear-gradient(90deg, #0088cc, #00a8ff);
}
h1 {
text-align: center;
margin-bottom: 30px;
font-size: 28px;
font-weight: 600;
color: #f1f1f1;
position: relative;
}
h1::after {
content: '';
position: absolute;
bottom: -10px;
left: 50%;
transform: translateX(-50%);
width: 60px;
height: 3px;
background: #0088cc;
border-radius: 3px;
}
.input-group {
margin-bottom: 25px;
position: relative;
}
label {
display: block;
margin-bottom: 8px;
font-weight: 500;
color: #a0a0a0;
font-size: 14px;
}
.input-container {
position: relative;
}
input {
width: 100%;
padding: 15px 20px 15px 50px;
background: rgba(40, 40, 40, 0.8);
border: 1px solid rgba(255, 255, 255, 0.1);
border-radius: 12px;
font-size: 16px;
color: #f1f1f1;
transition: all 0.3s ease;
}
input:focus {
outline: none;
border-color: #0088cc;
box-shadow: 0 0 0 3px rgba(0, 136, 204, 0.3);
}
.input-icon {
position: absolute;
left: 18px;
top: 50%;
transform: translateY(-50%);
color: #0088cc;
font-size: 18px;
}
.password-toggle {
position: absolute;
right: 15px;
top: 50%;
transform: translateY(-50%);
color: #777;
cursor: pointer;
font-size: 18px;
}
.password-toggle:hover {
color: #0088cc;
}
.btn {
display: block;
width: 100%;
padding: 16px;
background: linear-gradient(135deg, #0088cc, #006699);
color: white;
border: none;
border-radius: 12px;
font-size: 16px;
font-weight: 600;
cursor: pointer;
transition: all 0.3s ease;
margin-top: 10px;
position: relative;
overflow: hidden;
}
.btn:hover {
background: linear-gradient(135deg, #00a8ff, #0088cc);
transform: translateY(-2px);
box-shadow: 0 5px 15px rgba(0, 136, 204, 0.4);
}
.btn:active {
transform: translateY(0);
}
.terms {
text-align: center;
margin: 25px 0;
font-size: 14px;
color: #888;
line-height: 1.5;
}
.terms a {
color: #0088cc;
text-decoration: none;
transition: color 0.3s;
}
.terms a:hover {
color: #00a8ff;
text-decoration: underline;
}
.login-link {
text-align: center;
margin-top: 25px;
color: #a0a0a0;
font-size: 15px;
}
.login-link a {
color: #0088cc;
text-decoration: none;
font-weight: 600;
margin-left: 5px;
}
.login-link a:hover {
text-decoration: underline;
}
.divider {
display: flex;
align-items: center;
margin: 25px 0;
}
.divider::before,
.divider::after {
content: '';
flex: 1;
height: 1px;
background: rgba(255, 255, 255, 0.1);
}
.divider span {
padding: 0 15px;
color: #888;
font-size: 14px;
}
.social-login {
display: flex;
justify-content: center;
gap: 15px;
margin-top: 20px;
}
.social-btn {
width: 50px;
height: 50px;
border-radius: 50%;
background: rgba(40, 40, 40, 0.8);
display: flex;
align-items: center;
justify-content: center;
color: #f1f1f1;
font-size: 20px;
cursor: pointer;
transition: all 0.3s ease;
border: 1px solid rgba(255, 255, 255, 0.1);
}
.social-btn:hover {
transform: translateY(-3px);
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
border-color: rgba(0, 136, 204, 0.5);
}
.facebook:hover {
background: linear-gradient(135deg, #3b5998, #2d4373);
}
.google:hover {
background: linear-gradient(135deg, #dd4b39, #c23321);
}
.apple:hover {
background: linear-gradient(135deg, #a2aaad, #6d6d6d);
}
@keyframes fadeIn {
from { opacity: 0; transform: translateY(20px); }
to { opacity: 1; transform: translateY(0); }
}
.container > * {
animation: fadeIn 0.6s ease-out forwards;
}
h1 { animation-delay: 0.1s; }
.input-group:nth-child(2) { animation-delay: 0.2s; }
.input-group:nth-child(3) { animation-delay: 0.3s; }
.input-group:nth-child(4) { animation-delay: 0.4s; }
.btn { animation-delay: 0.5s; }
.terms { animation-delay: 0.6s; }
.divider { animation-delay: 0.7s; }
.social-login { animation-delay: 0.8s; }
.login-link { animation-delay: 0.9s; }
@media (max-width: 500px) {
.container {
padding: 30px 20px;
}
h1 {
font-size: 24px;
}
input {
padding: 13px 15px 13px 45px;
font-size: 15px;
}
.input-icon {
left: 15px;
font-size: 16px;
}
.btn {
padding: 14px;
}
}
.input-container:focus-within .input-icon {
color: #00a8ff;
transform: translateY(-50%) scale(1.1);
}
.btn::after {
content: "";
position: absolute;
top: 50%;
left: 50%;
width: 5px;
height: 5px;
background: rgba(255, 255, 255, 0.5);
opacity: 0;
border-radius: 100%;
transform: scale(1, 1) translate(-50%);
transform-origin: 0 0;
}
.btn:active::after {
animation: ripple 0.6s ease-out;
}
@keyframes ripple {
0% {
transform: scale(0, 0);
opacity: 0.5;
}
100% {
transform: scale(50, 50);
opacity: 0;
}
}
</style>
</head>
<body>
<div class="telegram-logo">
<i class="fab fa-telegram"></i>
</div>
<div class="container">
<h1>Регистрация</h1>
<div class="input-group">
<label for="phone">Телефон</label>
<div class="input-container">
<i class="fas fa-phone input-icon"></i>
<input type="tel" id="phone" placeholder="+7 (XXX) XXX-XXXX" required>
</div>
</div>
<div class="input-group">
<label for="firstName">Имя</label>
<div class="input-container">
<i class="fas fa-user input-icon"></i>
<input type="text" id="firstName" placeholder="Ваше имя" required>
</div>
</div>
<div class="input-group">
<label for="password">Пароль</label>
<div class="input-container">
<i class="fas fa-lock input-icon"></i>
<input type="password" id="password" placeholder="Придумайте пароль" required>
<i class="fas fa-eye password-toggle" id="togglePassword"></i>
</div>
</div>
<button class="btn" id="registerBtn">Зарегистрироваться</button>
<div class="terms">
Регистрируясь, вы принимаете <a href="#">Условия использования</a> и <a href="#">Политику конфиденциальности</a>
</div>
<div class="divider">
<span>или</span>
</div>
<div class="social-login">
<div class="social-btn facebook">
<i class="fab fa-facebook-f"></i>
</div>
<div class="social-btn google">
<i class="fab fa-google"></i>
</div>
<div class="social-btn apple">
<i class="fab fa-apple"></i>
</div>
</div>
<div class="login-link">
Уже есть аккаунт? <a href="#">Войти</a>
</div>
</div>
<script>
const togglePassword = document.getElementById('togglePassword');
const password = document.getElementById('password');
togglePassword.addEventListener('click', function() {
const type = password.getAttribute('type') === 'password' ? 'text' : 'password';
password.setAttribute('type', type);
this.classList.toggle('fa-eye');
this.classList.toggle('fa-eye-slash');
});
const phoneInput = document.getElementById('phone');
phoneInput.addEventListener('input', function(e) {
let value = e.target.value.replace(/\D/g, '');
if (value.length > 0) {
value = '+7 (' + value.substring(1, 4) + ') ' + value.substring(4, 7) + '-' + value.substring(7, 11);
}
e.target.value = value;
});
const registerBtn = document.getElementById('registerBtn');
registerBtn.addEventListener('click', function(e) {
e.preventDefault();
const phone = phoneInput.value.replace(/\D/g, '');
const firstName = document.getElementById('firstName').value;
const passwordValue = password.value;
if (phone.length !== 11) {
alert('Пожалуйста, введите корректный номер телефона');
return;
}
if (firstName.length < 2) {
alert('Имя должно содержать минимум 2 символа');
return;
}
if (passwordValue.length < 6) {
alert('Пароль должен содержать минимум 6 символов');
return;
}
this.innerHTML = '<i class="fas fa-spinner fa-spin"></i> Регистрация...';
this.disabled = true;
setTimeout(() => {
this.innerHTML = '<i class="fas fa-check"></i> Успешно!';
this.style.background = 'linear-gradient(135deg, #00c853, #009624)';
setTimeout(() => {
document.getElementById('registrationForm').reset();
this.innerHTML = 'Зарегистрироваться';
this.style.background = 'linear-gradient(135deg, #0088cc, #006699)';
this.disabled = false;
alert('Регистрация прошла успешно! Добро пожаловать!');
}, 2000);
}, 1500);
});
document.querySelectorAll('.social-btn').forEach(btn => {
btn.addEventListener('mouseenter', function() {
const icon = this.querySelector('i');
icon.style.transform = 'scale(1.2)';
});
btn.addEventListener('mouseleave', function() {
const icon = this.querySelector('i');
icon.style.transform = 'scale(1)';
});
});
</script>
</body>
</html>