/* ------------ Calendar ------------ */
.widget-calendar {
    width: 100%;
}

.widget-calendar * {
    padding: 0;
    margin: 0;
    outline: none;
    font-family: 'nobel', sans-serif;
}

.widget-calendar *, .widget-calendar *:before, .widget-calendar *:after {
    box-sizing: border-box;
}

.widget-calendar.disable-pointer * {
    pointer-events: none !important;
}

.widget-calendar .widget-calendar-main {
    width: 100%;
    padding: 0 1em;
    display: none !important;
}

.widget-calendar .widget-calendar-main.show {
    display: block !important;
}

/* ---- Header ---- */
.widget-calendar-header {
    width: 100%;
    margin: 0 auto;
    padding: 1em 0;
}

.widget-calendar-control {
    display: flex;
    justify-content: space-between;
    align-items: stretch;
}

.widget-calendar-prev, .widget-calendar-next {
    position: relative;
    width: 1rem;
    margin-left: .5rem;
    padding: .5rem 1rem;
}

.widget-calendar-next {
    margin-left: 0;
    margin-right: .5rem;
}

.widget-calendar-prev::after, .widget-calendar-next::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    border-bottom: 3px solid #000000;
    border-right: 3px solid #000000;
    height: 1rem;
    width: 1rem;
}

.widget-calendar-prev::after {
    transform: translateY(-50%) rotate(-225deg);
}

.widget-calendar-next::after {
    transform: translateY(-50%) rotate(-45deg);
}

.widget-calendar-prev.disabled, .widget-calendar-next.disabled {
    opacity: 0;
    pointer-events: none !important;
}

.widget-calendar-control-month {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.widget-calendar-control-month *,
.widget-calendar-control-picker * {
    font-size: 1.1rem;
    font-weight: 400;
    letter-spacing: .01rem;
    color: #000000;
}

.widget-calendar-control-picker {
    padding: .25rem .5rem;
    border-radius: .25rem;
}

.widget-calendar-control-picker:hover {
    background: #EEE;
}

.widget-calendar-control-picker>div {
    pointer-events: none;
}

/* ---- Weekday ---- */
.widget-calendar-weekday {
    width: 100%;
    margin: 0 auto;
    padding: 1em 0;
}

.widget-calendar-weekday>ul {
    list-style: none;
    display: flex;
    justify-content: space-around;
    align-items: stretch;
    width: 100%;
    margin: 0 auto;
}

.widget-calendar-weekday>ul>li {
    width: 14.2857%;
    width: calc(100% / 7);
    margin: 0 auto;
    text-align: center;
    color: #939EA9;
    font-size: .95rem;
    font-weight: 400;
}

/* ---- Dates ---- */
.widget-calendar-display {
    width: 100%;
    margin: 0 auto;
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    overflow: hidden;
}

.widget-calendar-grid {
    width: 100%;
    margin: 0 auto;
    flex: 10 0 auto;
}

.widget-calendar-grid>ul {
    list-style: none;
    display: flex;
    justify-content: space-around;
    align-items: stretch;
    flex-wrap: wrap;
    width: 100%;
    margin: 0 auto;
    background-color: #FFF;
}

.widget-calendar-grid>ul>li {
    width: 14.2857%;
    width: calc(100% / 7);
    margin: 0 auto;
    text-align: center;
    color: #111111;
    margin-top: .1vh;
    margin-bottom: .1vh;
    margin-top: calc(var(--vh, .1vh));
    margin-bottom: calc(var(--vh, .1vh));
    position: relative;
}

.widget-calendar-grid>ul>li.disabled,
.widget-calendar-grid>ul>li.out-of-month {
    opacity: .3;
    cursor: not-allowed;
}

.widget-calendar-grid>ul>li.out-of-month {
    opacity: .1;
}

.widget-calendar-grid>ul>li.disabled *,
.widget-calendar-grid>ul>li.out-of-month * {
    pointer-events: none !important;
}

.widget-calendar-grid>ul>li.out-of-month.in-range,
.widget-calendar-grid>ul>li.out-of-month.in-range-start,
.widget-calendar-grid>ul>li.out-of-month.in-range-end,
.widget-calendar-grid>ul>li.disabled.in-range-start,
.widget-calendar-grid>ul>li.disabled.in-range-end {
    opacity: 1;
}

.widget-calendar-grid>ul>li.out-of-month.in-range>button>div>div>span,
.widget-calendar-grid>ul>li.out-of-month.in-range-start>button>div>div>span,
.widget-calendar-grid>ul>li.out-of-month.in-range-end>button>div>div>span {
    opacity: .3;
}

.widget-calendar-grid>ul>li>button {
    width: 80%;
    margin: 0 auto;
    position: relative;
    border-radius: 50%;
}

.widget-calendar-grid>ul>li>button::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    transition: transform .2s cubic-bezier(0.165, 0.84, 0.44, 1);
    transform: scale(0);
}

.widget-calendar-grid>ul>li.today>button::after {
    background-color: #EEE;
    transform: scale(1);
}

.widget-calendar-grid>ul>li.chosen>button::after {
    background-color: #ffb100;
    transform: scale(1);
}

.widget-calendar-grid>ul>li.in-range-start:not(.chosen)>button::after,
.widget-calendar-grid>ul>li.in-range-end:not(.chosen)>button::after {
    background-color: #F7B535;
    transform: scale(1);
}

.widget-calendar-grid>ul>li.chosen>button>div>div>span,
.widget-calendar-grid>ul>li.in-range-start>button>div>div>span,
.widget-calendar-grid>ul>li.in-range-end>button>div>div>span {
    color: #FFF;
}

.widget-calendar-grid>ul>li.in-range::after {
    background: #e1e8ea;
    content: '';
    width: 100%;
    height: 50%;
    position: absolute;
    left: 0;
    top: 0;
    transform: translateY(40%);
}

.widget-calendar-grid>ul>li.in-range:nth-of-type(7n):after,
.widget-calendar-grid>ul>li.in-range-start:nth-of-type(7n):after,
.widget-calendar-grid>ul>li.in-range-end:nth-of-type(7n):after {
    border-radius: 0 16px 16px 0;
}

.widget-calendar-grid>ul>li.in-range:nth-of-type(7n+1):after,
.widget-calendar-grid>ul>li.in-range-start:nth-of-type(7n+1):after,
.widget-calendar-grid>ul>li.in-range-end:nth-of-type(7n+1):after {
    border-radius: 16px 0 0 16px;
}

.widget-calendar-grid>ul>li.in-range-end::after {
    background: #e1e8ea;
    content: '';
    width: 50%;
    height: 50%;
    position: absolute;
    left: 0;
    top: 0;
    transform: translateY(40%);
}

.widget-calendar-grid>ul>li.in-range-start::after {
    background: #e1e8ea;
    content: '';
    width: 50%;
    height: 50%;
    position: absolute;
    right: 0;
    top: 0;
    transform: translateY(40%);
}

.widget-calendar-grid>ul>li.in-range-end>button,
.widget-calendar-grid>ul>li.in-range-start>button {
    z-index: 10;
}

.widget-calendar-grid>ul>li>button>div {
    display: block;
    width: 100%;
    height: auto;
    position: relative;
    overflow: hidden;
    padding: 100% 0 0 0;
    margin: 0 auto;
    z-index: 1;
}

.widget-calendar-grid>ul>li>button>div>div {
    display: block;
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
}

.widget-calendar-grid>ul>li>button>div>div>span {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 16px;
    font-weight: 400;
    letter-spacing: .015rem;
    color: #111111;
}

/* ---- Year Month Select ---- */
.widget-calendar .widget-calendar-months,
.widget-calendar .widget-calendar-years {
    padding: 1em;
}

.widget-calendar .widget-calendar-months>ul,
.widget-calendar .widget-calendar-years>ul {
    position: relative;
    display: flex;
    width: 100%;
    flex-wrap: wrap;
    justify-content: flex-start;
    overflow-y: auto;
    overflow-x: hidden;
    max-height: 250px;
}

.widget-calendar .widget-calendar-years>ul>li {
    width: 25%;
}

.widget-calendar .widget-calendar-months>ul>li {
    width: 33.33%;
    width: calc(100% / 3);
}

.widget-calendar .widget-calendar-months>ul>li>button,
.widget-calendar .widget-calendar-years>ul>li>button {
    text-align: center;
    width: 100%;
    padding: .8em;
    border-radius: 5px;
    font-weight: 500;
    font-size: .95rem;
}

.widget-calendar .widget-calendar-months>ul>li>button:hover,
.widget-calendar .widget-calendar-years>ul>li>button:hover {
    background: #EEE;
}

.widget-calendar .widget-calendar-months>ul>li.chosen>button,
.widget-calendar .widget-calendar-years>ul>li.chosen>button {
    background: #ffb100;
}
.widget-calendar .widget-calendar-months>ul>li.disabled>button,
.widget-calendar .widget-calendar-years>ul>li.disabled>button {
    color: #c1c1c1;
    pointer-events: none;
}



@media(min-aspect-ratio: 5/4) and (max-height:560px) {
    .widget-calendar .widget-calendar-main {
        width: 50%;
    }
}

@media(max-aspect-ratio: 4/5) {
    .widget-calendar .widget-calendar-main {
        width: 100%;
    }
}

@media (max-width: 600px) {

    .widget-calendar .widget-calendar-years>ul>li {
        width: 33.333%;
        width: calc(100% / 3);
    }

    .widget-calendar .widget-calendar-months>ul>li {
        width: 50%;
    }

    .widget-calendar .widget-calendar-months>ul>li>button,
    .widget-calendar .widget-calendar-years>ul>li>button {
        padding: .5em;
        font-size: .875rem;
    }

    .widget-calendar-control-month *, .widget-calendar-control-picker * {
        font-size: .9rem;
    }

    .widget-calendar-next, .widget-calendar-prev {
        width: .8rem;
    }

    .widget-calendar-next::after, .widget-calendar-prev::after {
        height: .8rem;
        width: .8rem;
    }

    .widget-calendar-weekday>ul>li {
        font-size: .75rem;
    }

    .widget-calendar-grid>ul>li>button>div>div>span {
        font-size: 12px;
    }
}

@media (max-width: 400px) {

    .widget-calendar .widget-calendar-months>ul>li,
    .widget-calendar .widget-calendar-years>ul>li {
        width: 50%;
    }

    .widget-calendar .widget-calendar-months>ul>li>button,
    .widget-calendar .widget-calendar-years>ul>li>button {
        font-size: .75rem;
    }
}

/* smartphones, touchscreens */

@media (hover: none) and (pointer: coarse) {}

/* mouse, touch pad */

@media (hover: hover) and (pointer: fine) {
    .widget-calendar:not(.dotbar-enabled) .widget-calendar-grid>ul>li:not(.disabled)>button:hover {
        border: 1px solid rgba(0, 0, 0, 0.2);
    }
}