/* LECHAIM — Customer help bot (prepared answers, no AI) */

.help-bot-panel .visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.help-bot-fab[hidden],
.help-bot-panel[hidden],
.help-bot-welcome[hidden],
.help-bot-topics[hidden],
.help-bot-answer[hidden] {
  display: none !important;
}

:root {
  --lechaim-fab-floor: 4.8rem;
  --lechaim-help-bot-h: 7.9rem;
  --lechaim-fab-gap: 0.45rem;
  --lechaim-waiter-size: 3.2rem;
}

.help-bot-fab {
  position: fixed;
  z-index: 382;
  left: 0.2rem;
  right: auto;
  bottom: calc(var(--lechaim-fab-floor) + env(safe-area-inset-bottom, 0px));
  display: block;
  width: 7.4rem;
  height: 7.9rem;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #152640;
  font: inherit;
  box-shadow: none;
  cursor: pointer;
  overflow: visible;
}
.help-bot-fab__bot {
  position: absolute;
  left: 0;
  bottom: 0;
  width: auto;
  height: 5.9rem;
  max-width: none;
  object-fit: contain;
  object-position: center bottom;
  filter: drop-shadow(6px 10px 14px rgba(0, 0, 0, 0.38));
  pointer-events: none;
}
.help-bot-fab__label {
  position: absolute;
  left: 2.35rem;
  top: 1.05rem;
  z-index: 1;
  width: max-content;
  max-width: 8.6rem;
  padding: 0.4rem 0.62rem;
  border: 1.5px solid #c4a06a;
  border-radius: 1.05rem 1.05rem 1.05rem 0.28rem;
  background: #152640;
  color: #fff8ee;
  font-weight: 800;
  font-size: 0.78rem;
  line-height: 1.25;
  letter-spacing: 0.01em;
  text-align: start;
  box-shadow: 0 8px 18px rgba(21, 38, 64, 0.3);
}
.help-bot-fab__label::after {
  content: "";
  position: absolute;
  right: auto;
  left: 10px;
  bottom: -6px;
  border: 7px solid transparent;
  border-top-color: #152640;
  border-bottom: 0;
  border-left: 0;
}
.help-bot-fab:hover .help-bot-fab__label,
.help-bot-fab.is-open .help-bot-fab__label {
  background: #1e3a5f;
}

.help-bot-panel {
  position: fixed;
  z-index: 432;
  left: 1rem;
  right: auto;
  bottom: calc(var(--lechaim-fab-floor) + var(--lechaim-help-bot-h) + var(--lechaim-fab-gap) + env(safe-area-inset-bottom, 0px));
  width: min(calc(100vw - 1.5rem), 360px);
}

body.help-bot-open {
  overflow: hidden;
}

body.help-bot-open .help-bot-fab {
  display: none !important;
}

body.help-bot-open .help-bot-panel,
body.entry-pending.help-bot-open .help-bot-panel {
  top: max(0.4rem, env(safe-area-inset-top, 0px)) !important;
  bottom: max(0.45rem, env(safe-area-inset-bottom, 0px)) !important;
  left: 0.55rem !important;
  right: auto !important;
  width: min(calc(100vw - 1.1rem), 380px) !important;
  max-width: none;
  margin-inline: 0 !important;
  z-index: 10072;
}

.help-bot-panel__card {
  display: flex;
  flex-direction: column;
  height: 100%;
  max-height: min(72vh, 560px);
  background: #fff8ee;
  border: 1px solid #e6dfd0;
  border-radius: 16px;
  box-shadow: 0 16px 40px rgba(21, 38, 64, 0.22);
  overflow: hidden;
}

body.help-bot-open .help-bot-panel__card {
  max-height: none;
}

.help-bot-panel__header {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.75rem 0.8rem;
  background: #152640;
  color: #fff8ee;
}

.help-bot-panel__avatar {
  width: 2.7rem;
  height: 2.7rem;
  flex: 0 0 2.7rem;
  border-radius: 50%;
  background: #fff8ee;
  object-fit: contain;
  object-position: center 42%;
  display: block;
  box-shadow: 0 0 0 2px #c4a06a;
}

.help-bot-panel__title {
  flex: 1;
  margin: 0;
  font-size: 1.02rem;
  font-weight: 800;
  line-height: 1.25;
}

.help-bot-panel__close {
  flex: 0 0 auto;
  width: 2.25rem;
  height: 2.25rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #fff8ee;
  font-size: 1.55rem;
  line-height: 1;
  cursor: pointer;
}

.help-bot-panel__close:hover {
  background: rgba(255, 248, 238, 0.12);
}

.help-bot-panel__body {
  flex: 1;
  min-height: 0;
  padding: 0.75rem 0.8rem 0.9rem;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.help-bot-welcome {
  margin: 0 0 0.7rem;
  padding: 0;
  background: transparent;
  border: 0;
}

.help-bot-welcome__title,
.help-bot-welcome__body {
  margin: 0;
  color: #152640;
  line-height: 1.4;
}

.help-bot-welcome__title {
  font-size: 1.02rem;
  font-weight: 800;
}

.help-bot-welcome__body {
  margin-top: 0.28rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: #1e3a5f;
}

.help-bot-topics {
  display: grid;
  gap: 0.38rem;
}

.help-bot-topic {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 2.55rem;
  padding: 0.45rem 0.75rem;
  border: 1px solid #e6dfd0;
  border-radius: 12px;
  background: #fff;
  color: #152640;
  font: inherit;
  font-weight: 700;
  font-size: 0.98rem;
  text-align: start;
  cursor: pointer;
}

.help-bot-topic:hover,
.help-bot-topic:focus-visible {
  border-color: #c4a06a;
  background: #f7f0e4;
}

.help-bot-answer__title {
  margin: 0 0 0.55rem;
  font-size: 1.05rem;
  font-weight: 800;
  color: #152640;
  line-height: 1.35;
}

.help-bot-answer__body {
  margin: 0;
  color: #1e3a5f;
  font-size: 0.95rem;
  font-weight: 500;
  line-height: 1.55;
  white-space: pre-line;
}

.help-bot-answer__image {
  display: block;
  width: 100%;
  height: auto;
  margin: 0.75rem 0 0;
  border-radius: 12px;
  border: 1px solid #e6dfd0;
  background: #fff;
}

.help-bot-answer .around-us__list--embed {
  margin-top: 0.7rem;
}

.help-bot-answer .around-us__place {
  padding: 0.7rem 0.75rem 0.65rem;
  border-radius: 12px;
}

.help-bot-answer .around-us__emoji {
  flex-basis: 2.1rem;
  width: 2.1rem;
  height: 2.1rem;
  font-size: 1.1rem;
}

.help-bot-answer .around-us__name {
  font-size: 0.96rem;
}

.help-bot-answer .around-us__meta {
  font-size: 0.8rem;
}

.help-bot-answer .around-us__maps {
  min-height: 2.1rem;
  font-size: 0.78rem;
}

.help-bot-answer__maps {
  display: inline-flex;
  margin-top: 0.7rem;
  color: #1f6b4a;
  font-weight: 800;
  text-decoration: underline;
}

.help-bot-related {
  margin-top: 0.95rem;
  padding-top: 0.75rem;
  border-top: 1px solid #e6dfd0;
}

.help-bot-related__label {
  margin: 0 0 0.45rem;
  color: #152640;
  font-size: 0.9rem;
  font-weight: 800;
}

.help-bot-related__list {
  display: grid;
  gap: 0.4rem;
}

.help-bot-related__btn {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 2.55rem;
  padding: 0.45rem 0.75rem;
  border: 1px solid #e6dfd0;
  border-radius: 12px;
  background: #fff;
  color: #152640;
  font: inherit;
  font-weight: 700;
  font-size: 0.92rem;
  text-align: start;
  cursor: pointer;
}

.help-bot-related__btn:hover,
.help-bot-related__btn:focus-visible {
  border-color: #c4a06a;
  background: #f7f0e4;
}

.help-bot-answer__action,
.help-bot-back {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 2.75rem;
  margin-top: 0.75rem;
  padding: 0.5rem 0.85rem;
  border: 0;
  border-radius: 12px;
  font: inherit;
  font-weight: 800;
  text-decoration: none;
  box-sizing: border-box;
  cursor: pointer;
}

a.help-bot-answer__action + a.help-bot-answer__action {
  margin-top: 0.45rem;
}

.help-bot-answer__action {
  background: #152640;
  color: #fff8ee;
}

.help-bot-answer__action:hover {
  background: #1e3a5f;
}

.help-bot-back {
  background: transparent;
  color: #152640;
  border: 1px solid #c4a06a;
}

.help-bot-back:hover {
  background: #f7f0e4;
}

body.cart-open .help-bot-fab,
body.cart-open .help-bot-panel,
body.modal-open .help-bot-fab,
body.modal-open .help-bot-panel,
body.order-receipt-open .help-bot-fab,
body.order-receipt-open .help-bot-panel,
body.table-order-open .help-bot-fab,
body.table-order-open .help-bot-panel {
  display: none !important;
}

body.entry-pending .help-bot-fab {
  z-index: 10062;
  bottom: calc(0.85rem + env(safe-area-inset-bottom, 0px));
}

body.entry-pending .help-bot-panel {
  z-index: 10072;
  bottom: calc(8.6rem + env(safe-area-inset-bottom, 0px));
}

body:has(#lechaim-help-bot-fab) .site-footer--compact {
  padding-bottom: calc(8.8rem + env(safe-area-inset-bottom, 0px));
}

body.lang-fab-on:has(#lechaim-help-bot-fab) .site-footer--compact {
  padding-bottom: calc(14.8rem + env(safe-area-inset-bottom, 0px));
}

body.lang-fab-on.waiter-fab-on:has(#lechaim-help-bot-fab) .site-footer--compact {
  padding-bottom: calc(16.6rem + env(safe-area-inset-bottom, 0px));
}

@media (max-width: 640px) {
  :root {
    --lechaim-help-bot-h: 7.5rem;
  }

  .help-bot-fab {
    width: 7.1rem;
    height: 7.5rem;
    left: 0.1rem;
  }

  .help-bot-fab__bot {
    height: 5.5rem;
  }

  .help-bot-fab__label {
    font-size: 0.72rem;
    max-width: 7.8rem;
  }

  body.entry-pending .help-bot-fab {
    bottom: calc(0.7rem + env(safe-area-inset-bottom, 0px));
  }
}

@media (max-width: 768px) {
  body.entry-pending .help-bot-fab {
    bottom: calc(0.65rem + env(safe-area-inset-bottom, 0px));
  }
}

/* When the waiter FAB is visible, keep a compact robot under it */
body.waiter-fab-on {
  --lechaim-help-bot-h: 4.2rem;
}

body.waiter-fab-on .help-bot-fab {
  width: 3.6rem;
  height: 4.2rem;
  left: 0.55rem;
}

body.waiter-fab-on .help-bot-fab__label {
  display: none;
}

body.waiter-fab-on .help-bot-fab__bot {
  height: 4.05rem;
  animation: none;
}

/* Call waiter — round FAB stacked above the help-bot robot */
.waiter-call-fab[hidden],
.waiter-call-panel[hidden] {
  display: none !important;
}

.waiter-call-fab {
  position: fixed;
  z-index: 382;
  left: 1rem;
  right: auto;
  bottom: calc(var(--lechaim-fab-floor) + var(--lechaim-help-bot-h) + var(--lechaim-fab-gap) + env(safe-area-inset-bottom, 0px));
  width: 3.2rem;
  height: 3.2rem;
  padding: 0;
  border: 2px solid #c4a06a;
  border-radius: 50%;
  background: #8a2f2f;
  color: #fff8ee;
  font: inherit;
  box-shadow: 0 0 0 3px rgba(196, 160, 106, 0.22), 0 10px 28px rgba(21, 38, 64, 0.32);
  cursor: pointer;
}

.waiter-call-fab__icon {
  font-size: 1.35rem;
  line-height: 1;
}

.waiter-call-fab:hover,
.waiter-call-fab.is-open {
  background: #6f2424;
}

.waiter-call-panel {
  position: fixed;
  z-index: 433;
  left: 1rem;
  right: auto;
  bottom: calc(var(--lechaim-fab-floor) + var(--lechaim-help-bot-h) + var(--lechaim-fab-gap) + var(--lechaim-waiter-size) + var(--lechaim-fab-gap) + env(safe-area-inset-bottom, 0px));
  width: min(calc(100vw - 1.5rem), 320px);
}

.waiter-call-panel__card {
  display: grid;
  gap: 0.75rem;
  padding: 0.85rem 0.9rem 1rem;
  background: #fff8ee;
  border: 1px solid #e6dfd0;
  border-radius: 16px;
  box-shadow: 0 16px 40px rgba(21, 38, 64, 0.22);
}

.waiter-call-panel__header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.waiter-call-panel__title {
  margin: 0;
  flex: 1;
  font-size: 1.05rem;
  font-weight: 800;
  color: #152640;
}

.waiter-call-panel__close {
  width: 2rem;
  height: 2rem;
  border: 0;
  border-radius: 50%;
  background: rgba(21, 38, 64, 0.08);
  color: #152640;
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
}

.waiter-call-panel__hint {
  margin: 0;
  font-size: 0.88rem;
  font-weight: 600;
  color: #5c4318;
}

.waiter-call-panel__options {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.45rem;
}

.waiter-call-option {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 0.7rem;
  width: 100%;
  padding: 0.75rem 0.85rem;
  border: 1px solid rgba(21, 38, 64, 0.16);
  border-radius: 12px;
  background: #fff;
  color: #152640;
  font: inherit;
  font-weight: 800;
  font-size: 1rem;
  text-align: start;
  cursor: pointer;
}

.waiter-call-option__icon {
  font-size: 1.25rem;
  line-height: 1;
  width: 1.6rem;
  text-align: center;
}

.waiter-call-option:hover:not(:disabled),
.waiter-call-option:focus-visible {
  border-color: #8a2f2f;
  background: rgba(138, 47, 47, 0.08);
}

.waiter-call-option:disabled {
  opacity: 0.6;
  cursor: wait;
}

.waiter-call-panel__status {
  margin: 0;
  font-size: 0.86rem;
  font-weight: 700;
  color: #1f6b3a;
}

.waiter-call-panel__status.is-error {
  color: #8a2f2f;
}

body.app-confirm-open .waiter-call-fab,
body.app-confirm-open .waiter-call-panel,
body.cart-open .waiter-call-fab,
body.cart-open .waiter-call-panel,
body.modal-open .waiter-call-fab,
body.modal-open .waiter-call-panel,
body.order-receipt-open .waiter-call-fab,
body.order-receipt-open .waiter-call-panel,
body.table-order-open .waiter-call-fab,
body.table-order-open .waiter-call-panel,
body.help-bot-open .waiter-call-fab,
body.help-bot-open .waiter-call-panel,
body.entry-pending .waiter-call-fab,
body.entry-pending .waiter-call-panel {
  display: none !important;
}

@media (max-width: 768px) {
  .waiter-call-fab {
    left: 0.65rem;
    right: auto;
  }

  .waiter-call-panel {
    left: 0.65rem;
    right: auto;
  }
}

/* Language FAB — stacked above Call Waiter (or above help-bot when waiter is hidden) */
.lang-fab[hidden] {
  display: none !important;
}

.lang-fab {
  position: fixed;
  z-index: 383;
  left: 1rem;
  right: auto;
  bottom: calc(var(--lechaim-fab-floor) + var(--lechaim-help-bot-h) + var(--lechaim-fab-gap) + env(safe-area-inset-bottom, 0px));
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.18rem;
  width: 3.2rem;
  height: 5.5rem;
  min-width: 3.2rem;
  max-width: 3.2rem;
  padding: 0.28rem 0.18rem;
  border: 2px solid #c4a06a;
  border-radius: 999px;
  background: #152640;
  color: #fff8ee;
  font: inherit;
  box-shadow: 0 0 0 3px rgba(196, 160, 106, 0.22), 0 10px 28px rgba(21, 38, 64, 0.32);
  cursor: pointer;
}

.lang-fab__opt {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.15rem;
  height: 2.15rem;
  border-radius: 50%;
  opacity: 0.42;
}

.lang-fab__opt .lang-flag {
  width: 1.28rem;
  height: 0.92rem;
  object-fit: cover;
  border-radius: 2px;
  box-shadow: 0 0 0 1px rgba(255, 248, 238, 0.28);
}

.lang-fab__opt.is-active {
  opacity: 1;
  background: rgba(255, 248, 238, 0.16);
}

.lang-fab__sep {
  width: 1.05rem;
  height: 1px;
  background: rgba(196, 160, 106, 0.55);
  flex: 0 0 1px;
}

body.waiter-fab-on .lang-fab {
  bottom: calc(var(--lechaim-fab-floor) + var(--lechaim-help-bot-h) + var(--lechaim-fab-gap) + var(--lechaim-waiter-size) + var(--lechaim-fab-gap) + env(safe-area-inset-bottom, 0px));
}

.lang-fab:hover,
.lang-fab:focus-visible {
  background: #1e3a5f;
}

body.app-confirm-open .lang-fab,
body.cart-open .lang-fab,
body.modal-open .lang-fab,
body.order-receipt-open .lang-fab,
body.table-order-open .lang-fab,
body.help-bot-open .lang-fab,
body.entry-pending .lang-fab,
body.around-us-open .lang-fab,
body:has(#lechaim-waiter-call-panel:not([hidden])) .lang-fab {
  display: none !important;
}

@media (max-width: 768px) {
  .lang-fab {
    left: 0.65rem;
    right: auto;
  }
}

/* ---------- Around us (nearby things to do) ---------- */
.around-us[hidden] {
  display: none !important;
}

.around-us {
  position: fixed;
  inset: 0;
  z-index: 10080;
  display: grid;
  place-items: center;
  padding: 1rem;
  padding-bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
}

.around-us__backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(21, 38, 64, 0.5);
  cursor: pointer;
}

.around-us__panel {
  position: relative;
  z-index: 1;
  width: min(100%, 420px);
  max-height: min(90vh, 720px);
  overflow: auto;
  display: grid;
  gap: 0.7rem;
  padding: 1.15rem 1rem 1.05rem;
  border-radius: 20px;
  background: linear-gradient(180deg, #fffaf2 0%, #f7f3ea 48%, #f3eee4 100%);
  border: 1px solid rgba(196, 160, 106, 0.4);
  box-shadow: 0 16px 40px rgba(21, 38, 64, 0.28);
  text-align: start;
}

.around-us__kicker {
  margin: 0;
  text-align: center;
  font-size: 1.45rem;
  line-height: 1;
}

.around-us__title {
  margin: 0;
  padding-inline: 2.1rem;
  font-size: 1.22rem;
  font-weight: 800;
  color: #152640;
  text-align: center;
  letter-spacing: 0.01em;
}

.around-us__hint {
  margin: -0.15rem 0 0.15rem;
  font-size: 0.86rem;
  font-weight: 600;
  color: rgba(21, 38, 64, 0.68);
  text-align: center;
  line-height: 1.4;
}

.around-us__list {
  display: grid;
  gap: 0.65rem;
}

.around-us__place {
  display: grid;
  gap: 0.5rem;
  padding: 0.9rem 0.9rem 0.85rem;
  border-radius: 16px;
  background: #fff;
  border: 1px solid rgba(196, 160, 106, 0.28);
  box-shadow: 0 4px 14px rgba(21, 38, 64, 0.05);
}

.around-us__place-head {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  min-width: 0;
}

.around-us__emoji {
  flex: 0 0 2.4rem;
  width: 2.4rem;
  height: 2.4rem;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: #f7f3ea;
  border: 1px solid rgba(196, 160, 106, 0.28);
  font-size: 1.28rem;
  line-height: 1;
}

.around-us__name {
  margin: 0;
  font-size: 1.02rem;
  font-weight: 800;
  color: #152640;
  line-height: 1.25;
}

.around-us__meta {
  margin: 0;
  font-size: 0.84rem;
  font-weight: 600;
  color: rgba(21, 38, 64, 0.68);
  line-height: 1.45;
}

.around-us__maps {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 2.3rem;
  padding: 0.38rem 0.9rem;
  border-radius: 999px;
  background: #152640;
  color: #fff8ee;
  font-size: 0.82rem;
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(21, 38, 64, 0.18);
}

.around-us__maps:hover,
.around-us__maps:focus-visible {
  background: #1e3a5f;
  outline: 2px solid #c4a06a;
  outline-offset: 2px;
}

.around-us__close {
  position: absolute;
  top: 0.55rem;
  inset-inline-end: 0.55rem;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.15rem;
  height: 2.15rem;
  padding: 0;
  border-radius: 50%;
  border: 1px solid rgba(21, 38, 64, 0.16);
  background: #fff;
  color: #152640;
  font-size: 1.45rem;
  line-height: 1;
  box-shadow: 0 2px 8px rgba(21, 38, 64, 0.08);
  cursor: pointer;
}

.around-us__close:hover,
.around-us__close:focus-visible {
  background: #fff8ee;
  border-color: #c4a06a;
}

body.around-us-open {
  overflow: hidden;
}

body.around-us-open .help-bot-fab,
body.around-us-open .help-bot-panel,
body.around-us-open .waiter-call-fab,
body.around-us-open .waiter-call-panel,
body.around-us-open .lang-fab {
  display: none !important;
}

@media (prefers-reduced-motion: reduce) {
  .help-bot-fab__bot {
    animation: none;
  }
}
