#exercise{  
  max-width: 800px;
  touch-action: manipulation;
}

/*#exercise{  
  padding-top:20px;  
  clear:both;
  overflow: hidden;  
  max-width: 800px; 
  margin: 0px auto;       
  min-height:600px;
  text-align: center;        
  padding-bottom: 50px;
}
*/
#exercise h1,h2,h3{    
  margin: 5px 0px;
}

/* PRAVIDLA */
#exercise #rules{  
  max-width: 500px;
  text-align: left;
  margin:auto;
  display: block;
  background-color: white;  
  padding:20px;
  margin-bottom: 15px;
  border-radius: 6px;
  box-shadow: 0px 0px 32px 0px rgba(0,0,0,0.0);
}

/* TLACITKA */
#exercise .tlacitko-control{
  display: inline-block;
  margin: 5px;  
  margin-top: 15px;
  font-size: 18px;    
  width: 150px;      
  text-align:center;  
  border-radius:2px;  
  line-height: 50px;  
  cursor: pointer;

  background-color: #e0e0e2;
  color: var(--darkGray);
}

#exercise .tlacitko-control:hover{ 
  color:white; 
  background-color:#2ecc71; 
}

#exercise .tlacitko-control.disabled{ 
  color:white;
  background-color:#e6e8ea;  
}

#plan{
  display: inline-block;  
  padding: 30px;
  background-color: white;
  margin:20px;
  border-radius: 6px;
}

table.grid{
  margin:0px;
}

table.grid td{
  width: 50px;
  height: 50px;  
  background-color: white;
  font-size: 26px;
  font-weight: bold;
  border:0px solid white;
}


table.grid td.fence{  
  width: 10px;
  height: 10px;
  background-color: #ecf0f1;
  background-color: white;
  cursor: pointer;
}

table.grid td.fence:hover{
  background-color: #ecf0f1;
}

table.grid td.intersection{
  background-color: #ffebaa;
  width: 10px;
  height: 10px;
}

table.grid td.fence.selected{  
  background-color: #35495d;
}

table.grid td.fence.deleted{  
  background-color: white;
  background-position: center center;
  background-repeat: no-repeat;   
}

@media screen and (max-width: 550px) {
  table.grid td{
    width: 30px;
    height: 30px;  
    font-size: 20px;
    font-weight: bold;
    text-align: center;
  }
  table.grid td.fence, table.grid td.intersection{  
    width: 20px;
    height: 20px;
  }  
  #plan{
    display: inline-block;  
    padding: 5px;
    background-color: white;
    margin:10px;
    border-radius: 6px;
  }
}
