body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: #f4f6f9;
  margin: 0;
  padding: 0;
  color: #333;
}

#contenido_exportable {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* ENCABEZADO */
.header {
  background-color: #f4f6f9;
  padding: 15px 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

.logo-group {
  display: flex;
  gap: 25px;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
}

.logo-ajuste {
  max-height: 55px;
  max-width: 140px;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.logo-group img:hover {
  transform: scale(1.05);
}

/* CONTENIDO PRINCIPAL */
.container {
  flex: 1;
  width: 90%;
  max-width: 1200px;
  margin: 40px auto;
  background: white;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.08);
  position: relative;
  z-index: 1;
}

.title {
  text-align: center;
  margin-bottom: 20px;
  font-size: 1.8em;
  color: #2c3e50;
}

/* FORMULARIO */
.form-reporte {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.form-group {
  display: flex;
  flex-direction: column;
}

label {
  font-weight: 600;
  margin-bottom: 5px;
}

input[type="date"],
input[type="text"] {
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 1em;
}

.btn-submit {
  padding: 10px 20px;
  background-color: #007bff;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 1em;
  cursor: pointer;
  transition: background-color 0.3s ease;
  width: fit-content;
  align-self: flex-start;
}

.btn-submit:hover {
  background-color: #0056b3;
}

/* RESULTADO EMBEBIDO */
.resultado {
  max-height: none !important;
  overflow: visible !important;
  page-break-inside: auto;
  margin-top: 30px;
}

/* TABLA */
.tabla-responsive {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
  font-size: 0.95em;
  table-layout: auto;
}

.tabla-responsive th,
.tabla-responsive td {
  border: 1px solid #ccc;
  padding: 8px;
  text-align: center;
}

.tabla-responsive th {
  background-color: #eeeeee;
  font-weight: bold;
}

.tabla-responsive tr:nth-child(even) {
  background-color: #f9f9f9;
}

.totales td {
  background-color: #e0f7fa;
  font-weight: bold;
}

/* MARCA DE AGUA */
.background-logo {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 300px;
  height: 300px;
  background-image: url('img/movsbck.png');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  opacity: 0.05;
  z-index: 50;
  pointer-events: none;
}

/* FOOTER */
footer {
  background-color: #1a1a1a;
  color: #fff;
  text-align: center;
  padding: 20px 10px;
  font-size: 0.85em;
  line-height: 1.4;
}

/* RESPONSIVE */
@media (max-width: 600px) {
  .container {
    margin: 20px;
    padding: 20px;
  }

  .logo-ajuste {
    max-height: 45px;
    max-width: 100px;
  }

  .title {
    font-size: 1.5em;
  }

  footer {
    font-size: 0.75em;
  }
}

/* IMPRESIÓN Y EXPORTACIÓN A PDF */
@media print {
  .background-logo {
    opacity: 0.08;
  }

  body {
    transform: scale(0.95);
    transform-origin: top center;
    font-size: 11px;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .header, footer {
    position: fixed;
    left: 0;
    right: 0;
    background-color: #f4f6f9 !important;
    color: #000;
    z-index: 999;
  }

  .header {
    top: 0;
    padding: 10px 0;
    border-bottom: 1px solid #ccc;
  }

  footer {
    bottom: 0;
    padding: 10px 0;
    font-size: 10px;
    border-top: 1px solid #ccc;
  }

  .container {
    margin-top: 140px;
    margin-bottom: 100px;
  }

  .btn-submit,
  #btnExportarPDF {
    display: none !important;
  }

  .resultado {
    page-break-inside: avoid;
  }
}
