# Positioning in CSS

Position are types 
    1. Static (default)
    2.  Relative
    3.  Absolute
    4.  Fixed 
    5.  Sticky 


static are by default in nature nothing much will happen on it just be on default position on the page

# Relative positioning allow us to use top, bottom, left, right on a particular element and simple to move them on the webPage where ever we want accordingly 

it is relative to its normal position 
but by using relative there is gap left on its original position if gap is required we will use relative   


# Absolute will shift its position relative to its parent on the page.
   the box will shift according to it's parent form top or left it will jump on the top of it  
   only based on its first parent in the code


# Fixed as name suggest it helps us to fix any of the element on the page and if even we scroll left right or top bottom the element will not go anywhere it will be fixed on that particular location that we declared by the right: or bottom: position the element relatives to it's browser window 

# sticky when we scroll through the web page the position we declared sticky will be stick on the particular pace where its location is
it helps while designing the navigation bar of a website we  want the home all have to stick on top so we can declare them on sticky 
  
CODE FOR ALL THE POSITIONS:

<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .container{
            border: 5px solid black;
            background-color: bisque;
            height: 3444px;

        }
        .box{
            display: inline-block;
            border: 2px solid red;
            width: 150px;
            height: 150px;
            margin: 3px;
        }
        #box3{
            position: relative;
            top: 35px;
            left: 35px;
        }
        #box2{
             position: absolute;
             top: 35px;
             left: 135px;
        }
        #box3{
            position: fixed;
            right: 4px;
            bottom: 2px;
        }
        #box4{
            position: sticky;
            top: 3px;

        }

    </style>
</head>
<body> 
    <div class="container">
        <div class="box" id="box1">box1</div>
        <div class="box" id="box2">box2</div>
        <div class="box" id="box3">Chat box</div>
        <div class="box" id="box4">box4</div>

    </div>
    
</body>
</html>


    







