/* Parklio HR. One column of content, a left rail on desktop, a bottom tab bar on phones.
   Change --accent (and its dark value) to the Parklio brand colour to rebrand everything. */
@font-face{font-family:Manrope;src:url(fonts/manrope-latin-ext-wght-normal.woff2) format("woff2");font-weight:200 800;font-display:swap;unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:Manrope;src:url(fonts/manrope-latin-wght-normal.woff2) format("woff2");font-weight:200 800;font-display:swap;unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}

:root{
  --canvas:#f2f4f3;--surface:#ffffff;--ink:#14201c;--mute:#5e6a65;--line:#e1e5e3;
  --accent:#1f4fd8;--accent-soft:#e6ecfd;--on-accent:#ffffff;
  --go:#1b8553;--go-soft:#e3f4eb;--stop:#c0362c;--stop-soft:#fbe9e7;--wait:#9a6a0b;--wait-soft:#fbf1d9;--wfh:#6b45c4;--wfh-soft:#eee8fb;
  --av-l:90%;--av-t:30%;
  --r:16px;--r-sm:10px;--shadow:0 1px 2px rgba(20,32,28,.05),0 8px 24px -12px rgba(20,32,28,.12);
  --font:Manrope,system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;
  color-scheme:light;
}
@media (prefers-color-scheme:dark){:root{
  --canvas:#0f1513;--surface:#18201d;--ink:#e9eeec;--mute:#9ba7a2;--line:#2a3430;
  --accent:#7fa2ff;--accent-soft:#1c2a4e;--on-accent:#0f1513;
  --go:#5bc892;--go-soft:#143024;--stop:#f0857c;--stop-soft:#3a1b18;--wait:#e3b656;--wait-soft:#3a2e12;--wfh:#b39cf0;--wfh-soft:#2a2145;
  --av-l:24%;--av-t:82%;--shadow:none;color-scheme:dark;
}}

*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;background:var(--canvas);color:var(--ink);font:500 16px/1.5 var(--font)}
a{color:var(--accent);text-decoration:none}
a:hover{text-decoration:underline}
:focus-visible{outline:2px solid var(--accent);outline-offset:2px;border-radius:6px}
h1{font-size:28px;line-height:1.2;font-weight:800;letter-spacing:-.02em;margin:0;text-wrap:balance}
h2{font-size:17px;font-weight:700;margin:0}
p{margin:0}
.i{width:20px;height:20px;flex:none;stroke:currentColor;fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.mute{color:var(--mute);font-size:14px}
.warn{color:var(--wait);font-size:14px}

/* ---------- shell ---------- */
main{max-width:760px;margin:0 auto;padding:20px 16px 110px;display:flex;flex-direction:column;gap:20px}
.rail{display:none}
.tabs{position:fixed;inset:auto 0 0 0;z-index:20;display:flex;background:var(--surface);border-top:1px solid var(--line);padding:6px 4px calc(6px + env(safe-area-inset-bottom))}
.tabs a{flex:1;display:flex;flex-direction:column;align-items:center;gap:2px;padding:6px 2px;border-radius:12px;color:var(--mute);font-size:12px;font-weight:600;position:relative}
.tabs a:hover{text-decoration:none}
.tabs a.on{color:var(--accent)}
.tabs .dot,.rail .count{background:var(--stop);color:#fff;font-size:11px;font-weight:700;border-radius:99px;min-width:18px;height:18px;padding:0 5px;display:grid;place-items:center}
.tabs .dot{position:absolute;top:0;left:calc(50% + 4px)}
@media (min-width:900px){
  body.app{padding-left:240px}
  main{padding:40px 32px 64px;gap:24px}
  .tabs{display:none}
  .rail{display:flex;flex-direction:column;gap:4px;position:fixed;inset:0 auto 0 0;width:240px;padding:24px 14px;background:var(--surface);border-right:1px solid var(--line)}
  .rail .brand{font-weight:800;font-size:18px;letter-spacing:-.01em;color:var(--ink);padding:0 10px 18px;display:flex;align-items:center;gap:10px}
  .rail .brand b{display:grid;place-items:center;width:30px;height:30px;border-radius:9px;background:var(--accent);color:var(--on-accent);font-size:16px}
  .rail a.nav{display:flex;align-items:center;gap:12px;padding:10px;border-radius:var(--r-sm);color:var(--mute);font-weight:600;font-size:15px}
  .rail a.nav:hover{background:var(--canvas);text-decoration:none;color:var(--ink)}
  .rail a.nav.on{background:var(--accent-soft);color:var(--accent)}
  .rail .count{margin-left:auto}
  .rail .group{font-size:13px;color:var(--mute);padding:18px 10px 6px}
  .rail .me{margin-top:auto;display:flex;align-items:center;gap:10px;padding:10px;border-top:1px solid var(--line);padding-top:16px}
  .rail .me a{color:var(--ink);font-weight:600;font-size:14px;flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
}

/* ---------- building blocks ---------- */
.card{background:var(--surface);border:1px solid var(--line);border-radius:var(--r);box-shadow:var(--shadow);padding:20px}
.card.flush{padding:4px 20px}
.head{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.stack{display:flex;flex-direction:column;gap:12px}
.rowx{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.flash{padding:12px 16px;border-radius:var(--r-sm);font-weight:600;font-size:15px}
.flash.ok{background:var(--go-soft);color:var(--go)}
.flash.err{background:var(--stop-soft);color:var(--stop)}

button,.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:44px;padding:0 18px;border:1px solid transparent;border-radius:12px;font:700 15px/1 var(--font);cursor:pointer;background:var(--accent);color:var(--on-accent);white-space:nowrap}
.btn:hover{text-decoration:none;filter:brightness(1.06)}button:hover{filter:brightness(1.06)}
button:disabled{opacity:.45;cursor:not-allowed}
.ghost{background:transparent;color:var(--ink);border-color:var(--line)}
.ghost:hover{background:var(--canvas);filter:none}
.go{background:var(--go);color:var(--on-accent)}
.stopline{background:transparent;color:var(--stop);border-color:var(--stop)}
.sm{min-height:36px;padding:0 12px;font-size:14px;border-radius:10px}
.wide{width:100%}

label{display:block;font-size:14px;font-weight:600;color:var(--mute);margin-bottom:6px}
input,select,textarea{width:100%;min-height:46px;padding:10px 12px;border:1px solid var(--line);border-radius:12px;background:var(--surface);color:var(--ink);font:500 16px/1.3 var(--font)}
input:focus,select:focus,textarea:focus{outline:2px solid var(--accent);outline-offset:0;border-color:transparent}
input[type=checkbox],input[type=radio]{width:20px;min-height:20px;height:20px;accent-color:var(--accent);flex:none;padding:0}
input[type=file]{padding:10px}
textarea{min-height:84px;resize:vertical}
.fields{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:16px}
.check{display:flex;align-items:center;gap:10px;color:var(--ink);margin:0}
form.stack{gap:16px}
form.inline{display:inline}

.badge{display:inline-flex;align-items:center;height:26px;padding:0 10px;border-radius:99px;font-size:13px;font-weight:700;white-space:nowrap;background:var(--canvas);color:var(--mute)}
.badge.pending{background:var(--wait-soft);color:var(--wait)}
.badge.approved{background:var(--go-soft);color:var(--go)}
.badge.rejected{background:var(--stop-soft);color:var(--stop)}
.badge.wfh{background:var(--wfh-soft);color:var(--wfh)}
.badge.away{background:var(--accent-soft);color:var(--accent)}
.av{flex:none;display:grid;place-items:center;width:40px;height:40px;border-radius:50%;font-size:14px;font-weight:800;background:hsl(var(--h) 60% var(--av-l));color:hsl(var(--h) 55% var(--av-t))}
.av.s{width:26px;height:26px;font-size:11px}
.tico{flex:none;display:grid;place-items:center;width:40px;height:40px;border-radius:12px;background:var(--accent-soft);color:var(--accent)}
.tico.wfh{background:var(--wfh-soft);color:var(--wfh)}
.tico.sick{background:var(--stop-soft);color:var(--stop)}
.tico.other{background:var(--canvas);color:var(--mute)}

/* list rows */
.item{display:flex;gap:14px;padding:16px 0;border-bottom:1px solid var(--line)}
.item:last-child{border-bottom:0}
.item .body{flex:1;min-width:0;display:flex;flex-direction:column;gap:4px}
.item .top{display:flex;justify-content:space-between;align-items:center;gap:8px;flex-wrap:wrap}
.item .title{font-weight:700}
.item .acts{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin-top:8px}
.empty{padding:28px 8px;text-align:center;color:var(--mute)}

/* ---------- balance: one bay per vacation day ---------- */
.balance{display:flex;flex-direction:column;gap:18px}
.balance .num{font-size:56px;line-height:1;font-weight:800;letter-spacing:-.03em}
.balance .lead{display:flex;align-items:baseline;gap:10px;flex-wrap:wrap}
.bays{display:flex;flex-wrap:wrap;gap:5px}
.bay{width:18px;height:28px;border-radius:5px;border:2px solid var(--accent);background:var(--accent)}
.bay.used{background:var(--line);border-color:var(--line)}
.bay.pending{background:repeating-linear-gradient(135deg,var(--wait-soft) 0 4px,var(--wait) 4px 6px);border-color:var(--wait)}
.key{display:flex;gap:16px;flex-wrap:wrap;font-size:13px;color:var(--mute)}
.key span{display:inline-flex;align-items:center;gap:6px}
.key .bay{width:10px;height:14px;border-radius:3px;border-width:1.5px}
.facts{display:flex;gap:10px;flex-wrap:wrap}
.fact{display:flex;align-items:center;gap:8px;padding:8px 14px;border-radius:99px;background:var(--surface);border:1px solid var(--line);font-size:14px;font-weight:600}
.fact b{font-weight:800}
.years{display:flex;gap:6px;flex-wrap:wrap}
.pill{display:inline-flex;align-items:center;height:32px;padding:0 12px;border-radius:99px;font-size:14px;font-weight:700;color:var(--mute);border:1px solid var(--line);background:var(--surface)}
.pill:hover{text-decoration:none;color:var(--ink)}
.pill.on{background:var(--ink);color:var(--surface);border-color:var(--ink)}

/* ---------- new request ---------- */
.kinds{display:grid;grid-template-columns:repeat(2,1fr);gap:10px}
@media (min-width:560px){.kinds{grid-template-columns:repeat(4,1fr)}}
.kind{position:relative;margin:0}
.kind input{position:absolute;opacity:0;inset:0;min-height:0;cursor:pointer}
.kind span{display:flex;flex-direction:column;align-items:center;gap:8px;padding:16px 8px;border:2px solid var(--line);border-radius:14px;font-size:14px;font-weight:700;color:var(--ink);text-align:center;background:var(--surface)}
.kind input:checked+span{border-color:var(--accent);background:var(--accent-soft);color:var(--accent)}
.kind input:focus-visible+span{outline:2px solid var(--accent);outline-offset:2px}
.count{padding:14px 16px;border-radius:12px;background:var(--canvas);font-weight:700}
.count small{display:block;font-weight:500;color:var(--mute);font-size:14px}
[hidden]{display:none!important}

/* ---------- calendar ---------- */
.day{display:flex;gap:14px;padding:14px 0;border-bottom:1px solid var(--line);align-items:flex-start}
.day:last-child{border-bottom:0}
.day .when{flex:none;width:52px;text-align:center;border-radius:12px;padding:6px 0;background:var(--canvas);font-size:12px;font-weight:700;color:var(--mute);line-height:1.2}
.day .when b{display:block;font-size:20px;font-weight:800;color:var(--ink)}
.day.today .when{background:var(--accent);color:var(--on-accent)}.day.today .when b{color:var(--on-accent)}
.who{display:flex;flex-wrap:wrap;gap:8px;padding-top:4px}
.person{display:inline-flex;align-items:center;gap:8px;padding:4px 12px 4px 4px;border-radius:99px;font-size:14px;font-weight:600;background:var(--accent-soft);color:var(--accent)}
.person.wfh{background:var(--wfh-soft);color:var(--wfh)}
.person small{font-weight:500;opacity:.85}

/* ---------- admin ---------- */
.hub{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:12px}
.hub a{display:flex;gap:14px;align-items:center;color:var(--ink)}
.hub a:hover{text-decoration:none;border-color:var(--accent)}
.hub .t{font-weight:700}
.seg{display:inline-flex;padding:4px;border-radius:12px;background:var(--line);gap:4px}
.seg a{padding:8px 16px;border-radius:9px;font-weight:700;font-size:14px;color:var(--mute)}
.seg a:hover{text-decoration:none}
.seg a.on{background:var(--surface);color:var(--ink);box-shadow:var(--shadow)}
details>summary{cursor:pointer;font-weight:700;font-size:14px;color:var(--accent);list-style:none;display:inline-flex;align-items:center;gap:6px;min-height:36px}
details>summary::-webkit-details-marker{display:none}
details[open]>summary{margin-bottom:10px}
.meter{height:6px;border-radius:99px;background:var(--line);overflow:hidden;width:120px}
.meter i{display:block;height:100%;background:var(--accent);border-radius:99px}
.steps{counter-reset:step}
.step{display:flex;gap:16px}
.step::before{counter-increment:step;content:counter(step);flex:none;display:grid;place-items:center;width:32px;height:32px;border-radius:50%;background:var(--ink);color:var(--surface);font-weight:800;font-size:14px}
.step>div{flex:1;min-width:0;display:flex;flex-direction:column;gap:12px}
.tiles{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:12px}
.tile{display:flex;flex-direction:column;gap:2px}
.tile b{font-size:30px;line-height:1.1;font-weight:800;letter-spacing:-.02em}
.tile span{font-size:14px;color:var(--mute)}
.bars{display:flex;align-items:flex-end;gap:6px;height:170px}
.bars .col{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;gap:4px;height:100%;font-size:12px;color:var(--mute);font-weight:600}
.bars .stackbar{width:100%;max-width:34px;display:flex;flex-direction:column-reverse;border-radius:6px;overflow:hidden;gap:2px}
.t-vacation{background:var(--accent)}.t-wfh{background:var(--wfh)}.t-sick{background:var(--stop)}.t-other{background:var(--mute)}
.legend{display:flex;gap:16px;flex-wrap:wrap;font-size:13px;color:var(--mute)}
.legend i{display:inline-block;width:10px;height:10px;border-radius:3px;margin-right:6px}
.scroll{overflow-x:auto}
table{width:100%;border-collapse:collapse;font-size:15px;font-variant-numeric:tabular-nums}
th{text-align:left;font-size:13px;color:var(--mute);font-weight:700;padding:10px 8px;border-bottom:1px solid var(--line);white-space:nowrap}
td{padding:12px 8px;border-bottom:1px solid var(--line);vertical-align:middle}
tr:last-child td{border-bottom:0}
.num{text-align:right}
@media (max-width:640px){
  table.fold thead{display:none}
  table.fold tr{display:block;padding:10px 0;border-bottom:1px solid var(--line)}
  table.fold tr:last-child{border-bottom:0}
  table.fold td{display:flex;justify-content:space-between;gap:12px;border:0;padding:3px 0;text-align:right}
  table.fold td::before{content:attr(data-l);color:var(--mute);font-size:13px;text-align:left}
}

/* ---------- signed-out pages ---------- */
body.bare main{max-width:420px;padding-top:12vh}
.secret{background:var(--canvas);border-radius:12px;padding:14px;font-family:ui-monospace,Menlo,Consolas,monospace;font-size:15px;word-break:break-all}
@media (prefers-reduced-motion:no-preference){.btn,button,.pill,.seg a{transition:filter .15s,background-color .15s}}

/* ---------- month grid: one row per person, one column per day ---------- */
.gridwrap{overflow-x:auto;margin:0 -4px;padding:0 4px 4px}
table.cal{border-collapse:separate;border-spacing:2px;width:auto;min-width:100%;font-size:12px}
table.cal th,table.cal td{border:0;padding:0}
table.cal thead th{text-align:center;color:var(--mute);font-weight:700;line-height:1.25;min-width:22px;padding-bottom:4px}
table.cal thead th.off{opacity:.45}
table.cal thead th.today{color:var(--accent)}
table.cal th.p{position:sticky;left:0;z-index:1;background:var(--surface);text-align:left;white-space:nowrap;padding-right:14px;font-size:14px;font-weight:600;color:var(--ink)}
table.cal td{height:30px;min-width:22px;border-radius:6px;background:var(--canvas)}
table.cal td.off{background:transparent}
table.cal td.vacation,table.cal td.away{background:var(--accent)}
table.cal td.wfh{background:var(--wfh)}
table.cal td.sick{background:var(--stop)}
table.cal td.other{background:var(--mute)}
table.cal td.pend,.legend i.pend{background:repeating-linear-gradient(135deg,var(--wait-soft) 0 4px,var(--wait) 4px 6px)}
.calc{border-collapse:collapse;width:100%;max-width:440px;font-size:14px}
.calc td{padding:6px 0;border-bottom:1px solid var(--line)}
.calc td.n{text-align:right;font-variant-numeric:tabular-nums;font-weight:700;white-space:nowrap;padding-left:16px}
.calc tr.sum td{border-bottom:0;font-weight:800}
.period{font-size:14px;margin:0}
.calc.next{max-width:none;font-size:15px}
.calc.next td{padding:10px 0}
.calc.next td span{display:block;font-size:13px;color:var(--mute);font-weight:400}
.calc.next tr.sum td.n{font-size:18px}

.doz{flex-wrap:wrap;gap:8px;margin-top:6px}
.doz input[type=file]{width:auto;max-width:100%;font-size:13px;padding:6px}
.doz input[type=date]{width:auto;font-size:14px;padding:6px 8px}
