.we-v2-form-workbench {
  grid-template-columns: minmax(320px, .84fr) minmax(0, 1.16fr);
}

.we-v2-form-workbench .we-v2-workbench__input,
.we-v2-form-workbench .we-v2-result {
  min-width: 0;
}

.we-v2-form-workbench .we-v2-result {
  min-height: 560px;
}

.we-v2-form-tool__presets {
  margin-top: 20px;
}

.we-v2-form-tool__fields {
  margin-top: 18px;
  display: grid;
  gap: 18px;
}

.we-v2-form-tool__measure {
  min-width: 0;
}

.we-v2-form-tool__measure .we-v2-control strong {
  flex: 0 0 auto;
  color: var(--we-v2-muted);
  font-size: 12px;
  font-weight: 700;
}

.we-v2-form-tool__range {
  margin-top: 9px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
}

.we-v2-form-tool__range input[type="range"] {
  width: 100%;
  height: 28px;
  margin: 0;
  accent-color: var(--we-v2-primary);
  cursor: pointer;
}

.we-v2-form-tool__range output {
  min-width: 68px;
  color: var(--we-v2-text-soft);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 12px;
  font-weight: 700;
  text-align: right;
}

.we-v2-form-tool__actions {
  margin-top: 20px;
  display: flex;
  justify-content: flex-end;
}

.we-v2-form-tool__actions button {
  min-height: 42px;
}

.we-v2-bmi-result .we-v2-result__top button:disabled {
  cursor: not-allowed;
  opacity: .48;
}

.we-v2-bmi-result .we-v2-result-state {
  min-height: 390px;
}

.we-v2-bmi-result__hero .we-v2-result-hero__value {
  min-width: 112px;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 34px;
}

.we-v2-bmi-result__hero .we-v2-result-hero__value small {
  display: block;
  margin-top: 4px;
  color: var(--we-v2-muted);
  font-family: inherit;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0;
}

.we-v2-bmi-judgements {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.we-v2-bmi-judgements dd {
  font-size: 16px;
}

.we-v2-bmi-ideal {
  margin-top: 10px;
  padding: 14px;
  border: 1px solid var(--we-v2-line);
  border-radius: var(--we-v2-radius-sm);
  background: var(--we-v2-surface);
}

.we-v2-bmi-ideal > header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.we-v2-bmi-ideal h3 {
  margin: 0;
  font-size: 14px;
  letter-spacing: -.02em;
}

.we-v2-bmi-ideal header span {
  color: var(--we-v2-muted);
  font-size: 11px;
}

.we-v2-bmi-ideal__scale {
  margin-top: 13px;
  display: grid;
  grid-template-columns: 1fr 1.7fr 1fr;
  overflow: hidden;
  border-radius: 7px;
}

.we-v2-bmi-ideal__scale span {
  min-height: 8px;
  background: var(--we-v2-primary-line);
}

.we-v2-bmi-ideal__scale span:nth-child(2) {
  background: var(--we-v2-success);
}

.we-v2-bmi-ideal__scale span:nth-child(3) {
  background: var(--we-v2-warning-line);
}

.we-v2-bmi-ideal__values {
  margin: 9px 0 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.we-v2-bmi-ideal__values div {
  min-width: 0;
}

.we-v2-bmi-ideal__values dt {
  color: var(--we-v2-muted);
  font-size: 10px;
}

.we-v2-bmi-ideal__values dd {
  margin: 2px 0 0;
  overflow-wrap: anywhere;
  color: var(--we-v2-text-soft);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 12px;
  font-weight: 700;
}

.we-v2-bmi-ideal__values div:nth-child(2) {
  text-align: center;
}

.we-v2-bmi-ideal__values div:last-child {
  text-align: right;
}

.we-v2-bmi-standard {
  margin-top: 10px;
}

.we-v2-bmi-standard .we-v2-record-table {
  min-width: 520px;
}

.we-v2-bmi-standard .we-v2-record-table td:not(:first-child),
.we-v2-bmi-standard .we-v2-record-table th:not(:first-child) {
  text-align: right;
}

.we-v2-bmi-standard .we-v2-record-table tbody tr:nth-child(2) {
  background: var(--we-v2-success-soft);
}

.we-v2-bmi-status {
  margin: 10px 0 0;
  color: var(--we-v2-muted);
  font-size: 11px;
}

@media (max-width: 920px) {
  .we-v2-form-workbench {
    grid-template-columns: 1fr;
  }

  .we-v2-form-workbench .we-v2-workbench__input {
    border-right: 0;
    border-bottom: 1px solid var(--we-v2-line);
  }

  .we-v2-form-workbench .we-v2-result {
    min-height: auto;
  }
}

@media (max-width: 640px) {
  .we-v2-form-workbench .we-v2-workbench__input,
  .we-v2-form-workbench .we-v2-result {
    padding: 20px;
  }

  .we-v2-form-tool__presets {
    align-items: stretch;
  }

  .we-v2-form-tool__presets > span {
    width: 100%;
  }

  .we-v2-form-tool__presets button {
    min-height: 42px;
    flex: 1 1 140px;
  }

  .we-v2-bmi-result__hero {
    grid-template-columns: 38px minmax(0, 1fr);
  }

  .we-v2-bmi-result__hero .we-v2-result-hero__value {
    grid-column: 1 / -1;
    max-width: none;
    text-align: left;
  }

  .we-v2-bmi-ideal__values {
    grid-template-columns: 1fr;
  }

  .we-v2-bmi-ideal__values div,
  .we-v2-bmi-ideal__values div:nth-child(2),
  .we-v2-bmi-ideal__values div:last-child {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    text-align: left;
  }
}
