@import url('https://fonts.googleapis.com/css2?family=Barlow:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');

.calendar-modal {
    background-color: #ddddddab;
    justify-content: center;
    align-items: center;
    width: 100vw;
    height: 100vh;
    display: flex;
    z-index: 0;
    position: fixed;
    top: 0;
    left: 100%;
    opacity: 0;
    box-sizing: border-box;
    transition: opacity 0.1s ease-in-out;
}

.calendar-modal.show {
    top: 0;
    left: 0;
    opacity: 1;
    z-index: 200;
}

.calendar-container {
    font-family: Barlow, sans-serif;
}

.calendar-container .container-new {
    display: inline-block;
    background-color: #fff;
    padding: 1rem;
    border-radius: 4px;
}

.calendar-container .header-display p {
    color: #000;
    margin: 5px;
    font-size: 14px;
    font-weight: 500;
    word-spacing: 0.5rem;
    user-select: none;
}

.calendar-container .calendar-days-wrapper {
    height: 276px;
}

.calendar-container div {
    transition: all 0.2s ease-in-out;

}


.calendar-container .calendar-days-wrapper,
.calendar-container .calendar-week-wrapper {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    margin: auto;
    padding: 0px 20px;
    justify-content: space-between;
    user-select: none;
}

.calendar-container .calendar-week-wrapper div,
.calendar-container .calendar-days-wrapper div {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 2.5rem;
    width: 3.1em;
    border-radius: 4px;
    margin: 3px;
    cursor: pointer;
    border: 1px solid transparent;
}

.calendar-container .calendar-week-wrapper div {
    font-weight: 500;
    font-size: 14px;
}

.calendar-container .calendar-days-wrapper div {
    font-weight: 400;
    font-size: 13px;
}

.selected-date {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
}

.disabled-date {
    pointer-events: none;
    opacity: 0.4;
}

.custom-calendar>.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin: 1rem 1.5rem;
}

.calendar-header .left,
.calendar-header .right {
    display: flex;
    justify-content: center;
    align-items: center;
    border: none;
    outline: none;
    background-color: transparent;
    cursor: pointer;
    user-select: none;
}

.calendar-container .display-selected {
    margin: 1rem 0;
    background-color: #bd191e10;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 500;
    padding: 1rem 0;
}

.calendar-days-wrapper div:not(.disabled-date) {
    position: relative;
}

.calendar-days-wrapper div.active-date {
    border: 1px solid #bd191e85;
    background-color: #bd191e0a;
}

.calendar-days-wrapper div.highlighted-date {
    border: 1px solid #bd191e85;
}

.calendar-days-wrapper div.available-date::before {
    content: "";
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background-color: #bd191f99;
    position: absolute;
    bottom: 6px;
    left: 50%;
    transform: translateX(-50%);
}


.calendar-days-wrapper div:not(.available-date) {
    opacity: 0.4;
    cursor: not-allowed;
}

.calendar-days-wrapper div.available-date {
    opacity: 1;
}

.base-save-btn {
    border: none;
    outline: none;
    background-color: var(--primary-color);
    font-weight: 500;
    text-transform: uppercase;
    cursor: pointer;
    text-align: center !important;
    font-size: 13px;
    padding: 0.5rem;
    border-radius: 4px;
}

.base-cancel-btn {
    border: 1px solid #dddddd;
    outline: none;
    background-color: var(--white);
    font-weight: 500;
    text-transform: uppercase;
    cursor: pointer;
    text-align: center !important;
    font-size: 13px;
    padding: 0.5rem;
    border-radius: 4px;
}

.calendar-footer-btn-wrapper {
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    margin-top: 1rem;
}

.pointer-events-none {
    pointer-events: none;
}

.container-new {
    position: relative;
}

.container-new::before {
    content: "";
    position: absolute;
    top: -9px;
    left: 17px;
    width: 6%;
    height: 6%;
    background-color: #ffffff;
    border-radius: 4px;
    rotate: 44deg;
    z-index: 0;
}

.calendar-error-wrapper {
    font-weight: 500;
    font-size: 14px;
    text-align: center;
}

.display-selected-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2rem;
}

.calendar-start-date-wrapper,
.calendar-end-date-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
}

.calendar-start-date,
.calendar-end-date {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2px;
}

.error-shake {
    animation: horizontal-shaking 0.25s linear infinite;
}

@keyframes horizontal-shaking {
    0% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(5px);
    }

    50% {
        transform: translateX(-5px);
    }

    75% {
        transform: translateX(5px);
    }

    100% {
        transform: translateX(0);
    }
}

.save-calendar-btn,
.cancel-calendar-btn {
    border: none;
    outline: none;
    font-weight: 500;
    text-transform: uppercase;
    cursor: pointer;
    text-align: center !important;
    font-size: 13px;
    padding: 0.5rem;
    border-radius: 4px;
    width: 100%;
    box-sizing: border-box;
}

.cancel-calendar-btn {
    border: 1px solid #dddddd;
    background-color: white;
    color: #000000;
}

.save-calendar-btn {
    background-color: #bd191f;
    border: 1px solid #bd191f;
    color: #ffffff;
}

.transition {
    transition-timing-function: cubic-bezier(0.58, 0.3, 0.005, 1);
    transition: 0.3s;
}

.text-red-500 {
    color: rgb(239 68 68);
}

@media only screen and (max-width: 476px) {
    .calendar-footer-btn-wrapper {
        flex-direction: column;
        gap: 0.4rem;
    }

    .calendar-container .calendar-week-wrapper div,
    .calendar-container .calendar-days-wrapper div {
        height: 2.8rem;
        width: 2rem;
    }
}

@media only screen and (max-width: 373px) {
    .calendar-container .container-new {
        padding: 0;
    }

    .display-selected,
    .calendar-footer-btn-wrapper,
    .calendar-error-wrapper {
        margin: 1rem !important;
    }
}

.highlighted-range {
    background-color: #bd191e0a;
}