/* ============================================================
   Totonab — CSS اختصاصی پروژه (مکمل قالب اصلی)
   گیت ۴.۲: cart_area + CTA band (shipping + newsletter)
   ============================================================ */

/* ===== Cart/Wishlist/Compare area (رفع ستونی) ===== */
/* ===== Cart/Wishlist/Compare area (رفع تداخل) ===== */
.cart_area {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 14px;
    flex-wrap: nowrap;
}

/* override margin پیش‌فرض قالب (.cart_link { margin-right: 40px }) */
.cart_link {
    margin: 0 !important;
    position: relative;
}

.wishlist_link {
    position: relative;
    margin: 0 !important;
}

.cart_link a,
.wishlist_link a {
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
}

/* آیکون‌ها کمی کوچک‌تر از 32px تا در col-lg-3 جا شوند */
.cart_link a i,
.wishlist_link a i {
    font-size: 24px;
    margin: 0 !important;
}

/* شمارنده‌ها */
.wishlist_link span.cart_count,
.cart_link span.cart_count {
    position: absolute;
    top: -6px;
    right: -10px;
    min-width: 18px;
    min-height: 18px;
    line-height: 18px;
    background: #dc4444;
    border-radius: 100%;
    color: #ffffff;
    font-size: 10px;
    font-weight: 700;
    text-align: center;
    display: inline-block;
    padding: 0 3px;
}

.homepage-category-no-image .categorie_banner_content {
    position: static;
    border: 1px solid #eeeeee;
}

.homepage-brand {
    text-align: center;
}

.homepage-brand img {
    max-width: 100%;
}

.homepage-brand span {
    display: block;
}

.categories_menu_inner li {
    position: relative;
}

.category-submenu-toggle {
    position: absolute;
    top: 0;
    left: 0;
    min-width: 44px;
    min-height: 41px;
    border: 0;
    background: transparent;
    color: #444444;
    cursor: pointer;
}

.categories_menu_inner li > a {
    padding-left: 44px;
}

.categories_title .categori_toggle {
    border: 0;
    background: transparent;
    color: #fff;
    font: inherit;
    cursor: pointer;
}

.categories_title .categori_toggle:hover,
.categories_title .categori_toggle:focus,
.categories_title.active .categori_toggle {
    color: #fff;
}

.homepage-mosaic-empty-0 { aspect-ratio: 470 / 670; }
.homepage-mosaic-empty-1 { aspect-ratio: 670 / 210; }
.homepage-mosaic-empty-2, .homepage-mosaic-empty-3 { aspect-ratio: 370 / 200; }
.homepage-mosaic-empty-4 { aspect-ratio: 270 / 430; }
.homepage-mid-promo-empty { aspect-ratio: 570 / 180; }
.homepage-banner-empty { margin-bottom: 30px; }

.homepage-deal .single_countdown_product {
    border: 0;
    border-left: 1px solid #ddd;
}

.homepage-deal .countdown_product_content {
    margin-top: 0;
    padding: 0 20px 0 10px;
}

.homepage-deal .countdown_product_content h3 {
    font-size: 18px;
}

.homepage-deal .countdown_product_title p {
    color: #fff;
    margin: 0 20px;
}

.homepage-support .single_shipping {
    overflow-wrap: anywhere;
}

.homepage-support .shipping_content h3 {
    text-transform: none;
}

.homepage-support > div:last-child .single_shipping::before {
    display: none;
}

/* ===== Blog comment replies ===== */
.comment_reply {
    border-right: 3px solid var(--brand-tobacco);
}

/* ===== CTA band (shipping + newsletter) ===== */
/* wrapper جدید که هم shipping items و هم newsletter را نگه می‌دارد.
   والد position:relative برای newsletter.newsletter_area (absolute) */
.totonab-cta {
    position: relative;
    padding-top: 90px;
    padding-bottom: 37px;
    margin-top: 106px;
    margin-bottom: 45px;
    background: #f7f7f7;
}

.totonab-cta-inner {
    position: relative;
}

.totonab-cta .newsletter_area .mc-form {
    display: flex;
    align-items: center;
    position: relative;
}

/* ===== Fix dropdown max-height (بیش از ۴ آیتم) ===== */
/* قالب اصلی max-height: 150px دارد (برای ۴ آیتم) — با ۵ آیتم
   (پنل/پروفایل/سفارشات/تخفیف/خروج)، آیتم پنجم بریده می‌شود.
   override می‌کنیم تا با هر تعداد آیتم کار کند. */
.top_right .dropdown_links.open {
    max-height: 400px !important;
    overflow-y: auto;
}

/* آیتم «خروج» — بدون border-bottom (آخرین آیتم) */
.top_right .dropdown_links li:last-child {
    border-bottom: 0 !important;
}

/* Homepage banners use configured media while retaining the theme's slider. */
.homepage-hero {
    position: relative;
    overflow: hidden;
}

.homepage-hero-picture {
    position: absolute;
    inset: 0;
}

.homepage-hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.homepage-hero > .container {
    position: relative;
    z-index: 1;
}

.homepage-compact-products .single_product {
    display: flex;
    align-items: center;
    gap: 20px;
}

.homepage-compact-products .product_thumb {
    flex: 0 0 25%;
}

@media (max-width: 575px) {
    .homepage-compact-products .single_product {
        display: block;
    }

    .homepage-compact-products .product_thumb {
        width: 100%;
    }
}
