@media (max-width: 576px) {
    .thankyou-section {
        padding: 28px 0 56px;
    }

    .thankyou-card,
    .thankyou-side-card {
        border-radius: 14px;
    }

    .thankyou-card,
    .thankyou-side-card {
        padding: 18px 16px;
    }

    .thankyou-title {
        font-size: 28px;
    }

    .thankyou-info-grid,
    .account-form-grid {
        grid-template-columns: 1fr;
    }

    .account-section {
        padding: 28px 0 56px;
    }

    .account-panel,
    .account-sidebar,
    .account-stat,
    .account-order-card,
    .account-info-card {
        border-radius: 14px;
    }

    .account-panel,
    .account-sidebar {
        padding: 18px 16px;
    }

    .account-title {
        font-size: 26px;
    }

    .account-stats,
    .account-grid-2,
    .account-summary-grid {
        grid-template-columns: 1fr;
    }

    .account-table th,
    .account-table td {
        padding: 14px 12px;
    }

    .account-product {
        align-items: flex-start;
    }

    .auth-section {
        padding: 30px 0 56px;
    }

    .auth-showcase-inner,
    .auth-card-inner {
        padding: 24px 18px;
    }

    .auth-showcase h1,
    .auth-card-head h2 {
        font-size: 26px;
    }

    .auth-benefit {
        padding: 14px;
    }

    .checkout-section {
        padding: 28px 0 56px;
    }

    .checkout-panel,
    .checkout-summary {
        border-radius: 12px;
        box-shadow: 0 12px 30px rgba(26, 26, 26, 0.05);
    }

    .checkout-panel {
        padding: 22px 16px;
    }

    .checkout-summary {
        padding: 20px 16px;
    }

    .checkout-heading {
        font-size: 26px;
    }

    .checkout-block-title {
        font-size: 22px;
    }

    .checkout-grid-2,
    .checkout-grid-3 {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .checkout-method {
        padding: 16px;
    }

    .checkout-order-item {
        grid-template-columns: 64px minmax(0, 1fr);
        gap: 12px;
    }

    .checkout-order-thumb {
        width: 64px;
        height: 82px;
        border-radius: 10px;
    }

    .checkout-order-actions {
        align-items: flex-start;
        flex-direction: column;
    }

    .hero-section {
        height: 250px;
        min-height: 250px;
    }
    .hero-swiper-pagination {
        bottom: 10px !important;
    }
    .section-title h2{
        padding-bottom: 10px;
        font-size: 20px;
    }
    .collections-section .container, .flash-sale-section .container, .new-products-section .container{
    padding-right: calc(var(--bs-gutter-x) * .5) !important;
    padding-left: calc(var(--bs-gutter-x) * .5) !important;
    }
    .collections-swiper, .new-products-swiper, .promo-products-swiper{
            padding-bottom: 16px !important;

    }
     /* Flash sale header */
    .flash-sale-section .d-flex.flex-column.flex-md-row {
        padding-bottom: 20px !important;
        margin-bottom: 20px !important;
    }

    .flash-sale-title {
        justify-content: center;
        flex-wrap: wrap;
        gap: 6px;
        font-size: 22px;
        line-height: 1.25;
    }

    .flash-icon {
        font-size: 25px;
    }

    .badge-time {
        width: 100%;
        margin: 4px 0 0;
        padding: 5px 10px;
        font-size: 11px;
        line-height: 1.2;
    }

    .countdown-box {
        justify-content: center;
        width: 100%;
        gap: 6px;
    }

    .countdown-item {
        width: 48px;
        height: 48px;
    }

    .countdown-num {
        font-size: 15px;
    }

    .countdown-lbl {
        font-size: 8px;
    }

    /* Product card: compact height on mobile */
    .product-img-wrap {
        aspect-ratio: 0.95;
    }

    .product-info {
        padding-top: 5px;
    }

    .product-sold-progress-container {
        height: 12px;
        margin-bottom: 4px;
    }

    .product-sold-progress-text {
        font-size: 8px;
        line-height: 12px;
    }

    .product-title-text {
        height: 2.5em;
        margin-bottom: 3px;
        font-size: 13.5px;
        line-height: 1.25;
    }

    .product-price-box {
        gap: 4px;
        font-size: 15px;
    }

    .product-price-box .price-old {
        font-size: 11px;
    }

    .product-badge {
        top: 8px;
        left: 8px;
        padding: 3px 7px;
        font-size: 9px;
    }

    .product-badge.badge-hot {
        top: 34px;
    }

    .product-badge.badge-hot.no-sale-badge {
        top: 8px;
    }

    /* Category tabs: one-line horizontal scroll on mobile */
    .category-tabs-section .container > .d-flex {
        justify-content: flex-start !important;
        width: 100%;
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 3px;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
    }

    .category-tabs-section .container > .d-flex::-webkit-scrollbar {
        display: none;
    }

    .custom-tabs {
        width: max-content;
        min-width: max-content;
        flex-wrap: nowrap;
    }

    .custom-tabs .nav-item {
        flex: 0 0 auto;
    }

    .custom-tabs .nav-link {
        white-space: nowrap;
        padding: 8px 12px;
        font-size: 12px;
    }

    /* Mobile header search button */
    .main-header .d-lg-none .btn-search-trigger {
        width: 38px;
        height: 38px;
        padding: 0;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        flex: 0 0 38px;
        border: 1px solid #e4e8ec;
        border-radius: 50% !important;
        background-color: #f7f9fb;
        color: var(--primary);
        font-size: 15px;
        line-height: 1;
        box-shadow: 0 2px 8px rgba(17, 17, 17, 0.06);
        transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
        -webkit-tap-highlight-color: transparent;
    }

    .main-header .d-lg-none .btn-search-trigger:active {
        color: #fff;
        background-color: var(--secondary);
        border-color: var(--secondary);
        transform: scale(0.94);
    }

    .main-header .d-lg-none .btn-search-trigger i {
        display: block;
        pointer-events: none;
    }

    /* Size guide table */
    .size-guide-table {
        padding: 0 !important;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
    }

    .size-guide-table .table {
        min-width: 650px;
        font-size: 12px;
    }

    .size-guide-table th,
    .size-guide-table td {
        padding: 9px 8px;
        white-space: nowrap;
    }

    .size-guide-table th {
        font-size: 11px;
        line-height: 1.3;
    }

    .size-guide-table th:first-child,
    .size-guide-table td:first-child {
        position: sticky;
        left: 0;
        z-index: 2;
        min-width: 54px;
        background-color: #fff;
        box-shadow: 2px 0 5px rgba(0, 0, 0, 0.08);
    }

    .size-guide-table thead th:first-child {
        z-index: 3;
        background-color: var(--bs-secondary-bg, #e2e3e5);
    }

    /* News category filters */
    #newsCategoryFilters {
        flex-wrap: nowrap !important;
        justify-content: flex-start !important;
        width: 100%;
        gap: 7px !important;
        overflow-x: auto;
        overflow-y: hidden;
        padding: 2px 1px 6px;
        scrollbar-width: none;
        scroll-snap-type: x proximity;
        -webkit-overflow-scrolling: touch;
    }

    #newsCategoryFilters::-webkit-scrollbar {
        display: none;
    }

    #newsCategoryFilters .btn-news-filter {
        flex: 0 0 auto;
        white-space: nowrap;
        padding: 7px 13px;
        border-radius: 50px !important;
        font-size: 12px;
        line-height: 1.35;
        scroll-snap-align: start;
    }

    #newsCategoryFilters .btn-news-filter.active {
        box-shadow: 0 3px 8px rgba(14, 118, 188, 0.2);
    }

    /* Retail pricing table: display each product as a mobile card */
    .pricing-tabs-section .table-responsive {
        overflow: visible;
        padding: 0 !important;
        border: 0 !important;
        background: transparent !important;
        box-shadow: none !important;
    }

    .repsaigon-pricing-table,
    .repsaigon-pricing-table tbody,
    .repsaigon-pricing-table tr,
    .repsaigon-pricing-table td {
        display: block;
        width: 100%;
    }

    .repsaigon-pricing-table {
        border: 0;
        background: transparent;
    }

    .repsaigon-pricing-table thead {
        display: none;
    }

    .repsaigon-pricing-table tbody {
        display: grid;
        gap: 14px;
    }

    .repsaigon-pricing-table tbody tr {
        overflow: hidden;
        border: 1px solid #e2e8f0;
        border-radius: 8px !important;
        background-color: #fff;
        box-shadow: 0 4px 14px rgba(17, 24, 39, 0.06);
    }

    .repsaigon-pricing-table tbody td {
        display: grid;
        grid-template-columns: 108px minmax(0, 1fr);
        gap: 10px;
        align-items: start;
        padding: 9px 12px !important;
        border-width: 0 0 1px !important;
        font-size: 12.5px;
        line-height: 1.45;
        text-align: left !important;
    }

    .repsaigon-pricing-table tbody td::before {
        color: #64748b;
        font-size: 10px;
        font-weight: 800;
        letter-spacing: 0.04em;
        text-transform: uppercase;
    }

    .repsaigon-pricing-table tbody td:first-child {
        display: block;
        padding: 12px !important;
        border-bottom-color: rgba(14, 118, 188, 0.22) !important;
        background: rgba(14, 118, 188, 0.07) !important;
        color: var(--primary) !important;
        font-size: 14px;
        line-height: 1.35;
    }

    .repsaigon-pricing-table tbody td:nth-child(2)::before {
        content: "Chất liệu";
    }

    .repsaigon-pricing-table tbody td:nth-child(3)::before {
        content: "Đặc điểm";
    }

    .repsaigon-pricing-table tbody td:nth-child(4)::before {
        content: "Kích cỡ";
    }

    .repsaigon-pricing-table tbody td:nth-child(5)::before {
        content: "Giá bán lẻ";
    }

    .repsaigon-pricing-table tbody td:nth-child(5) {
        align-items: center;
        font-size: 15px;
    }

    .repsaigon-pricing-table tbody td:last-child {
        display: block;
        padding: 10px 12px 12px !important;
        border-bottom: 0 !important;
        text-align: right !important;
    }

    .repsaigon-pricing-table tbody td:last-child .btn {
        width: 100%;
        padding: 8px 12px !important;
        font-size: 11px;
    }

    .py-xl {
        padding-top: 24px !important;
        padding-bottom: 24px !important;
    }
    .cta-section h2{
        font-size: 20px;
    }
    #quoteModal{
        padding-right: 0 !important
    }
}

@media (max-width: 991.98px) {
    .thankyou-shell {
        grid-template-columns: 1fr;
    }

    .thankyou-info-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .account-shell {
        grid-template-columns: 1fr;
    }

    .account-sidebar {
        position: static;
        top: auto;
    }

    .account-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .account-summary-grid {
        grid-template-columns: 1fr;
    }

    .auth-shell {
        grid-template-columns: 1fr;
    }

    .checkout-shell {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .checkout-summary {
        position: static;
        top: auto;
    }
}
