@charset "UTF-8";
/* =========================================================
   培训门户 - 城市频道页（c_bj）PC 页面 —— 移动端适配样式
   说明：本文件只做样式覆盖，不改动任何页面结构（DOM）
   ========================================================= */

/* ---------------------------------------------------------
   一、通用：解除 1220px 定宽限制（平板及以下）
   --------------------------------------------------------- */
@media screen and (max-width: 1220px) {
  html,
  body {
    min-width: 0;
  }
  .w_1220,
  .contWidth {
    width: 100%;
    max-width: 1220px;
    padding-left: 12px;
    padding-right: 12px;
  }
  img {
    max-width: 100%;
  }
  /* 主体两栏：左栏自适应，右栏保持固定宽 */
  .main-content .main-left {
    width: auto;
    flex: 1 1 auto;
    min-width: 0;
  }
  .main-content .main-right {
    width: 260px;
    flex: 0 0 260px;
  }
  /* 顶部通栏：左占位块换行，轮播区占满 */
  .banner-box {
    flex-wrap: wrap;
  }
  .banner-box .banner-block {
    flex: 1 1 100%;
  }
  .banner-box .banner-box-l {
    width: 100%;
    margin-left: 0;
  }
}

/* ---------------------------------------------------------
   二、移动端主体适配（<=768px）
   --------------------------------------------------------- */
@media screen and (max-width: 768px) {

  /* ===== 基础 ===== */
  html,
  body {
    min-width: 0;
    overflow-x: hidden;
    -webkit-text-size-adjust: 100%;
  }
  body {
    font-size: 13px;
    background-color: #f5f5f5;
  }
  img {
    max-width: 100%;
    height: auto;
  }
  .w_1220,
  .contWidth {
    width: 100%;
    padding-left: 10px;
    padding-right: 10px;
  }
  .mt10 {
    margin-top: 10px;
  }

  /* ===== 顶部城市条 ===== */
  .head-city {
    position: relative;
    z-index: 9000;
    height: auto;
    min-height: 30px;
    line-height: 22px;
    font-size: 11px;
    padding: 4px 0;
  }
  .head-city .head-city-1220 {
    /* 作为下拉面板的定位参照，使面板可以铺满整行宽度 */
    position: relative;
    flex-wrap: wrap;
  }
  .head-city .head-city-left > span,
  .head-city .head-city-right > span {
    margin: 0 3px;
  }
  .head-city .head-city-left > span:nth-of-type(2) {
    display: none;
  }
  .head-city .head-city-right > a {
    padding: 0 4px;
  }

  /* ===== 网站导航下拉 =====
     PC 是 1218px 宽的横向四列悬浮面板，移动端改为
     整屏宽度、纵向堆叠、可整块滚动的下拉面板，并改为点击展开 */
  .head-city .head-city-nav {
    position: static;
    margin-left: 10px;
  }
  .head-city .head-city-dh {
    padding: 3px 6px;
    font-size: 12px;
  }
  .head-city .head-city-dh img {
    width: 9px;
    height: 9px;
    margin-left: 3px;
    transition: transform 0.2s ease-out;
  }
  .head-city .head-city-nav.open .head-city-dh {
    color: #ff6c00;
  }
  .head-city .head-city-nav.open .head-city-dh img {
    transform: rotate(180deg);
  }
  /* 移动端屏蔽 hover 展开，统一用点击控制，避免触屏“粘滞 hover”打不开/关不掉 */
  .head-city .head-city-nav:hover .head-city-dropdown {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-8px);
  }
  .head-city .head-city-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    width: auto;
    max-width: 100%;
    max-height: calc(100vh - 56px);
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    padding: 4px 0 8px;
    box-sizing: border-box;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
    transform-origin: 50% 0;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-8px);
    transition: opacity 0.22s ease-out, transform 0.22s ease-out, visibility 0.22s;
  }
  .head-city .head-city-nav.open .head-city-dropdown {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
  }
  /* 四列固定宽度 -> 单列纵向堆叠，取消各自独立滚动 */
  .head-city .head-city-dropdown li,
  .head-city .head-city-dropdown li.li1,
  .head-city .head-city-dropdown li.li2,
  .head-city .head-city-dropdown li.li3,
  .head-city .head-city-dropdown li.li4 {
    width: 100%;
    height: auto;
    padding: 0 12px 12px;
    overflow: visible;
    border-right: 0;
    border-bottom: 1px solid #efefef;
    box-sizing: border-box;
  }
  .head-city .head-city-dropdown li:last-child {
    border-bottom: 0;
    padding-bottom: 4px;
  }
  .head-city .head-city-dropdown li .m_sitenav_til {
    margin-top: 14px;
    font-size: 15px;
  }
  /* 链接改为胶囊标签，去掉 PC 的固定宽度与外边距，保证点击区域 */
  .head-city .head-city-dropdown li dl {
    padding-top: 6px;
  }
  .head-city .head-city-dropdown li dd {
    flex: 0 0 auto;
    margin: 8px 8px 0 0;
  }
  .head-city .head-city-dropdown li dl a {
    display: block;
    width: auto;
    margin: 0;
    padding: 7px 12px;
    font-size: 13px;
    line-height: 18px;
    color: #6d6d6d;
    background-color: #f6f7f9;
    border-radius: 4px;
    white-space: nowrap;
  }
  .head-city .head-city-dropdown li.li1 a,
  .head-city .head-city-dropdown li.li2 a,
  .head-city .head-city-dropdown li.li3 a,
  .head-city .head-city-dropdown li.li4 a {
    width: auto;
    margin-top: 0;
  }

  /* ===== LOGO + 搜索 ===== */
  .head-main .head-search-box {
    display: flex;
    flex-direction: column;
    height: auto;
    padding-top: 10px;
    padding-bottom: 10px;
  }
  .head-main .head-search-box .logo {
    margin-top: 0 !important;
    height: auto;
    align-self: flex-start;
  }
  .head-main .head-search-box .logo img {
    width: 116px;
    height: auto;
  }
  .head-main .head-search-box .head-search-r {
    margin-top: 10px;
    width: 100%;
  }
  .head-main .head-search-box .head-search-r dl {
    padding-left: 0;
  }
  .head-main .head-search-box .head-search-input {
    width: 100%;
  }
  .head-main .head-search-box .head-search-input input {
    flex: 1 1 auto;
    width: auto;
    min-width: 0;
    height: 38px;
    padding-left: 30px;
    font-size: 14px;
  }
  .head-main .head-search-box .head-search-input button {
    flex: 0 0 64px;
    width: 64px;
    height: 38px;
    line-height: 38px;
    font-size: 15px;
  }
  .head-main .head-search-box .head-search-input .input_lx {
    width: 100%;
    top: 38px;
  }
  .head-main .head-search-box .head-search-tj {
    padding-left: 0;
    margin-top: 6px;
    flex-wrap: wrap;
  }
  .head-main .head-search-box .head-search-tj a {
    margin-right: 12px;
    line-height: 24px;
  }

  /* ===== 主导航：分类按钮 + 导航横向滚动 ===== */
  .head-main .head-nav {
    margin-top: 6px;
    padding-bottom: 4px;
  }
  /* 手机端「全部分类」按钮及其下拉大面板整体隐藏 */
  .head-main .head-nav-l {
    display: none !important;
  }
  .head-main .head-nav-ul {
    margin-left: 0;
    flex: 1 1 auto;
    min-width: 0;
    overflow-x: auto;
    overflow-y: hidden;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
  }
  .head-main .head-nav-ul::-webkit-scrollbar {
    display: none;
  }
  .head-main .head-nav-ul li {
    flex: 0 0 auto;
    margin-right: 18px;
  }
  .head-main .head-nav-ul a {
    font-size: 14px;
    line-height: 34px;
  }

  /* ===== 主体两栏改为单列 ===== */
  .main-content {
    flex-direction: column;
  }
  .main-content .main-left,
  .main-content .main-right {
    width: 100%;
    flex: 0 0 auto;
  }
  .main-content .main-right {
    margin-top: 10px;
  }

  /* ===== 面包屑 ===== */
  .crumbs {
    height: auto;
    padding: 14px 12px;
    box-sizing: border-box;
    line-height: 22px;
    font-size: 12px;
    flex-wrap: wrap;
  }
  .crumbs i {
    margin: 0 4px;
  }

  /* ===== 机构动态列表 ===== */
  .main-left .main-title {
    padding-left: 12px;
    font-size: 15px;
    line-height: 44px;
  }
  .info-list li {
    padding: 12px;
    min-height: 0;
  }
  .info-list li .info-logo {
    flex: 0 0 112px;
    width: 112px;
    height: 76px;
    margin-right: 10px;
  }
  .info-list li .info-r .info-name {
    font-size: 14px;
    line-height: 20px;
    margin-bottom: 4px;
  }
  /* PC 摘要是固定 44px 高，移动端交给 ellipsis-2 自己裁剪 */
  .info-list li .info-r p {
    height: auto;
    margin-bottom: 8px;
    font-size: 12px;
    line-height: 20px;
  }
  .info-list li .info-r span {
    font-size: 11px;
  }

  /* ===== 分页 ===== */
  .dzw-pagation {
    padding: 24px 6px;
  }
  .dzw-pagation .pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    height: auto;
    margin: 0;
  }
  .dzw-pagation .pagination li {
    margin: 6px 4px;
  }
  /* 上一页 / 下一页 与页码之间多留一些间距 */
  .dzw-pagation .pagination li.prev,
  .dzw-pagation .pagination li.next {
    margin: 6px 8px;
    padding: 0 6px;
  }
  .dzw-pagation .pagination li a {
    padding: 4px 9px;
    font-size: 13px;
    line-height: 20px;
  }

  /* ===== 右栏：5 分钟选课表单 ===== */
  .bxk-outer .bxk-top {
    height: auto;
    padding: 12px 0;
    background-size: cover;
  }
  .bxk-outer .bxk-top h4 {
    padding-top: 0;
    font-size: 17px;
    line-height: 24px;
  }
  .bxk-outer .bxk-top p {
    font-size: 12px;
    letter-spacing: 2px;
  }
  .bxk-outer .bxk-form {
    padding: 12px;
    box-sizing: border-box;
  }
  .bxk-outer .bxk-form-item {
    margin-bottom: 8px;
  }
  .bxk-outer .bxk-form-item input {
    height: 38px;
    font-size: 14px;
  }
  .bxk-outer .bxk-btn {
    width: 100%;
    height: 40px;
    line-height: 40px;
    font-size: 15px;
  }

  /* ===== 顶部轮播 ===== */
  /* 手机端隐藏该块（内含轮播图 + 热门分类） */
  .banner-box .banner-box-l {
    display: none !important;
  }
  .banner-box .banner-swiper {
    height: 44vw;
    min-height: 130px;
    max-height: 200px;
  }
  .banner-box .banner-swiper .swiper-slide img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
  /* 左右箭头为 hover 显示，移动端不展示 */
  .banner-box .banner-swiper .swiper-btn {
    display: none;
  }
  .banner-box .banner-swiper .swiper-pagination {
    bottom: 8px;
    height: 12px;
  }
  .banner-box .banner-swiper .swiper-pagination .swiper-pagination-bullet {
    width: 6px;
    height: 6px;
    margin: 3px 6px 0;
  }

  /* ===== 热门分类 / 热门城市：改为上下两块 ===== */
  .banner-box .banner-hot {
    flex-direction: column;
  }
  .banner-box .banner-hot .banner-hot-item {
    padding: 0 12px 12px;
  }
  .banner-box .banner-hot .banner-hot-item + .banner-hot-item {
    border-left: 0;
    border-top: 1px solid #ededee;
    padding-top: 12px;
  }
  .banner-box .banner-hot .banner-hot-item .banner-hot-tit {
    height: auto;
    padding: 10px 0;
    margin-bottom: 8px;
    font-size: 14px;
  }
  .banner-box .banner-hot .banner-hot-item ul li {
    width: calc((100% - 24px) / 3);
    margin: 8px 12px 0 0;
    font-size: 13px;
    line-height: 20px;
    text-align: center;
  }
  .banner-box .banner-hot .banner-hot-item ul li:nth-child(4n) {
    margin-right: 12px;
  }
  .banner-box .banner-hot .banner-hot-item ul li:nth-child(3n) {
    margin-right: 0;
  }

  /* ===== 行业聚合区块 ===== */
  .aggregation-box {
    padding: 12px;
    margin-bottom: 10px;
  }
  .aggregation-box .aggregation-box-title {
    flex-wrap: wrap;
    margin-bottom: 12px;
  }
  .aggregation-box .aggregation-box-title > span {
    font-size: 15px;
    line-height: 22px;
    margin-right: 12px;
  }
  .aggregation-box .aggregation-box-title > a {
    margin-left: auto;
    font-size: 12px;
  }
  /* 分类 tab：独占一行，横向滑动 */
  .aggregation-box .aggregation-tab {
    flex: 1 1 100%;
    margin-top: 8px;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 2px;
  }
  .aggregation-box .aggregation-tab::-webkit-scrollbar {
    display: none;
  }
  .aggregation-box .aggregation-tab > li {
    flex: 0 0 auto;
    margin-right: 8px;
  }
  .aggregation-box .aggregation-tab > li a {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 14px;
    font-size: 12px;
    line-height: 18px;
    white-space: nowrap;
  }
  /* 「查看更多」由 JS 移到 ul 末尾，跟着标签横向滑动，拉到最右边才看得到 */
  .aggregation-box .aggregation-tab > li.tab-more {
    margin-right: 12px;
  }
  .aggregation-box .aggregation-tab > li.tab-more a {
    color: #FF6C00;
    border-color: rgba(255, 108, 0, 0.45);
    background-color: rgba(255, 108, 0, 0.06);
  }

  /* 机构列表：两列改单列 */
  .aggregation-box .aggregation-jg-ul li {
    width: 100%;
    margin-top: 14px;
  }
  .aggregation-box .aggregation-jg-ul li:first-child {
    margin-top: 4px;
  }
  .aggregation-box .aggregation-jg-ul li:nth-child(2n) {
    margin-left: 0;
  }
  .aggregation-box .aggregation-jg-ul li .aggregation-jg-logo {
    flex: 0 0 112px;
    width: 112px;
    height: 76px;
    margin-right: 10px;
  }
  .aggregation-box .aggregation-jg-ul li .aggregation-jg-r .aggregation-jg-name {
    font-size: 14px;
  }
  .aggregation-box .aggregation-jg-ul li .aggregation-jg-r .aggregation-jg-xq {
    margin: 6px 0;
    font-size: 12px;
  }
  .aggregation-box .aggregation-jg-ul li .aggregation-jg-r .aggregation-jg-info dd {
    font-size: 12px;
    margin-right: 8px;
  }
  .aggregation-box .aggregation-jg-ul li .aggregation-jg-r .aggregation-jg-b {
    margin-top: 8px;
    flex-wrap: wrap;
  }
  .aggregation-box .aggregation-jg-ul li .aggregation-jg-r .aggregation-jg-b a {
    width: 68px;
    height: 24px;
    line-height: 24px;
  }

  /* ===== 右栏：热推机构 / 热推课程 / 列表 ===== */
  .office-cont-right .office-cont-title {
    height: 44px;
    line-height: 44px;
    font-size: 14px;
    padding: 0 12px;
  }
  .office-city-jg ul {
    padding: 0 12px 12px;
  }
  .office-city-jg ul li {
    width: calc((100% - 10px) / 2);
    margin-right: 10px;
    margin-top: 12px;
  }
  .office-city-jg ul li:nth-child(2n) {
    margin-right: 0;
  }
  .office-city-jg ul li .jg-logo {
    height: 64px;
  }
  .office-cont-kc li {
    padding: 12px;
  }
  .office-cont-kc li a .office-cont-kc-logo {
    flex: 0 0 84px;
    width: 84px;
    height: 50px;
    margin-right: 10px;
  }
  .office-cont-kc li a .office-cont-kc-r {
    flex: 1 1 auto;
    min-width: 0;
  }
  .office-cont-kc li a .office-cont-kc-r h3 {
    font-size: 13px;
    line-height: 18px;
  }
  .office-cont-info li {
    padding: 12px 12px 12px 16px;
    font-size: 13px;
    line-height: 18px;
  }
  .office-cont-info li a::before {
    left: 6px;
  }

  /* ===== 底部说明文字 ===== */
  body .main-tip {
    width: auto;
    max-width: 100%;
    padding: 12px;
    margin: 10px auto;
    line-height: 20px;
    font-size: 12px;
  }

  /* ===== 区块标题 ===== */
  .related-tit p {
    padding-left: 12px;
    line-height: 44px;
    font-size: 15px;
  }
  .related-tit a {
    margin-right: 12px;
    line-height: 44px;
    font-size: 12px;
  }

  /* ===== 相关推荐 ===== */
  .related-tj-box {
    padding: 12px;
  }
  .related-tj-box .tj-nav-tab {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .related-tj-box .tj-nav-tab::-webkit-scrollbar {
    display: none;
  }
  .related-tj-box .tj-nav-tab dd {
    flex: 0 0 auto;
    padding: 6px 10px;
    font-size: 13px;
  }
  .related-tj-box .related-tj-list {
    padding: 12px 12px 0;
  }
  .related-tj-box .related-tj-list ul li {
    margin: 0 12px 12px 0;
  }
  .related-tj-box .related-tj-list ul li a {
    font-size: 13px;
  }

  /* ===== 页脚 ===== */
  .m-footer {
    padding: 18px 10px 24px;
  }
  .m-footer .m-footer-link {
    flex-wrap: wrap;
    line-height: 22px;
  }
  .m-footer .m-footer-link span {
    margin: 0 2px;
  }
  .m-footer .m-footer-text1 {
    line-height: 26px;
  }
  .m-footer .m-footer-text2 {
    flex-wrap: wrap;
    line-height: 22px;
  }
  .m-footer .m-footer-text2 p {
    margin-right: 8px;
  }
  .m-footer .m-footer-orther-link {
    margin-top: 16px;
    flex-wrap: wrap;
  }
  .m-footer .m-footer-orther-link a {
    margin-right: 12px;
  }
  .m-footer .m-footer-orther-link img {
    height: 34px;
    width: auto;
  }
}

/* ---------------------------------------------------------
   三、超小屏（<=360px）微调
   --------------------------------------------------------- */
@media screen and (max-width: 360px) {
  .head-main .head-search-box .logo img {
    width: 100px;
  }
  .banner-box .banner-hot .banner-hot-item ul li {
    width: calc((100% - 16px) / 2);
    margin-right: 16px;
  }
  .banner-box .banner-hot .banner-hot-item ul li:nth-child(3n) {
    margin-right: 16px;
  }
  .banner-box .banner-hot .banner-hot-item ul li:nth-child(2n) {
    margin-right: 0;
  }
  .aggregation-box .aggregation-jg-ul li .aggregation-jg-logo {
    flex: 0 0 92px;
    width: 92px;
    height: 62px;
  }
  .m-footer .m-footer-orther-link img {
    height: 28px;
  }
}

/* ---------------------------------------------------------
   四、页头「LOGO + 搜索区」间距优化（>768px）
   --------------------------------------------------------- */
@media screen and (min-width: 769px) {
  /* 原布局 justify-content: space-between 把 LOGO 与搜索区顶到容器两端，
     中间留出 400px+ 空白；改为 LOGO 靠左、搜索区紧随其后，
     两块之间只保留 40px 间距（搜索框宽度保持原样，不拉伸） */
  .head-main .head-search-box {
    justify-content: flex-start;
    align-items: flex-start;
  }
  .head-main .head-search-box .logo {
    flex: 0 0 auto;
    margin-top: 44px;
  }
  .head-main .head-search-box .head-search-r {
    margin-top: 44px;
    margin-left: 40px;
    flex: 0 1 auto;
    min-width: 0;
  }
  /* 搜索框维持原有尺寸：输入框 511px + 按钮 76px，
     不做拉伸；仅在窄屏空间不足时才允许收缩 */
  .head-main .head-search-box .head-search-input input {
    flex: 0 1 auto;
    width: 511px;
    max-width: 100%;
    min-width: 0;
  }
  .head-main .head-search-box .head-search-input button {
    flex: 0 0 76px;
    width: 76px;
  }
  .head-main .head-search-box .head-search-input .input_lx {
    width: 542px;
    max-width: 100%;
  }
  /* 分类切换、热门词与搜索框左边缘对齐 */
  .head-main .head-search-box .head-search-r dl,
  .head-main .head-search-box .head-search-tj {
    padding-left: 0;
  }
  .head-main .head-search-box .head-search-tj {
    flex-wrap: wrap;
  }

  /* 行业聚合：标题 + 标签 + 「查看更多」始终同一行，标签胶囊化
     原来三者同在一行但都是 nowrap，标签一多就被压缩，li 内文字折行、高度变形；
     现在标题与「查看更多」不收缩，标签区固定 700px、单行排列，
     放不下的标签直接隐藏，标题行高度不再被撑开 */
  .aggregation-box .aggregation-box-title {
    flex-wrap: nowrap;
    min-width: 0;
    margin-bottom: 14px;
  }
  .aggregation-box .aggregation-box-title > span {
    flex: 0 0 auto;
  }
  .aggregation-box .aggregation-box-title > a {
    flex: 0 0 auto;
    padding: 4px 12px;
    border-radius: 14px;
    transition: color 0.2s, background-color 0.2s;
  }
  .aggregation-box .aggregation-box-title > a:hover {
    color: #FF6C00;
    background-color: rgba(255, 108, 0, 0.06);
  }
  /* 固定宽度 + 单行，超出部分隐藏 */
  .aggregation-box .aggregation-tab {
    flex: 0 0 700px;
    width: 700px;
    margin-top: 0;
    flex-wrap: nowrap;
    gap: 0 10px;
    overflow: hidden;
    justify-content: flex-start;
  }
  .aggregation-box .aggregation-tab > li {
    flex: 0 0 auto;
    margin-right: 0;
  }
  .aggregation-box .aggregation-tab > li a {
    display: inline-block;
    max-width: 100%;
    padding: 6px 14px;
    border: 1px solid #EDEDEE;
    border-radius: 16px;
    background-color: #fff;
    font-size: 13px;
    line-height: 18px;
    color: #6D6D6D;
    white-space: nowrap;
    transition: color 0.2s, border-color 0.2s, background-color 0.2s;
  }
  .aggregation-box .aggregation-tab > li a:hover {
    color: #FF6C00;
    border-color: #FF6C00;
    background-color: rgba(255, 108, 0, 0.06);
  }
    .common-layer {
        width: 365px !important;
    }

    .tc_box_div {
        width: 329px !important;
    }

    .yyst_box_form div input {
        width: 243px;
    }

    .common-layer .bxk-notice {
        width: 365px !important;
    }

    .yyst_box_form .formBtn {
        width: 330px !important;
    }
}
