-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathcarousel.css
133 lines (131 loc) · 2.79 KB
/
carousel.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
* {
box-sizing: border-box;
}
.slider {
width: 720px;
overflow: hidden;
}
.slides {
display: flex;
overflow-x: auto;
scroll-snap-type: x mandatory;
scroll-behavior: smooth;
-webkit-overflow-scrolling: touch;
}
.slides::-webkit-scrollbar {
width: 10px;
height: 10px;
}
.slides::-webkit-scrollbar-thumb {
background: black;
border-radius: 10px;
}
.slides::-webkit-scrollbar-track {
background: transparent;
}
.slides > div {
scroll-snap-align: start;
flex-shrink: 0;
padding: 0.5em 2em;
width: 720px;
height: 300px;
margin-right: 50px;
border-radius: 10px;
background: white;
color: #444;
transform-origin: center center;
transform: scale(1);
transition: transform 0.5s;
position: relative;
display: flex;
flex-direction: column;
justify-content: center;
}
.slides > div > p {
margin-top: 6px;
}
.slider > a {
display: inline-flex;
height: 1.5rem;
text-decoration: none;
align-items: center;
justify-content: center;
border-radius: .4em;
margin: 0.5rem;
padding: 2px 6px;
position: relative;
border-left: solid 2px #e4ebf5;
border-right: solid 2px #e4ebf5;
}
.slider > a:hover {
border-left: solid 2px #014db5;
border-right: solid 2px #014db5;
}
.slider > a:focus, a.hi {
background-color: #014db5;
color: white;
}
/* Don't need button navigation */
@supports (scroll-snap-type) {
.slider > a {
display: none;
}
}
html, body {
margin: 0px;
padding: 0px;
height: 100%;
overflow: hidden;
font-family: 'IBM Plex Sans', sans-serif;
font-size: 11pt;
background-color: #e4ebf5;
min-width: 320px;
}
#tagline {
padding-bottom: 50px;
text-align: center;
}
#banner {
display: flex;
height: 300px;
background-image: url(logo-white-on-dark-100x20.png);
background-repeat: no-repeat;
background-position: 16px 16px;
font-size: 50px;
background-color: #014db5;
color: white;
justify-content: center;
align-items: flex-end;
}
#content {
height: 400px;
display: flex;
align-items: center;
justify-content: center;
background-color: #e4ebf5;
}
.summary {
text-align: center;
font-style: italic;
}
.summary > em {
color: #014db5;
font-style: normal;
}
@media screen and (max-width: 750px) {
.slider > a { margin: 0.5rem 0; }
.slider { width: 600px; }
.slides > div { width: 600px; }
}
@media screen and (max-width: 600px) {
.slider > a { font-size: 90%; }
#tagline { font-size: 42px; }
.slider { width: 500px; }
.slides > div { width: 500px; font-size: 90% }
}
@media screen and (max-width: 500px) {
.slider > a { font-size: 80%; }
#tagline { font-size: 36px; }
.slider { width: 96%; }
.slides > div { width: 96%; font-size: 80% }
}