
/* Botón flotante */
#chat-chiapas-btn {
  position: fixed;
  bottom: 25px;
  right: 25px;
  background: #C90166;
  color: white;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,.3);
  z-index: 9999;
  transition: transform .2s ease;
}
#chat-chiapas-btn:hover {
  transform: scale(1.1);
}

/* Ventana del chat */
#chat-chiapas-window {
  position: fixed;
  bottom: 100px;
  right: 25px;
  width: 350px;
  height: 500px;
  background: #ffffffdd;
  backdrop-filter: blur(10px);
  border-radius: 20px;
  border: 2px solid #C90166;
  box-shadow: 0 8px 25px rgba(0,0,0,.3);
  display: none;
  flex-direction: column;
  overflow: hidden;
  z-index: 9999;
}

#chat-chiapas-header {
  background: linear-gradient(90deg, #C90166, #009887);
  color: white;
  padding: 12px 15px;
  font-weight: bold;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

#chat-chiapas-close {
  cursor: pointer;
  font-size: 24px;
}

/* Área de mensajes */
#chat-chiapas-messages {
  flex: 1;
  padding: 10px;
  overflow-y: auto;
  font-size: 14px;
}

.chat-msg {
  margin-bottom: 12px;
  padding: 10px;
  border-radius: 10px;
  max-width: 80%;
}

.chat-user {
  background: #C90166;
  color: white;
  margin-left: auto;
}

.chat-ai {
  background: #f3f3f3;
  border: 1px solid #ccc;
}

/* Input */
#chat-chiapas-input {
  display: flex;
  border-top: 1px solid #ddd;
}

#chat-chiapas-text {
  flex: 1;
  padding: 10px;
  border: none;
  outline: none;
}

#chat-chiapas-send {
  background: #009887;
  color: white;
  border: none;
  padding: 0 20px;
  cursor: pointer;
}



/* ==== BOTÓN FLOTANTE (en header) ==== */
.theme-toggle {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  background: #009887;
  color: #fff;
  border: 2px solid #fff;
  border-radius: 50%;
  width: 3.2rem;
  height: 3.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
  z-index: 5;
  transition: all 0.3s ease;
}

.theme-toggle:hover,
.theme-toggle:focus {
  background: #C90166;
  transform: scale(1.1);
  outline: none;
}

/* Asegura accesibilidad al navegar con teclado */
.theme-toggle:focus-visible {
  outline: 3px solid #AE1922;
  outline-offset: 3px;
}

    
   /* ====== MODO OSCURO TOGGLE (flotante arriba derecha) ====== */
.theme-toggle {
  position: fixed;
  top: 1.2rem;
  right: 1.2rem;
  background: var(--color-primario);
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 3rem;
  height: 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
  z-index: 1050;
  transition: all 0.3s ease;
}

.theme-toggle:hover {
  background: var(--color-secundario);
  transform: scale(1.1);
}




  #contador-visitas {
    transition: all 0.3s ease-in-out;
  }
