/* Look and colours follow the reference page the user named (takeoff.lcwth.tech/rn1-vu1). */
:root {
  --bg: #f2f5ef; --ink: #233d37; --card: #fff; --line: #c4d1c9; --row: #dde6df;
  --green: #245c4a; --green-ink: #174e3f; --soft: #f8faf7; --soft-line: #bfcec3;
  --muted: #52685e; --crumb: #365b4c; --field: #80988a; --mark: #fff2ce; --warn: #8a4b12;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 system-ui, "Leelawadee UI", sans-serif; }
/* Top bar and mark: same as the unit-cost site's (unitcost.lcwth.tech). */
.appbar { display: flex; align-items: center; gap: 25px; min-height: 86px; padding: 0 32px; background: #fff; border-bottom: 1px solid #dce6e0; }
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; }
.brand .icon { flex: none; width: 44px; height: 44px; padding: 9px; border-radius: 12px; background: #17664e; fill: none; stroke: #fff; stroke-width: 1.6; }
.brand-name { display: block; font-size: 20px; font-weight: 700; line-height: 1.3; color: #183c37; }
.brand-name small { display: block; font-size: 12px; font-weight: 400; color: #68808e; }
.page-header { max-width: 1160px; padding: 14px 24px 5px; }
nav { display: flex; flex-wrap: wrap; gap: 6px; }
nav a { background: var(--card); border: 1px solid var(--line); color: var(--green-ink); border-radius: 6px;
  padding: 6px 10px; font-size: 14px; text-decoration: none; }
nav a.on { background: var(--green); border-color: var(--green); color: #fff; }
main { padding: 20px; max-width: 1160px; }
.crumb { font-size: 12px; font-weight: 650; color: var(--crumb); }
h1 { font-size: 36px; line-height: 1.2; margin: 4px 0 6px; }
h2 { font-size: 20px; margin: 0 0 8px; }
h3 { font-size: 15px; margin: 0 0 4px; }
p { margin: 4px 0; }
.sub, small, .muted { color: var(--muted); font-size: 13px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 13px; padding: 16px; margin-top: 14px; }
.panel { background: var(--soft); border: 1px solid var(--soft-line); border-radius: 8px; padding: 9px 11px; margin: 10px 0; }
.panel.on { border-color: var(--green); box-shadow: inset 3px 0 0 var(--green); }
.fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; margin-top: 12px; }
.field { display: flex; flex-direction: column; gap: 3px; font-size: 13px; }
select, input { font: inherit; font-size: 13px; color: var(--ink); background: #fff; border: 1px solid var(--field);
  border-radius: 5px; padding: 8px 10px; width: 100%; }
button { font: inherit; font-size: 13px; background: #fff; border: 1px solid #bacbc1; color: #2a4c3f; border-radius: 6px;
  padding: 5px 10px; cursor: pointer; }
button.main { background: #174d3c; border-color: #174d3c; color: #fff; border-radius: 18px; padding: 8px 15px; font-weight: 600; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; padding: 6px; border-bottom: 1px solid var(--row); }
td { padding: 8px; border-bottom: 1px solid var(--row); vertical-align: top; }
td.n, th.n { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
td.b { font-weight: 700; }
tr.go { cursor: pointer; }
tr.go:hover td { background: var(--soft); }
.fill { background: var(--mark); border: 1px solid #9fb8ac; border-radius: 6px; padding: 5px 9px; display: inline-block; }
tr.wait td { background: #fffaf0; }
.err { color: var(--warn); }
.tag { display: inline-block; font-size: 12px; border: 1px solid var(--line); border-radius: 6px; padding: 1px 7px; margin-left: 6px; color: var(--green-ink); background: #fff; }
.tag.on { background: var(--green); border-color: var(--green); color: #fff; }
.note { padding: 7px 0; border-bottom: 1px solid var(--row); }
.note:last-child { border-bottom: 0; }
.note ul { margin: 3px 0 0; padding-left: 18px; color: var(--muted); font-size: 13px; }
details { margin-top: 6px; }
summary { cursor: pointer; font-weight: 650; font-size: 13.6px; }
dl { margin: 6px 0 0; font-size: 13px; }
dt { font-weight: 700; margin-top: 5px; }
dd { margin: 0; color: var(--muted); }
.rowline { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: space-between; }
.proj td .fields { margin-top: 0; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 6px; }
.proj td select, .proj td input { padding: 5px 7px; }
.opt { display: flex; gap: 8px; align-items: flex-start; padding: 5px 0; }
.opt input { width: auto; margin-top: 4px; }
/* Phones and tablets. */
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
.card, .panel { overflow-x: auto; -webkit-overflow-scrolling: touch; }
/* touch screens: 16px inputs stop iOS from zooming the page on focus; larger targets for fingers */
@media (pointer: coarse) {
  select, input { font-size: 16px; }
  button, nav a { min-height: 40px; padding: 8px 12px; }
  nav a { display: flex; align-items: center; }
}
@media (max-width: 640px) {
  h1 { font-size: 26px; } main { padding: 12px; } .page-header { padding: 10px 12px 4px; }
  .appbar { min-height: 60px; padding: 8px 12px; }
  .brand { gap: 10px; }
  .brand .icon { width: 38px; height: 38px; padding: 8px; border-radius: 10px; }
  .brand-name { font-size: 16px; }  /* the full name stays on one line on a phone */
  .brand-name small { font-size: 11px; }
  .card { padding: 12px; border-radius: 10px; }
  table { font-size: 13.5px; } th, td { padding: 6px 4px; }
  table.wide { min-width: 600px; }  /* many columns: scroll sideways inside the card instead of squeezing */
  .fields { grid-template-columns: 1fr 1fr; }
  .fields .field:first-child { grid-column: 1 / -1; }
  /* project rows: one block per structure instead of a four-column table */
  .proj thead { display: none; }
  .proj table, .proj tbody, .proj tr, .proj td { display: block; }
  .proj tr { padding: 8px 0; border-bottom: 1px solid var(--row); }
  .proj td { border-bottom: 0; padding: 3px 0; }
  .proj td .fields .field:first-child { grid-column: auto; }
}
