.dboard-wrap,
.delivery-form-page {
  min-height: 100%;
  padding: clamp(14px, 2vw, 24px);
  background: #eef5ff;
  color: #0f172a;
}

.dboard-topbar,
.delivery-form-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.dboard-title,
.delivery-form-title {
  margin: 0;
  color: #132144;
  font-size: 1.8rem;
  font-weight: 900;
  line-height: 1.2;
}

.dboard-subtitle,
.delivery-form-subtitle {
  margin-top: 6px;
  color: #475569;
  font-size: .95rem;
  line-height: 1.6;
}

.dboard-actions,
.delivery-form-actions,
.delivery-form-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.dboard-actions .btn,
.delivery-form-actions .btn {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 8px;
  font-weight: 800;
  white-space: nowrap;
}

.delivery-form-icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  flex: 0 0 46px;
  border-radius: 8px;
  background: #0f766e;
  color: #fff;
  font-size: 20px;
}

.dboard-kpis {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin-bottom: 16px;
}

.kpi-card {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border: 1px solid rgba(148, 163, 184, .18);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 14px 32px rgba(15, 23, 42, .05);
}

.kpi-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  flex: 0 0 44px;
  border-radius: 8px;
  font-size: 20px;
}

.bg-soft-success { background: #dcfce7; color: #166534; }
.bg-soft-primary { background: #dbeafe; color: #1d4ed8; }
.bg-soft-dark { background: #e2e8f0; color: #172033; }
.bg-soft-warning { background: #fef3c7; color: #92400e; }

.kpi-title,
.kpi-meta {
  color: #64748b;
  font-size: .82rem;
  font-weight: 800;
}

.kpi-value {
  margin-top: 4px;
  color: #0f172a;
  font-size: 1.65rem;
  font-weight: 900;
  line-height: 1.1;
}

.dboard-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.dboard-card,
.delivery-card {
  min-width: 0;
  border: 1px solid rgba(148, 163, 184, .16);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 16px 36px rgba(15, 23, 42, .05);
  overflow: hidden;
}

.delivery-card {
  margin-bottom: 14px;
}

.dboard-card-wide {
  grid-column: 1 / -1;
}

.dboard-card-header,
.delivery-card-header {
  min-height: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 16px;
  border-bottom: 1px solid rgba(148, 163, 184, .14);
  background: #fbfdff;
  color: #0f172a;
  font-weight: 900;
}

.dboard-card-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.dboard-card-title i,
.delivery-card-header i {
  color: #0f766e;
}

.dboard-card-meta,
.delivery-card-meta {
  color: #64748b;
  font-size: .82rem;
  font-weight: 800;
}

.dboard-card-body,
.delivery-card-body {
  padding: 16px;
}

.mini-chart {
  height: 128px;
  display: flex;
  align-items: flex-end;
  gap: 7px;
  padding: 4px 2px;
}

.mini-bar {
  min-width: 12px;
  flex: 1;
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  background: #e2e8f0;
}

.mini-bar > span {
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  border-radius: 8px;
  background: #0f766e;
}

.dboard-chart-range {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 10px;
  color: #64748b;
  font-size: .82rem;
  font-weight: 800;
}

.dboard-table,
.delivery-lines-table {
  min-width: 760px;
}

.dboard-table thead th,
.delivery-lines-table thead th {
  background: #f3f7fb;
  color: #475569;
  border-bottom: 1px solid #dbe3ee;
  font-size: .82rem;
  font-weight: 900;
  white-space: nowrap;
}

.dboard-table tbody td,
.delivery-lines-table tbody td {
  color: #0f172a;
  border-color: #edf2f7;
  vertical-align: middle;
}

.badge-soft {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 9px;
  border-radius: 999px;
  background: #eef6f4;
  color: #0f766e;
  font-size: .8rem;
  font-weight: 900;
}

.delivery-form-page .form-label {
  color: #334155;
  font-size: .82rem;
  font-weight: 800;
  margin-bottom: 5px;
}

.delivery-form-page .form-control,
.delivery-form-page .form-select {
  min-height: 40px;
  border: 1px solid #dbe3ee;
  border-radius: 8px;
  box-shadow: none;
}

.delivery-form-page .form-control:focus,
.delivery-form-page .form-select:focus {
  border-color: #0f766e;
}

@media (max-width: 1100px) {
  .dboard-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .dboard-topbar,
  .delivery-form-header {
    flex-direction: column;
  }

  .dboard-actions,
  .delivery-form-actions {
    width: 100%;
    align-items: stretch;
  }

  .dboard-actions .btn,
  .delivery-form-actions .btn {
    flex: 1 1 160px;
  }

  .dboard-title,
  .delivery-form-title {
    font-size: 1.45rem;
  }
}
