/* product.css — 产品详情页（007 风格） */

.page-product-detail { background: var(--gray-100); }

/* ── 面包屑 ── */
.page-product-detail .breadcrumb {
    padding: 10px 0;
    font-size: 13px;
    background: transparent;
}
.page-product-detail .breadcrumb-inner {
    display: flex;
    align-items: center;
    gap: 6px;
}
.page-product-detail .breadcrumb-inner a { color: var(--text-secondary); }
.page-product-detail .breadcrumb-inner a:hover { color: var(--primary-orange); }
.page-product-detail .breadcrumb-inner span { color: var(--text-tertiary); }
.page-product-detail .breadcrumb-inner strong { color: var(--text-primary); font-weight: 400; }


/* ── 两栏布局 ── */
.pd-shell {
    margin-top: 20px;
}
.pd-layout {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}
.pd-main { flex: 1; min-width: 0; }
.pd-side { width: 310px; flex-shrink: 0; }

/* ── 产品顶部：图册 + 参数 ── */
.pd-top {
    display: flex;
    gap: 20px;
    background: #fff;
    border: 1px solid var(--gray-300);
    padding: 20px;
    margin-bottom: 16px;
}

.pd-gallery { width: 360px; flex-shrink: 0; }
.pd-main-img {
    width: 100%;
    aspect-ratio: 1;
    background: var(--gray-50);
    border: 1px solid var(--gray-300);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.pd-main-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.pd-thumbs {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 10px;
}
.pd-thumbs-prev, .pd-thumbs-next {
    width: 24px; height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gray-200);
    border: 1px solid var(--gray-400);
    cursor: pointer;
    font-size: 16px;
    color: var(--text-secondary);
    flex-shrink: 0;
}
.pd-thumbs-track {
    display: flex;
    gap: 6px;
    overflow: hidden;
    flex: 1;
}
.pd-thumb-img {
    width: 60px; height: 60px;
    object-fit: cover;
    border: 1px solid var(--gray-400);
    cursor: pointer;
    flex-shrink: 0;
}
.pd-thumb-img:hover,
.pd-thumb-img.active {
    border-color: var(--primary-orange);
}

/* ── 产品信息区 ── */
.pd-info { flex: 1; min-width: 0; }

.pd-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.4;
    margin-bottom: 12px;
}

.pd-price {
    font-size: 22px;
    font-weight: 700;
    color: var(--primary-orange);
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--gray-200);
}

.pd-param-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    margin-bottom: 16px;
}
.pd-param-table tr { border-bottom: 1px dashed var(--gray-200); }
.pd-param-table td { padding: 7px 0; color: var(--text-primary); }
.pd-param-label {
    width: 70px;
    color: var(--text-tertiary);
    padding-right: 12px;
    white-space: nowrap;
}
.pd-param-table a { color: #2979ff; }

/* ── CTA 按钮 ── */
.pd-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--gray-200);
}
.pd-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
    border: 1px solid transparent;
    transition: opacity 0.15s, transform 0.1s;
}
.pd-btn:hover { opacity: 0.88; transform: translateY(-1px); }
.pd-btn--primary {
    background: var(--primary-orange);
    color: #fff;
    border-color: var(--primary-orange);
    padding: 12px 28px;
    font-size: 15px;
}
.pd-btn--secondary {
    background: #fff;
    color: var(--primary-orange);
    border-color: var(--primary-orange);
}
.pd-btn--wechat {
    background: #07c160;
    color: #fff;
    border-color: #07c160;
}
.pd-btn--block { width: 100%; }

/* ── 微信弹出 ── */
.pd-wechat-wrap { position: relative; display: inline-flex; }
.pd-wechat-popup {
    display: none;
    position: absolute;
    bottom: 110%;
    left: 50%;
    transform: translateX(-50%);
    background: #fff;
    border: 1px solid var(--gray-400);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    padding: 12px;
    text-align: center;
    z-index: 10;
    white-space: nowrap;
}
.pd-wechat-wrap:hover .pd-wechat-popup { display: block; }
.pd-wechat-popup__qr { width: 120px; height: 120px; display: block; margin: 0 auto 8px; }
.pd-wechat-popup__id { font-size: 12px; color: var(--text-secondary); }

/* ── Section 区块 ── */
.pd-section {
    background: #fff;
    border: 1px solid var(--gray-300);
    margin-bottom: 16px;
}
.pd-section-head {
    padding: 12px 20px;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    border-bottom: 1px solid var(--gray-300);
    border-left: 3px solid var(--primary-orange);
}
.pd-section-body {
    padding: 16px 20px;
    font-size: 14px;
    line-height: 1.8;
    color: #444;
}

/* 降级 section：Trade / Company Profile */
.pd-section--trade .pd-section-head,
.pd-section--company .pd-section-head {
    border-left: none;
    background: var(--gray-50);
    font-size: 14px;
    color: var(--text-secondary);
}
.pd-section--trade,
.pd-section--company {
    border-color: var(--gray-200);
}

/* 正文 */
.rich-text img { max-width: 100%; height: auto; margin: 8px 0; }
.rich-text p { margin-bottom: 12px; }
.empty-state { color: var(--text-tertiary); padding: 20px 0; }

/* 企业简介表格 */
.pd-profile-grid { display: grid; grid-template-columns: 1fr; gap: 0; }
.pd-profile-row {
    display: flex;
    padding: 8px 0;
    border-bottom: 1px dashed var(--gray-200);
    font-size: 13px;
}
.pd-profile-label {
    width: 80px;
    flex-shrink: 0;
    color: var(--text-tertiary);
}
.pd-profile-value {
    flex: 1;
    color: var(--text-primary);
    word-break: break-all;
}

/* 相关资讯列表 */
.pd-article-list {
    list-style: none;
    padding: 0; margin: 0;
}
.pd-article-list li {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px dashed var(--gray-200);
    font-size: 13px;
}
.pd-article-list li a { color: var(--text-primary); flex: 1; }
.pd-article-list li a:hover { color: var(--primary-orange); }
.pd-article-list li .muted { font-size: 12px; color: var(--text-tertiary); flex-shrink: 0; margin-left: 12px; }

/* ── 右栏 ── */
.pd-company-card {
    background: #fff;
    border: 1px solid var(--gray-300);
    margin-bottom: 16px;
}
.pd-company-head {
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 600;
    background: var(--gray-50);
    border-bottom: 1px solid var(--gray-300);
}
.pd-company-body { padding: 14px 16px; }
.pd-company-name {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 10px;
}
.pd-company-name a { color: var(--text-primary); }
.pd-company-name a:hover { color: var(--primary-orange); }

.pd-badge {
    display: inline-block;
    font-size: 11px;
    padding: 1px 6px;
    border-radius: 2px;
    margin-left: 6px;
    vertical-align: middle;
}
.pd-badge--vip { background: linear-gradient(135deg, #312e81, #4338ca); color: #fff; font-weight: 700; }
.pd-badge--verified { background: #dcfce7; color: #15803d; font-weight: 700; }

.pd-company-list {
    list-style: none;
    padding: 0; margin: 0 0 12px;
    font-size: 13px;
}
.pd-company-list li {
    display: flex;
    padding: 5px 0;
    border-bottom: 1px dashed var(--gray-100);
}
.pd-company-list li span {
    width: 50px;
    color: var(--text-tertiary);
    flex-shrink: 0;
}
.pd-company-list li em {
    font-style: normal;
    color: var(--text-primary);
}
.pd-phone { color: var(--primary-orange); font-weight: 500; }
.wechat-qr-btn {
    font-size: 12px;
    color: #07c160;
    margin-left: 8px;
    cursor: pointer;
}

.pd-company-actions {
    display: flex;
    gap: 8px;
}
.pd-company-actions .pd-btn {
    flex: 1;
    padding: 7px 0;
    font-size: 13px;
}

/* ── 右栏：其他产品 ── */
.pd-side-box {
    background: #fff;
    border: 1px solid var(--gray-300);
    margin-bottom: 16px;
}
.pd-side-head {
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 600;
    background: var(--gray-50);
    border-bottom: 1px solid var(--gray-300);
    border-left: 3px solid var(--primary-orange);
}

.pd-other-list { padding: 8px 12px; }
.pd-other-item {
    display: flex;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px dashed var(--gray-200);
    text-decoration: none;
    align-items: center;
}
.pd-other-item:last-child { border-bottom: none; }
.pd-other-item img {
    width: 56px; height: 56px;
    object-fit: cover;
    border: 1px solid var(--gray-300);
    flex-shrink: 0;
}
.pd-other-info { flex: 1; min-width: 0; }
.pd-other-title {
    display: block;
    font-size: 13px;
    color: var(--text-primary);
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}
.pd-other-item:hover .pd-other-title { color: var(--primary-orange); }
.pd-other-price {
    font-size: 12px;
    color: var(--primary-orange);
    margin-top: 4px;
    display: block;
}

/* ── 右栏：快速询价 ── */
.pd-inquiry-mini { padding: 12px 16px; }
.pd-inquiry-mini input,
.pd-inquiry-mini textarea {
    width: 100%;
    padding: 7px 10px;
    border: 1px solid var(--gray-400);
    border-radius: 3px;
    font-size: 13px;
    margin-bottom: 8px;
    box-sizing: border-box;
}
.pd-inquiry-mini input:focus,
.pd-inquiry-mini textarea:focus {
    border-color: var(--primary-orange);
    outline: none;
}
.pd-inquiry-mini .pd-btn { margin-top: 4px; }
.pd-form-note { font-size: 11px; color: #64748b; text-align: center; margin-top: 8px; line-height: 1.4; }

/* ── 询盘弹窗 ── */
.iq-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}
.iq-overlay.is-show { display: flex; }
.iq-dialog {
    background: #fff;
    width: 420px;
    max-width: 90vw;
    padding: 28px 24px;
    position: relative;
    border-radius: 4px;
}
.iq-close {
    position: absolute;
    right: 12px; top: 12px;
    font-size: 20px;
    color: var(--text-tertiary);
    cursor: pointer;
    background: none;
    border: none;
}
.iq-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--text-primary);
}
.iq-subtitle {
    font-size: 13px;
    color: #64748b;
    margin-bottom: 20px;
    line-height: 1.5;
}
.iq-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}
.iq-form .iq-field {
    margin-bottom: 14px;
}
.iq-form label {
    display: block;
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}
.iq-form input {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid var(--gray-400);
    border-radius: 3px;
    font-size: 14px;
    box-sizing: border-box;
}
.iq-form input:focus { border-color: var(--primary-orange); outline: none; }
.iq-form textarea {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid var(--gray-400);
    border-radius: 3px;
    font-size: 14px;
    box-sizing: border-box;
    resize: vertical;
    font-family: inherit;
}
.iq-form textarea:focus { border-color: var(--primary-orange); outline: none; }
.iq-submit-btn { margin-top: 8px; }
.iq-tip { font-size: 11px; color: var(--text-tertiary); margin-top: 10px; text-align: center; }
.iq-success { padding: 24px 16px; text-align: center; }
.iq-success strong { display: block; font-size: 16px; color: #15803d; margin-bottom: 8px; }
.iq-success p { font-size: 13px; color: #475569; line-height: 1.6; }

/* ── Tiered Pricing Grid ── */
.pd-tier-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
}
.pd-tier-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 14px 10px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 6px;
    text-align: center;
    position: relative;
}
.pd-tier-card:last-child {
    background: #ecfdf5;
    border-color: #6ee7b7;
    box-shadow: 0 0 0 1px #6ee7b7;
}
.pd-tier-card:last-child::after {
    content: 'Best Price';
    position: absolute;
    top: -8px;
    right: 8px;
    font-size: 10px;
    font-weight: 700;
    color: #fff;
    background: #059669;
    padding: 1px 6px;
    border-radius: 3px;
    letter-spacing: 0.3px;
}
.pd-tier-range {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}
.pd-tier-price {
    font-size: 18px;
    font-weight: 700;
    color: #15803d;
}

/* ── Trade Terms Table ── */
.pd-trade-table {
    width: 100%;
    border-collapse: collapse;
}
.pd-trade-table td {
    padding: 10px 12px;
    border-bottom: 1px solid var(--border-light, #f1f5f9);
    font-size: 13px;
    color: var(--text-primary);
    vertical-align: top;
}
.pd-trade-label {
    width: 120px;
    font-weight: 600;
    color: var(--text-secondary);
    white-space: nowrap;
}

/* ── Specifications Table ── */
.pd-specs-table {
    width: 100%;
    border-collapse: collapse;
}
.pd-specs-table tr:nth-child(even) { background: #f8fafc; }
.pd-specs-table td {
    padding: 10px 12px;
    border-bottom: 1px solid var(--border-light, #f1f5f9);
    font-size: 13px;
    vertical-align: top;
}
.pd-spec-label {
    width: 160px;
    font-weight: 600;
    color: var(--text-secondary);
    white-space: nowrap;
}
.pd-spec-value {
    color: var(--text-primary);
}

/* ── 微信弹层 ── */
.wechat-qr-modal { display: none; position: fixed; inset: 0; z-index: 1100; }
.wechat-qr-modal.is-show { display: block; }
.wechat-qr-modal__mask { position: absolute; inset: 0; background: rgba(0,0,0,0.4); }
.wechat-qr-modal__box {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    background: #fff;
    padding: 24px;
    text-align: center;
    border-radius: 4px;
    min-width: 240px;
}
.wechat-qr-modal__close {
    position: absolute;
    right: 10px; top: 8px;
    font-size: 20px;
    color: var(--text-tertiary);
    cursor: pointer;
    background: none;
    border: none;
}
.wechat-qr-modal__title { font-size: 14px; margin-bottom: 12px; color: var(--text-primary); }
.wechat-qr-modal__img { width: 180px; height: 180px; margin: 0 auto 10px; display: block; }
.wechat-qr-modal__id { font-size: 12px; color: var(--text-secondary); }

/* ── 响应式 ── */
@media (max-width: 1024px) {
    .pd-top { flex-direction: column; }
    .pd-gallery { width: 100%; max-width: 400px; }
}
@media (max-width: 900px) {
    .pd-layout { flex-direction: column; }
    .pd-side { width: 100%; }
}
@media (max-width: 600px) {
    .pd-top { padding: 14px; }
    .pd-section-body { padding: 12px 14px; }
    .pd-title { font-size: 17px; }
    .pd-price { font-size: 18px; }
    .pd-tier-grid { grid-template-columns: repeat(2, 1fr); }
    .pd-spec-label, .pd-trade-label { width: auto; white-space: normal; }
}
@media (max-width: 480px) {
    .pd-top { padding: 10px; }
    .pd-gallery { max-width: 100%; }
    .pd-section-head { padding: 10px 12px; font-size: 14px; }
    .pd-section-body { padding: 10px 12px; }
    .pd-meta-grid { grid-template-columns: 1fr; }
    .pd-title { font-size: 16px; }
}
