@font-face { font-family: "Lato"; font-weight: 400; font-display: swap; src: url("/fonts/lato-400.woff2") format("woff2"); }
@font-face { font-family: "Lato"; font-weight: 700; font-display: swap; src: url("/fonts/lato-700.woff2") format("woff2"); }
@font-face { font-family: "Lato"; font-weight: 900; font-display: swap; src: url("/fonts/lato-900.woff2") format("woff2"); }

:root {
  --blue: #09C3F4;
  --blue-dark: #0794BA;   /* for text on white: passes contrast */
  --green: #80C242;
  --green-dark: #4E7F1F;
  --black: #000000;
  --white: #FFFFFF;
  --ink: #111418;
  --muted: #5D6670;
  --line: #E3E7EB;
  --bg: #F5F7F9;
  --error: #C62828;
  --error-bg: #FDECEC;
  --warn: #8A5A00;
  --warn-bg: #FFF4D6;
  --radius: 14px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Lato", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.4;
  min-height: 100vh;
  padding-bottom: calc(72px + var(--safe-bottom));
}
button, input, select { font: inherit; color: inherit; }
[hidden] { display: none !important; }

/* ---- top bar ---- */
.topbar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between;
  padding: calc(10px + env(safe-area-inset-top, 0px)) 16px 10px;
  background: var(--black); color: var(--white);
}
.brand { display: flex; align-items: center; gap: 10px; }
.logo-img { display: block; height: 40px; width: auto; }
/* Login: big logo on a black band under the bar; hide the small one so it isn't doubled */
.auth-screen .brand { visibility: hidden; }
.hero { background: var(--black); margin: -16px -16px 0; padding: 4px 16px 28px; text-align: center; }
.hero img { height: 150px; width: auto; }
.auth-screen .auth { margin-top: 20px; }
.topbar-right { display: flex; align-items: center; gap: 12px; font-size: 14px; }
.topbar-right #username { background: none; border: 0; color: inherit; font: inherit; cursor: pointer; padding: 6px 0; text-decoration: underline dotted; text-underline-offset: 4px; opacity: .85; max-width: 40vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.link-btn { background: none; border: 0; padding: 6px 0; color: var(--blue); font-weight: 700; cursor: pointer; }

.banner { padding: 10px 16px; font-size: 14px; background: var(--warn-bg); color: var(--warn); border-bottom: 1px solid #F1DFA6; }

main { max-width: 640px; margin: 0 auto; padding: 16px; }
.loading { text-align: center; color: var(--muted); padding: 48px 0; }

/* ---- forms ---- */
.card { background: var(--white); border-radius: var(--radius); padding: 20px; box-shadow: 0 1px 2px rgba(0,0,0,.05); }
.auth { margin-top: 8vh; }
.auth h1 { margin: 0 0 4px; font-size: 24px; font-weight: 900; }
.auth p.sub { margin: 0 0 20px; color: var(--muted); }
label { display: block; font-weight: 700; font-size: 14px; margin: 14px 0 6px; }
input[type=email], input[type=password], input[type=text], select {
  width: 100%; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 10px;
  background: var(--white); font-size: 16px; /* 16px stops iOS zooming */
}
input:focus, select:focus, button:focus-visible { outline: 3px solid rgba(9,195,244,.35); outline-offset: 1px; border-color: var(--blue); }
.btn {
  display: block; width: 100%; margin-top: 20px; padding: 14px; border: 0; border-radius: 10px;
  background: var(--blue); color: var(--black); font-weight: 900; font-size: 16px; cursor: pointer;
}
.btn:disabled { opacity: .6; cursor: default; }
.form-error { margin: 14px 0 0; padding: 10px 12px; border-radius: 8px; background: var(--error-bg); color: var(--error); font-size: 14px; }
.hint { color: var(--muted); font-size: 13px; margin: 6px 0 0; }

/* ---- roster header ---- */
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin: 4px 0 14px; }
.page-head h1 { margin: 0; font-size: 22px; font-weight: 900; }
.updated { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.icon-btn { border: 1.5px solid var(--line); background: var(--white); border-radius: 999px; padding: 4px 10px; font-size: 12px; font-weight: 700; cursor: pointer; }

.segmented { display: flex; background: #E9EDF0; border-radius: 10px; padding: 3px; margin-bottom: 16px; }
.segmented button { flex: 1; border: 0; background: none; padding: 9px; border-radius: 8px; font-weight: 700; color: var(--muted); cursor: pointer; }
.segmented button[aria-pressed=true] { background: var(--white); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.08); }

/* ---- next shift ---- */
.next {
  background: var(--black); color: var(--white); border-radius: var(--radius); padding: 16px 18px; margin-bottom: 18px;
  border-left: 6px solid var(--green);
}
.next .eyebrow { color: var(--green); font-size: 12px; font-weight: 900; text-transform: uppercase; letter-spacing: .8px; }
.next .when { font-size: 20px; font-weight: 900; margin: 4px 0 2px; }
.next .what { opacity: .85; }

/* ---- list ---- */
.month-title { font-size: 13px; font-weight: 900; text-transform: uppercase; letter-spacing: .8px; color: var(--muted); margin: 22px 0 8px; }
.day { margin-bottom: 12px; }
.day-label { font-weight: 700; font-size: 14px; margin: 0 0 6px; color: var(--ink); }
.day-label .today-pill { background: var(--blue); color: var(--black); font-size: 11px; font-weight: 900; padding: 2px 8px; border-radius: 999px; margin-left: 6px; vertical-align: 1px; }
.shift {
  background: var(--white); border-radius: 12px; padding: 12px 14px; margin-bottom: 8px;
  border-left: 5px solid var(--blue); box-shadow: 0 1px 2px rgba(0,0,0,.05);
}
.shift.past { opacity: .55; }
.shift .row1 { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.shift .time { font-weight: 900; font-size: 17px; }
.shift .hrs { font-size: 13px; color: var(--muted); white-space: nowrap; }
.shift .role { font-weight: 700; margin-top: 2px; }
.shift .tz, .next .tz { font-size: 12px; font-weight: 700; color: var(--muted); }
.next .tz { color: #B8C0C8; }
.shift .localtime { font-size: 14px; font-weight: 700; color: var(--green-dark); margin-top: 1px; }
.next .local { color: var(--green); font-weight: 700; margin-bottom: 2px; }
.shift .meta { font-size: 14px; color: var(--muted); margin-top: 2px; }
.shift .notes { font-size: 13px; margin-top: 6px; padding: 6px 8px; background: var(--bg); border-radius: 6px; }
.shift .who { font-size: 13px; font-weight: 700; color: var(--blue-dark); }
.chip { display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: #EAF8FE; color: var(--blue-dark); margin-left: 4px; }
.dept-first-aid { border-left-color: var(--green); }
.dept-first-aid .chip { background: #EFF7E6; color: var(--green-dark); }
.dept-offshore { border-left-color: var(--black); }
.dept-offshore .chip { background: #ECEEF0; color: var(--ink); }

.empty {
  text-align: center; background: var(--white); border-radius: var(--radius); padding: 22px 16px; color: var(--muted);
  border: 1.5px dashed var(--line);
}
.empty strong { display: block; color: var(--ink); font-size: 16px; margin-bottom: 2px; }
.show-earlier { display: block; margin: 0 auto 12px; }

/* ---- calendar ---- */
.cal { background: var(--white); border-radius: var(--radius); padding: 12px; box-shadow: 0 1px 2px rgba(0,0,0,.05); }
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.cal-head h2 { margin: 0; font-size: 17px; font-weight: 900; }
.cal-nav { border: 0; background: var(--bg); width: 36px; height: 36px; border-radius: 50%; font-size: 18px; font-weight: 900; cursor: pointer; }
.cal-nav:disabled { opacity: .3; cursor: default; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-dow { text-align: center; font-size: 11px; font-weight: 700; color: var(--muted); padding: 4px 0; }
.cal-day {
  aspect-ratio: 1 / 1; border: 0; background: none; border-radius: 10px; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 3px; font-weight: 700; cursor: pointer; padding: 0;
}
.cal-day.blank { visibility: hidden; }
.cal-day.past { color: #A3ABB3; }
.cal-day.today { box-shadow: inset 0 0 0 2px var(--blue); }
.cal-day.has { background: #EAF8FE; }
.cal-day.selected { background: var(--black); color: var(--white); }
.dots { display: flex; gap: 3px; height: 6px; }
.dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--blue); }
.dots i.fa { background: var(--green); }
.cal-day.selected .dots i { box-shadow: 0 0 0 1px var(--black); }
.cal-detail { margin-top: 14px; }

/* ---- admin ---- */
.filters { display: flex; gap: 10px; margin-bottom: 14px; }
.filters select { flex: 1; }
.issue { background: var(--white); border-radius: 12px; padding: 12px 14px; margin-bottom: 8px; border-left: 5px solid var(--warn); }
.issue.error { border-left-color: var(--error); }
.issue .where { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; }
.issue.error .lvl { color: var(--error); }
.issue .lvl { font-weight: 900; color: var(--warn); }
.issue .rows { font-size: 13px; color: var(--muted); margin-top: 4px; }
.summary { display: flex; gap: 8px; margin-bottom: 14px; flex-wrap: wrap; }
.summary span { font-size: 13px; font-weight: 700; padding: 6px 10px; border-radius: 999px; }
.summary .e { background: var(--error-bg); color: var(--error); }
.summary .w { background: var(--warn-bg); color: var(--warn); }
.summary .ok { background: #EFF7E6; color: var(--green-dark); }

/* ---- bottom tab bar ---- */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 10; display: flex;
  background: var(--white); border-top: 1px solid var(--line); padding-bottom: var(--safe-bottom);
}
.tabbar button {
  flex: 1; border: 0; background: none; padding: 12px 4px 14px; font-weight: 700; font-size: 13px; color: var(--muted);
  cursor: pointer; position: relative;
}
.tabbar button[aria-current=page] { color: var(--ink); }
.tabbar button[aria-current=page]::before { content: ""; position: absolute; top: 0; left: 25%; right: 25%; height: 3px; background: var(--blue); border-radius: 0 0 3px 3px; }
.badge { display: inline-block; min-width: 18px; padding: 0 5px; margin-left: 4px; border-radius: 999px; background: var(--error); color: var(--white); font-size: 11px; line-height: 18px; }

/* ---- clock in / out ---- */
.clock-card {
  background: var(--white); border-radius: var(--radius); padding: 16px; margin-bottom: 18px;
  box-shadow: 0 1px 2px rgba(0,0,0,.05); border-top: 5px solid var(--line);
}
.clock-card.is-in { border-top-color: var(--green); }
.clock-status { display: flex; align-items: center; gap: 8px; font-weight: 900; font-size: 17px; }
.clock-status .dot { width: 10px; height: 10px; border-radius: 50%; background: #B9C0C7; }
.clock-card.is-in .clock-status .dot { background: var(--green); box-shadow: 0 0 0 4px rgba(128,194,66,.25); }
.btn-clock {
  display: block; width: 100%; margin-top: 12px; padding: 18px; border: 0; border-radius: 12px;
  font-weight: 900; font-size: 20px; cursor: pointer; letter-spacing: .3px;
}
.btn-clock.in { background: var(--blue); color: var(--black); }
.btn-clock.out { background: var(--black); color: var(--white); }
.btn-clock:disabled { opacity: .6; cursor: default; }
.clock-note, .clock-pending, .clock-today { font-size: 14px; color: var(--muted); margin: 10px 0 0; }
.clock-msg { margin: 10px 0 0; padding: 10px 12px; border-radius: 8px; font-size: 14px; font-weight: 700; }
.clock-msg.ok { background: #EFF7E6; color: var(--green-dark); }
.clock-msg.warn { background: var(--warn-bg); color: var(--warn); }
.clock-msg.error { background: var(--error-bg); color: var(--error); }

/* PIN pad (staff app + kiosk) */
.pin-overlay {
  position: fixed; inset: 0; z-index: 50; background: #050607;
  display: flex; align-items: center; justify-content: center; padding: 16px;
}
.pin-box { width: 100%; max-width: 360px; text-align: center; color: var(--white); }
.pin-title { font-size: 20px; font-weight: 900; margin: 0 0 18px; }
.pin-dots { display: flex; justify-content: center; gap: 14px; margin-bottom: 26px; }
.pin-dots i { width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--white); }
.pin-dots i.on { background: var(--blue); border-color: var(--blue); }
.pin-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.pin-key {
  aspect-ratio: 1.4 / 1; border: 0; border-radius: 16px; background: #1E2328; color: var(--white);
  font-size: 28px; font-weight: 700; cursor: pointer;
}
.pin-key:active { background: #2E353C; }
.pin-cancel, .pin-del { font-size: 16px; background: transparent; }

/* admin clock view */
.day-nav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.day-title { font-weight: 900; font-size: 17px; display: flex; align-items: center; gap: 8px; }
.today-pill { background: var(--blue); color: var(--black); font-size: 11px; font-weight: 900; padding: 2px 8px; border-radius: 999px; }
.clock-sess { background: var(--white); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; border-left: 5px solid var(--green); box-shadow: 0 1px 2px rgba(0,0,0,.05); }
.clock-sess.flagged { border-left-color: var(--warn); }
.clock-sess .row1 { display: flex; justify-content: space-between; gap: 10px; margin-bottom: 4px; }
.clock-sess .hrs { font-size: 13px; color: var(--muted); }
.clock-sess .pl { font-size: 14px; margin: 2px 0; }
.clock-sess .pl.missing { color: var(--error); font-weight: 700; }
.clock-sess .pl a { color: var(--blue-dark); }
.clock-sess .meta { font-size: 13px; color: var(--muted); margin-top: 4px; }
.flags { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 4px; }
.flag { font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 999px; }
.flag.e { background: var(--error-bg); color: var(--error); }
.flag.w { background: var(--warn-bg); color: var(--warn); }
.flag.i { background: #ECEEF0; color: var(--muted); }
.link-btn.dark { color: var(--blue-dark); padding: 6px 0; }
.fix-form { display: grid; gap: 8px; margin-top: 8px; padding-top: 10px; border-top: 1px solid var(--line); }
.fix-actions { display: flex; align-items: center; gap: 14px; }
.btn.small { width: auto; margin: 0; padding: 10px 18px; font-size: 15px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip.big { font-size: 13px; padding: 5px 10px; margin: 0; }
.on-clock { margin-bottom: 8px; }

/* ---- leave ---- */
.bal-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-bottom: 14px; }
.bal { background: var(--white); border-radius: var(--radius); padding: 14px; box-shadow: 0 1px 2px rgba(0,0,0,.05); border-top: 5px solid var(--blue); }
.bal:nth-child(2) { border-top-color: var(--green); }
.bal-label { font-weight: 700; font-size: 14px; color: var(--muted); }
.bal-num { font-size: 34px; font-weight: 900; line-height: 1.1; margin-top: 4px; }
.bal-num span { font-size: 15px; font-weight: 700; color: var(--muted); }
.bal-sub { font-size: 13px; color: var(--muted); }
.bal-sub.warn { color: var(--warn); font-weight: 700; }
.bal-next { font-size: 13px; font-weight: 700; color: var(--green-dark); margin-top: 6px; }
.leave-form { margin-bottom: 14px; }
.leave-form .btn { margin-top: 14px; }
.date-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; }
.date-row input { min-width: 0; }
input[type=date] { width: 100%; padding: 11px 12px; border: 1.5px solid var(--line); border-radius: 10px; background: var(--white); font-size: 16px; }
label.check { display: flex; align-items: center; gap: 8px; font-weight: 400; margin: 12px 0 0; }
label.check input { width: 20px; height: 20px; }
.leave-preview { margin: 12px 0 0; font-weight: 700; }
.leave-preview.warn { color: var(--warn); }
.leave-req { background: var(--white); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; box-shadow: 0 1px 2px rgba(0,0,0,.05); border-left: 5px solid var(--line); }
.leave-req.st-pending { border-left-color: var(--warn); }
.leave-req.st-approved { border-left-color: var(--green); }
.leave-req.st-declined { border-left-color: var(--error); }
.leave-req .row1 { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 2px; }
.leave-req .meta { font-size: 13px; color: var(--muted); margin-top: 2px; }
.pill { font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 999px; white-space: nowrap; background: #ECEEF0; color: var(--muted); }
.pill.pending { background: var(--warn-bg); color: var(--warn); }
.pill.approved { background: #EFF7E6; color: var(--green-dark); }
.pill.declined { background: var(--error-bg); color: var(--error); }
.decide { display: grid; gap: 8px; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); }
.decide-btns { display: flex; gap: 10px; }
.btn.approve { background: var(--green); }
.btn.decline { background: #E9EDF0; color: var(--ink); }

/* ---- xero ---- */
.card.xero { margin-bottom: 14px; }
.card.xero .row1 { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.card.xero a.btn { text-align: center; text-decoration: none; }
.xero-h { font-size: 14px; margin: 16px 0 6px; }
.xero-row { display: grid; gap: 6px; padding: 10px 0; border-top: 1px solid var(--line); }
.xero-row .meta { font-size: 13px; color: var(--muted); }

ul.files { list-style: none; margin: 8px 0 0; padding: 0; }
ul.files li { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding: 3px 0; font-size: 14px; }
ul.files a { color: var(--blue-dark); font-weight: 700; word-break: break-all; }
.link-btn.small { font-size: 13px; padding: 0 4px; }
input[type=file] { width: 100%; font-size: 14px; }

/* ---- availability ---- */
.avail { margin-top: 8px; }
.avail-card { padding: 14px 16px; margin-top: 10px; }
.avail-card .row1 { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.avail-card .meta, .avail-dates .meta { font-size: 14px; color: var(--muted); }
.avail-form { margin-top: 8px; }
.avail-form .btn { margin-top: 14px; }
.avail-day { display: grid; grid-template-columns: 96px minmax(0, 1fr); align-items: center; gap: 4px 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.avail-day:first-child { border-top: 0; }
.avail-dname { font-weight: 700; font-size: 14px; }
.avail-day .avail-times { grid-column: 2; }
.avail-times { display: flex; align-items: center; gap: 8px; margin-top: 4px; }
.avail-times[hidden] { display: none; }
.avail-times span { color: var(--muted); font-size: 14px; }
input[type=time] { flex: 1; min-width: 0; padding: 10px 10px; border: 1.5px solid var(--line); border-radius: 10px; background: var(--white); font-size: 16px; }
ul.avail-dates { list-style: none; margin: 8px 0 0; padding: 0; }
ul.avail-dates li { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 14px; }
ul.avail-dates li:first-child { border-top: 0; }
.clash-list { display: grid; gap: 8px; margin: 8px 0; }
.clash { background: var(--warn-bg); color: var(--ink); border-left: 5px solid var(--warn); border-radius: 10px; padding: 10px 12px; font-size: 14px; }
.clash .kind { display: inline-block; font-size: 12px; font-weight: 700; color: var(--warn); margin-right: 6px; }
.pill.new { background: #E6F7FD; color: var(--blue-dark); margin-left: 6px; }
.account { display: grid; gap: 0; }
.btn.secondary { background: #E9EDF0; color: var(--ink); }
.clash-ul { margin: 6px 0; padding-left: 20px; }
.avail-day .avail-times { grid-column: 1 / -1; }

/* ---- pay report ---- */
.pay-card { background: var(--white); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; box-shadow: 0 1px 2px rgba(0,0,0,.05); }
.pay-card .row1 { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.pay-card .meta { font-size: 13px; color: var(--muted); }
table.pay-items { width: 100%; border-collapse: collapse; margin: 8px 0 4px; font-size: 15px; }
table.pay-items td { padding: 4px 0; border-top: 1px solid var(--line); }
table.pay-items td:last-child { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }
.pay-leave { font-size: 14px; margin-top: 6px; color: var(--green-dark); }
ul.pay-flags { margin: 8px 0 4px; padding-left: 18px; font-size: 14px; color: var(--warn); }
table.pay-shifts { width: 100%; border-collapse: collapse; font-size: 13px; margin-top: 6px; }
table.pay-shifts th { text-align: left; color: var(--muted); font-weight: 700; padding: 4px 4px 4px 0; }
table.pay-shifts td { padding: 4px 4px 4px 0; border-top: 1px solid var(--line); font-variant-numeric: tabular-nums; }
table.pay-shifts tr.sub td { border-top: 0; color: var(--muted); padding-top: 0; }
.tracker-row { padding: 8px 0; border-top: 1px solid var(--line); }
.card.venue { display: grid; gap: 8px; padding: 14px; margin-bottom: 10px; }
.venue-km { display: flex; gap: 8px; align-items: center; }
.venue-km input { width: 90px; }
.card.venue .btn.small { justify-self: start; }
.new-secret { background: #EFF7E6; border-radius: 10px; padding: 12px 14px; margin: 10px 0; }
.new-secret .secret { font-size: 28px; font-weight: 900; letter-spacing: 3px; font-variant-numeric: tabular-nums; margin: 4px 0; word-break: break-all; }
div.pay-flags { color: var(--warn); font-size: 14px; margin-top: 4px; }
.inline-select { display: flex; align-items: center; gap: 8px; font-weight: 400; font-size: 14px; margin: 8px 0 0; } .inline-select select { flex: 1; padding: 8px 10px; }
.staff-email { display: flex; gap: 8px; align-items: center; margin-top: 8px; } .staff-email input { flex: 1; padding: 8px 10px; font-size: 15px; }
textarea { width: 100%; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 10px; background: var(--white); font: inherit; font-size: 16px; resize: vertical; }
.claim-btns { display: grid; gap: 10px; }
.claim-btns .btn { margin-top: 0; }
.table-scroll { overflow-x: auto; margin: 8px 0; -webkit-overflow-scrolling: touch; }
table.bookings { border-collapse: collapse; font-size: 13px; min-width: 100%; }
table.bookings th { text-align: left; white-space: nowrap; color: var(--muted); padding: 4px 6px; border-bottom: 1px solid var(--line); }
table.bookings td { padding: 4px 6px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.bookings td input { width: 130px; padding: 6px 8px; font-size: 14px; border: 1px solid var(--line); border-radius: 6px; }
table.bookings a { color: var(--blue-dark); font-weight: 700; }
.short-notice { background: var(--warn-bg); border-left: 5px solid var(--warn); border-radius: 10px; padding: 10px 12px; margin-top: 12px; font-size: 14px; } .short-notice[hidden] { display: none; }
.shift.on-leave .row1, .shift.on-leave .role, .shift.on-leave .meta { opacity: .5; }
.shift.on-leave .time { text-decoration: line-through; }
.leave-tag { display: inline-block; font-size: 13px; font-weight: 700; border-radius: 999px; padding: 3px 10px; margin-bottom: 6px; }
.leave-tag.approved { background: #EFF7E6; color: var(--green-dark); }
.leave-tag.pending { background: var(--warn-bg); color: var(--warn); }
.cal-day .cal-count { display: block; font-size: 11px; font-weight: 900; color: var(--blue-dark); line-height: 1; margin-top: 2px; }
.cal-day .cal-leave { display: block; font-size: 10px; line-height: 1; }
.cal-day .cal-leave.pending { filter: grayscale(1) opacity(.6); }
.sub-head { font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin: 14px 0 6px; }
.leave-line { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; background: var(--white); border-radius: 10px; padding: 10px 12px; margin-bottom: 8px; font-size: 14px; box-shadow: 0 1px 2px rgba(0,0,0,.05); }
.leave-line .leave-tag { margin: 0 0 0 auto; }
/* Team calendar: cells hold a count and a leave mark, so let them grow and never push the grid wider. */
.team-cal .cal-grid { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.team-cal .cal-day { aspect-ratio: auto; min-height: 52px; height: auto; padding: 4px 0; min-width: 0; }
.cal-day.selected .cal-count { color: var(--white); }
