@font-face {
  font-family: Manrope; font-style: normal; font-weight: 400 800; font-display: swap;
  src: url("vendor/fonts/manrope-cyrillic.woff2") format("woff2");
  unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116;
}
@font-face {
  font-family: Manrope; font-style: normal; font-weight: 400 800; font-display: swap;
  src: url("vendor/fonts/manrope-latin.woff2") format("woff2");
  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 {
  --ink: #201b2e;
  --muted: #615d71;
  --surface: #fff;
  --canvas: #f7f7fb;
  --hairline: #e9e7f0;
  --brand: #6138ca;
  --brand-dark: #4e28af;
  --brand-light: #f0eaff;
  --mint: #e6f6ee;
  --peach: #fff0e8;
  --bs-body-font-family: Manrope, "Segoe UI", system-ui, sans-serif;
  --bs-body-color: var(--ink);
  --bs-body-font-size: .9rem;
  --bs-body-bg: var(--canvas);
  --bs-link-color: var(--brand);
  --bs-link-hover-color: var(--brand-dark);
  --bs-secondary-color: var(--muted);
  --bs-border-color: var(--hairline);
}
a { color: var(--brand); text-underline-offset: .2em; }
button, input, select, textarea { max-width: 100%; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--brand) !important; outline-offset: 2px; }
.skip-link { position: fixed; z-index: 10; padding: .5rem; background: #fff; }
h1, h2, h3 { color: var(--ink); font-weight: 800; letter-spacing: -.035em; overflow-wrap: anywhere; }
h1 { font-size: clamp(1.85rem, 4vw, 2.55rem); line-height: 1.12; margin: 0; }
h2 { font-size: 1.1rem; margin: 0; line-height: 1.3; }
small { color: var(--muted); }
.btn { --bs-btn-font-weight: 750; --bs-btn-font-size: .875rem; --bs-btn-border-radius: .65rem; --bs-btn-padding-x: .95rem; --bs-btn-padding-y: .6rem; white-space: normal; }
.btn .bi { margin-inline-end: .22rem; }
.btn-primary {
  --bs-btn-bg: var(--brand); --bs-btn-border-color: var(--brand);
  --bs-btn-hover-bg: var(--brand-dark); --bs-btn-hover-border-color: var(--brand-dark);
  --bs-btn-active-bg: var(--brand-dark); --bs-btn-active-border-color: var(--brand-dark);
  --bs-btn-disabled-bg: var(--brand); --bs-btn-disabled-border-color: var(--brand);
  --bs-btn-focus-shadow-rgb: 97,56,202;
}
.btn-outline-primary {
  --bs-btn-color: var(--brand-dark); --bs-btn-border-color: #ddd4f5; --bs-btn-bg: #fff;
  --bs-btn-hover-color: var(--brand-dark); --bs-btn-hover-bg: var(--brand-light); --bs-btn-hover-border-color: #cdbcf6;
  --bs-btn-active-color: var(--brand-dark); --bs-btn-active-bg: var(--brand-light); --bs-btn-active-border-color: #cdbcf6;
  --bs-btn-focus-shadow-rgb: 97,56,202;
}
.btn-sm { --bs-btn-padding-y: .43rem; --bs-btn-padding-x: .7rem; --bs-btn-font-size: .8rem; }
.app-shell { display: grid; grid-template-columns: 236px minmax(0, 1fr); min-height: 100vh; }
.sidebar { background: var(--surface); border-right: 1px solid var(--hairline); position: sticky; top: 0; height: 100dvh; display: flex; flex-direction: column; overflow: auto; padding: 1.45rem 1rem 1rem; }
.brand { display: flex; align-items: center; gap: .7rem; padding: .15rem .45rem; color: var(--ink); text-decoration: none; width: fit-content; }
.brand strong { display: block; color: var(--ink); font-size: 1.19rem; font-weight: 800; line-height: 1.1; letter-spacing: -.04em; }
.brand small { display: block; margin-top: .25rem; font-size: .72rem; white-space: nowrap; }
.brand-mark { background: #6b42d9; color: #fff; width: 42px; height: 42px; flex: 0 0 42px; display: grid; place-items: center; border-radius: .8rem; font-size: 1.25rem; box-shadow: 0 4px 9px #5b38b32a; }
.sidebar-nav { margin: 1.8rem 0 1.1rem; }
.nav-heading { padding-inline: .65rem; margin: 1.35rem 0 .55rem; font-size: .65rem; font-weight: 800; text-transform: uppercase; letter-spacing: .11em; color: #6d687d; }
.side-link { color: #4b465b; display: flex; gap: .7rem; align-items: center; padding: .56rem .67rem; margin: .22rem 0; border-radius: .58rem; text-decoration: none; font-weight: 700; }
.side-link .bi { font-size: 1rem; width: 1.15rem; text-align: center; }
.side-link:hover { background: #f7f4fe; color: var(--brand-dark); }
.side-link.selected { background: var(--brand-light); color: var(--brand-dark); font-weight: 800; }
.account { margin-top: auto; border-top: 1px solid var(--hairline); padding: .85rem .32rem .12rem; display: flex; align-items: center; gap: .6rem; }
.account-avatar { display: grid; place-items: center; width: 35px; height: 35px; border-radius: 50%; flex: 0 0 35px; color: var(--brand-dark); background: var(--brand-light); font-weight: 800; }
.account-label { min-width: 0; flex: 1; }
.account-label strong, .account-label small { display: block; overflow: hidden; text-overflow: ellipsis; }
.account-label small { font-size: .69rem; }
.icon-btn { border: 0; color: var(--muted); background: transparent; text-decoration: none; min-width: 34px; min-height: 34px; display: inline-grid; place-items: center; border-radius: .55rem; flex: 0 0 auto; }
.icon-btn:hover { color: var(--brand-dark); background: var(--brand-light); }
.icon-btn.outline { border: 1px solid #e4daff; }
.main-column { min-width: 0; }
.topbar { height: 65px; display: flex; align-items: center; justify-content: space-between; gap: .6rem; padding: 0 clamp(1.2rem, 3vw, 2.65rem); background: var(--surface); border-bottom: 1px solid var(--hairline); }
.topbar-label { display: flex; gap: .7rem; align-items: center; min-width: 0; }
.top-section { font-weight: 750; overflow-wrap: anywhere; }
.menu-toggle { display: none; font-size: 1.32rem; }
.local-time { color: var(--muted); white-space: nowrap; font-size: .79rem; }
.local-time .bi { margin-inline-end: .28rem; }
.main-content { max-width: 1570px; margin: 0 auto; padding: 1.95rem clamp(1.2rem, 3vw, 2.65rem) 2.5rem; }
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; margin-bottom: 1.5rem; }
.page-heading > div { min-width: 0; }
.page-heading p { color: var(--muted); margin: .55rem 0 0; }
.actions { display: flex; flex-wrap: wrap; gap: .55rem; flex: 0 0 auto; }
.date-label { display: flex; align-items: center; gap: .42rem; color: #574179; font-size: .75rem; font-weight: 800; margin-bottom: .46rem; }
.panel { background: var(--surface); border: 1px solid var(--hairline); border-radius: 1rem; min-width: 0; box-shadow: 0 2px 3px #29175203; }
.metrics-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.metric { display: flex; flex-direction: column; align-items: flex-start; padding: 1.12rem 1.2rem; }
.metric-icon { display: grid; place-items: center; flex: 0 0 39px; width: 39px; height: 39px; border-radius: .67rem; font-size: 1.04rem; }
.metric-icon.purple { color: #5731b4; background: var(--brand-light); }
.metric-icon.mint { color: #216b50; background: var(--mint); }
.metric-icon.peach { color: #994c30; background: var(--peach); }
.metric h2 { font-size: .85rem; letter-spacing: 0; color: #534e65; margin: .76rem 0 .14rem; font-weight: 750; }
.metric strong { font-size: clamp(1.2rem, 2.45vw, 2.03rem); font-weight: 800; letter-spacing: -.045em; line-height: 1.25; overflow-wrap: anywhere; max-width: 100%; }
.metric > span:last-child:not(.metric-icon) { margin-top: .35rem; font-size: .73rem; color: var(--muted); }
.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.63fr) minmax(0, 1fr); gap: 1rem; margin-top: 1rem; }
.dashboard-panel { display: flex; flex-direction: column; padding: 1.2rem; }
.section-head { display: flex; align-items: flex-start; justify-content: space-between; gap: .7rem; }
.section-head p, .strip-title p { color: var(--muted); font-size: .78rem; margin: .32rem 0 0; }
.legend { color: var(--muted); font-size: .73rem; display: flex; align-items: center; gap: .35rem; white-space: nowrap; }
.legend span { width: .45rem; height: .45rem; background: #8059e3; border-radius: 50%; }
.chart { height: 180px; margin: 1.3rem 0 .8rem; display: grid; gap: .5rem; grid-template-columns: auto minmax(0,1fr); }
.chart-scale { display: flex; flex-direction: column; justify-content: space-between; align-items: flex-end; color: var(--muted); font-size: .65rem; padding-bottom: 29px; white-space: nowrap; }
.chart-body { height: 100%; min-width: 0; position: relative; display: grid; grid-template-columns: repeat(7,minmax(0,1fr)); }
.chart-gridlines { position: absolute; inset: .35rem 0 34px; border-top: 1px dashed #e2dfeb; border-bottom: 1px solid #e2dfeb; }
.chart-gridlines::before { content: ""; position: absolute; inset: 50% 0 auto; border-top: 1px dashed #e2dfeb; }
.bar-group { display: grid; grid-template-rows: minmax(0,1fr) 34px; min-width: 0; }
.bar-track { margin-top: .35rem; display: flex; align-items: flex-end; justify-content: center; }
.chart-bar { height: max(2px, var(--height)); width: 58%; max-width: 37px; border-radius: .35rem .35rem 0 0; background: #c4b0f4; z-index: 1; }
.bar-current .chart-bar { background: #784ee2; }
.bar-label { padding-top: .4rem; color: var(--muted); text-align: center; font-weight: 700; font-size: .69rem; line-height: 1.1; }
.bar-label small { display: block; font-size: .62rem; margin-top: .17rem; }
.bar-current .bar-label, .bar-current .bar-label small { color: var(--brand-dark); font-weight: 800; }
.chart-footer, .panel-footer { margin-top: auto; border-top: 1px solid var(--hairline); padding-top: .76rem; min-height: 2rem; }
.chart-footer { display: flex; justify-content: space-between; gap: .5rem; color: var(--muted); font-size: .78rem; }
.chart-footer strong { color: var(--ink); font-weight: 800; }
.count-pill { padding: .17rem .55rem; color: var(--brand-dark); background: var(--brand-light); border-radius: 2rem; font-weight: 800; }
.empty-state { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 2.4rem 1rem; min-height: 185px; gap: .33rem; }
.empty-state strong { font-weight: 800; }
.empty-state p { color: var(--muted); font-size: .8rem; margin: 0; max-width: 26ch; }
.empty-state .btn { margin-top: .35rem; }
.empty-icon { width: 51px; height: 51px; display: grid; place-items: center; color: var(--brand); background: #f2edfe; border-radius: 1rem; font-size: 1.3rem; margin-bottom: .23rem; }
.dashboard-panel .empty-state { flex: 1; padding: .85rem .25rem; min-height: 166px; }
.text-link { display: inline-flex; gap: .45rem; align-items: center; font-size: .82rem; font-weight: 800; text-decoration: none; }
.text-link:hover, .back-link:hover { text-decoration: underline; }
.today-list { display: grid; gap: .25rem; padding: .7rem 0; }
.today-list article { display: flex; align-items: center; min-width: 0; gap: .55rem; padding: .35rem 0; }
.today-list article div { min-width: 0; flex: 1; overflow-wrap: anywhere; }
.today-list strong, .today-list small { display: block; }
.appointment-time { color: var(--brand-dark); background: var(--brand-light); padding: .25rem .4rem; border-radius: .36rem; font-weight: 800; }
.result-strip { margin-top: 1rem; display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 1rem 1.2rem; }
.strip-title, .strip-value { display: flex; align-items: center; gap: .7rem; }
.strip-value strong { font-size: 1.18rem; }
.back-link { display: inline-flex; align-items: center; gap: .4rem; text-decoration: none; font-weight: 750; margin-bottom: .8rem; }
.form-panel { padding: clamp(1rem, 2.5vw, 1.65rem); max-width: 790px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .85rem 1rem; }
.field { min-width: 0; }
.field-wide { grid-column: 1 / -1; }
.field label { font-weight: 750; color: #433b53; display: block; margin-bottom: .32rem; }
.field .form-check label { display: inline; }
.form-control, .form-select { --bs-body-bg: #fff; font-size: .875rem; border-radius: .6rem; min-height: 40px; border-color: #dbd7e7; }
.form-control:focus, .form-select:focus { border-color: #a484f1; box-shadow: 0 0 0 .16rem #6d40d620; }
.form-check { padding-top: .3rem; }
.form-check-input:checked { background-color: var(--brand); border-color: var(--brand); }
.form-text, .field-error { font-size: .75rem; margin-top: .24rem; }
.field-error, .errorlist { color: #a02646; }
.errorlist { padding-left: 1.15rem; }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-start; gap: .6rem; border-top: 1px solid var(--hairline); margin-top: 1.05rem; padding-top: 1rem; }
.schedule, .receipt-lines { margin-top: 1.3rem; border-top: 1px solid var(--hairline); padding-top: 1rem; }
.schedule p, .receipt-lines p { color: var(--muted); margin: .35rem 0 .9rem; }
.shift-row { display: grid; grid-template-columns: minmax(100px, 1fr) repeat(2, minmax(0, 1fr)); gap: .55rem; align-items: start; padding: .45rem 0; border-top: 1px solid var(--hairline); }
.shift-row strong { padding-top: .45rem; }
.shift-row label { position: absolute; width: 1px; height: 1px; clip-path: inset(50%); white-space: nowrap; overflow: hidden; }
.secondary-action { margin-top: 1rem; }
.inline-help { padding: .55rem .8rem; background: var(--brand-light); color: var(--brand-dark); border-radius: .55rem; max-width: 790px; margin-bottom: .8rem; }
.checkout-panel { max-width: 960px; }
.receipt-line { display: grid; grid-template-columns: minmax(0,1.4fr) minmax(0,1fr) minmax(0,.65fr) 34px; gap: .55rem; align-items: start; margin-bottom: .75rem; }
.receipt-line .errorlist { grid-column: 1 / -1; margin-bottom: 0; }
.remove-line { margin-top: 1.65rem; color: #9d3c51; }
.receipt-actions { justify-content: space-between; }
.receipt-actions strong { font-size: 1rem; }
.ledger { --bs-table-bg: #fff; --bs-table-color: var(--ink); margin: 0; }
.ledger th, .ledger td { padding: .75rem 1rem; vertical-align: middle; }
.ledger thead th { color: #554d66; font-size: .74rem; background: #fbfafc; white-space: nowrap; }
.ledger tbody tr:last-child td, .ledger tbody tr:last-child th { border-bottom: 0; }
.ledger th a { font-weight: 800; }
.ledger a { text-decoration: none; }
.ledger a:hover { text-decoration: underline; }
.ledger .money-cell { white-space: nowrap; font-weight: 800; }
.table-responsive { border-radius: inherit; }
.panel > .table-heading + .table-responsive { border-radius: 0 0 1rem 1rem; }
.table-heading { padding: .95rem 1rem; }
.status-pill { display: inline-block; padding: .18rem .42rem; border-radius: .38rem; background: #f0edf3; color: #594c65; font-size: .7rem; font-weight: 800; white-space: nowrap; }
.status-pill.active { color: #255f47; background: var(--mint); }
.status-pill.void { color: #9d2f4f; background: #fdebf1; }
.segments { display: flex; flex-wrap: wrap; width: fit-content; gap: .2rem; border: 1px solid var(--hairline); border-radius: .75rem; background: #fff; padding: .24rem; margin-bottom: .95rem; }
.segments a { color: var(--muted); text-decoration: none; font-weight: 750; padding: .4rem .65rem; border-radius: .5rem; }
.segments a.selected, .segments a:hover { background: var(--brand-light); color: var(--brand-dark); }
.filters { display: flex; align-items: flex-end; gap: .42rem; flex-wrap: wrap; }
.filters.compact .form-control, .filters.compact .form-select { min-height: 34px; padding-top: .25rem; padding-bottom: .25rem; }
.filters.compact label { font-size: .72rem; margin-bottom: .16rem; }
.filters .field-error { max-width: 15rem; }
.search-filter { margin: 0 0 .9rem; align-items: center; }
.search-filter input { flex: 1 1 190px; max-width: 330px; }
.pager { display: flex; justify-content: flex-end; gap: .55rem; align-items: center; flex-wrap: wrap; margin-top: .85rem; color: var(--muted); }
.directory-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(min(250px,100%),1fr)); gap: 1rem; }
.directory-card { padding: 1rem; }
.directory-head { display: flex; align-items: center; gap: .65rem; margin-bottom: .7rem; }
.directory-head > div { flex: 1; min-width: 0; }
.directory-head h2 { margin-bottom: .22rem; }
.directory-row { display: flex; justify-content: space-between; gap: .5rem; padding: .48rem 0; border-bottom: 1px solid var(--hairline); overflow-wrap: anywhere; }
.directory-row:last-child { border-bottom: 0; }
.detail-note { padding: 1rem; overflow-wrap: anywhere; margin-bottom: .9rem; }
.detail-note h2 { margin-bottom: .48rem; }
.detail-note p { margin: .4rem 0 0; }
.detail-list { padding-left: 1.2rem; margin-bottom: 0; }
.calendar-toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .7rem; padding: .8rem; }
.week-nav { display: flex; align-items: center; gap: .3rem; }
.calendar-grid { display: grid; grid-template-columns: repeat(7,minmax(0,1fr)); border-top: 1px solid var(--hairline); }
.calendar-day { min-width: 0; min-height: 11rem; border-right: 1px solid var(--hairline); padding: .42rem; }
.calendar-day:last-child { border-right: 0; }
.calendar-day header { display: flex; align-items: center; gap: .25rem; font-size: .72rem; margin-bottom: .25rem; }
.calendar-day header strong { font-size: .9rem; }
.calendar-day header .icon-btn { margin-left: auto; min-width: 25px; min-height: 31px; }
.calendar-today { background: #fcfaff; }
.calendar-today header { color: var(--brand-dark); }
.calendar-empty { color: var(--muted); font-size: .7rem; padding: .26rem; }
.calendar-item { border-radius: .5rem; padding: .42rem; background: #f2eefe; margin-bottom: .4rem; display: grid; gap: .1rem; color: #443753; font-size: .72rem; overflow-wrap: anywhere; }
.calendar-item time { font-weight: 800; color: var(--brand-dark); }
.calendar-item a { font-weight: 800; text-decoration: none; }
.calendar-item a:hover { text-decoration: underline; }
.calendar-item.status-done { background: var(--mint); }
.calendar-item.status-cancelled { background: #f1eff4; }
.calendar-actions { margin-top: .27rem; display: grid; gap: .24rem; }
.calendar-actions a { display: block; }
.status-label { font-weight: 800; }
.report-filters { display: flex; gap: .7rem 1rem; align-items: flex-end; flex-wrap: wrap; margin-bottom: 1rem; }
.report-filters .segments { margin: 0; }
.report-period { margin-block: 1rem .65rem; }
.report-metrics { grid-template-columns: repeat(4,minmax(0,1fr)); }
.report-grid { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1.55fr); gap: 1rem; margin-top: 1rem; }
.report-grid .section-head { margin-bottom: .55rem; }
.report-breakdown { margin-top: 1rem; }
.ledger.compact-table th, .ledger.compact-table td { padding-inline: .45rem; }
.backup-panel { display: flex; gap: .8rem; max-width: 670px; padding: 1.25rem; }
.backup-panel p { margin: .4rem 0 .8rem; color: var(--muted); }
.login-shell { min-height: 100dvh; display: grid; place-items: center; background: radial-gradient(ellipse at 15% 15%,#e8e0ff 0,transparent 46%),radial-gradient(ellipse at 90% 90%,#eee6ff 0,transparent 44%),var(--canvas); padding: 1rem; }
.login-card { width: min(100%, 425px); background: #fff; border: 1px solid var(--hairline); border-radius: 1.3rem; padding: clamp(1.3rem,5vw,2.2rem); box-shadow: 0 15px 48px #23114412; }
.login-brand { padding: 0; margin-bottom: 1.45rem; }
.login-card h1 { font-size: 1.85rem; margin-bottom: .45rem; }
.login-card .field { margin-bottom: .82rem; }
.login-card form .btn { margin-top: .35rem; }
.login-local { color: var(--muted); font-size: .76rem; margin-top: 1.2rem; padding-top: .85rem; border-top: 1px solid var(--hairline); }
.direct-login { padding: 1rem; }
.direct-login .btn { margin-top: 1rem; }
@media (max-width: 1100px) {
  .app-shell { grid-template-columns: 205px minmax(0,1fr); }
  .calendar-grid { grid-template-columns: repeat(4,minmax(0,1fr)); }
  .calendar-day { border-bottom: 1px solid var(--hairline); }
}
@media (max-width: 880px) {
  .app-shell { display: flex; flex-direction: column; position: relative; }
  .sidebar { height: auto; width: 100%; top: 0; position: relative; display: none; border-right: 0; border-bottom: 1px solid var(--hairline); max-height: 69dvh; order: 0; }
  .sidebar.menu-open { display: flex; }
  .menu-toggle { display: inline-grid; }
  .topbar { height: 55px; }
  .main-column { width: 100%; }
  .main-content { padding-top: 1.33rem; }
}
@media (max-width: 680px) {
  .page-heading { flex-wrap: wrap; align-items: flex-start; margin-bottom: 1rem; }
  .metrics-grid, .dashboard-grid, .report-grid { gap: .65rem; }
  .dashboard-grid, .report-grid { grid-template-columns: 1fr; }
  .report-metrics, .calendar-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .metric { padding: .72rem .62rem; }
  .metric h2 { margin-top: .43rem; font-size: .75rem; }
  .metric > span:last-child:not(.metric-icon) { font-size: .64rem; }
  .metric-icon { width: 31px; height: 31px; flex-basis: 31px; font-size: .89rem; }
  .dashboard-panel { padding: .88rem; }
  .result-strip { padding: .75rem; flex-wrap: wrap; }
  .calendar-day { min-height: 6.5rem; }
  .table-responsive table { min-width: 425px; }
  .form-grid { grid-template-columns: 1fr; gap: .7rem; }
  .form-control, .form-select { font-size: 1rem; }
  .receipt-line { padding: .65rem; border: 1px solid var(--hairline); border-radius: .6rem; grid-template-columns: minmax(0,1fr) 34px; }
  .receipt-line > .field { grid-column: 1 / -1; }
  .receipt-line > .field:has(input[type="number"]) { grid-column: 1; }
  .receipt-line .remove-line { grid-column: 2; }
  .tz-offset { display: none; }
}
@media (max-width: 340px) {
  .main-content, .topbar { padding-inline: .75rem; }
  .metrics-grid { grid-template-columns: 1fr 1fr; }
  .shift-row { grid-template-columns: 1fr 1fr; }
  .shift-row strong { grid-column: 1 / -1; }
}

.calendar-master-color {
  --calendar-accent: hsl(var(--master-hue) 60% 37%);
  border-left: 3px solid var(--calendar-accent);
  background: hsl(var(--master-hue) 56% 95%);
}
.calendar-master-color.status-done { background: hsl(var(--master-hue) 32% 94%); }
.calendar-master-color.status-cancelled { background: hsl(var(--master-hue) 19% 96%); border-left-style: dashed; }
.calendar-master-color time { color: var(--calendar-accent); }
.calendar-availability { margin-top: .35rem; font-size: .76rem; }
.calendar-availability summary { cursor: pointer; padding: .35rem .15rem; font-weight: 700; }
.calendar-free-master { margin: .25rem 0 .1rem; font-weight: 700; color: hsl(var(--master-hue) 58% 34%); overflow-wrap: anywhere; }
.calendar-slot { text-decoration: none; display: inline-flex; align-items: center; padding: .35rem; margin: .13rem; min-height: 32px; background: var(--brand-light); color: var(--brand-dark); border-radius: .45rem; white-space: nowrap; font-variant-numeric: tabular-nums; }
.calendar-slot:hover { text-decoration: underline; }
@media (pointer: coarse) { .calendar-slot, .calendar-availability summary { min-height: 44px; } }

.payroll-card { margin-block: 0 1rem; }
.payroll-metrics { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(145px,100%),1fr)); gap: .55rem; margin: .85rem 0; }
.payroll-metrics > div { background: #f8f6fc; border: 1px solid var(--hairline); border-radius: .6rem; padding: .65rem .75rem; }
.payroll-metrics dt { color: var(--muted); font-size: .78rem; }
.payroll-metrics dd { color: var(--ink); font-size: 1.1rem; font-weight: 800; margin: .2rem 0 0; }
.payroll-categories { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: .4rem; }
.payroll-categories li { padding: .35rem .55rem; background: var(--brand-light); border-radius: .55rem; }
.payroll-categories strong { margin-left: .3rem; }
.payroll-checks { border-top: 1px solid var(--hairline); padding-top: .6rem; }
.payroll-checks summary { font-weight: 750; cursor: pointer; padding: .35rem 0; }
.payroll-check { border-top: 1px solid var(--hairline); padding: .55rem 0; }
.payroll-check header { display: flex; flex-wrap: wrap; gap: .3rem .7rem; align-items: center; }
.payroll-check header a { font-weight: 800; }
.payroll-check ul { margin: .35rem 0 0; padding-left: 1.35rem; }

.material-editor { border-top: 1px solid var(--hairline); margin-top: .9rem; padding-top: .8rem; }
.material-editor h2 { font-size: 1.15rem; margin-bottom: .5rem; }
.material-picker label, .material-quantity > span { display: block; font-size: .78rem; font-weight: 750; margin-bottom: .2rem; }
.material-row { padding: .65rem 0; border-bottom: 1px solid var(--hairline); display: grid; grid-template-columns: minmax(0,1fr) minmax(80px,125px) auto 34px; gap: .45rem; align-items: center; }
.material-row-heading strong, .material-row-heading small { display: block; overflow-wrap: anywhere; }
.material-row output { font-weight: 800; text-align: right; }
.material-quantity [aria-invalid="true"] { border-color: #b73f5b; }
.material-remove { color: var(--muted); }
.material-subtotal { display:flex; justify-content:space-between; gap:.55rem; margin-top:.5rem; color:var(--muted); }
@media (max-width: 540px) {
  .material-row { grid-template-columns: minmax(0,1fr) auto 34px; }
  .material-row-heading { grid-column: 1 / -1; }
}

.category-list { padding: .75rem 1rem; }
.category-list > div { display: flex; flex-wrap: wrap; align-items: center; gap: .65rem; padding: .65rem 0; }
.category-list > div + div { border-top: 1px solid var(--hairline); }
.category-list > div > a:first-child { flex: 1 1 13rem; overflow-wrap: anywhere; }
.category-list small { color: var(--muted); }
.category-list .btn { min-height: 44px; }
@media (max-width: 710px) {
  .page-heading, .segments, .form-actions { flex-wrap: wrap; }
  .form-grid > *, .main-content { min-width: 0; }
  .form-panel :is(input, select, textarea):not([type="checkbox"]) { min-height: 44px; font-size: 1rem; }
}

.online-main { max-width:42rem; margin:auto; padding:clamp(1rem,4vw,2.5rem); }
.online-main .form-panel { display:grid; gap:1rem; margin:1rem 0; }
.online-main :is(input:not([type=checkbox]),select,button,summary), .online-main #id_services label { min-height:44px; font-size:1rem; }
.online-main #id_services label { display:flex; align-items:center; gap:.5rem; }
.online-main #id_services input { width:1.2rem; height:1.2rem; }
@media(max-width:880px) {
  .menu-toggle, .side-link, .form-actions .btn, .calendar-availability summary { min-height:44px; }
  .sidebar.menu-open { overscroll-behavior:contain; }
  .table-responsive { max-width:100%; overflow-x:auto; }
  .form-panel :is(input,select,textarea) { max-width:100%; font-size:1rem; }
  .calendar-grid { min-width:0; }
  .calendar-actions { display:flex; flex-wrap:wrap; gap:.4rem; }
  .calendar-actions a { display:inline-flex; min-height:44px; align-items:center; }
}
