/*
 * Write-offs workspace visual layer.
 *
 * The legacy stylesheet is shared with the former KPI screen. Keep this file
 * scoped to the write-offs shell so the operational workflow can evolve
 * independently without changing its existing DOM/API contract.
 */

body.ops-writeoffs-shell {
  --wo-bg: #f7f8fa;
  --wo-surface: #ffffff;
  --wo-surface-subtle: #f8faf9;
  --wo-border: #e1e5e9;
  --wo-border-strong: #cbd2d9;
  --wo-text: #18212b;
  --wo-muted: #63707d;
  --wo-dark: #111827;
  --wo-green: #187a43;
  --wo-green-dark: #126336;
  --wo-green-soft: #eaf6ef;
  --wo-success-strong: var(--wo-green-dark);
  --wo-red: #b42318;
  --wo-red-soft: #fef3f2;
  --wo-amber: #9a6700;
  --wo-amber-soft: #fff8e6;
  --wo-blue: #175cd3;
  --wo-blue-soft: #eff6ff;
  --wo-shadow: 0 1px 2px rgba(16, 24, 40, .035), 0 8px 24px rgba(16, 24, 40, .035);
  min-height: 100vh;
  background: var(--wo-bg);
  color: var(--wo-text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body.ops-writeoffs-shell .writeoff-document-dialog {
  width: min(1220px, calc(100vw - 32px));
  max-width: none;
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 8px;
  background: var(--wo-surface);
  color: var(--wo-text);
  box-shadow: 0 24px 72px rgba(15, 23, 42, .28);
}

body.ops-writeoffs-shell .writeoff-document-dialog::backdrop {
  background: rgba(15, 23, 42, .56);
}

body.ops-writeoffs-shell .writeoff-document-dialog-content {
  display: grid;
  max-height: calc(100dvh - 32px);
  grid-template-rows: auto minmax(0, 1fr);
}

body.ops-writeoffs-shell .writeoff-document-dialog-head {
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--wo-border);
  background: #fff;
}

body.ops-writeoffs-shell .writeoff-document-dialog-head .eyebrow {
  margin: 0 0 2px;
  color: var(--wo-green);
  font-size: 11px;
  font-weight: 800;
}

body.ops-writeoffs-shell .writeoff-document-dialog-head h2 {
  margin: 0;
  font-size: 18px;
  line-height: 1.25;
}

body.ops-writeoffs-shell .writeoff-document-dialog-head .icon-button {
  display: inline-grid;
  flex: 0 0 40px;
  width: 40px;
  min-width: 40px;
  min-height: 40px;
  place-items: center;
  padding: 0;
  border: 1px solid var(--wo-border-strong);
  border-radius: 6px;
  background: #fff;
  color: var(--wo-text);
  font-size: 26px;
  line-height: 1;
}

body.ops-writeoffs-shell .writeoff-document-dialog-body {
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  padding: 18px;
  background: var(--wo-bg);
}

body.ops-writeoffs-shell .writeoff-document-dialog-body #documentSection {
  margin: 0;
  padding: 18px;
  border: 1px solid var(--wo-border);
  border-radius: 8px;
  background: #fff;
  box-shadow: none;
}

body.ops-writeoffs-shell .writeoff-document-dialog-body input,
body.ops-writeoffs-shell .writeoff-document-dialog-body select,
body.ops-writeoffs-shell .writeoff-document-dialog-body textarea {
  min-height: 44px;
  border: 1px solid var(--wo-border-strong);
  border-radius: 6px;
  padding: 9px 11px;
  background: #fff;
  color: var(--wo-text);
}

body.ops-writeoffs-shell .writeoff-document-dialog-body button {
  border-radius: 6px;
}

body.ops-writeoffs-shell .writeoff-document-dialog-body .primary {
  border-color: var(--wo-green);
  background: var(--wo-green);
  color: #fff;
}

body.ops-writeoffs-shell .writeoff-document-dialog-body .secondary,
body.ops-writeoffs-shell .writeoff-document-dialog-body .ghost {
  border-color: var(--wo-border-strong);
  background: #fff;
  color: #34404c;
}

body.ops-writeoffs-shell .writeoff-day-dialog {
  width: min(920px, calc(100vw - 32px));
  max-width: none;
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 8px;
  background: var(--wo-surface);
  color: var(--wo-text);
  box-shadow: 0 24px 72px rgba(15, 23, 42, .28);
}

body.ops-writeoffs-shell .writeoff-day-dialog::backdrop {
  background: rgba(15, 23, 42, .48);
}

body.ops-writeoffs-shell .writeoff-day-dialog-content {
  display: grid;
  max-height: calc(100dvh - 32px);
  grid-template-rows: auto minmax(0, 1fr);
}

body.ops-writeoffs-shell .writeoff-day-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--wo-border);
  background: #fff;
}

body.ops-writeoffs-shell .writeoff-day-dialog-head .eyebrow {
  margin: 0 0 3px;
  color: var(--wo-green);
  font-size: 11px;
  font-weight: 800;
}

body.ops-writeoffs-shell .writeoff-day-dialog-head h2 {
  margin: 0;
  font-size: 20px;
  line-height: 1.25;
}

body.ops-writeoffs-shell .writeoff-day-dialog-hint {
  margin: 4px 0 0;
  color: var(--wo-muted);
  font-size: 13px;
}

body.ops-writeoffs-shell .writeoff-day-dialog-head .icon-button {
  display: inline-grid;
  flex: 0 0 40px;
  width: 40px;
  min-width: 40px;
  min-height: 40px;
  place-items: center;
  padding: 0;
  border: 1px solid var(--wo-border-strong);
  border-radius: 6px;
  background: #fff;
  color: var(--wo-text);
  font-size: 26px;
  line-height: 1;
}

body.ops-writeoffs-shell .writeoff-day-dialog-body {
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  padding: 16px 18px 18px;
  background: var(--wo-bg);
}

body.ops-writeoffs-shell .writeoff-day-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

body.ops-writeoffs-shell .writeoff-day-metrics article {
  display: grid;
  min-width: 0;
  gap: 4px;
  padding: 11px 12px;
  border: 1px solid var(--wo-border);
  border-radius: 6px;
  background: #fff;
}

body.ops-writeoffs-shell .writeoff-day-metrics span {
  color: var(--wo-muted);
  font-size: 11px;
  font-weight: 700;
}

body.ops-writeoffs-shell .writeoff-day-metrics strong {
  overflow-wrap: anywhere;
  font-size: 16px;
  font-variant-numeric: tabular-nums;
}

body.ops-writeoffs-shell .writeoff-day-statuses {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

body.ops-writeoffs-shell .writeoff-day-statuses > span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

body.ops-writeoffs-shell .writeoff-day-statuses > span > b {
  color: var(--wo-muted);
  font-size: 12px;
}

body.ops-writeoffs-shell .writeoff-day-attention {
  display: grid;
  gap: 3px;
  margin-top: 10px;
  padding: 10px 12px;
  border: 1px solid #edc86d;
  border-radius: 6px;
  background: var(--wo-amber-soft);
  color: #7a3e0d;
}

body.ops-writeoffs-shell .writeoff-day-attention strong {
  font-size: 13px;
}

body.ops-writeoffs-shell .writeoff-day-attention span {
  font-size: 12px;
}

body.ops-writeoffs-shell .writeoff-day-attention.is-risk {
  border-color: #f0b4af;
  background: var(--wo-red-soft);
  color: #912018;
}

body.ops-writeoffs-shell .writeoff-day-attention.is-incomplete {
  border-color: #edc86d;
  background: var(--wo-amber-soft);
  color: #7a3e0d;
}

body.ops-writeoffs-shell .writeoff-day-dialog-status {
  margin-top: 10px;
  padding: 9px 11px;
  border: 1px solid var(--wo-border);
  border-radius: 6px;
  background: #fff;
  color: var(--wo-muted);
  font-size: 13px;
}

body.ops-writeoffs-shell .writeoff-day-dialog-status.is-error {
  border-color: #f0b4af;
  background: var(--wo-red-soft);
  color: var(--wo-red);
}

body.ops-writeoffs-shell .writeoff-day-dialog-documents {
  margin-top: 12px;
  overflow: hidden;
  border: 1px solid var(--wo-border);
  border-radius: 7px;
  background: #fff;
}

@media (max-width: 800px) {
  body.ops-writeoffs-shell .writeoff-document-dialog {
    width: 100vw;
    max-height: 100dvh;
    border-radius: 0;
  }

  body.ops-writeoffs-shell .writeoff-document-dialog-content {
    height: 100dvh;
    max-height: 100dvh;
  }

  body.ops-writeoffs-shell .writeoff-document-dialog-head {
    padding: max(10px, env(safe-area-inset-top)) 12px 10px;
  }

  body.ops-writeoffs-shell .writeoff-document-dialog-head h2 {
    max-width: calc(100vw - 90px);
    overflow: hidden;
    font-size: 16px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  body.ops-writeoffs-shell .writeoff-document-dialog-body {
    padding: 10px 10px max(10px, env(safe-area-inset-bottom));
  }

  body.ops-writeoffs-shell .writeoff-document-dialog-body #documentSection {
    padding: 14px;
  }

  body.ops-writeoffs-shell .writeoff-day-dialog {
    width: 100vw;
    max-height: 100dvh;
    border-radius: 0;
  }

  body.ops-writeoffs-shell .writeoff-day-dialog-content {
    height: 100dvh;
    max-height: 100dvh;
  }

  body.ops-writeoffs-shell .writeoff-day-dialog-head {
    padding: max(10px, env(safe-area-inset-top)) 12px 10px;
  }

  body.ops-writeoffs-shell .writeoff-day-dialog-head h2 {
    font-size: 17px;
  }

  body.ops-writeoffs-shell .writeoff-day-dialog-body {
    padding: 10px 10px max(10px, env(safe-area-inset-bottom));
  }

  body.ops-writeoffs-shell .writeoff-day-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

body.ops-writeoffs-shell .app-shell {
  width: 100%;
  margin: 0 auto;
  padding: 0;
}

body.ops-writeoffs-shell #appMain {
  width: min(1440px, 100%);
  margin: 0 auto;
  padding: 0 28px 44px;
}

body.ops-writeoffs-shell .topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  min-height: 64px;
  margin: 0 0 18px;
  padding: 0 28px;
  border: 0;
  border-bottom: 1px solid var(--wo-border);
  border-radius: 0;
  background: rgba(255, 255, 255, .98);
  box-shadow: none;
  backdrop-filter: blur(12px);
}

body.ops-writeoffs-shell .ops-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

body.ops-writeoffs-shell .ops-brand-mark {
  display: inline-grid;
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  place-items: center;
  border: 1px solid #8bcda7;
  border-radius: 6px;
  background: #fff;
  color: var(--wo-green);
  font-size: 11px;
  font-weight: 850;
}

body.ops-writeoffs-shell .ops-brand-copy {
  display: grid;
  gap: 1px;
  min-width: 0;
}

body.ops-writeoffs-shell .ops-brand-name {
  color: var(--wo-text);
  font-size: 17px;
  font-weight: 800;
  line-height: 1.2;
}

body.ops-writeoffs-shell .topbar .ops-brand-module,
body.ops-writeoffs-shell .topbar h1 {
  display: none;
  margin: 0;
  color: var(--wo-text);
  font-size: 18px;
  font-weight: 750;
  line-height: 1.15;
  letter-spacing: 0;
}

body.ops-writeoffs-shell .topbar-actions .btn {
  width: auto;
  min-height: 38px;
  padding: 7px 12px;
  border: 1px solid var(--wo-border-strong);
  border-radius: 6px;
  background: #fff;
  color: #34404c;
  font-size: 14px;
  font-weight: 700;
}

body.ops-writeoffs-shell .topbar-actions {
  justify-self: end;
}

body.ops-writeoffs-shell .topbar .module-nav {
  justify-self: center;
  width: auto;
  max-width: none;
  position: static;
  display: flex;
  gap: 26px;
  margin: 0;
  padding: 0;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

body.ops-writeoffs-shell .topbar .module-nav .module-link,
body.ops-writeoffs-shell .topbar .module-nav .nav-link {
  display: flex;
  min-width: 0;
  position: relative;
  min-height: 63px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 0;
  color: #4b5563;
  background: transparent;
  padding: 0 2px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
}

body.ops-writeoffs-shell.ops-classic-shell .topbar .module-nav,
body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode .topbar .module-nav {
  width: auto;
  max-width: none;
  display: flex;
}

body.ops-writeoffs-shell .topbar .module-nav .module-link:hover,
body.ops-writeoffs-shell .topbar .module-nav .nav-link:hover {
  color: var(--wo-text);
  background: transparent;
}

body.ops-writeoffs-shell .topbar .module-nav .module-link.active,
body.ops-writeoffs-shell .topbar .module-nav .nav-link.active,
body.ops-writeoffs-shell .topbar .module-nav .module-link[aria-current="page"],
body.ops-writeoffs-shell .topbar .module-nav .nav-link[aria-current="page"] {
  color: var(--wo-green);
  background: transparent;
}

body.ops-writeoffs-shell .topbar .module-nav .module-link.active::after,
body.ops-writeoffs-shell .topbar .module-nav .nav-link.active::after,
body.ops-writeoffs-shell .topbar .module-nav .module-link[aria-current="page"]::after,
body.ops-writeoffs-shell .topbar .module-nav .nav-link[aria-current="page"]::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: var(--wo-green);
}

body.ops-writeoffs-shell #writeoffsModule {
  min-width: 0;
}

body.ops-writeoffs-shell #writeoffsModule > .tabs {
  position: sticky;
  top: 64px;
  z-index: 20;
  display: flex;
  width: 100%;
  min-width: 0;
  flex-wrap: nowrap;
  justify-content: flex-start;
  gap: 28px;
  margin: 0 0 14px;
  padding: 0 2px;
  border: 0;
  border-bottom: 1px solid var(--wo-border);
  border-radius: 0;
  background: rgba(247, 248, 250, .96);
  box-shadow: none;
  backdrop-filter: blur(8px);
}

body.ops-writeoffs-shell #writeoffsModule > .tabs .tab {
  position: relative;
  flex: 0 0 auto;
  min-width: 0;
  width: auto;
  min-height: 44px;
  border: 0;
  border-radius: 0;
  padding: 10px 2px 9px;
  color: #4a5663;
  background: transparent;
  font-size: 14px;
  font-weight: 750;
}

body.ops-writeoffs-shell #writeoffsModule > .tabs .tab:hover {
  color: var(--wo-text);
  background: transparent;
}

body.ops-writeoffs-shell #writeoffsModule > .tabs .tab.active {
  color: var(--wo-green-dark);
  background: transparent;
}

body.ops-writeoffs-shell #writeoffsModule > .tabs .tab.active::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: var(--wo-green);
}

body.ops-writeoffs-shell #writeoffsModule .tab-panel {
  min-width: 0;
}

body.ops-writeoffs-shell #writeoffsModule .panel,
body.ops-writeoffs-shell #loginSection,
body.ops-writeoffs-shell #authLoadingSection,
body.ops-writeoffs-shell #accessDeniedSection {
  margin: 0 0 12px;
  padding: 18px;
  border: 1px solid var(--wo-border);
  border-radius: 8px;
  background: var(--wo-surface);
  box-shadow: var(--wo-shadow);
}

body.ops-writeoffs-shell #documentTab > .sticky-controls,
body.ops-writeoffs-shell #documentTab > #documentSection,
body.ops-writeoffs-shell #managerTab > .panel,
body.ops-writeoffs-shell #summaryTab > .panel {
  position: static;
}

body.ops-writeoffs-shell #writeoffsModule h2,
body.ops-writeoffs-shell #writeoffsModule h3,
body.ops-writeoffs-shell #writeoffsModule strong,
body.ops-writeoffs-shell #writeoffsModule b {
  letter-spacing: 0;
}

body.ops-writeoffs-shell #writeoffsModule h2 {
  color: var(--wo-text);
  font-size: 24px;
  font-weight: 760;
  line-height: 1.25;
}

body.ops-writeoffs-shell #writeoffsModule h3 {
  color: var(--wo-text);
  font-size: 17px;
  font-weight: 750;
  line-height: 1.3;
}

body.ops-writeoffs-shell #writeoffsModule .eyebrow {
  margin: 0 0 5px;
  color: var(--wo-green);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .04em;
}

body.ops-writeoffs-shell #writeoffsModule .muted-text,
body.ops-writeoffs-shell #writeoffsModule .state-hint,
body.ops-writeoffs-shell #writeoffsModule .field-hint {
  color: var(--wo-muted);
}

body.ops-writeoffs-shell #writeoffsModule .state-hint {
  margin-top: 5px;
  font-size: 14px;
  line-height: 1.45;
}

body.ops-writeoffs-shell #writeoffsModule .grid-form {
  gap: 12px;
}

body.ops-writeoffs-shell #writeoffsModule .grid-form label,
body.ops-writeoffs-shell #writeoffsModule .line-grid label,
body.ops-writeoffs-shell #writeoffsModule .picker-search label {
  gap: 6px;
  color: #34404c;
  font-size: 13px;
  font-weight: 700;
}

body.ops-writeoffs-shell #writeoffsModule input,
body.ops-writeoffs-shell #writeoffsModule select,
body.ops-writeoffs-shell #writeoffsModule textarea {
  min-height: 44px;
  border: 1px solid var(--wo-border-strong);
  border-radius: 6px;
  padding: 9px 11px;
  background: #fff;
  color: var(--wo-text);
  box-shadow: none;
}

body.ops-writeoffs-shell #writeoffsModule textarea {
  min-height: 84px;
  resize: vertical;
}

body.ops-writeoffs-shell #writeoffsModule input:hover,
body.ops-writeoffs-shell #writeoffsModule select:hover,
body.ops-writeoffs-shell #writeoffsModule textarea:hover {
  border-color: #aeb8c3;
}

body.ops-writeoffs-shell #writeoffsModule input:focus,
body.ops-writeoffs-shell #writeoffsModule select:focus,
body.ops-writeoffs-shell #writeoffsModule textarea:focus {
  outline: 0;
  border-color: var(--wo-green);
  box-shadow: 0 0 0 3px rgba(24, 122, 67, .14);
}

body.ops-writeoffs-shell #writeoffsModule button,
body.ops-writeoffs-shell #writeoffsModule .primary,
body.ops-writeoffs-shell #writeoffsModule .secondary,
body.ops-writeoffs-shell #writeoffsModule .ghost {
  border-radius: 6px;
  letter-spacing: 0;
}

body.ops-writeoffs-shell #writeoffsModule .primary,
body.ops-writeoffs-shell #writeoffsModule .btn-success {
  border-color: var(--wo-green);
  background: var(--wo-green);
  color: #fff;
  box-shadow: none;
}

body.ops-writeoffs-shell #writeoffsModule .primary:hover,
body.ops-writeoffs-shell #writeoffsModule .btn-success:hover {
  border-color: var(--wo-green-dark);
  background: var(--wo-green-dark);
}

body.ops-writeoffs-shell #writeoffsModule .secondary,
body.ops-writeoffs-shell #writeoffsModule .ghost,
body.ops-writeoffs-shell #writeoffsModule .btn-outline-success {
  border-color: var(--wo-border-strong);
  background: #fff;
  color: #34404c;
  box-shadow: none;
}

body.ops-writeoffs-shell #writeoffsModule .secondary:hover,
body.ops-writeoffs-shell #writeoffsModule .ghost:hover,
body.ops-writeoffs-shell #writeoffsModule .btn-outline-success:hover {
  border-color: #9da9b4;
  background: #f4f6f7;
  color: var(--wo-text);
}

body.ops-writeoffs-shell #writeoffsModule button:focus-visible,
body.ops-writeoffs-shell #writeoffsModule a:focus-visible {
  outline: 3px solid rgba(24, 122, 67, .2);
  outline-offset: 2px;
}

body.ops-writeoffs-shell #writeoffsModule .local-date-picker-button {
  top: 50%;
  right: 4px;
  width: 36px;
  min-width: 36px;
  min-height: 36px;
  border: 0;
  background: transparent;
}

body.ops-writeoffs-shell #documentTab > .sticky-controls {
  display: grid;
  gap: 14px;
}

body.ops-writeoffs-shell .document-selection-intro {
  gap: 3px;
  margin: 0;
}

body.ops-writeoffs-shell .document-selection-intro h2 {
  font-size: 24px;
}

body.ops-writeoffs-shell .document-form {
  grid-template-columns: minmax(220px, 1fr) minmax(200px, .7fr) auto;
}

body.ops-writeoffs-shell .document-form #openDocumentButton {
  min-width: 170px;
  min-height: 44px;
}

body.ops-writeoffs-shell .document-context {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0;
}

body.ops-writeoffs-shell .document-context.document-context-clean {
  border: 0;
  padding: 0;
}

body.ops-writeoffs-shell .document-context > div {
  display: none;
}

body.ops-writeoffs-shell .context-action {
  flex: 0 0 auto;
  width: auto;
  min-height: 36px;
  padding: 6px 10px;
  font-size: 13px;
}

body.ops-writeoffs-shell #documentSection {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(270px, 310px);
  column-gap: 28px;
  align-items: start;
  overflow: visible;
}

body.ops-writeoffs-shell .document-head {
  display: contents;
}

body.ops-writeoffs-shell .document-head > div:first-child {
  grid-column: 1;
  grid-row: 1;
  min-width: 0;
  gap: 12px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--wo-border);
}

body.ops-writeoffs-shell .document-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

body.ops-writeoffs-shell .document-title-row > div:first-child {
  min-width: 0;
}

body.ops-writeoffs-shell .document-title-row h2 {
  margin: 0;
  overflow-wrap: anywhere;
  font-size: 26px;
}

body.ops-writeoffs-shell .document-meta-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  margin: 0;
}

body.ops-writeoffs-shell .document-meta-card,
body.ops-writeoffs-shell .document-meta-cards .summary-card {
  display: inline-flex;
  width: auto;
  align-items: center;
  gap: 7px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

body.ops-writeoffs-shell .document-meta-card span,
body.ops-writeoffs-shell .document-meta-cards .summary-card span {
  color: var(--wo-muted);
  font-size: 12px;
}

body.ops-writeoffs-shell .document-meta-card strong,
body.ops-writeoffs-shell .document-meta-cards .summary-card strong {
  color: var(--wo-text);
  font-size: 13px;
}

body.ops-writeoffs-shell .document-meta-card-lines {
  display: none;
}

body.ops-writeoffs-shell .document-sale-total-top-anchor,
body.ops-writeoffs-shell .document-sale-total-action-slot:empty {
  display: none;
}

body.ops-writeoffs-shell .document-meta-card-total {
  gap: 6px;
  padding: 5px 9px;
  border-radius: 8px;
  background: #eef9f1;
}

body.ops-writeoffs-shell .document-meta-card-total strong {
  color: #166534;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

body.ops-writeoffs-shell .document-meta-card-total small {
  color: #9a5b13;
  font-size: 11px;
  font-weight: 750;
  white-space: nowrap;
}

body.ops-writeoffs-shell .document-actions .document-sale-total-action-slot {
  display: block;
}

body.ops-writeoffs-shell .document-actions .document-meta-card-total {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 3px 12px;
  width: 100%;
  padding: 12px 13px;
  border: 1px solid #cbe5d3;
  border-radius: 7px;
  background: #fff;
}

body.ops-writeoffs-shell .document-actions .document-meta-card-total > span {
  align-self: center;
  color: var(--wo-muted);
  font-size: 12px;
  font-weight: 750;
}

body.ops-writeoffs-shell .document-actions .document-meta-card-total > strong {
  justify-self: end;
  color: var(--wo-green-dark);
  font-size: 20px;
  line-height: 1.15;
}

body.ops-writeoffs-shell .document-actions .document-meta-card-total > small {
  grid-column: 1 / -1;
  padding-top: 4px;
  border-top: 1px solid #e8f1eb;
  white-space: normal;
  line-height: 1.35;
}

body.ops-writeoffs-shell .status-pill {
  min-height: 25px;
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 750;
}

body.ops-writeoffs-shell .document-actions {
  grid-column: 2;
  grid-row: 1 / span 7;
  position: sticky;
  top: 120px;
  width: 100%;
  gap: 9px;
  margin: 0;
  padding: 18px;
  border: 1px solid var(--wo-border);
  border-radius: 8px;
  background: var(--wo-surface-subtle);
}

body.ops-writeoffs-shell .document-actions[data-state] {
  border-color: var(--wo-border);
  background: var(--wo-surface-subtle);
}

body.ops-writeoffs-shell .document-actions[data-state="ready"] {
  border-color: #b8d9c5;
  background: #f5fbf7;
}

body.ops-writeoffs-shell .document-actions[data-state="blocked"] {
  border-color: #ead9a9;
  background: #fffdf6;
}

body.ops-writeoffs-shell .document-actions-eyebrow {
  color: var(--wo-muted);
  font-size: 11px;
  letter-spacing: .03em;
}

body.ops-writeoffs-shell .document-action-title {
  font-size: 17px;
  font-weight: 750;
}

body.ops-writeoffs-shell .document-action-copy {
  color: var(--wo-muted);
  font-size: 12.5px;
  line-height: 1.4;
}

body.ops-writeoffs-shell .document-actions .action-primary,
body.ops-writeoffs-shell .document-actions .action-secondary {
  width: 100%;
  min-height: 40px;
  padding: 8px 11px;
  font-size: 13px;
  box-shadow: none;
}

body.ops-writeoffs-shell .document-actions-secondary {
  padding-top: 8px;
  border-color: var(--wo-border);
}

body.ops-writeoffs-shell .action-hint {
  border-radius: 6px;
  padding: 9px 10px;
  font-size: 12px;
}

body.ops-writeoffs-shell .action-requirement {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px 10px;
}

body.ops-writeoffs-shell .section-divider {
  display: none;
}

body.ops-writeoffs-shell .line-toolbar {
  grid-column: 1;
  margin: 18px 0 8px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--wo-border);
}

body.ops-writeoffs-shell .line-toolbar-title {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

body.ops-writeoffs-shell .line-toolbar-title h3 {
  font-size: 17px;
}

body.ops-writeoffs-shell .line-count {
  color: var(--wo-muted);
  font-size: 13px;
}

body.ops-writeoffs-shell .line-add-action {
  display: flex;
  grid-column: 1;
  justify-content: flex-start;
  margin-top: 12px;
}

body.ops-writeoffs-shell .line-add-action.hidden {
  display: none;
}

body.ops-writeoffs-shell .item-action {
  width: auto;
  min-height: 40px;
  padding: 8px 12px;
  border-color: rgba(24, 122, 67, .45);
  color: var(--wo-green);
}

body.ops-writeoffs-shell .empty-state {
  gap: 3px;
  border: 1px dashed var(--wo-border-strong);
  border-radius: 6px;
  background: var(--wo-surface-subtle);
  padding: 18px;
  color: var(--wo-muted);
  font-size: 14px;
}

body.ops-writeoffs-shell .picker-panel {
  grid-column: 1;
  margin: 12px 0 14px;
  padding: 12px;
  border: 1px solid #b9d8c5;
  border-top: 3px solid var(--wo-green);
  border-radius: 8px;
  background: #f8fbf9;
}

body.ops-writeoffs-shell .picker-panel-head {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: -12px -12px 12px;
  padding: 11px 12px 12px;
  border-bottom: 1px solid #d4e7db;
  background: #eff8f2;
}

body.ops-writeoffs-shell .picker-panel-title {
  display: grid;
  min-width: 0;
  gap: 2px;
}

body.ops-writeoffs-shell .picker-panel-title span {
  color: var(--wo-green);
  font-size: 10px;
  font-weight: 800;
  line-height: 1.2;
  text-transform: uppercase;
}

body.ops-writeoffs-shell .picker-panel-title h4 {
  margin: 0;
  color: var(--wo-text);
  font-size: 16px;
  line-height: 1.25;
}

body.ops-writeoffs-shell .picker-close {
  width: auto;
  min-height: 38px;
  flex: 0 0 auto;
  padding: 7px 11px;
  border-color: #a9cbb6;
  background: #fff;
  color: #344c3d;
  font-size: 12px;
}

body.ops-writeoffs-shell .picker-results {
  gap: 8px;
  max-height: min(56vh, 540px);
  margin-top: 8px;
  padding-right: 4px;
}

body.ops-writeoffs-shell .picker-status:empty {
  display: none;
}

body.ops-writeoffs-shell .picker-status:not(:empty) {
  min-height: 0;
  margin: 8px 0 0;
  padding: 8px 10px;
  border-radius: 6px;
  background: #fff8e8;
  color: #695729;
  font-size: 12px;
}

body.ops-writeoffs-shell .picker-prompt {
  display: grid;
  gap: 3px;
  padding: 8px 2px 2px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--wo-muted);
  font-size: 13px;
}

body.ops-writeoffs-shell .picker-prompt strong {
  color: var(--wo-text);
  font-size: 13px;
}

body.ops-writeoffs-shell .picker-section {
  gap: 6px;
}

body.ops-writeoffs-shell .picker-section + .picker-section {
  margin-top: 6px;
  padding-top: 12px;
  border-top: 1px solid var(--wo-border);
}

body.ops-writeoffs-shell .picker-section-head {
  min-height: 24px;
}

body.ops-writeoffs-shell .picker-section-head strong {
  font-size: 13px;
}

body.ops-writeoffs-shell .picker-section-list {
  gap: 5px;
}

body.ops-writeoffs-shell .picker-item {
  grid-template-columns: minmax(0, 1fr) 32px;
  min-height: 50px;
  padding: 8px 9px 8px 11px;
  border: 1px solid var(--wo-border);
  border-radius: 6px;
  background: #fff;
  transition: border-color .14s ease, background-color .14s ease;
}

body.ops-writeoffs-shell .picker-item:hover {
  border-color: rgba(24, 122, 67, .5);
  background: #f8fcfa;
  box-shadow: none;
  transform: none;
}

body.ops-writeoffs-shell .picker-item strong {
  font-size: 14px;
  line-height: 1.25;
}

body.ops-writeoffs-shell .picker-item small {
  font-size: 12px;
}

body.ops-writeoffs-shell .picker-item-action {
  display: inline-flex;
  width: 30px;
  height: 30px;
  align-items: center;
  justify-content: center;
  justify-self: end;
  border-radius: 50%;
  background: var(--wo-green-soft);
  color: var(--wo-green);
  font-size: 22px;
  font-weight: 500;
  line-height: 1;
}

body.ops-writeoffs-shell .source-badge,
body.ops-writeoffs-shell .approved-line-badge,
body.ops-writeoffs-shell .line-risk-badge,
body.ops-writeoffs-shell .inactive-badge {
  border-radius: 999px;
  padding: 3px 7px;
  font-size: 11px;
}

body.ops-writeoffs-shell .lines-list {
  grid-column: 1;
  gap: 10px;
}

body.ops-writeoffs-shell .readonly-lines-header {
  display: none;
  grid-column: 1;
  grid-template-columns: 32px minmax(150px, 1.3fr) 72px 44px minmax(130px, .7fr) minmax(100px, .9fr) minmax(100px, 1fr) minmax(140px, 176px);
  gap: 10px;
  align-items: center;
  min-height: 38px;
  padding: 0 10px;
  border-bottom: 1px solid var(--wo-border);
  color: var(--wo-muted);
  font-size: 11px;
  font-weight: 700;
}

body.ops-writeoffs-shell #documentSection.readonly.has-lines .readonly-lines-header {
  display: grid;
}

body.ops-writeoffs-shell #documentSection.has-locked-lines .readonly-lines-header {
  display: grid;
}

body.ops-writeoffs-shell .approved-line-badge {
  border: 1px solid #b9d8c4;
  background: #eff8f2;
  color: #19623a;
  font-weight: 700;
}

body.ops-writeoffs-shell #documentSection.readonly .lines-list {
  gap: 0;
}

body.ops-writeoffs-shell #documentErrors,
body.ops-writeoffs-shell #documentRiskReview,
body.ops-writeoffs-shell #emptyLines {
  grid-column: 1;
}

body.ops-writeoffs-shell .document-risk-review {
  display: grid;
  gap: 10px;
  padding: 13px 15px;
  border: 1px solid #e5c77c;
  border-radius: 7px;
  background: #fffaf0;
  color: #5f4510;
}

body.ops-writeoffs-shell .document-risk-review.hidden {
  display: none;
}

body.ops-writeoffs-shell .document-risk-review p {
  margin: 3px 0 0;
  color: #735b28;
  font-size: 12px;
  line-height: 1.45;
}

body.ops-writeoffs-shell .document-risk-review ul {
  display: grid;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}

body.ops-writeoffs-shell .document-risk-review li {
  display: grid;
  gap: 2px;
  padding-top: 7px;
  border-top: 1px solid rgba(151, 112, 25, .18);
  font-size: 12px;
  line-height: 1.4;
}

body.ops-writeoffs-shell .document-risk-review li strong {
  color: #4f390c;
  font-size: 12px;
}

body.ops-writeoffs-shell .document-risk-review .document-risk-more {
  color: #735b28;
  font-weight: 700;
}

body.ops-writeoffs-shell .document-risk-review .document-risk-suggestion {
  color: #5f4510;
  font-weight: 750;
}

body.ops-writeoffs-shell #writeoffsModule .document-risk-fix,
body.ops-writeoffs-shell #writeoffsModule .line-risk-fix {
  width: fit-content;
  min-height: 32px;
  margin-top: 4px;
  padding: 5px 9px;
  border: 1px solid #c99d2b;
  border-radius: 6px;
  background: #fff;
  color: #65480a;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.25;
}

body.ops-writeoffs-shell #writeoffsModule .document-risk-fix:hover,
body.ops-writeoffs-shell #writeoffsModule .line-risk-fix:hover {
  border-color: #a77c10;
  background: #fff5d9;
}

body.ops-writeoffs-shell .line-card {
  overflow: hidden;
  border: 1px solid var(--wo-border);
  border-radius: 8px;
  padding: 0;
  background: #fff;
}

body.ops-writeoffs-shell .line-card.has-validation-error {
  border-color: #dfa19c;
  box-shadow: inset 3px 0 0 #c83f35;
}

body.ops-writeoffs-shell .line-card.has-validation-error .line-card-head {
  background: #fff9f8;
}

body.ops-writeoffs-shell .line-card.has-risk-warning,
body.ops-writeoffs-shell .readonly-line-card.has-risk-warning {
  box-shadow: inset 3px 0 0 #d5a72e;
}

body.ops-writeoffs-shell .readonly-line-card {
  display: grid;
  grid-template-columns: 32px minmax(150px, 1.3fr) 72px 44px minmax(130px, .7fr) minmax(100px, .9fr) minmax(100px, 1fr) minmax(140px, 176px);
  align-items: center;
  gap: 10px;
  padding: 13px 10px;
  border: 0;
  border-bottom: 1px solid var(--wo-border);
  border-radius: 0;
  background: #fff;
  box-shadow: none;
}

body.ops-writeoffs-shell .readonly-line-index {
  color: var(--wo-muted);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}

body.ops-writeoffs-shell .readonly-line-head {
  min-width: 0;
}

body.ops-writeoffs-shell .readonly-line-head h4 {
  margin: 0;
  overflow-wrap: anywhere;
  color: var(--wo-text);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
}

body.ops-writeoffs-shell .readonly-line-head p {
  display: none;
  margin: 3px 0 0;
  color: var(--wo-muted);
  font-size: 12px;
}

body.ops-writeoffs-shell .readonly-line-badges {
  margin-top: 4px;
}

body.ops-writeoffs-shell .readonly-line-cell {
  min-width: 0;
  overflow-wrap: anywhere;
  color: #34404c;
  font-size: 13px;
  line-height: 1.35;
}

body.ops-writeoffs-shell .readonly-line-reason {
  grid-column: auto;
}

body.ops-writeoffs-shell .readonly-line-quantity {
  color: var(--wo-text);
  font-variant-numeric: tabular-nums;
}

body.ops-writeoffs-shell .readonly-line-quantity strong,
body.ops-writeoffs-shell .readonly-line-quantity small {
  display: block;
}

body.ops-writeoffs-shell .readonly-line-quantity strong {
  font-size: 13px;
  font-weight: 750;
}

body.ops-writeoffs-shell .readonly-line-quantity small {
  margin-top: 3px;
  color: var(--wo-muted);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.3;
}

body.ops-writeoffs-shell .readonly-line-quantity .readonly-line-price-source {
  white-space: normal;
}

body.ops-writeoffs-shell .readonly-line-toggle,
body.ops-writeoffs-shell .readonly-line-mobile-details {
  display: none;
}

body.ops-writeoffs-shell .line-card-head {
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--wo-border);
  background: var(--wo-surface-subtle);
}

body.ops-writeoffs-shell .line-title {
  font-size: 15px;
  line-height: 1.35;
}

body.ops-writeoffs-shell .line-subtitle {
  margin-top: 2px;
  font-size: 12px;
}

body.ops-writeoffs-shell .line-badges {
  margin-top: 5px;
}

body.ops-writeoffs-shell .line-validation-badge {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 3px 7px;
  border: 1px solid #efb7b1;
  border-radius: 999px;
  background: #fff1f0;
  color: #9f2f27;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
}

body.ops-writeoffs-shell .line-risk-badge {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border: 1px solid #e6c46b;
  background: #fff8e5;
  color: #73520b;
  font-weight: 800;
  line-height: 1.2;
}

body.ops-writeoffs-shell .line-card .remove-line {
  width: auto;
  min-height: 34px;
  padding: 6px 9px;
  border-color: #f0b9b5;
  color: var(--wo-red);
  font-size: 12px;
}

body.ops-writeoffs-shell .line-card .remove-line:hover {
  border-color: #e49a94;
  background: var(--wo-red-soft);
  color: var(--wo-red);
}

body.ops-writeoffs-shell .line-card-body {
  gap: 0;
  margin: 0;
  padding: 14px;
}

body.ops-writeoffs-shell .line-section {
  gap: 10px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

body.ops-writeoffs-shell .line-grid-main {
  grid-template-columns: minmax(120px, .42fr) minmax(170px, .58fr) minmax(210px, .78fr);
  align-items: start;
}

body.ops-writeoffs-shell .line-field {
  display: grid;
  min-width: 0;
  gap: 6px;
}

body.ops-writeoffs-shell .line-field > label {
  min-width: 0;
}

body.ops-writeoffs-shell #writeoffsModule input.has-risk-warning {
  border-color: #c99d2b;
  background: #fffdf6;
  box-shadow: 0 0 0 3px rgba(213, 167, 46, .13);
}

body.ops-writeoffs-shell .line-field-warning {
  display: grid;
  gap: 4px;
  padding: 8px 9px;
  border: 1px solid #e5c77c;
  border-radius: 6px;
  background: #fffaf0;
  color: #65480a;
  font-size: 11px;
  font-weight: 650;
  line-height: 1.4;
}

body.ops-writeoffs-shell .line-field-warning.hidden {
  display: none;
}

body.ops-writeoffs-shell .line-price-source,
body.ops-writeoffs-shell .line-price-total,
body.ops-writeoffs-shell .line-quantity-hint {
  display: block;
  margin-top: 5px;
  color: var(--wo-muted);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.35;
}

body.ops-writeoffs-shell .line-quantity-hint {
  min-height: 17px;
}

body.ops-writeoffs-shell .line-price-total {
  min-height: 17px;
  color: var(--wo-text);
  font-weight: 700;
}

body.ops-writeoffs-shell .summary-cost-value {
  display: block;
  margin-top: 2px;
  color: var(--wo-green-dark);
  font-size: 11px;
  font-weight: 750;
  white-space: nowrap;
}

body.ops-writeoffs-shell .summary-missing-price {
  display: block;
  margin-top: 2px;
  color: #8a5a00;
  font-size: 11px;
  line-height: 1.3;
}

body.ops-writeoffs-shell .line-grid .wide {
  grid-column: auto;
}

body.ops-writeoffs-shell .line-grid-main > label.wide {
  grid-column: 1 / span 2;
}

body.ops-writeoffs-shell .line-grid-main > .line-photo-field {
  grid-column: 3;
}

body.ops-writeoffs-shell .line-comment {
  min-height: 78px;
}

body.ops-writeoffs-shell .line-photo-field {
  display: grid;
  min-width: 0;
  gap: 8px;
  align-content: start;
}

body.ops-writeoffs-shell .line-photo-heading {
  display: flex;
  min-height: 22px;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

body.ops-writeoffs-shell .line-photo-heading > div {
  display: flex;
  align-items: baseline;
  gap: 7px;
}

body.ops-writeoffs-shell .line-photo-heading strong {
  color: var(--wo-text);
  font-size: 13px;
}

body.ops-writeoffs-shell .line-photo-heading span {
  color: var(--wo-muted);
  font-size: 11px;
  font-weight: 600;
}

body.ops-writeoffs-shell .line-photo-heading .line-photo-count {
  color: var(--wo-success-strong);
  font-variant-numeric: tabular-nums;
}

body.ops-writeoffs-shell .line-photo-actions button {
  width: auto;
  min-height: 38px;
  padding: 7px 11px;
  font-size: 12px;
}

body.ops-writeoffs-shell .line-photo-camera {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

body.ops-writeoffs-shell .line-photo-camera-icon {
  position: relative;
  display: inline-block;
  width: 16px;
  height: 12px;
  flex: 0 0 16px;
  border: 1.5px solid currentColor;
  border-radius: 3px;
}

body.ops-writeoffs-shell .line-photo-camera-icon::before {
  position: absolute;
  top: -4px;
  left: 3px;
  width: 7px;
  height: 4px;
  border: 1.5px solid currentColor;
  border-bottom: 0;
  border-radius: 2px 2px 0 0;
  content: '';
}

body.ops-writeoffs-shell .line-photo-camera-icon::after {
  position: absolute;
  top: 2px;
  left: 5px;
  width: 4px;
  height: 4px;
  border: 1.5px solid currentColor;
  border-radius: 50%;
  content: '';
}

body.ops-writeoffs-shell .line-photo-gallery {
  display: flex;
  min-width: 0;
  flex-wrap: wrap;
  gap: 8px;
}

body.ops-writeoffs-shell .line-photo-thumb-wrap {
  position: relative;
  width: 72px;
  height: 72px;
}

body.ops-writeoffs-shell .line-photo-thumb,
body.ops-writeoffs-shell .readonly-line-photo {
  position: relative;
  display: grid;
  overflow: hidden;
  flex: 0 0 auto;
  width: 72px;
  min-width: 72px;
  height: 72px;
  min-height: 72px;
  place-items: center;
  padding: 0;
  border: 1px solid var(--wo-border-strong);
  border-radius: 7px;
  background: var(--wo-surface-subtle);
  color: var(--wo-muted);
  box-shadow: none;
}

body.ops-writeoffs-shell .line-photo-thumb img,
body.ops-writeoffs-shell .readonly-line-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  object-fit: cover;
  transition: opacity .16s ease;
}

body.ops-writeoffs-shell .line-photo-thumb.is-loaded img,
body.ops-writeoffs-shell .readonly-line-photo.is-loaded img {
  opacity: 1;
}

body.ops-writeoffs-shell .line-photo-thumb.has-error,
body.ops-writeoffs-shell .readonly-line-photo.has-error {
  border-color: #e7b5b0;
  background: #fff4f3;
  color: #9f2f27;
}

body.ops-writeoffs-shell .line-photo-thumb-remove {
  position: absolute;
  top: -6px;
  right: -6px;
  z-index: 2;
  display: grid;
  width: 24px;
  min-width: 24px;
  height: 24px;
  min-height: 24px;
  place-items: center;
  padding: 0 0 2px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #9f2f27;
  color: #fff;
  font-size: 17px;
  line-height: 1;
  box-shadow: 0 2px 8px rgba(15, 23, 42, .2);
}

body.ops-writeoffs-shell .line-photo-preview-loading,
body.ops-writeoffs-shell .readonly-line-photo-loading {
  padding: 4px;
  font-size: 10px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
}

body.ops-writeoffs-shell .line-photo-actions {
  display: flex;
  min-width: 0;
  flex-wrap: wrap;
  gap: 6px;
}

body.ops-writeoffs-shell .line-photo-status {
  min-height: 0;
  margin: 0;
  font-size: 11px;
  line-height: 1.35;
}

body.ops-writeoffs-shell .line-photo-status:empty {
  display: none;
}

body.ops-writeoffs-shell .line-photo-status-loading {
  color: #236b42;
}

body.ops-writeoffs-shell .line-photo-status-error {
  color: #9f2f27;
}

body.ops-writeoffs-shell .readonly-line-head > div:first-child {
  min-width: 0;
}

body.ops-writeoffs-shell .readonly-line-photo-gallery {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
}

body.ops-writeoffs-shell .readonly-line-photo-gallery.is-empty {
  color: var(--wo-muted);
}

body.ops-writeoffs-shell .readonly-line-photo {
  width: 52px;
  min-width: 52px;
  height: 44px;
  min-height: 44px;
}

body.ops-writeoffs-shell .readonly-line-photo-more {
  display: grid;
  width: 44px;
  min-width: 44px;
  height: 44px;
  min-height: 44px;
  place-items: center;
  padding: 0;
  border: 1px solid var(--wo-border-strong);
  border-radius: 7px;
  background: var(--wo-surface-subtle);
  color: var(--wo-success-strong);
  font-size: 13px;
  font-weight: 800;
}

body.ops-writeoffs-shell .line-photo-more {
  display: grid;
  width: 54px;
  min-width: 54px;
  height: 72px;
  min-height: 72px;
  place-items: center;
  padding: 0;
  border: 1px solid var(--wo-border-strong);
  border-radius: 7px;
  background: var(--wo-surface-subtle);
  color: var(--wo-success-strong);
  font-size: 13px;
  font-weight: 800;
}

body.ops-writeoffs-shell .document-row-photo-count {
  color: var(--wo-success-strong);
  font-weight: 700;
}

body.ops-writeoffs-shell .writeoff-photo-dialog {
  width: min(920px, calc(100vw - 32px));
  max-width: 920px;
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: #fff;
  color: var(--wo-text);
  box-shadow: 0 24px 70px rgba(15, 23, 42, .28);
}

body.ops-writeoffs-shell .writeoff-photo-dialog::backdrop {
  background: rgba(15, 23, 42, .72);
}

body.ops-writeoffs-shell .writeoff-photo-dialog-content {
  display: grid;
  max-height: calc(100dvh - 32px);
  grid-template-rows: auto minmax(0, 1fr);
}

body.ops-writeoffs-shell .writeoff-photo-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--wo-border);
}

body.ops-writeoffs-shell .writeoff-photo-dialog-head h2 {
  margin: 2px 0 0;
  font-size: clamp(18px, 2vw, 24px);
}

body.ops-writeoffs-shell .writeoff-photo-dialog-meta {
  max-width: min(720px, calc(100vw - 140px));
  margin: 4px 0 0;
  color: var(--wo-muted);
  font-size: 12px;
  line-height: 1.4;
}

body.ops-writeoffs-shell .writeoff-photo-dialog-head .icon-button {
  width: 40px;
  min-width: 40px;
  height: 40px;
  min-height: 40px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--wo-muted);
  font-size: 30px;
  font-weight: 400;
}

body.ops-writeoffs-shell .writeoff-photo-dialog-stage {
  position: relative;
  display: grid;
  min-height: min(68vh, 620px);
  place-items: center;
  overflow: auto;
  padding: 16px;
  background: #18212b;
  color: #fff;
}

body.ops-writeoffs-shell .writeoff-photo-dialog-loading {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: rgba(255, 255, 255, .9);
  font-size: 13px;
  font-weight: 650;
}

body.ops-writeoffs-shell .writeoff-photo-dialog-loading::before {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, .32);
  border-top-color: #fff;
  border-radius: 50%;
  content: '';
  animation: wo-spin .8s linear infinite;
}

@keyframes wo-spin {
  to { transform: rotate(360deg); }
}

body.ops-writeoffs-shell .writeoff-photo-dialog-nav {
  position: absolute;
  top: 50%;
  z-index: 2;
  display: grid;
  width: 48px;
  min-width: 48px;
  height: 48px;
  min-height: 48px;
  place-items: center;
  padding: 0 0 5px;
  border: 1px solid rgba(255, 255, 255, .42);
  border-radius: 50%;
  background: rgba(15, 23, 42, .76);
  color: #fff;
  font-size: 38px;
  font-weight: 300;
  line-height: 1;
  box-shadow: 0 6px 24px rgba(0, 0, 0, .24);
  transform: translateY(-50%);
}

body.ops-writeoffs-shell .writeoff-photo-dialog-nav.is-previous {
  left: 16px;
}

body.ops-writeoffs-shell .writeoff-photo-dialog-nav.is-next {
  right: 16px;
}

body.ops-writeoffs-shell .writeoff-photo-dialog-nav:disabled {
  opacity: .24;
}

body.ops-writeoffs-shell .writeoff-photo-dialog-counter {
  position: absolute;
  right: 50%;
  bottom: 12px;
  z-index: 2;
  padding: 5px 9px;
  border: 1px solid rgba(255, 255, 255, .2);
  border-radius: 999px;
  background: rgba(15, 23, 42, .78);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  transform: translateX(50%);
}

body.ops-writeoffs-shell .writeoff-photo-dialog-counter:empty {
  display: none;
}

body.ops-writeoffs-shell .writeoff-photo-dialog-stage img {
  display: none;
  max-width: 100%;
  max-height: calc(100dvh - 130px);
  object-fit: contain;
}

body.ops-writeoffs-shell .writeoff-photo-dialog-stage img.is-loaded {
  display: block;
}

body.ops-writeoffs-shell .writeoff-camera-dialog {
  width: min(760px, calc(100vw - 24px));
  max-width: 760px;
  max-height: calc(100dvh - 24px);
  margin: auto;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: #fff;
  color: var(--wo-text);
  box-shadow: 0 24px 70px rgba(15, 23, 42, .32);
}

body.ops-writeoffs-shell .writeoff-camera-dialog::backdrop {
  background: rgba(15, 23, 42, .8);
}

body.ops-writeoffs-shell .writeoff-camera-dialog-content {
  display: grid;
  max-height: calc(100dvh - 24px);
  grid-template-rows: auto minmax(240px, 1fr) auto auto;
  overflow: hidden;
}

body.ops-writeoffs-shell .writeoff-camera-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--wo-border);
}

body.ops-writeoffs-shell .writeoff-camera-dialog-head h2 {
  margin: 2px 0 0;
  font-size: 20px;
}

body.ops-writeoffs-shell .writeoff-camera-dialog-count {
  margin: 3px 0 0;
  color: var(--wo-muted);
  font-size: 12px;
  font-weight: 700;
}

body.ops-writeoffs-shell .writeoff-camera-dialog-head .icon-button {
  width: 40px;
  min-width: 40px;
  height: 40px;
  min-height: 40px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--wo-muted);
  font-size: 30px;
  font-weight: 400;
}

body.ops-writeoffs-shell .writeoff-camera-stage {
  position: relative;
  display: grid;
  min-height: 320px;
  place-items: center;
  overflow: hidden;
  background: #101820;
}

body.ops-writeoffs-shell .writeoff-camera-stage video {
  width: 100%;
  height: 100%;
  max-height: 58dvh;
  object-fit: contain;
}

body.ops-writeoffs-shell .writeoff-camera-status {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(15, 23, 42, .72);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.45;
  text-align: center;
}

body.ops-writeoffs-shell .writeoff-camera-thumbnails {
  display: flex;
  min-height: 0;
  gap: 8px;
  overflow-x: auto;
  padding: 10px 14px;
  border-top: 1px solid var(--wo-border);
  background: var(--wo-surface-subtle);
}

body.ops-writeoffs-shell .writeoff-camera-thumbnails:empty {
  display: none;
}

body.ops-writeoffs-shell .writeoff-camera-thumbnail {
  position: relative;
  width: 58px;
  min-width: 58px;
  height: 58px;
}

body.ops-writeoffs-shell .writeoff-camera-thumbnail img {
  width: 100%;
  height: 100%;
  border-radius: 6px;
  object-fit: cover;
}

body.ops-writeoffs-shell .writeoff-camera-thumbnail button {
  position: absolute;
  top: -5px;
  right: -5px;
  display: grid;
  width: 22px;
  min-width: 22px;
  height: 22px;
  min-height: 22px;
  place-items: center;
  padding: 0 0 2px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #9f2f27;
  color: #fff;
  line-height: 1;
}

body.ops-writeoffs-shell .writeoff-camera-actions {
  display: grid;
  grid-template-columns: minmax(100px, 1fr) auto minmax(100px, 1fr);
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-top: 1px solid var(--wo-border);
}

body.ops-writeoffs-shell .writeoff-camera-actions > :last-child {
  justify-self: stretch;
}

body.ops-writeoffs-shell .writeoff-camera-shutter {
  display: grid;
  width: 64px;
  min-width: 64px;
  height: 64px;
  min-height: 64px;
  place-items: center;
  padding: 0;
  border: 3px solid #d8e1e9;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 10px rgba(15, 23, 42, .16);
}

body.ops-writeoffs-shell .writeoff-camera-shutter-surface {
  position: relative;
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border-radius: 50%;
  background: var(--wo-success-strong);
  transition: transform .12s ease, background-color .12s ease;
}

body.ops-writeoffs-shell .writeoff-camera-shutter-icon {
  position: relative;
  display: block;
  width: 23px;
  height: 17px;
  border: 2px solid #fff;
  border-radius: 4px;
}

body.ops-writeoffs-shell .writeoff-camera-shutter-icon::before {
  position: absolute;
  top: -6px;
  left: 4px;
  width: 10px;
  height: 5px;
  border: 2px solid #fff;
  border-bottom: 0;
  border-radius: 3px 3px 0 0;
  content: '';
}

body.ops-writeoffs-shell .writeoff-camera-shutter-icon::after {
  position: absolute;
  top: 3px;
  left: 7px;
  width: 6px;
  height: 6px;
  border: 2px solid #fff;
  border-radius: 50%;
  content: '';
}

body.ops-writeoffs-shell .writeoff-camera-shutter:active:not(:disabled) .writeoff-camera-shutter-surface {
  transform: scale(.9);
}

body.ops-writeoffs-shell .writeoff-camera-shutter:disabled {
  opacity: .42;
}

body.ops-writeoffs-shell .line-error,
body.ops-writeoffs-shell .form-error {
  margin: 10px 14px 14px;
  padding: 10px 12px;
  border: 1px solid #f4c7c3;
  border-radius: 6px;
  background: var(--wo-red-soft);
  color: #912018;
  font-size: 13px;
}

body.ops-writeoffs-shell .line-error {
  margin-top: 0;
  padding-block: 8px;
}

body.ops-writeoffs-shell #documentFormError,
body.ops-writeoffs-shell #documentErrors {
  margin-inline: 0;
}

body.ops-writeoffs-shell .section-head {
  align-items: center;
  margin-bottom: 16px;
}

body.ops-writeoffs-shell .section-head > div {
  min-width: 0;
}

body.ops-writeoffs-shell .section-head .icon-button {
  flex: 0 0 auto;
  width: 40px;
  min-width: 40px;
  min-height: 40px;
  padding: 0;
}

body.ops-writeoffs-shell .section-head-actions {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: flex-end;
}

body.ops-writeoffs-shell .filter-reset-button {
  min-height: 40px;
  padding: 8px 12px;
  color: var(--wo-muted);
}

body.ops-writeoffs-shell .summary-advanced-filters-toggle {
  display: none;
}

body.ops-writeoffs-shell #managerTab .filters,
body.ops-writeoffs-shell #summaryTab .filters {
  display: grid;
  align-items: end;
  margin: 0 -20px;
  padding: 14px 20px;
  border-block: 1px solid var(--wo-border);
  background: var(--wo-surface-subtle);
}

body.ops-writeoffs-shell #managerTab .filters {
  grid-template-columns: minmax(180px, .8fr) minmax(180px, .6fr) minmax(180px, .6fr);
}

body.ops-writeoffs-shell #summaryTab .filters {
  grid-template-columns: repeat(3, minmax(170px, 1fr));
}

body.ops-writeoffs-shell .writeoffs-cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  margin: 0;
  border-bottom: 1px solid var(--wo-border);
}

body.ops-writeoffs-shell .documents-load-status {
  margin: 12px 0 0;
  border-radius: 6px;
  border-color: var(--wo-border);
  background: var(--wo-surface-subtle);
  color: var(--wo-muted);
}

body.ops-writeoffs-shell .documents-load-status-loading {
  border-color: #bbdfc8;
  background: var(--wo-green-soft);
  color: var(--wo-green-dark);
}

body.ops-writeoffs-shell .documents-load-status-error {
  border-color: #f2b8b5;
  background: var(--wo-red-soft);
  color: var(--wo-red);
}

body.ops-writeoffs-shell .documents-load-status button {
  width: auto;
  min-height: 34px;
  padding: 6px 11px;
}

body.ops-writeoffs-shell .documents-loading-placeholder {
  gap: 0;
  overflow: hidden;
  border: 1px solid var(--wo-border);
  border-radius: 8px;
}

body.ops-writeoffs-shell .documents-loading-placeholder span {
  min-height: 62px;
  border: 0;
  border-bottom: 1px solid var(--wo-border);
  border-radius: 0;
  background: var(--wo-surface-subtle);
}

body.ops-writeoffs-shell .documents-loading-placeholder span:last-child {
  border-bottom: 0;
}

body.ops-writeoffs-shell .writeoffs-cards > article,
body.ops-writeoffs-shell .writeoffs-cards > .summary-card {
  display: grid;
  gap: 3px;
  min-width: 0;
  padding: 15px 16px;
  border: 0;
  border-right: 1px solid var(--wo-border);
  border-radius: 0;
  background: #fff;
}

body.ops-writeoffs-shell .writeoffs-cards > article:last-child,
body.ops-writeoffs-shell .writeoffs-cards > .summary-card:last-child {
  border-right: 0;
}

body.ops-writeoffs-shell .writeoffs-cards span {
  color: var(--wo-muted);
  font-size: 12px;
}

body.ops-writeoffs-shell .writeoffs-cards strong {
  color: var(--wo-text);
  font-size: 22px;
  line-height: 1.2;
}

body.ops-writeoffs-shell .documents-list {
  gap: 0;
  margin-top: 0;
}

body.ops-writeoffs-shell .documents-period-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

body.ops-writeoffs-shell .documents-period-modes {
  display: inline-grid;
  grid-template-columns: repeat(3, minmax(82px, 1fr));
  padding: 3px;
  border: 1px solid var(--wo-border);
  border-radius: 7px;
  background: var(--wo-surface-subtle);
}

body.ops-writeoffs-shell .documents-period-modes button {
  min-height: 36px;
  padding: 6px 12px;
  border: 0;
  background: transparent;
  color: var(--wo-muted);
  font-size: 13px;
  font-weight: 750;
}

body.ops-writeoffs-shell .documents-period-modes button.is-active {
  background: var(--wo-dark);
  color: #fff;
}

body.ops-writeoffs-shell .documents-period-navigation {
  display: grid;
  grid-template-columns: 38px minmax(150px, auto) 38px auto;
  align-items: center;
  gap: 6px;
}

body.ops-writeoffs-shell .documents-period-navigation .icon-button {
  width: 38px;
  min-width: 38px;
  min-height: 38px;
  padding: 0;
  border: 1px solid var(--wo-border-strong);
  background: #fff;
  color: var(--wo-text);
  font-size: 24px;
  line-height: 1;
}

body.ops-writeoffs-shell .documents-period-navigation strong {
  min-width: 0;
  text-align: center;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}

body.ops-writeoffs-shell .documents-period-navigation .secondary {
  min-height: 38px;
  padding: 7px 11px;
  font-size: 13px;
}

body.ops-writeoffs-shell .documents-calendar {
  min-width: 0;
  margin-bottom: 12px;
  padding: 0 0 9px;
  overflow: hidden;
  border: 1px solid var(--wo-border);
  border-radius: 8px;
  background: var(--wo-surface-subtle);
}

body.ops-writeoffs-shell .documents-calendar-table-scroll {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-x: contain;
  scrollbar-color: var(--wo-border-strong) transparent;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  touch-action: pan-x pan-y;
  -webkit-overflow-scrolling: touch;
}

body.ops-writeoffs-shell .documents-calendar-table-scroll:focus-visible {
  outline: 2px solid var(--wo-green);
  outline-offset: -2px;
}

body.ops-writeoffs-shell .documents-calendar-table-scroll::-webkit-scrollbar {
  height: 9px;
}

body.ops-writeoffs-shell .documents-calendar-table-scroll::-webkit-scrollbar-track {
  background: var(--wo-surface-subtle);
}

body.ops-writeoffs-shell .documents-calendar-table-scroll::-webkit-scrollbar-thumb {
  border: 2px solid var(--wo-surface-subtle);
  border-radius: 999px;
  background: var(--wo-border-strong);
}

body.ops-writeoffs-shell .documents-calendar-table {
  width: max-content;
  min-width: 100%;
  border-spacing: 0;
  border-collapse: separate;
  color: var(--wo-text);
}

body.ops-writeoffs-shell .documents-calendar-table th,
body.ops-writeoffs-shell .documents-calendar-table td {
  padding: 0;
  border-right: 1px solid var(--wo-border);
  border-bottom: 1px solid var(--wo-border);
  background: #fff;
  vertical-align: stretch;
}

body.ops-writeoffs-shell .documents-calendar-table tr > :last-child {
  border-right: 0;
}

body.ops-writeoffs-shell .documents-calendar-table tfoot tr > * {
  border-bottom: 0;
  border-top: 2px solid var(--wo-border-strong);
}

body.ops-writeoffs-shell .documents-calendar-store-column {
  position: sticky;
  left: 0;
  z-index: 2;
  width: 190px;
  min-width: 190px;
  max-width: 190px;
  padding: 10px 12px !important;
  background: #fff !important;
  box-shadow: 8px 0 12px -12px rgba(15, 25, 40, .72);
  text-align: left;
}

body.ops-writeoffs-shell .documents-calendar-table thead .documents-calendar-store-column {
  z-index: 3;
  background: var(--wo-surface-subtle) !important;
  color: var(--wo-muted);
  font-size: 11px;
  text-transform: uppercase;
}

body.ops-writeoffs-shell .documents-calendar-store-column strong,
body.ops-writeoffs-shell .documents-calendar-store-column span,
body.ops-writeoffs-shell .documents-calendar-store-column small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.ops-writeoffs-shell .documents-calendar-store-column strong {
  font-size: 12px;
  line-height: 1.3;
}

body.ops-writeoffs-shell .documents-calendar-store-column span,
body.ops-writeoffs-shell .documents-calendar-store-column small {
  margin-top: 3px;
  color: var(--wo-muted);
  font-size: 10px;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}

body.ops-writeoffs-shell .documents-calendar-date-column {
  width: 104px;
  min-width: 104px;
  height: 50px;
  padding: 7px 8px !important;
  background: var(--wo-surface-subtle) !important;
  text-align: center;
}

body.ops-writeoffs-shell .documents-calendar-date-column span,
body.ops-writeoffs-shell .documents-calendar-date-column strong {
  display: block;
}

body.ops-writeoffs-shell .documents-calendar-date-column span {
  color: var(--wo-muted);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
}

body.ops-writeoffs-shell .documents-calendar-date-column strong {
  margin-top: 2px;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}

body.ops-writeoffs-shell .documents-calendar-date-column.is-today {
  color: var(--wo-green-dark);
  box-shadow: inset 0 -3px var(--wo-green);
}

body.ops-writeoffs-shell .documents-calendar-cell-button {
  position: relative;
  display: grid;
  width: 100%;
  min-width: 103px;
  min-height: 78px;
  align-content: center;
  gap: 3px;
  padding: 8px;
  border: 0;
  border-radius: 0;
  background: #fff;
  color: var(--wo-text);
  text-align: left;
}

body.ops-writeoffs-shell .documents-calendar-cell-button.is-opening {
  box-shadow: inset 0 0 0 2px rgba(24, 122, 67, .55);
}

body.ops-writeoffs-shell .documents-calendar-cell-button.is-opening > :not(.documents-calendar-cell-loading) {
  opacity: .18;
}

body.ops-writeoffs-shell .documents-calendar-cell-loading {
  position: absolute;
  inset: 0;
  display: grid;
  z-index: 1;
  align-items: center;
  padding: 8px;
  color: var(--wo-green-dark);
  font-size: 11px;
  font-weight: 850;
  text-align: center;
}

body.ops-writeoffs-shell .documents-calendar-cell-button:disabled {
  cursor: default;
  opacity: 1;
}

body.ops-writeoffs-shell .documents-calendar-cell-button.has-documents:not(:disabled) {
  background: var(--wo-green-soft);
  cursor: pointer;
}

body.ops-writeoffs-shell .documents-calendar-cell-button.has-documents:hover:not(:disabled) {
  box-shadow: inset 0 0 0 2px rgba(24, 122, 67, .5);
}

body.ops-writeoffs-shell .documents-calendar-cell-button.has-only-cancelled {
  background: #f4f7fa;
}

body.ops-writeoffs-shell .documents-calendar-cell-button.has-only-cancelled .documents-calendar-cell-count {
  color: var(--wo-muted);
}

body.ops-writeoffs-shell .documents-calendar-cell-button.has-incomplete {
  background: var(--wo-amber-soft);
}

body.ops-writeoffs-shell .documents-calendar-cell-button.has-risk {
  background: var(--wo-red-soft);
}

body.ops-writeoffs-shell .documents-calendar-cell-button.is-today {
  box-shadow: inset 0 -3px var(--wo-green);
}

body.ops-writeoffs-shell .documents-calendar-cell-count,
body.ops-writeoffs-shell .documents-calendar-cell-button > strong,
body.ops-writeoffs-shell .documents-calendar-risk,
body.ops-writeoffs-shell .documents-calendar-incomplete {
  overflow: hidden;
  font-size: 10px;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.ops-writeoffs-shell .documents-calendar-cell-count {
  color: var(--wo-green-dark);
  font-weight: 800;
}

body.ops-writeoffs-shell .documents-calendar-cell-button > strong {
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}

body.ops-writeoffs-shell .documents-calendar-risk,
body.ops-writeoffs-shell .documents-calendar-incomplete {
  color: #9a4f0b;
  font-weight: 800;
}

body.ops-writeoffs-shell .documents-calendar-risk {
  color: var(--wo-red);
}

body.ops-writeoffs-shell .documents-calendar-cell-empty {
  color: #c6ced8;
  font-size: 12px;
  text-align: center;
}

body.ops-writeoffs-shell .documents-calendar-total-row .documents-calendar-store-column {
  background: #f4f7fa !important;
}

body.ops-writeoffs-shell .documents-calendar-total-row .documents-calendar-cell-button {
  font-weight: 750;
}

body.ops-writeoffs-shell .documents-calendar-total-row .documents-calendar-cell-button:not(.has-documents) {
  background: #f4f7fa;
}

body.ops-writeoffs-shell .documents-calendar-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin-top: 9px;
  padding: 0 3px;
  color: var(--wo-muted);
  font-size: 11px;
  font-weight: 650;
}

body.ops-writeoffs-shell .documents-calendar-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

body.ops-writeoffs-shell .documents-calendar-legend i {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 2px;
  background: var(--wo-green-soft);
  box-shadow: inset 0 0 0 1px rgba(24, 122, 67, .32);
}

body.ops-writeoffs-shell .documents-calendar-legend i.has-incomplete {
  background: var(--wo-amber-soft);
  box-shadow: inset 0 0 0 1px #d69e2e;
}

body.ops-writeoffs-shell .documents-calendar-legend i.has-risk {
  background: var(--wo-red-soft);
  box-shadow: inset 0 0 0 1px #d97970;
}

body.ops-writeoffs-shell .documents-filters {
  grid-template-columns: minmax(180px, 280px);
  margin-bottom: 12px;
}

body.ops-writeoffs-shell .documents-workspace {
  gap: 14px;
}

body.ops-writeoffs-shell .documents-section {
  gap: 0;
  overflow: hidden;
  padding: 0;
  border: 1px solid var(--wo-border);
  border-radius: 8px;
  background: #fff;
}

body.ops-writeoffs-shell .documents-section-head {
  align-items: center;
  padding: 12px 14px;
  border-bottom: 1px solid var(--wo-border);
  background: var(--wo-surface-subtle);
}

body.ops-writeoffs-shell .documents-section-head h3 {
  margin: 0 0 2px;
  font-size: 15px;
}

body.ops-writeoffs-shell .documents-section-head p {
  color: var(--wo-muted);
  font-size: 12px;
  line-height: 1.35;
}

body.ops-writeoffs-shell .documents-section-count {
  min-width: 34px;
  min-height: 28px;
  padding: 3px 9px;
  border: 1px solid var(--wo-border);
  border-radius: 999px;
  background: #fff;
  color: var(--wo-text);
  font-size: 12px;
}

body.ops-writeoffs-shell .documents-section-list {
  gap: 0;
}

body.ops-writeoffs-shell .document-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  min-height: 78px;
  padding: 12px 14px;
  border: 0;
  border-bottom: 1px solid var(--wo-border);
  border-radius: 0;
  background: #fff;
  color: inherit;
}

body.ops-writeoffs-shell .document-row:last-child {
  border-bottom: 0;
}

body.ops-writeoffs-shell .document-row:hover {
  border-color: var(--wo-border);
  background: #f8fbf9;
  box-shadow: none;
  transform: none;
}

body.ops-writeoffs-shell .document-row.is-current {
  border-color: var(--wo-border);
  box-shadow: inset 3px 0 var(--wo-green);
  background: var(--wo-green-soft);
}

body.ops-writeoffs-shell .document-row.is-opening {
  border-color: var(--wo-border);
  box-shadow: inset 3px 0 var(--wo-green);
  background: var(--wo-green-soft);
  opacity: 1;
}

body.ops-writeoffs-shell .document-row.has-incomplete {
  box-shadow: inset 3px 0 #d69e2e;
}

body.ops-writeoffs-shell .document-row.has-incomplete:hover {
  box-shadow: inset 3px 0 #b7791f;
}

body.ops-writeoffs-shell .document-row.has-risk {
  box-shadow: inset 3px 0 var(--wo-red);
}

body.ops-writeoffs-shell .document-row.has-risk:hover {
  box-shadow: inset 3px 0 #912018;
}

body.ops-writeoffs-shell .document-row-anomaly {
  min-height: 22px;
  padding: 3px 8px;
  background: var(--wo-amber-soft);
  color: #8a4b0f;
  line-height: 1.2;
}

body.ops-writeoffs-shell .document-row-main {
  gap: 5px;
}

body.ops-writeoffs-shell .document-row-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
}

body.ops-writeoffs-shell .document-row-head strong {
  font-size: 15px;
  line-height: 1.3;
}

body.ops-writeoffs-shell .document-row-note {
  display: none;
}

body.ops-writeoffs-shell .document-row-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  color: var(--wo-muted);
  font-size: 12px;
}

body.ops-writeoffs-shell .document-row-meta span::before {
  width: 3px;
  height: 3px;
}

body.ops-writeoffs-shell .document-row-meta .document-row-amount {
  color: #166534;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
}

body.ops-writeoffs-shell .document-row-meta .document-row-incomplete {
  color: #9a5b13;
  font-weight: 700;
}

body.ops-writeoffs-shell .document-row-open {
  align-self: center;
  color: var(--wo-green);
  font-size: 13px;
  white-space: nowrap;
}

body.ops-writeoffs-shell .documents-empty-state {
  margin: 12px;
}

body.ops-writeoffs-shell .documents-more {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  border-top: 1px solid var(--wo-border);
  background: #fff;
}

body.ops-writeoffs-shell .documents-more button {
  width: auto;
  min-height: 36px;
  padding: 7px 12px;
  font-size: 13px;
}

body.ops-writeoffs-shell .documents-server-more {
  border: 1px solid var(--wo-border);
  border-radius: 6px;
}

body.ops-writeoffs-shell #summaryTab > .panel {
  overflow: hidden;
}

body.ops-writeoffs-shell #summaryTab .section-head {
  margin-bottom: 16px;
}

body.ops-writeoffs-shell #exportExcelButton {
  flex: 0 0 auto;
  min-height: 40px;
  padding: 8px 12px;
}

body.ops-writeoffs-shell #summaryTotals {
  margin-inline: -20px;
}

body.ops-writeoffs-shell .summary-workspace {
  gap: 14px;
  margin-top: 16px;
}

body.ops-writeoffs-shell .summary-primary-grid {
  gap: 14px;
}

body.ops-writeoffs-shell .summary-main-section,
body.ops-writeoffs-shell .summary-insight-grid section {
  min-width: 0;
  overflow: hidden;
  padding: 0;
  border: 1px solid var(--wo-border);
  border-radius: 8px;
  background: #fff;
}

body.ops-writeoffs-shell .summary-insight-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(360px, 100%), 1fr));
  gap: 14px;
}

body.ops-writeoffs-shell .summary-section-title {
  min-height: 58px;
  margin: 0;
  padding: 12px 14px;
  border-bottom: 1px solid var(--wo-border);
  background: var(--wo-surface-subtle);
}

body.ops-writeoffs-shell .summary-section-title h3 {
  margin: 0 0 2px;
  font-size: 15px;
}

body.ops-writeoffs-shell .summary-section-title p {
  color: var(--wo-muted);
  font-size: 12px;
  line-height: 1.35;
}

body.ops-writeoffs-shell .summary-section-title p:empty {
  display: none;
}

body.ops-writeoffs-shell .summary-data-table {
  width: 100%;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
}

body.ops-writeoffs-shell .summary-data-table table,
body.ops-writeoffs-shell .summary-data-table-compact table {
  display: table;
  width: 100%;
  min-width: 620px;
  border-collapse: collapse;
  table-layout: auto;
  font-size: 13px;
}

body.ops-writeoffs-shell .summary-data-table-compact table {
  min-width: 360px;
  table-layout: fixed;
}

body.ops-writeoffs-shell .summary-data-table thead {
  display: table-header-group;
}

body.ops-writeoffs-shell .summary-data-table tbody {
  display: table-row-group;
}

body.ops-writeoffs-shell .summary-data-table tr {
  display: table-row;
  margin: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

body.ops-writeoffs-shell .summary-data-table th,
body.ops-writeoffs-shell .summary-data-table td {
  display: table-cell;
  padding: 10px 12px;
  border: 0;
  border-bottom: 1px solid var(--wo-border);
  background: #fff;
  color: #34404c;
  text-align: left;
  vertical-align: top;
  overflow-wrap: normal;
  word-break: normal;
}

body.ops-writeoffs-shell .summary-data-table th {
  background: #f1f4f5;
  color: #55616d;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .02em;
  text-transform: uppercase;
  white-space: nowrap;
}

body.ops-writeoffs-shell .summary-data-table tbody tr:last-child td {
  border-bottom: 0;
}

body.ops-writeoffs-shell .summary-data-table tbody tr:hover td {
  background: #f8fbf9;
}

body.ops-writeoffs-shell .summary-line-reason,
body.ops-writeoffs-shell .summary-line-comment {
  display: block;
}

body.ops-writeoffs-shell .summary-document-open {
  width: auto;
  min-height: 34px;
  padding: 6px 10px;
  border: 1px solid #b8d2c2;
  border-radius: 6px;
  background: #fff;
  color: var(--wo-success-strong);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

body.ops-writeoffs-shell .summary-document-open:hover {
  border-color: var(--wo-success);
  background: var(--wo-green-soft);
}

body.ops-writeoffs-shell .summary-line-reason {
  color: #26333e;
  font-weight: 700;
}

body.ops-writeoffs-shell .summary-line-comment {
  max-width: 320px;
  margin-top: 3px;
  color: var(--wo-muted);
  font-size: 12px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

body.ops-writeoffs-shell .summary-data-table .mobile-cell-label {
  display: none;
}

body.ops-writeoffs-shell .summary-data-table .empty-state {
  margin: 12px;
}

body.ops-writeoffs-shell .summary-status {
  margin: 12px 0 0;
  padding: 10px 12px;
  border-radius: 6px;
  background: var(--wo-blue-soft);
  color: var(--wo-blue);
}

body.ops-writeoffs-shell .summary-status-error {
  background: var(--wo-red-soft);
  color: var(--wo-red);
}

body.ops-writeoffs-shell .summary-status-loading {
  background: var(--wo-green-soft);
  color: var(--wo-green-dark);
}

body.ops-writeoffs-shell #writeoffsStatus:empty,
body.ops-writeoffs-shell #summaryStatus:empty {
  display: none;
}

@media (max-width: 1100px) {
  body.ops-writeoffs-shell #documentSection {
    grid-template-columns: minmax(0, 1fr) minmax(250px, 280px);
    column-gap: 18px;
  }

  body.ops-writeoffs-shell .line-grid-main {
    grid-template-columns: minmax(120px, .45fr) minmax(220px, .8fr);
  }

  body.ops-writeoffs-shell .line-grid-main > label.wide,
  body.ops-writeoffs-shell .line-grid-main > .line-photo-field {
    grid-column: 1 / -1;
  }

  body.ops-writeoffs-shell .readonly-lines-header,
  body.ops-writeoffs-shell .readonly-line-card {
    grid-template-columns: 32px minmax(140px, 1.2fr) minmax(130px, .7fr) minmax(100px, .8fr) minmax(100px, .9fr) minmax(140px, 166px);
  }

  body.ops-writeoffs-shell .readonly-lines-header > span:nth-child(3),
  body.ops-writeoffs-shell .readonly-lines-header > span:nth-child(4),
  body.ops-writeoffs-shell .readonly-line-code,
  body.ops-writeoffs-shell .readonly-line-unit {
    display: none;
  }

  body.ops-writeoffs-shell .readonly-line-head p {
    display: block;
  }

  body.ops-writeoffs-shell .line-grid .wide {
    grid-column: 1 / -1;
  }

  body.ops-writeoffs-shell #summaryTab .filters {
    grid-template-columns: repeat(2, minmax(180px, 1fr));
  }
}

@media (max-width: 800px) {
  body.ops-writeoffs-shell #appMain {
    padding: 0 20px 36px;
  }

  body.ops-writeoffs-shell .topbar {
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 12px;
    min-height: 62px;
    margin-bottom: 12px;
    padding: 10px 12px;
  }

  body.ops-writeoffs-shell .topbar .module-nav {
    justify-self: stretch;
  }

  body.ops-writeoffs-shell #writeoffsModule > .tabs {
    width: 100%;
    top: 64px;
    margin-bottom: 8px;
  }

  body.ops-writeoffs-shell #writeoffsModule .panel {
    padding: 16px;
  }

  body.ops-writeoffs-shell .document-form {
    grid-template-columns: 1fr 1fr;
  }

  body.ops-writeoffs-shell .document-form #openDocumentButton {
    grid-column: 1 / -1;
    width: 100%;
  }

  body.ops-writeoffs-shell #documentSection {
    display: flex;
    flex-direction: column;
    align-items: stretch;
  }

  body.ops-writeoffs-shell #documentSection .document-head {
    display: contents;
  }

  body.ops-writeoffs-shell #documentSection .document-head > div:first-child { order: 1; }
  body.ops-writeoffs-shell #documentSection #documentErrors { order: 2; }
  body.ops-writeoffs-shell #documentSection #documentRiskReview { order: 3; }
  body.ops-writeoffs-shell #documentSection .section-divider { order: 4; }
  body.ops-writeoffs-shell #documentSection .line-toolbar { order: 5; }
  body.ops-writeoffs-shell #documentSection #emptyLines { order: 6; }
  body.ops-writeoffs-shell #documentSection #linesList { order: 7; }
  body.ops-writeoffs-shell #documentSection .line-add-action { order: 8; }
  body.ops-writeoffs-shell #documentSection #pickerPanel { order: 9; }
  body.ops-writeoffs-shell #documentSection #documentActions { order: 10; }

  body.ops-writeoffs-shell .document-actions {
    position: static;
    margin-top: 8px;
    padding: 14px;
  }

  body.ops-writeoffs-shell .readonly-line-card {
    grid-template-columns: 34px minmax(0, 1fr) 36px;
    grid-template-rows: auto auto auto auto;
    gap: 2px 10px;
    margin-bottom: 8px;
    padding: 12px;
    border: 1px solid var(--wo-border);
    border-radius: 8px;
  }

  body.ops-writeoffs-shell #documentSection.readonly.has-lines .readonly-lines-header,
  body.ops-writeoffs-shell #documentSection.has-locked-lines .readonly-lines-header {
    display: none;
  }

  body.ops-writeoffs-shell #documentSection.readonly .lines-list {
    gap: 0;
  }

  body.ops-writeoffs-shell .readonly-line-index {
    grid-column: 1;
    grid-row: 1 / span 2;
    display: inline-grid;
    width: 30px;
    height: 30px;
    place-items: center;
    align-self: center;
    border: 1px solid var(--wo-border-strong);
    border-radius: 50%;
    color: var(--wo-text);
    font-weight: 700;
  }

  body.ops-writeoffs-shell .readonly-line-head {
    grid-column: 2;
    grid-row: 1;
  }

  body.ops-writeoffs-shell .readonly-line-head p {
    display: block;
  }

  body.ops-writeoffs-shell .readonly-line-badges {
    display: flex;
    justify-content: flex-start;
    margin-top: 5px;
  }

  body.ops-writeoffs-shell .readonly-line-quantity {
    grid-column: 2;
    grid-row: 2;
    margin-top: 4px;
    white-space: nowrap;
  }

  body.ops-writeoffs-shell .readonly-line-reason {
    display: none;
  }

  body.ops-writeoffs-shell .readonly-line-code,
  body.ops-writeoffs-shell .readonly-line-unit,
  body.ops-writeoffs-shell .readonly-line-comment {
    display: none;
  }

  body.ops-writeoffs-shell .readonly-line-toggle {
    grid-column: 3;
    grid-row: 1 / span 2;
    display: inline-grid;
    width: 36px;
    min-width: 36px;
    height: 36px;
    min-height: 36px;
    place-items: center;
    align-self: center;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: var(--wo-text);
  }

  body.ops-writeoffs-shell .readonly-line-photo-gallery {
    grid-column: 2 / -1;
    grid-row: 3;
    margin-top: 8px;
    overflow-x: auto;
  }

  body.ops-writeoffs-shell .readonly-line-photo-gallery.is-empty {
    display: none;
  }

  body.ops-writeoffs-shell .readonly-line-toggle span {
    width: 9px;
    height: 9px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg) translate(-2px, -2px);
    transition: transform .16s ease;
  }

  body.ops-writeoffs-shell .readonly-line-card.is-expanded .readonly-line-toggle span {
    transform: rotate(225deg) translate(-1px, -1px);
  }

  body.ops-writeoffs-shell .readonly-line-mobile-details {
    grid-column: 1 / -1;
    grid-row: 4;
    display: none;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 18px;
    margin: 10px 0 0;
    padding: 12px 0 0;
    border-top: 1px solid var(--wo-border);
  }

  body.ops-writeoffs-shell .readonly-line-card.is-expanded .readonly-line-mobile-details {
    display: grid;
  }

  body.ops-writeoffs-shell .readonly-line-mobile-details div {
    min-width: 0;
  }

  body.ops-writeoffs-shell .readonly-line-mobile-details dt {
    margin-bottom: 4px;
    color: var(--wo-muted);
    font-size: 11px;
    font-weight: 650;
  }

  body.ops-writeoffs-shell .readonly-line-mobile-details dd {
    margin: 0;
    overflow-wrap: anywhere;
    color: var(--wo-text);
    font-size: 13px;
    font-weight: 650;
  }

  body.ops-writeoffs-shell .line-grid-main {
    grid-template-columns: 1fr 1fr;
  }

  body.ops-writeoffs-shell #managerTab .filters {
    margin-inline: -16px;
    padding-inline: 16px;
    grid-template-columns: 1fr 1fr;
  }

  body.ops-writeoffs-shell #managerTab .filters label:first-child {
    grid-column: 1 / -1;
  }

  body.ops-writeoffs-shell #summaryTab .filters {
    margin-inline: -16px;
    padding-inline: 16px;
  }

  body.ops-writeoffs-shell #summaryTotals {
    margin-inline: -16px;
  }

  body.ops-writeoffs-shell .writeoffs-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body.ops-writeoffs-shell .writeoffs-cards > article:nth-child(2n),
  body.ops-writeoffs-shell .writeoffs-cards > .summary-card:nth-child(2n) {
    border-right: 0;
  }

  body.ops-writeoffs-shell .writeoffs-cards > article:nth-child(-n+2),
  body.ops-writeoffs-shell .writeoffs-cards > .summary-card:nth-child(-n+2) {
    border-bottom: 1px solid var(--wo-border);
  }

  body.ops-writeoffs-shell .summary-insight-grid {
    grid-template-columns: 1fr;
  }

  body.ops-writeoffs-shell .summary-data-table-compact table {
    min-width: 520px;
  }
}

@media (max-width: 600px) {
  body.ops-writeoffs-shell {
    padding-bottom: calc(66px + env(safe-area-inset-bottom));
  }

  body.ops-writeoffs-shell #appMain {
    padding: 0 10px 24px;
  }

  body.ops-writeoffs-shell .topbar {
    grid-template-columns: 40px minmax(0, 1fr) auto;
    gap: 10px;
    min-height: 56px;
    margin: 0;
    padding: max(7px, env(safe-area-inset-top)) 12px 7px;
    border-bottom: 1px solid var(--wo-border);
    border-radius: 0;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }

  body.ops-writeoffs-shell .ops-brand {
    grid-column: 1;
    grid-row: 1;
  }

  body.ops-writeoffs-shell .ops-brand-mark {
    flex-basis: 32px;
    width: 32px;
    height: 32px;
  }

  body.ops-writeoffs-shell .ops-brand-name {
    display: none;
  }

  body.ops-writeoffs-shell .topbar .ops-brand-module,
  body.ops-writeoffs-shell .topbar h1 {
    grid-column: 2;
    grid-row: 1;
    display: block;
    justify-self: center;
    align-self: center;
    font-size: 18px;
  }

  body.ops-writeoffs-shell .topbar-actions {
    grid-column: 3;
    grid-row: 1;
  }

  body.ops-writeoffs-shell .topbar-actions .btn {
    min-height: 34px;
    padding: 5px 9px;
    font-size: 12px;
  }

  body.ops-writeoffs-shell .topbar .module-nav,
  body.ops-writeoffs-shell.ops-classic-shell .topbar .module-nav,
  body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode .topbar .module-nav {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 70;
    width: 100vw;
    max-width: none;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    display: grid;
    margin: 0;
    padding: 5px 8px max(5px, env(safe-area-inset-bottom));
    border-top: 1px solid var(--wo-border);
    border-radius: 0;
    background: rgba(255, 255, 255, .98);
    box-shadow: 0 -6px 18px rgba(16, 24, 40, .06);
    backdrop-filter: blur(12px);
  }

  body.ops-writeoffs-shell .topbar .module-nav .module-link,
  body.ops-writeoffs-shell .topbar .module-nav .nav-link {
    min-height: 50px;
    padding: 7px 4px 5px;
    border-radius: 6px;
    color: var(--wo-muted);
    font-size: 0;
    font-weight: 700;
    white-space: normal;
  }

  body.ops-writeoffs-shell .topbar .module-nav .module-link::before,
  body.ops-writeoffs-shell .topbar .module-nav .nav-link::before {
    content: "";
    position: absolute;
    top: 4px;
    left: 50%;
    width: 18px;
    height: 3px;
    border-radius: 999px;
    background: transparent;
    transform: translateX(-50%);
  }

  body.ops-writeoffs-shell .topbar .module-nav .module-link.active,
  body.ops-writeoffs-shell .topbar .module-nav .nav-link.active,
  body.ops-writeoffs-shell .topbar .module-nav .module-link[aria-current="page"],
  body.ops-writeoffs-shell .topbar .module-nav .nav-link[aria-current="page"] {
    color: var(--wo-green);
    background: var(--wo-green-soft);
  }

  body.ops-writeoffs-shell .topbar .module-nav .module-link.active::before,
  body.ops-writeoffs-shell .topbar .module-nav .nav-link.active::before,
  body.ops-writeoffs-shell .topbar .module-nav .module-link[aria-current="page"]::before,
  body.ops-writeoffs-shell .topbar .module-nav .nav-link[aria-current="page"]::before {
    background: var(--wo-green);
  }

  body.ops-writeoffs-shell .topbar .module-nav .module-link.active::after,
  body.ops-writeoffs-shell .topbar .module-nav .nav-link.active::after,
  body.ops-writeoffs-shell .topbar .module-nav .module-link[aria-current="page"]::after,
  body.ops-writeoffs-shell .topbar .module-nav .nav-link[aria-current="page"]::after {
    content: attr(data-mobile-label);
    position: static;
    display: block;
    width: auto;
    height: auto;
    border-radius: 0;
    background: transparent;
    color: currentColor;
    font-size: 12px;
    line-height: 1.2;
    transform: none;
  }

  body.ops-writeoffs-shell .topbar .module-nav .module-link:not(.active):not([aria-current="page"])::after,
  body.ops-writeoffs-shell .topbar .module-nav .nav-link:not(.active):not([aria-current="page"])::after {
    content: attr(data-mobile-label);
    position: static;
    display: block;
    width: auto;
    height: auto;
    border-radius: 0;
    background: transparent;
    color: currentColor;
    font-size: 12px;
    line-height: 1.2;
  }

  body.ops-writeoffs-shell #writeoffsModule > .tabs {
    display: grid;
    position: static;
    width: 100%;
    min-width: 0;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0;
    top: 56px;
    z-index: 40;
    margin: 0 0 10px;
    padding: 0 6px;
    border-radius: 0;
    background: var(--wo-surface);
  }

  body.ops-writeoffs-shell #writeoffsModule > .tabs .tab {
    min-height: 40px;
    padding: 8px 6px;
    font-size: 13px;
  }

  body.ops-writeoffs-shell #writeoffsModule .panel,
  body.ops-writeoffs-shell #loginSection,
  body.ops-writeoffs-shell #authLoadingSection,
  body.ops-writeoffs-shell #accessDeniedSection {
    margin: 0;
    padding: 16px;
    border: 1px solid var(--wo-border);
    border-radius: 8px;
    box-shadow: none;
  }

  body.ops-writeoffs-shell #writeoffsModule h2,
  body.ops-writeoffs-shell .document-selection-intro h2 {
    font-size: 21px;
  }

  body.ops-writeoffs-shell .document-form,
  body.ops-writeoffs-shell .line-grid-main,
  body.ops-writeoffs-shell #managerTab .filters,
  body.ops-writeoffs-shell #summaryTab .filters {
    grid-template-columns: 1fr;
  }

  body.ops-writeoffs-shell .line-grid-main > label.wide,
  body.ops-writeoffs-shell .line-grid-main > .line-photo-field {
    grid-column: 1;
  }

  body.ops-writeoffs-shell .summary-advanced-filters-toggle {
    display: flex;
    width: 100%;
    min-height: 40px;
    align-items: center;
    justify-content: center;
  }

  body.ops-writeoffs-shell .summary-advanced-filters-toggle.has-active-filters {
    border-color: #9bc7a8;
    background: var(--wo-green-soft);
    color: var(--wo-green-dark);
  }

  body.ops-writeoffs-shell #summaryTab .filters .summary-advanced-filter {
    display: none;
  }

  body.ops-writeoffs-shell #summaryTab .filters.summary-filters-expanded .summary-advanced-filter {
    display: grid;
  }

  body.ops-writeoffs-shell .document-form #openDocumentButton,
  body.ops-writeoffs-shell #managerTab .filters label:first-child {
    grid-column: auto;
  }

  body.ops-writeoffs-shell .document-context {
    display: flex;
  }

  body.ops-writeoffs-shell .document-title-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 12px;
  }

  body.ops-writeoffs-shell .context-action {
    width: auto;
    min-width: 44px;
  }

  body.ops-writeoffs-shell #exportExcelButton {
    width: 100%;
  }

  body.ops-writeoffs-shell .item-action {
    width: auto;
    justify-self: start;
  }

  body.ops-writeoffs-shell .document-meta-cards {
    gap: 7px 14px;
  }

  body.ops-writeoffs-shell .readonly-line-facts {
    grid-template-columns: minmax(90px, .4fr) minmax(0, 1fr);
  }

  body.ops-writeoffs-shell .line-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 14px;
  }

  body.ops-writeoffs-shell .line-toolbar-title {
    display: grid;
    min-width: 0;
    gap: 1px;
  }

  body.ops-writeoffs-shell .line-toolbar-title h3 {
    white-space: nowrap;
  }

  body.ops-writeoffs-shell .line-card-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    padding: 11px 12px;
  }

  body.ops-writeoffs-shell .line-card-body {
    padding: 12px;
  }

  body.ops-writeoffs-shell .line-grid .wide {
    grid-column: auto;
  }

  body.ops-writeoffs-shell .picker-search {
    grid-template-columns: 1fr;
  }

  body.ops-writeoffs-shell .picker-item {
    grid-template-columns: minmax(0, 1fr) 32px;
  }

  body.ops-writeoffs-shell .picker-item-title-row {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  body.ops-writeoffs-shell .section-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
  }

  body.ops-writeoffs-shell #summaryTab .section-head {
    grid-template-columns: 1fr;
  }

  body.ops-writeoffs-shell #summaryTab .section-head-actions {
    width: 100%;
    justify-content: stretch;
  }

  body.ops-writeoffs-shell #summaryTab .section-head-actions > button {
    flex: 1 1 140px;
    width: auto;
  }

  body.ops-writeoffs-shell #managerTab .section-head-actions {
    flex-wrap: nowrap;
  }

  body.ops-writeoffs-shell #managerTab .section-head-actions > button {
    width: auto;
  }

  body.ops-writeoffs-shell #managerTab .filters,
  body.ops-writeoffs-shell #summaryTab .filters {
    margin-inline: -14px;
    padding-inline: 14px;
  }

  body.ops-writeoffs-shell #summaryTotals {
    margin-inline: -14px;
  }

  body.ops-writeoffs-shell .writeoffs-cards > article,
  body.ops-writeoffs-shell .writeoffs-cards > .summary-card {
    padding: 12px;
  }

  body.ops-writeoffs-shell .writeoffs-cards strong {
    font-size: 19px;
  }

  body.ops-writeoffs-shell .documents-section-head {
    display: flex;
    padding: 11px 12px;
  }

  body.ops-writeoffs-shell .documents-section-head p {
    display: none;
  }

  body.ops-writeoffs-shell .document-row {
    grid-template-columns: 1fr;
    gap: 7px;
    min-height: 0;
    padding: 11px 12px;
  }

  body.ops-writeoffs-shell .document-row-meta {
    gap: 3px 9px;
  }

  body.ops-writeoffs-shell .document-row-open {
    justify-self: start;
  }

  body.ops-writeoffs-shell .summary-section-title {
    min-height: 0;
    padding: 11px 12px;
  }

  body.ops-writeoffs-shell .summary-data-table {
    overflow: visible;
  }

  body.ops-writeoffs-shell .summary-data-table table,
  body.ops-writeoffs-shell .summary-data-table-compact table,
  body.ops-writeoffs-shell .summary-data-table tbody {
    display: block;
    width: 100%;
    min-width: 0;
  }

  body.ops-writeoffs-shell .summary-data-table thead {
    display: none;
  }

  body.ops-writeoffs-shell .summary-data-table tr {
    display: grid;
    gap: 0;
    margin: 0;
    padding: 8px 12px;
    border-bottom: 1px solid var(--wo-border);
    background: #fff;
  }

  body.ops-writeoffs-shell .summary-data-table tbody tr:last-child {
    border-bottom: 0;
  }

  body.ops-writeoffs-shell .summary-data-table td {
    display: grid;
    grid-template-columns: minmax(92px, .42fr) minmax(0, 1fr);
    gap: 12px;
    align-items: start;
    padding: 5px 0;
    border: 0;
    background: transparent;
    font-size: 13px;
    overflow-wrap: anywhere;
  }

  body.ops-writeoffs-shell .summary-data-table tbody tr:hover td {
    background: transparent;
  }

  body.ops-writeoffs-shell .summary-data-table .mobile-cell-label {
    display: block;
    color: var(--wo-muted);
    font-size: 11px;
    font-weight: 650;
    line-height: 1.35;
  }

  body.ops-writeoffs-shell .summary-data-table .table-cell-value {
    min-width: 0;
    color: var(--wo-text);
    overflow-wrap: anywhere;
  }

  body.ops-writeoffs-shell .summary-data-table-compact tr {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    padding-block: 11px;
  }

  body.ops-writeoffs-shell .summary-data-table-compact td {
    display: block;
    padding: 0;
  }

  body.ops-writeoffs-shell .summary-data-table-compact td .mobile-cell-label {
    display: none;
  }

  body.ops-writeoffs-shell .summary-data-table-compact td:last-child {
    min-width: 62px;
    text-align: right;
  }

  body.ops-writeoffs-shell .summary-data-table-compact td:last-child .mobile-cell-label {
    display: block;
    margin-bottom: 2px;
    font-size: 10px;
  }
}

/* Unified platform sidebar. These selectors intentionally override the
 * legacy horizontal module and tab navigation without touching page content. */
body.ops-writeoffs-shell .ops-platform-sidebar .ops-brand-mark {
  width: 42px;
  height: 42px;
  flex-basis: 42px;
  border: 0;
  border-radius: var(--ops-radius);
  background: var(--ops-brand);
  color: var(--ops-brand-ink);
  font-size: 15px;
}

body.ops-writeoffs-shell .ops-platform-sidebar .ops-brand-name {
  display: block;
  color: #fff;
}

body.ops-writeoffs-shell .ops-platform-sidebar .ops-brand-module {
  display: block;
  color: #cbd5e1;
}

body.ops-writeoffs-shell .ops-platform-sidebar .module-nav {
  width: 100%;
  max-width: none;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  position: static;
  gap: 3px;
  margin: 0;
  padding: 0 0 13px;
  overflow: visible;
  border: 0;
  border-bottom: 1px solid #334155;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

body.ops-writeoffs-shell .ops-platform-sidebar .module-nav > a {
  min-height: 38px;
  border: 0;
  border-radius: 8px;
  padding: 8px 10px;
  background: transparent;
  color: #cbd5e1;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.2;
  text-align: left;
}

body.ops-writeoffs-shell .ops-platform-sidebar .module-nav > a:hover {
  background: #1e293b;
  color: #fff;
}

body.ops-writeoffs-shell .ops-platform-sidebar .module-nav > a.active,
body.ops-writeoffs-shell .ops-platform-sidebar .module-nav > a[aria-current="page"] {
  background: rgba(34, 197, 94, .13);
  color: #bbf7d0;
  box-shadow: inset 3px 0 0 #4ade80;
}

body.ops-writeoffs-shell .ops-platform-sidebar .module-nav > a::before,
body.ops-writeoffs-shell .ops-platform-sidebar .module-nav > a::after {
  display: none;
}

body.ops-writeoffs-shell .ops-platform-sidebar .tabs {
  width: 100%;
  display: flex;
  position: static;
  flex-direction: column;
  grid-template-columns: none;
  gap: 3px;
  margin: 0;
  padding: 2px 0 0 8px;
  border-left: 1px solid #334155;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

body.ops-writeoffs-shell .ops-platform-sidebar .tabs .tab {
  width: 100%;
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  border: 0;
  border-radius: 8px;
  padding: 9px 10px;
  background: transparent;
  color: #cbd5e1;
  font-size: 15px;
  font-weight: 750;
  text-align: left;
}

body.ops-writeoffs-shell .ops-platform-sidebar .tabs .tab::before {
  width: 6px;
  height: 6px;
  flex: 0 0 6px;
  margin-right: 8px;
  border-radius: 50%;
  background: transparent;
  content: "";
}

body.ops-writeoffs-shell .ops-platform-sidebar .tabs .tab:hover {
  background: #1e293b;
  color: #fff;
}

body.ops-writeoffs-shell .ops-platform-sidebar .tabs .tab.active {
  background: #1e293b;
  color: #fff;
  box-shadow: none;
}

body.ops-writeoffs-shell .ops-platform-sidebar .tabs .tab.active::before {
  background: #4ade80;
}

body.ops-writeoffs-shell .ops-platform-sidebar .tabs .tab::after {
  display: none;
}

body.ops-writeoffs-shell .ops-platform-page-header {
  padding: 24px 0 18px;
}

body.ops-writeoffs-shell > .app-shell > .ops-platform-content > #loginSection,
body.ops-writeoffs-shell > .app-shell > .ops-platform-content > #authLoadingSection,
body.ops-writeoffs-shell > .app-shell > .ops-platform-content > #accessDeniedSection {
  width: min(760px, calc(100% - 32px));
  margin: clamp(24px, 8vh, 72px) auto;
}

.writeoff-line-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.writeoff-rejected-line {
  border: 1px solid #cbd5db;
  border-left: 4px solid #9b3840;
  border-radius: 6px;
  padding: 14px;
  background: #f8fafb;
  color: #394753;
  overflow-wrap: anywhere;
}

.writeoff-rejected-line header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.writeoff-rejected-line p { margin: 10px 0 6px; }
.writeoff-rejected-line small { display: block; font-size: 14px; }
.rejected-lines-title { margin: 16px 0 0; font-size: 18px; }
.line-decision-reason { display: grid; gap: 8px; }
.line-decision-reason textarea { width: 100%; min-width: 0; box-sizing: border-box; font-size: 16px; padding: 12px; }

.writeoff-confirm-dialog {
  width: min(520px, calc(100vw - 32px));
  max-width: 520px;
  margin: auto;
  padding: 0;
  border: 1px solid #d9e1e7;
  border-radius: 8px;
  background: #fff;
  color: #16202a;
  box-shadow: 0 24px 64px rgba(15, 23, 42, .24);
}

.writeoff-confirm-dialog::backdrop {
  background: rgba(15, 23, 42, .5);
  backdrop-filter: blur(2px);
}

.writeoff-confirm-dialog-content {
  display: grid;
  gap: 18px;
  padding: 24px;
}

.writeoff-confirm-dialog-heading {
  display: grid;
  gap: 5px;
}

.writeoff-confirm-dialog-heading p,
.writeoff-confirm-dialog-heading h2,
.writeoff-confirm-dialog-message {
  margin: 0;
}

.writeoff-confirm-dialog-heading h2 {
  font-size: 22px;
  line-height: 1.25;
}

.writeoff-confirm-dialog-message {
  color: #52606d;
  font-size: 15px;
  line-height: 1.55;
  white-space: pre-line;
}

.writeoff-confirm-dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.writeoff-confirm-dialog-actions button {
  min-height: 44px;
}

@media (max-width: 520px) {
  .writeoff-confirm-dialog {
    width: calc(100vw - 24px);
  }

  .writeoff-confirm-dialog-content {
    padding: 20px;
  }

  .writeoff-confirm-dialog-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .writeoff-confirm-dialog-actions .primary {
    grid-row: 1;
  }
}

@media (max-width: 1100px) {
  body.ops-writeoffs-shell .ops-platform-sidebar .ops-brand-name {
    display: block;
  }
}

@media (max-width: 640px) {
  body.ops-writeoffs-shell .ops-platform-sidebar .ops-brand-mark {
    width: 42px;
    height: 42px;
    flex-basis: 42px;
  }

  body.ops-writeoffs-shell .ops-platform-page-header {
    padding: 18px 0 14px;
  }
}

@media (max-width: 370px) {
  body.ops-writeoffs-shell .ops-brand-name {
    display: none;
  }

  body.ops-writeoffs-shell .topbar .module-nav {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  body.ops-writeoffs-shell #writeoffsModule > .tabs .tab {
    padding-inline: 4px;
    font-size: 12px;
  }

  body.ops-writeoffs-shell .writeoffs-cards {
    grid-template-columns: 1fr 1fr;
  }
}

/* The shared base sheet uses high-specificity shell selectors. Keep the
 * write-offs product shell authoritative. */
body.ops-writeoffs-shell.ops-classic-shell .app-shell,
body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode .app-shell {
  width: 100%;
  margin: 0;
  padding: 0;
}

body.ops-writeoffs-shell.ops-classic-shell .topbar,
body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode .topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 18px;
  min-height: 64px;
  margin: 0 0 18px;
  padding: 0 28px;
  border: 0;
  border-bottom: 1px solid var(--wo-border);
  border-radius: 0;
  background: rgba(255, 255, 255, .98);
  color: var(--wo-text);
  box-shadow: none;
}

body.ops-writeoffs-shell.ops-classic-shell .topbar h1,
body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode .topbar h1 {
  display: none;
  color: var(--wo-text);
}

body.ops-writeoffs-shell.ops-classic-shell .topbar .ghost,
body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode .topbar .ghost {
  min-height: 36px;
  border-color: var(--wo-border-strong);
  border-radius: 6px;
  background: #fff;
  color: #34404c;
}

body.ops-writeoffs-shell.ops-classic-shell .topbar .ghost:hover,
body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode .topbar .ghost:hover {
  border-color: #9da9b4;
  background: #f4f6f7;
  color: var(--wo-text);
}

@media (max-width: 600px) {
  body.ops-writeoffs-shell.ops-classic-shell .app-shell,
  body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode .app-shell {
    padding: 0;
  }

  body.ops-writeoffs-shell.ops-classic-shell .topbar,
  body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode .topbar {
    grid-template-columns: 40px minmax(0, 1fr) auto;
    gap: 10px;
    min-height: 56px;
    margin: 0;
    padding: max(7px, env(safe-area-inset-top)) 12px 7px;
    border-radius: 0;
  }

  body.ops-writeoffs-shell.ops-classic-shell .topbar h1,
  body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode .topbar h1 {
    grid-column: 2;
    grid-row: 1;
    display: block;
    justify-self: center;
    align-self: center;
    font-size: 18px;
  }

  body.ops-writeoffs-shell.ops-classic-shell .ops-brand-mark,
  body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode .ops-brand-mark {
    width: 32px;
    height: 32px;
    flex-basis: 32px;
  }

  body.ops-writeoffs-shell.ops-classic-shell .ops-brand-name,
  body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode .ops-brand-name {
    display: none;
  }

  body.ops-writeoffs-shell.ops-classic-shell .topbar .ghost,
  body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode .topbar .ghost {
    min-height: 34px;
    padding: 5px 9px;
    font-size: 12px;
  }

  body.ops-writeoffs-shell.ops-classic-shell #writeoffsModule .panel,
  body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode #writeoffsModule .panel {
    padding: 16px;
    border-radius: 8px;
  }

  body.ops-writeoffs-shell.ops-classic-shell .ops-platform-sidebar .ops-brand-mark {
    width: 42px;
    height: 42px;
    flex-basis: 42px;
  }

  body.ops-writeoffs-shell.ops-classic-shell .ops-platform-sidebar .ops-brand-name {
    display: block;
  }

  body.ops-writeoffs-shell .line-grid-main {
    grid-template-columns: 1fr;
  }

  body.ops-writeoffs-shell .line-grid-main .wide {
    grid-column: 1;
  }

  body.ops-writeoffs-shell .line-photo-actions {
    display: flex;
    flex-wrap: wrap;
  }

  body.ops-writeoffs-shell .line-photo-actions button {
    width: auto;
    flex: 1 1 140px;
    min-height: 44px;
  }

  body.ops-writeoffs-shell .readonly-line-photo-gallery {
    justify-content: flex-start;
  }

  body.ops-writeoffs-shell .writeoff-photo-dialog {
    width: calc(100vw - 16px);
    max-height: calc(100dvh - 16px);
    border-radius: 8px;
  }

  body.ops-writeoffs-shell .writeoff-photo-dialog-content {
    max-height: calc(100dvh - 16px);
  }

  body.ops-writeoffs-shell .writeoff-photo-dialog-head {
    padding: 12px 14px;
  }

  body.ops-writeoffs-shell .writeoff-photo-dialog-meta {
    max-width: calc(100vw - 92px);
    font-size: 11px;
  }

  body.ops-writeoffs-shell .writeoff-photo-dialog-stage {
    min-height: min(72vh, 620px);
    padding: 8px;
  }

  body.ops-writeoffs-shell .writeoff-photo-dialog-stage img {
    max-height: calc(100dvh - 132px);
  }

  body.ops-writeoffs-shell .writeoff-photo-dialog-nav {
    top: auto;
    bottom: 10px;
    width: 42px;
    min-width: 42px;
    height: 42px;
    min-height: 42px;
    font-size: 32px;
    transform: none;
  }

  body.ops-writeoffs-shell .writeoff-photo-dialog-nav.is-previous {
    left: 10px;
  }

  body.ops-writeoffs-shell .writeoff-photo-dialog-nav.is-next {
    right: 10px;
  }

  body.ops-writeoffs-shell .writeoff-photo-dialog-counter {
    bottom: 18px;
  }

  body.ops-writeoffs-shell .writeoff-camera-dialog {
    width: 100vw;
    max-width: none;
    max-height: 100dvh;
    border-radius: 0;
  }

  body.ops-writeoffs-shell .writeoff-camera-dialog-content {
    height: 100dvh;
    max-height: 100dvh;
    grid-template-rows: auto minmax(0, 1fr) auto auto;
  }

  body.ops-writeoffs-shell .writeoff-camera-dialog-head {
    padding: max(12px, env(safe-area-inset-top)) 14px 10px;
  }

  body.ops-writeoffs-shell .writeoff-camera-stage {
    min-height: 0;
  }

  body.ops-writeoffs-shell .writeoff-camera-stage video {
    max-height: none;
  }

  body.ops-writeoffs-shell .writeoff-camera-thumbnails {
    padding-inline: 12px;
  }

  body.ops-writeoffs-shell .writeoff-camera-actions {
    padding: 10px 12px max(10px, env(safe-area-inset-bottom));
  }
}

@media (max-width: 800px) {
  body.ops-writeoffs-shell .documents-period-toolbar {
    display: grid;
  }

  body.ops-writeoffs-shell .documents-period-modes {
    width: 100%;
  }

  body.ops-writeoffs-shell .documents-period-navigation {
    grid-template-columns: 38px minmax(0, 1fr) 38px;
  }

  body.ops-writeoffs-shell .documents-period-navigation .secondary {
    grid-column: 1 / -1;
    justify-self: center;
  }

  body.ops-writeoffs-shell .documents-calendar {
    padding-bottom: 7px;
  }

  body.ops-writeoffs-shell .documents-calendar-table-scroll::-webkit-scrollbar {
    height: 7px;
  }

  body.ops-writeoffs-shell .documents-calendar-store-column {
    width: 132px;
    min-width: 132px;
    max-width: 132px;
    padding: 8px 9px !important;
  }

  body.ops-writeoffs-shell .documents-calendar-store-column strong {
    display: -webkit-box;
    overflow: hidden;
    white-space: normal;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  body.ops-writeoffs-shell .documents-calendar-store-column small {
    font-size: 9px;
  }

  body.ops-writeoffs-shell .documents-calendar-date-column {
    width: 86px;
    min-width: 86px;
    height: 46px;
    padding: 6px !important;
  }

  body.ops-writeoffs-shell .documents-calendar-cell-button {
    min-width: 85px;
    min-height: 74px;
    padding: 7px;
  }

  body.ops-writeoffs-shell .documents-calendar-cell-button > strong {
    font-size: 10px;
  }

  body.ops-writeoffs-shell .documents-calendar-legend {
    padding-inline: 9px;
  }
}

/* Mobile sellers spend most of their time inside editable product rows. Keep
 * those rows readable and touch-friendly without making completed documents
 * or desktop tables less dense. */
@media (max-width: 600px) {
  body.ops-writeoffs-shell.ops-classic-shell.writeoffs-mode #writeoffsModule #documentSection.panel {
    padding: 12px;
  }

  body.ops-writeoffs-shell .line-toolbar-title h3 {
    font-size: 18px;
  }

  body.ops-writeoffs-shell .line-count {
    font-size: 13px;
  }

  body.ops-writeoffs-shell .line-card-head {
    gap: 10px;
    padding: 13px 12px;
  }

  body.ops-writeoffs-shell .line-title {
    font-size: 17px;
    line-height: 1.35;
  }

  body.ops-writeoffs-shell .line-subtitle {
    margin-top: 3px;
    font-size: 13px;
    line-height: 1.35;
  }

  body.ops-writeoffs-shell .line-card .remove-line {
    min-height: 44px;
    padding: 8px 10px;
    font-size: 13px;
  }

  body.ops-writeoffs-shell .line-card-body {
    padding: 13px 12px 14px;
  }

  body.ops-writeoffs-shell .line-grid-main {
    gap: 15px 12px;
  }

  body.ops-writeoffs-shell #writeoffsModule .line-grid-main label {
    gap: 5px;
    font-size: 15px;
    line-height: 1.3;
  }

  body.ops-writeoffs-shell #writeoffsModule .line-grid-main input,
  body.ops-writeoffs-shell #writeoffsModule .line-grid-main select,
  body.ops-writeoffs-shell #writeoffsModule .line-grid-main textarea {
    min-height: 50px;
    padding: 11px 12px;
    font-size: 16px;
    font-weight: 650;
    line-height: 1.35;
  }

  body.ops-writeoffs-shell #writeoffsModule .line-grid-main textarea {
    min-height: 72px;
    font-weight: 550;
  }

  body.ops-writeoffs-shell .line-quantity-hint,
  body.ops-writeoffs-shell .line-price-source {
    min-height: 0;
    margin-top: 1px;
    font-size: 12px;
    font-weight: 550;
    line-height: 1.4;
  }

  body.ops-writeoffs-shell .line-price-total {
    display: flex;
    min-height: 28px;
    align-items: center;
    margin-top: 2px;
    padding: 5px 8px;
    border-left: 3px solid var(--wo-green);
    border-radius: 0 5px 5px 0;
    background: var(--wo-green-soft);
    color: var(--wo-green-dark);
    font-size: 14px;
    font-weight: 800;
    line-height: 1.3;
  }

  body.ops-writeoffs-shell .line-field-warning {
    padding: 9px 10px;
    font-size: 13px;
  }

  body.ops-writeoffs-shell .line-photo-heading strong {
    font-size: 15px;
  }

  body.ops-writeoffs-shell .line-photo-heading span {
    font-size: 12px;
  }

  body.ops-writeoffs-shell .line-photo-actions button {
    min-height: 48px;
    font-size: 14px;
  }

  body.ops-writeoffs-shell #documentSection .line-add-action {
    margin-top: 14px;
  }

  body.ops-writeoffs-shell #documentSection .line-add-action .item-action {
    width: 100%;
    min-height: 50px;
    justify-content: center;
    font-size: 15px;
  }

  body.ops-writeoffs-shell #documentSection .picker-panel {
    margin-top: 14px;
  }

  body.ops-writeoffs-shell .picker-panel-title h4 {
    font-size: 17px;
  }

  body.ops-writeoffs-shell .picker-close {
    min-height: 44px;
    padding-inline: 12px;
    font-size: 14px;
  }

  body.ops-writeoffs-shell #writeoffsModule .picker-search label {
    gap: 5px;
    font-size: 15px;
  }

  body.ops-writeoffs-shell #writeoffsModule .picker-search input {
    min-height: 50px;
    font-size: 16px;
  }
}

@media (min-width: 380px) and (max-width: 600px) {
  body.ops-writeoffs-shell .line-grid-main {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body.ops-writeoffs-shell .line-reason-field,
  body.ops-writeoffs-shell .line-grid-main > label.line-comment-field,
  body.ops-writeoffs-shell .line-grid-main > .line-photo-field {
    grid-column: 1 / -1;
  }

  body.ops-writeoffs-shell .line-grid-main > label.line-comment-field textarea {
    width: 100%;
  }
}
