.mtc-date-popover {
  position: fixed;
  z-index: 100000;
  box-sizing: border-box;
  width: 336px;
  max-width: calc(100vw - 24px);
  padding: 12px;
  border: 1px solid #e2e8ef;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 18px 40px rgba(11, 31, 58, .16);
  color: #001b44;
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.mtc-date-popover[hidden] {
  display: none !important;
}

.mtc-date-top {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) 96px 32px;
  gap: 5px;
  align-items: center;
  margin-bottom: 10px;
}

.mtc-date-arrow,
.mtc-date-month,
.mtc-date-year,
.mtc-date-clear,
.mtc-date-done {
  height: 32px;
  border: 1px solid #e2e8ef;
  border-radius: 8px;
  background: #fff;
  color: #001b44;
  font: inherit;
  font-size: 14px;
  line-height: 1;
}

.mtc-date-arrow {
  display: grid;
  place-items: center;
  padding: 0;
  cursor: pointer;
}

.mtc-date-month,
.mtc-date-year {
  width: 100%;
  min-width: 0;
  padding: 0 24px 0 8px;
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, #8593a5 50%),
    linear-gradient(135deg, #8593a5 50%, transparent 50%);
  background-position:
    calc(100% - 15px) 13px,
    calc(100% - 10px) 13px;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  cursor: pointer;
  font-size: 14px;
}

.mtc-date-week,
.mtc-date-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px 6px;
}

.mtc-date-week {
  margin-bottom: 7px;
  color: #8593a5;
  font-size: 11px;
  font-weight: 800;
  text-align: center;
}

.mtc-date-day {
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  justify-self: center;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: #001b44;
  font: inherit;
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
}

.mtc-date-day:hover:not(:disabled):not(.is-selected),
.mtc-date-arrow:hover,
.mtc-date-clear:hover,
.mtc-date-done:hover {
  background: #f4f7fb;
}

.mtc-date-day.is-selected {
  background: #0ea885;
  color: #fff;
  font-weight: 800;
}

.mtc-date-day.is-today:not(.is-selected) {
  box-shadow: inset 0 0 0 1px #cbd5e1;
}

.mtc-date-day:disabled {
  color: #c8d1dc;
  cursor: not-allowed;
}

.mtc-date-day.is-empty {
  visibility: hidden;
}

.mtc-date-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin-top: 10px;
  padding-top: 9px;
  border-top: 1px solid #edf1f5;
}

.mtc-date-clear,
.mtc-date-done {
  width: 100%;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

body.mtc-profile-builder #view2 [data-mtc-date-picker],
.details-editor-page [data-mtc-date-picker],
.ed-input[data-mtc-date-picker] {
  padding-right: 42px;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--mtcd-navy-40, #8593a5) 50%),
    linear-gradient(135deg, var(--mtcd-navy-40, #8593a5) 50%, transparent 50%);
  background-position:
    calc(100% - 22px) 50%,
    calc(100% - 15px) 50%;
  background-size: 8px 8px, 8px 8px;
  background-repeat: no-repeat;
}

@media (min-width: 761px) and (max-width: 1199px) {
  .mtc-date-popover {
    width: 368px;
    padding: 14px;
    border-radius: 14px;
  }

  .mtc-date-top {
    grid-template-columns: 36px minmax(0, 1fr) 108px 36px;
    gap: 6px;
    margin-bottom: 12px;
  }

  .mtc-date-arrow,
  .mtc-date-month,
  .mtc-date-year,
  .mtc-date-clear,
  .mtc-date-done {
    height: 36px;
    font-size: 16px;
  }

  .mtc-date-month,
  .mtc-date-year {
    padding-right: 28px;
  }

  .mtc-date-week {
    margin-bottom: 8px;
    font-size: 12px;
  }

  .mtc-date-grid {
    gap: 5px 7px;
  }

  .mtc-date-day {
    width: 30px;
    height: 30px;
    font-size: 16px;
  }

  .mtc-date-actions {
    gap: 8px;
    margin-top: 12px;
    padding-top: 10px;
  }
}

@media (max-width: 760px) {
  .mtc-date-popover {
    width: calc(100vw - 24px);
    max-width: 404px;
    padding: 15px;
    border-radius: 16px;
  }

  .mtc-date-top {
    grid-template-columns: 38px minmax(0, 1fr) 104px 38px;
    gap: 7px;
    margin-bottom: 13px;
  }

  .mtc-date-month,
  .mtc-date-year,
  .mtc-date-arrow,
  .mtc-date-clear,
  .mtc-date-done {
    height: 38px;
    font-size: 16px;
  }

  .mtc-date-week {
    margin-bottom: 8px;
    font-size: 13px;
  }

  .mtc-date-grid {
    gap: 6px 6px;
  }

  .mtc-date-day {
    width: 32px;
    height: 32px;
    font-size: 16px;
  }

  .mtc-date-actions {
    gap: 8px;
    margin-top: 12px;
    padding-top: 10px;
  }

  .mtc-date-clear,
  .mtc-date-done {
    font-size: 16px;
  }
}
