-
Notifications
You must be signed in to change notification settings - Fork 0
/
style.css
140 lines (128 loc) · 3.45 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
body {
background: #132535;
color: #ebeff0;
font-family: 'Open Sans', sans-serif; /*Explain how all/most "children" elements inside of this one will "inherit" these styles and use the same font/color/font-size*/
/*Don't change padding/margin to 0 until styling the nav menu, to show why they're needed*/
padding: 0;
margin: 0;
}
html {
scroll-behavior: smooth; /*Don't add until the end when talking about cool CSS stuff we didn't cover*/
}
/*Don't add this main part (HTML or CSS) either, until towards the end when we want to do one quick fix so that the page is readable on large things*/
main {
margin: 0 auto; /*Note that this is a quick trick to get things centered*/
padding: 1em;
width: 100%;
max-width: 850px;
}
h1, h2, h3 {
font-size: 3em;
margin: 10px 0;
}
h1 {
font-size: 4em;
text-align: center;
}
h2 {
font-size: 3em;
}
h3 {
font-size: 2em;
}
a {
text-decoration: none;
color: #105a9d;
}
a:hover {
text-decoration: underline;
/*Emphasize this is a normal CSS block and we could've done absolutely anything here we wanted*/
}
/*Make styling the navigation the first big piece we style (probably give its own video section?); introduce margin/padding, width/height, and flex-box basics here*/
#navigation {
display: flex;
justify-content: space-evenly;
align-items: center;
width: 100%;
height: 80px;
margin: 0;
padding: 0;
background: #105a9d;
}
#navigation li {
height: 100%;
width: 100%;
list-style: none;
}
#navigation li a {
display: flex;
justify-content: space-evenly;
align-items: center;
padding: 0 5px;
color: #ebeff0;
height: 100%;
}
#navigation li a:hover {
background: #ebeff0;
color: #105a9d;
text-decoration: none;
}
/*Next up, focus on making the image grid, introducing classes*/
.image-grid {
display: flex;
justify-content: center;
flex-wrap: wrap;
}
.image-grid img {
height: 300px;
border: solid 1px white; /*Introduce borders to separate images*/
}
.hot-text {
padding: 2px;
color: lightcoral;
background: lightyellow;
border-radius: 5px;
}
.cold-text {
padding: 2px;
color: aquamarine;
background: lightskyblue;
border-radius: 5px;
}
/*Finally, style the dojo; first, set up the dojo, then turn David to face the right way, then finally style the button (even using a kung-fu font)*/
#david-dojo-arena {
/*Need to set container position as absolute so child positioning works*/
position: absolute;
display: flex;
justify-content: space-between;
align-items: center;
padding: 10px;
width: 500px;
height: 300px;
background: white;
border: solid 10px #2a3b6a;
border-radius: 5px;
}
#david-dojo-david {
position: absolute;
transform: scaleX(-1); /*Use a trick that scaling by a negative is the same thing as flipping (if you've taken linear algebra, you should know this, and shame on you for forgetting)*/
}
#david-dojo-opponent {
position: absolute;
left: 400px;
}
#david-dojo-fight {
/*Look on Google Fonts for a Karate looking font*/
font-family: "Permanent Marker", cursive;
margin: 0;
padding: 5px;
font-size: 2em;
color: inherit;
background: red;
border: none;
}
#david-dojo-fight:hover {
padding: 10px;
background: url("img/david_karate.PNG");
background-size: cover; /*Note background is way too zoomed in at first, but we can adjust that with this setting*/
}