.kwb-mpte {
  --mpte-ink: #15363d;
  --mpte-accent: #845438;
  --mpte-border: #bba69a;
  --mpte-error: #9e2b20;
  max-width: 52rem;
  margin: 0 auto;
  color: var(--mpte-ink);
  font-size: 1rem;
  line-height: 1.55;
}

.kwb-mpte [hidden] {
  display: none !important;
}

.kwb-mpte .kwb-mpte__intro {
  margin: 0 0 1.25rem;
  font-size: clamp(1.25rem, 3vw, 1.5rem);
  font-weight: 700;
  line-height: 1.25;
  text-align: center;
}

.kwb-mpte .kwb-mpte__form,
.kwb-mpte .kwb-mpte__result {
  padding: clamp(1rem, 3vw, 2rem);
  border: 1px solid #e7d7ca;
  border-radius: 1rem;
  color: var(--mpte-ink);
  background: #f9f3ed;
}

.kwb-mpte .kwb-mpte__form {
  display: grid;
  gap: 1rem;
  margin: 0;
}

.kwb-mpte .kwb-mpte__measurements {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.kwb-mpte .kwb-mpte__field {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 0.375rem;
}

.kwb-mpte .kwb-mpte__field label {
  color: var(--mpte-ink);
  font-weight: 650;
  line-height: 1.4;
}

.kwb-mpte .kwb-mpte__field input,
.kwb-mpte .kwb-mpte__field select {
  box-sizing: border-box;
  display: block;
  width: 100%;
  min-height: 2.875rem;
  max-width: 100%;
  margin: 0;
  padding: 0.625rem 0.75rem;
  border: 1px solid var(--mpte-border);
  border-radius: 0.5rem;
  background-color: #fff;
  color: var(--mpte-ink);
  font: inherit;
}

.kwb-mpte .kwb-mpte__field select {
  appearance: auto;
}

.kwb-mpte .kwb-mpte__field [aria-invalid="true"] {
  border-color: var(--mpte-error);
}

.kwb-mpte .kwb-mpte__error {
  color: var(--mpte-error);
  font-size: 0.875rem;
}

.kwb-mpte button[type="submit"] {
  min-height: 2.875rem;
  margin: 0.25rem 0 0;
  padding: 0.75rem 1.25rem;
  border: 1px solid transparent;
  border-radius: 0.5rem;
  background-color: var(--mpte-accent);
  color: #fff;
  font: inherit;
  font-weight: 750;
  line-height: 1.4;
  cursor: pointer;
}

.kwb-mpte button[type="submit"]:hover {
  background-color: #6b432d;
}

.kwb-mpte :focus-visible {
  outline: 2px solid var(--mpte-accent);
  outline-offset: 3px;
}

.kwb-mpte .kwb-mpte__result {
  margin: 1rem 0 0;
}

.kwb-mpte .kwb-mpte__result h2 {
  margin: 0 0 0.75rem;
  color: var(--mpte-ink);
  font-size: clamp(1.25rem, 3vw, 1.625rem);
  line-height: 1.3;
  text-transform: none;
}

.kwb-mpte .kwb-mpte__result p {
  margin: 0 0 0.75rem;
}

.kwb-mpte .kwb-mpte__result .kwb-mpte__book {
  margin-bottom: 0;
  padding-top: 0.75rem;
  border-top: 1px solid #e7d7ca;
}

@media (max-width: 35rem) {
  .kwb-mpte .kwb-mpte__measurements {
    grid-template-columns: 1fr;
  }
}

.kwb-mpte .kwb-mpte__welcome {
  display: grid;
  grid-template-columns: clamp(5.5rem, 12vw, 7.25rem) minmax(0, 1fr);
  align-items: start;
  gap: clamp(1rem, 3vw, 1.75rem);
  margin: 0 0 1.5rem;
  padding: clamp(1rem, 3vw, 2rem);
  border: 1px solid #e7ded4;
  border-radius: 14px;
  background: #f8f5ef;
}

.kwb-mpte .kwb-mpte__portrait {
  width: 100%;
  aspect-ratio: 1;
  overflow: hidden;
  border: 3px solid #fff;
  border-radius: 50%;
  box-shadow: 0 3px 10px rgba(21, 54, 61, 0.12);
}

.kwb-mpte .kwb-mpte__portrait img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  transform: scale(1.65);
  transform-origin: center top;
}

.kwb-mpte .kwb-mpte__welcome-copy p {
  margin: 0 0 0.75rem;
}

.kwb-mpte .kwb-mpte__signature {
  display: block;
  width: min(10rem, 100%);
  height: auto;
  margin: 0;
}

.kwb-mpte .kwb-mpte__welcome-copy .kwb-mpte__byline {
  margin: 0;
  color: var(--col1, #15363d);
  font-size: 0.875rem;
  font-weight: 600;
}

.kwb-mpte .kwb-mpte__result .kwb-mpte__disclaimer {
  margin: 0.85rem 0 0;
  font-size: 0.875rem;
  line-height: 1.5;
}

@media (max-width: 42rem) {
  .kwb-mpte .kwb-mpte__welcome {
    grid-template-columns: clamp(3.5rem, 17vw, 5.25rem) minmax(0, 1fr);
    gap: 0.75rem;
    padding: 0.875rem;
  }
}

@media (max-width: 700px) {
  .kwb-mpte:not(.kwb-mpte--proposals) .kwb-mpte__welcome {
    grid-template-columns: 3.5rem minmax(0, 1fr);
    align-items: center;
    row-gap: 0.75rem;
  }

  .kwb-mpte:not(.kwb-mpte--proposals) .kwb-mpte__welcome-copy {
    display: contents;
  }

  .kwb-mpte:not(.kwb-mpte--proposals) .kwb-mpte__welcome-copy > p {
    grid-column: 1 / -1;
    margin: 0;
  }

  .kwb-mpte:not(.kwb-mpte--proposals) .kwb-mpte__welcome-copy > .kwb-mpte__byline {
    grid-area: 1 / 2;
  }
}

.kwb-mpte .kwb-mpte__box {
  padding: clamp(1rem, 3vw, 2rem);
  border: 1px solid #e5d5c8;
  border-radius: 14px;
  background: #f3e7dd;
  box-shadow: 0 8px 24px rgb(20 63 66 / 5%);
}

.kwb-mpte .kwb-mpte__box:has(> form[hidden]) {
  display: none;
}

.kwb-mpte .kwb-mpte__box > :is(form.kwb-mpte__form, section.kwb-mpte__result) {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.kwb-mpte .kwb-mpte__box > section.kwb-mpte__result {
  margin: 1.5rem 0 0;
  padding-top: 1.5rem;
  border-top: 1px solid #c8b7a9;
}

.kwb-mpte :is(button[type="submit"], .kwb-mpte__more) {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 46px;
  padding: 0.625rem 1rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--col1, #15363d);
  color: #fff;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.4;
  text-align: center;
  text-decoration: none;
}

.kwb-mpte .kwb-mpte__more:hover {
  background: #244a50;
  color: #fff;
}

.kwb-mpte .kwb-mpte__diet-info {
  margin-top: 1rem;
  padding: clamp(1rem, 2.5vw, 1.5rem);
  border: 1px solid #d0dfda;
  border-radius: 14px;
  background: #eef4f1;
  scroll-margin-top: 8rem;
}

.kwb-mpte .kwb-mpte__diet-info .kwb-mpte__book {
  margin: 0;
}

.kwb-mpte .kwb-mpte__diet-info .kwb-mpte__disclaimer {
  margin: 0.75rem 0 0;
  font-size: 0.875rem;
  line-height: 1.5;
}

@media (max-width: 700px) {
  .kwb-mpte.kwb-mpte--proposals {
    display: flex;
    flex-direction: column;
  }

  .kwb-mpte--proposals .kwb-mpte__opening {
    order: 1;
    margin-top: 1.25rem;
  }
}
