@charset "UTF-8";

/*
 * Embedded HubSpot forms (.hubspot-form).
 *
 * Matches the look of the download forms (.p-dl__form) and the contact form
 * (.p-diagnose__form) of template-journal.css. HubSpot adds no CSS of its own
 * (cssRequired is empty), so this file sets the whole look.
 */

.hubspot-form {
  /* Colour of the 必須 mark. The contact page sets its own. */
  --hubspot-form-required-color: #ffcd3a;

  /* Height kept free while the form loads, so the content below does not
     move. */
  --hubspot-form-min-height: 0;

  min-height: var(--hubspot-form-min-height);
}

.p-diagnose .hubspot-form {
  --hubspot-form-required-color: #57b2df;
}

.hubspot-form .hs-form {
  margin: 0;
}

/* A fieldset is a row of fields, such as 姓 and 名. */
.hubspot-form .hs-form fieldset {
  display: flex;
  justify-content: space-between;
  max-width: none;
  margin: 0;
  padding: 0;
  border: 0;
}

.hubspot-form .hs-form fieldset + fieldset,
.hubspot-form .hs-form .hs_submit {
  margin-top: 18px;
}

/* Hidden fields take a fieldset of their own. */
.hubspot-form .hs-form fieldset:has(> .hs-form-field[style*="display: none"]:only-child),
.hubspot-form .hs-form fieldset:has(> input[type="hidden"]:only-child) {
  display: none;
}

.hubspot-form .hs-form .hs-form-field {
  display: flex;
  flex: 0 0 100%;
  flex-wrap: wrap;
  align-content: flex-start;
  align-items: baseline;
  min-width: 0;
  line-height: 1;
}

/* The label and its help text share the first line. The input and its
   messages take a line each. */
.hubspot-form .hs-form .hs-form-field > .input,
.hubspot-form .hs-form .hs-form-field > .hs-error-msgs {
  flex: 0 0 100%;
}

.hubspot-form .hs-form .form-columns-2 .hs-form-field {
  flex-basis: 49%;
}

/* Label and its 必須 / 任意 mark. */
.hubspot-form .hs-form .hs-form-field > label {
  display: inline;
  margin-right: 5px;
  color: #333;
  font-size: 1.4rem;
  font-weight: 700;
}

.hubspot-form .hs-form .hs-form-field > label br {
  display: none;
}

.hubspot-form .hs-form .hs-form-required {
  display: inline-block;
  margin-left: 5px;
  padding: 2px 5px;
  border-radius: 8px;
  background: #fff;
  color: var(--hubspot-form-required-color);
  font-size: 0;
  font-weight: 700;
  line-height: 1;
  vertical-align: 1px;
}

.hubspot-form .hs-form .hs-form-required::before {
  content: "必須";
  font-size: 1.1rem;
}

.hubspot-form .hs-form .hs_message > label::after {
  content: "任意";
  display: inline-block;
  margin-left: 5px;
  padding: 2px 5px;
  border-radius: 8px;
  background: #c4c4c4;
  color: #000;
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1;
  vertical-align: 1px;
}

/* Help text of a field, next to the label. */
.hubspot-form .hs-form .hs-field-desc {
  display: block;
  margin: 0;
  padding: 0;
  color: #333;
  font-size: 1rem;
}

.hubspot-form .hs-form .hs-field-desc::before {
  content: "※";
}

@media (max-width: 767px) {
  .hubspot-form .hs-form .hs-field-desc {
    flex: 0 0 100%;
    margin-top: 6px;
  }
}

/* Inputs. */
.hubspot-form .hs-form .input {
  margin: 0;
}

.hubspot-form .hs-form .hs-input:not([type="checkbox"], [type="radio"]) {
  display: block;
  box-sizing: border-box;
  width: 100%;
  margin-top: 6px;
  padding: 14px;
  border: 0;
  border-radius: 8px;
  background: #fff;
  box-shadow: none;
  color: #000;
  font-size: 1.5rem;
  appearance: none;
}

.hubspot-form .hs-form .hs-input::placeholder {
  color: #999;
}

.hubspot-form .hs-form textarea.hs-input {
  height: 100px;
  resize: vertical;
}

/* Stronger than the rule of every input above, which sets the background. */
.hubspot-form .hs-form select.hs-input:not([type="checkbox"], [type="radio"]) {
  padding-right: 36px;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23333' stroke-width='2'/%3E%3C/svg%3E") no-repeat right 14px center;
}

.hubspot-form .hs-form .hs-input.invalid.error {
  box-shadow: inset 0 0 0 1px #e0245e;
}

/* Messages under a field. */
.hubspot-form .hs-form .hs-error-msgs {
  margin: 6px 0 0;
  padding: 0;
  list-style: none;
}

.hubspot-form .hs-form .hs-error-msg,
.hubspot-form .hs-form .hs-main-font-element {
  color: #e0245e;
  font-size: 1.2rem;
  font-weight: 400;
  line-height: 1.4;
}

/* The summary of the errors under the form. Each field shows its own
   message instead. */
.hubspot-form .hs-form .hs_error_rollup {
  display: none;
}

/* Consent checkbox, centred like the old form. */
.hubspot-form .hs-form .hs-fieldtype-booleancheckbox {
  text-align: center;
}

.hubspot-form .hs-form .inputs-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.hubspot-form .hs-form .hs-form-booleancheckbox-display {
  display: inline;
  color: #727272;
  font-size: 1.3rem;
  font-weight: 400;
  line-height: 1.6;
  cursor: pointer;
}

.hubspot-form .hs-form .hs-form-booleancheckbox-display a {
  color: #727272;
}

.hubspot-form .hs-form .hs-form-booleancheckbox-display input {
  position: relative;
  top: 3px;
  width: 16px;
  height: 16px;
  margin: 0 4px 0 0;
}

.hubspot-form .hs-form .hs-form-booleancheckbox-display .hs-form-required {
  display: none;
}

.hubspot-form .hs-form .hs-fieldtype-booleancheckbox .hs-error-msgs {
  text-align: center;
}

/* The reCAPTCHA badge. The notice under the button says the same as text. */
.hubspot-form .hs-form .hs_recaptcha {
  position: absolute;
  margin: 0;
  padding: 0;
  visibility: hidden;
}

/* Submit button, as .btn--shindan-submit. */
.hubspot-form .hs-form .hs_submit {
  margin-top: 20px;
}

.hubspot-form .hs-form .actions {
  margin: 0;
  padding: 0;
}

.hubspot-form .hs-form .hs-button {
  display: block;
  width: 350px;
  max-width: 100%;
  margin: auto;
  padding: 15px;
  border: 0;
  border-radius: 10px;
  background-color: #ffcd3a;
  box-shadow: 0 2px 2px rgba(0, 0, 0, 0.3);
  color: #000;
  font-family: inherit;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.6;
  text-align: center;
  white-space: normal;
  cursor: pointer;
  appearance: none;
}

.hubspot-form .hs-form .hs-button:hover {
  background-color: #e6b935;
}

@media (max-width: 767px) {
  .hubspot-form .hs-form .hs-button {
    width: 100%;
  }
}

/* The reCAPTCHA notice under the button. */
.hubspot-form-recaptcha {
  margin: 12px 0 0;
  color: #727272;
  font-size: 1.1rem;
  line-height: 1.6;
  text-align: center;
}

.hubspot-form-recaptcha a {
  color: #727272;
}
