.scratchpad {
  margin: 18px auto 22px;
  overflow: hidden;
  border: 2px solid #ddd6fe;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 7px 22px rgba(76, 29, 149, 0.08);
}

.scratch-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  padding: 13px 15px;
  background: #f5f3ff;
}

.scratch-head b,
.scratch-head small {
  display: block;
}

.scratch-head small {
  margin-top: 3px;
  color: #667085;
}

.scratch-tools {
  display: flex;
  gap: 6px;
}

.scratch-tool,
.scratch-clear {
  min-height: 38px;
  padding: 7px 11px;
  border: 1px solid #d8d1e8;
  border-radius: 10px;
  background: #fff;
  color: #4c1d95;
  font-weight: 800;
}

.scratch-tool.active {
  border-color: #6d28d9;
  background: #6d28d9;
  color: #fff;
}

.scratch-clear {
  color: #b91c1c;
}

.scratchpad canvas {
  display: block;
  width: 100%;
  height: 280px;
  background-color: #fff;
  background-image: linear-gradient(#ede9fe 1px, transparent 1px), linear-gradient(90deg, #ede9fe 1px, transparent 1px);
  background-size: 24px 24px;
  cursor: crosshair;
  touch-action: none;
}

.answer-card.compact-answer {
  padding: 17px 22px;
}

.answer-card.compact-answer label {
  margin-bottom: 4px;
}

.answer-card.compact-answer .currency-input {
  margin: 6px 0 10px;
}

.answer-card.compact-answer .currency-input span {
  padding-top: 8px;
  padding-bottom: 8px;
  font-size: 1.15rem;
}

.answer-card.compact-answer .currency-input input {
  padding-top: 7px;
  padding-bottom: 7px;
  font-size: 1.4rem;
}

.answer-card.compact-answer > .btn {
  min-height: 44px;
  padding-top: 9px;
  padding-bottom: 9px;
}

@media (max-width: 600px) {
  .scratch-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .scratch-tools {
    width: 100%;
  }

  .scratch-tool,
  .scratch-clear {
    flex: 1;
    padding: 7px 5px;
  }

  .scratchpad canvas {
    height: 230px;
  }
}
