/*
 * Compact desktop density.
 *
 * Full HD at 100% should feel like the former desktop layout at 80%.
 * The breakpoint deliberately stops at 1920px, so 2K/4K keep their
 * existing spacing, typography and panel sizes.
 */
@media (min-width: 901px) and (max-width: 1920px) {
  :root {
    --cms-side: 174px;
  }

  body.portal {
    font-size: 12px;
  }

  .cms-sidebar {
    padding: 12px 10px;
    gap: 9px;
  }

  .cms-brand {
    padding: 1px 6px 10px;
    font-size: 18px;
  }

  .cms-sidebar .cms-logo-img {
    width: 108px;
    height: 108px;
    max-width: 108px;
    max-height: 108px;
  }

  .cms-profile-mini {
    gap: 7px;
    padding: 8px;
    border-radius: 6px;
  }

  .cms-profile-mini i {
    width: 27px;
    height: 27px;
    font-size: 12px;
  }

  .cms-profile-mini b {
    max-width: 112px;
    font-size: 11.5px;
  }

  .cms-profile-mini small {
    margin-top: 2px;
    font-size: 9.5px;
  }

  .cms-lang-switch {
    gap: 5px;
  }

  .cms-lang-switch button {
    height: 26px;
    font-size: 10px;
  }

  .cms-nav-title {
    padding: 6px 7px 2px;
    font-size: 9.5px;
    letter-spacing: .65px;
  }

  .cms-nav {
    gap: 2px;
  }

  .cms-nav a {
    height: 34px;
    gap: 7px;
    padding: 0 7px;
    border-radius: 5px;
    font-size: 11.5px;
  }

  .cms-support {
    padding: 8px;
    font-size: 9.5px;
  }

  .cms-topbar {
    height: 62px;
    padding: 0 18px;
  }

  .cms-topbar h1 {
    font-size: 15px;
  }

  .cms-top-actions {
    gap: 7px;
  }

  .cms-wallet {
    gap: 7px;
    padding: 6px 8px;
    font-size: 11px;
  }

  .cms-content {
    padding: 13px 16px 24px;
  }

  .page-kicker {
    font-size: 9.5px;
  }

  .simple-page {
    max-width: 920px;
  }

  .simple-page h1 {
    margin: 5px 0 7px;
    font-size: 21.5px !important;
  }

  .simple-page p {
    font-size: 12px !important;
  }

  .simple-page > .page-card {
    padding: 19px !important;
  }

  .simple-page div[style*="font-size:80px"] {
    font-size: 64px !important;
  }

  .page-card {
    border-radius: 8px;
  }

  .auc-btn {
    height: 30px;
    padding: 0 10px;
    font-size: 11px;
  }

  .cms-content .craft-frame {
    height: calc(100vh - 116px);
  }

  /* Home */
  body.portal .home-page .hero {
    padding: 48px 32px !important;
  }

  body.portal .home-page .hero h1 {
    margin-bottom: 10px !important;
    font-size: 51px !important;
    letter-spacing: 1.6px !important;
  }

  body.portal .home-page .hero-subtitle {
    max-width: 560px !important;
    margin-bottom: 26px !important;
    font-size: 17.5px !important;
  }

  body.portal .home-page .hero-actions {
    gap: 13px !important;
  }

  body.portal .home-page .hero-actions .auc-btn {
    padding: 10px 26px !important;
    font-size: 14.5px !important;
  }

  body.portal .home-page .features-grid {
    grid-template-columns: repeat(auto-fit, minmax(208px, 1fr)) !important;
    gap: 16px !important;
    margin-top: 19px !important;
  }

  body.portal .home-page .feature-card {
    padding: 22px 19px !important;
  }

  body.portal .home-page .feature-icon {
    margin-bottom: 9px !important;
    font-size: 35px !important;
  }

  body.portal .home-page .feature-card h3 {
    margin-bottom: 6px !important;
    font-size: 16px !important;
  }

  body.portal .home-page .feature-card p {
    margin-bottom: 13px !important;
    font-size: 12px !important;
  }

  body.portal .home-page .feature-link {
    font-size: 12px !important;
  }

  body.portal .home-page .cta-section {
    margin-top: 22px !important;
    padding: 35px 26px !important;
  }

  body.portal .home-page .cta-section h2 {
    margin-bottom: 6px !important;
    font-size: 25.5px !important;
  }

  body.portal .home-page .cta-section p {
    margin-bottom: 16px !important;
    font-size: 14.5px !important;
  }

  /* Monitor */
  .cms-content .app .main {
    max-width: 1264px;
    padding: 0;
  }

  .cms-content .app .topbar {
    height: 50px;
    padding: 0 14px;
    margin-bottom: 11px;
    border-radius: 6px;
  }

  .cms-content .app .top-left {
    gap: 25px;
    font-size: 11.5px;
  }

  .cms-content .app .topbtn {
    height: 33px;
    padding: 0 13px;
    font-size: 11px;
  }

  .cms-content .app .panel {
    margin-bottom: 11px;
    border-radius: 6px;
  }

  .cms-content .app .panel-head {
    min-height: 43px;
    padding: 0 13px;
  }

  .cms-content .app .panel-title {
    font-size: 13.5px;
  }

  .cms-content .app .badge {
    padding: 4px 9px;
    font-size: 9.5px;
  }

  .cms-content .app .watch-table th {
    height: 39px;
    padding: 0 8px;
    font-size: 10.5px;
  }

  .cms-content .app .watch-table td {
    height: 56px;
    padding: 7px 8px;
    font-size: 11.5px;
  }

  .cms-content .app .watch-table .item-icon {
    width: 48px;
    height: 48px;
    flex-basis: 48px;
    border-radius: 7px;
  }

  .cms-content .app .watch-table .item-icon img {
    width: 43px;
    height: 43px;
  }

  .cms-content .app .watch-table .item-name-input,
  .cms-content .app .watch-table .mini {
    height: 43px;
    padding: 0 10px;
    font-size: 12.5px;
  }

  .cms-content .app .watch-table .num {
    font-size: 14px;
  }

  .cms-content .app .watch-table .any-wrap {
    gap: 7px;
    font-size: 11px;
  }

  .cms-content .app .watch-table .any-wrap input {
    width: 18px;
    height: 18px;
  }

  .cms-content .app .watch-table .marketCell {
    font-size: 13px;
  }

  .cms-content .app .watch-table .status-ok {
    font-size: 12px;
  }

  .cms-content .app .watch-table .ibtn {
    width: 35px;
    height: 34px;
  }

  .cms-content .app .watch-table .ibtn svg {
    width: 16px;
    height: 16px;
  }

  .cms-content .app .col-n {
    width: 34px;
  }

  .cms-content .app .col-enabled {
    width: 34px;
  }

  .cms-content .app .watch-toggle-all,
  .cms-content .app .watch-enabled {
    width: 17px;
    height: 17px;
  }

  .cms-content .app .col-price {
    width: 124px;
  }

  .cms-content .app .col-amount {
    width: 84px;
  }

  .cms-content .app .col-any {
    width: 116px;
  }

  .cms-content .app .col-market {
    width: 104px;
  }

  .cms-content .app .col-status {
    width: 100px;
  }

  .cms-content .app .col-actions {
    width: 120px;
  }

  .cms-content .app .lots-table th {
    height: 38px;
    padding: 0 8px;
    font-size: 10.5px;
  }

  .cms-content .app .lots-table td {
    height: 49px;
    padding: 7px 8px;
    font-size: 11.5px;
  }

  .cms-content .app .lots-table .lot-title,
  .cms-content .app .lots-table .seller,
  .cms-content .app .lots-table .money,
  .cms-content .app .lots-table .deal,
  .cms-content .app .lots-table .bad {
    font-size: 11.5px;
  }

  .cms-content .app .lots-table .item-icon {
    width: 35px;
    height: 35px;
    flex-basis: 35px;
  }

  .cms-content .app .lots-table .item-icon img {
    width: 32px;
    height: 32px;
  }

  .cms-content .app .history-small {
    width: 30px;
    height: 30px;
  }

  .cms-content .app .sort,
  .cms-content .app .columns-btn {
    height: 30px;
    padding: 0 9px;
    font-size: 10px;
  }

  .cms-content .app .columns-menu {
    top: 36px;
    width: 272px;
    padding: 11px;
  }

  .cms-content .app .columns-menu-title {
    font-size: 11px;
  }

  .cms-content .app .col-opt {
    padding: 4px 3px;
    font-size: 10px;
  }

  .cms-content .app .col-opt input {
    width: 14px;
    height: 14px;
  }

  .cms-content .app .modal-bg {
    padding: 64px 18px 18px;
  }

  .cms-content .app .modal {
    --hist-scale: .96;
    width: min(1056px, calc(100vw - 264px));
    max-height: calc(100vh - 84px);
    border-radius: 7px;
  }

  .cms-content .app .modal-head {
    height: 50px;
    padding: 0 16px;
  }

  .cms-content .app .modal-head #modalTitle {
    font-size: 15px;
  }

  .cms-content .app .modal-body {
    padding: 13px 16px 15px;
  }

  .cms-content .app .hist-scale button,
  .cms-content .app .hist-view button {
    height: 28px;
    min-width: 34px;
    padding: 0 9px;
  }

  .cms-content .app .metrics {
    margin: 12px 0;
  }

  .cms-content .app .metric {
    padding: 11px 13px;
  }

  .cms-content .app .chart-wrap {
    height: 376px;
  }

  .cms-content .app .hist-table-wrap {
    max-height: 448px;
  }

  .cms-content .app .hist-table th {
    height: 37px;
    padding: 0 11px;
  }

  .cms-content .app .hist-table td {
    height: 35px;
    padding: 0 11px;
  }

  .cms-content .app .subpanel {
    padding: 11px 13px;
  }

  .cms-content .app .modal-bottom {
    gap: 10px;
    margin-top: 10px;
  }

  /* Auction */
  .auction-search-page {
    gap: 10px;
    font-size: 11.5px;
  }

  .auction-query {
    padding: 10px;
  }

  .auction-query-title {
    gap: 7px;
    margin-bottom: 8px;
  }

  .auction-query-title b {
    font-size: 14.5px;
  }

  .auction-query-title span,
  .auction-query input,
  .auction-query select {
    font-size: 10.5px;
  }

  .auction-query input,
  .auction-query select {
    height: 29px;
  }

  .search-item-field {
    flex-basis: 240px;
  }

  .check-line {
    font-size: 9.5px;
  }

  .check-line input {
    width: 13px;
    height: 13px;
  }

  .auction-quick {
    padding: 0 11px 11px;
  }

  .quick-tab {
    padding: 7px 9px;
    font-size: 9.5px;
  }

  .quick-hint {
    padding: 8px 2px 7px;
    font-size: 9.5px;
  }

  .quick-grid {
    grid-template-columns: repeat(auto-fill, minmax(84px, 1fr));
    gap: 6px;
  }

  .quick-item {
    min-height: 83px;
    padding: 6px;
  }

  .quick-item img {
    width: 40px;
    height: 40px;
  }

  .quick-item b {
    font-size: 9.5px;
  }

  .quick-item small {
    font-size: 8px;
  }

  .auction-detail {
    gap: 10px;
  }

  .auction-stats {
    gap: 6px;
  }

  .market-stat {
    padding: 9px 11px;
  }

  .market-stat span {
    font-size: 8.5px;
  }

  .market-stat b {
    margin-top: 4px;
    font-size: 14px;
  }

  .lots-head {
    padding: 10px 12px;
  }

  .auction-selected {
    gap: 8px;
  }

  .auction-selected img {
    width: 35px;
    height: 35px;
  }

  .auction-selected h2 {
    font-size: 14px;
  }

  .auction-selected #auctionSearchInfo,
  .lots-note {
    font-size: 9px;
  }

  .search-table {
    min-width: 1008px;
  }

  .search-table th,
  .search-table td {
    padding: 8px 9px;
  }

  .search-table th {
    font-size: 8.5px;
  }

  .search-table td {
    font-size: 11.5px;
  }

  .search-table .lot-item {
    max-width: 208px;
  }

  .search-table .lot-item img {
    width: 32px;
    height: 32px;
  }

  .quality-tabs {
    gap: 5px;
    padding: 8px 13px;
  }

  .quality-tab {
    padding: 6px 10px;
  }

  .quality-tab b {
    font-size: 10.5px;
  }

  .quality-tab small {
    font-size: 8px;
  }

  .auction-history-modal {
    width: min(848px, 96vw);
    max-height: 92vh;
  }

  .history-modal-head {
    padding: 12px 14px;
  }

  .history-modal-head h2 {
    font-size: 16px;
  }

  .history-modal-body {
    padding: 13px 14px;
  }

  .history-presets button,
  .history-date-range input {
    height: 27px;
    padding: 0 9px;
    font-size: 9px;
  }

  .history-date-range label,
  .history-metrics span,
  .history-columns h4,
  .history-sales h4 {
    font-size: 8.5px;
  }

  .history-metrics > div {
    padding: 9px;
  }

  .history-metrics b {
    font-size: 13px;
  }

  .history-chart-wrap {
    height: 272px;
  }

  .history-columns {
    gap: 8px;
    margin-top: 8px;
  }

  .history-columns section,
  .history-sales {
    padding: 9px;
  }

  .history-dist,
  .history-columns section > div > div,
  .history-sales th,
  .history-sales td,
  .history-info {
    font-size: 8.5px;
  }

  /* Trends */
  .trends-page {
    gap: 11px;
  }

  .trends-head {
    gap: 14px;
    padding: 16px;
  }

  .trends-head h1 {
    margin: 3px 0 5px;
    font-size: 20px;
  }

  .trends-head p {
    font-size: 10.5px;
  }

  .trends-head-actions {
    gap: 9px;
  }

  .trends-limit {
    padding: 6px 8px;
    font-size: 9.5px;
  }

  .trends-limit b,
  .trends-col-title {
    font-size: 13px;
  }

  .trends-info {
    padding: 9px 12px;
    font-size: 9.5px;
  }

  .trends-list {
    gap: 6px;
  }

  .trends-lot {
    grid-template-columns: 45px minmax(144px, 1fr) minmax(92px, .65fr) minmax(92px, .65fr) 80px 109px 86px;
    gap: 11px;
    padding: 10px 13px;
  }

  .trends-icon {
    width: 42px;
    height: 42px;
  }

  .trends-icon img {
    width: 37px;
    height: 37px;
  }

  .trends-name {
    font-size: 12px;
  }

  .trends-name small,
  .trends-value span,
  .trends-trends small {
    margin-top: 3px;
    font-size: 8px;
  }

  .trends-value b,
  .trends-trends {
    font-size: 12px;
  }

  .trends-time {
    font-size: 9.5px;
  }

  .trends-tab {
    padding: 7px 13px;
    font-size: 10.5px;
  }

  .trends-tab.region {
    padding: 6px 10px;
    font-size: 9.5px;
  }

  .trends-columns {
    gap: 11px;
  }

  .trends-col {
    padding: 11px 13px;
  }

  .trends-col-title {
    margin-bottom: 10px;
    font-size: 13px;
  }

  .trends-cards {
    gap: 6px;
  }

  .trends-card {
    grid-template-columns: 42px minmax(96px, 1fr) minmax(77px, .7fr) minmax(77px, .7fr) 70px;
    gap: 10px;
    padding: 8px 10px;
  }

  .trends-delta {
    font-size: 12px;
  }

  /* Catalog */
  .catalog-page {
    gap: 13px;
    font-size: 14.5px;
  }

  .catalog-hero {
    min-height: 131px;
    padding: 24px 27px;
    gap: 19px;
  }

  .catalog-hero span {
    font-size: 12.5px;
  }

  .catalog-hero h2 {
    font-size: 31px;
  }

  .catalog-hero p {
    font-size: 15px;
  }

  .catalog-hero .auc-btn {
    height: 48px;
    padding: 0 22px;
    font-size: 15px;
  }

  .catalog-stats {
    gap: 10px;
  }

  .catalog-stats article {
    min-height: 98px;
    padding: 18px 20px;
  }

  .catalog-stats span {
    font-size: 13px;
  }

  .catalog-stats b {
    font-size: 30px;
  }

  .catalog-layout {
    grid-template-columns: minmax(544px, 1.5fr) minmax(456px, 1fr);
    gap: 14px;
  }

  .catalog-browser-head {
    padding: 16px;
    gap: 11px;
  }

  .catalog-search {
    height: 46px;
  }

  .catalog-search span {
    padding-left: 14px;
    font-size: 23px;
  }

  .catalog-search input {
    height: 44px;
    padding: 0 13px;
    font-size: 15px;
  }

  .catalog-filters {
    gap: 7px;
  }

  .catalog-filters button {
    height: 37px;
    padding: 0 13px;
    font-size: 12.5px;
  }

  .catalog-browser-actions #catalogNew {
    height: 37px;
    padding: 0 14px;
    font-size: 12.5px;
  }

  .catalog-list {
    height: min(576px, calc(100vh - 312px));
    min-height: 448px;
    padding: 10px;
    gap: 8px;
  }

  .catalog-item {
    min-height: 86px;
    padding: 10px 12px;
    grid-template-columns: 61px minmax(0, 1fr) auto;
    gap: 13px;
  }

  .catalog-item-icon {
    width: 61px;
    height: 61px;
  }

  .catalog-item-icon img {
    width: 54px;
    height: 54px;
  }

  .catalog-item-copy b {
    font-size: 16px;
  }

  .catalog-item-copy small {
    margin-top: 5px;
    font-size: 13px;
  }

  .catalog-item-tags span {
    padding: 5px 7px;
    font-size: 11px;
  }

  .catalog-editor {
    padding: 22px;
  }

  .catalog-editor-title h3 {
    font-size: 25px;
  }

  .catalog-icon-section {
    margin-top: 19px;
    padding: 14px;
    grid-template-columns: 128px minmax(0, 1fr);
    gap: 14px;
  }

  .catalog-icon-preview {
    width: 128px;
    height: 128px;
  }

  .catalog-icon-preview img {
    width: 118px;
    height: 118px;
  }

  .catalog-form-grid {
    margin-top: 18px;
    gap: 14px;
  }

  .catalog-form-grid span {
    font-size: 13.5px;
  }

  .catalog-form-grid input,
  .catalog-form-grid select {
    height: 45px;
    padding: 0 12px;
    font-size: 15px;
  }

  /* Warehouse */
  .warehouse-page {
    gap: 13px;
    font-size: 12.5px;
  }

  .warehouse-toolbar {
    padding: 11px;
    grid-template-columns: minmax(264px, 1fr) 176px auto auto;
    gap: 9px;
  }

  .warehouse-toolbar.warehouse-toolbar-v2 {
    grid-template-columns:
      minmax(210px, 1fr)
      minmax(145px, 176px)
      auto
      minmax(145px, auto)
      auto
      auto;
  }

  .warehouse-search-wrap {
    height: 38px;
  }

  .warehouse-search-wrap span {
    padding-left: 12px;
    font-size: 20px;
  }

  .warehouse-search-wrap input,
  .warehouse-toolbar select {
    height: 37px;
    padding: 0 10px;
    font-size: 12.5px;
  }

  .warehouse-toolbar .auc-btn,
  .warehouse-page .auc-btn,
  .warehouse-modal .auc-btn {
    min-height: 35px;
    height: 38px;
    padding: 0 14px;
    font-size: 12.5px;
  }

  .warehouse-layout {
    grid-template-columns: minmax(0, 1fr) 10px var(--warehouse-side-width, 520px);
    gap: 8px;
  }

  .warehouse-section-head {
    min-height: 62px;
    padding: 0 18px;
  }

  .warehouse-section-head > div {
    gap: 12px;
  }

  .warehouse-section-head b {
    font-size: 19px;
  }

  .warehouse-section-head span {
    font-size: 14.5px;
  }

  .warehouse-section-head small {
    font-size: 12px;
  }

  .warehouse-trash {
    min-height: 83px;
    margin: 12px 13px 0;
    padding: 11px 18px;
    gap: 14px;
  }

  .warehouse-trash-icon {
    font-size: 40px;
  }

  .warehouse-trash b {
    font-size: 18px;
  }

  .warehouse-trash small {
    font-size: 13.5px;
  }

  .warehouse-grid {
    padding: 13px;
    grid-template-columns: repeat(auto-fill, minmax(184px, 1fr));
    gap: 9px;
  }

  .warehouse-card {
    min-height: 228px;
    padding: 12px;
  }

  .warehouse-card-count {
    right: 12px;
    top: 10px;
    font-size: 18.5px;
  }

  .warehouse-card img {
    width: 99px;
    height: 99px;
    margin: 12px auto 8px;
  }

  .warehouse-card-name {
    font-size: 15px;
  }

  .warehouse-card-price {
    margin-top: 6px;
    font-size: 12.5px;
  }

  .warehouse-quick {
    left: 11px;
    right: 11px;
    bottom: 10px;
    height: 34px;
    grid-template-columns: 37px 1fr 37px;
  }

  .warehouse-quick button {
    font-size: 20px;
  }

  .warehouse-quick span {
    font-size: 10.5px;
  }

  .warehouse-side {
    top: 67px;
  }

  .warehouse-inspector {
    max-height: calc(100vh - 80px);
    min-height: 488px;
    padding: 18px;
  }

  .warehouse-side-title {
    font-size: 18px;
  }

  .warehouse-side-title button {
    width: 34px;
    height: 34px;
    font-size: 22px;
  }

  .warehouse-edit-empty {
    min-height: 400px;
  }

  .warehouse-edit-empty span {
    font-size: 61px;
  }

  .warehouse-edit-empty b {
    margin: 14px 0 7px;
    font-size: 20px;
  }

  .warehouse-edit-empty small {
    max-width: 264px;
    font-size: 13.5px;
  }

  .warehouse-edit-item {
    gap: 14px;
    margin: 19px 0;
    padding: 13px;
  }

  .warehouse-edit-item img {
    width: 93px;
    height: 93px;
  }

  .warehouse-edit-item b {
    font-size: 17.5px;
  }

  .warehouse-edit-item small {
    font-size: 12.5px;
  }

  .warehouse-edit-panel label {
    gap: 7px;
    margin: 14px 0;
    font-size: 14.5px;
  }

  .warehouse-edit-panel input {
    height: 40px;
    padding: 0 11px;
    font-size: 16px;
  }

  .warehouse-price-source {
    gap: 7px;
    margin: 16px 0;
  }

  .warehouse-price-source button {
    min-height: 43px;
    font-size: 12.5px;
  }

  .warehouse-median-info {
    gap: 6px;
    margin: 13px 0 16px;
    padding: 13px;
  }

  .warehouse-median-info span,
  .warehouse-median-info small {
    font-size: 12px;
  }

  .warehouse-median-info b {
    font-size: 21.5px;
  }

  .warehouse-edit-panel .auc-btn.primary {
    height: 42px;
    margin-top: 11px;
    font-size: 14.5px;
  }

  .warehouse-dialog-head {
    min-height: 75px;
    padding: 14px 18px;
  }

  .warehouse-dialog-head span {
    font-size: 10px;
  }

  .warehouse-dialog-head b {
    font-size: 20px;
  }

  .warehouse-dialog-head small {
    font-size: 12px;
  }

  .warehouse-dialog-body {
    padding: 14px 18px 11px;
  }

  .warehouse-item-search > input {
    height: 37px !important;
    padding-left: 39px !important;
    font-size: 13.5px !important;
  }

  .warehouse-dialog-body > label > input {
    height: 37px;
    font-size: 14px;
  }

  .warehouse-dialog-foot {
    padding: 11px 18px 14px;
  }

  /* Account */
  .account-dashboard {
    gap: 13px;
    font-size: 12.5px;
  }

  .account-profile-strip {
    padding: 14px 16px;
  }

  .profile-main {
    gap: 11px;
  }

  .profile-avatar {
    width: 46px;
    height: 46px;
    font-size: 19px;
  }

  .profile-main h2 {
    font-size: 19px;
  }

  .profile-badges {
    gap: 6px;
    margin-top: 6px;
    font-size: 11px;
  }

  .profile-badges span {
    padding: 3px 6px;
  }

  .balance-mini {
    min-width: 176px;
    padding: 10px 11px;
  }

  .balance-mini small {
    font-size: 11px;
  }

  .balance-mini b {
    margin-top: 4px;
    font-size: 24px;
  }

  .account-grid {
    gap: 13px;
  }

  .account-card {
    padding: 14px;
  }

  .card-title {
    padding-bottom: 10px;
    font-size: 17px;
  }

  .card-title a {
    font-size: 10.5px;
  }

  .muted {
    font-size: 12.5px;
  }

  .muted.small,
  .small {
    font-size: 11px;
  }

  .field-label {
    margin: 11px 0 6px;
    font-size: 11.5px;
  }

  .money-input {
    height: 35px;
  }

  .offer-check {
    margin: 10px 0;
    font-size: 11.5px;
  }

  .offer-check input {
    width: 14px;
    height: 14px;
  }

  .account-dashboard .auc-btn,
  .identity-btn {
    height: 31px;
    min-width: 88px;
    padding: 0 12px;
    font-size: 11px;
  }

  .notice {
    margin-top: 11px;
    padding: 9px 10px;
    font-size: 11px;
  }

  .product-list {
    gap: 6px;
    margin-top: 10px;
  }

  .product-row {
    grid-template-columns: 34px 1fr 74px 66px;
    gap: 8px;
    padding: 8px;
  }

  .product-icon {
    width: 30px;
    height: 30px;
  }

  .product-copy b {
    font-size: 13.5px;
  }

  .product-copy small,
  .product-price small {
    font-size: 9.5px;
  }

  .product-price {
    font-size: 16px;
  }

  .benefits {
    gap: 5px;
    margin-top: 10px;
    padding-top: 9px;
    font-size: 11px;
  }

  .slot-circle {
    width: 106px;
    height: 106px;
    border-width: 10px;
  }

  .slot-circle b {
    font-size: 27px;
  }

  .slot-circle span {
    font-size: 14px;
  }

  .slot-circle small {
    bottom: 19px;
    font-size: 10.5px;
  }

  .slot-summary span {
    padding: 7px;
    font-size: 11px;
  }

  .slot-summary b {
    font-size: 14.5px;
  }

  .slot-products > div {
    gap: 6px;
    font-size: 11px;
  }

  .ref-stats span {
    padding: 9px;
    font-size: 8.5px;
  }

  .ref-stats b {
    font-size: 16px;
  }

  .identity-row {
    grid-template-columns: 38px 1fr auto;
    gap: 11px;
    padding: 9px 11px;
  }

  .identity-mark {
    width: 35px;
    height: 35px;
    font-size: 12px;
  }

  .identity-info b {
    font-size: 12.5px;
  }

  .identity-info small {
    font-size: 10.5px;
  }

  .quick-grid {
    gap: 6px;
  }

  .quick-grid a {
    min-height: 58px;
    padding: 7px;
    font-size: 16px;
  }

  .quick-grid a span {
    font-size: 10.5px;
  }

  .account-stats-strip {
    padding: 11px;
  }

  .account-stats-strip > div {
    padding: 4px 12px;
  }

  .account-stats-strip span {
    font-size: 17px;
  }

  .account-stats-strip small {
    font-size: 11px;
  }

  .account-stats-strip b {
    font-size: 13px;
  }

  .profile-form {
    gap: 13px 11px;
    margin-top: 11px;
  }

  .profile-form input {
    height: 34px;
    padding: 0 10px;
    font-size: 12px;
  }

  .profile-form-actions {
    gap: 8px;
    margin-top: 14px;
  }

  /* Admin */
  .admin-shell {
    gap: 13px;
    font-size: 12px;
  }

  .admin-head {
    min-height: 144px;
    padding: 24px 27px;
    gap: 16px;
  }

  .admin-head h2 {
    margin: 4px 0;
    font-size: 24px;
  }

  .admin-head p,
  .admin-section-title p {
    font-size: 11.5px;
  }

  .admin-head > div:first-child > span,
  .admin-section-title span,
  .admin-editor-block-title > div > span,
  .admin-revenue-chart header > div > span,
  .admin-payments header > div > span {
    font-size: 17.5px;
  }

  .admin-role-badge {
    min-width: 256px;
    padding: 20px 22px;
  }

  .admin-role-badge small {
    font-size: 11px;
  }

  .admin-role-badge b {
    font-size: 14px;
  }

  .admin-tabs {
    gap: 6px;
    padding: 7px;
  }

  .admin-tabs a {
    min-height: 38px;
    padding: 0 14px;
    gap: 7px;
    font-size: 12px;
  }

  .admin-tabs a span {
    font-size: 16px;
  }

  .admin-root-access {
    padding: 23px 25px;
  }

  .admin-section-title h3 {
    font-size: 19px;
  }

  .admin-role-form {
    margin-top: 12px;
    grid-template-columns: minmax(208px, 1fr) minmax(192px, .7fr) auto;
    gap: 8px;
  }

  .admin-role-form label span,
  .admin-reason span,
  .admin-security label span,
  .admin-access-grid label span {
    font-size: 15px;
  }

  .admin-role-form input,
  .admin-role-form select,
  .admin-reason input,
  .admin-security input,
  .admin-access-grid input {
    height: 50px;
    padding: 0 13px;
    font-size: 12px;
  }

  .admin-role-form .auc-btn {
    height: 50px;
    font-size: 16px;
  }

  .admin-grant-list {
    gap: 6px;
    margin-top: 10px;
  }

  .admin-grant {
    padding: 8px 11px;
    font-size: 15px;
  }

  .admin-user-stats,
  .admin-accounting-summary {
    gap: 9px;
  }

  .admin-user-stats article,
  .admin-accounting-summary article {
    min-height: 112px;
    padding: 17px 19px;
  }

  .admin-user-stats span,
  .admin-accounting-summary span {
    font-size: 15px;
  }

  .admin-user-stats b,
  .admin-accounting-summary b {
    font-size: 15px;
  }

  .admin-accounting-summary small {
    font-size: 14.5px;
  }

  .admin-users-layout {
    grid-template-columns: minmax(608px, 1.55fr) minmax(480px, 1fr);
    gap: 13px;
  }

  .admin-users-toolbar {
    padding: 11px;
    grid-template-columns: 1fr 50px;
    gap: 6px;
  }

  .admin-users-toolbar label {
    height: 50px;
  }

  .admin-users-toolbar label span {
    padding-left: 10px;
    font-size: 22px;
  }

  .admin-users-toolbar input {
    height: 48px;
    font-size: 12px;
  }

  .admin-users-toolbar > button {
    font-size: 23px;
  }

  .admin-shell .admin-users-table th {
    padding: 9px 10px;
    font-size: 11px;
  }

  .admin-shell .admin-users-table td {
    padding: 10px;
    font-size: 12px;
  }

  .admin-table-user {
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 9px;
    min-width: 256px;
  }

  .admin-table-user > span {
    width: 48px;
    height: 48px;
    font-size: 15px;
  }

  .admin-table-user b {
    font-size: 18.5px;
  }

  .admin-table-user small {
    font-size: 13.5px;
  }

  .admin-status {
    padding: 5px 7px;
    font-size: 13px;
  }

  .admin-user-editor {
    top: 67px;
    max-height: calc(100vh - 80px);
    padding: 21px;
  }

  .admin-user-profile {
    grid-template-columns: 66px 1fr 42px;
    gap: 13px;
  }

  .admin-user-profile > div {
    width: 66px;
    height: 66px;
    font-size: 26px;
  }

  .admin-user-profile section > span {
    font-size: 13.5px;
  }

  .admin-user-profile h3 {
    font-size: 26px;
  }

  .admin-user-profile small {
    font-size: 14.5px;
  }

  .admin-user-profile > button {
    width: 42px;
    height: 42px;
    font-size: 24px;
  }

  .admin-user-flags {
    gap: 6px;
    margin: 13px 0;
  }

  .admin-user-flags span {
    padding: 6px 9px;
    font-size: 14px;
  }

  .admin-editor-block {
    margin-top: 13px;
    padding: 17px;
  }

  .admin-editor-block-title h4 {
    font-size: 18px;
  }

  .admin-editor-block-title > button {
    height: 37px;
    font-size: 14px;
  }

  .admin-balance-grid article {
    padding: 11px;
  }

  .admin-balance-grid small {
    font-size: 14.5px;
  }

  .admin-balance-grid b {
    font-size: 26px;
  }

  .admin-balance-grid input,
  .admin-balance-grid button {
    height: 45px;
    font-size: 16px;
  }

  .admin-access-status span {
    font-size: 14px;
  }

  .admin-access-grid .auc-btn {
    height: 48px;
    font-size: 16px;
  }

  .admin-security > button {
    height: 46px;
    font-size: 16px;
  }

  .admin-identity,
  .admin-ip,
  .admin-history-row {
    padding: 9px 10px;
  }

  .admin-identity b,
  .admin-ip b,
  .admin-history-row b,
  .admin-history-row strong {
    font-size: 15px;
  }

  .admin-identity small,
  .admin-ip small,
  .admin-history-row small,
  .admin-ip > span,
  .admin-identity > span,
  .admin-history-row em {
    font-size: 13.5px;
  }

  .admin-periods {
    gap: 9px;
  }

  .admin-periods article {
    padding: 18px 19px;
  }

  .admin-periods span {
    font-size: 15px;
  }

  .admin-periods b {
    font-size: 15px;
  }

  .admin-periods small {
    font-size: 14.5px;
  }

  .admin-periods em {
    font-size: 13.5px;
  }

  .admin-accounting-grid {
    gap: 13px;
  }

  .admin-revenue-chart,
  .admin-payments {
    padding: 19px;
  }

  .admin-revenue-chart h3,
  .admin-payments h3 {
    font-size: 19px;
  }

  .admin-revenue-chart header button {
    height: 42px;
    padding: 0 11px;
    font-size: 14px;
  }

  .admin-bars {
    height: 312px;
    padding-bottom: 30px;
  }

  .admin-shell .admin-payments th,
  .admin-shell .admin-payments td {
    padding: 11px 9px;
    font-size: 12px;
  }

  .admin-user-modal {
    padding: 22px;
  }

  .admin-user-modal .admin-user-editor {
    width: min(1088px, calc(100vw - 44px));
    max-height: calc(100vh - 44px);
    padding: 22px 24px;
  }

  .admin-user-modal .admin-user-profile {
    grid-template-columns: 59px 1fr 38px;
    gap: 14px;
  }

  .admin-user-modal .admin-user-profile > div {
    width: 59px;
    height: 59px;
    font-size: 24px;
  }

  .admin-user-modal .admin-user-profile section > span {
    font-size: 12px;
  }

  .admin-user-modal .admin-user-profile h3 {
    font-size: 24px;
  }

  .admin-user-modal .admin-user-profile small {
    font-size: 13px;
  }

  .admin-user-modal .admin-user-profile > button {
    width: 38px;
    height: 38px;
    font-size: 23px;
  }

  .admin-user-modal .admin-user-flags span {
    font-size: 12px;
  }

  .admin-user-panel-tabs {
    gap: 6px;
    padding: 7px;
  }

  .admin-user-panel-tabs button {
    min-height: 42px;
    padding: 6px 10px;
    font-size: 12px;
  }

  .admin-user-panel-body .admin-editor-block {
    margin-top: 13px;
    padding: 18px;
  }

  .admin-user-panel-body .admin-editor-block-title h4 {
    font-size: 20px;
  }

  .admin-auth-toolbar {
    padding: 22px 24px;
    gap: 22px;
  }

  .admin-auth-toolbar > div > span {
    font-size: 13px;
  }

  .admin-auth-toolbar h3 {
    font-size: 28px;
  }

  .admin-auth-toolbar p {
    font-size: 14px;
  }

  .admin-auth-toolbar .auc-btn {
    min-width: 240px;
    height: 46px;
    padding: 0 18px;
    font-size: 14px;
  }

  .admin-auth-grid {
    gap: 12px;
  }

  .admin-auth-provider {
    padding: 18px;
  }

  .admin-auth-provider > header {
    grid-template-columns: 48px 1fr auto;
    gap: 10px;
    padding-bottom: 12px;
  }

  .admin-auth-mark {
    width: 46px;
    height: 46px;
    font-size: 14px;
  }

  .admin-auth-provider > header small {
    font-size: 11px;
  }

  .admin-auth-provider h4 {
    font-size: 21px;
  }

  .admin-auth-provider > header em {
    padding: 6px 8px;
    font-size: 11px;
  }

  .admin-auth-field > label > span {
    font-size: 13px;
  }

  .admin-auth-field > label > input {
    height: 43px;
    padding: 0 11px;
  }

  .admin-auth-field > label > input,
  .admin-auth-field > label > textarea {
    font-size: 14px;
  }

  .admin-auth-field > small {
    font-size: 11px;
  }

  .admin-workers-head {
    padding: 18px 19px;
  }

  .admin-workers-head h3 {
    font-size: 20px;
  }

  .admin-workers-head p {
    font-size: 12px;
  }

  .admin-worker-card {
    padding: 11px 13px;
  }

  .admin-worker-head b {
    font-size: 14px;
  }

  .admin-worker-head small,
  .admin-worker-card p,
  .admin-worker-meta,
  .admin-worker-setting p {
    font-size: 11px;
  }

  .admin-worker-meta code,
  .admin-worker-setting-head code {
    font-size: 10.5px;
  }

  .admin-promo-maker,
  .admin-prices {
    padding: 22px;
  }

  .admin-promo-maker {
    max-width: 784px;
  }

  .admin-prices {
    max-width: 896px;
  }

  .admin-promo-maker h3,
  .admin-prices h3 {
    margin: 6px 0;
    font-size: 22px;
  }

  .admin-promo-maker p,
  .admin-prices p {
    font-size: 13.5px;
  }

  .admin-promo-grid {
    gap: 11px;
    margin: 18px 0;
  }

  .admin-promo-grid input,
  .admin-promo-grid select {
    height: 34px;
  }

  .admin-promo-result {
    margin-top: 13px;
    padding: 13px;
    font-size: 14.5px;
  }

  .admin-promo-result b {
    font-size: 20px;
  }

  .admin-prices-list {
    gap: 10px;
    margin-top: 22px;
  }

  .admin-prices-list label {
    grid-template-columns: minmax(0, 1fr) 136px 24px 114px;
    gap: 10px;
    padding: 14px;
  }

  .admin-prices-list b {
    font-size: 15px;
  }

  .admin-prices-list small {
    font-size: 10.5px;
  }

  .admin-prices-list input {
    height: 37px;
    padding: 0 10px;
    font-size: 16px;
  }

  .admin-prices-list > label > span {
    font-size: 16px;
  }

  .admin-prices-list .auc-btn {
    height: 37px;
    font-size: 12px;
  }

  .admin-i18n {
    max-width: 960px;
    padding: 21px;
  }

  .admin-i18n h3 {
    font-size: 22px;
  }

  .admin-i18n p {
    font-size: 12px;
  }

  .admin-i18n-lang,
  .admin-i18n-controls input[type="search"] {
    height: 30px;
  }

  .admin-i18n-stats {
    gap: 8px;
    margin-bottom: 11px;
    font-size: 11px;
  }

  .admin-i18n-row {
    gap: 11px;
    padding: 10px 11px;
  }

  .admin-i18n-key code,
  .admin-i18n-key small {
    font-size: 10.5px;
  }

  .admin-i18n-value {
    min-height: 42px;
    padding: 7px 9px;
    font-size: 12px;
  }

  .admin-i18n-actions .auc-btn {
    height: 30px;
    min-width: 84px;
  }

  .admin-settings-group-head b {
    font-size: 11px;
  }

  .admin-settings-group-head small,
  .admin-setting-label,
  .admin-setting-desc {
    font-size: 10px;
  }

  .admin-setting {
    padding: 8px 10px;
  }

  .admin-setting-label input[type=number] {
    width: 88px;
    height: 24px;
  }

  .oauth-message {
    width: min(416px, calc(100vw - 32px));
    padding: 27px;
  }

  .oauth-message h1 {
    font-size: 23px;
  }

  .oauth-message p {
    font-size: 12px;
  }

  .auth-modal-layer {
    padding: 19px;
  }

  .auth-dialog {
    width: min(688px, calc(100vw - 32px));
    max-height: calc(100vh - 32px);
    padding: 27px 30px 29px;
    border-radius: 11px;
  }

  .auth-dialog-close {
    top: 13px;
    right: 13px;
    width: 30px;
    height: 30px;
    font-size: 19px;
  }

  .auth-dialog-brand {
    height: 50px;
  }

  .auth-dialog-brand img {
    width: 128px;
    height: 50px;
  }

  .auth-dialog-kicker {
    font-size: 10.5px;
  }

  .auth-dialog h1 {
    font-size: 24px;
  }

  .auth-dialog-lead {
    margin: 7px 0 16px;
    font-size: 12px;
  }

  .auth-provider-list {
    gap: 9px;
  }

  .auth-provider {
    min-height: 58px;
    grid-template-columns: 38px 1fr 22px;
    gap: 11px;
    padding: 0 13px;
    border-radius: 8px;
  }

  .auth-provider-mark {
    width: 37px;
    height: 37px;
    font-size: 11px;
  }

  .auth-provider-mark svg {
    width: 22px;
    height: 22px;
  }

  .auth-provider-copy b {
    font-size: 13.5px;
  }

  .auth-provider-copy small {
    margin-top: 3px;
    font-size: 10.5px;
  }

  .auth-provider-arrow {
    font-size: 18px;
  }

  .auth-more > summary {
    min-height: 54px;
    grid-template-columns: 38px 1fr 22px;
    gap: 11px;
    padding: 0 13px;
  }

  .auth-more-content {
    gap: 14px;
    padding: 14px;
  }

  /* Operations and settings */
  .operations-page {
    gap: 13px;
  }

  .operations-head {
    gap: 19px;
    padding: 23px 27px;
  }

  .operations-head h2 {
    margin: 6px 0;
    font-size: 28px;
  }

  .operations-head p {
    font-size: 13.5px;
  }

  .operations-table-head {
    padding: 16px 20px;
    font-size: 14.5px;
  }

  .operations-table-head span {
    font-size: 12px;
  }

  .operations-table th {
    padding: 12px 18px;
    font-size: 10.5px;
  }

  .operations-table td {
    padding: 14px 18px;
    font-size: 13px;
  }

  .operation-type {
    padding: 4px 7px;
    font-size: 10px;
  }

  .settings-bg {
    padding: 18px;
  }

  .settings-modal {
    width: min(1176px, 97vw);
    max-height: min(880px, 96vh);
  }

  .settings-head {
    min-height: 66px;
    padding: 0 24px;
  }

  .settings-title {
    font-size: 18px;
  }

  .settings-title small {
    margin-top: 3px;
    font-size: 11px;
  }

  .settings-x {
    width: 30px;
    height: 37px;
    font-size: 22px;
  }

  .settings-body {
    padding: 22px 24px 24px;
  }

  .settings-section {
    padding-bottom: 16px;
    margin-bottom: 16px;
  }

  .settings-section-title {
    margin-bottom: 11px;
    font-size: 14px;
  }

  .settings-form-grid {
    gap: 10px 13px;
  }

  .settings-label {
    font-size: 12px;
  }

  .settings-help {
    font-size: 10.5px;
  }

  .settings-control {
    height: 40px;
    padding: 0 9px;
  }

  .scan-mode-card {
    padding: 14px 16px;
  }

  .scan-mode-card b {
    font-size: 14px;
  }

  .scan-mode-card small {
    font-size: 11px;
  }

  .toggle-row {
    min-height: 50px;
    padding: 7px 10px;
  }

  .toggle-copy b {
    font-size: 13px;
  }

  .toggle-copy small {
    font-size: 10.5px;
  }

  .settings-small-btn {
    height: 34px;
    font-size: 11px;
  }

  .settings-columns-grid {
    grid-template-columns: repeat(3, minmax(144px, 1fr));
    gap: 7px 10px;
    padding: 11px;
    max-height: 248px;
  }

  .settings-col-opt {
    min-height: 34px;
    gap: 8px;
    padding: 5px 6px;
    font-size: 12px;
  }

  .settings-col-opt input {
    width: 16px;
    height: 16px;
    flex-basis: 16px;
  }

  .settings-foot {
    min-height: 66px;
    padding: 0 24px;
  }

  .settings-btn {
    height: 37px;
    padding: 0 12px;
  }

  /* Calculators */
  .calculators-page {
    max-width: 976px;
  }

  .calculators-intro {
    padding: 29px 32px;
  }

  .calculators-intro h2,
  .inventory-calculator-placeholder h2 {
    margin: 6px 0 8px;
    font-size: 30.5px;
  }

  .calculators-intro p,
  .inventory-calculator-placeholder p {
    max-width: 624px;
    font-size: 14.5px;
  }

  .calculators-grid {
    gap: 14px;
    margin-top: 14px;
  }

  .calculator-card {
    min-height: 176px;
    padding: 22px;
    grid-template-columns: 54px 1fr;
    gap: 0 16px;
  }

  .calculator-icon {
    width: 50px;
    height: 50px;
    font-size: 26px;
  }

  .calculator-card small {
    font-size: 9px;
  }

  .calculator-card h3 {
    margin: 6px 0 8px;
    font-size: 20px;
  }

  .calculator-card p {
    font-size: 12.5px;
  }

  .calculator-card > b {
    font-size: 12.5px;
  }

  .craftPage {
    gap: 10px;
  }

  .craftPageHead h1 {
    margin: 2px 0 4px;
    font-size: 20px;
  }

  .craftPageHead p {
    font-size: 12px;
  }

  .craftSuperFrame {
    height: calc(100vh - 114px);
    min-height: 656px;
  }

  .inventory-calculator {
    max-width: 1136px;
    gap: 13px;
  }

  .inventory-calc-head {
    padding: 22px 24px;
    gap: 20px;
  }

  .inventory-calc-head h2 {
    font-size: 27px;
  }

  .inventory-calc-head p {
    font-size: 13px;
  }

  .inventory-calc-upload {
    padding: 16px;
    gap: 14px;
  }

  .inventory-calc-drop {
    min-height: 84px;
  }

  .inventory-calc-workspace {
    grid-template-columns: minmax(0, 1fr) 288px;
    gap: 13px;
  }

  .inventory-calc-list-head {
    padding: 16px 18px;
  }

  .inventory-calc-list-head b {
    font-size: 14.5px;
  }

  .inventory-calc-list-head span {
    font-size: 10.5px;
  }

  .inventory-calc-items {
    padding: 0 14px 14px;
  }

  .inventory-calc-item {
    grid-template-columns: 58px minmax(144px, 1fr) 104px minmax(160px, 1fr) 28px;
    gap: 11px;
    padding: 10px;
  }

  .inventory-calc-item img {
    width: 51px;
    height: 51px;
  }

  .inventory-calc-name b {
    font-size: 13.5px;
  }

  .inventory-calc-name small {
    font-size: 9.5px;
  }

  .inventory-calc-result {
    top: 76px;
    padding: 20px;
  }

  .inventory-calc-result h3 {
    font-size: 30.5px;
  }

  .inventory-calc-break {
    font-size: 10.5px;
  }
}

/* Standalone craft calculator. */
@media (min-width: 901px) and (max-width: 1920px) {
  .craftApp {
    gap: 10px;
    font-size: 12px;
  }

  .craftToolbar {
    grid-template-columns: minmax(280px, 1fr) auto auto;
    gap: 8px;
  }

  .searchWrap input,
  .stockSearch input,
  .formStack input,
  .formStack select,
  .resultFields input,
  .rightFilter select,
  .settingEditor input {
    height: 36px;
    padding: 0 10px;
  }

  .settingAuctionBtn {
    height: 36px;
    padding: 0 9px;
    font-size: 10.5px;
  }

  .searchWrap input {
    padding-left: 34px;
    font-size: 12px;
  }

  .searchIcon {
    left: 11px;
    top: 6px;
    font-size: 20px;
  }

  .suggest {
    top: 40px;
    max-height: 336px;
  }

  .suggestItem {
    gap: 8px;
    padding: 8px 10px;
  }

  .suggestItem img {
    width: 32px;
    height: 32px;
  }

  .uiBtn {
    height: 36px;
    padding: 0 13px;
    font-size: 11px;
  }

  .workspaceTabs {
    height: 38px;
  }

  .workspaceTab {
    padding: 0 16px;
    font-size: 11px;
  }

  .mainGrid {
    gap: 10px !important;
  }

  .leftPanel,
  .treePanel,
  .rightPanel,
  .resultPanel {
    font-size: 12px !important;
  }

  #leftRecipePane.on {
    grid-template-rows: 23px 61px !important;
    column-gap: 7px !important;
    row-gap: 4px !important;
    padding: 7px 8px !important;
  }

  #leftRecipePane > .sectionLabel {
    height: 23px !important;
    min-height: 23px !important;
    line-height: 23px !important;
    font-size: 12px !important;
  }

  #leftRecipePane > .selectedRecipe,
  #leftRecipePane > .controlSection {
    height: 61px !important;
    min-height: 61px !important;
  }

  #leftRecipePane .controlTitle,
  .panelHead,
  .resultHeader {
    font-size: 12px !important;
  }

  #leftRecipePane .choiceCard {
    height: 36px !important;
    min-height: 36px !important;
    padding: 4px 6px !important;
  }

  #leftRecipePane .choiceCard b,
  .selectedRecipe b,
  .compMain b,
  .compMeta b,
  .calcStatusCopy b {
    font-size: 12px !important;
  }

  #leftRecipePane .choiceCard small,
  .selectedRecipe small,
  .compMain small,
  .compMeta small,
  .compSource button,
  .rightFilter,
  .treeLegend,
  .calcStatusCopy span,
  .missingItem {
    font-size: 10.5px !important;
  }

  #leftRecipePane .qtyControl {
    height: 30px !important;
  }

  #selectedBody {
    gap: 8px !important;
  }

  #selectedBody > .selectedRecipe,
  #selectedBody > .controlSection {
    min-width: 0 !important;
    padding: 7px 8px !important;
  }

  #selectedBody .controlTitle {
    font-size: 11px !important;
    line-height: 1.15 !important;
    white-space: normal !important;
    overflow-wrap: anywhere;
  }

  #selectedBody .qtyControl {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 30px !important;
    grid-template-columns: 28px minmax(0, 1fr) 28px !important;
    gap: 4px !important;
  }

  #selectedBody .qtyControl button,
  #selectedBody .qtyControl input {
    width: 100% !important;
    min-width: 0 !important;
    height: 30px !important;
    padding: 0 !important;
    font-size: 12px !important;
  }

  #openStockSettings {
    width: 100% !important;
    height: 30px !important;
    min-height: 30px !important;
    margin-top: 4px !important;
    padding: 0 8px !important;
    font-size: 10.5px !important;
  }

  .panelHead {
    height: 39px;
    padding: 0 11px;
  }

  .miniBtn,
  .squareBtn,
  .uiBtn {
    font-size: 11px !important;
  }

  .miniBtn {
    height: 26px;
    padding: 0 8px;
  }

  .squareBtn {
    width: 28px;
    height: 28px;
    font-size: 15px !important;
  }

  .treeViewport {
    height: 416px;
  }

  .treeCanvas {
    min-height: 392px;
    padding: 22px 34px 46px;
  }

  .treeNode {
    width: 94px;
    min-height: 106px;
    padding: 7px 6px 8px;
  }

  .treeNode.root {
    width: 106px;
    min-height: 114px;
  }

  .nodeIcon {
    height: 45px;
  }

  .treeNode .nodeIcon img {
    width: 42px;
    height: 42px;
  }

  .treeNode.root .nodeIcon img {
    width: 50px;
    height: 50px;
  }

  .treeNode b {
    max-width: 84px;
    font-size: 10px !important;
  }

  .treeNode .nodeQty,
  .treeNode .nodePrice,
  .treeNode .nodeStock,
  .treeNode .nodeMode {
    font-size: 8px !important;
  }

  .treeLegend {
    height: 35px;
    gap: 16px;
    padding: 0 11px;
  }

  .rightFilter {
    gap: 7px;
    padding: 8px 10px;
  }

  .rightFilter select {
    width: 224px;
    height: 28px;
  }

  .componentList {
    grid-template-columns: repeat(4, minmax(224px, 1fr));
    gap: 8px;
    max-height: 336px !important;
    padding: 8px 11px 11px !important;
  }

  .compRow {
    grid-template-columns: 37px minmax(0, 1fr) auto !important;
    gap: 6px 8px !important;
    padding: 9px !important;
  }

  .compRow img,
  .compRow > .itemIcon {
    width: 32px;
    height: 32px;
  }

  .resultHeader {
    height: 40px;
    padding: 0 12px;
  }

  .resultBody {
    padding: 10px;
  }

  .resultFields {
    gap: 8px;
  }

  .resultFields label,
  .statBox span {
    font-size: 10px !important;
  }

  .resultValue,
  .resultFields input {
    height: 34px;
    font-size: 12px;
  }

  .resultValue,
  .statBox b {
    font-size: 16px !important;
  }

  .resultStats {
    gap: 8px;
    margin-top: 8px;
  }

  .statBox {
    min-height: 54px;
    padding: 8px;
  }

  .calcStatus {
    min-height: 58px;
    padding: 11px 14px;
  }

  .drawer {
    width: min(608px, 96vw);
    padding: 14px;
  }

  .drawer h2 {
    font-size: 18px;
  }

  .drawerTableHead,
  .settingRow {
    grid-template-columns: minmax(176px, 1fr) 80px 104px 61px;
    gap: 6px;
  }

  .setName img {
    width: 27px;
    height: 27px;
  }

  .settingRow input {
    height: 27px;
  }
}

/* Preserve the existing single-column layouts near the compact breakpoint. */
@media (min-width: 901px) and (max-width: 1500px) {
  .catalog-layout,
  .admin-users-layout {
    grid-template-columns: 1fr;
  }

  .catalog-editor,
  .admin-user-editor {
    position: static;
    max-height: none;
  }
}

@media (min-width: 901px) and (max-width: 1200px) {
  .admin-auth-grid {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 901px) and (max-width: 1120px) {
  .warehouse-layout,
  .inventory-calc-workspace,
  .inventory-calc-upload {
    grid-template-columns: 1fr;
  }

  .warehouse-side,
  .inventory-calc-result {
    position: static;
  }

  .warehouse-inspector {
    min-height: 0;
  }
}

@media (min-width: 901px) and (max-width: 1050px) {
  .trends-lot {
    grid-template-columns: 45px 1fr 1fr 80px 104px;
  }
}

@media (min-width: 901px) and (max-width: 980px) {
  .cms-content .app .modal-bg {
    padding: 16px;
  }

  .cms-content .app .modal {
    width: 96vw;
  }
}

@media (min-width: 901px) and (max-width: 950px) {
  .settings-columns-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 901px) and (max-width: 1300px) {
  .componentList {
    grid-template-columns: repeat(3, minmax(200px, 1fr));
  }
}
