:root {
  --bedc-green: #078527;
  --bedc-green-dark: #05651e;
  --bedc-red: #ed2924;
  --bedc-yellow: #f6d91b;
  --bedc-ink: #17201a;
  --bedc-muted: #657168;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body.bedc-popup-open {
  overflow: hidden;
}

.demo-page {
  min-height: 100vh;
  padding: 72px max(24px, calc((100vw - 980px) / 2));
  color: var(--bedc-ink);
  background: #f4f5f6;
}

.demo-page h1 {
  margin: 28px 0 12px;
  color: var(--bedc-green);
}

.demo-logo {
  width: 155px;
}

.bedc-popup {
  position: fixed;
  z-index: 2147483647;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  visibility: hidden;
  opacity: 0;
  transition: opacity 220ms ease, visibility 220ms ease;
}

.bedc-popup.is-visible {
  visibility: visible;
  opacity: 1;
}

.bedc-popup__backdrop {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 35%, rgb(7 133 39 / 12%), transparent 38%),
    rgb(8 18 11 / 72%);
  backdrop-filter: blur(5px);
}

.bedc-popup__card {
  position: relative;
  width: min(760px, 100%);
  max-height: min(760px, calc(100vh - 48px));
  overflow: auto;
  border: 1px solid rgb(7 133 39 / 16%);
  border-radius: 24px;
  background: #fff;
  color: #101812;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  box-shadow: 0 30px 90px rgb(0 0 0 / 35%);
  transform: translateY(18px) scale(.985);
  transition: transform 260ms cubic-bezier(.2, .8, .2, 1);
  scrollbar-width: thin;
}

.bedc-popup.is-visible .bedc-popup__card {
  transform: translateY(0) scale(1);
}

.bedc-popup__accent {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  display: flex;
  width: 100%;
  height: 6px;
  overflow: hidden;
  border-radius: 24px 24px 0 0;
}

.bedc-popup__accent span {
  flex: 1;
}

.bedc-popup__accent span:nth-child(1) { background: var(--bedc-red); }
.bedc-popup__accent span:nth-child(2) { background: var(--bedc-yellow); }
.bedc-popup__accent span:nth-child(3) { background: var(--bedc-green); }

.bedc-popup__close {
  position: absolute;
  z-index: 2;
  top: 18px;
  right: 18px;
  display: grid;
  width: 42px;
  height: 42px;
  padding: 0;
  place-items: center;
  border: 1px solid #e1e7e2;
  border-radius: 50%;
  color: #344239;
  background: #f7f9f7;
  cursor: pointer;
  transition: color 160ms ease, background 160ms ease, transform 160ms ease;
}

.bedc-popup__close:hover {
  color: #fff;
  background: var(--bedc-green);
  transform: rotate(4deg);
}

.bedc-popup__close:focus-visible,
.bedc-popup__continue:focus-visible {
  outline: 3px solid rgb(246 217 27 / 72%);
  outline-offset: 3px;
}

.bedc-popup__close svg {
  width: 19px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 2;
}

.bedc-popup__header {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 28px 76px 24px 34px;
  border-bottom: 1px solid #e9eee9;
  background: linear-gradient(120deg, #fff 50%, #f2faf4);
}

.bedc-popup__logo {
  display: block;
  width: 165px;
  max-width: 42%;
  height: auto;
}

.bedc-popup__heading {
  min-width: 0;
}

.bedc-popup__eyebrow {
  margin: 0;
  color: var(--bedc-green-dark);
  font-size: .94rem;
  font-weight: 800;
  letter-spacing: .06em;
  line-height: 1.35;
  text-transform: uppercase;
}

.bedc-popup h2 {
  margin: 0;
  font-size: clamp(1.75rem, 4vw, 2.35rem);
  line-height: 1.05;
}

.bedc-popup__body {
  padding: 26px 34px;
}

.bedc-popup__pledge {
  display: flex;
  gap: 16px;
  margin: 0;
  padding: 22px;
  border: 1px solid #dce9df;
  border-left: 5px solid var(--bedc-yellow);
  border-radius: 16px;
  background: #fbfdfb;
  box-shadow: 0 8px 24px rgb(7 133 39 / 6%);
}

.bedc-popup__pledge-icon {
  flex-basis: 42px;
  width: 42px;
  height: 42px;
}

.bedc-popup__pledge h3 {
  margin: 1px 0 10px;
  color: var(--bedc-green-dark);
  font-size: 1.08rem;
  line-height: 1.35;
}

.bedc-popup__pledge p {
  margin: 0;
  color: #17231a;
  font-size: clamp(1rem, 1.8vw, 1.08rem);
  font-weight: 500;
  line-height: 1.72;
}

.bedc-popup__pledge strong {
  color: var(--bedc-green);
  font-weight: 800;
  letter-spacing: .04em;
}

.bedc-popup__pledge .bedc-popup__pledge-closing {
  margin-top: 9px;
  color: var(--bedc-green-dark);
  font-size: .96rem;
  font-weight: 700;
}

.bedc-popup__statements {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 16px;
}

.bedc-popup__statements article {
  display: flex;
  gap: 13px;
  padding: 18px;
  border: 1px solid #e1ebe3;
  border-radius: 15px;
  background: #fbfdfb;
}

.bedc-popup__icon {
  display: grid;
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 10px;
  color: var(--bedc-green);
  background: #e5f4e8;
}

.bedc-popup__icon svg {
  width: 21px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
}

.bedc-popup__statements h3 {
  margin: 1px 0 7px;
  color: var(--bedc-green-dark);
  font-size: 1rem;
  line-height: 1.35;
}

.bedc-popup__statements p {
  margin: 0;
  color: #3f4c43;
  font-size: .84rem;
  font-weight: 500;
  line-height: 1.6;
}

.bedc-popup__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 19px 34px;
  border-top: 1px solid #e7ece8;
  background: #f7f9f7;
}

.bedc-popup__footer p {
  margin: 0;
  color: #6c776f;
  font-size: .78rem;
  font-weight: 600;
}

.bedc-popup__continue {
  min-height: 43px;
  padding: 0 22px;
  border: 0;
  border-radius: 10px;
  color: #fff;
  background: var(--bedc-green);
  box-shadow: 0 8px 20px rgb(7 133 39 / 22%);
  font: inherit;
  font-size: .86rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.bedc-popup__continue:hover {
  background: var(--bedc-green-dark);
  box-shadow: 0 10px 24px rgb(7 133 39 / 30%);
  transform: translateY(-1px);
}

@media (max-width: 640px) {
  .bedc-popup {
    align-items: center;
    padding: 10px;
  }

  .bedc-popup__card {
    width: 100%;
    max-height: calc(100dvh - 20px);
    border-radius: 18px;
  }

  .bedc-popup__accent {
    border-radius: 18px 18px 0 0;
  }

  .bedc-popup__header {
    gap: 14px;
    padding: 24px 58px 18px 20px;
  }

  .bedc-popup__logo {
    width: 118px;
    max-width: 44%;
  }

  .bedc-popup__eyebrow {
    font-size: .78rem;
    letter-spacing: .04em;
  }

  .bedc-popup__heading {
    min-width: 0;
  }

  .bedc-popup__body {
    padding: 18px 16px;
  }

  .bedc-popup__pledge {
    gap: 11px;
    padding: 16px 14px;
    border-left-width: 4px;
  }

  .bedc-popup__pledge-icon {
    flex-basis: 36px;
    width: 36px;
    height: 36px;
  }

  .bedc-popup__pledge p {
    font-size: .92rem;
    line-height: 1.62;
  }

  .bedc-popup__pledge h3 {
    margin-bottom: 7px;
    font-size: 1rem;
  }

  .bedc-popup__statements {
    grid-template-columns: 1fr;
    gap: 10px;
    margin-top: 12px;
  }

  .bedc-popup__statements article {
    gap: 11px;
    padding: 14px;
  }

  .bedc-popup__statements p {
    font-size: .82rem;
    line-height: 1.55;
  }

  .bedc-popup__footer {
    align-items: stretch;
    flex-direction: column;
    gap: 10px;
    padding: 13px 16px 16px;
  }

  .bedc-popup__footer p {
    text-align: center;
  }

  .bedc-popup__continue {
    min-height: 46px;
    width: 100%;
  }
}

@media (max-width: 380px) {
  .bedc-popup__header {
    align-items: flex-start;
    flex-direction: column;
    padding-right: 56px;
  }

  .bedc-popup__logo {
    width: 110px;
    max-width: 100%;
  }

  .bedc-popup__pledge {
    display: block;
  }

  .bedc-popup__pledge-icon {
    margin-bottom: 9px;
  }

  .bedc-popup__pledge p {
    font-size: .88rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .bedc-popup,
  .bedc-popup__card,
  .bedc-popup__close,
  .bedc-popup__continue {
    transition: none;
  }
}
