.conteinercontac {
    position: relative;
    height: 46rem;
}

.imgcontac {
    position: relative;
    z-index: 1;
    height: 46rem;
    margin-top: -16px;
}

.imgcontac::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../cateycurs/img/IMG_Contacto2_fond.jpg') no-repeat center center;
    background-size: cover;
    opacity: 0.5; /* Ajusta este valor según la opacidad deseada */
    z-index: -1; /* Asegúrate de que esté detrás del contenido de .imgcontac */
}

.totalconteiner {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

form {
    max-width: 600px;
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(5, 95, 231, 0.358);
    z-index: 2;
}

.horizontal-group {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
}

.horizontal-item {
    flex: 1;
    margin-right: 10px;
}

.horizontal-item:last-child {
    margin-right: 0;
}

label {
    font-weight: bold;
    margin-bottom: 5px;
    display: block;
}

input[type="text"],
textarea {
    width: calc(100% - 10px);
    padding: 10px;
    border: 1px solid #30b615be;
    border-radius: 4px;
    font-size: 14px;
    margin-top: 5px;
    margin-bottom: 10px;
}

textarea {
    resize: vertical;
}

.form-group {
    margin-bottom: 15px;
}

button[type="submit"] {
    background-color: #333;
    color: #ffffff;
    border: none;
    padding: 12px 20px;
    font-size: 16px;
    border-radius: 4px;
    cursor: pointer;
    width: 100%;
}

button[type="submit"]:hover {
    background-color: #096cd7;
}

.form-group label {
    display: inline;
}

@media screen and (max-width: 600px) {
    form {
        padding: 15px;
    }

    input[type="text"],
    textarea {
        width: 100%;
    }
}
