.calendar-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin: 1.5rem 0 2rem;
    flex-wrap: wrap;
}

.current-period {
    font-weight: 600;
    color: var(--primary);
    padding: 0 0.75rem;
    white-space: nowrap;
}

.month-section {
    display: none;
}

.month-section.active {
    display: block;
}

.year-section {
    display: none;
}

.year-section.active {
    display: block;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.5rem;
    margin-top: 1rem;
}

.weekday {
    text-align: center;
    font-weight: 600;
    color: var(--gray);
    font-size: 0.9rem;
}

.calendar-controls .nav-btn {
    margin-top: unset;
    padding: 0.5rem;
}

.calendar-day {
    min-height: 64px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: white;
    padding: 0.4rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: var(--transition);
}

.calendar-day .day-number {
    text-decoration: none;
    color: var(--text);
}

.calendar-day a {
    text-decoration: none;
    display: flex;
    height: 100%;
    width: 100%;
    justify-content: space-between;
}

.calendar-day.empty {
    background: transparent;
    border: none;
}

.calendar-day:hover {
    border-color: var(--primary);
    background: var(--hover);
}

.day-number {
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
}


.day-link {
    margin-top: 0.25rem;
    font-size: 0.8rem;
    text-decoration: underline;
    font-weight: 500;
    color: var(--primary);
    align-self: flex-end;
}