.courses{
  height: 600px;
  margin: 0;
  display: grid;
  grid-template-rows: 500px 100px;
  grid-template-columns: 1fr 30px 30px 30px 30px 30px 1fr;
  align-items: center;
  justify-items: center;
}
 
#courseImg{
    height: 185px;
    width: 95%;
    object-fit: cover;
    margin: 5px 0px;
    border-radius: 15px;
}


main#carousel {
  
    grid-row: 1 / 2;
    grid-column: 1 / 8;
    width: 100%;
    height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transform-style: preserve-3d;
    perspective: 600px;
    --items: 7;
    --middle: 4;
    --position: 1;
  }
  
  div.item {
    position: absolute;
    width: 300px;
    height: 400px;
    background-color: coral;
    --r: calc(var(--position) - var(--offset));
    --abs: max(calc(var(--r) * -1), var(--r));
    transition: all 0.25s linear;
    transform: rotateY(calc(-10deg * var(--r)))
      translateX(calc(-300px * var(--r)));
    z-index: calc((var(--position) - var(--abs)));
    border-radius: 15px;
    text-align: center;
  }

  div.item h4{
    margin: 0 0;
  }

  div.item button{
    border-radius: 8px;
    border: none;
    color: white;
    padding: 3px 6px;
    margin: 4px 2px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    background-color: rgb(0, 0, 0);
    cursor: pointer;
  }
  
  div.item:nth-of-type(1) {
    --offset: 1;
    background-color: #90f1ef;
  }
  div.item:nth-of-type(2) {
    --offset: 2;
    background-color: #ff70a6;
  }
  div.item:nth-of-type(3) {
    --offset: 3;
    background-color: #ff9770;
  }
  div.item:nth-of-type(4) {
    --offset: 4;
    background-color: #ffd670;
  }
  div.item:nth-of-type(5) {
    --offset: 5;
    background-color: #e9ff70;
  }
  div.item:nth-of-type(6) {
    --offset: 6;
    background-color: #ff70ea;
  }
  div.item:nth-of-type(7) {
    --offset: 7;
    background-color: #70faff;
  }
  
  input:nth-of-type(1) {
    height: 25px;
    width: 25px;
    margin-left: 95%;
  }
  input:nth-of-type(1):checked ~ main#carousel {
    --position: 1;
  }
  
  input:nth-of-type(2) {
    height: 25px;
    width: 25px;
  }
  input:nth-of-type(2):checked ~ main#carousel {
    --position: 2;
  }
  
  input:nth-of-type(3) {
    height: 25px;
    width: 25px;
  }
  input:nth-of-type(3):checked ~ main#carousel {
    --position: 3;
  }
  
  input:nth-of-type(4) {
    /* grid-column: 5 / 6;
    grid-row: 2 / 5; */
    height: 25px;
    width: 25px;
  }
  input:nth-of-type(4):checked ~ main#carousel {
    --position: 4;
  }
  
  input:nth-of-type(5) {
    height: 25px;
    width: 25px;
  }
  input:nth-of-type(5):checked ~ main#carousel {
    --position: 5;
  }

  input:nth-of-type(6) {
    height: 25px;
    width: 25px;
  }
  input:nth-of-type(6):checked ~ main#carousel {
    --position: 6;
    
  }
  input:nth-of-type(7) {
    height: 25px;
    width: 25px;
    margin-right: 95%;

  }
  input:nth-of-type(7):checked ~ main#carousel {
    --position: 7; 
  }
  