:root {
    --primary-color: black;
    --secondary-color: white;
    --tertiary-color: rgb(109, 162, 176);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #f9f9f9;
    overflow-x: hidden;
}

/*header*/
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4rem;
    z-index: 1000;
    color: var(--primary-color);
    background: transparent;
    transition: 0.4s ease;
}

header.scrolled {
    color: white;
    background: var(--primary-color);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

header nav {
    height: 100%;
    padding: 0 2rem;
    display: flex;
    align-items: center;
    justify-content: space-around;
    background: transparent;
}

header h1 {
    margin: 0;
    white-space: nowrap;
}

header h1 span {
    font-size: 1.5rem;
}

header h1 .iconify {
    margin-right: 0.5rem;
    color: var(--tertiary-color);
}

.language-switcher {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px;
    border: 1px solid rgba(109, 162, 176, 0.45);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.35);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

header.scrolled .language-switcher {
    background: #fff;
}

header.scrolled #headerSearch {
    background: #fff;
}


.lang-btn {
    border: none;
    background: transparent;
    color: #222;
    font-size: 17px;
    font-weight: 600;
    padding: 5px 9px;
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.lang-btn.active {
    background: rgb(109, 162, 176);
    color: #fff;
}

.lang-btn:hover {
    background: rgba(109, 162, 176, 0.18);
}

.language-switcher span {
    display: none;
}

.mobile-language-item {
    display: none;
}

header .nav-list {
    padding: 0;
    display: flex;
    align-items: center;
    gap: 3rem;
    list-style: none;
}

header .nav-list li a {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 1rem;
    transition: color 0.3s ease;
}

header.scrolled .nav-list li a {
    color: white;
}

header .nav-list li a:hover {
    color: var(--tertiary-color);
}

.menu-toggle {
    display: none;
    color: var(--primary-color);
    font-size: 1.8rem;
    cursor: pointer;
    z-index: 1003;
}

header.scrolled .menu-toggle {
    color: white;
}

.header-search-wrap {
    position: relative;
}

.header-search-btn {
    cursor: pointer;
}

.header-search-wrap .iconify {
    position: absolute;
    top: 50%;
    left: 1rem;
    transform: translateY(-50%);
    color: var(--tertiary-color);
    font-size: 1.8rem;
    z-index: 2;
}

header nav input {
    width: 16rem;
    height: 2.5rem;
    padding-left: 3.2rem;
    background: rgba(255, 255, 255, 0.8);
    border: 2px solid #ccc;
    border-radius: 2rem;
    outline: none;
    font-size: 0.9rem;
}

header nav input:focus {
    background: white;
    border-color: var(--tertiary-color);
}

html[lang="ar"] .hero-img h2 {
    direction: rtl;
    text-align: right;
}

html[lang="ar"] .hero-img h2 span {
    margin-left: 0;
    margin-right: 4rem;
}

html[lang="ar"] .why-description {
    direction: rtl;
    text-align: right;
}

html[lang="ar"] .why-description p {
    line-height: 2;
}

/* ==========================================
   NAVIGATION ICONS
   ========================================== */

header .nav-list li a {
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

/* Home */
header .nav-list li:nth-child(1) a::before {
    content: "\f015";
}

/* Auto Parts */
header .nav-list li:nth-child(2) a::before {
    content: "\f1b9";
}

/* About */
header .nav-list li:nth-child(3) a::before {
    content: "\f05a";
}

/* Contact */
header .nav-list li:nth-child(4) a::before {
    content: "\f0e0";
}

header .nav-list li a::before {
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    color: var(--tertiary-color);
    font-size: 0.9rem;
    width: 1rem;
    text-align: center;
    flex-shrink: 0;
}

@media (max-width: 768px) {

    header .nav-list li a {
        gap: 0.9rem;
        padding-left: 1.35rem;
        padding-right: 1.35rem;
    }

    header .nav-list li a::before {
        width: 1.15rem;
        margin-right: 0.5rem;
    }

    header .nav-list li {
        min-height: 3.4rem;
    }

}

/*hero*/
.hero {
    margin-top: 0;
}

.hero-img {
    position: relative;
}

.hero-img img {
    width: 100%;
    height: 42rem;
    display: block;
    object-fit: cover;
    object-position: center;
}

.hero-img h2 {
    position: absolute;
    top: 18%;
    left: 5%;
    color: var(--primary-color);
    font-size: 3rem;
}

.hero-img h2 span {
    margin-left: 4rem;
    color: var(--tertiary-color);
    font-size: 2.8rem;
}

/*car brand*/
.car-brand {
    margin-top: 3rem;
    padding: 0 3rem;
}

.search-car {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.search-car h2 {
    margin-right: 1rem;
    color: var(--tertiary-color);
    font-size: 2.5rem;
}

.search-car select {
    width: 12rem;
    height: 3rem;
    padding: 0.5rem;
    background: white;
    border: 1px solid #ccc;
    border-radius: 0.5rem;
    outline: none;
    font-size: 1rem;
}

.search-car select:focus {
    border-color: var(--tertiary-color);
}

.search-car button {
    width: 7rem;
    height: 3rem;
    padding: 0.8rem;
    color: var(--secondary-color);
    background: rgb(47, 119, 138);
    border: 1px solid #ccc;
    border-radius: 0.5rem;
    cursor: pointer;
    font-size: 1rem;
    transition: 0.2s ease;
}

.search-car button:hover {
    background: var(--tertiary-color);
}

#reset {
    background: rgb(192, 37, 37);
}

#reset:hover {
    background: rgb(224, 69, 69);
}

#div-view {
    margin-top: 1.5rem;
    display: flex;
    justify-content: center;
}

#button-view {
    width: 25rem;
    height: 3rem;
    color: var(--secondary-color);
    background: rgb(55, 121, 139);
    border: 1px solid #ccc;
    border-radius: 0.5rem;
    cursor: pointer;
    font-size: 1.3rem;
}

#button-view:hover {
    background: var(--tertiary-color);
}

/*car parts*/
.car-part {
    position: relative;
    margin-top: 4rem;
}

.car-part > img {
    width: 100%;
    height: 50rem;
    display: block;
    object-fit: cover;
}

.car-part h2 {
    position: absolute;
    top: 5%;
    left: 45%;
    color: var(--tertiary-color);
    font-size: 3rem;
}

.slider-wrapper {
    position: absolute;
    top: 40%;
    left: 48%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.crousel {
    width: 100%;
    max-width: 44rem;
    overflow: hidden;
}

.group {
    display: flex;
    gap: 1.2rem;
}

.card {
    flex: 0 0 13.5rem;
    height: 17.5rem;
    margin-top: 15px;
    overflow: hidden;
    background: white;
    border: 5px solid var(--tertiary-color);
    border-radius: 1rem;
    transition: 0.3s ease;
}

.card:hover {
    transform: translateY(-10px);
}

.card img {
    width: 100%;
    height: 12rem;
    object-fit: cover;
}

.card h3 {
    padding: 0.5rem;
    color: var(--tertiary-color);
    text-align: center;
    font-size: 1.1rem;
}

/*featured products*/
.Featured-products {
    margin-top: 7rem;
    padding: 0 2rem;
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-around;
    gap: 2rem;
}

.featured-left {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.Featured-products h2 {
    margin: 0;
    color: var(--tertiary-color);
    font-size: 2.5rem;
}

.products-img {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
}

.products-img img {
    width: 18rem;
    height: 13rem;
    object-fit: cover;
    border-radius: 1rem;
}

.search-box {
    display: flex;
    align-items: center;
}

.search-box input {
    width: 25rem;
    height: 2.8rem;
    padding: 0 1rem;
    border: 1px solid var(--tertiary-color);
    border-radius: 0.5rem 0 0 0.5rem;
    outline: none;
    font-size: 1rem;
}

.search-box input:focus {
    border-color: var(--tertiary-color);
}

.search-btn {
    width: 3rem;
    height: 2.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgb(55, 121, 139);
    border: none;
    border-radius: 0 0.5rem 0.5rem 0;
    cursor: pointer;
    transition: 0.3s ease;
}

.search-btn:hover {
    background: var(--tertiary-color);
}

.search-btn .iconify {
    color: white;
    font-size: 2rem;
}

/*why*/
.choose-us {
    margin-top: 7rem;
    padding: 0 2rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 3rem;
}

.choose-us .img-mechanic img {
    width: 100%;
    max-width: 33rem;
    height: auto;
    border-radius: 3rem;
}

.choose-us .why-description {
    font-size: 1.4rem;
}

#why {
    color: var(--tertiary-color);
}

.choose-us .why-description p {
    font-size: 1rem;
}

.read-more {
    position: relative;
    margin-top: 1rem;
    display: inline-block;
    color: var(--tertiary-color);
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 600;
    transition: color 0.3s ease;
}

.read-more::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -4px;
    width: 40%;
    height: 2px;
    transform: translateX(-50%);
    background: currentColor;
    transition: width 0.3s ease;
}

.read-more:hover {
    color: black;
}

.read-more:hover::after {
    width: 100%;
}

/*footer*/
footer {
    margin-top: 7rem;
    background: var(--primary-color);
    color: rgb(201, 218, 223);
}

.footer-1 {
    max-width: 1300px;
    margin: 0 auto;
    padding: 4rem 2rem 3rem;
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-around;
    gap: 3rem;
}

.footer-1 > div {
    flex: 1;
    min-width: 250px;
}

.footer-1 .iconify {
    margin-right: 0.5rem;
    color: var(--tertiary-color);
    vertical-align: middle;
    font-size: 1.5rem;
}

.footer-1 h2 {
    margin-bottom: 1rem;
    font-size: 1.2rem;
    font-weight: normal;
    line-height: 1.8;
}

.footer-contact-item {
    margin-top: 1.3rem;
}

.footer-1 h2 span {
    margin-top: 0.2rem;
    display: block;
    color: var(--tertiary-color);
    font-weight: bold;
}

.footer-1 h3 {
    position: relative;
    margin-bottom: 1.2rem;
    padding-bottom: 0.5rem;
    color: var(--secondary-color);
    font-size: 1.5rem;
}

.footer-1 h3::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 2.5rem;
    height: 2px;
    background: var(--tertiary-color);
}

.footer-1 .quick-link {
    margin-bottom: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: rgb(201, 218, 223);
    text-decoration: none;
    font-size: 1.15rem;
    transition: 0.3s ease;
}

.footer-1 .quick-link span {
    color: var(--tertiary-color);
    font-weight: bold;
}

.footer-1 .quick-link:hover {
    color: var(--secondary-color);
    transform: translateX(5px);
}

.footer-1 h4 {
    color: var(--secondary-color);
    font-size: 1.8rem;
}

.footer-1 h4 .iconify {
    font-size: 2rem;
}

.footer-2 {
    min-height: 3.5rem;
    padding: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgb(25, 25, 25);
    color: rgba(207, 223, 233, 0.7);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    text-align: center;
    font-size: 1rem;
}

/*whatsapp*/
.whatsapp-float {
    position: fixed;
    right: 20px;
    bottom: 20px;
    width: 60px;
    height: 60px;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--tertiary-color);
    border-radius: 50%;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
    text-decoration: none;
    transition: transform 0.2s ease;
}

.whatsapp-float .fa-whatsapp {
    color: white;
    font-size: 2.4rem;
}

.whatsapp-float:hover {
    transform: scale(1.05);
}

/*tablet*/
@media (max-width: 1100px) {
    header nav {
        padding: 0 1rem;
        justify-content: space-between;
        gap: 1rem;
    }

    header h1 {
        font-size: 1.5rem;
    }

    header h1 span {
        font-size: 1.1rem;
    }

    .header-search-wrap {
        flex: 1;
        max-width: 18rem;
    }

    header nav input {
        width: 100%;
    }

    .hero-img img {
        height: 36rem;
    }

    .hero-img h2 {
        max-width: 80%;
        font-size: 2.6rem;
    }

    .hero-img h2 span {
        font-size: 2.3rem;
    }

    .products-img img {
        width: 16rem;
        height: 12rem;
    }
}

/*small tablet*/
@media (max-width: 900px) {
    header {
        height: 7rem;
    }

    header nav {
        min-height: 7rem;
        padding: 0.35rem 1rem 0.55rem;
        flex-wrap: wrap;
        align-content: center;
        row-gap: 0.25rem;
    }

    .header-search-wrap {
        order: 3;
        width: 100%;
        max-width: none;
        flex-basis: 100%;
    }

    header nav input {
        width: 100%;
        max-width: none;
        height: 2.45rem;
    }

    header.scrolled,
    header.scrolled nav,
    header.scrolled .header-search-wrap {
        background: var(--primary-color);
    }

    .hero-img img {
        height: 34rem;
    }

    .hero-img h2 {
        top: 26%;
        left: 5%;
        max-width: none;
        font-size: 1.2rem;
        line-height: 1.1;
        white-space: nowrap;
    }

    .hero-img h2 span {
        margin: 0.3rem 0 0;
        display: block;
        font-size: 1rem;
        white-space: nowrap;
    }

    .car-brand {
        margin-top: 2rem;
        padding: 0 1rem;
    }

    .search-car {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.8rem;
    }

    .search-car h2 {
        grid-column: 1 / -1;
        margin: 0 0 0.5rem;
        text-align: center;
        font-size: 2rem;
    }

    .search-car select,
    .search-car button {
        width: 100%;
        min-width: 0;
    }

    #button-view {
        width: 100%;
        max-width: 28rem;
    }

    .Featured-products {
        margin-top: 2rem;
        padding: 0 1rem;
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 1rem;
    }

    .featured-left {
        display: contents;
    }

    .Featured-products h2 {
        order: 1;
        font-size: 1.8rem;
        line-height: 1.15;
        white-space: nowrap;
    }

    .Featured-products h2 br {
        display: none;
    }

    .products-img {
        order: 2;
        width: 100%;
        flex-wrap: nowrap;
        gap: 0.6rem;
    }

    .products-img img {
        width: calc((100% - 1.2rem) / 3);
        max-width: 12rem;
        height: auto;
        aspect-ratio: 4 / 3;
        border-radius: 0.7rem;
    }

    .search-box {
        order: 3;
        width: 100%;
        max-width: 30rem;
        justify-content: center;
    }

    .search-box input {
        width: calc(100% - 3rem);
    }

    .choose-us {
        margin-top: 4rem;
        padding: 0 1rem;
        flex-direction: column;
        gap: 2rem;
        text-align: center;
    }

    .choose-us .img-mechanic,
    .choose-us .why-description {
        width: min(100%, 38rem);
    }

    .choose-us .why-description p br {
        display: none;
    }
}

/*mobile*/
@media (max-width: 768px) {
    .menu-toggle {
        position: relative;
        width: 2.5rem;
        height: 2.5rem;
        display: flex;
        align-items: center;
        justify-content: center;
        background: transparent;
        border-radius: 0;
        font-size: 1.45rem;
    }

    header nav {
        position: relative;
        justify-content: space-between;
    }

    header h1 {
        position: absolute;
        top: 12%;
        left: 50%;
        margin: 0;
        transform: translateX(-50%);
        font-size: 1.5rem;
        white-space: nowrap;
        z-index: 1001;
    }

    header .nav-list {
        position: fixed;
        top: 0;
        left: -290px;
        right: auto;
        width: 290px;
        max-width: 78vw;
        height: 100vh;
        margin: 0;
        padding: 5.2rem 0 1.5rem;
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        align-items: stretch;
        gap: 0;
        background: rgba(255, 255, 255, 0.97);
        border-right: 1px solid rgba(0, 0, 0, 0.08);
        box-shadow: 8px 0 28px rgba(0, 0, 0, 0.25);
        overflow-y: auto;
        transition: left 0.35s ease;
        z-index: 1001;
    }

    header .nav-list.active {
        left: 0;
    }

    header .nav-list li {
        width: 100%;
        border-bottom: 1px solid #ececec;
    }

    header .nav-list li:first-child {
        border-top: 1px solid #ececec;
    }

    header .nav-list li a {
        width: 100%;
        padding: 1rem 1.2rem;
        display: block;
        color: #666 !important;
        background: transparent;
        font-size: 0.92rem;
        font-weight: 600;
        text-align: left;
    }

    body:has(header .nav-list.active)::before {
        content: "";
        position: fixed;
        inset: 0;
        z-index: 998;
        background: rgba(0, 0, 0, 0.72);
        pointer-events: none;
    }

    body:has(header .nav-list.active) .menu-toggle {
        position: fixed;
        top: 0.65rem;
        left: 240px;
        z-index: 1003;
        color: #666 !important;
    }

    .hero-img h2 {
        top: 40%;
        left: 5%;
        font-size: 1.4rem;
        line-height: 1.1;
        white-space: nowrap;
    }

    .hero-img h2 span {
        margin: 0.25rem 0 0;
        display: block;
        font-size: 1.15rem;
        white-space: nowrap;
    }

    .car-brand h2 {
        font-size: 2.2rem;
    }

    .car-part {
        margin-top: 1.5rem;
        padding: 0.5rem 0;
        background: #f9f9f9;
    }

    .car-part > img {
        display: none;
    }

    .car-part h2 {
        position: relative;
        top: auto;
        left: auto;
        margin-bottom: 1.5rem;
        text-align: center;
        font-size: 2.2rem;
    }

    .slider-wrapper {
        position: relative;
        top: auto;
        left: auto;
        padding: 0 0.5rem;
    }

    .card {
        flex: 0 0 55vw;
        max-width: 45vw;
        height: 14.3rem;
    }

    .card img {
        height: 10rem;
    }

    .Featured-products h2 {
        font-size: 2.2rem;
    }

    .why-description h2 {
        font-size: 2.2rem;
    }

    .why-description h3 {
        font-size: 1.5rem;
    }

    .footer-1 {
        padding: 2rem 1rem;
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        align-items: start;
        gap: 1.25rem 1rem;
        text-align: left;
    }

    .footer-1 > div {
        width: 100%;
        min-width: 0;
    }

    .footer-1 > div:nth-child(3) {
        grid-column: 1 / -1;
        margin-top: 0.5rem;
        text-align: center;
    }

    .footer-1 h2 {
        margin-bottom: 0.8rem;
        font-size: 0.72rem;
        line-height: 1.55;
        overflow-wrap: anywhere;
    }

    .footer-1 h3 {
        margin-bottom: 0.8rem;
        font-size: 0.95rem;
    }

    .footer-1 h3::after {
        left: 0;
        transform: none;
    }

    .footer-1 .quick-link {
        margin-bottom: 0.55rem;
        font-size: 0.76rem;
    }

    .footer-1 h4 {
        font-size: 1rem;
        white-space: nowrap;
    }

    header .nav-list li a:hover,
    header .nav-list li a:focus {
        color: #666 !important;
        background: transparent;
    }

    header .nav-list li a:active {
        color: var(--tertiary-color) !important;
        background: #f4f4f4;
    }

    .desktop-language-switcher {
        display: none;
    }

    header .nav-list .mobile-language-item {
        display: block;
        padding: 1rem 1.2rem 1.2rem;
        border-bottom: 1px solid #ececec;
    }

    .mobile-language-title {
        margin-bottom: 0.7rem;
        color: #666;
        font-size: 0.92rem;
        font-weight: 700;
        text-align: left;
    }

    .mobile-language-switcher {
        display: flex;
        align-items: center;
        gap: 0.55rem;
    }

    .mobile-lang-btn {
        min-width: 82px;
        padding: 0.5rem 0.8rem;
        border: 1px solid rgba(109, 162, 176, 0.55);
        border-radius: 18px;
        background: #fff;
        color: #555;
        cursor: pointer;
        font-size: 0.82rem;
        font-weight: 700;
        transition: 0.2s ease;
    }

    .mobile-lang-btn.active {
        background: var(--tertiary-color);
        color: #fff;
        border-color: var(--tertiary-color);
    }
}

/*small mobile*/
@media (max-width: 480px) {
    .hero-img img {
        height: 30rem;
    }

    .hero-img h2 {
        top: 25%;
        left: 5%;
        font-size: 1.1rem;
    }

    .hero-img h2 span {
        font-size: 0.9rem;
    }

    header .nav-list {
        width: 76vw;
        max-width: 280px;
        left: -80vw;
    }

    body:has(header .nav-list.active) .menu-toggle {
        left: min(calc(76vw - 42px), 238px);
    }

    .Featured-products h2 {
        font-size: 2.2rem;
    }

    .products-img {
        gap: 0.4rem;
    }

    .products-img img {
        width: calc((100% - 0.8rem) / 3);
        border-radius: 0.55rem;
    }

    .search-box {
        max-width: 100%;
    }

    .footer-1 {
        grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
        padding: 1.6rem 0.8rem;
        gap: 1rem 0.75rem;
    }

    .footer-1 h2 {
        font-size: 0.8rem;
    }

    .footer-1 h3 {
        font-size: 1.2rem;
    }

    .footer-1 .quick-link {
        font-size: 0.9rem;
    }

    .footer-1 h4 {
        font-size: 1.5rem;
    }
}

/*desktop hover*/
@media (hover: hover) and (pointer: fine) and (max-width: 768px) {
    header .nav-list li a:hover {
        padding-left: 1.45rem;
        color: var(--tertiary-color) !important;
        background: #f4f4f4;
    }
}

