* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* === STYLES ABM === */

/* Variables (heredadas de styles.css si querés) */
:root {
  --primary-color: #c4d526;
  --primary-btn-color: #1d48bd;
  --primary-btn-color-hover: #122a6b;
  --light-bg: #f8f9fa;
  --dark-bg: #2c2c2c;
  --text-dark: #333;
  --text-light: #666;
}

/* General ABM */
body.abm-page {
  background: var(--light-bg);
  font-family: "Arial", sans-serif;
  color: var(--text-dark);
  line-height: 1.6;
}

/* HEADER ABM */

header {
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  align-items: center;
  margin-top: 3vh
}

.header-abm {
  width: 50vw;
  background: var(--light-bg);
  border-bottom: 2px solid var(--primary-color);
  padding: 1rem 0;
  margin: 6rem 0 2rem 0;
}

.header-abm h1 {
  font-size: 1.8rem;
  font-weight: bold;
  margin: 0;
}

.header-abm .btn-cerrar {
  background: #dc3545;
  color: white;
  font-weight: 600;
  font-size: 0.9rem;
}

/* MAIN ABM */

.abm-table-container {
  width: 90%;      /* Ocupa casi toda la pantalla */
  margin: 0 auto;  /* Centrada horizontalmente */
  overflow-x: auto; /* Si aún queda muy ancha, agrega scroll horizontal */
}
.abm-table-container table th,
.abm-table-container table td {
  white-space: nowrap;      /* Evita que se quiebre la palabra */
  max-width: 200px;         /* Limita ancho máximo de columnas */
  text-overflow: ellipsis;  /* Muestra ... si el contenido es muy largo */
  overflow: hidden;
}

.main-abm {
  width: 80%;
  margin: 0 auto;
  padding: 1rem;
}

/* Secciones ABM */
.abm-section {
  margin-bottom: 3rem;
}

.abm-section h2 {
  font-size: 1.4rem;
  margin-bottom: 1rem;
  color: var(--primary-color);
}

/* Botones ABM */
.btn-abm {
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.4rem 1rem;
  border-radius: 4px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  transition: all 0.2s ease;
}

.btn-abm-add {
  background: var(--primary-btn-color);
  color: #fff;
}

.btn-abm-add:hover {
  background: var(--primary-btn-color-hover);
  color: #fff;
}

.btn-abm-edit {
  background: #ffc107;
  color: #000;
}

.btn-abm-edit:hover {
  background: #e0a800;
}

.btn-abm-delete {
  background: #dc3545;
  color: #fff;
}

.btn-abm-delete:hover {
  background: #b02a37;
}

/* Tabla ABM */
.table-abm {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1rem;
}

.table-abm th,
.table-abm td {
  padding: 0.5rem 0.7rem;
  text-align: center;
  border: 1px solid #dee2e6;
  vertical-align: middle;
}

.table-abm th {
  background: var(--text-dark);
  color: #fff;
  font-weight: 600;
}

.table-abm tbody tr:nth-child(even) {
  background: #f2f2f2;
}

.table-abm img.abm-logo {
  max-width: 80px;
  max-height: 50px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
}

/* Formulario ABM */
.form-abm {
  background: #fff;
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
  margin-top: 1rem;
}

.form-abm label {
  font-weight: 600;
  margin-bottom: 0.3rem;
  display: block;
}

.form-abm input,
.form-abm select,
.form-abm textarea {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid #ced4da;
  border-radius: 4px;
  margin-bottom: 1rem;
  font-size: 0.95rem;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.form-abm input:focus,
.form-abm select:focus,
.form-abm textarea:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(196, 213, 38, 0.25);
  outline: none;
}

.table-abm td.col-descargar {
    max-width: 250px;        /* ancho máximo fijo */
    white-space: nowrap;     /* no hace salto de línea */
    overflow: hidden;        /* oculta el sobrante */
    text-overflow: ellipsis; /* agrega los "..." */
}


/* Responsivo ABM */
@media (max-width: 768px) {
  .header-abm h1 {
    font-size: 1.4rem;
  }

  .btn-abm {
    font-size: 0.8rem;
    padding: 0.3rem 0.6rem;
  }

  .table-abm th,
  .table-abm td {
    padding: 0.3rem 0.5rem;
  }

  .table-abm img.abm-logo {
    max-width: 60px;
    max-height: 40px;
  }

  .form-abm {
    padding: 1rem;
  }
}

.acciones-main {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

#menuAcciones {
    display: flex;
    flex-direction: column;
    gap: 0.5em;
}

.menu-item {
    text-indent: 2em;
    margin: 0;
}

#navegacion_acciones, #cerrarSesion {
    margin-bottom: 1em;
}
