/* ═══════════════════════════════════════════════════
   هدر دیتاگستران v1.11 — تمیز و ریسپانسیو
   ═══════════════════════════════════════════════════ */

.dg-header {
    position: sticky;
    top: 0;
    z-index: 999;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 1px 8px rgba(0,0,0,0.06);
}

.dg-header-inner {
    display: flex;
    align-items: center;
    gap: 1rem;
    height: 64px;
}

/* لوگو */
.dg-logo {
    display: flex;
    align-items: center;
    gap: .7rem;
    text-decoration: none !important;
    flex-shrink: 0;
}
.dg-logo-icon {
    width: 42px;
    height: 42px;
    background: var(--teal-deep);
    color: var(--gold-bright);
    display: grid;
    place-items: center;
    border-radius: .9rem;
    flex-shrink: 0;
}
.dg-logo-texts {
    display: flex;
    flex-direction: column;
    line-height: 1.25;
}
.dg-logo-texts strong {
    font-size: 1.1rem;
    font-weight: 900;
    color: var(--teal-deep);
}
.dg-logo-texts small {
    font-size: .58rem;
    font-weight: 800;
    color: var(--gold);
    letter-spacing: .1em;
}

/* منوی دسکتاپ */
.dg-main-nav { flex: 1; }
.dg-nav-list {
    display: flex;
    align-items: center;
    gap: .2rem;
    list-style: none;
    margin: 0;
    padding: 0;
}
.dg-nav-list a {
    display: block;
    padding: .45rem .9rem;
    border-radius: .65rem;
    font-weight: 700;
    font-size: .9rem;
    color: var(--ink);
    white-space: nowrap;
    transition: all .18s;
}
.dg-nav-list a:hover,
.dg-nav-list .current-menu-item > a,
.dg-nav-list .current_page_item > a {
    background: var(--paper-deep);
    color: var(--teal);
}

/* ابزارها */
.dg-header-actions {
    display: flex;
    align-items: center;
    gap: .35rem;
    flex-shrink: 0;
}

/* آیکون‌های هدر */
.dg-icon-btn {
    position: relative;
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: .8rem;
    border: 1px solid var(--line);
    background: var(--card);
    color: var(--teal-deep);
    cursor: pointer;
    text-decoration: none !important;
    transition: all .18s;
    padding: 0;
    flex-shrink: 0;
}
.dg-icon-btn:hover {
    border-color: var(--gold);
    background: var(--gold-soft);
}

/* شمارنده سبد */
.dg-cart-count {
    position: absolute;
    top: -5px;
    left: -5px;
    min-width: 18px;
    height: 18px;
    background: var(--gold);
    color: var(--teal-deep);
    border-radius: 50%;
    font-size: .65rem;
    font-weight: 900;
    display: grid;
    place-items: center;
    border: 2px solid var(--paper);
    line-height: 1;
    padding: 0 3px;
}
.dg-cart-count.hidden { display: none; }

/* همبرگر */
.dg-hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    background: none;
    border: 0;
    cursor: pointer;
    padding: .5rem;
    border-radius: .7rem;
    flex-shrink: 0;
}
.dg-hamburger span {
    display: block;
    height: 2px;
    background: var(--teal-deep);
    border-radius: 2px;
    transition: all .25s;
}
.dg-hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.dg-hamburger.open span:nth-child(2) { opacity: 0; }
.dg-hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* منوی موبایل */
.dg-mobile-nav {
    background: var(--paper);
    border-top: 1px solid var(--line);
}
.dg-mobile-menu-list {
    list-style: none;
    margin: 0;
    padding: 1rem;
}
.dg-mobile-menu-list li a {
    display: block;
    padding: .8rem 1rem;
    border-radius: .8rem;
    font-weight: 700;
    font-size: .95rem;
    color: var(--ink);
    border-bottom: 1px solid rgba(229,219,192,.4);
}
.dg-mobile-menu-list li:last-child a { border-bottom: 0; }
.dg-mobile-menu-list a:hover { background: var(--paper-deep); color: var(--teal); }
.dg-mobile-nav-footer {
    padding: 0 1rem 1rem;
    display: flex;
    flex-direction: column;
    gap: .6rem;
}

/* ریسپانسیو */
@media (max-width: 1023px) {
    .dg-main-nav { display: none; }
    .dg-desktop-only { display: none !important; }
    .dg-hamburger { display: flex; }
    .dg-header-inner { height: 56px; }
    .dg-logo-icon { width: 36px; height: 36px; }
    .dg-logo-texts strong { font-size: .95rem; }
    .dg-logo-texts small { font-size: .52rem; }
}
@media (min-width: 1024px) {
    .dg-hamburger { display: none; }
    .dg-mobile-nav { display: none !important; }
}

/* بار بارگذاری اولیه */
.dg-header .dg-mobile-nav[hidden] { display: none !important; }
