/* USEK website reference: Lato and blue #00549E; see public/fonts/README.md. */
@font-face {
  font-family: "Lato"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("/fonts/lato-regular.woff2") format("woff2");
}
@font-face {
  font-family: "Lato"; font-style: normal; font-weight: 700; font-display: swap;
  src: url("/fonts/lato-bold.woff2") format("woff2");
}
:root {
  --font-sans: "Lato", Arial, Helvetica, sans-serif;
  --brand: #00549e; --brand-hover: #003f78; --accent: #1999d7;
  --text: #243746; --muted: #536574; --line: #dce4eb; --paper: #fff;
  --surface: #f5f7fa; --surface-soft: #f0f5fa; --brand-soft: #edf6fc;
  --brand-tint: #dcecf8; --brand-border: #c5dced;
  --shadow: 0 3px 12px #003f7804, 0 1px 2px #003f7803;
  font-family: var(--font-sans); color: var(--text); background: var(--surface); font-synthesis: none;
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea, summary, [tabindex] { outline-offset: 4px; }
:focus-visible { outline: 3px solid #00549e; }
::selection { background: var(--brand-tint); color: var(--brand); }
button {
  cursor: pointer; border: 1px solid var(--line); background: white; color: var(--brand);
  border-radius: 10px; padding: 11px 17px; font-size: 13px; font-weight: 700;
  line-height: 1.4; min-height: 42px; transition: background .16s, border-color .16s, box-shadow .16s;
}
button:hover { background: var(--surface-soft); border-color: var(--brand-border); }
button:disabled { opacity: .55; cursor: wait; }
button.primary { background: var(--brand); border-color: var(--brand); color: #fff; box-shadow: 0 2px 3px #003f7810; }
button.primary:hover { background: var(--brand-hover); border-color: var(--brand-hover); }
button.danger { color: #a33d37; }
button.danger:hover { background: #fff1ee; border-color: #e4b8b0; }
button.small { padding: 7px 11px; min-height: 34px; font-size: 12px; }
button.icon { padding: 5px 12px; min-width: 38px; font-size: 22px; line-height: 1; }
a { color: inherit; text-underline-offset: 3px; }
.ui-icon { width: 18px; height: 18px; vertical-align: middle; flex-shrink: 0; }
button .ui-icon { margin-right: 6px; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(30px, 3vw, 40px); font-weight: 700; line-height: 1.18; letter-spacing: -.8px; margin-bottom: 10px; }
h2 { font-size: 16px; font-weight: 700; letter-spacing: -.3px; }
h3 { font-size: 14px; font-weight: 700; margin-bottom: 8px; }
p { font-size: 14px; line-height: 1.7; color: var(--muted); }
.eyebrow { text-transform: uppercase; letter-spacing: .14em; font-size: 10px; font-weight: 700; margin-bottom: 13px; color: var(--muted); line-height: 1.6; overflow-wrap: anywhere; }
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.mark { width: 42px; height: 42px; flex-shrink: 0; border-radius: 13px; display: grid; place-items: center; background: var(--brand); color: #fff; }
.mark .ui-icon { width: 24px; height: 24px; }
.brand strong { font-size: 17px; font-weight: 700; letter-spacing: -.3px; }
.brand small { display: block; font-size: 9px; font-weight: 700; letter-spacing: .17em; margin-top: 4px; color: var(--muted); }

/* Workspace navigation and page hierarchy. */
.app { min-height: 100vh; display: flex; flex-direction: column; }
.appbar { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 30px; padding: 18px max(28px, calc((100vw - 1360px) / 2)); border-bottom: 1px solid var(--line); background: #fffffffa; }
.tabs { display: flex; align-items: center; gap: 4px; padding: 4px; background: var(--surface); border-radius: 12px; }
.tabs button { border: 1px solid transparent; color: var(--muted); background: transparent; padding: 9px 16px; min-height: 38px; display: flex; align-items: center; gap: 8px; }
.tabs button .ui-icon { margin: 0; width: 16px; height: 16px; }
.tabs button:hover { background: var(--brand-tint); }
.tabs button.active { background: #fff; border-color: var(--line); color: var(--brand); box-shadow: 0 2px 4px #003f7809; }
.badge { display: inline-grid; place-items: center; min-width: 21px; padding: 2px 6px; border-radius: 6px; background: var(--brand-tint); color: var(--brand); font-size: 10px; font-weight: 700; }
.appbar-right { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.appbar-right button { white-space: nowrap; }
.main { width: 100%; max-width: 1400px; padding: 36px 32px 28px; margin: 0 auto; min-width: 0; flex: 1; }
.page-heading { display: flex; justify-content: space-between; align-items: center; gap: 24px; margin: 0 0 28px; }
.page-heading > div { min-width: 0; }
.page-heading > button { flex-shrink: 0; }
.heading-actions { display: flex; gap: 8px; align-items: center; flex-shrink: 0; flex-wrap: wrap; justify-content: flex-end; }
.page-heading p { max-width: 750px; }
.live { display: inline-flex; align-items: center; gap: 8px; }
.dot { width: 6px; height: 6px; border-radius: 50%; background: #639c73; box-shadow: 0 0 0 4px #e5eee6; flex-shrink: 0; }
.page-footer { display: flex; justify-content: space-between; gap: 16px; padding-top: 23px; margin-top: 28px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; line-height: 1.6; }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin: 0 0 26px; }
.stat { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 24px; border: 1px solid var(--line); border-radius: 16px; background: white; box-shadow: var(--shadow); }
.stat:first-child { background: var(--brand-soft); border-color: var(--brand-border); }
.stat-label { font-size: 11px; letter-spacing: .08em; font-weight: 700; color: var(--muted); margin-bottom: 14px; }
.stat strong { font-size: 38px; letter-spacing: -1.6px; line-height: 1; font-weight: 700; font-variant-numeric: tabular-nums; }
.stat strong.next-date { font-size: clamp(23px, 3vw, 34px); letter-spacing: -1px; white-space: nowrap; }
.stat small { display: block; color: var(--muted); font-size: 12px; line-height: 1.5; margin-top: 10px; }
.stat-symbol { width: 42px; height: 42px; display: grid; place-items: center; flex-shrink: 0; background: var(--surface-soft); color: var(--brand); border: 1px solid var(--line); border-radius: 12px; }
.stat:first-child .stat-symbol { background: var(--brand-tint); border-color: var(--brand-border); }
.stat-symbol .ui-icon { width: 21px; height: 21px; }
.content-grid { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 22px; align-items: start; }
.card { background: white; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; box-shadow: var(--shadow); min-width: 0; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 22px 24px; }
.card-head .eyebrow { margin-bottom: 6px; font-size: 9px; }
.section-title { display: flex; justify-content: space-between; align-items: center; margin: 28px 0 14px; }
.controls { display: flex; align-items: center; gap: 7px; }

/* Calendar. */
.month-title { display: flex; align-items: center; gap: 12px; }
.month-title h2 { font-size: 19px; }
.calendar-scroll { overflow-x: auto; overscroll-behavior-x: contain; }
.calendar { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); min-width: 560px; }
.weekday { padding: 13px 0; border-block: 1px solid var(--line); background: var(--surface); text-align: center; font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.day { min-height: 108px; padding: 8px 5px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); cursor: pointer; overflow: hidden; transition: background .15s; }
.day:nth-child(7n) { border-right: 0; }
.day:hover { background: var(--brand-soft); }
.day:focus-visible { outline-offset: -3px; }
.day.off { background: var(--surface); }
.day.outside { color: #657687; background: var(--surface); }
.day.today { background: var(--brand-soft); }
.day-num { display: grid; place-items: center; width: 27px; height: 27px; margin: 0 0 7px 3px; font-size: 12px; font-weight: 400; font-variant-numeric: tabular-nums; }
.today .day-num { background: var(--brand); color: #fff; border-radius: 9px; }
.event { background: #e6f0de; border-left: 3px solid #78a566; color: #36582d; border-radius: 4px; margin-top: 4px; padding: 4px 5px; font-size: 10px; line-height: 1.5; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.event.half { background: #fbefda; border-color: #c7a052; color: #775820; }
.event.pending { background: #eeebf8; border-color: #a497ce; color: #65528a; }
.event.office { background: #fce9e5; border-color: #cf7967; color: #973f32; font-weight: 700; }
.day.has-event { background: #fff8f6; }
.day.has-event:hover { background: #fceee9; }
.more { padding: 5px; color: var(--muted); font-size: 10px; }
.legend { display: flex; flex-wrap: wrap; gap: 12px 18px; align-items: center; padding: 17px 24px; color: var(--muted); font-size: 11px; }
.legend span { display: flex; align-items: center; gap: 6px; }
.legend-hint { margin-left: auto; }
.swatch { width: 8px; height: 8px; border-radius: 3px; background: #82a76b; }
.swatch.half { background: #c9a360; }
.swatch.pending { background: #a497ce; }
.swatch.office { background: #cf7967; }

/* Requests, people and activity. */
.aside-card { padding: 22px; margin-bottom: 18px; }
.aside-card h2 { font-size: 15px; margin-bottom: 6px; }
.aside-card .sub { font-size: 12px; margin-bottom: 17px; }
.note-card { background: var(--surface-soft); border-color: var(--line); box-shadow: none; }
.note-card p { font-size: 13px; }
.empty { padding: 38px 22px; text-align: center; }
.empty-icon { width: 50px; height: 50px; border: 1px solid var(--line); background: var(--brand-soft); display: grid; place-items: center; border-radius: 16px; margin: 0 auto 16px; color: var(--brand); }
.empty-icon .ui-icon { width: 23px; height: 23px; }
.empty h3 { font-size: 14px; font-weight: 700; }
.empty p { max-width: 330px; margin: auto; font-size: 12px; }
.aside-card .empty { padding: 20px 0 6px; }
.avatar { display: grid; place-items: center; height: 38px; width: 38px; flex-shrink: 0; border: 1px solid var(--line); border-radius: 12px; background: var(--brand-soft); color: var(--brand); font-weight: 700; font-size: 12px; }
.avatar.event-mark { background: #fce9e5; color: #a1402f; border-color: #f0d5ce; }
.away-item { display: flex; align-items: center; gap: 11px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.away-item:last-child { border-bottom: 0; }
.away-item > div { min-width: 0; overflow-wrap: anywhere; }
.away-item strong { display: block; font-size: 13px; font-weight: 700; }
.away-item small { display: block; font-size: 11px; color: var(--muted); line-height: 1.65; margin-top: 4px; }
.away-item .controls { margin-left: auto; flex-shrink: 0; }
.decide { margin-bottom: 24px; border-color: #eadcba; background: #fffcf5; }
.decide .card-head { padding: 20px 24px 17px; }
.decide .card-head h2 { display: flex; align-items: center; gap: 9px; }
.decide .card-head .ui-icon { color: #a98132; }
.decide .sub { font-size: 12px; margin-top: 5px; }
.decide-row { display: flex; align-items: center; gap: 12px; padding: 17px 24px; border-top: 1px solid #f0e7d1; }
.decide-row > div { min-width: 0; overflow-wrap: anywhere; }
.decide-row strong { display: block; font-size: 14px; }
.decide-row small { font-size: 12px; color: var(--muted); line-height: 1.75; }
.decide-row em { color: #84682d; font-style: normal; }
.decide-row .controls { margin-left: auto; flex-shrink: 0; }
.decide-row button[data-status="approved"], .away-item button[data-status="approved"] { background: var(--brand); color: white; border-color: var(--brand); }
.clash, .decide-row em.clash { color: #a1402f; font-style: normal; font-weight: 700; }
.feed-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 10px; }
.feed-row { padding: 13px 0 13px 14px; border-bottom: 1px solid var(--line); font-size: 12px; position: relative; line-height: 1.65; }
.feed-row::before { content: ""; position: absolute; left: 0; top: 21px; height: 5px; width: 5px; border-radius: 50%; background: #c2d7e8; }
.feed-row.unread::before { background: var(--brand); }
.feed-row:last-child { border-bottom: 0; }
.feed-row strong { font-weight: 700; }
.feed-row small { display: block; color: var(--muted); font-size: 11px; margin-top: 4px; }

/* Tables keep horizontal scrolling inside their card on small screens. */
.table-wrap { overflow-x: auto; overscroll-behavior-x: contain; }
table { width: 100%; border-collapse: collapse; text-align: left; white-space: nowrap; }
th { padding: 15px 21px; background: var(--surface); color: var(--muted); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
td { padding: 18px 21px; border-top: 1px solid var(--line); font-size: 13px; line-height: 1.6; }
tbody tr:hover { background: var(--surface); }
td.name { font-weight: 700; }
.team-person { display: flex; align-items: center; gap: 11px; }
.team-person small { display: block; font-weight: 400; color: var(--muted); margin-top: 4px; }
.team-person .pill { margin-top: 5px; }
.pill { display: inline-block; border: 1px solid #dce8d5; border-radius: 6px; padding: 3px 8px; font-size: 11px; font-weight: 400; background: #edf4e7; color: #466638; }
.pill.am, .pill.pm { border-color: #efdfbf; background: #fcf2df; color: #846324; }
.pill.pending { border-color: #e1dbf1; background: #f1edfa; color: #6e588f; }
.pill.cancelled { border-color: #e3e7eb; background: #f1f3f5; color: #697680; }
.pill.declined { border-color: #f0d8d3; background: #fceeea; color: #a05043; }
.table-note { max-width: 220px; white-space: normal; color: var(--muted); font-size: 11px; margin-top: 5px; }
.toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-bottom: 20px; }
.search-field { display: flex; align-items: center; width: min(100%, 350px); position: relative; }
.search-field > .ui-icon { position: absolute; left: 14px; color: #657687; pointer-events: none; }
.search-field input { padding-left: 42px; }
.filter-status { min-width: 170px; max-width: 220px; }
details.note-card { padding: 0; }
details.note-card summary { cursor: pointer; padding: 17px 22px; list-style: none; display: flex; align-items: center; gap: 10px; }
details.note-card summary::-webkit-details-marker { display: none; }
details.note-card summary::before { content: "›"; font-size: 20px; transition: transform .15s; }
details.note-card[open] summary::before { transform: rotate(90deg); }
details.note-card summary h3 { margin: 0; font-size: 13px; }
details.note-card p { padding: 0 22px 17px; }
[hidden] { display: none !important; }

/* Form controls and dialogs. */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { display: grid; gap: 8px; margin-bottom: 20px; }
.field label, .field-label { font-size: 13px; font-weight: 700; }
.field small { font-size: 12px; color: var(--muted); line-height: 1.6; }
input, select, textarea { width: 100%; min-width: 0; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: white; color: var(--text); font-size: 14px; line-height: 1.5; transition: border-color .15s, box-shadow .15s; }
input:hover, select:hover, textarea:hover { border-color: var(--brand-border); }
input:focus, select:focus, textarea:focus { border-color: #00549e; box-shadow: 0 0 0 3px var(--brand-tint); }
input::placeholder, textarea::placeholder { color: #657687; }
input[type="password"] { letter-spacing: .3em; }
input[type="checkbox"] { width: 17px; height: 17px; flex-shrink: 0; accent-color: var(--brand); }
textarea { resize: vertical; min-height: 96px; }
.checks { display: flex; gap: 12px 17px; flex-wrap: wrap; }
.checks label { display: flex; align-items: center; gap: 7px; font-size: 13px; line-height: 1.6; }
.actions { display: flex; justify-content: flex-end; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.inline-error { color: #a04438; background: #fff0eb; border: 1px solid #f0d1c7; padding: 12px 14px; border-radius: 9px; font-size: 13px; line-height: 1.6; margin: 14px 0; }
.help { color: var(--muted); font-size: 12px; line-height: 1.75; }
.card + .help { margin-top: 15px; }
.btn-link { min-height: 28px; border: 0; background: transparent; text-decoration: underline; padding: 3px 1px; font-size: 11px; font-weight: 400; text-underline-offset: 3px; }
.btn-link:hover { background: transparent; color: var(--brand-hover); }
.link-output { font-family: ui-monospace, monospace; font-size: 12px; word-break: break-all; background: var(--surface-soft); padding: 15px; border-radius: 9px; margin: 18px 0; user-select: all; }
dialog { border: 1px solid var(--line); border-radius: 20px; padding: 30px; width: 560px; max-width: calc(100vw - 32px); max-height: calc(100dvh - 40px); overflow-y: auto; color: var(--text); box-shadow: 0 24px 100px #003f7838; }
dialog::backdrop { background: #1736535c; backdrop-filter: blur(5px); }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 26px; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.modal-head h2 { font-size: 25px; letter-spacing: -.8px; font-weight: 700; margin-bottom: 9px; }
.modal-head p { font-size: 13px; }
.modal-head button { padding: 3px; min-width: 32px; min-height: 32px; background: var(--surface); border: 0; font-size: 21px; }
.date-detail { padding: 12px 0; border-bottom: 1px solid var(--line); }
#toast { position: fixed; z-index: 20; bottom: 24px; left: 50%; transform: translateX(-50%); display: none; max-width: 90vw; padding: 14px 22px; border: 1px solid #3376b1; border-radius: 12px; background: var(--brand); color: white; box-shadow: 0 8px 30px #003f7826; font-size: 13px; line-height: 1.6; }
.loading { min-height: 100vh; display: flex; gap: 12px; align-items: center; justify-content: center; color: var(--muted); font-size: 14px; }
.loading::before { content: ""; width: 18px; height: 18px; border: 2px solid var(--brand-border); border-top-color: var(--brand); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.screen-reader { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Sign-in: illustrated welcome beside a focused form. */
.login-page { min-height: 100vh; min-height: 100dvh; display: grid; place-items: center; padding: 36px; background: var(--surface); }
.login-card { width: 100%; max-width: 460px; background: white; border: 1px solid var(--line); border-radius: 22px; padding: 42px; box-shadow: 0 12px 50px #003f7808; }
.login-card > .mark { margin-bottom: 32px; }
.login-card h1 { font-size: 32px; letter-spacing: -1.1px; }
.login-card p { margin: 14px 0 28px; }
.login-card button { width: 100%; }
.login-card .actions button { width: auto; }
.login-card .help { font-size: 12px; margin-bottom: 0; }
.auth-layout { width: 100%; max-width: 1080px; display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--brand-border); border-radius: 28px; overflow: hidden; background: white; box-shadow: 0 18px 70px #003f780a; }
.auth-story { display: flex; flex-direction: column; padding: 36px 40px; background: var(--brand-tint); position: relative; overflow: hidden; }
.auth-story-copy { margin: 36px 0 8px; }
.auth-story-copy h2 { font-family: var(--font-sans); font-size: 48px; line-height: 1.13; font-weight: 400; letter-spacing: -1.2px; color: var(--brand); }
.auth-story-copy p { margin-top: 20px; max-width: 320px; color: var(--muted); font-size: 14px; }
.auth-story-foot { display: flex; gap: 8px; align-items: center; margin-top: auto; padding-top: 24px; color: var(--muted); font-size: 11px; }
.auth-layout .login-card { max-width: none; border: 0; border-radius: 0; box-shadow: none; align-self: center; padding: 52px 46px; }
.auth-layout .login-card > .brand { display: none; }
.auth-layout .login-card > .eyebrow { margin-bottom: 18px; }
.auth-layout .login-card form > button.primary { min-height: 48px; }
.auth-layout .login-card .help { padding-top: 22px; margin-top: 26px; border-top: 1px solid var(--line); }
.calendar-art { position: relative; height: 190px; margin: 24px 0 0; user-select: none; }
.art-sheet { position: absolute; left: 30px; top: 8px; width: 244px; padding: 21px; background: #fff; border: 1px solid var(--brand-border); border-radius: 17px; box-shadow: 9px 12px 0 #d5e6f3; transform: rotate(-7deg); }
.art-binding { height: 16px; display: flex; justify-content: space-between; padding: 0 21px; margin-top: -30px; margin-bottom: 20px; }
.art-binding i { display: block; width: 5px; height: 20px; border-radius: 4px; background: var(--accent); }
.art-lines { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.art-lines::before { content: ""; width: 80px; height: 8px; border-radius: 4px; background: var(--brand); }
.art-lines::after { content: ""; width: 27px; height: 8px; border-radius: 4px; background: var(--brand-tint); }
.art-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; }
.art-days i { height: 18px; background: var(--brand-soft); border-radius: 4px; }
.art-days i:nth-child(7n), .art-days i:nth-child(7n - 1) { background: var(--surface-soft); }
.art-days i:nth-child(n + 10):nth-child(-n + 12) { background: #aecfe8; }
.art-days i:nth-child(18) { background: var(--brand); }
.art-badge { position: absolute; left: 207px; top: 139px; width: 62px; height: 62px; display: grid; place-items: center; border: 6px solid var(--brand-tint); border-radius: 50%; background: var(--brand); color: #fff; transform: rotate(6deg); }
.art-badge .ui-icon { width: 27px; height: 27px; }
.staff-card .brand { margin-bottom: 34px; }
.staff-card .brand .mark { margin: 0; }
.staff-card .eyebrow { margin-bottom: 12px; }
.me-page { display: block; }
.me-card { max-width: 1020px; margin: 0 auto; background: transparent; border: 0; box-shadow: none; padding: 0; }
.me-card > .brand { padding-bottom: 25px; border-bottom: 1px solid var(--line); margin-bottom: 34px; }
.me-card .page-heading { margin-bottom: 28px; }
.me-card h1 { font-size: 36px; }
.me-card button { width: auto; }
.me-card .page-heading p { margin: 0; }
.me-card .aside-card p { margin: 0 0 16px; }
.me-card .aside-card .empty p { margin: auto; }
.me-card .help { margin-top: 16px; }
.me-card .empty { padding: 28px 20px; }
.me-card .stat { padding: 22px; }

/* Narrow laptops, tablets and phones. */
@media (min-width: 1500px) { .day { min-height: 120px; } .event { font-size: 11px; } }
@media (max-width: 1150px) {
  .appbar { padding: 16px 24px; gap: 18px; flex-wrap: wrap; }
  .appbar-right { gap: 6px; }
  .appbar-right button { padding-inline: 11px; }
  .main { padding: 28px 24px; }
  .content-grid { grid-template-columns: minmax(0, 1fr); }
  .aside { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
  .aside-card { margin-bottom: 0; }
  details.aside-card, .me-card .aside-card { margin-bottom: 20px; }
  .auth-story { padding: 34px; }
  .auth-layout .login-card { padding: 40px 32px; }
  .auth-story-copy h2 { font-size: 45px; }
}
@media (max-width: 800px) {
  .appbar { gap: 14px; padding: 14px 18px 10px; }
  .appbar .brand strong { font-size: 15px; }
  .appbar .brand small { font-size: 8px; }
  .appbar .mark { width: 36px; height: 36px; border-radius: 11px; }
  .tabs { order: 3; width: 100%; }
  .tabs button { flex: 1; justify-content: center; }
  .appbar-right button { min-height: 36px; font-size: 11px; padding: 8px 10px; }
  .appbar-right button .ui-icon { display: none; }
  .main { padding: 26px 18px; }
  .page-heading { gap: 16px; margin-bottom: 24px; }
  h1 { font-size: 30px; }
  .page-heading p { font-size: 13px; }
  .stats { gap: 10px; margin-bottom: 22px; }
  .stat { padding: 19px 16px; }
  .stat-symbol { display: none; }
  .stat-label { font-size: 10px; margin-bottom: 12px; }
  .stat strong { font-size: 32px; }
  .stat small { font-size: 11px; }
  .auth-layout { max-width: 540px; grid-template-columns: 1fr; }
  .auth-story { padding: 28px 32px; }
  .auth-story-copy { margin: 28px 0 0; }
  .auth-story-copy h2 { font-size: 35px; letter-spacing: -1px; }
  .auth-story-copy h2 br { display: none; }
  .auth-story-copy p, .calendar-art, .auth-story-foot { display: none; }
  .auth-layout .login-card { padding: 34px 32px; }
  .login-page { padding: 24px; }
  .me-card .stat { padding: 18px 14px; }
  .me-card .page-heading h1 { font-size: 32px; }
}
@media (max-width: 540px) {
  .appbar { padding: 12px 14px 9px; gap: 11px; }
  .appbar .brand { gap: 8px; max-width: 100%; }
  .appbar .brand strong { font-size: 14px; }
  .appbar-right { flex-wrap: wrap; }
  .appbar-right button { padding: 7px 9px; }
  .appbar-right button[data-action="settings"] { font-size: 0; width: 34px; }
  .appbar-right button[data-action="settings"] .ui-icon { display: inline-block; font-size: initial; margin: 0; width: 16px; }
  .appbar-right button[data-action="my-page"] { order: 3; }
  .tabs button { font-size: 12px; padding: 8px 12px; }
  .main { padding: 24px 14px; }
  .page-heading { flex-wrap: wrap; }
  .page-heading > button { min-height: 40px; }
  .page-heading .eyebrow { font-size: 9px; margin-bottom: 8px; }
  h1 { font-size: 28px; letter-spacing: -1px; }
  .stats { gap: 7px; }
  .stat { padding: 16px 11px; border-radius: 12px; }
  .stat-label { font-size: 9px; letter-spacing: .04em; min-height: 24px; margin-bottom: 7px; }
  .stat strong { font-size: 29px; }
  .stat small { font-size: 10px; }
  .content-grid { gap: 16px; }
  .aside { display: flex; flex-direction: column; gap: 16px; }
  .aside-card { padding: 20px; }
  .card-head { padding: 18px 16px; gap: 8px; }
  .month-title h2 { font-size: 17px; }
  .card-head .controls { gap: 4px; }
  .card-head .controls button { padding: 7px 9px; min-height: 34px; }
  .card-head .controls button.icon { min-width: 32px; }
  .calendar { min-width: 490px; }
  .day { min-height: 98px; }
  .legend { padding: 15px 16px; gap: 10px 13px; font-size: 10px; }
  .legend-hint { margin-left: 0; width: 100%; }
  .decide .card-head { padding: 18px; }
  .decide-row { flex-wrap: wrap; padding: 17px; }
  .decide-row > div { flex: 1; }
  .decide-row .controls { margin-left: 50px; }
  .away-item { flex-wrap: wrap; }
  .away-item .controls { margin-left: 49px; }
  .page-footer { flex-direction: column; gap: 8px; font-size: 10px; }
  .form-grid { grid-template-columns: 1fr; gap: 0; }
  input, select, textarea { font-size: 16px; }
  dialog { padding: 22px; border-radius: 16px; }
  .modal-head h2 { font-size: 23px; }
  .login-page { padding: 16px; }
  .login-card { padding: 28px; }
  .auth-layout { border-radius: 20px; }
  .auth-story { padding: 25px; }
  .auth-story-copy { margin-top: 24px; }
  .auth-story-copy h2 { font-size: 30px; }
  .auth-layout .login-card { padding: 29px 25px; }
  .login-card h1 { font-size: 28px; }
  .me-card { padding: 8px 0; }
  .me-card > .brand { margin-bottom: 26px; }
  .me-card .stat { padding: 15px 10px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* Authenticator enrollment (2026-09-18): the QR code and the manual key on the link screen, and the setup code shown once on the Team page. */
.link-output.code { font-size: 28px; letter-spacing: .3em; text-align: center; }
/* Sick leave and the doctor's note (2026-09-21). */
.pill.sick { border-color: #cfe0f0; background: #e9f2fb; color: #2b5b8a; }
.doc em.missing { color: #a1402f; font-style: normal; font-weight: 700; }
.doc .btn-link { font-size: inherit; min-height: 0; padding: 0 1px; vertical-align: baseline; }
.doc-preview { margin: 6px 0 4px; }
.doc-preview img { display: block; max-width: 100%; max-height: 60vh; margin: 0 auto; border: 1px solid var(--line); border-radius: 9px; }
.doc-preview iframe { display: block; width: 100%; height: 60vh; border: 1px solid var(--line); border-radius: 9px; background: #fff; }
.actions a.button { display: inline-flex; align-items: center; min-height: 42px; padding: 11px 17px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--brand); font-size: 13px; font-weight: 700; text-decoration: none; }
.actions a.button:hover { background: var(--surface-soft); border-color: var(--brand-border); }
.actions a.button.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.actions a.button.primary:hover { background: var(--brand-hover); border-color: var(--brand-hover); }
