.calendar-control {
  position: relative;
  width: 100%;
  min-width: 0;
}
.calendar-control > .calendar-value {
  position: absolute;
  top: 0;
  left: 0;
  width: 1px;
  max-width: 1px;
  height: 1px;
  min-height: 0;
  padding: 0;
  border: 0;
  opacity: 0;
  pointer-events: none;
}
.calendar-control .calendar-trigger {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
  min-width: 0;
  min-height: 43px;
  padding: 11px 12px;
  gap: 10px;
  border: 1px solid #e5e7eb;
  border-radius: 9px;
  background: #ffffff;
  color: #005176;
  font: inherit;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
}
.calendar-trigger [data-calendar-label] {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
  text-align: left;
}
.calendar-trigger > .icon {
  height: 17px;
  width: 17px;
  flex: none;
  color: #005176;
}
.calendar-trigger > .calendar-caret {
  height: 14px;
  width: 14px;
  margin-left: auto;
}
.calendar-control .calendar-trigger:hover {
  border-color: #e5e7eb;
  background: #005176;
}
.calendar-control .calendar-trigger:focus-visible,
.calendar-control .calendar-trigger[aria-expanded='true'] {
  outline: none;
  border-color: #e5e7eb;
  box-shadow: 0 0 0 3px #00517622;
}
.calendar-popup {
  display: none;
  position: fixed;
  inset: auto;
  margin: 0;
  width: 310px;
  max-width: calc(100vw - 28px);
  padding: 15px 14px 13px;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  background: #f3f4f6;
  color: #005176;
  box-shadow: 0 18px 55px #17233c12;
  font-family: Inter, 'Segoe UI', sans-serif;
  overflow: auto;
  scrollbar-width: thin;
  scrollbar-color: #005176 #005176;
  z-index: 1000;
}
.calendar-popup:popover-open,
.calendar-popup.is-open {
  display: block;
}
.calendar-popup::backdrop {
  background: transparent;
}
.calendar-heading {
  display: grid;
  grid-template-columns: 33px minmax(0, 1fr) 33px;
  align-items: center;
  gap: 7px;
  margin-bottom: 15px;
}
.calendar-popup button {
  min-height: 33px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: none;
  color: #005176;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: inherit;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
}
.calendar-popup button > .icon {
  width: 17px;
  height: 17px;
}
.calendar-popup button:hover:not(:disabled) {
  background: #00517620;
  border-color: #e5e7eb;
  color: #005176;
}
.calendar-popup button:focus-visible {
  outline: 2px solid #005176;
  outline-offset: 1px;
  background: #00517633;
}
.calendar-popup button:disabled {
  opacity: 0.28;
  cursor: not-allowed;
}
.calendar-heading .calendar-title {
  font-size: 13px;
  font-weight: 650;
  color: #005176;
  min-width: 0;
  white-space: nowrap;
}
.calendar-weekdays,
.calendar-dates {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
}
.calendar-weekdays {
  margin-bottom: 8px;
  font-size: 10px;
  font-weight: 500;
  color: #005176;
  text-align: center;
}
.calendar-weekdays span {
  padding: 6px 0;
}
.calendar-dates button {
  height: 34px;
  min-height: 34px;
  padding: 4px;
  font-size: 12px;
  line-height: 1;
  font-weight: 550;
  color: #005176;
}
.calendar-popup .selected,
.calendar-popup .selected:hover:not(:disabled) {
  background: #f3f4f6;
  border-color: #e5e7eb;
  color: #005176;
}
.calendar-dates button.today:not(.selected) {
  border-color: #e5e7eb;
  color: #005176;
  background: #00517612;
}
.calendar-blank {
  height: 34px;
}
.calendar-bottom {
  padding-top: 13px;
  margin-top: 10px;
  border-top: 1px solid #e5e7eb;
}
.calendar-bottom button {
  width: 100%;
  border: 1px solid #e5e7eb;
  background: #00517655;
  color: #005176;
  font-size: 12px;
  font-weight: 600;
  min-height: 35px;
}
.calendar-months {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  padding: 4px 0;
}
.calendar-months button {
  min-height: 40px;
  border: 1px solid #e5e7eb;
  background: #ffffff02;
  text-transform: capitalize;
  font-size: 11px;
}
.competence-field > .calendar-field {
  margin: 0;
}
.competence-field .calendar-control {
  width: 145px;
}
.competence-field .calendar-trigger {
  font-size: 11px;
  min-height: 38px;
  padding: 9px 10px;
}
.competence-field .calendar-trigger > .icon {
  width: 15px;
  height: 15px;
}
.competence-field .calendar-caret {
  width: 12px;
  height: 12px;
}
@media (max-width: 600px) {
  .calendar-popup {
    padding: 13px 11px;
    border-radius: 13px;
  }
  .calendar-dates button {
    height: 33px;
    min-height: 33px;
  }
  .calendar-heading {
    margin-bottom: 10px;
  }
  .calendar-popup .calendar-title {
    font-size: 12px;
  }
  .calendar-control .calendar-trigger {
    gap: 8px;
    padding: 11px 10px;
  }
  .competence-field .calendar-control {
    width: 145px;
  }
}
.calendar-popup button.selected:focus-visible,
.calendar-popup button.selected:focus,
.calendar-popup button.selected:hover:not(:disabled) {
  background: #f3f4f6;
  color: #005176;
  border-color: #e5e7eb;
  font-weight: 700;
  outline: 2px solid #005176;
  outline-offset: 2px;
}
