/* ===== Header ===== */
header.main {
    padding: 14px 0;
    border-bottom: 1px solid var(--line);
    background: #fff;
}

header.main .wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-mark {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    flex-shrink: 0;
    overflow: hidden;
    background: var(--cream);
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-mark img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.35;
}

.logo-word {
    font-size: 20px;
    font-weight: 900;
    letter-spacing: .5px;
    color: var(--maroon);
}

.logo-word span {
    color: var(--gold);
}

.logo-sub {
    font-size: 11px;
    font-weight: 600;
    color: var(--muted);
}

nav.mainnav ul {
    display: flex;
    gap: 16px;
    font-size: 13px;
    font-weight: 600;
    flex-wrap: nowrap;
}

nav.mainnav a {
    color: #4a3a3c;
    padding: 6px 2px;
    position: relative;
}

nav.mainnav li.active a {
    color: var(--maroon);
}

nav.mainnav li.active a::after {
    content: "";
    position: absolute;
    bottom: -16px;
    right: 0;
    left: 0;
    height: 2px;
    background: var(--maroon);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.cart-icon {
    position: relative;
    font-size: 18px;
    color: var(--maroon);
}

.cart-icon .badge {
    position: absolute;
    top: -8px;
    left: -10px;
    background: var(--maroon);
    color: #fff;
    font-size: 10px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ===== تکمیل CSS هدر: منوی موبایل + جهت صحیح المان‌ها (رفع برخورد با استایل قدیمی صفحه) ===== */
header.main .wrap {
    flex-direction: row !important;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 20px;
    color: #4a3a3c;
    cursor: pointer;
    padding: 6px;
}

.mobile-nav {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    background: #fff;
    border-bottom: 1px solid #eee;
    box-shadow: 0 12px 24px -12px rgba(0, 0, 0, .15);
    padding: 8px 24px 18px;
    z-index: 99;
}

.mobile-nav.open {
    display: block;
}

.mobile-nav ul {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.mobile-nav a {
    display: block;
    padding: 12px 4px;
    border-bottom: 1px solid #eee;
    font-weight: 600;
    color: #4a3a3c;
}

.mobile-nav a.active {
    color: var(--maroon);
}

@media (max-width: 1180px) {
    nav.mainnav {
        display: none;
    }

    .nav-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }
}

