-
Notifications
You must be signed in to change notification settings - Fork 0
/
style.css
125 lines (109 loc) · 2.16 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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;700&display=swap');
* {
box-sizing: border-box;
margin: 0;
padding: 0;
outline: none;
}
body {
font-family: "Poppins", sans-serif;
background-color: #262626;
color: #fff;
overflow-x: hidden;
margin: 30px;
}
div,
img,
a {
border-radius: 10px;
}
h1 {
font-size: 2.5rem;
text-align: center;
margin-bottom: 30px;
}
.projects {
display: grid;
grid-template-columns: repeat(5, 1fr);
gap: 8px;
width: 100%;
}
@media (max-width: 900px) {
.projects {
grid-template-columns: repeat(3, 1fr);
}
}
@media (max-width: 700px) {
.projects {
grid-template-columns: repeat(2, 1fr);
}
}
@media (max-width: 400px) {
.projects {
grid-template-columns: repeat(1, 1fr);
}
}
.project {
position: relative;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
width: 100%;
background: beige;
color: #000;
font-size: 1rem;
aspect-ratio: 4 / 3;
}
.project__number {
position: absolute;
top: 4px;
left: 4px;
background-color: rgb(153, 205, 50);
text-align: center;
padding: 6px 0;
border-radius: 8px;
width: 40px;
}
.project img {
width: 100%;
height: 100%;
object-fit: cover;
}
.project__hidden-block {
opacity: 0;
position: absolute;
z-index: 2;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
gap: 12px;
width: 100%;
height: 100%;
padding: 4px;
background-color: rgba(153, 205, 50, 0.6);
transition: all 0.3s ease-out;
}
.project__hidden-block:hover {
opacity: 1;
}
.project__hidden-block h2 {
text-transform: capitalize;
text-align: center;
font-size: 1.2rem;
line-height: 1.5rem;
}
.project__hidden-block a {
text-decoration: none;
text-align: center;
color: inherit;
background-color: rgb(239, 229, 39);
box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
padding: 6px 12px;
cursor: pointer;
transition: all 0.3s ease-out;
}
.project__hidden-block a:hover {
transform: scale(1.1);
}