
@import "../../../_public/less/_core.less";


/**
 * 卡片类
 */
.cardShadow(){
  background: #fff;
  border-radius: 2px;
  box-shadow: 0 0 2px rgba(0,0,0,0.2);
}

.side_card{
  margin-bottom: 20px;
  overflow: hidden;
  .cardShadow();
  .caption{
    padding: .5em 1em;
    box-shadow: 0 0 2px #aaa;
    strong,
    span,
    small{
      display: inline-block;
      vertical-align: bottom;
      height: 24px;
      line-height: 24px;
    }
    small{
      padding: 0 .5em;
      opacity: .6;
    }
  }
  .text{
    padding: 1em 0;
    color: #ccc;
    font-size: 18px;
    text-align: center;
  }
}
.side-github{
  header{
    position: relative;
    height: 110px;
    background: #555;
  }
  .logo{
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    font-size: 120px;
    color: #333;
    height: 70px;
    overflow: hidden;
    text-align: center;
    line-height: 90px;
  }
  .avatar{
    position: absolute;
    bottom: -30px;
    left: 50%;;
    width: 70px;
    height: 70px;
    margin-left: -40px;
    padding: 5px;
    border-radius: 100%;
    background: #fff;
    img{
      display: block;
      width: 70px;
      height: 70px;
      border-radius: 100%;
    }
  }
  .main{
    padding: 40px 0 15px;
    text-align: center;
    h3{
      font-size: 18px;
      font-weight: normal;
      margin-bottom: .5em;
    }
    i{
      margin-right: 6px;
    }
  }
  .count{
    border-top: 1px solid #eee;
    &:after{
      content: '';
      display: block;
      clear: both;
      height: 0;
      overflow: hidden;
    }
    a{
      display: block;
      width: 33.333%;
      float: left;
      padding: 10px 0;
      &:hover{
        background: #fafafa;
      }
    }
    strong,
    span{
      display: block;
      text-align: center;
      line-height: 1.2em;
    }
    strong{
      font-size: 20px;
      color: #333;
    }
    span{
      font-size: 12px;
      color: #aaa;
    }
}
}
.side-comments-item{
  display: block;
  padding: 10px;
  border-top: 1px solid #eee;
  &:after{
    content: "";
    display: block;
    clear: both;
    height: 0;
    overflow: hidden;
  }
  .cover{
    float: left;
    img{
      display: block;
      width: 40px;
      height: 40px;
      border-radius: 100%;
      background: #eee;
    }
  }
  .main{
    float: right;
    width: calc(~"100% - 50px");
    h4{
      font-size: 14px;
      font-weight: 500;
      small{
        opacity: .7;
        font-weight: normal;
      }
    }
    p{
      padding: .5em 0 0;
      font-size: 12px;
      color: #888;
      word-break: break-word;
      line-height: 1.4em;
      max-height: 4.2em;
      overflow: hidden;
    }
  }
  &:hover{
    background: #fafafa;
    color: inherit;
  }
}
@media screen and (max-width: 950px) {
  .sidebar{
    padding-top: 20px;
  }
}