forked from aslushnikov/been
-
Notifications
You must be signed in to change notification settings - Fork 0
/
style.css
162 lines (137 loc) · 2.66 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
* {
box-sizing: border-box;
font-family: 'Roboto', 'Helvetica Neue', Helvetica, Arial, sans-serif;
}
html {
background-color: rgb(246, 246, 246);
}
body {
background-color: white;
}
:root {
font-size: 16px;
}
h3 {
font-size: 24px;
}
body {
color: #333;
padding: 0;
margin: 0 auto;
max-width: 1280px;
height: 100%;
display: grid;
grid-template-areas: "countries header"
"countries map"
"countries map";
grid-template-columns: 250px auto;
grid-template-rows: 50px auto 50px;
grid-gap: 10px;
}
@media only screen and (max-width: 600px) {
body {
grid-template-areas: "header"
"map"
"countries";
grid-template-columns: auto;
grid-template-rows: 50px 1fr 2fr;
}
.countrylist {
border-top: 1px solid #DDD;
}
}
header {
grid-area: header;
display: flex;
align-items: center;
justify-content: space-between;
margin: 0 1em;
}
header h3 {
margin: 0em;
}
.countrylist {
grid-area: countries;
border-left: 1px solid #DDD;
border-right: 1px solid #DDD;
max-height: 100%;
min-height: 0;
overflow: auto;
--gap: 10px;
cursor: pointer;
/* support smooth scrolling on safari */
-webkit-overflow-scrolling: touch;
-webkit-tap-highlight-color: rgba(0,0,0,0);
}
.countrylist .region {
position: relative;
}
.countrylist .region .region-title {
position: sticky;
position: -webkit-sticky;
top: 0;
background-color: white;
padding: 4px var(--gap);
background-color: #EEE;
display: flex;
justify-content: space-between;
align-items: center;
}
.countrylist .region .region-title h3 {
margin: 0;
padding: 0;
}
.countrylist .region .entry {
margin: 0px var(--gap);
padding: 6px 0;
display: flex;
justify-content: space-between;
align-items: center;
}
.countrylist .region .entry.revealing {
color: blue !important;
}
.countrylist .region .entry.hovered {
color: rgba(0, 0, 255, 0.5);
}
.countrylist .region .entry.visited::after {
content: '✔';
font-size: 12px;
--green: #4CAF50;
color: white;
padding: 1px 3px;
border-radius: 3px;
background-color: var(--green);
}
.countrylist .region .entry + .entry {
padding-top: var(--gap);
border-top: 1px solid #DDD;
}
.map {
grid-area: map;
margin: 1em;
}
.map svg {
min-width: 0;
min-height: 0;
max-width: 100%;
max-height: 100%;
-webkit-tap-highlight-color: rgba(0,0,0,0);
}
.map svg .revealing {
fill: blue !important;
fill-opacity: 1 !important;
}
.map svg .visited {
fill: #8bc34a;
}
.map svg .land {
cursor: pointer;
}
.map svg .land.hovered {
fill: blue;
fill-opacity: 0.5;
}
footer {
grid-area: footer;
}