/*=============== GOOGLE FONTS ===============*/
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

/*=============== VARIABLES CSS ===============*/
:root {
  --header-height: 3.5rem; /*56px*/

  /*========== Colors ==========*/
  /*Color mode HSL(hue, saturation, lightness)*/
  --hue: 152;
  --first-color: hsl(var(--hue), 24%, 32%);
  --first-color-alt: hsl(var(--hue), 24%, 28%);
  --first-color-light: hsl(var(--hue), 24%, 66%);
  --first-color-lighten: hsl(var(--hue), 24%, 92%);
  --title-color: hsl(var(--hue), 4%, 15%);
  --text-color: hsl(var(--hue), 4%, 35%);
  --text-color-light: hsl(var(--hue), 4%, 55%);
  --body-color: hsl(var(--hue), 0%, 100%);
  --container-color: #FFF;
  --banner-color: hsl(0, 0%, 10%);

  /*========== Font and typography ==========*/
  /*.5rem = 8px | 1rem = 16px ...*/
  --body-font: 'Poppins', sans-serif;
  --big-font-size: 2rem;
  --h1-font-size: 1.5rem;
  --h2-font-size: 1.25rem;
  --h3-font-size: 1rem;
  --normal-font-size: .938rem;
  --small-font-size: .813rem;
  --smaller-font-size: .75rem;

  /*========== Font weight ==========*/
  --font-medium: 500;
  --font-semi-bold: 600;

  /*========== Margenes Bottom ==========*/
  /*.5rem = 8px | 1rem = 16px ...*/
  --mb-0-5: .5rem;
  --mb-0-75: .75rem;
  --mb-1: 1rem;
  --mb-1-5: 1.5rem;
  --mb-2: 2rem;
  --mb-2-5: 2.5rem;

  /*========== z index ==========*/
  --z-tooltip: 10;
  --z-fixed: 100;
  --z-modal: 1000;
  --z-popup: 1000;
}

/* Responsive typography */
@media screen and (min-width: 968px) {
  :root {
    --big-font-size: 3.5rem;
    --h1-font-size: 2.25rem;
    --h2-font-size: 1.5rem;
    --h3-font-size: 1.25rem;
    --normal-font-size: 1rem;
    --small-font-size: .875rem;
    --smaller-font-size: .813rem;
  }
}

/*=============== BASE ===============*/
*{
  box-sizing: border-box;
  padding: 0;
  margin: 0;
  scroll-behavior: smooth;
}

html{
  scroll-behavior: smooth;
}

html:focus-within{
    scroll-behavior: smooth !important;
}

body,
button,
input,
textarea{
  font-family: var(--body-font);
  font-size: var(--normal-font-size);
}

body{
  margin: var(--header-height) 0 0 0;
  background-color: var(--body-color);
  color: var(--text-color);
  transition: 0.4s; /*For animation dark mode*/
  scroll-behavior: smooth;
}

button{
  cursor: pointer;
  border: none;
  outline: none;
}

h1,h2,h3{
  color: var(--title-color);
  font-weight: var(--font-semi-bold);
}

p{
    color: var(--text-color-light);
}

ul{
  list-style: none;
}

a{
  text-decoration: none;
}

img{
  max-width: 100%;
  height: auto;

  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
}

/*=============== THEME ===============*/
/*========== Variables Dark theme ==========*/
body.dark-theme{
    --first-color-dark: hsl(var(--hue), 8%, 20%);
    --title-color: hsl(var(--hue), 4%, 95%);
    --text-color: hsl(var(--hue), 4%, 75%);
    --body-color: hsl(var(--hue), 8%, 12%);
    --container-color:  hsl(var(--hue), 8%, 16%);
}

/*========== Button Dark/Light ==========*/
.change-theme{
    color: var(--title-color);
    font-size: 1.2rem;
    cursor: pointer;
}

.nav-btns{
    display: inline-flex;
    align-items: center;
    column-gap: 1rem;
}

/*========== Color changes in some parts of the website, in dark theme ==========*/
.dark-theme .home-title{
    color: var(--title-color);
}

.dark-theme .home-description{
    color: var(--title-color);
}

.dark-theme .steps-bg{
    background-color: var(--first-color-dark);
}

.dark-theme .scroll-header{
    box-shadow: 0 1px 4px hsl(var(--hue), 4%, 4%, 0.3);
}


/*=============== REUSABLE CSS CLASSES ===============*/
.section{
  padding: 5.5rem 0 1rem;
}

.section-title,
.section-title-center{
  font-size: var(--h2-font-size);
  margin-bottom: var(--mb-2);
  line-height: 140%;
}

.section-title-center{
  text-align: center;
}

.container{
  max-width: 968px;
  margin-left: var(--mb-1);
  margin-right: var(--mb-1);
}

.grid{
  display: grid;
}

.main{
  overflow: hidden; /*For animation*/
}

/*=============== HEADER ===============*/
.header{
    width: 100%;
    background-color: var(--body-color);
    position: fixed;
    top: 0;
    left: 0;
    z-index: var(--z-fixed);
    transition: 0.4s; /* For animation dark*/
}


/*=============== NAV ===============*/
.nav{
    height: var(--header-height);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo,
.nav-toggle,
.nav-close{
    color: var(--title-color);
}

.nav-logo{
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: -1px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    column-gap: 0.5rem;
    transition: 0.3s;
}

.nav-logo:hover{
    color: var(--first-color);
}

.nav-toggle{
    display: inline-flex;
    font-size: 1.25rem;
    cursor: pointer;
}

@media screen and (max-width: 767px){
    .nav-menu{
        position: fixed;
        background-color: var(--container-color);
        width: 80%;
        height: 100%;
        top: 0;
        right: -100%;
        box-shadow: -2px 0 4px hsl(var(--hue), 24%, 15%, 0.1);
        padding: 4rem 0 0 3rem;
        transition: 0.3s;
        z-index: var(--z-fixed);
    }
}

.nav-close{
    font-size: 1.5rem;
    position: absolute;
    top: 1rem;
    right: 1.25rem;
    cursor: pointer;
}

.nav-list{
    display: flex;
    flex-direction: column;
    row-gap: 1.5rem;
}

.nav-link{
    color: var(--title-color);
    font-weight: var(--font-medium);
}

.nav-link:hover{
        color: var(--first-color);
}


/* Show menu */
.show-menu{
    right: 0;
}

/* Change background header */
.scroll-header{
    box-shadow: 0 1px 4px hsl(var(--hue), 4%, 15%, 0.1);
}

/* Active link */
.active-link{
    position: relative;
    color: var(--first-color)
}

.active-link::after{
    content: "";
    position: absolute;
    bottom: -0.5rem;
    left: 0;
    width: 50%;
    height: 2px;
    background-color: var(--first-color);
}


/*=============== HOME ===============*/
.home{
    padding: 3.5rem 0 2rem;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.7)), url('../img/home.png');
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}

.home-data{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    gap: 1.5rem;
}

.home-title{
    font-size: var(--big-font-size);
    line-height: 140%;
    margin-bottom: var(--mb-1);
    color: var(--container-color);
}

.home-description{
    margin-bottom: var(--mb-2-5);  
    color: var(--body-color);
}

/*=============== BUTTONS ===============*/
.button{
    display: inline-block;
    background-color: var(--first-color);
    color: #FFF;
    padding: 1rem 1rem;
    border-radius: 0.5rem;
    font-weight: var(--font-medium);
    transition: 0.3s;
}

.button:hover{
    background-color: var(--first-color-alt);
}

.button-icon{
    transition: 0.3s;
}

.button:hover .button-icon{
    transform: translateX(0.25rem);
}

.button-flex{
    display: inline-flex;
    align-items: center;
    column-gap: 0.5rem;
}

.button-link{
    color: var(--first-color);
    font-weight: var(--font-medium);
}

.button-link:hover .button-icon{
    transform: translateX(0.25rem);
}


/*=============== ABOUT ===============*/
.about-container{
    row-gap: 2rem;
}

.about-img{
    width: 280px;
    justify-self: center;
}

.about-title{
    margin-bottom: var(--mb-1);
}

.about-description{
    margin-bottom: var(--mb-2);
}

.about-details{
    display: grid;
    row-gap: 1rem;
    margin-bottom: var(--mb-2-5);
}

.about-details-description{
    display: inline-flex;
    column-gap: 0.5rem;
    font-size: var(--small-font-size);
}

.about-details-icon{
    font-size: 1rem;
    color: var(--first-color);
    margin-top:  0.15rem;
}

/*=============== STEPS ===============*/
.steps-bg{
    background-color: var(--first-color);
    padding: 3rem 1rem 2rem;
    border-radius: 1rem;
}

.steps-container{
    gap: 2rem;
    padding-top: 1rem;
}

.steps-title{
    color: #FFF;
    text-align: center;
}

.steps-card{
    background-color: var(--container-color);
    padding: 2.5rem 3rem 2rem 1.5rem;
    border-radius: 1rem;
}

.steps-card-number{
    display: inline-block;
    background-color: var(--first-color-alt);
    color: #FFF;
    padding: 0.5rem 0.75rem;
    border-radius: 0.25rem;
    font-size: var(--h2-font-size);
    margin-bottom: var(--mb-1-5);
    transition: 0.3s;
}

.steps-card-icon{
    font-size: 2rem;
}

.steps-card-title{
    font-size: var(--h3-font-size);
    margin-bottom: var(--mb-0-5);
}

.steps-card-description{
    font-size: var(--small-font-size);
}

.steps-card:hover .steps-card-number{
    transform: translateY(-0.25rem);
}

/*=============== PRODUCTS ===============*/
.product-description{
    text-align: center;
}

.product-container{
    padding: 3rem 0;
    grid-template-columns: repeat(1, 1fr);
    gap: 2.5rem 3rem;
}

.card-product{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.product-img{
    width: 380px;
    justify-self: center;
    filter: drop-shadow(0 8px 16px hsla(5, 90%, 4%, 0.2));
    transition: transform 0.3s;
    margin-bottom: 1rem;
}

.product-title{
    margin-bottom: 0.5rem;
    font-size: var(--h3-font-size);
}


.product-button{   
    background-color: var(--first-color);
    color: #FFF;
    padding: 0.45rem;
    border-radius: 0.35rem;
    font-size: 0.9rem;
}

.product-button:hover{
    background-color: var(--first-color-alt);
}

/***** POPUP MODAL *****/
.modal{
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 1.0);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    display: grid;
    place-items: center;
    padding: 2rem 2rem;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    z-index: var(--z-modal);
    transition: opacity 0.4s, visibility 0.4s;  
    overflow: hidden;
    height: 100vh;
}

.modal-card{
    position: relative;
    background-color: var(--body-color);
    padding: 3rem 1.25rem;
    display: grid;
    row-gap: 1rem;
    transition: 1s ease-in-out;
    height: 90vh;
    transition: transform 1s ease-in-out;
    overflow-y: auto; /* Ensures vertical scrolling */
}

.modal-close{
    position: absolute;
    top: 0.5rem;
    right: 1.5rem;
    font-size: 1.2rem;
    color: #FFF;
    cursor: pointer;
    background: rgba(103, 103, 103, 0.394);
    padding: 0.3rem 0.3rem;
    border-radius: 2rem;
    transform: translateX(100%); /* Start off-screen to the right */
    opacity: 0; /* Start fully transparent */
    transition: transform 0.5s ease-in-out, opacity 0.5s ease-in-out; /* Smooth transition */
}


/* Active modal */
.active-modal{
    opacity: 1;
    visibility: initial;
    pointer-events: all;
}

.modal.active-modal {
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.active-modal .modal-close {
    transform: translateX(0); /* Slide into final position */
    opacity: 1; /* Fade in */
}

body.modal-open {
    overflow: hidden;
}


/*=============== BANNER ===============*/
.repair-banner-container{
    background-color: var(--banner-color);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    padding: 1rem 0;
    
}

.repair-banner-title{
    color: #FFF;
    text-transform: uppercase;
    text-align: center;
}

.repair-banner-button{
    background-color: var(--first-color);
    color: #fff;
    padding: 0.45rem;
    border-radius: 0.35rem;
    font-size: var(--normal-font-size);
    font-weight: var(--font-medium);
}

@keyframes vibrate {
    0%, 90%, 100% {
        transform: rotate(0deg);
    }
    10%, 30%, 50%, 70% {
        transform: rotate(-25deg);
    }
    20%, 40%, 60%, 80% {
        transform: rotate(25deg);
    }
}

.repair-banner-button .ri-phone-line {
    display: inline-block;
    animation: vibrate 1.2s linear infinite;
}

/*=============== PORTFOLIO ===============*/
.portfolio-content{
    overflow: hidden;
}

.portofolio-card{
    border-radius: 1rem;
    margin: 0 auto;
    transition: 0.4s;
}

.portfolio-image img{
    border-radius: 1rem;
}



/* Swiper class */
.swiper-wrapper{
    margin-bottom: 2rem;
}

.swiper-button-prev::after,
.swiper-button-next::after{
    content: ''
}

.swiper-button-prev,
.swiper-button-next{
    width: initial;
    height: initial;
    font-size: 3rem;
    display: none;
}

.swiper-button-icon{
    color: #FFF;
}

.swiper-button-prev{
    left: 0;
}

.swiper-button-next{
    right: 0;
}

.swiper-pagination-bullet{
    
    background-color: #FFF;
}

/* popup image */

.popup-image{
    position: fixed;
    top: 0;
    left: 0;
    background-color: rgba(0, 0, 0, 1.0);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    height: 100%;
    width: 100%;
    display: none;
    z-index: var(--z-popup);
    
}

.popup-close{
    position: absolute;
    top: 18px;
    right: 30px;
    font-size: 1.2rem; 
    color: #fff;
    cursor: pointer;
    z-index: var(--z-popup);
    background: rgba(103, 103, 103, 0.394);
    padding: 0.3rem 0.3rem;
    border-radius: 2rem;

    transform: translateX(100%);
    opacity: 0;
    animation: popup-close-animation 0.5s ease-in-out forwards;
}

@keyframes popup-close-animation {
    100% {
        transform: translateX(0);
        opacity: 1;
    }

}

.popup-image img{
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 5px;
    width: 100%;
    padding: 3rem 1rem;
}

/*=============== CONTACT ===============*/
.contact-container{
    row-gap: 3.5rem;
}

.contact-data{
    display: grid;
    row-gap: 2rem;
}

.contact-subtitle{
    font-size: var(--normal-font-size);
    font-weight: var(--font-medium);
    color: var(--text-color);
    margin-bottom: var(--mb-0-5);
}

.contact-description{
    display: inline-flex;
    align-items: center;
    column-gap: 0.5rem;
    color: var(--title-color);
    font-weight: var(--font-medium);
}

.contact-description a{
    color: var(--title-color);
}

.contact-icon{
    font-size: 1.25rem;
}

.contact-inputs{
    display: grid;
    row-gap: 2rem;
    margin-bottom: var(--mb-2-5);
}

.contact-content{
    position: relative;
    height: 3rem;
    border-bottom: 1px solid var(--text-color-light);
}

.contact-input{
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 1rem 1rem 1rem 0;
    background: none;
    border: none;
    outline: none;
    z-index: 1;
}

.contact-label{
    position: absolute;
    top: 0.75rem;
    width: 100%;
    font-size: var(--small-font-size);
    color: var(--text-color-light);
    transition: 0.3s;
}

.contact-area{
    height: 7rem;
}

.contact-area textarea{
    resize: none;
}

/* Input focus move up label */
.contact-input:focus + .contact-label{
    top: -0.75rem;
    left: 0;
    font-size: var(--smaller-font-size);
    z-index: 10;
}

/* Input focus sticky top label */
.contact-input:not(:placeholder-shown):not(:focus) + .contact-label{
    top: -0.75rem;
    font-size: var(--small-font-size);
    z-index: 10;
}



/*=============== FOOTER ===============*/
.footer-container{
    row-gap: 3rem;
}

.footer-logo{
    display: inline-flex;
    align-items: center;
    column-gap: 0.5rem;
    color: var(--title-color);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: -1px;
    transition: 0.3s;
}

.footer-logo-icon{
    font-size: 1.15rem;
    color: var(--first-color);
}

.footer-title{
    font-size: var(--h3-font-size);
    margin-bottom: var(--mb-1-5);
}

.footer-data{
    display: grid;
    row-gap: 0.75rem;
}

.footer-data a{
    color: var(--text-color-light);
}

.footer-information{
    font-size: var(--small-font-size);
    color: var(--text-color-light);
}

.footer-logo:hover,
.footer-title:hover,
.footer-information:hover, 
.footer-information a:hover, 
.footer-social a:hover{
    color: var(--first-color);
    cursor: pointer;
}

.footer-social{
    display: inline-flex;
    column-gap: 0.75rem;
}

.footer-social-link{
    font-size: 1rem;
    color: var(--text-color);
    transition: 0.3s;
}

.footer-social-link:hover{
    transform: translateY(-0.25rem);
}

.footer-copyright{
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    margin: 5rem 0 1rem;
    gap: 0.8rem;
}

.footer-copy{
    text-align: center;
    font-size: var(--smaller-font-size);
    color: var(--text-color-light);
   
}
/*=============== SCROLL UP ===============*/
.scrollup{
    position: fixed;
    background-color: var(--first-color);
    right: 1rem;
    bottom: -30%;
    display: inline-flex;
    padding: 0.5rem;
    border-radius: 0.25rem;
    z-index: var(--z-tooltip);
    opacity: 0.8;
    transition: 0.4s;
}

.scrollup-icon{
    font-size: 1rem;
    color: #FFF;
}

.scrollup:hover{
    background-color: var(--first-color-alt);
    opacity: 1;
}

.show-scroll{
    bottom: 3rem;
}


/*=============== SCROLL BAR ===============*/
::-webkit-scollbar{
    width: 0.6rem;
    background: hsl(var(--hue), 4%, 53%);
}

::-webkit-scollbar-thumb{
    background: hsl(var(--hue), 4%, 29%);
    border-radius: 0.5rem;
}



/*=============== BREAKPOINTS ===============*/
/* For small devices */
@media screen and (max-width: 320px){
    .container{
        margin-left: var(--mb-1);
        margin-right: var(--mb-1) ;
    }
    
    .button{
        scale: 0.8;
    }

    .home-title{
        font-size: var(--h1-font-size);
    }

    .steps-bg{
        padding: 2rem 1rem;
    }

    .steps-card{
        padding: 1.5rem;
    }

    .product-container{
        grid-template-columns: 1fr;
        justify-content: center;
    }

    .modal-description{
        font-size: var(--small-font-size);
    }

    .modal-close{
        font-size: 0.8rem;
    }

    .repair-banner-title{
        padding: 0 1rem;
        text-align: center;
    }

    .popup-close{
        font-size: 0.8rem;
    }

 

}


/* For medium devices */
@media screen and (min-width: 576px) {


    .steps-container{
        grid-template-columns: repeat(2, 1fr);
    }

    .product-description{
        padding: 0 4rem;
    }

    .product-container{
        grid-template-columns: repeat(2, 1fr);
        justify-content: center;
        column-gap: 5rem;
    }
    
  
}

@media screen and (min-width: 767px) {
    body{
        margin: 0;
    }

    .nav{
        height: calc(var(--header-height) + 1.5rem);
        column-gap: 3rem;
    }

    .nav-toggle,
    .nav-close{
        display: none;
    }

    .nav-list{
        flex-direction: row;
        column-gap:  3rem;
    }

    .nav-menu{
        margin-left: auto;
    }

    .about-container,
    .contact-container,
    .footer-container{
        grid-template-columns: repeat(2, 1fr);
    }

    .home-container{
        align-items: center;
    }

    .home{
        padding: 10rem 0 5rem;
    }

    .modal-card{
        width: 70%;
    }

    .portfolio-content{
        margin-inline: 3rem;
    }

   

    .swiper-button-next,
    .swiper-button-prev{
        display: block;
    }

    .footer-container{
        column-gap: 3rem;
    }

}

/* For large devices */
@media screen and (min-width: 992px) {
    .container{
        margin-left: auto;
        margin-right: auto;
    }

    .section{
        padding: 8rem 0 1rem;
    }

    .section-title,
    .section-title-center{
        font-size: var(--h1-font-size);
    }

    .home{
        padding: 13rem 0 5rem;
    }

    .home-img{
        width: 350px;
    }

    .home-description{
        padding-right: 9rem;
    }

    .about-img{
        width: 380px;
    }

    .steps-container{
        grid-template-columns: repeat(3, 1fr);
    }

    .steps-bg{
        padding: 3.5rem 2.5rem;
    }

    .steps-card-title{
        font-size: var(--normal-font-size);
    }

    .product-description{
        padding: 0 16rem;
    }

    .product-container{
        padding: 4rem 0;
        grid-template-columns: repeat(2, 400px);
        gap: 4rem 6rem;
    }


    .product-title,
    .product-price{
        font-size: var(--normal-font-size);
    }

    .modal-card{
        width: 60%;
    }

    .footer-logo{
        font-size: var(--h3-font-size);
    }

    .footer-container{
        grid-template-columns: 1fr 0.5fr 0.5fr;
    }

    .footer-copy{
        margin: 1rem 0 2rem;
    }

    .footer-copyright{
        flex-direction: row;
    }
}

@media screen and (min-width: 1200px){

    .about-container{
        column-gap: 7rem;
    }

    .scrollup{
        right: 3rem;
    }

    .repair-banner-container{
        flex-direction: row;
        padding: 3rem 0;
        gap: 8rem;
    }

    .popup-image img{
        width: 80%;
    }


    .modal-card{
        width: 60%;
    }

}