@import url('https://fonts.googleapis.com/css2?family=Quicksand:wght@500&display=swap');
@font-face {
    font-family: digital7;
    src: url(../fonts/digital-7.ttf);
  }

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: #090909;
    background: #07141b;
    /* background: url(../bg.png); */
}



body.light {
    background: #d1dae3;
}


.clock {
    width: 500px;
    height: 500px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: url(../watch3.png);
    background-size: 100%;
    background-repeat: no-repeat;
    background-position: center center;    
}

body.light .clock {
    box-shadow: 0em -1.2em 1.2em rgba(255, 255, 255, 0.3),
                inset 1em 1em -1em rgba(255, 255, 255, 0.3),
                0em -1.2em -1.2em rgba(0, 0, 0, 0.5),
                inset 1em -1em 1em rgba(0, 0, 0, 0.1);
}

.clock :hover {
    /* yet to be completed; when hovered, diplay complete information about time, `new Date().toLocaleString();` */
    cursor: pointer;

}



/* The small circle int the center */
.clock:before {
    /* content: '';
    position: absolute;
    width: 15px;
    height: 15px;
    background: rgb(255, 255, 255);
    border-radius: 50%; */

    /* The z-index property specifies the stack order of an element.
    /* An element with greater stack order is always in front of an element with a lower stack order.  */
    /* Note: z-index only works on positioned elements (position: absolute, position: relative, position: fixed, or position: sticky). */
    z-index: 10000;
    /* kept as a high value, since wanted at top */
}

body.light .clock:before {
    background: #1a74be;
}


.clock .hour,
.clock .min,
.clock .sec {
    position: absolute;
}

/* length of respective arms; */
.clock .hour, .hr {
    width: 500px;
    height: 500px;
    /* min-height: 100vh; */
} 

.clock .min, .mn {
    width: 500px;
    height: 500px;
    /* min-height: 100vh; */
}

.clock .sec, .sc {
    width: 500px;
    height: 400px;
    display:none;
    
}


.hr, .mn, .sc {
    display: flex;
    justify-content: center;
    /* align-items: center; */
    position: absolute;
    border-radius: 50%;
    
}

.dsc, .dd, .dm, .dda,.dadd{
    width:300px;
    height:300px;
    position: absolute;
    font-family: digital7;
    color:#fff;
}
.dsec{
    top: 48%;
    right: 24%;
    position: absolute;
    font-size: 20px;
}
.dday{
    top: 44%;
    left: 22%;
    position: absolute;
    font-size: 15px;
}
.dmonth{
    top: 49%;
    left: 24%;
    position: absolute;
    font-size: 15px;
}
.ddate{
    top: 54%;
    left: 27%;
    position: absolute;
    font-size: 15px;
}

.daddr{
    top: 64.5%;
    left: 38%;
    position: absolute;
    font-size: 14px;
    width: 26%;
    overflow: hidden;
    animation-duration: 7s;
    animation-timing-function: linear;
    animation-delay: 0s;
    animation-iteration-count: infinite;
    animation-direction: normal;
    animation-fill-mode: none;
    animation-play-state: running;
    animation-name: scroll;
}

.hr:before {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    /* background: #f81460; */
    background: url(../hour.png);
    background-size: cover;
    z-index: 10;
    /* z-index least */
    border-radius: 2.8px;
}

.mn:before {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    /* background: #8a3ead; */
    background: url(../minute.png);
    background-size: cover;
    z-index: 11;
    /* z-index more than hour hand */
    border-radius: 3px;
}

body.light .mn:before {
    background: #091921;

}


.sc:before {
    content: '';
    position: absolute;
    width: 3px;
    height: 260px;
    background: #0075fa80;
    /* background: url(../hand.png);
    background-size: cover; */
    z-index: 12;
    /* z-index more than hour minute hand */
    border-radius: 3px;
}


.toggleClass {
    position: absolute;
    top: 35px;
    right: 150px;
    width: 20px;
    margin: 2px;
    height: 20px;
    font-size: 18px;
    border-radius: 50%;
    background: #d1dae3;
    color: #d1dae3;
    font-family: 'Quicksand', sans-serif;
    cursor: pointer;
    display: flex;
    align-items: center;
}


.toggleClass:before {
    position: absolute;
    content: 'Light Mode';
    white-space: nowrap;
    left: 25px;
}

body.light .toggleClass {
    background: #091921;
    color: #091921;
    content: 'Dark Mode';
}


body.light .toggleClass:before {
    content: 'Dark Mode';
    white-space: nowrap;
}

@media only screen and (max-width: 400px) {
    .clock {
        width: 375px;
        height: 375px;
    }
    .mn:before,
    .hr:before,
    .clock .min, .mn,
    .clock .hour, .hr {
        width: 375px;
        height: 375px;
        /* min-height: 100vh; */
    } 

    .dsc, .dd, .dm, .dda,.dadd{
        width:220px;
        height:220px;        
    }
    
    .clock .sec, .sc {
        width: 375px;
        height: 375px;
        display:none;
        
    }
    .dsec{
        top: 48%;
        right: 24%;        
        font-size: 15px;
    }
    .dday{
        top: 44%;
        left: 23%;
        font-size: 11px;
    }
    .dmonth{
        top: 49%;
        left: 24%;
        font-size: 12px;
    }
    .ddate{
        top: 54%;
        left: 27%;
        font-size: 12px;
    }
    
    .daddr{
        top: 63.5%;
        left: 38%;        
        font-size: 10px;
        width: 26%;
        height:10px;
    }
}