/* ==========================================================
 * 展会单页样式 (Exhibition Single Page)
 * 路径: wp-content/plugins/mx-matrix-engine/assets/css/components/exhibition.css
 * 作用：A方案 - 左侧阅读，右侧粘性转化漏斗
 * ========================================================== */

/* =========================================
   🛡️ MX Matrix 精准防御盾 (展会单页内外兼顾版)
   ========================================= */

/* 1. ⚠️ 绝对保留：千万不要写 margin: 0 去破坏外部侧边栏和顶部的骨架留白！让主题自己控制。 */

/* 2. 电脑端 (≥769px)：只优化白底卡片内部的 padding 为 20px */
@media (min-width: 769px) {
    body.single-mx_exhibition .inside-article {
        padding: 20px !important; 
    }
}

/* 3. 手机/平板端 (≤768px)：赋予移动端白底卡片上下 30px、左右 10px 的呼吸空间 */
@media (max-width: 768px) {
    body.single-mx_exhibition .inside-article {
        padding: 30px 10px !important; 
    }
}

/* 4. 内部模块清零防御：脱去底部“翻页导航”等自带 mx-matrix-wrapper 模块的额外左右护甲，使其与正文完美对齐 */
body.single-mx_exhibition .inside-article .mx-matrix-wrapper > div {
    padding-left: 0 !important;
    padding-right: 0 !important;
    max-width: 100% !important; /* 确保模块 100% 撑满文章白底卡片区域 */
}

/* --- 2. 核心 Grid 布局：完美解决右侧空洞 --- */
.mx-single-layout {
    display: grid;
    grid-template-columns: 1fr 360px; /* 左侧自适应填满，右侧锁定 360px */
    gap: 50px;
    align-items: start; /* 必须加：防止侧边栏被左侧内容撑高拉伸 */
    margin-bottom: 80px;
}

/* --- 3. 左侧主内容区 --- */
.mx-single-title {
    font-size: 36px;
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 30px;
    color: #111;
    border: none !important; /* 屏蔽外部主题可能添加的边框 */
    padding: 0 !important;
}

/* 保护正文内容里的图片排版 */
.mx-single-content {
    font-size: 16px;
    line-height: 1.7;
    color: #333;
}
.mx-single-content img {
    border-radius: 2px;
    margin: 20px 0;
    border: 1px solid #eaeaea;
    max-width: 100%;
    height: auto;
}

/* --- 4. 右侧侧边栏 (Sticky 魔法) --- */
.mx-single-sidebar {
    position: sticky;
    top: 120px; /* 距离浏览器顶部的悬浮距离，可根据你的 Header 高度微调 */
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* 侧边栏卡片通用样式 */
.mx-sidebar-card {
    background: #fff;
    border: 1px solid #eaeaea;
    border-radius: 2px;
    padding: 25px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.02);
}

.mx-sidebar-card h3 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 20px;
    text-transform: uppercase;
    border-bottom: 2px solid #111;
    padding-bottom: 10px;
    display: inline-block;
}

/* 核心信息列表 */
.mx-sidebar-list { list-style: none; padding: 0; margin: 0; }
.mx-sidebar-list li { 
    margin-bottom: 12px; 
    display: flex; 
    align-items: flex-start; 
    gap: 8px; 
    font-size: 15px; 
    color: #444; 
    line-height: 1.5;
}
.mx-sidebar-list li .dashicons { color: #0056b3; margin-top: 2px; }
.mx-highlight-text { 
    background: #f8f9fa; 
    padding: 6px 10px; 
    border-radius: 2px; 
    width: 100%; 
    box-sizing: border-box;
}

/* 专家名片特化 */
.mx-expert-card { border-top: 3px solid #0056b3; } /* 顶部蓝条强调 */
.mx-expert-header { display: flex; align-items: center; gap: 15px; margin-bottom: 15px; }
.mx-expert-avatar { 
    width: 50px; 
    height: 50px; 
    background: #f1f3f5; 
    border-radius: 50%; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    font-weight: 700; 
    color: #0056b3; 
    font-size: 18px; 
}
.mx-expert-name h4 { margin: 0 0 4px 0; font-size: 16px; font-weight: 700; color: #111; }
.mx-expert-name p { margin: 0; font-size: 12px; color: #666; line-height: 1.2; text-transform: uppercase;}
.mx-expert-desc { font-size: 14px; color: #555; margin-bottom: 20px; line-height: 1.5; }

/* 按钮样式复用/覆盖 */
.mx-btn-full { 
    display: block; 
    width: 100%; 
    text-align: center; 
    padding: 12px 0;
    box-sizing: border-box;
}

/* --- 5. 移动端降级处理 --- */
/* 当屏幕小于 992px 时，自动变为单列，侧边栏堆叠在正文下方 */
@media (max-width: 991px) {
    .mx-single-layout {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    .mx-single-sidebar {
        position: static; /* 移动端取消悬浮，回归正常文档流 */
    }
}

/* 展会单页：右侧边栏智能悬浮 (Sticky Sidebar) */
.single-mx_exhibition .inside-right-sidebar {
    position: sticky;
    top: 120px; /* 距离浏览器顶部的悬浮高度，你可以根据自己顶部导航栏的高度微调 */
    transition: all 0.3s ease;
}

/* 移动端防溢出：屏幕小于 992px 时解除悬浮，恢复正常上下堆叠排版 */
@media (max-width: 991px) {
    .single-mx_exhibition .inside-right-sidebar {
        position: static;
    }
}

/* 优化专家按钮交互视觉：同步工业风配色与直角，但保持侧边栏原有的精巧尺寸 */
.mx-expert-widget .mx-btn-primary {
    background-color: var(--mx-text-dark, #1a1a1a) !important; /* 默认纯黑 */
    color: var(--mx-bg-white, #ffffff) !important; 
    font-size: 14px !important; /* 恢复原版较小的字号，避免文字撑爆 */
    font-weight: 500 !important;
    padding: 10px 0 !important; /* 恢复原版的上下 10px 间距，让按钮变回纤细 */
    border-radius: 0 !important; /* 强制直角 */
    border: none !important;
    box-shadow: none !important; /* 移除阴影 */
    transition: all 0.3s ease !important;
    text-transform: uppercase !important; /* 确保全大写 */
    font-family: inherit;
}

.mx-expert-widget .mx-btn-primary:hover {
    background-color: var(--mx-accent-blue, #0056B3) !important; /* 悬停变成工业蓝 */
    transform: none !important; /* 取消悬停时的上浮位移 */
    box-shadow: none !important; /* 取消悬停阴影 */
}