/* ============================================================
   Scout Crew — technician portal styles
   Design language from DESIGN_BRIEF.md (green "command center")
   ============================================================ */

:root {
  --bg: #F5F7F4;
  --bg-warm: #FDF7E3;
  --card: #FFFFFF;
  --card-soft: #F8FAF7;
  --green-900: #0F5132;
  --green-700: #166534;
  --green-600: #15803D;
  --green-500: #16A34A;
  --green-soft: #EAF6EF;
  --text: #111827;
  --muted: #6B7280;
  --soft: #9CA3AF;
  --border: rgba(15, 23, 42, 0.08);
  --shadow-card: 0 12px 30px rgba(15, 23, 42, 0.06);
  --shadow-soft: 0 8px 20px rgba(15, 23, 42, 0.05);
  --radius-lg: 24px;
  --radius-md: 16px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

/* Safety net, not a fix: a single element wider than the viewport otherwise
   drags the whole page wider and strips the side padding from EVERY card (the
   topbar did exactly this). Keep fixing the real cause; this stops one mistake
   from wrecking the layout of the entire portal on a phone. */
html { overflow-x: hidden; }
/* iOS Safari ignores overflow-x on <html> alone and still lets the page pan
   sideways when any element pokes past the edge (Darren, 2026-10-21: "the
   screen will slide side to side"). Clipping on body and the page container
   too, with clip (no scroll container created) where supported, stops the
   pan on the phone. */
html, body { overflow-x: clip; }
body { position: relative; width: 100%; max-width: 100vw; }
.container { overflow-x: clip; }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top right, rgba(234, 246, 239, 0.9), transparent 34%),
    linear-gradient(135deg, #F5F7F4 0%, #FDF7E3 100%);
  background-attachment: fixed;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

.hidden { display: none !important; }
.muted { color: var(--muted); }

/* ---------- brand ---------- */
.brand {
  font-size: 28px;
  font-weight: 800;
  color: var(--green-900);
  letter-spacing: -0.02em;
}
.brand span { color: var(--green-500); }
.brand.small { font-size: 20px; }

/* ---------- login ---------- */
.login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.login-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 36px 28px;
  width: 100%;
  max-width: 380px;
  text-align: center;
}
.login-slogan { margin: 10px 0 24px; font-size: 14px; font-weight: 600; color: var(--green-600); letter-spacing: 0.01em; }
.login-sub { color: var(--muted); margin: 6px 0 24px; font-size: 15px; }
#login-form, #reset-form { display: flex; flex-direction: column; gap: 16px; text-align: left; }
.link-btn { background: none; border: 0; color: var(--green-600); font-family: inherit; font-size: 13.5px; font-weight: 600; cursor: pointer; text-decoration: underline; padding: 2px; margin-top: -4px; }
.link-btn:hover { color: var(--green-700); }
.reset-note { color: var(--green-700); font-size: 13.5px; margin: -4px 0 0; }
.reset-title { font-size: 16px; font-weight: 700; color: var(--text); }
label {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
input {
  font-family: inherit;
  font-size: 16px;
  padding: 13px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card-soft);
  color: var(--text);
  transition: border-color 0.15s, box-shadow 0.15s;
}
input:focus {
  outline: none;
  border-color: var(--green-500);
  box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.12);
}

/* ---------- buttons ---------- */
.btn-primary {
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(135deg, var(--green-700) 0%, var(--green-500) 100%);
  border: none;
  border-radius: 999px;
  padding: 14px;
  cursor: pointer;
  transition: filter 0.18s, transform 0.18s;
}
.btn-primary:hover { filter: brightness(1.05); }
.btn-primary:active { transform: scale(0.99); }
.btn-primary:disabled { opacity: 0.6; cursor: default; }
.btn-ghost {
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--green-700);
  background: var(--green-soft);
  border: none;
  border-radius: 999px;
  padding: 9px 16px;
  cursor: pointer;
  display: inline-block;      /* so an <a> sits like the buttons beside it */
  text-decoration: none;
  line-height: 1.2;
}
.error { color: #991B1B; font-size: 14px; background: #FEE2E2; padding: 10px 12px; border-radius: 10px; }

/* ---------- recent time (tech-editable punches) ---------- */
.ms-row {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 10px 0; border-bottom: 1px solid var(--border);
}
.ms-row:last-of-type { border-bottom: none; }
.ms-when { font-size: 15px; min-width: 0; }
.ms-when .muted { display: block; font-size: 13px; margin-top: 2px; }
.ms-right { display: flex; align-items: center; gap: 8px; flex: none; }
.ms-hrs { font-weight: 700; font-variant-numeric: tabular-nums; }
.ms-flag { font-size: 13px; }
.ms-edit { font-size: 13px; padding: 6px 12px; }
.ms-note { font-size: 12px; margin-top: 10px; }
/* admin timesheet row buttons */
.row-actions { display: flex; gap: 6px; flex: none; }

/* ---------- advancement (Level up) ---------- */
.adv-totals { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 12px; font-size: 14px; color: var(--muted); }
.adv-totals b { color: var(--green-700); font-size: 16px; }
.adv-form { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; }
.adv-form select, .adv-form input { font-family: inherit; font-size: 15px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--card); }
.adv-row { padding: 8px 0; border-bottom: 1px solid var(--border); font-size: 14px; }
.adv-row:last-child { border-bottom: none; }
.adv-ok { color: var(--green-600); font-weight: 700; }
.adv-pend { color: #B45309; font-weight: 700; }
.adv-no { color: #991B1B; font-weight: 700; }
.req-row .row-actions { display: flex; gap: 6px; }
.req-ok { padding: 6px 12px; font-size: 13px; }
.req-no { padding: 6px 12px; font-size: 13px; }
.signoff-history summary { cursor: pointer; color: var(--muted); font-size: 14px; padding: 6px 0; }
.req-peer-head { font-size: 12px; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); margin: 12px 0 6px; }
.recent-row.peer-appr { background: #EFF6FF; border-radius: 10px; padding: 8px 10px; margin-bottom: 4px; }
.req-reverse { padding: 6px 12px; font-size: 13px; color: #991B1B; }
.btn-danger { background: #B91C1C; color: #fff; border: none; border-radius: 12px; padding: 10px 16px; font: inherit; font-weight: 700; cursor: pointer; }
.btn-danger:hover { background: #991B1B; }
/* promotion tracker — front and center on Home */
/* .card.promo-card, not .promo-card — the base .card rule is declared later in
   this file, so at equal specificity its white background would win. */
.card.promo-card {
  background: linear-gradient(135deg, var(--green-900) 0%, var(--green-700) 100%);
  color: #fff; border: none;
}
.promo-top { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 20px; letter-spacing: -0.01em; }
.promo-now { opacity: 0.75; font-size: 15px; font-weight: 700; }
.promo-arrow { opacity: 0.6; }
.promo-tier { font-size: 20px; }
.promo-bar { height: 10px; border-radius: 999px; background: rgba(255,255,255,0.22); margin: 12px 0 6px; overflow: hidden; }
.promo-fill { height: 100%; border-radius: 999px; background: #FCD34D; transition: width .4s; }
.promo-nums { font-size: 13px; font-weight: 700; opacity: 0.9; font-variant-numeric: tabular-nums; }
.promo-cta { font-size: 14px; margin-top: 8px; line-height: 1.4; opacity: 0.95; }
.promo-cta b { color: #FCD34D; }
.promo-sub { font-size: 14px; opacity: 0.85; margin-top: 4px; }
.promo-max { margin-left: auto; font-size: 15px; }

.promo-wage { color: #FCD34D; }
.promo-raise { color: #FCD34D; font-weight: 700; }
/* hands-on mastery minimums on the promo card */
.promo-mastery { margin-top: 12px; padding-top: 12px; border-top: 1px solid rgba(255,255,255,.18); }
.pm-head { font-size: 12px; font-weight: 800; letter-spacing: .02em; opacity: .95; margin-bottom: 8px; }
.pm-row { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.pm-act { flex: 1 1 auto; font-size: 13px; opacity: .95; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pm-bar { flex: 0 0 64px; height: 6px; border-radius: 999px; background: rgba(255,255,255,.2); overflow: hidden; }
.pm-fill { display: block; height: 100%; background: #FCD34D; border-radius: 999px; }
.pm-num { flex: 0 0 auto; font-size: 12.5px; font-weight: 800; font-variant-numeric: tabular-nums; min-width: 44px; text-align: right; }
.pm-more { font-size: 12px; font-weight: 700; margin-top: 6px; padding: 4px 0; background: none;
  border: none; color: #FCD34D; cursor: pointer; opacity: .95; font-family: inherit; }
.pm-more:hover { text-decoration: underline; }
/* Sits on the dark promo card, so it's white-at-low-opacity rather than a gray. */
.pm-foot { font-size: 11.5px; line-height: 1.5; opacity: .7; margin-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.15); padding-top: 9px; }
.pm-foot b { font-weight: 700; opacity: 1; }
.promo-more { margin-top: 10px; font-size: 13px; font-weight: 700; color: #FCD34D; }

/* how you're earning */
.earn-toggle { display: inline-flex; gap: 4px; background: var(--card-soft); border-radius: 999px; padding: 3px; margin-bottom: 14px; }
.earn-toggle button { font: inherit; font-size: 13px; font-weight: 700; border: none; background: none; color: var(--muted); padding: 6px 14px; border-radius: 999px; cursor: pointer; }
.earn-toggle button.on { background: var(--card); color: var(--green-700); box-shadow: var(--shadow-soft); }
.earn-total { font-size: 30px; font-weight: 800; color: var(--green-700); letter-spacing: -0.02em; margin-bottom: 12px; }
.earn-total span { font-size: 14px; font-weight: 600; color: var(--muted); letter-spacing: 0; }
.earn-sec { font-size: 12px; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); margin: 12px 0 4px; }
.earn-row { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 6px 0; border-bottom: 1px solid var(--border); font-size: 15px; }
.earn-row:last-child { border-bottom: none; }
.earn-row b { color: var(--green-700); font-variant-numeric: tabular-nums; }
.earn-tap { cursor: pointer; }
.earn-caret { color: var(--soft); font-weight: 700; transition: transform .15s; display: inline-block; }
.earn-tap.open .earn-caret { transform: rotate(90deg); }
.earn-detail { padding: 2px 0 8px 12px; border-bottom: 1px solid var(--border); }
.earn-det-row { display: flex; justify-content: space-between; gap: 10px; padding: 4px 0; font-size: 14px; color: var(--muted); }
.adv-witness, .adv-field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; color: var(--muted); }
/* quantity stepper on the Level-up form */
.adv-qtywrap { display: flex; align-items: stretch; gap: 8px; }
.adv-qtywrap input { flex: 1; text-align: center; -moz-appearance: textfield; }
.adv-qtywrap input::-webkit-outer-spin-button, .adv-qtywrap input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.adv-qty-btn { flex: none; width: 46px; border: 1px solid var(--border); border-radius: 12px; background: var(--card-soft);
  color: var(--green-700); font-size: 22px; font-weight: 700; line-height: 1; cursor: pointer; user-select: none; }
.adv-qty-btn:active { background: var(--green-soft); }
.adv-qty-hint { font-size: 13px; font-weight: 700; color: var(--green-600); min-height: 1em; }
.adv-qty { color: var(--green-700); font-weight: 800; }
.adv-date-hint { font-size: 12.5px; color: var(--soft); }
.adv-row.adv-penalty { background: #FEF2F2; border-radius: 10px; padding: 6px 10px; }
.adv-pen-pts { color: #B91C1C; font-weight: 800; }
.adv-waiting { background: #FEF3C7; border: 1px solid #FCD34D; border-radius: 14px; padding: 12px 14px; margin-bottom: 14px; }
.adv-waiting-head { font-weight: 800; color: #92400E; margin-bottom: 8px; }
.adv-wait-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 6px 0; font-size: 14px; }
.adv-ok-btn { padding: 7px 14px; font-size: 13px; }
.adv-no-btn { padding: 7px 12px; font-size: 13px; }

/* ---------- app shell ---------- */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  max-width: 760px;
  margin: 0 auto;
}
.topbar-actions { display: flex; gap: 8px; align-items: center; }
.container { max-width: 760px; margin: 0 auto; padding: 8px 20px 60px; }

/* Narrow phones: brand + the two pill buttons are ~387px of non-shrinkable
   (white-space: nowrap) content, which overflows a 390px viewport. That widens
   the page itself, so every card below loses its right-hand padding and looks
   cut off at the screen edge. Shrink the row, and let the actions wrap to a
   second line rather than overflow on very narrow devices. */
@media (max-width: 430px) {
  .topbar { padding: 14px 16px; gap: 8px; flex-wrap: wrap; }
  .brand.small { font-size: 18px; }
  .topbar-actions { gap: 6px; }
  .topbar-actions .btn-ghost { font-size: 13px; padding: 8px 12px; }
}
.welcome { margin: 10px 0 20px; display: flex; align-items: center; gap: 14px; }
.welcome-text { min-width: 0; }
.welcome h1 { font-size: 30px; font-weight: 800; letter-spacing: -0.02em; }
.welcome .muted { font-size: 16px; margin-top: 4px; }

/* avatars (profile photos) */
.avatar {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  border-radius: 50%; background-size: cover; background-position: center; background-repeat: no-repeat;
  color: #fff; font-weight: 800; overflow: hidden; border: 0; padding: 0;
}
.avatar-initials { background: linear-gradient(135deg, var(--green-600), var(--green-900)); }
.avatar-lg { width: 56px; height: 56px; font-size: 20px; cursor: pointer; }
.avatar-lg:hover { filter: brightness(1.05); }
.avatar-sm { width: 30px; height: 30px; font-size: 12px; vertical-align: middle; }
.ct-avatar { cursor: pointer; margin-right: 9px; vertical-align: middle; }
.ct-name { white-space: nowrap; }
.ct-nametext { vertical-align: middle; }

/* ---------- period toggle ---------- */
.toggle {
  display: flex;
  gap: 2px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 4px;
  margin-bottom: 20px;
  box-shadow: var(--shadow-soft);
  overflow-x: auto;
  max-width: 100%;
  -webkit-overflow-scrolling: touch;
}
.toggle::-webkit-scrollbar { display: none; }
.toggle-btn {
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  background: transparent;
  border: none;
  border-radius: 999px;
  padding: 8px 16px;
  cursor: pointer;
  transition: all 0.15s;
  flex: 0 0 auto;
  white-space: nowrap;
}
.toggle-btn.active { background: var(--green-900); color: #fff; }

/* ---------- hero card ---------- */
.hero-card {
  border-radius: var(--radius-lg);
  padding: 28px;
  margin-bottom: 16px;
  color: #fff;
  background:
    radial-gradient(circle at top right, rgba(134, 239, 172, 0.35), transparent 35%),
    linear-gradient(135deg, var(--green-900) 0%, var(--green-600) 100%);
  box-shadow: var(--shadow-card);
}
.hero-card .hero-label { font-size: 14px; font-weight: 500; opacity: 0.85; }
.hero-card .hero-value { font-size: 48px; font-weight: 800; letter-spacing: -0.02em; margin-top: 6px; }
.hero-card .hero-sub { font-size: 14px; opacity: 0.85; margin-top: 8px; }

/* ---------- KPI grid ---------- */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}
.kpi-tile {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 13px 15px;
  box-shadow: var(--shadow-soft);
}
.kpi-tile .kpi-value { font-size: 23px; font-weight: 700; letter-spacing: -0.01em; }
.kpi-tile .kpi-label { font-size: 12.5px; color: var(--muted); margin-top: 2px; font-weight: 500; }
.kpi-tile .kpi-sub { font-weight: 400; opacity: .8; white-space: nowrap; }
.kpi-tile.expandable { cursor: pointer; }
.kd-caret { font-size: 10px; color: var(--soft); }
.kpi-detail { margin-top: 10px; border-top: 1px solid var(--border); padding-top: 8px; }
.kd-row { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; padding: 2px 0; }
.kd-row span:first-child { color: var(--muted); }
.kd-row span:last-child { font-weight: 600; }
.kd-note { font-size: 12px; color: var(--muted); margin-top: 8px; line-height: 1.45; }

/* ---------- cards / lists ---------- */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px 24px;
  box-shadow: var(--shadow-card);
  margin-bottom: 16px;
}
.card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.card-head h2 { font-size: 18px; font-weight: 700; }
.list { display: flex; flex-direction: column; gap: 12px; }

.review-item { border-bottom: 1px solid var(--border); padding-bottom: 12px; }
.review-item:last-child { border-bottom: none; padding-bottom: 0; }
.review-stars { color: #F59E0B; font-size: 16px; letter-spacing: 1px; }
.review-meta { font-size: 13px; color: var(--muted); margin-top: 2px; }
.review-text { font-size: 15px; margin-top: 6px; color: var(--text); }
.named-tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  color: var(--green-700);
  background: var(--green-soft);
  border-radius: 999px;
  padding: 2px 8px;
  vertical-align: middle;
}
.rewritten-tag { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px; font-size: 11px; font-weight: 600; color: #8a5a00; background: rgba(245, 166, 35, 0.16); vertical-align: middle; }
.rb-rewritten { font-size: 12px; color: #8a5a00; margin: 2px 0 4px; }

/* ---------- admin ---------- */
.adminform { display: flex; flex-direction: column; gap: 12px; }
.adminform label { font-size: 13px; font-weight: 600; color: var(--muted); }
.adminform input, .adminform select, .adminform textarea {
  font-family: inherit; font-size: 15px; padding: 10px 12px; margin-top: 5px;
  border: 1px solid var(--border); border-radius: 10px; background: var(--card-soft); width: 100%;
}
.adminform textarea { resize: vertical; }
/* Pinned to the viewport: admin forms run well below the fold, and a banner at
   the top of the document meant every save — good or bad — reported into empty
   space the user was never looking at. */
.flash { position: fixed; left: 50%; transform: translateX(-50%); top: 16px; z-index: 200;
         max-width: min(560px, calc(100vw - 32px)); box-shadow: 0 6px 24px rgba(0,0,0,.18);
         background: var(--green-soft); color: var(--green-900); padding: 10px 14px;
         border-radius: 10px; font-weight: 600; }
.flash-error { background: #fdecea; color: #8a1c12; border: 1px solid #f2b8b2; }
.recent-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; border-bottom: 1px solid var(--border); padding: 8px 0; font-size: 14px; }
.recent-row:last-child { border-bottom: none; }
.rr-text { color: var(--ink, inherit); }
.recent-auto { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; }
.post-recent { margin-top: 8px; font-size: 13px; line-height: 1.4; background: var(--green-soft); border-radius: 10px; padding: 8px 10px; }
.post-recent-row { padding: 2px 0; }
.rr-form { display: grid; gap: 6px; width: 100%; }
.rr-form label { display: flex; flex-direction: column; gap: 2px; font-size: 12.5px; color: var(--muted); }
.rr-form input { font: inherit; font-size: 14px; color: inherit; padding: 6px 8px; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.rr-go { font-size: 12.5px; white-space: nowrap; }
.cc-tile { cursor: pointer; }
/* Meetings tab (2026-11-03) */
.mg-off { display: none !important; }
.mg-tabs { margin: 0 0 12px; }
.mg-tabs .mg-new { border-style: dashed; }
.mg-n { display: inline-block; min-width: 18px; padding: 0 5px; border-radius: 999px; background: var(--green-700); color: #fff; font-size: 11px; line-height: 18px; text-align: center; margin-left: 2px; }
.mg-head { min-width: 0; flex: 1 1 auto; }
.mg-title-in { font: inherit; font-size: 26px; font-weight: 800; letter-spacing: -0.02em; color: inherit; background: transparent; border: 0; border-bottom: 1px dotted transparent; padding: 0; width: 100%; max-width: 100%; }
.mg-title-in:hover, .mg-title-in:focus { border-bottom-color: var(--muted); outline: none; }
.mg-sub { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.mg-sub-in { font: inherit; font-size: 14px; color: inherit; background: transparent; border: 0; border-bottom: 1px dotted var(--muted); padding: 0 2px; min-width: 60px; width: auto; }
.mg-sub-in:focus { outline: none; border-bottom-style: solid; border-bottom-color: var(--green-700); }
.mg-acts { flex: none; }
.mg-tag { font-size: 12px; }
.ms-check.ms-static { cursor: default; }
.mg-past-items { padding: 4px 0 8px 8px; }
.rf-tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.rf-steps { margin-top: 14px; display: grid; gap: 6px; }
.rf-step { display: grid; grid-template-columns: 130px 1fr 90px; align-items: center; gap: 10px; font-size: 14px; }
.rf-step .rf-bar { margin: 0; background: rgba(127,127,127,.15); }
.rf-step .promo-fill { background: var(--green-500); }
.rf-n { text-align: right; }
.rf-fine { margin: 8px 0 0; font-size: 13px; }
@media (max-width: 640px) { .rf-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } .rf-step { grid-template-columns: 100px 1fr 70px; } }
.cc-row-today td { background: var(--green-soft); }
.del { padding: 4px 10px; }

/* ---------- admin entries shown on the portal ---------- */
.announce { display: flex; align-items: center; gap: 10px; background: var(--bg-warm); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 12px 16px; margin-bottom: 16px; }
.announce-tag { font-weight: 700; font-size: 14px; white-space: nowrap; }
.announce-text { font-size: 15px; }

/* recent Coins earned — quick celebratory banner on Home */
.coins-earned {
  display: block; width: 100%; text-align: left; cursor: pointer; border: 0;
  font-family: inherit; font-size: 14.5px; font-weight: 600; color: #7C4A03;
  background: linear-gradient(135deg, #FEF3C7, #FDE68A);
  border-radius: 16px; padding: 12px 16px; margin-bottom: 16px;
}
.coins-earned b { font-weight: 800; color: #5B3A02; }

/* running contest — front and center on Home (charcoal + gold) */
.contest-banner {
  border-radius: var(--radius-lg); padding: 18px 20px; margin-bottom: 16px; color: #fff;
  background:
    radial-gradient(circle at top right, rgba(251, 191, 36, 0.25), transparent 46%),
    linear-gradient(135deg, #1F2937 0%, #111827 100%);
  box-shadow: var(--shadow-card);
}
.contest-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.contest-badge { font-size: 12px; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; color: #FBBF24; }
.contest-countdown { font-size: 12px; font-weight: 700; color: #FCD34D; background: rgba(251, 191, 36, 0.16); border-radius: 999px; padding: 3px 11px; white-space: nowrap; }
.contest-title { font-size: 19px; font-weight: 800; line-height: 1.25; letter-spacing: -0.01em; }
.contest-prize { margin-top: 9px; font-size: 14px; color: rgba(255, 255, 255, 0.9); }
.contest-prize-label { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; color: #FBBF24; margin-right: 7px; }

/* contest team progress bar + claim */
.contest-progress { margin-top: 14px; }
.contest-bar { height: 10px; border-radius: 999px; background: rgba(255, 255, 255, 0.14); overflow: hidden; }
.contest-bar > span { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #F59E0B, #FBBF24); transition: width 0.5s ease; }
.contest-bar-meta { margin-top: 7px; font-size: 13px; color: rgba(255, 255, 255, 0.85); }
.contest-bar-meta b { color: #fff; font-size: 15px; }
.contest-claim {
  margin-top: 12px; width: 100%; padding: 11px; border: none; border-radius: 12px; cursor: pointer;
  font-family: inherit; font-size: 15px; font-weight: 800; color: #1F2937;
  background: linear-gradient(135deg, #FBBF24, #F59E0B);
}
.contest-claim:disabled { opacity: 0.75; cursor: default; background: rgba(255, 255, 255, 0.16); color: #fff; }
.contest-recent { margin-top: 9px; font-size: 12.5px; color: rgba(251, 191, 36, 0.9); }
.contest-undo { display: block; margin: 8px auto 0; background: none; border: 0; cursor: pointer; font-family: inherit; font-size: 11.5px; color: rgba(255, 255, 255, 0.5); text-decoration: underline; }
.contest-undo:hover { color: rgba(255, 255, 255, 0.85); }

/* admin: current contest strip */
.contest-live { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--green-soft); border-radius: 12px; padding: 12px 14px; margin-bottom: 12px; font-size: 14px; }
.contest-live .btn-ghost { color: #B91C1C; white-space: nowrap; }

/* toast — contest claims + light notifications */
.toast {
  position: fixed; left: 50%; bottom: 84px; transform: translate(-50%, 20px);
  background: #111827; color: #fff; font-size: 14px; font-weight: 600;
  padding: 12px 18px; border-radius: 999px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  opacity: 0; pointer-events: none; transition: opacity 0.2s ease, transform 0.2s ease; z-index: 100; max-width: 90vw; text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.msg-item { border-bottom: 1px solid var(--border); padding-bottom: 12px; }
.msg-item:last-child { border-bottom: none; padding-bottom: 0; }
.msg-item.me { background: var(--green-soft); border-radius: 12px; padding: 10px 12px; border-bottom: none; }
.msg-head { font-size: 13px; font-weight: 600; color: var(--muted); }
.msg-text { font-size: 15px; margin-top: 4px; }
.focus-list { margin: 0 0 0 18px; font-size: 15px; }
.focus-list li { margin: 2px 0; }

.tip-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
  padding-bottom: 12px;
}
.tip-item:last-child { border-bottom: none; padding-bottom: 0; }
.tip-date { font-size: 14px; color: var(--muted); }
.tip-amount { font-size: 16px; font-weight: 700; color: var(--green-700); }

.empty { color: var(--soft); font-size: 15px; padding: 6px 0; }
.updated { font-size: 12px; text-align: center; margin-top: 12px; }

/* ---------- achievements ---------- */
.badge-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
  gap: 12px;
}
.badge {
  background: #F3FAF5;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px 12px;
  text-align: center;
}
.badge-icon { font-size: 30px; line-height: 1; }
.badge-title { font-weight: 700; font-size: 14px; margin-top: 8px; }
.badge-desc { font-size: 12px; color: var(--muted); margin-top: 3px; }
.badge-locked { background: transparent; opacity: .55; border-style: dashed; }
.badge-tag { display: inline-block; padding: 1px 7px; margin-left: 4px; border-radius: 999px; background: var(--gold-soft, #FBF2DC); color: var(--gold, #96690A); font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; vertical-align: 1px; }
.badge-count { display: inline-block; min-width: 22px; padding: 1px 7px; margin-left: 4px; border-radius: 999px; background: var(--green-700, #0F5132); color: #fff; font-size: 12px; font-weight: 800; vertical-align: 1px; }

/* ---------- goals / progress bars ---------- */
.goals { display: flex; flex-direction: column; gap: 18px; }
.goal-top { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 8px; }
.goal-label { font-size: 15px; font-weight: 600; }
.goal-num { font-size: 15px; font-weight: 700; }
.bar { height: 10px; background: var(--green-soft); border-radius: 999px; overflow: hidden; }
.bar-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--green-700) 0%, var(--green-500) 100%);
  transition: width 0.4s ease;
}

/* ---------- leaderboard ---------- */
.lb-tabs { display: flex; gap: 6px; margin-bottom: 14px; overflow-x: auto; }
.lb-tabs::-webkit-scrollbar { display: none; }
.lb-tab {
  font-family: inherit; font-size: 13px; font-weight: 600; color: var(--muted);
  background: var(--green-soft); border: none; border-radius: 999px;
  padding: 7px 14px; cursor: pointer; flex: 0 0 auto; white-space: nowrap;
}
.lb-tab.active { background: var(--green-900); color: #fff; }
.lb-list { display: flex; flex-direction: column; gap: 2px; }
.lb-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; }
.lb-row.me { background: var(--green-soft); }
.lb-rank { width: 30px; font-weight: 700; color: var(--muted); text-align: center; flex: 0 0 auto; }
.lb-name { flex: 1; font-weight: 600; font-size: 15px; }
.lb-val { font-weight: 700; color: var(--green-700); }
/* tap-to-explain: rows with a precomputed AI note */
.lb-row.has-explain { cursor: pointer; }
.lb-row.has-explain:hover { background: var(--card-soft); }
.lb-row.me.has-explain:hover { background: var(--green-soft); }
.lb-why { display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; margin-left: 6px; border-radius: 999px; background: var(--green-soft); color: var(--green-700); font-size: 11px; font-weight: 800; vertical-align: middle; }
/* One <p> per sentence now — the sync writes them blank-line separated so a
   phone shows short paragraphs instead of a block of run-on text. */
.explain-text { font-size: 16px; line-height: 1.6; color: var(--text); margin: 0 0 14px; }
.explain-text:last-of-type { margin-bottom: 0; }
.explain-foot { font-size: 12px; color: var(--muted); font-weight: 600; }

/* ---------- sales account view: scorecards ---------- */
.scorecards {
  /* Masonry via CSS columns, not grid. Grid rows are as tall as their tallest
     cell, so one card with its quote list open left a card-sized void beside
     it (and This Month / This Year never match heights anyway). Columns pack
     each card directly under the previous one whatever its height. 300px is
     the width one card needs before client names start wrapping. */
  columns: 300px;
  column-gap: 14px;
}
.scorecard {
  background: var(--card);
  border: 1px solid var(--border);
  border-left: 5px solid var(--green-500);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  box-shadow: var(--shadow-soft);
  /* one card = one piece; never split across columns */
  break-inside: avoid;
  -webkit-column-break-inside: avoid;
  margin-bottom: 14px;
}
.scorecard .sc-label {
  font-size: 12px; font-weight: 700; letter-spacing: 0.6px; text-transform: uppercase;
}
.scorecard .sc-value {
  font-size: 30px; font-weight: 800; color: var(--text); margin: 6px 0 0; line-height: 1.1;
}
.scorecard .sc-sub { font-size: 11px; color: var(--soft); }
.scorecard .sc-bar {
  position: relative; margin-top: 12px; background: #F1F5F9;
  border-radius: 6px; height: 9px;
}
.scorecard .sc-fill { height: 100%; border-radius: 6px; }
.scorecard .sc-tick {
  position: absolute; top: -3px; width: 2px; height: 15px; background: #1F2937;
}
.scorecard .sc-foot { font-size: 11px; color: var(--muted); margin-top: 6px; }
.scorecard .sc-note { font-size: 11px; color: var(--soft); margin-top: 12px; }

/* expandable scorecard quote list */
.scorecard.expandable { cursor: pointer; }
.scorecard .sc-caret { font-size: 10px; color: var(--soft); }
.scorecard .sc-list {
  margin-top: 12px;
  border-top: 1px solid var(--border);
  padding-top: 8px;
  /* A month's worth of approvals is over a hundred rows. Cap it and scroll,
     rather than letting one card run the length of the page. */
  max-height: 340px;
  overflow-y: auto;
}
.scorecard .sc-li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  font-size: 13px;
  padding: 5px 0;
  color: var(--text);
}
/* The name gets its own line and truncates; the date drops beneath it. Before,
   name + date + amount shared one line, so a two-word client broke across lines
   mid-name with the date stranded after it. */
.scorecard .sc-li .sc-li-main { min-width: 0; }   /* lets the ellipsis happen in a flex row */
.scorecard .sc-li .sc-li-client {
  color: var(--text);
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.scorecard .sc-li .sc-li-date {
  color: var(--soft); font-size: 11px;
  display: block; margin-top: 1px;
}
.scorecard .sc-li .sc-li-amt { font-weight: 700; white-space: nowrap; flex: none; }

/* ---------- time clock ---------- */
.clock-status { font-size: 15px; margin-bottom: 12px; }
.clock-status.on { color: var(--green-700); font-weight: 600; }
.clock-status.off { color: var(--muted); }
.clock-elapsed { color: var(--muted); font-weight: 500; }
.clock-btn { width: 100%; font-size: 17px; padding: 14px; }
.clock-btn.out { background: linear-gradient(135deg, #B45309 0%, #D97706 100%); }
.clock-totals { display: flex; gap: 24px; margin-top: 14px; }
.clock-totals div { display: flex; flex-direction: column; }
.clock-totals span { font-size: 12px; }
.clock-totals b { font-size: 20px; font-weight: 700; }

/* ---------- admin timesheets ---------- */
.shift-tools { display: flex; align-items: center; gap: 12px; margin: 12px 0; flex-wrap: wrap; }
.shift-tools label { font-size: 13px; color: var(--muted); display: flex; gap: 6px; align-items: center; }
.ts-totals { font-size: 13px; color: var(--muted); padding: 8px 0 12px; border-bottom: 1px solid var(--border); margin-bottom: 8px; }

/* ---------- coins & rewards ---------- */
.coins-balance { text-align: center; padding: 6px 0 16px; }
.coins-num { font-size: 34px; font-weight: 800; color: var(--green-900); letter-spacing: -0.02em; }
.coins-sub { font-size: 14px; color: var(--muted); margin-top: 2px; }
.coins-penalty { font-size: 13px; font-weight: 600; color: #B91C1C; margin-top: 6px; }
.coins-tiers { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
@media (max-width: 560px) { .coins-tiers { grid-template-columns: 1fr; } }
.coin-tier { border: 1px solid var(--border); border-radius: 14px; padding: 12px 14px; background: var(--card-soft); }
.coin-tier.locked { opacity: 0.5; }
.ct-top { font-size: 14px; margin-bottom: 8px; }
.ct-opts { display: flex; gap: 8px; }
.ct-opts .btn-ghost { flex: 1; padding: 8px; font-size: 13px; }
.ct-opts .btn-ghost:disabled { opacity: 0.5; cursor: default; }
.coins-history { margin-top: 16px; border-top: 1px solid var(--border); padding-top: 12px; }
.ch-head { font-size: 13px; font-weight: 700; color: var(--muted); margin-bottom: 8px; }
.ch-row { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; padding: 4px 0; }
/* Arriving from the earned-today banner: say which row you were sent to. Fades
   out on its own, so it reads as "here" rather than as a permanent state. */
.ch-flash { animation: chFlash 1.8s ease-out; border-radius: 6px; }
/* Continuation lines in a drill-down list — the 2nd..nth client on a day, which
   hang under the "Jobs:" label rather than repeating it. */
.sf-cont { padding-left: 34px; display: inline-block; }
@keyframes chFlash {
  0%, 30% { background: rgba(250, 204, 21, .28); box-shadow: 0 0 0 6px rgba(250, 204, 21, .28); }
  100%    { background: transparent; box-shadow: 0 0 0 6px transparent; }
}
@media (prefers-reduced-motion: reduce) { .ch-flash { animation: none; } }
.tx-amt { font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; }
.tx-pos { color: var(--green-600); }
.tx-neg { color: #B91C1C; }

/* ---------- time clock (Gusto-style) ---------- */
.tc-card { padding: 22px 24px; overflow: hidden; }
.tc-greeting { text-align: center; margin-bottom: 18px; }
.tc-hello { font-size: 15px; color: var(--muted); }
.tc-cta { font-size: 26px; font-weight: 800; color: var(--text); margin-top: 2px; letter-spacing: -0.02em; }
.tc-btn-in {
  width: 100%; padding: 16px; border: none; border-radius: 999px;
  background: linear-gradient(135deg, var(--green-700) 0%, var(--green-500) 100%);
  color: #fff; font-family: inherit; font-size: 18px; font-weight: 700; cursor: pointer;
  margin-bottom: 20px; transition: filter 0.15s;
}
.tc-btn-in:hover { filter: brightness(1.05); }
/* clocked-in green header — bleeds to the card edges like Gusto's dark band */
.tc-hero {
  margin: -22px -24px 18px; padding: 30px 24px 24px; text-align: center; color: #fff;
  background:
    radial-gradient(circle at top right, rgba(134, 239, 172, 0.28), transparent 42%),
    linear-gradient(135deg, var(--green-900) 0%, var(--green-600) 100%);
}
.tc-status { font-size: 24px; font-weight: 800; letter-spacing: -0.01em; }
.tc-timer {
  font-size: 44px; font-weight: 800; margin: 6px 0 20px;
  font-variant-numeric: tabular-nums; letter-spacing: 1px;
}
.tc-btn-out {
  width: 100%; padding: 15px; border: none; border-radius: 999px;
  background: #fff; color: var(--green-700); font-family: inherit;
  font-size: 17px; font-weight: 700; cursor: pointer;
}
.tc-btn-in:disabled, .tc-btn-out:disabled { opacity: 0.6; cursor: default; }
.tc-summary { }
.tc-row { display: flex; justify-content: space-between; align-items: center; padding: 14px 2px; font-size: 15px; }
.tc-row + .tc-row { border-top: 1px dashed var(--border); }
.tc-row span { color: var(--muted); }
.tc-row b { font-weight: 700; color: var(--text); }

/* time clock — extras (breaks, buttons, pay periods, modal) */
.tc-btnrow { display: flex; gap: 10px; margin-bottom: 10px; }
.tc-btn-sec {
  flex: 1; padding: 12px; border-radius: 999px; border: none; cursor: pointer;
  font-family: inherit; font-size: 14px; font-weight: 700;
  background: rgba(255,255,255,0.16); color: #fff;
}
.tc-btn-sec.outline { background: transparent; border: 1.5px solid rgba(255,255,255,0.55); }
.tc-hero.break {
  background: linear-gradient(135deg, #B45309 0%, #D97706 100%);
}
/* non-job time code (recycling run, shop...): paid, not productivity */
.tc-hero.nonjob { background: linear-gradient(135deg, #1E3A5F 0%, #2F6690 100%); }
.tc-sub { font-size: 13px; opacity: 0.85; margin-top: 2px; }
.tc-link {
  display: block; width: 100%; margin: 12px auto 0; padding: 6px; border: none; background: none;
  color: rgba(255,255,255,0.85); font-family: inherit; font-size: 13px; text-decoration: underline; cursor: pointer;
}
.tc-link.dark { color: var(--muted); margin: -8px 0 16px; }
.ms-code { font-size: 11px; font-weight: 700; color: #2F6690; background: rgba(47,102,144,0.12); border-radius: 999px; padding: 2px 8px; }
.ts-code { font-size: 11px; font-weight: 700; color: #2F6690; background: rgba(47,102,144,0.12); border-radius: 999px; padding: 1px 7px; white-space: nowrap; }
.code-opt { cursor: pointer; font-family: inherit; font-size: inherit; color: inherit; margin-bottom: 12px; }
.tc-breakicon { font-size: 30px; margin-bottom: 4px; }
.tc-pphead {
  display: flex; justify-content: space-between; align-items: baseline;
  font-size: 15px; font-weight: 700; padding: 2px 2px 8px; border-bottom: 1px solid var(--border); margin-bottom: 4px;
}
.tc-pphead span { font-size: 13px; font-weight: 500; color: var(--muted); }

/* My pay — per-period pay stub */
.mp-nav { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.mp-arrow {
  width: 34px; height: 34px; flex: none; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--border); background: var(--card-soft); color: var(--green-700);
  font-size: 20px; line-height: 1; font-family: inherit;
}
.mp-arrow:disabled { opacity: 0.3; cursor: default; }
.mp-period { font-size: 14px; font-weight: 700; color: var(--text); text-align: center; }
.mp-cur { display: inline-block; margin-left: 6px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em; color: var(--green-600); }
.mp-gross {
  display: flex; align-items: baseline; justify-content: space-between;
  background: var(--green-soft); border-radius: var(--radius-md); padding: 14px 16px; margin-bottom: 8px;
}
.mp-gross span { font-size: 13px; font-weight: 600; color: var(--green-700); text-transform: uppercase; letter-spacing: 0.03em; }
.mp-gross b { font-size: 26px; font-weight: 800; letter-spacing: -0.02em; color: var(--green-900); }
.mp-rows { margin-top: 4px; }
.mp-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border); }
.mp-row:last-child { border-bottom: none; }
.mp-label { font-size: 15px; color: var(--text); display: flex; flex-direction: column; gap: 2px; }
.mp-sub { font-size: 12px; color: var(--muted); font-weight: 400; }
.mp-val { font-size: 17px; font-weight: 700; white-space: nowrap; }
.mp-empty { padding: 14px 2px; color: var(--muted); font-size: 14px; text-align: center; }
.mp-pto { margin-top: 10px; font-size: 13px; color: var(--muted); }
.mp-note { margin-top: 12px; font-size: 12px; line-height: 1.4; color: var(--soft); }

/* Your paycheck — frozen itemized breakdown */
.pay-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.pay-pick {
  font-family: inherit; font-size: 14px; font-weight: 700; color: var(--text);
  padding: 8px 10px; border-radius: 10px; border: 1px solid var(--border); background: var(--card-soft);
}
.pay-period-label { font-size: 14px; font-weight: 700; color: var(--text); }
.pay-gross { display: flex; flex-direction: column; align-items: flex-end; }
.pay-gross span { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em; color: var(--green-700); }
.pay-gross b { font-size: 24px; font-weight: 800; letter-spacing: -0.02em; color: var(--green-900); }
.pay-sec { border-top: 1px solid var(--border); }
.pay-sec > summary {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 13px 2px; cursor: pointer; list-style: none; font-size: 15px;
}
.pay-sec > summary::-webkit-details-marker { display: none; }
.pay-sec-t { font-weight: 600; color: var(--text); }
.pay-sec-t::before { content: "▸"; display: inline-block; margin-right: 8px; color: var(--soft); font-size: 12px; transition: transform 0.15s; }
.pay-sec[open] .pay-sec-t::before { transform: rotate(90deg); }
.pay-sec-amt { font-weight: 700; white-space: nowrap; }
.pay-sec-body { padding: 2px 2px 12px 18px; }
.pay-line { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 8px 0; }
.pay-line + .pay-line { border-top: 1px dashed var(--border); }
.pay-l { font-size: 14px; color: var(--text); display: flex; flex-direction: column; gap: 2px; }
.pay-sub { font-size: 12px; color: var(--muted); }
.pay-r { font-size: 15px; font-weight: 700; white-space: nowrap; }
.pay-tag {
  display: inline-block; margin-left: 6px; font-size: 10px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.03em; color: var(--green-700); background: var(--green-soft); padding: 1px 6px; border-radius: 999px; vertical-align: middle;
}
.pay-pto { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border); font-size: 13px; color: var(--muted); }
.pay-note { margin-top: 12px; font-size: 12px; line-height: 1.4; color: var(--soft); }

/* link-style cards (Time off) */
.tc-linkcard { padding: 16px 20px; }
.tc-linkrow { display: flex; justify-content: space-between; align-items: center; font-size: 16px; }

/* modal / bottom sheet */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(15,23,42,0.45);
  display: flex; align-items: flex-end; justify-content: center; z-index: 50;
}
.modal {
  background: #fff; width: 100%; max-width: 480px;
  border-radius: 24px 24px 0 0; padding: 24px 22px 32px; position: relative;
  box-shadow: 0 -8px 30px rgba(0,0,0,0.15);
  /* Sheets grow with their content, and the score breakdown is now seven
     categories plus coaching - tall enough to run off the top of the screen
     with nothing to scroll. Cap it and let the sheet itself scroll. */
  max-height: 88vh; max-height: 88dvh;   /* dvh so iOS toolbars don't clip it */
  overflow-y: auto;
  overscroll-behavior: contain;          /* don't drag the page behind it */
  -webkit-overflow-scrolling: touch;
}
@media (min-width: 620px) { .modal-overlay { align-items: center; } .modal { border-radius: 24px; } }
/* Sticky rather than absolute: the modal is now the scroll container, so an
   absolutely-positioned close button would scroll up out of reach on a long
   sheet. Floated so it doesn't take a line of its own. */
.modal-close {
  position: sticky; top: 0; float: right; margin: -6px -4px 0 8px;
  width: 34px; height: 34px; border-radius: 999px; z-index: 2;
  border: none; background: var(--green-soft); color: var(--green-700); font-size: 20px; cursor: pointer; line-height: 1;
}
.modal-title { font-size: 24px; font-weight: 800; }
.modal-sub { font-size: 15px; color: var(--muted); margin: 4px 0 18px; }
.modal-label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 14px; }
.modal-label input, .modal-label textarea {
  font-family: inherit; font-size: 16px; padding: 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--card-soft);
}
.modal-primary { width: 100%; margin-top: 6px; }
.break-option {
  display: flex; align-items: center; gap: 14px; width: 100%; text-align: left;
  border: 1.5px solid var(--border); border-radius: 14px; padding: 16px; margin-bottom: 18px; background: #fff;
}
.break-option.selected { border-color: var(--green-500); box-shadow: 0 0 0 3px rgba(22,163,74,0.12); }
.bo-icon { font-size: 26px; }

/* past pay periods — collapsible */
.payperiods > summary {
  display: flex; align-items: center; justify-content: space-between;
  cursor: pointer; list-style: none; user-select: none;
}
.payperiods > summary::-webkit-details-marker { display: none; }
.payperiods > summary h2 { font-size: 18px; font-weight: 700; }
.payperiods[open] > summary { margin-bottom: 12px; }
.pp-caret { color: var(--soft); font-size: 14px; transition: transform 0.2s; }
.payperiods[open] .pp-caret { transform: rotate(180deg); }

/* ---------- book list (Growth) ---------- */
.booklist > summary {
  display: flex; align-items: center; justify-content: space-between;
  cursor: pointer; list-style: none; user-select: none;
}
.booklist > summary::-webkit-details-marker { display: none; }
.booklist > summary h2 { font-size: 18px; font-weight: 700; }
.booklist[open] > summary { margin-bottom: 12px; }
.bk-meta { display: flex; align-items: center; gap: 8px; color: var(--soft); font-size: 13px; font-weight: 600; }
.bk-caret { font-size: 14px; transition: transform 0.2s; }
.booklist[open] .bk-caret { transform: rotate(180deg); }
.bk-intro { font-size: 14px; line-height: 1.55; color: var(--muted); margin-bottom: 14px; }
.bk-intro b { color: var(--green-700); }
.bk-row { padding: 11px 0; border-bottom: 1px solid var(--border); }
.bk-row:last-child { border-bottom: none; padding-bottom: 0; }
.bk-title { font-size: 15px; font-weight: 700; }
.bk-author { font-size: 13px; color: var(--muted); margin-top: 1px; }
.bk-note { font-size: 13px; color: var(--soft); margin-top: 4px; line-height: 1.45; }

/* ---------- admin payroll ---------- */
.payroll-tools { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.pp-label { font-weight: 700; font-size: 15px; }
.payroll-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
#payroll-table { border-collapse: collapse; width: 100%; font-size: 13px; white-space: nowrap; }
#payroll-table th, #payroll-table td { padding: 8px 10px; border-bottom: 1px solid var(--border); text-align: right; }
#payroll-table th:first-child, #payroll-table td:first-child { text-align: left; position: sticky; left: 0; background: var(--card); }
#payroll-table thead th { color: var(--muted); font-weight: 600; font-size: 12px; }
#payroll-table .pr-name { font-weight: 600; }
#payroll-table input { width: 74px; padding: 6px 8px; border: 1px solid var(--border); border-radius: 8px; font-family: inherit; font-size: 13px; text-align: right; background: var(--card-soft); }
#payroll-table tfoot td { border-top: 2px solid var(--border); border-bottom: none; padding-top: 10px; }
.promo-signoff {
  margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--border);
  font-size: 13px; color: var(--muted);
}

.health-off { opacity: 0.6; }

/* admin home */
.hm-goal { margin-top: 14px; }
.hm-goal-top { display: flex; justify-content: space-between; align-items: baseline; font-size: 14px; margin-bottom: 6px; }
.hm-bar { position: relative; overflow: visible; }
.hm-tick { position: absolute; top: -4px; width: 2px; height: calc(100% + 8px); background: #1F2937; border-radius: 1px; }
.hm-pace { font-size: 12px; margin-top: 6px; color: var(--muted); }
.hm-pace.hm-behind b { color: #991B1B; }
.hm-pace.hm-ahead b { color: var(--green-700); }
.hm-quote { font-size: 16px; line-height: 1.45; }
.hm-by { font-size: 12px; margin-top: 8px; }

/* admin section nav */
.adminnav { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 18px; }
.an-item {
  font: inherit; font-size: 14px; font-weight: 700; cursor: pointer;
  padding: 9px 14px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--card); color: var(--muted);
}
.an-item:hover { background: var(--card-soft); }
.an-item.on { background: var(--green-900); color: #fff; border-color: transparent; }
/* Desktop: a real two-column grid. The nav used to be a floated sticky
   block, and once you scrolled past the float's own height the cards slid
   under it (Darren, 2026-10-16: "the left side menu covers up the page").
   A grid column can't be covered. */
@media (min-width: 900px) {
  .admin-shell { max-width: 1000px; display: grid; grid-template-columns: 150px minmax(0, 1fr); column-gap: 24px; align-items: start; }
  .admin-shell > #flash { grid-column: 1 / -1; }
  .adminnav { grid-column: 1; position: sticky; top: 12px; flex-direction: column; margin: 0; align-self: start; }
  .an-item { text-align: left; }
  .adminbody { grid-column: 2; min-width: 0; max-width: 760px; }
  body.wide .admin-shell { max-width: none; }
  body.wide .adminbody { max-width: none; }
}

.ce-head { font-size: 16px; font-weight: 700; }
.ce-why { font-size: 13px; line-height: 1.5; margin-top: 6px; opacity: 0.92; }
.ce-prov { font-size: 12px; font-weight: 700; opacity: 0.75; }
.ce-more { font-size: 12px; font-weight: 700; margin-top: 8px; opacity: 0.8; }

/* today's forecast */
.td-hero { text-align: center; padding: 4px 0 16px; }
.td-hero-label { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 0.6px; }
.td-hero-value { font-size: 40px; font-weight: 800; color: var(--green-700); line-height: 1.05; margin-top: 2px; }
.td-hero-sub { font-size: 13px; color: var(--muted); margin-top: 2px; }
.td-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.td-col { text-align: center; padding: 12px 6px; border: 1px solid var(--border); border-radius: var(--radius-md); background: var(--card-soft); }
/* Deeper green the higher the tier — one hue, more is more. */
.td-col.td-out { opacity: 0.55; }
.td-col.td-tier1 { background: #EAF6EF; border-color: transparent; }
.td-col.td-tier2 { background: #CFEBDB; border-color: transparent; }
.td-col.td-tier3 { background: #A9DCC1; border-color: transparent; }
.td-hrs { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 0.5px; }
.td-rate-big { font-size: 24px; font-weight: 800; color: var(--text); line-height: 1.1; margin-top: 4px; }
.td-rate-big span { font-size: 13px; font-weight: 700; color: var(--muted); }
.td-tier { font-size: 12px; font-weight: 700; color: var(--green-700); margin-top: 4px; }
.td-coins-sm { font-size: 12px; color: var(--muted); margin-top: 2px; }
.td-note { font-size: 14px; margin-top: 14px; }
.td-detail { margin-top: 10px; }
.td-sum { cursor: pointer; font-size: 13px; font-weight: 600; color: var(--muted); list-style: none; }
.td-sum::-webkit-details-marker { display: none; }
.td-sum::before { content: "▸ "; }
details[open] > .td-sum::before { content: "▾ "; }
.td-job { display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
          font-size: 13px; padding: 7px 0; border-bottom: 1px solid var(--border); }
.td-job:last-child { border-bottom: none; }
.td-job-main { min-width: 0; }
.td-job-client { display: block; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.td-job-title { display: block; color: var(--muted); font-size: 12px; margin-top: 1px; }
.td-job-amt { flex: none; font-weight: 700; text-align: right; }
.td-job-share { display: block; font-size: 11px; font-weight: 600; color: var(--muted); }

/* sales — quote performance */
.period-select { margin-left: auto; padding: 7px 10px; border: 1px solid var(--border); border-radius: 10px; font-family: inherit; font-size: 13px; background: var(--card-soft); color: var(--text); }
.sp-sub { font-size: 11px; color: var(--muted); margin-top: 2px; }
.sp-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; margin-top: 14px; }
.sp-table { border-collapse: collapse; width: 100%; font-size: 13px; white-space: nowrap; }
.sp-table th, .sp-table td { padding: 8px 10px; border-bottom: 1px solid var(--border); text-align: right; }
.sp-table th:first-child, .sp-table td:first-child { text-align: left; }
.sp-table thead th { color: var(--muted); font-weight: 600; font-size: 12px; }
.sp-table .sp-cat { font-weight: 700; }
.sp-table .sp-open { color: var(--green-700); font-weight: 700; }
.sp-note { font-size: 13px; margin-top: 12px; }
/* The key, deliberately quiet: the glyphs already differ by shape, so it's a
   reminder rather than the thing carrying meaning. */
.sp-key { font-size: 12px; margin-top: 10px; display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.sp-key .sp-q-mark { width: auto; margin-left: 10px; }
.sp-key .sp-q-mark:first-child { margin-left: 0; }
/* monthly approvals — a column chart made of divs */
.bc-plot {
  display: flex; align-items: flex-end; gap: 2px;   /* 2px surface gap between bars */
  height: 170px; padding-top: 18px;
  border-bottom: 1px solid var(--border);           /* hairline baseline, recessive */
}
.bc-col { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: center;
          justify-content: flex-end; height: 100%; }
/* The plotting area proper — everything a bar height is a percentage OF. The
   month name lives outside it, so it can't shift a label off its own bar. */
.bc-track { position: relative; flex: 1 1 auto; width: 100%; min-height: 0;
            display: flex; align-items: flex-end; justify-content: center; }
.bc-bar {
  width: 100%; max-width: 24px;                     /* cap the thickness; the rest is air */
  background: var(--green-500);
  border-radius: 4px 4px 0 0;                       /* rounded data-end, square at the baseline */
}
/* The month in progress is not a smaller month — it's an unfinished one. */
.bc-partial {
  background: repeating-linear-gradient(135deg, var(--green-500) 0 5px, #7FCB9B 5px 10px);
}
/* Rides its own bar (inline `bottom` = that bar's height), so the number stays
   attached to the thing it measures. 10px because all twelve months carry one. */
.bc-val { position: absolute; bottom: 0; font-size: 10px; font-weight: 700;
          color: var(--text); white-space: nowrap; letter-spacing: -0.2px; }
.bc-x { font-size: 11px; color: var(--muted); margin-top: 6px; white-space: nowrap; }

/* ---- daily gross profit ------------------------------------------------
   Reuses the .bc-* column chart. Thirty bars instead of twelve, so the value
   labels come OFF every bar (they'd collide) and live in the tooltip and the
   drill-down instead; only the day being read carries a number. */
.gp-plot { height: 150px; gap: 1px; }
.gp-plot .bc-bar { max-width: 14px; cursor: pointer; }
.gp-plot .bc-col { cursor: pointer; }
/* Hours are assumed until the timesheet lands, so the cost side of the newest
   bar is an estimate. Same stripe the unfinished month wears — "not settled
   yet", not "worse". */
.gp-est { background: repeating-linear-gradient(135deg, var(--green-500) 0 5px, #7FCB9B 5px 10px); }
/* A day that cost more than it earned. Rare, and the whole point of the graph
   is that it cannot hide: it gets the house negative red AND keeps its number. */
.gp-loss { background: #B91C1C; }
.gp-plot .bc-col.on .bc-bar { outline: 2px solid var(--green-900); outline-offset: 1px; }
.gp-x { font-size: 10px; color: var(--soft); margin-top: 6px; white-space: nowrap; }
/* Three headline numbers above the chart. */
.gp-tiles { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 12px; }
.gp-tile { flex: 1 1 120px; background: var(--card-soft); border-radius: var(--radius-md); padding: 10px 12px; }
.gp-tile-k { font-size: 11px; color: var(--muted); font-weight: 600; }
.gp-tile-v { font-size: 20px; font-weight: 800; letter-spacing: -0.4px; margin-top: 2px;
             font-variant-numeric: tabular-nums; }
.gp-tile-s { font-size: 11px; color: var(--muted); margin-top: 2px; }
/* The tapped day, opened underneath the bar it came from. */
.gp-day { background: var(--card-soft); border-radius: var(--radius-md); padding: 12px; margin-top: 10px; }
.gp-day-h { font-weight: 800; margin-bottom: 8px; }
.gp-row { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; padding: 3px 0; }
.gp-row b { font-variant-numeric: tabular-nums; }
.gp-row.gp-total { border-top: 1px solid var(--border); margin-top: 5px; padding-top: 6px; font-weight: 800; }
/* Patterns: weekday averages and the category mix, both as plain rows so the
   numbers stay readable and nothing needs a second colour to be understood. */
.gp-pat-h { font-size: 12px; font-weight: 700; color: var(--muted); margin: 14px 0 6px; }
.gp-mix { display: flex; align-items: center; gap: 8px; font-size: 13px; padding: 3px 0; }
.gp-mix-n { flex: 0 0 108px; }
/* The track sits INSIDE .gp-day, which is already --card-soft — so a --card-soft
   track was an invisible groove. Border grey reads as an empty bar. */
.gp-mix-t { flex: 1 1 auto; height: 10px; background: var(--border); border-radius: 999px; overflow: hidden; }
/* display:block is load-bearing, not tidiness. This is a <span>; an inline
   element ignores height, so the fill rendered at zero height and every
   weekday row looked identical — the one comparison the card exists to make. */
.gp-mix-f { display: block; height: 100%; min-width: 3px; background: var(--green-500); border-radius: 999px; }
.gp-mix-v { flex: 0 0 auto; font-variant-numeric: tabular-nums; font-weight: 700; }
/* The row worth noticing, darkened rather than recoloured. */
.gp-mix.gp-hi .gp-mix-f { background: var(--green-900); }
.gp-mix.gp-hi .gp-mix-n, .gp-mix.gp-hi .gp-mix-v { font-weight: 800; }
/* The pattern said out loud. A bar chart shows Saturday is low; this line says
   how low, so Darren doesn't have to do the division himself. */
.gp-insight { font-size: 13px; line-height: 1.5; margin: 6px 0 2px; }
.gp-insight b { font-weight: 800; }

/* a category row opens to the quotes behind it */
.sp-table .sp-row { cursor: pointer; }
.sp-table .sp-row:hover { background: var(--card-soft); }
.sp-caret { color: var(--soft); font-size: 10px; margin-right: 2px; }
.sp-table .sp-detail > td { padding: 0 10px 10px; background: var(--card-soft); }
.sp-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px 0 4px; }
.sp-chip {
  font: inherit; font-size: 12px; font-weight: 600;
  padding: 5px 10px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--border); background: var(--card); color: var(--muted);
}
.sp-chip.on { background: var(--green-soft); color: var(--green-700); border-color: transparent; }
.sp-chips-sort { padding-top: 0; }
.sp-chip.sp-sort { font-weight: 600; }
.sp-chip.sp-sort.on { background: var(--card-soft); color: var(--text); border-color: var(--border); }
.sp-q-tel { color: var(--green-700); font-weight: 600; text-decoration: none; }
.sp-q-tel:hover { text-decoration: underline; }
.sp-q { display: flex; align-items: baseline; gap: 10px; padding: 6px 0; border-bottom: 1px solid var(--border); font-size: 13px; white-space: normal; }
.sp-q:last-child { border-bottom: none; }
.sp-q-mark { flex: none; width: 14px; text-align: center; font-weight: 700; }
.sp-q-mark.sp-won { color: var(--green-600); }
.sp-q-mark.sp-lost { color: #991B1B; }
.sp-q-mark.sp-openq { color: var(--soft); }
.sp-q-main { min-width: 0; flex: 1; }
.sp-q-client { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sp-q-date { display: block; color: var(--soft); font-size: 11px; margin-top: 1px; }
.sp-q-amt { flex: none; font-weight: 700; white-space: nowrap; }

/* private notes — admin only */
.notes-tools { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; margin: 14px 0 6px; }
.notes-tools label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); font-weight: 600; }
.notes-tools select, .notes-tools input { padding: 8px 10px; border: 1px solid var(--border); border-radius: 10px; font-family: inherit; font-size: 13px; background: var(--card-soft); }
.note-row { border-bottom: 1px solid var(--border); padding: 10px 0 10px 12px; border-left: 3px solid transparent; }
.note-row:last-child { border-bottom: none; }
.note-row.note-concern { border-left-color: #991B1B; }
.note-row.note-positive { border-left-color: var(--green-500); }
.note-row.note-neutral { border-left-color: var(--border); }
.note-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 14px; }
.note-head .muted { font-size: 12px; }
.note-acts { margin-left: auto; display: flex; gap: 6px; }
.note-acts .btn-ghost { padding: 5px 10px; font-size: 12px; }
.note-body { font-size: 14px; margin-top: 4px; white-space: pre-wrap; }
.coinrep { margin-top: 14px; border-top: 1px solid var(--border); padding-top: 12px; }
.coinrep-tools { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; margin: 10px 0; }
.coinrep-tools label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); font-weight: 600; }
.coinrep-tools input { padding: 8px 10px; border: 1px solid var(--border); border-radius: 10px; font-family: inherit; font-size: 13px; background: var(--card-soft); }
.coinrep-detail { margin-top: 10px; }
.payroll-weeks { margin-top: 12px; }
.payroll-weeks:empty { display: none; }
.pr-weeks-sum { cursor: pointer; font-size: 13px; font-weight: 600; color: var(--muted); list-style: none; }
.pr-weeks-sum::-webkit-details-marker { display: none; }
.pr-weeks-sum::before { content: "▸ "; }
details[open] > .pr-weeks-sum::before { content: "▾ "; }
table.pr-weeks { border-collapse: collapse; width: 100%; font-size: 13px; white-space: nowrap; margin-top: 8px; }
table.pr-weeks th, table.pr-weeks td { padding: 6px 10px; border-bottom: 1px solid var(--border); text-align: right; }
table.pr-weeks th:first-child, table.pr-weeks td:first-child { text-align: left; }
table.pr-weeks th { color: var(--muted); font-weight: 600; font-size: 12px; }
.pr-ot { color: #991B1B; font-weight: 700; font-size: 12px; }
.payroll-sources { font-size: 12px; margin-top: 10px; }
.payroll-sources:empty { display: none; }
.pr-warn { color: #991B1B; font-weight: 700; }
.payroll-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; flex-wrap: wrap; }
.payroll-btns { display: flex; gap: 10px; }

/* ---------- admin: wide desktop layout ---------- */
.admin-page .container,
.admin-page .topbar { max-width: 1200px; }
/* keep entry forms readable (don't stretch inputs across the whole width) */
.admin-page .adminform { max-width: 560px; }
/* payroll table can breathe; only scrolls if it truly overflows */
.admin-page #payroll-table { min-width: 100%; }
.admin-page #payroll-table input { width: 88px; }

/* ---------- bottom tab bar + tabs ---------- */
.tab-hidden { display: none !important; }
.has-tabbar .container { padding-bottom: 100px; }
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: flex; justify-content: space-around;
  background: rgba(255, 255, 255, 0.97); backdrop-filter: blur(8px);
  border-top: 1px solid var(--border);
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom, 0px));
}
.tabbar-btn {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px;
  background: none; border: none; cursor: pointer; font-family: inherit;
  font-size: 11px; font-weight: 600; color: var(--muted); padding: 6px 0;
}
.tabbar-btn .tb-ico { font-size: 20px; }
.tabbar-btn.active { color: var(--green-700); }
.tabbar-btn { position: relative; }
.tab-badge {
  position: absolute; top: 2px; right: 50%; transform: translateX(18px);
  min-width: 16px; height: 16px; padding: 0 4px; border-radius: 999px;
  background: #DC2626; color: #fff; font-size: 10px; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
}

/* a teammate asked you to sign off — amber, confirm right here (no tab hop) */
.signoff-alert {
  width: 100%; background: linear-gradient(135deg, #D97706 0%, #F59E0B 100%);
  color: #fff; border-radius: 14px; padding: 14px 16px; margin-bottom: 14px;
  box-shadow: 0 6px 16px rgba(217, 119, 6, 0.28);
}
.sa-head { font-size: 14px; font-weight: 800; margin-bottom: 8px; }
.sa-row {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 7px 0; border-top: 1px solid rgba(255,255,255,0.25);
}
.sa-what { font-size: 15px; min-width: 0; }
.sa-meta { display: block; font-size: 13px; opacity: 0.9; margin-top: 2px; }
.sa-actions { display: flex; gap: 6px; flex: none; }
.sa-ok, .sa-no {
  font-family: inherit; font-weight: 800; font-size: 13px; border-radius: 999px;
  padding: 8px 14px; cursor: pointer; border: none;
}
.sa-ok { background: #fff; color: #B45309; }
.sa-no { background: rgba(255,255,255,0.18); color: #fff; }

/* ---------- home hero ---------- */
.home-hero-card {
  border-radius: var(--radius-lg); padding: 26px 24px; margin-bottom: 16px; color: #fff;
  background:
    radial-gradient(circle at top right, rgba(134, 239, 172, 0.30), transparent 38%),
    linear-gradient(135deg, var(--green-900) 0%, var(--green-600) 100%);
  box-shadow: var(--shadow-card);
}
.hh-label { font-size: 14px; opacity: 0.85; }
.hh-big { font-size: 46px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.05; margin-top: 4px; }
.hh-sub { font-size: 13px; opacity: 0.8; }
.hh-wage { margin-top: 14px; font-size: 15px; }
.hh-wage b { font-size: 18px; }
.hh-wage-note { opacity: 0.7; font-size: 12px; }
.hh-review { margin-top: 16px; padding-top: 14px; border-top: 1px solid rgba(255, 255, 255, 0.25); }
.hh-stars { color: #FDE68A; font-size: 14px; letter-spacing: 1px; }
.hh-rtext { font-size: 15px; margin-top: 4px; line-height: 1.45; }
.hh-rtext b { color: #FDE68A; }
.hh-rmeta { font-size: 12px; opacity: 0.75; margin-top: 6px; }
/* home-hero core value / quote — just the words, with a quiet amber accent rail */
.hh-filler { position: relative; margin-top: 18px; padding: 16px 2px 2px 18px; border-top: 1px solid rgba(255, 255, 255, 0.18); }
.hh-filler::before {
  content: ""; position: absolute; left: 0; top: 16px; bottom: 6px; width: 3px; border-radius: 3px;
  background: linear-gradient(180deg, #FDE68A, rgba(253, 230, 138, 0.15));
}
.hh-filler-text { font-size: 21px; line-height: 1.2; font-weight: 700; letter-spacing: -0.01em; color: #fff; }
.hh-filler-desc { margin-top: 6px; font-size: 14px; line-height: 1.5; font-weight: 400; color: rgba(255, 255, 255, 0.82); }

/* home hero — current bonus + two-stat row */
.hh-bonus { text-align: center; padding-bottom: 14px; }
.hh-bonus-label { font-size: 12px; opacity: 0.85; text-transform: uppercase; letter-spacing: 0.6px; }
.hh-bonus-big { font-size: 46px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.05; margin-top: 2px; }
/* Sits under the headline figure, quiet enough that it reads as a footnote to
   the number rather than competing with it. */
.hh-bonus-rate { font-size: 13px; font-weight: 600; opacity: 0.72; margin-top: 6px; font-variant-numeric: tabular-nums; }
.hh-2col { display: flex; gap: 12px; border-top: 1px solid rgba(255, 255, 255, 0.22); padding-top: 14px; }
.hh-2col > div { flex: 1; text-align: center; }
.hh-k { font-size: 12px; opacity: 0.82; }
.hh-v { font-size: 22px; font-weight: 800; margin-top: 2px; }
.hh-kk { font-size: 11px; opacity: 0.65; margin-top: 1px; }

/* new-message banner (Home) */
/* New-message banner: a note from a person, not an alarm. Dark card, the
   sender's face, the first line of what they wrote, a pulsing dot for "new"
   (Darren, 2026-10-29: the red count bar "isn't compelling"). */
.msg-banner {
  display: block; width: 100%; text-align: left; cursor: pointer;
  background: linear-gradient(135deg, #1E293B 0%, #0F172A 100%); color: #fff;
  border: none; font-family: inherit; font-size: 15px; font-weight: 500;
  border-radius: 16px; padding: 14px 16px; margin-bottom: 14px;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.32);
}
.msg-banner .mb-top { display: flex; align-items: center; gap: 10px; }
.msg-banner .avatar-sm { flex: 0 0 auto; border: 2px solid rgba(255,255,255,.35); }
.msg-banner .mb-who { display: flex; flex-direction: column; min-width: 0; flex: 1; line-height: 1.25; }
.msg-banner .mb-who b { font-size: 15.5px; font-weight: 750; }
.msg-banner .mb-when { font-size: 12.5px; opacity: .72; margin-top: 2px; }
.msg-banner .mb-dot {
  width: 10px; height: 10px; border-radius: 50%; background: #FACC15; flex: 0 0 auto;
  box-shadow: 0 0 0 0 rgba(250, 204, 21, .6); animation: mb-pulse 1.8s ease-out infinite;
}
@keyframes mb-pulse { 0% { box-shadow: 0 0 0 0 rgba(250,204,21,.6); } 100% { box-shadow: 0 0 0 10px rgba(250,204,21,0); } }
@media (prefers-reduced-motion: reduce) { .msg-banner .mb-dot { animation: none; } }
.msg-banner .mb-text {
  display: block; margin: 10px 0 0; padding: 10px 12px; font-size: 14.5px; line-height: 1.4;
  background: rgba(255,255,255,.09); border-left: 3px solid #FACC15; border-radius: 0 10px 10px 0;
  font-style: italic; overflow-wrap: anywhere;
}
.msg-banner .mb-cta { display: block; margin-top: 10px; font-size: 13.5px; font-weight: 700; color: #FDE68A; }

/* home hero — prominent coin balance pill */
.hh-coins {
  display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%;
  background: linear-gradient(135deg, #F59E0B 0%, #FCD34D 100%); color: #3B2F00;
  border: none; font-family: inherit; font-size: 18px; font-weight: 800;
  border-radius: 999px; padding: 13px; margin-bottom: 18px; cursor: pointer;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.35);
}
.hh-coins-go { font-size: 12px; font-weight: 700; opacity: 0.7; }

/* leaderboard period selector */
.lb-period {
  font-family: inherit; font-size: 13px; font-weight: 600; color: var(--green-700);
  background: var(--green-soft); border: none; border-radius: 999px;
  padding: 6px 12px; cursor: pointer;
}

/* work-day streak chip on the clock */
/* subtle status chips (rank + streak) — small pills, sized to content */
.stat-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.stat-chip {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 12.5px; font-weight: 700; color: var(--text);
  background: var(--card-soft); border: 1px solid var(--border);
  border-radius: 999px; padding: 5px 11px;
}

/* home hero — "this pay period" section header (governs the whole tile) */
.hh-period {
  display: flex; align-items: center; gap: 12px; justify-content: center;
  font-size: 12px; font-weight: 700; letter-spacing: 1.2px; text-transform: uppercase;
  opacity: 0.85; margin: 4px 0 14px;
}
.hh-period::before, .hh-period::after {
  content: ""; height: 1px; flex: 1; background: rgba(255, 255, 255, 0.25);
}

/* upsell bonus tile — encouraging zero-state */
.mysales-nudge { font-size: 13px; color: var(--muted); margin-top: 12px; text-align: center; }

/* Home pay-period section header (above KPI tiles) */
.pp-eyebrow {
  display: flex; align-items: center; gap: 12px;
  font-size: 12px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase;
  color: var(--muted); margin: 6px 2px 14px;
}
.pp-eyebrow::before, .pp-eyebrow::after { content: ""; height: 1px; flex: 1; background: var(--border); }

/* barometer — monthly produced-revenue goal */
.baro-card { padding: 20px 22px; }
.baro-top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 10px; }
.baro-label { font-size: 13px; color: var(--muted); font-weight: 600; }
.baro-nums { text-align: right; white-space: nowrap; }
.baro-big { font-size: 26px; font-weight: 800; }
.baro-goal { font-size: 13px; color: var(--muted); }
.baro-lvl { display: inline-block; margin-left: 4px; padding: 1px 7px; border-radius: 999px;
  background: var(--green-50, #E8F5EC); color: var(--green-700, #15803D);
  font-size: 11px; font-weight: 700; letter-spacing: .01em; vertical-align: 1px; }
.baro-bar { position: relative; height: 14px; background: #EEF2EE; border-radius: 999px; }
.baro-fill { height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--green-600), var(--green-500)); }
.baro-tick { position: absolute; top: -3px; width: 3px; height: 20px; background: #1F2937; border-radius: 2px; }
.baro-foot { font-size: 12px; color: var(--muted); margin-top: 9px; }

/* daily / weekly target chips — split the monthly goal into today's + this week's number */
.baro-targets { display: flex; gap: 10px; margin-top: 12px; }
.baro-chip { flex: 1; background: var(--green-soft); border: 1px solid var(--border); border-radius: 12px; padding: 9px 13px; display: flex; flex-direction: column; gap: 2px; }
.baro-chip-lbl { font-size: 11px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 0.03em; }
.baro-chip-val { font-size: 19px; font-weight: 800; color: var(--green-700); }

/* personal-best tag */
.record-tag { font-size: 0.72em; }

/* clickable Current bonus + breakdown modal */
.hh-bonus.clickable { cursor: pointer; }
.hh-bonus-caret { font-size: 12px; opacity: 0.7; }
.bd-row { display: flex; justify-content: space-between; padding: 11px 2px; border-bottom: 1px solid var(--border); font-size: 15px; }
.bd-row span { color: var(--muted); }
.bd-total { border-bottom: none; border-top: 2px solid var(--border); margin-top: 4px; font-weight: 700; }
.bd-total span { color: var(--text); }

/* barometer footer marker (matches the pace tick) */
.baro-key { display: inline-block; width: 2px; height: 11px; background: #1F2937; border-radius: 1px; vertical-align: middle; margin: 0 5px; }

/* leaderboard APR value: ahead of pace (green) / behind (red) — subtle */
.lb-val-good { color: #15803D; }
.lb-val-bad { color: #DC2626; }

/* admin crew settings table */
.crew-scroll { overflow-x: auto; }
.crew-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.crew-table th { text-align: left; padding: 7px 8px; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .5px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.crew-table td { padding: 5px 8px; border-bottom: 1px solid var(--border); }
.crew-table .ct-name { font-weight: 600; white-space: nowrap; }
.crew-table input { width: 78px; padding: 6px 8px; border: 1px solid var(--border); border-radius: 8px; font-size: 14px; }
.crew-table select.ct-level { width: 128px; padding: 6px 8px; border: 1px solid var(--border); border-radius: 8px; font-size: 14px; background: var(--card); color: var(--text); }
.crew-table .ct-save { padding: 6px 14px; font-size: 13px; }
/* Crew settings: twelve columns on one screen (Darren, 2026-10-29). Tighter
   cells and inputs sized to what they hold; the People tab is also "wide". */
#crew-table th, #crew-table td { padding: 5px 5px; }
#crew-table input[type="number"] { width: 58px; padding: 6px 6px; }
#crew-table input.ct-start { width: 124px; padding: 6px 4px; }
#crew-table input.ct-title { width: 96px; }
#crew-table select.ct-level { width: 130px; }
#crew-table select.ct-boss { width: 126px; padding: 6px 4px; border: 1px solid var(--border); border-radius: 8px; font-size: 13px; background: var(--card); color: var(--text); }
#crew-table .ct-save { padding: 6px 10px; }
#crew-table .ct-remove { padding: 6px 8px; }
#crew-table .ct-name { position: sticky; left: 0; background: var(--card); z-index: 1; }
.crew-table .ct-remove { padding: 6px 12px; font-size: 13px; color: #B91C1C; }
.crew-table tr.ct-removed { opacity: 0.5; }
.crew-table tr.ct-removed input { color: var(--muted); }
.crew-table tr.ct-removed .ct-remove { color: var(--green-700); }
.ct-tag { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: #B91C1C; background: #FEE2E2; border-radius: 999px; padding: 1px 7px; vertical-align: middle; }

/* compact stat sheet — replaces the KPI tile boxes */
.stat-sheet { padding: 2px 18px; }
.stat-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--border); }
.stat-item:last-child .stat-row { border-bottom: none; }
.stat-label { font-size: 14px; color: var(--muted); font-weight: 500; }
.stat-val { font-size: 20px; font-weight: 700; letter-spacing: -0.01em; white-space: nowrap; }
.stat-row.expandable { cursor: pointer; }
/* Tappable Extra pay rows — tap a total to see the items behind it. */
.xp-tap { cursor: pointer; }
.xp-caret { color: var(--muted); font-weight: 400; display: inline-block; transition: transform .15s ease; }
.xp-tap.xp-open .xp-caret { transform: rotate(90deg); }
.xp-det { padding: 2px 0 10px 2px; }
.xp-det-row { display: flex; justify-content: space-between; gap: 10px; padding: 4px 0;
  font-size: 13.5px; color: var(--muted); }
.xp-det-row b { font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; }
.stat-detail { padding: 2px 0 12px; }

/* master number (Home headline score) */
.score-card { text-align: center; }
.score-label { font-size: 12px; color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: .5px; }
.score-big { font-size: 60px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.05; margin-top: 2px; color: var(--green-700); }
.score-max { font-size: 22px; color: var(--soft); font-weight: 700; }
.score-sub { font-size: 14px; color: var(--muted); margin-top: 2px; }
/* extra-pay total row */
.stat-total .stat-label { font-weight: 700; color: var(--text); }
.stat-total .stat-val { color: var(--green-700); }

/* master-score medal backgrounds (1st gold, 2nd silver, 3rd bronze; 4th+ default white) */
.score-card.rank-1 { background: linear-gradient(135deg, #FEF3C7 0%, #F59E0B 100%); border-color: #F59E0B; }
.score-card.rank-2 { background: linear-gradient(135deg, #F3F4F6 0%, #9CA3AF 100%); border-color: #9CA3AF; }
.score-card.rank-3 { background: linear-gradient(135deg, #FDE4C8 0%, #C2703D 100%); border-color: #C2703D; }
.score-card.rank-1 .score-big, .score-card.rank-2 .score-big, .score-card.rank-3 .score-big { color: #1F2937; }
.score-card.rank-1 .score-label, .score-card.rank-2 .score-label, .score-card.rank-3 .score-label,
.score-card.rank-1 .score-sub, .score-card.rank-2 .score-sub, .score-card.rank-3 .score-sub { color: rgba(31, 41, 55, 0.8); }
.score-card.rank-1 .score-max, .score-card.rank-2 .score-max, .score-card.rank-3 .score-max { color: rgba(31, 41, 55, 0.5); }

/* score tile is tappable for its factor breakdown */
.score-card { cursor: pointer; }
.score-hint { opacity: .7; font-weight: 600; }

/* top performers (Team-tab recognition) */
.tp-list { display: flex; flex-direction: column; gap: 8px; }
.tp-row { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 12px; background: var(--card-soft); border: 1px solid var(--border); }
.tp-row.tp-1 { background: linear-gradient(135deg, #FEF3C7, #FDE68A); border-color: #F59E0B; }
.tp-row.tp-2 { background: linear-gradient(135deg, #F9FAFB, #E5E7EB); border-color: #D1D5DB; }
.tp-row.tp-3 { background: linear-gradient(135deg, #FDF0E4, #F5D9BF); border-color: #E3A26A; }
.tp-row.me { box-shadow: 0 0 0 2px var(--green-500) inset; }
.tp-medal { font-size: 22px; }
.tp-name { flex: 1; font-weight: 700; }
.tp-score { font-weight: 800; font-size: 20px; color: #1F2937; }

/* score factor list (tap-through explainer, no personal numbers) */
.score-factor { padding: 12px 0; border-bottom: 1px solid var(--border); }
.score-factor:last-child { border-bottom: none; }
.sf-name { font-weight: 700; font-size: 15px; }
.sf-desc { font-size: 13px; color: var(--muted); margin-top: 2px; }

/* callback penalty sub-rows (red pills) */
.sf-sub { display: flex; justify-content: space-between; align-items: center; font-size: 13.5px; color: var(--muted); margin-top: 7px; }
.sf-pen { font-weight: 700; color: #DC2626; background: #FEE2E2; border-radius: 999px; padding: 2px 10px; font-size: 12px; }

/* positive (green) pill for score bonuses */
.sf-bonus { font-weight: 700; color: var(--green-700); background: var(--green-soft); border-radius: 999px; padding: 2px 10px; font-size: 12px; }

/* effective wage line in the Extra pay card */
.eff-note { font-size: 12px; color: var(--soft); font-weight: 500; }
.eff-val { color: var(--green-700); }

/* score modal: sections + weight chips (balances the layout) */
.sf-section { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); margin: 18px 0 4px; }
.sf-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.sf-weight { font-weight: 700; color: var(--green-700); background: var(--green-soft); border-radius: 999px; padding: 2px 10px; font-size: 12px; white-space: nowrap; }
.sf-bonus { font-weight: 700; color: var(--green-700); background: var(--green-soft); border-radius: 999px; padding: 2px 10px; font-size: 12px; white-space: nowrap; }
.sf-x { font-weight: 600; color: var(--muted); font-size: 13px; }
.sf-clean { font-size: 14px; color: var(--green-700); padding: 10px 0 2px; }
/* A category that isn't being scored yet. Muted, not red — it is genuinely not
   counting against anyone, and it must not read as a zero the tech earned. */
.sf-pending { opacity: .62; }
.sf-soon { font-weight: 700; color: var(--muted); background: var(--border);
  border-radius: 999px; padding: 2px 10px; font-size: 12px; white-space: nowrap; }
.sf-coach { background: var(--green-soft); border-radius: 12px; padding: 12px 14px; margin: 10px 0 4px; }
.sf-coach-lab { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; color: var(--green-700); }
.sf-coach-txt { font-size: 14px; line-height: 1.5; color: var(--text); margin-top: 6px; }
.sf-coach-strong { color: var(--muted); }
.sf-subtotal { display: flex; justify-content: space-between; align-items: baseline; padding: 10px 0 2px; border-top: 2px solid var(--border); font-size: 14px; color: var(--muted); }
.sf-subtotal b { font-size: 15px; color: var(--text); }
.sf-story { font-size: 14px; line-height: 1.6; color: var(--text); }
.sf-story b { font-weight: 700; }

/* ── Points Guide ─────────────────────────────────────────────────────────── */
.pg-card { padding: 0; overflow: hidden; }
.pg-teaser {
  display: flex; align-items: center; gap: 14px; width: 100%; text-align: left;
  border: none; cursor: pointer; padding: 18px 20px; font: inherit;
  background: linear-gradient(135deg, var(--green-900), var(--green-600)); color: #fff;
}
.pg-teaser-txt { flex: 1; }
.pg-teaser-k { font-size: 11px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; opacity: .82; }
.pg-teaser-h { font-size: 17px; font-weight: 800; margin-top: 3px; line-height: 1.22; }
.pg-teaser-sub { font-size: 12.5px; opacity: .82; margin-top: 5px; }
.pg-teaser-arrow {
  flex: none; width: 40px; height: 40px; border-radius: 999px; font-size: 20px; font-weight: 700;
  background: rgba(255,255,255,.15); display: grid; place-items: center; transition: transform .15s ease;
}
.pg-teaser:hover .pg-teaser-arrow, .pg-teaser:active .pg-teaser-arrow { transform: translateX(3px); }

/* the full sheet, inside the modal */
/* The sheet bleeds over the modal's padding so the mast runs edge to edge.
   It must NOT scroll itself: the .modal is already the scroll container, and
   a second scroller here put its own scrollbar track inside the bleed — a
   white gutter down the whole right edge of the green mast (Darren, 31 Aug). */
.pg-sheet { margin: -24px -22px -32px; }
.pg-mast {
  background: linear-gradient(135deg, var(--green-900) 0%, var(--green-600) 100%);
  color: #fff; padding: 32px 24px 26px; border-radius: 24px 24px 0 0;
}
.pg-mast-k { font-size: 11px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; opacity: .82; }
.pg-mast-h { font-size: 27px; font-weight: 850; letter-spacing: -.02em; margin-top: 5px; text-wrap: balance; }
.pg-mast-p { font-size: 13.5px; opacity: .9; margin-top: 9px; line-height: 1.5; max-width: 46ch; }

.pg-sec { padding: 22px 22px 2px; }
.pg-sec:last-child { padding-bottom: 28px; }
.pg-eye { display: flex; align-items: baseline; gap: 9px; margin-bottom: 10px; flex-wrap: wrap; }
.pg-eye-l { font-size: 12px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--green-600); }
.pg-eye-n { font-size: 12.5px; color: var(--muted); }
.pg-eye.gold .pg-eye-l { color: #9A6B00; }

.pg-tbl { width: 100%; border-collapse: collapse; background: var(--card-soft); border-radius: 14px; overflow: hidden; }
.pg-tbl td { padding: 11px 14px; border-bottom: 1px solid var(--border); font-size: 14.5px; }
.pg-tbl tr:last-child td { border-bottom: none; }
.pg-act { font-weight: 600; color: var(--text); }
.pg-pts { text-align: right; font-weight: 800; color: var(--green-600); font-variant-numeric: tabular-nums; white-space: nowrap; width: 1%; }
.pg-how { text-align: right; white-space: nowrap; width: 1%; }
.pg-tag { display: inline-block; font-size: 10.5px; font-weight: 800; letter-spacing: .02em; padding: 3px 9px; border-radius: 999px; white-space: nowrap; }
.pg-tag.auto  { background: #E3F5E9; color: #137a45; }
.pg-tag.peer  { background: #E7F0FF; color: #1D4ED8; }
.pg-tag.admin { background: #EDE7FF; color: #6D28D9; }
/* Grouped view: the per-row flag becomes the Sr. Tech gate, not the sign-off
   type, since the section heading already says how it's earned. */
.pg-tag.senior { background: #FDF2D8; color: #92610A; }

.pg-tbl.complex { background: #FEF9EC; box-shadow: inset 0 0 0 1px #F1D98A; }
.pg-tbl.complex td { border-bottom-color: #F4E4B0; }
.pg-tbl.complex .pg-act { box-shadow: inset 3px 0 0 #EAB308; }
.pg-tbl.complex .pg-pts { color: #9A6B00; }

.pg-ladder { display: flex; flex-direction: column; gap: 7px; }
.pg-rung { border: 1px solid var(--border); border-radius: 12px; padding: 11px 14px; }
.pg-rung.cur { border-color: var(--green-500); background: var(--green-soft); box-shadow: 0 0 0 1px var(--green-500); }
.pg-rung-main { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.pg-rung-name { font-size: 14.5px; font-weight: 700; color: var(--text); }
.pg-you { font-size: 9.5px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: #fff; background: var(--green-600); padding: 2px 7px; border-radius: 999px; margin-left: 6px; vertical-align: 1px; }
.pg-rung-nums { display: flex; align-items: baseline; gap: 12px; white-space: nowrap; }
.pg-rung-thr { font-size: 13px; font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; }
.pg-rung-wage { font-size: 13.5px; font-weight: 800; color: var(--green-600); font-variant-numeric: tabular-nums; }
.pg-rung-gate { font-size: 12px; color: #9A6B00; margin-top: 7px; background: #FEF9EC; border: 1px solid #F4E4B0; border-radius: 8px; padding: 5px 9px; }

/* Admin "To" picker — toggle chips instead of a <select multiple>. An incident
   usually applies to the whole crew that was on the job, and cmd-clicking a
   dropdown to pick two people is the kind of thing that quietly stops getting
   done. Each selected tech gets its own admin_entries row. */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.chips .chip {
  border: 1px solid var(--border); background: #fff; color: var(--text);
  border-radius: 999px; padding: 7px 14px; font-size: 14px; font-weight: 600;
  font-family: inherit; cursor: pointer; line-height: 1.2;
}
.chips .chip:hover { border-color: var(--green-700); }
.chips .chip.on {
  background: var(--green-700); border-color: var(--green-700); color: #fff;
}
.hint-inline { font-weight: 400; font-size: 12.5px; color: var(--muted); margin-left: 6px; }
.inc-ok { color: var(--green-700); }
.inc-hit { color: #B91C1C; }
/* "includes today" — the score already reflects something logged since the
   nightly sync, so a number that differs from last night is explained. */
.score-live { color: var(--green-700); font-weight: 700; }
/* Tappable score categories — definition + the items behind the number. */
.sf-tap { cursor: pointer; }
.sf-caret { color: var(--soft); font-weight: 400; display: inline-block; transition: transform .15s ease; }
.sf-tap.sf-open .sf-caret { transform: rotate(90deg); }
.sf-detail { padding: 2px 0 12px; border-bottom: 1px solid var(--border); }
.sf-def { font-size: 13.5px; line-height: 1.5; color: var(--muted); background: var(--card-soft);
  border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; }
.sf-item { display: flex; justify-content: space-between; gap: 10px; padding: 5px 2px;
  font-size: 13.5px; color: var(--muted); }
.sf-item b { font-weight: 700; color: var(--text); white-space: nowrap; }

/* Promotion fanfare — shown on the promo card for a week after an admin
   signs one off. A promotion used to arrive as a silently different number. */
.promo-fanfare {
  background: linear-gradient(135deg, var(--green-700), var(--green-500));
  color: #fff; border-radius: var(--radius-md); padding: 18px 16px 16px;
  margin-bottom: 14px; text-align: center; box-shadow: var(--shadow-soft);
}
.pf-burst { font-size: 34px; line-height: 1; animation: pf-pop .5s ease-out; }
.pf-head { font-size: 12px; font-weight: 800; letter-spacing: .08em;
  text-transform: uppercase; opacity: .85; margin-top: 6px; }
.pf-tier { font-size: 26px; font-weight: 800; margin-top: 2px; }
.pf-sub { font-size: 13px; opacity: .9; margin-top: 4px; }
@keyframes pf-pop { 0% { transform: scale(.4); opacity: 0; } 70% { transform: scale(1.15); } 100% { transform: scale(1); opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .pf-burst { animation: none; } }

/* Admin data-health panel — feed freshness, so "can I trust this number" is
   answerable before "what is the number". */
.health-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(215px, 1fr)); gap: 10px; margin-top: 6px; }
.health-item { border: 1px solid var(--border); border-radius: var(--radius-md); padding: 12px 13px; background: var(--card-soft); }
.health-item.health-warn  { border-color: #FBBF24; background: #FFFBEB; }
.health-item.health-stale { border-color: #FCA5A5; background: #FEF2F2; }
.hi-top { display: flex; align-items: center; gap: 7px; }
.hi-icon { font-size: 15px; }
.hi-label { font-weight: 700; font-size: 14px; }
.hi-detail { font-size: 12.5px; color: var(--muted); margin-top: 5px; line-height: 1.45; }

/* Crew scorecard grid */
#score-grid td, #score-grid th { text-align: center; }
#score-grid td:first-child, #score-grid th:first-child { text-align: left; }
.sg-total { font-weight: 800; font-size: 15px; }
.sg-of { color: var(--soft); font-size: 11px; }
.sg-good { color: var(--green-700); font-weight: 700; }
.sg-mid  { color: #B45309; font-weight: 700; }
.sg-low  { color: #B91C1C; font-weight: 700; }
.sg-na   { color: var(--soft); }

/* ---------- "Who did what" — lead splits a multi-tech job's skilled work ----
   Chips, not a dropdown, for the same reason the admin "To" picker uses them:
   this gets answered on a phone at the end of a long day, and anything that
   needs precision tapping quietly stops getting done. */
.ws-intro { font-size: 13.5px; color: var(--muted); line-height: 1.5; margin-bottom: 12px; }
.ws-job {
  border: 1px solid var(--border); border-radius: var(--radius-md);
  padding: 13px 14px; margin-bottom: 12px; background: var(--card-soft);
}
.ws-job-head { display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.ws-when { font-weight: 800; font-size: 14.5px; }
.ws-client { font-size: 13.5px; color: var(--muted); min-width: 0; overflow-wrap: anywhere; }
.ws-tick { font-size: 12px; font-weight: 700; color: var(--green-600); margin-left: auto; }
.ws-act { padding-top: 10px; border-top: 1px solid var(--border); }
.ws-act:first-of-type { border-top: none; padding-top: 0; }
.ws-act-name { font-weight: 700; font-size: 14px; }
.ws-act-items { font-size: 12.5px; color: var(--muted); margin-top: 2px; overflow-wrap: anywhere; }
.ws-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 12px; }
.ws-chip {
  border: 1px solid var(--border); background: #fff; color: var(--text);
  border-radius: 999px; padding: 8px 15px; font-size: 14px; font-weight: 600;
  font-family: inherit; cursor: pointer; line-height: 1.2;
}
.ws-chip.on { background: var(--green-700); border-color: var(--green-700); color: #fff; }
.ws-save {
  width: 100%; font-family: inherit; font-weight: 800; font-size: 14px;
  border: none; border-radius: 999px; padding: 11px 16px; cursor: pointer;
  background: var(--green-700); color: #fff;
}
.ws-save:disabled { background: #E5E7EB; color: var(--soft); cursor: default; }
.ws-done { margin-top: 6px; }
.ws-done > summary { cursor: pointer; font-size: 13px; color: var(--muted); font-weight: 600; padding: 6px 0; }

/* My pay: the extras fold in here (the separate "Extra pay" card is gone), so
   the itemised rows are tappable in place and the effective wage closes it. */
.mp-tap { cursor: pointer; }
.mp-tap .xp-caret { color: var(--soft); font-weight: 400; display: inline-block; transition: transform .15s ease; }
.mp-tap.xp-open .xp-caret { transform: rotate(90deg); }
.mp-eff { border-top: 1px solid var(--border); margin-top: 4px; padding-top: 12px; }

/* Promo card: the wage they're on now, shown next to the promoted wage so the
   "+$1 over current pay" rule for grandfathered techs is checkable on sight. */
.promo-now-wage { opacity: 0.75; font-weight: 600; }

/* Coins: cash and time off are two ladders now, in different units — cash in
   round dollars (same for everyone), time off in round hours priced per wage. */
.coins-group { margin-top: 18px; }
.cg-head {
  display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap;
  font-size: 13px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  color: var(--muted); margin-bottom: 8px;
}
.cg-sub { font-size: 12px; font-weight: 500; letter-spacing: 0; text-transform: none; color: var(--soft); }
.ct-cost { font-size: 12px; color: var(--soft); margin-top: 6px; font-variant-numeric: tabular-nums; }

/* Admin crew scorecard, styled like the crew leaderboard — medal, avatar, name,
   big score — while keeping the per-category columns that make it worth having
   its own table. */
#score-grid .sg-row:hover { background: var(--card-soft); }
#score-grid td, #score-grid th { vertical-align: middle; }
#score-grid td.sg-who, #score-grid th.sg-who { text-align: left; white-space: nowrap; }
.sg-who { display: flex; align-items: center; gap: 9px; }
thead .sg-who { display: table-cell; }
.sg-rank { width: 24px; text-align: center; font-weight: 700; color: var(--muted); flex: 0 0 auto; }
.sg-name { font-weight: 650; font-size: 14.5px; }
#score-grid .sg-total { font-weight: 800; font-size: 17px; font-variant-numeric: tabular-nums; }

/* ---------- admin: per-tech mastery gaps under the ladder row ---------- */
.lg-row { cursor: pointer; }
.lg-caret { color: var(--soft); font-weight: 700; display: inline-block; transition: transform .15s ease; }
.lg-row.open .lg-caret { transform: rotate(90deg); }
.lg-detail > td { background: var(--card-soft); padding: 12px 14px !important; }
.lg-gap-head { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em;
  color: var(--muted); margin-bottom: 8px; }
.lg-gaps { display: grid; gap: 4px 24px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.lg-gap { display: flex; justify-content: space-between; gap: 12px; font-size: 13.5px; color: var(--text); }
.lg-gap b { font-variant-numeric: tabular-nums; color: var(--muted); }


/* Reviews needing a customer — the admin to-do queue. One block per review, kept
   visually quiet: an empty queue is the normal state and shouldn't shout. */
.revtodo { border: 1px solid var(--line, #e6e8e6); border-radius: 10px; padding: 10px 12px; margin-bottom: 10px; }
.rt-head { font-size: 14px; margin-bottom: 4px; }
.rt-stars { color: #d4a017; letter-spacing: 1px; }
.rt-text { font-size: 13px; line-height: 1.45; opacity: .85; margin-bottom: 8px; }
.rt-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.rt-actions .rt-pick { flex: 1 1 220px; min-width: 0; }
.rt-none { font-size: 12px; margin-top: 6px; }


/* Count of things waiting on the admin, on the section nav. Small and warm
   rather than alarming — it's a to-do, not an error. */
.an-badge { display: inline-block; min-width: 18px; padding: 0 5px; margin-left: 6px;
  border-radius: 9px; background: #d97706; color: #fff; font-size: 11px;
  font-weight: 700; line-height: 18px; text-align: center; vertical-align: middle; }

/* Custom date range on the sales view. Kept to one line on a phone by letting
   the inputs shrink rather than wrap the labels away from their fields. */
.custom-range {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 10px 14px 2px;
  font-size: 0.85rem;
}
.custom-range label {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
}
.custom-range input[type="date"] {
  min-width: 0;
  padding: 6px 8px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font: inherit;
  background: var(--card);
  color: inherit;
}
.btn-small {
  padding: 6px 14px;
  border: 0;
  border-radius: 8px;
  background: var(--green-600);
  color: #fff;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
.btn-small:active { transform: translateY(1px); }

/* Target tables in the admin settings section. Deliberately plainer than
   .crew-table — these are read-back lists confirming what was saved, not
   editable grids. */
.settings-table { margin-top: 10px; }
.mini-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.mini-table td { padding: 5px 8px; border-bottom: 1px solid var(--border); }
.mini-table td.num { text-align: right; font-variant-numeric: tabular-nums; }
.mini-table tr.is-now td { font-weight: 700; }
.mini-table tr.total-row td {
  border-top: 2px solid var(--border);
  border-bottom: 0;
  padding-top: 8px;
  font-weight: 700;
}
/* The "Earns" toggle in Crew settings — a checkbox in a dense row needs to be
   hittable on a phone without widening the column. */
.crew-table .ct-earns-cell { text-align: center; }
.crew-table .ct-earns { width: 18px; height: 18px; accent-color: var(--green-600); cursor: pointer; }
/* A closed period sitting among the live ones: same shape, quieter, so it reads
   as context rather than competing with this week's number. */
.scorecard.sc-closed { background: var(--card-soft); }
.scorecard.sc-closed .sc-value { color: var(--muted); }

/* Seasonal curve editor. 52 editable weeks in one card, so which month a week
   belongs to has to be obvious at a glance, and the running total has to stay
   visible while you type — changing one week silently changes what every other
   week is a share of. */
.curve-foot { display: flex; align-items: center; gap: 10px; padding: 12px 14px 2px; flex-wrap: wrap; }
.curve-total { font-size: 13px; font-variant-numeric: tabular-nums; color: var(--muted); margin-right: auto; }
.curve-total.is-off { color: #B45309; font-weight: 600; }
.mini-table tr.month-row td {
  padding-top: 12px;
  font-weight: 700;
  color: var(--green-700);
  border-bottom: 1px solid var(--border);
}
.mini-table tr.month-row td.num { font-weight: 700; color: var(--green-700); }
.mini-table tr.week-row td { color: var(--muted); border-bottom: 0; padding: 3px 8px; }
#curve-table input {
  width: 78px; padding: 5px 8px; border: 1px solid var(--border); border-radius: 8px;
  font-family: inherit; font-size: 13px; text-align: right; background: var(--card-soft);
  color: var(--text);
}
/* An edited-but-unsaved week is the one thing you need to be able to find again
   before pressing Save. */
#curve-table input.is-edited { border-color: var(--green-500); background: var(--green-soft); color: var(--text); }
.curve-note { font-size: 12.5px; color: var(--muted); margin: 8px 14px 0; line-height: 1.5; }
.curve-mirror { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; color: var(--text); }

/* ---------- the jobs behind a mastery count ---------- */
/* The row was a label; it is now a control, so it has to look like one. */
.pm-row[data-act] { cursor: pointer; border-radius: 6px; padding: 2px 4px; margin-left: -4px; }
.pm-row[data-act]:hover { background: rgba(255,255,255,.06); }
.pm-row[data-act]:focus-visible { outline: 2px solid var(--green-300, #7FCB9B); outline-offset: 1px; }
.pm-caret { flex: 0 0 auto; font-size: 10px; opacity: .55; transition: transform .15s; }
.pm-row[aria-expanded="true"] .pm-caret { transform: rotate(180deg); }
.pm-jobs { margin: 2px 0 10px 4px; padding-left: 10px; border-left: 2px solid rgba(255,255,255,.14); }
.pm-jobs-msg { font-size: 12px; opacity: .7; padding: 4px 0 6px; }
.pm-job { display: flex; align-items: baseline; gap: 8px; padding: 4px 0; font-size: 12.5px; }
.pm-j-date { flex: 0 0 auto; opacity: .6; font-variant-numeric: tabular-nums; }
.pm-j-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
.pm-j-who { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pm-j-what { opacity: .62; font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pm-j-n { flex: 0 0 auto; font-weight: 800; font-variant-numeric: tabular-nums; }
.pm-j-tag { flex: 0 0 auto; font-size: 10px; font-weight: 800; letter-spacing: .04em;
            text-transform: uppercase; opacity: .75; }

/* ---------- line-item wording queue (admin) ---------- */
.wording-row { align-items: center; gap: 10px; flex-wrap: wrap; }
.wording-main { flex: 1 1 260px; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.wording-row .wsel, .wording-row .wsel2 {
  flex: 0 0 auto; max-width: 240px; font: inherit; font-size: 12.5px;
  padding: 5px 8px; border-radius: 8px;
  border: 1px solid var(--border); background: var(--card); color: inherit;
}

/* ---------- "where you stand" — the private half of the board ---------- */
.my-ranks { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--border); }
.mr-head { font-size: 12px; font-weight: 800; letter-spacing: .04em;
           text-transform: uppercase; opacity: .75; margin-bottom: 8px; }
.mr-private { font-weight: 600; text-transform: none; letter-spacing: 0; opacity: .8; }
.mr-row { display: flex; align-items: center; gap: 10px; padding: 7px 0;
          border-bottom: 1px solid var(--border-soft, rgba(255,255,255,.06)); }
.mr-row:last-child { border-bottom: none; }
.mr-label { flex: 1 1 auto; font-size: 13.5px; }
.mr-rank { flex: 0 0 auto; font-weight: 800; font-size: 13.5px; font-variant-numeric: tabular-nums; }
.mr-of { font-weight: 600; opacity: .55; font-size: 12px; }
.mr-val { flex: 0 0 auto; min-width: 76px; text-align: right;
          font-weight: 800; font-variant-numeric: tabular-nums; }


/* Career credit, said plainly at the top of the list it explains. */
.pm-credit { font-size: 12.5px; line-height: 1.45; padding: 7px 9px; margin: 4px 0 6px;
             border-radius: 7px; background: rgba(127,203,155,.14); }
.pm-credit b { font-weight: 800; }
.mr-none { font-size: 13px; opacity: .7; line-height: 1.5; }
/* A ladder row with no gate: says so, rather than being a tap that does nothing. */
.lg-nogate { font-size: 10.5px; font-weight: 700; letter-spacing: .02em;
             opacity: .5; white-space: nowrap; }

/* ---------- give a crew member a login (admin) ---------- */
.hire-form { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-top: 4px; }
.hire-in { font: inherit; font-size: 13.5px; padding: 8px 10px; border-radius: 9px;
           border: 1px solid var(--border); background: var(--card); color: inherit; min-width: 170px; }
.hire-result { margin-top: 12px; padding: 12px 14px; border-radius: 10px;
               background: var(--card-soft); font-size: 13.5px; line-height: 1.55; }
.hire-pw { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 15px;
           font-weight: 700; letter-spacing: .5px; user-select: all; }

/* ---------- mastered: the half of the card that says what he's done ---------- */
.pm-done { margin-bottom: 14px; padding-bottom: 12px;
           border-bottom: 1px solid rgba(255,255,255,.10); }
.pm-done-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 8px; }
.pm-done-k { font-size: 13px; font-weight: 800; letter-spacing: .01em; }
.pm-done-n { margin-left: auto; font-size: 13px; font-variant-numeric: tabular-nums; opacity: .85; }
.pm-done-n b { font-size: 16px; font-weight: 800; }
.pm-done-bar { height: 6px; border-radius: 999px; background: rgba(255,255,255,.14);
               overflow: hidden; margin-bottom: 10px; }
.pm-done-bar span { display: block; height: 100%; border-radius: 999px;
                    background: var(--green-300, #7FCB9B); }
.pm-row-done .pm-act { opacity: 1; }
.pm-row-done .pm-num { min-width: 34px; }
.pm-row-done::before { content: "✓"; flex: 0 0 auto; font-size: 11px; font-weight: 800;
                       opacity: .75; margin-right: 2px; }
.pm-allclear { font-weight: 700; }
.pm-more-done { opacity: .85; }

/* ---------- your numbers: a man's own figures, on his own home screen ---------- */
.mynum-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; }
.mynum { padding: 12px 14px; border-radius: 12px; background: var(--card-soft, rgba(255,255,255,.05)); }
.mynum.first { background: rgba(255,209,102,.14); }
.mynum-v { font-size: 24px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.mynum-l { font-size: 13px; font-weight: 700; margin-top: 1px; }
.mynum-r { font-size: 12px; font-weight: 700; opacity: .8; margin-top: 4px; }
.mynum-h { font-size: 11px; opacity: .55; margin-top: 2px; line-height: 1.35; }
.mynum-foot { font-size: 12px; opacity: .6; margin: 10px 0 0; }
/* The bar he cleared, next to what he's actually done — "1175/100" says more
   than "1175", which on its own is a number with nothing to lean on. */
.pm-of { font-weight: 600; opacity: .45; font-size: 11.5px; }
/* Opens the Points Guide from the promotion card. It used to say "in the Points
   Guide below", which was a card and a scroll away from the man reading it. */
.pm-guide {
  display: block; width: 100%; margin-top: 12px; padding: 11px 14px;
  font: inherit; font-size: 13.5px; font-weight: 700; text-align: left;
  color: inherit; cursor: pointer;
  background: rgba(255,255,255,.10); border: 1px solid rgba(255,255,255,.16);
  border-radius: 10px;
}
.pm-guide:hover { background: rgba(255,255,255,.16); }
.pm-guide:focus-visible { outline: 2px solid var(--green-300, #7FCB9B); outline-offset: 2px; }
/* A tier already won at a normal day: stated, not celebrated — the useful
   information is the bar above it, not this one. */
.td-col .td-tier { line-height: 1.25; }

/* Cakewalk day: the ladder says nothing (every bar is already won at 8 hours),
   so the job takes the space and the tier becomes one quiet line. */
.td-nudge { margin: 10px 0 2px; font-size: 14px; line-height: 1.5; text-align: center;
            color: var(--muted, #5B6A62); }
.td-nudge b { color: inherit; font-weight: 800; }
.td-detail-open > .td-sum { font-size: 13px; opacity: .7; }
.td-detail-open .td-job { padding: 10px 0; font-size: 16px; }
.td-detail-open .td-job-client { font-weight: 700; }

/* The Growth-points twin of the Coins tile: same shape, different currency, so
   it reads as a sibling rather than a second thing to learn. Green rather than
   gold — Coins are money, points are the ladder. */
.growth-earned { background: linear-gradient(180deg, #E4F0E8 0%, #D6E9DC 100%);
                 border-color: rgba(27,103,66,.22); color: #14432C; }
.growth-earned .ce-head b { color: #0F5132; }

/* Dollars ride under the count: Darren asked for quotes approved, so the number
   of quotes is the headline and the money is the supporting detail. */
.hm-sales-amt { font-size: 12px; color: var(--muted); margin-top: 2px; }
.hm-sales-who { font-size: 13px; font-weight: 600; margin: 10px 0 6px; }

/* The approval banner. Red because Darren asked for red, and because it is the
   one thing on Home that is news rather than status — everything else is a
   number that was already true yesterday. */
.quote-banner { display: block; width: 100%; text-align: left; cursor: pointer;
  background: linear-gradient(180deg, #DC2626 0%, #B91C1C 100%); color: #fff;
  border: none; border-radius: 14px; padding: 12px 14px; margin-bottom: 12px;
  box-shadow: 0 2px 10px rgba(185,28,28,.28); }
.quote-banner .qb-head { font-weight: 700; font-size: 15px; margin-bottom: 4px; }
.quote-banner .qb-line { font-size: 14px; line-height: 1.45; }
.quote-banner .qb-foot { font-size: 11px; opacity: .8; margin-top: 6px; }

/* The season's goal under the year card. Quieter than the pace line above it:
   pace is what to do today, this is what the year is for. */
.sc-year { font-size: 12px; color: var(--muted); margin-top: 6px;
  padding-top: 6px; border-top: 1px solid var(--border); }
.sc-year b { color: var(--text); }

/* The remaining-months plan, folded away under the year card. Closed by default:
   it answers "what do I do about it", which is a second question. */
.mp { margin-top: 8px; }
.mp-sum { font-size: 12px; color: var(--muted); cursor: pointer; }
.mp-table { width: 100%; border-collapse: collapse; margin-top: 8px; font-size: 13px; }
.mp-table th { font-size: 11px; font-weight: 600; color: var(--muted); text-align: left;
  padding: 0 0 4px; border-bottom: 1px solid var(--border); }
.mp-table td { padding: 4px 0; border-bottom: 1px solid var(--border); }
.mp-num { text-align: right; font-variant-numeric: tabular-nums; }
.mp-hot { color: #B91C1C; font-weight: 600; }
.mp-note { font-size: 11px; color: var(--muted); margin-top: 6px; line-height: 1.4; }

/* The sheet's Explanation, under the activity name in the Points Guide. Smaller
   and quieter than the name — it's the answer to "does what I did count?", read
   once, not scanned. */
/* Name and points on one line, the explanation full-width underneath. The two
   <tr>s are one visual row: the name row drops its rule so the pair reads as a
   block, and the text row carries the divider. */
.pg-tbl tr.has-why td { border-bottom: none; padding-bottom: 2px; }
.pg-tbl tr.pg-r-why td { padding: 0 14px 11px; }
.pg-why { font-size: 12.5px; line-height: 1.5; color: var(--muted); font-weight: 400; }
.pg-tbl tr.pg-r-why:last-child td { border-bottom: none; }
.pg-act { hyphens: none; overflow-wrap: anywhere; }
/* Nothing in this sheet may be wider than the sheet. The graduated point chips
   are three nowrap boxes; on a narrow modal they used to push the table past
   its container and take the whole page sideways with it. */
.pg-sheet { overflow-x: hidden; }
/* The rung ladder for the two graduated activities, said in words under the
   name instead of as three chips fighting the points column. */
.pg-rungs { font-size: 11px; line-height: 1.5; color: var(--muted); margin-top: 4px; }
.pg-rungs b { color: var(--green-700); font-weight: 700; }
.pg-rung-bit.you { color: var(--text); font-weight: 600; }
.pg-rung-bit.you b { color: var(--green-600); }

/* Full leaderboard (admin). Self-contained on purpose — the score grid's .sg-who
   sets display:flex on the CELL, and the CREW leaderboard already owns every
   .lb-* name (.lb-row is a flex list row, which blockifies a <tr>'s cells).
   Hence the alb- prefix: this table shares no class with either. */
#alb-grid td, #alb-grid th { vertical-align: middle; }
#alb-grid th.alb-num, #alb-grid td.alb-num { text-align: right; white-space: nowrap; }
#alb-grid td.alb-num { font-variant-numeric: tabular-nums; font-weight: 650; }
.alb-who { display: flex; align-items: center; gap: 9px; }
.alb-rank { width: 22px; text-align: center; font-weight: 700; color: var(--muted); flex: 0 0 auto; }
.alb-name { font-weight: 650; font-size: 14.5px; white-space: nowrap; }
.alb-good { color: var(--green-700); }
.alb-low { color: #B91C1C; }
.alb-dim { color: var(--soft); font-weight: 400; }
/* Sortable headings read as buttons, because they are. */
.alb-sort { cursor: pointer; user-select: none; }
.alb-sort:hover { color: var(--text); background: var(--card-soft); }
/* The inactive marker is faint but always there, so a heading reads as a
   control before you hover it. */
.alb-arrow { color: var(--green-700); }
.alb-arrow-off { opacity: .32; }
.alb-sort:hover .alb-arrow-off { opacity: .8; }

/* Job profitability table borrows the leaderboard's number styling (the alb-
   classes above are element styles, but the alignment rules are scoped to
   #alb-grid, so they are repeated for this grid). */
#jp-grid th.alb-num, #jp-grid td.alb-num { text-align: right; white-space: nowrap; }
#jp-grid td.alb-num { font-variant-numeric: tabular-nums; font-weight: 650; }
/* One long job title must not push seven number columns off screen. */
.jp-job { color: inherit; text-decoration: none; display: inline-block; max-width: 340px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: middle; }
.jp-job:hover { text-decoration: underline; }

/* On-the-clock board: one row per tech with a timer today. */
.clk-row { display: flex; align-items: center; gap: 10px; padding: 8px 2px;
  border-bottom: 1px solid var(--border); font-size: 14.5px; }
.clk-row:last-child { border-bottom: none; }
.clk-dot { width: 9px; height: 9px; border-radius: 50%; flex: 0 0 auto; background: var(--soft); }
.clk-on .clk-dot { background: var(--green-700); box-shadow: 0 0 0 3px rgba(21,128,61,.18); }
.clk-off { opacity: .62; }
.clk-name { font-weight: 650; white-space: nowrap; }
.clk-io { color: var(--muted); white-space: nowrap; }
.clk-hrs { font-variant-numeric: tabular-nums; font-weight: 700; white-space: nowrap; }
.clk-job { margin-left: auto; text-align: right; overflow: hidden; text-overflow: ellipsis; }
.clk-warn { color: #B4472C; font-weight: 600; }

/* Produced-revenue pulse: readout line the bars write into on hover. */
.ap-readout { font-size: 14px; padding: 6px 2px 10px; min-height: 22px; }
.ap-col { cursor: pointer; }

/* Sales-desk drill-down: tap a tile, the quotes behind it open underneath. */
.hm-sales-tile { cursor: pointer; }
.hm-sales-tile:hover { background: var(--card-soft); }
.hm-squotes { margin: 8px 0 4px; border: 1px solid var(--border); border-radius: 10px; padding: 6px 10px; }
.hm-squotes-head { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px;
  color: var(--muted); padding: 4px 2px 6px; }
.hm-squote { display: flex; align-items: baseline; gap: 8px; padding: 4px 2px;
  border-top: 1px solid var(--border); font-size: 14px; }
.hm-squote:first-of-type { border-top: none; }
.hm-squote-st { width: 14px; text-align: center; font-weight: 700; }
.hm-squote.won .hm-squote-st { color: var(--green-700); }
.hm-squote.lost .hm-squote-st { color: #B91C1C; }
.hm-squote.open { opacity: .75; }
.hm-squote-who { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hm-squote-amt { margin-left: auto; font-variant-numeric: tabular-nums; font-weight: 650; white-space: nowrap; }
.hm-squote.won .hm-squote-amt { color: var(--green-700); }

/* The Coins Guide — the one place every earn/lose amount is listed, opened
   from the bottom of the Pay tab. Amounts render from live config. */
.cg-open { display: flex; align-items: center; justify-content: center; gap: 6px; width: 100%;
  margin-top: 14px; padding: 12px; border: 1px solid var(--border); border-radius: 12px;
  background: var(--card); font-size: 14.5px; font-weight: 650; color: var(--text); cursor: pointer; }
.cg-open:active { background: var(--card-soft); }
.cg-arrow { color: var(--muted); font-weight: 400; }
.cg-list { border: 1px solid var(--border); border-radius: 12px; overflow: hidden; background: var(--card); }
.cg-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
  padding: 10px 12px; border-top: 1px solid var(--border); font-size: 14px; }
.cg-row:first-child { border-top: none; }
.cg-row > span:first-child { line-height: 1.35; }
.cg-amt { font-variant-numeric: tabular-nums; font-weight: 700; white-space: nowrap; }
.cg-amt.plus { color: var(--green-700); }
.cg-amt.minus { color: #B91C1C; }
.cg-dim { color: var(--muted); }
.cg-dim .cg-amt { font-weight: 500; }
/* Only numbers that actually have an explanation invite a click. */
.alb-drill { cursor: pointer; }
.alb-drill:hover { background: var(--card-soft); text-decoration: underline; }
/* Closed by default. Toggled by class, never the hidden attribute — hidden is a
   UA display:none and loses to any author rule that sets display. */
.alb-why { display: none; }
.alb-why.open { display: table-row; }
.alb-why-box {
  padding: 2px 4px 12px 53px; color: var(--muted); font-size: 13.5px;
  line-height: 1.6; max-width: 90ch;
}

/* The earning ladder on the Coins tab — the crew's view of the grid that pays
   them. Their own level column is highlighted, because "where am I" is the
   first question anyone asks of a table like this. */
.coin-ladder { margin-bottom: 18px; }
.cl-lede { margin: 2px 0 12px; font-size: 15px; line-height: 1.55; }
.cl-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.cl-table { border-collapse: collapse; width: 100%; font-size: 14px; }
.cl-table th, .cl-table td { padding: 7px 9px; text-align: right; white-space: nowrap;
  border-bottom: 1px solid var(--border); font-variant-numeric: tabular-nums; }
.cl-table thead th { font-size: 11.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .4px; }
.cl-table th.cl-tier { text-align: left; font-weight: 700; }
.cl-tier .cl-floor { display: block; font-weight: 500; font-size: 11.5px; color: var(--muted);
  text-transform: none; letter-spacing: 0; }
/* Your column, top to bottom — the one row of numbers that is actually yours. */
.cl-table .cl-me { background: var(--green-soft); font-weight: 800; color: var(--green-700); }
.cl-table thead th.cl-me { color: var(--green-700); }
.cl-floor-note { margin: 10px 0 0; font-size: 13px; color: var(--muted); }
.cl-next { margin: 8px 0 0; font-size: 14.5px; }

/* Upsell rates is nine columns wide; without tightening it forces a horizontal
   scrollbar on a 1400px screen, which hides the column the table is sorted by. */
#ur-grid th, #ur-grid td { padding: 6px 7px; }
#ur-grid th { letter-spacing: .2px; }
#ur-grid td:first-child, #ur-grid th:first-child { padding-left: 2px; }
#ur-grid .alb-name { font-size: 14px; }

/* Your upsells (crew) — two numbers, the denominator stated in words above them
   so the percentage is arguable rather than handed down. */
.up-lede { margin: 0 0 14px; font-size: 15px; line-height: 1.55; }
.up-pair { display: flex; gap: 12px; }
.up-stat { flex: 1; background: var(--card-soft); border-radius: 12px; padding: 14px 16px; }
.up-label { font-size: 12px; font-weight: 700; letter-spacing: .5px; text-transform: uppercase; color: var(--muted); }
.up-num { font-size: 30px; font-weight: 800; line-height: 1.15; margin-top: 4px; }
.up-num.up-good { color: var(--green-700); }
.up-sub { font-size: 13px; color: var(--muted); margin-top: 3px; }
.up-note { margin: 12px 0 0; font-size: 13.5px; color: var(--muted); line-height: 1.55; }

/* Upsell trend + drill-down. The delta is a chip, not a headline: it should be
   noticeable to someone looking, invisible to someone glancing. */
.up-arrow { font-size: 14px; font-weight: 700; margin-left: 6px; vertical-align: 4px; white-space: nowrap; }
.up-up { color: var(--green-700); }
.up-down { color: #B91C1C; }
.up-flat { color: var(--soft); margin-left: 4px; }
.up-win { margin: 12px 0 0; padding: 9px 12px; border-radius: 10px; background: var(--green-soft);
  color: var(--green-700); font-size: 14px; font-weight: 650; }
/* The count is a button but must read as part of the sentence it sits in. */
.up-count { font: inherit; font-weight: 800; color: var(--green-700); background: none;
  border: none; border-bottom: 2px dotted var(--green-700); padding: 0 1px; cursor: pointer; }
.up-count:active { opacity: .6; }
.uv-list { max-height: 60vh; overflow-y: auto; margin-top: 6px; }
.uv-row { display: flex; justify-content: space-between; align-items: center; gap: 10px;
  padding: 9px 2px; border-bottom: 1px solid var(--border); }
.uv-row:last-child { border-bottom: none; }
.uv-l { display: flex; flex-direction: column; font-weight: 600; font-size: 14.5px; }
.uv-sub { font-weight: 400; font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.uv-r { font-size: 12.5px; color: var(--muted); white-space: nowrap; }

/* Admin: the opportunity visits behind a count, three to a row so 55 jobs stay
   scannable instead of becoming a page of their own. */
.ur-vis { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 4px 18px; margin-top: 8px; }
.ur-vis-i { display: flex; justify-content: space-between; gap: 10px; font-size: 13px;
  padding: 3px 0; border-bottom: 1px dotted var(--border); }
.ur-vis-i em { font-style: normal; color: var(--soft); white-space: nowrap; }
/* The quotes behind an Upsell-rates row. */
.ur-row { cursor: pointer; }
.ur-row:hover td { background: var(--card-soft); }
.ur-q { border-collapse: collapse; width: 100%; margin-top: 8px; font-size: 13px; color: var(--text); }
.ur-q th, .ur-q td { padding: 5px 8px; text-align: left; border-bottom: 1px solid var(--border); vertical-align: top; }
.ur-q thead th { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .4px; white-space: nowrap; }
.ur-q td.alb-num, .ur-q th.alb-num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ur-q a { color: inherit; text-decoration: underline dotted; }
.ur-q-row-won td { font-weight: 600; }
.ur-q-won { color: var(--green-700); font-weight: 700; white-space: nowrap; }
.ur-q-open { color: var(--muted); white-space: nowrap; }
.ur-q-lost { color: var(--soft); white-space: nowrap; }

/* The fortnight line: the part that actually moves week to week. Quieter than
   the headline numbers, louder than the footnote. */
.up-14 { margin: 12px 0 0; font-size: 14.5px; }
.up-14 b { font-weight: 800; }
.up-14-sub { color: var(--soft); font-size: 12.5px; margin-left: 4px; white-space: nowrap; }

/* The banked floor on Today. Quiet, and phrased as money already won — it is
   there to reassure, not to compete with the tile being aimed at. */
.td-floor { margin: 10px 0 0; font-size: 13.5px; color: var(--muted); line-height: 1.5; }
.td-floor b { color: var(--green-700); }

/* ONE target: a band, not a stranded grid cell. The rate and the ask sit on
   opposite ends so the eye lands on "$160/hr" and then on what it costs. */
.td-target {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 16px 18px; border-radius: var(--radius-md); background: #A9DCC1;
}
.td-target-label { font-size: 11.5px; font-weight: 800; letter-spacing: .7px;
  text-transform: uppercase; color: var(--green-900); opacity: .72; }
.td-target-rate { font-size: 30px; font-weight: 800; color: var(--green-900); line-height: 1.05; margin-top: 2px; }
.td-target-rate span { font-size: 15px; font-weight: 700; opacity: .7; }
.td-target-r { text-align: right; }
.td-target-hrs { font-size: 14.5px; color: var(--green-900); }
.td-target-hrs b { font-size: 19px; font-weight: 800; }
.td-target-coins { font-size: 13px; font-weight: 700; color: var(--green-900); opacity: .75; margin-top: 3px; }
@media (max-width: 380px) {
  .td-target { flex-direction: column; align-items: flex-start; gap: 8px; }
  .td-target-r { text-align: left; }
}

/* Closeout selfies on the pay card. Shown even at zero — an empty space where
   money could have been is the whole message. Muted when zero so it reads as a
   gap to fill rather than a deduction. */
.mp-selfie .mp-sub { display: block; font-size: 12px; font-weight: 400; color: var(--muted); margin-top: 2px; }
.mp-selfie-zero .mp-val { color: var(--soft); }
.mp-selfie-zero .mp-sub { color: var(--ochre, #B45309); }

/* "Why you're Level N" — the two questions the Coin table provokes. Sits under
   the grid, quieter than it, because it is an answer rather than a headline. */
.cl-why { margin-top: 14px; padding: 14px 16px; border-radius: 12px; background: var(--card-soft); }
.cl-why-head { font-size: 13px; font-weight: 800; letter-spacing: .3px; color: var(--green-900); margin-bottom: 6px; }
.cl-why p { margin: 0 0 7px; font-size: 14px; line-height: 1.55; }
.cl-why p:last-child { margin-bottom: 0; }
.cl-why-more { color: var(--muted); font-size: 13px; }

/* ---------- mood check (post-clock-out, one tap) ---------- */
.mood-q { font-size: 16px; font-weight: 700; text-align: center; }
.mood-row { display: flex; justify-content: center; gap: 18px; margin-top: 14px; }
.mood-btn {
  font-size: 34px; line-height: 1; padding: 10px 16px;
  background: var(--card); border: 1px solid var(--border); border-radius: 14px;
  cursor: pointer; transition: transform .1s;
}
.mood-btn:active { transform: scale(1.15); }
.mood-btn:disabled { opacity: .5; }

/* per-event detail under a score deduction: date · client — "note" */
.sf-ev { font-size: 12.5px; color: var(--muted); padding: 2px 0 0 2px; }

/* crew callback streak: one quiet line between home cards */
.streak-line {
  text-align: center; font-size: 13.5px; color: var(--muted);
  padding: 2px 0 4px; letter-spacing: .01em;
}
.streak-line b { color: var(--green-700); }

/* promise-break tagging */
.pb-reason, .pb-tech { font-size: 12.5px; padding: 4px 6px; border: 1px solid var(--border); border-radius: 8px; background: var(--card); }
.pb-part { white-space: nowrap; }
.pb-retag { font-size: 12px; padding: 4px 10px; }

/* reschedule-rate trend: same bar anatomy, admin-card sized */
.pr-plot { height: 130px; margin: 12px 0 14px; }

/* Admin quote calculator */
.qc-houses { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.qc-house { padding: 10px 14px; border: 1px solid var(--border); border-radius: 12px;
  background: var(--card-soft); color: var(--text); cursor: pointer;
  font-family: inherit; font-size: 14px; }
.qc-house.on { border-color: var(--green-500); box-shadow: 0 0 0 3px rgba(22,163,74,0.12); font-weight: 600; }
.qc-grid { display: flex; flex-direction: row; gap: 12px; flex-wrap: wrap; margin-bottom: 4px; }
.qc-grid label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; }
.qc-grid input, .qc-grid select { width: 140px; }
.qc-results table { width: 100%; border-collapse: collapse; }
.qc-results th, .qc-results td { padding: 8px 10px; text-align: left; border-bottom: 1px solid var(--border); font-size: 14px; }
.qc-results th { font-size: 12px; text-transform: uppercase; letter-spacing: 0.04em; }
.qc-results .qc-best td { background: rgba(22,163,74,0.07); }
.qc-note { font-size: 13px; margin: 8px 0; }

/* Quote tool pipeline */
.qc-reps { display: flex; gap: 6px; margin-bottom: 12px; flex-wrap: wrap; }
.qc-rep { padding: 7px 14px; border: 1px solid var(--border); border-radius: 999px;
  background: var(--card-soft); color: var(--text); cursor: pointer; font-family: inherit; font-size: 13px; }
.qc-rep.on { background: var(--green-500); border-color: var(--green-500); color: #fff; font-weight: 600; }
.qc-list { margin-top: 10px; }
.qc-row { display: flex; justify-content: space-between; align-items: center; gap: 10px;
  padding: 9px 2px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.qc-row-main { font-size: 14px; }
.qc-row-acts { display: flex; gap: 5px; }
.qc-chip { padding: 5px 10px; border: 1px solid var(--border); border-radius: 999px;
  background: var(--card); color: var(--text); cursor: pointer; font-family: inherit; font-size: 12px; }
.qc-chip.on { color: #fff; font-weight: 600; }
.qc-chip.on.qc-quoted { background: #64748B; border-color: #64748B; }
.qc-chip.on.qc-closed { background: var(--green-500); border-color: var(--green-500); }
.qc-chip.on.qc-paid { background: var(--green-700); border-color: var(--green-700); }
.qc-chip.on.qc-lost { background: #B91C1C; border-color: #B91C1C; }

/* ---- Calendar Rewind (admin) ---------------------------------------------
   A time grid, not a list: the whole point of the page is *when*, so the hour
   axis is the first thing the eye lands on. Blocks are positioned by
   start/end; overlapping visits share the column side by side. */
body.wide .container { max-width: 1600px; }
.cal-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; margin-bottom: 10px; }
.cal-weeknav, .cal-asof { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.cal-week-label { font-weight: 700; font-size: 15px; min-width: 150px; text-align: center; font-variant-numeric: tabular-nums; }
.cal-lbl { font-size: 12px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.cal-btn { padding: 6px 11px; border: 1px solid var(--border); border-radius: 10px; background: var(--card-soft); color: var(--text); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.cal-btn:hover { background: var(--green-soft); }
.cal-btn.on { background: var(--green-900); color: #fff; border-color: transparent; }
.cal-input { padding: 6px 9px; border: 1px solid var(--border); border-radius: 10px; font: inherit; font-size: 13px; background: var(--card-soft); color: var(--text); }
.cal-toggle { display: flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 600; cursor: pointer; }
.cal-tiles { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin: 10px 0 14px; }
.cal-tile { background: var(--card-soft); border: 1px solid var(--border); border-radius: 14px; padding: 10px 14px; }
.cal-tile .k { font-size: 11px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.cal-tile .v { font-size: 24px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.cal-tile.moved .v { color: #B45309; } .cal-tile.removed .v { color: #B91C1C; } .cal-tile.added .v { color: var(--green-600); }
.cal-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.cal-legend span { display: inline-flex; align-items: center; gap: 5px; }
.cal-legend i { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.cal-scroll { overflow-x: auto; border: 1px solid var(--border); border-radius: 14px; background: var(--card); }
.cal-grid { display: grid; min-width: 880px; }
.cal-gutter-h, .cal-day-h { position: sticky; top: 0; background: var(--card); border-bottom: 1px solid var(--border); padding: 8px 8px 6px; z-index: 2; }
.cal-day-h { display: flex; align-items: baseline; gap: 6px; }
.cal-day-h .dn { font-size: 11px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.cal-day-h .dd { font-size: 18px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.cal-day-h .cnt { margin-left: auto; font-size: 11px; color: var(--soft); font-variant-numeric: tabular-nums; }
.cal-day-h.today .dd { color: var(--green-600); }
.cal-gutter { position: relative; border-right: 1px solid var(--border); }
.cal-gutter span { position: absolute; right: 6px; transform: translateY(-50%); font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.cal-day { position: relative; border-right: 1px solid var(--border);
  background-image: repeating-linear-gradient(to bottom, var(--border) 0 1px, transparent 1px var(--calpx)),
                    repeating-linear-gradient(to bottom, transparent 0 calc(var(--calpx) / 2), rgba(15,23,42,.035) calc(var(--calpx) / 2) calc(var(--calpx) / 2 + 1px), transparent calc(var(--calpx) / 2 + 1px) var(--calpx)); }
.cal-day:last-child, .cal-day-h:last-child { border-right: none; }
.cal-day.today { background-color: rgba(22,163,74,.035); }
.cal-nowline { position: absolute; left: 0; right: 0; height: 2px; background: var(--green-500); z-index: 1; pointer-events: none; }
.cal-nowline::before { content: ""; position: absolute; left: -4px; top: -3px; width: 8px; height: 8px; border-radius: 50%; background: var(--green-500); }
.cv { position: absolute; box-sizing: border-box; border-radius: 8px; padding: 4px 6px 4px 9px; background: #fff; border: 1px solid var(--border); box-shadow: 0 1px 2px rgba(15,23,42,.06); font-size: 11.5px; line-height: 1.3; overflow: hidden; cursor: default; }
.cv::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--crew); }
/* assessments: striped edge + tinted body so they read apart from job visits */
.cv.cv-assess::before, .cvs.cv-assess::before { background: repeating-linear-gradient(180deg, var(--crew) 0 6px, #fff 6px 9px); }
.cv.cv-assess { background: #FAFAF7; border-style: dashed; }
.cal-tile.assess .v { color: #4F46E5; }
.cv .cv-t { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cv .cv-n { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cv .cv-c { color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cv .cv-chg { margin-top: 2px; font-weight: 600; font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cv.short .cv-c, .cv.short .cv-chg { display: none; }
.cv.cv-moved { background: #FEF3C7; border-color: #F59E0B; } .cv.cv-moved .cv-chg { color: #B45309; }
.cv.cv-crew { border-color: #F59E0B; } .cv.cv-crew .cv-chg { color: #B45309; }
.cv.cv-removed { background: #FEE2E2; border-color: #EF4444; }
.cv.cv-removed .cv-t, .cv.cv-removed .cv-n, .cv.cv-removed .cv-c { text-decoration: line-through; opacity: .75; }
.cv.cv-removed .cv-chg { color: #B91C1C; }
.cv.cv-ghost { background: transparent; border: 1px dashed rgba(15,23,42,.35); box-shadow: none; }
.cv.cv-ghost::before { background: rgba(15,23,42,.3); } .cv.cv-ghost .cv-chg { color: var(--green-600); }
.cv.cv-landed { background: transparent; border: 2px dashed #F59E0B; box-shadow: none; } .cv.cv-landed .cv-chg { color: #B45309; }
.cal-h3 { font-size: 15px; font-weight: 700; margin: 18px 0 6px; }
.cal-log { display: flex; flex-direction: column; }
.cal-log .row { display: grid; grid-template-columns: 8px 1fr; gap: 10px; padding: 8px 0; border-top: 1px solid var(--border); font-size: 13px; }
.cal-log .row:first-child { border-top: none; }
.cal-log .mark { width: 8px; height: 8px; border-radius: 50%; margin-top: 6px; background: var(--soft); }
.cal-log .mark.moved, .cal-log .mark.crew { background: #F59E0B; } .cal-log .mark.removed { background: #EF4444; } .cal-log .mark.added { background: var(--green-500); }
.cal-log .when { font-size: 11px; color: var(--soft); font-variant-numeric: tabular-nums; }
.cal-log .what { font-weight: 600; }
.cal-log .detail { color: var(--muted); font-variant-numeric: tabular-nums; }
.cal-how { font-size: 12px; margin-top: 14px; }
@media (max-width: 720px) { .cal-tiles { grid-template-columns: repeat(2, 1fr); } .cal-toggle { margin-left: 0; } }
.cal-strip-g, .cal-strip { border-bottom: 2px solid var(--border); padding: 4px 4px 4px; background: var(--card-soft); }
.cal-strip-g { font-size: 10px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); text-align: right; padding-right: 6px; padding-top: 8px; border-right: 1px solid var(--border); }
.cal-strip { border-right: 1px solid var(--border); display: flex; flex-direction: column; gap: 3px; }
.cal-strip:last-child { border-right: none; }
.cal-strip.today { background: rgba(22,163,74,.05); }
.cvs { position: relative; border-radius: 7px; padding: 3px 6px 3px 9px; background: #fff; border: 1px solid var(--border); font-size: 11px; line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cvs::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--crew); }
.cvs b { font-variant-numeric: tabular-nums; }
.cvs .cvs-n { font-weight: 600; }
.cvs .cvs-c { color: var(--muted); margin-left: 5px; }
.cvs .cvs-chg { font-weight: 600; margin-left: 5px; }
.cvs.cv-moved { background: #FEF3C7; border-color: #F59E0B; } .cvs.cv-moved .cvs-chg, .cvs.cv-crew .cvs-chg { color: #B45309; }
.cvs.cv-crew { border-color: #F59E0B; }
.cvs.cv-removed { background: #FEE2E2; border-color: #EF4444; } .cvs.cv-removed b, .cvs.cv-removed .cvs-n { text-decoration: line-through; opacity: .75; } .cvs.cv-removed .cvs-chg { color: #B91C1C; }
.cvs.cv-ghost { background: transparent; border-style: dashed; } .cvs.cv-ghost .cvs-chg { color: var(--green-600); }
.cvs.cv-landed { background: transparent; border: 2px dashed #F59E0B; } .cvs.cv-landed .cvs-chg { color: #B45309; }
.cal-toggle input { width: auto; margin: 0; }
.cv, .cvs { cursor: pointer; }
.cv.sel, .cvs.sel { outline: 2px solid var(--green-600); outline-offset: 1px; }
.cal-detail { margin-top: 10px; padding: 10px 14px; border: 1px solid var(--border); border-radius: 12px; background: var(--card-soft); font-size: 13px; display: flex; flex-direction: column; gap: 3px; }
.cal-detail-name { font-weight: 700; font-size: 15px; display: flex; align-items: center; gap: 8px; }
.cal-detail-name i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }
.cal-detail-chg { font-weight: 600; } .cal-detail-chg.cv-moved, .cal-detail-chg.cv-crew, .cal-detail-chg.cv-landed { color: #B45309; } .cal-detail-chg.cv-removed { color: #B91C1C; } .cal-detail-chg.cv-ghost { color: var(--green-600); }
.cal-detail-title { font-size: 12px; }

/* Crew habits card: two rates with a this-week trend beside each. */
.hb-row { display: flex; align-items: baseline; gap: 10px; margin-top: 14px; }
.hb-row:first-child { margin-top: 2px; }
.hb-label { font-weight: 650; font-size: 15px; }
.hb-week { font-size: 12.5px; color: var(--muted); }
.hb-up { color: var(--green-700); font-weight: 650; }
.hb-down { color: #B4472C; font-weight: 650; }
.hb-pct { margin-left: auto; font-variant-numeric: tabular-nums; font-weight: 750; font-size: 17px; }
.hb-good { color: var(--green-700); }
.hb-low { color: #B4472C; }
.hb-track { height: 8px; border-radius: 999px; background: var(--border); overflow: hidden; margin-top: 6px; }
.hb-fill { height: 100%; border-radius: 999px; background: var(--green-600, #16A34A); }
.hb-fill-good { background: var(--green-700, #15803D); }
.hb-note { font-size: 13px; color: var(--muted); margin: 12px 0 0; }

/* Yesterday's-misses banner: amber, not red — a reminder, not an alarm. */
.habit-banner {
  display: block; width: 100%; text-align: left; cursor: pointer;
  background: linear-gradient(135deg, #B45309 0%, #D97706 100%); color: #fff;
  border: none; font-family: inherit; font-size: 14.5px; font-weight: 500;
  line-height: 1.45; border-radius: 14px; padding: 13px 16px; margin-bottom: 14px;
  box-shadow: 0 6px 16px rgba(180, 83, 9, 0.26);
}
.habit-banner b { font-weight: 750; }

/* Perfect-yesterday flash: green, then gone — praise shouldn't linger. */
.praise-banner {
  display: block; width: 100%; text-align: left;
  background: linear-gradient(135deg, #15803D 0%, #16A34A 100%); color: #fff;
  font-size: 14.5px; font-weight: 500; line-height: 1.45;
  border-radius: 14px; padding: 13px 16px; margin-bottom: 14px;
  box-shadow: 0 6px 16px rgba(21, 128, 61, 0.26);
  transition: opacity 1.1s ease, transform 1.1s ease;
}
.praise-banner b { font-weight: 750; }
.praise-out { opacity: 0; transform: translateY(-6px); }
@media (prefers-reduced-motion: reduce) { .praise-banner { transition: none; } }
/* Office/pay-only people on the Log form: addressable, visibly not crew. */
.chip.chip-office { border-style: dashed; opacity: .85; }
.chip.chip-office.on { border-style: solid; opacity: 1; }

/* View-as bar (admins only) */
.viewas { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 0 14px; padding: 10px 14px;
  border-radius: var(--radius-md); background: #FBF2DC; color: #6B4A05; font-size: 14px; font-weight: 600; }
.viewas select { font: inherit; padding: 4px 8px; border-radius: 8px; border: 1px solid #E5D3A6; background: #fff; }
.viewas-note { font-weight: 500; opacity: .8; }
.viewas .btn-ghost { margin-left: auto; }
body.view-as .tc-btn-out, body.view-as .tc-btn-in, body.view-as .btn-primary { opacity: .6; }
/* Upsell rates: group labels over the column headers */
.alb-group th { font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted);
  text-align: center; border-bottom: none; padding-bottom: 0; border-left: 1px solid var(--border); }
.alb-group th:first-child { border-left: none; }
.alb-group th.alb-group-hi { color: var(--green-700); font-weight: 800; }
.crew-table td.alb-dim2 { color: var(--muted); }

/* ---- weekly teammate check-in (openPeerReview) ---- */
.pr-list { display: flex; flex-direction: column; gap: 14px; margin-bottom: 16px; }
.pr-person { border: 1px solid var(--border); border-radius: 16px; padding: 12px; background: var(--card-soft); }
.pr-who { display: flex; align-items: center; gap: 10px; font-size: 16px; margin-bottom: 10px; }
.pr-opt {
  display: block; width: 100%; text-align: left; font: inherit; font-size: 15px; font-weight: 600;
  padding: 12px 14px; margin-top: 8px; border-radius: 12px; cursor: pointer;
  border: 2px solid var(--border); background: #fff; color: inherit;
}
.pr-opt.on.pr-yes { border-color: var(--green-700); background: var(--green-soft); color: var(--green-700); }
.pr-opt.on.pr-no  { border-color: #B4472C; background: #FBEDE8; color: #8C3520; }
.pr-later { display: block; width: 100%; margin-top: 10px; }
.pr-note { font-size: 13px; color: var(--muted); text-align: center; margin: 10px 0 0; }
.pr-err { color: #B4472C; font-weight: 600; font-size: 14px; min-height: 18px; margin-bottom: 6px; }
.pr-why textarea { resize: vertical; }

/* ---- admin: teammate check-in report ---- */
.pr-tech { border-bottom: 1px solid var(--border); padding: 10px 2px; }
.pr-tech:last-child { border-bottom: none; }
.pr-tech summary { display: flex; align-items: center; gap: 10px; cursor: pointer; list-style: none; flex-wrap: wrap; }
.pr-tech summary::-webkit-details-marker { display: none; }
.pr-tally { margin-left: auto; font-size: 14px; color: var(--muted); font-weight: 600; }
.pr-ans { margin: 10px 0 0 42px; padding: 10px 12px; border-radius: 12px; font-size: 14px; border-left: 4px solid var(--border); background: var(--card-soft); }
.pr-ans-yes { border-left-color: var(--green-700); }
.pr-ans-no  { border-left-color: #B4472C; }
.pr-ans-why { margin-top: 4px; }

/* ---- clock-out check ("Before you go") ---- */
.co-block { border: 1px solid var(--border); border-radius: 16px; padding: 14px; background: var(--card-soft); margin-bottom: 12px; }
.co-head { font-weight: 800; font-size: 16px; }
.co-list { margin: 8px 0 6px; padding-left: 20px; font-size: 16px; }
.co-list li { margin: 4px 0; }
.co-job { color: var(--muted); font-size: 13px; font-weight: 600; }
.co-how { font-size: 14px; color: var(--muted); }

/* "Since August 1, 2025" under the welcome name */
.welcome-since { margin: 2px 0 0; font-size: 12.5px; color: var(--muted); opacity: .8; letter-spacing: .01em; }

/* admin: revenue to go */
.rtg-tiles { cursor: pointer; }
.rtg-detail { margin-top: 14px; }
.rtg-hint { margin: 10px 0 0; font-size: 13px; }
.rtg-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 560px) { .rtg-tiles { grid-template-columns: 1fr; } }
.rtg-yoy { margin-top: 12px; }
.rbk-kinds { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 12px; }
.rbk-sum { margin: 6px 0 0; font-size: 13px; }
.rtg-ly-fill { background: var(--muted); opacity: .55; }

/* ---- capacity planner (admin Home) ---- */
.cap-rows { display: flex; flex-direction: column; gap: 4px; margin-top: 14px; }
.cap-row { padding: 10px 8px; border-radius: 10px; cursor: pointer; }
.cap-row:hover, .cap-row:focus-visible { background: rgba(127, 127, 127, .08); outline: none; }
.cap-top { display: flex; align-items: baseline; gap: 8px; }
.cap-right { margin-left: auto; white-space: nowrap; font-variant-numeric: tabular-nums; }
.cap-tag { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: 2px 8px; border-radius: 999px; background: rgba(127, 127, 127, .15); }
.cap-bar { position: relative; display: flex; height: 12px; margin: 7px 0 5px; border-radius: 999px; background: rgba(127, 127, 127, .16); overflow: hidden; }
.cap-done { height: 100%; background: #15803D; }
.cap-booked { height: 100%; background: #4ADE80; opacity: .75; }
.cap-mid .cap-booked { background: #FCD34D; opacity: .9; }
.cap-mid .cap-done { background: #B45309; }
.cap-open .cap-booked { background: #93C5FD; opacity: .9; }
.cap-open .cap-done { background: #1D4ED8; }
.cap-over .cap-tag, .cap-full .cap-tag { background: rgba(21, 128, 61, .18); }
.cap-line { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -2px; background: currentColor; opacity: .55; }
.cap-target { width: 0; background: none; border-left: 2px dotted currentColor; opacity: .8; }
.cap-sub { font-size: 13px; }
.cap-detail { padding: 4px 8px 14px; display: flex; flex-direction: column; gap: 12px; }
.cap-note { margin: 12px 0 0; font-size: 13px; }

.cap-cell { display: inline-block; min-width: 46px; padding: 3px 8px; border: 0; border-radius: 999px; font: inherit; font-size: 13px; font-variant-numeric: tabular-nums; text-align: center; color: inherit; background: rgba(147, 197, 253, .35); }
button.cap-cell { cursor: pointer; }
button.cap-cell:hover, button.cap-cell:focus-visible { outline: 2px solid currentColor; outline-offset: 1px; }
.cap-cell.cap-mid { background: rgba(252, 211, 77, .5); }
.cap-cell.cap-full, .cap-cell.cap-over { background: rgba(74, 222, 128, .5); }
.cap-grid td, .cap-grid th { white-space: nowrap; }
.cap-h3 { margin: 16px 0 4px; font-size: 16px; }
.cap-crew-head { margin-top: 16px; padding: 12px 8px 4px; border-top: 1px solid rgba(127, 127, 127, .25); cursor: pointer; display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; }
.cap-crew-head .muted { font-size: 13px; }

.cap-verdict { margin: 14px 0 6px; }
.cap-read { white-space: nowrap; }
#cap-crew-detail .crew-table th, #cap-crew-detail .crew-table td { padding-left: 8px; padding-right: 8px; }

/* ---- booking funnel: where people really leave ---- */
.bf-h3 { margin: 18px 0 6px; font-size: 16px; }
.bf-leaks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.bf-leak { display: block; width: 100%; text-align: left; font: inherit; color: inherit; background: none; border: 0; border-radius: 10px; padding: 9px 10px; cursor: pointer; line-height: 1.45; }
.bf-leak:hover, .bf-leak:focus-visible { background: rgba(127, 127, 127, .08); outline: none; }
.bf-leak.on { background: rgba(127, 127, 127, .12); }
.bf-drill { margin: 6px 0 10px; }
.bf-plans { margin-top: 12px; }
.bf-fine { font-size: 13px; margin: 8px 0 0; }

/* ---- break editor on the shift form ---- */
#shift-breaks { margin: 8px 0 14px; padding: 10px 12px; border: 1px solid rgba(127, 127, 127, .25); border-radius: 12px; }
.brk-head { margin-bottom: 6px; }
.brk-row { display: flex; flex-wrap: wrap; align-items: end; gap: 8px 12px; padding: 6px 0; }
.brk-row label { display: flex; flex-direction: column; font-size: 12px; gap: 2px; }
.brk-row label.brk-paid { flex-direction: row; align-items: center; gap: 6px; font-size: 14px; padding-bottom: 8px; }
.brk-row .muted { font-size: 13px; padding-bottom: 8px; }
.brk-new { border-top: 1px dashed rgba(127, 127, 127, .3); margin-top: 4px; padding-top: 10px; }

/* ---- Home: your production ---- */
.pd-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; align-items: end; }
.pd-day { display: flex; flex-direction: column; align-items: center; gap: 3px; background: none; border: 0; padding: 4px 0; font: inherit; color: inherit; cursor: pointer; border-radius: 8px; }
.pd-day:disabled { cursor: default; opacity: .55; }
.pd-day:not(:disabled):hover, .pd-day:focus-visible { background: rgba(127, 127, 127, .1); outline: none; }
.pd-val { font-size: 11px; font-variant-numeric: tabular-nums; min-height: 14px; }
.pd-bar { display: block; width: 100%; height: 64px; border-radius: 6px; background: rgba(127, 127, 127, .14); position: relative; overflow: hidden; }
.pd-fill { position: absolute; left: 0; right: 0; bottom: 0; border-radius: 6px 6px 0 0; background: #9CA3AF; }
.pd-t1 .pd-fill { background: #FCD34D; } .pd-t2 .pd-fill { background: #4ADE80; } .pd-t3 .pd-fill { background: #15803D; }
.pd-lbl { font-size: 11px; color: var(--muted, #6B7280); }
.pd-coins { font-size: 11px; font-variant-numeric: tabular-nums; }
.pd-week { margin: 8px 0 4px; font-size: 13px; }
.pd-detail { margin: 8px 0 12px; padding: 10px 12px; border-radius: 10px; background: rgba(127, 127, 127, .08); }
.pd-detail-head { margin-bottom: 4px; } .pd-why { font-size: 13px; margin-bottom: 6px; }
.pd-trend-head { margin-top: 14px; } .pd-trend-head .muted { font-size: 12px; }
.pd-trend-box { position: relative; height: 120px; margin: 6px 0 18px; }
.pd-trend { position: absolute; inset: 0; width: 100%; height: 100%; display: block; overflow: visible; }
.pd-trendline { fill: none; stroke: #15803D; stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.pd-dot { position: absolute; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; background: #15803D; box-shadow: 0 0 0 3px rgba(21, 128, 61, .2); }
.pd-floor { position: absolute; left: 0; right: 0; border-top: 1px dashed rgba(127, 127, 127, .45); }
.pd-floor-lbl { position: absolute; left: 0; top: -14px; font-size: 10px; color: var(--muted, #6B7280); }
.pd-axis { position: absolute; top: 100%; font-size: 10px; color: var(--muted, #6B7280); margin-top: 2px; }
.pd-axis-l { left: 0; } .pd-axis-r { right: 0; }
.pd-date { font-size: 10px; color: var(--muted, #6B7280); margin-top: -2px; }
.pd-legend { font-size: 11px; } .pd-sw { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin: 0 3px 0 6px; vertical-align: -1px; background: #9CA3AF; }
.pd-sw.pd-t1 { background: #FCD34D; } .pd-sw.pd-t2 { background: #4ADE80; } .pd-sw.pd-t3 { background: #15803D; }
.pd-t0 .pd-fill { background: #9CA3AF; }
.pd-trend-foot { font-size: 13px; margin-top: 2px; }
.pd-up { color: #15803D; } .pd-down { color: #B4472C; }
.pd-earn-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 16px; }
.pd-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 8px; }
.pd-tile { padding: 10px; border-radius: 10px; background: rgba(127, 127, 127, .08); }
.pd-big { font-size: 20px; font-weight: 700; font-variant-numeric: tabular-nums; }
.pd-sub { font-size: 11px; color: var(--muted, #6B7280); }
.pd-src { margin-top: 10px; } .pd-src summary { cursor: pointer; font-size: 13px; }
.pd-table { width: 100%; border-collapse: collapse; margin: 8px 0; font-size: 14px; }
.pd-table td { padding: 4px 0; border-bottom: 1px solid rgba(127, 127, 127, .15); }
.pd-total td { font-weight: 700; border-bottom: 0; }
.pd-num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pd-list { display: flex; flex-direction: column; gap: 2px; font-size: 13px; max-height: 320px; overflow: auto; }
.pd-row { display: flex; justify-content: space-between; gap: 10px; padding: 3px 0; }
@media (max-width: 400px) { .pd-tiles { grid-template-columns: 1fr 1fr; } .pd-val { font-size: 10px; } }

/* ---- Sales: follow up ---- */
.fu-h3 { margin: 10px 0 6px; font-size: 15px; }
.fu-quiet { margin: 0 0 8px; }
.fu-listhead { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-top: 12px; }
.fu-toggle { font-size: 12px; color: var(--muted, #6B7280); display: flex; align-items: center; gap: 5px; }
.fu-item { padding: 10px 0; border-top: 1px solid rgba(127, 127, 127, .18); }
.fu-due { background: rgba(252, 211, 77, .14); border-radius: 10px; padding: 10px 12px; border-top: 0; margin-bottom: 6px; }
.fu-line { font-size: 14px; line-height: 1.4; }
.fu-items { font-size: 12.5px; }
.fu-tel { margin-right: 10px; white-space: nowrap; }
.fu-note { margin: 4px 0; font-size: 14px; padding: 6px 10px; border-radius: 8px; background: rgba(127, 127, 127, .1); }
.fu-set { margin-top: 2px; }
.fu-clear { background: none; border: 0; color: inherit; text-decoration: underline; font: inherit; font-size: 12px; cursor: pointer; opacity: .7; }
.fu-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 6px; }
.fu-actions .btn-ghost, .fu-actions .btn-primary { padding: 5px 10px; font-size: 13px; }
.fu-lbl { font-size: 12px; }
.fu-datebox { display: inline-flex; align-items: center; gap: 6px; }
.fu-datebox .fu-dateset { padding: 5px 12px; font-size: 13px; }
.fu-date { font: inherit; font-size: 13px; padding: 4px 6px; border-radius: 8px; border: 1px solid rgba(127, 127, 127, .35); background: transparent; color: inherit; max-width: 140px; }
.fu-noteform { display: flex; gap: 6px; margin-top: 6px; }
.fu-noteinput { flex: 1; font: inherit; font-size: 14px; padding: 7px 10px; border-radius: 8px; border: 1px solid rgba(127, 127, 127, .35); background: transparent; color: inherit; min-width: 0; }
.fu-soon summary { cursor: pointer; font-size: 14px; margin: 6px 0; }
.fu-fine { font-size: 12px; margin-top: 10px; }
.fu-alert { border: 0; cursor: pointer; font: inherit; }

.fu-addbox { margin-top: 14px; } .fu-addbox summary { cursor: pointer; font-size: 14px; font-weight: 600; margin-bottom: 8px; }
.fu-search { width: 100%; box-sizing: border-box; margin-bottom: 6px; }
.fu-picklist { display: flex; flex-direction: column; gap: 2px; max-height: 360px; overflow: auto; }
.fu-pick { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 6px 0; border-top: 1px solid rgba(127, 127, 127, .14); font-size: 13.5px; }
.fu-pick .btn-ghost { padding: 4px 10px; font-size: 13px; white-space: nowrap; }

.hb-gaps { margin: 10px 0 4px; padding: 8px 10px; border-radius: 10px; background: rgba(252, 211, 77, .14); }
.hb-gaps-head { font-weight: 700; font-size: 14px; margin-bottom: 4px; }
.hb-gaplist { margin: 0; padding-left: 18px; font-size: 13.5px; line-height: 1.5; }
.hb-gaplist a { margin-left: 4px; white-space: nowrap; }
.hb-how { font-size: 12.5px; margin-top: 4px; }

/* ---- Monday meeting (admin, owner-only) ----------------------------------
   An agenda to talk from, standing up, off a phone: big tap targets, the
   covered items fade back, the numbers open in place. */
#mt-week-label { min-width: 90px; }
#mt-next:disabled { opacity: .35; cursor: default; }
.mt-add textarea { width: 100%; border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px;
  font: inherit; font-size: 15px; resize: vertical; margin-top: 10px; }
.mt-add .chips { margin: 8px 0 10px; }
.mt-add .chips .chip { padding: 6px 11px; font-size: 13px; }
.mt-sec .card-head { margin-bottom: 8px; }
.mt-head-right { display: inline-flex; align-items: center; gap: 8px; }
.mt-all { border: 1px solid var(--green-600); color: var(--green-600); background: #fff; border-radius: 999px;
  padding: 3px 10px; font: inherit; font-size: 12px; font-weight: 600; cursor: pointer; line-height: 1.4; }
.mt-all:hover { background: var(--green-600); color: #fff; }
.mt-item { display: flex; align-items: flex-start; gap: 10px; padding: 10px 0; border-top: 1px solid var(--border); }
.mt-item:first-of-type { border-top: none; }
.mt-check { flex: 0 0 26px; height: 26px; border-radius: 8px; border: 2px solid var(--border); background: #fff;
  color: #fff; font-weight: 800; font-size: 14px; line-height: 1; cursor: pointer; margin-top: 1px; }
.mt-item.done .mt-check { background: var(--green-600); border-color: var(--green-600); }
.mt-text { flex: 1; font-size: 15.5px; line-height: 1.45; overflow-wrap: anywhere; }
.mt-mine { cursor: text; }
.mt-text.editing > .mt-body-txt { display: none; }
.mt-addline { display: block; background: none; border: none; font: inherit; font-size: 14.5px; font-weight: 600; color: var(--green-700);
  padding: 10px 0 2px 2px; cursor: pointer; text-align: left; border-top: 1px solid var(--border); width: 100%; margin-top: 2px; }
.mt-addline:hover { color: var(--green-800, #065F46); }
.mt-newbox { margin: 10px 0 2px 0; width: 100%; }
.mt-edit { display: block; width: 100%; box-sizing: border-box; font: inherit; line-height: 1.45; resize: none; overflow: hidden;
  border: 1.5px solid var(--green-700); border-radius: 10px; padding: 6px 10px; margin: -7px 0 2px -11px; width: calc(100% + 11px);
  background: #fff; color: inherit; outline: none; }
.mt-item.done .mt-text { color: var(--muted); text-decoration: line-through; text-decoration-color: var(--border); }
.mt-src { display: inline-block; margin-left: 4px; padding: 1px 7px; border-radius: 999px; background: var(--green-soft);
  color: var(--green-700); font-size: 11px; font-weight: 700; white-space: nowrap; vertical-align: 1px; text-decoration: none; }
.mt-carried { background: #FBF2DC; color: #96690A; }
.mt-x { border: none; background: none; color: var(--soft); font-size: 20px; line-height: 1; cursor: pointer; padding: 2px 6px; }
.mt-x:hover { color: #B91C1C; }
.mt-grid { margin: 14px 0 8px; }   /* the 'week so far' line sat flush on the tiles (Darren, 2026-10-09) */
/* minmax(0, 1fr), not 1fr: a 1fr track can't shrink below its content, so a
   long no-wrap pill pushed the 4th column out past the card (Darren, 2026-10-26). */
@media (min-width: 720px) { .mt-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.mt-tile { min-width: 0; }
.mt-tile:hover { background: var(--card-soft); }
.mt-sub { font-size: 12px; color: var(--muted); margin-top: 3px; }
.mt-good { color: var(--green-700); }
.mt-low { color: #B45309; }
.mt-fine { font-size: 12.5px; margin: 6px 0 0; }
.mt-sec .card-head + .mt-fine { margin: -2px 0 12px; }
.mt-scroll { overflow-x: auto; margin-top: 12px; }
.mt-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.mt-table th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 600; padding: 6px 8px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.mt-table td { padding: 8px; border-bottom: 1px solid var(--border); white-space: nowrap; font-weight: 600; }
.mt-table .mt-num { text-align: right; font-variant-numeric: tabular-nums; }
.mt-table .mt-dim { color: var(--soft); font-weight: 400; }
.mt-why { cursor: pointer; }
.mt-goal { display: block; font-size: 11px; font-weight: 500; color: var(--muted); }
.mt-whytext { font-size: 14px; line-height: 1.5; padding: 4px 2px 8px; }
.mt-fab { position: fixed; right: 16px; bottom: 18px; z-index: 150; border: none; border-radius: 999px;
  padding: 12px 18px; background: var(--green-900); color: #fff; font: inherit; font-size: 14px; font-weight: 700;
  box-shadow: 0 6px 18px rgba(15,23,42,.25); cursor: pointer; }
.mt-pop { position: fixed; right: 16px; bottom: 74px; z-index: 151; width: min(360px, calc(100vw - 32px));
  background: var(--card); border: 1px solid var(--border); border-radius: 16px; padding: 14px;
  box-shadow: 0 12px 32px rgba(15,23,42,.22); }
.mt-pop-head { display: flex; justify-content: space-between; align-items: center; }
/* Monday meeting photos */
.mt-addrow { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.mt-addrow .btn-primary { width: auto; }
.mt-photo-btn { border: 1px solid var(--border); border-radius: 999px; padding: 8px 14px; font-size: 14px; font-weight: 600; cursor: pointer; background: #fff; }
.mt-photo-btn:hover { border-color: var(--green-700); }
.mt-filecount { font-size: 13px; }
.mt-imgs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.mt-img { width: 96px; height: 96px; object-fit: cover; border-radius: 10px; border: 1px solid var(--border); cursor: pointer; }
.mt-item.done .mt-img { opacity: .55; }
.mt-cam { border: 1px solid var(--border); background: #fff; border-radius: 999px; font: inherit; font-size: 12px; font-weight: 600; color: var(--muted); cursor: pointer; padding: 3px 9px; white-space: nowrap; }
.mt-text a { color: var(--green-700); overflow-wrap: anywhere; }
.mt-cam:hover { border-color: var(--green-700); color: var(--green-700); }
.mt-imgwrap { position: relative; display: inline-block; line-height: 0; }
.mt-imgx { position: absolute; top: -6px; right: -6px; width: 20px; height: 20px; border-radius: 50%; border: 1px solid var(--border);
  background: #fff; color: var(--muted); font-size: 13px; line-height: 1; cursor: pointer; padding: 0; }
.mt-imgx:hover { color: #B91C1C; }
.mt-uprow { cursor: pointer; } .mt-uprow:hover td { background: var(--card-soft); }
/* Penalty reviews ("ask admin to review") */
.hb-ask { font-size: 12.5px; margin: 0 0 0 4px; }
.hb-rev { display: block; font-size: 12.5px; color: var(--muted); }
.hb-rev-ok { color: var(--green-700); font-weight: 600; }
.hb-rev-no { color: #B45309; }
.pr-reason { width: 100%; border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px; font: inherit; font-size: 15px; margin: 12px 0 4px; }
.prv-row { display: flex; gap: 12px; align-items: flex-start; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 14px; flex-wrap: wrap; }
.prv-why { margin-top: 4px; font-size: 14.5px; }
.prv-acts { display: flex; gap: 8px; }
.prv-acts .btn-primary { width: auto; padding: 8px 16px; }
.prv-past { margin-top: 10px; }
.hb-waive { padding: 3px 10px; font-size: 12px; }
.pr-excuse-row { font-size: 13px; margin: 6px 0 10px; } .pr-excuse-row .btn-ghost { padding: 3px 10px; font-size: 12px; margin-left: 4px; }
.pr-crew { margin: 6px 0 12px; align-items: center; } .pr-crew .chip { padding: 5px 11px; font-size: 13px; }

/* ---------- Mission (admin, owner-only): Darren's personal planner ---------- */
.ms-nav { margin: 0 0 14px; }
.ms-sec .card-head { margin-bottom: 10px; align-items: flex-start; gap: 10px; }
.ms-sec .card-head h2 { line-height: 1.3; }
.ms-count { display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 999px; background: var(--green-soft); color: var(--green-700); font-size: 12px; font-weight: 700; vertical-align: 2px; }
.ms-streak { font-size: 15px; margin: -2px 0 12px; }
.ms-rit { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; background: var(--card-soft); border: 1px solid var(--border); margin-bottom: 8px; }
.ms-rit.on { background: var(--green-soft); border-color: rgba(22, 163, 74, .25); }
.ms-rit-foot { margin-top: 16px; margin-bottom: 0; }
.ms-rit-text { flex: 1; min-width: 0; }
.ms-daybar { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 4px 2px 10px; }
.ms-daybar .ms-streak { margin: 0; }
.ms-check { flex: 0 0 26px; width: 26px; height: 26px; border-radius: 8px; border: 2px solid var(--border); background: #fff; color: #fff; font-weight: 800; font-size: 15px; line-height: 1; cursor: pointer; padding: 0; }
.ms-check.ms-big { flex-basis: 32px; width: 32px; height: 32px; border-radius: 10px; font-size: 18px; }
.ms-item.done .ms-check, .ms-rit.on .ms-check, .ms-goal.done .ms-check { background: var(--green-600); border-color: var(--green-600); }
.ms-item { display: flex; align-items: flex-start; gap: 10px; padding: 10px 0; border-top: 1px solid var(--border); }
.ms-item:first-of-type, .ms-fold + .ms-item { border-top: none; }
.ms-item.ms-editing { flex-direction: column; gap: 8px; }
.ms-item.ms-editing .ms-in, .ms-item.ms-editing .ms-ta { width: 100%; }
.ms-text { flex: 1; min-width: 0; cursor: text; }
.ms-title { font-size: 15.5px; font-weight: 600; line-height: 1.4; overflow-wrap: anywhere; }
.ms-item.done .ms-title { color: var(--muted); text-decoration: line-through; text-decoration-color: var(--border); }
.ms-desc { font-size: 14px; color: var(--text); line-height: 1.5; margin-top: 3px; white-space: normal; overflow-wrap: anywhere; }
.ms-meta { font-size: 12px; color: var(--muted); margin-top: 3px; }
.ms-in, .ms-ta { width: 100%; font: inherit; font-size: 15px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--card-soft); color: var(--text); }
.ms-in:focus, .ms-ta:focus { outline: none; border-color: var(--green-500); box-shadow: 0 0 0 3px rgba(22, 163, 74, .12); background: #fff; }
.ms-ta { resize: none; line-height: 1.5; min-height: 64px; display: block; }
.ms-ta.ms-doc { min-height: 50vh; font-size: 16px; }
.ms-journal { min-height: 72px; }
.ms-addrow { margin-top: 10px; }
.ms-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.ms-spacer { flex: 1; }
.btn-primary.ms-sm { width: auto; padding: 9px 18px; font-size: 14px; }
.btn-ghost.ms-quiet { background: transparent; border: 1px solid var(--border); color: var(--muted); padding: 7px 12px; font-size: 13px; white-space: nowrap; }
.btn-ghost.ms-quiet:hover { color: var(--green-700); border-color: var(--green-700); }
.btn-ghost.ms-danger { background: transparent; color: #B91C1C; }
.ms-fold { display: block; width: 100%; text-align: left; border: none; background: none; font: inherit; font-size: 14px; font-weight: 600; color: var(--muted); padding: 10px 0 4px; cursor: pointer; }
.ms-fold:hover { color: var(--green-700); }
.ms-vischips { margin-top: 6px; }
.ms-vischips .chip, .ms-days .chip { padding: 5px 10px; font-size: 12.5px; }
.ms-days { margin-top: 6px; }
.ms-routine-edit { margin-top: 12px; padding-top: 6px; border-top: 2px dashed var(--border); }
.ms-prose { font-size: 17px; line-height: 1.65; }
.ms-prose p { margin: 0 0 14px; }
.ms-statement { font-size: 18px; line-height: 1.5; font-weight: 600; color: var(--green-900); margin: 4px 0 2px; }
.ms-h3 { font-size: 13px; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); margin: 18px 0 6px; }
.ms-h4 { font-size: 12px; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); margin: 10px 0 4px; }
.ms-ul { padding-left: 20px; font-size: 15px; line-height: 1.55; }
.ms-ul li { margin: 2px 0; }
.ms-lbl { display: block; font-size: 13px; font-weight: 600; color: var(--muted); margin: 12px 0 5px; }
/* Visions: titles are text fields in Edit mode (2026-11-03). Same look as the
   label they replace, plus a dotted underline so it reads as editable. */
.ms-lbl-row { display: flex; align-items: baseline; gap: 6px; }
.ms-lbl-edit, .ms-title-edit { font: inherit; color: inherit; background: transparent; border: 0; border-bottom: 1px dotted var(--muted); border-radius: 0; padding: 0 2px 1px; min-width: 120px; width: auto; max-width: 100%; }
.ms-lbl-edit { flex: 1 1 auto; font-size: 13px; font-weight: 600; }
.ms-title-row { display: flex; align-items: center; gap: 6px; }
.ms-title-edit { flex: 1 1 auto; font-size: inherit; font-weight: inherit; }
.ms-icon-edit { flex: 0 0 auto; width: 2.2em; min-width: 0; text-align: center; }
.ms-lbl-edit:focus, .ms-title-edit:focus { outline: none; border-bottom-style: solid; border-bottom-color: var(--green-700); }
.ms-fine { font-size: 12.5px; margin: 0 0 8px; }
.ms-goal { padding: 14px 0; border-top: 1px solid var(--border); }
.ms-goal:first-of-type, .ms-fold + .ms-goal { border-top: none; }
.ms-goal-top { display: flex; align-items: flex-start; gap: 12px; }
.ms-goal-title { flex: 1; font-size: 17px; font-weight: 700; line-height: 1.35; overflow-wrap: anywhere; }
.ms-goal.done .ms-goal-title { color: var(--muted); }
.ms-goal-meta { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 0 44px; }
.ms-goal-why { font-size: 15px; font-style: italic; color: var(--green-900); margin: 10px 0 0 44px; line-height: 1.5; }
.ms-goal .ms-desc, .ms-goal .ms-meta, .ms-goal .ms-h4, .ms-goal .ms-ul, .ms-goal-acts { margin-left: 44px; }
.ms-goal .ms-ul { padding-left: 18px; }
.ms-goal.ms-editing { padding-top: 4px; }
/* Goal progress on a Mission goal linked to a counter (counter.html). */
.ms-gprog { margin: 10px 0 0 44px; padding: 10px 12px; border-radius: 12px; background: rgba(127, 127, 127, .07); }
.ms-gprog-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-bottom: 6px; }
.ms-gprog-n { font-size: 15px; } .ms-gprog-n b { font-size: 20px; }
.ms-gprog-pct { font-weight: 700; color: var(--gc, #10b981); }
.ms-gprog-txt { font-size: 13px; color: var(--muted); margin-top: 6px; }
.gc-bar { height: 10px; border-radius: 999px; background: var(--card-soft); border: 1px solid var(--border); overflow: hidden; }
.gc-bar i { display: block; height: 100%; background: var(--gc, #10b981); border-radius: 999px; transition: width .3s; }
.gc-link { font: inherit; color: var(--green-700); text-decoration: underline; }
.ms-pill { display: inline-block; padding: 2px 9px; border-radius: 999px; background: var(--card-soft); border: 1px solid var(--border); font-size: 12px; font-weight: 600; color: var(--muted); }
.ms-pill.ms-late { background: #FEF2F2; color: #991B1B; border-color: #FECACA; }
.ms-pill.ms-done { background: var(--green-soft); color: var(--green-700); border-color: transparent; }
.ms-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 12px; }
.ms-tile { padding: 12px; border-radius: 14px; background: var(--card-soft); border: 1px solid var(--border); text-align: center; }
.ms-tile-n { font-size: 24px; font-weight: 800; color: var(--green-900); line-height: 1.1; }
@media (max-width: 480px) {
  .ms-goal-meta, .ms-goal-why, .ms-goal .ms-desc, .ms-goal .ms-meta, .ms-goal .ms-h4, .ms-goal .ms-ul, .ms-goal-acts { margin-left: 0; }
  .ms-tile-n { font-size: 20px; }
}
.ms-capture { padding: 10px 12px; }
.ms-capture .ms-in { border-style: dashed; }
.ms-capture-opts { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.ms-capture-sel { font: inherit; font-size: 12.5px; padding: 4px 6px; border: 1px solid var(--border); border-radius: 8px; background: var(--card); color: var(--muted); }
.ms-capture-sel:focus { outline: none; border-color: var(--green-500); color: var(--text); }
.map-frame { width: 100%; height: 72vh; min-height: 420px; border: 1px solid var(--border); border-radius: 12px; background: #fff; display: block; }
.cd-ask { margin-top: 8px; }
.cd-state { margin-top: 8px; font-size: 13px; font-weight: 600; }
.cd-pending { color: #92400E; } .cd-approved { color: var(--green-700); } .cd-denied { color: #B91C1C; }
.ms-due { color: var(--muted); }
.ms-due-now { color: #B91C1C; font-weight: 600; }
.ms-snooze { flex: none; padding: 5px 9px !important; font-size: 12px !important; }
.ms-idea { font-weight: 500; }
/* Idea actions: one wrapping row under the text, small and quiet. */
.ms-ib-acts { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; margin-top: 4px; }
.ms-ib-acts .ms-meta { margin: 0 4px 0 0; }
.ms-ib-acts .btn-ghost.ms-quiet { padding: 2px 8px; font-size: 12px; border-radius: 6px; line-height: 1.5; }
.ms-item:has(.ms-ib-acts) { padding: 7px 0; }
.ms-item:has(.ms-ib-acts) .ms-title { font-size: 15px; line-height: 1.3; }
.ms-ev { display: flex; align-items: baseline; gap: 10px; padding: 8px 0; border-top: 1px solid var(--border); font-size: 15px; }
.ms-ev:first-of-type { border-top: none; }
.ms-ev-dot { flex: 0 0 10px; width: 10px; height: 10px; border-radius: 50%; align-self: center; }
.ms-ev-when { flex: 0 0 auto; min-width: 128px; font-variant-numeric: tabular-nums; color: var(--muted); font-size: 13.5px; font-weight: 600; }
.ms-ev-title { flex: 1; min-width: 0; font-weight: 600; overflow-wrap: anywhere; }
@media (max-width: 480px) { .ms-ev { flex-wrap: wrap; } .ms-ev-when { min-width: 0; } }

/* ---- Monday meeting · DESIGN_BRIEF pass (2026-10-07) ----------------------
   Hero gradient card, white KPI cards with one big number + trend chip,
   pill chips for status, soft dividers instead of borders, pill buttons. */
.chip { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700;
  line-height: 1.5; white-space: nowrap; vertical-align: 1px; }
.chip-success { background: #DCFCE7; color: #166534; }
.chip-warning { background: #FEF3C7; color: #92400E; }
.chip-danger  { background: #FEE2E2; color: #991B1B; }
.chip-neutral { background: #F1F5F9; color: #475569; }

.mt-hero { color: #fff; border: none; padding: 26px 28px 24px;
  background: radial-gradient(circle at top right, rgba(134, 239, 172, 0.35), transparent 35%),
              linear-gradient(135deg, #0F5132 0%, #15803D 100%);
  box-shadow: 0 18px 45px rgba(15, 81, 50, 0.22); }
.mt-hero-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.mt-eyebrow { font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; opacity: .78; }
.mt-hero-title { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.15; margin-top: 6px; }
.mt-hero-sub { font-size: 14px; opacity: .85; margin-top: 6px; }
.mt-weeknav { display: flex; align-items: center; gap: 6px; }
.mt-navbtn { width: 36px; height: 36px; border-radius: 999px; border: none; background: rgba(255,255,255,.16); color: #fff;
  font: inherit; font-size: 18px; font-weight: 700; cursor: pointer; transition: background .15s; }
.mt-navbtn:hover { background: rgba(255,255,255,.28); }
.mt-navbtn:disabled { opacity: .35; cursor: default; }
.mt-week-label { font-weight: 700; font-size: 14px; min-width: 76px; text-align: center; font-variant-numeric: tabular-nums; }
.mt-hero-stat { margin-top: 22px; }
.mt-hero-num { font-size: 48px; font-weight: 800; letter-spacing: -0.03em; line-height: 1; }
.mt-hero-unit { font-size: 16px; font-weight: 600; opacity: .85; letter-spacing: 0; margin-left: 4px; }
.mt-hero-bar { height: 8px; border-radius: 999px; background: rgba(255,255,255,.22); margin: 14px 0 8px; overflow: hidden; max-width: 420px; }
.mt-hero-bar > div { height: 100%; border-radius: 999px; background: #fff; transition: width .3s; }
.mt-hero-meta { font-size: 13px; opacity: .85; }
.mt-wrap { margin-top: 14px; background: #fff; color: var(--green-900); border: none; font-weight: 700; padding: 9px 16px; border-radius: 999px; }
.mt-wrap:disabled { opacity: .6; }

.mt-add textarea { border-radius: 16px; padding: 12px 14px; background: var(--card-soft); border-color: transparent; margin-top: 0; }
.mt-add textarea:focus { outline: none; background: #fff; border-color: var(--green-500); }
.mt-add .chips .chip { background: #fff; color: var(--text); border: 1px solid var(--border); }
.mt-add .chips .chip.on { background: var(--green-700); color: #fff; border-color: var(--green-700); }
.mt-addrow .btn-primary { box-shadow: 0 8px 20px rgba(15, 81, 50, .22); transition: transform .15s, box-shadow .15s; }
.mt-addrow .btn-primary:hover { transform: translateY(-1px); box-shadow: 0 12px 26px rgba(15, 81, 50, .28); }

.mt-sec .card-head h2 { font-size: 18px; }
.mt-item { border-top: 1px solid var(--border); padding: 12px 0; }
.mt-check { width: 28px; height: 28px; flex-basis: 28px; border-radius: 999px; border: 2px solid #CBD5E1; transition: background .15s, border-color .15s; }
.mt-check:hover { border-color: var(--green-500); }
.mt-item.done .mt-check { background: var(--green-600); border-color: var(--green-600); }
.mt-text { font-size: 15px; }
.mt-src { margin-left: 6px; }
.mt-item.done .mt-src { opacity: .6; }
.mt-x { color: #CBD5E1; }

.mt-grid { gap: 12px; }
.mt-tile { border-radius: 20px; padding: 16px 18px; box-shadow: var(--shadow-soft); transition: transform .15s, box-shadow .15s; }
.mt-tile:hover { transform: translateY(-2px); box-shadow: 0 18px 45px rgba(15, 23, 42, 0.10); background: var(--card); }
.mt-tile-top { display: flex; justify-content: space-between; align-items: center; }
.mt-tile .kpi-label { margin: 0 0 8px; font-size: 12.5px; }
.mt-tile .kpi-value { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 10px; color: var(--text); }
.mt-tile-arrow { width: 26px; height: 26px; border-radius: 999px; background: var(--green-soft); color: var(--green-700);
  font-size: 13px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.mt-tile-hero { color: #fff; border: none;
  background: radial-gradient(circle at top right, rgba(134, 239, 172, 0.35), transparent 35%),
              linear-gradient(135deg, #0F5132 0%, #15803D 100%); }
.mt-tile-hero:hover { background: radial-gradient(circle at top right, rgba(134, 239, 172, 0.4), transparent 35%),
              linear-gradient(135deg, #0F5132 0%, #15803D 100%); }
.mt-tile-hero .kpi-label, .mt-tile-hero .kpi-value { color: #fff; }
.mt-tile-hero .kpi-label { opacity: .85; }
.mt-tile-hero .mt-tile-arrow { background: rgba(255,255,255,.18); color: #fff; }
.mt-tile-hero .chip { background: rgba(255,255,255,.18); color: #fff; }

.mt-table th { border-bottom: none; padding: 8px 10px; font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; }
.mt-table td { border-bottom: 1px solid var(--border); padding: 10px; font-size: 14px; }
.mt-table tbody tr:last-child td { border-bottom: none; }
.mt-table .mt-good { color: var(--green-700); }
.mt-table tbody tr:hover td { background: var(--card-soft); }
.hm-squotes { border-radius: 16px; }

.mt-fab { padding: 13px 20px; box-shadow: 0 12px 30px rgba(15, 81, 50, .30); transition: transform .15s, box-shadow .15s; }
.mt-fab:hover { transform: translateY(-2px); box-shadow: 0 18px 45px rgba(15, 81, 50, .36); }
.mt-pop { border-radius: 24px; padding: 18px; box-shadow: var(--shadow-card); }

/* ---- gross-profit quote helper ---- */
.gp-field { margin-bottom: 14px; }
.gp-field > label { display: block; font-size: 14px; font-weight: 700; margin-bottom: 4px; }
.gp-hint { font-size: 13px; color: var(--muted); line-height: 1.45; margin-bottom: 8px; }
.gp-field input { width: 100%; max-width: 240px; font: inherit; font-size: 18px; font-weight: 600; padding: 10px 14px;
  border: 1px solid var(--border); border-radius: 14px; background: var(--card-soft); }
.gp-field input:focus { outline: none; border-color: var(--green-500); background: #fff; }
.gp-cats .chip { font-size: 13.5px; }
.gp-result { margin: 16px 0 12px; }
.gp-price { color: #fff; border-radius: 20px; padding: 18px 20px;
  background: radial-gradient(circle at top right, rgba(134, 239, 172, 0.35), transparent 35%),
              linear-gradient(135deg, #0F5132 0%, #15803D 100%); }
.gp-price-label { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; opacity: .8; }
.gp-price-num { font-size: 40px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; margin: 4px 0; }
.gp-price-sub { font-size: 13px; opacity: .85; }
.gp-lines { margin-top: 10px; }
.gp-line { display: flex; justify-content: space-between; gap: 12px; padding: 8px 2px; border-bottom: 1px solid var(--border); font-size: 14px; }
.gp-line-total { border-bottom: none; }
.gp-line-total b { color: var(--green-700); }
.gp-copy { margin-top: 10px; }
.gp-note { font-size: 13px; line-height: 1.45; }
.gp-checklist { margin-top: 12px; padding: 14px 16px; border-radius: 16px; background: var(--card-soft); font-size: 13.5px; line-height: 1.5; }
.gp-check-head { font-weight: 700; margin-bottom: 6px; }
.gp-checklist ul { margin: 0 0 8px; padding-left: 18px; }
.gp-checklist li { margin: 4px 0; }
.gp-checklist .gp-hint { margin: 0; }
.gp-two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 6px; } .gp-two input { max-width: none; } .gp-mh { margin-bottom: 14px; } @media (max-width: 420px) { .gp-two { grid-template-columns: 1fr; } }
.fu-pick { font: inherit; font-size: 14px; font-weight: 600; padding: 8px 12px; border-radius: 999px; border: 1px solid var(--border); background: var(--green-soft); color: var(--green-700); max-width: 100%; }
.mood-sheet { padding: 10px 0 6px; } .mood-sheet .mood-btn { font-size: 52px; }
.recent-filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 10px; } .recent-filters .muted { font-size: 12.5px; }
.ts-controls { display: flex; gap: 8px; flex-wrap: wrap; }

/* ---- Ask Darren ---- */
.ask-thread { display: flex; flex-direction: column; gap: 10px; max-height: 360px; overflow-y: auto; padding: 4px 2px 8px; }
.ask-msg { max-width: 88%; padding: 10px 14px; border-radius: 16px; font-size: 15px; line-height: 1.45; }
.ask-user { align-self: flex-end; background: var(--green-700); color: #fff; border-bottom-right-radius: 6px; }
.ask-adam { align-self: flex-start; background: var(--card-soft); border: 1px solid var(--border); border-bottom-left-radius: 6px; }
.ask-who { font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--green-700); margin-bottom: 3px; }
.ask-chips { display: flex; gap: 6px; overflow-x: auto; padding: 6px 0 8px; -webkit-overflow-scrolling: touch; }
.ask-chips .chip { white-space: nowrap; cursor: pointer; flex: 0 0 auto; border: 1px solid var(--border); background: #fff; }
.ask-form { display: flex; gap: 8px; }
.ask-form input { flex: 1; min-width: 0; font: inherit; font-size: 15px; padding: 11px 14px; border: 1px solid var(--border); border-radius: 999px; background: var(--card-soft); }
.ask-form input:focus { outline: none; border-color: var(--green-500); background: #fff; }
.ask-form .btn-primary { width: auto; padding: 10px 18px; }
.ask-fine { font-size: 12.5px; margin-top: 8px; }
.asklog-row { border-bottom: 1px solid var(--border); padding: 8px 0; font-size: 14px; } .asklog-gap { display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 999px; font-size: 12px; font-weight: 600; background: #fff3dc; color: #9a5b00; } .asklog-row summary { cursor: pointer; } .asklog-a { margin: 8px 0 2px 14px; padding: 8px 12px; border-left: 3px solid var(--green-500); background: var(--card-soft); border-radius: 0 10px 10px 0; line-height: 1.5; }
/* clock-in phrase: a soft card that rises in, sits six seconds, fades */
.ci-phrase { position: fixed; left: 50%; bottom: 96px; transform: translate(-50%, 16px); max-width: min(420px, calc(100vw - 32px));
  background: var(--green-900); color: #fff; padding: 12px 18px; border-radius: 16px; font-size: 15px; font-weight: 600; line-height: 1.4;
  text-align: center; box-shadow: 0 12px 30px rgba(15, 81, 50, .3); opacity: 0; transition: opacity .35s, transform .35s; z-index: 60; pointer-events: none; }
.ci-phrase.on { opacity: 1; transform: translate(-50%, 0); }

/* #MM photos on the Monday tab: bigger than note attachments, they ARE the item */
.mt-img-big { width: 160px; height: 160px; }
@media (max-width: 480px) { .mt-img-big { width: 128px; height: 128px; } }

/* Your week: Monday summary card */
.wk-sec { margin-bottom: 12px; }
.wk-head { font-weight: 700; font-size: 13px; letter-spacing: .04em; text-transform: uppercase; color: var(--brand, #1f6b3a); margin-bottom: 6px; }
.wk-list { margin: 0; padding-left: 22px; font-size: 15.5px; line-height: 1.5; }
.wk-list li { margin: 2px 0; }
.wk-goals li::marker { font-weight: 700; }
.wk-from { font-size: 11px; vertical-align: middle; margin-left: 4px; }
.wk-fine { font-size: 12.5px; margin: 4px 0 0; }
.mt-goalblock { padding: 10px 0; border-bottom: 1px solid var(--border); }
.mt-goalname { font-weight: 700; font-size: 16px; margin-bottom: 4px; }
.mt-goalcols { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 640px) { .mt-goalcols { grid-template-columns: 1fr; } }
.mt-goalx, .mt-goalhide { border: 0; background: none; color: var(--muted, #6b7280); font-size: 12px; cursor: pointer; margin-left: 6px; }
.mt-goalx { font-size: 16px; line-height: 1; }
.mt-goal-off { opacity: .45; text-decoration: line-through; }
.mt-goalform { display: flex; gap: 6px; margin-top: 8px; }
.mt-goalform input { flex: 1; min-width: 0; padding: 7px 10px; border: 1px solid var(--border); border-radius: 8px; font: inherit; font-size: 14px; }
.mt-selfie-tech { margin-top: 10px; font-size: 14px; }
.mt-selfie { display: inline-flex; flex-direction: column; align-items: center; gap: 3px; text-decoration: none; color: inherit; }
.mt-selfie-cap { font-size: 11.5px; color: var(--muted, #6b7280); max-width: 160px; text-align: center; line-height: 1.2; }
.mt-selfie-nopic { padding: 8px 10px; border: 1px dashed var(--border); border-radius: 10px; }
.up-onsite { margin-top: 10px; }

/* ＋ Monday on every admin card: tiny, quiet, right end of the card head */
.card-head { position: relative; }
.mt-sendbtn { margin-left: auto; border: 1px solid var(--border); background: transparent; color: var(--muted, #6b7280); border-radius: 999px; font: inherit; font-size: 11px; padding: 2px 8px; cursor: pointer; opacity: .55; white-space: nowrap; }
.mt-sendbtn:hover { opacity: 1; color: var(--brand, #1f6b3a); border-color: var(--brand, #1f6b3a); }

/* Mission rich-text editor */
.ms-rte { border: 1px solid var(--border); border-radius: 12px; background: var(--card-soft); overflow: hidden; }
.ms-rte:focus-within { border-color: var(--green-500); box-shadow: 0 0 0 3px rgba(22, 163, 74, .12); background: #fff; }
.ms-rte-bar { display: flex; flex-wrap: wrap; gap: 4px; padding: 6px 8px; border-bottom: 1px solid var(--border); background: rgba(0,0,0,.02); }
.ms-rte-btn { border: 1px solid transparent; background: transparent; border-radius: 8px; font: inherit; font-size: 12.5px; padding: 4px 8px; cursor: pointer; color: var(--text); }
.ms-rte-btn:hover { background: #fff; border-color: var(--border); }
.ms-rte-sep { width: 1px; background: var(--border); margin: 2px 4px; }
.ms-rte-area { min-height: 160px; padding: 12px 14px; outline: none; font-size: 15px; line-height: 1.55; }
.ms-rte-area:empty::before { content: attr(data-placeholder); color: var(--muted, #6b7280); }
.ms-prose h2 { font-size: 20px; margin: 14px 0 6px; }
.ms-prose h3 { font-size: 16px; margin: 12px 0 4px; }
.ms-prose ul, .ms-prose ol { padding-left: 22px; margin: 6px 0; }
.ms-prose blockquote { border-left: 3px solid var(--border); margin: 8px 0; padding-left: 10px; color: var(--muted, #6b7280); }
.ms-snoozers { display: inline-flex; align-items: center; gap: 2px; }
.ms-datepick { position: relative; display: inline-flex; align-items: center; cursor: pointer; font-size: 13px; color: var(--muted, #6b7280); padding: 4px 6px; border-radius: 8px; }
.ms-datepick:hover { background: var(--card-soft); color: var(--text); }
.ms-datepick input[type=date] { position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%; cursor: pointer; }
.ms-actions .ms-datepick { border: 1px solid var(--border); }
.ms-actions .ms-datepick::after { content: " Pick a date"; }
.tips-row { display: grid; grid-template-columns: 1fr 2fr 1fr; gap: 10px; }
@media (max-width: 640px) { .tips-row { grid-template-columns: 1fr; } }
.tips-line .prv-acts { flex-wrap: wrap; }
.tip-editbox { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 10px 12px; margin: -4px 0 8px; background: var(--card-soft); border: 1px solid var(--border); border-radius: 10px; font-size: 14px; }
.tip-editbox label { display: inline-flex; align-items: center; gap: 4px; }
.tip-editbox input { font: inherit; padding: 6px 8px; border: 1px solid var(--border); border-radius: 8px; }
.tip-editbox .te-share { width: 90px; } .tip-editbox .te-client { width: 180px; }
.rvoid { opacity: .55; text-decoration: line-through; }
.rvoid .muted { text-decoration: none; }

/* Referral: what the office should do next */
.ref-next .chips { gap: 8px; flex-wrap: wrap; }
.ref-next-hint { margin: 0; font-size: 13px; min-height: 1em; }

/* ---- Org chart: a real tree with connector lines (2026-10-21), drawn by
   org_chart.js. Wide screens: classic top-down tree, children in a row under
   their manager; side staff (sales, office) sit on the manager's row joined by
   a short dashed line. Phones: a vertical indented tree with a rail. ---- */
.oc-wrap { overflow-x: auto; padding: 4px 0; }
.oc, .oc ul { list-style: none; margin: 0; padding: 0; display: flex; justify-content: center; position: relative; }
.oc ul { padding-top: 22px; }
.oc li { display: flex; flex-direction: column; align-items: center; position: relative; padding: 22px 2px 0; }
.oc > li { padding-top: 0; }
.oc li::before, .oc li::after { content: ""; position: absolute; top: 0; right: 50%; width: 50%; height: 22px; border-top: 1.5px solid var(--border-strong, #cbd5e1); }
.oc li::after { right: auto; left: 50%; border-left: 1.5px solid var(--border-strong, #cbd5e1); }
.oc > li::before, .oc > li::after, .oc li:only-child::before, .oc li:only-child::after { display: none; }
.oc li:first-child::before, .oc li:last-child::after { border: 0 none; }
.oc li:last-child::before { border-right: 1.5px solid var(--border-strong, #cbd5e1); border-radius: 0 8px 0 0; }
.oc li:first-child::after { border-radius: 8px 0 0 0; }
.oc ul::before { content: ""; position: absolute; top: 0; left: 50%; width: 0; height: 22px; border-left: 1.5px solid var(--border-strong, #cbd5e1); }
.oc ul.oc-staff { display: none; }
/* manager row: [pad][manager][side staff] — pad mirrors the side group so the
   manager stays centred over the row below and the line from above meets him */
.oc-row { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; }
.oc-pad { grid-column: 1; }
.oc-side { grid-column: 3; display: flex; align-items: center; gap: 8px; justify-self: start; margin-left: 18px; position: relative; }
.oc-sidenode { display: flex; align-items: center; }
.oc-side::before { content: ""; position: absolute; left: -18px; top: 50%; width: 18px; border-top: 1.5px dashed var(--border-strong, #cbd5e1); }
.org-node { display: flex; flex-direction: column; align-items: center; gap: 3px; width: 88px; padding: 8px 4px; border: 1px solid var(--border); border-radius: 12px; background: var(--card-soft); font: inherit; color: inherit; cursor: pointer; text-align: center; position: relative; z-index: 1; }
.org-node:hover { border-color: var(--green-500); }
.oc-side .org-node { background: #fff; }
.org-avatar { width: 44px; height: 44px; font-size: 15px; }
.org-name { font-size: 13px; font-weight: 700; line-height: 1.15; }
.org-last { font-weight: 600; }
.org-title { font-size: 11px; color: var(--muted); line-height: 1.15; }
.org-txt { display: contents; }
@media (max-width: 639px) {
  .oc, .oc ul { display: block; }
  .oc ul { padding: 0 0 0 20px; margin-left: 24px; }
  .oc ul::before { display: none; }
  .oc li { display: block; padding: 10px 0 0; }
  .oc > li { padding-top: 0; }
  /* :nth-child(n) only raises specificity above the wide-screen first/last
     rules so the resets below win. Rail: from the bottom of the manager's row
     down to each child's centre (node 62px tall, li has 10px on top → 41px). */
  .oc li:nth-child(n)::before, .oc li:nth-child(n)::after { display: none; border: 0; border-radius: 0; }
  .oc ul > li:nth-child(n)::before { display: block; left: -20px; right: auto; top: -10px; bottom: auto; width: 16px; height: 51px; border: 0; border-left: 1.5px solid var(--border-strong, #cbd5e1); border-bottom: 1.5px solid var(--border-strong, #cbd5e1); border-radius: 0 0 0 8px; }
  .oc ul > li:nth-child(n):not(:last-child)::after { display: block; left: -20px; right: auto; top: 41px; bottom: 0; width: 0; height: auto; border: 0; border-left: 1.5px solid var(--border-strong, #cbd5e1); }
  /* phone: the row is just the manager; side staff become a dashed list
     right under him, ahead of the crew, on the same rail */
  .oc-row { display: flex; align-items: flex-start; }
  .oc-pad, .oc-side { display: none; }
  .oc ul.oc-staff { display: block; }
  .oc ul.oc-staff > li:nth-child(n)::before { border-bottom-style: dashed; }
  .oc ul.oc-staff > li .org-node { background: #fff; }
  .oc ul.oc-staff > li > ul.oc-staff { margin-left: 24px; }
  .oc ul.oc-staff:has(+ ul.oc-main) > li:last-child::after { display: block; left: -20px; right: auto; top: 41px; bottom: 0; width: 0; height: auto; border: 0; border-left: 1.5px solid var(--border-strong, #cbd5e1); }
  .org-node { flex-direction: row; width: auto; max-width: 100%; text-align: left; gap: 10px; padding: 6px 12px 6px 6px; height: 62px; }
  .org-txt { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
  .org-avatar { width: 36px; height: 36px; font-size: 13px; flex: 0 0 36px; }
  .org-name br { display: none; }
  .org-last { margin-left: 4px; }
}

/* Full-screen org chart (2026-10-22): a plain white sheet over everything;
   the tree is drawn a size up so it reads from across a desk. */
.org-full { position: fixed; inset: 0; z-index: 90; background: #fff; display: flex; flex-direction: column; overflow: auto; overscroll-behavior: contain; }
.org-full[hidden] { display: none; }
.org-full-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--border); }
.org-full-head h2 { font-size: 20px; font-weight: 700; margin: 0; }
.org-full-body { flex: 1; padding: 24px 16px 40px; }
.org-full-body .oc-wrap { min-height: 100%; display: flex; align-items: flex-start; justify-content: center; }
.org-full-body .org-node { cursor: default; width: 140px; padding: 12px 8px; gap: 5px; }
.org-full-body .org-node:hover { border-color: var(--border); }
.org-full-body .org-avatar { width: 72px; height: 72px; font-size: 22px; }
.org-full-body .org-name { font-size: 17px; }
.org-full-body .org-title { font-size: 14px; }
.org-full-body .oc li { padding-left: 8px; padding-right: 8px; }
body.org-full-open { overflow: hidden; }
#org-admin .oc-wrap { cursor: zoom-in; }
#org-admin .org-node { cursor: pointer; }
@media (max-width: 639px) {
  .org-full-body .org-node { width: auto; height: 70px; }
  .org-full-body .org-avatar { width: 44px; height: 44px; font-size: 15px; flex: 0 0 44px; }
  .org-full-body .oc ul > li:nth-child(n)::before { height: 55px; }
  .org-full-body .oc ul > li:nth-child(n):not(:last-child)::after, .org-full-body .oc ul.oc-staff:has(+ ul.oc-main) > li:last-child::after { top: 45px; }
}

/* Repeating Mission tasks (2026-10-15) */
.ms-repeat { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 8px 0 2px; }
.ms-repeat .ms-sel { width: auto; padding: 6px 10px; font-size: 14px; }
.ms-repeat [hidden] { display: none; }

/* CSR phone scorecard (2026-10-15) */
.csr-note { font-size: 12.5px; margin: 10px 0 0; }
.kpi-tile.active { outline: 2px solid var(--green-500); }
.csr-list { margin-top: 12px; }
.csr-h3 { font-size: 14px; margin: 4px 0 8px; color: var(--muted); font-weight: 600; }
.csr-call { border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; background: var(--card-soft); cursor: pointer; }
.csr-call-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.csr-call-title { font-weight: 600; font-size: 14.5px; }
.csr-call-sub { font-size: 12.5px; margin-top: 2px; }
.csr-call-score { font-weight: 700; font-size: 18px; min-width: 40px; text-align: center; border-radius: 10px; padding: 4px 6px; }
.csr-call-score.good { background: rgba(22,163,74,.12); color: var(--green-700, #15803d); }
.csr-call-score.mid { background: rgba(245,158,11,.14); color: #b45309; }
.csr-call-score.low { background: rgba(239,68,68,.12); color: #b91c1c; }
.csr-call-body { display: none; margin-top: 10px; font-size: 13.5px; }
.csr-call.open .csr-call-body { display: block; }
.csr-call-body h4, .csr-h4 { font-size: 12.5px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin: 12px 0 4px; }
.csr-call-body ul, .csr-coach-list { margin: 0; padding-left: 18px; }
.csr-call-body li, .csr-coach-list li { margin: 4px 0; line-height: 1.4; }
.csr-flags li { color: #b91c1c; }
.csr-quote { font-style: italic; border-left: 3px solid var(--green-500); padding-left: 10px; margin: 4px 0; line-height: 1.4; }
.csr-dims-mini { display: flex; flex-wrap: wrap; gap: 6px 12px; font-size: 12.5px; color: var(--muted); }
.csr-overall { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.csr-big { font-size: 38px; font-weight: 800; letter-spacing: -0.02em; line-height: 1; }
.csr-big .muted { font-size: 16px; font-weight: 500; }
.csr-overall-label { font-weight: 600; font-size: 14.5px; }
.csr-dims { display: grid; gap: 8px; }
.csr-dim-row { display: flex; align-items: baseline; gap: 8px; font-size: 13.5px; }
.csr-dim-row b { margin-left: auto; }
.csr-dim-prev { font-size: 12px; min-width: 44px; text-align: right; }
.csr-bar { height: 7px; background: var(--border); border-radius: 6px; overflow: hidden; margin-top: 3px; }
.csr-std-row { display: flex; justify-content: space-between; gap: 10px; font-size: 13.5px; padding: 6px 0; border-bottom: 1px solid var(--border); }
.csr-std-row:last-child { border-bottom: 0; }
.csr-focus { font-size: 14px; margin: 0 0 6px; }
.csr-bar > div { height: 100%; border-radius: 6px; }

/* Job reviews (2026-10-15) */
.jr-tiles { margin-bottom: 8px; }
.jr-warn { color: #b45309; }
.jp-visits { margin-top: 16px; }
.jp-visits > summary { font-size: 13px; text-transform: uppercase; letter-spacing: .04em; margin-bottom: 8px; }
.jr-h3 { font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin: 16px 0 8px; }
.jr-row { border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; background: var(--card-soft); }
.jr-row.low { border-color: #f59e0b; }
.jr-sub { font-size: 12.5px; margin-top: 2px; }
.jr-scores { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 12.5px; color: var(--muted); margin-top: 6px; }
.jr-s b { color: var(--text); }
.jr-s.low b { color: #b91c1c; }
.jr-s.na b { color: var(--soft, #9ca3af); }
.jr-comment { margin-top: 8px; font-size: 14px; line-height: 1.4; border-left: 3px solid var(--green-500); padding-left: 10px; }
.jr-comment.none { border-left-color: #f59e0b; font-size: 13px; }
.jr-fold { margin-top: 12px; }
.jr-fold summary { cursor: pointer; font-size: 13.5px; margin-bottom: 8px; }
.jr-table td, .jr-table th { white-space: nowrap; }

.csr-goal-row { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.csr-goal-big { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; }
.csr-goal-big .muted { font-size: 15px; font-weight: 500; }
.csr-goal-pct { font-weight: 700; font-size: 18px; }
.csr-goal-pct.hit { color: var(--green-700, #15803d); }
.csr-goal-bar { height: 10px; margin: 8px 0 6px; }

/* CSR promises */
.csr-promise { display: flex; align-items: flex-start; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.csr-promise:last-child { border-bottom: 0; }
.csr-promise.late .csr-promise-what { color: #b91c1c; }
.csr-promise.done .csr-promise-what { text-decoration: line-through; color: var(--muted); }
.csr-promise-text { flex: 1; min-width: 0; }
.csr-promise-what { font-size: 14.5px; font-weight: 600; line-height: 1.35; }
.csr-tel { color: var(--green-700, #15803d); text-decoration: none; }
.csr-dismiss { padding: 2px 8px; font-size: 14px; }
.csr-promise.done .ms-check { background: var(--green-600); border-color: var(--green-600); }
.jp-cats-all td { font-weight: 700; border-top: 2px solid var(--border); }

/* ---- recycle tickets (recycle.js) ---- */
.rc-actions { display: flex; gap: 8px; flex-wrap: wrap; margin: 6px 0 10px; }
.rc-two { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.rc-two > *, .rc-form .adv-field { min-width: 0; }
.rc-form input, .rc-form select { box-sizing: border-box; width: 100%; max-width: 100%; }
.rc-lines-head, .rc-line { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr 28px; gap: 6px; align-items: center; }
.rc-lines-head { font-size: 12px; color: var(--muted); padding: 0 2px; }
.rc-line { margin-bottom: 6px; }
.rc-line input { min-width: 0; width: 100%; font-size: 15px; padding: 10px 8px; border: 1px solid var(--border); border-radius: 12px; background: var(--card); font-family: inherit; }
.rc-x { border: none; background: none; color: var(--muted); font-size: 14px; cursor: pointer; padding: 4px; }
.rc-photo img { display: block; max-width: 100%; max-height: 320px; border-radius: 12px; border: 1px solid var(--border); margin: 0 auto 8px; }
.rc-reading .rc-photo img { max-height: 200px; opacity: .7; }
.rc-scannote { background: #FFFBEB; border: 1px solid #FDE68A; border-radius: 10px; padding: 8px 10px; }
.rc-more { font-size: 14px; }
.rc-more summary { cursor: pointer; color: var(--muted); padding: 4px 0; }
.rc-row { display: flex; justify-content: space-between; gap: 10px; cursor: pointer; }
.rc-row-nums { white-space: nowrap; text-align: right; }
.rc-in { color: var(--green-700); }
.rc-out { color: #B91C1C; }
.rc-edit { padding: 8px 0 12px; border-bottom: 1px solid var(--border); }
.rc-table { width: 100%; border-collapse: collapse; font-size: 14px; margin: 6px 0 10px; }
.rc-table th { text-align: left; font-weight: 600; color: var(--muted); font-size: 12px; padding: 4px 6px; }
.rc-table td { padding: 6px; border-top: 1px solid var(--border); }
.rc-table td:not(:first-child), .rc-table th:not(:first-child) { text-align: right; }
.rc-break summary { cursor: pointer; font-weight: 600; padding: 6px 0; }
.rc-h3 { font-size: 15px; margin: 14px 0 4px; }
.rc-tiles { margin-top: 4px; }

/* ---- job profit charts (profit_charts.js) ---- */
.jpc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 4px 0 14px; }
.jpc-panel { background: var(--card-soft); border: 1px solid var(--border); border-radius: 14px; padding: 12px 14px; min-width: 0; }
.jpc-panel h4 { margin: 0 0 8px; font-size: 13px; font-weight: 600; color: var(--muted); }
.jpc-wide { grid-column: 1 / -1; }
.jpc-donut { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.jpc-donut svg { flex: 0 0 140px; }
.jpc-center { font-size: 15px; font-weight: 700; fill: var(--text); }
.jpc-sub { font-size: 10px; fill: var(--muted); }
.jpc-legend { display: flex; flex-direction: column; gap: 6px; font-size: 13px; min-width: 0; flex: 1; }
.jpc-leg { display: grid; grid-template-columns: 10px 1fr auto auto; gap: 8px; align-items: center; }
.jpc-leg b { color: var(--text); }
.jpc-dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.jpc-svg-bars { width: 100%; height: auto; display: block; }
.jpc-grid line.jpc-grid { stroke: var(--border); stroke-width: 1; }
.jpc-ref { stroke: var(--muted); stroke-width: 1; stroke-dasharray: 3 3; opacity: .7; }
.jpc-tick { font-size: 9px; fill: var(--muted); }
.jpc-val { font-size: 10px; font-weight: 600; fill: var(--text); }
.jpc-bar { fill: var(--green-600); }
.jpc-bar-low { fill: #e34948; }
.jpc-foot { font-size: 12px; margin-top: 4px; }
.jpc-empty { font-size: 13px; padding: 10px 0; }
@media (max-width: 640px) { .jpc-grid { grid-template-columns: 1fr; } }

/* ---- job profitability custom date range ---- */
.jp-range { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; margin-right: 8px; font-size: 13px; }
.jp-range input { font-family: inherit; font-size: 13px; padding: 6px 8px; border: 1px solid var(--border); border-radius: 10px; background: var(--card-soft); color: var(--text); max-width: 150px; }
.jp-range + .period-select { margin-left: 0; }
@media (max-width: 640px) { .jp-range { width: 100%; order: 3; margin: 8px 0 0; } .card-head { flex-wrap: wrap; } }

/* Latest selfies (Home): three square photos, name + time-up under each */
.selfie-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.selfie-tile { display: block; text-decoration: none; color: inherit; text-align: center; }
.selfie-tile img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 12px; border: 1px solid var(--border); background: var(--border); }
.selfie-name { font-size: 13.5px; font-weight: 600; margin-top: 6px; }
.selfie-up { font-size: 12px; color: var(--muted); margin-top: 1px; }
.selfie-record { font-size: 12.5px; color: var(--muted); margin-top: 10px; text-align: center; }
.selfie-who { cursor: pointer; text-decoration: underline; text-decoration-color: var(--border); text-underline-offset: 3px; }
.selfie-who:hover { text-decoration-color: var(--green-700); }
.selfie-sep { color: var(--muted); margin: 0 5px; font-weight: 400; }
.selfie-gallery { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.selfie-gtile { display: block; text-decoration: none; color: inherit; }
.selfie-gtile img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 12px; border: 1px solid var(--border); background: var(--border); }
.selfie-gcap { font-size: 12px; color: var(--muted); margin-top: 4px; }

/* ---- new navigation (feature_nav2) ---- */
.nav2-menu { width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--border); background: var(--card); color: var(--text); font-size: 18px; cursor: pointer; margin-right: 10px; }
.nav2-title { flex: 1; font-size: 15px; font-weight: 700; color: var(--muted); margin-left: 12px; }
body.nav2 .topbar { gap: 0; }
body.nav2 .topbar-actions #change-pw-btn { display: none; }   /* lives in the drawer under nav2 (same button, same function) */
.nav2-scrim { position: fixed; inset: 0; background: rgba(15, 23, 42, .35); z-index: 60; }
.nav2-drawer { position: fixed; top: 0; bottom: 0; left: 0; width: 82%; max-width: 320px; z-index: 61; background: var(--card); box-shadow: 0 0 40px rgba(15,23,42,.25);
  padding: calc(18px + env(safe-area-inset-top, 0px)) 14px 18px; display: flex; flex-direction: column; gap: 4px; border-radius: 0 24px 24px 0; }
.nav2-drawer[hidden] { display: none; }
.nav2-who { display: flex; gap: 10px; align-items: center; padding: 4px 8px 14px; border-bottom: 1px solid var(--border); margin-bottom: 8px; }
.nav2-who b { display: block; font-size: 15px; } .nav2-who span.muted { font-size: 12px; }
.nav2-item { display: grid; grid-template-columns: 28px 1fr auto; gap: 10px; align-items: center; padding: 12px 10px; border-radius: 12px; font-size: 15px; font-weight: 600; cursor: pointer; border: none; background: none; color: var(--text); text-align: left; font-family: inherit; width: 100%; }
.nav2-item.on { background: var(--green-soft); color: var(--green-700); }
.nav2-item .n2i { font-size: 18px; }
.nav2-item .n2b { font-size: 11px; font-weight: 800; background: #DC2626; color: #fff; padding: 2px 7px; border-radius: 999px; }
.nav2-item .n2b.quiet { background: var(--card-soft); color: var(--muted); border: 1px solid var(--border); }
.nav2-sep { height: 1px; background: var(--border); margin: 6px 8px; }
.nav2-foot { margin-top: auto; font-size: 11px; color: var(--soft); padding: 8px; }
body.nav2-open { overflow: hidden; }
body.nav2 .tabbar-btn { font-size: 10px; }
.spotlight-card { background: var(--green-soft); border-color: var(--green-500); }
.spotlight-card h2 { color: var(--green-700); }
.spotlight-card p { margin: 0; font-size: 15px; line-height: 1.45; }

/* ---- nav2 format: the Layout Lab look on the real cards ---- */
body.nav2 h1, body.nav2 .card-head h2, body.nav2 .score-big, body.nav2 .hh-bonus-big, body.nav2 .coins-num, body.nav2 .nav2-coins-tile .v, body.nav2 .kpi-value { font-family: "Manrope", "Inter", system-ui, -apple-system, sans-serif; }
body.nav2 .topbar { padding: 10px 16px; gap: 8px; }
body.nav2 .topbar-actions #logout-btn { display: none; }       /* in the drawer */
body.nav2 .topbar-actions .avatar-lg { width: 36px; height: 36px; font-size: 13px; margin: 0; }
body.nav2 .brand.small { font-size: 18px; }
body.nav2 .welcome { margin: 2px 0 12px; gap: 10px; }
body.nav2 .welcome h1 { font-size: 18px; letter-spacing: -.01em; }
body.nav2 .welcome .muted { font-size: 13px; margin-top: 0; }
body.nav2 .welcome-since { font-size: 11.5px; }
body.nav2 .container { padding-top: 4px; }
body.nav2 .card { border-radius: 20px; padding: 14px 16px; margin-bottom: 12px; box-shadow: none; }
body.nav2 .tc-card { padding: 14px 16px; }
body.nav2 .card-head { margin-bottom: 8px; }
body.nav2 .card-head h2 { font-size: 15px; }
body.nav2 .nav2-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 12px; }
body.nav2 .nav2-tiles .card { margin: 0; padding: 12px 14px; min-width: 0; }
body.nav2 .nav2-tiles .score-card { text-align: left; }
body.nav2 .nav2-tiles .score-label { font-size: 11px; }
body.nav2 .nav2-tiles .score-big { font-size: 26px; letter-spacing: -.02em; }
body.nav2 .nav2-tiles .score-sub { font-size: 12px; }
body.nav2 .nav2-coins-tile { text-align: left; cursor: pointer; font-family: inherit; color: var(--text); background: var(--card); border: 1px solid var(--border); }
body.nav2 .nav2-coins-tile .v { font-size: 26px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
body.nav2 .nav2-coins-tile .l { font-size: 12px; color: var(--muted); margin-top: 2px; }
body.nav2 #today-card { background: linear-gradient(135deg, var(--green-900), var(--green-700)); color: #fff; border: none; }
body.nav2 #today-card .card-head h2, body.nav2 #today-card .muted { color: #fff; }
body.nav2 #today-card .muted { opacity: .85; }
body.nav2 .nav2-end { text-align: center; color: var(--soft); font-size: 12px; padding: 4px 0 18px; }
body.nav2 .tab-hidden.nav2-end { display: none; }

/* score trend arrow (since yesterday) */
.score-trend { font-size: 12px; font-weight: 800; letter-spacing: 0; text-transform: none; margin-left: 6px; }
.score-trend.up { color: var(--green-600); } .score-trend.down { color: #B91C1C; } .score-trend.flat { color: var(--muted); }
.score-trend-when { font-weight: 600; color: var(--muted); }
/* nav2 green Today hero: every figure readable on the dark green */
body.nav2 #today-card .td-hero-value { color: #fff; }
body.nav2 #today-card .td-hero-label, body.nav2 #today-card .td-hero-sub, body.nav2 #today-card .td-sum, body.nav2 #today-card .td-floor { color: rgba(255, 255, 255, .82); }
body.nav2 #today-card .td-note, body.nav2 #today-card .td-nudge { color: #fff; }

/* Today: tiers as plain sentences (rough numbers) */
.td-lines { display: flex; flex-direction: column; gap: 6px; margin: 4px 0 6px; }
.td-line { font-size: 15px; line-height: 1.45; padding: 10px 12px; border-radius: 14px; background: var(--card-soft); border: 1px solid var(--border); color: var(--text); }
.td-line b { font-weight: 800; }
.td-line-top { background: #EAF6EF; border-color: transparent; font-size: 16px; }
.td-line-approx { color: var(--muted); font-weight: 800; margin-right: 4px; }
.td-line-coins { color: var(--muted); font-size: 12.5px; }
body.nav2 #today-card .td-line { background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .18); color: #fff; }
body.nav2 #today-card .td-line-top { background: rgba(255, 255, 255, .22); }
body.nav2 #today-card .td-line-approx, body.nav2 #today-card .td-line-coins { color: rgba(255, 255, 255, .8); }
body.nav2 #today-card .td-floor b, body.nav2 #today-card .td-note b, body.nav2 #today-card .td-nudge b { color: #fff; }
/* nav2 green Today hero: the jobs list and any other muted text, readable */
body.nav2 #today-card .td-job-share, body.nav2 #today-card .td-job-client, body.nav2 #today-card .td-job-amt,
body.nav2 #today-card .td-job, body.nav2 #today-card .td-line-coins, body.nav2 #today-card .td-sum,
body.nav2 #today-card .td-floor, body.nav2 #today-card .td-hero-label, body.nav2 #today-card .td-hero-sub { color: rgba(255, 255, 255, .92); }
body.nav2 #today-card .td-job-share { font-weight: 600; }
body.nav2 #today-card .td-job { border-color: rgba(255, 255, 255, .15); }

/* log by person: time-off context */
.lbp-context { background: var(--card-soft); border: 1px solid var(--border); border-radius: 14px; padding: 10px 14px; margin: 4px 0 10px; font-size: 14px; }
.lbp-ctx-row { display: grid; grid-template-columns: 150px auto 1fr; gap: 10px; align-items: baseline; padding: 4px 0; }
.lbp-ctx-k { color: var(--muted); font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.lbp-hi { color: #B45309; } .lbp-lo { color: var(--green-700); }
.lbp-crew { margin-top: 6px; font-size: 13px; } .lbp-crew summary { cursor: pointer; color: var(--muted); font-weight: 600; }
.lbp-crew tr.lbp-me td { font-weight: 700; background: var(--green-soft); }
@media (max-width: 640px) { .lbp-ctx-row { grid-template-columns: 1fr; gap: 2px; } }

.asklog-card > summary { cursor: pointer; font-size: 16px; font-weight: 700; list-style: none; }
.asklog-card > summary::-webkit-details-marker { display: none; }
.asklog-card > summary::before { content: '▸ '; color: var(--muted); }
.asklog-card[open] > summary::before { content: '▾ '; }

/* latest reviews (crew-wide) */
.rb-row { padding: 10px 0; border-top: 1px solid var(--border); }
.rb-row:first-child { padding-top: 2px; border-top: none; }
.rb-top { display: flex; align-items: baseline; gap: 8px; font-size: 13px; }
.rb-stars { color: #F59E0B; letter-spacing: 1px; font-size: 14px; }
.rb-who { font-weight: 700; } .rb-date { margin-left: auto; color: var(--muted); font-size: 12px; white-space: nowrap; }
.rb-text { font-size: 14.5px; line-height: 1.45; margin-top: 4px; }
.rb-by { font-size: 12px; color: var(--muted); margin-top: 3px; }

/* close rate chart */
.variant-toggle { display: inline-flex; gap: 6px; margin-left: auto; }
.crc-legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: 13px; margin: 2px 0 8px; align-items: center; }
.crc-leg { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; }
.crc-leg i { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }
.crc-leg i.crc-cur { background: transparent; border: 1.5px dashed var(--muted); }
.crc-val { font-size: 10px; font-weight: 700; fill: var(--text); }

.hm-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.hm-chip { font-size: 12.5px; padding: 4px 9px; border-radius: 999px; background: var(--card-soft); border: 1px solid var(--border); }

/* ---- lead installer page (installer.js, 2026-10-20) ---- */
.inst-hero { padding: 14px 16px; border-radius: 14px; background: var(--green-700); color: #fff; margin-bottom: 10px; }
.inst-hero-label { font-size: 12px; text-transform: uppercase; letter-spacing: .04em; opacity: .85; }
.inst-hero-value { font-size: 34px; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.inst-hero-sub { font-size: 12px; opacity: .9; margin-top: 4px; }
.inst-tile { text-align: left; border: 1px solid transparent; cursor: pointer; font: inherit; color: inherit; }
.inst-tile-on { border-color: var(--green-500); }
.inst-list-head { font-size: 13px; font-weight: 700; margin: 8px 0 2px; }
.inst-job { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--border); }
.inst-job:last-child { border-bottom: none; }
.inst-job-l { min-width: 0; }
.inst-job-client { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.inst-job-sub { font-size: 12px; color: var(--muted); margin-top: 1px; }
.inst-job-r { text-align: right; flex: none; }
.inst-job-pay { font-weight: 700; font-variant-numeric: tabular-nums; }
.inst-job-val { font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.inst-done .inst-job-client { color: var(--green-700); }
.inst-tag { display: inline-block; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; padding: 1px 6px; border-radius: 999px; background: rgba(127,127,127,.12); color: var(--muted); vertical-align: 1px; }
.inst-tag-warn { background: rgba(234,179,8,.18); color: #92400e; }
.inst-today-head { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; font-size: 13px; margin-bottom: 4px; }
.inst-today-pay { color: var(--green-700); }
.inst-clock-link { display: block; width: 100%; background: none; border: none; color: var(--muted); font: inherit; font-size: 13px; padding: 10px 0 18px; cursor: pointer; text-align: center; }
.inst-bonus { margin: 6px 0 12px; }
.inst-bonus-head { display: flex; justify-content: space-between; font-size: 14px; margin-bottom: 6px; }
.inst-bar { position: relative; height: 12px; border-radius: 6px; background: var(--border, #e5e7eb); overflow: visible; }
.inst-bar-fill { height: 100%; border-radius: 6px; background: var(--green-700, #166534); transition: width .4s; }
.inst-bar-mark { position: absolute; top: -3px; width: 3px; height: 18px; margin-left: -1px; border-radius: 2px; background: var(--muted, #6b7280); }
.inst-bar-mark.inst-bar-hit { background: #f59e0b; }
.inst-bonus-sub { font-size: 12px; color: var(--muted, #6b7280); margin-top: 6px; }
.inst-tag-ok { background: #dcfce7; color: #166534; }
.inst-nudge { font-size: 13px; color: var(--green-700, #166534); font-weight: 600; margin: 8px 0 10px; }
.inst-quote-card { background: linear-gradient(135deg, var(--green-700), #0f3d22); color: #fff; border: none; }
.inst-quote-label { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; opacity: .85; font-weight: 700; }
.inst-quote { margin: 6px 0 0; font-size: 18px; font-weight: 700; line-height: 1.35; letter-spacing: -.01em; }

/* Approved quotes board (Quotes page): standings + feed */
.qw-standings { display: flex; flex-direction: column; gap: 4px; margin: 2px 0 10px; }
.qw-row { display: flex; align-items: baseline; gap: 8px; padding: 6px 8px; border-radius: 10px; font-size: 15px; }
.qw-row.qw-me, .fu-item.qw-me { background: rgba(46, 125, 50, .10); }
.fu-item.qw-me { border-radius: 10px; padding-left: 8px; padding-right: 8px; }
.qw-medal { width: 28px; text-align: center; }
.qw-name { font-weight: 700; flex: 1; }
.qw-n { font-size: 13px; }
.qw-total { font-weight: 700; font-variant-numeric: tabular-nums; }

/* Daily goals tile (Today) */
.dg-lead { margin: 0 0 8px; }
.dg-list { display: flex; flex-direction: column; gap: 10px; }
.dg-row { padding: 8px 10px; border-radius: 12px; background: rgba(127, 127, 127, .06); }
.dg-row.dg-done { background: rgba(46, 125, 50, .10); }
.dg-top { display: flex; align-items: baseline; gap: 8px; font-size: 15px; }
.dg-check { width: 18px; color: #2E7D32; font-weight: 800; }
.dg-label { font-weight: 700; flex: 1; }
.dg-num { font-variant-numeric: tabular-nums; font-weight: 700; }
.dg-bar { height: 6px; border-radius: 999px; background: rgba(127, 127, 127, .18); margin: 6px 0 0 26px; overflow: hidden; }
.dg-fill { height: 100%; background: #2E7D32; border-radius: 999px; transition: width .3s; }
.dg-hint { font-size: 12.5px; margin: 4px 0 0 26px; }
.dg-days { display: flex; align-items: center; gap: 5px; margin-top: 12px; flex-wrap: wrap; }
.dg-dot { width: 12px; height: 12px; border-radius: 50%; background: rgba(127, 127, 127, .25); display: inline-block; }
.dg-dot.dg-hit { background: #2E7D32; }
.dg-dot.dg-part { background: #F2B705; }
.dg-dot.dg-miss { background: rgba(127, 127, 127, .35); }
.dg-days-l { font-size: 12px; margin-left: 4px; }
/* Admin: daily goals table */
.dgm-ok { color: #2E7D32; font-weight: 700; }
.dgm-no { color: var(--muted); }

/* Tappable terms: dotted underline, opens a definition */
.term { text-decoration: underline dotted; text-underline-offset: 3px; text-decoration-color: rgba(127,127,127,.6); cursor: pointer; }
.term-title { margin: 0 0 10px; font-size: 20px; }
.term-body p { margin: 0 0 10px; font-size: 15px; line-height: 1.5; }
.term-body ul { margin: 0 0 10px 18px; padding: 0; font-size: 15px; line-height: 1.5; }

/* Your year so far (crew Pay page) */
.my-sec { border-top: 1px solid var(--border); }
.my-sec summary { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 0; cursor: pointer; font-size: 15px; list-style: none; }
.my-sec summary::-webkit-details-marker { display: none; }
.my-sec summary > span::before { content: "▸ "; color: var(--muted); }
.my-sec[open] summary > span::before { content: "▾ "; }
.my-list { padding: 0 0 10px 18px; }
.my-row { display: flex; justify-content: space-between; gap: 10px; padding: 4px 0; font-size: 13.5px; }
.my-sub { font-size: 12px; color: var(--muted); margin-top: 8px; text-transform: uppercase; letter-spacing: .04em; }
.my-total { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 12px 0 4px; border-top: 2px solid var(--border); font-size: 15px; }
.my-total b { font-size: 18px; }
.dg-note { background: rgba(242, 183, 5, .10); }
.dg-note-text { color: var(--text, inherit); font-size: 14px; line-height: 1.45; }
.nav2-intro { font-size: 13.5px; margin: 4px 2px 12px; }

/* Mission: an idea row collapsing out of the list */
.ms-item { transition: height .28s ease, opacity .22s ease, padding .28s ease, margin .28s ease; }
.ms-item.ms-leaving { height: 0 !important; padding-top: 0; padding-bottom: 0; opacity: 0; overflow: hidden; border-top-color: transparent; transition-delay: .12s, 0s, .12s, .12s; }
/* Mission → Today: the CWS card on a coaching-call day */
.ms-cws { border-color: rgba(22, 163, 74, .35); background: var(--green-soft); }
/* Mission inbox: temporary Undo pill at the bottom of the screen */
.ms-undo { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 16px); z-index: 160; display: flex; align-items: center; gap: 12px; padding: 8px 10px 8px 16px; border-radius: 999px; background: rgba(17, 24, 39, .92); color: #fff; font-size: 13px; box-shadow: 0 8px 24px rgba(0, 0, 0, .25); opacity: 0; pointer-events: none; transition: opacity .2s ease, transform .2s ease; max-width: calc(100vw - 32px); }
.ms-undo.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.ms-undo-btn { border: none; background: rgba(255, 255, 255, .14); color: #86efac; font: inherit; font-weight: 700; padding: 5px 12px; border-radius: 999px; cursor: pointer; }
.ms-undo-btn:hover { background: rgba(255, 255, 255, .22); }

.sr-map{margin:-4px 0 10px;font-size:13px}
.sr-map a{color:var(--brand,#1d4ed8);text-decoration:none}
.sr-map a:hover{text-decoration:underline}

/* ── Competencies (2026-10-22) ── */
.cp-status { font-size: 13px; font-weight: 700; margin-top: 5px; }
.cp-yes { color: var(--green-700); }
.cp-no { color: var(--muted); font-weight: 600; }
.cp-others { font-size: 12px; color: var(--soft); margin-top: 3px; }
/* ── Resources card (2026-10-22) ── */
.res-link { display: flex; align-items: center; gap: 12px; padding: 12px 10px; border: 1px solid var(--border); border-radius: 14px; text-decoration: none; color: var(--text); }
.res-link + .res-link { margin-top: 8px; }
.res-link:hover { background: rgba(0,0,0,.03); }
.res-ico { font-size: 22px; flex: 0 0 auto; }
.res-txt { display: flex; flex-direction: column; flex: 1 1 auto; min-width: 0; }
.res-txt b { font-size: 15px; }
.res-sub { font-size: 13px; color: var(--muted); line-height: 1.4; }
.res-arrow { color: var(--muted); font-size: 16px; flex: 0 0 auto; }
/* admin: competency grid */
.cp-grid td.cp-cell { text-align: center; }
.cp-grid input[type=checkbox] { width: 20px; height: 20px; accent-color: var(--green-700, #1B7F4D); cursor: pointer; }
.cp-grid th.cp-head { max-width: 120px; white-space: normal; }
.cp-add { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.cp-add input { flex: 1 1 180px; padding: 8px 10px; border: 1px solid var(--border); border-radius: 8px; font-size: 14px; }

/* Brand colors card (admin Setup) */
.brandc-company { font-size: 14px; font-weight: 700; margin: 14px 0 6px; }
.brandc-grid { display: grid; grid-template-columns: 28px max-content auto auto auto auto; justify-content: start; gap: 6px 14px; align-items: center; overflow-x: auto; }
.brandc-head { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted, #6b7280); }
.brandc-swatch { width: 26px; height: 26px; border-radius: 7px; border: 1px solid rgba(0,0,0,.12); }
.brandc-name { font-size: 14px; font-weight: 600; }
.brandc-val { font: inherit; font-size: 13px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; background: none; border: 1px solid transparent; border-radius: 6px; padding: 2px 6px; cursor: pointer; text-align: left; color: inherit; white-space: nowrap; }
.brandc-val:hover { border-color: rgba(0,0,0,.15); }
.brandc-val.on { color: var(--green-700, #15803d); font-weight: 700; }
@media (max-width: 640px) { .brandc-grid { grid-template-columns: 28px 1fr auto; } .brandc-grid .brandc-head:nth-child(n+4), .brandc-grid .brandc-val:not(:nth-of-type(4n+1)) { display: none; } }

/* empty selfie board (2026-10-22) */
.selfie-empty { font-size: 15px; font-weight: 600; color: var(--green-700); line-height: 1.5; margin: 4px 0 2px; }

/* tiny face before a first name in crew-wide tiles (2026-10-22) */
.avatar-xs { width: 22px; height: 22px; font-size: 9px; vertical-align: middle; }
.face-name { display: inline-flex; align-items: center; gap: 5px; vertical-align: middle; }
.rb-top { align-items: center; }

/* Add to Todd's follow-ups (admin, 2026-10-22) */
.afu-top label { font-size: 14px; display: inline-flex; flex-direction: row; gap: 8px; align-items: center; }
.afu-form { display: grid; gap: 8px; margin: 10px 0 14px; }
.afu-form input, .afu-form select, .afu-top select { font: inherit; font-size: 14px; padding: 8px 10px; border-radius: 8px; border: 1px solid var(--border); background: transparent; color: inherit; min-width: 0; }
.afu-form input[type="search"] { width: 100%; box-sizing: border-box; }
.afu-when { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.afu-when label { display: inline-flex; flex-direction: row; gap: 6px; align-items: center; font-size: 14px; }
.afu-hits { display: flex; flex-direction: column; gap: 4px; margin-top: 6px; }
.afu-hit { text-align: left; font: inherit; font-size: 13.5px; padding: 6px 10px; border: 1px solid var(--border); border-radius: 8px; background: var(--card-soft); cursor: pointer; color: inherit; }
.afu-hit:hover { border-color: var(--green-500); }
.afu-chip { display: inline-flex; gap: 6px; align-items: center; font-size: 13.5px; padding: 6px 10px; border-radius: 999px; background: var(--green-soft); color: var(--green-700); }
.afu-chip button { border: 0; background: none; cursor: pointer; font: inherit; color: inherit; }
.afu-none { margin: 6px 0 0; font-size: 13px; }
.afu-h3 { font-size: 15px; margin: 6px 0; }
.afu-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.afu-table th, .afu-table td { text-align: left; padding: 6px 8px; border-top: 1px solid var(--border); vertical-align: top; }
.afu-table th { font-size: 12px; color: var(--muted); border-top: 0; }
.afu-due td:nth-child(2) { color: #b45309; font-weight: 600; }
.afu-table .btn-ghost { padding: 4px 10px; font-size: 13px; }

/* ---------- hide a tile (2026-10-26) ---------- */
.tile-hide { margin-left: auto; padding-left: 10px; border: none; background: transparent; color: var(--muted); font: inherit; font-size: 12px; font-weight: 600; opacity: .55; cursor: pointer; white-space: nowrap; }
.tile-hide:hover { opacity: 1; }
.card.tile-hidden { padding: 8px 16px; }
.card.tile-hidden > :not(.tile-pill) { display: none !important; }
.tile-pill { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 10px; border: none; background: transparent; font: inherit; color: var(--muted); cursor: pointer; padding: 4px 0; text-align: left; }
.tile-pill-name { font-size: 14px; font-weight: 600; }
.tile-pill-show { font-size: 12px; font-weight: 700; color: var(--green-700); }
body.view-as .tile-hide { display: none; }

/* ---------- work hours grid (Farrell, 2026-10-26) ---------- */
.hg-nav { display: flex; align-items: center; gap: 6px; font-size: 14px; white-space: nowrap; }
.hg-nav .btn-ghost { padding: 2px 10px; font-size: 16px; }
.hg-table td { vertical-align: top; padding: 4px 6px; }
.hg-table .ct-name { position: sticky; left: 0; background: var(--card); }
.hg-table .hg-empty { color: var(--muted); text-align: center; }
.hg-table .hg-week { font-weight: 700; white-space: nowrap; }
.hg-cell { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; border: none; background: transparent; font: inherit; color: var(--text); cursor: pointer; padding: 2px 4px; border-radius: 8px; text-align: left; }
.hg-cell:hover { background: var(--green-soft); }
.hg-cell.hg-open .hg-span { color: var(--green-700); font-weight: 700; }
.hg-span { white-space: nowrap; font-size: 13.5px; }
.hg-hrs { font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.hg-detail-box { margin-top: 10px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 12px; }

/* ---------- Friday reminder (2026-10-26) ---------- */
.modal .friday-check { display: flex; flex-direction: row; align-items: center; justify-content: center; gap: 10px; font-size: 16px; font-weight: 600; margin: 6px 0 16px; cursor: pointer; }
.friday-check input { width: 22px; height: 22px; }
.friday-actions { display: flex; gap: 10px; }


/* People page: logins Supabase would refuse (unconfirmed email) */
.login-health { background: #fff7e6; border: 1px solid #f0c36d; border-radius: 10px; padding: 10px 12px; margin-bottom: 10px; }
.login-health-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }

.tflag-lane { font-size: 12px; max-width: 180px; text-align: right; }

/* Installer Today: the done box (green only when checklist + timer are done) */
.inst-check { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; margin-right: 8px; border: 2px solid #9ca3af; border-radius: 5px; background: #fff; color: #fff; font-size: 14px; font-weight: 800; line-height: 1; vertical-align: -4px; flex: none; }
.inst-check.on { background: #16a34a; border-color: #16a34a; }

/* face chips inside a small muted line (installer job rows, goal hints) */
.face-name-sm { gap: 4px; }
.face-name-sm .avatar-xs { width: 16px; height: 16px; font-size: 7px; }

/* Board time (selfie card) */
.bt-box { margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--border); }
.bt-head { font-weight: 700; margin-bottom: 2px; cursor: pointer; list-style: none; display: flex; align-items: center; justify-content: space-between; }
.bt-head::-webkit-details-marker { display: none; }
.bt-caret { color: var(--muted); font-size: 12px; transition: transform .15s; }
.bt-box[open] .bt-caret { transform: rotate(180deg); }
.bt-box[open] .bt-head { margin-bottom: 4px; }
.bt-sub { font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.bt-row { display: flex; align-items: center; gap: 8px; padding: 4px 0; }
.bt-rank { width: 18px; font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.bt-name { flex: 1; min-width: 0; }
.bt-time { font-variant-numeric: tabular-nums; font-weight: 600; }
.bt-live { color: #16a34a; }
.bt-rate { font-variant-numeric: tabular-nums; white-space: nowrap; }
.bt-rate small { color: var(--muted); font-size: 11px; }
.bt-unq { opacity: .55; }
.bt-time-sm { font-size: 12px; font-weight: 500; color: var(--muted); }
.bt-time-sm.bt-live { color: #16a34a; }
.bt-me { background: rgba(22,163,74,.07); border-radius: 8px; padding-left: 4px; padding-right: 4px; }
.bt-foot { font-size: 11px; color: var(--muted); margin-top: 6px; }

/* contest teaser on the selfie card */
.contest-line { background: #fff7db; border: 1px solid #f3d27a; color: #7a5a00; border-radius: 10px; padding: 8px 12px; margin-bottom: 10px; font-size: 13px; line-height: 1.35; }
.contest-line.on { background: #e9f8ee; border-color: #9fd9b4; color: #1d5f35; }
.contest-line.won { background: #fff7db; border-color: #e4b93c; font-weight: 600; }
.contest-line .face-name { vertical-align: -3px; }

.mt-sub { margin: 12px 0 2px; font-size: 14px; }

/* Admin sections: the body class owns visibility, so a loader cannot leak a card into another tab */
body.sec-cal [data-sec]:not([data-sec="cal"]) { display: none !important; }
body.sec-cap [data-sec]:not([data-sec="cap"]) { display: none !important; }
body.sec-funnel [data-sec]:not([data-sec="funnel"]) { display: none !important; }
body.sec-home [data-sec]:not([data-sec="home"]) { display: none !important; }
body.sec-log [data-sec]:not([data-sec="log"]) { display: none !important; }
body.sec-meeting [data-sec]:not([data-sec="meeting"]) { display: none !important; }
body.sec-mission [data-sec]:not([data-sec="mission"]) { display: none !important; }
body.sec-pay [data-sec]:not([data-sec="pay"]) { display: none !important; }
body.sec-people [data-sec]:not([data-sec="people"]) { display: none !important; }
body.sec-perf [data-sec]:not([data-sec="perf"]) { display: none !important; }
body.sec-profit [data-sec]:not([data-sec="profit"]) { display: none !important; }
body.sec-invoices [data-sec]:not([data-sec="invoices"]) { display: none !important; }
body.sec-materials [data-sec]:not([data-sec="materials"]) { display: none !important; }
body.sec-reviews [data-sec]:not([data-sec="reviews"]) { display: none !important; }
body.sec-quote [data-sec]:not([data-sec="quote"]) { display: none !important; }
body.sec-setup [data-sec]:not([data-sec="setup"]) { display: none !important; }
body.sec-start [data-sec]:not([data-sec="start"]) { display: none !important; }
body.sec-time [data-sec]:not([data-sec="time"]) { display: none !important; }

/* How far out are we booking? (Todd's lead-time card, 2026-10-28) */
.lt-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.lt-box{display:block;width:100%;text-align:left;border:1px solid var(--border,#e5e7eb);border-radius:12px;padding:10px 10px 8px;background:var(--card,#fff);color:inherit;font:inherit;cursor:pointer;min-width:0}
.lt-box.open{border-color:var(--brand,#1d4ed8);box-shadow:0 0 0 2px rgba(29,78,216,.15)}
.lt-label{font-size:12.5px;font-weight:600;opacity:.8;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.lt-date{font-size:17px;font-weight:700;margin-top:4px;line-height:1.2}
.lt-sub{font-size:12.5px;margin-top:2px;color:var(--brand,#1d4ed8);font-weight:600}
.lt-through{font-size:11.5px;margin-top:4px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.lt-days{margin-top:10px}
.lt-rule{font-size:12.5px;margin:0 0 8px}
.lt-day{padding:7px 0;border-top:1px solid var(--border,#e5e7eb)}
.lt-day.is-open{background:rgba(16,185,129,.06);margin:0 -6px;padding-left:6px;padding-right:6px;border-radius:6px}
.lt-day-top{display:flex;justify-content:space-between;align-items:center;gap:8px}
.lt-pill{font-size:11.5px;font-weight:600;padding:2px 8px;border-radius:999px;background:#f3f4f6;color:#6b7280}
.lt-pill.ok{background:rgba(16,185,129,.15);color:#047857}
.lt-pill.no{background:rgba(239,68,68,.1);color:#b91c1c}
.lt-day-sub{font-size:12.5px;margin-top:2px}

/* Job receipts (receipts.js, 2026-10-29) — reuses the rc-* ticket styles plus: */
.rr-lines-head, .rr-line { grid-template-columns: 2.4fr .8fr 1fr 28px; }
.rr-jobbox { display: flex; flex-direction: column; gap: 6px; }
.rr-jobbox > .adv-field { flex-direction: row; }
.rr-picked { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px; border: 1px solid var(--green-600); border-radius: 12px; background: var(--green-soft); font-size: 14px; font-weight: 600; }
.rr-picked .btn-ghost { padding: 4px 10px; font-size: 13px; flex: none; }
.rr-jobs { display: flex; flex-direction: column; gap: 6px; max-height: 260px; overflow-y: auto; margin-top: 6px; }
.rr-job { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; width: 100%; text-align: left; padding: 8px 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--card); font-family: inherit; font-size: 14px; cursor: pointer; }
.rr-job:active { background: var(--green-soft); }
.rr-job-sub { font-size: 12px; color: var(--muted); }
.rr-st { font-size: 11px; font-weight: 700; padding: 2px 7px; border-radius: 999px; margin-right: 4px; white-space: nowrap; }
.rr-ok { background: #DCFCE7; color: #166534; }
.rr-warn { background: #FEF3C7; color: #92400E; }
.rr-bad { background: #FEE2E2; color: #991B1B; }
.rr-err { background: #FEF2F2; border-color: #FECACA; }
.rr-posted-note { font-size: 13px; }
.rr-job-head { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; margin: 6px 0 0; }

/* Notices under the clock (reversed Coin charge etc.): read in place, ✕ clears */
#notice-strip { margin: -6px 0 14px; }
.notice { display: flex; align-items: flex-start; gap: 10px; background: #ECFDF5; border: 1px solid #A7F3D0;
  color: #065F46; border-radius: 14px; padding: 11px 12px 11px 14px; font-size: 14px; line-height: 1.4; margin-top: 8px; }
.notice-ico { flex: 0 0 auto; font-size: 17px; line-height: 1.2; }
.notice-text { flex: 1; min-width: 0; }
.notice-when { display: block; font-size: 12px; opacity: .7; margin-top: 3px; }
.notice-x { flex: 0 0 auto; background: transparent; border: none; color: #047857; font-size: 16px; line-height: 1;
  padding: 2px 6px; margin: -2px -4px 0 0; cursor: pointer; border-radius: 8px; }
.notice-x:hover { background: rgba(4,120,87,.12); }

/* ---- Pulse tiles (admin Home, 2026-10-30) ---- */
.pl-block { margin-bottom: 10px; }
.pl-sub { font-weight: 700; font-size: 14px; margin: 2px 0 8px; }
.pl-three { grid-template-columns: repeat(3, 1fr); }
.pl-four { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 640px) { .pl-four { grid-template-columns: repeat(2, 1fr); } }
.pl-svg { width: 100%; height: auto; display: block; margin: 6px 0 2px; }
.pl-bar { fill: var(--green-600); } .pl-bar-now { fill: var(--green-500); opacity: .85; }
.pl-bar-prior { fill: #94A3B8; }
.pl-goal { stroke: #EF6248; stroke-width: 2.5; }
.pl-grid { stroke: var(--border); stroke-width: 1; }
.pl-tick { font-size: 9.5px; fill: var(--muted); }
.pl-val { font-size: 10px; font-weight: 700; fill: #374151; }
.pl-pace { fill: none; stroke: #94A3B8; stroke-width: 2; stroke-dasharray: 6 4; }
.pl-actual { fill: none; stroke: var(--green-600); stroke-width: 3; stroke-linejoin: round; }
.pl-today { stroke: #EF6248; stroke-width: 1.5; stroke-dasharray: 2 2; }
.pl-dot { fill: var(--green-700); }
.pl-stack { position: relative; height: 14px; border-radius: 7px; background: #E5E7EB; overflow: hidden; display: flex; margin-top: 8px; }
.pl-stack-a { background: var(--green-600); } .pl-stack-s { background: #9BD3B4; }
.pl-foot { font-size: 12.5px; margin: 4px 0 0; }
.pl-key { display: inline-block; width: 10px; height: 10px; border-radius: 2px; vertical-align: -1px; }
.pl-key-prior { background: #94A3B8; } .pl-key-cur { background: var(--green-600); }
.pl-key-goal { background: #EF6248; height: 3px; width: 12px; vertical-align: 2px; }
.pl-key-pace { background: repeating-linear-gradient(90deg, #94A3B8 0 4px, transparent 4px 7px); height: 2px; width: 14px; vertical-align: 3px; }
.pl-key-today { background: #EF6248; width: 2px; height: 12px; }
.pl-up { color: var(--green-700); font-weight: 600; } .pl-down { color: #B91C1C; font-weight: 600; }
.pl-perday { font-size: 11.5px; margin-top: 3px; }
.pl-day { white-space: nowrap; font-variant-numeric: tabular-nums; min-width: 46px; }
.pl-note { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12.5px; }
.hm-pace { margin-top: 8px; }

/* Log filters: two loaf chips, slices after a divider (2026-10-30) */
.chips .chip-loaf { font-weight: 700; }
.chips .chip-slice { font-size: 12px; opacity: .9; }
.chip-sep { width: 1px; align-self: stretch; background: var(--border); margin: 0 2px; }

/* Crew calendar (Capacity tab) */
.cc-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; margin: 12px 0 10px; }
.cc-dow { font-size: 11px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); padding: 0 4px 2px; }
.cc-cell { border: 1px solid var(--border); border-radius: 12px; padding: 6px 6px 7px; background: #fff; min-height: 78px; display: flex; flex-direction: column; gap: 4px; }
.cc-cell.cc-pad { border: none; background: transparent; }
.cc-cell.cc-we, .cc-cell.cc-hol { background: var(--card-soft, #F8FAFC); }
.cc-cell.cc-past { opacity: .6; }
.cc-cell.cc-today { border-color: var(--green-600); box-shadow: 0 0 0 1px var(--green-600) inset; }
.cc-cell.cc-set { border-color: #2563EB; }
.cc-top { display: flex; align-items: center; gap: 4px; }
.cc-d { font-weight: 700; font-size: 13px; }
.cc-tag { font-size: 10px; color: var(--muted); }
.cc-reset { margin-left: auto; border: none; background: none; color: #2563EB; cursor: pointer; font-size: 13px; padding: 0 2px; }
.cc-ctl { display: flex; align-items: center; gap: 2px; }
.cc-btn { width: 24px; height: 26px; border-radius: 8px; border: 1px solid var(--border); background: #fff; cursor: pointer; font-size: 15px; line-height: 1; color: var(--text, #0F172A); }
.cc-btn:hover { border-color: var(--green-500); }
.cc-in { width: 100%; min-width: 0; text-align: center; font: inherit; font-weight: 800; font-size: 16px; border: none; background: transparent; -moz-appearance: textfield; }
.cc-in::-webkit-outer-spin-button, .cc-in::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.cc-off { font-size: 10.5px; color: #B45309; line-height: 1.25; }
@media (max-width: 720px) { .cc-grid { gap: 3px; } .cc-cell { padding: 4px; min-height: 64px; border-radius: 8px; } .cc-btn { width: 18px; height: 22px; font-size: 13px; } .cc-in { font-size: 14px; } .cc-off { display: none; } }
.hm-squote.hm-sub { border-top: 1px solid var(--border); margin-top: 4px; padding-top: 6px; }
.rr-multi { align-items: center; justify-content: space-between; }
.rr-multi .btn-ghost { padding: 4px 10px; font-size: 13px; }
