:root {
  --paper: oklch(97% 0.002 250);
  --surface: oklch(99.5% 0.001 250);
  --ink: oklch(22% 0.004 250);
  --muted: oklch(47% 0.006 250);
  --rule: oklch(73% 0.004 250);
  --accent: #16734b;
  --tint: oklch(96% 0.012 155);
  font-family: "Barlow", sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
a {
  color: inherit;
  text-decoration: none;
}
input,
select {
  font: inherit;
  border-radius: 0;
}
input:focus-visible,
select:focus-visible,
a:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
.masthead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--surface);
  border-bottom: 1px solid var(--rule);
  padding: 18px max(24px, calc((100vw - 1120px) / 2));
}
.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}
.wordmark img {
  display: block;
}
.wordmark span {
  font-family: "Barlow Condensed", "Arial Narrow", sans-serif;
  font-size: 28px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
}
main {
  max-width: 1120px;
  margin: 32px auto 48px;
}
.calculator {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--rule);
}
.calculator::before,
.calculator::after {
  content: "";
  position: absolute;
  width: 10px;
  height: 10px;
  border: 1px solid var(--ink);
  pointer-events: none;
}
.calculator::before {
  top: -5px;
  left: -5px;
  border-right: 0;
  border-bottom: 0;
}
.calculator::after {
  right: -5px;
  bottom: -5px;
  border-top: 0;
  border-left: 0;
}
.tool-heading {
  padding: 18px 24px;
  border-bottom: 1px solid var(--rule);
}
h1,
h2 {
  margin: 0;
  font-family: "Barlow Condensed", "Arial Narrow", sans-serif;
  font-weight: 500;
  text-transform: uppercase;
}
h1 {
  font-size: 24px;
  letter-spacing: 0.4px;
}
.inputs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.field {
  padding: 16px 24px 12px;
  border-right: 1px solid var(--rule);
}
.field:last-child {
  border-right: 0;
}
.field > label,
.hint,
thead th,
.totals > div > span:first-child {
  font-family: "Barlow Condensed", "Arial Narrow", sans-serif;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 1.4px;
  text-transform: uppercase;
}
.field > label {
  display: flex;
  align-items: baseline;
  gap: 8px;
  color: var(--muted);
  margin-bottom: 7px;
}
.hint {
  letter-spacing: 0.5px;
  margin-left: auto;
}
.field input,
.field select {
  width: 100%;
  min-width: 0;
  height: 44px;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-family: "Barlow Condensed", "Arial Narrow", sans-serif;
  font-size: 32px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.field select {
  cursor: pointer;
}
.field input:disabled {
  opacity: 0.35;
}
.money-input {
  display: flex;
  align-items: center;
  gap: 4px;
  font-family: "Barlow Condensed", "Arial Narrow", sans-serif;
  font-size: 28px;
}
.money-input input {
  flex: 1;
}
.mixed-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  margin: 0 24px;
  font-size: 13px;
  cursor: pointer;
}
input[type="checkbox"] {
  width: 17px;
  height: 17px;
  margin: 0;
  accent-color: var(--accent);
  flex-shrink: 0;
  cursor: pointer;
}
.individual-odds {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  gap: 12px;
  padding: 8px 24px 20px;
}
.individual-odds[hidden] {
  display: none;
}
.individual-odds label {
  font-size: 13px;
  color: var(--muted);
}
.individual-odds input {
  display: block;
  width: 100%;
  margin-top: 6px;
  padding: 8px;
  border: 1px solid var(--rule);
  background: var(--surface);
  font-size: 20px;
  color: var(--ink);
}
.error {
  color: var(--accent);
  font-size: 14px;
  margin: 0;
  padding: 8px 24px 16px;
}
.error:empty {
  display: none;
}
.table-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 24px;
  background: var(--paper);
  border-block: 1px solid var(--rule);
}
.table-heading h2 {
  font-size: 16px;
  letter-spacing: 1px;
}
.table-heading > span {
  font-size: 12px;
  color: var(--muted);
}
table {
  table-layout: fixed;
  width: 100%;
  border-collapse: collapse;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
thead th {
  padding: 11px 24px;
  color: var(--muted);
}
thead th:first-child {
  width: 43%;
  text-align: left;
}
thead th:nth-child(2) {
  width: 13%;
}
thead span {
  white-space: nowrap;
}
th,
td {
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
th:last-child,
td:last-child {
  border-right: 0;
}
tbody th {
  text-align: left;
  font-size: 16px;
  font-weight: 400;
}
tbody th label {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 14px 24px;
  min-height: 51px;
  cursor: pointer;
}
tbody td {
  padding: 12px 24px;
  font-size: 19px;
  font-family: "Barlow Condensed", "Arial Narrow", sans-serif;
  font-weight: 500;
  letter-spacing: 0.3px;
  overflow-wrap: anywhere;
}
tr.selected {
  background: var(--tint);
}
tr.selected td:last-child {
  color: var(--accent);
}
tbody tr:hover {
  background: oklch(94% 0.004 250);
}
.empty {
  height: 90px;
  text-align: center;
  color: var(--muted);
  font-family: "Barlow", sans-serif;
  font-size: 14px;
}
.totals {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1.2fr;
  background: var(--paper);
}
.totals > div {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  padding: 18px 24px;
  border-right: 1px solid var(--rule);
}
.totals > div:last-child {
  border-right: 0;
}
.totals > div > span {
  font-size: 12px;
  color: var(--muted);
}
.totals strong {
  font-family: "Barlow Condensed", "Arial Narrow", sans-serif;
  font-size: 38px;
  line-height: 1.1;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
.totals .return-total strong {
  color: var(--accent);
}
.totals small {
  font-size: 12px;
  color: var(--muted);
}
.assumption {
  border-top: 1px solid var(--rule);
  font-size: 12px;
  line-height: 1.5;
  color: var(--muted);
  margin: 0;
  padding: 12px 24px;
}
.guide {
  margin-top: 16px;
  border-bottom: 1px solid var(--rule);
}
.guide summary {
  min-height: 44px;
  padding: 10px 0;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
}
.guide-copy {
  max-width: 70ch;
  padding: 12px 0 24px;
}
.guide h3 {
  font-size: 15px;
  font-weight: 600;
  margin: 0 0 6px;
}
.guide p {
  font-size: 14px;
  line-height: 1.6;
  margin: 0 0 18px;
  color: var(--muted);
}
.guide .guide-note {
  font-size: 12px;
  margin-bottom: 0;
}
.formula {
  white-space: nowrap;
  color: var(--ink);
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
footer {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 24px;
  max-width: 1120px;
  margin: 0 auto;
  padding: 18px 0 24px;
  border-top: 1px solid var(--rule);
}
.footer-wordmark {
  font-family: "Barlow Condensed", "Arial Narrow", sans-serif;
  font-size: 20px;
  font-weight: 600;
  color: var(--accent);
}
footer > span {
  font-size: 12px;
  line-height: 1.4;
  color: var(--muted);
  text-align: right;
}
@media (max-width: 1168px) {
  main,
  footer {
    margin-inline: 24px;
  }
}
@media (max-width: 600px) {
  footer {
    margin-inline: 12px;
    gap: 20px;
  }
  footer > span {
    max-width: 220px;
  }
  .masthead {
    padding: 14px 16px;
  }
  .wordmark {
    gap: 10px;
  }
  .wordmark img {
    width: 29px;
    height: 32px;
  }
  .wordmark span {
    font-size: 25px;
  }
  main {
    margin: 16px 12px 32px;
  }
  .tool-heading {
    padding: 14px 12px;
  }
  h1 {
    font-size: 21px;
    letter-spacing: 0;
  }
  .field {
    padding: 12px 10px 8px;
  }
  .field > label {
    display: block;
    font-size: 11px;
    letter-spacing: 0.5px;
    min-height: 29px;
    margin-bottom: 3px;
  }
  .hint {
    display: block;
    font-size: 10px;
    letter-spacing: 0;
  }
  .field input,
  .field select {
    font-size: 29px;
    height: 40px;
  }
  .money-input {
    font-size: 24px;
  }
  .mixed-toggle {
    margin-inline: 12px;
    font-size: 12px;
  }
  .individual-odds {
    padding-inline: 12px;
  }
  .error {
    padding-inline: 12px;
  }
  .table-heading {
    padding: 10px 12px;
    gap: 8px;
  }
  .table-heading h2 {
    font-size: 14px;
    letter-spacing: 0.4px;
  }
  .table-heading > span {
    font-size: 11px;
  }
  thead th {
    font-size: 10px;
    letter-spacing: 0.5px;
    padding: 9px 6px;
  }
  thead th:first-child {
    width: 41%;
  }
  thead th:nth-child(2) {
    width: 12%;
  }
  thead span {
    display: block;
  }
  tbody th {
    font-size: 13px;
  }
  tbody th label {
    padding: 11px 8px;
    min-height: 52px;
    gap: 8px;
  }
  tbody td {
    font-size: 16px;
    padding: 10px 6px;
    letter-spacing: 0;
  }
  input[type="checkbox"] {
    width: 16px;
    height: 16px;
  }
  .totals {
    grid-template-columns: 0.9fr 1fr 1.25fr;
  }
  .totals > div {
    padding: 14px 10px;
    gap: 6px;
  }
  .totals > div > span:first-child {
    font-size: 10px;
    letter-spacing: 0.5px;
  }
  .totals strong {
    font-size: 28px;
  }
  .totals small,
  .totals #selection-note {
    font-size: 10px;
    line-height: 1.4;
  }
  .assumption {
    padding: 10px 12px;
    font-size: 11px;
  }
  .guide {
    margin-top: 8px;
  }
}

.view-link {
  font-size: 13px;
  color: var(--accent);
  padding-block: 12px;
}
