/* Sales chats — club chat colours, two labelled tabs. */

/* The chat fills the window. The page itself does not scroll. */
body.rcs-pilot-page.rcs-sales-chats-page {
  overflow-x: hidden;
  overflow-y: hidden;
  height: 100dvh;
  max-height: 100dvh;
  min-height: 0;
  padding-bottom: 0 !important;
}

body.rcs-sales-chats-page .rcs-pilot-scene {
  box-sizing: border-box;
  height: 100dvh;
  max-height: 100dvh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding-top: calc(var(--rcs-pilot-topper-h, 56px) + 15px);
  padding-bottom: calc(56px + var(--rcs-safe-bottom, env(safe-area-inset-bottom, 0px)));
}

@media (min-width: 960px) {
  body.rcs-sales-chats-page .rcs-pilot-scene {
    padding-bottom: calc(92px + var(--rcs-safe-bottom, env(safe-area-inset-bottom, 0px)));
  }
}

body.rcs-sales-chats-page .us-wrap {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding-bottom: 0;
}

body.rcs-sales-chats-page #page-main:not([hidden]) {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  margin: 0;
}

body.rcs-sales-chats-page #sc-root {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.rcs-sc-desk {
  --cc-accent: #38bdf8;
  --cc-accent-2: #22c55e;
  --cc-danger: #ef4444;
  --cc-bubble-me: rgba(14, 165, 233, 0.22);
  --cc-bubble-them: rgba(15, 23, 42, 0.72);
  --cc-panel: rgba(11, 18, 32, 0.82);
  --cc-rail: rgba(15, 23, 42, 0.72);
  --cc-chat-bg: transparent;
  --cc-border: rgba(148, 163, 184, 0.28);
  --cc-text: #f1f5f9;
  --cc-muted: #94a3b8;
  --cc-send: #38bdf8;
  --sc-sales: #f87171;
  --sc-buy: #38bdf8;
  color: var(--cc-text);
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  height: auto;
  max-height: 100%;
  overflow: hidden;
}

html[data-theme="light"] .rcs-sc-desk,
html:not([data-theme="dark"]) .rcs-sc-desk {
  --cc-bubble-me: rgba(186, 230, 253, 0.88);
  --cc-bubble-them: rgba(255, 255, 255, 0.88);
  --cc-panel: rgba(255, 255, 255, 0.78);
  --cc-rail: rgba(241, 245, 249, 0.72);
  --cc-border: rgba(15, 23, 42, 0.12);
  --cc-text: #0f172a;
  --cc-muted: #64748b;
  --cc-send: #0284c7;
  --sc-sales: #b91c1c;
  --sc-buy: #0369a1;
}

html[data-theme="dark"] .rcs-sc-desk {
  --sc-sales: #f87171;
  --sc-buy: #38bdf8;
}

.rcs-sc-desk .rcs-cc-tabs {
  border: 1px solid var(--cc-border);
  border-bottom: 0;
  border-radius: 18px 18px 0 0;
  overflow: visible;
  background: var(--cc-panel);
}

.rcs-sc-tab-pair {
  display: flex;
  min-width: 0;
  min-height: 48px;
  border-right: 1px solid var(--cc-border);
}

.rcs-sc-desk .rcs-sc-tab-pair .rcs-cc-tab--sales {
  flex: 1 1 auto;
  border-right: 0;
  border-top-left-radius: 0;
}

.rcs-sc-desk .rcs-cc-tab--sales {
  color: var(--sc-sales);
  font-weight: 800;
  border-top-left-radius: 0;
}

.rcs-sc-desk .rcs-cc-tab--buy {
  color: var(--sc-buy);
  font-weight: 800;
  border-top-right-radius: 17px;
}

.rcs-sc-desk .rcs-cc-tab.is-active,
html[data-theme="light"] .rcs-sc-desk .rcs-cc-tab.is-active,
html[data-theme="dark"] .rcs-sc-desk .rcs-cc-tab.is-active,
html:not([data-theme="dark"]) .rcs-sc-desk .rcs-cc-tab.is-active {
  background: #dc2626;
  color: #fff;
  box-shadow: none;
}

.rcs-sc-desk .rcs-cc-guests-shell {
  flex: 1;
  min-height: 0;
  border-radius: 0 0 18px 18px;
}

.rcs-sc-card__media {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  flex: 0 0 auto;
  width: 76px;
}

.rcs-sc-photo-line {
  background: none;
  border: 0;
  padding: 0;
  color: inherit;
  font: inherit;
  font-weight: 700;
  text-decoration: underline;
  cursor: pointer;
}

.rcs-sc-photo-mine {
  display: block;
  max-width: 220px;
  border-radius: 12px;
  border: 0;
  padding: 0;
  background: none;
  cursor: pointer;
}

.rcs-sc-photo-mine img {
  display: block;
  width: 100%;
  max-height: 180px;
  object-fit: cover;
  border-radius: 12px;
}

.rcs-sc-photo-del {
  margin-top: 6px;
}

.rcs-sc-side-dot {
  margin-left: 8px;
}

.rcs-sc-sheet {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  background: rgba(15, 23, 42, 0.55);
}

.rcs-sc-sheet[hidden] {
  display: none;
}

.rcs-sc-sheet__panel {
  width: min(440px, 100%);
  max-height: min(90dvh, 640px);
  overflow: auto;
  background: var(--rcs-panel, #0f172a);
  color: var(--rcs-text, #f8fafc);
  border: 1px solid var(--rcs-border, rgba(148, 163, 184, 0.35));
  border-radius: 16px;
  padding: 20px 20px 16px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
}

.rcs-sc-sheet__lead {
  margin: 0 0 14px;
  line-height: 1.45;
}

.rcs-sc-sheet__checks {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 4px;
  margin: 0 0 12px;
}

.rcs-sc-sheet__checks label.rcs-check {
  width: 100%;
  padding: 8px 4px;
  box-sizing: border-box;
}

.rcs-sc-sheet__city {
  display: block;
  width: 100%;
  box-sizing: border-box;
  margin: 0 0 12px;
  padding: 8px 10px;
}

.rcs-sc-sheet__preview {
  margin: 0 0 14px;
  line-height: 1.4;
}

.rcs-sc-keep {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  background: rgba(15, 23, 42, 0.55);
}

.rcs-sc-keep[hidden] {
  display: none;
}

.rcs-sc-keep__panel {
  width: min(420px, 100%);
  background: var(--rcs-panel, #0f172a);
  color: var(--rcs-text, #f8fafc);
  border: 1px solid var(--rcs-border, rgba(148, 163, 184, 0.35));
  border-radius: 16px;
  padding: 20px;
}

.rcs-sc-keep__panel p {
  margin: 0 0 16px;
  line-height: 1.45;
}

@media (min-width: 820px) {
  .rcs-sc-desk .rcs-cc-layout.is-split {
    grid-template-columns: minmax(300px, 360px) minmax(0, 1fr);
  }
}

.rcs-sc-desk .rcs-cc-side-item.rcs-sc-card {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.rcs-sc-thumb,
.rcs-sc-head__photo {
  object-fit: cover;
  background: rgba(148, 163, 184, 0.18);
  flex: 0 0 auto;
}

.rcs-sc-thumb {
  width: 56px;
  height: 56px;
  border-radius: 10px;
}

.rcs-sc-thumb.is-empty,
.rcs-sc-head__photo.is-empty {
  display: block;
}

.rcs-sc-card__body {
  flex: 1 1 auto;
  min-width: 0;
}

.rcs-sc-facts {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  column-gap: 12px;
  row-gap: 3px;
  margin-top: 6px;
  align-items: baseline;
}

.rcs-sc-fact {
  display: contents;
}

.rcs-sc-fact__k {
  color: var(--cc-muted);
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.35;
  white-space: nowrap;
}

.rcs-sc-fact__v {
  font-size: 0.84rem;
  font-weight: 650;
  line-height: 1.35;
  min-width: 0;
}

.rcs-sc-card__kind {
  display: block;
  width: 100%;
  margin: 0;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1.15;
  text-align: center;
  text-transform: uppercase;
  white-space: nowrap;
  color: #dc2626;
}

html[data-theme="dark"] .rcs-sc-card__kind {
  color: #ef4444;
}

.rcs-sc-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--cc-border);
  flex: 0 0 auto;
}

.rcs-sc-head__photo {
  width: 96px;
  height: 96px;
  border-radius: 12px;
}

.rcs-sc-head__main {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
}

.rcs-sc-head__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.rcs-sc-head__title {
  font-size: 1.05rem;
  line-height: 1.25;
  min-width: 0;
}

.rcs-sc-head .rcs-sc-facts {
  margin-top: 0;
}

.rcs-sc-head__ad {
  flex: 0 0 auto;
  text-decoration: none;
}

.rcs-sc-back {
  display: none;
}

@media (max-width: 819px) {
  .rcs-sc-back {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 36px;
    width: 36px;
    height: 36px;
    margin-top: 4px;
    padding: 0;
    border: 1px solid var(--cc-border);
    border-radius: 10px;
    background: transparent;
    color: var(--cc-text);
    font: inherit;
    font-weight: 800;
    cursor: pointer;
  }

  .rcs-sc-head__photo {
    width: 72px;
    height: 72px;
  }
}

.rcs-sc-menu {
  position: relative;
  flex: 0 0 auto;
  display: flex;
  padding: 0;
}

.rcs-sc-menu-btn {
  appearance: none;
  border: 0;
  border-right: 1px solid var(--cc-border);
  border-top-left-radius: 17px;
  background: transparent;
  color: var(--cc-text);
  font: inherit;
  font-weight: 800;
  padding: 0 16px;
  cursor: pointer;
}

.rcs-sc-menu-btn:hover,
.rcs-sc-menu-btn:focus-visible,
.rcs-sc-menu-btn[aria-expanded="true"] {
  background: color-mix(in srgb, var(--cc-text) 16%, transparent);
  color: var(--cc-text);
}

.rcs-sc-menu__drop {
  position: absolute;
  z-index: 8;
  top: 100%;
  left: 0;
  min-width: 180px;
  padding: 6px;
  border: 1px solid var(--cc-border);
  border-radius: 0 0 12px 12px;
  background: var(--cc-panel);
}

.rcs-sc-menu__drop .rcs-btn {
  width: 100%;
  justify-content: flex-start;
}

.rcs-sc-banner {
  margin: 8px 0 0;
  padding: 8px 12px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--cc-panel) 80%, #dc2626);
  font-weight: 700;
}

.rcs-sc-head__acts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.rcs-sc-blocked {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 8px 16px 16px;
}

.rcs-sc-blocked h2 {
  margin: 12px 0 6px;
  font-size: 1.15rem;
}

.rcs-sc-blocked__list {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
}

.rcs-sc-blocked__list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--cc-border);
}

.rcs-sc-blocked__list li div {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.rcs-sc-keep__panel h3 {
  margin: 0 0 8px;
}

.rcs-sc-keep__panel label.rcs-check {
  display: flex !important;
  width: 100%;
  margin-bottom: 4px;
}

.rcs-sc-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 12px 0;
  font-weight: 700;
}

.rcs-sc-field textarea,
.rcs-sc-field input[type="file"] {
  width: 100%;
  box-sizing: border-box;
  font: inherit;
  font-weight: 500;
}

.rcs-sc-sheet-err {
  margin: 0 0 10px;
  color: var(--rcs-error, #f87171);
  font-weight: 700;
}
