.btrw-widget,
.btrw-widget * {
  box-sizing: border-box;
}

.btrw-widget {
  position: fixed;
  top: 110px;
  left: 24px;
  width: min(360px, calc(100vw - 24px));
  max-height: min(620px, calc(100vh - 130px));
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #ffc6b5;
  border-radius: 20px;
  background: #fffdf9;
  color: #071713;
  direction: rtl;
  font-family: Inter, "Segoe UI", Tahoma, Arial, sans-serif;
  box-shadow: 0 18px 46px rgba(29, 38, 55, .22);
  z-index: 2147483000;
  opacity: 0;
  pointer-events: none;
  transition: opacity .16s ease, box-shadow .16s ease;
}

.btrw-widget.btrw-open {
  opacity: 1;
  pointer-events: auto;
}

.btrw-widget.btrw-dragging {
  transition: none;
  box-shadow: 0 24px 56px rgba(29, 38, 55, .28);
}

.btrw-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 1px solid #eadccb;
  background: #fffdf9;
  cursor: grab;
  user-select: none;
}

.btrw-dragging .btrw-head {
  cursor: grabbing;
}

.btrw-head strong {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 16px;
}

.btrw-dots {
  color: #9a8e83;
  font-size: 18px;
  line-height: 1;
}

.btrw-head button,
.btrw-item button,
.btrw-toggle {
  border: 0;
  cursor: pointer;
  font: inherit;
  font-weight: 800;
}

.btrw-head button {
  border: 1px solid #eadccb;
  border-radius: 999px;
  background: #fffdf9;
  color: #071713;
  padding: 6px 10px;
  font-size: 12px;
}

.btrw-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px 14px;
  overflow: auto;
}

.btrw-added {
  border: 1px dashed #dfcbb5;
  border-radius: 14px;
  background: #fffaf4;
  padding: 9px 10px;
  color: #4e5a52;
  font-size: 12px;
  font-weight: 800;
}

.btrw-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.btrw-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 34px;
  align-items: center;
  gap: 8px;
  border: 1px solid #eadccb;
  border-radius: 14px;
  background: #fffaf4;
  padding: 10px;
}

.btrw-item-main {
  min-width: 0;
}

.btrw-item strong {
  display: block;
  font-size: 13px;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.btrw-item-main > span {
  display: block;
  margin-top: 3px;
  color: #738178;
  font-size: 11px;
  font-weight: 700;
}

.btrw-score {
  width: fit-content;
  border: 1px solid #bfe2d2;
  border-radius: 999px;
  background: #eef7f2;
  color: #156f4f !important;
  padding: 3px 7px;
  direction: rtl;
  font-weight: 950 !important;
}

.btrw-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 7px;
}

.btrw-badges span {
  border: 1px solid #cddffc;
  border-radius: 999px;
  background: #edf4ff;
  color: #1d5aa7;
  padding: 3px 7px;
  font-size: 10px;
  font-weight: 800;
}

.btrw-item button {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: #ff856f;
  color: #fff;
  font-size: 18px;
}

.btrw-item button:disabled {
  opacity: .45;
  cursor: not-allowed;
}

.btrw-empty,
.btrw-error {
  border: 1px dashed #dfcbb5;
  border-radius: 14px;
  background: #fffaf4;
  color: #738178;
  padding: 14px;
  text-align: center;
  font-size: 12px;
  line-height: 1.5;
}

.btrw-error {
  border-color: #f0b7af;
  background: #fff5f3;
  color: #a53124;
}

.btrw-toggle {
  position: fixed;
  left: 22px;
  bottom: 22px;
  z-index: 2147482999;
  display: none;
  align-items: center;
  gap: 8px;
  border: 1px solid #ffc6b5;
  border-radius: 999px;
  background: #fffdf9;
  color: #071713;
  padding: 10px 14px;
  box-shadow: 0 10px 24px rgba(29, 38, 55, .16);
}

.btrw-toggle.btrw-show {
  display: inline-flex;
}

.btrw-toggle span {
  min-width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #ff856f;
  color: #fff;
  font-size: 11px;
  font-weight: 950;
}

@media (max-width: 640px) {
  .btrw-widget {
    top: 86px;
    left: 9px;
    width: calc(100vw - 18px);
    max-height: calc(100vh - 100px);
  }

  .btrw-toggle {
    left: 12px;
    bottom: 12px;
  }
}
