:root {
  /* CrewCall palette */
  --white: #FFFFFF; --fog: #CCCCCC; --smoke: #7D7D7D; --iron: #4D4D4D; --midnight: #262626; --black: #1A1A1A;

  --bg: #EFEFEF; --surface: #F6F6F6; --card: var(--white); --ink: var(--black); --muted: var(--smoke); --line: #E2E2E2;
  --dark: var(--black); --dark-2: var(--midnight); --dark-line: var(--iron); --dark-ink: var(--white); --dark-muted: #A8A8A8;
  --brand: var(--black); --brand-soft: var(--fog); --brand-ink: var(--white);
  /* muted status colours: only used on small dots and pills */
  --ok: #2F6B4F; --ok-bg: #E4EEE8; --warn: #85661C; --warn-bg: #F3ECD9; --bad: #9C3B30; --bad-bg: #F4E3E0;
  --info: var(--midnight); --info-bg: #E6E6E6;
  /* card shades (one per job, picked from its id) */
  --tint-0: #F1F1F1; --tint-1: #E7E7E7; --tint-2: #EDEDED; --tint-3: #E2E2E2; --tint-4: #EAEAEA; --tint-5: #F5F5F5;
  --radius: 18px; --radius-sm: 12px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: "Manrope", system-ui, "Segoe UI", Roboto, sans-serif; background: var(--bg); color: var(--ink); font-size: 15px; line-height: 1.45; }
a { color: var(--info); }
button { font-family: inherit; }

/* ---------- top bar ---------- */
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 24px; background: var(--dark); color: var(--dark-ink); position: sticky; top: 0; z-index: 20; border-bottom: 1px solid var(--dark-line); }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 800; font-size: 18px; letter-spacing: .2px; }
.brand .logo { width: 30px; height: 30px; display: block; flex: none; }
.brand b { font-weight: 800; } .brand b span { color: var(--fog); font-weight: 600; }
#nav { display: flex; gap: 4px; flex-wrap: wrap; align-items: center; }
#nav a { color: var(--dark-muted); text-decoration: none; font-size: 14px; font-weight: 600; padding: 8px 12px; border-radius: 999px; }
#nav a:hover { color: #fff; }
#nav a.active { color: #fff; background: var(--dark-2); }
#nav a.cta { color: var(--black); background: var(--white); }
/* ---------- applications page ---------- */
.rv-bar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; position: sticky; top: 72px; z-index: 5; padding: 12px 16px; }
.rv-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 12px 0; border-top: 1px solid var(--line); }
.card .sectionhead + .rv-row { margin-top: 10px; }
.rv-check { width: 20px; height: 20px; accent-color: var(--black); flex: none; }

/* ---------- about section and legal pages ---------- */
.about { max-width: 640px; margin: 28px auto 0; text-align: center; }
.about h2 { font-size: 20px; }
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 16px 0; text-align: left; }
.about-grid > div { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.about-grid p { margin: 6px 0 0; color: var(--iron); font-size: 14px; }
@media (max-width: 560px) { .about-grid { grid-template-columns: 1fr; } }
.legal-foot { font-size: 13px; color: var(--muted); text-align: center; margin: 18px 0 24px; }
.legal-foot a { color: var(--iron); }
main.legal { max-width: 760px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); margin: 24px auto; padding: 28px 32px; line-height: 1.6; }
main.legal h2 { font-size: 18px; margin-top: 26px; }
main.legal ul { padding-left: 20px; }
main.legal li { margin: 6px 0; }
main.legal a { color: var(--ink); }
@media (max-width: 600px) { main.legal { margin: 0; border-radius: 0; border-left: 0; border-right: 0; padding: 20px 16px; } }

/* ---------- logo on the dark app bar (inverted: white square, black C) ---------- */
.topbar .logo { filter: invert(1); }

/* ---------- public homepage ---------- */
body.public { background: #fff; }
body.public .topbar { background: #fff; border-bottom: 1px solid #000; color: #000; position: static; padding: 18px 40px; }
body.public .brand { color: #000; font-size: 24px; gap: 12px; }
body.public .brand .logo { filter: none; width: 40px; height: 40px; }
body.public .brand b span { color: #000; font-weight: 800; }
body.public #nav .login-btn { background: #fff; color: #000; border: 1.5px solid #000; border-radius: 8px; padding: 9px 22px; font-weight: 800; font-size: 16px; }
body.public #nav .login-btn:hover { background: #000; color: #fff; }
body.public main { max-width: 1180px; padding: 0 40px 40px; }
.hp-hero { text-align: center; padding: 64px 0 40px; }
.hp-hero h1 { font-size: clamp(38px, 7vw, 80px); line-height: 1.05; font-weight: 800; letter-spacing: -1.5px; margin: 0; }
.hp-hero p { font-size: clamp(16px, 2vw, 21px); margin: 18px auto 0; max-width: 820px; color: #111; }
.hp-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.hp-card { border: 1.5px solid #000; border-radius: 6px; padding: 36px 40px; display: flex; flex-direction: column; align-items: flex-start; }
.hp-card h2 { font-size: clamp(24px, 3vw, 36px); font-weight: 800; letter-spacing: -.5px; margin: 0; }
.hp-card p { font-size: 17px; margin: 14px 0 32px; flex: 1; }
.hp-btn { background: #000; color: #fff; border: 1.5px solid #000; border-radius: 4px; font: inherit; font-weight: 800; font-size: 18px; padding: 14px 28px; cursor: pointer; }
.hp-btn:hover { background: #262626; }
.hp-btn:disabled { opacity: .6; cursor: default; }
.hp-form { border: 1.5px solid #000; border-radius: 6px; padding: 32px 40px; margin-top: 28px; scroll-margin-top: 20px; }
.hp-form h2 { font-size: 28px; font-weight: 800; margin: 0; outline: none; }
.hp-switch { margin: 6px 0 20px; color: var(--iron); }
.linkish { background: none; border: 0; padding: 0; font: inherit; font-weight: 700; color: #000; text-decoration: underline; cursor: pointer; }
.hp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 20px; }
.hp-grid .field.full { grid-column: 1 / -1; }
.field label { font-size: 14px; }
.field input { border: 1.5px solid #000; border-radius: 4px; }
.field input[type=file] { border-style: dashed; padding: 12px; }
.optional { font-weight: 500; color: var(--smoke); }
.field-err { color: var(--bad); font-size: 13px; font-weight: 600; margin: 4px 0 6px; min-height: 0; }
.field-err:empty { display: none; }
.form-err { background: var(--bad-bg); color: var(--bad); border-radius: 4px; padding: 10px 14px; font-weight: 600; }
.hp-form .submit { margin-top: 18px; }
.hp-hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.hp-done { border-left: 4px solid #000; padding: 6px 0 6px 18px; outline: none; }
.hp-done h3 { margin: 0 0 6px; font-size: 22px; }
.back-home { max-width: 420px; margin: 4vh auto -3vh; }
.back-home a { color: var(--iron); font-weight: 700; text-decoration: none; }
table.kv th { width: 160px; text-transform: none; font-size: 14px; letter-spacing: 0; color: var(--muted); }
@media (max-width: 760px) {
  body.public .topbar { padding: 14px 16px; }
  body.public .brand { font-size: 20px; }
  body.public .brand .logo { width: 34px; height: 34px; }
  body.public #nav .login-btn { padding: 7px 16px; font-size: 15px; }
  body.public main { padding: 0 16px 32px; }
  .hp-hero { padding: 40px 0 28px; }
  .hp-cards, .hp-grid { grid-template-columns: 1fr; }
  .hp-card, .hp-form { padding: 24px 20px; }
  .hp-btn { width: 100%; }
}

/* ---------- staff page ---------- */
.staff-filters { display: grid; gap: 10px; }
.staff-filters .row select { width: auto; padding: 8px 10px; font-size: 14px; }
.staff-table td { vertical-align: top; }
.contact-btns { gap: 6px; }
.contact-btns .btn { padding: 5px 10px; font-size: 12px; }

/* ---------- profile form sections, join/welcome ---------- */
.form-h { font-size: 15px; text-transform: uppercase; letter-spacing: .6px; color: var(--iron); margin: 26px 0 4px; padding-top: 16px; border-top: 1px solid var(--line); }
.card > .photo-pick + .form-h { border-top: 0; padding-top: 0; }
input.invalid, select.invalid { border-color: var(--bad); outline: 2px solid var(--bad-bg); }
.small-note { font-size: 12px; margin: 10px 0 12px; }
.welcome .big-check { width: 64px; height: 64px; border-radius: 50%; background: var(--black); color: var(--white); display: grid; place-items: center; font-size: 30px; font-weight: 800; margin: 0 auto 14px; }

/* ---------- sign-in page ---------- */
.login { max-width: 420px; margin: 6vh auto 0; background: var(--card); border: 1px solid var(--line); border-radius: 24px; padding: 36px 28px; text-align: center; }
.login-logo { width: 64px; height: 64px; border-radius: 18px; background: var(--black); padding: 6px; margin-bottom: 14px; }
.login h1 { font-size: 26px; }
.login .sub { margin: 8px 0 22px; }
.login .sub.small { font-size: 12px; margin: 14px 0 0; }
.btn.google { background: var(--white); color: var(--ink); border: 1px solid var(--fog); gap: 10px; }
.btn.google:hover { border-color: var(--iron); }
.btn.google svg.g { width: 20px; height: 20px; }
.or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13px; margin: 18px 0 4px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }

.bell-wrap { position: relative; }
.bell { position: relative; width: 36px; height: 36px; border-radius: 50%; border: 0; background: var(--dark-2); color: var(--white); display: grid; place-items: center; cursor: pointer; }
.bell:hover { background: var(--iron); }
.bell svg.i { width: 18px; height: 18px; vertical-align: 0; }
.bell .dot { position: absolute; top: -3px; right: -3px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: #C8432F; color: #fff; font-size: 11px; font-weight: 800; display: grid; place-items: center; border: 2px solid var(--dark); }
.bell-panel { position: absolute; right: 0; top: 46px; width: min(380px, calc(100vw - 24px)); background: var(--card); color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 12px 32px rgba(26,26,26,.18); z-index: 40; overflow: hidden; }
.bell-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.bell-list { max-height: 60vh; overflow-y: auto; }
.note { padding: 12px 16px; border-bottom: 1px solid var(--line); }
.note:last-child { border-bottom: 0; }
.note.unread { background: var(--surface); box-shadow: inset 3px 0 0 var(--black); }
.note-title { font-weight: 700; font-size: 14px; }
.note-body { font-size: 13px; color: var(--iron); margin-top: 2px; }
.note-time { font-size: 12px; color: var(--muted); margin-top: 4px; }
#nav a.avatar { padding: 0; color: var(--black); background: var(--white); overflow: hidden; }
#nav a.avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
#nav a.avatar:hover { outline: 2px solid var(--fog); }
.panel-dark .btn.primary { background: var(--white); color: var(--black); border-color: var(--white); }
#nav select { color: #fff; background: var(--dark-2); border: 1px solid var(--dark-line); border-radius: 999px; padding: 7px 12px; font: inherit; font-size: 14px; width: auto; }
#nav select option { color: #000; }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--white); color: var(--black); display: grid; place-items: center; font-weight: 800; font-size: 13px; text-decoration: none; margin-left: 6px; }

/* ---------- dark filter strip ---------- */
.filterbar { background: var(--dark); border-bottom: 1px solid var(--dark-line); padding: 14px 24px 18px; }
.filterbar .inner { max-width: 1180px; margin: 0 auto; display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.fb-field { display: flex; align-items: center; gap: 8px; background: var(--dark-2); border: 1px solid var(--dark-line); border-radius: 999px; padding: 6px 6px 6px 14px; color: var(--dark-ink); flex: 1; min-width: 180px; }
.fb-field .ico { color: var(--dark-muted); font-size: 14px; }
.fb-field input, .fb-field select { background: transparent; border: 0; color: var(--dark-ink); font: inherit; font-size: 14px; padding: 6px 4px; width: 100%; outline: none; }
.fb-field select option { color: #000; }
.fb-field input::placeholder { color: var(--dark-muted); }

/* ---------- page layout ---------- */
main { max-width: 1180px; margin: 0 auto; padding: 24px; }
.page { background: var(--surface); }
.layout { display: grid; grid-template-columns: 250px 1fr; gap: 24px; align-items: start; }
.sidebar { position: sticky; top: 88px; display: grid; gap: 16px; }
h1 { font-size: 26px; margin: 0; letter-spacing: -.3px; }
h2 { font-size: 17px; margin: 0 0 8px; }
.sub { color: var(--muted); margin: 4px 0 16px; font-size: 14px; }
.headrow { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.headrow .left { display: flex; align-items: center; gap: 10px; }
.count { display: inline-grid; place-items: center; min-width: 34px; height: 28px; padding: 0 10px; border: 1px solid var(--line); border-radius: 999px; font-weight: 700; font-size: 13px; background: #fff; }
.sortby { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 13px; }
.sortby select { width: auto; border: 0; background: transparent; font-weight: 700; color: var(--ink); padding: 4px; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin-bottom: 14px; }
.card.flat { margin-bottom: 0; }
.panel-dark { background: var(--dark); color: var(--dark-ink); border-radius: var(--radius); padding: 20px; position: relative; overflow: hidden; }
.panel-dark::after { content: ""; position: absolute; right: -40px; bottom: -40px; width: 160px; height: 160px; border-radius: 50%; border: 24px solid rgba(255,255,255,.06); pointer-events: none; }
.panel-dark > * { position: relative; z-index: 1; }
.panel-dark.clock { margin-bottom: 14px; }
.panel-dark.clock .row { margin-top: 4px; }
.times { font-size: 12px; color: var(--iron); margin-top: 4px; font-weight: 600; }
.comment { border-top: 1px solid var(--line); padding: 10px 0; font-size: 14px; }
.card h2 + .comment { border-top: 0; }
.comment .meta { font-size: 12px; color: var(--muted); margin-bottom: 4px; }
.linkbtn { background: none; border: 0; padding: 0; margin-top: 4px; font: inherit; font-size: 12px; font-weight: 700; color: var(--bad); cursor: pointer; text-decoration: underline; }
tr.click { cursor: pointer; }
tr.click:hover td { background: var(--surface); }
.clock-state { display: inline-block; font-size: 14px; font-weight: 700; background: var(--midnight); color: var(--white); border: 1px solid var(--iron); padding: 6px 12px; border-radius: 999px; margin-bottom: 14px; }
.panel-dark .k { font-size: 12px; color: var(--dark-muted); text-transform: uppercase; letter-spacing: .6px; font-weight: 700; }
.panel-dark .v { font-size: 20px; font-weight: 800; margin: 6px 0 4px; line-height: 1.25; }
.panel-dark .s { font-size: 13px; color: var(--dark-muted); margin-bottom: 14px; }

.filters h3 { font-size: 15px; margin: 0 0 10px; display: flex; justify-content: space-between; }
.filters .group { font-size: 12px; color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: .5px; margin: 14px 0 6px; }
.check { display: flex; align-items: center; gap: 10px; font-size: 14px; padding: 5px 0; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--ink); margin: 0; }
.check .n { margin-left: auto; color: var(--muted); font-size: 12px; }

/* ---------- job cards ---------- */
.jobgrid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.jobcard { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 8px; display: flex; flex-direction: column; text-decoration: none; color: inherit; transition: transform .12s, box-shadow .12s; }
.jobcard:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(26,26,26,.10); }
.jobcard .tint { border-radius: 13px; padding: 14px; flex: 1; }
.jobcard .top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.chip-date { background: #fff; border-radius: 999px; padding: 5px 11px; font-size: 12px; font-weight: 700; }
.dot { width: 30px; height: 30px; border-radius: 50%; background: #fff; display: grid; place-items: center; }
.dot i { width: 10px; height: 10px; border-radius: 50%; display: block; }
.jobcard .venue { font-size: 13px; font-weight: 600; color: var(--iron); }
.jobcard .title { font-size: 19px; font-weight: 800; line-height: 1.2; margin: 4px 0 14px; letter-spacing: -.2px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { border: 1px solid rgba(26,26,26,.16); border-radius: 999px; padding: 3px 10px; font-size: 12px; font-weight: 600; background: rgba(255,255,255,.6); }
.jobcard .bottom { display: flex; justify-content: space-between; align-items: center; padding: 12px 8px 6px; gap: 10px; }
.jobcard .big { font-size: 18px; font-weight: 800; }
.jobcard .small { font-size: 12px; color: var(--muted); }
.meter { height: 6px; background: var(--line); border-radius: 999px; overflow: hidden; margin-top: 6px; width: 110px; }
.meter b { display: block; height: 100%; background: var(--ink); border-radius: 999px; }

/* ---------- buttons, forms ---------- */
label { display: block; font-size: 13px; font-weight: 700; margin: 12px 0 5px; }
input, textarea, select { width: 100%; font: inherit; padding: 11px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fff; color: var(--ink); }
input:focus, textarea:focus, select:focus { outline: 2px solid var(--iron); outline-offset: 0; border-color: transparent; }
textarea { min-height: 80px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; font: inherit; font-weight: 700; font-size: 14px; padding: 10px 16px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--ink); cursor: pointer; text-decoration: none; white-space: nowrap; }
.btn:hover { border-color: var(--fog); }
.btn:disabled { opacity: .55; cursor: default; }
.btn.dark { background: var(--ink); color: #fff; border-color: var(--ink); }
.btn.primary { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.btn.ok { background: var(--ok); color: #fff; border-color: var(--ok); }
.btn.danger { color: var(--bad); border-color: #E3C9C5; }
.btn.light { background: rgba(255,255,255,.1); color: #fff; border-color: var(--dark-line); }
.btn.big { width: 100%; padding: 15px; font-size: 17px; }
.btn.sm { padding: 6px 12px; font-size: 13px; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.spread { justify-content: space-between; }

/* ---------- status pills ---------- */
.pill { display: inline-block; font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; white-space: nowrap; }
.pill.confirmed { background: var(--info-bg); color: var(--info); }
.pill.checked_in { background: var(--ok-bg); color: var(--ok); }
.pill.standby { background: var(--warn-bg); color: var(--warn); }
.pill.dropped, .pill.no_show { background: var(--bad-bg); color: var(--bad); }
.pill.pending { background: var(--black); color: var(--white); }
.pill.declined { background: var(--tint-3); color: var(--smoke); }
.review-tag { background: var(--black) !important; color: var(--white); border-color: var(--black) !important; }
.grid.home-org { grid-template-columns: minmax(240px, 300px) minmax(0, 1fr); align-items: start; }
@media (max-width: 760px) { .grid.home-org { grid-template-columns: 1fr; } }
.card.review .eoi { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 10px 0; border-top: 1px solid var(--line); }
.card.review .eoi .person { flex: 1; min-width: 220px; }
.card.review .eoi:first-of-type { margin-top: 10px; }
.review-btns { gap: 6px; }
.pill.risk { background: var(--bad); color: #fff; }
.pill.lastmin { background: var(--black); color: var(--white); }
.pill.neutral { background: var(--tint-5); color: var(--iron); }

/* ---------- job dashboard ---------- */
.hero { border-radius: var(--radius); padding: 22px; margin-bottom: 16px; }
.hero .title { font-size: 26px; font-weight: 800; letter-spacing: -.3px; margin: 8px 0 4px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 10px; margin: 12px 0; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 12px; }
.stat b { display: block; font-size: 22px; font-weight: 800; }
.stat span { font-size: 12px; color: var(--muted); font-weight: 600; }
.hero .stat { background: rgba(255,255,255,.65); border-color: transparent; }
.sharebox { display: flex; gap: 8px; flex-wrap: wrap; }
.sharebox input { flex: 1; min-width: 200px; background: var(--surface); }
.sectionhead { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
th { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; }
.table-wrap { overflow-x: auto; }
.person { display: flex; align-items: center; gap: 10px; }
.person .ini { width: 34px; height: 34px; border-radius: 50%; background: var(--tint-5); display: grid; place-items: center; font-weight: 800; font-size: 12px; flex: none; }

/* ---------- job form ---------- */
.pos-row { display: grid; grid-template-columns: 2fr 1fr 1fr 90px 40px; gap: 8px; align-items: end; padding: 10px; background: var(--surface); border-radius: var(--radius-sm); margin-bottom: 8px; }
.pos-row label { margin-top: 0; }

/* ---------- worker pages ---------- */
.narrow { max-width: 560px; margin: 0 auto; }
.notice { background: var(--info-bg); color: var(--midnight); border-radius: var(--radius-sm); padding: 12px 14px; font-size: 14px; margin-bottom: 14px; }
.notice.warn { background: var(--warn-bg); color: #5A4512; }
.boarding { background: var(--surface); border: 2px dashed var(--line); border-radius: var(--radius); padding: 18px; text-align: center; }
.boarding .big { font-size: 28px; font-weight: 800; margin: 6px 0; }
.option { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; margin: 10px 0; }
.empty { color: var(--muted); text-align: center; padding: 28px; }
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); background: var(--dark); color: #fff; padding: 11px 18px; border-radius: 999px; font-size: 14px; font-weight: 600; z-index: 30; max-width: calc(100% - 32px); }
.mail { font-size: 13px; background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--brand); padding: 10px 14px; margin: 8px 0; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.mail .meta { color: var(--muted); font-size: 12px; }
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }

svg.i { vertical-align: -3px; flex: none; }

/* ---------- people: photos, badges ---------- */
.ava { border-radius: 50%; object-fit: cover; flex: none; background: var(--tint-3); display: block; }
.ini { border-radius: 50%; background: var(--tint-3); color: var(--iron); display: grid; place-items: center; font-weight: 800; font-size: 13px; flex: none; }
.rel-badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 9px; border-radius: 999px; white-space: nowrap; vertical-align: 1px; }
.rel-badge.top { background: var(--ok-bg); color: var(--ok); }
.rel-badge.reliable { background: var(--info-bg); color: var(--midnight); }
.rel-badge.watch { background: var(--bad-bg); color: var(--bad); }
.rel-badge.new { background: transparent; color: var(--smoke); border: 1px solid var(--line); }

/* ---------- worker home ---------- */
.profile-head { display: flex; align-items: center; gap: 14px; }
.rel-card { border-radius: var(--radius); padding: 16px 18px; margin-bottom: 4px; background: var(--black); color: var(--white); }
.rel-card .k { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .6px; color: var(--dark-muted); }
.rel-card .score { font-size: 40px; font-weight: 800; line-height: 1; }
.rel-card .tierline { font-size: 14px; margin-top: 6px; color: var(--fog); }
.rel-card .when { font-size: 14px; font-weight: 800; color: var(--white); background: var(--iron); padding: 3px 10px; border-radius: 999px; }
.rel-card .next-title { font-size: 22px; font-weight: 800; color: var(--white); margin-top: 8px; line-height: 1.2; }
.rel-card .next-status { display: inline-block; margin-top: 12px; font-size: 13px; font-weight: 700; color: var(--black); background: var(--white); padding: 4px 12px; border-radius: 999px; }
.jump-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 14px; }
.jump { display: flex; align-items: center; gap: 10px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; text-decoration: none; color: var(--ink); font-weight: 700; }
.jump:hover { border-color: var(--fog); }
.jump .n { font-size: 22px; font-weight: 800; }
.jump svg { margin-left: auto; color: var(--smoke); }
.seg { display: flex; background: var(--line); border-radius: 999px; padding: 4px; gap: 4px; }
.seg a { flex: 1; text-align: center; padding: 9px 12px; border-radius: 999px; text-decoration: none; color: var(--iron); font-weight: 700; font-size: 14px; display: flex; align-items: center; justify-content: center; gap: 8px; }
.seg a.on { background: var(--card); color: var(--ink); box-shadow: 0 1px 3px rgba(26,26,26,.12); }
.seg .count { height: 22px; min-width: 24px; font-size: 12px; padding: 0 7px; }
.rules { margin: 10px 0 0; padding-left: 18px; color: var(--iron); font-size: 14px; display: grid; gap: 6px; }
.rel-card.top .score { color: #9FD8B8; }
.rel-card.watch .score { color: #F0B2A9; }
.shift-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); text-decoration: none; color: inherit; }
.card h2 + .shift-row, .card > .shift-row:first-child { border-top: 0; }
.crew-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }

/* ---------- profile form ---------- */
.photo-pick { display: flex; align-items: center; gap: 16px; margin-bottom: 6px; }
.photo-pick > div { min-width: 0; flex: 1; }
.photo-pick .btn { white-space: normal; text-align: left; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { margin: 0; font-weight: 600; cursor: pointer; }
.chip input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.chip span { display: inline-block; border: 1px solid var(--line); border-radius: 999px; padding: 7px 14px; font-size: 14px; background: #fff; }
.chip input:checked + span { background: var(--black); color: var(--white); border-color: var(--black); }
.chip input:focus-visible + span { outline: 2px solid var(--iron); outline-offset: 2px; }
.check.consent { align-items: flex-start; margin-top: 18px; padding: 12px; background: var(--surface); border-radius: var(--radius-sm); font-weight: 600; }
.check.consent input { margin-top: 2px; flex: none; }
.fb-field .ico { display: grid; place-items: center; }
.ftoggle { display: none; }
@media (max-width: 860px) {
  .ftoggle { display: inline-flex; }
  .layout { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .filters { display: none; }
  .filters.open { display: block; }
}
@media (max-width: 600px) {
  .topbar { padding: 12px 16px; }
  .filterbar { padding: 12px 16px 14px; }
  main { padding: 16px; }
  .pos-row { grid-template-columns: 1fr 1fr; }
  .pos-row .pos-name { grid-column: 1 / -1; }
  .hero .title { font-size: 22px; }
  #nav { flex-wrap: nowrap; gap: 2px; }
  #nav a { padding: 7px 8px; font-size: 13px; }
  #nav select { padding: 6px 8px; font-size: 13px; }
  .brand { font-size: 16px; gap: 8px; }
  .avatar { display: none; }
}

/* ---------- organiser header: compact on phones ---------- */
.topbar { min-width: 0; }
.topbar .brand { flex: none; }
#nav { min-width: 0; flex-wrap: nowrap; }
.nav-links { display: flex; gap: 4px; align-items: center; }
.menu-btn { display: none; background: var(--dark-2); color: #fff; border: 1px solid var(--dark-line); border-radius: 999px; padding: 7px 14px; font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
#nav .bell-wrap { margin-left: 6px; }
#nav a.avatar.org { display: grid; width: 34px; height: 34px; flex: none; }
@media (max-width: 720px) {
  .menu-btn { display: inline-block; }
  .nav-links { display: none; position: absolute; top: calc(100% + 1px); right: 0; left: 0; flex-direction: column; align-items: stretch; gap: 2px;
    background: var(--dark); border-bottom: 1px solid var(--dark-line); padding: 8px 16px 14px; z-index: 30; }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 14px !important; font-size: 16px !important; border-radius: 12px !important; }
  #nav a.cta { text-align: center; margin-top: 6px; }
  #nav { gap: 6px; }
}
body { overflow-x: hidden; }

/* ---------- organiser home: Organiser · Staff · CLAI ---------- */
.home-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 8px; align-items: stretch; }
.home-card { display: flex; flex-direction: column; margin: 0; }
.home-card .k { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .6px; color: var(--iron); }
.panel-dark.home-card .k { color: var(--dark-muted); }
.home-card .v { font-size: 20px; font-weight: 800; margin: 8px 0 4px; line-height: 1.25; }
.home-card .s { font-size: 14px; color: var(--muted); margin-bottom: 16px; flex: 1; }
.panel-dark.home-card .s { color: var(--dark-muted); }
.home-card .row { gap: 8px; flex-wrap: wrap; }
@media (max-width: 900px) { .home-cards { grid-template-columns: 1fr; } }

/* ---------- edit / delete, candidate approval ---------- */
.rec-btns { gap: 6px; margin-top: 8px; flex-wrap: nowrap; }
.rec-inline .rec-btns { margin-top: 0; }
.cand-foot { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; flex-wrap: wrap; margin-top: 14px; }
.cand-foot .contact-btns { gap: 6px; flex-wrap: wrap; }
.approve-box { margin-left: auto; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
@media (max-width: 600px) { .cand-foot { flex-direction: column; align-items: stretch; } .approve-box { margin-left: 0; justify-content: stretch; } .approve-box .btn { flex: 1; justify-content: center; } }
dialog.form-dialog { border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; width: min(460px, calc(100vw - 32px)); max-height: calc(100vh - 32px); overflow-y: auto; color: var(--ink); background: var(--card); }
dialog.form-dialog::backdrop { background: rgba(26,26,26,.45); }
dialog.form-dialog label { display: block; margin-top: 10px; }
dialog.form-dialog .form-err { margin: 12px 0 0; }

/* ---------- sign in / sign up ---------- */
.auth-form { text-align: left; margin-top: 4px; }
.auth-form label { display: block; margin-top: 12px; }
.auth-form .form-err { margin: 12px 0 0; }
.small-link { font-size: 13px; color: var(--iron); font-weight: 700; }
.auth-switch { text-align: center; margin: 18px 0 0; font-size: 15px; }
.auth-switch a { color: var(--ink); font-weight: 800; }
.login .notice { margin-bottom: 14px; }

/* ---------- CLAI ---------- */
.clai { display: flex; flex-direction: column; gap: 12px; }
.clai-log { max-height: 60vh; min-height: 200px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; padding: 4px; }
.clai-msg { max-width: 100%; border-radius: 14px; padding: 12px 14px; font-size: 15px; line-height: 1.45; }
.clai-msg.me { align-self: flex-end; background: var(--black); color: var(--white); max-width: 80%; }
.clai-msg.bot { align-self: flex-start; background: var(--surface); border: 1px solid var(--line); width: 100%; }
.clai-msg p { margin: 0 0 8px; } .clai-msg p:last-child { margin: 0; }
.clai-msg ul { margin: 6px 0 0; padding-left: 20px; }
.clai-msg table { margin-top: 6px; }
.clai-msg tfoot td { border-top: 2px solid var(--ink); }
.clai-warn { color: var(--bad); margin-top: 10px !important; }
.clai-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip-btn { border: 1px solid var(--fog); background: var(--white); border-radius: 999px; padding: 6px 12px; font: inherit; font-size: 13px; cursor: pointer; }
.chip-btn:hover { border-color: var(--iron); }
.clai-form { display: flex; gap: 8px; }
.clai-form input { flex: 1; min-width: 0; }
.home-card > .btn { align-self: flex-start; }

/* ---------- enquiry attachment ---------- */
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.attach .label { display: block; font-weight: 700; font-size: 14px; }
.attach .helper { margin: 2px 0 8px; color: var(--muted); font-size: 14px; }
.attach-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.upload-btn { background: #fff; color: #000; border: 1.5px solid #000; border-radius: 8px; font-weight: 700; }
.attach-name { font-size: 14px; font-weight: 600; word-break: break-all; }
.linkish { background: none; border: 0; padding: 0; font: inherit; font-weight: 700; text-decoration: underline; cursor: pointer; color: inherit; }
.account-offer { margin-top: 16px; padding: 18px; border: 1px solid #000; border-radius: 8px; background: #fff; }
.account-offer p { margin: 0 0 12px; }
.back-link { color: inherit; font-weight: 700; }
.hp-done h3 { font-size: 20px; line-height: 1.35; }
.company-form { margin-top: 0; }

/* ---------- manager: account indicator ---------- */
.acct { display: inline-block; font-size: 12px; font-weight: 700; color: var(--muted); }
.acct.on { color: var(--ok, #2f7d4f); }
.provider-box { margin-top: 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 14px; }
.provider-box summary { cursor: pointer; font-weight: 700; }
.pos-row .pos-extra { grid-column: 1 / -1; display: grid; grid-template-columns: 150px 150px minmax(0, 1fr); gap: 8px; }
@media (max-width: 600px) { .pos-row .pos-extra { grid-template-columns: 1fr 1fr; } .pos-row .pos-extra > :last-child { grid-column: 1 / -1; } }

/* ---------- worker: Available jobs ---------- */
.job-filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.job-filters select { width: auto; min-width: 150px; flex: 1; }
.date-filter { display: flex; align-items: center; gap: 6px; margin: 0; font-weight: 600; font-size: 14px; }
.date-filter input { width: auto; }
.job-row { display: flex; gap: 12px; justify-content: space-between; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.job-row:last-child { border-bottom: 0; }
.job-main { min-width: 0; flex: 1; }
.job-role { font-size: 17px; }
.job-facts { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 6px; font-size: 14px; }
.job-act { flex: none; }
.applied { display: inline-flex; gap: 6px; align-items: center; font-size: 13px; font-weight: 700; color: var(--iron); text-decoration: none; }
.provider-note { margin-top: 6px; font-size: 13px; font-weight: 600; color: var(--iron); }
@media (max-width: 600px) { .job-row { flex-direction: column; align-items: stretch; } .job-act .btn { width: 100%; justify-content: center; } }
.show-sm { display: none !important; }
@media (max-width: 600px) { .hide-sm { display: none !important; } .show-sm { display: inline-block !important; } #nav a.avatar { display: grid; } }
.req-card .kv th { width: 150px; }
.co-links { display: flex; gap: 4px; align-items: center; } @media (max-width: 400px) { .co-links a { padding: 7px 6px !important; font-size: 12px !important; } }
.btn.danger.solid { background: #C8432F; color: #fff; border-color: #C8432F; }

/* ---------- neutral sign-up: Company / Worker ---------- */
.acct-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 6px 0 14px; text-align: left; }
.acct-tab { display: flex; flex-direction: column; gap: 4px; padding: 14px; border: 1.5px solid var(--fog); border-radius: 12px; background: var(--white); cursor: pointer; font: inherit; color: var(--ink); text-align: left; }
.acct-tab b { font-size: 16px; }
.acct-tab span { font-size: 13px; color: var(--muted); line-height: 1.35; }
.acct-tab.on { border-color: var(--black); box-shadow: inset 0 0 0 1px var(--black); }
.acct-tab:focus-visible { outline: 2px solid var(--iron); outline-offset: 2px; }
@media (max-width: 420px) { .acct-tabs { grid-template-columns: 1fr; } }
.cv-field .helper, .field .helper { margin: 2px 0 8px; color: var(--muted); font-size: 14px; }
.file-msg { margin: 6px 0 0; font-size: 13px; color: var(--iron); } .file-msg.bad { color: var(--bad); font-weight: 700; } .file-msg a { font-weight: 700; }
#nav .signout-top { background: #fff; color: #000; border: 1px solid #fff; }
.done-lead { font-size: 18px; font-weight: 600; margin: 0 0 4px; }

/* ---------- requests: company overview, manager tracking ---------- */
.request-cta { width: 100%; max-width: 360px; }
.req-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.req-mini { margin: 0; display: flex; flex-direction: column; gap: 8px; }
.req-mini.needs { border: 2px solid #C8432F; }
.req-mini .btn { align-self: flex-start; }
.req-facts { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 14px; }
.req-next { font-size: 14px; } .req-next .k { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px; color: var(--iron); margin-right: 4px; }
.req-last { font-size: 13px; margin: 0; }
.gap-note { color: #C8432F; font-weight: 700; font-size: 13px; }
.history { list-style: none; padding: 0; margin: 0; }
.history li { padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.history li:last-child { border-bottom: 0; }
.history .when { color: var(--muted); font-size: 12px; font-weight: 700; display: inline-block; min-width: 120px; }
.track-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 14px; }
.track { margin: 0; display: flex; flex-direction: column; }
.track .k { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .6px; color: var(--iron); }
.track .v { font-size: 18px; font-weight: 800; margin: 6px 0 2px; }
.track .row { margin-top: auto; gap: 8px; flex-wrap: wrap; }
@media (max-width: 900px) { .track-grid { grid-template-columns: 1fr; } }
.change-review { border: 2px solid var(--black); }
.change-review tr.diff td:last-child { background: #FFF6D6; }
.req-bar { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; margin: 8px 0 4px; font-size: 14px; }

/* ---------- manager dashboard ---------- */
.attention { border: 2px solid var(--black); }
.att-list { list-style: none; padding: 0; margin: 12px 0 0; }
.att-item { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.att-item.urgent { box-shadow: inset 4px 0 0 #C8432F; padding-left: 12px; }
.att-kind { display: block; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px; color: var(--iron); }
.att-item .btn { flex: none; }
.hc-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 10px 0 14px; }
.hc-row div { background: var(--surface); border-radius: 10px; padding: 8px; text-align: center; }
.hc-row b { display: block; font-size: 22px; } .hc-row span { font-size: 12px; color: var(--muted); }
@media (max-width: 600px) { .att-item { flex-direction: column; align-items: stretch; } .att-item .btn { justify-content: center; } }

/* ---------- worker dashboard ---------- */
.wtabs { max-width: 560px; }
.wcard .k { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .6px; color: var(--iron); }
.wcard .v { font-size: 19px; font-weight: 800; margin-top: 4px; }
.wcard.offer, .offer-card { border: 2px solid var(--black); }
.venue-box { background: var(--surface); border-radius: 10px; padding: 10px 12px; margin-top: 10px; font-size: 14px; line-height: 1.6; }
.clock-elapsed { font-weight: 800; }
@media (max-width: 420px) { #nav #langSel { max-width: 84px; padding: 6px; } #nav { gap: 4px; } #nav a { padding: 7px 6px; } }

/* ---------- standby explanation (hover / focus / tap) ---------- */
.tip-wrap { position: relative; display: inline-block; }
.tip-btn { border: 0; cursor: help; font: inherit; }
.tip { display: none; position: absolute; right: 0; top: calc(100% + 6px); width: min(260px, 80vw); background: var(--black); color: #fff; font-size: 13px; font-weight: 600; line-height: 1.4; padding: 10px 12px; border-radius: 10px; z-index: 30; text-align: left; white-space: normal; }
.tip-wrap:hover .tip, .tip-btn:focus-visible + .tip, .tip-wrap.open .tip { display: block; }

/* ---------- documents ---------- */
.doc-list { list-style: none; padding: 0; margin: 0; }
.doc-list li { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.doc-list li:last-child { border-bottom: 0; }
.doc-vis { margin: 0 0 0 auto; font-size: 13px; }
.docs-card textarea { min-height: 80px; }

/* ---------- timetable ---------- */
.tt-row.focus { outline: 3px solid var(--black); }
.tt-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 10px 0 0; }
.tt-grid div { background: var(--surface); border-radius: 10px; padding: 8px; }
.tt-grid dt { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .4px; color: var(--iron); }
.tt-grid dd { margin: 2px 0 0; font-size: 15px; }
@media (max-width: 480px) { .tt-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------- mobile: keep everything on screen ---------- */
main { padding-bottom: 96px; }                      /* room above the floating site badge */
.mail { overflow-wrap: anywhere; word-break: break-word; }
.mail a { font-weight: 700; }
.mobile-only { display: none; }
details.kit summary { cursor: pointer; font-size: 13px; font-weight: 700; color: var(--iron); }
details.kit[open] summary { margin-bottom: 6px; }
@media (max-width: 720px) {
  .bell-panel { position: fixed; left: 12px; right: 12px; top: 64px; width: auto; max-height: 70vh; }
  .mobile-only { display: block; }
  /* Staff: stacked cards instead of a wide table */
  .staff-table thead { display: none; }
  .staff-table, .staff-table tbody, .staff-table tr, .staff-table td { display: block; width: 100%; }
  .staff-table tr { border: 1px solid var(--line); border-radius: 14px; padding: 12px; margin-bottom: 10px; background: var(--card); }
  .staff-table td { border: 0; padding: 4px 0; }
  .staff-table td.st-avail { display: none; }
  .staff-table td:nth-last-child(-n+2) { display: inline-block; width: auto; margin-right: 12px; font-size: 13px; color: var(--muted); }
  .staff-table .contact-btns { flex-wrap: wrap; }
  .staff-table .sub { overflow-wrap: anywhere; }
  .card.table-wrap:has(.staff-table) { background: transparent; border: 0; padding: 0; box-shadow: none; overflow: visible; }
}
.note-body { overflow-wrap: anywhere; } .note-body a { font-weight: 700; }
.wtabs { max-width: 680px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); } .wtabs a { min-width: 0; text-align: center; } @media (max-width: 520px) { .wtabs { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; } }

/* ---------- worker Overview & Profile: full dashboard width on desktop, unchanged on phones ---------- */
.desktop-only { display: block; }
@media (max-width: 720px) { .desktop-only { display: none !important; } }
@media (min-width: 721px) {
  .ov-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr); gap: 18px; align-items: start; }
  .ov-main > .card, .ov-main > .panel-dark { margin-top: 0; }
  .ov-side { display: flex; flex-direction: column; gap: 14px; }
  .ov-side > .card { margin: 0; }
  .ov-side .btn.danger { width: 100%; }
  .panel-dark.clock .v { font-size: 26px; }
  #pf .photo-pick { gap: 20px; }
}
/* Standby: same bold rounded pill as "Completed", in yellow; the ⓘ stays small. */
.pill.tip-btn { font-family: inherit; font-size: 12px; font-weight: 700; line-height: normal; padding: 3px 10px; border: 0; border-radius: 999px; cursor: help; }
.pill.tip-btn span { font-size: 11px; margin-left: 2px; }
.pill.tip-btn:focus-visible { outline: 2px solid var(--iron); outline-offset: 2px; }
.li-q { font-size: 17px; margin: 14px 0 10px; }
.back-top { margin: 0 0 12px; } .back-top a { color: var(--iron); text-decoration: none; font-weight: 700; } .back-top a:hover { text-decoration: underline; }
@media (min-width: 721px) { .ov-side .profile-head { flex-wrap: wrap; } .ov-side .profile-head > div { min-width: 120px; } .ov-side .profile-head .btn { flex-basis: 100%; justify-content: center; } }

/* ---------- worker account menu ---------- */
.acct-menu { position: relative; }
.acct-btn { display: flex; align-items: center; gap: 4px; background: none; border: 0; padding: 2px 4px 2px 2px; border-radius: 999px; color: #fff; cursor: pointer; }
.acct-btn:hover, .acct-btn[aria-expanded="true"] { background: var(--dark-2); }
.acct-btn:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.acct-btn .avatar { display: grid !important; margin-left: 0; width: 34px; height: 34px; overflow: hidden; }
.acct-btn .avatar img { width: 100%; height: 100%; object-fit: cover; }
.acct-drop { position: absolute; right: 0; top: calc(100% + 8px); min-width: 190px; background: var(--card); color: var(--ink); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 12px 32px rgba(26,26,26,.18); padding: 6px; z-index: 40; }
.acct-drop [role="menuitem"] { display: block; width: 100%; text-align: left; padding: 10px 12px; border-radius: 8px; font: inherit; font-size: 15px; font-weight: 600; color: var(--ink) !important; background: none; border: 0; cursor: pointer; text-decoration: none; }
.acct-drop [role="menuitem"]:hover, .acct-drop [role="menuitem"]:focus-visible { background: var(--surface); outline: none; }
.acct-drop #acctSignOut { color: #B3261E !important; }

/* ---------- desktop Overview cards ---------- */
.ov-empty h2 { font-size: 26px; margin: 0 0 4px; }
.ov-empty .sub { margin: 0 0 14px; font-size: 16px; }
.ov-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.ov-row h3 { margin: 0 0 6px; font-size: 18px; }
.ov-row h3.light { font-weight: 600; margin: 0; }
.ov-app { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.ov-link { flex: none; color: var(--ink); font-weight: 700; text-decoration: underline; }
.help-link { margin: 6px 4px 0; }
.help-link summary { cursor: pointer; list-style: none; text-decoration: underline; font-weight: 600; }
.help-link summary::-webkit-details-marker { display: none; }
.help-link .rules { margin-top: 8px; }
.ov-side .profile-head.compact { flex-wrap: wrap; }
.ov-side .profile-head.compact .btn { flex-basis: 100%; justify-content: center; }
.ov-main > .desktop-only > .card { margin-top: 0; }
.ov-main > .desktop-only { display: flex; flex-direction: column; gap: 14px; }
@media (max-width: 720px) { .ov-main > .desktop-only { display: none !important; } }

/* =====================================================================
   Dark mode (Light / Dark toggle in the header; remembered in this browser)
   ===================================================================== */
.theme-toggle { margin-left: auto; margin-right: 8px; display: inline-flex; align-items: center; gap: 6px; background: transparent; color: inherit;
  border: 1px solid var(--dark-line); border-radius: 999px; padding: 6px 12px; font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
.theme-toggle svg { width: 16px; height: 16px; }
.theme-toggle:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
body.public .theme-toggle { border-color: currentColor; }
@media (max-width: 600px) { .theme-toggle .tt-label { display: none; } .theme-toggle { padding: 6px 8px; margin-right: 4px; } }

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #121212; --surface: #1E1E1E; --card: #181818; --ink: #ECECEC; --muted: #A6A6A6; --line: #333333;
  --fog: #555555; --smoke: #9C9C9C; --iron: #CFCFCF; --midnight: #E4E4E4;
  --white: #181818; --black: #ECECEC; --dark-ink: #FFFFFF; --dark-muted: #A8A8A8;
  --dark: #0A0A0A; --dark-2: #222222; --dark-line: #3A3A3A;
  --brand: #ECECEC; --brand-ink: #111111;
  --ok: #86D4A9; --ok-bg: #173023; --warn: #EAC36B; --warn-bg: #3A3018; --bad: #F29C90; --bad-bg: #3C201C;
  --info: #E4E4E4; --info-bg: #262626;
  --tint-0: #1C1C1C; --tint-1: #222222; --tint-2: #1F1F1F; --tint-3: #262626; --tint-4: #202020; --tint-5: #1A1A1A;
}
:root[data-theme="dark"] input, :root[data-theme="dark"] textarea, :root[data-theme="dark"] select { background: #141414; color: var(--ink); border-color: #3A3A3A; }
:root[data-theme="dark"] .btn { background: #202020; color: var(--ink); border-color: #3A3A3A; }
:root[data-theme="dark"] .btn.dark, :root[data-theme="dark"] .btn.primary { background: #ECECEC; color: #111; border-color: #ECECEC; }
:root[data-theme="dark"] .btn.ok { background: #86D4A9; color: #0E2A1B; border-color: #86D4A9; }
:root[data-theme="dark"] .btn.danger { color: var(--bad); border-color: #5A2C26; }
:root[data-theme="dark"] .btn.danger.solid { background: #C8432F; color: #fff; }
:root[data-theme="dark"] .btn.google { background: #202020; border-color: #3A3A3A; }
:root[data-theme="dark"] .panel-dark .btn.primary, :root[data-theme="dark"] .panel-dark .btn { background: #ECECEC; color: #111; border-color: #ECECEC; }
:root[data-theme="dark"] .panel-dark .btn.light { background: rgba(255,255,255,.08); color: #fff; border-color: #444; }
:root[data-theme="dark"] .notice.warn { color: #F1D899; }
:root[data-theme="dark"] .tag { background: rgba(255,255,255,.05); border-color: rgba(255,255,255,.18); color: var(--ink); }
:root[data-theme="dark"] .seg a.on { box-shadow: none; }
:root[data-theme="dark"] .linkish { color: var(--ink); }
:root[data-theme="dark"] a { color: var(--ink); }
:root[data-theme="dark"] .bell-panel, :root[data-theme="dark"] .acct-drop, :root[data-theme="dark"] .kebab-menu, :root[data-theme="dark"] dialog.form-dialog { background: #1C1C1C; color: var(--ink); border-color: #333; }
:root[data-theme="dark"] .tip { background: #ECECEC; color: #111; }
:root[data-theme="dark"] .change-review tr.diff td:last-child { background: #3A3018; }
:root[data-theme="dark"] .upload-btn { background: #202020; color: var(--ink); border-color: #777; }
/* public site */
:root[data-theme="dark"] body.public { background: #121212; }
:root[data-theme="dark"] body.public .topbar { background: #121212; color: #ECECEC; border-bottom-color: #444; }
:root[data-theme="dark"] body.public .brand, :root[data-theme="dark"] body.public .brand b span { color: #ECECEC; }
:root[data-theme="dark"] body.public .brand .logo { filter: invert(1); }
:root[data-theme="dark"] body.public #nav .login-btn { background: #121212; color: #ECECEC; border-color: #ECECEC; }
:root[data-theme="dark"] body.public #nav .login-btn:hover { background: #ECECEC; color: #111; }
:root[data-theme="dark"] .hp-hero p { color: #D6D6D6; }
:root[data-theme="dark"] .hp-card, :root[data-theme="dark"] .hp-form, :root[data-theme="dark"] .field input { border-color: #8A8A8A; }
:root[data-theme="dark"] .hp-btn { background: #ECECEC; color: #111; border-color: #ECECEC; }
:root[data-theme="dark"] .hp-btn:hover { background: #D0D0D0; }
:root[data-theme="dark"] .hp-done { border-left-color: #ECECEC; }
:root[data-theme="dark"] .account-offer { background: #181818; border-color: #8A8A8A; }
:root[data-theme="dark"] main.legal { background: var(--card); }
/* new bits from this update */
.jc-wrap { position: relative; }
.kebab { position: absolute; top: 10px; right: 10px; z-index: 3; }
.kebab-btn { width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--line); background: var(--card); color: var(--ink); font-size: 18px; line-height: 1; cursor: pointer; }
.kebab-menu { position: absolute; right: 0; top: 38px; min-width: 160px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 12px 32px rgba(26,26,26,.18); padding: 6px; }
.kebab-menu a { display: block; padding: 9px 12px; border-radius: 8px; color: var(--ink); font-weight: 600; text-decoration: none; }
.kebab-menu a:hover, .kebab-menu a:focus-visible { background: var(--surface); outline: none; }
.jc-wrap .jobcard .top { padding-right: 40px; }
.form-tabs { max-width: 420px; margin: 4px 0 16px; }
.draft-saved { margin: -6px 0 10px; font-size: 13px; }
.eoi-h { margin: 22px 0 10px; }
.eoi-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.eoi-card { margin: 0; }
a.eoi-card { text-decoration: none; color: var(--ink); display: block; }
.pill.eoi-badge { background: #E6E1F5; color: #4B3F7A; }
:root[data-theme="dark"] .pill.eoi-badge { background: #2C2640; color: #CFC5F2; }
.eoi-row { cursor: default; }
:root[data-theme="dark"] .brand b span { color: #8C8C8C; }
:root[data-theme="dark"] #nav a.cta { background: #ECECEC; color: #111; }
:root[data-theme="dark"] #nav .signout-top { background: #ECECEC; color: #111; border-color: #ECECEC; }
:root[data-theme="dark"] .pill.risk { background: #C8432F; }
:root[data-theme="dark"] .welcome .big-check, :root[data-theme="dark"] .login-logo { background: #ECECEC; }
:root[data-theme="dark"] .login-logo { filter: none; }
:root[data-theme="dark"] .jobcard, :root[data-theme="dark"] .mail, :root[data-theme="dark"] .chip span { background: var(--card); color: var(--ink); }
:root[data-theme="dark"] .chip-date, :root[data-theme="dark"] .dot { background: #2C2C2C; color: var(--ink); }
:root[data-theme="dark"] .count { background: #2C2C2C; color: var(--ink); }
:root[data-theme="dark"] .jobcard:hover { box-shadow: 0 8px 24px rgba(0,0,0,.5); }
:root[data-theme="dark"] select option { color: var(--ink); background: #1C1C1C; }
@media (max-width: 600px) { .topbar { gap: 8px; } .theme-toggle { margin-left: auto; margin-right: 0; width: 34px; height: 34px; padding: 0; justify-content: center; flex: none; } }
@media (max-width: 440px) { .topbar:has(#nav .acct-menu, #nav .avatar) .brand b { display: none; } }

/* =====================================================================
   November update: manager enquiries tabs + cards, role dropdown, settings,
   worker profile setup, homepage layout, slim footer + contact panel, dark mode
   ===================================================================== */
.wrap-any { overflow-wrap: anywhere; word-break: break-word; }

/* ---------- manager: Enquiries tabs (two equal tabs with count badges) ---------- */
.eq-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; background: var(--line); border-radius: 14px; padding: 4px; max-width: 560px; }
.eq-tab { min-width: 0; display: flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 12px; border: 0; border-radius: 11px;
  background: transparent; color: var(--iron); font: inherit; font-weight: 700; font-size: 14px; cursor: pointer; }
.eq-tab-label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.eq-badge { flex: none; display: inline-grid; place-items: center; min-width: 24px; height: 22px; padding: 0 7px; border-radius: 999px;
  font-size: 12px; font-weight: 800; background: var(--card); color: var(--ink); border: 1px solid var(--line); }
.eq-tab.on { background: var(--card); color: var(--ink); box-shadow: 0 1px 3px rgba(26,26,26,.14); }
.eq-tab.on .eq-badge { background: var(--ink); color: var(--card); border-color: var(--ink); }
.eq-tab:hover:not(.on) { color: var(--ink); }
.eq-tab:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.eq-tab-note { margin: 8px 0 16px; font-size: 13px; font-weight: 600; color: var(--muted); }

/* Records: table on desktop (unchanged), stacked cards on phones. */
.eq-cards { list-style: none; margin: 0; padding: 0; display: none; }
.eq-card { margin: 0 0 12px; padding: 16px; min-width: 0; }
.eq-card-title { margin: 0 0 8px; font-size: 17px; line-height: 1.3; overflow-wrap: anywhere; }
.eq-card-facts { margin: 0; display: grid; gap: 6px; }
.eq-card-facts > div { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 8px; font-size: 14px; }
.eq-card-facts dt { color: var(--muted); font-weight: 600; }
.eq-card-facts dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.eq-card-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.eq-card-foot .btn { flex: none; }
@media (max-width: 720px) {
  .eq-tabs { max-width: none; }
  .eq-tab { padding: 10px 8px; font-size: 13.5px; gap: 6px; }
  .eq-cards { display: block; padding-bottom: 88px; }   /* room so floating badges never cover the last card's actions */
  .desktop-table { display: none; }
  .eq-card-foot .btn { flex: 1 1 100%; }
}

/* ---------- role dropdown ---------- */
.role-field select { border: 1.5px solid #000; border-radius: 4px; }
.form-dialog .role-field select { border: 1px solid var(--line); border-radius: var(--radius-sm); }
.role-other { margin-top: 4px; }

/* ---------- manager: Profile and settings ---------- */
.set-sec h2 { margin: 0 0 4px; font-size: 19px; }
.set-sec > .sub { margin: 0 0 6px; }
.helper { font-size: 13px; color: var(--muted); margin: 4px 0 0; }
.set-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.tag.internal { margin-left: 6px; font-size: 11px; padding: 2px 8px; vertical-align: 1px; }
input.readonly { background: var(--surface); color: var(--iron); }
.switch { display: flex; align-items: center; gap: 10px; margin: 14px 0 0; font-size: 14px; cursor: pointer; position: relative; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch-ui { flex: none; width: 42px; height: 24px; border-radius: 999px; background: var(--fog); position: relative; transition: background .15s; }
.switch-ui::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .15s; box-shadow: 0 1px 2px rgba(0,0,0,.25); }
.switch input:checked + .switch-ui { background: var(--ink); }
.switch input:checked + .switch-ui::after { transform: translateX(18px); }
.switch input:focus-visible + .switch-ui { outline: 2px solid var(--ink); outline-offset: 2px; }
.notify-grid { margin-top: 6px; }
.ng-row { border: 0; margin: 0; padding: 0; min-width: 0; }
.ng-inner { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 8px 10px; padding: 12px 0; border-top: 1px solid var(--line); }
.ng-row:first-child .ng-inner { border-top: 0; }
.ng-label b { display: block; font-size: 14px; }
.ng-label .sub { display: block; margin: 2px 0 0; font-size: 12.5px; }
.ng-opt { display: inline-flex; align-items: center; gap: 8px; margin: 0; padding: 8px 12px; border: 1px solid var(--line); border-radius: 999px; font-size: 13px; cursor: pointer; background: var(--card); }
.ng-opt input { width: 18px; height: 18px; margin: 0; padding: 0; accent-color: var(--ink); }
.ng-opt:has(input:checked) { border-color: var(--ink); }
.ng-opt:has(input:focus-visible) { outline: 2px solid var(--ink); outline-offset: 2px; }
.id-preview { margin: 14px 0 0; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface); font-size: 13px; overflow-wrap: anywhere; }
.id-preview .k { font-weight: 800; text-transform: uppercase; font-size: 11px; letter-spacing: .5px; color: var(--muted); margin-right: 6px; }
.set-save { position: sticky; bottom: 0; z-index: 5; display: flex; align-items: center; gap: 14px; justify-content: flex-end; padding: 12px 0; background: var(--bg); }
.set-save .btn.big { width: auto; padding: 13px 28px; }
.set-status { margin: 0; font-size: 14px; font-weight: 700; color: var(--muted); }
.set-status.ok { color: var(--ok); } .set-status.bad { color: var(--bad); } .set-status.dirty { color: var(--warn); }
@media (max-width: 600px) {
  .set-pair { grid-template-columns: 1fr; }
  .ng-inner { grid-template-columns: 1fr 1fr; }
  .ng-label { grid-column: 1 / -1; }
  .ng-opt { justify-content: center; }
  .set-save { flex-direction: column-reverse; align-items: stretch; gap: 6px; padding-bottom: calc(12px + env(safe-area-inset-bottom)); }
  .set-save .btn.big { width: 100%; }
  .set-status { text-align: center; }
}

/* ---------- worker: profile setup ---------- */
.setup-missing { margin: -4px 0 14px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 14px; }
.link-card { border-color: var(--ink); }

/* ---------- homepage (signed-out) ---------- */
body.public { display: flex; flex-direction: column; min-height: 100vh; min-height: 100dvh; }
body.public main { flex: 1 0 auto; width: 100%; display: flex; flex-direction: column; padding-bottom: 0; }
.hp-hero { padding: 44px 0 28px; }
.hp-hero h1 { font-size: clamp(32px, 5.2vw, 56px); letter-spacing: -1px; }
.hp-hero p { font-size: clamp(16px, 1.7vw, 19px); max-width: 600px; margin-top: 12px; line-height: 1.5; text-wrap: balance; }
.hp-cards { gap: 20px; }
.hp-card { border: 1px solid #DCDCDC; border-radius: 16px; padding: 28px 30px; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.04); }
.hp-card h2 { font-size: clamp(22px, 2.4vw, 30px); }
.hp-card > p { font-size: 16px; margin: 10px 0 22px; color: #333; }
.hp-actions { margin-top: auto; width: 100%; }
.hp-note { margin: 10px 0 0; font-size: 14px; color: #555; }
.hp-note a { color: inherit; font-weight: 700; }
.hp-btn { border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; font-size: 17px; padding: 13px 24px; }
.hp-form { border: 1px solid #DCDCDC; border-radius: 16px; margin-top: 20px; }
.hp-form .hp-switch a { color: inherit; font-weight: 700; }
.hp-btn:focus-visible, body.public #nav .login-btn:focus-visible, .theme-toggle:focus-visible, .contact-btn:focus-visible, .contact-mail:focus-visible,
.site-foot a:focus-visible, .hp-note a:focus-visible, .brand:focus-visible { outline: 3px solid #000; outline-offset: 3px; border-radius: 6px; }
body.public .theme-toggle { width: 40px; height: 40px; padding: 0; justify-content: center; border-radius: 50%; margin-right: 10px; border-color: #CFCFCF; }
body.public .theme-toggle .tt-label { display: none; }
@media (max-width: 760px) {
  .hp-hero { padding: 28px 0 20px; }
  .hp-card { padding: 22px 20px; }
  .hp-btn { width: 100%; }
  body.public .theme-toggle { width: 36px; height: 36px; margin-right: 8px; }
}

/* ---------- slim footer + Contact panel ---------- */
.site-foot { margin-top: auto; padding: 22px 0 18px; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 10px; font-size: 13px; color: var(--muted); }
body.public .site-foot { padding-top: 32px; padding-bottom: calc(18px + env(safe-area-inset-bottom)); }
.site-foot a { color: var(--iron); }
.contact-wrap { position: relative; display: inline-flex; }
.contact-btn { background: none; border: 0; padding: 2px 0; font: inherit; color: var(--iron); text-decoration: underline; cursor: pointer; }
.contact-panel { position: absolute; bottom: calc(100% + 10px); left: 50%; transform: translateX(-50%); z-index: 30; padding: 10px; background: var(--card);
  border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,.16); white-space: nowrap; }
.contact-panel::after { content: ""; position: absolute; top: 100%; left: 50%; margin-left: -6px; border: 6px solid transparent; border-top-color: var(--card); }
.contact-mail { display: inline-flex; align-items: center; justify-content: center; padding: 10px 18px; border-radius: 10px; background: #000; color: #fff !important;
  font-weight: 800; font-size: 14px; text-decoration: none; }
.contact-mail:hover { background: #262626; }

/* ---------- dark mode: charcoal page, slightly lighter cards, subtle borders, off-white text ---------- */
:root[data-theme="dark"] body.public { background: #1C1C1E; color: #F2F2EF; }
:root[data-theme="dark"] body.public .topbar { background: #1C1C1E; color: #F2F2EF; border-bottom-color: #34343A; }
:root[data-theme="dark"] body.public .brand, :root[data-theme="dark"] body.public .brand b span { color: #F2F2EF; }
:root[data-theme="dark"] body.public #nav .login-btn { background: transparent; color: #F2F2EF; border-color: #F2F2EF; }
:root[data-theme="dark"] body.public #nav .login-btn:hover { background: #F2F2EF; color: #1C1C1E; }
:root[data-theme="dark"] body.public .theme-toggle { border-color: #4A4A50; color: #F2F2EF; }
:root[data-theme="dark"] .hp-hero p { color: #D4D4D0; }
:root[data-theme="dark"] .hp-card, :root[data-theme="dark"] .hp-form { background: #26262A; border-color: #3A3A40; box-shadow: none; color: #F2F2EF; }
:root[data-theme="dark"] .hp-card > p { color: #D4D4D0; }
:root[data-theme="dark"] .hp-note, :root[data-theme="dark"] .hp-switch { color: #BDBDB8; }
:root[data-theme="dark"] .hp-btn, :root[data-theme="dark"] .contact-mail { background: #F2F2EF; color: #1C1C1E !important; border-color: #F2F2EF; }
:root[data-theme="dark"] .hp-btn:hover, :root[data-theme="dark"] .contact-mail:hover { background: #DADAD5; }
:root[data-theme="dark"] .field input, :root[data-theme="dark"] .role-field select { border-color: #55555C; background: #1C1C1E; }
:root[data-theme="dark"] .account-offer { background: #1F1F22; border-color: #3A3A40; }
:root[data-theme="dark"] .site-foot, :root[data-theme="dark"] .site-foot a, :root[data-theme="dark"] .contact-btn { color: #C8C8C3; }
:root[data-theme="dark"] .contact-panel { background: #2C2C31; border-color: #44444A; box-shadow: 0 10px 30px rgba(0,0,0,.5); }
:root[data-theme="dark"] .contact-panel::after { border-top-color: #2C2C31; }
:root[data-theme="dark"] .hp-btn:focus-visible, :root[data-theme="dark"] body.public #nav .login-btn:focus-visible, :root[data-theme="dark"] .theme-toggle:focus-visible,
:root[data-theme="dark"] .contact-btn:focus-visible, :root[data-theme="dark"] .contact-mail:focus-visible, :root[data-theme="dark"] .site-foot a:focus-visible,
:root[data-theme="dark"] .hp-note a:focus-visible, :root[data-theme="dark"] .brand:focus-visible, :root[data-theme="dark"] .eq-tab:focus-visible { outline-color: #F2F2EF; }
:root[data-theme="dark"] .eq-tab.on { background: #ECECEC; color: #111; }
:root[data-theme="dark"] .eq-tab.on .eq-badge { background: #111; color: #ECECEC; border-color: #111; }
:root[data-theme="dark"] .eq-badge { background: #2C2C2C; border-color: #3A3A3A; }
:root[data-theme="dark"] .switch input:not(:checked) + .switch-ui { background: #444; }
:root[data-theme="dark"] .switch input:checked + .switch-ui::after { background: #111; }

/* ===== Team permissions (owner) ===== */
.profile-head { position: relative; }
.perm-corner { position: absolute; top: 14px; right: 14px; display: flex; align-items: center; gap: 8px; }
.profile-head:has(.perm-corner) h1 { padding-right: 260px; }
.access-pill { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700;
  border: 1px solid var(--line); background: var(--surface); color: var(--iron); white-space: nowrap; vertical-align: middle; }
.access-pill.team { background: var(--ink); color: var(--card); border-color: var(--ink); }
.perm-mobile-pill { display: none; }
.wp-menu { display: none; position: relative; }
.wp-menu-list { position: absolute; left: 0; top: calc(100% + 6px); z-index: 30; min-width: 220px; background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius-sm); box-shadow: 0 8px 24px rgba(0,0,0,.12); padding: 6px; display: flex; flex-direction: column; }
.wp-menu-list[hidden] { display: none; }
.wp-menu-list button { text-align: left; background: none; border: 0; padding: 10px 12px; border-radius: 8px; font: inherit; font-size: 14px; color: var(--ink); cursor: pointer; }
.wp-menu-list button:hover, .wp-menu-list button:focus-visible { background: var(--surface); }
.wp-menu-list button.danger { color: var(--bad); }
@media (max-width: 640px) {
  .perm-corner, .wp-desk-actions { display: none; }
  .profile-head:has(.perm-corner) h1 { padding-right: 0; }
  .perm-mobile-pill { display: inline; }
  .wp-menu { display: inline-block; }
  .profile-head { flex-wrap: wrap; align-items: flex-start; }
}
dialog.perm-dialog { width: min(560px, calc(100vw - 32px)); }
.perm-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.perm-list li { border-bottom: 1px solid var(--line); }
dialog.perm-dialog label.perm-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin: 0; padding: 12px 2px; cursor: pointer; }
.perm-row .switch { margin: 0; flex: none; }
.perm-row input:disabled + .switch-ui { opacity: .45; }
.perm-actions { margin-top: 16px; gap: 8px; flex-wrap: wrap; }
.perm-hist { margin-top: 14px; font-size: 13px; }
.perm-hist summary { cursor: pointer; font-weight: 700; }
.perm-hist ul { margin: 8px 0 0; padding-left: 18px; }
.perm-hist li { margin-bottom: 6px; }
.field-err { color: var(--bad); font-size: 13px; margin: 10px 0 0; }
.team-link { font-weight: 700; }
/* Bell: each notification opens its record */
a.note { display: block; color: inherit; text-decoration: none; }
a.note:hover, .note[tabindex]:hover { background: var(--surface); }
a.note:focus-visible, .note[tabindex]:focus-visible { outline: 2px solid var(--ink); outline-offset: -2px; }
:root[data-theme="dark"] .wp-menu-list { background: #1C1C1C; border-color: #333; }
:root[data-theme="dark"] dialog.perm-dialog { background: #1C1C1C; }
#nav .bell-panel a.note { display: block; color: var(--ink); font-size: inherit; font-weight: 400; padding: 12px 16px; border-radius: 0; background: none; }
#nav .bell-panel a.note.unread { background: var(--surface); }
#nav .bell-panel a.note:hover { color: var(--ink); background: var(--surface); }
#nav .bell-panel .note-body a { padding: 0; border-radius: 0; color: inherit; font-size: inherit; }

/* ---------- desktop dashboard calendar (hidden on phones via .desktop-only) ---------- */
@media (min-width: 721px) {
  .dash-grid { display: grid; grid-template-columns: minmax(250px, 300px) minmax(0, 1fr); gap: 16px; align-items: start; margin-top: 8px; }
  .dash-grid .home-cards { grid-template-columns: 1fr; gap: 10px; margin: 0; }
  .dash-grid .home-card { padding: 14px 16px; }
  .dash-grid .home-card .v { font-size: 17px; margin: 4px 0 2px; }
  .dash-grid .home-card .s { font-size: 13px; margin-bottom: 10px; }
  .dash-grid .home-card .hc-row { margin: 6px 0 10px; }
  .dash-grid .cal { margin: 0; }
}
.cal { padding: 14px 16px; }
.cal-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.cal-head h2 { font-size: 17px; margin: 0; }
.cal-nav { display: flex; align-items: center; gap: 6px; }
.cal-nav .btn { min-width: 34px; justify-content: center; }
.cal-month { min-width: 130px; text-align: center; font-size: 15px; }
.cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.cal-wd { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); padding: 5px 6px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.cal-day { min-height: 84px; padding: 4px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.cal-day.out { background: var(--tint-5); }
.cal-day.past .cal-n { color: var(--muted); }
.cal-n { font-size: 12px; font-weight: 700; align-self: flex-end; width: 22px; height: 22px; display: grid; place-items: center; border-radius: 50%; }
.cal-day.today .cal-n { background: var(--black); color: var(--white); }
.cal-ev { display: block; text-decoration: none; color: var(--ink); background: var(--tint-5); border-left: 3px solid var(--fog); border-radius: 4px; padding: 3px 5px; font-size: 11.5px; line-height: 1.3; min-width: 0; }
#app .cal-ev, .cal-ev:visited { color: var(--ink); }
.cal-ev:hover { background: var(--tint-3); }
.cal-ev:focus-visible, .cal-more:focus-visible { outline: 2px solid var(--iron); outline-offset: 1px; }
.cal-ev > span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-st { font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .4px; }
.cal-t { font-weight: 700; }
.cal-s { color: var(--muted); }
.cal-ev.t-checked_in { border-left-color: var(--ok); } .cal-ev.t-checked_in .cal-st { color: var(--ok); }
.cal-ev.t-standby { border-left-color: var(--warn); } .cal-ev.t-standby .cal-st { color: var(--warn); }
.cal-ev.t-risk, .cal-ev.t-dropped, .cal-ev.t-no_show { border-left-color: var(--bad); } .cal-ev.t-risk .cal-st, .cal-ev.t-dropped .cal-st { color: var(--bad); }
.cal-ev.t-confirmed, .cal-ev.t-pending { border-left-color: var(--black); }
.cal-ev.t-declined { border-left-style: dashed; } .cal-ev.t-declined .cal-st { color: var(--muted); }
.cal-more { background: none; border: 0; padding: 2px 4px; font: inherit; font-size: 11.5px; font-weight: 700; color: var(--iron); text-align: left; cursor: pointer; text-decoration: underline; }
.cal-empty { margin: 10px 0 0; }
.cal-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; min-width: min(420px, 80vw); }
.cal-list a { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; text-decoration: none; color: var(--ink); }
.cal-list a:hover { background: var(--tint-5); }
.cal-list .sub { flex-basis: 100%; margin: 0; }
.ov-main .cal { margin-bottom: 14px; }
@media (min-width: 721px) {
  /* Manager dashboard: keep Needs attention short (it scrolls) so the cards and calendar fit on one desktop screen. */
  .attention { padding: 12px 18px; margin-bottom: 12px; }
  .attention .att-list { max-height: 196px; overflow-y: auto; margin-top: 8px; padding-right: 4px; }
  .attention .att-item { padding-top: 8px; padding-bottom: 8px; }
  .dash-grid .cal-day { min-height: 68px; }
}
@media (min-width: 721px) {
  /* Next job card with no upcoming jobs: title at the top, "+ New job" at the bottom-left like the Jobs and Staff buttons. */
  .dash-grid .home-card:has(.hc-new) { min-height: 150px; }
  .dash-grid .home-card .hc-new { margin-top: auto; align-self: flex-start; }
}

/* ---------- worker ID (phones only) ---------- */
.acct-drop .id-item { display: none; }
@media (max-width: 720px) { .acct-drop .id-item { display: block; } }
dialog.id-dialog { width: min(340px, calc(100vw - 32px)); padding: 18px; }
.id-card { border-radius: 18px; background: var(--dark); color: #fff; padding: 20px 18px 18px; text-align: center; position: relative; overflow: hidden; }
.id-card::after { content: ''; position: absolute; right: -60px; top: -60px; width: 180px; height: 180px; border-radius: 50%; border: 22px solid rgba(255,255,255,.06); }
.id-top { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 15px; justify-content: flex-start; }
.id-logo { width: 22px; height: 22px; filter: invert(1); }
/* The card stays dark in both themes, so the logo is shown inverted (white square) in both. */
.id-photo { width: 112px; height: 112px; border-radius: 50%; margin: 18px auto 12px; overflow: hidden; background: #2a2a2a; border: 3px solid #fff; display: grid; place-items: center; }
.id-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.id-photo span { font-size: 38px; font-weight: 800; color: #fff; }
.id-card h2 { margin: 0; font-size: 22px; color: #fff; overflow-wrap: anywhere; }
.id-role { margin: 4px 0 16px; font-size: 13px; font-weight: 700; letter-spacing: .6px; text-transform: uppercase; color: #BDBDBD; }
.id-no { background: #fff; color: #111; border-radius: 12px; padding: 10px; display: flex; flex-direction: column; gap: 2px; }
.id-no span { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .6px; color: #555; }
.id-no b { font-size: 26px; letter-spacing: 3px; font-variant-numeric: tabular-nums; }
.member-line b { color: var(--ink); letter-spacing: 1px; }

/* ---------- floating CLAI (desktop manager dashboard) ---------- */
.clai-fab { position: fixed; z-index: 60; display: flex; align-items: stretch; background: var(--black); color: var(--white); border-radius: 14px;
  box-shadow: 0 6px 20px rgba(0,0,0,.22); transition: left .18s ease, top .18s ease; }
.clai-fab.dragging { transition: none; box-shadow: 0 10px 28px rgba(0,0,0,.3); }
.clai-grip { width: 16px; border: 0; background: none; color: inherit; cursor: grab; padding: 0 0 0 4px; touch-action: none; display: grid; place-items: center; border-radius: 14px 0 0 14px; }
.clai-fab.dragging .clai-grip { cursor: grabbing; }
.clai-grip span { width: 6px; height: 16px; background-image: radial-gradient(currentColor 1.1px, transparent 1.3px); background-size: 3px 4px; opacity: .65; }
.clai-bot { width: 44px; height: 48px; border: 0; background: none; color: inherit; display: grid; place-items: center; cursor: pointer; border-radius: 0 14px 14px 0; padding: 0 6px 0 2px; }
.clai-grip:focus-visible, .clai-bot:focus-visible { outline: 2px solid var(--black); outline-offset: 3px; }
.clai-pop { position: fixed; z-index: 61; width: 330px; background: var(--card); color: var(--ink); border: 1px solid var(--line); border-radius: 16px;
  box-shadow: 0 12px 36px rgba(0,0,0,.2); display: flex; flex-direction: column; overflow: hidden; }
.clai-pop[hidden] { display: none; }
.clai-pop header { display: flex; align-items: center; gap: 8px; padding: 10px 10px 10px 14px; border-bottom: 1px solid var(--line); }
.clai-pop header h2 { font-size: 16px; margin: 0; }
.clai-pop header .sub { margin: 0; font-size: 12px; flex: 1; }
.clai-pop-ico { width: 28px; height: 28px; border-radius: 8px; background: var(--black); color: var(--white); display: grid; place-items: center; }
.clai-pop-ico svg { width: 18px; height: 18px; }
.clai-x { border: 0; background: none; color: var(--ink); width: 32px; height: 32px; border-radius: 8px; cursor: pointer; font-size: 15px; }
.clai-x:hover { background: var(--tint-5); }
.clai-pop-log { flex: 1; min-height: 140px; overflow-y: auto; padding: 12px; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.clai-pop-log .clai-msg { font-size: 13.5px; padding: 9px 11px; }
.clai-pop-log .clai-msg.me { align-self: flex-end; }
.clai-pop-log .clai-msg table { font-size: 12.5px; }
.clai-pop-log .table-wrap { overflow-x: auto; }
.clai-msg.err { border-color: var(--bad); }
.clai-typing { display: flex; gap: 4px; width: auto !important; }
.clai-typing span { width: 6px; height: 6px; border-radius: 50%; background: var(--muted); animation: claiDot 1s infinite ease-in-out; }
.clai-typing span:nth-child(2) { animation-delay: .15s; } .clai-typing span:nth-child(3) { animation-delay: .3s; }
@keyframes claiDot { 0%, 80%, 100% { opacity: .25; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }
@media (prefers-reduced-motion: reduce) { .clai-typing span { animation: none; } .clai-fab { transition: none; } }
.clai-pop-form { display: flex; gap: 6px; padding: 10px; border-top: 1px solid var(--line); }
.clai-pop-form input { flex: 1; min-width: 0; margin: 0; }
:root[data-theme="dark"] .chip-btn { background: #202020; color: var(--ink); border-color: #3A3A3A; }
.clai-pop-log .clai-msg.bot { width: 100%; }
.clai-pop-log table { min-width: 0 !important; width: 100%; }
.clai-pop-log th, .clai-pop-log td { padding: 5px 6px; white-space: normal; }
.clai-pop-log th { font-size: 10.5px; letter-spacing: 0; } .clai-pop-log { padding: 10px; }
.clai-pop-log table { table-layout: fixed; } .clai-pop-log td, .clai-pop-log th { overflow-wrap: anywhere; }
.clai-bot { touch-action: none; cursor: pointer; } .clai-fab.dragging .clai-bot { cursor: grabbing; }
.clai-pop header, .clai-pop-form { flex: none; } .clai-pop-log { min-height: 60px; }

/* ---------- profile menu: managers and companies (same dropdown as workers) ---------- */
#nav .acct-menu { flex: none; }
#nav .co-acct { margin-left: 14px; }
.acct-drop { max-width: calc(100vw - 24px); }
@media (max-width: 720px) { #nav .co-acct { margin-left: 8px; } }

/* ---------- company Overview heading: name left, one Request staff button right ---------- */
.co-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.co-head h1 { margin: 0; }
.co-head .sub { margin: 4px 0 0; }
.co-head .request-cta { width: auto; max-width: none; padding: 13px 28px; font-size: 16px; }
@media (max-width: 600px) {
  .co-head { flex-direction: column; align-items: stretch; gap: 14px; margin-bottom: 16px; }
  .co-head .request-cta { width: 100%; padding: 14px; }
}
.cal-req { text-decoration: none; color: inherit; border-radius: 6px; padding: 0 4px; }
.cal-req:hover { background: var(--surface); text-decoration: underline; }
.cal-req:focus-visible { outline: 2px solid var(--ink); outline-offset: 1px; }

/* ---------- Request staff form ---------- */
.rq-card { max-width: 860px; margin: 0 auto; padding: 32px 40px 36px; }
.rq-card h1 { font-size: 30px; margin: 0 0 6px; outline: none; }
.rq-sec { font-size: 19px; margin: 22px 0 10px; }
.rq-role { display: grid; grid-template-columns: 1fr 1fr; gap: 0 24px; align-items: start; position: relative; }
.rq-role + .rq-role { border-top: 1px solid var(--line); padding-top: 10px; margin-top: 4px; }
.rq-role .rq-rm { grid-column: 1 / -1; justify-self: start; margin: -2px 0 8px; font-size: 14px; }
.rq-role .field, .rq-card .field { margin: 0; }
.rq-card .field label { display: block; font-weight: 700; font-size: 14px; margin: 10px 0 6px; }
.rq-card input:not([type=checkbox]):not([type=file]), .rq-card select, .rq-card textarea { width: 100%; box-sizing: border-box; }
.rq-card textarea { min-height: 84px; resize: vertical; font: inherit; }
.rq-add { margin: 6px 0 4px; font-weight: 700; }
.rq-when { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 24px; }
.rq-fdate { max-width: calc((100% - 48px) / 3); }
.rq-card .hint { color: var(--muted); font-size: 13px; margin: 6px 0 0; }
.rq-note:empty { display: none; }
.rq-note { margin: 6px 0 0; }
.rq-tbc { margin: 10px 0 4px; display: inline-flex; align-items: center; gap: 10px; font-weight: 600; }
.rq-tbc input { width: 18px; height: 18px; }
.rq-contact { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin: 20px 0 6px; padding: 2px 0 16px; }
.rq-contact-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.rq-contact-head .linkish { font-weight: 700; font-size: 15px; }
.rq-contact-view p { margin: 0 0 2px; }
.rq-two { display: grid; grid-template-columns: 1fr 1fr; gap: 0 24px; }
.rq-attach { margin-top: 14px !important; }
.rq-attach .attach-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 6px; }
.rq-attach .label { display: inline-block; }
.rq-submit { width: auto !important; padding: 14px 38px !important; margin-top: 20px; }
.rq-done { text-align: left; outline: none; }
.rq-done h1 { margin-top: 10px; }
.rq-done p { font-size: 16px; max-width: 60ch; }
.rq-done-mark { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: #E3F1E6; color: #1E6B34; }
.rq-done-mark .i { width: 24px; height: 24px; }
:root[data-theme="dark"] .rq-done-mark { background: #1F3A27; color: #9BD9AC; }
@media (max-width: 720px) {
  .rq-card { padding: 22px 18px 26px; }
  .rq-card h1 { font-size: 26px; }
  .rq-role, .rq-when, .rq-two { grid-template-columns: 1fr; }
  .rq-fdate { max-width: none; }
  .rq-submit { width: 100% !important; }
}

/* ---------- worker profile: Contact and More dropdowns ---------- */
.wp-actions { margin-top: 12px; gap: 10px; flex-wrap: wrap; }
.dd { position: relative; display: inline-block; }
.dd-btn { gap: 6px; }
.dd-btn[aria-expanded="true"] { background: var(--surface); }
.dd-btn .chev { transition: transform .15s; }
.dd-btn[aria-expanded="true"] .chev { transform: rotate(180deg); }
.dd-list { position: absolute; left: 0; top: calc(100% + 6px); z-index: 35; min-width: 220px; max-width: calc(100vw - 32px);
  background: var(--card); color: var(--ink); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 12px 32px rgba(26,26,26,.16); padding: 6px; }
.dd-list.up { top: auto; bottom: calc(100% + 6px); }
.dd-list[hidden] { display: none; }
.dd-list [role="menuitem"] { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 10px 12px; border-radius: 8px; border: 0; background: none;
  font: inherit; font-size: 15px; font-weight: 600; color: var(--ink); text-decoration: none; cursor: pointer; white-space: nowrap; }
.dd-list [role="menuitem"] .i { width: 18px; height: 18px; flex: none; }
.dd-list [role="menuitem"]:hover, .dd-list [role="menuitem"]:focus-visible { background: var(--surface); outline: none; }
.dd-list [role="menuitem"].danger { color: var(--bad); }
.dd-list [role="menuitem"]:disabled { opacity: .5; cursor: default; }
.dd-hint { font-weight: 500; font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; max-width: 200px; }
.dd-sep { height: 1px; background: var(--line); margin: 6px 4px; }
.wp-cvmsg:empty, .wp-cvmsg span:empty { display: none; }
.wp-cvmsg .file-msg { margin-top: 8px; }
:root[data-theme="dark"] .dd-list { background: #1C1C1C; border-color: #333; box-shadow: 0 12px 32px rgba(0,0,0,.5); }
@media (max-width: 640px) {
  .perm-corner { display: flex; position: static; order: 3; width: 100%; }
  .perm-corner .access-pill { display: none; }
  .dd-hint { display: none; }
}
@media (max-width: 400px) { .wp-actions .dd:last-child .dd-list { left: auto; right: 0; } }

/* ---------- mobile ID cards: worker charcoal, company near-black (same in light and dark mode) ---------- */
.id-card.worker { background: #3A3A3A; color: #fff; }
.id-card.company { background: #121212; color: #fff; }
.id-card.worker .id-photo { background: #2A2A2A; }
.id-card.company .id-photo { background: #262626; }
.id-card .id-role { color: #D0D0D0; }

/* ---------- worker profile: mobile number ---------- */
#pf .helper { color: var(--muted); font-size: 13px; }
#pf input[aria-invalid="true"] { border-color: var(--bad); }

/* ---------- requests: withdrawal pending ---------- */
.req-pending-msg { margin: 6px 0 0; font-weight: 600; }

/* ---------- job visibility ---------- */
.pub-row { display: flex; align-items: flex-end; gap: 12px 24px; flex-wrap: wrap; margin-top: 14px; }
.pub-row .pub-check { margin: 0 0 10px; font-weight: 700; }
.pub-row .vis-field { min-width: 220px; }
.pub-row .vis-field label { margin-top: 0; }
.vis-help { margin: 6px 0 0; }
.vis-note { margin: 8px 0 0; }
.tag.unlisted-tag { background: var(--ink); color: var(--card); border-color: var(--ink); }
.jc-wrap .jc-copy { margin-top: 8px; width: 100%; justify-content: center; }
@media (max-width: 600px) { .pub-row { flex-direction: column; align-items: stretch; } .pub-row .vis-field { min-width: 0; } }

/* =====================================================================
   Worker profile (#/me/profile): one card per section, mobile-first
   ===================================================================== */
.pf { display: grid; gap: 14px; }
.pf .card { margin: 0; }
.pf-sec .form-h { margin: 0 0 12px; padding-top: 0; border-top: 0; }
.pf-field { margin-bottom: 14px; }
.pf-field:last-child { margin-bottom: 0; }
.pf-field label, .pf-sublabel { display: block; font-weight: 700; font-size: 15px; margin: 0 0 6px; color: var(--ink); }
.pf .req { color: var(--bad); }
.pf .helper { margin: 6px 0 0; color: var(--muted); font-size: 13px; line-height: 1.45; }
.pf input:not([type=checkbox]):not([type=radio]):not([type=file]), .pf select { min-height: 48px; font-size: 16px; }
.pf-row { display: flex; gap: 12px; align-items: flex-start; }
.pf-row .pf-field { margin-bottom: 0; }
.pf-grow { flex: 1; min-width: 0; }
.pf-state { width: 108px; flex: none; }
.pf-hint { margin: 6px 0 0; font-size: 13px; font-weight: 600; color: var(--warn); }
.pf-hint:empty { display: none; }

/* Photo */
.pf-photo { display: flex; gap: 16px; align-items: center; }
.pf-photo #pv { flex: none; }
.pf-photo-body { min-width: 0; flex: 1; }
.pf-h3 { font-size: 16px; margin: 0; }
.pf-photo .helper { margin: 2px 0 10px; }
.pf-photo-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.pf-photo-btn { min-height: 44px; cursor: pointer; white-space: normal; text-align: left; }
.pf-photo-btn:focus-within { outline: 2px solid var(--ink); outline-offset: 2px; }
.pf-photo-rm { font-size: 14px; font-weight: 600; color: var(--muted); min-height: 44px; }

/* CV status */
.cv-status { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 12px; background: var(--surface); margin-bottom: 12px; line-height: 1.4; }
.cv-status.on { background: var(--ok-bg); }
.cv-status.on .i { color: var(--ok); flex: none; margin-top: 2px; width: 18px; height: 18px; }
.cv-status .sub { margin: 0; font-size: 13px; }
.pf .cv-field label { font-weight: 700; }

/* Work preferences: separate, well-spaced groups */
.pf-group { border: 0; margin: 0; padding: 16px 0 0; border-top: 1px solid var(--line); min-width: 0; }
.pf-group + .pf-group, .pf-two { margin-top: 16px; }
.pf-sec > .form-h + .pf-group { border-top: 0; padding-top: 0; }
.pf-group legend { font-weight: 800; font-size: 15px; padding: 0; margin: 0 0 10px; float: left; width: 100%; }
.pf-group legend + * { clear: both; }
.pf .chips { gap: 8px; }
.pf .chip span { min-height: 40px; display: inline-flex; align-items: center; padding: 8px 14px; }
.pf-car { margin: 14px 0 0; min-height: 44px; font-size: 15px; font-weight: 600; }
.pf-travel { margin-top: 12px; }
.pf-travel-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.pf-travel-head output { font-weight: 800; font-size: 15px; }
.seg-radio { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; margin-top: 4px; }
.seg-radio label { margin: 0; cursor: pointer; }
.seg-radio input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.seg-radio span { display: flex; align-items: center; justify-content: center; text-align: center; min-height: 44px; padding: 4px 6px; border: 1px solid var(--line);
  border-radius: 12px; font-weight: 700; font-size: 14px; background: var(--card); color: var(--ink); line-height: 1.15; }
.seg-radio input:checked + span { background: var(--ink); color: var(--card); border-color: var(--ink); }
.seg-radio input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 2px; }
.pf-two { display: grid; grid-template-columns: 1fr; gap: 0; }
.pf-two .pf-group + .pf-group { margin-top: 16px; }
@media (min-width: 640px) { .pf-two { grid-template-columns: 1fr 1fr; gap: 24px; } .pf-two .pf-group + .pf-group { margin-top: 0; } }

/* Other languages as tags */
.tag-input { margin-top: 12px; }
.tag-list { list-style: none; margin: 0 0 8px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.tag-list[hidden] { display: none; }
.tag-chip { display: inline-flex; align-items: center; gap: 4px; padding: 4px 4px 4px 12px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-weight: 600; font-size: 14px; }
.tag-chip button { width: 32px; height: 32px; border: 0; background: none; border-radius: 50%; font-size: 18px; line-height: 1; cursor: pointer; color: var(--muted); }
.tag-chip button:hover, .tag-chip button:focus-visible { background: var(--line); color: var(--ink); }
.tag-add { display: flex; gap: 8px; }
.tag-add input { flex: 1; min-width: 0; margin: 0; }
.tag-add .btn { min-height: 48px; }

/* Agreements and saving */
.pf-agree .check.consent { line-height: 1.5; margin-top: 10px; padding: 14px; font-weight: 500; font-size: 15px; gap: 12px; }
.pf-agree .check.consent input { width: 22px; height: 22px; }
.pf-agree .small-note { font-size: 13px; margin: 14px 0; }
.pf-save { width: 100%; min-height: 54px; font-size: 17px; margin-top: 6px; }
.pf-later { width: 100%; margin-top: 10px; }

/* Account footer */
.pf-account { margin: 28px 0 0; padding: 18px 2px 0; border-top: 1px solid var(--line); }
.pf-account h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); margin: 0 0 6px; }
.pf-account .sub { margin: 0 0 12px; }
.pf-account .btn { min-height: 44px; }
@media (max-width: 600px) {
  .pf-photo { align-items: flex-start; }
  .seg-radio { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  main:has(.pf) { padding-bottom: 120px; }
}

/* =====================================================================
   Worker dashboard (#/me), mobile-first
   ===================================================================== */
/* Header card: name and place never squeeze against the Edit button */
.me-head:not(.compact) { display: flex; flex-wrap: nowrap !important; align-items: center !important; gap: 12px; }
.me-head .avatar { flex: none; }
.me-id { flex: 1; min-width: 0; }
.me-name { font-size: 19px; margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.me-loc { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.me-head:not(.compact) > .btn { flex: none; min-height: 44px; }

/* Tabs: one line; scroll sideways on narrow phones */
@media (max-width: 720px) {
  .wtabs { display: flex !important; grid-template-columns: none !important; overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none;
    -webkit-overflow-scrolling: touch; max-width: none; }
  .wtabs::-webkit-scrollbar { display: none; }
  .wtabs a { flex: none !important; white-space: nowrap; min-height: 44px; padding: 0 16px; scroll-snap-align: center; }
}

/* Next shift */
.next-card { display: flex; flex-direction: column; gap: 10px; }
.next-card .v { font-size: 20px; line-height: 1.25; margin: 0; }
.next-card .btn.big { margin-top: 4px; min-height: 50px; }
.shift-facts { margin: 0; display: grid; gap: 8px; }
.shift-facts > div { display: flex; gap: 10px; align-items: flex-start; }
.shift-facts dt { flex: none; color: var(--muted); padding-top: 2px; }
.shift-facts dd { margin: 0; font-weight: 600; min-width: 0; overflow-wrap: anywhere; }
.checkin-line { display: flex; gap: 8px; align-items: center; padding: 10px 12px; border-radius: 12px; background: var(--surface); font-weight: 700; font-size: 14px; }
.checkin-line.open { background: var(--ok-bg); color: var(--ok); }
.gear-line { margin: 0; font-size: 13px; color: var(--muted); }
.ready-line { margin: 0; font-size: 14px; color: var(--iron); line-height: 1.45; }
.ready-line.ok .i { color: var(--ok); vertical-align: -3px; }
.ready-line a { font-weight: 700; }

/* Quiet sign-out at the very bottom */
.me-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 14px; margin: 22px 2px 0; padding-top: 16px; border-top: 1px solid var(--line); }
.me-foot .sub { margin: 0; font-size: 13px; min-width: 0; }
.me-foot .linkish { min-height: 44px; font-weight: 700; }

/* Top bar touch targets on phones */
@media (max-width: 600px) {
  .theme-toggle { width: 44px !important; height: 44px !important; }
  #nav select { min-height: 44px; }
  #nav .acct-btn { min-height: 44px; }
}
@media (max-width: 600px) {
  #nav > a:not(.avatar):not(.login-btn) { min-height: 44px; display: inline-flex; align-items: center; }
  .topbar .brand { min-height: 44px; }
  /* The worker tabs already link to the dashboard, so the top-bar Dashboard link is dropped there to give the controls room. */
  body:has(#app .wtabs) #nav > a[href="#/me"] { display: none; }
}
.pf-travel-head output { display: inline-block; padding: 4px 12px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-size: 14px; margin-bottom: 6px; }
.pf-travel-head .pf-sublabel { margin: 0 0 6px; }
@media (max-width: 600px) { .seg-radio label:last-child { grid-column: span 2; } }
/* Dark mode: selected chips are filled, like the light theme (the dark card colour used to override the selected state). */
:root[data-theme="dark"] .chip input:checked + span { background: var(--ink); color: var(--card); border-color: var(--ink); }
@media (min-width: 721px) { .me-foot { display: none; } }

/* =====================================================================
   Available jobs (#/jobs): stacked filters, light empty state, EOI cards
   ===================================================================== */
.jf { display: grid; grid-template-columns: 1fr; gap: 12px; margin: 0 0 16px; }
.jf-field label { display: block; font-weight: 700; font-size: 14px; margin: 0 0 6px; color: var(--ink); }
.jf-field select, .jf-field input { width: 100%; min-height: 48px; font-size: 16px; margin: 0; }
.jf-reset { min-height: 44px; justify-self: start; }
@media (min-width: 721px) {
  .jf { grid-template-columns: repeat(3, minmax(0, 1fr)) auto; align-items: end; }
  .jf-reset { align-self: end; min-height: 48px; }
}
.jf-count { margin: 0 0 8px; font-size: 13px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; }
.job-list { padding-top: 4px; padding-bottom: 4px; }
.jobs-empty { padding: 18px 2px 6px; }
.jobs-empty-t { font-size: 18px; font-weight: 800; margin: 0 0 4px; }
.jobs-empty .sub { margin: 0 0 12px; }
.jobs-empty .btn { min-height: 44px; }
.eoi-h { margin: 26px 0 12px; }
.eoi-card { display: flex; flex-direction: column; }
.eoi-title { margin: 10px 0 4px; font-size: 18px; line-height: 1.3; }
.eoi-meta { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 14px; }
.eoi-meta span { display: inline-flex; align-items: center; gap: 4px; }
.eoi-card .btn, .eoi-card > .pill { margin-top: auto; }
.eoi-card .btn { min-height: 48px; }
@media (max-width: 600px) {
  .eoi-card .btn { width: 100%; justify-content: center; }
  .eoi-card > .pill { align-self: flex-start; padding: 8px 12px; }
  main:has(.jf), main:has(.ev-list), main:has(.eoi-grid) { padding-bottom: 120px; }
}

/* =====================================================================
   My events (#/jobs?tab=mine)
   ===================================================================== */
.ev-filter { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 0 14px; padding: 2px; }
.ev-filter::-webkit-scrollbar { display: none; }
.ev-chip { flex: none; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--card); color: var(--ink); font: inherit; font-weight: 700; font-size: 14px; cursor: pointer; white-space: nowrap; }
.ev-chip .n { font-size: 12px; min-width: 20px; padding: 1px 6px; border-radius: 999px; background: var(--surface); text-align: center; }
.ev-chip.on { background: var(--ink); color: var(--card); border-color: var(--ink); }
.ev-chip.on .n { background: rgba(255,255,255,.18); color: inherit; }
.ev-chip:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.ev-list { display: grid; gap: 12px; }
@media (min-width: 721px) { .ev-list { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); } }
.ev-card { margin: 0; display: flex; flex-direction: column; gap: 8px; }
.ev-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.ev-role { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px; color: var(--iron); }
.ev-title { margin: 0; font-size: 18px; line-height: 1.3; overflow-wrap: anywhere; }
.ev-facts { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; color: var(--iron); font-size: 14px; }
.ev-facts li { display: flex; gap: 6px; align-items: flex-start; }
.ev-facts .i { flex: none; margin-top: 2px; }
.ev-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.ev-acts .btn { min-height: 44px; }
.ev-quiet { background: transparent; }

/* =====================================================================
   Header: hamburger button and the account menu's ID row
   ===================================================================== */
.menu-btn { width: 44px; height: 44px; padding: 0 !important; border-radius: 50% !important; align-items: center; justify-content: center; flex: none; }
@media (max-width: 720px) { .menu-btn { display: inline-flex !important; } }
.menu-btn[aria-expanded="true"] { background: var(--dark-ink, #fff); color: var(--dark, #000); }
.menu-btn:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.acct-drop [role="menuitem"] { min-height: 44px; }
.acct-drop .mi-sub { margin-left: auto; font-size: 13px; font-weight: 700; color: var(--muted); letter-spacing: 1px; font-variant-numeric: tabular-nums; }
@media (max-width: 720px) { .acct-drop .id-item { display: flex; align-items: center; } }
.acct-drop #acctSignOut { border-top: 1px solid var(--line); border-radius: 0 0 8px 8px; margin-top: 4px; }

/* Photo control (manager and company settings) */
.photo-pick .pf-photo-actions { margin-top: 0; }

/* =====================================================================
   Header hamburger (all accounts, phone and desktop)
   ===================================================================== */
.hm { position: relative; flex: none; }
.menu-btn { display: inline-flex !important; }
.hm-panel { position: absolute; right: 0; top: calc(100% + 8px); z-index: 45; min-width: 240px; max-width: calc(100vw - 24px);
  background: var(--card); color: var(--ink); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 12px 32px rgba(26,26,26,.18); padding: 6px; }
.hm-panel[hidden] { display: none; }
.hm-list { list-style: none; margin: 0; padding: 0; }
#nav .hm-list a { display: flex; align-items: center; min-height: 46px; padding: 0 14px; border-radius: 10px; font-size: 16px; font-weight: 600;
  color: var(--ink) !important; text-decoration: none; background: none !important; }
#nav .hm-list a:hover, #nav .hm-list a:focus-visible { background: var(--surface) !important; outline: none; }
#nav .hm-list a.on { font-weight: 800; background: var(--surface) !important; box-shadow: inset 3px 0 0 var(--ink); }
.hm-lang { border-top: 1px solid var(--line); margin-top: 6px; padding: 10px 8px 6px; }
.hm-lang label { display: block; font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); margin: 0 0 6px; }
#nav .hm-lang select { width: 100%; min-height: 44px; background: var(--card); color: var(--ink); border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; font-size: 15px; }
#nav .hm-lang select option { color: var(--ink); background: var(--card); }
.hm-mob { display: none; }
@media (max-width: 720px) {
  .hm-mob { display: block; }
  .hm-desk { display: none; }
  #nav .nav-cta { display: none; }
  .wtabs { display: none !important; }            /* phones use the header menu instead of the tab bar */
}
.wsec { font-size: 22px; margin: 10px 0 14px; }
:root[data-theme="dark"] .hm-panel { background: #1C1C1C; border-color: #333; box-shadow: 0 12px 32px rgba(0,0,0,.5); }
:root[data-theme="dark"] #nav .hm-lang select { background: #1C1C1C; }

/* =====================================================================
   Account menu: the ID row (with the member number) shows on every screen size
   ===================================================================== */
.acct-drop .id-item { display: flex !important; align-items: center; gap: 12px; }

/* =====================================================================
   Notifications: new-enquiry alerts are one summary line
   ===================================================================== */
.note-body.note-summary { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* =====================================================================
   ID cards: Worker light grey with dark text; Manager charcoal. Same in light and dark mode.
   ===================================================================== */
.id-card.worker { background: #E6E6E6; color: #111; }
.id-card.worker::after { border-color: rgba(0,0,0,.05); }
.id-card.worker .id-top, .id-card.worker h2 { color: #111; }
.id-card.worker .id-role { color: #4A4A4A; }
.id-card.worker .id-logo, :root[data-theme="dark"] .id-card.worker .id-logo { filter: none; }
.id-card.worker .id-photo { background: #CFCFCF; border-color: #fff; }
.id-card.worker .id-photo span { color: #111; }
.id-card.worker .id-no { box-shadow: 0 0 0 1px rgba(0,0,0,.06); }
.id-card.manager { background: #3A3A3A; color: #fff; }
.id-card.manager .id-photo { background: #2A2A2A; }
#nav .hm-lang #langSel { max-width: none; width: 100%; padding: 8px 10px; }
@media (max-width: 720px) { #nav > a.nav-cta { display: none !important; } }

/* =====================================================================
   Worker desktop header: Dashboard · [theme] · Language · avatar (no hamburger)
   ===================================================================== */
.nav-lead { display: flex; gap: 4px; align-items: center; margin-left: auto; }
.nav-lead:empty { display: none; }
.nav-lead:not(:empty) + .theme-toggle { margin-left: 8px; }
.nav-lead a { color: var(--dark-muted); text-decoration: none; font-size: 14px; font-weight: 600; padding: 8px 12px; border-radius: 999px; }
.nav-lead a:hover { color: #fff; }
.nav-lead a.active { color: #fff; background: var(--dark-2); }
.nav-lead a:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
#nav.nav-worker { gap: 8px; }
@media (min-width: 721px) { #nav.nav-worker .hm-phone { display: none; } }
@media (max-width: 720px) { .nav-lead { display: none !important; } #nav.nav-worker .lang-bar { display: none; } }

/* =====================================================================
   Manager desktop header: theme · menu · + New job · bell · avatar, all 40px tall, evenly spaced
   ===================================================================== */
@media (min-width: 721px) {
  .topbar:has(#nav.nav-mgr) { gap: 10px; }
  body:has(#nav.nav-mgr) .theme-toggle { height: 40px; margin-right: 0; }
  #nav.nav-mgr { gap: 10px; flex-wrap: nowrap; }
  #nav.nav-mgr .menu-btn { width: 40px; height: 40px; }
  #nav.nav-mgr .menu-btn svg { display: block; width: 20px; height: 20px; }
  #nav.nav-mgr > a.nav-cta { height: 40px; display: inline-flex; align-items: center; padding: 0 18px; font-weight: 700; }
  #nav.nav-mgr .bell-wrap { margin-left: 0; }
  #nav.nav-mgr .bell { width: 40px; height: 40px; }
  #nav.nav-mgr .acct-btn { height: 40px; }
  /* The menu opens directly under its button. */
  .hm-panel { left: 0; right: auto; }
}

/* Hamburger panel: same look as the profile dropdown */
.hm-panel { border-radius: 12px; padding: 6px; min-width: 200px; }
#nav .hm-list a { min-height: 44px; padding: 0 12px; border-radius: 8px; font-size: 15px; font-weight: 600; line-height: 1.3; }
#nav .hm-list a.on { font-weight: 700; box-shadow: none; }

/* =====================================================================
   Profile dropdown rows: same size, weight, line height and left edge; vertically centred
   ===================================================================== */
#nav .acct-drop [role="menuitem"] { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 0 12px !important; margin: 0;
  font-size: 15px !important; font-weight: 600 !important; line-height: 1.3; border-radius: 8px !important; text-align: left; box-sizing: border-box; }
#nav .acct-drop #acctSignOut { color: var(--bad) !important; border-radius: 0 0 8px 8px !important; }

/* =====================================================================
   Manager ID card: orange #E85002 with near-black text and icons (light and dark mode)
   ===================================================================== */
.id-card.manager { background: #E85002; color: #111; }
.id-card.manager::after { border-color: rgba(0,0,0,.08); }
.id-card.manager .id-top, .id-card.manager h2 { color: #111; }
.id-card.manager .id-role { color: #1A1A1A; }
.id-card.manager .id-logo, :root[data-theme="dark"] .id-card.manager .id-logo { filter: none; }
.id-card.manager .id-photo { background: rgba(255,255,255,.28); border-color: #111; }
.id-card.manager .id-photo span { color: #111; }

/* =====================================================================
   Shift status badges (worker): Clocked in = red, Clocked out = green. Readable in both themes.
   ===================================================================== */
.pill.clocked-in { background: #C62828; color: #fff; border-color: #C62828; }
.pill.clocked-out { background: #1E7B3A; color: #fff; border-color: #1E7B3A; }
/* Overview clock card: "On shift since … · … worked" in a red badge while the shift is in progress */
.clock-state.live { display: inline-block; background: #C62828; color: #fff; border-radius: 12px; padding: 8px 12px; font-weight: 700; margin: 8px 0 4px; }
.clock-state.live.on-break { background: #8A5A00; }
.clock-state.live .clock-elapsed { color: #fff; }
.clock-geo-note { flex-basis: 100%; margin: 6px 0 0; font-size: 13px; opacity: .8; }

/* My events: expressions of interest collapsed under the shifts */
.ev-eoi { margin-top: 18px; border-top: 1px solid var(--line); padding-top: 12px; }
.ev-eoi > summary { cursor: pointer; font-weight: 800; font-size: 16px; min-height: 44px; display: flex; align-items: center; gap: 8px; list-style: none; }
.ev-eoi > summary::-webkit-details-marker { display: none; }
.ev-eoi > summary::before { content: '▸'; transition: transform .15s; }
.ev-eoi[open] > summary::before { transform: rotate(90deg); }
.ev-eoi > summary:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; border-radius: 8px; }
.ev-eoi .ev-list { margin-top: 10px; }

/* Manager: zone labels and location results */
.tz-tag { font-size: 11px; font-weight: 700; color: var(--muted); }
.tz-local { font-weight: 500; color: var(--muted); }
.pill.geo-pill { font-size: 11px; vertical-align: 1px; margin-left: 4px; }
.geo-ok { font-size: 13px; margin-top: 4px; display: inline-block; }
.tz-help { margin: 6px 0 0; }
.clock-point { margin-top: 12px; }

/* Overview: workers pending review */
.pw-line { margin: 6px 0 4px; display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; }
.pw-n { font-size: 18px; }
.pw-link { font-weight: 700; }
.pw-err { color: var(--bad); font-weight: 600; }

/* =====================================================================
   Payslips
   ===================================================================== */
.ps-issues ul { margin: 6px 0 0; padding-left: 18px; }
.pr-form { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 14px; align-items: end; }
.pr-form .pr-wide, .pr-form .form-err, .pr-form button { grid-column: 1 / -1; }
.pr-form button { justify-self: start; margin-top: 12px; }
@media (max-width: 600px) { .pr-form { grid-template-columns: 1fr 1fr; } }
.ps-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 4px 0 24px; }
.ps-actions .btn { min-height: 44px; }
.payslip-doc { position: relative; background: #fff; color: #111; border: 1px solid #DDD; border-radius: 8px; padding: 0 0 16px; overflow: hidden; font-size: 14px; }
.payslip-doc .ps-head { display: flex; justify-content: space-between; align-items: center; background: #1A1A1A; color: #fff; padding: 16px 20px; font-size: 20px; }
.payslip-doc .ps-head span { font-weight: 800; letter-spacing: 1px; font-size: 16px; }
.payslip-doc .ps-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; padding: 16px 20px; }
.payslip-doc .ps-meta span { display: block; font-size: 12px; color: #666; }
.payslip-doc .ps-meta small { display: block; color: #444; }
.payslip-doc .ps-table { width: calc(100% - 40px); margin: 0 20px; border-collapse: collapse; font-size: 13px; }
.payslip-doc .ps-table th, .payslip-doc .ps-table td { text-align: left; padding: 6px 4px; border-bottom: 1px solid #E5E5E5; color: #111; }
.payslip-doc .ps-table .num { text-align: right; }
.payslip-doc .ps-totals { margin: 12px 20px 0 auto; max-width: 300px; padding: 0 20px 0 0; }
.payslip-doc .ps-totals div { display: flex; justify-content: space-between; gap: 12px; padding: 3px 0; }
.payslip-doc .ps-totals dd { margin: 0; font-variant-numeric: tabular-nums; }
.payslip-doc .ps-totals .net { border-top: 1px solid #111; margin-top: 4px; padding-top: 6px; font-weight: 800; }
.payslip-doc .ps-foot { margin: 14px 20px 0; font-size: 12px; color: #666; }
.payslip-doc .ps-water { position: absolute; inset: 0; display: grid; place-items: center; font-size: 90px; font-weight: 900; color: rgba(198,40,40,.12);
  transform: rotate(-18deg); pointer-events: none; letter-spacing: 8px; }
@media (max-width: 600px) { .payslip-doc .ps-meta { grid-template-columns: 1fr; } .payslip-doc .ps-totals { margin-left: 20px; max-width: none; } }
.ps-list { list-style: none; margin: 0; padding: 0; }
.ps-list li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); }
.ps-list li:first-child { border-top: 0; }
.clai-pick { list-style: none; padding: 0; margin: 6px 0 0; display: grid; gap: 6px; }
.pr-fix { margin-top: 10px; } .pr-fix > summary { cursor: pointer; font-weight: 700; min-height: 44px; display: flex; align-items: center; }

/* =====================================================================
   Header hamburger: never past the viewport edge. Company menu opens under the button, right edges aligned, extending left.
   (JS keeps 12 px of clearance from the visible viewport, scrollbar excluded, at any width or zoom.)
   ===================================================================== */
@media (min-width: 721px) {
  .hm-panel { left: auto; right: 0; }
  #nav.nav-mgr .hm-panel { left: 0; right: auto; }
}
#nav.nav-co .hm-panel { left: auto; right: 0; top: calc(100% + 8px); min-width: 190px; border-radius: 12px; padding: 6px;
  box-shadow: 0 12px 32px rgba(26,26,26,.18); }
.hm-panel { box-sizing: border-box; }

/* =====================================================================
   Company Overview (mockup): Active requests card with side-by-side request cards, then a collapsed Request calendar
   ===================================================================== */
.co-active { padding: 22px 24px 24px; border-radius: 16px; }
.co-sec-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.co-sec-head h2 { margin: 0; font-size: 22px; }
.co-all { font-weight: 700; font-size: 15px; color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.co-empty { margin: 0; color: var(--muted); }
.coq-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; align-items: stretch; }
.coq-card { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 14px; padding: 18px 22px 20px; background: var(--card); min-width: 0; }
.coq-card.needs { border: 2px solid #C8432F; }
.coq-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.coq-id { min-width: 0; }
.coq-id h3 { margin: 0; font-size: 22px; line-height: 1.25; overflow-wrap: anywhere; }
.coq-where { margin: 4px 0 0; color: var(--muted); font-size: 16px; overflow-wrap: anywhere; }
.coq-pills { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; flex: none; }
.coq-pills .pill { font-size: 13px; padding: 5px 12px; }
.coq-body { margin: 18px 0 20px; flex: 1; }
.coq-count { margin: 0 0 12px; font-size: 17px; font-weight: 600; }
.coq-next { margin: 0; color: var(--muted); }
.coq-next b { color: var(--ink); font-weight: 600; opacity: .8; }
.coq-prog + .coq-prog { margin-top: 14px; }
.coq-bar { height: 14px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); overflow: hidden; }
.coq-bar b { display: block; height: 100%; background: #5E9E6A; border-radius: 999px; min-width: 0; }
.coq-left { margin: 8px 0 0; color: var(--muted); font-size: 15px; }
.coq-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.coq-actions .btn { padding: 12px 24px; font-size: 16px; }
.pill.chg { background: var(--warn-bg); color: var(--warn); }
@media (max-width: 720px) {
  .coq-grid { grid-template-columns: 1fr; gap: 14px; }
  .co-active { padding: 18px 16px; }
  .coq-card { padding: 16px; }
  .coq-id h3 { font-size: 20px; }
  .coq-actions .btn { flex: 1 1 auto; white-space: normal; text-align: center; min-width: 0; }
}
@media (max-width: 420px) { .coq-top { flex-direction: column; } .coq-pills { align-items: flex-start; flex-direction: row; flex-wrap: wrap; } }

/* Collapsible Request calendar */
.cal-fold { padding: 18px 24px; border-radius: 16px; margin-top: 18px; }
.cal-bar { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.cal-bar h2 { margin: 0; font-size: 22px; padding-right: 18px; border-right: 1px solid var(--line); }
.cal-bar-month { display: inline-flex; align-items: center; gap: 10px; font-size: 17px; font-weight: 600; }
.cal-bar-month .i { width: 22px; height: 22px; }
.cal-toggle { margin-left: auto; padding: 10px 18px; font-size: 15px; white-space: normal; }
.cal-toggle[aria-expanded="true"] .chev { transform: rotate(180deg); }
.cal-fold .cal-body { margin-top: 16px; }
.cal-fold .cal-nav { justify-content: flex-end; margin-bottom: 10px; }
@media (max-width: 720px) {
  .cal-fold { padding: 16px; }
  .cal-bar { gap: 10px 14px; }
  .cal-bar h2 { font-size: 19px; padding-right: 14px; }
  .cal-toggle { margin-left: 0; width: 100%; }
  .cal-fold .cal-nav { justify-content: space-between; flex-wrap: wrap; }
  .cal-fold .cal-day { min-height: 56px; padding: 2px; }
  .cal-fold .cal-ev { padding: 2px 3px; font-size: 10px; }
  .cal-fold .cal-ev .cal-s, .cal-fold .cal-ev .cal-st { display: none; }
  .cal-fold .cal-wd { padding: 4px 2px; font-size: 10px; text-align: center; }
}

/* =====================================================================
   Worker profile → Payslips (below Timesheets). Generate payslip sits right of the heading; below it on phones.
   ===================================================================== */
.ps-card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.ps-card-head h2 { margin: 0; }
.ps-gen { background: transparent; }
@media (max-width: 720px) {
  .ps-card-head { flex-direction: column; align-items: stretch; }
  .ps-gen { width: 100%; min-height: 44px; }
}
.ps-hist { list-style: none; margin: 0; padding: 0; }
.ps-hist li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.ps-hist li:first-child { border-top: 0; padding-top: 4px; }
.ps-hist li > div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ps-hist .sub { margin: 0; font-size: 13px; }
.ps-hist .btn { flex: none; min-height: 36px; }
.ps-none { margin: 0; color: var(--muted); font-weight: 600; }
.ps-dialog .set-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 480px) { .ps-dialog .set-pair { grid-template-columns: 1fr; gap: 0; } }
.ps-dialog select:disabled { opacity: 1; }
.ps-issues p { color: inherit; }
.ps-pdf-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.ps-frame { width: 100%; height: 78vh; min-height: 480px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); }

/* Job card menu: button rows (Archive / Restore) look like the link rows */
.kebab-menu button[role="menuitem"] { display: block; width: 100%; text-align: left; padding: 9px 12px; border-radius: 8px; border: 0; background: none;
  color: var(--ink); font: inherit; font-weight: 600; cursor: pointer; }
.kebab-menu button[role="menuitem"]:hover, .kebab-menu button[role="menuitem"]:focus-visible { background: var(--surface); outline: none; }
.kebab-menu { min-width: 170px; }

/* My hours: the manager label ("Gabriel - Crew Link Manager") wraps on narrow screens */
.tt-row .sub { overflow-wrap: anywhere; }
.mgr-label { overflow-wrap: anywhere; }
/* Dark mode: the current page in the hamburger stays clearly highlighted against the dark panel */
:root[data-theme="dark"] #nav .hm-list a.on { background: #2C2C2C !important; }
:root[data-theme="dark"] #nav .hm-list a:hover, :root[data-theme="dark"] #nav .hm-list a:focus-visible { background: #262626 !important; }

/* ---------- pilot: My crew + My jobs (company) and crew links ---------- */
.pilot-tag { display: inline-block; vertical-align: middle; margin-left: 6px; padding: 2px 9px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--muted); font-size: 11px; font-weight: 800; letter-spacing: .6px; text-transform: uppercase; }
.cw-seg { max-width: 560px; margin-bottom: 16px; }
.cw-rows { list-style: none; margin: 0; padding: 0; }
.cw-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 14px 0; border-top: 1px solid var(--line); }
.cw-rows > .cw-row:first-child { border-top: 0; padding-top: 4px; }
.card .co-sec-head + .cj-tally + .cw-rows > .cw-row:first-child, .card .hint + .cw-rows > .cw-row:first-child { border-top: 1px solid var(--line); padding-top: 14px; }
.cw-ini { width: 42px; height: 42px; }
.cw-main { flex: 1 1 220px; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.cw-main b { overflow-wrap: anywhere; }
.cw-sub { display: block; color: var(--muted); font-size: 13px; overflow-wrap: anywhere; }
.cw-state { flex: none; }
.cw-acts { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; flex: 0 1 auto; }
.cw-pick { display: flex; flex-direction: column; gap: 2px; max-height: 50vh; overflow-y: auto; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 6px 12px; }
.cw-pick .check { padding: 8px 0; border-top: 1px solid var(--line); }
.cw-pick .check:first-child { border-top: 0; }
.cw-dialog { width: min(520px, calc(100vw - 32px)); }
.cw-when { gap: 0 16px; }
.cj-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: stretch; }
.cj-card { display: flex; flex-direction: column; gap: 8px; margin: 0; }
.cj-top { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.cj-top h2 { margin: 0 0 6px; font-size: 19px; overflow-wrap: anywhere; }
.cj-meta { margin: 2px 0; color: var(--iron); font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.cj-meta .i { flex: none; color: var(--muted); }
.cj-pills { flex: none; }
.cj-count { margin: 4px 0 0; font-weight: 700; }
.cj-actions { margin-top: auto; padding-top: 6px; }
.cj-head { align-items: flex-start; }
.cj-head h1 { overflow-wrap: anywhere; }
.cj-head-acts { justify-content: flex-end; }
.cj-notes h2 { font-size: 16px; margin: 0 0 6px; }
.cj-notes p { margin: 0; white-space: pre-line; }
.cj-tally { margin: -8px 0 6px; }
.cj-total { margin: 12px 0 0; padding-top: 12px; border-top: 1px solid var(--line); text-align: right; }
.cj-form textarea { resize: vertical; }
.cl-card { max-width: 560px; margin-left: auto; margin-right: auto; }
.cl-card h1 { font-size: 24px; margin: 4px 0 10px; overflow-wrap: anywhere; }
.cl-card h2 { margin-top: 0; }
.cl-kicker { margin: 0; color: var(--muted); font-size: 12px; font-weight: 800; letter-spacing: .6px; text-transform: uppercase; }
.cl-notes { white-space: pre-line; background: var(--surface); border-radius: var(--radius-sm); padding: 12px 14px; margin: 12px 0; }
.cl-status { margin: 14px 0; font-weight: 700; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.cl-acts .btn { flex: 1 1 160px; }
@media (max-width: 720px) {
  .cj-grid { grid-template-columns: 1fr; }
  .cw-acts { justify-content: flex-start; flex-basis: 100%; padding-left: 54px; }
  .cj-hours-acts { padding-left: 0; }
  .cj-head-acts { justify-content: flex-start; }
  .cw-seg { max-width: none; }
}
@media (max-width: 420px) { .cw-acts { padding-left: 0; } .cw-seg a { padding: 9px 6px; font-size: 13px; } }
:root[data-theme="dark"] .pilot-tag { background: #1E1E1E; border-color: #333; }

/* =====================================================================
   Worker Overview, desktop (mockup): next action + Applications | profile + Recent hours; calendar collapsed below
   ===================================================================== */
.wd-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: 24px; align-items: start; margin-top: 4px; }
.wd-col { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
.wd-col > .card { margin: 0; border-radius: 18px; }
.wd-col .ov-empty { padding: 26px 26px 28px; }
.wd-col .ov-empty h2 { font-size: 30px; }
.wd-card { padding: 22px 24px; }
.wd-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.wd-head h2 { margin: 0; font-size: 26px; }
.wd-list { list-style: none; margin: 0; padding: 0; }
.wd-list li { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-top: 1px solid var(--line); }
.wd-list li:first-child { border-top: 0; padding-top: 4px; }
.wd-list li > a { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; color: var(--ink); text-decoration: none; }
.wd-list li > a:hover b, .wd-list li > a:focus-visible b { text-decoration: underline; }
.wd-list li > a b { font-size: 16px; overflow-wrap: anywhere; }
.wd-list li .sub { margin: 0; font-size: 14px; }
.wd-dur { font-size: 18px; font-weight: 700; white-space: nowrap; }
.wd-list.hrs { border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.wd-empty { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.wd-empty .sub { margin: 0; font-size: 16px; }
.wd-foot { margin: 10px 0 0; }
.wd-link { font-weight: 600; color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.wd-col .me-head.compact { display: flex; align-items: center; gap: 14px; padding: 18px 22px; flex-wrap: nowrap; }
.wd-col .me-head.compact .me-id { flex: 1; min-width: 0; }
.wd-col .me-head.compact .me-name { margin: 0; font-size: 20px; overflow-wrap: anywhere; }
.wd-col .me-head.compact > .btn { flex: none; background: transparent; padding: 9px 18px; font-size: 15px; }
.wd-col .next-card .row .btn { min-height: 44px; }
.cal-fold-icon { margin-top: 24px; border-radius: 18px; }
.cal-fold-icon .cal-bar h2 { border-right: 0; padding-right: 0; display: inline-flex; align-items: center; gap: 14px; font-size: 24px; }
.cal-fold-icon .cal-ico .i { width: 26px; height: 26px; }
.help-link { margin-top: 14px; }
@media (max-width: 860px) { .wd-grid { grid-template-columns: 1fr; } }

/* =====================================================================
   Manager desktop: segmented tab bar below the header replaces the hamburger (phones keep the hamburger)
   ===================================================================== */
.mgr-bar { display: none; }
@media (min-width: 721px) {
  .mgr-bar { display: block; background: var(--bg); padding: 16px 24px 0; }
  .mgr-bar .inner { max-width: 1180px; margin: 0 auto; }
  .mgr-seg { list-style: none; margin: 0; display: inline-flex; flex-wrap: wrap; max-width: 100%; }
  .mgr-seg li { display: flex; }
  .mgr-seg a { min-height: 44px; padding: 0 26px; font-size: 15px; white-space: nowrap; }
  .mgr-seg a:hover { color: var(--ink); }
  .mgr-seg a:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
  #nav.nav-mgr .hm { display: none; }
}
:root[data-theme="dark"] .mgr-seg { background: #262626; }
:root[data-theme="dark"] .mgr-seg a.on { background: #3A3A3A; color: #fff; }

/* =====================================================================
   Manager → Jobs, light mode only: white rounded toolbar instead of the black strip, aligned with the page content,
   16 px below the tab bar; Next shift as a white card. Dark mode keeps its current look.
   ===================================================================== */
:root:not([data-theme="dark"]) .filterbar.jobs-tb { background: transparent; border-bottom: 0; padding: 16px 24px 0; }
:root:not([data-theme="dark"]) .filterbar.jobs-tb .inner { max-width: 1132px; background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 12px; gap: 10px; }
:root:not([data-theme="dark"]) .jobs-tb .fb-field { background: var(--surface); border: 1px solid var(--line); color: var(--ink);
  min-height: 46px; padding: 0 12px 0 14px; min-width: 200px; }
:root:not([data-theme="dark"]) .jobs-tb .fb-field:focus-within { border-color: var(--iron); background: var(--card); }
:root:not([data-theme="dark"]) .jobs-tb .fb-field .ico { color: var(--muted); }
:root:not([data-theme="dark"]) .jobs-tb .fb-field input, :root:not([data-theme="dark"]) .jobs-tb .fb-field select { color: var(--ink); font-weight: 600; }
:root:not([data-theme="dark"]) .jobs-tb .fb-field input::placeholder { color: var(--muted); font-weight: 500; }
:root:not([data-theme="dark"]) .jobs-tb .fb-field select option { color: var(--ink); background: var(--card); }
/* Tab bar lines up with the Jobs content on this page (same left edge as the toolbar and the cards). */
@media (min-width: 721px) {
  :root:not([data-theme="dark"]) body:has(.filterbar.jobs-tb) .mgr-bar .inner { max-width: 1132px; }
}
@media (max-width: 720px) {
  :root:not([data-theme="dark"]) .filterbar.jobs-tb { padding: 12px 16px 0; }
  :root:not([data-theme="dark"]) .jobs-tb .fb-field { min-width: 100%; }
}
:root:not([data-theme="dark"]) .panel-dark.next-shift { background: var(--card); color: var(--ink); border: 1px solid var(--line); }
:root:not([data-theme="dark"]) .panel-dark.next-shift::after { border-color: rgba(26,26,26,.05); }
:root:not([data-theme="dark"]) .panel-dark.next-shift .k, :root:not([data-theme="dark"]) .panel-dark.next-shift .s { color: var(--muted); }
:root:not([data-theme="dark"]) .panel-dark.next-shift .v { color: var(--ink); font-size: 22px; }
:root:not([data-theme="dark"]) .panel-dark.next-shift .btn.primary { background: var(--ink); color: #fff; border-color: var(--ink); }

/* =====================================================================
   Public homepage: header links, About us and Pricing (three plan cards side by side; stacked on phones)
   ===================================================================== */
#nav.nav-public { display: flex; align-items: center; gap: 6px; }
body.public #nav .hp-nav-link { color: inherit; text-decoration: none; font-weight: 700; font-size: 15px; padding: 9px 12px; border-radius: 8px; white-space: nowrap; }
body.public #nav .hp-nav-link:hover, body.public #nav .hp-nav-link.on { text-decoration: underline; text-underline-offset: 4px; }
body.public #nav .login-btn { margin-left: 6px; }
.hp-eyebrow { margin: 0 0 6px; font-size: 13px; font-weight: 800; text-transform: uppercase; letter-spacing: .8px; color: #555; }
.hp-about, .hp-pricing { margin-top: 56px; scroll-margin-top: 16px; }
.hp-about h2, .hp-pricing h2 { font-size: clamp(26px, 3.4vw, 40px); font-weight: 800; letter-spacing: -.6px; margin: 0 0 14px; line-height: 1.15; }
.hp-about h2:focus, .hp-pricing h2:focus { outline: none; }
.hp-about { max-width: 760px; }
.hp-about > p { font-size: 17px; line-height: 1.6; color: #222; margin: 0 0 14px; }
.hp-sign { display: flex; flex-direction: column; margin-top: 18px !important; }
.hp-sign b { font-size: 17px; } .hp-sign span { color: #555; }
.hp-price-sub { font-size: 18px; font-weight: 700; margin: -6px 0 4px; }
.hp-price-note { color: #555; margin: 0 0 22px; }
.hp-plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; align-items: stretch; }
.hp-plan { border: 1px solid #DCDCDC; border-radius: 16px; padding: 26px 26px 28px; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.04); display: flex; flex-direction: column; }
.hp-plan h3 { margin: 0; font-size: 22px; font-weight: 800; }
.hp-plan-price { margin: 8px 0 16px; display: flex; align-items: baseline; gap: 4px; }
.hp-plan-price b { font-size: 34px; font-weight: 800; letter-spacing: -.5px; } .hp-plan-price span { color: #555; font-weight: 600; }
.hp-plan ul { margin: 0; padding: 16px 0 0; border-top: 1px solid #E6E6E6; list-style: none; display: grid; gap: 10px; }
.hp-plan li { position: relative; padding-left: 24px; font-size: 15px; line-height: 1.45; }
.hp-plan li::before { content: ""; position: absolute; left: 2px; top: 6px; width: 10px; height: 6px; border-left: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(-45deg); }
.hp-price-cta { margin: 26px 0 8px; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.site-foot { flex-wrap: wrap; }
@media (max-width: 860px) { .hp-plans { grid-template-columns: 1fr; } }
@media (max-width: 720px) {
  .hp-about, .hp-pricing { margin-top: 40px; }
  body.public #nav .hp-nav-link { padding: 8px 6px; font-size: 14px; }
  .hp-price-cta { align-items: stretch; }
}
@media (max-width: 420px) { body.public #nav .hp-nav-link { font-size: 13px; padding: 8px 4px; } body.public #nav .login-btn { padding: 7px 12px; } }
:root[data-theme="dark"] .hp-plan { background: #181818; border-color: #444; }
:root[data-theme="dark"] .hp-plan ul { border-top-color: #333; }
:root[data-theme="dark"] .hp-eyebrow, :root[data-theme="dark"] .hp-sign span, :root[data-theme="dark"] .hp-price-note, :root[data-theme="dark"] .hp-plan-price span { color: #B5B5B5; }
:root[data-theme="dark"] .hp-about > p { color: #D6D6D6; }

/* Request staff: Priority sits beside the date and start time (4 columns); on phones it stacks right below them. */
@media (min-width: 721px) {
  .rq-when { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0 18px; }
  .rq-fdate { max-width: calc((100% - 54px) / 4); margin-left: calc(((100% - 54px) / 4 + 18px) * 3); }
}
.rq-prio .hint { line-height: 1.4; }
.pill.prio-standard { background: var(--surface); color: var(--iron); border: 1px solid var(--line); }
.pill.prio-urgent { background: var(--warn-bg); color: var(--warn); }
.pill.prio-last_minute { background: var(--bad-bg); color: var(--bad); }

/* Cancel job */
.pill.cancelled { background: var(--bad-bg); color: var(--bad); }
.tag.cancelled-tag { background: var(--bad-bg); color: var(--bad); border-color: transparent; }
.cj-facts { margin: 0 0 6px; display: grid; gap: 10px; }
.cj-facts div { display: grid; grid-template-columns: 120px 1fr; gap: 10px; align-items: baseline; }
.cj-facts dt { font-size: 13px; font-weight: 700; color: var(--muted); }
.cj-facts dd { margin: 0; }
@media (max-width: 480px) { .cj-facts div { grid-template-columns: 1fr; gap: 2px; } }

/* =====================================================================
   Company → Timesheets (pay week) and Request Review
   ===================================================================== */
.ts-head { align-items: center; }
.ts-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0 0 12px; }
.ts-bar label { margin: 0; font-weight: 700; }
.ts-bar select { width: auto; min-width: 240px; min-height: 44px; }
.ts-sum { margin: 0 0 10px; }
.ts-card { padding: 6px 8px; }
.ts-table { width: 100%; }
.ts-table th.num, .ts-table td.num { text-align: right; white-space: nowrap; }
.ts-table td { vertical-align: top; }
.ts-table td .sub { display: block; margin: 2px 0 0; font-size: 13px; }
.ts-table td[data-k="Status"] .pill { margin-bottom: 4px; }
.ts-flag { display: block; font-size: 13px; font-weight: 700; margin-top: 2px; }
.ts-flag.warn { color: var(--warn); } .ts-flag.bad { color: var(--bad); }
.ts-pick { width: 36px; }
.ts-pick input { width: 20px; height: 20px; }
.ts-reviews h2 { margin-top: 0; }
.ts-rev-list { list-style: none; margin: 0; padding: 0; }
.ts-rev-list > li { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); flex-wrap: wrap; }
.ts-rev-list > li:first-child { border-top: 0; padding-top: 0; }
.ts-rev-act { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ts-note { margin: 6px 0 0; }
.ts-findings { margin: 6px 0 0; padding-left: 18px; }
.ts-findings li.bad { color: var(--bad); } .ts-findings li.warn { color: var(--warn); }
dialog.ts-dialog { width: min(920px, calc(100vw - 24px)); max-width: none; }
.ts-dialog .ts-all { margin: 0 0 6px; }
.ts-dialog .table-wrap { max-height: 46vh; overflow: auto; border: 1px solid var(--line); border-radius: 12px; }
@media (max-width: 720px) {
  .ts-bar select { min-width: 0; flex: 1; }
  .ts-card { padding: 4px 12px; }
  .ts-table thead { display: none; }
  .ts-table, .ts-table tbody, .ts-table tr, .ts-table td { display: block; width: 100%; }
  .ts-table tr { padding: 12px 0; border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px 10px; }
  .ts-table tr:first-child { border-top: 0; }
  .ts-table td { padding: 0 !important; border: 0 !important; }
  .ts-table td[data-k="Worker"], .ts-table td[data-k="Event"], .ts-table td[data-k="Status"] { grid-column: 1 / -1; }
  .ts-table td[data-k="Date"] { grid-column: 1 / -1; color: var(--muted); }
  .ts-table td.num { text-align: left; }
  .ts-table td.num::before { content: attr(data-k); display: block; font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .4px; }
  .ts-table td.ts-pick { grid-column: 1 / -1; }
  .ts-head .btn { width: 100%; }
}
/* Very narrow phones: the public header wraps — logo and theme on top, About us · Log in on a second row.
   (520px while Pricing was in the header; with Pricing hidden everything fits on one row down to ~350px.) */
@media (max-width: 350px) {
  body.public #nav.nav-public .hp-nav-link { padding: 8px 10px 8px 0; font-size: 15px; }
}
@media (max-width: 520px) {
  body.public .topbar { gap: 8px; }
  body.public .brand { gap: 8px; }
  body.public #nav.nav-public { gap: 2px; }
  body.public #nav.nav-public .hp-nav-link { font-size: 15px; padding: 8px 6px; white-space: nowrap; }
  body.public #nav.nav-public .login-btn { white-space: nowrap; padding: 7px 14px; }
}
@media (max-width: 400px) {
  body.public .brand { font-size: 19px; }
  body.public .brand .logo { width: 30px; height: 30px; }
}
@media (max-width: 349px) {
  body.public .topbar { flex-wrap: wrap; row-gap: 10px; }
  body.public #nav.nav-public { flex-basis: 100%; justify-content: flex-start; gap: 2px; }
  body.public #nav.nav-public .hp-nav-link { padding: 8px 10px 8px 0; font-size: 15px; }
  body.public #nav.nav-public .login-btn { margin-left: auto; }
}

/* ---------- Homepage hero: text + buttons left, venue map right (stacks on phones) ---------- */
.hp-hero.hp-split { text-align: left; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); align-items: center; gap: 24px 32px; padding: 48px 0 16px; }
.hp-split .hp-hero-text { min-width: 0; }
.hp-split h1 { font-size: clamp(32px, 3.3vw, 46px); line-height: 1.06; letter-spacing: -1.2px; text-wrap: balance; }
.hp-split p { margin: 16px 0 0; max-width: 520px; font-size: clamp(16px, 1.5vw, 19px); line-height: 1.5; color: #333; text-wrap: pretty; }
.hp-hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 30px; }
.hp-cta { display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 26px; border-radius: 10px; font: inherit; font-size: 17px;
  font-weight: 800; text-decoration: none; cursor: pointer; border: 1.5px solid #000; transition: background .15s, color .15s; }
.hp-cta.solid { background: #000; color: #fff; }
.hp-cta.solid:hover { background: #262626; }
.hp-cta.outline { background: #fff; color: #000; }
.hp-cta.outline:hover { background: #F1F1F1; }
.hp-cta:focus-visible { outline: 3px solid #000; outline-offset: 3px; }
.hp-hero-map { min-width: 0; }
/* Map + marker layer share one frame (1448×616), so the markers stay on their spots at every size and theme. */
.hp-map-stage { position: relative; width: 100%; aspect-ratio: 1448 / 616; }
.hp-map { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.hp-map-dark { display: none; }
:root[data-theme="dark"] .hp-map-light { display: none; }
:root[data-theme="dark"] .hp-map-dark { display: block; }
.hp-markers { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.mk-stem { stroke: #161616; stroke-width: 2.3; stroke-linecap: round; }
.mk-dot { fill: currentColor; stroke: #161616; stroke-width: 1; }
.mk-glow { display: none; }
.mk-disc { stroke: #161616; stroke-width: 1.3; }
.mk-person { fill: none; stroke: #111; stroke-width: 2.4; stroke-linejoin: round; }
:root[data-theme="dark"] .mk-stem { stroke: #EDEDED; stroke-width: 2; }
:root[data-theme="dark"] .mk-dot { stroke: rgba(255,255,255,.85); stroke-width: .8; }
:root[data-theme="dark"] .mk-glow { display: inline; }
:root[data-theme="dark"] .mk-disc { stroke: none; }

/* Crew markers finishing their shift: app.js (startCrewMarkers) adds .off to one marker at a time in a random order.
   Icon, disc, stem, dot and glow fade together. Reduced motion: no fading, all five stay visible. */
.mk { transition: opacity 1.4s ease-in-out; }
.mk.off { opacity: 0; }
@media (prefers-reduced-motion: reduce) { .mk, .mk.off { transition: none; opacity: 1; } }

:root[data-theme="dark"] .hp-split p { color: #B8B8B8; }
:root[data-theme="dark"] .hp-cta { border-color: #F2F2F2; }
:root[data-theme="dark"] .hp-cta.solid { background: #F2F2F2; color: #111; }
:root[data-theme="dark"] .hp-cta.solid:hover { background: #D9D9D9; }
:root[data-theme="dark"] .hp-cta.outline { background: transparent; color: #F2F2F2; }
:root[data-theme="dark"] .hp-cta.outline:hover { background: #222; }
:root[data-theme="dark"] .hp-cta:focus-visible { outline-color: #F2F2F2; }

/* ---------- Homepage sections: one content width, thin dividers with 48px (phones 28px) above and below ---------- */
body.public main.hp-page { max-width: 1040px; }
.hp-page .hp-hero.hp-split { padding-bottom: 0; }
.hp-rule { border: 0; border-top: 1px solid #E4E4E4; margin: 48px 0; width: 100%; }
body.public .hp-page .hp-about, .hp-page .hp-how, .hp-page .hp-pricing { margin-top: 0; }
.hp-page .hp-about { max-width: 680px; }
.hp-page .hp-about > p:last-child { margin-bottom: 0; }
.hp-how h2 { font-size: clamp(26px, 3.4vw, 40px); font-weight: 800; letter-spacing: -.6px; margin: 0 0 22px; line-height: 1.15; }
.hp-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; }
.hp-steps h3 { font-size: 20px; font-weight: 800; letter-spacing: -.3px; margin: 0 0 8px; }
.hp-steps p { margin: 0; font-size: 16px; line-height: 1.55; color: #333; }
.hp-pilot { display: flex; align-items: center; justify-content: space-between; gap: 16px 28px; background: #F3F4F6; border-radius: 14px; padding: 24px 28px; margin-bottom: 64px; }
.hp-pilot h2 { font-size: 22px; font-weight: 800; letter-spacing: -.3px; margin: 0; line-height: 1.25; }
.hp-pilot p { margin: 4px 0 0; font-size: 16px; color: #444; }
.hp-pilot .hp-cta { flex: none; }
:root[data-theme="dark"] .hp-rule { border-top-color: #333336; }
:root[data-theme="dark"] .hp-steps p { color: #C4C4C4; }
:root[data-theme="dark"] .hp-pilot { background: #252528; border: 1px solid #36363A; }
:root[data-theme="dark"] .hp-pilot p { color: #B5B5B5; }
@media (max-width: 860px) {
  .hp-hero.hp-split { grid-template-columns: 1fr; padding-top: 32px; gap: 20px; }
  .hp-split p { max-width: none; }
  .hp-steps { grid-template-columns: 1fr; gap: 20px; }
}
@media (max-width: 720px) {
  .hp-rule { margin: 28px 0; }
  .hp-pilot { flex-direction: column; align-items: flex-start; padding: 20px; margin-bottom: 40px; }
}
@media (max-width: 480px) {
  .hp-hero-cta { flex-direction: column; }
  .hp-cta { width: 100%; }
  .hp-pilot { align-items: stretch; }
}
/* Phones: no venue map (text and buttons only). Lazy loading means hidden images aren't downloaded. */
@media (max-width: 599px) { .hp-hero-map { display: none; } }
.auth-form .req { color: var(--bad, #C8432F); }
.auth-form input[aria-invalid="true"] { border-color: var(--bad, #C8432F); }
