티스토리 뷰

HTML_CSS/CSS Battle

1-3. Push Button

LHOIKTN 2021. 10. 14. 11:01

<div id='item1'></div>
<div id='item2'></div>
<div id='item3'></div>
<div id='item4'></div>
<style>
*{
    margin: 0;
    padding:0;
    background:#6592CF;
  }
  
  body{
    position:relative;
    width:400px;
    height:300px;
  }
  div {
   position:absolute;
    left:50%;
    top:50%;
    transform:translateX(-50%) translateY(-50%);
  }
  
  #item1{
    width:300px;
    height:150px;
    background:#243D83;
  }
  
   #item2{
    width:250px;
    height:250px;
     border-radius:50%;
    background:#6592CF;
  }
  
  #item3{
    width:150px;
    height:150px;
     border-radius:50%;
    background:#243D83;
  }
  
  #item4{
    width:50px;
    height:50px;
     border-radius:50%;
    background:#EEB850;
  }
  
  
  
  
</style>

<!-- OBJECTIVE -->
<!-- Write HTML/CSS in this editor and replicate the given target image in the least code possible. What you write here, renders as it is -->

<!-- SCORING -->
<!-- The score is calculated based on the number of characters you use (this comment included :P) and how close you replicate the image. Read the FAQS (https://cssbattle.dev/faqs) for more info. -->

<!-- IMPORTANT: remove the comments before submitting -->
728x90

'HTML_CSS > CSS Battle' 카테고리의 다른 글

1-6. Missing Slice  (0) 2021.10.14
1-5. Acid Rain  (0) 2021.10.14
1-4. Ups n Downs  (0) 2021.10.14
1-2. Carrom  (0) 2021.10.14
1-1. Simply Square  (0) 2021.10.14
공지사항
최근에 올라온 글
최근에 달린 댓글
Total
Today
Yesterday
링크
«   2024/11   »
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
글 보관함