/*
 * 笔记本 / 中小屏紧凑适配（751px – 1680px）
 * 配合 common.js 中的根字号计算：rem 部分按比例缩小，这里负责 px 写死的部分。
 * 手机端（<=750px）仍由 memberResponsive.css 负责，不受影响。
 */
@media screen and (min-width: 751px) and (max-width: 1680px) {
  /* ---------- 外壳：侧边栏 190 -> 172，顶栏 60 -> 52 ---------- */
  html body .el-aside {
    width: 172px !important;
    padding: 0 6px;
    font-size: 13px;
  }

  html body .el-header {
    height: 52px !important;
    width: calc(100% - 172px) !important;
    padding: 0 16px;
  }

  html.shiwai-app-navigation body #shiwaiAppShell .el-header {
    left: 172px;
  }

  html.shiwai-app-navigation body #shiwaiAppOutlet {
    margin-left: 172px;
  }

  html body #shiwaiAppProgress {
    left: 172px;
  }

  html body #shiwaiHeaderSnapshot {
    left: 172px;
    width: calc(100% - 172px);
    height: 52px;
    padding: 0 16px;
  }

  html body #shiwaiSidebarSnapshot {
    width: 172px !important;
  }

  html body .ali-logo {
    height: 24px;
    max-width: 120px;
  }

  html body .el-aside .el-menu-item,
  html body .el-aside .el-submenu__title {
    height: 38px !important;
    min-height: 38px !important;
    line-height: 38px !important;
    font-size: 13px !important;
  }

  html body .el-aside .el-menu-item i,
  html body .el-aside .el-submenu__title i {
    font-size: 15px;
  }

  /* 顶栏右侧控件 */
  html body .header-right {
    margin-right: 4px;
  }

  html body .header-right .car-item {
    margin-right: 20px;
  }

  html body .header-right .cloum-line-item {
    margin-left: 14px;
    margin-right: 12px;
  }

  html body .header-right .header-right-item img,
  html body .header-right .header-right-item .el-dropdown-header .head-box {
    width: 22px;
    height: 22px;
  }

  html body .header-right .header-right-item .el-dropdown-header .head-box {
    font-size: 13px;
  }

  /* ---------- 正文基础字号 ---------- */
  html body .el-main,
  html body .main-card {
    font-size: 13px !important;
  }

  /* ---------- Element UI 默认尺寸组件收紧 ---------- */
  html body .el-button:not(.el-button--medium):not(.el-button--small):not(.el-button--mini):not(.el-button--text):not(.is-circle) {
    padding: 9px 16px;
    font-size: 13px;
  }

  html body .el-button--medium:not(.el-button--text):not(.is-circle) {
    padding: 8px 15px;
    font-size: 13px;
  }

  html body .el-input:not(.el-input--medium):not(.el-input--small):not(.el-input--mini) .el-input__inner {
    height: 34px;
    line-height: 34px;
    font-size: 13px;
  }

  html body .el-input:not(.el-input--medium):not(.el-input--small):not(.el-input--mini) .el-input__icon {
    line-height: 34px;
  }

  html body .el-range-editor.el-input__inner:not(.el-range-editor--medium):not(.el-range-editor--small):not(.el-range-editor--mini) {
    height: 34px;
    line-height: 26px;
  }

  html body .el-range-editor:not(.el-range-editor--medium):not(.el-range-editor--small):not(.el-range-editor--mini) .el-range-separator,
  html body .el-range-editor:not(.el-range-editor--medium):not(.el-range-editor--small):not(.el-range-editor--mini) .el-range__icon,
  html body .el-range-editor:not(.el-range-editor--medium):not(.el-range-editor--small):not(.el-range-editor--mini) .el-range__close-icon {
    line-height: 26px;
  }

  html body .el-textarea__inner {
    font-size: 13px;
  }

  html body .el-form-item {
    margin-bottom: 18px;
  }

  html body .el-form-item__label,
  html body .el-form-item__content {
    line-height: 34px;
    font-size: 13px;
  }

  html body .el-table {
    font-size: 13px;
  }

  html body .el-table th,
  html body .el-table td,
  html body .el-table th.el-table__cell,
  html body .el-table td.el-table__cell {
    padding-top: 8px;
    padding-bottom: 8px;
  }

  html body .el-tabs__item {
    height: 36px;
    line-height: 36px;
    font-size: 13px;
  }

  html body .el-radio-button__inner,
  html body .el-checkbox__label,
  html body .el-radio__label {
    font-size: 13px;
  }

  html body .el-dialog__header {
    padding: 16px 20px 8px;
  }

  html body .el-dialog__title {
    font-size: 16px;
  }

  html body .el-dialog__body {
    padding: 18px 20px;
    font-size: 13px;
  }

  html body .el-dialog__footer {
    padding: 8px 20px 16px;
  }

  html body .el-message-box__title {
    font-size: 16px;
  }

  html body .el-message-box__content {
    font-size: 13px;
  }

  html body .el-dropdown-menu__item {
    line-height: 32px;
    padding: 0 16px;
    font-size: 13px;
  }

  html body .el-select-dropdown__item {
    height: 32px;
    line-height: 32px;
    font-size: 13px;
  }

  html body .el-pagination {
    font-size: 13px;
  }

  /* 弹出层不允许超出视口宽度 */
  html body .el-dropdown-menu,
  html body .el-popover,
  html body .el-select-dropdown,
  html body .el-autocomplete-suggestion {
    max-width: calc(100vw - 16px);
    box-sizing: border-box;
  }

  /* ---------- 控制台首页 / 财务 / 产品列表（px 写死的部分） ---------- */
  html:has(.member-home) body .member-home,
  html body .member-home {
    --console-gap: 14px;
  }

  html:has(.finance-console) body .finance-console,
  html body .finance-console {
    --finance-gap: 14px;
  }

  html:has(.resource-console) body .resource-console,
  html body .resource-console {
    --resource-gap: 14px;
  }

  html body .member-home .main-card.console-dashboard,
  html body .template.finance-console .finance.main-card,
  html body .resource-console .main-card.resource-list {
    padding: 18px;
  }

  html body .console-page-header h1,
  html body .finance-console .finance-heading h1,
  html body .resource-console .resource-list-header h1 {
    font-size: 20px;
  }

  html body .console-panel-header h2 {
    font-size: 15px;
  }

  html body .console-metric strong {
    font-size: 20px;
  }

  html body .console-metric-lead strong {
    font-size: 26px;
  }

  html body .console-balance strong {
    font-size: 24px;
  }

  html body .console-empty {
    padding: 18px 16px;
  }

  html body .template.finance-console .finance.main-card .finance-top .finance-money-main {
    padding: 16px 18px !important;
  }

  html body .template.finance-console .finance.main-card .finance-top .finance-money-main .balance-left-num {
    font-size: 28px !important;
    line-height: 36px !important;
  }

  html body .template.finance-console .finance.main-card .finance-top .finance-money-main .other-money-item-value {
    font-size: 17px !important;
  }

  html body .finance-console .finance .content_box {
    padding-top: 14px;
  }

  html body .finance-console .finance .myPage,
  html body .resource-console .resource-list .myPage {
    padding-top: 14px;
  }

  html body .resource-console .resource-list .main-card-search {
    padding: 14px 0 10px;
  }

  /* ---------- 订购页（cart）大横幅收紧 ---------- */
  html body .shiwai-goodslistheader {
    height: 60px;
  }

  html body .shiwai-goodslistheader .gslogo {
    height: 42px;
  }

  html body .shiwai-goodslistheader .hea-box-r-li {
    width: 104px;
    height: 34px;
    line-height: 32px;
    font-size: 14px;
  }

  html body .shiwai-goodslistbanner {
    padding-top: 110px;
    height: 190px;
  }

  html body .shiwai-goodslistbanner .gsli-text-tit,
  html body .shiwai-goodslistbanner .gsli-text-tit span {
    font-size: 34px !important;
    margin-bottom: 16px;
  }

  html body .shiwai-goodslistbanner .gsli-text-desc,
  html body .shiwai-goodslistbanner .gsli-text-desc span {
    font-size: 17px !important;
  }
}
