@media (max-width: 760px) {
  .lia-chat-page {
    overflow: hidden;
    background: #f7f3ec;
  }

  .lia-shell {
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    padding: 0;
  }

  .lia-desktop-frame {
    display: block;
    width: 100%;
    height: 100%;
  }

  .lia-desktop-sidebar {
    display: none;
  }

  .lia-chat-workspace,
  .lia-chat-card,
  .lia-settings-panel {
    width: 100%;
    height: 100%;
  }

  .lia-chat-card,
  .lia-settings-panel {
    border-radius: 0;
    border: 0;
    box-shadow: none;
  }

  .lia-chat-header,
  .lia-settings-header {
    min-height: 72px;
    padding: max(12px, env(safe-area-inset-top)) 14px 10px;
  }

  .lia-avatar {
    width: 40px;
    height: 40px;
  }

  .lia-header-text strong,
  .lia-settings-header strong {
    font-size: 18px;
  }

  .lia-header-text span,
  .lia-settings-header span {
    font-size: 12px;
  }

  .lia-header-icon {
    display: inline-grid;
  }

  .lia-header-button,
  .lia-settings-close {
    padding: 8px 12px;
  }

  .lia-messages {
    padding: 18px 14px;
  }

  .lia-bubble {
    max-width: 86%;
    font-size: 15px;
    padding: 12px 14px;
  }

  .lia-typing {
    padding: 0 14px 8px;
  }

  .lia-composer {
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 9px;
    padding: 12px 12px max(12px, env(safe-area-inset-bottom));
  }

  .lia-input {
    min-height: 44px;
    border-radius: 22px;
  }

  .lia-icon-button,
  .lia-send-button {
    min-height: 44px;
    border-radius: 22px;
  }

  .lia-icon-button {
    width: 44px;
  }

  .lia-send-button {
    padding: 0 14px;
  }

  .lia-settings-content {
    padding: 14px;
  }

  .lia-section-title-row {
    display: grid;
    gap: 12px;
  }

  .lia-section-title-row h2 {
    font-size: 28px;
  }

  .lia-form-actions {
    width: 100%;
  }

  .lia-primary-button,
  .lia-secondary-button {
    flex: 1;
  }

  .lia-general-card {
    padding: 16px;
    border-radius: 22px;
  }

  .lia-photo-row {
    grid-template-columns: 84px minmax(0, 1fr);
    gap: 14px;
  }

  .lia-photo-preview {
    width: 84px;
    height: 84px;
    border-radius: 22px;
  }

  .lia-general-form {
    grid-template-columns: 1fr;
    gap: 14px;
  }
}

@media (min-width: 761px) and (max-width: 1060px) {
  .lia-desktop-frame {
    grid-template-columns: 230px minmax(0, 1fr);
  }

  .lia-shell {
    padding: 10px;
  }

  .lia-desktop-sidebar {
    padding: 12px;
    border-radius: 24px;
  }

  .lia-chat-card,
  .lia-settings-panel {
    border-radius: 24px;
  }

  .lia-bubble {
    max-width: 76%;
  }

  .lia-general-form {
    grid-template-columns: 1fr;
  }

  .lia-photo-row {
    grid-template-columns: 88px minmax(0, 1fr);
  }

  .lia-photo-preview {
    width: 88px;
    height: 88px;
  }
}

@media (max-width: 780px) {
  .lia-messages,
  #lia-messages,
  .lia-chat-messages,
  .lia-live-messages {
    overflow-y: auto;
    overflow-x: hidden;
    min-height: 0;
    padding-right: 8px;
  }

  .lia-message-row {
    gap: 8px;
    margin: 8px 0;
  }

  .lia-message-avatar {
    width: 30px;
    height: 30px;
    flex-basis: 30px;
  }

  .lia-message-bubble {
    max-width: calc(100% - 46px);
    padding: 10px 12px 7px;
    border-radius: 16px;
  }

  .lia-message-time {
    font-size: 0.72rem;
  }

  .lia-live-bubble-assistant {
    margin-left: 38px;
  }
}


@media (max-width: 760px) {
  .lia-composer {
    display: flex !important;
    grid-template-columns: none !important;
    align-items: center;
    gap: 9px;
    padding: 10px 10px max(10px, env(safe-area-inset-bottom));
  }

  .lia-composer .lia-input {
    flex: 1 1 auto;
    min-height: 46px;
    border-radius: 24px;
    padding: 12px 15px;
  }

  .lia-composer .lia-icon-button,
  .lia-composer .lia-send-button {
    flex: 0 0 48px;
    width: 48px;
    height: 48px;
    min-width: 48px;
    min-height: 48px;
    border-radius: 999px;
    padding: 0;
  }

  .lia-composer .lia-send-button {
    font-size: 25px;
  }

  .lia-composer-has-text .lia-icon-button {
    display: none !important;
  }

  .lia-composer-is-idle .lia-send-button,
  .lia-composer:not(.lia-composer-has-text) .lia-send-button {
    display: none !important;
  }
}

@media (max-width: 760px) {
  .lia-chat-card {
    overflow: hidden;
  }

  .lia-composer {
    position: relative;
    display: flex !important;
    grid-template-columns: none !important;
    align-items: center;
    gap: 8px;
    padding: 9px 10px max(10px, env(safe-area-inset-bottom));
    background: rgba(246, 250, 249, 0.96);
    border-top: 1px solid rgba(177, 190, 203, 0.24);
  }

  .lia-composer .lia-input-label {
    position: static !important;
    order: 1;
    flex: 0 0 42px;
    width: 42px;
    height: 42px;
    min-width: 42px;
    min-height: 42px;
    overflow: visible;
    clip-path: none !important;
    white-space: normal;
    border-radius: 999px;
    display: inline-grid;
    place-items: center;
    color: rgba(71, 85, 105, 0.82);
    font-size: 0;
    background: transparent;
  }

  .lia-composer .lia-input-label::before {
    content: "☺";
    font-size: 28px;
    line-height: 1;
    font-weight: 400;
  }

  .lia-composer .lia-input {
    order: 2;
    flex: 1 1 auto;
    width: auto;
    min-width: 0;
    min-height: 50px;
    max-height: 116px;
    border: 0;
    border-radius: 999px;
    padding: 13px 84px 13px 4px;
    background: transparent;
    box-shadow: none;
    color: #18232f;
    font-size: 1rem;
    line-height: 1.35;
  }

  .lia-composer .lia-input::placeholder {
    color: rgba(80, 91, 105, 0.62);
  }

  .lia-composer::before {
    content: "";
    position: absolute;
    left: 10px;
    right: 66px;
    top: 9px;
    bottom: max(10px, env(safe-area-inset-bottom));
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow:
      inset 0 0 0 1px rgba(177, 190, 203, 0.16),
      0 10px 24px rgba(24, 39, 52, 0.08);
    z-index: 0;
    pointer-events: none;
  }

  .lia-composer::after {
    content: "📎   📷";
    position: absolute;
    right: 83px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 64px;
    height: 42px;
    color: rgba(71, 85, 105, 0.72);
    font-size: 22px;
    letter-spacing: 8px;
    pointer-events: none;
  }

  .lia-composer > * {
    position: relative;
    z-index: 1;
  }

  .lia-composer .lia-icon-button,
  .lia-composer .lia-send-button {
    order: 3;
    flex: 0 0 54px;
    width: 54px;
    height: 54px;
    min-width: 54px;
    min-height: 54px;
    border-radius: 999px;
    padding: 0;
    display: inline-grid;
    place-items: center;
    border: 0;
    color: #ffffff;
    background: linear-gradient(135deg, #111a8f, #047b64);
    box-shadow: 0 12px 26px rgba(8, 93, 93, 0.24);
    font-size: 24px;
    line-height: 1;
  }

  .lia-composer .lia-send-button {
    font-size: 0;
  }

  .lia-composer .lia-send-button::before {
    content: "➤";
    font-size: 29px;
    line-height: 1;
    transform: translateX(1px);
  }

  .lia-composer .lia-icon-button {
    font-size: 0;
  }

  .lia-composer .lia-icon-button::before {
    content: "🎙";
    font-size: 25px;
    line-height: 1;
  }

  .lia-composer-is-idle .lia-send-button,
  .lia-composer:not(.lia-composer-has-text) .lia-send-button,
  .lia-composer .lia-send-button[hidden] {
    display: none !important;
  }

  .lia-composer-has-text .lia-icon-button,
  .lia-composer .lia-icon-button[hidden] {
    display: none !important;
  }

  .lia-composer-has-text::after {
    content: "📎";
    min-width: 30px;
    right: 84px;
    letter-spacing: 0;
  }

  .lia-composer-has-text .lia-input {
    padding-right: 52px;
  }

  .lia-composer-is-recording::before {
    box-shadow:
      inset 0 0 0 1px rgba(239, 68, 68, 0.22),
      0 10px 24px rgba(239, 68, 68, 0.10);
  }

  .lia-composer-is-recording .lia-icon-button {
    display: inline-grid !important;
    background: linear-gradient(135deg, #ef4444, #dc2626) !important;
    box-shadow: 0 12px 26px rgba(220, 38, 38, 0.24);
  }

  .lia-composer-is-recording .lia-icon-button::before {
    content: "■";
    font-size: 20px;
  }

  .lia-composer-is-recording::after {
    content: "";
  }
}

@media (max-width: 420px) {
  .lia-composer {
    gap: 7px;
    padding-left: 8px;
    padding-right: 8px;
  }

  .lia-composer::before {
    left: 8px;
    right: 61px;
  }

  .lia-composer .lia-input-label {
    flex-basis: 38px;
    width: 38px;
    min-width: 38px;
  }

  .lia-composer .lia-input-label::before {
    font-size: 25px;
  }

  .lia-composer .lia-input {
    min-height: 48px;
    padding-right: 74px;
    font-size: 0.96rem;
  }

  .lia-composer::after {
    right: 75px;
    min-width: 58px;
    font-size: 20px;
    letter-spacing: 6px;
  }

  .lia-composer .lia-icon-button,
  .lia-composer .lia-send-button {
    flex-basis: 50px;
    width: 50px;
    height: 50px;
    min-width: 50px;
    min-height: 50px;
  }

  .lia-composer-has-text::after {
    right: 75px;
    min-width: 26px;
  }

  .lia-composer-has-text .lia-input {
    padding-right: 46px;
  }
}


@media (max-width: 760px) {
  .lia-composer {
    gap: 7px;
  }

  .lia-composer::before {
    right: 56px;
  }

  .lia-composer .lia-input-label {
    flex: 0 0 34px;
    width: 34px;
    min-width: 34px;
    height: 40px;
    min-height: 40px;
  }

  .lia-composer .lia-input-label::before {
    font-size: 19px;
    opacity: 0.78;
  }

  .lia-composer .lia-input {
    min-height: 46px;
    padding-top: 12px;
    padding-bottom: 12px;
    padding-right: 68px;
    font-size: 0.94rem;
  }

  .lia-composer::after {
    right: 69px;
    min-width: 52px;
    height: 34px;
    font-size: 15px;
    letter-spacing: 5px;
    opacity: 0.78;
  }

  .lia-composer .lia-icon-button,
  .lia-composer .lia-send-button {
    flex: 0 0 46px;
    width: 46px;
    height: 46px;
    min-width: 46px;
    min-height: 46px;
    box-shadow: 0 9px 18px rgba(8, 93, 93, 0.20);
  }

  .lia-composer .lia-icon-button::before {
    font-size: 20px;
  }

  .lia-composer .lia-send-button::before {
    font-size: 24px;
  }

  .lia-composer-has-text::after {
    right: 69px;
    min-width: 24px;
    font-size: 16px;
    letter-spacing: 0;
  }

  .lia-composer-has-text .lia-input {
    padding-right: 42px;
  }

  .lia-composer-is-recording .lia-icon-button::before {
    font-size: 17px;
  }
}

@media (max-width: 420px) {
  .lia-composer {
    gap: 6px;
    padding-left: 7px;
    padding-right: 7px;
  }

  .lia-composer::before {
    left: 7px;
    right: 54px;
  }

  .lia-composer .lia-input-label {
    flex-basis: 32px;
    width: 32px;
    min-width: 32px;
  }

  .lia-composer .lia-input-label::before {
    font-size: 18px;
  }

  .lia-composer .lia-input {
    min-height: 44px;
    padding-left: 3px;
    padding-right: 62px;
    font-size: 0.92rem;
  }

  .lia-composer::after {
    right: 65px;
    min-width: 48px;
    font-size: 14px;
    letter-spacing: 4px;
  }

  .lia-composer .lia-icon-button,
  .lia-composer .lia-send-button {
    flex-basis: 44px;
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
  }

  .lia-composer .lia-icon-button::before {
    font-size: 19px;
  }

  .lia-composer .lia-send-button::before {
    font-size: 23px;
  }

  .lia-composer-has-text::after {
    right: 65px;
    min-width: 22px;
    font-size: 15px;
  }

  .lia-composer-has-text .lia-input {
    padding-right: 39px;
  }
}


@media (max-width: 760px) {
  .lia-composer {
    isolation: isolate;
    align-items: flex-end !important;
  }

  .lia-composer::before {
    top: 9px;
    bottom: max(10px, env(safe-area-inset-bottom));
    pointer-events: none;
    z-index: 0;
  }

  .lia-composer > * {
    position: relative;
    z-index: 2;
  }

  .lia-composer .lia-input-label {
    align-self: flex-end;
    margin-bottom: 3px;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1 !important;
    padding: 0 !important;
    pointer-events: none;
    transform: translateY(-2px);
  }

  .lia-composer .lia-input-label::before {
    display: block;
    width: 22px;
    height: 22px;
    line-height: 21px;
    text-align: center;
    font-family: "Segoe UI Symbol", "Apple Color Emoji", "Noto Color Emoji", system-ui, sans-serif;
    font-size: 18px;
    transform: translateY(0);
  }

  .lia-composer .lia-input {
    align-self: stretch;
    display: block;
    height: 46px;
    min-height: 46px;
    max-height: 118px;
    overflow-y: hidden;
    line-height: 1.34;
    padding-top: 12px;
    padding-bottom: 12px;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
  }

  .lia-composer .lia-input:focus {
    outline: none;
  }

  .lia-composer::after {
    top: auto;
    bottom: calc(max(10px, env(safe-area-inset-bottom)) + 11px);
    transform: none;
    height: 24px;
    line-height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: "Segoe UI Symbol", "Apple Color Emoji", "Noto Color Emoji", system-ui, sans-serif;
    pointer-events: none;
    z-index: 1;
  }

  .lia-composer .lia-icon-button,
  .lia-composer .lia-send-button {
    align-self: flex-end;
    margin-bottom: 0;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1 !important;
    padding: 0 !important;
    position: relative;
    z-index: 3;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }

  .lia-composer .lia-icon-button::before,
  .lia-composer .lia-send-button::before {
    position: static;
    display: block;
    width: 24px;
    height: 24px;
    line-height: 23px;
    text-align: center;
    margin: 0;
    font-family: "Segoe UI Symbol", "Apple Color Emoji", "Noto Color Emoji", system-ui, sans-serif;
    transform: none;
  }

  .lia-composer .lia-icon-button::before {
    font-size: 19px;
  }

  .lia-composer .lia-send-button::before {
    font-size: 23px;
    transform: translateX(1px);
  }

  .lia-composer .lia-send-button[hidden],
  .lia-composer-is-idle .lia-send-button,
  .lia-composer:not(.lia-composer-has-text) .lia-send-button {
    display: none !important;
  }

  .lia-composer .lia-icon-button[hidden],
  .lia-composer-has-text .lia-icon-button {
    display: none !important;
  }

  .lia-composer-is-recording .lia-icon-button {
    display: inline-flex !important;
  }

  .lia-composer-is-recording .lia-icon-button::before {
    font-size: 16px;
    line-height: 24px;
  }
}

@media (max-width: 420px) {
  .lia-composer .lia-input-label {
    transform: translateY(-1px);
  }

  .lia-composer .lia-input-label::before {
    font-size: 17px;
  }

  .lia-composer::after {
    bottom: calc(max(10px, env(safe-area-inset-bottom)) + 10px);
    height: 22px;
    line-height: 22px;
  }

  .lia-composer .lia-icon-button::before {
    font-size: 18px;
  }

  .lia-composer .lia-send-button::before {
    font-size: 22px;
  }
}


@media (max-width: 760px) {
  html,
  body {
    height: 100%;
    min-height: 100%;
    overflow: hidden;
  }

  body.lia-chat-page {
    min-height: 100dvh;
    height: 100dvh;
  }

  .lia-shell,
  .lia-desktop-frame,
  .lia-chat-workspace,
  .lia-chat-card {
    min-height: 100dvh;
    height: 100dvh;
    max-height: 100dvh;
  }

  @supports (height: 100svh) {
    .lia-shell,
    .lia-desktop-frame,
    .lia-chat-workspace,
    .lia-chat-card {
      min-height: 100svh;
      height: 100svh;
      max-height: 100svh;
    }
  }

  .lia-chat-workspace {
    overflow: hidden !important;
  }

  .lia-chat-card {
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
  }

  .lia-chat-header {
    flex: 0 0 auto !important;
    position: relative;
    z-index: 3;
  }

  .lia-messages {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    height: auto !important;
    max-height: none !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    scroll-behavior: smooth;
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
    align-items: stretch !important;
    gap: 10px;
    padding-top: 18px !important;
    padding-bottom: 18px !important;
  }

  .lia-messages .lia-date-separator,
  .lia-messages .lia-message-row {
    flex: 0 0 auto;
  }

  .lia-message-row {
    max-width: 100%;
  }

  .lia-message-bubble {
    max-width: min(82vw, 680px);
    overflow-wrap: anywhere;
    word-break: normal;
  }

  .lia-composer {
    flex: 0 0 auto !important;
    position: relative !important;
    z-index: 4;
  }

  .lia-typing {
    display: none !important;
  }

  .lia-mobile-chat-active .lia-messages {
    contain: layout paint;
  }
}

@media (max-width: 420px) {
  .lia-messages {
    gap: 9px;
    padding-top: 14px !important;
    padding-bottom: 14px !important;
  }

  .lia-message-bubble {
    max-width: min(84vw, 620px);
  }
}


@media (max-width: 760px) {
  :root {
    --lia-mobile-visual-height: 100dvh;
    --lia-mobile-keyboard-offset: 0px;
  }

  body.lia-chat-page {
    height: var(--lia-mobile-visual-height, 100dvh) !important;
    min-height: var(--lia-mobile-visual-height, 100dvh) !important;
    max-height: var(--lia-mobile-visual-height, 100dvh) !important;
    overflow: hidden !important;
  }

  .lia-shell,
  .lia-desktop-frame,
  .lia-chat-workspace,
  .lia-chat-card {
    height: var(--lia-mobile-visual-height, 100dvh) !important;
    min-height: var(--lia-mobile-visual-height, 100dvh) !important;
    max-height: var(--lia-mobile-visual-height, 100dvh) !important;
    overflow: hidden !important;
  }

  .lia-chat-card {
    display: flex !important;
    flex-direction: column !important;
  }

  .lia-chat-header {
    flex: 0 0 auto !important;
  }

  .lia-messages {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    padding-bottom: 12px !important;
  }

  .lia-composer {
    flex: 0 0 auto !important;
    position: relative !important;
    bottom: auto !important;
  }

  body.lia-mobile-keyboard-open .lia-chat-card {
    height: var(--lia-mobile-visual-height, 100dvh) !important;
    min-height: var(--lia-mobile-visual-height, 100dvh) !important;
    max-height: var(--lia-mobile-visual-height, 100dvh) !important;
  }

  body.lia-mobile-keyboard-open .lia-messages {
    scroll-behavior: auto !important;
    padding-bottom: 10px !important;
  }

  body.lia-mobile-keyboard-open.lia-mobile-user-typing .lia-messages {
    overscroll-behavior: contain;
  }

  body.lia-mobile-input-focused .lia-composer {
    box-shadow: 0 -8px 18px rgba(16, 24, 35, 0.08);
  }

  body.lia-mobile-keyboard-open .lia-composer {
    padding-bottom: max(8px, env(safe-area-inset-bottom)) !important;
  }

  body.lia-mobile-keyboard-open .lia-composer::before {
    bottom: max(8px, env(safe-area-inset-bottom)) !important;
  }

  body.lia-mobile-keyboard-open .lia-composer::after {
    bottom: calc(max(8px, env(safe-area-inset-bottom)) + 10px) !important;
  }

  body.lia-mobile-keyboard-open .lia-message-bubble {
    max-width: min(84vw, 620px);
  }
}

@media (max-width: 420px) {
  body.lia-mobile-keyboard-open .lia-messages {
    padding-top: 10px !important;
    padding-bottom: 8px !important;
  }

  body.lia-mobile-keyboard-open .lia-composer {
    padding-top: 7px !important;
    padding-bottom: max(7px, env(safe-area-inset-bottom)) !important;
  }
}

@media (max-width: 760px) {
  .lia-composer {
    align-items: flex-end !important;
    justify-content: flex-end !important;
    min-height: 64px;
    height: auto !important;
    padding-top: 8px !important;
    padding-bottom: max(8px, env(safe-area-inset-bottom)) !important;
  }

  .lia-composer::before {
    top: auto !important;
    bottom: max(8px, env(safe-area-inset-bottom)) !important;
    height: calc(100% - 16px) !important;
    min-height: 46px !important;
    max-height: 126px !important;
    border-radius: 24px !important;
  }

  .lia-composer .lia-input-label {
    align-self: flex-end !important;
    margin-bottom: 3px !important;
  }

  .lia-composer .lia-input {
    align-self: flex-end !important;
    box-sizing: border-box !important;
    min-height: 44px !important;
    max-height: 116px !important;
    height: auto;
    line-height: 1.34 !important;
    padding-top: 12px !important;
    padding-bottom: 12px !important;
    overflow-y: auto;
    resize: none;
  }

  .lia-composer .lia-icon-button,
  .lia-composer .lia-send-button {
    align-self: flex-end !important;
    margin-bottom: 0 !important;
  }

  .lia-composer::after {
    top: auto !important;
    bottom: calc(max(8px, env(safe-area-inset-bottom)) + 10px) !important;
    transform: none !important;
  }

  body.lia-mobile-keyboard-open .lia-composer {
    align-items: flex-end !important;
    justify-content: flex-end !important;
    padding-top: 8px !important;
    padding-bottom: max(7px, env(safe-area-inset-bottom)) !important;
  }

  body.lia-mobile-keyboard-open .lia-composer::before {
    top: auto !important;
    bottom: max(7px, env(safe-area-inset-bottom)) !important;
    height: calc(100% - 15px) !important;
  }

  body.lia-mobile-keyboard-open .lia-composer::after {
    top: auto !important;
    bottom: calc(max(7px, env(safe-area-inset-bottom)) + 10px) !important;
    transform: none !important;
  }

  body.lia-mobile-keyboard-open .lia-composer .lia-input,
  body.lia-mobile-input-focused .lia-composer .lia-input {
    align-self: flex-end !important;
  }
}

@media (max-width: 420px) {
  .lia-composer {
    min-height: 60px;
    padding-top: 7px !important;
  }

  .lia-composer::before {
    min-height: 44px !important;
    max-height: 122px !important;
    height: calc(100% - 14px) !important;
  }

  .lia-composer .lia-input {
    min-height: 42px !important;
    max-height: 112px !important;
    padding-top: 11px !important;
    padding-bottom: 11px !important;
  }
}


@media (max-width: 760px) {
  :root {
    --lia-mobile-input-height: 44px;
    --lia-mobile-composer-height: 62px;
  }

  .lia-chat-card {
    display: flex !important;
    flex-direction: column !important;
  }

  .lia-messages {
    flex: 1 1 auto !important;
    min-height: 0 !important;
  }

  .lia-composer {
    flex: 0 0 var(--lia-mobile-composer-height) !important;
    height: var(--lia-mobile-composer-height) !important;
    min-height: var(--lia-mobile-composer-height) !important;
    max-height: 138px !important;
    align-items: flex-end !important;
    justify-content: flex-end !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    padding-top: 8px !important;
    padding-bottom: max(8px, env(safe-area-inset-bottom)) !important;
  }

  .lia-composer::before {
    top: auto !important;
    bottom: max(8px, env(safe-area-inset-bottom)) !important;
    height: var(--lia-mobile-input-height) !important;
    min-height: 44px !important;
    max-height: 118px !important;
    border-radius: 24px !important;
  }

  .lia-composer .lia-input {
    align-self: flex-end !important;
    height: var(--lia-mobile-input-height) !important;
    min-height: 44px !important;
    max-height: 118px !important;
    box-sizing: border-box !important;
    line-height: 1.34 !important;
    padding-top: 12px !important;
    padding-bottom: 12px !important;
    resize: none !important;
    transform: none !important;
    margin-top: auto !important;
    margin-bottom: 0 !important;
  }

  .lia-composer .lia-input-label,
  .lia-composer .lia-icon-button,
  .lia-composer .lia-send-button {
    align-self: flex-end !important;
    margin-top: auto !important;
    margin-bottom: 0 !important;
  }

  .lia-composer .lia-input-label {
    margin-bottom: 2px !important;
  }

  .lia-composer::after {
    top: auto !important;
    bottom: calc(max(8px, env(safe-area-inset-bottom)) + 10px) !important;
    transform: none !important;
  }

  .lia-composer-multiline::before {
    border-radius: 22px !important;
  }

  .lia-composer-input-limited .lia-input {
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
  }

  body.lia-mobile-keyboard-open .lia-composer {
    flex-basis: var(--lia-mobile-composer-height) !important;
    height: var(--lia-mobile-composer-height) !important;
    min-height: var(--lia-mobile-composer-height) !important;
    align-items: flex-end !important;
    justify-content: flex-end !important;
    padding-bottom: max(7px, env(safe-area-inset-bottom)) !important;
  }

  body.lia-mobile-keyboard-open .lia-composer::before {
    top: auto !important;
    bottom: max(7px, env(safe-area-inset-bottom)) !important;
    height: var(--lia-mobile-input-height) !important;
  }

  body.lia-mobile-keyboard-open .lia-composer::after {
    top: auto !important;
    bottom: calc(max(7px, env(safe-area-inset-bottom)) + 10px) !important;
    transform: none !important;
  }
}

@media (max-width: 420px) {
  :root {
    --lia-mobile-input-height: 42px;
    --lia-mobile-composer-height: 59px;
  }

  .lia-composer {
    max-height: 132px !important;
  }

  .lia-composer::before {
    min-height: 42px !important;
    max-height: 112px !important;
  }

  .lia-composer .lia-input {
    min-height: 42px !important;
    max-height: 112px !important;
    padding-top: 11px !important;
    padding-bottom: 11px !important;
  }
}


@media (max-width: 760px) {
  :root {
    --lia-mobile-input-height: 42px;
    --lia-mobile-composer-height: 60px;
  }

  .lia-chat-card {
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
  }

  .lia-messages {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
  }

  .lia-composer.lia-composer-whatsapp-mode,
  .lia-composer {
    flex: 0 0 var(--lia-mobile-composer-height) !important;
    height: var(--lia-mobile-composer-height) !important;
    min-height: var(--lia-mobile-composer-height) !important;
    max-height: 136px !important;
    display: flex !important;
    align-items: flex-end !important;
    justify-content: flex-end !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    padding-top: 8px !important;
    padding-bottom: max(8px, env(safe-area-inset-bottom)) !important;
  }

  .lia-composer.lia-composer-whatsapp-mode::before,
  .lia-composer::before {
    top: auto !important;
    bottom: max(8px, env(safe-area-inset-bottom)) !important;
    height: var(--lia-mobile-input-height) !important;
    min-height: 42px !important;
    max-height: 118px !important;
    border-radius: 22px !important;
  }

  .lia-composer.lia-composer-whatsapp-mode .lia-input,
  .lia-composer .lia-input {
    align-self: flex-end !important;
    height: var(--lia-mobile-input-height) !important;
    min-height: 42px !important;
    max-height: 118px !important;
    box-sizing: border-box !important;
    margin: 0 !important;
    line-height: 1.34 !important;
    padding-top: 11px !important;
    padding-bottom: 11px !important;
    resize: none !important;
    transform: none !important;
    overflow-anchor: none !important;
    vertical-align: bottom !important;
  }

  .lia-composer .lia-input-label,
  .lia-composer .lia-icon-button,
  .lia-composer .lia-send-button {
    align-self: flex-end !important;
    margin-top: auto !important;
    margin-bottom: 0 !important;
  }

  .lia-composer .lia-input-label {
    transform: none !important;
    margin-bottom: 1px !important;
  }

  .lia-composer::after {
    top: auto !important;
    bottom: calc(max(8px, env(safe-area-inset-bottom)) + 10px) !important;
    transform: none !important;
  }

  .lia-composer.lia-composer-multiline::before {
    border-radius: 20px !important;
  }

  .lia-composer.lia-composer-input-limited .lia-input {
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
  }

  body.lia-mobile-keyboard-open .lia-composer,
  body.lia-mobile-input-focused .lia-composer {
    flex: 0 0 var(--lia-mobile-composer-height) !important;
    height: var(--lia-mobile-composer-height) !important;
    min-height: var(--lia-mobile-composer-height) !important;
    max-height: 136px !important;
    align-items: flex-end !important;
    justify-content: flex-end !important;
    padding-top: 8px !important;
    padding-bottom: max(7px, env(safe-area-inset-bottom)) !important;
  }

  body.lia-mobile-keyboard-open .lia-composer::before,
  body.lia-mobile-input-focused .lia-composer::before {
    top: auto !important;
    bottom: max(7px, env(safe-area-inset-bottom)) !important;
    height: var(--lia-mobile-input-height) !important;
  }

  body.lia-mobile-keyboard-open .lia-composer::after,
  body.lia-mobile-input-focused .lia-composer::after {
    top: auto !important;
    bottom: calc(max(7px, env(safe-area-inset-bottom)) + 10px) !important;
    transform: none !important;
  }

  body.lia-mobile-keyboard-open .lia-messages,
  body.lia-mobile-input-focused .lia-messages {
    flex: 1 1 auto !important;
    min-height: 0 !important;
  }
}

@media (max-width: 420px) {
  :root {
    --lia-mobile-input-height: 42px;
    --lia-mobile-composer-height: 58px;
  }

  .lia-composer,
  .lia-composer.lia-composer-whatsapp-mode {
    max-height: 130px !important;
    padding-top: 7px !important;
  }

  .lia-composer::before,
  .lia-composer.lia-composer-whatsapp-mode::before {
    min-height: 42px !important;
    max-height: 112px !important;
  }

  .lia-composer .lia-input,
  .lia-composer.lia-composer-whatsapp-mode .lia-input {
    min-height: 42px !important;
    max-height: 112px !important;
    padding-top: 11px !important;
    padding-bottom: 11px !important;
  }
}
