* { box-sizing: border-box; }
body {
  font-family: 'Hiragino Sans', 'Meiryo', sans-serif;
  margin: 0;
  padding: 16px;
  background-color: #f4f4f9;
  color: #333;
}
.container {
  max-width: 480px;
  margin: 0 auto;
  background: white;
  padding: 24px 18px;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
}
h1 {
  background-color: #0056b3;
  color: white;
  padding: 14px;
  border-radius: 8px;
  text-align: center;
  font-size: 1.2em;
  margin-top: 0;
}
h2 {
  color: #0056b3;
  border-bottom: 2px solid #0056b3;
  padding-bottom: 6px;
  font-size: 1.05em;
}
.big-input {
  width: 100%;
  padding: 18px;
  font-size: 22px;
  text-align: center;
  border: 2px solid #ccc;
  border-radius: 8px;
  margin-bottom: 14px;
  letter-spacing: 4px;
}
.btn {
  display: block;
  width: 100%;
  padding: 18px;
  margin-bottom: 14px;
  font-size: 18px;
  font-weight: bold;
  color: white;
  background-color: #007BFF;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 4px 0 #0056b3;
}
.btn:active { transform: translateY(3px); box-shadow: none; }
.btn-green { background-color: #28a745; box-shadow: 0 4px 0 #1e7e34; }
.btn-red { background-color: #dc3545; box-shadow: 0 4px 0 #a71d2a; }
.btn-gray { background-color: #6c757d; box-shadow: 0 4px 0 #4b5157; }
.btn-outline {
  background: white; color: #0056b3; border: 2px solid #0056b3;
  box-shadow: none;
}
.nav-links { text-align: center; margin-top: 20px; font-size: 14px; }
.nav-links a { color: #0056b3; margin: 0 8px; text-decoration: none; }

.item-card {
  border: 2px solid #ddd;
  border-radius: 8px;
  padding: 14px;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: all 0.15s;
}
.item-card.selected {
  border-color: #28a745;
  background-color: #eaf7ec;
}
.item-card .check {
  width: 26px; height: 26px; border-radius: 50%;
  border: 2px solid #ccc; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-weight: bold; color: white;
}
.item-card.selected .check { background-color: #28a745; border-color: #28a745; }
.item-card .info { flex: 1; font-size: 14px; line-height: 1.5; }
.item-card .info b { font-size: 16px; }

.reason-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.reason-btn {
  padding: 16px 6px; text-align: center; border-radius: 8px;
  border: 2px solid #007BFF; background: white; color: #007BFF;
  font-weight: bold; cursor: pointer; font-size: 15px;
}
.reason-btn.selected { background: #007BFF; color: white; }

.msg { padding: 12px; border-radius: 6px; margin-bottom: 14px; font-size: 14px; }
.msg-error { background: #f8d7da; color: #721c24; border: 1px solid #f5c6cb; }
.msg-info { background: #d1ecf1; color: #0c5460; border: 1px solid #bee5eb; }
.msg-warn { background: #fff3cd; color: #856404; border: 1px solid #ffeeba; }

.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; color: #555; margin-bottom: 4px; font-weight: bold; }
.field input, .field select, .field textarea {
  width: 100%; padding: 12px; font-size: 16px; border: 1px solid #ccc; border-radius: 6px;
}

table.records-table { width: 100%; border-collapse: collapse; font-size: 13px; }
table.records-table th, table.records-table td { border: 1px solid #ddd; padding: 6px; text-align: left; }
table.records-table th { background: #f0f0f0; }

.loading { text-align: center; padding: 30px; color: #888; }