/* Tharsol Connect: the HR attendance reports (/hr/attendance, its print view). Namespaced (.at-*). Connect's tokens for
   surfaces, text and the accent (tabs, avatars, today, selection); the day colours are fixed semantic colours (ok, late,
   early, absent, missing, half day, leave, holiday, short), never the accent, set once here for light and dark. Chips,
   pills and cells are tinted: tint fill, saturated text, 1px border. */

.at-root {
    --at-ok: #1F8A57;
    --at-late: #B7791F;
    --at-early: #C8622A;
    --at-abs: #C93F38;
    --at-miss: #8E4BB8;
    --at-half: #2F78C9;
    --at-leave: #1F8BAF;
    --at-hol: #5562D1;
    --at-satoff: #0F7F74;
    --at-short: #CF4B47;
    --at-track: color-mix(in srgb, var(--muted) 16%, transparent);
    --at-rest: color-mix(in srgb, var(--muted) 10%, transparent);
}

:root[data-theme="dark"] .at-root {
    --at-ok: #3FBF7F;
    --at-late: #E8A33D;
    --at-early: #F08A4B;
    --at-abs: #E5534B;
    --at-miss: #C678DD;
    --at-half: #5AA8FF;
    --at-leave: #4FB3D9;
    --at-hol: #7E8CFF;
    --at-satoff: #3CC7B5;
    --at-short: #EF7A7A;
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme]) .at-root {
        --at-ok: #3FBF7F;
        --at-late: #E8A33D;
        --at-early: #F08A4B;
        --at-abs: #E5534B;
        --at-miss: #C678DD;
        --at-half: #5AA8FF;
        --at-leave: #4FB3D9;
        --at-hol: #7E8CFF;
        --at-satoff: #3CC7B5;
        --at-short: #EF7A7A;
    }
}

/* ---- the page ---------------------------------------------------------------------------------------------------- */

.at-page { display: flex; flex-direction: column; min-height: 0; height: 100%; overflow: hidden; color: var(--text); }
.at-scroll { flex: 1; min-height: 0; overflow: auto; padding: 12px 16px 24px; }
.at-top { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
    .at-top h1 { margin: 0 10px 0 0; font-size: 18px; display: inline-flex; align-items: center; gap: 8px; }
.at-grow { flex: 1; }
.at-tabs { display: flex; flex-wrap: wrap; gap: 4px; }
    .at-tabs button { border: 1px solid transparent; background: transparent; color: var(--muted); font: inherit; font-size: 13px; font-weight: 600; padding: 5px 11px; border-radius: 7px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
        .at-tabs button:hover { background: var(--hover); color: var(--text); }
        .at-tabs button.on { background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent); border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
    .at-tabs .at-count { color: var(--at-miss); font-weight: 700; }
.at-btn { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 11px; border: 1px solid var(--border); border-radius: 7px; background: var(--surface); color: var(--text); font: inherit; font-size: 13px; cursor: pointer; white-space: nowrap; text-decoration: none; }
    .at-btn:hover { background: var(--hover); }
    .at-btn .icon { width: 15px; height: 15px; }
.at-lock { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 11px; border-radius: 7px; font-size: 12.5px; font-weight: 600; color: var(--at-ok); border: 1px solid color-mix(in srgb, var(--at-ok) 45%, transparent); background: color-mix(in srgb, var(--at-ok) 12%, transparent); }
    .at-lock .icon { width: 14px; height: 14px; }
/* The month's salary is published to Accounts (24 Oct 2026): nothing about its attendance changes any more. */
.at-lock.at-salary-lock { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 45%, transparent); background: color-mix(in srgb, var(--accent) 10%, transparent); }
.at-flag.at-salary-locked { display: flex; align-items: flex-start; gap: 6px; color: var(--accent); border-color: color-mix(in srgb, var(--accent) 40%, transparent); background: color-mix(in srgb, var(--accent) 8%, transparent); }
    .at-flag.at-salary-locked .icon { width: 14px; height: 14px; flex: none; margin-top: 1px; }
.at-menu { position: relative; }
    .at-menu > summary { list-style: none; }
    .at-menu > summary::-webkit-details-marker { display: none; }
    .at-menu .at-menu-list { position: absolute; right: 0; top: 34px; z-index: 30; min-width: 250px; background: var(--surface); border: 1px solid var(--border); border-radius: 9px; padding: 5px; box-shadow: 0 8px 26px rgba(0, 0, 0, .18); display: flex; flex-direction: column; }
        .at-menu .at-menu-list a { padding: 7px 10px; border-radius: 6px; color: var(--text); text-decoration: none; font-size: 13px; display: flex; align-items: center; gap: 8px; }
            .at-menu .at-menu-list a:hover { background: var(--hover); }
            .at-menu .at-menu-list a small { color: var(--muted); margin-left: auto; }

.at-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 9px 16px; border-bottom: 1px solid var(--line); }
.at-f { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 4px 0 10px; border: 1px solid var(--border); border-radius: 7px; background: var(--surface); color: var(--text); font-size: 13px; max-width: 100%; }
    .at-f > small { color: var(--muted); font-size: 11.5px; }
    .at-f input, .at-f select { border: 0; background: transparent; color: var(--text); font: inherit; font-size: 13px; height: 30px; min-width: 0; outline-offset: 0; }
    .at-f.search { width: min(240px, 100%); }
        .at-f.search input { flex: 1; }
    .at-f .icon { width: 14px; height: 14px; color: var(--muted); }
.at-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.at-chip { padding: 3px 10px; border-radius: 999px; font: inherit; font-size: 12px; border: 1px solid var(--border); color: var(--muted); background: transparent; cursor: pointer; }
    .at-chip:hover { color: var(--text); }
    .at-chip.on { --c: var(--at-late); color: var(--c); border-color: color-mix(in srgb, var(--c) 50%, transparent); background: color-mix(in srgb, var(--c) 12%, transparent); }
    .at-chip.on.ng { --c: var(--at-miss); }
    .at-chip b { font-weight: 600; margin-left: 3px; }

.at-note { color: var(--muted); font-size: 12.5px; margin: 0 0 10px; }
.at-empty { color: var(--muted); font-size: 13px; padding: 18px; }

/* ---- KPI cards ----------------------------------------------------------------------------------------------------- */

.at-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-bottom: 12px; }
.at-k { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 9px 12px; min-width: 0; }
    .at-k small { color: var(--muted); font-size: 12px; }
    .at-k b { display: block; font-size: 20px; margin-top: 3px; font-variant-numeric: tabular-nums; }
    .at-k i { display: block; font-style: normal; font-size: 11.5px; color: var(--muted); margin-top: 2px; }
    .at-k .up { color: var(--at-ok); }
    .at-k .dn { color: var(--at-abs); }
    .at-k b.ng { color: var(--at-miss); }

/* ---- Month: the grid ------------------------------------------------------------------------------------------------ */

.at-wrap { display: flex; gap: 12px; align-items: flex-start; }
.at-main { flex: 1; min-width: 0; background: var(--surface); border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.at-gridwrap { overflow-x: auto; }
.at-grid { border-collapse: separate; border-spacing: 2px; font-size: 12px; }
    .at-grid th { font-size: 10.5px; color: var(--muted); font-weight: 600; padding: 4px 0; text-align: center; min-width: 31px; }
        .at-grid th span { display: block; font-size: 9px; opacity: .75; }
        .at-grid th.we { opacity: .55; }
        .at-grid th.today { color: var(--accent); }
        .at-grid th.emp { text-align: left; padding-left: 8px; min-width: 180px; position: sticky; left: 0; background: var(--surface); z-index: 2; }
    .at-grid td.emp { position: sticky; left: 0; z-index: 1; background: var(--surface); padding: 3px 6px; min-width: 180px; }
.at-emp { display: flex; gap: 8px; align-items: center; min-width: 0; }
    .at-emp > div { min-width: 0; flex: 1; }
    .at-emp b { font-size: 12.5px; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; overflow-wrap: anywhere; line-height: 1.25; }
    .at-emp small { display: block; color: var(--muted); font-size: 10.5px; white-space: nowrap; }
.at-av { width: 26px; height: 26px; flex: none; border-radius: 50%; display: grid; place-items: center; font-size: 10px; font-weight: 700; background: color-mix(in srgb, var(--accent) 16%, transparent); color: var(--accent); }
.at-grid tr.sel td.emp { box-shadow: inset 3px 0 0 var(--accent); }

.at-c { width: 31px; height: 30px; border-radius: 5px; text-align: center; line-height: 1; border: 1px solid transparent; padding: 0; vertical-align: middle; }
    .at-c b { display: block; font-size: 11px; }
    .at-c i { display: block; font-style: normal; font-size: 8.5px; opacity: .9; margin-top: 2px; white-space: nowrap; }
    .at-c.click { cursor: pointer; }
        .at-c.click:hover { filter: brightness(1.08); outline: 1px solid color-mix(in srgb, var(--accent) 50%, transparent); }
    .at-c.on { outline: 2px solid var(--accent); outline-offset: 0; }
.at-root :is(.ok, .late, .early, .abs, .miss, .half, .leave, .hol, .satoff) { background: color-mix(in srgb, var(--c) 15%, transparent); color: var(--c); border-color: color-mix(in srgb, var(--c) 35%, transparent) !important; }
.at-root .ok { --c: var(--at-ok); }
.at-root .late { --c: var(--at-late); }
.at-root .early { --c: var(--at-early); }
.at-root .abs { --c: var(--at-abs); }
.at-root .miss { --c: var(--at-miss); }
.at-root .half { --c: var(--at-half); }
.at-root .leave { --c: var(--at-leave); }
.at-root .hol { --c: var(--at-hol); }
.at-root .satoff { --c: var(--at-satoff); }
.at-c.rest { background: var(--at-rest); color: var(--muted); }
.at-c.future { background: transparent; border: 1px dashed var(--border); }
.at-c.none { background: transparent; color: var(--faint); }
.at-num { text-align: right; padding: 0 6px; font-variant-numeric: tabular-nums; white-space: nowrap; }
    .at-num.lt { color: var(--at-late); }
    .at-num.ab { color: var(--at-abs); }
    .at-num.neg { color: var(--at-short); }
    .at-num.pos { color: var(--at-ok); }
    .at-num.lv { color: var(--at-leave); }
    .at-num.gl { color: var(--at-ok); }
    .at-num.z { color: var(--muted); opacity: .7; }
.at-bar { display: inline-block; width: 38px; height: 5px; border-radius: 9px; background: var(--at-track); margin-right: 5px; vertical-align: middle; overflow: hidden; }
    .at-bar span { display: block; height: 100%; border-radius: 9px; background: var(--accent); }
.at-legend { display: flex; gap: 12px; flex-wrap: wrap; padding: 8px 12px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; }
    .at-legend span b { display: inline-block; width: 12px; height: 12px; border-radius: 3px; vertical-align: -2px; margin-right: 4px; border: 1px solid; }
    .at-legend .rest { background: var(--at-rest); border-color: var(--border); }

/* ---- the day's side panel ------------------------------------------------------------------------------------------ */

.at-side { width: 330px; flex: none; display: flex; flex-direction: column; gap: 12px; }
.at-card { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px; }
    .at-card h3 { margin: 0 0 2px; font-size: 15px; display: flex; align-items: center; gap: 8px; }
    .at-card h4 { margin: 0 0 8px; font-size: 13px; display: flex; align-items: center; gap: 8px; }
        .at-card h4 a { margin-left: auto; font-weight: 400; color: var(--accent); font-size: 12.5px; }
    .at-card .m { color: var(--muted); font-size: 12px; margin-bottom: 10px; }
    .at-card .x { margin-left: auto; border: 0; background: transparent; color: var(--muted); cursor: pointer; padding: 2px; }
.at-li { display: flex; justify-content: space-between; gap: 8px; padding: 5px 0; border-bottom: 1px solid var(--line); font-size: 12px; }
    .at-li:last-child { border-bottom: 0; }
    .at-li .v { color: var(--at-short); font-variant-numeric: tabular-nums; }
    .at-li button { border: 0; background: transparent; color: inherit; font: inherit; padding: 0; cursor: pointer; text-align: left; }
.at-rules div { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; padding: 3px 0; color: var(--muted); }
    .at-rules b { color: var(--text); font-weight: 600; text-align: right; }
.at-punches { list-style: none; padding: 0; margin: 10px 0; }
    .at-punches li { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 5px 0; border-bottom: 1px solid var(--line); font-size: 12px; }
    .at-punches .t { font-variant-numeric: tabular-nums; margin-right: 6px; }
.at-pill { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; border-radius: 999px; font-size: 11px; font-weight: 600; border: 1px solid; white-space: nowrap; line-height: 17px; }
    .at-pill.in { --c: var(--at-ok); }
    .at-pill.out { --c: var(--at-half); }
    .at-pill.ng { --c: var(--at-miss); }
    .at-pill.sh { --c: var(--at-short); }
    .at-pill.lt { --c: var(--at-late); }
    .at-pill.good { --c: var(--at-ok); }
    .at-pill.miss { --c: var(--at-miss); }
    .at-pill.in, .at-pill.out, .at-pill.ng, .at-pill.sh, .at-pill.lt, .at-pill.good, .at-pill.miss { color: var(--c); border-color: color-mix(in srgb, var(--c) 45%, transparent); background: color-mix(in srgb, var(--c) 12%, transparent); }
.at-sum { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-top: 10px; }
    .at-sum div { background: var(--surface-2); border-radius: 8px; padding: 7px 9px; }
    .at-sum small { color: var(--muted); display: block; font-size: 10.5px; }
    .at-sum b { font-variant-numeric: tabular-nums; }
.at-flag { margin-top: 8px; padding: 7px 10px; border-radius: 8px; font-size: 12px; color: var(--at-miss); border: 1px solid color-mix(in srgb, var(--at-miss) 45%, transparent); background: color-mix(in srgb, var(--at-miss) 10%, transparent); }
    .at-flag.mute { color: var(--muted); border-color: var(--border); background: var(--surface-2); }
.lt-t { color: var(--at-late); font-weight: 600; }

/* ---- timelines (08:00 to 20:00) -------------------------------------------------------------------------------------- */

.at-tl { position: relative; height: 16px; background: var(--at-track); border-radius: 4px; overflow: hidden; }
    .at-tl.big { height: 44px; border-radius: 8px; margin: 8px 0 4px; }
    .at-tl .sg { position: absolute; top: 2px; bottom: 2px; border-radius: 3px; }
    .at-tl.big .sg { top: 9px; bottom: 9px; border-radius: 5px; }
    .at-tl .sg.in { background: color-mix(in srgb, var(--at-ok) 55%, transparent); }
    .at-tl.big .sg.in { background: color-mix(in srgb, var(--at-ok) 30%, transparent); border: 1px solid color-mix(in srgb, var(--at-ok) 60%, transparent); }
    .at-tl .sg.out { background: color-mix(in srgb, var(--muted) 35%, transparent); }
    .at-tl .sg.quick { background: var(--at-late); }
    .at-tl .sg.hidden { background: repeating-linear-gradient(45deg, color-mix(in srgb, var(--at-miss) 70%, transparent) 0 3px, transparent 3px 6px); border: 1px solid var(--at-miss); }
    .at-tl .sg.open { background: transparent; border: 1px dotted var(--at-miss); }
    .at-tl .lunch { position: absolute; top: 0; bottom: 0; border-left: 1px dashed var(--at-half); border-right: 1px dashed var(--at-half); background: color-mix(in srgb, var(--at-half) 8%, transparent); pointer-events: none; }
    .at-tl .lbl { position: absolute; inset: 0; display: grid; place-items: center; font-size: 10.5px; color: var(--muted); }
.at-ticks { display: flex; justify-content: space-between; color: var(--muted); font-size: 10px; }

/* ---- Short time ------------------------------------------------------------------------------------------------------ */

.at-st { width: 100%; border-collapse: collapse; font-size: 12.5px; }
    .at-st th { text-align: left; color: var(--muted); font-size: 11px; font-weight: 600; padding: 8px 6px; border-bottom: 1px solid var(--line); white-space: nowrap; }
    .at-st tr.m > td { padding: 7px 6px; border-bottom: 1px solid var(--line); vertical-align: middle; }
    .at-st tr.m.open > td { background: color-mix(in srgb, var(--accent) 6%, transparent); }
    .at-st tr.m { cursor: pointer; }
        .at-st tr.m:hover > td { background: var(--hover); }
    .at-st .ch { color: var(--muted); width: 18px; text-align: center; }
    .at-st .neg { color: var(--at-short); }
    .at-st .pos { color: var(--at-ok); }
    .at-st .num small { color: var(--muted); margin-left: 4px; font-size: 10.5px; }
/* Short time explained (22 Oct 2026): the ⓘ on a label with a tooltip, and the one-line notes under the reports. */
.at-tip { color: var(--muted); font-size: 10px; font-weight: 400; cursor: help; }
.at-grid th[data-col=short] { white-space: nowrap; }
.at-grid th .at-tip { display: inline; }
.at-short-note { margin: 8px 12px 0; font-size: 12px; }
.at-spark { display: flex; align-items: flex-end; gap: 2px; height: 24px; }
    .at-spark i { width: 4px; min-height: 2px; background: var(--at-track); border-radius: 1px; }
        .at-spark i.s { background: var(--at-short); }
        .at-spark i.so { background: color-mix(in srgb, var(--at-satoff) 45%, transparent); }
.at-nbar { width: 120px; height: 4px; border-radius: 9px; background: var(--at-track); margin-top: 4px; overflow: hidden; }
    .at-nbar span { display: block; height: 100%; border-radius: 9px; background: var(--at-ok); }
        .at-nbar span.bad { background: var(--at-short); }
.at-flags { display: flex; gap: 5px; flex-wrap: wrap; }
.at-det { margin: 4px 0 10px; border: 1px solid var(--line); border-radius: 9px; padding: 8px 10px; background: var(--surface-2); cursor: default; }
.at-dh, .at-day { display: grid; grid-template-columns: 62px 46px minmax(140px, 1fr) 46px 44px 48px minmax(120px, 230px); gap: 8px; align-items: center; }
    .at-dh { color: var(--muted); font-size: 10.5px; padding-bottom: 6px; }
.at-day { padding: 5px 0; border-top: 1px solid var(--line); font-size: 12px; }
    .at-day .dd { color: var(--muted); }
    .at-day.k-late .dd { color: var(--at-late); }
    .at-day.k-miss .dd, .at-day.k-abs .dd { color: var(--at-abs); }
    .at-day .t { font-variant-numeric: tabular-nums; }
    .at-day .nt { color: var(--at-miss); font-size: 11px; }
    .at-day .neg { color: var(--at-short); }
    .at-day .pos { color: var(--at-ok); }
    .at-day.k-miss .at-tl { background: repeating-linear-gradient(90deg, var(--at-track) 0 6px, transparent 6px 9px); }
.at-more { color: var(--muted); font-size: 11.5px; padding-top: 6px; display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
    .at-more button { border: 0; background: transparent; color: var(--accent); font: inherit; text-decoration: underline; cursor: pointer; padding: 0; }

/* ---- Today, Exceptions, Employee --------------------------------------------------------------------------------- */

.at-tbl { width: 100%; border-collapse: collapse; font-size: 12.5px; }
    .at-tbl th { text-align: left; color: var(--muted); font-size: 11px; font-weight: 600; padding: 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
    .at-tbl td { padding: 7px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
    .at-tbl tr:last-child td { border-bottom: 0; }
.at-soon { padding: 40px 20px; text-align: center; color: var(--muted); }
    .at-soon b { display: block; color: var(--text); font-size: 15px; margin-bottom: 6px; }

/* ---- phones ------------------------------------------------------------------------------------------------------ */

@media (max-width: 1100px) {
    .at-wrap { flex-direction: column; }
    .at-side { width: 100%; }
}

@media (max-width: 640px) {
    .at-top, .at-filters { padding-left: 12px; padding-right: 12px; }
    .at-scroll { padding: 10px 12px 20px; }
    .at-kpis { grid-template-columns: 1fr 1fr; }
    .at-dh { display: none; }
    .at-day { grid-template-columns: 56px 1fr 1fr 1fr; }
        .at-day .at-tl { grid-column: 1 / -1; order: 9; }
        .at-day .nt { grid-column: 1 / -1; order: 10; }
}

/* ---- the print view ---------------------------------------------------------------------------------------------- */

.at-print { max-width: 1400px; margin: 0 auto; padding: 16px; background: var(--surface); color: var(--text); font-size: 11px; }
    .at-print h1 { font-size: 17px; margin: 6px 0 2px; }
    .at-print table { border-collapse: collapse; width: 100%; }
    .at-print th, .at-print td { border: 1px solid var(--border); padding: 2px 4px; text-align: center; font-variant-numeric: tabular-nums; }
    .at-print td.l, .at-print th.l { text-align: left; }
    .at-print td.c-ok, .at-print td.c-late, .at-print td.c-early, .at-print td.c-abs, .at-print td.c-miss, .at-print td.c-half { font-weight: 700; }
    .at-print td.c-abs { color: var(--at-abs); }
    .at-print td.c-late { color: var(--at-late); }
    .at-print td.c-miss { color: var(--at-miss); }
    .at-print td.c-satoff { color: var(--at-satoff); }

/* ---- Saturdays (the alternate-Saturday schedule, read-only here) ---------------------------------------------------- */

.at-sat-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-bottom: 10px; }
    .at-sat-head .at-note { margin: 0; flex: 1 1 260px; }
.at-satt th.c, .at-satt td.c { text-align: center; white-space: nowrap; }
.at-satt tr.tot td { color: var(--muted); font-size: 11.5px; font-variant-numeric: tabular-nums; }

@media print {
    .at-noprint { display: none !important; }
    .at-print { max-width: none; padding: 0; }
    .at-print table { page-break-inside: auto; }
    .at-print tr { page-break-inside: avoid; }
}

/* ---- filters: one focus ring (the field's), the people picker, "show unlinked" ------------------------------------ */

.at-f:focus-within { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
    .at-f input, .at-f select, .at-f input:focus, .at-f select:focus, .at-f input:focus-visible, .at-f select:focus-visible { outline: 0; box-shadow: none; border: 0; background: transparent; }
    .at-f input[type=search]::-webkit-search-decoration { -webkit-appearance: none; }
.at-check { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); }
.at-pick > summary.at-f { cursor: pointer; padding-right: 10px; }
.at-pick .at-pick-list { left: 0; right: auto; width: 300px; display: flex; flex-direction: column; gap: 6px; padding: 8px; }
    .at-pick .at-pick-list .at-f.search { width: 100%; }
.at-pick-acts { display: flex; align-items: center; gap: 8px; }
.at-pick-items { max-height: 300px; overflow: auto; display: flex; flex-direction: column; }
.at-pick-item { display: grid; grid-template-columns: auto 1fr; column-gap: 8px; padding: 5px 6px; border-radius: 6px; font-size: 13px; cursor: pointer; }
    .at-pick-item:hover { background: var(--hover); }
    .at-pick-item input { grid-row: span 2; align-self: center; }
    .at-pick-item small { color: var(--muted); font-size: 11.5px; }

/* ---- the sync check in the header ------------------------------------------------------------------------------- */

.at-sync-badge.ok { color: var(--at-ok); border-color: color-mix(in srgb, var(--at-ok) 45%, transparent); background: color-mix(in srgb, var(--at-ok) 10%, var(--surface)); }
.at-sync-badge.bad { color: var(--at-abs); border-color: color-mix(in srgb, var(--at-abs) 45%, transparent); background: color-mix(in srgb, var(--at-abs) 10%, var(--surface)); }
.at-sync-badge.none { color: var(--muted); }
.at-menu-list.at-sync { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px; min-width: 290px; font-size: 13px; }
    .at-sync .at-sync-row { display: flex; justify-content: space-between; gap: 10px; }
        .at-sync .at-sync-row small { color: var(--muted); margin-left: 4px; }
        .at-sync .at-sync-row.tot { border-top: 1px solid var(--line); padding-top: 5px; font-weight: 600; }
    .at-sync .at-note { margin: 0; }

/* ---- Day ---------------------------------------------------------------------------------------------------------- */

.at-daybar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 12px; border-radius: 8px; }
    .at-daybar:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
    .at-daybar input[type=date] { height: 30px; border: 1px solid var(--border); border-radius: 7px; background: var(--surface); color: var(--text); font: inherit; font-size: 13px; padding: 0 8px; }
    .at-daybar .at-btn:disabled { opacity: .5; cursor: default; }
.at-dayname { font-size: 14px; margin-left: 4px; }
.at-daysum { grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); }
    .at-daysum button.at-k { text-align: left; font: inherit; color: var(--text); cursor: pointer; }
        .at-daysum button.at-k:hover { background: var(--hover); }
        .at-daysum button.at-k.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.at-dayt tr.click { cursor: pointer; }
    .at-dayt tr.sel td { background: color-mix(in srgb, var(--accent) 7%, transparent); }
    .at-dayt td.neg { color: var(--at-short); font-weight: 600; }
    .at-dayt td.pos { color: var(--at-ok); }
.at-pill.st { --c: var(--muted); color: var(--c); border-color: color-mix(in srgb, var(--c) 45%, transparent); background: color-mix(in srgb, var(--c) 12%, transparent); }
    .at-pill.st.ok { --c: var(--at-ok); }
    .at-pill.st.late { --c: var(--at-late); }
    .at-pill.st.early { --c: var(--at-early); }
    .at-pill.st.half { --c: var(--at-half); }
    .at-pill.st.miss { --c: var(--at-miss); }
    .at-pill.st.abs { --c: var(--at-abs); }
    .at-pill.st.leave { --c: var(--at-leave); }
    .at-pill.st.hol { --c: var(--at-hol); }
    .at-pill.st.satoff { --c: var(--at-satoff); }
.at-tl .tk { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: var(--text); opacity: .7; }
    .at-tl .tk.out { background: var(--at-half); }

/* ---- Leave (HR -> Leave): balances as tinted pills, used-of-allowed bars, the admin import and forms --------------- */

.at-lv { color: var(--at-leave) !important; font-weight: 600; }
.lv-inline { margin: 0; display: inline; }
.lv-red { color: var(--at-short); }
.lv-msg { font-size: 12.5px; margin: 8px 0; padding: 6px 10px; border-radius: 7px; border: 1px solid; --c: var(--muted); color: var(--c); border-color: color-mix(in srgb, var(--c) 40%, transparent); background: color-mix(in srgb, var(--c) 10%, transparent); }
    .lv-msg.ok { --c: var(--at-ok); }
    .lv-msg.bad { --c: var(--at-short); }
    .lv-msg.warn { --c: var(--at-late); }
.lv-acts { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 8px 0; }
.lv-pri { background: var(--accent); border-color: var(--accent); color: #fff; font-weight: 600; }
    .lv-pri:hover { background: var(--accent); filter: brightness(1.08); }
.lv-file { position: relative; overflow: hidden; }
    .lv-file input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.lv-admin { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 10px; margin-bottom: 10px; }
.lv-import { flex: 1 1 100%; }
    .lv-import > summary { list-style: none; width: max-content; }
    .lv-import > summary::-webkit-details-marker { display: none; }
    .lv-import-body { margin-top: 8px; }
.lv-file-card { border: 1px solid var(--border); border-radius: 9px; padding: 10px 12px; margin: 10px 0; }
    .lv-file-card header { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 6px; }
.lv-counts { display: flex; flex-wrap: wrap; gap: 14px; font-size: 12.5px; color: var(--muted); margin: 4px 0 8px; }
    .lv-counts b { color: var(--text); font-variant-numeric: tabular-nums; }
    .lv-counts .lv-warn b { color: var(--at-late); }
.lv-preview { max-height: 340px; overflow: auto; border: 1px solid var(--line); border-radius: 8px; }
.lv-skipped ul { margin: 6px 0 0; padding-left: 18px; font-size: 12px; color: var(--muted); }
.lv-tbl .n, .lv-preview .n { text-align: right; font-variant-numeric: tabular-nums; }
.at-tbl .mono { font-variant-numeric: tabular-nums; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }
.lv-default { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 13px; }
    .lv-default .at-f input { width: 64px; }
.lv-tbl tr.click { cursor: pointer; }
    .lv-tbl tr.click:hover td { background: var(--hover); }
    .lv-tbl tr.sel td { background: color-mix(in srgb, var(--accent) 7%, transparent); }
    .lv-tbl .at-pill[data-unknown] { margin-top: 4px; }
.lv-chev { color: var(--muted); width: 20px; text-align: center; }
.lv-used { display: inline-flex; align-items: center; gap: 2px; white-space: nowrap; font-variant-numeric: tabular-nums; }
    .lv-used small { color: var(--muted); }
.lv-bar { width: 54px; }
    .lv-bar span { background: var(--at-ok); }
    .lv-bar.lv-few span { background: var(--at-late); }
    .lv-bar.lv-over span { background: var(--at-short); }
.lv-detail > td { background: color-mix(in srgb, var(--accent) 3%, transparent); padding: 10px 12px 12px; }
.lv-months { border-collapse: collapse; font-size: 12px; margin-bottom: 6px; }
    .lv-months th, .lv-months td { padding: 4px 8px; text-align: center; min-width: 34px; border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums; }
    .lv-months th { color: var(--muted); font-weight: 600; font-size: 11px; }
    .lv-months td.adj { text-decoration: underline dotted; text-underline-offset: 3px; }
.lv-forms { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; cursor: default; }
.lv-form { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 12.5px; }
    .lv-form > b { min-width: 130px; }
    .lv-form .at-f input[type=number] { width: 60px; }
    .lv-form .lv-reason { flex: 1 1 220px; }
        .lv-form .lv-reason input { flex: 1; }
.lv-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; margin-bottom: 8px; }
.lv-big { --c: var(--at-ok); background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; }
    .lv-big.lv-few { --c: var(--at-late); }
    .lv-big.lv-over { --c: var(--at-short); }
    .lv-big > small { color: var(--muted); font-size: 12.5px; font-weight: 600; }
    .lv-big > b { font-size: 30px; line-height: 1.1; font-variant-numeric: tabular-nums; }
        .lv-big > b .of { font-size: 14px; font-weight: 500; color: var(--muted); }
    .lv-big .at-pill { align-self: flex-start; color: var(--c); }
.lv-meter { height: 8px; border-radius: 9px; background: var(--at-track); overflow: hidden; }
    .lv-meter span { display: block; height: 100%; border-radius: 9px; background: var(--c); }
.lv-monthlist { max-width: 520px; }

/* ---- team groups (Day, Month, Short time, Leave, Exceptions): a tinted header row per team, a click closes it -------- */

.at-teambar { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
tr.at-team { cursor: pointer; }
    tr.at-team > td { background: color-mix(in srgb, var(--accent) 9%, var(--surface)); border-top: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); border-bottom: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); padding: 6px 8px; font-size: 12.5px; }
    tr.at-team:hover > td { background: color-mix(in srgb, var(--accent) 14%, var(--surface)); }
    tr.at-team > td.at-num { font-weight: 700; color: var(--accent); }
    tr.at-team > td.at-num.neg { color: var(--at-short); }
.at-team-h { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; position: sticky; left: 0; width: max-content; max-width: 100%; }
    .at-team-h b { color: var(--accent); font-size: 13px; }
    .at-team-h small { color: var(--muted); font-size: 11.5px; }
.at-team-sum { color: var(--text); font-size: 12px; font-variant-numeric: tabular-nums; }
    .at-team-sum .lv-red { color: var(--at-abs); font-weight: 600; }
.at-team-btn { border: 0; background: transparent; color: var(--accent); font: inherit; font-size: 11px; width: 18px; padding: 0; cursor: pointer; }
.at-grid tr.at-team > td { border-radius: 5px; }

/* ---- former employees (admins and HR only) and leave eligibility ------------------------------------------------- */

.at-pill.former { --c: var(--muted); color: var(--c); border-color: color-mix(in srgb, var(--c) 45%, transparent); background: color-mix(in srgb, var(--c) 12%, transparent); margin-left: 6px; font-size: 10px; padding: 0 6px; line-height: 15px; vertical-align: middle; }
.at-emp b .at-pill.former { display: inline-flex; }
.lv-join { display: block; color: var(--muted); font-size: 11px; margin-top: 2px; }
.lv-months td.early { box-shadow: inset 0 -2px 0 var(--at-late); color: var(--at-late); font-weight: 600; }

/* HR's day adjustments (20 Oct 2026): the "Adjusted" pill and the corner mark on a Month cell use the accent, tinted, so
   they read in light and dark; the adjust form lists the range's days before saving. */
.at-pill.adj { --c: var(--accent); color: var(--c); border-color: color-mix(in srgb, var(--c) 45%, transparent); background: color-mix(in srgb, var(--c) 12%, transparent); margin-left: 4px; }
.at-c.adj { position: relative; }
    .at-c.adj::after { content: ""; position: absolute; top: 2px; right: 2px; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); }
.at-adj { margin-top: 10px; }
    .at-adj h4 { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; }
    .at-adj h4 .x { margin-left: auto; border: 0; background: none; color: var(--muted); cursor: pointer; }
.at-adj-grid { display: flex; flex-wrap: wrap; gap: 8px; }
    .at-adj-grid .at-adj-reason { flex: 1 1 220px; }
        .at-adj-grid .at-adj-reason input { flex: 1; }
/* The range's days (21 Oct 2026): a compact list in columns that grows with the page (user: no box scrolling inside the
   page), each day with its tick; a day that stays as it is is muted; an added date has a dashed accent edge. */
.at-adj-pickbar { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin-top: 10px; font-size: 12.5px; }
    .at-adj-pickbar > b { font-weight: 600; }
    .at-adj-pickbar .grow { flex: 1; }
    .at-adj-pickbar .at-btn.sm { height: 26px; padding: 0 9px; font-size: 12px; }
    .at-adj-pickbar .at-btn:disabled { opacity: .5; cursor: default; }
    .at-adj-add input { width: 140px; }
.at-adj-days { list-style: none; margin: 6px 0 0; padding: 0; font-size: 12.5px; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(250px, 100%), 1fr)); gap: 0 18px; }
    .at-adj-days li { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; padding: 4px 2px; border-bottom: 1px solid var(--line); min-width: 0; }
    .at-adj-days li.skip { color: var(--muted); }
    .at-adj-days li.extra { box-shadow: inset 2px 0 0 color-mix(in srgb, var(--accent) 60%, transparent); padding-left: 6px; }
    .at-adj-days .ck { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
        .at-adj-days .ck input { margin: 0; accent-color: var(--accent); }
        .at-adj-days .ck input:disabled { cursor: default; }
    .at-adj-days .d { min-width: 82px; font-weight: 600; }
    .at-adj-days li.skip .d { font-weight: 500; }
    .at-adj-days .c { color: var(--muted); min-width: 0; overflow-wrap: anywhere; }
    .at-adj-days .at-note { margin: 0; font-size: 12px; }
    .at-adj-days .x { margin-left: auto; border: 0; background: none; color: var(--muted); cursor: pointer; padding: 0 2px; }
        .at-adj-days .x .icon { width: 13px; height: 13px; }
    .at-adj-days select.at-adj-to { font: inherit; font-size: 11px; font-weight: 600; height: 20px; padding: 0 4px; margin-left: auto; cursor: pointer; max-width: 100%; }
.at-adj-short { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 8px; padding: 7px 10px; border-radius: 8px; font-size: 12.5px;
    color: var(--at-late); border: 1px solid color-mix(in srgb, var(--at-late) 45%, transparent); background: color-mix(in srgb, var(--at-late) 10%, transparent); }
    .at-adj-short .at-btn.on { outline: 2px solid var(--accent); }
.at-adj .at-acts { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 10px; }
.at-adj-existing { margin-top: 10px; display: flex; flex-direction: column; gap: 4px; font-size: 12.5px; }
    .at-adj-existing > small { color: var(--muted); }
.lv-manual { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 4px; }
.at-adj .at-btn.pri { background: var(--accent); border-color: var(--accent); color: var(--on-accent, #fff); }
.at-adj .at-btn:disabled { opacity: .5; cursor: default; }
/* Staff requests to adjust an absent day (21 Oct 2026): status chips tinted (tint fill, saturated text, 1px border) -
   pending amber, approved green, rejected red, cancelled muted; the request items, the admin's decision row, the form. */
.at-pill.rq { --c: var(--muted); color: var(--c); border-color: color-mix(in srgb, var(--c) 45%, transparent); background: color-mix(in srgb, var(--c) 12%, transparent); }
    .at-pill.rq.pending { --c: var(--at-late); }
    .at-pill.rq.approved { --c: var(--at-ok); }
    .at-pill.rq.rejected { --c: var(--at-abs); }
.at-rqs { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }
.at-rq-item { padding: 8px 10px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); font-size: 12.5px; min-width: 0; }
    .at-rq-head { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
    .at-rq-who small { color: var(--muted); font-weight: 500; margin-left: 4px; }
    .at-rq-hours { color: var(--muted); }
    .at-rq-reason { margin-top: 4px; overflow-wrap: anywhere; }
    .at-rq-notes { margin-top: 2px; color: var(--muted); white-space: pre-wrap; overflow-wrap: anywhere; }
    .at-rq-comment { margin-top: 6px; padding: 5px 8px; border-radius: 7px; border: 1px solid; --c: var(--muted); color: var(--c); border-color: color-mix(in srgb, var(--c) 40%, transparent); background: color-mix(in srgb, var(--c) 10%, transparent); overflow-wrap: anywhere; }
        .at-rq-comment.rejected { --c: var(--at-abs); }
        .at-rq-comment.approved { --c: var(--at-ok); }
    .at-rq-when { display: block; margin: 4px 0 0; font-size: 11.5px; }
    .at-rq-item .at-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.at-rq-decide { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--line); }
    .at-rq-decide .at-btn.pri { background: var(--accent); border-color: var(--accent); color: var(--on-accent, #fff); }
    .at-rq-decide .at-btn.bad { --c: var(--at-abs); color: var(--c); border-color: color-mix(in srgb, var(--c) 50%, transparent); background: color-mix(in srgb, var(--c) 10%, transparent); }
    .at-rq-decide .at-btn:disabled { opacity: .5; cursor: default; }
    .at-rq-decide .at-rq-comment-in { flex: 1 1 220px; }
        .at-rq-decide .at-rq-comment-in input { flex: 1; }
    .at-rq-decide .lv-msg { margin: 0; }
/* Adjust days: a day's worked hours and optional off-site From–To (24 Oct 2026). */
.at-adj-hours { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; flex-basis: 100%; padding: 2px 0 2px 22px; }
    .at-adj-hours .at-f.sm { height: 26px; padding-left: 7px; }
        .at-adj-hours .at-f.sm select, .at-adj-hours .at-f.sm input { height: 24px; font-size: 12px; }
        .at-adj-hours .at-f.sm input[type=time] { width: 84px; }
        .at-adj-hours .at-f.sm select:disabled { opacity: .7; }
.at-pill.hrs { margin: 0 4px; --c: var(--accent); color: var(--c); border-color: color-mix(in srgb, var(--c) 45%, transparent); background: color-mix(in srgb, var(--c) 12%, transparent); font-variant-numeric: tabular-nums; }
.at-tl .sg.dadj { background: repeating-linear-gradient(135deg, color-mix(in srgb, var(--accent) 28%, transparent) 0 4px, color-mix(in srgb, var(--accent) 10%, transparent) 4px 8px);
    border: 1px dashed color-mix(in srgb, var(--accent) 70%, transparent); }
.at-tl.big .sg.dadj { top: 4px; bottom: 4px; }
.at-tl .hrs-tag { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); font-size: 10.5px; font-weight: 600; padding: 0 6px; border-radius: 9px; line-height: 16px;
    color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, var(--surface)); border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent); pointer-events: none; }
.at-rq-days li { gap: 4px 8px; }
    .at-rq-days .at-f.sm { height: 26px; padding-left: 7px; }
        .at-rq-days .at-f.sm select, .at-rq-days .at-f.sm input { height: 24px; font-size: 12px; }
.at-rq-form .at-rq-text { margin-top: 10px; }
.at-rq-notes-in { display: flex; flex-direction: column; gap: 4px; margin-top: 8px; font-size: 12px; color: var(--muted); }
    .at-rq-notes-in textarea { font: inherit; font-size: 13px; color: var(--text); background: var(--surface); border: 1px solid var(--border); border-radius: 7px; padding: 6px 8px; resize: vertical; min-height: 44px; }
.at-rq-tab { display: flex; flex-direction: column; gap: 12px; }
    .at-rq-tab h4 .at-count { color: var(--at-late); font-weight: 700; }
    .at-rq-tab h4 .at-btn { margin-left: auto; }
    .at-rq-tab .at-btn.pri { background: var(--accent); border-color: var(--accent); color: var(--on-accent, #fff); }
    .at-rq-tab .at-btn:disabled { opacity: .5; cursor: default; }
.at-rq-list { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
    .at-rq-list > li { display: flex; align-items: flex-start; gap: 8px; min-width: 0; }
        .at-rq-list > li > .at-rq-item { flex: 1; }
    .at-rq-tick { margin-top: 12px; accent-color: var(--accent); }
.at-c.rq { position: relative; }
    .at-c.rq::before { content: ""; position: absolute; bottom: 2px; right: 2px; width: 5px; height: 5px; border-radius: 50%; background: var(--at-late); }


/* ---- fits the page (user, 20 Oct 2026: no sideways scroll at 1000 px and wider) ----------------------------------------
   The page and the Month card are size containers. The day panel sits beside the grid while the page is wide enough and
   goes under it when it isn't; the grid's day cells narrow step by step, the arrival times under the letters go at the
   narrowest step and Late / Abs fold into the Days cell. Below that the grid scrolls inside its card (the last resort),
   never taller than the window, so its scrollbar stays in view. */
.at-scroll { container: atpage / size; }
/* The day's side panel stays in view while the grid scrolls under it (a bottom row's day opens beside it, not at the
   top of a long page); taller than the window, it scrolls on its own. Under the grid (narrow pages) it scrolls with it. */
.at-side { position: sticky; top: 0; max-height: 100cqh; overflow-y: auto; overscroll-behavior: contain; }
    .at-side > * { flex-shrink: 0; }
.at-main { container: atmain / inline-size; }
.at-gridwrap { overflow: auto; overscroll-behavior-x: contain; }
    .at-gridwrap > table > thead th { position: sticky; top: 0; z-index: 2; background: var(--surface); }
    .at-gridwrap > .at-grid > thead th.emp { z-index: 3; }
.at-lo-in { display: none; }
    .at-lo-in .lt { color: var(--at-late); }
    .at-lo-in .ab { color: var(--at-abs); }
    .at-lo-in .lv { color: var(--at-leave); }
@container atpage (max-width: 1500px) {
    .at-side { width: 300px; }
}
@container atpage (max-width: 1100px) {
    .at-wrap { flex-direction: column; align-items: stretch; }
    .at-side { width: 100%; position: static; max-height: none; overflow: visible; }
}
@container atmain (max-width: 1400px) {
    .at-grid th:not(.emp) { min-width: 27px; }
    .at-grid .at-c { width: 27px; }
    .at-grid th.emp, .at-grid td.emp { min-width: 160px; }
}
@container atmain (max-width: 1240px) {
    .at-grid { border-spacing: 1px; }
    .at-grid th:not(.emp) { min-width: 25px; }
    .at-grid .at-c { width: 25px; }
    .at-grid .at-c i { font-size: 8px; }
    .at-grid th.emp, .at-grid td.emp { min-width: 140px; }
    .at-grid .at-emp { max-width: 170px; }
    .at-grid .at-num { padding: 0 4px; }
    .at-grid .at-bar { width: 24px; }
}
@container atmain (max-width: 1120px) {
    .at-grid th:not(.emp) { min-width: 22px; }
    .at-grid .at-c { width: 22px; height: 26px; }
    .at-grid .at-c i { display: none; }
    .at-grid .at-av { display: none; }
    .at-grid th.emp, .at-grid td.emp { min-width: 120px; }
    .at-grid .at-emp { max-width: 150px; }
    .at-grid .at-lo { display: none; }
    .at-grid .at-lo-in { display: block; font-size: 10px; white-space: nowrap; }
    .at-grid .at-bar { display: none; }
}
@container atmain (max-width: 960px) {
    .at-grid th:not(.emp) { min-width: 19px; font-size: 10px; }
    .at-grid th span { font-size: 8px; }
    .at-grid .at-c { width: 19px; }
    .at-grid .at-c b { font-size: 10px; }
    .at-grid th.emp, .at-grid td.emp { min-width: 100px; }
    .at-grid .at-emp { max-width: 120px; }
}

/* Time adjustments and the adjust forms' reason box (23 Oct 2026): a band of time worked outside the office on the day's
   line (tinted and hatched, under the in-office spans), a short bar along the bottom of the grid cell, a tinted pill; the
   reason a 2-3 line box styled like the other fields; "Adjust days / Adjust time" as a pair of toggles. */
.at-tl .sg.adj { background: repeating-linear-gradient(135deg, color-mix(in srgb, var(--at-half) 30%, transparent) 0 4px, color-mix(in srgb, var(--at-half) 12%, transparent) 4px 8px);
    border: 1px dashed color-mix(in srgb, var(--at-half) 70%, transparent); }
.at-tl.big .sg.adj { top: 4px; bottom: 4px; }
.at-c.tadj { box-shadow: inset 0 -3px 0 color-mix(in srgb, var(--at-half) 85%, transparent); }
.at-legend b.tadj { background: color-mix(in srgb, var(--at-half) 15%, transparent); border-color: var(--at-half); box-shadow: inset 0 -2px 0 var(--at-half); }
.at-pill.tadj { --c: var(--at-half); color: var(--c); border-color: color-mix(in srgb, var(--c) 45%, transparent); background: color-mix(in srgb, var(--c) 12%, transparent); }
.at-ta { display: flex; flex-direction: column; gap: 4px; margin-top: 8px; font-size: 12px; color: var(--muted); }
    .at-ta > small { font-size: 11.5px; }
    .at-ta textarea { font: inherit; font-size: 13px; color: var(--text); background: var(--surface); border: 1px solid var(--border); border-radius: 7px; padding: 6px 10px;
        resize: vertical; min-height: 44px; width: 100%; box-sizing: border-box; line-height: 1.4; }
    .at-ta textarea:focus { outline: 0; border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.at-modes { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
    .at-modes .at-btn.on { border-color: var(--accent); color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, transparent); }
.at-adj-override { flex-basis: 100%; color: var(--text); }
    .at-adj-override input { accent-color: var(--accent); }
.at-tadj .at-f input[type=time] { width: 92px; }

/* A punch moved by a clock correction (24 Oct 2026): the machine's own stamp is in the title. */
.at-pill.corr { margin-left: 4px; --c: var(--at-half); color: var(--c); border-color: color-mix(in srgb, var(--c) 45%, transparent); background: color-mix(in srgb, var(--c) 12%, transparent); font-variant-numeric: tabular-nums; }

/* Paid days (26 Oct 2026): the days the month's salary counts (days only, never an amount). The header says "so far" in
   the running month; a pending unused Saturday allowance is a small "+N?"; a finalized run that no longer matches the
   attendance gets an amber "changed" pill. */
.at-grid th[data-col=paid] { white-space: nowrap; }
    .at-grid th[data-col=paid] .at-sofar { display: block; font-size: 8.5px; font-weight: 500; color: var(--muted); line-height: 1; }
.at-num.pd { font-weight: 600; }
.at-pend { font-size: 8.5px; font-weight: 500; color: var(--muted); margin-left: 1px; cursor: help; }
.at-pill.chg { --c: var(--at-late); color: var(--c); border-color: color-mix(in srgb, var(--c) 45%, transparent); background: color-mix(in srgb, var(--c) 12%, transparent);
    margin-left: 4px; font-size: 9.5px; padding: 0 5px; line-height: 14px; }
.at-k[data-kpi=paid] .at-sofar { font-size: 11px; font-weight: 500; color: var(--muted); margin-left: 4px; }
