/* Main section */
.main-banner {
    background: url('../images/main-banner.png') no-repeat top center;
    background-position: center;
    background-size: cover;
    min-height: 890px;
}

.main-section {
    padding: 7.5rem 1.87rem;
    display: flex;
    justify-content: space-between;
}

.main-section__image {
    text-align: right;
    position: relative;
    top: 35px;
    left: 20px;
}

.header__buttons {
    display: flex;
    align-items: center;
}

/* Hamburger menu button */
.header__menu-button {
    display: none; /* Desktopda yashirin */
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.625rem; /* 10px = 0.625rem */
}

.header__menu-button span {
    display: block;
    width: 1.5rem; /* 24px = 1.5rem */
    height: 0.125rem; /* 2px = 0.125rem */
    background: #333;
    margin-bottom: 0.25rem; /* 4px = 0.25rem */
    transition: all 0.3s ease;
}

/* Hamburger menu ochilganda animatsiya */
.header__menu-button.active span:nth-child(1) {
    transform: rotate(45deg) translate(0.3125rem, 0.3125rem); /* 5px = 0.3125rem */
}

.header__menu-button.active span:nth-child(2) {
    opacity: 0;
}

.header__menu-button.active span:nth-child(3) {
    transform: rotate(-45deg) translate(0.3125rem, -0.3125rem); /* 5px = 0.3125rem */
}

.main-section__welcome {
    font-size: 1rem;
    font-weight: 400;
    margin-bottom: 1.25rem;
    letter-spacing: 2px;
    color: #797979;
}

.main-section__introduction {
    margin-top: 1.25rem;
    font-size: 3.75rem; /* 60 / 16 = 3.75rem */
    font-weight: 500;
    margin-bottom: 1.25rem;
    color: #05364e;
}

.main-section__position {
    color: #05364e;
    font-size: 1.5rem;
    font-weight: 300;
    margin-bottom: 1.25rem;
}

.main-section__social-networks a {
    color: #8fa1aa;
    font-size: 1.25rem;
    display: inline-block;
    margin-right: 1rem;
    cursor: pointer;
}

.main-section__social-networks a:hover i {
    color: #1c44e4;
}

.main-section__action {
    margin-top: 1.87rem; 
}

/* Statistics section */
.statistics {
    padding-top: 6.25rem; /* 100 / 16 = 6.25rem */
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
}

.statistics__item {
    width: 150px;
    background-color: #f8faff;
    text-align: center;
    padding: 0.32rem 0.94rem;
    margin-right: 1.5rem;
    flex: 1 1 auto;
    max-width: 120px;
}

.statistics__number {
    font-size: 1.69rem;
    margin-bottom: 0.32rem;
    background: linear-gradient(90deg, #1345e6 0%, #ed239f 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.statistics__title {
    font-size: 1rem;
    color: #797979;
    font-weight: 300;
}

/* About me section */
.about-me {
    padding: 6.25rem 0;
    display: flex;
    align-items: center;
}

.about-me > div {
    flex: 1;
}

.about-me__image img {
    width: 80%;
}

.about-me__description {
    font-size: 0.87rem;
    font-weight: 300;
    color: #797979;
    line-height: 1.69rem;
}

.about-me__action {
    margin-top: 2.5rem;
}

/* Services section style */
.services {
    padding-top: 6.25rem;
}

.services__cards {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
}

.service-card {
    width: 30%;
    padding: 3.75rem 1.87rem;
    background-color: #f8faff;
    text-align: center;
    box-sizing: border-box;
    transition: all 0.4s ease 0s;
}

.service-card__title {
    color: #05364d;
    font-size: 1.25rem;
    font-weight: 500;
    margin-bottom: 1.25rem;
    text-transform: uppercase;
}

.service-card__description {
    font-size: 0.87rem;
    line-height: 1.68rem;
    font-weight: 300;
    color: #797979;
}

.service-card__link {
    font-size: 0.81rem;
    font-weight: 500;
    text-transform: uppercase;
    color: #05364d;
}

.service-card:hover {
    background-color: #5f30ff;
}

.service-card:hover .service-card__title,
.service-card:hover .service-card__description,
.service-card:hover .service-card__link {
    color: #ffffff;
}

/* Clients section styles */
.clients {
    padding-top: 6.25rem;
}

.client-item {
    display: flex;
    align-items: center;
}

.clients-item > div {
    flex: 1;
}

.client-item__image {
    width: 40%;
}

.client-item__image img {
    width: 100%;
}

.client-item__info {
    padding-top: 3.12rem;
    padding-left: 3.12rem;
}

.clients-item__name {
    font-size: 1.25rem;
    margin-bottom: 0.25rem;
}

.client-item__position {
    font-size: 0.87rem;
    font-weight: 300;
    color: #5b6d75;
}

.client-item__review {
    font-size: 0.87rem;
    line-height: 1.68rem;
    font-weight: 300;
    color: #5b6d75;
}

.client-item__rate {
    display: flex;
    flex-direction: column;
    margin-left: 50px;
    color: #ffd805;
}

/* Portfolio section styles */
.portfolio {
    padding: 3.12rem 0;
}

.portfolio-filters {
    margin-bottom: 1.875rem;
    list-style: none;
    padding: 0;
}

.portfolio-filters li {
    display: inline-block;
    margin-right: 40px;
    font-size: 0.85rem;
    font-weight: 500;
    text-transform: uppercase;
    padding: 0.625rem 1.25rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

.portfolio-filters li:hover,
.portfolio-filters li.active {
    color: #1345e6;
}

.portfolio-items {
    width: 100%;
}

.first_portfolio_container,
.second_portfolio_container {
    width: 100%;
}

.portfolio-item {
    width: 33.33%; 
    padding: 0.625rem;
    position: relative;
    cursor: pointer;
    box-sizing: border-box;
    overflow: hidden;
}

.portfolio_item_twins {
    display: flex;
    width: 100%;
    flex-wrap: wrap;
}

.twins-container {
    width: 50%; /* O‘z holicha qoldi, chunki bu foiz */
    padding: 0.625rem; /* 10px = 0.625rem */
    box-sizing: border-box;
}

.portfolio-item__image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

.portfolio-item__overlay {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 100%;
    z-index: 1;
    transition: all 0.4s ease 0s;
}

.portfolio-item:hover .portfolio-item__overlay {
    opacity: 1;
}

.portfolio-item__info {
    position: absolute;
    bottom: 2.75rem; 
    left: 5rem;
    color: white;
    visibility: hidden;
    opacity: 0;
    z-index: 1;
    transition: all 0.4s ease 0s;
}

.portfolio-item__info a {
    color: white;
    text-decoration: none;
}

.portfolio-item:hover .portfolio-item__overlay {
    visibility: visible;
    top: 20px;
    left: 20px;
    background: rgba(19, 69, 230, 0.9);
}

.portfolio-item:hover .portfolio-item__info {
    visibility: visible;
    bottom: 1.5rem;
    left: 3.75rem;
    opacity: 1;
}

.portfolio_item_twins  {
    display: flex;
    gap: 10px;
    width: 100%;
    justify-content: space-between;
}

.twin-container {
    width: 100%; 
    height: 100%; 
    object-fit: cover;
}

/* Blog section styles */
.blog {
    padding: 6.25rem;
}

.blog-items {
    margin-top: 3.125rem;
    display: flex;
    justify-content: space-between;
}

.blog-item {
    overflow: hidden;
    margin-right: 3%;
    box-sizing: border-box;
}

.blog-item:hover {
    box-shadow: 0px 10px 20px rgb(5 54 77 / 10%);
}

.blog-item:hover .blog-item__info {
    background-color: white;
}

.blog-item__image {
    overflow: hidden;
}
 
.blog-item__image img {
    width: 100%;
    vertical-align: middle;
    transition: all 0.4s ease 0s;
}

.blog-item:hover .blog-item__image img {
    transform: scale(1.1);
}

.blog-item__info {
    background-color: #f8faff;
    padding: 1.87rem;
    color: #797979;
}

.blog-item__main-info span {
    font-size: 0.87rem;
    margin-right: 1.87rem;
    font-weight: lighter;
}

.blog-item__author {
    margin-right: 10px;
}

.blog-item__info i {
margin-right: 0.31rem;
font-weight: lighter;
}

.blog-item__title {
    font-size: 1.25rem;
    margin-top: 1.25rem;
    margin-bottom: 0.94rem;
    color: #05364d;
    font-weight: 700;
}

.blog-item__description {
   line-height: 1.68rem; 
   font-weight: lighter;
   font-size: 0.94rem;
}

.blog-item__learn-more {
    font-size: 0.81rem;
    font-weight: 500;
    text-transform: uppercase;
    color: #05364d;
    cursor: pointer;
}

.blog-item__learn-more:hover {
    color: #ed239f;
}

.blog-item__date {
    display: flex;
    align-items: center;
    gap: 5px;
}

.blog-item__date span {
    display: flex;
    align-items: center;
}

/* Partners section styles */
.partners {
    padding-bottom: 6.25rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
}

.partner {
    padding: 0 1.87rem;
}

.footer__text {
    padding-left: 50px;
}

@media only screen and (max-width: 1120px) {
    .container {
        width: 90%;
    }
}

@media only screen and (max-width: 992px) {
    /* Main section */
    .main-section__image {
        display: none;
    }

    .main-section > div {
        width: 100%;
    }

    .header__menu-button {
        display: block;        /* Hamburger menu ko‘rinadi */
        margin-left: 170px;
    }

    .header__nav {
        display: none; /* Menyu yashirinadi */
        width: 100%;
        position: absolute;
        top: 100%;
        left: 0;
        background: #fff;
        padding: 1.25rem; /* 20px = 1.25rem */
        box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.1);
    }

    .header__nav.active {
        display: block; /* Menyu ochilganda ko‘rinadi */
    }

    .header__list {
        flex-direction: column; /* Vertikal joylashadi */
        gap: 0.625rem; /* 10px = 0.625rem */
    }

    .header__item {
        width: 100%;
    }

    .header__link {
        display: block;
        padding: 0.625rem 0; /* 10px = 0.625rem */
        font-size: 1.125rem; /* 18px = 1.125rem */
    }

    /* Statistics */
    .statistics {
        padding-top: 1rem;
        text-align: center;
        justify-content: center;
    }

    .statistics__item {
        margin-bottom: 20px;
        width: 100%;
        max-width: none;
    }

    /* About me section */
    .about-me {
        padding: 1.5rem 0;
    }

    .about-me > div {
        width: 100%;
    }

    .about-me__action {
        margin-left: auto;
        margin-right: auto;
        display: block;
    }

    .about-me__image {
        display: none;
    }
    /* Services */ 
    .services {
        padding: 1.5rem 0;
    }

    .service__cards {
        flex-wrap: wrap;
    }

    .service-card {
        /* flex-basis: 45%; */
        width: 48%;
        margin-bottom: 20px;
    }
    
    /* Clients */
    .clients {
        padding: 1.5rem;
    }

    .client-item {
        flex-direction: column;
    }

    .clients-item > div {
        width: 100%;
        float: none;
    }

    .client-item__image {
        width: 100%;
    }

    .client-item__rate {
        flex-direction: row;
    }

    /* Portfolio */

    .portfolio_item_twins {
        flex-direction: column;
        justify-content: start;
        height: 30%;
    }

    .twins-container {
        height: 49%;
    }

    .portfolio_item_twins .twins-container {
        width: 100%;
    }

    .second_portfolio_container {
        justify-content: start;
    }
    
    /* Blog */
    .blog {
        padding: 1.5rem 0;
        }
    
    .blog-items { 
        flex-wrap: wrap;
    }

    .blog-item {
        width: 45%;
        margin-bottom: 20px;
    }

    /* Partners */
    .partners {
        padding: 1.5rem 0;
    }

    .partners {
        flex-direction: column;
    }

    .partner {
        padding: 0;
        text-align: center;
        margin-bottom: 10px;
    }

    /* Footer */
    .footer__text {
        padding-left: 50px;
    }

}

@media only screen and (max-width: 768px) {
    /* Main section */
    .main-banner {
        background: none;
        min-height: auto;
    }

    .main-section__action {
        display: none;
    }

    .main-section__welcome {
        font-size: 30px;
    }

    .main-section__introduction {
        font-size: 35px;
        line-height: 42px;
    }

    .main-section__position {
        line-height: 36px;
        font-size: 24px;
        font-weight: 300;
        margin-bottom: 40px;
    }


    /* Statistics section */
    .statistics {
        flex-direction: column;
        align-items: center;
    }
    
    .statistics__item {
        width: 100%;
        margin-bottom: 20px;
        margin-right: 0;
        box-sizing: border-box;
    }


    /* Services section */
    .service-card {
        width: 100%;
        flex-basis: auto;
        margin-right: 0;
        margin-bottom: 20px;
    }

    /* Portfolio */
    .portfolio {
        padding: 1.5rem 0;
    }

    .portfolio-items {
        grid-template-columns: repeat(1, 1fr); /* Mobil devicelar uchun 1 ustun */
        flex-direction: column;
    }

    .first_portfolio_container {
        width: 100%;
    }

    .second_portfolio_container {
        width: 100%;
    }

    .portsolio-item {
        width: 100%;
    }

    .portfolio-item-2,
    .portfolio-item-3 {
        position: static;
    }

    /* Blog */
    .blog-item {
        width: 100%;
        margin-right: 0;
        margin-bottom: 20px;
    }

    /* Footer */

    .footer__brand {
        padding-right: 25px;
    }

    .footer__socials {
        padding-left: 15px;
    }

    .footer__text {
        padding: 0;
    }
}
