/* ============================================================
   Дизайн-система — «Отчёты»
   Холодный dark интерфейс, голубой акцент, стеклянные панели.
   Все классы-хуки сохранены для совместимости с app.js.
   ============================================================ */

:root {
  color-scheme: dark;

  --bg: #0b0e16;
  --bg-2: #0e1220;
  --panel: rgba(24, 30, 49, 0.86);
  --panel-solid: #131828;
  --panel-strong: #181e31;
  --surface: rgba(19, 24, 40, 0.78);
  --field: #1b2130;
  --field-strong: #232c44;
  --sidebar: rgba(14, 18, 32, 0.94);

  --ink: #e9edfa;
  --ink-soft: #f2f5ff;
  --muted: #aab4d4;
  --faint: #6b7699;
  --line: rgba(148, 163, 216, 0.14);
  --line-strong: rgba(148, 163, 216, 0.3);

  --accent: #5b8cff;
  --accent-2: #7aa2ff;
  --accent-glow: rgba(91, 140, 255, 0.42);
  --blue: #7aa2ff;
  --blue-strong: #93b8fa;

  --green: #34d399;
  --green-dark: #6ee7b7;
  --amber: #fbbf24;
  --red: #fb6f84;

  --button-text: #ffffff;
  --nav-text: #aab4d4;

  --soft-blue: rgba(91, 140, 255, 0.16);
  --soft-green: rgba(52, 211, 153, 0.16);
  --soft-danger: rgba(251, 111, 132, 0.16);
  --soft-warning: rgba(251, 191, 36, 0.18);

  --grad-accent: linear-gradient(135deg, #6c9bff 0%, #5b8cff 48%, #4d7dff 100%);
  --grad-panel: linear-gradient(180deg, rgba(148, 163, 216, 0.09), rgba(148, 163, 216, 0.015));

  --shadow: 0 24px 70px rgba(0, 0, 0, 0.5);
  --shadow-sm: 0 10px 28px rgba(0, 0, 0, 0.32);
  --shadow-lg: var(--shadow);
  --shadow-glow: 0 18px 42px rgba(91, 140, 255, 0.32);

  --r: 14px;
  --r-sm: 10px;
  --r-md: var(--r);
  --r-lg: 18px;
  --r-pill: 999px;

  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

body[data-theme="light"] {
  color-scheme: light;

  --bg: #eef4fb;
  --bg-2: #e5edf7;
  --panel: rgba(255, 255, 255, 0.84);
  --panel-solid: #ffffff;
  --panel-strong: #f1f6fc;
  --surface: rgba(245, 249, 254, 0.78);
  --field: #f8fbff;
  --field-strong: #edf4fb;
  --sidebar: rgba(248, 251, 255, 0.9);

  --ink: #0b1c30;
  --ink-soft: #1f344b;
  --muted: #4b6178;
  --faint: #657b93;
  --line: rgba(55, 112, 168, 0.18);
  --line-strong: rgba(55, 112, 168, 0.32);

  --accent: #258fe8;
  --accent-2: #6fc4ff;
  --accent-glow: rgba(37, 143, 232, 0.24);
  --blue: #258fe8;
  --blue-strong: #176fb8;

  --green: #139d72;
  --green-dark: #0f7a58;
  --amber: #bb850e;
  --red: #d84f59;

  --button-text: #ffffff;
  --nav-text: #42576e;

  --soft-blue: rgba(37, 143, 232, 0.12);
  --soft-green: rgba(19, 157, 114, 0.12);
  --soft-danger: rgba(216, 79, 89, 0.11);
  --soft-warning: rgba(187, 133, 14, 0.13);

  --grad-accent: linear-gradient(180deg, #78cbff 0%, #2f9dec 52%, #1678c8 100%);
  --grad-panel: linear-gradient(180deg, rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0));

  --shadow: 0 18px 44px rgba(24, 63, 102, 0.13);
  --shadow-sm: 0 6px 18px rgba(24, 63, 102, 0.09);
  --shadow-glow: 0 14px 32px rgba(37, 143, 232, 0.2);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(1100px 500px at 85% -10%, rgba(91, 140, 255, 0.10), transparent 60%),
    radial-gradient(900px 500px at -10% 110%, rgba(139, 124, 246, 0.08), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  color: var(--ink);
  font-family: "Manrope", Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  letter-spacing: 0;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(118deg, transparent 0 18%, rgba(160, 215, 255, 0.045) 23%, transparent 35% 100%),
    linear-gradient(62deg, transparent 0 42%, rgba(255, 255, 255, 0.035) 49%, transparent 60% 100%),
    linear-gradient(142deg, rgba(7, 13, 22, 0.2), transparent 34%, rgba(3, 6, 10, 0.55) 76%),
    repeating-linear-gradient(90deg, rgba(148, 163, 216, 0.018) 0 1px, transparent 1px 68px),
    radial-gradient(1200px circle at 52% -18%, rgba(103, 184, 243, 0.12), transparent 58%),
    linear-gradient(180deg, var(--bg-2), var(--bg));
}

body::after {
  content: "";
  position: fixed;
  inset: -18%;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(125deg, transparent 8%, rgba(255, 255, 255, 0.035) 20%, rgba(255, 255, 255, 0.008) 31%, transparent 43%),
    linear-gradient(68deg, transparent 38%, rgba(120, 200, 255, 0.045) 49%, transparent 58%),
    linear-gradient(160deg, transparent 55%, rgba(255, 255, 255, 0.028) 66%, transparent 77%);
  filter: blur(22px);
  opacity: 0.9;
}

body[data-theme="light"]::before {
  background:
    linear-gradient(118deg, transparent 0 18%, rgba(37, 143, 232, 0.05) 23%, transparent 36% 100%),
    repeating-linear-gradient(90deg, rgba(37, 143, 232, 0.028) 0 1px, transparent 1px 68px),
    radial-gradient(1000px circle at 50% -8%, rgba(37, 143, 232, 0.16), transparent 50%),
    linear-gradient(180deg, #f7fbff, var(--bg));
}

body[data-theme="light"]::after {
  opacity: 0.32;
}

body[data-theme="light"] .login-card,
body[data-theme="light"] .modal {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0)),
    rgba(255, 255, 255, 0.9);
}

body[data-theme="light"] .topbar-actions button,
body[data-theme="light"] .import-button,
body[data-theme="light"] .ghost-button,
body[data-theme="light"] .icon-button,
body[data-theme="light"] .delete-button,
body[data-theme="light"] .extra-chip,
body[data-theme="light"] .tx-type-btn {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.75), rgba(255, 255, 255, 0)),
    rgba(255, 255, 255, 0.72);
}

body[data-theme="light"] .sidebar-note,
body[data-theme="light"] .table-wrap,
body[data-theme="light"] .payroll-tool-card,
body[data-theme="light"] .admin-shift-card,
body[data-theme="light"] .shift-detail-stat,
body[data-theme="light"] .shift-detail-section {
  background: rgba(255, 255, 255, 0.64);
}

body[data-theme="light"] thead th {
  background: rgba(240, 247, 255, 0.96);
}

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

button {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.4;
}

::selection {
  background: var(--accent-glow);
  color: var(--ink);
}

/* ---------- Скроллбар ---------- */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--line-strong) transparent;
}

*::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

*::-webkit-scrollbar-thumb {
  background: var(--line-strong);
  border-radius: var(--r-pill);
  border: 2px solid transparent;
  background-clip: content-box;
}

*::-webkit-scrollbar-thumb:hover {
  background: var(--faint);
  background-clip: content-box;
}

/* ============================================================
   Экран входа
   ============================================================ */
.login-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.36)),
    radial-gradient(520px circle at 50% 52%, rgba(148, 163, 216, 0.08), transparent 68%);
}

.login-card {
  position: relative;
  width: min(392px, 100%);
  display: grid;
  gap: 17px;
  border: 1px solid rgba(150, 205, 255, 0.14);
  border-radius: var(--r-lg);
  padding: 28px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0)),
    rgba(22, 25, 33, 0.78);
  backdrop-filter: blur(22px);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.06) inset,
    0 28px 90px rgba(0, 0, 0, 0.62);
  overflow: hidden;
}

.login-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(148, 163, 216, 0.08);
}

.login-brand {
  color: var(--ink);
}

.login-brand span:not(.brand-mark) {
  color: var(--faint);
}

.login-card h1 {
  font-size: 28px;
}

.login-error {
  margin: 0;
  border: 1px solid rgba(255, 96, 114, 0.35);
  border-radius: var(--r-sm);
  padding: 11px 13px;
  background: var(--soft-danger);
  color: var(--red);
  font-weight: 700;
  font-size: 14px;
}

.login-hint {
  margin: 0;
  color: var(--faint);
  font-size: 13px;
  text-align: center;
}

/* ============================================================
   Каркас приложения
   ============================================================ */
.app-shell {
  display: grid;
  grid-template-columns: 258px minmax(0, 1fr);
  min-height: 100vh;
}

.app-shell[hidden],
.login-screen[hidden] {
  display: none !important;
}

/* ---------- Сайдбар ---------- */
.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 24px 16px;
  background:
    linear-gradient(180deg, rgba(148, 163, 216, 0.045), transparent 28%),
    var(--sidebar);
  backdrop-filter: blur(24px);
  border-right: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 4px 8px;
  min-height: 68px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border: 1px solid rgba(194, 233, 255, 0.28);
  border-radius: 18px;
  background: var(--panel-strong);
  color: #06121d;
  font-weight: 800;
  font-size: 20px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.16),
    0 16px 36px rgba(70, 170, 245, 0.2);
  overflow: hidden;
}

.brand-mark svg {
  display: none;
}

.brand-mark img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.brand-mark::before {
  content: "";
  display: none;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 9px;
  border: 1px solid rgba(6, 18, 29, 0.24);
  background: rgba(255, 255, 255, 0.2);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.42);
}

.brand strong,
.brand span {
  display: block;
}

.brand strong {
  color: var(--ink);
  font-size: 22px;
  line-height: 1.1;
  letter-spacing: 0;
}

.brand span {
  color: var(--faint);
  font-size: 12.5px;
  font-weight: 650;
}

.login-brand .brand-message {
  max-width: 250px;
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 1.35;
}

.nav {
  display: grid;
  gap: 4px;
}

.nav-group {
  display: grid;
  gap: 4px;
}

.nav-group[hidden] {
  display: none;
}

.nav-group + .nav-group {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.nav-label {
  padding: 2px 13px 6px;
  color: var(--blue-strong);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0;
}

.nav a {
  position: relative;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 11px 13px;
  border: 1px solid transparent;
  border-radius: var(--r-sm);
  color: var(--nav-text);
  font-size: 14.5px;
  font-weight: 600;
  text-decoration: none;
  transition: border-color 180ms var(--ease), background 180ms var(--ease), color 180ms var(--ease), transform 120ms var(--ease);
}

.nav a svg {
  width: 19px;
  height: 19px;
  flex-shrink: 0;
  opacity: 0.85;
}

.nav a[hidden] {
  display: none;
}

.nav a:hover {
  background: var(--soft-blue);
  border-color: var(--line);
  color: var(--ink);
}

.nav a.active {
  background: var(--grad-accent);
  color: #06121d;
  box-shadow: var(--shadow-glow);
}

.nav a.active svg {
  opacity: 1;
}

.sidebar-note {
  margin-top: auto;
  display: grid;
  gap: 10px;
  padding: 15px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: rgba(24, 32, 45, 0.78);
  color: var(--ink-soft);
  font-size: 12.5px;
  line-height: 1.4;
}

.sidebar-note button {
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  padding: 9px 10px;
  background: transparent;
  color: var(--ink-soft);
  font-weight: 600;
  font-size: 13px;
  transition: border-color 160ms var(--ease), color 160ms var(--ease);
}

.sidebar-note button:hover {
  border-color: var(--red);
  color: var(--red);
}

/* ---------- Основная область ---------- */
main {
  min-width: 0;
  width: 100%;
  padding: 28px 34px 44px;
}

.topbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
  flex-wrap: wrap;
}

.eyebrow {
  margin: 0 0 5px;
  color: var(--blue-strong);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2 {
  margin: 0;
  line-height: 1.12;
  letter-spacing: 0;
}

h1 {
  font-size: clamp(26px, 3.2vw, 38px);
  font-weight: 800;
}

h2 {
  font-size: 19px;
  font-weight: 700;
}

.topbar-actions,
.filters,
.panel-heading {
  display: flex;
  align-items: center;
  gap: 9px;
}

.topbar-actions {
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: flex-end;
  gap: 10px;
}

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

.table-actions[hidden],
body[data-page="dashboard"] .table-actions,
body[data-page="employees"] .table-actions,
body[data-page="processing"] .table-actions {
  display: none !important;
}

.profile-switcher {
  display: grid;
  gap: 6px;
  min-width: 184px;
  color: var(--ink-soft);
  font-size: 11.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0;
}

.profile-switcher select {
  height: 46px;
  min-height: 46px;
  margin-top: 0;
}

/* ---------- Кнопки в топбаре (вторичные) ---------- */
.topbar-actions button,
.import-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 46px;
  border: 1px solid rgba(148, 163, 216, 0.28);
  border-radius: var(--r-sm);
  padding: 0 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0)),
    rgba(24, 32, 45, 0.82);
  color: var(--ink-soft);
  font-weight: 600;
  font-size: 14px;
  white-space: nowrap;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.045);
  transition: border-color 160ms var(--ease), background 160ms var(--ease), color 160ms var(--ease), transform 120ms var(--ease), box-shadow 160ms var(--ease);
}

.topbar-actions button:hover,
.import-button:hover {
  border-color: var(--accent);
  color: var(--ink);
  transform: translateY(-1px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.075),
    0 12px 30px rgba(91, 140, 255, 0.12);
}

.import-button {
  cursor: pointer;
  border-style: dashed;
}

.import-button input {
  display: none;
}

.theme-toggle {
  min-width: 108px;
}

.theme-toggle::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 0 12px var(--accent);
}

#exportCsv {
  border-color: rgba(94, 226, 167, 0.38);
  color: var(--green-dark);
}

#exportCsv:hover {
  border-color: var(--green);
}

#logoutButton:hover {
  border-color: var(--red);
  color: var(--red);
}

/* ---------- Основная (акцентная) кнопка ---------- */
.primary-button {
  position: relative;
  width: 100%;
  border: 1px solid rgba(167, 221, 255, 0.72);
  border-radius: var(--r-sm);
  padding: 12px 16px;
  background: var(--grad-accent);
  color: #06121d;
  font-weight: 700;
  font-size: 14.5px;
  text-shadow: none;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.48),
    var(--shadow-glow);
  transition: transform 120ms var(--ease), box-shadow 200ms var(--ease), filter 160ms var(--ease);
}

.primary-button:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.56),
    0 22px 48px var(--accent-glow);
}

.primary-button:active {
  transform: translateY(0);
}

.panel-heading .primary-button {
  width: auto;
  padding: 10px 18px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  border-radius: var(--r-pill);
  padding: 5px 13px;
  background: var(--soft-blue);
  color: var(--blue-strong);
  font-size: 12.5px;
  font-weight: 700;
}

/* ============================================================
   Карточки-метрики
   ============================================================ */
.metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 15px;
}

.page {
  min-width: 0;
}

.page[hidden] {
  display: none !important;
}

.page > .panel + .panel,
.page > form + .panel {
  margin-top: 18px;
}

#operations {
  display: grid;
  gap: 18px;
}

.metrics article {
  position: relative;
  padding: 20px;
  border: 1px solid rgba(148, 163, 216, 0.24);
  border-radius: var(--r);
  background:
    var(--grad-panel),
    var(--panel);
  backdrop-filter: blur(16px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    var(--shadow-sm);
  overflow: hidden;
  transition: transform 180ms var(--ease), border-color 180ms var(--ease);
}

.metrics article:hover {
  transform: translateY(-3px);
  border-color: var(--line-strong);
}

.metrics article::after {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--accent);
  opacity: 0.7;
}

.metrics article:nth-child(2)::after {
  background: var(--green);
}

.metrics article:nth-child(3)::after {
  background: var(--amber);
}

.metrics span,
.report-grid span {
  display: block;
  color: var(--faint);
  font-size: 13px;
  font-weight: 650;
}

.metrics strong {
  display: block;
  margin-top: 11px;
  font-size: 29px;
  font-weight: 800;
  letter-spacing: 0;
  font-variant-numeric: tabular-nums;
}

.net-card::after {
  width: 100% !important;
  height: 3px;
  bottom: auto !important;
  background: var(--grad-accent) !important;
  opacity: 1 !important;
}

.net-card strong {
  background: var(--grad-accent);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ============================================================
   Панели
   ============================================================ */
.workspace {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(360px, 1.3fr) minmax(310px, 0.7fr);
  gap: 18px;
  margin-bottom: 18px;
}

.panel {
  min-width: 0;
  padding: 22px;
  border: 1px solid rgba(148, 163, 216, 0.24);
  border-radius: var(--r);
  background:
    var(--grad-panel),
    var(--panel);
  backdrop-filter: blur(16px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    var(--shadow-sm);
}

.panel-heading {
  justify-content: space-between;
  margin-bottom: 18px;
  flex-wrap: wrap;
  gap: 12px;
}

.icon-button,
.delete-button {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(148, 163, 216, 0.24);
  border-radius: var(--r-sm);
  background: rgba(24, 32, 45, 0.78);
  color: var(--ink-soft);
  font-size: 20px;
}

.icon-button:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.row-actions {
  display: flex;
  gap: 6px;
  align-items: center;
  justify-content: flex-end;
  white-space: nowrap;
}
.row-actions .row-action,
.row-actions .delete-button {
  width: 32px;
  height: 32px;
  font-size: 16px;
}
.row-actions .delete-button:hover {
  border-color: var(--red);
  color: var(--red);
}

.delete-button {
  width: 30px;
  height: 30px;
  font-size: 18px;
  color: var(--faint);
}

@media (hover: hover) {
  .delete-button:hover {
    border-color: var(--red);
    background: var(--soft-danger);
    color: var(--red);
  }
}

/* Подсветка только при реальном нажатии — никакого залипания на тач/трекпаде. */
.delete-button:active {
  border-color: var(--red);
  background: var(--soft-danger);
  color: var(--red);
}

/* Кнопка скрина в режиме подтверждения удаления (после первого клика). */
.delete-button.confirming {
  border-color: var(--red) !important;
  background: var(--soft-danger) !important;
  color: var(--red) !important;
}

/* ============================================================
   Формы
   ============================================================ */
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 13px;
  margin-bottom: 16px;
}

label {
  display: grid;
  gap: 7px;
  color: var(--ink-soft);
  font-size: 12.5px;
  font-weight: 650;
}

.wide {
  grid-column: 1 / -1;
}

input,
select {
  width: 100%;
  min-height: 42px;
  border: 1px solid rgba(148, 163, 216, 0.3);
  border-radius: var(--r-sm);
  padding: 10px 12px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0)),
    var(--field);
  color: var(--ink);
  transition: border-color 150ms var(--ease), box-shadow 150ms var(--ease), background 150ms var(--ease);
}

input:hover,
select:hover {
  border-color: var(--faint);
}

input:focus,
select:focus,
button:focus-visible,
.import-button:focus-within {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

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

select {
  appearance: none;
  background-image:
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0)),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4l4 4 4-4' stroke='%238ccfff' stroke-width='1.6' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 34px;
}

/* ---------- Комбобокс ---------- */
.combo-wrap {
  position: relative;
}

.combo-wrap::after {
  content: "";
  position: absolute;
  right: 13px;
  top: 50%;
  width: 7px;
  height: 7px;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  pointer-events: none;
  transform: translateY(-65%) rotate(45deg);
}

.combo-wrap input {
  padding-right: 36px;
}

.combo-menu {
  position: absolute;
  z-index: 30;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  max-height: 264px;
  overflow-y: auto;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--panel-strong);
  backdrop-filter: blur(20px);
  box-shadow: var(--shadow);
  padding: 6px;
}

.combo-option {
  width: 100%;
  min-height: 38px;
  border: 0;
  border-radius: 8px;
  padding: 9px 11px;
  background: transparent;
  color: var(--ink-soft);
  text-align: left;
  font-weight: 600;
  transition: background 120ms var(--ease), color 120ms var(--ease);
}

.combo-option:hover,
.combo-option:focus-visible {
  background: var(--soft-blue);
  color: var(--ink);
  outline: 0;
}

.combo-empty {
  padding: 12px 11px;
  color: var(--faint);
  font-weight: 600;
}

/* ---------- Отчётная сетка ---------- */
.report-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 13px;
}

.report-filters {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 12px;
  padding: 16px;
  margin-bottom: 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--surface);
}

.report-filter-wide {
  grid-column: 1 / -1;
}

.report-count {
  margin: 0 0 14px;
  color: var(--faint);
  font-size: 13.5px;
  font-weight: 600;
}

/* ---------- Курс USDT ---------- */
.rate-panel {
  margin-bottom: 18px;
}

.rate-widget {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}

.rate-note {
  margin: 6px 0 0;
  max-width: 460px;
  color: var(--faint);
  font-size: 12.5px;
  line-height: 1.45;
}

.rate-form {
  display: flex;
  align-items: flex-end;
  gap: 10px;
}

.rate-form label {
  min-width: 150px;
}

.rate-form .primary-button {
  width: auto;
  white-space: nowrap;
}

/* ---------- Доп услуги ---------- */
.extras-panel {
  margin-top: 18px;
}

.extra-form {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(140px, 0.5fr) minmax(120px, 0.25fr) auto;
  gap: 13px;
  align-items: end;
  margin-bottom: 18px;
}

.extra-form .primary-button {
  width: auto;
  padding: 12px 22px;
}

.operation-extras {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 42px;
  align-items: center;
}

.operation-extras-empty {
  color: var(--faint);
  font-size: 13px;
  font-weight: 650;
}

.extra-chip {
  border: 1px solid rgba(148, 163, 216, 0.28);
  border-radius: var(--r-pill);
  padding: 8px 14px;
  background: rgba(24, 32, 45, 0.78);
  color: var(--ink-soft);
  font-weight: 600;
  font-size: 13px;
  transition: border-color 140ms var(--ease), background 140ms var(--ease), color 140ms var(--ease);
}

.extra-chip:hover {
  border-color: var(--accent);
}

.extra-chip.active {
  border-color: transparent;
  background: var(--grad-accent);
  color: #06121d;
}

/* ---------- Плитки прайса ---------- */
.price-tiles-panel .panel-heading input[type="search"] {
  width: auto;
  min-width: 200px;
}

.price-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 12px;
}

.price-tile {
  display: grid;
  gap: 5px;
  text-align: left;
  padding: 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--surface);
  color: var(--ink);
  transition: transform 120ms var(--ease), border-color 140ms var(--ease), box-shadow 160ms var(--ease);
}

.price-tile:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: var(--shadow-sm);
}

.price-tile strong {
  font-size: 15px;
}

.price-tile span {
  color: var(--faint);
  font-size: 12.5px;
}

.price-tile small {
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
}

.price-tile .tile-stock-ok { color: var(--green-dark); }
.price-tile .tile-stock-empty { color: var(--red); }

/* ---------- Аналитика Авито ---------- */
.avito-metrics {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  margin-bottom: 18px;
}

.avito-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.avito-actions input[type="search"] {
  width: auto;
  min-width: 180px;
}

.avito-status {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 13px;
}

.avito-period {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 14px;
  font-size: 13px;
}

.avito-period-label {
  color: var(--muted);
}

.avito-period label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
}

.avito-period input[type="date"] {
  padding: 6px 10px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: inherit;
}

.avito-table {
  min-width: 2200px;
}
.avito-group-row td {
  background: var(--surface);
  font-size: 13px;
  color: var(--muted);
  padding: 10px 12px;
  border-top: 2px solid var(--border);
}
.avito-group-row strong { color: inherit; font-size: 14px; }
.avito-table th.avito-hl,
.avito-table td.avito-hl {
  background: var(--soft-blue);
  font-weight: 600;
}
.avito-table th.avito-hl { color: var(--accent); }

.avito-table td {
  font-variant-numeric: tabular-nums;
}

.avito-table td:first-child {
  font-weight: 600;
  max-width: 280px;
}

/* ---------- Склад ---------- */
.stock-metrics { margin-bottom: 18px; }
.stock-add-panel { margin-bottom: 18px; }

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

.stock-form .wide { grid-column: 1 / -1; }

.stock-form textarea {
  width: 100%;
  min-height: 96px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  padding: 10px 12px;
  background: var(--field);
  color: var(--ink);
  font: inherit;
  resize: vertical;
}

.stock-form textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.stock-form .primary-button { grid-column: 1 / -1; justify-self: start; width: auto; padding: 12px 28px; }

.stock-filters input,
.stock-filters select { min-width: 160px; }

.stock-groups {
  display: grid;
  gap: 10px;
}

.stock-group {
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--surface);
  overflow: hidden;
}

.stock-group-head {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 14px 16px;
  background: transparent;
  border: 0;
  color: var(--ink);
  text-align: left;
}

.stock-group-head:hover { background: var(--soft-blue); }

.stock-group-title { display: flex; align-items: baseline; gap: 10px; flex: 1; min-width: 0; }
.stock-group-title strong { font-size: 15.5px; }
.stock-group-title span { color: var(--muted); font-size: 13px; }
.stock-group-title .stock-orphan { color: var(--red); font-weight: 700; }

.stock-group-counts { display: flex; gap: 8px; }

.stock-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 11px;
  border-radius: var(--r-pill);
  font-weight: 700;
  font-size: 12.5px;
}

.stock-pill.available { background: var(--soft-green); color: var(--green-dark); }
.stock-pill.used { background: var(--soft-warning); color: var(--amber); }

.stock-caret { color: var(--muted); font-size: 12px; }

.stock-items {
  display: grid;
  gap: 6px;
  padding: 0 14px 14px;
}

.stock-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel-solid);
}

.stock-item.used { opacity: 0.62; }

.stock-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
  color: var(--ink);
  word-break: break-all;
  min-width: 120px;
}

.stock-item-meta {
  color: var(--muted);
  font-size: 12.5px;
  margin-right: auto;
}

.stock-item-actions { display: flex; align-items: center; gap: 6px; }
.stock-item-actions .icon-button { width: 30px; height: 30px; font-size: 15px; }
.stock-toggle-btn { padding: 7px 12px; font-size: 12.5px; }

@media (max-width: 680px) {
  .stock-form { grid-template-columns: 1fr; }
  .stock-group-head { flex-wrap: wrap; }
  .stock-item { flex-wrap: wrap; }
}

.bars b {
  margin-left: 6px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.price-panel,
.platforms-panel,
.payments-panel {
  margin-bottom: 0;
}

.price-form,
.platform-form,
.employee-form,
.role-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: 13px;
  align-items: end;
  margin-bottom: 18px;
}

.roles-panel {
  margin-top: 18px;
}

.role-form .permission-grid {
  grid-column: 1 / -1;
}

.role-form > label:first-child {
  grid-column: 1 / -1;
  max-width: 360px;
}

.role-form .primary-button {
  grid-column: 1 / -1;
  justify-self: start;
  width: auto;
  padding: 12px 28px;
}

.platform-form {
  grid-template-columns: minmax(220px, 1fr) repeat(3, minmax(150px, 0.5fr)) minmax(170px, 0.45fr);
}

.employee-form {
  grid-template-columns: repeat(4, minmax(170px, 1fr));
}

.permission-grid {
  grid-column: span 3;
  display: grid;
  grid-template-columns: repeat(3, minmax(120px, 1fr));
  gap: 9px;
  align-self: stretch;
  padding: 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--surface);
}

.permission-grid label {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--ink-soft);
  font-weight: 600;
}

.permission-grid input {
  width: 17px;
  min-height: 17px;
  accent-color: var(--accent);
}

/* ---------- Сводка платежей ---------- */
.payment-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 13px;
  margin-bottom: 16px;
}

.payment-summary div,
.report-grid div {
  padding: 16px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--surface);
}

.payment-summary span {
  display: block;
  color: var(--faint);
  font-size: 13px;
  font-weight: 650;
}

.payment-summary strong,
.report-grid strong {
  display: block;
  margin-top: 8px;
  font-size: 24px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

/* ============================================================
   Процессинг
   ============================================================ */
.processing-metrics {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin-bottom: 18px;
}

.debt-card::after {
  background: var(--red) !important;
}

.debt-card strong.negative {
  color: var(--red);
}

.debt-card strong.positive {
  color: var(--green-dark);
}

/* ---------- Зарплаты процессинга ---------- */
.payroll-panel {
  display: grid;
  gap: 18px;
}

.payroll-content {
  display: grid;
  gap: 18px;
}

.payroll-employee-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}

.payroll-employee-card {
  display: grid;
  gap: 6px;
  min-height: 96px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  padding: 14px;
  background: var(--surface);
  color: var(--ink);
  text-align: left;
  transition: border-color 160ms var(--ease), transform 160ms var(--ease), background 160ms var(--ease);
}

.payroll-employee-card:hover,
.payroll-employee-card.active {
  border-color: var(--accent);
  background: var(--panel);
  transform: translateY(-1px);
}

.payroll-employee-card strong {
  font-size: 15px;
}

.payroll-employee-card span {
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.payroll-employee-card small {
  color: var(--faint);
  font-weight: 700;
}

.payroll-summary {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}

.payroll-stat {
  display: grid;
  gap: 7px;
  min-height: 84px;
  padding: 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--surface);
}

.payroll-stat span {
  color: var(--faint);
  font-size: 12px;
  font-weight: 700;
}

.payroll-stat strong {
  align-self: end;
  color: var(--ink);
  font-size: 18px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.payroll-stat.negative strong,
.payroll-employee-card .negative {
  color: var(--red);
}

.payroll-stat.positive strong,
.payroll-employee-card .positive {
  color: var(--green-dark);
}

.payroll-tools {
  display: grid;
  grid-template-columns: repeat(2, minmax(260px, 1fr));
  gap: 14px;
}

.payroll-tool-card {
  display: grid;
  gap: 12px;
  align-content: start;
  border: 1px solid rgba(148, 163, 216, 0.24);
  border-radius: var(--r-sm);
  padding: 16px;
  background: rgba(24, 32, 45, 0.72);
}

.payroll-tool-card h3 {
  margin: 0;
  font-size: 16px;
}

.payroll-tool-card .primary-button,
.payroll-tool-card .ghost-button {
  width: auto;
  justify-self: start;
  padding-inline: 22px;
}

.payroll-preview {
  margin: 0;
  color: var(--faint);
  font-size: 13px;
  line-height: 1.45;
}

.payroll-section {
  padding: 16px;
}

.payroll-table-wrap {
  margin: 0;
}

.payroll-table {
  min-width: 760px;
}

.payroll-table .empty-row {
  color: var(--faint);
  text-align: center;
  font-weight: 700;
}

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

.admin-processing-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-processing-actions .primary-button,
.admin-processing-actions .ghost-button,
.admin-back-button {
  width: auto;
  padding-inline: 18px;
}

.admin-shift-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
}

.admin-shift-card {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid rgba(148, 163, 216, 0.24);
  border-radius: var(--r-sm);
  background: rgba(24, 32, 45, 0.72);
}

.admin-shift-card > strong {
  font-size: 17px;
}

.admin-shift-card > span {
  color: var(--faint);
  font-size: 13px;
  font-weight: 700;
}

.admin-shift-card .ghost-button {
  width: auto;
  justify-self: start;
  padding-inline: 18px;
}

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

.admin-shift-stats .payroll-stat {
  min-height: 72px;
  padding: 11px;
}

.admin-shift-stats .payroll-stat strong {
  font-size: 15px;
}

/* ---------- Вкладки процессинга ---------- */
.proc-tabs {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  margin-bottom: 18px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--surface);
}

.proc-tab {
  border: 0;
  border-radius: 9px;
  padding: 9px 18px;
  background: transparent;
  color: var(--faint);
  font-weight: 600;
  font-size: 14px;
  transition: background 160ms var(--ease), color 160ms var(--ease);
}

.proc-tab:hover {
  color: var(--ink);
}

.proc-tab.active {
  background: var(--grad-accent);
  color: #06121d;
  box-shadow: var(--shadow-glow);
}

/* ---------- Калькулятор чистого % (матрица) ---------- */
.calc-rates {
  display: flex;
  align-items: flex-end;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.calc-rate {
  display: grid;
  gap: 7px;
  flex: 1 1 200px;
  color: var(--muted);
  font-size: 12.5px;
  font-weight: 600;
}

.calc-rate input {
  min-height: 56px;
  font-size: 24px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  text-align: center;
  letter-spacing: 0.02em;
  border: 2px solid #2f8bff;
  background: rgba(47, 139, 255, 0.12);
  color: #eaf4ff;
  box-shadow: 0 0 0 1px rgba(47, 139, 255, 0.4), 0 8px 26px rgba(47, 139, 255, 0.25);
}

.calc-rate input::placeholder {
  color: rgba(180, 214, 255, 0.6);
}

.calc-rate input:focus {
  border-color: #4da3ff;
  box-shadow: 0 0 0 4px rgba(47, 139, 255, 0.3), 0 10px 30px rgba(47, 139, 255, 0.35);
}

.calc-arrow {
  padding-bottom: 14px;
  color: var(--accent);
  font-size: 22px;
  font-weight: 800;
}

.calc-clear {
  margin-bottom: 0;
  height: 56px;
  white-space: nowrap;
}

.calc-settings {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  padding: 14px;
  margin-bottom: 16px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--surface);
}

.calc-setting {
  display: grid;
  gap: 6px;
}

.calc-setting span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

/* матрица */
.calc-matrix {
  display: grid;
  gap: 8px;
}

.calc-matrix-row {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) repeat(2, minmax(110px, 1fr));
  gap: 8px;
}

.calc-corner {
  background: transparent;
}

.calc-col-head {
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 2px;
  padding: 10px;
  border-radius: var(--r-sm);
  background: var(--panel-strong);
  color: var(--ink);
  font-weight: 800;
  font-size: 15px;
  text-align: center;
}

.calc-col-head small {
  color: var(--muted);
  font-weight: 600;
  font-size: 11.5px;
}

.calc-row-head {
  display: grid;
  align-content: center;
  gap: 2px;
  padding: 12px 14px;
  border-radius: var(--r-sm);
  color: #fff;
  font-weight: 800;
  font-size: 15px;
}

.calc-row-head small {
  font-weight: 600;
  font-size: 11.5px;
  opacity: 0.85;
}

.calc-row-head.calc-exotic { background: #1e3a8a; }
.calc-row-head.calc-syncra { background: #7c3aed; }

.calc-cell {
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 2px;
  min-height: 64px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--surface);
  font-variant-numeric: tabular-nums;
}

.calc-cell b {
  font-size: 22px;
  font-weight: 800;
}

.calc-cell small {
  font-size: 12px;
  color: var(--muted);
}

.calc-cell.positive b { color: var(--green-dark); }
.calc-cell.negative b { color: var(--red); }
.calc-cell.empty {
  color: var(--faint);
  font-size: 20px;
  font-weight: 700;
}

.calc-spread {
  margin: 14px 0 4px;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 14px;
}
.calc-spread b { font-size: 16px; }
.calc-spread span { color: var(--muted); font-size: 13px; }
.calc-spread.positive b { color: var(--green-dark); }
.calc-spread.negative b { color: var(--red); }


.calc-note {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 13px;
}

@media (max-width: 680px) {
  .calc-matrix-row {
    grid-template-columns: minmax(96px, 1fr) repeat(2, minmax(86px, 1fr));
  }
  .calc-cell b { font-size: 18px; }
  .calc-arrow { display: none; }
}

/* ---------- Экран «Начать смену» ---------- */
.shift-start {
  display: grid;
  justify-items: center;
  gap: 14px;
  text-align: center;
  padding: 48px 24px;
}

.shift-start-icon {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 20px;
  background: var(--soft-blue);
  color: var(--accent);
  font-size: 26px;
}

.shift-start-hint {
  margin: 0;
  max-width: 420px;
  color: var(--faint);
  font-size: 14px;
  line-height: 1.5;
}

.shift-start-btn {
  width: auto;
  padding: 14px 34px;
  font-size: 15px;
}

/* ---------- Карточка активной смены ---------- */
.shift-card {
  display: grid;
  gap: 18px;
}

.shift-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line-strong);
}

.shift-who strong {
  display: block;
  font-size: 17px;
  font-weight: 700;
}

.shift-who span {
  color: var(--faint);
  font-size: 13px;
}

.shift-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: var(--r-pill);
  background: var(--soft-green);
  color: var(--green-dark);
  font-weight: 700;
  font-size: 13px;
}

.shift-status::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--green);
  box-shadow: 0 0 10px var(--green);
  animation: pulse 1.6s var(--ease) infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}

.shift-stage {
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--surface);
}

.shift-stage-head {
  display: flex;
  align-items: center;
  gap: 11px;
}

.shift-stage-head h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
}

.stage-num {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 9px;
  background: var(--grad-accent);
  color: #06121d;
  font-weight: 800;
  font-size: 14px;
  flex-shrink: 0;
}

.stage-time {
  margin-left: auto;
  color: var(--faint);
  font-weight: 600;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.shift-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 14px;
  align-items: end;
}

.proc-field {
  display: grid;
  gap: 7px;
  color: var(--ink-soft);
  font-size: 12.5px;
  font-weight: 600;
}

.stage-stamp-btn {
  justify-self: start;
}

/* ---------- Левые транзакции ---------- */
.tx-bar {
  display: flex;
}

.tx-add-btn {
  width: auto;
  padding: 10px 18px;
}

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

.tx-empty {
  margin: 0;
  color: var(--faint);
  font-size: 13.5px;
  font-weight: 650;
}

.tx-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--panel-solid);
}

.tx-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 11px;
  border-radius: var(--r-pill);
  font-weight: 700;
  font-size: 12.5px;
  white-space: nowrap;
}

.tx-pill.tx-loss { background: var(--soft-danger); color: var(--red); }
.tx-pill.tx-gain { background: var(--soft-green); color: var(--green-dark); }
.tx-pill.tx-out { background: var(--soft-warning); color: var(--amber); }
.tx-pill.tx-uid { background: var(--soft-blue); color: var(--blue-strong); }
.tx-pill.tx-other { background: var(--soft-blue); color: var(--blue-strong); }
.tx-pill.tx-salary { background: var(--soft-green); color: var(--green-dark); }
.tx-pill.tx-transfer { background: var(--soft-blue); color: var(--blue-strong); }

.stock-export-controls {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.stock-export-controls .monitor-filters,
.stock-export-controls .monitor-employees {
  margin-bottom: 0;
}

.stock-export-controls #stockExport {
  align-self: flex-start;
}

/* Окно выдачи кодов со склада */
.issued-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 14px 0;
  max-height: 50vh;
  overflow-y: auto;
}

.issued-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}

.issued-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.issued-name {
  font-size: 12px;
  color: var(--muted);
}

.issued-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 15px;
  font-weight: 600;
  word-break: break-all;
}

.issued-copy {
  flex-shrink: 0;
}

.issued-copy.copied {
  color: var(--green-dark);
  border-color: var(--green-dark);
}

.editing-row {
  background: var(--soft-blue);
}

/* ====== Операция: светлый «лист» (как в прототипе) ====== */
#entryForm.form-panel {
  background: #141927;
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #e8ecf7;
}
#entryForm .eyebrow { color: #8b96ad; }
#entryForm .panel-heading h2 { color: #f4f7ff; }
#entryForm .op-label,
#entryForm .op-grid label { color: #8b96ad; }
#entryForm input,
#entryForm select,
#entryForm textarea {
  background: #1b2130;
  border: 1px solid #2a3346;
  color: #e8ecf7;
}
#entryForm input::placeholder,
#entryForm textarea::placeholder { color: #5d6a83; }
#entryForm input:focus,
#entryForm select:focus,
#entryForm textarea:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59,130,246,.22);
}
#entryForm select {
  appearance: none;
  -webkit-appearance: none;
  background: #1b2130 url("data:image/svg+xml,%3Csvg width='12' height='8' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238b96ad' stroke-width='1.6' fill='none' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right 13px center;
  background-size: 12px 8px;
  padding-right: 34px;
}

/* числовые поля: без стрелок-спиннеров и без серой обводки */
#entryForm input[type="number"]::-webkit-inner-spin-button,
#entryForm input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
#entryForm input[type="number"] { -moz-appearance: textfield; }
#entryForm .op-money > input,
#entryForm .op-hero > input { outline: none; box-shadow: none !important; }
#entryForm .op-money > input:focus,
#entryForm .op-hero > input:focus { outline: none; box-shadow: none !important; }
#entryForm .icon-button {
  background: #1b2130;
  border-color: #2a3346;
  color: #8b96ad;
}

/* вкладки способа */
#entryForm .op-method-tabs { background: #0f131d; border-color: #2a3346; }
#entryForm .op-method-tab { color: #8b96ad; }
#entryForm .op-method-tab:hover { color: #e8ecf7; border-color: transparent; }
#entryForm .op-method-tab.active { background: #3b82f6; color: #fff; box-shadow: 0 6px 16px rgba(59,130,246,.35); }
#entryForm .op-method-tab.op-method-loss.active { background: #e23b4c; box-shadow: 0 6px 16px rgba(226,59,76,.32); }

/* «что продали» */
#entryForm .op-hero { background: rgba(59,130,246,.12); border-color: #3b82f6; }
#entryForm .op-hero .op-label { color: #6ea8ff; }
#entryForm .op-hero > input { background: transparent; border: 0; color: #f4f7ff; }

/* площадки-чипы */
#entryForm .quick-chip { background: #1b2130; border: 1.5px solid #2a3346; color: #e8ecf7; }
#entryForm .quick-chip:hover { border-color: #3b82f6; color: #6ea8ff; }
#entryForm .quick-chip.active { background: #3b82f6; border-color: #3b82f6; color: #fff; }
#entryForm .quick-chip-other { color: #8b96ad; }

/* суммы */
#entryForm .op-money { background: #1b2130; border-color: #2a3346; }
#entryForm .op-money > input { background: transparent; border: 0; }
#entryForm .op-money-hero { background: rgba(22,163,74,.14); border-color: #16a34a; }
#entryForm .op-money-hero .op-label { color: #4ade80; }
#entryForm .op-money-hero > input { color: #4ade80; }
#entryForm .op-money-loss { background: rgba(226,59,76,.12); border-color: #e23b4c; }
#entryForm .op-money-loss .op-label,
#entryForm .op-money-loss > input { color: #f87171; }

/* доп услуги — те же чипы */
#entryForm .operation-extras .extra-chip,
#entryForm .operation-extras button {
  background: #1b2130; border: 1px solid #2a3346; color: #e8ecf7;
}
#entryForm .operation-extras .extra-chip.active,
#entryForm .operation-extras button.active { background: #3b82f6; border-color: #3b82f6; color: #fff; }

/* кнопка добавить — синяя акцентная */
#entryForm > .primary-button { background: #3b82f6; color: #fff; }
#entryForm > .primary-button:hover { background: #2f6fe0; }

/* календарь даты в тёмной форме */
#entryForm .range-trigger { background: #1b2130; border-color: #2a3346; color: #e8ecf7; min-width: 100%; }
#entryForm .range-trigger.has-value { color: #e8ecf7; border-color: #3b82f6; }
.date-picker { display: block; }
.date-picker .range-trigger { width: 100%; }
.range-day.is-sel { background: #1f6fb8; color: #fff; border-radius: 8px; font-weight: 700; }

/* Операция: раскладка форма + живая сводка */
.op-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 18px;
  align-items: start;
}
@media (max-width: 1040px) { .op-layout { grid-template-columns: 1fr; } }

.op-summary { position: sticky; top: 20px; }
.op-summary h3 {
  margin: 0 0 14px;
  font-size: 12px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--muted); font-weight: 600;
}
.op-sum-row {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 11px 0; border-bottom: 1px dashed var(--border);
}
.op-sum-row span { color: var(--muted); font-size: 14px; }
.op-sum-row b { font-variant-numeric: tabular-nums; font-weight: 600; font-size: 15px; }
.op-sum-row.net { border-bottom: 0; border-top: 1px solid var(--line-strong, var(--border)); margin-top: 6px; padding-top: 15px; }
.op-sum-row.net span { color: var(--ink, inherit); }
.op-sum-row.net b { font-size: 26px; }
.op-sum-hint { color: var(--muted); font-size: 12px; margin: 12px 0 0; }

/* Форма операции — вариант 2 */
.op-v2 {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
#opSaleFields,
#opLossFields {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
#opSaleFields[hidden],
#opLossFields[hidden] {
  display: none;
}

.op-label {
  display: block;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin-bottom: 6px;
}

.op-method-tabs {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  align-self: flex-start;
  flex-wrap: wrap;
}
.op-method-tab {
  padding: 9px 20px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  border-radius: 9px;
  cursor: pointer;
}
.op-method-tab:hover { color: inherit; border-color: var(--border); }
.op-method-tab.active {
  background: #1f6fb8;
  color: #fff;
  box-shadow: 0 2px 8px rgba(31, 111, 184, 0.4);
}

.op-hero {
  display: block;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid #1f6fb8;
  background: var(--soft-blue);
}
.op-hero .op-label { color: var(--accent); }
.op-hero > input {
  width: 100%;
  height: 40px;
  font-size: 17px;
  font-weight: 600;
  padding: 0 10px;
  border: none;
  background: transparent;
}
.op-hero > input:focus { outline: none; box-shadow: none; }

.op-platform-block { }
.op-platform-input {
  display: none;
  margin-top: 10px;
  max-width: 320px;
}
.quick-chip-other {
  border-style: dashed;
}

.quick-pick {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.quick-chip {
  padding: 9px 18px;
  border-radius: 999px;
  border: 1.5px solid var(--border);
  background: var(--surface);
  color: inherit;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
}
.quick-chip:hover { border-color: var(--blue-strong); color: var(--blue-strong); }
.quick-chip.active {
  background: #1f6fb8;
  color: #fff;
  border-color: #1f6fb8;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(31, 111, 184, 0.4);
}

.op-money-row {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 14px;
}
.op-money {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px 16px;
}
.op-money > input {
  width: 100%;
  border: none;
  background: transparent;
  padding: 0;
  font-size: 22px;
  font-weight: 600;
}
.op-money > input:focus { outline: none; box-shadow: none; }
.op-money-hero {
  border-color: var(--green-dark, #1f9d57);
  background: var(--soft-green);
}
.op-money-hero .op-label { color: var(--green-dark, #1f9d57); }
.op-money-hero > input { font-size: 28px; color: var(--green-dark, #1f9d57); }

.op-money-loss {
  border-color: var(--red);
  background: var(--soft-danger);
}
.op-money-loss .op-label { color: var(--red); }
.op-money-loss > input { color: var(--red); font-size: 24px; }
.op-loss-platform { display: flex; flex-direction: column; gap: 6px; max-width: 360px; }

.op-comment {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.op-comment > textarea {
  width: 100%;
  min-height: 56px;
  resize: vertical;
  padding: 12px 14px;
  font: inherit;
}

.op-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
}
.op-grid label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}
.op-extras-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.confirm-summary {
  font-weight: 600;
  margin: 4px 0 12px;
}
.confirm-comment {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 12px;
}
.confirm-comment-label {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin-bottom: 4px;
}
.confirm-comment p { margin: 0; white-space: pre-wrap; }
.confirm-comment.empty { color: var(--muted); font-style: italic; }
.confirm-warn { font-size: 13px; color: var(--red); margin: 0 0 8px; }
.danger-button { background: var(--red); border-color: var(--red); }
.confirm-actions { flex-wrap: wrap; }

.entry-details-grid {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 6px 16px;
  margin: 8px 0 14px;
  font-size: 14px;
}
.entry-details-key { color: var(--muted); }
.entry-details-val { text-align: right; }

.journal-toggle-btn {
  display: block;
  width: 100%;
  margin: 8px auto 0;
  padding: 16px;
  font-size: 16px;
  font-weight: 600;
}

.entries-pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 14px;
}
.entries-pager-info {
  font-size: 13px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.entry-code {
  margin-top: 4px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
  color: var(--blue-strong);
  word-break: break-all;
}

/* ВАЖНО: проблемы */
.nav-important span {
  color: var(--red);
  font-weight: 700;
}
.nav-important svg { color: var(--red); }

.nav-badge-red {
  background: var(--red) !important;
  color: #fff !important;
}

.eyebrow.important { color: var(--red); }

.problems-banner {
  display: block;
  padding: 16px 20px;
  margin-bottom: 18px;
  border-radius: 14px;
  border: 1px solid var(--red);
  background: var(--soft-danger);
  color: var(--red);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.01em;
  text-decoration: none;
}

.dashboard-problems:hover { filter: brightness(1.05); }

.problem-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.problem-form .wide { grid-column: 1 / -1; }
.problem-form label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--muted); }
.problem-form input,
.problem-form select,
.problem-form textarea {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: inherit;
  font: inherit;
}
.problem-form > button { grid-column: 1 / -1; justify-self: start; }

.problems-show-resolved {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}

.problems-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.problem-card {
  border: 1px solid var(--border);
  border-left: 4px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  background: var(--surface);
}
.problem-card.ps-refund { border-left-color: var(--red); }
.problem-card.ps-replace { border-left-color: var(--amber); }
.problem-card.ps-fail { border-left-color: var(--blue-strong); }
.problem-card.is-resolved { opacity: 0.6; }

.problem-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.problem-title-wrap { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.problem-title { font-size: 16px; }

.problem-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.problem-pill {
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  background: var(--soft-blue);
  color: var(--blue-strong);
}
.problem-pill.ps-refund { background: var(--soft-danger); color: var(--red); }
.problem-pill.ps-replace { background: var(--soft-warning); color: var(--amber); }
.problem-pill.problem-flag {
  background: var(--red);
  color: #fff;
  letter-spacing: 0.04em;
}
.problem-pill.problem-done { background: var(--soft-green); color: var(--green-dark); }

.problem-meta { margin: 10px 0 0; font-size: 12px; color: var(--muted); }
.problem-info { margin: 8px 0 0; font-size: 14px; white-space: pre-wrap; }

.problem-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
}
.problem-resolve {
  padding: 12px 26px;
  border: none;
  border-radius: 12px;
  background: #12914f;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}
.problem-resolve:hover { filter: brightness(1.08); }
.problem-delete { color: var(--muted); }

.platform-apply {
  display: flex;
  align-items: center;
  gap: 10px;
  grid-column: 1 / -1;
  font-size: 13.5px;
  color: var(--muted);
}
.platform-apply input { width: 18px; height: 18px; }

/* Прайс: счётчик и аккуратная таблица */
.price-count {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: var(--r-pill);
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.price-searchbar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 4px 0 16px;
}
.price-searchbar input {
  flex: 1;
  height: 50px;
  font-size: 16px;
  padding: 0 18px;
  border-radius: 14px;
}
.price-count {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  padding: 10px 16px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.price-table table { min-width: 760px; }
.price-table td { vertical-align: middle; padding-top: 13px; padding-bottom: 13px; }
.price-table tbody tr:nth-child(even) td { background: rgba(255, 255, 255, 0.025); }
.price-table tbody tr:hover td { background: var(--surface); }
.price-table td:first-child { font-weight: 600; }

/* Поиск-выпадашка (searchable select) */
.searchable-select { position: relative; width: 100%; }
.searchable-trigger {
  width: 100%;
  min-height: 42px;
  text-align: left;
  padding: 10px 34px 10px 14px;
  border: 1px solid rgba(148, 163, 216, 0.3);
  border-radius: var(--r-sm);
  background:
    var(--field)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4l4 4 4-4' stroke='%238ccfff' stroke-width='1.6' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E")
    no-repeat right 12px center;
  color: var(--muted);
  font: inherit;
  cursor: pointer;
}
.searchable-trigger.has-value { color: var(--ink); }
.searchable-trigger:hover { border-color: var(--accent); }

.searchable-pop {
  position: absolute;
  z-index: 200;
  top: calc(100% + 6px);
  left: 0; right: 0;
  background: #161b28;
  border: 1px solid rgba(148, 163, 216, 0.22);
  border-radius: 14px;
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.6);
  padding: 10px;
  max-height: 360px;
  display: flex;
  flex-direction: column;
}
.searchable-pop[hidden] { display: none; }
body[data-theme="light"] .searchable-pop { background: #ffffff; }
.searchable-search-row { display: flex; gap: 8px; margin-bottom: 8px; }
.searchable-search {
  flex: 1;
  padding: 10px 12px;
  border: 1px solid rgba(148, 163, 216, 0.22);
  border-radius: 10px;
  background: #1e2433;
  color: var(--ink, inherit);
  font: inherit;
}
body[data-theme="light"] .searchable-search { background: #f1f4fa; }
.searchable-close {
  flex: 0 0 38px;
  border: 1px solid rgba(148, 163, 216, 0.22);
  border-radius: 10px;
  background: #1e2433;
  color: var(--muted);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}
.searchable-close:hover { color: var(--ink, #fff); border-color: var(--accent); }
body[data-theme="light"] .searchable-close { background: #f1f4fa; }
.searchable-item:hover { background: #222a3b; }
.searchable-list { overflow-y: auto; display: flex; flex-direction: column; gap: 2px; }
.searchable-item {
  text-align: left;
  padding: 10px 12px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--ink, inherit);
  font: inherit;
  cursor: pointer;
}
.searchable-item:hover { background: var(--surface); }
.searchable-item.on { background: var(--soft-blue); color: var(--blue-strong); font-weight: 600; }
.searchable-empty { padding: 16px 12px; text-align: center; color: var(--muted); font-size: 13px; }

/* Выбор диапазона дат */
.range-picker {
  position: relative;
  display: inline-block;
}

.range-trigger {
  padding: 8px 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-size: 13px;
  cursor: pointer;
  min-width: 190px;
  text-align: left;
}

.range-trigger.has-value {
  color: inherit;
  border-color: var(--blue-strong);
}

.range-pop {
  position: absolute;
  z-index: 50;
  top: calc(100% + 8px);
  left: 0;
  width: 280px;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--panel, #1b2230);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}

.range-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.range-month {
  font-weight: 600;
  font-size: 14px;
}

.range-nav {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: inherit;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}

.range-nav:hover {
  border-color: var(--blue-strong);
}

.range-week,
.range-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}

.range-week span {
  text-align: center;
  font-size: 11px;
  color: var(--muted);
  padding: 4px 0;
}

.range-day {
  aspect-ratio: 1 / 1;
  border: none;
  background: transparent;
  color: inherit;
  border-radius: 8px;
  font-size: 13px;
  cursor: pointer;
}

.range-day:hover {
  background: var(--surface);
}

.range-day.is-today {
  outline: 1px solid var(--border);
}

.range-day.in-range {
  background: var(--soft-blue);
  border-radius: 0;
}

.range-day.is-start,
.range-day.is-end {
  background: var(--blue-strong);
  color: #fff;
  font-weight: 600;
}

.range-day.is-start { border-radius: 8px 0 0 8px; }
.range-day.is-end { border-radius: 0 8px 8px 0; }

.range-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
}

.range-clear,
.range-done {
  border: none;
  background: transparent;
  color: var(--blue-strong);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  padding: 6px 4px;
}

/* Слежка за сотрудниками */
.monitor-filters,
.monitor-employees {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}

.monitor-filter-label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

.monitor-filter-hint {
  color: var(--muted);
  font-size: 12px;
  font-style: italic;
}

.monitor-filters label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
}

.monitor-filters input[type="date"] {
  padding: 6px 10px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: inherit;
}

.monitor-emp-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 13px;
  cursor: pointer;
}

.monitor-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 8px;
}

.monitor-chip {
  flex: 1 1 130px;
  min-width: 120px;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}

.monitor-chip span {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin-bottom: 4px;
}

.monitor-chip strong {
  font-size: 19px;
  font-variant-numeric: tabular-nums;
}

.monitor-section {
  margin-top: 18px;
}

.monitor-section h3 {
  margin: 0 0 10px;
  font-size: 14px;
}

.monitor-table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
}

.monitor-table th,
.monitor-table td {
  padding: 8px 12px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.monitor-table tbody tr:hover {
  background: var(--surface);
}

.monitor-table th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.monitor-table td:first-child {
  font-weight: 600;
}

.tx-salary-fields {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--soft-green);
}

.tx-salary-fields[hidden] {
  display: none;
}

.salary-requests.has-pending {
  border: 1px solid rgba(70, 211, 154, 0.4);
  border-radius: var(--r);
  padding: 14px;
  background: var(--soft-green);
}

.salary-confirm-btn {
  width: auto;
  padding: 9px 16px;
  font-size: 13px;
  white-space: nowrap;
}

.salary-amount-input {
  min-width: 92px;
  max-width: 120px;
  min-height: 34px;
  padding: 6px 9px;
  font-weight: 700;
  color: var(--green-dark);
}

.nav-badge {
  margin-left: auto;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  display: inline-grid;
  place-items: center;
  border-radius: var(--r-pill);
  background: var(--red);
  color: #fff;
  font-size: 11.5px;
  font-weight: 800;
  line-height: 1;
}

.nav a.active .nav-badge {
  background: rgba(0, 0, 0, 0.28);
}

.tx-amount {
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.tx-meta {
  color: var(--faint);
  font-size: 13px;
  margin-right: auto;
}

.tx-item .delete-button {
  width: 28px;
  height: 28px;
  font-size: 16px;
}

.tx-item-actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
}

.tx-edit-button {
  width: 30px;
  height: 30px;
  display: inline-grid;
  place-items: center;
  flex: none;
  border: 1px solid rgba(91, 140, 255, 0.3);
  border-radius: 8px;
  background: rgba(91, 140, 255, 0.09);
  color: var(--accent-2);
  font-size: 15px;
  font-weight: 800;
}

.tx-edit-button:hover { border-color: var(--accent); background: rgba(91, 140, 255, 0.16); }
.tx-edit-button:disabled { opacity: 0.35; cursor: not-allowed; }

/* ---------- Итог смены ---------- */
.shift-summary {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: end;
  gap: 16px;
}

.shift-comment {
  min-width: 0;
}

.shift-stats {
  display: flex;
  gap: 22px;
}

.shift-stats div {
  display: grid;
  gap: 2px;
}

.shift-stats span {
  color: var(--faint);
  font-size: 12.5px;
}

.shift-stats strong {
  font-size: 22px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.shift-close-btn {
  width: auto;
  padding: 13px 24px;
}

/* ---------- История ---------- */
.processing-history-filters {
  display: grid;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
  padding: 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-md);
  background: var(--surface);
}

.processing-history-filters label {
  display: grid;
  gap: 7px;
  min-width: 0;
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 700;
}

.processing-history-filters input,
.processing-history-filters select {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  padding: 9px 11px;
  background: var(--field);
  color: var(--ink);
  font: inherit;
  font-size: 13px;
}

.processing-filter-search {
  grid-column: span 2;
}

.processing-history-filters .ghost-button {
  align-self: end;
  min-height: 40px;
}

.history-screens {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}

.history-screen-link {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 7px;
  background: var(--soft-blue);
  color: var(--blue-strong);
  font-size: 12px;
  font-weight: 700;
  text-decoration: none !important;
}

.history-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.history-detail-btn {
  min-height: 30px;
  padding: 6px 10px;
  font-size: 12px;
}

.history-reopen {
  width: 30px;
  height: 30px;
  font-size: 16px;
}

/* ---------- Модальное окно ---------- */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(1, 4, 8, 0.68);
  backdrop-filter: blur(8px);
}

.modal {
  width: min(440px, 100%);
  max-height: calc(100dvh - 40px);
  overflow-y: auto;
  overscroll-behavior: contain;
  align-content: start;
  display: grid;
  gap: 16px;
  padding: 24px;
  border: 1px solid rgba(148, 163, 216, 0.3);
  border-radius: var(--r-lg);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0)),
    rgba(20, 25, 34, 0.94);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.045),
    var(--shadow);
}

.modal h3 {
  margin: 0;
  font-size: 19px;
  font-weight: 700;
}

.shift-detail-modal {
  width: min(1040px, 96vw);
  max-height: 92vh;
  overflow: auto;
  align-content: start;
}

.shift-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 4px;
}

.shift-detail-head h3 {
  margin: 3px 0 4px;
  font-size: 24px;
}

.shift-detail-head p {
  margin: 0;
  color: var(--faint);
  font-weight: 600;
}

.shift-detail-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(160px, 1fr));
  gap: 10px;
}

.shift-detail-stat {
  display: grid;
  gap: 5px;
  padding: 13px 14px;
  border: 1px solid rgba(148, 163, 216, 0.24);
  border-radius: var(--r-sm);
  background: rgba(24, 32, 45, 0.72);
}

.shift-detail-stat span {
  color: var(--faint);
  font-size: 12px;
  font-weight: 700;
}

.shift-detail-stat strong {
  font-size: 20px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

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

.shift-detail-section {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid rgba(148, 163, 216, 0.24);
  border-radius: var(--r-sm);
  background: rgba(24, 32, 45, 0.72);
}

.shift-detail-section h4 {
  margin: 0;
  color: var(--ink);
  font-size: 14px;
}

.shift-detail-screens {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.shift-detail-screens a {
  border: 1px solid var(--line-strong);
  border-radius: var(--r-pill);
  padding: 7px 10px;
  background: var(--soft-blue);
  color: var(--blue-strong);
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.shift-detail-tx-list {
  display: grid;
  gap: 10px;
}

.shift-detail-tx {
  display: grid;
  gap: 9px;
  padding: 12px;
  border: 1px solid rgba(148, 163, 216, 0.24);
  border-radius: var(--r-sm);
  background: rgba(15, 20, 28, 0.9);
}

.shift-detail-tx-top {
  display: flex;
  align-items: center;
  gap: 10px;
}

.shift-detail-tx-top strong {
  font-size: 17px;
  font-variant-numeric: tabular-nums;
}

.shift-detail-tx-top span:last-child {
  margin-left: auto;
  color: var(--faint);
  font-size: 12px;
  font-weight: 700;
}

.shift-detail-tx p,
.shift-detail-comment {
  margin: 0;
  color: var(--faint);
  line-height: 1.45;
}

.tx-type-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.tx-type-btn {
  border: 1px solid rgba(148, 163, 216, 0.28);
  border-radius: var(--r-sm);
  padding: 11px 12px;
  background: rgba(24, 32, 45, 0.78);
  color: var(--ink-soft);
  font-weight: 600;
  font-size: 14px;
  transition: border-color 140ms var(--ease), background 140ms var(--ease), color 140ms var(--ease);
}

.tx-type-btn:hover {
  border-color: var(--accent);
}

.tx-type-btn.active {
  border-color: transparent;
  background: var(--grad-accent);
  color: #06121d;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.modal-actions .primary-button,
.modal-actions .ghost-button {
  width: auto;
  padding: 11px 22px;
}

.ghost-button {
  border: 1px solid rgba(148, 163, 216, 0.28);
  border-radius: var(--r-sm);
  padding: 11px 18px;
  background: rgba(24, 32, 45, 0.72);
  color: var(--ink-soft);
  font-weight: 600;
  font-size: 14px;
  transition: border-color 140ms var(--ease), background 140ms var(--ease), color 140ms var(--ease), transform 120ms var(--ease);
}

.ghost-button:hover {
  border-color: var(--accent);
  background: var(--soft-blue);
  color: var(--ink);
  transform: translateY(-1px);
}

@media (max-width: 680px) {
  .shift-summary {
    grid-template-columns: 1fr;
  }

  .tx-type-grid {
    grid-template-columns: 1fr;
  }
}

.processing-table {
  min-width: 1700px;
}

.processing-table .table-input {
  min-height: 36px;
  padding: 7px 9px;
  font-size: 13px;
  background: var(--field-strong);
}

.processing-table input[type="date"],
.processing-table input[type="number"] {
  min-width: 94px;
}

.processing-table input[type="text"] {
  min-width: 120px;
}

.processing-table select.table-input {
  min-width: 120px;
}

.processing-image-cell {
  display: flex;
  flex-direction: column;
  gap: 7px;
  min-width: 152px;
}

.processing-image-list {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.processing-image-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 5px 9px;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  background: var(--surface);
  font-size: 12.5px;
}

/* Ссылка занимает всю строку — клик «просмотреть» больше не попадает в крестик. */
.processing-image-item > a {
  flex: 1;
  min-width: 0;
  padding: 6px 2px;
  display: block;
}

.processing-image-item .delete-button {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  font-size: 15px;
}

.processing-image-upload {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 1px dashed var(--line-strong);
  border-radius: 9px;
  padding: 8px 10px;
  background: var(--soft-blue);
  color: var(--blue-strong);
  font-weight: 700;
  font-size: 12px;
  cursor: pointer;
  transition: border-color 160ms var(--ease), background 160ms var(--ease);
}

.processing-image-upload:hover {
  border-color: var(--accent);
  background: var(--soft-blue);
}

.processing-image-upload input {
  display: none;
}

.tx-screens {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

.tx-screens a {
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 4px 8px;
  background: var(--soft-blue);
  color: var(--blue-strong);
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
}

.image-viewer-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.78);
}

.image-viewer {
  width: min(1100px, 96vw);
  max-height: 92vh;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-md);
  background: var(--panel);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.image-viewer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line-strong);
}

.image-viewer img {
  display: block;
  max-width: 100%;
  max-height: calc(92vh - 64px);
  margin: auto;
  object-fit: contain;
}

/* ============================================================
   Таблицы
   ============================================================ */
.table-wrap a {
  color: var(--blue-strong);
  font-weight: 700;
  text-decoration: none;
}

.table-wrap a:hover {
  text-decoration: underline;
}

.table-panel {
  overflow: hidden;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid rgba(148, 163, 216, 0.24);
  border-radius: var(--r-sm);
  background: rgba(14, 20, 30, 0.84);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 10px 26px rgba(0, 0, 0, 0.16);
}

table {
  width: 100%;
  min-width: 1220px;
  border-collapse: separate;
  border-spacing: 0;
}

.compact-table table {
  min-width: 1120px;
}

thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: rgba(32, 43, 60, 0.98);
  color: var(--ink-soft);
  text-align: left;
  white-space: nowrap;
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0;
  padding: 13px 12px;
  border-bottom: 1px solid var(--line-strong);
}

th:last-child {
  width: 48px;
}

td {
  padding: 12px 12px;
  border-bottom: 1px solid rgba(148, 163, 216, 0.14);
  font-size: 14px;
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}

tbody tr {
  transition: background 130ms var(--ease);
}

tbody tr:hover {
  background: var(--soft-blue);
}

tbody tr.payment-fuzzy-row {
  background: var(--soft-blue);
}

tbody tr.payment-missing-row {
  background: var(--soft-warning);
}

tbody tr:last-child td {
  border-bottom: 0;
}

/* ---------- Пилюли и статусы ---------- */
.method-pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  border-radius: var(--r-pill);
  padding: 4px 11px;
  background: var(--soft-blue);
  color: var(--blue-strong);
  font-size: 12.5px;
  font-weight: 700;
}

.method-pill.buy {
  background: var(--soft-warning);
  color: var(--amber);
}

.method-pill.loss {
  background: var(--soft-danger);
  color: var(--red);
}

.match-ok {
  color: var(--green-dark);
  font-weight: 700;
}

.match-missing {
  color: var(--amber);
  font-weight: 700;
}

.match-fuzzy {
  color: var(--blue-strong);
  font-weight: 700;
}

.positive {
  color: var(--green-dark);
  font-weight: 700;
}

.negative {
  color: var(--red);
  font-weight: 700;
}

.empty-state {
  margin: 18px 0 4px;
  padding: 28px;
  color: var(--faint);
  text-align: center;
  font-size: 14px;
  font-weight: 650;
}

/* ---------- Графики отчёта ---------- */
.bars {
  display: grid;
  gap: 14px;
  margin-top: 20px;
}

.bars div {
  display: grid;
  gap: 8px;
}

.bars span {
  color: var(--faint);
  font-size: 13px;
  font-weight: 600;
}

.bars i {
  display: block;
  width: 0%;
  height: 11px;
  border-radius: var(--r-pill);
  background: var(--grad-accent);
  transition: width 220ms var(--ease);
}

.bars div:nth-child(2) i {
  background: var(--amber);
}

.bars div:nth-child(3) i {
  background: var(--red);
}

.bars div:nth-child(4) i {
  background: linear-gradient(135deg, var(--green), var(--green-dark));
}

/* ============================================================
   Адаптив
   ============================================================ */
@media (max-width: 1050px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

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

  .sidebar {
    position: static;
    height: auto;
    flex-direction: row;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
  }

  .nav {
    grid-auto-flow: column;
    grid-auto-columns: max-content;
    margin-left: auto;
  }

  .nav-group {
    display: contents;
  }

  .nav-group + .nav-group {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
  }

  .nav-label {
    display: none;
  }

  .nav a span {
    display: none;
  }

  .nav a {
    padding: 11px;
  }

  .sidebar-note {
    width: 100%;
    margin-top: 0;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }

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

  .processing-metrics,
  .payroll-summary,
  .payroll-tools {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .topbar-actions {
    justify-content: flex-start;
  }
  .price-form,
  .platform-form,
  .employee-form,
  .role-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .permission-grid {
    grid-column: 1 / -1;
  }
}

@media (max-width: 680px) {
  main {
    padding: 18px;
  }

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

  .topbar-actions,
  .filters {
    justify-content: stretch;
  }

  .topbar-actions > *,
  .filters > * {
    flex: 1 1 150px;
  }

  .nav {
    grid-auto-flow: row;
    grid-template-columns: repeat(auto-fit, minmax(46px, 1fr));
    width: 100%;
    margin-left: 0;
  }

  .metrics,
  .form-grid,
  .report-grid,
  .payment-summary,
  .price-form,
  .platform-form,
    .employee-form,
  .permission-grid,
  .processing-metrics,
  .payroll-summary,
  .payroll-tools,
  .admin-shift-stats {
    grid-template-columns: 1fr;
  }

  .wide {
    grid-column: auto;
  }
}

/* ================= НОВОЕ: тосты, алерты, графики, аудит, аватары ================= */

/* Тосты */
.toast-wrap {
  position: fixed; right: 18px; bottom: 18px; z-index: 1200;
  display: flex; flex-direction: column; gap: 10px; max-width: min(420px, calc(100vw - 36px));
}
.toast {
  padding: 12px 16px; border-radius: 12px; font-size: 14px; line-height: 1.45;
  background: #1c2333; color: #e8ecf7; border: 1px solid rgba(255,255,255,.1);
  box-shadow: 0 12px 30px rgba(0,0,0,.35);
  opacity: 0; transform: translateY(8px); transition: opacity .25s ease, transform .25s ease;
  white-space: pre-line;
}
.toast.show { opacity: 1; transform: translateY(0); }
.toast-ok { border-color: rgba(34,197,94,.5); }
.toast-ok::before { content: "✓ "; color: #4ade80; font-weight: 700; }
.toast-warn { border-color: rgba(245,158,11,.55); }
.toast-warn::before { content: "⚠ "; color: #fbbf24; }

/* Алерты на панели/складе */
.dashboard-alerts { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 14px; }
.dashboard-alerts[hidden] { display: none; }
.alert-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 9px 14px; border-radius: 999px; font-size: 13.5px; font-weight: 600;
  text-decoration: none; border: 1px solid transparent; cursor: pointer;
}
.alert-warn { background: rgba(245,158,11,.12); color: #fbbf24; border-color: rgba(245,158,11,.4); }
.alert-danger { background: rgba(226,59,76,.14); color: #f87171; border-color: rgba(226,59,76,.45); }
a.alert-chip:hover { filter: brightness(1.15); }

/* График «чистые по дням» */
.chart-panel .panel-heading { margin-bottom: 8px; }
.chart-mount { width: 100%; }
.net-chart svg { width: 100%; height: 220px; display: block; }
.net-chart .ch-axis { stroke: rgba(255,255,255,.18); stroke-width: 1; }
.net-chart .ch-rev { fill: rgba(110,168,255,.28); }
.net-chart .ch-net-pos { fill: #22c55e; }
.net-chart .ch-net-neg { fill: #e23b4c; }
.net-chart .ch-label { fill: var(--muted); font-size: 11px; }
.chart-legend { display: flex; gap: 16px; margin-top: 8px; font-size: 12px; color: var(--muted); }
.chart-legend .lg::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.chart-legend .lg-rev::before { background: rgba(110,168,255,.4); }
.chart-legend .lg-net::before { background: #22c55e; }

/* Отчёты: сравнение периодов и топы */
.report-compare { font-size: 13.5px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 4px 0 10px; }
.report-compare[hidden] { display: none; }
.cmp-title { font-weight: 600; }
.cmp-item b { color: inherit; }
.cmp-delta { font-style: normal; font-weight: 700; padding: 1px 7px; border-radius: 999px; font-size: 12px; }
.cmp-up { background: rgba(34,197,94,.15); color: #4ade80; }
.cmp-down { background: rgba(226,59,76,.15); color: #f87171; }
.cmp-flat { background: rgba(255,255,255,.08); color: var(--muted); }
.cmp-item small { color: var(--muted); }

.report-extras { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 22px; margin-top: 22px; }
@media (max-width: 900px) { .report-extras { grid-template-columns: 1fr; } }
.report-extras h3 { margin: 0 0 10px; font-size: 12.5px; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.report-tops { display: flex; flex-direction: column; gap: 18px; }
.top-list { display: flex; flex-direction: column; gap: 6px; }
.top-row {
  position: relative; display: grid; grid-template-columns: minmax(0,1fr) auto auto; gap: 10px;
  align-items: center; padding: 8px 10px; border-radius: 10px; overflow: hidden;
  background: rgba(255,255,255,.03);
}
.top-name { font-weight: 600; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.top-meta { color: var(--muted); font-size: 12.5px; }
.top-net { font-variant-numeric: tabular-nums; font-weight: 700; font-size: 14px; }
.top-bar { position: absolute; left: 0; bottom: 0; height: 3px; background: rgba(110,168,255,.5); border-radius: 2px; }

/* Аудит-лог */
.audit-list { display: flex; flex-direction: column; }
.audit-row {
  display: grid; grid-template-columns: 130px auto auto minmax(0,1fr); gap: 12px;
  align-items: center; padding: 9px 4px; border-bottom: 1px dashed var(--border); font-size: 13.5px;
}
.audit-time { color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.audit-action { font-weight: 600; white-space: nowrap; }
.audit-target { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Аватары сотрудников */
.emp-avatar {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px; border-radius: 50%; flex: 0 0 22px;
  font-size: 11px; font-weight: 800; color: #fff;
  background: hsl(var(--emp-hue, 200) 55% 45%);
}
.emp-cell { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; }

/* Склад: мало/просрочено, настройка порога */
.stock-pill.low { background: rgba(226,59,76,.16); color: #f87171; }
.stock-exp { color: var(--muted); }
.stock-exp.expired { color: #f87171; font-weight: 700; }
.low-stock-setting { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.low-stock-setting input { width: 64px; }
.low-stock-setting[hidden] { display: none; }

/* Слежка: цель за смену */
.monitor-goal { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.monitor-goal input { width: 90px; }
.shift-goal-note { margin: 4px 0 12px; font-size: 14px; font-weight: 600; color: #6ea8ff; }

/* Дедлайн проблемы */
.problem-pill.problem-deadline { background: rgba(245,158,11,.14); color: #fbbf24; }

/* Скелетон при первой синхронизации */
body.syncing .metrics strong,
body.syncing #entriesBody,
body.syncing .stock-groups { opacity: .45; animation: sync-pulse 1.2s ease-in-out infinite; }
@keyframes sync-pulse { 50% { opacity: .25; } }

/* ================= Мобильная адаптация (дополнение к существующей) ================= */
@media (max-width: 760px) {
  .op-layout { grid-template-columns: 1fr; }
  .op-summary { position: static; }
  .table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .table-wrap table { min-width: 640px; }
  .toast-wrap { right: 10px; bottom: 10px; left: 10px; max-width: none; }
  .audit-row { grid-template-columns: 96px minmax(0,1fr); }
  .audit-row .audit-action { grid-column: 2; }
  .audit-row .audit-target { grid-column: 1 / -1; }
  .report-extras { grid-template-columns: 1fr; }
  .price-searchbar input { width: 100%; }
  .dashboard-alerts { gap: 6px; }
  .alert-chip { font-size: 12.5px; padding: 8px 11px; }
  .net-chart svg { height: 170px; }
}

/* ================= Индиго-тема: моноширинный шрифт кодов ================= */
.stock-code, .entry-code, code {
  font-family: "JetBrains Mono", ui-monospace, Menlo, monospace;
}

/* ================= Панель админа: сводка процессинга + ленты ================= */
.dash-feeds { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 18px; }
@media (max-width: 980px) { .dash-feeds { grid-template-columns: 1fr; } }
#dashProc > .panel { margin-top: 18px; }
.dash-proc-note { color: var(--faint); font-size: 12.5px; margin: 12px 0 0; }
.dash-feed { display: flex; flex-direction: column; }
.dash-feed-item {
  display: flex; gap: 11px; align-items: flex-start;
  padding: 10px 2px; border-bottom: 1px dashed var(--line); font-size: 13.5px;
}
.dash-feed-item:last-child { border-bottom: 0; }
.dash-feed-item > div { flex: 1; min-width: 0; }
.dash-feed-time { color: var(--faint); font-size: 12px; white-space: nowrap; font-variant-numeric: tabular-nums; padding-top: 1px; }
.dash-feed-dot { width: 8px; height: 8px; border-radius: 50%; margin-top: 6px; flex: 0 0 8px; }
.dash-feed-dot.dot-g { background: var(--green); }
.dash-feed-dot.dot-b { background: var(--accent); }
.dash-feed-dot.dot-r { background: var(--red); }
.dash-feed-dot.dot-y { background: var(--amber); }
.dash-period-tabs { margin: 0; }

/* Зарплаты: переводы прибыли */
.transfer-arrow { color: var(--faint); font-weight: 700; padding: 0 4px; }

/* Калькулятор: настройки процентов (админ) */
.calc-settings-box {
  background: var(--field);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  padding: 14px 16px;
  margin: 0 0 16px;
}
.calc-settings-box[hidden] { display: none; }
.calc-settings-head {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  flex-wrap: wrap; margin-bottom: 12px; font-size: 12.5px; color: var(--muted);
}
.calc-settings-actions { display: flex; gap: 8px; }
.calc-setting { position: relative; }
.calc-setting-remove { position: absolute; top: -6px; right: -6px; }
.calc-row-head.calc-other { background: linear-gradient(135deg, #0f766e, #14b8a6); color: #fff; }

/* [hidden] должен побеждать display:grid у метрик */
.metrics[hidden] { display: none; }

/* ================= Перенос прототипа: топбар, палитра, быстрая операция, уведомления ================= */

/* Топбар */
.topbar-search {
  display: inline-flex; align-items: center; gap: 9px;
  background: var(--field); border: 1px solid var(--line);
  border-radius: var(--r-sm); padding: 9px 13px;
  color: var(--faint); font-size: 13.5px; cursor: pointer;
  min-width: 220px; transition: border-color .15s;
}
.topbar-search:hover { border-color: var(--accent); color: var(--muted); }
.topbar-search kbd {
  margin-left: auto;
  font: 600 11px/1 "JetBrains Mono", ui-monospace, Menlo, monospace;
  color: var(--muted); background: var(--bg-2);
  border: 1px solid var(--line); border-bottom-width: 2px;
  border-radius: 6px; padding: 3px 6px;
}
.topbar-quick { white-space: nowrap; }
.notif-bell {
  position: relative;
  background: var(--field); border: 1px solid var(--line); border-radius: var(--r-sm);
  color: var(--muted); padding: 9px 12px; cursor: pointer; transition: border-color .15s, color .15s;
}
.notif-bell:hover { border-color: var(--accent); color: var(--ink); }
.notif-bell i {
  position: absolute; top: 6px; right: 7px; width: 8px; height: 8px;
  border-radius: 50%; background: var(--red); box-shadow: 0 0 8px var(--red);
}
.notif-bell i[hidden] { display: none; }

/* Оверлеи: палитра и быстрая операция */
.pal-ov {
  position: fixed; inset: 0; z-index: 1100;
  background: rgba(5, 7, 12, 0.6); backdrop-filter: blur(5px);
  display: flex; align-items: flex-start; justify-content: center; padding-top: 12vh;
}
.pal-ov[hidden] { display: none; }
.pal {
  width: min(590px, 92vw); background: var(--panel-solid);
  border: 1px solid var(--line-strong); border-radius: 18px;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.6); overflow: hidden;
  animation: pal-rise .18s ease;
}
@keyframes pal-rise { from { opacity: 0; transform: translateY(8px); } }
.pal > input {
  width: 100%; border: 0; border-bottom: 1px solid var(--line); border-radius: 0;
  background: transparent; padding: 17px 20px; font-size: 16px; color: var(--ink);
  box-shadow: none !important; outline: none;
}
.pal-list { max-height: 320px; overflow-y: auto; padding: 8px; }
.pal-item {
  width: 100%; display: flex; align-items: center; gap: 12px;
  padding: 11px 13px; border: 0; border-radius: 10px; background: transparent;
  font-size: 14px; color: var(--muted); text-align: left; cursor: pointer;
}
.pal-item i { font-style: normal; width: 20px; text-align: center; }
.pal-item kbd {
  margin-left: auto;
  font: 600 11px/1 "JetBrains Mono", ui-monospace, Menlo, monospace;
  color: var(--muted); background: var(--bg-2);
  border: 1px solid var(--line); border-radius: 6px; padding: 3px 6px;
}
.pal-item:hover, .pal-item.sel { background: var(--soft-blue); color: var(--ink); }
.pal-empty { padding: 18px; text-align: center; color: var(--faint); font-size: 13.5px; }

/* Быстрая операция */
.quickop { padding: 24px; display: flex; flex-direction: column; gap: 14px; }
.quickop h3 { margin: 0; font-size: 17px; color: var(--ink); }
.quickop-hint { margin: 0; color: var(--faint); font-size: 13px; }
.quickop-label { display: flex; flex-direction: column; gap: 6px; font-size: 12px; color: var(--muted); font-weight: 650; text-transform: uppercase; letter-spacing: .05em; }
.quickop-label input, .quickop-label select { width: 100%; }
.quickop #qoName {
  background: var(--soft-blue); border: 1.5px solid var(--accent); border-radius: var(--r-sm);
  padding: 12px 14px; font-size: 16px; font-weight: 650; color: var(--ink);
}
.quickop-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }
.quickop-actions { display: flex; gap: 10px; justify-content: flex-end; }

/* Панель уведомлений */
.notif-drawer {
  position: fixed; top: 0; right: 0; width: min(360px, 92vw); height: 100vh; z-index: 1050;
  background: var(--panel-solid); border-left: 1px solid var(--line-strong);
  padding: 22px; overflow-y: auto;
  box-shadow: -20px 0 60px rgba(0, 0, 0, 0.45);
  animation: drawer-in .2s ease;
}
.notif-drawer[hidden] { display: none; }
@keyframes drawer-in { from { transform: translateX(30px); opacity: 0; } }
.notif-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.notif-head h3 { margin: 0; }
.notif-alerts { flex-direction: column; align-items: stretch; }
.notif-alerts .alert-chip { justify-content: flex-start; border-radius: 12px; }
.notif-sub {
  margin: 18px 0 8px; font-size: 11px; letter-spacing: .12em;
  text-transform: uppercase; color: var(--faint);
}

/* Метрики: дельты и спарклайн */
.metric-hero { position: relative; overflow: hidden; }
.metric-delta { display: block; font-style: normal; font-size: 12px; font-weight: 700; margin-top: 4px; }
.metric-delta.up { color: var(--green); }
.metric-delta.dn { color: var(--red); }
.metric-spark { position: absolute; right: 12px; bottom: 10px; width: 84px; height: 30px; color: var(--accent-2); }

/* Навигация: активный пункт с градиентом как в v3 */
.nav a.active {
  background: linear-gradient(90deg, rgba(91, 140, 255, 0.20), rgba(91, 140, 255, 0.06));
  box-shadow: inset 2px 0 0 var(--accent);
  color: #fff;
}

@media (max-width: 900px) {
  .topbar-search span, .topbar-search kbd { display: none; }
  .topbar-search { min-width: 0; }
}

/* ================= V3-скин: пластика прототипа на основном сайте ================= */

/* Сайдбар компактнее, группы капсом */
.sidebar { padding: 20px 14px; gap: 14px; }
.nav a { font-size: 14px; font-weight: 550; padding: 10px 12px; }
.nav a svg { width: 17px; height: 17px; }
.nav-label {
  font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--faint); font-weight: 700; padding: 0 12px 2px;
}

/* Топбар: компактный заголовок как в v3 */
.topbar { align-items: center; margin-bottom: 22px; }
.topbar h1 { font-size: 20px; font-weight: 750; letter-spacing: -0.01em; }
.topbar .eyebrow { font-size: 10.5px; letter-spacing: 0.14em; color: var(--faint); margin-bottom: 3px; }

/* Панели: гладкий градиент, ровные границы, радиус 16 */
.panel,
.metrics article {
  border-color: var(--line);
  border-radius: 16px;
  background: linear-gradient(180deg, var(--panel-strong), var(--panel-solid));
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.25);
}
.panel-heading h2 { font-size: 16px; font-weight: 700; }
.panel-heading .eyebrow { font-size: 10.5px; letter-spacing: 0.15em; color: var(--accent-2); font-weight: 700; }

/* Метрики: без цветных полосок слева, цифры плотнее */
.metrics article { padding: 17px 18px 15px; }
.metrics article::after { display: none; }
.metrics span { font-size: 12.5px; color: var(--faint); font-weight: 600; }
.metrics strong { margin-top: 6px; font-size: 25px; font-weight: 800; letter-spacing: -0.02em; }
.metrics article.net-card {
  background:
    linear-gradient(135deg, rgba(91, 140, 255, 0.16), rgba(139, 124, 246, 0.09)),
    linear-gradient(180deg, var(--panel-strong), var(--panel-solid));
  border-color: rgba(91, 140, 255, 0.35);
}
.metrics article.net-card strong { color: #fff; }
.metrics article.debt-card { border-color: rgba(251, 111, 132, 0.4); }
.metrics article.debt-card strong { color: var(--red); }

/* Таблицы: тонкие капс-заголовки, мягкий ховер */
thead th {
  background: rgba(19, 24, 40, 0.97);
  color: var(--faint);
  font-size: 11px;
  letter-spacing: 0.1em;
  border-bottom: 1px solid var(--line-strong);
  padding: 10px 12px;
}
td { border-bottom: 1px solid var(--line); }
tbody tr { transition: background 0.1s; }
tbody tr:hover { background: rgba(148, 163, 216, 0.05); }

/* Вкладки-сегменты (процессинг, периоды) */
.proc-tabs {
  display: inline-flex; gap: 4px;
  background: var(--field); border: 1px solid var(--line);
  border-radius: 12px; padding: 4px;
}
.proc-tab {
  border: 0; background: transparent;
  padding: 8px 18px; border-radius: 9px;
  font-size: 13.5px; font-weight: 650; color: var(--faint);
}
.proc-tab:hover { color: var(--ink); background: transparent; }
.proc-tab.active {
  background: var(--accent); color: #fff;
  box-shadow: 0 5px 14px rgba(91, 140, 255, 0.3);
}

/* Кнопки */
.ghost-button {
  border-color: var(--line-strong);
  border-radius: var(--r-sm);
  font-weight: 650;
}
.ghost-button:hover { border-color: var(--accent); color: var(--ink); }
.primary-button {
  border-radius: var(--r-sm);
  font-weight: 650;
  box-shadow: 0 7px 18px rgba(91, 140, 255, 0.35);
}

/* Алерты-чипы: как в v3 */
.alert-chip { font-weight: 650; }

/* Пилюли статусов */
.method-pill, .stock-pill, .problem-pill, .tx-pill {
  font-size: 11.5px; font-weight: 700; border-radius: 999px;
}

/* ================= V3-скин: остальные вкладки ================= */

/* Поля форм — единый вид на всех страницах */
input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),
select,
textarea {
  border-radius: 10px;
}

/* Карточки-компоненты: тот же градиент, что у панелей */
.price-tile,
.payroll-employee-card,
.payroll-tool-card,
.payroll-stat,
.problem-card,
.stock-group,
.shift-card .shift-stage,
.calc-settings-box {
  background: linear-gradient(180deg, var(--panel-strong), var(--panel-solid));
}
.problem-card,
.payroll-tool-card,
.payroll-employee-card,
.price-tile { border-radius: 14px; }

/* Калькулятор: плитки результата с цветной подложкой как в v3 */
.calc-cell.positive {
  background: rgba(52, 211, 153, 0.07);
  border-color: rgba(52, 211, 153, 0.35);
}
.calc-cell.negative {
  background: rgba(251, 111, 132, 0.07);
  border-color: rgba(251, 111, 132, 0.35);
}
.calc-row-head.calc-exotic { background: linear-gradient(135deg, #2848c8, #3b5fe0); }
.calc-row-head.calc-syncra { background: linear-gradient(135deg, #7c3aed, #8b5cf6); }

/* Процессинг: монитор-чипы и tx-пилюли */
.monitor-chip,
.monitor-emp-chip {
  border-radius: 999px;
}

/* Плитки прайса: остатки цветом v3 */
.tile-stock-ok { color: var(--green); font-weight: 700; }
.tile-stock-empty { color: var(--red); font-weight: 700; }

/* Аналитика Авито: выделенные колонки */
.avito-table th.avito-hl { color: var(--accent-2); }

/* Журнал/детализация: тонкая сетка */
.entry-details-grid { gap: 8px 16px; }

/* Топбар: аккуратная строка действий вместо сетки */
.topbar-actions {
  display: flex !important;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  grid-template-columns: none !important;
}
.topbar-actions .profile-switcher {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--faint);
  font-weight: 700;
}
.topbar-actions .profile-switcher select { min-width: 150px; }
.topbar-actions > button,
.topbar-actions .theme-toggle,
.topbar-actions #logoutButton {
  border-radius: var(--r-sm);
}
.topbar-search { order: -1; }

/* Долг: цвет задаётся классом positive/negative по роли, карточка нейтральная */
.metrics article.debt-card { border-color: var(--line); }
.metrics article.debt-card strong { color: inherit; }
.metrics article.debt-card strong.positive,
.payroll-stat strong.positive { color: var(--green); }
.metrics article.debt-card strong.negative,
.payroll-stat strong.negative { color: var(--red); }

/* Чипы-переключатели (подписки в выгрузке склада, сотрудники в слежке):
   чекбокс скрыт, выбор — синяя таблетка */
.monitor-emp-chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 8px 16px;
  border: 1.5px solid var(--line-strong);
  border-radius: 999px;
  background: var(--field);
  color: var(--muted);
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
  user-select: none;
  transition: all 0.13s var(--ease);
  line-height: 1.2;
  white-space: nowrap;
}
.monitor-emp-chip:hover { border-color: var(--accent); color: var(--accent-2); }
.monitor-emp-chip input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  pointer-events: none;
}
.monitor-emp-chip:has(input:checked) {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  box-shadow: 0 5px 14px rgba(91, 140, 255, 0.3);
}

/* График динамики: два показателя + линия с заливкой */
.chart-stats { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 14px; }
.chart-stat {
  flex: 1; min-width: 180px;
  background: var(--field);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 16px;
}
.chart-stat span { display: block; font-size: 12px; color: var(--faint); font-weight: 650; }
.chart-stat b { display: block; margin-top: 4px; font-size: 20px; font-weight: 800; font-variant-numeric: tabular-nums; }
.net-chart .ch-line { fill: none; stroke: var(--green); stroke-width: 2.4; stroke-linejoin: round; stroke-linecap: round; }
.net-chart .ch-area { fill: url(#chFill); }
.net-chart .ch-dot-pos { fill: var(--green); stroke: var(--panel-solid); stroke-width: 1.5; }
.net-chart .ch-dot-neg { fill: var(--red); stroke: var(--panel-solid); stroke-width: 1.5; }
.net-chart svg { height: 190px; }

/* График динамики v3: HTML-оверлеи поверх SVG-линии */
.net-chart2 { width: 100%; }
.ch2-plot { position: relative; width: 100%; height: var(--ch2-h, 230px); }
.ch2-svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.ch2-axis { stroke: rgba(148, 163, 216, 0.18); stroke-width: 1; }
.ch2-line { fill: none; stroke: var(--green); stroke-width: 2.4; stroke-linejoin: round; stroke-linecap: round; }
.ch2-area { fill: url(#chFill2); }
.ch2-dot {
  position: absolute; width: 9px; height: 9px; border-radius: 50%;
  transform: translate(-50%, -50%);
  background: var(--green); border: 2px solid var(--panel-solid);
  box-shadow: 0 0 6px rgba(52, 211, 153, 0.5);
}
.ch2-dot.neg { background: var(--red); box-shadow: 0 0 6px rgba(251, 111, 132, 0.5); }
.ch2-dot.zero { width: 5px; height: 5px; background: var(--faint); border: 0; box-shadow: none; opacity: .6; }
.ch2-val {
  position: absolute; transform: translate(-50%, -100%);
  font-size: 11px; font-weight: 800; font-variant-numeric: tabular-nums;
  color: var(--green); white-space: nowrap;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.7);
}
.ch2-val.neg { color: var(--red); }
.ch2-day {
  position: absolute; bottom: 2px; transform: translateX(-50%);
  font-size: 11px; color: var(--faint); font-variant-numeric: tabular-nums; white-space: nowrap;
}
@media (max-width: 760px) {
  .ch2-val { font-size: 9.5px; }
}

/* Сайдбар v3: без линий-разделителей, плотные группы, аккуратный активный пункт */
.nav { gap: 2px; }
.nav-group { gap: 2px; }
.nav-group + .nav-group {
  margin-top: 14px;
  padding-top: 0;
  border-top: 0;
}
.nav a {
  padding: 9px 12px;
  border-radius: 10px;
  font-weight: 550;
}
.nav a:hover { background: rgba(148, 163, 216, 0.07); color: var(--ink); border-color: transparent; }
.nav a.active {
  background: linear-gradient(90deg, rgba(91, 140, 255, 0.18), rgba(91, 140, 255, 0.05));
  border-color: transparent;
  box-shadow: inset 2px 0 0 var(--accent);
  color: #fff;
}
.nav a svg { opacity: 0.75; }
.nav a.active svg, .nav a:hover svg { opacity: 1; }
.nav-important { color: var(--red); }
.nav-badge {
  min-width: 20px; height: 20px; padding: 0 6px;
  display: inline-grid; place-items: center;
  margin-left: auto;
  border-radius: 999px;
  font-size: 11.5px; font-weight: 800;
  background: var(--accent); color: #fff;
}
.nav-badge-red { background: var(--red); }

/* Топбар: компактное меню «⋯» */
.top-menu-wrap { position: relative; }
.top-menu {
  position: absolute; right: 0; top: calc(100% + 10px); z-index: 80;
  min-width: 240px;
  display: flex; flex-direction: column; gap: 8px;
  background: var(--panel-solid);
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  padding: 12px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}
.top-menu[hidden] { display: none; }
.top-menu > button,
.top-menu .import-button,
.top-menu #exportCsv {
  width: 100%;
  text-align: left;
  justify-content: flex-start;
}
.top-menu #tableActions {
  display: flex !important;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
  padding-top: 10px;
  border-top: 1px dashed var(--line);
}
.top-menu #tableActions[hidden] { display: none !important; }
.profile-switcher { white-space: nowrap; }

/* Профиль: аватар-чип вместо селекта */
.profile-switcher select { display: none; }
.profile-chip {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 6px 15px 6px 7px;
  background: var(--field);
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 650;
  color: var(--ink);
  letter-spacing: normal;
  text-transform: none;
}
.profile-chip .emp-avatar { width: 26px; height: 26px; flex: 0 0 26px; font-size: 12px; }

/* Топбар: кнопка выхода иконкой */
.logout-icon-btn {
  background: var(--field);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  color: var(--muted);
  padding: 9px 12px;
  cursor: pointer;
  transition: border-color .15s, color .15s;
}
.logout-icon-btn:hover { border-color: var(--red); color: var(--red); }

/* Топбар: единая высота и форма всех элементов */
.topbar-actions { gap: 8px; }
.topbar-search,
.notif-bell,
.profile-chip,
.logout-icon-btn {
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--field);
  border: 1px solid var(--line);
  box-sizing: border-box;
}
.topbar-search { padding: 0 14px; justify-content: flex-start; min-width: 210px; }
.notif-bell, .logout-icon-btn { width: 38px; padding: 0; }
.notif-bell svg, .logout-icon-btn svg { display: block; }
.notif-bell i { top: 7px; right: 8px; }
.profile-chip { padding: 0 15px 0 6px; gap: 8px; }

/* Топбар: иконки-кнопки с гарантированной отрисовкой (фон data-URI) */
.notif-bell,
.logout-icon-btn,
.top-menu-btn {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
  background-color: var(--field);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 16px 16px;
  box-shadow: none;
  transition: border-color .15s var(--ease);
}
.notif-bell:hover, .logout-icon-btn:hover, .top-menu-btn:hover { border-color: var(--accent); transform: none; }
.logout-icon-btn:hover { border-color: var(--red); }
.notif-bell {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23aab4d4' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M18 8A6 6 0 0 0 6 8c0 7-3 9-3 9h18s-3-2-3-9'/%3E%3Cpath d='M13.73 21a2 2 0 0 1-3.46 0'/%3E%3C/svg%3E");
}
.logout-icon-btn {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23aab4d4' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4'/%3E%3Cpolyline points='16 17 21 12 16 7'/%3E%3Cline x1='21' y1='12' x2='9' y2='12'/%3E%3C/svg%3E");
}
.top-menu-btn {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23aab4d4'%3E%3Ccircle cx='5' cy='12' r='2'/%3E%3Ccircle cx='12' cy='12' r='2'/%3E%3Ccircle cx='19' cy='12' r='2'/%3E%3C/svg%3E");
}
.top-menu-wrap[hidden] { display: none; }
.top-menu .import-button,
.top-menu #exportCsv { width: 100%; height: 42px; justify-content: flex-start; }

/* Иконки топбара: селекторы сильнее, чем .topbar-actions button */
.topbar-actions .notif-bell,
.topbar-actions .logout-icon-btn,
.topbar-actions .top-menu-btn {
  width: 38px;
  min-width: 38px;
  height: 38px;
  flex: 0 0 38px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 999px;
  background-color: var(--field);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 16px 16px;
  box-shadow: none;
}
.topbar-actions .notif-bell {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23aab4d4' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M18 8A6 6 0 0 0 6 8c0 7-3 9-3 9h18s-3-2-3-9'/%3E%3Cpath d='M13.73 21a2 2 0 0 1-3.46 0'/%3E%3C/svg%3E");
}
.topbar-actions .logout-icon-btn {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23aab4d4' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4'/%3E%3Cpolyline points='16 17 21 12 16 7'/%3E%3Cline x1='21' y1='12' x2='9' y2='12'/%3E%3C/svg%3E");
}
.topbar-actions .top-menu-btn {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23aab4d4'%3E%3Ccircle cx='5' cy='12' r='2'/%3E%3Ccircle cx='12' cy='12' r='2'/%3E%3Ccircle cx='19' cy='12' r='2'/%3E%3C/svg%3E");
}
.topbar-actions .notif-bell:hover,
.topbar-actions .top-menu-btn:hover { border-color: var(--accent); transform: none; }
.topbar-actions .logout-icon-btn:hover { border-color: var(--red); transform: none; }

/* Топбар: профиль в самом правом краю, иконки крупнее и единообразные */
.topbar-actions .profile-switcher { order: 10; }
.topbar-actions .notif-bell,
.topbar-actions .logout-icon-btn,
.topbar-actions .top-menu-btn {
  width: 40px;
  min-width: 40px;
  height: 40px;
  flex: 0 0 40px;
  background-size: 18px 18px;
}
.topbar-actions .profile-chip { height: 40px; }
.topbar-actions .topbar-search { height: 40px; }
.notif-bell i { top: 8px; right: 9px; }

/* ================= Зарплаты v2 (по прототипу) ================= */
.pr-layout { display: grid; grid-template-columns: 300px 1fr; gap: 18px; align-items: start; }
.pr-layout.solo { grid-template-columns: 1fr; }
@media (max-width: 980px) { .pr-layout { grid-template-columns: 1fr; } }
.pr-mut { color: var(--faint); font-size: 12.5px; }
.pr-lbl { font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--faint); font-weight: 700; margin-bottom: 10px; }
.pr-spacer { flex: 1; }

.pr-btn {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 10px 16px; border-radius: 11px; font-weight: 700; font-size: 13.5px;
  border: 1px solid var(--line-strong); color: var(--muted);
  background: transparent; cursor: pointer; transition: all .13s var(--ease);
  white-space: nowrap;
}
.pr-btn:hover { color: var(--ink); border-color: var(--accent); }
.pr-btn-pay { background: linear-gradient(135deg, #22b880, #15966a); border: 0; color: #fff; box-shadow: 0 6px 16px rgba(34,184,128,.3); }
.pr-btn-pay:hover { color: #fff; filter: brightness(1.08); }
.pr-btn-take { border-color: rgba(251,111,132,.5); color: var(--red); }
.pr-btn-take:hover { background: rgba(251,111,132,.1); color: var(--red); border-color: var(--red); }

/* Запрос на вывод */
.pr-request {
  grid-column: 1 / -1;
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  border: 1px solid rgba(251,191,36,.4); background: rgba(251,191,36,.06);
  border-radius: 16px; padding: 13px 18px;
}
.pr-request-info { font-size: 13.5px; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.pr-request-info b { color: var(--amber); }
.pr-request-amount { width: 110px; text-align: center; font-weight: 700; }

/* Список сотрудников */
.pr-emp-list { display: flex; flex-direction: column; gap: 8px; padding: 10px; }
.pr-emp {
  display: grid; grid-template-columns: 40px 1fr auto; gap: 4px 12px; align-items: center;
  text-align: left; padding: 12px 14px; border-radius: 13px;
  border: 1.5px solid transparent; background: transparent; cursor: pointer; transition: all .13s var(--ease);
  color: var(--ink);
}
.pr-emp:hover { background: rgba(148,163,216,.06); }
.pr-emp.on { background: rgba(91,140,255,.10); border-color: var(--accent); }
.pr-emp-ava { grid-row: 1 / 3; width: 40px; height: 40px; flex: 0 0 40px; font-size: 15px; }
.pr-emp b { font-size: 14.5px; }
.pr-emp-debt { font-size: 13px; font-weight: 800; font-variant-numeric: tabular-nums; text-align: right; grid-row: 1 / 3; align-self: center; }
.pr-emp-bar { grid-column: 2 / 3; height: 4px; border-radius: 3px; background: rgba(148,163,216,.13); overflow: hidden; }
.pr-emp-bar i { display: block; height: 100%; border-radius: 3px; background: linear-gradient(90deg, var(--accent), var(--accent-2)); }

/* Кабинет */
.pr-detail { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.pr-hero { display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: center; }
@media (max-width: 760px) { .pr-hero { grid-template-columns: 1fr; } }
.pr-hero-who { display: flex; align-items: center; gap: 14px; }
.pr-hero-ava { width: 52px; height: 52px; flex: 0 0 52px; font-size: 20px; }
.pr-debt-num { font-size: 34px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.pr-hero-actions { display: flex; gap: 9px; flex-wrap: wrap; justify-content: flex-end; }
.pr-substats { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
@media (max-width: 760px) { .pr-substats { grid-template-columns: repeat(2, 1fr); } }
.pr-sub { background: var(--field); border: 1px solid var(--line); border-radius: 12px; padding: 11px 14px; }
.pr-sub span { display: block; font-size: 11.5px; color: var(--faint); font-weight: 650; }
.pr-sub b { display: block; margin-top: 3px; font-size: 16px; font-weight: 800; font-variant-numeric: tabular-nums; }

/* Правка долга одной строкой */
.pr-adjust { display: flex; gap: 9px; align-items: center; flex-wrap: wrap; }
.pr-seg { display: inline-flex; gap: 3px; background: var(--field); border: 1px solid var(--line-strong); border-radius: 11px; padding: 3px; }
.pr-seg button { padding: 8px 16px; border: 0; border-radius: 8px; font-weight: 700; font-size: 13px; color: var(--faint); background: transparent; cursor: pointer; }
.pr-seg button.on-pay { background: #22b880; color: #fff; }
.pr-seg button.on-take { background: var(--red); color: #fff; }
.pr-adj-amount { width: 130px; font-weight: 700; }
.pr-adj-comment { flex: 1; min-width: 180px; }

/* Лента */
.pr-tl-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.pr-tl-head h2 { font-size: 15px; }
.pr-chips { display: flex; gap: 7px; flex-wrap: wrap; }
.pr-chip {
  padding: 7px 14px; border-radius: 999px; font-size: 12.5px; font-weight: 700;
  background: var(--field); border: 1.5px solid var(--line-strong); color: var(--muted);
  cursor: pointer; transition: all .12s var(--ease);
}
.pr-chip:hover { border-color: var(--accent); }
.pr-chip.on { background: var(--accent); border-color: var(--accent); color: #fff; }
.pr-tl { position: relative; padding-left: 26px; }
.pr-tl::before { content: ""; position: absolute; left: 8px; top: 6px; bottom: 6px; width: 2px; background: rgba(148,163,216,.15); border-radius: 2px; }
.pr-ev { position: relative; padding: 10px 0 10px 6px; display: flex; gap: 14px; align-items: baseline; flex-wrap: wrap; }
.pr-ev::before {
  content: ""; position: absolute; left: -24px; top: 16px;
  width: 12px; height: 12px; border-radius: 50%; border: 2.5px solid var(--panel-solid);
}
.pr-ev.pay::before { background: var(--green); box-shadow: 0 0 8px rgba(52,211,153,.5); }
.pr-ev.take::before { background: var(--red); }
.pr-ev.fine::before { background: var(--red); box-shadow: 0 0 8px rgba(251,111,132,.42); }
.pr-ev.tin::before { background: var(--accent); }
.pr-ev.tout::before { background: var(--accent); opacity: .55; }
.pr-ev-when { color: var(--faint); font-size: 12px; font-variant-numeric: tabular-nums; min-width: 108px; }
.pr-ev-what { font-size: 14px; flex: 1; min-width: 200px; }
.pr-ev-what small { display: block; color: var(--faint); font-size: 12px; margin-top: 2px; }
.pr-ev-sum { font-weight: 800; font-variant-numeric: tabular-nums; font-size: 14.5px; }
.pr-tag { font-size: 11px; font-weight: 800; padding: 3px 9px; border-radius: 999px; white-space: nowrap; }
.pr-tag.pay { background: rgba(52,211,153,.13); color: var(--green); }
.pr-tag.take { background: rgba(251,111,132,.13); color: var(--red); }
.pr-tag.fine { background: rgba(251,111,132,.13); color: var(--red); }
.pr-tag.tin { background: rgba(91,140,255,.15); color: var(--accent-2); }
.pr-tag.tout { background: rgba(91,140,255,.09); color: var(--muted); }
.pr-ev-del { align-self: center; }

/* Зарплаты: карточка сотрудника без шкалы, долг крупнее */
.pr-emp { grid-template-columns: 44px 1fr; gap: 0 13px; }
.pr-emp-info { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.pr-emp-info b { font-size: 14px; }
.pr-emp-debt {
  font-size: 17px;
  text-align: left;
  grid-row: auto;
}
.pr-emp-ava { grid-row: 1; width: 44px; height: 44px; flex: 0 0 44px; font-size: 16px; }
.pr-emp-bar { display: none; }

/* Смены сотрудников: карточки с аватаром и длительностью */
.admin-shift-card { border-radius: 14px; }
.admin-shift-head { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; margin-bottom: 4px; }
.admin-shift-head .emp-cell { font-weight: 750; font-size: 15px; }
.admin-shift-head .emp-avatar { width: 28px; height: 28px; flex: 0 0 28px; font-size: 12.5px; }
.shift-pill {
  font-size: 11px; font-weight: 800; padding: 3.5px 10px; border-radius: 999px; white-space: nowrap;
}
.shift-pill.wave { background: rgba(91, 140, 255, 0.14); color: var(--accent-2); }
.shift-pill.dur { background: rgba(52, 211, 153, 0.12); color: var(--green); }
.shift-pill.dur.stale { background: rgba(251, 191, 36, 0.13); color: var(--amber); }
.admin-shift-meta { color: var(--faint); font-size: 12px; }
.proc-feed-panel { margin-top: 18px; }

/* Авито: расходы на объявления в подытоге аккаунта */
.avito-adspend { color: var(--accent-2); font-weight: 700; }

/* Детали смены: разбор чистых и переводы */
.shift-net-breakdown {
  margin: 12px 0 0;
  font-size: 13px;
  color: var(--muted);
  background: var(--field);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 14px;
}
.shift-net-breakdown b { font-variant-numeric: tabular-nums; }
.shift-transfers { display: flex; flex-direction: column; gap: 6px; }
.shift-transfer {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 9px 12px; border-radius: 10px; font-size: 13.5px;
  background: rgba(148, 163, 216, 0.05); border: 1px solid var(--line);
}
.shift-transfer.in { border-left: 3px solid var(--green); }
.shift-transfer.out { border-left: 3px solid var(--red); }
.st-dir { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.st-note { color: var(--faint); }
.st-sum { margin-left: auto; font-weight: 800; font-variant-numeric: tabular-nums; }
.st-when { color: var(--faint); font-size: 12px; font-variant-numeric: tabular-nums; }

/* ================= Процессинг v2: история и левые движения ================= */
.proc-tab-right { margin-left: 0; }

/* История: топбар */
.hist-topbar { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; margin-bottom: 14px; }
.hist-chips { display: inline-flex; gap: 7px; flex-wrap: wrap; }
.hist-emp-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; }
.fcnt {
  display: inline-grid; place-items: center;
  min-width: 17px; height: 17px; margin-left: 5px; padding: 0 4px;
  border-radius: 999px; background: #fff; color: var(--accent);
  font-size: 10.5px; font-weight: 800;
}
.fcnt[hidden] { display: none; }
.hist-more-active { border-color: var(--accent) !important; color: var(--accent-2) !important; }
#histAdvanced[hidden] { display: none; }
#histAdvanced label:has(#processingFilterEmployee),
#histAdvanced label:has(#processingFilterFrom),
#histAdvanced label:has(#processingFilterTo) { display: none; }

/* История: группы по дням */
.hist-groups { display: flex; flex-direction: column; gap: 10px; }
.hist-day-head { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; padding: 8px 6px 0; }
.hist-day-head b { font-size: 14.5px; }
.hist-day-count { color: var(--faint); font-size: 12.5px; }
.hist-day-net { margin-left: auto; font-weight: 800; font-variant-numeric: tabular-nums; }
.hrow {
  display: flex; align-items: center; gap: 13px; flex-wrap: wrap;
  background: linear-gradient(180deg, var(--panel-strong), var(--panel-solid));
  border: 1px solid var(--line); border-radius: 14px; padding: 12px 16px;
}
.hrow .emp-cell { font-weight: 700; min-width: 108px; }
.hrow-time { color: var(--faint); font-size: 12.5px; font-variant-numeric: tabular-nums; }
.hchip {
  font-size: 12px; color: var(--muted); background: var(--field);
  border: 1px solid var(--line); border-radius: 999px; padding: 4px 11px; white-space: nowrap;
}
.hchip.bad { color: var(--red); border-color: rgba(251, 111, 132, 0.35); }
.hrow-note { color: var(--faint); font-size: 12px; flex-basis: 100%; order: 9; padding-left: 4px; }
.hrow-net { margin-left: auto; text-align: right; }
.hrow-net b { display: block; font-size: 17px; font-weight: 800; font-variant-numeric: tabular-nums; }
.hrow-net span { font-size: 11px; color: var(--faint); }
.hrow-actions { display: inline-flex; align-items: center; gap: 6px; }
.hrow-open { padding: 7px 13px; font-size: 12.5px; }

/* Левые движения */
.mov-filters { display: flex; flex-direction: column; gap: 11px; margin-bottom: 16px; }
.mov-frow { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.mov-flabel {
  font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--faint); font-weight: 700; min-width: 86px;
}
.mov-search {
  flex: 0 1 260px;
  min-width: 170px;
  max-width: 280px;
  padding: 8px 13px 8px 32px;
  border-radius: 999px;
  font-size: 13px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7699' stroke-width='2'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 11px center;
  background-size: 13px 13px;
}
.mov-min { border-radius: 999px; font-size: 13px; padding: 8px 13px; }
.mov-min { width: 104px; }
.mov-totals { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.mov-tt { background: var(--field); border: 1px solid var(--line); border-radius: 12px; padding: 10px 16px; }
.mov-tt span { display: block; font-size: 10.5px; color: var(--faint); font-weight: 700; text-transform: uppercase; letter-spacing: 0.07em; }
.mov-tt b { font-size: 17px; font-variant-numeric: tabular-nums; }
.mov-list { display: flex; flex-direction: column; }
.mov-row {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 11px 4px; border-bottom: 1px dashed var(--line); font-size: 13.5px;
}
.mov-row:last-child { border-bottom: 0; }
.mov-when { color: var(--faint); font-size: 12px; min-width: 130px; font-variant-numeric: tabular-nums; }
.mov-row .emp-cell { min-width: 100px; font-weight: 650; }
.mov-note { color: var(--muted); flex: 1; min-width: 160px; }
.mov-shot { color: var(--accent-2); font-size: 12px; text-decoration: none; border: 1px solid var(--line); border-radius: 7px; padding: 3px 8px; }
.mov-shot:hover { border-color: var(--accent); }
.mov-rub { color: var(--faint); font-size: 12px; min-width: 80px; text-align: right; font-variant-numeric: tabular-nums; }
.mov-sum { font-weight: 800; font-variant-numeric: tabular-nums; min-width: 110px; text-align: right; }
.mov-edit-button { margin-left: 2px; }

/* Общая компактная навигация для длинных лент и историй */
.report-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  margin: 16px 0 2px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: color-mix(in srgb, var(--field) 72%, transparent);
}
.report-page-button {
  min-height: 38px;
  padding: 8px 14px;
  border-radius: 10px;
  font-size: 12.5px;
  font-weight: 750;
  white-space: nowrap;
  transition: border-color .15s var(--ease), background .15s var(--ease), color .15s var(--ease), opacity .15s var(--ease);
}
.report-page-button:not(:disabled):hover { border-color: var(--accent); background: rgba(91,140,255,.1); color: var(--accent-2); }
.report-page-button:disabled { opacity: .42; cursor: not-allowed; }
.report-page-status {
  min-width: 190px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  font-variant-numeric: tabular-nums;
}
@media (max-width: 560px) {
  .report-pagination { justify-content: space-between; gap: 6px; padding: 8px; }
  .report-page-button { padding: 8px 10px; font-size: 12px; }
  .report-page-status { min-width: 0; flex: 1; font-size: 11px; }
}

/* Слежка: переводы прибыли */
.monitor-transfer-summary { color: var(--muted); font-size: 13px; margin: 0 0 10px; }
.monitor-transfers { display: flex; flex-direction: column; }
.monitor-transfer {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 10px 4px; border-bottom: 1px dashed var(--line); font-size: 13.5px;
}
.monitor-transfer:last-child { border-bottom: 0; }
.mt-dir { display: inline-flex; align-items: center; gap: 6px; font-weight: 650; min-width: 220px; }

/* История: карточка в две строки */
.hrow.hrow2 { flex-direction: column; align-items: stretch; gap: 9px; }
.hrow-top { display: flex; align-items: center; gap: 13px; flex-wrap: wrap; }
.hrow-spacer { flex: 1; }
.hrow-bottom { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.hrow.hrow2 .hrow-note { flex-basis: auto; order: 0; padding-left: 6px; }
.hrow.hrow2 .hrow-net { margin-left: 0; display: flex; align-items: baseline; gap: 10px; text-align: right; }
.hrow.hrow2 .hrow-net b { font-size: 18px; }

/* Левые движения: мультивыбор типов */
.mov-multi-hint { color: var(--faint); font-size: 12px; font-style: italic; }

/* История: акцентный чип баланса */
.hchip-balance {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  padding: 6px 14px;
  background: var(--field);
  border-color: var(--line-strong);
}
.hchip-balance i {
  font-style: normal;
  font-size: 10.5px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--faint);
  font-weight: 700;
}
.hchip-balance b {
  font-size: 14.5px;
  font-weight: 800;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.hchip-balance b.positive { color: var(--green); }
.hchip-balance b.negative { color: var(--red); }
.hb-arrow { color: var(--faint); font-weight: 700; }

/* Дубли активных смен */
.admin-shift-dup { border-color: rgba(251, 191, 36, 0.5); }
.admin-shift-dup-warn { color: var(--amber); font-size: 12px; margin: 8px 0 0; }
.admin-shift-dup-del { border-color: rgba(251, 111, 132, 0.5); color: var(--red); }
.admin-shift-dup-del:hover { border-color: var(--red); background: rgba(251, 111, 132, 0.08); color: var(--red); }

/* ================= Меню v2 на основном сайте ================= */

/* Минимальное выделение активного пункта */
.nav a.active {
  background: rgba(91, 140, 255, 0.12);
  box-shadow: none;
  color: #fff;
  font-weight: 650;
}
.nav a.active svg { color: var(--accent-2); opacity: 1; }
.nav a.nav-important.active { background: rgba(251, 111, 132, 0.10); color: var(--red); }

/* Кнопка быстрой операции */
.side-quick-op {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  margin: 2px 6px 6px; padding: 10px;
  border: 0; border-radius: 11px; cursor: pointer;
  font-weight: 700; font-size: 13.5px; color: #fff;
  background: linear-gradient(135deg, var(--accent), #4d7dff);
  box-shadow: 0 6px 16px rgba(91, 140, 255, 0.3);
  transition: filter .13s;
}
.side-quick-op:hover { filter: brightness(1.08); }
.side-quick-op[hidden] { display: none; }

/* Кнопка сворачивания */
.brand { position: relative; }
.rail-toggle {
  margin-left: auto; width: 26px; height: 26px; flex: 0 0 26px;
  border: 1px solid transparent; border-radius: 8px; background: transparent;
  display: grid; place-items: center; color: var(--faint); font-size: 12px; cursor: pointer;
}
.rail-toggle:hover { border-color: var(--line-strong); color: var(--ink); }

/* Статус синхронизации внизу меню */
.side-sync {
  margin-top: auto;
  display: flex; align-items: center; gap: 7px;
  padding: 12px 12px 0; font-size: 11.5px; color: var(--faint);
  border-top: 1px solid var(--line);
}
.side-sync i { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px var(--green); flex: 0 0 7px; }
.side-sync.offline i { background: var(--red); box-shadow: 0 0 8px var(--red); }
.side-sync.offline span { color: var(--red); }

/* Живая точка у Процессинга */
.nav-live-dot {
  margin-left: auto; width: 7px; height: 7px; border-radius: 50%;
  background: var(--green); box-shadow: 0 0 8px var(--green); flex: 0 0 7px;
}
.nav a .nav-badge + .nav-live-dot { margin-left: 6px; }

/* ================= Штрафы ================= */
.penalty-rules-panel {
  padding: 22px;
  margin-bottom: 14px;
}

.penalty-rules-panel[hidden],
.penalty-stats[hidden],
.penalty-layout[hidden] { display: none; }

.penalty-heading {
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 18px;
}

.penalty-subtitle {
  margin: 5px 0 0;
  color: var(--faint);
  font-size: 12px;
  line-height: 1.45;
}

.penalty-formula {
  flex: none;
  border: 1px solid rgba(91, 140, 255, 0.35);
  border-radius: 11px;
  padding: 10px 14px;
  background: rgba(91, 140, 255, 0.11);
  color: #cbd7ff;
  font-size: 13px;
  white-space: nowrap;
}

.penalty-settings-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(150px, 1fr)) auto;
  gap: 11px;
  align-items: end;
}

.penalty-settings-form label,
.penalty-warning-modal label {
  display: grid;
  gap: 7px;
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 650;
}

.penalty-settings-form .primary-button {
  width: auto;
  min-height: 43px;
  padding-inline: 18px;
}

.penalty-schedule {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 15px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
  color: var(--faint);
  font-size: 11px;
}

.penalty-schedule strong { color: var(--ink); }

.penalty-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 11px;
  margin-bottom: 14px;
}

.penalty-stats article {
  min-height: 108px;
  padding: 17px 18px;
}

.penalty-stats span,
.penalty-stats small {
  display: block;
  color: var(--faint);
  font-size: 11px;
}

.penalty-stats strong {
  display: block;
  margin: 7px 0 3px;
  color: var(--ink);
  font-size: 25px;
  letter-spacing: -0.03em;
}

.penalty-stats .warning strong { color: var(--amber); }
.penalty-stats .danger strong { color: var(--red); }

.penalty-layout {
  display: grid;
  grid-template-columns: minmax(620px, 1.5fr) minmax(320px, 0.8fr);
  gap: 14px;
  align-items: start;
}

.penalty-people-panel,
.penalty-history-panel { overflow: hidden; }

.penalty-people-panel .panel-heading,
.penalty-history-panel .panel-heading { padding: 17px 18px; }

.penalty-table td { vertical-align: middle; }

.penalty-person {
  display: flex;
  align-items: center;
  gap: 10px;
}

.penalty-avatar {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  flex: none;
  border-radius: 11px;
  background: hsl(var(--penalty-hue, 220) 58% 49%);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
}

.penalty-person strong,
.penalty-person small { display: block; }
.penalty-person small { margin-top: 3px; color: var(--faint); font-size: 10px; }

.penalty-counter { min-width: 170px; }
.penalty-counter-head { display: flex; justify-content: space-between; gap: 10px; margin-bottom: 7px; }
.penalty-counter-head strong { font-size: 13px; }
.penalty-counter-head span { color: var(--faint); font-size: 9px; white-space: nowrap; }
.penalty-progress { height: 7px; overflow: hidden; border-radius: 99px; background: var(--field); }
.penalty-progress i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--accent), var(--amber)); }
.penalty-fine-count { color: var(--red); font-weight: 750; white-space: nowrap; }

.penalty-row-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.penalty-warn-button,
.penalty-remove-button {
  border: 1px solid rgba(246, 184, 84, 0.3);
  border-radius: 9px;
  padding: 8px 11px;
  background: rgba(246, 184, 84, 0.09);
  color: #ffd28b;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.penalty-warn-button:hover { border-color: var(--amber); background: rgba(246, 184, 84, 0.14); }
.penalty-remove-button {
  border-color: rgba(91, 140, 255, 0.28);
  background: rgba(91, 140, 255, 0.08);
  color: #a9c0ff;
}
.penalty-remove-button:hover { border-color: var(--accent-2); background: rgba(91, 140, 255, 0.14); }

.penalty-history {
  max-height: 535px;
  overflow: auto;
  padding: 8px 10px;
}

.penalty-event {
  display: grid;
  grid-template-columns: 31px minmax(0, 1fr);
  gap: 10px;
  padding: 12px 8px;
}

.penalty-event + .penalty-event { border-top: 1px solid var(--line); }
.penalty-event-icon { width: 31px; height: 31px; display: grid; place-items: center; border-radius: 9px; background: rgba(246, 184, 84, 0.1); color: var(--amber); font-weight: 800; }
.penalty-event.fine .penalty-event-icon { background: rgba(251, 111, 132, 0.11); color: var(--red); }
.penalty-event.reset .penalty-event-icon { background: rgba(91, 140, 255, 0.11); color: var(--accent-2); }
.penalty-event.removed .penalty-event-icon { background: rgba(91, 140, 255, 0.11); color: var(--accent-2); }
.penalty-event-title { color: var(--ink); font-size: 11px; font-weight: 750; }
.penalty-event.fine .penalty-event-title { color: #ff9caf; }
.penalty-event p { margin: 4px 0; color: var(--ink-soft); font-size: 10px; line-height: 1.4; }
.penalty-event time { color: var(--faint); font-size: 9px; }
.penalty-event-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.penalty-event-footer button {
  border: 1px solid rgba(91, 140, 255, 0.25);
  border-radius: 7px;
  padding: 5px 8px;
  background: rgba(91, 140, 255, 0.07);
  color: #a9c0ff;
  font-size: 9px;
  font-weight: 700;
}
.penalty-event-footer button:hover { border-color: var(--accent-2); background: rgba(91, 140, 255, 0.13); }
.penalty-empty { padding: 34px 16px; color: var(--faint); text-align: center; font-size: 11px; }

.penalty-warning-modal {
  width: min(480px, 100%);
  max-height: calc(100vh - 32px);
  gap: 18px;
  overflow-y: auto;
}

.penalty-modal-head {
  display: grid;
  gap: 5px;
}

.penalty-modal-head .eyebrow,
.penalty-modal-head h3,
.penalty-modal-head p { margin: 0; }

.penalty-warning-label > span {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.penalty-warning-label small {
  color: var(--faint);
  font-size: 9px;
  font-weight: 600;
}

.penalty-warning-modal textarea {
  width: 100%;
  min-height: 96px;
  padding: 12px 13px;
  resize: vertical;
  line-height: 1.45;
}
.modal-overlay[hidden] { display: none; }
.penalty-modal-employee { margin: 5px 0 0; color: var(--faint); font-size: 12px; }
.penalty-warning-preview { border: 1px solid rgba(246, 184, 84, 0.2); border-radius: 11px; padding: 12px 14px; background: rgba(246, 184, 84, 0.06); color: var(--ink-soft); font-size: 11px; line-height: 1.5; }
.penalty-warning-preview strong { color: #ffd28b; }
.penalty-modal-actions { align-items: stretch; }
.penalty-modal-actions .ghost-button,
.penalty-modal-actions .primary-button { min-height: 43px; }

.penalty-personal-view {
  display: grid;
  grid-template-columns: minmax(560px, 1.35fr) minmax(320px, 0.65fr);
  gap: 14px;
  align-items: start;
}

.penalty-personal-view[hidden] { display: none; }

.penalty-personal-card { padding: 24px; }
.penalty-personal-head { display: flex; align-items: center; gap: 13px; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.penalty-personal-head h2 { font-size: 20px; }
.penalty-personal-head .eyebrow { margin-bottom: 4px; }
.penalty-personal-avatar {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  flex: none;
  border-radius: 16px;
  background: hsl(var(--penalty-hue, 220) 58% 49%);
  color: #fff;
  font-size: 18px;
  font-weight: 800;
}

.penalty-personal-status {
  margin-left: auto;
  border: 1px solid rgba(94, 226, 167, 0.25);
  border-radius: 999px;
  padding: 7px 11px;
  background: rgba(94, 226, 167, 0.08);
  color: var(--green);
  font-size: 11px;
  font-weight: 700;
}

.penalty-personal-status.warning {
  border-color: rgba(246, 184, 84, 0.28);
  background: rgba(246, 184, 84, 0.09);
  color: var(--amber);
}

.penalty-personal-main { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 13px; margin-top: 18px; }
.penalty-personal-counter,
.penalty-personal-rule {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 17px;
  background: rgba(11, 15, 27, 0.2);
}

.penalty-personal-counter > span,
.penalty-personal-rule > span,
.penalty-personal-reset span { color: var(--faint); font-size: 10px; font-weight: 650; }
.penalty-personal-counter > strong { display: block; margin: 9px 0; color: var(--amber); font-size: 34px; line-height: 1; }
.penalty-personal-counter > strong small { color: var(--faint); font-size: 17px; }
.penalty-personal-counter p,
.penalty-personal-rule p,
.penalty-personal-reset p { margin: 8px 0 0; color: var(--ink-soft); font-size: 10px; line-height: 1.45; }
.penalty-personal-progress { height: 8px; overflow: hidden; border-radius: 99px; background: var(--field); }
.penalty-personal-progress i { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--accent), var(--amber)); transition: width 180ms ease; }
.penalty-personal-rule strong { display: block; margin-top: 10px; color: var(--red); font-size: 22px; }

.penalty-personal-reset {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  margin-top: 13px;
  border: 1px solid rgba(91, 140, 255, 0.24);
  border-radius: 13px;
  padding: 14px 16px;
  background: rgba(91, 140, 255, 0.06);
}
.penalty-personal-reset > span { color: var(--accent-2); font-size: 18px; }
.penalty-personal-reset strong { display: block; margin-top: 4px; color: var(--ink); font-size: 13px; }
.penalty-personal-reset p { margin: 0; text-align: right; }
.penalty-personal-history-panel { overflow: hidden; }
.penalty-personal-history-panel .panel-heading { padding: 17px 18px; }

body[data-theme="light"] .penalty-formula { color: #3b5fb6; }
body[data-theme="light"] .penalty-warn-button { color: #9b6200; }
body[data-theme="light"] .penalty-remove-button,
body[data-theme="light"] .penalty-event-footer button { color: #3b5fb6; }

@media (max-width: 1240px) {
  .penalty-settings-form { grid-template-columns: repeat(3, 1fr); }
  .penalty-settings-form .primary-button { grid-column: 1 / -1; justify-self: start; }
  .penalty-layout,
  .penalty-personal-view { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .penalty-heading { display: grid; }
  .penalty-formula { justify-self: start; }
  .penalty-settings-form,
  .penalty-stats { grid-template-columns: 1fr; }
  .penalty-schedule { align-items: flex-start; flex-wrap: wrap; }
  .penalty-personal-main { grid-template-columns: 1fr; }
  .penalty-personal-reset { grid-template-columns: auto 1fr; }
  .penalty-personal-reset p { grid-column: 2; text-align: left; }
  .modal-overlay { padding: 12px; }
  .modal { max-height: calc(100dvh - 24px); }
  .penalty-warning-modal { padding: 20px; gap: 15px; }
  .penalty-modal-actions { display: grid; grid-template-columns: 1fr; }
  .penalty-modal-actions .primary-button,
  .penalty-modal-actions .ghost-button { width: 100%; }
  .penalty-modal-actions .primary-button { grid-row: 1; }
}

/* Свёрнутое меню (rail) */
.app-shell.rail-mode { grid-template-columns: 76px minmax(0, 1fr); }
.sidebar.rail { padding: 16px 10px 12px; }
.sidebar.rail .brand { flex-direction: column; gap: 8px; padding-bottom: 4px; }
.sidebar.rail .brand > div { display: none; }
.sidebar.rail .rail-toggle { margin: 0; }
.sidebar.rail .nav-label { display: none; }
.sidebar.rail .nav a span { display: none; }
.sidebar.rail .nav a { justify-content: center; padding: 11px 0; position: relative; }
.sidebar.rail .nav a svg { margin: 0; }
.sidebar.rail .nav-badge {
  position: absolute; top: 3px; right: 8px;
  min-width: 15px; height: 15px; padding: 0 4px; font-size: 9.5px;
}
.sidebar.rail .nav-live-dot { position: absolute; top: 6px; right: 12px; margin: 0; }
.sidebar.rail .nav-group + .nav-group { border-top: 1px dashed var(--line); margin-top: 8px; padding-top: 8px; }
.sidebar.rail .side-quick-op { width: 44px; height: 44px; padding: 0; margin: 6px auto; border-radius: 13px; }
.sidebar.rail .side-quick-op span { display: none; }
.sidebar.rail .side-sync { justify-content: center; padding: 12px 0 0; }
.sidebar.rail .side-sync span { display: none; }
.sidebar.rail .sidebar-note { display: none; }

/* Числовые поля: глобально без стрелок-спиннеров */
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
  -webkit-appearance: none !important;
  appearance: none !important;
  margin: 0;
  display: none;
}
input[type="number"] {
  -moz-appearance: textfield;
  appearance: textfield;
}

/* Лента зарплат: начисления за смены */
.pr-ev.earn::before { background: var(--accent-2); }
.pr-tag.earn { background: rgba(122, 162, 255, 0.13); color: var(--accent-2); }

/* Свои типы движений */
.mov-add-type { border-style: dashed; color: var(--accent-2); }
.mov-add-type:hover { background: rgba(91, 140, 255, 0.08); }
.mov-del-type { border-style: dashed; color: var(--faint); }
.mov-del-type:hover { border-color: var(--red); color: var(--red); }

/* Смены: компактное рабочее место и отдельное окно истории. */
input[type=number] { -moz-appearance: textfield; appearance: textfield; }
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.shift-v2 {padding:24px;gap:22px;}
.shift-workspace {display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:22px;align-items:start;}
.shift-main,.shift-aside {display:grid;gap:18px;min-width:0;}
.shift-v2 .shift-stage {padding:22px;gap:20px;align-content:start;}
.shift-balance-grid {display:grid;grid-template-columns:1fr 1fr;gap:18px;}
.shift-v2 .table-input {min-width:0;width:100%;box-sizing:border-box;min-height:46px;}
.shift-balance-grid input[type=number] {font-size:21px;}
.shift-balance-grid input[readonly] {font-size:14px;color:var(--muted);}
.shift-end-balance::placeholder {font-size:13px;color:var(--faint);opacity:1;}
.shift-end-balance:placeholder-shown {text-align:center;}
.shift-screens-grid {display:grid;grid-template-columns:1fr 1fr;gap:20px;border-top:1px solid var(--line);padding-top:18px;}
.shift-v2 .processing-image-cell {display:contents;}
.shift-v2 .processing-image-list {display:contents;}
.shift-v2 .shift-screens-grid .proc-field {display:grid;grid-template-columns:repeat(auto-fill,minmax(76px,1fr));align-content:start;gap:8px;}
.shift-v2 .shift-screens-grid .proc-field>span {grid-column:1/-1;margin-bottom:5px;}
.shift-v2 .processing-image-item {position:relative;display:grid;place-items:center;min-width:0;height:76px;padding:0;border-radius:12px;}
.shift-v2 .processing-image-item a {display:grid;place-items:center;width:100%;height:100%;font-size:12px;text-decoration:none;padding:12px 4px 0;box-sizing:border-box;}
.shift-v2 .processing-image-item .image-remove {position:absolute;right:3px;top:2px;width:20px;height:20px;min-height:20px;font-size:13px;border:none;}
.shift-v2 .processing-image-upload {height:76px;min-width:0;box-sizing:border-box;display:flex;align-items:center;justify-content:center;font-size:11px;padding:4px;border-radius:12px;white-space:nowrap;}
.shift-v2 .processing-image-upload input {display:none;}
.shift-result {border:1px solid var(--line-strong);border-radius:18px;padding:22px;background:var(--surface);display:grid;gap:20px;}
.shift-result h3 {margin:0;font-size:17px;}
.shift-net,.shift-mine {display:grid;gap:10px;}
.shift-net {color:var(--muted);font-size:13px;}
.shift-net strong {font-size:20px;font-weight:500;color:var(--ink-soft);}
.shift-mine {border-top:1px solid var(--line);padding-top:20px;font-size:14px;color:var(--muted);}
.shift-mine strong {font-size:32px;line-height:1.2;color:var(--green);font-weight:750;overflow-wrap:anywhere;}
.shift-v2 .shift-close-btn {width:100%;min-height:46px;white-space:normal;}
.shift-v2 textarea {resize:vertical;line-height:1.6;padding:12px;}
.shift-v2 .tx-item {min-width:0;flex-wrap:wrap;}
.shift-detail-modal {width:min(900px,calc(100vw - 32px));max-height:88vh;overflow-y:auto;overscroll-behavior:contain;}
.shift-detail-stat.shift-detail-net strong {font-size:20px;font-weight:500;color:var(--ink-soft);}
.shift-detail-stat.shift-detail-mine strong {font-size:28px;color:var(--green);}
.coverage-panel {display:grid;gap:18px;margin-bottom:18px;padding:24px;}
.coverage-panel h2,.coverage-panel h3,.coverage-panel p {margin:0;}
.coverage-panel>.primary-button,.coverage-panel>.ghost-button {justify-self:start;}
.coverage-panel .table-input {width:100%;min-width:0;box-sizing:border-box;}
.coverage-pending {border:1px solid #b98a39;padding:14px;border-radius:12px;display:grid;gap:10px;}
.coverage-history-row {display:flex;justify-content:space-between;align-items:center;gap:12px;border-top:1px solid var(--line);padding-top:14px;}
.coverage-history-row p,.coverage-notes {font-size:13px;color:var(--muted);line-height:1.6;overflow-wrap:anywhere;}
.coverage-notes:empty {display:none;}
@media(max-width:1150px) {.shift-workspace {grid-template-columns:minmax(0,1fr) 260px;}.shift-v2 {padding:16px;}.shift-v2 .shift-stage,.shift-result {padding:16px;}}
@media(max-width:850px) {.shift-workspace {grid-template-columns:1fr;}.shift-aside {grid-template-columns:1fr 1fr;}.shift-detail-stats {grid-template-columns:repeat(2,minmax(0,1fr));}}
@media(max-width:540px) {.shift-v2 {padding:12px;}.shift-balance-grid,.shift-screens-grid,.shift-aside {grid-template-columns:1fr;}.shift-v2 .shift-stage-head {flex-wrap:wrap;}.shift-v2 .stage-time {margin-left:0;}.coverage-history-row {align-items:start;flex-direction:column;}.shift-detail-modal {padding:18px;}.proc-tabs {flex-wrap:wrap;}}

/* Согласованный макет «Рабочая смена». Изолирован от остальных разделов. */
#processing.processing-design,.shift-design-overlay {
 --sd-bg:#0c1019;--sd-panel:#141b29;--sd-field:#0f1521;--sd-line:#283247;--sd-text:#e8edf7;--sd-muted:#98a6be;--sd-accent:#5e87ff;--sd-green:#56d6ac;--sd-red:#ff7e90;
 color:var(--sd-text);font:14px/1.5 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
 --panel:var(--sd-panel);--panel-solid:var(--sd-panel);--panel-strong:var(--sd-panel);--surface:var(--sd-panel);--field:var(--sd-field);--line:var(--sd-line);--line-strong:var(--sd-line);--muted:var(--sd-muted);--faint:var(--sd-muted);--ink:var(--sd-text);--ink-soft:var(--sd-text);--accent:var(--sd-accent);--green:var(--sd-green);--red:var(--sd-red);
}
body[data-theme="light"] #processing.processing-design,body[data-theme="light"] .shift-design-overlay {--sd-bg:#f3f5f9;--sd-panel:#fff;--sd-field:#f6f8fb;--sd-line:#e1e6ef;--sd-text:#192338;--sd-muted:#606e83;--sd-green:#12845f;--sd-red:#c43a51;}
#processing.processing-design {max-width:1240px;margin-inline:auto;width:100%;}
#processing.processing-design *, .shift-design-overlay * {box-sizing:border-box;}
#processing.processing-design [hidden],.shift-design-overlay [hidden] {display:none!important;}
#processing.processing-design.sd-employee>.processing-metrics {display:none;}
#processing.processing-design :is(h1,h2,h3,p),.shift-design-overlay :is(h1,h2,h3,p) {margin:0;}
#processing.processing-design h1 {font-size:25px;font-weight:600;letter-spacing:-.7px;line-height:1.3;}
#processing.processing-design h2,.shift-design-overlay h2 {font-size:16px;font-weight:600;letter-spacing:0;line-height:1.4;}
#processing.processing-design h3,.shift-design-overlay h3 {font-size:14px;font-weight:600;letter-spacing:0;}
#processing.processing-design .sd-muted,.shift-design-overlay .sd-muted {color:var(--sd-muted);}
#processing.processing-design .sd-eyebrow,.shift-design-overlay .sd-eyebrow {font-size:11px;letter-spacing:1.3px;color:var(--sd-muted);margin-bottom:4px;font-weight:600;}
#processing.processing-design .sd-heading {display:flex;align-items:center;justify-content:space-between;gap:16px;margin:4px 0 22px;}
#processing.processing-design .sd-date {margin-top:5px;text-transform:capitalize;}
#processing.processing-design .sd-heading-status {display:flex;align-items:center;gap:14px;font-size:13px;}
#processing.processing-design .sd-status {color:var(--sd-green);font-size:12px;display:inline-flex;align-items:center;gap:6px;white-space:nowrap;}
#processing.processing-design .sd-status i {width:6px;height:6px;background:currentColor;border-radius:50%;}
#processing.processing-design>.proc-tabs {display:flex;gap:22px;border:0;border-bottom:1px solid var(--sd-line);border-radius:0;background:none;box-shadow:none;padding:0;margin:0 0 22px;width:100%;}
#processing.processing-design>.proc-tabs .proc-tab {display:inline-flex;align-items:center;gap:7px;min-height:39px;padding:0 0 12px;border:0;border-bottom:2px solid transparent;border-radius:0;background:none;box-shadow:none;color:var(--sd-muted);font-size:14px;font-weight:500;transform:none;}
#processing.processing-design>.proc-tabs .proc-tab.active {color:var(--sd-text);border-bottom-color:var(--sd-accent);}
#processing.processing-design .panel,#processing.processing-design .sd-panel {background:var(--sd-panel);border:1px solid var(--sd-line);border-radius:12px;box-shadow:none;backdrop-filter:none;padding:22px;min-width:0;}
#processing.processing-design .panel::before,#processing.processing-design .panel::after {display:none;}
#processing.processing-design .shift-v3 {display:block;background:none;border:0;padding:0;margin:0;box-shadow:none;}
#processing.processing-design .sd-layout {display:grid;grid-template-columns:minmax(0,1.55fr) minmax(260px,1fr);gap:18px;align-items:start;}
#processing.processing-design .sd-stack {display:grid;gap:18px;min-width:0;}
#processing.processing-design .sd-panelhead,.shift-design-overlay .sd-panelhead {display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:18px;flex-wrap:wrap;}
#processing.processing-design .sd-panelhead>svg {width:20px;height:20px;color:var(--sd-muted);flex:none;}
#processing.processing-design :is(.sd-note,.tx-empty),.shift-design-overlay .sd-note {font-size:12px;font-weight:400;line-height:1.5;color:var(--sd-muted);}
#processing.processing-design .sd-note {margin-top:5px;}
#processing.processing-design .sd-button,.shift-design-overlay .sd-button,
#processing.processing-design :is(.ghost-button,.primary-button),.shift-design-overlay :is(.ghost-button,.primary-button) {border:1px solid var(--sd-line);background:var(--sd-panel);color:var(--sd-text);padding:9px 13px;border-radius:9px;display:inline-flex;align-items:center;justify-content:center;gap:7px;white-space:normal;min-height:39px;font:500 14px/1.4 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;box-shadow:none;transform:none;width:auto;cursor:pointer;}
#processing.processing-design .sd-button svg,.shift-design-overlay .sd-button svg {width:16px;height:16px;flex:none;}
#processing.processing-design :is(.sd-primary,.primary-button),.shift-design-overlay :is(.sd-primary,.primary-button) {background:var(--sd-accent);border-color:var(--sd-accent);color:white;}
#processing.processing-design .sd-quiet,.shift-design-overlay .sd-quiet {border-color:transparent;background:transparent;color:var(--sd-muted);}
#processing.processing-design button:hover,.shift-design-overlay button:hover {box-shadow:none;transform:none;filter:brightness(1.08);}
#processing.processing-design button:disabled,.shift-design-overlay button:disabled {opacity:.5;cursor:default;}
#processing.processing-design .sd-full {width:100%;}
#processing.processing-design .sd-transfer {margin-top:14px;}
#processing.processing-design :is(input:not([type=file]),select,textarea),.shift-design-overlay :is(input:not([type=file]),select,textarea) {font:400 14px/1.5 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;border:1px solid var(--sd-line);background:var(--sd-field);color:var(--sd-text);border-radius:8px;padding:10px 11px;width:100%;min-width:0;min-height:42px;box-shadow:none;}
#processing.processing-design .proc-field,.shift-design-overlay .proc-field {display:grid;gap:7px;font-size:12px;font-weight:400;color:var(--sd-muted);}
#processing.processing-design input::placeholder,#processing.processing-design textarea::placeholder,.shift-design-overlay input::placeholder {color:var(--sd-muted);opacity:.7;}
#processing.processing-design textarea {resize:vertical;min-height:65px;}
#processing.processing-design .sd-balancegrid {display:grid;grid-template-columns:1fr 1fr;gap:14px;}
#processing.processing-design .sd-balancegrid input {font-size:22px;letter-spacing:-.4px;padding:13px;font-variant-numeric:tabular-nums;}
#processing.processing-design .sd-balancegrid input::placeholder {font-size:13px;letter-spacing:0;}
#processing.processing-design .shift-end-balance:placeholder-shown {text-align:center;}
#processing.processing-design .sd-fields {margin-top:16px;display:grid;grid-template-columns:1fr 1fr;gap:14px;}
#processing.processing-design .sd-screen-section {margin-top:18px;}
#processing.processing-design .sd-fields+.sd-screen-section {border-top:1px solid var(--sd-line);padding-top:20px;margin-top:20px;}
#processing.processing-design .sd-shot-heading {display:flex;justify-content:space-between;align-items:center;gap:8px;flex-wrap:wrap;}
#processing.processing-design .sd-shot-heading small,#processing.processing-design .sd-shot-count {color:var(--sd-muted);font-size:12px;font-weight:400;}
#processing.processing-design .sd-screen-section .processing-image-cell {display:grid;grid-template-columns:repeat(auto-fill,minmax(76px,1fr));gap:8px;margin-top:10px;align-items:stretch;}
#processing.processing-design .sd-screen-section .processing-image-list {display:contents;}
#processing.processing-design .sd-screen-section .processing-image-item {position:relative;display:block;width:100%;min-width:0;height:76px;border-radius:7px;border:1px solid var(--sd-line);background:var(--sd-field);padding:0;overflow:hidden;}
#processing.processing-design .sd-screen-section .processing-image-item a {display:grid;align-content:space-between;width:100%;height:100%;color:var(--sd-muted);padding:9px 6px;font-size:11px;line-height:1.2;text-align:center;text-decoration:none;}
.sd-shot-document {display:none;}
#processing.processing-design .sd-shot-document {display:block;padding-right:8px;}
#processing.processing-design .sd-shot-document i {display:block;height:3px;background:var(--sd-line);border-radius:2px;margin:3px 0;}
#processing.processing-design .sd-shot-document i:first-child {width:55%;background:var(--sd-accent);}
#processing.processing-design .processing-image-item .image-remove {position:absolute;top:0;right:0;min-height:18px;width:18px;height:18px;padding:0;font-size:12px;color:var(--sd-muted);background:var(--sd-field);border:0;border-radius:4px;box-shadow:none;}
#processing.processing-design .sd-screen-section .processing-image-upload {position:relative;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:6px;min-width:0;width:100%;height:76px;padding:7px;border:1px dashed var(--sd-line);border-radius:7px;background:var(--sd-field);color:var(--sd-muted);font-size:11px;line-height:1.2;font-weight:400;text-align:center;white-space:nowrap;overflow:hidden;cursor:pointer;}
#processing.processing-design .sd-screen-section .processing-image-upload::before {content:'+';font-size:28px;line-height:1;}
#processing.processing-design .sd-screen-section .processing-image-upload input {position:absolute;opacity:0;width:100%;height:100%;inset:0;cursor:pointer;}
#processing.processing-design .sd-summaryrow {display:flex;justify-content:space-between;align-items:center;gap:12px;}
#processing.processing-design .sd-profit {color:var(--sd-muted);font-size:14px;}
#processing.processing-design .sd-share {margin-top:18px;font-weight:500;}
#processing.processing-design .sd-share strong {font-size:25px;font-weight:500;letter-spacing:-.7px;color:var(--sd-green);font-variant-numeric:tabular-nums;}
#processing.processing-design .sd-profit-help {font-size:12px;color:var(--sd-muted);margin-top:20px;padding-top:20px;border-top:1px solid var(--sd-line);}
#processing.processing-design .sd-coverhint {display:flex;gap:12px;align-items:start;margin:15px 0 17px;}
#processing.processing-design .sd-coverhint>svg {color:var(--sd-accent);width:22px;height:22px;flex:none;}
#processing.processing-design .sd-bottom {margin-top:18px;display:flex;gap:18px;align-items:center;justify-content:space-between;background:var(--sd-panel);border:1px solid var(--sd-line);border-radius:12px;padding:16px 20px;flex-wrap:wrap;}
#processing.processing-design .sd-bottom small {display:block;color:var(--sd-muted);font-size:12px;margin-top:3px;}
#processing.processing-design .sd-admin-dates {margin-top:16px;}
#processing.processing-design .sd-admin-dates .proc-field {margin-top:10px;}
#processing.processing-design :is(.shift-v3,.sd-cover-work) .tx-list {display:block;}
#processing.processing-design :is(.shift-v3,.sd-cover-work) .tx-item {display:grid;grid-template-columns:32px minmax(0,1fr) auto auto;column-gap:10px;row-gap:3px;padding:13px 0;border:0;border-bottom:1px solid var(--sd-line);border-radius:0;background:none;align-items:center;box-shadow:none;}
#processing.processing-design :is(.shift-v3,.sd-cover-work) .tx-item:last-child {border-bottom:0;}
#processing.processing-design :is(.shift-v3,.sd-cover-work) .tx-item::before {content:'↗';grid-column:1;grid-row:1 / span 2;width:32px;height:32px;display:grid;place-items:center;background:var(--sd-field);border-radius:9px;color:var(--sd-muted);}
#processing.processing-design :is(.shift-v3,.sd-cover-work) .tx-pill {grid-column:2;grid-row:1;background:none;padding:0;border:0;color:var(--sd-text);font-size:14px;font-weight:500;}
#processing.processing-design :is(.shift-v3,.sd-cover-work) .tx-amount {grid-column:3;grid-row:1 / span 2;font-size:14px;font-weight:500;font-variant-numeric:tabular-nums;white-space:nowrap;}
#processing.processing-design :is(.shift-v3,.sd-cover-work) .tx-meta {grid-column:2;grid-row:2;color:var(--sd-muted);font-size:12px;white-space:normal;overflow-wrap:anywhere;}
#processing.processing-design :is(.shift-v3,.sd-cover-work) .tx-item-actions {grid-column:4;grid-row:1 / span 2;}
#processing.processing-design :is(.shift-v3,.sd-cover-work) .tx-screens {grid-column:2 / -1;grid-row:3;}
#processing.processing-design #processingCoverage {display:grid;gap:18px;}
#processing.processing-design .sd-coverhero {display:flex;align-items:center;justify-content:space-between;gap:18px;flex-wrap:wrap;}
#processing.processing-design .sd-coverhero h2 {font-size:20px;margin-bottom:5px;}
#processing.processing-design .sd-coverhero>div>p:not(.sd-eyebrow) {max-width:470px;color:var(--sd-muted);}
#processing.processing-design .sd-inline-actions {display:flex;align-items:center;gap:8px;flex-wrap:wrap;}
#processing.processing-design .sd-cover-work>.sd-panelhead:first-child {margin-bottom:22px;}
#processing.processing-design .sd-cover-work>.sd-note {margin-top:18px;}
#processing.processing-design .sd-coverage-comment {display:grid;gap:10px;margin-top:18px;}
#processing.processing-design .sd-coverage-comment>.sd-button {justify-self:start;}
#processing.processing-design .sd-cover-empty {padding:20px 0;color:var(--sd-muted);}
#processing.processing-design .sd-cover-empty>svg {width:25px;height:25px;margin-bottom:12px;}
#processing.processing-design .sd-cover-empty h3 {color:var(--sd-text);font-weight:500;margin-bottom:5px;}
#processing.processing-design .sd-coverentry {padding:17px 0;border-bottom:1px solid var(--sd-line);}
#processing.processing-design .sd-coverentry:last-child {border-bottom:0;padding-bottom:0;}
#processing.processing-design .sd-personline {display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin-bottom:7px;}
#processing.processing-design .sd-personline strong {font-weight:500;}
#processing.processing-design .sd-bot>.sd-panelhead {justify-content:flex-start;gap:10px;margin-bottom:8px;}
#processing.processing-design .sd-bot>.sd-panelhead>svg {color:var(--sd-accent);}
#processing.processing-design .sd-telegram {background:#102331;padding:16px;border-radius:11px;margin-top:14px;}
#processing.processing-design .sd-bubble {background:#213a4a;border-radius:11px 11px 11px 2px;padding:13px;font-size:13px;margin-bottom:10px;}
#processing.processing-design .sd-bubble:last-child {margin-bottom:0;}
#processing.processing-design .sd-bubble b {display:block;color:#82c6e7;font-weight:500;margin-bottom:7px;}
#processing.processing-design .sd-bubble small {display:block;text-align:right;color:var(--sd-muted);margin-top:7px;font-size:11px;}
#processing.processing-design .sd-bot>.sd-note {margin-top:10px;}
body[data-theme=light] #processing .sd-telegram {background:#eaf1f7;}
body[data-theme=light] #processing .sd-bubble {background:white;}
body[data-theme=light] #processing .sd-bubble b {color:#287ca4;}
#processing.processing-design .coverage-pending {margin:0;border-radius:12px;font-size:13px;}
/* История: читаемая строка и отдельное окно с прежними данными. */
#processing.processing-design .panel-heading {margin-bottom:18px;}
#processing.processing-design .hist-day-title {font-size:13px;}
#processing.processing-design .hrow {background:none;border:0;border-radius:0;border-bottom:1px solid var(--sd-line);box-shadow:none;padding:18px 0;}
#processing.processing-design .hrow:last-child {border-bottom:0;}
#processing.processing-design .hrow .hchip {border:1px solid var(--sd-line);border-radius:7px;background:none;padding:4px 9px;font-size:12px;font-weight:400;color:var(--sd-muted);}
#processing.processing-design .hrow .hchip b {font-weight:500;color:var(--sd-text);}
#processing.processing-design .hrow .sd-history-share {display:flex;flex-direction:column;align-items:flex-end;gap:2px;}
#processing.processing-design .hrow .sd-history-share span {font-size:12px;color:var(--sd-muted);}
#processing.processing-design .hrow .sd-history-share b {color:var(--sd-green);font-size:17px;font-weight:500;}
#processing.processing-design .hrow-bottom {gap:8px;margin-top:13px;flex-wrap:wrap;}
#processing.processing-design .hrow-note {flex-basis:100%;font-size:12px;color:var(--sd-muted);white-space:normal;margin:3px 0 0;overflow-wrap:anywhere;}
#processing.processing-design .hrow-time,#processing.processing-design .shift-pill {color:var(--sd-muted);font-size:12px;font-weight:400;}
#processing.processing-design .hist-day-sum {color:var(--sd-muted);font-size:12px;font-weight:400;}
.shift-design-overlay {background:#03050ac7;backdrop-filter:blur(4px);padding:24px 16px;}
.shift-design-overlay .shift-design-modal {width:min(450px,calc(100vw - 32px));max-height:88vh;overflow:auto;padding:24px;background:var(--sd-panel);border:1px solid var(--sd-line);border-radius:15px;box-shadow:0 20px 70px #0004;gap:16px;}
.shift-design-overlay .shift-design-modal>h3 {font-size:21px;}
.shift-design-overlay .shift-detail-modal {width:min(820px,calc(100vw - 32px));}
.shift-design-overlay .sd-panelhead>h2 {font-size:21px;}
.shift-design-overlay .tx-type-btn {background:var(--sd-field);color:var(--sd-text);border:1px solid var(--sd-line);border-radius:8px;box-shadow:none;font-size:12px;font-weight:400;}
.shift-design-overlay .tx-type-btn.active {background:var(--sd-accent);color:white;border-color:var(--sd-accent);}
.shift-design-overlay .modal-actions {display:flex;justify-content:flex-end;gap:8px;margin-top:22px;flex-wrap:wrap;}
.shift-design-overlay .shift-detail-stat,.shift-design-overlay .shift-detail-section,.shift-design-overlay .shift-detail-tx,.shift-design-overlay .shift-transfer,.shift-design-overlay .shift-net-breakdown {background:var(--sd-field);border:0;border-radius:9px;box-shadow:none;}
.shift-design-overlay .shift-detail-stat {padding:14px;}
.shift-design-overlay .shift-detail-stat span {font-size:12px;font-weight:400;color:var(--sd-muted);}
.shift-design-overlay .shift-detail-stat strong {font-size:18px;font-weight:500;}
.shift-design-overlay .shift-detail-net strong {font-size:16px;color:var(--sd-muted);}
.shift-design-overlay .shift-detail-mine strong {font-size:25px;color:var(--sd-green);}
.shift-design-overlay .shift-detail-head p {font-size:13px;font-weight:400;color:var(--sd-muted);}
.shift-design-overlay .shift-detail-head h3 {font-size:21px;font-weight:600;}
.shift-design-overlay .shift-detail-screens a {background:var(--sd-field);border:1px solid var(--sd-line);color:var(--sd-muted);border-radius:7px;padding:9px 12px;font-weight:400;font-size:12px;}
.shift-design-overlay .icon-button {background:transparent;border:0;color:var(--sd-muted);box-shadow:none;}
.shift-design-overlay .shift-detail-tx-top strong {font-size:15px;font-weight:500;}
@media(max-width:900px) {
 #processing.processing-design .sd-layout {grid-template-columns:1fr;}
 #processing.processing-design .sd-heading {align-items:flex-start;}
 #processing.processing-design .sd-heading-status {flex-wrap:wrap;justify-content:flex-end;gap:5px 12px;}
 #processing.processing-design .sd-panel {padding:18px;}
}
@media(max-width:540px) {
 #processing.processing-design .sd-heading h1 {font-size:22px;}
 #processing.processing-design>.proc-tabs {gap:18px;flex-wrap:wrap;}
 #processing.processing-design>.proc-tabs .proc-tab {font-size:13px;}
 #processing.processing-design .sd-heading-status {max-width:120px;}
 #processing.processing-design .sd-panelhead {gap:10px;}
 #processing.processing-design .sd-coverhero .sd-inline-actions {width:100%;justify-content:space-between;}
 #processing.processing-design :is(.shift-v3,.sd-cover-work) .tx-item {grid-template-columns:28px minmax(0,1fr) auto;gap:7px;}
 #processing.processing-design :is(.shift-v3,.sd-cover-work) .tx-item-actions {grid-column:3;grid-row:2;}
 #processing.processing-design :is(.shift-v3,.sd-cover-work) .tx-amount {grid-column:3;grid-row:1;font-size:12px;}
 #processing.processing-design .sd-bottom {padding:16px;}
 #processing.processing-design .sd-bottom>.sd-button {width:100%;}
 .shift-design-overlay .shift-design-modal {padding:18px;}
}
@media(max-width:400px) {#processing.processing-design .sd-balancegrid,#processing.processing-design .sd-fields {grid-template-columns:1fr;}}
@media(pointer:coarse) {#processing.processing-design .sd-button,.shift-design-overlay .sd-button {min-height:44px;}#processing.processing-design :is(input,select,textarea),.shift-design-overlay :is(input,select,textarea) {font-size:16px;}}
#processing.processing-design :is(.shift-v3,.sd-cover-work) .tx-pill::before {display:none;}
#processing.processing-design .sd-date {text-transform:none;}
#processing.processing-design .sd-date::first-letter {text-transform:uppercase;}
body[data-page="processing"].sd-employee-view .topbar>div:first-child {display:none;}
body[data-page="processing"].sd-employee-view .topbar {display:flex;justify-content:flex-end;align-items:center;margin-bottom:20px;}
@media(max-width:540px) {
 body[data-page="processing"].sd-employee-view .topbar-actions {display:flex;flex-direction:row;flex-wrap:nowrap;width:100%;gap:8px;}
 body[data-page="processing"].sd-employee-view .topbar-search {min-width:40px;flex:1;padding:0 12px;}
 body[data-page="processing"].sd-employee-view .topbar-actions>button:not(.topbar-search) {flex:none;width:40px;}
}
.shift-design-overlay .shift-detail-stats {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;}
.shift-design-overlay .shift-detail-stats .shift-detail-stat strong {font-size:16px;}
.shift-design-overlay .sd-history-result {display:grid;grid-template-columns:1fr 1fr;gap:18px;align-items:center;padding:18px 0;}
.shift-design-overlay .sd-history-result>div {display:grid;gap:6px;}
.shift-design-overlay .sd-history-result>div:first-child {color:var(--sd-muted);}
.shift-design-overlay .sd-history-result small {font-size:12px;}
.shift-design-overlay .sd-history-result strong {font-size:25px;font-weight:500;letter-spacing:-.7px;color:var(--sd-green);}
.shift-design-overlay .shift-detail-section {background:none;border:0;border-top:1px solid var(--sd-line);padding:18px 0;border-radius:0;}
.shift-design-overlay .shift-detail-screen-grid {padding-top:18px;border-top:1px solid var(--sd-line);gap:18px;}
.shift-design-overlay .shift-detail-screen-grid .shift-detail-section {border:0;padding:0;}
.shift-design-overlay .shift-detail-screens {display:grid;grid-template-columns:repeat(auto-fill,minmax(76px,1fr));gap:8px;}
.shift-design-overlay .shift-detail-screens a {display:grid;align-content:space-between;height:76px;padding:9px 6px;font-size:11px;line-height:1.2;text-align:center;text-decoration:none;}
.shift-design-overlay .shift-detail-screens .sd-shot-document {display:block;}
.shift-design-overlay .sd-shot-document i {display:block;height:3px;background:var(--sd-line);border-radius:2px;margin:3px 0;}
.shift-design-overlay .sd-shot-document i:first-child {width:55%;background:var(--sd-accent);}
.shift-design-overlay .shift-net-breakdown b:first-child {color:var(--sd-muted);font-weight:500;}
@media(max-width:600px) {.shift-design-overlay .shift-detail-stats{grid-template-columns:repeat(2,minmax(0,1fr));}.shift-design-overlay .shift-detail-screen-grid {grid-template-columns:1fr;}}

/* Компактное меню в стиле рабочей смены. */
.sidebar-v2{--sn-bg:#101722;--sn-field:#172131;--sn-line:#263244;--sn-text:#e7edf7;--sn-muted:#9baac1;--sn-accent:#6590ff;--sn-selected:#1c2c49;background:var(--sn-bg);backdrop-filter:none;padding:20px 12px 12px;gap:18px;border-color:var(--sn-line);overflow-y:auto}
[data-theme="light"] .sidebar-v2{--sn-bg:#f5f7fb;--sn-field:#e9edf5;--sn-line:#d6deeb;--sn-text:#1c293f;--sn-muted:#596982;--sn-accent:#3568d6;--sn-selected:#e1eaff}
.sidebar-v2 .brand{gap:11px;padding:0 7px 8px;min-height:48px}
.sidebar-v2 .brand-mark{width:38px;height:38px;flex-shrink:0;border:1px solid var(--sn-line);border-radius:12px;box-shadow:none;background:var(--sn-field)}
.sidebar-v2 .brand strong{font-size:18px;letter-spacing:-.4px;font-weight:600;color:var(--sn-text)}
.sidebar-v2 .brand span:not(.brand-mark){font-size:12px;font-weight:400;color:var(--sn-muted);margin-top:3px}
.sidebar-v2 .rail-toggle{margin-left:auto;border:0;background:transparent;color:var(--sn-muted);box-shadow:none;padding:6px;min-width:30px;min-height:34px}
.sidebar-v2 .nav{gap:0;grid-auto-flow:row;grid-auto-columns:auto;margin:0}
.sidebar-v2 .nav-group{gap:2px}
.sidebar-v2 .nav-group+.nav-group{margin-top:17px;padding-top:0;border-top:0}
.sidebar-v2 .nav-label{display:flex;justify-content:space-between;align-items:center;min-height:27px;padding:0 13px 6px;margin:0;border:0;border-radius:0;background:transparent;box-shadow:none;text-align:left;font-size:11px;letter-spacing:1.3px;color:var(--sn-muted);font-weight:500;cursor:pointer}
.sidebar-v2 .nav-label::after{content:'⌄';font-size:14px}
.sidebar-v2 .nav-label[aria-expanded="false"]::after{content:'›'}
.sidebar-v2:not(.rail) .nav-collapsed>a{display:none}
.sidebar-v2 .nav a{min-height:38px;padding:7px 13px;gap:12px;border:0;border-radius:8px;background:transparent;box-shadow:none;color:var(--sn-muted);font-size:14px;font-weight:400;transform:none}
.sidebar-v2 .nav a svg{width:18px;height:18px;stroke-width:1.7;opacity:.85}
.sidebar-v2 .nav a:hover{background:var(--sn-field);color:var(--sn-text);transform:none}
.sidebar-v2 .nav a.active{background:var(--sn-selected);color:var(--sn-text);box-shadow:none;font-weight:500}
.sidebar-v2 .nav a.active::before{content:'';position:absolute;left:0;top:10px;bottom:10px;width:3px;background:var(--sn-accent);border-radius:3px;box-shadow:none}
.sidebar-v2 .nav a.active svg{color:var(--sn-accent);opacity:1}
.sidebar-v2 .nav a.nav-important{color:#e994a2}
[data-theme="light"] .sidebar-v2 .nav a.nav-important{color:#b23b53}
.sidebar-v2 .nav-live-dot{width:6px;height:6px;box-shadow:none;background:#56d6ac}
.sidebar-v2 .side-sync{margin-top:auto;padding:15px 10px 4px;border-top:1px solid var(--sn-line);color:var(--sn-muted);font-size:11px;min-height:38px}
.sidebar-v2 .side-sync.offline{color:#e994a2}
.sidebar-v2.rail .brand{flex-direction:column;padding:0 0 10px;gap:8px}
.sidebar-v2.rail .rail-toggle{margin:0}
.sidebar-v2.rail .nav-label{display:none}
.sidebar-v2.rail .nav-group+.nav-group{border-top:1px solid var(--sn-line);padding-top:12px;margin-top:12px}
.sidebar-v2.rail .nav a{padding:10px 0;min-height:42px;justify-content:center}
@media(min-width:1051px){.app-shell{grid-template-columns:252px minmax(0,1fr)}.app-shell.rail-mode{grid-template-columns:76px minmax(0,1fr)}}
@media(max-width:1050px){.app-shell,.app-shell.rail-mode{grid-template-columns:minmax(0,1fr)}.sidebar-v2{position:static;height:auto;overflow:visible;flex-direction:column;align-items:stretch;gap:12px}.sidebar-v2 .brand,.sidebar-v2.rail .brand{flex-direction:row;justify-content:flex-start}.sidebar-v2.rail .brand>div{display:block}.sidebar-v2 .nav{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:12px}.sidebar-v2 .nav-group{display:grid;align-content:start}.sidebar-v2 .nav-group+.nav-group{margin:0;padding:0;border:0}.sidebar-v2 .nav a span{display:inline}.sidebar-v2.rail .nav{display:none}.sidebar-v2 .side-sync{margin-top:0}.sidebar-v2.rail .side-sync{padding:8px 10px;justify-content:flex-start}.sidebar-v2.rail .side-sync span{display:inline}.sidebar-v2.rail .rail-toggle{margin-left:auto}}
@media(pointer:coarse){.sidebar-v2 .nav a,.sidebar-v2 .nav-label,.sidebar-v2 .rail-toggle{min-height:44px}}
/* Оповещения: отдельные окна и редактор, без изменений формы смены. */
.notice-admin-panel{background:var(--panel);box-shadow:none}.notice-modal-head{display:flex;justify-content:space-between;align-items:center;gap:16px;flex-wrap:wrap}.notice-modal-head h2{margin:0;font-size:23px}.notice-modal-head p,.notice-help{color:var(--ink-soft);font-size:13px}.notice-actions{display:flex;gap:8px;flex-wrap:wrap;align-items:center}.notice-admin-row{border:1px solid var(--line);border-radius:10px;margin-top:14px;padding:16px;display:flex;gap:16px;justify-content:space-between;flex-wrap:wrap}.notice-admin-row p{font-size:12px;color:var(--ink-soft);margin:6px 0}.notice-admin-row>div:first-child{flex:1;min-width:180px;overflow-wrap:anywhere}.notice-overlay{z-index:1200;overflow:auto;align-items:flex-start;padding:40px 16px}.notice-modal{width:min(640px,100%);max-height:none;margin:auto;background:var(--panel);border:1px solid var(--line);border-radius:16px;padding:26px;overflow-wrap:anywhere}.notice-editor{display:grid;gap:17px;margin-top:22px}.notice-editor label{display:grid;gap:7px;font-size:13px}.notice-editor input,.notice-editor textarea,.notice-editor select{width:100%;min-width:0}.notice-fields{display:grid;grid-template-columns:1fr 1fr;gap:14px}.notice-people{display:flex;gap:15px;flex-wrap:wrap;border:1px solid var(--line);border-radius:8px}.notice-people label{display:flex;align-items:center}.notice-people input{width:auto}.notice-message{display:grid;gap:18px;margin-top:25px}.notice-message h3{font-size:22px;margin:0}.notice-message p{white-space:pre-wrap;line-height:1.7;font-size:16px;margin:0}.notice-message small{color:var(--ink-soft)}.notice-message button{width:100%;margin-top:8px}.notice-journal article{padding:14px 0;border-bottom:1px solid var(--line)}.notice-journal p{font-size:12px;color:var(--ink-soft)}.notice-banner{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 16px;margin-bottom:16px;background:var(--panel);border:1px solid var(--line);border-radius:10px;flex-wrap:wrap}.notice-people[hidden],.notice-banner[hidden]{display:none!important}@media(max-width:540px){.notice-fields{grid-template-columns:1fr}.notice-modal{padding:18px}.notice-overlay{padding:16px 8px}.notice-actions button{min-height:44px}}

/* Штрафы: та же спокойная сетка и поверхности, что у активной смены. */
#penalties {max-width:1240px;width:100%;margin-inline:auto;--panel:#141b29;--panel-solid:#141b29;--field:#0f1521;--line:#283247;--ink:#e8edf7;--muted:#98a6be;color:var(--ink);font-size:14px;}
#penalties [hidden] {display:none!important;}
#penalties .panel {background:var(--panel);border:1px solid var(--line);border-radius:12px;padding:22px;box-shadow:none;backdrop-filter:none;min-width:0;}
#penalties .panel::before,#penalties .panel::after {display:none;}
#penalties h1 {font-size:25px;letter-spacing:-.7px;margin:4px 0 8px;font-weight:600;}
#penalties h2 {font-size:16px;font-weight:600;letter-spacing:0;}
#penalties .eyebrow {font-size:10px;letter-spacing:1.4px;color:var(--muted);}
#penalties .penalty-subtitle {color:var(--muted);font-size:13px;line-height:1.6;}
.penalties-page-head {margin-bottom:22px;}
#fixedPenaltyPanel {margin-bottom:18px;}
.fixed-penalty-recipient {display:grid;gap:8px;max-width:400px;color:var(--muted);font-size:13px;margin:20px 0 12px;}
#penalties :is(input,select) {background:var(--field);border:1px solid var(--line);border-radius:8px;min-height:44px;color:var(--ink);}
.fixed-penalty-grid {display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-top:20px;}
.fixed-penalty-card {background:var(--field);border:1px solid var(--line);border-radius:10px;padding:18px;display:flex;flex-direction:column;gap:18px;min-width:0;}
.fixed-penalty-card h3 {font-size:15px;line-height:1.5;margin:8px 0 0;overflow-wrap:anywhere;}
.fixed-penalty-card>strong {font-size:25px;color:#ff7e90;font-weight:600;margin-top:auto;}
.fixed-penalty-actions {display:flex;gap:8px;align-items:center;flex-wrap:wrap;}
.fixed-penalty-card .fixed-penalty-actions {justify-content:space-between;}
#penalties button {min-height:40px;box-shadow:none;border-radius:8px;font-size:13px;}
.fixed-penalty-apply {border:1px solid #663445;background:#352331;color:#ffb6c0;padding:10px 14px;font-weight:600;}
.fixed-penalty-apply:disabled {opacity:.4;cursor:not-allowed;}
#penalties .penalty-stats {gap:12px;margin:18px 0;}
#penalties .penalty-stats strong {font-size:25px;}
#penalties .penalty-layout {grid-template-columns:minmax(0,1fr);gap:18px;}
#penalties .penalty-history {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;max-height:440px;overflow:auto;}
#penalties .penalty-event {background:var(--field);border:1px solid var(--line);border-radius:10px;margin:0;align-items:start;}
#penalties .penalty-event-title {font-size:13px;line-height:1.5;}
#penalties .penalty-formula {background:var(--field);color:var(--muted);font-size:12px;border:1px solid var(--line);box-shadow:none;}
#penalties .penalty-personal-card {background:var(--panel);}
.fixed-penalty-form {display:grid;gap:18px;}.fixed-penalty-form label {display:grid;gap:8px;}.fixed-penalty-form input {min-height:44px;width:100%;}
body[data-theme="light"] #penalties {--panel:#fff;--panel-solid:#fff;--field:#f6f8fb;--line:#e1e6ef;--ink:#192338;--muted:#606e83;}
@media(max-width:900px){.fixed-penalty-grid {grid-template-columns:repeat(2,minmax(0,1fr));}#penalties .penalty-stats {grid-template-columns:repeat(2,minmax(0,1fr));}}
@media(max-width:600px){#penalties .panel {padding:16px;}#penalties .panel-heading {align-items:start;flex-direction:column;gap:14px;}.fixed-penalty-grid,#penalties .penalty-history {grid-template-columns:1fr;}#penalties button {min-height:44px;}#penalties .penalty-settings-form {grid-template-columns:1fr;}.fixed-penalty-recipient {max-width:none;}}
#penalties .penalty-table {min-width:0;width:100%;table-layout:auto;}
#penalties .penalty-table th,#penalties .penalty-table td {padding:14px 10px;}
#penalties .penalty-counter {min-width:150px;max-width:260px;}
#penalties .penalty-people-panel .panel-heading,#penalties .penalty-history-panel .panel-heading {padding:0;margin-bottom:18px;}
@media(max-width:700px){
 #penalties .penalty-table,#penalties .penalty-table tbody,#penalties .penalty-table tr,#penalties .penalty-table td {display:block;min-width:0;width:100%;}
 #penalties .penalty-table thead {display:none;}
 #penalties .penalty-table tr {padding:12px;border-bottom:1px solid var(--line);}
 #penalties .penalty-table td {padding:8px 0;border:0;}
 #penalties .penalty-table td:nth-child(3)::before {content:'Штрафы за цикл: ';color:var(--muted);}
 #penalties .penalty-row-actions {justify-content:flex-start;}
 #penalties .penalty-counter {max-width:none;}
}

/* Общий фон с сеткой и мягким свечением действует во всех разделах. */
.retired-subscriptions {display:none!important;}
#dashboard .dash-feeds {grid-template-columns:minmax(0,1fr);}

:is(#my-reporting,#extra-calculations){max-width:1240px;margin-inline:auto;width:100%;}:is(#my-reporting,#extra-calculations)>.panel{background:var(--panel);border:1px solid var(--line);border-radius:12px;padding:24px;box-shadow:none;}
.owner-money-toolbar{display:flex;gap:10px;justify-content:flex-end;margin:18px 0;flex-wrap:wrap;}
.owner-money-totals{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin:24px 0;}
.owner-money-totals article,.owner-money-list article{background:var(--field);border:1px solid var(--line);border-radius:12px;padding:20px;min-width:0;}
.owner-money-totals span{color:var(--muted);font-size:12px;}.owner-money-totals strong{display:block;font-size:24px;margin-top:12px;overflow-wrap:anywhere;}
.owner-money-list{display:grid;gap:14px;}.owner-money-head{display:flex;justify-content:space-between;align-items:start;gap:16px;}.owner-money-head h3{margin:0;font-size:17px;overflow-wrap:anywhere;}.owner-money-head strong{font-size:20px;color:var(--green);white-space:nowrap;}
.owner-money-description{white-space:pre-wrap;overflow-wrap:anywhere;color:var(--muted);line-height:1.6;}.owner-money-form{display:grid;gap:18px;}.owner-money-form label{display:grid;gap:8px;}.owner-money-form :is(input,select,textarea){width:100%;min-height:44px;}.owner-money-fields{display:grid;grid-template-columns:2fr 1fr;gap:14px;}.owner-money-error{color:var(--red);font-size:13px;}
@media(max-width:650px){.owner-money-totals{grid-template-columns:1fr;}.owner-money-head{flex-direction:column;}:is(#my-reporting,#extra-calculations)>.panel{padding:16px;}.owner-money-fields{grid-template-columns:1fr;}}
.owner-money-toolbar>.primary-button{width:auto;flex:none;}

/* Owner report uses the active-shift design language. */
:is(#my-reporting,#extra-calculations),[data-owner-money] {--om-panel:#141b29;--om-field:#0f1521;--om-line:#283247;--om-text:#e8edf7;--om-muted:#98a6be;--om-accent:#5e87ff;color:var(--om-text);font:14px/1.5 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;}
:is(#my-reporting,#extra-calculations)>.panel {padding:0;background:none;border:0;box-shadow:none;backdrop-filter:none;}
:is(#my-reporting,#extra-calculations)>.panel::before,:is(#my-reporting,#extra-calculations)>.panel::after {display:none;}
.owner-money-section-head{display:flex;justify-content:space-between;align-items:center;gap:20px;margin-bottom:24px;}
:is(#my-reporting,#extra-calculations) .eyebrow{font-size:10px;letter-spacing:1.4px;color:var(--om-muted);margin:0 0 6px;}
:is(#my-reporting,#extra-calculations) h2{font-size:25px;font-weight:600;letter-spacing:-.7px;margin:0;}
.owner-money-hint{color:var(--om-muted);font-size:13px;margin:8px 0 0;}
.owner-money-section-head .owner-money-toolbar{margin:0;flex-shrink:0;}
:is(#my-reporting,#extra-calculations) button,[data-owner-money] button{min-height:40px;border-radius:8px;box-shadow:none;font-size:13px;font-family:inherit;transform:none;}
:is(#my-reporting,#extra-calculations) .primary-button,[data-owner-money] .primary-button{background:var(--om-accent);border:1px solid var(--om-accent);color:#fff;width:auto;padding:10px 18px;}
:is(#my-reporting,#extra-calculations) .ghost-button,[data-owner-money] .ghost-button{background:transparent;border:1px solid var(--om-line);color:var(--om-text);padding:9px 14px;}
.owner-money-totals{gap:14px;margin:0 0 30px;}
.owner-money-totals article{background:var(--om-panel);border-color:var(--om-line);padding:20px 22px;}
.owner-money-totals span{color:var(--om-muted);font-weight:400;font-size:12px;}
.owner-money-totals strong{font-size:26px;font-weight:600;letter-spacing:-.5px;line-height:1.4;color:var(--om-text);font-variant-numeric:tabular-nums;}
.owner-money-list-title{font-size:13px;color:var(--om-muted);margin:0 0 12px;}
.owner-money-list{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;}
.owner-money-list article{background:var(--om-panel);border-color:var(--om-line);padding:22px;display:flex;flex-direction:column;}
.owner-money-head{flex-direction:column;gap:12px;}
.owner-money-head h3{font-size:16px;font-weight:600;line-height:1.5;}
.owner-money-head strong{font-size:23px;color:var(--om-text);font-weight:600;white-space:normal;overflow-wrap:anywhere;font-variant-numeric:tabular-nums;}
.owner-money-description{font-size:13px;color:var(--om-muted);margin:12px 0 20px;}
.owner-money-list .owner-money-toolbar{border-top:1px solid var(--om-line);padding-top:14px;margin:auto 0 0;}
.owner-money-list .owner-money-toolbar button:last-child{color:#c69aa3;}
.owner-money-empty{grid-column:1/-1;border:1px dashed var(--om-line);border-radius:12px;background:var(--om-panel);padding:42px 22px;text-align:center;}
.owner-money-empty h3{font-size:16px;font-weight:500;margin:0 0 8px;}.owner-money-empty p{color:var(--om-muted);font-size:13px;margin:0 0 20px;}
[data-owner-money] .notice-modal{width:min(520px,calc(100vw - 32px));max-height:calc(100dvh - 40px);overflow:auto;background:var(--om-panel);border:1px solid var(--om-line);border-radius:14px;padding:24px;box-shadow:0 24px 80px #0005;}
[data-owner-money] .notice-modal-head{margin:0 0 24px;gap:16px;}[data-owner-money] .notice-modal-head h2{font-size:20px;line-height:1.35;letter-spacing:-.3px;font-weight:600;margin:0;}
[data-owner-money] .notice-modal-head button{width:36px;min-height:36px;padding:0;flex-shrink:0;}
[data-owner-money] .owner-money-form{gap:18px;}[data-owner-money] label{font-size:13px;color:var(--om-muted);font-weight:400;gap:7px;}
[data-owner-money] :is(input,select,textarea){background:var(--om-field);border:1px solid var(--om-line);border-radius:8px;color:var(--om-text);padding:12px;font:14px/1.5 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;box-shadow:none;min-width:0;}
[data-owner-money] :is(input,select,textarea):focus{outline:2px solid #5e87ff55;outline-offset:1px;border-color:var(--om-accent);}
[data-owner-money] :is(input,textarea)::placeholder{color:#748198;font-size:13px;}
[data-owner-money] textarea{resize:vertical;min-height:96px;}
[data-owner-money] .owner-money-fields{grid-template-columns:minmax(0,1fr) 130px;gap:12px;}
.owner-money-error:empty{display:none;}.owner-money-form-actions{display:flex;justify-content:flex-end;gap:10px;border-top:1px solid var(--om-line);padding-top:18px;margin-top:4px;}
body[data-theme=light] :is(#my-reporting,#extra-calculations),body[data-theme=light] [data-owner-money]{--om-panel:#fff;--om-field:#f6f8fb;--om-line:#e1e6ef;--om-text:#192338;--om-muted:#606e83;}
@media(max-width:700px){.owner-money-section-head{align-items:flex-start;flex-direction:column;gap:16px;}.owner-money-section-head .owner-money-toolbar{width:100%;justify-content:flex-start;}.owner-money-list{grid-template-columns:1fr;}.owner-money-totals{grid-template-columns:1fr;gap:10px;}.owner-money-totals article{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:16px;}.owner-money-totals strong{margin:0;font-size:21px;}:is(#my-reporting,#extra-calculations) button,[data-owner-money] button{min-height:44px;}[data-owner-money] .notice-modal{padding:20px;}[data-owner-money] .notice-modal-head h2{font-size:18px;}.owner-money-form-actions>*{flex:1;} }

/* Personal reporting: approved compact prototype, separate team snapshots. */
.owner-money-list{grid-template-columns:1fr;}
.owner-money-head{flex-direction:row;align-items:center;gap:20px;}
.owner-money-head h3{font-size:15px;font-weight:500;}
.owner-money-head strong{font-size:20px;font-weight:500;}
.owner-money-description{margin:6px 0 0;}
.owner-money-details{min-width:0;flex:1;}
.owner-money-list .owner-money-toolbar{border:0;padding-top:14px;}
#ownerTeamBalances{margin-top:36px;padding-top:28px;border-top:1px solid var(--om-line);}
.owner-team-heading{display:flex;align-items:center;justify-content:space-between;gap:24px;margin-bottom:18px;}
.owner-team-heading h3{font-size:19px;font-weight:500;margin:0;}
.owner-team-total{display:grid;gap:6px;text-align:right;}
.owner-team-total span{font-size:12px;color:var(--om-muted);}
.owner-team-total strong{font-size:24px;font-weight:500;font-variant-numeric:tabular-nums;overflow-wrap:anywhere;}
.owner-team-list{border:1px solid var(--om-line);border-radius:12px;background:var(--om-panel);overflow:hidden;}
.owner-team-row{display:flex;align-items:center;justify-content:space-between;gap:24px;padding:18px 22px;border-bottom:1px solid var(--om-line);}
.owner-team-row:last-child{border:0;}.owner-team-row strong{font-weight:500;font-variant-numeric:tabular-nums;overflow-wrap:anywhere;}.owner-team-row>div{min-width:0;}.owner-team-row>strong{text-align:right;}.owner-team-row p{font-size:12px;color:var(--om-muted);margin:5px 0 0;}
@media(max-width:700px){.owner-money-head{flex-wrap:wrap;}.owner-money-head strong{font-size:20px;}.owner-team-heading{align-items:flex-start;flex-direction:column;gap:18px;}.owner-team-total{text-align:left;}.owner-team-row{gap:14px;padding:16px;flex-wrap:wrap;}.owner-team-row>strong{text-align:left;}}

/* Compact owner overview: team first, storage in two columns. */
#ownerTeamBalances{margin:0 0 24px;padding:0 0 20px;border-top:0;border-bottom:1px solid var(--om-line);}
.owner-money-section-head{margin-bottom:20px;}
.owner-team-heading{margin-bottom:12px;gap:16px;}
.owner-team-heading h3{font-size:16px;}
.owner-team-heading .owner-money-hint{margin-top:4px;font-size:12px;}
.owner-team-total strong{font-size:22px;}
.owner-team-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;background:none;border:0;border-radius:0;overflow:visible;}
.owner-team-row,.owner-team-row:last-child{padding:12px 14px;border:1px solid var(--om-line);border-radius:9px;background:var(--om-panel);gap:12px;min-width:0;}
.owner-team-row p{font-size:11px;margin-top:3px;}
#ownerTeamBalances>.owner-money-hint{font-size:11px;margin-top:10px;}
.owner-money-totals{margin-bottom:20px;gap:10px;}
.owner-money-totals article{padding:14px 16px;}
.owner-money-totals strong{font-size:23px;line-height:1.3;margin-top:6px;}
.owner-money-list{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;align-items:start;}
.owner-money-list article{padding:16px;min-width:0;}
.owner-money-head{gap:12px;align-items:start;}
.owner-money-head strong{font-size:18px;flex-shrink:0;max-width:55%;overflow-wrap:anywhere;}
.owner-money-head h3{font-size:14px;}
.owner-money-description{font-size:12px;line-height:1.5;margin:5px 0 0;}
.owner-money-list .owner-money-toolbar{padding-top:10px;gap:8px;margin:0;}
:is(#my-reporting,#extra-calculations) .owner-money-list .owner-money-toolbar button{min-height:30px;padding:5px 9px;font-size:11px;}
@media(min-width:1600px){.owner-team-list{grid-template-columns:repeat(3,minmax(0,1fr));}}
@media(max-width:800px){.owner-money-list,.owner-team-list{grid-template-columns:1fr;}.owner-team-heading{flex-direction:row;align-items:start;flex-wrap:wrap;}.owner-team-total{text-align:left;}.owner-money-totals article{padding:12px 14px;}.owner-money-totals strong{font-size:21px;margin:0;}.owner-money-head{flex-wrap:nowrap;}.owner-money-head strong{font-size:17px;}}
@media(pointer:coarse){:is(#my-reporting,#extra-calculations) .owner-money-list .owner-money-toolbar button{min-height:44px;}}
.extra-calculation-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;align-items:start;}
.extra-places-section{display:grid;gap:12px;margin:18px 0 22px;padding:17px 19px;border:1px solid var(--om-line);border-radius:13px;background:linear-gradient(115deg,#6b8cff0a,transparent 60%),var(--om-panel);}
.extra-places-head{display:flex;align-items:center;justify-content:space-between;gap:14px;}.extra-places-head h3{margin:0;font-size:14px;font-weight:650;}.extra-places-head p{margin:3px 0 0;color:var(--om-muted);font-size:11px;}
.extra-place-catalog{display:flex;flex-wrap:wrap;gap:8px;align-items:center;}.extra-place-catalog-tag{--place-accent:#6b8cff;display:inline-flex;align-items:center;gap:7px;padding:6px 10px;border:1px solid color-mix(in srgb,var(--place-accent) 30%,var(--om-line));border-radius:999px;background:color-mix(in srgb,var(--place-accent) 9%,var(--om-field));color:var(--om-text);font-size:11px;font-weight:600;}.extra-place-catalog-tag i{width:7px;height:7px;border-radius:50%;background:var(--place-accent);}
.extra-places-empty{color:var(--om-muted);font-size:11px;}.extra-places-main-create{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:9px;align-items:start;padding-top:3px;}.extra-places-main-create input{min-width:0;min-height:40px;background:var(--om-field);border:1px solid var(--om-line);border-radius:8px;padding:9px 12px;color:var(--om-text);font:inherit;}.extra-places-main-create .owner-money-error{grid-column:1/-1;margin:0;}
.extra-calculation-card{padding:0;background:var(--om-panel);border:1px solid var(--om-line);border-radius:15px;min-width:0;overflow:hidden;box-shadow:0 10px 28px #00000012;}
.extra-calculation-card[data-place-color]{border-top:3px solid var(--place-accent,#6b8cff);}
.extra-calculation-card[data-place-color] .extra-calculation-card-head{background:linear-gradient(120deg,color-mix(in srgb,var(--place-accent,#6b8cff) 12%,transparent),transparent 74%);}
.extra-calculation-card[data-place-color=blue],.extra-place-badge[data-place-color=blue],.extra-place-catalog-tag[data-place-color=blue],.extra-place-choice[data-place-color=blue]{--place-accent:#6b8cff}.extra-calculation-card[data-place-color=teal],.extra-place-badge[data-place-color=teal],.extra-place-catalog-tag[data-place-color=teal],.extra-place-choice[data-place-color=teal]{--place-accent:#43cbb0}.extra-calculation-card[data-place-color=violet],.extra-place-badge[data-place-color=violet],.extra-place-catalog-tag[data-place-color=violet],.extra-place-choice[data-place-color=violet]{--place-accent:#ad82ff}.extra-calculation-card[data-place-color=amber],.extra-place-badge[data-place-color=amber],.extra-place-catalog-tag[data-place-color=amber],.extra-place-choice[data-place-color=amber]{--place-accent:#e8ae53}.extra-calculation-card[data-place-color=rose],.extra-place-badge[data-place-color=rose],.extra-place-catalog-tag[data-place-color=rose],.extra-place-choice[data-place-color=rose]{--place-accent:#f27d9a}.extra-calculation-card[data-place-color=cyan],.extra-place-badge[data-place-color=cyan],.extra-place-catalog-tag[data-place-color=cyan],.extra-place-choice[data-place-color=cyan]{--place-accent:#52c4e8}.extra-calculation-card[data-place-color=green],.extra-place-badge[data-place-color=green],.extra-place-catalog-tag[data-place-color=green],.extra-place-choice[data-place-color=green]{--place-accent:#80c86f}.extra-calculation-card[data-place-color=orange],.extra-place-badge[data-place-color=orange],.extra-place-catalog-tag[data-place-color=orange],.extra-place-choice[data-place-color=orange]{--place-accent:#ed8d58}
.extra-calculation-card-head{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:19px 20px;background:linear-gradient(120deg,#678cff12,transparent 72%);border-bottom:1px solid var(--om-line);}
.extra-calculation-card-head h3{margin:4px 0 0;font-size:16px;font-weight:600;font-variant-numeric:tabular-nums;}
.extra-calculation-eyebrow{font-size:10px;letter-spacing:1.35px;color:var(--om-muted);font-weight:650;}
.extra-place-badge{display:inline-flex;align-items:center;gap:7px;margin-top:8px;padding:4px 9px;border:1px solid color-mix(in srgb,var(--place-accent,#6b8cff) 30%,var(--om-line));border-radius:999px;background:color-mix(in srgb,var(--place-accent,#6b8cff) 9%,var(--om-panel));color:color-mix(in srgb,var(--place-accent,#6b8cff) 78%,var(--om-text));font-size:11px;font-weight:600;line-height:1.3;}
.extra-place-picker{display:grid;gap:9px;padding:13px 14px;border:1px solid var(--om-line);border-radius:12px;background:var(--om-field);}.extra-place-picker-head{display:flex;align-items:baseline;gap:9px;}.extra-place-picker-head strong{font-size:12px;font-weight:650;color:var(--om-text);}.extra-place-picker-head span{font-size:10px;color:var(--om-muted);}
.extra-place-choice-buttons{display:flex;flex-wrap:wrap;gap:8px;}.extra-place-choice{--place-accent:#8793a7;display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:36px!important;padding:7px 12px!important;border:1px solid color-mix(in srgb,var(--place-accent) 35%,var(--om-line))!important;border-radius:9px!important;background:color-mix(in srgb,var(--place-accent) 7%,var(--om-panel))!important;color:var(--om-text)!important;font-family:inherit!important;font-size:11px!important;font-weight:600!important;line-height:1.2;cursor:pointer;transition:background .15s,border-color .15s,transform .15s;}.extra-place-choice:hover{border-color:var(--place-accent)!important;transform:translateY(-1px);}.extra-place-choice[aria-pressed=true]{border-color:var(--place-accent)!important;background:color-mix(in srgb,var(--place-accent) 21%,var(--om-panel))!important;box-shadow:0 0 0 2px color-mix(in srgb,var(--place-accent) 12%,transparent);}.extra-place-choice i{width:8px;height:8px;flex:none;border-radius:50%;background:var(--place-accent);box-shadow:0 0 9px color-mix(in srgb,var(--place-accent) 38%,transparent);}.extra-place-choice[data-place-color=none]{--place-accent:#8793a7;}
.extra-place-badge i,.extra-place-current i{width:8px;height:8px;flex:none;border-radius:50%;background:var(--place-accent,#6b8cff);box-shadow:0 0 10px color-mix(in srgb,var(--place-accent,#6b8cff) 48%,transparent);}
.extra-place-row{display:grid;grid-template-columns:minmax(180px,1fr) auto auto;align-items:end;gap:10px;padding:13px 14px;border:1px solid var(--om-line);border-radius:12px;background:linear-gradient(120deg,#6b8cff0b,transparent 70%),var(--om-field);}
.extra-place-row>label{display:grid;gap:6px;color:var(--om-muted);font-size:12px;}
.extra-place-row select{width:100%;min-height:42px;background:var(--om-panel);border-color:var(--om-line);}
.extra-place-current{display:flex;align-items:center;gap:8px;min-height:40px;padding:0 11px;color:var(--om-muted);font-size:11px;white-space:nowrap;}
.extra-place-current.is-selected{color:var(--om-text);font-weight:600;}
.extra-place-current i{background:var(--om-line);box-shadow:none;}.extra-place-current i[data-place-color=blue]{--place-accent:#6b8cff}.extra-place-current i[data-place-color=teal]{--place-accent:#43cbb0}.extra-place-current i[data-place-color=violet]{--place-accent:#ad82ff}.extra-place-current i[data-place-color=amber]{--place-accent:#e8ae53}.extra-place-current i[data-place-color=rose]{--place-accent:#f27d9a}.extra-place-current i[data-place-color=cyan]{--place-accent:#52c4e8}.extra-place-current i[data-place-color=green]{--place-accent:#80c86f}.extra-place-current i[data-place-color=orange]{--place-accent:#ed8d58}
.extra-place-create{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:end;gap:10px;padding:12px 14px;margin-top:9px;border:1px solid color-mix(in srgb,var(--om-accent) 30%,var(--om-line));border-radius:11px;background:color-mix(in srgb,var(--om-accent) 6%,var(--om-panel));}
.extra-place-create label{display:grid;gap:6px;color:var(--om-muted);font-size:12px;}.extra-place-create .owner-money-error{grid-column:1/-1;margin:0;}
.extra-calculation-result{display:grid;gap:4px;text-align:right;flex:0 0 auto;}
.extra-calculation-result span{font-size:11px;color:var(--om-muted);}
.extra-calculation-result strong{font-size:20px;font-weight:650;font-variant-numeric:tabular-nums;}
.extra-calculation-result.is-positive strong{color:#43c99b;}.extra-calculation-result.is-negative strong{color:#ff7889;}
.extra-calculation-card>.owner-money-description{padding:0 20px;margin:14px 0 0;}
.extra-calculation-period{padding:15px 20px 13px;border-bottom:1px solid color-mix(in srgb,var(--om-line) 72%,transparent);}
.extra-calculation-period h4{margin:0 0 10px;font-size:12px;font-weight:600;color:var(--om-text);}
.extra-calculation-period dl{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:7px 16px;margin:0;font-size:12px;}
.extra-calculation-period dt{color:var(--om-muted);}.extra-calculation-period dd{margin:0;text-align:right;overflow-wrap:anywhere;font-variant-numeric:tabular-nums;color:var(--om-text);}
.extra-calculation-period dd:last-child{font-weight:650;}
.extra-calculation-card.has-end .extra-calculation-period:last-of-type{background:color-mix(in srgb,var(--om-field) 40%,transparent);}
.extra-calculation-foot{padding:13px 20px;display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;}
.extra-calculation-foot>span{font-size:11px;color:var(--om-muted);}.extra-calculation-foot .owner-money-toolbar{margin:0;}
.extra-calculation-preview{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:12px;padding:14px 16px;background:linear-gradient(110deg,#5e87ff12,transparent),var(--om-field);border:1px solid var(--om-line);border-radius:11px;}
.extra-calculation-preview span{display:grid;gap:3px;font-size:13px;color:var(--om-text);}.extra-calculation-preview span small{font-size:11px;color:var(--om-muted);}.extra-calculation-preview>strong{text-align:right;font-weight:650;font-size:18px;overflow-wrap:anywhere;font-variant-numeric:tabular-nums;}.extra-calculation-preview>strong.is-negative{color:#ff7889;}
[data-owner-money] [hidden]{display:none!important;}
@media(max-width:800px){.extra-calculation-list{grid-template-columns:1fr;}}
[data-owner-money] .extra-period-modal{width:min(1080px,calc(100vw - 32px));max-height:calc(100dvh - 32px);overflow:auto;scrollbar-width:thin;background:linear-gradient(145deg,color-mix(in srgb,var(--om-panel) 98%,#6b8cff 2%),var(--om-panel));}
[data-owner-money] .extra-period-modal .notice-modal-head{position:sticky;top:-24px;z-index:2;padding:3px 0 13px;background:var(--om-panel);border-bottom:1px solid var(--om-line);}
[data-owner-money] .extra-period-modal .owner-money-form{gap:14px;margin-top:17px;}
.extra-period-intro{display:grid;gap:4px;padding:13px 16px;border:1px solid color-mix(in srgb,var(--om-accent) 28%,var(--om-line));border-radius:11px;background:color-mix(in srgb,var(--om-accent) 7%,var(--om-field));}
.extra-period-intro strong{font-size:14px;font-weight:600;}.extra-period-intro span{font-size:12px;color:var(--om-muted);line-height:1.5;}
.extra-period-description textarea{min-height:62px;resize:vertical;}
.extra-period-columns{display:grid;grid-template-columns:minmax(0,1fr);gap:14px;}.extra-period-columns.has-end{grid-template-columns:repeat(2,minmax(0,1fr));}
.extra-period-block{min-width:0;margin:0;padding:17px;border:1px solid var(--om-line);border-radius:13px;display:grid;align-content:start;gap:12px;background:linear-gradient(160deg,color-mix(in srgb,var(--om-accent) 4%,var(--om-panel)),var(--om-panel) 45%);}
.extra-period-block[data-block="end_"]{border-color:color-mix(in srgb,#47c69d 26%,var(--om-line));background:linear-gradient(160deg,color-mix(in srgb,#47c69d 5%,var(--om-panel)),var(--om-panel) 46%);}
.extra-period-block legend{display:flex;align-items:center;gap:8px;padding:0 7px;font-size:15px;font-weight:650;}
.extra-period-step{display:grid;place-items:center;width:23px;height:23px;border-radius:7px;background:color-mix(in srgb,var(--om-accent) 16%,var(--om-field));color:#90aaff;font-size:10px;font-variant-numeric:tabular-nums;}
.extra-period-block[data-block="end_"] .extra-period-step{background:#47c69d20;color:#54d2a7;}
.extra-period-block label{font-size:12px;color:var(--om-muted);}
.extra-period-block :is(input,select){background:var(--om-field);border-color:var(--om-line);}
[data-owner-money] .extra-end-toggle{display:flex;align-items:center;gap:11px;padding:12px 14px;border:1px solid var(--om-line);border-radius:11px;background:var(--om-field);cursor:pointer;}
[data-owner-money] .extra-end-toggle input{width:18px;height:18px;min-height:18px;accent-color:var(--om-accent);}
.extra-end-toggle span{display:grid;gap:2px;}.extra-end-toggle strong{font-size:12px;color:var(--om-text);font-weight:550;}.extra-end-toggle small{font-size:11px;color:var(--om-muted);}
.extra-period-subtotal{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:10px 12px;border-radius:9px;background:var(--om-field);font-size:12px;color:var(--om-muted);}.extra-period-subtotal strong{overflow-wrap:anywhere;text-align:right;color:var(--om-text);font-size:14px;font-variant-numeric:tabular-nums;}
[data-owner-money] .extra-period-modal .owner-money-form-actions{position:sticky;bottom:-24px;padding:13px 0 0;background:linear-gradient(transparent,var(--om-panel) 40%);}
@media(max-width:700px){.extra-calculation-list{grid-template-columns:1fr;}.extra-period-columns.has-end{grid-template-columns:1fr;}.extra-period-block{padding:13px;}[data-owner-money] .extra-period-modal{max-height:calc(100dvh - 16px);width:calc(100vw - 16px);padding:18px;}[data-owner-money] .extra-period-modal .notice-modal-head{top:-18px;}.extra-calculation-card-head{padding:16px;}.extra-calculation-period{padding:13px 16px;}.extra-calculation-foot{padding:12px 16px;}.extra-place-row{grid-template-columns:minmax(0,1fr) auto;}.extra-place-row>label{grid-column:1/-1}.extra-place-current{padding-left:2px}.extra-place-create{grid-template-columns:minmax(0,1fr)}.extra-place-create .owner-money-error{grid-column:auto;}}

/* Private owner notes */
#ownerNotes {margin:28px 0;padding:22px;border:1px solid var(--border);border-radius:16px;background:var(--sd-panel,#131c2a);}
#ownerNotes .owner-money-section-head {margin-bottom:18px;}
.owner-notes-grid {display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,280px),1fr));gap:14px;}
.owner-note-card {min-width:0;display:flex;flex-direction:column;gap:14px;padding:20px;border:1px solid var(--border);border-top:3px solid #658cff;border-radius:12px;background:var(--sd-bg,#0e1521);}
.owner-note-card h4 {margin:0;font-size:17px;overflow-wrap:anywhere;}
.owner-note-text {font-size:14px;line-height:1.7;white-space:pre-wrap;overflow-wrap:anywhere;max-height:300px;overflow:auto;}
.owner-note-card small {margin-top:auto;color:var(--muted);}
.owner-note-card .owner-money-toolbar {justify-content:flex-end;}
.owner-note-format {display:flex;gap:8px;}
.owner-note-format button {padding:7px 12px;border:1px solid var(--border);border-radius:8px;background:transparent;color:inherit;cursor:pointer;}
@media(max-width:600px){#ownerNotes {padding:16px;}#ownerNotes .owner-money-section-head {align-items:flex-start;gap:12px;flex-wrap:wrap;}}

.penalty-period-report {margin-bottom:20px;}
.penalty-period-filter {display:flex;align-items:end;flex-wrap:wrap;gap:12px;}
.penalty-period-filter label {display:grid;gap:6px;min-width:155px;color:var(--muted);font-size:13px;}
.penalty-period-filter input {min-height:42px;}
.penalty-period-totals {display:grid;grid-template-columns:1fr 1fr 1.3fr;gap:14px;margin:18px 0;}
.penalty-period-totals>div {display:grid;gap:9px;padding:18px;border:1px solid var(--border);border-radius:12px;background:var(--sd-bg,#0e1521);}
.penalty-period-totals span {font-size:13px;color:var(--muted);}
.penalty-period-totals strong {font-size:22px;font-variant-numeric:tabular-nums;}
.penalty-period-totals>div:last-child strong {font-size:16px;}
@media(max-width:650px){.penalty-period-totals {grid-template-columns:1fr 1fr;}.penalty-period-totals>div:last-child {grid-column:1/-1;}.penalty-period-filter label {flex:1;min-width:125px;}}
.penalty-period-filter .primary-button {width:auto;}
.penalty-period-report .penalty-period-table {width:100%;min-width:360px;table-layout:auto;}
.penalty-period-report .penalty-period-table th,.penalty-period-report .penalty-period-table td {width:auto;}
.penalty-period-report .penalty-period-table td:last-child {font-weight:600;}

/* Employee issues: same quiet surfaces and typography as the shift. */
.issue-launch{border:1px solid #29374b;background:#121b29;color:#bdc9da;border-radius:10px;padding:10px 14px;font:inherit;font-size:13px;cursor:pointer;white-space:nowrap}
.issue-launch.has-issues{color:#ffc5aa;border-color:#805443;background:#30252a}
.issues-dialog{width:min(720px,calc(100vw - 32px));max-height:85vh;overflow:auto;background:#121b29;color:#e8edf6;border:1px solid #29374b;border-radius:20px;padding:28px}
.issue-hint,.issue-card small{color:#94a4bb;font-size:13px;line-height:1.6}
.issue-actions{display:flex;gap:10px;justify-content:flex-end;flex-wrap:wrap;margin:20px 0}
.issue-actions .primary-button{background:#597eff;color:#fff;box-shadow:none;border:0;border-radius:10px;padding:12px 18px}
.issue-list h3{font-size:14px;color:#96a7be;margin:24px 0 12px}
.issue-card{background:#0e1521;border:1px solid #29374b;border-radius:14px;padding:18px;margin:10px 0;border-left:3px solid #dc9c79}
.issue-card h4{font-size:17px;margin:8px 0}.issue-card p{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.6;font-size:14px;color:#c0cadb;margin:8px 0 16px}.issue-card h4{overflow-wrap:anywhere}
.issue-card.is-resolved{border-left-color:#4bba9c}.issue-list details{margin-top:24px}.issue-list summary{cursor:pointer;color:#94a4bb}.issue-empty{padding:30px 16px;text-align:center;color:#94a4bb;background:#0e1521;border-radius:14px}
.issue-form label{display:grid;gap:9px;font-size:14px;color:#bdc9da;margin-top:20px}.issue-form input,.issue-form textarea{box-sizing:border-box;width:100%;font:inherit;color:#e8edf6;background:#0e1521;border:1px solid #29374b;border-radius:12px;padding:14px;resize:vertical}.issue-form :is(input,textarea):focus{outline:2px solid #597eff;outline-offset:2px}.issue-error{color:#ff9f9f;font-size:13px}
@media(max-width:600px){.issues-dialog{padding:20px}.issue-launch{padding:8px;font-size:12px}.issue-actions>*{flex:1}.topbar-actions{flex-wrap:wrap}}
.issue-launch{display:grid;text-align:left;gap:3px;max-width:240px}.issue-launch small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:11px;max-width:210px;color:#d9ac98}
.issues-dialog{gap:16px}.issues-dialog .issue-actions{margin:4px 0}.issues-dialog .issue-actions .primary-button{width:auto;margin:0}.issues-dialog .issue-hint{margin:0}.issues-dialog .issue-list h3{margin-top:8px}
/* Problems workspace: immediate composition, compact current list. */
body:has(#processing:not([hidden]) .sd-current-issues-card) #employeeIssuesButton{display:none}
.issues-dialog{display:block!important;width:min(960px,calc(100vw - 32px));padding:26px;max-height:90dvh;overflow:auto}
.issues-dialog .notice-modal-head{margin:0 0 24px;padding:0}.issues-dialog .notice-modal-head h2{font-size:23px;font-weight:600}.issues-dialog .notice-modal-head button{width:36px;height:36px;padding:0;border-radius:10px}
.issues-workspace{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:28px;align-items:start}
.issues-compose{min-width:0}.issues-compose>h3{font-size:16px;font-weight:500;margin:0 0 8px}.issues-overview{min-width:0;border-left:1px solid #29374b;padding-left:28px}
.issues-dialog .issue-form{display:block;margin:0}.issues-dialog .issue-form label{margin-top:16px}.issues-dialog .issue-form textarea{min-height:145px}.issues-dialog .issue-form .issue-actions{display:flex;margin:12px 0 0}.issues-dialog .issue-form .primary-button{width:100%;padding:12px}.issues-dialog .issue-error:empty{display:none}
.issues-list-toolbar{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:12px;font-size:14px;color:#94a4bb}.issues-list-toolbar button{font-size:12px;padding:7px 10px}
.issues-dialog .issue-list h3{font-size:13px;margin:0 0 12px}.issues-dialog .issue-empty{padding:24px 16px;font-size:14px;line-height:1.6;border:1px dashed #29374b;background:transparent;margin:0}
.issues-dialog .issue-card{padding:14px;margin:0 0 10px}.issues-dialog .issue-card h4{font-size:15px}.issues-dialog .issue-card p{font-size:13px;margin-bottom:10px}.issues-dialog .issue-card small{font-size:11px}.issues-dialog .issue-card button{font-size:12px;padding:7px 12px}
.sd-current-issues-card .sd-note{overflow-wrap:anywhere}
@media(max-width:700px){.issues-dialog{padding:20px}.issues-workspace{grid-template-columns:1fr;gap:24px}.issues-overview{border-left:0;border-top:1px solid #29374b;padding:20px 0 0}.issues-dialog .notice-modal-head{margin-bottom:18px}.issues-dialog .issue-form textarea{min-height:110px}}
/* Issues stay on the shift page; only the composition form expands. */
#processing .issues-inline .issue-form[hidden],#processing .issues-inline .issue-history[hidden]{display:none!important}
#processing .issues-inline .issue-list{margin:14px 0 18px}
#processing .issues-inline .issue-card{margin:12px 0;padding:14px;border-radius:12px}
#processing .issues-inline .issue-card h4{font-size:15px;font-weight:500;margin:6px 0}
#processing .issues-inline .issue-card p{font-size:13px;line-height:1.5;margin:8px 0 12px}
#processing .issues-inline .issue-card small{font-size:11px}
#processing .issues-inline .issue-card button{font-size:13px;padding:8px 12px}
#processing .issues-inline .issue-form{display:block;padding-top:18px;margin-top:18px;border-top:1px solid var(--sd-line)}
#processing .issues-inline .issue-form label{margin-top:14px}
#processing .issues-inline .issue-form textarea{min-height:110px}
#processing .issues-inline .issue-form .issue-actions{margin:12px 0 0}
#processing .issues-inline .issue-form .primary-button{width:100%;margin:0;box-shadow:none;color:#fff}
#processing .issues-inline .issue-error:empty{display:none}
#processing .issues-inline .issue-history{margin-top:18px;font-size:13px;color:var(--sd-muted)}
#processing .issues-inline .issue-history summary{cursor:pointer}
#staffAlertsContent{max-width:1280px;margin:0 auto;padding:24px 16px;color:#e6edf8}.ta-header,.ta-row,.ta-toolbar{display:flex;align-items:center;justify-content:space-between;gap:16px}.ta-header{margin-bottom:28px}.ta-header h1{font-size:28px;margin:7px 0 10px}.ta-eyebrow{font-size:11px;letter-spacing:2px;color:#92a5c0}.ta-muted{color:#91a3bd;font-size:13px;line-height:1.6}.ta-tabs{display:flex;gap:8px;border-bottom:1px solid #263449;padding-bottom:12px;margin-bottom:24px;flex-wrap:wrap}.ta-tabs .active{background:#263959;color:#c3d6ff;border-color:#4c6ea5}.ta-button,.ta-primary{font:inherit;font-size:13px;padding:10px 15px;border-radius:10px;cursor:pointer;border:1px solid #2b3b52;background:#121c2a;color:#dce6f4}.ta-primary{background:#567cff;color:#fff;border-color:transparent}.ta-button:disabled,.ta-primary:disabled{opacity:.5;cursor:wait}.ta-toolbar{margin:20px 0}.ta-layout.editing{display:grid;grid-template-columns:minmax(0,1fr) minmax(350px,.95fr);gap:22px;align-items:start}.ta-card,.ta-member,.ta-editor{background:#121b29;border:1px solid #27364c;border-radius:16px;padding:22px;margin-bottom:14px}.ta-card h3,.ta-member h3{font-size:17px;margin:0}.ta-message{white-space:pre-wrap;overflow-wrap:anywhere;font-size:14px;line-height:1.6;margin:16px 0}.ta-badge{border:1px solid #34475f;border-radius:20px;padding:5px 10px;white-space:nowrap;font-size:11px;color:#a1b1c8}.ta-badge.active{color:#62d5b4;border-color:#28574c}.ta-controls{display:flex;gap:8px;flex-wrap:wrap;margin-top:18px}.ta-empty{padding:45px 24px;border:1px dashed #2b3b52;border-radius:16px;color:#91a3bd;font-size:14px;line-height:1.6}.ta-editor h2{font-size:19px;margin:0}.ta-editor label{display:grid;gap:8px;font-size:13px;color:#acbdd5;margin:16px 0}.ta-editor input,.ta-editor textarea,.ta-editor select,.ta-access select,.ta-invite input{background:#0c1420;border:1px solid #2b3b52;border-radius:9px;color:#e3ecf8;padding:11px;font:inherit;width:100%;box-sizing:border-box;color-scheme:dark}.ta-editor textarea{resize:vertical}.ta-fields{display:grid;grid-template-columns:1fr 1fr;gap:12px}.ta-people{border:1px solid #2b3b52;border-radius:10px;padding:12px;max-height:220px;overflow:auto}.ta-people label,.ta-access label{display:flex;align-items:center;gap:9px;margin:9px 0}.ta-people input,.ta-access input{width:16px;height:16px;accent-color:#678aff}.ta-preview{padding:16px;background:#0c1420;border-radius:10px;font-size:13px}.ta-preview summary{cursor:pointer;color:#9daec5}.ta-preview strong{display:block;margin-top:15px}.ta-preview p{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.6}.ta-error,.ta-warning{color:#f9af99;font-size:13px}.ta-warning{padding:14px;border:1px solid #6b4c43;border-radius:12px}.ta-access{display:grid;grid-template-columns:1fr 1fr;gap:8px 18px;margin:14px 0 18px;font-size:13px}.ta-invite{background:#192b43;border:1px solid #41628b;border-radius:14px;padding:20px;margin-bottom:20px}.ta-invite input{margin:8px 0}.ta-delivery{font-size:13px;padding:10px 0;border-bottom:1px solid #253348}@media(max-width:850px){.ta-layout.editing{display:flex;flex-direction:column-reverse}.ta-layout>*{width:100%;box-sizing:border-box}.ta-fields{grid-template-columns:1fr}.ta-header,.ta-toolbar{align-items:flex-start;flex-wrap:wrap}.ta-access{grid-template-columns:1fr}.ta-row{flex-wrap:wrap}}
#staffAlertsContent [hidden]{display:none!important}
.ta-layout.editing{display:flex;flex-direction:column-reverse;gap:20px;align-items:stretch}.ta-layout.editing>*{width:100%;box-sizing:border-box}
.ta-editor{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:0 28px}.ta-editor>.ta-row,.ta-editor>.ta-controls,.ta-editor>.ta-error{grid-column:1/-1}.ta-editor>.ta-controls{justify-content:flex-end;padding-top:14px;border-top:1px solid #27364c}.ta-editor .ta-compose textarea{min-height:200px}.ta-editor .ta-timing{border-left:1px solid #27364c;padding-left:28px}.ta-editor label{margin:12px 0}.ta-people label{margin:8px 0}.ta-editor .ta-people{margin:12px 0}.ta-compose,.ta-timing{min-width:0}.ta-error:empty{display:none}
@media(max-width:850px){.ta-editor{display:block}.ta-editor .ta-timing{border-left:0;padding-left:0;margin-top:18px}.ta-editor .ta-compose textarea{min-height:140px}}
/* Moscow date/time picker, shared by start and optional end. */
.ta-editor .ta-fields{grid-template-columns:1fr}.ta-date-field{min-width:0;margin:12px 0}.ta-date-label{display:block;font-size:13px;color:#acbdd5;margin-bottom:8px}.ta-editor .ta-date-trigger{width:100%;display:flex;align-items:center;justify-content:space-between;padding:12px 15px;background:#0c1420;border:1px solid #30435e;text-align:left;box-sizing:border-box}.ta-date-trigger strong{display:block;font-size:14px;font-weight:500}.ta-date-trigger small{display:block;color:#92a8c6;margin-top:5px;font-size:12px}.ta-date-trigger[aria-expanded=true]{border-color:#789bff;box-shadow:0 0 0 2px #567cff25}.ta-date-icon{font-size:24px;color:#9bb5ee}.ta-date-panel{margin-top:10px;padding:14px;border:1px solid #344764;background:#101a2a;border-radius:14px;box-sizing:border-box}.ta-date-quick{display:flex;gap:6px;flex-wrap:wrap}.ta-date-quick .ta-button{padding:7px 10px;font-size:11px;border-color:#2c3c55;background:#18243a}.ta-date-month{display:flex;align-items:center;justify-content:space-between;margin:14px 0 10px}.ta-date-month strong{font-size:14px;font-weight:500;text-transform:capitalize}.ta-date-month .ta-button{padding:4px 13px;font-size:24px;line-height:1.1}.ta-date-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:4px}.ta-weekday{text-align:center;padding:6px 0;font-size:11px;color:#7e94b2}.ta-date-day{padding:0;height:34px;border-radius:8px;border:1px solid transparent;background:transparent;color:#dbe7fc;font:inherit;font-size:12px;cursor:pointer}.ta-date-day:hover:not(:disabled){background:#263b61}.ta-date-day.today{border-color:#547cb7}.ta-date-day[aria-pressed=true]{background:#567cff;color:white}.ta-date-day.outside{color:#7d8a9d}.ta-date-day:disabled{color:#45536b;cursor:default}.ta-date-day:focus-visible{outline:2px solid #a1bbff;outline-offset:1px}.ta-date-time{display:flex;align-items:center;gap:8px;border-top:1px solid #263954;margin:14px 0 10px;padding-top:14px;font-size:13px}.ta-editor .ta-date-time input{width:48px;padding:8px 2px;text-align:center;font-size:17px;background:#17243a}.ta-date-time small{font-size:10px;color:#91a3bd;margin-left:auto}.ta-date-footer{display:flex;gap:6px;justify-content:flex-end;margin-top:14px}.ta-date-footer button{font-size:12px;padding:9px 12px}.ta-date-panel .ta-error:empty{display:none}
@media(max-width:450px){.ta-date-panel{padding:10px}.ta-date-grid{gap:2px}.ta-date-quick .ta-button{font-size:10px;padding:6px}.ta-date-day{height:32px}.ta-date-time{gap:6px}.ta-date-time small{font-size:9px}.ta-date-footer button{padding:9px;font-size:11px}}

/* Per-notice delivery hours. */
.ta-hours{margin:16px 0;padding:14px 16px;border:1px solid #30435e;border-radius:12px;background:#101a2a}.ta-editor .ta-hours>label{margin-top:0}.ta-hours-range{display:grid;grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);gap:14px;align-items:center}.ta-hours-range>span{padding-top:22px;color:#8ea1bd}.ta-editor .ta-hours-range input{font-variant-numeric:tabular-nums;font-size:20px;letter-spacing:1px;text-align:center}.ta-hours .ta-muted{margin:12px 0 0}.ta-hours input:focus{outline:2px solid #678aff;outline-offset:2px}

.penalty-access-row{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:16px 0;border-top:1px solid #29364a}.penalty-access-row strong,.penalty-access-row small{display:block}.penalty-access-row small{margin-top:6px;color:#93a3bb}.penalty-access-row button{flex-shrink:0}.penalty-access-list{margin-top:18px}#penaltyAccessPanel[hidden]{display:none!important}@media(max-width:550px){.penalty-access-row{align-items:flex-start;flex-direction:column}.penalty-access-row button{width:100%}}

.pr-history-toggle{display:flex;align-items:center;gap:12px;position:relative;margin-top:18px;padding-top:16px;border-top:1px solid #2a3549;cursor:pointer}.pr-history-toggle input{position:absolute;width:1px;height:1px;opacity:0}.pr-switch-track{flex:0 0 42px;height:24px;border-radius:20px;background:#394457;transition:background .15s}.pr-switch-track:after{content:"";display:block;width:18px;height:18px;margin:3px;border-radius:50%;background:#dbe4f4;transition:transform .15s}.pr-history-toggle input:checked+.pr-switch-track{background:#567cff}.pr-history-toggle input:checked+.pr-switch-track:after{transform:translateX(18px);background:#fff}.pr-history-toggle input:focus-visible+.pr-switch-track{outline:2px solid #a9c1ff;outline-offset:3px}.pr-history-toggle strong{display:block;font-size:13px;font-weight:500}.pr-history-toggle small{display:block;margin-top:5px;color:#91a3bd;font-size:12px;line-height:1.5}

/* One calendar selects the entire fine-report period. */
.penalty-range{position:relative;width:min(100%,370px)}.penalty-range-trigger{display:flex;align-items:center;gap:12px;width:100%;padding:13px 16px;border:1px solid #33425b;border-radius:12px;background:#0e1726;color:#e7eefb;text-align:left;cursor:pointer}.penalty-range-trigger svg{width:23px;height:23px;color:#8dabff;flex-shrink:0}.penalty-range-trigger small{display:block;font-size:11px;color:#94a7c2;margin-bottom:5px}.penalty-range-trigger strong{font-size:14px;font-weight:500;font-variant-numeric:tabular-nums}.penalty-range-chevron{margin-left:auto;color:#91a6c5}.penalty-range-trigger[aria-expanded=true]{border-color:#678aff;box-shadow:0 0 0 3px #567cff20}.penalty-range-pop{position:absolute;top:calc(100% + 10px);left:0;z-index:60;width:100%;box-sizing:border-box;background:#131e2e;border:1px solid #35465f;border-radius:16px;padding:16px;box-shadow:0 18px 50px #0006}.penalty-range-pop[hidden]{display:none!important}.penalty-range button{font-family:inherit}.penalty-range-pop button{cursor:pointer;color:#dce7f7;border:1px solid #30435c;border-radius:8px;background:#1a293e}.penalty-range-presets{display:grid;grid-template-columns:repeat(4,1fr);gap:6px;margin-bottom:18px}.penalty-range-presets button{padding:8px 3px;font-size:11px;white-space:nowrap}.penalty-range-month{display:flex;align-items:center;justify-content:space-between;margin-bottom:12px}.penalty-range-month strong{font-size:14px;font-weight:500;text-transform:capitalize}.penalty-range-month button{width:32px;height:32px;font-size:22px}.penalty-range-week,.penalty-range-days{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:3px}.penalty-range-week span{text-align:center;font-size:11px;color:#8fa4c1;padding:6px 0}.penalty-range-days button{aspect-ratio:1;border:1px solid transparent;background:transparent;font-size:13px;font-variant-numeric:tabular-nums}.penalty-range-days button.outside{color:#697f9d}.penalty-range-days button[aria-current=date]{border-color:#5874a4}.penalty-range-days button.between{background:#253c62;border-radius:4px;color:#d8e6ff}.penalty-range-days button.endpoint{background:#567cff;color:white;border-color:#82a3ff}.penalty-range button:focus-visible{outline:2px solid #a7c0ff;outline-offset:2px}.penalty-range-days button:hover{box-shadow:inset 0 0 0 1px #88a8eb}.penalty-range-hint{font-size:12px;line-height:1.5;color:#a2b5d0;min-height:36px;margin:16px 0 10px}.penalty-range-footer{display:flex;justify-content:flex-end;gap:8px;border-top:1px solid #293951;padding-top:14px}.penalty-range-footer button{padding:10px 15px;font-size:12px}.penalty-range-footer [data-apply]{background:#567cff;border-color:#567cff;color:white}.penalty-range-footer button:disabled{opacity:.4;cursor:default}#penaltyPeriodReport{overflow:visible}@media(max-width:600px){.penalty-range{width:100%}.penalty-range-pop{position:relative;top:auto;margin-top:10px;padding:12px;box-shadow:none}.penalty-range-presets{gap:4px}.penalty-range-presets button{font-size:10px}.penalty-range-trigger strong{font-size:13px}}

/* Per-employee pay policy, kept separate from access settings. */
.employee-salary{grid-column:1/-1;border:1px solid var(--line-strong);border-radius:16px;padding:20px;background:var(--surface)}
.employee-salary-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:18px}
.employee-salary-heading h3{margin:4px 0 0;font-size:18px}.employee-salary-heading .eyebrow{margin:0}
.salary-tag{font-size:12px;color:#9fb6ec;background:rgba(89,125,255,.1);border-radius:20px;padding:6px 10px;white-space:nowrap}
.employee-salary-controls{display:grid;grid-template-columns:1.6fr 1fr 1fr;gap:16px;align-items:end}
.salary-preview{display:flex;flex-direction:column;justify-content:center;gap:8px;min-height:68px;padding:10px 16px;border-radius:12px;background:rgba(89,125,255,.08)}
.salary-preview span{font-size:12px;color:var(--muted)}.salary-preview strong{font-size:23px;font-variant-numeric:tabular-nums;color:#64d6b2}
.employee-salary .sd-note{margin:12px 0 0;font-size:13px;line-height:1.6}.employee-salary summary{cursor:pointer;padding-top:14px;font-size:14px;color:#a6bbf3}
.salary-steps{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin-top:14px;max-height:360px;overflow:auto;scrollbar-width:thin;scrollbar-color:#45516d transparent}.salary-steps span{display:flex;flex-direction:column;gap:6px;padding:12px;border-radius:8px;background:rgba(127,147,180,.07);font-size:13px;font-variant-numeric:tabular-nums}.salary-steps b{font-weight:400;color:var(--muted)}.salary-steps strong{font-weight:600;color:#9be4c9}.salary-steps:focus-visible{outline:2px solid var(--accent);outline-offset:4px}
@media(max-width:700px){.employee-salary{padding:16px}.employee-salary-controls{grid-template-columns:1fr 1fr}.employee-salary-controls>label:first-child{grid-column:1/-1}.employee-salary-heading{align-items:flex-start;flex-direction:column}.salary-steps{grid-template-columns:repeat(2,minmax(0,1fr))}.salary-preview strong{font-size:20px}}
