html{
    font-size: 62.5%;
    box-sizing: border-box;
    font-family: 'Roboto', sans-serif;
}

*, *::before, *::after {
    box-sizing: inherit;
}

body{
    margin: 0;
    padding: 0;
    font-size: 1.6rem;
    background-color: #f1f1f1;
}

.display-flex{
    display: flex;
    align-items: center;
}

.margin-top-10px{
    margin-right: 1rem;
}

.container{
    max-width: 120rem;
    margin: 0 auto;
    overflow: hidden;
}

header{
    background-color: #f7f7f8;
    padding: 1rem 0;
}

h1{
    margin: 2rem 0;
    font-size: 3rem;
    font-family: 'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande', 'Lucida Sans Unicode', Geneva, Verdana, sans-serif;
    font-weight: lighter;
}

h2{
    font-weight: lighter;
}

.logo{
    width: 10rem;
    margin-left: 2rem;
    text-decoration: none;
    color: #000;
}

.top-bar{
    max-width: 120rem;
    margin: 0 auto;
    display: flex;
    justify-content: space-evenly;
    align-items: center;

}


.buscador {
    background-color: #ffffff;
    padding: 1rem;
    border-radius: 3rem;
    box-shadow: 0 0 5px rgba(0,0,0,0.1);
    width: 30rem;
    height: 4rem;
    border: none;
    position: relative;
}

.barra-buscador{
    position: relative;
}

.search-icono img{
    width: 2rem;
    top: 0.1rem;
    position: relative;
}

.barra-buscador::after{
    content: '';
    background-color: #108ac4;
    width: 12rem;
    height: 4rem;
    position: absolute;
    right: 0rem;
    top: 0rem;
    border-radius: 3rem;
    display: flex;
    cursor: pointer;
}

.search-icono{
    display: flex;
    justify-content: center;
    align-items: center;
    position: absolute;
    cursor: pointer;
    width: 1rem;
    height: 1rem;
    margin-left: 1rem;
    z-index: 1;
    right: 5.5rem;
    top: 1.5rem;
}

.margin-right-110px{
    margin-right: 11rem;
    
}

.search-icono p{
    color: #ffffff;
    margin: 1rem;
}

nav ul{
    list-style: none;
    padding: 0;
    margin: 0;
}

nav ul li{
    display: inline;
}

nav ul li a{
    color: #000;
    text-decoration: none;
    padding: 1rem;
}

nav ul li a:hover{
    background-color: #108ac4;
    border-radius: 1.5rem;
}

.icons-right {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-left: 1rem;
}

.icons-right img{
    width: 2rem;
    margin-left: 2rem;
    cursor: pointer;
}


/* Ocultar el div de contactos por defecto */
.contactos {
    display: none;
    width: 30rem;
    height: 20rem;
    background: white;
    border-radius: 15px;
    box-shadow: 0px 10px 25px rgba(0, 0, 0, 0.3);
    padding: 25px;
    text-align: center;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.8);
    opacity: 0;
    transition: transform 0.3s ease-out, opacity 0.3s ease-out;
}

.telefono {
    text-decoration: none;
}

/* Mostrar el div de contactos cuando se usa el enlace */
#contactos:target {
    display: block;
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

.contactos h2 {
    margin-bottom: 10px;
    font-size: 2rem;
    color: #333;
}

.contactos p {
    margin: 10px 0;
    font-size: 1.5rem;
    color: #555;
}

.cerrar {
    margin-top: 15px;
    padding: 8px 15px;
    background: linear-gradient(to right, #ff416c, #ff4b2b);
    color: white;
    border: none;
    cursor: pointer;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    transition: background 0.3s, transform 0.2s;
    display: inline-block;
}

.cerrar:hover {
    background: linear-gradient(to right, #ff4b2b, #ff416c);
    transform: scale(1.05);
}

/*-----------------------------Hero----------------------------*/

.hero{
    width: 100%;
    height: 60rem;
    background-image: url(../img/hero.jpg);
    background-size: cover;
    background-position: center;
    
}

/*----------------------------Productos-----------------------*/

.productos{
    margin-top: 10rem;
}

.productos h2{
    text-align: center;
    margin-bottom: 4rem;
}

.fila{
    display: flex;
    justify-content: center;
}

.fila div{
    margin: 0rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
}

.fila p{
    text-align: center;
    margin: 1.4rem;
    font-size: 1.4rem;
    color: #666;
}

/*------------------------------footer----------------------------*/

footer{
    background: #f7f7f8;
    margin-top: 10rem;
    padding-bottom: 4rem;
}

.columnas{
    display: flex;
    justify-content: center;
}

.columna {
    margin-top: 2rem;
    margin-right: 10rem;
}

.fa-brands{
    margin: 1.6rem 0.5rem;
    font-size: 2.5rem;
}

.columna:last-child{
    margin-right: 0;
}
/*-------------------Nosotros--------------------*/
.nosotros {
    text-align: center;
}

/*-------------------Inicia sesion--------------------*/

.contenedor-centrado{
    display: flex;
    justify-content: center;
    align-items: center;
    height: 50rem;
    margin-top: 10rem;
}

.contenedor-centrado .formulario
{
    background-color: #ffffff;
    padding: 4rem;
    border-radius: 3rem;
    box-shadow: 0 0 5px rgba(0,0,0,0.1);
    width: 60rem;
    height: 60rem;
}

.contenedor-centrado h2{
    text-align: center;
    margin-bottom: 4rem;
    font-weight: lighter;
}

.contenedor-centrado p{
    text-align: center;
    margin-bottom: 1rem;
    font-size: 1.4rem;
    color: #666;
}

.contenedor-centrado input {
    width: 30rem;
    height: 4rem;
    border-radius: 3rem;
    padding: 2rem;
    border: none;
    box-shadow: 0 0 5px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.contenedor-centrado hr{
    margin: 4rem auto;
    border: none;
    border-top: 1px solid #ccc;
    width: 30rem;
}

.contenedor-centrado input:focus{
    outline: none;
    box-shadow: 0 0 5px rgba(0,0,0,0.2);
}
.contenedor-centrado input[type="submit"]{
    background-color: #108ac4;
    color: #ffffff;
    cursor: pointer;
    font-size: 1.6rem;
    font-weight: bold;
    padding: 0;
    margin-top: 4rem;
}
.contenedor-centrado input[type="submit"]:hover{
    background-color: #0f7ab4;
}

.contenedor-centrado a{
    text-decoration: none;
    color: #108ac4;
    font-size: 1.4rem;
    display: block;
    text-align: center;
}
.contenedor-centrado a:hover{
    text-decoration: underline;
}

/*-------------------Registro--------------------*/	

.crear-cuenta{
    height: 80rem;
}

.crear-cuenta .formulario
{
    height: 80rem;
}

/*-------------------Favoritos--------------------*/

.favoritos{
    margin-top: 10rem;
}
.favoritos h2{
    text-align: center;
    margin-bottom: 4rem;
    font-weight: lighter;
}


.fila .columna{
    margin: 2rem;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    width: 200rem;
    height: 16rem;
    background-color: #d9d9d9;
    padding: 2rem;
    margin-left: 10rem;
    margin-right: 10rem;
    margin-top: 0rem;
    margin-bottom: 2rem;
    cursor: pointer;
    transition: all 0.6s ease;
}

.favoritos .fila .columna img{
    width: 10rem;
    height: 10rem;
    margin-right: 2rem;
}

.fila .producto{
    display: flex;
    flex-direction: row;
}

/*--------------------Carrito--------------------*/

.carrito{
    margin-top: 10rem;
}

.carrito h2{
    text-align: center;
    margin-bottom: 8rem;
}

.fila-carrito {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.fila-carrito p{
    text-align: center;
}

.fila-carrito .columna-venta{
    display: flex;
    flex-direction: row;
    justify-content: space-around;
    align-items: center;
    width: 100%;
    height: 5rem;
    background-color: #d9d9d9;
    padding: 2rem;
    margin-left: 10rem;
    margin-right: 10rem;
    margin-top: 0rem;
    margin-bottom: 2rem;
}

.fila-carrito .columna-producto{
    display: flex;
    flex-direction: row;
    justify-content: space-around;
    align-items: center;
    width: 100%;
    height: 10rem;
    padding: 2rem;
}

.fila-carrito .columna-producto div, .fila-carrito .columna-venta div{
    display: flex;
    flex-direction: row;
    justify-content: space-around;
    align-items: center;
    width: 100%;
    height: 10rem;
    padding: 2rem;
}
.fila-carrito .columna-producto img{
    width: 10rem;
    height: 10rem;
    margin-right: 2rem;
}
.fila-carrito .producto-venta p{
    margin: 0;
    font-size: 1.4rem;
}

.fila-carrito hr{
    margin: 4rem auto;
    border: none;
    border-top: 1px solid #ccc;
    width: 100%;
}

.total-carrito .columna-venta{
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    height: 5rem;
    background-color: #d9d9d9;
    padding: 2rem;
}

.total-carrito .columna-producto{
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    height: 10rem;
    padding: 2rem;
}

.pos-boton-carrito{
    display: flex;
    justify-content: right;
}

.boton-carrito{
    background-color: #108ac4;
    color: #ffffff;
    cursor: pointer;
    font-size: 1.6rem;
    font-weight: bold;
    margin-top: 4rem;
    width: 20rem;
    height: 5rem;
    border-radius: 3rem;
    border: none;
}
.boton-carrito:hover{
    background-color: #0f7ab4;
}

@media (max-width: 1024px) {
    .logo {
        width: auto;
        margin: 0;
    }
    h1{
        font-size: 3.5rem;
        font-weight: bold;
    }
    .icons-right{
        margin-left: 0;
    }
    .top-bar {
        flex-direction: column;
    }

    .top-bar .display-flex {
        flex-direction: column;
        margin-bottom: 2rem;
        width: 80%;
    }

    .barra-buscador {
        margin-bottom: 2rem;
        width: 100%;
    }

    .buscador {
        width: 80%;
    }
    .fila-carrito{
        width: auto;
    }
    .fila-carrito .columna-venta{
        height: auto;
    }
}

@media (max-width: 768px) {
    .top-bar {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .footer .columnas {
        display: block;
    }
    
    .columnas .columna {
        margin: 2rem auto;
        width: 80%;
    }
    .columnas .columna:last-child {
        margin-right: auto;
    }
    
    .buscador {
        width: 100%;
    }
    
    .catalogo .fila, .columnas {
        flex-direction: column;
        
    }
    .productos .fila .columna{
        width: 100%;
        margin: 0;
        margin-bottom: 2rem;
    }
    
    .productos-carrito p{
        font-size: 1rem;
    }

    .fila-carrito .columna-producto img{
        width: 4rem;
        height: 4rem;
    }

    .fila-carrito .columna-producto div, .fila-carrito .columna-venta div{
        width: 100%;
        height: auto;
        padding: 0.5rem;
    }
}