.ds-wrap {
  max-width: 860px;
  margin: 24px auto;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, "Noto Sans JP", sans-serif;
}

.ds-title {
  text-align: center;
  margin: 0 0 16px;
  font-weight: 700;
}

.ds-card {
  border: 1px solid #e5e7eb;
  padding: 16px;
  border-radius: 10px;
  background: #fff;
}

.ds-section + .ds-section {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px dashed #e5e7eb;
}

.ds-section-title {
  font-weight: 600;
  margin-bottom: 10px;
}

.ds-structure {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.ds-btn {
  appearance: none;
  border: 1px solid #cbd5e1;
  background: #fff;
  padding: 12px 10px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
}

.ds-structure-btn.is-active {
  background: #f59e0b; /* orange-ish */
  border-color: #f59e0b;
  color: #fff;
}

.ds-field {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.ds-label {
  min-width: 120px;
  font-weight: 600;
}

.ds-required {
  color: #ef4444;
  margin-right: 6px;
}

.ds-input {
  width: 120px;
  padding: 10px 10px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
}

.ds-suffix {
  font-weight: 600;
}

.ds-hint {
  color: #64748b;
  font-size: 12px;
}

.ds-actions {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
}

.ds-calc-btn {
  width: min(360px, 100%);
  background: #9b4d4d; /* similar to screenshot button tone */
  border-color: #9b4d4d;
  color: #fff;
  padding: 14px 12px;
}

.ds-calc-btn.is-loading {
  opacity: 0.7;
  cursor: wait;
}

.ds-error {
  color: #ef4444;
  font-weight: 600;
}

.ds-result {
  margin-top: 20px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #fff;
  padding: 16px;
}

.ds-result-title {
  margin: 0 0 12px;
  font-weight: 700;
}

.ds-summary {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 12px;
}

.ds-summary th,
.ds-summary td {
  border: 1px solid #e5e7eb;
  padding: 10px;
}

.ds-summary th {
  width: 140px;
  background: #f8fafc;
  text-align: left;
}

.ds-table {
  width: 100%;
  border-collapse: collapse;
}

.ds-table th,
.ds-table td {
  border: 1px solid #e5e7eb;
  padding: 10px;
  vertical-align: top;
}

.ds-table thead th {
  background: #f8fafc;
}

.ds-right {
  text-align: right;
  white-space: nowrap;
}