.bubble-wrap:has(.privacy-policy-chat-bubble) {
  width: min(860px, calc(100vw - 120px));
  max-width: min(88%, 860px);
}

.privacy-policy-chat-bubble.bubble.ai {
  width: 100%;
  padding: 0;
  overflow: hidden;
  border-radius: 8px;
  white-space: normal;
}

.pp-chat {
  width: 100%;
  color: #172033;
  background: #fff;
}

.pp-chat svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pp-chat__header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 20px;
  border-bottom: 1px solid #e7ebf0;
  background: #f8fafb;
}

.pp-chat__mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  color: #087f72;
  border: 1px solid #b9ddd7;
  border-radius: 8px;
  background: #eaf6f3;
}

.pp-chat__mark svg { width: 20px; height: 20px; }
.pp-chat__header h3 { margin: 0; font-size: 15px; line-height: 1.3; font-weight: 650; letter-spacing: 0; }
.pp-chat__header p { margin: 3px 0 0; color: #667085; font-size: 12.5px; line-height: 1.4; }

.pp-chat__picker { padding: 16px 20px 20px; }
.pp-chat__search { position: relative; display: block; }
.pp-chat__search svg { position: absolute; top: 50%; left: 12px; width: 16px; height: 16px; color: #7a8494; transform: translateY(-50%); }
.pp-chat__search input {
  width: 100%;
  height: 40px;
  padding: 0 12px 0 38px;
  color: #172033;
  font: inherit;
  font-size: 13px;
  border: 1px solid #d8dee7;
  border-radius: 6px;
  outline: none;
  background: #fff;
}
.pp-chat__search input:focus { border-color: #159487; box-shadow: 0 0 0 3px rgba(21, 148, 135, .11); }

.pp-chat__customer-list {
  max-height: 290px;
  margin-top: 10px;
  overflow: auto;
  border: 1px solid #e2e7ed;
  border-radius: 6px;
  background: #fff;
}

.pp-chat__customer {
  width: 100%;
  min-height: 54px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 22px;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  color: inherit;
  text-align: left;
  border: 0;
  border-bottom: 1px solid #eef1f4;
  background: #fff;
  cursor: pointer;
}
.pp-chat__customer:last-child { border-bottom: 0; }
.pp-chat__customer:hover { background: #f7faf9; }
.pp-chat__customer.is-selected { background: #edf8f5; }
.pp-chat__customer-avatar { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; color: #087f72; background: #dff1ed; font-size: 12px; font-weight: 700; }
.pp-chat__customer > span:nth-child(2) { min-width: 0; }
.pp-chat__customer strong, .pp-chat__customer small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pp-chat__customer strong { font-size: 12.75px; font-weight: 600; }
.pp-chat__customer small { margin-top: 2px; color: #748092; font-size: 11.5px; }
.pp-chat__customer i { display: none; color: #087f72; }
.pp-chat__customer.is-selected i { display: block; }
.pp-chat__customer i svg { width: 17px; height: 17px; }
.pp-chat__no-results, .pp-chat__empty { padding: 24px; color: #6b7585; text-align: center; font-size: 12.5px; }

.pp-chat__selection {
  display: grid;
  gap: 12px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #e7ebf0;
}
.pp-chat__selection[hidden] { display: none; }
.pp-chat__selection-head { min-width: 0; }
.pp-chat__selection-head > span, .pp-chat__selection-head strong, .pp-chat__selection-head small { display: block; }
.pp-chat__selection-head > span { color: #7b8492; font-size: 10.5px; text-transform: uppercase; }
.pp-chat__selection-head strong { margin-top: 2px; font-size: 12.75px; font-weight: 650; }
.pp-chat__selection-head small { margin-top: 2px; color: #748092; font-size: 11.5px; overflow-wrap: anywhere; }
.pp-chat__website-choice { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.pp-chat__website-option {
  min-width: 0;
  display: grid;
  grid-template-columns: 17px minmax(0, 1fr);
  align-items: start;
  gap: 9px;
  padding: 11px;
  border: 1px solid #dfe5eb;
  border-radius: 7px;
  background: #fff;
  cursor: pointer;
}
.pp-chat__website-option:has(input[type="radio"]:checked) { border-color: #72b9ad; background: #f2faf8; box-shadow: 0 0 0 2px rgba(21, 148, 135, .08); }
.pp-chat__website-option.is-disabled { color: #98a1ae; background: #f8f9fa; cursor: default; }
.pp-chat__website-option > input[type="radio"] { width: 15px; height: 15px; margin: 2px 0 0; accent-color: #178f82; }
.pp-chat__website-option > span { min-width: 0; }
.pp-chat__website-option > span strong, .pp-chat__website-option > span small { display: block; }
.pp-chat__website-option > span strong { font-size: 11.5px; font-weight: 650; }
.pp-chat__website-option > span small { margin-top: 3px; overflow: hidden; color: #748092; font-size: 10.5px; text-overflow: ellipsis; white-space: nowrap; }
.pp-chat__website-option--custom { grid-template-columns: 17px minmax(0, 1fr); }
.pp-chat__custom-url {
  grid-column: 2;
  width: 100%;
  min-width: 0;
  height: 33px;
  box-sizing: border-box;
  margin-top: 7px;
  padding: 0 9px;
  color: #202939;
  font: inherit;
  font-size: 11.5px;
  border: 1px solid #ccd6df;
  border-radius: 5px;
  outline: none;
  background: #fff;
}
.pp-chat__custom-url:focus { border-color: #159487; box-shadow: 0 0 0 3px rgba(21, 148, 135, .1); }
.pp-chat__custom-url:disabled { display: none; }
.pp-chat__selection-actions { display: flex; justify-content: flex-end; }
.pp-chat__start svg:last-child { width: 14px; height: 14px; }

.pp-chat__scan { display: flex; align-items: center; gap: 14px; margin: 22px 20px 16px; padding: 16px; border: 1px solid #dce5e8; border-radius: 6px; background: #f8fbfa; }
.pp-chat__scan strong, .pp-chat__scan span { display: block; }
.pp-chat__scan strong { font-size: 12.75px; font-weight: 600; }
.pp-chat__scan span { margin-top: 3px; color: #6d7888; font-size: 11.75px; line-height: 1.45; }
.pp-chat__spinner { width: 24px; height: 24px; flex: 0 0 24px; border: 2px solid #c9ddd9; border-top-color: #087f72; border-radius: 50%; animation: pp-spin .8s linear infinite; }
@keyframes pp-spin { to { transform: rotate(360deg); } }
.pp-chat__scan-lines { display: grid; gap: 7px; padding: 0 20px 22px; }
.pp-chat__scan-lines i { display: block; height: 7px; border-radius: 3px; background: #edf0f3; animation: pp-pulse 1.2s ease-in-out infinite; }
.pp-chat__scan-lines i:nth-child(2) { width: 82%; animation-delay: .12s; }
.pp-chat__scan-lines i:nth-child(3) { width: 60%; animation-delay: .24s; }
@keyframes pp-pulse { 50% { opacity: .45; } }

.pp-chat__result-summary { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(220px, .85fr); align-items: start; gap: 10px; padding: 16px 20px 10px; }
.pp-chat__progress-summary, .pp-chat__scan-summary { min-height: 60px; box-sizing: border-box; border: 1px solid #e0e6eb; border-radius: 6px; background: #fafbfc; }
.pp-chat__progress-summary { padding: 10px 12px; }
.pp-chat__progress-summary > div { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.pp-chat__progress-summary span, .pp-chat__progress-summary small, .pp-chat__progress-summary strong { display: block; }
.pp-chat__progress-summary small, .pp-chat__scan-summary small { color: #7a8493; font-size: 9.5px; font-weight: 600; line-height: 1.2; text-transform: uppercase; }
.pp-chat__progress-summary strong { margin-top: 3px; color: #344054; font-size: 12px; font-weight: 600; }
.pp-chat__progress-summary strong b { color: inherit; font-weight: 700; }
.pp-chat__progress-summary em { color: #087f72; font-size: 15px; font-style: normal; font-weight: 700; }
.pp-chat__progress-summary > i { display: block; height: 5px; margin-top: 9px; overflow: hidden; border-radius: 3px; background: #e4e9ec; }
.pp-chat__progress-summary > i > span { display: block; height: 100%; border-radius: inherit; background: #178f82; transition: width .2s ease; }
.pp-chat__scan-summary { position: relative; color: #344054; }
.pp-chat__scan-summary > summary { min-height: 58px; display: grid; grid-template-columns: 30px minmax(0, 1fr) 16px; align-items: center; gap: 9px; padding: 0 11px; cursor: pointer; list-style: none; }
.pp-chat__scan-summary > summary::-webkit-details-marker { display: none; }
.pp-chat__scan-summary > summary > svg:first-child { width: 19px; height: 19px; color: #087f72; }
.pp-chat__scan-summary > summary > svg:last-child { width: 14px; height: 14px; color: #8993a3; transition: transform .15s ease; }
.pp-chat__scan-summary[open] > summary > svg:last-child { transform: rotate(90deg); }
.pp-chat__scan-summary summary span, .pp-chat__scan-summary summary strong, .pp-chat__scan-summary summary small { display: block; }
.pp-chat__scan-summary summary strong { margin-top: 3px; font-size: 12px; font-weight: 650; }
.pp-chat__scan-summary.is-warning { display: flex; align-items: center; gap: 9px; padding: 10px 12px; color: #835d13; border-color: #eadba8; background: #fffaf0; }
.pp-chat__page-list { max-height: 210px; overflow: auto; border-top: 1px solid #e6eaef; background: #fff; }
.pp-chat__page-list > a { display: grid; grid-template-columns: 24px minmax(0, 1fr) 15px; align-items: center; gap: 8px; padding: 9px 11px; color: #344054; text-decoration: none; border-bottom: 1px solid #eef1f4; }
.pp-chat__page-list > a:last-child { border-bottom: 0; }
.pp-chat__page-list > a:hover { background: #f5faf8; }
.pp-chat__page-list > a.is-excluded { background: #fafafa; }
.pp-chat__page-list > a.is-excluded strong { color: #7a5a13; }
.pp-chat__page-list i { color: #8a94a3; font-size: 9px; font-style: normal; }
.pp-chat__page-list span { min-width: 0; }
.pp-chat__page-list strong, .pp-chat__page-list small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pp-chat__page-list strong { font-size: 10.75px; font-weight: 600; }
.pp-chat__page-list small { margin-top: 2px; color: #7c8797; font-size: 9.75px; }
.pp-chat__page-list svg { width: 13px; height: 13px; color: #778294; }
.pp-chat__notice { margin: 0 20px 16px; padding: 10px 12px; color: #5e6877; font-size: 11.75px; line-height: 1.45; border-left: 3px solid #79b8ae; background: #f6f9f9; }
.pp-chat__case-result { display: none; align-items: center; gap: 9px; margin: 0 20px 14px; padding: 10px 12px; color: #175e55; border: 1px solid #bfe0da; border-radius: 6px; background: #f0faf7; }
.pp-chat__case-result.is-visible { display: flex; }
.pp-chat__case-result > svg { width: 17px; height: 17px; flex: 0 0 17px; }
.pp-chat__case-result span, .pp-chat__case-result strong, .pp-chat__case-result small { display: block; }
.pp-chat__case-result strong { font-size: 11.75px; font-weight: 650; }
.pp-chat__case-result small { margin-top: 2px; color: #52746f; font-size: 10.75px; line-height: 1.4; }

.pp-chat__form { border-top: 1px solid #e7ebf0; }
.pp-chat__section { padding: 18px 20px; border-bottom: 1px solid #e7ebf0; }
.pp-chat__section > header { display: flex; align-items: center; gap: 9px; margin-bottom: 14px; }
.pp-chat__section > header > span { color: #8791a1; font-size: 10px; font-weight: 650; }
.pp-chat__section h4 { margin: 0; font-size: 13.5px; font-weight: 650; letter-spacing: 0; }
.pp-chat__fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px 14px; }
.pp-chat__field { display: flex; flex-direction: column; min-width: 0; }
.pp-chat__field:has(textarea), .pp-chat__field:has(.pp-chat__checklist) { grid-column: 1 / -1; }
.pp-chat__field-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; min-height: 23px; margin-bottom: 5px; }
.pp-chat__field-head strong { color: #465164; font-size: 11.5px; line-height: 1.35; font-weight: 600; }
.pp-chat__source { flex: 0 0 auto; padding: 2px 6px; border-radius: 4px; font-size: 9.5px; line-height: 1.35; font-style: normal; font-weight: 600; }
.pp-chat__source--website { color: #0b6b61; background: #ddf2ed; }
.pp-chat__source--customer { color: #285f9e; background: #e5effb; }
.pp-chat__source--manual { color: #6953a5; background: #eeeafb; }
.pp-chat__source--open { color: #7a5a13; background: #f8edce; }
.pp-chat__field input, .pp-chat__field textarea, .pp-chat__field select {
  width: 100%;
  min-height: 37px;
  box-sizing: border-box;
  padding: 8px 10px;
  color: #202939;
  font: inherit;
  font-size: 12px;
  line-height: 1.45;
  border: 1px solid #d7dde5;
  border-radius: 5px;
  outline: none;
  background: #fff;
}
.pp-chat__field textarea { min-height: 76px; resize: vertical; }
.pp-chat__field input:focus, .pp-chat__field textarea:focus, .pp-chat__field select:focus { border-color: #159487; box-shadow: 0 0 0 3px rgba(21, 148, 135, .10); }
.pp-chat__checklist {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  overflow: hidden;
  border: 1px solid #d7dde5;
  border-radius: 5px;
  background: #fff;
}
.pp-chat__check-option {
  min-height: 38px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 10px;
  box-sizing: border-box;
  color: #344054;
  font-size: 11.5px;
  line-height: 1.35;
  border-bottom: 1px solid #edf0f3;
  cursor: pointer;
}
.pp-chat__check-option:nth-child(odd) { border-right: 1px solid #edf0f3; }
.pp-chat__check-option:nth-last-child(-n + 2) { border-bottom: 0; }
.pp-chat__check-option:hover { background: #f7faf9; }
.pp-chat__check-option input[type="checkbox"] {
  width: 16px;
  height: 16px;
  min-height: 0;
  flex: 0 0 16px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 3px;
  box-shadow: none;
  accent-color: #178f82;
}
.pp-chat__check-option input[type="checkbox"]:focus-visible { outline: 2px solid rgba(21, 148, 135, .25); outline-offset: 2px; }
.pp-chat__evidence { margin-top: 5px; color: #667085; font-size: 10.5px; }
.pp-chat__evidence summary { display: inline-flex; align-items: center; gap: 4px; cursor: pointer; list-style: none; }
.pp-chat__evidence summary::-webkit-details-marker { display: none; }
.pp-chat__evidence summary svg { width: 12px; height: 12px; }
.pp-chat__evidence summary svg:last-child { margin-left: 1px; transition: transform .15s ease; }
.pp-chat__evidence[open] summary svg:last-child { transform: rotate(90deg); }
.pp-chat__evidence > div { display: grid; gap: 6px; margin-top: 6px; }
.pp-chat__evidence-item { padding: 8px 9px; border-left: 2px solid #78b8ad; background: #f7faf9; }
.pp-chat__evidence-item strong { display: block; color: #3f4a5c; font-size: 10.5px; font-weight: 650; }
.pp-chat__evidence-item p { margin: 3px 0 0; color: #667085; font-size: 10.25px; line-height: 1.4; }
.pp-chat__evidence-item a { display: flex; align-items: center; gap: 5px; min-width: 0; margin-top: 5px; color: #087f72; text-decoration: none; }
.pp-chat__evidence-item a span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pp-chat__evidence-item a svg { flex: 0 0 11px; width: 11px; height: 11px; }
.pp-chat__footer { display: flex; align-items: center; justify-content: flex-end; gap: 12px; padding: 14px 20px 18px; background: #fafbfc; }
.pp-chat__primary-slot { display: contents; }
.pp-chat__save-state { margin-right: auto; color: #778294; font-size: 11px; }
.pp-chat__save-state.is-saved { display: inline-flex; align-items: center; gap: 5px; color: #087f72; font-weight: 600; }
.pp-chat__save-state.is-saved svg { width: 14px; height: 14px; }
.pp-chat__footer button svg, .pp-chat__footer a svg, .pp-chat__retry svg { width: 14px; height: 14px; }
.pp-chat__empty { display: flex; flex-direction: column; align-items: center; gap: 13px; }

@media (max-width: 720px) {
  .bubble-wrap:has(.privacy-policy-chat-bubble) { width: calc(100vw - 70px); max-width: calc(100vw - 70px); }
  .pp-chat__header, .pp-chat__picker, .pp-chat__section { padding-left: 14px; padding-right: 14px; }
  .pp-chat__fields { grid-template-columns: 1fr; }
  .pp-chat__field:has(textarea), .pp-chat__field:has(.pp-chat__checklist) { grid-column: auto; }
  .pp-chat__checklist { grid-template-columns: 1fr; }
  .pp-chat__check-option, .pp-chat__check-option:nth-child(odd), .pp-chat__check-option:nth-last-child(-n + 2) { border-right: 0; border-bottom: 1px solid #edf0f3; }
  .pp-chat__check-option:last-child { border-bottom: 0; }
  .pp-chat__result-summary { grid-template-columns: 1fr; padding-left: 14px; padding-right: 14px; }
  .pp-chat__notice { margin-left: 14px; margin-right: 14px; }
  .pp-chat__website-choice { grid-template-columns: 1fr; }
  .pp-chat__selection-actions { justify-content: stretch; }
  .pp-chat__selection-actions .pp-chat__start { width: 100%; justify-content: center; }
  .pp-chat__case-result { margin-left: 14px; margin-right: 14px; }
  .pp-chat__footer { align-items: stretch; flex-wrap: wrap; }
  .pp-chat__save-state { width: 100%; margin-right: 0; }
}
