input,
textarea,
select {
  font: inherit;
  font-size: 14px !important;
}

.cm-tools {
  background: var(--bg, #fff);
  color: var(--text, #292929);
}

.cm-tools [hidden] {
  display: none !important;
}

.cm-tools .screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

body.cm-modal-open {
  overflow: hidden;
}

.cm-hero {
  padding: 132px 0 42px;
  background: var(--surface, #f6f5f3);
}

.cm-tools>.cm-hero:not(.cm-hero--form) {
  position: relative;
  overflow: hidden;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

.cm-tools>.cm-hero:not(.cm-hero--form)::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0.78) 34%, rgba(255, 255, 255, 0.28) 62%, rgba(255, 255, 255, 0.08) 100%);
  pointer-events: none;
}

.cm-tools>.cm-hero:not(.cm-hero--form) .container {
  position: relative;
  z-index: 1;
}

.cm-hero--form .container {
  position: relative;
}

.cm-hero h1 {
  max-width: 980px;
  margin: 16px 0 0;
  font-size: clamp(36px, 5vw, 66px);
  line-height: 0.98;
  font-weight: 600;
}

.cm-title-accent {
  color: var(--accent, #ee3c41);
}

.cm-text-mark {
  color: var(--accent, #ee3c41);
}

.cm-hero p,
.cm-hero__text,
.cm-hero__text p {
  max-width: 780px;
  margin: 22px 0 0;
  color: rgb(0 0 0);
  font-size: 17px;
  line-height: 1.55;
}

.cm-hero__text p:first-child {
  margin-top: 0;
}

.cm-hero__notice {
  max-width: 980px;
}

.cm-hero .attention-info,
.cm-hero__notice,
.cm-hero__notice p {
  font-size: 15px;
  margin-top: 10px;
  display: block;
  position: relative;
  line-height: 1.55;
  color: rgb(0 0 0);
}

.cm-hero--form {
  padding-bottom: 34px;
}

.cm-consultation-trigger {
  display: none;
}

.cm-section {
  padding: 54px 0 86px;
}

.cm-form-group+.cm-form-group {
  margin-top: 46px;
}

.cm-form-group__title {
  margin: 0 0 20px;
  color: var(--accent, #ee3c41);
  font-size: 32px;
  line-height: 1.1;
  font-weight: 700;
}

.cm-form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.cm-form-card {
  min-height: 300px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 24px;
  padding: 26px;
  border: 1px solid var(--line, rgba(41, 41, 41, 0.1));
  border-radius: 8px;
  background: var(--card, #fbfbfa);
}

.cm-form-card--primary {
  border-color: rgba(238, 60, 65, 0.34);
  background: linear-gradient(180deg, rgba(238, 60, 65, 0.08), rgba(255, 255, 255, 0.95));
}

.cm-form-card__meta {
  display: inline-flex;
  margin-bottom: 12px;
  color: var(--accent, #ee3c41);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.cm-form-card h2 {
  margin: 0;
  font-size: 25px;
  line-height: 1.08;
}

.cm-form-card p,
.cm-notice p,
.cm-aside-panel p,
.cm-section-description {
  margin: 14px 0 0;
  color: var(--text-soft, rgba(41, 41, 41, 0.72));
  line-height: 1.5;
}

.cm-back-link {
  display: inline-flex;
  margin-bottom: 20px;
  color: var(--accent, #ee3c41);
  font-weight: 700;
}

.cm-form-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 28px;
  align-items: start;
}

.cm-form-main,
.cm-notice,
.cm-aside-panel {
  border: 1px solid var(--line, rgba(41, 41, 41, 0.1));
  border-radius: 8px;
  background: var(--card, #fbfbfa);
}

.cm-form-main {
  overflow: hidden;
}

.cm-form-section {
  margin: 0;
  padding: 30px;
  border: 0;
  border-bottom: 1px solid var(--line, rgba(41, 41, 41, 0.1));
}

.cm-form-section:last-child {
  border-bottom: 0;
}

.cm-form-section legend {
  width: 100%;
  margin: 10px 0 15px;
  padding: 15px 0 0 0;
  padding: 0;
  color: #000000;
  font-size: 24px;
  font-weight: 100;
}

.cm-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.cm-field {
  position: relative;
  display: grid;
  gap: 9px;
}

.cm-field--textarea,
.cm-field--radio,
.cm-conditional-group,
.cm-repeater {
  grid-column: 1 / -1;
}

.cm-form-section--side-fields .cm-field--textarea {
  grid-column: auto;
}

.cm-form-section--side-fields .cm-fields {
  align-items: start;
}

.cm-conditional-group,
.cm-repeater__item {
  padding: 20px;
  border: 1px solid var(--line, rgba(41, 41, 41, 0.1));
  border-radius: 8px;
  background: #fff;
}

.cm-conditional-group--enrolment_letter_details,
.cm-conditional-group--previous_education_details {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.cm-conditional-group--previous_education_details {
  margin-top: 12px;
  padding-top: 18px;
  border-top: 1px solid var(--line, rgba(41, 41, 41, 0.1));
}

.cm-conditional-group--enrolment_letter_details h3,
.cm-conditional-group--previous_education_details h3 {
  display: none;
}

.cm-conditional-group--previous_education_details .cm-field--radio {
  grid-column: auto;
}

.cm-conditional-group--want_education_details .cm-field[data-field="user_money_to_life"],
.cm-conditional-group--want_education_details .cm-field[data-field="user_have_spouse"],
.cm-conditional-group--want_education_details .cm-field[data-field="user_have_child"] {
  grid-column: auto;
}

.cm-conditional-group--already_educated_details .cm-field[data-field="user_program_name_now"] {
  grid-column: 1 / -1;
}

.cm-conditional-group--already_educated_details .cm-field[data-field="user_study_permit"],
.cm-conditional-group--already_educated_details .cm-field[data-field="user_after_education_plan"],
.cm-conditional-group--already_educated_details .cm-field[data-field="user_pgwp_permission"],
.cm-conditional-group--already_educated_details .cm-field[data-field="user_immigrate_canada_plan"],
.cm-conditional-group--already_educated_details .cm-field[data-field="user_have_spouse2"],
.cm-conditional-group--already_educated_details .cm-field[data-field="user_have_child2"] {
  grid-column: auto;
}

@media (min-width: 641px) {

  .cm-conditional-group--want_education_details .cm-field[data-field="user_education_budget"] .cm-field__label,
  .cm-conditional-group--want_education_details .cm-field[data-field="user_money_to_life"] .cm-field__label,
  .cm-conditional-group--want_education_details .cm-field[data-field="user_have_spouse"] .cm-field__label,
  .cm-conditional-group--want_education_details .cm-field[data-field="user_have_child"] .cm-field__label {
    min-height: 52px;
  }

  .cm-conditional-group--already_educated_details .cm-field[data-field="user_study_permit"] .cm-field__label,
  .cm-conditional-group--already_educated_details .cm-field[data-field="user_after_education_plan"] .cm-field__label,
  .cm-conditional-group--already_educated_details .cm-field[data-field="user_pgwp_permission"] .cm-field__label,
  .cm-conditional-group--already_educated_details .cm-field[data-field="user_immigrate_canada_plan"] .cm-field__label,
  .cm-conditional-group--already_educated_details .cm-field[data-field="user_have_spouse2"] .cm-field__label,
  .cm-conditional-group--already_educated_details .cm-field[data-field="user_have_child2"] .cm-field__label {
    min-height: 52px;
  }
}

.cm-conditional-group h3,
.cm-repeater__head h3 {
  margin: 0 0 16px;
  font-size: 19px;
  line-height: 1.2;
}

.cm-fields--nested {
  grid-column: 1 / -1;
}

.cm-repeater {
  display: grid;
  gap: 14px;
}

.cm-repeater__head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}

.cm-link-button,
.cm-secondary-button {
  border: 0;
  background: transparent;
  color: var(--accent, #ee3c41);
  font-weight: 700;
}

.cm-secondary-button {
  width: fit-content;
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid rgba(238, 60, 65, 0.34);
  border-radius: 8px;
  background: rgba(238, 60, 65, 0.08);
}

.cm-calendar {
  position: absolute;
  z-index: 10000;
  width: 292px;
  padding: 14px;
  border: 1px solid var(--line-strong, rgba(41, 41, 41, 0.16));
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.16);
}

.cm-calendar__head {
  display: grid;
  grid-template-columns: 34px 1fr 34px;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.cm-calendar__head strong {
  text-align: center;
  font-size: 14px;
  text-transform: capitalize;
}

.cm-calendar__head button,
.cm-calendar__days button {
  min-height: 34px;
  border: 1px solid var(--line, rgba(41, 41, 41, 0.1));
  border-radius: 8px;
  background: #fff;
}

.cm-calendar__head button:hover,
.cm-calendar__days button:hover,
.cm-calendar__days button.is-active {
  border-color: rgba(238, 60, 65, 0.34);
  background: var(--accent, #ee3c41);
  color: #fff;
}

.cm-calendar__week,
.cm-calendar__days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 5px;
}

.cm-calendar__week {
  margin-bottom: 6px;
  color: var(--text-soft, rgba(41, 41, 41, 0.72));
  font-size: 12px;
  text-align: center;
}

.cm-field__label {
  font-size: 16px;
  font-weight: 100;
}

.cm-required {
  color: var(--accent, #ee3c41);
}

.cm-field input:not([type="radio"]):not([type="checkbox"]),
.cm-field select,
.cm-field textarea {
  width: 100%;
  min-height: 54px;
  padding: 0 15px;
  border: 1px solid var(--line-strong, rgba(41, 41, 41, 0.16));
  border-radius: 8px;
  background: #fff;
  color: var(--text, #292929);
}

.cm-field textarea {
  min-height: 138px;
  padding-top: 14px;
  resize: vertical;
}

.cm-radio-group {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.cm-radio-group label {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 14px;
  border: 1px solid var(--line-strong, rgba(41, 41, 41, 0.16));
  border-radius: 8px;
  background: #fff;
}

.cm-radio-group input[type="radio"],
.cm-radio-group input[type="checkbox"] {
  width: 18px;
  height: 18px;
  min-width: 18px;
  min-height: 18px;
  flex: 0 0 18px;
  margin: 0;
  padding: 0;
  accent-color: var(--accent, #ee3c41);
}

.cm-field__error {
  min-height: 18px;
  color: var(--accent, #ee3c41);
  font-size: 13px;
}

.cm-field__hint {
  margin-top: -3px;
  color: var(--text-soft, rgba(41, 41, 41, 0.72));
  font-size: 12px;
}

.cm-field--invalid input,
.cm-field--invalid select,
.cm-field--invalid textarea {
  border-color: var(--accent, #ee3c41);
}

.cm-field--pulse input,
.cm-field--pulse select,
.cm-field--pulse textarea {
  animation: cmFieldPulse 1s ease;
}

.cm-field-balloon {
  position: absolute;
  z-index: 5;
  left: 12px;
  bottom: calc(100% + 6px);
  padding: 8px 10px;
  border-radius: 8px;
  background: var(--accent, #ee3c41);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 10px 26px rgba(238, 60, 65, 0.28);
  animation: cmBalloon 1s ease forwards;
}

@keyframes cmFieldPulse {

  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(238, 60, 65, 0);
  }

  35%,
  70% {
    box-shadow: 0 0 0 4px rgba(238, 60, 65, 0.16);
  }
}

@keyframes cmBalloon {
  0% {
    opacity: 0;
    transform: translateY(4px);
  }

  15%,
  80% {
    opacity: 1;
    transform: translateY(0);
  }

  100% {
    opacity: 0;
    transform: translateY(-4px);
  }
}

.cm-form-aside {
  position: sticky;
  top: 102px;
}

.cm-form-aside .cm-aside-panel+.cm-aside-panel {
  margin-top: 18px;
}

.cm-aside-panel,
.cm-notice {
  padding: 26px;
}

.cm-aside-panel h2,
.cm-notice h2 {
  margin: 0;
  font-size: 26px;
  line-height: 1.1;
}

.cm-aside-panel--consultation h2 {
  font-size: 22px;
}

.cm-aside-panel .compound-button {
  width: 100%;
  margin-top: 24px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--text, #292929);
}

.cm-aside-panel .compound-button.red {
  background: var(--accent, #ee3c41);
}

.cm-aside-panel .compound-button__label {
  flex: 1;
}

.cm-aside-panel--consultation .compound-button__label {
  white-space: normal;
  line-height: 1.2;
}

.cm-aside-panel .compound-button__label,
.cm-aside-panel .compound-button__icon {
  border-radius: 0;
  background: transparent;
}

.cm-aside-panel .compound-button:hover {
  background: var(--accent, #ee3c41);
}

.cm-aside-panel .compound-button.red:hover {
  background: var(--text, #292929) !important;
}

.cm-aside-panel .compound-button:hover .compound-button__label,
.cm-aside-panel .compound-button:hover .compound-button__icon {
  background: transparent;
}

.cm-form-message {
  margin-top: 18px;
  padding: 14px;
  border-radius: 8px;
  display: none;
  line-height: 1.4;
}

.cm-form-message[data-state] {
  display: block;
}

.cm-form-message[data-state="success"] {
  background: rgba(43, 146, 83, 0.12);
  color: #1f6f3d;
}

.cm-form-message[data-state="error"] {
  background: rgba(238, 60, 65, 0.12);
  color: #b3282d;
}

.cm-form-message[data-state="pending"] {
  background: var(--surface-2, #f0efec);
}

.cm-consultation-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
}

.cm-consultation-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.42);
}

.cm-consultation-modal__dialog {
  position: relative;
  width: min(520px, calc(100vw - 34px));
  margin: 12vh auto 0;
  padding: 28px;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 24px 72px rgba(0, 0, 0, 0.22);
}

.cm-consultation-modal__dialog h2 {
  margin: 0 36px 16px 0;
  color: var(--accent, #ee3c41);
  font-size: 25px;
  line-height: 1.16;
}

.cm-consultation-modal__dialog p {
  margin: 0 0 14px;
  font-size: 16px;
  line-height: 1.48;
}

.cm-consultation-modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 999px;
  background: rgba(41, 41, 41, 0.06);
  color: var(--text, #292929);
  font-size: 26px;
  line-height: 1;
}

.cm-consultation-modal .compound-button {
  width: 100%;
  margin-top: 18px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--text, #292929);
}

.cm-consultation-modal .compound-button__label {
  flex: 1;
  white-space: normal;
  line-height: 1.2;
}

.cm-consultation-modal .compound-button__label,
.cm-consultation-modal .compound-button__icon {
  border-radius: 0;
  background: transparent;
}

.cm-consultation-modal .compound-button:hover {
  background: var(--accent, #ee3c41);
}

.cm-hp {
  position: absolute;
  left: -9999px;
  opacity: 0;
  pointer-events: none;
}

@media (max-width: 980px) {

  .cm-form-grid,
  .cm-form-shell {
    grid-template-columns: 1fr;
  }

  .cm-form-aside {
    position: static;
  }
}

@media (max-width: 640px) {
  .cm-hero {
    padding-top: 106px;
  }

  .cm-hero--form {
    padding-bottom: 56px;
  }

  .cm-consultation-trigger {
    position: absolute;
    right: 18px;
    bottom: -95px;
    z-index: 2;
    display: inline-grid;
    width: 78px;
    height: 78px;
    place-items: center;
    border: 4px solid #ee3c4173;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.45);
    color: #ee3c4173;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  }

  .cm-consultation-trigger.is-fixed {
    position: fixed;
    top: var(--cm-consultation-fixed-top, 112px);
    right: 18px;
    bottom: auto;
    z-index: 99990;
  }

  .cm-consultation-trigger span[aria-hidden="true"] {
    font-size: 46px;
    line-height: 1;
    font-weight: 600;
  }

  .cm-aside-panel--consultation {
    display: none;
  }

  .cm-fields {
    grid-template-columns: 1fr;
  }

  .cm-form-section,
  .cm-aside-panel,
  .cm-notice,
  .cm-form-card {
    padding: 20px;
  }

  .cm-consultation-modal__dialog {
    margin-top: 10vh;
    padding: 24px 22px;
  }
}