
body {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  margin: 0;
  background-image: url('../img/fondo.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed;
}


/*------------INDEX---------------------------------*/

.contenedor_index {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  height: 80vh; /* alto de la ventana */
  text-align: center; /* centra el texto también */
}

.bienvenida {

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.titulo {
  font-size: 2.5rem;
  margin-bottom: 10px;
  color: white;
}

.subtitulo {
  font-size: 1.2rem;
  color: #666;
}

@media (max-width: 768px) {

  .contenedor_index {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 60vh; /* alto de la ventana */
    text-align: center; /* centra el texto también */
  }

  .titulo {
    font-size: 2.5rem;
    margin-bottom: 10px;
    color: white;
  }

  .subtitulo {
    font-size: 1.2rem;
    color: #666;
  }

}
/*----------------------------------------------------------*/

/*-----------------PANTALLA LOCAL 2-------------------------*/

        
.header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 10px 0;
            margin-bottom: 20px;
            border-bottom: 1px solid #dee2e6;
}
        
.animated-button {
            border-radius: 16px;
            padding: 20px;
            display: flex;
            flex-direction: column;
            justify-content: space-between;
            cursor: pointer;
            transition: transform 0.15s ease-out, box-shadow 0.15s ease-out;
            box-shadow: 6px 6px 12px rgba(0, 0, 0, 0.4), -4px -4px 6px rgba(255, 255, 255, 0.4);
}

.animated-button:active {
            transform: translate(2px, 2px);
            box-shadow: 2px 2px 12px rgba(0, 0, 0, 0.4), -1px -1px 6px rgba(255, 255, 255, 0.4);
}

.button-content {
            display: flex;
            flex-direction: column;
            height: 100%;
            justify-content: space-between; 
            align-items: left;
            padding: 0 10px;
}

.animated-button i {
            font-size: 85px;
            color: white;
            text-shadow: 3px 3px 6px rgba(255, 255, 255, 0.38);
}

.animated-button h3 {
            color: white;
            font-size: 22px;
            font-weight: bold;
            text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.45);
            margin-bottom: 10px;
}

.emergency {
            background: linear-gradient(to bottom right, #972323, #ff0000);
            height: 550px;
            flex: 1;
            min-width: 300px;
            margin-right: 10px;
}

.caution {
            background: linear-gradient(to bottom right, #b39d26, #f0e004);
            height: 550px;
            flex: 1;
            min-width: 300px;
            margin-left: 10px;
}

.big-buttons-row {
            display: flex;
            justify-content: space-between;
            margin-bottom: 30px;
}

.desconectado {
            background: linear-gradient(to bottom right,rgb(121, 45, 9),rgb(219, 171, 10));
            height: 50px;
            font-size: 30px;
            color: white;
            text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.38);
            justify-content: center;
            align-items: center;
            text-align: center;
            animation: blink 1s infinite;
}
    
.disabled-button {
            background: white !important;
}

.disabled-button i,
.disabled-button h3 {
            color: black !important;
}
        
.user-status {
            position: relative;
            padding-left: 15px; 
            display: inline-block;
}

.status-circle {
            position: absolute;
            left: 0; 
            top: 55%;
            transform: translateY(-50%);
            width: 12px;
            height: 12px;
            border-radius: 50%;
}

.status-circle.online {
            background-color: #01fa3b;
            box-shadow: 0 0 5px #1cf04d;
}

.status-circle.offline {
  background-color: #6c757d;
}

@media (max-width: 768px) {
            .big-buttons-row {
                flex-direction: column;
            }
            .emergency, .caution {
                height: 300px;
                color: white;
                margin: 10px 0 !important;
                width: 100% !important;
            }
            .animated-button h3 {
                color: white;
                font-size: 22px;
                font-weight: bold;
                text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.45);
                margin-bottom: 10px;
            }
            .animated-button i {
                font-size: 75px;
                color: white;
                text-shadow: 3px 3px 6px rgba(255, 255, 255, 0.38);
            }
}

@keyframes blink {
            0% {
                opacity: 1;
            }

            50% {
                opacity: 0;
            }

            100% {
                opacity: 1;
            }
}
/*---------------------------------------------------*/


/*-----------------------LOGIN-----------------------*/

.login-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  border-radius: 16px;
  padding: 1rem;
  width: 100%;
  max-width: 890px;
}

.container-img-palmares {
  width: 100%;
  max-width: 100vw;
  height: 220px; /* Ajustá este valor según lo que necesites */
  overflow: hidden; /* Oculta el contenido que se salga */
  margin-bottom: 5.0rem;
}

.img_logo {
width: 100%;
height: 100%;
display: block;
}

.container-img-digital{
width: 40%;
max-width: 100vw;
height: 150px; /* Ajustá este valor según lo que necesites */
overflow: hidden; /* Oculta el contenido que se salga */
}

.img_serv {
width: 100%;
height: 100%;
object-fit: cover; /* Hace que la imagen se recorte si es necesario y cubra todo el contenedor */
display: block;
}

.login {
  width: 100%;
  box-sizing: border-box;
}

.login__field {
  position: relative;
  margin-bottom: 2.5rem;
  box-sizing: border-box;
}

.login__icon {
  position: absolute;
  top: 50%;
  left: 10px;
  transform: translateY(-50%);
  color: #fff;
  font-size: 0.9rem;
}

.login__input {
  width: 100%;
  padding: 10px 10px 10px 35px;
  border: 1px solid #444;
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  border-radius: 10px;
  outline: none;
  font-size: 1.0rem;
  box-sizing: border-box;
}

.login__submit {
  background-color: #fff;
  color: #000;
  font-weight: 600;
  border: none;
  padding: 10px;
  border-radius: 10px;
  width: 100%;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.button__icon {
  margin-left: 8px;
  font-size: 1rem;
}

.alert {
  text-align: center;
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
}

::placeholder {
  color: #ccc;
}

.toggle-password{
  position: absolute; 
  right: 12px; 
  top: 50%; 
  transform: translateY(-50%); 
  cursor: pointer;
  color: #fff;
}

@media (max-width: 768px) {
  .login-container {
    padding: 1rem;
    max-width: 90%;
  }

  .login__input {
    font-size: 0.85rem;
    padding-left: 32px;
  }

  .login__submit {
    font-size: 13px;
  }

  .container-img-palmares {
    width: 100%;
    max-width: 100vw;
    height: 150px; /* Ajustá este valor según lo que necesites */
    overflow: hidden; /* Oculta el contenido que se salga */
  }

  .img_logo {
    width: 100%;
    height: 65%;
    object-fit: cover; 
    display: block;
  }

  .container-img-digital{
    width: 100%;
    max-width: 50vw;
    height: 100px; /* Ajustá este valor según lo que necesites */
    overflow: hidden; /* Oculta el contenido que se salga */
  }

  .img_serv {
    width: 100%;
    height: 65%;
    object-fit: cover; 
    display: block;
  }

}

/*----------------------------------------------*/

/*-------------FILTRADO DE TABLAS-------------------*/
.dataTables_wrapper {
  color: rgb(131, 131, 131);
}

.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select {
  color: white;
  background-color: #333; 
  border: 1px solid #555;
}

.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_paginate {
  color: white;
}

/*---------------------------------------------------*/
/*---------------------------EVENTOS WEB--------------------------*/
#events-container {
  max-width: 1200px;
  margin: 0 auto;
  background: white;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.08);
  overflow: hidden;
}
.header_evento {
  background: #2c3e50;
  color: white;
  padding: 15px 20px;
  font-size: 1.2em;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
#status {
  padding: 10px 15px;
  border-radius: 20px;
  font-size: 0.9em;
  font-weight: bold;
}
.connected { background: #28a745; color: white; }
.disconnected { background: #dc3545; color: white; }
.error { background: #ffc107; color: #343a40; }
.connecting { background: #17a2b8; color: white; }

#events {
  max-height: 70vh;
  overflow-y: auto;
  padding: 0;
}

.event {
  padding: 15px 20px;
  border-bottom: 1px solid #e9ecef;
  transition: all 0.2s ease;
  display: flex; /* Cambiado a flex para alinear icono y contenido */
  align-items: flex-start;
  gap: 15px; /* Espacio entre icono y contenido */
}
.event:hover {
  background-color: #f8f9fa;
}
.event-icon {
  font-size: 1.5em;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  flex-shrink: 0;
}
.event-content {
  flex-grow: 1;
}
.event-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
  align-items: center;
}
.event-type {
  font-weight: 600;
  color: #2c3e50;
  font-size: 1.1em;
}
.event-time {
  color: #6c757d;
  font-size: 1.1em;
  font-weight: 600;
}
.event-details {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 10px;
  margin-top: 10px;
}
.detail-item {
  margin-bottom: 5px;
}
.detail-label {
  font-weight: 600;
  color: #495057;
  font-size: 0.85em;
  display: block;
}
.detail-value {
  color: #212529;
  font-size: 0.95em;
  padding: 5px 0;
}
.event-action {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 0.75em;
  font-weight: bold;
  text-transform: uppercase;
  margin-left: 8px;
}

/* Colores para diferentes tipos de eventos */
.icon-security { color: #dc3545; background-color: #f8d7da; }
.icon-alert { color: #ffc107; background-color: #fff3cd; }
.icon-info { color: #17a2b8; background-color: #d1ecf1; }
.icon-success { color: #28a745; background-color: #d4edda; }
.icon-warning { color: #fd7e14; background-color: #ffe5d0; }

/* Scrollbar styling */
#events::-webkit-scrollbar {
  width: 8px;
}
#events::-webkit-scrollbar-track {
  background: #f1f1f1;
}
#events::-webkit-scrollbar-thumb {
  background: #adb5bd;
  border-radius: 4px;
}
#events::-webkit-scrollbar-thumb:hover {
  background: #6c757d;
}

.no-events {
  text-align: center;
  padding: 30px;
  color: #6c757d;
  font-style: italic;
}
