*{
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}
:root{
    --white:#fff;
    --whitegray:#e0e0e0;
    --black:#000000;
    --grayblack: rgb(39, 39, 39);
     --indi-white:#fff;
      --lightblack:#212121;
}


body{
    height: 100vh;
    width: 100vw;
    background-color: var(--whitegray);
    overflow-x: hidden;
}
.container{
    display: flex;
    justify-content: center;
  align-items: center; 
   max-width: 100%;
   min-width: 300px;
    padding-top: 30px;
    margin-bottom: 40px;
    
}
/* nav bar */
.nav{
    width: 70%;
 
   align-items: flex-start;
   border-radius: 30px;
    height: 60px;
    background-color: var(--black);
    backdrop-filter: blur(10px);
    display: flex;
align-items: center;
justify-content: space-around;
box-shadow: 8px 8px 16px var(--grayblack), -8px -8px 16px var(--whitegray);
}
.logo {
    font-size: 30px;
    color: var(--white);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 12px;
    cursor: pointer;
}
.menu ul{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
   
}
.menu ul li{
    list-style-type: none;    
}
.menu ul li a{
    text-decoration: none;
    font-size: 20px;
    color: var(--white);
    text-transform: capitalize;
    position: relative;
 
}
.menu ul li a::after{
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  border-radius: 20px;
  height: 3px;
  width: 100%;
  background-color: var(--white);
  transform: scaleX(0);
  transition: all 0.3s ease;
}
.menu ul li a:hover::after{
    transform: scaleX(1);
}
/* toggle */
.label {
  display: inline-flex;
  align-items: center;
  cursor: pointer;
  color: #394a56;
}

.label-text {
  margin-left: 16px;
}

.toggle {
  isolation: isolate;
  position: relative;
  height: 30px;
  width: 60px;
  background-color: var(--white);
  border-radius: 15px;
  overflow: hidden;
   box-shadow: -2px -2px 8px var(--whitegray),
    2px 2px 8px  #444445,
    4px 4px 4px 0px #d1d9e6 inset,
    -4px -4px 4px 0px #ffffff inset;
}
body.darktheme .toggle{
background-color: #212121;
box-shadow: -2px -2px 8px rgb(50, 50, 50),
    2px 2px 8px  rgb(25, 25, 25),
    4px 4px 4px 0px  rgb(25, 25, 25)inset,
    -4px -4px 4px 0px rgb(50, 50, 50) inset;
}

.toggle-state {
  display: none;
}

.indicator {
  height: 100%;
  width: 200%;
  background: #0c0e0f;
  border-radius: 15px;
  transform: translate3d(-75%, 0, 0);
  transition: transform 0.4s cubic-bezier(0.85, 0.05, 0.18, 1.35);
  box-shadow: -8px -4px 8px 0px #ffffff,
    8px 4px 12px 0px #d1d9e6;
}


.toggle-state:checked ~ .indicator {
  transform: translate3d(25%, 0, 0);
}
.menubtn{
    background-color: white;
    width: 26px;
    padding: 5px;
    border-radius: 10px;
    display: none;
    box-shadow: inset 2px 2px 10px rgb(41, 41, 41) ,inset -2px -2px 10px #e0e0e0;
}
.closebtn{
    display: block;
    background-color: white;
    width: 26px;
    padding: 5px;
    border-radius: 10px;
    position: absolute;
    right: 10%;
    display: none;
      box-shadow: inset 2px 2px 10px rgb(41, 41, 41) ,inset -2px -2px 10px #e0e0e0;

}
body.darktheme{
 background-color: var(--lightblack);
 
}
body.darktheme .nav{
    background-color: var(--whitegray);
    color: var(--black);
    box-shadow: 8px 8px 16px var(--whitegray), -8px -8px 16px var(--lightblack);
}
body.darktheme .logo {
    color: var(--black);
}
body.darktheme .menu ul li a {
    color: var(--black);
}
body.darktheme .menu ul li a {
    color: var(--black);
}
body.darktheme .menu ul li a::after{
  background-color: var(--black);
  
}

body.darktheme .indicator{
     background: var(--whitegray);
       box-shadow: -8px -4px 8px 0px rgb(25, 25, 25),
    8px 4px 12px 0px rgb(25, 25, 25);
}

@media (max-width:700px) {
 body{
  overflow-x: hidden;
  
 }
   .logo {
    font-size: 16px;
} 
.nav{
     width: 100%;
}
.menu{
    position: absolute;
   width: 150px;
  padding-inline-start: 0;
  right: -200px;
    top: 0%;   
    background-color: black;
    z-index: 100;
    padding:20px;
    border-radius: 20px;
    transition: all 0.5s linear;
    display: none;
}
body.darktheme .menu{
  background-color: var(--whitegray);
}
.menu ul{
   flex-direction: column;
 padding-top: 50px;
 padding-bottom: 50px;
     
}
.menu ul li{
  display: block;

}
.menu ul li a{
    color: white; 
      
}
.toggle {

  height: 20px;
  width: 40px;
 
}

.menubtn, .closebtn{
    display: inline-block;
}
}
/* nav bar end */

/* weather */
.weather{
    width: 80%;
    margin: auto;
  
    display: flex;
    align-items: center;
    justify-content: center;
       border-radius: 50px;

}
.cards{
    width: 100%;
    max-width: 560px;
    min-width:300px;
   padding: 40px 20px 20px;
      background: var(--lightblack);
  box-shadow: 20px 20px 60px #bebebe,
               -20px -20px 60px #ffffff;

}
body.darktheme .cards{
box-shadow: 4px 4px 10px #bebebe,
               -4px -4px 10px #ffffff;               
 background: #e0e0e0;

}
.search{
    width: 90%;
    margin: 15px auto 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;   
}
.search input{
   height: 50px;
   width: 70%;
    border-radius: 30px;
    font-size: 20px;
    padding: 10px;
    text-transform: capitalize;
    border: none;
      background-color: transparent;
  box-shadow: 3px 3px 10px rgba(0,0,0,1),
  -1px -1px 6px rgba(255, 255, 255, 0.4);
}
body.darktheme .search input{
 box-shadow: 
  3px 3px 10px #c5c5c5, 
  -1px -1px 6px #ffffff;

}
.search input:focus{
    outline: none;
    color: #fff;
  box-shadow: 3px 3px 10px rgba(0,0,0,1),
  -1px -1px 6px rgba(255, 255, 255, 0.4),
  inset 3px 3px 10px rgba(0,0,0,1),
  inset -1px -1px 6px rgba(255, 255, 255, 0.4);
}
.search input::placeholder{
    font-size: 24px;
     text-transform: capitalize;
}
.search button {
    flex-direction: 30%;
    width:50px;
    height: 50px;
    border-radius: 100%;
    display:flex;
    align-items: center;
    justify-content: center;
    border: none;
     cursor: pointer;
      background: #212121;
  border: 1px solid #212121;

  box-shadow: 6px 6px 12px #000, -6px -6px 12px #2f2f2f;
}
body.darktheme .search button{
 background: #e8e8e8;
  border: 1px solid #e8e8e8;
  transition: all 0.3s;
  box-shadow: 6px 6px 12px #c5c5c5, -6px -6px 12px #ffffff;
  color: black;
}
body.darktheme .search input:focus{
    color: #000; /* Use black text for contrast in light mode */
box-shadow: 
  3px 3px 10px #c5c5c5,               /* outer shadow (light gray) */
  -1px -1px 6px #ffffff,              /* outer highlight (white) */
  inset 3px 3px 10px #c5c5c5,         /* inner shadow (light gray) */
  inset -1px -1px 6px #ffffff;        /* inner highlight (white) */

}
.search button img{
    width: 15px;
}
@media (max-width:700px) {
    .cards{
   margin-top: 10px;
}
.search{
    width: 100%;
    
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;  
}
.search input{
    height:40px ;
   width: 70%;
    border-radius: 30px;
    font-size: 18px;
    padding: 10px;
    text-transform: capitalize;
    border: none;
}
.search input::placeholder{
    font-size: 18px;
     text-transform: capitalize;
}
.search button {
   width: 30%;
    width:40px;
    height: 40px;
}
.search button img{
    width: 15px;
}
}
.hero{
    width: 90%;
    margin: 40px auto 10px;
    text-align: center;
   
}
.hero > img{
    width: 180px;
    margin-bottom: 30px;
     background: #212121;
  border: 1px solid #212121;

  box-shadow: 6px 6px 12px #000, -6px -6px 12px #2f2f2f;
}
.hero .temploc{
    
}
.hero .temploc h4:nth-child(1){
    color: white;
    font-size: 52px;
    line-height: 60px;
     text-transform: capitalize;
}
.hero .temploc h4:nth-child(2){
    color: white;
    font-size: 42px;
    text-transform: capitalize;
    display: inline;
    position: relative;
     cursor: pointer;
}
.hero .temploc h4:nth-child(2)::after{
    content: '';
    position: absolute;
    bottom:-5px;
    left: 0;
    width: 100%;
    transform: scaleX(0);
    height: 3px;
    background-color: white;
    transition: all 0.3s linear;
   
}
.hero .temploc h4:nth-child(2):hover::after{
    transform: scaleX(1);
}

.humispeed{
    width: 90%;
margin: 40px auto 10px;
    color: white;
    display: flex;
    align-items: center; 
    justify-content: space-between;
    gap: 30px;
     
}
.humi,.speed{
   display: flex;
   align-items: center;
   gap: 15px;
    background: #212121;
  border: 1px solid #212121;
  transition: all 0.3s;
  box-shadow: 6px 6px 12px #000, -6px -6px 12px #2f2f2f;
   
    
}
.humi img ,.speed img{
    width: 55px;
    padding-top: 20px;
}
.text p:nth-child(1){
    font-size: 32px;
}
.text p:nth-child(2){
    font-size: 28px;
}
body.darktheme .humi{
    padding: 5px;
color: #090909;
  background: #84f1b5;
  border: 1px solid #84f1b5;
  box-shadow: 6px 6px 12px #c5c5c5, -6px -6px 12px #ffffff;
}
body.darktheme .speed{
color: #090909;
  background: #84f1b5;
  border: 1px solid #84f1b5;
  box-shadow: 6px 6px 12px #c5c5c5, -6px -6px 12px #ffffff;
}
body.darktheme .hero .temploc h4{
    color: black;
}
body.darktheme .hero> img {
     border-radius: 0.5em;
        background: #e8e8e8;
  border: 1px solid #e8e8e8;
  box-shadow: 6px 6px 12px #c5c5c5, -6px -6px 12px #ffffff;
}
@media (max-width:700px){
  .humispeed{
 flex-direction: column;     
} 
.humi img ,.speed img{
    width: 45px;
    padding-top: 20px;
}
.text p:nth-child(1){
    font-size: 28px;
}
.text p:nth-child(2){
    font-size: 24px;
} 
.humi,.speed{
    width: 100%;
    justify-content: center;
    text-transform: capitalize;
   padding: 0.7em 1.7em;
  font-size: 18px;
  border-radius: 0.5em;
  background: #212121;
  border: 1px solid #212121;
 
  box-shadow: 6px 6px 12px #000, -6px -6px 12px #2f2f2f;
   color: white; 
}
body.darktheme .humi{
color: #090909;
  background: #84f1b5;
  border: 1px solid #84f1b5;
  box-shadow: 6px 6px 12px #c5c5c5, -6px -6px 12px #ffffff;
}
body.darktheme .speed{
color: #090909;
  background: #84f1b5;
  border: 1px solid #84f1b5;
  box-shadow: 6px 6px 12px #c5c5c5, -6px -6px 12px #ffffff;
}
body.darktheme .hero .temploc h4{
    color: black;
}
body.darktheme .hero> img {
     border-radius: 0.5em;
        background: #e8e8e8;
  border: 1px solid #e8e8e8;
  box-shadow: 6px 6px 12px #c5c5c5, -6px -6px 12px #ffffff;
}
}
