/* One Talibon: styles for the hr module. Everything is prefixed hr-.
   The printed form (.hr-sheet and what is inside it) is sized in millimeters and points and does not depend on any ancestor,
   because OT.ui.print copies the node into the print root. */

/* ------------------------------------------------------------------ my record */
.hr-head { display: flex; align-items: center; gap: var(--s5); flex-wrap: wrap; }
.hr-person { display: flex; align-items: center; gap: 12px; min-width: 0; flex: 1 1 260px; }
.hr-person-t { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; }
.hr-person-t b { font-size: 1.05rem; color: var(--head); }
.hr-person .badge { margin-left: auto; }
.hr-credits { display: flex; gap: 12px; flex-wrap: wrap; }
.hr-credit { display: flex; flex-direction: column; gap: 2px; padding: 10px 16px; border-radius: 12px; background: var(--sand); min-width: 150px; }
.hr-credit-l { font-size: var(--fs-sm); color: var(--muted); font-weight: 600; }
.hr-credit-n { font-size: 1.7rem; font-weight: 700; color: var(--head); line-height: 1.1; }
.hr-credit-n small { font-size: .85rem; font-weight: 600; color: var(--muted); }

.hr-cols { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(280px, 1fr); gap: var(--s5); align-items: start; }
.hr-side { position: sticky; top: 16px; }
.hr-card-pad { padding: var(--s4) var(--s5) var(--s3); }
.hr-summary { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; color: var(--ink-2, var(--ink)); }
.hr-summary b { color: var(--head); font-size: 1.05rem; margin-right: -4px; }
.hr-sep { color: var(--muted); }

.hr-att-wrap { overflow-x: auto; }
.hr-att { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); font-variant-numeric: tabular-nums; }
.hr-att th, .hr-att td { padding: 6px 8px; text-align: center; border-top: 1px solid var(--line); white-space: nowrap; }
.hr-att thead th { background: var(--sand); color: var(--muted); font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; border-top: 0; padding: 7px 8px; }
.hr-att thead tr + tr th { border-top: 1px solid var(--line); }
.hr-att .hr-day { text-align: left; font-weight: 600; white-space: nowrap; width: 76px; padding-left: var(--s5); }
.hr-att thead th:first-child { text-align: left; padding-left: var(--s5); }
.hr-dow { display: inline-block; width: 2.7em; color: var(--muted); font-weight: 600; }
.hr-att tbody tr { height: 38px; }
.hr-att tr.is-off th, .hr-att tr.is-off td { background: var(--sand); color: var(--muted); }
.hr-att tr.is-off .hr-dow { opacity: .8; }
.hr-att tr.is-future th, .hr-att tr.is-future td { color: #9aa7b4; }
.hr-att tr.is-today th, .hr-att tr.is-today td { background: #f3f8f8; box-shadow: inset 0 1px 0 var(--sea-300), inset 0 -1px 0 var(--sea-300); }
.hr-att tr.is-today .hr-day { box-shadow: inset 3px 0 0 var(--gold), inset 0 1px 0 var(--sea-300), inset 0 -1px 0 var(--sea-300); }
.hr-across { text-align: left !important; padding-left: 16px !important; letter-spacing: .02em; }
.hr-across.hr-off { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
td.hr-late { color: var(--due-ink, #8a5a10); font-weight: 700; position: relative; }
td.hr-late::before { content: ""; position: absolute; left: 4px; top: 50%; width: 5px; height: 5px; margin-top: -2.5px; border-radius: 50%; background: var(--due); }
span.hr-late { color: var(--due-ink, #8a5a10); font-weight: 700; }
.hr-under { color: var(--muted); font-size: 12.5px; }
.hr-legend { padding: 10px var(--s5) var(--s4); border-top: 1px solid var(--line); color: var(--muted); font-size: 12.5px; }

.hr-reqs { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.hr-req { display: flex; flex-direction: column; gap: 3px; padding: 12px 0; border-top: 1px solid var(--line); }
.hr-req:first-child { border-top: 0; padding-top: 0; }

/* ------------------------------------------------------------------ approvals */
.grid.auto.hr-appr { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.hr-actions { display: flex; gap: 10px; flex-wrap: wrap; padding-top: 4px; }
.hr-actions .btn { flex: 1 1 130px; }
.hr-decided { list-style: none; margin: 0; padding: 0; }
.hr-decided li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px var(--s5); border-top: 1px solid var(--line); flex-wrap: wrap; }
.hr-decided li:first-child { border-top: 0; }
.hr-decided-t { display: flex; flex-direction: column; min-width: 0; }
.hr-decided-s { display: flex; align-items: center; gap: 10px; }

/* ------------------------------------------------------------------ directory */
.hr-dir-search { max-width: 460px; }
.hr-dir-count { margin: 0 0 var(--s4); }
.grid.auto.hr-dir-grid { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); align-items: start; }
.hr-dir-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.hr-dir-list li { display: flex; align-items: center; gap: 12px; min-width: 0; }
.hr-dir-t { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; }
.hr-dir-t b { font-weight: 650; }

/* ------------------------------------------------------------------ DTR screen chrome */
.hr-dtr-bar { display: flex; gap: var(--s4); flex-wrap: wrap; align-items: flex-end; }
.hr-dtr-bar .field { min-width: 190px; flex: 0 1 260px; margin: 0; }
.hr-dtr-print { margin-left: auto; }
.hr-dtr-note { margin: 4px 0 0; }
.hr-desk { background: var(--sand-200); border: 1px solid var(--line); border-radius: 14px; padding: 18px; min-width: 0; overflow: hidden; }
.hr-zoom { width: 193mm; margin: 0 auto; }
.hr-desk.is-big { overflow-x: auto; overflow-y: hidden; }
.hr-desk.is-big .hr-zoom { margin: 0; }
.hr-phone-only { display: none; }

/* ------------------------------------------------------------------ the form: Civil Service Form No. 48, two copies on A4 */
.hr-sheet { box-sizing: border-box; width: 193mm; height: 278mm; display: flex; background: #fff; color: #000; overflow: hidden;
  font-family: "Times New Roman", Times, "Liberation Serif", Georgia, serif; font-size: 8pt; line-height: 1.2; box-shadow: 0 6px 24px rgba(11, 46, 60, .22); text-align: left; }
.hr-sheet * { box-sizing: border-box; }
.hr-form { flex: 1 1 0; width: 0; min-width: 0; height: 100%; padding: 5mm 3.5mm 4mm 3.5mm; display: flex; flex-direction: column; }
.hr-form + .hr-form { border-left: .25mm dashed #777; }
.hr-f-no { font-style: italic; font-size: 7.5pt; }
.hr-f-title { text-align: center; font-weight: 700; font-size: 13pt; letter-spacing: .06em; margin-top: 1.5mm; }
.hr-f-o0o { text-align: center; font-size: 9pt; margin-top: .5mm; letter-spacing: .05em; }
.hr-f-name { margin-top: 3mm; height: 7mm; display: flex; align-items: flex-end; justify-content: center; text-align: center; font-weight: 700; font-size: 10pt; letter-spacing: .03em; border-bottom: .3mm solid #000; padding-bottom: .5mm; line-height: 1.05; }
.hr-f-name.long { font-size: 7.5pt; }
.hr-f-cap { text-align: center; font-size: 7pt; }
.hr-f-month { margin-top: 1.5mm; font-size: 9pt; }
.hr-f-fill { display: inline-block; border-bottom: .25mm solid #000; padding: 0 2mm; font-weight: 700; min-width: 20mm; text-align: center; }
.hr-f-month .hr-f-fill { min-width: 40mm; }
.hr-f-hours { display: flex; gap: 2mm; margin: 1.5mm 0 2mm; font-size: 7.5pt; align-items: center; }
.hr-f-hl { flex: 0 0 34mm; }
.hr-f-hr { flex: 1; display: flex; flex-direction: column; gap: .6mm; }
.hr-f-hr .hr-f-fill { font-weight: 400; min-width: 0; padding: 0 1mm; font-size: 7.5pt; }

.hr-f-table { width: 100%; table-layout: fixed; border-collapse: collapse; border: .3mm solid #000; font-size: 7.5pt; }
.hr-f-table col.c-day { width: 7.5mm; }
.hr-f-table col.c-t { width: 14.5mm; }
.hr-f-table col.c-u { width: 12mm; }
.hr-f-table th, .hr-f-table td { border: .2mm solid #000; padding: 0 .4mm; text-align: center; height: 5.4mm; line-height: 4.8mm; overflow: hidden; white-space: nowrap; font-weight: 400; }
.hr-f-table thead th { font-weight: 700; height: 4.4mm; line-height: 3.9mm; font-size: 6.8pt; letter-spacing: -.02em; }
.hr-f-table td.hr-d { font-weight: 700; }
.hr-f-table td.hr-w { font-style: italic; letter-spacing: .05em; }
.hr-f-table .hr-total td { font-weight: 700; border-top: .3mm solid #000; }
.hr-f-table .hr-total td:first-child { text-align: left; padding-left: 2mm; letter-spacing: .05em; }

.hr-f-foot { margin-top: auto; padding-top: 2mm; }
.hr-f-cert { margin: 0; font-size: 7.5pt; line-height: 1.25; text-align: justify; text-indent: 4mm; }
.hr-f-sig { height: 9mm; border-bottom: .3mm solid #000; margin: 0 6mm; }
.hr-f-ver { margin: 2mm 0 0; font-size: 7.5pt; }
.hr-f-inch { text-align: center; font-size: 7.5pt; margin-top: .6mm; }
.hr-f-foot .hr-f-sig:last-of-type { height: 8mm; }

@media print {
  .hr-sheet { box-shadow: none; margin: 0; }
}

/* ------------------------------------------------------------------ phones */
@media (max-width: 900px) {
  .hr-cols { grid-template-columns: 1fr; }
  .hr-side { position: static; order: -1; }
}
@media (max-width: 640px) {
  .hr-head { align-items: stretch; }
  .hr-head > .btn { width: 100%; }
  .hr-credits { width: 100%; }
  .hr-credit { flex: 1 1 0; min-width: 0; }
  .hr-att th, .hr-att td { padding: 6px 3px; }
  .hr-att .hr-day { width: 62px; padding-left: 12px; }
  .hr-att thead th:first-child { padding-left: 12px; }
  .hr-card-pad, .hr-legend { padding-left: var(--s4); padding-right: var(--s4); }
  .grid.auto.hr-appr { grid-template-columns: 1fr; }
  .grid.auto.hr-dir-grid { grid-template-columns: 1fr; }
  .hr-dtr-bar .field { flex: 1 1 100%; }
  .hr-dtr-print { margin-left: 0; width: 100%; }
  .hr-dtr-print .btn { width: 100%; }
  .hr-desk { padding: 8px; border-radius: 10px; }
  .hr-phone-only { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); }
  .hr-phone-only .hr-dtr-full { margin: 0; }
}
.hr-appr .stack { gap: 16px; }
