.cj-list-trigger {
  position: fixed;
  z-index: 1028;
  right: 24px;
  top: 92px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 0 18px;
  color: #3f5f55;
  background: rgb(255 255 255 / 92%);
  border: 1px solid #a8b8a3;
  border-radius: 4px;
  box-shadow: 0 14px 36px rgb(44 44 42 / 8%);
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
}

.cj-list-trigger__count {
  display: grid;
  min-width: 22px;
  height: 22px;
  padding-inline: 6px;
  place-items: center;
  color: #fff;
  background: #3f5f55;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.cj-add-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 34px;
  padding: 0 12px;
  color: #3f5f55;
  background: #fbfaf7;
  border: 1px solid rgb(168 184 163 / 70%);
  border-radius: 999px;
  font: inherit;
  font-size: 12px;
  line-height: 1;
  cursor: pointer;
  transition:
    background-color .18s ease,
    border-color .18s ease,
    color .18s ease;
}

.cj-add-button:hover,
.cj-add-button.is-added {
  color: #fff;
  background: #3f5f55;
  border-color: #3f5f55;
}

.cj-add-button--icon {
  width: 30px;
  min-width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 999px;
  font-size: 18px;
}

.sgc-label-display__card .cj-add-button {
  margin-top: 10px;
  align-self: flex-start;
}

.cj-product-detail-add {
  width: 100%;
  max-width: 420px;
  margin: 12px 0 0;
}

.sgc-label-display[data-section-id="purpose"],
.sgc-label-display.cj-purpose-display {
  --cj-purpose-gap: 12px;
}

.sgc-label-display[data-section-id="purpose"] .sgc-label-display__title,
.sgc-label-display[data-section-id="purpose"] .sgc-label-display__description,
.sgc-label-display.cj-purpose-display .sgc-label-display__title,
.sgc-label-display.cj-purpose-display .sgc-label-display__description {
  text-align: start;
}

.sgc-label-display[data-section-id="purpose"] .sgc-label-display__list,
.sgc-label-display.cj-purpose-display .sgc-label-display__list {
  display: flex;
}

.sgc-label-display[data-section-id="purpose"] .sgc-label-display__flex:not(.splide),
.sgc-label-display.cj-purpose-display .sgc-label-display__flex:not(.splide) {
  flex-wrap: nowrap;
  gap: var(--cj-purpose-gap);
  overflow-x: auto;
  padding: 2px 2px 10px;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.sgc-label-display[data-section-id="purpose"] .sgc-label-display__flex:not(.splide)::-webkit-scrollbar,
.sgc-label-display.cj-purpose-display .sgc-label-display__flex:not(.splide)::-webkit-scrollbar {
  display: none;
}

.sgc-label-display[data-section-id="purpose"] .sgc-label-display__flex:not(.splide) .sgc-label-display__flex-item,
.sgc-label-display.cj-purpose-display .sgc-label-display__flex:not(.splide) .sgc-label-display__flex-item {
  flex: 0 0 220px;
  width: 220px;
  max-width: 220px;
  scroll-snap-align: start;
}

.sgc-label-display[data-section-id="purpose"] .sgc-label-display__card,
.sgc-label-display.cj-purpose-display .sgc-label-display__card {
  display: flex;
  min-height: 0;
  height: 176px;
  padding: 16px;
  background: rgb(255 255 255 / 84%);
  border: 1px solid #e8e3d8;
  border-radius: 4px;
  box-shadow: 0 10px 28px rgb(44 44 42 / 4%);
  overflow: hidden;
}

.sgc-label-display[data-section-id="purpose"] .sgc-label-display__card-content,
.sgc-label-display.cj-purpose-display .sgc-label-display__card-content {
  display: flex;
  min-height: 0;
  height: 100%;
  flex-direction: column;
  justify-content: flex-start;
}

.sgc-label-display[data-section-id="purpose"] .sgc-block-subtitle,
.sgc-label-display.cj-purpose-display .sgc-block-subtitle {
  font-family: Georgia, "Times New Roman", serif !important;
  font-size: 16px !important;
  line-height: 1.12 !important;
}

.sgc-label-display[data-section-id="purpose"] .sgc-block-description,
.sgc-label-display.cj-purpose-display .sgc-block-description {
  display: -webkit-box;
  margin-top: 8px;
  overflow: hidden;
  font-size: 12px !important;
  line-height: 1.45 !important;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
}

.sgc-label-display[data-section-id="purpose"] .sgc-label-display__card .cj-add-button,
.sgc-label-display.cj-purpose-display .sgc-label-display__card .cj-add-button {
  min-height: 28px;
  margin-top: auto;
  padding-inline: 10px;
  font-size: 11px;
}

.block-product-card,
.product-card,
.card-product {
  position: relative;
}

.block-product-card .cj-add-button,
.product-card .cj-add-button,
.card-product .cj-add-button {
  position: absolute;
  z-index: 3;
  right: 12px;
  bottom: 12px;
}

.cj-list-overlay {
  position: fixed;
  z-index: 1030;
  inset: 0;
  display: none;
  background: rgb(31 31 29 / 22%);
}

.cj-list-overlay.is-open {
  display: block;
}

.cj-list-drawer {
  position: fixed;
  z-index: 1031;
  inset-block: 0;
  inset-inline-end: 0;
  display: flex;
  width: min(420px, 100vw);
  max-width: 100%;
  flex-direction: column;
  color: #1f1f1d;
  background: rgb(255 255 255 / 97%);
  border-left: 1px solid #e8e3d8;
  box-shadow: -26px 0 70px rgb(44 44 42 / 16%);
  transform: translateX(104%);
  transition: transform .22s ease;
}

.cj-list-drawer.is-open {
  transform: translateX(0);
}

.cj-list-drawer__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 28px 28px 20px;
  border-bottom: 1px solid #e8e3d8;
}

.cj-list-drawer h2,
.cj-list-panel h2 {
  margin: 0;
  color: #1f1f1d;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 28px;
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: 0;
}

.cj-list-drawer p,
.cj-list-panel p {
  margin: 6px 0 0;
  color: #6f6f68;
  font-size: 13px;
  line-height: 1.5;
}

.cj-list-close {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  place-items: center;
  color: #6f6f68;
  background: #fff;
  border: 1px solid #e8e3d8;
  border-radius: 999px;
  cursor: pointer;
}

.cj-list-drawer__body {
  flex: 1 1 auto;
  overflow: auto;
  padding: 0 28px 26px;
}

.cj-list-block {
  padding: 22px 0;
  border-bottom: 1px solid #e8e3d8;
}

.cj-list-block h3 {
  margin: 0 0 12px;
  color: #3f5f55;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  line-height: 1.2;
  text-transform: uppercase;
}

.cj-list-empty {
  margin: 0;
  color: #6f6f68;
  font-size: 14px;
  line-height: 1.6;
}

.cj-list-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cj-list-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  max-width: 100%;
  min-height: 34px;
  padding: 0 10px;
  color: #3f5f55;
  background: rgb(216 221 214 / 28%);
  border: 1px solid rgb(168 184 163 / 75%);
  border-radius: 999px;
  font-size: 12px;
}

.cj-list-remove {
  display: grid;
  width: 18px;
  height: 18px;
  padding: 0;
  place-items: center;
  color: #6f6f68;
  background: transparent;
  border: 0;
  cursor: pointer;
}

.cj-list-form {
  display: grid;
  gap: 10px;
}

.cj-list-field {
  display: grid;
  gap: 6px;
}

.cj-list-field label {
  color: #2c2c2a;
  font-size: 12px;
  font-weight: 600;
}

.cj-list-field input,
.cj-list-field select,
.cj-list-field textarea {
  width: 100%;
  min-height: 42px;
  padding: 10px 12px;
  color: #1f1f1d;
  background: #fbfaf7;
  border: 1px solid #e8e3d8;
  border-radius: 4px;
  font: inherit;
  font-size: 13px;
}

.cj-list-field textarea {
  min-height: 72px;
  resize: vertical;
}

.cj-list-field input:focus,
.cj-list-field select:focus,
.cj-list-field textarea:focus {
  outline: 1px solid #a8b8a3;
  border-color: #a8b8a3;
}

.cj-list-actions {
  position: sticky;
  bottom: 0;
  display: grid;
  gap: 10px;
  padding: 16px 28px 24px;
  background: linear-gradient(180deg, rgb(255 255 255 / 84%), #fff 18%);
  border-top: 1px solid #e8e3d8;
}

.cj-list-action {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  color: #3f5f55;
  background: #fff;
  border: 1px solid #a8b8a3;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
}

.cj-list-action--primary {
  color: #fff;
  background: #3f5f55;
  border-color: #3f5f55;
}

.cj-list-note {
  padding: 14px;
  color: #4f554f;
  background: linear-gradient(135deg, rgb(237 229 214 / 70%), rgb(216 221 214 / 40%));
  border: 1px solid #e8e3d8;
  border-radius: 6px;
  font-size: 12px;
  line-height: 1.5;
}

.cj-mobile-bar,
.cj-list-panel {
  display: none;
}

@media (max-width: 959px) {
  .cj-list-trigger {
    display: none;
  }

  .cj-list-drawer {
    display: none;
  }

  .cj-list-overlay.is-open {
    display: none;
  }

  .cj-mobile-bar {
    position: fixed;
    z-index: 1028;
    inset-inline: 14px;
    bottom: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 58px;
    padding: 10px 12px 10px 16px;
    color: #1f1f1d;
    background: rgb(255 255 255 / 96%);
    border: 1px solid #e8e3d8;
    border-radius: 8px;
    box-shadow: 0 12px 40px rgb(44 44 42 / 16%);
    transform: translateY(calc(100% + 24px));
    transition: transform .2s ease;
  }

  .cj-mobile-bar.is-visible {
    transform: translateY(0);
  }

  .cj-mobile-bar b {
    font-size: 13px;
    line-height: 1.25;
  }

  .cj-mobile-bar button {
    min-height: 38px;
    padding: 0 16px;
    color: #fff;
    background: #3f5f55;
    border: 0;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
  }

  .cj-list-panel {
    position: fixed;
    z-index: 1032;
    inset-inline: 12px;
    bottom: 84px;
    max-height: calc(100vh - 110px);
    overflow: auto;
    padding: 18px;
    background: #fff;
    border: 1px solid #e8e3d8;
    border-radius: 12px;
    box-shadow: 0 18px 54px rgb(44 44 42 / 18%);
    transform: translateY(18px);
    opacity: 0;
    pointer-events: none;
    transition:
      opacity .18s ease,
      transform .18s ease;
  }

  .cj-list-panel.is-open {
    display: block;
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .cj-list-panel__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e8e3d8;
  }

  .cj-list-panel .cj-list-block {
    padding: 16px 0;
  }

  .cj-list-panel .cj-list-actions {
    position: static;
    padding: 14px 0 0;
    border-top: 0;
  }
}
