.xy-tc-wrapper {
  max-width: 1120px;
  margin: 32px auto;
  padding: 0 18px;
  font-family: inherit;
}
.xy-tc-hero,
.xy-tc-card {
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 20px;
  box-shadow: 0 16px 44px rgba(15, 23, 42, 0.08);
  padding: 28px;
  margin-bottom: 20px;
}
.xy-tc-kicker {
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 12px;
  opacity: 0.7;
}
.xy-tc-hero h2,
.xy-tc-card h3 {
  margin-top: 0;
}
.xy-tc-description p:last-child,
.xy-tc-weather p:last-child {
  margin-bottom: 0;
}
.xy-tc-intro {
  font-size: 18px;
  line-height: 1.55;
  margin: 10px 0 18px;
}
.xy-tc-radius-note {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 8px 12px;
  margin: 0 0 14px;
  background: rgba(15, 23, 42, 0.06);
  color: #334155;
  font-size: 14px;
}
.xy-tc-city-info {
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  margin-top: 18px;
  padding-top: 18px;
}
.xy-tc-city-info h3 {
  margin-top: 0;
  font-size: 20px;
}
.xy-tc-webcam-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}
.xy-tc-webcam-card {
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 18px;
  padding: 12px;
}
.xy-tc-webcam-frame {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 16px;
  background: var(--xy-tc-primary, #0f172a);
}
.xy-tc-webcam-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.xy-tc-webcam-card h4 {
  margin: 12px 0 6px;
}
.xy-tc-webcam-card p {
  margin: 0 0 10px;
  font-size: 14px;
  opacity: 0.82;
}
.xy-tc-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 8px 12px;
  background: var(--xy-tc-primary, #0f172a);
  color: #fff;
  text-decoration: none;
  font-size: 13px;
}
.xy-tc-link:hover,
.xy-tc-link:focus {
  color: #fff;
  opacity: 0.9;
}
.xy-tc-quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0;
}
.xy-tc-quick-actions button,
.xy-tc-chat-form button {
  border: 0;
  border-radius: 999px;
  padding: 10px 16px;
  background: var(--xy-tc-primary, #0f172a);
  color: #fff;
  cursor: pointer;
}
.xy-tc-chat-widget,
.xy-tc-chat-widget * {
  box-sizing: border-box;
}
.xy-tc-chat-widget {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 99999;
  font-family: var(--xy-tc-font-family, inherit);
  max-width: calc(100vw - 28px);
}
.xy-tc-chat-toggle {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: 0;
  background: var(--xy-tc-primary, #0f172a);
  color: var(--xy-tc-header-text, #fff);
  font-size: 26px;
  cursor: pointer;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.25);
}
.xy-tc-chat-panel {
  display: none;
  position: absolute;
  right: 0;
  bottom: 78px;
  width: min(390px, calc(100vw - 36px));
  height: 560px;
  max-height: calc(100vh - 120px);
  background: var(--xy-tc-chat-bg, #f8fafc);
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 22px;
  box-shadow: 0 22px 80px rgba(15, 23, 42, 0.24);
  overflow: hidden;
  max-width: calc(100vw - 36px);
}
.xy-tc-chat-widget.is-open .xy-tc-chat-panel {
  display: flex;
  flex-direction: column;
}
.xy-tc-chat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 18px;
  background: var(--xy-tc-primary, #0f172a);
  color: var(--xy-tc-header-text, #fff);
  min-width: 0;
}
.xy-tc-chat-header strong {
  color: var(--xy-tc-title-color, var(--xy-tc-header-text, #fff));
  min-width: 0;
  overflow-wrap: anywhere;
}
.xy-tc-chat-close {
  background: transparent;
  border: 0;
  color: var(--xy-tc-header-text, #fff);
  font-size: 24px;
  cursor: pointer;
  flex: 0 0 auto;
}
.xy-tc-chat-messages {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 16px;
  background: var(--xy-tc-chat-bg, #f8fafc);
  max-width: 100%;
}
.xy-tc-msg {
  max-width: 86%;
  margin-bottom: 10px;
  padding: 11px 13px;
  border-radius: 16px;
  line-height: 1.4;
  overflow-wrap: anywhere;
  word-break: break-word;
  white-space: normal;
}
.xy-tc-msg a {
  color: var(--xy-tc-primary, #0f172a);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.xy-tc-msg-bot {
  background: var(--xy-tc-bot-bg, #fff);
  border: 1px solid rgba(15, 23, 42, 0.08);
  color: var(--xy-tc-text-color, #0f172a);
}
.xy-tc-msg-user {
  margin-left: auto;
  background: var(--xy-tc-primary, #0f172a);
  color: var(--xy-tc-user-text, #fff);
}
.xy-tc-msg-user a {
  color: var(--xy-tc-user-text, #fff);
}
.xy-tc-chat-form {
  display: flex;
  gap: 8px;
  padding: 12px;
  background: #fff;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  position: relative;
  max-width: 100%;
}
.xy-tc-chat-form input {
  flex: 1 1 auto;
  min-width: 0;
  border: 1px solid rgba(15, 23, 42, 0.18);
  border-radius: 999px;
  padding: 10px 14px;
  color: var(--xy-tc-text-color, #0f172a);
}
.xy-tc-chat-form button {
  flex: 0 0 auto;
}
.xy-tc-chat-form.is-loading::before {
  content: '';
  display: none;
  position: absolute;
  bottom: 65px;
  left: 18px;
  font-size: 12px;
  opacity: 0.7;
  color: var(--xy-tc-text-color, #0f172a);
}
@media (max-width: 520px) {
  .xy-tc-chat-widget {
    right: 14px;
    bottom: 14px;
  }
  .xy-tc-chat-panel {
    height: 74vh;
    width: calc(100vw - 28px);
    max-width: calc(100vw - 28px);
  }
  .xy-tc-chat-form {
    gap: 6px;
  }
  .xy-tc-chat-form button {
    padding-left: 12px;
    padding-right: 12px;
  }
}
.xy-tc-date-action {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.xy-tc-date-action label {
  font-weight: 700;
  color: var(--xy-tc-text-color, #0f172a);
}
.xy-tc-date-action input[type="date"] {
  max-width: 170px;
  border: 1px solid rgba(15, 23, 42, 0.18);
  border-radius: 999px;
  padding: 9px 12px;
  min-width: 0;
}
.xy-tc-chat-panel,
.xy-tc-chat-messages,
.xy-tc-msg,
.xy-tc-msg * {
  max-width: 100%;
  overflow-wrap: anywhere;
  word-wrap: break-word;
}
.xy-tc-msg pre,
.xy-tc-msg code {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.xy-tc-chat-form {
  overflow: hidden;
}
@media (max-width: 520px) {
  .xy-tc-date-action {
    width: 100%;
  }
  .xy-tc-date-action input[type="date"] {
    flex: 1 1 150px;
  }
}

/* V2.1.2 — boutons frontend plus propres et anti-styles du thème */
.xy-tc-wrapper,
.xy-tc-wrapper * {
  box-sizing: border-box;
}
.xy-tc-quick-actions {
  align-items: center;
  gap: 12px;
  margin: 22px 0 24px;
}
.xy-tc-quick-actions > button,
.xy-tc-date-action button {
  appearance: none !important;
  -webkit-appearance: none !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: auto !important;
  min-width: 0 !important;
  max-width: 100% !important;
  height: 44px !important;
  min-height: 0 !important;
  aspect-ratio: auto !important;
  border: 1px solid rgba(15, 23, 42, 0.08) !important;
  border-radius: 14px !important;
  padding: 0 16px !important;
  margin: 0 !important;
  background: var(--xy-tc-primary, #0f172a) !important;
  color: var(--xy-tc-header-text, #fff) !important;
  font-family: var(--xy-tc-font-family, inherit) !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1 !important;
  text-align: center !important;
  white-space: nowrap !important;
  text-decoration: none !important;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.14) !important;
  cursor: pointer !important;
  transition: transform .18s ease, box-shadow .18s ease, opacity .18s ease !important;
}
.xy-tc-quick-actions > button:hover,
.xy-tc-date-action button:hover,
.xy-tc-quick-actions > button:focus,
.xy-tc-date-action button:focus {
  transform: translateY(-1px) !important;
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.18) !important;
  opacity: .96 !important;
}
.xy-tc-date-action {
  display: inline-flex !important;
  align-items: center !important;
  gap: 10px !important;
  min-width: 0 !important;
  padding: 6px !important;
  border: 1px solid rgba(15, 23, 42, 0.09) !important;
  border-radius: 18px !important;
  background: #fff !important;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.06) !important;
}
.xy-tc-date-action label {
  margin: 0 2px 0 4px !important;
  white-space: nowrap !important;
  font-size: 14px !important;
}
.xy-tc-date-action input[type="date"] {
  height: 44px !important;
  width: 170px !important;
  max-width: min(170px, 48vw) !important;
  border-radius: 14px !important;
  background: #fff !important;
}

/* V2.1.2 — webcams : évite les iframes cassées et affiche un vrai état de secours */
.xy-tc-webcam-frame {
  background: linear-gradient(135deg, rgba(15,23,42,.08), rgba(15,23,42,.16));
}
.xy-tc-webcam-frame img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 0;
}
.xy-tc-webcam-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 18px;
  text-align: center;
  color: #334155;
  background: linear-gradient(135deg, #f1f5f9, #e2e8f0);
}
.xy-tc-webcam-placeholder span {
  font-size: 26px;
  line-height: 1;
}
.xy-tc-webcam-placeholder strong {
  font-size: 14px;
  color: #0f172a;
}
.xy-tc-webcam-placeholder small {
  font-size: 12px;
  color: #64748b;
}
.xy-tc-webcam-frame-image .xy-tc-webcam-placeholder {
  display: none;
}
.xy-tc-webcam-frame-image.is-broken .xy-tc-webcam-placeholder {
  display: flex;
}

/* V2.1.2 — chat : boutons et messages sans scroll horizontal */
.xy-tc-chat-panel,
.xy-tc-chat-panel * {
  box-sizing: border-box;
}
.xy-tc-chat-panel {
  overflow: hidden !important;
}
.xy-tc-chat-messages {
  overscroll-behavior: contain;
}
.xy-tc-msg {
  width: fit-content;
  min-width: 0;
  max-width: 88% !important;
  overflow: hidden;
}
.xy-tc-msg p,
.xy-tc-msg ul,
.xy-tc-msg ol {
  max-width: 100%;
  overflow-wrap: anywhere;
}
.xy-tc-language-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  max-width: 88%;
  margin: 0 0 12px;
}
.xy-tc-language-chips button,
.xy-tc-chat-form button {
  appearance: none !important;
  -webkit-appearance: none !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: auto !important;
  min-width: 0 !important;
  height: 42px !important;
  min-height: 0 !important;
  aspect-ratio: auto !important;
  border: 0 !important;
  border-radius: 14px !important;
  padding: 0 14px !important;
  margin: 0 !important;
  background: var(--xy-tc-primary, #0f172a) !important;
  color: var(--xy-tc-header-text, #fff) !important;
  font-family: var(--xy-tc-font-family, inherit) !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1 !important;
  white-space: nowrap !important;
  cursor: pointer !important;
}
.xy-tc-chat-form button {
  flex: 0 0 auto !important;
  min-width: 86px !important;
}
.xy-tc-chat-form input {
  height: 42px !important;
  max-width: 100% !important;
}
.xy-tc-chat-toggle {
  appearance: none !important;
  -webkit-appearance: none !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 60px !important;
  height: 60px !important;
  min-width: 60px !important;
  min-height: 60px !important;
  aspect-ratio: 1 / 1 !important;
  padding: 0 !important;
  border-radius: 50% !important;
}
@media (max-width: 700px) {
  .xy-tc-quick-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .xy-tc-quick-actions > button {
    width: 100% !important;
    white-space: normal !important;
  }
  .xy-tc-date-action {
    grid-column: 1 / -1;
    width: 100%;
    flex-wrap: wrap;
  }
}
@media (max-width: 420px) {
  .xy-tc-quick-actions {
    grid-template-columns: 1fr;
  }
  .xy-tc-date-action input[type="date"] {
    flex: 1 1 150px !important;
    width: auto !important;
  }
  .xy-tc-chat-form {
    align-items: stretch;
  }
  .xy-tc-chat-form button {
    min-width: 74px !important;
    padding-left: 10px !important;
    padding-right: 10px !important;
  }
}


/* V2.1.3 — correctif critique : le panneau de chat ne doit jamais reprendre la largeur du bouton */
html body .xy-tc-chat-widget[data-xy-tc-chat] {
  width: auto !important;
  min-width: 0 !important;
  max-width: none !important;
}
html body .xy-tc-chat-widget[data-xy-tc-chat].is-open {
  width: 390px !important;
  min-width: 320px !important;
  max-width: calc(100vw - 32px) !important;
}
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-chat-panel {
  position: fixed !important;
  right: 22px !important;
  bottom: 96px !important;
  left: auto !important;
  top: auto !important;
  width: 390px !important;
  min-width: 320px !important;
  max-width: calc(100vw - 32px) !important;
  height: 560px !important;
  max-height: calc(100vh - 125px) !important;
  min-height: 360px !important;
  display: none !important;
  flex-direction: column !important;
  overflow: hidden !important;
  transform: none !important;
}
html body .xy-tc-chat-widget[data-xy-tc-chat].is-open .xy-tc-chat-panel {
  display: flex !important;
}
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-chat-header {
  width: 100% !important;
  min-width: 0 !important;
  flex: 0 0 auto !important;
}
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-chat-header strong {
  display: block !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  word-break: normal !important;
  overflow-wrap: normal !important;
  letter-spacing: normal !important;
}
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-chat-messages {
  width: 100% !important;
  min-width: 0 !important;
  flex: 1 1 auto !important;
}
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-chat-form {
  width: 100% !important;
  min-width: 0 !important;
  flex: 0 0 auto !important;
}
@media (max-width: 520px) {
  html body .xy-tc-chat-widget[data-xy-tc-chat] {
    right: 14px !important;
    bottom: 14px !important;
  }
  html body .xy-tc-chat-widget[data-xy-tc-chat].is-open {
    width: calc(100vw - 28px) !important;
    min-width: 0 !important;
    max-width: calc(100vw - 28px) !important;
  }
  html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-chat-panel {
    right: 14px !important;
    bottom: 88px !important;
    width: calc(100vw - 28px) !important;
    min-width: 0 !important;
    max-width: calc(100vw - 28px) !important;
    height: 74vh !important;
    max-height: calc(100vh - 112px) !important;
  }
}

/* V3 — envoi du récapitulatif par mail */
.xy-tc-email-share {
  flex: 0 0 auto;
  padding: 10px 12px 12px;
  background: #fff;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}
.xy-tc-email-toggle {
  appearance: none !important;
  -webkit-appearance: none !important;
  border: 0 !important;
  background: transparent !important;
  color: var(--xy-tc-primary, #0f172a) !important;
  font-family: var(--xy-tc-font-family, inherit) !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  padding: 0 !important;
  margin: 0 0 8px !important;
  text-decoration: underline !important;
  text-underline-offset: 3px !important;
  cursor: pointer !important;
  width: auto !important;
  height: auto !important;
  min-width: 0 !important;
  min-height: 0 !important;
  box-shadow: none !important;
}
.xy-tc-email-form {
  display: flex;
  gap: 8px;
  align-items: center;
  max-width: 100%;
}
.xy-tc-email-form[hidden] {
  display: none !important;
}
.xy-tc-email-form input[type="email"] {
  flex: 1 1 auto;
  min-width: 0;
  height: 40px;
  border: 1px solid rgba(15, 23, 42, 0.18);
  border-radius: 14px;
  padding: 9px 12px;
  color: var(--xy-tc-text-color, #0f172a);
}
.xy-tc-email-form button {
  flex: 0 0 auto !important;
  height: 40px !important;
  min-width: 74px !important;
  border-radius: 14px !important;
  border: 0 !important;
  padding: 0 12px !important;
  background: var(--xy-tc-primary, #0f172a) !important;
  color: var(--xy-tc-header-text, #fff) !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  line-height: 1 !important;
  cursor: pointer !important;
}
.xy-tc-email-status {
  min-height: 16px;
  margin: 6px 0 0;
  font-size: 12px;
  line-height: 1.3;
  color: var(--xy-tc-text-color, #0f172a);
  opacity: .82;
}
@media (max-width: 420px) {
  .xy-tc-email-form {
    flex-direction: column;
    align-items: stretch;
  }
  .xy-tc-email-form button,
  .xy-tc-email-form input[type="email"] {
    width: 100% !important;
  }
}

/* V4.1 — liens du chat visibles en boutons compacts */
.xy-tc-msg-bot a,
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-msg-bot a {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 4px !important;
  margin: 2px 2px !important;
  padding: 5px 9px !important;
  border-radius: 999px !important;
  background: var(--xy-tc-primary, #0f172a) !important;
  color: var(--xy-tc-header-text, #ffffff) !important;
  font-weight: 700 !important;
  font-size: 12px !important;
  line-height: 1.1 !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  max-width: 100% !important;
}
.xy-tc-msg-bot a:hover,
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-msg-bot a:hover {
  opacity: .9 !important;
  text-decoration: none !important;
}

/* V5.0 — indicateur de réflexion du chatbot */
.xy-tc-chat-form.is-loading::before,
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-chat-form.is-loading::before {
  content: none !important;
  display: none !important;
}
.xy-tc-thinking,
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-thinking {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  width: auto !important;
  max-width: 88% !important;
  opacity: .9;
}
.xy-tc-thinking-text {
  white-space: nowrap;
}
.xy-tc-thinking-dots {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.xy-tc-thinking-dots span {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: currentColor;
  opacity: .35;
  animation: xyTcThinkingDots 1s infinite ease-in-out;
}
.xy-tc-thinking-dots span:nth-child(2) {
  animation-delay: .16s;
}
.xy-tc-thinking-dots span:nth-child(3) {
  animation-delay: .32s;
}
@keyframes xyTcThinkingDots {
  0%, 80%, 100% {
    transform: translateY(0);
    opacity: .35;
  }
  40% {
    transform: translateY(-3px);
    opacity: 1;
  }
}

/* V5.2 — bouton de réinitialisation de session */
.xy-tc-session-reset,
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-session-reset {
  display: flex !important;
  justify-content: flex-start !important;
  width: 100% !important;
  margin: 8px 0 4px !important;
}
.xy-tc-session-reset button,
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-session-reset button {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 38px !important;
  padding: 9px 14px !important;
  border: 0 !important;
  border-radius: 12px !important;
  background: var(--xy-tc-primary, #0f172a) !important;
  color: var(--xy-tc-header-text, #ffffff) !important;
  font-family: var(--xy-tc-font-family, inherit) !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  cursor: pointer !important;
  white-space: normal !important;
  max-width: 100% !important;
  box-shadow: 0 8px 18px rgba(15, 23, 42, .16) !important;
}
.xy-tc-session-reset button:hover,
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-session-reset button:hover {
  opacity: .92 !important;
}

/* V5.3 — carte gratuite OpenStreetMap avant les webcams */
.xy-tc-map-card {
  overflow: hidden;
}
.xy-tc-map-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}
.xy-tc-map-head h3 {
  margin: 0 0 6px !important;
}
.xy-tc-map-head p {
  margin: 0;
  color: #475569;
  line-height: 1.45;
}
.xy-tc-map-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr);
  gap: 16px;
  align-items: stretch;
}
.xy-tc-map-canvas {
  width: 100%;
  min-height: 420px;
  border-radius: 18px;
  overflow: hidden;
  background: #e2e8f0;
  border: 1px solid rgba(15, 23, 42, 0.08);
  z-index: 1;
}
.xy-tc-map-list {
  max-height: 420px;
  overflow: auto;
  padding: 6px;
  border-radius: 18px;
  background: #f8fafc;
  border: 1px solid rgba(15, 23, 42, 0.08);
}
.xy-tc-map-status {
  margin: 10px;
  color: #475569;
  font-size: 14px;
  line-height: 1.45;
}
.xy-tc-map-list-item {
  appearance: none !important;
  -webkit-appearance: none !important;
  display: flex !important;
  width: 100% !important;
  gap: 10px !important;
  align-items: flex-start !important;
  text-align: left !important;
  border: 1px solid rgba(15, 23, 42, 0.08) !important;
  border-radius: 14px !important;
  background: #fff !important;
  color: #0f172a !important;
  padding: 10px !important;
  margin: 0 0 8px !important;
  cursor: pointer !important;
  box-shadow: none !important;
  min-height: 0 !important;
  height: auto !important;
  font-family: var(--xy-tc-font-family, inherit) !important;
}
.xy-tc-map-list-item:hover,
.xy-tc-map-list-item:focus {
  border-color: rgba(15, 23, 42, 0.22) !important;
  background: #f8fafc !important;
}
.xy-tc-map-pin {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: var(--xy-tc-primary, #0f172a);
  color: var(--xy-tc-header-text, #fff);
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
}
.xy-tc-map-list-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.xy-tc-map-list-text strong {
  font-size: 14px;
  line-height: 1.25;
  color: #0f172a;
}
.xy-tc-map-list-text small,
.xy-tc-map-list-text em {
  font-size: 12px;
  line-height: 1.25;
  color: #64748b;
  font-style: normal;
}
.xy-tc-map-list-text .xy-tc-map-geocoded {
  color: #475569;
  opacity: .78;
}
.xy-tc-map-card .leaflet-container {
  font-family: var(--xy-tc-font-family, inherit);
}
.xy-tc-map-card .leaflet-popup-content {
  line-height: 1.35;
}
.xy-tc-map-card .leaflet-popup-content a {
  display: inline-flex;
  margin-top: 5px;
  padding: 5px 9px;
  border-radius: 999px;
  background: var(--xy-tc-primary, #0f172a);
  color: var(--xy-tc-header-text, #fff) !important;
  text-decoration: none;
  font-size: 12px;
  font-weight: 700;
}
@media (max-width: 860px) {
  .xy-tc-map-layout {
    grid-template-columns: 1fr;
  }
  .xy-tc-map-canvas {
    min-height: 340px;
  }
  .xy-tc-map-list {
    max-height: 280px;
  }
}

/* V5.5 — météo dans le bloc informations */
.xy-tc-city-weather {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.05);
  border: 1px solid rgba(15, 23, 42, 0.08);
  color: #334155;
}
.xy-tc-city-weather strong {
  color: #0f172a;
}
.xy-tc-city-weather span {
  line-height: 1.35;
}

/* V5.5 — carte centrée sur la ville + aperçu photo au survol */
.xy-tc-map-canvas {
  position: relative;
}
.xy-tc-map-radius-circle {
  stroke: var(--xy-tc-primary, #0f172a);
  fill: var(--xy-tc-primary, #0f172a);
}
.xy-tc-map-photo-preview {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 500;
  width: min(220px, calc(100% - 28px));
  border-radius: 16px;
  overflow: hidden;
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, 0.12);
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.22);
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity .18s ease, transform .18s ease;
}
.xy-tc-map-photo-preview.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.xy-tc-map-photo-preview img {
  display: block;
  width: 100%;
  height: 130px;
  object-fit: cover;
  background: #e2e8f0;
}
.xy-tc-map-photo-preview strong,
.xy-tc-map-photo-preview small {
  display: block;
  padding: 0 12px;
}
.xy-tc-map-photo-preview strong {
  padding-top: 10px;
  color: #0f172a;
  line-height: 1.25;
}
.xy-tc-map-photo-preview small {
  padding-top: 4px;
  padding-bottom: 10px;
  color: #64748b;
  line-height: 1.25;
}
.xy-tc-map-photo-empty {
  height: 110px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e2e8f0;
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
}
.xy-tc-map-popup-photo {
  display: block;
  width: 210px;
  max-width: 100%;
  height: 105px;
  object-fit: cover;
  border-radius: 10px;
  margin: 0 0 8px;
  background: #e2e8f0;
}
@media (max-width: 640px) {
  .xy-tc-map-photo-preview {
    top: auto;
    bottom: 14px;
    right: 14px;
    width: min(200px, calc(100% - 28px));
  }
  .xy-tc-map-photo-preview img {
    height: 105px;
  }
}

/* V5.6.1 — correctif carte : certains thèmes imposent une hauteur/affichage à 0 */
.xy-tc-map-card,
.xy-tc-map-layout,
.xy-tc-map-canvas {
  display: block;
}
.xy-tc-map-layout {
  display: grid !important;
}
.xy-tc-map-canvas,
.xy-tc-map-canvas.leaflet-container {
  height: 420px !important;
  min-height: 420px !important;
  max-height: none !important;
}
.xy-tc-map-canvas .leaflet-pane,
.xy-tc-map-canvas .leaflet-map-pane,
.xy-tc-map-canvas .leaflet-tile-pane,
.xy-tc-map-canvas .leaflet-overlay-pane,
.xy-tc-map-canvas .leaflet-marker-pane,
.xy-tc-map-canvas .leaflet-popup-pane {
  max-width: none !important;
}
@media (max-width: 640px) {
  .xy-tc-map-canvas,
  .xy-tc-map-canvas.leaflet-container {
    height: 340px !important;
    min-height: 340px !important;
  }
}


/* V5.6.3 — correction largeur carte / suppression scroll horizontal */
.xy-tc-wrapper,
.xy-tc-wrapper *,
.xy-tc-chat-widget,
.xy-tc-chat-widget * {
  box-sizing: border-box;
}
.xy-tc-wrapper,
.xy-tc-card,
.xy-tc-map-card,
.xy-tc-map-layout,
.xy-tc-map-canvas,
.xy-tc-map-list {
  max-width: 100% !important;
  min-width: 0 !important;
}
.xy-tc-map-card {
  width: 100% !important;
  overflow: hidden !important;
}
.xy-tc-map-layout {
  width: 100% !important;
  overflow: hidden !important;
  grid-template-columns: minmax(0, 1.25fr) minmax(240px, .75fr) !important;
}
.xy-tc-map-canvas,
.xy-tc-map-canvas.leaflet-container {
  width: 100% !important;
  max-width: 100% !important;
  overflow: hidden !important;
}
.xy-tc-map-list {
  width: 100% !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
}
.xy-tc-map-list-item,
html body .xy-tc-wrapper .xy-tc-map-list-item {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
}
.xy-tc-map-list-text {
  min-width: 0 !important;
  max-width: 100% !important;
  overflow: hidden !important;
}
.xy-tc-map-list-text strong,
.xy-tc-map-list-text small,
.xy-tc-map-list-text em {
  max-width: 100% !important;
  overflow-wrap: anywhere !important;
  word-break: normal !important;
}
.xy-tc-map-card .leaflet-container,
.xy-tc-map-card .leaflet-pane,
.xy-tc-map-card .leaflet-map-pane {
  max-width: 100% !important;
}
.xy-tc-map-photo-empty {
  display: none !important;
}
@media (max-width: 980px) {
  .xy-tc-map-layout {
    grid-template-columns: minmax(0, 1fr) !important;
  }
}

/* V6.1 — météo locale dans l'entête du chat, aucune information hors bulle */
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-chat-header {
  align-items: flex-start !important;
  gap: 12px !important;
}
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-chat-header-content {
  min-width: 0 !important;
  flex: 1 1 auto !important;
}
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-chat-weather {
  display: block !important;
  margin-top: 5px !important;
  line-height: 1.25 !important;
  color: var(--xy-tc-header-text, #fff) !important;
  opacity: 0.92 !important;
  white-space: normal !important;
}
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-chat-weather span {
  display: block !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.04em !important;
  opacity: 0.8 !important;
}
html body .xy-tc-chat-widget[data-xy-tc-chat] .xy-tc-chat-weather small {
  display: block !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  word-break: normal !important;
  overflow-wrap: anywhere !important;
}
