/* Page layout with background image support (like assessments) */
.aa-forms-page {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background-color: #f6f7f7; /* fallback only; no hardcoded image */
}

.aa-forms-inner {
  max-width: 720px;
  width: 100%;
  background: rgba(255,255,255,.96);
  border-radius: 14px;
  box-shadow: 0 8px 32px rgba(0,0,0,.08);
  padding: 24px;
}

.aa-forms-title {
  text-align: center;
  margin: 0 0 1.5rem;
  font-size: 1.8rem;
}

/* Scope everything to the wrapper so theme styles don't leak in */
.aa-forms-wrapper,
.aa-forms-wrapper * {
  box-sizing: border-box;
}

.aa-forms-wrapper {
  max-width: 100%;
  margin: 0;
  padding: 0;
}

.aa-forms-wrapper .aa-forms-form {
  margin: 0;
}

/* Reset common theme margins inside forms */
.aa-forms-wrapper p,
.aa-forms-wrapper label {
  margin: 0 0 8px;
}

/* Labels */
.aa-forms-wrapper label {
  display: block;
  line-height: 1.3;
  margin-bottom: 1em;
}

.aa-forms-wrapper .aa-required {
  color: #b30000;
}

/* Text-like inputs */
.aa-forms-wrapper input[type="text"],
.aa-forms-wrapper input[type="email"],
.aa-forms-wrapper input[type="url"],
.aa-forms-wrapper input[type="tel"],
.aa-forms-wrapper input[type="number"],
.aa-forms-wrapper input[type="search"],
.aa-forms-wrapper textarea,
.aa-forms-wrapper select {
  display: block;
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  background: #fff;
  line-height: 1.4;
  outline: none;
}

/* Focus state */
.aa-forms-wrapper input:focus,
.aa-forms-wrapper textarea:focus,
.aa-forms-wrapper select:focus {
  border-color: #aaa;
  box-shadow: 0 0 0 2px rgba(0,0,0,.05);
}

/* Spacing between fields */
.aa-forms-wrapper .aa-field,
.aa-forms-wrapper .form-row,
.aa-forms-wrapper .form-group,
.aa-forms-wrapper p + p {
  margin-top: 16px;
}

/* Checkbox and radio groups */
.aa-forms-wrapper .choices,
.aa-forms-wrapper .checkbox-group,
.aa-forms-wrapper .radio-group {
  margin: 8px 0 30px;
  padding: 0;
  list-style: none;
}

.aa-forms-wrapper .choices li,
.aa-forms-wrapper .checkbox-group li,
.aa-forms-wrapper .radio-group li {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 6px 0;
}

/* Checkbox & radio overrides */
.aa-forms-wrapper input[type="checkbox"],
.aa-forms-wrapper input[type="radio"] {
  width: auto;             /* stop full width */
  height: auto;
  margin: 0 0.5rem 0 0;
  display: inline-block;
  vertical-align: middle;
}

/* Labels that wrap inputs inline */
.aa-forms-wrapper label input[type="checkbox"],
.aa-forms-wrapper label input[type="radio"] {
  margin-right: 0.5rem;
}

.aa-field label, div.label {
    margin-bottom: 0.8em;
    font-weight: 600;
    font-size: 1.2em;
}

.aa-forms-wrapper .checkbox-group label,
.aa-forms-wrapper .radio-group label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0.25rem 0;
  font-size: 1em;
  font-weight: 400;
}
ul.checkbox-group li, ul.radio-group li {
    list-style: none!important;
}


/* Buttons */
.aa-forms-wrapper button,
.aa-forms-wrapper input[type="submit"] {
  display: inline-block;
  margin-top: 18px;
  padding: 10px 16px;
  border: 1px solid #333;
  background: #333;
  color: #fff;
  border-radius: 4px;
  cursor: pointer;
}

.aa-forms-wrapper button:hover,
.aa-forms-wrapper input[type="submit"]:hover {
  filter: brightness(1.05);
}

/* Help text */
.aa-forms-wrapper .description,
.aa-forms-wrapper .help,
.aa-forms-wrapper small {
  display: block;
  margin-top: 6px;
  color: #555;
  font-size: 0.9em;
}

/* Thank-you panel (kept hidden by default) */
.aa-forms-wrapper .aa-forms-thanks {
  margin-top: 16px;
}

/* Optional: tighten spacing in theme content areas */
.entry-content .aa-forms-wrapper {
  margin-left: 0;
  margin-right: 0;
}
#availabilityRow {
  display: none;
}

/* Inline error styling */
.aa-error {
  color: #b30000;
  font-size: 0.9em;
  margin-top: 6px;
}

.aa-has-error input,
.aa-has-error textarea,
.aa-has-error select {
  border-color: #b30000;
  box-shadow: 0 0 0 2px rgba(179,0,0,0.07);
}

/* Status area */
#formStatus {
  margin-top: 8px;
  font-size: 0.95em;
}
#formStatus.success { color: #156c2f; }
#formStatus.error   { color: #b30000; }
.aa-forms-thanks {
  display: none;            /* stays hidden until JS shows it */
  margin-top: 16px;
}

.aa-forms-thanks h1,
.aa-forms-thanks h2,
.aa-forms-thanks h3 {
  margin-top: 0;
}