/**
 * product-list-a – Mobile Display A
 * 复用 product-list.php 已有 HTML，纯 CSS 实现左栏布局
 */

/* ══ 隐藏 mobile-only pill 元素 ══ */
.mkl-mobile-only { display: none !important; }

/* ══ Tab Bar ══ */
.mkl-tab-bar-wrap {
    display: block;
    padding: 10px 12px 0;
    background: #FAFAFA;
}
.mkl-tab-bar {
    display: flex;
    background: #EFEFEF;
    border-radius: 12px;
    padding: 3px;
    gap: 2px;
}
.mkl-tab-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    flex: 1;
    padding: 7px 8px;
    border-radius: 10px;
    background: transparent;
    font-family: 'Inter', 'Noto Sans SC', -apple-system, sans-serif;
    font-size: 13px;
    font-weight: 500;
    color: #86868B;
    text-decoration: none;
    transition: background 0.2s, color 0.18s;
}
.mkl-tab-btn.active {
    background: white;
    color: var(--mkl-accent, #5856D6);
    box-shadow: 0 1px 4px rgba(0,0,0,0.12), 0 0 0 0.5px rgba(0,0,0,0.05);
}
.mkl-tab-btn .mkl-tab-dot {
    width: 5px; height: 5px;
    border-radius: 50%;
    background: var(--mkl-accent, #5856D6);
    opacity: 0; transform: scale(0);
    transition: opacity 0.2s, transform 0.3s cubic-bezier(0.34,1.56,0.64,1);
    flex-shrink: 0;
}
.mkl-tab-btn.active .mkl-tab-dot { opacity: 1; transform: scale(1); }

/* ══ 页面根节点 ══ */
.mkl-list-page { min-width: 0; padding-top: 0; background: #FAFAFA; }
.mkl-list-header { display: none !important; }

/* ══ MAIN：flex 左右分栏 ══ */
.mkl-list-main {
    display: flex !important;
    align-items: stretch;
    margin-top: 8px;
    min-height: calc(100vh - 90px);
    padding: 0 !important;
    gap: 0 !important;
}

/* ══ 左侧筛选栏：100px 固定宽 ══ */
.mkl-list-sidebar {
    display: block !important;
    width: 100px !important;
    flex-shrink: 0 !important;
    height: calc(100vh - 90px);
    overflow-y: auto;
    overflow-x: hidden;
    position: sticky;
    top: 0;
    background: white;
    border-right: 0.5px solid #E5E5EA;
    scrollbar-width: none;
    padding-bottom: 40px;
}
.mkl-list-sidebar::-webkit-scrollbar { display: none; }

.mkl-filter-panel { padding: 0; }

.mkl-filter-section {
    padding: 10px 8px 6px;
    border-bottom: 0.5px solid #F0F0F0;
}
.mkl-filter-section:last-child { border-bottom: none; }

.mkl-filter-heading {
    font-size: 10px;
    font-weight: 600;
    color: #86868B;
    letter-spacing: 0.02em;
    margin-bottom: 6px;
    text-transform: uppercase;
}

/* Radio / Checkbox 选项行 */
.mkl-filter-option {
    font-size: 11px !important;
    color: #1D1D1F;
    padding: 4px 0 4px 18px !important;
    line-height: 1.3;
    word-break: keep-all;
}

/* Radio/Checkbox 控件尺寸缩小 */
.mkl-list-page .mkl-filter-option::before {
    width: 13px !important;
    height: 13px !important;
}
.mkl-list-page .mkl-filter-option input[type="radio"],
.mkl-list-page .mkl-filter-option input[type="checkbox"] {
    width: 13px !important;
    height: 13px !important;
}
.mkl-list-page .mkl-filter-option:has(input[type="radio"]:checked)::after {
    left: 4px !important;
    width: 5px !important;
    height: 5px !important;
}
.mkl-list-page .mkl-filter-option:has(input[type="checkbox"]:checked)::after {
    left: 3px !important;
    width: 7px !important;
    height: 4px !important;
}

/* Badge Toggle 竖向单列 */
.mkl-badge-toggle-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.mkl-badge-toggle {
    display: block !important;
    width: 100%;
    padding: 3px 4px;
    border-radius: 5px;
    font-size: 10px !important;
    text-align: center;
    box-sizing: border-box;
    opacity: 0.55;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: opacity 0.15s, box-shadow 0.15s;
    word-break: keep-all;
    line-height: 1.4;
}
.mkl-badge-toggle.active {
    opacity: 1;
    box-shadow: 0 0 0 1.5px currentColor;
}

/* ══ 右侧产品区 ══ */
.mkl-product-area {
    flex: 1;
    min-width: 0;
    overflow-y: auto;
    height: calc(100vh - 90px);
    padding: 8px 8px 40px;
    scrollbar-width: none;
}
.mkl-product-area::-webkit-scrollbar { display: none; }

.mkl-results-info {
    font-size: 11px;
    color: #86868B;
    margin-bottom: 8px;
    padding-left: 2px;
}

/* ══ 产品网格：单列 ══ */
.mkl-product-grid {
    grid-template-columns: 1fr !important;
    column-gap: 0;
    row-gap: 10px;
}
.mkl-product-grid .mkl-product-card {
    width: 100% !important;
    min-width: 0 !important;
}

/* ══ 卡片内：隐藏变体缩略图轮播（空间太窄）══ */
.mkl-product-grid .mkl-card-variants,
.mkl-product-grid .mkl-variant-thumbs,
.mkl-product-grid .mkl-card-thumb-row,
.mkl-product-grid .mkl-card-slider,
.mkl-product-grid .mkl-card-gallery,
.mkl-product-grid .swiper,
.mkl-product-grid .mkl-card-swiper { display: none !important; }

/* 卡片右侧内容区不截断 */
.mkl-product-grid .mkl-card-body,
.mkl-product-grid .mkl-card-content,
.mkl-product-grid .mkl-card-info { overflow: visible !important; }
.mkl-product-grid .mkl-card-name,
.mkl-product-grid .mkl-card-title { white-space: normal !important; overflow: visible !important; text-overflow: unset !important; }
