/*
 * ============================================================
 * Ahmadiyad - Premium Women's Undergarments E-Commerce
 * Developed by: Etarnity Global Innovation
 * Website: https://etarnity.com
 * ============================================================
 */

/* ============================================================
 * TABLET (max-width: 1024px)
 * ============================================================
 */
@media (max-width: 1024px) {
    .navbar-container {
        gap: 12px;
        padding: 0 16px;
    }

    .brand-name {
        font-size: 20px;
    }

    .search-bar {
        max-width: 400px;
    }

    .all-products-btn span {
        display: none;
    }

    .all-products-btn {
        padding: 10px 12px;
    }

    .nav-btn {
        padding: 9px 16px;
        font-size: 12px;
    }

    /* Hero: reduce height + side card width */
    .hero-container {
        padding: 0 16px;
    }

    .hero-grid {
        height: 340px;
        gap: 12px;
    }

    .hero-side-cards {
        width: 240px;
    }

    /* Category: 4-col main grid on tablet */
    .main-cat-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 12px;
    }

    /* Category blocks: 3-col product grid on tablet */
    .cat-block-products {
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
    }

    .cat-block-banner {
        height: 180px;
    }

    .cat-block-banner-text h3 {
        font-size: 26px;
    }

    /* ---- FOOTER (Tablet) ---- */
    .footer-main {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
        padding: 40px 20px 32px;
    }

    .footer-newsletter-form input {
        width: 260px;
    }

    /* ---- PRODUCT DETAIL (Tablet) ---- */
    .pdp-layout {
        gap: 32px;
    }

    .pdp-thumb {
        width: 60px;
        height: 75px;
    }

    .pdp-name {
        font-size: 22px;
    }

    .pdp-related-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
    }

}

/* ============================================================
 * MOBILE (max-width: 768px)
 * ============================================================
 */
@media (max-width: 768px) {
    :root {
        --navbar-height: 60px;
    }

    /* --- Show/Hide Controls --- */
    .hamburger {
        display: flex !important;
    }

    .mobile-only {
        display: flex !important;
    }

    .desktop-only {
        display: none !important;
    }

    .bottom-nav {
        display: flex;
    }

    /* --- Floating Cart: hidden on mobile, bottom nav cart badge used instead --- */
    .floating-cart {
        display: none !important;
    }

    /* --- Hero Section: Stack vertically, slider full width + 2-col grid --- */
    .hero-section {
        padding: 12px 0;
    }

    .hero-container {
        padding: 0 16px;
    }

    .hero-grid {
        flex-direction: column;
        height: auto;
        gap: 12px;
    }

    .hero-slider {
        height: 200px;
        border-radius: var(--radius);
    }

    /* Arrows hidden on mobile */
    .hero-slider-arrow {
        display: none !important;
    }

    .hero-slider-dots {
        bottom: 10px;
    }

    .hero-slider-dot {
        width: 22px;
        height: 5px;
        border-radius: 3px;
    }

    .hero-slider-dot.active {
        width: 30px;
    }

    /* Side cards: 2-column grid below slider */
    .hero-side-cards {
        width: 100%;
        flex-direction: row;
        gap: 12px;
    }

    .hero-side-card {
        flex: 1;
        min-width: 0;
        height: 140px;
    }

    /* --- Category Section --- */
    .category-section {
        padding: 24px 0;
    }

    .category-container {
        padding: 0 16px;
    }

    .category-header {
        margin-bottom: 20px;
    }

    .category-header-text h2 {
        font-size: 20px;
    }

    .main-cat-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 10px;
    }

    .main-cat-card {
        padding: 14px 8px;
        gap: 8px;
    }

    .main-cat-card .cat-icon {
        width: 40px;
        height: 40px;
    }

    .main-cat-card .cat-name {
        font-size: 11px;
    }

    /* ============================================================
     * CATEGORY BLOCKS (Mobile) — CRITICAL FIXES
     * ============================================================ */

    /* 1. HIDE banner image completely on mobile — show text-only title */
    .cat-block-banner {
        display: none !important;
    }

    /* 2. Show text-only title on mobile */
    .cat-block-title {
        display: block !important;
    }

    .cat-block {
        margin-bottom: 32px;
    }

    /* 3. 2-column product grid on mobile — products show with their images */
    .cat-block-products {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px !important;
        margin-bottom: 16px;
    }

    /* 4. Compact product cards on mobile */
    .product-card-info {
        padding: 10px 10px 12px;
    }

    .product-card-name {
        font-size: 12px;
        line-height: 1.35;
        margin-bottom: 4px;
    }

    .product-card-price {
        font-size: 16px;
    }

    .product-card-price .currency {
        font-size: 12px;
    }

    .product-card-wishlist {
        width: 28px;
        height: 28px;
        font-size: 13px;
        top: 8px;
        right: 8px;
    }

    .product-card {
        border-radius: var(--radius);
    }

    .seeall-btn {
        padding: 9px 22px;
        font-size: 12px;
    }

    /* --- Bottom Nav hover effect for touch devices --- */
    .bottom-nav-item:hover {
        background: rgba(213, 0, 109, 0.06);
        border-radius: 8px;
    }

    /* --- Navbar Adjustments --- */
    .navbar-container {
        padding: 0 16px;
        gap: 8px;
        justify-content: space-between;
    }

    .brand-name {
        font-size: 22px;
    }

    .navbar-center {
        display: none;
    }

    /* --- Body padding for bottom nav --- */
    body {
        padding-bottom: calc(var(--bottom-nav-height) + env(safe-area-inset-bottom, 0));
    }

    /* --- Sidebar width --- */
    .sidebar {
        width: 280px;
    }

    /* --- Sidebar footer responsive --- */
    .sidebar-footer {
        padding: 14px 16px;
    }

    .sidebar-footer p {
        font-size: 12px;
        margin-bottom: 10px;
    }

    .sidebar-auth-btn {
        padding: 9px 12px;
        font-size: 12px;
    }

    /* --- Main content adjust --- */
    .main-content {
        min-height: calc(100vh - var(--navbar-height) - 200px - var(--bottom-nav-height));
    }

    /* ============================================================
     * ALL PRODUCTS PAGE (Mobile)
     * ============================================================ */
    .ap-filter-toggle {
        display: flex;
    }

    .ap-top-filters {
        display: none; /* Hidden by default, toggled via Filters button */
        flex-direction: row;
        flex-wrap: nowrap;
        overflow-x: auto;
        align-items: center;
        gap: 10px;
        padding: 12px 16px;
        border-radius: 0;
        border: none;
        border-bottom: 1px solid rgba(0,0,0,0.06);
        box-shadow: none;
        margin: 0 -16px 20px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Firefox */
    }
    
    .ap-top-filters.mobile-open {
        display: flex;
    }

    .ap-top-filters::-webkit-scrollbar {
        display: none; /* Chrome/Safari */
    }

    .ap-top-filter-group {
        flex-direction: row;
        align-items: center;
        gap: 0;
        flex-shrink: 0;
    }
    
    .ap-top-filter-group label {
        display: none; /* Hide label to save space, rely on default option */
    }

    .ap-top-filter-group select {
        width: auto;
        min-width: unset;
        padding: 8px 30px 8px 16px;
        font-size: 13px;
        border-radius: 50px;
        background-color: var(--white);
        border: 1px solid rgba(0,0,0,0.1);
        box-shadow: 0 2px 6px rgba(0,0,0,0.04);
    }

    .ap-clear-all {
        margin-left: 0;
        width: auto;
        flex-shrink: 0;
        padding: 8px 16px;
        border-radius: 50px;
        font-size: 13px;
        text-align: center;
    }

    .ap-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    /* ============================================================
     * FOOTER (Mobile)
     * ============================================================ */
    .site-footer {
        margin-top: 40px;
    }

    .footer-newsletter {
        padding: 28px 0;
    }

    .footer-newsletter-inner {
        flex-direction: column;
        text-align: center;
        gap: 16px;
        padding: 0 16px;
    }

    .footer-newsletter-text h3 {
        font-size: 18px;
    }

    .footer-newsletter-form {
        width: 100%;
        max-width: 400px;
    }

    .footer-newsletter-form input {
        flex: 1;
        width: auto;
        min-width: 0;
        font-size: 13px;
        height: 44px;
    }

    .footer-newsletter-form button {
        height: 44px;
        padding: 0 16px;
        font-size: 12px;
    }

    .footer-main {
        grid-template-columns: 1fr 1fr;
        gap: 24px;
        padding: 32px 16px 28px;
    }

    .footer-brand-name {
        font-size: 24px;
    }

    .footer-brand-desc {
        font-size: 12px;
        margin-bottom: 16px;
    }

    .footer-col-title {
        font-size: 12px;
        margin-bottom: 14px;
        padding-bottom: 10px;
    }

    .footer-link {
        font-size: 12px;
    }

    .footer-bottom-inner {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

    .footer-copyright {
        font-size: 11px;
    }

    /* ============================================================
     * PRODUCT DETAIL (Mobile)
     * ============================================================ */
    .pdp-section {
        padding: 16px 0 40px;
    }

    .pdp-container {
        padding: 0 16px;
    }

    .pdp-breadcrumb {
        margin-bottom: 16px;
        gap: 6px;
    }

    .pdp-breadcrumb a,
    .pdp-container {
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 16px !important;
        box-sizing: border-box !important;
        overflow-x: hidden !important;
    }

    .pdp-breadcrumb {
        width: 100% !important;
        max-width: 100% !important;
        overflow-wrap: anywhere !important;
        word-break: break-word !important;
        gap: 6px !important;
        margin-bottom: 16px !important;
    }

    .pdp-breadcrumb span {
        font-size: 11px;
    }

    /* Stack layout on mobile — thumbnails horizontal below main image */
    .pdp-layout {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        max-width: 100% !important;
        gap: 24px !important;
        box-sizing: border-box !important;
    }

    /* Mobile: gallery reverts to column — main image FIRST, thumbnails BELOW */
    .pdp-gallery {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 auto !important;
        gap: 12px !important;
        box-sizing: border-box !important;
    }

    /* Main image appears first on mobile */
    .pdp-main-image {
        order: -1 !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 auto !important;
        position: relative !important;
    }

    .pdp-main-img-inner {
        width: 100% !important;
        max-width: 100% !important;
        aspect-ratio: 4 / 5;
        max-height: 480px;
        border-radius: var(--radius);
        margin: 0 auto !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        box-sizing: border-box !important;
    }

    /* Thumbnails horizontal row below image on mobile */
    .pdp-thumbnails {
        display: flex !important;
        flex-direction: row !important;
        order: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
        gap: 8px !important;
        overflow-x: auto !important;
        scrollbar-width: none !important;
        -webkit-overflow-scrolling: touch !important;
    }

    .pdp-thumbnails::-webkit-scrollbar {
        display: none !important;
    }

    .pdp-wishlist-btn {
        top: 12px;
        right: 12px;
        width: 36px;
        height: 36px;
        font-size: 16px;
    }

    .pdp-thumb {
        width: 56px !important;
        height: 70px !important;
        flex-shrink: 0 !important;
        border-radius: 8px;
    }

    .pdp-info {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        overflow-wrap: anywhere !important;
        word-break: break-word !important;
        padding-top: 0 !important;
    }

    .pdp-category-tag {
        font-size: 10px;
        padding: 4px 10px;
        margin-bottom: 8px;
    }

    .pdp-name {
        font-size: 21px !important;
        line-height: 1.35 !important;
        margin-bottom: 12px !important;
        overflow-wrap: anywhere !important;
        word-break: break-word !important;
        hyphens: auto !important;
    }

    .pdp-rating-row {
        gap: 8px;
        margin-bottom: 12px;
    }

    .pdp-stars {
        font-size: 13px;
    }

    .pdp-rating-text {
        font-size: 12px;
    }

    .pdp-price {
        font-size: 24px;
    }

    .pdp-price .currency {
        font-size: 14px;
    }

    .pdp-price-regular {
        font-size: 14px;
    }

    .pdp-price-badge {
        font-size: 10px;
    }

    .pdp-description {
        font-size: 13px;
        line-height: 1.7;
        margin-bottom: 20px;
        padding-bottom: 20px;
    }

    .pdp-option-label {
        font-size: 12px;
        margin-bottom: 10px;
    }

    .pdp-sizes {
        gap: 8px;
        margin-bottom: 20px;
    }

    .pdp-size-btn {
        min-width: 46px;
        height: 40px;
        font-size: 12px;
        border-radius: 6px;
    }

    .pdp-colors {
        gap: 8px;
        margin-bottom: 20px;
    }

    .pdp-color-btn {
        width: 34px;
        height: 34px;
    }

    /* Live Stock Badge on Mobile */
    .pdp-stock-status-wrap {
        margin-bottom: 18px;
    }

    .pdp-stock-badge {
        display: inline-flex !important;
        align-items: center !important;
        gap: 8px !important;
        padding: 7px 14px !important;
        border-radius: 50px !important;
        font-size: 12px !important;
        font-weight: 700 !important;
        line-height: 1.4 !important;
    }

    /* Quantity Stepper on Mobile */
    .pdp-qty-wrap {
        display: flex !important;
        align-items: center !important;
        gap: 12px !important;
        margin-bottom: 20px !important;
    }

    .pdp-qty-stepper {
        display: inline-flex !important;
        align-items: center !important;
        border: 2px solid #E2E8F0 !important;
        border-radius: 12px !important;
        background: #FFFFFF !important;
        overflow: hidden !important;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04) !important;
    }

    .pdp-qty-btn {
        width: 44px !important;
        height: 44px !important;
        border: none !important;
        background: #F8FAFC !important;
        font-size: 18px !important;
        font-weight: 700 !important;
        color: #0F172A !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        cursor: pointer !important;
        -webkit-tap-highlight-color: transparent;
    }

    .pdp-qty-btn:active {
        background: #CBD5E1 !important;
        transform: scale(0.94);
    }

    .pdp-qty-input {
        width: 50px !important;
        height: 44px !important;
        border: none !important;
        text-align: center !important;
        font-size: 16px !important;
        font-weight: 800 !important;
        color: #0F172A !important;
        background: #FFFFFF !important;
        outline: none !important;
    }

    /* Mobile: Side by side — Add to Cart (LEFT) + Buy Now (RIGHT) */
    .pdp-actions {
        display: flex !important;
        flex-direction: row !important;
        gap: 10px !important;
        margin-bottom: 16px !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    /* Reset order: HTML order = Add to Cart first (left), Buy Now second (right) */
    .pdp-addcart-btn {
        order: 0 !important;
        flex: 1 1 50% !important;
        min-width: 0 !important;
        max-width: calc(50% - 5px) !important;
        height: 50px !important;
        font-size: 13.5px !important;
        font-weight: 700 !important;
        gap: 6px !important;
        border-radius: 12px !important;
        background: var(--text, #4A1F27) !important;
        color: #FFFFFF !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        box-sizing: border-box !important;
        -webkit-tap-highlight-color: transparent;
    }

    .pdp-addcart-btn:active {
        transform: scale(0.96);
    }

    .pdp-addcart-btn i {
        font-size: 16px !important;
    }

    .pdp-buynow-btn {
        order: 0 !important;
        flex: 1 1 50% !important;
        min-width: 0 !important;
        max-width: calc(50% - 5px) !important;
        height: 50px !important;
        justify-content: center !important;
        font-size: 13.5px !important;
        font-weight: 700 !important;
        gap: 6px !important;
        padding: 0 !important;
        border-radius: 12px !important;
        background: var(--secondary, #D5006D) !important;
        color: #FFFFFF !important;
        display: flex !important;
        align-items: center !important;
        box-sizing: border-box !important;
        -webkit-tap-highlight-color: transparent;
    }

    .pdp-buynow-btn:active {
        transform: scale(0.96);
    }

    .pdp-buynow-btn i {
        font-size: 16px !important;
    }

    .pdp-delivery-info {
        padding: 16px;
        gap: 10px;
    }

    .pdp-delivery-item {
        font-size: 12px;
        gap: 10px;
    }

    .pdp-delivery-item i {
        font-size: 16px;
        width: 20px;
    }

    /* Related Products */
    .pdp-related {
        margin-top: 40px;
        padding-top: 28px;
    }

    .pdp-related-header h2 {
        font-size: 18px;
    }

    .pdp-related-grid {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px !important;
    }


/* ============================================================
     * LONG DESCRIPTION (Mobile)
     * ============================================================ */
    .pdp-long-desc {
        margin-top: 32px;
        padding-top: 28px;
    }

    .pdp-section-title h2 {
        font-size: 17px;
        padding-bottom: 10px;
    }

    .pdp-section-title h2::after {
        width: 32px;
        height: 2.5px;
    }

    .pdp-long-desc-content {
        font-size: 13px;
        line-height: 1.75;
    }

    .pdp-long-desc-content p {
        margin-bottom: 14px;
    }

    /* ============================================================
     * REVIEWS SECTION (Mobile)
     * ============================================================ */
    .pdp-reviews {
        margin-top: 32px;
        padding-top: 28px;
    }

    .page-back-btn {
        display: none !important;
    }

    .pdp-reviews-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        margin-bottom: 24px;
    }

    .pdp-reviews-summary {
        gap: 8px;
    }

    .pdp-reviews-avg {
        font-size: 24px;
    }

    .pdp-reviews-stars {
        font-size: 14px;
    }

    .pdp-reviews-count-text {
        font-size: 12px;
    }

    .pdp-review-card {
        padding: 18px;
        border-radius: var(--radius);
    }

    .pdp-review-top {
        gap: 10px;
        margin-bottom: 12px;
    }

    .pdp-review-avatar {
        width: 38px;
        height: 38px;
        font-size: 14px;
    }

    .pdp-review-name {
        font-size: 13px;
    }

    .pdp-verified-badge {
        font-size: 10px;
        padding: 2px 6px;
    }

    .pdp-review-date {
        font-size: 11px;
    }

    .pdp-review-rating {
        font-size: 13px;
    }

    .pdp-review-text {
        font-size: 13px;
        line-height: 1.7;
    }

    .pdp-review-images {
        gap: 8px;
        margin-top: 12px;
    }

    .pdp-review-img {
        width: 68px;
        height: 68px;
        border-radius: 8px;
    }

    .pdp-helpful-btn {
        font-size: 11px;
        padding: 5px 12px;
    }

    /* Review CTA & Status Cards on Mobile */
    .pdp-reviews-cta {
        margin-top: 24px !important;
        width: 100% !important;
    }

    .pdp-review-card-status {
        display: flex !important;
        flex-direction: column !important;
        align-items: stretch !important;
        padding: 20px !important;
        border-radius: 16px !important;
        gap: 16px !important;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05) !important;
        box-sizing: border-box !important;
    }

    .pdp-status-main {
        display: flex !important;
        align-items: center !important;
        gap: 14px !important;
        width: 100% !important;
    }

    .pdp-status-icon {
        width: 44px !important;
        height: 44px !important;
        font-size: 20px !important;
        margin-bottom: 2px !important;
    }

    .pdp-status-body h4 {
        font-size: 15px !important;
        font-weight: 700 !important;
        margin: 0 0 4px !important;
    }

    .pdp-status-body p {
        font-size: 13px !important;
        line-height: 1.5 !important;
        color: #64748B !important;
        margin: 0 !important;
    }

    .pdp-write-review-btn {
        width: 100% !important;
        min-height: 48px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        font-size: 14px !important;
        font-weight: 700 !important;
        color: #FFFFFF !important;
        background: var(--secondary, #D5006D) !important;
        border: 2px solid var(--secondary, #D5006D) !important;
        border-radius: 12px !important;
        padding: 12px 20px !important;
        cursor: pointer !important;
        box-sizing: border-box !important;
        box-shadow: 0 4px 14px rgba(213, 0, 109, 0.25) !important;
        -webkit-tap-highlight-color: transparent;
    }

    .pdp-write-review-btn:active {
        transform: scale(0.97) !important;
    }

    .pdp-review-buy-btn {
        width: 100% !important;
        min-height: 48px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
        font-size: 14px !important;
        font-weight: 700 !important;
        color: #FFFFFF !important;
        background: #0F172A !important;
        border: 2px solid #0F172A !important;
        border-radius: 12px !important;
        padding: 12px 20px !important;
        cursor: pointer !important;
        box-sizing: border-box !important;
        box-shadow: 0 4px 14px rgba(15, 23, 42, 0.2) !important;
        -webkit-tap-highlight-color: transparent;
    }

    .pdp-review-buy-btn:active {
        transform: scale(0.97) !important;
        background: var(--secondary, #D5006D) !important;
        border-color: var(--secondary, #D5006D) !important;
    }

    .pdp-review-login-btn {
        width: 100% !important;
        min-height: 48px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
        font-size: 14px !important;
        font-weight: 700 !important;
        color: #FFFFFF !important;
        background: #0F172A !important;
        border: 2px solid #0F172A !important;
        border-radius: 12px !important;
        padding: 12px 20px !important;
        text-decoration: none !important;
        box-sizing: border-box !important;
        box-shadow: 0 4px 14px rgba(15, 23, 42, 0.2) !important;
        -webkit-tap-highlight-color: transparent;
    }

    .pdp-review-login-btn:active {
        transform: scale(0.97) !important;
        background: var(--secondary, #D5006D) !important;
        border-color: var(--secondary, #D5006D) !important;
    }

    /* ============================================================
     * IMAGE ZOOM: handled by JS (panel on body), no CSS override needed
     * ============================================================ */
    .pdp-main-image {
        cursor: pointer;
    }

    /* ============================================================
     * MOBILE VIEWER (Mobile only)
     * ============================================================ */
    .pdp-viewer-nav {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }

    .pdp-viewer-close {
        top: 12px;
        right: 12px;
        width: 36px;
        height: 36px;
        font-size: 16px;
    }

    .pdp-viewer-counter {
        bottom: 20px;
        font-size: 12px;
    }
}

/* ============================================================
 * SMALL MOBILE (max-width: 380px)
 * ============================================================
 */
@media (max-width: 380px) {
    .brand-name {
        font-size: 16px;
    }

    .navbar-container {
        gap: 6px;
        padding: 0 12px;
    }

    .nav-icon {
        width: 36px;
        height: 36px;
        font-size: 17px;
    }

    .mobile-search-toggle {
        width: 36px;
        height: 36px;
        font-size: 17px;
    }

    .hamburger {
        width: 36px;
        height: 36px;
    }

    .hamburger span {
        width: 18px;
    }

    .sidebar {
        width: 260px;
    }

    .sidebar-footer {
        padding: 12px 14px;
    }

    .sidebar-auth-btns {
        flex-direction: column;
        gap: 6px;
    }

    .sidebar-auth-btn {
        padding: 10px;
        font-size: 12px;
    }

    /* Even more compact product cards on small mobile */
    .product-card-name {
        font-size: 11px;
    }

    .product-card-price {
        font-size: 15px;
    }

    .product-card-info {
        padding: 8px 8px 10px;
    }

    .cat-block-products {
        gap: 8px !important;
    }

    /* ---- FOOTER (Small Mobile) ---- */
    .footer-main {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .footer-newsletter-form input {
        font-size: 12px;
        height: 40px;
    }

    .footer-newsletter-form button {
        height: 40px;
        padding: 0 14px;
        font-size: 11px;
    }

    /* ---- PDP (Small Mobile) ---- */
    .pdp-name {
        font-size: 18px;
    }

    .pdp-price {
        font-size: 22px;
    }

    .pdp-size-btn {
        min-width: 42px;
        height: 38px;
        font-size: 11px;
    }
}

/* ============================================================
 * LARGE DESKTOP (min-width: 1400px)
 * ============================================================
 */
@media (min-width: 1400px) {
    .search-bar {
        max-width: 700px;
    }
}

/* ============================================================
 * SAFE AREA (iPhone notch etc)
 * ============================================================
 */
@supports (padding-top: env(safe-area-inset-top)) {
    .navbar {
        padding-top: env(safe-area-inset-top);
    }

    .mobile-search-bar {
        padding-top: calc(12px + env(safe-area-inset-top));
    }

    .sidebar {
        padding-top: env(safe-area-inset-top);
    }
}

/* ============================================================
* HOVER MEDIA QUERY (disable hover on touch devices)
* ============================================================
*/
@media (hover: none) {
    .sidebar-link:hover,
    .subcategory-list a:hover,
    .category-header:hover {
        background: transparent;
    }

    .sidebar-link:active,
    .subcategory-list a:active,
    .category-header:active {
        background: rgba(213, 0, 109, 0.08);
    }
}

/* ============================================================
 * ALL PRODUCTS PAGE — Responsive
 * ============================================================ */

/* Tablet */
@media (max-width: 1024px) {
    .ap-layout {
        grid-template-columns: 220px 1fr;
        gap: 24px;
    }

    .ap-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Mobile */
@media (max-width: 768px) {
    .ap-filter-toggle {
        display: flex;
    }

    .ap-sort select {
        max-width: 160px;
    }

    .ap-layout {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    /* Sidebar: slide-in from left on mobile */
    .ap-sidebar {
        position: fixed;
        top: 0;
        left: -300px;
        width: 280px;
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
        z-index: 999;
        transition: left 0.3s ease;
        box-shadow: none;
    }

    .ap-sidebar.mobile-open {
        left: 0;
        box-shadow: 4px 0 24px rgba(0, 0, 0, 0.15);
    }

    .ap-grid {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px !important;
    }

    .ap-title {
        font-size: 20px;
    }

    .all-products-container {
        padding: 0 16px;
    }

    .all-products-section {
        padding: 16px 0 40px;
    }
}

@media (max-width: 380px) {
    .ap-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
    }
}

/* ============================================================
 * AUTH PAGES — Responsive
 * ============================================================ */
@media (max-width: 768px) {
    .auth-section {
        padding: 20px 16px 40px;
        align-items: flex-start;
        padding-top: 24px;
    }

    .auth-card {
        padding: 28px 22px;
    }

    .auth-card--register {
        padding: 24px 20px;
    }

    .auth-form-title {
        font-size: 20px;
    }

    .auth-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .auth-brand-name {
        font-size: 30px;
    }

    .auth-extras {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
}

@media (max-width: 380px) {
    .auth-card {
        padding: 24px 16px;
    }

    .auth-input-wrap {
        height: 42px;
        padding: 0 12px;
    }

    .auth-submit-btn,
    .auth-google-btn {
        height: 44px;
        font-size: 13px;
    }
}

/* ============================================================
 * UNIVERSAL VIEWPORT & ZERO HORIZONTAL OVERFLOW SYSTEM
 * ============================================================ */
html, body {
    width: 100% !important;
    max-width: 100vw !important;
    overflow-x: hidden !important;
    box-sizing: border-box !important;
    -webkit-text-size-adjust: 100%;
}

*, *::before, *::after {
    box-sizing: border-box !important;
}

.site-container, .site-main, .main-content, .hero-section, .category-section {
    max-width: 100% !important;
    overflow-x: hidden !important;
}

/* ============================================================
 * MULTI-STEP CHECKOUT & PAYMENT (Mobile Optimization)
 * ============================================================ */
@media (max-width: 900px) {
    .checkout-grid {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
    .checkout-summary-section {
        position: static !important;
        order: 2;
    }
    .step-pill span:not(.step-number) {
        font-size: 12px !important;
    }
}

@media (max-width: 580px) {
    .checkout-grid {
        display: flex !important;
        flex-direction: column !important;
    }
    div[style*="display:grid; grid-template-columns: 1fr 1fr"],
    div[style*="display:grid; grid-template-columns:1fr 1fr"] {
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }
    .step-pill {
        font-size: 11px !important;
    }
    .payment-card-option {
        padding: 14px 12px !important;
    }
}

/* ============================================================
 * USER PROFILE, ORDERS & ADDRESSES (Mobile Optimization)
 * ============================================================ */
@media (max-width: 768px) {
    .profile-layout-grid,
    .addresses-grid,
    .orders-layout-grid {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }
    .profile-sidebar {
        width: 100% !important;
        margin-bottom: 16px;
    }
    .order-card-header,
    .order-detail-header {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 10px !important;
    }
}

/* ============================================================
 * CART & WISHLIST (Mobile Optimization)
 * ============================================================ */
@media (max-width: 768px) {
    .cart-page-grid {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
    .cart-item-card {
        padding: 12px !important;
    }
}



