File size: 2,294 Bytes
1e92f2d
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
.background(@from, @to){
  background: (@from + @to)/2;
  background: -webkit-gradient(linear, left top, left bottom, from(@from), to(@to));
  background: -moz-linear-gradient(top,  @from,  @from);
  // IE9使用filter背景渐变, 但因为使用了borader-radius, 所以不兼容, IE9使用中和的背景色即可
  //filter:  progid:DXImageTransform.Microsoft.gradient(startColorstr='@{from}', endColorstr='@{to}');
}

.button{
  position: absolute;
  text-align: center;
  color: #111;
  position: absolute;
  white-space: nowrap;
  line-height: 1.6;
  &.s2{
    font-size: 16px;
  }
  span.position{
    position: absolute;
    top: 5px;
    left: 102px;
  }
  i{
    display: block;
    position: relative;
    border: 1px solid #000;
    border-radius: 50%;
    &:before, &:after{
      content: '';
      display: block;
      width: 100%;
      height: 100%;
      position: absolute;
      top: 0;
      left: 0;
      border-radius:50%;
      box-shadow: 0 5px 10px rgba(255, 255, 255, .8) inset;
    }
    &:after{
      box-shadow: 0 -5px 10px rgba(0, 0, 0, .8) inset;
    }
    &.active{
      &:before{
        box-shadow: 0 -3px 6px rgba(255, 255, 255, .6) inset;
      }
      &:after{
        box-shadow: 0 5px 5px rgba(0, 0, 0, .6) inset;
      }
    }
    box-shadow: 0 3px 3px rgba(0, 0, 0, .2);

  }

  &.blue i{
    .background(#6e77ef, #4652f3);
  }
  &.green i{
    .background(#4bc441, #0ec400);
  }
  &.red i{
    .background(#dc3333, #de0000);
  }
  &.s0 i{
    width: 160px;
    height: 160px;

  }
  &.s1 i{
    width: 100px;
    height: 100px;
  }
  &.s2 i{
    width: 52px;
    height: 52px;
    &:before, &:after{
      box-shadow: 0px 3px 6px rgba(255, 255, 255, .8) inset;
    }
    &:after{
      box-shadow: 0px -3px 6px rgba(0, 0, 0, .8) inset;
    }
    &.active{
      &:before{
        box-shadow: 0px -1px 2px rgba(255, 255, 255, .6) inset;
      }
      &:after{
        box-shadow: 0px 3px 3px rgba(0, 0, 0, .7) inset;
      }
    }
    box-shadow: 1px 1px 1px rgba(0, 0, 0, .2);
  }

  &.s1{
    em{
        display: block;
        width: 0;
        height: 0;
        border: 8px solid;
        border-color: transparent transparent #111;
        position: absolute;
        top: 50%;
        left: 50%;
        margin: -12px 0 0 -8px;
    }
  }
}