/* Student-PC | Registration form: student/guardian fields, validation states, pre-approval review. */

.spc-register {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #292c30;
}

.spc-register__panel {
  background-color: #fff;
  padding: 32px 0;
  width: 100%;
  max-width: 480px;
}

.spc-register__panel--parent {
  background-color: #fff;
  padding: 32px 0;
  width: 100%;
  max-width: 480px;
}

/* Base typography: Roboto body for the form (matches Designsystemet feel) */
.spc-register__form {
  font-family: "Roboto", sans-serif;
  color: #292c30;
  font-size: 16px;
  line-height: 1.5;
}

/* Greeting acts as the page title */
.spc-register__form h4 {
  font-family: "Barlow Semi Condensed", sans-serif;
  font-weight: 600;
  font-size: 30px;
  line-height: 1.1;
  letter-spacing: -0.4px;
  color: #292c30;
  margin: 0 0 8px;
}

/* Intro text reads as a subtitle directly under the greeting title */
.spc-register__form h4 + p {
  margin: 0;
  font-family: "Roboto", sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.09px;
  color: #292c30;
}

#spc-register__name,
.spc-register__form h4 .spc-register__name {
  font-weight: 700;
}

@media screen and (max-width: 599px) {
  .spc-register__panel,
  .spc-register__panel--parent {
    width: 100%;
    border: 0;
    background-color: inherit;
    /* CAAS removes the .container gutters on mobile, so add our own */
    padding: 24px 20px;
  }

  .spc-register__form h4 {
    font-size: 32px;
  }

  .spc-register__form .spc-register__heading {
    font-size: 18px;
  }
}

.spc-register__panel input[type="text"]:disabled {
  background-color: inherit;
  color: var(--gray);
  border: none;
  padding: 0;
}

.spc-register__form .spc-register__heading {
  font-family: "Barlow Semi Condensed", sans-serif;
  font-size: 24px;
  line-height: 1.3;
  letter-spacing: -0.075px;
  color: #292c30;
  font-weight: 500;
  margin: 8px 0 24px;
}

.spc-input-group {
  display: flex;
  flex-direction: column;
  margin-bottom: 1.25rem;
  position: relative;
}

.spc-input-group > label {
  font-family: "Roboto", sans-serif;
  font-size: 14px;
  color: #70757a;
  line-height: 1.4;
  font-weight: 500;
  letter-spacing: 0.2px;
  margin-bottom: 4px;
}

.spc-input-group > input,
.spc-input-group > select {
  height: 52px;
  border: 1px solid #c9c9c9;
  border-radius: 4px;
  padding: 0 14px;
  font-family: "Roboto", sans-serif;
  font-size: 18px;
  color: #292c30;
  background-color: #fff;
  box-sizing: border-box;
}

.spc-input-group > input:focus,
.spc-input-group > select:focus {
  outline: none;
  border-color: #c9960e;
  box-shadow: 0 0 0 3px rgba(248, 185, 18, 0.25);
}

/* Read-only value in the pre-approval review: this is the data the student verifies, so make it
   the prominent element of each field (the muted label above just names it). */
.spc-register__value {
  font-family: "Roboto", sans-serif;
  font-size: 18px;
  font-weight: 500;
  line-height: 1.4;
  color: #292c30;
}

.spc-input-checkbox {
  display: flex;
  flex-direction: row;
  align-items: center;
  flex-wrap: wrap;
}

.spc-input-checkbox label p {
  margin: 0px;
}

.spc-student-information {
  font-family: "Roboto", sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: #525252;
  margin-top: 24px !important;
}

.spc-input-checkbox > label {
  margin-left: 0.7em;
  font-family: "Roboto", sans-serif;
  font-size: 16px !important;
  line-height: 1.5;
  color: #292c30;
  margin-bottom: 0;
  flex: 1;
}

.spc-submit-button {
  display: flex;
  margin-top: 8px;
}

.spc-submit-button .spc-btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 48px;
  padding: 0 18px;
  border: none;
  border-radius: 4px;
  background: var(--komplett-yellow);
  background-image: none;
  box-shadow: none;
  color: #222;
  font-family: "Roboto", sans-serif;
  font-weight: 500;
  font-size: 18px;
  letter-spacing: 0.4px;
  line-height: 1.3;
  text-transform: none;
  text-decoration: none;
  cursor: pointer;
  box-sizing: border-box;
  transition: background-color 0.15s ease-in-out;
}

.spc-submit-button .spc-btn-primary:hover {
  background: #e0a700;
  box-shadow: none;
  color: #222;
}

.spc-link {
  font-family: "Roboto", sans-serif;
  color: var(--link-color);
}

.spc-back-container {
  display: flex;
  align-items: center;
  margin-top: 1.5em;
  margin-bottom: 1em;
  font-family: "Roboto", sans-serif;
  font-size: 16px;
}

.spc-error-message-box {
  display: none;
  background-color: var(--error-container-color);
  padding: 1rem;
  margin-bottom: 1rem;
  font-size: 14px;
  align-items: center;
  border: 1px solid var(--error-color);
}

.spc-error-message-alert {
  height: 32px;
  width: 32px;
  border-radius: 50%;
  color: var(--white);
  font-size: 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  background: var(--error-color);
  margin-right: 12px;
}

.spc-error-message {
  display: none;
  color: var(--error-color);
  margin-top: 6px;
  font-size: 14px;
}

.spc-birthdate-error {
  display: none;
  color: var(--error-color);
  margin-top: 6px;
  font-size: 14px;
}

.spc-phone-number-error {
  display: none;
  color: var(--error-color);
  margin-top: 6px;
  font-size: 14px;
}

.spc-has-error > input {
  border-color: var(--error-color) !important;
}

.spc-has-date-error > input {
  border-color: var(--error-color) !important;
}

.spc-has-phone-number-error > input {
  border-color: var(--error-color) !important;
}

.spc-has-error > select {
  border-color: var(--error-color) !important;
}

.spc-input-group.spc-has-error > .spc-error-message {
  display: block;
}

.spc-input-group.spc-has-date-error > .spc-birthdate-error {
  display: block;
}

.spc-input-group.spc-has-phone-number-error > .spc-phone-number-error {
  display: block;
}

.spc-error-message-box.spc-has-error {
  display: flex;
}

.spc-info {
  position: relative;
  display: inline-block;
  width: 20px;
  height: 20px;
  margin: 0 5px;
  text-align: center;
  font: bold 14px/20px Arial;
  border-radius: 10px;
  background: #3498db;
  color: #fff;
}

.spc-info__tooltip {
  display: none;
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translate(-50%, -12px);
  background: #666;
  width: 260px;
  color: #fff;
  font-weight: normal;
  font-family: Roboto, Arial;
  z-index: 1;
  padding: 10px 20px;
  border-radius: 5px;
  box-shadow: 10px 10px 20px rgba(0, 0, 0, 0.2);
}
.spc-info__tooltip::after {
  position: absolute;
  content: "";
  display: block;
  width: 10px;
  height: 10px;
  background: #666;
  top: 100%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-45deg);
}

.spc-info:hover .spc-info__tooltip {
  display: block;
}
