.calendar {
    margin: 0 auto;
    max-width: 100%;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
}

.calendar-month-year {
    margin: 0; /* Removes margin from h4 to keep things tight */
    font-size: 1em; /* Adjust size as needed */
}

.calendar-nav a {
    margin: 0 10px; /* Space out the nav arrows */
    color: #007bff; /* Example color; adjust as needed */
    text-decoration: none; /* Removes underline from links */
}

.calendar-nav i.fa {
    font-size: 1.2em; /* Adjust arrow size as needed */
}

.calendar .table {
    width: 100%;
    table-layout: fixed;
    border-collapse: collapse;
}

.calendar th,
.calendar td {
    text-align: right;
    border: 1px solid #ddd;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    padding: 5px;
    vertical-align: top;
    position: relative;
    /* For positioning event dots */
}

.calendar th {
    background-color: #f2f2f2;
    height: 40px;
}

.calendar td {
    width: 14.28%;
    /* Evenly distribute columns */
    min-height: 80px;
    /* Ensure enough space for multiple events */
    height: 80px;
}

.calendar td:hover {
    background-color: #f2f2f2;
    /* Add your desired shade color */
}


.calendar .event-bar {
    background-color: #007bff;
    /* Example event color */
    color: white;
    text-align: center;
    padding: 2px 0;
    border-radius: 4px;
    font-size: 0.75em;
    /* Smaller font size for the event bar */
    margin-top: 5px;
    cursor: pointer;
    display: block;
    /* Ensure it behaves as a block for layout */
}

@media (max-width: 767px) {

    .calendar th,
    .calendar td {
        text-align: center;
        /* Center-align the text for smaller screens */
        padding: 2px;
        font-size: 0.75em;
        /* Smaller font size for better fit */
    }

    .calendar .event-bar {
        height: 10px;
        width: 10px;
        border-radius: 50%;
        /* Create a dot shape */
        padding: 0;
        font-size: 0;
        /* Hide text */
        margin: 5px auto;
        /* Center the dot horizontally */
    }

    .calendar td {
        padding-top: 20px;
        /* Add padding to ensure space for the dots */
    }
}