/* RadiHR. Radionyx look: ink, emerald and amber. One stylesheet, no build step. */
:root {
  --ink: #0A150F;
  --ink-2: #1D2A23;
  --text: #17231C;
  --muted: #5B6B62;
  --line: #E1E7E3;
  --line-2: #CBD5CF;
  --bg: #F4F6F4;
  --card: #FFFFFF;
  --brand: #0C8054;
  --brand-dark: #08623F;
  --brand-bright: #1B9A69;
  --brand-soft: #E5F3EC;
  --amber: #D98B2D;
  --amber-ink: #8A5208;
  --amber-soft: #FCF1E1;
  --bad: #B3261E;
  --bad-soft: #FDECEA;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(10, 21, 15, .05), 0 2px 8px rgba(10, 21, 15, .04);
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 16px/1.55 var(--font); color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; }
a { color: var(--brand); text-decoration: none; font-weight: 500; }
a:hover { text-decoration: underline; }
h1 { font-size: 1.65rem; line-height: 1.2; margin: 0; letter-spacing: -.015em; color: var(--ink); }
h2 { font-size: 1.1rem; line-height: 1.3; margin: 0 0 .7rem; color: var(--ink); }
h3 { font-size: .95rem; margin: 1.4rem 0 .4rem; color: var(--ink); }
p { margin: 0 0 .75rem; }
code { background: #EEF2EF; padding: .1em .35em; border-radius: 5px; font-size: .9em; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.r { text-align: right; }
.pre { white-space: pre-line; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.icon { width: 1.2em; height: 1.2em; flex: none; vertical-align: -.22em; }

/* brand */
.logo { display: inline-flex; align-items: center; gap: .45rem; color: var(--ink); }
.logo-mark { width: 1.8rem; height: 1.8rem; flex: none; }
.logo-word { font-weight: 800; font-size: 1.3rem; letter-spacing: -.01em; }
.logo-word b { color: var(--brand); font-weight: 800; }
.logo-tag { font-size: .75rem; font-weight: 600; color: var(--muted); border-left: 1px solid var(--line-2); padding-left: .55rem; margin-left: .15rem; }
.logo.on-dark { color: #fff; }
.logo.on-dark .logo-word b { color: #3CC48C; }
.brand { font-weight: 800; font-size: 1.3rem; }
.brand b { color: var(--brand); }

/* ---------- backend layout ---------- */
.shell { display: grid; grid-template-columns: 248px 1fr; min-height: 100vh; }
.side { background: var(--ink); color: #C6D2CB; padding: 1.2rem .9rem; display: flex; flex-direction: column; gap: .3rem; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.side-top { padding: 0 .5rem .8rem; border-bottom: 1px solid #1F2E26; margin-bottom: .4rem; }
.side .tenant { display: flex; gap: .4rem; align-items: center; font-size: .85rem; color: #9DB0A5; margin: .7rem 0 0; }
.side nav { display: flex; flex-direction: column; gap: 2px; }
.nav-group { font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .09em; color: #6F857A; margin: .9rem .6rem .3rem; }
.side nav a { display: flex; align-items: center; gap: .65rem; color: #D3DED7; padding: .55rem .7rem; border-radius: 10px; font-weight: 500; font-size: .95rem; }
.side nav a .icon { color: #8FA79A; }
.side nav a:hover { background: #16241C; text-decoration: none; }
.side nav a.on { background: var(--brand); color: #fff; font-weight: 650; }
.side nav a.on .icon { color: #fff; }
.side-foot { margin-top: auto; display: flex; flex-direction: column; gap: .5rem; font-size: .88rem; padding: .9rem .5rem 0; border-top: 1px solid #1F2E26; }
.side-foot a, .side-foot .link { color: #9FDCC0; display: inline-flex; gap: .45rem; align-items: center; }
.me-card { display: flex; gap: .6rem; align-items: center; color: #fff; line-height: 1.3; }
.me-card .small { color: #9DB0A5; }
.avatar { width: 2.3rem; height: 2.3rem; border-radius: 50%; background: var(--amber); color: var(--ink); font-weight: 800; display: grid; place-items: center; font-size: .85rem; flex: none; }
.content { padding: 1.8rem clamp(1rem, 3vw, 2.6rem) 4rem; max-width: 1280px; width: 100%; }

/* ---------- top bars ---------- */
.appbar { background: var(--card); border-bottom: 1px solid var(--line); }
.appbar-inner { max-width: 1180px; margin: 0 auto; padding: .8rem 1rem; display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; }
.appbar-right { display: flex; gap: .7rem; align-items: center; font-size: .9rem; flex-wrap: wrap; }
.who { display: inline-flex; gap: .35rem; align-items: center; color: var(--muted); }
.wide { max-width: 1180px; margin: 0 auto; padding: 1.6rem 1rem 4rem; }
.topbar { display: flex; justify-content: space-between; align-items: center; padding: .8rem 1rem; }
.topbar-right { display: flex; gap: 1rem; align-items: center; font-size: .9rem; }

/* ---------- promoter app ---------- */
.mobile { max-width: 560px; margin: 0 auto; min-height: 100vh; display: flex; flex-direction: column; }
.mobile-bar { display: flex; justify-content: space-between; align-items: center; padding: .7rem 1rem; position: sticky; top: 0; z-index: 6; }
.mobile-bar .logo-mark { width: 1.6rem; height: 1.6rem; }
.mobile-bar .logo-word { font-size: 1.15rem; }
.mobile .content { padding: 1rem 1rem 7rem; }
.chip { display: inline-flex; align-items: center; gap: .3rem; padding: .35rem .7rem; border-radius: 99px; border: 1px solid var(--line-2); background: #fff; color: var(--text); font-size: .85rem; font-weight: 600; cursor: pointer; min-height: 2.25rem; }
.chip:hover { border-color: var(--brand); text-decoration: none; }
.tabbar { position: fixed; bottom: 0; left: 0; right: 0; background: var(--card); border-top: 1px solid var(--line); display: flex; justify-content: center; padding: .3rem .25rem calc(.3rem + env(safe-area-inset-bottom)); z-index: 5; box-shadow: 0 -2px 12px rgba(10, 21, 15, .05); }
.tabbar a { flex: 1; max-width: 112px; display: flex; flex-direction: column; align-items: center; gap: .1rem; padding: .45rem .15rem; color: var(--muted); font-size: .76rem; font-weight: 600; border-radius: 12px; position: relative; }
.tabbar a .icon { width: 1.5rem; height: 1.5rem; }
.tabbar a:hover { text-decoration: none; }
.tabbar a.on { color: var(--brand); background: var(--brand-soft); }
.dot { position: absolute; top: .2rem; left: calc(50% + .45rem); background: var(--bad); color: #fff; border-radius: 99px; font-size: .68rem; min-width: 1.15rem; padding: 0 .3em; line-height: 1.15rem; text-align: center; }
.hello { margin: .4rem 0 1rem; }
.hello .muted { margin: 0 0 .1rem; }
.links { display: flex; justify-content: center; gap: .6rem; flex-wrap: wrap; margin-top: 1rem; }

/* status hero on the clock page */
.status { display: flex; gap: .9rem; align-items: center; border-radius: var(--radius); padding: 1rem 1.1rem; margin-bottom: 1rem; }
.status .icon { width: 2.2rem; height: 2.2rem; }
.status b { display: block; font-size: 1.15rem; line-height: 1.25; }
.status span { font-size: .92rem; }
.status-out { background: var(--amber-soft); color: var(--amber-ink); }
.status-in { background: var(--brand); color: #fff; }
.status-done { background: var(--ink); color: #fff; }
.status-leave { background: #EEF2EF; color: var(--ink); }

/* ---------- sign-in pages ---------- */
.plain { max-width: 460px; margin: 0 auto; padding: 7vh 1rem 2rem; }
.plain-brand { text-align: center; margin-bottom: 1.4rem; }
.plain-brand .logo-mark { width: 2.6rem; height: 2.6rem; }
.plain-brand .logo-word { font-size: 1.9rem; }
.plain-foot { text-align: center; color: var(--muted); font-size: .8rem; margin-top: 2rem; }
.welcome { text-align: center; margin-bottom: 1.2rem; }
.welcome h1 { font-size: 1.45rem; }
.welcome p { color: var(--muted); margin: .3rem 0 0; }
.lang-line { font-size: .88em; color: var(--muted); font-weight: 400; }

/* ---------- blocks ---------- */
.back-link { display: inline-flex; gap: .3rem; align-items: center; font-size: .9rem; margin-bottom: .5rem; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.1rem; }
.page-head .subtitle { color: var(--muted); margin: .25rem 0 0; }
.help { display: flex; gap: .6rem; align-items: flex-start; background: var(--brand-soft); color: #134D35; border-radius: var(--radius-sm); padding: .7rem .9rem; margin: -.3rem 0 1.2rem; font-size: .93rem; }
.help .icon { margin-top: .12rem; color: var(--brand); }
.actions { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.2rem 1.3rem; margin-bottom: 1rem; box-shadow: var(--shadow); }
.card.flush { padding: 0; overflow: hidden; }
.card.scroll { overflow-x: auto; }
.card-title { padding: 1rem 1.3rem .3rem; margin: 0; }
.card.narrow { max-width: 460px; margin-left: auto; margin-right: auto; }
.card.narrow h1 { margin-bottom: .9rem; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: .6rem; margin-bottom: .7rem; }
.card-head h2 { margin: 0; display: flex; gap: .5rem; align-items: center; }
.card-head h2 .icon { color: var(--brand); }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 0 1rem; }
.grid2 > .card { margin-bottom: 1rem; }
.grid2.wide-right { grid-template-columns: minmax(280px, 1fr) minmax(320px, 1.3fr); align-items: start; }
.grid3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0 1rem; }
.span2 { grid-column: span 2; }
.row { display: flex; gap: .6rem; align-items: center; flex-wrap: wrap; margin: .6rem 0; }
.row.end { align-items: flex-end; }
.row.end .field { margin-bottom: 0; }
form.inline { display: inline; }

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: .8rem; margin-bottom: 1.2rem; }
.tile { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.1rem; display: flex; flex-direction: column; gap: .15rem; color: inherit; box-shadow: var(--shadow); position: relative; }
a.tile:hover { border-color: var(--brand); text-decoration: none; }
.tile-label { font-size: .88rem; font-weight: 600; color: var(--muted); display: flex; gap: .4rem; align-items: center; }
.tile-label .icon { color: var(--brand); }
.tile-value { font-size: 2.1rem; font-weight: 800; line-height: 1.1; font-variant-numeric: tabular-nums; color: var(--ink); }
.tile-value.sm { font-size: 1.3rem; }
.tile-note { font-size: .82rem; color: var(--muted); }
.tile.alert { border-color: #F0C68B; background: var(--amber-soft); }
.tile.alert .tile-value { color: var(--amber-ink); }

.badge { display: inline-block; font-size: .76rem; font-weight: 650; padding: .15em .65em; border-radius: 99px; background: #ECF0ED; color: var(--muted); vertical-align: middle; white-space: nowrap; }
.badge-good { background: var(--brand-soft); color: var(--brand-dark); }
.badge-warn { background: var(--amber-soft); color: var(--amber-ink); }
.badge-bad { background: var(--bad-soft); color: var(--bad); }

.flash { display: flex; gap: .6rem; align-items: flex-start; padding: .8rem 1rem; border-radius: var(--radius-sm); margin-bottom: 1rem; overflow-wrap: anywhere; font-weight: 500; }
.flash .icon { margin-top: .1rem; }
.flash-info { background: var(--brand-soft); color: #0B4A32; }
.flash-error { background: var(--bad-soft); color: var(--bad); }
.note { background: var(--amber-soft); color: var(--amber-ink); padding: .6rem .85rem; border-radius: var(--radius-sm); }
.warn-line { display: block; color: var(--amber-ink); font-size: .82rem; }
.empty { text-align: center; padding: 1.6rem 1rem; color: var(--muted); }
.empty .icon { width: 2.4rem; height: 2.4rem; color: var(--brand-bright); }
.empty-title { font-weight: 650; color: var(--ink); margin: .4rem 0 .2rem; }

/* checklist on the backend home page */
.checklist { list-style: none; margin: 0; padding: 0; counter-reset: c; }
.checklist li { display: flex; gap: .8rem; align-items: flex-start; padding: .8rem 0; border-top: 1px solid var(--line); }
.checklist li:first-child { border-top: 0; }
.checklist .tick { width: 1.8rem; height: 1.8rem; border-radius: 50%; border: 2px solid var(--line-2); display: grid; place-items: center; flex: none; font-weight: 800; color: var(--muted); font-size: .85rem; }
.checklist li.done .tick { background: var(--brand); border-color: var(--brand); color: #fff; }
.checklist li.done .what { color: var(--muted); }
.checklist .what { flex: 1; }
.checklist .what b { display: block; color: var(--ink); }
.checklist li.done .what b { text-decoration: line-through; text-decoration-color: var(--line-2); color: var(--muted); }
.progress { height: .5rem; background: #E6ECE8; border-radius: 99px; overflow: hidden; margin: .2rem 0 .9rem; }
.progress > span { display: block; height: 100%; background: var(--brand); border-radius: 99px; }

/* stepper */
.stepper { list-style: none; margin: 0 0 1.2rem; padding: 0; display: flex; gap: .4rem; flex-wrap: wrap; }
.stepper li { display: flex; align-items: center; gap: .45rem; padding: .4rem .8rem .4rem .45rem; border-radius: 99px; background: #ECF0ED; color: var(--muted); font-size: .88rem; font-weight: 600; }
.stepper-num { width: 1.55rem; height: 1.55rem; border-radius: 50%; background: #fff; display: grid; place-items: center; font-size: .8rem; }
.stepper li.done { background: var(--brand-soft); color: var(--brand-dark); }
.stepper li.done .stepper-num { background: var(--brand); color: #fff; }
.stepper li.now { background: var(--ink); color: #fff; }
.stepper li.now .stepper-num { background: var(--amber); color: var(--ink); }

/* ---------- tables and lists ---------- */
.table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.table th, .table td { padding: .7rem .9rem; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.table th.r, .table td.r { text-align: right; }
.table thead th { font-size: .8rem; font-weight: 650; color: var(--muted); white-space: nowrap; background: #F8FAF8; }
.table tbody tr:hover td { background: #FAFCFA; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tfoot th { border-top: 2px solid var(--ink); border-bottom: 0; }
.table.small td, .table.small th { padding: .4rem .8rem; font-size: .88rem; }
.table td.over { color: var(--bad); font-weight: 700; }
.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .9rem 1.3rem; border-bottom: 1px solid var(--line); }
.list li.top { align-items: flex-start; }
.list li:last-child { border-bottom: 0; }
.list .stretch { flex: 1; display: flex; flex-direction: column; color: inherit; }
.list a.stretch:hover { text-decoration: none; }
.list .unread { font-weight: 750; }
.list .unread::before { content: ""; display: inline-block; width: .5rem; height: .5rem; border-radius: 50%; background: var(--amber); margin-right: .45rem; vertical-align: .12em; }
.figure { font-weight: 750; font-variant-numeric: tabular-nums; white-space: nowrap; color: var(--ink); }
.plain-list { list-style: none; padding: 0; margin: 0 0 1rem; }
.plain-list li { padding: .4rem 0; border-bottom: 1px dashed var(--line); }
.plain-list li:last-child { border-bottom: 0; }
.clip { max-height: 3em; overflow: hidden; color: var(--muted); }
.days { list-style: none; margin: 0; padding: 0; }
.days li { display: flex; gap: .8rem; align-items: baseline; padding: .8rem 1.3rem; border-top: 1px solid var(--line); flex-wrap: wrap; }
.days li.today { background: var(--brand-soft); box-shadow: inset 4px 0 0 var(--brand); }
.days .when { width: 6.6rem; font-weight: 650; }
.detail { display: grid; grid-template-columns: minmax(120px, max-content) 1fr; gap: .45rem 1.2rem; margin: 0; }
.detail dt { color: var(--muted); }
.detail dd { margin: 0; overflow-wrap: anywhere; font-weight: 500; }
.pair { display: flex; gap: 2.4rem; margin: .7rem 0 0; }
.pair dt { font-size: .82rem; font-weight: 600; color: var(--muted); }
.pair dd { margin: 0; font-size: 1.7rem; font-weight: 800; font-variant-numeric: tabular-nums; color: var(--ink); }
.month-nav { display: flex; justify-content: space-between; margin-bottom: .8rem; }
.month-nav a { display: inline-flex; padding: .4rem .8rem; border-radius: 99px; background: #fff; border: 1px solid var(--line); }
.month-nav a:hover { text-decoration: none; border-color: var(--brand); }
.fold { border-top: 1px solid var(--line); padding: .7rem 0; }
.fold summary { cursor: pointer; font-weight: 600; color: var(--brand); }
.fold form { margin-top: .8rem; }
.fold h3 { margin-top: 0; }

/* ---------- forms ---------- */
.field { margin-bottom: 1rem; display: flex; flex-direction: column; }
.field > label, .filters label { font-size: .9rem; font-weight: 650; margin-bottom: .3rem; color: var(--ink); }
input, select, textarea, button { font: inherit; color: inherit; }
input[type=text], input[type=password], input[type=email], input[type=number], input[type=date], input[type=time], input[type=search], input[type=tel], input:not([type]), select, textarea {
  width: 100%; padding: .6rem .75rem; border: 1.5px solid var(--line-2); border-radius: var(--radius-sm); background: #fff; min-height: 2.75rem; font-size: 1rem;
}
input:focus, select:focus, textarea:focus { border-color: var(--brand); outline: none; box-shadow: 0 0 0 3px rgba(12, 128, 84, .15); }
.btn:focus-visible, a:focus-visible, button:focus-visible { outline: 3px solid rgba(12, 128, 84, .35); outline-offset: 2px; }
input:disabled { background: #F1F4F2; color: var(--muted); }
input[type=file] { font-size: .92rem; }
.hint { font-size: .85rem; color: var(--muted); margin: .3rem 0 0; }
.error { font-size: .86rem; color: var(--bad); margin: .3rem 0 0; font-weight: 500; }
.has-error input, .has-error select { border-color: var(--bad); }
.check { display: flex; gap: .55rem; align-items: flex-start; font-weight: 500 !important; }
.check input { margin-top: .2rem; width: 1.2rem; height: 1.2rem; flex: none; accent-color: var(--brand); }
.filters { display: flex; gap: .6rem; flex-wrap: wrap; align-items: flex-end; margin-bottom: 1rem; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: .8rem; }
.filters input, .filters select { width: auto; min-width: 9rem; }
.filters label { display: flex; flex-direction: column; }
.decide { display: flex; gap: .4rem; align-items: center; flex-wrap: wrap; }
.decide input { width: 12rem; }
.decide select { width: auto; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; padding: .55rem 1rem; border-radius: var(--radius-sm); border: 1.5px solid var(--line-2); background: #fff; color: var(--ink); font-weight: 650; cursor: pointer; white-space: nowrap; min-height: 2.75rem; font-size: .95rem; }
.btn:hover { border-color: var(--ink); text-decoration: none; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.primary:hover { background: var(--brand-dark); border-color: var(--brand-dark); }
.btn.dark { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn.dark:hover { background: var(--ink-2); }
.btn.amber { background: var(--amber); border-color: var(--amber); color: var(--ink); }
.btn.danger { color: var(--bad); border-color: #EBB8B3; }
.btn.danger:hover { background: var(--bad-soft); border-color: var(--bad); }
.btn.ghost { background: transparent; border-color: transparent; color: var(--brand); }
.btn.small { padding: .3rem .7rem; min-height: 2.2rem; font-size: .88rem; }
.btn.block { width: 100%; }
.btn.big { min-height: 3.9rem; font-size: 1.2rem; border-radius: 16px; }
.btn:disabled { opacity: .4; cursor: not-allowed; }
.link { background: none; border: 0; padding: 0; color: var(--brand); cursor: pointer; font-weight: 500; }

/* ---------- clock-in ---------- */
.clock .steps { list-style: none; padding: 0; margin: .4rem 0 1rem; display: grid; gap: .7rem; counter-reset: step; }
.clock .steps > li { counter-increment: step; display: grid; grid-template-columns: 2rem 1fr; gap: .2rem .7rem; align-items: start; padding: .75rem; border: 1.5px solid var(--line); border-radius: 12px; }
.clock .steps > li::before { content: counter(step); width: 2rem; height: 2rem; border-radius: 50%; background: #ECF0ED; color: var(--muted); font-weight: 800; display: grid; place-items: center; grid-row: span 3; }
.clock .steps > li.done { border-color: #A9D9C2; background: #F6FBF8; }
.clock .steps > li.done::before { content: "✓"; background: var(--brand); color: #fff; }
.clock .steps > li.fail { border-color: #EBB8B3; background: #FFF9F8; }
.step-title { font-weight: 700; color: var(--ink); }
.clock video, .clock #preview { width: 100%; max-width: 260px; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 12px; background: #0E1712; display: block; transform: scaleX(-1); margin-top: .4rem; }
.step-state { display: block; font-size: .9rem; color: var(--muted); }
.step-state.ok { color: var(--brand-dark); font-weight: 650; }
.step-state.fail { color: var(--bad); font-weight: 650; }
.waiting { text-align: center; font-size: .88rem; color: var(--muted); margin: .6rem 0 0; }
.fallback { border: 1.5px dashed var(--line-2); border-radius: 12px; padding: .7rem .9rem; margin-bottom: .9rem; }
.fallback summary { cursor: pointer; color: var(--brand); font-weight: 650; display: flex; gap: .4rem; align-items: center; }
.fallback[open] summary { margin-bottom: .6rem; }
.fallback #pin { max-width: 11rem; font-size: 1.4rem; letter-spacing: .25em; text-align: center; }
.clock .flash { margin: .4rem 0 .8rem; }

/* ---------- roster and payroll grids ---------- */
.roster select.cell { min-width: 9.5rem; padding: .3rem; font-size: .85rem; min-height: 2.3rem; }
.roster td:first-child { min-width: 11rem; }
.roster .cell-work { background: var(--brand-soft); border-color: #9FD3BB; }
.roster .cell-rest, .roster .cell-off { background: #ECF0ED; }
.roster .draft { border-style: dashed; border-width: 2px; }
.roster th.holiday { color: var(--amber-ink); }
.roster td.on-leave { background: var(--amber-soft); }
.roster .custom-times { display: flex; flex-direction: column; gap: .2rem; margin-top: .25rem; }
.roster .custom-times input { width: 100%; min-width: 9.5rem; min-height: 2rem; padding: .15rem .3rem; font-size: .82rem; }
.grid-input input { width: 4.6rem; min-height: 2.2rem; padding: .25rem .4rem; text-align: right; }
.grid-input th, .grid-input td { padding-left: .35rem; padding-right: .35rem; }
.grid-input thead th { white-space: normal; }
.grid-input td:first-child { min-width: 9.5rem; }
.legend { display: flex; gap: 1rem; flex-wrap: wrap; font-size: .85rem; color: var(--muted); margin: .2rem 0 .9rem; }
.legend span::before { content: ""; display: inline-block; width: .9rem; height: .9rem; border-radius: 4px; margin-right: .35rem; vertical-align: -.12em; border: 1px solid var(--line-2); }
.legend .l-work::before { background: var(--brand-soft); border-color: #9FD3BB; }
.legend .l-rest::before { background: #ECF0ED; }
.legend .l-leave::before { background: var(--amber-soft); }
.legend .l-draft::before { border: 2px dashed var(--muted); }

/* ---------- payslip ---------- */
.payslip { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; margin-bottom: 1rem; box-shadow: var(--shadow); }
.payslip header { display: flex; justify-content: space-between; gap: 1rem; border-bottom: 3px solid var(--brand); padding-bottom: .7rem; margin-bottom: .9rem; }
.payslip h1 { font-size: 1.2rem; }
.payslip .table thead th { white-space: normal; }
.payslip .table th, .payslip .table td { padding-left: .5rem; padding-right: .5rem; }
.payslip .cols { margin-bottom: 1rem; }
.payslip-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; align-items: start; }
.payslip .net { text-align: right; font-size: 1.1rem; margin: 1rem 0; padding: .8rem 1rem; background: var(--brand-soft); color: var(--brand-dark); border-radius: 12px; font-weight: 600; }
.payslip .net b { font-size: 1.5rem; margin-left: .6rem; font-variant-numeric: tabular-nums; color: var(--ink); }
.prose ul { padding-left: 1.2rem; }
.prose li { margin-bottom: .4rem; }

/* ---------- misc ---------- */
.pager { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin: -.3rem 0 1rem; font-size: .92rem; }
.list-box { max-height: 26rem; overflow-y: auto; border: 1px solid var(--line); border-radius: 10px; margin: .6rem 0; }
.list-box thead th { position: sticky; top: 0; }
.pin-code { font-size: 1.1rem; letter-spacing: .14em; font-weight: 800; font-variant-numeric: tabular-nums; }
.wa { display: inline-flex; align-items: center; gap: .3rem; color: #0A7D3B; font-weight: 650; }
.device-link-row { display: flex; gap: 1.2rem; align-items: flex-start; flex-wrap: wrap; }
.device-link-row > div:last-child { flex: 1; min-width: 260px; }
.small-qr { padding: .5rem; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.small-qr svg { display: block; width: 180px; height: 180px; }
input.copy { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .85rem; }
.row.tight { margin: .35rem 0 0; gap: .5rem; }
.link.small { font-size: .85rem; }

/* ---------- counter tablet screen ---------- */
.display { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .7rem; padding: 1.5rem; text-align: center; background: var(--bg); }
.display h1 { font-size: clamp(1.6rem, 4vw, 2.6rem); }
.display .lead { font-size: 1.2rem; margin: 0; color: var(--muted); }
.display .qr svg { width: min(70vw, 58vh, 420px); height: auto; display: block; }
.display .qr { padding: 1rem; background: #fff; border: 3px solid var(--brand); border-radius: 22px; box-shadow: var(--shadow); }
.display .pin { font-size: 1.1rem; background: #fff; border: 1px solid var(--line); padding: .6rem 1.2rem; border-radius: 12px; }
.display .pin b { font-size: 1.9rem; letter-spacing: .2em; margin: 0 .6rem; font-variant-numeric: tabular-nums; color: var(--ink); }

@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: static; height: auto; padding: .8rem; }
  .side-top { display: flex; justify-content: space-between; align-items: center; border: 0; margin: 0; padding: 0 .3rem .4rem; }
  .side .tenant { margin: 0; }
  .side nav { flex-direction: row; overflow-x: auto; gap: .25rem; padding-bottom: .3rem; }
  .side nav a { white-space: nowrap; padding: .45rem .7rem; }
  .nav-group { display: none; }
  .side-foot { flex-direction: row; flex-wrap: wrap; gap: .9rem; align-items: center; padding-top: .6rem; }
  .grid2.wide-right { grid-template-columns: 1fr; }
  .span2 { grid-column: auto; }
  h1 { font-size: 1.4rem; }
}
@media print {
  body { background: #fff; }
  .side, .topbar, .appbar, .tabbar, .no-print, .flash, .help, .back-link { display: none !important; }
  .shell { display: block; }
  .content, .mobile .content { padding: 0; max-width: none; }
  .payslip { border: 0; padding: 0; box-shadow: none; }
  .grid2.wide-right { display: block; }
}
@media (prefers-reduced-motion: no-preference) { .btn, .chip, .side nav a { transition: background .12s, border-color .12s, color .12s; } }
label .lang-line { display: block; font-weight: 400; font-size: .85rem; }
.shell { background: linear-gradient(to right, var(--ink) 248px, var(--bg) 248px); }
@media (max-width: 900px) { .shell { background: var(--bg); } }
