.bf-joker-chat {
  color-scheme: dark;
  font-family: var(--bf-font-sans, "Vazirmatn", Tahoma, sans-serif);
}

.bf-joker-chat .bf-joker-brandbar {
  position: relative;
  z-index: 4;
  display: flex;
  flex: 0 0 auto;
  direction: ltr;
  align-items: center;
  justify-content: space-between;
  min-height: calc(62px + env(safe-area-inset-top));
  padding: env(safe-area-inset-top) 14px 8px;
  overflow: hidden;
  border-bottom: 1px solid rgba(110, 207, 255, .24);
  background-image:
    radial-gradient(ellipse at 50% 0%, rgba(38, 115, 208, .2), transparent 58%),
    radial-gradient(ellipse at 82% 65%, rgba(169, 74, 255, .12), transparent 46%),
    linear-gradient(125deg, #050918 0%, #101a3b 52%, #080a20 100%);
  background-position: center;
  background-size: cover;
  text-shadow: 0 2px 9px #05030d;
}

.bf-joker-chat .bf-joker-close {
  display: grid;
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 1px solid rgba(174, 108, 255, .62);
  border-radius: 50%;
  color: #fff;
  background: radial-gradient(circle at 35% 25%, #17245b, #080d22 72%);
  box-shadow: 0 0 12px rgba(85, 87, 255, .2);
  cursor: pointer;
}

.bf-joker-chat .bf-joker-brand {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #fff;
}

.bf-joker-chat .bf-joker-brand-name {
  position: relative;
  font-family: "Apple Chancery", "URW Chancery L", "Segoe Script", cursive;
  font-size: clamp(25px, 7vw, 32px);
  font-style: italic;
  letter-spacing: -1.4px;
  line-height: 1;
  white-space: nowrap;
}

.bf-joker-chat .bf-joker-brand-name i {
  color: #d263ff;
  font-weight: 700;
}

.bf-joker-chat .bf-joker-brand-name b {
  position: absolute;
  top: -15px;
  left: 44%;
  color: #eee8ff;
  font-family: serif;
  font-size: 16px;
  font-weight: 400;
}

.bf-joker-chat .bf-joker-brand-subtitle {
  margin-top: 5px;
  color: #d6d1ed;
  font-size: 8px;
  letter-spacing: 2.2px;
}

.bf-joker-chat .bf-joker-more-mark {
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  padding: 8px;
  border: 1px solid rgba(123, 134, 255, .55);
  border-radius: 50%;
  color: #e8e9ff;
  background: radial-gradient(circle at 35% 25%, #17255a, #080d22 72%);
}

.bf-joker-chat .bf-joker-header {
  min-height: 64px;
  padding: 7px 15px !important;
  padding-top: 7px !important;
  border-bottom-color: rgba(166, 124, 255, .24) !important;
  background: linear-gradient(100deg, rgba(5, 10, 28, .97), rgba(10, 13, 40, .93)) !important;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .34) !important;
}

.bf-joker-chat .bf-joker-header > button:first-child {
  display: none !important;
}

.bf-joker-chat .bf-joker-header > div:first-of-type {
  border: 1px solid rgba(168, 123, 255, .7);
  border-radius: 50% !important;
  background: radial-gradient(circle at 35% 25%, #33245f, #0a1028 72%) !important;
  box-shadow: 0 0 14px rgba(151, 92, 255, .25);
}

.bf-joker-chat .bf-joker-notice {
  min-height: 42px;
  padding: 7px 14px !important;
  border-bottom-color: rgba(182, 134, 255, .18) !important;
  background: rgba(3, 7, 20, .92) !important;
}

.bf-joker-chat .bf-joker-notice > div:first-child {
  min-width: 0;
  font-size: 11px !important;
  line-height: 1.5;
}

.bf-joker-chat .bf-joker-notice > div:last-child {
  flex: 0 0 auto;
  border-radius: 14px !important;
  background: rgba(100, 57, 177, .48) !important;
}

.bf-joker-chat .bf-joker-scroll {
  background-color: #050713 !important;
  background-repeat: no-repeat;
  background-attachment: local;
  background-size: cover;
  background-position: center 38%;
  padding: 14px 12px 18px !important;
}

.bf-joker-chat .bf-joker-dot-pattern {
  display: none !important;
}

.bf-joker-chat .bf-joker-scroll > div:last-child {
  gap: 9px !important;
}

.bf-joker-chat .bf-joker-bubble.is-mine {
  border-bottom-right-radius: 5px !important;
}

.bf-joker-chat .bf-joker-bubble.is-theirs {
  border-bottom-left-radius: 5px !important;
}

.bf-joker-chat .bf-joker-composer {
  flex: 0 0 auto;
  padding: 11px 14px calc(12px + env(safe-area-inset-bottom)) !important;
  border-top: 1px solid rgba(140, 106, 255, .3) !important;
  background: linear-gradient(180deg, rgba(3, 6, 19, .97), #050817) !important;
  box-shadow: 0 -5px 20px rgba(0, 0, 0, .32) !important;
}

.bf-joker-chat .bf-joker-compose-row {
  direction: rtl;
  align-items: center !important;
  gap: 9px !important;
}

.bf-joker-chat .bf-joker-gallery-button,
.bf-joker-chat .bf-joker-send-button {
  display: grid !important;
  flex: 0 0 44px !important;
  width: 44px !important;
  height: 44px !important;
  place-items: center !important;
  border: 1px solid rgba(123, 134, 255, .62) !important;
  border-radius: 50% !important;
  color: #e8e9ff !important;
  background: radial-gradient(circle at 35% 25%, #17255a, #080d22 72%) !important;
  box-shadow: 0 0 13px rgba(70, 91, 255, .2) !important;
}

.bf-joker-chat .bf-joker-send-button:not(:disabled) {
  border-color: rgba(208, 116, 255, .74) !important;
  background: linear-gradient(145deg, #392080, #121d50) !important;
  box-shadow: 0 0 14px rgba(187, 82, 255, .28) !important;
}

.bf-joker-chat .bf-joker-send-button:disabled {
  color: rgba(196, 185, 223, .62) !important;
  background: radial-gradient(circle at 35% 25%, #11182f, #070b19 72%) !important;
  box-shadow: none !important;
}

.bf-joker-chat .bf-joker-input-shell {
  min-width: 0;
  min-height: 48px;
  align-items: center !important;
  padding: 0 8px !important;
  border: 1px solid rgba(196, 100, 255, .74) !important;
  border-radius: 26px !important;
  background: linear-gradient(100deg, rgba(22, 11, 44, .97), rgba(8, 17, 41, .98)) !important;
  box-shadow: 0 0 12px rgba(190, 63, 255, .2), inset 0 0 12px rgba(126, 57, 195, .15) !important;
}

.bf-joker-chat .bf-joker-textarea {
  min-height: 40px !important;
  padding: 10px 5px !important;
  color: #f1eaff !important;
  font-size: 14px !important;
}

.bf-joker-chat .bf-joker-textarea::placeholder {
  color: #a9a1bd !important;
}

.bf-joker-chat .bf-joker-mic-button {
  flex: 0 0 36px !important;
  width: 36px !important;
  color: #d575ff !important;
}

@media (max-width: 360px) {
  .bf-joker-chat .bf-joker-notice {
    padding-inline: 9px !important;
  }

  .bf-joker-chat .bf-joker-scroll {
    padding-inline: 8px !important;
  }
}

.bf-room-portal.bf-joker-chat {
  transform: translateY(calc(62px + env(safe-area-inset-top))) !important;
  height: calc(var(--bf-visual-height) - 62px - env(safe-area-inset-top)) !important;
  max-height: calc(var(--bf-visual-height) - 62px - env(safe-area-inset-top)) !important;
  overflow: hidden !important;
  background-color: transparent !important;
  background-image: none !important;
  color-scheme: dark;
}

.bf-joker-wallpaper {
  position: fixed;
  z-index: 1199;
  overflow: hidden;
  pointer-events: none;
  background-color: #050713;
  background-image:
    linear-gradient(180deg, rgba(3, 7, 19, .14), rgba(3, 7, 19, .24) 48%, rgba(3, 7, 19, .66)),
    var(--joker-background);
  background-repeat: no-repeat, no-repeat;
  background-position: center center, center center;
  background-size: 100% 100%, cover;
}

.bf-joker-topbar {
  position: fixed !important;
  right: 0;
  left: 0;
  z-index: 1301;
  box-sizing: border-box;
  display: flex;
  flex: 0 0 auto;
  direction: ltr;
  align-items: center;
  justify-content: space-between;
  min-height: calc(62px + env(safe-area-inset-top));
  padding: calc(env(safe-area-inset-top) + 4px) 14px 8px;
  overflow: hidden;
  border-bottom: 1px solid rgba(110, 207, 255, .24);
  background-image:
    radial-gradient(ellipse at 50% 0%, rgba(38, 115, 208, .2), transparent 58%),
    radial-gradient(ellipse at 82% 65%, rgba(169, 74, 255, .12), transparent 46%),
    linear-gradient(125deg, #050918 0%, #101a3b 52%, #080a20 100%);
  background-position: center;
  background-size: cover;
  text-shadow: 0 2px 9px #05030d;
}

.bf-joker-topbar .bf-joker-close {
  display: grid;
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 1px solid rgba(174, 108, 255, .62);
  border-radius: 50%;
  color: #fff;
  background: radial-gradient(circle at 35% 25%, #17245b, #080d22 72%);
  box-shadow: 0 0 12px rgba(85, 87, 255, .2);
  cursor: pointer;
}

.bf-joker-topbar .bf-joker-brand {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #fff;
}

.bf-joker-topbar .bf-joker-brand-name {
  position: relative;
  font-family: "Apple Chancery", "URW Chancery L", "Segoe Script", cursive;
  font-size: clamp(25px, 7vw, 32px);
  font-style: italic;
  letter-spacing: -1.4px;
  line-height: 1;
  white-space: nowrap;
}

.bf-joker-topbar .bf-joker-brand-name i {
  color: #d263ff;
  font-weight: 700;
}

.bf-joker-topbar .bf-joker-brand-name b {
  position: absolute;
  top: -15px;
  left: 44%;
  color: #eee8ff;
  font-family: serif;
  font-size: 16px;
  font-weight: 400;
}

.bf-joker-topbar .bf-joker-brand-subtitle {
  margin-top: 5px;
  color: #d6d1ed;
  font-size: 8px;
  letter-spacing: 2.2px;
}

.bf-joker-topbar .bf-joker-more-mark {
  display: grid;
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 1px solid rgba(123, 134, 255, .55);
  border-radius: 50%;
  color: #e8e9ff;
  background: radial-gradient(circle at 35% 25%, #17255a, #080d22 72%);
}

.bf-joker-chat .bf-joker-group-title {
  position: relative;
  font-size: 0 !important;
  line-height: 1.25;
}

.bf-joker-chat .bf-joker-group-title::after {
  content: "Joker";
  color: #f7f1ff;
  font-size: 15px;
  font-weight: 900;
}

.bf-joker-chat .bf-joker-scroll {
  background-color: transparent !important;
  background-image: none !important;
  background-attachment: initial !important;
  background-position: initial !important;
  background-size: auto !important;
}

.bf-joker-chat .bf-joker-bubble.is-mine {
  border: 1px solid rgba(207, 130, 255, .64) !important;
  background: linear-gradient(145deg, rgba(61, 44, 131, .96), rgba(14, 28, 75, .97)) !important;
  box-shadow: 0 5px 18px rgba(119, 60, 214, .28), inset 0 0 16px rgba(173, 101, 255, .08) !important;
}

.bf-joker-chat .bf-joker-bubble.is-theirs {
  border: 1px solid rgba(91, 209, 255, .44) !important;
  background: linear-gradient(145deg, rgba(8, 25, 48, .95), rgba(9, 11, 31, .96)) !important;
  box-shadow: 0 5px 18px rgba(0, 0, 0, .36), inset 0 0 12px rgba(71, 111, 188, .08) !important;
}

.bf-joker-chat .bf-joker-bubble > .bf-joker-meta {
  position: static !important;
  inset: auto !important;
  align-self: stretch !important;
  box-sizing: border-box;
  width: 100% !important;
  margin-top: 4px !important;
  justify-content: flex-start !important;
  flex-wrap: wrap;
  row-gap: 2px !important;
  line-height: 1.35 !important;
}

.bf-joker-chat .bf-joker-bubble > .bf-joker-message-copy {
  padding-bottom: 0 !important;
}

.bf-joker-chat .bf-joker-sender-name {
  color: #d58cff !important;
}

.bf-joker-chat .bf-joker-composer .bf-joker-compose-row {
  direction: rtl;
}
