/* Styles for the Register (Create New Account) page. */

.create-account-layout {
  width: 100%;
  max-width: 100%;
  min-height: calc(100vh - 4rem);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 2rem 1rem;
  overflow-y: auto;
}

.create-account-card {
  width: 100%;
  max-width: 36rem;
  background: #ffffff;
  border: 1px solid #d7c8ef;
  border-radius: 1.1rem;
  overflow: hidden;
  box-shadow: 0 1.25rem 2.7rem rgba(49, 19, 90, 0.17);
  padding: 2.5rem;
  margin: auto 0;
}

.form-header {
  margin-bottom: 2rem;
  text-align: center;
}

.form-header h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  color: #522398;
  font-weight: 700;
}

.subtitle {
  margin: 0 0 0.75rem;
  color: #61507e;
  font-size: 1rem;
  font-weight: 600;
}

.intro-text {
  margin: 0 0 0.75rem;
  color: #61507e;
  font-size: 0.9rem;
  line-height: 1.5;
}

.intro-text a {
  color: #522398;
  font-weight: 600;
}

.required-note {
  margin: 0;
  color: #522398;
  font-size: 0.8rem;
  font-weight: 700;
}

.account-form {
  display: grid;
  gap: 1.25rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-field {
  display: grid;
  gap: 0.4rem;
}

.form-field label {
  font-weight: 600;
  font-size: 0.9rem;
  color: #522398;
}

.field-hint {
  margin: 0;
  font-size: 0.78rem;
  color: #61507e;
}

.account-form input,
.account-form select {
  font: inherit;
  width: 100%;
  padding: 0.75rem 0.85rem;
  border: 1px solid #c6b3e9;
  border-radius: 0.5rem;
  background: #fff;
  font-size: 0.95rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.account-form input:focus,
.account-form select:focus {
  outline: none;
  border-color: #FFE900;
  box-shadow: 0 0 0 3px rgba(255, 233, 0, 0.2);
}

.account-form select {
  cursor: pointer;
}

.phone-field {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.5rem;
}

.phone-field__country {
  width: auto;
}

.checkbox-label,
.radio-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.9rem;
  color: #3a2660;
}

.checkbox-label input[type="checkbox"],
.radio-label input[type="radio"] {
  width: auto;
  margin: 0;
  accent-color: #522398;
  cursor: pointer;
}

.sms-disclaimer,
.consent-disclaimer {
  margin: 0.5rem 0 0;
  font-size: 0.78rem;
  color: #61507e;
  line-height: 1.5;
}

.contact-method-group {
  border: 1px solid #c6b3e9;
  border-radius: 0.5rem;
  padding: 0.75rem 1rem;
  margin: 0;
}

.contact-method-group legend {
  font-weight: 600;
  font-size: 0.9rem;
  color: #522398;
  padding: 0 0.25rem;
}

.radio-group {
  display: flex;
  gap: 1.5rem;
  margin-top: 0.5rem;
  flex-wrap: wrap;
}

.consent-disclaimer {
  margin: 0.75rem 0 0;
  font-size: 0.78rem;
  color: #61507e;
  line-height: 1.5;
  text-align: center;
}

.form-actions {
  margin-top: 1rem;
}

.submit-btn {
  width: 100%;
  border: 1px solid transparent;
  border-radius: 0.6rem;
  padding: 0.85rem 1rem;
  cursor: pointer;
  background: #FFE900;
  color: #522398;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.02em;
  transition: background-color 0.2s, opacity 0.2s;
}

.submit-btn:hover {
  background: #f5dd00;
  opacity: 0.9;
}

.submit-btn:focus-visible {
  outline: 2px solid #FFE900;
  outline-offset: 2px;
}

/* MVC helper / plugin compatibility */
.create-account-layout {
  flex: 1 0 auto;
  min-height: 0;
}

.form-field .label-required::after {
  content: " **";
}

.form-field .text-danger {
  color: #b42318;
  font-size: 0.8rem;
}

.form-field .field-validation-valid {
  display: none;
}

.control-container.has-error input,
.control-container.has-error select {
  border-color: #b42318;
}

.phone-control .intl-tel-input,
.phone-control .iti {
  display: block;
  width: 100%;
}

.modality-description {
  padding: 0.75rem 0.85rem;
  border: 1px solid #d7c8ef;
  border-radius: 0.5rem;
  background: #f8f5fd;
  color: #24103f;
  font-size: 0.9rem;
  font-weight: 600;
}

.modality-description .text-normal {
  font-weight: 400;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

@media (max-width: 640px) {
  .create-account-layout {
    padding: 0.5rem;
    align-items: flex-start;
  }

  .create-account-card {
    padding: 1.25rem;
    border-radius: 0.8rem;
  }

  .form-header {
    margin-bottom: 1.25rem;
  }

  .account-form {
    gap: 1rem;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .form-actions {
    margin-top: 0.5rem;
  }
}
