/* ============================================================
   UNISHOP — PREMIUM MOBILE SHOP & CATEGORY PAGE
   Inspired by Flipkart, Ajio, Amazon, Myntra mobile UX
   All rules scoped inside @media (max-width: 991.98px)
   Desktop layout is NEVER affected.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

/* ────────────────────────────────────────────────────────────
   PAGE WRAPPER
   ──────────────────────────────────────────────────────────── */
@media (max-width: 991.98px) {

    body {
        background: #f4f4f4 !important;

    }

    /* Hide desktop page-header, sort bar */
    .page-header {
        display: none !important;
    }

    .section-margin {
        margin-top: 0 !important;
        padding-top: 0 !important;
    }

    .container {
        padding-left: 0 !important;
        padding-right: 0 !important;
        max-width: 100% !important;
    }

    .shop-sort-bar {
        display: none !important;
    }

    /* ────────────────────────────────────────────────────────────
   MOBILE SHOP HEADER BAR
   ──────────────────────────────────────────────────────────── */
    .mob-shop-header {
        display: flex;
        align-items: center;
        gap: 10px;
        background: #0a4455;
        color: #fff;
        padding: 14px 16px;
        font-family: 'Inter', sans-serif;
        position: sticky;
        top: 0;
        z-index: 200;
    }

    .mob-shop-header .mob-page-title {
        font-size: 16px;
        font-weight: 700;
        color: #fff;
        margin: 0;
        flex: 1;
    }

    .mob-shop-header .mob-product-count {
        font-size: 11px;
        color: rgba(255, 255, 255, 0.65);
        white-space: nowrap;
    }

    /* ────────────────────────────────────────────────────────────
   SUBCATEGORY PILL CHIP ROW (category page)
   ──────────────────────────────────────────────────────────── */
    .mob-subcategory-pills {
        display: flex;
        gap: 8px;
        overflow-x: auto;
        padding: 10px 16px;
        background: #fff;
        border-bottom: 1px solid #e8ecef;
        scrollbar-width: none;
        -ms-overflow-style: none;
        white-space: nowrap;
        -webkit-overflow-scrolling: touch;
    }

    .mob-subcategory-pills::-webkit-scrollbar {
        display: none;
    }

    .mob-subcategory-pill {
        flex-shrink: 0;
        display: inline-flex;
        align-items: center;
        gap: 4px;
        padding: 6px 14px;
        border-radius: 20px;
        border: 1.5px solid #e8ecef;
        background: #fff;
        font-size: 12px;
        font-weight: 600;
        color: #374151;
        text-decoration: none;
        cursor: pointer;
        transition: all 0.15s ease;
        font-family: 'Inter', sans-serif;
    }

    .mob-subcategory-pill.active,
    .mob-subcategory-pill:hover {
        background: #0a4455;
        border-color: #0a4455;
        color: #fff;
    }

    /* ────────────────────────────────────────────────────────────
   ACTIVE FILTER TAGS STRIP
   ──────────────────────────────────────────────────────────── */
    .mob-active-filters {
        display: none;
        gap: 8px;
        overflow-x: auto;
        padding: 8px 16px;
        background: #fff;
        border-bottom: 1px solid #e8ecef;
        scrollbar-width: none;
        white-space: nowrap;
    }

    .mob-active-filters::-webkit-scrollbar {
        display: none;
    }

    .mob-active-filters.has-filters {
        display: flex;
    }

    .mob-filter-tag {
        flex-shrink: 0;
        display: inline-flex;
        align-items: center;
        gap: 5px;
        padding: 4px 10px;
        border-radius: 20px;
        background: #e0f2fe;
        color: #0369a1;
        font-size: 11px;
        font-weight: 600;
        font-family: 'Inter', sans-serif;
    }

    .mob-filter-tag button {
        background: none;
        border: none;
        padding: 0;
        color: #0369a1;
        cursor: pointer;
        font-size: 11px;
        line-height: 1;
    }

    /* ────────────────────────────────────────────────────────────
   PRODUCT RESULT COUNT BAR
   ──────────────────────────────────────────────────────────── */
    .mob-result-bar {
        padding: 8px 16px 4px;
        background: #f4f4f4;
        font-size: 12px;
        color: #6b7280;
        font-family: 'Inter', sans-serif;
        font-weight: 500;
    }

    /* ────────────────────────────────────────────────────────────
   PRODUCT GRID (2-column premium)
   ──────────────────────────────────────────────────────────── */
    #shopProductsGrid.row {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px !important;
        padding: 10px !important;
        margin: 0 !important;
    }

    #shopProductsGrid.row>[class*='col'] {
        width: 100% !important;
        max-width: 100% !important;
        flex: none !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    /* ────────────────────────────────────────────────────────────
   PREMIUM PRODUCT CARD
   ──────────────────────────────────────────────────────────── */
    .shop-products-area .product-card {
        background: #fff !important;
        border: 1px solid #edf2f7 !important;
        border-radius: 12px !important;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04) !important;
        padding: 6px !important;
        overflow: hidden !important;
        display: flex !important;
        flex-direction: column !important;
        height: 276px !important;
        /* Strict equal heights */
        width: 100% !important;
        cursor: pointer !important;
        position: relative !important;
        justify-content: space-between !important;
        transition: transform 0.15s ease, box-shadow 0.15s ease !important;
        font-family: 'Inter', sans-serif !important;
    }

    .shop-products-area .product-card:active {
        transform: scale(0.975) !important;
        box-shadow: 0 4px 20px rgba(10, 68, 85, 0.12) !important;
    }

    /* Image — square ratio, compact height */
    .shop-products-area .product-card .product-image {
        width: 100% !important;
        height: 130px !important;
        background: #f8fafc !important;
        border-radius: 8px !important;
        margin: 0 0 4px 0 !important;
        flex-shrink: 0 !important;
        position: relative !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        overflow: hidden;
    }

    .shop-products-area .product-card .product-image img {
        max-height: 120px !important;
        max-width: 100% !important;
        width: auto !important;
        height: auto !important;
        object-fit: contain !important;
        display: block !important;
    }

    .shop-products-area .product-card .product-image .overlay,
    .shop-products-area .product-card .product-image .hover-icons {
        display: none !important;
    }

    /* Discount badge */
    .shop-products-area .product-card .pc-discount-badge {
        position: absolute !important;
        top: 8px !important;
        left: 8px !important;
        background: #f97316 !important;
        color: #fff !important;
        font-size: 9px !important;
        font-weight: 800 !important;
        padding: 2px 7px !important;
        border-radius: 4px !important;
        z-index: 3 !important;
        letter-spacing: 0.3px !important;
        font-family: 'Inter', sans-serif !important;
    }

    /* Wishlist heart */
    .shop-products-area .product-card .mobile-wishlist-btn {
        position: absolute !important;
        top: 8px !important;
        right: 8px !important;
        z-index: 10 !important;
        border: none !important;
        background: rgba(255, 255, 255, 0.9) !important;
        width: 28px !important;
        height: 28px !important;
        border-radius: 50% !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1) !important;
        padding: 0 !important;
        outline: none !important;
        cursor: pointer !important;
        transition: transform 0.15s ease !important;
    }

    .shop-products-area .product-card .mobile-wishlist-btn:active {
        transform: scale(0.88) !important;
    }

    .shop-products-area .product-card .mobile-wishlist-btn i {
        font-size: 13px !important;
        color: #64748b !important;
        transition: color 0.2s !important;
    }

    .shop-products-area .product-card .mobile-wishlist-btn i.fa-solid.fa-heart,
    .shop-products-area .product-card .mobile-wishlist-btn i.text-danger {
        color: #ef4444 !important;
    }

    /* Product info */
    .shop-products-area .product-card .product-info {
        padding: 4px 6px !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        flex-grow: 1 !important;
        justify-content: flex-start !important;
        /* Do not stretch elements */
    }

    .shop-products-area .product-card .product-image a {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: 100% !important;
        height: 100% !important;
    }

    .shop-products-area .product-card .product-image img {
        max-height: 100% !important;
        max-width: 100% !important;
        width: auto !important;
        height: auto !important;
        object-fit: contain !important;
        display: block !important;
    }

    .shop-products-area .product-card .product-info h4 {
        font-size: 11px !important;
        font-weight: 600 !important;
        color: #1e293b !important;
        margin: 0 0 4px 0 !important;
        line-height: 1.3 !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
        height: 30px !important;
        /* Fixed height for 2 lines */
        text-align: center !important;
        font-family: 'Inter', sans-serif !important;
    }

    .shop-products-area .product-card .product-info h4 a {
        color: inherit !important;
        text-decoration: none !important;
    }

    /* Price block — compact, centered */
    .shop-products-area .product-card .pc-price-block {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 6px !important;
        flex-wrap: wrap !important;
        margin-bottom: 6px !important;
        padding-bottom: 0 !important;
    }

    .shop-products-area .product-card .pc-final-price {
        font-size: 15px !important;
        font-weight: 700 !important;
        color: #2563eb !important;
        font-family: 'Inter', sans-serif !important;
        line-height: 1.1 !important;
        display: inline !important;
        width: auto !important;
    }

    .shop-products-area .product-card .pc-mrp-price {
        font-size: 11px !important;
        color: #94a3b8 !important;
        text-decoration: line-through !important;
        font-weight: 500 !important;
    }

    .shop-products-area .product-card .pc-discount-pct {
        font-size: 11px !important;
        font-weight: 700 !important;
        color: #16a34a !important;
        background: none !important;
        padding: 0 !important;
        border-radius: 0 !important;
        display: inline !important;
    }

    /* Integrated Add to Cart buttons & stock status inside the card */
    .shop-products-area .product-card .pc-mob-footer {
        width: 100% !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        margin-top: auto !important;
        padding-top: 4px !important;
    }

    .shop-products-area .product-card .pc-mob-stock-status {
        margin-bottom: 4px !important;
        display: block !important;
    }

    .shop-products-area .product-card .pc-mob-buttons {
        width: 100% !important;
        display: flex !important;
        gap: 5px !important;
    }

    .shop-products-area .product-card .pc-mob-btn {
        height: 32px !important;
        border-radius: 6px !important;
        font-size: 11px !important;
        font-weight: 700 !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 4px !important;
        border: none !important;
        padding: 0 !important;
        transition: all 0.15s ease !important;
    }

    .shop-products-area .product-card .pc-mob-quickview-btn {
        flex: 1 !important;
        background: #f1f5f9 !important;
        color: #334155 !important;
        border: 1px solid #cbd5e1 !important;
    }

    .shop-products-area .product-card .pc-mob-quickview-btn:active {
        background: #e2e8f0 !important;
    }

    .shop-products-area .product-card .pc-mob-cart-btn {
        flex: 1 !important;
        height: 32px !important;
        border-radius: 6px !important;
        background: #0a4455 !important;
        border-color: #0a4455 !important;
        color: #fff !important;
        font-size: 11px !important;
        font-weight: 700 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 4px !important;
        box-shadow: 0 2px 5px rgba(10, 68, 85, 0.12) !important;
        padding: 0 !important;
    }

    .shop-products-area .product-card .pc-mob-cart-btn:active {
        background: #062f3d !important;
        border-color: #062f3d !important;
    }

    /* Hide the old sibling button */
    .shop-mob-cart-strip {
        display: none !important;
    }

    /* ────────────────────────────────────────────────────────────
   PAGINATION
   ──────────────────────────────────────────────────────────── */
    .shop-products-area .pagination-area {
        padding: 16px !important;
        gap: 6px !important;
        margin-top: 0 !important;
    }

    .shop-products-area .pagination-area a,
    .shop-products-area .pagination-area span {
        width: 36px !important;
        height: 36px !important;
        border-radius: 8px !important;
        font-size: 13px !important;
        font-weight: 600 !important;
    }

    /* ────────────────────────────────────────────────────────────
   STICKY SORT + FILTER BOTTOM BAR
   ──────────────────────────────────────────────────────────── */
    .mob-sort-filter-bar {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 99990;
        display: flex;
        background: #fff;
        border-top: 1.5px solid #e8ecef;
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.09);
        height: 52px;
        font-family: 'Inter', sans-serif;
    }

    .mob-sort-filter-bar .mob-bar-btn {
        flex: 1;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 7px;
        background: none;
        border: none;
        cursor: pointer;
        font-size: 13px;
        font-weight: 700;
        color: #374151;
        position: relative;
        transition: background 0.12s;
        padding: 0;
    }

    .mob-sort-filter-bar .mob-bar-btn:first-child {
        border-right: 1.5px solid #e8ecef;
    }

    .mob-sort-filter-bar .mob-bar-btn:active {
        background: #f9fafb;
    }

    .mob-sort-filter-bar .mob-bar-btn i {
        font-size: 15px;
        color: #0a4455;
    }

    .mob-sort-filter-bar .mob-filter-badge {
        position: absolute;
        top: 8px;
        right: calc(50% - 44px);
        background: #f97316;
        color: #fff;
        font-size: 9px;
        font-weight: 800;
        width: 16px;
        height: 16px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        line-height: 1;
    }

    /* ────────────────────────────────────────────────────────────
   BOTTOM SHEET OVERLAY
   ──────────────────────────────────────────────────────────── */
    .mob-bottom-sheet-overlay {
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.45);
        z-index: 99995;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.25s ease, visibility 0.25s ease;
    }

    .mob-bottom-sheet-overlay.active {
        opacity: 1;
        visibility: visible;
    }

    /* ────────────────────────────────────────────────────────────
   BOTTOM SHEET BASE
   ──────────────────────────────────────────────────────────── */
    .mob-bottom-sheet {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 99996;
        background: #fff;
        border-radius: 20px 20px 0 0;
        transform: translateY(100%);
        transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
        font-family: 'Inter', sans-serif;
        max-height: 90vh;
        overflow: hidden;
        display: flex;
        flex-direction: column;
    }

    .mob-bottom-sheet.active {
        transform: translateY(0);
    }

    .mob-sheet-handle {
        width: 40px;
        height: 4px;
        background: #d1d5db;
        border-radius: 2px;
        margin: 12px auto 0;
        flex-shrink: 0;
    }

    .mob-sheet-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 12px 20px 14px;
        border-bottom: 1px solid #f3f4f6;
        flex-shrink: 0;
    }

    .mob-sheet-header h4 {
        font-size: 16px;
        font-weight: 800;
        color: #1a1a2e;
        margin: 0;
    }

    .mob-sheet-close {
        background: #f3f4f6;
        border: none;
        border-radius: 50%;
        width: 32px;
        height: 32px;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        font-size: 15px;
        color: #374151;
    }

    /* ────────────────────────────────────────────────────────────
   SORT SHEET
   ──────────────────────────────────────────────────────────── */
    #mobSortSheet {
        max-height: 65vh;
    }

    .mob-sort-options {
        padding: 6px 0 16px;
        overflow-y: auto;
        flex: 1;
    }

    .mob-sort-option {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 14px 20px;
        cursor: pointer;
        border-bottom: 1px solid #f9fafb;
        font-size: 14px;
        font-weight: 500;
        color: #374151;
        transition: background 0.1s;
        gap: 10px;
    }

    .mob-sort-option:active {
        background: #f9fafb;
    }

    .mob-sort-option.active {
        color: #0a4455;
        font-weight: 700;
        background: #f0f9ff;
    }

    .mob-sort-radio {
        width: 20px;
        height: 20px;
        border-radius: 50%;
        border: 2px solid #d1d5db;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
        transition: border-color 0.15s, background 0.15s;
    }

    .mob-sort-option.active .mob-sort-radio {
        background: #0a4455;
        border-color: #0a4455;
    }

    .mob-sort-option.active .mob-sort-radio::after {
        content: '';
        width: 7px;
        height: 7px;
        background: #fff;
        border-radius: 50%;
        display: block;
    }

    /* ────────────────────────────────────────────────────────────
   FILTER SHEET — Two-panel Myntra/Ajio style
   ──────────────────────────────────────────────────────────── */
    #mobFilterSheet {
        max-height: 92vh;
    }

    .mob-filter-body {
        display: flex;
        flex: 1;
        overflow: hidden;
        min-height: 0;
    }

    .mob-filter-sections {
        width: 108px;
        flex-shrink: 0;
        border-right: 1px solid #f3f4f6;
        overflow-y: auto;
        background: #fafafa;
    }

    .mob-filter-section-tab {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        padding: 13px 10px 13px 14px;
        font-size: 12px;
        font-weight: 600;
        color: #6b7280;
        cursor: pointer;
        border-left: 3px solid transparent;
        gap: 3px;
        line-height: 1.3;
        transition: all 0.12s;
        border-bottom: 1px solid #f3f4f6;
    }

    .mob-filter-section-tab.active {
        color: #0a4455;
        border-left-color: #0a4455;
        background: #f0f9ff;
        font-weight: 700;
    }

    .mob-filter-count-badge {
        background: #f97316;
        color: #fff;
        font-size: 9px;
        padding: 1px 5px;
        border-radius: 10px;
        font-weight: 700;
        line-height: 1.4;
    }

    .mob-filter-options {
        flex: 1;
        overflow-y: auto;
        padding: 12px 14px;
    }

    .mob-filter-panel {
        display: none;
    }

    .mob-filter-panel.active {
        display: block;
    }

    /* Filter check items */
    .mob-filter-check-item {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 10px 2px;
        border-bottom: 1px solid #f9fafb;
        cursor: pointer;
        font-size: 13px;
        color: #374151;
        font-weight: 500;
    }

    .mob-filter-check-item input[type="checkbox"] {
        width: 18px;
        height: 18px;
        accent-color: #0a4455;
        flex-shrink: 0;
        cursor: pointer;
    }

    .mob-filter-check-item.checked {
        color: #0a4455;
        font-weight: 700;
    }

    /* Price range */
    .mob-price-filter {
        padding: 4px 0 10px;
    }

    .mob-price-filter input[type="range"] {
        width: 100%;
        accent-color: #0a4455;
        margin: 10px 0;
    }

    .mob-price-display {
        display: flex;
        justify-content: space-between;
        font-size: 12px;
        font-weight: 600;
        color: #0a4455;
        margin-top: 4px;
    }

    /* Rating filter */
    .mob-rating-item {
        display: flex;
        align-items: center;
        gap: 8px;
        padding: 11px 2px;
        border-bottom: 1px solid #f9fafb;
        cursor: pointer;
        font-size: 13px;
        font-weight: 500;
        color: #374151;
    }

    .mob-rating-item .stars {
        color: #f59e0b;
        font-size: 12px;
        letter-spacing: 1px;
    }

    .mob-rating-item input[type="checkbox"] {
        width: 18px;
        height: 18px;
        accent-color: #0a4455;
        flex-shrink: 0;
        cursor: pointer;
    }

    /* Filter footer */
    .mob-filter-footer {
        display: flex;
        gap: 10px;
        padding: 14px 16px;
        border-top: 1px solid #f3f4f6;
        background: #fff;
        flex-shrink: 0;
    }

    .mob-filter-footer .btn-clear {
        flex: 1;
        height: 44px;
        border: 1.5px solid #e8ecef;
        background: #fff;
        color: #374151;
        border-radius: 10px;
        font-size: 13px;
        font-weight: 700;
        cursor: pointer;
        font-family: 'Inter', sans-serif;
    }

    .mob-filter-footer .btn-apply {
        flex: 2;
        height: 44px;
        background: #0a4455;
        color: #fff;
        border: none;
        border-radius: 10px;
        font-size: 13px;
        font-weight: 700;
        cursor: pointer;
        font-family: 'Inter', sans-serif;
    }

    .mob-filter-footer .btn-apply:active {
        background: #062f3d;
    }

    .mob-filter-footer .btn-clear:active {
        background: #f9fafb;
    }

    /* ────────────────────────────────────────────────────────────
   EMPTY STATE
   ──────────────────────────────────────────────────────────── */
    .shop-products-area .col-12.text-center.py-5 {
        padding: 50px 20px !important;
    }

    .shop-products-area .col-12.text-center.py-5 p {
        font-size: 14px !important;
        color: #6b7280 !important;
        font-family: 'Inter', sans-serif !important;
    }

    /* ────────────────────────────────────────────────────────────
   SHOP SIDEBAR OVERRIDE — keep existing desktop logic
   ──────────────────────────────────────────────────────────── */
    .shop-sidebar {
        left: -320px !important;
        transition: left 0.3s ease !important;
    }

    .shop-sidebar.active {
        left: 0 !important;
    }

    /* Restore container padding inside footer sections on mobile */
    .site-footer .container {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }

}

/* end @media (max-width: 991.98px) */