body {
  background-color: #048fd4;
  color: #333;
  height: 100vh; /* asegura que el body ocupe toda la altura de la pantalla */
  margin: 0; /* elimina márgenes predeterminados */
  font-family: Arial, sans-serif;
}

body.silueta {
  background-image: url('img/fondoAraucarias.png');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  background-repeat: no-repeat;
}

body.dashboard-bg::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('img/fondoAraucarias.png');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  background-repeat: no-repeat;
  filter: blur(2px);
  opacity: 0.6;
  z-index: -1;
}

.login-container {
  height: 100vh;
  display: flex;
  align-items: center;    /* centra verticalmente */
  justify-content: center; /* centra horizontalmente */
  padding: 1rem; /* padding para móviles */
}

.login-card {
  max-width: 700px; /* ancho más amplio */
  width: 100%;
  padding: 2rem; /* espacio interno */
  margin: 0 auto; /* centrar horizontalmente */
}

.card {
  border-radius: 15px;
  border: none;
}

.btn-primary {
  background-color: #005A8C;
  border: none;
  min-height: 44px; /* Touch target minimum */
  padding: 0.75rem 1.5rem; /* Consistent padding */
}

.btn-primary:hover {
  background-color: #004080;
}

/* Button groups and flex layouts */
.btn-group {
  gap: 0.5rem;
}

.btn-group-vertical {
  gap: 0.5rem;
}

/* Mobile button optimizations */
@media (max-width: 768px) {
  .btn {
    min-height: 44px; /* Ensure touch targets */
    font-size: 1rem; /* Prevent zoom on iOS */
    padding: 0.75rem 1rem;
  }

  .btn-sm {
    min-height: 40px;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
  }

  /* Convert horizontal button groups to vertical on mobile */
  .btn-group {
    flex-direction: column;
    width: 100%;
  }

  .btn-group .btn {
    width: 100%;
  }

  /* Modal buttons */
  .modal-footer .btn {
    flex: 1;
    margin: 0.25rem;
  }
}

.alert {
  font-size: 0.9rem;
}

/* Media queries para responsividad */
@media (max-width: 768px) {
  .login-container {
    padding: 0.5rem;
  }

  .login-card {
    padding: 1rem;
    margin: 0 0.5rem;
  }

  .alert {
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .login-card {
    padding: 0.75rem;
  }
}

.timer-box {
    font-size: 1.2rem;
    font-weight: bold;
    padding: 10px 15px;
    border-radius: 8px;
    border: 2px solid #ccc;
    width: fit-content;
    margin-bottom: 15px;
    background-color: #f5f5f5;
}

.timer-green {
    color: green;
}

.timer-yellow {
    color: #c9a200;
}

.timer-red {
    color: red;
}

.resultado-box {
    padding: 20px;
    margin: 20px auto;
    max-width: 600px;
    background: #ffffff;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.nota-final {
    font-size: 2rem;
    font-weight: bold;
    color: #005A8C;
    margin-bottom: 20px;
}

.criterio-item {
    padding: 10px;
    border-bottom: 1px solid #dddddd;
}

.criterio-item:last-child {
    border-bottom: none;
}

.criterio-nombre {
    font-weight: bold;
}

@media (max-width: 500px) {
    .resultado-box {
        padding: 15px;
        margin: 10px;
    }
    .nota-final {
        font-size: 1.6rem;
    }
}

.ponderacion-final {
    margin-bottom: 20px;
    font-size: 1rem;
    color: #333;
}

h2 {
  margin-bottom: 15px;
}

@media (max-width: 400px) {
    .resultado-box {
        padding: 12px;
        border-radius: 8px;
        font-size: 0.9rem;
    }
    .nota-final {
        font-size: 1.4rem;
    }
    .criterio-item {
        padding: 8px;
    }
}

.hidden {
    display: none;
}

/* Responsive table improvements */
@media (max-width: 768px) {
    .table-responsive {
        border: none;
    }

    .table-responsive table {
        font-size: 0.875rem;
    }

    .table-responsive th,
    .table-responsive td {
        white-space: nowrap;
        padding: 0.5rem;
    }

    /* Allow horizontal scroll for tables */
    .table-responsive {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}
