-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstyle.css
254 lines (223 loc) · 3.46 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
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
* {
box-sizing: border-box;
}
.container {
width: 800px;
margin: 0 auto;
}
/**
* nav
*/
#nav {
background-color: #ff6600;
width: 100%;
border: 1px solid #ff6600;
position: fixed;
top: 0;
left: 0;
z-index: 100; /* z-index定義元素的層級,愈大的數字會放在愈上層,而視窗位於 0 的位置 */
}
.menu {
float: right;
}
.menu li { /* menu下所有li選起來 */
width: 150px;
padding: 10px 0px;
border: 1px solid #fff;
border-radius: 5px;
margin-bottom: -5px;
list-style-type: none;
text-align: center;
background-color: #ff6600;
color: #fff;
display: inline-block;
}
a {
display: block;
color: #fff;
text-decoration: none;
}
li:hover { /* 滑鼠移到時 */
border: 1px solid #ff6600;
background-color: #fff;
}
li:hover a {
color: #ff6600;
font-weight: 800;
}
/**
* content
*/
#content {
position: relative;
top: 0px;
padding: 70px;
}
#content > .container > div {
padding: 70px 0;
}
hr.bar {
border: 2px solid #ff6600;
width: 80px;
}
h1 {
text-align: center;
}
/* about me */
#my-avatar {
float: left;
margin-right: 20px;
}
#my-avatar img {
width: 300px;
}
#about h1 {
margin-bottom: 0;
text-align: left;
}
h3 {
margin: 0;
}
table {
font-size: 14px;
text-align: left;
}
th, td {
vertical-align: top;
}
td {
color: #666;
padding-left: 10px;
}
hr {
border: 0.5px solid #eee;
}
/* my work */
#my-work {
text-align: center;
}
.item {
max-width: 30%;
position: relative;
display: inline-block;
margin-bottom: 10px;
}
.item img {
width: 100%;
}
.item-info {
width: 100%;
height: 100%;
text-align: center;
padding: 25px 10px;
background-color: rgba(255,255,255,.8);
position: absolute;
top: 0;
left: 0;
opacity: 0;
}
.item-info:hover {
opacity: 1;
}
/* contact me */
#contact-me {
}
form.contact-form {
width: 50%;
margin: 0 auto;
}
.form-row {
margin-bottom: 15px;
}
.form-row input, .form-row textarea {
border-radius: 3px;
width: 100%;
border: 1px solid #d6d9dc;
padding: 7px;
}
.form-row textarea {
resize: none; /*關閉'拖曳元素的右下角來改變大小'*/
height: 4em;
}
.form-row button {
border: none;
border-radius: 3px;
padding: 10px 15px;
cursor: pointer; /* 改變滑鼠游標的形狀 */
}
.form-row button[type="submit"] {
background-color: #5995da;
color: #fff;
}
.form-row button:hover {
background-color: #76aeed;
}
.form-row button:active {
background-color: #407fc7;
}
/**
* RWD
*/
@media screen and (min-width: 768px) {
.menu-button,
.menu-button-checkbox {
display: none;
}
}
@media screen and (max-width: 767px) { /* 手機版 */
.container {
width: auto;
}
.menu-button {
float: right;
font-size: 25px;
line-height: 40px;
color: white;
background: transparent;
padding: 0 15px;
border: 0;
}
.menu-button-checkbox {
position: fixed;
top: 0;
right: 0;
width: 55px;
height: 40px;
opacity: 0;
}
.menu-button-checkbox:checked ~ .menu {
display: block;
}
.menu {
margin-top: 0;
padding-left: 0;
position: fixed;
right: 0;
top: 42px;
width: 150px;
height: 100%;
background: red;
display: none;
}
.menu li {
border: 0;
border-radius: 0;
}
#content {
padding: 40px;
}
#my-avatar {
width: 100%;
}
#my-avatar img {
width: 250px;
display: block;
margin: 10px auto;
}
.item {
max-width: 100%;
}
form.contact-form {
width: 80%;
}
}