.visit-welcome,
.visit-help {
  --visit-navy: #062b50;
  --visit-teal: #007971;
  --visit-gradient: linear-gradient(135deg, #061f3b 2%, #0b3e67 55%, #00675f 100%);
  --visit-accent: linear-gradient(90deg, #158abb, #55ebbc);
}

.visit-welcome {
  position: fixed;
  z-index: 240;
  inset: 0;
  inline-size: min(290px, calc(100% - 32px));
  block-size: fit-content;
  margin: auto;
  overflow: hidden;
  padding: 16px 16px 19px;
  border: 1px solid rgb(0 121 113 / .3);
  border-radius: 18px;
  background: linear-gradient(135deg, rgb(255 255 255 / .68), rgb(229 248 249 / .58));
  -webkit-backdrop-filter: blur(8px) saturate(130%);
  backdrop-filter: blur(8px) saturate(130%);
  color: var(--visit-navy);
  box-shadow: 0 16px 45px rgb(4 40 65 / .2), 0 3px 12px rgb(3 43 85 / .1);
  text-align: center;
  pointer-events: none;
  animation: visit-welcome-appear var(--visit-welcome-time, 2000ms) ease both;
}
.visit-welcome-logo {
  --medtravel-navy: #002f5f;
  --medtravel-teal: var(--medtravel-action);
  display: block;
  inline-size: min(190px, 100%);
  margin: 0 auto 10px;
  padding: 8px 10px;
  border-radius: 10px;
  background: transparent;
}
.visit-welcome-logo svg { display: block; inline-size: 100%; block-size: auto; }
.visit-welcome-logo .medtravel-wordmark-glint { display: none; }
.visit-welcome strong, .visit-welcome small { display: block; overflow-wrap: anywhere; }
.visit-welcome strong {
  font-size: clamp(1.05rem, 4.4vw, 1.25rem);
  font-weight: 820;
  line-height: 1.18;
  letter-spacing: -.025em;
}
.visit-welcome small {
  margin-block-start: 7px;
  color: #385369;
  font-size: .875rem;
  line-height: 1.45;
}
.visit-welcome-progress {
  position: absolute;
  inset: auto 0 0;
  block-size: 4px;
  background: var(--visit-accent);
  transform-origin: left;
  animation: visit-welcome-progress var(--visit-welcome-time, 2000ms) linear both;
}
@keyframes visit-welcome-appear {
  0% { opacity: 0; transform: translateY(8px) scale(.98); }
  7%, 91% { opacity: 1; transform: none; }
  100% { opacity: 0; transform: translateY(-4px); }
}
@keyframes visit-welcome-progress {
  from { transform: scaleX(1); }
  to { transform: scaleX(0); }
}

.visit-help {
  position: fixed;
  inset: 0;
  inline-size: min(365px, calc(100% - 28px));
  block-size: fit-content;
  max-block-size: calc(100dvh - 28px);
  margin: auto;
  padding: 0;
  overflow: auto;
  overscroll-behavior: contain;
  border: 1px solid rgb(84 169 174 / .5);
  border-radius: 21px;
  background: linear-gradient(145deg, rgb(255 255 255 / .88), rgb(231 249 250 / .82));
  -webkit-backdrop-filter: blur(18px) saturate(145%);
  backdrop-filter: blur(18px) saturate(145%);
  color: #0a3254;
  box-shadow: 0 22px 60px rgb(5 36 57 / .24), 0 3px 14px rgb(5 67 77 / .10);
}
.visit-help::backdrop { background: rgb(5 37 55 / .25); }
.visit-help-header {
  position: relative;
  padding: 15px 60px 14px 17px;
  border-block-start: 4px solid #17a9a5;
  background: radial-gradient(ellipse at 100% 0, rgb(57 196 191 / .26), transparent 72%), linear-gradient(115deg, rgb(255 255 255 / .48), rgb(197 235 241 / .35));
  color: #0a3254;
}
.visit-help .visit-help-brand {
  margin: 0 0 5px;
  color: #007c80;
  font-size: .6875rem;
  font-weight: 850;
  letter-spacing: .14em;
  line-height: 1.25;
  text-transform: uppercase;
}
.visit-help h2 {
  margin: 0 0 5px;
  color: #082f54;
  font-size: clamp(1.125rem, 5vw, 1.5rem);
  font-weight: 820;
  letter-spacing: -.024em;
  line-height: 1.2;
  overflow-wrap: anywhere;
}
.visit-help #visit-help-intro {
  margin: 0;
  color: #31566b;
  font-size: .8125rem;
  line-height: 1.42;
}
.visit-help button { font: inherit; cursor: pointer; }
.visit-help-close {
  position: absolute;
  inset-block-start: 8px;
  inset-inline-end: 9px;
  display: grid;
  place-items: center;
  inline-size: 44px;
  block-size: 44px;
  padding: 0;
  border: 1px solid rgb(13 120 128 / .24);
  border-radius: 50%;
  background: rgb(255 255 255 / .52);
  color: #0a5866;
}
.visit-help-close svg { inline-size: 17px; block-size: 17px; }
.visit-help-close:hover { background: rgb(255 255 255 / .82); }
.visit-help-content { padding: 12px 14px 4px; }
.visit-help-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}
.visit-help-actions a {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  gap: 7px;
  min-block-size: 44px;
  padding: 7px 9px;
  border: 1px solid rgb(68 158 162 / .38);
  border-radius: 10px;
  background: rgb(255 255 255 / .66);
  color: #0a3254;
  font-size: .8125rem;
  font-weight: 760;
  line-height: 1.26;
  text-decoration: none;
  overflow-wrap: anywhere;
}
.visit-help-actions a:hover {
  border-color: var(--visit-teal);
  background: var(--mist);
}
.visit-help-actions svg { inline-size: 17px; block-size: 17px; color: var(--teal-dark); }
.visit-help-actions a.visit-help-chat {
  grid-column: 1 / -1;
  grid-template-columns: 18px minmax(0, 1fr) 16px;
  background: linear-gradient(110deg, #006855, #07516a);
  border-color: #006b65;
  color: #fff;
}
.visit-help-actions .visit-help-chat svg { inline-size: 15px; block-size: 15px; color: currentColor; }
.visit-help-actions a.visit-help-chat:hover { background: #075347; }
.visit-help-pulse {
  justify-self: center;
  inline-size: 12px;
  block-size: 12px;
  border: 1px solid #bcffd6;
  border-radius: 50%;
  background: #54ffa0;
  box-shadow: 0 0 0 3px #5bffb04d, 0 0 10px #5bffb099;
  animation: visit-chat-blink 1.45s ease-in-out infinite;
}
@keyframes visit-chat-blink {
  0%, 34%, 100% { opacity: 1; }
  65%, 78% { opacity: .35; }
}
.visit-help button.visit-help-later {
  display: block;
  min-block-size: 44px;
  margin: 0 auto;
  padding: 4px 14px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font-size: .8125rem;
  font-weight: 720;
}
.visit-help button.visit-help-later:hover { color: var(--navy); text-decoration: underline; }
.visit-help :is(a,button):focus-visible { outline: 2px solid var(--teal-dark); outline-offset: 2px; }
.visit-help .visit-help-close:focus-visible { outline-color: #007c80; }
:root[data-theme="dark"] .visit-help {
  background: linear-gradient(145deg, rgb(12 39 54 / .94), rgb(9 48 54 / .91));
  border-color: rgb(116 225 220 / .45);
  color: #edf9fa;
}
:root[data-theme="dark"] .visit-help-header { background: linear-gradient(120deg, rgb(14 57 71 / .8), rgb(10 94 91 / .5)); }
:root[data-theme="dark"] .visit-help :is(h2, #visit-help-intro) { color: #effcff; }
:root[data-theme="dark"] .visit-help .visit-help-brand { color: #8fe6df; }
:root[data-theme="dark"] .visit-help-close { background: rgb(255 255 255 / .1); color: #fff; border-color: rgb(255 255 255 / .25); }
:root[data-theme="dark"] .visit-help-actions a:not(.visit-help-chat) { background: rgb(255 255 255 / .09); color: #effcff; }
:root[data-theme="dark"] .visit-help button.visit-help-later { color: #d3e7eb; }
@media (max-width: 340px) {
  .visit-help-actions { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  .visit-welcome, .visit-welcome-progress, .visit-help-pulse { animation: none; }
}
