@font-face {
    font-family: 'IRANSans';
    font-style: normal;
    font-weight: 400;
    src: url('/css/fonts/iransans.woff2');
    src: url('/css/fonts/iransans.woff') format('embedded-opentype'), url('/css/fonts/iransans.woff2') format('woff2'), url('/css/fonts/iransans.woff') format('woff'), url('/css/fonts/iransans.ttf') format('truetype');
}
body {
    align-items: center;
    background-color: #f4f4f4;
    margin: 0;
}

/*html,
body {
    font-family: 'YekanBakh-Regular', sans-serif;
    overflow-x: hidden !important;
}*/
header {
    background-color: #ffffff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: relative;
    padding: 1% 0;
}

.container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 10px 20px;
    position: relative;
}


.left-section {
    display: flex;
    gap: 10px;
    align-items: center;
}

.button1 {
    background-color: #02544c;
    color: white;
    border-radius: 30px;
    font-size: 16px;
    padding: 15px;
    min-width: 130px;
    text-decoration: none;
}

.button1:hover {
    background-color: #00342f;
    transform: translateY(1px);
    color: white;
}

/* Button */
.button2 {
    background-color: #02544c72;
    color: #02544c;
    width: 50px;
    height: 50px;
    min-width: 50px;
    border-radius: 50%;
    align-items: center;
    display: flex;
    justify-content: center;
    position: relative;
    /* Important for absolute positioning inside */
    cursor: pointer;
    padding: 0;
}

/* Cart Badge (Small Circle) */
.cart-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #02544c;
    color: white;
    width: 18px;
    height: 18px;
    font-size: 12px;
    font-weight: bold;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 4px;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
    transition: background-color 0.3s ease-in-out;
}

/* Tooltip Wrapper */
.tooltip-wrapper {
    position: relative;
    display: inline-block;
}

/* Tooltip */
.tooltip-container {
    position: absolute;
    top: 115%;
    left: 350%;
    transform: translateX(-50%);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.5s ease-in-out, transform 0.5s ease-in-out;
}

.tooltip-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 400px;
    max-height: 220px;
    overflow-y: auto;
    font-size: 14px;
    background-color: white;
    border-top: 3px solid #02544c;
    color: black;
    text-align: center;
    padding: 8px 4px;
    border-radius: 10px;
    white-space: nowrap;
    box-shadow: 5px 10px 10px 5px #3333331d;
}

/* Keep tooltip visible when hovering */
@media (min-width: 1024px) {
    .tooltip-wrapper:hover .tooltip-container {
        opacity: 1;
        visibility: visible;
        transform: translateX(-50%) translateY(-5px);
        pointer-events: auto;
    }
}

.button2:hover {
    background-color: #02544c;
    color: white;
}

.Buy {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    padding: 10px;
}

.BtnBuy {
    background-color: #02544c;
    color: white;
    padding: 1px 10px;
    border-radius: 15px;
    padding-top: 5px;
    cursor: pointer;
}

.RemainingCount {
    display: flex;
    flex-direction: row;
    justify-content: center;
    text-align: center;
    background-color: rgba(203, 203, 207, 0.107);
    width: 80px;
    padding: 3px 10px;
    border-radius: 20px;
}

.NoProductImg {
    width: 100%;
    height: auto;
}

.NoProductImg img {
    width: 150px;
    height: auto;
}


.button1,
.button2 {
    border-color: #02544c72;
    cursor: pointer;
}

.SearchSectionBody {
    width: 100%;
    height: 80px;
    background-color: white;
    border-bottom-right-radius: 10px;
    border-bottom-left-radius: 10px;
    display: flex;
    justify-content: center;
}


.search-box-article {
    text-align: right;
}

.search-box-article input {
    padding: 13px 10px;
    border: none;
    border-radius: 10px;
    text-align: right;
    font-size: 14px;
    background-color: rgba(180, 179, 176, 0.107);
}

.search-box-article span {
    padding: 8px 10px;
    border: none;
    border-radius: 10px;
    text-align: center;
    background-color: rgba(180, 179, 176, 0.107);
    color: #9b9a9a;
}

.search-box-article input:focus {
    outline: none !important;
    box-shadow: none !important;
    border-color: #ccc !important;
    background-color: rgba(180, 179, 176, 0.107);
}

/* غیرفعال کردن کلیک روی آیکون */
.search-box-article .input-group-text {
    pointer-events: none;
}

.navbar {
    display: flex;
    position: absolute;
    right: 18%;
    top: 30%;
}

.navbar a {
    text-decoration: none;
    color: #333;
    font-size: 14px;
    transition: color 0.3s;
    padding-right: 20px;
    padding-left: 20px;
}

.sidebar a {
    text-decoration: none;
    color: #333;
    font-size: 14px;
    transition: color 0.3s;
}

.navbar a:hover {
    text-decoration: none;
    background-color: #02e8210d;
    color: #009229;
    padding-top: 15px;
    padding-bottom: 15px;
    border-radius: 10px;
    transition: 0.3s all ease;
}

.logo {
    width: 10em;
    height: auto;
}

.right-section a {
    cursor: pointer;
}

.hamburger {
    display: none;
    cursor: pointer;
    border: none;
    background: none;
    padding: 10px;
    text-align: center;
}


.sidebar {
    position: fixed;
    top: 0;
    right: -300px;
    width: 290px;
    height: 100%;
    background-color: #ffffff;
    box-shadow: -2px 0 5px rgba(0, 0, 0, 0.1);
    transition: right 0.3s;
    padding: 20px;
    z-index: 1000;
}

.sidebar.open {
    right: 0;
}

.sidebar .close-btn {
    position: absolute;
    top: 10px;
    left: 10px;
    cursor: pointer;
    font-size: 30px;
    width: 50px;
    height: 50px;
    text-align: center;
    padding-top: 5px;
}

.sidebar .SearchSectionBody {
    position: absolute;
    right: -5px;
}

.sidebar1 {
    flex-direction: row-reverse;
}

.sidebar2 {
    flex-direction: row-reverse;
}

.Sidebar2-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
}

.basket span {
    cursor: pointer;
}

.sidebar1,
.sidebar2 a {
    cursor: pointer;
}

.left-buttons,
.right-items {
    display: flex;
    align-items: center;
}

.button,
.menu-item {
    margin: 0 10px;
    cursor: pointer;
}

.right-items {
    display: flex;
}

.btn-dark {
    background-color: #02544c;
    color: white;
    border-radius: 5px;
}

.btn-lighter {
    background-color: #02544c72;
    color: #02544c;
    border-radius: 5px;
}

.btn-lighter:hover {
    background-color: #02544c;
    color: white;
    border-radius: 5px;
}

.transition-3 {
    transition: 0.3s all ease;
}

.zoom-image {
    width: 300px;
    height: auto;
    transition: transform 0.3s ease;
}

.zoom-image:hover {
    transform: scale(1.015);
}

.green-box {
    width: 100%;
    height: 300px;
    background-color: #02544c;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    padding: 20px;
}



@media (max-width: 1024px) {
    .container {
        flex-wrap: wrap;
        gap: 15px;
    }

    .navbar {
        display: none;
    }

    .hamburger {
        display: block;
    }

    .left-section {
        order: 2;
        display: flex;
        flex-direction: row-reverse;
        justify-content: space-between;
        align-items: center;
        width: 100%;
    }


    .right-section {
        order: 1;
        display: flex;
        flex-direction: row-reverse;
        justify-content: space-between;
        align-items: center;
        width: 100%;
    }

    .logo {
        width: 8em;
    }

    .button1 {
        background-color: #02544c72;
        color: #02544c;
        border-radius: 10px;
        padding: 15px 5px;
    }

    .button1:hover {
        background-color: #02544c;
        color: white;
    }

    .button2 {
        border-radius: 5px;
    }

    .responsive-header {
        padding-top: 0px;
    }
}

@media (min-width: 1024px) {
    .SearchSectionBody {
        display: none;
    }
}

.custom-container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 0 10px;
}

.image-container {
    width: 100%;
    max-width: 100%;
    border-radius: 10px;
    height: auto;
}


/*green box*/
.green-box-title {
    background-color: #02544c;
    color: white;
    width: 100%;
    height: 180px;
    display: flex;
    flex-direction: column;
    text-align: right;
    justify-content: center;
    position: relative;
    padding-right: 30px;
    margin-bottom: 2%;
}

@media (max-width: 768px) {
    .green-box-title {
        height: 110px;
    }
}

@media (max-width: 1200px) {
    .green-box-title {
        padding-right: 40px;
    }
}


.ProductImg {
    width: 100%;
    border: 15px solid white;
    border-radius: 25px;
    border-bottom-left-radius: 0px;
    border-bottom-right-radius: 0px;
    aspect-ratio: 16 / 9;
}

.BookImg {
    width: 100%;
    border: 15px solid white;
    border-bottom: 30px solid white;
    border-radius: 25px;
    border-bottom-left-radius: 0px;
    border-bottom-right-radius: 0px;
}

.caption {
    background-color: white;
    width: 100%;
    height: 120px;
    justify-content: right;
    text-align: right;
    padding: 8%;
    font-size: 14px;
    font-weight: bold;
    border-bottom-right-radius: 25px;
    border-bottom-left-radius: 25px;
    position: relative;
}

.name {
    display: flex;
    flex-direction: column;
    justify-content: right;
    text-align: right;
    position: absolute;
    top: 15%;
    right: 15%;
}

.description {
    direction: rtl;
    color: #33333398;
    padding-left: 5%;
    font-weight: lighter;
}

.date {
    display: flex;
    flex-direction: column;
    text-align: center;
    line-height: 0.5;
    font-size: 14px;
    position: absolute;
    top: 1%;
    right: 4%;
    color: gray;
    border-radius: 5px;
    width: 35px;
    height: 50px;
    padding-top: 10px;
    font-weight: lighter;
}

.comments {
    display: flex;
    flex-direction: column;
    text-align: center;
    position: absolute;
    bottom: 10%;
    right: 4%;
    color: gray;
    border-radius: 5px;
    width: 35px;
    height: 50px;
}

.comments svg {
    padding-top: 5px;
    padding-left: -5px;
}

.col-12 {
    cursor: pointer;
    transition: transform 0.3s ease;
}

.AllThumbnails {
    margin-bottom: 10%;
}

.AllThumbnails a {
    color: #333333dc;
}

.col-12:hover {
    filter: brightness(1.1);
}


/*footer*/
/* Green Footer (Above the Main Footer) */
.green-footer {
    width: 100%;
    background: #02544c;
    padding: 15px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    color: white;
    height: 40px;
}

.green-footer::before {
    content: '';
    background: #02544c;
    width: 100%;
    position: absolute;
    left: 0;
    top: -20px;
    height: 40px;
    border-radius: 50%;
    z-index: -1;
}

/* Main Footer (Sits at the bottom of the page) */
.main-footer {
    width: 100%;
    height: auto;
    background-color: rgba(114, 114, 116, 0.107);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 0;
    position: relative;
}

.footer-socials {
    display: flex;
    gap: 10px;
}


@media (max-width: 768px) {
    .green-footer .container {
        flex-direction: column-reverse;
        text-align: center;
        gap: 1px;
    }

    .green-footer {
        height: 90px;
    }

    .main-footer .container {
        flex-direction: column-reverse;
        text-align: center;
        gap: 20px;
    }
}



.fixed-span {
    position: fixed;
    left: 10px;
    /* Distance from the left */
    bottom: 10px;
    /* Distance from the top */
    background-color: #aac9c7;
    color: #02544c;
    font-size: 16px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    text-align: center;
    z-index: 999;
    cursor: pointer;
}

.fixed-span:hover {
    background-color: #001c18;
    color: white;
}



#overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 999;
    display: none;
    transition: opacity 0.3s ease;
}

#overlay.active {
    display: block;
    opacity: 1;
}


.BtnBuy {
    background-color: #02544c;
    color: white;
    padding: 1px 10px;
    border-radius: 15px;
    padding-top: 5px;
    cursor: pointer;
    text-decoration: none;
}

.BtnBuy:hover {
    color: white;
}