*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
* {
    transition: all 0.2s ease;
}
body {
    font-family: 'Poppins', sans-serif;
}

/* canvas  */
#paint {
    width: 100%;
    height: 100%;
    display: block; 
}
/* paint area */

#paintarea{
    position: relative;
    border: 8px solid #1a1a40;
    height: 70vh;
    width:100%;

}
/* option button */
.options{
    height:30vh ;
    background-color: #1a1a40;
    padding: 30px;

}
/* tools are  */
.tool-row{
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    gap: 20px;
    margin-bottom: 40px;

}
/* row function */
.tool-row h5{
    margin-bottom: 10px;
    color: white;
    font-weight: 400;
    font-size: 19px;
    letter-spacing: 0.6px;
}
canvas.dark {
    background: #121212;
    color: #e0e0e0;
}
/* butoon styling */
.tool-row button {
     width: 200px;   
    height: 45px;   
    padding: 0;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 600;
    border: none;
    background: white;
    color: #788eff;
    cursor: pointer;
       box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}
/* hover button section */
.tool-row button:hover {
    background: #5f72d6;
    color: white;
}

input[type="range"]{
    height: 40px;

}
input[type="color"]{
    appearance:none;
    width: 80px;
   height: 40px;
   border: 2px ;
   border-radius: 5%;
   background-color: transparent;
   cursor: pointer;
}
input[type="color"]::-webkit-color-swatch{
    border-radius: 8px;
    border: 3px solid black ;
}
input[type="color"]::-moz-color-swatch {
    border-radius: 8px;
    border: 3px solid black;
}
/* font selest */
#font-select {
    width: 180px;
    padding: 10px;
    border-radius: 8px;
    border: 2px solid #5f72d6;
    font-size: 16px;
    cursor: pointer;
    background: white;
    color: #333;
    transition: all 0.3s ease;
}
/* toogle button styling */
#toggle-darkmode {
  position: absolute;
  top: 15px;
  right: 15px;
  padding: 10px 20px;
  background: linear-gradient(135deg, #5f72d6, #788eff);
  color: white;
  border: none;
  border-radius: 25px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0,0,0,0.25);
  transition: all 0.3s ease;
}
#toggle-darkmode:hover {
  filter: brightness(1.15);
  transform: translateY(-2px);
}

/* mobile screen */
@media screen and (max-width: 768px) {


  #paintarea {
    height: 82vh;
    width: 100%;
    border: 5px solid #1a1a40;
  }

  .options {
    height: auto;
    padding: 15px;
  }

  
  .tool-row {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 20px;
  }
  .tool-row {
    grid-template-columns: 1fr 1fr 1fr 1fr;
    gap: 10px;
    margin-bottom: 20px;
  }
  .tool-row button {
    width: 100%;
    height: 40px;
    font-size: 14px;
    border-radius: 20px;
  }

  
  #font-select {
    width: 100%;
    font-size: 14px;
    padding: 8px;
  }
  
  input[type="range"] {
    width: 100%;
    height: 30px;
  }

  input[type="color"] {
    width: 60px;
    height: 35px;
  }

  
  #toggle-darkmode {
    top: 10px;
    right: 10px;
    padding: 8px 15px;
    font-size: 14px;
  }
}