.month-name {
  font-size: 26px;
  color: black;
  font-weight: bold;

  text-align: center;
  align-self: center;
  width: 100%;
}

.calendar {
  flex-wrap: wrap;
  justify-content: center;
}

#year-buttons {
  margin: 10px 40px;
}

.calendar-parent {
  display: flex;
  justify-content: center;
}

.calendar .dates-parent {
  align-items: center;
  flex-flow: wrap;
  flex-direction: column;
  display: flex;
}

.calendar .date {
  background: black;
  border-right: solid 1px white;
  border-bottom: solid 1px white;
  cursor: not-allowed;
  color: white;
  width: 14.28%;
  height: 100px;
  text-align: center;
  flex-direction: column;
  justify-content: center;
}

.calendar .date.other-month {
  background: #FFF;
  cursor: default;
  color: lightgray;
  border-right: solid 1px lightgray;
  border-bottom: solid 1px lightgray;
}

.calendar .date.today {
  /* border: solid 1px darkgreen; */
  background: #AFA;
}

.calendar .date-info {
  text-align: left;
  padding: 3px;
  flex-grow: 1;
  position: relative;
}

.calendar .date-number {
  flex-grow: 1;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.calendar .date-day {
  font-size: 10px;
}

.calendar .date-bookings {
  font-size: 12px;
  text-align: right;
  padding: 5px;
  color: #AAA;
  position: absolute;
}

.calendar .date:not(.other-month):hover {
  background: #CCC;
}

.calendar .week-right {
  justify-content: flex-end;
}

.calendar .month {
  padding: 4px;
  width: 100%;
  max-width: 1500px;
}

.calendar .week-right, .calendar .week {
  display: flex;
  flex-direction: row;
  width: 100%;
}

.calendar .week-day-names {
  display: flex;
  width: 100%;
  margin-top: 15px;
  border-top: 1px solid #e2e7e9;
  border-bottom: 1px solid #e2e7e9;
}

.calendar .week-day-names>div {
  border: solid 1px white;
  margin: 3px;
  width: 14.28%;
  height: 20px;
  color: #666;
  font-size: 16px;
  font-weight: bold;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 15px 0;
  text-transform: uppercase;
}

select[name=month] {
  width: 100%;
  margin-right: 5px;
  height: 40px;
}

select[name=year] {
  min-width: 70px;
  height: 40px;
}

.prev-month {
  width: 30px;
  height: 30px;
  cursor: pointer;
  background-image: url(../arrows/rhdr_arrow_left.png);
}

.next-month {
  width: 30px;
  height: 30px;
  cursor: pointer;
  background-image: url(../arrows/rhdr_arrow_right.png);
}

.date-info>.pretext {
  position: absolute;
  text-align: center;
  width: calc(100% - 6px);
}

.legend {
  display: flex;
  flex-flow: wrap;
  /* justify-content: center; */
  padding: 10px;
}

.legend .colour {
  display: flex;
  margin-bottom: 10px;
  margin-right: 10%;
  align-items: center;
}

.colourName {
  display: inline-block;
  vertical-align: middle;
  width: 130px;
}

.colourCube {
  width: 26px;
  height: 26px;
  margin-right: 6px;
  display: inline-block;
  vertical-align: middle;
}

@media only screen and (max-width: 1100px) {
  .date-info>.pretext {
    position: absolute;
    font-size: 10px;
  }
  .calendar .date {
    height: 60px;
  }
}

@media only screen and (max-width: 600px) {
  .calendar .date {
    height: 50px;
  }
  .flex-parent {
    flex-direction: column;
  }
  #month-selection, #event-selection {
    width: auto;
    margin: 0;
  }
}

@media only screen and (max-width: 440px) {
  .calendar .date {
    height: 30px;
  }
}

@media only screen and (min-width: 1100px) {
  .calendar .date {
    height: 100px;
  }
}