File "overlay thay tin.html"
Full path: E:/sites/Single15/tinmung2007/webroot/Tin VUI_BUON/_TinVui/2026/overlay thay tin.html
File size: 1.89 KiB (1939 bytes)
MIME-type:
Charset: utf-8
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Text Overlay Hover Effect</title>
<style>
* {
box-sizing: border-box;
}
body {
display: flex;
justify-content: center;
align-items: center; /* Sửa từ align-content thành align-items để căn giữa chuẩn */
min-height: 100vh;
margin: 0;
font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
background-color: #f5f5f5;
}
.overlay-container {
/* Đã sửa lỗi sai cú pháp background và đường dẫn ảnh mẫu */
background: url('https://picsum.photos/300/450') no-repeat center;
width: 300px;
height: 450px;
background-size: cover; /* Sửa lỗi viết sai chính tả backgroud-size */
position: relative;
color: #fff;
overflow: hidden;
box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}
.overlay-text {
background-color: rgba(255, 85, 85, 1); /* Màu đỏ của bạn */
padding: 15px 10px;
position: absolute;
bottom: -100px; /* Đẩy hẳn xuống dưới để giấu đi trước khi hover */
width: 100%;
transition: all 0.3s ease-in-out;
opacity: 0; /* Ẩn mặc định */
}
/* Hiệu ứng kích hoạt khi trỏ chuột vào background */
.overlay-container:hover .overlay-text {
bottom: 0;
opacity: 1;
}
.overlay-title {
text-transform: uppercase;
font-size: 14px;
margin: 0;
text-align: center; /* Thay thế cho thuộc tính align="center" đã lỗi thời trong HTML5 */
}
</style>
</head>
<body>
<div class="overlay-container">
<div class="overlay-text">
<h3 class="overlay-title">CHA ĐAMINH MARIA TRẦN ĐÌNH THỦ</h3>
</div>
</div>
</body>
</html>