@font-face {
    font-family: IRANSans;
    font-style: normal;
    font-weight: normal;
    src: url('../fonts/IRANSansWeb(FaNum).eot');
    src: url('../fonts/IRANSansWeb(FaNum).eot?#iefix') format('embedded-opentype'),  /* IE6-8 */
    url('../fonts/IRANSansWeb(FaNum).woff2') format('woff2'),  /* FF39+,Chrome36+, Opera24+*/
    url('../fonts/IRANSansWeb(FaNum).woff') format('woff'),  /* FF3.6+, IE9, Chrome6+, Saf5.1+*/
    url('../fonts/IRANSansWeb(FaNum).ttf') format('truetype');
}
body { font-family: IRANSans !important; color:#414f62; font-size: 12pt; overflow-x: hidden }
a { color: #062149; text-decoration: none }
header a { color: black; text-decoration: none;  }

main{
    padding-top: 120px;
}
@media (max-width: 992px) {
    main{
        padding-top: 180px;
    }
}

header, .header, .container, .container-lg, .row {
    overflow: visible !important;
}

.user-dropdown-wrap{
    position: relative;
    display: inline-flex;
}

.user-dropdown-menu{
    position: absolute;
    top: calc(100% + 10px);
    left: 50%;
    transform: translate(-50%, 10px);

    width: 230px;
    background: #fff;
    border: 1px solid #eee;
    border-radius: 18px;
    box-shadow: 0 18px 40px rgba(0,0,0,0.12);
    padding: 10px 0;
    z-index: 99999;

    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
}

.user-dropdown-wrap:hover .user-dropdown-menu{
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, 0);
}

.user-dropdown-item{
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 14px;
    text-decoration: none;
    color: #222;
    font-size: 14px;
    font-weight: 700;
    transition: all 0.2s ease;
}

.user-dropdown-item i{
    font-size: 18px;
}

.user-dropdown-item:hover{
    background: #f6f7fb;
}

.user-dropdown-item-danger:hover{
    background: rgba(220,53,69,0.08);
}

.user-dropdown-divider{
    height: 1px;
    background: #eee;
    margin: 6px 0;
}
/* ===== Mobile Fix ===== */
@media (max-width: 991px){
    .user-dropdown-menu{
        width: 155px;
        top: calc(100% + 8px);
    }
}

/*!* ===============================*/
   /*Mega Menu ULTRA (Bootstrap 5)*/
   /*RTL + Multi Level + Desktop Fix*/
/*================================ *!*/

.mega-navbar {
    border-top: 1px solid rgba(0,0,0,0.06);
}

.mega-dropdown.position-static {
    position: static !important;
}

/* مگامنو */
.mega-menu {
    width: 100%;
    max-width: 1200px;
    margin-top: 14px;

    right: 0;
    left: 0;
    margin-right: auto;
    margin-left: auto;

    direction: rtl;
    text-align: right;

    padding: 18px !important;
}

/* جلوگیری از به‌هم‌ریختگی دسکتاپ */
@media (min-width: 992px) {
    .mega-menu {
        position: absolute !important;
        top: 100%;
    }

    /* hover باز شود */
    /*.mega-dropdown:hover > .dropdown-menu {*/
        /*display: block;*/
    /*}*/
}
/* زیرمنو موبایل */
@media (max-width: 992px) {
    .dropdown-menu, .sub-menu {
        max-height: 60vh; /* حداکثر ارتفاع 60٪ ارتفاع صفحه */
        overflow-y: auto;  /* اسکرول عمودی فعال */
        -webkit-overflow-scrolling: touch; /* اسکرول نرم در موبایل */
    }
    .dropdown-menu.show {
        display: block !important;
    }
}


/* عنوان ستون */
.mega-col-title {
    display: flex;
    align-items: center;
    gap: 10px;

    text-decoration: none;
    color: #111827;

    font-weight: 900;
    font-size: 14px;

    padding: 10px 10px;
    border-radius: 16px;

    background: #f9fafb;
    margin-bottom: 12px;
}

/* آیکون‌ها بزرگ و رنگی */
.mega-icon {
    width: 42px;
    height: 42px;
    border-radius: 14px;

    display: flex;
    align-items: center;
    justify-content: center;

    font-size: 22px;
}

/* رنگ‌های جذاب */
.bg-soft-blue { background: rgba(59,130,246,0.12); color: #2563eb; }
.bg-soft-red { background: rgba(239,68,68,0.12); color: #dc2626; }
.bg-soft-green { background: rgba(34,197,94,0.12); color: #16a34a; }
.bg-soft-purple { background: rgba(168,85,247,0.12); color: #7c3aed; }

/* درخت چندسطحی */
.mega-tree {
    margin: 0;
    padding: 0;
}

.mega-tree li {
    position: relative;
}

/* لینک‌های داخل ستون */
.mega-link {
    display: flex;
    align-items: center;
    justify-content: space-between;

    text-decoration: none;
    color: #374151;

    font-size: 13px;
    padding: 8px 10px;
    border-radius: 14px;

    transition: 0.15s;
}

.mega-link:hover {
    background: #f3f4f6;
    color: #111827;
}

/* فلش */
.mega-link .arrow {
    font-size: 12px;
    opacity: 0.55;
}

/* زیرمنوها */
.sub-menu {
    list-style: none;
    padding: 6px 12px 6px 0;
    margin: 6px 0 0 0;

    border-right: 2px solid rgba(0,0,0,0.06);
    display: none;
}

/* سطح‌های بیشتر تو در تو */
.sub-menu .sub-menu {
    margin-top: 6px;
    padding-right: 12px;
    border-right: 2px dashed rgba(0,0,0,0.08);
}

/* دسکتاپ: hover زیرمنوها */
@media (min-width: 992px) {
    .has-children:hover > .sub-menu {
        display: block;
    }
}

/* موبایل: کلیکی */
@media (max-width: 991.98px) {
    .has-children.open > .sub-menu {
        display: block;
    }
}

/* بنر پایین */
.mega-banner {
    background: linear-gradient(135deg, #111827, #1f2937);
    color: #fff;
    border-radius: 18px;
    padding: 18px;
}

.scroll-top-btn {
    position: fixed;
    bottom: 22px;
    right: 22px;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: none;
    background: #fff;
    box-shadow: 0 10px 25px rgba(0,0,0,.15);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: .3s ease;
    z-index: 9999;
}

.scroll-top-btn.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-top-btn i {
    position: absolute;
    font-size: 18px;
    color: #0d6efd;
}

.progress-ring {
    position: absolute;
    transform: rotate(-90deg);
}

.progress-ring__circle {
    stroke: #0d6efd;
    stroke-dasharray: 125;
    stroke-dashoffset: 125;
    transition: stroke-dashoffset .2s linear;
}


/* ===== SLIDER FULL WIDTH - BACKGROUND IMAGE ===== */

/* RESPONSIVE */
@media (max-width: 992px) {
    .slider-bg {
        height: 280px;
    }
    .slider-box {
        max-width: 100%;
        padding: 14px;
        border-radius: 16px;
    }
    .banner-img {
        height: 160px;
    }
}
/* SLIDER WRAPPER */
.slider-wrapper {
    width: 100%;
    /*height: 100%; !* ارتفاع اسلایدر *!*/
    height: 480px; /* ارتفاع اسلایدر */
    display: flex;
    justify-content: center;
    align-items: center;
    background: #fff; /* فضای خالی سفید */
    overflow: hidden;
    position: relative;
}

.slider-img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* تمام تصویر بدون کراپ دیده میشه */
}

/* متن روی اسلایدر */
.slider-box {
    background: rgba(0,0,0,0.55);
    padding: 18px;
    border-radius: 18px;
    max-width: 520px;
}

/* SPECIAL BOX */
.special-img {
    width: 78px;
    height: 78px;
    object-fit: contain;
    background: #f8f9fa;
    border-radius: 14px;
    padding: 8px;
}

.banner-img {
    height: 140px;
    object-fit: cover;
    transition: 0.25s ease;
}

.banner-box:hover .banner-img {
    transform: scale(1.03);
}

/* RESPONSIVE */
@media (max-width: 992px) {
    .slider-wrapper {
        height: 280px;
    }
    .slider-box {
        max-width: 100%;
        padding: 14px;
        border-radius: 16px;
    }
    .banner-img {
        height: 160px;
    }
}
/* ====== MAIN SLIDER RESET ====== */
#mainSlider {
    margin: 0 !important;
    padding: 0 !important;
}

/* carousel-item باید height داشته باشه */
#mainSlider .carousel-item {
    /*height: 460px;*/
    height: 100%;
}

/* wrapper هم باید 100% باشه */
#mainSlider .slider-wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}


/* عکس */
#mainSlider .slider-img {
    width: 100%;
    height: 100%;
    object-fit: contain;     /* عکس کامل نمایش داده میشه */
    background: transparent; /* نوار سیاه هم نداریم */
    display: block;
}

/* موبایل */
@media (max-width: 992px) {
    #mainSlider .carousel-item {
        /*height: 260px;*/
        height: 100%;
    }
}

/* ===== CAR HORIZONTAL SCROLL ===== */
/* اسکرول افقی */
.car-scroll {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    padding: 12px 4px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.car-scroll::-webkit-scrollbar {
    height: 0;
}

/* کارت */
.car-item {
    min-width: 140px;
    max-width: 140px;
    height: 150px; /* ارتفاع بیشتر */

    flex: 0 0 auto;
    scroll-snap-align: start;

    background: #fff;
    border: 1px solid #eee;
    border-radius: 20px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;

    text-decoration: none;
    color: #111;
    font-weight: 700;
    font-size: 14px;

    transition: 0.2s ease;
}

.car-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
}

/* لوگو */
.car-item img,
.car-item .more-icon {
    width: 68px;
    height: 68px;
    object-fit: contain;
}

/* اسم */
.car-item span {
    white-space: nowrap;
}

/* آخر نوار */
.car-more {
    background: #f8f9fa;
    border-style: dashed;
}

/* آیکون پیکان */
.car-more .more-icon {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 18px;

    display: flex;
    align-items: center;
    justify-content: center;
}

.car-more i {
    font-size: 34px;
    color: #0d6efd;
}

/* موبایل */
@media (max-width: 576px) {
    .car-item {
        min-width: 120px;
        max-width: 120px;
        height: 135px;
        border-radius: 18px;
        font-size: 13px;
    }

    .car-item img,
    .car-item .more-icon {
        width: 58px;
        height: 58px;
    }

    .car-more i {
        font-size: 30px;
    }
}

/* SECTION BACKGROUND */
.discount-section {
    /*background: #6f2dbd; !* بنفش *!*/
    background: linear-gradient(to left, #f3ddff, #a853db);
    padding: 22px 0;
    border-radius: 26px;
}

/* RIGHT BOX */
.discount-title-box {
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.18);
    border-radius: 22px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* PRODUCT CARD */
.product-card {
    display: block;
    background: #fff;
    border-radius: 22px;
    overflow: hidden;
    text-decoration: none;
    color: #111;
    border: 1px solid #eee;
    height: 100%;
    transition: 0.2s ease;
}

.product-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(0,0,0,0.15);
}

/* IMAGE */
.product-img {
    width: 100%;
    height: 150px;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 10px;
}

/* BODY */
.product-body {
    padding: 12px 12px 14px 12px;
}

.product-title {
    font-size: 14px;
    font-weight: 800;
    margin: 0 0 10px 0;
    line-height: 1.7;
    min-height: 48px;
}

/* META */
.product-meta {
    display: flex;
    align-items: center;
    justify-content: flex-start; /* تغییر به flex-start */
    gap: 10px; /* فاصله بین آیکون و متن */
    flex-wrap: wrap; /* اجازه میده متن به خط بعد بره */
}

.fast-send {
    font-size: 12px;
    color: #0d6efd;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.fast-send i {
    font-size: 16px;
}

.stock-left {
    font-size: 12px;
    color: #dc3545;
    white-space: nowrap;
}

/* PRICE */
.product-price {
    font-weight: 900;
    font-size: 15px;
}

.product-price.available {
    color: #0d6efd;
}

.product-price.unavailable {
    color: #dc3545;
}

/* SWIPER FIX */
.discountSwiper {
    padding: 6px 0;
}

/* BUTTONS */
.discount-prev,
.discount-next {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background: #fff;
    color: #111;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 5;
    box-shadow: 0 8px 18px rgba(0,0,0,0.18);
    transition: 0.2s ease;
}

.discount-prev:hover,
.discount-next:hover {
    transform: translateY(-50%) scale(1.05);
}

/* راست و چپ */
.discount-prev {
    right: -10px;
}

.discount-next {
    left: -10px;
}

/* MOBILE */
@media (max-width: 992px) {
    .discount-section {
        border-radius: 18px;
    }

    .discount-prev,
    .discount-next {
        display: none; /* در موبایل با درگ کار میکنه */
    }
}
/* پیشنهاد ما */
.suggest-badge {
    position: absolute;
    top: 10px;
    right: 10px;

    background: #ffc107;
    color: #111;

    border-radius: 14px;
    padding: 6px 10px;

    font-size: 12px;
    font-weight: 800;

    display: inline-flex;
    align-items: center;
    gap: 6px;

    box-shadow: 0 8px 18px rgba(0,0,0,0.15);
    z-index: 5;
}

/* آیکون ستاره */
.suggest-badge i {
    font-size: 14px;
}
.product-img {
    position: relative;
}
.discount-icon {
    width: 162px;
    height: 162px;
    object-fit: contain;
    margin-bottom: 14px;
}

#searchResults .search-item {
    cursor: pointer;
    transition: background 0.2s;
}

#searchResults .search-item:hover {
    background-color: #f3f4f6;
}
.banner-img{
    height: 140px;
    width: 100%;
    object-fit: cover;
    object-position: center top; /* برش بیشتر از پایین */
    border-radius: 18px;
}


@media (min-width: 768px){
    .banner-img{
        height: 170px;
    }
}

a:hover .banner-img{
    transform: scale(1.03);
}

.cartype-section {
    background: linear-gradient(to left, #e5e6e8, #9eb0c3);
    padding: 22px 0;
    border-radius: 26px;
}

.full-banner-img{
    width: 100%;
    height: auto;
    display: block;
}

.category-card{
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    text-decoration: none;
    color: #111827;

    background: #fff;
    border-radius: 18px;
    padding: 14px 10px;

    transition: 0.2s;
    border: 1px solid rgba(0,0,0,0.06);
}

.category-card:hover{
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

.category-card img{
    width: 74px;
    height: 74px;
    object-fit: cover;

    border-radius: 50%;
    border: 6px solid #7c3aed; /* ضخامت بیشتر */
    padding: 3px;
    background: #fff;
}

.category-card span{
    margin-top: 10px;
    font-size: 13px;
    font-weight: 700;
    text-align: center;
    line-height: 1.6;
}

/* دکمه‌های روی اسلایدر */
.categorySwiper {
    position: relative; /* دکمه‌ها داخل اسلایدر */
}

.slider-btn-prev,
.slider-btn-next {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;

    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 999; /* مهم: بالا باشد تا روی اسلایدها دیده شود */

    background: #fff;
    border: 1px solid rgba(0,0,0,0.15);
    border-radius: 50%;
    cursor: pointer;
}

.slider-btn-prev { right: 0; }
.slider-btn-next { left: 0; }

.slider-btn-prev i,
.slider-btn-next i {
    font-size: 18px;
    color: #7c3aed;
}


/* مخفی شدن دکمه‌ها روی موبایل کوچک در صورت نیاز */
@media (max-width: 576px){
    .slider-btn-prev,
    .slider-btn-next{
        width: 32px;
        height: 32px;
    }
}


.brandSwiper {
    position: relative;
}

/* دکمه‌های چپ و راست دایره‌ای روی خود اسلایدر */
.swiper-button-prev,
.swiper-button-next {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    color: #333; /* رنگ آیکون */
    font-size: 22px;
}

/* فقط وقتی Swiper خودش محتوا اضافه میکنه متن next/prev رو حذف کن */
.swiper-button-prev::after,
.swiper-button-next::after {
    content: "";
    font-family: none;
    font-size: 0;
}


/* سایه و تصویر برندها */
.brand-card img {
    width: 80px;
    height: 80px;
    object-fit: contain;
}

/* متن و باکس‌ها */
.brand-card span {
    display: block;
    margin-top: 6px;
}


.articleSwiper {
    background-color: #f8f9fa; /* پس‌زمینه خاکستری روشن */
    padding: 1rem 0;
    position: relative;
}

.article-card img {
    height: 120px;
    object-fit: cover;
}

.article-card h6 {
    font-size: 14px;
}

.article-card p {
    font-size: 12px;
    line-height: 1.4;
}

.shop-description h3 {
    font-size: 1.75rem;
}

.shop-description p {
    font-size: 14px;
    line-height: 1.6;
}

.description-preview p strong {
    font-size: 1.1rem;
}

/* انیمیشن باز و بسته شدن */
.description-more {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease;
}
.description-more.show {
    max-height: 1000px; /* ارتفاع کافی برای متن */
}


.footer-top {
    background: #f8f9fa;
    border-top: 1px solid #eee;
    padding: 28px 0; /* کل بخش درشت‌تر و با فاصله‌تر */
}

.footer-feature {
    border: none;            /* حذف کادر */
    background: transparent; /* حذف بک‌گراند سفید */
    border-radius: 0;
    padding: 10px 6px;
    height: 100%;
}

.footer-feature-icon {
    width: 52px;   /* بزرگتر */
    height: 52px;
    object-fit: contain;
    flex-shrink: 0;
}

.footer-feature-text p {
    line-height: 1.4;
    font-size: 15px; /* متن بزرگتر */
}

.footer-feature-text p:first-child {
    margin-bottom: 10px; /* فاصله بیشتر بین متن بالا و پایین */
    font-weight: 800;
}

.footer-feature-text p:last-child {
    font-size: 13px;
}

/* کل فوتر */
.site-footer{
    background: #f3f4f6; /* خاکستری روشن */
}

/* نوار بنفش بالای فوتر */
.footer-top-line{
    height: 5px;
    background: linear-gradient(90deg, #4b2aad, #8a5cff);
}

/* جداکننده ظریف */
.footer-divider{
    height: 1px;
    background: rgba(0,0,0,0.07);
}

/* باکس‌ها */
.footer-box{
    /*background: #fff;*/
    border-radius: 18px;
    padding: 18px 18px;
    /*box-shadow: 0 10px 30px rgba(0,0,0,0.05);*/
    height: 100%;
}

/* برند انگلیسی خاص */
.footer-brand{
    font-size: 28px;
    font-weight: 900;
    letter-spacing: 1px;
    color: #4b2aad;
    font-family: "Trebuchet MS", "Segoe UI", sans-serif;
    line-height: 1.2;
}

/* عنوان ستون ها */
.footer-title{
    font-size: 18px;
    font-weight: 800;
    color: #111;
}

/* متن توضیحات */
.footer-text{
    color: rgba(0,0,0,0.65);
    line-height: 1.9;
    font-size: 14.5px;
}

/* لینک‌ها */

.footer-links li{
    margin-bottom: 12px;
}

.footer-link{
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(0,0,0,0.7);
    text-decoration: none;
    font-size: 14.5px;
    transition: 0.2s ease;
    font-weight: 600;
}

.footer-link:hover{
    color: #4b2aad;
    transform: translateX(-2px);
}

/* نقطه کنار لینک‌ها */
.footer-link .dot{
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #4b2aad;
    flex-shrink: 0;
}

/* لوگوها */
.trust-logo-box{
    width: 120px;
    height: 120px;
    background: #f8f9fa;
    border-radius: 16px;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid rgba(0,0,0,0.06);
    transition: 0.2s ease;
}

.trust-logo-box:hover{
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

.trust-logo{
    max-width: 85%;
    max-height: 85%;
    object-fit: contain;
}

/*----------------------------------------loginPage css----------------------------------------*/

 /*body{*/
     /*background: radial-gradient(circle at 20% 10%, rgba(13,110,253,0.20), transparent 40%),*/
     /*radial-gradient(circle at 90% 70%, rgba(220,53,69,0.18), transparent 45%),*/
     /*linear-gradient(180deg, #f6f8ff, #ffffff);*/
     /*min-height: 100vh;*/
     /*font-family: IRANSans, Vazirmatn, Tahoma, sans-serif;*/
 /*}*/

.auth-wrapper{
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px 0;
}

.auth-card{
    width: 100%;
    max-width: 980px;
    border: none;
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 25px 80px rgba(0,0,0,0.12);
    background: #fff;
}

.auth-right{
    padding: 38px 34px;
}

.auth-rules{
    width: 100%;
}

.auth-checkbox{
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    user-select: none;
    font-size: 13px;
    color: #4b5563;
    line-height: 1.8;
}

.auth-checkbox input{
    display: none;
}

/* custom checkbox */
.auth-checkbox .checkmark{
    width: 18px;
    height: 18px;
    border-radius: 6px;
    border: 2px solid #cbd5e1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: 0.2s;
    flex-shrink: 0;
}

.auth-checkbox input:checked + .checkmark{
    border-color: #0d6efd;
    background: #0d6efd;
}

.auth-checkbox input:checked + .checkmark::after{
    content: "✓";
    font-size: 12px;
    color: #fff;
    font-weight: 900;
}

.auth-rules-text{
    font-weight: 500;
}

/* make all buttons same height */
.auth-btn{
    height: 48px;
    border-radius: 14px;
    font-weight: 700;
    font-size: 14px;
}


.auth-left{
    background: linear-gradient(135deg, #0d6efd, #0b3ea9);
    color: #fff;
    padding: 40px 34px;
    position: relative;
    overflow: hidden;
}

.auth-left:before{
    content: "";
    position: absolute;
    top: -60px;
    right: -60px;
    width: 200px;
    height: 200px;
    background: rgba(255,255,255,0.15);
    border-radius: 50%;
}

.auth-left:after{
    content: "";
    position: absolute;
    bottom: -70px;
    left: -70px;
    width: 240px;
    height: 240px;
    background: rgba(255,255,255,0.12);
    border-radius: 50%;
}

.brand-logo{
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
    font-size: 18px;
}

.auth-title{
    font-size: 20px;
    font-weight: 900;
    color: #111827;
}

.auth-subtitle{
    font-size: 13px;
    color: #6b7280;
    margin-top: 6px;
    line-height: 1.9;
}

.form-label{
    font-weight: 800;
    font-size: 13px;
    color: #111827;
}

.auth-input{
    border-radius: 16px;
    padding: 12px 14px;
    border: 1px solid #e5e7eb;
    background: #f9fafb;
    transition: 0.2s ease;
    font-size: 14px;
}

.auth-input:focus{
    border-color: rgba(13,110,253,0.55);
    box-shadow: 0 0 0 0.22rem rgba(13,110,253,0.12);
    background: #fff;
}

.input-icon{
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    right: 14px;
    color: #6b7280;
    font-size: 18px;
    pointer-events: none;
}

.input-group-wrap{
    position: relative;
}

.input-group-wrap input{
    padding-right: 44px;
}

.toggle-pass{
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: transparent;
    font-size: 18px;
    color: #6b7280;
    padding: 4px 6px;
}

.toggle-pass:hover{
    color: #0d6efd;
}

.auth-btn{
    border-radius: 16px;
    padding: 12px 14px;
    font-weight: 900;
    font-size: 14px;
    box-shadow: 0 16px 40px rgba(13,110,253,0.18);
}

.auth-link{
    text-decoration: none;
    font-weight: 800;
    font-size: 13px;
}

.auth-link:hover{
    text-decoration: underline;
}

.auth-divider{
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 18px 0;
    color: #6b7280;
    font-size: 12px;
    font-weight: 800;
}

.auth-divider:before,
.auth-divider:after{
    content: "";
    flex: 1;
    height: 1px;
    background: #e5e7eb;
}

.auth-left-img-wrap{
    height: 100%;
    min-height: 100%;
    background: #0d6efd;
    overflow: hidden;
}

.auth-left-img{
    width: 100%;
    height: 100%;
    object-fit: cover; /* عکس کامل و جذاب بدون کشیدگی */
    display: block;
}

/* توی موبایل عکس رو بالا نشون بده */
@media (max-width: 992px){
    .auth-left-img-wrap{
        height: 260px;
    }
}

/* کل بخش لاگین ارتفاع ثابت داشته باشه */
.auth-row{
    min-height: 100vh;
    align-items: stretch;
}

/* ستون چپ و راست هر دو هم ارتفاع باشند */
.auth-left,
.auth-right{
    height: 100%;
}

/* ظرف عکس */
.auth-left-img-wrap{
    width: 100%;
    height: 100%;
    min-height: 100vh;
    overflow: hidden;
    border-radius: 24px;
    background: #fff; /* یا هر رنگی که دوست داری */
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-left-img-wrap img{
    width: 100%;
    height: 100%;
    object-fit: contain;  /* مهم */
    object-position: center;
    display: block;
}

/* Smooth Toggle Sections */
.auth-toggle-section{
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.35s ease;
    pointer-events: none;
}

.auth-toggle-section.show{
    max-height: 500px; /* عدد بزرگ برای جا شدن محتوا */
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}
/* Fix checkbox + label in RTL */
.form-check {
    display: flex !important;
    align-items: center;
    gap: 10px;
}

.form-check-input {
    margin: 0 !important;
    flex: 0 0 auto;
}

.form-check-label {
    margin: 0 !important;
    line-height: 1.8;
    cursor: pointer;
}



/*----------------------------------------BlogPage css----------------------------------------*/

/* Categories Wrapper */
.categories-wrapper {
    background: #fff;
    border-radius: 20px;
    padding: 20px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 6px 18px rgba(0,0,0,0.04);
}

/* Categories Header */
.categories-main-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #2d3436;
    display: flex;
    align-items: center;
}

.categories-main-title i {
    font-size: 1.4rem;
}

/* Categories List */
.categories-list {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* Category Items */
.category-item {
    margin-bottom: 2px;
}

.category-link-wrapper {
    width: 100%;
    transition: all 0.2s ease;
}

.category-link {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    color: #495057;
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.3s ease;
    font-weight: 500;
    position: relative;
    overflow: hidden;
    transform: translateZ(0); /* فعال‌سازی شتاب‌دهی سخت‌افزاری */
    backface-visibility: hidden; /* جلوگیری از محو شدگی */
    -webkit-font-smoothing: antialiased; /* بهبود نمایش فونت */
}

.category-link::before {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    height: 100%;
    width: 3px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.category-link:hover {
    background-color: #f8f9fa;
    color: #667eea;
    /* حذف transform: translateX(-5px); */
}

.category-link:hover::before {
    opacity: 1;
}

/* Active Category */
.category-link.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.2);
}

.category-link.active .category-count {
    background: white !important;
    color: #667eea !important;
}

.category-link.active::before {
    opacity: 0;
}

/* Category Icons */
.category-icon {
    font-size: 1.2rem;
    margin-left: 12px;
    width: 24px;
    text-align: center;
    flex-shrink: 0; /* جلوگیری از تغییر اندازه */
}

.category-dot {
    font-size: 1.5rem;
    margin-left: 8px;
    color: #adb5bd;
    flex-shrink: 0;
}

.category-return-icon {
    font-size: 0.9rem;
    margin-left: 8px;
    color: #adb5bd;
    flex-shrink: 0;
}

/* Category Name */
.category-name {
    flex-grow: 1;
    font-size: 0.95rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Category Count */
.category-count {
    font-size: 0.7rem;
    padding: 3px 8px;
    border-radius: 30px;
    margin-right: 8px;
    font-weight: 500;
    flex-shrink: 0;
}

/* Toggle Button */
.toggle-subcategories-btn {
    background: none;
    border: none;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #adb5bd;
    border-radius: 50%;
    transition: all 0.3s ease;
    cursor: pointer;
    margin: 0 5px;
    flex-shrink: 0;
}

.toggle-subcategories-btn:hover {
    background-color: #f1f3f5;
    color: #495057;
    transform: scale(1.1);
}

.toggle-subcategories-btn i {
    font-size: 1.1rem;
    transition: transform 0.3s ease;
}

.toggle-subcategories-btn.active i {
    transform: rotate(-90deg);
}

/* Subcategories List */
.subcategories-list {
    margin-right: 35px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-in-out;
    opacity: 0;
}

.subcategories-list.show {
    max-height: 500px;
    opacity: 1;
    margin-bottom: 5px;
}

/* Level 2 & 3 Styles - Fixed */
.level-2 .category-link {
    padding: 8px 15px;
    font-size: 0.9rem;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.level-2 .category-link:hover {
    background-color: #f1f3f5;
    color: #495057;
    /* حذف transform */
}

.level-2 .category-link.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.level-3 .category-link {
    padding: 6px 15px;
    font-size: 0.85rem;
    color: #6c757d;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.level-3 .category-link:hover {
    background-color: #f1f3f5;
    color: #2d3436;
    /* حذف transform */
}

.level-3 .category-link.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.level-3 .category-link.active .category-name {
    color: white;
}

.level-3 .category-link.active .category-count {
    background: white !important;
    color: #667eea !important;
}

.level-3 .category-link:hover .category-return-icon {
    color: #667eea;
}

/* RTL Adjustments */
[dir="rtl"] .toggle-subcategories-btn i {
    transform: rotate(180deg);
}

[dir="rtl"] .toggle-subcategories-btn.active i {
    transform: rotate(90deg);
}

[dir="rtl"] .category-link:hover {
    transform: none; /* حذف کامل transform در RTL */
}

/* Responsive */
@media (max-width: 992px) {
    .categories-wrapper {
        margin-bottom: 20px;
    }
    .categories-wrapper{
        padding-top: 0 !important;
    }
}

@media (max-width: 768px) {
    .categories-wrapper {
        padding: 15px;
    }

    .category-link {
        padding: 10px 12px;
    }

    .category-icon {
        font-size: 1rem;
        width: 20px;
    }

    .subcategories-list {
        margin-right: 25px;
    }

    .categories-wrapper{
        padding-top: 0 !important;
    }
}

/* Animations - بدون transform */
@keyframes slideIn {
    from {
        opacity: 0;
        /* حذف transform: translateX(-10px); */
    }
    to {
        opacity: 1;
        /* حذف transform: translateX(0); */
    }
}

.category-item {
    animation: slideIn 0.3s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.level-3 .category-link {
    animation: fadeIn 0.3s ease forwards;
}

/* Mobile Categories Toggle Button */
.mobile-categories-toggle {
    display: block;
}

.mobile-categories-toggle .btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 50px;
    padding: 12px 20px;
    font-weight: 500;
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
    transition: all 0.3s ease;
}

.mobile-categories-toggle .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px rgba(102, 126, 234, 0.4);
}

.mobile-categories-toggle .btn-primary i {
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.mobile-categories-toggle .btn-primary:active i {
    transform: translateX(-5px);
}

/* Categories Sidebar - Mobile Styles */
.categories-sidebar {
    position: fixed;
    top: 0;
    right: -350px; /* مخفی در سمت راست */
    width: 320px;
    height: 100vh;
    background: white;
    z-index: 1050;
    transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -5px 0 30px rgba(0, 0, 0, 0.15);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.categories-sidebar.show {
    right: 0; /* نمایش با اسلاید */
}

/* Sidebar Header */
.categories-sidebar-header {
    padding: 20px;
    background: white;
    /*border-bottom: 1px solid #e9ecef;*/
    position: sticky;
    top: 0;
    z-index: 10;
}

.categories-sidebar-header h5 {
    font-size: 1.2rem;
    font-weight: 600;
    color: #2d3436;
}

.categories-sidebar-header .btn-close {
    width: 35px;
    height: 35px;
    background-color: #f1f3f5;
    border-radius: 50%;
    opacity: 1;
    transition: all 0.3s ease;
    position: relative;
}

.categories-sidebar-header .btn-close:hover {
    background-color: #e9ecef;
    transform: rotate(90deg);
}

.categories-sidebar-header hr {
    margin: 15px 0 0 0;
    opacity: 0.1;
}

/* Categories Wrapper داخل سایدبار */
.categories-sidebar .categories-wrapper {
    border: none;
    box-shadow: none;
    padding: 20px;
    flex: 1;
    overflow-y: auto;
}

/* Backdrop */
.categories-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1040;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(3px);
}

.categories-backdrop.show {
    opacity: 1;
    visibility: visible;
}

/* Responsive Adjustments */
@media (min-width: 992px) {
    .mobile-categories-toggle {
        display: none !important;
    }

    .categories-sidebar {
        position: static;
        width: auto;
        height: auto;
        background: transparent;
        overflow-y: visible;
        right: auto;
        transition: none;
        border: 1px solid #e5e7eb;
        box-shadow: 0 6px 18px rgba(0,0,0,0.04);
        border-radius: 18px;
    }

    .categories-sidebar.show {
        right: auto;
    }

    .categories-sidebar-header {
        display: none;
    }

    .categories-backdrop {
        display: none;
    }
}

@media (max-width: 576px) {
    .categories-sidebar {
        width: 280px; /* برای موبایل‌های کوچکتر */
    }
}

/* Articles Grid */
.articles-grid {
    margin-top: 10px;
}

/* Article Cards - اصلاح اساسی */
.article-card {
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    background: #fff;
    position: relative;
    transform: translateY(0);
    border: 1px solid #e9ecef !important;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.article-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.12) !important;
}

/* تصویر - مشکل اصلی اینجا بود */
.article-image-wrapper {
    position: relative;
    width: 100%;
    height: 200px; /* ارتفاع ثابت */
    overflow: hidden;
    flex-shrink: 0;
    background-color: #f8f9fa; /* پس‌زمینه placeholder */
}

.article-image {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover; /* تصویر کل فضا رو پر کنه */
    object-position: center;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    display: block; /* حذف فضای خالی زیر تصویر */
}

.article-card:hover .article-image {
    transform: scale(1.1);
}

/* Card Body - اصلاح فاصله */
.article-card .card-body {
    padding: 16px 16px 18px 16px !important;
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* عنوان مقاله */
.article-title {
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.5;
    margin-bottom: 8px !important;
    min-height: 48px;
}

.article-title a {
    transition: color 0.3s ease;
    color: #2d3436 !important;
}

.article-title a:hover {
    color: #667eea !important;
}

.article-excerpt {
    font-size: 0.85rem;
    line-height: 1.6;
    margin-bottom: 12px !important;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    position: relative;
    color: #6c757d !important;
    flex: 1;

    /* خط آخر محو بشه */
    -webkit-mask-image: linear-gradient(to bottom,
    black 0%,
    black 70%,
    transparent 100%);
    mask-image: linear-gradient(to bottom,
    black 0%,
    black 70%,
    transparent 100%);
}

/* متای مقاله */
.article-meta {
    border-top: 1px dashed #e9ecef;
    padding-top: 12px !important;
    margin-top: auto !important;
}

.article-meta .d-flex {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
}

.article-meta i {
    font-size: 0.85rem;
    margin-left: 4px !important;
}

.article-meta small {
    font-size: 0.8rem;
    font-weight: 500;
    color: #6c757d !important;
}

/* تاریخ و زمان - رنگ آیکون‌ها */
.article-date i,
.article-time i {
    font-size: 0.9rem;
}

.article-date i.bi-calendar3.text-primary { color: #667eea !important; }

.article-date i.bi-calendar3.text-danger { color: #dc3545 !important; }

.article-date i.bi-calendar3.text-warning { color: #f39c12 !important; }

.article-date i.bi-calendar3.text-info { color: #17a2b8 !important; }

.article-date i.bi-calendar3.text-success { color: #28a745 !important; }

/* Responsive - اصلاح شده */
@media (max-width: 1200px) {
    .article-image-wrapper {
        height: 180px;
    }
}

@media (max-width: 992px) {
    .article-image-wrapper {
        height: 200px;
    }

    .article-title {
        font-size: 0.95rem;
        min-height: 44px;
    }

    .article-card .card-body {
        padding: 14px 14px 16px 14px !important;
    }
}

@media (max-width: 768px) {
    .article-image-wrapper {
        height: 220px;
    }

    .article-title {
        min-height: auto;
    }

    .articles-pagination {
        flex-direction: column;
        gap: 15px;
        align-items: center !important;
    }

    .article-excerpt {
        min-height: 40px;
    }
}

@media (max-width: 576px) {
    .articles-toolbar .row > div:first-child {
        margin-bottom: 10px;
    }

    .article-image-wrapper {
        height: 200px;
    }

    .pagination .page-link {
        padding: 6px 12px;
    }

    .article-card .card-body {
        padding: 12px 12px 14px 12px !important;
    }

    .article-title {
        font-size: 0.95rem;
        margin-bottom: 6px !important;
    }

    .article-excerpt {
        font-size: 0.8rem;
        margin-bottom: 10px !important;
        min-height: 36px;
    }

    .article-meta {
        padding-top: 10px !important;
    }

    .article-meta small {
        font-size: 0.75rem;
    }
}

/* Override قوی برای تصاویر */
.article-image-wrapper img.article-image {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: center !important;
    max-width: 100% !important;
    max-height: 100% !important;
    min-width: 100% !important;
    min-height: 100% !important;
}

/* برای رفع مشکل display در مرورگرهای مختلف */
.article-image-wrapper {
    display: block;
    line-height: 0; /* حذف فضای خالی */
    font-size: 0;
}

.article-image-wrapper img {
    line-height: 0;
}

/* اطمینان از ارتفاع یکسان */
.row.g-4.mb-4 .col-12 {
    margin-bottom: 0 !important;
}

/* Article Detail Page */
.article-detail-wrapper {
    background: #fff;
    border-radius: 20px;
    padding: 30px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 6px 18px rgba(0,0,0,0.04);
}

/* Breadcrumb */
.breadcrumb {
    background: none;
    padding: 0;
}

.breadcrumb-item a:hover {
    color: #667eea !important;
}

/* Article Header */
.article-detail-title {
    font-size: 2rem;
    font-weight: 700;
    color: #2d3436;
    line-height: 1.4;
}

/* Featured Image */
.article-featured-image {
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.article-featured-image img {
    transition: transform 0.5s ease;
}

.article-featured-image:hover img {
    transform: scale(1.02);
}

/* Article Content */
.article-content {
    font-size: 1rem;
    line-height: 1.8;
    color: #4a5568;
}

.article-intro {
    color: #2d3436;
    font-weight: 400;
    border-right: 4px solid #667eea;
    padding-right: 20px;
}

/* Sections */
.section-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #2d3436;
    position: relative;
    padding-right: 15px;
}

/* Alert */
.alert-info {
    border-right: 4px solid #17a2b8;
}


/* Share Buttons */
.article-share .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.article-share .btn:hover {
    transform: translateY(-3px);
}

.article-share .btn-outline-primary:hover {
    background: #667eea;
    color: white;
}

/* Related Articles */
.related-articles .card {
    transition: all 0.3s ease;
    border-radius: 12px;
    overflow: hidden;
}

.related-articles .card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1) !important;
}

.related-articles .card img {
    transition: transform 0.5s ease;
}

.related-articles .card:hover img {
    transform: scale(1.1);
}

/* Responsive */
@media (max-width: 992px) {
    .article-detail-wrapper {
        padding: 20px;
    }

    .article-detail-title {
        font-size: 1.75rem;
    }
}

@media (max-width: 768px) {
    .article-detail-title {
        font-size: 1.5rem;
    }

    .section-title {
        font-size: 1.3rem;
    }
}

@media (max-width: 576px) {
    .article-detail-wrapper {
        padding: 15px;
    }

    .article-detail-title {
        font-size: 1.3rem;
    }

    .article-intro {
        font-size: 1rem;
    }

    .related-articles .col-12 {
        margin-bottom: 15px;
    }
}

/* Static Pages Styles */
.static-page-wrapper .row{
    background: #fff;
    border-radius: 20px;
    padding: 30px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 6px 18px rgba(0,0,0,0.04);
    /*max-width: 1000px; !* حداکثر عرض برای خوانایی بهتر *!*/
    margin: 0 auto; /* وسط‌چین کردن */
}

/* Page Header */
.static-page-header {
    border-bottom: 2px solid #f1f3f5;
    padding-bottom: 20px;
}

.static-page-title {
    font-size: 2rem;
    font-weight: 700;
    color: #2d3436;
    position: relative;
    display: inline-block;
    margin-bottom: 10px;
}

/* Page Content */
.static-page-content {
    padding: 15px 0;
    font-size: 1rem;
    line-height: 1.8;
    color: #4a5568;
}

/* Section Title */
.section-title {
    font-size: 1.8rem;
    font-weight: 600;
    color: #2d3436;
    margin-bottom: 15px;
}

/* Responsive */
@media (max-width: 992px) {
    .static-page-wrapper {
        padding: 25px;
        /*max-width: 100%;*/
    }

    .static-page-title {
        font-size: 1.8rem;
    }
}

@media (max-width: 768px) {
    .static-page-wrapper {
        padding: 20px;
    }

    .static-page-title {
        font-size: 1.6rem;
    }
}

@media (max-width: 576px) {
    .static-page-wrapper {
        padding: 15px;
    }

    .static-page-title {
        font-size: 1.4rem;
    }
}
