-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathstyle.css
81 lines (70 loc) · 1.29 KB
/
style.css
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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
body {
font-family: Arial, sans-serif;
text-align: center;
background-color: #f4f4f9;
margin: 0;
padding: 0;
}
h1 {
margin: 20px 0;
}
.grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
gap: 10px;
max-width: 400px;
margin: 20px auto;
}
.card {
width: 100px;
height: 100px;
perspective: 1000px;
cursor: pointer;
}
.card-inner {
width: 100%;
height: 100%;
position: relative;
transform-style: preserve-3d;
transition: transform 0.6s;
}
.card.flipped .card-inner {
transform: rotateY(180deg);
}
.card-front,
.card-back {
position: absolute;
width: 100%;
height: 100%;
backface-visibility: hidden;
border: 1px solid #ccc;
border-radius: 10px;
}
.card-front {
background-color: #333;
}
.card-back {
background-color: #fff;
transform: rotateY(180deg);
display: flex;
justify-content: center;
align-items: center;
}
.card-back img {
max-width: 90%;
max-height: 90%;
}
button {
margin: 10px auto;
padding: 10px 20px;
font-size: 16px;
cursor: pointer;
background-color: #007bff;
color: #fff;
border: none;
border-radius: 5px;
transition: background-color 0.3s;
}
button:hover {
background-color: #0056b3;
}