/* KGP Crew — brand: 2024 guidelines. Saira (headlines), Montserrat (labels/buttons; web stand-in for Gotham), Roboto (body). */
:root {
  --abyss: #231f20; --kelly: #40b449; --alloy: #e6e7e8; --gun: #404041; --sage: #437045;
  --light: #a7a9ac; --dark: #6d706e; --line: #d1d3d4; --white: #fff; --red: #9b2c1f;
  --head: "Saira", "Arial Narrow", Arial, sans-serif;
  --label: "Montserrat", Arial, sans-serif;
  --body: "Roboto", system-ui, -apple-system, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { font-family: var(--body); color: var(--abyss); background: var(--alloy); font-size: 16px; line-height: 1.45; -webkit-text-size-adjust: 100%; }
a { color: var(--sage); }
h1, h2, h3 { font-family: var(--head); margin: 0; line-height: 1.15; }
button, input, select, textarea { font: inherit; color: inherit; }
button { font-family: var(--label); font-weight: 700; cursor: pointer; }
.hidden { display: none !important; }
.sr { position: absolute; left: -9999px; }

.app { max-width: 560px; margin: 0 auto; min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; background: var(--alloy); }
.admin .app { max-width: 760px; }

.top { background: var(--abyss); color: var(--white); padding: 14px 18px 18px; padding-top: max(14px, env(safe-area-inset-top)); }
.top .bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.top .brand { display: flex; align-items: center; gap: 10px; font-family: var(--label); font-weight: 700; font-size: 14px; }
.top .brand img { height: 34px; width: auto; display: block; }
.top h1 { font-size: 26px; font-weight: 700; margin-top: 12px; }
.top .sub { color: var(--light); font-size: 14px; margin-top: 4px; }
.eyebrow { font-family: var(--label); font-weight: 700; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--light); }
.eyebrow.dark { color: var(--gun); }

.lang { display: flex; border: 1px solid var(--dark); }
.lang button { min-width: 46px; min-height: 40px; border: 0; background: transparent; color: var(--white); font-size: 13px; }
.lang button[aria-pressed="true"] { background: var(--white); color: var(--abyss); }

.main { flex: 1 1 auto; padding: 14px 16px 24px; display: flex; flex-direction: column; gap: 12px; }
.card { background: var(--white); border: 1px solid var(--line); padding: 16px; }
.card h2 { font-size: 19px; font-weight: 700; }
.card .muted, .muted { color: var(--gun); font-size: 14px; }
.small { font-size: 13px; }

.btn { min-height: 48px; padding: 0 18px; border: 0; background: var(--kelly); color: var(--abyss); font-size: 15px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; font-family: var(--label); font-weight: 700; }
.btn.block { width: 100%; }
.btn.ghost { background: var(--white); border: 2px solid var(--abyss); }
.btn.dark { background: var(--abyss); color: var(--white); }
.btn.link { background: transparent; color: var(--sage); min-height: 44px; padding: 0 6px; text-decoration: underline; }
.btn:disabled { opacity: .5; cursor: default; }
.btn.danger { background: var(--white); border: 2px solid var(--red); color: var(--red); }

label.field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 700; }
.field input, .field select, .field textarea, input.text { min-height: 48px; border: 1px solid var(--dark); padding: 0 12px; font-size: 16px; background: var(--white); font-weight: 400; width: 100%; }
.field textarea { padding: 10px 12px; line-height: 1.45; resize: vertical; min-height: 96px; }
.row2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 13px; line-height: 1.45; cursor: pointer; }
.check input { width: 22px; height: 22px; flex: 0 0 22px; margin: 0; accent-color: var(--sage); }

.msg { padding: 12px 14px; font-size: 14px; border: 1px solid var(--line); background: var(--white); }
.msg.err { border-color: var(--red); color: var(--red); }
.msg.ok { border-color: var(--sage); color: var(--sage); }

/* Login */
.people-group h2 { font-family: var(--label); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--gun); margin: 6px 0 8px; }
.name-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.name-grid button { min-height: 56px; padding: 0 14px; border: 1px solid var(--line); background: var(--white); text-align: left; font-family: var(--body); font-size: 16px; font-weight: 700; }
.dots { display: flex; gap: 18px; justify-content: center; margin: 18px 0 6px; }
.dots span { width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--abyss); }
.dots span.on { background: var(--abyss); }
.pad { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; max-width: 320px; width: 100%; margin: 12px auto 0; }
.pad button { height: 66px; border: 1px solid var(--line); background: var(--white); font-size: 26px; font-family: var(--body); }
.pad button.fn { background: var(--alloy); font-size: 20px; }
.pad .blank { visibility: hidden; }

/* Worker home */
.hero-note { background: var(--abyss); color: var(--white); padding: 18px; }
.hero-note .when { font-family: var(--head); font-size: 28px; font-weight: 700; line-height: 1.15; margin-top: 4px; }
.kv { font-size: 12px; font-family: var(--label); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--gun); }
.job { font-size: 18px; font-weight: 700; margin-top: 4px; }
.notes { white-space: pre-line; margin: 6px 0 0; }
.steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.steps li { display: flex; gap: 12px; align-items: flex-start; }
.steps .n { width: 30px; height: 30px; flex: 0 0 30px; display: flex; align-items: center; justify-content: center; font-family: var(--label); font-weight: 700; background: var(--alloy); }
.steps .n.done { background: var(--sage); color: var(--white); }

/* Admin */
.tabs { position: sticky; bottom: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); background: var(--white); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); }
.tabs button { min-height: 58px; border: 0; background: transparent; color: var(--gun); font-size: 13px; border-top: 3px solid transparent; }
.tabs button[aria-current="page"] { color: var(--abyss); border-top-color: var(--kelly); }
.list { display: flex; flex-direction: column; gap: 8px; }
.item { width: 100%; min-height: 64px; padding: 12px 14px; border: 1px solid var(--line); background: var(--white); display: flex; align-items: center; gap: 10px; text-align: left; font-family: var(--body); font-weight: 400; }
.item .grow { flex: 1 1 auto; min-width: 0; }
.item .title { font-weight: 700; font-size: 16px; }
.item .title.head { font-family: var(--head); font-size: 20px; }
.chev { color: var(--gun); font-size: 22px; }
.badge { display: inline-block; padding: 3px 9px; font-size: 12px; font-weight: 700; font-family: var(--label); background: var(--alloy); }
.badge.push { background: var(--abyss); color: var(--white); }
.st-ok { color: var(--sage); } .st-bad { color: var(--red); } .st-dim { color: var(--gun); }
.checklist { list-style: none; margin: 0; padding: 0; background: var(--white); border: 1px solid var(--line); }
.checklist li { display: flex; align-items: center; border-bottom: 1px solid var(--alloy); }
.checklist li:last-child { border-bottom: 0; }
.checklist label { flex: 1 1 auto; min-height: 56px; display: flex; align-items: center; gap: 14px; padding: 0 14px; cursor: pointer; }
.checklist input { width: 24px; height: 24px; margin: 0; accent-color: var(--sage); }
.checklist .who { display: flex; flex-direction: column; }
.checklist .who b { font-size: 16px; }
.checklist .who small { font-size: 12px; color: var(--gun); }
.checklist .who small.move { color: var(--red); }
.star { width: 52px; height: 56px; border: 0; background: transparent; font-size: 22px; color: var(--light); }
.star[aria-pressed="true"] { color: var(--sage); }
.sticky-foot { position: sticky; bottom: 58px; background: var(--white); border-top: 1px solid var(--line); padding: 12px 16px; margin: 0 -16px -24px; display: flex; flex-direction: column; gap: 8px; }
.chips { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 2px; }
.chips button { flex: 0 0 auto; min-height: 44px; padding: 0 14px; border: 1px solid var(--dark); background: transparent; color: var(--white); font-size: 13px; }
.chips button[aria-selected="true"] { background: var(--kelly); border-color: var(--kelly); color: var(--abyss); }
.datebar { display: flex; align-items: center; gap: 8px; }
.datebar button { width: 44px; height: 44px; border: 1px solid var(--dark); background: transparent; color: var(--white); font-size: 18px; }
.sheet-bg { position: fixed; inset: 0; background: rgba(35,31,32,.55); display: flex; align-items: flex-end; justify-content: center; z-index: 20; }
.sheet { background: var(--alloy); width: 100%; max-width: 560px; max-height: 92vh; overflow-y: auto; padding: 18px 16px 24px; display: flex; flex-direction: column; gap: 12px; }
.sheet h2 { font-size: 22px; }
.toast { position: fixed; left: 50%; bottom: 80px; transform: translateX(-50%); background: var(--abyss); color: var(--white); padding: 12px 18px; font-size: 14px; z-index: 30; max-width: 90vw; }
@media (min-width: 761px) { .sheet-bg { align-items: center; } }
