forked from GoogleChromeLabs/ui-element-samples
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstyles.css
115 lines (103 loc) · 2.14 KB
/
styles.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
/**
*
* Copyright 2016 Google Inc. All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
* {
box-sizing: border-box;
}
html, body {
margin: 0;
padding: 0;
width: 100%;
height: 100%;
font-family: Arial, Helvetica, sans-serif;
}
body {
display: flex;
align-items: center;
justify-content: center;
background: #E2E2E2;
overflow-x: hidden;
overflow-y: scroll;
}
sc-card {
width: 260px;
height: 380px;
position: relative;
perspective: 500px;
will-change: transform;
}
sc-card .front,
sc-card .back {
backface-visibility: hidden;
position: absolute;
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
border-radius: 3px;
overflow: hidden;
}
sc-card button {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: none;
border: none;
text-indent: -10000px;
/*display: none;*/
}
sc-card .front {
background: #444;
color: #FFF;
}
sc-card .front h1 {
font-size: 24px;
}
sc-card .back {
background: url(images/supercharged.jpg) center center no-repeat;
color: #FFF;
transform: rotateY(180deg);
}
sc-card .umbra,
sc-card .penumbra {
width: 100%;
height: 100%;
position: absolute;
top: 0;
left: 0;
backface-visibility: visible;
}
sc-card .umbra {
width: 270px;
height: 390px;
top: -5px;
left: -5px;
background: url(images/umbra.svg) center center no-repeat;
transform: translateY(2px);
opacity: 0.3;
}
sc-card .penumbra {
width: 330px;
height: 450px;
top: -35px;
left: -35px;
background: url(images/penumbra.svg) center center no-repeat;
transform: translateY(2px);
opacity: 0;
}