.edcc {
  --edcc-bg: #fbfaf7;
  --edcc-bg-soft: #f5f3ee;
  --edcc-text: #242424;
  --edcc-muted: #686762;
  --edcc-line: #dfddd7;
  --edcc-control: #2d2d2b;
  --edcc-focus: rgba(45, 45, 43, 0.22);
  position: fixed;
  left: 24px;
  bottom: 24px;
  width: min(470px, calc(100vw - 48px));
  z-index: 2147482000;
  color: var(--edcc-text);
  font: inherit;
}

.edcc[hidden],
.edcc [hidden] {
  display: none !important;
}

.edcc__panel {
  box-sizing: border-box;
  width: 100%;
  padding: 24px;
  background: var(--edcc-bg);
  border: 1px solid var(--edcc-line);
  border-radius: 16px;
  box-shadow: 0 16px 46px rgba(28, 28, 26, 0.12);
}

.edcc__panel--settings {
  max-height: min(760px, calc(100vh - 48px));
  overflow-y: auto;
  overscroll-behavior: contain;
}

.edcc__title,
.edcc__category-title,
.edcc__text,
.edcc__category-text {
  margin-top: 0;
}

.edcc__title {
  margin-bottom: 10px;
  font-size: 20px;
  line-height: 1.25;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--edcc-text);
}

.edcc__text {
  margin-bottom: 18px;
  font-size: 14px;
  line-height: 1.58;
  color: var(--edcc-muted);
}

.edcc__decision-row,
.edcc__settings-actions {
  display: flex;
  gap: 10px;
}

.edcc__button,
.edcc__text-button,

.edcc__error {
  margin-top: 10px;
  padding: 9px 10px;
  border: 1px solid var(--edcc-line);
  border-radius: 8px;
  background: var(--edcc-bg-soft);
  color: var(--edcc-text);
  font-size: 12px;
  line-height: 1.4;
}

.edcc__button:disabled {
  cursor: wait;
  opacity: 0.55;
}

.edcc__back {
  font: inherit;
  cursor: pointer;
}

.edcc__button {
  min-height: 44px;
  padding: 10px 14px;
  border: 1px solid var(--edcc-control);
  border-radius: 10px;
  background: transparent;
  color: var(--edcc-text);
  font-size: 13.5px;
  line-height: 1.2;
  font-weight: 600;
  text-align: center;
  transition: background-color 140ms ease, box-shadow 140ms ease;
}

.edcc__button--decision {
  flex: 1 1 0;
}

.edcc__button:hover {
  background: var(--edcc-bg-soft);
}

.edcc__button:focus-visible,
.edcc__text-button:focus-visible,
.edcc__legal-link:focus-visible,
.edcc__back:focus-visible,
.edcc__switch-input:focus-visible + .edcc__switch-ui {
  outline: none;
  box-shadow: 0 0 0 3px var(--edcc-focus);
}

.edcc__text-button,
.edcc__back {
  border: 0;
  background: transparent;
  color: var(--edcc-text);
}

.edcc__text-button {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  margin-top: 7px;
  padding: 5px 0;
  font-size: 13.5px;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.edcc__text-button--centered {
  justify-content: center;
  align-self: center;
  margin-top: 0;
}

.edcc__meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
  margin-top: 10px;
  font-size: 12px;
  line-height: 1.45;
  color: var(--edcc-muted);
  text-align: left;
}

.edcc__meta--centered {
  align-items: center;
  text-align: center;
}

.edcc__revocation-note {
  width: 100%;
}

.edcc__revocation-note--centered {
  max-width: 100%;
}

.edcc__legal-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 0 6px;
  width: 100%;
  align-items: center;
  text-align: left;
}

.edcc__legal-links--single {
  justify-content: center;
  text-align: center;
}

.edcc__legal-links--split {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: 0;
  width: 100%;
  max-width: none;
  margin: 0;
  justify-content: center;
  align-items: center;
  text-align: center;
}

.edcc__legal-cell {
  min-width: 0;
  display: flex;
  align-items: center;
}

.edcc__legal-cell--left {
  justify-content: center;
  padding-right: 12px;
}

.edcc__legal-cell--right {
  justify-content: center;
  padding-left: 12px;
}

.edcc__legal-divider {
  width: 1px;
  height: 14px;
  background: var(--edcc-line);
  align-self: center;
}

.edcc__legal-link {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.edcc__back {
  display: inline-flex;
  gap: 7px;
  align-items: center;
  min-height: 38px;
  margin: -7px 0 8px -7px;
  padding: 6px 7px;
  border-radius: 8px;
  font-size: 13px;
}

.edcc__category {
  padding: 16px 0;
  border-top: 1px solid var(--edcc-line);
}

.edcc__category:last-of-type {
  border-bottom: 1px solid var(--edcc-line);
}

.edcc__category-head {
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
}

.edcc__category-title {
  margin-bottom: 0;
  font-size: 15px;
  line-height: 1.35;
  font-weight: 600;
  color: var(--edcc-text);
}

.edcc__category-text {
  margin: 7px 0 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--edcc-muted);
}

.edcc__status {
  flex: 0 0 auto;
  padding: 5px 9px;
  border-radius: 999px;
  background: var(--edcc-bg-soft);
  color: var(--edcc-muted);
  font-size: 11.5px;
  font-weight: 600;
  white-space: nowrap;
}

.edcc__switch {
  position: relative;
  flex: 0 0 auto;
  width: 46px;
  height: 26px;
  margin: 0;
}

.edcc__switch-input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.edcc__switch-ui {
  position: absolute;
  inset: 0;
  border: 1px solid #b9b6ae;
  border-radius: 999px;
  background: #dedbd4;
  transition: background-color 140ms ease, border-color 140ms ease, box-shadow 140ms ease;
}

.edcc__switch-ui::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.16);
  transition: transform 140ms ease;
}

.edcc__switch-input:checked + .edcc__switch-ui {
  border-color: var(--edcc-control);
  background: var(--edcc-control);
}

.edcc__switch-input:checked + .edcc__switch-ui::after {
  transform: translateX(20px);
}

.edcc__settings-actions {
  margin-top: 18px;
}


@media (max-width: 640px) {
  .edcc {
    left: 10px;
    right: 10px;
    bottom: 8px;
    width: auto;
  }

  .edcc__panel {
    padding: 15px 15px calc(13px + env(safe-area-inset-bottom, 0px));
    border-radius: 14px;
    box-shadow: 0 12px 34px rgba(28, 28, 26, 0.14);
  }

  .edcc__panel--settings {
    max-height: calc(100vh - 16px);
    max-height: calc(100dvh - 16px);
    overflow-y: auto;
  }

  .edcc__title {
    margin-bottom: 7px;
    font-size: 18px;
    line-height: 1.22;
  }

  .edcc__text {
    margin-bottom: 12px;
    font-size: 13px;
    line-height: 1.46;
  }

  .edcc__decision-row {
    gap: 8px;
  }

  .edcc__button {
    min-height: 42px;
    padding: 9px 10px;
    font-size: 12.75px;
  }

  .edcc__text-button {
    min-height: 34px;
    margin-top: 4px;
    padding: 3px 0;
    font-size: 12.75px;
  }

  .edcc__text-button--centered {
    margin-top: 0;
  }

  .edcc__meta {
    gap: 3px 10px;
    margin-top: 5px;
    font-size: 11px;
    line-height: 1.35;
  }

  .edcc__legal-cell--left {
    padding-right: 10px;
  }

  .edcc__legal-cell--right {
    padding-left: 10px;
  }

  .edcc__legal-divider {
    height: 12px;
  }

  .edcc__back {
    min-height: 34px;
    margin: -5px 0 5px -5px;
    padding: 5px;
    font-size: 12.5px;
  }

  .edcc__category {
    padding: 13px 0;
  }

  .edcc__category-title {
    font-size: 14px;
  }

  .edcc__category-text {
    margin-top: 5px;
    font-size: 12.5px;
    line-height: 1.45;
  }

  .edcc__settings-actions {
    flex-direction: column;
    gap: 8px;
    margin-top: 14px;
  }

  .edcc__settings-actions .edcc__button {
    width: 100%;
  }

}

@media (max-width: 359px) {
  .edcc__decision-row {
    flex-direction: column;
  }

  .edcc__decision-row .edcc__button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .edcc *,
  .edcc *::before,
  .edcc *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.001ms !important;
  }
}
