body {
      font-family: Arial, sans-serif;
      font-size: clamp(14px, 2vw, 18px);
      background: #f9f9f9;
      display: flex;
      flex-direction: column;
      align-items: center;
      padding: 1vw;
    }

    h1 {
      margin-bottom: 10px;
      font-size: clamp(1.5rem, 4vw, 2.5rem);
    }

    .controls {
      margin: 1.2rem 0;
    }

    .controls button {
      padding: 0.5rem 1rem;
      margin: 0 0.625rem;
      font-size: clamp(0.875rem, 2vw, 1.125rem);
      cursor: pointer;
      background-color: #007bff;
      color: white;
      border: none;
      border-radius: 0.375rem;
    }

    #monthYear {
      font-size: clamp(1rem, 2.5vw, 1.25rem);
      font-weight: bold;
    }

    .calendar {
      display: grid;
      grid-template-columns: repeat(7, 1fr);
      gap: 0em;
      width: 100%;
      max-width: 980px;
      box-sizing: border-box;
    }

    .day {
      background: #e0ffe0;
      border: .01vw solid #ccc;
      border-radius: 1vw;
      padding: 1vw;
      text-align: center;
      font-size: clamp(0.75rem, 1.2vw, 1rem);
    }

    .inactive {
      background: #f0f0f0;
      opacity: 0.6;
      }

     

    .slot {
      padding: 6px;
      margin-top: 4px;
      border-radius: 8px;
      }



    .free {
      background-color: #299929;
    }

    .busy {
      background-color: #f8a5a5;
    }

    .calendar-header {
      display: grid;
      grid-template-columns: repeat(7, 1fr);
      width: 100%;
      max-width: 61.25rem; /* Same as .calendar */
      box-sizing: border-box;
      margin-bottom: 0.5rem;
          }

.day-name {
      text-align: center;
      font-weight: bold;
      font-size: clamp(0.75rem, 1.2vw, 1rem);
      padding: 0.25rem 0;
      background-color: #e6e6e6;
      border-radius: 0.5rem;
}



/*for very narrow devices, only three columns*/

    @media (max-width: 320px) {
    .day   {
          font-size: clamp(0.5rem, 1.2vw, 1rem);/*reduce font size on small devices, could affect readability*/
 }           
}