/* Estilos generales */
body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f9;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
    background-image: url('../images/fondo.jpg'); /* Ruta de la imagen */
    background-size: cover; /* Ajusta la imagen para cubrir todo el fondo */
    background-repeat: no-repeat; /* Evita que la imagen se repita */
    background-position: center; /* Centra la imagen */
}

/* Capa semitransparente sobre el fondo */
body::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.7); /* Capa blanca con 50% de opacidad */
    z-index: -1; /* Ubicar detrás de los elementos */
}

.container {
    background-color: #ffffff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    text-align: center;
    width: 100%;
    max-width: 400px; /* Controla el tamaño en pantallas más grandes */
}

h1 {
    color: #333;
    margin-bottom: 20px;
    font-size: 24px;
}

form {
    display: flex;
    flex-direction: column;
}

label {
    text-align: left;
    color: #555;
    margin-bottom: 5px;
    font-weight: bold;
}

input {
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 16px;
}

button {
    background-color: #4CAF50;
    color: white;
    padding: 10px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
}

button:hover {
    background-color: #45a049;
}

.error {
    color: red;
    margin-top: 10px;
    font-size: 14px;
}

/* Diseño responsive */
@media (max-width: 768px) {
    .container {
        width: 90%; /* Reduce el ancho en tablets */
        padding: 15px;
    }

    h1 {
        font-size: 20px;
    }

    button {
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .container {
        width: 95%; /* Más compacto en móviles */
        padding: 10px;
    }

    h1 {
        font-size: 18px;
    }

    label, input, button {
        font-size: 14px;
        padding: 8px;
    }
}