@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/ibm-plex-sans-latin-400-normal.woff2") format("woff2");
}

@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../fonts/ibm-plex-sans-latin-500-normal.woff2") format("woff2");
}

@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/ibm-plex-sans-latin-600-normal.woff2") format("woff2");
}

:root,
[data-theme="light"],
[data-theme="dark"] {
  --s-font-sans: "IBM Plex Sans", system-ui, sans-serif;
  --s-font-body: var(--s-font-sans);
  --s-font-heading: var(--s-font-sans);
}

body > header nav {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  align-items: center;
}

body > header nav form {
  margin: 0;
}

/* Sumi small button size (see .small in sumi.min.css) */
:is(button, [type="button"], [type="submit"], [type="reset"], [role="button"]) {
  padding: 0.4rem 0.8rem;
  font-size: 0.875rem;
}

.flash {
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  border: 1px solid var(--s-border, #ccc);
  border-radius: var(--s-radius, 0.25rem);
}

.flash.error {
  border-color: #c00;
}

.flash.success {
  border-color: #080;
}

.flash.info {
  border-color: #08c;
}

textarea {
  width: 100%;
  min-height: 6rem;
}

.muted {
  opacity: 0.75;
  font-size: 0.9rem;
}

table {
  width: 100%;
  margin-bottom: 1rem;
}

form.survey-respond legend {
  font-size: var(--s-text-h4, 1.25rem);
  font-weight: var(--s-heading-weight, 700);
  line-height: 1.35;
  color: var(--s-text);
  padding: 0 0 0.35rem;
  margin-bottom: 0.25rem;
}

form.survey-respond label {
  font-size: 0.875rem;
  font-weight: 500;
}

form.survey-respond .survey-respond-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1rem 1.25rem;
  align-items: start;
}

form.survey-respond .survey-respond-field select,
form.survey-respond .survey-respond-field textarea {
  width: 100%;
  margin: 0;
}

@media (max-width: 40rem) {
  form.survey-respond .survey-respond-fields {
    grid-template-columns: 1fr;
  }
}

.survey-respond-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  margin: 0;
}

.survey-respond-progress {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--s-muted);
}

.survey-edit [id^="section-"],
.survey-edit [id^="question-"] {
  scroll-margin-top: 1.25rem;
}

.survey-edit-label-pair {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1rem 1.25rem;
  align-items: start;
}

@media (max-width: 40rem) {
  .survey-edit-label-pair {
    grid-template-columns: 1fr;
  }
}

.survey-edit-question {
  margin-top: 1.5rem;
}

.survey-edit-question-title {
  margin: 0 0 0.75rem;
  font-size: var(--s-text-h4, 1.25rem);
}

.survey-edit-question-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1rem 1.25rem;
  align-items: start;
}

.survey-edit-question-field textarea {
  width: 100%;
  min-height: 8rem;
}

@media (max-width: 40rem) {
  .survey-edit-question-fields {
    grid-template-columns: 1fr;
  }
}

.survey-edit .callout.success {
  transition:
    background-color 0.5s ease,
    border-color 0.5s ease;
}
