:root {
  color: #1c1c1c;
  background: #f7f6f3;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  color: #1c1c1c;
  background: #f7f6f3;
  border-top: 4px solid #c4553a;
  line-height: 1.4;
}

main {
  max-width: 36rem;
  margin: 0 auto;
  padding: 1.25rem 1rem 2.5rem;
}

h1 {
  margin: 0 0 0.25rem;
  font-size: 1.6rem;
  font-weight: 650;
}

.lede { margin: 0 0 1rem; }

label {
  display: block;
  margin: 0.85rem 0 0.3rem;
  font-size: 0.85rem;
}

input, select, button {
  font: inherit;
  color: inherit;
  max-width: 100%;
}

input, select {
  display: block;
  width: 100%;
  padding: 0.55rem 0.65rem;
  background: #fff;
  border: 1px solid #cfcabe;
  border-radius: 4px;
}

button {
  margin-top: 1rem;
  padding: 0.55rem 0.9rem;
  background: #1c1c1c;
  color: #f7f6f3;
  border: 0;
  border-radius: 4px;
  cursor: pointer;
}

input:focus-visible,
select:focus-visible,
button:focus-visible {
  outline: 2px solid #c4553a;
  outline-offset: 2px;
}

.error {
  min-height: 1.25rem;
  margin: 0.6rem 0 0;
  color: #c4553a;
}

.total {
  margin: 0.8rem 0 0.3rem;
  font-size: 1.4rem;
  font-variant-numeric: tabular-nums;
}

#breakdown {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.9rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

#breakdown li { font-size: 0.92rem; }

.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.7rem 0;
  border-bottom: 1px solid #e4dfd6;
}

.row div { min-width: 0; }

.row strong,
.row span {
  display: block;
  overflow-wrap: anywhere;
}

.row strong { font-variant-numeric: tabular-nums; }

.row button {
  flex: 0 0 auto;
  margin: 0;
  background: transparent;
  color: #c4553a;
  border: 1px solid #c4553a;
}

.empty { margin: 0.8rem 0; }
