/* ==========================================
   首页专属样式（爱采购三栏布局）
   公共样式见 common.css
   ========================================== */

.vc2b-home { background: var(--vc2b-bg); padding: 20px 0 0; }

/* 三栏骨架：左分类 / 中主内容 / 右用户面板（左右等宽） */
.vc2b-home-grid {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr) 300px;
    grid-template-areas: "left center right";
    gap: 18px;
    align-items: start;
}
.vc2b-home-left { grid-area: left; position: sticky; top: 128px; }
.vc2b-home-center { grid-area: center; min-width: 0; display: flex; flex-direction: column; gap: 18px; }
.vc2b-home-right { grid-area: right; position: sticky; top: 128px; }

/* 左：分类栏（组件样式在 common.css，此处仅首页布局相关） */

/* ==========================================
   Banner 轮播（固定高度防 CLS）
   ========================================== */
.vc2b-banner { position: relative; }
.vc2b-banner-carousel {
    position: relative; overflow: hidden;
    border-radius: var(--vc2b-radius-lg);
    height: clamp(260px, 26vw, 400px);
    background: var(--vc2b-ink);
    box-shadow: var(--vc2b-shadow);
}
.vc2b-banner-slide {
    position: absolute; inset: 0;
    opacity: 0; transition: opacity .5s ease;
}
.vc2b-banner-slide.active { opacity: 1; }
.vc2b-banner-slide img {
    width: 100%; height: 100%; object-fit: cover; display: block;
}
.vc2b-banner-cap {
    position: absolute; left: 24px; bottom: 20px;
    background: rgba(28, 33, 40, .72); color: #fff;
    font-size: 14px; font-weight: 700;
    padding: 8px 16px; border-radius: 999px;
    backdrop-filter: blur(4px);
}
.vc2b-banner-arrow {
    position: absolute; top: 50%; transform: translateY(-50%);
    width: 40px; height: 40px; border-radius: 50%; border: 0;
    background: rgba(255, 255, 255, .92); color: var(--vc2b-ink);
    font-size: 18px; cursor: pointer; z-index: 5;
    display: none; align-items: center; justify-content: center;
    box-shadow: 0 4px 12px rgba(28, 33, 40, .2);
    transition: background .15s ease;
}
.vc2b-banner-carousel:hover .vc2b-banner-arrow { display: flex; }
.vc2b-banner-arrow:hover { background: #fff; }
.vc2b-banner-prev { left: 16px; }
.vc2b-banner-next { right: 16px; }
.vc2b-banner-dots {
    position: absolute; left: 0; right: 0; bottom: 14px; z-index: 5;
    display: flex; justify-content: center; gap: 7px;
}
.vc2b-banner-dot {
    width: 8px; height: 8px; border-radius: 999px;
    background: rgba(255, 255, 255, .55); cursor: pointer;
    transition: background .2s ease, width .2s ease;
    border: 0; padding: 0;
}
.vc2b-banner-dot.active { width: 22px; background: #fff; }

/* 无 Banner 时的默认 Hero 块 */
.vc2b-banner-default {
    display: flex; align-items: center; justify-content: space-between; gap: 24px;
    border-radius: var(--vc2b-radius-lg);
    background: linear-gradient(120deg, #FF4438 0%, #FF8A3D 100%);
    padding: 44px 48px; min-height: 300px;
    color: #fff; text-decoration: none;
    position: relative; overflow: hidden;
    box-shadow: var(--vc2b-shadow-hover);
}
.vc2b-banner-default::after {
    content: ""; position: absolute; right: -60px; top: -60px;
    width: 280px; height: 280px; border-radius: 50%;
    background: rgba(255, 255, 255, .08);
}
/* 锁定 hover 颜色：Banner 是 <a>，全局 a:hover 会把继承色染红导致副标题看不清 */
.vc2b-banner-default:hover { color: #fff; }
.vc2b-banner-default-text { position: relative; max-width: 56%; }
.vc2b-banner-default-text h2 {
    margin: 0 0 10px; font-size: 36px; font-weight: 800; line-height: 1.2;
    color: #fff;
}
.vc2b-banner-default-text p { margin: 0 0 22px; font-size: 15.5px; color: #fff; opacity: .92; }
.vc2b-banner-default-art { position: relative; flex-shrink: 0; opacity: .9; }

/* ==========================================
   数据条
   ========================================== */
.vc2b-stats {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px;
}
.vc2b-stat {
    display: flex; align-items: center; gap: 13px;
    padding: 18px 20px;
}
.vc2b-stat .vc2b-ico {
    width: 46px; height: 46px; border-radius: 13px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
}
.vc2b-stat-num { font-size: 26px; font-weight: 800; color: var(--vc2b-ink); line-height: 1.1; }
.vc2b-stat-num em { font-style: normal; font-size: 15px; font-weight: 800; color: var(--vc2b-red); margin-left: 1px; }
.vc2b-stat-label { font-size: 12.5px; color: var(--vc2b-gray); margin-top: 2px; }

/* ==========================================
   快捷 Tab 条
   ========================================== */
.vc2b-quicktabs {
    display: flex; gap: 10px; flex-wrap: wrap;
    padding: 2px;
}
.vc2b-quicktabs a {
    padding: 9px 18px; border-radius: 999px;
    background: #fff; border: 1px solid var(--vc2b-border);
    font-size: 13.5px; font-weight: 700; color: var(--vc2b-text);
    text-decoration: none;
    transition: border-color .15s ease, color .15s ease, background .15s ease;
}
.vc2b-quicktabs a:hover { border-color: var(--vc2b-red); color: var(--vc2b-red); }
.vc2b-quicktabs a.active {
    background: var(--vc2b-red); border-color: var(--vc2b-red); color: #fff;
}

/* ==========================================
   区块通用
   ========================================== */
.vc2b-section { background: transparent; }
.vc2b-section-head {
    display: flex; align-items: baseline; justify-content: space-between; gap: 16px;
    margin-bottom: 14px;
}
.vc2b-section-head h2 {
    margin: 0; font-size: 22px; font-weight: 800; color: var(--vc2b-ink);
    display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap;
}
.vc2b-section-sub { font-size: 13px; font-weight: 500; color: var(--vc2b-light); }
.vc2b-more {
    font-size: 13px; font-weight: 700; color: var(--vc2b-red);
    text-decoration: none; white-space: nowrap; flex-shrink: 0;
}
.vc2b-more:hover { text-decoration: underline; }

/* 优选精品（产品卡组件样式在 common.css） */

/* 王牌工厂（供应商卡组件样式在 common.css） */

/* 热门求购 / 行业资讯（组件样式在 common.css） */

/* 首页 FAQ（手风琴，details/summary 原生，无 JS） */
.vc2b-hp-faq { display: grid; gap: 10px; }
.vc2b-hp-faq-item { background: var(--vc2b-white); border: 1px solid var(--vc2b-border); border-radius: var(--vc2b-radius); overflow: hidden; }
.vc2b-hp-faq-item summary {
    position: relative; padding: 15px 44px 15px 18px; cursor: pointer; list-style: none;
    font-size: 14.5px; font-weight: 700; color: var(--vc2b-ink);
}
.vc2b-hp-faq-item summary::-webkit-details-marker { display: none; }
.vc2b-hp-faq-item summary::after {
    content: "+"; position: absolute; right: 18px; top: 50%; transform: translateY(-50%);
    font-size: 20px; font-weight: 500; color: var(--vc2b-red); line-height: 1;
}
.vc2b-hp-faq-item[open] summary::after { content: "\2212"; }
.vc2b-hp-faq-item p { margin: 0; padding: 0 18px 16px; font-size: 13.5px; line-height: 1.65; color: var(--vc2b-gray); }

/* ==========================================
   响应式
   ========================================== */
@media (max-width: 1200px) {
    .vc2b-home-grid {
        grid-template-columns: 205px minmax(0, 1fr);
        grid-template-areas:
            "left center"
            ". right";
    }
    .vc2b-home-right { position: static; }
    .vc2b-user-panel {
        display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
        align-items: start;
    }
}

@media (max-width: 1080px) {
    .vc2b-product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
    /* 分类栏从侧边移到内容之后 */
    .vc2b-home-grid {
        grid-template-columns: minmax(0, 1fr);
        grid-template-areas:
            "center"
            "left"
            "right";
    }
    .vc2b-home-left, .vc2b-home-right { position: static; }
    .vc2b-cat-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 4px; }
    .vc2b-cat-cta { display: none; }
}

@media (max-width: 768px) {
    .vc2b-home { padding-top: 14px; }
    .vc2b-banner-carousel { height: 220px; }
    .vc2b-banner-default { padding: 30px 24px; min-height: 0; flex-direction: column; align-items: flex-start; gap: 16px; }
    .vc2b-banner-default-text { max-width: 100%; }
    .vc2b-banner-default-text h2 { font-size: 26px; }
    .vc2b-banner-default-art { display: none; }
    .vc2b-stats { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .vc2b-stat { padding: 14px 16px; }
    .vc2b-stat-num { font-size: 20px; }
    .vc2b-section-head h2 { font-size: 18px; }
    .vc2b-user-panel { grid-template-columns: 1fr; }
    .vc2b-cat-list { grid-template-columns: 1fr; }
    .vc2b-rfq-row { flex-direction: column; align-items: flex-start; gap: 8px; }
    .vc2b-rfq-row-main { width: 100%; }
    .vc2b-rfq-row-side { width: 100%; justify-content: flex-start; }
}

@media (max-width: 480px) {
    .vc2b-product-grid, .vc2b-supplier-grid, .vc2b-news-grid { grid-template-columns: 1fr; }
    .vc2b-stats { grid-template-columns: 1fr 1fr; }
}
