/*
 * Store archive and single product styles.
 */

.shop-layout {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 32px;
}

.shop-sidebar {
    position: -webkit-sticky;
    position: sticky;
    top: 132px;
    align-self: start;
}

.sidebar-search {
    margin-bottom: 28px;
}

.sidebar-search__label,
.sidebar-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    color: var(--dch-navy);
    font-size: 1.08rem;
    font-weight: 700;
}

/* Aggressive Sidebar Reset to beat theme-induced 'bubbles' */
.shop-sidebar .therapeutic-list {
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
    width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
    list-style: none !important;
}

.shop-sidebar .therapeutic-item {
    display: flex !important;
    width: 100% !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 12px 16px !important;
    border-radius: 12px !important;
    color: #475569 !important;
    background: transparent !important; /* Force transparent or reset background */
    border: none !important;
    box-shadow: none !important;
    text-decoration: none !important;
    transition: all 0.2s ease;
}

.shop-sidebar .therapeutic-item span {
    background: transparent !important; /* Kill theme inner-bubbles */
    padding: 0 !important;
    margin: 0 !important;
    border-radius: 0 !important;
    color: inherit !important;
}

.shop-sidebar .therapeutic-item:hover {
    background: #eef2f7 !important;
    color: var(--dch-navy) !important;
}

.shop-sidebar .therapeutic-item.active {
    background: var(--dch-navy) !important;
    color: #ffffff !important;
}

.shop-sidebar .therapeutic-item.active span {
    color: #ffffff !important;
}

.shop-sidebar .therapeutic-item .count {
    min-width: 28px !important;
    height: 28px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 999px !important;
    background: #f1f5f9 !important;
    color: #64748b !important;
    margin: 0 !important;
    padding: 0 !important;
    font-size: 0.75rem !important;
    font-weight: 700 !important;
}

.shop-sidebar .therapeutic-item.active .count {
    background: rgba(255, 255, 255, 0.2) !important;
    color: #ffffff !important;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(var(--dch-store-columns, 3), minmax(0, 1fr));
    gap: 24px;
}

.product-card {
    background: #ffffff;
    border: 1px solid #edf2f7;
    border-radius: 18px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.04);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-card:hover {
    box-shadow: 0 12px 24px rgba(38, 57, 151, 0.08);
    border-color: rgba(38, 57, 151, 0.1);
}

.product-card__image {
    aspect-ratio: 4 / 3;
    padding: 12px;
    border-radius: 12px;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.product-card__image img,
.product-single-gallery img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.4s ease;
}

.product-card:hover .product-card__image img {
    transform: scale(1.05);
}

.product-card__body {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-card__category {
    margin-bottom: 8px;
    color: var(--dch-navy);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.product-card__title {
    margin: 0 0 6px;
    color: #1a202c;
    font-size: var(--text-lg);
    font-weight: var(--dch-font-extrabold);
    line-height: var(--dch-leading-snug);
}

.product-card__generic {
    color: #718096;
    font-size: 0.9rem;
    font-style: italic;
    margin-bottom: 0;
}

.product-card__footer {
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.product-card__details {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--dch-red);
    font-weight: 700;
    transition: gap 0.2s ease;
}

.product-card__details:hover {
    gap: 10px;
    color: var(--dch-red);
}

.product-single-container {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 40px;
    padding: 48px 0;
}

.product-single-main {
    background: #ffffff;
    border-radius: 20px;
    padding: 32px;
    box-shadow: var(--dch-shadow-card);
    border: 1px solid #edf2f7;
}

.product-single-hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    margin-bottom: 48px;
    align-items: start;
}

.product-single-gallery {
    aspect-ratio: 1;
    padding: 24px;
    border-radius: 16px;
    background: #ffffff;
    border: 1px solid #f1f5f9;
    position: -webkit-sticky;
    position: sticky;
    top: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.product-single-header .cat {
    display: inline-block;
    margin-bottom: 12px;
    color: var(--dch-navy);
    font-size: var(--text-sm);
    font-weight: var(--dch-font-bold);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.product-single-header h1 {
    margin: 0 0 8px;
    font-size: var(--text-5xl);
    font-weight: var(--dch-font-extrabold);
    color: #1a202c;
    letter-spacing: -0.02em;
}

.product-single-header .generic {
    margin-bottom: 24px;
    color: #718096;
    font-size: var(--text-lg);
    font-style: italic;
}

.product-single-desc,
.product-single-desc p {
    color: #4a5568;
    font-size: 1.05rem;
    line-height: var(--dch-leading-relaxed);
    margin-bottom: 32px;
}

.product-feature-flags {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    font-weight: 600;
}

.flag-stock {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: #059669;
}

.flag-grade {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: var(--dch-navy);
}

.technical-specs-title {
    margin: 0 0 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--dch-navy);
    font-size: var(--text-xl);
    font-weight: var(--dch-font-bold);
}

.technical-specs-title i {
    color: var(--dch-red);
}

.specs-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    background: #f8fafc;
    border-radius: 16px;
    padding: 24px;
}

.spec-label {
    display: block;
    margin-bottom: 4px;
    color: #94a3b8;
    font-size: var(--text-xs);
    font-weight: var(--dch-font-semibold);
    text-transform: uppercase;
}

.spec-value {
    color: #1e293b;
    font-size: var(--text-base);
    font-weight: var(--dch-font-medium);
}

/* ── Product Overview (Technical Specifications) ── */
.dch-product-overview {
    margin-top: 40px;
    padding: 0;
}

.dch-product-overview__title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--dch-navy, #263997);
    margin: 0 0 20px;
}

.dch-product-overview__title i {
    color: var(--dch-red, #bf2527);
}

.dch-product-overview__content {
    background: #f8fafc;
    border-radius: 16px;
    padding: 24px 28px;
    border: 1px solid #edf2f7;
    color: #4a5568;
    line-height: 1.8;
    font-size: 1.05rem;
}

.dch-product-overview__content p {
    margin-bottom: 1.25em;
}

.dch-product-overview__content p:last-child {
    margin-bottom: 0;
}

.related-products {
    margin-top: 60px;
}

.related-products h2 {
    margin-bottom: 32px;
    text-align: center;
    color: var(--dch-navy);
}

@media (max-width: 1024px) {
    .shop-layout,
    .product-single-hero {
        grid-template-columns: 1fr;
    }

    .shop-sidebar,
    .product-single-gallery {
        position: static;
    }
}

@media (max-width: 768px) {
    .products-grid,
    .specs-grid {
        grid-template-columns: 1fr;
    }
}


/* ── Badges Summary Top Row ── */
.dch-badges-summary-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem;
    justify-content: center;
    margin-bottom: 2rem;
}

.dch-badge-card {
    background: #fff;
    border-radius: 12px;
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease;
    min-width: 220px;
}

.dch-badge-card:hover {
    transform: translateY(-3px);
}

.dch-badge-card__icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.dch-badge-card--offer .dch-badge-card__icon { color: #bf2527; background: rgba(191, 37, 39, 0.1); }
.dch-badge-card--new .dch-badge-card__icon { color: #10b981; background: rgba(16, 185, 129, 0.1); }
.dch-badge-card--coming_soon .dch-badge-card__icon { color: #f59e0b; background: rgba(245, 158, 11, 0.1); }
.dch-badge-card--best_seller .dch-badge-card__icon { color: var(--dch-navy, #263997); background: rgba(38, 57, 151, 0.1); }

.dch-badge-card__title {
    margin: 0 0 0.25rem;
    font-size: 1rem;
    font-weight: 700;
    color: var(--dch-navy, #263997);
}

.dch-badge-card__count {
    font-size: 0.85rem;
    color: #64748b;
}

@media (max-width: 768px) {
    .dch-badges-summary-row {
        gap: 1rem;
    }
    .dch-badge-card {
        width: 100%;
        min-width: unset;
    }
}
