@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

*{
    font-family: 'Poppins', sans-serif;
    margin: 0;
    padding: 0;
    scroll-padding-top: 1rem;
    scroll-behavior: smooth;
    list-style: none;
    box-sizing: border-box;
    text-decoration: none;
}

:root{
    --main-color:#d40000;

    --bg-color:#fff;
}

/*---------------------------------------*/

html::-webkit-scrollbar{
    width: 0.5rem;
    background: transparent;
}
html::-webkit-scrollbar-thumb{
    border-radius: 5rem;
    background: var(--text-color);
}

/*---------------------------------------*/

section{
    padding: -2rem 0 2rem;
}

img{
    width: 100%;
}

body{
    background-image: linear-gradient(180deg, #ffffffcb 0%, #ffffffcb 100%), url('../img/repuestos.webp');
    background-repeat: no-repeat;
    background-position-x:  center;
    background-attachment: fixed;
}

.container{
    max-width: 1068px;
    margin-left: auto;
    margin-right: auto;
}

/*---------------------------------------*/

header{
    display: block;
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 100;
}

header.shadow{
    background-color: var(--bg-color);
    box-shadow: 4px 4px 4px rgb(15 54 55 / 10%);
    transition: 0.5s ease;
}
header.shadow #search-icon{
    color: var(--text-color);


}

/*---------------------------------------*/

.nav{
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 35px;
}

#menu-icon{
    font-size: 24px;
    cursor: pointer;
    color: var(--text-color);
    display: none;
}
.logo{
    width: 100%;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-color);
    margin-top: 20px;
}
.logo span{
    color: var(--main-color);
}
.navbar{
    display: flex;
    column-gap: 15rem;
}
.navbar a{
    color: var(--text-color);
    font-size: 1rem;
    text-transform: uppercase;
    font-weight: 500;
}

/*--------------------------------------*/

.subtitle {
    margin-left: -650px;
    font-size: 1.5rem;
    align-items: center;
    display: flex;
    justify-content: center;
    padding-top: 20px;
}

.subtitle span{
    font-size: 2.0rem;
}

.subtitle h1,span{
    margin-bottom: 10px;
}

.subtitle img{
    width: 60px;
    height: 60px;
    margin-left: 25px;
}

/*--------------------------------------*/


/* Header */

header{
    width: 100%;
    height: 90px;
    position: fixed;
    top: 0;
    left: 0;
    background: #000000;
}

/*Header superior*/

.header_superior{
    max-width: 1200px;
    margin: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}


/* Barra menu */

.nav_container{
    width: 100%;
    height: 70px;
    padding: 0px;
    margin-top: 20px;
    margin-left: 20px;
    background-color: #000000;
}

.nav_container .logo{
    color: #fff;
    margin-left: 10px;
}

.navbar{
    max-width: 1200px;
    margin-left: 450px;
    height: 60%;
    color: #fff;
}

nav{
    height: 100%;
}

nav > ul{
    height: 100%;
    display: flex;
}

nav > ul > li{
    height: 100%;
    list-style: none;
    position: relative;
}

nav > ul > li > a{
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    padding: 15px;
    color: #ffffff;
}


.navbar a:hover,

.navbar .active{
    color: var(--main-color);
    border-bottom: 3px solid var(--main-color);
}

/* --------------------Sub menu-----------------*/

nav  ul  li ul {
    width: 200px;
    display: flex;
    flex-direction: column;
    background-color: #000000;
    position: absolute;
    top: 55px;
    left: -5px;
    padding: 14px 0px;
    visibility: hidden;
    opacity: 0;
    box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.5);
    z-index: 10;
    transition: all 300ms ease;
    color: #ffffff;
}

nav ul li:hover ul{
    visibility: visible;
    opacity: 1;
    top: 60;
}

nav ul li ul::before{
    content: '';
    width: 0;
    height: 0;
    border-left: 12px solid transparent;
    border-right: 12px solid transparent;
    border-bottom: 12px solid rgb(0, 0, 0);
    position: absolute;
    top: -10px;
    left: 20px;
}

nav ul li ul li a{
    display: block;
    padding: 16px;
    margin-left: 14px;
    margin-right: 10px;
    margin-top: 0px;
    transition: all 200ms ease;
}

/*-----------------------------------------*/

.box2{
    width: 100%;
    display: flex;
    padding: 0%;
    text-align: center;
    align-items: center;
    gap: 2rem;
    justify-content: center;
}

/*-----------------------------------------*/

#search-icon{
    font-size: 24px;
    cursor: pointer;
    color: var(--bg-color);
    margin-top: 10px;
}
.search-box{
    position: absolute;
    top: 110%;
    right: 0;
    left: 0;
    background: var(--bg-color);
    box-shadow: 4px 4px 20px rgb(15 54 55 / 10%);
    border: 1px solid  var(--main-color);
    border-radius: 0.5rem;
    clip-path: circle(0% at 100% 0%);
}
.search-box.active{
    clip-path: circle(144% at 100% 0%);
    transition: 0.4s;
}
.search-box input{
    width: 100%;
    padding: 20px;
    border: none;
    outline: none;
    background: transparent;
    font-size: 1rem;
}
.home{
    max-width: 1300px;
    margin: auto;
    width: 100%;
    min-height: 400px;
    display: flex;
    align-items: center;
    /*background: url(/img/Background-home.png);*/
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center left;
}
.home-text{
    padding-left: 130px;
}
.home-text h1{
    font-size: 2.4rem;
}
.home-text span{
    color: var(--main-color);
}
.home-text p{
    font-size: 0.938rem;
    font-weight: 300;
    margin: 0.5rem 0 1.2rem;
}
/* Contenedor del slider */
.slider_box {
    width: 100%;
    overflow: hidden;
    position: relative;
}

/* Contenedor de la lista de imágenes */
.slider_box ul {
    display: flex;
    padding: 0;
    margin: 0;
    list-style: none;
    animation: slide 20s infinite;
}

/* Estilos para cada imagen y su texto */
.slider_box li {
    min-width: 100%;
    position: relative;
}

/* Estilos para las imágenes */
.slider_box img {
    width: 100%;
    height: auto;
    display: block;
}

/* Estilos para el texto sobre las imágenes */
.slider_box .text {
    position: absolute;
    bottom: 10%;
    left: 5%;
    color: white;
    background: rgba(0, 0, 0, 0.5);
    padding: 10px;
    border-radius: 5px;
}

/* Animación para el slider automático */
@keyframes slide {
    0% { transform: translateX(0); }
    20% { transform: translateX(0); }
    25% { transform: translateX(-100%); }
    45% { transform: translateX(-100%); }
    50% { transform: translateX(-200%); }
    70% { transform: translateX(-200%); }
    75% { transform: translateX(-300%); }
    95% { transform: translateX(-300%); }
    100% { transform: translateX(0); }
}

/*--------------------------------------*/

.btn2{
    padding: 10px 22px;
    background: #990000;
    color: var(--bg-color);
    font-weight: 400;
    border-radius: 0.5rem;
    margin-top: 10px;
    border: none;
    outline: none;
    cursor: pointer;
    transition: .5s;
}
.btn2:hover{
    background: #970000;
}

/*--------------------------------------*/

.btn{
    padding: 10px 22px;
    background: #7e0101;
    color: var(--bg-color);
    font-weight: 400;
    border-radius: 0.5rem;
    margin-top: 10px;
    border: none;
    outline: none;
    cursor: pointer;
    transition: .5s;
}
.btn:hover{
    background: #970000;
}

/*--------------------------------------*/

.btn3{
    width: 120px;

    padding: 10px 22px;
    background-color: var(--main-color);
    color: var(--bg-color);
    font-weight: 400;
    border-radius: 0.5rem;
    margin-top: 10px;
}

/*--------------------------------------*/

.btn-add-cart{
    padding: 10px 22px;
    background: #b80404;
    color: var(--bg-color);
    font-weight: 400;
    border-radius: 0.5rem;
    margin-top: 10px;
    border: none;
    outline: none;
    cursor: pointer;
    transition: .5s;
}
.btn-add-cart:hover{
    background: #790000;
}


/*--------------------------------------*/

.heading{
    text-align: center;
    margin-top: 15px;
}
.heading span{
    font-weight: 500;
    color: var(--main-color);
}
.heading p{
    font-size: 0.938rem;
    font-weight: 300;
}

/*--------------------------------------*/

.cars-container{
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-top: rem;
}
.cars-container .box{
    flex: 1 1 17rem;
    position: relative;
    height: 200px;
    border-radius: 0.5rem;
    overflow: hidden;
}
.cars-container .box img{
    width: 50%;
    height: auto;
    object-fit: cover;
    overflow: hidden;
}

.cars-container .box img:hover{
    transform: scale(1.1);
    transition: 0.5s;

}
.cars-container .box h2{
    position: absolute;
    bottom: 1rem;
    left: 1rem;
    font-weight: 400;
    font-size: 1rem;
    background-color: var(--bg-color);
    padding: 8px;
    border-radius: 0.5rem;

}
.cars-container  .box:hover h2{
    background: var(--main-color);
    color: var(--bg-color);
}

/*--------------------------------------*/

.about{
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1.5rem;
}
.about-img{
    flex: 1 1 21rem;
}
.about-text{
    flex: 1 1 21rem;
}
.about-text span{
    font-weight: 500;
    color: var(--main-color);
}
.about-text h2{
    font-size: 1.7rem;
}
.about-text p{
    font-size: 0.938rem;
    margin: 0.5rem 0 1.4rem;
}

/*--------------------------------------*/

.parts-container{
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-top: 2rem;
}
.parts-container .box{
    flex: 1 1 17rem;
    position: relative;
    padding: 20px;
    display: flex;
    flex-direction: column;
    background: #f6f6f6;
    border-radius: 0.5rem;
    align-items: center;
}
.parts-container .box img{
    width: 100%;
    height: 150px;
    object-fit: contain;
    object-position: center;
    margin-bottom: 1rem;
}
.parts-container .box .titulo.item{
    font-size: 1.1rem;
    font-weight: 600;
}
.parts-container .box .precio-item{
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--main-color);
}

.parts-container .box .btn-add-cart{
    font-size: 0.938rem;
    font-weight: 300;
    margin: 0.5rem 0 1.2rem;
}

.parts-container .box .bx{
    color: var(--main-color);
    margin: 0.8rem 0;
}
.parts-container .box .btn{
    max-width: 120px;
}
.parts-container .box .details{
    display: flex;
    align-items: center;
    position: absolute;
    bottom: 1.8rem;
    right: 1rem;
    font-size: 1rem;
    color: var(--text-color);
}
.parts-container .box .details:hover{
    color: var(--main-color);
    text-decoration: underline;
}

/*--------------------------------------*/

.blog-container{
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-top: 2rem;
}
.blog-container .box{
    flex: 1 1 13rem;
    padding: 20px;
    border-radius: 0.5rem;
    
}
.blog-container .box:hover{
    background: #f6f6f6;
}
.blog-container .box span{
    font-size: 0.8rem;
    color: var(--main-color);
}
.blog-container h3{
    font-size: 1.2rem;

}
.blog-container.box p{
    font-size: 0.938rem;
    margin: 4px 0;
}
.blog-container .box .blog-btn{
    display: flex;
    align-items: center;
    column-gap: 4px;
    color: var(--text-color);
}
.blog-container .box .blog-btn .bx{
    font-size: 20px;
}
.blog-container .box .blog-btn:hover{
    color: var(--main-color);
    column-gap: 0.7rem;
    transition: 0.4s;
}

/*--------------------------------------*/

.footer{
    background-color: #000000;
    color: #ffffff;
    border-top: 2px solid var(--main-color);
    margin-top: 25px;
}
.footer-container{
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}
.footer-container .logo{
    color: black;
    margin-bottom: 1rem;
}
.footer-container .footer-box{
    margin-top: 15px;
    display: flex;
    flex-direction: column;
}

/*--------------------------------------*/

.social{
    display: flex;
    align-items: center;
}
.social a{
    font-size: 24px;
    color:var(--bg-color);
    margin-right: 1rem;
}
.social a:hover{
    color: var(--main-color);
}

/*----------------------------------------------------------------------------------*/


.footer-box h3{
    font-size: 1.1rem;
    font-weight: 400;
    margin-bottom: 1rem;
}
.footer-box p:hover{
    color: var(--main-color);
}
.footer-box a,

.footer-box p{
    color: #818181;
    margin-bottom: 10px;
}
.footer-box a:hover{
    color: var(--main-color);
}

/*--------------------------------------*/

.copyright{
    padding-top: 0px;
    text-align: center;
    color: var(--bg-color);
    background: var(--text-color);
}
.copyright p:hover{
    color: var(--main-color);
}

/*--------------------------------------*/

@media (max-width: 1080px) {
    .container {
    margin-left: 1rem;
    margin-right: 1rem;
    }
}

@media (max-width: 991px) {
    .nav {
    padding: 15px 20px;
    }
    section {
    padding: 3rem 0 1rem;
    }
    .home-text {
    padding-left: 2rem;
    }
    .home-text h1 {
    font-size: 2.1rem;
    }
}
@media (max-width: 920px) {
    #search-icon {
    color: var(--text-color);
    }
}

.icon__menu{
    font-size: 26px;
    color:#fff;
    cursor: pointer;
    width: 26px;
    height: 100%;
    display: none;
    align-items: center;
}


#label__check{
    width: 26px;
    height: 100%;
    display: none;
}

#check__menu{
    display: none;
}


/* Estilos para el menú responsive */
#check__menu,
#label__check {
    display: none;
}

.icon__menu {
    font-size: 1.5em;
    cursor: pointer;
    color: #fff;
}

@media screen and (max-width: 768px) {
    .navbar {
        margin-left: 0;
    }

    nav > ul {
        flex-direction: column;
        background-color: #000000;
        position: fixed;
        left: 0;
        top: 90px;
        width: 100%;
        height: 0;
        transition: all 300ms ease;
        z-index: 100;
        opacity: 0;
        visibility: hidden;
    }

    nav > ul > li > a:hover {
        transform: scale(1);
    }

    nav ul li ul {
        left: 90px;
    }

    nav > ul > li:hover ul {
        top: 50px;
        position: fixed;
    }

    #label__check {
        display: block;
        cursor: pointer;
        width: 26px;
        height: 100%;
        padding: 20px;
    }

    #check__menu:checked ~ nav > ul {
        height: calc(100vh - 90px);
        visibility: visible;
        align-items: center;
        opacity: 1;
    }
}


@media (max-width: 727px) {
    .heading span {
    font-size: 0.9rem;
    }
    .heading h2 {
    font-size: 1.4rem;
    }
    .about {
    flex-direction: column-reverse;
    }
    .about-text {
    text-align: center;
    }
    .about-text h2 {
    font-size: 1.4rem;
    }
}

@media (max-width: 991px) {
    .subtitle {
        padding-left: 40rem;
    }

    .subtitle span{
        font-size: 2.0rem;
    }

    .subtitle img{
        margin-left: auto;
    }
}

@media (max-width: 607px) {
    .footer-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    }
}
@media (max-width: 360px) {
    .search-box input {
    padding: 11px;
    }
    .home {
    min-height: 500px;
    }
    .home-text h1 {
    font-size: 2rem;
    }
    .home-text p br {
    display: contents;
    }
}