:root {
  color-scheme: dark;
  --ink: #f3efe7;
  --text: #f3efe7;
  --muted: #a8b0b8;
  --line: #333b42;
  --line-strong: #46505a;
  --panel: #1e2429;
  --panel-2: #252c32;
  --page: #121619;
  --surface-0: #121619;
  --surface-1: #171d21;
  --surface-2: #1e2429;
  --surface-3: #252c32;
  --surface-field: #11171b;
  --theme-glow: rgba(66, 184, 168, 0.18);
  --accent: #42b8a8;
  --accent-strong: #60d5c2;
  --sun: #e0a84f;
  --red: #e06f63;
  --blue: #6d9ed0;
  --green: #77bd8e;
  --shadow: 0 18px 46px rgba(0, 0, 0, 0.34);
  --radius: 8px;
  --radius-soft: 12px;
}

:root[data-theme="bmc"] {
  color-scheme: dark;
  --ink: #d0dbe2;
  --text: #d0dbe2;
  --muted: #8796a2;
  --line: #2b3d4f;
  --line-strong: #536a7c;
  --panel: #172331;
  --panel-2: #1f2e3e;
  --page: #101923;
  --surface-0: #101923;
  --surface-1: #152130;
  --surface-2: #1b2938;
  --surface-3: #243443;
  --surface-field: #0f1a26;
  --theme-glow: rgba(111, 167, 166, 0.12);
  --accent: #668f92;
  --accent-strong: #91b6b7;
  --sun: #b48a43;
  --red: #d9827a;
  --blue: #7fa4c7;
  --green: #7fb292;
  --shadow: 0 16px 38px rgba(3, 8, 14, 0.32);
}

:root[data-theme="graphite"] {
  --ink: #f4f0e7;
  --text: #f4f0e7;
  --muted: #b5afa4;
  --line: #3d3a33;
  --line-strong: #5b5548;
  --panel: #25231f;
  --panel-2: #302c25;
  --page: #171614;
  --surface-0: #151412;
  --surface-1: #1d1b17;
  --surface-2: #25231f;
  --surface-3: #302c25;
  --surface-field: #14120f;
  --theme-glow: rgba(200, 163, 75, 0.18);
  --accent: #c8a34b;
  --accent-strong: #f0c96a;
  --sun: #d89b45;
  --red: #e37967;
  --blue: #8aa1bf;
  --green: #83b883;
}

:root[data-theme="ember"] {
  --ink: #f7eee8;
  --text: #f7eee8;
  --muted: #b8aaa3;
  --line: #473a38;
  --line-strong: #684f4a;
  --panel: #2a2025;
  --panel-2: #38292f;
  --page: #171216;
  --surface-0: #171216;
  --surface-1: #21191d;
  --surface-2: #2a2025;
  --surface-3: #38292f;
  --surface-field: #151014;
  --theme-glow: rgba(217, 121, 93, 0.2);
  --accent: #d9795d;
  --accent-strong: #ff9b7f;
  --sun: #e2ad5f;
  --red: #ef6f6f;
  --blue: #8299c9;
  --green: #87bd98;
}

:root[data-theme="light"] {
  color-scheme: light;
  --ink: #15202b;
  --text: #15202b;
  --muted: #667382;
  --line: #d8e0e8;
  --line-strong: #b9c6d3;
  --panel: #ffffff;
  --panel-2: #f4f7fa;
  --page: #eef3f7;
  --surface-0: #eef3f7;
  --surface-1: #f7fafc;
  --surface-2: #ffffff;
  --surface-3: #eef3f7;
  --surface-field: #ffffff;
  --theme-glow: rgba(33, 132, 119, 0.16);
  --accent: #248678;
  --accent-strong: #0f6f65;
  --sun: #c38a22;
  --red: #bf4f48;
  --blue: #336fb0;
  --green: #2f8e62;
  --shadow: 0 18px 44px rgba(40, 63, 87, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  max-width: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  max-width: 100%;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at top left, rgba(66, 184, 168, 0.18), transparent 34rem),
    linear-gradient(135deg, #111518 0%, #171316 46%, #151b19 100%);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 15px;
}

:root[data-theme="graphite"] body {
  background:
    radial-gradient(circle at top left, rgba(200, 163, 75, 0.16), transparent 34rem),
    linear-gradient(135deg, #141412 0%, #191815 46%, #171915 100%);
}

:root[data-theme="bmc"] body {
  background:
    radial-gradient(circle at 12% 0%, rgba(111, 167, 166, 0.07), transparent 28rem),
    linear-gradient(135deg, #101923 0%, #121f2b 52%, #152535 100%);
}

:root[data-theme="ember"] body {
  background:
    radial-gradient(circle at top left, rgba(217, 121, 93, 0.17), transparent 34rem),
    linear-gradient(135deg, #151214 0%, #1b1416 46%, #16171b 100%);
}

:root[data-theme="light"] body {
  background:
    radial-gradient(circle at 10% 0%, rgba(36, 134, 120, 0.14), transparent 30rem),
    radial-gradient(circle at 85% 0%, rgba(195, 138, 34, 0.12), transparent 28rem),
    linear-gradient(135deg, #eef3f7 0%, #f8fafc 48%, #edf4f2 100%);
}

a {
  color: var(--accent-strong);
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 1px solid var(--line);
  background: linear-gradient(180deg, #293139, #20262c);
  color: var(--ink);
  min-height: 38px;
  padding: 0 13px;
  border-radius: var(--radius);
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transition: border-color 140ms ease, background 140ms ease, color 140ms ease, transform 140ms ease;
}

button:hover {
  border-color: var(--accent);
  color: #ffffff;
  transform: translateY(-1px);
}

button:disabled {
  cursor: default;
  filter: saturate(0.25);
  opacity: 0.55;
  transform: none;
}

button:disabled:hover {
  border-color: var(--line);
  color: var(--ink);
  transform: none;
}

.topbar {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
  min-height: 88px;
  padding: 12px 24px;
  background: rgba(20, 24, 27, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
  max-width: 100vw;
  overflow: hidden;
}

.brand-lockup {
  align-items: center;
  display: flex;
  gap: 14px;
  min-width: 210px;
}

.brand-logo {
  aspect-ratio: 3 / 2;
  border: 1px solid color-mix(in srgb, var(--accent) 42%, var(--line) 58%);
  border-radius: 8px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.28);
  height: 58px;
  object-fit: cover;
  object-position: center;
  width: 88px;
}

.theme-control {
  align-items: center;
  display: flex;
  gap: 9px;
  justify-self: end;
  white-space: nowrap;
}

.theme-control select {
  min-height: 34px;
  min-width: 178px;
  padding: 6px 9px;
}

.nav-link-button {
  align-items: center;
  background: linear-gradient(180deg, #293139, #20262c);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink);
  display: inline-flex;
  font-weight: 800;
  min-height: 38px;
  padding: 0 13px;
  text-decoration: none;
}

.nav-link-button:hover {
  border-color: var(--accent);
  color: #fff;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  font-size: 27px;
  line-height: 1.1;
  letter-spacing: 0;
}

h2 {
  font-size: 21px;
  line-height: 1.2;
  letter-spacing: 0;
}

h3 {
  font-size: 15px;
  margin-bottom: 12px;
}

.eyebrow {
  color: var(--accent-strong);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
  margin-bottom: 5px;
}

.topbar-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.icon-button {
  width: 38px;
  padding: 0;
  display: inline-grid;
  place-items: center;
}

.app-shell {
  display: grid;
  grid-template-columns: minmax(0, 190px) minmax(0, 1fr);
  gap: 16px;
  max-width: 100vw;
  padding: 16px;
  width: 100%;
}

.site-footer {
  align-items: center;
  border-top: 1px solid var(--line);
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  justify-content: space-between;
  margin: 8px 16px 20px;
  padding: 14px 2px 0;
  font-size: 12px;
  font-weight: 750;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.site-footer a {
  color: var(--accent-strong);
  text-decoration: none;
}

.site-footer a:hover {
  color: #fff;
}

.sidebar {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-self: start;
  min-width: 0;
  overflow: visible;
  position: sticky;
  top: 92px;
}

.panel,
.workspace {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.panel {
  padding: 15px;
  background: linear-gradient(180deg, rgba(37, 44, 50, 0.98), rgba(28, 33, 38, 0.98));
}

.panel-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
}

label {
  color: var(--muted);
  display: grid;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink);
  background: #161b1f;
  min-height: 38px;
  padding: 8px 10px;
  font-weight: 650;
}

input::placeholder {
  color: var(--muted);
  opacity: 1;
}

input[type="date"].empty-date {
  color: var(--muted);
}

input[type="date"]::-webkit-datetime-edit {
  color: var(--text);
}

input[type="date"].empty-date::-webkit-datetime-edit {
  color: var(--muted);
}

input[type="date"]::-webkit-calendar-picker-indicator {
  opacity: 0.72;
}

select:has(option[value=""]:checked) {
  color: var(--muted);
}

select option {
  color: var(--text);
}

select option[value=""] {
  color: var(--muted);
}

select[multiple] {
  min-height: 112px;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(66, 184, 168, 0.18);
  outline: none;
}

textarea {
  resize: vertical;
}

form {
  display: grid;
  gap: 11px;
}

.time-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.primary-button {
  background: linear-gradient(180deg, var(--accent), #2e9c90);
  border-color: var(--accent);
  color: #071412;
  font-weight: 900;
  box-shadow: 0 10px 22px rgba(66, 184, 168, 0.18);
}

.primary-button:hover {
  background: linear-gradient(180deg, var(--accent-strong), var(--accent));
  border-color: var(--accent-strong);
  color: #071412;
}

.primary-button:disabled,
.primary-button:disabled:hover {
  background: #283038;
  border-color: var(--line);
  box-shadow: none;
  color: var(--muted);
}

.tabs {
  display: grid;
  grid-template-columns: 1fr;
  gap: 7px;
  overflow: visible;
}

.tab-button {
  justify-content: flex-start;
  font-weight: 900;
  background: #20262c;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  transform: none;
  width: 100%;
}

.tab-button:hover {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 0 0 1px color-mix(in srgb, var(--accent) 34%, transparent);
  transform: none;
}

.tab-button.active {
  color: #081312;
  background: var(--accent);
  border-color: var(--accent);
}

.development-nav {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(17, 23, 27, 0.68);
  overflow: hidden;
}

.development-nav summary {
  align-items: center;
  color: var(--muted);
  cursor: pointer;
  display: flex;
  font-size: 12px;
  font-weight: 950;
  justify-content: space-between;
  list-style: none;
  min-height: 36px;
  padding: 0 11px;
  text-transform: uppercase;
}

.development-nav summary::-webkit-details-marker {
  display: none;
}

.development-nav summary::after {
  color: var(--accent-strong);
  content: "+";
  font-size: 17px;
  font-weight: 950;
}

.development-nav[open] summary::after {
  content: "-";
}

.development-nav > div {
  border-top: 1px solid var(--line);
  display: grid;
  gap: 6px;
  padding: 7px;
}

.development-nav .tab-button {
  background: #171d21;
  font-size: 13px;
  min-height: 34px;
}

.sidebar-summary {
  display: grid;
  gap: 8px;
}

.sidebar-summary strong {
  font-size: 18px;
}

.sidebar-summary p:last-child {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.workspace {
  min-width: 0;
  min-height: calc(100vh - 108px);
  overflow: hidden;
  background: linear-gradient(180deg, rgba(32, 38, 43, 0.98), rgba(25, 30, 34, 0.98));
}

.legal-page {
  background:
    radial-gradient(circle at top left, rgba(66, 184, 168, 0.14), transparent 28rem),
    linear-gradient(135deg, #111518 0%, #171316 46%, #151b19 100%);
}

.legal-topbar {
  position: sticky;
  top: 0;
  z-index: 5;
}

.legal-shell {
  margin: 0 auto;
  max-width: 900px;
  padding: 22px 16px 8px;
}

.legal-document {
  display: grid;
  gap: 22px;
}

.legal-document section {
  display: grid;
  gap: 10px;
}

.legal-document h2 {
  font-size: 18px;
}

.legal-document p,
.legal-document li,
.legal-document address {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.62;
}

.legal-document ul {
  margin: 0;
  padding-left: 20px;
}

.legal-document address {
  font-style: normal;
}

.legal-updated {
  color: var(--accent-strong);
  font-weight: 900;
}

.view {
  display: none;
  padding: 20px;
}

.view.active {
  display: block;
}

.view-header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  margin-bottom: 20px;
}

.view-subtitle {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
  line-height: 1.45;
  margin-top: 6px;
  max-width: 560px;
}

.admin-view-header {
  align-items: center;
  background:
    linear-gradient(135deg, rgba(77, 224, 206, 0.075), transparent 42%),
    linear-gradient(180deg, rgba(35, 43, 49, 0.82), rgba(24, 30, 35, 0.78));
  border: 1px solid rgba(255, 255, 255, 0.065);
  border-radius: var(--radius-soft);
  margin-bottom: 14px;
  padding: 16px;
}

.admin-view-header h2 {
  font-size: 25px;
}

#dataView:has(#adminSchedulePanel.active) {
  padding-top: 12px;
}

#dataView:has(#adminSchedulePanel.active) .admin-view-header {
  align-items: center;
  margin-bottom: 8px;
  padding: 10px 12px;
}

#dataView:has(#adminSchedulePanel.active) .admin-view-header h2 {
  font-size: 20px;
  line-height: 1;
}

#dataView:has(#adminSchedulePanel.active) .admin-view-header .view-subtitle {
  margin-top: 3px;
}

#dataView:has(#adminSchedulePanel.active) .admin-subtabs {
  margin-bottom: 8px;
}

.calendar-header {
  align-items: center;
  background: linear-gradient(180deg, rgba(35, 43, 49, 0.72), rgba(24, 30, 35, 0.72));
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-soft);
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(280px, 1fr) auto;
  margin-bottom: 10px;
  padding: 8px 12px;
}

.calendar-title-group {
  min-width: 0;
}

.calendar-header h2 {
  font-size: 20px;
  line-height: 1.1;
  min-height: 22px;
  white-space: nowrap;
}

.calendar-controls-row {
  align-items: stretch;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.calendar-week-actions {
  align-items: center;
  background: #141a1e;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: flex;
  gap: 7px;
  min-height: 38px;
  padding: 4px 6px;
}

.calendar-week-actions > span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
}

.calendar-week-actions .topbar-actions {
  flex-wrap: nowrap;
}

.calendar-week-actions button {
  min-height: 30px;
}

.calendar-header .inline-control {
  align-items: center;
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  min-width: 0;
  width: auto;
}

.calendar-header .inline-control select {
  min-height: 38px;
  width: 210px;
}

.inline-control {
  min-width: 210px;
}

.selected-stream-label {
  background: rgba(77, 224, 206, 0.1);
  border: 1px solid rgba(77, 224, 206, 0.18);
  border-radius: 999px;
  color: var(--accent-strong);
  display: inline-flex;
  font-size: 13px;
  font-weight: 900;
  margin-top: 6px;
  min-height: 26px;
  padding: 4px 9px;
}

.metric-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
  min-width: min(410px, 100%);
}

.metric-strip div {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 9px 11px;
  background: linear-gradient(180deg, #252d33, #20272c);
  position: relative;
}

.metric-strip span {
  display: block;
  font-size: clamp(17px, 1.35vw, 22px);
  font-weight: 900;
  line-height: 1.05;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.metric-strip small {
  color: var(--muted);
  font-weight: 700;
}

.metric-strip div[data-tooltip]:hover::after,
.user-month-metrics div[data-tooltip]:hover::after {
  background: #0f1418;
  border: 1px solid var(--accent);
  border-radius: 8px;
  bottom: auto;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.34);
  color: var(--text);
  content: attr(data-tooltip);
  font-size: 13px;
  font-weight: 900;
  left: 8px;
  line-height: 1;
  max-width: min(240px, 70vw);
  padding: 8px 10px;
  position: absolute;
  top: calc(100% + 8px);
  white-space: nowrap;
  z-index: 200;
}

.metric-strip div[data-tooltip]:hover::before,
.user-month-metrics div[data-tooltip]:hover::before {
  border-bottom: 6px solid var(--accent);
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-top: 0;
  bottom: auto;
  content: "";
  left: 18px;
  position: absolute;
  top: calc(100% + 2px);
  z-index: 201;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(172px, 1fr));
  border: 1px solid var(--line);
  border-radius: var(--radius-soft);
  overflow: auto;
  background: #2a333a;
  gap: 1px;
  min-width: 0;
  scrollbar-color: #56616b #171d21;
}

.calendar-with-mini {
  align-items: start;
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(210px, 236px) minmax(0, 1fr);
  min-width: 0;
}

.admin-calendar-with-mini {
  gap: 10px;
  grid-template-columns: minmax(190px, 214px) minmax(0, 1fr);
}

.mini-calendar-panel {
  background:
    linear-gradient(135deg, rgba(77, 224, 206, 0.055), transparent 44%),
    linear-gradient(180deg, #1e252a, #171d21);
  border: 1px solid var(--line);
  border-radius: var(--radius-soft);
  display: grid;
  gap: 12px;
  padding: 12px;
  position: sticky;
  top: 14px;
}

.mini-calendar-brand {
  align-items: center;
  display: grid;
  gap: 10px;
  grid-template-columns: 38px minmax(0, 1fr);
}

.mini-calendar-brand strong {
  display: block;
  font-size: 14px;
}

.mini-calendar-brand small {
  color: var(--muted);
  display: block;
  font-size: 11px;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.calendar-app-icon {
  background:
    linear-gradient(90deg, #4c83f1 0 50%, #f3c23c 50% 100%),
    #f5f7fb;
  border-radius: 8px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
  height: 38px;
  overflow: hidden;
  position: relative;
  width: 38px;
}

.calendar-app-icon::before {
  background: #f5f7fb;
  bottom: 0;
  content: "";
  left: 0;
  position: absolute;
  right: 0;
  top: 9px;
}

.calendar-app-icon::after {
  background:
    linear-gradient(90deg, #35a854 0 50%, #ea4335 50% 100%);
  bottom: 0;
  content: "";
  height: 7px;
  left: 0;
  position: absolute;
  right: 0;
}

.calendar-app-icon span {
  color: #3482f6;
  display: grid;
  font-size: 17px;
  font-weight: 900;
  inset: 9px 0 6px;
  place-items: center;
  position: absolute;
  z-index: 1;
}

.mini-calendar-month {
  align-items: center;
  display: flex;
  gap: 10px;
  justify-content: space-between;
}

.mini-calendar-month strong {
  font-size: 14px;
}

.mini-calendar-month div {
  display: flex;
  gap: 4px;
}

.mini-calendar-nav {
  min-height: 28px;
  width: 30px;
}

.mini-calendar-weekdays,
.mini-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.mini-calendar-weekdays span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 950;
  text-align: center;
}

.mini-calendar-grid {
  gap: 3px;
}

.mini-calendar-day {
  aspect-ratio: 1;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--text);
  display: grid;
  font-size: 12px;
  font-weight: 850;
  min-height: 28px;
  padding: 0;
  place-items: center;
  position: relative;
}

.mini-calendar-day.muted {
  color: rgba(185, 193, 201, 0.45);
}

.mini-calendar-day.selected-week {
  background: rgba(77, 224, 206, 0.1);
  border-color: rgba(77, 224, 206, 0.12);
  border-radius: 8px;
}

.mini-calendar-day.today span {
  background: var(--accent);
  border-radius: 999px;
  color: #07100f;
  display: grid;
  font-weight: 950;
  height: 24px;
  place-items: center;
  width: 24px;
}

.mini-calendar-day:hover {
  background: rgba(255, 255, 255, 0.075);
  border-color: var(--line);
}

.mini-calendar-day i {
  background: var(--accent-strong);
  border-radius: 999px;
  bottom: 3px;
  height: 4px;
  position: absolute;
  width: 4px;
}

.stream-calendars {
  display: grid;
  gap: 20px;
  min-width: 0;
}

.stream-calendar {
  background: rgba(18, 23, 27, 0.52);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: var(--radius-soft);
  display: grid;
  gap: 10px;
  min-width: 0;
  padding: 12px;
}

.stream-heading {
  align-items: center;
  background: #171d21;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 12px;
}

.stream-heading h3 {
  margin: 0;
  font-size: 17px;
}

.stream-heading span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.day-column {
  min-height: 620px;
  background: rgba(22, 27, 31, 0.92);
  display: flex;
  flex-direction: column;
}

.day-column.today {
  background: rgba(24, 34, 35, 0.96);
}

.day-header {
  align-items: start;
  position: sticky;
  top: 0;
  z-index: 1;
  background: rgba(32, 39, 45, 0.98);
  border-bottom: 1px solid var(--line);
  display: grid;
  gap: 7px;
  grid-template-rows: auto 16px;
  height: 78px;
  padding: 10px;
}

.day-column.today .day-header {
  border-bottom-color: rgba(77, 224, 206, 0.3);
  box-shadow: inset 0 2px 0 var(--accent);
}

.day-header strong {
  display: block;
  font-size: 14px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.day-header span {
  color: var(--muted);
  display: block;
  font-size: 12px;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.day-header small {
  color: var(--muted);
  display: block;
  font-size: 10px;
  font-weight: 850;
  line-height: 1.25;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.day-body {
  display: grid;
  align-content: start;
  gap: 9px;
  padding: 9px;
}

.shift-card,
.request-card {
  border: 1px solid rgba(255, 255, 255, 0.055);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #232b31, #1d2429);
  padding: 10px;
  display: grid;
  gap: 8px;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.2);
  transition: border-color 140ms ease, transform 140ms ease, box-shadow 140ms ease;
}

.shift-card:hover,
.request-card:hover {
  border-color: var(--line-strong);
  transform: translateY(-1px);
  box-shadow: 0 12px 22px rgba(0, 0, 0, 0.26);
}

.shift-card[role="button"] {
  cursor: pointer;
}

.shift-card[role="button"]:focus-visible {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(77, 224, 206, 0.18), 0 12px 22px rgba(0, 0, 0, 0.26);
  outline: none;
}

.shift-card.breaks {
  background: linear-gradient(180deg, #233348, #1c2b3c);
  border-left-color: var(--blue);
}

.shift-card.collectibles {
  background: linear-gradient(180deg, #22372f, #1b2d27);
  border-left-color: var(--green);
}

.shift-time {
  display: block;
  font-size: 14px;
  letter-spacing: 0;
  line-height: 1.2;
}

.shift-person,
.shift-meta,
.request-card p {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.shift-person {
  display: grid;
  gap: 3px;
}

.shift-person span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.shift-meta {
  border-top: 1px solid rgba(255, 255, 255, 0.055);
  padding-top: 7px;
}

.shift-gmv {
  border: 1px solid rgba(77, 224, 206, 0.26);
  border-radius: var(--radius);
  background: rgba(77, 224, 206, 0.09);
  display: grid;
  gap: 2px;
  padding: 8px 9px;
}

.shift-gmv span {
  color: var(--accent-strong);
  font-size: 18px;
  font-weight: 950;
  line-height: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.shift-gmv small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
}

.shift-gmv small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
}

.shift-person {
  display: grid;
  gap: 3px;
}

.card-actions {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
}

.small-button {
  min-height: 28px;
  padding: 0 9px;
  font-size: 11px;
  font-weight: 800;
}

.danger {
  color: var(--red);
}

.hidden {
  display: none !important;
}

.request-date-range {
  display: grid;
  gap: 10px;
  grid-template-columns: 1fr 1fr;
}

.split-layout,
.user-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 22px;
}

.user-layout {
  grid-template-columns: 280px minmax(0, 1fr);
  align-items: start;
}

.user-metrics {
  min-width: min(520px, 100%);
}

.user-metrics span {
  font-size: 18px;
}

.calendar-week-actions {
  background: #181d21;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 6px;
  min-width: 164px;
  padding: 10px;
}

.calendar-week-actions span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.user-week-selector {
  background: #181d21;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 6px;
  min-width: min(360px, 100%);
  padding: 10px;
}

.user-week-selector span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.week-stepper {
  align-items: center;
  display: grid;
  gap: 7px;
  grid-template-columns: 38px minmax(130px, 1fr) auto 38px;
}

.week-stepper input {
  min-height: 38px;
}

.admin-subtabs,
.inventory-subtabs,
.user-subtabs {
  background: rgba(17, 23, 27, 0.86);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);
  display: inline-flex;
  gap: 4px;
  margin-bottom: 14px;
  padding: 4px;
}

.admin-subtabs {
  width: min(620px, 100%);
}

.admin-subtab,
.inventory-subtab,
.user-subtab {
  background: transparent;
  border: 0;
  color: var(--muted);
  flex: 1 1 0;
  font-weight: 850;
  min-height: 32px;
  padding: 0 14px;
  white-space: nowrap;
}

.admin-subtab.active,
.inventory-subtab.active,
.user-subtab.active {
  background: linear-gradient(180deg, #303942, #252d34);
  border: 1px solid rgba(255, 255, 255, 0.04);
  color: var(--text);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.18);
}

.admin-panel,
.inventory-panel,
.user-panel {
  display: none;
}

.admin-panel.active,
.inventory-panel.active,
.user-panel.active {
  display: block;
}

.analytics-panel {
  display: grid;
  gap: 16px;
}

.orders-view-header {
  align-items: stretch;
  display: grid;
  gap: 16px;
  grid-template-columns: 1fr;
}

.orders-filter-bar {
  align-items: end;
  background: linear-gradient(180deg, #1d2429, #171d21);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 10px;
  grid-template-columns: minmax(220px, 2fr) repeat(5, minmax(130px, 1fr)) minmax(94px, auto) minmax(84px, auto);
  max-width: 100%;
  overflow: hidden;
  padding: 12px;
}

.orders-filter-bar .inline-control {
  min-width: 0;
}

.orders-filter-bar > button {
  min-height: 38px;
}

.orders-filter-bar .secondary-button {
  background: #20272c;
  border-color: var(--line);
  color: var(--muted);
}

.orders-range-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  grid-column: 1 / -1;
}

.orders-range-presets button {
  background: rgba(77, 224, 206, 0.07);
  border: 1px solid rgba(77, 224, 206, 0.16);
  border-radius: 999px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  min-height: 30px;
  padding: 0 10px;
}

.orders-range-presets button:hover {
  background: rgba(77, 224, 206, 0.14);
  color: var(--accent-strong);
}

.orders-metrics {
  margin-bottom: 16px;
}

.orders-browser-panel {
  background: linear-gradient(180deg, #1a2025, #151a1e);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 12px;
  padding: 12px;
}

.table-wrap.orders-table-wrap {
  max-height: none;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: visible;
}

.orders-table {
  min-width: 1040px;
}

.orders-table th:last-child,
.orders-table td:last-child {
  text-align: right;
}

.order-audit-row {
  cursor: pointer;
}

.order-audit-row td {
  background: #171d21;
  transition: background 140ms ease;
}

.order-audit-row:hover td {
  background: rgba(77, 224, 206, 0.08);
}

.order-id-cell,
.order-customer-cell,
.order-date-cell,
.order-product-cell {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.order-id-cell strong,
.order-date-cell strong,
.order-product-cell strong {
  color: var(--text);
  font-size: 13px;
}

.order-id-cell small,
.order-customer-cell small,
.order-date-cell small,
.order-product-cell small,
.order-product-cell em {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.order-product-cell strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.order-status-chip {
  border: 1px solid rgba(77, 224, 206, 0.2);
  border-radius: 999px;
  color: var(--accent-strong);
  display: inline-flex;
  font-size: 10px;
  font-weight: 950;
  min-height: 22px;
  padding: 4px 8px;
  text-transform: uppercase;
}

.order-status-chip.excluded {
  border-color: rgba(224, 111, 99, 0.28);
  color: var(--red);
}

.orders-pagination {
  align-items: center;
  background: linear-gradient(180deg, #1d2429, #171d21);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
  padding: 10px;
}

.orders-page-numbers {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.orders-page-button {
  background: #20272c;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  font-size: 12px;
  font-weight: 900;
  min-height: 32px;
  min-width: 34px;
  padding: 0 10px;
}

.orders-page-button:hover:not(:disabled),
.orders-page-button.active {
  background: rgba(77, 224, 206, 0.16);
  border-color: rgba(77, 224, 206, 0.38);
  color: var(--accent-strong);
}

.orders-page-button:disabled {
  color: var(--muted);
  cursor: default;
  opacity: 0.55;
}

.orders-page-gap,
.orders-page-summary {
  align-items: center;
  color: var(--muted);
  display: inline-flex;
  font-size: 12px;
  font-weight: 850;
  min-height: 32px;
}

.orders-page-summary {
  margin-left: 4px;
}

.audit-drawer {
  background: rgba(4, 7, 9, 0.52);
  bottom: 0;
  display: flex;
  justify-content: flex-end;
  left: 0;
  position: fixed;
  right: 0;
  top: 0;
  z-index: 60;
}

.audit-drawer-panel {
  background: linear-gradient(180deg, #252c32, #1b2126);
  border-left: 1px solid var(--line-strong);
  box-shadow: -24px 0 60px rgba(0, 0, 0, 0.44);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  max-width: min(680px, 100vw);
  min-width: min(680px, 100vw);
}

.audit-drawer-header {
  align-items: start;
  border-bottom: 1px solid var(--line);
  display: flex;
  gap: 12px;
  justify-content: space-between;
  padding: 18px;
}

.audit-drawer-header h3 {
  font-size: 20px;
  margin-bottom: 6px;
}

.audit-drawer-header p:last-child {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.4;
}

.audit-drawer-actions {
  align-items: center;
  display: flex;
  flex-shrink: 0;
  gap: 8px;
}

.audit-back-button {
  border-color: rgba(96, 225, 211, 0.24);
  color: var(--accent);
  font-size: 18px;
  line-height: 1;
}

#auditDrawerBody {
  display: grid;
  gap: 14px;
  align-content: start;
  overflow: auto;
  padding: 18px;
}

.audit-metric-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
}

.audit-metric {
  background: #171d21;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  min-width: 0;
  padding: 12px;
}

.audit-metric span {
  color: var(--muted);
  display: block;
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
}

.audit-metric strong {
  display: block;
  font-size: 16px;
  margin-top: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.audit-section {
  background: #171d21;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 10px;
  padding: 12px;
}

.audit-section h4 {
  margin: 0;
}

.audit-section-heading {
  align-items: center;
  display: flex;
  gap: 12px;
  justify-content: space-between;
}

.audit-section-heading span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-align: right;
}

.audit-section p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.audit-order-profile {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.045), transparent 42%),
    #171d21;
}

.audit-buyer-card {
  align-items: center;
  background: #20272c;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 12px;
  grid-template-columns: 44px minmax(0, 1fr);
  padding: 12px;
}

.audit-buyer-avatar {
  background: rgba(77, 224, 206, 0.12);
  border: 1px solid rgba(77, 224, 206, 0.22);
  border-radius: 999px;
  height: 44px;
  object-fit: cover;
  width: 44px;
}

.audit-buyer-avatar.fallback {
  color: var(--accent-strong);
  display: grid;
  font-size: 18px;
  font-weight: 950;
  place-items: center;
}

.audit-buyer-card span,
.audit-detail-item span,
.audit-note span {
  color: var(--muted);
  display: block;
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
}

.audit-buyer-card strong {
  display: block;
  font-size: 18px;
  margin-top: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.audit-buyer-card small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.audit-detail-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.audit-detail-item {
  background: #10161a;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  min-width: 0;
  padding: 10px;
}

.audit-detail-item strong {
  display: block;
  font-size: 12px;
  margin-top: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.audit-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.audit-chip {
  background: rgba(77, 224, 206, 0.1);
  border: 1px solid rgba(77, 224, 206, 0.2);
  border-radius: 999px;
  color: var(--accent-strong);
  font-size: 11px;
  font-weight: 900;
  padding: 5px 8px;
}

.audit-chip.muted {
  background: #10161a;
  border-color: var(--line);
  color: var(--muted);
}

.audit-note {
  background: #10161a;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px;
}

.audit-note p {
  margin-top: 5px;
}

.audit-decision-section {
  background: linear-gradient(180deg, rgba(77, 224, 206, 0.08), rgba(23, 29, 33, 0.94));
}

.audit-step-list {
  display: grid;
  gap: 8px;
}

.audit-step {
  align-items: start;
  display: grid;
  gap: 10px;
  grid-template-columns: 14px minmax(0, 1fr);
}

.audit-step > span {
  background: var(--accent);
  border-radius: 999px;
  box-shadow: 0 0 0 4px rgba(77, 224, 206, 0.12);
  height: 9px;
  margin-top: 5px;
  width: 9px;
}

.audit-step.blocked > span {
  background: var(--red);
  box-shadow: 0 0 0 4px rgba(224, 111, 99, 0.14);
}

.audit-step.attention > span {
  background: #f0bd62;
  box-shadow: 0 0 0 4px rgba(240, 189, 98, 0.14);
}

.audit-step strong {
  display: block;
  font-size: 12px;
  margin-bottom: 2px;
}

.audit-step p {
  margin: 0;
}

.audit-item-list,
.audit-order-list,
.audit-shift-list {
  display: grid;
  gap: 8px;
}

.audit-item-row,
.audit-order-button,
.audit-shift-button {
  align-items: center;
  background: #20272c;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 8px;
  padding: 10px;
  text-align: left;
}

.audit-order-button:hover,
.audit-shift-button:hover {
  background: #263038;
  border-color: rgba(77, 224, 206, 0.28);
}

.audit-item-row {
  grid-template-columns: minmax(0, 1fr) auto;
}

.audit-order-button,
.audit-shift-button {
  grid-template-columns: minmax(90px, 0.45fr) minmax(90px, 0.45fr) minmax(0, 1fr);
}

.audit-order-ref {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.audit-order-time {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  line-height: 1.1;
}

.payroll-shift-row {
  align-items: center;
  background:
    linear-gradient(90deg, rgba(77, 224, 206, 0.08), transparent 42%),
    #1d252a;
  grid-template-columns: 72px minmax(0, 1fr) minmax(120px, auto);
  min-height: 62px;
  padding: 9px 11px;
}

.payroll-shift-date {
  background: #10161a;
  border: 1px solid var(--line);
  border-radius: 9px;
  display: grid;
  gap: 1px;
  min-width: 0;
  padding: 8px 7px;
  text-align: center;
}

.payroll-shift-date strong {
  font-size: 14px;
  line-height: 1;
}

.payroll-shift-date small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
}

.payroll-shift-main,
.payroll-shift-stats {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.payroll-shift-main strong {
  font-size: 15px;
  line-height: 1.1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.payroll-shift-main small,
.payroll-shift-stats small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.payroll-shift-stats {
  justify-items: end;
  text-align: right;
}

.payroll-shift-stats strong {
  color: var(--accent-strong);
  font-size: 15px;
  line-height: 1.1;
}

.audit-single-action {
  background: rgba(77, 224, 206, 0.08);
  border-color: rgba(77, 224, 206, 0.24);
}

.audit-order-button small,
.audit-shift-button small,
.audit-item-row span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.audit-item-row small {
  color: var(--muted);
  display: block;
  font-size: 10px;
  font-weight: 750;
  margin-top: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.inventory-metrics {
  margin-bottom: 16px;
}

.payroll-panel {
  background:
    linear-gradient(180deg, rgba(37, 44, 50, 0.92), rgba(25, 30, 34, 0.94)),
    #1e2429;
  display: grid;
  gap: 16px;
  padding: 16px;
}

.payroll-heading {
  align-items: end;
  background:
    linear-gradient(135deg, rgba(77, 224, 206, 0.08), transparent 48%),
    #171d21;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin-bottom: 0;
  padding: 13px 14px;
}

.payroll-heading h3 {
  margin-bottom: 7px;
}

.payroll-heading strong {
  color: var(--ink);
  display: block;
  font-size: 15px;
  line-height: 1.25;
}

.payroll-heading .inline-control {
  min-width: 190px;
}

.payroll-metrics {
  grid-template-columns: repeat(3, minmax(150px, 1fr));
  min-width: 0;
}

.payroll-metrics div {
  padding: 14px;
}

.payroll-metrics span {
  font-size: clamp(19px, 1.55vw, 25px);
}

.payroll-metrics div:first-child {
  border-color: rgba(77, 224, 206, 0.22);
}

.payroll-metrics div:last-child {
  border-color: rgba(224, 168, 79, 0.22);
}

.payroll-metrics div:first-child span {
  color: var(--accent-strong);
}

.payroll-metrics div:last-child span {
  color: #f2c06b;
}

.attribution-gap-panel {
  background: linear-gradient(180deg, #1a2025, #151a1e);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 12px;
  padding: 14px;
}

.attribution-gap-panel .panel-heading {
  align-items: start;
}

.attribution-gap-panel .panel-heading strong {
  color: var(--muted);
  display: block;
  font-size: 12px;
  margin-top: 4px;
}

.attribution-gap-metrics {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  min-width: 0;
}

.excluded-orders-summary,
.offline-breaks-summary {
  background: rgba(77, 224, 206, 0.08);
  border: 1px solid rgba(77, 224, 206, 0.22);
  border-radius: var(--radius);
  display: grid;
  gap: 10px;
  padding: 10px;
}

.excluded-orders-summary {
  background: rgba(239, 125, 87, 0.08);
  border-color: rgba(239, 125, 87, 0.2);
}

.excluded-orders-toggle,
.offline-breaks-toggle {
  align-items: center;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  color: inherit;
  cursor: pointer;
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(2, minmax(0, 1fr)) max-content;
  min-height: 0;
  padding: 0;
  text-align: left;
  transform: none;
  width: 100%;
}

.excluded-orders-toggle:hover,
.offline-breaks-toggle:hover {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
  color: inherit;
  transform: none;
}

.excluded-orders-toggle:focus-visible,
.offline-breaks-toggle:focus-visible {
  border-radius: var(--radius);
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.excluded-orders-toggle div,
.offline-breaks-toggle div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.excluded-orders-toggle strong {
  color: var(--red);
  font-size: 20px;
  line-height: 1;
}

.excluded-orders-toggle span,
.excluded-orders-toggle small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.offline-breaks-toggle strong {
  color: var(--accent-strong);
  font-size: 20px;
  line-height: 1;
}

.offline-breaks-toggle span,
.offline-breaks-toggle small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.offline-break-order {
  grid-template-columns: 116px minmax(150px, 0.8fr) minmax(220px, 1.4fr) minmax(110px, 0.6fr) minmax(90px, 0.45fr) minmax(120px, 0.65fr);
}

.excluded-order {
  background: rgba(239, 125, 87, 0.08);
  grid-template-columns: 116px minmax(150px, 0.8fr) minmax(220px, 1.4fr) minmax(110px, 0.6fr) minmax(90px, 0.45fr) minmax(120px, 0.65fr);
}

.unattributed-list {
  display: grid;
  gap: 16px;
}

.unattributed-queue-panel,
.manual-attribution-panel {
  background: linear-gradient(180deg, #1a2025, #151a1e);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 10px;
  padding: 10px;
}

.breaks-upload-panel {
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--accent) 10%, transparent), transparent 42%),
    #14191d;
  border: 1px solid color-mix(in srgb, var(--accent) 22%, var(--line) 78%);
  border-radius: var(--radius);
  display: grid;
  gap: 12px;
  padding: 14px;
}

.breaks-upload-copy {
  align-items: start;
  display: flex;
  gap: 12px;
  justify-content: space-between;
}

.breaks-upload-copy h3 {
  color: var(--text);
  font-size: 18px;
  line-height: 1.1;
  margin: 2px 0 4px;
}

.breaks-upload-copy strong {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.3;
}

.breaks-upload-eyebrow {
  color: var(--accent-strong);
  display: block;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.breaks-upload-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

.breaks-upload-meta span {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  padding: 6px 8px;
  white-space: nowrap;
}

.breaks-upload-footer {
  align-items: center;
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(0, 1fr) max-content;
}

.breaks-upload-actions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.file-upload-control {
  align-items: center;
  background: color-mix(in srgb, var(--accent) 88%, #ffffff 12%);
  border: 1px solid color-mix(in srgb, var(--accent-strong) 50%, transparent);
  border-radius: var(--radius);
  color: #071412;
  cursor: pointer;
  display: inline-flex;
  font-size: 12px;
  font-weight: 900;
  justify-content: center;
  min-height: 36px;
  overflow: hidden;
  padding: 9px 12px;
  position: relative;
}

.file-upload-control input {
  cursor: pointer;
  inset: 0;
  opacity: 0;
  position: absolute;
}

.breaks-upload-results {
  display: grid;
  gap: 8px;
}

.breaks-upload-result-card {
  background: rgba(77, 224, 206, 0.08);
  border: 1px solid var(--accent-border);
  border-radius: var(--radius);
  display: grid;
  gap: 4px;
  padding: 9px 10px;
}

.breaks-upload-result-card.error {
  background: rgba(239, 125, 87, 0.08);
  border-color: rgba(239, 125, 87, 0.35);
}

.breaks-upload-result-card strong {
  color: var(--text);
  font-size: 13px;
}

.breaks-upload-result-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.breaks-upload-changed-list {
  display: grid;
  gap: 6px;
  margin-top: 6px;
  max-height: 260px;
  overflow: auto;
  padding-right: 2px;
}

.breaks-upload-order {
  align-items: center;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  cursor: pointer;
  display: grid;
  gap: 8px;
  grid-template-columns: 74px minmax(120px, 0.7fr) minmax(180px, 1fr);
  min-height: 38px;
  padding: 8px 9px;
  text-align: left;
}

.breaks-upload-order:hover {
  border-color: var(--accent-border);
  background: rgba(77, 224, 206, 0.08);
}

.breaks-upload-order span,
.breaks-upload-order strong,
.breaks-upload-order small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.breaks-upload-order span {
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 900;
}

.breaks-upload-order strong,
.breaks-upload-order small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.unattributed-toolbar {
  align-items: center;
  background: #11171b;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 8px;
  grid-template-columns: minmax(130px, max-content) minmax(180px, 1fr) max-content;
  padding: 9px;
  position: sticky;
  top: 0;
  z-index: 2;
}

.bulk-select-control,
.order-select-cell {
  align-items: center;
  color: var(--text);
  cursor: pointer;
  display: flex;
  flex-direction: row;
  font-size: 12px;
  font-weight: 900;
  gap: 8px;
  min-height: 44px;
}

.bulk-select-control input[type="checkbox"],
.order-select-cell input[type="checkbox"] {
  appearance: none;
  background: #151b1f;
  border: 1px solid color-mix(in srgb, var(--muted) 45%, transparent);
  border-radius: 5px;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.02);
  cursor: pointer;
  flex: 0 0 18px;
  height: 18px;
  min-height: 18px;
  padding: 0;
  width: 18px;
}

.bulk-select-control input[type="checkbox"]:checked,
.order-select-cell input[type="checkbox"]:checked {
  background: var(--accent-strong);
  border-color: var(--accent-strong);
  box-shadow: inset 0 0 0 4px #151b1f;
}

.bulk-select-control input[type="checkbox"]:focus-visible,
.order-select-cell input[type="checkbox"]:focus-visible {
  outline: 2px solid var(--accent-strong);
  outline-offset: 3px;
}

.unattributed-section {
  display: grid;
  gap: 8px;
}

.unattributed-order {
  align-items: center;
  background: #20272c;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 8px;
  grid-template-columns: 116px minmax(150px, 0.8fr) minmax(220px, 1.4fr) minmax(110px, 0.6fr) minmax(90px, 0.45fr) minmax(160px, 0.85fr);
  padding: 9px 10px;
}

.unattributed-order.assigned {
  background: rgba(77, 224, 206, 0.08);
}

.unattributed-order span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.unattributed-order label {
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  gap: 4px;
}

.unattributed-order select {
  min-height: 32px;
  padding: 5px 7px;
}

.unattributed-assigned-actions {
  align-items: center;
  display: flex;
  gap: 8px;
  justify-content: space-between;
  min-width: 0;
}

.unattributed-assigned-actions span {
  color: var(--accent-strong);
}

.manual-attribution-toggle {
  align-items: center;
  background: #11171b;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  cursor: pointer;
  display: inline-flex;
  font-size: 12px;
  font-weight: 900;
  gap: 8px;
  justify-content: center;
  min-height: 36px;
  padding: 9px 10px;
  white-space: nowrap;
}

.manual-attribution-toggle:disabled {
  color: var(--muted);
  cursor: default;
  opacity: 0.65;
}

.manual-attribution-panel .compact-heading strong {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.25;
}

.show-more-unattributed {
  justify-self: center;
  min-width: 180px;
}

.compact-button {
  min-height: 34px;
  padding: 0 12px;
  white-space: nowrap;
}

.payroll-grid {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #171d21;
  overflow: auto;
  scrollbar-color: #56616b #171d21;
}

.payroll-grid-toolbar {
  align-items: center;
  background: linear-gradient(180deg, #1b2227, #151b1f);
  border-bottom: 1px solid var(--line);
  display: flex;
  gap: 12px;
  justify-content: space-between;
  min-width: 1040px;
  padding: 10px 12px;
  position: sticky;
  top: 0;
  z-index: 2;
}

.payroll-grid-toolbar div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.payroll-grid-toolbar strong {
  color: var(--text);
  font-size: 13px;
}

.payroll-grid-toolbar span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.payroll-grid-header,
.payroll-row {
  align-items: center;
  display: grid;
  grid-template-columns:
    minmax(104px, 1.25fr)
    minmax(74px, 0.68fr)
    minmax(74px, 0.68fr)
    minmax(98px, 0.95fr)
    minmax(54px, 0.46fr)
    minmax(74px, 0.62fr)
    minmax(68px, 0.6fr)
    minmax(86px, 0.78fr)
    minmax(92px, 0.82fr)
    minmax(92px, 0.85fr);
}

.payroll-grid-header {
  background: #141a1e;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  min-height: 40px;
  min-width: 1040px;
  position: sticky;
  top: 58px;
  text-transform: uppercase;
  z-index: 1;
}

.payroll-grid-header span,
.payroll-row > div {
  border-right: 1px solid var(--line);
  font-size: 12px;
  min-width: 0;
  padding: 8px 7px;
}

.payroll-grid-header span:last-child,
.payroll-row > div:last-child {
  border-right: 0;
}

.payroll-grid-body {
  display: grid;
}

.payroll-row {
  background: #1d2429;
  border-bottom: 1px solid var(--line);
  min-height: 62px;
  min-width: 1040px;
}

.payroll-row:nth-child(even) {
  background: #20272c;
}

.payroll-row:hover {
  background: rgba(66, 184, 168, 0.09);
}

.payroll-row:last-child {
  border-bottom: 0;
}

.payroll-person strong,
.payroll-cell strong,
.payroll-total-cell {
  display: block;
  font-weight: 950;
}

.payroll-person strong {
  font-size: 13px;
}

.payroll-audit-link {
  background: transparent;
  border: 0;
  box-shadow: none;
  color: var(--ink);
  display: inline;
  font-size: 13px;
  font-weight: 950;
  min-height: 0;
  padding: 0;
  text-align: left;
}

.payroll-audit-link:hover {
  background: transparent;
  border-color: transparent;
  color: var(--accent-strong);
  transform: none;
}

.payroll-person span,
.payroll-cell span {
  color: var(--muted);
  display: block;
  font-size: 10px;
  font-weight: 800;
  margin-top: 3px;
}

.payroll-input {
  background: transparent;
  border: 0;
  color: var(--text);
  font-size: 12px;
  min-height: 32px;
  max-width: none;
  padding: 5px 4px;
  width: 100%;
}

.payroll-input:focus {
  outline: 0;
}

.payroll-input-wrap {
  align-items: center;
  background: #11171b;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  display: flex;
  font-size: 11px;
  font-weight: 900;
  gap: 2px;
  min-height: 34px;
  padding: 0 7px;
}

.payroll-input-wrap:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(77, 224, 206, 0.12);
}

.payroll-total-cell {
  color: var(--accent-strong);
  font-size: 14px;
}

.inventory-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.inventory-grid.single {
  grid-template-columns: 1fr;
}

.inventory-grid section {
  min-width: 0;
}

.pack-ratio-input {
  max-width: 86px;
}

.analytics-insight {
  background: #171d21;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 4px;
  padding: 14px;
}

.analytics-insight span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.analytics-insight strong {
  font-size: 20px;
}

.analytics-insight p {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.analytics-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.analytics-grid section {
  min-width: 0;
}

.analytics-grid h3 {
  margin-bottom: 8px;
}

.admin-workbench {
  align-items: start;
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(0, 1fr) max-content;
}

.admin-workbench:has(.admin-form-toggle[open]) {
  grid-template-columns: minmax(620px, 1fr) minmax(320px, 380px);
}

.admin-scheduler-panel {
  background:
    linear-gradient(180deg, rgba(37, 44, 50, 0.92), rgba(25, 30, 34, 0.94)),
    #1e2429;
  min-width: 0;
}

.admin-scheduler-panel > .panel-heading {
  align-items: center;
  background:
    linear-gradient(135deg, rgba(77, 224, 206, 0.07), transparent 44%),
    #171d21;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin-bottom: 8px;
  padding: 8px 10px;
}

.admin-scheduler-panel > .panel-heading h3 {
  font-size: 15px;
  line-height: 1;
}

.admin-form-toggle {
  border: 1px solid rgba(77, 224, 206, 0.18);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #1c2529, #151b1f);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.2);
  justify-self: end;
  position: sticky;
  top: 18px;
  width: max-content;
}

.admin-form-toggle summary {
  align-items: center;
  color: var(--text);
  cursor: pointer;
  display: flex;
  gap: 8px;
  justify-content: space-between;
  list-style: none;
  min-height: 38px;
  padding: 0 12px;
}

.admin-form-toggle summary::-webkit-details-marker {
  display: none;
}

.admin-form-toggle summary::after {
  content: "+";
  color: var(--accent-strong);
  font-size: 18px;
  font-weight: 900;
}

.admin-form-toggle[open] summary::after {
  content: "-";
}

.admin-form-toggle[open] {
  justify-self: stretch;
  width: 100%;
}

.admin-form-toggle summary span {
  font-size: 12px;
  font-weight: 900;
}

.admin-form-toggle summary small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.admin-form-toggle:not([open]) summary small {
  display: none;
}

.admin-form-panel {
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0 0 var(--radius) var(--radius);
  max-width: none;
  padding: 13px;
}

.admin-scheduler-panel .panel-heading strong {
  color: var(--muted);
  display: block;
  font-size: 12px;
  font-weight: 800;
  margin-top: 3px;
}

.admin-scheduler {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.admin-stream-board {
  background: rgba(18, 23, 27, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.045);
  border-radius: var(--radius-soft);
  display: grid;
  gap: 7px;
  padding: 8px;
}

.admin-stream-actions {
  align-items: center;
  display: flex;
  gap: 10px;
}

.admin-day-scroll-controls {
  display: flex;
  gap: 6px;
}

.admin-day-scroll-controls .icon-button {
  min-height: 30px;
  width: 32px;
}

.admin-today-button {
  min-height: 30px;
  padding: 0 12px;
}

.admin-time-grid {
  background: #273138;
  border: 1px solid var(--line);
  border-radius: var(--radius-soft);
  display: grid;
  grid-template-columns: 76px repeat(7, minmax(132px, 1fr));
  gap: 1px;
  height: clamp(640px, calc(100vh - 235px), 920px);
  max-width: 100%;
  overflow: scroll;
  overscroll-behavior: contain;
  position: relative;
  scrollbar-gutter: stable both-edges;
  scrollbar-color: #56616b #171d21;
  scrollbar-width: thin;
  touch-action: pan-x pan-y;
  user-select: none;
}

.admin-time-grid::-webkit-scrollbar {
  height: 12px;
  width: 12px;
}

.admin-time-grid::-webkit-scrollbar-track {
  background: #171d21;
  border-radius: 999px;
}

.admin-time-grid::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #66717a, #4b565f);
  border: 2px solid #171d21;
  border-radius: 999px;
}

.admin-time-grid::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #7a8791, #5b6872);
}

.admin-time-grid::-webkit-scrollbar-corner {
  background: #171d21;
}

.admin-grid-corner,
.admin-day-heading,
.admin-time-label,
.admin-slot {
  background: #151b1f;
}

.admin-grid-corner {
  border-top-left-radius: var(--radius-soft);
}

.admin-day-heading:last-of-type {
  border-top-right-radius: var(--radius-soft);
}

.admin-grid-corner,
.admin-day-heading {
  position: sticky;
  top: 0;
  z-index: 2;
}

.admin-grid-corner {
  left: 0;
  z-index: 3;
}

.admin-day-heading {
  background: #1b2227;
  min-height: 48px;
  padding: 8px 10px;
}

.admin-day-heading strong {
  display: block;
  font-size: 12px;
}

.admin-day-heading span {
  color: var(--muted);
  display: block;
  font-size: 10px;
  font-weight: 800;
  margin-top: 2px;
}

.admin-time-label {
  align-items: center;
  color: var(--muted);
  display: flex;
  font-size: 10px;
  font-weight: 800;
  justify-content: flex-end;
  min-height: 30px;
  line-height: 1;
  padding: 0 10px;
  position: sticky;
  left: 0;
  text-align: right;
  white-space: nowrap;
  z-index: 1;
}

.admin-slot {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.022), transparent),
    #151b1f;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  color: transparent;
  min-height: 30px;
  overflow: hidden;
  padding: 0;
  position: relative;
  text-align: left;
  touch-action: none;
  user-select: none;
  white-space: nowrap;
}

.admin-slot:hover {
  background: rgba(77, 224, 206, 0.08);
  transform: none;
}

.admin-slot.occupied {
  background: #171d21;
  color: transparent;
  cursor: pointer;
}

.admin-slot.shift-start:hover {
  background: rgba(77, 224, 206, 0.08);
}

.admin-shift-bubble {
  align-items: start;
  background: linear-gradient(180deg, #253b4f, #1d3142);
  border: 1px solid rgba(117, 154, 184, 0.54);
  border-left: 4px solid var(--blue);
  border-radius: 8px;
  box-shadow:
    0 12px 24px rgba(0, 0, 0, 0.32),
    0 0 0 1px rgba(255, 255, 255, 0.035) inset;
  color: #edf7ff;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 4px;
  justify-content: flex-start;
  min-height: 24px;
  overflow: hidden;
  padding: 8px 9px;
  position: absolute;
  text-align: left;
  transform: translateZ(0);
  transition:
    border-color 140ms ease,
    box-shadow 140ms ease,
    transform 140ms ease;
  z-index: 5;
}

.admin-shift-bubble.collectibles {
  background: linear-gradient(180deg, #243f35, #1c332b);
  border-color: rgba(119, 189, 142, 0.48);
  border-left-color: var(--green);
}

.admin-shift-bubble.breaks {
  background: linear-gradient(180deg, #253b4f, #1d3142);
  border-color: rgba(109, 158, 208, 0.5);
  border-left-color: var(--blue);
}

.admin-shift-bubble:hover {
  border-color: rgba(221, 239, 255, 0.76);
  box-shadow:
    0 14px 28px rgba(0, 0, 0, 0.38),
    0 0 0 1px rgba(255, 255, 255, 0.07) inset;
  transform: translateY(-1px);
}

.admin-shift-bubble strong {
  color: #f7fbff;
  font-size: 14px;
  font-weight: 950;
  line-height: 1.15;
  margin-top: 2px;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-shift-bubble span {
  color: rgba(231, 241, 247, 0.78);
  font-size: 10.5px;
  font-weight: 750;
  line-height: 1.2;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-shift-bubble .admin-shift-role {
  color: rgba(236, 247, 252, 0.82);
  font-size: 10px;
  font-weight: 850;
}

.admin-shift-bubble .admin-shift-detail {
  color: rgba(211, 225, 234, 0.68);
  font-size: 10px;
  font-weight: 750;
}

.admin-selection-block {
  align-items: start;
  background: linear-gradient(180deg, rgba(45, 126, 117, 0.96), rgba(35, 96, 91, 0.94));
  border: 1px solid rgba(119, 222, 202, 0.72);
  border-left: 4px solid var(--accent-strong);
  border-radius: 9px;
  box-shadow:
    0 12px 26px rgba(0, 0, 0, 0.34),
    0 0 0 1px rgba(255, 255, 255, 0.06) inset;
  color: #eafffb;
  display: flex;
  font-size: 11px;
  font-weight: 900;
  line-height: 1.2;
  min-height: 24px;
  padding: 7px 8px 7px 9px;
  pointer-events: none;
  position: absolute;
  transform-origin: top center;
  animation: selection-pop 150ms cubic-bezier(0.2, 0.9, 0.2, 1);
  z-index: 6;
}

.shift-popover {
  background: linear-gradient(180deg, #252c32, #1d2328);
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.52);
  display: grid;
  gap: 12px;
  left: 0;
  opacity: 1;
  max-height: calc(100vh - 24px);
  overflow: auto;
  padding: 14px;
  position: fixed;
  transform: translateY(0) scale(1);
  transform-origin: top left;
  transition:
    opacity 150ms ease,
    transform 170ms cubic-bezier(0.2, 0.9, 0.2, 1),
    visibility 150ms ease;
  top: 0;
  visibility: visible;
  width: min(320px, calc(100vw - 24px));
  z-index: 20;
}

.shift-popover.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px) scale(0.97);
  visibility: hidden;
}

.shift-popover.closing {
  opacity: 0;
  transform: translateY(6px) scale(0.98);
}

@keyframes selection-pop {
  from {
    opacity: 0.72;
    transform: scaleY(0.82);
  }
  to {
    opacity: 1;
    transform: scaleY(1);
  }
}

.popover-header {
  align-items: start;
  display: flex;
  gap: 12px;
  justify-content: space-between;
}

.popover-header strong {
  display: block;
  font-size: 14px;
  line-height: 1.35;
}

.popover-metrics {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.popover-metrics.hidden {
  display: none;
}

.popover-metrics div {
  background: rgba(77, 224, 206, 0.08);
  border: 1px solid rgba(77, 224, 206, 0.22);
  border-radius: 8px;
  min-width: 0;
  padding: 8px;
}

.popover-metrics span {
  color: var(--accent-strong);
  display: block;
  font-size: 14px;
  font-weight: 950;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.popover-metrics small {
  color: var(--muted);
  display: block;
  font-size: 10px;
  font-weight: 900;
  margin-top: 2px;
  text-transform: uppercase;
}

.popover-audit-button {
  align-items: center;
  display: inline-flex;
  justify-content: center;
  min-height: 34px;
  width: 100%;
}

.assistant-picker {
  display: grid;
  gap: 6px;
  position: relative;
}

.assistant-picker > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.assistant-picker button {
  justify-content: space-between;
  min-width: 0;
  overflow: hidden;
  padding-right: 30px;
  position: relative;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
  width: 100%;
}

.assistant-picker button::after {
  content: "v";
  color: var(--muted);
  position: absolute;
  right: 12px;
}

.assistant-picker-menu {
  background: #171d21;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
  display: grid;
  gap: 2px;
  max-height: 190px;
  overflow: auto;
  padding: 6px;
  position: absolute;
  top: calc(100% + 4px);
  width: 100%;
  z-index: 24;
}

.assistant-picker-menu.hidden {
  display: none;
}

.assistant-picker-menu label {
  align-items: center;
  border-radius: 8px;
  display: flex;
  flex-direction: row;
  gap: 8px;
  padding: 7px 8px;
}

.assistant-picker-menu label:hover {
  background: rgba(77, 224, 206, 0.08);
}

.assistant-picker-menu input {
  width: auto;
}

.popover-actions {
  align-items: center;
  background: linear-gradient(180deg, rgba(29, 35, 40, 0), #1d2328 28%);
  bottom: -14px;
  display: flex;
  gap: 8px;
  justify-content: space-between;
  margin: 2px -2px -14px;
  padding: 14px 2px 14px;
  position: sticky;
  z-index: 2;
}

.popover-actions .primary-button {
  flex: 1;
}

.popover-actions .hidden {
  display: none;
}

.user-picker {
  background: #181d21;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
  display: grid;
  gap: 14px;
}

.user-summary {
  border-top: 1px solid var(--line);
  display: grid;
  gap: 6px;
  padding-top: 14px;
}

.user-summary strong {
  font-size: 18px;
}

.user-summary p {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.user-month-card {
  border-top: 1px solid var(--line);
  display: grid;
  gap: 12px;
  padding-top: 14px;
}

.compact-heading {
  align-items: start;
  margin-bottom: 0;
}

.compact-heading h3 {
  margin-bottom: 4px;
}

.compact-heading strong {
  color: var(--accent-strong);
  display: block;
  font-size: 24px;
  line-height: 1.05;
}

.user-month-metrics {
  display: grid;
  gap: 7px;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.85fr) minmax(0, 0.85fr);
}

.user-month-metrics div {
  background: #20272c;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 9px;
  position: relative;
}

.user-month-metrics span {
  display: block;
  font-size: clamp(13px, 0.95vw, 15px);
  font-weight: 900;
  line-height: 1.1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-month-metrics .wide-metric span {
  font-size: clamp(12px, 0.85vw, 15px);
}

.user-month-metrics small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.embedded-panel {
  box-shadow: none;
  height: 100%;
}

.list {
  display: grid;
  gap: 10px;
}

.compact-form {
  background: #181d21;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
}

.table-wrap {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  max-height: 310px;
  overflow: auto;
}

.data-table {
  border-collapse: collapse;
  min-width: 100%;
}

.data-table th,
.data-table td {
  border-bottom: 1px solid var(--line);
  font-size: 12px;
  padding: 9px 10px;
  text-align: left;
  vertical-align: top;
}

.data-table th {
  background: #171d21;
  color: var(--muted);
  font-size: 11px;
  position: sticky;
  top: 0;
  z-index: 1;
}

.data-table tr:last-child td {
  border-bottom: 0;
}

.data-table td[colspan] {
  color: var(--muted);
}

.analytics-row {
  cursor: pointer;
}

.analytics-row:hover td,
.analytics-row.selected td {
  background: rgba(66, 184, 168, 0.1);
}

.analytics-row.selected td:first-child {
  color: var(--accent-strong);
  font-weight: 900;
}

.status-pill {
  border-radius: 999px;
  color: #fff;
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.status-open {
  background: var(--sun);
  color: #241600;
}

.status-approved {
  background: var(--green);
  color: #061409;
}

.status-declined {
  background: var(--red);
  color: #210404;
}

.empty-state {
  color: var(--muted);
  background: #1a2025;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  padding: 16px;
  line-height: 1.45;
}

@media (max-width: 980px) {
  .app-shell,
  .split-layout,
  .user-layout {
    grid-template-columns: 1fr;
  }

  .calendar-header {
    grid-template-columns: 1fr;
  }

  .calendar-controls-row {
    justify-content: flex-start;
  }

  .calendar-with-mini {
    grid-template-columns: 1fr;
  }

  .mini-calendar-panel {
    position: static;
  }

  .admin-workbench,
  .admin-workbench:has(.admin-form-toggle[open]) {
    grid-template-columns: 1fr;
  }

  .analytics-grid {
    grid-template-columns: 1fr;
  }

  .orders-view-header,
  .orders-filter-bar {
    grid-template-columns: 1fr;
  }

  .inventory-grid {
    grid-template-columns: 1fr;
  }

  .admin-form-toggle {
    position: static;
  }

  .admin-view-header {
    align-items: stretch;
    flex-direction: column;
  }

  .sidebar {
    position: static;
  }

  .tabs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .tab-button {
    justify-content: center;
  }

  .calendar-grid {
    grid-template-columns: repeat(7, minmax(210px, 1fr));
  }
}

@media (max-width: 1280px) {
  .orders-filter-bar {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .orders-filter-bar .inline-control:first-child,
  .orders-range-presets {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 14px;
  }

  h1 {
    font-size: 22px;
  }

  h2 {
    font-size: 18px;
  }

  button,
  .nav-link-button {
    min-height: 42px;
  }

  input,
  select,
  textarea {
    min-height: 42px;
  }

  .breaks-upload-copy,
  .breaks-upload-footer,
  .breaks-upload-actions {
    align-items: stretch;
    display: grid;
    grid-template-columns: 1fr;
    justify-content: stretch;
  }

  .breaks-upload-meta {
    justify-content: flex-start;
  }

  .file-upload-control,
  .breaks-upload-actions .small-button {
    width: 100%;
  }

  .breaks-upload-order {
    grid-template-columns: 1fr;
  }

  .topbar {
    gap: 10px;
    justify-content: flex-start;
    min-height: 0;
    padding: 10px 12px;
  }

  .brand-lockup {
    gap: 10px;
    min-width: 0;
  }

  .brand-logo {
    border-radius: 7px;
    height: 44px;
    width: 66px;
  }

  .brand-lockup .eyebrow {
    margin-bottom: 2px;
  }

  .theme-control {
    flex: 0 1 142px;
    font-size: 0;
    gap: 0;
    min-width: 112px;
  }

  .theme-control select {
    font-size: 12px;
    min-height: 38px;
    min-width: 0;
    padding-inline: 8px;
  }

  .app-shell {
    gap: 10px;
    padding: 10px;
  }

  .sidebar {
    gap: 8px;
    overflow: visible;
    z-index: 15;
  }

  .tabs {
    background: color-mix(in srgb, var(--surface-0) 88%, var(--accent) 12%);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    gap: 4px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding: 4px;
    position: sticky;
    top: 0;
    z-index: 12;
  }

  .tab-button {
    border-radius: 8px;
    font-size: 13px;
    min-height: 40px;
    padding: 0 8px;
  }

  .development-nav {
    display: none;
  }

  .sidebar-summary {
    display: none;
  }

  .workspace {
    border-radius: var(--radius);
    min-height: 0;
    overflow: hidden;
  }

  .view-header {
    align-items: stretch;
    flex-direction: column;
  }

  .view {
    padding: 10px;
  }

  .admin-view-header {
    padding: 12px;
  }

  .admin-subtabs,
  .inventory-subtabs,
  .user-subtabs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    width: 100%;
  }

  .admin-subtab,
  .inventory-subtab,
  .user-subtab {
    font-size: 12px;
    line-height: 1.12;
    min-height: 42px;
    padding: 0 6px;
    white-space: normal;
  }

  .orders-metrics,
  .audit-metric-grid,
  .audit-detail-grid {
    grid-template-columns: 1fr;
  }

  .audit-drawer-panel {
    border-radius: 0;
    min-width: 100vw;
    width: 100vw;
  }

  .audit-order-button,
  .audit-shift-button {
    grid-template-columns: 1fr;
  }

  .payroll-shift-row {
    grid-template-columns: 58px minmax(0, 1fr) minmax(86px, auto);
    min-height: 58px;
    padding: 8px;
  }

  .payroll-shift-date {
    padding: 7px 5px;
  }

  .payroll-shift-date strong,
  .payroll-shift-main strong,
  .payroll-shift-stats strong {
    font-size: 13px;
  }

  .payroll-shift-main small,
  .payroll-shift-stats small {
    font-size: 10px;
  }

  .calendar-header {
    display: grid;
    gap: 10px;
    margin-bottom: 8px;
    padding: 10px;
  }

  .calendar-header h2 {
    font-size: 19px;
    min-height: 0;
    white-space: normal;
  }

  .calendar-controls-row {
    display: grid;
    gap: 8px;
  }

  .calendar-header .inline-control,
  .calendar-week-actions {
    width: 100%;
  }

  .calendar-header .inline-control {
    align-items: stretch;
    display: grid;
  }

  .calendar-header .inline-control select {
    width: 100%;
  }

  .calendar-week-actions {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
  }

  .calendar-week-actions .topbar-actions {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) 44px;
    width: 100%;
  }

  .calendar-with-mini,
  .admin-calendar-with-mini {
    gap: 10px;
  }

  .calendar-with-mini > .mini-calendar-panel,
  .admin-calendar-with-mini > .mini-calendar-panel {
    display: none;
  }

  .mini-calendar-panel {
    gap: 10px;
    padding: 10px;
  }

  .mini-calendar-day {
    min-height: 32px;
  }

  .stream-calendar {
    gap: 8px;
    overflow: hidden;
    padding: 8px;
  }

  .stream-heading {
    align-items: start;
    padding: 9px 10px;
  }

  .stream-heading h3 {
    font-size: 15px;
  }

  .calendar-grid {
    grid-template-columns: repeat(7, minmax(150px, 1fr));
    max-width: 100%;
    overflow-x: auto;
    overscroll-behavior-x: contain;
  }

  .day-column {
    min-height: 500px;
  }

  .orders-view-header {
    gap: 10px;
  }

  .orders-view-header .view-subtitle {
    display: none;
  }

  .orders-filter-bar {
    gap: 8px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: 10px;
  }

  .orders-filter-bar .inline-control:first-child,
  .orders-range-presets {
    grid-column: 1 / -1;
  }

  .orders-filter-bar > button {
    width: 100%;
  }

  .orders-range-presets {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .orders-range-presets button {
    min-height: 34px;
    padding: 0 8px;
  }

  .orders-browser-panel {
    gap: 10px;
    min-width: 0;
    overflow: hidden;
    padding: 8px;
  }

  .table-wrap.orders-table-wrap {
    max-width: 100%;
    overflow-x: auto;
    overflow-y: visible;
    -webkit-overflow-scrolling: touch;
  }

  .orders-table {
    min-width: 920px;
  }

  .orders-pagination {
    justify-content: center;
  }

  .orders-page-numbers {
    display: none;
  }

  .metric-strip {
    grid-template-columns: 1fr;
  }

  .admin-workbench,
  .admin-workbench:has(.admin-form-toggle[open]) {
    gap: 10px;
    grid-template-columns: minmax(0, 1fr);
    overflow: hidden;
  }

  .admin-scheduler-panel {
    min-width: 0;
    overflow: hidden;
    padding: 10px;
  }

  .admin-scheduler-panel > .panel-heading {
    align-items: stretch;
    display: grid;
    gap: 10px;
  }

  .admin-scheduler-panel > .panel-heading h3 {
    font-size: 16px;
  }

  .admin-scheduler-panel .panel-heading .inline-control {
    min-width: 0;
    width: 100%;
  }

  .admin-scheduler-panel .panel-heading .inline-control select {
    width: 100%;
  }

  .admin-stream-board {
    overflow: hidden;
    padding: 7px;
  }

  .admin-stream-actions {
    align-items: stretch;
    display: grid;
    gap: 8px;
    grid-template-columns: 1fr auto;
  }

  .admin-day-scroll-controls {
    display: grid;
    grid-template-columns: 38px 68px 38px;
  }

  .admin-day-scroll-controls .icon-button {
    min-height: 38px;
    width: 38px;
  }

  .admin-today-button {
    min-height: 38px;
    padding: 0 10px;
  }

  .admin-time-grid {
    grid-template-columns: 58px repeat(7, minmax(116px, 1fr));
    height: clamp(520px, 68vh, 760px);
    max-width: 100%;
  }

  .admin-day-heading {
    padding: 8px 7px;
  }

  .admin-time-label {
    font-size: 11px;
    padding-right: 6px;
  }

  .admin-shift-bubble {
    padding: 8px;
  }

  .admin-shift-bubble strong {
    font-size: 11px;
  }

  .admin-shift-bubble .shift-gmv {
    font-size: 15px;
  }

  .admin-form-toggle {
    justify-self: stretch;
    position: static;
    width: 100%;
  }

  .payroll-panel {
    padding: 12px;
  }

  .payroll-heading {
    align-items: stretch;
    display: grid;
    gap: 12px;
    padding: 12px;
  }

  .payroll-heading .inline-control {
    min-width: 0;
    width: 100%;
  }

  .payroll-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    min-width: 0;
  }

  .payroll-metrics div {
    min-width: 0;
    padding: 10px;
  }

  .payroll-metrics span {
    font-size: clamp(17px, 5vw, 21px);
  }

  .attribution-gap-metrics,
  .unattributed-toolbar,
.unattributed-order {
    grid-template-columns: 1fr;
  }

  .payroll-grid {
    border: 0;
    display: grid;
    gap: 10px;
    overflow: visible;
  }

  .payroll-grid-toolbar {
    min-width: 0;
    position: static;
  }

  .payroll-grid-header {
    display: none;
  }

  .payroll-grid-body {
    gap: 10px;
  }

  .payroll-row {
    background: linear-gradient(180deg, #20272d, #1a2025);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    grid-template-columns: 1fr;
    min-width: 0;
    overflow: hidden;
  }

  .payroll-row > div {
    align-items: center;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    display: flex;
    gap: 12px;
    justify-content: space-between;
    min-height: 42px;
    padding: 9px 11px;
    text-align: right;
  }

  .payroll-row > div:last-child {
    border-bottom: 0;
  }

  .payroll-person {
    align-items: start;
    background: rgba(255, 255, 255, 0.025);
    justify-content: flex-start;
    text-align: left;
  }

  .payroll-row > div:not(.payroll-person)::before {
    color: var(--muted);
    content: attr(data-label);
    flex: 0 0 118px;
    font-size: 11px;
    font-weight: 900;
    text-align: left;
    text-transform: uppercase;
  }

  .payroll-edit-cell {
    align-items: center;
  }

  .payroll-edit-cell .payroll-input-wrap {
    max-width: 190px;
    width: min(190px, 58%);
  }

  .payroll-cell span {
    text-align: right;
  }

  .payroll-grid-toolbar {
    align-items: stretch;
    display: grid;
  }

  .payroll-grid-toolbar .primary-button {
    justify-self: stretch;
  }
}

.order-audit-card {
  cursor: pointer;
}

.order-audit-card:hover {
  border-color: rgba(77, 224, 206, 0.34);
}

/* Theme surface layer: keeps every palette dark-compatible and visibly distinct. */
:root[data-theme] .topbar {
  background: color-mix(in srgb, var(--surface-0) 88%, var(--accent) 12%);
}

:root[data-theme] .topbar,
:root[data-theme] .sidebar,
:root[data-theme] .workspace {
  border-color: var(--line);
}

:root[data-theme] .workspace,
:root[data-theme] .panel,
:root[data-theme] .orders-filter-bar,
:root[data-theme] .orders-browser-panel,
:root[data-theme] .admin-scheduler-panel,
:root[data-theme] .admin-stream-board,
:root[data-theme] .audit-drawer-panel,
:root[data-theme] .payroll-grid,
:root[data-theme] .analytics-panel,
:root[data-theme] .inventory-grid section,
:root[data-theme] .embedded-panel {
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--surface-2) 92%, var(--accent) 8%), var(--surface-1));
  border-color: var(--line);
  color: var(--text);
}

:root[data-theme] button,
:root[data-theme] .nav-link-button,
:root[data-theme] .tab-button,
:root[data-theme] input,
:root[data-theme] select,
:root[data-theme] textarea,
:root[data-theme] .orders-pagination,
:root[data-theme] .table-wrap,
:root[data-theme] .admin-subtabs,
:root[data-theme] .inventory-subtabs,
:root[data-theme] .user-subtabs,
:root[data-theme] .metric-strip div,
:root[data-theme] .user-month-metrics div,
:root[data-theme] .audit-detail-item,
:root[data-theme] .audit-order-button,
:root[data-theme] .audit-shift-button,
:root[data-theme] .audit-item-row {
  background: linear-gradient(180deg, var(--surface-3), var(--surface-2));
  border-color: var(--line);
  color: var(--text);
}

:root[data-theme] button:hover,
:root[data-theme] .nav-link-button:hover {
  border-color: var(--accent);
  color: var(--accent-strong);
}

:root[data-theme] input,
:root[data-theme] select,
:root[data-theme] textarea {
  background: var(--surface-field);
  color: var(--text);
}

:root[data-theme] .data-table th,
:root[data-theme] .admin-day-heading,
:root[data-theme] .admin-grid-corner,
:root[data-theme] .admin-time-label,
:root[data-theme] .payroll-grid-toolbar {
  background: color-mix(in srgb, var(--surface-1) 86%, var(--accent) 14%);
}

:root[data-theme] .data-table td,
:root[data-theme] .order-audit-row td,
:root[data-theme] .payroll-row,
:root[data-theme] .admin-slot,
:root[data-theme] .admin-scheduler,
:root[data-theme] .admin-stream-calendar,
:root[data-theme] .mini-calendar-day,
:root[data-theme] .sidebar-summary {
  background: var(--surface-1);
}

:root[data-theme] .orders-range-presets button,
:root[data-theme] .order-status-chip,
:root[data-theme] .selected-stream-label,
:root[data-theme] .metric-pill {
  background: color-mix(in srgb, var(--accent) 16%, var(--surface-1) 84%);
  border-color: color-mix(in srgb, var(--accent) 42%, var(--line) 58%);
}

:root[data-theme] .tab-button.active,
:root[data-theme] .admin-subtab.active,
:root[data-theme] .inventory-subtab.active,
:root[data-theme] .user-subtab.active,
:root[data-theme] .orders-page-button.active {
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 38%, var(--surface-3) 62%), var(--surface-3));
  border-color: color-mix(in srgb, var(--accent) 54%, var(--line) 46%);
  color: var(--text);
}

:root[data-theme] .admin-shift-bubble.collectibles,
:root[data-theme] .shift-card.collectibles {
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 22%, var(--surface-2) 78%), var(--surface-2));
  border-color: color-mix(in srgb, var(--accent) 54%, var(--line) 46%);
  border-left-color: var(--accent-strong);
}

:root[data-theme] .admin-shift-bubble.breaks,
:root[data-theme] .shift-card.breaks {
  background: linear-gradient(180deg, color-mix(in srgb, var(--blue) 24%, var(--surface-2) 76%), var(--surface-2));
  border-color: color-mix(in srgb, var(--blue) 54%, var(--line) 46%);
  border-left-color: var(--blue);
}

:root[data-theme] .primary-button {
  background: linear-gradient(180deg, var(--accent-strong), var(--accent));
  border-color: var(--accent);
  color: var(--surface-0);
}

:root[data-theme] .audit-note,
:root[data-theme] .audit-section,
:root[data-theme] .audit-order-profile,
:root[data-theme] .order-detail-card,
:root[data-theme] .unattributed-card,
:root[data-theme] .manual-attribution-card,
:root[data-theme] .orders-filter-shell {
  background: color-mix(in srgb, var(--surface-2) 88%, var(--surface-1) 12%);
  border-color: var(--line);
}

:root[data-theme] .audit-decision-section {
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 10%, var(--surface-2) 90%), var(--surface-1));
}

:root[data-theme] .admin-day-scroll {
  scrollbar-color: var(--line-strong) var(--surface-1);
}

:root[data-theme="bmc"] .topbar {
  background:
    linear-gradient(90deg, rgba(16, 25, 35, 0.98), rgba(18, 31, 43, 0.96) 58%, rgba(22, 38, 53, 0.94)),
    radial-gradient(circle at 9% 50%, rgba(156, 197, 197, 0.08), transparent 18rem);
  box-shadow:
    inset 0 -1px 0 rgba(156, 197, 197, 0.1),
    0 10px 28px rgba(0, 0, 0, 0.16);
}

:root[data-theme="bmc"] .brand-logo {
  border-color: rgba(180, 138, 67, 0.42);
  box-shadow:
    0 0 0 1px rgba(180, 138, 67, 0.06),
    0 10px 24px rgba(0, 0, 0, 0.28);
}

:root[data-theme="bmc"] .tab-button.active,
:root[data-theme="bmc"] .admin-subtab.active,
:root[data-theme="bmc"] .inventory-subtab.active,
:root[data-theme="bmc"] .user-subtab.active,
:root[data-theme="bmc"] .orders-page-button.active {
  background: linear-gradient(180deg, #3f6266, #314f56);
  border-color: #6f8f94;
  color: #dce6e9;
}

:root[data-theme="bmc"] .primary-button {
  color: #101923;
}

:root[data-theme="bmc"] .orders-range-presets button,
:root[data-theme="bmc"] .order-status-chip,
:root[data-theme="bmc"] .selected-stream-label,
:root[data-theme="bmc"] .metric-pill {
  color: #a8c5c6;
}

:root[data-theme="bmc"] .admin-shift-bubble.collectibles,
:root[data-theme="bmc"] .shift-card.collectibles {
  background:
    linear-gradient(180deg, rgba(34, 49, 65, 0.96), rgba(24, 38, 52, 0.98));
  border-color: #405468;
  border-left-color: #b48a43;
  box-shadow:
    inset 4px 0 0 rgba(180, 138, 67, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 8px 18px rgba(0, 0, 0, 0.16);
}

:root[data-theme="bmc"] .admin-shift-bubble.collectibles:hover,
:root[data-theme="bmc"] .shift-card.collectibles:hover {
  border-color: #637b91;
  border-left-color: #c79b55;
  box-shadow:
    inset 4px 0 0 rgba(180, 138, 67, 0.28),
    0 0 0 1px rgba(180, 138, 67, 0.08),
    0 12px 24px rgba(0, 0, 0, 0.2);
}

:root[data-theme="bmc"] .admin-shift-bubble.breaks,
:root[data-theme="bmc"] .shift-card.breaks {
  background:
    linear-gradient(180deg, rgba(28, 55, 65, 0.96), rgba(21, 42, 53, 0.98));
  border-color: #3f6270;
  border-left-color: #6b999c;
  box-shadow:
    inset 4px 0 0 rgba(107, 153, 156, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 8px 18px rgba(0, 0, 0, 0.16);
}

:root[data-theme="bmc"] .admin-shift-bubble.breaks:hover,
:root[data-theme="bmc"] .shift-card.breaks:hover {
  border-color: #688996;
  border-left-color: #8fb9bc;
}

:root[data-theme="light"] .topbar {
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 1px 0 rgba(32, 50, 68, 0.08);
}

:root[data-theme="light"] .brand-logo {
  box-shadow: 0 8px 22px rgba(24, 42, 64, 0.18);
}

:root[data-theme="light"] .workspace,
:root[data-theme="light"] .panel,
:root[data-theme="light"] .orders-filter-bar,
:root[data-theme="light"] .orders-browser-panel,
:root[data-theme="light"] .admin-scheduler-panel,
:root[data-theme="light"] .admin-stream-board,
:root[data-theme="light"] .audit-drawer-panel,
:root[data-theme="light"] .payroll-grid,
:root[data-theme="light"] .analytics-panel,
:root[data-theme="light"] .inventory-grid section,
:root[data-theme="light"] .embedded-panel {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), var(--surface-1));
}

:root[data-theme="light"] .audit-drawer {
  background: rgba(21, 32, 43, 0.28);
}

:root[data-theme="light"] .calendar-with-mini,
:root[data-theme="light"] .admin-calendar-with-mini,
:root[data-theme="light"] .stream-calendar,
:root[data-theme="light"] .admin-stream-calendar {
  background: rgba(255, 255, 255, 0.74);
}

:root[data-theme="light"] .admin-grid-cell,
:root[data-theme="light"] .calendar-day,
:root[data-theme="light"] .admin-slot {
  background: #f8fbfd;
}

:root[data-theme="light"] .admin-shift-bubble.collectibles,
:root[data-theme="light"] .shift-card.collectibles {
  background: linear-gradient(180deg, #e8f5f1, #dcefe9);
  border-color: #8dc7b8;
  border-left-color: var(--accent);
}

:root[data-theme="light"] .admin-shift-bubble.breaks,
:root[data-theme="light"] .shift-card.breaks {
  background: linear-gradient(180deg, #eaf2fb, #dfeaf7);
  border-color: #8fb5df;
  border-left-color: var(--blue);
}

:root[data-theme="light"] .primary-button {
  color: #ffffff;
}

:root[data-theme="light"] .audit-back-button {
  color: var(--accent-strong);
}

@media (max-width: 470px) {
  .topbar {
    align-items: stretch;
    flex-direction: column;
    gap: 10px;
    justify-content: flex-start;
  }

  .theme-control {
    flex: none;
  }

  .brand-logo {
    height: 44px;
    width: 66px;
  }
}
