/* Estilos básicos */
* {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    display: flex;
    justify-content: center;
    align-items: flex-start; /* Cambiado para que el contenido empiece arriba */
    height: 100vh;
    background: #f4f4f4;
    background-image: url('../Imagen/4889282.jpg');
    background-size: cover;
    background-position: top center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    min-height: 100vh;
    margin: 0;
    padding: 0;
}

.container {
    background: white;
    padding: 40px 30px;
    margin: auto;
    border-radius: 20px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    text-align: center;
    width: 100%;
    max-width: 600px; /* un poco más ancho */
    max-height: 80vh; /* limita la altura para scroll interno */
    overflow-y: auto; /* permite scroll dentro del contenedor si hay mucho contenido */
}

/* Resto de estilos igual */

.logo {
    display: block;
    margin: 0 auto 20px auto;
    width: 550px;
    max-width: 100%;
    height: auto;
}

h2 {
    margin-top: 20px;
    margin-bottom: 20px;
    color: #333;
    font-weight: 500;
    text-align: center;
}

/* --- Entrada usuario --- */
input[type="text"] {
    width: 70%;
    margin: 10px auto;
    display: block;
    padding: 11px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 16px;
    box-sizing: border-box;
}

/* --- Contenedor y input contraseña con ojo --- */
.input-password-container {
    position: relative;
    width: 70%;
    margin: 10px auto;
}

#contrasena {
    width: 100%;
    padding-right: 40px;
    box-sizing: border-box;
    padding: 11px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 16px;
}

/* Icono para mostrar/ocultar contraseña */
.toggle-password {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    font-size: 18px;
    user-select: none;
    color: #666;
}

.toggle-password:hover {
    color: #333;
}

button {
    width: 30%;
    padding: 12px;
    margin-top: 10px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    color: white;
    font-size: 16px;
    font-weight: 600;
    transition: background-color 0.3s;
}

.btn-login,
.btn-menu {
    background-color: rgb(93, 128, 54);
}

.btn-login:hover,
.btn-menu:hover {
    background-color: rgb(75, 105, 40);
}

.btn-logout {
    background-color: rgb(76, 84, 84);
}

.btn-save {
    background-color: rgb(43, 53, 70);
}

.btn-back {
    background-color: rgb(140, 148, 164);
}

/* Eliminar selector global hover para evitar conflicto con .btn-menu */
.btn-menu:hover {
    opacity: 0.8;
}

.menu-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px 40px;
    margin-top: 30px;
    max-width: 680px;
    margin-left: auto;
    margin-right: auto;
}

.btn-menu {
    flex: 1 1 45%;
    max-width: 300px;
    min-width: 150px;
    padding: 12px;
    font-size: 16px;
    font-weight: 600;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    background-color: rgb(93, 128, 54);
    transition: background-color 0.3s;
}

.btn-menu:hover {
    background-color: rgb(75, 105, 40);
}

html, body {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow-y: auto; /* ✅ permite scroll vertical general */
}

.titulo-sistema {
    text-align: center;
    font-size: 28px;
    font-weight: bold;
    color: #1a1a1a;
    margin-bottom: 15px;
}