/*  
Theme Name: 简站主题For1a25trade1-b
Theme URI: http://www.jianzhanpress.com
Description: 本主题为简站主题www.jianzhanpress.com定制.
Version: 1.0
Author: jianzhanpress.com
Author URI: http://www.jianzhanpress.com
*/
/* 控制视频组的居中与宽度 */
.video-center-custom {
    max-width: 900px !important; /* 电脑端最大宽度，可改为800px/1000px */
    margin: 30px auto !important; /* 上下留空，左右自动居中 */
    padding: 0 15px !important; /* 防止手机端贴边 */
}
/* 固定视频16:9比例，避免拉伸变形 */
.video-center-custom .wp-block-embed__wrapper {
    position: relative;
    padding-bottom: 56.25% !important;
    height: 0 !important;
    overflow: hidden !important;
}
/* 让视频填满容器 */
.video-center-custom iframe {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
}
/* 手机端自适应（自动缩小宽度） */
@media (max-width: 768px) {
    .video-center-custom {
        max-width: 100% !important; /* 手机端充满屏幕 */
    }
}

/* 1. 确保头部容器内所有元素垂直方向“绝对对齐” */
#myheader .container {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    justify-content: space-between !important;
    align-items: center !important; /* 强制所有元素在这一行的中心线上 */
    height: 80px !important; /* 设定一个固定高度，确保稳定性，可根据需要微调 */
}

/* 2. 菜单容器：取消可能的偏移，确保居中 */
#myheader .navbar-collapse {
    flex: 1 !important;
    display: flex !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* 3. 电话组件：彻底抹平高度差 */
.header-contact {
    margin: 0 !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center !important; /* 确保图标和文字水平齐平 */
    position: static !important; /* 放弃之前的 top 偏移 */
    transform: none !important;
    white-space: nowrap !important;
}

/* 针对内部图标和文字的微调 */
.header-contact .d-flex {
    align-items: center !important;
}

/* 4. 如果导航文字太挤，适当压缩间距确保一行放下 */
#myheader .nav-link {
    padding-left: 12px !important;
    padding-right: 12px !important;
}

/* 5. 移动端保护 */
@media (max-width: 991px) {
    #myheader .container {
        height: auto !important;
        flex-wrap: wrap !important;
    }
}