/* =========================
   Body context
========================= */
.shop-body {
    background: var(--bg, #f5f6f7);
}

.admin-body {
    background: #f3f5f7;
}

/* =========================
   Shared brand styles
========================= */
.brand-logo,
.brand-mini {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.brand-logo {
    gap: 12px;
    min-width: 0;
}

.brand-mini {
    gap: 12px;
    min-width: 0;
    flex: 1;
}

.brand-logo-image,
.brand-mini-logo {
    object-fit: contain;
    flex-shrink: 0;
    background: #fff;
}

.brand-logo-image {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    padding: 6px;
}

.brand-mini-logo {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    padding: 7px;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.06);
}

.brand-text-group,
.brand-mini-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.brand-text-group {
    font-weight: 700;
    line-height: 1.05;
}

.brand-text-group span {
    white-space: nowrap;
}

.brand-mini-text {
    justify-content: center;
    line-height: 1.1;
}

.brand-mini-text strong {
    font-size: 1rem;
    font-weight: 700;
    color: #222;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.brand-mini-text small {
    margin-top: 2px;
    color: #7b7b7b;
    font-size: 0.82rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* =========================
   Shop header desktop
========================= */
.site-header.shop-header {
    position: sticky;
    top: 0;
    z-index: 100;
    width: 100%;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
}

.shop-header-desktop {
    display: block;
}

.shop-header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 16px 0;
}

.shop-header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.shop-header-actions a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 999px;
    background: #f6f7f8;
    color: #4a4a4a;
    white-space: nowrap;
    transition: 0.2s ease;
    text-decoration: none;
    flex-shrink: 0;
}

.shop-header-actions a.active,
.shop-header-actions a:hover {
    background: var(--primary, #4caf50);
    color: #fff;
}

.shop-header-actions a i {
    font-size: 0.95rem;
}

.cart-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: #fff;
    color: var(--primary, #4caf50);
    font-size: 0.78rem;
    font-weight: 700;
}

/* =========================
   Shop header mobile
========================= */
.shop-header-mobile {
    display: none;
    position: sticky;
    top: 0;
    z-index: 101;
    background: rgba(245, 246, 247, 0.96);
    backdrop-filter: blur(10px);
    padding: 14px 0 10px;
}

.mobile-header-row {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 14px;
    flex-wrap: nowrap;
}

/* =========================
   Admin header
========================= */
.site-header.admin-header {
    position: sticky;
    top: 0;
    z-index: 110;
    width: 100%;
    background: #fff;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 16px 0;
}

.brand-area {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.brand-tagline {
    margin: 0;
    color: #7b7b7b;
    font-size: 0.9rem;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #ecf9ee;
    color: #256b2a;
    padding: 10px 14px;
    border-radius: 999px;
    font-weight: 600;
}

.user-pill i {
    font-size: 0.95rem;
}

.main-nav {
    display: flex;
    gap: 10px;
    padding: 0 0 16px;
    overflow-x: auto;
    scrollbar-width: thin;
}

.main-nav a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 14px;
    border-radius: 999px;
    background: #f6f7f8;
    color: #4a4a4a;
    white-space: nowrap;
    transition: 0.2s ease;
    text-decoration: none;
    flex-shrink: 0;
}

.main-nav a.active,
.main-nav a:hover {
    background: var(--primary, #4caf50);
    color: #fff;
}

.main-nav a i {
    font-size: 0.95rem;
}

/* =========================
   Flash messages
========================= */
.flash {
    margin: 0 0 16px;
    padding: 14px 16px;
    border-radius: 16px;
    font-size: 0.95rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
    background: #fff;
}

.flash.success {
    background: #ecf9ee;
    color: #256b2a;
    border: 1px solid #cfead3;
}

.flash.error {
    background: #fff1f1;
    color: #b42318;
    border: 1px solid #f3c7c7;
}

.flash.warning {
    background: #fff8e8;
    color: #9a6700;
    border: 1px solid #f0dfae;
}

.flash.info {
    background: #eef6ff;
    color: #175cd3;
    border: 1px solid #cfe0ff;
}

/* =========================
   Responsive
========================= */
@media (max-width: 767px) {
    .shop-header-desktop {
        display: none !important;
    }

    .shop-header-mobile {
        display: block !important;
    }
}

@media (max-width: 600px) {
    .mobile-header-row {
        gap: 12px;
    }

    .brand-mini {
        min-width: 0;
    }
}

@media (min-width: 768px) {
    .shop-header-desktop {
        display: block !important;
    }

    .shop-header-mobile {
        display: none !important;
    }
}