/*
  Site top nav (SITE-1450): marketing/templates/top_nav_dark.html, loaded by
  marketing/layout.php and the Learning Center layout after tokens.css.
  Two rows from the 10/20 homepage prototype: logo, AI chat pill and account
  on top (60px), nav links and their dropdowns underneath (44px). Sticky, on
  a see-through scrim. At 768px and below the links row and pill give way to
  a menu button (the same links) and a round "ask" button that opens the
  chat full screen. Total height is
  --ti-nav-h (tokens.css); heroes that slide up under the nav use it too.

  The chat panel is chat.html's markup (#main-chatbot-div), styled here in
  full: MainSite/css/chat.css is not loaded, because its global .hidden and
  .show rules and !important fonts would reach the rest of the page.
*/

.ti-topnav {
  position: sticky;
  top: 0;
  z-index: 1020;
  font-family: var(--ti-font);
  color: var(--ti-text);
  box-shadow: 0 1px 0 var(--ti-overlay-1); /* a border would add 1px to --ti-nav-h */
  --font-base: var(--ti-font); /* brand-tokens.css (Learning Center) sets links to var(--font-base) !important */
}
/* styles.css sets Poppins on * and on links, so set Inter on every element
   here (icon fonts excluded). The Learning Center's own font rule skips the nav. */
.ti-topnav :where(:not(i, .fa, .fas, .far, .fab, .bi, code, pre)) { font-family: var(--ti-font); }
/* The blur sits on a pseudo-element: backdrop-filter on the header itself
   would make it the containing block for the fixed chat panel. Solid by
   default; see-through on the dark (.ti-theme) pages, where the hero slides
   up under it. Over a light page the scrim reads as grey. */
.ti-topnav::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--ti-bg);
  -webkit-backdrop-filter: blur(18px) saturate(1.2);
  backdrop-filter: blur(18px) saturate(1.2);
}
body:has(.ti-theme) .ti-topnav::before { background: var(--ti-scrim); }
/* styles.css pins .modal-backdrop at z-index 1; drop under it while a modal is open */
body.modal-open .ti-topnav { z-index: 0; }

.ti-topnav__in {
  max-width: var(--ti-max);
  margin: 0 auto;
  padding: 0 var(--ti-gutter);
}

.ti-topnav__row {
  display: flex;
  align-items: center;
  min-width: 0;
}
.ti-topnav__row--top { height: 60px; gap: 16px; }
.ti-topnav__row--links { height: 44px; }

.ti-topnav__logo { display: block; flex-shrink: 0; line-height: 0; }
.ti-topnav__logo img { display: block; width: auto; height: 44px; }

/* Links row */
.ti-topnav__links {
  display: flex;
  gap: 4px;
  margin: 0 0 0 -10px;
  padding: 0;
  list-style: none;
}
.ti-topnav__links > li { position: relative; }
.ti-topnav__links > li > a,
.ti-topnav__links > li > button {
  display: inline-flex;
  align-items: center;
  height: 44px;
  padding: 0 10px;
  font-size: var(--ti-fs-md);
  font-weight: var(--ti-fw-medium);
  color: var(--ti-muted);
  text-decoration: none;
  white-space: nowrap;
  border: 0;
  background: none;
  cursor: pointer;
  transition: color var(--ti-dur-fast);
}
.ti-topnav__links > li > a:hover,
.ti-topnav__links > li > button:hover,
.ti-topnav__links > li.has-sub:hover > a,
.ti-topnav__links > li.has-sub:hover > button { color: var(--ti-text); }
.ti-topnav__links > li > .is-current {
  color: var(--ti-text);
  box-shadow: inset 0 -2px 0 var(--ti-orange);
}

/* Dropdowns: open on hover, keyboard focus or a click on the button
   (touch). top-nav.js holds them shut on a fresh page load until the mouse
   moves, and closes one after a link in it is clicked (.is-closed). */
.ti-topnav__sub {
  position: absolute;
  top: calc(100% + 4px);
  left: 50%;
  z-index: 30;
  display: none;
  min-width: 250px;
  padding: 8px;
  transform: translateX(-50%);
  border: 1px solid var(--ti-overlay-2);
  border-radius: var(--ti-radius-md);
  background: var(--ti-bg-sunken); /* solid: page text showed through the 96% glass */
  box-shadow: var(--ti-shadow-md);
}
.ti-topnav__sub::before { content: ""; position: absolute; left: 0; right: 0; top: -8px; height: 8px; } /* hover bridge */
.ti-topnav__links .has-sub:hover > .ti-topnav__sub,
.ti-topnav__links .has-sub:focus-within > .ti-topnav__sub,
.ti-topnav__links .has-sub.is-open > .ti-topnav__sub { display: block; }
.ti-topnav__links .has-sub:hover > .ti-topnav__sub--mega,
.ti-topnav__links .has-sub:focus-within > .ti-topnav__sub--mega,
.ti-topnav__links .has-sub.is-open > .ti-topnav__sub--mega { display: grid; }
html.ti-nav-hold .ti-topnav__links .has-sub:not(.is-open) > .ti-topnav__sub,
.ti-topnav__links .has-sub.is-closed > .ti-topnav__sub { display: none !important; }

.ti-topnav__sub--mega {
  left: 0;
  grid-template-columns: 1fr 1fr;
  gap: 0 10px;
  min-width: 560px;
  transform: none;
}
.ti-topnav__sub a {
  display: block;
  padding: 6px 11px;
  border-radius: 8px;
  font-size: var(--ti-fs-sm);
  line-height: var(--ti-lh-snug);
  color: var(--ti-text-subtle);
  text-decoration: none;
}
.ti-topnav__sub a:hover { background: var(--ti-orange-dim); color: var(--ti-text); }
.ti-topnav__sub a.is-current { color: var(--ti-orange); }
.ti-topnav__sub small,
.ti-topnav__panel small {
  display: block;
  margin-top: 2px;
  font-size: var(--ti-fs-2xs);
  font-weight: var(--ti-fw-medium);
  color: var(--ti-muted-mid);
}
.ti-topnav__sub--mega .is-all {
  grid-column: 1 / -1;
  margin: 0 0 4px;
  padding: 9px 11px;
  border-bottom: 1px solid var(--ti-overlay-2);
  border-radius: 8px 8px 0 0;
  font-weight: var(--ti-fw-black);
  color: var(--ti-orange);
}
.ti-topnav__sub .is-child { margin-left: 14px; padding-left: 16px; border-left: 2px solid var(--ti-orange-line); border-radius: 0 8px 8px 0; }
.ti-topnav__sub .is-list {
  margin: 0 0 4px;
  padding: 8px 11px;
  border: 1px solid var(--ti-orange-line);
  border-radius: var(--ti-radius-sm);
  background: var(--ti-orange-wash);
  font-weight: var(--ti-fw-black);
  color: var(--ti-orange);
  white-space: nowrap;
}
.ti-topnav__head {
  margin: 6px 0 2px;
  padding: 6px 11px 4px;
  font-size: var(--ti-fs-2xs);
  font-weight: var(--ti-fw-black);
  letter-spacing: var(--ti-track-caps);
  text-transform: uppercase;
  color: var(--ti-orange);
}
.ti-topnav__sep { height: 1px; margin: 8px 11px; background: var(--ti-overlay-2); }

/* Right side: ask button (phones), account, Get Started, menu (phones) */
.ti-topnav__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.ti-topnav__user { display: flex; align-items: center; gap: 8px; }
.ti-topnav__user a { text-decoration: none; }
/* No first name beside the avatar (ProfileView.html prints it with Bootstrap's !important display classes) */
.ti-topnav .display-name-profile { display: none !important; }

/* Account icons as round buttons: a bell for notifications and the avatar
   with a small chevron badge. Notifications.html and ProfileView.html are
   shared with other pages, so this is all CSS. notifications.js finds the
   envelope <i> by its fa-envelope class to drop the unread dot inside it,
   so only its glyph changes (to the solid bell). */
.ti-topnav .dropdown-view-profile,
.ti-topnav .dropdown-notifications {
  position: relative;
  display: flex;
  align-items: center;
  width: auto;
  height: 40px;
  margin: 0;
}
.ti-topnav .navbar-brand-envelope,
.ti-topnav .navbar-brand-user {
  position: relative;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
}
.ti-topnav .navbar-brand-envelope {
  background-color: var(--ti-overlay-2) !important; /* core/css/main.css: .dropdown-toggle { background-color: transparent !important } */
  color: var(--ti-text);
  transition: background-color var(--ti-dur-fast);
}
.ti-topnav .navbar-brand-envelope:hover { background-color: var(--ti-overlay-3) !important; color: var(--ti-text); }
.ti-topnav .navbar-brand-envelope::after { display: none; } /* Bootstrap's dropdown caret */
.ti-topnav .navbar-brand-envelope > i {
  position: static;
  margin: 0;
  font-size: var(--ti-fs-2xl);
  text-shadow: none;
}
.ti-topnav .navbar-brand-envelope > i::before {
  content: "\f0f3"; /* bell */
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
}
.ti-topnav .navbar-brand-envelope i.fa-circle { /* unread dot */
  top: 7px;
  right: 7px;
  left: auto;
  font-size: var(--ti-fs-2xs);
  color: var(--ti-red);
}

.ti-topnav .navbar-brand-user > i { /* signed out: no photo */
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  margin: 0;
  padding: 0;
  border-radius: 50%;
  background: var(--ti-overlay-2);
  color: var(--ti-text-soft);
  font-size: var(--ti-fs-2xl);
}
.ti-topnav .navbar-brand-user img#user-image-top-bar {
  width: 40px;
  height: 40px;
  object-fit: cover;
  box-shadow: none;
}
.ti-topnav .navbar-brand-user::after { /* replaces Bootstrap's caret with a chevron badge */
  content: "\f078";
  position: absolute;
  right: -3px;
  bottom: -3px;
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  margin: 0;
  border: 2px solid var(--ti-bg);
  border-radius: 50%;
  background: var(--ti-card-elev);
  color: var(--ti-text);
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: var(--ti-fs-2xs);
  line-height: 1;
  vertical-align: 0;
}

.ti-topnav .dropdown-view-profile .dropdown-menu,
.ti-topnav .dropdown-notifications .dropdown-menu {
  top: 100% !important;
  left: auto !important;
  right: 0;
  margin-top: 6px;
  padding: 6px;
  background: var(--ti-card-elev);
  border: 1px solid var(--ti-border);
  border-radius: var(--ti-radius-sm);
  box-shadow: var(--ti-shadow-md);
}
.ti-topnav .dropdown-view-profile .dropdown-menu { min-width: 170px; }
/* Hover bridge across the 6px gap to the menu. It sits on the wrapper, not
   the menu: the notifications list scrolls (overflow-y in core/css/main.css),
   which would clip a bridge sticking out of its top. */
.ti-topnav .dropdown-view-profile::after,
.ti-topnav .dropdown-notifications::after { content: ""; position: absolute; left: 0; right: 0; top: 100%; height: 8px; }
.ti-topnav .dropdown-view-profile .dropdown-menu > li > a {
  display: block;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: var(--ti-fs-md);
  color: var(--ti-text-soft);
}
.ti-topnav .dropdown-view-profile .dropdown-menu > li > a:hover { background: var(--ti-overlay-2); color: var(--ti-text); }
.ti-topnav .dropdown-notifications .alert-list { color: var(--ti-text-soft) !important; }
.ti-topnav .dropdown-notifications .alert-list li { padding: 8px 10px; border-bottom: 1px solid var(--ti-border); border-radius: 8px; }
.ti-topnav .dropdown-notifications .alert-list li:last-child { border-bottom: 0; }
.ti-topnav .dropdown-notifications .alert-list li.alert-list-row:hover { background: var(--ti-overlay-2); color: var(--ti-text); }
.ti-topnav .dropdown-notifications .alert-list p { color: inherit; }

.ti-topnav__cta {
  display: inline-flex;
  align-items: center;
  height: 40px;
  padding: 0 18px;
  border-radius: var(--ti-radius-sm);
  background: var(--ti-orange);
  color: var(--ti-on-accent);
  font-size: var(--ti-fs-md);
  font-weight: var(--ti-fw-bold);
  text-decoration: none;
  white-space: nowrap;
  transition: background var(--ti-dur-fast), box-shadow var(--ti-dur-fast);
}
.ti-topnav__cta:hover { background: var(--ti-orange-hot); color: var(--ti-on-accent); box-shadow: var(--ti-shadow-orange); }

.ti-topnav__ask,
.ti-topnav__burger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid var(--ti-border);
  border-radius: var(--ti-radius-sm);
  background: transparent;
  cursor: pointer;
}
.ti-topnav__ask { display: none; border-radius: var(--ti-radius-pill); }
.ti-topnav__burger[aria-expanded="true"] { border-color: var(--ti-orange-line); }
.ti-topnav__burger span,
.ti-topnav__burger span::before,
.ti-topnav__burger span::after {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--ti-text);
}
.ti-topnav__burger span { position: relative; }
.ti-topnav__burger span::before,
.ti-topnav__burger span::after { content: ""; position: absolute; left: 0; }
.ti-topnav__burger span::before { top: -6px; }
.ti-topnav__burger span::after { top: 6px; }

.ti-topnav__menu { position: relative; display: none; } /* phones only, see the 768px block */
.ti-topnav__panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 280px;
  max-height: calc(100vh - var(--ti-nav-h) - 24px);
  overflow-y: auto;
  padding: 8px;
  border: 1px solid var(--ti-overlay-3);
  border-radius: var(--ti-radius);
  background: var(--ti-bg-sunken); /* solid: page text showed through the 96% glass */
  box-shadow: var(--ti-shadow-lg);
}
.ti-topnav__panel[hidden] { display: none; }
.ti-topnav__panel a {
  display: block;
  padding: 11px 12px;
  border-radius: var(--ti-radius-sm);
  font-size: var(--ti-fs-md);
  font-weight: var(--ti-fw-semibold);
  color: var(--ti-text-soft);
  text-decoration: none;
}
.ti-topnav__panel a:hover { background: var(--ti-orange-dim); color: var(--ti-text); }
.ti-topnav__panel a.is-current { color: var(--ti-orange); }
.ti-topnav__panel .ti-topnav__panel-cta { display: none; margin-bottom: 6px; background: var(--ti-orange); color: var(--ti-on-accent); text-align: center; }
.ti-topnav__panel .ti-topnav__panel-cta:hover { background: var(--ti-orange-hot); color: var(--ti-on-accent); }
.ti-topnav__panel summary {
  padding: 11px 12px;
  border-radius: var(--ti-radius-sm);
  font-size: var(--ti-fs-md);
  font-weight: var(--ti-fw-bold);
  color: var(--ti-text-soft);
  list-style: none;
  cursor: pointer;
}
.ti-topnav__panel summary::-webkit-details-marker { display: none; }
.ti-topnav__panel summary::after { content: " \25BE"; color: var(--ti-orange); }
.ti-topnav__panel details[open] summary::after { content: " \25B4"; }
.ti-topnav__panel details a {
  display: block;
  padding: 7px 12px;
  font-size: var(--ti-fs-sm);
  font-weight: var(--ti-fw-medium);
}
.ti-topnav__panel details .is-child { padding-left: 24px; }
.ti-topnav__panel .ti-topnav__head { margin: 4px 0 0; }
.ti-topnav__panel .ti-topnav__sep { margin: 6px 4px; }
.ti-topnav__panel :focus-visible,
.ti-topnav__sub :focus-visible { outline: 2px solid var(--ti-orange); outline-offset: 1px; }

/* ==========================================================================
   AI chat pill
   ========================================================================== */

.ti-chat {
  position: relative;
  flex: 1 1 auto;
  min-width: 200px;
  max-width: 340px;
  margin-left: auto;
}
.ti-chat__pill {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 40px;
  margin: 0;
  padding: 0 6px 0 14px;
  border: 1px solid var(--ti-border);
  border-radius: var(--ti-radius-pill);
  background: var(--ti-card);
  cursor: text;
  transition: border-color var(--ti-dur-fast);
}
.ti-chat__pill:focus-within { border-color: var(--ti-orange-line); }
.ti-chat__orb {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: conic-gradient(from 210deg, var(--ti-orange), var(--ti-amber), var(--ti-teal), var(--ti-orange));
}
.ti-chat__pill input {
  flex: 1;
  min-width: 0;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ti-text);
  font: inherit;
  font-size: var(--ti-fs-sm);
  font-weight: var(--ti-fw-medium);
}
.ti-chat__pill input::placeholder { color: var(--ti-muted-mid); }
.ti-chat__go {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--ti-border);
  color: var(--ti-muted);
  cursor: pointer;
  transition: background var(--ti-dur-fast), color var(--ti-dur-fast);
}
.ti-chat__go svg { width: 12px; height: 12px; }
.ti-chat__go:hover,
.ti-chat__pill:focus-within .ti-chat__go { background: var(--ti-orange); color: var(--ti-on-accent); }

/* ==========================================================================
   AI chat panel (chat.html's markup, added on first use)
   ========================================================================== */

.ti-chat .hidden { display: none !important; }
.ti-chat #main-chat { position: static; }

.ti-chat #main-chatbot-div {
  position: fixed;
  z-index: 10; /* above the account icons, which come later in the nav */
  top: calc(var(--ti-nav-h) + 8px);
  right: max(var(--ti-gutter), calc((100vw - var(--ti-max)) / 2 + var(--ti-gutter)));
  display: flex;
  flex-direction: column;
  width: min(440px, calc(100vw - 32px));
  height: min(620px, calc(100vh - var(--ti-nav-h) - 24px));
  max-height: none !important; /* chat.js sets an inline max-height for its old hero spot */
  overflow: hidden;
  border: 1px solid var(--ti-border);
  border-radius: var(--ti-radius);
  background: var(--ti-card);
  box-shadow: var(--ti-shadow);
  color: var(--ti-text);
  font-size: var(--ti-fs-md);
  line-height: var(--ti-lh-body);
}

.ti-chat__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px 10px 16px;
  border-bottom: 1px solid var(--ti-border);
}
.ti-chat__title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: var(--ti-fs-md);
  font-weight: var(--ti-fw-semibold);
  color: var(--ti-text);
}
.ti-chat .btn-close-main-chat {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border: 1px solid var(--ti-border);
  border-radius: var(--ti-radius-pill);
  background: transparent;
  color: var(--ti-muted);
  font-size: var(--ti-fs-xs);
  cursor: pointer;
}
.ti-chat .btn-close-main-chat:hover { color: var(--ti-text); border-color: var(--ti-border-strong); }
.ti-chat .btn-close-main-chat svg { width: 12px; height: 12px; }
.ti-chat .btn-close-main-chat svg g { fill: currentColor; }

/* Pieces of the full-page chat this panel doesn't use: history sidebar,
   theme switch, the new-chat screen and its expand/collapse control. */
.ti-chat #main-sidebar,
.ti-chat #user-new-chat-div,
.ti-chat #btn-close-collapse { display: none !important; }

.ti-chat #inner-mian-chatbot-div {
  position: relative;
  display: flex;
  flex: 1;
  min-height: 0;
}
.ti-chat #main-content-div {
  position: relative;
  display: flex !important;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}
.ti-chat #main-content {
  flex: 1;
  overflow-y: auto;
  padding: 12px 16px;
}
.ti-chat #main-content .init-text { margin: 4px 0; color: var(--ti-muted); }

.ti-chat .message-container { display: flex; justify-content: flex-end; }
.ti-chat .user-message,
.ti-chat .bot-message {
  margin: 6px 0;
  padding: 9px 13px;
  overflow-wrap: anywhere;
}
.ti-chat .user-message {
  max-width: 85%;
  border: 1px solid var(--ti-orange-line);
  border-radius: 14px 14px 4px 14px;
  background: var(--ti-orange-dim);
  color: var(--ti-text);
}
.ti-chat .bot-message {
  max-width: 94%;
  border: 1px solid var(--ti-border);
  border-radius: 14px 14px 14px 4px;
  background: var(--ti-card-elev);
  color: var(--ti-text-soft);
}
.ti-chat .bot-message:empty { display: none; }
.ti-chat .bot-message p { margin: 0 0 0.6em; color: inherit; } /* styles.css sets p to #333 */
.ti-chat .bot-message > :last-child { margin-bottom: 0; }
.ti-chat .bot-message :is(h1, h2, h3, h4) {
  margin: 0.4em 0;
  font-size: var(--ti-fs-lg);
  font-weight: var(--ti-fw-semibold);
  line-height: var(--ti-lh-snug);
  color: var(--ti-text);
}
.ti-chat .bot-message ul,
.ti-chat .bot-message ol { margin: 0 0 0.6em; padding-left: 1.2em; }
.ti-chat .bot-message a { color: var(--ti-orange); font-weight: var(--ti-fw-medium); }
.ti-chat .bot-message img { display: block; max-width: 100%; height: auto; margin: 4px 0; }
.ti-chat .bot-message pre {
  margin: 0 0 0.6em;
  padding: 10px;
  overflow-x: auto;
  border: 1px solid var(--ti-border);
  border-radius: 8px;
  background: var(--ti-bg-deep);
  font-size: var(--ti-fs-xs);
}
.ti-chat .bot-message code { color: var(--ti-text-soft); white-space: pre-wrap; }
.ti-chat .pre-wrapper { position: relative; margin: 8px 0; }
.ti-chat .copy-button {
  position: absolute;
  top: 6px;
  right: 6px;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: var(--ti-overlay-2);
  color: var(--ti-muted);
  cursor: pointer;
}
.ti-chat .copy-button svg path { fill: currentColor; }

.ti-chat #loading_gif { position: absolute; left: 16px; bottom: 64px; }
.ti-chat #loading_gif .loading { width: 28px; height: 28px; }

.ti-chat .scroll-to-bottom {
  position: absolute;
  left: 50%;
  bottom: 68px;
  display: none;
  width: 32px;
  height: 32px;
  padding: 0;
  transform: translateX(-50%);
  border: 1px solid var(--ti-border);
  border-radius: 50%;
  background: var(--ti-card-elev);
  color: var(--ti-text);
  cursor: pointer;
}
.ti-chat .scroll-to-bottom.active { display: grid; place-items: center; }
.ti-chat .scroll-to-bottom svg { width: 18px; height: 18px; }
.ti-chat .scroll-to-bottom svg path { fill: currentColor; }

/* Follow-up box at the foot of the panel */
.ti-chat #mini-exp-seend-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-top: 1px solid var(--ti-border);
  background: var(--ti-bg-sunken);
}
.ti-chat #mini-exp-seend-btn > svg { display: none; }
.ti-chat .main-chat-input {
  flex: 1;
  min-width: 0;
  height: 38px;
  padding: 0 14px;
  border: 1px solid var(--ti-border);
  border-radius: var(--ti-radius-pill);
  outline: 0;
  background: var(--ti-card);
  color: var(--ti-text);
  font: inherit;
  font-size: var(--ti-fs-sm);
}
.ti-chat .main-chat-input:focus { border-color: var(--ti-orange-line); }
.ti-chat .main-chat-input::placeholder { color: var(--ti-muted-mid); }
.ti-chat .main-send-btn {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}
.ti-chat .main-send-btn svg { width: 34px; height: 34px; }
.ti-chat .main-send-btn svg path { fill: var(--ti-orange); }

/* ==========================================================================
   Breakpoints
   ========================================================================== */

/* The weekly-signals box (aside.tow-form, marketing/templates/tow_signup_form.html)
   sits above the nav at z-index 1499 and covers the panel's send button;
   hide it while the chat is open rather than lift the nav over Bootstrap's modals. */
html.ti-chat-open .tow-form { display: none; }

@media (max-width: 900px) {
  .ti-chat { max-width: 240px; }
}

@media (max-width: 768px) {
  .ti-topnav__row--top { height: 56px; gap: 10px; }
  .ti-topnav__row--links,
  .ti-chat__pill { display: none; }
  .ti-topnav__logo img { height: 38px; }
  .ti-topnav__ask { display: inline-flex; }
  .ti-topnav__menu { display: block; }
  .ti-topnav__actions { gap: 8px; margin-left: auto; }
  .ti-topnav__cta { height: 40px; padding: 0 14px; font-size: var(--ti-fs-sm); }

  /* The pill is hidden, so .ti-chat only hosts the full-screen panel */
  .ti-chat { position: static; flex: 0 0 auto; min-width: 0; max-width: none; margin: 0; }
  .ti-chat #main-chatbot-div {
    inset: 0;
    width: auto;
    height: 100dvh;
    border: 0;
    border-radius: 0;
  }
  .ti-chat .main-chat-input { font-size: var(--ti-fs-lg); } /* 16px: no zoom on iOS */
  html.ti-chat-open,
  html.ti-chat-open body { overflow: hidden; }
}

/* Narrow phones: logo, ask, account, Get Started and menu don't fit across
   320-400px, so Get Started moves to the top of the menu. */
@media (max-width: 560px) {
  .ti-topnav__row--top { gap: 8px; }
  .ti-topnav__actions > .ti-topnav__cta { display: none; }
  .ti-topnav__panel .ti-topnav__panel-cta { display: block; }
}
