/* SURFLOCAL_MEDIA_PRESENTATION_FIX2
 * Visible rules require the matching helper's readiness class. The original
 * style.css remains the usable fallback when this sheet or helper is absent.
 */
body.standalone:not(.embedded), body.embedded:not(.standalone) {
  --slmf2-assistant-css: 1;
}
body.slmf2-ready {
  --ink: #18304d;
  --soft: #536880;
  --blue: #245bcb;
  --line: #d3deec;
  color: #18304d;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
body.slmf2-ready :focus-visible { outline: 3px solid #237bd0; outline-offset: 3px; }
body.slmf2-ready #chat:focus { outline: none; }
body.slmf2-ready .slmf2-opening-welcome > .speaker {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
body.slmf2-ready .slmf2-opening-welcome > p { margin-top: 0; }
body.slmf2-ready #clear {
  min-height: 44px;
  border: 1px solid #c3d0e2;
  border-radius: 8px;
  padding: 7px 10px;
  background: #fff;
  color: #18304d;
  font-size: 12px;
  font-weight: 650;
  line-height: 1.4;
}
body.slmf2-ready .button {
  min-height: 44px;
  border-radius: 8px;
  background: #245bcb;
  color: #fff;
  text-shadow: none;
  font-size: 13px;
  line-height: 1.4;
}
body.slmf2-ready .button:hover { background: #1949aa; }
body.slmf2-ready .button.secondary { background: #234b7a; }
body.slmf2-ready .button.secondary:hover { background: #142d4c; }
body.slmf2-ready #question {
  box-sizing: border-box;
  width: 100%;
  border: 1px solid #acbdd3;
  border-radius: 10px;
  background: #fbfcfe;
  color: #18304d;
}
body.slmf2-ready #question::placeholder { color: #536880; opacity: 1; }
body.slmf2-ready .message { overflow-wrap: anywhere; }
body.slmf2-ready .privacy summary {
  cursor: pointer;
  min-height: 44px;
  font-weight: 650;
  color: #3f5873;
}

/* Full page: one document scroller, with the composer in ordinary flow. */
body.standalone.slmf2-standalone-ready:not(.embedded) {
  height: auto;
  min-height: 100vh;
  max-height: none;
  overflow: visible;
  background: #f2f5fa;
  font-size: 15px;
  line-height: 1.5;
}
body.standalone.slmf2-standalone-ready:not(.embedded) > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 14px;
  min-height: 64px;
  max-width: none;
  margin: 0;
  padding: 8px max(24px, calc((100% - 872px) / 2));
  border-bottom: 3px solid #eabf55;
  background: linear-gradient(115deg, #142d4c, #234b7a);
  color: #fff;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .brand {
  min-width: 0;
  gap: 10px;
  color: #fff;
  letter-spacing: 0;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .brand img {
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  object-fit: contain;
  background: #fff;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .brand .brand-name {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
  gap: 1px;
  margin: 0;
  font-size: 20px;
  line-height: 1.2;
  color: #fff;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .brand .brand-name > span {
  margin: 0;
  color: #dce7f6;
  font-size: 11px;
  line-height: 1.3;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .header-contact {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 7px 10px;
  border: 1px solid #6f88a8;
  border-radius: 8px;
  background: #fff;
  color: #18304d;
  font-size: 12px;
  line-height: 1.4;
}
body.standalone.slmf2-standalone-ready:not(.embedded) > main {
  display: block;
  width: 100%;
  max-width: 920px;
  height: auto;
  max-height: none;
  overflow: visible;
  margin: 0 auto;
  padding: 24px 24px 32px;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .intro {
  margin: 0 0 18px;
  padding: 0;
  max-width: none;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .intro .eyebrow,
body.standalone.slmf2-standalone-ready:not(.embedded) .intro .intro-points,
body.standalone.slmf2-standalone-ready:not(.embedded) .intro .intro-note,
body.standalone.slmf2-standalone-ready:not(.embedded) .intro h1 br { display: none; }
body.standalone.slmf2-standalone-ready:not(.embedded) .intro h1 {
  margin: 0 0 7px;
  color: #18304d;
  font-size: 28px;
  line-height: 1.25;
  letter-spacing: -.4px;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .intro h1 span { color: #18304d; }
body.standalone.slmf2-standalone-ready:not(.embedded) .intro h1 span::before { content: ' '; }
body.standalone.slmf2-standalone-ready:not(.embedded) .intro > p:not(.eyebrow):not(.intro-note) {
  max-width: none;
  margin: 0;
  color: #536880;
  font-size: 14px;
  line-height: 1.6;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .assistant {
  display: block;
  height: auto;
  min-height: 0;
  max-height: none;
  overflow: visible;
  border: 1px solid #d3deec;
  border-radius: 12px;
  box-shadow: 0 4px 18px #15365908;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .panel-head {
  gap: 8px;
  padding: 8px 16px;
  border-radius: 11px 11px 0 0;
  background: #fff;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .panel-head strong { font-size: 15px; }
body.standalone.slmf2-standalone-ready:not(.embedded) .panel-head span { font-size: 11px; }
body.standalone.slmf2-standalone-ready:not(.embedded):not(.lead-open) .next-steps {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 8px 16px;
  background: #f2f5fa;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .next-steps .text-button {
  min-width: 0;
  min-height: 44px;
  padding: 7px 8px;
  border-radius: 8px;
  font-size: 12px;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
body.slmf2-ready .next-steps .human-action > span { display: none; }
body.standalone.slmf2-standalone-ready:not(.embedded) #chat {
  height: auto;
  min-height: 0;
  max-height: none;
  padding: 14px 16px 0;
  overflow: visible;
  overscroll-behavior: auto;
  scrollbar-gutter: auto;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .message {
  padding: 12px 14px;
  margin-bottom: 12px;
  border: 1px solid #d3deec;
  border-radius: 12px;
  background: #fff;
  color: #18304d;
  font-size: 16px;
  line-height: 1.6;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .user-message { background: #eaf1fd; }
body.standalone.slmf2-standalone-ready:not(.embedded) .suggestions { padding: 4px 16px 12px; }
body.standalone.slmf2-standalone-ready:not(.embedded) .suggestions button { min-height: 44px; }
body.standalone.slmf2-standalone-ready:not(.embedded) #ask {
  position: static;
  height: auto;
  max-height: none;
  padding: 14px 16px 10px;
  overflow: visible;
  overflow-anchor: none;
  background: #fff;
}
body.standalone.slmf2-standalone-ready:not(.embedded) #ask > label {
  display: block;
  margin: 0 0 7px;
  font-size: 13px;
}
body.standalone.slmf2-standalone-ready:not(.embedded) #question {
  display: block;
  height: var(--slmf2-question-height, 144px);
  min-height: 144px;
  max-height: none;
  padding: 12px 14px;
  overflow: hidden;
  resize: none;
  font: 16px/1.6 system-ui, sans-serif;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .compose-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 10px;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .compose-bottom > span {
  max-width: none;
  font-size: 11px;
  line-height: 1.4;
}
body.standalone.slmf2-standalone-ready:not(.embedded) #send { flex: 0 0 auto; min-width: 88px; }
body.standalone.slmf2-standalone-ready:not(.embedded) #status { padding: 0 16px; }
body.standalone.slmf2-standalone-ready:not(.embedded) .request-shortcut {
  gap: 10px 16px;
  padding: 12px 16px;
  border-radius: 0 0 11px 11px;
  background: #f8fafd;
}
body.standalone.slmf2-standalone-ready:not(.embedded) .request-shortcut > div { min-width: 0; }
body.standalone.slmf2-standalone-ready:not(.embedded) .request-shortcut .button { width: auto; }
body.standalone.slmf2-standalone-ready:not(.embedded) .lead-panel {
  height: auto;
  max-height: none;
  overflow: visible;
  border-radius: 10px;
}
body.standalone.slmf2-standalone-ready:not(.embedded) > main > .privacy {
  margin: 18px 0;
  font-size: 12px;
  line-height: 1.6;
}
body.standalone.slmf2-standalone-ready:not(.embedded) > main > footer {
  margin-top: 18px;
  padding-top: 12px;
}
body.standalone.slmf2-standalone-ready:not(.embedded) footer a { min-height: 44px; }

/* Compact Media iframe: one content scroller above the original composer. */
body.embedded.slmf2-embedded-ready:not(.standalone) {
  height: 100dvh;
  min-height: 0;
  margin: 0;
  overflow: hidden;
  background: #fff;
  font-size: 14px;
  line-height: 1.5;
}
body.embedded.slmf2-embedded-ready:not(.standalone) > main {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  gap: 0;
  padding: 0;
  overflow: hidden;
}
body.embedded.slmf2-embedded-ready:not(.standalone) .assistant {
  display: flex;
  flex: 1 1 0;
  flex-direction: column;
  min-height: 0;
  height: 100%;
  overflow: hidden;
  border: 0;
  border-radius: 0;
}
body.embedded.slmf2-embedded-ready:not(.standalone) #slmf2-content {
  display: block;
  flex: 1 1 0;
  min-height: 0;
  max-height: none;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}
body.embedded.slmf2-embedded-ready:not(.standalone) #slmf2-dock {
  position: static;
  flex: 0 0 auto;
  min-width: 0;
  border-top: 1px solid #d3deec;
  background: #fff;
}
body.embedded.slmf2-embedded-ready:not(.standalone) .panel-head {
  display: flex;
  justify-content: flex-end;
  padding: 4px 10px;
  min-height: 0;
  border-bottom: 0;
}
body.embedded.slmf2-embedded-ready:not(.standalone) #clear { min-height: 44px; padding: 6px 9px; }
body.embedded.slmf2-embedded-ready:not(.standalone) #chat {
  flex: none;
  height: auto;
  min-height: 0;
  max-height: none;
  padding: 6px 10px 0;
  overflow: visible;
  overscroll-behavior: auto;
  scrollbar-gutter: auto;
}
body.embedded.slmf2-embedded-ready:not(.standalone) .message {
  padding: 10px 11px;
  margin-bottom: 10px;
  border: 1px solid #d3deec;
  border-radius: 10px;
  background: #f8fafd;
  font-size: 14px;
  line-height: 1.5;
}
body.embedded.slmf2-embedded-ready:not(.standalone) .user-message { background: #eaf1fd; }
body.embedded.slmf2-embedded-ready:not(.standalone) .suggestions {
  display: flex;
  flex-wrap: wrap;
  max-height: none;
  gap: 5px;
  padding: 4px 10px 8px;
  overflow: visible;
}
body.embedded.slmf2-embedded-ready:not(.standalone) .assistant:has(.user-message) .suggestions { display: none; }
body.embedded.slmf2-embedded-ready:not(.standalone) .suggestions button {
  min-height: 44px;
  padding: 7px 9px;
  font-size: 11px;
  line-height: 1.4;
}
body.embedded.slmf2-embedded-ready:not(.standalone) #ask {
  flex: none;
  padding: 7px 10px 6px;
  border-top: 0;
}
body.embedded.slmf2-embedded-ready:not(.standalone) #ask > label {
  display: block;
  margin: 0 0 4px;
  font-size: 11px;
  line-height: 1.3;
}
body.embedded.slmf2-embedded-ready:not(.standalone) #question {
  display: block;
  height: 54px;
  min-height: 54px;
  max-height: 54px;
  padding: 6px 9px;
  overflow-y: auto;
  resize: none;
  font: 16px/1.25 system-ui, sans-serif;
}
body.embedded.slmf2-embedded-ready:not(.standalone) .compose-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 5px;
}
body.embedded.slmf2-embedded-ready:not(.standalone) .compose-bottom > span {
  display: block;
  max-width: 150px;
  color: #536880;
  font-size: 10px;
  line-height: 1.35;
}
body.embedded.slmf2-embedded-ready:not(.standalone) #send { min-height: 44px; padding: 7px 13px; }
body.embedded.slmf2-embedded-ready:not(.standalone) #status {
  padding: 0 10px;
  margin: 0 0 6px;
  font-size: 12px;
  overflow-wrap: anywhere;
}
body.embedded.slmf2-embedded-ready:not(.standalone) #status:empty { display: none; }
body.embedded.slmf2-embedded-ready:not(.standalone) .request-shortcut {
  display: flex;
  padding: 6px 10px;
}
body.embedded.slmf2-embedded-ready:not(.standalone) .request-shortcut .button {
  width: 100%;
  min-height: 44px;
  font-size: 11px;
}
body.embedded.slmf2-embedded-ready:not(.standalone) .privacy {
  display: block;
  height: auto;
  max-height: none;
  margin: 0;
  padding: 0 10px 5px;
  border-top: 1px solid #d3deec;
  overflow: visible;
  font-size: 11px;
  line-height: 1.5;
}
body.embedded.slmf2-embedded-ready:not(.standalone) .privacy summary {
  min-height: 44px;
  padding: 12px 0;
  font-size: 11px;
}
body.embedded.slmf2-embedded-ready:not(.standalone) .privacy p { font-size: 11px; }
/* Enabled only after the helper verifies both corresponding outer links. */
body.embedded.slmf2-embedded-ready:not(.standalone) > main > footer { display: none; }
body.embedded.slmf2-embedded-ready:not(.standalone).lead-open #slmf2-content,
body.embedded.slmf2-embedded-ready:not(.standalone).lead-open #slmf2-dock { display: none; }
body.embedded.slmf2-embedded-ready:not(.standalone).lead-open .lead-panel {
  display: block;
  flex: 1 1 0;
  min-height: 0;
  max-height: none;
  margin: 0;
  padding: 12px;
  border: 0;
  border-radius: 0;
  overflow-y: auto;
}
body.embedded.slmf2-embedded-ready:not(.standalone) .lead-panel form { padding: 0; }
body.embedded.slmf2-embedded-ready:not(.standalone) .lead-panel label { display: block; }
body.embedded.slmf2-embedded-ready:not(.standalone) .lead-panel label.consent { display: flex; }
body.embedded.slmf2-embedded-ready:not(.standalone) .lead-panel textarea { min-height: 90px; }

@media (max-width: 600px) {
  body.standalone.slmf2-standalone-ready:not(.embedded) > header { padding: 8px 16px; }
  body.standalone.slmf2-standalone-ready:not(.embedded) > main { padding: 20px 12px 28px; }
  body.standalone.slmf2-standalone-ready:not(.embedded) .intro h1 { font-size: 25px; }
  body.standalone.slmf2-standalone-ready:not(.embedded) #question {
    min-height: 128px;
    height: var(--slmf2-question-height, 128px);
  }
  body.standalone.slmf2-standalone-ready:not(.embedded) .panel-head,
  body.standalone.slmf2-standalone-ready:not(.embedded) #ask { padding-inline: 12px; }
  body.standalone.slmf2-standalone-ready:not(.embedded) .next-steps { padding-inline: 12px; }
  body.standalone.slmf2-standalone-ready:not(.embedded) .request-shortcut { flex-wrap: wrap; }
  body.standalone.slmf2-standalone-ready:not(.embedded) .request-shortcut .button { width: 100%; }
}
@media (hover: hover) and (pointer: fine) {
  body.embedded.slmf2-embedded-ready:not(.standalone) #question { font-size: 14px; }
}
/* Very short viewports (for example an open phone keyboard) cannot fit a
 * fixed composer plus content. Keep all original controls reachable through
 * one iframe document scroller instead of clipping the writing area. */
@media (max-height: 240px) {
  body.embedded.slmf2-embedded-ready:not(.standalone) { overflow-y: auto; }
  body.embedded.slmf2-embedded-ready:not(.standalone) > main { height: auto; overflow: visible; }
  body.embedded.slmf2-embedded-ready:not(.standalone) .assistant {
    display: block;
    height: auto;
    min-height: 100dvh;
    overflow: visible;
  }
  body.embedded.slmf2-embedded-ready:not(.standalone) #slmf2-content {
    height: auto;
    overflow: visible;
  }
  body.embedded.slmf2-embedded-ready:not(.standalone).lead-open .lead-panel {
    height: auto;
    overflow: visible;
  }
}
@media (prefers-reduced-motion: reduce) {
  body.slmf2-ready * { scroll-behavior: auto !important; }
}
