@font-face {
  font-family: Manrope;
  src: url('/brand/Manrope-latin-variable.woff2') format('woff2');
  font-weight: 200 800;
  font-display: swap;
}

:root {
  color-scheme: light;
  --ink: #15334e;
  --muted: #486073;
  --line: #d9e3e9;
  --control: #7b92a2;
  --paper: #faf9f6;
  --blue-soft: #edf5fb;
  --gold: #f1c76b;
  --gold-soft: #f9efd9;
  --danger: #8c2836;
  font: 16px/1.5 Manrope, 'Segoe UI', sans-serif;
  color: var(--ink);
  background: var(--paper);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; }
main { min-height: calc(100vh - 80px); }
button, input, select { font: inherit; }
button { cursor: pointer; }
button:disabled { opacity: .55; cursor: default; }
:focus-visible { outline: 3px solid #24669a; outline-offset: 3px; }
h1, h2, p, ul { margin: 0; }
h1 { font-size: clamp(1.66rem, 3vw, 2.5rem); letter-spacing: -.04em; line-height: 1.1; }
h2 { font-size: 1.15rem; letter-spacing: -.02em; }
a { color: inherit; text-underline-offset: 3px; }
.muted { color: var(--muted); font-size: .88rem; }
.visually-hidden, .skip-link:not(:focus) {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip-link:focus { position: fixed; z-index: 10; top: 10px; left: 14px; background: var(--gold); padding: 10px 16px; border-radius: 8px; }

.topbar { background: white; border-bottom: 1px solid var(--line); }
.topbar-content {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px 22px;
  min-height: 80px;
  width: min(1510px, calc(100% - 52px));
  margin-inline: auto;
  padding-block: 8px;
}
.logo { width: 185px; height: auto; display: block; }
.product-name { border-inline-start: 1px solid var(--line); padding-inline-start: 22px; font-weight: 750; font-size: .94rem; }
.account-bar { margin-inline-start: auto; display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; font-size: .86rem; font-weight: 680; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 7px 14px;
  border: 1px solid var(--control);
  border-radius: 9px;
  background: #fff;
  color: var(--ink);
  font-size: .86rem;
  font-weight: 750;
  white-space: nowrap;
}
.button:not(:disabled):hover { background: var(--blue-soft); }
.button-primary { border-color: var(--ink); color: white; background: var(--ink); }
.button-primary:not(:disabled):hover { background: #244c6f; }
.button-small { min-height: 36px; padding-inline: 11px; }
.button-danger { color: var(--danger); border-color: #ad6370; }
.button-link { background: transparent; border: 0; padding-inline: 0; text-decoration: underline; text-underline-offset: 3px; }
.button-link:not(:disabled):hover { background: transparent; }

.startup, .auth-panel { width: min(460px, calc(100% - 32px)); margin: clamp(34px, 9vh, 110px) auto 40px; }
.auth-panel {
  padding: clamp(22px, 5vw, 36px);
  border-radius: 16px;
  border: 1px solid var(--line);
  border-top: 5px solid var(--gold);
  background: white;
  box-shadow: 0 15px 34px #15334e0c;
}
.intro { margin-top: 10px; margin-bottom: 22px; color: var(--muted); }
.notice, .error { margin-block: 0 16px; padding: 10px 12px; border-radius: 7px; border: 1px solid #bdd4e5; background: var(--blue-soft); font-size: .88rem; }
.error { background: #fff2f3; border-color: #e8b9bf; color: var(--danger); }
form, label { display: grid; gap: 9px; }
form { gap: 14px; }
form > .button { justify-self: stretch; }
label { font-weight: 750; font-size: .83rem; }
input, select { min-width: 0; min-height: 42px; padding: 8px 10px; border: 1px solid var(--control); border-radius: 8px; background: white; color: var(--ink); font-size: .9rem; }
form small { color: var(--muted); margin-top: -9px; }
.authenticator { display: grid; grid-template-columns: minmax(0, auto) 1fr; align-items: center; gap: 12px; padding: 10px 11px; background: var(--blue-soft); border-radius: 8px; font-size: .85rem; }
.authenticator code { display: block; margin-top: 5px; overflow-wrap: anywhere; }
.authenticator p + p { margin-top: 8px; }
.qr { width: 122px; max-width: 100%; color: var(--ink); }
.qr svg { display: block; height: auto; }

.workspace { width: min(1510px, calc(100% - 52px)); margin: 0 auto; padding-block: 30px 40px; }
.workspace-header { display: flex; align-items: end; justify-content: space-between; flex-wrap: wrap; gap: 16px; margin-bottom: 19px; }
.section-nav { display: flex; flex-wrap: wrap; gap: 4px; }
.nav-button { appearance: none; border: 0; border-radius: 7px; color: var(--ink); background: transparent; padding: 8px 11px; font-size: .87rem; font-weight: 760; }
.nav-button:hover { background: var(--blue-soft); }
.nav-button[aria-current='page'] { background: var(--ink); color: white; }
.week-toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 12px; background: white; border: 1px solid var(--line); border-radius: 12px; }
.week-controls { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.week-arrow { width: 38px; padding: 0; font-size: 1.48rem; line-height: 1; }
.week-picker select { font-weight: 760; }
.week-context { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 3px 16px; padding: 12px 1px 10px; }
.week-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; align-items: start; }
.day-panel { min-width: 0; min-height: 130px; overflow: hidden; border-radius: 10px; border: 1px solid var(--line); background: #fff; }
.day-panel h2 { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 2px 4px; border-bottom: 1px solid var(--line); padding: 9px 9px; background: var(--blue-soft); text-transform: capitalize; font-size: .81rem; }
.day-panel time { color: var(--muted); font-size: .73rem; font-weight: 690; text-transform: none; }
.day-panel.today { border-color: #9f7a31; }
.day-panel.today h2 { background: var(--gold-soft); }
.empty-day { padding: 12px 9px; color: var(--muted); font-size: .8rem; }
.shift-list { display: grid; gap: 5px; list-style: none; padding: 7px; }
.shift-card { display: grid; width: 100%; gap: 0; padding: 6px 7px; border: 1px solid #dee6eb; border-inline-start: 3px solid #76b6df; border-radius: 6px; background: #fafdff; text-align: start; color: var(--ink); overflow-wrap: anywhere; }
button.shift-card:hover { border-color: #5a7e99; background: var(--blue-soft); }
.shift-time { font-weight: 800; font-size: .77rem; font-variant-numeric: tabular-nums; }
.shift-label { font-size: .77rem; }
.shift-person { color: var(--muted); font-size: .74rem; }

.service-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); align-items: start; gap: 10px; margin-top: 13px; }
.service-card { padding: 13px 15px; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.service-card h2 { font-size: .98rem; }
.service-card ul { padding-inline-start: 21px; margin-top: 6px; color: var(--muted); font-size: .84rem; }
.people-heading { display: flex; justify-content: space-between; align-items: end; flex-wrap: wrap; gap: 12px; margin-bottom: 10px; }
.search-field { width: min(100%, 290px); }
.table-wrap { overflow: auto; padding-bottom: 1px; border: 1px solid var(--line); border-radius: 10px; background: white; }
table { width: 100%; border-collapse: collapse; text-align: start; font-size: .85rem; }
th, td { text-align: start; padding: 8px 12px; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
thead { background: var(--blue-soft); }
tbody tr:last-child > * { border-bottom: 0; }
#people-panel > h2 { margin-block: 19px 9px; }

dialog { width: min(460px, calc(100% - 30px)); max-height: calc(100vh - 30px); padding: 22px; overflow: auto; color: var(--ink); background: white; border: 1px solid var(--line); border-radius: 14px; }
dialog::backdrop { background: #122b45a0; }
.time-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.form-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 6px; }
#invite-result { display: grid; gap: 10px; }
#invite-result .button { justify-self: start; }

@media (max-width: 1150px) {
  .week-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .topbar-content, .workspace { width: calc(100% - 32px); }
  .logo { width: 145px; }
  .product-name { padding-inline-start: 12px; font-size: .82rem; }
  .topbar-content { gap: 7px 12px; }
  .account-bar { margin-top: 2px; }
  .workspace { padding-block: 20px 30px; }
  .week-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .day-panel { min-height: 85px; }
}

@media (max-width: 430px) {
  .week-grid { grid-template-columns: minmax(0, 1fr); }
  .authenticator { grid-template-columns: 1fr; }
  .account-bar { margin-inline-start: 0; }
  .week-toolbar { padding: 8px; }
  .shift-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .time-fields { grid-template-columns: minmax(0, 1fr); }
}
