#calendar {
    color: var(--clr-05);
    height: 20rem;
}

#calendarTop {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#calendarInfo span {
    display: flex;
    align-items: center;
}

#calculatedInfo {
    display: flex;
    align-items: center;
    color: var(--clr-05);
    font-size: 0.8rem;
}

#calendarInfo {
    display: flex;
    gap: 1rem;
    font-size: 0.9rem;
}

.holiday_square,
.judicial_square,
.today_square,
.calculated_square {
    display: inline-block;
    background-color: var(--clr-holiday);
    border-radius: 4px;
    margin-right: 0.4rem;
    width: 1rem;
    height: 1rem;
}

.judicial_square {
    background-color: var(--clr-judicial);
}

.today_square {
    background-color: var(--clr-3);
}

.calculated_square {
    outline: 1px solid var(--clr-8);
    background-color: white;
    color: var(--clr-8);
    display: flex;
    justify-content: center;
    align-items: center;
}

/* YEAR */
#calendar #year {
    display: flex;
    justify-content: flex-end;

    opacity: 0.75;
    font-size: 1.15rem;
    font-weight: 700;
}

#calendar .triangle {
    width: 0;
    height: 0;
    border-top: 5px solid transparent;
    border-right: 10px solid var(--clr-05);
    border-bottom: 5px solid transparent;
    margin-right: 0.6rem;
    margin-top: 5px;
    cursor: pointer;
}

#calendar .triangle.inverted {
    border-right: none;
    border-left: 10px solid var(--clr-05);

    margin-right: 0;
    margin-left: 0.6rem;
    margin-top: 5px;
}

#calendar .triangle.inactive {
    opacity: 0;
    pointer-events: none;
}

/* MONTHS */
#calendar #months {
    display: flex;
    justify-content: space-between;
    margin-top: 1.65rem;
    border-bottom: 1px solid var(--clr-05);
    padding-bottom: 0.5rem;
}

#calendar #months span {
    cursor: pointer;
}

#calendar #months .active {
    color: var(--clr-3);
    font-weight: 700;
    text-decoration: underline;
}

/* DAYS */
#calendar #days,
#calendar #dayLabels {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr 1fr 1fr 1fr;
    justify-items: center;
    align-items: center;
    gap: 0.15rem;
    column-gap: .7rem;
}

#calendar #days span {
    width: 2.3rem;
    text-align: center;
    padding: 0.4rem;
    border-radius: 6px;
}

#calendar #dayLabels {
    font-weight: 800;
    text-transform: uppercase;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    padding-top: 0;
}

#calendar #days span.day {
    cursor: pointer;
}

#calendar #days span.day:hover {
    outline: 1px solid rgba(0, 0, 0, 0.211);
    opacity: 0.7;
}

#calendar #days span.day.today {
    font-weight: 700;
    text-decoration: underline;
}

#calendar #days span.day.holiday {
    background-color: var(--clr-holiday);
    color: white;
    font-weight: 700;
}

#calendar #days span.day.judicial {
    background-color: var(--clr-judicial);
    color: white;
}

#calendar #days span.day.calculated {
    color: var(--clr-8) !important;
    background-color: white;
    outline: 1px solid var(--clr-8);
    color: white;
}

#calendar #days span.day.calculated.finalDateCalculated {
    animation: lastDay 380ms ease-in-out 100ms forwards;
}

#calendar #days span.dateSkipped {
    background-color: var(--clr-5);
    animation: animSkippedDate 1s forwards;
}

#idCopy,
#idCalendar {
    cursor: pointer;
    padding-left: 0.8rem;
    width: 2rem;
}

.playAnimation {
    animation: bigAndThenSmall 300ms ease-in-out forwards;
}

#calcResultDate {
    display: flex;
    align-items: center;
}

#idReminderIcon {
    margin-left: 0.78rem;
    transform: scale(0.9);
    cursor: pointer;
}

#idCalendar {
    transform: scale(0.9);
}

#idCopy {
    transform: scale(0.9);
}

#calcResultDate img:hover {
    opacity: 0.5;
}

#idDownloadCalendar {
    display: block;
    position: absolute;
    right: 0;
    bottom:0;

    width: 1.5rem;
    margin-right: 1.15rem;
    margin-bottom: .25rem;
    opacity: .5;
    transition: all;
    transition-duration: 200ms;
}


#idDownloadCalendar:hover{
    opacity: 1;
}

#idDownloadCalendar img {
    width: 100%;
}

@keyframes animDate {
    0% {
        background-color: white;
    }

    30% {
        color: white;
    }

    100% {
        color: white;
        background-color: var(--clr-7);
    }
}

@keyframes animSkippedDate {
    0% {
        background-color: white;
    }

    30% {
        color: white;
    }

    100% {
        color: white;
        background-color: var(--clr-5);
    }
}

@keyframes showIn {
    0% {
    }

    100% {
        background-color: var(--clr-8);
        font-weight: 700;
    }
}

@keyframes bigAndThenSmall {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.5);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes lastDay {
    0% {
    }

    100% {
        background-color: rgb(72, 179, 50);
    }
}

/* Mobile ajusts */
/* 63.9375 == 1023px / desktop starts at 1024px */
@media (max-width: 63.9375rem) {
    #idCalcDateBtn {
        margin-top: 0rem;
        margin-bottom: -1rem;
    }

    #calendarInfo {
        display: flex;
        gap: 0.6rem;
        font-size: 0.78rem;
    }

    #idCopy {
        display: none;
    }

    #calcContentContainer {
        display: flex;
        flex-direction: column;
    }

    #calendar {
        height: 17.2rem;
    }

    #calendar #months span{
        display: flex;
        gap: .2rem;
    }

    #calendar #months span {
        font-size: 0.78rem;
    }

    #calendar #dayLabels {
        font-size: 0.78rem;
    }

    #calendarTop {
        justify-content: space-between;
        gap: 1.8rem;
        width: 100%;
    }

    #calendar #days span {
        width: 2rem;
        text-align: center;
        padding: 0.2rem;
        border-radius: 6px;
    }
}
