/* Shared CHAT_EA_1 presentation for LP_EA consulting pages. */
.chat-item-wrapper-skeleton {
  display: none !important;
}

.mobile-chat-block {
  display: none;
  position: relative;
  width: 100%;
  cursor: pointer;
  border-radius: 24px;
  overflow: hidden;
}

.mobile-chat-block .chat {
  height: 100%;
}

.chat {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 20px;
  background: #fff;
  box-shadow: var(--chat-shadow-md, 0 8px 32px rgba(0, 0, 0, 0.10));
}

.chat-head {
  position: relative;
  overflow: hidden;
  padding: 22px 24px;
  color: #fff;
  background: linear-gradient(135deg, var(--chat-dark, #134e4a) 0%, var(--chat-primary, #0d9488) 62%, var(--chat-online, #14b8a6) 100%);
}

.chat-head::before {
  content: "";
  position: absolute;
  top: -65px;
  right: -45px;
  width: 180px;
  height: 180px;
  pointer-events: none;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.14) 0%, transparent 70%);
}

.chat-head h2 {
  position: relative;
  margin: 0 0 10px;
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.25;
}

.online-experts {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
}

.expert-avatars {
  position: relative;
  display: flex;
  flex: 0 0 auto;
  padding-right: 12px;
}

.expert-avatars .avatar {
  width: 34px;
  height: 34px;
  margin-right: -12px;
  object-fit: cover;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #fff;
}

.expert-avatars .online-indicator {
  position: absolute;
  right: -2px;
  bottom: 0;
  width: 12px;
  height: 12px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: var(--chat-online, #14b8a6);
  animation: chatPulse 2s ease-in-out infinite;
}

.expert-online-text {
  margin: 0;
  color: rgba(255, 255, 255, 0.92);
  font-size: 14px;
  line-height: 1.35;
}

.chat-trust-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 12px;
  overflow: hidden;
  white-space: nowrap;
  background: linear-gradient(90deg, var(--chat-light, #f0fdfa) 0%, #fff 50%, var(--chat-light, #f0fdfa) 100%);
  border-bottom: 1px solid var(--chat-border-light, #e8eff5);
}

.trust-label,
.trust-city {
  color: var(--chat-text-secondary, #4b5e6d);
  font-size: 13px;
  font-weight: 600;
}

.trust-stars {
  display: flex;
  align-items: center;
  gap: 2px;
}

.trust-star {
  width: 15px;
  height: 15px;
}

.trust-city {
  max-width: 40%;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat-value-prop {
  padding: 9px 14px;
  background: #fff;
  border-bottom: 1px solid var(--chat-border-light, #e8eff5);
}

.chat-value-prop-title {
  margin: 0 0 6px;
  color: var(--chat-text, #1a2332);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.3;
}

.chat-value-prop-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.chat-value-prop-list li {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin-bottom: 4px;
  color: var(--chat-text-secondary, #4b5e6d);
  font-size: 12px;
  line-height: 1.35;
}

.chat-value-prop-list li:last-child {
  margin-bottom: 0;
}

.value-prop-check {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
  margin-top: 1px;
}

.chat-body {
  flex: 1;
  height: auto;
  min-height: 0;
  overflow: auto;
  background: #fff;
}

.chat-list {
  display: flex;
  flex-direction: column;
  padding: 20px;
}

.chat-item-wrapper {
  display: flex;
  align-items: flex-end;
  max-width: 100%;
  margin-bottom: 14px;
  gap: 10px;
}

.chat-item-wrapper.right {
  align-self: flex-end;
}

.chat-item-avatar {
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
  overflow: hidden;
  border-radius: 50%;
}

.chat-item-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.chat-item-content {
  display: flex;
  flex-direction: column;
  max-width: calc(100% - 44px);
}

.chat-item-wrapper.right .chat-item-content {
  max-width: 100%;
}

.chat-author-label {
  margin-bottom: 4px;
  color: var(--chat-text-muted, #7c8d9e);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.2;
}

.chat-item {
  min-height: 20px;
  padding: 9px 11px;
  color: var(--chat-text, #1a2332);
  background: var(--chat-bubble-bg, #f1f5f9);
  border-radius: 10px 10px 10px 2px;
}

.chat-item-wrapper.right .chat-item,
.right .chat-item {
  background: #fff;
  border: 1px solid var(--chat-border-light, #e8eff5);
  border-radius: 10px 10px 2px 10px;
}

.chat-item label {
  margin-bottom: 4px;
  color: var(--chat-text, #1a2332);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
}

.chat-item .message {
  white-space: pre-wrap;
  color: var(--chat-text, #1a2332);
  font-size: 14px;
  line-height: 1.45;
}

.chat-item .message.error-message {
  color: var(--chat-danger, #dc3545);
}

.chat-item .message.typing {
  display: flex;
  align-items: center;
  gap: 4px;
}

.chat-item .message.typing span {
  width: 5px;
  height: 5px;
  display: inline-block;
  border-radius: 50%;
  background: var(--chat-text-muted, #7c8d9e);
  opacity: 0.45;
}

.chat-item .message.typing span:nth-child(1) {
  animation: chatTyping 1s infinite 0s;
}

.chat-item .message.typing span:nth-child(2) {
  animation: chatTyping 1s infinite 0.2s;
}

.chat-item .message.typing span:nth-child(3) {
  animation: chatTyping 1s infinite 0.4s;
}

.chat-input-wrapper {
  padding: 16px 20px;
  background: #fff;
  border-top: 1px solid var(--chat-border-light, #e8eff5);
  box-shadow: var(--chat-shadow-sm, 0 -2px 12px rgba(0, 0, 0, 0.04));
}

.chat-input-group {
  position: relative;
  min-height: 60px;
  margin-bottom: 10px;
}

.chat-input-group textarea {
  width: 100%;
  min-height: 64px;
  display: block;
  resize: none;
  padding: 14px 16px;
  color: var(--chat-text, #1a2332);
  border: 1px solid var(--chat-border, #d1dde6);
  border-radius: 20px;
  background: #fff;
  font-size: 15px;
  line-height: 1.4;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.chat-input-group textarea:focus,
.chat-input-group textarea.focused {
  border-color: var(--chat-primary, #0d9488);
  box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.16);
}

.chat-footer {
  padding: 0;
}

.chat .btn-send {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 12px 22px;
  color: #fff;
  border: 0;
  border-radius: 999px;
  background: var(--chat-primary, #0d9488);
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.chat .btn-send:hover {
  background: var(--chat-primary-hover, var(--chat-primary, #0d9488));
  transform: translateY(-1px);
}

.tooltip-container {
  position: relative;
  width: 100%;
}

.tooltip {
  position: absolute;
  bottom: 100%;
  left: 50%;
  z-index: 10;
  margin-bottom: 10px;
  padding: 8px 14px;
  visibility: hidden;
  opacity: 0;
  color: #fff;
  white-space: nowrap;
  border-radius: 8px;
  background: var(--chat-dark, #134e4a);
  box-shadow: var(--chat-shadow-md, 0 8px 32px rgba(0, 0, 0, 0.10));
  transform: translateX(-50%);
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.tooltip.visible {
  visibility: visible;
  opacity: 1;
}

.tooltip-arrow {
  position: absolute;
  bottom: -8px;
  left: 50%;
  width: 0;
  height: 0;
  border-top: 8px solid var(--chat-dark, #134e4a);
  border-right: 8px solid transparent;
  border-left: 8px solid transparent;
  transform: translateX(-50%);
}

.bubble-chat-container,
.bubble-chat-button,
.bubble-chat-button.hidden {
  display: none;
}

.dialog-overlay,
.notify {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(19, 78, 74, 0.42);
}

.notify .dialog-content {
  position: relative;
  width: min(440px, calc(100vw - 32px));
  overflow: hidden;
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--chat-shadow-md, 0 8px 32px rgba(0, 0, 0, 0.10));
}

.notify .dialog-head {
  padding: 24px;
  background: var(--chat-light, #f0fdfa);
}

.dialog-head .online {
  display: flex;
  align-items: center;
  gap: 14px;
}

.dialog-head .avatars {
  display: flex;
  flex: 0 0 auto;
}

.dialog-head .avatar {
  width: 34px;
  height: 34px;
  margin-right: -10px;
  overflow: hidden;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #fff;
}

.dialog-head .avatar img,
.notify .image-avatar {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dialog-head .online-info h4 {
  margin: 0 0 2px;
  color: var(--chat-text, #1a2332);
  font-size: 16px;
  font-weight: 700;
}

.dialog-head .online-info p {
  margin: 0;
  color: var(--chat-text-secondary, #4b5e6d);
  font-size: 13px;
  line-height: 1.35;
}

.notify .dialog-body {
  padding: 28px 30px;
  text-align: center;
}

.notify .recap-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.notify .recap-avatar {
  position: relative;
  width: 96px;
  height: 96px;
  margin-bottom: 16px;
  overflow: visible;
  border-radius: 50%;
}

.notify .recap-avatar .image-avatar {
  border-radius: 50%;
}

.notify .recap-avatar .shield {
  position: absolute;
  right: -2px;
  bottom: -2px;
  width: 30px;
  height: 30px;
}

.notify .recap-info h4 {
  margin: 0 0 6px;
  color: var(--chat-text, #1a2332);
  font-size: 20px;
  font-weight: 700;
}

.notify .recap-info p {
  margin: 0;
  color: var(--chat-text-secondary, #4b5e6d);
  font-size: 14px;
}

.notify .recap-rate {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: 12px;
}

.notify .stars {
  display: flex;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--chat-primary, #0d9488);
}

.notify h2 {
  max-width: 340px;
  margin: 28px auto;
  color: var(--chat-text, #1a2332);
  font-size: 22px;
  line-height: 1.25;
}

.notify .separator {
  height: 1px;
  margin: 0 0 24px;
  background: var(--chat-border-light, #e8eff5);
}

.notify .btn-primary {
  width: 100%;
  margin: 0;
}

.btn-close-dialog {
  position: absolute;
  top: 16px;
  right: 16px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.btn-close-chat-mobile {
  display: none;
}

@media (min-width: 1025px) {
  .hero-content-right#chatWrapper {
    display: flex;
    flex-direction: column;
    top: 96px;
    height: calc(100vh - 120px);
    max-height: 620px;
  }

  .hero-content-right#chatWrapper .chat-head.mobile,
  .hero-content-right#chatWrapper .btn-close-chat-mobile {
    display: none !important;
  }
}

@media (max-width: 1024px) {
  .hero {
    height: calc(var(--vh, 100vh) - 60px) !important;
    max-height: calc(var(--vh, 100vh) - 60px) !important;
    overflow: hidden;
  }

  .hero-content {
    position: relative;
    height: 100% !important;
    overflow: hidden;
  }

  .hero-content-left {
    width: 100% !important;
    max-width: 100% !important;
    padding-bottom: 300px !important;
  }

  .hero-content-left-text {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
  }

  .hero-content-left h1 {
    font-size: 30px !important;
    line-height: 1.15 !important;
    letter-spacing: 0 !important;
  }

  .hero-content-left h2,
  .hero-content-left .hero-description {
    font-size: 15px !important;
    line-height: 1.4 !important;
  }

  .hero-trust-indicators {
    display: none !important;
  }

  .mobile-chat-block {
    display: flex;
    flex-direction: column;
    position: absolute;
    right: 18px;
    bottom: 14px;
    left: 18px;
    z-index: 5;
    width: auto;
    height: 270px;
    min-height: 270px;
  }

  .mobile-chat-block .chat-input-wrapper {
    padding: 8px;
    background: var(--chat-bg-off-white, #f8fafb);
  }

  .mobile-chat-block .chat {
    min-height: 0;
  }

  .mobile-chat-block .chat-body {
    flex: 1;
    height: auto;
    min-height: 0;
  }

  .mobile-chat-block .chat-head {
    padding: 10px 12px;
  }

  .mobile-chat-block .chat-head h2 {
    margin-bottom: 4px;
    font-size: 14px;
  }

  .mobile-chat-block .online-experts {
    gap: 10px;
  }

  .mobile-chat-block .expert-avatars .avatar {
    width: 24px;
    height: 24px;
    margin-right: -8px;
  }

  .mobile-chat-block .expert-online-text {
    font-size: 12px;
  }

  .mobile-chat-block .chat-trust-bar {
    padding: 4px 8px;
  }

  .mobile-chat-block .trust-label,
  .mobile-chat-block .trust-city {
    font-size: 11px;
  }

  .mobile-chat-block .trust-star {
    width: 12px;
    height: 12px;
  }

  .mobile-chat-block .chat-value-prop {
    display: none;
  }

  .mobile-chat-block .chat-list {
    padding: 8px 10px;
  }

  .mobile-chat-block .chat-input-group {
    min-height: 48px;
    margin-bottom: 6px;
  }

  .mobile-chat-block .chat-input-group textarea {
    min-height: 48px;
    padding: 10px 12px;
  }

  .hero-content-right#chatWrapper {
    display: none;
  }

  .hero-content-right#chatWrapper.chat-modal-wrapper {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    width: 100%;
    max-width: none;
    height: calc(var(--vh, 100vh));
    min-height: 0;
    padding: 0;
    border-radius: 0;
    background: #fff;
    transform: none;
  }

  .chat-modal-wrapper .chat {
    height: 100%;
    border-radius: 0;
  }

  .chat-modal-wrapper .chat-head.hidden-mobile {
    display: none !important;
  }

  .chat-modal-wrapper .chat-head.mobile {
    display: block !important;
    min-height: 74px;
    padding: 10px 48px 10px 52px;
    border-radius: 0;
  }

  .chat-modal-wrapper .chat-head.mobile h2 {
    margin-bottom: 4px;
    font-size: 14px;
  }

  .chat-modal-wrapper .online-experts {
    gap: 10px;
  }

  .chat-modal-wrapper .expert-avatars .avatar {
    width: 26px;
    height: 26px;
    margin-right: -9px;
  }

  .chat-modal-wrapper .expert-online-text {
    font-size: 12px;
  }

  .chat-modal-wrapper .btn-close-chat-mobile {
    position: absolute;
    top: 50%;
    left: 12px;
    z-index: 2;
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    border: 0;
    background: transparent;
    transform: translateY(-50%);
  }

  .chat-modal-wrapper .btn-close-chat-mobile img {
    width: 28px;
    height: 28px;
    filter: brightness(0) invert(1);
  }

  .chat-modal-wrapper .chat-trust-bar {
    padding: 5px 10px;
  }

  .chat-modal-wrapper .chat-value-prop {
    padding: 6px 10px;
  }

  .chat-modal-wrapper .chat-value-prop-title {
    margin-bottom: 3px;
    font-size: 12px;
  }

  .chat-modal-wrapper .chat-value-prop-list li {
    margin-bottom: 2px;
    font-size: 11px;
  }

  .chat-modal-wrapper .chat-list {
    padding: 10px 12px;
  }

  .chat-modal-wrapper .chat-item-wrapper {
    gap: 6px;
    margin-bottom: 8px;
  }

  .chat-modal-wrapper .chat-item-avatar {
    width: 24px;
    height: 24px;
  }

  .chat-modal-wrapper .chat-author-label {
    margin-bottom: 2px;
    font-size: 10px;
  }

  .chat-modal-wrapper .chat-item {
    padding: 8px 10px;
  }

  .chat-modal-wrapper .chat-item .message {
    font-size: 13px;
  }

  .chat-modal-wrapper .chat-input-wrapper {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    padding: 8px 10px 10px;
    background: var(--chat-bg-off-white, #f8fafb);
  }

  .chat-modal-wrapper .chat-input-group {
    flex: 1;
    min-width: 0;
    min-height: 44px;
    margin-bottom: 0;
  }

  .chat-modal-wrapper .chat-input-group textarea {
    min-height: 44px;
    padding: 10px 12px;
    font-size: 14px;
  }

  .chat-modal-wrapper .chat-footer {
    flex: 0 0 auto;
  }

  .chat-modal-wrapper .chat .btn-send {
    width: 44px;
    min-width: 44px;
    min-height: 44px;
    padding: 0;
    border-radius: 50%;
  }

  .chat-modal-wrapper .chat .btn-send span {
    display: none;
  }

  .chat-modal-wrapper .chat .btn-send::after {
    content: "";
    width: 20px;
    height: 20px;
    display: block;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='white' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M5 12h14M12 5l7 7-7 7'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
  }

  .bubble-chat-container {
    position: fixed;
    right: 0;
    bottom: 24px;
    left: 0;
    z-index: 999;
    display: block;
    width: 100%;
    padding: 0 20px;
    pointer-events: none;
    animation: chatFadeIn 0.3s ease;
  }

  .bubble-chat-container.hidden,
  .block-scroll .bubble-chat-container {
    display: none !important;
  }

  .bubble-chat-container > div {
    pointer-events: auto;
  }

  .bubble-chat-message {
    max-width: calc(100% - 76px);
    margin: 0 8px 8px 0;
    padding: 10px 12px;
    color: #fff;
    border-radius: 10px;
    background: var(--chat-dark, #134e4a);
    box-shadow: var(--chat-shadow-md, 0 8px 32px rgba(0, 0, 0, 0.10));
    font-size: 12px;
    line-height: 1.35;
  }

  .bubble-chat-button {
    width: 60px;
    min-width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 50%;
    background: var(--chat-primary, #0d9488);
    box-shadow: 0 8px 20px rgba(13, 148, 136, 0.32);
    cursor: pointer;
  }

  .bubble-chat-button img {
    width: 88%;
    height: 88%;
    object-fit: cover;
    border-radius: 50%;
  }

  .notify {
    align-items: flex-start;
    padding: 16px;
    overflow: auto;
  }

  .notify .dialog-head,
  .notify .dialog-body {
    padding: 20px 18px;
  }

  .notify .recap-avatar {
    width: 76px;
    height: 76px;
  }

  .notify h2 {
    margin: 22px auto;
    font-size: 19px;
  }
}

@media (max-height: 450px) {
  .chat-modal-wrapper .chat-value-prop {
    display: none;
  }

  .chat-modal-wrapper .chat-head.mobile {
    min-height: 62px;
    padding-top: 8px;
    padding-bottom: 8px;
  }

  .chat-modal-wrapper .chat-trust-bar {
    display: none;
  }
}

@keyframes chatPulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.75;
    transform: scale(1.15);
  }
}

@keyframes chatTyping {
  0%, 60%, 100% {
    opacity: 0.35;
    transform: translateY(0);
  }
  30% {
    opacity: 1;
    transform: translateY(-2px);
  }
}

@keyframes chatFadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
