/* =====================================
   1. Importar tipograf�a (con soporte acentos)
   ===================================== */
@import url('https://fonts.googleapis.com/css?family=Roboto:400,500,700&display=swap');

/* =====================================
   2. Reset b�sico
   ===================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* =====================================
   3. Estilos base
   ===================================== */
   body {
    font-family: 'Roboto', sans-serif;
    background-color: #1a1a1d; /* Dark background */
    color: #ffffff; /* Light text */
    margin: 0;
    padding: 0;
    height: 100vh; /* Full viewport height */
    display: flex;
    justify-content: center;
    align-items: center;
  }

  .container {
    margin: 0;
    padding: 30px;
    background-color: #2c2c32; /* Slightly lighter dark container */
    border-radius: 15px; /* More rounded corners */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5); /* Stronger shadow */
    width: 100%; /* Full width */
    max-width: none; /* Remove max-width */
    box-sizing: border-box;
    max-height: 100vh; /* Altura máxima del viewport */
    overflow-y: auto; /* Permitir desplazamiento vertical */
  }

/* Ttulos, prrafos, enlaces */
h1 {
  font-size: 2.5rem;
  margin-bottom: 25px;
  color: #f5f5f5;
  text-align: center;
}
h2 {
  font-size: 1.4rem;
  margin: 15px 0;
  color: #ddd; /* Slightly muted for better readability */
}

h3 {
    font-size: 1.2rem;
    margin: 10px 0;
    color: #bbb; /*Muted*/
}

p {
  margin-bottom: 10px;
    color:#bbb;
}

/* Input */
#searchInput {
    width: 100%;
    padding: 10px;
    margin-bottom: 20px;
    border: none;
    border-radius: 8px;
    background-color: #3a3a40;
    color: #ffffff;
    font-size: 1rem;
}

a {
  color: #3498db;
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
a[href="/logout"] {
  display: inline-block;
  background: #e74c3c;
  color: #fff !important;
  padding: 10px 20px; /* Larger button */
  margin-bottom: 10px;
  border-radius: 8px; /* More rounded */
  font-weight: 500;
  text-decoration: none;
  transition: background 0.2s;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); /* Subtle shadow */
}
a[href="/logout"]:hover {
  background: #c0392b;
}

/* Formulario (login) */
form {
  max-width: 400px;
  margin: 20px auto;
  padding: 15px;
  background: #ffffff;
  border: 1px solid #ddd;
  border-radius: 6px;
}
form label {
  display: block;
  margin: 10px 0 5px;
  font-weight: 500;
  color: #1a1a1d; /* Dark text for labels */
}
form input[type="text"],
form input[type="password"] {
  width: 100%;
  padding: 10px;
  font-size: 1rem;
  margin-bottom: 15px;
  border: 1px solid #ccc;
  border-radius: 4px;
}
form button {
  width: 100%;
  background: #3498db;
  color: #fff;
  font-weight: 600;
  text-transform: uppercase;
  border: none;
  border-radius: 4px;
  padding: 10px;
  cursor: pointer;
}
form button:hover {
  background: #2980b9;
}

/* Botones (PLAY, PAUSE, etc.) */
button {
  background-color: #007bff; /* Modern blue */
  color: #fff;
  border: none;
  padding: 12px 24px; /* Larger buttons */
  margin: 8px;
  border-radius: 8px; /* More rounded */
  cursor: pointer;
  font-weight: 600;
  transition: background-color 0.3s ease, transform 0.2s ease; /* Smooth transitions */
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2); /* Subtle shadow */
}

button:hover {
  background-color: #0056b3; /* Darker blue on hover */
  transform: translateY(-2px); /* Slight lift effect */
}

button:active {
  background-color: #003d80; /* Even darker on click */
  transform: translateY(0); /* Reset transform */
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2); /* Smaller shadow on click */
}

/* Tablas */
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
  background-color: #3a3a40; /* Darker table background */
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5); /* Stronger shadow */
  border-radius: 10px; /* Rounded corners */
  overflow: hidden; /* Ensure rounded corners are visible */
}

/* Mantener el encabezado de la tabla visible durante el desplazamiento */
thead {
  position: sticky;
  top: 0;
  background-color: #2c2c32;
  z-index: 10;
}

th, td {
  border: 1px solid #4a4a4f; /* Slightly lighter border */
  padding: 15px; /* More padding */
  text-align: left;
  color: #eee;
}
th {
  background: #2c2c32;
  font-weight: 600;
    color: #fff;
}
tr:nth-child(even) {
  background: #333339; /* Slightly different even row color */
}

tr:hover {
    background-color: #414149;
}

/* Cronmetro (si se utiliza) */
#apneaTimer {
  color: #e74c3c;
  font-weight: bold;
  font-size: 1.2rem;
}

/* History container */
#historyContainer {
    margin-top: 30px;
    padding: 20px;
    background-color: #2c2c32;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
}

#historyContainer h2 {
    color: #f5f5f5;
    margin-bottom: 15px;
    text-align: center;
}
