.consultation-page { min-height: 1024px; color: #09173c; background: #f2f7ff; }
.consultation-shell { width: min(1200px, calc(100% - 64px)); margin: 0 auto; }
.consultation-header { height: 96px; border-bottom: 1px solid #e0e8f5; background: #fff; }
.consultation-header__inner { display: flex; align-items: center; gap: 24px; height: 96px; }
.consultation-back { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: #f2f7ff; transition: background .2s ease, transform .2s ease; }
.consultation-back:hover { background: #e6efff; transform: translateX(-2px); }
.consultation-back img { width: 24px; height: 24px; }
.consultation-brand { display: flex; align-items: center; width: 172px; height: 96px; }
.consultation-brand img { width: 167px; height: 49px; object-fit: contain; }
.consultation-page-close { display: grid; place-items: center; width: 44px; height: 44px; margin-left: auto; border: 1px solid #dbe5f5; border-radius: 50%; color: #09173c; background: #fff; font-size: 30px; line-height: 1; transition: color .2s ease, background .2s ease, transform .2s ease; }
.consultation-page-close:hover { color: #fff; background: #09173c; transform: rotate(5deg); }
.consultation-workspace { min-height: 928px; padding: 40px 0; background: #f2f7ff; }
.consultation-workspace__inner { display: grid; grid-template-columns: 360px minmax(0, 816px); gap: 24px; min-height: 848px; }
.consultation-profile,
.consultation-conversation { height: 848px; overflow: hidden; border: 1px solid #dbe5f5; border-radius: 24px; background: #fff; box-shadow: 0 12px 32px rgba(10, 23, 61, .08); }
.consultation-profile { display: flex; flex-direction: column; align-items: center; gap: 24px; padding: 40px 32px; }
.consultation-profile__logo { display: grid; place-items: center; width: 96px; height: 96px; padding: 15px; overflow: hidden; border: 1px solid #d1e0fa; border-radius: 24px; color: #fff; background: #f2f7ff; }
.consultation-profile__logo img { width: 64px; height: 64px; object-fit: contain; border: 1px solid #dfe8f7; border-radius: 12px; background: #fff; }
.consultation-profile__logo span { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 12px; background: linear-gradient(135deg, #09173c, #2e63ff); font-weight: 800; font-size: 20px; }
.consultation-profile h1 { max-width: 296px; overflow: hidden; color: #09173c; font-size: 28px; line-height: 40px; font-weight: 700; text-align: center; text-overflow: ellipsis; white-space: nowrap; }
.consultation-profile__tags { display: flex; justify-content: center; gap: 8px; width: 100%; min-height: 32px; overflow: hidden; }
.consultation-profile__tags span { display: inline-flex; align-items: center; justify-content: center; min-width: 64px; max-width: 96px; height: 32px; padding: 0 13px; overflow: hidden; border: 1px solid #d1e0fa; border-radius: 16px; color: #3d5785; background: #f2f7ff; font-size: 14px; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.consultation-open { display: flex; align-items: center; justify-content: center; gap: 10px; width: 296px; min-height: 56px; border-radius: 16px; color: #fff; background: #09173c; font-size: 18px; font-weight: 500; transition: transform .2s ease, box-shadow .2s ease; }
.consultation-open:hover { transform: translateY(-2px); box-shadow: 0 12px 22px rgba(9, 23, 60, .2); }
.consultation-open img { width: 20px; height: 20px; }
.consultation-open.is-disabled { padding: 0 20px; color: #73829e; background: #f2f7ff; cursor: not-allowed; }
.consultation-open.is-disabled:hover { transform: none; box-shadow: none; }
.consultation-conversation { position: relative; }
.consultation-messages { position: absolute; top: 47px; right: 47px; bottom: 160px; left: 47px; overflow: auto; scrollbar-width: thin; }
.consultation-message { display: flex; flex-direction: column; gap: 10px; }
.consultation-message header { display: flex; align-items: center; gap: 12px; height: 26px; }
.consultation-message header strong { color: #09173c; font-size: 17px; line-height: 26px; font-weight: 700; }
.consultation-message header time { color: #73829e; font-size: 14px; }
.consultation-message--incoming { width: min(560px, 82%); }
.consultation-message--incoming .consultation-bubble { padding: 19px 27px; border: 1px solid #e0e8f5; border-radius: 18px; color: #1f2b45; background: #f6f8fc; }
.consultation-bubble p { font-size: 18px; line-height: 30px; }
.consultation-bubble p + p { margin-top: 2px; }
.consultation-message--outgoing { align-items: flex-end; width: min(340px, 58%); margin: 56px 0 0 auto; }
.consultation-message--outgoing header strong { color: #3d4f6e; font-size: 16px; font-weight: 500; }
.consultation-message--outgoing .consultation-bubble { display: flex; align-items: center; justify-content: center; min-width: 240px; min-height: 72px; padding: 18px 28px; border: 1px solid #bad1ff; border-radius: 18px; color: #09173c; background: #e6efff; text-align: center; }
.consultation-composer { position: absolute; right: 31px; bottom: 32px; left: 31px; display: grid; grid-template-columns: minmax(0, 1fr) 112px; gap: 12px; height: 64px; }
.consultation-composer label { display: block; min-width: 0; }
.consultation-composer input { width: 100%; height: 64px; padding: 0 24px; border: 1px solid #d6e3f7; border-radius: 16px; outline: none; color: #09173c; background: #f2f7ff; font-size: 17px; }
.consultation-composer input::placeholder { color: #73829e; opacity: 1; }
.consultation-composer input:focus { border-color: #2e63ff; box-shadow: 0 0 0 3px rgba(46, 99, 255, .12); }
.consultation-composer button { width: 112px; height: 64px; border: 0; border-radius: 16px; color: #fff; background: #2e63ff; font-size: 18px; font-weight: 500; transition: background .2s ease, transform .2s ease; }
.consultation-composer button:hover { background: #204fe1; transform: translateY(-1px); }
.consultation-composer button:disabled,
.consultation-hub-composer button:disabled { cursor: wait; opacity: .68; transform: none; }
.consultation-composer-status { position: absolute; right: 0; bottom: calc(100% + 8px); z-index: 3; max-width: min(560px, 82vw); margin: 0; padding: 6px 10px; border: 1px solid #d9e4f5; border-radius: 9px; color: #52627d; background: rgba(255, 255, 255, .96); box-shadow: 0 5px 16px rgba(20, 54, 110, .08); font-size: 12px; line-height: 18px; }
.consultation-composer-status:empty { display: none; }
.consultation-composer-status[data-state="error"] { border-color: #ffd0cc; color: #b42318; background: #fff5f4; }
.consultation-composer-status[data-state="success"] { border-color: #b9ead5; color: #087a55; background: #effbf6; }
.consultation-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.consultation-page.is-embedded { min-height: 100vh; }
.consultation-page.is-embedded .consultation-header { display: none; }
.consultation-page.is-embedded .consultation-workspace { min-height: 100vh; height: 100vh; padding: 24px; }
.consultation-page.is-embedded .consultation-workspace__inner { width: 100%; min-height: calc(100vh - 48px); }
.consultation-page.is-embedded .consultation-profile,
.consultation-page.is-embedded .consultation-conversation { height: calc(100vh - 48px); }

/* Unified online consultation center — Figma 400:2404 */
.consultation-page.is-embedded { min-height: 100vh; height: 100vh; overflow: hidden; background: #fbfcff; }
.consultation-hub { display: grid; grid-template-rows: 76px minmax(0, 1fr); width: 100%; height: 100vh; overflow: hidden; color: #101c38; background: #fbfcff; }
.consultation-hub__header { display: flex; align-items: center; gap: 14px; min-width: 0; padding: 0 72px 0 28px; border-bottom: 1px solid #dfe7f4; background: #fff; }
.consultation-hub__header > img { width: 24px; height: 24px; flex: 0 0 auto; }
.consultation-hub__header h1 { min-width: 0; overflow: hidden; color: #111a31; font-size: 22px; line-height: 32px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.consultation-hub__online { display: inline-flex; align-items: center; gap: 7px; height: 32px; margin-left: 54px; padding: 0 14px; border-radius: 16px; color: #159259; background: #eaf9f1; font-size: 14px; line-height: 20px; white-space: nowrap; }
.consultation-hub__online i,
.consultation-chat__agent span i { width: 6px; height: 6px; border-radius: 50%; background: #19b66a; }
.consultation-hub__body { display: grid; grid-template-columns: 300px minmax(0, 1fr); min-height: 0; }
.consultation-inbox { min-height: 0; padding: 22px 12px 20px; border-right: 1px solid #dfe7f4; background: #f5f8ff; }
.consultation-inbox__heading { display: flex; align-items: center; justify-content: space-between; padding: 0 12px 14px; }
.consultation-inbox__heading strong { color: #111a31; font-size: 17px; line-height: 26px; font-weight: 700; }
.consultation-inbox__heading span { color: #627493; font-size: 13px; line-height: 20px; }
.consultation-inbox__list { display: grid; gap: 8px; }
.consultation-inbox__item { position: relative; display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 12px; align-items: start; width: 100%; min-height: 92px; padding: 14px 14px; overflow: hidden; border: 1px solid transparent; border-radius: 14px; color: inherit; background: transparent; text-align: left; cursor: pointer; transition: border-color .18s ease, background .18s ease, box-shadow .18s ease; }
.consultation-inbox__item:hover { border-color: #d9e5f8; background: rgba(255, 255, 255, .72); }
.consultation-inbox__item.is-active { border-color: #d4e1f5; background: #fff; box-shadow: 0 2px 10px rgba(30, 67, 131, .04); }
.consultation-inbox__item.is-active::before { position: absolute; top: 0; bottom: 0; left: 0; width: 3px; border-radius: 3px; background: #2f62ff; content: ''; }
.consultation-inbox__item time { padding-top: 2px; color: #627493; font-size: 12px; line-height: 18px; }
.consultation-inbox__copy { display: block; min-width: 0; }
.consultation-inbox__copy strong { display: block; overflow: hidden; color: #101a34; font-size: 15px; line-height: 22px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.consultation-inbox__copy small { display: -webkit-box; margin-top: 5px; overflow: hidden; color: #637594; font-size: 12px; line-height: 18px; font-weight: 400; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.consultation-agent-avatar { display: grid; place-items: center; width: 44px; height: 44px; overflow: hidden; border: 1px solid #dce7f7; border-radius: 12px; color: #2f62ff; background: #edf4ff; flex: 0 0 auto; }
.consultation-agent-avatar img { width: 100%; height: 100%; object-fit: cover; }
.consultation-agent-avatar b { font-size: 14px; line-height: 20px; font-weight: 700; }
.consultation-agent-avatar.is-reviewer { border-radius: 50%; background: #fff; }
.consultation-agent-avatar.is-support { border-color: #2f62ff; background: #2f62ff; }
.consultation-agent-avatar.is-support img { padding: 10px; object-fit: contain; }
.consultation-agent-avatar.is-broker img { padding: 4px; object-fit: contain; background: #fff; }
.consultation-agent-avatar.is-broker b { color: #fff; background: linear-gradient(135deg, #102765, #2f62ff); width: 100%; height: 100%; display: grid; place-items: center; }
.consultation-inbox__hint { margin: 24px 12px 0; color: #8b9bb6; font-size: 13px; line-height: 20px; }
.consultation-chat { display: grid; grid-template-rows: 64px minmax(0, 1fr) auto 88px; min-width: 0; min-height: 0; background: #fbfcff; }
.consultation-suggest { padding: 18px 28px 20px; border-top: 1px solid #e8eef8; background: #fbfcff; }
.consultation-suggest[hidden] { display: none; }
.consultation-suggest > p { margin: 0 0 12px; color: #657796; font-size: 13px; line-height: 20px; }
.consultation-suggest__chips { display: flex; flex-wrap: wrap; gap: 8px; }
.consultation-suggest__chips button,
.consultation-suggest__chips a { display: inline-block; max-width: 100%; padding: 8px 14px; border: 1px solid #d5e1f4; border-radius: 999px; color: #1d2941; background: #fff; font-size: 13px; line-height: 18px; text-align: left; text-decoration: none; cursor: pointer; box-sizing: border-box; transition: border-color .15s ease, background .15s ease, color .15s ease; }
.consultation-suggest__chips button:hover,
.consultation-suggest__chips a:hover { border-color: #2f62ff; color: #2f62ff; background: #f3f7ff; }
.consultation-conversation .consultation-suggest { position: absolute; right: 31px; bottom: 128px; left: 31px; z-index: 2; padding: 0 0 16px; border: 0; background: transparent; }
.consultation-conversation .consultation-suggest > p { margin-bottom: 10px; }
.consultation-chat__agent { display: flex; flex-direction: row; align-items: center; justify-content: space-between; gap: 16px; padding: 0 28px; border-bottom: 1px solid #dfe7f4; background: #fff; }
.consultation-chat__agent > div { display: flex; flex-direction: column; justify-content: center; gap: 2px; min-width: 0; }
.consultation-chat__agent strong { max-width: 540px; overflow: hidden; color: #111a31; font-size: 15px; line-height: 22px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.consultation-chat__agent span { display: flex; align-items: center; gap: 6px; color: #657796; font-size: 12px; line-height: 18px; }
.consultation-chat__open { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; height: 36px; padding: 0 16px; border-radius: 18px; color: #fff; background: #09173c; font-size: 13px; line-height: 20px; font-weight: 600; white-space: nowrap; transition: background .18s ease, transform .18s ease; }
.consultation-chat__open:hover { color: #fff; background: #142a5c; transform: translateY(-1px); }
.consultation-chat__open[hidden] { display: none; }
.consultation-chat__messages { min-height: 0; overflow: hidden; background: #fbfcff; }
.consultation-chat__panel { width: 100%; height: 100%; overflow-y: auto; padding: 42px 28px; scrollbar-width: thin; }
.consultation-message-list { min-height: 100%; }
.consultation-hub-message { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; align-items: start; }
.consultation-hub-message > div { min-width: 0; }
.consultation-hub-message header { display: flex; align-items: center; gap: 26px; height: 22px; margin-bottom: 8px; }
.consultation-hub-message header strong { color: #111a31; font-size: 13px; line-height: 20px; font-weight: 700; }
.consultation-hub-message header time { color: #637594; font-size: 12px; line-height: 18px; }
.consultation-hub-bubble { width: min(500px, 100%); padding: 18px 20px; border: 1px solid #dce6f5; border-radius: 16px; color: #1d2941; background: #fff; box-shadow: 0 5px 18px rgba(20, 54, 110, .03); }
.consultation-hub-bubble p { font-size: 14px; line-height: 24px; }
.consultation-hub-bubble p + p { margin-top: 2px; }
.consultation-hub-message--outgoing { display: flex; flex-direction: column; align-items: flex-end; width: min(440px, 76%); margin: 28px 0 0 auto; }
.consultation-hub-message--outgoing header { margin-bottom: 8px; }
.consultation-hub-message--outgoing .consultation-hub-bubble { width: auto; min-width: 180px; max-width: 100%; border-color: #bed2ff; background: #eaf1ff; }
.consultation-hub-composer { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 106px; gap: 12px; align-items: center; padding: 16px 24px; border-top: 1px solid #dfe7f4; background: #fff; }
.consultation-hub-composer label { display: block; min-width: 0; }
.consultation-hub-composer input { width: 100%; height: 52px; padding: 0 18px; border: 1px solid #d5e1f4; border-radius: 14px; outline: none; color: #101a34; background: #f6f9ff; font-size: 14px; }
.consultation-hub-composer input::placeholder { color: #8a9bb6; opacity: 1; }
.consultation-hub-composer input:focus { border-color: #2f62ff; box-shadow: 0 0 0 3px rgba(47, 98, 255, .1); }
.consultation-hub-composer button { display: flex; align-items: center; justify-content: center; gap: 10px; width: 106px; height: 52px; border: 0; border-radius: 14px; color: #fff; background: #2f62ff; font-size: 15px; line-height: 22px; font-weight: 500; transition: background .18s ease, transform .18s ease; }
.consultation-hub-composer button:hover { background: #2454e8; transform: translateY(-1px); }
.consultation-hub-composer button img { width: 20px; height: 20px; }
[hidden].consultation-chat__panel { display: none; }
@media (max-width: 1120px) {
  .consultation-shell { width: calc(100% - 48px); }
  .consultation-workspace__inner { grid-template-columns: 320px minmax(0, 1fr); }
  .consultation-profile { padding-right: 12px; padding-left: 12px; }
  .consultation-open { width: 270px; }
  .consultation-messages { right: 32px; left: 32px; }
}
@media (max-width: 760px) {
  .consultation-hub__body { grid-template-columns: 240px minmax(0, 1fr); }
  .consultation-inbox__item { grid-template-columns: 40px minmax(0, 1fr); }
  .consultation-inbox__item time { display: none; }
  .consultation-agent-avatar { width: 40px; height: 40px; }
}
