/* Account forms share the request form's controls, type scale and actions. */
body.shg-site.account-page {
  --account-form-width: 560px;
}

body.shg-site.account-page :is(.account-entry__inner, .account-profile-layout) {
  max-width: var(--account-form-width);
}

body.shg-site.account-page :is(.account-form, .account-profile-form) {
  min-width: 0;
  gap: 8px;
}

body.shg-site.account-page :is(.account-form, .account-profile-form) label {
  color: var(--ds-body);
  font: 400 var(--ds-meta-size)/1.5 var(--ds-font-text);
}

body.shg-site.account-page .account-profile-form label {
  margin-top: 16px;
}

body.shg-site.account-page .account-profile-form label:first-child {
  margin-top: 0;
}

body.shg-site.account-page .account-profile-form__field {
  min-width: 0;
  gap: 8px;
  margin-top: 16px;
}

body.shg-site.account-page :is(.account-form, .account-profile-form)
  :is(input:not([type="checkbox"]):not([type="hidden"]), textarea, select) {
  width: 100%;
  min-width: 0;
  min-height: var(--ds-control-height);
  height: var(--ds-control-height);
  padding: 12px 0;
  border: 0;
  border-bottom: 1px solid var(--ds-line);
  border-radius: 0;
  background: transparent;
  color: var(--ds-ink);
  caret-color: var(--ds-ink);
  box-shadow: none;
  font: 400 var(--ds-ui-size)/1.5 var(--ds-font-text);
}

body.shg-site.account-page .account-form input[name="code"] {
  max-width: none;
  font-variant-numeric: tabular-nums;
}

body.shg-site.account-page :is(.account-form, .account-profile-form)
  :is(input:not([type="checkbox"]):not([type="hidden"]), textarea)::placeholder {
  color: var(--ds-muted);
  opacity: 1;
}

body.shg-site.account-page :is(.account-form, .account-profile-form)
  :is(input:not([type="checkbox"]):not([type="hidden"]), textarea, select):focus {
  border-bottom: 2px solid var(--ds-ink);
  outline: none;
}

body.shg-site.account-page :is(.account-form, .account-profile-form)
  :is(input:not([type="checkbox"]):not([type="hidden"]), textarea, select):focus-visible {
  outline: 2px solid var(--ds-ink);
  outline-offset: 4px;
}

body.shg-site.account-page :is(.account-form, .account-profile-form)
  :is(input:not([type="checkbox"]):not([type="hidden"]), textarea, select)[aria-invalid="true"] {
  border-bottom-color: var(--ds-error);
}

body.shg-site.account-page :is(.account-form, .account-profile-form)
  input[readonly]:not([type="checkbox"]):not([type="hidden"]) {
  background: transparent;
  color: var(--ds-muted);
  -webkit-text-fill-color: var(--ds-muted);
}

body.shg-site.account-page :is(.account-form, .account-profile-form)
  input:not([type="checkbox"]):-webkit-autofill {
  -webkit-text-fill-color: var(--ds-ink);
  -webkit-box-shadow: 0 0 0 1000px var(--ds-paper) inset;
  caret-color: var(--ds-ink);
}

body.shg-site.account-page :is(.account-form, .account-profile-form) .btn[type="submit"] {
  --btn-bg: transparent;
  --btn-fg: var(--ds-ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-width: 0;
  min-height: var(--ds-button-height);
  height: auto;
  margin-top: 24px;
  padding: 14px 28px;
  border: 0;
  border-radius: 0;
  background: var(--btn-bg);
  color: var(--btn-fg);
  box-shadow: inset 0 0 0 1px var(--ds-ink);
  font: 400 var(--ds-ui-size)/1.5 var(--ds-font-text);
  cursor: pointer;
}

body.shg-site.account-page :is(.account-form, .account-profile-form) .btn[type="submit"]:not(:disabled):hover {
  --btn-bg: var(--surface);
  background: var(--btn-bg);
}

body.shg-site.account-page :is(.account-form, .account-profile-form) .btn[type="submit"]:focus-visible {
  outline: 2px solid var(--ds-ink);
  outline-offset: 4px;
}

body.shg-site.account-page :is(.account-form, .account-profile-form) .btn[type="submit"]:disabled {
  opacity: .45;
  cursor: wait;
}

body.shg-site.account-page .account-form .account-consent {
  grid-template-columns: 20px minmax(0, 1fr);
  column-gap: 12px;
}

body.shg-site.account-page .account-form .account-consent input[type="checkbox"] {
  width: 20px;
  min-width: 20px;
  height: 20px;
  min-height: 20px;
  margin-top: 2px;
  border: 0;
  background: transparent;
  box-shadow: inset 0 0 0 1px var(--ds-ink);
}

body.shg-site.account-page .account-form .account-consent input[type="checkbox"]:checked {
  background: var(--ds-ink);
  box-shadow: none;
}

body.shg-site.account-page .account-form .account-consent input[type="checkbox"][aria-invalid="true"] {
  box-shadow: inset 0 0 0 1px var(--ds-error);
}

@media (forced-colors: active) {
  body.shg-site.account-page :is(.account-form, .account-profile-form) .btn[type="submit"] {
    border: 1px solid ButtonText;
    background: Canvas;
    color: ButtonText;
    box-shadow: none;
  }

  body.shg-site.account-page .account-form .account-consent input[type="checkbox"] {
    border: 1px solid ButtonText;
    background: Canvas;
    box-shadow: none;
  }

  body.shg-site.account-page .account-form .account-consent input[type="checkbox"]:checked {
    border-color: Highlight;
    background: Highlight;
  }
}
