/*
  HRMS UI
  Palette: cool mineral canvas, ink navy, ledger teal for "go/present",
  amber for "waiting", rose for "problem", slate blue for "away".
  The signature element is the timecard strip: days rendered as punched cells.
*/
:root {
  --canvas: #eef2f1;
  --surface: #ffffff;
  --surface-2: #f6f8f8;
  --ink: #17242f;
  --ink-2: #2b3a46;
  --muted: #5b6b76;
  --faint: #8b989f;
  --line: #d6dedc;
  --line-2: #e6ecea;

  --teal: #0e6e62;
  --teal-soft: #dcefeb;
  --amber: #a86a12;
  --amber-soft: #f8ead2;
  --rose: #b4385a;
  --rose-soft: #f7dfe5;
  --blue: #335fa8;
  --blue-soft: #e0e8f6;
  --hol: #6d5aa8;
  --hol-soft: #ebe6f6;

  --radius-s: 6px;
  --radius: 10px;
  --radius-l: 14px;
  --sidebar: 236px;
  --font: "Public Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font: 15px/1.5 var(--font);
  font-feature-settings: "tnum" 1;
}
a { color: var(--teal); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { line-height: 1.2; margin: 0; font-weight: 650; letter-spacing: -0.01em; }
h1 { font-size: 1.75rem; }
h2 { font-size: 1.125rem; }
h3 { font-size: 1rem; }
p { margin: 0 0 0.75rem; }
small, .muted { color: var(--muted); }
.faint { color: var(--faint); }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--teal) 55%, transparent); outline-offset: 2px; border-radius: 4px; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* ---------- shell ---------- */
.shell { display: grid; grid-template-columns: var(--sidebar) 1fr; min-height: 100vh; }
.sidebar {
  background: var(--ink);
  color: #c9d4d9;
  padding: 22px 14px;
  box-sizing: border-box; min-height: 100vh;
  display: flex; flex-direction: column; gap: 22px;
}
/* Menu and page scroll separately: each has its own scroll bar (computer screens). */
@media (min-width: 901px) {
  .shell { height: 100vh; overflow: hidden; }
  .sidebar { height: 100vh; min-height: 0; overflow-y: auto; overscroll-behavior: contain;
             scrollbar-width: thin; scrollbar-color: #3a4d5a transparent; }
  .main { height: 100vh; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
}
.sidebar .nav { flex: none; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; font-weight: 700; padding: 0 8px; }
.brand-mark {
  width: 30px; height: 30px; border-radius: 8px;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; padding: 5px;
  background: #24384a;
}
.brand-mark i { background: #4fb8a8; border-radius: 1px; }
.brand-mark i:nth-child(2n) { background: #24384a; box-shadow: inset 0 0 0 1px #4fb8a8; }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav-group { font-size: 0.75rem; color: #7e919c; padding: 14px 10px 6px; }
.nav a {
  color: #c9d4d9; padding: 8px 10px; border-radius: var(--radius-s);
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
}
.nav a:hover { background: #22323f; color: #fff; text-decoration: none; }
.nav a.active { background: #26404a; color: #fff; box-shadow: inset 3px 0 0 #4fb8a8; }
.nav .count { background: #e4a43a; color: var(--ink); font-size: 0.75rem; font-weight: 700; border-radius: 99px; padding: 0 7px; }
.sidebar-foot { margin-top: auto; display: flex; gap: 10px; align-items: center; padding: 10px 8px 0; border-top: 1px solid #2a3b48; }
.sidebar-foot .who { min-width: 0; flex: 1; }
.sidebar-foot .who strong { color: #fff; display: block; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-foot .who a { color: #9fb1bb; font-size: 0.8125rem; }
.main { min-width: 0; padding: 28px 36px 60px; }
.page { max-width: 1240px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head p { margin: 6px 0 0; color: var(--muted); }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar { position: static; height: auto; min-height: 0; padding: 12px 16px; gap: 10px; }
  .nav { flex-direction: row; overflow-x: auto; gap: 4px; }
  .nav a { white-space: nowrap; }
  .nav-group { display: none; }
  .sidebar-foot { display: none; }
  .main { padding: 20px 16px 48px; }
}

/* ---------- surfaces ---------- */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-l); padding: 20px; }
.panel + .panel { margin-top: 16px; }
.panel-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 14px; }
.panel-head a { font-size: 0.875rem; }
.panel.flush { padding: 0; overflow: hidden; }
.panel.flush .panel-head { padding: 18px 20px 0; }
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-main { grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); align-items: start; }
@media (max-width: 1100px) { .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid-main { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }
.stack > * + * { margin-top: 16px; }

/* ---------- buttons & forms ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  font: inherit; font-weight: 600; font-size: 0.875rem;
  padding: 8px 14px; border-radius: var(--radius-s); border: 1px solid var(--line);
  background: var(--surface); color: var(--ink); cursor: pointer; text-decoration: none;
}
.btn:hover { background: var(--surface-2); text-decoration: none; }
.btn-primary { background: var(--teal); border-color: var(--teal); color: #fff; }
.btn-primary:hover { background: #0b5c52; }
.btn-danger { color: var(--rose); border-color: color-mix(in srgb, var(--rose) 40%, var(--line)); }
.btn-danger:hover { background: var(--rose-soft); }
.btn-quiet { border-color: transparent; background: transparent; color: var(--muted); }
.btn-sm { padding: 5px 10px; font-size: 0.8125rem; }
.btn-lg { padding: 12px 20px; font-size: 1rem; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }

.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 20px; }
.form-grid .wide { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.field label { display: block; font-weight: 600; font-size: 0.875rem; margin-bottom: 5px; }
.field .help { color: var(--muted); font-size: 0.8125rem; margin-top: 4px; }
.field .err, .errorlist { color: var(--rose); font-size: 0.8125rem; margin: 4px 0 0; padding: 0; list-style: none; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=datetime-local], input[type=url], input[type=search], input[type=tel],
input[type=number], select, textarea {
  width: 100%; font: inherit; color: var(--ink); background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius-s); padding: 8px 10px;
}
input:focus, select:focus, textarea:focus { border-color: var(--teal); outline: 2px solid var(--teal-soft); }
.check { display: flex; gap: 8px; align-items: flex-start; }
.check input { margin-top: 4px; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.filters input[type=search] { width: 260px; max-width: 100%; }
.filters select { width: auto; }
.segmented { display: inline-flex; border: 1px solid var(--line); border-radius: var(--radius-s); overflow: hidden; background: var(--surface); }
.segmented a, .segmented label { padding: 7px 12px; font-size: 0.875rem; color: var(--muted); cursor: pointer; }
.segmented a + a, .segmented label + label { border-left: 1px solid var(--line); }
.segmented a.on, .segmented input:checked + span { background: var(--ink); color: #fff; }
.segmented a:hover { text-decoration: none; background: var(--surface-2); }
.segmented a.on:hover { background: var(--ink); }

/* ---------- messages ---------- */
.flash { border-radius: var(--radius); padding: 11px 14px; margin-bottom: 16px; border: 1px solid; }
.flash.success { background: var(--teal-soft); border-color: #b5ddd5; color: #0b4f46; }
.flash.error { background: var(--rose-soft); border-color: #eebccb; color: #7d2440; }
.flash.info { background: var(--blue-soft); border-color: #c4d3ee; color: #1f3e72; }
.form-errors { background: var(--rose-soft); color: #7d2440; border-radius: var(--radius); padding: 10px 14px 10px 30px; margin: 0 0 16px; }

/* ---------- tables ---------- */
.table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.table th { text-align: left; font-weight: 600; color: var(--muted); font-size: 0.8125rem; padding: 10px 14px; border-bottom: 1px solid var(--line); background: var(--surface-2); white-space: nowrap; }
.table td { padding: 11px 14px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table tbody tr:hover td { background: #fafcfb; }
.table .num { text-align: right; }
.table-wrap { overflow-x: auto; }
.empty { text-align: center; color: var(--muted); padding: 32px 16px; }

/* ---------- people bits ---------- */
.avatar {
  --c: var(--teal);
  width: 34px; height: 34px; border-radius: 50%; flex: none;
  display: inline-grid; place-items: center; font-weight: 700; font-size: 0.8125rem;
  background: color-mix(in srgb, var(--c) 16%, white); color: var(--c);
}
.avatar.lg { width: 64px; height: 64px; font-size: 1.375rem; }
.avatar.sm { width: 26px; height: 26px; font-size: 0.6875rem; }
.person { display: flex; gap: 10px; align-items: center; min-width: 0; }
.person .name { font-weight: 600; color: var(--ink); display: block; }
.person .sub { color: var(--muted); font-size: 0.8125rem; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.person a.name:hover { color: var(--teal); }

.pill { display: inline-flex; align-items: center; gap: 5px; font-size: 0.75rem; font-weight: 600; padding: 2px 8px; border-radius: 99px; background: var(--surface-2); color: var(--muted); border: 1px solid var(--line-2); white-space: nowrap; }
.pill.pending, .pill.probation, .pill.late, .pill.incomplete { background: var(--amber-soft); color: var(--amber); border-color: transparent; }
.pill.approved, .pill.active, .pill.present { background: var(--teal-soft); color: var(--teal); border-color: transparent; }
.pill.rejected, .pill.absent, .pill.left { background: var(--rose-soft); color: var(--rose); border-color: transparent; }
.pill.cancelled { text-decoration: line-through; }
.pill.leave, .pill.half_leave, .pill.notice { background: var(--blue-soft); color: var(--blue); border-color: transparent; }
.pill.holiday { background: var(--hol-soft); color: var(--hol); border-color: transparent; }
.swatch { width: 10px; height: 10px; border-radius: 3px; display: inline-block; flex: none; }

.dl { display: grid; grid-template-columns: 150px 1fr; gap: 9px 16px; margin: 0; font-size: 0.9rem; }
.dl dt { color: var(--muted); }
.dl dd { margin: 0; }
@media (max-width: 520px) { .dl { grid-template-columns: 1fr; gap: 2px; } .dl dd { margin-bottom: 8px; } }

.list { list-style: none; margin: 0; padding: 0; }
.list > li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line-2); }
.list > li:first-child { border-top: 0; padding-top: 0; }
.list > li:last-child { padding-bottom: 0; }

/* ---------- dashboard: the punch clock ---------- */
.punch {
  background: var(--ink); color: #dfe8ec; border-radius: var(--radius-l);
  padding: 24px 26px; display: grid; grid-template-columns: 1fr auto; gap: 18px 28px; align-items: center;
  position: relative; overflow: hidden;
}
.punch::after {
  /* the perforated edge of a timecard */
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 8px;
  background: radial-gradient(circle at 6px 8px, var(--canvas) 3px, transparent 3.5px) 0 0 / 14px 8px repeat-x;
}
.punch .greeting { font-size: 0.9375rem; color: #9fb1bb; }
.punch .clock { font-size: clamp(2.5rem, 6vw, 3.75rem); font-weight: 300; color: #fff; letter-spacing: -0.03em; line-height: 1; margin: 6px 0 8px; }
.punch .clock small { font-size: 0.35em; color: #9fb1bb; letter-spacing: 0; font-weight: 500; margin-left: 6px; }
.punch .state { font-size: 0.9375rem; }
.punch .state strong { color: #fff; font-weight: 600; }
.punch form { display: flex; flex-direction: column; gap: 8px; align-items: stretch; min-width: 190px; }
.punch .btn-punch { background: #4fb8a8; border: 0; color: var(--ink); font-size: 1rem; font-weight: 700; padding: 13px 22px; border-radius: var(--radius); }
.punch .btn-punch:hover { background: #69c8b9; }
.punch .btn-punch.out { background: #e4a43a; }
.punch .btn-punch.out:hover { background: #efb655; }
.punch label { font-size: 0.8125rem; color: #9fb1bb; display: flex; gap: 6px; align-items: center; }
.punch .done { text-align: right; }
.punch .done strong { display: block; font-size: 1.75rem; color: #fff; font-weight: 400; }
@media (max-width: 640px) { .punch { grid-template-columns: 1fr; } .punch .done { text-align: left; } }

/* ---------- timecard strip (signature) ---------- */
.timecard { display: grid; grid-template-columns: repeat(var(--n, 30), minmax(0, 1fr)); gap: 3px; }
.tc {
  aspect-ratio: 1 / 1.35; border-radius: 3px; background: var(--surface-2);
  border: 1px solid var(--line-2); position: relative; min-width: 0;
}
.tc.present { background: var(--teal); border-color: var(--teal); }
.tc.late { background: var(--teal); border-color: var(--amber); box-shadow: inset 0 -5px 0 var(--amber); }
.tc.incomplete { background: linear-gradient(var(--teal) 50%, var(--surface-2) 50%); border-color: var(--teal); }
.tc.absent { background: var(--surface); border: 1.5px dashed var(--rose); }
.tc.leave { background: var(--blue); border-color: var(--blue); }
.tc.half_leave { background: linear-gradient(135deg, var(--blue) 50%, var(--teal-soft) 50%); border-color: var(--blue); }
.tc.holiday { background: var(--hol-soft); border-color: #cfc4ea; }
.tc.weekend { background: repeating-linear-gradient(-45deg, var(--surface-2) 0 3px, var(--line-2) 3px 5px); }
.tc.future, .tc.not_joined { background: transparent; border-style: dotted; }
.tc.is-today { outline: 2px solid var(--ink); outline-offset: 1px; }
.timecard-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 0.8125rem; color: var(--muted); margin-top: 12px; }
.timecard-legend span { display: inline-flex; gap: 6px; align-items: center; }
.timecard-legend .tc { width: 11px; aspect-ratio: auto; height: 14px; display: inline-block; }

/* ---------- stats ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 0; border: 1px solid var(--line); border-radius: var(--radius-l); background: var(--surface); overflow: hidden; }
.stat { padding: 14px 18px; border-left: 1px solid var(--line-2); }
.stat:first-child { border-left: 0; }
.stat b { display: block; font-size: 1.5rem; font-weight: 600; letter-spacing: -0.02em; }
.stat span { color: var(--muted); font-size: 0.8125rem; }

/* ---------- leave balance meters ---------- */
.balance { padding: 14px 0; border-top: 1px solid var(--line-2); }
.balance:first-child { border-top: 0; padding-top: 0; }
.balance-top { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.balance-top .left { font-size: 1.25rem; font-weight: 650; }
.balance-top .left small { font-size: 0.8125rem; font-weight: 500; }
.meter { height: 8px; border-radius: 99px; background: var(--line-2); overflow: hidden; display: flex; margin: 8px 0 6px; }
.meter i { display: block; height: 100%; }
.meter .used { background: var(--c, var(--teal)); }
.meter .pend { background: repeating-linear-gradient(-45deg, var(--c, var(--teal)) 0 3px, transparent 3px 6px); opacity: 0.55; }
.balance .meta { font-size: 0.8125rem; color: var(--muted); }
.balance-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; }
.balance-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; border-top: 4px solid var(--c, var(--teal)); }
.balance-card .big { font-size: 2rem; font-weight: 600; letter-spacing: -0.02em; line-height: 1.1; }
.balance-card .big small { font-size: 0.875rem; color: var(--muted); font-weight: 500; letter-spacing: 0; }

/* ---------- bars (headcount) ---------- */
.bars { display: grid; gap: 8px; }
.bar-row { display: grid; grid-template-columns: 130px 1fr 32px; gap: 10px; align-items: center; font-size: 0.875rem; }
.bar-row .track { height: 10px; background: var(--line-2); border-radius: 3px; overflow: hidden; }
.bar-row .track i { display: block; height: 100%; background: var(--ink-2); border-radius: 3px; }
.bar-row .n { text-align: right; font-weight: 600; }

/* ---------- calendars ---------- */
.cal-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius-l); background: var(--surface); }
.cal { border-collapse: separate; border-spacing: 0; font-size: 0.8125rem; min-width: 100%; }
.cal th, .cal td { border-bottom: 1px solid var(--line-2); text-align: center; padding: 0; }
.cal thead th { padding: 8px 0 6px; font-weight: 600; color: var(--muted); min-width: 30px; position: sticky; top: 0; background: var(--surface); }
.cal thead th .dow { display: block; font-weight: 500; font-size: 0.6875rem; color: var(--faint); }
.cal thead th.is-today { color: var(--teal); }
.cal thead th.is-today .num { background: var(--teal); color: #fff; border-radius: 99px; padding: 1px 6px; }
.cal .who { text-align: left; padding: 7px 14px; position: sticky; left: 0; background: var(--surface); z-index: 1; min-width: 210px; border-right: 1px solid var(--line-2); }
.cal td.day { height: 38px; position: relative; }
.cal td.wk { background: repeating-linear-gradient(-45deg, transparent 0 4px, var(--surface-2) 4px 7px); }
.cal td.hol { background: var(--hol-soft); }
.cal td.today { box-shadow: inset 1px 0 0 var(--teal), inset -1px 0 0 var(--teal); }
.cal .chip { position: absolute; inset: 8px 1px; border-radius: 4px; background: var(--c); opacity: 0.9; }
.cal .chip.half { inset: 8px 50% 8px 1px; }
.cal .chip.pm { inset: 8px 1px 8px 50%; }
.cal .tcell { display: block; margin: 5px auto; width: 18px; height: 24px; aspect-ratio: auto; }
.cal td.tot { font-weight: 600; padding: 0 12px; color: var(--muted); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 0.8125rem; color: var(--muted); margin-top: 12px; }
.legend span { display: inline-flex; gap: 6px; align-items: center; }

.month-nav { display: flex; align-items: center; gap: 6px; }
.month-nav h2 { min-width: 150px; text-align: center; font-size: 1.0625rem; }

/* personal month calendar */
.month { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.month .dow { font-size: 0.75rem; color: var(--muted); padding: 0 4px; }
.mday { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-s); min-height: 92px; padding: 7px 8px; font-size: 0.8125rem; display: flex; flex-direction: column; gap: 3px; border-top-width: 4px; }
.mday .d { font-weight: 650; color: var(--ink); }
.mday.weekend { background: var(--surface-2); border-top-color: var(--line); }
.mday.present { border-top-color: var(--teal); }
.mday.late { border-top-color: var(--amber); }
.mday.incomplete { border-top-color: var(--amber); }
.mday.absent { border-top-color: var(--rose); }
.mday.leave, .mday.half_leave { border-top-color: var(--blue); background: var(--blue-soft); }
.mday.holiday { border-top-color: var(--hol); background: var(--hol-soft); }
.mday.future, .mday.not_joined { background: transparent; border-style: dashed; border-top-width: 1px; }
.mday.is-today { box-shadow: 0 0 0 2px var(--ink); }
.mday .t { color: var(--ink-2); }
.mday .tag { color: var(--muted); font-size: 0.75rem; line-height: 1.3; }
@media (max-width: 720px) { .mday { min-height: 58px; padding: 4px; } .mday .t, .mday .tag { display: none; } }

/* ---------- org chart ---------- */
.org { overflow-x: auto; padding: 8px 4px 24px; }
.org ul { list-style: none; margin: 0; padding: 0 0 0 28px; position: relative; }
.org > ul { padding-left: 0; }
.org li { position: relative; padding: 6px 0 6px 0; }
.org ul ul > li::before { content: ""; position: absolute; left: -18px; top: 0; bottom: 0; border-left: 1.5px solid var(--line); }
.org ul ul > li:last-child::before { bottom: auto; height: 31px; }
.org ul ul > li::after { content: ""; position: absolute; left: -18px; top: 31px; width: 16px; border-top: 1.5px solid var(--line); }
.org-card {
  display: inline-flex; align-items: center; gap: 10px; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 8px 12px 8px 8px; min-width: 260px; max-width: 100%;
}
.org-card .meta { min-width: 0; flex: 1; }
.org-card .count { font-size: 0.75rem; color: var(--muted); background: var(--surface-2); border-radius: 99px; padding: 1px 8px; white-space: nowrap; }
.org details > summary { list-style: none; cursor: pointer; }
.org details > summary::-webkit-details-marker { display: none; }
.org details > summary .org-card { border-color: var(--ink-2); }
.org details[open] > summary .count::after { content: " open"; }
.org .flag { font-size: 0.6875rem; font-weight: 700; color: var(--muted); border: 1px solid var(--line); border-radius: 4px; padding: 0 4px; }

/* ---------- profile header ---------- */
.profile-head { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
.profile-head h1 { font-size: 1.625rem; }
.crumbs { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; font-size: 0.8125rem; color: var(--muted); margin-top: 6px; }
.crumbs .sep { color: var(--faint); }

/* ---------- auth ---------- */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; }
.auth-side { background: var(--ink); color: #c9d4d9; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; }
.auth-side h1 { color: #fff; font-size: 2.25rem; font-weight: 400; max-width: 16ch; }
.auth-side .timecard { max-width: 420px; --n: 14; }
.auth-side .tc { border-color: #2a3b48; background: #1f2f3c; }
.auth-side .tc.present { background: #4fb8a8; border-color: #4fb8a8; }
.auth-side .tc.leave { background: #6f93d6; border-color: #6f93d6; }
.auth-side .tc.weekend { background: repeating-linear-gradient(-45deg, #1f2f3c 0 3px, #2a3b48 3px 5px); }
.auth-main { display: grid; place-items: center; padding: 32px 20px; }
.auth-card { width: 100%; max-width: 360px; }
.auth-card h2 { font-size: 1.5rem; margin-bottom: 6px; }
.demo-logins { margin-top: 28px; font-size: 0.8125rem; color: var(--muted); border-top: 1px solid var(--line); padding-top: 16px; }
.demo-logins button { font: inherit; background: none; border: 0; color: var(--teal); cursor: pointer; padding: 0; }
.demo-logins li { margin: 4px 0; }
@media (max-width: 820px) { .auth { grid-template-columns: 1fr; } .auth-side { padding: 28px 20px; gap: 24px; } .auth-side h1 { font-size: 1.625rem; } }

.preview-box { border-radius: var(--radius); padding: 12px 14px; background: var(--surface-2); border: 1px solid var(--line); font-size: 0.9rem; }
.preview-box .n { font-size: 1.5rem; font-weight: 650; }
.preview-box.bad { background: var(--rose-soft); border-color: #eebccb; }
.preview-box ul { margin: 6px 0 0; padding-left: 18px; }
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { position: relative; padding: 0 0 14px 20px; font-size: 0.875rem; }
.timeline li::before { content: ""; position: absolute; left: 4px; top: 6px; width: 8px; height: 8px; border-radius: 50%; background: var(--line); }
.timeline li::after { content: ""; position: absolute; left: 7.5px; top: 16px; bottom: 0; border-left: 1px solid var(--line); }
.timeline li:last-child::after { display: none; }
.timeline li.approved::before { background: var(--teal); }
.timeline li.rejected::before { background: var(--rose); }
.timeline li.submitted::before { background: var(--amber); }
.pagination { display: flex; gap: 6px; justify-content: flex-end; align-items: center; padding: 12px 16px; font-size: 0.875rem; }
.hide-sm { }
@media (max-width: 720px) { .hide-sm { display: none; } }

/* ---------- assets ---------- */
.pill.available { background: var(--teal-soft); color: var(--teal); border-color: transparent; }
.pill.assigned { background: var(--blue-soft); color: var(--blue); border-color: transparent; }
.pill.repair, .pill.unverified, .pill.expiring { background: var(--amber-soft); color: var(--amber); border-color: transparent; }
.pill.lost, .pill.expired { background: var(--rose-soft); color: var(--rose); border-color: transparent; }
.pill.retired { background: var(--surface-2); color: var(--faint); }
.tag { font-weight: 650; font-variant-numeric: tabular-nums; color: var(--ink); letter-spacing: 0.01em; }
.asset-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.asset-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; color: var(--ink); }
.asset-card:hover { border-color: var(--ink-2); text-decoration: none; }
.asset-card .top { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.asset-card .name { font-weight: 600; font-size: 1rem; }
.asset-card .meta { color: var(--muted); font-size: 0.8125rem; }
.notice { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; border-radius: var(--radius); padding: 11px 14px; margin-bottom: 12px; background: var(--amber-soft); color: #6d4710; }
.notice.rose { background: var(--rose-soft); color: #7d2440; }
.tabs-inline { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 720px) { .tabs-inline { grid-template-columns: 1fr; } }

/* ---------- client assignments ---------- */
.pill.current { background: var(--teal-soft); color: var(--teal); border-color: transparent; }
.pill.upcoming { background: var(--blue-soft); color: var(--blue); border-color: transparent; }
.pill.ended { background: var(--surface-2); color: var(--faint); }
.pill.ending { background: var(--amber-soft); color: var(--amber); border-color: transparent; }
.engagement { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--teal); border-radius: var(--radius); padding: 16px 18px; }
.engagement.upcoming { border-left-color: var(--blue); }
.engagement.ended { border-left-color: var(--line); background: var(--surface-2); }
.engagement + .engagement { margin-top: 12px; }
.engagement-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.engagement-head h2 { font-size: 1.25rem; }
.engagement-head .when { color: var(--muted); font-size: 0.875rem; margin-top: 3px; }
.contacts { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; margin: 12px 0 4px; }
.contact { background: var(--surface-2); border-radius: var(--radius-s); padding: 10px 12px; font-size: 0.875rem; }
.contact .role { color: var(--muted); font-size: 0.8125rem; display: block; }
.contact .who { font-weight: 600; display: block; }
.change-list { list-style: none; margin: 0; padding: 0; font-size: 0.875rem; }
.change-list li { padding: 10px 0; border-top: 1px solid var(--line-2); }
.change-list li:first-child { border-top: 0; padding-top: 0; }
.change-list .diff { white-space: pre-line; color: var(--ink-2); margin-top: 4px; }
.fieldset-title { grid-column: 1 / -1; font-weight: 650; margin: 8px 0 -6px; padding-top: 12px; border-top: 1px solid var(--line-2); }
.fieldset-title:first-child { border-top: 0; padding-top: 0; margin-top: 0; }

/* ---------- claims ---------- */
.pill.draft { background: var(--surface-2); color: var(--muted); }
.pill.submitted { background: var(--amber-soft); color: var(--amber); border-color: transparent; }
.pill.paid { background: var(--ink); color: #fff; border-color: transparent; }
.money { font-variant-numeric: tabular-nums; white-space: nowrap; }
.claim-total { display: flex; justify-content: space-between; align-items: baseline; padding: 14px 20px; border-top: 1px solid var(--line); background: var(--surface-2); font-weight: 650; }
.claim-total .money { font-size: 1.375rem; }
.item-form { display: grid; grid-template-columns: 1.2fr 0.9fr 2fr 0.8fr 0.9fr; gap: 12px; align-items: end; }
.item-form .full { grid-column: 1 / -1; }
@media (max-width: 900px) { .item-form { grid-template-columns: 1fr 1fr; } .item-form .desc { grid-column: 1 / -1; } }
.warn-list { margin: 0 0 14px; padding: 10px 14px 10px 30px; border-radius: var(--radius); background: var(--amber-soft); color: #6d4710; font-size: 0.9rem; }
.step-row { display: flex; gap: 6px; flex-wrap: wrap; font-size: 0.8125rem; color: var(--muted); margin-top: 8px; }
.step-row span { padding: 2px 10px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); }
.step-row span.done { background: var(--teal-soft); border-color: transparent; color: var(--teal); font-weight: 600; }
.step-row span.now { background: var(--ink); color: #fff; border-color: var(--ink); font-weight: 600; }
.step-row span.skipped { opacity: .5; text-decoration: line-through; }   /* CR-095: no interview held */

/* ---------- My Claim: its own app shell ---------- */
.claim-app { --accent: #9a5b13; --accent-soft: #f6ead8; min-height: 100vh; display: flex; flex-direction: column; }
.claim-top { background: #2a1e12; color: #e8d9c6; }
.claim-top-inner { max-width: 1180px; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; gap: 24px; min-height: 64px; flex-wrap: wrap; }
.claim-brand { display: flex; align-items: center; gap: 10px; color: #fff; font-weight: 700; text-decoration: none; }
.claim-brand:hover { text-decoration: none; }
.claim-brand .mark { width: 32px; height: 32px; border-radius: 9px; background: #d98a2b; color: #2a1e12; display: grid; place-items: center; font-weight: 800; font-size: 0.8125rem; }
.claim-nav { display: flex; gap: 4px; flex-wrap: wrap; flex: 1; }
.claim-nav a { color: #e8d9c6; padding: 8px 12px; border-radius: 8px; display: inline-flex; gap: 8px; align-items: center; }
.claim-nav a:hover { background: #3b2c1c; color: #fff; text-decoration: none; }
.claim-nav a.active { background: #4a3721; color: #fff; }
.claim-nav .count { background: #d98a2b; color: #2a1e12; font-size: 0.75rem; font-weight: 700; border-radius: 99px; padding: 0 7px; }
.claim-who { display: flex; align-items: center; gap: 12px; font-size: 0.875rem; }
.claim-who a, .claim-who button { color: #c9b39a; background: none; border: 0; padding: 0; font: inherit; cursor: pointer; }
.claim-main { width: 100%; max-width: 1180px; margin: 0 auto; padding: 28px 24px 60px; box-sizing: border-box; flex: 1; }
.claim-app .btn-primary { background: var(--accent); border-color: var(--accent); }
.claim-app .btn-primary:hover { background: #7f4a0f; }
.claim-app a { color: var(--accent); }
.claim-app .claim-nav a, .claim-app .claim-brand { color: #e8d9c6; }
.claim-app .claim-brand { color: #fff; }
@media (max-width: 720px) { .claim-top-inner { padding: 8px 16px; gap: 8px; } .claim-main { padding: 20px 16px 48px; } .claim-who .name { display: none; } }

/* ---------- landing page (app launcher) ---------- */
.launcher { min-height: 100vh; display: flex; flex-direction: column; }
.launcher-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding: 18px 32px; background: var(--ink); color: #c9d4d9; }
.launcher-top .who { display: flex; align-items: center; gap: 12px; font-size: 0.9rem; }
.launcher-top .who .pw-link { color: #9fb1bb; text-decoration: underline; }
.launcher-top .who button { background: none; border: 0; padding: 0; color: #9fb1bb; font: inherit; cursor: pointer; text-decoration: underline; }
.launcher-main { flex: 1; width: 100%; max-width: 1120px; margin: 0 auto; padding: 56px 20px 64px; box-sizing: border-box; }
.launcher-main h1 { font-size: clamp(1.75rem, 4vw, 2.5rem); font-weight: 500; letter-spacing: -0.02em; }
.launcher-main .sub { color: var(--muted); margin: 8px 0 32px; }
.app-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.app-tile { --tile: var(--teal); display: flex; flex-direction: column; gap: 14px; min-height: 270px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 26px; box-sizing: border-box; color: var(--ink); text-decoration: none; transition: border-color .15s, transform .15s; }
.app-tile:hover { text-decoration: none; border-color: var(--tile); transform: translateY(-2px); }
.app-tile:focus-visible { outline: 3px solid var(--tile); outline-offset: 3px; }
.app-tile.claim { --tile: #9a5b13; }
.app-tile.pms { --tile: #3a4fa0; }
.app-tile .mark { width: 52px; height: 52px; border-radius: 13px; display: grid; place-items: center; font-weight: 800; font-size: 1rem; color: #fff; background: var(--tile); }
.app-tile h2 { font-size: 1.5rem; font-weight: 650; }
.app-tile .desc { color: var(--muted); margin: 4px 0 0; }
.app-tile .facts { display: flex; flex-wrap: wrap; gap: 8px; }
.app-tile .open { margin-top: auto; font-weight: 650; color: var(--tile); }
@media (max-width: 720px) { .launcher-top { padding: 14px 16px; } .launcher-main { padding-top: 32px; } }
@media (prefers-reduced-motion: reduce) { .app-tile { transition: none; } .app-tile:hover { transform: none; } }

/* ---------- PMS (recruitment) ---------- */
.pms-app { --accent: #3a4fa0; --accent-soft: #e6e9f6; min-height: 100vh; display: flex; flex-direction: column; }
.pms-top { background: #161c33; color: #cfd5ea; }
.pms-top-inner { max-width: 1240px; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; gap: 24px; min-height: 64px; flex-wrap: wrap; }
.pms-brand { display: flex; align-items: center; gap: 10px; color: #fff; font-weight: 700; }
.pms-brand:hover { text-decoration: none; }
.pms-brand .mark { width: 32px; height: 32px; border-radius: 9px; background: #7d8fe0; color: #161c33; display: grid; place-items: center; font-weight: 800; font-size: 0.75rem; }
.pms-nav { display: flex; gap: 4px; flex-wrap: wrap; flex: 1; }
.pms-app .pms-nav a { color: #cfd5ea; padding: 8px 12px; border-radius: 8px; }
.pms-app .pms-nav a:hover { background: #232b4a; color: #fff; text-decoration: none; }
.pms-app .pms-nav a.active { background: #2e3863; color: #fff; }
.pms-who { display: flex; align-items: center; gap: 12px; font-size: 0.875rem; }
.pms-app .pms-who a, .pms-who button { color: #a9b2d4; background: none; border: 0; padding: 0; font: inherit; cursor: pointer; }
.pms-who .lvl { background: #2e3863; color: #fff; border-radius: 99px; padding: 2px 10px; font-size: 0.75rem; font-weight: 600; }
.pms-main { width: 100%; max-width: 1240px; margin: 0 auto; padding: 28px 24px 60px; box-sizing: border-box; flex: 1; }
.pms-app .btn-primary { background: var(--accent); border-color: var(--accent); }
.pms-app .btn-primary:hover { background: #2d3f85; }
.pms-app a { color: var(--accent); }
.pms-app a.btn-primary { color: #fff; }
.pms-app a.btn:not(.btn-primary) { color: var(--ink); }
.status-form select, .status-form input[type=date] { width: auto; }
.pms-app .pms-brand { color: #fff; }
.pill.st-PENDING_SUBMISSION { background: var(--surface-2); color: var(--muted); }
.pill.st-SUBMITTED, .pill.st-IN_PROCESS { background: var(--blue-soft); color: var(--blue); border-color: transparent; }
.pill.st-PROPOSED { background: var(--accent-soft, #e6e9f6); color: #3a4fa0; border-color: transparent; }
.pill.st-INTERVIEW { background: #fdf0dc; color: #9a5b00; border-color: transparent; }   /* CR-095 */
.pill.st-SELECTED { background: var(--teal-soft); color: var(--teal); border-color: transparent; }
.pill.st-JOINED { background: var(--teal); color: #fff; border-color: transparent; }
.pill.st-ROLE_HOLD { background: var(--amber-soft); color: var(--amber); border-color: transparent; }
.pill.st-ROLE_CLOSED { background: var(--surface-2); color: var(--faint); }
.pill.st-REJECTED_CLIENT, .pill.st-REJECTED_INTERNAL, .pill.st-DROPPED_CLIENT, .pill.st-DROPPED_INTERNAL { background: var(--rose-soft); color: var(--rose); border-color: transparent; }
.pill.prio-High { background: var(--rose-soft); color: var(--rose); border-color: transparent; }
.pill.prio-Medium { background: var(--amber-soft); color: var(--amber); border-color: transparent; }
.funnel { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); border: 1px solid var(--line); border-radius: var(--radius-l); background: var(--surface); overflow: hidden; }
.funnel > div { padding: 14px 18px; border-left: 1px solid var(--line-2); }
.funnel > div:first-child { border-left: 0; }
.funnel b { display: block; font-size: 1.625rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.funnel span { color: var(--muted); font-size: 0.8125rem; }
.funnel .rate { display: block; font-size: 0.75rem; color: var(--faint); margin-top: 2px; }
.tree-row td:first-child { padding-left: calc(14px + var(--d, 0) * 26px); }
.tree-row .branch { color: var(--faint); margin-right: 6px; }
.tree-row.off { opacity: .55; }
.lvl-pill { font-size: 0.75rem; font-weight: 600; border-radius: 99px; padding: 2px 9px; background: var(--surface-2); color: var(--muted); }
.lvl-pill.head { background: #161c33; color: #fff; }
.lvl-pill.lead { background: var(--accent-soft, #e6e9f6); color: #3a4fa0; }
.dup-box { border: 1px solid #e7c98f; background: var(--amber-soft); border-radius: var(--radius); padding: 12px 14px; font-size: 0.875rem; }
.dup-box h3 { font-size: 0.9375rem; margin: 0 0 6px; }
.dup-box ul { margin: 0; padding-left: 18px; }
.dup-ok { color: var(--teal); font-size: 0.8125rem; }
.check-list ul, .check-list > div { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 6px 14px; }
.check-list label { font-weight: 400 !important; display: flex !important; gap: 8px; align-items: center; }
.bar-cell { display: flex; align-items: center; gap: 8px; }
.bar-cell i { display: block; height: 8px; border-radius: 99px; background: var(--accent, #3a4fa0); min-width: 2px; }
@media (max-width: 900px) { .funnel { grid-auto-flow: row; grid-template-columns: repeat(3, minmax(0, 1fr)); } .funnel > div:nth-child(4) { border-left: 0; } .funnel > div:nth-child(n+4) { border-top: 1px solid var(--line-2); } }
@media (max-width: 720px) { .pms-top-inner { padding: 8px 16px; gap: 8px; } .pms-main { padding: 20px 16px 48px; } .pms-who .name { display: none; } }

/* ---------- CRM (sales) ---------- */
.crm-app { --accent: #7a3b78; --accent-soft: #f3e6f2; }
.crm-app .pms-top { background: #2a1429; }
.crm-app .pms-brand .mark { background: #d79bd3; color: #2a1429; }
.crm-app .pms-nav a:hover { background: #3d203b; }
.crm-app .pms-nav a.active, .crm-app .pms-who .lvl { background: #52294f; }
.crm-app .btn-primary:hover { background: #622e60; }
.app-tile.crm { --tile: #7a3b78; }
.board { display: grid; grid-template-columns: repeat(4, minmax(220px, 1fr)); gap: 12px; overflow-x: auto; padding-bottom: 6px; }
.board-col { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-l); padding: 12px; min-height: 200px; }
.board-col h2 { font-size: 0.9375rem; margin: 0 0 2px; display: flex; justify-content: space-between; }
.board-col .sum { font-size: 0.8125rem; color: var(--muted); margin-bottom: 10px; }
.deal { display: block; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 12px; margin-bottom: 8px; color: var(--ink); }
.crm-app a.deal { color: var(--ink); }
.deal:hover { border-color: var(--accent); text-decoration: none; }
.deal b { display: block; font-weight: 600; font-size: 0.875rem; }
.deal .meta { font-size: 0.8125rem; color: var(--muted); display: flex; justify-content: space-between; gap: 8px; margin-top: 4px; }
.deal .late { color: var(--rose); }
.pill.st-lead { background: var(--surface-2); color: var(--muted); }
.pill.st-qualified { background: var(--blue-soft); color: var(--blue); border-color: transparent; }
.pill.st-proposal { background: var(--accent-soft, #f3e6f2); color: #7a3b78; border-color: transparent; }
.pill.st-negotiation { background: var(--amber-soft); color: var(--amber); border-color: transparent; }
.pill.st-won { background: var(--teal); color: #fff; border-color: transparent; }
.pill.st-lost { background: var(--rose-soft); color: var(--rose); border-color: transparent; }
.act-kind { font-size: 0.6875rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.inline-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 14px; }
.inline-form .full { grid-column: 1 / -1; }
.contact-row { display: flex; justify-content: space-between; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line-2); font-size: 0.875rem; }
.contact-row:first-child { border-top: 0; }
@media (max-width: 900px) { .board { grid-template-columns: repeat(4, 240px); } }
@media (max-width: 720px) { .inline-form { grid-template-columns: 1fr; } }

/* ---------- MindPec branding ---------- */
.brand-icon { width: 30px; height: 30px; object-fit: contain; flex: none; }
.auth-logo { display: block; width: 216px; max-width: 100%; height: auto; margin-bottom: 26px; }
.launcher-top { background: var(--surface); color: var(--ink); border-bottom: 1px solid var(--line); }
.launcher-top .who button, .launcher-top .who .pw-link { color: var(--muted); }
.launcher-logo { display: block; height: 44px; width: auto; }

/* ---------- footer ---------- */
.site-footer { text-align: center; font-size: 0.8125rem; color: var(--muted); padding: 18px 16px 22px; }
.main { display: flex; flex-direction: column; min-height: 100vh; box-sizing: border-box; padding-bottom: 0; }
.main > .page { flex: 1; width: 100%; padding-bottom: 40px; }
.auth-main { grid-template-rows: 1fr auto; }
.auth-main .site-footer { padding-bottom: 0; }

/* faint illustrations on the landing-page tiles */
.app-tile { position: relative; overflow: hidden; }
.app-tile > :not(.tile-art) { position: relative; z-index: 1; }
.tile-art { position: absolute; right: -6px; bottom: -8px; width: 190px; height: auto; opacity: 0.13;
            pointer-events: none; transition: opacity .2s, transform .2s; }
.app-tile:hover .tile-art { opacity: 0.2; transform: translateY(-3px); }
@media (prefers-reduced-motion: reduce) { .tile-art { transition: none; } .app-tile:hover .tile-art { transform: none; } }
@media (max-width: 720px) { .tile-art { width: 140px; } }

/* sign-in page: the apps behind this sign-in */
.portal-apps { margin: 0; color: #e8edf0; font-weight: 600; font-size: .9375rem; letter-spacing: .01em; }
.portal-apps span { display: block; color: #8fa3ae; font-weight: 400; font-size: .8125rem; margin-top: 3px; }

/* ---------- public careers form ---------- */
.careers { --accent: #f47a20; min-height: 100vh; display: flex; flex-direction: column; background: #fbf7f2; }
.careers-top { background: #fff; border-bottom: 1px solid #ece7e1; }
.careers-inner { max-width: 880px; margin: 0 auto; padding: 14px 20px; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.careers-logo img { display: block; height: 44px; width: auto; }
.careers-back { font-weight: 600; color: #8a3405; }
.careers-main { flex: 1; width: 100%; max-width: 880px; margin: 0 auto; padding: 40px 20px 56px; box-sizing: border-box; }
.careers-intro h1 { font-size: clamp(1.75rem, 4vw, 2.5rem); font-weight: 700; letter-spacing: -0.01em; margin: 4px 0 10px; }
.careers .eyebrow { margin: 0; font-size: .8125rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #b4470a; }
.careers .lead { color: #3d4b57; font-size: 1.0625rem; max-width: 60ch; margin: 0 0 26px; }
.careers .applying { margin: 0 0 8px; font-size: 1.0625rem; }
.careers-form { background: #fff; border: 1px solid #ece7e1; border-radius: 18px; padding: 28px; display: flex; flex-direction: column; gap: 22px; }
.careers-form fieldset { border: 0; padding: 0; margin: 0; }
.careers-form legend { font-weight: 700; font-size: 1.0625rem; margin-bottom: 12px; }
.careers-submit { background: #f47a20; border-color: #f47a20; color: #13202c; font-weight: 700; align-self: flex-start; }
.careers-submit:hover { background: #e2680f; border-color: #e2680f; }
.careers .hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.careers .check input { width: 18px; height: 18px; margin-top: 3px; flex: none; }
@media (max-width: 720px) { .careers-form { padding: 20px; } .careers-form .form-grid { grid-template-columns: 1fr; } }

/* ---------- My Tasks ---------- */
.task-app { --accent: #1f6f8b; --accent-soft: #e2f0f5; }
.task-app .pms-top { background: #0f2a35; }
.task-app .pms-brand .mark { background: #7cc3da; color: #0f2a35; }
.task-app .pms-nav a:hover { background: #17404f; }
.task-app .pms-nav a.active { background: #1e5266; }
.task-app .pms-nav .count { background: #f0b74a; color: #2a1e00; font-size: .75rem; font-weight: 700; border-radius: 99px; padding: 0 7px; margin-left: 6px; }
.task-app .btn-primary:hover { background: #185a71; }
.app-tile.tasks { --tile: #1f6f8b; }
.tperson { display: inline-flex; align-items: center; gap: 7px; }
.tperson .avatar.sm { width: 24px; height: 24px; font-size: .625rem; }
.pill.ts-raised, .pill.ts-reassigned { background: var(--amber-soft); color: var(--amber); border-color: transparent; }
.pill.ts-accepted { background: var(--blue-soft); color: var(--blue); border-color: transparent; }
.pill.ts-in_progress { background: #e2f0f5; color: #1f6f8b; border-color: transparent; }
.pill.ts-completed { background: var(--teal-soft); color: var(--teal); border-color: transparent; }
.pill.ts-rejected { background: var(--rose-soft); color: var(--rose); border-color: transparent; }
.overdue { color: var(--rose); font-weight: 600; }
.prio-high { color: var(--amber); font-weight: 600; }
.prio-urgent { color: var(--rose); font-weight: 700; }

/* ---------- My Timesheet ---------- */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.ts-app { --accent: #3f7d3a; --accent-soft: #e6f1e4; }
.ts-app .pms-top { background: #16281a; }
.ts-app .pms-brand .mark { background: #9fd29a; color: #16281a; }
.ts-app .pms-nav a:hover { background: #22402a; }
.ts-app .pms-nav a.active { background: #2c5336; }
.ts-app .pms-nav .count { background: #f0b74a; color: #2a1e00; font-size: .75rem; font-weight: 700; border-radius: 99px; padding: 0 7px; margin-left: 6px; }
.ts-app .btn-primary:hover { background: #33672f; }
.app-tile.timesheet { --tile: #3f7d3a; }
.ts-grid th span { display: block; font-weight: 400; font-size: .75rem; color: var(--muted); }
.ts-grid th.off, .ts-grid td.off { background: var(--surface-2); }
.ts-grid td, .ts-grid th { padding-left: 8px; padding-right: 8px; }
.ts-grid .ts-what { min-width: 320px; }
.ts-what-inner { display: flex; gap: 6px; flex-wrap: wrap; }
.ts-what-inner select { width: auto; min-width: 130px; }
.ts-what-inner input[type=text] { flex: 1; min-width: 140px; }
.ts-grid input.hrs { width: 64px; text-align: right; padding: 7px 6px; }
.ts-grid tr.removed { opacity: .4; }
.ts-grid tr.removed input.hrs { text-decoration: line-through; }
.ts-leave td { font-size: .875rem; color: var(--blue); }
.ts-leave .lv, .ts-leave .hol { display: block; font-size: .6875rem; color: var(--muted); }
.ts-leave .hol { color: var(--hol, #8a4f2a); }
.ts-total th, .ts-total td { font-weight: 700; border-top: 2px solid var(--line); }
.ts-total td.long { color: var(--rose); }
.ts-del { cursor: pointer; color: var(--muted); display: inline-flex; align-items: center; gap: 4px; font-size: .875rem; }
.ts-del input { width: 16px; height: 16px; }
.pill.tss-draft { background: var(--surface-2); color: var(--muted); }
.pill.tss-submitted { background: var(--amber-soft); color: var(--amber); border-color: transparent; }
.pill.tss-approved { background: var(--teal-soft); color: var(--teal); border-color: transparent; }
.pill.tss-returned { background: var(--rose-soft); color: var(--rose); border-color: transparent; }
.notice.rose { background: var(--rose-soft); color: #7d2440; }
.ts-leave td:first-child { color: var(--ink); }
.ts-total th { background: transparent; }
.ts-grid thead th.off { background: var(--surface-2); }

/* CR-003: copy of the timesheet to the client manager */
.ts-client { display: flex; gap: 16px 24px; align-items: flex-start; flex-wrap: wrap; margin-bottom: 12px; }
.ts-client .check { font-weight: 600; padding-top: 30px; white-space: nowrap; }
.ts-client .field { flex: 1; min-width: 260px; margin: 0; }
.ts-client .field small { display: block; margin-top: 4px; font-size: .8125rem; }
.ts-client input:disabled { opacity: .55; }
.ts-client-line { margin: 14px 0 0; }

/* CR-004: My pass */
.pass-card { display: flex; justify-content: space-between; gap: 16px; padding: 16px 20px 18px; border-top: 1px solid var(--line, #e6ebe9); border-left: 4px solid var(--teal); }
.pass-card.soon { border-left-color: var(--amber); }
.pass-card.expired { border-left-color: var(--rose); }
.pass-type { font-weight: 700; font-size: 1.05rem; margin-bottom: 10px; }
.pass-main { flex: 1; min-width: 0; }
.pass-side { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.pill.exp-ok { background: var(--teal-soft); color: var(--teal); border-color: transparent; }
.pill.exp-soon { background: var(--amber-soft); color: var(--amber); border-color: transparent; }
.pill.exp-expired { background: var(--rose-soft); color: var(--rose); border-color: transparent; }
@media (max-width: 640px) { .pass-card { flex-direction: column; } .pass-side { align-items: flex-start; flex-direction: row; } }

/* CR-005: HR documents upload rows */
.up-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px 20px; padding: 10px 0; border-bottom: 1px dashed var(--line, #e6ebe9); }
.up-row .field { margin: 0; }
@media (max-width: 640px) { .up-row { grid-template-columns: 1fr; } }

/* CR-010: My email settings */
.email-kinds { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.email-kinds .check { font-weight: 400; }

/* CR-014: sign-in page, dark panel centred */
.auth-side { align-items: center; text-align: center; }
.auth-side h1 { margin-left: auto; margin-right: auto; }
.auth-side p { margin-left: auto; margin-right: auto; }

/* ---------- CR-015: phones ---------- */
/* Grid and flex children may shrink below their content, so a wide child (the menu strip, a table)
   scrolls inside its own box instead of stretching the whole page. */
.grid > *, .stack > *, .grid-main > * { min-width: 0; }
/* Hidden screen-reader labels inside a scrolling table are positioned within it, not the page. */
.table-wrap { position: relative; }
@media (max-width: 900px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .sidebar, .main { min-width: 0; }
  .nav { scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .nav::-webkit-scrollbar { display: none; }
}
/* App top bars (My Claim, PMS, CRM, My Tasks, My Timesheet): brand and sign-out on one line,
   the menu on its own swipeable row below. */
@media (max-width: 720px) {
  .pms-top-inner, .claim-top-inner { row-gap: 4px; min-height: 0; }
  .pms-who, .claim-who { margin-left: auto; gap: 10px; }
  .pms-nav, .claim-nav { order: 3; flex: 1 0 100%; flex-wrap: nowrap; overflow-x: auto; margin: 0 -16px; padding: 0 12px 6px;
                         scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .pms-nav::-webkit-scrollbar, .claim-nav::-webkit-scrollbar { display: none; }
  .pms-nav a, .claim-nav a { flex: none; white-space: nowrap; }
  .page-head h1 { font-size: 1.5rem; }
}
/* Timesheet week grid: scrolls sideways in its box; "What you worked on" stays put. */
@media (max-width: 720px) {
  .ts-grid .ts-what { min-width: 190px; max-width: 190px; }
  .ts-what-inner select, .ts-what-inner input[type=text] { min-width: 0; width: 100%; }
  .ts-grid th:first-child, .ts-grid td:first-child { position: sticky; left: 0; z-index: 1; background: var(--surface);
                                                     box-shadow: 1px 0 0 var(--line-2); }
  .ts-grid thead th:first-child { background: var(--surface-2); }
  .ts-grid input.hrs { width: 52px; }
}

/* CR-022: tick several statuses in a filter */
.multi-pick { position: relative; }
.multi-pick > summary { list-style: none; cursor: pointer; color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius-s); padding: 8px 30px 8px 10px; background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4l4 4 4-4' fill='none' stroke='%23667' stroke-width='1.5'/%3E%3C/svg%3E") no-repeat right 10px center; white-space: nowrap; }
.multi-pick > summary::-webkit-details-marker { display: none; }
.multi-menu { position: absolute; z-index: 20; top: calc(100% + 4px); left: 0; min-width: 220px; max-height: 320px; overflow: auto; background: var(--surface); border: 1px solid var(--line-2); border-radius: 10px; box-shadow: 0 8px 24px rgba(15, 30, 40, .12); padding: 6px; }
.multi-menu label { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 6px; font-size: .875rem; cursor: pointer; white-space: nowrap; }
.multi-menu label:hover { background: var(--surface-2); }
.multi-menu input { width: auto; margin: 0; }

/* CR-026: read-only fields (e.g. the automatic Employee ID) look read-only */
input:disabled, select:disabled, textarea:disabled { background: var(--surface-2); color: var(--muted); cursor: not-allowed; }

/* CR-031: a date range per stage on Reports */
.stage-ranges > summary { cursor: pointer; font-size: .875rem; color: var(--muted); }
.stage-grid { display: grid; grid-template-columns: repeat(2, auto); gap: 8px 28px; justify-content: start; margin-top: 4px; }
.stage-cell { display: grid; grid-template-columns: 11.5rem auto auto; gap: 8px; align-items: center; }
@media (max-width: 1100px) { .stage-grid { grid-template-columns: 1fr; } }
@media (max-width: 720px) { .stage-cell { grid-template-columns: 1fr; } }
/* CR-033: the split under the Dropped / Rejected numbers */
.funnel .split { display: block; font-size: 0.75rem; color: var(--ink); margin-top: 6px; line-height: 1.5; }

/* CR-042: Reports buttons: Download CSV at the end of the filter row; Show / Reset beside the last date range */
.csv-btn { margin-left: 20px; }
.stage-cell.stage-actions { display: flex; gap: 8px; align-items: center; }
@media (max-width: 1100px) { .csv-btn { margin-left: 0; } }

/* CR-043: fixed widths so the filter row (with "Everyone" for Admin/Finance) stays on one line. */
.filters input.f-search { width: 230px; }
.filters select.f-client, .filters select.f-person { width: 190px; max-width: 100%; text-overflow: ellipsis; }
.filters select.f-job { width: 230px; max-width: 100%; text-overflow: ellipsis; }
@media (max-width: 720px) { .filters input.f-search, .filters select.f-client, .filters select.f-person, .filters select.f-job { width: 100%; } }

/* CR-044: boxes filled from the resume */
.from-resume { background: #fff8d6 !important; border-color: #e0c45c !important; }
.from-resume-note { font-size: .75rem; color: #8a6d00; margin-top: 4px; }
.resume-status { margin-top: 8px; font-size: .8125rem; padding: 8px 10px; border-radius: var(--radius-s); background: var(--surface); border: 1px solid var(--line); }
.resume-status.busy { color: var(--muted, #667); }
.resume-status.ok { border-color: #9cc9a5; background: #eef8f0; }
.resume-status.warn { border-color: #e0c45c; background: #fff8d6; }

/* CR-052: a resume kept from the previous try */
.kept-note { margin-top: 6px; font-size: .8125rem; padding: 6px 10px; border-radius: var(--radius-s); background: #eef8f0; border: 1px solid #9cc9a5; }

/* CR-054: half-month timesheets. Laptop: the table. Phone: lines, then one card per day. */
.ts-period th, .ts-period td { padding-left: 5px; padding-right: 5px; }
.ts-period .ts-what { min-width: 220px; }
.ts-period input.hrs { width: 42px; padding: 6px 2px; }
.ts-grid input.hrs:disabled { background: var(--surface-2); color: var(--faint); }
.ts-sub { font-size: 1rem; margin: 18px 0 8px; }
.ts-sum { display: flex; justify-content: space-between; gap: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px; margin-bottom: 8px; font-size: .8125rem; color: var(--muted); }
.ts-sum b { color: var(--ink); font-size: 1rem; font-variant-numeric: tabular-nums; }
.ts-cards { gap: 6px; margin-bottom: 16px; }
.ts-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.ts-card.off { background: var(--surface-2); }
.ts-card summary { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 11px 12px; cursor: pointer; list-style: none; }
.ts-card summary::-webkit-details-marker { display: none; }
.ts-cline { display: flex; align-items: center; gap: 10px; padding: 7px 12px; border-top: 1px solid var(--line-2, var(--line)); font-size: .875rem; }
.ts-cline label { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.ts-cline input.hrs { width: 76px; text-align: right; }
.ts-badge { font-weight: 600; font-variant-numeric: tabular-nums; font-size: .875rem; white-space: nowrap; }
.ts-badge.off { color: var(--faint); font-weight: 400; }
.ts-badge.long { color: var(--rose); }
.ts-badge.miss { color: var(--amber); background: var(--amber-soft); border-radius: 99px; padding: 1px 8px; font-size: .75rem; }
.ts-badge.lv { color: var(--blue); background: var(--blue-soft); border-radius: 99px; padding: 1px 8px; font-size: .75rem; }
.ts-summary { display: flex; flex-wrap: wrap; border: 1px solid var(--line); border-radius: var(--radius-l); background: var(--surface); overflow: hidden; margin-top: 14px; }
.ts-phone-only, .ts-cards { display: none; }
.ts-summary > div { flex: 1 1 120px; padding: 12px 18px; border-left: 1px solid var(--line); }
.ts-summary > div:first-child { border-left: 0; }
.ts-summary b { display: block; font-size: 1.375rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.ts-summary span { color: var(--muted); font-size: .8125rem; }
@media (max-width: 760px) {
  .js .ts-phone-only { display: flex; }
  .js h2.ts-phone-only { display: block; }
  .js .ts-cards { display: grid; }
  .js .ts-period .dcol, .js .ts-period .dcol-body { display: none; }
  .js .ts-period .ts-what { min-width: 0; }
}

/* CR-061: Payroll */
.pay-app { --accent: #2f5d8a; --accent-soft: #e2ebf5; }
.pay-app .pms-top { background: #142338; }
.pay-app .pms-brand .mark { background: #9cc0e6; color: #142338; }
.pay-app .pms-nav a:hover { background: #1f3552; }
.pay-app .pms-nav a.active { background: #24426a; }
.pay-app .btn-primary:hover { background: #24496e; }
.app-tile.payroll { --tile: #2f5d8a; }
.co-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; }
.pay-app a.co-card { display: flex; flex-direction: column; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-l); padding: 20px; color: var(--ink); text-decoration: none; }
.pay-app a.co-card:hover { border-color: var(--accent); }
.co-top { display: flex; align-items: center; gap: 12px; }
.co-top > div { flex: 1; min-width: 0; }
.co-top b { display: block; }
.co-top span { color: var(--muted); font-size: .8125rem; }
.co-top .flag { width: 40px; height: 40px; border-radius: 10px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 800; font-size: .8125rem; flex: none; }
.co-nums { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.co-nums b { display: block; font-size: 1.05rem; font-variant-numeric: tabular-nums; }
.co-nums b.warn-n { color: var(--amber); }
.co-nums span { color: var(--muted); font-size: .75rem; }
.co-checks { margin: 0; padding: 0; list-style: none; font-size: .8125rem; color: var(--muted); display: grid; gap: 4px; }
.co-checks li.ok::before { content: "✓ "; color: var(--teal); }
.co-checks li.warn { color: var(--amber); }
.co-checks li.warn::before { content: "! "; }
.co-open { color: var(--accent); font-weight: 600; font-size: .875rem; margin-top: auto; }
.pay-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 16px; align-items: start; }
.pay-grid .panel + .panel { margin-top: 0; }
.pay-wide { grid-column: 1 / -1; }
.pay-app .kv { display: grid; grid-template-columns: minmax(120px, 45%) 1fr; gap: 8px 14px; margin: 0; font-size: .9rem; }
.pay-app .kv dt { color: var(--muted); }
.pay-app .kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.pay-app .hist { margin: 12px 0 0; padding-left: 18px; font-size: .875rem; color: var(--muted); }
.pay-app .mini { font-size: .875rem; margin: 16px 0 4px; }
.stack-form { display: grid; gap: 4px; }
.stack-form .field { margin-bottom: 8px; }
.inline-form { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; margin-top: 14px; }
.inline-form .field { margin: 0; flex: 1 1 200px; }
.pay-details { margin-top: 12px; }
.pay-details summary { list-style: none; display: inline-flex; }
.pay-details summary::-webkit-details-marker { display: none; }
.pay-details[open] summary { margin-bottom: 12px; }
.items-table input[type=text], .items-table select { min-width: 110px; }
.items-table input[type=number] { width: 64px; }
.table td.c, .table th.c { text-align: center; }
/* CR-062: approver changes stand out in the change list */
.pay-app .pill.approver-pill { background: #fdecc8; color: #7a4b00; }
.pay-app .pill.muted-pill { background: var(--line); color: var(--muted); }
.pay-app tr.by-approver td { background: #fffaf0; }
/* CR-061-B: monthly run */
.pay-app .run-steps { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 0 0 16px; counter-reset: step; }
.pay-app .run-steps li { counter-increment: step; padding: 6px 12px; border-radius: 999px; background: var(--surface-2); color: var(--muted); font-size: .8125rem; }
.pay-app .run-steps li::before { content: counter(step) ". "; }
.pay-app .run-steps li.done { background: var(--teal-soft); color: var(--teal); }
.pay-app .run-steps li.now { background: var(--accent); color: #fff; }
.pay-app .stats-panel { padding: 0; }
.pay-app .run-table .days-in { width: 72px; text-align: right; }
.pay-app .run-table tr.row-problem td { background: #fff5f6; }
.pay-app .run-table tr.row-hold td { color: var(--faint); }
.pay-app .run-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.pay-app .run-actions form { margin: 0; }
.pay-app .run-actions .inline-form input { width: 240px; max-width: 100%; }
.pay-app .net-row { margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--line); }
.pay-app .extras { list-style: none; padding: 0; margin: 0 0 12px; }
.pay-app .extras li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 6px 0; border-bottom: 1px solid var(--line-2); }
.pay-app .extras form { margin: 0; }
.pay-app .warn-list.soft { background: var(--surface-2); }
/* CR-061-C: payslip (on screen and printed) */
.slip { max-width: 760px; margin: 0 auto 24px; background: #fff; color: #111; border: 1px solid var(--line); box-shadow: 0 6px 24px rgba(23,36,47,.10); padding: 30px; font-size: .8125rem; position: relative; }
.slip.is-draft::after { content: "DRAFT"; position: absolute; top: 40%; left: 50%; transform: translate(-50%, -50%) rotate(-20deg); font-size: 5rem; font-weight: 800; color: rgba(180, 56, 90, .08); pointer-events: none; }
.slip-head { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; border-bottom: 3px solid #142338; padding-bottom: 12px; }
.slip-head > div:first-child { flex: 1 1 300px; min-width: 0; }
.slip-co { font-size: 1.15rem; font-weight: 800; }
.slip-sub { color: #555; margin-top: 2px; }
.slip-title { font-weight: 800; letter-spacing: .1em; color: #142338; text-align: right; }
.slip-title span { display: block; letter-spacing: 0; font-weight: 600; color: #333; }
.slip-who { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 4px 24px; margin: 14px 0; }
.slip-who dl { display: grid; grid-template-columns: 110px 1fr; gap: 3px 10px; margin: 0; }
.slip-who dt { color: #666; }
.slip-who dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.slip-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; }
.slip-t { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.slip-t th { text-align: left; background: #eef2f6; padding: 6px 8px; font-size: .75rem; letter-spacing: .03em; text-transform: uppercase; }
.slip-t th span { text-transform: none; letter-spacing: 0; font-weight: 400; color: #666; }
.slip-t td { padding: 5px 8px; border-bottom: 1px solid #e6e6e6; }
.slip-t .num { text-align: right; }
.slip-t tr.t td { font-weight: 700; border-top: 1.5px solid #111; border-bottom: 0; }
.slip-net { display: flex; justify-content: space-between; align-items: center; background: #142338; color: #fff; border-radius: 6px; padding: 12px 16px; margin: 16px 0; }
.slip-net b { font-size: 1.35rem; font-variant-numeric: tabular-nums; }
.slip-cols.small { font-size: .75rem; }
.slip-foot { color: #777; margin: 18px 0 0; font-size: .75rem; text-align: center; }
@media (max-width: 560px) { .slip { padding: 16px; } .slip-who dl { grid-template-columns: 96px 1fr; } }
@media print { .no-print, header, nav, footer, .site-footer { display: none !important; } .slip { box-shadow: none; border: 0; padding: 0; } }
/* CR-064: MindPec "Salary Slip" layout */
.ss { padding: 26px; }
.ss-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; background: #eef1f0; border: 1px solid #222; padding: 12px 14px; }
.ss-co { display: grid; gap: 4px; min-width: 0; }
.ss-co b { font-size: 1.15rem; }
.ss-co span { color: #333; font-size: .78rem; }
.ss-logo { max-height: 56px; max-width: 200px; object-fit: contain; }
.ss-title { text-align: center; font-weight: 700; font-size: 1.05rem; border: 1px solid #222; border-top: 0; padding: 6px; margin-bottom: 12px; }
.ss-info { width: 100%; border-collapse: collapse; margin-bottom: 12px; }
.ss-info th, .ss-info td { border: 1px solid #999; padding: 4px 8px; text-align: left; font-weight: 400; }
.ss-info th { color: #333; width: 18%; }
.ss-fx { font-size: .8125rem; margin: 0 0 8px; color: #333; }
.ss-info td { width: 32%; }
.ss-pay { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.ss-pay th { background: #eef1f0; border: 1px solid #222; padding: 6px 8px; text-align: center; }
.ss-pay th span { font-weight: 400; color: #555; font-size: .75rem; }
.ss-pay td { border: 1px solid #999; padding: 4px 8px; }
.ss-pay td.num { text-align: right; }
.ss-pay tr.t td { font-weight: 700; border-top: 1.5px solid #222; }
.ss-total { display: grid; grid-template-columns: 1fr 1.4fr 1fr; align-items: center; border: 1px solid #222; border-top: 0; background: #e3e7e5; min-height: 70px; }
.ss-seal { padding: 6px; }
.ss-seal img { max-height: 64px; }
.ss-tp { text-align: center; font-weight: 700; }
.ss-amt { text-align: right; font-weight: 700; font-size: 1.1rem; padding-right: 10px; font-variant-numeric: tabular-nums; }
.ss-er { margin-top: 14px; font-size: .75rem; }
@media (max-width: 560px) { .ss { padding: 12px; } .ss-info th, .ss-info td { display: block; width: auto; border-bottom: 0; } .ss-info tr { display: block; border-bottom: 1px solid #999; } .ss-total { grid-template-columns: 1fr 1fr; } .ss-seal { display: none; } }
/* CR-065: Find candidates (search strings) */
.ps-grid { display: grid; grid-template-columns: minmax(0, 400px) minmax(0, 1fr); gap: 18px; align-items: start; }
@media (max-width: 900px) { .ps-grid { grid-template-columns: minmax(0, 1fr); } }
.ps-brief { display: grid; gap: 12px; }
.ps-brief input[type=text], .ps-brief textarea { width: 100%; }
.ps-ai { display: grid; gap: 6px; background: var(--accent-soft, #e2ebf5); border-radius: 8px; padding: 10px; font-size: .8125rem; }
.ps-ai .btn { justify-self: start; }
.ps-checks { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: .875rem; }
.ps-checks label, .ps-portals label { display: inline-flex; gap: 6px; align-items: center; font-weight: 500; }
.ps-portals { border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px 10px; display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 4px 10px; font-size: .8125rem; }
.ps-portals legend { font-weight: 600; font-size: .875rem; padding: 0 4px; }
.ps-cards { display: grid; gap: 12px; min-width: 0; }
.ps-card { display: grid; gap: 8px; min-width: 0; }
.ps-card h2 { margin: 0; font-size: 1rem; }
.ps-field { display: grid; gap: 4px; min-width: 0; }
.ps-k { font-size: .72rem; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.ps-str { margin: 0; font: 13px/1.55 ui-monospace, "Cascadia Mono", Consolas, monospace; background: var(--surface-2); border: 1px solid var(--line); border-radius: 7px; padding: 8px 10px; white-space: pre-wrap; word-break: break-word; }
.ps-tools { display: flex; gap: 8px; align-items: center; font-size: .78rem; color: var(--muted); }
.ps-warn { margin: 0; font-size: .8rem; color: var(--amber); background: var(--amber-soft); border-radius: 6px; padding: 6px 10px; }
.ps-open { font-weight: 600; font-size: .8125rem; }
.ps-note { margin: 0; font-size: .8rem; }
/* CR-098: Priority job tag (Admin / Recruitment Head) */
.pill.prio-job { background: #fff3cd; color: #8a5a00; border-color: transparent; }
/* CR-102: demo site */
.demo-band { background: #7a3e00; color: #fff; text-align: center; font-size: .8125rem; font-weight: 600; padding: 4px 12px; letter-spacing: .02em; }
.demo-logins { margin-top: 18px; padding: 12px 14px; border: 1px dashed #c8a46b; border-radius: 8px; background: #fffaf0; font-size: .8125rem; }
.demo-logins ul { margin: 6px 0; padding-left: 18px; }
.demo-logins code { font-size: .8125rem; }

/* DEMO-002: the DEMO band takes 28px, so full-screen layouts are 28px shorter (nothing cut off, no extra scroll). */
.demo-band { box-sizing: border-box; height: 28px; line-height: 20px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
body.demo .shell, body.demo .sidebar, body.demo .main, body.demo .auth,
body.demo .launcher, body.demo .claim-app, body.demo .pms-app { min-height: calc(100vh - 28px); }
@media (min-width: 901px) {
  body.demo .shell, body.demo .sidebar, body.demo .main { height: calc(100vh - 28px); min-height: 0; }
}
/* DEMO-002: compact demo logins - one line each, click to fill in. */
body.demo .auth-logo { width: 170px; margin-bottom: 14px; }
body.demo .demo-logins { margin-top: 14px; padding: 10px 12px; }
.demo-logins .demo-login-grid { display: grid; gap: 0; margin: 6px -8px; }
.demo-login-grid button { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; width: 100%;
  min-height: 0; padding: 2px 8px; line-height: 1.35; border: 1px solid transparent; border-radius: 6px; background: none; cursor: pointer;
  font: inherit; color: var(--ink); text-align: left; }
.demo-login-grid button:hover, .demo-login-grid button:focus-visible { background: #fff; border-color: #e3cfa6; outline: none; }
.demo-login-grid button code { color: var(--teal); font-size: .75rem; }

/* DEMO-004: HR Assistant */
.assist-app { --accent: #5b4a9e; --accent-soft: #ece8f7; }
.assist-app .pms-top { background: #231c3d; }
.assist-app .pms-brand .mark { background: #c9bdf0; color: #231c3d; }
.assist-app .pms-nav a:hover { background: #33295a; }
.assist-app .pms-nav a.active { background: #3d3170; }
.app-tile.assist { --tile: #5b4a9e; }
.assist { max-width: 980px; margin: 0 auto; display: flex; flex-direction: column; gap: 14px; }
.assist-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.assist-head h1 { margin: 0; }
.assist-head p { margin: 6px 0 0; }
.assist-tools { display: flex; gap: 8px; align-items: center; }
.assist-log { display: flex; flex-direction: column; gap: 14px; min-height: 280px; }
.assist-empty { background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius-l); padding: 28px 24px; text-align: center; }
.assist-hello { font-size: 1.125rem; font-weight: 600; margin: 0 0 14px; color: var(--ink); }
.assist-examples { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.assist-chip { border: 1px solid #d9d1f2; background: var(--accent-soft); color: #3b2f72; border-radius: 999px; padding: 7px 14px; font: inherit; font-size: .875rem; cursor: pointer; }
.assist-chip:hover, .assist-chip:focus-visible { background: #ddd5f4; outline: none; }
.assist-msg { max-width: 100%; border-radius: var(--radius-l); padding: 12px 16px; line-height: 1.5; }
.assist-msg p { margin: 0 0 6px; }
.assist-msg p:last-child { margin-bottom: 0; }
.assist-msg ul { margin: 4px 0 8px; padding-left: 20px; }
.assist-msg.me { align-self: flex-end; max-width: 75%; background: var(--accent); color: #fff; border-bottom-right-radius: 4px; }
.assist-msg.bot { align-self: stretch; background: var(--surface); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.assist-msg.error { border-color: #e9b8c6; background: var(--rose-soft); color: #7c2440; }
.assist-msg.thinking { color: var(--muted); align-self: flex-start; }
.assist-table { overflow-x: auto; margin-top: 10px; max-height: 420px; overflow-y: auto; border: 1px solid var(--line-2); border-radius: var(--radius); }
.assist-table .table { margin: 0; font-size: .8125rem; }
.assist-table th { position: sticky; top: 0; background: var(--surface-2); z-index: 1; white-space: nowrap; }
.assist-table th, .assist-table td { padding: 7px 12px; white-space: nowrap; }
.assist-table td.num, .assist-table th.num { text-align: right; }
.assist-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 10px; font-size: .8125rem; flex-wrap: wrap; }
.assist-form { position: sticky; bottom: 12px; display: flex; gap: 8px; align-items: flex-end; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-l); padding: 8px; box-shadow: 0 6px 24px rgba(23, 36, 47, .08); }
.assist-form textarea { flex: 1; border: 0; resize: none; font: inherit; padding: 8px 10px; min-height: 22px; max-height: 160px; outline: none; background: transparent; }
.assist-form .btn-primary { background: var(--accent); border-color: var(--accent); }
.assist-form .btn-primary:hover { background: #4a3c85; }
.assist-note { font-size: .75rem; text-align: center; margin: -4px 0 0; }
.assist .dots { display: inline-flex; gap: 3px; margin-right: 6px; vertical-align: middle; }
.assist .dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); opacity: .3; animation: assist-dot 1.2s infinite; }
.assist .dots i:nth-child(2) { animation-delay: .2s; }
.assist .dots i:nth-child(3) { animation-delay: .4s; }
@keyframes assist-dot { 0%, 80%, 100% { opacity: .3; } 40% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .assist .dots i { animation: none; opacity: .7; } }
.assist-app td.nowrap { white-space: nowrap; }
.assist-app .rose-text { color: var(--rose); }
@media (max-width: 720px) { .assist-msg.me { max-width: 90%; } }

/* DEMO-007: All apps fits on one screen — slimmer header, one-line greeting, 4 smaller tiles per row. */
.launcher-top { padding: 10px 32px; }
.launcher-logo { height: 36px; }
.launcher-main { max-width: 1280px; padding: 20px 24px 24px; }
.launcher-hello { display: flex; align-items: baseline; gap: 6px 14px; flex-wrap: wrap; margin-bottom: 16px; }
.launcher-main .launcher-hello h1 { font-size: 1.625rem; margin: 0; }
.launcher-main .launcher-hello .sub { margin: 0; }
.app-tiles { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.app-tile { min-height: 0; padding: 16px 18px; gap: 8px; border-radius: 14px; }
.app-tile .mark { width: 38px; height: 38px; border-radius: 10px; font-size: .8125rem; }
.app-tile h2 { font-size: 1.125rem; margin: 0; }
.app-tile .desc { font-size: .8125rem; margin-top: 2px; line-height: 1.4; }
.app-tile .facts { gap: 6px; }
.app-tile .facts .pill { font-size: .75rem; padding: 2px 8px; }
.app-tile .open { margin-top: auto; font-size: .875rem; }
.app-tile .tile-art { width: 130px; }
@media (max-width: 720px) { .launcher-top { padding: 10px 16px; } .launcher-main { padding: 16px 16px 24px; } }
