/* ---- 导航栏层级修正 ---- */
#page-topbar { z-index: 1002; }

/* ---- 汉堡菜单按钮 ---- */
.nq-menu-toggle { display: none; align-items: center; justify-content: center; width: 36px; height: 36px; border: none; background: transparent; cursor: pointer; color: var(--nq-text-2); font-size: 22px; padding: 0; }
.nq-menu-toggle i { display: inline-block; transition: transform .3s cubic-bezier(.4,0,.2,1), color .15s; }
.nq-menu-toggle:hover { color: var(--nq-primary); }
body.sidebar-enable .nq-menu-toggle i { transform: rotate(90deg); color: var(--nq-primary); }

/* ---- 侧边栏遮罩 ---- */
.nq-sidebar-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 998; opacity: 0; visibility: hidden; transition: opacity .3s ease, visibility .3s ease; }

/* ---- 用户中心导航栏自适应 ---- */
@media (max-width: 992px) {
  .nq-menu-toggle { display: flex; }
  .nq-header-logo { display: none !important; }
  .nq-header-divider { display: none; }
  .nq-header-overview { font-size: 12px; }
  .vertical-menu { position: fixed !important; left: 0; height: 100vh; z-index: 999; display: block !important; transform: translateX(-100%); transition: transform .3s cubic-bezier(.4,0,.2,1); box-shadow: none; }
  body.sidebar-enable .vertical-menu { transform: translateX(0); box-shadow: 4px 0 16px rgba(0,0,0,.1); }
  body.sidebar-enable .nq-sidebar-overlay { opacity: 1; visibility: visible; }
  .footer { left: 0; font-size: 12px; text-align: center; }
  .footer .container-fluid { justify-content: center !important; }
  /* 导航栏紧凑 */
  #page-topbar .navbar-header { padding: 0 8px; }
  .nq-header-left { gap: 6px; }
  .nq-header-right { gap: 2px; }
  /* 未登录：控制台隐藏、保留搜索框、链接缩小 */
  .nq-header-nav-console { display: none !important; }
  .nq-header-search-input { width: 120px; }
  .nq-header-right > a.nq-header-nav-link { padding: 0 6px; font-size: 13px; }
  .nq-header-register-btn { padding: 0 12px; font-size: 12px; }
  /* 已登录：订购产品链接 */
  .nq-header-nav-cart { font-size: 13px; padding: 0 6px; }
  /* 已登录：图标按钮缩小 */
  a.nq-header-icon-btn, button.nq-header-icon-btn, .nq-header-lang-btn { width: 32px; height: 32px; font-size: 17px; }
  .nq-header-avatar { width: 28px; height: 28px; font-size: 14px; }
}

@media (max-width: 575.98px) {
  .nq-header-right > a.nq-header-nav-link { padding: 0 4px; font-size: 12px; }
  .nq-header-register-btn { padding: 0 10px; font-size: 11px; height: 50px; }
  
  .nq-header-search-input { width: 90px; height: 28px; font-size: 11px; padding-left: 28px !important; }
  .nq-header-search-icon { font-size: 12px; left: 8px; }
  a.nq-header-icon-btn, button.nq-header-icon-btn, .nq-header-lang-btn { width: 30px; height: 30px; font-size: 16px; }
  .nq-header-avatar { width: 26px; height: 26px; font-size: 13px; border-radius: 3px; }
}

/* ---- 下拉菜单：触屏设备禁用 hover，仅用点击 ---- */
@media (hover: none) {
  .nq-user-dropdown:hover .nq-user-menu { opacity: 0; visibility: hidden; transform: translateY(-4px); }
  .nq-lang-dropdown:hover .nq-lang-menu { opacity: 0; visibility: hidden; transform: translateY(-4px); }
  .nq-user-dropdown.open .nq-user-menu,
  .nq-lang-dropdown.open .nq-lang-menu { opacity: 1; visibility: visible; transform: translateY(0); }
}

/* ---- 全局页面自适应（平板 ≤991.98px） ---- */
@media (max-width: 991.98px) {
  /* 表格分页：隐藏"共X条"和每页选择器，分页按钮换行 */
  body.nq .table-footer-left { display: none; }
  body.nq .table-footer > .text-muted { display: none; }
  body.nq .table-pageinfo { display: none !important; }
  body.nq .pagination { flex-wrap: wrap; gap: 2px; }
  body.nq .table-footer { justify-content: flex-end; }
  /* 表头筛选栏 */
  body.nq .table-header { flex-wrap: wrap; gap: 8px; }
  body.nq .table-filter { flex-wrap: wrap; }
  body.nq .table-search { flex-wrap: wrap; justify-content: flex-start; }
  /* 用户中心主页 */
  .nq-dash-stat-value { font-size: 22px; }
  .nq-news-date { display: none; }
  /* 表单弹窗：label+input 纵向堆叠 */
  .modal-body .form-group.row { flex-direction: column; }
  .modal-body .form-group.row label,
  .modal-body .form-group.row [class*="col-sm-"] { text-align: left !important; max-width: 100%; flex: 0 0 100%; padding-bottom: 4px; }
  /* 工单聊天气泡 */
  .nq-sub-chat-msg { max-width: 90%; }
  .nq-sub-chat-messages { height: 400px; padding: 16px; }
  /* 工单信息侧栏 */
  .nq-sub-ticket-info { margin-top: 16px; }
  /* 安全中心头像区 */
  .nq-sec-avatar { width: 60px; height: 60px; font-size: 28px; margin-right: 16px; }
  /* 实名认证引导图 */
  .nq-verified-id-guide { height: auto; flex-wrap: wrap; padding: 16px; gap: 12px; }
}

/* ---- 全局页面自适应（手机 ≤575.98px） ---- */
@media (max-width: 575.98px) {
  /* 页面容器 */
  .page-content { padding-bottom: 40px !important; }
  .card { margin-bottom: 12px !important; }
  .card.card-body { padding: 16px; }

  /* 用户中心主页：右列在上 */
  .row.align-items-start > .col-xl-8 { order: 2; }
  .row.align-items-start > .col-xl-4 { order: 1; }
  .nq-shortcut-card { display: none !important; }
  .nq-dash-stat { padding: 12px 14px; }
  .nq-dash-stat-value { font-size: 20px; }
  .nq-dash-stat-footer a { font-size: 11px; }
  .nq-dash-product { padding: 8px 12px; font-size: 13px; }
  .nq-finance-amount { font-size: 20px; }
  .nq-stat-num { font-size: 16px; }
  .nq-stat-desc { font-size: 11px; }
  .user-center_header { width: 44px; height: 44px; font-size: 24px; }
  .nqusername { font-size: 14px; }
  .nq-news-item { padding: 8px 0; gap: 6px; }
  .nq-news-title { font-size: 13px; }

  /* 个人信息页 */
  .nq-profile-card { padding: 16px; }
  .nq-profile-avatar { width: 48px; height: 48px; font-size: 20px; }
  .nq-profile-name { font-size: 15px; }
  .nq-profile-info-label { width: 56px; }

  /* 安全中心 - 账户信息：头像左侧缩小，信息单列紧凑 */
  .nq-sec-avatar { width: 40px; height: 40px; font-size: 18px; margin-right: 12px; border-radius: 50%; }
  .nq-sec-account-grid { grid-template-columns: 1fr 1fr; gap: 4px 12px; }
  .nq-sec-account-label { font-size: 12px; min-width: 0; }
  .nq-sec-account-value { font-size: 12px; }
  /* 安全中心 - 安全设置项：保持横排，隐藏icon+描述，紧凑化 */
  .nq-sec-item { padding: 10px 12px; gap: 8px; }
  .nq-sec-item-icon { display: none; }
  .nq-sec-item-title { font-size: 13px; }
  .nq-sec-item-title .status { font-size: 11px; }
  .nq-sec-item-desc { display: none; }
  .nq-sec-item-action .btn { font-size: 12px; padding: 2px 10px; }
  /* 安全中心 - 右列 */
  .nq-security-progress { flex-direction: column; }
  .nq-security-ranges { font-size: 10px; }
  .nq-security-ranges .ml-3 { margin-left: 8px !important; }
  .nq-sec-remind { padding: 12px; }
  .nq-sec-remind-header { gap: 8px; }
  .nq-sec-remind-icon { width: 32px; height: 32px; font-size: 16px; }
  .nq-sec-remind-title { font-size: 13px; }
  .nq-sec-remind-desc { font-size: 11px; }

  /* 账单详情 */
  .nq-vb-header { flex-direction: column; gap: 8px; }
  .nq-vb-status { text-align: left; }
  .nq-vb-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .nq-vb-table-wrap .nq-vb-table { min-width: 500px; }
  .nq-vb-table { font-size: 12px; }
  .nq-vb-table th,
  .nq-vb-table td { padding: 8px; white-space: nowrap; }
  .nq-vb-table td:first-child { white-space: normal; }
  .nq-vb-actions { flex-wrap: wrap; }

  /* 工单聊天 */
  .nq-sub-chat-messages { height: 350px; padding: 12px; gap: 14px; }
  .nq-sub-chat-msg { max-width: 92%; }
  .nq-sub-chat-avatar { width: 30px; height: 30px; font-size: 12px; }
  .nq-sub-chat-bubble { padding: 8px 12px; font-size: 13px; }
  .nq-sub-chat-meta { font-size: 11px; }

  /* 工单提交 - 步骤 */
  .nq-sub-steps { justify-content: space-between; padding: 12px 0 0; }
  .nq-sub-step { gap: 4px; }
  .nq-sub-step-num { width: 20px; height: 20px; font-size: 11px; }
  .nq-sub-step-label { font-size: 12px; }
  .nq-sub-step-arrow { margin: 0 6px; font-size: 12px; }

  /* 充值页 */
  .addfunds-payment { margin-bottom: 0; }
  .nq-addfunds-account { flex-wrap: wrap !important; gap: 10px !important; }
  .nq-addfunds-select { flex: 1 1 100% !important; width: 100% !important; }
  .nq-amount-input { width: 100%; }
  .nq-gateway-card { padding: 12px; }
  .nq-amount-presets { gap: 6px; }
  .nq-amount-btn { padding: 0 12px; height: 30px; font-size: 12px; }

  /* 表头工具栏 */
  .nq-tab-scroll-wrap { margin-bottom: 8px; }
  body.nq .table-filter { margin-bottom: 0 !important; }
  body.nq .table-header { flex-direction: column; align-items: stretch; gap: 8px; }
  body.nq .table-filter { width: 100%; }
  body.nq .table-search { width: 100%; justify-content: flex-start; }
  body.nq .table-search .bootstrap-select { width: 100% !important; flex: 1 1 100%; }
  body.nq .table-search input[type="date"] { width: auto !important; flex: 1 1 40%; }
  /* 合同页 */
  .nq-ct-search-wrap { width: 100% !important; }
  .nq-ct-search-wrap .form-control { width: 100% !important; }
  .nq-ct-sign-dialog { max-width: 100% !important; margin: 8px; }
  .nq-ct-party-table table td { display: block; width: 100% !important; padding: 4px 0; font-size: 12px; }
  .nq-ct-enclosure { padding: 0; }
  #signContractContent { padding: 12px 0; font-size: 13px; }
  .nq-ct-info-row { flex-wrap: wrap; }
  .nq-ct-info-label { width: 100%; text-align: left; }
  .nq-ct-info-value { width: 100%; }

  /* 推介中心 */
  .nq-aff-empty-step { flex: 0 0 100%; }
  .nq-aff-link-row { flex-direction: column; gap: 8px; }
  .nq-aff-link-box { min-width: 0; }

  /* API 管理 */
  .nq-api-empty { padding: 40px 16px 32px; }
  .nq-api-empty-icon { width: 56px; height: 56px; font-size: 26px; }
  .nq-api-empty-title { font-size: 17px; }
  .nq-api-empty-desc { font-size: 13px; margin-bottom: 20px; }
  .nq-api-empty-features { gap: 16px; margin-top: 24px; padding-top: 16px; flex-wrap: wrap; justify-content: center; }
  .nq-api-empty-feature { font-size: 12px; }
  .nq-api-empty-req-item { padding: 10px 12px; font-size: 12px; }
  .nq-api-key-bar { flex-direction: column; align-items: flex-start !important; gap: 10px; }
  .nq-api-key-info { font-size: 12px; gap: 4px; }
  .nq-api-key-info .ml-3 { margin-left: 0 !important; }
  .nq-api-key-code { font-size: 12px; padding: 3px 8px; }
  .nq-api-key-actions { width: 100%; }
  .nq-api-key-actions .btn { font-size: 12px; flex: 1; }
  .nq-api-stat-grid { gap: 10px; }
  .nq-api-stat-value { font-size: 18px; }
  .nq-api-stat-icon { width: 36px; height: 36px; font-size: 18px; }
  .nq-api-protocol-dialog { max-width: 95% !important; }

  /* 产品详情概览 */
  .nq-ov-grid > .nq-ov-col:first-child .nq-ov-card-body { grid-template-columns: 1fr; }
  .nq-ov-row { gap: 4px; }
  .nq-ov-label { width: auto; flex-shrink: 0; }
  .nq-ov-card-head { flex-wrap: wrap; gap: 6px; }
  .nq-ov-actions { gap: 4px; }
  .nq-ov-actions .btn { font-size: 12px; padding: 2px 8px; }

  /* 图表区 */
  .nq-chart-head { flex-direction: column; align-items: flex-start; gap: 6px; }
  .nq-chart-range { flex-wrap: wrap; }
  .nq-chart-item { padding: 12px; }

  /* 信用额度 */
  .nq-cr-gauge { flex-direction: column; align-items: center; padding: 16px; }
  .nq-cr-empty-features { flex-wrap: wrap; gap: 8px; justify-content: center; }

  /* 消息页操作栏 */
  .nq-msg-actions { flex-wrap: wrap; gap: 6px; }
  .nq-msg-actions .btn { font-size: 12px; }

  /* 实名认证 */
  .nq-verified-id-guide { height: auto; flex-wrap: wrap; padding: 12px; gap: 8px; justify-content: center; }
  .nq-verified-id-guide-text { width: auto; height: auto; font-size: 12px; line-height: 1.6; }
  .nq-vf-info-card { padding: 16px; }

  /* 知识库/文档/新闻：侧栏在上 */
  .row > .col-xl-9.col-lg-8 { order: 2; }
  .row > .col-xl-3.col-lg-4 { order: 1; }
  .nq-kb-item { padding: 10px 0; }

  /* 发票表单 */
  .col-sm-1 { max-width: 100%; flex: 0 0 100%; }
  .col-sm-2 { max-width: 100%; flex: 0 0 100%; text-align: left !important; }

  /* 弹窗适配 */
  .modal-dialog { margin: 16px; }
}

/* ---- 认证页自适应 ---- */

/* 平板竖屏 */
@media (max-width: 768px) {
  .nq-auth { flex-direction: column; padding: 24px 16px; }
  .nq-auth-form { width: 100%; max-width: 420px; }
  .nq-auth-footer { position: static; width: 100%; padding: 16px; }
}

/* 手机 */
@media (max-width: 575.98px) {
  .nq-auth { background: var(--nq-bg-1) !important; padding: 0; align-items: stretch; flex-direction: column; min-height: 100vh; }
  .nq-auth-form { width: 100%; max-width: 100%; padding: 32px 24px; box-shadow: none; border-radius: 0; background: transparent; flex: 1; }
  .nq-auth-logo { margin-bottom: 32px; }
  .nq-auth-logo img { height: 36px; }
  .nq-auth-form .nav-tabs { margin-bottom: 16px; }
  .nq-auth-form .nav-tabs .nav-link { font-size: 15px; }
  .nq-auth-form .btn-login { height: 42px; font-size: 15px; border-radius: 8px; }
  .nq-auth-form .input-group-prepend { width: 90px; }
  .nq-auth-form .input-group>.input-group-prepend+.nq-ig-icon { left: calc(90px + 12px); }
  .nq-auth-form .input-group-append .btn { font-size: 13px; padding: 0 12px; }
  .nq-auth-actions { font-size: 13px; }
  .nq-auth-agreement { font-size: 12px; flex-wrap: wrap; justify-content: center; }
  .nq-auth-register { font-size: 13px; }
  .nq-auth-oauth { margin-top: 20px; padding-top: 20px; }
  .nq-auth-oauth .social-list-item { width: 36px; height: 36px; }
  .nq-auth-oauth .social-list-item svg,
  .nq-auth-oauth .social-list-item img,
  .nq-auth-oauth .social-list-item .icon { width: 22px; height: 22px; }
  .nq-auth-header { padding: 8px 0; font-size: 12px; }
  .nq-auth-footer { position: static; width: 100%; padding: 24px 16px; font-size: 12px; text-align: center; }
}

/* 超小屏 */
@media (max-width: 374px) {
  .nq-auth-form { padding: 24px 16px; }
  .nq-auth-form .input-group-prepend { width: 80px; }
  .nq-auth-form .input-group>.input-group-prepend+.nq-ig-icon { left: calc(80px + 10px); }
  .nq-auth-actions { flex-wrap: wrap; gap: 6px; }
}

/* 横屏手机 */
@media (max-height: 500px) {
  .nq-auth { align-items: flex-start; padding-top: 12px; flex-direction: column; }
  .nq-auth-logo { margin-bottom: 16px; }
  .nq-auth-footer { position: static; }
}

/* ============================================
   购物车主题自适应 (nqshop)
   ============================================ */

/* 默认隐藏移动端专属元素 */
.nq-breakdown-overlay { display: none; }
.nq-breakdown-close { display: none; }
.nq-spec-trigger { display: none; }
.nq-spec-drawer { display: none; }
.nq-cart-side--viewcart { display: none; }

/* ---- 购物车侧栏抽屉（与汉堡按钮同步 ≤992px） ---- */
@media (max-width: 992px) {
  .nq-cart-side { position: fixed; left: 0; top: 0; height: 100vh; z-index: 999; transform: translateX(-100%); transition: transform .3s cubic-bezier(.4,0,.2,1); box-shadow: none; }
  .nq-cart-side--viewcart { display: block; background: var(--nq-bg-1); width: 260px; overflow-y: auto; padding: 12px 0; top: 50px; height: calc(100vh - 50px); }
  body.sidebar-enable .nq-cart-side { transform: translateX(0); box-shadow: 4px 0 16px rgba(0,0,0,.1); }
}

/* ---- 平板 ≤768px ---- */
@media (max-width: 768px) {
  /* 登录提示条 */
  .nq-cart-login { flex-wrap: wrap; gap: 8px; }
  .nq-cart-login-icon { font-size: 28px; }
  .nq-cart-login-text { min-width: 0; }
  /* 商品组标题 */
  .nq-cart-group-heading { flex-wrap: wrap; font-size: 13px; }
  /* 商品网格 */
  .nq-product-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }

  /* ---- 配置页 ---- */
  /* 配置页主区改为可滚动 */
  .nq-cart-main.nq-cart-main--config { overflow-y: auto; }
  /* 配置区去边框，减少视觉层级 */
  .nq-productconfig { border: none; }
  /* 标题截断 */
  .nq-productconfig-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 1; }
  /* 返回按钮缩小 */
  .nq-productconfig-back { width: 24px; height: 24px; font-size: 16px; }
  /* 登录条/错误提示覆盖 inline margin */
  .nq-cart-main--config .alert { margin: 12px !important; }
  /* btn-group 换行为独立标签式 */
  .nq-productconfig-field .btn-group.btn-group-toggle { display: flex; flex-wrap: wrap; gap: 6px; border: none; }
  .nq-productconfig-field .btn-group.btn-group-toggle .btn { border-radius: var(--nq-radius) !important; margin-left: 0 !important; border: 1px solid var(--nq-fill-3) !important; }
  .nq-productconfig-field .btn-group.btn-group-toggle .btn.active { border-color: var(--nq-primary) !important; }
  /* 滑块：滑条独占一行，步进器换行 */
  .nq-productconfig-slider { gap: 6px; max-width: 100%; }
  .nq-productconfig-slider .configoption_range { min-width: 80px; }
  /* bootstrap-select 全宽 */
  .nq-productconfig-field .bootstrap-select { max-width: 100%; }
  /* 配置页底栏纵向堆叠 */
  .nq-productconfig-footer .configoption_total { flex-direction: column !important; align-items: stretch !important; gap: 8px !important; }
  /* 价格区：一行显示 */
  .nq-productconfig-footer-price { flex-wrap: nowrap; gap: 6px; align-items: baseline; }
  .nq-productconfig-footer-note { word-break: break-all; }
  /* 操作区：居右 */
  .nq-productconfig-footer-right { justify-content: flex-end !important; flex-shrink: 0; }
  /* 费用明细面板防超屏 */
  .nq-productconfig-footer-breakdown { min-width: 0; width: calc(100vw - 24px); max-width: 560px; right: -8px; }
  .nq-productconfig-footer-breakdown-body { overflow-x: auto; }
  .nq-productconfig-footer-breakdown table { min-width: 500px; }
  /* 推荐产品隐藏 */
  .nq-cart-recommend { display: none; }
  /* 结算页头部 */
  .nq-viewcart-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 1; }
}

/* ---- 手机 ≤575.98px ---- */
@media (max-width: 575.98px) {
  /* 购物车主内容 */
  .nq-cart-main { padding: 12px; }
  /* 商品网格单列 */
  .nq-product-grid { grid-template-columns: 1fr; gap: 10px; }
  /* 产品卡片紧凑化 */
  .nq-product-header { padding: 12px 14px; gap: 8px; }
  .nq-product-name { font-size: 14px; }
  .nq-product-desc { padding: 10px 14px; font-size: 13px; }
  .nq-product-footer { padding: 0 14px 14px; }
  .nq-price-current { font-size: 20px; }
  .nq-product-stock { font-size: 10px; padding: 1px 6px; }
  /* 登录提示条紧凑 */
  .nq-cart-login { padding: 10px 12px; gap: 8px; font-size: 13px; }
  .nq-cart-login-icon { font-size: 24px; }
  .nq-cart-login-title { font-size: 13px; }
  .nq-cart-login-desc { font-size: 11px; }
  .nq-cart-login-btn { font-size: 12px; }
  /* 空状态 */
  .nq-cart-empty-inner { padding: 40px 16px; }
  .nq-cart-empty-inner img { width: 80px; }
  /* ---- 配置页细化 ---- */
  /* 整体间距 */
  .nq-productconfig-wrap { margin: 0; gap: 0; }
  .nq-productconfig { border-radius: 0; }
  .nq-productconfig-header { padding: 10px 14px; gap: 6px; }
  .nq-productconfig-title { font-size: 13px; }
  .nq-productconfig-back { width: 22px; height: 22px; font-size: 15px; }
  .nq-productconfig-body { padding: 4px 0 12px; }
  .nq-productconfig-row { padding: 8px 14px; }
  /* 标签：缩小并加粗区分 */
  .nq-productconfig-label { font-size: 12px; padding-bottom: 4px; }
  .nq-productconfig-tip { font-size: 13px; }
  /* 配置项型号选择：改为抽屉 */
  .nq-spec-row { flex-direction: row !important; align-items: center !important; }
  .nq-spec-row .nq-productconfig-label { padding-bottom: 0 !important; flex-shrink: 0; margin-right: 8px; }
  .nq-spec-row .nq-productconfig-field { flex: 1; min-width: 0; display: flex; justify-content: flex-end; }
  .nq-spec-row .nq-spec-group { display: none !important; }
  .nq-spec-row .nq-spec-hint { display: none !important; }
  .nq-spec-trigger { display: inline-flex !important; align-items: center; gap: 4px; font-size: 13px; color: var(--nq-primary); cursor: pointer; }
  .nq-spec-trigger-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .nq-spec-trigger i { font-size: 14px; transition: transform .2s; }
  .nq-spec-trigger.open i { transform: rotate(180deg); }
  /* 型号抽屉 */
  .nq-spec-drawer { position: fixed; bottom: 0; left: 0; right: 0; z-index: 1001; background: var(--nq-bg-1); border-radius: 12px 12px 0 0; box-shadow: 0 -4px 20px rgba(0,0,0,.12); max-height: 70vh; flex-direction: column; overflow: hidden; }
  .nq-spec-drawer.active { display: flex; }
  .nq-spec-drawer-header { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-bottom: 1px solid var(--nq-fill-2); flex-shrink: 0; }
  .nq-spec-drawer-title { font-size: 15px; font-weight: 600; color: var(--nq-text-1); }
  .nq-spec-drawer-close { display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; border: none; background: var(--nq-fill-2); border-radius: 50%; color: var(--nq-text-2); font-size: 16px; cursor: pointer; }
  .nq-spec-drawer-body { flex: 1; overflow-y: auto; padding: 12px 16px; -webkit-overflow-scrolling: touch; }
  .nq-spec-drawer-body .nq-spec-group { display: flex !important; flex-wrap: wrap; gap: 8px; }
  .nq-spec-drawer-body .nq-spec-item { padding: 8px 14px; font-size: 13px; }
  .nq-spec-drawer-body .nq-spec-hint { margin-top: 12px; font-size: 12px; }
  /* 周期选择紧凑 */
  .nq-productconfig-cycles { gap: 5px; }
  .nq-productconfig-cycle { padding: 4px 10px; font-size: 12px; }
  .nq-productconfig-discount { font-size: 9px; height: 14px; line-height: 14px; top: -6px; right: -3px; padding: 0 4px; }
  /* btn-group 按钮紧凑 */
  .nq-productconfig-field .btn-group.btn-group-toggle { gap: 5px; }
  .nq-productconfig-field .btn-group.btn-group-toggle .btn { padding: 4px 10px; font-size: 12px; }
  /* 下拉选择器 */
  .nq-productconfig-field .bootstrap-select .dropdown-toggle { height: 30px; font-size: 12px; padding-right: 24px; }
  .nq-productconfig-field select.form-control { height: 30px; font-size: 12px; }
  .nq-productconfig-field input.form-control:not(.configoption_range_val) { height: 30px; font-size: 12px; }
  .nq-productconfig-field textarea.form-control { font-size: 12px; }
  /* 滑块区域 */
  .nq-productconfig-slider { max-width: 100%; }
  .nq-productconfig-slider-min, .nq-productconfig-slider-max { font-size: 11px; }
  .nq-productconfig-stepper .configoption_range_val { width: 44px !important; height: 26px; font-size: 12px; }
  .nq-productconfig-stepper-btn { width: 26px; height: 26px; font-size: 13px; }
  /* OS 卡片改用 grid 自适应列数 */
  .nq-productconfig-os-grid { display: grid !important; grid-template-columns: repeat(2, 1fr) !important; gap: 6px !important; }
  .nq-productconfig-os-card { width: auto !important; min-width: 0 !important; }
  .nq-productconfig-os-header { padding: 8px 10px; gap: 6px; }
  .nq-productconfig-os-icon { width: 16px; height: 16px; }
  .nq-productconfig-os-name { font-size: 12px; }
  .nq-productconfig-os-trigger { font-size: 11px; height: 26px; padding: 4px 10px; }
  .nq-productconfig-os-option { padding: 5px 10px; font-size: 11px; }
  /* 复选框紧凑 */
  .nq-productconfig-checkbox { margin-bottom: 2px; }
  .nq-productconfig-checkbox .custom-control-label { font-size: 12px; }
  /* 密码框全宽 */
  .nq-productconfig-password { max-width: 100%; }
  .nq-productconfig-password .form-control { height: 30px; font-size: 12px; }
  .nq-productconfig-password-icon { font-size: 14px; }
  /* ---- 配置页底栏细化 ---- */
  .nq-productconfig-footer .configoption_total { padding: 10px 14px; gap: 6px; }
  /* 价格区 */
  .nq-productconfig-footer-label { font-size: 12px; white-space: nowrap; }
  .nq-productconfig-footer-amount { font-size: 18px; }
  .nq-productconfig-footer-amount small { font-size: 11px; }
  .nq-productconfig-footer-discount { font-size: 11px; line-height: 1.4; }
  .nq-productconfig-footer-discount s { font-size: 11px; }
  .nq-productconfig-footer-nodiscount { font-size: 11px; }
  .nq-productconfig-footer-note { font-size: 10px; line-height: 1.4; color: var(--nq-text-3); }
  /* 操作区 */
  .nq-productconfig-footer-right { gap: 8px !important; flex-wrap: nowrap !important; justify-content: flex-end !important; }
  .nq-productconfig-footer-right > .btn { padding: 8px 14px; font-size: 13px; }
  .nq-productconfig-footer-right > .btn .btn-text { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .nq-productconfig-footer-detail { flex-shrink: 0; }
  .nq-productconfig-footer-detail-trigger { font-size: 12px; }
  /* 费用明细面板：底部抽屉 */
  .nq-breakdown-overlay { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 999; opacity: 0; visibility: hidden; transition: opacity .25s, visibility .25s; }
  .nq-breakdown-overlay.active { opacity: 1; visibility: visible; }
  .nq-productconfig-footer-breakdown { position: fixed !important; bottom: 0 !important; left: 0 !important; right: 0 !important; top: auto !important; width: 100% !important; max-width: 100% !important; max-height: 70vh; min-width: 0 !important; border-radius: 12px 12px 0 0 !important; z-index: 1001 !important; display: none; flex-direction: column; box-shadow: 0 -4px 20px rgba(0,0,0,.12); overflow: hidden !important; }
  .nq-productconfig-footer-breakdown-title { padding: 14px 16px; font-size: 15px; font-weight: 600; border-bottom: 1px solid var(--nq-fill-2); flex-wrap: wrap; gap: 4px 8px; }
  .nq-productconfig-footer-breakdown-total { font-size: 13px; }
  .nq-productconfig-footer-breakdown-total em { font-size: 16px; }
  .nq-breakdown-close { display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; border: none; background: var(--nq-fill-2); border-radius: 50%; color: var(--nq-text-2); font-size: 16px; cursor: pointer; transition: all .15s; flex-shrink: 0; }
  .nq-breakdown-close:hover { background: var(--nq-fill-3); color: var(--nq-text-1); }
  .nq-productconfig-footer-breakdown-body { flex: 1; overflow-x: hidden !important; overflow-y: auto !important; max-height: none; -webkit-overflow-scrolling: touch; }
  .nq-productconfig-footer-breakdown th { padding: 8px 10px; font-size: 11px; position: sticky; top: 0; z-index: 1; background: var(--nq-bg-1, #fff) !important; }
  .nq-productconfig-footer-breakdown td { padding: 8px 10px; font-size: 11px; }
  .nq-productconfig-footer-breakdown td:first-child { max-width: 80px; overflow: hidden; text-overflow: ellipsis; }
  .nq-productconfig-footer-breakdown td:nth-child(2) { max-width: 120px; overflow: hidden; text-overflow: ellipsis; }
  .nq-productconfig-footer-breakdown table { min-width: 0 !important; width: 100% !important; table-layout: fixed; }
  .nq-productconfig-footer-breakdown td, .nq-productconfig-footer-breakdown th { word-break: break-all; white-space: normal !important; }
  /* 服务须知 */
  .nq-cart-notice { margin-top: 16px; }
  .nq-cart-notice-header { padding: 8px 14px; font-size: 13px; }
  .nq-cart-notice-body { padding: 10px 14px; font-size: 13px; }
  /* 结算页：内部滚动 */
  .nq-viewcart { display: flex !important; flex-direction: column !important; height: calc(100vh - 50px) !important; margin-bottom: 0 !important; overflow: hidden !important; border-radius: 0 !important; border: none !important; }
  .nq-viewcart-header { padding: 10px 14px; gap: 8px; flex-shrink: 0; }
  .nq-viewcart-header h4 { font-size: 14px; }
  .nq-viewcart-count { font-size: 12px; }
  .nq-viewcart > .card-body { flex: 1 !important; overflow-y: auto !important; -webkit-overflow-scrolling: touch; min-height: 0; padding: 12px 14px 100px !important; }
  .nq-viewcart .card-header { padding: 10px 14px; font-size: 13px; flex-wrap: nowrap !important; }
  .nq-viewcart .card-header > strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 1; }
  /* 结算商品卡 */
  .nq-viewcart-config-tag { font-size: 11px; padding: 3px 8px; }
  /* 支付网关2列 */
  .nq-viewcart-gateway-grid { grid-template-columns: repeat(2, 1fr); gap: 6px; }
  .nq-viewcart-gateway-item { padding: 10px 6px; min-height: 60px; gap: 4px; }
  .nq-viewcart-gateway-item img { max-width: 70px; max-height: 22px; }
  .nq-viewcart-gateway-item span { font-size: 11px; }
  /* 底栏 */
  .nq-viewcart-footer-inner { padding: 10px 12px; gap: 8px; }
  .nq-viewcart-footer-amount { font-size: 18px; }
  .nq-viewcart-footer-right .btn { padding: 7px 14px; font-size: 13px; }
  /* 优惠码区 */
  .nq-viewcart .input-group { flex-wrap: nowrap; }
}

/* ---- 超小屏 ≤374px ---- */
@media (max-width: 374px) {
  .nq-cart-main { padding: 8px; }
  .nq-product-header { padding: 10px 12px; }
  .nq-product-footer { padding: 0 12px 12px; }
  .nq-price-current { font-size: 18px; }
  .nq-viewcart-gateway-grid { grid-template-columns: repeat(2, 1fr); }
  /* 配置页极小屏 */
  .nq-productconfig-row { padding: 6px 10px; }
  .nq-productconfig-header { padding: 8px 10px; }
  .nq-productconfig-title { font-size: 12px; }
  .nq-productconfig-label { font-size: 11px; }
  .nq-spec-item { padding: 3px 8px; font-size: 11px; }
  .nq-productconfig-cycle { padding: 3px 8px; font-size: 11px; }
  .nq-productconfig-field .btn-group.btn-group-toggle .btn { padding: 3px 8px; font-size: 11px; }
  .nq-productconfig-os-grid { grid-template-columns: 1fr !important; }
  .nq-productconfig-footer .configoption_total { padding: 8px 10px; }
  .nq-productconfig-footer-amount { font-size: 16px; }
  .nq-productconfig-footer-right > .btn { padding: 6px 10px; font-size: 12px; }
}
