-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathCard.module.css
More file actions
50 lines (44 loc) · 1.01 KB
/
Card.module.css
File metadata and controls
50 lines (44 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
.cardLink {
text-decoration: none;
color: inherit;
display: block;
position: relative; /* Ensures that positioning is relative to the card */
}
.card {
position: relative; /* Needed for absolute positioning of the label */
display: flex;
flex-direction: column;
align-items: center;
border-radius: 10px;
overflow: hidden;
margin: 10px;
transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.newLabel {
position: absolute;
top: 10px; /* Adjust as necessary */
right: 10px; /* Adjust as necessary */
background-color: #5332CD; /* Choose color based on your design */
color: white;
padding: 5px 10px;
border-radius: 5px; /* Rounded corners */
font-size: 0.9em;
font-weight: bold;
}
.cardImage {
width: 100%;
height: 200px;
object-fit: cover;
transition: transform 0.3s ease;
}
.card:hover .cardImage {
transform: scale(1.03);
}
.card:hover {
transform: translateY(-1px);
box-shadow: 0px 4px 12px rgba(0, 0, 0, 0.08);
}
.cardHeader {
padding: 10px;
text-align: center;
}