/
aska
/
web-static-labs
Обзор
Документация
Войти
/
aska
/
web-static-labs
Код
Запросы
0
Задачи
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
html/lab4/task2/styles.css
80 строк
2 KB
unknown
лабы 1 4 5
14 ноя 2025, 09:16
14 ноя 2025, 09:16
b757c12
Код
Авторство
О чём код?
body { font-family: sans-serif; margin: 20px; background-color: #f4f4f4; color: #333; } #cards { display: flex; gap: 36px; margin-bottom: 20px; justify-content: center; /* Центрируем карточки */ } #cards img { opacity: 1; height: 36px; transition: opacity 0.2s ease; cursor: pointer; /* Меняем курсор при наведении */ } #cards img:hover { opacity: 0.5; /* Немного подсвечиваем при наведении */ } #cards img.h1 { opacity: 1; } input[type="text"] { width: 320px; padding: 10px; margin-bottom: 10px; border: 1px solid #ccc; border-radius: 5px; box-sizing: border-box; /* Важно, чтобы padding не увеличивал ширину */ font-size: 16px; } button { background-color: #4CAF50; color: white; padding: 12px 20px; border: none; border-radius: 5px; cursor: pointer; font-size: 16px; transition: background-color 0.3s ease; /* Добавляем плавность */ } button:hover { background-color: #3e8e41; } #result { margin-top: 10px; padding: 10px; background-color: #fff; border: 1px solid #ddd; border-radius: 5px; color: #374151; font-size: 16px; } /* Добавляем стили для более выразительных ошибок */ #result.error { background-color: #ffebee; /* Светло-красный фон */ border-color: #ef9a9a; /* Красная граница */ color: #d32f2f; /* Темно-красный текст */ } /* Добавляем небольшой shadow, чтобы UI казался более современным */ body, input[type="text"], button, #result { box-shadow: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.24); transition: all 0.3s cubic-bezier(.25,.8,.25,1); } body:hover, input[type="text"]:hover, button:hover, #result:hover { box-shadow: 0 5px 10px rgba(0,0,0,0.25), 0 3px 5px rgba(0,0,0,0.22); }