/* Polished visual layer only. Business logic and markup remain untouched. */
:root {
  --brand: #2563eb;
  --brand-dark: #1d4ed8;
  --accent: #14b8a6;
  --ink: #172033;
  --ink-soft: #334155;
  --muted: #64748b;
  --line: #e2e8f0;
  --line-soft: #edf2f7;
  --page: #f5f7fb;
  --side: #101828;
  --side-soft: #182235;
}

body {
  color: var(--ink);
  background: var(--page);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Microsoft YaHei", Arial, sans-serif;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
}

a,
.ant-btn-link {
  color: var(--brand);
}

a:hover,
.ant-btn-link:hover {
  color: var(--brand-dark);
}

/* Login */
#userLayout.user-layout-wrapper .container {
  background:
    linear-gradient(140deg, rgba(15, 23, 42, 0.04), rgba(20, 184, 166, 0.08)),
    linear-gradient(135deg, #f8fbff 0%, #eef4ff 48%, #f7fafc 100%) !important;
  min-height: 100vh;
}

#userLayout.user-layout-wrapper .container .user-layout-content {
  min-height: calc(100vh - 64px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 42px 16px 28px !important;
}

#userLayout.user-layout-wrapper .container .user-layout-content .top {
  margin-bottom: 18px !important;
}

#userLayout.user-layout-wrapper .container .user-layout-content .top .header {
  height: auto !important;
  line-height: 1.2 !important;
}

#userLayout.user-layout-wrapper .container .user-layout-content .top .header .logo {
  height: 50px !important;
  margin-right: 12px !important;
  filter: drop-shadow(0 10px 18px rgba(37, 99, 235, 0.2));
}

#userLayout.user-layout-wrapper .container .user-layout-content .top .header .title {
  top: 0 !important;
  color: #0f172a !important;
  font-size: 30px !important;
  font-weight: 750 !important;
}

#userLayout.user-layout-wrapper .container .user-layout-content .top .desc {
  color: var(--muted) !important;
  margin: 10px 0 24px !important;
}

#userLayout.user-layout-wrapper .container .user-layout-content .main {
  width: min(396px, calc(100vw - 32px)) !important;
  padding: 30px 28px 26px;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(226, 232, 240, 0.96);
  border-radius: 14px;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.13);
  backdrop-filter: blur(12px);
}

/* Shell */
.ant-layout.layout-basic,
.ant-layout-content {
  background: var(--page) !important;
}

.ant-layout-sider,
.ant-layout-sider-children,
.ant-menu-dark,
.ant-menu-dark .ant-menu-sub {
  background: var(--side) !important;
}

.ant-layout-sider {
  box-shadow: 8px 0 24px rgba(15, 23, 42, 0.12);
}

.ant-menu-dark .ant-menu-item,
.ant-menu-dark .ant-menu-submenu-title {
  height: 42px !important;
  line-height: 42px !important;
  margin: 4px 10px !important;
  width: calc(100% - 20px) !important;
  border-radius: 8px;
}

.ant-menu-dark .ant-menu-item:hover,
.ant-menu-dark .ant-menu-submenu-title:hover {
  background: var(--side-soft) !important;
}

.ant-menu-dark .ant-menu-item-selected,
.ant-menu-dark .ant-menu-submenu-selected,
.ant-menu-dark .ant-menu-submenu-open > .ant-menu-submenu-title {
  color: #fff !important;
  background: linear-gradient(135deg, var(--brand), var(--accent)) !important;
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.24);
}

.ant-layout-header,
.cus-main .header {
  background: rgba(255, 255, 255, 0.97) !important;
  border-bottom: 1px solid var(--line);
  box-shadow: 0 8px 26px rgba(15, 23, 42, 0.06);
  backdrop-filter: blur(10px);
}

.header-img-left .header-img-title,
.ant-pro-global-header-index-right.ant-pro-global-header-index-dark .ant-pro-global-header-index-action {
  color: var(--ink) !important;
}

.ant-pro-global-header-index-right .ant-pro-account-avatar .antd-pro-global-header-index-avatar {
  background: #eff6ff !important;
  color: var(--brand) !important;
}

/* Cards, search, dashboard blocks */
.ant-card,
.ant-table-wrapper,
.table-page-search-wrapper,
.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col > div {
  border: 1px solid var(--line) !important;
  border-radius: 8px !important;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.07);
  background: #fff;
}

.ant-card {
  overflow: hidden;
}

.ant-card-head {
  min-height: 48px !important;
  border-bottom-color: var(--line) !important;
  background: #fff;
}

.ant-card-head-title,
.ant-table-title,
.p2 {
  color: var(--ink);
  font-weight: 700;
}

.table-page-search-wrapper {
  padding: 20px 20px 0;
  margin-bottom: 16px;
}

.table-operator {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px !important;
}

.table-operator button {
  margin-right: 0 !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col .top-count-acolp {
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%) !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col .top-count-acoldiv {
  background: linear-gradient(180deg, var(--brand), var(--accent)) !important;
}

/* Tables */
.ant-table {
  color: var(--ink);
}

.ant-table-thead > tr > th {
  color: var(--ink-soft) !important;
  background: #f8fafc !important;
  border-bottom: 1px solid var(--line) !important;
  font-weight: 700 !important;
}

.ant-table-tbody > tr > td {
  border-bottom-color: var(--line-soft) !important;
}

.ant-table-tbody > tr:hover > td {
  background: #eff6ff !important;
}

.ant-table-small > .ant-table-content > .ant-table-body {
  margin: 0 !important;
}

/* Controls */
.ant-input,
.ant-input-number,
.ant-select-selection,
.ant-calendar-picker-input,
.ant-time-picker-input,
.ant-cascader-picker {
  border-color: #cbd5e1 !important;
  border-radius: 8px !important;
  box-shadow: none !important;
}

.ant-input:hover,
.ant-input:focus,
.ant-select-selection:hover,
.ant-select-open .ant-select-selection,
.ant-calendar-picker:hover .ant-calendar-picker-input {
  border-color: var(--brand) !important;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12) !important;
}

.ant-btn {
  border-radius: 8px !important;
  font-weight: 600;
  box-shadow: none !important;
}

.ant-btn-primary {
  border-color: var(--brand) !important;
  background: linear-gradient(135deg, var(--brand), var(--accent)) !important;
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.22) !important;
}

.ant-btn-primary:hover,
.ant-btn-primary:focus {
  border-color: var(--brand-dark) !important;
  background: linear-gradient(135deg, var(--brand-dark), #0f766e) !important;
}

.ant-tag {
  border-radius: 999px !important;
  padding: 0 9px !important;
}

.ant-pagination-item,
.ant-pagination-prev .ant-pagination-item-link,
.ant-pagination-next .ant-pagination-item-link {
  border-radius: 8px !important;
}

.ant-pagination-item-active {
  border-color: var(--brand) !important;
}

.ant-modal-content,
.ant-dropdown-menu {
  border-radius: 8px !important;
  box-shadow: 0 18px 48px rgba(15, 23, 42, 0.16) !important;
}

.ant-modal-header {
  border-radius: 8px 8px 0 0 !important;
}

/* Loading */
.first-loading-wrp {
  min-height: 100vh !important;
  background: linear-gradient(135deg, #f8fbff, #eef4ff);
  color: var(--ink);
}

.dot i,
#nprogress .bar {
  background-color: var(--brand) !important;
}

#nprogress .peg {
  box-shadow: 0 0 10px var(--brand), 0 0 5px var(--brand) !important;
}

@media (max-width: 768px) {
  #userLayout.user-layout-wrapper .container .user-layout-content {
    padding-top: 24px !important;
  }

  #userLayout.user-layout-wrapper .container .user-layout-content .main {
    padding: 24px 18px 22px;
    border-radius: 12px;
  }

  #userLayout.user-layout-wrapper .container .user-layout-content .top .header .title {
    font-size: 24px !important;
  }

  .ant-card,
  .ant-table-wrapper,
  .table-page-search-wrapper {
    border-radius: 8px !important;
  }

  .table-page-search-wrapper {
    padding: 16px 14px 0;
  }

  .table-page-search-wrapper .ant-form-inline .ant-form-item {
    margin-bottom: 14px !important;
  }
}

/* Total overview: category modules instead of the old single-row summary. */
.dytj-manager-flex {
  margin-top: 16px;
}

.dytj-manager-flex .top-count-cus {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 14px 0 18px !important;
}

.dytj-manager-flex .top-count-cus::after {
  display: block;
  clear: both;
  content: "";
}

.dytj-manager-flex .top-count-cus .top-count-colone {
  display: none !important;
  float: none !important;
  width: 100% !important;
}

.dytj-manager-flex .top-count-cus .top-count-colone .top-count-acolp {
  padding: 0 !important;
  text-align: left !important;
}

.dytj-manager-flex .top-count-cus .top-count-colone .p1-total {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  color: transparent;
  font-size: 0 !important;
  line-height: 1.3 !important;
}

.dytj-manager-flex .top-count-cus .top-count-colone .p1-total .myImg1 {
  display: none !important;
}

.dytj-manager-flex .top-count-cus .top-count-colone .p1-total::before {
  color: var(--ink);
  font-size: 18px;
  font-weight: 750;
  content: "";
}

.dytj-manager-flex .top-count-cus .top-count-colone .p1-total::after {
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  content: "";
}

.dytj-manager-flex .top-count-cus .top-count-coltwo {
  float: none !important;
  display: grid !important;
  grid-template-columns: repeat(4, minmax(220px, 1fr));
  gap: 14px;
  width: 100% !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col {
  position: relative;
  float: none !important;
  flex: none !important;
  width: auto !important;
  min-width: 0;
  margin: 0 !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acoldiv {
  display: none !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp {
  position: relative;
  min-height: 180px;
  height: auto !important;
  padding: 50px 16px 16px !important;
  overflow: hidden;
  text-align: left !important;
  background: #fff !important;
  border: 1px solid var(--line) !important;
  border-radius: 12px !important;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.07);
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp::before {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 1;
  color: var(--ink);
  font-size: 15px;
  font-weight: 750;
  line-height: 20px;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp::after {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--brand), var(--accent));
  content: "";
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1) .top-count-acolp::before {
  content: "订阅与扣款";
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(2) .top-count-acolp::before {
  content: "成本";
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(3) .top-count-acolp::before {
  content: "ROI 与收支";
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(4) .top-count-acolp::before {
  content: "有效扣款";
}

.dytj-manager-flex .top-count-cus .count-kkl-left {
  float: none !important;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0 !important;
  font-size: 13px !important;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-dy,
.dytj-manager-flex .top-count-cus .count-kkl-left-kk {
  padding: 12px;
  background: #f8fafc;
  border: 1px solid var(--line-soft);
  border-radius: 8px;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-dyone,
.dytj-manager-flex .top-count-cus .count-kkl-left-kkone {
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 13px !important;
  font-weight: 600;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-dytwo,
.dytj-manager-flex .top-count-cus .count-kkl-left-kktwo {
  margin-left: 0 !important;
  color: var(--ink);
  font-size: 28px !important;
  font-weight: 800;
  line-height: 1.1;
}

.dytj-manager-flex .top-count-cus .count-kkl-right {
  float: none !important;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: auto !important;
  margin: 12px 0 0 !important;
  padding: 12px !important;
  color: var(--brand-dark);
  background: #eff6ff;
  border-radius: 8px;
}

.dytj-manager-flex .top-count-cus .count-kkl-right .p1 {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 650;
}

.dytj-manager-flex .top-count-cus .count-kkl-right .p2 {
  margin: 0;
  color: var(--brand-dark);
  font-size: 26px;
  font-weight: 800;
  line-height: 1;
}

.dytj-manager-flex .top-count-cus .top-count-acolp > div[style] {
  padding: 0 !important;
}

.dytj-manager-flex .top-count-cus .count-cb-left {
  float: none !important;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  height: auto !important;
  min-height: 48px;
  margin: 0 0 10px !important;
  padding: 11px 12px;
  text-align: left !important;
  background: #f8fafc;
  border: 1px solid var(--line-soft);
  border-radius: 8px;
}

.dytj-manager-flex .top-count-cus .count-cb-left-one,
.dytj-manager-flex .top-count-cus .count-cb-left-two {
  float: none !important;
  width: auto !important;
  margin-right: 0 !important;
}

.dytj-manager-flex .top-count-cus .count-cb-left-one {
  color: var(--muted);
  font-size: 13px !important;
  font-weight: 650 !important;
}

.dytj-manager-flex .top-count-cus .count-cb-left-two {
  color: var(--ink);
  font-size: 24px !important;
  font-weight: 800 !important;
  line-height: 1.1;
  text-align: right;
}

.dytj-manager-flex .top-count-cus .count-cb-left-one > div:first-child,
.dytj-manager-flex .top-count-cus .count-cb-left-two > div:first-child {
  color: var(--muted);
  font-size: 13px;
  font-weight: 650;
}

.dytj-manager-flex .top-count-cus .count-cb-left-one > div:last-child,
.dytj-manager-flex .top-count-cus .count-cb-left-two > div:last-child {
  margin-top: 5px;
  color: var(--ink);
  font-size: 22px;
  font-weight: 800;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:last-child {
  display: block !important;
  margin-top: 12px !important;
  color: var(--muted) !important;
  font-size: 12px;
  line-height: 1.7;
  background: #fff7ed;
  border-color: #fed7aa;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:last-child span {
  color: #dc2626 !important;
  font-size: 16px !important;
  font-weight: 800;
}

@media (max-width: 1400px) {
  .dytj-manager-flex .top-count-cus .top-count-coltwo {
    grid-template-columns: repeat(2, minmax(220px, 1fr));
  }
}

@media (max-width: 760px) {
  .dytj-manager-flex .top-count-cus .top-count-colone .p1-total {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo {
    grid-template-columns: 1fr;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp {
    min-height: auto;
  }
}

/* V4 compact metric dashboard: split large summary panels into smaller modules. */
.table-operator:empty {
  display: none !important;
  height: 0 !important;
  margin: 0 !important;
}

.dytj-manager-flex {
  margin-top: 10px !important;
}

.dytj-manager-flex .top-count-cus {
  gap: 0 !important;
  margin: 8px 0 14px !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)) !important;
  gap: 12px !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  min-height: 0 !important;
  padding: 44px 12px 12px !important;
  border-radius: 10px !important;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp::before {
  top: 13px !important;
  left: 14px !important;
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 9px;
  color: #0f172a;
  font-size: 13px;
  background: #f8fafc;
  border: 1px solid var(--line-soft);
  border-radius: 999px;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp::after {
  height: 3px !important;
  opacity: 0.85;
}

.dytj-manager-flex .top-count-cus .count-kkl-left,
.dytj-manager-flex .top-count-cus .top-count-acolp > div[style] {
  display: contents !important;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-dy,
.dytj-manager-flex .top-count-cus .count-kkl-left-kk,
.dytj-manager-flex .top-count-cus .count-kkl-right,
.dytj-manager-flex .top-count-cus .count-cb-left {
  min-height: 74px;
  margin: 0 !important;
  padding: 11px 12px !important;
  background: #f8fafc;
  border: 1px solid var(--line-soft);
  border-radius: 8px;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-dy,
.dytj-manager-flex .top-count-cus .count-kkl-left-kk {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.dytj-manager-flex .top-count-cus .count-kkl-right {
  grid-column: 1 / -1;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  color: var(--brand-dark);
  background: #eff6ff;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-dyone,
.dytj-manager-flex .top-count-cus .count-kkl-left-kkone,
.dytj-manager-flex .top-count-cus .count-cb-left-one {
  margin: 0 0 6px !important;
  color: var(--muted);
  font-size: 12px !important;
  font-weight: 650 !important;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-dytwo,
.dytj-manager-flex .top-count-cus .count-kkl-left-kktwo,
.dytj-manager-flex .top-count-cus .count-cb-left-two {
  color: #0f172a;
  font-size: clamp(20px, 1.8vw, 26px) !important;
  font-weight: 800 !important;
  line-height: 1.1;
}

.dytj-manager-flex .top-count-cus .count-cb-left {
  grid-template-columns: minmax(0, 1fr);
  align-content: center;
  gap: 0;
  min-height: 74px !important;
}

.dytj-manager-flex .top-count-cus .count-cb-left-one,
.dytj-manager-flex .top-count-cus .count-cb-left-two {
  text-align: left !important;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(3) .count-cb-left:first-child {
  grid-column: 1 / -1;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(3) .count-cb-left:nth-child(2) {
  grid-column: 1 / -1;
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 0 !important;
  background: transparent;
  border: 0;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(3) .count-cb-left:nth-child(2) .count-cb-left-one,
.dytj-manager-flex .top-count-cus .top-count-col:nth-child(3) .count-cb-left:nth-child(2) .count-cb-left-two {
  min-height: 74px;
  padding: 11px 12px;
  background: #f8fafc;
  border: 1px solid var(--line-soft);
  border-radius: 8px;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child {
  grid-column: 1 / -1;
  grid-template-columns: minmax(0, 1fr) auto;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:last-child {
  grid-column: 1 / -1;
  min-height: 0 !important;
  margin-top: 0 !important;
  padding: 9px 11px !important;
  font-size: 12px;
  line-height: 1.55;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:last-child span {
  font-size: 14px !important;
}

@media (max-width: 1180px) {
  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .dytj-manager-flex .top-count-cus {
    margin-top: 6px !important;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo {
    gap: 10px !important;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp {
    grid-template-columns: 1fr;
    padding: 42px 10px 10px !important;
  }

  .dytj-manager-flex .top-count-cus .count-kkl-right,
  .dytj-manager-flex .top-count-cus .top-count-col:nth-child(3) .count-cb-left:first-child,
  .dytj-manager-flex .top-count-cus .top-count-col:nth-child(3) .count-cb-left:nth-child(2),
  .dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child {
    grid-column: auto;
  }

  .dytj-manager-flex .top-count-cus .top-count-col:nth-child(3) .count-cb-left:nth-child(2) {
    grid-template-columns: 1fr;
  }
}

/* V5: refund-aware summary layout. */
.dytj-manager-flex .top-count-cus .top-count-coltwo {
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  align-items: stretch;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col {
  min-width: 0;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1) {
  grid-column: span 2;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1) .top-count-acolp {
  grid-template-columns: repeat(5, minmax(82px, 1fr)) !important;
  min-height: 138px !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1) .top-count-acolp::before {
  content: "订阅 / 扣款 / 退款" !important;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-dy {
  order: 1;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-kk {
  order: 2;
}

.dytj-manager-flex .top-count-cus .count-kkl-right {
  grid-column: auto !important;
  order: 3;
  display: flex !important;
  flex-direction: column;
  justify-content: center;
  background: #eef6ff;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-tk {
  order: 4;
  background: #fff7ed;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-tkl {
  order: 5;
  background: #fff1f2;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-tk,
.dytj-manager-flex .top-count-cus .count-kkl-left-tkl {
  display: flex;
  min-height: 74px;
  flex-direction: column;
  justify-content: center;
  margin: 0 !important;
  padding: 11px 12px !important;
  border: 1px solid var(--line-soft);
  border-radius: 8px;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-tkone,
.dytj-manager-flex .top-count-cus .count-kkl-left-tklone,
.dytj-manager-flex .top-count-cus .count-kkl-right .p1 {
  margin: 0 0 6px !important;
  color: var(--muted);
  font-size: 12px !important;
  font-weight: 650 !important;
  line-height: 1.25;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-tktwo,
.dytj-manager-flex .top-count-cus .count-kkl-left-tkltwo,
.dytj-manager-flex .top-count-cus .count-kkl-right .p2 {
  margin: 0 !important;
  color: #0f172a;
  font-size: clamp(20px, 1.8vw, 26px) !important;
  font-weight: 800 !important;
  line-height: 1.1;
}

@media (max-width: 1320px) {
  .dytj-manager-flex .top-count-cus .top-count-coltwo {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1) {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .dytj-manager-flex .top-count-cus .top-count-coltwo {
    grid-template-columns: 1fr !important;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1) {
    grid-column: auto;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1) .top-count-acolp {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media (max-width: 420px) {
  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1) .top-count-acolp {
    grid-template-columns: 1fr !important;
  }
}

/* V6: adaptive summary composition and full-width content. */
html,
body,
#app,
.cus-main {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

.cus-main > div:nth-child(2),
.ant-layout-content,
.ant-card,
.ant-card-body {
  width: 100%;
  max-width: none !important;
  min-width: 0;
}

.cus-main > div:nth-child(2) {
  padding: 14px 16px 20px !important;
  overflow-x: auto;
}

.ant-card-body {
  padding: 18px !important;
}

.ant-table-wrapper,
.ant-table-content,
.ant-table-body {
  max-width: 100%;
}

.ant-table-wrapper {
  overflow-x: auto;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo {
  grid-template-columns: minmax(420px, 1.35fr) repeat(2, minmax(220px, 1fr)) !important;
  grid-auto-rows: minmax(128px, auto);
  gap: 12px !important;
  width: 100% !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1) {
  grid-column: 1;
  grid-row: 1 / span 2;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(2) {
  grid-column: 2 / 4;
  grid-row: 1;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(3) {
  grid-column: 2;
  grid-row: 2;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(4) {
  grid-column: 3;
  grid-row: 2;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp {
  min-height: 100% !important;
  border-color: rgba(203, 213, 225, 0.9) !important;
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%) !important;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp:hover {
  transform: translateY(-2px);
  border-color: rgba(37, 99, 235, 0.28) !important;
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.1);
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp::after {
  display: none !important;
  content: none !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1) .top-count-acolp {
  grid-template-columns: repeat(5, minmax(74px, 1fr)) !important;
  background: linear-gradient(135deg, #ffffff 0%, #eef6ff 100%) !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(2) .top-count-acolp {
  background: linear-gradient(135deg, #ffffff 0%, #f0fdf4 100%) !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(3) .top-count-acolp {
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 56%, #eff6ff 100%) !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(4) .top-count-acolp {
  background: linear-gradient(135deg, #ffffff 0%, #fff7ed 100%) !important;
}

.dytj-manager-flex .top-count-cus .count-kkl-left-dytwo,
.dytj-manager-flex .top-count-cus .count-kkl-left-kktwo,
.dytj-manager-flex .top-count-cus .count-kkl-left-tktwo,
.dytj-manager-flex .top-count-cus .count-kkl-left-tkltwo,
.dytj-manager-flex .top-count-cus .count-kkl-right .p2,
.dytj-manager-flex .top-count-cus .count-cb-left-two {
  font-size: 24px !important;
}

@media (max-width: 1320px) {
  .dytj-manager-flex .top-count-cus .top-count-coltwo {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    grid-auto-rows: auto;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1),
  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(2) {
    grid-column: 1 / -1;
    grid-row: auto;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(3) {
    grid-column: 1;
    grid-row: auto;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(4) {
    grid-column: 2;
    grid-row: auto;
  }
}

/* V8: effective deduction card polish, no page layout changes. */
body,
.ant-card,
.ant-table,
.ant-btn,
.ant-input,
.ant-select {
  font-family: "Inter", "SF Pro Text", "HarmonyOS Sans SC", "PingFang SC",
    "Microsoft YaHei", Arial, sans-serif;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(4) .top-count-acolp {
  background:
    radial-gradient(circle at 88% 18%, rgba(16, 185, 129, 0.12), transparent 34%),
    linear-gradient(135deg, #ffffff 0%, #f0fdf4 58%, #ecfeff 100%) !important;
  border-color: rgba(134, 239, 172, 0.95) !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(4) .top-count-acolp::before {
  color: #047857 !important;
  background: #ecfdf5 !important;
  border-color: #bbf7d0 !important;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child {
  position: relative;
  grid-column: 1 / -1;
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  grid-template-rows: auto minmax(36px, 1fr);
  min-height: 128px !important;
  gap: 7px 18px;
  align-items: end;
  padding: 18px !important;
  overflow: hidden;
  background:
    linear-gradient(90deg, transparent calc(50% - 0.5px), rgba(16, 185, 129, 0.22) calc(50% - 0.5px), rgba(16, 185, 129, 0.22) calc(50% + 0.5px), transparent calc(50% + 0.5px)),
    linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(236, 253, 245, 0.94));
  border: 1px solid rgba(167, 243, 208, 0.96);
  border-radius: 10px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child::after {
  position: absolute;
  right: 12px;
  bottom: 10px;
  width: 54px;
  height: 54px;
  background: rgba(20, 184, 166, 0.08);
  border-radius: 50%;
  content: "";
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child .count-cb-left-one,
.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child .count-cb-left-two {
  position: relative;
  z-index: 1;
  width: auto !important;
  margin: 0 !important;
  text-align: left !important;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child .count-cb-left-one:nth-child(1) {
  grid-column: 1;
  grid-row: 1;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child .count-cb-left-two:nth-child(2) {
  grid-column: 1;
  grid-row: 2;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child .count-cb-left-one:nth-child(3) {
  grid-column: 2;
  grid-row: 1;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child .count-cb-left-two:nth-child(4) {
  grid-column: 2;
  grid-row: 2;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child .count-cb-left-one {
  color: #0f766e !important;
  font-size: 12px !important;
  font-weight: 750 !important;
  letter-spacing: 0;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child .count-cb-left-two {
  color: #064e3b !important;
  font-size: clamp(27px, 2.35vw, 36px) !important;
  font-weight: 850 !important;
  line-height: 1;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child .count-cb-left-two:nth-child(4) {
  color: #0f5fd4 !important;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:last-child {
  grid-column: 1 / -1;
  display: flex !important;
  align-items: center;
  gap: 10px;
  min-height: 62px !important;
  padding: 13px 14px !important;
  color: #7c2d12 !important;
  font-size: 12px !important;
  line-height: 1.55;
  background: linear-gradient(135deg, #fff7ed 0%, #fffbeb 100%) !important;
  border: 1px solid #fed7aa !important;
  border-radius: 10px !important;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:last-child::before {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  color: #b45309;
  font-size: 12px;
  font-weight: 800;
  background: #ffedd5;
  border: 1px solid #fed7aa;
  border-radius: 50%;
  content: "趋势";
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:last-child > div {
  min-width: 0;
}

.dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:last-child span {
  color: #dc2626 !important;
  font-size: 15px !important;
  font-weight: 850;
}

@media (max-width: 520px) {
  .dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child {
    grid-template-columns: 1fr !important;
    grid-template-rows: auto auto auto auto;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(236, 253, 245, 0.94));
  }

  .dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child .count-cb-left-one:nth-child(1),
  .dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child .count-cb-left-two:nth-child(2),
  .dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child .count-cb-left-one:nth-child(3),
  .dytj-manager-flex .top-count-cus .top-count-col:nth-child(4) .count-cb-left:first-child .count-cb-left-two:nth-child(4) {
    grid-column: 1;
    grid-row: auto;
  }
}

@media (max-width: 760px) {
  .cus-main > div:nth-child(2) {
    padding: 10px !important;
  }

  .ant-card-body {
    padding: 12px !important;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo {
    grid-template-columns: 1fr !important;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1),
  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(2),
  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(3),
  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(4) {
    grid-column: auto;
    grid-row: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp {
    transition: none;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-acolp:hover {
    transform: none;
  }
}

/* V7: place the cost module directly under the subscription module. */
.dytj-manager-flex .top-count-cus .top-count-coltwo {
  grid-template-columns: minmax(420px, 1.2fr) repeat(2, minmax(230px, 1fr)) !important;
  grid-auto-rows: minmax(126px, auto);
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1) {
  grid-column: 1;
  grid-row: 1;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(2) {
  grid-column: 1;
  grid-row: 2;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(3) {
  grid-column: 2;
  grid-row: 1 / span 2;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(4) {
  grid-column: 3;
  grid-row: 1 / span 2;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1) .top-count-acolp {
  min-height: 126px !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(2) .top-count-acolp {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  min-height: 126px !important;
}

.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(3) .top-count-acolp,
.dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(4) .top-count-acolp {
  align-content: start;
}

@media (max-width: 1320px) {
  .dytj-manager-flex .top-count-cus .top-count-coltwo {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1) {
    grid-column: 1;
    grid-row: 1;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(2) {
    grid-column: 1;
    grid-row: 2;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(3) {
    grid-column: 2;
    grid-row: 1;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(4) {
    grid-column: 2;
    grid-row: 2;
  }
}

@media (max-width: 760px) {
  .dytj-manager-flex .top-count-cus .top-count-coltwo {
    grid-template-columns: 1fr !important;
  }

  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(1),
  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(2),
  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(3),
  .dytj-manager-flex .top-count-cus .top-count-coltwo .top-count-col:nth-child(4) {
    grid-column: auto;
    grid-row: auto;
  }
}
