/* ==========================================================================
   MMLiveSearch Universal CSS - Color System & Presets
   ========================================================================== */
:root {
  --mmls-primary: #2563eb;
  --mmls-primary-hover: #1d4ed8;
  --mmls-primary-light: rgba(37, 99, 235, 0.08);
}

/* Classic Dropdown Search */
.mmlivesearch__result {
  position: absolute;
  top: 40px;
  width: 100%;
  z-index: 510;
  border-radius: 0 0 5px 5px;
  overflow-y: auto;
  left: 0;
  box-shadow: 0 10px 10px #b1b1b1;
  color: #000;
  border-top: 1px solid #ddd;
}
.mmlivesearch__result span.search_sel {
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 10px 15px;
  position: relative;
  border-top: 1px solid #e3e3e3;
  background: #fff;
  text-align: left;
  box-sizing: border-box;
}
.mmlivesearch__result span.search_sel .im {
  padding-right: 10px;
  width: 35px;
  flex-shrink: 0;
  text-align: center;
}
.mmlivesearch__result span.search_sel .w {
  flex: 1 1 auto;
  min-width: 0;
  word-break: break-word;
  padding-right: 15px;
  text-align: left;
}
.mmlivesearch__result span.search_sel:hover {
  background: #f1f5f9;
}
.mmlivesearch__result span.search_sel.history {
  padding: 10px 15px;
}
.mmlivesearch__result span.selected {
  background: #e2e8f0;
}
.mmlivesearch__result .title {
  padding: 10px 15px 4px 15px;
  background: #fff;
  text-align: left;
  font-weight: 600;
  color: #64748b;
  font-size: 12px;
  text-transform: uppercase;
}
.mmlivesearch__result span.all_products {
  width: 100%;
  padding: 10px;
  text-align: center !important;
  color: var(--mmls-primary, #2563eb);
  font-weight: 600;
}
.mmlivesearch__result span.no_find {
  width: 100%;
  padding: 12px;
  display: block;
  background: #fff;
  text-align: center;
  color: #64748b;
}
.mmlivesearch__result .clearMMLiveSearch {
  float: right;
  color: #94a3b8;
  cursor: pointer;
}
.mmlivesearch__result .clearMMLiveSearch:hover {
  color: #ef4444;
}
.mmlivesearch__result .mmls__price {
  position: static;
  flex-shrink: 0;
  font-weight: 700;
  white-space: nowrap;
  text-align: right;
  background: transparent;
  color: #1e293b;
}

/* ==========================================================================
   Full-screen Responsive Live Search Modal
   ========================================================================== */

html.mm-modal-open,
body.mm-modal-open {
    overflow: hidden !important;
    height: 100% !important;
    overscroll-behavior: none !important;
}

.mm-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: 100% !important;
    height: 100dvh !important;
    min-height: -webkit-fill-available !important;
    background: rgba(15, 23, 42, 0.65) !important;
    z-index: 99999999 !important;
    display: flex !important;
    justify-content: center !important;
    backdrop-filter: blur(5px) !important;
    -webkit-backdrop-filter: blur(5px) !important;
    animation: mmFadeIn 0.2s ease-out;
    box-sizing: border-box !important;
    overscroll-behavior: contain !important;
    -webkit-overflow-scrolling: touch !important;
}

@keyframes mmFadeIn {
    from { opacity: 0; transform: scale(0.99); }
    to { opacity: 1; transform: scale(1); }
}

/* Central container */
.mm-modal-container {
    width: 85%;
    max-width: 1600px;
    height: 100%;
    height: 100dvh;
    min-height: -webkit-fill-available;
    background: #ffffff;
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-sizing: border-box;
    overscroll-behavior: contain;
}

/* Header with large search input */
.mm-modal-header {
    height: 100px;
    flex-shrink: 0;
    border-bottom: 1px solid #eeeeee;
    display: flex;
    align-items: center;
    padding: 0 40px;
    position: relative;
    background: #ffffff;
    box-sizing: border-box;
}

.mm-search-icon {
    margin-right: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mm-large-input {
    flex-grow: 1 !important;
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
    font-size: 28px !important;
    font-weight: 300 !important;
    color: #222222 !important;
    background: transparent !important;
    padding: 0 !important;
    margin: 0 !important;
    height: 60px !important;
    line-height: 60px !important;
}

.mm-large-input::placeholder {
    color: #cccccc !important;
    font-weight: 300 !important;
}

.mm-close-btn {
    font-size: 42px;
    font-weight: 300;
    color: #999999;
    cursor: pointer;
    margin-left: 30px;
    line-height: 1;
    transition: color 0.2s;
    user-select: none;
}

.mm-close-btn:hover {
    color: #111111;
}

/* Results body */
.mm-modal-body {
    flex-grow: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    background: #ffffff;
    position: relative;
}

.mm-empty-state, .mm-loader-state {
    padding: 70px 20px;
    text-align: center;
    font-size: 18px;
    color: #777777;
}

/* Popular tags section */
.mm-popular-box {
    padding: 24px 35px 18px 35px;
    background: #ffffff;
    border-bottom: 1px solid #f0f0f0;
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
}

.mm-popular-title {
    display: flex;
    align-items: center;
    font-size: 14px;
    font-weight: 600;
    color: #444444;
    margin-bottom: 12px;
}

.mm-popular-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.mm-popular-tag {
    display: inline-flex;
    align-items: center;
    padding: 6px 14px;
    font-size: 13px;
    font-weight: 500;
    color: #333333;
    background: #f4f5f7;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}

.mm-popular-tag:hover {
    background: var(--mmls-primary, #2b2b2b);
    color: #ffffff;
    border-color: var(--mmls-primary, #2b2b2b);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* Layout: Sidebar + Grid */
.mm-layout {
    display: flex;
    height: 100%;
    overflow: hidden;
}

/* Left Sidebar */
.mm-sidebar {
    width: 320px;
    border-right: 1px solid #eeeeee;
    flex-shrink: 0;
    overflow-y: auto;
    padding: 20px 0;
    background: #fafafa;
    box-sizing: border-box;
}

.mm-cat-list {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.mm-cat-list li {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 14px 35px !important;
    font-size: 15px !important;
    color: #444444 !important;
    cursor: pointer !important;
    border-bottom: 1px solid #f5f5f5 !important;
    transition: background 0.15s, color 0.15s !important;
}

.mm-cat-list li:hover {
    background: #f0f0f0 !important;
    color: #111111 !important;
}

.mm-cat-list li.active {
    font-weight: bold !important;
    color: #111111 !important;
    background: #ffffff !important;
    border-left: 4px solid #333333 !important;
    padding-left: 31px !important;
}

.mm-cat-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-right: 10px;
}

.mm-badge {
    font-size: 12px;
    color: #777777;
    background: #e8e8e8;
    padding: 3px 9px;
    border-radius: 12px;
    font-weight: normal;
    flex-shrink: 0;
}

.mm-badge-main {
    background: #2b2b2b;
    color: #ffffff;
    font-weight: 600;
}

/* Right Content Area */
.mm-content {
    flex-grow: 1;
    padding: 35px 40px;
    overflow-y: auto;
    background: #ffffff;
    box-sizing: border-box;
}

.mm-columns {
    column-count: 3;
    column-gap: 40px;
    width: 100%;
}

.mm-group {
    break-inside: avoid;
    page-break-inside: avoid;
    margin-bottom: 40px;
    display: inline-block;
    width: 100%;
    box-sizing: border-box;
}

.mm-group-title {
    font-size: 19px;
    font-weight: 600;
    color: #222222;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f0f0;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s;
}

.mm-group-title:hover {
    color: #000000;
    border-bottom-color: #333333;
}

/* Product item card */
.mm-item {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
    cursor: pointer;
    border-radius: 6px;
    padding: 6px 8px;
    transition: background 0.15s;
    box-sizing: border-box;
}

.mm-item:hover {
    background: #f8f9fa;
}

.mm-item:hover .mm-name {
    color: #000000;
    text-decoration: underline;
}

.mm-item-img {
    width: 60px;
    height: 60px;
    flex-shrink: 0;
    margin-right: 15px;
    border: 1px solid #eeeeee;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2px;
    background: #ffffff;
    overflow: hidden;
}

.mm-item-img img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.mm-item-info {
    flex-grow: 1;
    min-width: 0;
}

.mm-name {
    font-size: 14px;
    color: #333333;
    margin-bottom: 4px;
    line-height: 1.35;
    word-break: break-word;
}

.mm-name strong {
    background: var(--mmls-primary-light, rgba(37, 99, 235, 0.12));
    color: var(--mmls-primary, #111111);
    padding: 0 3px;
    border-radius: 3px;
    font-weight: 600;
}

.mm-price {
    font-size: 15px;
    font-weight: 700;
    color: #111111;
}

.mm-more {
    font-size: 13px;
    color: #666666;
    cursor: pointer;
    margin-top: 8px;
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    background: #f5f5f5;
    transition: all 0.2s;
}

.mm-more:hover {
    color: #000000;
    background: #e9ecef;
}

.mm-all-results {
    width: 100%;
    display: block;
    text-align: center;
    padding: 15px;
    margin-top: 20px;
    border-radius: 6px;
    color: #222222;
    font-weight: bold;
    font-size: 15px;
    cursor: pointer;
    background: #f1f3f5;
    transition: background 0.2s;
    break-inside: avoid;
}

.mm-all-results:hover {
    background: #e2e6ea;
}

/* Empty category preview */
.mm-empty-preview {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    min-height: 250px;
    text-align: center;
    color: #555555;
    padding: 30px;
}

.mm-empty-preview h3 {
    font-size: 20px;
    margin-bottom: 10px;
    color: #333333;
}

.mm-empty-preview p {
    font-size: 14px;
    color: #888888;
    margin-bottom: 20px;
}

.mm-btn-view-all {
    background-color: var(--mmls-primary, #222222);
    color: #ffffff;
    border: none;
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s;
}

.mm-btn-view-all:hover {
    background-color: var(--mmls-primary-hover, #000000);
}

/* ==========================================================================
   Voice Search Button & Animation
   ========================================================================== */
.mm-voice-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    color: #666666;
    cursor: pointer;
    margin-right: 15px;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.mm-voice-btn:hover {
    color: #111111;
    background: #f4f4f4;
}

.mm-voice-btn.listening {
    color: #ffffff !important;
    background: #ff3b30 !important;
    animation: mmVoicePulse 1.5s infinite;
}

@keyframes mmVoicePulse {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 59, 48, 0.7);
    }
    70% {
        box-shadow: 0 0 0 14px rgba(255, 59, 48, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(255, 59, 48, 0);
    }
}

/* ==========================================================================
   Initial Modal State Wrapper (Scrollable)
   ========================================================================== */
.mm-initial-wrapper {
    flex: 1 1 auto;
    width: 100% !important;
    max-width: 100% !important;
    height: 100%;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    -webkit-overflow-scrolling: touch !important;
    overscroll-behavior: contain !important;
    box-sizing: border-box !important;
    padding-bottom: 40px !important;
    display: flex;
    flex-direction: column;
}

/* ==========================================================================
   Recently Viewed Products Block
   ========================================================================== */
.mm-recent-box {
    padding: 20px 35px 16px 35px;
    background: #ffffff;
    border-bottom: 1px solid #f0f0f0;
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
}

.mm-recent-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
}

.mm-recent-title {
    font-size: 14px;
    font-weight: 600;
    color: #444444;
    display: flex;
    align-items: center;
    min-width: 0;
}

.mm-recent-clear {
    font-size: 12px;
    color: #999999;
    background: none;
    border: none;
    cursor: pointer;
    text-decoration: underline;
    padding: 0;
    transition: color 0.2s;
    flex-shrink: 0;
}

.mm-recent-clear:hover {
    color: #e53935;
}

.mm-recent-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)) !important;
    gap: 12px !important;
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
}

@media (min-width: 1200px) {
    .mm-recent-grid {
        grid-template-columns: repeat(6, minmax(0, 1fr)) !important;
    }
}

@media (min-width: 768px) and (max-width: 1199px) {
    .mm-recent-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    }
}

.mm-recent-card {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    background: #ffffff;
    border: 1px solid #e8e8e8;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    box-sizing: border-box !important;
    min-width: 0 !important;
    max-width: 100% !important;
}

.mm-recent-card:hover {
    border-color: #2b2b2b;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.mm-recent-card img {
    width: 44px;
    height: 44px;
    min-width: 44px;
    max-width: 44px;
    object-fit: contain;
    border-radius: 6px;
    margin-right: 10px;
    flex-shrink: 0 !important;
    background: #f8fafc;
    padding: 2px;
    box-sizing: border-box;
}

/* ==========================================================================
   History Section in Initial View
   ========================================================================== */
.mm-history-box {
    padding: 20px 35px 24px 35px;
    background: #ffffff;
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
}

.mm-history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    box-sizing: border-box !important;
    width: 100% !important;
}

.mm-history-title {
    font-size: 14px;
    font-weight: 600;
    color: #444444;
    display: flex;
    align-items: center;
    min-width: 0;
}

.mm-history-clear {
    font-size: 12px;
    color: #999999;
    background: none;
    border: none;
    cursor: pointer;
    text-decoration: underline;
    padding: 0;
    transition: color 0.2s;
    flex-shrink: 0;
}

.mm-history-clear:hover {
    color: #e53935;
}

.mm-history-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    box-sizing: border-box;
    width: 100%;
}

.mm-history-chip {
    display: inline-flex;
    align-items: center;
    padding: 7px 14px;
    font-size: 13px;
    font-weight: 500;
    color: #333333;
    background: #f4f5f7;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
    box-sizing: border-box;
    max-width: 100%;
}

.mm-history-chip:hover {
    background: #2b2b2b;
    color: #ffffff;
    border-color: #2b2b2b;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.mm-history-chip:hover svg {
    stroke: #ffffff;
}

.mm-history-chip span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 350px;
}

.mm-recent-card-info {
    overflow: hidden !important;
    flex: 1 1 0% !important;
    min-width: 0 !important;
}

.mm-recent-card-name {
    font-size: 13px;
    color: #333333;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    word-break: break-word !important;
    line-height: 1.3;
    width: 100% !important;
}

.mm-recent-card-price {
    font-size: 12px;
    font-weight: 700;
    color: #111111;
    margin-top: 3px;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

/* ==========================================================================
   Quick Category Tabs
   ========================================================================== */
.mm-quick-tabs-bar {
    padding: 0 0 15px 0;
    margin-bottom: 20px;
    border-bottom: 1px solid #eeeeee;
    overflow-x: auto;
    white-space: nowrap;
    scrollbar-width: none;
}

.mm-quick-tabs-bar::-webkit-scrollbar {
    display: none;
}

.mm-quick-tabs {
    display: inline-flex;
    gap: 8px;
}

.mm-tab-chip {
    display: inline-flex;
    align-items: center;
    padding: 6px 14px;
    border-radius: 20px;
    border: 1px solid #e0e0e0;
    background: #ffffff;
    font-size: 13px;
    color: #555555;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 500;
}

.mm-tab-chip:hover {
    background: #f5f5f5;
    color: #111111;
    border-color: #cccccc;
}

.mm-tab-chip.active {
    background: var(--mmls-primary, #222222) !important;
    color: #ffffff !important;
    border-color: var(--mmls-primary, #222222) !important;
}

.mm-chip-count {
    display: inline-block;
    font-size: 11px;
    margin-left: 6px;
    opacity: 0.85;
    padding: 1px 6px;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.06);
}

.mm-tab-chip.active .mm-chip-count {
    background: rgba(255, 255, 255, 0.25) !important;
    color: #ffffff !important;
}

/* Responsive / Mobile */
@media (max-width: 1400px) {
    .mm-modal-container {
        width: 92%;
    }
}

@media (max-width: 1100px) {
    .mm-columns {
        column-count: 2;
        column-gap: 30px;
    }
}

@media (max-width: 1024px), (max-height: 600px), ((pointer: coarse) and (max-width: 1200px)) {
    html.mm-modal-open,
    body.mm-modal-open {
        position: fixed !important;
        width: 100% !important;
        height: 100% !important;
        overflow: hidden !important;
        overscroll-behavior: none !important;
    }

    .mm-overlay {
        position: fixed !important;
        inset: 0 !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        width: 100% !important;
        width: 100vw !important;
        max-width: 100vw !important;
        height: 100% !important;
        height: 100dvh !important;
        min-height: 100% !important;
        min-height: -webkit-fill-available !important;
        background: #ffffff !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        z-index: 99999999 !important;
        overflow: hidden !important;
        overscroll-behavior: none !important;
        padding: 0 !important;
        margin: 0 !important;
        box-shadow: none !important;
        -webkit-box-shadow: none !important;
        animation: none !important;
        transform: none !important;
        display: flex !important;
        flex-direction: column !important;
    }

    .mm-modal-container {
        position: relative !important;
        inset: auto !important;
        width: 100% !important;
        width: 100vw !important;
        max-width: 100% !important;
        max-width: 100vw !important;
        min-width: 100% !important;
        height: 100% !important;
        height: 100dvh !important;
        min-height: 100% !important;
        min-height: -webkit-fill-available !important;
        background: #ffffff !important;
        border-radius: 0 !important;
        box-shadow: none !important;
        -webkit-box-shadow: none !important;
        display: flex !important;
        flex-direction: column !important;
        overflow: hidden !important;
        overscroll-behavior: none !important;
        padding: 0 !important;
        margin: 0 !important;
        border: none !important;
        animation: none !important;
        transform: none !important;
        flex: 1 1 auto !important;
    }

    .mm-modal-header {
        padding-top: max(12px, env(safe-area-inset-top)) !important;
        padding-bottom: 10px !important;
        padding-left: max(14px, env(safe-area-inset-left)) !important;
        padding-right: max(14px, env(safe-area-inset-right)) !important;
        height: auto !important;
        min-height: 54px !important;
        background: #ffffff !important;
        border-bottom: 1px solid #eeeeee !important;
        flex: 0 0 auto !important;
        flex-shrink: 0 !important;
        box-sizing: border-box !important;
        touch-action: pan-y !important;
    }

    .mm-large-input {
        font-size: 18px !important;
        height: 40px !important;
        line-height: 40px !important;
    }

    .mm-voice-btn {
        width: 36px !important;
        height: 36px !important;
        margin-right: 8px !important;
    }

    .mm-voice-btn svg {
        width: 19px !important;
        height: 19px !important;
    }

    .mm-close-btn {
        font-size: 32px !important;
        margin-left: 10px !important;
        padding: 4px !important;
        line-height: 1 !important;
    }

    /* THE SOLE SCROLL CONTAINER ON MOBILE */
    .mm-modal-body {
        flex: 1 1 0% !important;
        min-height: 0 !important;
        height: 100% !important;
        max-height: none !important;
        overflow-x: hidden !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch !important;
        overscroll-behavior-y: contain !important;
        touch-action: pan-y !important;
        display: block !important;
        background: #ffffff !important;
        box-sizing: border-box !important;
        width: 100% !important;
        max-width: 100% !important;
        position: relative !important;
    }

    /* ALL INNER CONTAINERS EXPAND NATURALLY WITHOUT TRAPPING SCROLL */
    .mm-initial-wrapper {
        display: block !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow: visible !important;
        overflow-y: visible !important;
        overflow-x: hidden !important;
        box-sizing: border-box !important;
        padding-bottom: max(90px, calc(env(safe-area-inset-bottom) + 70px)) !important;
        width: 100% !important;
        max-width: 100% !important;
        touch-action: pan-y !important;
        overscroll-behavior: auto !important;
    }

    .mm-layout {
        display: block !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow: visible !important;
        overflow-y: visible !important;
        background: #ffffff !important;
        box-sizing: border-box !important;
        width: 100% !important;
        max-width: 100% !important;
        touch-action: pan-y !important;
    }

    /* Hide vertical sidebar on mobile to avoid duplicate categories and double scrollbars */
    .mm-sidebar {
        display: none !important;
    }

    .mm-content {
        display: block !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow: visible !important;
        overflow-y: visible !important;
        overflow-x: hidden !important;
        padding: 14px 16px !important;
        padding-bottom: max(90px, calc(env(safe-area-inset-bottom) + 70px)) !important;
        background: #ffffff !important;
        box-sizing: border-box !important;
        width: 100% !important;
        max-width: 100% !important;
        touch-action: pan-y !important;
    }

    .mm-columns {
        column-count: 1 !important;
        display: block !important;
        width: 100% !important;
        overflow: visible !important;
    }

    .mm-group {
        display: block !important;
        break-inside: avoid !important;
        margin-bottom: 25px !important;
        overflow: visible !important;
    }

    .mm-item {
        touch-action: pan-y !important;
    }

    .mm-quick-tabs-bar {
        touch-action: pan-x !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        -webkit-overflow-scrolling: touch !important;
        padding: 0 0 10px 0 !important;
        margin-bottom: 12px !important;
        position: sticky !important;
        top: 0 !important;
        background: #ffffff !important;
        z-index: 10 !important;
        box-sizing: border-box !important;
        width: 100% !important;
    }

    .mm-tab-chip {
        padding: 5px 12px !important;
        font-size: 12px !important;
        touch-action: pan-x !important;
    }

    .mm-group-title {
        font-size: 16px !important;
    }

    .mm-item-img {
        width: 50px !important;
        height: 50px !important;
        margin-right: 12px !important;
    }

    .mm-popular-box {
        padding: 12px 14px 10px 14px !important;
        background: #ffffff !important;
        box-sizing: border-box !important;
        width: 100% !important;
        max-width: 100% !important;
        overflow: visible !important;
        touch-action: pan-y !important;
    }

    .mm-popular-tags {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 6px !important;
        box-sizing: border-box !important;
        width: 100% !important;
        max-width: 100% !important;
        touch-action: pan-y !important;
    }

    .mm-popular-tag {
        font-size: 12px !important;
        padding: 5px 10px !important;
        box-sizing: border-box !important;
        touch-action: pan-y !important;
    }

    .mm-recent-box {
        padding: 12px 14px 10px 14px !important;
        background: #ffffff !important;
        box-sizing: border-box !important;
        width: 100% !important;
        max-width: 100% !important;
        overflow: visible !important;
        touch-action: pan-y !important;
    }

    .mm-recent-header {
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
        margin-bottom: 8px !important;
        box-sizing: border-box !important;
        width: 100% !important;
    }

    .mm-recent-title {
        font-size: 13px !important;
        font-weight: 600 !important;
        color: #444444 !important;
        display: flex !important;
        align-items: center !important;
        min-width: 0 !important;
    }

    .mm-recent-title svg {
        width: 16px !important;
        height: 16px !important;
        margin-right: 5px !important;
        flex-shrink: 0 !important;
    }

    .mm-recent-clear {
        font-size: 11px !important;
        color: #999999 !important;
        flex-shrink: 0 !important;
    }

    .mm-recent-grid {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 8px !important;
        box-sizing: border-box !important;
        width: 100% !important;
    }

    .mm-recent-card {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        padding: 8px !important;
        gap: 8px !important;
        box-sizing: border-box !important;
        width: 100% !important;
        min-width: 0 !important;
        overflow: hidden !important;
        touch-action: pan-y !important;
    }

    .mm-recent-card img {
        width: 36px !important;
        height: 36px !important;
        flex-shrink: 0 !important;
    }

    .mm-recent-card-info {
        flex: 1 1 0% !important;
        min-width: 0 !important;
        overflow: hidden !important;
    }

    .mm-recent-card-name {
        font-size: 11px !important;
        line-height: 1.25 !important;
        max-height: 2.5em !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    .mm-recent-card-price {
        font-size: 12px !important;
        margin-top: 3px !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    .mm-history-box {
        padding: 12px 14px 20px 14px !important;
        background: #ffffff !important;
        box-sizing: border-box !important;
        width: 100% !important;
        overflow: visible !important;
        touch-action: pan-y !important;
    }

    .mm-history-header {
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
        margin-bottom: 8px !important;
        width: 100% !important;
    }

    .mm-history-title {
        font-size: 13px !important;
        font-weight: 600 !important;
        color: #444444 !important;
    }

    .mm-history-clear {
        font-size: 11px !important;
        color: #999999 !important;
    }

    .mm-history-tags {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 6px !important;
        touch-action: pan-y !important;
    }

    .mm-history-chip {
        padding: 5px 10px !important;
        font-size: 12px !important;
        border-radius: 16px !important;
        touch-action: pan-y !important;
    }

    .mm-history-chip span {
        max-width: 240px !important;
    }
}

@media (max-width: 480px) {
    .mm-recent-box {
        padding: 10px 12px 8px 12px !important;
        overflow: visible !important;
    }

    .mm-recent-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 6px !important;
    }

    .mm-recent-card {
        padding: 5px 6px !important;
    }

    .mm-recent-card img {
        width: 32px !important;
        height: 32px !important;
        min-width: 32px !important;
        max-width: 32px !important;
        margin-right: 6px !important;
    }

    .mm-recent-card-name {
        font-size: 10.5px !important;
        line-height: 1.25 !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        word-break: break-word !important;
    }

    .mm-recent-card-price {
        font-size: 10.5px !important;
    }

    .mm-history-box {
        padding: 10px 12px 18px 12px !important;
    }

    .mm-history-chip {
        padding: 4px 8px !important;
        font-size: 11px !important;
    }

    .mm-history-chip span {
        max-width: 180px !important;
    }
}

@media (max-width: 340px) {
    .mm-recent-box {
        padding: 8px 8px 6px 8px !important;
        overflow: visible !important;
    }

    .mm-recent-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 4px !important;
    }

    .mm-recent-card {
        padding: 4px 4px !important;
    }

    .mm-recent-card img {
        width: 28px !important;
        height: 28px !important;
        min-width: 28px !important;
        max-width: 28px !important;
        margin-right: 5px !important;
    }

    .mm-recent-card-name {
        font-size: 10px !important;
        line-height: 1.2 !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        word-break: break-word !important;
    }

    .mm-recent-card-price {
        font-size: 10px !important;
    }
}

/* ==========================================================================
   Deals Theme Dropdown Standalone Fallback Styles
   ========================================================================== */
.ds-livesearch {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    min-width: 320px;
    background: #ffffff;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    border-radius: 0 0 8px 8px;
    z-index: 1001;
    max-height: 80vh;
    overflow-y: auto;
}
.ds-livesearch.expanded {
    display: block !important;
}
.ds-livesearch-inner {
    padding: 15px;
}
.ds-livesearch-item {
    display: flex;
    align-items: center;
    padding: 10px;
    border-radius: 6px;
    border: 1px solid #f0f0f0;
    margin-bottom: 8px;
    text-decoration: none;
    transition: background 0.15s ease;
    background: #ffffff;
}
.ds-livesearch-item:hover {
    background: #f8fafc;
}
.ds-livesearch-item-img {
    flex-shrink: 0;
    margin-right: 12px;
    text-align: center;
}
.ds-livesearch-item-img img {
    object-fit: contain;
    border-radius: 4px;
}
.ds-livesearch-item-sticker {
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 3px;
    text-align: center;
    font-weight: 600;
}
.ds-livesearch-item-sticker.green-bg {
    background: #e8f5e9;
    color: #2e7d32;
}
.ds-livesearch-item-sticker.red-bg {
    background: #ffebee;
    color: #c62828;
}
.ds-livesearch-item-info {
    flex: 1 1 auto;
    min-width: 0;
}
.ds-livesearch-item-title {
    font-size: 14px;
    font-weight: 500;
    color: #1e293b;
    text-decoration: none;
    display: block;
    margin-bottom: 4px;
    word-break: break-word;
}
.ds-livesearch-item-code {
    font-size: 12px;
    color: #64748b;
    margin-bottom: 2px;
}
.ds-livesearch-item-price {
    margin-top: 4px;
}
.ds-livesearch-item-price .ds-price-old {
    font-size: 13px;
    color: #94a3b8;
    text-decoration: line-through;
}
.ds-livesearch-item-price .ds-price-new {
    font-size: 16px;
    font-weight: 700;
    color: #0f172a;
}
.ds-livesearch-categories-item {
    display: inline-block;
    margin: 4px;
}
.ds-livesearch-categories-item a {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    text-decoration: none;
    background: #ffffff;
    transition: all 0.2s ease;
}
.ds-livesearch-categories-item a:hover {
    border-color: #cbd5e1;
    background: #f8fafc;
}

/* ==========================================================================
   UniShop2 Theme Dropdown Standalone Fallback Styles
   ========================================================================== */
.live-search {
    z-index: 999;
    position: relative;
}
.live-search__ul {
    position: absolute;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    list-style: none;
    padding: 15px;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
    margin: 0;
    left: 0;
    top: 100%;
}
.live-search__ul::-webkit-scrollbar {
    width: 6px;
    background: #f1f5f9;
}
.live-search__ul::-webkit-scrollbar-thumb {
    background-color: #cbd5e1;
    border-radius: 3px;
}
.live-search__section {
    margin: 0 0 10px;
    font-weight: 700;
    font-size: 14px;
    color: #334155;
    padding-bottom: 4px;
    border-bottom: 1px solid #f1f5f9;
}
.live-search__category {
    margin: 0 0 16px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.live-search__category-item {
    display: inline-block;
    padding: 4px 10px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    background: #f1f5f9;
    border-radius: 4px;
    color: #2563eb;
    text-decoration: none;
    transition: background 0.15s ease;
}
.live-search__category-item:hover {
    background: #e2e8f0;
}
.live-search__item {
    display: flex;
    align-items: center;
    padding: 8px 10px;
    cursor: pointer;
    border-radius: 6px;
    transition: background 0.15s ease;
}
.live-search__item:hover {
    background: #f8fafc;
}
.live-search__image {
    padding: 0 10px 0 0;
    text-align: center;
    flex-shrink: 0;
}
.live-search__wrapper {
    flex: 1 1 auto;
    min-width: 0;
    padding: 0 10px;
}
.live-search__name {
    font-size: 14px;
    font-weight: 600;
    color: #0f172a;
    text-decoration: none;
    display: block;
    word-break: break-word;
}
.live-search__model {
    margin: 3px 0 0;
    font-size: 12px;
    color: #64748b;
}
.live-search__price {
    flex-shrink: 0;
    text-align: right;
    padding-left: 10px;
    white-space: nowrap;
}
.live-search__price .price-new {
    font-size: 15px;
    font-weight: 700;
    color: #0f172a;
    display: block;
}
.live-search__price .price-old {
    font-size: 12px;
    color: #94a3b8;
    text-decoration: line-through;
    display: block;
}
.live-search__more {
    justify-content: center;
    padding: 8px 0;
    font-weight: 600;
    text-align: center;
    border-top: 1px solid #f1f5f9;
    background: #f8fafc;
    border-radius: 4px;
    margin-top: 8px;
}
.live-search__more a {
    color: #2563eb;
    text-decoration: none;
}
.live-search__loading {
    height: 36px;
    position: relative;
}
.live-search__loading:before {
    position: absolute;
    top: 50%;
    left: 50%;
    display: block;
    width: 22px;
    height: 22px;
    margin: -11px auto auto -11px;
    content: '';
    border: 3px solid #2563eb;
    border-right-color: transparent;
    border-radius: 50%;
    animation: mmSpin 0.8s infinite linear;
}
@keyframes mmSpin {
    to { transform: rotate(360deg); }
}

/* ==========================================================================
   UpStore Theme Live Search Dropdown Styles
   ========================================================================== */
.header-search .search_autocomplete {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    width: 100%;
    min-width: 320px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
    z-index: 1042 !important;
    display: none;
    font-size: 13px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    overflow: hidden;
}
@media (min-width: 992px) {
    .header-search .search_autocomplete {
        min-width: 540px;
    }
}
.dark-theme .header-search .search_autocomplete {
    background: #181818;
    border: 1px solid #2d2d2d;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    color: #f1f5f9;
}
.header-search .search_autocomplete .autocomplete-wrapper {
    max-height: 480px;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 12px 14px;
    scrollbar-width: thin;
}
.header-search .search_autocomplete .search_categories {
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid #f1f5f9;
}
.dark-theme .header-search .search_autocomplete .search_categories {
    border-bottom: 1px solid #282828;
}
.header-search .search_autocomplete .search_categories_title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: #94a3b8;
    margin-bottom: 8px;
    letter-spacing: 0.5px;
}
.header-search .search_autocomplete .search_category_items {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.header-search .search_autocomplete .search_category_items a {
    display: inline-flex;
    align-items: center;
    padding: 5px 11px;
    background: #f1f5f9;
    border-radius: 20px;
    color: #334155;
    font-size: 12px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.15s ease;
}
.header-search .search_autocomplete .search_category_items a:hover {
    background: var(--mmls-primary, #2563eb);
    color: #ffffff;
}
.dark-theme .header-search .search_autocomplete .search_category_items a {
    background: #252525;
    color: #cbd5e1;
}
.dark-theme .header-search .search_autocomplete .search_category_items a:hover {
    background: var(--mmls-primary, #2563eb);
    color: #ffffff;
}
.header-search .search_autocomplete li.autosearch_item + li.autosearch_item {
    border-top: 1px solid #f1f5f9;
}
.dark-theme .header-search .search_autocomplete li.autosearch_item + li.autosearch_item {
    border-top: 1px solid #252525;
}
.header-search .search_autocomplete a.autosearch_link {
    display: block;
    padding: 8px 10px;
    border-radius: 8px;
    text-decoration: none;
    color: #0f172a;
    transition: background 0.15s ease;
}
.header-search .search_autocomplete a.autosearch_link:hover {
    background: #f8fafc;
}
.dark-theme .header-search .search_autocomplete a.autosearch_link {
    color: #f1f5f9;
}
.dark-theme .header-search .search_autocomplete a.autosearch_link:hover {
    background: #222222;
}
.header-search .search_autocomplete .ajaxadvance {
    display: flex;
    align-items: center;
    width: 100%;
}
.header-search .search_autocomplete .ajaxadvance .image {
    width: 48px;
    height: 48px;
    margin-right: 12px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border-radius: 6px;
    padding: 2px;
}
.header-search .search_autocomplete .ajaxadvance .image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}
.header-search .search_autocomplete .ajaxadvance .content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex: 1;
    min-width: 0;
}
.header-search .search_autocomplete .ajaxadvance .name {
    font-size: 13px;
    font-weight: 600;
    color: #0f172a;
    margin-bottom: 3px;
    line-height: 1.35;
}
.dark-theme .header-search .search_autocomplete .ajaxadvance .name {
    color: #f8fafc;
}
.header-search .search_autocomplete .ajaxadvance .model {
    font-size: 11px;
    color: #64748b;
    margin-bottom: 2px;
}
.dark-theme .header-search .search_autocomplete .ajaxadvance .model {
    color: #94a3b8;
}
.header-search .search_autocomplete .stock_status {
    font-size: 11px;
    font-weight: 600;
}
.header-search .search_autocomplete .stock_status.instock {
    color: #10b981;
}
.header-search .search_autocomplete .stock_status.outofstock {
    color: #ef4444;
}
.header-search .search_autocomplete .ajaxadvance .price {
    flex-shrink: 0;
    text-align: right;
    padding-left: 12px;
    font-size: 14px;
    font-weight: 700;
    color: #0f172a;
}
.dark-theme .header-search .search_autocomplete .ajaxadvance .price {
    color: #f8fafc;
}
.header-search .search_autocomplete .price-old {
    font-size: 11px;
    color: #94a3b8;
    text-decoration: line-through;
    display: block;
}
.header-search .search_autocomplete .price-new {
    color: #e11d48;
}
.header-search .search_autocomplete .btn-search-more {
    display: block;
    width: 100%;
    padding: 10px 16px;
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    border-radius: 8px;
    background: var(--mmls-primary, #2563eb);
    color: #ffffff !important;
    text-decoration: none;
    transition: opacity 0.15s ease;
}
.header-search .search_autocomplete .btn-search-more:hover {
    opacity: 0.9;
}
.mobile-sidebar-search__content .search_autocomplete {
    position: static;
    box-shadow: none;
    border: none;
    min-width: 100%;
    width: 100%;
    margin-top: 10px;
    border-radius: 0;
}
.mobile-sidebar-search__content .autocomplete-wrapper {
    max-height: calc(100vh - 140px);
    padding: 8px 0;
}

