-
Notifications
You must be signed in to change notification settings - Fork 0
/
brasil-flag.scss
108 lines (94 loc) · 1.97 KB
/
brasil-flag.scss
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
/*!
* Bandeira do Brasil com CSS
* by nandomoreira.me | https://github.com/nandomoreirame
*/
$flag-width: 250px;
$flag-height: 150px;
$color-white: #fff;
$color-flag: #16b83e;
$color-losangue: #ffe11f;
$color-circle: #1651b8;
$losangue-width: 105px;
$losangue-height: 130px;
.brasil-flag {
position: relative;
background-color: $color-flag;
width: $flag-width;
height: $flag-height;
margin: 4em auto;
.circle,
.losangue:before,
.losangue:after {
position: absolute;
}
.losangue {
width: 100%;
height: 100%;
top: 0;
bottom: 0;
left: 0;
right: 0;
&:before,
&:after {
content: '';
width: 0;
height: 0;
left: 20px;
right: 20px;
}
&:before {
border-left: $losangue-width solid transparent;
border-right: $losangue-width solid transparent;
border-bottom: ($losangue-height/2) solid $color-losangue;
top: 10px;
}
&:after {
border-left: $losangue-width solid transparent;
border-right: $losangue-width solid transparent;
border-top: ($losangue-height/2) solid $color-losangue;
bottom: 10px;
}
}
.circle {
overflow: hidden;
z-index: 2;
display: block;
background-color: $color-circle;
height: 80px;
width: 80px;
margin-top: -40px;
margin-left: -40px;
&,
&:before,
&:after {
top: 50%;
left: 50%;
position: absolute;
border-radius: 50%;
-webkit-border-radius: 50%;
-moz-border-radius: 50%;
}
&:before,
&:after {
width: 90px;
height: 40px;
-ms-transform: rotate(14deg);
-webkit-transform: rotate(14deg);
transform: rotate(14deg);
}
&:before {
z-index: 3;
content: '';
margin-top: -20px;
margin-left: -45px;
background: $color-white;
}
&:after {
z-index: 4;
content: '';
margin-top: -10px;
margin-left: -48px;
background-color: $color-circle;
}
}
}