/* v1.0.105 desktop repair loaded after styles.css. */
body.auth-locked {
  overflow: hidden !important;
}

/* Desktop debtors: keep long customer lists calm by showing row quick actions on demand. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card {
    transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card:not(:hover):not(:focus-within) .desktop-debtor-quick-actions.desktop-debtor-reference-actions {
    max-height: 0 !important;
    margin-top: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    overflow: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card:hover,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card:focus-within {
    border-color: #dbe7f2 !important;
    box-shadow: 0 14px 30px rgba(15, 23, 42, .075) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card:hover .desktop-debtor-quick-actions.desktop-debtor-reference-actions,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card:focus-within .desktop-debtor-quick-actions.desktop-debtor-reference-actions {
    max-height: 92px !important;
    opacity: 1 !important;
    pointer-events: auto !important;
  }
}

/* Desktop debtors card final compact pass: override later inline desktop layout when the window is narrowed. */
@media (min-width: 769px) and (max-width: 1800px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card {
    grid-template-columns: minmax(270px, 1.28fr) minmax(130px, .62fr) minmax(140px, .68fr) minmax(176px, .82fr) 152px 50px !important;
    grid-template-areas:
      "person amount status due actions more"
      "person progress progress progress actions more" !important;
    align-items: stretch !important;
    gap: 14px !important;
    min-height: 168px !important;
    padding: 20px 18px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-person {
    grid-area: person !important;
    align-self: center !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-metric:nth-of-type(1) {
    grid-area: amount !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-metric:nth-of-type(2) {
    grid-area: status !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-metric:nth-of-type(3) {
    grid-area: due !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-progress {
    grid-area: progress !important;
    align-self: end !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-actions {
    grid-area: actions !important;
    align-self: center !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-more {
    grid-area: more !important;
    align-self: center !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-person-copy > div {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    align-items: start !important;
    gap: 8px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-name {
    max-width: 100% !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-tag {
    max-width: 100% !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-metric,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-progress {
    min-width: 0 !important;
    padding-left: 14px !important;
  }
}

/* Desktop debtor summary exact size guard: higher specificity than older debtor rules. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-summary-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr)) !important;
    gap: 12px !important;
    margin: 0 0 18px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-summary-card {
    grid-template-columns: minmax(0, 1fr) 36px !important;
    min-height: 76px !important;
    height: 76px !important;
    padding: 12px 13px !important;
    border-radius: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-summary-icon {
    width: 36px !important;
    height: 36px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-summary-icon svg {
    width: 18px !important;
    height: 18px !important;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card {
    grid-template-columns: minmax(245px, 1.05fr) minmax(132px, .6fr) minmax(132px, .6fr) 144px 48px !important;
    grid-template-areas:
      "person amount due actions more"
      "person status status actions more"
      "progress progress progress actions more" !important;
    gap: 12px !important;
    min-height: 204px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-person {
    grid-template-columns: 64px minmax(0, 1fr) !important;
    gap: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-avatar {
    width: 64px !important;
    height: 64px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-actions button {
    height: 46px !important;
    font-size: 14px !important;
  }
}

/* Desktop tracking page: keep this last so the debtor-style board wins over old table CSS. */
@media (min-width: 769px) {
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    margin: clamp(22px, 2.2vw, 34px) 0 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .panel-title,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .mini-summary-grid,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .simple-table-wrap,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .tracking-footer,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > #trackingMobileList {
    display: none !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) #desktopTrackingBoard {
    display: block !important;
    width: 100% !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-board {
    display: block !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-grid {
    display: grid !important;
    grid-template-columns: repeat(6, minmax(0, 1fr)) !important;
    gap: 14px !important;
    margin: 0 0 18px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-toolbar {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 360px) !important;
    gap: 14px !important;
    align-items: center !important;
    margin: 0 0 22px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-list {
    display: grid !important;
    gap: 14px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-card {
    display: grid !important;
    grid-template-columns: minmax(260px, 1.25fr) minmax(130px, .62fr) minmax(150px, .72fr) minmax(150px, .72fr) minmax(132px, .64fr) 170px 56px !important;
    gap: 14px !important;
    align-items: center !important;
    min-height: 150px !important;
    padding: 18px 18px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-actions button {
    min-height: 48px !important;
    border-radius: 14px !important;
    font-size: 15px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-more-button {
    width: 50px !important;
    min-height: 58px !important;
    border-radius: 16px !important;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-toolbar {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-card {
    grid-template-columns: minmax(240px, 1fr) minmax(130px, .7fr) minmax(130px, .7fr) 150px 50px !important;
    grid-template-areas:
      "person period due actions more"
      "person amount status actions more" !important;
    min-height: 168px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-person {
    grid-area: person !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric:nth-of-type(1) {
    grid-area: period !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric:nth-of-type(2) {
    grid-area: due !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric:nth-of-type(3) {
    grid-area: amount !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-status {
    grid-area: status !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-actions {
    grid-area: actions !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-more {
    grid-area: more !important;
  }
}

/* Final desktop tracking fence: placed last so older tracking-table styling cannot win. */
@media (min-width: 769px) {
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    margin: 28px 0 0 !important;
    padding: 0 !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 28px !important;
    background: #fff !important;
    box-shadow: 0 24px 60px rgba(15, 23, 42, .08) !important;
    overflow: visible !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .panel-title,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .mini-summary-grid,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .simple-table-wrap,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .tracking-footer,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > #trackingMobileList {
    display: none !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) #desktopTrackingBoard {
    display: block !important;
    padding: 36px 34px 32px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-board {
    display: grid !important;
  }
}

/* Desktop tracking page: match the debtor page pattern without touching mobile. */
#desktopTrackingBoard {
  display: none;
}

@media (max-width: 768px), (hover: none), (pointer: coarse) {
  html body:not(.auth-locked) #desktopTrackingBoard {
    display: none !important;
  }
}

@media (min-width: 769px) {
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    margin: 28px 0 0 !important;
    padding: 0 !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 28px !important;
    background: #fff !important;
    box-shadow: 0 24px 60px rgba(15, 23, 42, .08) !important;
    overflow: visible !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .panel-title,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .mini-summary-grid,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .simple-table-wrap,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .tracking-footer,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > #trackingMobileList {
    display: none !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) #desktopTrackingBoard {
    display: block !important;
    padding: 36px 34px 32px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-board,
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-board * {
    box-sizing: border-box !important;
    letter-spacing: 0 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-board {
    display: grid !important;
    gap: 28px !important;
    color: #101828 !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-grid {
    display: grid !important;
    grid-template-columns: repeat(6, minmax(0, 1fr)) !important;
    gap: 16px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-card {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 52px !important;
    align-items: center !important;
    min-height: 104px !important;
    padding: 18px 18px !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 16px !important;
    background: #fff !important;
    color: #101828 !important;
    text-align: left !important;
    box-shadow: 0 14px 34px rgba(15, 23, 42, .045) !important;
    cursor: pointer !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-card.is-active,
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-card:hover {
    border-color: #49a469 !important;
    box-shadow: 0 18px 42px rgba(18, 114, 76, .10) !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-copy {
    display: grid !important;
    gap: 12px !important;
    min-width: 0 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-copy > span {
    color: #667085 !important;
    font-size: 13px !important;
    font-weight: 800 !important;
    line-height: 1.2 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-card.is-good .desktop-tracking-summary-copy > span {
    color: #32835b !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-card.is-danger .desktop-tracking-summary-copy > span {
    color: #df3a43 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-card.is-warning .desktop-tracking-summary-copy > span,
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-card.is-today .desktop-tracking-summary-copy > span {
    color: #f97316 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-copy strong {
    display: flex !important;
    align-items: baseline !important;
    gap: 7px !important;
    color: #111827 !important;
    font-family: Inter, "IBM Plex Sans Thai", sans-serif !important;
    font-size: 30px !important;
    font-weight: 850 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-copy small {
    color: #667085 !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", sans-serif !important;
    font-size: 13px !important;
    font-weight: 800 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-icon {
    display: grid !important;
    width: 52px !important;
    height: 52px !important;
    place-items: center !important;
    border-radius: 50% !important;
    color: #15955f !important;
    background: #dcfce7 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-icon svg {
    width: 26px !important;
    height: 26px !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-toolbar {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(260px, 360px) !important;
    gap: 18px !important;
    align-items: center !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-filters {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 12px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-filter {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 12px !important;
    min-height: 50px !important;
    padding: 0 20px !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 14px !important;
    background: #fff !important;
    color: #667085 !important;
    font-size: 14px !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .035) !important;
    cursor: pointer !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-filter strong {
    display: inline-grid !important;
    min-width: 28px !important;
    height: 28px !important;
    place-items: center !important;
    border-radius: 50% !important;
    background: #eef2f7 !important;
    color: #667085 !important;
    font-family: Inter, sans-serif !important;
    font-size: 13px !important;
    font-weight: 850 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-filter.is-active {
    border-color: #009b62 !important;
    background: #0f9f68 !important;
    color: #fff !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-filter.is-active strong {
    background: rgba(255,255,255,.18) !important;
    color: #fff !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-filter.is-danger strong {
    background: #ffe4e8 !important;
    color: #df3a43 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-filter.is-warning strong,
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-filter.is-today strong {
    background: #ffedd5 !important;
    color: #f97316 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-sort {
    display: grid !important;
    grid-template-columns: auto minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 16px !important;
    min-height: 54px !important;
    padding: 0 18px !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 16px !important;
    background: #fff !important;
    box-shadow: 0 14px 34px rgba(15, 23, 42, .045) !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-sort span,
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-sort select {
    color: #101828 !important;
    font-size: 14px !important;
    font-weight: 850 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-sort select {
    min-width: 0 !important;
    border: 0 !important;
    background: transparent !important;
    outline: none !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-list {
    display: grid !important;
    gap: 18px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-card {
    display: grid !important;
    grid-template-columns: minmax(250px, 1.2fr) minmax(130px, .6fr) minmax(150px, .7fr) minmax(150px, .72fr) minmax(142px, .68fr) 180px 56px !important;
    align-items: center !important;
    gap: 18px !important;
    min-height: 150px !important;
    padding: 22px 24px !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 22px !important;
    background: #fff !important;
    box-shadow: 0 18px 42px rgba(15, 23, 42, .055) !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-person {
    display: grid !important;
    grid-template-columns: 72px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 18px !important;
    min-width: 0 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-avatar {
    display: grid !important;
    width: 72px !important;
    height: 72px !important;
    place-items: center !important;
    overflow: hidden !important;
    border: 1px solid #c9f2df !important;
    border-radius: 50% !important;
    background: #ecfdf5 !important;
    color: #0f9f68 !important;
    font-size: 24px !important;
    font-weight: 850 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-avatar img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-person-copy,
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric {
    display: grid !important;
    gap: 8px !important;
    min-width: 0 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-name {
    display: block !important;
    max-width: 100% !important;
    overflow: hidden !important;
    border: 0 !important;
    background: transparent !important;
    color: #101828 !important;
    font-size: 20px !important;
    font-weight: 850 !important;
    line-height: 1.12 !important;
    text-align: left !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    cursor: pointer !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-person-copy span,
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-person-copy small,
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric span,
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric small {
    overflow: hidden !important;
    color: #667085 !important;
    font-size: 13px !important;
    font-weight: 750 !important;
    line-height: 1.2 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric {
    min-height: 76px !important;
    padding-left: 16px !important;
    border-left: 1px solid #e6edf5 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric strong {
    overflow: hidden !important;
    color: #101828 !important;
    font-family: Inter, "IBM Plex Sans Thai", sans-serif !important;
    font-size: 18px !important;
    font-weight: 850 !important;
    line-height: 1.15 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric small.is-danger,
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-card.is-danger .desktop-tracking-metric strong {
    color: #df3a43 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric small.is-warning,
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric small.is-today {
    color: #f97316 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-status-pill {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-height: 42px !important;
    max-width: 100% !important;
    padding: 0 16px !important;
    border-radius: 12px !important;
    background: #dcfce7 !important;
    color: #15803d !important;
    font-size: 13px !important;
    font-weight: 850 !important;
    white-space: nowrap !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-status-pill.is-danger {
    background: #ffe4e8 !important;
    color: #df3a43 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-status-pill.is-warning,
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-status-pill.is-today {
    background: #ffedd5 !important;
    color: #f97316 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-actions {
    display: grid !important;
    gap: 10px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-actions button {
    width: 100% !important;
    min-height: 46px !important;
    border-radius: 14px !important;
    font-size: 14px !important;
    font-weight: 850 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-actions .primary-button {
    border: 0 !important;
    background: linear-gradient(135deg, #12b76a, #087443) !important;
    color: #fff !important;
    box-shadow: 0 16px 32px rgba(18, 119, 76, .20) !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-actions .secondary-button {
    border: 1px solid #dfe7f0 !important;
    background: #fff !important;
    color: #0f172a !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-actions button:disabled {
    opacity: .46 !important;
    cursor: not-allowed !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-more-button {
    display: grid !important;
    width: 54px !important;
    height: 58px !important;
    place-items: center !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 16px !important;
    background: #fff !important;
    color: #101828 !important;
    font-family: Inter, sans-serif !important;
    font-size: 26px !important;
    font-weight: 850 !important;
    cursor: pointer !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-empty {
    display: grid !important;
    min-height: 160px !important;
    place-items: center !important;
    border: 1px dashed #d8e2ee !important;
    border-radius: 22px !important;
    color: #667085 !important;
    font-size: 16px !important;
    font-weight: 800 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-footer {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto minmax(150px, auto) !important;
    align-items: center !important;
    gap: 18px !important;
    color: #667085 !important;
    font-size: 14px !important;
    font-weight: 800 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-pagination {
    display: flex !important;
    gap: 8px !important;
    align-items: center !important;
    justify-content: center !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-pagination button {
    display: grid !important;
    width: 44px !important;
    height: 44px !important;
    place-items: center !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 14px !important;
    background: #fff !important;
    color: #101828 !important;
    font-size: 16px !important;
    font-weight: 850 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-pagination button.is-active {
    border-color: #0f9f68 !important;
    background: #0f9f68 !important;
    color: #fff !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-pagination button:disabled {
    color: #cbd5e1 !important;
    cursor: not-allowed !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-page-size {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 8px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-page-size strong {
    display: inline-grid !important;
    min-width: 50px !important;
    height: 42px !important;
    place-items: center !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 14px !important;
    color: #101828 !important;
  }
}

@media (min-width: 769px) and (max-width: 1800px) {
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-card {
    grid-template-columns: minmax(230px, 1.1fr) minmax(112px, .54fr) minmax(138px, .64fr) minmax(138px, .64fr) minmax(128px, .62fr) 166px 52px !important;
    gap: 14px !important;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-toolbar {
    grid-template-columns: 1fr !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-card {
    grid-template-columns: minmax(230px, 1.05fr) minmax(130px, .6fr) minmax(130px, .6fr) 154px 48px !important;
    grid-template-areas:
      "person period due actions more"
      "person amount status actions more" !important;
    min-height: 190px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-person {
    grid-area: person !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric:nth-of-type(1) {
    grid-area: period !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric:nth-of-type(2) {
    grid-area: due !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric:nth-of-type(3) {
    grid-area: amount !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-status {
    grid-area: status !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-actions {
    grid-area: actions !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-more {
    grid-area: more !important;
  }
}

/* Activity history safety fence: reference timeline only on expanded desktop. */
@media (max-width: 1399px) {
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history > .save-confirm-panel.save-confirm-panel {
    width: min(820px, calc(100vw - 32px)) !important;
    min-width: 0 !important;
    max-width: calc(100vw - 32px) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history #paymentInfoContent {
    display: block !important;
    padding: 18px 20px 22px !important;
    overflow: auto !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    min-height: 0 !important;
    margin: 0 0 14px !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta div,
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta em {
    display: inline-flex !important;
    width: auto !important;
    min-height: 32px !important;
    align-items: center !important;
    gap: 8px !important;
    padding: 0 12px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 999px !important;
    background: #fff !important;
    color: #64748b !important;
    font-size: 14px !important;
    font-weight: 800 !important;
    white-space: nowrap !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta em {
    border-color: #bbf7d0 !important;
    background: #dcfce7 !important;
    color: #047857 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid {
    display: flex !important;
    flex-wrap: nowrap !important;
    gap: 8px !important;
    margin: 0 0 12px !important;
    overflow-x: auto !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid button {
    flex: 0 0 auto !important;
    min-width: 118px !important;
    min-height: 42px !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    gap: 8px !important;
    padding: 8px 10px !important;
    border-radius: 13px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid i {
    display: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row {
    display: grid !important;
    grid-template-columns: 1fr !important;
    width: 100% !important;
    margin: 0 0 14px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row button {
    display: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row label {
    display: grid !important;
    grid-template-columns: 20px minmax(0, 1fr) !important;
    width: 100% !important;
    min-height: 46px !important;
    align-items: center !important;
    gap: 8px !important;
    padding: 0 14px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 14px !important;
    background: #fff !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-list {
    position: relative !important;
    display: grid !important;
    gap: 12px !important;
    margin: 0 !important;
    padding-left: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-list::before,
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item::before,
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-time,
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-actor,
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-arrow {
    display: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item {
    min-height: 0 !important;
    display: grid !important;
    grid-template-columns: 44px minmax(0, 1fr) !important;
    grid-template-areas:
      "icon head"
      "icon detail"
      "meta meta" !important;
    gap: 9px 12px !important;
    padding: 16px !important;
    border: 1px solid #e0e8f2 !important;
    border-radius: 18px !important;
    background: #fff !important;
    box-shadow: 0 10px 22px rgba(15, 23, 42, .045) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-type-icon {
    position: static !important;
    grid-area: icon !important;
    display: grid !important;
    width: 44px !important;
    height: 44px !important;
    place-items: center !important;
    border-radius: 15px !important;
    background: #fff7ed !important;
    color: #f97316 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-head {
    grid-area: head !important;
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    min-width: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-head strong {
    font-size: 18px !important;
    line-height: 1.15 !important;
    white-space: normal !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item p {
    grid-area: detail !important;
    margin: 0 !important;
    overflow-wrap: anywhere !important;
    font-size: 15px !important;
    line-height: 1.4 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-meta {
    grid-area: meta !important;
    display: grid !important;
    gap: 8px !important;
    padding-left: 56px !important;
  }
}

@media (max-width: 768px) {
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history > .save-confirm-panel.save-confirm-panel {
    width: min(100%, 560px) !important;
    max-width: calc(100vw - 24px) !important;
    max-height: calc(100vh - 24px) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .panel-title.panel-title {
    padding: 22px 22px 16px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .panel-title.panel-title h2 {
    font-size: clamp(26px, 7vw, 34px) !important;
    line-height: 1.08 !important;
  }
}

@media (min-width: 1400px) {
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history > .save-confirm-panel.save-confirm-panel {
    width: min(1480px, calc(100vw - 36px)) !important;
    max-width: none !important;
  }
}


@media (min-width: 1400px) {
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history:not(.hidden) {
    display: grid !important;
    place-items: center !important;
    padding: 18px !important;
    background: rgba(15, 23, 42, .34) !important;
    backdrop-filter: blur(8px) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history > .save-confirm-panel.save-confirm-panel {
    width: min(1480px, calc(100vw - 36px)) !important;
    max-width: none !important;
    min-width: min(980px, calc(100vw - 36px)) !important;
    max-height: min(92vh, 980px) !important;
    border-radius: 24px !important;
    background: #f8fafc !important;
    overflow: hidden !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .panel-title.panel-title {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 64px !important;
    gap: 18px !important;
    padding: 34px 44px 24px !important;
    border-bottom: 1px solid #e5edf6 !important;
    background: #fff !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .panel-title.panel-title h2 {
    max-width: none !important;
    margin: 0 !important;
    color: #0f172a !important;
    font-size: clamp(36px, 2.7vw, 52px) !important;
    font-weight: 900 !important;
    line-height: 1.04 !important;
    letter-spacing: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .panel-title.panel-title p {
    max-width: none !important;
    margin: 8px 0 0 !important;
    color: #64748b !important;
    font-size: 20px !important;
    font-weight: 680 !important;
    line-height: 1.25 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .customer-profile-modal-close {
    width: 64px !important;
    height: 64px !important;
    border-radius: 999px !important;
    background: #f1f5f9 !important;
    color: #0f172a !important;
    font-size: 38px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history #paymentInfoContent {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    gap: 26px 28px !important;
    padding: 28px 30px 34px !important;
    background: #fff !important;
    overflow: auto !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta {
    grid-column: 1 / -1 !important;
    display: flex !important;
    align-items: center !important;
    flex-wrap: nowrap !important;
    gap: 0 !important;
    min-height: 88px !important;
    margin: 0 !important;
    padding: 0 28px !important;
    border: 1px solid #dfe7f1 !important;
    border-radius: 14px !important;
    background: #fff !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta div,
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta em {
    display: inline-flex !important;
    align-items: center !important;
    gap: 14px !important;
    min-width: 0 !important;
    min-height: 0 !important;
    padding: 0 28px !important;
    border: 0 !important;
    border-right: 1px solid #e5edf6 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #0f172a !important;
    font-size: 20px !important;
    font-style: normal !important;
    font-weight: 850 !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta div:first-child {
    padding-left: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta em {
    margin-left: 28px !important;
    padding: 8px 16px !important;
    border: 1px solid #bbf7d0 !important;
    border-radius: 8px !important;
    background: #ecfdf5 !important;
    color: #047857 !important;
    font-size: 18px !important;
    font-weight: 850 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta span {
    display: inline-grid !important;
    width: 26px !important;
    height: 26px !important;
    place-items: center !important;
    color: #475569 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history svg {
    width: 24px !important;
    height: 24px !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid {
    grid-column: 1 !important;
    display: flex !important;
    align-items: center !important;
    gap: 16px !important;
    margin: 0 !important;
    overflow: visible !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid button {
    min-width: 0 !important;
    min-height: 72px !important;
    display: grid !important;
    grid-template-columns: 32px minmax(0, auto) auto !important;
    align-items: center !important;
    gap: 16px !important;
    padding: 0 28px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 12px !important;
    background: #fff !important;
    color: #475569 !important;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .035) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid button.is-active {
    border-color: #22c55e !important;
    background: #ecfdf5 !important;
    color: #059669 !important;
    box-shadow: inset 0 0 0 1px #22c55e, 0 12px 28px rgba(5, 150, 105, .08) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid i {
    display: grid !important;
    width: 30px !important;
    height: 30px !important;
    place-items: center !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid span {
    color: currentColor !important;
    font-size: 20px !important;
    font-weight: 850 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid strong {
    display: inline-grid !important;
    min-width: 32px !important;
    height: 32px !important;
    place-items: center !important;
    padding: 0 9px !important;
    border-radius: 999px !important;
    background: #eef2f7 !important;
    color: currentColor !important;
    font-size: 18px !important;
    font-weight: 900 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row {
    grid-column: 2 !important;
    display: grid !important;
    grid-template-columns: auto auto minmax(290px, 1fr) !important;
    align-items: center !important;
    gap: 16px !important;
    width: auto !important;
    margin: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row button,
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row label {
    min-height: 60px !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 14px !important;
    padding: 0 24px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 10px !important;
    background: #fff !important;
    color: #475569 !important;
    box-shadow: 0 10px 22px rgba(15, 23, 42, .035) !important;
    font-size: 18px !important;
    font-weight: 800 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row label {
    min-width: 330px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row input {
    min-width: 0 !important;
    border: 0 !important;
    outline: 0 !important;
    background: transparent !important;
    color: #0f172a !important;
    font: inherit !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-list {
    grid-column: 1 / -1 !important;
    position: relative !important;
    display: grid !important;
    gap: 22px !important;
    margin: 8px 0 0 !important;
    padding-left: 230px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-list::before {
    content: "" !important;
    position: absolute !important;
    left: 170px !important;
    top: 0 !important;
    bottom: 0 !important;
    width: 2px !important;
    border-radius: 999px !important;
    background: #dbe3ee !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item {
    position: relative !important;
    min-height: 158px !important;
    display: grid !important;
    grid-template-columns: 78px minmax(0, 1fr) 300px 44px !important;
    grid-template-areas:
      "icon head actor arrow"
      "icon detail actor arrow" !important;
    align-items: center !important;
    gap: 8px 28px !important;
    padding: 28px 28px !important;
    border: 1px solid #e0e8f2 !important;
    border-radius: 18px !important;
    background: #fff !important;
    box-shadow: 0 14px 36px rgba(15, 23, 42, .045) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item::before {
    content: "" !important;
    position: absolute !important;
    left: -67px !important;
    top: 50% !important;
    width: 18px !important;
    height: 18px !important;
    transform: translate(-50%, -50%) !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: #f97316 !important;
    box-shadow: 0 0 0 5px #ffedd5 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-time {
    position: absolute !important;
    left: -230px !important;
    top: 50% !important;
    width: 140px !important;
    display: grid !important;
    gap: 8px !important;
    transform: translateY(-50%) !important;
    color: #0f172a !important;
    text-align: right !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-time strong {
    font-size: 22px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-time span {
    color: #64748b !important;
    font-size: 19px !important;
    font-weight: 650 !important;
    line-height: 1 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-type-icon {
    position: static !important;
    grid-area: icon !important;
    display: grid !important;
    width: 76px !important;
    height: 76px !important;
    place-items: center !important;
    border-radius: 999px !important;
    background: #fff7ed !important;
    color: #f97316 !important;
    pointer-events: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-type-icon svg {
    width: 36px !important;
    height: 36px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-head {
    grid-area: head !important;
    display: flex !important;
    min-width: 0 !important;
    align-items: center !important;
    gap: 16px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-head strong {
    color: #0f172a !important;
    font-size: 28px !important;
    font-weight: 900 !important;
    line-height: 1.08 !important;
    white-space: nowrap !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-head em {
    display: inline-flex !important;
    align-items: center !important;
    min-height: 34px !important;
    padding: 0 16px !important;
    border-radius: 999px !important;
    background: #fff7ed !important;
    color: #f97316 !important;
    font-size: 18px !important;
    font-style: normal !important;
    font-weight: 850 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item p {
    grid-area: detail !important;
    max-width: none !important;
    margin: 0 !important;
    color: #0f172a !important;
    font-size: 21px !important;
    font-weight: 750 !important;
    line-height: 1.38 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-actor {
    grid-area: actor !important;
    display: grid !important;
    grid-template-columns: 40px minmax(0, 1fr) !important;
    grid-template-areas:
      "icon name"
      "icon role" !important;
    align-items: center !important;
    gap: 4px 14px !important;
    min-height: 92px !important;
    padding-left: 34px !important;
    border-left: 1px solid #e5edf6 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-actor span {
    grid-area: icon !important;
    color: #475569 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-actor b {
    grid-area: name !important;
    color: #0f172a !important;
    font-size: 21px !important;
    font-weight: 900 !important;
    line-height: 1.15 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-actor em {
    grid-area: role !important;
    color: #64748b !important;
    font-size: 18px !important;
    font-style: normal !important;
    font-weight: 680 !important;
    line-height: 1.15 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-arrow {
    grid-area: arrow !important;
    color: #0f172a !important;
    font-size: 36px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    text-align: center !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-meta {
    display: none !important;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history > .save-confirm-panel.save-confirm-panel {
    width: min(940px, calc(100vw - 28px)) !important;
    min-width: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history #paymentInfoContent {
    grid-template-columns: 1fr !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row {
    grid-column: 1 !important;
    grid-template-columns: auto auto minmax(220px, 1fr) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-list {
    padding-left: 170px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-list::before {
    left: 126px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-time {
    left: -170px !important;
    width: 104px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item {
    grid-template-columns: 64px minmax(0, 1fr) 220px 32px !important;
    gap: 8px 18px !important;
  }
}

/* Desktop activity history: final wide modal repair, kept after all older activity rules. */
@media (min-width: 769px) {
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history:not(.hidden) {
    display: grid !important;
    place-items: center !important;
    padding: 28px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history > .save-confirm-panel.save-confirm-panel {
    width: min(1120px, calc(100vw - 56px)) !important;
    max-width: none !important;
    min-width: min(860px, calc(100vw - 56px)) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .panel-title.panel-title h2 {
    max-width: 760px !important;
    font-size: clamp(28px, 2.1vw, 38px) !important;
    line-height: 1.1 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row.activity-history-search-row {
    width: min(540px, 100%) !important;
    margin: -72px 0 24px auto !important;
    grid-template-columns: auto auto minmax(260px, 1fr) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item.activity-log-item {
    min-height: 116px !important;
    grid-template-columns: minmax(0, 1fr) 260px 28px !important;
    grid-template-areas:
      "head meta arrow"
      "detail meta arrow" !important;
    gap: 8px 22px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-list.activity-log-list {
    padding-left: 58px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-list.activity-log-list::before {
    left: 23px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item.activity-log-item::before {
    left: -53px !important;
    top: 35px !important;
    width: 36px !important;
    height: 36px !important;
    border-width: 2px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-type-icon.activity-log-type-icon {
    left: -44px !important;
    top: 44px !important;
    width: 18px !important;
    height: 18px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history:not(.hidden) {
    position: fixed !important;
    inset: 0 !important;
    z-index: 2147483400 !important;
    display: grid !important;
    place-items: center !important;
    padding: 28px !important;
    background: rgba(15, 23, 42, .38) !important;
    backdrop-filter: blur(9px) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history > .save-confirm-panel {
    width: min(1120px, calc(100vw - 56px)) !important;
    max-width: none !important;
    min-width: min(860px, calc(100vw - 56px)) !important;
    max-height: min(90vh, 940px) !important;
    display: grid !important;
    grid-template-rows: auto minmax(0, 1fr) auto !important;
    overflow: hidden !important;
    padding: 0 !important;
    border: 1px solid #dfe7f1 !important;
    border-radius: 24px !important;
    background: #f8fafc !important;
    box-shadow: 0 30px 90px rgba(15, 23, 42, .26) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 52px !important;
    align-items: start !important;
    gap: 18px !important;
    padding: 28px 36px 22px !important;
    border-bottom: 1px solid #e8eef6 !important;
    background: #fff !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title h2 {
    max-width: 760px !important;
    margin: 0 !important;
    color: #0f172a !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: clamp(28px, 2.1vw, 38px) !important;
    font-weight: 900 !important;
    letter-spacing: 0 !important;
    line-height: 1.1 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title p {
    max-width: 700px !important;
    margin: 7px 0 0 !important;
    color: #64748b !important;
    font-size: 16px !important;
    font-weight: 750 !important;
    line-height: 1.35 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .customer-profile-modal-close {
    width: 52px !important;
    height: 52px !important;
    display: grid !important;
    place-items: center !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: #eef2f7 !important;
    color: #0f172a !important;
    font-size: 30px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history #paymentInfoContent {
    min-height: 0 !important;
    overflow: auto !important;
    padding: 24px 36px 34px !important;
    background: #f8fafc !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-contract-meta {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    gap: 10px 20px !important;
    margin: -8px 0 20px !important;
    padding: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-filter-grid {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 10px !important;
    margin: 0 0 18px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-filter-grid button {
    width: auto !important;
    min-width: 138px !important;
    min-height: 54px !important;
    display: grid !important;
    grid-template-columns: 28px minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 10px !important;
    padding: 10px 14px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 14px !important;
    background: #fff !important;
    color: #64748b !important;
    box-shadow: 0 8px 18px rgba(15, 23, 42, .04) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row {
    display: grid !important;
    grid-template-columns: auto auto minmax(260px, 1fr) !important;
    gap: 10px !important;
    width: min(540px, 100%) !important;
    margin: -72px 0 24px auto !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-list {
    position: relative !important;
    display: grid !important;
    gap: 18px !important;
    padding-left: 70px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-list::before {
    content: "" !important;
    position: absolute !important;
    left: 29px !important;
    top: 16px !important;
    bottom: 16px !important;
    width: 2px !important;
    border-radius: 999px !important;
    background: #d8e1ec !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item {
    position: relative !important;
    min-height: 116px !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 260px 28px !important;
    grid-template-areas:
      "head meta arrow"
      "detail meta arrow" !important;
    align-items: center !important;
    gap: 8px 22px !important;
    padding: 22px 24px !important;
    border: 1px solid #dfe8f3 !important;
    border-radius: 18px !important;
    background: #fff !important;
    box-shadow: 0 12px 28px rgba(15, 23, 42, .05) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item p {
    grid-area: detail !important;
    max-width: 620px !important;
    margin: 0 !important;
    overflow-wrap: anywhere !important;
    color: #172033 !important;
    font-size: 16px !important;
    font-weight: 760 !important;
    line-height: 1.45 !important;
  }
}

/* Activity history modal: mobile-runtime repair, scoped only to this modal. */
@media (max-width: 768px) {
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history:not(.hidden) {
    position: fixed !important;
    inset: 0 !important;
    z-index: 2147483400 !important;
    display: grid !important;
    place-items: center !important;
    padding: 12px !important;
    background: rgba(15, 23, 42, .40) !important;
    backdrop-filter: blur(8px) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history > .save-confirm-panel.save-confirm-panel {
    width: min(100%, 560px) !important;
    max-width: calc(100vw - 24px) !important;
    min-width: 0 !important;
    max-height: calc(100vh - 24px) !important;
    display: grid !important;
    grid-template-rows: auto minmax(0, 1fr) auto !important;
    overflow: hidden !important;
    padding: 0 !important;
    border-radius: 22px !important;
    background: #f8fafc !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .panel-title.panel-title {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 46px !important;
    align-items: start !important;
    gap: 12px !important;
    padding: 22px 22px 16px !important;
    border-bottom: 1px solid #e8eef6 !important;
    background: #fff !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .panel-title.panel-title h2 {
    max-width: 100% !important;
    margin: 0 !important;
    color: #0f172a !important;
    font-size: clamp(26px, 7vw, 34px) !important;
    font-weight: 900 !important;
    line-height: 1.08 !important;
    letter-spacing: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .panel-title.panel-title p {
    max-width: 100% !important;
    margin: 8px 0 0 !important;
    color: #64748b !important;
    font-size: 14px !important;
    font-weight: 750 !important;
    line-height: 1.35 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .customer-profile-modal-close {
    width: 46px !important;
    height: 46px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 999px !important;
    background: #eef2f7 !important;
    color: #0f172a !important;
    font-size: 26px !important;
    font-weight: 900 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history #paymentInfoContent {
    min-height: 0 !important;
    overflow: auto !important;
    padding: 16px 14px 18px !important;
    background: #f8fafc !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 8px !important;
    margin: 0 0 14px !important;
    padding: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta div,
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta em {
    min-width: 0 !important;
    font-size: 13px !important;
    line-height: 1.25 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid {
    display: flex !important;
    gap: 8px !important;
    margin: 0 0 12px !important;
    padding: 0 0 3px !important;
    overflow-x: auto !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid button {
    flex: 0 0 auto !important;
    min-width: 118px !important;
    min-height: 44px !important;
    display: grid !important;
    grid-template-columns: 22px minmax(0, 1fr) auto !important;
    gap: 8px !important;
    padding: 8px 10px !important;
    border-radius: 13px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid span {
    font-size: 13px !important;
    white-space: nowrap !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
    width: 100% !important;
    margin: 0 0 14px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row label {
    grid-column: 1 / -1 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row button,
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row label {
    min-height: 44px !important;
    padding: 0 12px !important;
    border-radius: 13px !important;
    font-size: 13px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-list {
    display: grid !important;
    gap: 12px !important;
    padding-left: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-list::before {
    display: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item {
    position: relative !important;
    min-height: 0 !important;
    display: grid !important;
    grid-template-columns: 42px minmax(0, 1fr) !important;
    grid-template-areas:
      "icon head"
      "icon detail"
      "meta meta" !important;
    gap: 8px 12px !important;
    padding: 14px !important;
    border-radius: 17px !important;
    background: #fff !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item::before,
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item::after {
    display: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-type-icon {
    position: static !important;
    grid-area: icon !important;
    display: grid !important;
    width: 42px !important;
    height: 42px !important;
    place-items: center !important;
    border-radius: 15px !important;
    background: #fff7ed !important;
    color: #f97316 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-head {
    grid-area: head !important;
    display: flex !important;
    min-width: 0 !important;
    align-items: center !important;
    gap: 8px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-head strong {
    min-width: 0 !important;
    font-size: 18px !important;
    line-height: 1.12 !important;
    white-space: normal !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item p {
    grid-area: detail !important;
    min-width: 0 !important;
    margin: 0 !important;
    overflow-wrap: anywhere !important;
    font-size: 15px !important;
    font-weight: 760 !important;
    line-height: 1.38 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-meta {
    grid-area: meta !important;
    display: grid !important;
    gap: 8px !important;
    padding-left: 54px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history svg {
    width: 18px !important;
    height: 18px !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta span {
    display: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta div,
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta em {
    display: inline-flex !important;
    width: fit-content !important;
    max-width: 100% !important;
    align-items: center !important;
    padding: 6px 10px !important;
    border-radius: 999px !important;
    background: #fff !important;
    color: #64748b !important;
    box-shadow: inset 0 0 0 1px #e2e8f0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-contract-meta em {
    background: #dcfce7 !important;
    color: #047857 !important;
    box-shadow: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    overflow: visible !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid button {
    min-width: 0 !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    min-height: 40px !important;
    padding: 8px 9px !important;
    background: #fff !important;
    color: #64748b !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid button.is-active {
    border-color: #10b981 !important;
    background: #ecfdf5 !important;
    color: #047857 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid i {
    display: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid span {
    min-width: 0 !important;
    overflow: hidden !important;
    color: currentColor !important;
    font-size: 12px !important;
    font-weight: 850 !important;
    text-overflow: ellipsis !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-filter-grid strong {
    display: inline-grid !important;
    min-width: 22px !important;
    height: 22px !important;
    place-items: center !important;
    border-radius: 999px !important;
    background: #eef2f7 !important;
    color: currentColor !important;
    font-size: 12px !important;
    font-weight: 900 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row {
    grid-template-columns: 1fr !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row button {
    display: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row label {
    grid-column: auto !important;
    display: grid !important;
    grid-template-columns: 20px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 8px !important;
    background: #fff !important;
    box-shadow: inset 0 0 0 1px #e2e8f0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row input {
    min-width: 0 !important;
    border: 0 !important;
    outline: 0 !important;
    background: transparent !important;
    color: #0f172a !important;
    font: inherit !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-head em {
    display: inline-flex !important;
    align-items: center !important;
    min-height: 24px !important;
    padding: 0 9px !important;
    border-radius: 999px !important;
    background: #fff7ed !important;
    color: #f97316 !important;
    font-size: 12px !important;
    font-style: normal !important;
    font-weight: 900 !important;
    white-space: nowrap !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-meta span,
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-meta small {
    display: grid !important;
    grid-template-columns: 18px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 8px !important;
    color: #64748b !important;
    font-size: 13px !important;
    font-weight: 760 !important;
    line-height: 1.25 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-meta small b {
    color: #0f172a !important;
    font-weight: 850 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-meta small em {
    color: #64748b !important;
    font-style: normal !important;
    font-weight: 700 !important;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history > .save-confirm-panel.save-confirm-panel {
    width: min(900px, calc(100vw - 36px)) !important;
    min-width: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .panel-title.panel-title h2 {
    max-width: 620px !important;
    font-size: clamp(25px, 3.1vw, 32px) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-history-search-row.activity-history-search-row {
    width: 100% !important;
    margin: 0 0 18px !important;
    grid-template-columns: auto auto minmax(180px, 1fr) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-list.activity-log-list {
    padding-left: 54px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item.activity-log-item {
    min-height: 0 !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "head"
      "detail"
      "meta" !important;
    gap: 10px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal#paymentInfoModal.is-activity-history .activity-log-item.activity-log-item::after {
    display: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history > .save-confirm-panel {
    width: min(900px, calc(100vw - 36px)) !important;
    min-width: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title {
    padding: 24px 28px 18px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title h2 {
    max-width: 620px !important;
    font-size: clamp(25px, 3.1vw, 32px) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row {
    width: 100% !important;
    margin: 0 0 18px !important;
    grid-template-columns: auto auto minmax(180px, 1fr) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-list {
    padding-left: 54px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-list::before {
    left: 22px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item {
    min-height: 0 !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "head"
      "detail"
      "meta" !important;
    gap: 10px !important;
    padding: 20px 22px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item::after {
    display: none !important;
  }
}

/* Desktop activity history: repair narrow/zoomed desktop modal layout. */
@media (min-width: 769px) {
  html body:not(.auth-locked) #paymentInfoModal.is-activity-history > .save-confirm-panel {
    width: min(1120px, calc(100vw - 48px)) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title h2 {
    max-width: 760px !important;
    font-size: clamp(28px, 2.05vw, 38px) !important;
    line-height: 1.12 !important;
    text-wrap: balance !important;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  html body:not(.auth-locked) #paymentInfoModal.is-activity-history {
    padding: 18px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history > .save-confirm-panel {
    width: min(820px, calc(100vw - 36px)) !important;
    max-height: min(90vh, 900px) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title {
    grid-template-columns: minmax(0, 1fr) 46px !important;
    padding: 22px 24px 16px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title h2 {
    max-width: 100% !important;
    font-size: clamp(24px, 4.2vw, 34px) !important;
    line-height: 1.12 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title p {
    font-size: 14px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .customer-profile-modal-close {
    width: 46px !important;
    height: 46px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history #paymentInfoContent {
    padding: 18px 22px 24px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-contract-meta {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
    margin: 0 0 16px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-contract-meta div,
  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-contract-meta em {
    min-width: 0 !important;
    justify-content: flex-start !important;
    font-size: 13px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-filter-grid {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    padding-bottom: 4px !important;
    margin: 0 0 12px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-filter-grid button {
    flex: 0 0 auto !important;
    min-width: 128px !important;
    min-height: 48px !important;
    padding: 9px 12px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row {
    width: 100% !important;
    margin: 0 0 18px !important;
    grid-template-columns: auto auto minmax(180px, 1fr) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row button,
  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row label {
    min-height: 44px !important;
    border-radius: 12px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-list {
    gap: 14px !important;
    padding-left: 54px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-list::before {
    left: 24px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item {
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "head"
      "detail"
      "meta" !important;
    min-height: 0 !important;
    gap: 10px !important;
    padding: 18px 18px 16px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item::before {
    left: -55px !important;
    top: 18px !important;
    width: 42px !important;
    height: 42px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-type-icon {
    left: -45px !important;
    top: 28px !important;
    width: 22px !important;
    height: 22px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-head {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-head strong {
    font-size: 18px !important;
    line-height: 1.18 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item p {
    max-width: none !important;
    font-size: 15px !important;
    overflow-wrap: anywhere !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-meta {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 8px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item::after {
    display: none !important;
  }
}

/* Desktop postpone: open as a centered modal, isolated from mobile sheet styles. */
@media (min-width: 769px) {
  html body.postpone-sheet-open {
    overflow: hidden !important;
  }

  html body:not(.auth-locked) .postpone-sheet.hidden {
    display: none !important;
  }

  html body:not(.auth-locked) .postpone-sheet:not(.hidden) {
    position: fixed !important;
    inset: 0 !important;
    z-index: 2147483400 !important;
    display: grid !important;
    place-items: center !important;
    padding: 28px !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  html body:not(.auth-locked) .postpone-backdrop {
    position: absolute !important;
    inset: 0 !important;
    background: rgba(15, 23, 42, .28) !important;
    backdrop-filter: blur(6px) !important;
  }

  html body:not(.auth-locked) .postpone-panel {
    position: relative !important;
    z-index: 1 !important;
    width: min(780px, calc(100vw - 72px)) !important;
    max-height: min(86vh, 860px) !important;
    overflow: hidden !important;
    border: 1px solid #dfe8f3 !important;
    border-radius: 24px !important;
    background: #fff !important;
    box-shadow: 0 28px 80px rgba(15, 23, 42, .22) !important;
  }

  html body:not(.auth-locked) #postponeContent {
    max-height: inherit !important;
    display: grid !important;
    gap: 16px !important;
    overflow: auto !important;
    padding: 22px 24px 24px !important;
  }

  html body:not(.auth-locked) .postpone-handle {
    display: none !important;
  }

  html body:not(.auth-locked) .postpone-head {
    display: grid !important;
    grid-template-columns: 40px minmax(0, 1fr) 40px !important;
    align-items: center !important;
    gap: 12px !important;
    margin: 0 !important;
  }

  html body:not(.auth-locked) .postpone-head h2 {
    margin: 0 !important;
    color: #0f172a !important;
    font-size: 28px !important;
    font-weight: 900 !important;
    line-height: 1.05 !important;
  }

  html body:not(.auth-locked) .postpone-head p {
    margin: 5px 0 0 !important;
    color: #64748b !important;
    font-size: 14px !important;
    font-weight: 650 !important;
    line-height: 1.35 !important;
  }

  html body:not(.auth-locked) .postpone-close,
  html body:not(.auth-locked) .postpone-back,
  html body:not(.auth-locked) .postpone-spacer {
    width: 40px !important;
    height: 40px !important;
  }

  html body:not(.auth-locked) .postpone-close,
  html body:not(.auth-locked) .postpone-back {
    display: grid !important;
    place-items: center !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 12px !important;
    background: #fff !important;
    color: #334155 !important;
    font-size: 24px !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    cursor: pointer !important;
  }

  html body:not(.auth-locked) .postpone-steps {
    display: grid !important;
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    gap: 8px !important;
    padding: 8px !important;
    border-radius: 18px !important;
    background: #f8fafc !important;
  }

  html body:not(.auth-locked) .postpone-steps span {
    display: grid !important;
    grid-template-columns: 28px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 8px !important;
    min-height: 40px !important;
    padding: 6px 8px !important;
    border-radius: 12px !important;
    color: #64748b !important;
    font-size: 12px !important;
    font-weight: 750 !important;
  }

  html body:not(.auth-locked) .postpone-steps span.is-active,
  html body:not(.auth-locked) .postpone-steps span.is-done {
    background: #ecfdf5 !important;
    color: #059669 !important;
  }

  html body:not(.auth-locked) .postpone-steps b {
    display: grid !important;
    place-items: center !important;
    width: 28px !important;
    height: 28px !important;
    border-radius: 999px !important;
    background: #fff !important;
    color: currentColor !important;
  }

  html body:not(.auth-locked) .postpone-steps small {
    overflow: hidden !important;
    color: currentColor !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body:not(.auth-locked) .postpone-step-title {
    margin: 0 !important;
    color: #0f172a !important;
    font-size: 20px !important;
    font-weight: 900 !important;
    line-height: 1.2 !important;
  }

  html body:not(.auth-locked) .postpone-card,
  html body:not(.auth-locked) .postpone-field,
  html body:not(.auth-locked) .postpone-summary,
  html body:not(.auth-locked) .postpone-calendar,
  html body:not(.auth-locked) .postpone-installment-list button,
  html body:not(.auth-locked) .postpone-option-list button {
    border: 1px solid #e3ebf5 !important;
    border-radius: 16px !important;
    background: #fff !important;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .045) !important;
  }

  html body:not(.auth-locked) .postpone-card {
    display: grid !important;
    grid-template-columns: 58px minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 14px !important;
    padding: 14px !important;
  }

  html body:not(.auth-locked) .postpone-avatar,
  html body:not(.auth-locked) .postpone-avatar img {
    width: 58px !important;
    height: 58px !important;
    border-radius: 999px !important;
  }

  html body:not(.auth-locked) .postpone-card strong,
  html body:not(.auth-locked) .postpone-field strong,
  html body:not(.auth-locked) .postpone-summary strong,
  html body:not(.auth-locked) .postpone-installment-list strong,
  html body:not(.auth-locked) .postpone-option-list strong {
    color: #0f172a !important;
    font-size: 15px !important;
    font-weight: 850 !important;
    line-height: 1.2 !important;
  }

  html body:not(.auth-locked) .postpone-card small,
  html body:not(.auth-locked) .postpone-field small,
  html body:not(.auth-locked) .postpone-summary span,
  html body:not(.auth-locked) .postpone-installment-list small {
    color: #64748b !important;
    font-size: 13px !important;
    font-weight: 650 !important;
    line-height: 1.35 !important;
  }

  html body:not(.auth-locked) .postpone-amount {
    text-align: right !important;
  }

  html body:not(.auth-locked) .postpone-amount strong {
    display: block !important;
    color: #059669 !important;
    font-size: 18px !important;
    font-weight: 900 !important;
  }

  html body:not(.auth-locked) .postpone-amount b {
    display: inline-flex !important;
    margin-top: 4px !important;
    color: #64748b !important;
    font-size: 12px !important;
    font-weight: 750 !important;
  }

  html body:not(.auth-locked) .postpone-installment-list,
  html body:not(.auth-locked) .postpone-option-list {
    display: grid !important;
    gap: 10px !important;
  }

  html body:not(.auth-locked) .postpone-installment-list button,
  html body:not(.auth-locked) .postpone-option-list button {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto auto !important;
    align-items: center !important;
    gap: 12px !important;
    min-height: 54px !important;
    padding: 12px 14px !important;
    text-align: left !important;
    cursor: pointer !important;
  }

  html body:not(.auth-locked) .postpone-installment-list button.is-selected,
  html body:not(.auth-locked) .postpone-option-list button.is-selected {
    border-color: #10b981 !important;
    background: #ecfdf5 !important;
  }

  html body:not(.auth-locked) .postpone-installment-list em {
    border-radius: 999px !important;
    padding: 6px 10px !important;
    background: #fff7ed !important;
    color: #f97316 !important;
    font-size: 12px !important;
    font-style: normal !important;
    font-weight: 850 !important;
  }

  html body:not(.auth-locked) .postpone-field {
    display: grid !important;
    gap: 6px !important;
    padding: 14px !important;
  }

  html body:not(.auth-locked) .postpone-calendar {
    padding: 14px !important;
  }

  html body:not(.auth-locked) .postpone-calendar-head,
  html body:not(.auth-locked) .postpone-weekdays,
  html body:not(.auth-locked) .postpone-days {
    display: grid !important;
    grid-template-columns: repeat(7, minmax(0, 1fr)) !important;
    gap: 6px !important;
    align-items: center !important;
  }

  html body:not(.auth-locked) .postpone-calendar-head {
    grid-template-columns: 38px minmax(0, 1fr) 38px !important;
    margin-bottom: 10px !important;
  }

  html body:not(.auth-locked) .postpone-calendar-head strong {
    text-align: center !important;
  }

  html body:not(.auth-locked) .postpone-calendar-head button,
  html body:not(.auth-locked) .postpone-days button,
  html body:not(.auth-locked) .postpone-days > span {
    min-height: 38px !important;
    border: 1px solid #e5edf6 !important;
    border-radius: 10px !important;
    background: #fff !important;
  }

  html body:not(.auth-locked) .postpone-days button.is-selected {
    border-color: #059669 !important;
    background: #059669 !important;
    color: #fff !important;
  }

  html body:not(.auth-locked) .postpone-summary {
    display: grid !important;
    padding: 6px 14px !important;
  }

  html body:not(.auth-locked) .postpone-summary-row {
    display: grid !important;
    grid-template-columns: 160px minmax(0, 1fr) !important;
    gap: 12px !important;
    padding: 10px 0 !important;
    border-bottom: 1px solid #eef2f7 !important;
  }

  html body:not(.auth-locked) .postpone-summary-row:last-child {
    border-bottom: 0 !important;
  }

  html body:not(.auth-locked) .postpone-warning {
    border-radius: 14px !important;
    padding: 12px 14px !important;
    background: #fff7ed !important;
    color: #c2410c !important;
    font-size: 13px !important;
    font-weight: 760 !important;
    line-height: 1.45 !important;
  }

  html body:not(.auth-locked) .postpone-date-input {
    width: 100% !important;
    min-height: 48px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 14px !important;
    padding: 0 14px !important;
    font-size: 15px !important;
    font-weight: 700 !important;
  }

  html body:not(.auth-locked) .postpone-actions,
  html body:not(.auth-locked) .postpone-success-actions {
    position: sticky !important;
    bottom: -24px !important;
    display: grid !important;
    grid-template-columns: 1fr 1.35fr !important;
    gap: 10px !important;
    margin: 0 -24px -24px !important;
    padding: 14px 24px 18px !important;
    border-top: 1px solid #eef2f7 !important;
    background: rgba(255, 255, 255, .96) !important;
    backdrop-filter: blur(10px) !important;
  }

  html body:not(.auth-locked) .postpone-actions button,
  html body:not(.auth-locked) .postpone-success-actions button {
    min-height: 46px !important;
    border-radius: 13px !important;
    font-size: 15px !important;
    font-weight: 850 !important;
    cursor: pointer !important;
  }

  html body:not(.auth-locked) .postpone-actions .is-secondary,
  html body:not(.auth-locked) .postpone-success-actions .is-secondary {
    border: 1px solid #dfe7f0 !important;
    background: #fff !important;
    color: #0f172a !important;
  }

  html body:not(.auth-locked) .postpone-actions .is-primary,
  html body:not(.auth-locked) .postpone-success-actions .is-primary {
    border: 0 !important;
    background: linear-gradient(135deg, #059669, #00a96b) !important;
    color: #fff !important;
    box-shadow: 0 12px 24px rgba(5, 150, 105, .20) !important;
  }
}

/* Desktop activity history: clean timeline modal, isolated from mobile. */
@media (min-width: 769px) {
  html body:not(.auth-locked) #paymentInfoModal.is-activity-history:not(.hidden) {
    position: fixed !important;
    inset: 0 !important;
    z-index: 2147483400 !important;
    display: grid !important;
    place-items: center !important;
    padding: 30px !important;
    background: rgba(15, 23, 42, .36) !important;
    backdrop-filter: blur(8px) !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history > .save-confirm-panel {
    width: min(780px, calc(100vw - 72px)) !important;
    max-height: min(88vh, 920px) !important;
    display: grid !important;
    grid-template-rows: auto minmax(0, 1fr) auto !important;
    overflow: hidden !important;
    padding: 0 !important;
    border: 1px solid #dfe7f1 !important;
    border-radius: 24px !important;
    background: #f8fafc !important;
    box-shadow: 0 30px 90px rgba(15, 23, 42, .26) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 48px !important;
    align-items: start !important;
    gap: 14px !important;
    padding: 26px 30px 16px !important;
    border-bottom: 1px solid #e8eef6 !important;
    background: linear-gradient(180deg, #fff, #f8fafc) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title h2 {
    margin: 0 !important;
    color: #0f172a !important;
    font-size: clamp(24px, 1.85vw, 34px) !important;
    font-weight: 900 !important;
    line-height: 1.08 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title p {
    margin: 7px 0 0 !important;
    color: #64748b !important;
    font-size: 14px !important;
    font-weight: 680 !important;
    line-height: 1.35 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .customer-profile-modal-close {
    width: 48px !important;
    height: 48px !important;
    display: grid !important;
    place-items: center !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: #eef2f7 !important;
    color: #0f172a !important;
    font-size: 28px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history #paymentInfoContent {
    min-height: 0 !important;
    overflow: auto !important;
    padding: 22px 28px 26px !important;
    background: #f8fafc !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-list {
    position: relative !important;
    display: grid !important;
    gap: 16px !important;
    padding-left: 18px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-filter-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 10px !important;
    margin-bottom: 18px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-filter-grid button {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    align-items: center !important;
    min-height: 58px !important;
    padding: 12px 14px !important;
    border: 1px solid #e3ebf5 !important;
    border-radius: 16px !important;
    background: rgba(255, 255, 255, .96) !important;
    color: #64748b !important;
    box-shadow: 0 8px 20px rgba(15, 23, 42, .04) !important;
    text-align: left !important;
    cursor: pointer !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-filter-grid button.is-active {
    border-color: #10b981 !important;
    background: #ecfdf5 !important;
    color: #047857 !important;
    box-shadow: 0 10px 24px rgba(5, 150, 105, .12) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-filter-grid span {
    overflow: hidden !important;
    font-size: 14px !important;
    font-weight: 850 !important;
    line-height: 1.15 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-filter-grid strong {
    display: grid !important;
    place-items: center !important;
    min-width: 34px !important;
    height: 34px !important;
    padding: 0 8px !important;
    border-radius: 999px !important;
    background: #eef2f7 !important;
    color: currentColor !important;
    font-size: 15px !important;
    font-weight: 900 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-list::before {
    content: "" !important;
    position: absolute !important;
    left: 6px !important;
    top: 16px !important;
    bottom: 16px !important;
    width: 2px !important;
    border-radius: 999px !important;
    background: #dbe7f2 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item {
    position: relative !important;
    display: grid !important;
    gap: 13px !important;
    padding: 20px 22px 20px 24px !important;
    border: 1px solid #dfe8f3 !important;
    border-radius: 20px !important;
    background: rgba(255, 255, 255, .96) !important;
    box-shadow: 0 14px 32px rgba(15, 23, 42, .055) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item::before {
    content: "" !important;
    position: absolute !important;
    left: -18px !important;
    top: 28px !important;
    width: 14px !important;
    height: 14px !important;
    border: 3px solid #f8fafc !important;
    border-radius: 999px !important;
    background: #10b981 !important;
    box-shadow: 0 0 0 1px #a7f3d0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item.is-postpone::before {
    background: #f97316 !important;
    box-shadow: 0 0 0 1px #fed7aa !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item.is-payment::before {
    background: #2563eb !important;
    box-shadow: 0 0 0 1px #bfdbfe !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item.is-edit::before {
    background: #7c3aed !important;
    box-shadow: 0 0 0 1px #ddd6fe !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item.is-contract::before {
    background: #0f172a !important;
    box-shadow: 0 0 0 1px #cbd5e1 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-head {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    align-items: start !important;
    gap: 12px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-head strong {
    color: #0f172a !important;
    font-size: 18px !important;
    font-weight: 900 !important;
    line-height: 1.18 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-head span {
    color: #64748b !important;
    font-size: 13px !important;
    font-weight: 720 !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item p {
    margin: 0 !important;
    color: #172033 !important;
    font-size: 17px !important;
    font-weight: 760 !important;
    line-height: 1.45 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item small {
    color: #64748b !important;
    font-size: 14px !important;
    font-weight: 760 !important;
    line-height: 1.3 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .confirm-actions {
    display: none !important;
  }
}

/* Desktop activity history: reference-style contract timeline. */
@media (min-width: 769px) {
  html body:not(.auth-locked) #paymentInfoModal.is-activity-history > .save-confirm-panel {
    width: min(1120px, calc(100vw - 92px)) !important;
    max-height: min(90vh, 940px) !important;
    border-radius: 24px !important;
    background: #f8fafc !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title {
    grid-template-columns: minmax(0, 1fr) 52px !important;
    padding: 28px 34px 22px !important;
    background: #fff !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title h2 {
    font-size: clamp(30px, 2.3vw, 42px) !important;
    letter-spacing: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .panel-title p {
    max-width: 680px !important;
    font-size: 16px !important;
    font-weight: 750 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .customer-profile-modal-close {
    width: 52px !important;
    height: 52px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history #paymentInfoContent {
    padding: 22px 34px 34px !important;
    background: #f8fafc !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-contract-meta {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    gap: 10px 20px !important;
    margin: -8px 0 22px !important;
    padding: 0 2px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-contract-meta div {
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    color: #64748b !important;
    font-size: 15px !important;
    font-weight: 820 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-contract-meta svg {
    width: 18px !important;
    height: 18px !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-contract-meta em {
    display: inline-flex !important;
    align-items: center !important;
    min-height: 32px !important;
    padding: 0 14px !important;
    border-radius: 999px !important;
    background: #dcfce7 !important;
    color: #047857 !important;
    font-size: 14px !important;
    font-style: normal !important;
    font-weight: 900 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-contract-meta em.is-closed {
    background: #eef2f7 !important;
    color: #475569 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-filter-grid {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 10px !important;
    margin: 0 0 18px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-filter-grid button {
    width: auto !important;
    min-width: 142px !important;
    min-height: 54px !important;
    grid-template-columns: 28px minmax(0, 1fr) auto !important;
    gap: 10px !important;
    padding: 10px 14px !important;
    border-radius: 14px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-filter-grid i,
  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row button svg,
  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row label svg {
    display: grid !important;
    place-items: center !important;
    width: 24px !important;
    height: 24px !important;
    color: currentColor !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-filter-grid svg,
  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row svg,
  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-type-icon svg {
    width: 100% !important;
    height: 100% !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-icon.is-history svg {
    width: 24px !important;
    height: 24px !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row {
    display: grid !important;
    grid-template-columns: auto auto minmax(280px, 1fr) !important;
    gap: 10px !important;
    margin: -72px 0 24px auto !important;
    width: min(540px, 100%) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row button,
  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row label {
    min-height: 48px !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 10px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 13px !important;
    background: #fff !important;
    color: #334155 !important;
    box-shadow: 0 8px 18px rgba(15, 23, 42, .035) !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row button {
    padding: 0 14px !important;
    font-size: 14px !important;
    font-weight: 850 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row label {
    padding: 0 14px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-history-search-row input {
    width: 100% !important;
    border: 0 !important;
    outline: 0 !important;
    background: transparent !important;
    color: #0f172a !important;
    font-family: inherit !important;
    font-size: 15px !important;
    font-weight: 760 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-list {
    gap: 22px !important;
    padding-left: 72px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-list::before {
    left: 30px !important;
    top: 16px !important;
    bottom: 16px !important;
    width: 2px !important;
    background: #d8e1ec !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item {
    min-height: 118px !important;
    grid-template-columns: minmax(0, 1fr) 260px 32px !important;
    grid-template-areas:
      "head meta arrow"
      "detail meta arrow" !important;
    align-items: center !important;
    gap: 8px 24px !important;
    padding: 22px 24px !important;
    border-radius: 18px !important;
    background: #fff !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item::before {
    left: -73px !important;
    top: 24px !important;
    width: 48px !important;
    height: 48px !important;
    border: 2px solid #fed7aa !important;
    background: #fff7ed !important;
    box-shadow: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-type-icon {
    position: absolute !important;
    left: -62px !important;
    top: 35px !important;
    z-index: 1 !important;
    display: grid !important;
    place-items: center !important;
    width: 26px !important;
    height: 26px !important;
    color: #f97316 !important;
    pointer-events: none !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item.is-payment::before {
    border-color: #bbf7d0 !important;
    background: #dcfce7 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item.is-payment .activity-log-type-icon {
    color: #16a34a !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item.is-edit::before {
    border-color: #bfdbfe !important;
    background: #dbeafe !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item.is-edit .activity-log-type-icon {
    color: #2563eb !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item.is-contract::before {
    border-color: #ddd6fe !important;
    background: #ede9fe !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item.is-contract .activity-log-type-icon {
    color: #7c3aed !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-head {
    grid-area: head !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 12px !important;
    min-width: 0 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-head strong {
    font-size: 20px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-head em {
    display: inline-flex !important;
    min-height: 26px !important;
    align-items: center !important;
    padding: 0 10px !important;
    border-radius: 999px !important;
    background: #fff7ed !important;
    color: #f97316 !important;
    font-size: 12px !important;
    font-style: normal !important;
    font-weight: 900 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item.is-payment .activity-log-head em {
    background: #dcfce7 !important;
    color: #16a34a !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item.is-edit .activity-log-head em {
    background: #dbeafe !important;
    color: #2563eb !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item.is-contract .activity-log-head em {
    background: #ede9fe !important;
    color: #7c3aed !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-meta {
    grid-area: meta !important;
    display: grid !important;
    gap: 14px !important;
    align-self: center !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-meta span,
  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-meta small {
    display: grid !important;
    grid-template-columns: 22px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 10px !important;
    color: #64748b !important;
    font-size: 14px !important;
    font-weight: 780 !important;
    line-height: 1.2 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-meta svg {
    width: 18px !important;
    height: 18px !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-meta small {
    grid-template-columns: 34px minmax(0, 1fr) !important;
    grid-template-areas:
      "icon name"
      "icon role" !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-meta small svg {
    grid-area: icon !important;
    width: 34px !important;
    height: 34px !important;
    padding: 7px !important;
    border-radius: 999px !important;
    background: #eef2f7 !important;
    color: #475569 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-meta small b {
    grid-area: name !important;
    color: #0f172a !important;
    font-size: 14px !important;
    font-weight: 900 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-meta small em {
    grid-area: role !important;
    color: #64748b !important;
    font-size: 12px !important;
    font-style: normal !important;
    font-weight: 700 !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item p {
    grid-area: detail !important;
    max-width: 620px !important;
    font-size: 17px !important;
  }

  html body:not(.auth-locked) #paymentInfoModal.is-activity-history .activity-log-item::after {
    content: "⌄" !important;
    grid-area: arrow !important;
    color: #0f172a !important;
    font-size: 24px !important;
    font-weight: 900 !important;
  }
}

/* Desktop debtors: final calm list mode after all card layout rules. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card:not(:hover):not(:focus-within) .desktop-debtor-quick-actions.desktop-debtor-reference-actions,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-card:not(:hover):not(:focus-within) .desktop-debtor-quick-actions.desktop-debtor-reference-actions {
    display: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card:hover .desktop-debtor-quick-actions.desktop-debtor-reference-actions,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card:focus-within .desktop-debtor-quick-actions.desktop-debtor-reference-actions,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-card:hover .desktop-debtor-quick-actions.desktop-debtor-reference-actions,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-card:focus-within .desktop-debtor-quick-actions.desktop-debtor-reference-actions {
    display: grid !important;
  }
}

/* Desktop debtors: final calm list mode for many customers. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card:not(:hover):not(:focus-within) .desktop-debtor-quick-actions.desktop-debtor-reference-actions,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-card:not(:hover):not(:focus-within) .desktop-debtor-quick-actions.desktop-debtor-reference-actions {
    display: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card:hover .desktop-debtor-quick-actions.desktop-debtor-reference-actions,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card:focus-within .desktop-debtor-quick-actions.desktop-debtor-reference-actions,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-card:hover .desktop-debtor-quick-actions.desktop-debtor-reference-actions,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-card:focus-within .desktop-debtor-quick-actions.desktop-debtor-reference-actions {
    display: grid !important;
  }
}

/* Desktop debtors: six compact summary cards. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-summary-grid,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr)) !important;
    gap: 12px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-summary-card,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card {
    appearance: none !important;
    min-height: 82px !important;
    grid-template-columns: minmax(0, 1fr) 38px !important;
    gap: 10px !important;
    padding: 13px 14px !important;
    border-radius: 12px !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", sans-serif !important;
    text-align: left !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list button.desktop-debtor-summary-card,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList button.desktop-debtor-summary-card {
    cursor: pointer !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list button.desktop-debtor-summary-card:hover,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList button.desktop-debtor-summary-card:hover {
    transform: translateY(-1px) !important;
    box-shadow: 0 12px 24px rgba(15, 23, 42, .07) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-summary-card.is-active,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card.is-active {
    border-color: #16a34a !important;
    box-shadow: 0 10px 22px rgba(5, 150, 105, .13) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-summary-copy,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-copy {
    gap: 9px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-summary-copy > span,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-copy > span {
    overflow: hidden !important;
    font-size: 11.5px !important;
    font-weight: 780 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-summary-copy strong,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-copy strong {
    gap: 6px !important;
    font-size: clamp(20px, 1.28vw, 25px) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-summary-copy small,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-copy small {
    font-size: 11px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-summary-card.is-money .desktop-debtor-summary-copy strong,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card.is-money .desktop-debtor-summary-copy strong {
    font-size: clamp(17px, 1.12vw, 21px) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-summary-icon,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-icon {
    width: 38px !important;
    height: 38px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-summary-icon svg,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-icon svg {
    width: 21px !important;
    height: 21px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-summary-card.is-all .desktop-debtor-summary-icon,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card.is-all .desktop-debtor-summary-icon {
    background: #eef2f7 !important;
    color: #475569 !important;
  }
}

@media (min-width: 769px) and (max-width: 1360px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-summary-grid,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }
}

/* Desktop debtors: final slim sort dropdown override. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-toolbar .desktop-debtor-sort,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-toolbar .desktop-debtor-sort {
    width: 210px !important;
    min-width: 210px !important;
    max-width: 210px !important;
    height: 36px !important;
    min-height: 36px !important;
    max-height: 36px !important;
    gap: 7px !important;
    padding: 0 9px 0 11px !important;
    border: 1px solid #e7edf5 !important;
    border-radius: 10px !important;
    background: rgba(255, 255, 255, .98) !important;
    box-shadow: 0 5px 12px rgba(15, 23, 42, .025) !important;
    color: #64748b !important;
    line-height: 1 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-toolbar .desktop-debtor-sort span,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-toolbar .desktop-debtor-sort span {
    flex: 0 0 auto !important;
    font-size: 11px !important;
    font-weight: 560 !important;
    line-height: 1 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-toolbar .desktop-debtor-sort select,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-toolbar .desktop-debtor-sort select {
    height: 34px !important;
    min-height: 34px !important;
    padding: 0 4px !important;
    font-size: 12px !important;
    font-weight: 650 !important;
    line-height: 1 !important;
  }
}

/* Desktop debtors: make the sort dropdown very small and light. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-toolbar .desktop-debtor-sort,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-toolbar .desktop-debtor-sort {
    width: 210px !important;
    min-width: 210px !important;
    height: 36px !important;
    min-height: 36px !important;
    gap: 7px !important;
    padding: 0 9px 0 11px !important;
    border: 1px solid #e7edf5 !important;
    border-radius: 10px !important;
    background: rgba(255, 255, 255, .98) !important;
    box-shadow: 0 5px 12px rgba(15, 23, 42, .025) !important;
    color: #64748b !important;
    line-height: 1 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-toolbar .desktop-debtor-sort span,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-toolbar .desktop-debtor-sort span {
    flex: 0 0 auto !important;
    font-size: 11px !important;
    font-weight: 560 !important;
    line-height: 1 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-toolbar .desktop-debtor-sort select,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-toolbar .desktop-debtor-sort select {
    height: 34px !important;
    min-height: 34px !important;
    padding: 0 4px !important;
    font-size: 12px !important;
    font-weight: 650 !important;
    line-height: 1 !important;
  }
}

/* Desktop debtors card final: hide duplicated name-row status pill after all layout rules. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-person-copy > div > .desktop-debtor-tag {
    display: none !important;
  }
}

/* Desktop debtors three-dot menu: match the mobile action sheet style. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-more {
    position: relative !important;
    overflow: visible !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-more-panel.desktop-debtor-action-panel {
    position: absolute !important;
    z-index: 120 !important;
    top: 62px !important;
    right: 0 !important;
    display: grid !important;
    gap: 0 !important;
    width: 350px !important;
    max-width: min(350px, calc(100vw - 44px)) !important;
    padding: 0 !important;
    overflow: visible !important;
    border: 1px solid #dfe7f1 !important;
    border-radius: 24px !important;
    background: #fff !important;
    box-shadow: 0 26px 54px rgba(15, 23, 42, .18) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-more-panel.desktop-debtor-action-panel::after {
    content: "" !important;
    position: absolute !important;
    right: 30px !important;
    bottom: -10px !important;
    width: 22px !important;
    height: 22px !important;
    border-right: 1px solid #dfe7f1 !important;
    border-bottom: 1px solid #dfe7f1 !important;
    background: #fff !important;
    transform: rotate(45deg) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-action-panel > button {
    display: grid !important;
    grid-template-columns: 58px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 18px !important;
    width: 100% !important;
    min-height: 84px !important;
    height: auto !important;
    padding: 14px 20px !important;
    border: 0 !important;
    border-bottom: 1px solid #edf2f7 !important;
    border-radius: 0 !important;
    background: #fff !important;
    color: #0f172a !important;
    box-shadow: none !important;
    text-align: left !important;
    cursor: pointer !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-action-panel > button:first-child {
    border-top-left-radius: 24px !important;
    border-top-right-radius: 24px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-action-panel > button:hover,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-manage-more > summary:hover {
    background: #f8fafc !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-action-panel > button:disabled {
    opacity: .46 !important;
    cursor: not-allowed !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-icon {
    display: inline-grid !important;
    width: 58px !important;
    height: 58px !important;
    min-width: 58px !important;
    place-items: center !important;
    border-radius: 18px !important;
    font-family: Inter, "IBM Plex Sans Thai", sans-serif !important;
    font-size: 17px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-icon.is-line {
    background: #dcfce7 !important;
    color: #16a34a !important;
    font-size: 12px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-icon.is-postpone,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-icon.is-renew {
    background: #fff1d9 !important;
    color: #f97316 !important;
    font-size: 27px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-icon.is-history {
    background: #ede9fe !important;
    color: #6d5dfc !important;
    font-size: 27px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-icon.is-edit {
    background: #e0f2fe !important;
    color: #0ea5e9 !important;
    font-size: 26px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-copy {
    display: grid !important;
    min-width: 0 !important;
    gap: 6px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-copy strong {
    color: #0f172a !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: 19px !important;
    font-weight: 900 !important;
    line-height: 1.1 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-copy small {
    color: #94a3b8 !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    line-height: 1.2 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-manage-more {
    display: block !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-manage-more > summary {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    min-height: 66px !important;
    padding: 0 24px !important;
    list-style: none !important;
    color: #0f172a !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: 18px !important;
    font-weight: 850 !important;
    cursor: pointer !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-manage-more > summary::-webkit-details-marker {
    display: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-manage-actions {
    display: grid !important;
    gap: 6px !important;
    padding: 0 16px 16px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-manage-actions button {
    min-height: 44px !important;
    border: 0 !important;
    border-radius: 14px !important;
    background: #f8fafc !important;
    color: #334155 !important;
    font-size: 15px !important;
    font-weight: 850 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-manage-actions button.is-danger {
    background: #fff1f2 !important;
    color: #e11d48 !important;
  }
}

/* Desktop debtors three-dot menu: compact desktop scale. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-more-panel.desktop-debtor-action-panel {
    width: 270px !important;
    max-width: min(270px, calc(100vw - 44px)) !important;
    border-radius: 18px !important;
    box-shadow: 0 18px 38px rgba(15, 23, 42, .16) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-action-panel > button {
    grid-template-columns: 42px minmax(0, 1fr) !important;
    gap: 14px !important;
    min-height: 62px !important;
    padding: 10px 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-icon {
    width: 42px !important;
    height: 42px !important;
    min-width: 42px !important;
    border-radius: 14px !important;
    font-size: 18px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-icon.is-line {
    font-size: 10px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-icon.is-postpone,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-icon.is-renew,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-icon.is-history,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-icon.is-edit {
    font-size: 20px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-copy {
    gap: 3px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-copy strong {
    font-size: 15px !important;
    line-height: 1.08 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-menu-copy small {
    font-size: 12px !important;
    line-height: 1.15 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-manage-more > summary {
    min-height: 52px !important;
    padding: 0 18px !important;
    font-size: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-more-panel.desktop-debtor-action-panel::after {
    top: 26px !important;
    right: -10px !important;
    bottom: auto !important;
    width: 20px !important;
    height: 20px !important;
    border: 0 !important;
    border-top: 1px solid #dfe7f1 !important;
    border-right: 1px solid #dfe7f1 !important;
    background: #fff !important;
    transform: rotate(45deg) !important;
  }
}

/* Desktop debtors board: match the summary-and-quick-actions reference. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board {
    display: grid !important;
    gap: 26px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-grid {
    display: grid !important;
    grid-template-columns: repeat(6, minmax(0, 1fr)) !important;
    gap: 12px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card {
    min-height: 118px !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 58px !important;
    align-items: center !important;
    gap: 16px !important;
    padding: 20px 24px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 16px !important;
    background: rgba(255, 255, 255, .96) !important;
    box-shadow: 0 14px 30px rgba(15, 23, 42, .06) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card.is-good {
    border-color: #16a34a !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-copy {
    display: grid !important;
    gap: 16px !important;
    min-width: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-copy > span {
    color: #64748b !important;
    font-size: 15px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card.is-good .desktop-debtor-summary-copy > span {
    color: #059669 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card.is-danger .desktop-debtor-summary-copy > span {
    color: #ef4444 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card.is-warning .desktop-debtor-summary-copy > span {
    color: #f97316 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-copy strong {
    display: flex !important;
    align-items: baseline !important;
    gap: 10px !important;
    min-width: 0 !important;
    color: #0f172a !important;
    font-family: Inter, "IBM Plex Sans Thai", sans-serif !important;
    font-size: clamp(26px, 2.2vw, 34px) !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-copy small {
    color: #64748b !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", sans-serif !important;
    font-size: 14px !important;
    font-weight: 800 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-icon {
    display: grid !important;
    width: 58px !important;
    height: 58px !important;
    place-items: center !important;
    border-radius: 999px !important;
    background: #dcfce7 !important;
    color: #059669 !important;
    font-size: 24px !important;
    font-weight: 900 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card.is-danger .desktop-debtor-summary-icon {
    background: #ffe4e9 !important;
    color: #ef4444 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card.is-warning .desktop-debtor-summary-icon {
    background: #ffedd5 !important;
    color: #f97316 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card.is-closed .desktop-debtor-summary-icon {
    background: #e8eef6 !important;
    color: #2563eb !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card.is-all .desktop-debtor-summary-icon {
    background: #eef2f7 !important;
    color: #475569 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card.is-money .desktop-debtor-summary-icon {
    background: #dcfce7 !important;
    color: #16a34a !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-toolbar {
    align-items: center !important;
    margin: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-filters {
    gap: 18px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-filter {
    min-width: 168px !important;
    min-height: 58px !important;
    padding: 0 22px !important;
    border-radius: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-filter.is-active {
    box-shadow: 0 14px 28px rgba(5, 150, 105, .2) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-sort {
    min-width: 300px !important;
    height: 58px !important;
    border-radius: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-card {
    border-radius: 18px !important;
    padding-bottom: 20px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-quick-actions {
    grid-column: 1 / -1 !important;
    display: flex !important;
    align-items: center !important;
    flex-wrap: wrap !important;
    gap: 12px !important;
    margin-top: 12px !important;
    padding: 14px 18px !important;
    border-radius: 14px !important;
    background: linear-gradient(90deg, rgba(236, 253, 245, .95), rgba(236, 253, 245, .58)) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-quick-actions > span {
    margin-right: 10px !important;
    color: #059669 !important;
    font-size: 15px !important;
    font-weight: 900 !important;
    white-space: nowrap !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-quick-button {
    min-height: 42px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    padding: 0 18px !important;
    border: 0 !important;
    border-radius: 10px !important;
    background: rgba(255, 255, 255, .94) !important;
    color: #059669 !important;
    box-shadow: 0 8px 18px rgba(15, 23, 42, .05) !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", sans-serif !important;
    font-size: 15px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    text-decoration: none !important;
    white-space: nowrap !important;
    cursor: pointer !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-quick-button:disabled {
    opacity: .45 !important;
    cursor: not-allowed !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-quick-button span {
    color: #059669 !important;
    font-size: 16px !important;
    font-weight: 900 !important;
  }
}

@media (min-width: 769px) and (max-width: 1360px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }
}

/* Desktop debtors reference actions: move mobile-style menu actions into the quick bar. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-quick-actions.desktop-debtor-reference-actions {
    grid-column: 1 / -1 !important;
    display: grid !important;
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    gap: 12px !important;
    margin-top: 14px !important;
    padding: 14px 16px !important;
    border-radius: 16px !important;
    background: linear-gradient(90deg, rgba(236, 253, 245, .96), rgba(236, 253, 245, .62)) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-quick-card {
    display: grid !important;
    grid-template-columns: 44px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 12px !important;
    min-width: 0 !important;
    min-height: 66px !important;
    padding: 10px 12px !important;
    border: 0 !important;
    border-radius: 14px !important;
    background: rgba(255, 255, 255, .96) !important;
    color: #0f172a !important;
    box-shadow: 0 8px 18px rgba(15, 23, 42, .05) !important;
    text-align: left !important;
    cursor: pointer !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-quick-card:hover {
    transform: translateY(-1px) !important;
    box-shadow: 0 12px 22px rgba(15, 23, 42, .08) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-quick-card:disabled {
    opacity: .46 !important;
    cursor: not-allowed !important;
    transform: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-menu-icon {
    width: 44px !important;
    height: 44px !important;
    min-width: 44px !important;
    border-radius: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-menu-copy {
    display: grid !important;
    gap: 4px !important;
    min-width: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-menu-copy strong {
    overflow: hidden !important;
    color: #0f172a !important;
    font-size: 15px !important;
    font-weight: 900 !important;
    line-height: 1.08 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-menu-copy small {
    overflow: hidden !important;
    color: #94a3b8 !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    line-height: 1.12 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-more-panel.desktop-debtor-action-panel.is-manage-only {
    width: 168px !important;
    max-width: 168px !important;
    padding: 8px !important;
    border-radius: 16px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-more-panel.desktop-debtor-action-panel.is-manage-only > button {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    min-height: 42px !important;
    width: 100% !important;
    padding: 0 12px !important;
    border: 0 !important;
    border-radius: 12px !important;
    background: #fff !important;
    color: #334155 !important;
    font-size: 14px !important;
    font-weight: 850 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-more-panel.desktop-debtor-action-panel.is-manage-only > button:hover {
    background: #f8fafc !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-more-panel.desktop-debtor-action-panel.is-manage-only > button.is-danger {
    color: #e11d48 !important;
  }
}

/* Desktop debtor summary: smaller cards with clean SVG icons. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-grid {
    gap: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card {
    min-height: 82px !important;
    grid-template-columns: minmax(0, 1fr) 38px !important;
    gap: 10px !important;
    padding: 13px 14px !important;
    border-radius: 12px !important;
    box-shadow: 0 9px 20px rgba(15, 23, 42, .045) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-copy {
    gap: 9px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-copy > span {
    overflow: hidden !important;
    font-size: 11.5px !important;
    font-weight: 780 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-copy strong {
    gap: 6px !important;
    font-size: clamp(20px, 1.28vw, 25px) !important;
    font-weight: 900 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-copy small {
    font-size: 11px !important;
    font-weight: 760 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-card.is-money .desktop-debtor-summary-copy strong {
    font-size: clamp(17px, 1.12vw, 21px) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-icon {
    width: 38px !important;
    height: 38px !important;
    border-radius: 999px !important;
    font-size: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-summary-icon svg {
    width: 21px !important;
    height: 21px !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 1.9 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
  }
}

/* Desktop debtors: remove duplicated filter chips below the summary cards. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-toolbar {
    display: flex !important;
    justify-content: flex-end !important;
    margin-top: -4px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-filters {
    display: none !important;
  }
}

/* Desktop debtors: slim sort control. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-sort {
    min-width: 240px !important;
    width: 240px !important;
    height: 42px !important;
    min-height: 42px !important;
    padding: 0 12px 0 14px !important;
    border-radius: 12px !important;
    border-color: #e5edf6 !important;
    box-shadow: 0 6px 14px rgba(15, 23, 42, .035) !important;
    gap: 8px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-sort span {
    font-size: 12px !important;
    font-weight: 650 !important;
    color: #64748b !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-sort select {
    font-size: 13px !important;
    font-weight: 760 !important;
    color: #0f172a !important;
  }
}

@media (min-width: 769px) and (max-width: 1360px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-quick-actions.desktop-debtor-reference-actions {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }
}

/* Desktop debtors reference actions: slimmer and lighter. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-quick-actions.desktop-debtor-reference-actions {
    gap: 9px !important;
    margin-top: 10px !important;
    padding: 10px 12px !important;
    border-radius: 13px !important;
    background: rgba(236, 253, 245, .56) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-quick-card {
    grid-template-columns: 34px minmax(0, 1fr) !important;
    gap: 10px !important;
    min-height: 50px !important;
    padding: 8px 10px !important;
    border-radius: 12px !important;
    background: rgba(255, 255, 255, .82) !important;
    box-shadow: 0 5px 12px rgba(15, 23, 42, .035) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-quick-card:hover {
    transform: none !important;
    box-shadow: 0 7px 14px rgba(15, 23, 42, .055) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-menu-icon {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    border-radius: 11px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-menu-icon.is-line {
    font-size: 9px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-menu-icon.is-postpone,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-menu-icon.is-renew,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-menu-icon.is-history,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-menu-icon.is-edit {
    font-size: 16px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-menu-copy {
    gap: 2px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-menu-copy strong {
    font-size: 13px !important;
    font-weight: 800 !important;
    line-height: 1.05 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-reference-actions .desktop-debtor-menu-copy small {
    font-size: 11px !important;
    font-weight: 600 !important;
    line-height: 1.08 !important;
  }
}

/* Desktop debtors card: remove duplicated status pill beside customer name. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-person-copy .desktop-debtor-tag {
    display: none !important;
  }
}

/* Desktop debtors card final: hide duplicated name-row status pill after all layout rules. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-person-copy > div > .desktop-debtor-tag {
    display: none !important;
  }
}

/* Desktop debtors card: responsive compact layout for narrowed desktop windows. */
@media (min-width: 769px) and (max-width: 1600px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-card {
    grid-template-columns: minmax(270px, 1.28fr) minmax(130px, .62fr) minmax(140px, .68fr) minmax(176px, .82fr) 152px 50px !important;
    grid-template-areas:
      "person amount status due actions more"
      "person progress progress progress actions more" !important;
    align-items: stretch !important;
    gap: 14px !important;
    min-height: 168px !important;
    padding: 20px 18px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-person {
    grid-area: person !important;
    align-self: center !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-metric:nth-of-type(1) {
    grid-area: amount !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-metric:nth-of-type(2) {
    grid-area: status !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-metric:nth-of-type(3) {
    grid-area: due !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-progress {
    grid-area: progress !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-actions {
    grid-area: actions !important;
    align-self: center !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-more {
    grid-area: more !important;
    align-self: center !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-person-copy > div {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    align-items: start !important;
    gap: 8px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-name {
    max-width: 100% !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-tag {
    max-width: 100% !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-metric,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-progress {
    min-width: 0 !important;
    padding-left: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-progress {
    align-self: end !important;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-card {
    grid-template-columns: minmax(245px, 1.05fr) minmax(132px, .6fr) minmax(132px, .6fr) 144px 48px !important;
    grid-template-areas:
      "person amount due actions more"
      "person status status actions more"
      "progress progress progress actions more" !important;
    gap: 12px !important;
    min-height: 204px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-person {
    grid-template-columns: 64px minmax(0, 1fr) !important;
    gap: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-avatar {
    width: 64px !important;
    height: 64px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel #recordsList .desktop-debtor-board .desktop-debtor-actions button {
    height: 46px !important;
    font-size: 14px !important;
  }
}

/* v1.1.0-mobile-dashboard-premium15: stronger mobile-only dashboard compaction. */
@media (max-width: 767px) {
  html body[data-page="dashboard"]:not(.auth-locked) .content-shell,
  html body[data-page="dashboard"]:not(.auth-locked) .content-shell.main-content,
  html body[data-page="dashboard"]:not(.auth-locked) .main-content,
  html body[data-page="dashboard"]:not(.auth-locked) .content-area,
  html body[data-page="dashboard"] .content-shell,
  html body[data-page="dashboard"] .content-shell.main-content,
  html body[data-page="dashboard"] .main-content,
  html body[data-page="dashboard"] .content-area {
    padding: 4px 12px calc(64px + env(safe-area-inset-bottom)) !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel.dashboard-page,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel.dashboard-page {
    gap: 7px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .app-topbar.app-topbar,
  html body[data-page="dashboard"] .app-topbar.app-topbar {
    height: 36px !important;
    min-height: 36px !important;
    margin-bottom: 7px !important;
    padding: 0 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .global-search.global-search,
  html body[data-page="dashboard"] .global-search.global-search {
    height: 36px !important;
    min-height: 36px !important;
    border-radius: 13px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .global-search input,
  html body[data-page="dashboard"] .global-search input {
    font-size: 10px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .notification-button.notification-button,
  html body[data-page="dashboard"]:not(.auth-locked) .topbar-user.topbar-user,
  html body[data-page="dashboard"] .notification-button.notification-button,
  html body[data-page="dashboard"] .topbar-user.topbar-user {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    min-height: 32px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-top-row,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-top-row {
    margin-top: -4px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-top-row .dashboard-hero h2,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-hero h2,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-top-row .dashboard-hero h2,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-hero h2 {
    width: auto !important;
    height: 30px !important;
    min-height: 30px !important;
    max-height: 30px !important;
    color: #0f172a !important;
    font-size: 30px !important;
    line-height: 30px !important;
    font-weight: 800 !important;
    letter-spacing: 0 !important;
    margin: 0 !important;
    overflow: visible !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-date.dashboard-mobile-date,
  html body[data-page="dashboard"] .dashboard-mobile-date.dashboard-mobile-date {
    font-size: 9.8px !important;
    line-height: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-quick-actions,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-quick-actions {
    gap: 7px !important;
    height: 56px !important;
    min-height: 56px !important;
    max-height: 56px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-quick-actions #dashboardNewLoan,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-quick-actions #dashboardCreateLineConnect,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-quick-actions button.secondary-button,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-quick-actions #dashboardNewLoan,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-quick-actions #dashboardCreateLineConnect,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-quick-actions button.secondary-button {
    height: 56px !important;
    min-height: 56px !important;
    max-height: 56px !important;
    padding: 7px 7px !important;
    border-radius: 12px !important;
    grid-template-columns: 26px minmax(0, 1fr) 7px !important;
    gap: 6px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-button-icon,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-button-icon {
    width: 26px !important;
    height: 26px !important;
    min-width: 26px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-action-copy strong,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-action-copy strong {
    font-size: 9.5px !important;
    line-height: 1.04 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-action-copy small,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-action-copy small {
    margin-top: 1px !important;
    font-size: 8.2px !important;
    line-height: 1.03 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel {
    height: 150px !important;
    min-height: 150px !important;
    max-height: 150px !important;
    padding: 8px 14px 8px !important;
    grid-template-rows: auto 1fr 32px !important;
    border-radius: 14px !important;
    overflow: hidden !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel > div:first-child,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel > div:first-child {
    padding-right: 62px !important;
    position: relative !important;
    z-index: 2 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker {
    margin-bottom: 4px !important;
    padding: 3px 8px !important;
    font-size: 9.2px !important;
    line-height: 1.02 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel strong,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel strong {
    max-width: 224px !important;
    font-size: clamp(16px, 4.55vw, 18px) !important;
    line-height: 1.04 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel small,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel small {
    margin-top: 3px !important;
    max-width: 220px !important;
    font-size: 8.9px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-art,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-art {
    top: 48px !important;
    right: 15px !important;
    width: 39px !important;
    height: 43px !important;
    z-index: 1 !important;
    opacity: .92 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .work-art-calendar,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel .work-art-calendar {
    width: 29px !important;
    height: 36px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .work-art-bell,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel .work-art-bell {
    width: 21px !important;
    height: 21px !important;
    right: -3px !important;
    top: 8px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel::after,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel::after {
    right: 51px !important;
    bottom: 55px !important;
    transform: scale(.27) !important;
    z-index: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel > .primary-button,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel button.primary-button,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel > .primary-button,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel button.primary-button {
    position: relative !important;
    z-index: 5 !important;
    height: 32px !important;
    min-height: 32px !important;
    max-height: 32px !important;
    font-size: 11.8px !important;
    line-height: 1 !important;
    border-radius: 9px !important;
    margin-top: 0 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel > .summary-grid {
    gap: 7px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel > .summary-grid .summary-tile {
    height: 74px !important;
    min-height: 74px !important;
    padding: 7px !important;
    border-radius: 12px !important;
    grid-template-columns: 29px minmax(0, 1fr) !important;
    column-gap: 7px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile-icon,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel > .summary-grid .summary-tile-icon {
    width: 29px !important;
    height: 29px !important;
    min-width: 29px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon),
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon) {
    font-size: 9px !important;
    line-height: 1.04 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(17px, 4.8vw, 20px) !important;
    line-height: .98 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small {
    font-size: 8.5px !important;
    line-height: 1.03 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup,
  html body[data-page="dashboard"] .dashboard-mobile-followup {
    margin-top: 1px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3,
  html body[data-page="dashboard"] .dashboard-mobile-followup-head h3 {
    font-size: 13.2px !important;
    line-height: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-card,
  html body[data-page="dashboard"] .dashboard-mobile-followup-card {
    padding: 1px 9px !important;
    border-radius: 12px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row,
  html body[data-page="dashboard"] .dashboard-mobile-followup-row {
    min-height: 35px !important;
    padding: 3px 0 !important;
    grid-template-columns: 25px minmax(0, 1fr) auto 8px !important;
    gap: 6px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-icon,
  html body[data-page="dashboard"] .followup-icon {
    width: 25px !important;
    height: 25px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-copy strong,
  html body[data-page="dashboard"] .followup-copy strong {
    font-size: 10px !important;
    line-height: 1.02 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-copy small,
  html body[data-page="dashboard"]:not(.auth-locked) .followup-amount,
  html body[data-page="dashboard"] .followup-copy small,
  html body[data-page="dashboard"] .followup-amount {
    font-size: 8.7px !important;
    line-height: 1.02 !important;
  }
}

/* v1.1.0-mobile-dashboard-premium13: tighter mobile dashboard and non-overlapping work art/button. */
@media (max-width: 768px) {
  html body[data-page="dashboard"]:not(.auth-locked) .content-shell,
  html body[data-page="dashboard"]:not(.auth-locked) .content-shell.main-content,
  html body[data-page="dashboard"]:not(.auth-locked) .main-content,
  html body[data-page="dashboard"]:not(.auth-locked) .content-area {
    padding: 5px 12px calc(66px + env(safe-area-inset-bottom)) !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel.dashboard-page {
    gap: 8px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .app-topbar,
  html body[data-page="dashboard"]:not(.auth-locked) .app-topbar.page-header,
  html body[data-page="dashboard"]:not(.auth-locked) .topbar {
    height: 38px !important;
    min-height: 38px !important;
    max-height: 38px !important;
    margin-bottom: 8px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .global-search,
  html body[data-page="dashboard"]:not(.auth-locked) .global-search.search-box {
    height: 38px !important;
    min-height: 38px !important;
    border-radius: 13px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .global-search input {
    padding-left: 38px !important;
    font-size: 10.8px !important;
    line-height: 1.1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .notification-button,
  html body[data-page="dashboard"]:not(.auth-locked) .icon-button.notification-button,
  html body[data-page="dashboard"]:not(.auth-locked) .topbar-user {
    width: 35px !important;
    height: 35px !important;
    min-width: 35px !important;
    min-height: 35px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row {
    margin-top: -7px !important;
    align-items: center !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2 {
    width: auto !important;
    height: 22px !important;
    min-height: 22px !important;
    max-height: 22px !important;
    font-size: 22px !important;
    line-height: 22px !important;
    font-weight: 800 !important;
    letter-spacing: 0 !important;
    margin: 0 !important;
    overflow: visible !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint::after {
    margin: 0 0 5px !important;
    font-size: 10.4px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-date {
    font-size: 10.4px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions {
    gap: 8px !important;
    height: 62px !important;
    min-height: 62px !important;
    max-height: 62px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions #dashboardNewLoan,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions #dashboardCreateLineConnect,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions button.secondary-button {
    height: 62px !important;
    min-height: 62px !important;
    max-height: 62px !important;
    padding: 8px 7px !important;
    border-radius: 12px !important;
    grid-template-columns: 29px minmax(0, 1fr) 7px !important;
    gap: 6px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-button-icon {
    width: 29px !important;
    height: 29px !important;
    min-width: 29px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy strong {
    font-size: 10px !important;
    line-height: 1.06 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy small {
    margin-top: 1px !important;
    font-size: 8.9px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel.dashboard-work-panel {
    height: 168px !important;
    min-height: 168px !important;
    max-height: 168px !important;
    padding: 10px 14px 9px !important;
    grid-template-rows: auto 1fr 34px !important;
    border-radius: 14px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel.dashboard-work-panel > div:first-child {
    padding-right: 72px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .dashboard-work-kicker {
    margin-bottom: 5px !important;
    padding: 4px 9px !important;
    font-size: 9.8px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel strong {
    max-width: 232px !important;
    font-size: clamp(18px, 5.05vw, 20px) !important;
    line-height: 1.07 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel small {
    margin-top: 4px !important;
    max-width: 225px !important;
    font-size: 9.5px !important;
    line-height: 1.1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .dashboard-work-art {
    top: 49px !important;
    right: 17px !important;
    width: 49px !important;
    height: 52px !important;
    z-index: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .work-art-calendar {
    width: 36px !important;
    height: 43px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .work-art-bell {
    width: 25px !important;
    height: 25px !important;
    right: -2px !important;
    top: 9px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel::after {
    right: 58px !important;
    bottom: 66px !important;
    transform: scale(.34) !important;
    z-index: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel > .primary-button,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel button.primary-button {
    position: relative !important;
    z-index: 3 !important;
    height: 34px !important;
    min-height: 34px !important;
    max-height: 34px !important;
    font-size: 12.5px !important;
    line-height: 1 !important;
    border-radius: 9px !important;
    margin-top: 0 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid {
    gap: 7px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile {
    height: 82px !important;
    min-height: 82px !important;
    padding: 8px !important;
    border-radius: 12px !important;
    grid-template-columns: 32px minmax(0, 1fr) !important;
    column-gap: 7px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile-icon {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon) {
    font-size: 9.7px !important;
    line-height: 1.06 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(19px, 5vw, 22px) !important;
    line-height: .98 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile small {
    font-size: 9.2px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup {
    margin-top: 2px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head {
    margin-bottom: 4px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3 {
    font-size: 14.2px !important;
    line-height: 1.02 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head button {
    font-size: 11px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-card {
    padding: 2px 10px !important;
    border-radius: 12px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row {
    min-height: 39px !important;
    padding: 4px 0 !important;
    grid-template-columns: 27px minmax(0, 1fr) auto 8px !important;
    gap: 6px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-icon {
    width: 27px !important;
    height: 27px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-copy strong {
    font-size: 10.8px !important;
    line-height: 1.04 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-copy small,
  html body[data-page="dashboard"]:not(.auth-locked) .followup-amount {
    font-size: 9.4px !important;
    line-height: 1.04 !important;
  }
}

/* v1.1.0-mobile-dashboard-premium14: apply even when body keeps auth-locked during mobile session restore. */
@media (max-width: 768px) {
  html body[data-page="dashboard"] .content-shell,
  html body[data-page="dashboard"] .content-shell.main-content,
  html body[data-page="dashboard"] .main-content,
  html body[data-page="dashboard"] .content-area {
    padding: 5px 12px calc(66px + env(safe-area-inset-bottom)) !important;
  }

  html body[data-page="dashboard"] #dashboardPanel.dashboard-page {
    gap: 8px !important;
  }

  html body[data-page="dashboard"] .app-topbar,
  html body[data-page="dashboard"] .app-topbar.page-header,
  html body[data-page="dashboard"] .topbar {
    height: 38px !important;
    min-height: 38px !important;
    max-height: 38px !important;
    margin-bottom: 8px !important;
  }

  html body[data-page="dashboard"] .global-search,
  html body[data-page="dashboard"] .global-search.search-box {
    height: 38px !important;
    min-height: 38px !important;
    border-radius: 13px !important;
  }

  html body[data-page="dashboard"] .global-search input {
    padding-left: 38px !important;
    font-size: 10.8px !important;
    line-height: 1.1 !important;
  }

  html body[data-page="dashboard"] .notification-button,
  html body[data-page="dashboard"] .icon-button.notification-button,
  html body[data-page="dashboard"] .topbar-user {
    width: 35px !important;
    height: 35px !important;
    min-width: 35px !important;
    min-height: 35px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-top-row {
    margin-top: -7px !important;
    align-items: center !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-top-row .dashboard-hero h2,
  html body[data-page="dashboard"] #dashboardPanel .dashboard-hero h2 {
    width: auto !important;
    height: 22px !important;
    min-height: 22px !important;
    max-height: 22px !important;
    font-size: 22px !important;
    line-height: 22px !important;
    font-weight: 800 !important;
    letter-spacing: 0 !important;
    margin: 0 !important;
    overflow: visible !important;
  }

  html body[data-page="dashboard"] #dashboardFilterHint,
  html body[data-page="dashboard"] #dashboardFilterHint::after {
    margin: 0 0 5px !important;
    font-size: 10.4px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-date {
    font-size: 10.4px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-quick-actions {
    gap: 8px !important;
    height: 62px !important;
    min-height: 62px !important;
    max-height: 62px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-quick-actions #dashboardNewLoan,
  html body[data-page="dashboard"] #dashboardPanel .dashboard-quick-actions #dashboardCreateLineConnect,
  html body[data-page="dashboard"] #dashboardPanel .dashboard-quick-actions button.secondary-button {
    height: 62px !important;
    min-height: 62px !important;
    max-height: 62px !important;
    padding: 8px 7px !important;
    border-radius: 12px !important;
    grid-template-columns: 29px minmax(0, 1fr) 7px !important;
    gap: 6px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-button-icon {
    width: 29px !important;
    height: 29px !important;
    min-width: 29px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-action-copy strong {
    font-size: 10px !important;
    line-height: 1.06 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-action-copy small {
    margin-top: 1px !important;
    font-size: 8.9px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel.dashboard-work-panel {
    height: 168px !important;
    min-height: 168px !important;
    max-height: 168px !important;
    padding: 10px 14px 9px !important;
    grid-template-rows: auto 1fr 34px !important;
    border-radius: 14px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel.dashboard-work-panel > div:first-child {
    padding-right: 72px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel .dashboard-work-kicker {
    margin-bottom: 5px !important;
    padding: 4px 9px !important;
    font-size: 9.8px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel strong {
    max-width: 232px !important;
    font-size: clamp(18px, 5.05vw, 20px) !important;
    line-height: 1.07 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel small {
    margin-top: 4px !important;
    max-width: 225px !important;
    font-size: 9.5px !important;
    line-height: 1.1 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel .dashboard-work-art {
    top: 42px !important;
    right: 17px !important;
    width: 47px !important;
    height: 50px !important;
    z-index: 1 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel .work-art-calendar {
    width: 34px !important;
    height: 41px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel .work-art-bell {
    width: 24px !important;
    height: 24px !important;
    right: -2px !important;
    top: 9px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel::after {
    right: 56px !important;
    bottom: 72px !important;
    transform: scale(.32) !important;
    z-index: 1 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel > .primary-button,
  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel button.primary-button {
    position: relative !important;
    z-index: 3 !important;
    height: 34px !important;
    min-height: 34px !important;
    max-height: 34px !important;
    font-size: 12.5px !important;
    line-height: 1 !important;
    border-radius: 9px !important;
    margin-top: 0 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel > .summary-grid {
    gap: 7px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel > .summary-grid .summary-tile {
    height: 82px !important;
    min-height: 82px !important;
    padding: 8px !important;
    border-radius: 12px !important;
    grid-template-columns: 32px minmax(0, 1fr) !important;
    column-gap: 7px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel > .summary-grid .summary-tile-icon {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon) {
    font-size: 9.7px !important;
    line-height: 1.06 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(19px, 5vw, 22px) !important;
    line-height: .98 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel > .summary-grid .summary-tile small {
    font-size: 9.2px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-followup {
    margin-top: 2px !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-followup-head {
    margin-bottom: 4px !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-followup-head h3 {
    font-size: 14.2px !important;
    line-height: 1.02 !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-followup-head button {
    font-size: 11px !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-followup-card {
    padding: 2px 10px !important;
    border-radius: 12px !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-followup-row {
    min-height: 39px !important;
    padding: 4px 0 !important;
    grid-template-columns: 27px minmax(0, 1fr) auto 8px !important;
    gap: 6px !important;
  }

  html body[data-page="dashboard"] .followup-icon {
    width: 27px !important;
    height: 27px !important;
  }

  html body[data-page="dashboard"] .followup-copy strong {
    font-size: 10.8px !important;
    line-height: 1.04 !important;
  }

  html body[data-page="dashboard"] .followup-copy small,
  html body[data-page="dashboard"] .followup-amount {
    font-size: 9.4px !important;
    line-height: 1.04 !important;
  }
}

/* v1.1.0-mobile-dashboard-premium15-final: final high-specificity mobile pass. */
@media (max-width: 767px) {
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel.dashboard-page,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel.dashboard-page {
    gap: 6px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-top-row .dashboard-hero h2,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-hero h2,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-top-row .dashboard-hero h2,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-hero h2 {
    height: 28px !important;
    min-height: 28px !important;
    max-height: 28px !important;
    color: #0f172a !important;
    font-size: 28px !important;
    line-height: 28px !important;
    font-weight: 800 !important;
    margin: 0 !important;
    overflow: visible !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-quick-actions,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-quick-actions {
    height: 54px !important;
    min-height: 54px !important;
    max-height: 54px !important;
    gap: 7px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-quick-actions button.secondary-button,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel .dashboard-quick-actions button.secondary-button {
    height: 54px !important;
    min-height: 54px !important;
    max-height: 54px !important;
    padding: 7px !important;
    grid-template-columns: 25px minmax(0, 1fr) 7px !important;
    gap: 6px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel {
    height: 142px !important;
    min-height: 142px !important;
    max-height: 142px !important;
    padding: 8px 13px !important;
    grid-template-rows: auto 1fr 31px !important;
    overflow: hidden !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel > div:first-child,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel > div:first-child {
    padding-right: 58px !important;
    position: relative !important;
    z-index: 3 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker {
    margin-bottom: 3px !important;
    padding: 3px 8px !important;
    font-size: 8.8px !important;
    line-height: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel strong,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel strong {
    max-width: 214px !important;
    font-size: clamp(15.5px, 4.25vw, 17px) !important;
    line-height: 1.03 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel small,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel small {
    margin-top: 2px !important;
    max-width: 212px !important;
    font-size: 8.5px !important;
    line-height: 1.04 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-art,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-art {
    top: 43px !important;
    right: 15px !important;
    width: 34px !important;
    height: 38px !important;
    z-index: 1 !important;
    opacity: .86 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .work-art-calendar,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel .work-art-calendar {
    width: 26px !important;
    height: 32px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .work-art-bell,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel .work-art-bell {
    width: 19px !important;
    height: 19px !important;
    right: -3px !important;
    top: 7px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel::after,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel::after {
    right: 47px !important;
    bottom: 49px !important;
    transform: scale(.24) !important;
    z-index: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel > .primary-button,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel button.primary-button,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel > .primary-button,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel #dashboardWorkPanel button.primary-button {
    height: 31px !important;
    min-height: 31px !important;
    max-height: 31px !important;
    font-size: 11.4px !important;
    line-height: 1 !important;
    position: relative !important;
    z-index: 8 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel > .summary-grid .summary-tile {
    height: 72px !important;
    min-height: 72px !important;
    padding: 7px !important;
    grid-template-columns: 28px minmax(0, 1fr) !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong,
  html body[data-page="dashboard"] #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(16.5px, 4.4vw, 19px) !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row,
  html body[data-page="dashboard"] .dashboard-mobile-followup-row {
    min-height: 34px !important;
  }
}

/* v1.1.0: full production polish for dashboard, loan workspace, LINE, account, and settings. */
body:not(.auth-locked) .quick-nav .side-brand {
  display: grid !important;
  grid-template-columns: 42px minmax(0, 1fr) !important;
  align-items: center !important;
  gap: 10px !important;
  min-height: 62px !important;
  padding: 10px 12px !important;
}

body:not(.auth-locked) .quick-nav .side-brand .side-program-logo {
  grid-row: 1 / span 1 !important;
}

body:not(.auth-locked) .quick-nav .side-brand .side-brand-copy {
  display: flex !important;
  flex-direction: column !important;
  min-width: 0 !important;
  gap: 2px !important;
}

body:not(.auth-locked) .quick-nav .side-brand .side-brand-copy > span {
  display: block !important;
  font-size: 11px !important;
  line-height: 1.1 !important;
  font-weight: 800 !important;
  color: #64748b !important;
  letter-spacing: .04em !important;
  white-space: nowrap !important;
}

body:not(.auth-locked) .quick-nav .side-brand .side-brand-copy > strong {
  display: block !important;
  max-width: 100% !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  font-size: 16px !important;
  line-height: 1.2 !important;
}

body[data-page="tracking"]:not(.auth-locked) .workspace::before,
body[data-page="tracking"]:not(.auth-locked) .main-content::before {
  content: "ติดตามชำระ" !important;
}

body[data-page="history"]:not(.auth-locked) .workspace::before,
body[data-page="history"]:not(.auth-locked) .main-content::before {
  content: "ประวัติรับชำระ" !important;
}

body[data-page="leads"]:not(.auth-locked) .app-topbar,
body[data-page="leads"]:not(.auth-locked) .page-header,
body[data-page="lineoa"]:not(.auth-locked) .app-topbar,
body[data-page="lineoa"]:not(.auth-locked) .page-header {
  display: flex !important;
}

body[data-page="leads"]:not(.auth-locked) #lineLeadsPanel > .panel-title,
body[data-page="lineoa"]:not(.auth-locked) #lineOaPanel > .panel-title {
  display: flex !important;
}

body[data-page="leads"]:not(.auth-locked) #lineLeadsPanel,
body[data-page="lineoa"]:not(.auth-locked) #lineOaPanel {
  padding-top: 20px !important;
}

.line-onboarding-panel,
.line-status-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0 0 16px;
}

.line-status-strip {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.line-onboarding-panel article,
.line-status-strip > div {
  display: grid;
  gap: 6px;
  padding: 14px;
  border: 1px solid rgba(15, 23, 42, .08);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .05);
}

.line-onboarding-panel span,
.line-status-strip span {
  width: fit-content;
  color: #047857;
  font-size: 12px;
  font-weight: 800;
}

.line-onboarding-panel strong,
.line-status-strip strong {
  color: #0f172a;
  font-size: 15px;
  line-height: 1.3;
}

.line-onboarding-panel small {
  color: #64748b;
  line-height: 1.5;
}

.line-empty-state {
  display: grid !important;
  gap: 10px !important;
  justify-items: start !important;
  text-align: left !important;
}

.line-empty-state strong {
  color: #0f172a;
  font-size: 17px;
}

.line-empty-state span {
  color: #64748b;
}

.records-table .records-col-actions {
  width: 250px;
}

.records-inline-actions,
.profile-row-actions,
.customer-profile-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.records-inline-actions .primary-button,
.records-inline-actions .secondary-button,
.profile-row-actions .secondary-button,
.customer-profile-actions .primary-button,
.customer-profile-actions .secondary-button {
  min-height: 34px;
  padding: 8px 10px;
  font-size: 13px;
  border-radius: 8px;
  text-decoration: none;
}

.line-id-chip {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #ecfdf5;
  color: #047857;
  font-size: 12px;
  font-weight: 700;
}

#historyPanel .panel-title .button-row {
  align-items: end;
  gap: 10px;
}

#historyPanel .compact-select input[type="date"] {
  min-height: 40px;
}

body[data-page="settings"] #settingsPanel > .panel-title::before,
body[data-page="settings"] #settingsPanel .settings-sections::before,
body[data-page="account"] .account-section-title::before,
body[data-page="account"] .account-section-title > span {
  content: none !important;
  display: none !important;
}

body[data-page="settings"] #settingsPanel .settings-footer {
  position: sticky !important;
  right: auto !important;
  bottom: 12px !important;
  display: flex !important;
  justify-content: flex-end !important;
  align-items: center !important;
  gap: 12px !important;
  padding: 12px !important;
  margin-top: 18px !important;
  border: 1px solid rgba(15, 23, 42, .08) !important;
  border-radius: 8px !important;
  background: rgba(255, 255, 255, .92) !important;
  backdrop-filter: blur(12px) !important;
  box-shadow: 0 16px 36px rgba(15, 23, 42, .08) !important;
}

body[data-page="settings"] #settingsPanel .settings-footer .primary-button {
  position: static !important;
  min-width: 160px !important;
}

@media (max-width: 860px) {
  .line-onboarding-panel,
  .line-status-strip {
    grid-template-columns: 1fr;
  }

  .records-table .records-col-actions,
  .records-table .records-action-cell {
    display: none;
  }

  #historyPanel .panel-title .button-row {
    align-items: stretch;
  }
}

/* v1.0.144: clean duplicate desktop navigation/content and remove stray account/settings decoration. */
@media (min-width: 769px) {
  body[data-page="settings"]:not(.auth-locked) .workspace,
  body[data-page="account"]:not(.auth-locked) .workspace {
    background: #f8fbf9 !important;
    background-image: none !important;
  }

  body[data-page="settings"]:not(.auth-locked) .workspace::before,
  body[data-page="settings"]:not(.auth-locked) .workspace::after,
  body[data-page="settings"]:not(.auth-locked) .main-content::before,
  body[data-page="settings"]:not(.auth-locked) .main-content::after,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel::before,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel::after,
  body[data-page="account"]:not(.auth-locked) .workspace::before,
  body[data-page="account"]:not(.auth-locked) .workspace::after,
  body[data-page="account"]:not(.auth-locked) .main-content::before,
  body[data-page="account"]:not(.auth-locked) .main-content::after,
  body[data-page="account"]:not(.auth-locked) #accountPanel::before,
  body[data-page="account"]:not(.auth-locked) #accountPanel::after,
  body[data-page="account"]:not(.auth-locked) .account-settings-page::before,
  body[data-page="account"]:not(.auth-locked) .account-settings-page::after {
    content: none !important;
    display: none !important;
    background: none !important;
    background-image: none !important;
    box-shadow: none !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label,
  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#trackingPanel"] .nav-label {
    font-size: 0 !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label::after {
    content: "รายการลูกค้า" !important;
    font-size: 13.5px !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#trackingPanel"] .nav-label::after {
    content: "ติดตามชำระ" !important;
    font-size: 13.5px !important;
  }

  body[data-page="records"]:not(.auth-locked) .records-subnav,
  body[data-page="customer"]:not(.auth-locked) .records-subnav {
    display: none !important;
  }

  body[data-page="records"]:not(.auth-locked) .workspace::before,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel::before {
    content: "รายการลูกค้า" !important;
  }

  body[data-records-subview="tracking"]:not(.auth-locked) .workspace::before {
    content: "ติดตามชำระ" !important;
  }

  body[data-page="leads"]:not(.auth-locked) .workspace::before,
  body[data-page="lineoa"]:not(.auth-locked) .workspace::before,
  body[data-page="leads"]:not(.auth-locked) #lineLeadsPanel > .panel-title,
  body[data-page="lineoa"]:not(.auth-locked) #lineOaPanel > .panel-title {
    content: none !important;
    display: none !important;
  }

  body[data-page="leads"]:not(.auth-locked) #lineLeadsPanel,
  body[data-page="lineoa"]:not(.auth-locked) #lineOaPanel {
    padding-top: 24px !important;
  }

  body[data-page="account"]:not(.auth-locked) .account-section-title > span,
  body[data-page="account"]:not(.auth-locked) .account-password-heading::before,
  body[data-page="account"]:not(.auth-locked) .account-password-heading::after,
  body[data-page="account"]:not(.auth-locked) .account-profile-card::before,
  body[data-page="account"]:not(.auth-locked) .account-password-card::before {
    content: none !important;
    display: none !important;
  }
}

@media (max-width: 768px) {
  html body[data-page="records"]:not(.auth-locked) #recordsList > .desktop-debtor-board {
    display: none !important;
  }
}

/* v1.1.0 sidebar-collapse hotfix: apply even in narrow desktop browser panes. */
body.nav-collapsed:not(.auth-locked) .app-shell,
body.nav-collapsed:not(.auth-locked) .app-shell.loan-app {
  grid-template-columns: 96px minmax(0, 1fr) !important;
}

body.nav-collapsed:not(.auth-locked) .quick-nav,
body.nav-collapsed:not(.auth-locked) .quick-nav.sidebar,
body.nav-collapsed:not(.auth-locked) .quick-nav.side-nav,
body.nav-collapsed:not(.auth-locked) .quick-nav.app-sidebar {
  width: 96px !important;
  min-width: 96px !important;
  max-width: 96px !important;
  padding: 20px 12px !important;
  align-items: center !important;
  gap: 14px !important;
  overflow-x: hidden !important;
}

body.nav-collapsed:not(.auth-locked) .quick-nav .side-brand {
  display: grid !important;
  grid-template-columns: 1fr !important;
  justify-items: center !important;
  width: 72px !important;
  min-height: 78px !important;
  padding: 0 0 14px !important;
  margin: 0 0 8px !important;
  border-bottom: 1px solid #e5e7eb !important;
  overflow: visible !important;
}

body.nav-collapsed:not(.auth-locked) .quick-nav .side-brand .side-program-logo {
  position: static !important;
  display: inline-flex !important;
  width: 54px !important;
  height: 54px !important;
  min-width: 54px !important;
  max-width: 54px !important;
  margin: 0 !important;
  transform: none !important;
  border-radius: 18px !important;
}

body.nav-collapsed:not(.auth-locked) .quick-nav .side-brand .side-brand-copy,
body.nav-collapsed:not(.auth-locked) .quick-nav .side-brand > span:not(.side-program-logo),
body.nav-collapsed:not(.auth-locked) .quick-nav .side-brand strong,
body.nav-collapsed:not(.auth-locked) .quick-nav .nav-label,
body.nav-collapsed:not(.auth-locked) .quick-nav .nav-label::before,
body.nav-collapsed:not(.auth-locked) .quick-nav .nav-label::after,
body.nav-collapsed:not(.auth-locked) .quick-nav .nav-chevron,
body.nav-collapsed:not(.auth-locked) .quick-nav .profile-copy,
body.nav-collapsed:not(.auth-locked) .quick-nav .nav-group-items,
body.nav-collapsed:not(.auth-locked) .quick-nav .mobile-only-nav-link,
body.nav-collapsed:not(.auth-locked) .quick-nav .legacy-settings-link,
body.nav-collapsed:not(.auth-locked) .quick-nav .side-user-profile {
  content: none !important;
  display: none !important;
  visibility: hidden !important;
  width: 0 !important;
  max-width: 0 !important;
  height: 0 !important;
  max-height: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
}

body.nav-collapsed:not(.auth-locked) .quick-nav > .sidebar-link,
body.nav-collapsed:not(.auth-locked) .quick-nav .nav-group-toggle,
body.nav-collapsed:not(.auth-locked) .quick-nav .side-user .nav-text-link,
body.nav-collapsed:not(.auth-locked) .quick-nav .logout-nav-link {
  display: grid !important;
  grid-template-columns: 1fr !important;
  place-items: center !important;
  width: 58px !important;
  min-width: 58px !important;
  max-width: 58px !important;
  height: 58px !important;
  min-height: 58px !important;
  max-height: 58px !important;
  padding: 0 !important;
  margin: 0 auto !important;
  border-radius: 18px !important;
  font-size: 0 !important;
  text-align: center !important;
}

body.nav-collapsed:not(.auth-locked) .quick-nav .nav-icon,
body.nav-collapsed:not(.auth-locked) .quick-nav .settings-gear {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 24px !important;
  height: 24px !important;
  margin: 0 !important;
  font-size: 16px !important;
}

body.nav-collapsed:not(.auth-locked) .quick-nav .nav-group,
body.nav-collapsed:not(.auth-locked) .quick-nav .side-user {
  width: 72px !important;
  min-width: 72px !important;
  max-width: 72px !important;
  display: grid !important;
  justify-items: center !important;
  gap: 12px !important;
}

body.nav-collapsed:not(.auth-locked) .quick-nav .side-user {
  margin-top: auto !important;
  padding-top: 12px !important;
  border-top: 1px solid #e5e7eb !important;
}

body.nav-collapsed:not(.auth-locked) .quick-nav .nav-collapse-button {
  position: absolute !important;
  top: 24px !important;
  right: -8px !important;
  width: 28px !important;
  height: 28px !important;
  min-width: 28px !important;
  min-height: 28px !important;
  padding: 0 !important;
  border-radius: 999px !important;
  background: #ffffff !important;
  border: 1px solid #dbe7e2 !important;
  box-shadow: 0 8px 18px rgba(15, 23, 42, .08) !important;
  z-index: 5 !important;
}

body.nav-collapsed:not(.auth-locked) .quick-nav .nav-collapse-button span {
  display: inline !important;
  visibility: visible !important;
  width: auto !important;
  height: auto !important;
  max-width: none !important;
  max-height: none !important;
  color: #047857 !important;
  font-size: 18px !important;
}

/* v1.1.0 sidebar submenu font hotfix: active child items must stay compact. */
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items,
body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items,
body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items {
  gap: 6px !important;
  padding-left: 32px !important;
}

body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link,
body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link,
body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active,
body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active,
body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active {
  display: grid !important;
  grid-template-columns: 10px minmax(0, 1fr) !important;
  align-items: center !important;
  width: 100% !important;
  min-width: 0 !important;
  height: 38px !important;
  min-height: 38px !important;
  max-height: 38px !important;
  padding: 0 12px !important;
  margin: 0 !important;
  border-radius: 10px !important;
  font-size: 14px !important;
  line-height: 1.2 !important;
  letter-spacing: 0 !important;
  text-decoration: none !important;
  transform: none !important;
}

body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active,
body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active,
body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active {
  background: #ecfdf5 !important;
  color: #047857 !important;
  box-shadow: none !important;
}

body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label,
body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-label,
body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-label,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active .nav-label,
body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active .nav-label,
body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active .nav-label {
  display: block !important;
  min-width: 0 !important;
  max-width: 100% !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  color: inherit !important;
  font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  letter-spacing: 0 !important;
  transform: none !important;
}

body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label::before,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label::after,
body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-label::before,
body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-label::after,
body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-label::before,
body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-label::after {
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  letter-spacing: 0 !important;
  transform: none !important;
}

/* v1.0.139: move Account/Settings sections into the sidebar and remove the old user block. */
@media (min-width: 769px) {
  body:not(.auth-locked) .quick-nav {
    overflow-y: auto !important;
    scrollbar-width: none !important;
    padding-bottom: 18px !important;
  }

  body:not(.auth-locked) .quick-nav::-webkit-scrollbar {
    width: 0 !important;
    height: 0 !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-account-link,
  body:not(.auth-locked) .quick-nav .mobile-settings-link,
  body:not(.auth-locked) .quick-nav .side-user-profile,
  body:not(.auth-locked) .quick-nav .legacy-settings-link {
    display: none !important;
  }

  body:not(.auth-locked) .quick-nav .side-user {
    margin-top: auto !important;
    padding-top: 14px !important;
    border-top: 1px solid rgba(15, 23, 42, .08) !important;
    gap: 0 !important;
    flex: 0 0 auto !important;
  }

  body:not(.auth-locked) .quick-nav .side-user .logout-nav-link {
    display: grid !important;
    color: #475569 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
  }

  body:not(.auth-locked) .quick-nav .side-user .logout-nav-link:hover {
    color: #dc2626 !important;
    background: #fff5f5 !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group,
  body:not(.auth-locked) .quick-nav .settings-nav-group {
    display: block !important;
    width: 100% !important;
  }

  body[data-page="account"]:not(.auth-locked) .quick-nav .account-nav-group > .nav-group-toggle,
  body[data-page="settings"]:not(.auth-locked) .quick-nav .settings-nav-group > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .account-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group > .nav-group-toggle.active {
    background: #ecfdf5 !important;
    color: #047857 !important;
    border-color: rgba(25, 195, 125, .38) !important;
  }

  body[data-page="account"]:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items,
  body[data-page="settings"]:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open .nav-group-items {
    display: flex !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items {
    margin: 4px 0 8px 34px !important;
    padding: 4px 0 4px 18px !important;
    border-left: 1px solid rgba(100, 116, 139, .18) !important;
    gap: 2px !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link {
    grid-template-columns: 10px minmax(0, 1fr) !important;
    height: 34px !important;
    min-height: 34px !important;
    max-height: 34px !important;
    margin: 0 !important;
    padding: 0 10px !important;
    border: 0 !important;
    border-radius: 10px !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #475569 !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-label,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-label {
    font-size: 13.5px !important;
    font-weight: 500 !important;
    line-height: 1.2 !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-dot,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-dot {
    display: block !important;
    width: 5px !important;
    height: 5px !important;
    border-radius: 999px !important;
    background: rgba(100, 116, 139, .38) !important;
    justify-self: center !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active {
    color: #0e9f6e !important;
    background: rgba(25, 195, 125, .1) !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active .nav-dot,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active .nav-dot {
    background: #19c37d !important;
  }

  body[data-page="account"]:not(.auth-locked) .account-settings-page .account-tabs {
    display: none !important;
  }
}

/* v1.0.142 absolute final override: nested sidebar menus stay user-collapsible. */
@media (min-width: 769px) {
  body:not(.auth-locked) .quick-nav .customer-nav-group,
  body:not(.auth-locked) .quick-nav .account-nav-group,
  body:not(.auth-locked) .quick-nav .settings-nav-group {
    display: block !important;
    width: 100% !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items {
    display: none !important;
    margin: 4px 0 8px 34px !important;
    padding: 4px 0 4px 18px !important;
    border-left: 1px solid rgba(100, 116, 139, .18) !important;
    gap: 2px !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group.is-open .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open .nav-group-items {
    display: flex !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .account-nav-group > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .settings-nav-group > .nav-group-toggle {
    background: transparent !important;
    color: #475569 !important;
    border-color: transparent !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .account-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .customer-nav-group.is-open > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open > .nav-group-toggle {
    background: #ecfdf5 !important;
    color: #047857 !important;
    border-color: rgba(25, 195, 125, .38) !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link {
    grid-template-columns: 10px minmax(0, 1fr) !important;
    height: 34px !important;
    min-height: 34px !important;
    max-height: 34px !important;
    margin: 0 !important;
    padding: 0 10px !important;
    border: 0 !important;
    border-radius: 10px !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #475569 !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-label,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-label {
    font-size: 13.5px !important;
    font-weight: 500 !important;
    line-height: 1.2 !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-dot,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-dot,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-dot {
    display: block !important;
    width: 5px !important;
    height: 5px !important;
    border-radius: 999px !important;
    background: rgba(100, 116, 139, .38) !important;
    justify-self: center !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active {
    color: #0e9f6e !important;
    background: rgba(25, 195, 125, .1) !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active .nav-dot,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active .nav-dot,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active .nav-dot {
    background: #19c37d !important;
  }
}

/* v1.0.143: absolute final rule. Parent menus collapse even when a child is active, and Settings shows one panel at a time. */
@media (min-width: 769px) {
  body:not(.auth-locked) .quick-nav .customer-nav-group:not(.is-open) > .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group:not(.is-open) > .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group:not(.is-open) > .nav-group-items,
  body[data-page="customer"]:not(.auth-locked) .quick-nav .customer-nav-group:not(.is-open) > .nav-group-items,
  body[data-page="account"]:not(.auth-locked) .quick-nav .account-nav-group:not(.is-open) > .nav-group-items,
  body[data-page="settings"]:not(.auth-locked) .quick-nav .settings-nav-group:not(.is-open) > .nav-group-items {
    display: none !important;
    max-height: 0 !important;
    overflow: hidden !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group.is-open > .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open > .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open > .nav-group-items,
  body[data-page="customer"]:not(.auth-locked) .quick-nav .customer-nav-group.is-open > .nav-group-items,
  body[data-page="account"]:not(.auth-locked) .quick-nav .account-nav-group.is-open > .nav-group-items,
  body[data-page="settings"]:not(.auth-locked) .quick-nav .settings-nav-group.is-open > .nav-group-items {
    display: flex !important;
    max-height: none !important;
    overflow: visible !important;
    visibility: visible !important;
    pointer-events: auto !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group:not(.is-open) > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .account-nav-group:not(.is-open) > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group:not(.is-open) > .nav-group-toggle.active,
  body[data-page="customer"]:not(.auth-locked) .quick-nav .customer-nav-group:not(.is-open) > .nav-group-toggle,
  body[data-page="account"]:not(.auth-locked) .quick-nav .account-nav-group:not(.is-open) > .nav-group-toggle,
  body[data-page="settings"]:not(.auth-locked) .quick-nav .settings-nav-group:not(.is-open) > .nav-group-toggle {
    background: transparent !important;
    border-color: transparent !important;
    color: #475569 !important;
    box-shadow: none !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group.is-open > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open > .nav-group-toggle {
    background: #ecfdf5 !important;
    border-color: rgba(25, 195, 125, .38) !important;
    color: #047857 !important;
  }

  body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-box {
    display: none !important;
  }

  body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-box.is-active-setting {
    display: block !important;
  }
}

/* v1.0.144-final-eof: must remain at EOF so old desktop/mobile rules cannot override it. */
body[data-page="records"]:not(.auth-locked) .records-subnav,
body[data-page="customer"]:not(.auth-locked) .records-subnav {
  display: none !important;
}

/* v1.0.145: production audit fixes for brand spacing and dense tables. */
@media (min-width: 769px) {
  body:not(.auth-locked) .side-brand,
  body:not(.auth-locked) .sidebar-brand {
    display: grid !important;
    grid-template-columns: 48px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 12px !important;
    min-height: 64px !important;
  }

  body:not(.auth-locked) .side-program-logo,
  body:not(.auth-locked) .side-brand::before {
    grid-row: 1 / 3 !important;
  }

  body:not(.auth-locked) .side-brand > span:not(.side-program-logo),
  body:not(.auth-locked) .side-brand > strong {
    min-width: 0 !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  body:not(.auth-locked) .side-brand > span:not(.side-program-logo) {
    align-self: end !important;
    font-size: 11px !important;
    letter-spacing: .08em !important;
  }

  body:not(.auth-locked) .side-brand > strong {
    align-self: start !important;
    font-size: 18px !important;
    line-height: 1.15 !important;
  }
}

.simple-table-wrap,
.table-wrap {
  overflow-x: auto !important;
  -webkit-overflow-scrolling: touch !important;
}

.simple-table,
.table-wrap table {
  min-width: 760px !important;
}

@media (max-width: 768px) {
  .simple-table-wrap::after,
  .table-wrap::after {
    content: "เลื่อนซ้าย-ขวาเพื่อดูข้อมูลครบ" !important;
    display: block !important;
    padding: 8px 4px 0 !important;
    color: #64748b !important;
    font-size: 12px !important;
    font-weight: 700 !important;
  }
}

@media (min-width: 769px) {
  body[data-page="settings"]:not(.auth-locked) .content,
  body[data-page="account"]:not(.auth-locked) .content,
  body[data-page="settings"]:not(.auth-locked) .workspace,
  body[data-page="account"]:not(.auth-locked) .workspace,
  body[data-page="settings"]:not(.auth-locked) .main-content,
  body[data-page="account"]:not(.auth-locked) .main-content {
    background: #f8fbf9 !important;
    background-image: none !important;
  }

  body[data-page="settings"]:not(.auth-locked) .workspace::before,
  body[data-page="settings"]:not(.auth-locked) .workspace::after,
  body[data-page="settings"]:not(.auth-locked) .main-content::before,
  body[data-page="settings"]:not(.auth-locked) .main-content::after,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel::before,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel::after,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel.settings-panel::before,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel.settings-panel::after,
  body[data-page="account"]:not(.auth-locked) .workspace::before,
  body[data-page="account"]:not(.auth-locked) .workspace::after,
  body[data-page="account"]:not(.auth-locked) .main-content::before,
  body[data-page="account"]:not(.auth-locked) .main-content::after,
  body[data-page="account"]:not(.auth-locked) #accountPanel::before,
  body[data-page="account"]:not(.auth-locked) #accountPanel::after,
  body[data-page="account"]:not(.auth-locked) .account-settings-page::before,
  body[data-page="account"]:not(.auth-locked) .account-settings-page::after {
    content: none !important;
    display: none !important;
    background: none !important;
    box-shadow: none !important;
  }

  body[data-page="records"]:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label,
  body[data-page="customer"]:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label,
  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label,
  body[data-page="tracking"]:not(.auth-locked) .quick-nav .nav-group-items > a[href="#trackingPanel"] .nav-label,
  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#trackingPanel"] .nav-label {
    font-size: 0 !important;
  }

  body[data-page="records"]:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label::after,
  body[data-page="customer"]:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label::after,
  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label::after {
    content: "รายการลูกค้า" !important;
    display: inline !important;
    font-size: 26px !important;
  }

  body[data-page="tracking"]:not(.auth-locked) .quick-nav .nav-group-items > a[href="#trackingPanel"] .nav-label::after,
  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#trackingPanel"] .nav-label::after {
    content: "ติดตามชำระ" !important;
    display: inline !important;
    font-size: 26px !important;
  }

  body[data-page="records"]:not(.auth-locked) .workspace::before,
  body[data-page="customer"]:not(.auth-locked) .workspace::before {
    content: "รายการลูกค้า" !important;
  }

  body[data-page="tracking"]:not(.auth-locked) .workspace::before,
  body[data-records-subview="tracking"]:not(.auth-locked) .workspace::before {
    content: "ติดตามชำระ" !important;
  }

  body[data-page="leads"]:not(.auth-locked) .app-topbar,
  body[data-page="leads"]:not(.auth-locked) .page-header,
  body[data-page="lineoa"]:not(.auth-locked) .app-topbar,
  body[data-page="lineoa"]:not(.auth-locked) .page-header {
    display: none !important;
  }

  body[data-page="leads"]:not(.auth-locked) .workspace::before,
  body[data-page="lineoa"]:not(.auth-locked) .workspace::before {
    content: none !important;
    display: none !important;
  }

  body[data-page="leads"]:not(.auth-locked) #lineLeadsPanel > .panel-title,
  body[data-page="lineoa"]:not(.auth-locked) #lineOaPanel > .panel-title {
    display: none !important;
  }

  body[data-page="leads"]:not(.auth-locked) .content,
  body[data-page="lineoa"]:not(.auth-locked) .content {
    padding-top: 24px !important;
  }

  body[data-page="leads"]:not(.auth-locked) #lineLeadsPanel,
  body[data-page="lineoa"]:not(.auth-locked) #lineOaPanel {
    padding-top: 24px !important;
  }

  body[data-page="account"]:not(.auth-locked) .account-section-title > span,
  body[data-page="account"]:not(.auth-locked) .account-password-heading::before,
  body[data-page="account"]:not(.auth-locked) .account-password-heading::after,
  body[data-page="account"]:not(.auth-locked) .account-profile-card::before,
  body[data-page="account"]:not(.auth-locked) .account-profile-card::after,
  body[data-page="account"]:not(.auth-locked) .account-password-card::before,
  body[data-page="account"]:not(.auth-locked) .account-password-card::after {
    content: none !important;
    display: none !important;
  }
}

/* v1.1.0 EOF override: keep polish above every legacy desktop rule. */
body:not(.auth-locked) .quick-nav .side-brand {
  display: grid !important;
  grid-template-columns: 42px minmax(0, 1fr) !important;
  align-items: center !important;
  gap: 10px !important;
  min-height: 62px !important;
  padding: 10px 12px !important;
}

body:not(.auth-locked) .quick-nav .side-brand .side-brand-copy {
  display: flex !important;
  flex-direction: column !important;
  min-width: 0 !important;
  gap: 2px !important;
}

body:not(.auth-locked) .quick-nav .side-brand .side-brand-copy > span {
  display: block !important;
  font-size: 11px !important;
  line-height: 1.1 !important;
  font-weight: 800 !important;
  color: #64748b !important;
  letter-spacing: .04em !important;
  white-space: nowrap !important;
}

body:not(.auth-locked) .quick-nav .side-brand .side-brand-copy > strong {
  display: block !important;
  max-width: 100% !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  font-size: 16px !important;
  line-height: 1.2 !important;
}

body[data-page="tracking"]:not(.auth-locked) .workspace::before,
body[data-page="tracking"]:not(.auth-locked) .main-content::before {
  content: "ติดตามชำระ" !important;
}

body[data-page="history"]:not(.auth-locked) .workspace::before,
body[data-page="history"]:not(.auth-locked) .main-content::before {
  content: "ประวัติรับชำระ" !important;
}

body[data-page="leads"]:not(.auth-locked) .app-topbar,
body[data-page="leads"]:not(.auth-locked) .page-header,
body[data-page="lineoa"]:not(.auth-locked) .app-topbar,
body[data-page="lineoa"]:not(.auth-locked) .page-header {
  display: flex !important;
}

body[data-page="leads"]:not(.auth-locked) #lineLeadsPanel > .panel-title,
body[data-page="lineoa"]:not(.auth-locked) #lineOaPanel > .panel-title {
  display: flex !important;
}

body[data-page="leads"]:not(.auth-locked) #lineLeadsPanel,
body[data-page="lineoa"]:not(.auth-locked) #lineOaPanel {
  padding-top: 20px !important;
}

.line-onboarding-panel,
.line-status-strip {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 12px !important;
  margin: 0 0 16px !important;
}

.line-status-strip {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

.line-onboarding-panel article,
.line-status-strip > div {
  display: grid !important;
  gap: 6px !important;
  padding: 14px !important;
  border: 1px solid rgba(15, 23, 42, .08) !important;
  border-radius: 8px !important;
  background: #fff !important;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .05) !important;
}

.line-onboarding-panel span,
.line-status-strip span {
  width: fit-content !important;
  color: #047857 !important;
  font-size: 12px !important;
  font-weight: 800 !important;
}

.line-empty-state {
  display: grid !important;
  gap: 10px !important;
  justify-items: start !important;
  text-align: left !important;
}

.records-table .records-col-actions {
  width: 250px !important;
}

.records-inline-actions,
.profile-row-actions,
.customer-profile-actions {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 8px !important;
  align-items: center !important;
}

.records-inline-actions .primary-button,
.records-inline-actions .secondary-button,
.profile-row-actions .secondary-button,
.customer-profile-actions .primary-button,
.customer-profile-actions .secondary-button {
  min-height: 34px !important;
  padding: 8px 10px !important;
  font-size: 13px !important;
  border-radius: 8px !important;
  text-decoration: none !important;
}

.line-id-chip {
  display: inline-flex !important;
  align-items: center !important;
  min-height: 32px !important;
  padding: 6px 10px !important;
  border-radius: 999px !important;
  background: #ecfdf5 !important;
  color: #047857 !important;
  font-size: 12px !important;
  font-weight: 700 !important;
}

#historyPanel .panel-title .button-row {
  align-items: end !important;
  gap: 10px !important;
}

#historyPanel .compact-select input[type="date"] {
  min-height: 40px !important;
}

body[data-page="settings"] #settingsPanel > .panel-title::before,
body[data-page="settings"] #settingsPanel .settings-sections::before,
body[data-page="account"] .account-section-title::before,
body[data-page="account"] .account-section-title > span {
  content: none !important;
  display: none !important;
}

body[data-page="settings"] #settingsPanel .settings-footer {
  position: sticky !important;
  right: auto !important;
  bottom: 12px !important;
  display: flex !important;
  justify-content: flex-end !important;
  align-items: center !important;
  gap: 12px !important;
  padding: 12px !important;
  margin-top: 18px !important;
  border: 1px solid rgba(15, 23, 42, .08) !important;
  border-radius: 8px !important;
  background: rgba(255, 255, 255, .92) !important;
  backdrop-filter: blur(12px) !important;
  box-shadow: 0 16px 36px rgba(15, 23, 42, .08) !important;
}

body[data-page="settings"] #settingsPanel .settings-footer .primary-button {
  position: static !important;
  min-width: 160px !important;
}

@media (max-width: 860px) {
  .line-onboarding-panel,
  .line-status-strip {
    grid-template-columns: 1fr !important;
  }

  .records-table .records-col-actions,
  .records-table .records-action-cell {
    display: none !important;
  }

  #historyPanel .panel-title .button-row {
    align-items: stretch !important;
  }
}

/* v1.0.144: final cleanup for duplicate desktop chrome, stray decorations, and menu labels. */
body[data-page="records"]:not(.auth-locked) .records-subnav,
body[data-page="customer"]:not(.auth-locked) .records-subnav {
  display: none !important;
}

@media (min-width: 769px) {
  body[data-page="settings"]:not(.auth-locked) .content,
  body[data-page="account"]:not(.auth-locked) .content,
  body[data-page="settings"]:not(.auth-locked) .workspace,
  body[data-page="account"]:not(.auth-locked) .workspace,
  body[data-page="settings"]:not(.auth-locked) .main-content,
  body[data-page="account"]:not(.auth-locked) .main-content {
    background: #f8fbf9 !important;
    background-image: none !important;
  }

  body[data-page="settings"]:not(.auth-locked) .workspace::before,
  body[data-page="settings"]:not(.auth-locked) .workspace::after,
  body[data-page="settings"]:not(.auth-locked) .main-content::before,
  body[data-page="settings"]:not(.auth-locked) .main-content::after,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel::before,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel::after,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel.settings-panel::before,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel.settings-panel::after,
  body[data-page="account"]:not(.auth-locked) .workspace::before,
  body[data-page="account"]:not(.auth-locked) .workspace::after,
  body[data-page="account"]:not(.auth-locked) .main-content::before,
  body[data-page="account"]:not(.auth-locked) .main-content::after,
  body[data-page="account"]:not(.auth-locked) #accountPanel::before,
  body[data-page="account"]:not(.auth-locked) #accountPanel::after,
  body[data-page="account"]:not(.auth-locked) .account-settings-page::before,
  body[data-page="account"]:not(.auth-locked) .account-settings-page::after {
    content: none !important;
    display: none !important;
    background: none !important;
    box-shadow: none !important;
  }

  body[data-page="records"]:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label,
  body[data-page="customer"]:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label,
  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label,
  body[data-page="tracking"]:not(.auth-locked) .quick-nav .nav-group-items > a[href="#trackingPanel"] .nav-label,
  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#trackingPanel"] .nav-label {
    font-size: 0 !important;
  }

  body[data-page="records"]:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label::after,
  body[data-page="customer"]:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label::after,
  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label::after {
    content: "รายการลูกค้า" !important;
    display: inline !important;
    font-size: 26px !important;
  }

  body[data-page="tracking"]:not(.auth-locked) .quick-nav .nav-group-items > a[href="#trackingPanel"] .nav-label::after,
  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#trackingPanel"] .nav-label::after {
    content: "ติดตามชำระ" !important;
    display: inline !important;
    font-size: 26px !important;
  }

  body[data-page="records"]:not(.auth-locked) .workspace::before,
  body[data-page="customer"]:not(.auth-locked) .workspace::before {
    content: "รายการลูกค้า" !important;
  }

  body[data-page="tracking"]:not(.auth-locked) .workspace::before,
  body[data-records-subview="tracking"]:not(.auth-locked) .workspace::before {
    content: "ติดตามชำระ" !important;
  }

  body[data-page="leads"]:not(.auth-locked) .app-topbar,
  body[data-page="leads"]:not(.auth-locked) .page-header,
  body[data-page="lineoa"]:not(.auth-locked) .app-topbar,
  body[data-page="lineoa"]:not(.auth-locked) .page-header {
    display: none !important;
  }

  body[data-page="leads"]:not(.auth-locked) .workspace::before,
  body[data-page="lineoa"]:not(.auth-locked) .workspace::before {
    content: none !important;
    display: none !important;
  }

  body[data-page="leads"]:not(.auth-locked) #lineLeadsPanel > .panel-title,
  body[data-page="lineoa"]:not(.auth-locked) #lineOaPanel > .panel-title {
    display: none !important;
  }

  body[data-page="leads"]:not(.auth-locked) .content,
  body[data-page="lineoa"]:not(.auth-locked) .content {
    padding-top: 24px !important;
  }

  body[data-page="leads"]:not(.auth-locked) #lineLeadsPanel,
  body[data-page="lineoa"]:not(.auth-locked) #lineOaPanel {
    padding-top: 24px !important;
  }

  body[data-page="account"]:not(.auth-locked) .account-section-title > span,
  body[data-page="account"]:not(.auth-locked) .account-password-heading::before,
  body[data-page="account"]:not(.auth-locked) .account-password-heading::after,
  body[data-page="account"]:not(.auth-locked) .account-profile-card::before,
  body[data-page="account"]:not(.auth-locked) .account-profile-card::after,
  body[data-page="account"]:not(.auth-locked) .account-password-card::before,
  body[data-page="account"]:not(.auth-locked) .account-password-card::after {
    content: none !important;
    display: none !important;
  }
}

/* v1.0.141 last-mile override: keep nested sidebar menus collapsible on every page. */
@media (min-width: 769px) {
  body:not(.auth-locked) .quick-nav .customer-nav-group,
  body:not(.auth-locked) .quick-nav .account-nav-group,
  body:not(.auth-locked) .quick-nav .settings-nav-group {
    display: block !important;
    width: 100% !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items {
    display: none !important;
    margin: 4px 0 8px 34px !important;
    padding: 4px 0 4px 18px !important;
    border-left: 1px solid rgba(100, 116, 139, .18) !important;
    gap: 2px !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group.is-open .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open .nav-group-items {
    display: flex !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .account-nav-group > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .settings-nav-group > .nav-group-toggle {
    background: transparent !important;
    color: #475569 !important;
    border-color: transparent !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .account-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .customer-nav-group.is-open > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open > .nav-group-toggle {
    background: #ecfdf5 !important;
    color: #047857 !important;
    border-color: rgba(25, 195, 125, .38) !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link {
    grid-template-columns: 10px minmax(0, 1fr) !important;
    height: 34px !important;
    min-height: 34px !important;
    max-height: 34px !important;
    margin: 0 !important;
    padding: 0 10px !important;
    border: 0 !important;
    border-radius: 10px !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #475569 !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-label,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-label {
    font-size: 13.5px !important;
    font-weight: 500 !important;
    line-height: 1.2 !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-dot,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-dot,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-dot {
    display: block !important;
    width: 5px !important;
    height: 5px !important;
    border-radius: 999px !important;
    background: rgba(100, 116, 139, .38) !important;
    justify-self: center !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active {
    color: #0e9f6e !important;
    background: rgba(25, 195, 125, .1) !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active .nav-dot,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active .nav-dot,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active .nav-dot {
    background: #19c37d !important;
  }
}

/* v1.0.140 final override: Customer, Account and Settings use one collapsible dot-submenu pattern. */
@media (min-width: 769px) {
  body:not(.auth-locked) .quick-nav .customer-nav-group,
  body:not(.auth-locked) .quick-nav .account-nav-group,
  body:not(.auth-locked) .quick-nav .settings-nav-group {
    display: block !important;
    width: 100% !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items {
    display: none !important;
    margin: 4px 0 8px 34px !important;
    padding: 4px 0 4px 18px !important;
    border-left: 1px solid rgba(100, 116, 139, .18) !important;
    gap: 2px !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group.is-open .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open .nav-group-items {
    display: flex !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .account-nav-group > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .settings-nav-group > .nav-group-toggle {
    background: transparent !important;
    color: #475569 !important;
    border-color: transparent !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .account-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .customer-nav-group.is-open > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open > .nav-group-toggle {
    background: #ecfdf5 !important;
    color: #047857 !important;
    border-color: rgba(25, 195, 125, .38) !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link {
    grid-template-columns: 10px minmax(0, 1fr) !important;
    height: 34px !important;
    min-height: 34px !important;
    max-height: 34px !important;
    margin: 0 !important;
    padding: 0 10px !important;
    border: 0 !important;
    border-radius: 10px !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #475569 !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-label,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-label {
    font-size: 13.5px !important;
    font-weight: 500 !important;
    line-height: 1.2 !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-dot,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-dot,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-dot {
    display: block !important;
    width: 5px !important;
    height: 5px !important;
    border-radius: 999px !important;
    background: rgba(100, 116, 139, .38) !important;
    justify-self: center !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active {
    color: #0e9f6e !important;
    background: rgba(25, 195, 125, .1) !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active .nav-dot,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active .nav-dot,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active .nav-dot {
    background: #19c37d !important;
  }
}

/* v1.0.136: lock account tabs to one visible panel and keep save actions in normal flow. */
body[data-page="account"] .account-settings-page [data-account-panel][hidden],
body[data-page="account"] .account-settings-page [data-account-panel].hidden,
body[data-page="account"] .account-settings-page .account-card.hidden {
  display: none !important;
}

body[data-page="account"] .account-settings-page .account-grid {
  display: block !important;
  width: 100% !important;
  overflow: visible !important;
}

body[data-page="account"] .account-settings-page [data-account-panel]:not(.hidden):not([hidden]) {
  display: block !important;
}

body[data-page="account"] .account-settings-page .account-card,
body[data-page="account"] .account-settings-page .save-confirm-panel,
body[data-page="account"] .account-settings-page #userProfileForm,
body[data-page="account"] .account-settings-page #accountProfileMount:not(.hidden):not([hidden]) {
  max-height: none !important;
  overflow: visible !important;
}

body[data-page="account"] .account-settings-page #userProfileForm {
  display: flex !important;
  flex-direction: column !important;
}

body[data-page="account"] .account-settings-page .account-password-card {
  padding-bottom: 0 !important;
}

body[data-page="account"] .account-settings-page .confirm-actions {
  position: static !important;
  inset: auto !important;
  transform: none !important;
  margin: 12px 0 0 !important;
  padding: 12px 0 0 !important;
  border-top: 1px solid rgba(15, 23, 42, .06) !important;
  display: flex !important;
  justify-content: flex-end !important;
  align-items: center !important;
  gap: 12px !important;
  flex-wrap: wrap !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-page="account"] .account-settings-page .confirm-actions .primary-button,
body[data-page="account"] .account-settings-page .confirm-actions .secondary-button {
  width: auto !important;
  min-width: 150px !important;
  max-width: 100% !important;
}

@media (max-width: 768px) {
  body[data-page="account"] .account-settings-page .confirm-actions {
    justify-content: stretch !important;
  }

  body[data-page="account"] .account-settings-page .confirm-actions .primary-button,
  body[data-page="account"] .account-settings-page .confirm-actions .secondary-button {
    width: 100% !important;
  }
}

/* v1.0.138 final: desktop sidebar follows the clean Puzzler-style navigation. */
@media (min-width: 769px) {
  body:not(.auth-locked) {
    --loan-sidebar-width: 300px;
    --loan-sidebar-ink: #111827;
    --loan-sidebar-muted: #475569;
    --loan-sidebar-line: rgba(15, 23, 42, .09);
    --loan-sidebar-green: #0f8b66;
    --loan-sidebar-active: #edfdf5;
    font-family: Inter, "IBM Plex Sans Thai", "Noto Sans Thai", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  body:not(.auth-locked) .app-shell.loan-app,
  body:not(.auth-locked).nav-collapsed .app-shell.loan-app {
    display: grid !important;
    grid-template-columns: var(--loan-sidebar-width) minmax(0, 1fr) !important;
    align-items: stretch !important;
    gap: 0 !important;
    width: 100% !important;
    max-width: none !important;
    min-height: 100vh !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
  }

  body:not(.auth-locked) .content-shell,
  body:not(.auth-locked) .main-area,
  body:not(.auth-locked) .main-content,
  body:not(.auth-locked).nav-collapsed .content-shell,
  body:not(.auth-locked).nav-collapsed .main-area,
  body:not(.auth-locked).nav-collapsed .main-content {
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 26px 40px 56px !important;
    transform: none !important;
  }

  body:not(.auth-locked) .quick-nav.sidebar,
  body:not(.auth-locked) .quick-nav.side-nav,
  body:not(.auth-locked) .quick-nav.app-sidebar,
  body:not(.auth-locked).nav-collapsed .quick-nav.sidebar,
  body:not(.auth-locked).nav-collapsed .quick-nav.side-nav,
  body:not(.auth-locked).nav-collapsed .quick-nav.app-sidebar {
    position: sticky !important;
    inset: 0 auto auto 0 !important;
    z-index: 10 !important;
    width: var(--loan-sidebar-width) !important;
    min-width: var(--loan-sidebar-width) !important;
    max-width: var(--loan-sidebar-width) !important;
    height: 100vh !important;
    min-height: 100vh !important;
    max-height: 100vh !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
    margin: 0 !important;
    padding: 30px 28px 28px !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    background: #fff !important;
    border: 0 !important;
    border-right: 1px solid var(--loan-sidebar-line) !important;
    border-radius: 0 !important;
    box-shadow: 18px 0 42px rgba(15, 23, 42, .04) !important;
    transform: none !important;
  }

  body:not(.auth-locked) .quick-nav::-webkit-scrollbar {
    width: 0 !important;
  }

  body:not(.auth-locked) .nav-collapse-button {
    display: none !important;
  }

  body:not(.auth-locked).nav-collapsed .quick-nav .nav-label,
  body:not(.auth-locked).nav-collapsed .quick-nav .profile-copy,
  body:not(.auth-locked).nav-collapsed .quick-nav .side-brand span,
  body:not(.auth-locked).nav-collapsed .quick-nav .side-brand strong {
    display: block !important;
    width: auto !important;
    height: auto !important;
    opacity: 1 !important;
    visibility: visible !important;
    clip-path: none !important;
  }

  body:not(.auth-locked) .side-brand,
  body:not(.auth-locked) .sidebar-brand {
    display: grid !important;
    grid-template-columns: 46px minmax(0, 1fr) !important;
    column-gap: 14px !important;
    align-items: center !important;
    min-height: 58px !important;
    margin: 0 0 22px !important;
    padding: 0 0 28px !important;
    border-bottom: 1px solid var(--loan-sidebar-line) !important;
    text-align: left !important;
  }

  body:not(.auth-locked) .side-program-logo {
    display: none !important;
  }

  body:not(.auth-locked) .side-brand::before {
    content: "฿";
    width: 46px;
    height: 46px;
    border-radius: 13px;
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 24px;
    font-weight: 800;
    line-height: 1;
    background: linear-gradient(145deg, #1fd18a, #0aa66d);
    box-shadow: 0 16px 30px rgba(25, 195, 125, .20);
  }

  body:not(.auth-locked) .side-brand > span:not(.side-program-logo) {
    display: block !important;
    color: #087a6d !important;
    font-size: 13px !important;
    font-weight: 800 !important;
    line-height: 1.05 !important;
    letter-spacing: .15em !important;
    text-transform: uppercase !important;
  }

  body:not(.auth-locked) .side-brand strong {
    display: block !important;
    grid-column: 2 !important;
    margin-top: 3px !important;
    color: var(--loan-sidebar-ink) !important;
    font-size: 20px !important;
    font-weight: 700 !important;
    line-height: 1.15 !important;
    letter-spacing: 0 !important;
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: clip !important;
  }

  body:not(.auth-locked) .quick-nav .sidebar-link,
  body:not(.auth-locked) .quick-nav .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .nav-text-link,
  body:not(.auth-locked) .quick-nav .logout-nav-link,
  body:not(.auth-locked).nav-collapsed .quick-nav .sidebar-link,
  body:not(.auth-locked).nav-collapsed .quick-nav .nav-group-toggle,
  body:not(.auth-locked).nav-collapsed .quick-nav .nav-text-link,
  body:not(.auth-locked).nav-collapsed .quick-nav .logout-nav-link {
    position: relative !important;
    width: 100% !important;
    height: 44px !important;
    min-height: 44px !important;
    display: grid !important;
    grid-template-columns: 26px minmax(0, 1fr) 16px !important;
    align-items: center !important;
    column-gap: 16px !important;
    padding: 0 10px !important;
    margin: 3px 0 !important;
    border: 0 !important;
    border-radius: 12px !important;
    background: transparent !important;
    box-shadow: none !important;
    color: var(--loan-sidebar-ink) !important;
    text-align: left !important;
    text-decoration: none !important;
    transform: none !important;
  }

  body:not(.auth-locked) .quick-nav .nav-icon,
  body:not(.auth-locked).nav-collapsed .quick-nav .nav-icon {
    width: 26px !important;
    min-width: 26px !important;
    height: 26px !important;
    min-height: 26px !important;
    display: grid !important;
    place-items: center !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: currentColor !important;
  }

  body:not(.auth-locked) .quick-nav .nav-icon svg {
    width: 21px !important;
    height: 21px !important;
    stroke-width: 1.9 !important;
  }

  body:not(.auth-locked) .quick-nav .nav-label,
  body:not(.auth-locked) .quick-nav .nav-group-toggle .nav-label,
  body:not(.auth-locked) .quick-nav .nav-text-link .nav-label {
    display: block !important;
    color: currentColor !important;
    font-size: 16px !important;
    font-weight: 500 !important;
    line-height: 1.2 !important;
    letter-spacing: 0 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  body:not(.auth-locked) .quick-nav .nav-chevron {
    display: block !important;
    justify-self: end !important;
    color: currentColor !important;
    font-size: 16px !important;
    font-weight: 500 !important;
    line-height: 1 !important;
  }

  body:not(.auth-locked) .quick-nav .sidebar-link:hover,
  body:not(.auth-locked) .quick-nav .nav-group-toggle:hover,
  body:not(.auth-locked) .quick-nav .nav-text-link:hover,
  body:not(.auth-locked) .quick-nav .logout-nav-link:hover {
    background: #f7faf9 !important;
    color: var(--loan-sidebar-green) !important;
  }

  body:not(.auth-locked) .quick-nav .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .nav-group-toggle.active {
    background: var(--loan-sidebar-active) !important;
    color: var(--loan-sidebar-green) !important;
    box-shadow: inset 3px 0 0 rgba(25, 195, 125, .55) !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group {
    display: block !important;
    width: 100% !important;
    margin: 3px 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items {
    display: none !important;
    flex-direction: column !important;
    gap: 2px !important;
    margin: 6px 0 8px 23px !important;
    padding: 2px 0 2px 21px !important;
    border-left: 1px solid rgba(15, 23, 42, .16) !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group.is-open .nav-group-items {
    display: flex !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link {
    grid-template-columns: minmax(0, 1fr) !important;
    height: 36px !important;
    min-height: 36px !important;
    padding: 0 14px !important;
    border-radius: 10px !important;
    color: #374151 !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items .nav-icon {
    display: none !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items .nav-label {
    font-size: 14px !important;
    font-weight: 500 !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active {
    color: #fff !important;
    background: #2f80ed !important;
    box-shadow: 0 10px 22px rgba(47, 128, 237, .22) !important;
  }

  body:not(.auth-locked) .mobile-create-nav,
  body:not(.auth-locked) .mobile-only-nav-link {
    display: none !important;
  }

  body:not(.auth-locked) .side-user {
    margin-top: auto !important;
    padding-top: 18px !important;
    border-top: 1px solid var(--loan-sidebar-line) !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
  }

  body:not(.auth-locked) .side-user-profile {
    display: grid !important;
    grid-template-columns: 34px minmax(0, 1fr) !important;
    gap: 12px !important;
    align-items: center !important;
    min-height: 46px !important;
    padding: 6px 10px !important;
    border: 0 !important;
    border-radius: 12px !important;
    background: transparent !important;
    box-shadow: none !important;
    text-decoration: none !important;
  }

  body:not(.auth-locked) .profile-avatar {
    width: 34px !important;
    height: 34px !important;
    border-radius: 50% !important;
    display: grid !important;
    place-items: center !important;
    background: #eafff4 !important;
    color: #087a5a !important;
    font-size: 14px !important;
    font-weight: 700 !important;
  }

  body:not(.auth-locked) .profile-copy span {
    display: block !important;
    color: #64748b !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    line-height: 1.2 !important;
  }

  body:not(.auth-locked) .profile-copy strong {
    display: block !important;
    color: var(--loan-sidebar-ink) !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    line-height: 1.25 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }
}

/* v1.0.137: Puzzler-style desktop sidebar reset. */
@media (min-width: 769px) {
  body:not(.auth-locked) {
    --puzzle-sidebar-width: 288px;
    --puzzle-sidebar-pad-x: 30px;
    --puzzle-ink: #101828;
    --puzzle-muted: #4b5565;
    --puzzle-line: rgba(16, 24, 40, .10);
    --puzzle-soft: #f6f7f9;
    --puzzle-green: #19c37d;
    --puzzle-green-dark: #087a5a;
    --puzzle-green-soft: #e9fff5;
    font-family: Inter, "IBM Plex Sans Thai", "Noto Sans Thai", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  body:not(.auth-locked) .app-shell.loan-app {
    display: grid !important;
    grid-template-columns: var(--puzzle-sidebar-width) minmax(0, 1fr) !important;
    gap: 0 !important;
    align-items: stretch !important;
    width: 100% !important;
    min-height: 100vh !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: visible !important;
  }

  body:not(.auth-locked) .content-shell,
  body:not(.auth-locked) .main-area,
  body:not(.auth-locked) .main-content {
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 28px 40px 56px !important;
    transform: none !important;
  }

  body:not(.auth-locked).nav-collapsed .app-shell.loan-app {
    grid-template-columns: var(--puzzle-sidebar-width) minmax(0, 1fr) !important;
  }

  body:not(.auth-locked) .quick-nav.sidebar,
  body:not(.auth-locked) .quick-nav.side-nav,
  body:not(.auth-locked) .quick-nav.app-sidebar {
    position: sticky !important;
    top: 0 !important;
    left: 0 !important;
    z-index: 20 !important;
    width: var(--puzzle-sidebar-width) !important;
    min-width: var(--puzzle-sidebar-width) !important;
    max-width: var(--puzzle-sidebar-width) !important;
    height: 100vh !important;
    max-height: 100vh !important;
    min-height: 100vh !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
    padding: 34px var(--puzzle-sidebar-pad-x) 26px !important;
    margin: 0 !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    background: rgba(255, 255, 255, .96) !important;
    border: 0 !important;
    border-right: 1px solid rgba(15, 23, 42, .07) !important;
    border-radius: 0 !important;
    box-shadow: 18px 0 50px rgba(15, 23, 42, .05) !important;
    backdrop-filter: blur(18px) !important;
  }

  body:not(.auth-locked) .quick-nav::-webkit-scrollbar {
    width: 0 !important;
  }

  body:not(.auth-locked) .nav-collapse-button {
    display: none !important;
  }

  body:not(.auth-locked).nav-collapsed .quick-nav,
  body:not(.auth-locked).nav-collapsed .quick-nav.sidebar,
  body:not(.auth-locked).nav-collapsed .quick-nav.side-nav,
  body:not(.auth-locked).nav-collapsed .quick-nav.app-sidebar {
    width: var(--puzzle-sidebar-width) !important;
    min-width: var(--puzzle-sidebar-width) !important;
    max-width: var(--puzzle-sidebar-width) !important;
    padding-left: var(--puzzle-sidebar-pad-x) !important;
    padding-right: var(--puzzle-sidebar-pad-x) !important;
  }

  body:not(.auth-locked).nav-collapsed .nav-label,
  body:not(.auth-locked).nav-collapsed .profile-copy,
  body:not(.auth-locked).nav-collapsed .side-brand span,
  body:not(.auth-locked).nav-collapsed .side-brand strong {
    display: inline !important;
    opacity: 1 !important;
    visibility: visible !important;
    width: auto !important;
    height: auto !important;
  }

  body:not(.auth-locked) .side-brand,
  body:not(.auth-locked) .sidebar-brand {
    flex: 0 0 auto !important;
    display: grid !important;
    grid-template-columns: 44px minmax(0, 1fr) !important;
    align-items: center !important;
    column-gap: 12px !important;
    min-height: 54px !important;
    padding: 0 0 30px !important;
    margin: 0 0 18px !important;
    border-bottom: 1px solid var(--puzzle-line) !important;
    text-align: left !important;
  }

  body:not(.auth-locked) .side-brand::before {
    content: "฿";
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 24px;
    font-weight: 800;
    line-height: 1;
    background: linear-gradient(145deg, #1fd18a, #0aa66d);
    box-shadow: 0 14px 28px rgba(25, 195, 125, .22);
  }

  body:not(.auth-locked) .side-program-logo {
    display: none !important;
  }

  body:not(.auth-locked) .side-brand > span:not(.side-program-logo) {
    display: block !important;
    align-self: end !important;
    color: #087a6d !important;
    font-size: 13px !important;
    font-weight: 800 !important;
    line-height: 1.05 !important;
    letter-spacing: .16em !important;
    text-transform: uppercase !important;
  }

  body:not(.auth-locked) .side-brand strong {
    display: block !important;
    grid-column: 2 !important;
    color: var(--puzzle-ink) !important;
    font-size: 20px !important;
    font-weight: 760 !important;
    line-height: 1.15 !important;
    letter-spacing: -.02em !important;
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: clip !important;
  }

  body:not(.auth-locked) .quick-nav .sidebar-link,
  body:not(.auth-locked) .quick-nav .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .nav-text-link,
  body:not(.auth-locked) .quick-nav .logout-nav-link {
    width: 100% !important;
    height: 46px !important;
    min-height: 46px !important;
    display: grid !important;
    grid-template-columns: 28px minmax(0, 1fr) 18px !important;
    align-items: center !important;
    gap: 16px !important;
    padding: 0 !important;
    margin: 0 !important;
    color: var(--puzzle-ink) !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    text-decoration: none !important;
    text-align: left !important;
    transform: none !important;
    font-family: inherit !important;
    cursor: pointer !important;
  }

  body:not(.auth-locked) .quick-nav .sidebar-link + .sidebar-link,
  body:not(.auth-locked) .quick-nav .nav-group + .sidebar-link,
  body:not(.auth-locked) .quick-nav .sidebar-link + .nav-group {
    margin-top: 12px !important;
  }

  body:not(.auth-locked) .quick-nav .nav-icon,
  body:not(.auth-locked) .quick-nav .settings-gear {
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
    border-radius: 0 !important;
    display: grid !important;
    place-items: center !important;
    color: currentColor !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body:not(.auth-locked) .quick-nav svg {
    width: 22px !important;
    height: 22px !important;
    stroke-width: 1.85 !important;
  }

  body:not(.auth-locked) .quick-nav .nav-label {
    display: block !important;
    color: inherit !important;
    font-size: 16px !important;
    font-weight: 520 !important;
    line-height: 1.2 !important;
    letter-spacing: -.01em !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  body:not(.auth-locked) .quick-nav .sidebar-link:hover,
  body:not(.auth-locked) .quick-nav .nav-group-toggle:hover,
  body:not(.auth-locked) .quick-nav .nav-text-link:hover {
    color: #050b18 !important;
    transform: translateX(2px) !important;
  }

  body:not(.auth-locked) .quick-nav .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .nav-text-link.active,
  body:not(.auth-locked) .quick-nav .settings-nav-link.active {
    color: var(--puzzle-green-dark) !important;
    font-weight: 650 !important;
  }

  body:not(.auth-locked) .quick-nav > .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .side-user > .nav-text-link.active {
    height: 44px !important;
    padding: 0 12px !important;
    margin-left: -12px !important;
    width: calc(100% + 24px) !important;
    border-radius: 10px !important;
    background: var(--puzzle-green-soft) !important;
    box-shadow: 0 12px 24px rgba(25, 195, 125, .10) !important;
  }

  body:not(.auth-locked) .nav-group {
    display: block !important;
    width: 100% !important;
    margin: 12px 0 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  body:not(.auth-locked) .nav-group-toggle .nav-chevron {
    display: block !important;
    justify-self: end !important;
    color: currentColor !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    transform: none !important;
  }

  body:not(.auth-locked) .nav-group.is-open .nav-group-toggle .nav-chevron {
    transform: rotate(180deg) !important;
  }

  body:not(.auth-locked) .nav-group-toggle.active,
  body:not(.auth-locked) .nav-group.is-open .nav-group-toggle {
    color: var(--puzzle-ink) !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body:not(.auth-locked) .nav-group-items {
    position: relative !important;
    display: none !important;
    flex-direction: column !important;
    gap: 8px !important;
    margin: 8px 0 4px 42px !important;
    padding: 4px 0 4px 20px !important;
    border-left: 1px solid rgba(15, 23, 42, .12) !important;
    background: transparent !important;
    overflow: visible !important;
  }

  body:not(.auth-locked) .nav-group.is-open .nav-group-items {
    display: flex !important;
  }

  body:not(.auth-locked) .nav-group-items .sidebar-link {
    grid-template-columns: minmax(0, 1fr) !important;
    width: 100% !important;
    height: 34px !important;
    min-height: 34px !important;
    padding: 0 12px !important;
    border-radius: 8px !important;
    color: var(--puzzle-ink) !important;
    background: transparent !important;
  }

  body:not(.auth-locked) .nav-group-items .nav-icon {
    display: none !important;
  }

  body:not(.auth-locked) .nav-group-items .nav-label {
    font-size: 14px !important;
    font-weight: 480 !important;
  }

  body:not(.auth-locked) .nav-group-items .sidebar-link.active {
    color: #fff !important;
    background: linear-gradient(135deg, var(--puzzle-green), var(--puzzle-green-dark)) !important;
    box-shadow: 0 10px 18px rgba(25, 195, 125, .22) !important;
  }

  body:not(.auth-locked) .mobile-create-nav,
  body:not(.auth-locked) .mobile-only-nav-link {
    display: none !important;
  }

  body:not(.auth-locked) .side-user {
    flex: 0 0 auto !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 14px !important;
    margin: auto 0 0 !important;
    padding: 22px 0 0 !important;
    border-top: 1px solid var(--puzzle-line) !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body:not(.auth-locked) .side-user-profile {
    display: grid !important;
    grid-template-columns: 32px minmax(0, 1fr) !important;
    gap: 12px !important;
    align-items: center !important;
    width: 100% !important;
    min-height: 44px !important;
    padding: 0 !important;
    margin: 0 0 4px !important;
    color: var(--puzzle-ink) !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    text-decoration: none !important;
  }

  body:not(.auth-locked) .profile-avatar {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    border-radius: 50% !important;
    display: grid !important;
    place-items: center !important;
    color: var(--puzzle-green-dark) !important;
    background: #ecfff6 !important;
    box-shadow: none !important;
    font-size: 13px !important;
    font-weight: 750 !important;
  }

  body:not(.auth-locked) .profile-copy {
    display: block !important;
    min-width: 0 !important;
    line-height: 1.2 !important;
  }

  body:not(.auth-locked) .profile-copy span {
    display: block !important;
    color: #778196 !important;
    font-size: 12px !important;
    font-weight: 560 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  body:not(.auth-locked) .profile-copy strong {
    display: block !important;
    color: var(--puzzle-ink) !important;
    font-size: 14px !important;
    font-weight: 660 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  body:not(.auth-locked) .side-user .nav-text-link,
  body:not(.auth-locked) .side-user .logout-nav-link {
    grid-template-columns: 28px minmax(0, 1fr) !important;
    height: 38px !important;
    min-height: 38px !important;
    color: var(--puzzle-muted) !important;
    font-size: 15px !important;
  }

  body:not(.auth-locked) .side-user .nav-text-link .nav-label,
  body:not(.auth-locked) .side-user .logout-nav-link .nav-label {
    font-size: 15px !important;
    font-weight: 500 !important;
  }

  body:not(.auth-locked) .side-user .logout-nav-link {
    color: rgba(16, 24, 40, .62) !important;
  }

  body:not(.auth-locked) .side-user .logout-nav-link:hover {
    color: #d92d20 !important;
  }
}

/* v1.0.135 compact sidebar + one-panel account profile/password layout. */
@media (min-width: 641px) {
  body[data-page] .quick-nav,
  body[data-page] .quick-nav.sidebar,
  body[data-page] .quick-nav.app-sidebar {
    height: calc(100vh - 32px) !important;
    max-height: calc(100vh - 32px) !important;
    display: flex !important;
    flex-direction: column !important;
    padding: 18px 14px 16px !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    overscroll-behavior: contain !important;
    scrollbar-width: thin !important;
    scrollbar-color: rgba(100, 116, 139, .24) transparent !important;
  }

  body[data-page] .quick-nav::-webkit-scrollbar {
    width: 4px !important;
  }

  body[data-page] .quick-nav::-webkit-scrollbar-thumb {
    border-radius: 999px !important;
    background: rgba(100, 116, 139, .24) !important;
  }

  body[data-page] .quick-nav .side-brand {
    height: 84px !important;
    min-height: 84px !important;
    max-height: 84px !important;
    margin-bottom: 14px !important;
    padding-bottom: 16px !important;
  }

  body[data-page] .quick-nav .side-program-logo {
    width: 58px !important;
    min-width: 58px !important;
    max-width: 58px !important;
    height: 58px !important;
    min-height: 58px !important;
    max-height: 58px !important;
    border-radius: 18px !important;
  }

  body[data-page] .quick-nav .side-brand strong {
    font-size: 1.24rem !important;
    line-height: 1.08 !important;
  }

  body[data-page] .quick-nav .side-brand > span:not(.side-program-logo) {
    font-size: .72rem !important;
    line-height: 1 !important;
  }

  body[data-page] .quick-nav .sidebar-link,
  body[data-page] .quick-nav .nav-group-toggle,
  body[data-page] .quick-nav .nav-text-link,
  body[data-page] .quick-nav .side-user-profile {
    min-height: 48px !important;
    margin: 0 0 7px !important;
    padding: 8px 10px !important;
    gap: 10px !important;
    border-radius: 16px !important;
  }

  body[data-page] .quick-nav .nav-icon,
  body[data-page] .quick-nav .settings-gear,
  body[data-page] .quick-nav .profile-avatar {
    width: 38px !important;
    min-width: 38px !important;
    max-width: 38px !important;
    height: 38px !important;
    min-height: 38px !important;
    max-height: 38px !important;
    border-radius: 13px !important;
  }

  body[data-page] .quick-nav .nav-label,
  body[data-page] .quick-nav .profile-copy strong {
    font-size: 1rem !important;
    line-height: 1.12 !important;
  }

  body[data-page] .quick-nav .nav-group-items {
    gap: 6px !important;
    margin: 4px 0 8px 21px !important;
    padding-left: 14px !important;
  }

  body[data-page] .quick-nav .nav-group-items .sidebar-link {
    min-height: 44px !important;
    margin-bottom: 6px !important;
    padding: 7px 10px !important;
  }

  body[data-page] .quick-nav .side-user {
    margin-top: auto !important;
    padding-top: 12px !important;
    gap: 7px !important;
    border-top: 1px solid #dfe7ee !important;
  }

  body[data-page].nav-collapsed .quick-nav,
  body[data-page].nav-collapsed .quick-nav.sidebar,
  body[data-page].nav-collapsed .quick-nav.app-sidebar {
    overflow-y: auto !important;
    padding: 18px 14px 14px !important;
  }

  body[data-page="account"] .account-settings-page {
    width: 100% !important;
    max-width: none !important;
    padding: clamp(20px, 2vw, 28px) clamp(22px, 2.7vw, 36px) !important;
  }

  body[data-page="account"] .account-settings-page > .panel-title,
  body[data-page="account"] .account-settings-page .panel-title {
    margin-bottom: 16px !important;
  }

  body[data-page="account"] .account-settings-page > .panel-title h2,
  body[data-page="account"] .account-settings-page .panel-title h2 {
    font-size: clamp(2.2rem, 3.4vw, 3.05rem) !important;
    line-height: .96 !important;
  }

  body[data-page="account"] .account-settings-page > .panel-title p,
  body[data-page="account"] .account-settings-page .panel-title p {
    max-width: 680px !important;
    font-size: 1rem !important;
    line-height: 1.35 !important;
  }

  body[data-page="account"] .account-settings-page .account-tabs {
    min-height: 42px !important;
    margin-bottom: 20px !important;
    gap: 24px !important;
  }

  body[data-page="account"] .account-settings-page .account-tab {
    min-height: 42px !important;
    padding: 0 0 10px !important;
    gap: 10px !important;
  }

  body[data-page="account"] .account-settings-page .account-tab-icon {
    width: 34px !important;
    height: 34px !important;
    border-radius: 12px !important;
  }

  body[data-page="account"] .account-settings-page #accountProfileMount:not(.hidden):not([hidden]) {
    display: block !important;
    padding: 24px 28px 22px !important;
    border: 1px solid rgba(15, 23, 42, .08) !important;
    border-radius: 28px !important;
    background: rgba(255, 255, 255, .9) !important;
    box-shadow: 0 24px 70px rgba(15, 23, 42, .08) !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-card,
  body[data-page="account"] .account-settings-page .account-password-card,
  body[data-page="account"] .account-settings-page #userProfileForm {
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .account-settings-page #userProfileForm::before,
  body[data-page="account"] .account-settings-page #userProfileForm::after {
    display: none !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-hero {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 360px) !important;
    gap: 18px !important;
    align-items: center !important;
    margin-bottom: 18px !important;
    padding: 0 !important;
  }

  body[data-page="account"] .account-settings-page .account-section-title h3,
  body[data-page="account"] .account-settings-page .account-password-heading strong {
    font-size: 1.32rem !important;
    line-height: 1.1 !important;
  }

  body[data-page="account"] .account-settings-page .account-section-title p,
  body[data-page="account"] .account-settings-page .account-password-heading span,
  body[data-page="account"] .account-settings-page .account-profile-picture p {
    font-size: .88rem !important;
    line-height: 1.35 !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-picture {
    display: grid !important;
    grid-template-columns: 72px minmax(0, 1fr) !important;
    gap: 14px !important;
    align-items: center !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-orb {
    width: 72px !important;
    min-width: 72px !important;
    height: 72px !important;
    min-height: 72px !important;
    border-radius: 22px !important;
  }

  body[data-page="account"] .account-settings-page .account-upload-photo-button {
    min-height: 36px !important;
    padding: 8px 14px !important;
    border-radius: 10px !important;
    font-size: .82rem !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-readonly-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 14px !important;
  }

  body[data-page="account"] .account-settings-page .account-info-row,
  body[data-page="account"] .account-settings-page .account-card label:not(.file-button):not(.secondary-button) {
    display: grid !important;
    gap: 7px !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  body[data-page="account"] .account-settings-page .account-info-row-wide {
    width: calc(50% - 7px) !important;
    margin-top: 14px !important;
  }

  body[data-page="account"] .account-settings-page .account-info-row > span,
  body[data-page="account"] .account-settings-page .account-card label > span {
    font-size: .86rem !important;
    line-height: 1.2 !important;
  }

  body[data-page="account"] .account-settings-page .account-info-row > input,
  body[data-page="account"] .account-settings-page .account-card input,
  body[data-page="account"] .account-settings-page .account-card textarea,
  body[data-page="account"] .account-settings-page .account-card select {
    min-height: 44px !important;
    padding: 10px 14px !important;
    border: 1px solid #dbe4ee !important;
    border-radius: 13px !important;
    background: #fff !important;
    box-shadow: 0 8px 20px rgba(15, 23, 42, .025) !important;
    font-size: .95rem !important;
  }

  body[data-page="account"] .account-settings-page .account-info-row > input[readonly] {
    pointer-events: none !important;
  }

  body[data-page="account"] .account-settings-page .profile-signature-box {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 170px !important;
    gap: 18px !important;
    align-items: stretch !important;
    margin: 18px 0 0 !important;
    padding: 0 !important;
    border: 0 !important;
  }

  body[data-page="account"] .account-settings-page .signature-upload-field {
    display: grid !important;
    gap: 7px !important;
  }

  body[data-page="account"] .account-settings-page .signature-dropzone {
    min-height: 118px !important;
    padding: 16px !important;
    border-radius: 18px !important;
  }

  body[data-page="account"] .account-settings-page .signature-dropzone b {
    width: 34px !important;
    height: 34px !important;
  }

  body[data-page="account"] .account-settings-page .signature-dropzone em,
  body[data-page="account"] .account-settings-page .signature-dropzone small {
    font-size: .84rem !important;
    line-height: 1.25 !important;
  }

  body[data-page="account"] .account-settings-page .signature-dropzone strong {
    min-height: 34px !important;
    padding: 7px 16px !important;
    font-size: .82rem !important;
  }

  body[data-page="account"] .account-settings-page .signature-preview,
  body[data-page="account"] .account-settings-page .signature-preview.hidden {
    display: grid !important;
    place-items: center !important;
    min-height: 118px !important;
    max-width: none !important;
    margin: 0 !important;
    border-radius: 18px !important;
    font-size: .86rem !important;
  }

  body[data-page="account"] .account-settings-page .account-password-card {
    margin-top: 20px !important;
    padding-top: 18px !important;
    border-top: 1px solid rgba(15, 23, 42, .08) !important;
  }

  body[data-page="account"] .account-settings-page .account-password-heading {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 18px !important;
    margin-bottom: 14px !important;
  }

  body[data-page="account"] .account-settings-page .compact-password-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 14px !important;
    margin-top: 0 !important;
  }

  body[data-page="account"] .account-settings-page .compact-password-grid input {
    min-height: 42px !important;
    border-radius: 12px !important;
    padding: 8px 12px !important;
  }

  body[data-page="account"] .account-settings-page .password-strength-preview {
    margin-top: 12px !important;
    display: grid !important;
    grid-template-columns: auto 1fr !important;
    gap: 8px 12px !important;
    font-size: .8rem !important;
  }

  body[data-page="account"] .account-settings-page .confirm-actions {
    position: static !important;
    inset: auto !important;
    transform: none !important;
    margin: 12px 0 0 !important;
    padding: 12px 0 0 !important;
    border-top: 1px solid rgba(15, 23, 42, .06) !important;
    display: flex !important;
    justify-content: flex-end !important;
    align-items: center !important;
    gap: 12px !important;
    flex-wrap: wrap !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .account-settings-page .confirm-actions button {
    width: auto !important;
    min-width: 150px !important;
    max-width: 100% !important;
    min-height: 42px !important;
    border-radius: 12px !important;
  }
}

@media (max-width: 768px) {
  body[data-page="account"] .account-settings-page #accountProfileMount:not(.hidden):not([hidden]) {
    padding: 18px !important;
    border-radius: 22px !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-hero,
  body[data-page="account"] .account-settings-page .account-profile-readonly-grid,
  body[data-page="account"] .account-settings-page .profile-signature-box,
  body[data-page="account"] .account-settings-page .compact-password-grid {
    grid-template-columns: 1fr !important;
  }

  body[data-page="account"] .account-settings-page .account-info-row-wide {
    width: 100% !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-picture {
    grid-template-columns: 64px minmax(0, 1fr) !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-orb {
    width: 64px !important;
    min-width: 64px !important;
    height: 64px !important;
    min-height: 64px !important;
  }
}

/* v1.0.136 final: account tabs must show one panel only; save buttons stay visible. */
body[data-page="account"] .account-settings-page [data-account-panel][hidden],
body[data-page="account"] .account-settings-page [data-account-panel].hidden,
body[data-page="account"] .account-settings-page .account-card.hidden {
  display: none !important;
}

body[data-page="account"] .account-settings-page .account-grid {
  display: block !important;
  width: 100% !important;
  overflow: visible !important;
}

body[data-page="account"] .account-settings-page [data-account-panel]:not(.hidden):not([hidden]) {
  display: block !important;
}

body[data-page="account"] .account-settings-page .account-card,
body[data-page="account"] .account-settings-page .save-confirm-panel,
body[data-page="account"] .account-settings-page #userProfileForm,
body[data-page="account"] .account-settings-page #accountProfileMount:not(.hidden):not([hidden]) {
  max-height: none !important;
  overflow: visible !important;
}

body[data-page="account"] .account-settings-page #userProfileForm {
  display: flex !important;
  flex-direction: column !important;
}

body[data-page="account"] .account-settings-page .account-password-card {
  padding-bottom: 0 !important;
}

body[data-page="account"] .account-settings-page .confirm-actions {
  position: static !important;
  inset: auto !important;
  transform: none !important;
  margin: 12px 0 0 !important;
  padding: 12px 0 0 !important;
  border-top: 1px solid rgba(15, 23, 42, .06) !important;
  display: flex !important;
  justify-content: flex-end !important;
  align-items: center !important;
  gap: 12px !important;
  flex-wrap: wrap !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-page="account"] .account-settings-page .confirm-actions .primary-button,
body[data-page="account"] .account-settings-page .confirm-actions .secondary-button {
  width: auto !important;
  min-width: 150px !important;
  max-width: 100% !important;
}

@media (max-width: 768px) {
  body[data-page="account"] .account-settings-page .confirm-actions {
    justify-content: stretch !important;
  }

  body[data-page="account"] .account-settings-page .confirm-actions .primary-button,
  body[data-page="account"] .account-settings-page .confirm-actions .secondary-button {
    width: 100% !important;
  }
}

/* v1.0.127 hard-unify the desktop sidebar typography and states on every page. */
@media (min-width: 641px) {
  body,
  button,
  input,
  select,
  textarea {
    font-family: Inter, "Noto Sans Thai", "Sarabun", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  .app-shell,
  .app-shell.loan-app,
  body[data-page] .app-shell,
  body[data-page] .app-shell.loan-app {
    grid-template-columns: 264px minmax(0, 1fr) !important;
    gap: 22px !important;
  }

  body.nav-collapsed .app-shell,
  body.nav-collapsed .app-shell.loan-app,
  body[data-page].nav-collapsed .app-shell,
  body[data-page].nav-collapsed .app-shell.loan-app {
    grid-template-columns: 88px minmax(0, 1fr) !important;
  }

  .quick-nav,
  .quick-nav.sidebar,
  .quick-nav.app-sidebar,
  body[data-page] .quick-nav,
  body[data-page] .quick-nav.sidebar,
  body[data-page] .quick-nav.app-sidebar {
    position: sticky !important;
    top: 22px !important;
    width: 264px !important;
    min-width: 264px !important;
    max-width: 264px !important;
    height: auto !important;
    min-height: calc(100vh - 44px) !important;
    max-height: calc(100vh - 44px) !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 8px !important;
    margin: 0 !important;
    padding: 16px !important;
    overflow: auto !important;
    border: 1px solid #dde8f0 !important;
    border-radius: 22px !important;
    background: #fff !important;
    color: #0f172a !important;
    box-shadow: 0 18px 42px rgba(15, 23, 42, .08) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    transform: none !important;
  }

  body.nav-collapsed .quick-nav,
  body.nav-collapsed .quick-nav.sidebar,
  body.nav-collapsed .quick-nav.app-sidebar,
  body[data-page].nav-collapsed .quick-nav,
  body[data-page].nav-collapsed .quick-nav.sidebar,
  body[data-page].nav-collapsed .quick-nav.app-sidebar {
    width: 88px !important;
    min-width: 88px !important;
    max-width: 88px !important;
    padding: 14px 12px !important;
    align-items: center !important;
  }

  .quick-nav .side-brand,
  .quick-nav .sidebar-brand,
  body[data-page] .quick-nav .side-brand,
  body[data-page] .quick-nav .sidebar-brand {
    position: relative !important;
    display: grid !important;
    grid-template-columns: 58px minmax(0, 1fr) !important;
    grid-template-areas:
      "logo eyebrow"
      "logo title" !important;
    align-items: center !important;
    column-gap: 14px !important;
    row-gap: 0 !important;
    width: 100% !important;
    min-height: 74px !important;
    margin: 0 0 16px !important;
    padding: 4px 4px 18px !important;
    border: 0 !important;
    border-bottom: 1px solid #e2e8f0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #0f172a !important;
    text-align: left !important;
  }

  .quick-nav .side-program-logo,
  body[data-page] .quick-nav .side-program-logo {
    grid-area: logo !important;
    display: grid !important;
    width: 58px !important;
    height: 58px !important;
    min-width: 58px !important;
    border-radius: 16px !important;
    place-items: center !important;
    background: linear-gradient(145deg, #19c37d, #0e9f6e) !important;
    color: #fff !important;
    font-size: 1.35rem !important;
    font-weight: 950 !important;
    box-shadow: 0 18px 30px rgba(25, 195, 125, .22) !important;
  }

  .quick-nav .side-brand > span:not(.side-program-logo),
  body[data-page] .quick-nav .side-brand > span:not(.side-program-logo) {
    grid-area: eyebrow !important;
    display: block !important;
    width: auto !important;
    height: auto !important;
    margin: 0 !important;
    color: #0f766e !important;
    font-size: .78rem !important;
    font-weight: 950 !important;
    line-height: 1.05 !important;
    letter-spacing: .16em !important;
    text-transform: uppercase !important;
    opacity: 1 !important;
    visibility: visible !important;
  }

  .quick-nav .side-brand strong,
  body[data-page] .quick-nav .side-brand strong {
    grid-area: title !important;
    display: block !important;
    width: auto !important;
    height: auto !important;
    margin: 0 !important;
    color: #0f172a !important;
    font-size: 1.28rem !important;
    font-weight: 950 !important;
    line-height: 1.1 !important;
    letter-spacing: 0 !important;
    opacity: 1 !important;
    visibility: visible !important;
  }

  .quick-nav .side-brand::before,
  .quick-nav .side-brand::after,
  body[data-page] .quick-nav .side-brand::before,
  body[data-page] .quick-nav .side-brand::after {
    display: none !important;
    content: none !important;
  }

  .nav-collapse-button,
  body[data-page] .nav-collapse-button {
    position: absolute !important;
    top: 18px !important;
    right: 18px !important;
    z-index: 4 !important;
    display: grid !important;
    width: auto !important;
    height: auto !important;
    min-width: 0 !important;
    min-height: 0 !important;
    padding: 0 !important;
    place-items: center !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    color: #0f172a !important;
    box-shadow: none !important;
    font-size: 1.2rem !important;
    font-weight: 950 !important;
    line-height: 1 !important;
  }

  .quick-nav a,
  .quick-nav button,
  .quick-nav .sidebar-link,
  .quick-nav .nav-group-toggle,
  .quick-nav .nav-text-link,
  body[data-page] .quick-nav a,
  body[data-page] .quick-nav button,
  body[data-page] .quick-nav .sidebar-link,
  body[data-page] .quick-nav .nav-group-toggle,
  body[data-page] .quick-nav .nav-text-link {
    font-family: Inter, "Noto Sans Thai", "Sarabun", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    display: grid !important;
    grid-template-columns: 34px minmax(0, 1fr) auto !important;
    align-items: center !important;
    justify-items: stretch !important;
    gap: 12px !important;
    width: 100% !important;
    min-height: 46px !important;
    margin: 0 !important;
    padding: 9px 11px !important;
    border: 1px solid transparent !important;
    border-radius: 14px !important;
    background: transparent !important;
    color: #475569 !important;
    box-shadow: none !important;
    text-align: left !important;
    text-decoration: none !important;
    font-size: .98rem !important;
    font-weight: 850 !important;
    line-height: 1.2 !important;
    letter-spacing: 0 !important;
    transform: none !important;
  }

  .quick-nav .nav-label,
  body[data-page] .quick-nav .nav-label {
    display: block !important;
    width: auto !important;
    height: auto !important;
    color: currentColor !important;
    font-size: .98rem !important;
    font-weight: 850 !important;
    line-height: 1.2 !important;
    letter-spacing: 0 !important;
    opacity: 1 !important;
    visibility: visible !important;
    white-space: normal !important;
    text-align: left !important;
  }

  .quick-nav a::before,
  .quick-nav a::after,
  .quick-nav button::before,
  .quick-nav button::after,
  .quick-nav .nav-label::before,
  .quick-nav .nav-label::after,
  body[data-page] .quick-nav a::before,
  body[data-page] .quick-nav a::after,
  body[data-page] .quick-nav button::before,
  body[data-page] .quick-nav button::after,
  body[data-page] .quick-nav .nav-label::before,
  body[data-page] .quick-nav .nav-label::after {
    display: none !important;
    content: none !important;
  }

  .quick-nav .nav-icon,
  .quick-nav .settings-gear,
  body[data-page] .quick-nav .nav-icon,
  body[data-page] .quick-nav .settings-gear {
    display: grid !important;
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    min-height: 34px !important;
    place-items: center !important;
    border-radius: 12px !important;
    background: #f1f5f9 !important;
    color: currentColor !important;
    box-shadow: none !important;
  }

  .quick-nav .nav-icon svg,
  .quick-nav .settings-gear svg,
  body[data-page] .quick-nav .nav-icon svg,
  body[data-page] .quick-nav .settings-gear svg {
    width: 20px !important;
    height: 20px !important;
    stroke-width: 1.8 !important;
  }

  .quick-nav a:hover,
  .quick-nav button:hover,
  .quick-nav .sidebar-link:hover,
  .quick-nav .nav-group-toggle:hover,
  .quick-nav .nav-text-link:hover,
  .quick-nav .sidebar-link.active,
  .quick-nav .nav-group-toggle.active,
  body[data-page] .quick-nav a:hover,
  body[data-page] .quick-nav button:hover,
  body[data-page] .quick-nav .sidebar-link:hover,
  body[data-page] .quick-nav .nav-group-toggle:hover,
  body[data-page] .quick-nav .nav-text-link:hover,
  body[data-page] .quick-nav .sidebar-link.active,
  body[data-page] .quick-nav .nav-group-toggle.active {
    border-color: #9ff3c6 !important;
    background: #eafff4 !important;
    color: #047857 !important;
    box-shadow: none !important;
    transform: none !important;
  }

  body[data-page="account"] .side-user-profile,
  body[data-page="settings"] .settings-nav-link[href="#settingsPanel"] {
    border-color: #9ff3c6 !important;
    background: #eafff4 !important;
    color: #047857 !important;
    box-shadow: none !important;
  }

  body[data-page="settings"] .side-user-profile,
  body[data-page="account"] .settings-nav-link[href="#settingsPanel"] {
    border-color: transparent !important;
    background: transparent !important;
    color: #475569 !important;
  }

  .quick-nav .nav-group,
  body[data-page] .quick-nav .nav-group {
    display: grid !important;
    gap: 8px !important;
  }

  .quick-nav .nav-group-items,
  body[data-page] .quick-nav .nav-group-items {
    display: grid !important;
    gap: 8px !important;
    margin: 0 0 0 16px !important;
    padding-left: 14px !important;
    border-left: 1px solid #e2e8f0 !important;
  }

  .quick-nav .nav-group:not(.is-open) .nav-group-items,
  body[data-page] .quick-nav .nav-group:not(.is-open) .nav-group-items {
    display: none !important;
  }

  .quick-nav .nav-chevron,
  body[data-page] .quick-nav .nav-chevron {
    display: block !important;
    margin-left: auto !important;
    color: currentColor !important;
    font-size: 1rem !important;
    font-weight: 950 !important;
    line-height: 1 !important;
  }

  .quick-nav .mobile-create-nav,
  .quick-nav > .mobile-only-nav-link,
  body[data-page] .quick-nav .mobile-create-nav,
  body[data-page] .quick-nav > .mobile-only-nav-link {
    display: none !important;
  }

  .quick-nav .side-user,
  body[data-page] .quick-nav .side-user {
    display: grid !important;
    gap: 8px !important;
    margin-top: auto !important;
    padding: 14px 0 0 !important;
    border-top: 1px solid #e2e8f0 !important;
  }

  .quick-nav .side-user-profile,
  body[data-page] .quick-nav .side-user-profile {
    display: grid !important;
    grid-template-columns: 34px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 10px !important;
    width: 100% !important;
    min-height: 46px !important;
    padding: 9px 11px !important;
    border-radius: 14px !important;
    font-size: .98rem !important;
    font-weight: 850 !important;
  }

  .quick-nav .profile-avatar,
  body[data-page] .quick-nav .profile-avatar {
    display: grid !important;
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    place-items: center !important;
    border-radius: 12px !important;
    background: #eafff4 !important;
    color: #047857 !important;
    box-shadow: none !important;
    font-size: .86rem !important;
    font-weight: 950 !important;
  }

  .quick-nav .profile-copy,
  body[data-page] .quick-nav .profile-copy {
    display: grid !important;
    gap: 0 !important;
    min-width: 0 !important;
    color: inherit !important;
  }

  .quick-nav .profile-copy span,
  body[data-page] .quick-nav .profile-copy span {
    color: #64748b !important;
    font-size: .7rem !important;
    font-weight: 800 !important;
    line-height: 1.1 !important;
  }

  .quick-nav .profile-copy strong,
  body[data-page] .quick-nav .profile-copy strong {
    color: #0f172a !important;
    font-size: .9rem !important;
    font-weight: 950 !important;
    line-height: 1.15 !important;
  }

  body.nav-collapsed .quick-nav .side-brand,
  body[data-page].nav-collapsed .quick-nav .side-brand {
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-areas: "logo" !important;
    width: 56px !important;
    min-width: 56px !important;
    max-width: 56px !important;
    padding: 0 0 16px !important;
    margin-bottom: 12px !important;
    place-items: center !important;
  }

  body.nav-collapsed .quick-nav .side-program-logo,
  body[data-page].nav-collapsed .quick-nav .side-program-logo {
    width: 56px !important;
    height: 56px !important;
    min-width: 56px !important;
  }

  body.nav-collapsed .quick-nav .side-brand > span:not(.side-program-logo),
  body.nav-collapsed .quick-nav .side-brand strong,
  body.nav-collapsed .quick-nav .nav-label,
  body.nav-collapsed .quick-nav .profile-copy,
  body.nav-collapsed .quick-nav .nav-chevron,
  body[data-page].nav-collapsed .quick-nav .side-brand > span:not(.side-program-logo),
  body[data-page].nav-collapsed .quick-nav .side-brand strong,
  body[data-page].nav-collapsed .quick-nav .nav-label,
  body[data-page].nav-collapsed .quick-nav .profile-copy,
  body[data-page].nav-collapsed .quick-nav .nav-chevron {
    display: none !important;
  }

  body.nav-collapsed .quick-nav a,
  body.nav-collapsed .quick-nav button,
  body.nav-collapsed .quick-nav .sidebar-link,
  body.nav-collapsed .quick-nav .nav-group-toggle,
  body.nav-collapsed .quick-nav .nav-text-link,
  body.nav-collapsed .quick-nav .side-user-profile,
  body[data-page].nav-collapsed .quick-nav a,
  body[data-page].nav-collapsed .quick-nav button,
  body[data-page].nav-collapsed .quick-nav .sidebar-link,
  body[data-page].nav-collapsed .quick-nav .nav-group-toggle,
  body[data-page].nav-collapsed .quick-nav .nav-text-link,
  body[data-page].nav-collapsed .quick-nav .side-user-profile {
    grid-template-columns: 1fr !important;
    justify-items: center !important;
    width: 56px !important;
    min-width: 56px !important;
    max-width: 56px !important;
    height: 56px !important;
    min-height: 56px !important;
    padding: 0 !important;
    border-radius: 16px !important;
  }

  body.nav-collapsed .quick-nav .nav-group-items,
  body[data-page].nav-collapsed .quick-nav .nav-group-items {
    margin: 0 !important;
    padding: 0 !important;
    border-left: 0 !important;
  }
}

body.auth-locked .app-shell,
body.auth-locked .app-shell.loan-app,
body.auth-locked.nav-collapsed .app-shell,
body.auth-locked.nav-collapsed .app-shell.loan-app {
  display: none !important;
}

body.auth-locked .app-shell,
body.auth-locked .app-shell.loan-app {
  display: none !important;
}

body.auth-locked .auth-screen {
  min-height: 100dvh !important;
  position: fixed !important;
  inset: 0 !important;
  z-index: 9999 !important;
}

@media (min-width: 641px) {
  body {
    padding-bottom: 0 !important;
    overflow-x: hidden !important;
    background: #f4f7fb !important;
  }

  .app-shell,
  .app-shell.loan-app {
    width: min(1600px, calc(100% - 40px)) !important;
    max-width: 1600px !important;
    min-height: 100vh !important;
    margin: 0 auto !important;
    padding: 22px 0 !important;
    display: grid !important;
    grid-template-columns: 264px minmax(0, 1fr) !important;
    gap: 22px !important;
    align-items: start !important;
  }

  body.nav-collapsed .app-shell,
  body.nav-collapsed .app-shell.loan-app {
    grid-template-columns: 88px minmax(0, 1fr) !important;
  }

  .content-shell,
  .content-shell.main-content,
  .main-content,
  .main-area {
    width: 100% !important;
    min-width: 0 !important;
    padding: 0 !important;
  }

  body:not([data-page="dashboard"]) #dashboardPanel,
  #dashboardPanel.hidden {
    display: none !important;
  }

  body[data-page="dashboard"] #dashboardPanel:not(.hidden) {
    display: grid !important;
  }

  .quick-nav,
  .quick-nav.sidebar,
  .quick-nav.app-sidebar,
  body[data-page="dashboard"] .quick-nav,
  body[data-page="settings"] .quick-nav,
  body[data-page="account"] .quick-nav,
  body[data-page="leads"] .quick-nav,
  body[data-page="lineoa"] .quick-nav,
  body[data-records-subview="history"] .quick-nav,
  body[data-records-subview="customerProfiles"] .quick-nav {
    position: sticky !important;
    inset: auto !important;
    top: 22px !important;
    width: 264px !important;
    min-width: 264px !important;
    max-width: 264px !important;
    flex: 0 0 264px !important;
    height: auto !important;
    min-height: calc(100vh - 44px) !important;
    max-height: calc(100vh - 44px) !important;
    display: flex !important;
    grid-template-columns: none !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 8px !important;
    padding: 16px !important;
    overflow: auto !important;
    border: 1px solid #dde8f0 !important;
    border-radius: 22px !important;
    background: #ffffff !important;
    color: #0f172a !important;
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08) !important;
    transform: none !important;
    opacity: 1 !important;
    visibility: visible !important;
  }

  body.nav-collapsed .quick-nav,
  body.nav-collapsed .quick-nav.sidebar,
  body.nav-collapsed .quick-nav.app-sidebar {
    width: 88px !important;
    min-width: 88px !important;
    max-width: 88px !important;
    flex: 0 0 88px !important;
    padding: 14px 12px !important;
    align-items: center !important;
    overflow-x: hidden !important;
  }

  .quick-nav * {
    color: inherit !important;
  }

  .quick-nav .side-brand,
  .quick-nav .sidebar-brand {
    display: grid !important;
    gap: 4px !important;
    padding: 4px 4px 16px !important;
    margin: 0 0 8px !important;
    border-bottom: 1px solid #e2e8f0 !important;
  }

  .side-brand > span:not(.side-program-logo),
  .side-brand strong,
  .quick-nav .nav-label,
  .quick-nav a .nav-label,
  .quick-nav button .nav-label,
  .profile-copy,
  .nav-chevron {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
    width: auto !important;
    height: auto !important;
    max-width: 100% !important;
    color: inherit !important;
    font-size: inherit !important;
    line-height: inherit !important;
    white-space: normal !important;
    overflow: visible !important;
  }

  .quick-nav .nav-label::before,
  .quick-nav .nav-label::after,
  .quick-nav a::before,
  .quick-nav a::after,
  .quick-nav button::before,
  .quick-nav button::after {
    display: none !important;
    content: none !important;
  }

  .quick-nav a,
  .quick-nav .sidebar-link,
  .quick-nav .nav-group-toggle {
    width: 100% !important;
    min-height: 46px !important;
    display: grid !important;
    grid-template-columns: 34px minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 10px !important;
    padding: 9px 11px !important;
    border: 1px solid transparent !important;
    border-radius: 14px !important;
    background: transparent !important;
    color: #475569 !important;
    text-align: left !important;
    text-decoration: none !important;
    font-size: 0.93rem !important;
    font-weight: 850 !important;
    line-height: 1.2 !important;
    transform: none !important;
    box-shadow: none !important;
  }

  .quick-nav a:hover,
  .quick-nav .nav-group-toggle:hover,
  .quick-nav a.active,
  .quick-nav .sidebar-link.active {
    border-color: #bbf7d0 !important;
    background: #dcfce7 !important;
    color: #047857 !important;
  }

  .quick-nav .nav-icon,
  .nav-icon {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 12px !important;
    background: #f1f5f9 !important;
    color: currentColor !important;
  }

  .quick-nav .mobile-create-nav,
  .quick-nav > .mobile-only-nav-link {
    display: none !important;
  }

  .nav-group,
  .nav-group-items {
    display: grid !important;
    gap: 8px !important;
  }

  .nav-group-items {
    padding-left: 14px !important;
    margin-left: 16px !important;
    border-left: 1px solid #e2e8f0 !important;
  }

  .quick-nav .nav-group:not(.is-open) .nav-group-items {
    display: none !important;
  }

  .quick-nav .nav-group.is-open .nav-group-items {
    display: grid !important;
  }

  .quick-nav .nav-group:not(.is-open) .nav-chevron {
    transform: rotate(-90deg) !important;
  }

  .quick-nav .nav-group.is-open .nav-chevron {
    transform: rotate(0deg) !important;
  }

  .side-user {
    display: grid !important;
    gap: 8px !important;
    margin-top: auto !important;
    padding-top: 14px !important;
    border-top: 1px solid #e2e8f0 !important;
  }

  body.nav-collapsed .quick-nav .side-brand strong,
  body.nav-collapsed .quick-nav .side-brand > span:not(.side-program-logo),
  body.nav-collapsed .quick-nav .nav-label,
  body.nav-collapsed .quick-nav .profile-copy,
  body.nav-collapsed .quick-nav .nav-chevron {
    display: none !important;
  }

  body.nav-collapsed .quick-nav a,
  body.nav-collapsed .quick-nav .sidebar-link,
  body.nav-collapsed .quick-nav .nav-group-toggle {
    grid-template-columns: 1fr !important;
    justify-items: center !important;
    width: 56px !important;
    min-width: 56px !important;
    max-width: 56px !important;
    height: 56px !important;
    min-height: 56px !important;
    padding: 0 !important;
    border-radius: 16px !important;
  }

  body.nav-collapsed .quick-nav .nav-group-items {
    display: none !important;
  }

  body.nav-collapsed .quick-nav .nav-group,
  body.nav-collapsed .quick-nav .side-user {
    align-items: center !important;
    width: 56px !important;
    min-width: 56px !important;
    max-width: 56px !important;
  }

  body.nav-collapsed .quick-nav .side-brand,
  body.nav-collapsed .quick-nav .sidebar-brand {
    width: 56px !important;
    min-width: 56px !important;
    max-width: 56px !important;
    padding: 0 0 14px !important;
    place-items: center !important;
  }

  body.nav-collapsed .quick-nav .nav-collapse-button {
    width: 44px !important;
    height: 44px !important;
    min-width: 44px !important;
    min-height: 44px !important;
    margin: 0 auto 10px !important;
  }

  .nav-collapse-button {
    display: grid !important;
  }

  .app-topbar,
  .app-topbar.page-header,
  .app-topbar.topbar {
    position: sticky !important;
    top: 0 !important;
    z-index: 12 !important;
    display: grid !important;
    grid-template-columns: minmax(210px, 0.8fr) minmax(280px, 1.2fr) auto !important;
    align-items: center !important;
    gap: 16px !important;
    margin: 0 0 18px !important;
    padding: 16px 18px !important;
    border: 1px solid #dde8f0 !important;
    border-radius: 22px !important;
    background: rgba(255, 255, 255, 0.94) !important;
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.07) !important;
    backdrop-filter: blur(14px) !important;
  }

  .app-topbar h1 {
    margin: 0 !important;
    color: #0f172a !important;
    font-size: clamp(1.45rem, 2vw, 2rem) !important;
    line-height: 1.12 !important;
  }

  .global-search,
  .search-box {
    margin: 0 !important;
  }

  .global-search input,
  .search-box input {
    min-height: 48px !important;
    margin: 0 !important;
    border-radius: 16px !important;
    background: #f8fafc !important;
  }

  .topbar-actions,
  .header-actions {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
  }

  .panel,
  .hero-card,
  .summary-tile,
  .dashboard-chart-card,
  .records-table-wrap,
  .simple-table-wrap,
  .customer-profile-table-wrap,
  .payment-table-wrap {
    border-color: #dde8f0 !important;
    border-radius: 22px !important;
    background: #ffffff !important;
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.06) !important;
  }

  .panel {
    width: 100% !important;
    max-width: none !important;
    padding: 24px !important;
    position: relative !important;
  }

  .panel-title,
  .tracking-panel .panel-title,
  .lineoa-panel .panel-title,
  .history-panel .panel-title,
  .settings-panel .panel-title {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 18px !important;
    margin-bottom: 20px !important;
  }

  .panel-title h2 {
    margin: 0 0 4px !important;
    color: #0f172a !important;
    font-size: clamp(1.35rem, 1.8vw, 1.9rem) !important;
    line-height: 1.12 !important;
  }

  .panel-title p {
    max-width: 720px !important;
    color: #64748b !important;
    font-size: 0.95rem !important;
    line-height: 1.45 !important;
  }

  .button-row,
  .backup-actions,
  .tracking-actions,
  .history-actions,
  .payment-actions-cell,
  .confirm-actions {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 10px !important;
  }

  .primary-button,
  .secondary-button,
  .records-subnav-button,
  .slip-link-button,
  .custom-payment-button,
  .info-button {
    min-height: 42px !important;
    border-radius: 14px !important;
    padding: 9px 14px !important;
    font-size: 0.9rem !important;
    line-height: 1.15 !important;
    white-space: nowrap !important;
  }

  .dashboard-page {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 16px !important;
    padding-bottom: 28px !important;
  }

  .dashboard-hero {
    order: 2 !important;
    display: block !important;
    padding: 16px 18px !important;
    border-radius: 18px !important;
  }

  .dashboard-hero > div:first-child,
  .dashboard-menu-section,
  #dashboardMenuUsage,
  .dashboard-chart-card:has(#dashboardMenuUsage) {
    display: none !important;
  }

  .dashboard-filters {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: end !important;
    justify-content: flex-start !important;
    gap: 12px !important;
    max-width: none !important;
    text-align: left !important;
  }

  .dashboard-filters label {
    width: auto !important;
    min-width: 190px !important;
    max-width: 240px !important;
    margin: 0 !important;
  }

  .dashboard-filters label:first-child {
    min-width: 220px !important;
  }

  .dashboard-filters span {
    display: block !important;
    margin: 0 0 6px !important;
    color: #64748b !important;
    font-size: 0.82rem !important;
    font-weight: 800 !important;
  }

  .dashboard-filters select,
  .dashboard-filters input {
    min-height: 42px !important;
    margin: 0 !important;
    border-radius: 14px !important;
    background: #f8fafc !important;
  }

  .dashboard-menu-grid {
    display: none !important;
  }

  .dashboard-work-panel {
    order: 1 !important;
    min-height: 118px !important;
    margin: 0 !important;
    padding: 22px 24px !important;
    border-radius: 20px !important;
  }

  .dashboard-work-panel > div {
    display: grid !important;
    gap: 4px !important;
  }

  .dashboard-work-kicker {
    font-size: 0.84rem !important;
    letter-spacing: 0 !important;
  }

  .dashboard-work-panel strong {
    font-size: clamp(1.65rem, 2.7vw, 2.35rem) !important;
    line-height: 1.05 !important;
  }

  .dashboard-work-panel small {
    font-size: 0.95rem !important;
  }

  #dashboardPanel > .summary-grid {
    order: 3 !important;
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 12px !important;
    margin: 0 !important;
  }

  #dashboardPanel > .summary-grid .summary-tile,
  #dashboardPanel > .summary-grid .summary-tile:nth-child(n) {
    display: grid !important;
    align-content: center !important;
    min-height: 116px !important;
    padding: 18px 20px !important;
    border-radius: 18px !important;
  }

  #dashboardPanel > .summary-grid .summary-tile:nth-child(n + 5) {
    min-height: 96px !important;
    background: #fbfdff !important;
  }

  #dashboardPanel > .summary-grid .summary-tile span,
  #dashboardPanel > .summary-grid .summary-tile small {
    font-size: 0.9rem !important;
  }

  #dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(2.2rem, 3.8vw, 3.4rem) !important;
    line-height: 1 !important;
    letter-spacing: 0 !important;
  }

  #dashboardPanel > .summary-grid .summary-tile:nth-child(n + 5) strong {
    font-size: clamp(1.65rem, 2.5vw, 2.35rem) !important;
  }

  .dashboard-analytics-grid {
    order: 4 !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1.65fr) minmax(300px, 0.85fr) !important;
    gap: 16px !important;
  }

  .dashboard-chart-main {
    grid-row: span 2 !important;
    min-height: 360px !important;
  }

  .dashboard-chart-card {
    min-height: 220px !important;
    padding: 22px !important;
    border-radius: 18px !important;
  }

  .dashboard-chart-head {
    margin-bottom: 14px !important;
  }

  .dashboard-chart-head h3 {
    font-size: 1.15rem !important;
  }

  .dashboard-chart-head small {
    font-size: 0.88rem !important;
  }

  .mobile-debtor-list,
  .tracking-mobile-list,
  .customer-profile-mobile-list,
  .payment-installment-accordion-list,
  .contract-schedule-mobile-toggle,
  .mobile-fab-new-loan,
  .mobile-action-menu,
  .mobile-action-backdrop {
    display: none !important;
  }

  .records-table-wrap,
  .simple-table-wrap,
  .customer-profile-table-wrap,
  .payment-table-wrap {
    display: block !important;
    width: 100% !important;
    overflow: auto !important;
  }

  .records-table {
    min-width: min(760px, 100%) !important;
    width: 100% !important;
    table-layout: auto !important;
  }

  .records-detail-panel {
    padding: 18px 22px 22px !important;
    background: linear-gradient(180deg, #f8fbff 0%, #f4f8fd 100%) !important;
  }

  .records-detail-layout {
    grid-template-columns: minmax(360px, 1fr) minmax(300px, 410px) !important;
    align-items: start !important;
    gap: 22px !important;
  }

  .records-detail-summary,
  .records-detail-action-panel {
    min-width: 0 !important;
    border: 1px solid #dde8f0 !important;
    border-radius: 20px !important;
    background: rgba(255, 255, 255, 0.82) !important;
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.045) !important;
    padding: 16px !important;
  }

  .records-detail-section-title {
    margin-bottom: 12px !important;
    color: #0f7d66 !important;
    font-size: 0.82rem !important;
    font-weight: 950 !important;
    letter-spacing: 0 !important;
  }

  .records-detail-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 10px !important;
  }

  .records-detail-grid div {
    min-height: 78px !important;
    display: grid !important;
    align-content: center !important;
    gap: 6px !important;
    padding: 14px !important;
    border-radius: 16px !important;
    border: 1px solid #e1eaf2 !important;
    background: #ffffff !important;
  }

  .records-detail-grid strong {
    flex: none !important;
    color: #64748b !important;
    font-size: 0.76rem !important;
    font-weight: 900 !important;
    white-space: normal !important;
  }

  .records-detail-grid span {
    color: #0f172a !important;
    font-size: 0.92rem !important;
    font-weight: 950 !important;
    line-height: 1.25 !important;
  }

  .records-detail-actions {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 10px !important;
    align-items: stretch !important;
    justify-items: stretch !important;
  }

  .records-detail-actions .secondary-button,
  .records-detail-actions .danger-button {
    width: 100% !important;
    min-width: 0 !important;
    min-height: 88px !important;
    aspect-ratio: 1 / 1 !important;
    padding: 12px 8px 10px !important;
    border-radius: 16px !important;
    display: grid !important;
    grid-template-rows: 32px minmax(0, auto) !important;
    place-items: center !important;
    gap: 7px !important;
    border: 1px solid #dde8f0 !important;
    background: #ffffff !important;
    color: #0f172a !important;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06) !important;
    font-size: 0.82rem !important;
    font-weight: 950 !important;
    line-height: 1.2 !important;
    text-align: center !important;
    white-space: normal !important;
  }

  .records-detail-actions .secondary-button::before,
  .records-detail-actions .danger-button::before {
    content: "";
    width: 32px;
    height: 32px;
    border-radius: 12px;
    display: block;
    background-color: #e9fff4;
    background-position: center;
    background-repeat: no-repeat;
    background-size: 19px 19px;
    box-shadow: inset 0 0 0 1px rgba(16, 185, 129, 0.14);
  }

  .records-detail-actions [data-action="payment"] {
    background: linear-gradient(180deg, #11bd82 0%, #0fa875 100%) !important;
    color: #ffffff !important;
    border-color: rgba(16, 185, 129, 0.28) !important;
    box-shadow: 0 16px 30px rgba(16, 185, 129, 0.18) !important;
    grid-column: auto !important;
  }

  .records-detail-actions [data-action="payment"]::before {
    background-color: rgba(255, 255, 255, 0.18);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.24);
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 8.5h12A2.5 2.5 0 0 1 20.5 11v5A2.5 2.5 0 0 1 18 18.5H6A2.5 2.5 0 0 1 3.5 16v-5A2.5 2.5 0 0 1 6 8.5Zm1.5-3h9' stroke='white' stroke-width='2' stroke-linecap='round'/%3E%3Cpath d='M16 14h.01' stroke='white' stroke-width='3' stroke-linecap='round'/%3E%3C/svg%3E");
  }

  .records-detail-actions [data-action="lineReminder"]::before {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5 7.5A3.5 3.5 0 0 1 8.5 4h7A3.5 3.5 0 0 1 19 7.5v4A3.5 3.5 0 0 1 15.5 15H12l-4.5 3v-3A3.5 3.5 0 0 1 4 11.5v-4Z' stroke='%23047f66' stroke-width='2' stroke-linejoin='round'/%3E%3Cpath d='M8.5 9.5h.01M12 9.5h.01M15.5 9.5h.01' stroke='%23047f66' stroke-width='2.5' stroke-linecap='round'/%3E%3C/svg%3E");
  }

  .records-detail-actions [data-action="view"]::before {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 3.5h7l3 3v14H7a2 2 0 0 1-2-2v-13a2 2 0 0 1 2-2Z' stroke='%23047f66' stroke-width='2' stroke-linejoin='round'/%3E%3Cpath d='M14 3.5v4h4M8.5 12h7M8.5 15.5h5' stroke='%23047f66' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
  }

  .records-detail-actions [data-action="edit"]::before {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m5 16.5-.5 3 3-.5L18 8.5 15.5 6 5 16.5Z' stroke='%23047f66' stroke-width='2' stroke-linejoin='round'/%3E%3Cpath d='m14.5 7 2.5 2.5' stroke='%23047f66' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
  }

  .records-detail-actions [data-action="refinance"]::before {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 8h8.5a3.5 3.5 0 0 1 0 7H6' stroke='%23047f66' stroke-width='2' stroke-linecap='round'/%3E%3Cpath d='m9 5-3 3 3 3M15 19l3-3-3-3' stroke='%23047f66' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  }

  .records-detail-actions [data-action="history"]::before {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5 12a7 7 0 1 0 2-4.9L5 9' stroke='%23047f66' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M12 8v4l3 2' stroke='%23047f66' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
  }

  .records-detail-actions [data-action="closeContract"]::before {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 10V8a5 5 0 0 1 10 0v2M6.5 10h11A1.5 1.5 0 0 1 19 11.5v7A1.5 1.5 0 0 1 17.5 20h-11A1.5 1.5 0 0 1 5 18.5v-7A1.5 1.5 0 0 1 6.5 10Z' stroke='%23047f66' stroke-width='2' stroke-linejoin='round'/%3E%3Cpath d='m9.5 15 1.8 1.8 3.7-3.7' stroke='%23047f66' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  }

  .records-detail-actions [data-action="delete"] {
    color: #e54848 !important;
    border-color: #ffd0d0 !important;
    background: #fff9f9 !important;
    box-shadow: none !important;
  }

  .records-detail-actions [data-action="delete"]::before {
    background-color: #fff1f1;
    box-shadow: inset 0 0 0 1px rgba(239, 68, 68, 0.14);
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5 7h14M10 11v6M14 11v6M8 7l.5 13h7L16 7M9.5 7l.7-2h3.6l.7 2' stroke='%23e54848' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  }

  .records-detail-actions .secondary-button:disabled {
    opacity: 0.48 !important;
    box-shadow: none !important;
  }

  .simple-table,
  .customer-profile-table {
    min-width: 920px !important;
  }

  .payment-table {
    min-width: 980px !important;
  }

  thead th,
  .records-table thead th,
  .simple-table th,
  .customer-profile-table th,
  .payment-table th {
    position: sticky !important;
    top: 0 !important;
    z-index: 1 !important;
    padding: 13px 14px !important;
    color: #475569 !important;
    background: #f8fafc !important;
    font-size: 0.82rem !important;
    font-weight: 950 !important;
    text-align: left !important;
    white-space: nowrap !important;
  }

  tbody td,
  .records-table td,
  .simple-table td,
  .customer-profile-table td,
  .payment-table td {
    padding: 13px 14px !important;
    color: #0f172a !important;
    font-size: 0.9rem !important;
    vertical-align: middle !important;
  }

  .records-subnav {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    padding: 8px !important;
    margin-bottom: 16px !important;
  }

  .mini-summary-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 12px !important;
  }

  .tracking-panel .panel-title .button-row {
    display: grid !important;
    grid-template-columns: minmax(260px, 360px) 190px !important;
    align-items: end !important;
  }

  .settings-sections {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 14px !important;
    align-items: start !important;
  }

  .settings-box {
    min-height: 116px !important;
    border: 1px solid #dde8f0 !important;
    border-radius: 18px !important;
    background: #ffffff !important;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.05) !important;
    overflow: hidden !important;
  }

  .settings-box > summary {
    min-height: 116px !important;
    display: grid !important;
    grid-template-columns: 54px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 12px !important;
    padding: 18px !important;
    cursor: pointer !important;
    list-style: none !important;
    font-size: 1rem !important;
    font-weight: 950 !important;
  }

  .settings-box[open] {
    grid-column: 1 / -1 !important;
    min-height: 0 !important;
  }

  .settings-grid,
  .settings-box[open] .settings-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 14px !important;
    padding: 18px !important;
  }

  .full-field {
    grid-column: 1 / -1 !important;
  }

  .payment-page-modal,
  .save-confirm,
  .print-preview,
  .form-modal {
    place-items: center !important;
    padding: 28px !important;
  }

  .payment-page-panel,
  .save-confirm-panel,
  .print-preview-panel,
  .loan-form-dialog {
    width: min(1240px, 100%) !important;
    max-height: min(90vh, 900px) !important;
    padding: 26px !important;
    border-radius: 24px !important;
    background: #ffffff !important;
    box-shadow: 0 30px 90px rgba(15, 23, 42, 0.26) !important;
  }

  .save-confirm-panel {
    width: min(780px, 100%) !important;
  }

  .payment-page-bottom-actions {
    display: none !important;
  }

  .bulk-payment-bar {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 14px !important;
    margin: 0 0 16px !important;
    padding: 16px !important;
    border: 1px solid #bfdbfe !important;
    border-radius: 18px !important;
    background: #f0f9ff !important;
  }

  .payment-contract-summary {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 12px !important;
    margin-top: 16px !important;
  }

  .payment-table tr.payment-row-locked td {
    background: #f4f7fb !important;
    color: #94a3b8 !important;
  }

  .payment-table tr.payment-row-paid td {
    background: #f1f5f9 !important;
    color: #64748b !important;
  }

  .confirm-actions {
    border-top: 1px solid #e2e8f0 !important;
    padding-top: 16px !important;
    margin-top: 18px !important;
  }

  .panel-close-button,
  #recordsPanel > .panel-close-button,
  #customerProfilesPanel > .panel-close-button,
  #lineLeadsPanel > .panel-close-button,
  #lineOaPanel > .panel-close-button,
  #trackingPanel > .panel-close-button,
  #historyPanel > .panel-close-button,
  #settingsPanel > .panel-close-button,
  #accountPanel > .panel-close-button {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }
}

body.loan-form-open .quick-nav,
body.loan-form-open .quick-nav.sidebar,
body.loan-form-open .quick-nav.app-sidebar {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

body.loan-form-open #loanFormModal.form-modal,
#loanFormModal.form-modal:not(.hidden) {
  z-index: 4200 !important;
}

body.loan-form-open #loanFormModal .loan-form-dialog {
  position: relative !important;
  z-index: 4201 !important;
}

@media (min-width: 641px) {
  body.loan-form-open #loanFormModal.form-modal {
    display: grid !important;
    place-items: center !important;
    padding: 28px !important;
  }

  body.loan-form-open {
    overflow: hidden !important;
  }

  #loanFormModal.form-modal:not(.hidden) {
    display: grid !important;
    place-items: center !important;
    padding: 30px !important;
    background: rgba(15, 23, 42, 0.58) !important;
  }

  #loanFormModal .loan-form-dialog {
    width: min(1040px, calc(100vw - 72px)) !important;
    max-height: calc(100vh - 72px) !important;
    min-height: 0 !important;
    display: grid !important;
    grid-template-rows: auto auto minmax(0, 1fr) auto !important;
    overflow: hidden !important;
    padding: 0 !important;
    border: 1px solid #dbe7f0 !important;
    border-radius: 28px !important;
    background: #ffffff !important;
    box-shadow: 0 36px 100px rgba(15, 23, 42, 0.34) !important;
  }

  #loanFormModal .panel-title {
    position: relative !important;
    z-index: 2 !important;
    margin: 0 !important;
    padding: 24px 30px 14px !important;
    border-bottom: 1px solid #e3edf5 !important;
    background: #ffffff !important;
  }

  #loanFormModal .panel-title h2 {
    font-size: 1.5rem !important;
    line-height: 1.15 !important;
  }

  #loanFormModal .panel-title p {
    margin-top: 4px !important;
    font-size: 0.92rem !important;
  }

  #loanFormModal .loan-stepper {
    margin: 0 !important;
    padding: 12px 30px !important;
    border-bottom: 1px solid #e3edf5 !important;
    background: #f8fbff !important;
  }

  #loanFormModal .form-block {
    min-height: 0 !important;
    margin: 0 !important;
    padding: 22px 30px 24px !important;
    overflow: auto !important;
    border: 0 !important;
    border-left: 0 !important;
    border-radius: 0 !important;
    background: #ffffff !important;
    box-shadow: none !important;
  }

  #loanFormModal .form-block::before,
  #loanFormModal #customerSection::before,
  #loanFormModal #loanSection::before {
    display: none !important;
  }

  #loanFormModal #customerSection,
  #loanFormModal #loanSection {
    border-left: 0 !important;
  }

  #loanFormModal .block-heading {
    align-items: center !important;
    margin: 0 0 18px !important;
    padding: 14px 16px !important;
    border: 1px solid #dce8f1 !important;
    border-radius: 18px !important;
    background: #f8fbff !important;
  }

  #loanFormModal .block-heading > span {
    width: 38px !important;
    height: 38px !important;
    border-radius: 14px !important;
    background: #e5fff4 !important;
    color: #078061 !important;
  }

  #loanFormModal .block-heading h3 {
    font-size: 1.05rem !important;
  }

  #loanFormModal .field-grid {
    gap: 14px !important;
  }

  #loanFormModal .customer-meta-grid,
  #loanFormModal .customer-identity-grid,
  #loanFormModal .address-official-grid,
  #loanFormModal .address-subgrid,
  #loanFormModal .loan-term-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  #loanFormModal .customer-name-field,
  #loanFormModal .line-id-field,
  #loanFormModal .line-user-id-field {
    grid-column: auto !important;
  }

  #loanFormModal label {
    margin-bottom: 14px !important;
    min-width: 0 !important;
  }

  #loanFormModal label > span,
  #loanFormModal .line-heading {
    color: #64748b !important;
    font-size: 0.88rem !important;
    font-weight: 900 !important;
  }

  #loanFormModal input,
  #loanFormModal select,
  #loanFormModal textarea {
    min-height: 48px !important;
    border-radius: 16px !important;
    border-color: #cbd8e5 !important;
    font-size: 0.96rem !important;
  }

  #loanFormModal textarea {
    min-height: 118px !important;
  }

  #loanFormModal input[type="file"] {
    padding: 10px !important;
    background: #f8fbff !important;
  }

  #loanFormModal .attachment-preview {
    max-width: 520px !important;
    margin-top: 10px !important;
    padding: 12px !important;
    border-radius: 18px !important;
    border-color: #dce8f1 !important;
    background: #f8fbff !important;
  }

  #loanFormModal .attachment-preview img {
    width: 100% !important;
    max-width: 420px !important;
    max-height: 220px !important;
    object-fit: contain !important;
    object-position: center !important;
    border-radius: 14px !important;
    background: #eef4f8 !important;
  }

  #loanFormModal .loan-form-actions {
    position: sticky !important;
    bottom: 0 !important;
    z-index: 4 !important;
    margin: 0 !important;
    padding: 16px 30px !important;
    border-top: 1px solid #e3edf5 !important;
    background: rgba(255, 255, 255, 0.98) !important;
    backdrop-filter: blur(14px) !important;
    display: grid !important;
    grid-template-columns: minmax(220px, 320px) minmax(160px, 220px) !important;
    justify-content: end !important;
    align-items: center !important;
    gap: 12px !important;
  }

  #loanFormModal .loan-form-actions .primary-button,
  #loanFormModal .loan-form-actions .secondary-button {
    width: 100% !important;
    min-height: 52px !important;
    margin: 0 !important;
    border-radius: 18px !important;
    font-size: 0.96rem !important;
    font-weight: 950 !important;
  }

  #loanFormModal .loan-form-actions #backToCustomer:not(.hidden) {
    grid-column: auto !important;
  }

  #loanFormModal .loan-form-actions #saveContract {
    order: 1 !important;
  }

  #loanFormModal .loan-form-actions #closeLoanForm {
    order: 2 !important;
    background: #fff7f7 !important;
    color: #b91c1c !important;
    border-color: #fecaca !important;
  }
}

@media (min-width: 641px) {
  .app-shell,
  .app-shell.loan-app {
    width: min(1520px, calc(100% - 36px)) !important;
    grid-template-columns: 238px minmax(0, 1fr) !important;
    gap: 18px !important;
  }

  body.nav-collapsed .app-shell,
  body.nav-collapsed .app-shell.loan-app {
    grid-template-columns: 78px minmax(0, 1fr) !important;
  }

  .quick-nav,
  .quick-nav.sidebar,
  .quick-nav.app-sidebar,
  body[data-page="dashboard"] .quick-nav,
  body[data-page="settings"] .quick-nav,
  body[data-page="account"] .quick-nav,
  body[data-page="leads"] .quick-nav,
  body[data-page="lineoa"] .quick-nav,
  body[data-records-subview="history"] .quick-nav,
  body[data-records-subview="customerProfiles"] .quick-nav {
    width: 238px !important;
    min-width: 238px !important;
    max-width: 238px !important;
    flex-basis: 238px !important;
    padding: 14px !important;
    gap: 6px !important;
    border-radius: 18px !important;
    background: #ffffff !important;
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.07) !important;
  }

  body.nav-collapsed .quick-nav,
  body.nav-collapsed .quick-nav.sidebar,
  body.nav-collapsed .quick-nav.app-sidebar {
    width: 78px !important;
    min-width: 78px !important;
    max-width: 78px !important;
    flex-basis: 78px !important;
    padding: 12px 10px !important;
    overflow: visible !important;
  }

  .quick-nav .side-brand,
  .quick-nav .sidebar-brand {
    position: relative !important;
    display: grid !important;
    grid-template-columns: 42px minmax(0, 1fr) !important;
    align-items: center !important;
    column-gap: 10px !important;
    row-gap: 0 !important;
    min-height: 58px !important;
    padding: 4px 48px 14px 2px !important;
    margin: 0 0 10px !important;
    border-bottom: 1px solid #e6edf4 !important;
  }

  .quick-nav .side-program-logo {
    display: none !important;
  }

  .quick-nav .side-brand::before,
  .quick-nav .sidebar-brand::before {
    content: "฿" !important;
    grid-row: 1 / span 2 !important;
    width: 40px !important;
    height: 40px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 12px !important;
    background: linear-gradient(145deg, #12b981, #0f8f71) !important;
    color: #ffffff !important;
    font-size: 1.28rem !important;
    font-weight: 900 !important;
    box-shadow: 0 10px 22px rgba(16, 185, 129, 0.22) !important;
  }

  .quick-nav .side-brand > span:not(.side-program-logo) {
    margin: 0 !important;
    color: #0f766e !important;
    font-size: 0.72rem !important;
    font-weight: 900 !important;
    letter-spacing: 0.08em !important;
    text-transform: uppercase !important;
    line-height: 1 !important;
  }

  .quick-nav .side-brand strong {
    margin: 3px 0 0 !important;
    color: #0f172a !important;
    font-size: 1rem !important;
    font-weight: 900 !important;
    line-height: 1.15 !important;
  }

  .nav-collapse-button {
    position: absolute !important;
    top: 18px !important;
    right: 16px !important;
    width: 24px !important;
    height: 24px !important;
    min-width: 24px !important;
    min-height: 24px !important;
    padding: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    border: 0 !important;
    color: #0f172a !important;
    box-shadow: none !important;
    z-index: 5 !important;
  }

  .nav-collapse-button span {
    font-size: 1.12rem !important;
    line-height: 1 !important;
  }

  .quick-nav a,
  .quick-nav .sidebar-link,
  .quick-nav .nav-group-toggle {
    min-height: 44px !important;
    padding: 8px 10px !important;
    border-radius: 13px !important;
    font-size: 0.9rem !important;
    font-weight: 800 !important;
    color: #475569 !important;
    gap: 10px !important;
  }

  .quick-nav .nav-icon,
  .nav-icon {
    width: 30px !important;
    height: 30px !important;
    min-width: 30px !important;
    border-radius: 10px !important;
    background: #f1f5f9 !important;
    color: #475569 !important;
  }

  .quick-nav a.active,
  .quick-nav .sidebar-link.active {
    background: #ecfdf5 !important;
    border-color: #a7f3d0 !important;
    color: #047857 !important;
  }

  .quick-nav a.active .nav-icon,
  .quick-nav .sidebar-link.active .nav-icon {
    background: #d1fae5 !important;
    color: #047857 !important;
  }

  .nav-group-items {
    gap: 4px !important;
    margin-left: 14px !important;
    padding-left: 12px !important;
  }

  .side-user {
    gap: 6px !important;
    padding-top: 12px !important;
  }

  .side-user-profile {
    min-height: 44px !important;
    padding: 7px 8px !important;
    border-radius: 14px !important;
  }

  .profile-avatar {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    border-radius: 10px !important;
    background: #ecfdf5 !important;
    color: #047857 !important;
    font-size: 0.82rem !important;
    box-shadow: none !important;
  }

  .profile-copy span {
    font-size: 0.72rem !important;
    color: #64748b !important;
  }

  .profile-copy strong {
    font-size: 0.9rem !important;
    color: #0f172a !important;
  }

  body.nav-collapsed .quick-nav .side-brand,
  body.nav-collapsed .quick-nav .sidebar-brand {
    width: 48px !important;
    min-width: 48px !important;
    max-width: 48px !important;
    grid-template-columns: 1fr !important;
    padding: 4px 0 10px !important;
    margin-bottom: 4px !important;
    place-items: center !important;
  }

  body.nav-collapsed .quick-nav .side-brand::before,
  body.nav-collapsed .quick-nav .sidebar-brand::before {
    width: 38px !important;
    height: 38px !important;
  }

  body.nav-collapsed .quick-nav a,
  body.nav-collapsed .quick-nav .sidebar-link,
  body.nav-collapsed .quick-nav .nav-group-toggle,
  body.nav-collapsed .quick-nav .nav-group,
  body.nav-collapsed .quick-nav .side-user {
    width: 48px !important;
    min-width: 48px !important;
    max-width: 48px !important;
  }

  body.nav-collapsed .quick-nav a,
  body.nav-collapsed .quick-nav .sidebar-link,
  body.nav-collapsed .quick-nav .nav-group-toggle {
    height: 48px !important;
    min-height: 48px !important;
  }

  body.nav-collapsed .quick-nav .nav-collapse-button {
    position: absolute !important;
    top: 9px !important;
    right: 7px !important;
    order: initial !important;
    width: 18px !important;
    height: 18px !important;
    min-width: 18px !important;
    min-height: 18px !important;
    margin: 0 !important;
    padding: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    border: 0 !important;
    color: #047857 !important;
    box-shadow: none !important;
  }

  body.nav-collapsed .quick-nav .nav-collapse-button span {
    transform: none !important;
    font-size: 0.8rem !important;
    line-height: 1 !important;
  }

  body[data-page="dashboard"] #dashboardPanel:not(.hidden) {
    gap: 14px !important;
  }

  .dashboard-hero {
    padding: 14px 16px !important;
    border-radius: 16px !important;
    box-shadow: none !important;
  }

  .dashboard-work-panel {
    min-height: 104px !important;
    padding: 20px 22px !important;
    border: 1px solid #bbf7d0 !important;
    background: linear-gradient(135deg, #f0fdf4, #ffffff) !important;
    box-shadow: none !important;
  }

  .dashboard-work-panel strong {
    font-size: clamp(1.45rem, 2.25vw, 2.05rem) !important;
  }

  #dashboardPanel > .summary-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 12px !important;
  }

  #dashboardPanel > .summary-grid .summary-tile,
  #dashboardPanel > .summary-grid .summary-tile:nth-child(n) {
    min-height: 108px !important;
    padding: 16px 18px !important;
    border-radius: 16px !important;
    box-shadow: none !important;
  }

  #dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(1.95rem, 3vw, 2.85rem) !important;
  }

  #dashboardPanel > .summary-grid .summary-tile:nth-child(n + 5) strong {
    font-size: clamp(1.45rem, 2vw, 2rem) !important;
  }

  .dashboard-analytics-grid {
    grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.85fr) !important;
  }

  .dashboard-chart-main {
    min-height: 320px !important;
  }

  .dashboard-chart-card {
    min-height: 200px !important;
    padding: 20px !important;
    border-radius: 16px !important;
    box-shadow: none !important;
  }
}

@media (min-width: 641px) and (max-width: 1180px) {
  .app-shell,
  .app-shell.loan-app {
    width: min(100% - 28px, 1180px) !important;
    grid-template-columns: 236px minmax(0, 1fr) !important;
    gap: 18px !important;
  }

  .quick-nav,
  .quick-nav.sidebar,
  .quick-nav.app-sidebar {
    width: 236px !important;
    min-width: 236px !important;
    max-width: 236px !important;
    flex-basis: 236px !important;
  }

  body.nav-collapsed .app-shell,
  body.nav-collapsed .app-shell.loan-app {
    grid-template-columns: 84px minmax(0, 1fr) !important;
  }

  body.nav-collapsed .quick-nav,
  body.nav-collapsed .quick-nav.sidebar,
  body.nav-collapsed .quick-nav.app-sidebar {
    width: 84px !important;
    min-width: 84px !important;
    max-width: 84px !important;
    flex-basis: 84px !important;
    padding-inline: 10px !important;
  }

  .app-topbar,
  .app-topbar.page-header {
    grid-template-columns: minmax(0, 1fr) minmax(240px, 1fr) auto !important;
  }

  .dashboard-menu-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }

  #dashboardPanel > .summary-grid,
  .mini-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .dashboard-analytics-grid {
    grid-template-columns: 1fr !important;
  }

  .dashboard-chart-main {
    grid-row: auto !important;
  }

  .settings-sections {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .tracking-panel .panel-title,
  .lineoa-panel .panel-title,
  .history-panel .panel-title,
  .panel-title {
    grid-template-columns: 1fr !important;
  }

  .tracking-panel .panel-title .button-row {
    grid-template-columns: minmax(0, 1fr) 190px !important;
  }
}

/* v1.0.118 account/settings polish, loaded after styles.css. */
body[data-page="account"] .content,
body[data-page="settings"] .content {
  background:
    radial-gradient(circle at 92% 3%, rgba(31, 196, 142, .16), transparent 25%),
    radial-gradient(circle at 9% 21%, rgba(15, 139, 131, .08), transparent 20%),
    #fbfdff !important;
}

.account-settings-page,
#settingsPanel.settings-panel {
  position: relative !important;
  max-width: 1280px !important;
  margin: 0 auto !important;
  padding: clamp(28px, 4vw, 52px) !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  overflow: visible !important;
}

.account-settings-page::before,
#settingsPanel.settings-panel::before {
  content: "" !important;
  position: absolute !important;
  top: 10px !important;
  right: 16px !important;
  width: 220px !important;
  height: 150px !important;
  border-radius: 42px !important;
  background:
    radial-gradient(circle, rgba(20, 184, 166, .2) 1px, transparent 1px) 0 0 / 12px 12px,
    linear-gradient(135deg, rgba(16, 185, 129, .12), rgba(255, 255, 255, 0)) !important;
  transform: rotate(-10deg) !important;
  pointer-events: none !important;
  opacity: .55 !important;
}

.account-settings-page > .panel-title,
#settingsPanel > .panel-title {
  position: relative !important;
  z-index: 1 !important;
  padding: 0 !important;
  margin: 0 0 30px !important;
  border: 0 !important;
  background: transparent !important;
}

.account-settings-page > .panel-title h2,
#settingsPanel > .panel-title h2 {
  margin: 0 !important;
  color: #08213a !important;
  font-size: clamp(2.35rem, 4vw, 3.35rem) !important;
  font-weight: 950 !important;
  letter-spacing: 0 !important;
  line-height: 1.04 !important;
}

.account-settings-page > .panel-title h2::after,
#settingsPanel > .panel-title h2::after {
  content: " ✧" !important;
  color: #16c784 !important;
  font-size: .42em !important;
  vertical-align: 36% !important;
}

.account-settings-page .account-kicker,
.account-settings-page .account-shop-summary {
  display: none !important;
}

.account-settings-page > .panel-title p,
#settingsPanel > .panel-title p {
  display: block !important;
  margin: 8px 0 0 !important;
  color: #64748b !important;
  font-size: .98rem !important;
  font-weight: 650 !important;
}

.account-settings-page .account-tabs {
  position: relative !important;
  z-index: 1 !important;
  display: flex !important;
  align-items: stretch !important;
  gap: 14px !important;
  width: 100% !important;
  min-height: 72px !important;
  margin: 0 0 34px !important;
  padding: 0 0 1px !important;
  background: transparent !important;
  border: 0 !important;
  border-bottom: 1px solid #dde6ef !important;
  border-radius: 0 !important;
  overflow-x: auto !important;
}

.account-settings-page .account-tab {
  position: relative !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 11px !important;
  width: auto !important;
  min-width: 156px !important;
  min-height: 68px !important;
  padding: 0 18px 14px !important;
  border: 0 !important;
  border-radius: 10px 10px 0 0 !important;
  background: transparent !important;
  color: #475569 !important;
  box-shadow: none !important;
  font-size: .9rem !important;
  font-weight: 850 !important;
  line-height: 1.2 !important;
}

.account-settings-page .account-tab-icon {
  display: inline-grid !important;
  width: 26px !important;
  height: 26px !important;
  place-items: center !important;
  color: currentColor !important;
  font-size: 1.12rem !important;
  line-height: 1 !important;
}

.account-settings-page .account-tab.active {
  color: #11a879 !important;
  background: #fff !important;
  box-shadow: 0 16px 34px rgba(15, 23, 42, .06) !important;
}

.account-settings-page .account-tab::after {
  content: "" !important;
  position: absolute !important;
  left: 0 !important;
  right: 0 !important;
  bottom: -1px !important;
  height: 3px !important;
  border-radius: 999px !important;
  background: transparent !important;
}

.account-settings-page .account-tab.active::after {
  background: #11c584 !important;
}

.account-settings-page .account-grid,
.account-settings-page .account-card,
.account-settings-page .account-card .save-confirm-panel {
  display: block !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}

.account-settings-page .account-card.hidden,
.account-settings-page #accountProfileMount .panel-title {
  display: none !important;
}

.account-settings-page #userProfileForm {
  position: relative !important;
  z-index: 1 !important;
  padding: clamp(28px, 4vw, 42px) !important;
  background: rgba(255, 255, 255, .94) !important;
  border: 1px solid #e4ebf3 !important;
  border-radius: 18px !important;
  box-shadow: 0 24px 60px rgba(15, 23, 42, .07) !important;
}

.account-settings-page #userProfileForm::before {
  content: "ข้อมูลโปรไฟล์ร้าน\\Aจัดการชื่อผู้ใช้ เบอร์โทร และลายเซ็นบนเอกสาร" !important;
  display: block !important;
  white-space: pre-line !important;
  margin-bottom: 34px !important;
  padding-left: 18px !important;
  border-left: 6px solid #16c784 !important;
  color: #0f172a !important;
  font-size: 1.2rem !important;
  font-weight: 950 !important;
  line-height: 1.35 !important;
}

.account-settings-page #userProfileForm::after {
  content: none !important;
  display: none !important;
}

.account-settings-page .account-profile-readonly-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 24px 40px !important;
}

.account-settings-page .account-info-row,
.account-settings-page .account-card label:not(.file-button):not(.secondary-button) {
  display: grid !important;
  gap: 10px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
}

.account-settings-page .account-info-row-wide {
  max-width: calc(50% - 20px) !important;
  margin-top: 24px !important;
}

.account-settings-page .account-info-row > span,
.account-settings-page .account-card label > span {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  color: #0f172a !important;
  font-size: .88rem !important;
  font-weight: 900 !important;
  line-height: 1.25 !important;
}

.account-settings-page .account-info-row:nth-child(1) > span::before { content: "♙"; }
.account-settings-page .account-info-row:nth-child(2) > span::before { content: "☎"; }
.account-settings-page .account-info-row-wide > span::before { content: "@"; }
.account-settings-page .profile-signature-box > label > span::before { content: "▣"; }
.account-settings-page .compact-password-grid label span::before { content: "▣"; }

.account-settings-page .account-info-row > input,
.account-settings-page .account-card input,
.account-settings-page .account-card textarea,
.account-settings-page .account-card select {
  width: 100% !important;
  min-height: 54px !important;
  padding: 12px 44px 12px 18px !important;
  border: 1px solid #dbe3eb !important;
  border-radius: 10px !important;
  background: #fff !important;
  color: #0f172a !important;
  box-shadow: none !important;
  font-size: .98rem !important;
  font-weight: 650 !important;
  line-height: 1.2 !important;
  pointer-events: auto !important;
}

.account-settings-page .account-info-row > input[readonly] {
  background: radial-gradient(circle at calc(100% - 22px) 50%, #16c784 0 2px, #fff 3px) !important;
}

.account-settings-page .profile-signature-box {
  display: grid !important;
  grid-template-columns: minmax(260px, 1fr) minmax(180px, 260px) !important;
  gap: 24px !important;
  margin: 34px 0 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
}

.account-settings-page .profile-signature-box input[type="file"] {
  display: grid !important;
  min-height: 160px !important;
  max-width: none !important;
  margin-top: 12px !important;
  padding: 60px 22px 22px !important;
  border: 1px dashed #cbd5e1 !important;
  border-radius: 12px !important;
  background: #fff !important;
  cursor: pointer !important;
}

.account-settings-page .signature-preview,
.account-settings-page .signature-preview.hidden {
  display: grid !important;
  min-height: 160px !important;
  margin-top: 26px !important;
  max-width: none !important;
  place-items: center !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 12px !important;
  background: #fff !important;
}

.account-settings-page .signature-preview.hidden::before {
  content: "ยังไม่ได้แนบรูป\\A ยังไม่ได้อัปโหลดรูปภาพ" !important;
  white-space: pre-line !important;
  text-align: center !important;
  color: #64748b !important;
  font-weight: 800 !important;
}

.account-settings-page .account-password-heading {
  display: block !important;
  margin: 44px 0 20px !important;
  padding: 0 0 0 54px !important;
  background:
    radial-gradient(circle at 20px 20px, #d9faea 0 20px, transparent 21px) no-repeat,
    linear-gradient(#0f8b6f, #0f8b6f) 18px 12px / 6px 16px no-repeat !important;
}

.account-settings-page .account-password-heading strong,
.account-settings-page .account-password-heading span {
  display: block !important;
}

.account-settings-page .account-password-heading strong {
  color: #0f172a !important;
  font-size: 1.12rem !important;
  font-weight: 950 !important;
}

.account-settings-page .account-password-heading span {
  margin-top: 3px !important;
  color: #64748b !important;
  font-size: .86rem !important;
  font-weight: 650 !important;
}

.account-settings-page .compact-password-grid {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 22px 36px !important;
  margin-top: 0 !important;
  padding: 0 !important;
  border: 0 !important;
}

.account-settings-page .confirm-actions {
  display: flex !important;
  justify-content: center !important;
  gap: 14px !important;
  margin-top: 28px !important;
  padding-top: 0 !important;
  border: 0 !important;
}

.account-settings-page .confirm-actions .primary-button,
#settingsPanel .settings-footer .primary-button {
  min-width: 220px !important;
  min-height: 54px !important;
  border-radius: 12px !important;
  background: linear-gradient(135deg, #16c784, #08a676) !important;
  box-shadow: 0 12px 26px rgba(16, 185, 129, .22) !important;
}

#settingsPanel .settings-sections {
  display: grid !important;
  grid-template-columns: 300px minmax(0, 1fr) !important;
  align-items: start !important;
  gap: 24px !important;
}

#settingsPanel .settings-box {
  overflow: hidden !important;
  margin: 0 !important;
  border: 1px solid #e4ebf3 !important;
  border-radius: 18px !important;
  background: rgba(255, 255, 255, .94) !important;
  box-shadow: 0 24px 60px rgba(15, 23, 42, .06) !important;
}

#settingsPanel .settings-box summary {
  min-height: 76px !important;
  display: grid !important;
  grid-template-columns: 56px minmax(0, 1fr) auto !important;
  gap: 16px !important;
  align-items: center !important;
  padding: 18px 24px !important;
  border: 0 !important;
  color: #0f172a !important;
  font-size: 1.02rem !important;
  font-weight: 950 !important;
  background: #fff !important;
}

#settingsPanel .settings-summary-icon {
  width: 48px !important;
  height: 48px !important;
  border-radius: 14px !important;
  background: #ddfaeb !important;
  color: #0f8b6f !important;
}

#settingsPanel .settings-box[open] summary {
  border-bottom: 1px solid #edf2f7 !important;
}

#settingsPanel .settings-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 22px !important;
  padding: 24px !important;
}

#settingsPanel .settings-box > label,
#settingsPanel .backup-actions {
  padding: 24px !important;
}

#settingsPanel .settings-box:nth-child(1) {
  grid-row: span 4 !important;
}

#settingsPanel .settings-box:not(:first-child) {
  grid-column: 2 !important;
}

#settingsPanel .settings-footer {
  display: flex !important;
  justify-content: flex-end !important;
  margin-top: 24px !important;
  padding: 0 !important;
  border: 0 !important;
}

@media (max-width: 980px) {
  .account-settings-page .account-profile-readonly-grid,
  .account-settings-page .profile-signature-box,
  .account-settings-page .compact-password-grid,
  #settingsPanel .settings-sections,
  #settingsPanel .settings-grid {
    grid-template-columns: 1fr !important;
  }

  .account-settings-page .account-info-row-wide {
    max-width: none !important;
  }

  #settingsPanel .settings-box,
  #settingsPanel .settings-box:not(:first-child) {
    grid-column: auto !important;
    grid-row: auto !important;
  }
}

/* v1.0.119 copy-reference settings/account layout. */
body[data-page="account"],
body[data-page="settings"] {
  font-family: "Inter", "Noto Sans Thai", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
}

@media (min-width: 901px) {
  body[data-page="account"] .app-shell,
  body[data-page="settings"] .app-shell,
  body[data-page="account"].nav-collapsed .app-shell,
  body[data-page="settings"].nav-collapsed .app-shell {
    grid-template-columns: 170px minmax(0, 1fr) !important;
    background: #f8fbfd !important;
  }

  body[data-page="account"] .quick-nav,
  body[data-page="settings"] .quick-nav {
    width: 170px !important;
    padding: 32px 18px 18px !important;
    border: 0 !important;
    border-right: 1px solid #eef3f7 !important;
    border-radius: 0 !important;
    background: rgba(255, 255, 255, .96) !important;
    box-shadow: 14px 0 38px rgba(15, 23, 42, .035) !important;
  }

  body[data-page="account"] .nav-collapse-button,
  body[data-page="settings"] .nav-collapse-button {
    display: none !important;
  }

  body[data-page="account"] .side-brand,
  body[data-page="settings"] .side-brand {
    display: block !important;
    height: 64px !important;
    margin: 0 0 34px !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  body[data-page="account"] .side-brand > span,
  body[data-page="account"] .side-brand > strong,
  body[data-page="settings"] .side-brand > span,
  body[data-page="settings"] .side-brand > strong {
    display: none !important;
  }

  body[data-page="account"] .side-brand::before,
  body[data-page="settings"] .side-brand::before {
    content: "P" !important;
    display: grid !important;
    width: 44px !important;
    height: 44px !important;
    place-items: center !important;
    border-radius: 12px !important;
    color: #fff !important;
    background: linear-gradient(135deg, #14c784, #079d72) !important;
    box-shadow: 0 15px 28px rgba(16, 185, 129, .18) !important;
    font-size: 1.4rem !important;
    font-weight: 950 !important;
    line-height: 1 !important;
  }

  body[data-page="account"] .quick-nav a,
  body[data-page="account"] .quick-nav .sidebar-link,
  body[data-page="account"] .quick-nav .nav-group-toggle,
  body[data-page="account"] .quick-nav .nav-text-link,
  body[data-page="settings"] .quick-nav a,
  body[data-page="settings"] .quick-nav .sidebar-link,
  body[data-page="settings"] .quick-nav .nav-group-toggle,
  body[data-page="settings"] .quick-nav .nav-text-link {
    min-height: 44px !important;
    padding: 9px 12px !important;
    border: 0 !important;
    border-radius: 10px !important;
    background: transparent !important;
    color: #0f172a !important;
    box-shadow: none !important;
    font-size: .86rem !important;
    font-weight: 750 !important;
    gap: 12px !important;
  }

  body[data-page="account"] .quick-nav .nav-icon,
  body[data-page="settings"] .quick-nav .nav-icon {
    width: 24px !important;
    height: 24px !important;
    min-width: 24px !important;
    border-radius: 0 !important;
    background: transparent !important;
    color: currentColor !important;
  }

  body[data-page="settings"] .quick-nav .mobile-settings-link,
  body[data-page="settings"] .quick-nav .settings-nav-link,
  body[data-page="account"] .quick-nav .mobile-account-link,
  body[data-page="account"] .quick-nav .side-user-profile {
    background: linear-gradient(135deg, #16c784, #08a676) !important;
    color: #fff !important;
    box-shadow: 0 14px 24px rgba(16, 185, 129, .24) !important;
  }

  body[data-page="account"] .side-user,
  body[data-page="settings"] .side-user {
    margin-top: auto !important;
    padding-top: 0 !important;
    border: 0 !important;
    gap: 12px !important;
  }

  body[data-page="account"] .side-user-profile,
  body[data-page="settings"] .side-user-profile {
    display: grid !important;
    grid-template-columns: 40px minmax(0, 1fr) 12px !important;
    min-height: 78px !important;
    padding: 12px !important;
    border: 1px solid #eef3f7 !important;
    border-radius: 12px !important;
    background: #fff !important;
    color: #0f172a !important;
    box-shadow: 0 14px 30px rgba(15, 23, 42, .045) !important;
  }

  body[data-page="account"] .side-user-profile::after,
  body[data-page="settings"] .side-user-profile::after {
    content: "›" !important;
    align-self: center !important;
    color: #0f172a !important;
    font-size: 1.1rem !important;
    font-weight: 900 !important;
  }

  body[data-page="account"] .profile-avatar,
  body[data-page="settings"] .profile-avatar {
    width: 40px !important;
    height: 40px !important;
    background: #16c784 !important;
    color: #fff !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .profile-copy span,
  body[data-page="settings"] .profile-copy span {
    color: #64748b !important;
    font-size: .72rem !important;
    font-weight: 700 !important;
  }

  body[data-page="account"] .profile-copy strong,
  body[data-page="settings"] .profile-copy strong {
    color: #0f172a !important;
    font-size: .88rem !important;
    font-weight: 850 !important;
  }

  body[data-page="account"] .app-topbar,
  body[data-page="settings"] .app-topbar,
  body[data-page="account"] .hero,
  body[data-page="settings"] .hero {
    display: none !important;
  }
}

body[data-page="account"] .content,
body[data-page="settings"] .content {
  background:
    radial-gradient(circle at 88px 80px, rgba(16, 185, 129, .04), transparent 130px),
    radial-gradient(circle at 93% 0, rgba(16, 185, 129, .12), transparent 250px),
    #fbfdff !important;
}

.account-settings-page,
#settingsPanel.settings-panel {
  max-width: 980px !important;
  margin: 0 !important;
  padding: 38px 38px 56px !important;
  background: transparent !important;
}

.account-settings-page > .panel-title h2,
#settingsPanel > .panel-title h2 {
  font-size: 2rem !important;
  font-weight: 850 !important;
  color: #111827 !important;
  letter-spacing: -.02em !important;
}

.account-settings-page > .panel-title p,
#settingsPanel > .panel-title p {
  margin-top: 6px !important;
  color: #526173 !important;
  font-size: .82rem !important;
  font-weight: 500 !important;
}

.account-settings-page .account-tabs {
  gap: 20px !important;
  min-height: 64px !important;
  margin: 22px 0 34px !important;
  border-bottom: 1px solid #e5e9ef !important;
}

.account-settings-page .account-tab {
  min-width: 150px !important;
  min-height: 64px !important;
  padding: 0 20px 14px !important;
  color: #344256 !important;
  font-size: .82rem !important;
  font-weight: 750 !important;
}

.account-settings-page .account-tab.active {
  color: #0fb778 !important;
  background: #fff !important;
  box-shadow: 0 16px 36px rgba(15, 23, 42, .06) !important;
}

.account-settings-page .account-tab.active::after {
  height: 3px !important;
  background: #12bd7a !important;
}

.account-settings-page #userProfileForm {
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.account-settings-page #userProfileForm::before,
.account-settings-page #userProfileForm::after {
  content: none !important;
  display: none !important;
}

.account-profile-card,
.account-password-card,
#settingsPanel .settings-box {
  border: 1px solid #edf1f5 !important;
  border-radius: 10px !important;
  background: rgba(255, 255, 255, .97) !important;
  box-shadow: 0 18px 42px rgba(15, 23, 42, .055) !important;
}

.account-profile-card {
  padding: 32px !important;
}

.account-profile-hero {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) 420px !important;
  gap: 42px !important;
  align-items: start !important;
  margin-bottom: 48px !important;
}

.account-section-title {
  display: grid !important;
  grid-template-columns: 5px minmax(0, 1fr) !important;
  gap: 16px !important;
  align-items: start !important;
}

.account-section-title > span {
  width: 5px !important;
  height: 22px !important;
  margin-top: 3px !important;
  border-radius: 999px !important;
  background: #12bd7a !important;
}

.account-section-title h3,
.account-profile-picture strong,
.account-password-heading strong {
  margin: 0 !important;
  color: #111827 !important;
  font-size: 1.05rem !important;
  font-weight: 850 !important;
  letter-spacing: 0 !important;
}

.account-section-title p,
.account-profile-picture p,
.account-password-heading span {
  margin: 8px 0 0 !important;
  color: #64748b !important;
  font-size: .82rem !important;
  font-weight: 500 !important;
}

.account-profile-picture {
  display: grid !important;
  grid-template-columns: 100px minmax(0, 1fr) !important;
  gap: 28px !important;
  align-items: center !important;
}

.account-profile-orb {
  display: grid !important;
  width: 96px !important;
  height: 96px !important;
  place-items: center !important;
  border-radius: 999px !important;
  color: #fff !important;
  background: linear-gradient(135deg, #24d595, #08aa73) !important;
  box-shadow: 0 16px 30px rgba(16, 185, 129, .24) !important;
  font-size: 1.65rem !important;
  font-weight: 900 !important;
}

.account-upload-photo-button {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 38px !important;
  margin-top: 14px !important;
  padding: 8px 20px !important;
  border: 1px solid #12bd7a !important;
  border-radius: 5px !important;
  color: #0fb778 !important;
  background: #fff !important;
  font-size: .78rem !important;
  font-weight: 850 !important;
  cursor: pointer !important;
}

.account-settings-page .account-profile-readonly-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 30px 38px !important;
}

.account-settings-page .account-info-row-wide {
  max-width: calc(50% - 19px) !important;
  margin-top: 26px !important;
}

.account-settings-page .account-info-row > span,
.account-settings-page .account-card label > span {
  color: #1f2937 !important;
  font-size: .78rem !important;
  font-weight: 850 !important;
}

.account-settings-page .account-info-row > input,
.account-settings-page .account-card input,
.account-settings-page .account-card textarea,
.account-settings-page .account-card select {
  min-height: 50px !important;
  border-radius: 6px !important;
  border-color: #dce3eb !important;
  color: #162033 !important;
  font-size: .88rem !important;
  font-weight: 500 !important;
}

.account-settings-page .profile-signature-box {
  grid-template-columns: minmax(0, 1fr) 200px !important;
  gap: 38px !important;
  margin-top: 38px !important;
}

.signature-dropzone {
  display: grid !important;
  min-height: 190px !important;
  margin-top: 14px !important;
  place-items: center !important;
  align-content: center !important;
  gap: 8px !important;
  border: 1px dashed #cfd7e2 !important;
  border-radius: 8px !important;
  background: #fff !important;
  color: #657386 !important;
  text-align: center !important;
}

.signature-dropzone b {
  color: #12bd7a !important;
  font-size: 2rem !important;
  line-height: 1 !important;
}

.signature-dropzone em,
.signature-dropzone small {
  font-style: normal !important;
  font-size: .82rem !important;
  font-weight: 500 !important;
}

.signature-dropzone strong {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 38px !important;
  min-width: 130px !important;
  margin-top: 3px !important;
  border: 1px solid #12bd7a !important;
  border-radius: 5px !important;
  color: #0fb778 !important;
  background: #fff !important;
  font-size: .82rem !important;
  font-weight: 850 !important;
}

.account-settings-page .signature-upload-field input[type="file"] {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

.account-settings-page .signature-preview,
.account-settings-page .signature-preview.hidden {
  min-height: 190px !important;
  margin-top: 31px !important;
  border-radius: 8px !important;
  color: #657386 !important;
}

.account-password-card {
  margin-top: 22px !important;
  padding: 26px 30px 24px !important;
}

.account-settings-page .account-password-heading {
  margin: 0 0 28px !important;
  padding-left: 66px !important;
  min-height: 48px !important;
  background:
    radial-gradient(circle at 24px 24px, #d9faea 0 24px, transparent 25px) no-repeat,
    linear-gradient(#0f8b6f, #0f8b6f) 21px 15px / 7px 17px no-repeat !important;
}

.account-settings-page .compact-password-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 28px !important;
}

.password-strength-preview {
  display: grid !important;
  grid-template-columns: auto 1fr 1fr 1fr !important;
  gap: 8px !important;
  align-items: center !important;
  margin-top: 28px !important;
  color: #64748b !important;
  font-size: .76rem !important;
}

.password-strength-preview i {
  grid-column: 2 / 5 !important;
  height: 6px !important;
  border-radius: 999px !important;
  background: linear-gradient(90deg, #12bd7a 0 33%, #e5e7eb 33% 66%, #e5e7eb 66% 100%) !important;
}

.password-strength-preview small {
  text-align: center !important;
  font-size: .72rem !important;
}

.account-settings-page .confirm-actions {
  margin-top: 20px !important;
}

.account-settings-page .confirm-actions .primary-button,
#settingsPanel .settings-footer .primary-button {
  min-width: 210px !important;
  min-height: 44px !important;
  border-radius: 7px !important;
  font-size: .86rem !important;
}

.account-settings-page .confirm-actions .secondary-button {
  display: none !important;
}

#settingsPanel .settings-sections {
  grid-template-columns: 260px minmax(0, 1fr) !important;
}

#settingsPanel .settings-box summary {
  min-height: 62px !important;
  grid-template-columns: 42px minmax(0, 1fr) auto !important;
  padding: 14px 20px !important;
  font-size: .92rem !important;
}

#settingsPanel .settings-summary-icon {
  width: 38px !important;
  height: 38px !important;
  border-radius: 10px !important;
}

@media (max-width: 980px) {
  .account-profile-hero,
  .account-settings-page .account-profile-readonly-grid,
  .account-settings-page .profile-signature-box,
  .account-settings-page .compact-password-grid,
  #settingsPanel .settings-sections,
  #settingsPanel .settings-grid {
    grid-template-columns: 1fr !important;
  }

  .account-settings-page,
  #settingsPanel.settings-panel {
    padding: 24px 18px 110px !important;
  }

  .account-profile-card,
  .account-password-card {
    padding: 22px !important;
  }

  .account-settings-page .account-info-row-wide {
    max-width: none !important;
  }

  .account-profile-picture {
    grid-template-columns: 76px minmax(0, 1fr) !important;
  }

  .account-profile-orb {
    width: 74px !important;
    height: 74px !important;
  }
}

/* v1.0.120 premium SaaS settings dashboard. */
:root {
  --premium-green: #19c37d;
  --premium-green-dark: #0e9f6e;
  --premium-mint: #dffcf0;
  --premium-bg: #f4f7f5;
  --premium-text: #0f172a;
  --premium-subtext: #64748b;
  --premium-border: rgba(15, 23, 42, .08);
  --premium-shadow: 0 26px 70px rgba(15, 23, 42, .10);
  --premium-glow: 0 18px 42px rgba(25, 195, 125, .22);
}

@media (min-width: 981px) {
  body[data-page="account"],
  body[data-page="settings"] {
    color: var(--premium-text) !important;
    background:
      radial-gradient(circle at 86% 7%, rgba(25, 195, 125, .18), transparent 30%),
      radial-gradient(circle at 20% 18%, rgba(14, 159, 110, .10), transparent 34%),
      linear-gradient(135deg, #fbfffd 0%, var(--premium-bg) 52%, #eef6f2 100%) !important;
    font-family: Inter, "Noto Sans Thai", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  body[data-page="account"] .app-shell,
  body[data-page="settings"] .app-shell {
    display: grid !important;
    grid-template-columns: 188px minmax(0, 1fr) !important;
    min-height: 100vh !important;
    gap: 0 !important;
    padding: 0 !important;
    background: transparent !important;
  }

  body[data-page="account"] .content-shell,
  body[data-page="settings"] .content-shell {
    position: relative !important;
    min-height: 100vh !important;
    padding: 42px 54px 82px 38px !important;
    overflow: hidden !important;
    background:
      linear-gradient(90deg, rgba(255, 255, 255, .12), rgba(255, 255, 255, 0)),
      radial-gradient(circle at 92% 4%, rgba(25, 195, 125, .12), transparent 24%) !important;
  }

  body[data-page="account"] .content-shell::before,
  body[data-page="settings"] .content-shell::before {
    content: "" !important;
    position: fixed !important;
    inset: 0 0 auto 0 !important;
    height: 230px !important;
    pointer-events: none !important;
    background:
      radial-gradient(circle, rgba(25, 195, 125, .18) 1px, transparent 1.5px) 90% 18px / 16px 16px,
      linear-gradient(135deg, transparent 0%, rgba(255, 255, 255, .42) 52%, transparent 100%) !important;
    opacity: .58 !important;
    mask-image: linear-gradient(#000, transparent) !important;
    z-index: 0 !important;
  }

  body[data-page="account"] .app-topbar,
  body[data-page="settings"] .app-topbar {
    display: none !important;
  }

  body[data-page="account"] .panel,
  body[data-page="settings"] .panel {
    position: relative !important;
    z-index: 1 !important;
  }

  body[data-page="account"] .quick-nav,
  body[data-page="settings"] .quick-nav {
    position: sticky !important;
    top: 24px !important;
    align-self: start !important;
    width: 136px !important;
    height: calc(100vh - 48px) !important;
    margin: 24px 0 24px 22px !important;
    padding: 22px 12px !important;
    border: 1px solid rgba(15, 23, 42, .075) !important;
    border-radius: 30px !important;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .84), rgba(255, 255, 255, .60)),
      radial-gradient(circle at 50% 2%, rgba(25, 195, 125, .10), transparent 32%) !important;
    box-shadow:
      0 28px 80px rgba(15, 23, 42, .12),
      inset 0 1px 0 rgba(255, 255, 255, .95) !important;
    backdrop-filter: blur(26px) saturate(1.35) !important;
    -webkit-backdrop-filter: blur(26px) saturate(1.35) !important;
    overflow: hidden auto !important;
  }

  body[data-page="account"] .side-brand,
  body[data-page="settings"] .side-brand {
    position: relative !important;
    display: grid !important;
    width: 72px !important;
    height: 72px !important;
    margin: 0 auto 28px !important;
    place-items: center !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 24px !important;
    color: #fff !important;
    background: linear-gradient(145deg, #1fd08a 0%, #0e9f6e 78%) !important;
    box-shadow: 0 18px 42px rgba(25, 195, 125, .34), inset 0 1px 0 rgba(255, 255, 255, .35) !important;
    font-size: 0 !important;
    text-transform: none !important;
  }

  body[data-page="account"] .side-brand::after,
  body[data-page="settings"] .side-brand::after {
    content: "P" !important;
    color: #fff !important;
    font-size: 2.05rem !important;
    font-weight: 950 !important;
    line-height: 1 !important;
    letter-spacing: -.05em !important;
  }

  body[data-page="account"] .side-brand strong,
  body[data-page="account"] .side-brand > span,
  body[data-page="settings"] .side-brand strong,
  body[data-page="settings"] .side-brand > span,
  body[data-page="account"] .nav-collapse-button,
  body[data-page="settings"] .nav-collapse-button,
  body[data-page="account"] .mobile-create-nav,
  body[data-page="settings"] .mobile-create-nav,
  body[data-page="account"] .nav-group-toggle,
  body[data-page="settings"] .nav-group-toggle,
  body[data-page="account"] a[href="#recordsPanel"],
  body[data-page="settings"] a[href="#recordsPanel"],
  body[data-page="account"] a[href="#trackingPanel"],
  body[data-page="settings"] a[href="#trackingPanel"] {
    display: none !important;
  }

  body[data-page="account"] .mobile-only-nav-link,
  body[data-page="settings"] .mobile-only-nav-link,
  body[data-page="account"] .nav-group-items,
  body[data-page="settings"] .nav-group-items {
    display: grid !important;
  }

  body[data-page="account"] .quick-nav::after,
  body[data-page="settings"] .quick-nav::after {
    content: "" !important;
    display: block !important;
    width: 82px !important;
    height: 1px !important;
    margin: 22px auto !important;
    background: rgba(15, 23, 42, .08) !important;
  }

  body[data-page="account"] .sidebar-link,
  body[data-page="settings"] .sidebar-link,
  body[data-page="account"] .nav-text-link,
  body[data-page="settings"] .nav-text-link {
    position: relative !important;
    display: grid !important;
    width: 96px !important;
    min-height: 74px !important;
    margin: 0 auto 8px !important;
    padding: 11px 8px !important;
    place-items: center !important;
    gap: 8px !important;
    border: 1px solid transparent !important;
    border-radius: 22px !important;
    color: #536174 !important;
    background: transparent !important;
    box-shadow: none !important;
    transition: transform .22s ease, background .22s ease, color .22s ease, box-shadow .22s ease, border-color .22s ease !important;
  }

  body[data-page="account"] .sidebar-link:hover,
  body[data-page="settings"] .sidebar-link:hover,
  body[data-page="account"] .nav-text-link:hover,
  body[data-page="settings"] .nav-text-link:hover {
    transform: translateY(-2px) !important;
    color: var(--premium-green-dark) !important;
    background: rgba(255, 255, 255, .72) !important;
    border-color: rgba(25, 195, 125, .14) !important;
    box-shadow: 0 18px 34px rgba(15, 23, 42, .08) !important;
  }

  body[data-page="account"] .nav-icon,
  body[data-page="settings"] .nav-icon,
  body[data-page="account"] .settings-gear,
  body[data-page="settings"] .settings-gear {
    display: grid !important;
    width: 34px !important;
    height: 34px !important;
    place-items: center !important;
    border-radius: 13px !important;
    color: currentColor !important;
    background: rgba(241, 245, 249, .88) !important;
  }

  body[data-page="account"] .nav-label,
  body[data-page="settings"] .nav-label {
    color: currentColor !important;
    font-size: 0 !important;
    font-weight: 800 !important;
    line-height: 1.05 !important;
    text-align: center !important;
    white-space: normal !important;
  }

  body[data-page="account"] .nav-label::after,
  body[data-page="settings"] .nav-label::after {
    font-size: .69rem !important;
  }

  body[data-page="account"] a[href="#dashboardPanel"] .nav-label::after,
  body[data-page="settings"] a[href="#dashboardPanel"] .nav-label::after { content: "Dashboard" !important; }
  body[data-page="account"] a[href="#customerProfilesPanel"] .nav-label::after,
  body[data-page="settings"] a[href="#customerProfilesPanel"] .nav-label::after { content: "Customers" !important; }
  body[data-page="account"] a[href="#historyPanel"] .nav-label::after,
  body[data-page="settings"] a[href="#historyPanel"] .nav-label::after { content: "Analytics" !important; }
  body[data-page="account"] a[href="#lineLeadsPanel"] .nav-label::after,
  body[data-page="settings"] a[href="#lineLeadsPanel"] .nav-label::after { content: "Contracts" !important; }
  body[data-page="account"] a[href="#lineOaPanel"] .nav-label::after,
  body[data-page="settings"] a[href="#lineOaPanel"] .nav-label::after { content: "LINE Connect" !important; }
  body[data-page="account"] a[href="#accountPanel"] .nav-label::after,
  body[data-page="settings"] a[href="#accountPanel"] .nav-label::after { content: "Profile" !important; }
  body[data-page="account"] a[href="#settingsPanel"] .nav-label::after,
  body[data-page="settings"] a[href="#settingsPanel"] .nav-label::after { content: "Settings" !important; }
  body[data-page="account"] .logout-nav-link .nav-label::after,
  body[data-page="settings"] .logout-nav-link .nav-label::after { content: "Logout" !important; }

  body[data-page="account"] .sidebar-link.active,
  body[data-page="account"] .mobile-account-link,
  body[data-page="settings"] .sidebar-link.active,
  body[data-page="settings"] .mobile-settings-link {
    color: #08795a !important;
    background: linear-gradient(180deg, rgba(225, 255, 240, .95), rgba(236, 255, 246, .78)) !important;
    border-color: rgba(25, 195, 125, .30) !important;
    box-shadow: 0 20px 44px rgba(25, 195, 125, .18), inset 0 1px 0 rgba(255, 255, 255, .9) !important;
  }

  body[data-page="account"] .side-user,
  body[data-page="settings"] .side-user {
    margin-top: auto !important;
    padding: 20px 0 0 !important;
    border-top: 1px solid rgba(15, 23, 42, .08) !important;
  }

  body[data-page="account"] .side-user-profile,
  body[data-page="settings"] .side-user-profile {
    width: 96px !important;
    min-height: 74px !important;
    margin: 0 auto 8px !important;
    padding: 10px !important;
    border-radius: 22px !important;
    background: rgba(255, 255, 255, .54) !important;
    border: 1px solid rgba(15, 23, 42, .06) !important;
  }

  body[data-page="account"] .profile-avatar,
  body[data-page="settings"] .profile-avatar {
    width: 36px !important;
    height: 36px !important;
    margin: 0 auto !important;
    border-radius: 14px !important;
    color: #08795a !important;
    background: linear-gradient(180deg, #e6fff1, #d6f8e7) !important;
  }

  body[data-page="account"] .profile-copy,
  body[data-page="settings"] .profile-copy {
    display: none !important;
  }

  body[data-page="account"] .logout-nav-link,
  body[data-page="settings"] .logout-nav-link {
    color: #ef4444 !important;
  }

  body[data-page="account"] .account-settings-page,
  body[data-page="settings"] #settingsPanel.settings-panel {
    width: min(1180px, 100%) !important;
    max-width: none !important;
    margin: 0 auto !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .account-settings-page::before,
  body[data-page="settings"] #settingsPanel.settings-panel::before {
    content: "" !important;
    position: fixed !important;
    right: 64px !important;
    top: 34px !important;
    width: 190px !important;
    height: 190px !important;
    pointer-events: none !important;
    background:
      linear-gradient(135deg, rgba(25, 195, 125, .12), rgba(255, 255, 255, 0)),
      radial-gradient(circle at 60% 40%, rgba(25, 195, 125, .10), transparent 58%) !important;
    border-radius: 56px !important;
    transform: rotate(18deg) !important;
    filter: blur(.2px) !important;
    opacity: .85 !important;
  }

  body[data-page="account"] .account-settings-page .panel-title,
  body[data-page="settings"] #settingsPanel .panel-title {
    margin: 14px 0 24px !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  body[data-page="account"] .account-kicker,
  body[data-page="settings"] #settingsPanel .panel-title::before {
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    margin-bottom: 6px !important;
    color: var(--premium-green-dark) !important;
    font-size: .76rem !important;
    font-weight: 900 !important;
    letter-spacing: .12em !important;
    text-transform: uppercase !important;
  }

  body[data-page="settings"] #settingsPanel .panel-title::before {
    content: "หน้าตั้งค่า" !important;
  }

  body[data-page="account"] .account-settings-page .panel-title h2,
  body[data-page="settings"] #settingsPanel .panel-title h2 {
    margin: 0 !important;
    color: var(--premium-text) !important;
    font-size: clamp(2.65rem, 4.6vw, 4.85rem) !important;
    font-weight: 900 !important;
    line-height: .92 !important;
    letter-spacing: -.055em !important;
  }

  body[data-page="account"] .account-settings-page .panel-title h2::after,
  body[data-page="settings"] #settingsPanel .panel-title h2::after {
    content: " ✧" !important;
    color: var(--premium-green) !important;
    font-size: .42em !important;
    vertical-align: 45% !important;
    letter-spacing: 0 !important;
  }

  body[data-page="account"] .account-settings-page .panel-title p,
  body[data-page="settings"] #settingsPanel .panel-title p {
    max-width: 640px !important;
    margin: 12px 0 0 !important;
    color: var(--premium-subtext) !important;
    font-size: .98rem !important;
    font-weight: 650 !important;
    line-height: 1.55 !important;
  }

  body[data-page="account"] .account-shop-summary {
    display: none !important;
  }

  body[data-page="account"] .account-tabs {
    display: inline-flex !important;
    width: auto !important;
    margin: 18px 0 34px !important;
    padding: 0 !important;
    gap: 10px !important;
    border: 0 !important;
    border-bottom: 1px solid rgba(15, 23, 42, .10) !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .account-tab {
    position: relative !important;
    min-height: 68px !important;
    padding: 0 28px 16px 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    color: #3b4756 !important;
    background: transparent !important;
    box-shadow: none !important;
    font-size: .95rem !important;
    font-weight: 750 !important;
  }

  body[data-page="account"] .account-tab::after {
    content: "" !important;
    position: absolute !important;
    left: 0 !important;
    right: 28px !important;
    bottom: -1px !important;
    height: 3px !important;
    border-radius: 999px !important;
    background: linear-gradient(90deg, var(--premium-green), var(--premium-green-dark)) !important;
    transform: scaleX(0) !important;
    transform-origin: left !important;
    transition: transform .24s ease !important;
    box-shadow: 0 0 24px rgba(25, 195, 125, .35) !important;
  }

  body[data-page="account"] .account-tab:hover,
  body[data-page="account"] .account-tab.active {
    color: #08795a !important;
    transform: translateY(-1px) !important;
  }

  body[data-page="account"] .account-tab.active::after {
    transform: scaleX(1) !important;
  }

  body[data-page="account"] .account-tab-icon {
    display: grid !important;
    width: 38px !important;
    height: 38px !important;
    place-items: center !important;
    border-radius: 14px !important;
    color: currentColor !important;
    background: rgba(255, 255, 255, .64) !important;
    border: 1px solid rgba(15, 23, 42, .06) !important;
    font-size: .9rem !important;
  }

  body[data-page="account"] .account-tab.active .account-tab-icon {
    color: var(--premium-green-dark) !important;
    background: linear-gradient(180deg, #e8fff3, #ffffff) !important;
    box-shadow: var(--premium-glow) !important;
  }

  body[data-page="account"] .account-grid,
  body[data-page="account"] .account-card,
  body[data-page="settings"] #settingsPanel .settings-sections {
    display: block !important;
    min-width: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .account-card.hidden {
    display: none !important;
  }

  body[data-page="account"] #userProfileForm,
  body[data-page="account"] #userManageForm,
  body[data-page="account"] #userManageList,
  body[data-page="settings"] #settingsPanel .settings-box {
    position: relative !important;
    width: 100% !important;
    padding: 28px !important;
    border: 1px solid var(--premium-border) !important;
    border-radius: 28px !important;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .92), rgba(255, 255, 255, .72)),
      radial-gradient(circle at 100% 0, rgba(25, 195, 125, .06), transparent 30%) !important;
    box-shadow: var(--premium-shadow), inset 0 1px 0 rgba(255, 255, 255, .95) !important;
    backdrop-filter: blur(18px) saturate(1.16) !important;
    -webkit-backdrop-filter: blur(18px) saturate(1.16) !important;
  }

  body[data-page="account"] #userProfileForm > .panel-title {
    display: none !important;
  }

  body[data-page="account"] .account-profile-card,
  body[data-page="account"] .account-password-card {
    position: relative !important;
    margin: 0 0 28px !important;
    padding: 34px 36px !important;
    border: 1px solid rgba(15, 23, 42, .065) !important;
    border-radius: 26px !important;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .94), rgba(255, 255, 255, .78)),
      radial-gradient(circle at 12% 0, rgba(25, 195, 125, .045), transparent 32%) !important;
    box-shadow:
      0 22px 58px rgba(15, 23, 42, .075),
      inset 0 1px 0 rgba(255, 255, 255, .96) !important;
  }

  body[data-page="account"] .account-profile-card::before,
  body[data-page="account"] .account-password-card::before {
    content: "" !important;
    position: absolute !important;
    left: 34px !important;
    top: 36px !important;
    width: 5px !important;
    height: 28px !important;
    border-radius: 999px !important;
    background: linear-gradient(180deg, var(--premium-green), var(--premium-green-dark)) !important;
    box-shadow: 0 0 22px rgba(25, 195, 125, .24) !important;
  }

  body[data-page="account"] .account-profile-hero {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 430px) !important;
    gap: 34px !important;
    align-items: start !important;
    margin-bottom: 56px !important;
  }

  body[data-page="account"] .account-section-title {
    padding-left: 28px !important;
  }

  body[data-page="account"] .account-section-title > span {
    display: none !important;
  }

  body[data-page="account"] .account-section-title h3,
  body[data-page="account"] .account-password-heading strong {
    color: var(--premium-text) !important;
    font-size: 1.18rem !important;
    font-weight: 870 !important;
    letter-spacing: -.025em !important;
  }

  body[data-page="account"] .account-section-title p,
  body[data-page="account"] .account-password-heading span {
    margin-top: 8px !important;
    color: var(--premium-subtext) !important;
    font-size: .88rem !important;
    font-weight: 560 !important;
  }

  body[data-page="account"] .account-profile-picture {
    display: grid !important;
    grid-template-columns: 112px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 26px !important;
  }

  body[data-page="account"] .account-profile-orb {
    width: 112px !important;
    height: 112px !important;
    border-radius: 999px !important;
    color: #fff !important;
    background:
      radial-gradient(circle at 35% 28%, rgba(255, 255, 255, .32), transparent 32%),
      linear-gradient(145deg, #31d69b 0%, #10b981 48%, #078861 100%) !important;
    box-shadow: 0 26px 54px rgba(25, 195, 125, .34), inset 0 1px 0 rgba(255, 255, 255, .42) !important;
    font-size: 0 !important;
  }

  body[data-page="account"] .account-profile-orb::after {
    content: "◎" !important;
    font-size: 2.05rem !important;
    font-weight: 900 !important;
  }

  body[data-page="account"] .account-upload-photo-button {
    display: inline-flex !important;
    min-height: 42px !important;
    margin-top: 16px !important;
    padding: 0 20px !important;
    align-items: center !important;
    justify-content: center !important;
    border: 1px solid rgba(25, 195, 125, .55) !important;
    border-radius: 12px !important;
    color: var(--premium-green-dark) !important;
    background: rgba(255, 255, 255, .76) !important;
    box-shadow: 0 12px 26px rgba(25, 195, 125, .10) !important;
    font-size: .78rem !important;
    font-weight: 850 !important;
  }

  body[data-page="account"] .account-profile-readonly-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 30px 42px !important;
  }

  body[data-page="account"] .account-info-row,
  body[data-page="account"] .account-card label,
  body[data-page="settings"] #settingsPanel label {
    position: relative !important;
    display: grid !important;
    gap: 10px !important;
  }

  body[data-page="account"] .account-info-row > span,
  body[data-page="account"] .account-card label > span,
  body[data-page="settings"] #settingsPanel label > span {
    display: inline-flex !important;
    align-items: center !important;
    gap: 9px !important;
    color: #1f2a3a !important;
    font-size: .80rem !important;
    font-weight: 850 !important;
    letter-spacing: -.01em !important;
  }

  body[data-page="account"] .account-info-row::after {
    content: "✓" !important;
    position: absolute !important;
    right: 18px !important;
    bottom: 15px !important;
    color: var(--premium-green) !important;
    font-weight: 950 !important;
    pointer-events: none !important;
  }

  body[data-page="account"] .account-info-row > input,
  body[data-page="account"] .account-card input,
  body[data-page="account"] .account-card textarea,
  body[data-page="account"] .account-card select,
  body[data-page="settings"] #settingsPanel input,
  body[data-page="settings"] #settingsPanel textarea,
  body[data-page="settings"] #settingsPanel select {
    min-height: 58px !important;
    padding: 0 44px 0 18px !important;
    border: 1px solid rgba(148, 163, 184, .28) !important;
    border-radius: 15px !important;
    color: var(--premium-text) !important;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .94), rgba(255, 255, 255, .70)) !important;
    box-shadow: inset 0 1px 2px rgba(15, 23, 42, .035) !important;
    font-size: .93rem !important;
    font-weight: 620 !important;
    letter-spacing: -.01em !important;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease !important;
  }

  body[data-page="account"] .account-card textarea,
  body[data-page="settings"] #settingsPanel textarea {
    min-height: 112px !important;
    padding-top: 16px !important;
    line-height: 1.5 !important;
  }

  body[data-page="account"] .account-info-row > input:focus,
  body[data-page="account"] .account-card input:focus,
  body[data-page="account"] .account-card textarea:focus,
  body[data-page="settings"] #settingsPanel input:focus,
  body[data-page="settings"] #settingsPanel textarea:focus {
    outline: 0 !important;
    border-color: rgba(25, 195, 125, .70) !important;
    box-shadow: 0 0 0 4px rgba(25, 195, 125, .11), inset 0 1px 2px rgba(15, 23, 42, .025) !important;
  }

  body[data-page="account"] .account-info-row > input[readonly] {
    color: #132033 !important;
    background: rgba(255, 255, 255, .78) !important;
  }

  body[data-page="account"] .account-info-row-wide {
    max-width: calc(50% - 21px) !important;
    margin-top: 30px !important;
  }

  body[data-page="account"] .profile-signature-box {
    display: grid !important;
    grid-template-columns: minmax(0, 1.1fr) 260px !important;
    gap: 38px !important;
    align-items: stretch !important;
    margin-top: 48px !important;
  }

  body[data-page="account"] .signature-dropzone {
    min-height: 190px !important;
    margin-top: 12px !important;
    display: grid !important;
    place-items: center !important;
    align-content: center !important;
    gap: 8px !important;
    border: 1.5px dashed rgba(148, 163, 184, .38) !important;
    border-radius: 18px !important;
    color: #66758b !important;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .74), rgba(255, 255, 255, .44)),
      radial-gradient(circle at 50% 20%, rgba(25, 195, 125, .08), transparent 38%) !important;
    text-align: center !important;
  }

  body[data-page="account"] .signature-dropzone b {
    width: 48px !important;
    height: 48px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 999px !important;
    color: var(--premium-green) !important;
    background: rgba(225, 255, 240, .92) !important;
    font-size: 1.65rem !important;
  }

  body[data-page="account"] .signature-dropzone strong {
    display: inline-flex !important;
    min-height: 40px !important;
    min-width: 128px !important;
    align-items: center !important;
    justify-content: center !important;
    border: 1px solid rgba(25, 195, 125, .58) !important;
    border-radius: 11px !important;
    color: var(--premium-green-dark) !important;
    background: rgba(255, 255, 255, .80) !important;
    font-size: .78rem !important;
    font-weight: 860 !important;
  }

  body[data-page="account"] .signature-preview,
  body[data-page="account"] .signature-preview.hidden {
    min-height: 190px !important;
    margin-top: 29px !important;
    display: grid !important;
    place-items: center !important;
    border: 1px solid rgba(15, 23, 42, .07) !important;
    border-radius: 18px !important;
    color: #64748b !important;
    background: rgba(255, 255, 255, .62) !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .7) !important;
  }

  body[data-page="account"] .signature-preview.hidden::before {
    content: "ยังไม่ได้แนบรูป" !important;
    font-weight: 830 !important;
  }

  body[data-page="account"] .account-password-heading {
    position: relative !important;
    min-height: 58px !important;
    padding-left: 74px !important;
    margin-bottom: 30px !important;
    background:
      radial-gradient(circle at 28px 28px, #d9faea 0 28px, transparent 29px),
      linear-gradient(#0f8b6f, #0f8b6f) 25px 19px / 7px 18px no-repeat !important;
  }

  body[data-page="account"] .account-password-heading::after {
    content: "Protected" !important;
    position: absolute !important;
    right: 0 !important;
    top: 2px !important;
    padding: 8px 14px !important;
    border: 1px solid rgba(25, 195, 125, .22) !important;
    border-radius: 999px !important;
    color: #08795a !important;
    background: rgba(225, 255, 240, .86) !important;
    box-shadow: 0 12px 30px rgba(25, 195, 125, .12) !important;
    font-size: .72rem !important;
    font-weight: 900 !important;
  }

  body[data-page="account"] .compact-password-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 28px !important;
  }

  body[data-page="account"] .password-strength-preview {
    display: grid !important;
    grid-template-columns: auto 1fr 1fr 1fr !important;
    gap: 9px !important;
    align-items: center !important;
    margin-top: 26px !important;
    color: var(--premium-subtext) !important;
    font-size: .76rem !important;
  }

  body[data-page="account"] .password-strength-preview i {
    grid-column: 2 / 5 !important;
    height: 8px !important;
    border-radius: 999px !important;
    background: linear-gradient(90deg, var(--premium-green) 0 36%, rgba(25, 195, 125, .22) 36% 64%, rgba(15, 23, 42, .08) 64% 100%) !important;
    box-shadow: 0 0 24px rgba(25, 195, 125, .22) !important;
  }

  body[data-page="account"] .confirm-actions,
  body[data-page="settings"] #settingsPanel .settings-footer {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 16px !important;
    margin-top: 10px !important;
    padding-top: 0 !important;
    border: 0 !important;
  }

  body[data-page="account"] .primary-button,
  body[data-page="settings"] .primary-button,
  body[data-page="account"] .account-card .primary-button,
  body[data-page="settings"] #settingsPanel .settings-footer .primary-button {
    min-height: 54px !important;
    min-width: 230px !important;
    padding: 0 30px !important;
    border: 0 !important;
    border-radius: 16px !important;
    color: #fff !important;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .16), rgba(255, 255, 255, 0)),
      linear-gradient(135deg, var(--premium-green), var(--premium-green-dark)) !important;
    box-shadow: 0 18px 38px rgba(25, 195, 125, .26), inset 0 1px 0 rgba(255, 255, 255, .24) !important;
    font-size: .92rem !important;
    font-weight: 900 !important;
    letter-spacing: -.01em !important;
    transition: transform .22s ease, box-shadow .22s ease, filter .22s ease !important;
  }

  body[data-page="account"] .primary-button:hover,
  body[data-page="settings"] .primary-button:hover {
    transform: translateY(-2px) !important;
    filter: saturate(1.05) !important;
    box-shadow: 0 24px 48px rgba(25, 195, 125, .32), inset 0 1px 0 rgba(255, 255, 255, .30) !important;
  }

  body[data-page="account"] .secondary-button,
  body[data-page="settings"] .secondary-button {
    min-height: 54px !important;
    border: 1px solid rgba(148, 163, 184, .28) !important;
    border-radius: 16px !important;
    color: #172033 !important;
    background: rgba(255, 255, 255, .74) !important;
    box-shadow: 0 14px 30px rgba(15, 23, 42, .055), inset 0 1px 0 rgba(255, 255, 255, .9) !important;
    font-size: .90rem !important;
    font-weight: 850 !important;
  }

  body[data-page="account"] .form-error,
  body[data-page="settings"] .form-error {
    border-radius: 16px !important;
  }

  body[data-page="settings"] #settingsPanel .settings-sections {
    display: grid !important;
    grid-template-columns: minmax(270px, .32fr) minmax(0, 1fr) !important;
    gap: 24px !important;
    align-items: start !important;
  }

  body[data-page="settings"] #settingsPanel .settings-sections::before {
    content: "Settings\A\Aเลือกเมนูตั้งค่าที่ต้องการปรับ ระบบจะเก็บค่าไว้กับร้านนี้โดยตรง";
    white-space: pre-line !important;
    display: block !important;
    padding: 24px !important;
    min-height: 220px !important;
    border: 1px solid var(--premium-border) !important;
    border-radius: 26px !important;
    color: var(--premium-subtext) !important;
    background: linear-gradient(180deg, rgba(255, 255, 255, .82), rgba(255, 255, 255, .58)) !important;
    box-shadow: 0 20px 52px rgba(15, 23, 42, .075) !important;
    font-size: .88rem !important;
    font-weight: 700 !important;
    line-height: 1.5 !important;
  }

  body[data-page="settings"] #settingsPanel .settings-sections::before::first-line {
    color: var(--premium-text) !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box {
    grid-column: 2 !important;
    margin: 0 0 18px !important;
    padding: 0 !important;
    overflow: hidden !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box summary {
    min-height: 96px !important;
    display: grid !important;
    grid-template-columns: 54px minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 18px !important;
    padding: 24px 28px !important;
    color: var(--premium-text) !important;
    font-size: 1rem !important;
    font-weight: 900 !important;
    background: rgba(255, 255, 255, .52) !important;
    cursor: pointer !important;
  }

  body[data-page="settings"] #settingsPanel .settings-summary-icon {
    width: 54px !important;
    height: 54px !important;
    border-radius: 18px !important;
    color: var(--premium-green-dark) !important;
    background: linear-gradient(180deg, #e6fff1, #d8f7e7) !important;
    box-shadow: 0 16px 34px rgba(25, 195, 125, .12) !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box[open] {
    border-color: rgba(25, 195, 125, .20) !important;
    box-shadow: var(--premium-shadow), 0 0 0 1px rgba(25, 195, 125, .05) !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box > :not(summary) {
    padding: 0 28px 28px !important;
  }

  body[data-page="settings"] #settingsPanel .settings-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 22px !important;
  }

  body[data-page="settings"] #settingsPanel .full-field {
    grid-column: 1 / -1 !important;
  }
}

/* v1.0.132 sidebar overlap/collapse repair for desktop and tablet-width browsers. */
@media (min-width: 641px) {
  body[data-page] .app-shell,
  body[data-page] .app-shell.loan-app {
    display: grid !important;
    grid-template-columns: 300px minmax(0, 1fr) !important;
    gap: 24px !important;
    align-items: start !important;
    width: min(100% - 32px, 1680px) !important;
    margin-inline: auto !important;
    overflow: visible !important;
  }

  body[data-page].nav-collapsed .app-shell,
  body[data-page].nav-collapsed .app-shell.loan-app {
    grid-template-columns: 96px minmax(0, 1fr) !important;
  }

  body[data-page] .quick-nav,
  body[data-page] .quick-nav.sidebar,
  body[data-page] .quick-nav.app-sidebar {
    position: sticky !important;
    top: 16px !important;
    z-index: 20 !important;
    width: 300px !important;
    min-width: 300px !important;
    max-width: 300px !important;
    height: calc(100vh - 32px) !important;
    min-height: 680px !important;
    margin: 0 !important;
    padding: 22px 18px 18px !important;
    overflow: hidden !important;
    border: 1px solid #dbe7ef !important;
    border-radius: 28px !important;
    background: rgba(255, 255, 255, .97) !important;
    box-shadow: 0 22px 48px rgba(15, 23, 42, .10) !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .side-brand {
    position: relative !important;
    display: grid !important;
    grid-template-columns: 70px minmax(0, 1fr) !important;
    grid-template-rows: 24px 44px !important;
    grid-template-areas: "logo eyebrow" "logo title" !important;
    gap: 0 17px !important;
    align-items: center !important;
    width: 100% !important;
    height: 98px !important;
    min-height: 98px !important;
    max-height: 98px !important;
    margin: 0 0 22px !important;
    padding: 0 34px 22px 0 !important;
    border: 0 !important;
    border-bottom: 1px solid #dbe7ef !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .side-program-logo {
    grid-area: logo !important;
    width: 70px !important;
    min-width: 70px !important;
    max-width: 70px !important;
    height: 70px !important;
    min-height: 70px !important;
    max-height: 70px !important;
    border-radius: 20px !important;
    margin: 0 !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .side-brand > span:not(.side-program-logo) {
    grid-area: eyebrow !important;
    align-self: end !important;
    margin: 0 !important;
    padding: 0 !important;
    font-family: Inter, "IBM Plex Sans Thai", system-ui, sans-serif !important;
    font-size: .78rem !important;
    font-weight: 800 !important;
    letter-spacing: .15em !important;
    line-height: 1 !important;
    white-space: nowrap !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .side-brand strong {
    grid-area: title !important;
    align-self: start !important;
    margin: 0 !important;
    padding: 0 !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 1.2rem !important;
    font-weight: 700 !important;
    line-height: 1.16 !important;
    white-space: nowrap !important;
    transform: none !important;
  }

  body[data-page] .quick-nav > .nav-collapse-button,
  body[data-page] .quick-nav .nav-collapse-button,
  body[data-page] .nav-collapse-button {
    position: absolute !important;
    top: 32px !important;
    right: 22px !important;
    left: auto !important;
    bottom: auto !important;
    z-index: 50 !important;
    display: inline-grid !important;
    grid-template-columns: 1fr !important;
    place-items: center !important;
    width: 22px !important;
    min-width: 22px !important;
    max-width: 22px !important;
    height: 22px !important;
    min-height: 22px !important;
    max-height: 22px !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #0f172a !important;
    font-size: 1.05rem !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    text-align: center !important;
    transform: none !important;
  }

  body[data-page] .quick-nav > .nav-collapse-button:hover,
  body[data-page] .quick-nav .nav-collapse-button:hover {
    background: transparent !important;
    color: #047857 !important;
    box-shadow: none !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .sidebar-link,
  body[data-page] .quick-nav .nav-group-toggle,
  body[data-page] .quick-nav .nav-text-link,
  body[data-page] .quick-nav .side-user-profile {
    grid-template-columns: 42px minmax(0, 1fr) 16px !important;
    width: 100% !important;
    height: 56px !important;
    min-height: 56px !important;
    max-height: 56px !important;
    margin: 0 0 10px !important;
    padding: 0 13px !important;
    border-radius: 18px !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .nav-icon,
  body[data-page] .quick-nav .settings-gear,
  body[data-page] .quick-nav .profile-avatar {
    width: 42px !important;
    min-width: 42px !important;
    max-width: 42px !important;
    height: 42px !important;
    min-height: 42px !important;
    max-height: 42px !important;
    border-radius: 14px !important;
  }

  body[data-page] .quick-nav .side-user {
    margin-top: auto !important;
  }

  body[data-page] .app-content,
  body[data-page] .content-area,
  body[data-page] .panel-stack {
    min-width: 0 !important;
  }

  body[data-page].nav-collapsed .quick-nav,
  body[data-page].nav-collapsed .quick-nav.sidebar,
  body[data-page].nav-collapsed .quick-nav.app-sidebar {
    width: 96px !important;
    min-width: 96px !important;
    max-width: 96px !important;
    padding: 18px 14px !important;
    align-items: center !important;
  }

  body[data-page].nav-collapsed .quick-nav .side-brand {
    grid-template-columns: 56px !important;
    grid-template-rows: 56px !important;
    grid-template-areas: "logo" !important;
    justify-content: center !important;
    width: 56px !important;
    height: 78px !important;
    min-height: 78px !important;
    max-height: 78px !important;
    padding: 0 0 18px !important;
    margin: 0 0 18px !important;
  }

  body[data-page].nav-collapsed .quick-nav .side-program-logo {
    width: 56px !important;
    min-width: 56px !important;
    max-width: 56px !important;
    height: 56px !important;
    min-height: 56px !important;
    max-height: 56px !important;
  }

  body[data-page].nav-collapsed .quick-nav > .nav-collapse-button,
  body[data-page].nav-collapsed .quick-nav .nav-collapse-button {
    top: 34px !important;
    right: 5px !important;
    width: 14px !important;
    min-width: 14px !important;
    max-width: 14px !important;
    height: 18px !important;
    min-height: 18px !important;
    max-height: 18px !important;
    color: #047857 !important;
  }

  body[data-page].nav-collapsed .quick-nav .side-brand > span:not(.side-program-logo),
  body[data-page].nav-collapsed .quick-nav .side-brand strong,
  body[data-page].nav-collapsed .quick-nav .nav-label,
  body[data-page].nav-collapsed .quick-nav .profile-copy,
  body[data-page].nav-collapsed .quick-nav .nav-chevron {
    display: none !important;
  }
}

@media (max-width: 980px) {
  body[data-page="account"],
  body[data-page="settings"] {
    background:
      radial-gradient(circle at 92% 0, rgba(25, 195, 125, .15), transparent 32%),
      linear-gradient(180deg, #fbfffd, var(--premium-bg)) !important;
    font-family: Inter, "Noto Sans Thai", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  body[data-page="account"] .account-settings-page,
  body[data-page="settings"] #settingsPanel.settings-panel {
    padding: 24px 18px 122px !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .account-settings-page .panel-title h2,
  body[data-page="settings"] #settingsPanel .panel-title h2 {
    font-size: 2.4rem !important;
    letter-spacing: -.045em !important;
  }

  body[data-page="account"] .account-tabs {
    display: flex !important;
    gap: 8px !important;
    overflow-x: auto !important;
    padding-bottom: 10px !important;
  }

  body[data-page="account"] .account-tab {
    flex: 0 0 auto !important;
    min-height: 54px !important;
    padding: 0 16px !important;
    border-radius: 16px !important;
    border: 1px solid rgba(15, 23, 42, .08) !important;
    background: rgba(255, 255, 255, .78) !important;
  }

  body[data-page="account"] .account-tab.active {
    color: #08795a !important;
    border-color: rgba(25, 195, 125, .25) !important;
    background: rgba(225, 255, 240, .82) !important;
  }

  body[data-page="account"] #userProfileForm,
  body[data-page="account"] #userManageForm,
  body[data-page="account"] #userManageList,
  body[data-page="settings"] #settingsPanel .settings-box {
    padding: 18px !important;
    border-radius: 22px !important;
    background: rgba(255, 255, 255, .86) !important;
    box-shadow: 0 16px 38px rgba(15, 23, 42, .08) !important;
  }

  body[data-page="account"] .account-profile-card,
  body[data-page="account"] .account-password-card {
    padding: 22px !important;
    border-radius: 22px !important;
  }

  body[data-page="account"] .account-profile-hero,
  body[data-page="account"] .account-profile-readonly-grid,
  body[data-page="account"] .profile-signature-box,
  body[data-page="account"] .compact-password-grid,
  body[data-page="settings"] #settingsPanel .settings-sections,
  body[data-page="settings"] #settingsPanel .settings-grid {
    grid-template-columns: 1fr !important;
  }

  body[data-page="account"] .account-info-row-wide {
    max-width: none !important;
  }

  body[data-page="account"] .account-profile-orb {
    width: 84px !important;
    height: 84px !important;
  }

  body[data-page="account"] .confirm-actions,
  body[data-page="settings"] #settingsPanel .settings-footer {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }

  body[data-page="account"] .primary-button,
  body[data-page="settings"] .primary-button,
  body[data-page="account"] .secondary-button,
  body[data-page="settings"] .secondary-button {
    width: 100% !important;
    min-height: 52px !important;
    border-radius: 16px !important;
  }

  body[data-page="settings"] #settingsPanel .settings-sections::before {
    display: none !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box summary {
    min-height: 78px !important;
    grid-template-columns: 46px minmax(0, 1fr) auto !important;
    padding: 16px !important;
  }
}

/* v1.0.121 repaired premium account/settings layout. */
@media (min-width: 981px) {
  body[data-page="account"],
  body[data-page="settings"] {
    --ui-green: #19c37d;
    --ui-green-dark: #0e9f6e;
    --ui-ink: #0f172a;
    --ui-muted: #64748b;
    --ui-line: rgba(15, 23, 42, .09);
    --ui-card: rgba(255, 255, 255, .86);
    overflow-x: hidden !important;
    background:
      radial-gradient(circle at 84px 120px, rgba(25, 195, 125, .10), transparent 260px),
      radial-gradient(circle at 92% 8%, rgba(25, 195, 125, .13), transparent 320px),
      linear-gradient(180deg, #fbfefc 0%, #f4f7f5 100%) !important;
    color: var(--ui-ink) !important;
    font-family: Inter, "Noto Sans Thai", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  body[data-page="account"] .app-shell,
  body[data-page="settings"] .app-shell {
    display: grid !important;
    grid-template-columns: 276px minmax(0, 1fr) !important;
    gap: 32px !important;
    width: 100% !important;
    min-height: 100vh !important;
    padding: 24px 34px 24px 24px !important;
    background: transparent !important;
  }

  body[data-page="account"] .content-shell,
  body[data-page="settings"] .content-shell {
    width: 100% !important;
    min-width: 0 !important;
    min-height: calc(100vh - 48px) !important;
    padding: 26px 0 84px !important;
    overflow: visible !important;
    background: transparent !important;
  }

  body[data-page="account"] .content-shell::before,
  body[data-page="settings"] .content-shell::before,
  body[data-page="account"] .account-settings-page::before,
  body[data-page="settings"] #settingsPanel.settings-panel::before {
    display: none !important;
  }

  body[data-page="account"] .app-topbar,
  body[data-page="settings"] .app-topbar,
  body[data-page="account"] .mobile-create-nav,
  body[data-page="settings"] .mobile-create-nav {
    display: none !important;
  }

  body[data-page="account"] .quick-nav,
  body[data-page="settings"] .quick-nav {
    position: sticky !important;
    top: 24px !important;
    width: auto !important;
    height: calc(100vh - 48px) !important;
    margin: 0 !important;
    padding: 20px !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
    overflow: hidden auto !important;
    border: 1px solid var(--ui-line) !important;
    border-radius: 28px !important;
    background: linear-gradient(180deg, rgba(255,255,255,.90), rgba(255,255,255,.72)) !important;
    box-shadow: 0 24px 70px rgba(15, 23, 42, .10), inset 0 1px 0 rgba(255,255,255,.95) !important;
    backdrop-filter: blur(22px) saturate(1.12) !important;
    -webkit-backdrop-filter: blur(22px) saturate(1.12) !important;
  }

  body[data-page="account"] .quick-nav::after,
  body[data-page="settings"] .quick-nav::after {
    display: none !important;
  }

  body[data-page="account"] .side-brand,
  body[data-page="settings"] .side-brand {
    position: relative !important;
    display: grid !important;
    grid-template-columns: 54px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 14px !important;
    width: 100% !important;
    height: auto !important;
    margin: 0 0 18px !important;
    padding: 10px 8px 18px !important;
    border: 0 !important;
    border-bottom: 1px solid var(--ui-line) !important;
    border-radius: 0 !important;
    color: var(--ui-ink) !important;
    background: transparent !important;
    box-shadow: none !important;
    font-size: .72rem !important;
    text-transform: uppercase !important;
    letter-spacing: .09em !important;
  }

  body[data-page="account"] .side-brand::before,
  body[data-page="settings"] .side-brand::before {
    content: "฿" !important;
    display: grid !important;
    width: 54px !important;
    height: 54px !important;
    place-items: center !important;
    border-radius: 17px !important;
    color: #fff !important;
    background: linear-gradient(145deg, #22c985, #0e9f6e) !important;
    box-shadow: 0 16px 36px rgba(25,195,125,.28) !important;
    font-size: 1.75rem !important;
    font-weight: 950 !important;
    letter-spacing: 0 !important;
  }

  body[data-page="account"] .side-brand::after,
  body[data-page="settings"] .side-brand::after {
    display: none !important;
    content: none !important;
  }

  body[data-page="account"] .side-brand > span,
  body[data-page="settings"] .side-brand > span {
    display: block !important;
    grid-column: 2 !important;
    grid-row: 1 !important;
    color: var(--ui-green-dark) !important;
    font-size: .72rem !important;
    font-weight: 900 !important;
    letter-spacing: .12em !important;
  }

  body[data-page="account"] .side-brand strong,
  body[data-page="settings"] .side-brand strong {
    display: block !important;
    grid-column: 2 !important;
    grid-row: 1 !important;
    align-self: end !important;
    margin-top: 18px !important;
    color: var(--ui-ink) !important;
    font-size: 1rem !important;
    font-weight: 900 !important;
    letter-spacing: -.02em !important;
    text-transform: none !important;
  }

  body[data-page="account"] .side-brand .side-program-logo,
  body[data-page="settings"] .side-brand .side-program-logo {
    display: none !important;
  }

  body[data-page="account"] .nav-collapse-button,
  body[data-page="settings"] .nav-collapse-button {
    display: none !important;
  }

  body[data-page="account"] .sidebar-link,
  body[data-page="settings"] .sidebar-link,
  body[data-page="account"] .nav-group-toggle,
  body[data-page="settings"] .nav-group-toggle,
  body[data-page="account"] .nav-text-link,
  body[data-page="settings"] .nav-text-link,
  body[data-page="account"] .side-user-profile,
  body[data-page="settings"] .side-user-profile {
    display: grid !important;
    grid-template-columns: 40px minmax(0, 1fr) auto !important;
    align-items: center !important;
    justify-items: stretch !important;
    width: 100% !important;
    min-height: 54px !important;
    margin: 0 !important;
    padding: 8px 12px !important;
    gap: 12px !important;
    border: 1px solid transparent !important;
    border-radius: 16px !important;
    color: #475569 !important;
    background: transparent !important;
    box-shadow: none !important;
    text-decoration: none !important;
    transition: background .18s ease, border-color .18s ease, color .18s ease, transform .18s ease !important;
  }

  body[data-page="account"] .sidebar-link:hover,
  body[data-page="settings"] .sidebar-link:hover,
  body[data-page="account"] .nav-group-toggle:hover,
  body[data-page="settings"] .nav-group-toggle:hover,
  body[data-page="account"] .nav-text-link:hover,
  body[data-page="settings"] .nav-text-link:hover {
    transform: translateY(-1px) !important;
    color: var(--ui-green-dark) !important;
    background: rgba(25, 195, 125, .06) !important;
    border-color: rgba(25, 195, 125, .14) !important;
  }

  body[data-page="account"] .nav-icon,
  body[data-page="settings"] .nav-icon,
  body[data-page="account"] .settings-gear,
  body[data-page="settings"] .settings-gear {
    width: 38px !important;
    height: 38px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 13px !important;
    color: currentColor !important;
    background: rgba(241, 245, 249, .88) !important;
  }

  body[data-page="account"] .nav-label,
  body[data-page="settings"] .nav-label {
    display: block !important;
    color: currentColor !important;
    font-size: .88rem !important;
    font-weight: 800 !important;
    line-height: 1.1 !important;
    text-align: left !important;
    white-space: normal !important;
  }

  body[data-page="account"] .nav-label::after,
  body[data-page="settings"] .nav-label::after {
    content: none !important;
    display: none !important;
  }

  body[data-page="account"] .nav-group,
  body[data-page="settings"] .nav-group,
  body[data-page="account"] .nav-group-items,
  body[data-page="settings"] .nav-group-items {
    display: grid !important;
    gap: 6px !important;
  }

  body[data-page="account"] .nav-group-items,
  body[data-page="settings"] .nav-group-items {
    padding-left: 18px !important;
    border-left: 1px solid rgba(15, 23, 42, .08) !important;
    margin: 2px 0 8px 20px !important;
  }

  body[data-page="account"] a[href="#accountPanel"],
  body[data-page="settings"] a[href="#settingsPanel"],
  body[data-page="account"] .sidebar-link.active,
  body[data-page="settings"] .sidebar-link.active {
    color: #08795a !important;
    background: linear-gradient(180deg, rgba(226, 255, 240, .92), rgba(238, 255, 247, .78)) !important;
    border-color: rgba(25, 195, 125, .22) !important;
    box-shadow: 0 12px 30px rgba(25, 195, 125, .13) !important;
  }

  body[data-page="account"] .side-user,
  body[data-page="settings"] .side-user {
    display: grid !important;
    gap: 8px !important;
    margin-top: auto !important;
    padding-top: 18px !important;
    border-top: 1px solid var(--ui-line) !important;
  }

  body[data-page="account"] .profile-avatar,
  body[data-page="settings"] .profile-avatar {
    width: 38px !important;
    height: 38px !important;
    margin: 0 !important;
    border-radius: 13px !important;
    color: var(--ui-green-dark) !important;
    background: rgba(232, 255, 243, .94) !important;
    font-size: .9rem !important;
    font-weight: 900 !important;
  }

  body[data-page="account"] .profile-copy,
  body[data-page="settings"] .profile-copy {
    display: grid !important;
    gap: 1px !important;
  }

  body[data-page="account"] .profile-copy span,
  body[data-page="settings"] .profile-copy span {
    color: var(--ui-muted) !important;
    font-size: .68rem !important;
    font-weight: 800 !important;
  }

  body[data-page="account"] .profile-copy strong,
  body[data-page="settings"] .profile-copy strong {
    color: var(--ui-ink) !important;
    font-size: .86rem !important;
    font-weight: 900 !important;
  }

  body[data-page="account"] .logout-nav-link,
  body[data-page="settings"] .logout-nav-link {
    color: #ef4444 !important;
  }

  body[data-page="account"] .account-settings-page,
  body[data-page="settings"] #settingsPanel.settings-panel {
    width: 100% !important;
    max-width: 1180px !important;
    margin: 0 auto !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .account-settings-page .panel-title,
  body[data-page="settings"] #settingsPanel .panel-title {
    margin: 0 0 20px !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
  }

  body[data-page="account"] .account-kicker,
  body[data-page="settings"] #settingsPanel .panel-title::before {
    display: inline-flex !important;
    margin-bottom: 8px !important;
    color: var(--ui-green-dark) !important;
    font-size: .72rem !important;
    font-weight: 900 !important;
    letter-spacing: .12em !important;
    text-transform: uppercase !important;
  }

  body[data-page="settings"] #settingsPanel .panel-title::before {
    content: "ตั้งค่าระบบ" !important;
  }

  body[data-page="account"] .account-settings-page .panel-title h2,
  body[data-page="settings"] #settingsPanel .panel-title h2 {
    margin: 0 !important;
    color: var(--ui-ink) !important;
    font-size: clamp(2.5rem, 4vw, 3.65rem) !important;
    font-weight: 900 !important;
    line-height: .98 !important;
    letter-spacing: -.055em !important;
  }

  body[data-page="account"] .account-settings-page .panel-title h2::after,
  body[data-page="settings"] #settingsPanel .panel-title h2::after {
    content: none !important;
  }

  body[data-page="account"] .account-settings-page .panel-title p,
  body[data-page="settings"] #settingsPanel .panel-title p {
    max-width: 560px !important;
    margin: 10px 0 0 !important;
    color: var(--ui-muted) !important;
    font-size: .95rem !important;
    font-weight: 650 !important;
    line-height: 1.45 !important;
  }

  body[data-page="account"] .account-shop-summary {
    display: none !important;
  }

  body[data-page="account"] .account-tabs {
    display: flex !important;
    width: 100% !important;
    margin: 22px 0 28px !important;
    padding: 0 !important;
    gap: 28px !important;
    border: 0 !important;
    border-bottom: 1px solid var(--ui-line) !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .account-tab {
    position: relative !important;
    min-height: 54px !important;
    padding: 0 2px 14px !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 10px !important;
    flex: 0 0 auto !important;
    border: 0 !important;
    border-radius: 0 !important;
    color: #475569 !important;
    background: transparent !important;
    box-shadow: none !important;
    font-size: .92rem !important;
    font-weight: 800 !important;
  }

  body[data-page="account"] .account-tab::after {
    content: "" !important;
    position: absolute !important;
    left: 0 !important;
    right: 0 !important;
    bottom: -1px !important;
    height: 3px !important;
    border-radius: 999px !important;
    background: linear-gradient(90deg, var(--ui-green), var(--ui-green-dark)) !important;
    transform: scaleX(0) !important;
    transform-origin: left !important;
    transition: transform .2s ease !important;
  }

  body[data-page="account"] .account-tab.active {
    color: var(--ui-green-dark) !important;
  }

  body[data-page="account"] .account-tab.active::after {
    transform: scaleX(1) !important;
  }

  body[data-page="account"] .account-tab-icon {
    display: grid !important;
    width: 34px !important;
    height: 34px !important;
    place-items: center !important;
    border-radius: 12px !important;
    color: currentColor !important;
    background: rgba(255, 255, 255, .76) !important;
    border: 1px solid var(--ui-line) !important;
    box-shadow: none !important;
    font-size: .82rem !important;
  }

  body[data-page="account"] .account-card,
  body[data-page="account"] .account-grid {
    display: block !important;
    min-width: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .account-card.hidden {
    display: none !important;
  }

  body[data-page="account"] #userProfileForm,
  body[data-page="account"] #userManageForm,
  body[data-page="account"] #userManageList {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
  }

  body[data-page="account"] #userProfileForm > .panel-title {
    display: none !important;
  }

  body[data-page="account"] .account-profile-card,
  body[data-page="account"] .account-password-card {
    position: relative !important;
    margin: 0 0 24px !important;
    padding: 28px 30px !important;
    border: 1px solid var(--ui-line) !important;
    border-radius: 26px !important;
    background: var(--ui-card) !important;
    box-shadow: 0 20px 52px rgba(15, 23, 42, .075), inset 0 1px 0 rgba(255,255,255,.92) !important;
    backdrop-filter: blur(14px) !important;
  }

  body[data-page="account"] .account-profile-card::before,
  body[data-page="account"] .account-password-card::before {
    content: "" !important;
    position: absolute !important;
    left: 28px !important;
    top: 31px !important;
    width: 4px !important;
    height: 26px !important;
    border-radius: 999px !important;
    background: var(--ui-green) !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .account-profile-hero {
    display: grid !important;
    grid-template-columns: minmax(360px, 1fr) minmax(300px, 420px) !important;
    align-items: start !important;
    gap: 32px !important;
    margin: 0 0 34px !important;
  }

  body[data-page="account"] .account-section-title {
    display: block !important;
    min-width: 0 !important;
    padding-left: 22px !important;
  }

  body[data-page="account"] .account-section-title > span {
    display: none !important;
  }

  body[data-page="account"] .account-section-title h3,
  body[data-page="account"] .account-password-heading strong {
    max-width: 340px !important;
    margin: 0 !important;
    color: var(--ui-ink) !important;
    font-size: 1.25rem !important;
    font-weight: 900 !important;
    line-height: 1.16 !important;
    letter-spacing: -.025em !important;
  }

  body[data-page="account"] .account-section-title p,
  body[data-page="account"] .account-password-heading span {
    max-width: 420px !important;
    margin: 8px 0 0 !important;
    color: var(--ui-muted) !important;
    font-size: .92rem !important;
    font-weight: 600 !important;
    line-height: 1.45 !important;
  }

  body[data-page="account"] .account-profile-picture {
    display: grid !important;
    grid-template-columns: 96px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 22px !important;
  }

  body[data-page="account"] .account-profile-orb {
    display: grid !important;
    width: 96px !important;
    height: 96px !important;
    place-items: center !important;
    border-radius: 28px !important;
    color: #fff !important;
    background: linear-gradient(145deg, #34d399, #0e9f6e) !important;
    box-shadow: 0 18px 36px rgba(25, 195, 125, .22) !important;
    font-size: 0 !important;
  }

  body[data-page="account"] .account-profile-orb::after {
    content: "◎" !important;
    font-size: 1.65rem !important;
    line-height: 1 !important;
  }

  body[data-page="account"] .account-profile-picture strong {
    color: var(--ui-ink) !important;
    font-size: 1rem !important;
    font-weight: 900 !important;
  }

  body[data-page="account"] .account-profile-picture p {
    margin: 6px 0 12px !important;
    color: var(--ui-muted) !important;
    font-size: .82rem !important;
    font-weight: 600 !important;
  }

  body[data-page="account"] .account-upload-photo-button {
    display: inline-flex !important;
    width: auto !important;
    min-height: 40px !important;
    margin: 0 !important;
    padding: 0 18px !important;
    align-items: center !important;
    justify-content: center !important;
    border: 1px solid rgba(25, 195, 125, .42) !important;
    border-radius: 12px !important;
    color: var(--ui-green-dark) !important;
    background: rgba(255, 255, 255, .80) !important;
    box-shadow: none !important;
    font-size: .78rem !important;
    font-weight: 850 !important;
  }

  body[data-page="account"] .account-profile-readonly-grid,
  body[data-page="account"] .compact-password-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 20px 26px !important;
  }

  body[data-page="account"] .compact-password-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }

  body[data-page="account"] .account-info-row-wide {
    max-width: calc(50% - 13px) !important;
    margin-top: 20px !important;
  }

  body[data-page="account"] .account-info-row,
  body[data-page="account"] .account-card label {
    position: relative !important;
    display: grid !important;
    gap: 8px !important;
  }

  body[data-page="account"] .account-info-row > span,
  body[data-page="account"] .account-card label > span {
    display: block !important;
    color: #1f2937 !important;
    font-size: .80rem !important;
    font-weight: 850 !important;
    letter-spacing: 0 !important;
  }

  body[data-page="account"] .account-info-row > span::before,
  body[data-page="account"] .account-card label > span::before {
    display: none !important;
    content: none !important;
  }

  body[data-page="account"] .account-info-row::after {
    content: "✓" !important;
    position: absolute !important;
    right: 16px !important;
    bottom: 14px !important;
    color: var(--ui-green) !important;
    font-weight: 900 !important;
    pointer-events: none !important;
  }

  body[data-page="account"] .account-info-row > input,
  body[data-page="account"] .account-card input,
  body[data-page="account"] .account-card textarea,
  body[data-page="account"] .account-card select {
    width: 100% !important;
    min-height: 50px !important;
    padding: 0 42px 0 16px !important;
    border: 1px solid rgba(148, 163, 184, .34) !important;
    border-radius: 14px !important;
    color: var(--ui-ink) !important;
    background: rgba(255,255,255,.86) !important;
    box-shadow: inset 0 1px 2px rgba(15,23,42,.035) !important;
    font-size: .93rem !important;
    font-weight: 700 !important;
    letter-spacing: 0 !important;
  }

  body[data-page="account"] .account-card textarea {
    min-height: 106px !important;
    padding-top: 14px !important;
    line-height: 1.5 !important;
  }

  body[data-page="account"] .profile-signature-box {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 230px !important;
    gap: 26px !important;
    align-items: stretch !important;
    margin-top: 30px !important;
  }

  body[data-page="account"] .signature-dropzone {
    display: grid !important;
    min-height: 154px !important;
    margin-top: 10px !important;
    place-items: center !important;
    align-content: center !important;
    gap: 6px !important;
    border: 1.5px dashed rgba(148, 163, 184, .42) !important;
    border-radius: 18px !important;
    color: var(--ui-muted) !important;
    background: rgba(255,255,255,.58) !important;
    text-align: center !important;
  }

  body[data-page="account"] .signature-dropzone b {
    display: grid !important;
    width: 42px !important;
    height: 42px !important;
    place-items: center !important;
    border-radius: 999px !important;
    color: var(--ui-green) !important;
    background: rgba(226, 255, 240, .92) !important;
    font-size: 1.35rem !important;
  }

  body[data-page="account"] .signature-dropzone strong {
    display: inline-flex !important;
    min-height: 38px !important;
    min-width: 120px !important;
    align-items: center !important;
    justify-content: center !important;
    border: 1px solid rgba(25,195,125,.45) !important;
    border-radius: 11px !important;
    color: var(--ui-green-dark) !important;
    background: #fff !important;
    font-size: .76rem !important;
    font-weight: 850 !important;
  }

  body[data-page="account"] .signature-preview,
  body[data-page="account"] .signature-preview.hidden {
    display: grid !important;
    min-height: 154px !important;
    margin-top: 28px !important;
    place-items: center !important;
    border: 1px solid var(--ui-line) !important;
    border-radius: 18px !important;
    color: var(--ui-muted) !important;
    background: rgba(255,255,255,.70) !important;
    font-weight: 850 !important;
  }

  body[data-page="account"] .signature-preview.hidden::before {
    content: "ยังไม่ได้แนบรูป" !important;
  }

  body[data-page="account"] .account-password-heading {
    min-height: auto !important;
    margin: 0 0 22px !important;
    padding: 0 120px 0 22px !important;
    background: none !important;
  }

  body[data-page="account"] .account-password-heading::after {
    content: "Protected" !important;
    position: absolute !important;
    right: 30px !important;
    top: 28px !important;
    padding: 8px 14px !important;
    border: 1px solid rgba(25, 195, 125, .24) !important;
    border-radius: 999px !important;
    color: var(--ui-green-dark) !important;
    background: rgba(231, 255, 243, .88) !important;
    font-size: .72rem !important;
    font-weight: 900 !important;
  }

  body[data-page="account"] .password-strength-preview {
    display: grid !important;
    grid-template-columns: auto minmax(220px, 1fr) !important;
    gap: 8px 12px !important;
    align-items: center !important;
    margin-top: 20px !important;
    color: var(--ui-muted) !important;
    font-size: .78rem !important;
  }

  body[data-page="account"] .password-strength-preview i {
    grid-column: 2 !important;
    height: 7px !important;
    border-radius: 999px !important;
    background: linear-gradient(90deg, var(--ui-green) 0 36%, rgba(25,195,125,.16) 36% 66%, rgba(15,23,42,.08) 66% 100%) !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .password-strength-preview small {
    display: none !important;
  }

  body[data-page="account"] .confirm-actions,
  body[data-page="settings"] #settingsPanel .settings-footer {
    display: flex !important;
    justify-content: flex-end !important;
    gap: 14px !important;
    margin: 18px 0 0 !important;
    padding: 0 !important;
    border: 0 !important;
  }

  body[data-page="account"] .primary-button,
  body[data-page="settings"] .primary-button {
    width: auto !important;
    min-width: 190px !important;
    min-height: 48px !important;
    padding: 0 26px !important;
    border: 0 !important;
    border-radius: 14px !important;
    color: #fff !important;
    background: linear-gradient(135deg, var(--ui-green), var(--ui-green-dark)) !important;
    box-shadow: 0 14px 28px rgba(25,195,125,.20) !important;
    font-size: .88rem !important;
    font-weight: 900 !important;
  }

  body[data-page="account"] .secondary-button,
  body[data-page="settings"] .secondary-button {
    width: auto !important;
    min-width: 150px !important;
    min-height: 48px !important;
    padding: 0 22px !important;
    border: 1px solid rgba(148, 163, 184, .30) !important;
    border-radius: 14px !important;
    color: var(--ui-ink) !important;
    background: rgba(255,255,255,.80) !important;
    box-shadow: none !important;
    font-size: .86rem !important;
    font-weight: 850 !important;
  }

  body[data-page="settings"] #settingsPanel .settings-sections {
    display: grid !important;
    grid-template-columns: 260px minmax(0, 1fr) !important;
    gap: 22px !important;
    align-items: start !important;
  }

  body[data-page="settings"] #settingsPanel .settings-sections::before {
    content: "ตั้งค่า\A\Aเลือกหมวดจากเมนูด้านซ้าย ปรับเฉพาะค่าที่จำเป็นและกดบันทึก";
    display: block !important;
    white-space: pre-line !important;
    padding: 22px !important;
    border: 1px solid var(--ui-line) !important;
    border-radius: 24px !important;
    color: var(--ui-muted) !important;
    background: var(--ui-card) !important;
    box-shadow: 0 16px 42px rgba(15,23,42,.06) !important;
    font-size: .88rem !important;
    font-weight: 700 !important;
    line-height: 1.5 !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box {
    grid-column: 2 !important;
    margin: 0 0 14px !important;
    padding: 0 !important;
    overflow: hidden !important;
    border: 1px solid var(--ui-line) !important;
    border-radius: 22px !important;
    background: var(--ui-card) !important;
    box-shadow: 0 16px 42px rgba(15,23,42,.06) !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box summary {
    min-height: 76px !important;
    display: grid !important;
    grid-template-columns: 46px minmax(0, 1fr) auto !important;
    gap: 14px !important;
    align-items: center !important;
    padding: 16px 20px !important;
    color: var(--ui-ink) !important;
    font-size: .96rem !important;
    font-weight: 900 !important;
    background: transparent !important;
  }

  body[data-page="settings"] #settingsPanel .settings-summary-icon {
    width: 46px !important;
    height: 46px !important;
    border-radius: 15px !important;
    color: var(--ui-green-dark) !important;
    background: rgba(226, 255, 240, .88) !important;
    box-shadow: none !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box > :not(summary) {
    padding: 0 20px 22px !important;
  }

  body[data-page="settings"] #settingsPanel .settings-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 18px !important;
  }

  body[data-page="settings"] #settingsPanel .full-field {
    grid-column: 1 / -1 !important;
  }
}

@media (max-width: 980px) {
  body[data-page="account"] .account-settings-page,
  body[data-page="settings"] #settingsPanel.settings-panel {
    padding: 22px 16px 110px !important;
  }

  body[data-page="account"] .account-settings-page .panel-title h2,
  body[data-page="settings"] #settingsPanel .panel-title h2 {
    font-size: 2.25rem !important;
  }

  body[data-page="account"] .account-profile-card,
  body[data-page="account"] .account-password-card,
  body[data-page="account"] #userProfileForm,
  body[data-page="account"] #userManageForm,
  body[data-page="account"] #userManageList {
    border-radius: 22px !important;
    background: rgba(255,255,255,.88) !important;
  }

  body[data-page="account"] .account-profile-hero,
  body[data-page="account"] .account-profile-readonly-grid,
  body[data-page="account"] .compact-password-grid,
  body[data-page="account"] .profile-signature-box {
    grid-template-columns: 1fr !important;
  }
}

/* v1.0.122 compact account layout + 8 character password policy UI. */
@media (min-width: 981px) {
  body[data-page="account"] .content {
    padding-top: 22px !important;
  }

  body[data-page="account"] .account-settings-page {
    max-width: 1120px !important;
    padding: 32px 34px 42px !important;
  }

  body[data-page="account"] .account-settings-page .panel-title {
    margin-bottom: 18px !important;
  }

  body[data-page="account"] .account-settings-page .panel-title h2 {
    font-size: clamp(2.45rem, 4.8vw, 4.6rem) !important;
    line-height: .92 !important;
  }

  body[data-page="account"] .account-tabs {
    margin: 20px 0 24px !important;
    gap: 24px !important;
  }

  body[data-page="account"] .account-tab {
    min-height: 52px !important;
    padding: 0 6px !important;
    gap: 10px !important;
    font-size: .94rem !important;
  }

  body[data-page="account"] .account-tab-icon {
    width: 38px !important;
    height: 38px !important;
    border-radius: 13px !important;
  }

  body[data-page="account"] #userProfileForm,
  body[data-page="account"] #userManageForm,
  body[data-page="account"] #userManageList {
    gap: 18px !important;
    padding: 0 !important;
  }

  body[data-page="account"] .account-profile-card,
  body[data-page="account"] .account-password-card {
    padding: 28px 30px !important;
    border-radius: 28px !important;
    box-shadow: 0 16px 44px rgba(15,23,42,.065) !important;
  }

  body[data-page="account"] .account-profile-card::before,
  body[data-page="account"] .account-password-card::before {
    left: 26px !important;
    top: 30px !important;
    height: 24px !important;
  }

  body[data-page="account"] .account-profile-hero {
    grid-template-columns: minmax(0, 1fr) 380px !important;
    gap: 28px !important;
    margin-bottom: 18px !important;
  }

  body[data-page="account"] .account-section-title {
    grid-template-columns: 22px minmax(0, 1fr) !important;
    gap: 12px !important;
  }

  body[data-page="account"] .account-section-title > span {
    width: 5px !important;
    height: 34px !important;
    border-radius: 999px !important;
  }

  body[data-page="account"] .account-section-title h3,
  body[data-page="account"] .account-password-heading strong {
    font-size: 1.28rem !important;
    line-height: 1.08 !important;
  }

  body[data-page="account"] .account-section-title p,
  body[data-page="account"] .account-password-heading span {
    max-width: 520px !important;
    margin-top: 6px !important;
    font-size: .86rem !important;
    line-height: 1.35 !important;
  }

  body[data-page="account"] .account-profile-picture {
    grid-template-columns: 92px minmax(0, 1fr) !important;
    gap: 18px !important;
    justify-content: start !important;
    text-align: left !important;
  }

  body[data-page="account"] .account-profile-orb {
    width: 84px !important;
    height: 84px !important;
    border-radius: 24px !important;
    box-shadow: 0 14px 28px rgba(25,195,125,.18) !important;
  }

  body[data-page="account"] .account-profile-orb::after {
    font-size: 1.35rem !important;
  }

  body[data-page="account"] .account-profile-readonly-grid,
  body[data-page="account"] .compact-password-grid {
    gap: 14px 20px !important;
  }

  body[data-page="account"] .account-info-row,
  body[data-page="account"] .account-card label {
    gap: 7px !important;
  }

  body[data-page="account"] .account-info-row > span,
  body[data-page="account"] .account-card label > span {
    font-size: .75rem !important;
  }

  body[data-page="account"] .account-info-row > input,
  body[data-page="account"] .account-card input,
  body[data-page="account"] .account-card textarea,
  body[data-page="account"] .account-card select {
    min-height: 42px !important;
    padding: 0 34px 0 13px !important;
    border-radius: 12px !important;
    font-size: .84rem !important;
  }

  body[data-page="account"] .account-info-row::after {
    right: 12px !important;
    bottom: 10px !important;
    font-size: .9rem !important;
  }

  body[data-page="account"] .account-info-row-wide {
    max-width: calc(50% - 10px) !important;
    margin-top: 14px !important;
  }

  body[data-page="account"] .profile-signature-box {
    grid-template-columns: minmax(0, 1fr) 190px !important;
    gap: 20px !important;
    margin-top: 22px !important;
  }

  body[data-page="account"] .signature-dropzone {
    min-height: 108px !important;
    margin-top: 8px !important;
    gap: 4px !important;
    border-radius: 16px !important;
  }

  body[data-page="account"] .signature-dropzone b {
    width: 34px !important;
    height: 34px !important;
    font-size: 1rem !important;
  }

  body[data-page="account"] .signature-dropzone em,
  body[data-page="account"] .signature-dropzone small {
    font-size: .72rem !important;
  }

  body[data-page="account"] .signature-dropzone strong {
    min-height: 32px !important;
    min-width: 106px !important;
    border-radius: 10px !important;
    font-size: .70rem !important;
  }

  body[data-page="account"] .signature-preview,
  body[data-page="account"] .signature-preview.hidden {
    min-height: 108px !important;
    margin-top: 25px !important;
    border-radius: 16px !important;
    font-size: .78rem !important;
  }

  body[data-page="account"] .field-help {
    margin-top: 6px !important;
    font-size: .72rem !important;
  }

  body[data-page="account"] .account-password-card {
    padding-bottom: 24px !important;
  }

  body[data-page="account"] .account-password-heading {
    margin-bottom: 18px !important;
    padding: 0 120px 0 22px !important;
  }

  body[data-page="account"] .account-password-heading::after {
    top: 24px !important;
    right: 28px !important;
    padding: 6px 12px !important;
    font-size: .66rem !important;
  }

  body[data-page="account"] .password-strength-preview {
    grid-template-columns: auto minmax(180px, 1fr) !important;
    margin-top: 12px !important;
    font-size: .72rem !important;
  }

  body[data-page="account"] .password-strength-preview::after {
    content: "อย่างน้อย 8 ตัว มี A-Z, a-z และตัวเลข" !important;
    grid-column: 1 / -1 !important;
    color: var(--ui-muted) !important;
    font-size: .68rem !important;
    font-weight: 700 !important;
  }

  body[data-page="account"] .confirm-actions {
    margin-top: 14px !important;
  }

  body[data-page="account"] .primary-button,
  body[data-page="account"] .secondary-button {
    min-height: 42px !important;
    border-radius: 12px !important;
    font-size: .80rem !important;
  }

  body[data-page="account"] .primary-button {
    min-width: 168px !important;
  }

  body[data-page="account"] .secondary-button {
    min-width: 130px !important;
  }
}

@media (max-width: 980px) {
  body[data-page="account"] .account-profile-card,
  body[data-page="account"] .account-password-card {
    padding: 20px 16px !important;
  }

  body[data-page="account"] .account-profile-orb {
    width: 72px !important;
    height: 72px !important;
  }

  body[data-page="account"] .account-info-row > input,
  body[data-page="account"] .account-card input,
  body[data-page="account"] .account-card textarea,
  body[data-page="account"] .account-card select {
    min-height: 46px !important;
    font-size: .9rem !important;
  }

  body[data-page="account"] .signature-dropzone,
  body[data-page="account"] .signature-preview,
  body[data-page="account"] .signature-preview.hidden {
    min-height: 112px !important;
  }
}

/* v1.0.123 editor management polish + switch permissions. */
@media (min-width: 981px) {
  body[data-page="account"] #accountManageMount,
  body[data-page="account"] #accountUsersMount {
    max-width: 100% !important;
  }

  body[data-page="account"] #userManageForm {
    position: relative !important;
    display: grid !important;
    gap: 18px !important;
    padding: 28px 30px 30px !important;
    overflow: hidden !important;
    border: 1px solid rgba(15,23,42,.07) !important;
    border-radius: 28px !important;
    background:
      radial-gradient(circle at 92% 8%, rgba(25,195,125,.10), transparent 30%),
      linear-gradient(180deg, rgba(255,255,255,.94), rgba(255,255,255,.82)) !important;
    box-shadow: 0 18px 50px rgba(15,23,42,.07) !important;
  }

  body[data-page="account"] #userManageForm::before {
    content: "" !important;
    position: absolute !important;
    left: 28px !important;
    top: 34px !important;
    width: 5px !important;
    height: 32px !important;
    border-radius: 999px !important;
    background: linear-gradient(180deg, var(--ui-green), var(--ui-green-dark)) !important;
  }

  body[data-page="account"] #userManageForm > .panel-title {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    gap: 18px !important;
    align-items: end !important;
    margin: 0 0 2px !important;
    padding-left: 22px !important;
  }

  body[data-page="account"] #userManageForm > .panel-title h2 {
    margin: 0 !important;
    color: var(--ui-ink) !important;
    font-size: clamp(1.6rem, 2.1vw, 2.15rem) !important;
    line-height: 1.08 !important;
    letter-spacing: 0 !important;
  }

  body[data-page="account"] #userManageForm > .panel-title p {
    max-width: 560px !important;
    margin: 6px 0 0 !important;
    color: var(--ui-muted) !important;
    font-size: .88rem !important;
    font-weight: 700 !important;
    line-height: 1.45 !important;
  }

  body[data-page="account"] .user-manage-tabs {
    justify-self: end !important;
    display: inline-flex !important;
    gap: 4px !important;
    min-height: 42px !important;
    margin: -58px 0 8px auto !important;
    padding: 4px !important;
    border: 1px solid rgba(148,163,184,.18) !important;
    border-radius: 999px !important;
    background: rgba(248,250,252,.82) !important;
    box-shadow: inset 0 1px 2px rgba(15,23,42,.03) !important;
  }

  body[data-page="account"] .user-manage-tab {
    min-height: 34px !important;
    padding: 0 16px !important;
    border: 0 !important;
    border-radius: 999px !important;
    color: var(--ui-muted) !important;
    background: transparent !important;
    box-shadow: none !important;
    font-size: .74rem !important;
    font-weight: 900 !important;
    white-space: nowrap !important;
  }

  body[data-page="account"] .user-manage-tab.active {
    color: #fff !important;
    background: linear-gradient(135deg, var(--ui-green), var(--ui-green-dark)) !important;
    box-shadow: 0 10px 22px rgba(25,195,125,.20) !important;
  }

  body[data-page="account"] #managedUserEditor {
    display: grid !important;
    gap: 16px !important;
  }

  body[data-page="account"] #managedUserEditor > .field-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 14px 18px !important;
  }

  body[data-page="account"] #managedUserEditor label:not(.checkbox-line) {
    display: grid !important;
    gap: 7px !important;
  }

  body[data-page="account"] #managedUserEditor label:not(.checkbox-line) > span {
    color: #1f2937 !important;
    font-size: .75rem !important;
    font-weight: 850 !important;
  }

  body[data-page="account"] #managedUserEditor input[type="text"],
  body[data-page="account"] #managedUserEditor input[type="tel"],
  body[data-page="account"] #managedUserEditor input[type="password"] {
    min-height: 42px !important;
    padding: 0 13px !important;
    border: 1px solid rgba(148,163,184,.32) !important;
    border-radius: 12px !important;
    background: rgba(255,255,255,.92) !important;
    box-shadow: inset 0 1px 2px rgba(15,23,42,.03) !important;
    color: var(--ui-ink) !important;
    font-size: .84rem !important;
    font-weight: 750 !important;
  }

  body[data-page="account"] #managedUserEditor input:focus {
    border-color: rgba(25,195,125,.58) !important;
    box-shadow: 0 0 0 4px rgba(25,195,125,.10) !important;
    outline: 0 !important;
  }

  body[data-page="account"] .permission-box {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
    margin-top: 2px !important;
    padding: 14px !important;
    border: 1px solid rgba(15,23,42,.07) !important;
    border-radius: 20px !important;
    background: rgba(248,250,252,.70) !important;
  }

  body[data-page="account"] .permission-box::before {
    content: "สิทธิ์การใช้งาน" !important;
    grid-column: 1 / -1 !important;
    margin: 0 0 2px !important;
    color: var(--ui-ink) !important;
    font-size: .9rem !important;
    font-weight: 950 !important;
  }

  body[data-page="account"] .checkbox-line {
    position: relative !important;
    display: flex !important;
    min-height: 58px !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 16px !important;
    padding: 12px 14px !important;
    border: 1px solid rgba(148,163,184,.18) !important;
    border-radius: 16px !important;
    background: rgba(255,255,255,.78) !important;
    box-shadow: 0 8px 22px rgba(15,23,42,.035) !important;
    cursor: pointer !important;
    transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease, background .18s ease !important;
  }

  body[data-page="account"] .checkbox-line:hover {
    transform: translateY(-1px) !important;
    border-color: rgba(25,195,125,.28) !important;
    box-shadow: 0 12px 28px rgba(15,23,42,.055) !important;
  }

  body[data-page="account"] .checkbox-line span {
    order: 1 !important;
    color: var(--ui-ink) !important;
    font-size: .82rem !important;
    font-weight: 850 !important;
    line-height: 1.25 !important;
  }

  body[data-page="account"] .checkbox-line input[type="checkbox"] {
    order: 2 !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    position: relative !important;
    flex: 0 0 auto !important;
    width: 48px !important;
    height: 28px !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: #dbe4ee !important;
    box-shadow: inset 0 2px 5px rgba(15,23,42,.12) !important;
    cursor: pointer !important;
    transition: background .18s ease, box-shadow .18s ease !important;
  }

  body[data-page="account"] .checkbox-line input[type="checkbox"]::before {
    content: "" !important;
    position: absolute !important;
    left: 3px !important;
    top: 3px !important;
    width: 22px !important;
    height: 22px !important;
    border-radius: 999px !important;
    background: #fff !important;
    box-shadow: 0 3px 8px rgba(15,23,42,.18) !important;
    transition: transform .18s ease !important;
  }

  body[data-page="account"] .checkbox-line input[type="checkbox"]:checked {
    background: linear-gradient(135deg, var(--ui-green), var(--ui-green-dark)) !important;
    box-shadow: 0 8px 18px rgba(25,195,125,.20), inset 0 1px 2px rgba(255,255,255,.18) !important;
  }

  body[data-page="account"] .checkbox-line input[type="checkbox"]:checked::before {
    transform: translateX(20px) !important;
  }

  body[data-page="account"] .checkbox-line:has(input:checked) {
    border-color: rgba(25,195,125,.28) !important;
    background: rgba(236,253,245,.82) !important;
  }

  body[data-page="account"] #managedUserEditor .confirm-actions {
    display: flex !important;
    justify-content: flex-end !important;
    gap: 12px !important;
    margin-top: 2px !important;
  }

  body[data-page="account"] #managedUserEditor .form-error {
    margin: 0 !important;
    padding: 10px 12px !important;
    border-radius: 12px !important;
    font-size: .78rem !important;
  }
}

@media (max-width: 980px) {
  body[data-page="account"] #userManageForm {
    padding: 20px 16px !important;
  }

  body[data-page="account"] #managedUserEditor > .field-grid,
  body[data-page="account"] .permission-box {
    grid-template-columns: 1fr !important;
  }

  body[data-page="account"] .checkbox-line {
    display: flex !important;
    min-height: 54px !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 11px 12px !important;
    border: 1px solid rgba(148,163,184,.20) !important;
    border-radius: 15px !important;
    background: rgba(255,255,255,.84) !important;
  }

  body[data-page="account"] .checkbox-line input[type="checkbox"] {
    appearance: none !important;
    -webkit-appearance: none !important;
    position: relative !important;
    width: 46px !important;
    height: 27px !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: #dbe4ee !important;
  }

  body[data-page="account"] .checkbox-line input[type="checkbox"]::before {
    content: "" !important;
    position: absolute !important;
    left: 3px !important;
    top: 3px !important;
    width: 21px !important;
    height: 21px !important;
    border-radius: 999px !important;
    background: #fff !important;
    box-shadow: 0 3px 8px rgba(15,23,42,.16) !important;
    transition: transform .18s ease !important;
  }

  body[data-page="account"] .checkbox-line input[type="checkbox"]:checked {
    background: linear-gradient(135deg, var(--ui-green), var(--ui-green-dark)) !important;
  }

  body[data-page="account"] .checkbox-line input[type="checkbox"]:checked::before {
    transform: translateX(19px) !important;
  }
}

/* v1.0.124 account security list + clearer permission switches. */
body[data-page="account"] .checkbox-line input[type="checkbox"] {
  background: #cfd4dc !important;
  border: 1px solid rgba(148, 163, 184, .26) !important;
  box-shadow: inset 0 2px 4px rgba(15, 23, 42, .10) !important;
}

body[data-page="account"] .checkbox-line input[type="checkbox"]::before {
  background: #fff !important;
  box-shadow: 0 2px 7px rgba(15, 23, 42, .22) !important;
}

body[data-page="account"] .checkbox-line input[type="checkbox"]:checked {
  background: linear-gradient(135deg, #19C37D, #0E9F6E) !important;
  border-color: rgba(14, 159, 110, .44) !important;
  box-shadow: 0 9px 20px rgba(25, 195, 125, .22), inset 0 1px 2px rgba(255, 255, 255, .26) !important;
}

body[data-page="account"] .checkbox-line input[type="checkbox"]:disabled {
  opacity: .72 !important;
  cursor: not-allowed !important;
}

body[data-page="account"] .checkbox-line:has(input:disabled) {
  cursor: not-allowed !important;
}

body[data-page="account"] .checkbox-line:has(input:checked) span {
  color: #0f7f59 !important;
}

body[data-page="account"] #userManageList {
  display: grid !important;
  gap: 12px !important;
  margin: 6px 0 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
}

body[data-page="account"] #userManageList.hidden {
  display: none !important;
}

body[data-page="account"] .user-list-row {
  display: grid !important;
  grid-template-columns: 46px minmax(0, 1fr) auto !important;
  gap: 14px !important;
  align-items: center !important;
  min-height: 86px !important;
  padding: 16px !important;
  border: 1px solid rgba(15, 23, 42, .07) !important;
  border-radius: 22px !important;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .92), rgba(248, 250, 252, .80)),
    radial-gradient(circle at 92% 12%, rgba(25, 195, 125, .12), transparent 34%) !important;
  box-shadow: 0 14px 34px rgba(15, 23, 42, .055) !important;
}

body[data-page="account"] .user-list-row.is-owner {
  border-color: rgba(25, 195, 125, .20) !important;
  background:
    linear-gradient(135deg, rgba(236, 253, 245, .70), rgba(255, 255, 255, .92)),
    radial-gradient(circle at 90% 18%, rgba(25, 195, 125, .16), transparent 36%) !important;
}

body[data-page="account"] .user-list-avatar {
  display: grid !important;
  width: 46px !important;
  height: 46px !important;
  place-items: center !important;
  border-radius: 16px !important;
  color: #0f7f59 !important;
  background: rgba(236, 253, 245, .92) !important;
  font-size: .86rem !important;
  font-weight: 950 !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .72) !important;
}

body[data-page="account"] .user-list-main {
  display: grid !important;
  min-width: 0 !important;
  gap: 2px !important;
}

body[data-page="account"] .user-list-main strong {
  color: var(--ui-ink, #0f172a) !important;
  font-size: .96rem !important;
  font-weight: 950 !important;
  line-height: 1.2 !important;
  letter-spacing: 0 !important;
}

body[data-page="account"] .user-list-meta,
body[data-page="account"] .user-list-permission {
  color: var(--ui-muted, #64748b) !important;
  font-size: .78rem !important;
  font-weight: 760 !important;
  line-height: 1.35 !important;
}

body[data-page="account"] .user-list-permission {
  color: #334155 !important;
}

body[data-page="account"] .user-list-actions {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  gap: 8px !important;
}

body[data-page="account"] .user-list-actions .status-pill,
body[data-page="account"] .user-list-actions .owner-badge {
  display: inline-flex !important;
  min-height: 34px !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0 12px !important;
  border-radius: 999px !important;
  font-size: .72rem !important;
  font-weight: 900 !important;
}

body[data-page="account"] .user-list-actions .owner-badge {
  color: #0f7f59 !important;
  background: rgba(236, 253, 245, .92) !important;
  border: 1px solid rgba(25, 195, 125, .16) !important;
}

body[data-page="account"] .user-list-actions .secondary-button {
  min-width: 92px !important;
  min-height: 38px !important;
  padding: 0 14px !important;
  border-radius: 13px !important;
  font-size: .76rem !important;
  font-weight: 950 !important;
}

body[data-page="account"] [data-account-panel="users"] #userManageForm,
body[data-page="account"] #userManageModal:not(.hidden) #userManageForm {
  font-family: inherit !important;
}

@media (max-width: 980px) {
  body[data-page="account"] .user-list-row {
    grid-template-columns: 42px minmax(0, 1fr) !important;
    gap: 12px !important;
    padding: 14px !important;
  }

  body[data-page="account"] .user-list-avatar {
    width: 42px !important;
    height: 42px !important;
    border-radius: 14px !important;
  }

  body[data-page="account"] .user-list-actions {
    grid-column: 1 / -1 !important;
    justify-content: stretch !important;
    flex-wrap: wrap !important;
  }

  body[data-page="account"] .user-list-actions .secondary-button {
    flex: 1 1 120px !important;
  }
}

/* v1.0.125 compact permission switches; removes oversized glossy toggle look. */
body[data-page="account"] .permission-box {
  gap: 10px !important;
  padding: 12px !important;
}

body[data-page="account"] .checkbox-line {
  min-height: 46px !important;
  padding: 9px 12px !important;
  border-radius: 14px !important;
  background: rgba(255, 255, 255, .88) !important;
  box-shadow: 0 5px 14px rgba(15, 23, 42, .028) !important;
  transform: none !important;
}

body[data-page="account"] .checkbox-line:hover {
  transform: none !important;
  box-shadow: 0 7px 18px rgba(15, 23, 42, .04) !important;
}

body[data-page="account"] .checkbox-line span {
  font-size: .8rem !important;
  font-weight: 850 !important;
}

body[data-page="account"] .checkbox-line input[type="checkbox"],
body[data-page="account"] .checkbox-line input[type="checkbox"]:not(:checked) {
  box-sizing: border-box !important;
  inline-size: 40px !important;
  block-size: 24px !important;
  width: 40px !important;
  min-width: 40px !important;
  max-width: 40px !important;
  height: 24px !important;
  min-height: 24px !important;
  max-height: 24px !important;
  flex: 0 0 40px !important;
  padding: 0 !important;
  border: 1px solid rgba(148, 163, 184, .28) !important;
  border-radius: 999px !important;
  background: #d1d5db !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, .10) !important;
  filter: none !important;
  transform: none !important;
}

body[data-page="account"] .checkbox-line input[type="checkbox"]::before {
  left: 2px !important;
  top: 2px !important;
  inline-size: 18px !important;
  block-size: 18px !important;
  width: 18px !important;
  height: 18px !important;
  background: #fff !important;
  box-shadow: 0 1px 4px rgba(15, 23, 42, .22) !important;
  transform: translateX(0) !important;
}

body[data-page="account"] .checkbox-line input[type="checkbox"]:checked {
  background: #19C37D !important;
  border-color: rgba(14, 159, 110, .32) !important;
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, .20), 0 4px 10px rgba(25, 195, 125, .16) !important;
}

body[data-page="account"] .checkbox-line input[type="checkbox"]:checked::before {
  transform: translateX(16px) !important;
}

body[data-page="account"] .checkbox-line:has(input:checked) {
  background: rgba(248, 250, 252, .92) !important;
  border-color: rgba(148, 163, 184, .20) !important;
}

@media (max-width: 980px) {
  body[data-page="account"] .checkbox-line {
    min-height: 44px !important;
    padding: 8px 11px !important;
  }

  body[data-page="account"] .checkbox-line input[type="checkbox"],
  body[data-page="account"] .checkbox-line input[type="checkbox"]:not(:checked) {
    inline-size: 38px !important;
    block-size: 23px !important;
    width: 38px !important;
    min-width: 38px !important;
    max-width: 38px !important;
    height: 23px !important;
    min-height: 23px !important;
    max-height: 23px !important;
    flex-basis: 38px !important;
  }

  body[data-page="account"] .checkbox-line input[type="checkbox"]::before {
    width: 17px !important;
    height: 17px !important;
  }

  body[data-page="account"] .checkbox-line input[type="checkbox"]:checked::before {
    transform: translateX(15px) !important;
  }
}

/* v1.0.126 unified desktop sidebar across dashboard, settings and account. */
@media (min-width: 641px) {
  body[data-page="account"] .app-shell,
  body[data-page="settings"] .app-shell,
  body[data-page="account"].nav-collapsed .app-shell,
  body[data-page="settings"].nav-collapsed .app-shell {
    width: min(1600px, calc(100% - 40px)) !important;
    max-width: 1600px !important;
    margin: 0 auto !important;
    padding: 22px 0 !important;
    gap: 22px !important;
    align-items: start !important;
  }

  body[data-page="account"] .app-shell,
  body[data-page="settings"] .app-shell {
    grid-template-columns: 264px minmax(0, 1fr) !important;
  }

  body[data-page="account"].nav-collapsed .app-shell,
  body[data-page="settings"].nav-collapsed .app-shell {
    grid-template-columns: 88px minmax(0, 1fr) !important;
  }

  body[data-page="account"] .quick-nav,
  body[data-page="settings"] .quick-nav {
    position: sticky !important;
    top: 22px !important;
    width: 264px !important;
    min-width: 264px !important;
    max-width: 264px !important;
    height: auto !important;
    min-height: calc(100vh - 44px) !important;
    max-height: calc(100vh - 44px) !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 8px !important;
    margin: 0 !important;
    padding: 16px !important;
    overflow: auto !important;
    border: 1px solid #dde8f0 !important;
    border-radius: 22px !important;
    background: #fff !important;
    color: #0f172a !important;
    box-shadow: 0 18px 42px rgba(15, 23, 42, .08) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }

  body[data-page="account"].nav-collapsed .quick-nav,
  body[data-page="settings"].nav-collapsed .quick-nav {
    width: 88px !important;
    min-width: 88px !important;
    max-width: 88px !important;
    padding: 14px 12px !important;
    align-items: center !important;
  }

  body[data-page="account"] .side-brand,
  body[data-page="settings"] .side-brand {
    position: relative !important;
    display: grid !important;
    width: auto !important;
    height: auto !important;
    min-height: auto !important;
    margin: 0 0 8px !important;
    padding: 4px 4px 16px !important;
    place-items: start !important;
    gap: 4px !important;
    border: 0 !important;
    border-bottom: 1px solid #e2e8f0 !important;
    border-radius: 0 !important;
    color: #0f172a !important;
    background: transparent !important;
    box-shadow: none !important;
    font-size: inherit !important;
    text-transform: none !important;
  }

  body[data-page="account"] .side-brand::after,
  body[data-page="settings"] .side-brand::after {
    content: none !important;
    display: none !important;
  }

  body[data-page="account"] .side-brand > span:not(.side-program-logo),
  body[data-page="account"] .side-brand strong,
  body[data-page="settings"] .side-brand > span:not(.side-program-logo),
  body[data-page="settings"] .side-brand strong {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
    color: inherit !important;
    width: auto !important;
    height: auto !important;
    font-size: inherit !important;
    line-height: inherit !important;
  }

  body[data-page="account"] .side-brand > span:not(.side-program-logo),
  body[data-page="settings"] .side-brand > span:not(.side-program-logo) {
    color: #0f766e !important;
    font-size: .72rem !important;
    font-weight: 950 !important;
    letter-spacing: .16em !important;
    text-transform: uppercase !important;
  }

  body[data-page="account"] .side-brand strong,
  body[data-page="settings"] .side-brand strong {
    color: #0f172a !important;
    font-size: 1.28rem !important;
    font-weight: 950 !important;
    line-height: 1.15 !important;
  }

  body[data-page="account"] .nav-collapse-button,
  body[data-page="settings"] .nav-collapse-button {
    position: absolute !important;
    top: 16px !important;
    right: 16px !important;
    z-index: 3 !important;
    display: grid !important;
    width: 38px !important;
    height: 38px !important;
    min-width: 38px !important;
    min-height: 38px !important;
    place-items: center !important;
    margin: 0 !important;
    border: 1px solid #dbe7ef !important;
    border-radius: 13px !important;
    color: #0f172a !important;
    background: #fff !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .sidebar-link,
  body[data-page="account"] .nav-group-toggle,
  body[data-page="account"] .nav-text-link,
  body[data-page="settings"] .sidebar-link,
  body[data-page="settings"] .nav-group-toggle,
  body[data-page="settings"] .nav-text-link {
    display: grid !important;
    width: 100% !important;
    min-height: 46px !important;
    grid-template-columns: 34px minmax(0, 1fr) auto !important;
    align-items: center !important;
    justify-items: stretch !important;
    gap: 10px !important;
    margin: 0 !important;
    padding: 9px 11px !important;
    border: 1px solid transparent !important;
    border-radius: 14px !important;
    color: #475569 !important;
    background: transparent !important;
    box-shadow: none !important;
    text-align: left !important;
    text-decoration: none !important;
    font-size: .93rem !important;
    font-weight: 850 !important;
    line-height: 1.2 !important;
    transform: none !important;
  }

  body[data-page="account"] .sidebar-link:hover,
  body[data-page="account"] .nav-group-toggle:hover,
  body[data-page="account"] .nav-text-link:hover,
  body[data-page="settings"] .sidebar-link:hover,
  body[data-page="settings"] .nav-group-toggle:hover,
  body[data-page="settings"] .nav-text-link:hover {
    border-color: #bbf7d0 !important;
    background: #dcfce7 !important;
    color: #047857 !important;
    transform: none !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .sidebar-link.active,
  body[data-page="settings"] .sidebar-link.active,
  body[data-page="account"] .side-user-profile,
  body[data-page="settings"] .settings-nav-link[href="#settingsPanel"] {
    border-color: #bbf7d0 !important;
    background: #dcfce7 !important;
    color: #047857 !important;
    box-shadow: none !important;
  }

  body[data-page="settings"] .side-user-profile,
  body[data-page="account"] .settings-nav-link[href="#settingsPanel"] {
    border-color: transparent !important;
    background: transparent !important;
    color: #475569 !important;
  }

  body[data-page="account"] .nav-icon,
  body[data-page="account"] .settings-gear,
  body[data-page="settings"] .nav-icon,
  body[data-page="settings"] .settings-gear {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 12px !important;
    background: #f1f5f9 !important;
    color: currentColor !important;
  }

  body[data-page="account"] .nav-label,
  body[data-page="settings"] .nav-label {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
    width: auto !important;
    height: auto !important;
    color: currentColor !important;
    font-size: .93rem !important;
    font-weight: 850 !important;
    line-height: 1.2 !important;
    text-align: left !important;
    white-space: normal !important;
  }

  body[data-page="account"] .nav-label::before,
  body[data-page="account"] .nav-label::after,
  body[data-page="settings"] .nav-label::before,
  body[data-page="settings"] .nav-label::after {
    content: none !important;
    display: none !important;
  }

  body[data-page="account"] .mobile-create-nav,
  body[data-page="settings"] .mobile-create-nav,
  body[data-page="account"] .mobile-only-nav-link,
  body[data-page="settings"] .mobile-only-nav-link {
    display: none !important;
  }

  body[data-page="account"] .nav-group,
  body[data-page="settings"] .nav-group,
  body[data-page="account"] .nav-group-items,
  body[data-page="settings"] .nav-group-items {
    display: grid !important;
    gap: 8px !important;
  }

  body[data-page="account"] .nav-group-items,
  body[data-page="settings"] .nav-group-items {
    padding-left: 14px !important;
    margin: 0 0 0 16px !important;
    border-left: 1px solid #e2e8f0 !important;
  }

  body[data-page="account"] .nav-group:not(.is-open) .nav-group-items,
  body[data-page="settings"] .nav-group:not(.is-open) .nav-group-items {
    display: none !important;
  }

  body[data-page="account"] .side-user,
  body[data-page="settings"] .side-user {
    display: grid !important;
    gap: 8px !important;
    margin-top: auto !important;
    padding: 14px 0 0 !important;
    border-top: 1px solid #e2e8f0 !important;
  }

  body[data-page="account"] .side-user-profile,
  body[data-page="settings"] .side-user-profile {
    display: grid !important;
    width: 100% !important;
    min-height: 46px !important;
    grid-template-columns: 34px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 10px !important;
    margin: 0 !important;
    padding: 9px 11px !important;
    border-radius: 14px !important;
  }

  body[data-page="account"] .profile-avatar,
  body[data-page="settings"] .profile-avatar {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    margin: 0 !important;
    border-radius: 12px !important;
    color: #047857 !important;
    background: #dcfce7 !important;
    font-size: .82rem !important;
    font-weight: 950 !important;
  }

  body[data-page="account"] .profile-copy,
  body[data-page="settings"] .profile-copy {
    display: grid !important;
    gap: 0 !important;
    min-width: 0 !important;
  }

  body[data-page="account"] .profile-copy span,
  body[data-page="settings"] .profile-copy span {
    color: #64748b !important;
    font-size: .68rem !important;
    font-weight: 800 !important;
  }

  body[data-page="account"] .profile-copy strong,
  body[data-page="settings"] .profile-copy strong {
    color: #0f172a !important;
    font-size: .86rem !important;
    font-weight: 950 !important;
  }

  body[data-page="account"].nav-collapsed .side-brand strong,
  body[data-page="account"].nav-collapsed .side-brand > span:not(.side-program-logo),
  body[data-page="account"].nav-collapsed .nav-label,
  body[data-page="account"].nav-collapsed .profile-copy,
  body[data-page="account"].nav-collapsed .nav-chevron,
  body[data-page="settings"].nav-collapsed .side-brand strong,
  body[data-page="settings"].nav-collapsed .side-brand > span:not(.side-program-logo),
  body[data-page="settings"].nav-collapsed .nav-label,
  body[data-page="settings"].nav-collapsed .profile-copy,
  body[data-page="settings"].nav-collapsed .nav-chevron {
    display: none !important;
  }

  body[data-page="account"].nav-collapsed .sidebar-link,
  body[data-page="account"].nav-collapsed .nav-group-toggle,
  body[data-page="account"].nav-collapsed .nav-text-link,
  body[data-page="account"].nav-collapsed .side-user-profile,
  body[data-page="settings"].nav-collapsed .sidebar-link,
  body[data-page="settings"].nav-collapsed .nav-group-toggle,
  body[data-page="settings"].nav-collapsed .nav-text-link,
  body[data-page="settings"].nav-collapsed .side-user-profile {
    grid-template-columns: 1fr !important;
    justify-items: center !important;
    width: 56px !important;
    min-width: 56px !important;
    max-width: 56px !important;
    height: 56px !important;
    min-height: 56px !important;
    padding: 0 !important;
    border-radius: 16px !important;
  }

  body[data-page="account"].nav-collapsed .side-brand,
  body[data-page="settings"].nav-collapsed .side-brand {
    width: 56px !important;
    min-width: 56px !important;
    max-width: 56px !important;
    padding: 0 0 14px !important;
    place-items: center !important;
  }
}

/* v1.0.127 final sidebar lock: keep every desktop page identical to Dashboard. */
@media (min-width: 641px) {
  body,
  button,
  input,
  select,
  textarea {
    font-family: Inter, "Noto Sans Thai", "Sarabun", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  body[data-page] .app-shell,
  body[data-page] .app-shell.loan-app {
    grid-template-columns: 264px minmax(0, 1fr) !important;
    gap: 22px !important;
  }

  body[data-page].nav-collapsed .app-shell,
  body[data-page].nav-collapsed .app-shell.loan-app {
    grid-template-columns: 88px minmax(0, 1fr) !important;
  }

  body[data-page] .quick-nav,
  body[data-page] .quick-nav.sidebar,
  body[data-page] .quick-nav.app-sidebar {
    position: sticky !important;
    top: 22px !important;
    width: 264px !important;
    min-width: 264px !important;
    max-width: 264px !important;
    min-height: calc(100vh - 44px) !important;
    max-height: calc(100vh - 44px) !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 8px !important;
    margin: 0 !important;
    padding: 16px !important;
    overflow: auto !important;
    border: 1px solid #dde8f0 !important;
    border-radius: 22px !important;
    background: #fff !important;
    color: #0f172a !important;
    box-shadow: 0 18px 42px rgba(15, 23, 42, .08) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    transform: none !important;
  }

  body[data-page].nav-collapsed .quick-nav,
  body[data-page].nav-collapsed .quick-nav.sidebar,
  body[data-page].nav-collapsed .quick-nav.app-sidebar {
    width: 88px !important;
    min-width: 88px !important;
    max-width: 88px !important;
    padding: 14px 12px !important;
    align-items: center !important;
  }

  body[data-page] .quick-nav .side-brand {
    display: grid !important;
    grid-template-columns: 58px minmax(0, 1fr) !important;
    grid-template-areas: "logo eyebrow" "logo title" !important;
    align-items: center !important;
    column-gap: 14px !important;
    row-gap: 0 !important;
    width: 100% !important;
    min-height: 74px !important;
    margin: 0 0 16px !important;
    padding: 4px 4px 18px !important;
    border: 0 !important;
    border-bottom: 1px solid #e2e8f0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    text-align: left !important;
  }

  body[data-page] .quick-nav .side-program-logo {
    grid-area: logo !important;
    display: grid !important;
    width: 58px !important;
    height: 58px !important;
    min-width: 58px !important;
    place-items: center !important;
    border-radius: 16px !important;
    background: linear-gradient(145deg, #19c37d, #0e9f6e) !important;
    color: #fff !important;
    font-size: 1.35rem !important;
    font-weight: 950 !important;
    box-shadow: 0 18px 30px rgba(25, 195, 125, .22) !important;
  }

  body[data-page] .quick-nav .side-brand > span:not(.side-program-logo) {
    grid-area: eyebrow !important;
    display: block !important;
    color: #0f766e !important;
    font-size: .78rem !important;
    font-weight: 950 !important;
    line-height: 1.05 !important;
    letter-spacing: .16em !important;
    text-transform: uppercase !important;
  }

  body[data-page] .quick-nav .side-brand strong {
    grid-area: title !important;
    display: block !important;
    color: #0f172a !important;
    font-size: 1.28rem !important;
    font-weight: 950 !important;
    line-height: 1.1 !important;
    letter-spacing: 0 !important;
  }

  body[data-page] .quick-nav .side-brand::before,
  body[data-page] .quick-nav .side-brand::after {
    display: none !important;
    content: none !important;
  }

  body[data-page] .nav-collapse-button {
    position: absolute !important;
    top: 18px !important;
    right: 18px !important;
    z-index: 4 !important;
    display: grid !important;
    width: auto !important;
    height: auto !important;
    min-width: 0 !important;
    min-height: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    color: #0f172a !important;
    box-shadow: none !important;
    font-size: 1.2rem !important;
    font-weight: 950 !important;
    line-height: 1 !important;
  }

  body[data-page] .quick-nav .sidebar-link,
  body[data-page] .quick-nav .nav-group-toggle,
  body[data-page] .quick-nav .nav-text-link,
  body[data-page] .quick-nav .side-user-profile {
    display: grid !important;
    grid-template-columns: 34px minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 12px !important;
    width: 100% !important;
    min-height: 46px !important;
    margin: 0 !important;
    padding: 9px 11px !important;
    border: 1px solid transparent !important;
    border-radius: 14px !important;
    background: transparent !important;
    color: #475569 !important;
    box-shadow: none !important;
    text-align: left !important;
    text-decoration: none !important;
    font-size: .98rem !important;
    font-weight: 850 !important;
    line-height: 1.2 !important;
    letter-spacing: 0 !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .nav-label {
    display: block !important;
    width: auto !important;
    height: auto !important;
    color: currentColor !important;
    font-size: .98rem !important;
    font-weight: 850 !important;
    line-height: 1.2 !important;
    letter-spacing: 0 !important;
    opacity: 1 !important;
    visibility: visible !important;
    text-align: left !important;
  }

  body[data-page] .quick-nav .nav-icon,
  body[data-page] .quick-nav .settings-gear {
    display: grid !important;
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    min-height: 34px !important;
    place-items: center !important;
    border-radius: 12px !important;
    background: #f1f5f9 !important;
    color: currentColor !important;
    box-shadow: none !important;
  }

  body[data-page] .quick-nav .sidebar-link:hover,
  body[data-page] .quick-nav .nav-group-toggle:hover,
  body[data-page] .quick-nav .nav-text-link:hover,
  body[data-page] .quick-nav .sidebar-link.active,
  body[data-page] .quick-nav .nav-group-toggle.active,
  body[data-page="account"] .side-user-profile,
  body[data-page="settings"] .settings-nav-link[href="#settingsPanel"] {
    border-color: #9ff3c6 !important;
    background: #eafff4 !important;
    color: #047857 !important;
    box-shadow: none !important;
  }

  body[data-page="settings"] .side-user-profile,
  body[data-page="account"] .settings-nav-link[href="#settingsPanel"] {
    border-color: transparent !important;
    background: transparent !important;
    color: #475569 !important;
  }

  body[data-page] .quick-nav .nav-group-items {
    display: grid !important;
    gap: 8px !important;
    margin: 0 0 0 16px !important;
    padding-left: 14px !important;
    border-left: 1px solid #e2e8f0 !important;
  }

  body[data-page] .quick-nav .nav-group:not(.is-open) .nav-group-items {
    display: none !important;
  }

  body[data-page] .quick-nav .mobile-create-nav,
  body[data-page] .quick-nav > .mobile-only-nav-link {
    display: none !important;
  }

  body[data-page] .quick-nav .side-user {
    display: grid !important;
    gap: 8px !important;
    margin-top: auto !important;
    padding: 14px 0 0 !important;
    border-top: 1px solid #e2e8f0 !important;
  }

  body[data-page] .quick-nav .side-user-profile {
    grid-template-columns: 34px minmax(0, 1fr) !important;
  }

  body[data-page] .quick-nav .profile-avatar {
    display: grid !important;
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    place-items: center !important;
    border-radius: 12px !important;
    background: #eafff4 !important;
    color: #047857 !important;
    box-shadow: none !important;
    font-size: .86rem !important;
    font-weight: 950 !important;
  }

  body[data-page] .quick-nav .profile-copy {
    display: grid !important;
    gap: 0 !important;
    min-width: 0 !important;
  }

  body[data-page] .quick-nav .profile-copy span {
    color: #64748b !important;
    font-size: .7rem !important;
    font-weight: 800 !important;
    line-height: 1.1 !important;
  }

  body[data-page] .quick-nav .profile-copy strong {
    color: #0f172a !important;
    font-size: .9rem !important;
    font-weight: 950 !important;
    line-height: 1.15 !important;
  }

  body[data-page].nav-collapsed .quick-nav .side-brand {
    grid-template-columns: 1fr !important;
    grid-template-areas: "logo" !important;
    width: 56px !important;
    min-width: 56px !important;
    max-width: 56px !important;
    padding: 0 0 16px !important;
    margin-bottom: 12px !important;
    place-items: center !important;
  }

  body[data-page].nav-collapsed .quick-nav .side-program-logo {
    width: 56px !important;
    height: 56px !important;
    min-width: 56px !important;
  }

  body[data-page].nav-collapsed .quick-nav .side-brand > span:not(.side-program-logo),
  body[data-page].nav-collapsed .quick-nav .side-brand strong,
  body[data-page].nav-collapsed .quick-nav .nav-label,
  body[data-page].nav-collapsed .quick-nav .profile-copy,
  body[data-page].nav-collapsed .quick-nav .nav-chevron {
    display: none !important;
  }

  body[data-page].nav-collapsed .quick-nav .sidebar-link,
  body[data-page].nav-collapsed .quick-nav .nav-group-toggle,
  body[data-page].nav-collapsed .quick-nav .nav-text-link,
  body[data-page].nav-collapsed .quick-nav .side-user-profile {
    grid-template-columns: 1fr !important;
    justify-items: center !important;
    width: 56px !important;
    min-width: 56px !important;
    max-width: 56px !important;
    height: 56px !important;
    min-height: 56px !important;
    padding: 0 !important;
    border-radius: 16px !important;
  }
}

/* v1.0.133 last-mile sidebar fix: collapse control is absolute and never a menu row. */
@media (min-width: 641px) {
  body[data-page] .app-shell,
  body[data-page] .app-shell.loan-app {
    grid-template-columns: 300px minmax(0, 1fr) !important;
    gap: 24px !important;
    overflow: visible !important;
  }

  body[data-page].nav-collapsed .app-shell,
  body[data-page].nav-collapsed .app-shell.loan-app {
    grid-template-columns: 96px minmax(0, 1fr) !important;
  }

  body[data-page] .quick-nav,
  body[data-page] .quick-nav.sidebar,
  body[data-page] .quick-nav.app-sidebar {
    position: sticky !important;
    top: 16px !important;
    z-index: 20 !important;
    width: 300px !important;
    min-width: 300px !important;
    max-width: 300px !important;
    margin: 0 !important;
    overflow: hidden !important;
  }

  body[data-page] .quick-nav .side-brand {
    grid-template-columns: 70px minmax(0, 1fr) !important;
    grid-template-areas: "logo eyebrow" "logo title" !important;
    width: 100% !important;
    height: 98px !important;
    min-height: 98px !important;
    max-height: 98px !important;
    padding: 0 34px 22px 0 !important;
    margin: 0 0 22px !important;
  }

  body[data-page] .quick-nav > .nav-collapse-button,
  body[data-page] .quick-nav .nav-collapse-button,
  body[data-page] .nav-collapse-button {
    position: absolute !important;
    top: 32px !important;
    right: 22px !important;
    left: auto !important;
    bottom: auto !important;
    z-index: 60 !important;
    display: inline-grid !important;
    grid-area: auto !important;
    grid-template-columns: 1fr !important;
    place-items: center !important;
    width: 22px !important;
    min-width: 22px !important;
    max-width: 22px !important;
    height: 22px !important;
    min-height: 22px !important;
    max-height: 22px !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #0f172a !important;
    font-size: 1.05rem !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    transform: none !important;
  }

  body[data-page] .quick-nav > .nav-collapse-button:hover,
  body[data-page] .quick-nav .nav-collapse-button:hover {
    color: #047857 !important;
    background: transparent !important;
    box-shadow: none !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .sidebar-link,
  body[data-page] .quick-nav .nav-group-toggle,
  body[data-page] .quick-nav .nav-text-link,
  body[data-page] .quick-nav .side-user-profile {
    height: 56px !important;
    min-height: 56px !important;
    max-height: 56px !important;
  }

  body[data-page].nav-collapsed .quick-nav,
  body[data-page].nav-collapsed .quick-nav.sidebar,
  body[data-page].nav-collapsed .quick-nav.app-sidebar {
    width: 96px !important;
    min-width: 96px !important;
    max-width: 96px !important;
  }

  body[data-page].nav-collapsed .quick-nav > .nav-collapse-button,
  body[data-page].nav-collapsed .quick-nav .nav-collapse-button {
    top: 34px !important;
    right: 5px !important;
    width: 14px !important;
    min-width: 14px !important;
    max-width: 14px !important;
    height: 18px !important;
    min-height: 18px !important;
    max-height: 18px !important;
    color: #047857 !important;
  }
}

/* v1.0.128 keep the sidebar collapse control separate from menu buttons. */
@media (min-width: 641px) {
  .quick-nav .nav-collapse-button,
  body[data-page] .quick-nav .nav-collapse-button,
  body.nav-collapsed .quick-nav .nav-collapse-button,
  body[data-page].nav-collapsed .quick-nav .nav-collapse-button {
    position: absolute !important;
    top: 18px !important;
    right: 18px !important;
    left: auto !important;
    bottom: auto !important;
    z-index: 10 !important;
    display: inline-grid !important;
    grid-template-columns: 1fr !important;
    place-items: center !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #0f172a !important;
    font-size: 1.2rem !important;
    font-weight: 950 !important;
    line-height: 1 !important;
    text-align: center !important;
    transform: none !important;
  }

  .quick-nav .nav-collapse-button:hover,
  body[data-page] .quick-nav .nav-collapse-button:hover {
    background: transparent !important;
    color: #047857 !important;
    border: 0 !important;
    box-shadow: none !important;
  }
}

/* v1.0.129 softer Thai typography across the desktop app. */
@media (min-width: 641px) {
  body,
  button,
  input,
  select,
  textarea {
    font-family: "IBM Plex Sans Thai", Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-synthesis-weight: none;
  }

  .quick-nav,
  .quick-nav *,
  .settings-dashboard,
  .premium-settings-page,
  #accountPanel,
  #settingsPanel,
  #dashboardPanel,
  #recordsPanel,
  #customerProfilesPanel,
  #lineLeadsPanel,
  #lineOaPanel,
  #trackingPanel,
  #historyPanel {
    font-family: "IBM Plex Sans Thai", Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    letter-spacing: 0 !important;
  }

  body[data-page] .quick-nav .side-brand > span:not(.side-program-logo) {
    font-family: Inter, "IBM Plex Sans Thai", sans-serif !important;
    font-size: 0.78rem !important;
    font-weight: 800 !important;
    letter-spacing: 0.16em !important;
  }

  body[data-page] .quick-nav .side-brand strong {
    font-size: 1.16rem !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    color: #0f172a !important;
  }

  body[data-page] .quick-nav .sidebar-link,
  body[data-page] .quick-nav .nav-group-toggle,
  body[data-page] .quick-nav .nav-text-link,
  body[data-page] .quick-nav .side-user-profile {
    font-size: 0.95rem !important;
    font-weight: 600 !important;
    line-height: 1.28 !important;
    color: #4b5a6f !important;
  }

  body[data-page] .quick-nav .nav-label {
    font-size: 0.95rem !important;
    font-weight: 600 !important;
    line-height: 1.28 !important;
  }

  body[data-page] .quick-nav .sidebar-link.active,
  body[data-page] .quick-nav .nav-group-toggle.active,
  body[data-page="account"] .quick-nav .side-user-profile,
  body[data-page="settings"] .quick-nav .settings-nav-link[href="#settingsPanel"] {
    color: #047857 !important;
    font-weight: 700 !important;
  }

  body[data-page] .quick-nav .sidebar-link.active .nav-label,
  body[data-page] .quick-nav .nav-group-toggle.active .nav-label,
  body[data-page] .quick-nav .side-user .nav-text-link .nav-label,
  body[data-page] .quick-nav .logout-nav-link .nav-label {
    font-weight: 700 !important;
  }

  body[data-page] .quick-nav .profile-copy span {
    font-size: 0.68rem !important;
    font-weight: 500 !important;
    color: #718096 !important;
  }

  body[data-page] .quick-nav .profile-copy strong {
    font-size: 0.9rem !important;
    font-weight: 700 !important;
    color: #0f172a !important;
  }

  #accountPanel h1,
  #settingsPanel h1,
  .premium-settings-title,
  .settings-dashboard h1 {
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-weight: 700 !important;
    letter-spacing: 0 !important;
  }
}

/* v1.0.130 rebuild the desktop settings page so it does not inherit the account-page bento spacing. */
@media (min-width: 981px) {
  body[data-page="settings"] .content-shell {
    padding: 42px 48px 72px 38px !important;
    overflow: auto !important;
  }

  body[data-page="settings"] #settingsPanel.settings-panel {
    width: min(1180px, 100%) !important;
    max-width: 1180px !important;
    margin: 0 auto !important;
    padding: 0 !important;
    color: #0f172a !important;
  }

  body[data-page="settings"] #settingsPanel.settings-panel::before {
    right: 48px !important;
    top: 28px !important;
    width: 150px !important;
    height: 150px !important;
    opacity: .45 !important;
  }

  body[data-page="settings"] #settingsPanel > .panel-title {
    display: block !important;
    width: 100% !important;
    margin: 0 0 28px !important;
    padding: 0 !important;
    text-align: left !important;
  }

  body[data-page="settings"] #settingsPanel > .panel-title > div {
    width: min(760px, 100%) !important;
    margin: 0 !important;
  }

  body[data-page="settings"] #settingsPanel > .panel-title::before {
    content: "ตั้งค่าระบบ" !important;
    display: inline-flex !important;
    margin: 0 0 8px !important;
    color: #0e9f6e !important;
    font-family: Inter, "IBM Plex Sans Thai", sans-serif !important;
    font-size: .78rem !important;
    font-weight: 800 !important;
    letter-spacing: .12em !important;
    text-transform: uppercase !important;
  }

  body[data-page="settings"] #settingsPanel > .panel-title h2 {
    margin: 0 !important;
    color: #0f172a !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: clamp(2.25rem, 3vw, 3.2rem) !important;
    font-weight: 700 !important;
    line-height: 1.08 !important;
    letter-spacing: 0 !important;
    text-align: left !important;
  }

  body[data-page="settings"] #settingsPanel > .panel-title h2::after {
    content: none !important;
    display: none !important;
  }

  body[data-page="settings"] #settingsPanel > .panel-title p {
    max-width: 620px !important;
    margin: 8px 0 0 !important;
    color: #64748b !important;
    font-size: .95rem !important;
    font-weight: 500 !important;
    line-height: 1.55 !important;
    text-align: left !important;
  }

  body[data-page="settings"] #settingsPanel .settings-sections {
    display: grid !important;
    grid-template-columns: 280px minmax(0, 1fr) !important;
    gap: 20px !important;
    align-items: start !important;
  }

  body[data-page="settings"] #settingsPanel .settings-sections::before {
    content: "ตั้งค่า\A\Aเลือกหมวดจากเมนูด้านซ้าย แล้วแก้ไขเฉพาะส่วนที่ต้องการ";
    grid-column: 1 !important;
    grid-row: 1 / span 6 !important;
    align-self: start !important;
    min-height: 186px !important;
    padding: 22px 22px !important;
    border: 1px solid rgba(15, 23, 42, .08) !important;
    border-radius: 22px !important;
    color: #64748b !important;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .92), rgba(255, 255, 255, .72)),
      radial-gradient(circle at 100% 0, rgba(25, 195, 125, .08), transparent 38%) !important;
    box-shadow: 0 18px 46px rgba(15, 23, 42, .07) !important;
    white-space: pre-line !important;
    font-size: .88rem !important;
    font-weight: 500 !important;
    line-height: 1.62 !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box {
    grid-column: 2 !important;
    width: 100% !important;
    margin: 0 0 12px !important;
    padding: 0 !important;
    overflow: hidden !important;
    border: 1px solid rgba(15, 23, 42, .075) !important;
    border-radius: 22px !important;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .94), rgba(255, 255, 255, .76)) !important;
    box-shadow: 0 18px 44px rgba(15, 23, 42, .065), inset 0 1px 0 rgba(255, 255, 255, .92) !important;
    backdrop-filter: blur(16px) saturate(1.08) !important;
    -webkit-backdrop-filter: blur(16px) saturate(1.08) !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box[open] {
    border-color: rgba(25, 195, 125, .24) !important;
    box-shadow: 0 22px 52px rgba(15, 23, 42, .08), 0 0 0 1px rgba(25, 195, 125, .06) !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box > summary {
    min-height: 76px !important;
    display: grid !important;
    grid-template-columns: 46px minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 16px !important;
    padding: 16px 22px !important;
    color: #0f172a !important;
    background: transparent !important;
    cursor: pointer !important;
    font-size: .98rem !important;
    font-weight: 600 !important;
    line-height: 1.25 !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box > summary::after {
    content: "›" !important;
    color: #0e9f6e !important;
    font-size: 1rem !important;
    font-weight: 700 !important;
    transform: rotate(90deg) !important;
    transition: transform .18s ease !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box[open] > summary::after {
    transform: rotate(-90deg) !important;
  }

  body[data-page="settings"] #settingsPanel .settings-summary-icon {
    width: 46px !important;
    height: 46px !important;
    border-radius: 15px !important;
    color: #0e9f6e !important;
    background: #e8fff3 !important;
    box-shadow: none !important;
  }

  body[data-page="settings"] #settingsPanel .settings-box > :not(summary) {
    padding: 0 22px 22px !important;
  }

  body[data-page="settings"] #settingsPanel .settings-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 16px !important;
  }

  body[data-page="settings"] #settingsPanel label {
    gap: 7px !important;
  }

  body[data-page="settings"] #settingsPanel label > span,
  body[data-page="settings"] #settingsPanel .field-help {
    letter-spacing: 0 !important;
  }

  body[data-page="settings"] #settingsPanel input,
  body[data-page="settings"] #settingsPanel textarea,
  body[data-page="settings"] #settingsPanel select {
    min-height: 48px !important;
    padding: 0 15px !important;
    border-radius: 13px !important;
    font-size: .92rem !important;
    font-weight: 500 !important;
  }

  body[data-page="settings"] #settingsPanel textarea {
    min-height: 94px !important;
    padding-top: 13px !important;
  }

  body[data-page="settings"] #settingsPanel .settings-footer {
    justify-content: flex-end !important;
    margin-top: 12px !important;
  }

  body[data-page="settings"] #settingsPanel .settings-footer .primary-button {
    min-height: 46px !important;
    min-width: 160px !important;
    border-radius: 14px !important;
    font-size: .9rem !important;
    font-weight: 700 !important;
  }
}

@media (max-width: 980px) {
  body[data-page="settings"] #settingsPanel > .panel-title {
    text-align: left !important;
  }

  body[data-page="settings"] #settingsPanel > .panel-title h2,
  body[data-page="settings"] #settingsPanel > .panel-title p {
    text-align: left !important;
  }
}

/* v1.0.131 final sidebar geometry lock: every desktop page must keep the exact same rail. */
@media (min-width: 981px) {
  body[data-page] .app-shell {
    grid-template-columns: 320px minmax(0, 1fr) !important;
    column-gap: 20px !important;
    align-items: start !important;
  }

  body[data-page].nav-collapsed .app-shell {
    grid-template-columns: 120px minmax(0, 1fr) !important;
  }

  body[data-page] .quick-nav,
  body[data-page] .quick-nav.sidebar,
  body[data-page] .quick-nav.app-sidebar,
  body[data-page="dashboard"] .quick-nav,
  body[data-page="account"] .quick-nav,
  body[data-page="settings"] .quick-nav {
    position: sticky !important;
    top: 16px !important;
    display: flex !important;
    flex-direction: column !important;
    width: 292px !important;
    min-width: 292px !important;
    max-width: 292px !important;
    height: calc(100vh - 32px) !important;
    min-height: 720px !important;
    margin: 16px 0 16px 16px !important;
    padding: 24px 20px 20px !important;
    border: 1px solid #dbe7ef !important;
    border-radius: 28px !important;
    background: rgba(255, 255, 255, .96) !important;
    box-shadow: 0 24px 54px rgba(15, 23, 42, .10) !important;
    overflow: hidden !important;
    transform: none !important;
    isolation: isolate !important;
  }

  body[data-page] .quick-nav::before,
  body[data-page] .quick-nav::after {
    content: none !important;
    display: none !important;
  }

  body[data-page] .quick-nav .side-brand,
  body[data-page="account"] .quick-nav .side-brand,
  body[data-page="settings"] .quick-nav .side-brand {
    position: relative !important;
    display: grid !important;
    grid-template-columns: 70px minmax(0, 1fr) 18px !important;
    grid-template-rows: 22px 46px !important;
    grid-template-areas: "logo eyebrow toggle" "logo title toggle" !important;
    column-gap: 18px !important;
    row-gap: 0 !important;
    align-items: center !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 100px !important;
    min-height: 100px !important;
    max-height: 100px !important;
    margin: 0 0 22px !important;
    padding: 0 0 22px !important;
    border: 0 !important;
    border-bottom: 1px solid #dbe7ef !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    text-align: left !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .side-brand::before,
  body[data-page] .quick-nav .side-brand::after {
    content: none !important;
    display: none !important;
  }

  body[data-page] .quick-nav .side-program-logo,
  body[data-page="account"] .quick-nav .side-program-logo,
  body[data-page="settings"] .quick-nav .side-program-logo {
    grid-area: logo !important;
    display: grid !important;
    place-items: center !important;
    width: 70px !important;
    min-width: 70px !important;
    max-width: 70px !important;
    height: 70px !important;
    min-height: 70px !important;
    max-height: 70px !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 20px !important;
    background: linear-gradient(145deg, #19c37d 0%, #0e9f6e 100%) !important;
    color: #fff !important;
    box-shadow: 0 18px 34px rgba(25, 195, 125, .22) !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .side-brand > span:not(.side-program-logo),
  body[data-page="account"] .quick-nav .side-brand > span:not(.side-program-logo),
  body[data-page="settings"] .quick-nav .side-brand > span:not(.side-program-logo) {
    grid-area: eyebrow !important;
    display: block !important;
    align-self: end !important;
    width: auto !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    color: #0f766e !important;
    font-family: Inter, "IBM Plex Sans Thai", system-ui, sans-serif !important;
    font-size: .78rem !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    letter-spacing: .15em !important;
    text-transform: uppercase !important;
    white-space: nowrap !important;
    text-align: left !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .side-brand strong,
  body[data-page="account"] .quick-nav .side-brand strong,
  body[data-page="settings"] .quick-nav .side-brand strong {
    grid-area: title !important;
    display: block !important;
    align-self: start !important;
    width: auto !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    color: #0f172a !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 1.22rem !important;
    font-weight: 700 !important;
    line-height: 1.18 !important;
    letter-spacing: 0 !important;
    white-space: nowrap !important;
    text-align: left !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .nav-collapse-button,
  body[data-page="account"] .quick-nav .nav-collapse-button,
  body[data-page="settings"] .quick-nav .nav-collapse-button {
    grid-area: toggle !important;
    position: static !important;
    justify-self: end !important;
    align-self: start !important;
    display: grid !important;
    place-items: center !important;
    width: 18px !important;
    min-width: 18px !important;
    max-width: 18px !important;
    height: 22px !important;
    min-height: 22px !important;
    max-height: 22px !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #0f172a !important;
    font-size: 1.1rem !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .sidebar-link,
  body[data-page] .quick-nav .nav-group-toggle,
  body[data-page] .quick-nav .nav-text-link,
  body[data-page] .quick-nav .side-user-profile,
  body[data-page="account"] .quick-nav .side-user-profile,
  body[data-page="settings"] .quick-nav .settings-nav-link {
    display: grid !important;
    grid-template-columns: 42px minmax(0, 1fr) 18px !important;
    align-items: center !important;
    gap: 14px !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 58px !important;
    min-height: 58px !important;
    max-height: 58px !important;
    margin: 0 0 10px !important;
    padding: 0 14px !important;
    border: 1px solid transparent !important;
    border-radius: 18px !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #4b5a6f !important;
    text-align: left !important;
    text-decoration: none !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .nav-label,
  body[data-page] .quick-nav .profile-copy strong {
    display: block !important;
    overflow: hidden !important;
    color: currentColor !important;
    font-size: .98rem !important;
    font-weight: 600 !important;
    line-height: 1.2 !important;
    letter-spacing: 0 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  body[data-page] .quick-nav .nav-icon,
  body[data-page] .quick-nav .settings-gear,
  body[data-page] .quick-nav .profile-avatar {
    display: grid !important;
    place-items: center !important;
    width: 42px !important;
    min-width: 42px !important;
    max-width: 42px !important;
    height: 42px !important;
    min-height: 42px !important;
    max-height: 42px !important;
    margin: 0 !important;
    border-radius: 14px !important;
    background: #f1f5f9 !important;
    color: #526174 !important;
    box-shadow: none !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .sidebar-link:hover,
  body[data-page] .quick-nav .nav-group-toggle:hover,
  body[data-page] .quick-nav .nav-text-link:hover,
  body[data-page] .quick-nav .sidebar-link.active,
  body[data-page] .quick-nav .nav-group-toggle.active,
  body[data-page="settings"] .quick-nav .settings-nav-link[href="#settingsPanel"] {
    height: 58px !important;
    min-height: 58px !important;
    max-height: 58px !important;
    padding: 0 14px !important;
    border-color: #86efac !important;
    background: #ecfdf5 !important;
    color: #047857 !important;
    box-shadow: none !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .sidebar-link:hover .nav-icon,
  body[data-page] .quick-nav .nav-group-toggle:hover .nav-icon,
  body[data-page] .quick-nav .nav-text-link:hover .nav-icon,
  body[data-page] .quick-nav .sidebar-link.active .nav-icon,
  body[data-page] .quick-nav .nav-group-toggle.active .nav-icon,
  body[data-page="settings"] .quick-nav .settings-nav-link[href="#settingsPanel"] .nav-icon,
  body[data-page="settings"] .quick-nav .settings-nav-link[href="#settingsPanel"] .settings-gear {
    background: #d1fae5 !important;
    color: #047857 !important;
  }

  body[data-page] .quick-nav .nav-group-items {
    display: grid !important;
    gap: 8px !important;
    margin: 0 0 10px 21px !important;
    padding: 0 0 0 14px !important;
    border-left: 1px solid #dbe7ef !important;
  }

  body[data-page] .quick-nav .nav-group:not(.is-open) .nav-group-items {
    display: none !important;
  }

  body[data-page] .quick-nav > .mobile-only-nav-link,
  body[data-page] .quick-nav .mobile-create-nav {
    display: none !important;
  }

  body[data-page] .quick-nav .side-user {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
    margin-top: auto !important;
    padding-top: 18px !important;
    border-top: 1px solid #dbe7ef !important;
  }

  body[data-page] .quick-nav .side-user-profile,
  body[data-page="account"] .quick-nav .side-user-profile {
    grid-template-columns: 42px minmax(0, 1fr) !important;
    border-color: transparent !important;
    background: transparent !important;
    color: #4b5a6f !important;
  }

  body[data-page] .quick-nav .profile-copy {
    display: grid !important;
    gap: 1px !important;
    min-width: 0 !important;
  }

  body[data-page] .quick-nav .profile-copy span {
    display: block !important;
    overflow: hidden !important;
    color: #64748b !important;
    font-size: .72rem !important;
    font-weight: 500 !important;
    line-height: 1.1 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  body[data-page] .quick-nav .profile-copy strong {
    color: #0f172a !important;
    font-size: .92rem !important;
    font-weight: 700 !important;
  }

  body[data-page].nav-collapsed .quick-nav,
  body[data-page].nav-collapsed .quick-nav.sidebar,
  body[data-page].nav-collapsed .quick-nav.app-sidebar {
    width: 88px !important;
    min-width: 88px !important;
    max-width: 88px !important;
    padding: 18px 14px !important;
    align-items: center !important;
  }

  body[data-page].nav-collapsed .quick-nav .side-brand {
    grid-template-columns: 56px !important;
    grid-template-rows: 56px !important;
    grid-template-areas: "logo" !important;
    justify-content: center !important;
    width: 56px !important;
    height: 78px !important;
    min-height: 78px !important;
    max-height: 78px !important;
    margin: 0 0 18px !important;
    padding: 0 0 18px !important;
  }

  body[data-page].nav-collapsed .quick-nav .side-program-logo {
    width: 56px !important;
    min-width: 56px !important;
    max-width: 56px !important;
    height: 56px !important;
    min-height: 56px !important;
    max-height: 56px !important;
  }

  body[data-page].nav-collapsed .quick-nav .nav-collapse-button {
    position: absolute !important;
    top: 32px !important;
    right: 4px !important;
    width: 14px !important;
    height: 18px !important;
    color: #0f766e !important;
  }

  body[data-page].nav-collapsed .quick-nav .side-brand > span:not(.side-program-logo),
  body[data-page].nav-collapsed .quick-nav .side-brand strong,
  body[data-page].nav-collapsed .quick-nav .nav-label,
  body[data-page].nav-collapsed .quick-nav .profile-copy,
  body[data-page].nav-collapsed .quick-nav .nav-chevron {
    display: none !important;
  }

  body[data-page].nav-collapsed .quick-nav .sidebar-link,
  body[data-page].nav-collapsed .quick-nav .nav-group-toggle,
  body[data-page].nav-collapsed .quick-nav .nav-text-link,
  body[data-page].nav-collapsed .quick-nav .side-user-profile {
    grid-template-columns: 1fr !important;
    justify-items: center !important;
    width: 56px !important;
    min-width: 56px !important;
    max-width: 56px !important;
    height: 56px !important;
    min-height: 56px !important;
    max-height: 56px !important;
    padding: 0 !important;
    margin: 0 0 10px !important;
    border-radius: 16px !important;
  }
}

/* v1.0.134 final post-order sidebar repair: keep the rail in its own column and pin the collapse control. */
@media (min-width: 641px) {
  body[data-page] .app-shell,
  body[data-page] .app-shell.loan-app {
    display: grid !important;
    grid-template-columns: 300px minmax(0, 1fr) !important;
    gap: 24px !important;
    align-items: start !important;
    width: min(100% - 32px, 1680px) !important;
    margin-inline: auto !important;
    overflow: visible !important;
  }

  body[data-page].nav-collapsed .app-shell,
  body[data-page].nav-collapsed .app-shell.loan-app {
    grid-template-columns: 96px minmax(0, 1fr) !important;
  }

  body[data-page] .quick-nav,
  body[data-page] .quick-nav.sidebar,
  body[data-page] .quick-nav.app-sidebar {
    position: sticky !important;
    top: 16px !important;
    z-index: 20 !important;
    width: 300px !important;
    min-width: 300px !important;
    max-width: 300px !important;
    margin: 0 !important;
    padding: 22px 18px 18px !important;
    overflow: hidden !important;
    transform: none !important;
  }

  body[data-page] .quick-nav .side-brand {
    position: relative !important;
    display: grid !important;
    grid-template-columns: 70px minmax(0, 1fr) !important;
    grid-template-areas: "logo eyebrow" "logo title" !important;
    align-items: center !important;
    column-gap: 14px !important;
    width: 100% !important;
    height: 98px !important;
    min-height: 98px !important;
    max-height: 98px !important;
    margin: 0 0 22px !important;
    padding: 0 34px 22px 0 !important;
  }

  body[data-page] .quick-nav > .nav-collapse-button,
  body[data-page] .quick-nav .nav-collapse-button,
  body[data-page] .nav-collapse-button {
    position: absolute !important;
    top: 32px !important;
    right: 22px !important;
    left: auto !important;
    bottom: auto !important;
    z-index: 60 !important;
    display: inline-grid !important;
    grid-area: auto !important;
    grid-template-columns: 1fr !important;
    place-items: center !important;
    width: 22px !important;
    min-width: 22px !important;
    max-width: 22px !important;
    height: 22px !important;
    min-height: 22px !important;
    max-height: 22px !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #0f172a !important;
    font-size: 1.05rem !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    transform: none !important;
  }

  body[data-page] .quick-nav > .nav-collapse-button:hover,
  body[data-page] .quick-nav .nav-collapse-button:hover {
    color: #047857 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page].nav-collapsed .quick-nav,
  body[data-page].nav-collapsed .quick-nav.sidebar,
  body[data-page].nav-collapsed .quick-nav.app-sidebar {
    width: 96px !important;
    min-width: 96px !important;
    max-width: 96px !important;
    padding: 18px 14px !important;
    align-items: center !important;
  }

  body[data-page].nav-collapsed .quick-nav .side-brand {
    grid-template-columns: 56px !important;
    grid-template-rows: 56px !important;
    grid-template-areas: "logo" !important;
    justify-content: center !important;
    width: 56px !important;
    height: 78px !important;
    min-height: 78px !important;
    max-height: 78px !important;
    margin: 0 0 18px !important;
    padding: 0 0 18px !important;
  }

  body[data-page].nav-collapsed .quick-nav > .nav-collapse-button,
  body[data-page].nav-collapsed .quick-nav .nav-collapse-button {
    top: 34px !important;
    right: 5px !important;
    width: 14px !important;
    min-width: 14px !important;
    max-width: 14px !important;
    height: 18px !important;
    min-height: 18px !important;
    max-height: 18px !important;
    color: #047857 !important;
  }

  body[data-page] .app-content,
  body[data-page] .content-area,
  body[data-page] .panel-stack {
    min-width: 0 !important;
    overflow: visible !important;
  }
}

/* v1.0.135 final order: fit expanded sidebar and merge account profile/password into one compact panel. */
@media (min-width: 641px) {
  body[data-page] .quick-nav,
  body[data-page] .quick-nav.sidebar,
  body[data-page] .quick-nav.app-sidebar {
    height: calc(100vh - 32px) !important;
    max-height: calc(100vh - 32px) !important;
    display: flex !important;
    flex-direction: column !important;
    padding: 18px 14px 16px !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    overscroll-behavior: contain !important;
    scrollbar-width: thin !important;
    scrollbar-color: rgba(100, 116, 139, .24) transparent !important;
  }

  body[data-page] .quick-nav::-webkit-scrollbar {
    width: 4px !important;
  }

  body[data-page] .quick-nav::-webkit-scrollbar-thumb {
    border-radius: 999px !important;
    background: rgba(100, 116, 139, .24) !important;
  }

  body[data-page] .quick-nav .side-brand {
    height: 84px !important;
    min-height: 84px !important;
    max-height: 84px !important;
    margin-bottom: 14px !important;
    padding-bottom: 16px !important;
  }

  body[data-page] .quick-nav .side-program-logo {
    width: 58px !important;
    min-width: 58px !important;
    max-width: 58px !important;
    height: 58px !important;
    min-height: 58px !important;
    max-height: 58px !important;
    border-radius: 18px !important;
  }

  body[data-page] .quick-nav .side-brand strong {
    font-size: 1.24rem !important;
    line-height: 1.08 !important;
  }

  body[data-page] .quick-nav .side-brand > span:not(.side-program-logo) {
    font-size: .72rem !important;
    line-height: 1 !important;
  }

  body[data-page] .quick-nav .sidebar-link,
  body[data-page] .quick-nav .nav-group-toggle,
  body[data-page] .quick-nav .nav-text-link,
  body[data-page] .quick-nav .side-user-profile {
    min-height: 48px !important;
    margin: 0 0 7px !important;
    padding: 8px 10px !important;
    gap: 10px !important;
    border-radius: 16px !important;
  }

  body[data-page] .quick-nav .nav-icon,
  body[data-page] .quick-nav .settings-gear,
  body[data-page] .quick-nav .profile-avatar {
    width: 38px !important;
    min-width: 38px !important;
    max-width: 38px !important;
    height: 38px !important;
    min-height: 38px !important;
    max-height: 38px !important;
    border-radius: 13px !important;
  }

  body[data-page] .quick-nav .nav-label,
  body[data-page] .quick-nav .profile-copy strong {
    font-size: 1rem !important;
    line-height: 1.12 !important;
  }

  body[data-page] .quick-nav .nav-group-items {
    gap: 6px !important;
    margin: 4px 0 8px 21px !important;
    padding-left: 14px !important;
  }

  body[data-page] .quick-nav .nav-group-items .sidebar-link {
    min-height: 44px !important;
    margin-bottom: 6px !important;
    padding: 7px 10px !important;
  }

  body[data-page] .quick-nav .side-user {
    margin-top: auto !important;
    padding-top: 12px !important;
    gap: 7px !important;
    border-top: 1px solid #dfe7ee !important;
  }

  body[data-page].nav-collapsed .quick-nav,
  body[data-page].nav-collapsed .quick-nav.sidebar,
  body[data-page].nav-collapsed .quick-nav.app-sidebar {
    overflow-y: auto !important;
    padding: 18px 14px 14px !important;
  }

  body[data-page="account"] .account-settings-page {
    width: 100% !important;
    max-width: none !important;
    padding: clamp(20px, 2vw, 28px) clamp(22px, 2.7vw, 36px) !important;
  }

  body[data-page="account"] .account-settings-page > .panel-title,
  body[data-page="account"] .account-settings-page .panel-title {
    margin-bottom: 16px !important;
  }

  body[data-page="account"] .account-settings-page > .panel-title h2,
  body[data-page="account"] .account-settings-page .panel-title h2 {
    font-size: clamp(2.2rem, 3.4vw, 3.05rem) !important;
    line-height: .96 !important;
  }

  body[data-page="account"] .account-settings-page > .panel-title p,
  body[data-page="account"] .account-settings-page .panel-title p {
    max-width: 680px !important;
    font-size: 1rem !important;
    line-height: 1.35 !important;
  }

  body[data-page="account"] .account-settings-page .account-tabs {
    min-height: 42px !important;
    margin-bottom: 20px !important;
    gap: 24px !important;
  }

  body[data-page="account"] .account-settings-page .account-tab {
    min-height: 42px !important;
    padding: 0 0 10px !important;
    gap: 10px !important;
  }

  body[data-page="account"] .account-settings-page .account-tab-icon {
    width: 34px !important;
    height: 34px !important;
    border-radius: 12px !important;
  }

  body[data-page="account"] .account-settings-page #accountProfileMount:not(.hidden):not([hidden]) {
    display: block !important;
    padding: 24px 28px 22px !important;
    border: 1px solid rgba(15, 23, 42, .08) !important;
    border-radius: 28px !important;
    background: rgba(255, 255, 255, .9) !important;
    box-shadow: 0 24px 70px rgba(15, 23, 42, .08) !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-card,
  body[data-page="account"] .account-settings-page .account-password-card,
  body[data-page="account"] .account-settings-page #userProfileForm {
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="account"] .account-settings-page #userProfileForm::before,
  body[data-page="account"] .account-settings-page #userProfileForm::after {
    display: none !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-hero {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 360px) !important;
    gap: 18px !important;
    align-items: center !important;
    margin-bottom: 18px !important;
    padding: 0 !important;
  }

  body[data-page="account"] .account-settings-page .account-section-title h3,
  body[data-page="account"] .account-settings-page .account-password-heading strong {
    font-size: 1.32rem !important;
    line-height: 1.1 !important;
  }

  body[data-page="account"] .account-settings-page .account-section-title p,
  body[data-page="account"] .account-settings-page .account-password-heading span,
  body[data-page="account"] .account-settings-page .account-profile-picture p {
    font-size: .88rem !important;
    line-height: 1.35 !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-picture {
    display: grid !important;
    grid-template-columns: 72px minmax(0, 1fr) !important;
    gap: 14px !important;
    align-items: center !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-orb {
    width: 72px !important;
    min-width: 72px !important;
    height: 72px !important;
    min-height: 72px !important;
    border-radius: 22px !important;
  }

  body[data-page="account"] .account-settings-page .account-upload-photo-button {
    min-height: 36px !important;
    padding: 8px 14px !important;
    border-radius: 10px !important;
    font-size: .82rem !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-readonly-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 14px !important;
  }

  body[data-page="account"] .account-settings-page .account-info-row,
  body[data-page="account"] .account-settings-page .account-card label:not(.file-button):not(.secondary-button) {
    display: grid !important;
    gap: 7px !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  body[data-page="account"] .account-settings-page .account-info-row-wide {
    width: calc(50% - 7px) !important;
    margin-top: 14px !important;
  }

  body[data-page="account"] .account-settings-page .account-info-row > span,
  body[data-page="account"] .account-settings-page .account-card label > span {
    font-size: .86rem !important;
    line-height: 1.2 !important;
  }

  body[data-page="account"] .account-settings-page .account-info-row > input,
  body[data-page="account"] .account-settings-page .account-card input,
  body[data-page="account"] .account-settings-page .account-card textarea,
  body[data-page="account"] .account-settings-page .account-card select {
    min-height: 44px !important;
    padding: 10px 14px !important;
    border: 1px solid #dbe4ee !important;
    border-radius: 13px !important;
    background: #fff !important;
    box-shadow: 0 8px 20px rgba(15, 23, 42, .025) !important;
    font-size: .95rem !important;
  }

  body[data-page="account"] .account-settings-page .account-info-row > input[readonly] {
    pointer-events: none !important;
  }

  body[data-page="account"] .account-settings-page .profile-signature-box {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 170px !important;
    gap: 18px !important;
    align-items: stretch !important;
    margin: 18px 0 0 !important;
    padding: 0 !important;
    border: 0 !important;
  }

  body[data-page="account"] .account-settings-page .signature-upload-field {
    display: grid !important;
    gap: 7px !important;
  }

  body[data-page="account"] .account-settings-page .signature-dropzone {
    min-height: 118px !important;
    padding: 16px !important;
    border-radius: 18px !important;
  }

  body[data-page="account"] .account-settings-page .signature-dropzone b {
    width: 34px !important;
    height: 34px !important;
  }

  body[data-page="account"] .account-settings-page .signature-dropzone em,
  body[data-page="account"] .account-settings-page .signature-dropzone small {
    font-size: .84rem !important;
    line-height: 1.25 !important;
  }

  body[data-page="account"] .account-settings-page .signature-dropzone strong {
    min-height: 34px !important;
    padding: 7px 16px !important;
    font-size: .82rem !important;
  }

  body[data-page="account"] .account-settings-page .signature-preview,
  body[data-page="account"] .account-settings-page .signature-preview.hidden {
    display: grid !important;
    place-items: center !important;
    min-height: 118px !important;
    max-width: none !important;
    margin: 0 !important;
    border-radius: 18px !important;
    font-size: .86rem !important;
  }

  body[data-page="account"] .account-settings-page .account-password-card {
    margin-top: 20px !important;
    padding-top: 18px !important;
    border-top: 1px solid rgba(15, 23, 42, .08) !important;
  }

  body[data-page="account"] .account-settings-page .account-password-heading {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 18px !important;
    margin-bottom: 14px !important;
  }

  body[data-page="account"] .account-settings-page .compact-password-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 14px !important;
    margin-top: 0 !important;
  }

  body[data-page="account"] .account-settings-page .compact-password-grid input {
    min-height: 42px !important;
    border-radius: 12px !important;
    padding: 8px 12px !important;
  }

  body[data-page="account"] .account-settings-page .password-strength-preview {
    margin-top: 12px !important;
    display: grid !important;
    grid-template-columns: auto 1fr !important;
    gap: 8px 12px !important;
    font-size: .8rem !important;
  }

  body[data-page="account"] .account-settings-page .confirm-actions {
    margin-top: 18px !important;
    padding-top: 16px !important;
    gap: 12px !important;
  }

  body[data-page="account"] .account-settings-page .confirm-actions button {
    min-width: 150px !important;
    min-height: 42px !important;
    border-radius: 12px !important;
  }
}

@media (max-width: 768px) {
  body[data-page="account"] .account-settings-page #accountProfileMount:not(.hidden):not([hidden]) {
    padding: 18px !important;
    border-radius: 22px !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-hero,
  body[data-page="account"] .account-settings-page .account-profile-readonly-grid,
  body[data-page="account"] .account-settings-page .profile-signature-box,
  body[data-page="account"] .account-settings-page .compact-password-grid {
    grid-template-columns: 1fr !important;
  }

  body[data-page="account"] .account-settings-page .account-info-row-wide {
    width: 100% !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-picture {
    grid-template-columns: 64px minmax(0, 1fr) !important;
  }

  body[data-page="account"] .account-settings-page .account-profile-orb {
    width: 64px !important;
    min-width: 64px !important;
    height: 64px !important;
    min-height: 64px !important;
  }
}


/* v1.0.136 eof override: account panels and profile save row. */
body[data-page="account"] .account-settings-page [data-account-panel][hidden],
body[data-page="account"] .account-settings-page [data-account-panel].hidden,
body[data-page="account"] .account-settings-page .account-card.hidden {
  display: none !important;
}

body[data-page="account"] .account-settings-page [data-account-panel]:not(.hidden):not([hidden]) {
  display: block !important;
}

body[data-page="account"] .account-settings-page .account-grid,
body[data-page="account"] .account-settings-page .account-card,
body[data-page="account"] .account-settings-page .save-confirm-panel,
body[data-page="account"] .account-settings-page #userProfileForm,
body[data-page="account"] .account-settings-page #accountProfileMount {
  max-height: none !important;
  overflow: visible !important;
}

body[data-page="account"] .account-settings-page .account-grid {
  display: block !important;
  width: 100% !important;
}

body[data-page="account"] .account-settings-page #userProfileForm {
  display: flex !important;
  flex-direction: column !important;
}

body[data-page="account"] .account-settings-page .confirm-actions {
  position: static !important;
  inset: auto !important;
  transform: none !important;
  margin: 12px 0 0 !important;
  padding: 12px 0 0 !important;
  border-top: 1px solid rgba(15, 23, 42, .06) !important;
  display: flex !important;
  justify-content: flex-end !important;
  align-items: center !important;
  gap: 12px !important;
  flex-wrap: wrap !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-page="account"] .account-settings-page .confirm-actions .primary-button,
body[data-page="account"] .account-settings-page .confirm-actions .secondary-button {
  width: auto !important;
  min-width: 150px !important;
  max-width: 100% !important;
  min-height: 42px !important;
}

@media (max-width: 768px) {
  body[data-page="account"] .account-settings-page .confirm-actions {
    justify-content: stretch !important;
  }

  body[data-page="account"] .account-settings-page .confirm-actions .primary-button,
  body[data-page="account"] .account-settings-page .confirm-actions .secondary-button {
    width: 100% !important;
  }
}
/* v1.0.138 eof: Puzzler reference sidebar, locked across pages. */
@media (min-width: 769px) {
  body:not(.auth-locked) {
    --puzzler-sidebar: 292px;
    --puzzler-ink: #171717;
    --puzzler-muted: #475569;
    --puzzler-line: rgba(15, 23, 42, .10);
    --puzzler-green: #0f8b66;
    --puzzler-blue: #2f80ed;
    font-family: Inter, "Noto Sans Thai", "IBM Plex Sans Thai", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  body:not(.auth-locked) .app-shell.loan-app,
  body:not(.auth-locked).nav-collapsed .app-shell.loan-app {
    display: grid !important;
    grid-template-columns: var(--puzzler-sidebar) minmax(0, 1fr) !important;
    gap: 0 !important;
    width: 100% !important;
    max-width: none !important;
    min-height: 100vh !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    align-items: stretch !important;
  }

  body:not(.auth-locked) .content-shell,
  body:not(.auth-locked) .main-area,
  body:not(.auth-locked) .main-content,
  body:not(.auth-locked).nav-collapsed .content-shell,
  body:not(.auth-locked).nav-collapsed .main-area,
  body:not(.auth-locked).nav-collapsed .main-content {
    margin: 0 !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    padding: 30px 40px 56px !important;
    transform: none !important;
    overflow: visible !important;
  }

  body:not(.auth-locked) .quick-nav.sidebar,
  body:not(.auth-locked) .quick-nav.side-nav,
  body:not(.auth-locked) .quick-nav.app-sidebar,
  body:not(.auth-locked).nav-collapsed .quick-nav.sidebar,
  body:not(.auth-locked).nav-collapsed .quick-nav.side-nav,
  body:not(.auth-locked).nav-collapsed .quick-nav.app-sidebar {
    position: sticky !important;
    top: 0 !important;
    left: 0 !important;
    z-index: 12 !important;
    width: var(--puzzler-sidebar) !important;
    min-width: var(--puzzler-sidebar) !important;
    max-width: var(--puzzler-sidebar) !important;
    height: 100vh !important;
    min-height: 100vh !important;
    max-height: 100vh !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
    align-items: stretch !important;
    margin: 0 !important;
    padding: 34px 32px 28px !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    background: #fff !important;
    border: 0 !important;
    border-right: 1px solid var(--puzzler-line) !important;
    border-radius: 0 !important;
    box-shadow: 18px 0 44px rgba(15, 23, 42, .04) !important;
    transform: none !important;
    isolation: auto !important;
  }

  body:not(.auth-locked) .quick-nav::-webkit-scrollbar {
    width: 0 !important;
  }

  body:not(.auth-locked) .nav-collapse-button {
    display: none !important;
  }

  body:not(.auth-locked).nav-collapsed .quick-nav .nav-label,
  body:not(.auth-locked).nav-collapsed .quick-nav .profile-copy,
  body:not(.auth-locked).nav-collapsed .quick-nav .side-brand span,
  body:not(.auth-locked).nav-collapsed .quick-nav .side-brand strong,
  body:not(.auth-locked).nav-collapsed .quick-nav .nav-chevron {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
    width: auto !important;
    height: auto !important;
    clip: auto !important;
  }

  body:not(.auth-locked) .side-brand,
  body:not(.auth-locked) .quick-nav .side-brand,
  body:not(.auth-locked) .sidebar-brand {
    display: grid !important;
    grid-template-columns: 46px minmax(0, 1fr) !important;
    grid-template-rows: auto auto !important;
    column-gap: 12px !important;
    align-items: center !important;
    min-height: 58px !important;
    margin: 0 0 28px !important;
    padding: 0 0 28px !important;
    border-bottom: 1px solid var(--puzzler-line) !important;
    background: transparent !important;
    box-shadow: none !important;
    text-align: left !important;
  }

  body:not(.auth-locked) .side-program-logo {
    display: none !important;
  }

  body:not(.auth-locked) .side-brand::before {
    content: "฿";
    grid-row: 1 / span 2;
    width: 46px;
    height: 46px;
    border-radius: 13px;
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 24px;
    font-weight: 800;
    line-height: 1;
    background: linear-gradient(145deg, #19c37d, #0e9f6e);
    box-shadow: 0 16px 28px rgba(25, 195, 125, .20);
  }

  body:not(.auth-locked) .side-brand > span:not(.side-program-logo) {
    display: block !important;
    color: #0f766e !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    letter-spacing: .16em !important;
    text-transform: uppercase !important;
    line-height: 1.05 !important;
    white-space: nowrap !important;
  }

  body:not(.auth-locked) .side-brand strong {
    display: block !important;
    grid-column: 2 !important;
    color: #111827 !important;
    font-size: 20px !important;
    font-weight: 600 !important;
    line-height: 1.15 !important;
    letter-spacing: 0 !important;
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: clip !important;
  }

  body:not(.auth-locked) .quick-nav .sidebar-link,
  body:not(.auth-locked) .quick-nav .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .nav-text-link,
  body:not(.auth-locked) .quick-nav .logout-nav-link,
  body:not(.auth-locked) .quick-nav .side-user-profile {
    width: 100% !important;
    height: 44px !important;
    min-height: 44px !important;
    max-height: 44px !important;
    display: grid !important;
    grid-template-columns: 24px minmax(0, 1fr) 16px !important;
    align-items: center !important;
    column-gap: 16px !important;
    margin: 2px 0 !important;
    padding: 0 8px !important;
    border: 0 !important;
    border-radius: 10px !important;
    background: transparent !important;
    box-shadow: none !important;
    color: var(--puzzler-ink) !important;
    text-decoration: none !important;
    text-align: left !important;
    transform: none !important;
  }

  body:not(.auth-locked) .quick-nav .nav-icon,
  body:not(.auth-locked) .quick-nav .settings-gear,
  body:not(.auth-locked) .quick-nav .profile-avatar {
    width: 24px !important;
    min-width: 24px !important;
    max-width: 24px !important;
    height: 24px !important;
    min-height: 24px !important;
    max-height: 24px !important;
    display: grid !important;
    place-items: center !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: currentColor !important;
  }

  body:not(.auth-locked) .quick-nav .nav-icon svg {
    width: 21px !important;
    height: 21px !important;
    stroke-width: 1.85 !important;
  }

  body:not(.auth-locked) .quick-nav .nav-label,
  body:not(.auth-locked) .quick-nav .profile-copy strong {
    display: block !important;
    color: currentColor !important;
    font-size: 15.5px !important;
    font-weight: 500 !important;
    line-height: 1.2 !important;
    letter-spacing: 0 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  body:not(.auth-locked) .quick-nav .sidebar-link:hover,
  body:not(.auth-locked) .quick-nav .nav-group-toggle:hover,
  body:not(.auth-locked) .quick-nav .nav-text-link:hover {
    background: #f7faf9 !important;
    color: var(--puzzler-green) !important;
  }

  body:not(.auth-locked) .quick-nav .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .nav-group-toggle.active,
  body[data-page="settings"]:not(.auth-locked) .quick-nav .settings-nav-link[href="#settingsPanel"],
  body[data-page="account"]:not(.auth-locked) .quick-nav .side-user-profile[href="#accountPanel"] {
    background: #eefdf5 !important;
    color: var(--puzzler-green) !important;
    box-shadow: none !important;
    border: 0 !important;
  }

  body:not(.auth-locked) .quick-nav .nav-chevron {
    display: block !important;
    justify-self: end !important;
    color: currentColor !important;
    font-size: 16px !important;
    line-height: 1 !important;
    transform: none !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group {
    display: block !important;
    width: 100% !important;
    margin: 2px 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items {
    display: none !important;
    flex-direction: column !important;
    gap: 4px !important;
    margin: 4px 0 8px 36px !important;
    padding: 2px 0 2px 18px !important;
    border-left: 1px solid rgba(15, 23, 42, .16) !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group.is-open .nav-group-items {
    display: flex !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link {
    grid-template-columns: minmax(0, 1fr) !important;
    height: 34px !important;
    min-height: 34px !important;
    max-height: 34px !important;
    margin: 0 !important;
    padding: 0 14px !important;
    border-radius: 9px !important;
    color: #111827 !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items .nav-icon {
    display: none !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items .nav-label {
    font-size: 14px !important;
    font-weight: 500 !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active {
    color: #fff !important;
    background: var(--puzzler-blue) !important;
    box-shadow: 0 10px 22px rgba(47, 128, 237, .20) !important;
  }

  body:not(.auth-locked) .mobile-create-nav,
  body:not(.auth-locked) .mobile-only-nav-link {
    display: none !important;
  }

  body:not(.auth-locked) .side-user {
    margin-top: auto !important;
    padding-top: 20px !important;
    border-top: 1px solid var(--puzzler-line) !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
  }

  body:not(.auth-locked) .side-user-profile {
    grid-template-columns: 32px minmax(0, 1fr) !important;
    height: 46px !important;
    min-height: 46px !important;
    max-height: 46px !important;
  }

  body:not(.auth-locked) .profile-avatar {
    width: 32px !important;
    min-width: 32px !important;
    height: 32px !important;
    min-height: 32px !important;
    border-radius: 50% !important;
    background: #eafff4 !important;
    color: #087a5a !important;
    font-size: 14px !important;
    font-weight: 700 !important;
  }

  body:not(.auth-locked) .profile-copy span {
    display: block !important;
    color: #64748b !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  body:not(.auth-locked) .side-user .nav-text-link,
  body:not(.auth-locked) .side-user .logout-nav-link {
    color: #111827 !important;
  }

  body:not(.auth-locked) .side-user .logout-nav-link:hover {
    color: #dc2626 !important;
    background: #fff5f5 !important;
  }
}

/* v1.0.139 final override: Account/Settings submenu belongs in the sidebar. */
@media (min-width: 769px) {
  body:not(.auth-locked) .quick-nav {
    overflow-y: auto !important;
    scrollbar-width: none !important;
    padding-bottom: 18px !important;
  }

  body:not(.auth-locked) .quick-nav::-webkit-scrollbar {
    width: 0 !important;
    height: 0 !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-account-link,
  body:not(.auth-locked) .quick-nav .mobile-settings-link,
  body:not(.auth-locked) .quick-nav .side-user-profile,
  body:not(.auth-locked) .quick-nav .legacy-settings-link {
    display: none !important;
  }

  body:not(.auth-locked) .quick-nav .side-user {
    margin-top: auto !important;
    padding-top: 14px !important;
    border-top: 1px solid rgba(15, 23, 42, .08) !important;
    gap: 0 !important;
    flex: 0 0 auto !important;
  }

  body:not(.auth-locked) .quick-nav .side-user .logout-nav-link {
    display: grid !important;
    color: #475569 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
  }

  body:not(.auth-locked) .quick-nav .side-user .logout-nav-link:hover {
    color: #dc2626 !important;
    background: #fff5f5 !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group,
  body:not(.auth-locked) .quick-nav .settings-nav-group {
    display: block !important;
    width: 100% !important;
  }

  body[data-page="account"]:not(.auth-locked) .quick-nav .account-nav-group > .nav-group-toggle,
  body[data-page="settings"]:not(.auth-locked) .quick-nav .settings-nav-group > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .account-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group > .nav-group-toggle.active {
    background: #ecfdf5 !important;
    color: #047857 !important;
    border-color: rgba(25, 195, 125, .38) !important;
  }

  body[data-page="account"]:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items,
  body[data-page="settings"]:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open .nav-group-items {
    display: flex !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items {
    margin: 4px 0 8px 34px !important;
    padding: 4px 0 4px 18px !important;
    border-left: 1px solid rgba(100, 116, 139, .18) !important;
    gap: 2px !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link {
    grid-template-columns: 10px minmax(0, 1fr) !important;
    height: 34px !important;
    min-height: 34px !important;
    max-height: 34px !important;
    margin: 0 !important;
    padding: 0 10px !important;
    border: 0 !important;
    border-radius: 10px !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #475569 !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-label,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-label {
    font-size: 13.5px !important;
    font-weight: 500 !important;
    line-height: 1.2 !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-dot,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-dot {
    display: block !important;
    width: 5px !important;
    height: 5px !important;
    border-radius: 999px !important;
    background: rgba(100, 116, 139, .38) !important;
    justify-self: center !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active {
    color: #0e9f6e !important;
    background: rgba(25, 195, 125, .1) !important;
  }

  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active .nav-dot,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active .nav-dot {
    background: #19c37d !important;
  }

  body[data-page="account"]:not(.auth-locked) .account-settings-page .account-tabs {
    display: none !important;
  }
}

/* v1.0.142 absolute final override: nested sidebar menus stay user-collapsible. */
@media (min-width: 769px) {
  body:not(.auth-locked) .quick-nav .customer-nav-group,
  body:not(.auth-locked) .quick-nav .account-nav-group,
  body:not(.auth-locked) .quick-nav .settings-nav-group {
    display: block !important;
    width: 100% !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items {
    display: none !important;
    margin: 4px 0 8px 34px !important;
    padding: 4px 0 4px 18px !important;
    border-left: 1px solid rgba(100, 116, 139, .18) !important;
    gap: 2px !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group.is-open .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open .nav-group-items {
    display: flex !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .account-nav-group > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .settings-nav-group > .nav-group-toggle {
    background: transparent !important;
    color: #475569 !important;
    border-color: transparent !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .account-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .customer-nav-group.is-open > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open > .nav-group-toggle {
    background: #ecfdf5 !important;
    color: #047857 !important;
    border-color: rgba(25, 195, 125, .38) !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link {
    grid-template-columns: 10px minmax(0, 1fr) !important;
    height: 34px !important;
    min-height: 34px !important;
    max-height: 34px !important;
    margin: 0 !important;
    padding: 0 10px !important;
    border: 0 !important;
    border-radius: 10px !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #475569 !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-label,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-label {
    font-size: 13.5px !important;
    font-weight: 500 !important;
    line-height: 1.2 !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-dot,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .nav-dot,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .nav-dot {
    display: block !important;
    width: 5px !important;
    height: 5px !important;
    border-radius: 999px !important;
    background: rgba(100, 116, 139, .38) !important;
    justify-self: center !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active {
    color: #0e9f6e !important;
    background: rgba(25, 195, 125, .1) !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active .nav-dot,
  body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items .sidebar-link.active .nav-dot,
  body:not(.auth-locked) .quick-nav .settings-nav-group .nav-group-items .sidebar-link.active .nav-dot {
    background: #19c37d !important;
  }
}
 
/* v1.0.143: absolute EOF override. Parent menus collapse even when a child is active, and Settings shows one panel at a time. */
@media (min-width: 769px) {
  body:not(.auth-locked) .quick-nav .customer-nav-group:not(.is-open) > .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group:not(.is-open) > .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group:not(.is-open) > .nav-group-items,
  body[data-page="customer"]:not(.auth-locked) .quick-nav .customer-nav-group:not(.is-open) > .nav-group-items,
  body[data-page="account"]:not(.auth-locked) .quick-nav .account-nav-group:not(.is-open) > .nav-group-items,
  body[data-page="settings"]:not(.auth-locked) .quick-nav .settings-nav-group:not(.is-open) > .nav-group-items {
    display: none !important;
    max-height: 0 !important;
    overflow: hidden !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group.is-open > .nav-group-items,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open > .nav-group-items,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open > .nav-group-items,
  body[data-page="customer"]:not(.auth-locked) .quick-nav .customer-nav-group.is-open > .nav-group-items,
  body[data-page="account"]:not(.auth-locked) .quick-nav .account-nav-group.is-open > .nav-group-items,
  body[data-page="settings"]:not(.auth-locked) .quick-nav .settings-nav-group.is-open > .nav-group-items {
    display: flex !important;
    max-height: none !important;
    overflow: visible !important;
    visibility: visible !important;
    pointer-events: auto !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group:not(.is-open) > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .account-nav-group:not(.is-open) > .nav-group-toggle.active,
  body:not(.auth-locked) .quick-nav .settings-nav-group:not(.is-open) > .nav-group-toggle.active,
  body[data-page="customer"]:not(.auth-locked) .quick-nav .customer-nav-group:not(.is-open) > .nav-group-toggle,
  body[data-page="account"]:not(.auth-locked) .quick-nav .account-nav-group:not(.is-open) > .nav-group-toggle,
  body[data-page="settings"]:not(.auth-locked) .quick-nav .settings-nav-group:not(.is-open) > .nav-group-toggle {
    background: transparent !important;
    border-color: transparent !important;
    color: #475569 !important;
    box-shadow: none !important;
  }

  body:not(.auth-locked) .quick-nav .customer-nav-group.is-open > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .account-nav-group.is-open > .nav-group-toggle,
  body:not(.auth-locked) .quick-nav .settings-nav-group.is-open > .nav-group-toggle {
    background: #ecfdf5 !important;
    border-color: rgba(25, 195, 125, .38) !important;
    color: #047857 !important;
  }

  body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-box {
    display: none !important;
  }

  body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-box.is-active-setting {
    display: block !important;
  }
}

/* v1.0.144-final-eof: must remain at EOF so old desktop/mobile rules cannot override it. */
body[data-page="records"]:not(.auth-locked) .records-subnav,
body[data-page="customer"]:not(.auth-locked) .records-subnav {
  display: none !important;
}

@media (min-width: 769px) {
  body[data-page="settings"]:not(.auth-locked) .content,
  body[data-page="account"]:not(.auth-locked) .content,
  body[data-page="settings"]:not(.auth-locked) .workspace,
  body[data-page="account"]:not(.auth-locked) .workspace,
  body[data-page="settings"]:not(.auth-locked) .main-content,
  body[data-page="account"]:not(.auth-locked) .main-content {
    background: #f8fbf9 !important;
    background-image: none !important;
  }

  body[data-page="settings"]:not(.auth-locked) .workspace::before,
  body[data-page="settings"]:not(.auth-locked) .workspace::after,
  body[data-page="settings"]:not(.auth-locked) .main-content::before,
  body[data-page="settings"]:not(.auth-locked) .main-content::after,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel::before,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel::after,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel.settings-panel::before,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel.settings-panel::after,
  body[data-page="account"]:not(.auth-locked) .workspace::before,
  body[data-page="account"]:not(.auth-locked) .workspace::after,
  body[data-page="account"]:not(.auth-locked) .main-content::before,
  body[data-page="account"]:not(.auth-locked) .main-content::after,
  body[data-page="account"]:not(.auth-locked) #accountPanel::before,
  body[data-page="account"]:not(.auth-locked) #accountPanel::after,
  body[data-page="account"]:not(.auth-locked) .account-settings-page::before,
  body[data-page="account"]:not(.auth-locked) .account-settings-page::after {
    content: none !important;
    display: none !important;
    background: none !important;
    box-shadow: none !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label,
  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#trackingPanel"] .nav-label {
    font-size: 0 !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#recordsPanel"] .nav-label::after {
    content: "รายการลูกค้า" !important;
    display: inline !important;
    font-size: 13.5px !important;
  }

  body:not(.auth-locked) .quick-nav .nav-group-items > a[href="#trackingPanel"] .nav-label::after {
    content: "ติดตามชำระ" !important;
    display: inline !important;
    font-size: 13.5px !important;
  }

  body[data-page="records"]:not(.auth-locked) .workspace::before,
  body[data-page="customer"]:not(.auth-locked) .workspace::before {
    content: "รายการลูกค้า" !important;
  }

  body[data-page="tracking"]:not(.auth-locked) .workspace::before,
  body[data-records-subview="tracking"]:not(.auth-locked) .workspace::before {
    content: "ติดตามชำระ" !important;
  }

  body[data-page="leads"]:not(.auth-locked) .app-topbar,
  body[data-page="leads"]:not(.auth-locked) .page-header,
  body[data-page="lineoa"]:not(.auth-locked) .app-topbar,
  body[data-page="lineoa"]:not(.auth-locked) .page-header {
    display: none !important;
  }

  body[data-page="leads"]:not(.auth-locked) .workspace::before,
  body[data-page="lineoa"]:not(.auth-locked) .workspace::before {
    content: none !important;
    display: none !important;
  }

  body[data-page="leads"]:not(.auth-locked) #lineLeadsPanel > .panel-title,
  body[data-page="lineoa"]:not(.auth-locked) #lineOaPanel > .panel-title {
    display: none !important;
  }

  body[data-page="leads"]:not(.auth-locked) .content,
  body[data-page="lineoa"]:not(.auth-locked) .content,
  body[data-page="leads"]:not(.auth-locked) #lineLeadsPanel,
  body[data-page="lineoa"]:not(.auth-locked) #lineOaPanel {
    padding-top: 24px !important;
  }

  body[data-page="account"]:not(.auth-locked) .account-section-title > span,
  body[data-page="account"]:not(.auth-locked) .account-password-heading::before,
  body[data-page="account"]:not(.auth-locked) .account-password-heading::after,
  body[data-page="account"]:not(.auth-locked) .account-profile-card::before,
  body[data-page="account"]:not(.auth-locked) .account-profile-card::after,
  body[data-page="account"]:not(.auth-locked) .account-password-card::before,
  body[data-page="account"]:not(.auth-locked) .account-password-card::after {
    content: none !important;
    display: none !important;
  }
}
/* v1.1.0 true EOF override: final polish after legacy EOF rules. */
body[data-page="leads"]:not(.auth-locked) .app-topbar,
body[data-page="leads"]:not(.auth-locked) .page-header,
body[data-page="lineoa"]:not(.auth-locked) .app-topbar,
body[data-page="lineoa"]:not(.auth-locked) .page-header,
body[data-page="leads"]:not(.auth-locked) #lineLeadsPanel > .panel-title,
body[data-page="lineoa"]:not(.auth-locked) #lineOaPanel > .panel-title {
  display: flex !important;
}

body:not(.auth-locked) .quick-nav .side-brand {
  display: grid !important;
  grid-template-columns: 42px minmax(0, 1fr) !important;
  gap: 10px !important;
  align-items: center !important;
  min-height: 64px !important;
  overflow: hidden !important;
}

body:not(.auth-locked) .quick-nav .side-brand .side-program-logo {
  position: static !important;
  grid-column: 1 !important;
  grid-row: 1 !important;
  width: 42px !important;
  height: 42px !important;
  min-width: 42px !important;
  max-width: 42px !important;
  margin: 0 !important;
  transform: none !important;
}

body:not(.auth-locked) .quick-nav .side-brand .side-brand-copy {
  display: flex !important;
  flex-direction: column !important;
  grid-column: 2 !important;
  grid-row: 1 !important;
  position: static !important;
  margin: 0 !important;
  transform: none !important;
  min-width: 0 !important;
}

body:not(.auth-locked) .quick-nav .side-brand .side-brand-copy > span {
  font-size: 11px !important;
  letter-spacing: .04em !important;
  white-space: nowrap !important;
}

body:not(.auth-locked) .quick-nav .side-brand .side-brand-copy > strong {
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

body[data-page="settings"] #settingsPanel > .panel-title::before,
body[data-page="settings"] #settingsPanel .settings-sections::before,
body[data-page="account"] .account-section-title::before,
body[data-page="account"] .account-section-title > span {
  content: none !important;
  display: none !important;
}

body[data-page="settings"] #settingsPanel .settings-footer {
  position: sticky !important;
  right: auto !important;
  bottom: 12px !important;
  display: flex !important;
  justify-content: flex-end !important;
  align-items: center !important;
  padding: 12px !important;
  margin-top: 18px !important;
  border-radius: 8px !important;
  background: rgba(255, 255, 255, .92) !important;
}

body[data-page="settings"] #settingsPanel .settings-footer .primary-button {
  position: static !important;
}

.records-inline-actions,
.profile-row-actions,
.customer-profile-actions {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 8px !important;
}

@media (max-width: 860px) {
  .records-table .records-col-actions,
  .records-table .records-action-cell {
    display: none !important;
  }
}

/* v1.1.0 sidebar-collapse hotfix: icon-only rail when the side navigation is folded. */
@media (min-width: 769px) {
  body.nav-collapsed:not(.auth-locked) .app-shell,
  body.nav-collapsed:not(.auth-locked) .app-shell.loan-app {
    grid-template-columns: 96px minmax(0, 1fr) !important;
  }

  body.nav-collapsed:not(.auth-locked) .quick-nav,
  body.nav-collapsed:not(.auth-locked) .quick-nav.sidebar,
  body.nav-collapsed:not(.auth-locked) .quick-nav.side-nav,
  body.nav-collapsed:not(.auth-locked) .quick-nav.app-sidebar {
    width: 96px !important;
    min-width: 96px !important;
    max-width: 96px !important;
    padding: 20px 12px !important;
    align-items: center !important;
    gap: 14px !important;
    overflow-x: hidden !important;
  }

  body.nav-collapsed:not(.auth-locked) .quick-nav .side-brand {
    display: grid !important;
    grid-template-columns: 1fr !important;
    justify-items: center !important;
    width: 72px !important;
    min-height: 78px !important;
    padding: 0 0 14px !important;
    margin: 0 0 8px !important;
    border-bottom: 1px solid #e5e7eb !important;
    overflow: visible !important;
  }

  body.nav-collapsed:not(.auth-locked) .quick-nav .side-brand .side-program-logo {
    position: static !important;
    display: inline-flex !important;
    width: 54px !important;
    height: 54px !important;
    min-width: 54px !important;
    max-width: 54px !important;
    margin: 0 !important;
    transform: none !important;
    border-radius: 18px !important;
  }

  body.nav-collapsed:not(.auth-locked) .quick-nav .side-brand .side-brand-copy,
  body.nav-collapsed:not(.auth-locked) .quick-nav .side-brand > span:not(.side-program-logo),
  body.nav-collapsed:not(.auth-locked) .quick-nav .side-brand strong,
  body.nav-collapsed:not(.auth-locked) .quick-nav .nav-label,
  body.nav-collapsed:not(.auth-locked) .quick-nav .nav-chevron,
  body.nav-collapsed:not(.auth-locked) .quick-nav .profile-copy,
  body.nav-collapsed:not(.auth-locked) .quick-nav .nav-group-items,
  body.nav-collapsed:not(.auth-locked) .quick-nav .mobile-only-nav-link,
  body.nav-collapsed:not(.auth-locked) .quick-nav .legacy-settings-link,
  body.nav-collapsed:not(.auth-locked) .quick-nav .side-user-profile {
    display: none !important;
    visibility: hidden !important;
    width: 0 !important;
    max-width: 0 !important;
    height: 0 !important;
    max-height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: hidden !important;
  }

  body.nav-collapsed:not(.auth-locked) .quick-nav > .sidebar-link,
  body.nav-collapsed:not(.auth-locked) .quick-nav .nav-group-toggle,
  body.nav-collapsed:not(.auth-locked) .quick-nav .side-user .nav-text-link,
  body.nav-collapsed:not(.auth-locked) .quick-nav .logout-nav-link {
    display: grid !important;
    grid-template-columns: 1fr !important;
    place-items: center !important;
    width: 58px !important;
    min-width: 58px !important;
    max-width: 58px !important;
    height: 58px !important;
    min-height: 58px !important;
    max-height: 58px !important;
    padding: 0 !important;
    margin: 0 auto !important;
    border-radius: 18px !important;
    text-align: center !important;
  }

  body.nav-collapsed:not(.auth-locked) .quick-nav .nav-icon,
  body.nav-collapsed:not(.auth-locked) .quick-nav .settings-gear {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 24px !important;
    height: 24px !important;
    margin: 0 !important;
  }

  body.nav-collapsed:not(.auth-locked) .quick-nav .nav-group,
  body.nav-collapsed:not(.auth-locked) .quick-nav .side-user {
    width: 72px !important;
    min-width: 72px !important;
    max-width: 72px !important;
    display: grid !important;
    justify-items: center !important;
    gap: 12px !important;
  }

  body.nav-collapsed:not(.auth-locked) .quick-nav .side-user {
    margin-top: auto !important;
    padding-top: 12px !important;
    border-top: 1px solid #e5e7eb !important;
  }

  body.nav-collapsed:not(.auth-locked) .quick-nav .nav-collapse-button {
    position: absolute !important;
    top: 24px !important;
    right: 10px !important;
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
    min-height: 28px !important;
    padding: 0 !important;
    border-radius: 999px !important;
    z-index: 5 !important;
  }

  body.nav-collapsed:not(.auth-locked) .quick-nav .nav-collapse-button span {
    display: inline !important;
    visibility: visible !important;
    width: auto !important;
    height: auto !important;
    max-width: none !important;
    max-height: none !important;
    color: #047857 !important;
  }
}

/* v1.1.0 true EOF submenu typography fix. Must stay after all legacy sidebar rules. */
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items {
  gap: 6px !important;
  padding: 4px 0 4px 34px !important;
}

body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#recordsPanel"],
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#trackingPanel"],
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#historyPanel"] {
  display: grid !important;
  grid-template-columns: 10px minmax(0, 1fr) !important;
  align-items: center !important;
  width: 100% !important;
  min-width: 0 !important;
  height: 36px !important;
  min-height: 36px !important;
  max-height: 36px !important;
  padding: 0 12px !important;
  margin: 0 !important;
  border-radius: 10px !important;
  background: transparent !important;
  box-shadow: none !important;
  color: #475569 !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  letter-spacing: 0 !important;
  overflow: hidden !important;
  transform: none !important;
}

body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#recordsPanel"].active,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#trackingPanel"].active,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#historyPanel"].active {
  background: #ecfdf5 !important;
  color: #047857 !important;
}

body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active .nav-label,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#recordsPanel"] .nav-label,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#trackingPanel"] .nav-label,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#historyPanel"] .nav-label {
  display: block !important;
  width: auto !important;
  min-width: 0 !important;
  max-width: 100% !important;
  height: auto !important;
  max-height: none !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  color: inherit !important;
  font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  letter-spacing: 0 !important;
  transform: none !important;
}

body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label::before,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label::after,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active .nav-label::before,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active .nav-label::after,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#recordsPanel"] .nav-label::before,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#recordsPanel"] .nav-label::after,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#trackingPanel"] .nav-label::before,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#trackingPanel"] .nav-label::after,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#historyPanel"] .nav-label::before,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#historyPanel"] .nav-label::after {
  content: none !important;
  display: none !important;
  visibility: hidden !important;
  width: 0 !important;
  height: 0 !important;
  max-width: 0 !important;
  max-height: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  font-size: 0 !important;
  line-height: 0 !important;
}

body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-dot {
  width: 6px !important;
  height: 6px !important;
  border-radius: 999px !important;
  background: #cbd5e1 !important;
}

body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active .nav-dot {
  background: #10b981 !important;
}

/* v1.1.0 true EOF sidebar typography system: one size, one color scale. */
body:not(.auth-locked) .quick-nav,
body:not(.auth-locked) .quick-nav * {
  font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
  letter-spacing: 0 !important;
  font-synthesis-weight: none !important;
}

body:not(.auth-locked) .quick-nav .nav-label::before,
body:not(.auth-locked) .quick-nav .nav-label::after {
  content: none !important;
  display: none !important;
}

body:not(.auth-locked) .quick-nav > .sidebar-link,
body:not(.auth-locked) .quick-nav > .mobile-only-nav-link,
body:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle,
body:not(.auth-locked) .quick-nav .side-user .nav-text-link,
body:not(.auth-locked) .quick-nav .logout-nav-link {
  display: grid !important;
  grid-template-columns: 26px minmax(0, 1fr) 14px !important;
  align-items: center !important;
  gap: 12px !important;
  min-height: 48px !important;
  height: 48px !important;
  max-height: 48px !important;
  width: 100% !important;
  padding: 0 14px !important;
  margin: 0 !important;
  border-radius: 12px !important;
  background: transparent !important;
  border-color: transparent !important;
  box-shadow: none !important;
  color: #111827 !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  text-decoration: none !important;
  transform: none !important;
}

body:not(.auth-locked) .quick-nav > .sidebar-link.active,
body:not(.auth-locked) .quick-nav > .mobile-only-nav-link.active,
body:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle.active,
body:not(.auth-locked) .quick-nav .nav-group.is-open > .nav-group-toggle,
body:not(.auth-locked) .quick-nav .side-user .nav-text-link.active {
  background: #ecfdf5 !important;
  color: #047857 !important;
}

body:not(.auth-locked) .quick-nav .nav-icon,
body:not(.auth-locked) .quick-nav .settings-gear {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 22px !important;
  height: 22px !important;
  margin: 0 !important;
  color: currentColor !important;
}

body:not(.auth-locked) .quick-nav .nav-icon svg,
body:not(.auth-locked) .quick-nav .settings-gear svg {
  width: 22px !important;
  height: 22px !important;
}

body:not(.auth-locked) .quick-nav > .sidebar-link > .nav-label,
body:not(.auth-locked) .quick-nav > .mobile-only-nav-link > .nav-label,
body:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle > .nav-label,
body:not(.auth-locked) .quick-nav .side-user .nav-text-link > .nav-label,
body:not(.auth-locked) .quick-nav .logout-nav-link > .nav-label {
  display: block !important;
  min-width: 0 !important;
  max-width: 100% !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  color: inherit !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  transform: none !important;
}

body:not(.auth-locked) .quick-nav .nav-chevron {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 14px !important;
  height: 14px !important;
  margin: 0 !important;
  color: currentColor !important;
  font-size: 14px !important;
  font-weight: 800 !important;
  line-height: 1 !important;
}

body:not(.auth-locked) .quick-nav .nav-group-items {
  display: flex !important;
  flex-direction: column !important;
  gap: 6px !important;
  padding: 4px 0 8px 34px !important;
  margin: 0 !important;
  border-left: 1px solid #e2e8f0 !important;
}

body:not(.auth-locked) .quick-nav .nav-group:not(.is-open) > .nav-group-items {
  display: none !important;
}

body:not(.auth-locked) .quick-nav .nav-group.is-open > .nav-group-items {
  display: flex !important;
}

body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active {
  display: grid !important;
  grid-template-columns: 10px minmax(0, 1fr) !important;
  align-items: center !important;
  gap: 10px !important;
  min-height: 36px !important;
  height: 36px !important;
  max-height: 36px !important;
  width: 100% !important;
  padding: 0 12px !important;
  margin: 0 !important;
  border-radius: 10px !important;
  background: transparent !important;
  color: #475569 !important;
  box-shadow: none !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  transform: none !important;
}

body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active {
  background: #ecfdf5 !important;
  color: #047857 !important;
}

body:not(.auth-locked) .quick-nav .nav-group-items .nav-label,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-label {
  display: block !important;
  min-width: 0 !important;
  max-width: 100% !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  color: inherit !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  transform: none !important;
}

body:not(.auth-locked) .quick-nav .nav-dot {
  display: block !important;
  width: 6px !important;
  height: 6px !important;
  border-radius: 999px !important;
  background: #cbd5e1 !important;
}

body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-dot {
  background: #10b981 !important;
}

body.nav-collapsed:not(.auth-locked) .quick-nav .nav-label,
body.nav-collapsed:not(.auth-locked) .quick-nav .nav-chevron,
body.nav-collapsed:not(.auth-locked) .quick-nav .nav-group-items,
body.nav-collapsed:not(.auth-locked) .quick-nav .profile-copy,
body.nav-collapsed:not(.auth-locked) .quick-nav .side-brand-copy,
body.nav-collapsed:not(.auth-locked) .quick-nav .mobile-only-nav-link,
body.nav-collapsed:not(.auth-locked) .quick-nav .legacy-settings-link,
body.nav-collapsed:not(.auth-locked) .quick-nav .side-user-profile {
  display: none !important;
}

/* v1.1.0 sidebar uniform typography: identical color, size, and weight. */
body:not(.auth-locked) .quick-nav > .sidebar-link,
body:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle,
body:not(.auth-locked) .quick-nav .side-user .nav-text-link,
body:not(.auth-locked) .quick-nav .logout-nav-link,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active {
  color: #334155 !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
}

body:not(.auth-locked) .quick-nav > .sidebar-link > .nav-label,
body:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle > .nav-label,
body:not(.auth-locked) .quick-nav .side-user .nav-text-link > .nav-label,
body:not(.auth-locked) .quick-nav .logout-nav-link > .nav-label,
body:not(.auth-locked) .quick-nav .nav-group-items .nav-label,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-label {
  color: inherit !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
}

body:not(.auth-locked) .quick-nav .nav-group.is-open > .nav-group-toggle {
  background: #ecfdf5 !important;
  color: #334155 !important;
}

body:not(.auth-locked) .quick-nav > .sidebar-link.active,
body:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle.active,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active,
body:not(.auth-locked) .quick-nav .side-user .nav-text-link.active {
  background: #ecfdf5 !important;
  color: #047857 !important;
}

body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active {
  min-height: 42px !important;
  height: 42px !important;
  max-height: 42px !important;
}

body[data-page]:not(.auth-locked) .quick-nav > .sidebar-link,
body[data-page]:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle,
body[data-page]:not(.auth-locked) .quick-nav .side-user .nav-text-link,
body[data-page]:not(.auth-locked) .quick-nav .logout-nav-link,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active,
body[data-page]:not(.auth-locked) .quick-nav > .sidebar-link > .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle > .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .side-user .nav-text-link > .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .logout-nav-link > .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-label {
  color: #334155 !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
}

body[data-page]:not(.auth-locked) .quick-nav > .sidebar-link.active,
body[data-page]:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle.active,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active,
body[data-page]:not(.auth-locked) .quick-nav .side-user .nav-text-link.active {
  color: #047857 !important;
}

body:not(.auth-locked) .quick-nav .side-user .legacy-settings-link.nav-text-link {
  display: none !important;
}

/* v1.1.0 sidebar final equalize: main, account, and submenu labels. */
body:not(.auth-locked) .quick-nav > .sidebar-link,
body:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle,
body:not(.auth-locked) .quick-nav .side-user .nav-text-link,
body:not(.auth-locked) .quick-nav .logout-nav-link,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active,
body[data-page]:not(.auth-locked) .quick-nav > .sidebar-link,
body[data-page]:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle,
body[data-page]:not(.auth-locked) .quick-nav .side-user .nav-text-link,
body[data-page]:not(.auth-locked) .quick-nav .logout-nav-link,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active {
  color: #334155 !important;
  font-size: 15px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
}

body:not(.auth-locked) .quick-nav > .sidebar-link > .nav-label,
body:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle > .nav-label,
body:not(.auth-locked) .quick-nav .side-user .nav-text-link > .nav-label,
body:not(.auth-locked) .quick-nav .logout-nav-link > .nav-label,
body:not(.auth-locked) .quick-nav .nav-group-items .nav-label,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-label,
body[data-page]:not(.auth-locked) .quick-nav > .sidebar-link > .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle > .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .side-user .nav-text-link > .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .logout-nav-link > .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-label {
  color: inherit !important;
  font-size: 15px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

body:not(.auth-locked) .quick-nav .nav-group-items,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items {
  gap: 8px !important;
  margin: 0 !important;
  padding: 6px 0 10px 18px !important;
  border-left: 1px solid #e2e8f0 !important;
}

body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active {
  grid-template-columns: 8px minmax(0, 1fr) !important;
  gap: 8px !important;
  min-height: 40px !important;
  height: 40px !important;
  max-height: 40px !important;
  padding: 0 8px !important;
  border-radius: 10px !important;
}

body:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items,
body[data-page]:not(.auth-locked) .quick-nav .account-nav-group .nav-group-items {
  padding-left: 14px !important;
}

body:not(.auth-locked) .quick-nav .nav-dot,
body[data-page]:not(.auth-locked) .quick-nav .nav-dot {
  width: 6px !important;
  height: 6px !important;
}

@media (min-width: 769px) {
  body:not(.auth-locked) .quick-nav > .mobile-only-nav-link,
  body:not(.auth-locked) .quick-nav .side-user .legacy-settings-link.nav-text-link {
    display: none !important;
  }
}

/* v1.1.0 sidebar light typography: thin, same size, same gray color. */
body:not(.auth-locked) .quick-nav > .sidebar-link,
body:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle,
body:not(.auth-locked) .quick-nav .side-user .nav-text-link,
body:not(.auth-locked) .quick-nav .logout-nav-link,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active,
body[data-page]:not(.auth-locked) .quick-nav > .sidebar-link,
body[data-page]:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle,
body[data-page]:not(.auth-locked) .quick-nav .side-user .nav-text-link,
body[data-page]:not(.auth-locked) .quick-nav .logout-nav-link,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active {
  color: #475569 !important;
  font-size: 15px !important;
  font-weight: 500 !important;
  line-height: 1.2 !important;
}

body:not(.auth-locked) .quick-nav > .sidebar-link > .nav-label,
body:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle > .nav-label,
body:not(.auth-locked) .quick-nav .side-user .nav-text-link > .nav-label,
body:not(.auth-locked) .quick-nav .logout-nav-link > .nav-label,
body:not(.auth-locked) .quick-nav .nav-group-items .nav-label,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-label,
body[data-page]:not(.auth-locked) .quick-nav > .sidebar-link > .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle > .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .side-user .nav-text-link > .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .logout-nav-link > .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-label {
  color: #475569 !important;
  font-size: 15px !important;
  font-weight: 500 !important;
  line-height: 1.2 !important;
}

body:not(.auth-locked) .quick-nav .nav-icon,
body:not(.auth-locked) .quick-nav .settings-gear,
body:not(.auth-locked) .quick-nav .nav-chevron,
body[data-page]:not(.auth-locked) .quick-nav .nav-icon,
body[data-page]:not(.auth-locked) .quick-nav .settings-gear,
body[data-page]:not(.auth-locked) .quick-nav .nav-chevron {
  color: #475569 !important;
}

body:not(.auth-locked) .quick-nav > .sidebar-link.active,
body:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle.active,
body:not(.auth-locked) .quick-nav .nav-group.is-open > .nav-group-toggle,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active,
body:not(.auth-locked) .quick-nav .side-user .nav-text-link.active,
body[data-page]:not(.auth-locked) .quick-nav > .sidebar-link.active,
body[data-page]:not(.auth-locked) .quick-nav .nav-group > .nav-group-toggle.active,
body[data-page]:not(.auth-locked) .quick-nav .nav-group.is-open > .nav-group-toggle,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active,
body[data-page]:not(.auth-locked) .quick-nav .side-user .nav-text-link.active {
  color: #475569 !important;
  font-weight: 500 !important;
}

body:not(.auth-locked) .quick-nav .nav-dot,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-dot,
body[data-page]:not(.auth-locked) .quick-nav .nav-dot,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-dot {
  background: #cbd5e1 !important;
}

/* v1.1.0 sidebar extra-light text: force regular weight everywhere. */
body:not(.auth-locked) .quick-nav,
body:not(.auth-locked) .quick-nav *,
body[data-page]:not(.auth-locked) .quick-nav,
body[data-page]:not(.auth-locked) .quick-nav * {
  font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
  font-weight: 400 !important;
  font-synthesis-weight: none !important;
  text-shadow: none !important;
  -webkit-font-smoothing: antialiased !important;
}

body:not(.auth-locked) .quick-nav .nav-label,
body:not(.auth-locked) .quick-nav .nav-label *,
body:not(.auth-locked) .quick-nav .nav-label::before,
body:not(.auth-locked) .quick-nav .nav-label::after,
body[data-page]:not(.auth-locked) .quick-nav .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .nav-label *,
body[data-page]:not(.auth-locked) .quick-nav .nav-label::before,
body[data-page]:not(.auth-locked) .quick-nav .nav-label::after {
  color: #475569 !important;
  font-size: 15px !important;
  font-weight: 400 !important;
  line-height: 1.2 !important;
}

/* v1.1.0 sidebar true-light font: load/use the real 300 weight and remove customer-only legacy styling. */
body:not(.auth-locked) .quick-nav,
body:not(.auth-locked) .quick-nav *,
body[data-page]:not(.auth-locked) .quick-nav,
body[data-page]:not(.auth-locked) .quick-nav * {
  font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
  font-weight: 300 !important;
  font-synthesis-weight: none !important;
  letter-spacing: 0 !important;
  text-shadow: none !important;
  -webkit-font-smoothing: antialiased !important;
}

body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#recordsPanel"],
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#trackingPanel"],
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#historyPanel"],
body[data-page]:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link,
body[data-page]:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active,
body[data-page]:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#recordsPanel"],
body[data-page]:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#trackingPanel"],
body[data-page]:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#historyPanel"] {
  color: #475569 !important;
  font-size: 15px !important;
  font-weight: 300 !important;
  line-height: 1.2 !important;
}

body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active .nav-label,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#recordsPanel"] .nav-label,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#trackingPanel"] .nav-label,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#historyPanel"] .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .sidebar-link.active .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#recordsPanel"] .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#trackingPanel"] .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items > a[href="#historyPanel"] .nav-label {
  color: #475569 !important;
  font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
  font-size: 15px !important;
  font-weight: 300 !important;
  line-height: 1.2 !important;
}

body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label::before,
body:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label::after,
body[data-page]:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label::before,
body[data-page]:not(.auth-locked) .quick-nav .customer-nav-group .nav-group-items .nav-label::after {
  content: none !important;
  display: none !important;
  font-size: 0 !important;
  font-weight: 300 !important;
}

/* v1.1.0 sidebar submenu absolute final: every submenu uses one font system. */
body:not(.auth-locked) .quick-nav .nav-group-items,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items {
  display: flex !important;
  flex-direction: column !important;
  gap: 8px !important;
  margin: 0 !important;
  padding: 6px 0 10px 18px !important;
  border-left: 1px solid #e2e8f0 !important;
}

body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active {
  display: grid !important;
  grid-template-columns: 8px minmax(0, 1fr) !important;
  align-items: center !important;
  gap: 8px !important;
  min-height: 40px !important;
  height: 40px !important;
  max-height: 40px !important;
  width: 100% !important;
  padding: 0 8px !important;
  margin: 0 !important;
  border-radius: 10px !important;
  color: #475569 !important;
  font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
  font-size: 15px !important;
  font-weight: 300 !important;
  line-height: 1.2 !important;
  letter-spacing: 0 !important;
  text-shadow: none !important;
  -webkit-font-smoothing: antialiased !important;
}

body:not(.auth-locked) .quick-nav .nav-group-items .nav-label,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .nav-label,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-label {
  display: block !important;
  min-width: 0 !important;
  max-width: 100% !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  color: #475569 !important;
  font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
  font-size: 15px !important;
  font-weight: 300 !important;
  line-height: 1.2 !important;
  letter-spacing: 0 !important;
  text-shadow: none !important;
  -webkit-font-smoothing: antialiased !important;
}

body:not(.auth-locked) .quick-nav .nav-group-items .nav-label::before,
body:not(.auth-locked) .quick-nav .nav-group-items .nav-label::after,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .nav-label::before,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .nav-label::after {
  content: none !important;
  display: none !important;
  visibility: hidden !important;
  font-size: 0 !important;
  font-weight: 300 !important;
}

body:not(.auth-locked) .quick-nav .nav-group-items .nav-dot,
body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-dot,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .nav-dot,
body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active .nav-dot {
  display: block !important;
  width: 6px !important;
  height: 6px !important;
  border-radius: 999px !important;
  background: #cbd5e1 !important;
}

/* v1.1.0 account/security page: card layout and working password checklist. */
body:not(.auth-locked) .account-settings-page {
  padding: 30px 32px 96px !important;
  background: #f8fafc !important;
}

body:not(.auth-locked) .account-settings-page > .panel-title,
body:not(.auth-locked) .account-settings-page .account-shop-summary,
body:not(.auth-locked) .account-settings-page .account-tabs,
body:not(.auth-locked) .account-settings-page #accountProfileMount > .panel-title,
body:not(.auth-locked) .account-settings-page #userProfileForm > .panel-title {
  display: none !important;
}

body:not(.auth-locked) .account-settings-page .account-grid,
body:not(.auth-locked) .account-settings-page .account-card,
body:not(.auth-locked) .account-settings-page .account-card .save-confirm-panel {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body:not(.auth-locked) .account-settings-page .account-card.hidden {
  display: none !important;
}

body:not(.auth-locked) .account-settings-page #userProfileForm {
  display: grid !important;
  grid-template-columns: minmax(0, 1.05fr) minmax(360px, .95fr) !important;
  gap: 22px !important;
  align-items: stretch !important;
  width: 100% !important;
}

body:not(.auth-locked) .account-settings-page .account-profile-card,
body:not(.auth-locked) .account-settings-page .account-password-card,
body:not(.auth-locked) .account-settings-page .profile-signature-box,
body:not(.auth-locked) .account-settings-page #userManageForm,
body:not(.auth-locked) .account-settings-page #accountUsersMount .user-list {
  border: 1px solid #e5e7eb !important;
  border-radius: 18px !important;
  background: rgba(255, 255, 255, .96) !important;
  box-shadow: 0 16px 38px rgba(15, 23, 42, .08) !important;
}

body:not(.auth-locked) .account-settings-page .account-profile-card,
body:not(.auth-locked) .account-settings-page .account-password-card {
  grid-column: 1 !important;
  padding: 28px !important;
}

body:not(.auth-locked) .account-settings-page .profile-signature-box {
  grid-column: 2 !important;
  grid-row: 1 / span 2 !important;
  margin: 0 !important;
  padding: 28px !important;
}

body:not(.auth-locked) .account-settings-page .account-section-title,
body:not(.auth-locked) .account-settings-page .account-password-heading {
  display: flex !important;
  align-items: flex-start !important;
  gap: 14px !important;
  margin: 0 0 24px !important;
}

body:not(.auth-locked) .account-settings-page .account-section-title > span,
body:not(.auth-locked) .account-settings-page .account-password-heading::before {
  content: "" !important;
  display: inline-flex !important;
  width: 42px !important;
  height: 42px !important;
  min-width: 42px !important;
  border-radius: 999px !important;
  background: #dcfce7 !important;
  box-shadow: inset 0 0 0 1px #bbf7d0 !important;
}

body:not(.auth-locked) .account-settings-page .account-password-heading::before {
  content: "" !important;
}

body:not(.auth-locked) .account-settings-page .account-section-title h3,
body:not(.auth-locked) .account-settings-page .account-password-heading strong {
  margin: 0 !important;
  color: #0f172a !important;
  font-size: 1.12rem !important;
  font-weight: 700 !important;
}

body:not(.auth-locked) .account-settings-page .account-section-title p,
body:not(.auth-locked) .account-settings-page .account-password-heading span {
  display: block !important;
  margin: 8px 0 0 !important;
  color: #64748b !important;
  font-size: .9rem !important;
  font-weight: 500 !important;
}

body:not(.auth-locked) .account-settings-page .account-profile-picture {
  display: none !important;
}

body:not(.auth-locked) .account-settings-page .account-profile-hero {
  display: block !important;
  width: 100% !important;
  min-width: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
}

body:not(.auth-locked) .account-settings-page .account-section-title > div,
body:not(.auth-locked) .account-settings-page .account-password-heading > div {
  min-width: 0 !important;
  max-width: 100% !important;
}

body:not(.auth-locked) .account-settings-page .account-profile-readonly-grid,
body:not(.auth-locked) .account-settings-page .compact-password-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 18px 22px !important;
  margin: 0 !important;
  padding: 0 !important;
}

body:not(.auth-locked) .account-settings-page .compact-password-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
}

body:not(.auth-locked) .account-settings-page .account-info-row-wide {
  display: block !important;
  margin-top: 18px !important;
}

body:not(.auth-locked) .account-settings-page label,
body:not(.auth-locked) .account-settings-page .account-info-row {
  display: block !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
}

body:not(.auth-locked) .account-settings-page label > span,
body:not(.auth-locked) .account-settings-page .account-info-row > span,
body:not(.auth-locked) .account-settings-page .signature-preview-label {
  display: block !important;
  margin: 0 0 8px !important;
  color: #475569 !important;
  font-size: .88rem !important;
  font-weight: 700 !important;
}

body:not(.auth-locked) .account-settings-page input,
body:not(.auth-locked) .account-settings-page textarea,
body:not(.auth-locked) .account-settings-page select {
  width: 100% !important;
  min-height: 46px !important;
  padding: 10px 42px 10px 14px !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 10px !important;
  background: #fff !important;
  color: #0f172a !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, .04) !important;
  font-size: .98rem !important;
  font-weight: 600 !important;
  pointer-events: auto !important;
}

body:not(.auth-locked) .account-settings-page input[readonly] {
  background: #fff !important;
}

body:not(.auth-locked) .account-settings-page .account-info-row {
  position: relative !important;
}

body:not(.auth-locked) .account-settings-page .account-info-row::after {
  content: "✓" !important;
  position: absolute !important;
  right: 14px !important;
  bottom: 13px !important;
  display: grid !important;
  place-items: center !important;
  width: 20px !important;
  height: 20px !important;
  border-radius: 999px !important;
  color: #16a34a !important;
  border: 2px solid #22c55e !important;
  font-size: 12px !important;
  font-weight: 800 !important;
}

body:not(.auth-locked) .account-settings-page .signature-dropzone {
  display: grid !important;
  place-items: center !important;
  min-height: 210px !important;
  padding: 26px !important;
  border: 1.5px dashed #86efac !important;
  border-radius: 14px !important;
  background: #fbfefc !important;
  color: #166534 !important;
  text-align: center !important;
}

body:not(.auth-locked) .account-settings-page .signature-dropzone b {
  color: #16a34a !important;
  font-size: 42px !important;
}

body:not(.auth-locked) .account-settings-page .signature-dropzone em {
  color: #475569 !important;
  font-size: 1rem !important;
  font-style: normal !important;
  font-weight: 700 !important;
}

body:not(.auth-locked) .account-settings-page .signature-dropzone strong {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 42px !important;
  margin-top: 8px !important;
  padding: 0 22px !important;
  border: 1px solid #86efac !important;
  border-radius: 10px !important;
  background: #fff !important;
  color: #15803d !important;
  font-size: .92rem !important;
  font-weight: 700 !important;
}

body:not(.auth-locked) .account-settings-page .signature-upload-field input[type="file"] {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

body:not(.auth-locked) .account-settings-page .field-help {
  display: block !important;
  margin-top: 10px !important;
  color: #64748b !important;
  font-size: .82rem !important;
}

body:not(.auth-locked) .account-settings-page .signature-preview {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 160px !important;
  margin-top: 10px !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 10px !important;
  background: #fff !important;
}

body:not(.auth-locked) .account-settings-page .signature-preview.hidden::before {
  content: "ยังไม่มีลายเซ็น" !important;
  color: #94a3b8 !important;
}

body:not(.auth-locked) .account-settings-page .signature-preview img {
  max-width: 90% !important;
  max-height: 130px !important;
  object-fit: contain !important;
}

body:not(.auth-locked) .account-settings-page .signature-note {
  display: block !important;
  margin-top: 14px !important;
  color: #64748b !important;
  font-size: .86rem !important;
}

body:not(.auth-locked) .account-settings-page .password-strength-preview {
  display: grid !important;
  grid-template-columns: 1fr auto !important;
  gap: 10px 16px !important;
  align-items: center !important;
  margin-top: 22px !important;
}

body:not(.auth-locked) .account-settings-page .password-strength-preview > span {
  color: #64748b !important;
  font-size: .88rem !important;
  font-weight: 700 !important;
}

body:not(.auth-locked) .account-settings-page .password-strength-preview > strong {
  color: #16a34a !important;
  font-size: .9rem !important;
  font-weight: 700 !important;
}

body:not(.auth-locked) .account-settings-page .password-strength-preview > strong[data-strength="weak"] {
  color: #ef4444 !important;
}

body:not(.auth-locked) .account-settings-page .password-strength-preview > strong[data-strength="medium"] {
  color: #f59e0b !important;
}

body:not(.auth-locked) .account-settings-page .password-meter {
  grid-column: 1 / -1 !important;
  height: 10px !important;
  overflow: hidden !important;
  border-radius: 999px !important;
  background: #e5e7eb !important;
}

body:not(.auth-locked) .account-settings-page .password-meter i {
  display: block !important;
  width: 0;
  height: 100% !important;
  border-radius: inherit !important;
  background: #ef4444 !important;
  transition: width .18s ease, background .18s ease !important;
}

body:not(.auth-locked) .account-settings-page .password-meter i[data-strength="medium"] {
  background: #f59e0b !important;
}

body:not(.auth-locked) .account-settings-page .password-meter i[data-strength="strong"] {
  background: #16a34a !important;
}

body:not(.auth-locked) .account-settings-page .password-rule-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 10px 18px !important;
  margin-top: 18px !important;
}

body:not(.auth-locked) .account-settings-page .password-rule-grid span {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  color: #64748b !important;
  font-size: .86rem !important;
  font-weight: 600 !important;
}

body:not(.auth-locked) .account-settings-page .password-rule-grid span::before {
  content: "✓" !important;
  display: grid !important;
  place-items: center !important;
  width: 18px !important;
  height: 18px !important;
  border-radius: 999px !important;
  color: #94a3b8 !important;
  border: 1.5px solid #cbd5e1 !important;
  font-size: 11px !important;
  font-weight: 900 !important;
}

body:not(.auth-locked) .account-settings-page .password-rule-grid span.is-pass {
  color: #15803d !important;
}

body:not(.auth-locked) .account-settings-page .password-rule-grid span.is-pass::before {
  color: #16a34a !important;
  border-color: #22c55e !important;
}

body:not(.auth-locked) .account-settings-page .form-error {
  grid-column: 1 / -1 !important;
}

body:not(.auth-locked) .account-settings-page #userProfileForm > .confirm-actions {
  position: sticky !important;
  bottom: 0 !important;
  grid-column: 1 / -1 !important;
  display: flex !important;
  justify-content: flex-end !important;
  gap: 18px !important;
  margin: 0 -32px -96px !important;
  padding: 20px 32px !important;
  border-top: 1px solid #e5e7eb !important;
  background: rgba(255, 255, 255, .94) !important;
  backdrop-filter: blur(12px) !important;
  z-index: 10 !important;
}

body:not(.auth-locked) .account-settings-page #userProfileForm > .confirm-actions button {
  min-width: 170px !important;
  min-height: 50px !important;
  border-radius: 12px !important;
  font-size: .98rem !important;
  font-weight: 700 !important;
}

body:not(.auth-locked) .account-settings-page #userProfileForm > .confirm-actions .primary-button::before {
  content: "▣" !important;
  margin-right: 8px !important;
}

body:not(.auth-locked) .account-settings-page #userManageForm {
  padding: 28px !important;
}

body:not(.auth-locked) .account-settings-page .password-security-box {
  margin: 18px 0 20px !important;
}

@media (max-width: 1280px) {
  body:not(.auth-locked) .account-settings-page #userProfileForm {
    grid-template-columns: 1fr !important;
  }

  body:not(.auth-locked) .account-settings-page .profile-signature-box {
    grid-column: 1 !important;
    grid-row: auto !important;
  }
}

@media (max-width: 980px) {

  body:not(.auth-locked) .account-settings-page .compact-password-grid,
  body:not(.auth-locked) .account-settings-page .account-profile-readonly-grid,
  body:not(.auth-locked) .account-settings-page .password-rule-grid {
    grid-template-columns: 1fr !important;
  }
}

/* v1.1.0 account balance: calmer typography, even card rhythm, no special-character rule. */
body:not(.auth-locked) .account-settings-page {
  color: #334155 !important;
  font-family: "IBM Plex Sans Thai", "Inter", system-ui, sans-serif !important;
}

body:not(.auth-locked) .account-settings-page #userProfileForm {
  grid-template-columns: minmax(0, 1fr) minmax(360px, .88fr) !important;
  gap: 20px !important;
  align-items: stretch !important;
  padding: 24px !important;
}

body:not(.auth-locked) .account-settings-page .account-profile-card,
body:not(.auth-locked) .account-settings-page .account-password-card,
body:not(.auth-locked) .account-settings-page .profile-signature-box {
  padding: 24px !important;
  border-radius: 14px !important;
  border-color: #e2e8f0 !important;
  box-shadow: 0 10px 28px rgba(15, 23, 42, .06) !important;
}

body:not(.auth-locked) .account-settings-page .account-profile-card,
body:not(.auth-locked) .account-settings-page .account-password-card {
  display: block !important;
}

body:not(.auth-locked) .account-settings-page .account-profile-hero {
  display: block !important;
  margin: 0 0 20px !important;
}

body:not(.auth-locked) .account-settings-page .account-section-title,
body:not(.auth-locked) .account-settings-page .account-password-heading {
  display: flex !important;
  align-items: flex-start !important;
  gap: 12px !important;
  margin: 0 0 20px !important;
}

body:not(.auth-locked) .account-settings-page .account-section-title > span,
body:not(.auth-locked) .account-settings-page .account-password-heading::before {
  width: 36px !important;
  height: 36px !important;
  min-width: 36px !important;
  border-radius: 999px !important;
}

body:not(.auth-locked) .account-settings-page .account-section-title h3,
body:not(.auth-locked) .account-settings-page .account-password-heading strong {
  margin: 0 !important;
  color: #0f172a !important;
  font-size: 1rem !important;
  font-weight: 700 !important;
  line-height: 1.25 !important;
  letter-spacing: 0 !important;
}

body:not(.auth-locked) .account-settings-page .account-section-title p,
body:not(.auth-locked) .account-settings-page .account-password-heading span {
  max-width: 32rem !important;
  margin: 4px 0 0 !important;
  color: #64748b !important;
  font-size: .84rem !important;
  font-weight: 500 !important;
  line-height: 1.45 !important;
}

body:not(.auth-locked) .account-settings-page .account-profile-picture {
  display: none !important;
}

body:not(.auth-locked) .account-settings-page .account-profile-readonly-grid,
body:not(.auth-locked) .account-settings-page .compact-password-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 14px 16px !important;
  margin: 0 !important;
}

body:not(.auth-locked) .account-settings-page .account-info-row-wide {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  margin-top: 14px !important;
}

body:not(.auth-locked) .account-settings-page label > span,
body:not(.auth-locked) .account-settings-page .account-info-row > span,
body:not(.auth-locked) .account-settings-page .signature-preview-label {
  display: block !important;
  margin: 0 0 7px !important;
  color: #475569 !important;
  font-size: .82rem !important;
  font-weight: 650 !important;
  line-height: 1.35 !important;
  letter-spacing: 0 !important;
}

body:not(.auth-locked) .account-settings-page input,
body:not(.auth-locked) .account-settings-page textarea,
body:not(.auth-locked) .account-settings-page select {
  min-height: 42px !important;
  padding: 9px 38px 9px 12px !important;
  color: #0f172a !important;
  font-size: .92rem !important;
  font-weight: 600 !important;
  line-height: 1.35 !important;
}

body:not(.auth-locked) .account-settings-page .profile-signature-box {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) 260px !important;
  grid-template-areas:
    "title upload"
    "note previewLabel"
    "note preview" !important;
  column-gap: 28px !important;
  row-gap: 14px !important;
  align-content: start !important;
}

body:not(.auth-locked) .account-settings-page .profile-signature-box .account-section-title {
  grid-area: title !important;
}

body:not(.auth-locked) .account-settings-page .signature-upload-field {
  grid-area: upload !important;
  margin: 0 !important;
}

body:not(.auth-locked) .account-settings-page .signature-preview-label {
  grid-area: previewLabel !important;
  margin-top: 2px !important;
}

body:not(.auth-locked) .account-settings-page .signature-preview {
  grid-area: preview !important;
  min-height: 126px !important;
  border-radius: 12px !important;
}

body:not(.auth-locked) .account-settings-page .signature-note {
  grid-area: note !important;
  align-self: end !important;
  max-width: 34rem !important;
  margin: 0 !important;
  color: #64748b !important;
  font-size: .82rem !important;
  font-weight: 500 !important;
  line-height: 1.45 !important;
}

body:not(.auth-locked) .account-settings-page .signature-dropzone {
  min-height: 178px !important;
  padding: 20px !important;
  gap: 8px !important;
  border-radius: 14px !important;
}

body:not(.auth-locked) .account-settings-page .signature-dropzone b {
  width: 44px !important;
  height: 44px !important;
  font-size: 28px !important;
}

body:not(.auth-locked) .account-settings-page .signature-dropzone em {
  color: #334155 !important;
  font-size: .92rem !important;
  font-style: normal !important;
  font-weight: 700 !important;
  line-height: 1.3 !important;
}

body:not(.auth-locked) .account-settings-page .signature-dropzone small {
  color: #15803d !important;
  font-size: .78rem !important;
  font-weight: 700 !important;
}

body:not(.auth-locked) .account-settings-page .signature-dropzone strong {
  min-height: 38px !important;
  padding: 0 16px !important;
  border-radius: 10px !important;
  font-size: .84rem !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
}

body:not(.auth-locked) .account-settings-page .password-strength-preview {
  gap: 8px 14px !important;
  margin-top: 18px !important;
}

body:not(.auth-locked) .account-settings-page .password-strength-preview > span,
body:not(.auth-locked) .account-settings-page .password-strength-preview > strong {
  font-size: .84rem !important;
  line-height: 1.35 !important;
}

body:not(.auth-locked) .account-settings-page .password-meter {
  height: 8px !important;
}

body:not(.auth-locked) .account-settings-page .password-rule-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 9px 16px !important;
  margin-top: 14px !important;
}

body:not(.auth-locked) .account-settings-page .password-rule-grid span {
  color: #64748b !important;
  font-size: .81rem !important;
  font-weight: 600 !important;
  line-height: 1.32 !important;
}

body:not(.auth-locked) .account-settings-page .password-rule-grid span::before {
  width: 16px !important;
  height: 16px !important;
  min-width: 16px !important;
  font-size: 10px !important;
}

@media (max-width: 1280px) {
  body:not(.auth-locked) .account-settings-page #userProfileForm,
  body:not(.auth-locked) .account-settings-page .profile-signature-box {
    grid-template-columns: 1fr !important;
  }

  body:not(.auth-locked) .account-settings-page .profile-signature-box {
    grid-template-areas:
      "title"
      "upload"
      "previewLabel"
      "preview"
      "note" !important;
  }
}

@media (max-width: 980px) {
  body:not(.auth-locked) .account-settings-page #userProfileForm {
    padding: 18px !important;
  }

  body:not(.auth-locked) .account-settings-page .account-profile-card,
  body:not(.auth-locked) .account-settings-page .account-password-card,
  body:not(.auth-locked) .account-settings-page .profile-signature-box {
    padding: 18px !important;
  }

  body:not(.auth-locked) .account-settings-page .account-profile-readonly-grid,
  body:not(.auth-locked) .account-settings-page .compact-password-grid,
  body:not(.auth-locked) .account-settings-page .password-rule-grid {
    grid-template-columns: 1fr !important;
  }
}

/* v1.1.0 account balance2: keep password heading readable. */
body:not(.auth-locked) .account-settings-page .account-password-heading {
  display: grid !important;
  grid-template-columns: 36px max-content minmax(0, 1fr) !important;
  column-gap: 12px !important;
  row-gap: 4px !important;
  align-items: center !important;
}

body:not(.auth-locked) .account-settings-page .account-password-heading::before {
  grid-column: 1 !important;
  grid-row: 1 / span 2 !important;
}

body:not(.auth-locked) .account-settings-page .account-password-heading strong {
  grid-column: 2 !important;
  white-space: nowrap !important;
}

body:not(.auth-locked) .account-settings-page .account-password-heading span {
  grid-column: 3 !important;
  margin: 0 !important;
}

@media (max-width: 980px) {
  body:not(.auth-locked) .account-settings-page .account-password-heading {
    grid-template-columns: 36px minmax(0, 1fr) !important;
  }

  body:not(.auth-locked) .account-settings-page .account-password-heading strong,
  body:not(.auth-locked) .account-settings-page .account-password-heading span {
    grid-column: 2 !important;
  }
}

/* v1.1.0 account balance3: password heading follows the same two-line title rhythm. */
body:not(.auth-locked) .account-settings-page .account-password-heading {
  grid-template-columns: 36px minmax(0, 1fr) !important;
}

body:not(.auth-locked) .account-settings-page .account-password-heading strong,
body:not(.auth-locked) .account-settings-page .account-password-heading span {
  grid-column: 2 !important;
}

/* v1.1.0 user editor layout: match the requested admin create-user screen. */
body[data-page="account"] #userManageForm,
body:not(.auth-locked) .account-settings-page #userManageForm {
  position: relative !important;
  width: 100% !important;
  max-width: 100% !important;
  padding: 24px !important;
  overflow: visible !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 14px !important;
  background: rgba(255, 255, 255, .96) !important;
  box-shadow: 0 10px 30px rgba(15, 23, 42, .06) !important;
}

body[data-page="account"] #userManageForm::before,
body:not(.auth-locked) .account-settings-page #userManageForm::before {
  content: none !important;
}

body[data-page="account"] #userManageForm > .panel-title,
body:not(.auth-locked) .account-settings-page #userManageForm > .panel-title {
  display: grid !important;
  grid-template-columns: 40px minmax(0, 1fr) auto !important;
  gap: 12px !important;
  align-items: center !important;
  margin: 0 0 22px !important;
  padding: 0 !important;
}

body[data-page="account"] #userManageForm .user-editor-title-icon,
body:not(.auth-locked) .account-settings-page #userManageForm .user-editor-title-icon {
  display: grid !important;
  place-items: center !important;
  width: 34px !important;
  height: 34px !important;
  border-radius: 999px !important;
  color: #10b981 !important;
  background: #dcfce7 !important;
  font-size: 1.35rem !important;
  font-weight: 800 !important;
}

body[data-page="account"] #userManageForm > .panel-title h2,
body:not(.auth-locked) .account-settings-page #userManageForm > .panel-title h2 {
  margin: 0 !important;
  color: #0f172a !important;
  font-size: 1.42rem !important;
  font-weight: 800 !important;
  line-height: 1.16 !important;
  letter-spacing: 0 !important;
}

body[data-page="account"] #userManageForm > .panel-title p,
body:not(.auth-locked) .account-settings-page #userManageForm > .panel-title p {
  margin: 4px 0 0 !important;
  color: #64748b !important;
  font-size: .86rem !important;
  font-weight: 600 !important;
  line-height: 1.35 !important;
}

body[data-page="account"] #userManageForm .user-editor-top-actions,
body:not(.auth-locked) .account-settings-page #userManageForm .user-editor-top-actions {
  display: flex !important;
  gap: 10px !important;
  align-items: center !important;
}

body[data-page="account"] #userManageForm .user-editor-top-actions button,
body:not(.auth-locked) .account-settings-page #userManageForm .user-editor-top-actions button {
  min-height: 42px !important;
  min-width: 102px !important;
  padding: 0 18px !important;
  border-radius: 10px !important;
  font-size: .86rem !important;
  font-weight: 700 !important;
}

body[data-page="account"] #userManageForm .user-editor-top-actions .status-toggle-switch,
body:not(.auth-locked) .account-settings-page #userManageForm .user-editor-top-actions .status-toggle-switch {
  display: inline-flex !important;
  min-width: 154px !important;
  min-height: 42px !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 10px !important;
  padding: 0 14px 0 10px !important;
  border: 1px solid #bbf7d0 !important;
  border-radius: 999px !important;
  color: #047857 !important;
  background: #f0fdf4 !important;
  font-size: .82rem !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  white-space: nowrap !important;
  box-shadow: none !important;
}

body[data-page="account"] #userManageForm .user-editor-top-actions .status-toggle-switch.hidden,
body:not(.auth-locked) .account-settings-page #userManageForm .user-editor-top-actions .status-toggle-switch.hidden {
  display: none !important;
}

body[data-page="account"] #userManageForm .user-editor-top-actions .status-toggle-track,
body:not(.auth-locked) .account-settings-page #userManageForm .user-editor-top-actions .status-toggle-track {
  position: relative !important;
  display: inline-flex !important;
  width: 42px !important;
  height: 24px !important;
  flex: 0 0 42px !important;
  border-radius: 999px !important;
  background: #10b981 !important;
  transition: background .18s ease !important;
}

body[data-page="account"] #userManageForm .user-editor-top-actions .status-toggle-track i,
body:not(.auth-locked) .account-settings-page #userManageForm .user-editor-top-actions .status-toggle-track i {
  position: absolute !important;
  top: 3px !important;
  left: 21px !important;
  width: 18px !important;
  height: 18px !important;
  border-radius: 999px !important;
  background: #fff !important;
  box-shadow: 0 2px 6px rgba(15, 23, 42, .18) !important;
  transition: left .18s ease !important;
}

body[data-page="account"] #userManageForm .user-editor-top-actions .status-toggle-switch.is-off,
body:not(.auth-locked) .account-settings-page #userManageForm .user-editor-top-actions .status-toggle-switch.is-off {
  color: #b45309 !important;
  border-color: #fed7aa !important;
  background: #fff7ed !important;
}

body[data-page="account"] #userManageForm .user-editor-top-actions .status-toggle-switch.is-off .status-toggle-track,
body:not(.auth-locked) .account-settings-page #userManageForm .user-editor-top-actions .status-toggle-switch.is-off .status-toggle-track {
  background: #f59e0b !important;
}

body[data-page="account"] #userManageForm .user-editor-top-actions .status-toggle-switch.is-off .status-toggle-track i,
body:not(.auth-locked) .account-settings-page #userManageForm .user-editor-top-actions .status-toggle-switch.is-off .status-toggle-track i {
  left: 3px !important;
}

body[data-page="account"] #userManageForm .user-editor-top-actions .status-toggle-switch:disabled,
body:not(.auth-locked) .account-settings-page #userManageForm .user-editor-top-actions .status-toggle-switch:disabled {
  opacity: .55 !important;
  cursor: not-allowed !important;
}

body[data-page="account"] #userManageForm .user-manage-tabs,
body:not(.auth-locked) .account-settings-page #userManageForm .user-manage-tabs {
  display: none !important;
}

body[data-page="account"] #managedUserEditor,
body:not(.auth-locked) .account-settings-page #managedUserEditor {
  display: grid !important;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, .9fr) !important;
  gap: 12px !important;
}

body[data-page="account"] #managedUserEditor.hidden,
body:not(.auth-locked) .account-settings-page #managedUserEditor.hidden {
  display: none !important;
}

body[data-page="account"] #managedUserEditor .user-editor-card,
body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-card {
  padding: 18px !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 12px !important;
  background: rgba(255, 255, 255, .98) !important;
  box-shadow: 0 8px 22px rgba(15, 23, 42, .04) !important;
}

body[data-page="account"] #managedUserEditor .user-editor-section-title,
body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-section-title {
  display: flex !important;
  align-items: center !important;
  gap: 9px !important;
  margin: 0 0 16px !important;
}

body[data-page="account"] #managedUserEditor .user-editor-section-title > span,
body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-section-title > span {
  display: grid !important;
  place-items: center !important;
  width: 24px !important;
  height: 24px !important;
  border-radius: 8px !important;
  color: #10b981 !important;
  background: #ecfdf5 !important;
  font-size: .92rem !important;
  font-weight: 800 !important;
}

body[data-page="account"] #managedUserEditor .user-editor-section-title h3,
body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-section-title h3 {
  margin: 0 !important;
  color: #047857 !important;
  font-size: .98rem !important;
  font-weight: 800 !important;
  line-height: 1.25 !important;
}

body[data-page="account"] #managedUserEditor .user-editor-section-title p,
body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-section-title p {
  margin: 3px 0 0 !important;
  color: #64748b !important;
  font-size: .78rem !important;
  font-weight: 600 !important;
  line-height: 1.35 !important;
}

body[data-page="account"] #managedUserEditor .user-editor-user-card .field-grid,
body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-user-card .field-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 16px 18px !important;
  margin: 0 0 18px !important;
}

body[data-page="account"] #managedUserEditor .user-editor-user-card .field-grid:last-child,
body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-user-card .field-grid:last-child {
  margin-bottom: 0 !important;
}

body[data-page="account"] #managedUserEditor label:not(.checkbox-line) > span,
body:not(.auth-locked) .account-settings-page #managedUserEditor label:not(.checkbox-line) > span {
  color: #334155 !important;
  font-size: .82rem !important;
  font-weight: 700 !important;
  line-height: 1.35 !important;
}

body[data-page="account"] #managedUserEditor input[type="text"],
body[data-page="account"] #managedUserEditor input[type="tel"],
body[data-page="account"] #managedUserEditor input[type="password"],
body:not(.auth-locked) .account-settings-page #managedUserEditor input[type="text"],
body:not(.auth-locked) .account-settings-page #managedUserEditor input[type="tel"],
body:not(.auth-locked) .account-settings-page #managedUserEditor input[type="password"] {
  min-height: 42px !important;
  padding: 9px 12px !important;
  border: 1px solid #dbe3ef !important;
  border-radius: 10px !important;
  background: #fff !important;
  color: #0f172a !important;
  font-size: .9rem !important;
  font-weight: 600 !important;
  box-shadow: 0 2px 8px rgba(15, 23, 42, .025) !important;
}

body[data-page="account"] #managedUserEditor input::placeholder,
body:not(.auth-locked) .account-settings-page #managedUserEditor input::placeholder {
  color: #94a3b8 !important;
  font-weight: 500 !important;
}

body[data-page="account"] #managedUserEditor #newUserPasswordSecurity,
body:not(.auth-locked) .account-settings-page #managedUserEditor #newUserPasswordSecurity {
  align-self: stretch !important;
  margin: 0 !important;
}

body[data-page="account"] #managedUserEditor #newUserPasswordSecurity .password-strength-preview,
body:not(.auth-locked) .account-settings-page #managedUserEditor #newUserPasswordSecurity .password-strength-preview {
  display: grid !important;
  grid-template-columns: auto minmax(0, 1fr) 42px !important;
  gap: 8px !important;
  align-items: center !important;
  margin: 0 0 14px !important;
}

body[data-page="account"] #managedUserEditor #newUserPasswordSecurity .password-strength-preview > span,
body:not(.auth-locked) .account-settings-page #managedUserEditor #newUserPasswordSecurity .password-strength-preview > span {
  color: #334155 !important;
  font-size: .84rem !important;
  font-weight: 700 !important;
}

body[data-page="account"] #managedUserEditor #newUserPasswordSecurity .password-strength-preview > strong,
body:not(.auth-locked) .account-settings-page #managedUserEditor #newUserPasswordSecurity .password-strength-preview > strong {
  color: #f59e0b !important;
  font-size: .82rem !important;
  font-weight: 800 !important;
  text-align: right !important;
}

body[data-page="account"] #managedUserEditor #newUserPasswordSecurity .password-meter,
body:not(.auth-locked) .account-settings-page #managedUserEditor #newUserPasswordSecurity .password-meter {
  grid-column: 1 / -1 !important;
  height: 8px !important;
  border-radius: 999px !important;
}

body[data-page="account"] #managedUserEditor .password-rule-heading,
body:not(.auth-locked) .account-settings-page #managedUserEditor .password-rule-heading {
  margin: 8px 0 10px !important;
  color: #64748b !important;
  font-size: .78rem !important;
  font-weight: 700 !important;
}

body[data-page="account"] #managedUserEditor #newUserPasswordSecurity .password-rule-grid,
body:not(.auth-locked) .account-settings-page #managedUserEditor #newUserPasswordSecurity .password-rule-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 8px 12px !important;
  margin: 0 !important;
}

body[data-page="account"] #managedUserEditor #newUserPasswordSecurity .password-rule-grid span,
body:not(.auth-locked) .account-settings-page #managedUserEditor #newUserPasswordSecurity .password-rule-grid span {
  color: #64748b !important;
  font-size: .8rem !important;
  font-weight: 650 !important;
}

body[data-page="account"] #managedUserEditor .permission-preset-box,
body[data-page="account"] #managedUserEditor .permission-box,
body[data-page="account"] #managedUserEditor .user-editor-secure-note,
body[data-page="account"] #managedUserEditor .form-error,
body[data-page="account"] #managedUserEditor .confirm-actions,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-preset-box,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-box,
body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-secure-note,
body:not(.auth-locked) .account-settings-page #managedUserEditor .form-error,
body:not(.auth-locked) .account-settings-page #managedUserEditor .confirm-actions {
  grid-column: 1 / -1 !important;
}

body[data-page="account"] #managedUserEditor .permission-preset-grid,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-preset-grid {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 14px !important;
}

body[data-page="account"] #managedUserEditor .permission-preset-card,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-preset-card {
  position: relative !important;
  display: grid !important;
  justify-items: center !important;
  gap: 6px !important;
  min-height: 124px !important;
  padding: 18px 14px !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 12px !important;
  background: #fff !important;
  color: #334155 !important;
  box-shadow: 0 8px 18px rgba(15, 23, 42, .035) !important;
  cursor: pointer !important;
}

body[data-page="account"] #managedUserEditor .permission-preset-card.active,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-preset-card.active {
  border-color: #34d399 !important;
  background: linear-gradient(180deg, #f0fdf4, #fff) !important;
}

body[data-page="account"] #managedUserEditor .permission-preset-card .preset-icon,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-preset-card .preset-icon {
  color: #10b981 !important;
  font-size: 1.7rem !important;
  line-height: 1 !important;
}

body[data-page="account"] #managedUserEditor .permission-preset-card strong,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-preset-card strong {
  color: #0f172a !important;
  font-size: .92rem !important;
  font-weight: 800 !important;
  line-height: 1.25 !important;
}

body[data-page="account"] #managedUserEditor .permission-preset-card small,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-preset-card small {
  color: #64748b !important;
  font-size: .76rem !important;
  font-weight: 600 !important;
  line-height: 1.35 !important;
  text-align: center !important;
}

body[data-page="account"] #managedUserEditor .permission-preset-card i,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-preset-card i {
  position: absolute !important;
  right: 14px !important;
  top: 14px !important;
  display: none !important;
  place-items: center !important;
  width: 24px !important;
  height: 24px !important;
  border-radius: 999px !important;
  color: #fff !important;
  background: #10b981 !important;
  font-style: normal !important;
  font-size: .8rem !important;
  font-weight: 800 !important;
}

body[data-page="account"] #managedUserEditor .permission-preset-card.active i,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-preset-card.active i {
  display: grid !important;
}

body[data-page="account"] #managedUserEditor .permission-custom-grid,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-custom-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 14px !important;
}

body[data-page="account"] #managedUserEditor .permission-group-card,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-group-card {
  padding: 14px !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 12px !important;
  background: #fff !important;
}

body[data-page="account"] #managedUserEditor .permission-group-card h4,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-group-card h4 {
  margin: 0 0 10px !important;
  color: #0f172a !important;
  font-size: .9rem !important;
  font-weight: 800 !important;
  line-height: 1.3 !important;
}

body[data-page="account"] #managedUserEditor .permission-group-card p,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-group-card p {
  margin: 0 !important;
  color: #64748b !important;
  font-size: .78rem !important;
  font-weight: 600 !important;
  line-height: 1.45 !important;
}

body[data-page="account"] #managedUserEditor .checkbox-line,
body:not(.auth-locked) .account-settings-page #managedUserEditor .checkbox-line {
  min-height: 36px !important;
  padding: 6px 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-page="account"] #managedUserEditor .checkbox-line span,
body:not(.auth-locked) .account-settings-page #managedUserEditor .checkbox-line span {
  color: #475569 !important;
  font-size: .82rem !important;
  font-weight: 650 !important;
}

body[data-page="account"] #managedUserEditor .user-editor-secure-note,
body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-secure-note {
  display: grid !important;
  grid-template-columns: 28px minmax(0, 1fr) auto !important;
  gap: 12px !important;
  align-items: center !important;
  min-height: 46px !important;
  padding: 10px 14px !important;
  border: 1px solid #bbf7d0 !important;
  border-radius: 12px !important;
  background: #ecfdf5 !important;
}

body[data-page="account"] #managedUserEditor .user-editor-secure-note span,
body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-secure-note span {
  display: grid !important;
  place-items: center !important;
  width: 26px !important;
  height: 26px !important;
  border-radius: 999px !important;
  color: #fff !important;
  background: #10b981 !important;
  font-weight: 800 !important;
}

body[data-page="account"] #managedUserEditor .user-editor-secure-note strong,
body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-secure-note strong {
  color: #047857 !important;
  font-size: .82rem !important;
  font-weight: 700 !important;
}

body[data-page="account"] #managedUserEditor .user-editor-secure-note em,
body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-secure-note em {
  color: #64748b !important;
  font-size: .78rem !important;
  font-style: normal !important;
  font-weight: 650 !important;
}

body[data-page="account"] #managedUserEditor .confirm-actions,
body:not(.auth-locked) .account-settings-page #managedUserEditor .confirm-actions {
  display: none !important;
}

/* v1.1.0 user editor layout2: clear older permission-box grid decoration. */
body[data-page="account"] #managedUserEditor .permission-box,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-box {
  display: block !important;
  margin: 0 !important;
  padding: 18px !important;
}

body[data-page="account"] #managedUserEditor .permission-box::before,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-box::before {
  content: none !important;
  display: none !important;
}

body[data-page="account"] #managedUserEditor .permission-box .user-editor-section-title,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-box .user-editor-section-title {
  margin-bottom: 14px !important;
}

body[data-page="account"] #managedUserEditor .permission-box .permission-custom-grid,
body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-box .permission-custom-grid {
  width: 100% !important;
  margin: 0 !important;
}

@media (max-width: 1180px) {
  body[data-page="account"] #managedUserEditor,
  body:not(.auth-locked) .account-settings-page #managedUserEditor,
  body[data-page="account"] #managedUserEditor .permission-preset-grid,
  body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-preset-grid,
  body[data-page="account"] #managedUserEditor .permission-custom-grid,
  body:not(.auth-locked) .account-settings-page #managedUserEditor .permission-custom-grid {
    grid-template-columns: 1fr !important;
  }
}

@media (max-width: 760px) {
  body[data-page="account"] #userManageForm > .panel-title,
  body:not(.auth-locked) .account-settings-page #userManageForm > .panel-title {
    grid-template-columns: 34px minmax(0, 1fr) !important;
  }

  body[data-page="account"] #userManageForm .user-editor-top-actions,
  body:not(.auth-locked) .account-settings-page #userManageForm .user-editor-top-actions {
    grid-column: 1 / -1 !important;
    justify-content: stretch !important;
  }

  body[data-page="account"] #userManageForm .user-editor-top-actions button,
  body:not(.auth-locked) .account-settings-page #userManageForm .user-editor-top-actions button {
    flex: 1 1 0 !important;
  }

  body[data-page="account"] #managedUserEditor .user-editor-user-card .field-grid,
  body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-user-card .field-grid,
  body[data-page="account"] #managedUserEditor #newUserPasswordSecurity .password-rule-grid,
  body:not(.auth-locked) .account-settings-page #managedUserEditor #newUserPasswordSecurity .password-rule-grid,
  body[data-page="account"] #managedUserEditor .user-editor-secure-note,
  body:not(.auth-locked) .account-settings-page #managedUserEditor .user-editor-secure-note {
    grid-template-columns: 1fr !important;
  }
}

/* v1.1.0 signature responsive: content-width safe layout while resizing desktop. */
body:not(.auth-locked) .account-settings-page .profile-signature-box {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  grid-template-areas:
    "title"
    "upload"
    "previewLabel"
    "preview"
    "note" !important;
  gap: 14px !important;
  min-width: 0 !important;
  overflow: hidden !important;
}

body:not(.auth-locked) .account-settings-page .profile-signature-box .account-section-title {
  display: grid !important;
  grid-template-columns: 36px minmax(0, 1fr) !important;
  align-items: start !important;
  gap: 12px !important;
  min-width: 0 !important;
  margin: 0 !important;
}

body:not(.auth-locked) .account-settings-page .profile-signature-box .account-section-title > div,
body:not(.auth-locked) .account-settings-page .profile-signature-box .account-section-title h3,
body:not(.auth-locked) .account-settings-page .profile-signature-box .account-section-title p {
  min-width: 0 !important;
  max-width: 100% !important;
}

body:not(.auth-locked) .account-settings-page .profile-signature-box .account-section-title h3 {
  white-space: normal !important;
  overflow-wrap: normal !important;
  word-break: normal !important;
}

body:not(.auth-locked) .account-settings-page .profile-signature-box .account-section-title p,
body:not(.auth-locked) .account-settings-page .signature-note {
  white-space: normal !important;
  overflow-wrap: anywhere !important;
  word-break: normal !important;
}

body:not(.auth-locked) .account-settings-page .signature-upload-field,
body:not(.auth-locked) .account-settings-page .signature-dropzone,
body:not(.auth-locked) .account-settings-page .signature-preview {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  box-sizing: border-box !important;
}

body:not(.auth-locked) .account-settings-page .signature-dropzone {
  min-height: clamp(160px, 20vw, 220px) !important;
  padding: clamp(18px, 3vw, 28px) !important;
}

body:not(.auth-locked) .account-settings-page .signature-preview {
  min-height: 132px !important;
}

body:not(.auth-locked) .account-settings-page .signature-preview-label,
body:not(.auth-locked) .account-settings-page .signature-note {
  margin: 0 !important;
}

/* v1.1.0 toggle fix: prevent form input sizing from bloating permission switches. */
body[data-page="account"] #managedUserEditor .checkbox-line,
body:not(.auth-locked) .account-settings-page #managedUserEditor .checkbox-line {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) 42px !important;
  align-items: center !important;
  gap: 12px !important;
  min-height: 34px !important;
  padding: 5px 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-page="account"] #managedUserEditor .checkbox-line span,
body:not(.auth-locked) .account-settings-page #managedUserEditor .checkbox-line span {
  order: 1 !important;
  margin: 0 !important;
  min-width: 0 !important;
  color: #475569 !important;
  font-size: .82rem !important;
  font-weight: 650 !important;
  line-height: 1.3 !important;
}

body[data-page="account"] #managedUserEditor .checkbox-line input[type="checkbox"],
body[data-page="account"] #managedUserEditor .checkbox-line input[type="checkbox"]:not(:checked),
body:not(.auth-locked) .account-settings-page #managedUserEditor .checkbox-line input[type="checkbox"],
body:not(.auth-locked) .account-settings-page #managedUserEditor .checkbox-line input[type="checkbox"]:not(:checked) {
  appearance: none !important;
  -webkit-appearance: none !important;
  order: 2 !important;
  box-sizing: border-box !important;
  display: block !important;
  inline-size: 42px !important;
  block-size: 24px !important;
  width: 42px !important;
  min-width: 42px !important;
  max-width: 42px !important;
  height: 24px !important;
  min-height: 24px !important;
  max-height: 24px !important;
  flex: 0 0 42px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 1px solid rgba(148, 163, 184, .34) !important;
  border-radius: 999px !important;
  background: #d1d5db !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, .12) !important;
  filter: none !important;
  transform: none !important;
  cursor: pointer !important;
}

body[data-page="account"] #managedUserEditor .checkbox-line input[type="checkbox"]::before,
body:not(.auth-locked) .account-settings-page #managedUserEditor .checkbox-line input[type="checkbox"]::before {
  content: "" !important;
  position: absolute !important;
  left: 2px !important;
  top: 2px !important;
  inline-size: 18px !important;
  block-size: 18px !important;
  width: 18px !important;
  height: 18px !important;
  border-radius: 999px !important;
  background: #fff !important;
  box-shadow: 0 1px 4px rgba(15, 23, 42, .24) !important;
  transform: translateX(0) !important;
  transition: transform .18s ease !important;
}

body[data-page="account"] #managedUserEditor .checkbox-line input[type="checkbox"]:checked,
body:not(.auth-locked) .account-settings-page #managedUserEditor .checkbox-line input[type="checkbox"]:checked {
  background: #19c37d !important;
  border-color: rgba(14, 159, 110, .36) !important;
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, .2), 0 4px 10px rgba(25, 195, 125, .16) !important;
}

body[data-page="account"] #managedUserEditor .checkbox-line input[type="checkbox"]:checked::before,
body:not(.auth-locked) .account-settings-page #managedUserEditor .checkbox-line input[type="checkbox"]:checked::before {
  transform: translateX(18px) !important;
}

/* v1.1.0 profile actions: keep save buttons inside the profile form. */
body:not(.auth-locked) .account-settings-page #userProfileForm > .confirm-actions {
  position: static !important;
  bottom: auto !important;
  grid-column: 1 / -1 !important;
  display: flex !important;
  justify-content: flex-end !important;
  align-items: center !important;
  gap: 12px !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 18px 0 0 !important;
  border-top: 1px solid #e5e7eb !important;
  background: transparent !important;
  backdrop-filter: none !important;
  box-shadow: none !important;
  z-index: auto !important;
}

body:not(.auth-locked) .account-settings-page #userProfileForm > .confirm-actions button {
  min-width: 150px !important;
  min-height: 44px !important;
  padding: 0 18px !important;
  border-radius: 12px !important;
  font-size: .9rem !important;
  font-weight: 700 !important;
  box-shadow: none !important;
}

body:not(.auth-locked) .account-settings-page #userProfileForm > .confirm-actions .primary-button {
  box-shadow: 0 10px 24px rgba(25, 195, 125, .18) !important;
}

@media (max-width: 720px) {
  body:not(.auth-locked) .account-settings-page #userProfileForm > .confirm-actions {
    flex-direction: column-reverse !important;
    align-items: stretch !important;
  }

  body:not(.auth-locked) .account-settings-page #userProfileForm > .confirm-actions button {
    width: 100% !important;
  }
}

/* v1.1.0 users dashboard: account users list as summary cards + table. */
body[data-page="account"] #accountUsersMount,
body:not(.auth-locked) .account-settings-page #accountUsersMount {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  padding: 0 !important;
}

body[data-page="account"] #userManageList,
body:not(.auth-locked) .account-settings-page #userManageList {
  display: block !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-page="account"] #userManageList.hidden,
body:not(.auth-locked) .account-settings-page #userManageList.hidden {
  display: none !important;
}

body[data-page="account"] .users-dashboard,
body:not(.auth-locked) .account-settings-page .users-dashboard {
  display: grid !important;
  gap: 16px !important;
  width: 100% !important;
  min-width: 0 !important;
}

body[data-page="account"] .users-stat-grid,
body:not(.auth-locked) .account-settings-page .users-stat-grid {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 14px !important;
}

body[data-page="account"] .users-stat-card,
body:not(.auth-locked) .account-settings-page .users-stat-card {
  display: grid !important;
  grid-template-columns: 54px minmax(0, 1fr) !important;
  align-items: center !important;
  gap: 14px !important;
  min-height: 116px !important;
  padding: 18px !important;
  border: 1px solid #e5e7eb !important;
  border-radius: 12px !important;
  background: #fff !important;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .055) !important;
}

body[data-page="account"] .users-stat-icon,
body:not(.auth-locked) .account-settings-page .users-stat-icon {
  display: grid !important;
  place-items: center !important;
  width: 54px !important;
  height: 54px !important;
  border-radius: 12px !important;
  color: #10b981 !important;
  background: #ecfdf5 !important;
  font-size: 1.45rem !important;
  font-weight: 800 !important;
}

body[data-page="account"] .stat-active .users-stat-icon,
body:not(.auth-locked) .account-settings-page .stat-active .users-stat-icon {
  color: #2563eb !important;
  background: #eff6ff !important;
}

body[data-page="account"] .stat-disabled .users-stat-icon,
body:not(.auth-locked) .account-settings-page .stat-disabled .users-stat-icon {
  color: #7c3aed !important;
  background: #f5f3ff !important;
}

body[data-page="account"] .stat-roles .users-stat-icon,
body:not(.auth-locked) .account-settings-page .stat-roles .users-stat-icon {
  color: #f97316 !important;
  background: #fff7ed !important;
}

body[data-page="account"] .users-stat-card span:not(.users-stat-icon),
body:not(.auth-locked) .account-settings-page .users-stat-card span:not(.users-stat-icon) {
  display: block !important;
  color: #64748b !important;
  font-size: .86rem !important;
  font-weight: 700 !important;
  line-height: 1.3 !important;
}

body[data-page="account"] .users-stat-card strong,
body:not(.auth-locked) .account-settings-page .users-stat-card strong {
  color: #0f172a !important;
  font-size: 1.55rem !important;
  font-weight: 800 !important;
  line-height: 1.1 !important;
}

body[data-page="account"] .users-stat-card small,
body:not(.auth-locked) .account-settings-page .users-stat-card small {
  margin-left: 4px !important;
  color: #64748b !important;
  font-size: .84rem !important;
  font-weight: 700 !important;
}

body[data-page="account"] .users-table-card,
body:not(.auth-locked) .account-settings-page .users-table-card {
  overflow: hidden !important;
  border: 1px solid #e5e7eb !important;
  border-radius: 12px !important;
  background: #fff !important;
  box-shadow: 0 12px 26px rgba(15, 23, 42, .055) !important;
}

body[data-page="account"] .users-filter-tabs,
body:not(.auth-locked) .account-settings-page .users-filter-tabs {
  display: flex !important;
  gap: 28px !important;
  min-height: 58px !important;
  align-items: end !important;
  padding: 0 18px !important;
  border-bottom: 1px solid #e5e7eb !important;
}

body[data-page="account"] .users-filter-tabs button,
body:not(.auth-locked) .account-settings-page .users-filter-tabs button {
  position: relative !important;
  min-height: 58px !important;
  padding: 0 0 14px !important;
  border: 0 !important;
  background: transparent !important;
  color: #64748b !important;
  font-size: .86rem !important;
  font-weight: 750 !important;
}

body[data-page="account"] .users-filter-tabs button.active,
body:not(.auth-locked) .account-settings-page .users-filter-tabs button.active {
  color: #059669 !important;
}

body[data-page="account"] .users-filter-tabs button.active::after,
body:not(.auth-locked) .account-settings-page .users-filter-tabs button.active::after {
  content: "" !important;
  position: absolute !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  height: 3px !important;
  border-radius: 999px 999px 0 0 !important;
  background: #10b981 !important;
}

body[data-page="account"] .users-table-head,
body[data-page="account"] .users-table-row,
body:not(.auth-locked) .account-settings-page .users-table-head,
body:not(.auth-locked) .account-settings-page .users-table-row {
  display: grid !important;
  grid-template-columns: minmax(220px, 1.25fr) minmax(120px, .85fr) minmax(140px, .8fr) minmax(135px, .8fr) minmax(170px, .9fr) 96px !important;
  gap: 14px !important;
  align-items: center !important;
}

body[data-page="account"] .users-table-head,
body:not(.auth-locked) .account-settings-page .users-table-head {
  min-height: 52px !important;
  padding: 0 18px !important;
  color: #64748b !important;
  background: #f8fafc !important;
  border-bottom: 1px solid #e5e7eb !important;
  font-size: .8rem !important;
  font-weight: 800 !important;
}

body[data-page="account"] .users-table-row,
body:not(.auth-locked) .account-settings-page .users-table-row {
  min-height: 74px !important;
  padding: 12px 18px !important;
  border-bottom: 1px solid #edf2f7 !important;
}

body[data-page="account"] .users-table-row:last-child,
body:not(.auth-locked) .account-settings-page .users-table-row:last-child {
  border-bottom: 0 !important;
}

body[data-page="account"] .users-table-row.hidden,
body:not(.auth-locked) .account-settings-page .users-table-row.hidden {
  display: none !important;
}

body[data-page="account"] .users-user-cell,
body:not(.auth-locked) .account-settings-page .users-user-cell {
  display: grid !important;
  grid-template-columns: 44px minmax(0, 1fr) !important;
  gap: 12px !important;
  align-items: center !important;
  min-width: 0 !important;
}

body[data-page="account"] .users-avatar,
body:not(.auth-locked) .account-settings-page .users-avatar {
  display: grid !important;
  place-items: center !important;
  width: 44px !important;
  height: 44px !important;
  border-radius: 14px !important;
  color: #059669 !important;
  background: #ecfdf5 !important;
  font-size: 1rem !important;
  font-weight: 800 !important;
}

body[data-page="account"] .users-user-cell strong,
body:not(.auth-locked) .account-settings-page .users-user-cell strong {
  display: block !important;
  overflow: hidden !important;
  color: #0f172a !important;
  font-size: .9rem !important;
  font-weight: 800 !important;
  line-height: 1.25 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

body[data-page="account"] .users-user-cell small,
body[data-page="account"] .users-username,
body[data-page="account"] .users-last-login,
body:not(.auth-locked) .account-settings-page .users-user-cell small,
body:not(.auth-locked) .account-settings-page .users-username,
body:not(.auth-locked) .account-settings-page .users-last-login {
  color: #64748b !important;
  font-size: .82rem !important;
  font-weight: 700 !important;
  line-height: 1.35 !important;
}

body[data-page="account"] .users-role-pill,
body[data-page="account"] .users-status-pill,
body:not(.auth-locked) .account-settings-page .users-role-pill,
body:not(.auth-locked) .account-settings-page .users-status-pill {
  display: inline-flex !important;
  width: fit-content !important;
  min-height: 30px !important;
  align-items: center !important;
  gap: 7px !important;
  padding: 0 12px !important;
  border-radius: 9px !important;
  font-size: .78rem !important;
  font-weight: 800 !important;
  line-height: 1 !important;
}

body[data-page="account"] .users-role-pill.role-owner,
body:not(.auth-locked) .account-settings-page .users-role-pill.role-owner {
  color: #334155 !important;
  background: #f1f5f9 !important;
}

body[data-page="account"] .users-role-pill.role-manager,
body:not(.auth-locked) .account-settings-page .users-role-pill.role-manager {
  color: #7c3aed !important;
  background: #f3e8ff !important;
}

body[data-page="account"] .users-role-pill.role-finance,
body:not(.auth-locked) .account-settings-page .users-role-pill.role-finance {
  color: #047857 !important;
  background: #dffbed !important;
}

body[data-page="account"] .users-role-pill.role-staff,
body:not(.auth-locked) .account-settings-page .users-role-pill.role-staff {
  color: #2563eb !important;
  background: #eaf2ff !important;
}

body[data-page="account"] .users-role-pill.role-viewer,
body:not(.auth-locked) .account-settings-page .users-role-pill.role-viewer {
  color: #64748b !important;
  background: #f1f5f9 !important;
}

body[data-page="account"] .users-status-pill,
body:not(.auth-locked) .account-settings-page .users-status-pill {
  color: #059669 !important;
  background: #ecfdf5 !important;
}

body[data-page="account"] .users-status-pill.is-disabled,
body:not(.auth-locked) .account-settings-page .users-status-pill.is-disabled {
  color: #ef4444 !important;
  background: #fef2f2 !important;
}

body[data-page="account"] .users-status-pill i,
body:not(.auth-locked) .account-settings-page .users-status-pill i {
  width: 7px !important;
  height: 7px !important;
  border-radius: 999px !important;
  background: currentColor !important;
}

body[data-page="account"] .users-action-cell,
body:not(.auth-locked) .account-settings-page .users-action-cell {
  display: flex !important;
  justify-content: flex-end !important;
  gap: 8px !important;
}

body[data-page="account"] .users-icon-button,
body:not(.auth-locked) .account-settings-page .users-icon-button {
  display: grid !important;
  place-items: center !important;
  width: 38px !important;
  height: 38px !important;
  min-width: 38px !important;
  min-height: 38px !important;
  padding: 0 !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 10px !important;
  color: #475569 !important;
  background: #fff !important;
  font-size: 1rem !important;
  font-weight: 800 !important;
  box-shadow: 0 4px 10px rgba(15, 23, 42, .035) !important;
}

body[data-page="account"] .users-icon-button:disabled,
body:not(.auth-locked) .account-settings-page .users-icon-button:disabled {
  opacity: .5 !important;
  cursor: not-allowed !important;
}

body[data-page="account"] .users-delete-button,
body:not(.auth-locked) .account-settings-page .users-delete-button {
  color: #dc2626 !important;
  border-color: #fee2e2 !important;
  background: #fffafa !important;
  font-size: 1.15rem !important;
}

body[data-page="account"] .users-delete-button:not(:disabled):hover,
body:not(.auth-locked) .account-settings-page .users-delete-button:not(:disabled):hover {
  color: #b91c1c !important;
  border-color: #fecaca !important;
  background: #fef2f2 !important;
}

body[data-page="account"] .users-table-footer,
body:not(.auth-locked) .account-settings-page .users-table-footer {
  display: flex !important;
  min-height: 54px !important;
  align-items: center !important;
  padding: 0 18px !important;
  border-top: 1px solid #e5e7eb !important;
  color: #64748b !important;
  font-size: .82rem !important;
  font-weight: 700 !important;
}

@media (max-width: 1280px) {
  body[data-page="account"] .users-stat-grid,
  body:not(.auth-locked) .account-settings-page .users-stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  body[data-page="account"] .users-table-card,
  body:not(.auth-locked) .account-settings-page .users-table-card {
    overflow-x: auto !important;
  }

  body[data-page="account"] .users-table-head,
  body[data-page="account"] .users-table-row,
  body:not(.auth-locked) .account-settings-page .users-table-head,
  body:not(.auth-locked) .account-settings-page .users-table-row {
    min-width: 980px !important;
  }
}

@media (max-width: 720px) {
  body[data-page="account"] .users-stat-grid,
  body:not(.auth-locked) .account-settings-page .users-stat-grid {
    grid-template-columns: 1fr !important;
  }
}

/* v1.1.0 program settings card: open form layout, no accordion feel. */
body[data-page="settings"]:not(.auth-locked) #settingsPanel.settings-panel {
  padding: 28px 28px 92px !important;
  background: #f8fafc !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel > .panel-title {
  position: relative !important;
  display: flex !important;
  min-height: 108px !important;
  align-items: flex-start !important;
  margin: 0 0 22px !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel > .panel-title h2 {
  margin: 0 !important;
  color: #0f172a !important;
  font-size: 2.05rem !important;
  font-weight: 800 !important;
  line-height: 1.1 !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel > .panel-title p {
  margin: 10px 0 0 !important;
  color: #64748b !important;
  font-size: .96rem !important;
  font-weight: 500 !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel > .panel-title::after {
  content: "" !important;
  position: absolute !important;
  top: 2px !important;
  right: 22px !important;
  width: 190px !important;
  height: 86px !important;
  border-radius: 28px !important;
  background:
    radial-gradient(circle at 68% 52%, rgba(16, 185, 129, .95) 0 18px, transparent 19px),
    radial-gradient(circle at 68% 52%, transparent 0 31px, rgba(16, 185, 129, .28) 32px 42px, transparent 43px),
    linear-gradient(35deg, rgba(16, 185, 129, .18), rgba(187, 247, 208, .4)) !important;
  opacity: .74 !important;
  pointer-events: none !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel[data-active-setting="contractMessageSettingsBox"] > .panel-title::after {
  background:
    linear-gradient(#fff, #fff) 66% 46% / 54px 66px no-repeat,
    linear-gradient(90deg, rgba(148, 163, 184, .45) 0 34px, transparent 34px) 70% 35% / 54px 5px no-repeat,
    linear-gradient(90deg, rgba(148, 163, 184, .32) 0 42px, transparent 42px) 70% 47% / 54px 5px no-repeat,
    linear-gradient(90deg, rgba(148, 163, 184, .32) 0 36px, transparent 36px) 70% 59% / 54px 5px no-repeat,
    radial-gradient(circle at 82% 76%, #10b981 0 14px, transparent 15px),
    linear-gradient(35deg, rgba(16, 185, 129, .12), rgba(187, 247, 208, .42)) !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-sections {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-sections::before {
  content: none !important;
  display: none !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-box {
  display: none !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-box.is-active-setting {
  display: block !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox.program-settings-card.is-active-setting {
  display: block !important;
  width: 100% !important;
  margin: 0 !important;
  overflow: visible !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 18px !important;
  background: rgba(255, 255, 255, .98) !important;
  box-shadow: 0 18px 42px rgba(15, 23, 42, .07) !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox.program-settings-card > summary {
  display: grid !important;
  grid-template-columns: 54px minmax(0, 1fr) auto !important;
  gap: 16px !important;
  align-items: center !important;
  min-height: 106px !important;
  padding: 26px 28px !important;
  border-bottom: 1px solid #e5e7eb !important;
  cursor: default !important;
  list-style: none !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox.program-settings-card > summary::-webkit-details-marker {
  display: none !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox.program-settings-card > summary::after {
  content: "⌃" !important;
  color: #0f172a !important;
  font-size: 1.12rem !important;
  font-weight: 700 !important;
  transform: none !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox .settings-summary-icon {
  width: 54px !important;
  height: 54px !important;
  border-radius: 16px !important;
  color: #059669 !important;
  background: #dcfce7 !important;
  box-shadow: inset 0 0 0 1px #bbf7d0 !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox .settings-summary-copy {
  display: grid !important;
  gap: 6px !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox .settings-summary-copy strong {
  color: #0f172a !important;
  font-size: 1.08rem !important;
  font-weight: 800 !important;
  line-height: 1.2 !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox .settings-summary-copy small {
  color: #64748b !important;
  font-size: .9rem !important;
  font-weight: 600 !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox.program-settings-card > .program-settings-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 22px 28px !important;
  padding: 26px 28px 30px !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox label {
  display: grid !important;
  gap: 10px !important;
  margin: 0 !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox label > span {
  color: #0f172a !important;
  font-size: .9rem !important;
  font-weight: 700 !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox input,
body[data-page="settings"]:not(.auth-locked) #programSettingsBox textarea {
  width: 100% !important;
  min-height: 54px !important;
  padding: 12px 16px !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 12px !important;
  background: #fff !important;
  color: #0f172a !important;
  font-size: .96rem !important;
  font-weight: 600 !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, .04) !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox textarea {
  min-height: 118px !important;
  resize: vertical !important;
  line-height: 1.55 !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox .program-logo-row {
  display: flex !important;
  flex-wrap: wrap !important;
  align-items: center !important;
  gap: 14px !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox .program-logo-preview {
  width: 74px !important;
  height: 74px !important;
  flex: 0 0 74px !important;
  border: 1px solid #dbeafe !important;
  border-radius: 999px !important;
  background-size: cover !important;
  background-position: center !important;
  color: #059669 !important;
  font-size: .8rem !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox .logo-mini-button {
  min-width: 138px !important;
  min-height: 48px !important;
  justify-content: center !important;
  border-radius: 12px !important;
  font-size: .9rem !important;
  font-weight: 800 !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox label.logo-mini-button {
  border-color: #86efac !important;
  color: #059669 !important;
  background: #fff !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox #clearProgramLogo {
  border-color: #fecaca !important;
  color: #dc2626 !important;
  background: #fff !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox .field-help {
  display: block !important;
  margin: 4px 0 0 !important;
  color: #64748b !important;
  font-size: .82rem !important;
  font-weight: 500 !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox #programLogoName {
  color: #059669 !important;
  font-weight: 700 !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox.contract-settings-card {
  width: 100% !important;
  margin: 0 !important;
  overflow: visible !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 18px !important;
  background: rgba(255, 255, 255, .98) !important;
  box-shadow: 0 18px 42px rgba(15, 23, 42, .07) !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox.contract-settings-card > summary {
  display: grid !important;
  grid-template-columns: 54px minmax(0, 1fr) !important;
  gap: 16px !important;
  align-items: center !important;
  min-height: 104px !important;
  padding: 26px 28px !important;
  border-bottom: 1px solid #e5e7eb !important;
  cursor: default !important;
  list-style: none !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox.contract-settings-card > summary::-webkit-details-marker,
body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox.contract-settings-card > summary::after {
  content: none !important;
  display: none !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox .settings-summary-icon {
  width: 54px !important;
  height: 54px !important;
  border-radius: 16px !important;
  color: #059669 !important;
  background: #dcfce7 !important;
  box-shadow: inset 0 0 0 1px #bbf7d0 !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox .settings-summary-copy {
  display: grid !important;
  gap: 8px !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox .settings-summary-copy strong {
  color: #0f172a !important;
  font-size: 1.24rem !important;
  font-weight: 800 !important;
  line-height: 1.2 !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox .settings-summary-copy small {
  color: #64748b !important;
  font-size: .92rem !important;
  font-weight: 600 !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox .contract-settings-layout {
  display: grid !important;
  gap: 28px !important;
  padding: 28px !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox .contract-text-section {
  display: grid !important;
  gap: 12px !important;
  margin: 0 !important;
  padding: 0 !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox .contract-section-title {
  display: inline-flex !important;
  align-items: center !important;
  gap: 10px !important;
  color: #0f172a !important;
  font-size: .98rem !important;
  font-weight: 800 !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox .contract-section-title::before {
  content: "+" !important;
  display: inline-grid !important;
  width: 17px !important;
  height: 17px !important;
  place-items: center !important;
  border-radius: 999px !important;
  color: #fff !important;
  background: #10b981 !important;
  font-size: .8rem !important;
  font-weight: 800 !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox .contract-text-section > small:not(.contract-char-counter) {
  color: #64748b !important;
  font-size: .88rem !important;
  font-weight: 500 !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox textarea {
  width: 100% !important;
  min-height: 172px !important;
  padding: 20px 22px !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 14px !important;
  background: #fff !important;
  color: #0f172a !important;
  font-size: 1rem !important;
  font-weight: 650 !important;
  line-height: 1.55 !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, .04) !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox #settingContractFooter {
  min-height: 142px !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox .contract-token-row {
  display: flex !important;
  flex-wrap: wrap !important;
  align-items: center !important;
  gap: 10px !important;
  padding: 0 0 18px !important;
  border-bottom: 1px solid #e5e7eb !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox .contract-token-row > span {
  color: #64748b !important;
  font-size: .86rem !important;
  font-weight: 600 !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox [data-contract-token] {
  min-height: 34px !important;
  padding: 0 14px !important;
  border: 0 !important;
  border-radius: 10px !important;
  color: #059669 !important;
  background: #dcfce7 !important;
  font-size: .84rem !important;
  font-weight: 800 !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox .contract-copy-button {
  margin-left: auto !important;
  min-width: 96px !important;
  min-height: 38px !important;
  border-radius: 10px !important;
}

body[data-page="settings"]:not(.auth-locked) #contractMessageSettingsBox .contract-char-counter {
  justify-self: end !important;
  color: #64748b !important;
  font-size: .86rem !important;
  font-weight: 700 !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-footer {
  position: static !important;
  display: grid !important;
  grid-template-columns: auto minmax(0, 1fr) auto !important;
  align-items: center !important;
  gap: 16px !important;
  margin: 28px 0 0 !important;
  padding: 18px 22px !important;
  border: 1px solid #e5e7eb !important;
  border-radius: 14px !important;
  background: rgba(255, 255, 255, .98) !important;
  box-shadow: 0 18px 40px rgba(15, 23, 42, .07) !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-footer .secondary-button,
body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-footer .primary-button {
  min-width: 150px !important;
  min-height: 50px !important;
  border-radius: 12px !important;
  font-size: .96rem !important;
  font-weight: 800 !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-footer .primary-button {
  min-width: 240px !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel .save-status {
  justify-self: end !important;
}

@media (max-width: 900px) {
  body[data-page="settings"]:not(.auth-locked) #settingsPanel.settings-panel {
    padding: 20px 16px 86px !important;
  }

  body[data-page="settings"]:not(.auth-locked) #settingsPanel > .panel-title::after {
    display: none !important;
  }

  body[data-page="settings"]:not(.auth-locked) #programSettingsBox.program-settings-card > .program-settings-grid,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-footer {
    grid-template-columns: 1fr !important;
  }

  body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-footer .primary-button,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel .settings-footer .secondary-button {
    width: 100% !important;
  }
}

/* v1.1.0 payment reminder settings: bell card layout. */
body[data-page="settings"]:not(.auth-locked) #settingsPanel[data-active-setting="paymentReminderSettingsBox"] > .panel-title::after {
  background:
    radial-gradient(circle at 78% 69%, #fff 0 20px, #10b981 21px 27px, transparent 28px),
    radial-gradient(circle at 63% 48%, rgba(16, 185, 129, .98) 0 34px, transparent 35px),
    linear-gradient(180deg, rgba(16, 185, 129, .95), rgba(5, 150, 105, .9)) 49% 37% / 80px 72px no-repeat,
    radial-gradient(circle at 48% 29%, rgba(16, 185, 129, .9) 0 10px, transparent 11px),
    linear-gradient(35deg, rgba(16, 185, 129, .12), rgba(187, 247, 208, .42)) !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox.reminder-settings-card {
  width: 100% !important;
  margin: 0 !important;
  overflow: visible !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 18px !important;
  background: rgba(255, 255, 255, .98) !important;
  box-shadow: 0 18px 42px rgba(15, 23, 42, .07) !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox.reminder-settings-card > summary {
  display: grid !important;
  grid-template-columns: 54px minmax(0, 1fr) !important;
  gap: 16px !important;
  align-items: center !important;
  min-height: 104px !important;
  padding: 26px 28px !important;
  border-bottom: 1px solid #e5e7eb !important;
  cursor: default !important;
  list-style: none !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox.reminder-settings-card > summary::-webkit-details-marker,
body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox.reminder-settings-card > summary::after {
  content: none !important;
  display: none !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .settings-summary-icon {
  width: 54px !important;
  height: 54px !important;
  border-radius: 16px !important;
  color: #059669 !important;
  background: #dcfce7 !important;
  box-shadow: inset 0 0 0 1px #bbf7d0 !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .settings-summary-copy {
  display: grid !important;
  gap: 8px !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .settings-summary-copy strong {
  color: #0f172a !important;
  font-size: 1.24rem !important;
  font-weight: 800 !important;
  line-height: 1.2 !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .settings-summary-copy small {
  color: #64748b !important;
  font-size: .92rem !important;
  font-weight: 600 !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-settings-layout {
  display: grid !important;
  gap: 26px !important;
  padding: 28px !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-enable-row {
  display: grid !important;
  grid-template-columns: 68px minmax(0, 1fr) !important;
  gap: 18px !important;
  align-items: center !important;
  margin: 0 !important;
  cursor: pointer !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-enable-row input[type="checkbox"] {
  appearance: none !important;
  position: relative !important;
  display: block !important;
  width: 58px !important;
  height: 32px !important;
  min-width: 58px !important;
  min-height: 32px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 999px !important;
  background: #10b981 !important;
  box-shadow: inset 0 0 0 1px rgba(15, 118, 110, .08), 0 10px 18px rgba(16, 185, 129, .22) !important;
  cursor: pointer !important;
  transition: background-color .18s ease, box-shadow .18s ease !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-enable-row input[type="checkbox"]::before {
  content: "" !important;
  position: absolute !important;
  top: 4px !important;
  left: 30px !important;
  width: 24px !important;
  height: 24px !important;
  border-radius: 50% !important;
  background: #fff !important;
  box-shadow: 0 3px 8px rgba(15, 23, 42, .18) !important;
  transition: left .18s ease !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-enable-row input[type="checkbox"]:not(:checked) {
  background: #cbd5e1 !important;
  box-shadow: inset 0 0 0 1px rgba(100, 116, 139, .12) !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-enable-row input[type="checkbox"]:not(:checked)::before {
  left: 4px !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-enable-row div {
  display: grid !important;
  gap: 7px !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-enable-row span,
body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-line-card strong,
body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-field > span {
  color: #0f172a !important;
  font-size: 1rem !important;
  font-weight: 800 !important;
  line-height: 1.25 !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-enable-row small,
body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-line-card small,
body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-field small {
  color: #64748b !important;
  font-size: .88rem !important;
  font-weight: 500 !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-line-card {
  display: grid !important;
  grid-template-columns: 58px minmax(0, 1fr) !important;
  gap: 18px !important;
  align-items: center !important;
  padding: 24px 28px !important;
  border: 1px solid #bbf7d0 !important;
  border-radius: 14px !important;
  background: linear-gradient(180deg, #f0fdf4, #f8fffb) !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .line-app-badge {
  display: grid !important;
  width: 54px !important;
  height: 54px !important;
  place-items: center !important;
  border-radius: 12px !important;
  overflow: hidden !important;
  background: #06c755 !important;
  box-shadow: 0 10px 20px rgba(6, 199, 85, .18) !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .line-app-badge svg {
  display: block !important;
  width: 54px !important;
  height: 54px !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-field-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 26px !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-field {
  display: grid !important;
  gap: 12px !important;
  margin: 0 !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-field input,
body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-field select {
  width: 100% !important;
  min-height: 58px !important;
  padding: 0 18px !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 12px !important;
  background: #fff !important;
  color: #0f172a !important;
  font-size: 1rem !important;
  font-weight: 750 !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, .04) !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-warning-note {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  min-height: 54px !important;
  padding: 0 20px !important;
  border: 1px solid #fde68a !important;
  border-radius: 12px !important;
  color: #92400e !important;
  background: #fffbeb !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-warning-note span {
  display: grid !important;
  width: 24px !important;
  height: 24px !important;
  place-items: center !important;
  border: 2px solid #f59e0b !important;
  border-radius: 999px !important;
  color: #f59e0b !important;
  font-size: .82rem !important;
  font-weight: 900 !important;
}

body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-warning-note strong {
  font-size: .92rem !important;
  font-weight: 800 !important;
}

@media (max-width: 900px) {
  body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-field-grid,
  body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-line-card,
  body[data-page="settings"]:not(.auth-locked) #paymentReminderSettingsBox .reminder-enable-row {
    grid-template-columns: 1fr !important;
  }
}

/* v1.1.0 bank and backup settings: production card layouts. */
body[data-page="settings"]:not(.auth-locked) #settingsPanel[data-active-setting="bankSettingsBox"] > .panel-title::after {
  background:
    linear-gradient(180deg, rgba(16, 185, 129, .9), rgba(5, 150, 105, .88)) 58% 62% / 76px 42px no-repeat,
    linear-gradient(90deg, rgba(255,255,255,.75) 0 20px, transparent 20px) 48% 62% / 52px 4px no-repeat,
    linear-gradient(90deg, rgba(255,255,255,.55) 0 28px, transparent 28px) 48% 74% / 52px 4px no-repeat,
    radial-gradient(circle at 82% 62%, #fff 0 18px, transparent 19px),
    radial-gradient(circle at 82% 62%, transparent 0 29px, rgba(16, 185, 129, .72) 30px 40px, transparent 41px),
    linear-gradient(180deg, rgba(20, 184, 166, .32), rgba(187, 247, 208, .38)) 72% 32% / 82px 58px no-repeat,
    linear-gradient(35deg, rgba(16, 185, 129, .12), rgba(187, 247, 208, .42)) !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel[data-active-setting="backupSettingsBox"] > .panel-title::after {
  background:
    radial-gradient(circle at 74% 44%, rgba(187, 247, 208, .92) 0 34px, transparent 35px),
    radial-gradient(circle at 84% 58%, transparent 0 26px, rgba(16, 185, 129, .78) 27px 38px, transparent 39px),
    linear-gradient(180deg, rgba(16, 185, 129, .42), rgba(255,255,255,.1)) 42% 66% / 58px 34px no-repeat,
    linear-gradient(35deg, rgba(16, 185, 129, .10), rgba(187, 247, 208, .42)) !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox.bank-settings-card,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox.backup-settings-card {
  width: 100% !important;
  margin: 0 !important;
  overflow: visible !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 18px !important;
  background: rgba(255, 255, 255, .98) !important;
  box-shadow: 0 18px 42px rgba(15, 23, 42, .07) !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox.bank-settings-card > summary,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox.backup-settings-card > summary {
  display: grid !important;
  grid-template-columns: 54px minmax(0, 1fr) auto !important;
  gap: 16px !important;
  align-items: center !important;
  min-height: 106px !important;
  padding: 26px 28px !important;
  border-bottom: 1px solid #e5e7eb !important;
  cursor: default !important;
  list-style: none !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox.bank-settings-card > summary::-webkit-details-marker,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox.backup-settings-card > summary::-webkit-details-marker {
  display: none !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox.bank-settings-card > summary::after,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox.backup-settings-card > summary::after {
  content: "⌃" !important;
  color: #0f172a !important;
  font-size: 1.12rem !important;
  font-weight: 800 !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .settings-summary-icon,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .settings-summary-icon {
  width: 54px !important;
  height: 54px !important;
  border-radius: 16px !important;
  color: #059669 !important;
  background: #dcfce7 !important;
  box-shadow: inset 0 0 0 1px #bbf7d0 !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .settings-summary-copy,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .settings-summary-copy {
  display: grid !important;
  gap: 6px !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .settings-summary-copy strong,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .settings-summary-copy strong {
  color: #0f172a !important;
  font-size: 1.08rem !important;
  font-weight: 800 !important;
  line-height: 1.2 !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .settings-summary-copy small,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .settings-summary-copy small {
  color: #64748b !important;
  font-size: .9rem !important;
  font-weight: 600 !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-settings-layout,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-settings-layout {
  display: grid !important;
  gap: 26px !important;
  padding: 28px !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-field-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 26px 32px !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-field {
  display: grid !important;
  gap: 12px !important;
  margin: 0 !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-field > span,
body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-upload-title {
  display: inline-flex !important;
  align-items: center !important;
  gap: 10px !important;
  color: #0f172a !important;
  font-size: .94rem !important;
  font-weight: 800 !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-field > span::before,
body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-upload-title::before {
  display: inline-grid !important;
  width: 22px !important;
  height: 22px !important;
  place-items: center !important;
  border-radius: 8px !important;
  color: #059669 !important;
  background: #dcfce7 !important;
  font-size: .92rem !important;
  font-weight: 900 !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-field-account > span::before { content: "♙" !important; }
body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-field-bank > span::before { content: "▥" !important; }
body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-field-number > span::before { content: "#" !important; }
body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-field-promptpay > span::before { content: "▦" !important; }
body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-upload-title::before { content: "QR" !important; font-size: .7rem !important; }

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox input,
body[data-page="settings"]:not(.auth-locked) #bankSettingsBox select {
  width: 100% !important;
  min-height: 54px !important;
  padding: 12px 16px !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 12px !important;
  background: #fff !important;
  color: #0f172a !important;
  font-size: .96rem !important;
  font-weight: 650 !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, .04) !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox select {
  appearance: auto !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .field-help {
  display: block !important;
  margin: 2px 0 0 !important;
  color: #64748b !important;
  font-size: .84rem !important;
  font-weight: 550 !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-upload-section {
  display: grid !important;
  gap: 12px !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-upload-drop {
  display: grid !important;
  grid-template-columns: 64px minmax(0, 1fr) auto !important;
  gap: 18px !important;
  align-items: center !important;
  min-height: 112px !important;
  margin: 0 !important;
  padding: 20px 28px !important;
  border: 1.5px dashed #cbd5e1 !important;
  border-radius: 14px !important;
  background: #fff !important;
  cursor: pointer !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-upload-icon,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-upload-icon {
  display: grid !important;
  width: 56px !important;
  height: 56px !important;
  place-items: center !important;
  border-radius: 16px !important;
  color: #10b981 !important;
  background: #dcfce7 !important;
  font-size: 1.7rem !important;
  font-weight: 900 !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-upload-copy {
  display: grid !important;
  gap: 6px !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-upload-copy strong {
  color: #0f172a !important;
  font-size: 1.02rem !important;
  font-weight: 800 !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-upload-copy small {
  color: #64748b !important;
  font-size: .88rem !important;
  font-weight: 600 !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-file-button,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-file-button {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-width: 126px !important;
  min-height: 44px !important;
  padding: 0 18px !important;
  border: 1px solid #86efac !important;
  border-radius: 11px !important;
  color: #059669 !important;
  background: #fff !important;
  font-size: .92rem !important;
  font-weight: 800 !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox #settingBankQr,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-file-input {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

body[data-page="settings"]:not(.auth-locked) #bankSettingsBox #settingBankQrName {
  color: #64748b !important;
  font-size: .9rem !important;
  font-weight: 700 !important;
}

body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-actions {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 18px !important;
}

body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-action-button {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 12px !important;
  min-height: 54px !important;
  margin: 0 !important;
  border-radius: 12px !important;
  font-size: .94rem !important;
  font-weight: 800 !important;
  cursor: pointer !important;
}

body[data-page="settings"]:not(.auth-locked) #backupSettingsBox #importBackup {
  border-color: #34d399 !important;
  color: #059669 !important;
  background: #f0fdf4 !important;
  box-shadow: inset 0 0 0 1px rgba(16, 185, 129, .22) !important;
}

body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-restore-info {
  display: grid !important;
  grid-template-columns: 26px minmax(0, 1fr) !important;
  gap: 16px !important;
  align-items: center !important;
  padding: 18px 22px !important;
  border: 1px solid #bbf7d0 !important;
  border-radius: 14px !important;
  background: linear-gradient(180deg, #f0fdf4, #f8fffb) !important;
}

body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-restore-info > span,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-note > span {
  display: grid !important;
  width: 22px !important;
  height: 22px !important;
  place-items: center !important;
  border-radius: 999px !important;
  color: #fff !important;
  background: #10b981 !important;
  font-size: .84rem !important;
  font-weight: 900 !important;
}

body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-restore-info strong {
  display: block !important;
  color: #0f172a !important;
  font-size: .96rem !important;
  font-weight: 800 !important;
}

body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-restore-info small {
  display: block !important;
  margin-top: 4px !important;
  color: #64748b !important;
  font-size: .88rem !important;
  font-weight: 600 !important;
}

body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-upload-drop {
  display: grid !important;
  justify-items: center !important;
  gap: 10px !important;
  min-height: 250px !important;
  margin: 0 !important;
  padding: 34px !important;
  border: 1.5px dashed #cbd5e1 !important;
  border-radius: 14px !important;
  background: #fff !important;
  text-align: center !important;
  cursor: pointer !important;
}

body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-upload-drop strong {
  color: #0f172a !important;
  font-size: 1.02rem !important;
  font-weight: 800 !important;
}

body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-upload-drop small,
body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-upload-drop em {
  color: #64748b !important;
  font-size: .88rem !important;
  font-style: normal !important;
  font-weight: 600 !important;
}

body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-note {
  display: inline-grid !important;
  grid-template-columns: 22px minmax(0, 1fr) !important;
  gap: 12px !important;
  align-items: center !important;
  margin: 0 !important;
  color: #64748b !important;
  font-size: .9rem !important;
  font-weight: 600 !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel[data-active-setting="bankSettingsBox"] .settings-footer,
body[data-page="settings"]:not(.auth-locked) #settingsPanel[data-active-setting="backupSettingsBox"] .settings-footer {
  grid-template-columns: 180px minmax(0, 1fr) !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel[data-active-setting="bankSettingsBox"] .settings-footer .save-status,
body[data-page="settings"]:not(.auth-locked) #settingsPanel[data-active-setting="backupSettingsBox"] .settings-footer .save-status {
  display: none !important;
}

body[data-page="settings"]:not(.auth-locked) #settingsPanel[data-active-setting="bankSettingsBox"] .settings-footer .primary-button,
body[data-page="settings"]:not(.auth-locked) #settingsPanel[data-active-setting="backupSettingsBox"] .settings-footer .primary-button {
  width: 100% !important;
  min-width: 0 !important;
}

@media (max-width: 900px) {
  body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-field-grid,
  body[data-page="settings"]:not(.auth-locked) #bankSettingsBox .bank-upload-drop,
  body[data-page="settings"]:not(.auth-locked) #backupSettingsBox .backup-actions,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel[data-active-setting="bankSettingsBox"] .settings-footer,
  body[data-page="settings"]:not(.auth-locked) #settingsPanel[data-active-setting="backupSettingsBox"] .settings-footer {
    grid-template-columns: 1fr !important;
  }
}

/* v1.1.0 dashboard top controls and contract credit panel. */
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel.dashboard-page {
  gap: 18px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row {
  order: 1 !important;
  display: grid !important;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, .52fr) minmax(240px, .4fr) !important;
  gap: 16px !important;
  align-items: stretch !important;
  width: 100% !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filter-panel,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-credit-panel {
  display: grid !important;
  min-height: 142px !important;
  margin: 0 !important;
  padding: 24px 28px !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 18px !important;
  background: rgba(255, 255, 255, .98) !important;
  box-shadow: 0 18px 42px rgba(15, 23, 42, .07) !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero {
  order: 0 !important;
  align-content: center !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero > div:first-child {
  display: grid !important;
  gap: 8px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2 {
  margin: 0 !important;
  color: #0f172a !important;
  font-size: clamp(2rem, 3vw, 3.2rem) !important;
  font-weight: 850 !important;
  line-height: 1.05 !important;
  letter-spacing: 0 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero .eyebrow {
  color: #047857 !important;
  font-size: .92rem !important;
  font-weight: 850 !important;
  letter-spacing: 0 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardFilterHint {
  color: #64748b !important;
  font-size: .96rem !important;
  font-weight: 650 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 10px !important;
  margin-top: 8px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filter-panel,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-credit-panel {
  align-content: start !important;
  gap: 16px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-panel-heading {
  display: inline-flex !important;
  align-items: center !important;
  gap: 10px !important;
  color: #64748b !important;
  font-size: .95rem !important;
  font-weight: 850 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-panel-heading span {
  display: inline-grid !important;
  width: 34px !important;
  height: 34px !important;
  place-items: center !important;
  border-radius: 10px !important;
  color: #059669 !important;
  background: #dcfce7 !important;
  font-size: 1rem !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters {
  display: grid !important;
  grid-template-columns: 1fr !important;
  gap: 12px !important;
  align-items: start !important;
  max-width: none !important;
  text-align: left !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters label,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters label:first-child {
  display: grid !important;
  width: 100% !important;
  min-width: 0 !important;
  max-width: none !important;
  gap: 7px !important;
  margin: 0 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters span {
  margin: 0 !important;
  color: #64748b !important;
  font-size: .84rem !important;
  font-weight: 800 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters select,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters input {
  width: 100% !important;
  min-height: 46px !important;
  margin: 0 !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 13px !important;
  background: #fff !important;
  color: #0f172a !important;
  font-size: .94rem !important;
  font-weight: 750 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-credit-panel {
  position: relative !important;
  overflow: hidden !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-credit-panel::after {
  content: "" !important;
  position: absolute !important;
  right: -28px !important;
  bottom: -30px !important;
  width: 118px !important;
  height: 118px !important;
  border-radius: 999px !important;
  background: radial-gradient(circle, rgba(16, 185, 129, .18), transparent 66%) !important;
  pointer-events: none !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardContractCreditBalance {
  color: #0f172a !important;
  font-size: clamp(2.2rem, 3.4vw, 3.5rem) !important;
  font-weight: 900 !important;
  line-height: 1 !important;
  letter-spacing: 0 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardContractCreditStatus {
  color: #059669 !important;
  font-size: .96rem !important;
  font-weight: 850 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardContractCreditUsed {
  margin: 0 !important;
  color: #64748b !important;
  font-size: .88rem !important;
  font-weight: 700 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-menu-section {
  order: 2 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-panel {
  order: 3 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid {
  order: 4 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-analytics-grid {
  order: 5 !important;
}

@media (max-width: 1200px) {
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row {
    grid-template-columns: minmax(0, 1fr) minmax(260px, .72fr) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-credit-panel {
    grid-column: 1 / -1 !important;
  }
}

@media (max-width: 760px) {
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row {
    grid-template-columns: 1fr !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filter-panel,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-credit-panel {
    min-height: 0 !important;
    padding: 20px !important;
  }
}

#dashboardPanel .dashboard-top-row {
  order: 1 !important;
  display: grid !important;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, .52fr) minmax(240px, .4fr) !important;
  gap: 16px !important;
  align-items: stretch !important;
  width: 100% !important;
}

#dashboardPanel .dashboard-top-row .dashboard-hero,
#dashboardPanel .dashboard-top-row .dashboard-filter-panel,
#dashboardPanel .dashboard-top-row .dashboard-credit-panel {
  display: grid !important;
  min-height: 142px !important;
  margin: 0 !important;
  padding: 24px 28px !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 18px !important;
  background: rgba(255, 255, 255, .98) !important;
  box-shadow: 0 18px 42px rgba(15, 23, 42, .07) !important;
}

#dashboardPanel .dashboard-top-row .dashboard-hero > div:first-child {
  display: grid !important;
  gap: 8px !important;
}

#dashboardPanel .dashboard-top-row .dashboard-hero h2 {
  display: block !important;
  margin: 0 !important;
  color: #0f172a !important;
  font-size: clamp(2rem, 3vw, 3.2rem) !important;
  font-weight: 850 !important;
  line-height: 1.05 !important;
}

@media (max-width: 1200px) {
  #dashboardPanel .dashboard-top-row {
    grid-template-columns: minmax(0, 1fr) minmax(260px, .72fr) !important;
  }

  #dashboardPanel .dashboard-top-row .dashboard-credit-panel {
    grid-column: 1 / -1 !important;
  }
}

@media (max-width: 760px) {
  #dashboardPanel .dashboard-top-row {
    grid-template-columns: 1fr !important;
  }
}

/* v1.1.0-dashboard-credit3: move contract credit into the dashboard summary card group. */
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row,
#dashboardPanel .dashboard-top-row {
  grid-template-columns: minmax(0, 1fr) minmax(300px, .38fr) !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .summary-grid .dashboard-credit-summary-tile,
#dashboardPanel .summary-grid .dashboard-credit-summary-tile {
  position: relative !important;
  display: flex !important;
  min-height: var(--dashboard-card-height, 128px) !important;
  padding: 24px 26px !important;
  overflow: hidden !important;
  background: linear-gradient(145deg, #ffffff 0%, #ffffff 70%, rgba(236, 253, 245, .72) 100%) !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .summary-grid .dashboard-credit-summary-tile::after,
#dashboardPanel .summary-grid .dashboard-credit-summary-tile::after {
  content: "" !important;
  position: absolute !important;
  right: -26px !important;
  bottom: -34px !important;
  width: 118px !important;
  height: 118px !important;
  border-radius: 999px !important;
  background: radial-gradient(circle, rgba(16, 185, 129, .16), transparent 66%) !important;
  pointer-events: none !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .summary-grid .dashboard-credit-summary-tile span,
#dashboardPanel .summary-grid .dashboard-credit-summary-tile span {
  color: #64748b !important;
  font-size: clamp(.98rem, 1.1vw, 1.12rem) !important;
  font-weight: 850 !important;
  letter-spacing: 0 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .summary-grid #dashboardContractCreditBalance,
#dashboardPanel .summary-grid #dashboardContractCreditBalance {
  color: #0f172a !important;
  font-size: clamp(2.35rem, 3.7vw, 4rem) !important;
  font-weight: 900 !important;
  line-height: .98 !important;
  letter-spacing: 0 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .summary-grid #dashboardContractCreditStatus,
#dashboardPanel .summary-grid #dashboardContractCreditStatus {
  color: #059669 !important;
  font-size: clamp(.96rem, 1vw, 1.06rem) !important;
  font-weight: 850 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .summary-grid #dashboardContractCreditUsed,
#dashboardPanel .summary-grid #dashboardContractCreditUsed {
  margin-top: 2px !important;
  color: #64748b !important;
  font-size: clamp(.88rem, .95vw, .98rem) !important;
  font-weight: 750 !important;
}

@media (max-width: 1200px) {
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row,
  #dashboardPanel .dashboard-top-row {
    grid-template-columns: minmax(0, 1fr) !important;
  }
}

/* v1.1.0-dashboard-compact: keep the dashboard header compact and restore hidden filter fields. */
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel.dashboard-page,
#dashboardPanel.dashboard-page {
  gap: 16px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row,
#dashboardPanel .dashboard-top-row {
  grid-template-columns: minmax(0, 1.9fr) minmax(300px, .68fr) !important;
  gap: 14px !important;
  align-items: start !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-hero,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-filter-panel,
#dashboardPanel .dashboard-top-row .dashboard-hero,
#dashboardPanel .dashboard-top-row .dashboard-filter-panel {
  min-height: 0 !important;
  padding: 22px 26px !important;
  border-radius: 18px !important;
  box-shadow: 0 14px 32px rgba(15, 23, 42, .055) !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-hero,
#dashboardPanel .dashboard-top-row .dashboard-hero {
  align-content: center !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-hero > div:first-child,
#dashboardPanel .dashboard-top-row .dashboard-hero > div:first-child {
  gap: 8px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-hero h2,
#dashboardPanel .dashboard-top-row .dashboard-hero h2 {
  font-size: clamp(2.1rem, 2.6vw, 2.75rem) !important;
  line-height: 1.04 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row #dashboardFilterHint,
#dashboardPanel .dashboard-top-row #dashboardFilterHint {
  max-width: 560px !important;
  font-size: .9rem !important;
  line-height: 1.35 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions,
#dashboardPanel .dashboard-quick-actions {
  gap: 8px !important;
  margin-top: 6px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions .primary-button,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions .secondary-button,
#dashboardPanel .dashboard-quick-actions .primary-button,
#dashboardPanel .dashboard-quick-actions .secondary-button {
  min-height: 40px !important;
  padding: 9px 14px !important;
  border-radius: 13px !important;
  font-size: .9rem !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filter-panel,
#dashboardPanel .dashboard-filter-panel {
  gap: 12px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filter-panel .dashboard-panel-heading,
#dashboardPanel .dashboard-filter-panel .dashboard-panel-heading {
  font-size: .92rem !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filter-panel .dashboard-panel-heading span,
#dashboardPanel .dashboard-filter-panel .dashboard-panel-heading span {
  width: 32px !important;
  height: 32px !important;
  border-radius: 10px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters,
#dashboardPanel .dashboard-filters {
  gap: 10px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters .dashboard-period-field.hidden,
#dashboardPanel .dashboard-filters .dashboard-period-field.hidden,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters label.hidden,
#dashboardPanel .dashboard-filters label.hidden {
  display: none !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters select,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters input,
#dashboardPanel .dashboard-filters select,
#dashboardPanel .dashboard-filters input {
  min-height: 42px !important;
  border-radius: 12px !important;
  font-size: .9rem !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid,
#dashboardPanel > .summary-grid {
  margin-top: 0 !important;
}

@media (max-width: 980px) {
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row,
  #dashboardPanel .dashboard-top-row {
    grid-template-columns: 1fr !important;
  }
}

/* v1.1.0-dashboard-logo-scale: align credit card scale and fit the app logo. */
body:not(.auth-locked) .quick-nav .side-brand .side-program-logo,
body[data-page] .quick-nav .side-brand .side-program-logo,
body[data-page="account"] .side-brand .side-program-logo,
body[data-page="settings"] .side-brand .side-program-logo {
  width: 42px !important;
  height: 42px !important;
  min-width: 42px !important;
  flex: 0 0 42px !important;
  border-radius: 14px !important;
  background-color: #ecfdf5 !important;
  background-size: contain !important;
  background-position: center !important;
  background-repeat: no-repeat !important;
  box-shadow: 0 10px 24px rgba(16, 185, 129, .15) !important;
}

body.nav-collapsed:not(.auth-locked) .quick-nav .side-brand .side-program-logo,
body[data-page].nav-collapsed .quick-nav .side-brand .side-program-logo {
  width: 38px !important;
  height: 38px !important;
  min-width: 38px !important;
  border-radius: 13px !important;
}

body[data-page="settings"]:not(.auth-locked) #programSettingsBox .program-logo-preview {
  border-radius: 18px !important;
  background-color: #ecfdf5 !important;
  background-size: contain !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .dashboard-credit-summary-tile,
#dashboardPanel > .summary-grid .dashboard-credit-summary-tile {
  display: grid !important;
  align-content: center !important;
  gap: 6px !important;
  min-height: 108px !important;
  padding: 16px 18px !important;
  border-radius: 16px !important;
  box-shadow: none !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .dashboard-credit-summary-tile span,
#dashboardPanel > .summary-grid .dashboard-credit-summary-tile span {
  font-size: .9rem !important;
  font-weight: 850 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid #dashboardContractCreditBalance,
#dashboardPanel > .summary-grid #dashboardContractCreditBalance {
  font-size: clamp(1.45rem, 2vw, 2rem) !important;
  line-height: 1 !important;
  font-weight: 900 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid #dashboardContractCreditStatus,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid #dashboardContractCreditUsed,
#dashboardPanel > .summary-grid #dashboardContractCreditStatus,
#dashboardPanel > .summary-grid #dashboardContractCreditUsed {
  display: block !important;
  max-width: 100% !important;
  margin: 0 !important;
  overflow: hidden !important;
  color: #64748b !important;
  font-size: .85rem !important;
  font-weight: 800 !important;
  line-height: 1.18 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid #dashboardContractCreditStatus,
#dashboardPanel > .summary-grid #dashboardContractCreditStatus {
  color: #059669 !important;
}

/* v1.1.0-dashboard-rich: dashboard visual pass with icons, balanced buttons, and fixed logo. */
body:not(.auth-locked) .quick-nav .side-brand .side-program-logo,
body[data-page] .quick-nav .side-brand .side-program-logo,
.quick-nav .side-brand .side-program-logo {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  background-image: url("assets/loan-system-logo.png") !important;
  background-size: contain !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
  background-color: #ecfdf5 !important;
}

body[data-page="dashboard"]:not(.auth-locked) .app-topbar,
body[data-page="dashboard"]:not(.auth-locked) .topbar {
  min-height: 86px !important;
  padding: 22px 28px !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 20px !important;
  background: rgba(255, 255, 255, .98) !important;
  box-shadow: 0 18px 44px rgba(15, 23, 42, .07) !important;
}

body[data-page="dashboard"]:not(.auth-locked) .global-search,
body[data-page="dashboard"]:not(.auth-locked) .search-box {
  position: relative !important;
  max-width: 520px !important;
}

body[data-page="dashboard"]:not(.auth-locked) .global-search::before,
body[data-page="dashboard"]:not(.auth-locked) .search-box::before {
  content: "⌕" !important;
  position: absolute !important;
  left: 22px !important;
  top: 50% !important;
  z-index: 1 !important;
  transform: translateY(-50%) !important;
  color: #64748b !important;
  font-size: 1.45rem !important;
  line-height: 1 !important;
}

body[data-page="dashboard"]:not(.auth-locked) .global-search input,
body[data-page="dashboard"]:not(.auth-locked) .search-box input {
  min-height: 50px !important;
  padding-left: 58px !important;
  border: 1px solid #dbe3ef !important;
  border-radius: 999px !important;
  background: #fbfcff !important;
  font-size: .98rem !important;
  font-weight: 750 !important;
}

body[data-page="dashboard"]:not(.auth-locked) .notification-button {
  display: none !important;
}

body[data-page="dashboard"]:not(.auth-locked) .topbar-user {
  display: inline-flex !important;
  align-items: center !important;
  gap: 12px !important;
  min-height: 50px !important;
  padding: 8px 18px 8px 10px !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 999px !important;
  background: #fff !important;
  color: #0f172a !important;
  font-size: .98rem !important;
  font-weight: 850 !important;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .045) !important;
}

body[data-page="dashboard"]:not(.auth-locked) .topbar-user::before {
  content: "" !important;
  width: 38px !important;
  height: 38px !important;
  border-radius: 999px !important;
  background: #dcfce7 !important;
  box-shadow: inset 0 0 0 12px rgba(16, 185, 129, .06) !important;
}

body[data-page="dashboard"]:not(.auth-locked) .topbar-user::after {
  content: "⌄" !important;
  color: #64748b !important;
  font-size: 1rem !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-menu-section,
#dashboardPanel .dashboard-menu-section {
  display: none !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row,
#dashboardPanel .dashboard-top-row {
  grid-template-columns: minmax(0, 1.9fr) minmax(320px, .85fr) !important;
  gap: 18px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-hero,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-filter-panel,
#dashboardPanel .dashboard-top-row .dashboard-hero,
#dashboardPanel .dashboard-top-row .dashboard-filter-panel {
  min-height: 166px !important;
  padding: 28px 32px !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 18px !important;
  box-shadow: 0 18px 42px rgba(15, 23, 42, .06) !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-hero h2,
#dashboardPanel .dashboard-top-row .dashboard-hero h2 {
  font-size: clamp(2.25rem, 3.2vw, 3.45rem) !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row #dashboardFilterHint,
#dashboardPanel .dashboard-top-row #dashboardFilterHint {
  display: none !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions,
#dashboardPanel .dashboard-quick-actions {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 14px !important;
  margin-top: 22px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions .primary-button,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions .secondary-button,
#dashboardPanel .dashboard-quick-actions .primary-button,
#dashboardPanel .dashboard-quick-actions .secondary-button {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px !important;
  min-height: 52px !important;
  padding: 12px 22px !important;
  border-radius: 12px !important;
  font-size: .98rem !important;
  font-weight: 850 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions .primary-button,
#dashboardPanel .dashboard-quick-actions .primary-button {
  border-color: #059669 !important;
  background: linear-gradient(180deg, #10b981, #059669) !important;
  color: #fff !important;
  box-shadow: 0 16px 28px rgba(5, 150, 105, .22) !important;
}

.dashboard-button-icon {
  display: inline-grid !important;
  width: 24px !important;
  height: 24px !important;
  place-items: center !important;
  flex: 0 0 24px !important;
  border-radius: 8px !important;
  background: rgba(15, 23, 42, .06) !important;
  color: currentColor !important;
  font-size: .75rem !important;
  font-weight: 900 !important;
}

.primary-button .dashboard-button-icon {
  background: rgba(255, 255, 255, .18) !important;
}

.wallet-icon::before { content: "▣" !important; }
.plus-icon::before { content: "+" !important; font-size: 1.2rem !important; }
.line-icon {
  border-radius: 999px !important;
  background: #06c755 !important;
  color: #fff !important;
  font-size: .48rem !important;
  letter-spacing: -.02em !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filter-panel .dashboard-panel-heading span,
#dashboardPanel .dashboard-filter-panel .dashboard-panel-heading span {
  width: 40px !important;
  height: 40px !important;
  border-radius: 11px !important;
  background: #dcfce7 !important;
  color: #059669 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filter-panel .dashboard-panel-heading strong,
#dashboardPanel .dashboard-filter-panel .dashboard-panel-heading strong {
  color: #64748b !important;
  font-size: 1.05rem !important;
  font-weight: 850 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters select,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters input,
#dashboardPanel .dashboard-filters select,
#dashboardPanel .dashboard-filters input {
  min-height: 52px !important;
  padding-inline: 18px !important;
  border-radius: 13px !important;
  font-size: 1rem !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-panel,
#dashboardPanel .dashboard-work-panel {
  position: relative !important;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto auto !important;
  align-items: center !important;
  min-height: 140px !important;
  overflow: hidden !important;
  border: 1px solid #a7f3d0 !important;
  border-radius: 18px !important;
  background:
    radial-gradient(circle at 34% 75%, rgba(209, 250, 229, .92), transparent 22%),
    linear-gradient(135deg, #f0fdf4 0%, #ffffff 54%, #ecfdf5 100%) !important;
  box-shadow: 0 18px 44px rgba(15, 23, 42, .06) !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-kicker,
#dashboardPanel .dashboard-work-kicker {
  display: inline-flex !important;
  width: fit-content !important;
  padding: 6px 14px !important;
  border-radius: 999px !important;
  background: #dcfce7 !important;
  color: #047857 !important;
  font-size: .86rem !important;
  font-weight: 850 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-panel strong,
#dashboardPanel .dashboard-work-panel strong {
  margin-top: 12px !important;
  color: #0f172a !important;
  font-size: clamp(2.1rem, 3vw, 3rem) !important;
  line-height: 1.05 !important;
  font-weight: 900 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-art,
#dashboardPanel .dashboard-work-art {
  position: relative !important;
  width: 200px !important;
  height: 112px !important;
  margin-inline: 28px 34px !important;
}

.work-art-calendar {
  position: absolute !important;
  right: 26px !important;
  top: 10px !important;
  width: 92px !important;
  height: 86px !important;
  border-radius: 12px !important;
  background: linear-gradient(#10b981 0 28%, #fff 28% 100%) !important;
  box-shadow: 0 22px 30px rgba(15, 23, 42, .16) !important;
  transform: rotate(4deg) !important;
}

.work-art-calendar::before {
  content: "" !important;
  position: absolute !important;
  left: 22px !important;
  top: 44px !important;
  width: 12px !important;
  height: 12px !important;
  border-radius: 3px !important;
  background: #e2e8f0 !important;
  box-shadow: 24px 0 #e2e8f0, 48px 0 #e2e8f0, 0 22px #ef4444, 24px 22px #e2e8f0, 48px 22px #e2e8f0 !important;
}

.work-art-bell {
  position: absolute !important;
  right: 0 !important;
  bottom: 14px !important;
  width: 48px !important;
  height: 48px !important;
  border-radius: 50% 50% 46% 46% !important;
  background: linear-gradient(135deg, #fbbf24, #f59e0b) !important;
  box-shadow: 0 16px 26px rgba(245, 158, 11, .25) !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-panel .primary-button,
#dashboardPanel .dashboard-work-panel .primary-button {
  min-height: 52px !important;
  padding-inline: 22px !important;
  border-radius: 10px !important;
  background: linear-gradient(180deg, #10b981, #059669) !important;
  box-shadow: 0 16px 28px rgba(5, 150, 105, .22) !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid,
#dashboardPanel > .summary-grid {
  gap: 16px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile,
#dashboardPanel > .summary-grid .summary-tile {
  position: relative !important;
  display: grid !important;
  grid-template-columns: 52px minmax(0, 1fr) !important;
  grid-template-rows: auto auto auto !important;
  column-gap: 14px !important;
  align-content: center !important;
  min-height: 132px !important;
  padding: 22px 24px !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 18px !important;
  background: #fff !important;
  box-shadow: 0 16px 36px rgba(15, 23, 42, .055) !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .summary-tile-icon,
#dashboardPanel .summary-tile-icon {
  grid-row: 1 / span 3 !important;
  display: inline-grid !important;
  width: 52px !important;
  height: 52px !important;
  place-items: center !important;
  align-self: start !important;
  border-radius: 999px !important;
  background: #dcfce7 !important;
  color: #10b981 !important;
  font-size: 1.55rem !important;
  font-weight: 900 !important;
}

.dashboard-tile-principal .summary-tile-icon::before { content: "▣" !important; }
.dashboard-tile-received .summary-tile-icon::before { content: "↓" !important; }
.dashboard-tile-due .summary-tile-icon::before { content: "!" !important; }
.dashboard-tile-contracts .summary-tile-icon::before { content: "▤" !important; }
.dashboard-tile-interest .summary-tile-icon::before { content: "%" !important; }
.dashboard-tile-profit .summary-tile-icon::before { content: "✓" !important; }
.dashboard-tile-outstanding .summary-tile-icon::before { content: "◔" !important; }
.dashboard-credit-summary-tile .summary-tile-icon::before { content: "★" !important; }

.dashboard-tile-due .summary-tile-icon {
  background: #fee2e2 !important;
  color: #ef4444 !important;
}

.dashboard-tile-contracts .summary-tile-icon {
  background: #dbeafe !important;
  color: #3b82f6 !important;
}

.dashboard-tile-interest .summary-tile-icon {
  background: #dbeafe !important;
  color: #2563eb !important;
}

.dashboard-tile-outstanding .summary-tile-icon {
  background: #f3e8ff !important;
  color: #a855f7 !important;
}

.dashboard-credit-summary-tile .summary-tile-icon {
  background: #ffedd5 !important;
  color: #f59e0b !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon),
#dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon) {
  color: #64748b !important;
  font-size: .94rem !important;
  font-weight: 850 !important;
  line-height: 1.2 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile strong,
#dashboardPanel > .summary-grid .summary-tile strong,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid #dashboardContractCreditBalance,
#dashboardPanel > .summary-grid #dashboardContractCreditBalance {
  color: #0f172a !important;
  font-size: clamp(2rem, 2.75vw, 2.75rem) !important;
  line-height: 1 !important;
  font-weight: 900 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile small,
#dashboardPanel > .summary-grid .summary-tile small {
  color: #64748b !important;
  font-size: .86rem !important;
  font-weight: 800 !important;
  line-height: 1.2 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid #dashboardContractCreditStatus,
#dashboardPanel > .summary-grid #dashboardContractCreditStatus {
  color: #059669 !important;
}

@media (max-width: 980px) {
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row,
  #dashboardPanel .dashboard-top-row,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-panel,
  #dashboardPanel .dashboard-work-panel {
    grid-template-columns: 1fr !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-art,
  #dashboardPanel .dashboard-work-art {
    display: none !important;
  }
}

/* v1.1.0-dashboard-polish: compact action area, matched filter card, richer icons, and fixed credit text. */
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel,
#dashboardPanel {
  --dash-green: #10b981;
  --dash-green-dark: #059669;
  --dash-ink: #0f172a;
  --dash-muted: #64748b;
  --dash-line: #e2e8f0;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row,
#dashboardPanel .dashboard-top-row {
  display: grid !important;
  grid-template-columns: minmax(0, 2.1fr) minmax(320px, .9fr) !important;
  align-items: stretch !important;
  gap: 18px !important;
  margin-bottom: 18px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-hero,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-filter-panel,
#dashboardPanel .dashboard-top-row .dashboard-hero,
#dashboardPanel .dashboard-top-row .dashboard-filter-panel {
  min-height: 168px !important;
  height: auto !important;
  padding: 26px 30px !important;
  border-radius: 18px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-hero,
#dashboardPanel .dashboard-top-row .dashboard-hero {
  display: flex !important;
  align-items: center !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-hero > div:first-child,
#dashboardPanel .dashboard-top-row .dashboard-hero > div:first-child {
  width: 100% !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-hero h2,
#dashboardPanel .dashboard-top-row .dashboard-hero h2 {
  margin: 0 !important;
  font-size: clamp(2.35rem, 3.05vw, 3.15rem) !important;
  letter-spacing: 0 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions,
#dashboardPanel .dashboard-quick-actions {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: wrap !important;
  align-items: center !important;
  gap: 12px !important;
  margin-top: 24px !important;
  max-width: 100% !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions > *,
#dashboardPanel .dashboard-quick-actions > * {
  width: auto !important;
  min-width: 0 !important;
  flex: 0 0 auto !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions .primary-button,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions .secondary-button,
#dashboardPanel .dashboard-quick-actions .primary-button,
#dashboardPanel .dashboard-quick-actions .secondary-button {
  min-height: 50px !important;
  height: 50px !important;
  padding: 0 18px !important;
  border-radius: 12px !important;
  white-space: nowrap !important;
  font-size: .96rem !important;
  line-height: 1 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions .secondary-button,
#dashboardPanel .dashboard-quick-actions .secondary-button {
  background: #fff !important;
  border-color: var(--dash-line) !important;
  color: var(--dash-ink) !important;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .045) !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filter-panel,
#dashboardPanel .dashboard-filter-panel {
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filter-panel .dashboard-panel-heading,
#dashboardPanel .dashboard-filter-panel .dashboard-panel-heading {
  margin-bottom: 18px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters,
#dashboardPanel .dashboard-filters {
  display: block !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters label,
#dashboardPanel .dashboard-filters label {
  gap: 8px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters select,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filters input,
#dashboardPanel .dashboard-filters select,
#dashboardPanel .dashboard-filters input {
  width: 100% !important;
  min-height: 50px !important;
  height: 50px !important;
  font-size: 1rem !important;
}

.dashboard-button-icon,
#dashboardPanel .summary-tile-icon {
  color: currentColor !important;
}

.dashboard-button-icon::before,
#dashboardPanel .summary-tile-icon::before {
  content: "" !important;
  display: block !important;
  width: 1em !important;
  height: 1em !important;
  background: currentColor !important;
  -webkit-mask: var(--dashboard-icon) center / contain no-repeat !important;
  mask: var(--dashboard-icon) center / contain no-repeat !important;
}

.wallet-icon { --dashboard-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 7.5A3.5 3.5 0 0 1 7.5 4H18a2 2 0 0 1 2 2v2h-3.5A3.5 3.5 0 0 0 13 11.5v1A3.5 3.5 0 0 0 16.5 16H20v2a2 2 0 0 1-2 2H7.5A3.5 3.5 0 0 1 4 16.5v-9Zm12.5 2H21v5h-4.5A1.5 1.5 0 0 1 15 13v-2a1.5 1.5 0 0 1 1.5-1.5Z'/%3E%3C/svg%3E") !important; }
.plus-icon { --dashboard-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 5a1 1 0 1 1 2 0v6h6a1 1 0 1 1 0 2h-6v6a1 1 0 1 1-2 0v-6H5a1 1 0 1 1 0-2h6V5Z'/%3E%3C/svg%3E") !important; }
.line-icon {
  color: #fff !important;
  background: #06c755 !important;
  font-size: .62rem !important;
}
.line-icon::before {
  display: none !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-panel,
#dashboardPanel .dashboard-work-panel {
  grid-template-columns: minmax(0, 1fr) minmax(150px, 220px) auto !important;
  min-height: 128px !important;
  padding: 24px 28px !important;
  gap: 18px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-kicker,
#dashboardPanel .dashboard-work-kicker {
  padding: 6px 14px !important;
  font-size: .82rem !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-panel strong,
#dashboardPanel .dashboard-work-panel strong {
  margin-top: 10px !important;
  font-size: clamp(2rem, 2.65vw, 2.75rem) !important;
  line-height: 1.05 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-panel small,
#dashboardPanel .dashboard-work-panel small {
  max-width: 620px !important;
  font-size: .94rem !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-art,
#dashboardPanel .dashboard-work-art {
  width: 170px !important;
  height: 96px !important;
  margin: 0 !important;
  filter: drop-shadow(0 16px 20px rgba(15, 23, 42, .12)) !important;
}

.work-art-calendar {
  right: 34px !important;
  top: 8px !important;
  width: 84px !important;
  height: 78px !important;
  border-radius: 14px !important;
}

.work-art-calendar::after {
  content: "" !important;
  position: absolute !important;
  left: 16px !important;
  right: 16px !important;
  top: -10px !important;
  height: 18px !important;
  border-radius: 999px !important;
  border: 5px solid #475569 !important;
  border-bottom: 0 !important;
  opacity: .45 !important;
}

.work-art-bell {
  right: 0 !important;
  bottom: 8px !important;
  width: 46px !important;
  height: 46px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-panel .primary-button,
#dashboardPanel .dashboard-work-panel .primary-button {
  min-height: 48px !important;
  height: 48px !important;
  padding-inline: 20px !important;
  white-space: nowrap !important;
  border-radius: 10px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid,
#dashboardPanel > .summary-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 16px !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile,
#dashboardPanel > .summary-grid .summary-tile {
  grid-template-columns: 50px minmax(0, 1fr) !important;
  min-height: 124px !important;
  padding: 20px 22px !important;
  column-gap: 14px !important;
  overflow: hidden !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .summary-tile-icon,
#dashboardPanel .summary-tile-icon {
  width: 50px !important;
  height: 50px !important;
  font-size: 1.45rem !important;
}

.dashboard-tile-principal .summary-tile-icon { --dashboard-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 6a3 3 0 0 1 3-3h10a3 3 0 0 1 3 3v12a3 3 0 0 1-3 3H7a3 3 0 0 1-3-3V6Zm4 2v8h8V8H8Zm2 2h4v4h-4v-4Z'/%3E%3C/svg%3E") !important; }
.dashboard-tile-received .summary-tile-icon { --dashboard-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 4a1 1 0 1 1 2 0v10.6l3.3-3.3a1 1 0 0 1 1.4 1.4l-5 5a1 1 0 0 1-1.4 0l-5-5a1 1 0 1 1 1.4-1.4l3.3 3.3V4Z'/%3E%3C/svg%3E") !important; }
.dashboard-tile-due .summary-tile-icon { --dashboard-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18Zm1 5v5a1 1 0 1 1-2 0V8a1 1 0 1 1 2 0Zm-1 8.5a1.3 1.3 0 1 1 0-2.6 1.3 1.3 0 0 1 0 2.6Z'/%3E%3C/svg%3E") !important; }
.dashboard-tile-contracts .summary-tile-icon { --dashboard-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 3h9l4 4v14H6a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2Zm8 1.8V8h3.2L14 4.8ZM8 11a1 1 0 1 0 0 2h8a1 1 0 1 0 0-2H8Zm0 4a1 1 0 1 0 0 2h6a1 1 0 1 0 0-2H8Z'/%3E%3C/svg%3E") !important; }
.dashboard-tile-interest .summary-tile-icon { --dashboard-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7.5 8A2.5 2.5 0 1 0 7.5 3 2.5 2.5 0 0 0 7.5 8Zm9 13a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5ZM18.7 4.3a1 1 0 0 0-1.4-1.4L5.3 14.9a1 1 0 1 0 1.4 1.4l12-12Z'/%3E%3C/svg%3E") !important; }
.dashboard-tile-profit .summary-tile-icon { --dashboard-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M9.5 16.6 5.7 12.8a1 1 0 1 0-1.4 1.4l4.5 4.5a1 1 0 0 0 1.5-.1l9.4-11.7a1 1 0 1 0-1.6-1.2L9.5 16.6Z'/%3E%3C/svg%3E") !important; }
.dashboard-tile-outstanding .summary-tile-icon { --dashboard-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 3a9 9 0 1 0 8.95 10H13a2 2 0 0 1-2-2V3Zm2 .25V11h7.75A9.02 9.02 0 0 0 13 3.25Z'/%3E%3C/svg%3E") !important; }
.dashboard-credit-summary-tile .summary-tile-icon { --dashboard-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m12 3 2.4 5 5.5.8-4 3.9.9 5.5L12 15.6l-4.8 2.6.9-5.5-4-3.9 5.5-.8L12 3Z'/%3E%3C/svg%3E") !important; }

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon),
#dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon) {
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  font-size: .9rem !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile strong,
#dashboardPanel > .summary-grid .summary-tile strong,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid #dashboardContractCreditBalance,
#dashboardPanel > .summary-grid #dashboardContractCreditBalance {
  font-size: clamp(2rem, 2.45vw, 2.55rem) !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile small,
#dashboardPanel > .summary-grid .summary-tile small {
  display: block !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  max-width: 100% !important;
  font-size: .82rem !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid #dashboardContractCreditStatus,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid #dashboardContractCreditUsed,
#dashboardPanel > .summary-grid #dashboardContractCreditStatus,
#dashboardPanel > .summary-grid #dashboardContractCreditUsed {
  grid-column: 2 !important;
  white-space: nowrap !important;
  font-size: .78rem !important;
  letter-spacing: 0 !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .dashboard-credit-summary-tile,
#dashboardPanel > .summary-grid .dashboard-credit-summary-tile {
  grid-template-rows: auto auto auto auto !important;
}

body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .dashboard-credit-summary-tile .summary-tile-icon,
#dashboardPanel > .summary-grid .dashboard-credit-summary-tile .summary-tile-icon {
  grid-row: 1 / span 4 !important;
}

@media (max-width: 1280px) {
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row,
  #dashboardPanel .dashboard-top-row {
    grid-template-columns: minmax(0, 1.7fr) minmax(280px, .85fr) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions .primary-button,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions .secondary-button,
  #dashboardPanel .dashboard-quick-actions .primary-button,
  #dashboardPanel .dashboard-quick-actions .secondary-button {
    padding-inline: 15px !important;
    font-size: .9rem !important;
  }
}

@media (max-width: 980px) {
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row,
  #dashboardPanel .dashboard-top-row,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-panel,
  #dashboardPanel .dashboard-work-panel {
    grid-template-columns: 1fr !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-work-art,
  #dashboardPanel .dashboard-work-art {
    display: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid,
  #dashboardPanel > .summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

/* v1.1.0-dashboard-search-font: remove duplicated search chrome and align dashboard typography. */
body[data-page="dashboard"]:not(.auth-locked) .app-topbar,
body[data-page="dashboard"]:not(.auth-locked) .topbar,
body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel,
#dashboardPanel {
  font-family: "IBM Plex Sans Thai", Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
}

body[data-page="dashboard"]:not(.auth-locked) .global-search.search-box,
body[data-page="dashboard"]:not(.auth-locked) .global-search,
body[data-page="dashboard"]:not(.auth-locked) .search-box {
  position: relative !important;
  display: flex !important;
  align-items: center !important;
  width: min(100%, 560px) !important;
  max-width: 560px !important;
  height: 54px !important;
  min-height: 54px !important;
  margin: 0 auto !important;
  padding: 0 20px 0 58px !important;
  gap: 0 !important;
  border: 1px solid #dbe3ef !important;
  border-radius: 999px !important;
  background: #fbfcff !important;
  box-shadow: none !important;
  overflow: hidden !important;
}

body[data-page="dashboard"]:not(.auth-locked) .global-search::before,
body[data-page="dashboard"]:not(.auth-locked) .search-box::before {
  content: "" !important;
  position: absolute !important;
  left: 24px !important;
  top: 50% !important;
  width: 18px !important;
  height: 18px !important;
  border: 2px solid #94a3b8 !important;
  border-radius: 999px !important;
  background: transparent !important;
  transform: translateY(-55%) !important;
}

body[data-page="dashboard"]:not(.auth-locked) .global-search::after,
body[data-page="dashboard"]:not(.auth-locked) .search-box::after {
  content: "" !important;
  position: absolute !important;
  left: 39px !important;
  top: 50% !important;
  width: 9px !important;
  height: 2px !important;
  border-radius: 999px !important;
  background: #94a3b8 !important;
  transform: translateY(6px) rotate(45deg) !important;
}

body[data-page="dashboard"]:not(.auth-locked) .global-search input,
body[data-page="dashboard"]:not(.auth-locked) .search-box input {
  width: 100% !important;
  min-width: 0 !important;
  min-height: 0 !important;
  height: auto !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  outline: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: #0f172a !important;
  font-family: inherit !important;
  font-size: 1rem !important;
  font-weight: 600 !important;
  line-height: 1.2 !important;
}

body[data-page="dashboard"]:not(.auth-locked) .global-search input::placeholder,
body[data-page="dashboard"]:not(.auth-locked) .search-box input::placeholder {
  color: #64748b !important;
  opacity: .9 !important;
  font-weight: 600 !important;
}

body[data-page="dashboard"]:not(.auth-locked) .topbar-kicker,
body[data-page="dashboard"]:not(.auth-locked) .page-kicker,
#dashboardPanel .eyebrow {
  font-weight: 700 !important;
}

body[data-page="dashboard"]:not(.auth-locked) .app-topbar h1,
body[data-page="dashboard"]:not(.auth-locked) .topbar h1,
#dashboardPanel .dashboard-hero h2 {
  font-weight: 800 !important;
}

body[data-page="dashboard"]:not(.auth-locked) .topbar-user,
#dashboardPanel .dashboard-work-kicker,
#dashboardPanel .dashboard-filter-panel .dashboard-panel-heading strong,
#dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon),
#dashboardPanel > .summary-grid .summary-tile small {
  font-weight: 600 !important;
}

#dashboardPanel .dashboard-work-panel strong,
#dashboardPanel > .summary-grid .summary-tile strong,
#dashboardPanel > .summary-grid #dashboardContractCreditBalance {
  font-weight: 800 !important;
}

#dashboardPanel .dashboard-quick-actions .primary-button,
#dashboardPanel .dashboard-quick-actions .secondary-button,
#dashboardPanel .dashboard-work-panel .primary-button {
  font-family: inherit !important;
  font-weight: 700 !important;
}

/* v1.1.0-tracking-polish: production layout for the payment follow-up page. */
body[data-page="tracking"]:not(.auth-locked) .workspace::before,
body[data-page="tracking"]:not(.auth-locked) .main-content::before,
body[data-records-subview="tracking"]:not(.auth-locked) .workspace::before,
body[data-records-subview="tracking"]:not(.auth-locked) .main-content::before {
  content: none !important;
  display: none !important;
}

body[data-page="tracking"]:not(.auth-locked) .records-subnav,
body[data-records-subview="tracking"]:not(.auth-locked) .records-subnav {
  display: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel {
  display: grid !important;
  gap: 20px !important;
  width: 100% !important;
  max-width: none !important;
  margin-top: 0 !important;
  padding: 28px 30px 32px !important;
  border: 1px solid #dbe3ef !important;
  border-radius: 22px !important;
  background: rgba(255, 255, 255, .98) !important;
  box-shadow: 0 20px 48px rgba(15, 23, 42, .07) !important;
  font-family: "IBM Plex Sans Thai", Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
  display: grid !important;
  grid-template-columns: minmax(260px, .85fr) minmax(520px, 1fr) !important;
  align-items: end !important;
  gap: 24px !important;
  margin: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title > div:first-child,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title > div:first-child {
  position: relative !important;
  min-width: 0 !important;
  padding-left: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2 {
  margin: 0 !important;
  color: #0f172a !important;
  font-size: clamp(2rem, 2.6vw, 2.7rem) !important;
  line-height: 1.05 !important;
  font-weight: 800 !important;
  letter-spacing: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p {
  margin: 8px 0 0 !important;
  max-width: 540px !important;
  color: #64748b !important;
  font-size: 1rem !important;
  line-height: 1.35 !important;
  font-weight: 600 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row {
  position: static !important;
  display: grid !important;
  grid-template-columns: minmax(300px, 1fr) minmax(190px, 260px) !important;
  align-items: end !important;
  gap: 14px !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .compact-select,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .compact-select {
  display: grid !important;
  gap: 8px !important;
  min-width: 0 !important;
  margin: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control span,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control span,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .compact-select span,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .compact-select span {
  color: #64748b !important;
  font-size: .95rem !important;
  line-height: 1.15 !important;
  font-weight: 600 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel #trackingSearch,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel #trackingSearch,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel #trackingFilter,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel #trackingFilter {
  width: 100% !important;
  min-height: 54px !important;
  height: 54px !important;
  margin: 0 !important;
  border: 1px solid #cfd8e6 !important;
  border-radius: 14px !important;
  background-color: #fff !important;
  color: #0f172a !important;
  font-family: inherit !important;
  font-size: 1rem !important;
  font-weight: 600 !important;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .035) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel #trackingSearch,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel #trackingSearch {
  padding: 0 68px 0 18px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-clear-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-clear-button {
  right: 9px !important;
  bottom: 9px !important;
  min-height: 36px !important;
  padding: 0 12px !important;
  border-radius: 10px !important;
  background: #eefdf5 !important;
  color: #047857 !important;
  font-size: .84rem !important;
  font-weight: 700 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 14px !important;
  margin: 2px 0 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile {
  position: relative !important;
  display: grid !important;
  grid-template-columns: 46px minmax(0, 1fr) !important;
  grid-template-rows: auto auto auto !important;
  column-gap: 14px !important;
  align-content: center !important;
  min-height: 112px !important;
  padding: 18px 20px !important;
  border: 1px solid #dbe3ef !important;
  border-radius: 18px !important;
  background: #fff !important;
  box-shadow: 0 12px 30px rgba(15, 23, 42, .045) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::before,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::before {
  content: "" !important;
  grid-row: 1 / span 3 !important;
  width: 46px !important;
  height: 46px !important;
  border-radius: 999px !important;
  background: #dcfce7 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::after {
  content: "" !important;
  position: absolute !important;
  left: 31px !important;
  top: 35px !important;
  width: 18px !important;
  height: 18px !important;
  background: #10b981 !important;
  -webkit-mask: var(--tracking-card-icon) center / contain no-repeat !important;
  mask: var(--tracking-card-icon) center / contain no-repeat !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1) {
  --tracking-card-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18Zm1 5v5a1 1 0 1 1-2 0V8a1 1 0 1 1 2 0Zm-1 8.5a1.3 1.3 0 1 1 0-2.6 1.3 1.3 0 0 1 0 2.6Z'/%3E%3C/svg%3E") !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(2),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(2) {
  --tracking-card-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 3a1 1 0 0 1 1 1v1h8V4a1 1 0 1 1 2 0v1h1a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V7a2 2 0 0 1 2-2h1V4a1 1 0 0 1 1-1Zm12 7H5v9h14v-9Z'/%3E%3C/svg%3E") !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(3),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(3) {
  --tracking-card-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 2a10 10 0 1 0 10 10A10 10 0 0 0 12 2Zm1 5v4.6l3 1.8a1 1 0 1 1-1 1.7l-3.5-2.1A1 1 0 0 1 11 12V7a1 1 0 1 1 2 0Z'/%3E%3C/svg%3E") !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(4),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(4) {
  --tracking-card-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m9.5 16.6-3.8-3.8a1 1 0 1 0-1.4 1.4l4.5 4.5a1 1 0 0 0 1.5-.1l9.4-11.7a1 1 0 1 0-1.6-1.2L9.5 16.6Z'/%3E%3C/svg%3E") !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1)::before,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1)::before {
  background: #fee2e2 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1)::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1)::after {
  background: #ef4444 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(3)::before,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(3)::before {
  background: #dbeafe !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(3)::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(3)::after {
  background: #3b82f6 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span {
  color: #64748b !important;
  font-size: .92rem !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile strong {
  margin-top: 6px !important;
  color: #0f172a !important;
  font-size: 1.75rem !important;
  line-height: 1 !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile small {
  margin-top: 4px !important;
  color: #64748b !important;
  font-size: .86rem !important;
  font-weight: 600 !important;
  line-height: 1.2 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap {
  display: block !important;
  overflow: hidden !important;
  border: 1px solid #dbe3ef !important;
  border-radius: 18px !important;
  background: #fff !important;
  box-shadow: 0 12px 30px rgba(15, 23, 42, .04) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table {
  min-width: 920px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th {
  padding: 16px 18px !important;
  background: #f8fafc !important;
  color: #64748b !important;
  font-size: .86rem !important;
  font-weight: 700 !important;
  border-bottom: 1px solid #dbe3ef !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td {
  padding: 16px 18px !important;
  color: #0f172a !important;
  font-size: .92rem !important;
  font-weight: 600 !important;
  border-bottom: 1px solid #edf2f7 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr:last-child td,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr:last-child td {
  border-bottom: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td[colspan],
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td[colspan] {
  padding: 24px 18px !important;
  color: #0f172a !important;
  font-size: 1rem !important;
  font-weight: 700 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 8px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button {
  min-height: 36px !important;
  min-width: 86px !important;
  padding: 7px 10px !important;
  border-radius: 10px !important;
  font-size: .82rem !important;
  font-weight: 700 !important;
}

@media (max-width: 1180px) {
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
    grid-template-columns: 1fr !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row {
    grid-template-columns: minmax(0, 1fr) minmax(190px, 260px) !important;
  }
}

@media (max-width: 820px) {
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel {
    padding: 20px 16px !important;
    border-radius: 18px !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row,
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid {
    grid-template-columns: 1fr !important;
  }
}

/* v1.1.0-tracking-exact: match requested desktop tracking mockup. */
body[data-page="tracking"]:not(.auth-locked) .app-topbar,
body[data-records-subview="tracking"]:not(.auth-locked) .app-topbar {
  min-height: 118px !important;
  padding: 24px 32px !important;
  border-radius: 20px !important;
}

body[data-page="tracking"]:not(.auth-locked) .app-topbar h1,
body[data-records-subview="tracking"]:not(.auth-locked) .app-topbar h1 {
  font-size: clamp(2.05rem, 3vw, 2.9rem) !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel {
  gap: 24px !important;
  padding: 34px 36px 28px !important;
  border-radius: 22px !important;
  background: rgba(255, 255, 255, .99) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
  grid-template-columns: minmax(340px, .82fr) minmax(620px, 1fr) !important;
  gap: 34px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2 {
  font-size: clamp(2rem, 2.9vw, 2.85rem) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p strong {
  color: #059669 !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row {
  grid-template-columns: minmax(360px, 1fr) minmax(230px, 320px) !important;
  gap: 18px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control {
  position: relative !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control::before,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control::before {
  content: "" !important;
  position: absolute !important;
  left: 18px !important;
  bottom: 17px !important;
  width: 16px !important;
  height: 16px !important;
  border: 2px solid #94a3b8 !important;
  border-radius: 999px !important;
  z-index: 1 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control::after {
  content: "" !important;
  position: absolute !important;
  left: 32px !important;
  bottom: 16px !important;
  width: 8px !important;
  height: 2px !important;
  border-radius: 999px !important;
  background: #94a3b8 !important;
  transform: rotate(45deg) !important;
  z-index: 1 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel #trackingSearch,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel #trackingSearch {
  padding-left: 54px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-clear-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-clear-button {
  display: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid {
  gap: 20px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile {
  min-height: 136px !important;
  padding: 22px 24px !important;
  grid-template-columns: 64px minmax(0, 1fr) !important;
  column-gap: 16px !important;
  border-radius: 20px !important;
  overflow: hidden !important;
  background:
    radial-gradient(ellipse 78% 48% at 100% 116%, var(--tracking-wave, rgba(16, 185, 129, .12)) 0 46%, transparent 47%),
    #fff !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::before,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::before {
  width: 60px !important;
  height: 60px !important;
  background: var(--tracking-icon-bg, #dcfce7) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::after {
  left: 45px !important;
  top: 47px !important;
  width: 28px !important;
  height: 28px !important;
  background: var(--tracking-icon-color, #10b981) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1) {
  --tracking-icon-bg: #dcfce7;
  --tracking-icon-color: #16a34a;
  --tracking-wave: rgba(16, 185, 129, .12);
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(2),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(2) {
  --tracking-icon-bg: #ffedd5;
  --tracking-icon-color: #f59e0b;
  --tracking-wave: rgba(245, 158, 11, .13);
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(3),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(3) {
  --tracking-icon-bg: #dbeafe;
  --tracking-icon-color: #2563eb;
  --tracking-wave: rgba(59, 130, 246, .13);
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(4),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(4) {
  --tracking-icon-bg: #f3e8ff;
  --tracking-icon-color: #7c3aed;
  --tracking-wave: rgba(168, 85, 247, .13);
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span {
  font-size: 1rem !important;
  font-weight: 700 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile strong {
  margin-top: 8px !important;
  font-size: 2.1rem !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap {
  border-radius: 20px !important;
  overflow-x: auto !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table {
  min-width: 1180px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th {
  padding: 18px 24px !important;
  font-size: .95rem !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td {
  padding: 20px 24px !important;
  font-size: .98rem !important;
  vertical-align: middle !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-button {
  display: inline-grid !important;
  grid-template-columns: 52px minmax(0, 1fr) !important;
  align-items: center !important;
  gap: 14px !important;
  width: 100% !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  color: inherit !important;
  text-align: left !important;
  cursor: pointer !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-photo,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-photo {
  position: relative !important;
  display: block !important;
  width: 52px !important;
  height: 52px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-avatar,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-avatar {
  display: grid !important;
  width: 52px !important;
  height: 52px !important;
  place-items: center !important;
  border-radius: 999px !important;
  object-fit: cover !important;
  background: #ecfdf5 !important;
  color: #064e3b !important;
  font-size: .94rem !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-photo::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-photo::after {
  content: "" !important;
  position: absolute !important;
  right: -1px !important;
  bottom: 1px !important;
  width: 13px !important;
  height: 13px !important;
  border: 2px solid #fff !important;
  border-radius: 999px !important;
  background: #22c55e !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-photo.is-offline::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-photo.is-offline::after {
  background: #94a3b8 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy {
  display: grid !important;
  gap: 2px !important;
  min-width: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy strong {
  color: #0f172a !important;
  font-size: .98rem !important;
  font-weight: 800 !important;
  line-height: 1.22 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy small {
  color: #64748b !important;
  font-size: .88rem !important;
  font-weight: 600 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-period,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-period {
  color: #16a34a !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-amount,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-amount {
  color: #0f172a !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .status-badge.status-late,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .status-badge.status-late {
  min-width: 78px !important;
  justify-content: center !important;
  border: 1px solid #fecaca !important;
  border-radius: 999px !important;
  background: #fee2e2 !important;
  color: #dc2626 !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions {
  flex-wrap: nowrap !important;
  justify-content: flex-end !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  min-height: 42px !important;
  min-width: 112px !important;
  padding: 9px 14px !important;
  border: 1px solid #dbe3ef !important;
  border-radius: 12px !important;
  background: #fff !important;
  color: #0f172a !important;
  box-shadow: 0 8px 18px rgba(15, 23, 42, .035) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-more-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-more-button {
  min-width: 42px !important;
  width: 42px !important;
  padding: 0 !important;
  color: #0f172a !important;
  font-size: 1.25rem !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-action-icon,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-action-icon {
  display: inline-grid !important;
  width: 20px !important;
  height: 20px !important;
  place-items: center !important;
  flex: 0 0 20px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .payment-icon::before,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .payment-icon::before {
  content: "" !important;
  width: 18px !important;
  height: 18px !important;
  background: #64748b !important;
  -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 3h9l4 4v14H6a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2Zm8 1.8V8h3.2L14 4.8ZM8 12a1 1 0 1 0 0 2h8a1 1 0 1 0 0-2H8Zm0 4a1 1 0 1 0 0 2h6a1 1 0 1 0 0-2H8Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 3h9l4 4v14H6a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2Zm8 1.8V8h3.2L14 4.8ZM8 12a1 1 0 1 0 0 2h8a1 1 0 1 0 0-2H8Zm0 4a1 1 0 1 0 0 2h6a1 1 0 1 0 0-2H8Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .line-icon-mini,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .line-icon-mini {
  width: 22px !important;
  height: 22px !important;
  border-radius: 7px !important;
  background: #06c755 !important;
  color: #fff !important;
  font-size: .43rem !important;
  font-weight: 900 !important;
  line-height: 1 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-footer,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-footer {
  display: grid !important;
  grid-template-columns: minmax(220px, 1fr) auto minmax(220px, 1fr) !important;
  align-items: center !important;
  gap: 16px !important;
  padding: 4px 4px 0 !important;
  color: #64748b !important;
  font-size: .92rem !important;
  font-weight: 600 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-page-size,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-page-size {
  display: inline-flex !important;
  align-items: center !important;
  gap: 10px !important;
  justify-self: start !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-page-size select,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-page-size select {
  width: 62px !important;
  height: 42px !important;
  border: 1px solid #dbe3ef !important;
  border-radius: 12px !important;
  background: #fff !important;
  color: #0f172a !important;
  text-align: center !important;
  font-weight: 700 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-page-summary,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-page-summary {
  justify-self: center !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-pagination,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-pagination {
  display: inline-flex !important;
  align-items: center !important;
  justify-self: end !important;
  gap: 10px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-pagination button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-pagination button {
  width: 42px !important;
  height: 42px !important;
  border: 1px solid #dbe3ef !important;
  border-radius: 14px !important;
  background: #fff !important;
  color: #64748b !important;
  font-size: 1.2rem !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-pagination button.is-current,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-pagination button.is-current {
  border-color: #16a34a !important;
  background: #16a34a !important;
  color: #fff !important;
}

@media (max-width: 1180px) {
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
    grid-template-columns: 1fr !important;
  }
}

/* v1.1.0-tracking-exact2: keep tracking layout balanced with the desktop sidebar open. */
body[data-page="tracking"]:not(.auth-locked) #trackingPanel,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel {
  overflow: hidden !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
  width: 100% !important;
  max-width: 100% !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row {
  width: 100% !important;
  max-width: 100% !important;
  justify-content: stretch !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row label,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row label,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row input,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row input,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row select,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row select {
  min-width: 0 !important;
  max-width: 100% !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile {
  position: relative !important;
  display: grid !important;
  grid-template-columns: clamp(46px, 4.6vw, 64px) minmax(0, 1fr) !important;
  grid-template-rows: auto auto auto !important;
  align-content: center !important;
  align-items: center !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::before,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::before {
  content: "" !important;
  position: static !important;
  grid-column: 1 !important;
  grid-row: 1 / span 3 !important;
  align-self: start !important;
  justify-self: start !important;
  width: clamp(46px, 4.3vw, 60px) !important;
  height: clamp(46px, 4.3vw, 60px) !important;
  border-radius: 999px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::after {
  content: "" !important;
  position: absolute !important;
  left: calc(24px + clamp(46px, 4.3vw, 60px) / 2) !important;
  top: 50% !important;
  width: clamp(24px, 2.1vw, 30px) !important;
  height: clamp(24px, 2.1vw, 30px) !important;
  transform: translate(-50%, -50%) !important;
  background: var(--tracking-icon-color, #10b981) !important;
  -webkit-mask: var(--tracking-icon) center / contain no-repeat !important;
  mask: var(--tracking-icon) center / contain no-repeat !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small {
  grid-column: 2 !important;
  min-width: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1) {
  --tracking-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 2h9l5 5v15H6a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2Zm8 1.8V8h4.2L14 3.8ZM8 12h8v2H8v-2Zm0 4h6v2H8v-2Z'/%3E%3C/svg%3E");
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1)::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1)::after {
  -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 2h9l5 5v15H6a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2Zm8 1.8V8h4.2L14 3.8ZM8 12h8v2H8v-2Zm0 4h6v2H8v-2Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 2h9l5 5v15H6a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2Zm8 1.8V8h4.2L14 3.8ZM8 12h8v2H8v-2Zm0 4h6v2H8v-2Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(2),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(2) {
  --tracking-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 2a1 1 0 0 1 1 1v1h8V3a1 1 0 1 1 2 0v1h1a3 3 0 0 1 3 3v12a3 3 0 0 1-3 3H5a3 3 0 0 1-3-3V7a3 3 0 0 1 3-3h1V3a1 1 0 0 1 1-1Zm13 8H4v9a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1v-9ZM6 12h4v4H6v-4Z'/%3E%3C/svg%3E");
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(2)::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(2)::after {
  -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 2a1 1 0 0 1 1 1v1h8V3a1 1 0 1 1 2 0v1h1a3 3 0 0 1 3 3v12a3 3 0 0 1-3 3H5a3 3 0 0 1-3-3V7a3 3 0 0 1 3-3h1V3a1 1 0 0 1 1-1Zm13 8H4v9a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1v-9ZM6 12h4v4H6v-4Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 2a1 1 0 0 1 1 1v1h8V3a1 1 0 1 1 2 0v1h1a3 3 0 0 1 3 3v12a3 3 0 0 1-3 3H5a3 3 0 0 1-3-3V7a3 3 0 0 1 3-3h1V3a1 1 0 0 1 1-1Zm13 8H4v9a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1v-9ZM6 12h4v4H6v-4Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(3),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(3) {
  --tracking-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 2a10 10 0 1 1 0 20 10 10 0 0 1 0-20Zm1 5a1 1 0 1 0-2 0v5a1 1 0 0 0 .45.83l3 2a1 1 0 1 0 1.1-1.66L13 11.46V7Z'/%3E%3C/svg%3E");
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(3)::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(3)::after {
  -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 2a10 10 0 1 1 0 20 10 10 0 0 1 0-20Zm1 5a1 1 0 1 0-2 0v5a1 1 0 0 0 .45.83l3 2a1 1 0 1 0 1.1-1.66L13 11.46V7Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 2a10 10 0 1 1 0 20 10 10 0 0 1 0-20Zm1 5a1 1 0 1 0-2 0v5a1 1 0 0 0 .45.83l3 2a1 1 0 1 0 1.1-1.66L13 11.46V7Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(4),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(4) {
  --tracking-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 2a10 10 0 1 1 0 20 10 10 0 0 1 0-20Zm4.7 7.3a1 1 0 0 0-1.4 0L11 13.59l-2.3-2.3a1 1 0 1 0-1.4 1.42l3 3a1 1 0 0 0 1.4 0l5-5a1 1 0 0 0 0-1.42Z'/%3E%3C/svg%3E");
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(4)::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(4)::after {
  -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 2a10 10 0 1 1 0 20 10 10 0 0 1 0-20Zm4.7 7.3a1 1 0 0 0-1.4 0L11 13.59l-2.3-2.3a1 1 0 1 0-1.4 1.42l3 3a1 1 0 0 0 1.4 0l5-5a1 1 0 0 0 0-1.42Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 2a10 10 0 1 1 0 20 10 10 0 0 1 0-20Zm4.7 7.3a1 1 0 0 0-1.4 0L11 13.59l-2.3-2.3a1 1 0 1 0-1.4 1.42l3 3a1 1 0 0 0 1.4 0l5-5a1 1 0 0 0 0-1.42Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
}

@media (max-width: 1500px) {
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel {
    padding: 28px 28px 24px !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 18px !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row {
    grid-template-columns: minmax(0, 1fr) minmax(210px, 280px) !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile {
    min-height: 120px !important;
    padding: 18px 16px !important;
    column-gap: 12px !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::after,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::after {
    left: calc(16px + clamp(46px, 4.3vw, 60px) / 2) !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span {
    font-size: .84rem !important;
    line-height: 1.24 !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile strong,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile strong {
    font-size: 1.7rem !important;
    line-height: 1.05 !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile small,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile small {
    font-size: .82rem !important;
    line-height: 1.28 !important;
  }
}

@media (max-width: 980px) {
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

/* v1.1.0-tracking-exact4: use real inline SVG icons in tracking summary circles. */
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::before,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::before,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::after {
  display: none !important;
  content: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile {
  grid-template-columns: clamp(52px, 4.6vw, 64px) minmax(0, 1fr) !important;
  column-gap: 16px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon {
  grid-column: 1 !important;
  grid-row: 1 / span 3 !important;
  display: grid !important;
  place-items: center !important;
  align-self: start !important;
  justify-self: start !important;
  width: clamp(52px, 4.3vw, 60px) !important;
  height: clamp(52px, 4.3vw, 60px) !important;
  border-radius: 999px !important;
  flex: 0 0 auto !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon svg,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon svg {
  display: block !important;
  width: clamp(25px, 2.1vw, 30px) !important;
  height: clamp(25px, 2.1vw, 30px) !important;
  fill: currentColor !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-overdue,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-overdue {
  background: #fee2e2 !important;
  color: #ef4444 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-today,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-today {
  background: #ffedd5 !important;
  color: #f59e0b !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-soon,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-soon {
  background: #dbeafe !important;
  color: #2563eb !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-done,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-done {
  background: #f3e8ff !important;
  color: #7c3aed !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon),
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small {
  grid-column: 2 !important;
}

/* v1.1.0-tracking-clean: compact premium collection workflow, table-first. */
body[data-page="tracking"]:not(.auth-locked),
body[data-records-subview="tracking"]:not(.auth-locked) {
  background: #f6f8fb !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel {
  gap: 18px !important;
  padding: 26px 28px 24px !important;
  border: 1px solid rgba(203, 213, 225, .72) !important;
  border-radius: 24px !important;
  background: rgba(255,255,255,.96) !important;
  box-shadow: 0 20px 54px rgba(15,23,42,.065) !important;
  overflow: visible !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
  position: static !important;
  display: grid !important;
  grid-template-columns: minmax(280px, .82fr) minmax(520px, 1fr) !important;
  align-items: end !important;
  gap: 22px !important;
  margin: 0 0 4px !important;
  padding: 0 !important;
  background: transparent !important;
  backdrop-filter: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2 {
  margin: 0 0 6px !important;
  color: #0f172a !important;
  font-size: clamp(2rem, 2.55vw, 3rem) !important;
  font-weight: 850 !important;
  line-height: 1.02 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p {
  color: #64748b !important;
  font-size: .96rem !important;
  font-weight: 700 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row {
  display: grid !important;
  grid-template-columns: minmax(300px, 1fr) minmax(220px, 300px) !important;
  gap: 14px !important;
  align-items: end !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title label > span,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title label > span {
  color: #64748b !important;
  font-size: .84rem !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel #trackingSearch,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel #trackingSearch,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel #trackingFilter,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel #trackingFilter {
  min-height: 50px !important;
  border: 1px solid rgba(148, 163, 184, .34) !important;
  border-radius: 16px !important;
  background: #fff !important;
  box-shadow: 0 10px 26px rgba(15,23,42,.04) !important;
  color: #0f172a !important;
  font-size: .95rem !important;
  font-weight: 750 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 14px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile {
  min-height: 112px !important;
  padding: 18px !important;
  grid-template-columns: 48px minmax(0, 1fr) !important;
  column-gap: 14px !important;
  align-content: center !important;
  border: 1px solid rgba(203, 213, 225, .72) !important;
  border-radius: 20px !important;
  background:
    radial-gradient(ellipse 82% 42% at 102% 116%, var(--tracking-wave, rgba(16,185,129,.09)) 0 48%, transparent 49%),
    #fff !important;
  box-shadow: 0 14px 32px rgba(15,23,42,.045) !important;
  transform: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:hover,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:hover {
  transform: translateY(-1px) !important;
  box-shadow: 0 18px 40px rgba(15,23,42,.065) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon {
  width: 48px !important;
  height: 48px !important;
  align-self: center !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon svg,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon svg {
  width: 22px !important;
  height: 22px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon):not(.tracking-kpi-trend),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon):not(.tracking-kpi-trend) {
  color: #64748b !important;
  font-size: .86rem !important;
  font-weight: 800 !important;
  line-height: 1.2 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile strong {
  margin: 2px 0 0 !important;
  color: #0f172a !important;
  font-size: clamp(1.7rem, 2.25vw, 2.35rem) !important;
  font-weight: 850 !important;
  line-height: 1 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile small {
  color: #64748b !important;
  font-size: .8rem !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-promise-badge,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-promise-badge,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-ai-inline,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-ai-inline {
  display: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap {
  overflow: visible !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table {
  width: 100% !important;
  min-width: 0 !important;
  table-layout: fixed !important;
  border-collapse: separate !important;
  border-spacing: 0 10px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th {
  padding: 0 14px 6px !important;
  border: 0 !important;
  background: transparent !important;
  color: #64748b !important;
  font-size: .78rem !important;
  font-weight: 850 !important;
  text-transform: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(1),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(1) { width: 24% !important; }
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(2),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(2) { width: 16% !important; }
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(3),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(3) { width: 9% !important; }
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(4),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(4) { width: 12% !important; }
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(5),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(5) { width: 11% !important; }
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(6),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(6) { width: 10% !important; }
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(7),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(7) { width: 18% !important; }

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr {
  filter: drop-shadow(0 12px 26px rgba(15,23,42,.04)) !important;
  transform: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr:hover,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr:hover {
  filter: drop-shadow(0 16px 34px rgba(15,23,42,.06)) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td {
  padding: 14px !important;
  border-top: 1px solid rgba(203,213,225,.72) !important;
  border-bottom: 1px solid rgba(203,213,225,.72) !important;
  background: #fff !important;
  color: #0f172a !important;
  font-size: .9rem !important;
  font-weight: 760 !important;
  vertical-align: middle !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td:first-child,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td:first-child {
  border-left: 1px solid rgba(203,213,225,.72) !important;
  border-radius: 18px 0 0 18px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td:last-child,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td:last-child {
  position: static !important;
  right: auto !important;
  z-index: auto !important;
  border-right: 1px solid rgba(203,213,225,.72) !important;
  border-radius: 0 18px 18px 0 !important;
  box-shadow: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-button {
  grid-template-columns: 48px minmax(0, 1fr) !important;
  gap: 12px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-photo,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-photo,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-avatar,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-avatar {
  width: 48px !important;
  height: 48px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy strong {
  display: block !important;
  overflow: hidden !important;
  color: #0f172a !important;
  font-size: .95rem !important;
  font-weight: 850 !important;
  line-height: 1.24 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  word-break: normal !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy small {
  display: block !important;
  overflow: hidden !important;
  color: #64748b !important;
  font-size: .8rem !important;
  font-weight: 700 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-contract-no,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-contract-no,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-due-date,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-due-date {
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-period span,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-period span {
  display: inline-flex !important;
  padding: 6px 10px !important;
  border-radius: 999px !important;
  background: #ecfdf5 !important;
  color: #047857 !important;
  font-size: .84rem !important;
  font-weight: 850 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-amount,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-amount {
  color: #0f172a !important;
  font-size: .92rem !important;
  font-weight: 850 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .status-badge.status-late,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .status-badge.status-late {
  min-width: 70px !important;
  padding: 7px 10px !important;
  border: 1px solid #fecaca !important;
  border-radius: 999px !important;
  background: #fee2e2 !important;
  color: #dc2626 !important;
  font-size: .82rem !important;
  font-weight: 850 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions {
  display: flex !important;
  flex-wrap: nowrap !important;
  justify-content: flex-end !important;
  gap: 8px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button {
  min-width: 38px !important;
  min-height: 38px !important;
  height: 38px !important;
  padding: 0 10px !important;
  border-radius: 12px !important;
  font-size: .82rem !important;
  font-weight: 850 !important;
  box-shadow: 0 8px 18px rgba(15,23,42,.035) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action {
  min-width: 90px !important;
  border-color: rgba(16,185,129,.36) !important;
  background: linear-gradient(180deg, #10b981, #059669) !important;
  color: #fff !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action .payment-icon::before,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action .payment-icon::before {
  background: #fff !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .line-action,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .line-action {
  min-width: 92px !important;
  background: #fff !important;
  color: #0f172a !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-more-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-more-button {
  width: 38px !important;
  min-width: 38px !important;
  padding: 0 !important;
  font-size: 1rem !important;
}

@media (max-width: 1500px) {
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
    grid-template-columns: 1fr !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button span:not(.tracking-action-icon),
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button span:not(.tracking-action-icon) {
    display: none !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action,
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .line-action,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .line-action {
    width: 38px !important;
    min-width: 38px !important;
    padding: 0 !important;
  }
}

@media (max-width: 1180px) {
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap {
    overflow-x: auto !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table {
    min-width: 1040px !important;
  }
}

/* v1.1.0-tracking-fintech: premium collections workflow inspired by modern fintech SaaS. */
body[data-page="tracking"]:not(.auth-locked),
body[data-records-subview="tracking"]:not(.auth-locked) {
  background:
    radial-gradient(circle at 12% 8%, rgba(34, 197, 94, .08), transparent 32%),
    radial-gradient(circle at 88% 20%, rgba(59, 130, 246, .07), transparent 30%),
    #f6f8fb !important;
}

body[data-page="tracking"]:not(.auth-locked) .app-topbar,
body[data-records-subview="tracking"]:not(.auth-locked) .app-topbar {
  min-height: 104px !important;
  border-color: rgba(148, 163, 184, .24) !important;
  background: rgba(255, 255, 255, .86) !important;
  box-shadow: 0 22px 55px rgba(15, 23, 42, .075) !important;
  backdrop-filter: blur(18px) saturate(130%) !important;
}

body[data-page="tracking"]:not(.auth-locked) .app-topbar h1,
body[data-records-subview="tracking"]:not(.auth-locked) .app-topbar h1 {
  font-size: clamp(2rem, 2.35vw, 2.7rem) !important;
  letter-spacing: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel {
  isolation: isolate !important;
  gap: 22px !important;
  padding: clamp(24px, 2.4vw, 36px) !important;
  border: 1px solid rgba(203, 213, 225, .68) !important;
  border-radius: 28px !important;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .97), rgba(255, 255, 255, .91)),
    radial-gradient(circle at 0 0, rgba(16, 185, 129, .1), transparent 28%) !important;
  box-shadow: 0 26px 80px rgba(15, 23, 42, .08) !important;
  overflow: visible !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
  position: sticky !important;
  top: 118px !important;
  z-index: 8 !important;
  display: grid !important;
  grid-template-columns: minmax(320px, .74fr) minmax(520px, 1fr) !important;
  align-items: end !important;
  gap: 28px !important;
  margin: -4px -4px 2px !important;
  padding: 10px 4px 18px !important;
  background: linear-gradient(180deg, rgba(255,255,255,.92), rgba(255,255,255,.78)) !important;
  backdrop-filter: blur(12px) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2 {
  margin: 0 0 6px !important;
  color: #071126 !important;
  font-size: clamp(2.25rem, 3.3vw, 4.1rem) !important;
  font-weight: 850 !important;
  line-height: .96 !important;
  letter-spacing: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p {
  color: #667085 !important;
  font-size: 1rem !important;
  font-weight: 700 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p strong {
  color: #0e9f6e !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row {
  display: grid !important;
  grid-template-columns: minmax(280px, 1fr) minmax(210px, 300px) !important;
  gap: 16px !important;
  align-items: end !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title label > span,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title label > span {
  color: #667085 !important;
  font-size: .9rem !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel #trackingSearch,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel #trackingSearch,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel #trackingFilter,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel #trackingFilter {
  min-height: 54px !important;
  border: 1px solid rgba(148, 163, 184, .36) !important;
  border-radius: 18px !important;
  background: rgba(255,255,255,.82) !important;
  box-shadow: 0 14px 34px rgba(15, 23, 42, .045) !important;
  color: #101828 !important;
  font-size: 1rem !important;
  font-weight: 750 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 18px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile {
  min-height: 154px !important;
  padding: 22px !important;
  grid-template-columns: 56px minmax(0, 1fr) !important;
  align-content: center !important;
  border: 1px solid rgba(203, 213, 225, .75) !important;
  border-radius: 24px !important;
  background:
    radial-gradient(ellipse 86% 42% at 102% 112%, var(--tracking-wave, rgba(16, 185, 129, .12)) 0 48%, transparent 49%),
    linear-gradient(180deg, #fff, rgba(255,255,255,.92)) !important;
  box-shadow: 0 20px 45px rgba(15, 23, 42, .055) !important;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:hover,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:hover {
  transform: translateY(-2px) !important;
  border-color: rgba(148, 163, 184, .95) !important;
  box-shadow: 0 24px 64px rgba(15, 23, 42, .09) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile:nth-child(1) {
  --tracking-wave: rgba(239, 68, 68, .1) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon {
  width: 56px !important;
  height: 56px !important;
  align-self: center !important;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.7), 0 12px 26px rgba(15,23,42,.05) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon svg,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon svg {
  width: 26px !important;
  height: 26px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon):not(.tracking-kpi-trend),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon):not(.tracking-kpi-trend) {
  color: #667085 !important;
  font-size: .96rem !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile strong {
  margin: 3px 0 0 !important;
  color: #071126 !important;
  font-size: clamp(2rem, 3.2vw, 3.15rem) !important;
  font-weight: 850 !important;
  line-height: .98 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile small {
  color: #667085 !important;
  font-size: .9rem !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend {
  grid-column: 1 / -1 !important;
  display: grid !important;
  grid-template-columns: repeat(4, 1fr) !important;
  align-items: end !important;
  gap: 5px !important;
  width: 74px !important;
  height: 20px !important;
  margin-top: 8px !important;
  opacity: .7 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend i,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend i {
  display: block !important;
  height: 8px !important;
  border-radius: 999px !important;
  background: currentColor !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend i:nth-child(2),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend i:nth-child(2) { height: 14px !important; }

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend i:nth-child(3),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend i:nth-child(3) { height: 10px !important; }

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend i:nth-child(4),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend i:nth-child(4) { height: 18px !important; }

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center {
  display: grid !important;
  grid-template-columns: minmax(280px, 1fr) minmax(320px, 1.15fr) minmax(220px, .58fr) !important;
  gap: 16px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center > div,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center > div {
  min-height: 120px !important;
  padding: 22px !important;
  border: 1px solid rgba(203, 213, 225, .68) !important;
  border-radius: 24px !important;
  background: rgba(255,255,255,.78) !important;
  box-shadow: 0 18px 44px rgba(15,23,42,.055) !important;
  backdrop-filter: blur(16px) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-priority-card,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-priority-card {
  background:
    linear-gradient(135deg, rgba(254, 242, 242, .92), rgba(255,255,255,.82) 58%),
    #fff !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-ai-card,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-ai-card {
  background:
    linear-gradient(135deg, rgba(236, 253, 245, .92), rgba(255,255,255,.78) 60%),
    #fff !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-priority-kicker,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-priority-kicker,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-ai-badge,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-ai-badge,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-health-card > span,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-health-card > span {
  color: #0e9f6e !important;
  font-size: .78rem !important;
  font-weight: 850 !important;
  letter-spacing: 0 !important;
  text-transform: uppercase !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center strong {
  display: block !important;
  margin-top: 8px !important;
  color: #071126 !important;
  font-size: clamp(1.12rem, 1.35vw, 1.45rem) !important;
  font-weight: 850 !important;
  line-height: 1.16 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center p,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center p {
  margin: 8px 0 0 !important;
  color: #667085 !important;
  font-size: .9rem !important;
  font-weight: 650 !important;
  line-height: 1.45 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-health-meter,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-health-meter {
  height: 10px !important;
  margin-top: 18px !important;
  overflow: hidden !important;
  border-radius: 999px !important;
  background: #e5e7eb !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-health-meter i,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-health-meter i {
  display: block !important;
  width: 0%;
  height: 100% !important;
  border-radius: inherit !important;
  background: linear-gradient(90deg, #ef4444, #f59e0b, #10b981) !important;
  transition: width .28s ease !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap {
  overflow: visible !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table {
  width: 100% !important;
  min-width: 0 !important;
  table-layout: fixed !important;
  border-collapse: separate !important;
  border-spacing: 0 12px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th {
  padding: 0 16px 8px !important;
  border: 0 !important;
  background: transparent !important;
  color: #667085 !important;
  font-size: .8rem !important;
  font-weight: 850 !important;
  letter-spacing: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(1),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(1) { width: 25% !important; }

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(2),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(2) { width: 16% !important; }

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(3),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(3) { width: 9% !important; }

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(4),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(4) { width: 11% !important; }

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(5),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(5) { width: 11% !important; }

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(6),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(6) { width: 10% !important; }

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(7),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(7) { width: 18% !important; }

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr {
  border-radius: 22px !important;
  filter: drop-shadow(0 14px 32px rgba(15,23,42,.045)) !important;
  transition: transform .16s ease, filter .16s ease !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr:hover,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr:hover {
  transform: translateY(-1px) !important;
  filter: drop-shadow(0 18px 42px rgba(15,23,42,.075)) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td {
  padding: 18px 16px !important;
  border-top: 1px solid rgba(203, 213, 225, .72) !important;
  border-bottom: 1px solid rgba(203, 213, 225, .72) !important;
  background: rgba(255,255,255,.96) !important;
  color: #101828 !important;
  font-size: .95rem !important;
  font-weight: 760 !important;
  vertical-align: middle !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td:first-child,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td:first-child {
  border-left: 1px solid rgba(203, 213, 225, .72) !important;
  border-radius: 22px 0 0 22px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td:last-child,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td:last-child {
  position: sticky !important;
  right: 0 !important;
  z-index: 2 !important;
  border-right: 1px solid rgba(203, 213, 225, .72) !important;
  border-radius: 0 22px 22px 0 !important;
  box-shadow: -20px 0 30px rgba(255,255,255,.88) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-button {
  grid-template-columns: 58px minmax(0, 1fr) !important;
  gap: 14px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-photo,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-photo,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-avatar,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-avatar {
  width: 58px !important;
  height: 58px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy strong {
  overflow-wrap: normal !important;
  word-break: normal !important;
  color: #071126 !important;
  font-size: .98rem !important;
  font-weight: 850 !important;
  line-height: 1.2 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy small {
  color: #667085 !important;
  font-size: .86rem !important;
  font-weight: 720 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-promise-badge,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-promise-badge {
  display: inline-flex !important;
  width: fit-content !important;
  max-width: 100% !important;
  margin-top: 5px !important;
  padding: 4px 8px !important;
  border-radius: 999px !important;
  background: #f8fafc !important;
  color: #667085 !important;
  font-size: .72rem !important;
  font-style: normal !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-promise-badge.danger,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-promise-badge.danger {
  background: #fef2f2 !important;
  color: #dc2626 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-promise-badge.warning,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-promise-badge.warning {
  background: #fffbeb !important;
  color: #b45309 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-ai-inline,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-ai-inline {
  display: block !important;
  max-width: 360px !important;
  margin-top: 4px !important;
  overflow: hidden !important;
  color: #98a2b3 !important;
  font-size: .74rem !important;
  font-weight: 650 !important;
  line-height: 1.32 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-contract-no,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-contract-no,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-due-date,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-due-date {
  white-space: nowrap !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-period span,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-period span {
  display: inline-flex !important;
  padding: 7px 10px !important;
  border-radius: 999px !important;
  background: #ecfdf5 !important;
  color: #047857 !important;
  font-weight: 850 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-amount,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-amount {
  color: #071126 !important;
  font-size: 1rem !important;
  font-weight: 850 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .status-badge.status-late,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .status-badge.status-late {
  min-width: 76px !important;
  padding: 8px 12px !important;
  border-color: #fecaca !important;
  background: linear-gradient(180deg, #fff1f2, #fee2e2) !important;
  color: #dc2626 !important;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.8) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions {
  display: flex !important;
  flex-wrap: nowrap !important;
  justify-content: flex-end !important;
  gap: 8px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button {
  min-width: 0 !important;
  min-height: 40px !important;
  padding: 9px 12px !important;
  border-radius: 14px !important;
  font-size: .86rem !important;
  font-weight: 850 !important;
  box-shadow: 0 10px 22px rgba(15,23,42,.04) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action {
  border-color: rgba(16, 185, 129, .32) !important;
  background: linear-gradient(180deg, #10b981, #059669) !important;
  color: #fff !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action .payment-icon::before,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action .payment-icon::before {
  background: #fff !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .line-action,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .line-action {
  border-color: rgba(203, 213, 225, .78) !important;
  background: rgba(255,255,255,.96) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-more-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-more-button {
  width: 40px !important;
  min-width: 40px !important;
  font-size: 1.05rem !important;
}

@media (max-width: 1500px) {
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center {
    grid-template-columns: 1fr 1fr !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-health-card,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-health-card {
    grid-column: 1 / -1 !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button span:not(.tracking-action-icon),
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button span:not(.tracking-action-icon) {
    display: none !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button {
    width: 42px !important;
    min-width: 42px !important;
    padding: 0 !important;
  }
}

@media (max-width: 1180px) {
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
    position: static !important;
    grid-template-columns: 1fr !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table {
    min-width: 1080px !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap {
    overflow-x: auto !important;
  }
}

/* v1.1.0-tracking-clean2: final override after the fintech experiment. */
body[data-page="tracking"]:not(.auth-locked),
body[data-records-subview="tracking"]:not(.auth-locked) {
  background: #f6f8fb !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel {
  gap: 18px !important;
  padding: 24px 26px 24px !important;
  overflow: visible !important;
  border: 1px solid rgba(213, 222, 234, .92) !important;
  border-radius: 22px !important;
  background: rgba(255, 255, 255, .98) !important;
  box-shadow: 0 18px 46px rgba(15, 23, 42, .055) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
  position: static !important;
  display: grid !important;
  grid-template-columns: minmax(280px, .82fr) minmax(520px, 1fr) !important;
  align-items: end !important;
  gap: 20px !important;
  min-height: auto !important;
  margin: 0 0 6px !important;
  padding: 0 0 16px !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(226, 232, 240, .9) !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title::before,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title::before,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title::after {
  display: none !important;
  content: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2 {
  margin: 0 !important;
  color: #071126 !important;
  font-family: "Sarabun", "Inter", system-ui, sans-serif !important;
  font-size: clamp(2rem, 2.4vw, 2.75rem) !important;
  font-weight: 850 !important;
  letter-spacing: 0 !important;
  line-height: 1.05 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p {
  margin-top: 7px !important;
  color: #667085 !important;
  font-size: .98rem !important;
  font-weight: 680 !important;
  line-height: 1.34 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row {
  display: grid !important;
  grid-template-columns: minmax(260px, 1fr) minmax(180px, 260px) !important;
  gap: 12px !important;
  align-items: end !important;
  width: 100% !important;
  min-width: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .compact-select,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .compact-select {
  min-width: 0 !important;
  gap: 6px !important;
  color: #667085 !important;
  font-size: .82rem !important;
  font-weight: 760 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control input,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control input,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .compact-select select,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .compact-select select {
  height: 50px !important;
  min-height: 50px !important;
  padding: 0 44px 0 48px !important;
  border: 1px solid rgba(203, 213, 225, .95) !important;
  border-radius: 16px !important;
  background-color: #fff !important;
  box-shadow: 0 8px 18px rgba(15, 23, 42, .035) !important;
  color: #111827 !important;
  font-family: "Sarabun", "Inter", system-ui, sans-serif !important;
  font-size: .98rem !important;
  font-weight: 760 !important;
  letter-spacing: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control::after {
  left: 16px !important;
  top: calc(50% + 12px) !important;
  width: 20px !important;
  height: 20px !important;
  opacity: .7 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-clear-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-clear-button {
  right: 10px !important;
  bottom: 9px !important;
  min-height: 30px !important;
  padding: 0 10px !important;
  border-radius: 10px !important;
  font-size: .76rem !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 14px !important;
  margin: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile {
  position: relative !important;
  display: grid !important;
  grid-template-columns: 48px minmax(0, 1fr) !important;
  grid-template-rows: auto auto auto !important;
  align-content: center !important;
  align-items: center !important;
  column-gap: 14px !important;
  min-height: 108px !important;
  padding: 16px !important;
  overflow: hidden !important;
  border: 1px solid rgba(213, 222, 234, .92) !important;
  border-radius: 18px !important;
  background: #fff !important;
  box-shadow: 0 10px 26px rgba(15, 23, 42, .045) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::before,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::before,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile::after {
  display: none !important;
  content: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon {
  grid-column: 1 !important;
  grid-row: 1 / span 3 !important;
  display: grid !important;
  place-items: center !important;
  width: 48px !important;
  height: 48px !important;
  border-radius: 16px !important;
  align-self: center !important;
  justify-self: center !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon svg,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon svg {
  width: 24px !important;
  height: 24px !important;
  fill: currentColor !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-overdue,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-overdue {
  background: #fee2e2 !important;
  color: #dc2626 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-today,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-today {
  background: #fff7ed !important;
  color: #f59e0b !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-soon,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-soon {
  background: #eff6ff !important;
  color: #2563eb !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-done,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-done {
  background: #f5f3ff !important;
  color: #7c3aed !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon),
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small {
  grid-column: 2 !important;
  min-width: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon) {
  overflow: hidden !important;
  color: #667085 !important;
  font-size: .86rem !important;
  font-weight: 760 !important;
  line-height: 1.2 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile strong {
  margin-top: 2px !important;
  color: #071126 !important;
  font-size: clamp(1.85rem, 2.35vw, 2.55rem) !important;
  font-weight: 850 !important;
  letter-spacing: 0 !important;
  line-height: .98 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile small {
  margin-top: 6px !important;
  overflow: hidden !important;
  color: #667085 !important;
  font-size: .82rem !important;
  font-weight: 720 !important;
  line-height: 1.22 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-kpi-trend,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-command-center,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-promise-badge,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-promise-badge,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-ai-inline,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-ai-inline {
  display: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap {
  margin-top: 2px !important;
  overflow: visible !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table {
  width: 100% !important;
  min-width: 0 !important;
  table-layout: fixed !important;
  border-collapse: separate !important;
  border-spacing: 0 10px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table thead tr,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table thead tr {
  background: transparent !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th {
  height: 34px !important;
  padding: 0 14px 8px !important;
  border: 0 !important;
  background: transparent !important;
  color: #667085 !important;
  font-size: .78rem !important;
  font-weight: 800 !important;
  letter-spacing: 0 !important;
  text-align: left !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(1),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(1) { width: 25% !important; }
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(2),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(2) { width: 16% !important; }
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(3),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(3) { width: 9% !important; }
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(4),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(4) { width: 12% !important; }
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(5),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(5) { width: 10% !important; }
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(6),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(6) { width: 10% !important; }
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(7),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(7) { width: 18% !important; }

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr {
  filter: none !important;
  transition: transform .15s ease, box-shadow .15s ease !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr:hover,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table tbody tr:hover {
  transform: translateY(-1px) !important;
  filter: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td {
  height: 74px !important;
  padding: 12px 14px !important;
  overflow: hidden !important;
  border-top: 1px solid rgba(213, 222, 234, .92) !important;
  border-bottom: 1px solid rgba(213, 222, 234, .92) !important;
  background: #fff !important;
  color: #111827 !important;
  font-family: "Sarabun", "Inter", system-ui, sans-serif !important;
  font-size: .92rem !important;
  font-weight: 760 !important;
  line-height: 1.28 !important;
  vertical-align: middle !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td:first-child,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td:first-child {
  border-left: 1px solid rgba(213, 222, 234, .92) !important;
  border-radius: 18px 0 0 18px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td:last-child,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td:last-child {
  position: static !important;
  right: auto !important;
  z-index: auto !important;
  border-right: 1px solid rgba(213, 222, 234, .92) !important;
  border-radius: 0 18px 18px 0 !important;
  box-shadow: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-button {
  display: grid !important;
  grid-template-columns: 48px minmax(0, 1fr) !important;
  gap: 12px !important;
  align-items: center !important;
  width: 100% !important;
  min-width: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  text-align: left !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-photo,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-photo,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-avatar,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-avatar {
  width: 48px !important;
  height: 48px !important;
  border-radius: 16px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy {
  display: grid !important;
  min-width: 0 !important;
  gap: 3px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy strong,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy small,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-contract-no,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-contract-no,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-due-date,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-due-date {
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  word-break: normal !important;
  overflow-wrap: normal !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy strong {
  color: #071126 !important;
  font-size: .95rem !important;
  font-weight: 850 !important;
  line-height: 1.18 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-customer-copy small {
  color: #667085 !important;
  font-size: .8rem !important;
  font-weight: 700 !important;
  line-height: 1.18 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-contract-no,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-contract-no,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-due-date,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-due-date {
  font-size: .88rem !important;
  font-weight: 800 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-period span,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-period span {
  display: inline-flex !important;
  min-width: 0 !important;
  padding: 5px 10px !important;
  border-radius: 999px !important;
  background: #ecfdf5 !important;
  color: #047857 !important;
  font-size: .84rem !important;
  font-weight: 850 !important;
  white-space: nowrap !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-amount,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-amount {
  color: #071126 !important;
  font-size: .9rem !important;
  font-weight: 850 !important;
  white-space: nowrap !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .status-badge.status-late,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .status-badge.status-late {
  min-width: 0 !important;
  padding: 6px 10px !important;
  border-color: #fecaca !important;
  background: #fef2f2 !important;
  color: #dc2626 !important;
  font-size: .8rem !important;
  font-weight: 820 !important;
  box-shadow: none !important;
  white-space: nowrap !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions {
  display: flex !important;
  flex-wrap: nowrap !important;
  justify-content: flex-end !important;
  align-items: center !important;
  gap: 8px !important;
  min-width: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 7px !important;
  width: auto !important;
  min-width: 38px !important;
  min-height: 38px !important;
  height: 38px !important;
  padding: 0 11px !important;
  border-radius: 12px !important;
  font-size: .82rem !important;
  font-weight: 850 !important;
  line-height: 1 !important;
  box-shadow: none !important;
  white-space: nowrap !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action {
  min-width: 86px !important;
  border-color: rgba(16, 185, 129, .24) !important;
  background: #10b981 !important;
  color: #fff !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .line-action,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .line-action {
  min-width: 92px !important;
  border-color: rgba(203, 213, 225, .9) !important;
  background: #fff !important;
  color: #111827 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-action-icon,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-action-icon {
  flex: 0 0 auto !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-more-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-more-button {
  width: 38px !important;
  min-width: 38px !important;
  padding: 0 !important;
  color: #667085 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-footer,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-footer {
  margin-top: 0 !important;
  color: #667085 !important;
  font-size: .84rem !important;
  font-weight: 700 !important;
}

@media (max-width: 1500px) {
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row {
    grid-template-columns: minmax(0, 1fr) minmax(180px, 240px) !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button span:not(.tracking-action-icon),
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button span:not(.tracking-action-icon) {
    display: none !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button {
    width: 38px !important;
    min-width: 38px !important;
    padding: 0 !important;
  }
}

@media (max-width: 1180px) {
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table-wrap {
    overflow-x: auto !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table {
    min-width: 1040px !important;
  }
}

/* v1.1.0-tracking-clean3: single search icon, no stacked glyph. */
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control {
  position: relative !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control::before,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control::before {
  content: "" !important;
  position: absolute !important;
  left: 18px !important;
  right: auto !important;
  top: auto !important;
  bottom: 17px !important;
  width: 16px !important;
  height: 16px !important;
  border: 2px solid #94a3b8 !important;
  border-radius: 999px !important;
  background: transparent !important;
  transform: none !important;
  opacity: 1 !important;
  z-index: 1 !important;
}

/* v1.1.0-tracking-clean4: three status cards with horizontal number hierarchy. */
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 14px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile {
  grid-template-columns: 74px auto minmax(0, 1fr) !important;
  grid-template-rows: auto auto !important;
  min-height: 118px !important;
  padding: 20px 22px !important;
  column-gap: 18px !important;
  align-items: center !important;
  align-content: center !important;
  border-radius: 22px !important;
  background: linear-gradient(180deg, #ffffff 0%, #ffffff 62%, #fbfdff 100%) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon {
  grid-column: 1 !important;
  grid-row: 1 / span 2 !important;
  width: 74px !important;
  height: 74px !important;
  border-radius: 22px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon svg,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon svg {
  width: 32px !important;
  height: 32px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong {
  grid-column: 2 !important;
  grid-row: 1 / span 2 !important;
  align-self: center !important;
  margin: 0 !important;
  color: #071126 !important;
  font-size: clamp(3rem, 4.4vw, 4.75rem) !important;
  font-weight: 900 !important;
  letter-spacing: 0 !important;
  line-height: .9 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon) {
  grid-column: 3 !important;
  grid-row: 1 !important;
  align-self: end !important;
  color: #667085 !important;
  font-size: clamp(1.05rem, 1.65vw, 1.55rem) !important;
  font-weight: 850 !important;
  line-height: 1.05 !important;
  white-space: normal !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small {
  grid-column: 3 !important;
  grid-row: 2 !important;
  align-self: start !important;
  margin: 8px 0 0 !important;
  color: #667085 !important;
  font-size: clamp(.98rem, 1.35vw, 1.25rem) !important;
  font-weight: 800 !important;
  line-height: 1.12 !important;
  white-space: nowrap !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-overdue,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-overdue {
  background: #fee2e2 !important;
  color: #667085 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-today,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-today {
  background: #fff7ed !important;
  color: #667085 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-done,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon-done {
  background: #ecfdf5 !important;
  color: #667085 !important;
}

@media (max-width: 1280px) {
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid {
    grid-template-columns: 1fr !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile {
    grid-template-columns: 68px auto minmax(0, 1fr) !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon {
    width: 68px !important;
    height: 68px !important;
  }
}

/* v1.1.0-tracking-clean5: prevent summary number/icon collision in 3-card row. */
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile {
  grid-template-columns: 62px minmax(44px, auto) minmax(0, 1fr) !important;
  min-height: 104px !important;
  padding: 18px 18px !important;
  column-gap: 14px !important;
  justify-items: start !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon {
  width: 62px !important;
  height: 62px !important;
  justify-self: start !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon svg,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon svg {
  width: 28px !important;
  height: 28px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong {
  justify-self: start !important;
  min-width: 0 !important;
  font-size: clamp(2.65rem, 3.25vw, 3.7rem) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon) {
  justify-self: start !important;
  font-size: clamp(.98rem, 1.15vw, 1.22rem) !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small {
  justify-self: start !important;
  font-size: clamp(.9rem, 1.05vw, 1.08rem) !important;
}

/* v1.1.0-tracking-clean6: hard-position metric card parts to avoid inherited grid collisions. */
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile {
  position: relative !important;
  display: block !important;
  min-height: 104px !important;
  padding: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-summary-icon {
  position: absolute !important;
  left: 24px !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  width: 62px !important;
  height: 62px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong {
  position: absolute !important;
  left: 108px !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  min-width: 52px !important;
  margin: 0 !important;
  text-align: left !important;
  font-size: clamp(2.65rem, 3.15vw, 3.55rem) !important;
  line-height: .9 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon) {
  position: absolute !important;
  left: 178px !important;
  right: 18px !important;
  top: 30px !important;
  display: block !important;
  margin: 0 !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small {
  position: absolute !important;
  left: 178px !important;
  right: 18px !important;
  top: 60px !important;
  display: block !important;
  margin: 0 !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

/* v1.1.0-tracking-clean7: keep row actions stable while resizing the browser. */
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(7),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th:nth-child(7) {
  width: 154px !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions {
  width: 142px !important;
  min-width: 142px !important;
  max-width: 142px !important;
  gap: 8px !important;
  justify-content: flex-end !important;
  overflow: visible !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .payment-action,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .line-action,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .line-action,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-more-button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-more-button {
  width: 42px !important;
  min-width: 42px !important;
  max-width: 42px !important;
  height: 42px !important;
  min-height: 42px !important;
  padding: 0 !important;
  border-radius: 14px !important;
  overflow: hidden !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button span:not(.tracking-action-icon),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-actions .secondary-button span:not(.tracking-action-icon) {
  display: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-action-icon,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-action-icon {
  margin: 0 !important;
}

/* v1.1.0-history-premium1: payment history dashboard matching the premium reference. */
body[data-page="history"]:not(.auth-locked),
body[data-records-subview="history"]:not(.auth-locked) {
  background: #f6f8fb !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel {
  gap: 22px !important;
  padding: 28px !important;
  overflow: visible !important;
  border: 1px solid rgba(213, 222, 234, .92) !important;
  border-radius: 24px !important;
  background: rgba(255,255,255,.98) !important;
  box-shadow: 0 24px 58px rgba(15,23,42,.065) !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel > .panel-title,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel > .panel-title {
  position: static !important;
  display: grid !important;
  grid-template-columns: minmax(280px, .82fr) minmax(560px, 1fr) !important;
  gap: 24px !important;
  align-items: end !important;
  min-height: auto !important;
  padding: 0 0 18px !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(226,232,240,.92) !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel > .panel-title::before,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel > .panel-title::before,
body[data-page="history"]:not(.auth-locked) #historyPanel > .panel-title::after,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel > .panel-title::after {
  display: none !important;
  content: none !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel > .panel-title h2,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel > .panel-title h2 {
  margin: 0 !important;
  color: #071126 !important;
  font-family: "Sarabun", "Inter", system-ui, sans-serif !important;
  font-size: clamp(2.15rem, 2.75vw, 3.35rem) !important;
  font-weight: 900 !important;
  letter-spacing: 0 !important;
  line-height: 1.03 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel > .panel-title p,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel > .panel-title p {
  margin-top: 9px !important;
  color: #667085 !important;
  font-size: 1rem !important;
  font-weight: 740 !important;
  line-height: 1.35 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel > .panel-title p strong,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel > .panel-title p strong {
  color: #059669 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel > .panel-title .button-row,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel > .panel-title .button-row {
  display: grid !important;
  grid-template-columns: minmax(150px, 1fr) minmax(150px, 1fr) minmax(150px, .9fr) minmax(120px, auto) !important;
  gap: 12px !important;
  align-items: end !important;
  width: 100% !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .compact-select,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .compact-select {
  gap: 6px !important;
  color: #667085 !important;
  font-size: .82rem !important;
  font-weight: 780 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .compact-select input,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .compact-select input,
body[data-page="history"]:not(.auth-locked) #historyPanel .compact-select select,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .compact-select select {
  height: 50px !important;
  min-height: 50px !important;
  border: 1px solid rgba(203,213,225,.95) !important;
  border-radius: 16px !important;
  background-color: #fff !important;
  box-shadow: 0 10px 22px rgba(15,23,42,.035) !important;
  color: #111827 !important;
  font-size: .94rem !important;
  font-weight: 760 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-export-button,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-export-button {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  height: 50px !important;
  min-height: 50px !important;
  padding: 0 18px !important;
  border-radius: 16px !important;
  background: #fff !important;
  color: #111827 !important;
  font-size: .88rem !important;
  font-weight: 850 !important;
  white-space: nowrap !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-button-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-button-icon,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-th-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-th-icon,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-row-date-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-row-date-icon,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-row-contract-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-row-contract-icon,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-action-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-action-icon {
  display: inline-block !important;
  width: 18px !important;
  height: 18px !important;
  flex: 0 0 auto !important;
  background: currentColor !important;
  -webkit-mask: var(--history-icon) center / contain no-repeat !important;
  mask: var(--history-icon) center / contain no-repeat !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-icon-date,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-icon-date,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-row-date-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-row-date-icon {
  --history-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 2a1 1 0 0 1 1 1v1h8V3a1 1 0 1 1 2 0v1h1a3 3 0 0 1 3 3v12a3 3 0 0 1-3 3H5a3 3 0 0 1-3-3V7a3 3 0 0 1 3-3h1V3a1 1 0 0 1 1-1Zm13 8H4v9a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1v-9Z'/%3E%3C/svg%3E");
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-icon-customer,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-icon-customer {
  --history-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 12a5 5 0 1 0 0-10 5 5 0 0 0 0 10Zm-8 9a8 8 0 0 1 16 0 1 1 0 0 1-1 1H5a1 1 0 0 1-1-1Z'/%3E%3C/svg%3E");
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-icon-contract,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-icon-contract,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-row-contract-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-row-contract-icon {
  --history-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 2h9l5 5v15H6a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2Zm8 1.8V8h4.2L14 3.8ZM8 12h8v2H8v-2Zm0 4h6v2H8v-2Z'/%3E%3C/svg%3E");
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-icon-period,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-icon-period {
  --history-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 2h10a3 3 0 0 1 3 3v14a3 3 0 0 1-3 3H7a3 3 0 0 1-3-3V5a3 3 0 0 1 3-3Zm2 5h6v2H9V7Zm0 4h6v2H9v-2Zm0 4h4v2H9v-2Z'/%3E%3C/svg%3E");
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-icon-payment,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-icon-payment,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-summary-icon-wallet,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-summary-icon-wallet {
  --history-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 5a3 3 0 0 1 3-3h10a3 3 0 0 1 3 3v2h1a1 1 0 0 1 1 1v10a4 4 0 0 1-4 4H6a4 4 0 0 1-4-4V7a2 2 0 0 1 2-2Zm3-1a1 1 0 0 0-1 1h12a1 1 0 0 0-1-1H7Zm11 9a2 2 0 1 0 0 4h2v-4h-2Z'/%3E%3C/svg%3E");
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-icon-interest,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-icon-interest,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-summary-icon-interest,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-summary-icon-interest {
  --history-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 4a3 3 0 1 1 0 6 3 3 0 0 1 0-6Zm10 10a3 3 0 1 1 0 6 3 3 0 0 1 0-6ZM18.3 4.3a1 1 0 0 1 1.4 1.4l-14 14a1 1 0 0 1-1.4-1.4l14-14Z'/%3E%3C/svg%3E");
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-icon-slip,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-icon-slip {
  --history-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 2h10a2 2 0 0 1 2 2v18l-3-1.5-3 1.5-3-1.5L7 22l-3-1.5V4a2 2 0 0 1 2-2Zm2 6h6v2H9V8Zm0 4h6v2H9v-2Zm0 4h4v2H9v-2Z'/%3E%3C/svg%3E");
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-icon-export,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-icon-export {
  --history-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 3a1 1 0 1 1 2 0v9.59l3.3-3.3a1 1 0 1 1 1.4 1.42l-5 5a1 1 0 0 1-1.4 0l-5-5A1 1 0 0 1 7.7 9.3l3.3 3.29V3ZM5 19a1 1 0 0 1 1-1h12a1 1 0 1 1 0 2H6a1 1 0 0 1-1-1Z'/%3E%3C/svg%3E");
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-summary-icon-count,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-summary-icon-count {
  --history-icon: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 2h9l5 5v15H6a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2Zm8 1.8V8h4.2L14 3.8Zm-5 9.7 2 2 4-5 1.6 1.2-4.7 6a1 1 0 0 1-1.5.1l-2.8-2.8L9 13.5Z'/%3E%3C/svg%3E");
}

body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 16px !important;
  margin: 0 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile {
  position: relative !important;
  display: grid !important;
  grid-template-columns: 72px minmax(0, 1fr) !important;
  grid-template-rows: auto auto auto !important;
  align-content: center !important;
  column-gap: 20px !important;
  min-height: 134px !important;
  padding: 24px !important;
  overflow: hidden !important;
  border: 1px solid rgba(213,222,234,.9) !important;
  border-radius: 20px !important;
  background: linear-gradient(180deg, #fff 0%, #fff 72%, #fbfdff 100%) !important;
  box-shadow: 0 14px 34px rgba(15,23,42,.045) !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-summary-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-summary-icon {
  grid-column: 1 !important;
  grid-row: 1 / span 3 !important;
  display: grid !important;
  place-items: center !important;
  width: 72px !important;
  height: 72px !important;
  border-radius: 999px !important;
  align-self: center !important;
  background: #ecfdf5 !important;
  color: #059669 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-summary-icon::before,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-summary-icon::before {
  content: "" !important;
  width: 34px !important;
  height: 34px !important;
  background: currentColor !important;
  -webkit-mask: var(--history-icon) center / contain no-repeat !important;
  mask: var(--history-icon) center / contain no-repeat !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-summary-icon-wallet,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-summary-icon-wallet {
  background: #eef4ff !important;
  color: #4f7cff !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-summary-icon-interest,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-summary-icon-interest {
  background: #ecfdf5 !important;
  color: #059669 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > span:not(.history-summary-icon),
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > span:not(.history-summary-icon) {
  color: #667085 !important;
  font-size: .95rem !important;
  font-weight: 820 !important;
  line-height: 1.2 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile strong,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile strong {
  margin-top: 2px !important;
  color: #071126 !important;
  font-size: clamp(1.8rem, 2.65vw, 2.75rem) !important;
  font-weight: 900 !important;
  line-height: 1 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile small,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile small {
  margin-top: 8px !important;
  color: #667085 !important;
  font-size: .9rem !important;
  font-weight: 720 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .simple-table-wrap,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .simple-table-wrap {
  overflow: hidden !important;
  border: 1px solid rgba(213,222,234,.92) !important;
  border-radius: 22px !important;
  background: #fff !important;
  box-shadow: 0 14px 34px rgba(15,23,42,.045) !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable {
  width: 100% !important;
  min-width: 980px !important;
  table-layout: fixed !important;
  border-collapse: collapse !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable th,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable th {
  height: 58px !important;
  padding: 0 18px !important;
  border-bottom: 1px solid rgba(226,232,240,.92) !important;
  background: #fbfcff !important;
  color: #667085 !important;
  font-size: .84rem !important;
  font-weight: 850 !important;
  letter-spacing: 0 !important;
  text-align: left !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable th,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable th {
  vertical-align: middle !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable th .history-th-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable th .history-th-icon {
  margin-right: 8px !important;
  color: #71819a !important;
  vertical-align: -4px !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(1),
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(1) { width: 15% !important; }
body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(2),
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(2) { width: 19% !important; }
body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(3),
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(3) { width: 20% !important; }
body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(4),
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(4) { width: 11% !important; }
body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(5),
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(5) { width: 12% !important; }
body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(6),
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(6) { width: 11% !important; }
body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(7),
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable th:nth-child(7) { width: 12% !important; }

body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable td,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable td {
  height: 82px !important;
  padding: 14px 18px !important;
  border-bottom: 1px solid rgba(226,232,240,.92) !important;
  background: #fff !important;
  color: #071126 !important;
  font-size: .92rem !important;
  font-weight: 760 !important;
  vertical-align: middle !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable tbody tr:hover td,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable tbody tr:hover td {
  background: #fbfdff !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable .history-void-row td,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable .history-void-row td {
  background: linear-gradient(90deg, rgba(236,253,245,.9), #fff 42%) !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-date-cell,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-date-cell,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-contract-cell,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-contract-cell,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-customer,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-customer {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  min-width: 0 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-row-date-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-row-date-icon {
  color: #059669 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-row-contract-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-row-contract-icon {
  color: #71819a !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-date-copy,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-date-copy,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-customer-copy,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-customer-copy,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-contract-cell span:last-child,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-contract-cell span:last-child {
  min-width: 0 !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-date-cell strong,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-date-cell strong,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-customer strong,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-customer strong {
  display: block !important;
  color: #071126 !important;
  font-size: .92rem !important;
  font-weight: 860 !important;
  line-height: 1.18 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-date-cell span,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-date-cell span,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-customer span span,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-customer span span {
  color: #667085 !important;
  font-size: .8rem !important;
  font-weight: 700 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-customer-photo,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-customer-photo {
  position: relative !important;
  flex: 0 0 44px !important;
  width: 44px !important;
  height: 44px !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-customer-photo::after,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-customer-photo::after {
  content: "" !important;
  position: absolute !important;
  right: -2px !important;
  bottom: -2px !important;
  width: 11px !important;
  height: 11px !important;
  border: 2px solid #fff !important;
  border-radius: 999px !important;
  background: #10b981 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-customer-avatar,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-customer-avatar {
  display: grid !important;
  place-items: center !important;
  width: 44px !important;
  height: 44px !important;
  border-radius: 999px !important;
  background: #ecfdf5 !important;
  color: #047857 !important;
  object-fit: cover !important;
  font-size: .92rem !important;
  font-weight: 900 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-period-cell span,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-period-cell span {
  font-weight: 850 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-void-badge,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-void-badge {
  display: inline-flex !important;
  margin-left: 8px !important;
  padding: 5px 10px !important;
  border: 1px solid #fecaca !important;
  border-radius: 999px !important;
  background: #fef2f2 !important;
  color: #dc2626 !important;
  font-size: .74rem !important;
  font-style: normal !important;
  font-weight: 850 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-payment-amount,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-payment-amount {
  color: #059669 !important;
  font-weight: 900 !important;
  white-space: nowrap !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-payment-amount.is-negative,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-payment-amount.is-negative {
  color: #ef4444 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-interest-amount,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-interest-amount {
  color: #071126 !important;
  font-weight: 850 !important;
  white-space: nowrap !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-row-actions,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-row-actions {
  display: flex !important;
  justify-content: flex-end !important;
  gap: 10px !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-icon-button,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-icon-button {
  display: inline-grid !important;
  place-items: center !important;
  width: 44px !important;
  min-width: 44px !important;
  height: 44px !important;
  min-height: 44px !important;
  padding: 0 !important;
  border: 1px solid rgba(203,213,225,.95) !important;
  border-radius: 14px !important;
  background: #fff !important;
  color: #059669 !important;
  box-shadow: 0 8px 18px rgba(15,23,42,.04) !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-icon-button.is-disabled,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-icon-button.is-disabled {
  color: #cbd5e1 !important;
  cursor: default !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-more-button,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-more-button {
  color: #667085 !important;
  font-size: 1.25rem !important;
  line-height: 1 !important;
}

@media (max-width: 1400px) {
  body[data-page="history"]:not(.auth-locked) #historyPanel > .panel-title,
  body[data-records-subview="history"]:not(.auth-locked) #historyPanel > .panel-title {
    grid-template-columns: 1fr !important;
  }

  body[data-page="history"]:not(.auth-locked) #historyPanel > .panel-title .button-row,
  body[data-records-subview="history"]:not(.auth-locked) #historyPanel > .panel-title .button-row {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media (max-width: 1020px) {
  body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid,
  body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid {
    grid-template-columns: 1fr !important;
  }

  body[data-page="history"]:not(.auth-locked) #historyPanel .simple-table-wrap,
  body[data-records-subview="history"]:not(.auth-locked) #historyPanel .simple-table-wrap {
    overflow-x: auto !important;
  }
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control::after,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control::after {
  content: "" !important;
  position: absolute !important;
  left: 32px !important;
  right: auto !important;
  top: auto !important;
  bottom: 16px !important;
  width: 8px !important;
  height: 2px !important;
  border: 0 !important;
  border-radius: 999px !important;
  background: #94a3b8 !important;
  transform: rotate(45deg) !important;
  opacity: 1 !important;
  z-index: 1 !important;
}

/* v1.1.0-history-premium2: repair payment history table cell flow. */
body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable td.history-date-cell,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable td.history-date-cell,
body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable td.history-customer,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable td.history-customer,
body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable td.history-contract-cell,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable td.history-contract-cell,
body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable td.history-period-cell,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable td.history-period-cell,
body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable td.history-payment-amount,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable td.history-payment-amount,
body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable td.history-interest-amount,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable td.history-interest-amount,
body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable td.slip-cell,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable td.slip-cell {
  display: table-cell !important;
  vertical-align: middle !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable tbody tr,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable tbody tr {
  height: 88px !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable td,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable td {
  height: 88px !important;
  line-height: 1.25 !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-date-cell,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-date-cell,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-contract-cell,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-contract-cell {
  white-space: nowrap !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-row-date-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-row-date-icon,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-row-contract-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-row-contract-icon {
  margin-right: 10px !important;
  vertical-align: middle !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-date-copy,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-date-copy,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-customer-copy,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-customer-copy {
  display: inline-flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  vertical-align: middle !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-date-copy,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-date-copy {
  max-width: calc(100% - 34px) !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-customer-photo,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-customer-photo {
  display: inline-block !important;
  margin-right: 12px !important;
  vertical-align: middle !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-customer-copy,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-customer-copy {
  max-width: calc(100% - 62px) !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-contract-cell span:last-child,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-contract-cell span:last-child {
  display: inline-block !important;
  max-width: calc(100% - 34px) !important;
  vertical-align: middle !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-period-cell,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-period-cell {
  white-space: nowrap !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-payment-amount,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-payment-amount,
body[data-page="history"]:not(.auth-locked) #historyPanel .history-interest-amount,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-interest-amount {
  text-align: left !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .slip-cell,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .slip-cell {
  text-align: right !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-row-actions,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-row-actions {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  width: auto !important;
  max-width: 100% !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel #historyTable tbody tr:last-child td,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel #historyTable tbody tr:last-child td {
  border-bottom: 0 !important;
}

/* v1.1.0-history-premium3: match history KPI scale to repayment tracking. */
body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 14px !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile {
  display: grid !important;
  grid-template-columns: 62px minmax(96px, auto) minmax(0, 1fr) !important;
  grid-template-rows: auto auto !important;
  align-items: center !important;
  align-content: center !important;
  column-gap: 14px !important;
  min-height: 104px !important;
  padding: 18px 18px !important;
  border-radius: 22px !important;
  background: linear-gradient(180deg, #fff 0%, #fff 62%, #fbfdff 100%) !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-summary-icon,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-summary-icon {
  grid-column: 1 !important;
  grid-row: 1 / span 2 !important;
  width: 62px !important;
  height: 62px !important;
  border-radius: 22px !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .history-summary-icon::before,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .history-summary-icon::before {
  width: 28px !important;
  height: 28px !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > strong,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > strong {
  grid-column: 2 !important;
  grid-row: 1 / span 2 !important;
  align-self: center !important;
  justify-self: start !important;
  margin: 0 !important;
  color: #071126 !important;
  font-size: clamp(2.65rem, 3.15vw, 3.55rem) !important;
  font-weight: 900 !important;
  letter-spacing: 0 !important;
  line-height: .9 !important;
  white-space: nowrap !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > span:not(.history-summary-icon),
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > span:not(.history-summary-icon) {
  grid-column: 3 !important;
  grid-row: 1 !important;
  align-self: end !important;
  justify-self: start !important;
  min-width: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  color: #667085 !important;
  font-size: clamp(.98rem, 1.15vw, 1.22rem) !important;
  font-weight: 850 !important;
  line-height: 1.08 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > small,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > small {
  grid-column: 3 !important;
  grid-row: 2 !important;
  align-self: start !important;
  justify-self: start !important;
  min-width: 0 !important;
  margin: 6px 0 0 !important;
  overflow: hidden !important;
  color: #667085 !important;
  font-size: clamp(.9rem, 1.05vw, 1.08rem) !important;
  font-weight: 800 !important;
  line-height: 1.12 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

@media (max-width: 1280px) {
  body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid,
  body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid {
    grid-template-columns: 1fr !important;
  }
}

/* v1.1.0-panel-font-clean1: remove tracking header search and normalize panel typography. */
body[data-page="tracking"]:not(.auth-locked) #trackingPanel,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel,
body[data-page="history"]:not(.auth-locked) #historyPanel,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel {
  font-family: "Sarabun", "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif !important;
  letter-spacing: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel *,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel *,
body[data-page="history"]:not(.auth-locked) #historyPanel *,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel * {
  font-family: inherit !important;
  letter-spacing: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .tracking-search-control {
  display: none !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
  grid-template-columns: minmax(280px, 1fr) minmax(250px, 360px) !important;
  align-items: end !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row {
  display: grid !important;
  grid-template-columns: minmax(220px, 320px) !important;
  justify-content: end !important;
  width: 100% !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2,
body[data-page="history"]:not(.auth-locked) #historyPanel > .panel-title h2,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel > .panel-title h2 {
  color: #071126 !important;
  font-size: clamp(2.05rem, 2.55vw, 3.05rem) !important;
  font-weight: 900 !important;
  line-height: 1.06 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p,
body[data-page="history"]:not(.auth-locked) #historyPanel > .panel-title p,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel > .panel-title p {
  color: #667085 !important;
  font-size: 1rem !important;
  font-weight: 760 !important;
  line-height: 1.35 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .compact-select > span,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .compact-select > span,
body[data-page="history"]:not(.auth-locked) #historyPanel .compact-select > span,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .compact-select > span {
  color: #667085 !important;
  font-size: .86rem !important;
  font-weight: 780 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel select,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel select,
body[data-page="history"]:not(.auth-locked) #historyPanel select,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel select,
body[data-page="history"]:not(.auth-locked) #historyPanel input,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel input,
body[data-page="history"]:not(.auth-locked) #historyPanel button,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel button {
  font-weight: 760 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th,
body[data-page="history"]:not(.auth-locked) #historyPanel .simple-table th,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .simple-table th {
  color: #667085 !important;
  font-size: .88rem !important;
  font-weight: 850 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td,
body[data-page="history"]:not(.auth-locked) #historyPanel .simple-table td,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .simple-table td {
  color: #071126 !important;
  font-size: .94rem !important;
  font-weight: 760 !important;
}

@media (max-width: 1180px) {
  body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title {
    grid-template-columns: 1fr !important;
  }

  body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row,
  body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title .button-row {
    justify-content: start !important;
  }
}

/* v1.1.0-sidebar-font1: make tracking/history typography match the sidebar menu. */
body[data-page="tracking"]:not(.auth-locked) .main-content,
body[data-records-subview="tracking"]:not(.auth-locked) .main-content,
body[data-page="history"]:not(.auth-locked) .main-content,
body[data-records-subview="history"]:not(.auth-locked) .main-content,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel,
body[data-page="history"]:not(.auth-locked) #historyPanel,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel {
  font-family: "IBM Plex Sans Thai", Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  font-synthesis-weight: none !important;
  letter-spacing: 0 !important;
  -webkit-font-smoothing: antialiased !important;
  text-rendering: geometricPrecision !important;
}

body[data-page="tracking"]:not(.auth-locked) .main-content *,
body[data-records-subview="tracking"]:not(.auth-locked) .main-content *,
body[data-page="history"]:not(.auth-locked) .main-content *,
body[data-records-subview="history"]:not(.auth-locked) .main-content * {
  font-family: inherit !important;
  letter-spacing: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) .topbar-kicker,
body[data-records-subview="tracking"]:not(.auth-locked) .topbar-kicker,
body[data-page="history"]:not(.auth-locked) .topbar-kicker,
body[data-records-subview="history"]:not(.auth-locked) .topbar-kicker {
  font-weight: 700 !important;
}

body[data-page="tracking"]:not(.auth-locked) #topPageTitle,
body[data-records-subview="tracking"]:not(.auth-locked) #topPageTitle,
body[data-page="history"]:not(.auth-locked) #topPageTitle,
body[data-records-subview="history"]:not(.auth-locked) #topPageTitle,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title h2,
body[data-page="history"]:not(.auth-locked) #historyPanel > .panel-title h2,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel > .panel-title h2 {
  font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
  font-weight: 800 !important;
  line-height: 1.08 !important;
}

body[data-page="tracking"]:not(.auth-locked) #topUserName,
body[data-records-subview="tracking"]:not(.auth-locked) #topUserName,
body[data-page="history"]:not(.auth-locked) #topUserName,
body[data-records-subview="history"]:not(.auth-locked) #topUserName,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel > .panel-title p,
body[data-page="history"]:not(.auth-locked) #historyPanel > .panel-title p,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel > .panel-title p {
  font-weight: 700 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > strong,
body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > strong,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > strong {
  font-weight: 800 !important;
  letter-spacing: 0 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon):not(.tracking-kpi-trend),
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > span:not(.tracking-summary-icon):not(.tracking-kpi-trend),
body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > span:not(.history-summary-icon),
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > span:not(.history-summary-icon),
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .mini-summary-grid .summary-tile > small,
body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > small,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid .summary-tile > small {
  font-weight: 700 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table th,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table th,
body[data-page="history"]:not(.auth-locked) #historyPanel .simple-table th,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .simple-table th,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .compact-select > span,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .compact-select > span,
body[data-page="history"]:not(.auth-locked) #historyPanel .compact-select > span,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .compact-select > span {
  font-weight: 700 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td,
body[data-page="history"]:not(.auth-locked) #historyPanel .simple-table td,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .simple-table td,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel input,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel input,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel select,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel select,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel button,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel button,
body[data-page="history"]:not(.auth-locked) #historyPanel input,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel input,
body[data-page="history"]:not(.auth-locked) #historyPanel select,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel select,
body[data-page="history"]:not(.auth-locked) #historyPanel button,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel button {
  font-weight: 600 !important;
}

body[data-page="tracking"]:not(.auth-locked) #trackingPanel .simple-table td strong,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .simple-table td strong,
body[data-page="history"]:not(.auth-locked) #historyPanel .simple-table td strong,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .simple-table td strong,
body[data-page="tracking"]:not(.auth-locked) #trackingPanel .status-pill,
body[data-records-subview="tracking"]:not(.auth-locked) #trackingPanel .status-pill,
body[data-page="history"]:not(.auth-locked) #historyPanel .status-pill,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .status-pill {
  font-weight: 700 !important;
}

/* v1.1.0-history-label-gap1: remove duplicate history labels and breathe between KPIs/table. */
body[data-page="history"]:not(.auth-locked) .workspace::before,
body[data-page="history"]:not(.auth-locked) .main-content::before,
body[data-records-subview="history"]:not(.auth-locked) .workspace::before,
body[data-records-subview="history"]:not(.auth-locked) .main-content::before {
  content: none !important;
  display: none !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .mini-summary-grid,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .mini-summary-grid {
  margin-bottom: 24px !important;
}

body[data-page="history"]:not(.auth-locked) #historyPanel .simple-table-wrap,
body[data-records-subview="history"]:not(.auth-locked) #historyPanel .simple-table-wrap {
  margin-top: 0 !important;
}

/* v1.1.0-user-audit1: owner-only user activity report from last-login cells. */
body[data-page="account"] .users-last-login-button,
body:not(.auth-locked) .account-settings-page .users-last-login-button {
  display: inline-flex !important;
  width: fit-content !important;
  max-width: 100% !important;
  min-height: 34px !important;
  align-items: center !important;
  justify-content: flex-start !important;
  padding: 0 10px !important;
  border: 1px solid transparent !important;
  border-radius: 10px !important;
  background: transparent !important;
  color: #64748b !important;
  font: inherit !important;
  font-size: .82rem !important;
  font-weight: 700 !important;
  line-height: 1.35 !important;
  text-align: left !important;
  white-space: normal !important;
  cursor: pointer !important;
}

body[data-page="account"] .users-last-login-button:hover,
body:not(.auth-locked) .account-settings-page .users-last-login-button:hover {
  border-color: #bbf7d0 !important;
  background: #ecfdf5 !important;
  color: #047857 !important;
}

.user-activity-report-text {
  display: block !important;
  width: 100% !important;
  max-height: min(68vh, 720px) !important;
  overflow: auto !important;
  margin: 0 !important;
  padding: 18px !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 16px !important;
  background: #f8fafc !important;
  color: #0f172a !important;
  font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
  font-size: .98rem !important;
  font-weight: 600 !important;
  line-height: 1.75 !important;
  white-space: pre-wrap !important;
}

/* v1.1.0-loan-modal-stack1: keep the offline loan form above the dashboard header. */
body.loan-form-open:not(.auth-locked) .workspace {
  position: relative !important;
  z-index: 7000 !important;
}

body.loan-form-open:not(.auth-locked) .app-topbar,
body.loan-form-open:not(.auth-locked) .app-topbar.page-header,
body.loan-form-open:not(.auth-locked) .app-topbar.topbar {
  z-index: 0 !important;
  pointer-events: none !important;
}

body.loan-form-open:not(.auth-locked) #loanFormModal.form-modal,
#loanFormModal.form-modal:not(.hidden) {
  position: fixed !important;
  inset: 0 !important;
  z-index: 7100 !important;
}

body.loan-form-open:not(.auth-locked) #loanFormModal .loan-form-dialog {
  position: relative !important;
  z-index: 7101 !important;
}

/* v1.1.0-mobile-dashboard1: mobile-only dashboard order and bottom navigation repair. */
@media (max-width: 768px) {
  body:not(.auth-locked) {
    padding-bottom: calc(90px + env(safe-area-inset-bottom)) !important;
    overflow-x: hidden !important;
  }

  body:not(.auth-locked) .app-shell,
  body:not(.auth-locked) .app-shell.loan-app {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  body:not(.auth-locked) .content-shell,
  body:not(.auth-locked) .content-shell.main-content,
  body:not(.auth-locked) .main-content,
  body:not(.auth-locked) .main-area,
  body:not(.auth-locked) .content-area {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    padding: 10px 10px calc(94px + env(safe-area-inset-bottom)) !important;
    overflow-x: hidden !important;
  }

  body:not(.auth-locked) .quick-nav,
  body:not(.auth-locked) .quick-nav.sidebar,
  body:not(.auth-locked) .quick-nav.app-sidebar,
  body[data-page]:not(.auth-locked) .quick-nav,
  body.mobile-mode:not(.auth-locked) .quick-nav {
    position: fixed !important;
    inset: auto 8px calc(8px + env(safe-area-inset-bottom)) 8px !important;
    z-index: 6800 !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    height: 66px !important;
    min-height: 66px !important;
    max-height: 66px !important;
    display: grid !important;
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    align-items: center !important;
    gap: 4px !important;
    padding: 6px !important;
    overflow: hidden !important;
    border: 1px solid #dbe3ef !important;
    border-radius: 22px !important;
    background: rgba(255, 255, 255, .98) !important;
    box-shadow: 0 14px 36px rgba(15, 23, 42, .16) !important;
    backdrop-filter: blur(18px) !important;
    transform: none !important;
  }

  body:not(.auth-locked) .quick-nav > *,
  body[data-page]:not(.auth-locked) .quick-nav > *,
  body:not(.auth-locked) .quick-nav .side-brand,
  body:not(.auth-locked) .quick-nav .sidebar-brand,
  body:not(.auth-locked) .quick-nav .nav-collapse-button,
  body:not(.auth-locked) .quick-nav .side-user,
  body:not(.auth-locked) .quick-nav .customer-nav-group,
  body:not(.auth-locked) .quick-nav .account-nav-group,
  body:not(.auth-locked) .quick-nav .settings-nav-group {
    display: none !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"],
  body:not(.auth-locked) .quick-nav > .mobile-records-link,
  body:not(.auth-locked) .quick-nav > .mobile-tracking-link,
  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link,
  body:not(.auth-locked) .quick-nav .mobile-create-nav {
    display: grid !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] {
    order: 1 !important;
  }

  body:not(.auth-locked) .quick-nav > .mobile-records-link {
    order: 2 !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-create-nav {
    order: 3 !important;
  }

  body:not(.auth-locked) .quick-nav > .mobile-tracking-link {
    order: 4 !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link {
    order: 5 !important;
  }

  body:not(.auth-locked) .quick-nav a,
  body:not(.auth-locked) .quick-nav .sidebar-link,
  body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
  body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .mobile-create-nav,
  body[data-page]:not(.auth-locked) .quick-nav a,
  body[data-page]:not(.auth-locked) .quick-nav .sidebar-link,
  body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
  body[data-page]:not(.auth-locked) .quick-nav .mobile-create-nav {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    height: 54px !important;
    min-height: 54px !important;
    max-height: 54px !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: 26px 14px !important;
    align-items: center !important;
    justify-items: center !important;
    justify-content: center !important;
    gap: 2px !important;
    margin: 0 !important;
    padding: 4px 2px !important;
    border: 0 !important;
    border-radius: 16px !important;
    background: transparent !important;
    color: #64748b !important;
    box-shadow: none !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 10px !important;
    font-weight: 600 !important;
    line-height: 1.05 !important;
    text-align: center !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-decoration: none !important;
    transform: none !important;
  }

  body:not(.auth-locked) .quick-nav .nav-icon,
  body:not(.auth-locked) .quick-nav .settings-gear,
  body[data-page]:not(.auth-locked) .quick-nav .nav-icon,
  body[data-page]:not(.auth-locked) .quick-nav .settings-gear {
    display: grid !important;
    width: 26px !important;
    height: 26px !important;
    min-width: 26px !important;
    place-items: center !important;
    border-radius: 10px !important;
    background: transparent !important;
    color: currentColor !important;
  }

  body:not(.auth-locked) .quick-nav .nav-icon svg,
  body:not(.auth-locked) .quick-nav .settings-gear svg {
    width: 21px !important;
    height: 21px !important;
  }

  body:not(.auth-locked) .quick-nav .nav-dot,
  body[data-page]:not(.auth-locked) .quick-nav .nav-dot {
    display: none !important;
  }

  body:not(.auth-locked) .quick-nav .nav-label,
  body:not(.auth-locked) .quick-nav .nav-group-items .nav-label,
  body[data-page]:not(.auth-locked) .quick-nav .nav-label,
  body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .nav-label {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 14px !important;
    max-height: 14px !important;
    overflow: hidden !important;
    color: inherit !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 10px !important;
    font-weight: 600 !important;
    line-height: 1.15 !important;
    text-align: center !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  body:not(.auth-locked) .quick-nav a.active,
  body:not(.auth-locked) .quick-nav .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .mobile-create-nav[aria-expanded="true"],
  body[data-page]:not(.auth-locked) .quick-nav a.active {
    background: #ecfdf5 !important;
    color: #047857 !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-create-nav {
    background: linear-gradient(180deg, #10b981 0%, #059669 100%) !important;
    color: #fff !important;
    border-radius: 18px !important;
    box-shadow: 0 10px 24px rgba(16, 185, 129, .3) !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-create-nav .nav-label {
    color: #fff !important;
  }

  body:not(.auth-locked) #dashboardPanel.dashboard-page {
    display: flex !important;
    flex-direction: column !important;
    gap: 14px !important;
  }

  body:not(.auth-locked) #dashboardPanel .dashboard-top-row {
    display: contents !important;
  }

  body:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-hero {
    order: 1 !important;
  }

  body:not(.auth-locked) #dashboardPanel .dashboard-menu-section {
    order: 2 !important;
  }

  body:not(.auth-locked) #dashboardPanel .dashboard-work-panel {
    order: 3 !important;
  }

  body:not(.auth-locked) #dashboardPanel > .summary-grid {
    order: 4 !important;
  }

  body:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-filter-panel,
  body:not(.auth-locked) #dashboardPanel > .dashboard-filter-panel {
    order: 5 !important;
    width: 100% !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 20px !important;
    border-radius: 22px !important;
  }

  body:not(.auth-locked) #dashboardPanel .dashboard-analytics-grid,
  body:not(.auth-locked) #dashboardPanel > .dashboard-analytics-grid {
    order: 6 !important;
  }

  body:not(.auth-locked) #dashboardPanel .dashboard-filter-panel .dashboard-panel-heading {
    gap: 12px !important;
    font-size: 1.05rem !important;
  }

  body:not(.auth-locked) #dashboardPanel .dashboard-filter-panel .dashboard-panel-heading span {
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    border-radius: 13px !important;
  }

  body:not(.auth-locked) #dashboardPanel .dashboard-filters {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }

  body:not(.auth-locked) #dashboardPanel .dashboard-filters label,
  body:not(.auth-locked) #dashboardPanel .dashboard-filters select,
  body:not(.auth-locked) #dashboardPanel .dashboard-filters input {
    width: 100% !important;
  }
}

/* v1.1.0-mobile-action-sheet3: make the mobile navigation a docked tab bar, not a floating pill. */
@media (max-width: 768px) {
  body:not(.auth-locked) {
    padding-bottom: calc(82px + env(safe-area-inset-bottom)) !important;
  }

  body:not(.auth-locked) .quick-nav,
  body:not(.auth-locked) .quick-nav.sidebar,
  body:not(.auth-locked) .quick-nav.app-sidebar,
  body[data-page]:not(.auth-locked) .quick-nav,
  body.mobile-mode:not(.auth-locked) .quick-nav {
    inset: auto 0 0 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    height: calc(74px + env(safe-area-inset-bottom)) !important;
    min-height: calc(74px + env(safe-area-inset-bottom)) !important;
    max-height: calc(74px + env(safe-area-inset-bottom)) !important;
    padding: 7px max(10px, env(safe-area-inset-right)) calc(7px + env(safe-area-inset-bottom)) max(10px, env(safe-area-inset-left)) !important;
    border-width: 1px 0 0 0 !important;
    border-style: solid !important;
    border-color: #dbe3ef !important;
    border-radius: 0 !important;
    background: rgba(255, 255, 255, .99) !important;
    box-shadow: 0 -8px 22px rgba(15, 23, 42, .08) !important;
    backdrop-filter: blur(14px) !important;
    -webkit-backdrop-filter: blur(14px) !important;
  }

  body:not(.auth-locked) .quick-nav a,
  body:not(.auth-locked) .quick-nav .sidebar-link,
  body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
  body:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link.active,
  body:not(.auth-locked) .quick-nav .mobile-create-nav,
  body[data-page]:not(.auth-locked) .quick-nav a,
  body[data-page]:not(.auth-locked) .quick-nav .sidebar-link,
  body[data-page]:not(.auth-locked) .quick-nav .nav-group-items .sidebar-link,
  body[data-page]:not(.auth-locked) .quick-nav .mobile-create-nav {
    height: 58px !important;
    min-height: 58px !important;
    max-height: 58px !important;
    border-radius: 14px !important;
    align-self: center !important;
    transform: none !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-create-nav,
  body.mobile-mode:not(.auth-locked) .quick-nav .mobile-create-nav,
  body[data-page]:not(.auth-locked) .quick-nav .mobile-create-nav {
    width: 100% !important;
    height: 58px !important;
    min-height: 58px !important;
    max-height: 58px !important;
    border-radius: 14px !important;
    box-shadow: none !important;
    transform: none !important;
  }

  body:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav,
  body:not(.auth-locked) .quick-nav .mobile-create-nav#mobileCreateNav,
  body.mobile-mode:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav,
  body[data-page]:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav {
    display: grid !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    height: 58px !important;
    min-height: 58px !important;
    max-height: 58px !important;
    margin: 0 !important;
    padding: 4px 2px !important;
    border-radius: 14px !important;
    box-shadow: none !important;
    transform: none !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-create-nav .nav-icon {
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
    border-radius: 10px !important;
  }
}

/* v1.1.0-mobile-action-sheet3: slide the + menu up as a mobile bottom sheet. */
@media (max-width: 768px) {
  body:not(.auth-locked) .mobile-action-backdrop,
  body[data-page]:not(.auth-locked) .mobile-action-backdrop {
    position: fixed !important;
    inset: 0 !important;
    z-index: 7200 !important;
    display: block !important;
    background: rgba(15, 23, 42, .42) !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transition: opacity .22s ease, visibility .22s ease !important;
  }

  body:not(.auth-locked) .mobile-action-menu,
  body[data-page]:not(.auth-locked) .mobile-action-menu {
    position: fixed !important;
    left: 10px !important;
    right: 10px !important;
    bottom: 0 !important;
    z-index: 7210 !important;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
    padding: 18px 12px calc(18px + env(safe-area-inset-bottom)) !important;
    border: 1px solid #dbe3ef !important;
    border-bottom: 0 !important;
    border-radius: 28px 28px 0 0 !important;
    background: #fff !important;
    box-shadow: 0 -18px 48px rgba(15, 23, 42, .20) !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: none !important;
    transform: translateY(112%) !important;
    transition: transform .28s cubic-bezier(.22, 1, .36, 1), box-shadow .28s ease !important;
    will-change: transform !important;
  }

  body.mobile-action-open:not(.auth-locked) .mobile-action-backdrop,
  body.mobile-action-open[data-page]:not(.auth-locked) .mobile-action-backdrop {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
  }

  body.mobile-action-open:not(.auth-locked) .mobile-action-menu,
  body.mobile-action-open[data-page]:not(.auth-locked) .mobile-action-menu {
    pointer-events: auto !important;
    transform: translateY(0) !important;
  }

  body.mobile-action-open:not(.auth-locked) .quick-nav,
  body.mobile-action-open[data-page]:not(.auth-locked) .quick-nav {
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transform: translateY(100%) !important;
  }

  body:not(.auth-locked) .mobile-action-menu a,
  body:not(.auth-locked) .mobile-action-menu button,
  body[data-page]:not(.auth-locked) .mobile-action-menu a,
  body[data-page]:not(.auth-locked) .mobile-action-menu button {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    min-width: 0 !important;
    min-height: 58px !important;
    padding: 0 12px !important;
    border: 1px solid #dbe3ef !important;
    border-radius: 18px !important;
    background: #fff !important;
    color: #0f172a !important;
    box-shadow: none !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 17px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    letter-spacing: 0 !important;
    text-align: center !important;
    text-decoration: none !important;
    white-space: nowrap !important;
  }

  body:not(.auth-locked) .mobile-action-menu a:active,
  body:not(.auth-locked) .mobile-action-menu button:active {
    background: #f8fafc !important;
    transform: translateY(1px) !important;
  }
}

/* v1.1.0-mobile-action-sheet3: keep the bottom nav visible and park the sheet above it. */
@media (max-width: 768px) {
  body:not(.auth-locked) .mobile-action-backdrop,
  body[data-page]:not(.auth-locked) .mobile-action-backdrop {
    z-index: 6760 !important;
  }

  body:not(.auth-locked) .mobile-action-menu,
  body[data-page]:not(.auth-locked) .mobile-action-menu {
    bottom: calc(74px + env(safe-area-inset-bottom)) !important;
    z-index: 6900 !important;
    padding: 18px 12px 24px !important;
    border-radius: 28px 28px 0 0 !important;
    transform: translateY(calc(100% + 74px + env(safe-area-inset-bottom))) !important;
  }

  body.mobile-action-open:not(.auth-locked) .mobile-action-menu,
  body.mobile-action-open[data-page]:not(.auth-locked) .mobile-action-menu {
    transform: translateY(0) !important;
  }

  body.mobile-action-open:not(.auth-locked) .quick-nav,
  body.mobile-action-open[data-page]:not(.auth-locked) .quick-nav {
    z-index: 6950 !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transform: none !important;
  }
}

/* v1.1.0-mobile-records-only1: mobile customer tab shows only the debtor list card. */
@media (max-width: 768px) {
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) .app-topbar,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) .workspace::before,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) .page-header {
    display: none !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) .main-content {
    padding: 12px 12px calc(96px + env(safe-area-inset-bottom)) !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) .main-content > .panel:not(#recordsPanel),
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #dashboardPanel,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #loanSection,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #contractPanel,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #customerProfilesPanel,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #lineLeadsPanel,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #lineOaPanel,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #trackingPanel,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #historyPanel {
    display: none !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel {
    display: block !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 24px 14px 26px !important;
    border: 1px solid #dbe3ef !important;
    border-radius: 22px !important;
    background: #fff !important;
    box-shadow: 0 18px 42px rgba(15, 23, 42, .08) !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel::before {
    content: "ลูกหนี้";
    display: block !important;
    margin: 0 0 12px !important;
    color: #334155 !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 1.7rem !important;
    font-weight: 800 !important;
    line-height: 1.1 !important;
    letter-spacing: 0 !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel > .panel-title,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsSubnav,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .records-table-wrap {
    display: none !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordSearchBox {
    display: grid !important;
    gap: 12px !important;
    margin: 0 0 20px !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordSearchBox span {
    display: block !important;
    color: #64748b !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 1.32rem !important;
    font-weight: 600 !important;
    line-height: 1.15 !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordSearch {
    width: 100% !important;
    min-height: 58px !important;
    padding: 0 18px !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 22px !important;
    background: #fff !important;
    color: #0f172a !important;
    box-shadow: none !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 1.08rem !important;
    font-weight: 600 !important;
    line-height: 1.2 !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordSearch::placeholder {
    color: #737373 !important;
    opacity: 1 !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList {
    display: block !important;
    margin: 0 !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-list {
    display: grid !important;
    gap: 14px !important;
    margin: 0 !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-card {
    display: block !important;
    min-height: 92px !important;
    overflow: hidden !important;
    border: 1px solid #dbe3ef !important;
    border-radius: 22px !important;
    background: #fff !important;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .04) !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-collapse > summary {
    min-height: 92px !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 52px !important;
    align-items: center !important;
    gap: 12px !important;
    padding: 14px 14px 14px 18px !important;
    cursor: pointer !important;
    list-style: none !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-collapse > summary::-webkit-details-marker {
    display: none !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-collapse:not([open]) .mobile-debtor-body {
    display: none !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-collapse[open] .mobile-debtor-body {
    display: grid !important;
    gap: 12px !important;
    padding: 0 14px 16px !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-summary-main {
    min-width: 0 !important;
    display: block !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .record-name-button {
    width: 100% !important;
    min-width: 0 !important;
    display: grid !important;
    grid-template-columns: 58px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 16px !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    pointer-events: none !important;
    text-align: left !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .customer-mini-avatar {
    width: 58px !important;
    height: 58px !important;
    min-width: 58px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 999px !important;
    background: #e9fbf5 !important;
    color: #64748b !important;
    object-fit: cover !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 1.18rem !important;
    font-weight: 800 !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .record-name-button strong {
    display: block !important;
    max-width: 100% !important;
    overflow: hidden !important;
    color: #334155 !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 1.28rem !important;
    font-weight: 700 !important;
    line-height: 1.15 !important;
    letter-spacing: 0 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .record-name-button small,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .customer-channel-badge,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-card-facts,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .record-line-meta,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .record-origin-badge,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .record-contract-mini,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .customer-line-id {
    display: none !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-summary-toggle {
    display: grid !important;
    width: 46px !important;
    height: 46px !important;
    min-width: 46px !important;
    place-items: center !important;
    justify-self: end !important;
    border-radius: 999px !important;
    background: #ecfdf5 !important;
    color: transparent !important;
    font-size: 0 !important;
    font-weight: 800 !important;
    transform: none !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-summary-toggle::before {
    content: "⌄";
    color: #047857 !important;
    font-size: 1.34rem !important;
    line-height: 1 !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-collapse[open] .mobile-debtor-summary-toggle::before {
    content: "⌃";
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-facts {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
    padding: 12px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 18px !important;
    background: #f8fafc !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-facts div {
    display: grid !important;
    gap: 4px !important;
    min-width: 0 !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-facts span {
    color: #64748b !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: .78rem !important;
    font-weight: 600 !important;
    line-height: 1.2 !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-facts strong {
    min-width: 0 !important;
    overflow: hidden !important;
    color: #0f172a !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: .94rem !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-primary-actions {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-primary-actions button,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-more > summary,
  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-actions button {
    min-height: 46px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 12px !important;
    border-radius: 15px !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: .95rem !important;
    font-weight: 700 !important;
    line-height: 1.15 !important;
    white-space: nowrap !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-more {
    display: block !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-more > summary {
    list-style: none !important;
    border: 1px solid #dbe3ef !important;
    background: #fff !important;
    color: #334155 !important;
    cursor: pointer !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-more > summary::-webkit-details-marker {
    display: none !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-more[open] > summary {
    margin-bottom: 10px !important;
    background: #f8fafc !important;
  }

  body[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsList .mobile-debtor-actions {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
  }
}

/* v1.1.0-mobile-dashboard-premium1: dashboard redesign for mobile only. */
.dashboard-mobile-date,
.dashboard-mobile-followup,
.dashboard-action-copy small,
.dashboard-action-chevron {
  display: none;
}

@media (max-width: 768px) {
  body[data-page="dashboard"]:not(.auth-locked) {
    background:
      radial-gradient(circle at 18% 0%, rgba(255, 255, 255, .95), transparent 34%),
      linear-gradient(180deg, #f8fafc 0%, #f3f6fb 100%) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .content-shell,
  body[data-page="dashboard"]:not(.auth-locked) .content-shell.main-content,
  body[data-page="dashboard"]:not(.auth-locked) .main-content,
  body[data-page="dashboard"]:not(.auth-locked) .content-area {
    padding: 16px 14px calc(112px + env(safe-area-inset-bottom)) !important;
    background: transparent !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .hero,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-menu-section,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-filter-panel,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-analytics-grid {
    display: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .app-topbar,
  body[data-page="dashboard"]:not(.auth-locked) .app-topbar.page-header,
  body[data-page="dashboard"]:not(.auth-locked) .topbar {
    position: static !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 48px 48px !important;
    align-items: center !important;
    gap: 12px !important;
    width: 100% !important;
    min-height: 74px !important;
    margin: 0 0 16px !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    overflow: visible !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .app-topbar-title {
    display: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .global-search {
    position: relative !important;
    grid-column: 1 !important;
    display: block !important;
    width: 100% !important;
    height: 56px !important;
    min-width: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 18px !important;
    background: rgba(255, 255, 255, .96) !important;
    box-shadow: 0 12px 30px rgba(15, 23, 42, .08) !important;
    overflow: hidden !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .global-search::before {
    content: "" !important;
    position: absolute !important;
    left: 18px !important;
    top: 50% !important;
    width: 22px !important;
    height: 22px !important;
    background: #111827 !important;
    opacity: .82 !important;
    transform: translateY(-50%) !important;
    -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10.8 18.1a7.3 7.3 0 1 1 0-14.6 7.3 7.3 0 0 1 0 14.6Zm0-2.4a4.9 4.9 0 1 0 0-9.8 4.9 4.9 0 0 0 0 9.8Zm5.3.7 4.1 4.1-1.7 1.7-4.1-4.1 1.7-1.7Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
    mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10.8 18.1a7.3 7.3 0 1 1 0-14.6 7.3 7.3 0 0 1 0 14.6Zm0-2.4a4.9 4.9 0 1 0 0-9.8 4.9 4.9 0 0 0 0 9.8Zm5.3.7 4.1 4.1-1.7 1.7-4.1-4.1 1.7-1.7Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .global-search input {
    width: 100% !important;
    height: 100% !important;
    padding: 0 18px 0 52px !important;
    border: 0 !important;
    background: transparent !important;
    color: #0f172a !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 16px !important;
    font-weight: 500 !important;
    line-height: 1 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .global-search input::placeholder {
    color: #4b5563 !important;
    opacity: .9 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .topbar-actions {
    display: contents !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .notification-button {
    position: relative !important;
    grid-column: 2 !important;
    display: grid !important;
    width: 48px !important;
    height: 48px !important;
    min-width: 48px !important;
    place-items: center !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 50% !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #0f172a !important;
    font-size: 0 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .notification-button::before {
    content: "" !important;
    width: 31px !important;
    height: 31px !important;
    background: currentColor !important;
    -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 22a2.8 2.8 0 0 0 2.65-1.9h-5.3A2.8 2.8 0 0 0 12 22Zm7-5.6-1.5-2.1V10a5.5 5.5 0 0 0-4.2-5.35V3a1.3 1.3 0 1 0-2.6 0v1.65A5.5 5.5 0 0 0 6.5 10v4.3L5 16.4V18h14v-1.6ZM8.5 16v-6a3.5 3.5 0 1 1 7 0v6h-7Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
    mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 22a2.8 2.8 0 0 0 2.65-1.9h-5.3A2.8 2.8 0 0 0 12 22Zm7-5.6-1.5-2.1V10a5.5 5.5 0 0 0-4.2-5.35V3a1.3 1.3 0 1 0-2.6 0v1.65A5.5 5.5 0 0 0 6.5 10v4.3L5 16.4V18h14v-1.6ZM8.5 16v-6a3.5 3.5 0 1 1 7 0v6h-7Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .notification-button::after {
    content: "" !important;
    position: absolute !important;
    top: 8px !important;
    right: 9px !important;
    width: 9px !important;
    height: 9px !important;
    border: 2px solid #f8fafc !important;
    border-radius: 50% !important;
    background: #ef4444 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .topbar-user {
    grid-column: 3 !important;
    display: grid !important;
    width: 48px !important;
    height: 48px !important;
    min-width: 48px !important;
    place-items: center !important;
    border-radius: 50% !important;
    background: linear-gradient(180deg, #bbf7d0 0%, #34d399 100%) !important;
    color: #047857 !important;
    font-size: 0 !important;
    box-shadow: 0 12px 24px rgba(16, 185, 129, .16) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .topbar-user::before {
    content: "" !important;
    width: 28px !important;
    height: 28px !important;
    background: currentColor !important;
    -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 12.4a4.4 4.4 0 1 0 0-8.8 4.4 4.4 0 0 0 0 8.8Zm-8 8a8 8 0 0 1 16 0V21H4v-.6Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
    mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 12.4a4.4 4.4 0 1 0 0-8.8 4.4 4.4 0 0 0 0 8.8Zm-8 8a8 8 0 0 1 16 0V21H4v-.6Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel.dashboard-page {
    display: flex !important;
    flex-direction: column !important;
    gap: 18px !important;
    padding: 0 !important;
    overflow: visible !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row {
    display: contents !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero {
    order: 1 !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 8px 4px 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero > div {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    align-items: end !important;
    gap: 4px 10px !important;
    width: 100% !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero .eyebrow {
    display: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2 {
    grid-column: 1 !important;
    margin: 0 !important;
    color: #0f172a !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: clamp(34px, 10vw, 44px) !important;
    font-weight: 800 !important;
    line-height: .98 !important;
    letter-spacing: 0 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint {
    grid-column: 1 !important;
    margin: 6px 0 14px !important;
    color: #64748b !important;
    font-size: 0 !important;
    line-height: 1.25 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint::after {
    content: "สวัสดีครับ, Admin" !important;
    font-size: 15px !important;
    font-weight: 600 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-date {
    grid-column: 2 !important;
    grid-row: 1 / span 2 !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 7px !important;
    align-self: center !important;
    color: #64748b !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    white-space: nowrap !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-date::before {
    content: "" !important;
    width: 17px !important;
    height: 17px !important;
    background: currentColor !important;
    -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 2h2v3h6V2h2v3h3v17H4V5h3V2Zm11 8H6v10h12V10Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
    mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 2h2v3h6V2h2v3h3v17H4V5h3V2Zm11 8H6v10h12V10Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions {
    grid-column: 1 / -1 !important;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 12px !important;
    margin: 10px 0 4px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions button {
    display: grid !important;
    grid-template-columns: 54px minmax(0, 1fr) 14px !important;
    align-items: center !important;
    gap: 10px !important;
    min-height: 92px !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 16px 12px !important;
    border: 0 !important;
    border-radius: 14px !important;
    background: rgba(255, 255, 255, .96) !important;
    box-shadow: 0 12px 26px rgba(15, 23, 42, .06) !important;
    color: #0f172a !important;
    text-align: left !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-button-icon {
    display: grid !important;
    width: 52px !important;
    height: 52px !important;
    min-width: 52px !important;
    place-items: center !important;
    border-radius: 50% !important;
    background: #dcfce7 !important;
    color: #0f172a !important;
    font-size: 14px !important;
    font-weight: 800 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .plus-icon::before {
    content: "" !important;
    width: 30px !important;
    height: 30px !important;
    background: currentColor !important;
    -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M9.8 12.2a4.2 4.2 0 1 0 0-8.4 4.2 4.2 0 0 0 0 8.4Zm0 2.2c-3.6 0-6.6 2.3-7.1 5.3H13v-2.8h2.8v-2.5h-6Zm8.6 1.1h-2.8v2.8h-2.8v2.4h2.8v2.8h2.8v-2.8h2.8v-2.4h-2.8v-2.8Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
    mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M9.8 12.2a4.2 4.2 0 1 0 0-8.4 4.2 4.2 0 0 0 0 8.4Zm0 2.2c-3.6 0-6.6 2.3-7.1 5.3H13v-2.8h2.8v-2.5h-6Zm8.6 1.1h-2.8v2.8h-2.8v2.4h2.8v2.8h2.8v-2.8h2.8v-2.4h-2.8v-2.8Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .line-icon {
    background: linear-gradient(180deg, #3fe26a 0%, #06b847 100%) !important;
    color: #fff !important;
    font-size: 11px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy {
    display: block !important;
    min-width: 0 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy strong {
    display: block !important;
    overflow: hidden !important;
    color: #0f172a !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 16px !important;
    font-weight: 800 !important;
    line-height: 1.15 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy small {
    display: block !important;
    margin-top: 3px !important;
    overflow: hidden !important;
    color: #64748b !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    line-height: 1.2 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-chevron {
    display: block !important;
    color: #64748b !important;
    font-size: 28px !important;
    font-weight: 400 !important;
    line-height: 1 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel {
    order: 2 !important;
    position: relative !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 118px !important;
    grid-template-rows: auto 1fr auto !important;
    gap: 10px 10px !important;
    min-height: 294px !important;
    margin: 0 !important;
    padding: 28px 24px 22px !important;
    overflow: hidden !important;
    border: 1px solid #a7f3d0 !important;
    border-radius: 16px !important;
    background:
      radial-gradient(circle at 95% 35%, rgba(52, 211, 153, .12), transparent 30%),
      linear-gradient(135deg, #f0fdf4 0%, #f8fffb 62%, #eafbf2 100%) !important;
    box-shadow: 0 16px 30px rgba(15, 23, 42, .05) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel > div:first-child {
    grid-column: 1 / -1 !important;
    grid-row: 1 / 3 !important;
    align-self: start !important;
    max-width: 68% !important;
    z-index: 2 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .dashboard-work-kicker {
    display: inline-flex !important;
    align-items: center !important;
    width: fit-content !important;
    margin: 0 0 20px !important;
    padding: 8px 16px !important;
    border-radius: 999px !important;
    background: #dcfce7 !important;
    color: #047857 !important;
    font-size: 16px !important;
    font-weight: 800 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel strong {
    display: block !important;
    max-width: 320px !important;
    color: #0f172a !important;
    font-size: clamp(30px, 8vw, 42px) !important;
    font-weight: 800 !important;
    line-height: 1.12 !important;
    letter-spacing: 0 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel small {
    display: block !important;
    margin-top: 8px !important;
    color: #64748b !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    line-height: 1.35 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel small strong,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel small em {
    color: #059669 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .dashboard-work-art {
    grid-column: 2 !important;
    grid-row: 1 / 3 !important;
    position: relative !important;
    display: block !important;
    width: 118px !important;
    height: 118px !important;
    align-self: center !important;
    justify-self: end !important;
    opacity: 1 !important;
    transform: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .work-art-calendar {
    position: absolute !important;
    right: 12px !important;
    top: 18px !important;
    width: 78px !important;
    height: 88px !important;
    border-radius: 12px !important;
    background: #fff !important;
    box-shadow: 0 12px 24px rgba(15, 23, 42, .12) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .work-art-calendar::before {
    content: "" !important;
    position: absolute !important;
    inset: 0 0 auto 0 !important;
    height: 28px !important;
    border-radius: 12px 12px 0 0 !important;
    background: #34d399 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .work-art-calendar::after {
    content: "" !important;
    position: absolute !important;
    left: 14px !important;
    top: 42px !important;
    width: 12px !important;
    height: 12px !important;
    border-radius: 3px !important;
    background: #e2e8f0 !important;
    box-shadow: 26px 0 0 #e2e8f0, 0 24px 0 #ef4444, 26px 24px 0 #e2e8f0 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .work-art-bell {
    position: absolute !important;
    right: 0 !important;
    bottom: 8px !important;
    width: 54px !important;
    height: 54px !important;
    border-radius: 50% !important;
    background: #ef4444 !important;
    box-shadow: 0 10px 22px rgba(239, 68, 68, .22) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .work-art-bell::before {
    content: "!" !important;
    position: absolute !important;
    inset: 0 !important;
    display: grid !important;
    place-items: center !important;
    color: #fff !important;
    font-size: 34px !important;
    font-weight: 800 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel::after {
    content: "" !important;
    position: absolute !important;
    right: 118px !important;
    bottom: 88px !important;
    width: 50px !important;
    height: 14px !important;
    border-radius: 999px !important;
    background: #fbbf24 !important;
    box-shadow: 12px 12px 0 #f59e0b, -8px 24px 0 #fbbf24 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .primary-button {
    grid-column: 1 / -1 !important;
    grid-row: 3 !important;
    z-index: 3 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    min-height: 58px !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 10px !important;
    background: linear-gradient(180deg, #10b981 0%, #059669 100%) !important;
    color: #fff !important;
    box-shadow: 0 16px 32px rgba(5, 150, 105, .24) !important;
    font-size: 19px !important;
    font-weight: 800 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid {
    order: 3 !important;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 18px !important;
    width: 100% !important;
    margin: 0 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile:nth-child(n+3) {
    display: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile {
    display: grid !important;
    grid-template-columns: 58px minmax(0, 1fr) !important;
    grid-template-rows: auto auto auto !important;
    align-items: center !important;
    column-gap: 14px !important;
    min-height: 152px !important;
    padding: 18px !important;
    border: 0 !important;
    border-radius: 14px !important;
    background: rgba(255, 255, 255, .96) !important;
    box-shadow: 0 12px 28px rgba(15, 23, 42, .06) !important;
    text-align: left !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile-icon {
    grid-column: 1 !important;
    grid-row: 1 / span 3 !important;
    display: grid !important;
    width: 58px !important;
    height: 58px !important;
    min-width: 58px !important;
    place-items: center !important;
    border-radius: 50% !important;
    background: #dcfce7 !important;
    color: #059669 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile-icon::before {
    content: "" !important;
    width: 29px !important;
    height: 29px !important;
    background: currentColor !important;
    -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 5h13a3 3 0 0 1 3 3v2h-5a4 4 0 0 0 0 8h5v1a3 3 0 0 1-3 3H4a3 3 0 0 1-3-3V8a3 3 0 0 1 3-3Zm11 8a1.5 1.5 0 1 0 0 3h6v-3h-6Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
    mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 5h13a3 3 0 0 1 3 3v2h-5a4 4 0 0 0 0 8h5v1a3 3 0 0 1-3 3H4a3 3 0 0 1-3-3V8a3 3 0 0 1 3-3Zm11 8a1.5 1.5 0 1 0 0 3h6v-3h-6Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .dashboard-tile-received .summary-tile-icon::before {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M13.2 3h-2.4v13.1l-5-5-1.7 1.7L12 20.7l7.9-7.9-1.7-1.7-5 5V3Z'/%3E%3C/svg%3E") !important;
    mask-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M13.2 3h-2.4v13.1l-5-5-1.7 1.7L12 20.7l7.9-7.9-1.7-1.7-5 5V3Z'/%3E%3C/svg%3E") !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon) {
    grid-column: 2 !important;
    color: #64748b !important;
    font-size: 14px !important;
    font-weight: 800 !important;
    line-height: 1.25 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile strong {
    grid-column: 2 !important;
    margin: 5px 0 0 !important;
    color: #0f172a !important;
    font-size: clamp(28px, 7vw, 36px) !important;
    font-weight: 800 !important;
    line-height: 1.05 !important;
    letter-spacing: 0 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile small {
    grid-column: 2 !important;
    color: #64748b !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    line-height: 1.25 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup {
    order: 4 !important;
    display: block !important;
    width: 100% !important;
    margin: 0 0 4px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    margin: 0 0 12px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3 {
    margin: 0 !important;
    color: #0f172a !important;
    font-size: 19px !important;
    font-weight: 800 !important;
    line-height: 1.2 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head button {
    border: 0 !important;
    background: transparent !important;
    color: #059669 !important;
    font-size: 15px !important;
    font-weight: 800 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-card {
    display: grid !important;
    width: 100% !important;
    padding: 0 18px !important;
    border-radius: 14px !important;
    background: rgba(255, 255, 255, .98) !important;
    box-shadow: 0 12px 28px rgba(15, 23, 42, .06) !important;
    overflow: hidden !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row {
    display: grid !important;
    grid-template-columns: 48px minmax(0, 1fr) auto 16px !important;
    align-items: center !important;
    gap: 12px !important;
    min-height: 76px !important;
    width: 100% !important;
    padding: 12px 0 !important;
    border: 0 !important;
    border-bottom: 1px solid #e5edf6 !important;
    background: transparent !important;
    color: #0f172a !important;
    text-align: left !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row:last-child {
    border-bottom: 0 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-icon {
    display: grid !important;
    width: 48px !important;
    height: 48px !important;
    place-items: center !important;
    border-radius: 50% !important;
    background: #fee2e2 !important;
    color: #ef4444 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-call .followup-icon {
    background: #fef3c7 !important;
    color: #f59e0b !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-soon .followup-icon {
    background: #dbeafe !important;
    color: #2563eb !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-icon::before {
    content: "" !important;
    width: 25px !important;
    height: 25px !important;
    background: currentColor !important;
    -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 2h2v3h6V2h2v3h3v17H4V5h3V2Zm11 8H6v10h12V10Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
    mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 2h2v3h6V2h2v3h3v17H4V5h3V2Zm11 8H6v10h12V10Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-call .followup-icon::before {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6.6 2.8 10 6.2 8 8.2c.9 1.9 2.4 3.4 4.3 4.3l2-2 3.4 3.4-1.4 4.6c-.2.7-.9 1.1-1.6 1A15.2 15.2 0 0 1 4.9 9.7c-.1-.7.3-1.4 1-1.6l.7-5.3Z'/%3E%3C/svg%3E") !important;
    mask-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6.6 2.8 10 6.2 8 8.2c.9 1.9 2.4 3.4 4.3 4.3l2-2 3.4 3.4-1.4 4.6c-.2.7-.9 1.1-1.6 1A15.2 15.2 0 0 1 4.9 9.7c-.1-.7.3-1.4 1-1.6l.7-5.3Z'/%3E%3C/svg%3E") !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-soon .followup-icon::before {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20 4H4v14h12.5L20 21.5V4ZM7 9h10v2H7V9Zm0 4h7v2H7v-2Z'/%3E%3C/svg%3E") !important;
    mask-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20 4H4v14h12.5L20 21.5V4ZM7 9h10v2H7V9Zm0 4h7v2H7v-2Z'/%3E%3C/svg%3E") !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-copy {
    display: block !important;
    min-width: 0 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-copy strong {
    display: block !important;
    overflow: hidden !important;
    color: #0f172a !important;
    font-size: 16px !important;
    font-weight: 800 !important;
    line-height: 1.2 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-copy small {
    display: block !important;
    margin-top: 3px !important;
    overflow: hidden !important;
    color: #64748b !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    line-height: 1.25 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-amount {
    color: #ef4444 !important;
    font-size: 15px !important;
    font-weight: 800 !important;
    white-space: nowrap !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-chevron {
    color: #64748b !important;
    font-size: 25px !important;
    line-height: 1 !important;
  }

  body:not(.auth-locked) .mobile-fab-new-loan {
    display: none !important;
  }

  body:not(.auth-locked) .quick-nav,
  body:not(.auth-locked) .quick-nav.sidebar,
  body:not(.auth-locked) .quick-nav.app-sidebar,
  body[data-page]:not(.auth-locked) .quick-nav,
  body.mobile-mode:not(.auth-locked) .quick-nav {
    inset: auto 12px calc(12px + env(safe-area-inset-bottom)) 12px !important;
    width: auto !important;
    height: 78px !important;
    min-height: 78px !important;
    max-height: 78px !important;
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    gap: 4px !important;
    padding: 6px 8px !important;
    border: 0 !important;
    border-radius: 22px !important;
    background: rgba(255, 255, 255, .98) !important;
    box-shadow: 0 -8px 30px rgba(15, 23, 42, .10), 0 10px 28px rgba(15, 23, 42, .08) !important;
    backdrop-filter: blur(18px) !important;
    -webkit-backdrop-filter: blur(18px) !important;
    overflow: visible !important;
  }

  body:not(.auth-locked) .quick-nav a,
  body:not(.auth-locked) .quick-nav .sidebar-link,
  body:not(.auth-locked) .quick-nav .mobile-create-nav,
  body[data-page]:not(.auth-locked) .quick-nav a,
  body[data-page]:not(.auth-locked) .quick-nav .sidebar-link,
  body[data-page]:not(.auth-locked) .quick-nav .mobile-create-nav {
    height: 62px !important;
    min-height: 62px !important;
    max-height: 62px !important;
    border-radius: 18px !important;
    grid-template-rows: 30px 19px !important;
    color: #475569 !important;
    font-size: 12px !important;
    font-weight: 700 !important;
  }

  body:not(.auth-locked) .quick-nav .nav-icon,
  body:not(.auth-locked) .quick-nav .settings-gear,
  body[data-page]:not(.auth-locked) .quick-nav .nav-icon,
  body[data-page]:not(.auth-locked) .quick-nav .settings-gear {
    width: 30px !important;
    height: 30px !important;
    min-width: 30px !important;
    border-radius: 12px !important;
  }

  body:not(.auth-locked) .quick-nav .nav-label,
  body[data-page]:not(.auth-locked) .quick-nav .nav-label {
    height: 19px !important;
    max-height: 19px !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    line-height: 1.15 !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label,
  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label {
    font-size: 0 !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label::after,
  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label::after {
    display: block !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    line-height: 1.15 !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label::after {
    content: "หน้าแรก" !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label::after {
    content: "รายงาน" !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-icon svg,
  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-icon svg {
    display: none !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-icon::before,
  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-icon::before {
    content: "" !important;
    display: block !important;
    width: 26px !important;
    height: 26px !important;
    background: currentColor !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-icon::before {
    -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m3 11 9-8 9 8-1.6 1.8L18 11.6V21h-5v-6h-2v6H6v-9.4l-1.4 1.2L3 11Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
    mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m3 11 9-8 9 8-1.6 1.8L18 11.6V21h-5v-6h-2v6H6v-9.4l-1.4 1.2L3 11Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-icon::before {
    -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5 21H3v-8h2v8Zm8 0h-2V3h2v18Zm8 0h-2V8h2v13Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
    mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5 21H3v-8h2v8Zm8 0h-2V3h2v18Zm8 0h-2V8h2v13Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"],
  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"].active {
    background: #ecfdf5 !important;
    color: #10b981 !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-create-nav,
  body:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav,
  body.mobile-mode:not(.auth-locked) .quick-nav .mobile-create-nav,
  body[data-page]:not(.auth-locked) .quick-nav .mobile-create-nav {
    width: 72px !important;
    height: 72px !important;
    min-width: 72px !important;
    max-width: 72px !important;
    min-height: 72px !important;
    max-height: 72px !important;
    justify-self: center !important;
    align-self: start !important;
    margin-top: -20px !important;
    padding: 6px !important;
    border-radius: 50% !important;
    background: linear-gradient(180deg, #10b981 0%, #059669 100%) !important;
    color: #fff !important;
    box-shadow: 0 18px 32px rgba(5, 150, 105, .28) !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-create-nav .nav-icon {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-create-nav .nav-icon svg {
    width: 34px !important;
    height: 34px !important;
    stroke-width: 1.8 !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-create-nav .nav-label {
    height: 16px !important;
    color: #fff !important;
    font-size: 11px !important;
    line-height: 1 !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-tracking-link .nav-icon {
    position: relative !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-tracking-link .nav-icon::after {
    content: "8" !important;
    position: absolute !important;
    right: -4px !important;
    top: -5px !important;
    display: grid !important;
    width: 17px !important;
    height: 17px !important;
    place-items: center !important;
    border: 2px solid #fff !important;
    border-radius: 50% !important;
    background: #ef4444 !important;
    color: #fff !important;
    font-size: 9px !important;
    font-weight: 800 !important;
    line-height: 1 !important;
  }

  body:not(.auth-locked) .mobile-action-menu,
  body[data-page]:not(.auth-locked) .mobile-action-menu {
    bottom: calc(86px + env(safe-area-inset-bottom)) !important;
  }
}

@media (max-width: 420px) {
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions button {
    min-height: 86px !important;
    grid-template-columns: 48px minmax(0, 1fr) 12px !important;
    padding: 14px 10px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-button-icon {
    width: 48px !important;
    height: 48px !important;
    min-width: 48px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy strong {
    font-size: 15px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel {
    min-height: 286px !important;
    padding: 24px 24px 20px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel > div:first-child {
    max-width: 64% !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .dashboard-work-art {
    width: 104px !important;
    height: 112px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid {
    gap: 12px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile {
    min-height: 142px !important;
    grid-template-columns: 50px minmax(0, 1fr) !important;
    column-gap: 10px !important;
    padding: 15px 12px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile-icon {
    width: 50px !important;
    height: 50px !important;
    min-width: 50px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row {
    grid-template-columns: 44px minmax(0, 1fr) auto 12px !important;
    gap: 10px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-amount {
    max-width: 90px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }
}

/* v1.1.0-mobile-dashboard-premium2: tighten the mobile dashboard viewport to match the reference. */
@media (max-width: 768px) {
  body[data-page="dashboard"]:not(.auth-locked) .workspace::before,
  body[data-page="dashboard"]:not(.auth-locked) .workspace > .panel-title,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel::before {
    display: none !important;
    content: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .app-topbar,
  body[data-page="dashboard"]:not(.auth-locked) .app-topbar.page-header,
  body[data-page="dashboard"]:not(.auth-locked) .topbar {
    position: relative !important;
    display: block !important;
    height: 56px !important;
    min-height: 56px !important;
    max-height: 56px !important;
    margin: 0 0 28px !important;
    padding: 0 !important;
    overflow: visible !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .global-search,
  body[data-page="dashboard"]:not(.auth-locked) .global-search.search-box {
    position: absolute !important;
    left: 0 !important;
    top: 0 !important;
    width: calc(100% - 116px) !important;
    height: 56px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .notification-button,
  body[data-page="dashboard"]:not(.auth-locked) .icon-button.notification-button {
    position: absolute !important;
    top: 4px !important;
    right: 58px !important;
    width: 48px !important;
    height: 48px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .topbar-user {
    position: absolute !important;
    top: 4px !important;
    right: 0 !important;
    width: 48px !important;
    height: 48px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .panel.dashboard-hero,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row .dashboard-hero {
    min-height: 0 !important;
    height: auto !important;
    padding: 0 4px !important;
    border: 0 !important;
    outline: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2 {
    font-size: clamp(36px, 11vw, 46px) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint {
    margin-bottom: 20px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions {
    gap: 10px !important;
    margin-top: 4px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions button {
    grid-template-columns: 48px minmax(0, 1fr) 10px !important;
    gap: 9px !important;
    min-height: 88px !important;
    padding: 14px 10px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-button-icon {
    width: 48px !important;
    height: 48px !important;
    min-width: 48px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy strong {
    font-size: 14px !important;
    line-height: 1.18 !important;
    white-space: normal !important;
    text-overflow: clip !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy small {
    font-size: 12px !important;
    white-space: normal !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-chevron {
    font-size: 24px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel {
    min-height: 278px !important;
    padding: 22px 24px 20px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel > div:first-child {
    max-width: 74% !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .dashboard-work-kicker {
    margin-bottom: 16px !important;
    padding: 7px 15px !important;
    font-size: 15px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel strong {
    max-width: 100% !important;
    font-size: clamp(30px, 8.2vw, 36px) !important;
    line-height: 1.14 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel small {
    max-width: 82% !important;
    font-size: 15px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .dashboard-work-art {
    width: 104px !important;
    height: 112px !important;
    align-self: center !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .work-art-calendar {
    width: 72px !important;
    height: 82px !important;
    right: 8px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .work-art-bell {
    width: 50px !important;
    height: 50px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel::after {
    right: 104px !important;
    bottom: 82px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .primary-button {
    max-width: none !important;
    width: 100% !important;
    min-height: 56px !important;
  }
}

@media (max-width: 420px) {
  body[data-page="dashboard"]:not(.auth-locked) .content-shell,
  body[data-page="dashboard"]:not(.auth-locked) .content-shell.main-content,
  body[data-page="dashboard"]:not(.auth-locked) .main-content,
  body[data-page="dashboard"]:not(.auth-locked) .content-area {
    padding-left: 14px !important;
    padding-right: 14px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel {
    min-height: 264px !important;
    padding: 20px 18px 18px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel > div:first-child {
    max-width: 72% !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel strong {
    font-size: 30px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel small {
    max-width: 74% !important;
    font-size: 14px !important;
  }
}

/* v1.1.0-mobile-dashboard-premium3: final viewport fit and text anti-wrap pass. */
@media (max-width: 768px) {
  body[data-page="dashboard"]:not(.auth-locked) .topbar-actions {
    position: static !important;
    display: block !important;
    width: 0 !important;
    height: 0 !important;
    min-width: 0 !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .topbar-actions::before,
  body[data-page="dashboard"]:not(.auth-locked) .topbar-actions::after {
    display: none !important;
    content: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .global-search input {
    font-size: 14px !important;
    font-weight: 500 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy strong {
    font-size: 13px !important;
    line-height: 1.1 !important;
    -webkit-line-clamp: 1 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy small {
    font-size: 11px !important;
    line-height: 1.12 !important;
    -webkit-line-clamp: 2 !important;
    display: -webkit-box !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    text-overflow: clip !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel {
    min-height: 246px !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: auto 1fr auto !important;
    padding: 20px 18px 18px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel > div:first-child {
    grid-column: 1 !important;
    grid-row: 1 / 3 !important;
    max-width: 100% !important;
    padding-right: 110px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .dashboard-work-kicker {
    margin-bottom: 14px !important;
    font-size: 14px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel strong {
    font-size: clamp(26px, 7.2vw, 31px) !important;
    line-height: 1.16 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel small {
    max-width: 100% !important;
    font-size: 13px !important;
    line-height: 1.28 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .dashboard-work-art {
    position: absolute !important;
    right: 26px !important;
    top: 86px !important;
    width: 92px !important;
    height: 98px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel::after {
    right: 116px !important;
    bottom: 78px !important;
    transform: scale(.8) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel > button.primary-button,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .primary-button {
    grid-column: 1 !important;
    grid-row: 3 !important;
    justify-self: stretch !important;
    align-self: end !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    min-height: 54px !important;
    padding-left: 12px !important;
    padding-right: 12px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile {
    min-height: 132px !important;
  }
}

/* v1.1.0-mobile-dashboard-premium4: small polish for mobile-only dashboard chrome. */
@media (max-width: 768px) {
  body[data-page="dashboard"]:not(.auth-locked) .notification-button > span {
    display: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .global-search,
  body[data-page="dashboard"]:not(.auth-locked) .global-search.search-box {
    width: calc(100% - 104px) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .notification-button,
  body[data-page="dashboard"]:not(.auth-locked) .icon-button.notification-button {
    right: 52px !important;
    width: 42px !important;
    height: 42px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .global-search::before {
    left: 16px !important;
    width: 20px !important;
    height: 20px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .global-search input {
    padding-left: 46px !important;
    font-size: 12px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy strong {
    font-size: 12.5px !important;
    line-height: 1.15 !important;
    white-space: normal !important;
    -webkit-line-clamp: 2 !important;
    text-overflow: clip !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label,
  body:not(.auth-locked) .quick-nav > .sidebar-link[href="#dashboardPanel"] .nav-label,
  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label {
    color: transparent !important;
    font-size: 0 !important;
    text-overflow: clip !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label::after,
  body:not(.auth-locked) .quick-nav > .sidebar-link[href="#dashboardPanel"] .nav-label::after,
  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label::after {
    display: block !important;
    color: currentColor !important;
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    line-height: 1.15 !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label::after,
  body:not(.auth-locked) .quick-nav > .sidebar-link[href="#dashboardPanel"] .nav-label::after {
    content: "หน้าแรก" !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label::after {
    content: "รายงาน" !important;
  }
}

/* v1.1.0-mobile-dashboard-premium5: final mobile-only fit pass for the dashboard reference. */
@media (max-width: 768px) {
  body[data-page="dashboard"]:not(.auth-locked) .global-search input::-webkit-search-decoration,
  body[data-page="dashboard"]:not(.auth-locked) .global-search input::-webkit-search-cancel-button,
  body[data-page="dashboard"]:not(.auth-locked) .global-search input::-webkit-search-results-button,
  body[data-page="dashboard"]:not(.auth-locked) .global-search input::-webkit-search-results-decoration {
    display: none !important;
    -webkit-appearance: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .global-search input {
    -webkit-appearance: none !important;
    appearance: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions {
    gap: 18px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions button {
    grid-template-columns: 42px minmax(0, 1fr) 9px !important;
    gap: 8px !important;
    min-height: 104px !important;
    padding: 14px 10px !important;
    border-radius: 14px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-button-icon {
    width: 42px !important;
    height: 42px !important;
    min-width: 42px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .plus-icon::before {
    width: 27px !important;
    height: 27px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .line-icon {
    font-size: 10px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy strong {
    font-size: 13px !important;
    line-height: 1.12 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy small {
    margin-top: 4px !important;
    font-size: 10.5px !important;
    line-height: 1.18 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-chevron {
    font-size: 22px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel > .primary-button,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel button.primary-button {
    display: inline-flex !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"],
  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link {
    position: relative !important;
    overflow: hidden !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-icon,
  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-icon {
    position: absolute !important;
    top: 8px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label,
  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label {
    position: absolute !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 7px !important;
    display: block !important;
    width: 100% !important;
    height: 16px !important;
    max-height: 16px !important;
    overflow: visible !important;
    text-align: center !important;
  }

  body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label::after,
  body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label::after {
    display: block !important;
    width: 100% !important;
    overflow: visible !important;
    text-align: center !important;
    white-space: nowrap !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label::after {
    color: #059669 !important;
  }
}

/* v1.1.0-mobile-dashboard-premium6: override older button/search rules that carry !important heights. */
@media (max-width: 768px) {
  body[data-page="dashboard"]:not(.auth-locked) .global-search::after,
  body[data-page="dashboard"]:not(.auth-locked) .global-search.search-box::after {
    display: none !important;
    content: none !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions #dashboardNewLoan,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions #dashboardCreateLineConnect,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions button.secondary-button {
    display: grid !important;
    grid-template-columns: 42px minmax(0, 1fr) 9px !important;
    align-items: center !important;
    gap: 8px !important;
    height: 104px !important;
    min-height: 104px !important;
    max-height: 104px !important;
    padding: 14px 10px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions {
    min-height: 104px !important;
    height: 104px !important;
  }
}

/* v1.1.0-mobile-dashboard-premium7: compact dashboard fit and fixed-bottom nav for mobile only. */
@media (max-width: 768px) {
  body[data-page="dashboard"]:not(.auth-locked) .content-shell,
  body[data-page="dashboard"]:not(.auth-locked) .content-shell.main-content,
  body[data-page="dashboard"]:not(.auth-locked) .main-content,
  body[data-page="dashboard"]:not(.auth-locked) .content-area {
    padding: 10px 14px calc(78px + env(safe-area-inset-bottom)) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel.dashboard-page {
    gap: 12px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .app-topbar,
  body[data-page="dashboard"]:not(.auth-locked) .app-topbar.page-header,
  body[data-page="dashboard"]:not(.auth-locked) .topbar {
    height: 48px !important;
    min-height: 48px !important;
    max-height: 48px !important;
    margin: 0 0 18px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .global-search,
  body[data-page="dashboard"]:not(.auth-locked) .global-search.search-box {
    width: calc(100% - 98px) !important;
    height: 48px !important;
    border-radius: 16px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .global-search input {
    padding-left: 44px !important;
    font-size: 13px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .notification-button,
  body[data-page="dashboard"]:not(.auth-locked) .icon-button.notification-button {
    top: 3px !important;
    right: 50px !important;
    width: 42px !important;
    height: 42px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .topbar-user {
    top: 3px !important;
    width: 42px !important;
    height: 42px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .topbar-user::before {
    width: 24px !important;
    height: 24px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2 {
    font-size: clamp(32px, 9.5vw, 38px) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint {
    margin: 4px 0 12px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint::after {
    font-size: 14px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-date {
    font-size: 13px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions {
    gap: 12px !important;
    height: 86px !important;
    min-height: 86px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions #dashboardNewLoan,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions #dashboardCreateLineConnect,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions button.secondary-button {
    grid-template-columns: 40px minmax(0, 1fr) 8px !important;
    gap: 8px !important;
    height: 86px !important;
    min-height: 86px !important;
    max-height: 86px !important;
    padding: 12px 9px !important;
    border-radius: 14px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-button-icon {
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .plus-icon::before {
    width: 25px !important;
    height: 25px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy strong {
    font-size: 12px !important;
    line-height: 1.12 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy small {
    font-size: 10.5px !important;
    line-height: 1.12 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel {
    min-height: 224px !important;
    padding: 17px 16px 16px !important;
    border-radius: 16px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel > div:first-child {
    padding-right: 96px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .dashboard-work-kicker {
    margin-bottom: 11px !important;
    padding: 6px 13px !important;
    font-size: 13px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel strong {
    font-size: clamp(25px, 7vw, 30px) !important;
    line-height: 1.12 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel small {
    margin-top: 7px !important;
    font-size: 12.5px !important;
    line-height: 1.3 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .dashboard-work-art {
    right: 20px !important;
    top: 78px !important;
    width: 82px !important;
    height: 90px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .work-art-calendar {
    width: 62px !important;
    height: 72px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .work-art-bell {
    width: 44px !important;
    height: 44px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel .work-art-bell::before {
    font-size: 28px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel::after {
    right: 96px !important;
    bottom: 66px !important;
    transform: scale(.68) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel > .primary-button,
  body[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel button.primary-button {
    min-height: 46px !important;
    height: 46px !important;
    border-radius: 10px !important;
    font-size: 17px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid {
    gap: 10px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile {
    min-height: 112px !important;
    grid-template-columns: 46px minmax(0, 1fr) !important;
    column-gap: 10px !important;
    padding: 13px 12px !important;
    border-radius: 14px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile-icon {
    width: 46px !important;
    height: 46px !important;
    min-width: 46px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile-icon::before {
    width: 24px !important;
    height: 24px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon) {
    font-size: 12.5px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(25px, 6.5vw, 30px) !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile small {
    font-size: 12px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup {
    margin-top: 2px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head {
    margin-bottom: 8px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3 {
    font-size: 18px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-card {
    border-radius: 14px !important;
    padding: 6px 14px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row {
    min-height: 54px !important;
    grid-template-columns: 36px minmax(0, 1fr) auto 10px !important;
    gap: 9px !important;
    padding: 8px 0 !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-icon {
    width: 36px !important;
    height: 36px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-copy strong {
    font-size: 13.5px !important;
  }

  body[data-page="dashboard"]:not(.auth-locked) .followup-copy small,
  body[data-page="dashboard"]:not(.auth-locked) .followup-amount {
    font-size: 11.5px !important;
  }

  body:not(.auth-locked) .quick-nav,
  body:not(.auth-locked) .quick-nav.sidebar,
  body:not(.auth-locked) .quick-nav.app-sidebar,
  body[data-page]:not(.auth-locked) .quick-nav,
  body.mobile-mode:not(.auth-locked) .quick-nav {
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    inset: auto 0 0 0 !important;
    width: 100% !important;
    height: calc(70px + env(safe-area-inset-bottom)) !important;
    min-height: calc(70px + env(safe-area-inset-bottom)) !important;
    max-height: calc(70px + env(safe-area-inset-bottom)) !important;
    padding: 6px 14px calc(6px + env(safe-area-inset-bottom)) !important;
    border-radius: 20px 20px 0 0 !important;
    box-shadow: 0 -12px 28px rgba(15, 23, 42, .10) !important;
  }

  body:not(.auth-locked) .quick-nav a,
  body:not(.auth-locked) .quick-nav .sidebar-link,
  body:not(.auth-locked) .quick-nav .mobile-create-nav,
  body[data-page]:not(.auth-locked) .quick-nav a,
  body[data-page]:not(.auth-locked) .quick-nav .sidebar-link,
  body[data-page]:not(.auth-locked) .quick-nav .mobile-create-nav {
    height: 58px !important;
    min-height: 58px !important;
    max-height: 58px !important;
    border-radius: 16px !important;
  }

  body:not(.auth-locked) .quick-nav .mobile-create-nav,
  body:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav,
  body.mobile-mode:not(.auth-locked) .quick-nav .mobile-create-nav,
  body[data-page]:not(.auth-locked) .quick-nav .mobile-create-nav {
    width: 64px !important;
    height: 64px !important;
    min-width: 64px !important;
    max-width: 64px !important;
    min-height: 64px !important;
    max-height: 64px !important;
    margin-top: -12px !important;
  }
}

/* v1.1.0-mobile-dashboard-premium8: tighter mobile dashboard scale, fixed-bottom nav. */
@media (max-width: 768px) {
  html body[data-page="dashboard"]:not(.auth-locked) .content-shell,
  html body[data-page="dashboard"]:not(.auth-locked) .content-shell.main-content,
  html body[data-page="dashboard"]:not(.auth-locked) .main-content,
  html body[data-page="dashboard"]:not(.auth-locked) .content-area {
    padding: 8px 14px calc(76px + env(safe-area-inset-bottom)) !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel.dashboard-page {
    gap: 10px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .app-topbar,
  html body[data-page="dashboard"]:not(.auth-locked) .app-topbar.page-header,
  html body[data-page="dashboard"]:not(.auth-locked) .topbar {
    height: 46px !important;
    min-height: 46px !important;
    max-height: 46px !important;
    margin-bottom: 14px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .global-search,
  html body[data-page="dashboard"]:not(.auth-locked) .global-search.search-box {
    height: 46px !important;
    min-height: 46px !important;
    border-radius: 15px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .global-search input {
    font-size: 12.5px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2 {
    font-size: clamp(30px, 8.8vw, 36px) !important;
    line-height: 1.02 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint {
    margin: 2px 0 9px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint::after,
  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-date {
    font-size: 12.5px !important;
    line-height: 1.25 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions {
    gap: 10px !important;
    height: 78px !important;
    min-height: 78px !important;
    max-height: 78px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions #dashboardNewLoan,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions #dashboardCreateLineConnect,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions button.secondary-button {
    height: 78px !important;
    min-height: 78px !important;
    max-height: 78px !important;
    padding: 10px 8px !important;
    border-radius: 13px !important;
    grid-template-columns: 36px minmax(0, 1fr) 8px !important;
    gap: 8px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-button-icon {
    width: 36px !important;
    height: 36px !important;
    min-width: 36px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy strong {
    font-size: 11.5px !important;
    line-height: 1.08 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy small {
    font-size: 10px !important;
    line-height: 1.08 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel.dashboard-work-panel {
    height: 232px !important;
    min-height: 232px !important;
    max-height: 232px !important;
    padding: 15px 15px 13px !important;
    border-radius: 16px !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: auto 1fr 44px !important;
    overflow: hidden !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel.dashboard-work-panel > div:first-child {
    grid-area: 1 / 1 / 3 !important;
    max-width: 100% !important;
    padding-right: 82px !important;
    height: auto !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .dashboard-work-kicker {
    margin-bottom: 9px !important;
    padding: 5px 12px !important;
    font-size: 12px !important;
    line-height: 1.15 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel strong {
    max-width: 245px !important;
    font-size: clamp(23px, 6.8vw, 27px) !important;
    line-height: 1.1 !important;
    letter-spacing: 0 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel small {
    margin-top: 6px !important;
    max-width: 240px !important;
    font-size: 11.5px !important;
    line-height: 1.25 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .dashboard-work-art {
    right: 18px !important;
    top: 72px !important;
    width: 72px !important;
    height: 80px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .work-art-calendar {
    width: 54px !important;
    height: 64px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .work-art-bell {
    width: 38px !important;
    height: 38px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .work-art-bell::before {
    font-size: 24px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel::after {
    right: 82px !important;
    bottom: 58px !important;
    transform: scale(.58) !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel > .primary-button,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel button.primary-button {
    grid-area: 3 / 1 !important;
    width: 100% !important;
    height: 44px !important;
    min-height: 44px !important;
    max-height: 44px !important;
    border-radius: 10px !important;
    font-size: 15.5px !important;
    line-height: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid {
    gap: 9px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile {
    min-height: 104px !important;
    height: 104px !important;
    padding: 11px 10px !important;
    border-radius: 14px !important;
    grid-template-columns: 42px minmax(0, 1fr) !important;
    column-gap: 9px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile-icon {
    width: 42px !important;
    height: 42px !important;
    min-width: 42px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile-icon::before {
    width: 22px !important;
    height: 22px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon) {
    font-size: 11.5px !important;
    line-height: 1.15 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(23px, 6vw, 28px) !important;
    line-height: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile small {
    font-size: 11px !important;
    line-height: 1.15 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup {
    margin-top: 0 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head {
    margin-bottom: 6px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3 {
    font-size: 17px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-card {
    padding: 4px 12px !important;
    border-radius: 13px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row {
    min-height: 48px !important;
    padding: 6px 0 !important;
    grid-template-columns: 32px minmax(0, 1fr) auto 10px !important;
    gap: 8px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-icon {
    width: 32px !important;
    height: 32px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-copy strong {
    font-size: 12.5px !important;
    line-height: 1.16 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-copy small,
  html body[data-page="dashboard"]:not(.auth-locked) .followup-amount {
    font-size: 10.8px !important;
    line-height: 1.16 !important;
  }

  html body:not(.auth-locked) .quick-nav,
  html body:not(.auth-locked) .quick-nav.sidebar,
  html body:not(.auth-locked) .quick-nav.app-sidebar,
  html body[data-page]:not(.auth-locked) .quick-nav,
  html body.mobile-mode:not(.auth-locked) .quick-nav {
    position: fixed !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    inset: auto 0 0 0 !important;
    transform: none !important;
    width: 100% !important;
    height: calc(68px + env(safe-area-inset-bottom)) !important;
    min-height: calc(68px + env(safe-area-inset-bottom)) !important;
    max-height: calc(68px + env(safe-area-inset-bottom)) !important;
    padding: 6px 12px calc(6px + env(safe-area-inset-bottom)) !important;
    border-radius: 18px 18px 0 0 !important;
    box-shadow: 0 -10px 24px rgba(15, 23, 42, .10) !important;
  }

  html body:not(.auth-locked) .quick-nav a,
  html body:not(.auth-locked) .quick-nav .sidebar-link,
  html body:not(.auth-locked) .quick-nav .mobile-create-nav,
  html body[data-page]:not(.auth-locked) .quick-nav a,
  html body[data-page]:not(.auth-locked) .quick-nav .sidebar-link,
  html body[data-page]:not(.auth-locked) .quick-nav .mobile-create-nav {
    height: 56px !important;
    min-height: 56px !important;
    max-height: 56px !important;
    border-radius: 15px !important;
  }

  html body:not(.auth-locked) .quick-nav .mobile-create-nav,
  html body:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav,
  html body.mobile-mode:not(.auth-locked) .quick-nav .mobile-create-nav,
  html body[data-page]:not(.auth-locked) .quick-nav .mobile-create-nav {
    width: 62px !important;
    height: 62px !important;
    min-width: 62px !important;
    max-width: 62px !important;
    min-height: 62px !important;
    max-height: 62px !important;
    margin-top: -10px !important;
  }
}

/* v1.1.0-mobile-dashboard-premium9: mobile title, work art, and nav typography polish. */
@media (max-width: 768px) {
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2 {
    color: transparent !important;
    font-size: 0 !important;
    line-height: 1 !important;
    margin: 0 !important;
    min-height: 30px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2::after {
    content: "Dashboard";
    display: block;
    color: #0f172a;
    font-family: "IBM Plex Sans Thai", "Inter", system-ui, sans-serif;
    font-size: 29px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint {
    margin: 0 0 8px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint::after {
    font-size: 12px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row {
    margin-top: -2px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel.dashboard-work-panel {
    height: 224px !important;
    min-height: 224px !important;
    max-height: 224px !important;
    padding: 14px 15px 12px !important;
    grid-template-rows: auto 1fr 42px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .dashboard-work-kicker {
    margin-bottom: 8px !important;
    font-size: 11.5px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel strong {
    font-size: clamp(22px, 6.35vw, 25px) !important;
    line-height: 1.08 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel small {
    margin-top: 6px !important;
    font-size: 11px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .dashboard-work-art {
    top: 58px !important;
    right: 17px !important;
    width: 68px !important;
    height: 74px !important;
    z-index: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .work-art-calendar {
    width: 50px !important;
    height: 58px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .work-art-bell {
    width: 35px !important;
    height: 35px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel::after {
    right: 76px !important;
    bottom: 66px !important;
    transform: scale(.52) !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel > .primary-button,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel button.primary-button {
    height: 42px !important;
    min-height: 42px !important;
    max-height: 42px !important;
    margin-bottom: 2px !important;
    font-size: 15px !important;
    position: relative !important;
    z-index: 3 !important;
  }

  html body:not(.auth-locked) .quick-nav .nav-label,
  html body:not(.auth-locked) .quick-nav .sidebar-link .nav-label,
  html body:not(.auth-locked) .quick-nav .mobile-create-nav .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav .nav-label {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    color: inherit !important;
    font-family: "IBM Plex Sans Thai", "Inter", system-ui, sans-serif !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    line-height: 1.05 !important;
    letter-spacing: 0 !important;
    text-align: center !important;
    white-space: nowrap !important;
    overflow: visible !important;
    text-overflow: clip !important;
    transform: none !important;
  }

  html body:not(.auth-locked) .quick-nav .mobile-create-nav .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav .mobile-create-nav .nav-label {
    font-size: 12px !important;
    font-weight: 700 !important;
    margin-top: 2px !important;
  }

  html body:not(.auth-locked) .quick-nav .sidebar-link,
  html body:not(.auth-locked) .quick-nav .mobile-create-nav,
  html body[data-page]:not(.auth-locked) .quick-nav .sidebar-link,
  html body[data-page]:not(.auth-locked) .quick-nav .mobile-create-nav {
    gap: 3px !important;
    justify-content: center !important;
    align-items: center !important;
  }
}

/* v1.1.0-mobile-dashboard-premium10: force compact title box and equal mobile nav labels. */
@media (max-width: 768px) {
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero {
    min-height: 0 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2 {
    display: block !important;
    height: 30px !important;
    min-height: 30px !important;
    max-height: 30px !important;
    overflow: hidden !important;
    color: transparent !important;
    font-size: 0 !important;
    line-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2::after {
    content: "Dashboard" !important;
    display: block !important;
    height: 30px !important;
    color: #0f172a !important;
    font-size: 28px !important;
    font-weight: 800 !important;
    line-height: 30px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions {
    margin-top: 0 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel.dashboard-work-panel {
    height: 218px !important;
    min-height: 218px !important;
    max-height: 218px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .dashboard-work-art {
    top: 54px !important;
    right: 18px !important;
    width: 64px !important;
    height: 70px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .work-art-calendar {
    width: 48px !important;
    height: 56px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .work-art-bell {
    width: 33px !important;
    height: 33px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel > .primary-button,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel button.primary-button {
    align-self: start !important;
    margin-top: -2px !important;
    margin-bottom: 0 !important;
  }

  html body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label,
  html body:not(.auth-locked) .quick-nav > .sidebar-link[href="#dashboardPanel"] .nav-label,
  html body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav > .sidebar-link[href="#dashboardPanel"] .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label,
  html body:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav .nav-label {
    display: block !important;
    width: 100% !important;
    height: 15px !important;
    max-height: 15px !important;
    color: inherit !important;
    font-family: "IBM Plex Sans Thai", "Inter", system-ui, sans-serif !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    line-height: 15px !important;
    letter-spacing: 0 !important;
    text-align: center !important;
    white-space: nowrap !important;
    overflow: visible !important;
    text-overflow: clip !important;
  }

  html body:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav .nav-label {
    color: #fff !important;
    font-weight: 700 !important;
  }

  html body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label::after,
  html body:not(.auth-locked) .quick-nav > .sidebar-link[href="#dashboardPanel"] .nav-label::after,
  html body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label::after,
  html body[data-page]:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label::after,
  html body[data-page]:not(.auth-locked) .quick-nav > .sidebar-link[href="#dashboardPanel"] .nav-label::after,
  html body[data-page]:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label::after {
    display: block !important;
    width: 100% !important;
    height: 15px !important;
    color: currentColor !important;
    font-family: "IBM Plex Sans Thai", "Inter", system-ui, sans-serif !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    line-height: 15px !important;
    letter-spacing: 0 !important;
    text-align: center !important;
    white-space: nowrap !important;
  }
}

/* v1.1.0-mobile-dashboard-premium11: real Dashboard title and single-line bottom nav labels. */
@media (max-width: 768px) {
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2 {
    width: auto !important;
    height: 30px !important;
    min-height: 30px !important;
    max-height: 30px !important;
    color: #0f172a !important;
    font-family: "IBM Plex Sans Thai", "Inter", system-ui, sans-serif !important;
    font-size: 28px !important;
    font-weight: 800 !important;
    line-height: 30px !important;
    overflow: visible !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2::after {
    content: none !important;
    display: none !important;
  }

  html body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label,
  html body:not(.auth-locked) .quick-nav > .sidebar-link[href="#dashboardPanel"] .nav-label,
  html body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav > .sidebar-link[href="#dashboardPanel"] .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label {
    color: transparent !important;
    font-size: 0 !important;
    line-height: 0 !important;
  }

  html body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label::after,
  html body:not(.auth-locked) .quick-nav > .sidebar-link[href="#dashboardPanel"] .nav-label::after,
  html body:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label::after,
  html body[data-page]:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label::after,
  html body[data-page]:not(.auth-locked) .quick-nav > .sidebar-link[href="#dashboardPanel"] .nav-label::after,
  html body[data-page]:not(.auth-locked) .quick-nav > a[href="#settingsPanel"].mobile-settings-link .nav-label::after {
    display: block !important;
    color: currentColor !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    line-height: 15px !important;
  }

  html body:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav .nav-label::before,
  html body:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav .nav-label::after,
  html body[data-page]:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav .nav-label::before,
  html body[data-page]:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav .nav-label::after {
    content: none !important;
    display: none !important;
  }

  html body:not(.auth-locked) .quick-nav > .mobile-only-nav-link .nav-label,
  html body:not(.auth-locked) .quick-nav > .mobile-records-link .nav-label,
  html body:not(.auth-locked) .quick-nav > .mobile-tracking-link .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav > .mobile-only-nav-link .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav > .mobile-records-link .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav > .mobile-tracking-link .nav-label,
  html body:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav .nav-label {
    color: inherit !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    line-height: 15px !important;
    height: 15px !important;
    max-height: 15px !important;
    text-align: center !important;
    white-space: nowrap !important;
  }

  html body:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav button.mobile-create-nav#mobileCreateNav .nav-label {
    color: #fff !important;
    font-weight: 700 !important;
  }
}

/* v1.1.0-mobile-dashboard-premium12: compact final mobile viewport fit. */
@media (max-width: 768px) {
  html body[data-page="dashboard"]:not(.auth-locked) .content-shell,
  html body[data-page="dashboard"]:not(.auth-locked) .content-shell.main-content,
  html body[data-page="dashboard"]:not(.auth-locked) .main-content,
  html body[data-page="dashboard"]:not(.auth-locked) .content-area {
    padding: 6px 12px calc(68px + env(safe-area-inset-bottom)) !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel.dashboard-page {
    gap: 9px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .app-topbar,
  html body[data-page="dashboard"]:not(.auth-locked) .app-topbar.page-header,
  html body[data-page="dashboard"]:not(.auth-locked) .topbar {
    height: 42px !important;
    min-height: 42px !important;
    max-height: 42px !important;
    margin-bottom: 10px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .global-search,
  html body[data-page="dashboard"]:not(.auth-locked) .global-search.search-box {
    height: 42px !important;
    min-height: 42px !important;
    border-radius: 14px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .global-search input {
    padding-left: 40px !important;
    font-size: 11.5px !important;
    font-weight: 600 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .notification-button,
  html body[data-page="dashboard"]:not(.auth-locked) .icon-button.notification-button,
  html body[data-page="dashboard"]:not(.auth-locked) .topbar-user {
    width: 38px !important;
    height: 38px !important;
    min-width: 38px !important;
    min-height: 38px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row {
    margin-top: -4px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2 {
    height: 27px !important;
    min-height: 27px !important;
    max-height: 27px !important;
    font-size: 25px !important;
    line-height: 27px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint {
    margin: 0 0 6px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint::after,
  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-date {
    font-size: 11.5px !important;
    line-height: 1.15 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions {
    gap: 9px !important;
    height: 70px !important;
    min-height: 70px !important;
    max-height: 70px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions #dashboardNewLoan,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions #dashboardCreateLineConnect,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions button.secondary-button {
    height: 70px !important;
    min-height: 70px !important;
    max-height: 70px !important;
    padding: 9px 8px !important;
    border-radius: 12px !important;
    grid-template-columns: 32px minmax(0, 1fr) 8px !important;
    gap: 7px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-button-icon {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy strong {
    font-size: 10.6px !important;
    line-height: 1.08 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy small {
    margin-top: 2px !important;
    font-size: 9.4px !important;
    line-height: 1.08 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel.dashboard-work-panel {
    height: 196px !important;
    min-height: 196px !important;
    max-height: 196px !important;
    padding: 12px 14px 10px !important;
    grid-template-rows: auto 1fr 38px !important;
    border-radius: 15px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel.dashboard-work-panel > div:first-child {
    padding-right: 76px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .dashboard-work-kicker {
    margin-bottom: 7px !important;
    padding: 4px 10px !important;
    font-size: 10.8px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel strong {
    max-width: 245px !important;
    font-size: clamp(20px, 5.8vw, 23px) !important;
    line-height: 1.08 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel small {
    margin-top: 5px !important;
    max-width: 240px !important;
    font-size: 10.4px !important;
    line-height: 1.18 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .dashboard-work-art {
    top: 48px !important;
    right: 18px !important;
    width: 58px !important;
    height: 62px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .work-art-calendar {
    width: 42px !important;
    height: 50px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .work-art-bell {
    width: 30px !important;
    height: 30px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel::after {
    right: 68px !important;
    bottom: 54px !important;
    transform: scale(.46) !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel > .primary-button,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel button.primary-button {
    height: 38px !important;
    min-height: 38px !important;
    max-height: 38px !important;
    font-size: 13.5px !important;
    border-radius: 9px !important;
    margin-top: -1px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid {
    gap: 8px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile {
    height: 92px !important;
    min-height: 92px !important;
    padding: 9px 9px !important;
    border-radius: 13px !important;
    grid-template-columns: 36px minmax(0, 1fr) !important;
    column-gap: 8px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile-icon {
    width: 36px !important;
    height: 36px !important;
    min-width: 36px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon) {
    font-size: 10.5px !important;
    line-height: 1.1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(21px, 5.5vw, 25px) !important;
    line-height: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile small {
    font-size: 10px !important;
    line-height: 1.1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head {
    margin-bottom: 5px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3 {
    font-size: 15.8px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head button {
    font-size: 12px !important;
    line-height: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-card {
    padding: 3px 11px !important;
    border-radius: 13px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row {
    min-height: 43px !important;
    padding: 5px 0 !important;
    grid-template-columns: 30px minmax(0, 1fr) auto 9px !important;
    gap: 7px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-icon {
    width: 30px !important;
    height: 30px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-copy strong {
    font-size: 11.8px !important;
    line-height: 1.08 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-copy small,
  html body[data-page="dashboard"]:not(.auth-locked) .followup-amount {
    font-size: 10px !important;
    line-height: 1.08 !important;
  }

  html body:not(.auth-locked) .quick-nav,
  html body:not(.auth-locked) .quick-nav.sidebar,
  html body:not(.auth-locked) .quick-nav.app-sidebar,
  html body[data-page]:not(.auth-locked) .quick-nav,
  html body.mobile-mode:not(.auth-locked) .quick-nav {
    height: calc(64px + env(safe-area-inset-bottom)) !important;
    min-height: calc(64px + env(safe-area-inset-bottom)) !important;
    max-height: calc(64px + env(safe-area-inset-bottom)) !important;
    padding: 5px 12px calc(5px + env(safe-area-inset-bottom)) !important;
    border-radius: 16px 16px 0 0 !important;
  }

  html body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"],
  html body:not(.auth-locked) .quick-nav > .mobile-only-nav-link,
  html body:not(.auth-locked) .quick-nav > button.mobile-create-nav#mobileCreateNav,
  html body[data-page]:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"],
  html body[data-page]:not(.auth-locked) .quick-nav > .mobile-only-nav-link,
  html body[data-page]:not(.auth-locked) .quick-nav > button.mobile-create-nav#mobileCreateNav {
    height: 52px !important;
    min-height: 52px !important;
    max-height: 52px !important;
    border-radius: 14px !important;
    gap: 2px !important;
    align-items: center !important;
    justify-content: center !important;
  }

  html body:not(.auth-locked) .quick-nav > button.mobile-create-nav#mobileCreateNav,
  html body[data-page]:not(.auth-locked) .quick-nav > button.mobile-create-nav#mobileCreateNav {
    width: 58px !important;
    height: 58px !important;
    min-width: 58px !important;
    max-width: 58px !important;
    min-height: 58px !important;
    max-height: 58px !important;
    margin-top: -8px !important;
    border-radius: 18px !important;
  }

  html body:not(.auth-locked) .quick-nav .nav-icon,
  html body[data-page]:not(.auth-locked) .quick-nav .nav-icon {
    width: 24px !important;
    height: 24px !important;
    min-width: 24px !important;
  }

  html body:not(.auth-locked) .quick-nav > button.mobile-create-nav#mobileCreateNav .nav-icon,
  html body[data-page]:not(.auth-locked) .quick-nav > button.mobile-create-nav#mobileCreateNav .nav-icon {
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
  }

  html body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label,
  html body:not(.auth-locked) .quick-nav > .sidebar-link[href="#dashboardPanel"] .nav-label {
    position: relative !important;
    color: transparent !important;
    font-size: 0 !important;
    line-height: 0 !important;
    text-indent: -9999px !important;
  }

  html body:not(.auth-locked) .quick-nav > a[href="#dashboardPanel"] .nav-label::after,
  html body:not(.auth-locked) .quick-nav > .sidebar-link[href="#dashboardPanel"] .nav-label::after {
    content: "หน้าแรก" !important;
    position: absolute !important;
    inset: 0 !important;
    display: block !important;
    color: currentColor !important;
    font-size: 11.2px !important;
    font-weight: 600 !important;
    line-height: 14px !important;
    text-align: center !important;
    text-indent: 0 !important;
    white-space: nowrap !important;
  }

  html body:not(.auth-locked) .quick-nav > .mobile-only-nav-link .nav-label,
  html body:not(.auth-locked) .quick-nav > button.mobile-create-nav#mobileCreateNav .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav > .mobile-only-nav-link .nav-label,
  html body[data-page]:not(.auth-locked) .quick-nav > button.mobile-create-nav#mobileCreateNav .nav-label {
    font-size: 11.2px !important;
    font-weight: 600 !important;
    line-height: 14px !important;
    height: 14px !important;
    max-height: 14px !important;
    text-align: center !important;
    white-space: nowrap !important;
  }

  html body:not(.auth-locked) .quick-nav > button.mobile-create-nav#mobileCreateNav .nav-label {
    color: #fff !important;
    font-weight: 700 !important;
  }

  html body:not(.auth-locked) .quick-nav > .mobile-only-nav-link .nav-label::before,
  html body:not(.auth-locked) .quick-nav > .mobile-only-nav-link .nav-label::after,
  html body:not(.auth-locked) .quick-nav > button.mobile-create-nav#mobileCreateNav .nav-label::before,
  html body:not(.auth-locked) .quick-nav > button.mobile-create-nav#mobileCreateNav .nav-label::after {
    content: none !important;
    display: none !important;
  }
}

/* v1.1.0-mobile-dashboard-premium13-final: must stay last, compact dashboard on phones only. */
@media (max-width: 768px) {
  html body[data-page="dashboard"]:not(.auth-locked) .content-shell,
  html body[data-page="dashboard"]:not(.auth-locked) .content-shell.main-content,
  html body[data-page="dashboard"]:not(.auth-locked) .main-content,
  html body[data-page="dashboard"]:not(.auth-locked) .content-area {
    padding: 5px 12px calc(66px + env(safe-area-inset-bottom)) !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel.dashboard-page {
    gap: 8px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .app-topbar,
  html body[data-page="dashboard"]:not(.auth-locked) .app-topbar.page-header,
  html body[data-page="dashboard"]:not(.auth-locked) .topbar {
    height: 38px !important;
    min-height: 38px !important;
    max-height: 38px !important;
    margin-bottom: 8px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .global-search,
  html body[data-page="dashboard"]:not(.auth-locked) .global-search.search-box {
    height: 38px !important;
    min-height: 38px !important;
    border-radius: 13px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .global-search input {
    padding-left: 38px !important;
    font-size: 10.8px !important;
    line-height: 1.1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .notification-button,
  html body[data-page="dashboard"]:not(.auth-locked) .icon-button.notification-button,
  html body[data-page="dashboard"]:not(.auth-locked) .topbar-user {
    width: 35px !important;
    height: 35px !important;
    min-width: 35px !important;
    min-height: 35px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row {
    margin-top: -7px !important;
    align-items: center !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2 {
    width: auto !important;
    height: 22px !important;
    min-height: 22px !important;
    max-height: 22px !important;
    font-size: 22px !important;
    line-height: 22px !important;
    font-weight: 800 !important;
    letter-spacing: 0 !important;
    margin: 0 !important;
    overflow: visible !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardFilterHint::after {
    margin: 0 0 5px !important;
    font-size: 10.4px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-date {
    font-size: 10.4px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions {
    gap: 8px !important;
    height: 62px !important;
    min-height: 62px !important;
    max-height: 62px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions #dashboardNewLoan,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions #dashboardCreateLineConnect,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-quick-actions button.secondary-button {
    height: 62px !important;
    min-height: 62px !important;
    max-height: 62px !important;
    padding: 8px 7px !important;
    border-radius: 12px !important;
    grid-template-columns: 29px minmax(0, 1fr) 7px !important;
    gap: 6px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-button-icon {
    width: 29px !important;
    height: 29px !important;
    min-width: 29px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy strong {
    font-size: 10px !important;
    line-height: 1.06 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-action-copy small {
    margin-top: 1px !important;
    font-size: 8.9px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel.dashboard-work-panel {
    height: 168px !important;
    min-height: 168px !important;
    max-height: 168px !important;
    padding: 10px 14px 9px !important;
    grid-template-rows: auto 1fr 34px !important;
    border-radius: 14px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel.dashboard-work-panel > div:first-child {
    padding-right: 72px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .dashboard-work-kicker {
    margin-bottom: 5px !important;
    padding: 4px 9px !important;
    font-size: 9.8px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel strong {
    max-width: 232px !important;
    font-size: clamp(18px, 5.05vw, 20px) !important;
    line-height: 1.07 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel small {
    margin-top: 4px !important;
    max-width: 225px !important;
    font-size: 9.5px !important;
    line-height: 1.1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .dashboard-work-art {
    top: 49px !important;
    right: 17px !important;
    width: 49px !important;
    height: 52px !important;
    z-index: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .work-art-calendar {
    width: 36px !important;
    height: 43px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel .work-art-bell {
    width: 25px !important;
    height: 25px !important;
    right: -2px !important;
    top: 9px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel::after {
    right: 58px !important;
    bottom: 66px !important;
    transform: scale(.34) !important;
    z-index: 1 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel > .primary-button,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel #dashboardWorkPanel button.primary-button {
    position: relative !important;
    z-index: 3 !important;
    height: 34px !important;
    min-height: 34px !important;
    max-height: 34px !important;
    font-size: 12.5px !important;
    line-height: 1 !important;
    border-radius: 9px !important;
    margin-top: 0 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid {
    gap: 7px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile {
    height: 82px !important;
    min-height: 82px !important;
    padding: 8px !important;
    border-radius: 12px !important;
    grid-template-columns: 32px minmax(0, 1fr) !important;
    column-gap: 7px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile-icon {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon) {
    font-size: 9.7px !important;
    line-height: 1.06 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(19px, 5vw, 22px) !important;
    line-height: .98 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel > .summary-grid .summary-tile small {
    font-size: 9.2px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup {
    margin-top: 2px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head {
    margin-bottom: 4px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3 {
    font-size: 14.2px !important;
    line-height: 1.02 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head button {
    font-size: 11px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-card {
    padding: 2px 10px !important;
    border-radius: 12px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row {
    min-height: 39px !important;
    padding: 4px 0 !important;
    grid-template-columns: 27px minmax(0, 1fr) auto 8px !important;
    gap: 6px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-icon {
    width: 27px !important;
    height: 27px !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-copy strong {
    font-size: 10.8px !important;
    line-height: 1.04 !important;
  }

  html body[data-page="dashboard"]:not(.auth-locked) .followup-copy small,
  html body[data-page="dashboard"]:not(.auth-locked) .followup-amount {
    font-size: 9.4px !important;
    line-height: 1.04 !important;
  }
}

/* v1.1.0-mobile-dashboard-premium14: apply even when body keeps auth-locked during mobile session restore. */
@media (max-width: 768px) {
  html body[data-page="dashboard"] .content-shell,
  html body[data-page="dashboard"] .content-shell.main-content,
  html body[data-page="dashboard"] .main-content,
  html body[data-page="dashboard"] .content-area {
    padding: 5px 12px calc(66px + env(safe-area-inset-bottom)) !important;
  }

  html body[data-page="dashboard"] #dashboardPanel.dashboard-page {
    gap: 8px !important;
  }

  html body[data-page="dashboard"] .app-topbar,
  html body[data-page="dashboard"] .app-topbar.page-header,
  html body[data-page="dashboard"] .topbar {
    height: 38px !important;
    min-height: 38px !important;
    max-height: 38px !important;
    margin-bottom: 8px !important;
  }

  html body[data-page="dashboard"] .global-search,
  html body[data-page="dashboard"] .global-search.search-box {
    height: 38px !important;
    min-height: 38px !important;
    border-radius: 13px !important;
  }

  html body[data-page="dashboard"] .global-search input {
    padding-left: 38px !important;
    font-size: 10.8px !important;
    line-height: 1.1 !important;
  }

  html body[data-page="dashboard"] .notification-button,
  html body[data-page="dashboard"] .icon-button.notification-button,
  html body[data-page="dashboard"] .topbar-user {
    width: 35px !important;
    height: 35px !important;
    min-width: 35px !important;
    min-height: 35px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-top-row {
    margin-top: -7px !important;
    align-items: center !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-top-row .dashboard-hero h2,
  html body[data-page="dashboard"] #dashboardPanel .dashboard-hero h2 {
    width: auto !important;
    height: 22px !important;
    min-height: 22px !important;
    max-height: 22px !important;
    font-size: 22px !important;
    line-height: 22px !important;
    font-weight: 800 !important;
    letter-spacing: 0 !important;
    margin: 0 !important;
    overflow: visible !important;
  }

  html body[data-page="dashboard"] #dashboardFilterHint,
  html body[data-page="dashboard"] #dashboardFilterHint::after {
    margin: 0 0 5px !important;
    font-size: 10.4px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-date {
    font-size: 10.4px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-quick-actions {
    gap: 8px !important;
    height: 62px !important;
    min-height: 62px !important;
    max-height: 62px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-quick-actions #dashboardNewLoan,
  html body[data-page="dashboard"] #dashboardPanel .dashboard-quick-actions #dashboardCreateLineConnect,
  html body[data-page="dashboard"] #dashboardPanel .dashboard-quick-actions button.secondary-button {
    height: 62px !important;
    min-height: 62px !important;
    max-height: 62px !important;
    padding: 8px 7px !important;
    border-radius: 12px !important;
    grid-template-columns: 29px minmax(0, 1fr) 7px !important;
    gap: 6px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-button-icon {
    width: 29px !important;
    height: 29px !important;
    min-width: 29px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-action-copy strong {
    font-size: 10px !important;
    line-height: 1.06 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel .dashboard-action-copy small {
    margin-top: 1px !important;
    font-size: 8.9px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel.dashboard-work-panel {
    height: 168px !important;
    min-height: 168px !important;
    max-height: 168px !important;
    padding: 10px 14px 9px !important;
    grid-template-rows: auto 1fr 34px !important;
    border-radius: 14px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel.dashboard-work-panel > div:first-child {
    padding-right: 72px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel .dashboard-work-kicker {
    margin-bottom: 5px !important;
    padding: 4px 9px !important;
    font-size: 9.8px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel strong {
    max-width: 232px !important;
    font-size: clamp(18px, 5.05vw, 20px) !important;
    line-height: 1.07 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel small {
    margin-top: 4px !important;
    max-width: 225px !important;
    font-size: 9.5px !important;
    line-height: 1.1 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel .dashboard-work-art {
    top: 42px !important;
    right: 17px !important;
    width: 47px !important;
    height: 50px !important;
    z-index: 1 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel .work-art-calendar {
    width: 34px !important;
    height: 41px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel .work-art-bell {
    width: 24px !important;
    height: 24px !important;
    right: -2px !important;
    top: 9px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel::after {
    right: 56px !important;
    bottom: 72px !important;
    transform: scale(.32) !important;
    z-index: 1 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel > .primary-button,
  html body[data-page="dashboard"] #dashboardPanel #dashboardWorkPanel button.primary-button {
    position: relative !important;
    z-index: 3 !important;
    height: 34px !important;
    min-height: 34px !important;
    max-height: 34px !important;
    font-size: 12.5px !important;
    line-height: 1 !important;
    border-radius: 9px !important;
    margin-top: 0 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel > .summary-grid {
    gap: 7px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel > .summary-grid .summary-tile {
    height: 82px !important;
    min-height: 82px !important;
    padding: 8px !important;
    border-radius: 12px !important;
    grid-template-columns: 32px minmax(0, 1fr) !important;
    column-gap: 7px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel > .summary-grid .summary-tile-icon {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
  }

  html body[data-page="dashboard"] #dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon) {
    font-size: 9.7px !important;
    line-height: 1.06 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(19px, 5vw, 22px) !important;
    line-height: .98 !important;
  }

  html body[data-page="dashboard"] #dashboardPanel > .summary-grid .summary-tile small {
    font-size: 9.2px !important;
    line-height: 1.05 !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-followup {
    margin-top: 2px !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-followup-head {
    margin-bottom: 4px !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-followup-head h3 {
    font-size: 14.2px !important;
    line-height: 1.02 !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-followup-head button {
    font-size: 11px !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-followup-card {
    padding: 2px 10px !important;
    border-radius: 12px !important;
  }

  html body[data-page="dashboard"] .dashboard-mobile-followup-row {
    min-height: 39px !important;
    padding: 4px 0 !important;
    grid-template-columns: 27px minmax(0, 1fr) auto 8px !important;
    gap: 6px !important;
  }

  html body[data-page="dashboard"] .followup-icon {
    width: 27px !important;
    height: 27px !important;
  }

  html body[data-page="dashboard"] .followup-copy strong {
    font-size: 10.8px !important;
    line-height: 1.04 !important;
  }

  html body[data-page="dashboard"] .followup-copy small,
  html body[data-page="dashboard"] .followup-amount {
    font-size: 9.4px !important;
    line-height: 1.04 !important;
  }
}

/* Desktop-only debtors board, 2026-05-21. Mobile cards stay untouched below 768px. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) {
    background: #f7fafc !important;
  }

  html body[data-page="records"]:not(.auth-locked) .app-topbar,
  html body[data-page="records"]:not(.auth-locked) #recordsSubnav,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel .mobile-debtor-title-actions,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title .button-row,
  html body[data-page="records"]:not(.auth-locked) #recordsList > .mobile-debtor-screen,
  html body[data-page="records"]:not(.auth-locked) #recordsList > .records-table-wrap,
  html body[data-page="records"]:not(.auth-locked) #recordsList > .empty-state {
    display: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) .app-shell,
  html body[data-page="records"]:not(.auth-locked) .content-shell,
  html body[data-page="records"]:not(.auth-locked) .content-shell.main-content,
  html body[data-page="records"]:not(.auth-locked) .main-content,
  html body[data-page="records"]:not(.auth-locked) .content-area,
  html body[data-page="records"]:not(.auth-locked) .workspace {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .content-shell,
  html body[data-page="records"]:not(.auth-locked) .content-shell.main-content,
  html body[data-page="records"]:not(.auth-locked) .main-content,
  html body[data-page="records"]:not(.auth-locked) .content-area {
    padding: 22px 28px 34px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .workspace {
    display: block !important;
    min-height: auto !important;
    padding: 0 !important;
    background: transparent !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    min-height: calc(100vh - 56px) !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title {
    display: block !important;
    margin: 0 0 28px !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title h2 {
    margin: 0 !important;
    color: #0f172a !important;
    font-size: clamp(40px, 3.7vw, 56px) !important;
    line-height: .95 !important;
    font-weight: 900 !important;
    letter-spacing: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsHint {
    display: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox.record-search {
    display: grid !important;
    grid-template-columns: 48px minmax(260px, 1fr) !important;
    align-items: center !important;
    width: min(100%, 930px) !important;
    height: 66px !important;
    margin: 0 0 26px !important;
    padding: 0 24px 0 18px !important;
    border: 1px solid rgba(16, 185, 129, .28) !important;
    border-radius: 22px !important;
    background: linear-gradient(90deg, rgba(236, 253, 245, .88), rgba(255, 255, 255, .97)) !important;
    box-shadow: 0 10px 28px rgba(15, 23, 42, .05), inset 0 0 0 1px rgba(16, 185, 129, .08) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox .record-search-label {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox .record-search-icon {
    display: grid !important;
    place-items: center !important;
    width: 38px !important;
    height: 38px !important;
    color: #059669 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox .record-search-icon svg {
    width: 27px !important;
    height: 27px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox input {
    width: 100% !important;
    height: 100% !important;
    padding: 0 !important;
    border: 0 !important;
    outline: 0 !important;
    background: transparent !important;
    color: #0f172a !important;
    font-size: 17px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox input::placeholder {
    color: #8a96a8 !important;
    opacity: 1 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsList.records-list {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-board {
    width: 100% !important;
    padding: 34px 28px 24px !important;
    border: 1px solid rgba(226, 232, 240, .92) !important;
    border-radius: 24px !important;
    background: rgba(255, 255, 255, .94) !important;
    box-shadow: 0 24px 60px rgba(15, 23, 42, .08) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-toolbar {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 20px !important;
    margin-bottom: 28px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-filters {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-filter {
    display: inline-flex !important;
    align-items: center !important;
    gap: 12px !important;
    height: 52px !important;
    padding: 0 22px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 17px !important;
    background: #fff !important;
    color: #64748b !important;
    box-shadow: 0 8px 20px rgba(15, 23, 42, .04) !important;
    font-size: 16px !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    cursor: pointer !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-filter strong {
    display: inline-grid !important;
    place-items: center !important;
    min-width: 28px !important;
    height: 28px !important;
    padding: 0 8px !important;
    border-radius: 999px !important;
    background: #eef2f7 !important;
    color: #64748b !important;
    font-size: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-filter.is-active {
    border-color: transparent !important;
    background: linear-gradient(135deg, #059669, #00a96b) !important;
    color: #fff !important;
    box-shadow: 0 16px 30px rgba(5, 150, 105, .24) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-filter.is-active strong {
    background: rgba(255, 255, 255, .18) !important;
    color: #fff !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-filter.is-danger strong {
    background: #ffe4e9 !important;
    color: #e11d48 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-filter.is-warning strong {
    background: #ffedd5 !important;
    color: #f97316 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-sort {
    display: inline-flex !important;
    align-items: center !important;
    gap: 10px !important;
    min-width: 270px !important;
    height: 52px !important;
    padding: 0 16px 0 20px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 16px !important;
    background: #fff !important;
    color: #475569 !important;
    font-size: 15px !important;
    font-weight: 800 !important;
    box-shadow: 0 8px 20px rgba(15, 23, 42, .04) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-sort select {
    flex: 1 !important;
    min-width: 0 !important;
    border: 0 !important;
    outline: 0 !important;
    background: transparent !important;
    color: #0f172a !important;
    font: inherit !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-list {
    display: grid !important;
    gap: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-card {
    display: grid !important;
    grid-template-columns: minmax(300px, 1.55fr) minmax(150px, .72fr) minmax(150px, .76fr) minmax(170px, .9fr) minmax(250px, 1.25fr) 178px 58px !important;
    align-items: center !important;
    gap: 22px !important;
    min-height: 136px !important;
    padding: 22px 20px !important;
    border: 1px solid #e8eef5 !important;
    border-radius: 18px !important;
    background: #fff !important;
    box-shadow: 0 12px 28px rgba(15, 23, 42, .06) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-person {
    display: grid !important;
    grid-template-columns: 82px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 20px !important;
    min-width: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-avatar {
    display: grid !important;
    place-items: center !important;
    width: 82px !important;
    height: 82px !important;
    overflow: hidden !important;
    border-radius: 999px !important;
    background: #ecfdf5 !important;
    color: #059669 !important;
    font-size: 28px !important;
    font-weight: 900 !important;
    box-shadow: inset 0 0 0 1px rgba(5, 150, 105, .12) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-avatar img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-person-copy,
  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-person-copy > div {
    min-width: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-person-copy > div {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    margin-bottom: 8px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-name {
    min-width: 0 !important;
    border: 0 !important;
    background: transparent !important;
    color: #0f172a !important;
    font-size: 22px !important;
    font-weight: 900 !important;
    line-height: 1.15 !important;
    text-align: left !important;
    cursor: pointer !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-person-copy span,
  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-person-copy small {
    display: block !important;
    color: #64748b !important;
    font-size: 15px !important;
    font-weight: 760 !important;
    line-height: 1.45 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-tag,
  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-status {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: fit-content !important;
    min-height: 34px !important;
    padding: 7px 13px !important;
    border-radius: 12px !important;
    background: #dcfce7 !important;
    color: #059669 !important;
    font-size: 15px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-tag.is-danger,
  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-status.is-danger {
    background: #ffe4e9 !important;
    color: #e11d48 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-tag.is-warning,
  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-status.is-warning {
    background: #dcfce7 !important;
    color: #059669 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-tag.is-closed,
  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-status.is-closed {
    background: #eef2f7 !important;
    color: #64748b !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-metric {
    min-width: 0 !important;
    padding-left: 22px !important;
    border-left: 1px solid #e8eef5 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-metric span,
  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-progress > span {
    display: block !important;
    margin-bottom: 9px !important;
    color: #64748b !important;
    font-size: 14px !important;
    font-weight: 820 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-metric strong {
    display: block !important;
    color: #0f172a !important;
    font-size: 22px !important;
    font-weight: 900 !important;
    line-height: 1.1 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-card.is-danger .desktop-debtor-metric:first-of-type strong {
    color: #e11d48 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-metric small {
    display: block !important;
    margin-top: 6px !important;
    color: #f97316 !important;
    font-size: 14px !important;
    font-weight: 900 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-metric small.is-danger {
    color: #e11d48 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-progress {
    min-width: 0 !important;
    padding-left: 22px !important;
    border-left: 1px solid #e8eef5 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-progress-track {
    width: 100% !important;
    height: 9px !important;
    overflow: hidden !important;
    border-radius: 999px !important;
    background: #e8eef5 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-progress-track i {
    display: block !important;
    height: 100% !important;
    border-radius: inherit !important;
    background: linear-gradient(90deg, #059669, #10b981) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-card.is-danger .desktop-debtor-progress-track i {
    background: linear-gradient(90deg, #e11d48, #fb7185) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-progress > div:last-of-type {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 10px !important;
    margin-top: 11px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-progress small {
    color: #64748b !important;
    font-size: 13px !important;
    font-weight: 780 !important;
    line-height: 1.25 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-progress strong {
    color: #0f172a !important;
    font-size: 16px !important;
    font-weight: 900 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-actions {
    display: grid !important;
    gap: 10px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-actions button {
    width: 100% !important;
    height: 50px !important;
    border-radius: 13px !important;
    font-size: 15px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-actions .primary-button {
    background: linear-gradient(135deg, #059669, #009b62) !important;
    color: #fff !important;
    border: 0 !important;
    box-shadow: 0 12px 24px rgba(5, 150, 105, .22) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-actions .secondary-button {
    background: #fff !important;
    color: #0f172a !important;
    border: 1px solid #e2e8f0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-more {
    position: relative !important;
    display: flex !important;
    justify-content: center !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-more-button,
  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-pagination button {
    display: inline-grid !important;
    place-items: center !important;
    width: 50px !important;
    height: 50px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 14px !important;
    background: #fff !important;
    color: #0f172a !important;
    font-size: 24px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    cursor: pointer !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-more-panel {
    position: absolute !important;
    z-index: 20 !important;
    top: 58px !important;
    right: 0 !important;
    display: grid !important;
    gap: 6px !important;
    width: 170px !important;
    padding: 10px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 14px !important;
    background: #fff !important;
    box-shadow: 0 18px 40px rgba(15, 23, 42, .14) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-more-panel button {
    min-height: 36px !important;
    border: 0 !important;
    border-radius: 10px !important;
    background: transparent !important;
    color: #0f172a !important;
    font-size: 14px !important;
    font-weight: 850 !important;
    text-align: left !important;
    cursor: pointer !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-more-panel button:hover {
    background: #f1f5f9 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-more-panel button.is-danger {
    color: #e11d48 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-empty {
    display: grid !important;
    place-items: center !important;
    min-height: 180px !important;
    border: 1px dashed #cbd5e1 !important;
    border-radius: 18px !important;
    background: #f8fafc !important;
    color: #64748b !important;
    font-size: 18px !important;
    font-weight: 850 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-footer {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto minmax(160px, auto) !important;
    align-items: center !important;
    gap: 16px !important;
    margin-top: 26px !important;
    color: #64748b !important;
    font-size: 15px !important;
    font-weight: 820 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-pagination {
    display: flex !important;
    justify-content: center !important;
    gap: 9px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-pagination button {
    width: 46px !important;
    height: 46px !important;
    font-size: 17px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-pagination button.is-active {
    border-color: transparent !important;
    background: linear-gradient(135deg, #059669, #009b62) !important;
    color: #fff !important;
    box-shadow: 0 12px 22px rgba(5, 150, 105, .2) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-pagination button:disabled {
    opacity: .45 !important;
    cursor: default !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-page-size {
    display: inline-flex !important;
    justify-content: flex-end !important;
    align-items: center !important;
    gap: 10px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-page-size strong {
    display: inline-grid !important;
    place-items: center !important;
    min-width: 64px !important;
    height: 46px !important;
    padding: 0 16px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 14px !important;
    background: #fff !important;
    color: #0f172a !important;
  }
}

@media (min-width: 769px) and (max-width: 1280px) {
  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-card {
    grid-template-columns: minmax(260px, 1.4fr) minmax(138px, .7fr) minmax(138px, .72fr) minmax(150px, .8fr) minmax(210px, 1fr) 150px 52px !important;
    gap: 16px !important;
    padding: 20px 16px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-person {
    grid-template-columns: 68px minmax(0, 1fr) !important;
    gap: 15px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-avatar {
    width: 68px !important;
    height: 68px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-name {
    font-size: 19px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-metric strong {
    font-size: 19px !important;
  }
}

@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) .app-shell.loan-app {
    display: grid !important;
    grid-template-columns: 300px minmax(0, 1fr) !important;
    gap: 24px !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .content-shell.main-content,
  html body[data-page="records"]:not(.auth-locked) .content-shell.main-area,
  html body[data-page="records"]:not(.auth-locked) .content-shell.content-area {
    display: block !important;
    grid-column: auto !important;
    width: auto !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .workspace,
  html body[data-page="records"]:not(.auth-locked) .workspace .results,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel,
  html body[data-page="records"]:not(.auth-locked) #recordsList,
  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-board {
    width: 100% !important;
    max-width: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-card {
    width: 100% !important;
    max-width: 100% !important;
    grid-template-columns: minmax(220px, 1.12fr) minmax(106px, .56fr) minmax(110px, .58fr) minmax(124px, .66fr) minmax(164px, .88fr) 132px 42px !important;
    gap: 10px !important;
    padding: 20px 18px !important;
  }
}

/* Desktop sidebar repair, 2026-05-21. Keeps mobile tab bar rules below 768px only. */
@media (min-width: 769px) {
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar {
    position: sticky !important;
    inset: auto !important;
    top: 0 !important;
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
    display: grid !important;
    flex-direction: initial !important;
    grid-template-columns: 1fr !important;
    grid-auto-rows: max-content !important;
    grid-template-rows: none !important;
    align-content: start !important;
    align-items: stretch !important;
    gap: 8px !important;
    width: 292px !important;
    min-width: 292px !important;
    max-width: 292px !important;
    height: 100vh !important;
    min-height: 100vh !important;
    max-height: 100vh !important;
    margin: 0 !important;
    padding: 34px 32px 28px !important;
    border-radius: 0 !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    background: #ffffff !important;
    box-shadow: 10px 0 30px rgba(15, 23, 42, .06) !important;
    transform: none !important;
  }

  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link.mobile-only-nav-link,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link.mobile-only-nav-link,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link.mobile-only-nav-link,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > button#mobileCreateNav {
    display: none !important;
  }

  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link[data-mobile-label],
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link {
    position: relative !important;
    display: grid !important;
    grid-template-columns: 26px minmax(0, 1fr) 14px !important;
    grid-template-rows: none !important;
    align-items: center !important;
    justify-items: stretch !important;
    place-items: initial !important;
    justify-content: stretch !important;
    align-content: center !important;
    gap: 12px !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    height: 48px !important;
    min-height: 48px !important;
    max-height: 48px !important;
    margin: 12px 0 0 !important;
    padding: 0 14px !important;
    border-radius: 14px !important;
    text-align: left !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    transform: none !important;
  }

  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link[data-mobile-label]::after,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link[href="#dashboardPanel"] .nav-label::after,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a[href="#settingsPanel"].mobile-settings-link .nav-label::after {
    content: none !important;
    display: none !important;
  }

  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link[data-mobile-label] > span.nav-label,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link[href="#dashboardPanel"] .nav-label {
    position: static !important;
    inset: auto !important;
    grid-row: auto !important;
    display: block !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    margin: 0 !important;
    overflow: hidden !important;
    color: inherit !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: 14px !important;
    font-weight: 400 !important;
    line-height: 1.2 !important;
    letter-spacing: 0 !important;
    text-align: left !important;
    text-indent: 0 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
  }

  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-icon,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-icon,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-icon {
    grid-row: auto !important;
    position: static !important;
    inset: auto !important;
    display: grid !important;
    place-items: center !important;
    width: 26px !important;
    min-width: 26px !important;
    max-width: 26px !important;
    height: 26px !important;
    min-height: 26px !important;
    max-height: 26px !important;
    margin: 0 !important;
    padding: 0 !important;
    color: currentColor !important;
    background: transparent !important;
    transform: none !important;
  }

  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-brand {
    display: grid !important;
    grid-template-columns: 46px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 12px !important;
    min-height: 76px !important;
    margin: 0 0 20px !important;
  }

  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user {
    display: grid !important;
    margin-top: auto !important;
    padding-top: 18px !important;
  }

  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link.mobile-only-nav-link,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link.mobile-only-nav-link,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link.mobile-only-nav-link,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > button#mobileCreateNav {
    display: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title::before,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title::after {
    content: none !important;
    display: none !important;
    background: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title {
    height: 66px !important;
    min-height: 66px !important;
    margin: 0 0 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title h2 {
    font-size: clamp(34px, 2.45vw, 39px) !important;
    line-height: 1.05 !important;
    font-weight: 880 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox.record-search {
    grid-template-columns: 38px minmax(0, 1fr) !important;
    width: min(100%, 460px) !important;
    height: 50px !important;
    margin: 0 0 16px !important;
    padding: 0 18px 0 14px !important;
    border-radius: 16px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox .record-search-icon {
    position: static !important;
    grid-column: 1 !important;
    align-self: center !important;
    width: 30px !important;
    height: 30px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox .record-search-icon svg {
    width: 23px !important;
    height: 23px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox input {
    grid-column: 2 !important;
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 100% !important;
    font-size: 14px !important;
    outline: 0 !important;
    box-shadow: none !important;
    -webkit-appearance: none !important;
    appearance: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox input:focus,
  html body[data-page="records"]:not(.auth-locked) #recordSearchBox input:focus-visible {
    outline: 0 !important;
    box-shadow: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox.record-search:focus-within {
    border-color: rgba(16, 185, 129, .36) !important;
    box-shadow: 0 12px 28px rgba(15, 23, 42, .06), inset 0 0 0 1px rgba(16, 185, 129, .1) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-board {
    padding-top: 30px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel {
    position: relative !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox.record-search {
    position: absolute !important;
    top: 13px !important;
    right: 0 !important;
    z-index: 3 !important;
    width: min(460px, calc(100% - 320px)) !important;
    margin: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title {
    padding-right: min(500px, 48%) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsList.records-list {
    padding-top: 8px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title {
    display: grid !important;
    align-items: center !important;
    min-height: 118px !important;
    height: 118px !important;
    margin: 0 0 26px !important;
    padding: 24px 690px 24px 34px !important;
    border: 1px solid rgba(226, 232, 240, .92) !important;
    border-radius: 24px !important;
    background: rgba(255, 255, 255, .96) !important;
    box-shadow: 0 20px 48px rgba(15, 23, 42, .08) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title h2 {
    margin: 0 !important;
    font-size: clamp(34px, 2.7vw, 42px) !important;
    line-height: 1.02 !important;
    font-weight: 900 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title h2::before {
    content: "ระบบเงินกู้" !important;
    display: block !important;
    margin: 0 0 6px !important;
    color: #009b62 !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: 14px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title::after {
    content: "ณเอก wichapom" !important;
    position: absolute !important;
    top: 34px !important;
    right: 34px !important;
    display: inline-grid !important;
    place-items: center !important;
    min-width: 132px !important;
    height: 58px !important;
    padding: 0 24px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 999px !important;
    background: #ffffff !important;
    color: #0f172a !important;
    box-shadow: 0 12px 26px rgba(15, 23, 42, .06) !important;
    font-size: 16px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox.record-search {
    top: 34px !important;
    right: 210px !important;
    width: min(500px, calc(100% - 520px)) !important;
    height: 58px !important;
    grid-template-columns: 48px minmax(0, 1fr) !important;
    padding: 0 24px 0 18px !important;
    border-color: #e2e8f0 !important;
    border-radius: 999px !important;
    background: #f8fafc !important;
    box-shadow: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox .record-search-icon {
    width: 36px !important;
    height: 36px !important;
    color: #94a3b8 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    align-self: center !important;
    justify-self: center !important;
    margin: 0 !important;
    transform: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox .record-search-icon svg {
    display: block !important;
    width: 24px !important;
    height: 24px !important;
    margin: 0 !important;
    transform: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox input {
    color: #0f172a !important;
    font-size: 16px !important;
    font-weight: 760 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox input::placeholder {
    color: #94a3b8 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsList.records-list {
    padding-top: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-board {
    padding-top: 30px !important;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title {
    padding-right: 34px !important;
    padding-bottom: 92px !important;
    min-height: 184px !important;
    height: 184px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox.record-search {
    top: 104px !important;
    left: 34px !important;
    right: 34px !important;
    width: auto !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title::after {
    top: 24px !important;
    right: 34px !important;
  }
}

/* Hide Dashboard latest customers on desktop only, 2026-05-21. */
@media (min-width: 769px) {
  html.mobile-nav-labels-on body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel.dashboard-page .dashboard-mobile-customers,
  html.mobile-nav-labels-on body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-mobile-customers,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel.dashboard-page .dashboard-mobile-customers,
  html body[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-mobile-customers {
    display: none !important;
  }
}

/* Customer profiles desktop topbar: match dashboard header, 2026-05-21. */
@media (min-width: 769px) {
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel.customer-profiles-panel,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel.customer-profiles-panel,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel.customer-profiles-panel {
    position: relative !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title {
    position: relative !important;
    display: grid !important;
    align-items: center !important;
    min-height: 118px !important;
    height: 118px !important;
    margin: 0 0 28px !important;
    padding: 24px 690px 24px 34px !important;
    border: 1px solid rgba(226, 232, 240, .92) !important;
    border-radius: 24px !important;
    background: rgba(255, 255, 255, .96) !important;
    box-shadow: 0 20px 48px rgba(15, 23, 42, .08) !important;
    overflow: visible !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title > div,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title > div,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title > div {
    min-width: 0 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title h2,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title h2,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title h2 {
    margin: 0 !important;
    color: #0f172a !important;
    font-size: clamp(34px, 2.7vw, 42px) !important;
    line-height: 1.02 !important;
    font-weight: 900 !important;
    letter-spacing: 0 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title h2::before,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title h2::before,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title h2::before {
    content: "ระบบเงินกู้" !important;
    display: block !important;
    margin: 0 0 6px !important;
    color: #009b62 !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: 14px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesHint,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesHint,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesHint {
    display: none !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title::after,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title::after,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title::after {
    content: "ณเอก wichapom" !important;
    position: absolute !important;
    top: 34px !important;
    right: 34px !important;
    display: inline-grid !important;
    place-items: center !important;
    min-width: 132px !important;
    height: 58px !important;
    padding: 0 24px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 999px !important;
    background: #ffffff !important;
    color: #0f172a !important;
    box-shadow: 0 12px 26px rgba(15, 23, 42, .06) !important;
    font-size: 16px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search {
    position: absolute !important;
    top: 34px !important;
    right: 210px !important;
    z-index: 3 !important;
    display: grid !important;
    grid-template-columns: 48px minmax(0, 1fr) !important;
    align-items: center !important;
    width: min(500px, calc(100% - 520px)) !important;
    height: 58px !important;
    min-height: 58px !important;
    margin: 0 !important;
    padding: 0 24px 0 18px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 999px !important;
    background: #f8fafc !important;
    box-shadow: none !important;
    overflow: hidden !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search::before,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search::before,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search::before {
    content: "" !important;
    display: block !important;
    width: 36px !important;
    height: 36px !important;
    align-self: center !important;
    justify-self: center !important;
    background: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m20 20-4.25-4.25M10.75 18a7.25 7.25 0 1 1 0-14.5 7.25 7.25 0 0 1 0 14.5Z' stroke='%2394a3b8' stroke-width='2.1' stroke-linecap='round'/%3E%3C/svg%3E") center / 27px 27px no-repeat !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search > span,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search > span,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search > span {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    clip: rect(0 0 0 0) !important;
    clip-path: inset(50%) !important;
    overflow: hidden !important;
    white-space: nowrap !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfileSearch,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfileSearch,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfileSearch {
    grid-column: 2 !important;
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    color: #0f172a !important;
    box-shadow: none !important;
    outline: 0 !important;
    font-size: 16px !important;
    font-weight: 760 !important;
    line-height: 1 !important;
    -webkit-appearance: none !important;
    appearance: none !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfileSearch::placeholder,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfileSearch::placeholder,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfileSearch::placeholder {
    color: #94a3b8 !important;
    opacity: 1 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search:focus-within,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search:focus-within,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search:focus-within {
    border-color: rgba(16, 185, 129, .36) !important;
    box-shadow: 0 12px 28px rgba(15, 23, 42, .06), inset 0 0 0 1px rgba(16, 185, 129, .1) !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesList.customer-profile-list,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesList.customer-profile-list,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesList.customer-profile-list {
    margin-top: 0 !important;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title {
    min-height: 184px !important;
    height: 184px !important;
    padding-right: 34px !important;
    padding-bottom: 92px !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search {
    top: 104px !important;
    right: 34px !important;
    left: 34px !important;
    width: auto !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title::after,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title::after,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title::after {
    top: 24px !important;
    right: 34px !important;
  }
}

/* Customer profiles uses the main desktop header; remove duplicate inner header/search. */
@media (min-width: 769px) {
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search {
    display: none !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel.customer-profiles-panel,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel.customer-profiles-panel,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel.customer-profiles-panel {
    margin-top: 36px !important;
    padding-top: 26px !important;
  }
}

/* Customer profiles desktop main header: compact like the dashboard reference. */
@media (min-width: 769px) {
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-topbar.app-topbar.page-header.topbar,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-topbar.app-topbar.page-header.topbar,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-topbar.app-topbar.page-header.topbar {
    position: static !important;
    display: grid !important;
    grid-template-columns: minmax(230px, 1fr) minmax(360px, 500px) auto !important;
    align-items: center !important;
    column-gap: 24px !important;
    width: 100% !important;
    min-height: 118px !important;
    height: 118px !important;
    max-height: 118px !important;
    margin: 0 0 36px !important;
    padding: 24px 34px !important;
    border: 1px solid rgba(226, 232, 240, .92) !important;
    border-radius: 24px !important;
    background: rgba(255, 255, 255, .96) !important;
    box-shadow: 0 20px 48px rgba(15, 23, 42, .08) !important;
    overflow: visible !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-topbar-title,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-topbar-title,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-topbar-title {
    grid-column: 1 !important;
    display: block !important;
    min-width: 0 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .topbar-kicker,
  html body[data-page="customerProfiles"]:not(.auth-locked) .topbar-kicker,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .topbar-kicker {
    display: block !important;
    margin: 0 0 6px !important;
    color: #009b62 !important;
    font-size: 14px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle,
  html body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #topPageTitle {
    margin: 0 !important;
    color: #0f172a !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: clamp(34px, 2.7vw, 42px) !important;
    font-weight: 900 !important;
    line-height: 1.02 !important;
    letter-spacing: 0 !important;
    white-space: nowrap !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .global-search.global-search,
  html body[data-page="customerProfiles"]:not(.auth-locked) .global-search.global-search,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .global-search.global-search {
    position: relative !important;
    grid-column: 2 !important;
    display: grid !important;
    grid-template-columns: 48px minmax(0, 1fr) !important;
    align-items: center !important;
    width: 100% !important;
    max-width: 500px !important;
    height: 58px !important;
    min-height: 58px !important;
    margin: 0 !important;
    padding: 0 24px 0 18px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 999px !important;
    background: #f8fafc !important;
    box-shadow: none !important;
    overflow: hidden !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .global-search::before,
  html body[data-page="customerProfiles"]:not(.auth-locked) .global-search::before,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .global-search::before {
    content: "" !important;
    position: static !important;
    display: block !important;
    width: 36px !important;
    height: 36px !important;
    align-self: center !important;
    justify-self: center !important;
    background: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m20 20-4.25-4.25M10.75 18a7.25 7.25 0 1 1 0-14.5 7.25 7.25 0 0 1 0 14.5Z' stroke='%2394a3b8' stroke-width='2.1' stroke-linecap='round'/%3E%3C/svg%3E") center / 27px 27px no-repeat !important;
    opacity: 1 !important;
    transform: none !important;
    -webkit-mask: none !important;
    mask: none !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .global-search::after,
  html body[data-page="customerProfiles"]:not(.auth-locked) .global-search::after,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .global-search::after {
    display: none !important;
    content: none !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .global-search input,
  html body[data-page="customerProfiles"]:not(.auth-locked) .global-search input,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .global-search input {
    grid-column: 2 !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    color: #0f172a !important;
    font-size: 16px !important;
    font-weight: 760 !important;
    line-height: 1 !important;
    box-shadow: none !important;
    outline: 0 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .global-search input::placeholder,
  html body[data-page="customerProfiles"]:not(.auth-locked) .global-search input::placeholder,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .global-search input::placeholder {
    color: #94a3b8 !important;
    opacity: 1 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .topbar-actions,
  html body[data-page="customerProfiles"]:not(.auth-locked) .topbar-actions,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .topbar-actions {
    grid-column: 3 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    width: auto !important;
    min-width: 0 !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .notification-button,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .mobile-top-settings,
  html body[data-page="customerProfiles"]:not(.auth-locked) .notification-button,
  html body[data-page="customerProfiles"]:not(.auth-locked) .mobile-top-settings,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .notification-button,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .mobile-top-settings {
    display: none !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .topbar-user,
  html body[data-page="customerProfiles"]:not(.auth-locked) .topbar-user,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .topbar-user {
    display: inline-grid !important;
    place-items: center !important;
    min-width: 132px !important;
    width: auto !important;
    height: 58px !important;
    min-height: 58px !important;
    padding: 0 24px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 999px !important;
    background: #ffffff !important;
    color: #0f172a !important;
    box-shadow: 0 12px 26px rgba(15, 23, 42, .06) !important;
    font-size: 16px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-topbar.app-topbar.page-header.topbar,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-topbar.app-topbar.page-header.topbar,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-topbar.app-topbar.page-header.topbar {
    grid-template-columns: minmax(0, 1fr) auto !important;
    grid-template-rows: auto 58px !important;
    row-gap: 16px !important;
    min-height: 184px !important;
    height: 184px !important;
    max-height: 184px !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .global-search.global-search,
  html body[data-page="customerProfiles"]:not(.auth-locked) .global-search.global-search,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .global-search.global-search {
    grid-column: 1 / -1 !important;
    grid-row: 2 !important;
    max-width: none !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .topbar-actions,
  html body[data-page="customerProfiles"]:not(.auth-locked) .topbar-actions,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .topbar-actions {
    grid-column: 2 !important;
    grid-row: 1 !important;
  }
}

/* Customer profiles desktop spacing: keep content directly under compact header. */
@media (min-width: 769px) {
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .content-shell.content-shell,
  html body[data-page="customerProfiles"]:not(.auth-locked) .content-shell.content-shell,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .content-shell.content-shell {
    display: block !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .workspace,
  html body[data-page="customerProfiles"]:not(.auth-locked) .workspace,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .workspace {
    display: block !important;
    margin-top: 0 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel.customer-profiles-panel,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel.customer-profiles-panel,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel.customer-profiles-panel {
    margin-top: 0 !important;
  }
}

/* Customer profiles desktop font: match desktop debtors page. */
@media (min-width: 769px) {
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked),
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) *,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) *::before,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) *::after,
  html body[data-page="customerProfiles"]:not(.auth-locked),
  html body[data-page="customerProfiles"]:not(.auth-locked) *,
  html body[data-page="customerProfiles"]:not(.auth-locked) *::before,
  html body[data-page="customerProfiles"]:not(.auth-locked) *::after,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked),
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) *,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) *::before,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) *::after {
    font-family: "TH Sarabun New", "TH SarabunPSK", "TH Sarabun", Sarabun, sans-serif !important;
    letter-spacing: normal !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle,
  html body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #topPageTitle {
    font-family: "Krungthai Fast", "IBM Plex Sans Thai", Sarabun, sans-serif !important;
    font-weight: 900 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle *,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle::before,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle::after,
  html body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle *,
  html body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle::before,
  html body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle::after,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #topPageTitle *,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #topPageTitle::before,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #topPageTitle::after {
    font-family: "Krungthai Fast", "IBM Plex Sans Thai", Sarabun, sans-serif !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .topbar-kicker,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .global-search input,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .topbar-user,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel button,
  html body[data-page="customerProfiles"]:not(.auth-locked) .topbar-kicker,
  html body[data-page="customerProfiles"]:not(.auth-locked) .global-search input,
  html body[data-page="customerProfiles"]:not(.auth-locked) .topbar-user,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel button,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .topbar-kicker,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .global-search input,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .topbar-user,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel button {
    font-family: "TH Sarabun New", "TH SarabunPSK", "TH Sarabun", Sarabun, sans-serif !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .topbar-user,
  html body[data-page="customerProfiles"]:not(.auth-locked) .topbar-user,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .topbar-user {
    font-size: 20px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .global-search input,
  html body[data-page="customerProfiles"]:not(.auth-locked) .global-search input,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .global-search input {
    font-size: 22px !important;
    font-weight: 760 !important;
    line-height: 1 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel .customer-profile-list,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel table,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel th,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel td,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel .customer-profile-card,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel .customer-profile-card *,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel .customer-profile-list,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel table,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel th,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel td,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel .customer-profile-card,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel .customer-profile-card *,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel .customer-profile-list,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel table,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel th,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel td,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel .customer-profile-card,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel .customer-profile-card * {
    font-family: "TH Sarabun New", "TH SarabunPSK", "TH Sarabun", Sarabun, sans-serif !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel th,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel th,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel th {
    font-size: 22px !important;
    font-weight: 760 !important;
    line-height: 1.1 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel td,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel td strong,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel td,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel td strong,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel td,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel td strong {
    font-size: 22px !important;
    font-weight: 900 !important;
    line-height: 1.1 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel button,
  html body[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel button,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel button {
    font-size: 18px !important;
    font-weight: 760 !important;
    line-height: 1 !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .side-brand-copy,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .side-brand-copy *,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .nav-label,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .nav-label::before,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .nav-label::after,
  html body[data-page="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .side-brand-copy,
  html body[data-page="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .side-brand-copy *,
  html body[data-page="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .nav-label::before,
  html body[data-page="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .nav-label::after,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .side-brand-copy,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .side-brand-copy *,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .nav-label,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .nav-label::before,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .quick-nav.quick-nav .nav-label::after {
    font-family: "TH Sarabun New", "TH SarabunPSK", "TH Sarabun", Sarabun, sans-serif !important;
    letter-spacing: normal !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label {
    font-family: "TH Sarabun New", "TH SarabunPSK", "TH Sarabun", Sarabun, sans-serif !important;
    letter-spacing: normal !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-topbar-title,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-topbar-title,
  html body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-topbar-title,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #topPageTitle {
    overflow: visible !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle,
  html body[data-page="customerProfiles"]:not(.auth-locked) #topPageTitle,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) #topPageTitle {
    line-height: 1.16 !important;
    padding-bottom: 6px !important;
  }
}

/* Desktop sidebar font lock: keep the left menu identical on every page. */
@media (min-width: 769px) {
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar {
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 16px !important;
    font-weight: 300 !important;
    line-height: 23.2px !important;
    letter-spacing: normal !important;
  }

  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-brand-copy,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-brand-copy,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-brand-copy {
    font-family: Inter, "IBM Plex Sans Thai", system-ui, sans-serif !important;
    font-size: 11.52px !important;
    font-weight: 800 !important;
    line-height: 11.52px !important;
    letter-spacing: normal !important;
  }

  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-brand-copy span,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-brand-copy span,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-brand-copy span {
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 11px !important;
    font-weight: 800 !important;
    line-height: 12.1px !important;
    letter-spacing: normal !important;
  }

  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar #sideBrandName,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar #sideBrandName,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar #sideBrandName {
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 16px !important;
    font-weight: 700 !important;
    line-height: 19.2px !important;
    letter-spacing: normal !important;
  }

  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link {
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 15px !important;
    font-weight: 500 !important;
    line-height: 18px !important;
    letter-spacing: normal !important;
  }

  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label {
    font-family: "IBM Plex Sans Thai", Sarabun, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: 14px !important;
    font-weight: 400 !important;
    line-height: 16.8px !important;
    letter-spacing: normal !important;
  }

  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-chevron,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-chevron,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-chevron {
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 15px !important;
    font-weight: 500 !important;
    line-height: 18px !important;
    letter-spacing: normal !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label,
  html.mobile-nav-labels-on body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html.mobile-nav-labels-on body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html.mobile-nav-labels-on body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label {
    font-family: "IBM Plex Sans Thai", Sarabun, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: 14px !important;
    font-weight: 400 !important;
    line-height: 16.8px !important;
    letter-spacing: normal !important;
  }

  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-chevron,
  html.mobile-nav-labels-on body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html.mobile-nav-labels-on body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-chevron,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-chevron,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html body[data-records-subview="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-chevron {
    font-family: "IBM Plex Sans Thai", Inter, system-ui, sans-serif !important;
    font-size: 15px !important;
    font-weight: 500 !important;
    line-height: 18px !important;
    letter-spacing: normal !important;
  }
}

/* Desktop sidebar menu text weight lock: keep every menu label equally thick. */
@media (min-width: 769px) {
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link.active > span.nav-label,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label,
  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link.active > span.nav-label,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link.active > span.nav-label,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link.active > span.nav-label,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link > span.nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar > a.sidebar-link.active > span.nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-toggle > span.nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-group-items .sidebar-link > span.nav-label,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .side-user .nav-text-link > span.nav-label {
    font-family: "IBM Plex Sans Thai", Sarabun, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: 14px !important;
    font-weight: 400 !important;
    line-height: 16.8px !important;
    letter-spacing: normal !important;
  }

  html body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-chevron,
  html body[data-page]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-chevron,
  html.mobile-nav-labels-on body:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-chevron,
  html body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-chevron,
  html.mobile-nav-labels-on body[data-page="customerProfiles"]:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar .nav-chevron {
    font-size: 14px !important;
    font-weight: 400 !important;
    line-height: 16.8px !important;
  }
}

/* Runtime fence: mobile/tablet touch views must not inherit late desktop patches. */
@media (hover: none), (pointer: coarse), (max-width: 1200px) {
  html.mobile-runtime body.mobile-runtime:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar,
  html body.mobile-runtime:not(.auth-locked) .app-shell.loan-app > nav.quick-nav.sidebar.side-nav.app-sidebar {
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .app-topbar,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .app-topbar.page-header,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .app-topbar.topbar,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .app-topbar,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .app-topbar.page-header,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .app-topbar.topbar {
    display: none !important;
    height: 0 !important;
    min-height: 0 !important;
    max-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .content-shell,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .content-shell.main-content,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .main-content,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .content-shell,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .content-shell.main-content,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .main-content {
    padding-top: max(12px, env(safe-area-inset-top)) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="customerProfiles"]:not(.auth-locked) .content-shell.content-shell,
  html body.mobile-runtime[data-page="customerProfiles"]:not(.auth-locked) .content-shell.content-shell,
  html.mobile-runtime body.mobile-runtime[data-records-subview="customerProfiles"]:not(.auth-locked) .content-shell.content-shell,
  html body.mobile-runtime[data-records-subview="customerProfiles"]:not(.auth-locked) .content-shell.content-shell {
    display: grid !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title,
  html.mobile-runtime body.mobile-runtime[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search,
  html body.mobile-runtime[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title,
  html body.mobile-runtime[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search,
  html.mobile-runtime body.mobile-runtime[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title,
  html.mobile-runtime body.mobile-runtime[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search,
  html body.mobile-runtime[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > .panel-title,
  html body.mobile-runtime[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel > label.record-search {
    display: revert !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel.customer-profiles-panel,
  html body.mobile-runtime[data-page="customerProfiles"]:not(.auth-locked) #customerProfilesPanel.customer-profiles-panel,
  html.mobile-runtime body.mobile-runtime[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel.customer-profiles-panel,
  html body.mobile-runtime[data-records-subview="customerProfiles"]:not(.auth-locked) #customerProfilesPanel.customer-profiles-panel {
    margin-top: revert !important;
    padding-top: revert !important;
  }
}

/* Mobile dashboard header reset: keep the original mobile dashboard layout clean. */
@media (hover: none), (pointer: coarse), (max-width: 1200px) {
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-top-row,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel .dashboard-hero h2,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardMobileDate,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardMobileDate {
    display: none !important;
    height: 0 !important;
    min-height: 0 !important;
    max-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel.dashboard-page,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel.dashboard-page {
    gap: 8px !important;
    padding-top: 0 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel.dashboard-work-panel,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardWorkPanel.dashboard-work-panel {
    margin-top: 0 !important;
  }
}

/* Mobile dashboard exact reference pass: phone/touch dashboard only, no desktop selectors. */
@media (hover: none), (pointer: coarse), (max-width: 1200px) {
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked),
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) {
    background:
      radial-gradient(circle at 18% 16%, rgba(214, 255, 235, .8), transparent 34%),
      radial-gradient(circle at 88% 28%, rgba(219, 234, 254, .9), transparent 32%),
      #eef5ff !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .content-shell,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .content-shell.main-content,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .main-content,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .content-shell,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .content-shell.main-content,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .main-content {
    padding: max(8px, env(safe-area-inset-top)) 10px calc(94px + env(safe-area-inset-bottom)) !important;
    background: transparent !important;
    overflow-x: hidden !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel.dashboard-page,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel.dashboard-page {
    display: flex !important;
    flex-direction: column !important;
    gap: clamp(12px, 2.1vw, 18px) !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .app-topbar.app-topbar,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-top-row,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-hero,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-filter-panel,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-menu-section,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-analytics-grid,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .app-topbar.app-topbar,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-top-row,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-hero,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-filter-panel,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-menu-section,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-analytics-grid {
    display: none !important;
    height: 0 !important;
    min-height: 0 !important;
    max-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel {
    order: 1 !important;
    position: relative !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: minmax(0, 1fr) clamp(48px, 8.6vw, 70px) !important;
    gap: clamp(12px, 2.5vw, 18px) !important;
    width: 100% !important;
    height: clamp(172px, 37.2vw, 268px) !important;
    min-height: clamp(172px, 37.2vw, 268px) !important;
    max-height: clamp(172px, 37.2vw, 268px) !important;
    margin: 0 !important;
    padding: clamp(19px, 4vw, 31px) clamp(22px, 4.6vw, 36px) clamp(18px, 3.8vw, 30px) !important;
    border: 0 !important;
    border-radius: clamp(19px, 4.2vw, 32px) !important;
    background:
      radial-gradient(circle at 83% 86%, rgba(46, 204, 113, .5), transparent 36%),
      linear-gradient(135deg, #09b866 0%, #06a85b 42%, #007f48 100%) !important;
    box-shadow: 0 18px 34px rgba(16, 185, 129, .22) !important;
    overflow: hidden !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel::before,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel::before {
    content: "" !important;
    position: absolute !important;
    top: 6% !important;
    right: 4% !important;
    width: clamp(116px, 35vw, 265px) !important;
    height: clamp(92px, 26vw, 198px) !important;
    background: url("data:image/svg+xml,%3Csvg width='280' height='210' viewBox='0 0 280 210' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cpath d='M203 18c18 4 33 14 43 29 22 33 9 81-28 106-40 27-96 22-126-11-27-30-24-76 6-104 25-23 68-30 105-20Z' fill='%23078a50' opacity='.26'/%3E%3Cg transform='translate(133 18)'%3E%3Crect x='20' y='0' width='86' height='118' rx='14' fill='%2346d59a'/%3E%3Crect x='28' y='19' width='70' height='87' rx='8' fill='%23e8fff4'/%3E%3Cpath d='M20 28h86v-14c0-8-6-14-14-14H34c-8 0-14 6-14 14v14Z' fill='%23008d56'/%3E%3Crect x='38' y='33' width='13' height='13' rx='2' fill='%2376d9ff'/%3E%3Crect x='59' y='33' width='13' height='13' rx='2' fill='%2310b981'/%3E%3Crect x='80' y='33' width='13' height='13' rx='2' fill='%2322c55e'/%3E%3Crect x='38' y='55' width='13' height='13' rx='2' fill='%2386efac'/%3E%3Crect x='59' y='55' width='13' height='13' rx='2' fill='%2360a5fa'/%3E%3Crect x='80' y='55' width='13' height='13' rx='2' fill='%23059669'/%3E%3Ccircle cx='94' cy='84' r='22' fill='%2310b981' stroke='%23fff' stroke-width='5'/%3E%3Cpath d='m83 84 8 8 16-18' stroke='%23fff' stroke-width='6' stroke-linecap='round' stroke-linejoin='round'/%3E%3Crect x='33' y='-7' width='10' height='24' rx='5' fill='%23dbeafe'/%3E%3Crect x='83' y='-7' width='10' height='24' rx='5' fill='%23dbeafe'/%3E%3C/g%3E%3Cg transform='translate(28 98)'%3E%3Crect x='0' y='22' width='71' height='48' rx='8' fill='%23a7f3d0' opacity='.88'/%3E%3Crect x='6' y='14' width='71' height='48' rx='8' fill='%2386efac'/%3E%3Crect x='12' y='6' width='71' height='48' rx='8' fill='%23bbf7d0'/%3E%3Ccircle cx='47' cy='30' r='14' fill='%234ade80'/%3E%3Cpath d='M47 20v20M39 30h16' stroke='%23059669' stroke-width='5' stroke-linecap='round'/%3E%3C/g%3E%3Cpath d='M211 151c20-8 33-2 40 8 5 8 3 18-7 24-19 11-45 10-73 1-12-4-15-17-5-24 11-8 27-2 45-9Z' fill='%23ffb199'/%3E%3Cpath d='M184 148c8 1 17 9 28 3 8-4 10-11 18-14 8-2 13 4 9 12-9 20-35 37-62 28-11-4-16-16-9-24 4-4 9-6 16-5Z' fill='%23ffd4c2'/%3E%3Ccircle cx='93' cy='87' r='14' fill='%23fbbf24' opacity='.95'/%3E%3Cpath d='M93 78v18M86 87h14' stroke='%23fff' stroke-width='4' stroke-linecap='round'/%3E%3Cpath d='M17 34h7v7h-7zM250 22h8v8h-8zM122 172h6v6h-6z' fill='%23fff' opacity='.92'/%3E%3C/g%3E%3C/svg%3E") center / contain no-repeat !important;
    opacity: .98 !important;
    z-index: 1 !important;
    pointer-events: none !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel::after,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-art,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-art {
    display: none !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-mobile-copy,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-mobile-copy {
    position: relative !important;
    z-index: 3 !important;
    display: grid !important;
    align-content: start !important;
    gap: clamp(7px, 1.6vw, 12px) !important;
    width: min(66%, 470px) !important;
    min-width: 0 !important;
    padding: 0 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker {
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    color: #fff !important;
    font-size: clamp(16px, 4.2vw, 31px) !important;
    font-weight: 800 !important;
    line-height: 1.12 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-title,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-title,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-people strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-people strong {
    max-width: 100% !important;
    margin: 0 !important;
    color: #fff !important;
    font-size: clamp(34px, 8.9vw, 64px) !important;
    font-weight: 900 !important;
    line-height: .98 !important;
    letter-spacing: 0 !important;
    white-space: nowrap !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-detail,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-detail,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-money small,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-money small {
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    color: rgba(255, 255, 255, .96) !important;
    font-size: clamp(16px, 4.2vw, 30px) !important;
    font-weight: 900 !important;
    line-height: 1.05 !important;
    white-space: nowrap !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-mobile-metrics,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-mobile-metrics {
    display: grid !important;
    grid-template-columns: minmax(92px, .58fr) 1px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: clamp(14px, 2.8vw, 25px) !important;
    width: min(70%, 500px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-people-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-people-icon {
    display: none !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-divider,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-divider {
    display: block !important;
    width: 1px !important;
    height: clamp(54px, 10vw, 84px) !important;
    background: rgba(255, 255, 255, .3) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-money strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-money strong {
    color: #fff !important;
    font-size: clamp(34px, 8.4vw, 58px) !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-money strong span,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-money strong span {
    font-size: clamp(17px, 4.2vw, 28px) !important;
    font-weight: 900 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel > .primary-button,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel > .primary-button {
    position: relative !important;
    z-index: 4 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    height: clamp(48px, 8.6vw, 70px) !important;
    min-height: clamp(48px, 8.6vw, 70px) !important;
    max-height: clamp(48px, 8.6vw, 70px) !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: clamp(17px, 3.4vw, 28px) !important;
    background: #fff !important;
    color: #059669 !important;
    box-shadow: 0 16px 26px rgba(15, 23, 42, .18) !important;
    font-size: clamp(22px, 5.7vw, 38px) !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    text-decoration: none !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid {
    order: 2 !important;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: clamp(10px, 2vw, 18px) !important;
    width: 100% !important;
    margin: 0 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile:nth-child(n + 3),
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile:nth-child(n + 3) {
    display: none !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile {
    position: relative !important;
    display: grid !important;
    grid-template-columns: clamp(54px, 12vw, 90px) minmax(0, 1fr) !important;
    grid-template-rows: auto auto auto !important;
    align-content: center !important;
    column-gap: clamp(12px, 2.6vw, 21px) !important;
    height: clamp(92px, 20.6vw, 148px) !important;
    min-height: clamp(92px, 20.6vw, 148px) !important;
    max-height: clamp(92px, 20.6vw, 148px) !important;
    padding: clamp(13px, 3.2vw, 24px) !important;
    border: 0 !important;
    border-radius: clamp(14px, 3vw, 26px) !important;
    background: rgba(255, 255, 255, .98) !important;
    box-shadow: 0 14px 28px rgba(15, 23, 42, .1) !important;
    overflow: hidden !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile-icon {
    grid-row: 1 / 4 !important;
    align-self: center !important;
    width: clamp(54px, 12vw, 90px) !important;
    height: clamp(54px, 12vw, 90px) !important;
    min-width: clamp(54px, 12vw, 90px) !important;
    border-radius: 50% !important;
    background: radial-gradient(circle at 35% 28%, #dcfce7, #86efac) !important;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .8), 0 10px 22px rgba(16, 185, 129, .22) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon),
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile > span:not(.summary-tile-icon) {
    color: #334155 !important;
    font-size: clamp(16px, 4.1vw, 28px) !important;
    font-weight: 900 !important;
    line-height: 1.02 !important;
    white-space: nowrap !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong {
    color: #0f172a !important;
    font-size: clamp(31px, 7.8vw, 58px) !important;
    font-weight: 900 !important;
    line-height: .98 !important;
    white-space: nowrap !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small {
    color: #64748b !important;
    font-size: clamp(16px, 4vw, 27px) !important;
    font-weight: 800 !important;
    line-height: 1.1 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small::after {
    content: none !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup {
    order: 3 !important;
    display: block !important;
    margin: clamp(10px, 2vw, 18px) 0 0 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    margin: 0 4px clamp(10px, 2vw, 16px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head h3,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head h3 {
    margin: 0 !important;
    color: #0f172a !important;
    font-size: clamp(28px, 7.7vw, 51px) !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    letter-spacing: 0 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3::after {
    content: none !important;
    display: none !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head button,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head a,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head button,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head a {
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    color: #059669 !important;
    font-size: clamp(18px, 4.6vw, 30px) !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    text-decoration: none !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-card,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-card {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: clamp(10px, 2vw, 18px) !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    overflow: visible !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row {
    position: relative !important;
    display: grid !important;
    grid-template-columns: clamp(52px, 12vw, 88px) minmax(0, 1fr) clamp(16px, 3vw, 24px) !important;
    align-items: center !important;
    gap: clamp(11px, 2.4vw, 18px) !important;
    min-height: clamp(96px, 18vw, 134px) !important;
    padding: clamp(14px, 3vw, 22px) clamp(12px, 2.8vw, 22px) !important;
    border: 0 !important;
    border-radius: clamp(14px, 3vw, 24px) !important;
    background: rgba(255, 255, 255, .98) !important;
    box-shadow: 0 14px 28px rgba(15, 23, 42, .09) !important;
    overflow: hidden !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row:last-child,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row:last-child {
    grid-column: 1 / -1 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-icon {
    width: clamp(52px, 12vw, 88px) !important;
    height: clamp(52px, 12vw, 88px) !important;
    min-width: clamp(52px, 12vw, 88px) !important;
    border-radius: 50% !important;
    box-shadow: 0 10px 22px rgba(15, 23, 42, .12) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy {
    display: grid !important;
    gap: clamp(3px, .8vw, 7px) !important;
    min-width: 0 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy strong {
    color: #0f172a !important;
    font-size: clamp(15px, 3.85vw, 26px) !important;
    font-weight: 900 !important;
    line-height: 1.08 !important;
    white-space: normal !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy small,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy small {
    display: flex !important;
    align-items: baseline !important;
    gap: clamp(6px, 1.4vw, 10px) !important;
    color: #475569 !important;
    font-size: clamp(15px, 3.6vw, 25px) !important;
    font-weight: 800 !important;
    line-height: 1 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-count,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-count {
    font-size: clamp(30px, 8vw, 58px) !important;
    font-weight: 900 !important;
    line-height: .95 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-chevron,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-chevron {
    color: #475569 !important;
    font-size: clamp(30px, 6vw, 46px) !important;
    font-weight: 700 !important;
    line-height: 1 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-overdue .followup-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-overdue .followup-icon {
    background: radial-gradient(circle at 35% 25%, #fff, #fecdd3) !important;
    color: #f43f5e !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-call .followup-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-call .followup-icon {
    background: radial-gradient(circle at 35% 25%, #fff7ed, #fde68a) !important;
    color: #f59e0b !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-slip .followup-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-slip .followup-icon {
    background: radial-gradient(circle at 35% 25%, #eff6ff, #bfdbfe) !important;
    color: #2563eb !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-missed .followup-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-missed .followup-icon {
    background: radial-gradient(circle at 35% 25%, #f8fafc, #cbd5e1) !important;
    color: #475569 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-soon .followup-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-soon .followup-icon {
    background: radial-gradient(circle at 35% 25%, #f0fdf4, #86efac) !important;
    color: #059669 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-overdue .followup-count,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-overdue .followup-count {
    color: #ef4444 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-call .followup-count,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-call .followup-count {
    color: #f59e0b !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-slip .followup-count,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-slip .followup-count {
    color: #2563eb !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-missed .followup-count,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-missed .followup-count {
    color: #475569 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-soon .followup-count,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-soon .followup-count {
    color: #059669 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers {
    order: 4 !important;
    display: block !important;
    margin: clamp(10px, 2vw, 18px) 0 18px !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-list,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-list {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: clamp(10px, 2vw, 18px) !important;
    width: 100% !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-card,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-card {
    position: relative !important;
    min-height: clamp(176px, 29vw, 246px) !important;
    border: 0 !important;
    border-radius: clamp(16px, 3vw, 25px) !important;
    background: rgba(255, 255, 255, .98) !important;
    box-shadow: 0 14px 28px rgba(15, 23, 42, .09) !important;
    overflow: hidden !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-main,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-main {
    display: grid !important;
    grid-template-columns: clamp(54px, 12vw, 84px) minmax(0, 1fr) !important;
    grid-template-rows: minmax(0, 1fr) auto !important;
    align-items: start !important;
    gap: clamp(10px, 2vw, 16px) !important;
    width: 100% !important;
    min-height: clamp(176px, 29vw, 246px) !important;
    padding: clamp(17px, 3.3vw, 26px) clamp(16px, 3.2vw, 24px) clamp(16px, 3.2vw, 24px) !important;
    border: 0 !important;
    background: transparent !important;
    text-align: left !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-menu,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-menu {
    position: absolute !important;
    top: clamp(14px, 2.7vw, 22px) !important;
    right: clamp(14px, 2.7vw, 22px) !important;
    z-index: 4 !important;
    color: #64748b !important;
    font-size: clamp(20px, 4vw, 30px) !important;
    font-weight: 900 !important;
    line-height: 1 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-avatar,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-avatar {
    grid-column: 1 !important;
    grid-row: 1 !important;
    display: grid !important;
    place-items: center !important;
    width: clamp(54px, 12vw, 84px) !important;
    height: clamp(54px, 12vw, 84px) !important;
    min-width: clamp(54px, 12vw, 84px) !important;
    margin: 0 !important;
    border-radius: 50% !important;
    background: #d1fae5 !important;
    color: #059669 !important;
    object-fit: cover !important;
    font-size: clamp(20px, 4.5vw, 32px) !important;
    font-weight: 900 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy {
    grid-column: 2 !important;
    grid-row: 1 !important;
    display: grid !important;
    align-content: start !important;
    gap: clamp(3px, .8vw, 8px) !important;
    min-width: 0 !important;
    padding-right: clamp(18px, 3vw, 26px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy strong {
    display: block !important;
    color: #0f172a !important;
    font-size: clamp(16px, 4vw, 27px) !important;
    font-weight: 900 !important;
    line-height: 1.12 !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-limit,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-limit {
    display: flex !important;
    align-items: baseline !important;
    gap: 6px !important;
    color: #64748b !important;
    font-size: clamp(13px, 3.1vw, 22px) !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-limit b,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-limit b {
    color: #059669 !important;
    font-size: clamp(16px, 3.7vw, 27px) !important;
    font-weight: 900 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy small,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy small {
    justify-self: start !important;
    display: inline-flex !important;
    align-items: center !important;
    width: max-content !important;
    max-width: 100% !important;
    margin: 4px 0 0 !important;
    padding: clamp(5px, 1vw, 8px) clamp(10px, 1.8vw, 16px) !important;
    border-radius: 999px !important;
    background: #d1fae5 !important;
    color: #059669 !important;
    font-size: clamp(12px, 2.9vw, 19px) !important;
    font-weight: 900 !important;
    line-height: 1 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-date,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-date {
    grid-column: 1 / 3 !important;
    grid-row: 2 !important;
    align-self: end !important;
    justify-self: start !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: clamp(6px, 1.2vw, 10px) !important;
    max-width: calc(100% - clamp(48px, 10vw, 76px)) !important;
    padding: clamp(8px, 1.4vw, 12px) clamp(10px, 2vw, 16px) !important;
    border-radius: 999px !important;
    background: #eef2f7 !important;
    color: #64748b !important;
    font-size: clamp(12px, 2.8vw, 18px) !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-date svg,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-date svg {
    width: clamp(16px, 3.3vw, 22px) !important;
    height: clamp(16px, 3.3vw, 22px) !important;
    flex: 0 0 auto !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    fill: none !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-call,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-call {
    position: absolute !important;
    right: clamp(16px, 3.2vw, 24px) !important;
    bottom: clamp(15px, 3vw, 23px) !important;
    left: auto !important;
    display: grid !important;
    place-items: center !important;
    width: clamp(48px, 10vw, 70px) !important;
    height: clamp(48px, 10vw, 70px) !important;
    min-width: clamp(48px, 10vw, 70px) !important;
    transform: none !important;
    border-radius: 50% !important;
    background: #bbf7d0 !important;
    color: #059669 !important;
    box-shadow: 0 10px 22px rgba(16, 185, 129, .18) !important;
  }
}

/* Mobile dashboard exact reference pass: specificity cleanup for old mobile dashboard rules. */
@media (hover: none), (pointer: coarse), (max-width: 1200px) {
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-principal > span:not(.summary-tile-icon),
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-received > span:not(.summary-tile-icon),
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-principal > span:not(.summary-tile-icon),
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-received > span:not(.summary-tile-icon) {
    position: relative !important;
    display: block !important;
    min-width: 0 !important;
    overflow: hidden !important;
    color: transparent !important;
    font-size: 0 !important;
    line-height: 0 !important;
    white-space: nowrap !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-principal > span:not(.summary-tile-icon)::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-principal > span:not(.summary-tile-icon)::after {
    content: "เงินกู้ทั้งหมด" !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-received > span:not(.summary-tile-icon)::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-received > span:not(.summary-tile-icon)::after {
    content: "รับแล้ววันนี้" !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-principal > span:not(.summary-tile-icon)::after,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-received > span:not(.summary-tile-icon)::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-principal > span:not(.summary-tile-icon)::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-received > span:not(.summary-tile-icon)::after {
    display: block !important;
    overflow: hidden !important;
    color: #334155 !important;
    font-size: clamp(15px, 3.55vw, 26px) !important;
    font-weight: 900 !important;
    line-height: 1.04 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small {
    position: relative !important;
    overflow: hidden !important;
    color: transparent !important;
    font-size: 0 !important;
    line-height: 0 !important;
    white-space: nowrap !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small::after {
    content: "บาท" !important;
    display: block !important;
    color: #64748b !important;
    font-size: clamp(15px, 3.6vw, 25px) !important;
    font-weight: 800 !important;
    line-height: 1.08 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-mobile-customer-list,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-mobile-customer-list {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: clamp(10px, 2vw, 18px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-mobile-customer-card,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-mobile-customer-card {
    width: auto !important;
    inline-size: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    min-height: clamp(176px, 29vw, 246px) !important;
    justify-self: stretch !important;
    align-self: stretch !important;
  }
}

/* Mobile dashboard exact reference pass: font and icon polish, still phone runtime only. */
@media (hover: none), (pointer: coarse), (max-width: 1200px) {
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel *,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel * {
    font-family: "Noto Sans Thai", "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    letter-spacing: 0 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel {
    height: clamp(184px, 38.5vw, 284px) !important;
    min-height: clamp(184px, 38.5vw, 284px) !important;
    max-height: clamp(184px, 38.5vw, 284px) !important;
    padding: clamp(22px, 4.35vw, 34px) clamp(24px, 4.9vw, 38px) clamp(20px, 4vw, 31px) !important;
    border-radius: clamp(21px, 4.4vw, 34px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel::before,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel::before {
    top: 4% !important;
    right: 2% !important;
    width: clamp(142px, 39vw, 300px) !important;
    height: clamp(112px, 29vw, 224px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-mobile-copy,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-mobile-copy {
    width: min(68%, 500px) !important;
    gap: clamp(8px, 1.7vw, 13px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker {
    font-size: clamp(18px, 4.5vw, 34px) !important;
    font-weight: 700 !important;
    line-height: 1.05 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-title,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-title {
    font-size: clamp(39px, 9.9vw, 74px) !important;
    font-weight: 900 !important;
    line-height: .94 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-detail,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-detail {
    font-size: clamp(17px, 4.25vw, 31px) !important;
    font-weight: 800 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel > .primary-button,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel > .primary-button {
    height: clamp(54px, 9.4vw, 76px) !important;
    min-height: clamp(54px, 9.4vw, 76px) !important;
    max-height: clamp(54px, 9.4vw, 76px) !important;
    border-radius: clamp(19px, 4vw, 30px) !important;
    font-size: clamp(24px, 6.2vw, 43px) !important;
    font-weight: 900 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile {
    grid-template-columns: clamp(66px, 14.2vw, 106px) minmax(0, 1fr) !important;
    height: clamp(112px, 23.9vw, 172px) !important;
    min-height: clamp(112px, 23.9vw, 172px) !important;
    max-height: clamp(112px, 23.9vw, 172px) !important;
    padding: clamp(17px, 3.6vw, 27px) !important;
    border-radius: clamp(18px, 3.7vw, 28px) !important;
    column-gap: clamp(15px, 3vw, 23px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile-icon {
    width: clamp(66px, 14.2vw, 106px) !important;
    height: clamp(66px, 14.2vw, 106px) !important;
    min-width: clamp(66px, 14.2vw, 106px) !important;
    box-shadow:
      inset 0 0 0 1px rgba(255, 255, 255, .88),
      0 12px 24px rgba(16, 185, 129, .22) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile-icon::before,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile-icon::before {
    width: 54% !important;
    height: 54% !important;
    color: #059669 !important;
    filter: drop-shadow(0 2px 2px rgba(4, 120, 87, .24)) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-principal > span:not(.summary-tile-icon)::after,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-received > span:not(.summary-tile-icon)::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-principal > span:not(.summary-tile-icon)::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-received > span:not(.summary-tile-icon)::after {
    font-size: clamp(17px, 4vw, 30px) !important;
    font-weight: 800 !important;
    line-height: 1.05 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(38px, 9.3vw, 66px) !important;
    font-weight: 900 !important;
    line-height: .95 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small::after {
    font-size: clamp(17px, 4vw, 29px) !important;
    font-weight: 700 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head h3,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head h3 {
    font-size: clamp(32px, 8.5vw, 57px) !important;
    font-weight: 900 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head button,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head a,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head button,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head a {
    font-size: clamp(20px, 5vw, 33px) !important;
    font-weight: 900 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row {
    grid-template-columns: clamp(64px, 13.6vw, 100px) minmax(0, 1fr) clamp(18px, 3.2vw, 26px) !important;
    min-height: clamp(108px, 20.2vw, 148px) !important;
    padding: clamp(16px, 3.3vw, 24px) clamp(14px, 3vw, 23px) !important;
    border-radius: clamp(17px, 3.5vw, 27px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-icon {
    width: clamp(64px, 13.6vw, 100px) !important;
    height: clamp(64px, 13.6vw, 100px) !important;
    min-width: clamp(64px, 13.6vw, 100px) !important;
    box-shadow:
      inset 0 0 0 1px rgba(255, 255, 255, .78),
      0 12px 25px rgba(15, 23, 42, .13) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-icon::before,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-icon::before {
    width: 52% !important;
    height: 52% !important;
    filter: drop-shadow(0 2px 2px rgba(15, 23, 42, .18)) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy strong {
    font-size: clamp(17px, 4.2vw, 29px) !important;
    font-weight: 900 !important;
    line-height: 1.08 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy small,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy small {
    font-size: clamp(17px, 4vw, 28px) !important;
    font-weight: 700 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-count,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-count {
    font-size: clamp(38px, 9.5vw, 68px) !important;
    font-weight: 900 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-chevron,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-chevron {
    font-size: clamp(34px, 6.7vw, 50px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-mobile-customer-card,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-mobile-customer-card {
    min-height: clamp(206px, 33.5vw, 266px) !important;
    border-radius: clamp(18px, 3.6vw, 28px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-main,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-main {
    grid-template-columns: clamp(64px, 13.8vw, 100px) minmax(0, 1fr) !important;
    min-height: clamp(206px, 33.5vw, 266px) !important;
    padding: clamp(19px, 3.7vw, 28px) clamp(18px, 3.6vw, 27px) clamp(18px, 3.6vw, 27px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-avatar,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-avatar {
    width: clamp(64px, 13.8vw, 100px) !important;
    height: clamp(64px, 13.8vw, 100px) !important;
    min-width: clamp(64px, 13.8vw, 100px) !important;
    font-size: clamp(22px, 5vw, 36px) !important;
    box-shadow: 0 10px 22px rgba(16, 185, 129, .14) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy strong {
    font-size: clamp(18px, 4.3vw, 30px) !important;
    font-weight: 900 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-limit,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-limit {
    font-size: clamp(14px, 3.35vw, 23px) !important;
    font-weight: 700 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-limit b,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-limit b {
    font-size: clamp(18px, 4.15vw, 29px) !important;
    font-weight: 900 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy small,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy small {
    padding: clamp(6px, 1.15vw, 9px) clamp(12px, 2vw, 17px) !important;
    font-size: clamp(13px, 3.05vw, 20px) !important;
    font-weight: 800 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-date,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-date {
    padding: clamp(9px, 1.55vw, 13px) clamp(12px, 2.2vw, 18px) !important;
    font-size: clamp(13px, 3.05vw, 20px) !important;
    font-weight: 700 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-call,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-call {
    width: clamp(54px, 11.2vw, 78px) !important;
    height: clamp(54px, 11.2vw, 78px) !important;
    min-width: clamp(54px, 11.2vw, 78px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-call::before,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-call::before {
    width: 52% !important;
    height: 52% !important;
  }
}

/* Mobile dashboard exact reference pass: final fit for narrow phone width. */
@media (hover: none), (pointer: coarse), (max-width: 1200px) {
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-title,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-detail,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-title,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-detail {
    font-family: "Noto Sans Thai", "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile {
    grid-template-columns: clamp(56px, 12.2vw, 92px) minmax(0, 1fr) !important;
    height: clamp(104px, 21.8vw, 160px) !important;
    min-height: clamp(104px, 21.8vw, 160px) !important;
    max-height: clamp(104px, 21.8vw, 160px) !important;
    padding: clamp(14px, 3.1vw, 24px) !important;
    column-gap: clamp(12px, 2.5vw, 20px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile-icon {
    width: clamp(56px, 12.2vw, 92px) !important;
    height: clamp(56px, 12.2vw, 92px) !important;
    min-width: clamp(56px, 12.2vw, 92px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-principal > span:not(.summary-tile-icon)::after,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-received > span:not(.summary-tile-icon)::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-principal > span:not(.summary-tile-icon)::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-received > span:not(.summary-tile-icon)::after {
    font-size: clamp(16px, 3.65vw, 27px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(34px, 8.2vw, 60px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row {
    grid-template-columns: clamp(52px, 11.7vw, 86px) minmax(0, 1fr) clamp(18px, 3vw, 24px) !important;
    min-height: clamp(96px, 18.4vw, 136px) !important;
    padding: clamp(14px, 3vw, 22px) clamp(12px, 2.7vw, 21px) !important;
    gap: clamp(10px, 2.2vw, 17px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-icon {
    width: clamp(52px, 11.7vw, 86px) !important;
    height: clamp(52px, 11.7vw, 86px) !important;
    min-width: clamp(52px, 11.7vw, 86px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy strong {
    font-size: clamp(15px, 3.55vw, 25px) !important;
    line-height: 1.08 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy small,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy small {
    font-size: clamp(15px, 3.45vw, 24px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-count,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-count {
    font-size: clamp(34px, 8.4vw, 60px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-mobile-customer-card,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-mobile-customer-card {
    min-height: clamp(190px, 31vw, 252px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-main,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-main {
    grid-template-columns: clamp(56px, 12vw, 90px) minmax(0, 1fr) !important;
    min-height: clamp(190px, 31vw, 252px) !important;
    padding: clamp(18px, 3.5vw, 27px) clamp(16px, 3.2vw, 25px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-avatar,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-avatar {
    width: clamp(56px, 12vw, 90px) !important;
    height: clamp(56px, 12vw, 90px) !important;
    min-width: clamp(56px, 12vw, 90px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy strong {
    font-size: clamp(16px, 3.75vw, 27px) !important;
  }
}

/* Mobile dashboard exact reference pass: restore softer Thai font and reduce cramped cards. */
@media (hover: none), (pointer: coarse), (max-width: 1200px) {
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel *,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel * {
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    letter-spacing: 0 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-title,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-count,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-title,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-count {
    font-family: Inter, "IBM Plex Sans Thai", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel.dashboard-work-panel {
    height: clamp(168px, 36vw, 250px) !important;
    min-height: clamp(168px, 36vw, 250px) !important;
    max-height: clamp(168px, 36vw, 250px) !important;
    padding: clamp(19px, 4vw, 30px) clamp(22px, 4.6vw, 36px) clamp(18px, 3.8vw, 29px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker {
    font-size: clamp(15px, 3.65vw, 27px) !important;
    font-weight: 800 !important;
    line-height: 1.08 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-title,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-title {
    font-size: clamp(32px, 8.1vw, 58px) !important;
    font-weight: 900 !important;
    line-height: .98 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-detail,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-detail {
    font-size: clamp(15px, 3.55vw, 25px) !important;
    font-weight: 800 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel > .primary-button,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel > .primary-button {
    height: clamp(48px, 8.4vw, 66px) !important;
    min-height: clamp(48px, 8.4vw, 66px) !important;
    max-height: clamp(48px, 8.4vw, 66px) !important;
    font-size: clamp(20px, 5.1vw, 34px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile {
    grid-template-columns: clamp(50px, 11.4vw, 82px) minmax(0, 1fr) !important;
    height: clamp(90px, 20vw, 138px) !important;
    min-height: clamp(90px, 20vw, 138px) !important;
    max-height: clamp(90px, 20vw, 138px) !important;
    padding: clamp(13px, 2.9vw, 22px) !important;
    column-gap: clamp(11px, 2.4vw, 18px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile-icon {
    width: clamp(50px, 11.4vw, 82px) !important;
    height: clamp(50px, 11.4vw, 82px) !important;
    min-width: clamp(50px, 11.4vw, 82px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-principal > span:not(.summary-tile-icon)::after,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-received > span:not(.summary-tile-icon)::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-principal > span:not(.summary-tile-icon)::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .dashboard-tile-received > span:not(.summary-tile-icon)::after {
    font-size: clamp(14px, 3.25vw, 24px) !important;
    font-weight: 800 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong {
    font-size: clamp(30px, 7.1vw, 52px) !important;
    font-weight: 900 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small::after,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile small::after {
    font-size: clamp(14px, 3.25vw, 23px) !important;
    font-weight: 700 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head h3,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head h3 {
    font-size: clamp(26px, 7vw, 46px) !important;
    font-weight: 900 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-row {
    grid-template-columns: clamp(46px, 10.5vw, 76px) minmax(0, 1fr) clamp(16px, 2.8vw, 23px) !important;
    min-height: clamp(88px, 17.2vw, 124px) !important;
    padding: clamp(12px, 2.7vw, 20px) clamp(11px, 2.5vw, 19px) !important;
    gap: clamp(9px, 2vw, 16px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-icon,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-icon {
    width: clamp(46px, 10.5vw, 76px) !important;
    height: clamp(46px, 10.5vw, 76px) !important;
    min-width: clamp(46px, 10.5vw, 76px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy strong {
    font-size: clamp(13px, 3.15vw, 22px) !important;
    font-weight: 900 !important;
    line-height: 1.08 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy small,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy small {
    font-size: clamp(13px, 3.05vw, 21px) !important;
    font-weight: 700 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-count,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-count {
    font-size: clamp(30px, 7.4vw, 52px) !important;
    font-weight: 900 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-mobile-customer-card,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel .dashboard-mobile-customer-card {
    min-height: clamp(176px, 29vw, 238px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-main,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-main {
    grid-template-columns: clamp(50px, 11vw, 82px) minmax(0, 1fr) !important;
    min-height: clamp(176px, 29vw, 238px) !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-avatar,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-avatar {
    width: clamp(50px, 11vw, 82px) !important;
    height: clamp(50px, 11vw, 82px) !important;
    min-width: clamp(50px, 11vw, 82px) !important;
  }
}

/* Mobile dashboard exact reference pass: Thai headings stay Thai, numbers stay numeric. */
@media (hover: none), (pointer: coarse), (max-width: 1200px) {
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-title,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-detail,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel > .primary-button,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head h3,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy strong,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy small,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy strong,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-limit,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy small,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-date,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-title,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-kicker,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel .dashboard-work-idle-detail,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel #dashboardWorkPanel > .primary-button,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head h3,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head h3,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-copy small,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-limit,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-copy small,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-date {
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-count,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-limit b,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) #dashboardPanel#dashboardPanel > .summary-grid .summary-tile strong,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .followup-count,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customer-limit b {
    font-family: Inter, "IBM Plex Sans Thai", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }
}

/* Mobile dashboard exact reference pass: smaller see-all links. */
@media (hover: none), (pointer: coarse), (max-width: 1200px) {
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head button,
  html.mobile-runtime body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head a,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-followup-head button,
  html body.mobile-runtime[data-page="dashboard"]:not(.auth-locked) .dashboard-mobile-customers-head a {
    font-size: clamp(15px, 3.6vw, 24px) !important;
    font-weight: 800 !important;
    line-height: 1 !important;
  }
}

/* Mobile records card: keep status/value readable and show the tap cue. */
@media (hover: none), (pointer: coarse), (max-width: 1200px) {
  html.mobile-runtime body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-collapse > summary,
  html body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-collapse > summary {
    position: relative !important;
    grid-template-columns: minmax(0, 1fr) clamp(118px, 28vw, 132px) !important;
    grid-template-areas: "person money" "due due" !important;
    column-gap: 12px !important;
    row-gap: 13px !important;
    overflow: visible !important;
    padding-right: 18px !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-money,
  html body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-money {
    position: relative !important;
    width: clamp(118px, 28vw, 132px) !important;
    min-width: clamp(118px, 28vw, 132px) !important;
    max-width: clamp(118px, 28vw, 132px) !important;
    justify-items: end !important;
    align-self: start !important;
    gap: 5px !important;
    padding: 18px 0 0 !important;
    overflow: visible !important;
    text-align: right !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-money small,
  html body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-money small {
    max-width: 100% !important;
    overflow: visible !important;
    color: currentColor !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: clamp(12px, 3.05vw, 14px) !important;
    font-weight: 800 !important;
    line-height: 1.05 !important;
    text-overflow: clip !important;
    white-space: nowrap !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-money strong,
  html body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-money strong {
    max-width: 100% !important;
    overflow: visible !important;
    color: currentColor !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: clamp(15px, 3.65vw, 17px) !important;
    font-weight: 900 !important;
    line-height: 1.05 !important;
    text-overflow: clip !important;
    white-space: nowrap !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-money i,
  html body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-money i {
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    display: inline-grid !important;
    width: 30px !important;
    height: 16px !important;
    place-items: center !important;
    color: transparent !important;
    font-size: 0 !important;
    line-height: 1 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-money i::before,
  html body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-money i::before {
    content: "•••" !important;
    color: #64748b !important;
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: 18px !important;
    font-weight: 900 !important;
    letter-spacing: 2px !important;
    line-height: 1 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-facts,
  html body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-facts {
    grid-auto-flow: row !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-facts > div,
  html body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-facts > div {
    grid-column: auto !important;
    grid-row: auto !important;
    min-width: 0 !important;
  }

  html.mobile-runtime body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-facts strong,
  html body.mobile-runtime[data-page="records"][data-records-subview="list"]:not(.auth-locked) #recordsPanel #recordsList .mobile-debtor-facts strong {
    overflow: visible !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    font-size: clamp(13px, 3.35vw, 15px) !important;
    font-weight: 800 !important;
    line-height: 1.15 !important;
    text-overflow: clip !important;
    white-space: nowrap !important;
  }
}

/* Desktop debtors card final compact pass: override later inline desktop layout when the window is narrowed. */
@media (min-width: 769px) and (max-width: 1600px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card {
    grid-template-columns: minmax(270px, 1.28fr) minmax(130px, .62fr) minmax(140px, .68fr) minmax(176px, .82fr) 152px 50px !important;
    grid-template-areas:
      "person amount status due actions more"
      "person progress progress progress actions more" !important;
    align-items: stretch !important;
    gap: 14px !important;
    min-height: 168px !important;
    padding: 20px 18px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-person {
    grid-area: person !important;
    align-self: center !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-metric:nth-of-type(1) {
    grid-area: amount !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-metric:nth-of-type(2) {
    grid-area: status !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-metric:nth-of-type(3) {
    grid-area: due !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-progress {
    grid-area: progress !important;
    align-self: end !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-actions {
    grid-area: actions !important;
    align-self: center !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-more {
    grid-area: more !important;
    align-self: center !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-person-copy > div {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    align-items: start !important;
    gap: 8px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-name {
    max-width: 100% !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-tag {
    max-width: 100% !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-metric,
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-progress {
    min-width: 0 !important;
    padding-left: 14px !important;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-card {
    grid-template-columns: minmax(245px, 1.05fr) minmax(132px, .6fr) minmax(132px, .6fr) 144px 48px !important;
    grid-template-areas:
      "person amount due actions more"
      "person status status actions more"
      "progress progress progress actions more" !important;
    gap: 12px !important;
    min-height: 204px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-person {
    grid-template-columns: 64px minmax(0, 1fr) !important;
    gap: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-avatar {
    width: 64px !important;
    height: 64px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel #recordsList.records-list .desktop-debtor-board .desktop-debtor-actions button {
    height: 46px !important;
    font-size: 14px !important;
  }
}
/* Desktop tracking page: final desktop-only pattern lock. */
@media (min-width: 769px) {
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    margin: clamp(22px, 2.2vw, 34px) 0 0 !important;
    padding: 0 !important;
    background: #fff !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 28px !important;
    box-shadow: 0 24px 60px rgba(15, 23, 42, .08) !important;
    overflow: visible !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .panel-title,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .mini-summary-grid,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .simple-table-wrap,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > .tracking-footer,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel > #trackingMobileList {
    display: none !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) #desktopTrackingBoard {
    display: block !important;
    width: 100% !important;
    padding: 36px 34px 32px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-board {
    display: grid !important;
    gap: 28px !important;
    color: #101828 !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-grid {
    display: grid !important;
    grid-template-columns: repeat(6, minmax(0, 1fr)) !important;
    gap: 16px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-toolbar {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(260px, 360px) !important;
    gap: 18px !important;
    align-items: center !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-list {
    display: grid !important;
    gap: 18px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-card {
    display: grid !important;
    grid-template-columns: minmax(250px, 1.2fr) minmax(130px, .6fr) minmax(150px, .7fr) minmax(150px, .72fr) minmax(142px, .68fr) 180px 56px !important;
    align-items: center !important;
    gap: 18px !important;
    min-height: 150px !important;
    padding: 22px 24px !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 22px !important;
    background: #fff !important;
    box-shadow: 0 18px 42px rgba(15, 23, 42, .055) !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-actions button {
    width: 100% !important;
    min-height: 46px !important;
    border-radius: 14px !important;
    font-size: 14px !important;
    font-weight: 850 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-more-button {
    width: 54px !important;
    height: 58px !important;
  }
}

@media (min-width: 769px) and (max-width: 1800px) {
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-card {
    grid-template-columns: minmax(270px, 1.28fr) minmax(130px, .62fr) minmax(140px, .68fr) minmax(142px, .68fr) 152px 50px !important;
    grid-template-areas:
      "person period due status actions more"
      "person amount amount status actions more" !important;
    align-items: stretch !important;
    gap: 14px !important;
    min-height: 168px !important;
    padding: 20px 18px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-person {
    grid-area: person !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric:nth-of-type(1) {
    grid-area: period !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric:nth-of-type(2) {
    grid-area: due !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-metric:nth-of-type(3) {
    grid-area: amount !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-status {
    grid-area: status !important;
    align-self: center !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-actions {
    grid-area: actions !important;
    align-self: center !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-more {
    grid-area: more !important;
    align-self: center !important;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-toolbar {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-card {
    grid-template-columns: minmax(240px, 1fr) minmax(130px, .7fr) minmax(130px, .7fr) 150px 50px !important;
    grid-template-areas:
      "person period due actions more"
      "person amount status actions more" !important;
  }
}

/* Desktop tracking compact pass: one summary row, no duplicate filter row. */
@media (min-width: 769px) {
  html body[data-page="tracking"]:not(.auth-locked) #desktopTrackingBoard {
    padding: 30px 34px 30px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-board {
    gap: 20px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-grid {
    display: grid !important;
    grid-template-columns: repeat(6, minmax(0, 1fr)) !important;
    gap: 12px !important;
    align-items: stretch !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-card {
    grid-template-columns: minmax(0, 1fr) 36px !important;
    min-height: 76px !important;
    padding: 12px 13px !important;
    border-radius: 14px !important;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .035) !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-copy {
    gap: 6px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-copy > span {
    font-size: 11px !important;
    line-height: 1.1 !important;
    white-space: nowrap !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-copy strong {
    gap: 5px !important;
    font-size: 22px !important;
    line-height: 1 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-copy small {
    font-size: 10px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-icon {
    width: 36px !important;
    height: 36px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-summary-icon svg {
    width: 18px !important;
    height: 18px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-toolbar {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    gap: 12px !important;
    margin-top: -2px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-filters {
    display: none !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-sort {
    justify-self: end !important;
    width: 240px !important;
    min-height: 40px !important;
    height: 40px !important;
    padding: 0 12px !important;
    gap: 10px !important;
    border-radius: 12px !important;
    overflow: hidden !important;
    box-shadow: 0 8px 20px rgba(15, 23, 42, .035) !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-sort span,
  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-sort select {
    font-size: 12px !important;
    font-weight: 800 !important;
    line-height: 1 !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) .desktop-tracking-sort select {
    height: 38px !important;
    min-height: 0 !important;
    padding: 0 18px 0 0 !important;
  }
}

/* Desktop payment history: match tracking pattern without touching mobile. */
#desktopHistoryBoard {
  display: none;
}

@media (max-width: 768px), (hover: none), (pointer: coarse) {
  html body:not(.auth-locked) #desktopHistoryBoard {
    display: none !important;
  }
}

@media (min-width: 769px) {
  html body[data-page="history"]:not(.auth-locked) #historyPanel.history-panel,
  html body[data-records-subview="history"]:not(.auth-locked) #historyPanel.history-panel {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    margin: 28px 0 0 !important;
    padding: 0 !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 28px !important;
    background: #fff !important;
    box-shadow: 0 24px 60px rgba(15, 23, 42, .08) !important;
    overflow: visible !important;
  }

  html body[data-page="history"]:not(.auth-locked) #historyPanel.history-panel > .panel-title,
  html body[data-page="history"]:not(.auth-locked) #historyPanel.history-panel > .mini-summary-grid,
  html body[data-page="history"]:not(.auth-locked) #historyPanel.history-panel > .simple-table-wrap,
  html body[data-records-subview="history"]:not(.auth-locked) #historyPanel.history-panel > .panel-title,
  html body[data-records-subview="history"]:not(.auth-locked) #historyPanel.history-panel > .mini-summary-grid,
  html body[data-records-subview="history"]:not(.auth-locked) #historyPanel.history-panel > .simple-table-wrap {
    display: none !important;
  }

  html body[data-page="history"]:not(.auth-locked) #desktopHistoryBoard,
  html body[data-records-subview="history"]:not(.auth-locked) #desktopHistoryBoard {
    display: block !important;
    padding: 30px 34px !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-board,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-board *,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-board,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-board * {
    box-sizing: border-box !important;
    font-family: "IBM Plex Sans Thai", "Sarabun", Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
    letter-spacing: 0 !important;
    font-synthesis-weight: none !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-board,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-board {
    display: grid !important;
    gap: 20px !important;
    color: #101828 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-grid,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-grid {
    display: grid !important;
    grid-template-columns: repeat(6, minmax(150px, 1fr)) !important;
    gap: 12px !important;
    align-items: stretch !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-card,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-card {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 36px !important;
    align-items: center !important;
    min-height: 76px !important;
    padding: 12px 13px !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 14px !important;
    background: #fff !important;
    color: #101828 !important;
    text-align: left !important;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .035) !important;
    cursor: pointer !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-card.is-active,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-card:not([aria-disabled="true"]):hover,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-card.is-active,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-card:not([aria-disabled="true"]):hover {
    border-color: #49a469 !important;
    box-shadow: 0 14px 30px rgba(18, 114, 76, .08) !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-card[aria-disabled="true"],
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-card[aria-disabled="true"] {
    cursor: default !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-copy,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-copy {
    display: grid !important;
    gap: 5px !important;
    min-width: 0 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-copy > span,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-copy > span {
    overflow: hidden !important;
    color: #667085 !important;
    font-size: 11px !important;
    font-weight: 800 !important;
    line-height: 1.1 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-card.is-good .desktop-history-summary-copy > span,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-card.is-money .desktop-history-summary-copy > span,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-card.is-good .desktop-history-summary-copy > span,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-card.is-money .desktop-history-summary-copy > span {
    color: #32835b !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-card.is-danger .desktop-history-summary-copy > span,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-card.is-danger .desktop-history-summary-copy > span {
    color: #df3a43 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-copy strong,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-copy strong {
    display: flex !important;
    align-items: baseline !important;
    gap: 5px !important;
    overflow: hidden !important;
    color: #071126 !important;
    font-family: Inter, "IBM Plex Sans Thai", sans-serif !important;
    font-size: 22px !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-copy small,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-copy small {
    color: #667085 !important;
    font-size: 10px !important;
    font-weight: 800 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-icon,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-icon {
    display: grid !important;
    width: 36px !important;
    height: 36px !important;
    place-items: center !important;
    border-radius: 999px !important;
    color: #15955f !important;
    background: #dcfce7 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-card.is-danger .desktop-history-summary-icon,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-card.is-danger .desktop-history-summary-icon {
    color: #df3a43 !important;
    background: #ffe4e8 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-card.is-slip .desktop-history-summary-icon,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-card.is-slip .desktop-history-summary-icon {
    color: #2563eb !important;
    background: #dbeafe !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-icon svg,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-icon svg {
    width: 18px !important;
    height: 18px !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-toolbar,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-toolbar {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    gap: 12px !important;
    align-items: center !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-filters,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-filters {
    display: none !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-controls,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-controls {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: flex-end !important;
    gap: 10px !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-date-control,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-tool-button,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-search,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-sort,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-date-control,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-tool-button,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-search,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-sort {
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    height: 40px !important;
    min-height: 40px !important;
    padding: 0 12px !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 12px !important;
    background: #fff !important;
    color: #101828 !important;
    box-shadow: 0 8px 20px rgba(15, 23, 42, .035) !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-date-control span,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-sort span,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-date-control span,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-sort span {
    color: #667085 !important;
    font-size: 12px !important;
    font-weight: 800 !important;
    white-space: nowrap !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-date-control input,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-search input,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-sort select,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-date-control input,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-search input,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-sort select {
    width: auto !important;
    min-width: 0 !important;
    height: 32px !important;
    border: 0 !important;
    background: transparent !important;
    color: #101828 !important;
    font-size: 12px !important;
    font-weight: 800 !important;
    outline: none !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-search,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-search {
    width: min(260px, 24vw) !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-search input,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-search input {
    width: 100% !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-tool-button,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-tool-button {
    font-size: 12px !important;
    font-weight: 850 !important;
    cursor: pointer !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-tool-button svg,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-search svg,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-tool-button svg,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-search svg {
    width: 16px !important;
    height: 16px !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-list,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-list {
    display: grid !important;
    gap: 14px !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-card,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-card {
    display: grid !important;
    grid-template-columns: minmax(260px, 1.25fr) minmax(150px, .7fr) minmax(110px, .52fr) minmax(130px, .62fr) minmax(120px, .56fr) 168px 52px !important;
    align-items: center !important;
    gap: 14px !important;
    min-height: 132px !important;
    padding: 18px 18px !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 22px !important;
    background: #fff !important;
    box-shadow: 0 16px 38px rgba(15, 23, 42, .05) !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-date,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-date {
    display: grid !important;
    grid-template-columns: 38px minmax(0, 1fr) !important;
    grid-template-rows: auto auto !important;
    gap: 4px 10px !important;
    align-items: center !important;
    min-width: 0 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-date-icon,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-date-icon {
    grid-row: 1 / span 2 !important;
    display: grid !important;
    width: 38px !important;
    height: 38px !important;
    place-items: center !important;
    border-radius: 999px !important;
    background: #ecfdf5 !important;
    color: #059669 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-date-icon svg,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-date-icon svg {
    width: 18px !important;
    height: 18px !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-date strong,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-date strong {
    overflow: hidden !important;
    color: #101828 !important;
    font-size: 13px !important;
    font-weight: 850 !important;
    line-height: 1.15 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-date small,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-date small {
    color: #667085 !important;
    font-size: 11px !important;
    font-weight: 750 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-person,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-person {
    display: grid !important;
    grid-template-columns: 64px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 16px !important;
    min-width: 0 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-avatar,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-avatar {
    display: grid !important;
    width: 64px !important;
    height: 64px !important;
    place-items: center !important;
    overflow: hidden !important;
    border: 1px solid #c9f2df !important;
    border-radius: 50% !important;
    background: #ecfdf5 !important;
    color: #0f9f68 !important;
    font-size: 22px !important;
    font-weight: 850 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-avatar img,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-avatar img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-person-copy,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-metric,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-person-copy,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-metric {
    display: grid !important;
    gap: 7px !important;
    min-width: 0 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-name,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-name {
    display: block !important;
    max-width: 100% !important;
    overflow: hidden !important;
    border: 0 !important;
    background: transparent !important;
    color: #101828 !important;
    font-size: 18px !important;
    font-weight: 850 !important;
    line-height: 1.12 !important;
    text-align: left !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    cursor: pointer !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-person-copy span,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-person-copy small,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-metric span,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-metric small,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-person-copy span,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-person-copy small,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-metric span,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-metric small {
    overflow: hidden !important;
    color: #667085 !important;
    font-size: 12px !important;
    font-weight: 750 !important;
    line-height: 1.15 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-metric,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-metric {
    padding-left: 16px !important;
    border-left: 1px solid #e6edf5 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-metric strong,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-metric strong {
    overflow: hidden !important;
    color: #101828 !important;
    font-family: Inter, "IBM Plex Sans Thai", sans-serif !important;
    font-size: 16px !important;
    font-weight: 850 !important;
    line-height: 1.15 !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-metric strong.is-negative,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-metric strong.is-negative {
    color: #df3a43 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-status-pill,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-status-pill {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-height: 38px !important;
    max-width: 100% !important;
    padding: 0 14px !important;
    border-radius: 12px !important;
    background: #dcfce7 !important;
    color: #15803d !important;
    font-size: 12px !important;
    font-weight: 850 !important;
    white-space: nowrap !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-status-pill.is-voided,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-status-pill.is-voided {
    background: #ffe4e8 !important;
    color: #df3a43 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-actions,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-actions {
    display: grid !important;
    gap: 8px !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-actions button,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-actions button {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    width: 100% !important;
    min-height: 42px !important;
    border-radius: 13px !important;
    font-size: 13px !important;
    font-weight: 850 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-actions button svg,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-actions button svg {
    width: 16px !important;
    height: 16px !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-actions .primary-button,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-actions .primary-button {
    border: 0 !important;
    background: linear-gradient(135deg, #12b76a, #087443) !important;
    color: #fff !important;
    box-shadow: 0 14px 28px rgba(18, 119, 76, .18) !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-actions .secondary-button,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-actions .secondary-button {
    border: 1px solid #dfe7f0 !important;
    background: #fff !important;
    color: #0f172a !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-actions button:disabled,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-actions button:disabled {
    opacity: .46 !important;
    cursor: not-allowed !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-more-button,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-more-button {
    display: grid !important;
    width: 52px !important;
    height: 56px !important;
    place-items: center !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 16px !important;
    background: #fff !important;
    color: #101828 !important;
    font-size: 22px !important;
    font-weight: 850 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-empty,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-empty {
    display: grid !important;
    min-height: 150px !important;
    place-items: center !important;
    border: 1px dashed #dfe7f0 !important;
    border-radius: 18px !important;
    color: #667085 !important;
    font-size: 14px !important;
    font-weight: 800 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-footer,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-footer {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto minmax(140px, auto) !important;
    align-items: center !important;
    gap: 16px !important;
    color: #667085 !important;
    font-size: 13px !important;
    font-weight: 800 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-pagination,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-pagination {
    display: flex !important;
    gap: 8px !important;
    align-items: center !important;
    justify-content: center !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-pagination button,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-pagination button {
    display: grid !important;
    width: 40px !important;
    height: 40px !important;
    place-items: center !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 13px !important;
    background: #fff !important;
    color: #101828 !important;
    font-size: 15px !important;
    font-weight: 850 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-pagination button.is-active,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-pagination button.is-active {
    border-color: #0f9f68 !important;
    background: #0f9f68 !important;
    color: #fff !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-pagination button:disabled,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-pagination button:disabled {
    color: #cbd5e1 !important;
    cursor: not-allowed !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-page-size,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-page-size {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 8px !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-page-size strong,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-page-size strong {
    display: inline-grid !important;
    min-width: 48px !important;
    height: 40px !important;
    place-items: center !important;
    border: 1px solid #dfe7f0 !important;
    border-radius: 13px !important;
    color: #101828 !important;
  }
}

@media (min-width: 769px) and (max-width: 1500px) {
  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-grid,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-toolbar,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-toolbar {
    grid-template-columns: 1fr !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-controls,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-controls {
    justify-content: flex-start !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-card,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-card {
    grid-template-columns: minmax(230px, 1.15fr) minmax(140px, .68fr) minmax(100px, .52fr) minmax(118px, .58fr) minmax(118px, .58fr) 158px 50px !important;
    gap: 12px !important;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  html body[data-page="history"]:not(.auth-locked) .desktop-history-card,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-card {
    grid-template-columns: minmax(210px, 1fr) minmax(110px, .55fr) minmax(130px, .65fr) 150px 48px !important;
    grid-template-areas:
      "person amount period actions more"
      "date status status actions more" !important;
    min-height: 168px !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-date,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-date {
    grid-area: date !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-person,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-person {
    grid-area: person !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-card > .desktop-history-metric:nth-child(2),
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-card > .desktop-history-metric:nth-child(2) {
    grid-area: amount !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-card > .desktop-history-metric:nth-child(3),
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-card > .desktop-history-metric:nth-child(3) {
    grid-area: period !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-status,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-status {
    grid-area: status !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-actions,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-actions {
    grid-area: actions !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-more-button,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-more-button {
    grid-area: more !important;
  }
}

/* Desktop records/history card lock: match the tracking page scale, desktop only. */
@media (min-width: 769px) {
  html body[data-page="history"]:not(.auth-locked) .app-topbar.app-topbar.page-header.topbar,
  html body[data-records-subview="history"]:not(.auth-locked) .app-topbar.app-topbar.page-header.topbar {
    min-height: 150px !important;
    height: 150px !important;
    padding: 24px 32px !important;
    border-radius: 20px !important;
    border: 1px solid rgba(148, 163, 184, .24) !important;
    background: rgba(255, 255, 255, .86) !important;
    box-shadow: 0 22px 55px rgba(15, 23, 42, .075) !important;
    backdrop-filter: blur(18px) saturate(130%) !important;
  }

  html body[data-page="history"]:not(.auth-locked) .app-topbar.app-topbar.page-header.topbar h1,
  html body[data-records-subview="history"]:not(.auth-locked) .app-topbar.app-topbar.page-header.topbar h1 {
    font-size: clamp(2rem, 2.35vw, 2.7rem) !important;
    line-height: 1.02 !important;
    font-weight: 800 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel {
    width: calc(100% - 48px) !important;
    max-width: none !important;
    margin: 0 24px 0 8px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title {
    min-height: 150px !important;
    height: 150px !important;
    margin: 0 0 34px !important;
    padding: 24px 690px 24px 34px !important;
    border-radius: 20px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title h2 {
    font-size: clamp(2rem, 2.35vw, 2.7rem) !important;
    line-height: 1.02 !important;
    font-weight: 800 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title::after {
    top: 46px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordSearchBox.record-search {
    top: 46px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-board,
  html body[data-page="history"]:not(.auth-locked) #historyPanel.history-panel,
  html body[data-records-subview="history"]:not(.auth-locked) #historyPanel.history-panel {
    border: 1px solid #dfe7f0 !important;
    border-radius: 28px !important;
    background: #fff !important;
    box-shadow: 0 24px 60px rgba(15, 23, 42, .08) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-board,
  html body[data-page="history"]:not(.auth-locked) #desktopHistoryBoard,
  html body[data-records-subview="history"]:not(.auth-locked) #desktopHistoryBoard {
    padding: 30px 34px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-summary-grid,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-grid,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-grid {
    display: grid !important;
    grid-template-columns: repeat(6, minmax(0, 1fr)) !important;
    gap: 12px !important;
    align-items: stretch !important;
    margin: 0 0 18px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-summary-card,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-card,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-card {
    grid-template-columns: minmax(0, 1fr) 36px !important;
    min-height: 76px !important;
    height: 76px !important;
    padding: 12px 13px !important;
    border-radius: 14px !important;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .035) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-summary-copy,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-copy,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-copy {
    gap: 6px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-summary-copy > span,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-copy > span,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-copy > span {
    font-size: 11px !important;
    line-height: 1.1 !important;
    white-space: nowrap !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-summary-copy strong,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-copy strong,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-copy strong {
    gap: 5px !important;
    font-size: 22px !important;
    line-height: 1 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-summary-copy small,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-copy small,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-copy small {
    font-size: 10px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-summary-icon,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-icon,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-icon {
    width: 36px !important;
    height: 36px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-summary-icon svg,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-summary-icon svg,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-summary-icon svg {
    width: 18px !important;
    height: 18px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-toolbar,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-toolbar,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-toolbar {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    gap: 12px !important;
    align-items: center !important;
    margin: 0 0 22px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-filters,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-filters,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-filters {
    display: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-sort,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-controls,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-controls {
    justify-self: end !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-sort {
    width: 240px !important;
    min-width: 0 !important;
    height: 40px !important;
    min-height: 40px !important;
    padding: 0 12px !important;
    border-radius: 12px !important;
    box-shadow: 0 8px 20px rgba(15, 23, 42, .035) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-sort span,
  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-sort select {
    font-size: 12px !important;
    font-weight: 800 !important;
    line-height: 1 !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-sort select {
    height: 38px !important;
    min-height: 0 !important;
    padding: 0 18px 0 0 !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-list,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-list,
  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-list {
    gap: 14px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-card,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-card,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-card {
    gap: 14px !important;
    min-height: 208px !important;
    height: 208px !important;
    padding: 20px 18px !important;
    border-radius: 22px !important;
    box-shadow: 0 18px 42px rgba(15, 23, 42, .055) !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-actions button,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-actions button,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-actions button {
    min-height: 48px !important;
    height: auto !important;
    border-radius: 14px !important;
    font-size: 15px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-more-button,
  html body[data-page="history"]:not(.auth-locked) .desktop-history-more-button,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-more-button {
    width: 50px !important;
    min-height: 58px !important;
    height: 58px !important;
    border-radius: 16px !important;
  }
}

@media (min-width: 769px) and (max-width: 1800px) {
  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-card {
    grid-template-columns: minmax(240px, 1fr) minmax(132px, .62fr) minmax(132px, .62fr) minmax(150px, .72fr) 170px 56px !important;
    grid-template-areas:
      "person due amount status actions more"
      "person progress progress progress actions more" !important;
    align-items: stretch !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-person {
    grid-area: person !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-metric:nth-of-type(1) {
    grid-area: amount !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-metric:nth-of-type(2) {
    grid-area: status !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-metric:nth-of-type(3) {
    grid-area: due !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-progress {
    grid-area: progress !important;
    align-self: end !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-actions {
    grid-area: actions !important;
    align-self: center !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-more {
    grid-area: more !important;
    align-self: center !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-card,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-card {
    grid-template-columns: minmax(240px, 1fr) minmax(132px, .62fr) minmax(132px, .62fr) minmax(150px, .72fr) 170px 56px !important;
    grid-template-areas:
      "person amount period status actions more"
      "person date date date actions more" !important;
    align-items: stretch !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-person,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-person {
    grid-area: person !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-card > .desktop-history-metric:nth-child(2),
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-card > .desktop-history-metric:nth-child(2) {
    grid-area: amount !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-card > .desktop-history-metric:nth-child(3),
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-card > .desktop-history-metric:nth-child(3) {
    grid-area: period !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-date,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-date {
    grid-area: date !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-status,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-status {
    grid-area: status !important;
    align-self: center !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-actions,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-actions {
    grid-area: actions !important;
    align-self: center !important;
  }

  html body[data-page="history"]:not(.auth-locked) .desktop-history-more-button,
  html body[data-records-subview="history"]:not(.auth-locked) .desktop-history-more-button {
    grid-area: more !important;
    align-self: center !important;
  }
}

/* Desktop records/history/tracking frame lock: keep page shells from jumping between menus. */
@media (min-width: 769px) {
  html body[data-page="records"]:not(.auth-locked) .content-shell.main-content,
  html body[data-page="records"]:not(.auth-locked) .main-content,
  html body[data-page="tracking"]:not(.auth-locked) .content-shell.main-content,
  html body[data-page="tracking"]:not(.auth-locked) .main-content,
  html body[data-page="history"]:not(.auth-locked) .content-shell.main-content,
  html body[data-page="history"]:not(.auth-locked) .main-content,
  html body[data-records-subview="history"]:not(.auth-locked) .content-shell.main-content,
  html body[data-records-subview="history"]:not(.auth-locked) .main-content {
    display: grid !important;
    grid-template-columns: minmax(0, 1250px) !important;
    justify-content: center !important;
    align-content: start !important;
    gap: 20px !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 30px 40px 56px !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel,
  html body[data-page="history"]:not(.auth-locked) #historyPanel.history-panel,
  html body[data-records-subview="history"]:not(.auth-locked) #historyPanel.history-panel {
    width: 100% !important;
    max-width: 1250px !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel.records-panel {
    margin-top: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title,
  html body[data-page="tracking"]:not(.auth-locked) .app-topbar.app-topbar.page-header.topbar,
  html body[data-page="history"]:not(.auth-locked) .app-topbar.app-topbar.page-header.topbar,
  html body[data-records-subview="history"]:not(.auth-locked) .app-topbar.app-topbar.page-header.topbar {
    width: 100% !important;
    max-width: 1250px !important;
    min-height: 150px !important;
    height: 150px !important;
    margin: 0 !important;
    border-radius: 20px !important;
    border: 1px solid rgba(148, 163, 184, .24) !important;
    background: rgba(255, 255, 255, .86) !important;
    box-shadow: 0 22px 55px rgba(15, 23, 42, .075) !important;
    backdrop-filter: blur(18px) saturate(130%) !important;
  }

  html body[data-page="records"]:not(.auth-locked) #recordsPanel > .panel-title {
    margin-bottom: 72px !important;
    padding: 24px 690px 24px 34px !important;
  }

  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel,
  html body[data-page="history"]:not(.auth-locked) #historyPanel.history-panel,
  html body[data-records-subview="history"]:not(.auth-locked) #historyPanel.history-panel {
    margin-top: 34px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-board,
  html body[data-page="tracking"]:not(.auth-locked) .tracking-desktop-board,
  html body[data-page="history"]:not(.auth-locked) #desktopHistoryBoard,
  html body[data-records-subview="history"]:not(.auth-locked) #desktopHistoryBoard {
    width: 100% !important;
    max-width: 1250px !important;
  }

  html body[data-page="records"]:not(.auth-locked) .desktop-debtor-board,
  html body[data-page="tracking"]:not(.auth-locked) #trackingPanel.tracking-panel,
  html body[data-page="history"]:not(.auth-locked) #historyPanel.history-panel,
  html body[data-records-subview="history"]:not(.auth-locked) #historyPanel.history-panel {
    min-height: 420px !important;
  }
}
