:root {
  --blue: #302f82;
  --gold: #b09655;
  --text: #303043;
  --muted: #5f6070;
  --field: #f1f1f2;
  --page-width: 840px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: #fff;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 16px;
  line-height: 1.5;
}

.page {
  width: min(var(--page-width), calc(100% - 48px));
  margin: 0 auto;
  padding: 42px 0 48px;
}

.intro {
  text-align: left;
}

.intro-hero {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
  width: clamp(250px, 34vw, 300px);
  margin: 0 auto 29px;
}

.graduate-window {
  width: min(430px, 55%);
  margin: 0;
  background: #fff;
}

.graduate-window img {
  width: 100%;
  max-width: 100%;
  height: auto;
  display: block;
}

.yes-word {
  flex: 0 0 auto;
  color: var(--blue);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(55px, 7vw, 78px);
  font-weight: 700;
  line-height: .9;
  text-shadow: 4px 5px 2px rgba(52, 52, 70, .3);
  white-space: nowrap;
}

.intro-copy {
  margin: 0;
  color: var(--blue);
  font-size: clamp(22px, 3.25vw, 34px);
  line-height: 1.28;
}

.intro-copy strong {
  font-weight: 700;
}

.service-heading {
  margin: 54px 0 24px;
  color: var(--gold);
  font-size: clamp(24px, 3vw, 31px);
  line-height: 1.25;
}

.service-list {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 25px;
  padding: 0 8px 13px;
}

.service-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.service-row span {
  flex: 0 1 auto;
  padding: 2px 12px 4px;
  color: #cfcb00;
  background: linear-gradient(90deg, #fff 0%, #d8d4e6 38%, #312379 100%);
  font-size: clamp(17px, 2.5vw, 26px);
  line-height: 1.2;
  text-align: center;
  white-space: nowrap;
}

.service-row:nth-child(1) span:first-child,
.service-row:nth-child(2) span:last-child,
.service-row:nth-child(3) span:nth-child(2) {
  min-width: 150px;
}

.service-row:nth-child(1) span:nth-child(2),
.service-row:nth-child(1) span:nth-child(3),
.service-row:nth-child(2) span:first-child,
.service-row:nth-child(2) span:nth-child(2),
.service-row:nth-child(3) span:first-child,
.service-row:nth-child(3) span:last-child {
  min-width: 215px;
}

.compact-row {
  justify-content: space-around;
}

.compact-row span {
  min-width: 110px;
}

.divider {
  height: 1px;
  margin: 60px 0 27px;
  background: #686868;
}

.contact-section h1 {
  margin: 0;
  color: #36363b;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(50px, 8vw, 74px);
  font-style: italic;
  font-weight: 400;
  line-height: 1.1;
  text-align: center;
}

.contact-subtitle {
  margin: 34px 0 18px;
  color: var(--text);
  font-size: clamp(20px, 2.8vw, 27px);
  line-height: 1.3;
}

.form-card {
  padding: 31px 31px 29px;
  background: var(--field);
}

form label {
  display: block;
  margin-bottom: 22px;
  color: #545568;
  font-size: 16px;
  line-height: 1.35;
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

input,
select,
textarea {
  width: 100%;
  margin-top: 10px;
  padding: 15px 16px;
  border: 0;
  border-radius: 6px;
  outline: 0;
  color: var(--text);
  background: #fff;
  font: inherit;
  font-size: 17px;
}

input,
select {
  min-height: 54px;
}

textarea {
  min-height: 132px;
  resize: vertical;
}

input::placeholder,
textarea::placeholder,
select:invalid {
  color: #bdc0c8;
}

input:focus,
select:focus,
textarea:focus {
  box-shadow: 0 0 0 2px rgba(48, 47, 130, .35);
}

input[aria-invalid="true"] {
  box-shadow: 0 0 0 2px rgba(180, 50, 50, .55);
}

.field-error {
  display: block;
  margin-top: 7px;
  color: #a73535;
  font-size: 13px;
  line-height: 1.35;
}

.field-error[hidden] {
  display: none;
}

select {
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, #50548e 50%),
    linear-gradient(135deg, #50548e 50%, transparent 50%);
  background-position:
    calc(100% - 24px) 23px,
    calc(100% - 18px) 23px;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

.phone-input {
  position: relative;
  display: flex;
  align-items: center;
  margin-top: 10px;
  min-height: 54px;
  border-radius: 6px;
  background: #fff;
}

.phone-input input {
  min-height: 54px;
  margin: 0;
  padding-left: 6px;
}

.flag {
  position: relative;
  display: inline-block;
  width: 24px;
  height: 16px;
  margin-left: 16px;
  overflow: hidden;
  border-radius: 1px;
  background: repeating-linear-gradient(
    to bottom,
    #b22234 0,
    #b22234 1.23px,
    #fff 1.23px,
    #fff 2.46px
  );
  font-size: 0;
  line-height: 1;
}

.flag::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 10px;
  height: 8.6px;
  background: #3c3b6e;
}

.country-code {
  color: #8d8fa0;
  font-size: 16px;
  white-space: nowrap;
}

.country-selector {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  height: 54px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font: inherit;
}

.country-selector:focus-visible {
  outline: 2px solid rgba(48, 47, 130, .35);
  outline-offset: -2px;
}

.country-selector .flag {
  position: relative;
  display: inline-block;
  width: 24px;
  height: 16px;
  margin-left: 16px;
  overflow: hidden;
  border-radius: 1px;
  background: repeating-linear-gradient(
    to bottom,
    #b22234 0,
    #b22234 1.23px,
    #fff 1.23px,
    #fff 2.46px
  );
  font-size: 0;
  line-height: 1;
}

.country-selector .flag::before {
  display: block;
  top: 0;
  left: 0;
  width: 10px;
  height: 8.6px;
  background: #3c3b6e;
}

.country-selector[data-country="CA"] .flag {
  background: linear-gradient(to right, #d80621 0 25%, #fff 25% 75%, #d80621 75%);
}

.country-selector[data-country="GB"] .flag {
  background:
    linear-gradient(25deg, transparent 43%, #fff 43% 49%, #c8102e 49% 53%, #fff 53% 59%, transparent 59%),
    linear-gradient(-25deg, transparent 43%, #fff 43% 49%, #c8102e 49% 53%, #fff 53% 59%, transparent 59%),
    linear-gradient(to right, transparent 40%, #fff 40% 60%, transparent 60%),
    linear-gradient(to bottom, transparent 34%, #fff 34% 66%, transparent 66%),
    #012169;
}

.country-selector[data-country="AU"] .flag {
  background: #012169;
}

.country-selector[data-country="DE"] .flag {
  background: linear-gradient(to bottom, #000 0 33%, #dd0000 33% 66%, #ffce00 66%);
}

.country-selector[data-country="FR"] .flag {
  background: linear-gradient(to right, #0055a4 0 33%, #fff 33% 66%, #ef4135 66%);
}

.country-selector[data-country="CN"] .flag {
  background: #de2910;
}

.country-selector[data-country="IN"] .flag {
  background: linear-gradient(to bottom, #ff9933 0 33%, #fff 33% 66%, #138808 66%);
}

.country-selector[data-country="CA"] .flag::before,
.country-selector[data-country="GB"] .flag::before,
.country-selector[data-country="AU"] .flag::before,
.country-selector[data-country="DE"] .flag::before,
.country-selector[data-country="FR"] .flag::before,
.country-selector[data-country="CN"] .flag::before,
.country-selector[data-country="IN"] .flag::before {
  display: none;
}

.country-selector[aria-expanded="true"] .phone-arrow {
  top: 2px;
  transform: rotate(225deg);
}

.phone-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 9px;
  height: 9px;
  margin: 0 12px 0 5px;
  border-right: 1.5px solid #5d6093;
  border-bottom: 1.5px solid #5d6093;
  position: relative;
  top: -2px;
  transform: rotate(45deg);
  font-size: 0;
}

.country-menu {
  position: absolute;
  top: calc(100% + 5px);
  left: 0;
  z-index: 20;
  width: 250px;
  max-height: 320px;
  padding: 6px 0;
  border: 1px solid #d7d8e0;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(35, 35, 70, .16);
  overflow-y: auto;
}

.country-option {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 42px;
  margin: 0;
  padding: 8px 14px;
  border: 0;
  background: #fff;
  color: #444761;
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.country-option:hover,
.country-option[aria-selected="true"] {
  background: #f1f1f7;
}

.country-option .flag {
  width: auto;
  height: auto;
  margin: 0 10px 0 0;
  overflow: visible;
  background: none;
  font-size: 20px;
}

.country-option .flag::before {
  display: none;
}

.country-option .country-code {
  min-width: 38px;
  color: #656982;
}

.country-name {
  margin-left: 8px;
  color: #4a4d66;
  font-size: 15px;
}

.consent {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  color: #777985;
  font-size: 12px;
}

.consent input {
  width: 16px;
  min-height: 16px;
  flex: 0 0 16px;
  margin: 2px 0 0;
  accent-color: var(--blue);
}

form button {
  width: 100%;
  min-height: 55px;
  margin-top: 2px;
  border: 0;
  color: #fff;
  background: var(--blue);
  cursor: pointer;
  font-size: 17px;
  transition: background .2s ease, transform .2s ease;
}

form button:hover {
  background: #242365;
  transform: translateY(-1px);
}

form button:disabled {
  cursor: default;
  opacity: .8;
  transform: none;
}

.country-selector {
  width: auto;
  min-height: 54px;
  margin-top: 0;
  color: inherit;
  background: transparent;
  font-size: inherit;
  transition: none;
}

.country-selector:hover {
  background: transparent;
  transform: none;
}

.country-option {
  width: 100%;
  min-height: 42px;
  margin-top: 0;
  color: #444761;
  background: #fff;
  font-size: 16px;
  text-align: left;
  transition: background .15s ease;
}

.country-option:hover {
  background: #f1f1f7;
  transform: none;
}

.form-note {
  margin: 11px 0 0;
  color: #898a91;
  font-size: 11px;
  text-align: center;
}

.success-message {
  margin-top: 16px;
  padding: 13px;
  color: #326243;
  background: #e1efe4;
  font-size: 14px;
  text-align: center;
}

.legal-note {
  margin: 22px auto 0;
  color: #8b8b94;
  font-size: 11px;
  line-height: 1.5;
  text-align: center;
}

@media (max-width: 720px) {
  .page {
    width: min(100% - 32px, var(--page-width));
    padding-top: 26px;
  }

  .intro-hero {
    width: min(100%, 300px);
    gap: 10px;
    margin-bottom: 24px;
  }

  .graduate-window {
    width: 58%;
  }

  .graduate-window img {
    width: 100%;
  }

  .yes-word {
    font-size: clamp(60px, 18vw, 100px);
  }

  .service-list {
    justify-content: center;
    gap: 14px 12px;
    padding: 0 0 8px;
  }

  .service-row {
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px 12px;
  }

  .service-row span,
  .service-row span:nth-child(n) {
    min-width: 0 !important;
    flex: 0 1 auto;
    font-size: 17px;
  }

  .divider {
    margin-top: 42px;
  }

  .form-card {
    padding: 24px 18px 22px;
  }

  .field-row {
    grid-template-columns: 1fr;
    gap: 0;
  }
}

@media (max-width: 420px) {
  .graduate-window {
    width: 58%;
  }

  .graduate-window img {
    width: 100%;
  }

  .yes-word {
    font-size: clamp(52px, 16vw, 82px);
  }

  .intro-copy {
    font-size: 21px;
  }

  .service-heading {
    margin-top: 38px;
    font-size: 23px;
  }

  .service-row span,
  .service-row span:nth-child(n) {
    font-size: 15px;
  }

  .contact-subtitle {
    margin-top: 24px;
    font-size: 18px;
  }

  form label {
    font-size: 14px;
  }

  input,
  select,
  textarea {
    font-size: 15px;
  }
}
