.cindy-help-trigger,
#cindy-help-dialog {
  --help-ink: #0d395e;
  --help-border: #dce6ec;
  --help-surface: #f3f7fa;
  color: var(--help-ink);
  font-family: "Be Vietnam Pro", Arial, sans-serif;
}

.cindy-help-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: 24px;
  background: transparent;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
}

.topbar .cindy-help-header { flex: 0 0 auto; }
.cindy-help-header:hover { background: var(--help-surface); }
.cindy-help-trigger svg { flex: 0 0 20px; }

.cindy-help-floating {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 300;
  padding-inline: 15px;
  min-height: 48px;
  color: #fff;
  background: var(--help-ink);
  box-shadow: 0 5px 18px #0d395e39;
}

.cindy-help-floating svg { color: #e9df73; }
.cindy-help-floating:hover { background: #164e76; }
body[data-cindy-chat-open] .cindy-help-floating { visibility: hidden; }

#cindy-help-dialog:not([open]),
#cindy-help-dialog [hidden] { display: none; }

#cindy-help-dialog {
  position: fixed;
  inset: auto max(16px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) auto;
  width: min(364px, calc(100% - 32px));
  max-width: none;
  max-height: calc(100vh - 32px);
  max-height: calc(100dvh - 32px);
  box-sizing: border-box;
  z-index: 301;
  margin: 0;
  padding: 0;
  overflow: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--help-border);
  border-radius: 17px;
  background: #fff;
  box-shadow: 0 12px 42px #0d395e30;
}

#cindy-help-dialog::backdrop { background: #0d253726; backdrop-filter: none; }

.cindy-help-bar {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 8px 8px 8px 16px;
  border-bottom: 1px solid var(--help-border);
}

#cindy-help-title {
  flex: 1;
  margin: 0;
  color: var(--help-ink);
  font: 700 18px/1.35 "Be Vietnam Pro", Arial, sans-serif;
}

.cindy-help-bar button {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: var(--help-ink);
  background: transparent;
  cursor: pointer;
}

.cindy-help-bar button:hover { background: var(--help-surface); }
.cindy-help-trigger:focus-visible,
#cindy-help-dialog :is(a, button):focus-visible { outline: 2px solid #9c7b15; outline-offset: 2px; }

.cindy-help-options { padding: 14px; }

.cindy-help-live {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 51px;
  padding: 0 12px;
  border: 0;
  border-radius: 10px;
  color: #fff;
  background: var(--help-ink);
  text-align: left;
  font: 600 14px/1.4 "Be Vietnam Pro", Arial, sans-serif;
  cursor: pointer;
}

.cindy-help-live span { flex: 1; }
.cindy-help-live svg:first-child { color: #e9df73; }
.cindy-help-live:hover { background: #164e76; }
.cindy-help-live:disabled { opacity: .65; cursor: default; }
.cindy-help-status { margin: 10px 0 0; color: #425d70; font-size: 13px; line-height: 1.5; }

.cindy-help-channels {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  margin: 9px 0 0;
  padding: 0;
  list-style: none;
}

.cindy-help-channel {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 47px;
  box-sizing: border-box;
  padding: 5px 6px;
  border: 1px solid var(--help-border);
  border-radius: 9px;
  background: #fff;
  color: var(--help-ink);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.cindy-help-channel:hover { background: var(--help-surface); }
.cindy-help-channel-icon {
  display: grid;
  place-items: center;
  flex: 0 0 32px;
  height: 32px;
  border-radius: 7px;
  color: #1b5c8b;
  background: #edf4fb;
}

.cindy-help-channel-icon svg { width: 17px; height: 17px; }
.cindy-help-whatsapp .cindy-help-channel-icon,
.cindy-help-imessage .cindy-help-channel-icon { color: #137445; background: #e9f7ee; }
.cindy-help-messenger .cindy-help-channel-icon { color: #5434a5; background: #f1edfc; }
.cindy-help-email .cindy-help-channel-icon { color: #935921; background: #fcf1e5; }

#cindy-help-dialog[data-show-chat] {
  width: min(390px, calc(100% - 32px));
  overflow: hidden;
}

.cindy-help-frame {
  display: block;
  width: 100%;
  height: min(540px, calc(100vh - 94px));
  height: min(540px, calc(100dvh - 94px));
  border: 0;
}

@media (min-width: 1180px) and (max-width: 1359px) {
  .topbar:has(> .cindy-help-header) { gap: 8px; }
  .topbar:has(> .cindy-help-header) .brand { flex-basis: 148px; width: 148px; }
  .topbar:has(> .cindy-help-header) #menu .nav-button { padding-inline: 8px; font-size: 13px; }
}

@media (min-width: 1360px) and (max-width: 1599px) {
  .topbar:has(> .cindy-help-header) { gap: 10px; }
  .topbar:has(> .cindy-help-header) .brand { flex-basis: 170px; width: 170px; }
  .topbar:has(> .cindy-help-header) #menu .nav-button { padding-inline: 10px; font-size: 14px; }
}

@media (max-width: 600px), (min-width: 1180px) and (max-width: 1279px) {
  .topbar .cindy-help-header { width: 44px; padding: 0; }
  .topbar .cindy-help-header span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
}
