* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f0f4f8;
  color: #1e293b;
  min-height: 100vh;
}

.container {
  max-width: 640px;
  margin: 0 auto;
  padding: 16px;
}

h1 {
  font-size: 1.4rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 20px;
  color: #1e293b;
}

h2 {
  font-size: 1rem;
  font-weight: 600;
  color: #475569;
  margin-bottom: 12px;
}

/* フォームセクション */
.form-section {
  background: #fff;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 16px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
  margin-bottom: 12px;
}

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

.form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

label {
  font-size: 0.8rem;
  font-weight: 600;
  color: #64748b;
}

input[type="text"],
input[type="number"] {
  width: 100%;
  padding: 8px 10px;
  border: 1.5px solid #e2e8f0;
  border-radius: 8px;
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.15s;
}

input[type="text"]:focus,
input[type="number"]:focus {
  border-color: #2563eb;
}

/* ボタン */
.btn {
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 10px 20px;
  transition: opacity 0.15s;
}

.btn:hover {
  opacity: 0.85;
}

.btn-primary {
  background: #2563eb;
  color: #fff;
  width: 100%;
}

.btn-danger {
  background: #ef4444;
  color: #fff;
}

.btn-sm {
  padding: 5px 12px;
  font-size: 0.82rem;
}

/* 合計セクション */
.total-section {
  background: #2563eb;
  color: #fff;
  border-radius: 12px;
  padding: 20px 16px;
  margin-bottom: 16px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.total-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.total-label {
  font-size: 0.85rem;
  opacity: 0.85;
  font-weight: 500;
}

.total-amount {
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.staff-count {
  margin-top: 8px;
  font-size: 0.82rem;
  opacity: 0.75;
}

/* 一覧セクション */
.list-section {
  background: #fff;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.list-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.list-header h2 {
  margin-bottom: 0;
}

.staff-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.empty-msg {
  text-align: center;
  color: #94a3b8;
  font-size: 0.9rem;
  padding: 24px 0;
}

/* スタッフカード */
.staff-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #f8fafc;
  border: 1.5px solid #e2e8f0;
  border-radius: 10px;
  padding: 12px 14px;
  gap: 8px;
}

.staff-info {
  flex: 1;
  min-width: 0;
}

.staff-name {
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.staff-detail {
  font-size: 0.8rem;
  color: #64748b;
}

.staff-cost {
  font-size: 1.05rem;
  font-weight: 700;
  color: #2563eb;
  white-space: nowrap;
}

.delete-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: #94a3b8;
  font-size: 1.1rem;
  padding: 4px 6px;
  border-radius: 6px;
  transition: color 0.15s, background 0.15s;
  flex-shrink: 0;
}

.delete-btn:hover {
  color: #ef4444;
  background: #fee2e2;
}
