/* Ask Lighthouse: bottom bar, closable to a circle; the conversation opens as a bubble above the bar (see ask-chat.js) */
.lt-dock { position: fixed; left: 50%; bottom: 14px; transform: translateX(-50%); width: min(760px, calc(100vw - 20px)); z-index: 9999; display: flex; flex-direction: column; gap: 8px; color: var(--ink, #1E3A4C); font: 15px/1.5 var(--ui, system-ui, sans-serif); }
.lt-dock[hidden] { display: none; }
.lt-ask-bar { position: relative; background: var(--surface, #fff); border: 1.5px solid var(--ink, #1E3A4C); border-radius: 18px; padding: 12px 14px 8px; box-shadow: 0 12px 36px rgb(30 58 76 / .22); }
.lt-ask-form { display: flex; gap: 10px; align-items: flex-end; padding-right: 26px; }
.lt-ask-form textarea { flex: 1; resize: none; min-height: 54px; max-height: 140px; font: 16px/1.45 var(--ui, sans-serif); padding: 11px 14px; border: 1px solid var(--line, #DDD6C8); border-radius: 12px; background: var(--bg, #F6F3EC); color: var(--ink, #1E3A4C); }
.lt-ask-form textarea:focus { outline: 2px solid var(--sage, #3D6B66); outline-offset: 0; border-color: transparent; }
.lt-ask-send { flex: none; width: 46px; height: 46px; border-radius: 50%; border: 0; background: var(--ink, #1E3A4C); color: var(--bg, #F6F3EC); font-size: 20px; cursor: pointer; }
.lt-ask-x { position: absolute; top: 4px; right: 6px; background: none; border: 0; color: var(--ink-soft, #4A5A66); font-size: 22px; line-height: 1; padding: 4px 6px; cursor: pointer; }
.lt-ask-row { display: flex; flex-wrap: wrap; gap: 4px 14px; align-items: baseline; margin-top: 6px; }
.lt-ask-quick { background: none; border: 0; padding: 0; font: 600 13.5px var(--ui, sans-serif); color: var(--sage, #3D6B66); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.lt-ask-fine { font-size: 11.5px; color: var(--ink-soft, #4A5A66); }
.lt-ask-fine a { color: inherit; }
.lt-ask-chat { background: var(--bg, #F6F3EC); border: 1.5px solid var(--ink, #1E3A4C); border-radius: 18px; overflow: hidden; display: flex; flex-direction: column; max-height: min(58vh, 560px); box-shadow: 0 12px 36px rgb(30 58 76 / .22); }
.lt-ask-chat[hidden] { display: none; }
.lt-ask-head { display: flex; justify-content: space-between; align-items: center; padding: 8px 14px; background: var(--ink, #1E3A4C); color: var(--bg, #F6F3EC); }
.lt-ask-title { font: 500 16px var(--display, Georgia, serif); }
.lt-ask-min { background: none; border: 0; color: inherit; font-size: 20px; line-height: 1; cursor: pointer; padding: 0 4px; }
.lt-ask-log { overflow-y: auto; padding: 12px 14px; display: flex; flex-direction: column; gap: 10px; position: relative; }
.lt-ask-msg p { margin: 0 0 6px; }
.lt-ask-msg p:last-child { margin-bottom: 0; }
.lt-ask-me { align-self: flex-end; max-width: 85%; background: var(--ink, #1E3A4C); color: var(--bg, #F6F3EC); padding: 7px 12px; border-radius: 14px 14px 4px 14px; white-space: pre-wrap; }
.lt-ask-notice { font-size: 12.5px !important; color: var(--ink-soft, #4A5A66); border-left: 3px solid var(--sage, #3D6B66); padding: 1px 0 1px 9px; }
.lt-ask-crisis { font-weight: 700; color: #8a2a1a; }
.lt-ask-wait { color: var(--ink-soft, #4A5A66); font-style: italic; }
.lt-ask-card { display: block; margin: 5px 0; padding: 7px 10px; border: 1px solid var(--line, #DDD6C8); border-radius: 10px; background: var(--surface, #fff); color: var(--ink, #1E3A4C); text-decoration: none; }
.lt-ask-card:hover { border-color: var(--ink, #1E3A4C); }
.lt-ask-t { display: block; font: 600 13.5px/1.3 var(--ui, sans-serif); }
.lt-ask-card:hover .lt-ask-t { color: var(--sage, #3D6B66); }
.lt-ask-q { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 2px; font: 12.5px/1.45 var(--ui, sans-serif); color: var(--ink-soft, #4A5A66); }
.lt-ask-more { font-size: 12.5px; color: var(--ink-soft, #4A5A66); margin-top: 6px !important; }
.lt-ask-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.lt-ask-chips button { font: 500 12.5px var(--ui, sans-serif); text-align: left; padding: 5px 10px; border-radius: 999px; border: 1.5px solid var(--ink, #1E3A4C); background: var(--bg, #F6F3EC); color: var(--ink, #1E3A4C); cursor: pointer; }
.lt-ask-chips button:hover, .lt-ask-chips button.on { background: var(--ink, #1E3A4C); color: var(--bg, #F6F3EC); }
.lt-ask-next { font: 600 13px var(--ui, sans-serif); padding: 6px 16px; border-radius: 999px; border: 0; background: var(--sage, #3D6B66); color: #fff; cursor: pointer; }
.lt-ask-sr { position: absolute; left: -9999px; }
.lt-ask-cta { display: none; }
.lt-ask-fab { position: fixed; right: 16px; bottom: 16px; z-index: 9998; width: 54px; height: 54px; border-radius: 50%; border: 0; background: var(--ink, #1E3A4C); color: var(--bg, #F6F3EC); box-shadow: 0 8px 24px rgb(30 58 76 / .3); cursor: pointer; display: grid; place-items: center; font: 700 22px var(--ui, sans-serif); }
.lt-ask-fab[hidden] { display: none !important; }
body.lt-has-dock { padding-bottom: 150px; }
@media (max-width: 600px) {
  .lt-dock { bottom: 8px; width: calc(100vw - 16px); }
  /* Closed: a friendly tap target, no text box */
  .lt-ask-bar { padding: 0; border-radius: 20px; border: 0; background: linear-gradient(135deg, #1E3A4C 0%, #2B5160 60%, #3D6B66 100%); box-shadow: 0 14px 34px rgb(30 58 76 / .35), inset 0 1px 0 rgb(255 255 255 / .08); }
  .lt-ask-cta { display: flex; gap: 12px; align-items: center; width: 100%; text-align: left; padding: 15px 40px 15px 14px; background: none; border: 0; color: #F6F3EC; cursor: pointer; font: 13.5px/1.4 var(--ui, sans-serif); }
  .lt-ask-cta-i { flex: none; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; background: #F6F3EC; box-shadow: 0 0 0 4px rgb(246 243 236 / .18); }
  .lt-ask-cta-i img { display: block; width: 34px; height: 34px; }
  .lt-ask-cta-t { flex: 1; }
  .lt-ask-cta-t strong { display: block; font: 500 18px/1.25 var(--display, Georgia, serif); margin-bottom: 3px; color: #fff; }
  .lt-ask-cta-t span { color: rgb(246 243 236 / .85); }
  .lt-ask-cta-go { flex: none; align-self: center; font: 700 13px var(--ui, sans-serif); color: #1E3A4C; background: #E9C27A; padding: 7px 11px; border-radius: 999px; }
  .lt-ask-form, .lt-ask-row { display: none; }
  .lt-ask-x { top: 4px; transform: none; right: 4px; color: rgb(246 243 236 / .7); font-size: 18px; }
  body.lt-has-dock { padding-bottom: 110px; }
  .lt-dock.open .lt-ask-cta { display: none; }
  .lt-dock.open .lt-ask-bar { background: var(--surface, #fff); border-color: var(--ink, #1E3A4C); }
  .lt-dock.open .lt-ask-form { display: flex; }
  .lt-dock.open .lt-ask-x { color: var(--ink-soft, #4A5A66); }
  /* Open: a large bubble, most of the screen, still floating */
  .lt-dock.open { top: 10px; bottom: 8px; }
  .lt-dock.open .lt-ask-chat { flex: 1; max-height: none; min-height: 0; }
  .lt-dock.open .lt-ask-bar { border-radius: 18px; padding: 10px 10px 6px; }
  .lt-dock.open .lt-ask-form textarea { height: auto; min-height: 48px; border-radius: 12px; }
  .lt-dock.open .lt-ask-row { display: flex; }
  .lt-dock.open .lt-ask-x { top: 4px; transform: none; }
  .lt-ask-fine { font-size: 10.5px; }
}
/* Desktop: a standard chat panel in the lower right; closed, it's an "Ask Lighthouse" button */
@media (min-width: 601px) {
  .lt-dock { left: auto; right: 18px; bottom: 18px; transform: none; width: min(420px, calc(100vw - 36px)); height: min(620px, calc(100vh - 36px)); gap: 0; }
  .lt-dock .lt-ask-chat { flex: 1; max-height: none; min-height: 0; border-radius: 18px 18px 0 0; border-bottom: 0; box-shadow: none; }
  .lt-dock .lt-ask-bar { border-radius: 0 0 18px 18px; box-shadow: 0 18px 50px rgb(30 58 76 / .25); padding: 10px 12px 6px; }
  .lt-dock .lt-ask-x { display: none; }
  .lt-dock .lt-ask-form { padding-right: 0; }
  .lt-ask-fab { width: auto; height: auto; border-radius: 999px; padding: 11px 18px 11px 12px; gap: 8px; display: inline-flex; align-items: center; font: 600 15px var(--ui, sans-serif); }
  .lt-ask-fab-i { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--bg, #F6F3EC); color: var(--ink, #1E3A4C); font-weight: 700; }
  body.lt-has-dock { padding-bottom: 0; }
}
@media (max-width: 600px) { .lt-ask-fab-t { position: absolute; left: -9999px; } .lt-ask-fab-i { font-size: 22px; } }

/* Set the chat apart from the page without shouting: a soft sage-tinted body, white reply bubbles, a deeper header */
.lt-ask-chat { background: #E9F0EE; border-color: #2F5A62; box-shadow: 0 16px 44px rgb(30 58 76 / .28); }
.lt-ask-head { background: linear-gradient(135deg, #1E3A4C 0%, #2B5160 65%, #3D6B66 100%); padding: 10px 14px; }
.lt-ask-head .lt-ask-title::before { content: ""; display: inline-block; width: 22px; height: 22px; margin: 0 8px -5px 0; border-radius: 50%; background: #F6F3EC url(/assets/email/logo.png) center / 18px no-repeat; }
.lt-ask-bot { background: #fff; border: 1px solid #D5E1DE; border-radius: 4px 14px 14px 14px; padding: 9px 12px; box-shadow: 0 1px 2px rgb(30 58 76 / .06); }
.lt-ask-bot .lt-ask-card { background: #F6F3EC; }
.lt-ask-bar { border-color: #2F5A62; }
.lt-dock.open .lt-ask-bar { background: #fff; }
.lt-ask-fab { background: linear-gradient(135deg, #1E3A4C 0%, #2B5160 65%, #3D6B66 100%); }

.lt-ask-label { margin: 10px 0 -2px !important; font: 700 10.5px var(--ui, sans-serif); letter-spacing: .08em; text-transform: uppercase; color: var(--sage, #3D6B66); }
.lt-ask-first { border-color: #2F5A62; border-width: 1.5px; }
.lt-ask-refine { margin-top: 12px !important; font-weight: 600; }

.lt-ask-quickbar { display: flex; justify-content: space-between; align-items: center; gap: 10px; width: 100%; margin: 0 0 8px; padding: 9px 12px; border: 1px solid #C9DAD6; border-radius: 12px; background: #E9F0EE; color: var(--ink, #1E3A4C); text-align: left; cursor: pointer; font: 13px/1.35 var(--ui, sans-serif); }
.lt-ask-quickbar span { color: var(--ink-soft, #4A5A66); }
.lt-ask-quickbar strong { color: var(--sage, #3D6B66); white-space: nowrap; font-weight: 700; }
.lt-ask-quickbar:hover { border-color: var(--sage, #3D6B66); }
.lt-dock.quick-used .lt-ask-quickbar { display: none; }
@media (max-width: 600px) { .lt-ask-quickbar { display: none; } .lt-dock.open .lt-ask-quickbar { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; } .lt-dock.open.quick-used .lt-ask-quickbar { display: none; } }

.lt-ask-bot p a { color: var(--sage, #3D6B66); font-weight: 600; text-underline-offset: 3px; }
.lt-ask-related { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 8px; padding-top: 8px; border-top: 1px solid #E3ECEA; }
.lt-ask-related span { font: 700 10.5px var(--ui, sans-serif); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft, #4A5A66); margin-right: 2px; }
.lt-ask-related a { font: 500 12.5px/1.3 var(--ui, sans-serif); padding: 5px 10px; border-radius: 999px; background: #F6F3EC; border: 1px solid #D5E1DE; color: var(--ink, #1E3A4C); text-decoration: none; }
.lt-ask-related a:hover { border-color: var(--sage, #3D6B66); }
.lt-ask-dots { display: inline-flex; gap: 4px; padding: 4px 0; }
.lt-ask-dots i { width: 7px; height: 7px; border-radius: 50%; background: #9BB5B0; animation: ltdot 1s infinite ease-in-out; }
.lt-ask-dots i:nth-child(2) { animation-delay: .15s; } .lt-ask-dots i:nth-child(3) { animation-delay: .3s; }
@keyframes ltdot { 0%, 80%, 100% { opacity: .3; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }

.lt-ask-beta { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px; font: 700 10px/1.6 var(--ui, sans-serif); letter-spacing: .06em; text-transform: uppercase; font-style: normal; background: #E9C27A; color: #1E3A4C; vertical-align: 2px; }
.lt-ask-consent label { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; line-height: 1.45; color: var(--ink, #1E3A4C); margin: 6px 0; }
.lt-ask-consent input { margin-top: 3px; flex: none; width: 16px; height: 16px; }
.lt-ask-consent .lt-ask-next:disabled { opacity: .45; cursor: default; }

/* Phones, open: one window, not two. The conversation and the text box share a single frame (Jeremy, 2026-11-23). */
@media (max-width: 600px) {
  .lt-dock.open { gap: 0; filter: drop-shadow(0 16px 40px rgb(30 58 76 / .28)); }
  .lt-dock.open .lt-ask-chat { border-radius: 18px 18px 0 0; border-bottom: 0; box-shadow: none; }
  .lt-dock.open .lt-ask-bar { border: 1.5px solid #2F5A62; border-top: 1px solid #D5E1DE; border-radius: 0 0 18px 18px; box-shadow: none; padding: 8px 10px 6px; }
}
/* Desktop: the same, with a hairline between the conversation and the text box instead of a seam */
@media (min-width: 601px) {
  .lt-dock .lt-ask-bar { border-top: 1px solid #D5E1DE; }
}

/* Quick questions: room between the choices and the Next button */
.lt-ask-msg .lt-ask-chips + p { margin: 12px 0 0; }
.lt-ask-msg .lt-ask-chips + p .lt-ask-next { display: inline-block; }

/* Header: Save and End chat (shown once the parent has sent a message) */
.lt-ask-hacts { display: flex; align-items: center; gap: 6px; }
.lt-ask-save, .lt-ask-end { font: 600 12.5px var(--ui, sans-serif); color: #F6F3EC; background: rgb(246 243 236 / .14); border: 1px solid rgb(246 243 236 / .35); border-radius: 999px; padding: 4px 10px; cursor: pointer; }
.lt-ask-save:hover, .lt-ask-end:hover { background: rgb(246 243 236 / .26); }
.lt-ask-save[hidden], .lt-ask-end[hidden] { display: none; }
/* End-of-chat card: copy by email or download */
.lt-ask-end-card .lt-ask-chips { margin-top: 8px; }
.lt-ask-mail { display: flex; gap: 8px; margin-top: 10px; }
.lt-ask-mail[hidden] { display: none; }
.lt-ask-mail input { flex: 1; min-width: 0; font: 16px var(--ui, sans-serif); padding: 7px 10px; border: 1px solid var(--line, #DDD6C8); border-radius: 10px; background: #fff; color: var(--ink, #1E3A4C); }
.lt-ask-mail-note { font-size: 12px !important; color: var(--ink-soft, #4A5A66); margin-top: 6px !important; }
.lt-ask-mail-note[hidden] { display: none; }

/* 2026-11-25: the conversation scrolls inside its frame (it used to grow past it and get clipped, so it felt stuck),
   and scrolling it doesn't drag the page behind it. */
.lt-ask-log { flex: 1 1 auto; min-height: 0; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
/* Once the chat is open, close it from the header (⌄), not from an × beside the text box. */
.lt-dock.open .lt-ask-x { display: none; }
.lt-dock.open .lt-ask-form { padding-right: 0; }

/* Suggested resources (2026-11-26, modeled on RVK's web chat): guides the chat brings up collect in a toggled panel
   under the conversation, so replies stay conversational and the saved copy carries the reading list. */
.lt-ask-chat { position: relative; }
.lt-ask-resbar { flex: none; display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; padding: 9px 12px; border: 0; border-top: 1px solid #C9DAD6; background: linear-gradient(135deg, #2B5160 0%, #3D6B66 100%); color: #F6F3EC; font: 600 14px var(--ui, sans-serif); cursor: pointer; }
.lt-ask-resbar[hidden] { display: none; }
.lt-ask-resbar svg, .lt-ask-res-i svg, .lt-ask-rescard-i svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.lt-ask-rescount { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: #F6F3EC; color: #1E3A4C; font: 700 12px var(--ui, sans-serif); }
.lt-ask-resbar.pulse .lt-ask-rescount { animation: ltpulse .9s ease-out 2; }
@keyframes ltpulse { 0% { box-shadow: 0 0 0 0 rgb(233 194 122 / .9); } 100% { box-shadow: 0 0 0 10px rgb(233 194 122 / 0); } }
.lt-ask-res { position: absolute; left: 0; right: 0; bottom: 0; max-height: 78%; display: flex; flex-direction: column; background: #fff; border-radius: 18px 18px 0 0; box-shadow: 0 -12px 34px rgb(30 58 76 / .22); z-index: 2; animation: ltup .2s ease-out; }
.lt-ask-res[hidden] { display: none; }
@keyframes ltup { from { transform: translateY(24px); opacity: 0; } to { transform: none; opacity: 1; } }
.lt-ask-res-head { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-bottom: 1px solid #E3ECEA; }
.lt-ask-res-i { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: #E9F0EE; color: var(--sage, #3D6B66); }
.lt-ask-res-ttl { flex: 1; display: flex; flex-direction: column; }
.lt-ask-res-ttl strong { font: 500 17px/1.2 var(--display, Georgia, serif); color: var(--ink, #1E3A4C); }
.lt-ask-res-ttl small { font: 12.5px var(--ui, sans-serif); color: var(--ink-soft, #4A5A66); }
.lt-ask-res-x { flex: none; width: 34px; height: 34px; border-radius: 10px; border: 1px solid #D5E1DE; background: #fff; color: var(--ink-soft, #4A5A66); font-size: 20px; line-height: 1; cursor: pointer; }
.lt-ask-res-list { overflow-y: auto; overscroll-behavior: contain; padding: 10px 12px 4px; display: flex; flex-direction: column; gap: 8px; }
.lt-ask-rescard { display: flex; gap: 12px; align-items: flex-start; padding: 11px 12px; border: 1px solid #D5E1DE; border-radius: 12px; background: #fff; color: var(--ink, #1E3A4C); text-decoration: none; }
.lt-ask-rescard:hover { border-color: var(--sage, #3D6B66); }
.lt-ask-rescard-i { flex: none; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: #E9F0EE; color: var(--sage, #3D6B66); }
.lt-ask-rescard-k { display: block; font: 700 10.5px var(--ui, sans-serif); letter-spacing: .07em; text-transform: uppercase; color: var(--sage, #3D6B66); margin-bottom: 2px; }
.lt-ask-rescard-k em { font-style: normal; margin-left: 4px; padding: 1px 6px; border-radius: 999px; background: #E9C27A; color: #1E3A4C; letter-spacing: .04em; }
.lt-ask-rescard-t { display: block; font: 600 14px/1.3 var(--ui, sans-serif); }
.lt-ask-rescard:hover .lt-ask-rescard-t { color: var(--sage, #3D6B66); }
.lt-ask-rescard-d { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 3px; font: 12.5px/1.45 var(--ui, sans-serif); color: var(--ink-soft, #4A5A66); }
.lt-ask-rescard.crisis { border-color: #E2B8AE; background: #FDF6F3; }
.lt-ask-rescard.crisis .lt-ask-rescard-i { background: #F8E3DD; color: #8a2a1a; }
.lt-ask-rescard.crisis .lt-ask-rescard-k { color: #8a2a1a; }
.lt-ask-res-foot { margin: 0; padding: 8px 14px 12px; font-size: 12px; color: var(--ink-soft, #4A5A66); }
.lt-ask-resnote { margin-top: 8px !important; }
.lt-ask-resnote button { background: none; border: 0; padding: 0; font: 600 12.5px var(--ui, sans-serif); color: var(--sage, #3D6B66); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }

/* Dark mode (2026-11-26): the chat keeps its own light palette. The site's dark theme turns --ink light, and the chat's
   fixed white and sage backgrounds then left the text nearly invisible on phones in dark mode. */
.lt-dock, .lt-ask-fab { --ink: #1E3A4C; --ink-soft: #4A5A66; --bg: #F6F3EC; --surface: #fff; --line: #DDD6C8; --sage: #3D6B66; color-scheme: light; }
.lt-dock { color: #1E3A4C; }
.lt-ask-bot, .lt-ask-res, .lt-ask-rescard, .lt-ask-mail input, .lt-ask-form textarea { color: #1E3A4C; }

/* "i" in the header: what Ask Lighthouse is and where its knowledge comes from (2026-11-26) */
.lt-ask-info { display: inline-grid; place-items: center; width: 20px; height: 20px; margin-left: 6px; padding: 0; border-radius: 50%; border: 1.5px solid rgb(246 243 236 / .7); background: none; color: #F6F3EC; font: italic 700 12px/1 Georgia, serif; cursor: pointer; vertical-align: 2px; }
.lt-ask-info:hover, .lt-ask-info[aria-expanded="true"] { background: #F6F3EC; color: #1E3A4C; }
.lt-ask-about { position: absolute; top: 46px; left: 10px; right: 10px; z-index: 3; padding: 14px 16px; background: #fff; color: #1E3A4C; border: 1px solid #C9DAD6; border-radius: 14px; box-shadow: 0 14px 34px rgb(30 58 76 / .25); font: 13.5px/1.5 var(--ui, sans-serif); animation: ltup .15s ease-out; }
.lt-ask-about[hidden] { display: none; }
.lt-ask-about strong { display: block; font: 500 16px var(--display, Georgia, serif); margin-bottom: 6px; }
.lt-ask-about p { margin: 0 0 8px; }
.lt-ask-about a { color: #3D6B66; font-weight: 600; }
.lt-ask-about-more { display: inline-block; margin-top: 2px; }
