.cmlc-tool {
  font-size: 13.5px;
  color: #1e1b4b;
}
.cmlc-tool * {
  box-sizing: border-box;
}
.cmlc-fieldset {
  border: none;
  padding: 0;
  margin: 0;
}
.cmlc-legend {
  padding: 0;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #6366f1;
  margin-bottom: 12px;
}
.cmlc-row {
  margin-bottom: 14px;
}
.cmlc-row-shared {
  margin-bottom: 4px;
}
.cmlc-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #4b5563;
  margin-bottom: 6px;
}
.cmlc-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.cmlc-input-split {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
}
.cmlc-or {
  font-size: 11px;
  font-weight: 600;
  color: #9ca3af;
  text-align: center;
}
.cmlc-unit-pre {
  position: absolute;
  left: 14px;
  font-size: 14px;
  font-weight: 700;
  color: #6b7280;
  pointer-events: none;
  z-index: 1;
}
.cmlc-input {
  width: 100%;
  height: 42px;
  padding: 0 14px 0 14px;
  border: 1.5px solid #e0e7ff;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  color: #1e1b4b;
  background: #fafaff;
  transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
}
.cmlc-input-pre {
  padding-left: 26px;
}
.cmlc-input::placeholder {
  color: #c7c9e0;
  font-weight: 500;
}
.cmlc-input:focus {
  outline: none;
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
  background: #fff;
}
.cmlc-input.cmlc-invalid {
  border-color: #f87171;
  background: #fff5f5;
}
.cmlc-unit {
  position: absolute;
  right: 14px;
  font-size: 12.5px;
  font-weight: 600;
  color: #9ca3af;
  pointer-events: none;
}
.cmlc-divider {
  height: 1px;
  background: #e0e7ff;
  margin: 4px 0 18px;
}
.cmlc-row#cmlc-condition-group {
  display: flex;
  gap: 8px;
}
.cmlc-chip {
  flex: 1;
  height: 42px;
  padding: 0 8px;
  border: 1.5px solid #e0e7ff;
  border-radius: 10px;
  background: #fafaff;
  color: #6b7280;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
}
.cmlc-chip:hover {
  border-color: #6366f1;
}
.cmlc-chip-active {
  background: #eef2ff;
  border-color: #4338ca;
  color: #4338ca;
}
.cmlc-term-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 7px;
}
.cmlc-term-chip {
  height: 36px;
  border: 1.5px solid #e0e7ff;
  border-radius: 8px;
  background: #fafaff;
  color: #6b7280;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
}
.cmlc-term-chip:hover {
  border-color: #6366f1;
}
.cmlc-term-chip.cmlc-chip-active {
  background: #eef2ff;
  border-color: #4338ca;
  color: #4338ca;
}
.cmlc-btn {
  width: 100%;
  height: 44px;
  margin-top: 6px;
  background: #4338ca;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s;
}
.cmlc-btn:hover {
  background: #3730a3;
}
.cmlc-btn:active {
  transform: scale(0.98);
}
.cmlc-warn {
  font-size: 11.5px;
  font-weight: 600;
  color: #ef4444;
  text-align: center;
  min-height: 14px;
  margin: 10px 0 0;
}
.cmlc-results {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 16px;
}
.cmlc-result-wide {
  grid-column: 1 / -1;
}
.cmlc-result-card {
  background: #f8f9ff;
  border: 1.5px solid #e0e7ff;
  border-radius: 10px;
  padding: 12px 10px;
  text-align: center;
  transition: border-color 0.2s, background 0.2s;
}
.cmlc-result-card.cmlc-has-value {
  background: #fff;
  border-color: #4338ca;
}
.cmlc-result-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 18px;
  padding: 0 5px;
  border-radius: 5px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.02em;
  margin-bottom: 8px;
}
.cmlc-tag-monthly { background: #eef2ff; color: #4338ca; }
.cmlc-tag-principal { background: #f3f4f6; color: #6b7280; }
.cmlc-tag-interest { background: #fdf2f8; color: #be185d; }
.cmlc-tag-total { background: #f3f4f6; color: #6b7280; }
.cmlc-result-main {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 2px;
}
.cmlc-result-unit-pre {
  font-size: 13px;
  font-weight: 600;
  color: #9ca3af;
}
.cmlc-result-value {
  font-size: 20px;
  font-weight: 700;
  color: #1e1b4b;
  line-height: 1;
}
.cmlc-result-wide .cmlc-result-value {
  font-size: 28px;
}
.cmlc-result-unit {
  font-size: 12px;
  font-weight: 600;
  color: #9ca3af;
}
.cmlc-result-diff {
  display: block;
  font-size: 10.5px;
  color: #9ca3af;
  margin-top: 4px;
  min-height: 13px;
}
.cmlc-amort-wrap {
  margin-top: 14px;
}
.cmlc-amort-toggle {
  width: 100%;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: #f8f9ff;
  border: 1.5px solid #e0e7ff;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 600;
  color: #4338ca;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.cmlc-amort-toggle:hover {
  background: #eef2ff;
  border-color: #6366f1;
}
.cmlc-amort-arrow {
  font-size: 14px;
  transition: transform 0.2s;
  display: inline-block;
}
.cmlc-amort-arrow.open {
  transform: rotate(180deg);
}
.cmlc-amort-table-wrap {
  margin-top: 10px;
  max-height: 260px;
  overflow-y: auto;
  border: 1.5px solid #e0e7ff;
  border-radius: 10px;
}
.cmlc-amort-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11.5px;
}
.cmlc-amort-table thead {
  position: sticky;
  top: 0;
  z-index: 1;
}
.cmlc-amort-table th {
  background: #eef2ff;
  color: #4338ca;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 7px 10px;
  text-align: right;
  border-bottom: 1.5px solid #e0e7ff;
}
.cmlc-amort-table th:first-child { text-align: center; }
.cmlc-amort-table td {
  padding: 6px 10px;
  text-align: right;
  border-bottom: 1px solid #f0f1fa;
  color: #374151;
  font-weight: 500;
}
.cmlc-amort-table td:first-child {
  text-align: center;
  color: #9ca3af;
  font-weight: 600;
  font-size: 10.5px;
}
.cmlc-amort-table tbody tr:last-child td {
  border-bottom: none;
}
.cmlc-amort-table tbody tr:nth-child(even) td {
  background: #fafaff;
}
.cmlc-amort-table .cmlc-interest-cell {
  color: #be185d;
}
.cmlc-note {
  font-size: 11.5px;
  line-height: 1.5;
  color: #9ca3af;
  margin: 14px 0 0;
  text-align: center;
}