/* ============================================================
   irid — Course application page
   All page-specific styles are scoped to the application page.
   ============================================================ */

.apply-main {
  padding-bottom: 100px;
}

.apply-content {
  width: 100%;
  max-width: 620px;
}

.apply-header {
  margin-bottom: 45px;
}

.apply-eyebrow {
  margin-bottom: 12px !important;
  color: var(--magenta) !important;
  font-size: 13px !important;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.apply-header h1 {
  margin-bottom: 14px;
  font-size: 34px;
  line-height: 1.08;
  letter-spacing: -0.025em;
}

/*.apply-header > p:last-child {*/
/*  max-width: 540px;*/
/*  margin-bottom: 0;*/
/*}*/

.application-form {
  display: flex;
  flex-direction: column;
  gap: 58px;
}

.form-section {
  display: grid;
  gap: 28px;
}

.form-section-heading {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 12px;
  align-items: baseline;
  padding-bottom: 10px;
  border-bottom: 1px solid #dedede;
}

.form-section-number {
  margin: 0 !important;
  color: var(--light) !important;
  font-size: 12px !important;
  font-weight: 500;
  letter-spacing: 0.08em;
}

.form-section-heading h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 500;
}

.field-group {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.field-group label,
.choice-fieldset legend {
  font-family: var(--font);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.45;
  color: var(--black);
}

.field-help,
.required-note,
.form-status,
.field-error {
  margin: 0 !important;
  font-size: 12px !important;
  line-height: 1.5 !important;
  color: var(--mid) !important;
}

.field-error {
  color: #b33a3a !important;
}

.field-group input[type="text"],
.field-group input[type="email"],
.field-group textarea {
  width: 100%;
  border: 0;
  border-bottom: 1px solid var(--light);
  border-radius: 0;
  padding: 8px 0 9px;
  background: transparent;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  color: var(--black);
  outline: none;
  transition: border-color 0.2s ease;
}

.field-group textarea {
  min-height: 60px;
  resize: vertical;
}

.field-group input[type="text"]:focus,
.field-group input[type="email"]:focus,
.field-group textarea:focus {
  border-bottom-color: var(--black);
}

.field-group input:user-invalid,
.field-group textarea:user-invalid {
  border-bottom-color: #b33a3a;
}

.choice-fieldset {
  border: 0;
  padding: 0;
  margin: 0;
}

.choice-fieldset legend {
  margin-bottom: 4px;
}

.choice-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid #ececec;
  cursor: pointer;
}

.choice-row:first-of-type {
  margin-top: 10px;
  border-top: 1px solid #ececec;
}

.choice-row input[type="checkbox"],
.choice-row input[type="radio"] {
  appearance: none;
  -webkit-appearance: none;
  width: 17px;
  height: 17px;
  min-width: 17px;
  margin-top: 2px;
  border: 1px solid var(--black);
  background: transparent;
  cursor: pointer;
}

.choice-row input[type="checkbox"] {
  border-radius: 3px;
}

.choice-row input[type="radio"] {
  border-radius: 50%;
}

.choice-row input:checked {
  background: var(--black);
  box-shadow: inset 0 0 0 4px var(--white);
}

.choice-row input:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

.choice-row span {
  font-size: 14px;
  line-height: 1.45;
  font-weight: 400;
}

.course-specific-sections {
  display: flex;
  flex-direction: column;
  gap: 58px;
}

.course-section[hidden] {
  display: none;
}

.course-section.course-section-visible {
  animation: revealCourse 0.35s ease both;
}

@keyframes revealCourse {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.course-dot-purple { color: #7770d8 !important; }
.course-dot-orange { color: var(--orange) !important; }
.course-dot-cyan   { color: var(--cyan) !important; }

.form-footer {
  display: grid;
  gap: 14px;
  padding-top: 4px;
}

.application-submit {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 36px;
  width: fit-content;
  min-width: 218px;
  border: 1px solid var(--black);
  border-radius: 12px;
  padding: 15px 18px;
  background: var(--black);
  color: var(--white);
  font-family: var(--font);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.application-submit:hover {
  transform: translateY(-1px);
}

.application-submit:disabled {
  opacity: 0.5;
  cursor: wait;
  transform: none;
}

.form-status.is-success {
  color: var(--green) !important;
}

.form-status.is-error {
  color: #b33a3a !important;
}

.form-honeypot {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  white-space: nowrap !important;
}

/* Night mode ------------------------------------------------ */
body.night-mode .apply-eyebrow {
  color: var(--magenta) !important;
}

body.night-mode .form-section-heading,
body.night-mode .choice-row {
  border-color: #353553;
}

body.night-mode .field-group label,
body.night-mode .choice-fieldset legend,
body.night-mode .choice-row span {
  color: #fff;
}

body.night-mode .field-group input[type="text"],
body.night-mode .field-group input[type="email"],
body.night-mode .field-group textarea {
  color: #fff;
  border-bottom-color: #55556d;
}

body.night-mode .field-group input[type="text"]:focus,
body.night-mode .field-group input[type="email"]:focus,
body.night-mode .field-group textarea:focus {
  border-bottom-color: #fff;
}

body.night-mode .choice-row input[type="checkbox"],
body.night-mode .choice-row input[type="radio"] {
  border-color: #fff;
}

body.night-mode .choice-row input:checked {
  background: #fff;
  box-shadow: inset 0 0 0 4px #000323;
}

body.night-mode .application-submit {
  background: #fff;
  border-color: #fff;
  color: var(--black);
}

body.night-mode .field-help,
body.night-mode .required-note,
body.night-mode .form-status {
  color: #a0a0ae !important;
}

/* Mobile ---------------------------------------------------- */
@media (max-width: 1060px) {
  .apply-content {
    max-width: 620px;
    margin: 0 auto;
  }

  .apply-header {
    margin-bottom: 42px;
  }

  .apply-header h1 {
    font-size: 30px;
  }
}

@media (max-width: 560px) {
  .apply-content {
    max-width: none;
  }

  .application-form,
  .course-specific-sections {
    gap: 48px;
  }

  .form-section {
    gap: 24px;
  }

  .form-section-heading {
    grid-template-columns: 28px 1fr;
  }

  .application-submit {
    width: 100%;
  }
}

/* More compact application form */

.apply-header {
  margin-bottom: 32px;
}

.application-form {
  gap: 36px;
}

.form-section {
  gap: 18px;
}

.field-group {
  gap: 5px;
}

.course-specific-sections {
  gap: 36px;
}

.form-section-heading {
  padding-bottom: 8px;
}

.choice-fieldset legend {
  margin-bottom: 2px;
}

.choice-row {
  gap: 10px;
  padding: 7px 0;
}

.choice-row:first-of-type {
  margin-top: 6px;
}

.form-footer {
  gap: 10px;
}

.field-group input[type="text"],
.field-group input[type="email"] {
  padding: 4px 0 5px;
  font-size: 12px;
  line-height: 1.2;
}

.field-group input[type="checkbox"]{
  /*padding: 4px 10px 10px;*/
  margin-right:10px;
  
  line-height: 1.2;
}