/* Aryam Bakery dashboard visual refresh — Melostic brand palette v1 */
#bakeryDashboard {
  --dash-navy: #172b5f;
  --dash-blue: #315fc8;
  --dash-gold: #e4a126;
  --dash-teal: #15998b;
  --dash-coral: #df6470;
  --dash-violet: #7559c9;
  position: relative;
  padding: clamp(14px, 1.6vw, 24px);
  border: 1px solid rgba(23, 43, 95, 0.08);
  border-radius: 28px;
  overflow: hidden;
  background:
    radial-gradient(circle at 96% 0%, rgba(228, 161, 38, 0.16), transparent 24%),
    radial-gradient(circle at 0% 100%, rgba(21, 153, 139, 0.12), transparent 26%),
    linear-gradient(145deg, #f8fbff 0%, #f5f7fc 55%, #fffaf0 100%);
  box-shadow: 0 18px 45px rgba(19, 39, 82, 0.09);
}

#bakeryDashboard::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.22;
  background-image: radial-gradient(circle, rgba(49, 95, 200, 0.18) 1px, transparent 1px);
  background-size: 24px 24px;
  -webkit-mask-image: linear-gradient(to bottom, #000, transparent 42%);
  mask-image: linear-gradient(to bottom, #000, transparent 42%);
}

#bakeryDashboard > * {
  position: relative;
  z-index: 1;
}

#bakeryDashboard .kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 22px;
}

#bakeryDashboard .kpi {
  --card-accent: var(--dash-blue);
  position: relative;
  min-width: 0;
  min-height: 145px;
  padding: 24px;
  overflow: hidden;
  border: 1px solid rgba(23, 43, 95, 0.09);
  border-radius: 22px;
  background: linear-gradient(145deg, #fff, #edf3ff);
  box-shadow: 0 12px 30px rgba(20, 40, 86, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

#bakeryDashboard .kpi::before {
  content: "";
  position: absolute;
  top: 0;
  left: 22px;
  width: 66px;
  height: 4px;
  border-radius: 0 0 8px 8px;
  background: var(--card-accent);
}

#bakeryDashboard .kpi::after {
  content: "";
  position: absolute;
  right: -38px;
  bottom: -52px;
  width: 105px;
  height: 105px;
  pointer-events: none;
  border-radius: 50%;
  background: var(--card-accent);
  box-shadow: -38px -26px 0 -18px var(--card-accent);
  opacity: 0.08;
}

#bakeryDashboard .kpi:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 36px rgba(20, 40, 86, 0.13);
}

#bakeryDashboard .kpi span {
  color: #65718a;
  font-size: 0.78rem;
  letter-spacing: 0.045em;
}

#bakeryDashboard .kpi strong {
  position: relative;
  z-index: 1;
  color: #12234d;
  font-size: clamp(1.55rem, 2.1vw, 2.15rem);
  line-height: 1.12;
}

#bakeryDashboard .kpi:nth-child(1) {
  --card-accent: #315fc8;
  background: linear-gradient(145deg, #fff, #edf3ff);
}

#bakeryDashboard .kpi:nth-child(2) {
  --card-accent: #1f956b;
  background: linear-gradient(145deg, #fff, #edf9f4);
}

#bakeryDashboard .kpi:nth-child(3) {
  --card-accent: #15998b;
  background: linear-gradient(145deg, #fff, #eaf9f8);
}

#bakeryDashboard .kpi:nth-child(4) {
  --card-accent: #7559c9;
  background: linear-gradient(145deg, #fff, #f2efff);
}

#bakeryDashboard .kpi:nth-child(5) {
  --card-accent: #d85b68;
  background: linear-gradient(145deg, #fff, #fff0f2);
}

#bakeryDashboard .kpi:nth-child(6) {
  --card-accent: #df971a;
  background: linear-gradient(145deg, #fff, #fff7e8);
}

#bakeryDashboard .kpi:nth-child(7) {
  --card-accent: #2587a8;
  background: linear-gradient(145deg, #fff, #ecf9fd);
}

#bakeryDashboard .kpi:nth-child(8) {
  --card-accent: #f2b33f;
  color: #fff;
  border-color: transparent;
  background: linear-gradient(135deg, #152553, #294b97);
  box-shadow: 0 16px 34px rgba(21, 37, 83, 0.25);
}

#bakeryDashboard .kpi:nth-child(8) span,
#bakeryDashboard .kpi:nth-child(8) strong {
  color: #fff;
}

#bakeryDashboard .report-card {
  border: 1px solid rgba(23, 43, 95, 0.09);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 30px rgba(20, 40, 86, 0.08);
  backdrop-filter: blur(8px);
}

#bakeryDashboard .report-card h3 {
  color: #152553;
}

#bakeryDashboard .bakery-dashboard-reconciliation {
  color: #fff;
  border-color: transparent;
  background: linear-gradient(135deg, #152553, #1c376f);
  box-shadow: 0 18px 36px rgba(21, 37, 83, 0.2);
}

#bakeryDashboard .bakery-dashboard-reconciliation .dashboard-reconciliation-title h2 {
  color: #ffffff;
}

#bakeryDashboard .bakery-dashboard-reconciliation .dashboard-reconciliation-title .eyebrow {
  color: #c9d8ff;
}

#bakeryDashboard .bakery-dashboard-reconciliation .dashboard-reconciliation-equation span {
  color: #102349;
  background: #ffffff;
}

#bakeryDashboard .bakery-dashboard-reconciliation .dashboard-reconciliation-equation small {
  color: #53627a;
}

#bakeryDashboard .bakery-dashboard-reconciliation .dashboard-reconciliation-equation strong {
  color: #0b2348;
  -webkit-text-fill-color: #0b2348;
}

#bakeryDashboard .bakery-dashboard-reconciliation .dashboard-reconciliation-equation span.result {
  color: #573700;
  background: #fff8e8;
}

#bakeryDashboard .bakery-dashboard-reconciliation .dashboard-reconciliation-equation span.result strong {
  color: #573700;
  -webkit-text-fill-color: #573700;
}

#bakeryDashboard .bakery-dashboard-reconciliation .dashboard-reconciliation-equation b {
  color: #d8e4ff;
}

#bakeryDashboard .bakery-dashboard-reconciliation .dashboard-reconciliation-note,
#bakeryDashboard .bakery-dashboard-reconciliation .dashboard-reconciliation-note strong {
  color: #263a5b;
  -webkit-text-fill-color: #263a5b;
}

#bakeryDashboard .compact-report-grid {
  gap: 18px;
}

#bakeryDashboard .progress-track {
  height: 12px;
  border-radius: 999px;
  background: #e8edf6;
}

#bakeryDashboard .progress-fill {
  border-radius: 999px;
}

@media (max-width: 1100px) {
  #bakeryDashboard .kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  #bakeryDashboard {
    padding: 10px;
    border-radius: 20px;
  }

  #bakeryDashboard .kpi-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  #bakeryDashboard .kpi {
    min-height: 122px;
    padding: 20px;
  }
}
