  /* Botão flutuante */
  .gb-chat-toggle {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 100000;
    width: 60px;
    height: 60px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    box-shadow: 0 6px 18px rgba(0, 0, 0, .25);
    cursor: pointer;
    display: none;
    transition: transform .2s ease;
  }

  .gb-chat-toggle.is-ready {
    display: block;
  }

  .gb-chat-toggle:hover {
    transform: scale(1.06);
  }

  .gb-chat-toggle img {
    display: block;
    width: 60px;
    height: 60px;
    transition: opacity .2s ease, transform .2s ease;
  }

  .gb-chat-toggle::after {
    content: "\00d7";
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: #262626;
    color: #fff;
    font: 300 38px/60px Arial, sans-serif;
    text-align: center;
    opacity: 0;
    transform: rotate(-90deg);
    transition: opacity .2s ease, transform .2s ease;
  }

  .gb-chat-toggle.is-open img {
    opacity: 0;
    transform: rotate(90deg);
  }

  .gb-chat-toggle.is-open::after {
    opacity: 1;
    transform: rotate(0);
  }

  /* Base do widget */
  #cvchat,
  #cvchat * {
    box-sizing: border-box;
  }

  #cvchat {
    font-family: Heebo, Roboto, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.4;
    color: #333;
  }

  #cvchat .chat-cta {
    display: none !important;
  }

  /* Painel */
  #cvchat .chat-content {
    position: fixed;
    right: 24px;
    bottom: 96px;
    z-index: 99999;
    width: 360px;
    height: min(560px, calc(100vh - 120px));
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 12px 40px rgba(0, 0, 0, .25);
    display: none;
  }

  #cvchat .chat-content.active {
    display: flex;
    flex-direction: column;
    animation: gbChatIn .25s ease;
  }

  @keyframes gbChatIn {
    from {
      opacity: 0;
      transform: translateY(16px);
    }

    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  #cvchat .chat-content>div {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
  }

  /* Tela inicial (formulário) */
  #cvchat .chat-start {
    display: none;
  }

  #cvchat .chat-start.active {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
  }

  #cvchat .chat-start h2 {
    margin: 0;
    padding: 24px 56px 24px 24px;
    color: #fff;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.3;
  }

  #cvchat .chat-form {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
    background: #fff;
    border-radius: 16px 16px 0 0;
  }

  #cvchat .chat-form-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin: 0;
  }

  #cvchat .chat-form-content>div {
    display: flex;
    flex-direction: column;
    gap: 6px;
  }

  #cvchat .chat-form-content label {
    margin: 0;
    font-size: 13px;
    font-weight: 500;
    color: #555;
  }

  #cvchat .chat-form-content input,
  #cvchat .chat-form-content select {
    width: 100%;
    height: 44px;
    margin: 0;
    padding: 0 14px;
    border: 1px solid #dcdce0;
    border-radius: 8px;
    background-color: #fff;
    font: inherit;
    color: #333;
    outline: none;
    transition: border-color .2s ease, box-shadow .2s ease;
  }

  #cvchat .chat-form-content select {
    -webkit-appearance: none;
    appearance: none;
    padding-right: 36px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%23666' stroke-width='2' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    cursor: pointer;
  }

  #cvchat .chat-form-content input:focus,
  #cvchat .chat-form-content select:focus {
    border-color: #B95100;
    box-shadow: 0 0 0 3px rgba(185, 81, 0, .15);
  }

  #cvchat .chat-form-content .small {
    font-size: 12px;
    color: #888;
  }

  #cvchat .chat-form-bt {
    width: 100%;
    height: 46px;
    margin-top: 4px;
    border: 0;
    border-radius: 8px;
    color: #fff;
    font: inherit;
    font-weight: 500;
    font-size: 15px;
    cursor: pointer;
    transition: filter .2s ease;
  }

  #cvchat .chat-form-bt:hover {
    filter: brightness(1.15);
  }

  /* Carregando */
  #cvchat .chat-loading {
    display: none;
  }

  #cvchat .chat-loading.active {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
  }

  #cvchat .chat-loading img {
    width: 64px;
    height: 64px;
  }

  /* Conversa */
  #cvchat .chat-dialog {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
  }

  #cvchat .dialog-header {
    padding: 18px 56px 18px 24px;
    color: #fff;
  }

  #cvchat .dialog-header small {
    display: block;
    font-size: 12px;
    opacity: .8;
  }

  #cvchat .dialog-header h5 {
    margin: 2px 0 0;
    font-size: 17px;
    font-weight: 500;
    color: #fff;
  }

  #cvchat .dialog-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    background: #f5f5f7;
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  #cvchat .chat-message-line {
    display: flex;
  }

  #cvchat .chat-message-line.baloon-right {
    justify-content: flex-end;
  }

  #cvchat .chat-message {
    max-width: 80%;
    padding: 8px 12px;
    border-radius: 14px 14px 14px 4px;
    background: #fff;
    color: #333;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .08);
    word-wrap: break-word;
    overflow-wrap: anywhere;
  }

  #cvchat .baloon-right .chat-message {
    border-radius: 14px 14px 4px 14px;
    background: var(--ballonBgColor, #B95100);
    color: var(--ballonTxColor, #fff);
  }

  #cvchat .chat-message .time {
    margin-bottom: 2px;
    font-size: 11px;
    opacity: .6;
  }

  #cvchat .chat-message img {
    display: block;
    max-width: 100%;
    border-radius: 8px;
  }

  #cvchat .chat-message a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: inherit;
  }

  #cvchat .chat-message-finish {
    align-self: center;
    margin-top: 8px;
    padding: 6px 12px;
    border-radius: 12px;
    background: #e6e6ea;
    font-size: 12px;
    color: #666;
  }

  #cvchat .dialog-actions {
    display: flex;
    gap: 8px;
    padding: 12px;
    background: #fff;
    border-top: 1px solid #eee;
  }

  #cvchat #dialog-action-input {
    flex: 1;
    min-width: 0;
    height: 42px;
    margin: 0;
    padding: 0 16px;
    border: 1px solid #dcdce0;
    border-radius: 21px;
    font: inherit;
    color: #333;
    outline: none;
  }

  #cvchat #dialog-action-input:focus {
    border-color: #B95100;
  }

  #cvchat #dialog-action-send {
    height: 42px;
    padding: 0 18px;
    border: 0;
    border-radius: 21px;
    color: #fff;
    font: inherit;
    font-weight: 500;
    cursor: pointer;
  }

  #cvchat #dialog-action-input:disabled,
  #cvchat #dialog-action-send:disabled {
    opacity: .5;
    cursor: not-allowed;
  }

  /* Celular */
  @media (max-width: 480px) {
    .gb-chat-toggle {
      right: 16px;
      bottom: 16px;
    }

    #cvchat .chat-content {
      left: 12px;
      right: 12px;
      bottom: 88px;
      width: auto;
      height: calc(100vh - 104px);
      max-height: 600px;
    }
  }
