/** CUSTOM PROPERTIES **/
:root{
    --fuenteHeading: 'Poppins', sans-serif;
    --fuenteParrafos: 'Roboto', sans-serif;

    --primario: #784D3C;
    --blanco: #ffff;
    --claro: #e1e1e1;
    --negro: #000000;

    --azulEspec: #1f628a;
    --espectro: #4391bf;
    --cafe: #bf6c43;
}
html{
    box-sizing: border-box; /*Elemento Padre*/
    font-size: 62.5%; /*1rem = 10px*/
}
/**RESET*/
*, *::before, *::after{
    box-sizing: inherit; /*Hereda el elemento padre*/
}
body{
    font-family: var(--fuenteParrafos);
    font-size: 1.6rem;
    line-height: 2; /**Interlinedao*/
}
/*? GLOBALES**/
.contenedor{
    max-width: 120rem;
    width: 90%;
    width: min(90%, 120rem);
    margin: 0 auto;
}
/**Enlaces*/
a{
    text-decoration: none;
}
h1, h2, h3, h4{
    font-family: var(--fuenteHeading);
    line-height: 1.2; /*?Interlineado*/
}
h1{
    font-size: 4.8rem;
}
h2{
    font-size: 4rem;
}
h3{
    font-size: 3.2rem;
}
h4{
    font-size: 2.8rem;
}
img{
    max-width: 100%;
}
/*?UTILIDADES*/
.no-margin{
    margin: 0;
}
.no-padding{
    padding: 0;
}
.centrar-texto{
    text-align: center;
}

/** header  */
.header{
    background-image:linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.5),
        rgba(0, 0, 0, 0.3)
    ),url('../img/bannder-panaderia1.webp');
    height: 60rem;
    background-size: cover; /*toma todo el espacio disponible*/
    background-repeat: no-repeat; /*no se repite la imagen*/
    background-position: center center; /*centrar verticalmente y horizontalmente*/
}
.header_texto{
    text-align: center;
    color: var(--blanco);
    margin-top: 15rem;
}
.barra{
    padding-top: 3rem;
}
.logo{
    color: var(--blanco);
    word-wrap: break-word; /*Permite que las palabras largas se dividan en varias lineas*/
}
.logo__nombre{
    font-weight: 400;
}
.logo__bold{
    font-weight: 700;
}
.navegacion__enlace{
    display: block;
    text-align: center;
    font-size: 1.8rem;
    color: var(--blanco);
    position: relative;
    transition: color 0.7s ease; /* Transición más larga para el color */
}
.navegacion__enlace:hover {
    color: #d7994a; /* Cambia el color al hacer hover */
} 
/* Estilos para el menú hamburguesa */
.menu-hamburguesa {
    display: block;
    flex-direction: column;
    cursor: pointer;
    z-index: 1000; /* Asegúrate de que el menú hamburguesa esté por encima de otros elementos */
}
.menu-hamburguesa .barra-icono {
    width: 25px;
    height: 3px;
    background-color: var(--blanco);
    margin: 4px 0;
}
.menu-hamburguesa.activar .barra-icono:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}
.menu-hamburguesa.activar .barra-icono:nth-child(2) {
    opacity: 0;
}
.menu-hamburguesa.activar .barra-icono:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Clase para desactivar el desplazamiento del cuerpo */
.no-scroll {
    overflow: hidden;
}
/**Fin nav**
/** Datos del Main  */
.entrada{
    border-bottom: 1px solid var(--claro);
    margin-bottom: 2rem; /*margen inferior*/
}
.entrada:last-of-type{ /*última entrada*/
    border: none;
    margin-bottom: 0;
}
.boton{
    display: block;
    font-family: var(--fuenteHeading);
    color: var(--blanco);
    text-align: center;
    padding: 1rem 3rem;
    font-size: 1.8rem;
    text-transform: uppercase;
    font-weight: 700;
    margin-bottom: 2rem;
    border: none;
}
.boton:hover{
    cursor: pointer;
}
.boton--primario{
    background-color: var(--negro);
}
.boton--secundario{
    background-color: var(--primario);
}
.cursos{
    list-style: none;
}
/** Datos del Aside  */
.widget-curso{
    border-bottom: 1px solid var(--claro);
    margin-bottom: 2rem;
}
.widget-curso:last-of-type{ /**Elimina el border el ultimo elemento*/
    border: none;
    margin-bottom: 0;
}
.widget-curso__label{
    font-family: var(--fuenteHeading);
    font-weight: 700;
}
.widget-curso__info{
    font-weight: 400;
}
.widget-curso__label,
.widget-curso__info{
    font-size: 2rem;
}
/** Inicia el Footer */
.footer{
    background-color: var(--negro);
    padding-bottom: 3rem;
    margin-top: 4rem;
}
.footer .contenedor {
    display: flex;
    flex-direction: column;
    align-items: center;
}
.barra-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
}
.footer-navegacion,
.footer-redes,
.footer-ubicacion {
    margin: 1rem 0;
}
.footer__enlace{
    display: block;
    text-align: center;
    font-size: 1.8rem;
    color: var(--blanco);
    margin: 0.5rem 0;
    position: relative;
    transition: color 0.7s ease; /* Transición más larga para el color */
}
.footer__enlace:hover {
    color: #d7994a; /* Cambia el color al hacer hover */
}
.footer__ubicacion__texto {
    font-weight: 700;
}
.footer__ubicacion__texto,
.footer__ubicacion__enlace {
    color: var(--blanco);
    text-align: center;
}
.facebook_i {
    color: var(--azulEspec);
}
.twitter_i {
    color: var(--espectro);
}
.instagram_i {
    color: var(--cafe);
}
/** Responsive Design **/
@media (max-width: 767px) {
    .barra {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }
    .navegacion {
        display: none;
        flex-direction: column;
        width: 100%;
        height: 100%; /* Esto asegura que cubra todo el header */
        background-color: rgba(0, 0, 0, 0.8);
        position: fixed; /* Cambiado a fixed para que siempre esté visible */
        top: 0;
        left: 0;
        text-align: center;
        z-index: 999;
        gap: 1rem;
    }
    .navegacion.mostrar {
        display: flex;
    }
    .navegacion__enlace{
        margin: 2rem;
    }
}
@media (min-width: 768px) {
    .barra{
        display: flex;
        justify-content: space-between;
        align-items: center;
    }
    .navegacion{
        display: flex;
        gap: 2rem;
    }
    .header_texto{
        margin-top: 15rem;
    }
    .logo__nombre{
        font-weight: 400;
    }
    .contenido-principal{
        display: grid;
        grid-template-columns: 2fr 1fr;
        column-gap: 4rem;
    }
    .boton{
        display: inline-block; /*respetara los margenes y otros elementos*/
    }
    .navegacion__enlace::after {
        content: '';
        position: absolute;
        left: 50%;
        bottom: -2px; /* Ajusta el espacio del subrayado */
        width: 0;
        height: 2px;
        background-color: #d7994a; /* Color del subrayado */
        transition: width 0.3s ease; /* Transición para el ancho del subrayado */
        transform: translateX(-50%);
    }
    .navegacion__enlace:hover {
        color: #d7994a;
    }
    /* Efecto de hover para el subrayado */
    .navegacion__enlace:hover::after {
        width: 100%; /* Ancho completo del subrayado al hacer hover */
    }
    .menu-hamburguesa {
        display: none;
    }
    .barra-footer {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        gap: 4rem;
    }
    .footer-navegacion {
        display: flex;
        flex-direction: column;
        gap: 2rem;
    }
    .footer-redes {
        display: flex;
        gap: 2rem;
    }
    .footer-ubicacion {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    .footer__enlace {
        margin: 0;
    }
    .footer__enlace::after {
        content: '';
        position: absolute;
        left: 50%;
        bottom: -2px; /* Ajusta el espacio del subrayado */
        width: 0;
        height: 2px;
        background-color: #d7994a; /* Color del subrayado */
        transition: width 0.3s ease; /* Transición para el ancho del subrayado */
        transform: translateX(-50%);
    }
    .footer__enlace:hover {
        color: #d7994a;
    }
    /* Efecto de hover para el subrayado */
    .footer__enlace:hover::after {
        width: 100%; /* Ancho completo del subrayado al hacer hover */
    }
}

/*? SOBRE NOSOTROS  */
@media (min-width: 768px) {
    /** flexbox */
    /* .sobre-nosotros{
        display: flex;
        justify-content: space-between;
    }
    
    .sobre-nosotros__texto{
        flex: 0 0 calc(50% - 1rem);
    }
    .sobre-nosotros__imagen{
        flex: 0 0 calc(50% - 1rem);
    } */
    /** grid */
    .sobre-nosotros{
        display: grid;
        grid-template-columns: repeat(2,1fr);
        column-gap: 2rem;
    }
}
/*? Cursos  */
.curso{
    padding: 3rem 0;
    border-bottom: 1px solid var(--claro);
}
@media (min-width: 768px) {
    .curso{
        display: grid;
        grid-template-columns: 1fr 2fr;
        column-gap: 2rem;
    }
}
.curso:last-of-type{ /**Elimina el border el ultimo elemento*/
    border: none;
    margin-bottom: 0;
}
.curso__label{
    font-family: var(--fuenteHeading);
    font-weight: 700;
}
.curso__info{
    font-weight: 400;
}
.curso__label,
.curso__info{
    font-size: 2rem;
}
/*? Contacto  */
.formEnviado {
    background-color: rgb(74, 185, 0);
    text-align: center;
    padding: 1rem;
    color: var(--blanco);
    text-transform: uppercase;
}
.error {
    background-color: rgb(185, 0, 0);
    text-align: center;
    padding: 1rem;
    color: var(--blanco);
    text-transform: uppercase;
}
/* Estilos para los campos del formulario */
.campo__field.exito {
    border: 2px solid green; /* Borde verde para éxito */
}

.campo__field.error {
    border: 2px solid red; /* Borde rojo para error */
}
.contacto-bg{
    background-image: url(../img/contacto.jpg);
    height: 40rem;
    background-size: cover;
    background-repeat: no-repeat;
}

.formulario{
    background-color: var(--blanco);
    margin: -5rem auto 0 auto;
    width: auto;
    padding: 3rem 0;
}
@media (min-width: 768px) {
    .formulario{
        width: 95%;
        padding: 3rem;
    }
}
.campo{
    display: flex;
    margin-bottom: 2rem;
}
.campo__label{
    flex: 0 0 9rem;
    text-align: right;
    padding-right: 2rem;
}
.campo__field{
    flex: 1;
    border: 1px solid var(--claro);
}
.campo__field--textarea{ /**Modificador text-tarea*/
    height: 20rem;
}