:root {
  --nx-stone-900: #171819;
  --nx-stone-800: #24272a;
  --nx-stone-700: #44484d;
  --nx-stone-500: #8f8d86;
  --nx-stone-300: #d8d2cb;
  --nx-stone-200: #ebe6e1;
  --nx-stone-100: #f7f3ef;
  --nx-accent: #b4232e;
  --nx-accent-soft: rgba(180, 35, 46, 0.12);
  --nx-shadow: 0 22px 45px rgba(27, 31, 35, 0.08);
}

body {
  background:
    radial-gradient(circle at top left, rgba(180, 35, 46, 0.06), transparent 28%),
    linear-gradient(180deg, #fbf8f4 0%, #f3efe9 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(rgba(255, 251, 247, 0.64), rgba(246, 240, 233, 0.58)),
    linear-gradient(115deg, transparent 0 18%, rgba(165, 151, 135, 0.16) 18.6%, transparent 20.2% 41%, rgba(196, 181, 163, 0.14) 41.6%, transparent 43.1% 64%, rgba(140, 130, 118, 0.1) 64.6%, transparent 66.2% 100%),
    linear-gradient(196deg, transparent 0 22%, rgba(155, 143, 129, 0.1) 22.6%, transparent 24.2% 61%, rgba(195, 181, 164, 0.12) 61.6%, transparent 63.1% 100%),
    url("../img/backgrounds/calacatta-goa-quartz.jpg") center top / cover no-repeat;
  filter: saturate(1) contrast(1.14) brightness(1);
}

/* Sidebar - Solid Background matching Cards */
html[data-bs-theme="light"] .layout-menu {
  background: #f8f7fa !important;
  border-inline-end: 1px solid rgba(15, 23, 42, 0.08) !important;
}

html[data-bs-theme="dark"] .layout-menu {
  background: #2f3349 !important;
  border-inline-end: 1px solid rgba(255, 255, 255, 0.05) !important;
}

/* Menu Flicker Prevention */
.layout-menu .menu-inner {
  opacity: 1;
  transition: opacity 0.15s ease-in-out;
}

html:not(.nexo-menu-ready) .layout-menu .menu-inner {
  opacity: 0;
}

.menu-vertical .menu-item.active > .menu-link {
  background: rgba(var(--bs-primary-rgb), 0.12) !important;
  box-shadow: none !important;
  color: rgba(var(--bs-primary-rgb), 0.95) !important;
  font-weight: 600;
}

.menu-vertical .menu-item .menu-link {
  transition: all 0.2s ease;
}

.menu-vertical .menu-item.active .menu-icon {
  color: rgba(var(--bs-primary-rgb), 0.95) !important;
}

html[data-bs-theme="dark"] .menu-vertical .menu-item.active > .menu-link {
  background: rgba(var(--bs-primary-rgb), 0.22) !important;
  color: #f1f5f9 !important;
}

html[data-bs-theme="dark"] .menu-vertical .menu-item.active .menu-icon {
  color: #f1f5f9 !important;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 12% 18%, rgba(255, 255, 255, 0.24), transparent 20%),
    radial-gradient(circle at 84% 22%, rgba(255, 255, 255, 0.18), transparent 16%),
    linear-gradient(125deg, transparent 0 14%, rgba(127, 116, 105, 0.1) 14.4%, transparent 15.4% 31%, rgba(214, 198, 177, 0.08) 31.4%, transparent 32.2% 100%);
  mix-blend-mode: multiply;
  opacity: 0.76;
}

html[data-bs-theme="dark"] body {
  background:
    radial-gradient(circle at top left, rgba(180, 35, 46, 0.08), transparent 26%),
    linear-gradient(180deg, #17191c 0%, #101214 100%);
}

html[data-bs-theme="dark"] body::before {
  background:
    linear-gradient(rgba(8, 10, 14, 0.34), rgba(9, 11, 15, 0.46)),
    radial-gradient(circle at 18% 16%, rgba(255, 255, 255, 0.06), transparent 18%),
    linear-gradient(115deg, transparent 0 14%, rgba(212, 204, 192, 0.05) 14.5%, transparent 16.2% 34%, rgba(154, 146, 138, 0.04) 34.5%, transparent 36.2% 57%, rgba(214, 207, 195, 0.035) 57.5%, transparent 59% 100%),
    linear-gradient(195deg, transparent 0 22%, rgba(129, 123, 118, 0.035) 22.5%, transparent 24.5% 61%, rgba(205, 198, 188, 0.03) 61.5%, transparent 63.5% 100%),
    url("../img/backgrounds/dark-marble-dashboard-slate.jpg") center center / cover no-repeat;
  opacity: 1;
  filter: saturate(0.96) contrast(1.02) brightness(0.82);
}

html[data-bs-theme="dark"] body::after {
  background:
    radial-gradient(circle at 18% 20%, rgba(255, 255, 255, 0.04), transparent 16%),
    linear-gradient(125deg, transparent 0 15%, rgba(211, 201, 188, 0.035) 15.5%, transparent 17.2% 38%, rgba(156, 150, 142, 0.028) 38.5%, transparent 40% 100%);
  opacity: 0.24;
}

html[data-bs-theme="dark"] .nx-hero,
html[data-bs-theme="dark"] .nx-dashboard-card,
html[data-bs-theme="dark"] .nx-command-card,
html[data-bs-theme="dark"] .nx-surface-card,
html[data-bs-theme="dark"] .nx-kpi-card {
  background:
    linear-gradient(180deg, rgba(18, 20, 24, 0.28), rgba(12, 13, 16, 0.18)),
    linear-gradient(145deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.01));
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 20px 46px rgba(0, 0, 0, 0.22);
}

html[data-bs-theme="dark"] .nx-overview-item,
html[data-bs-theme="dark"] .nx-alert-item,
html[data-bs-theme="dark"] .nx-order-item,
html[data-bs-theme="dark"] .nx-order-queue-row,
html[data-bs-theme="dark"] .nx-command-stats>div,
html[data-bs-theme="dark"] .revenue-metric-card,
html[data-bs-theme="dark"] .nx-pipeline-row,
html[data-bs-theme="dark"] .nx-shortcut-card,
html[data-bs-theme="dark"] .nx-checklist-item,
html[data-bs-theme="dark"] .nx-timeline-item,
html[data-bs-theme="dark"] .nx-priority-card,
html[data-bs-theme="dark"] .nx-meta-pill,
html[data-bs-theme="dark"] .nx-customer-item,
html[data-bs-theme="dark"] .nx-empty-state,
html[data-bs-theme="dark"] .nx-revenue-bar-track {
  background: rgba(12, 14, 17, 0.12);
  border-color: rgba(255, 255, 255, 0.06);
}

html[data-bs-theme="dark"] .nx-hero-title,
html[data-bs-theme="dark"] .nx-command-revenue,
html[data-bs-theme="dark"] .revenue-value,
html[data-bs-theme="dark"] .revenue-metric-card span,
html[data-bs-theme="dark"] .nx-chart-heading strong,
html[data-bs-theme="dark"] .nx-section-title,
html[data-bs-theme="dark"] .nx-overview-item strong,
html[data-bs-theme="dark"] .nx-status-value,
html[data-bs-theme="dark"] .nx-kpi-value,
html[data-bs-theme="dark"] .nx-shortcut-card strong,
html[data-bs-theme="dark"] .nx-stone-swatch strong,
html[data-bs-theme="dark"] .nx-priority-card strong,
html[data-bs-theme="dark"] .nx-timeline-item strong,
html[data-bs-theme="dark"] .nx-customer-item strong,
html[data-bs-theme="dark"] .nx-revenue-bar-value {
  color: #f4f4f2;
}

html[data-bs-theme="dark"] .nx-hero-title-accent,
html[data-bs-theme="dark"] .nx-command-copy,
html[data-bs-theme="dark"] .nx-chart-heading small,
html[data-bs-theme="dark"] .nx-command-stats small,
html[data-bs-theme="dark"] .revenue-label,
html[data-bs-theme="dark"] .revenue-metric-card small,
html[data-bs-theme="dark"] .nx-alert-item span,
html[data-bs-theme="dark"] .nx-order-item small,
html[data-bs-theme="dark"] .nx-order-queue-product small,
html[data-bs-theme="dark"] .nx-order-queue-cell,
html[data-bs-theme="dark"] .nx-order-queue-head,
html[data-bs-theme="dark"] .nx-order-queue-date,
html[data-bs-theme="dark"] .nx-pipeline-row small,
html[data-bs-theme="dark"] .nx-hero-text,
html[data-bs-theme="dark"] .nx-overview-item span,
html[data-bs-theme="dark"] .nx-status-label,
html[data-bs-theme="dark"] .nx-kpi-label,
html[data-bs-theme="dark"] .nx-kpi-copy,
html[data-bs-theme="dark"] .nx-shortcut-card small,
html[data-bs-theme="dark"] .nx-checklist-item span,
html[data-bs-theme="dark"] .nx-timeline-item p,
html[data-bs-theme="dark"] .nx-priority-card p,
html[data-bs-theme="dark"] .nx-time,
html[data-bs-theme="dark"] .nx-stone-swatch small,
html[data-bs-theme="dark"] .nx-meta-pill,
html[data-bs-theme="dark"] .nx-customer-item small,
html[data-bs-theme="dark"] .nx-revenue-bar-label,
html[data-bs-theme="dark"] .nx-empty-state {
  color: rgba(244, 244, 242, 0.74);
}

/* Stronger contrast for dark dashboard readability */
html[data-bs-theme="dark"] .nexo-dashboard,
html[data-bs-theme="dark"] .nexo-dashboard .card,
html[data-bs-theme="dark"] .nexo-dashboard .card-title,
html[data-bs-theme="dark"] .nexo-dashboard .card-header,
html[data-bs-theme="dark"] .nexo-dashboard h1,
html[data-bs-theme="dark"] .nexo-dashboard h2,
html[data-bs-theme="dark"] .nexo-dashboard h3,
html[data-bs-theme="dark"] .nexo-dashboard h4,
html[data-bs-theme="dark"] .nexo-dashboard h5,
html[data-bs-theme="dark"] .nexo-dashboard h6,
html[data-bs-theme="dark"] .nexo-dashboard strong {
  color: #f7f9ff !important;
}

html[data-bs-theme="dark"] .nexo-dashboard p,
html[data-bs-theme="dark"] .nexo-dashboard span,
html[data-bs-theme="dark"] .nexo-dashboard small,
html[data-bs-theme="dark"] .nexo-dashboard .text-body-secondary,
html[data-bs-theme="dark"] .nexo-dashboard .text-muted {
  color: rgba(244, 248, 255, 0.92) !important;
}

html[data-bs-theme="dark"] .layout-navbar {
  background-color: rgba(9, 10, 12, 0.08) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.nexo-dashboard {
  position: relative;
  z-index: 1;
  --nx-dash-section-gap: 1.5rem;
  --nx-dash-card-pad-x: clamp(1rem, 1.85vw, 1.65rem);
  --nx-dash-card-pad-y: 1.5rem;
}

.dashboard-top-grid {
  display: grid;
  grid-template-columns: minmax(0, 8fr) minmax(320px, 4fr);
  gap: 1.5rem;
  align-items: stretch;
}

.dashboard-top-stack {
  display: flex;
  flex-direction: column;
  gap: var(--nx-dash-section-gap);
  margin-bottom: var(--nx-dash-section-gap);
}

.dashboard-revenue-compact.revenue-card {
  min-height: 440px;
}

/* Compact revenue card: chart only (KPIs live in dashboard-kpi-row) */
.dashboard-revenue-compact .revenue-card__content--stacked {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.35rem;
  padding: 1rem var(--nx-dash-card-pad-x) 1.25rem;
}

.dashboard-revenue-compact .revenue-chart--full {
  width: 100%;
  min-width: 0;
  flex: 1 1 auto;
  min-height: 16rem;
  display: flex;
  flex-direction: column;
}

.dashboard-revenue-compact .revenue-chart-header {
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
  row-gap: 0.35rem;
}

/* Trend chart: full width, taller bars, horizontal day labels */
.dashboard-revenue-compact .nx-revenue-spark {
  width: 100%;
  min-height: 300px;
  margin-top: 0.25rem;
  margin-bottom: 0.25rem;
  padding-right: 0.25rem;
  padding-left: 0.25rem;
  gap: 4px;
}

.dashboard-revenue-compact .nx-spark-column {
  height: auto;
  min-height: 280px;
  max-width: 100%;
  overflow: visible;
}

.dashboard-revenue-compact .nx-spark-value {
  height: auto;
  min-height: 1.1rem;
  max-height: 2.5rem;
  margin-bottom: 4px;
  font-size: 0.58rem;
  max-width: 100%;
  width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 0 1px;
  box-sizing: border-box;
  writing-mode: horizontal-tb;
  transform: none;
  align-items: center;
  justify-content: center;
}

.dashboard-revenue-compact .nx-spark-column:hover .nx-spark-value {
  transform: none;
}

.dashboard-revenue-compact .nx-spark-track {
  height: 188px;
  flex: 0 0 188px;
  max-width: 20px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(23, 24, 25, 0.055), rgba(23, 24, 25, 0.095));
  box-shadow:
    inset 0 1px 2px rgba(255, 255, 255, 0.42),
    inset 0 -2px 4px rgba(23, 24, 25, 0.07);
  transition: box-shadow 0.2s ease, background 0.2s ease;
}

.dashboard-revenue-compact .nx-spark-track span {
  border-radius: inherit;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.4) 0%, rgba(255, 255, 255, 0) 46%),
    linear-gradient(180deg, #e64a57 0%, #b4232e 44%, #65151c 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    0 2px 6px rgba(90, 18, 26, 0.28);
  transition: height 0.25s ease, filter 0.2s ease;
}

.dashboard-revenue-compact .nx-spark-column:hover .nx-spark-track span {
  filter: brightness(1.07) saturate(1.04);
}

html[data-bs-theme="dark"] .dashboard-revenue-compact .nx-spark-track {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(0, 0, 0, 0.22));
  box-shadow:
    inset 0 1px 1px rgba(255, 255, 255, 0.1),
    inset 0 -2px 6px rgba(0, 0, 0, 0.38);
}

html[data-bs-theme="dark"] .dashboard-revenue-compact .nx-spark-track span {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.32) 0%, rgba(255, 255, 255, 0) 40%),
    linear-gradient(180deg, #ff6b7a 0%, #c42d3c 46%, #6d1520 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.14),
    0 2px 8px rgba(0, 0, 0, 0.42);
}

html[data-bs-theme="dark"] .dashboard-revenue-compact .nx-spark-column:hover .nx-spark-track span {
  filter: brightness(1.09);
}

.dashboard-revenue-compact .nx-spark-column small {
  height: auto;
  min-height: 1.5rem;
  max-height: 2.25rem;
  margin-top: 8px;
  font-size: 0.58rem;
  max-width: 100%;
  width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: block;
  text-align: center;
  line-height: 1.15;
  writing-mode: horizontal-tb;
  transform: none;
}

.dashboard-revenue-compact .nx-spark-track.is-empty {
  background: transparent;
  box-shadow: none;
  border: 0;
}

.dashboard-revenue-compact .nx-spark-track.is-empty span {
  background: transparent;
  box-shadow: none;
}

.dashboard-revenue-compact .nx-spark-column:hover small {
  transform: none;
}

.nx-kpi-value--money {
  font-size: clamp(1.05rem, 2.1vw, 1.35rem);
  line-height: 1.25;
  word-break: break-word;
}

.nx-order-queue-full {
  min-height: 0;
}

.nx-dashboard-card,
.nx-command-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.34), rgba(245, 240, 235, 0.16)),
    linear-gradient(145deg, rgba(248, 244, 239, 0.08), rgba(235, 227, 220, 0.02));
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: var(--nx-shadow);
  backdrop-filter: blur(3px);
}

.nx-command-card::before,
.nx-dashboard-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 12% 0%, rgba(255, 255, 255, 0.5), transparent 24%),
    linear-gradient(135deg, rgba(180, 35, 46, 0.06), transparent 34%);
  opacity: 0.7;
}

.nx-command-card .card-body,
.nx-dashboard-card .card-body {
  position: relative;
  z-index: 1;
}

.revenue-card {
  width: 100%;
  min-height: 360px;
  overflow: visible !important;
}

.revenue-card__content {
  height: 100%;
  display: grid;
  grid-template-columns: minmax(320px, 0.9fr) minmax(420px, 1.4fr);
  gap: clamp(2rem, 3vw, 3rem);
  align-items: center;
  overflow: visible !important;
  padding: 1.25rem 2.5rem 1.25rem 1.5rem;
}

.revenue-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.revenue-card-logo {
  margin-bottom: 1.5rem;
  margin-left: -0.5rem;
  padding-top: 0;
  overflow: visible;
}

.revenue-card-logo img {
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.05));
  max-width: 400px;
  object-fit: contain;
}

.revenue-label {
  display: block;
  color: rgba(36, 39, 42, 0.58);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  line-height: 1.2;
  text-transform: uppercase;
}

.revenue-value {
  margin: 1.05rem 0 1.75rem;
  color: var(--nx-stone-900);
  font-size: clamp(2.55rem, 4.45vw, 4rem);
  font-weight: 800;
  line-height: 0.96;
  letter-spacing: 0;
  white-space: nowrap;
}

.revenue-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem;
  max-width: 28rem;
}

.revenue-metric-card {
  min-height: 82px;
  padding: 1rem 1.1rem;
  border: 1px solid rgba(23, 24, 25, 0.06);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.22);
}

.revenue-metric-card span {
  display: block;
  color: var(--nx-stone-900);
  font-size: 1.45rem;
  font-weight: 800;
  line-height: 1.1;
}

.revenue-metric-card small {
  display: block;
  margin-top: 0.35rem;
  color: rgba(36, 39, 42, 0.62);
  font-weight: 700;
}

.revenue-chart {
  min-width: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.revenue-chart-header {
  margin-bottom: 1.4rem;
}

.revenue-bars {
  width: 100%;
  overflow: hidden;
}

.nx-command-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2rem;
}

.nx-command-grid {
  display: grid;
  grid-template-columns: minmax(430px, 0.95fr) minmax(360px, 1.05fr);
  gap: clamp(1.35rem, 2vw, 2.25rem);
  align-items: stretch;
  min-height: 335px;
}

.nx-command-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.nx-command-revenue {
  margin: 0.75rem 0 1.8rem;
  color: var(--nx-stone-900);
  font-size: clamp(4.35rem, 4.75vw, 5.75rem);
  line-height: 1;
  letter-spacing: 0;
  white-space: nowrap;
}

.nx-command-copy {
  max-width: 32rem;
  color: rgba(36, 39, 42, 0.7);
  font-size: 1rem;
  line-height: 1.65;
}

.nx-command-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
  margin-top: 0;
  max-width: 27.5rem;
}

.nx-command-stats>div {
  min-height: 76px;
  padding: 0.95rem 1rem;
  border: 1px solid rgba(23, 24, 25, 0.06);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.18);
}

.nx-command-stats span {
  display: block;
  color: var(--nx-stone-900);
  font-size: 1.35rem;
  font-weight: 800;
}

.nx-command-stats small {
  display: block;
  margin-top: 0.25rem;
  color: rgba(36, 39, 42, 0.62);
  font-weight: 600;
}

.nx-command-trend {
  min-width: 0;
  align-self: stretch;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.nx-chart-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
}

.nx-chart-heading strong {
  color: var(--nx-stone-900);
  font-size: 0.95rem;
}

.nx-chart-heading small {
  color: rgba(36, 39, 42, 0.58);
  font-weight: 600;
}

.nx-revenue-chart,
.nx-customer-chart {
  display: grid;
  gap: 1rem;
  min-width: 0;
}

.nx-revenue-spark {
  display: grid;
  grid-template-columns: repeat(30, minmax(0, 1fr));
  gap: 2px;
  align-items: flex-start;
  min-height: 340px;
  margin-top: 1rem;
  padding-right: 2.5rem;
  margin-bottom: 2rem;
  overflow: visible;
}

.nx-spark-column {
  display: flex;
  min-width: 0;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  height: 310px;
}

.nx-spark-value {
  height: 50px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  color: var(--nx-accent);
  font-size: 0.6rem;
  font-weight: 800;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  opacity: 0;
  transition: all 0.2s ease;
  margin-bottom: 8px;
}

.nx-spark-value.has-value {
  opacity: 0.85;
}

.nx-spark-column:hover .nx-spark-value {
  opacity: 1;
  transform: rotate(180deg) translateY(2px);
}

.nx-spark-track {
  position: relative;
  height: 178px;
  width: 100%;
  flex: 0 0 178px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(23, 24, 25, 0.06);
}

.nx-spark-track span {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(180, 35, 46, 0.82), rgba(31, 37, 45, 0.92));
}

.nx-spark-track.is-empty {
  background: transparent;
  box-shadow: none;
  border: 0;
}

.nx-spark-track.is-empty span {
  background: transparent;
}

.nx-spark-column small {
  height: 65px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  color: rgba(36, 39, 42, 0.65);
  font-size: 0.6rem;
  font-weight: 700;
  white-space: nowrap;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  opacity: 1;
  transition: all 0.2s ease;
  margin-top: 8px;
  width: 100%;
}

.nx-spark-column:hover small {
  color: var(--nx-accent);
  opacity: 1;
  transform: rotate(180deg) translateY(2px);
}

.nx-alert-list,
.nx-order-queue #dashboardOrderBoardList,
.nx-pipeline-chart {
  display: grid;
  gap: 0.72rem;
}

.nx-alert-item,
.nx-order-item,
.nx-pipeline-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.85rem;
  align-items: center;
  padding: 0.85rem 0.95rem;
  border: 1px solid rgba(23, 24, 25, 0.06);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.16);
  color: inherit;
  text-decoration: none;
}

.nx-alert-item:hover {
  color: inherit;
  border-color: rgba(180, 35, 46, 0.22);
  background: rgba(180, 35, 46, 0.06);
}

.nx-alert-item span,
.nx-order-item small,
.nx-pipeline-row small {
  color: rgba(36, 39, 42, 0.62);
  font-weight: 600;
}

.nx-alert-item strong,
.nx-order-item strong,
.nx-pipeline-row strong {
  color: var(--nx-stone-900);
  font-weight: 800;
}

.nx-alert-item.is-active strong {
  color: var(--nx-accent);
}

.nx-order-item small,
.nx-order-item strong,
.nx-pipeline-row small,
.nx-pipeline-row strong {
  display: block;
}

.nx-order-queue-card-body {
  padding: var(--nx-dash-card-pad-y) var(--nx-dash-card-pad-x);
}

.nx-order-queue-scroll {
  max-height: min(78vh, 48rem);
  min-height: 12rem;
  overflow-x: auto;
  overflow-y: auto;
  padding-right: 0.15rem;
  -webkit-overflow-scrolling: touch;
}

.nx-order-queue-card .nx-chart-heading {
  margin-bottom: 0.75rem;
}

.nx-order-queue-card .nx-chart-heading small {
  font-weight: 600;
}

.nx-order-queue-card .min-h-0 {
  min-height: 0;
}

.nx-order-queue-row--nav {
  cursor: pointer;
}

.nx-order-queue-row--nav:hover {
  border-color: rgba(180, 35, 46, 0.2);
  background: rgba(180, 35, 46, 0.04);
}

.nx-order-queue-row--nav:focus-visible {
  outline: 2px solid rgba(180, 35, 46, 0.55);
  outline-offset: 2px;
}

.nx-order-queue-no-nav {
  cursor: default;
}

.nx-order-queue-no-nav .nx-order-queue-action {
  cursor: pointer;
}

html[data-bs-theme="dark"] .nx-order-queue-row--nav:hover {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
}

.nx-order-queue-table {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  min-width: 0;
  width: 100%;
  align-items: stretch;
}

.nx-order-queue-row {
  display: grid;
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  grid-template-columns:
    minmax(7.5rem, 1.85fr)
    minmax(3rem, 0.75fr)
    minmax(3.25rem, 0.82fr)
    minmax(3rem, 0.75fr)
    minmax(2.5rem, 0.48fr)
    minmax(3.25rem, 0.82fr)
    minmax(3.1rem, 0.8fr)
    minmax(3.25rem, 0.82fr)
    minmax(4.25rem, 0.88fr);
  gap: 0.6rem 0.65rem;
  align-items: center;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(23, 24, 25, 0.06);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.12);
}

.nx-order-queue-product {
  min-width: 0;
}

.nx-order-queue-cell {
  font-size: 0.92rem;
  line-height: 1.35;
  color: rgba(36, 39, 42, 0.78);
}

.nx-order-queue-head {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: rgba(36, 39, 42, 0.55);
  background: rgba(23, 24, 25, 0.04);
}

.nx-order-queue-head-status {
  white-space: nowrap;
  font-size: 0.74rem;
  letter-spacing: 0.05em;
  line-height: 1.15;
  padding-inline: 0.15rem;
}

.nx-order-queue-head-num {
  white-space: nowrap;
}

.nx-order-queue-product small {
  display: block;
  color: rgba(36, 39, 42, 0.55);
  font-weight: 600;
  font-size: 0.8rem;
}

.nx-order-queue-product strong {
  display: block;
  font-weight: 800;
  color: var(--nx-stone-900);
  line-height: 1.3;
  font-size: 1.05rem;
}

.nx-order-queue-date {
  display: block;
  font-size: 0.75rem;
  color: rgba(36, 39, 42, 0.5);
  margin-top: 0.15rem;
}

.nx-order-queue-action {
  width: 2.1rem;
  height: 2.1rem;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.nx-order-queue-arrived-check {
  width: 1.3rem;
  height: 1.3rem;
  margin: 0 auto;
  display: block;
  cursor: pointer;
}

.nx-order-queue-arrived-check:disabled {
  cursor: default;
  opacity: 1;
}

.nx-pipeline-meter {
  grid-column: 1 / -1;
  height: 0.55rem;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(23, 24, 25, 0.06);
}

.nx-pipeline-meter i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(180, 35, 46, 0.8), rgba(31, 37, 45, 0.74));
}

.nx-load-chart {
  display: grid;
  gap: 1rem;
}

.nx-load-bars {
  display: grid;
  grid-template-columns: repeat(14, minmax(0, 1fr));
  gap: 0.45rem;
  align-items: end;
  min-height: 225px;
}

.nx-load-day {
  display: flex;
  flex-direction: column;
  justify-content: end;
  gap: 0.45rem;
  height: 225px;
}

.nx-load-stack {
  display: flex;
  flex-direction: column-reverse;
  min-height: 12px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(23, 24, 25, 0.06);
}

.nx-load-stack span {
  display: block;
  min-height: 3px;
}

.nx-load-stack .measurement,
.nx-load-legend .measurement::before {
  background: #ea5455;
}

.nx-load-stack .fabrication,
.nx-load-legend .fabrication::before {
  background: #7367f0;
}

.nx-load-stack .installation,
.nx-load-legend .installation::before {
  background: #28c76f;
}

.nx-load-day small {
  color: rgba(36, 39, 42, 0.5);
  font-size: 0.6rem;
  font-weight: 700;
  text-align: center;
  transform: rotate(-45deg) translateX(-4px);
  transform-origin: top right;
  white-space: nowrap;
  transition: color 0.2s ease;
}

.nx-load-day:hover small {
  color: var(--nx-accent);
}

.nx-load-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  color: rgba(36, 39, 42, 0.62);
  font-size: 0.72rem;
  font-weight: 700;
}

.nx-load-legend span {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.nx-load-legend span::before {
  content: "";
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
}

.nx-revenue-bars {
  display: grid;
  grid-template-columns: repeat(10, minmax(0, 1fr));
  gap: 0.75rem;
  align-items: end;
  min-height: 260px;
}

.nx-revenue-bar {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.nx-revenue-bar-track {
  height: 220px;
  border-radius: 18px;
  background: rgba(23, 24, 25, 0.06);
  position: relative;
  overflow: hidden;
}

.nx-revenue-bar-fill {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(180, 35, 46, 0.72), rgba(31, 37, 45, 0.95));
}

.nx-revenue-bar-label,
.nx-revenue-bar-value {
  font-size: 0.78rem;
  text-align: center;
  color: var(--nx-stone-700);
}

.nx-revenue-bar-value {
  font-weight: 700;
  color: var(--nx-stone-900);
}

/* Fix for logo and character clipping */
.app-brand {
  padding-top: 10px !important;
  overflow: visible !important;
}

.app-brand-logo {
  overflow: visible !important;
}

.app-brand-logo svg {
  overflow: visible !important;
}

.app-brand-text {
  line-height: 1.2 !important;
  display: inline-block !important;
  padding-bottom: 2px !important;
}

.nx-customer-list {
  display: grid;
  gap: 0.85rem;
}

.nx-customer-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.75rem;
  padding: 0.95rem 1rem;
  border: 1px solid rgba(23, 24, 25, 0.08);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.3);
}

.nx-customer-item strong {
  display: block;
  font-size: 0.98rem;
  color: var(--nx-stone-900);
}

.nx-customer-item small {
  display: block;
  color: var(--nx-stone-700);
}

.nx-customer-meter {
  grid-column: 1 / -1;
  height: 0.5rem;
  border-radius: 999px;
  background: rgba(23, 24, 25, 0.08);
  overflow: hidden;
}

.nx-customer-meter>span {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(180, 35, 46, 0.82), rgba(44, 49, 58, 0.72));
}

.nx-empty-state {
  padding: 1.25rem;
  border: 1px dashed rgba(23, 24, 25, 0.14);
  border-radius: 18px;
  color: var(--nx-stone-700);
  background: rgba(255, 255, 255, 0.24);
}

.nx-hero,
.nx-surface-card,
.nx-kpi-card {
  box-shadow: var(--nx-shadow);
}

.nx-hero {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.34), rgba(244, 238, 232, 0.16)),
    linear-gradient(145deg, rgba(248, 245, 241, 0.1), rgba(235, 229, 223, 0.04));
  backdrop-filter: blur(3px);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.nx-hero::before,
.nx-surface-card::before,
.nx-kpi-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(120deg, transparent 0 12%, rgba(120, 126, 132, 0.08) 12.5%, transparent 13.5% 23%, rgba(138, 140, 144, 0.06) 23.5%, transparent 24.5% 100%),
    radial-gradient(circle at 15% 20%, rgba(255, 255, 255, 0.8), transparent 24%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.32), transparent 80%);
  opacity: 0.42;
}

.nx-hero::after {
  content: "";
  position: absolute;
  top: -6%;
  right: -4%;
  width: min(46%, 420px);
  height: 112%;
  pointer-events: none;
  border-radius: 42% 58% 47% 53% / 58% 45% 55% 42%;
  background:
    radial-gradient(circle at 28% 24%, rgba(255, 255, 255, 0.9), transparent 18%),
    linear-gradient(165deg, rgba(255, 255, 255, 0.5), rgba(205, 197, 189, 0.12)),
    linear-gradient(115deg, transparent 0 16%, rgba(148, 146, 141, 0.16) 16.5%, transparent 18.2% 34%, rgba(185, 181, 173, 0.14) 34.5%, transparent 36% 54%, rgba(120, 123, 129, 0.1) 54.5%, transparent 56% 100%),
    linear-gradient(200deg, transparent 0 24%, rgba(175, 171, 165, 0.14) 24.5%, transparent 26.5% 62%, rgba(124, 128, 133, 0.12) 62.5%, transparent 64% 100%);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.3),
    inset 18px 0 40px rgba(255, 255, 255, 0.28),
    -24px 20px 50px rgba(76, 72, 66, 0.08);
  opacity: 0.95;
  transform: rotate(8deg);
  filter: saturate(0.82);
}

.nx-hero-shell,
.nx-surface-card .card-body,
.nx-kpi-card .card-body {
  position: relative;
  z-index: 1;
}

.nx-hero-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.85fr);
  gap: 1.5rem;
  align-items: stretch;
}

.nx-eyebrow,
.nx-section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  color: var(--nx-accent);
  padding: 0.28rem 0.55rem 0.28rem 0.4rem;
  border: 1px solid rgba(180, 35, 46, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.nx-eyebrow-dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 999px;
  background: var(--nx-accent);
  box-shadow: 0 0 0 8px var(--nx-accent-soft);
}

.nx-hero-logo {
  display: block;
  width: min(100%, 360px);
  margin-top: 1.25rem;
}

.nx-hero-title,
.nx-section-title {
  color: var(--nx-stone-900);
}

.nx-hero-title {
  display: grid;
  gap: 0.35rem;
  margin: 1.5rem 0 0;
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(2.45rem, 3.2vw, 4rem);
  line-height: 0.98;
  letter-spacing: 0;
}

.nx-hero-title-accent {
  font-size: clamp(1.3rem, 2vw, 2.15rem);
  line-height: 1.04;
  color: var(--nx-stone-700);
}

.nx-hero-text {
  width: min(100%, 44rem);
  margin: 1.25rem 0 0;
  color: rgba(36, 39, 42, 0.8);
  font-size: 1rem;
  line-height: 1.75;
}

.nx-hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.nx-meta-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.8rem 1rem;
  border: 1px solid rgba(23, 24, 25, 0.04);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--nx-stone-800);
  font-weight: 600;
}

.nx-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.nx-hero-board {
  position: relative;
  overflow: hidden;
  align-self: stretch;
  padding: 1.35rem;
  border: 1px solid rgba(23, 24, 25, 0.08);
  border-radius: 22px;
  background:
    linear-gradient(160deg, rgba(24, 28, 33, 0.98), rgba(45, 50, 57, 0.94)),
    radial-gradient(circle at top right, rgba(180, 35, 46, 0.18), transparent 28%);
  color: #fff;
}

.nx-board-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.nx-board-item {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.nx-board-item small,
.nx-board-note,
.nx-mini-note,
.nx-kpi-copy,
.nx-timeline-item p,
.nx-priority-card p,
.nx-shortcut-card small,
.nx-checklist-item span {
  color: rgba(255, 255, 255, 0.72);
}

.nx-board-item strong,
.nx-board-note {
  display: block;
}

.nx-board-item strong {
  color: #fff;
}

.nx-board-item span {
  flex-shrink: 0;
  color: rgba(255, 255, 255, 0.82);
  font-weight: 700;
}

.nx-board-note {
  margin-top: 1rem;
  padding: 0.95rem 1rem;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.08);
  line-height: 1.6;
}

.nx-surface-card,
.nx-kpi-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.24), rgba(245, 240, 235, 0.1)),
    linear-gradient(145deg, rgba(248, 244, 239, 0.06), rgba(235, 227, 220, 0.01));
  backdrop-filter: blur(3px);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.nx-overview-list {
  display: grid;
  gap: 0.85rem;
}

.nx-overview-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.1rem;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(23, 24, 25, 0.02);
}

.nx-overview-link {
  color: inherit;
  text-decoration: none;
  transition:
    transform 0.2s ease,
    border-color 0.2s ease,
    background 0.2s ease;
}

.nx-overview-link:hover {
  color: inherit;
  text-decoration: none;
  transform: translateY(-1px);
  border-color: rgba(234, 84, 85, 0.26);
  background: rgba(234, 84, 85, 0.06);
}

.nx-overview-link:hover strong {
  color: #ea5455;
}

.nx-overview-item span,
.nx-status-label,
.nx-kpi-label,
.nx-stone-swatch small,
.nx-time {
  color: rgba(36, 39, 42, 0.63);
}

.nx-overview-item strong,
.nx-status-value,
.nx-kpi-value,
.nx-shortcut-card strong,
.nx-stone-swatch strong,
.nx-priority-card strong,
.nx-timeline-item strong {
  color: var(--nx-stone-900);
}

.nx-status-block {
  margin-top: 1.25rem;
}

.nx-status-track {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.55rem;
  font-weight: 700;
}

.progress {
  height: 0.55rem;
  border-radius: 999px;
  background: rgba(23, 24, 25, 0.04);
}

.nx-mini-note {
  margin-top: 1.25rem;
  padding: 1rem 1.1rem;
  border-radius: 16px;
  background: linear-gradient(145deg, rgba(180, 35, 46, 0.28), rgba(130, 24, 32, 0.32));
}

.nx-kpi-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: 14px;
}

.nx-kpi-label {
  display: block;
  margin-top: 1.15rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.nx-kpi-value {
  margin-top: 0.5rem;
  margin-bottom: 0.6rem;
  font-size: 2.15rem;
}

.nx-kpi-copy {
  margin-bottom: 0;
  color: rgba(36, 39, 42, 0.68);
  line-height: 1.7;
}

.nx-shortcut-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.nx-shortcut-card {
  position: relative;
  display: block;
  padding: 1.15rem;
  border: 1px solid rgba(23, 24, 25, 0.03);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.025);
  color: inherit;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.nx-shortcut-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 28px rgba(25, 29, 33, 0.08);
  border-color: rgba(180, 35, 46, 0.18);
  background: rgba(255, 255, 255, 0.08);
}

.nx-shortcut-icon {
  display: inline-flex;
  width: 2.85rem;
  height: 2.85rem;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.95rem;
  border-radius: 14px;
  background: var(--nx-accent-soft);
  color: var(--nx-accent);
  font-size: 1.2rem;
}

.nx-shortcut-card strong,
.nx-shortcut-card small {
  display: block;
}

.nx-shortcut-card small {
  margin-top: 0.35rem;
  color: rgba(36, 39, 42, 0.68);
  line-height: 1.55;
}

.nx-stone-swatch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1rem;
  padding: 1rem 1rem 1rem 1.15rem;
  border-radius: 18px;
  border: 1px solid rgba(23, 24, 25, 0.04);
  backdrop-filter: blur(3px);
}

.nx-stone-swatch span {
  display: inline-flex;
  align-items: center;
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: var(--nx-stone-800);
  font-size: 0.78rem;
  font-weight: 700;
}

.swatch-ice {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(230, 232, 235, 0.95)),
    linear-gradient(120deg, rgba(135, 142, 154, 0.13), transparent 38%);
}

.swatch-sand {
  background:
    linear-gradient(135deg, rgba(250, 245, 236, 0.98), rgba(230, 214, 187, 0.85)),
    linear-gradient(120deg, rgba(177, 144, 96, 0.12), transparent 35%);
}

.swatch-night {
  background:
    linear-gradient(135deg, rgba(51, 56, 61, 0.98), rgba(24, 27, 32, 0.96)),
    linear-gradient(120deg, rgba(255, 255, 255, 0.06), transparent 42%);
}

.swatch-night strong,
.swatch-night small {
  color: rgba(255, 255, 255, 0.9);
}

.nx-checklist {
  display: grid;
  gap: 0.8rem;
  margin-top: 1.2rem;
}

.nx-checklist-item {
  display: flex;
  gap: 0.8rem;
  align-items: flex-start;
  padding: 0.9rem 1rem;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.015);
}

.nx-timeline {
  display: grid;
  gap: 1rem;
}

.nx-timeline-item {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 1rem;
  padding: 1rem 1.1rem;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(23, 24, 25, 0.02);
}

.nx-time {
  font-weight: 700;
}

.nx-timeline-item p,
.nx-priority-card p {
  margin: 0.35rem 0 0;
  color: rgba(36, 39, 42, 0.7);
  line-height: 1.7;
}

.nx-priority-card {
  margin-top: 1rem;
  padding: 1.1rem 1.15rem;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(23, 24, 25, 0.02);
}

.layout-navbar {
  backdrop-filter: blur(3px);
  background-color: rgba(255, 251, 247, 0.08) !important;
}

@media (max-width: 1399.98px) {
  .nx-hero-shell {
    grid-template-columns: 1fr;
  }

  .nx-hero::after {
    width: min(54%, 360px);
    height: 58%;
    top: auto;
    bottom: -8%;
    right: -8%;
  }
}

@media (max-width: 1199.98px) {
  .dashboard-top-grid {
    grid-template-columns: 1fr;
  }

  .revenue-card__content {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }

  .dashboard-revenue-compact .revenue-card__content--stacked {
    gap: 1rem;
  }

  .revenue-value {
    font-size: clamp(3.35rem, 8vw, 5rem);
    white-space: normal;
  }

  .nx-command-grid {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .nx-command-revenue {
    font-size: clamp(3rem, 8vw, 4.8rem);
  }

  .nx-shortcut-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .nx-revenue-bars {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
}

@media (max-width: 767.98px) {
  .revenue-card {
    min-height: 0;
  }

  .revenue-card__content {
    padding: 1.375rem;
  }

  .revenue-value {
    font-size: clamp(2.8rem, 13vw, 3.9rem);
  }

  .revenue-metrics {
    grid-template-columns: 1fr;
  }

  .revenue-chart-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.35rem;
  }

  .nx-command-revenue {
    font-size: clamp(2.65rem, 13vw, 3.6rem);
  }

  .nx-command-stats {
    grid-template-columns: 1fr;
  }

  .nx-hero,
  .nx-surface-card,
  .nx-kpi-card {
    border-radius: 22px;
  }

  .nx-hero-title {
    font-size: 2.35rem;
  }

  .nx-hero::after {
    width: 70%;
    height: 38%;
    right: -18%;
    bottom: -10%;
    transform: rotate(12deg);
  }

  .nx-shortcut-grid {
    grid-template-columns: 1fr;
  }

  .nx-timeline-item {
    grid-template-columns: 1fr;
  }

  .nx-hero-actions {
    flex-direction: column;
  }

  .nx-hero-actions .btn {
    width: 100%;
  }

  .nx-revenue-bars {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.55rem;
  }

  .nx-revenue-bar-track {
    height: 180px;
  }
}

/* Trend layout: chart + full-width daily table (fills card horizontally) */
.nx-revenue-chart.nx-revenue-chart--trend {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
}

.dashboard-revenue-compact .revenue-chart--full .nx-revenue-chart--trend {
  flex: 1 1 auto;
}

.nx-revenue-trend--wide {
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
  display: flex;
  flex-direction: column;
}

.nx-revenue-trend--wide .nx-revenue-trend-chart {
  flex: 1 1 auto;
  min-height: 12.5rem;
}

.nx-visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.nx-revenue-day-table-wrap {
  width: 100%;
  min-width: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin-top: 0.25rem;
  flex-shrink: 0;
}

.nx-revenue-day-table {
  width: 100%;
  min-width: max(100%, 52rem);
  table-layout: fixed;
  border-collapse: collapse;
  font-size: 0.62rem;
  line-height: 1.25;
}

.nx-revenue-day-th,
.nx-revenue-day-td {
  padding: 0.4rem 0.15rem;
  text-align: center;
  vertical-align: middle;
  border: 1px solid rgba(23, 24, 25, 0.08);
  box-sizing: border-box;
}

.nx-revenue-day-th {
  font-weight: 700;
  color: var(--bs-secondary-color);
  background: rgba(23, 24, 25, 0.03);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nx-revenue-day-td {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  color: var(--bs-heading-color);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

html[data-bs-theme='dark'] .nx-revenue-day-th,
html[data-bs-theme='dark'] .nx-revenue-day-td {
  border-color: rgba(255, 255, 255, 0.1);
}

html[data-bs-theme='dark'] .nx-revenue-day-th {
  background: rgba(255, 255, 255, 0.04);
}

/* Revenue trend: area + line (sqrt-scaled in JS) — readable with outlier days */
.nx-revenue-trend {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  width: 100%;
  min-width: 0;
}

.nx-revenue-trend--flat .nx-revenue-trend-chart--muted {
  min-height: 6rem;
  border-radius: 1rem;
  background: linear-gradient(180deg, rgba(23, 24, 25, 0.04), rgba(23, 24, 25, 0.02));
  border: 1px dashed rgba(23, 24, 25, 0.1);
}

.nx-revenue-trend-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  align-items: baseline;
  font-size: 0.78rem;
  color: var(--bs-secondary-color);
}

.nx-revenue-stat strong {
  color: var(--bs-heading-color);
  font-weight: 700;
}

.nx-revenue-trend-chart {
  width: 100%;
  min-height: 11rem;
  flex: 1 1 auto;
  border-radius: 1rem;
  padding: 0.35rem 0.15rem 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.55), rgba(248, 244, 239, 0.25));
  border: 1px solid rgba(23, 24, 25, 0.06);
}

.nx-revenue-plot {
  width: 100%;
  height: auto;
  min-height: 11rem;
  max-height: min(32vh, 280px);
  display: block;
}

.nx-revenue-baseline {
  stroke: rgba(23, 24, 25, 0.12);
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}

.nx-revenue-line {
  stroke: #b4232e;
  stroke-width: 2.25;
  stroke-linejoin: round;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
}

.nx-revenue-dot {
  fill: #e64a57;
  stroke: #fff;
  stroke-width: 1.5;
  cursor: default;
  vector-effect: non-scaling-stroke;
  transition: transform 0.15s ease, filter 0.15s ease;
}

.nx-revenue-dot:hover {
  filter: drop-shadow(0 2px 6px rgba(90, 18, 26, 0.45));
  opacity: 0.95;
}

.nx-revenue-xlabel {
  fill: var(--bs-secondary-color);
  font-size: 10px;
  font-weight: 600;
}

.nx-revenue-trend-hint {
  line-height: 1.35;
  flex-shrink: 0;
}

html[data-bs-theme='dark'] .nx-revenue-trend-chart {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(0, 0, 0, 0.12));
  border-color: rgba(255, 255, 255, 0.08);
}

html[data-bs-theme='dark'] .nx-revenue-baseline {
  stroke: rgba(255, 255, 255, 0.14);
}

html[data-bs-theme='dark'] .nx-revenue-line {
  stroke: #ff8a96;
}

html[data-bs-theme='dark'] .nx-revenue-dot {
  fill: #ff6b7a;
  stroke: rgba(15, 18, 24, 0.9);
}

html[data-bs-theme='dark'] .nx-revenue-xlabel {
  fill: rgba(226, 232, 240, 0.72);
}

html[data-bs-theme='dark'] .nx-revenue-trend--flat .nx-revenue-trend-chart--muted {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(0, 0, 0, 0.15));
  border-color: rgba(255, 255, 255, 0.12);
}