/* Shell compartido home — resets Elementor (patrón Nebula) + sin brincos entre bloques */

html:has(#rt-video-scroll),
body.elementor-template-canvas:has(#rt-video-scroll) {
  margin: 0 !important;
  padding: 0 !important;
  background: #f5f0e8 !important;
  background-color: #f5f0e8 !important;
  overscroll-behavior-x: none;
  -webkit-text-size-adjust: 100%;
}

@media (max-width: 768px) {
  html:has(#rt-video-scroll),
  body.elementor-template-canvas:has(#rt-video-scroll) {
    overscroll-behavior: none;
  }

  #rt-tienda-fab .rt-tienda-fab__icon,
  #rt-eventos-fab .rt-eventos-fab__icon {
    animation: none;
  }
}

body:has(#rt-video-scroll) .site-content,
body:has(#rt-video-scroll) #content,
body:has(#rt-video-scroll) .entry-content,
body:has(#rt-restaurantes) .site-content,
body:has(#rt-restaurantes) #content,
body:has(#rt-restaurantes) .entry-content {
  margin: 0 !important;
  padding: 0 !important;
  max-width: none !important;
}

.elementor-element:has(#rt-video-scroll),
.elementor-element:has(#rt-restaurantes),
.elementor-widget:has(#rt-video-scroll),
.elementor-widget:has(#rt-restaurantes),
.elementor-widget-container:has(#rt-video-scroll),
.elementor-widget-container:has(#rt-restaurantes),
.e-con:has(#rt-video-scroll),
.e-con:has(#rt-restaurantes),
.e-con-inner:has(#rt-video-scroll),
.e-con-inner:has(#rt-restaurantes) {
  margin: 0 !important;
  padding: 0 !important;
  max-width: none !important;
  width: 100% !important;
  background: transparent !important;
  background-color: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  gap: 0 !important;
  row-gap: 0 !important;
  --e-con-flex-gap: 0px !important;
  --flex-wrap-mobile-wrap: nowrap !important;
}

/* Contenedor padre que lleva scroll + restaurantes */
.e-con:has(#rt-video-scroll):has(#rt-restaurantes),
.e-con-inner:has(#rt-video-scroll):has(#rt-restaurantes) {
  gap: 0 !important;
  row-gap: 0 !important;
  --gap: 0 !important;
  --row-gap: 0 !important;
}

/* Unión sin hueco entre hero y restaurantes */
#rt-video-scroll.rt-video-scroll {
  margin-bottom: 0 !important;
  max-width: 100%;
}

#rt-tienda-fab.rt-tienda-fab,
#rt-eventos-fab.rt-eventos-fab {
  position: fixed !important;
  top: auto !important;
  bottom: max(1.15rem, env(safe-area-inset-bottom, 0px)) !important;
  z-index: 2147483000;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.42rem 0.8rem 0.42rem 0.42rem;
  border-radius: 999px;
  color: #fff !important;
  text-decoration: none;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  -webkit-tap-highlight-color: transparent;
  transform: none !important;
  will-change: auto;
}

#rt-tienda-fab.rt-tienda-fab {
  right: max(0.9rem, env(safe-area-inset-right, 0px)) !important;
  left: auto !important;
  background: #1c7944;
  box-shadow: 0 10px 28px rgba(28, 121, 68, 0.42);
}

#rt-eventos-fab.rt-eventos-fab {
  left: max(0.9rem, env(safe-area-inset-left, 0px)) !important;
  right: auto !important;
  background: #1a1612;
  box-shadow: 0 10px 28px rgba(26, 22, 18, 0.42);
}

#rt-tienda-fab .rt-tienda-fab__icon,
#rt-eventos-fab .rt-eventos-fab__icon {
  display: block;
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background-color: #fff;
  animation: rt-fab-float 2.8s ease-in-out infinite;
}

#rt-tienda-fab .rt-tienda-fab__icon {
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M7 18c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm10 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zM7.2 14h9.45c.75 0 1.41-.41 1.75-1.03L21 7H6.2L5.3 4H2v2h2l3.6 7.59L6.2 16c-.1.2-.2.4-.2.7 0 .8.7 1.3 1.5 1.3H19v-2H8.4l.8-1.6z'/%3E%3C/svg%3E") center / 20px 20px no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M7 18c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm10 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zM7.2 14h9.45c.75 0 1.41-.41 1.75-1.03L21 7H6.2L5.3 4H2v2h2l3.6 7.59L6.2 16c-.1.2-.2.4-.2.7 0 .8.7 1.3 1.5 1.3H19v-2H8.4l.8-1.6z'/%3E%3C/svg%3E") center / 20px 20px no-repeat;
}

#rt-eventos-fab .rt-eventos-fab__icon {
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M20 6h-2V4h-2v2H8V4H6v2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm0 14H4V10h16v10zm-8-1l-4-4 1.4-1.4L12 16.2l4.6-4.6L18 13l-6 6z'/%3E%3C/svg%3E") center / 20px 20px no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M20 6h-2V4h-2v2H8V4H6v2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm0 14H4V10h16v10zm-8-1l-4-4 1.4-1.4L12 16.2l4.6-4.6L18 13l-6 6z'/%3E%3C/svg%3E") center / 20px 20px no-repeat;
  animation-delay: 0.35s;
}

#rt-tienda-fab:hover,
#rt-tienda-fab:focus-visible {
  background: #21924f;
  outline: none;
}

#rt-eventos-fab:hover,
#rt-eventos-fab:focus-visible {
  background: #2c2620;
  outline: none;
}

@keyframes rt-fab-float {
  0%,
  100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

@media (min-width: 769px) {
  #rt-tienda-fab.rt-tienda-fab,
  #rt-eventos-fab.rt-eventos-fab {
    bottom: 1.35rem !important;
    font-size: 0.72rem;
    padding: 0.4rem 0.85rem 0.4rem 0.4rem;
  }

  #rt-tienda-fab.rt-tienda-fab {
    right: 1.35rem !important;
    left: auto !important;
  }

  #rt-eventos-fab.rt-eventos-fab {
    left: 1.35rem !important;
    right: auto !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  #rt-tienda-fab .rt-tienda-fab__icon,
  #rt-eventos-fab .rt-eventos-fab__icon {
    animation: none;
  }
}
