
/* ===========================
   RESET & BASE
=========================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;               /* Para centrar el login */
  font-family: 'Inter', sans-serif;
  background: #F4F6F9;
}

/* Variables de color */
:root {
  --primary: #1F3A5F;         /* Azul oscuro */
  --secondary: #1a3150;       /* Dorado corporativo */
  --light: #F4F6F9;
  --text-dark: #2B2B2B;
  --gray: #C8C8C8;
}

/* ===========================
   LOADER
=========================== */
.loader-screen {
  position: fixed;
  inset: 0;
  background: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  z-index: 9999;
}

.loader-circle {
  width: 70px;
  height: 70px;
  border: 6px solid rgba(255, 255, 255, 0.3);
  border-top: 6px solid var(--secondary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 15px;
}

.loader-text {
  color: white;
  font-size: 18px;
  font-weight: 500;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ===========================
   LOGIN
=========================== */
.login-container {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--primary), #162B45);
  padding: 20px;
}

.login-box {
  background: white;
  width: 340px;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.2);
  text-align: center;
}

.login-logo {
  width: 90px;
  margin-bottom: 15px;
}

.login-box h2 {
  margin-bottom: 20px;
  font-weight: 600;
  color: var(--primary);
}

.input-group {
  text-align: left;
  margin-bottom: 18px;
}

.input-group label {
  display: block;
  font-size: 14px;
  margin-bottom: 6px;
  color: var(--text-dark);
}

.input-group input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--gray);
  border-radius: 8px;
  font-size: 14px;
  transition: 0.3s;
}

.input-group input:focus {
  border-color: var(--secondary);
  outline: none;
}

.login-btn {
  width: 100%;
  padding: 12px;
  background: var(--secondary);
  border: none;
  color: white;
  font-size: 15px;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: 0.3s;
}

.login-btn:hover {
  background: #1a3150;
}

.login-footer {
  margin-top: 15px;
  font-size: 12px;
  color: var(--gray);
}

/* ===========================
   HEADER
=========================== */
.header {
  background: var(--primary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 30px;
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-container img {
  height: 35px;
}

.logo {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.nav a {
  color: white;
  text-decoration: none;
  margin: 0 15px;
  font-weight: 500;
  transition: 0.3s;
}

.nav a:hover,
.nav a.active {
  color: var(--secondary);
}

.user-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.user-avatar {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  border: 2px solid var(--secondary);
}

/* ===========================
   SIDEBAR
=========================== */
.sidebar {
  width: 220px;
  height: calc(100vh - 60px);
  background: #162B45;
  color: white;
  position: fixed;
  top: 60px;
  left: 0;
  padding-top: 20px;
  box-shadow: 4px 0 10px rgba(0,0,0,0.15);
}

.sidebar ul {
  list-style: none;
}

.sidebar ul li {
  padding: 15px 25px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  transition: 0.3s;
  font-size: 15px;
}

.sidebar ul li:hover {
  background: var(--primary);
  padding-left: 30px;
}

.sidebar ul li.active {
  background: var(--secondary);
  color: #ffffff;
  font-weight: 600;
}

/* ===========================
   MAIN CONTENT
=========================== */
.main-content {
  margin-left: 220px;
  padding: 30px;
}

.main-content h1 {
  margin-bottom: 25px;
  color: var(--primary);
  font-size: 26px;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 25px;
}

.card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
  transform: scale(1.03);                /* Zoom suave */
  box-shadow: 0 8px 18px rgba(0,0,0,0.2); /* Sombra al hover */
}

.card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.card-body {
  padding: 15px;
}

.card-body h2 {
  font-size: 18px;
  color: var(--primary);
  margin-bottom: 8px;
}

.card-body p {
  font-size: 14px;
  margin-bottom: 12px;
  color: #555;
}

.card-body button {
  background: var(--secondary);
  border: none;
  padding: 8px 15px;
  border-radius: 8px;
  color: white;
  font-size: 14px;
  cursor: pointer;
  transition: 0.3s;
}

.card-body button:hover {
  background: #1a3150;
}

/* ===========================
   FOOTER
=========================== */
.footer {
  text-align: center;
  padding: 12px;
  background: #EAEAEA;
  color: #777;
  font-size: 13px;
  margin-top: 40px;
  
}/* ===========================
   LOGIN BODY
=========================== */

/* Fondo general del login */
body.login-page {
  background: linear-gradient(135deg, var(--primary), #162B45); /* igual que el fondo principal */
  height: 100vh;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}


/* Logo fuera del cuadro */
.logo-outside {
  text-align: center;
  margin-bottom: 15px;
  color: white;
}

.logo-outside img {
  width: 100px;
  height: 100px;
  margin-bottom: 5px;
}

.logo-outside h1 {
  font-size: 24px;
  margin: 0;
  font-weight: 600;
}

/* Contenedor principal */
.login-container {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 10px;
}

/* Caja del login */
.login-box {
  background: white;
  width: 340px;
  padding: 30px 25px;
  border-radius: 14px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.25);
  text-align: center;
  animation: fadeIn 0.6s ease-in-out;
}

.login-box h2 {
  margin-bottom: 20px;
  font-weight: 600;
  color: #1F3A5F;
}

/* Campos */
.input-group {
  text-align: left;
  margin-bottom: 18px;
}

.input-group label {
  display: block;
  font-size: 14px;
  margin-bottom: 5px;
  color: #333;
}

.input-group input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 14px;
  transition: border 0.3s;
}

.input-group input:focus {
  border-color: #162B45; /* Verde esmeralda */
  outline: none;
}

/* Botón */
.login-btn {
  width: 100%;
  padding: 12px;
  background: #162B45; /* Verde esmeralda */
  border: none;
  color: white;
  font-size: 15px;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: 0.3s;
}

.login-btn:hover {
  background: #162B45; /* Verde más oscuro */
}

/* Footer */
.login-footer {
  margin-top: 15px;
  font-size: 12px;
  color: #666;
}

.companies-logos {
  margin-top: 12px;
  display: flex;
  justify-content: center;
  gap: 12px;
}

.companies-logos img {
  height: 28px;
  object-fit: contain;
  opacity: 0.8;
  transition: transform 0.3s, opacity 0.3s;
}

.companies-logos img:hover {
  opacity: 1;
  transform: scale(1.05);
}

/* Animación */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* 🔹 Logo dentro del login */
.logo-container {
  text-align: center;
  margin-bottom: 20px;
}

.logo-img {
  width: 1000px;
  height: 500px;
  margin-bottom: 5px;
  object-fit: contain;
}

.logo-title {
  font-size: 24px;
  font-weight: 600;
  color: #162B45;       /* Mantiene el color del login */
  margin: 0;
}
.logo-title {
  color: #162B45;
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
}
.sidebar ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  cursor: pointer;
  transition: background 0.3s;
}

.sidebar li:hover {
  background: rgba(255, 255, 255, 0.1);
}

.sidebar li.active {
  background: rgba(255, 255, 255, 0.2);
}

.icon-sidebar {
  width: 22px;
  height: 22px;
  object-fit: contain;
}



/* ===========================
   ocultar
=========================== */
/* Sidebar oculto por defecto */
.sidebar {
  position: fixed;
  top: 0;
  left: -260px; /* Oculto a la izquierda */
  width: 260px;
  height: 100%;
  background: rgba(0, 36, 61, 0.95);
  backdrop-filter: blur(8px);
  color: #fff;
  padding-top: 60px;
  transition: left 0.3s ease;
  z-index: 1000;
}

/* Sidebar visible */
.sidebar.active {
  left: 0;
}

/* Botón cerrar dentro del sidebar */
.close-btn {
  position: absolute;
  top: 15px;
  right: 15px;
  background: none;
  border: none;
  font-size: 28px;
  color: #fff;
  cursor: pointer;
}

/* Estilo de los items */
.sidebar ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sidebar li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 20px;
  cursor: pointer;
  transition: background 0.3s;
}

.sidebar li:hover {
  background: rgba(255, 255, 255, 0.1);
}

.sidebar li.active {
  background: rgba(255, 255, 255, 0.2);
}

.icon-sidebar {
  width: 22px;
  height: 22px;
  object-fit: contain;
}

/* Botón menú del header */
.menu-btn img {
  width: 28px;
  height: 28px;
}


/* === Overlay del sidebar === */
#sidebar-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4); /* oscurece el fondo */
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  z-index: 998; /* debajo del sidebar */
}

#sidebar-overlay.active {
  opacity: 1;
  pointer-events: all;
}

/* Ajustar el z-index del sidebar para que esté sobre el overlay */
.sidebar {
  z-index: 999;
}


/* ===========================
   slider para inicio
=========================== */
/* Sidebar por defecto oculto */
.sidebar {
  position: fixed;
  top: 60px;
  left: -250px;
  width: 250px;
  height: calc(100% - 60px);
  background: #162B45;
  transition: left 0.3s ease;
  z-index: 1000;
}

/* Sidebar visible */
.sidebar.active {
  left: 0;
}

/* Overlay */
#sidebar-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
  z-index: 999;
}

#sidebar-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* ===========================
   🌐 RESPONSIVE DESIGN
=========================== */

/* === Tablets (pantallas medianas) === */
@media (max-width: 992px) {
  .header {
    flex-direction: column;
    align-items: flex-start;
    padding: 15px;
    height: auto;
  }

  .logo {
    font-size: 20px;
    margin-bottom: 8px;
  }

  .user-info {
    width: 100%;
    justify-content: space-between;
  }

  .sidebar {
    width: 220px;
    left: -220px;
  }

  .sidebar.active {
    left: 0;
  }

  .main-content {
    margin-left: 0;
    padding: 20px;
  }

  .card-grid {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  }
}

/* === Celulares grandes === */
@media (max-width: 768px) {
  /* Header */
  .header {
    flex-direction: row;
    justify-content: space-between;
    height: 60px;
    padding: 10px 15px;
  }

  .logo {
    font-size: 18px;
  }

  .user-info {
    gap: 6px;
  }

  .user-avatar {
    width: 28px;
    height: 28px;
  }

  /* Sidebar oculto y deslizable */
  .sidebar {
    width: 200px;
    height: 100vh;
    left: -200px;
    top: 0;
    padding-top: 70px;
  }

  .sidebar.active {
    left: 0;
  }

  #sidebar-overlay.active {
    opacity: 1;
    visibility: visible;
  }

  /* Contenido principal */
  .main-content {
    margin-left: 0;
    padding: 15px;
  }

  .card-grid {
    grid-template-columns: 1fr;
  }

  .card img {
    height: 160px;
  }

  /* Botones */
  .login-btn, .card-body button {
    padding: 10px;
    font-size: 14px;
  }
}

/* === Celulares pequeños (menos de 480px) === */
@media (max-width: 480px) {
  /* Login */
  .login-box {
    width: 95%;
    padding: 20px 15px;
  }

  .login-box h2 {
    font-size: 18px;
  }

  .input-group label {
    font-size: 13px;
  }

  .input-group input {
    font-size: 13px;
    padding: 8px 10px;
  }

  .login-btn {
    font-size: 14px;
    padding: 10px;
  }

  /* Sidebar */
  .sidebar {
    width: 180px;
  }

  .sidebar ul li {
    padding: 10px 15px;
    font-size: 14px;
  }

  /* Header */
  .header {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }

  .logo {
    font-size: 16px;
  }

  /* Cards */
  .card-body h2 {
    font-size: 16px;
  }

  .card-body p {
    font-size: 13px;
  }

  /* Footer */
  .footer {
    font-size: 12px;
    padding: 10px;
  }

  /* Overlay */
  #sidebar-overlay {
    background: rgba(0, 0, 0, 0.5);
  }
}
/* prueba de push*/ 
/* prueba de push*/