/* ===== 共通 ===== */
form {
  margin-top: 20px;
}

button {
  background: #2563eb;
  color: white;
  padding: 8px 16px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  cursor: pointer;
}
button:hover {
  background: #1d4ed8;
}

/* ===== Q6以降: 機種ごとのカード ===== */
.machine-card {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  border: 1px solid #ddd;
  border-radius: 10px;
  padding: 12px 16px;
  margin-bottom: 12px;
}
.machine-info {
  max-width: 300px;
}
.machine-info strong {
  font-size: 1.1em;
}
.machine-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-start;
}
.machine-actions label {
  font-weight: 500;
}
.machine-actions input[type=number] {
  width: 100px;
  padding: 6px 8px;
  border: 1px solid #ccc;
  border-radius: 6px;
}
.machine-actions .inputs {
  display: flex;
  gap: 8px;
}

/* ラジオを非表示 */
.option-item input[type="radio"] {
  display: none;
}

/* Q1〜Q5 ボタン用ラッパー */
.option-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 15px 0;
  justify-content: flex-start;
}

/* 各ボタン */
.option-list .btn {
  width: 180px;
  height: 75px;
  display: flex;
  align-items: center;  /* 縦中央 */
  justify-content: center; /* 横中央 */
  text-align: center;
  white-space: normal;  /* 折り返し許可 */
  word-break: keep-all;
}

/* 800px 以下では縦並び */
@media (max-width: 800px) {
  .option-list {
    flex-direction: column;
    align-items: stretch;
    justify-content: center;
  }
  .option-list .btn {
    width: 80%;
    height: 40px;     /* 高さ統一 */
    max-width: none;
  }
}

/* ラベル自体をボタン化 */
.option-item {
  flex: 1 1 120px;
  max-width: 200px;
  padding: 10px 15px;
  border: 2px solid #007bff;
  border-radius: 6px;
  color: #007bff;
  font-size: 15px;
  text-align: center;
  background: #fff;
  cursor: pointer;
  transition: all 0.2s;
}

/* hover */
.option-item:hover {
  background: #f0f8ff;
}

/* 選択状態 */
.option-item input[type="radio"]:checked + span {
  background: #007bff;
  color: #fff;
  border-color: #007bff;
}

.purchase-cell {
  padding: 0; /* セル内の余白をなくす */
}

.purchase-label {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  margin: 0;
  padding: 0.5rem; /* 少し余白 */
}
