*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
body {
  font-family: system-ui, sans-serif;
  background: #34373b;
  color: #1a1a18;
  min-height: 100vh;
  padding: 2rem 1rem;
}
#Interface {
  max-width: 640px;
  margin: 0 auto;
}
h2 {
  color: rgb(245, 245, 245);
  font-size: 20px;
  font-weight: 500;
  margin-bottom: 1.25rem;
}
.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 1.5rem;
}
.card {
  background: #121612;
  border-radius: 8px;
  padding: 0.85rem 1rem;
}
.card .label {
  font-size: 12px;
  color: #666;
  margin-bottom: 4px;
}
.card .value {
  font-size: 20px;
  font-weight: 500;
  color: #9e9e30;
}
.card.income .value {
  color: #3b6d11;
}

.card.expense .value {
  color: #a32d2d;
}
.form-wrap {
  background: #fff;
  border: 0.5px solid rgba(0, 0, 0, 0.12);
  border-radius: 12px;
  padding: 1rem 1.25rem;
  margin-bottom: 1.5rem;
}

form-wrap h3 {
  font-size: 14px;
  font-weight: 500;
  color: #666;
  margin-bottom: 0.85rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 8px;
}
.form-row.full {
  grid-template-columns: 1fr;
}
input,
select {
  width: 100%;
  padding: 7px 10px;
  font-size: 14px;
  border: 0.5px solid rgba(0, 0, 0, 0.2);
  border-radius: 8px;
  background: #fff;
  color: #1a1a18;
  outline: none;
  font-family: inherit;
}
input:focus,
select:focus {
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.15);
}
.button-row {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}
button {
  border: 0.5px solid rgba(0, 0, 0, 0.2);
  border-radius: 8px;
  background: transparent;
  color: #1a1a18;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s;
  padding: 7px 16px;
  font-size: 14px;
}
button:hover {
  background: #f0f0ee;
}
button.primary {
  background: #1a1a18;
  color: #fff;
  border-color: transparent;
}
button.primary:hover {
  opacity: 0.85;
}
button.danger {
  color: #a32d2d;
  border-color: #fcebeb;
}
button.danger:hover {
  background: #fcebeb;
}
.filter-option {
  display: flex;
  gap: 8px;
  margin-bottom: 1rem;
  align-items: center;
}
.filter-option select {
  max-width: 160px;
}
.filter-option input {
  max-width: 220px;
}
.list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.item {
  display: flex;
  background: #fff;
  border: 0.5px solid rgba(0, 0, 0, 0.12);
  border-radius: 12px;
  padding: 0.75rem 1rem;
  align-items: center;
  gap: 10px;
}
.item-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}
.item-dot.income {
  background: #3b6d11;
}
.item-dot.expense {
  background: #a32d2d;
}
.item-desc {
  flex: 1;
  min-width: 0;
}
.item-desc .name {
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.item-desc .meta {
  font-size: 12px;
  color: #888;
  margin-top: 2px;
}
.item-amount {
  font-size: 15px;
  font-weight: 500;
  white-space: nowrap;
}
.item-amount.income {
  color: #3b6d11;
}
.item-amount.expense {
  color: #a32d2d;
}
.item-actions {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}
.item-actions button {
  padding: 4px 8px;
  font-size: 12px;
}
.badge {
  display: inline-block;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 99px;
  font-weight: 500;
}
.badge.income {
  background: #eaf3de;
  color: #27500a;
}
.badge.expense {
  background: #fcebeb;
  color: #791f1f;
}
.edit-note {
  font-size: 12px;
  color: #854f0b;
  background: #faeeda;
  padding: 4px 10px;
  border-radius: 8px;
  margin-bottom: 8px;
  display: none;
}
.empty {
  text-align: center;
  color: #888;
  font-size: 14px;
  padding: 2rem 0;
}
