﻿:root {
  --font-body: "IBM Plex Sans", "Segoe UI", sans-serif;
  --font-brand: "IBM Plex Sans", "Segoe UI", sans-serif;
  --font-doc: "IBM Plex Sans", "Segoe UI", sans-serif;
  --font-doc-heading: "IBM Plex Serif", "Times New Roman", serif;
  /* Updated at runtime (see static/js/app.js) to match the sticky navbar height. */
  --app-nav-height: 78px;
  --color-bg: #0f172a;
  --color-surface: #111c31;
  --color-surface-alt: #16233b;
  --color-border: #29415f;
  --color-text: #f3f7ff;
  --color-text-muted: #9fb2cc;
  --color-accent: #58b0ff;
  --color-control-bg: #0d1627;
  --color-control-border: #304964;
  --color-control-placeholder: #6f88ac;
}

html {
  color-scheme: dark;
}

html[data-theme="light"] {
  color-scheme: light;
  --color-bg: #f4f6fb;
  --color-surface: #ffffff;
  --color-surface-alt: #eef2f7;
  --color-border: rgba(15, 23, 42, 0.14);
  --color-text: #0f172a;
  --color-text-muted: rgba(15, 23, 42, 0.68);
  --color-accent: #1d4ed8;
  --color-control-bg: #ffffff;
  --color-control-border: rgba(15, 23, 42, 0.18);
  --color-control-placeholder: rgba(15, 23, 42, 0.45);
}

body {
  font-family: var(--font-body);
  background: var(--color-bg);
  color: var(--color-text);
  font-weight: 500;
}

.svs-desktop-window-controls {
  position: fixed;
  top: 10px;
  right: 12px;
  z-index: 9999;
  display: flex;
  gap: 8px;
  padding: 6px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.35);
  border: 1px solid rgba(148, 163, 184, 0.18);
  backdrop-filter: blur(8px);
  pointer-events: none;
}

html[data-theme="light"] .svs-desktop-window-controls {
  background: rgba(255, 255, 255, 0.7);
  border-color: rgba(15, 23, 42, 0.12);
}

.svs-desktop-window-controls__btn {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--color-text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  pointer-events: auto;
}

.svs-desktop-window-controls__btn:hover {
  background: rgba(88, 176, 255, 0.14);
}

.svs-desktop-window-controls__btn[data-action="close"]:hover {
  background: rgba(255, 84, 112, 0.18);
}

.svs-desktop-window-controls--nav {
  position: static;
  top: auto;
  right: auto;
  z-index: auto;
  padding: 0;
  background: transparent;
  border: 0;
  backdrop-filter: none;
  pointer-events: auto;
}

.svs-desktop-window-controls--nav .svs-desktop-window-controls__btn {
  width: 30px;
  height: 30px;
}

main.py-3 {
  background: var(--color-bg);
  min-height: calc(100vh - var(--app-nav-height));
}

a {
  color: #8ec9ff;
}

a:hover {
  color: #b8dcff;
}

.text-muted {
  color: var(--color-text-muted) !important;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--color-text);
}

.card {
  background: linear-gradient(180deg, var(--color-surface) 0%, var(--color-surface-alt) 100%);
  border: 1px solid var(--color-border) !important;
  color: var(--color-text);
  border-radius: 12px;
}

.card-header,
.card-footer {
  background: var(--color-surface-alt);
  border-color: var(--color-border);
  color: var(--color-text);
}

.card-footer.bg-white {
  background: var(--color-surface-alt) !important;
}

html[data-theme="dark"] .dropdown-menu,
html[data-theme="dark"] .offcanvas,
html[data-theme="dark"] .offcanvas-header,
html[data-theme="dark"] .offcanvas-body {
  background: linear-gradient(180deg, var(--color-surface) 0%, var(--color-surface-alt) 100%) !important;
  color: var(--color-text) !important;
  border-color: var(--color-border) !important;
}

html[data-theme="dark"] .dropdown-item {
  color: var(--color-text) !important;
}

html[data-theme="dark"] .dropdown-item:hover,
html[data-theme="dark"] .dropdown-item:focus {
  background: rgba(88, 176, 255, 0.1) !important;
  color: var(--color-text) !important;
}

html[data-theme="dark"] .btn-close {
  filter: invert(1) grayscale(1);
}

html[data-theme="dark"] .text-dark {
  color: var(--color-text) !important;
}

.form-label {
  color: var(--color-text-muted);
  font-weight: 600;
}

.form-label.required::after {
  content: " *";
  color: #ff8fa3;
  font-weight: 700;
}

.form-hint {
  color: #8fa7cb;
  font-size: 0.86rem;
}

.required-field {
  border-color: rgba(255, 143, 163, 0.5) !important;
}

.form-control,
.form-select {
  background: var(--color-control-bg);
  border: 1px solid var(--color-control-border);
  color: var(--color-text);
}

.form-control:focus,
.form-select:focus {
  background: var(--color-control-bg);
  border-color: var(--color-accent);
  box-shadow: 0 0 0 0.18rem rgba(79, 182, 255, 0.2);
  color: var(--color-text);
}

.form-control::placeholder {
  color: var(--color-control-placeholder);
}

html[data-theme="dark"] .form-check-input {
  background-color: #122038;
  border-color: rgba(84, 109, 144, 0.55);
}

html[data-theme="dark"] .form-check-input:checked {
  background-color: var(--color-accent);
  border-color: var(--color-accent);
}

html[data-theme="dark"] .form-check-input:focus {
  box-shadow: 0 0 0 0.18rem rgba(79, 182, 255, 0.18);
}

html[data-theme="dark"] .progress {
  --bs-progress-bg: rgba(226, 232, 240, 0.14) !important;
  background-color: rgba(226, 232, 240, 0.14) !important;
}

html[data-theme="dark"] .list-group,
html[data-theme="dark"] .list-group-item,
html[data-theme="dark"] .list-group-item-action {
  --bs-list-group-bg: rgba(255, 255, 255, 0.03) !important;
  --bs-list-group-color: var(--color-text) !important;
  --bs-list-group-border-color: rgba(94, 122, 159, 0.18) !important;
  --bs-list-group-action-hover-bg: rgba(88, 176, 255, 0.08) !important;
  --bs-list-group-action-hover-color: var(--color-text) !important;
  --bs-list-group-action-active-bg: rgba(88, 176, 255, 0.12) !important;
  --bs-list-group-action-active-color: var(--color-text) !important;
  background-color: rgba(255, 255, 255, 0.03) !important;
  color: var(--color-text) !important;
  border-color: rgba(94, 122, 159, 0.18) !important;
}

html[data-theme="dark"] .list-group-item.active {
  background: rgba(88, 176, 255, 0.16) !important;
  color: var(--color-text) !important;
  border-color: rgba(88, 176, 255, 0.26) !important;
}

html[data-theme="dark"] .pagination .page-link {
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(94, 122, 159, 0.24);
  color: var(--color-text);
}

html[data-theme="dark"] .pagination .page-link:hover,
html[data-theme="dark"] .pagination .page-link:focus {
  background: rgba(88, 176, 255, 0.08);
  color: var(--color-text);
}

html[data-theme="dark"] .pagination .page-item.active .page-link {
  background: rgba(88, 176, 255, 0.16);
  border-color: rgba(88, 176, 255, 0.26);
  color: var(--color-text);
}

html[data-theme="dark"] .pagination .page-item.disabled .page-link {
  background: rgba(255, 255, 255, 0.02);
  border-color: rgba(94, 122, 159, 0.16);
  color: var(--color-text-muted);
}

.table {
  --bs-table-bg: var(--color-surface);
  --bs-table-color: var(--color-text);
  --bs-table-border-color: var(--color-border);
  --bs-table-hover-bg: rgba(50, 79, 118, 0.26);
  --bs-table-hover-color: var(--color-text);
  background-color: var(--color-surface);
}

.table thead th {
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 0.78rem;
  font-weight: 700;
}

.table-light,
.table thead.table-light,
.table-light th,
.table-light td {
  --bs-table-bg: #1b2d48 !important;
  --bs-table-color: #d4e6ff !important;
  --bs-table-border-color: rgba(83, 119, 167, 0.28) !important;
  background: #1b2d48 !important;
  color: #d4e6ff !important;
  border-color: rgba(83, 119, 167, 0.28) !important;
}

html[data-theme="dark"] .table > :not(caption) > .table-light > *,
html[data-theme="dark"] .table > :not(caption) > tr.table-light > *,
html[data-theme="dark"] .table > thead.table-light > tr > *,
html[data-theme="dark"] .table > tbody > tr.table-light > * {
  background-color: #1b2d48 !important;
  color: #d4e6ff !important;
  border-color: rgba(83, 119, 167, 0.28) !important;
}

html[data-theme="dark"] .table > :not(caption) > * > * {
  background-color: var(--color-surface);
  color: var(--color-text);
}

html[data-theme="dark"] .table-striped > tbody > tr:nth-of-type(odd) > * {
  background-color: rgba(18, 28, 46, 0.7);
}

html[data-theme="dark"] .table-hover > tbody > tr:hover > * {
  background-color: rgba(50, 79, 118, 0.32);
  color: var(--color-text);
}

html[data-theme="dark"] .text-bg-light,
html[data-theme="dark"] .badge.text-bg-light {
  background-color: #1f314f !important;
  color: #d4e6ff !important;
}

html[data-theme="dark"] .bg-white,
html[data-theme="dark"] .bg-light,
html[data-theme="dark"] .bg-body-tertiary {
  background-color: var(--color-surface) !important;
  color: var(--color-text) !important;
}

.btn {
  border-radius: 10px;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.btn:hover,
.btn:focus {
  transform: translateY(-1px);
}

.btn-primary {
  background: linear-gradient(180deg, rgba(36, 164, 112, 0.98), rgba(24, 120, 80, 0.98));
  border-color: rgba(101, 221, 174, 0.34);
  color: #f7fffb;
  box-shadow: inset 0 1px 0 rgba(214, 255, 236, 0.08), 0 10px 24px rgba(9, 38, 27, 0.18);
}

.btn-primary:hover,
.btn-primary:focus {
  background: linear-gradient(180deg, rgba(42, 182, 125, 1), rgba(28, 133, 89, 1));
  border-color: rgba(126, 236, 194, 0.48);
  color: #ffffff;
  box-shadow: inset 0 1px 0 rgba(214, 255, 236, 0.12), 0 12px 28px rgba(9, 38, 27, 0.24);
}

.btn-outline-primary {
  background: linear-gradient(180deg, rgba(34, 78, 135, 0.92), rgba(24, 58, 101, 0.92));
  border-color: rgba(97, 160, 236, 0.34);
  color: #d9ecff;
  box-shadow: inset 0 1px 0 rgba(191, 224, 255, 0.05);
}

.btn-outline-primary:hover,
.btn-outline-primary:focus {
  background: linear-gradient(180deg, rgba(41, 95, 164, 0.98), rgba(30, 70, 121, 0.98));
  border-color: rgba(124, 183, 248, 0.5);
  color: #ffffff;
}

.btn-outline-secondary {
  background: rgba(18, 32, 52, 0.84);
  border-color: rgba(96, 121, 154, 0.3);
  color: #c7d5ea;
}

.btn-outline-secondary:hover,
.btn-outline-secondary:focus {
  background: rgba(31, 52, 80, 0.94);
  border-color: rgba(128, 156, 193, 0.42);
  color: #ffffff;
}

.btn-outline-dark {
  background: rgba(19, 34, 55, 0.9);
  border-color: rgba(93, 125, 166, 0.28);
  color: #d7e8ff;
}

.btn-outline-dark:hover,
.btn-outline-dark:focus {
  background: rgba(41, 78, 123, 0.94);
  border-color: rgba(128, 176, 237, 0.46);
  color: #fff;
}

.btn-outline-danger {
  background: rgba(49, 20, 28, 0.76);
  border-color: rgba(219, 99, 117, 0.42);
  color: #ffbcc8;
}

.btn-outline-danger:hover,
.btn-outline-danger:focus {
  background: rgba(126, 43, 59, 0.96);
  border-color: rgba(240, 126, 145, 0.58);
  color: #fff;
}

.alert {
  border-width: 1px;
}

.system-flash-stack {
  position: fixed;
  top: calc(var(--app-nav-height) + 6px);
  right: 18px;
  z-index: 1080;
  display: grid;
  gap: 0.7rem;
  width: min(420px, calc(100vw - 24px));
}

.system-flash {
  position: relative;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid rgba(112, 141, 181, 0.26);
  box-shadow: 0 18px 36px rgba(6, 14, 25, 0.28);
  backdrop-filter: blur(10px);
}

.system-flash__body {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: start;
  gap: 0.8rem;
  padding: 0.95rem 1rem;
}

.system-flash__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  font-size: 1rem;
  flex-shrink: 0;
}

.system-flash__message {
  padding-top: 0.18rem;
  font-size: 0.96rem;
  font-weight: 600;
  line-height: 1.45;
}

.system-flash .btn-close {
  filter: invert(1) grayscale(1);
  opacity: 0.72;
  margin-top: 0.1rem;
}

.system-flash .btn-close:hover,
.system-flash .btn-close:focus {
  opacity: 1;
}

.system-flash__progress {
  height: 3px;
  transform-origin: left center;
  animation: system-flash-progress 5s linear forwards;
}

.alert-success.system-flash {
  background: rgba(15, 43, 33, 0.96);
  border-color: rgba(74, 142, 114, 0.42);
  color: #d8f5e7;
}

.alert-success .system-flash__icon {
  background: rgba(36, 122, 88, 0.2);
  color: #80e0b8;
}

.alert-success .system-flash__progress {
  background: linear-gradient(90deg, #3bc48a, #86ebbc);
}

.alert-danger.system-flash {
  background: rgba(52, 23, 31, 0.96);
  border-color: rgba(160, 83, 97, 0.42);
  color: #ffdbe2;
}

.alert-danger .system-flash__icon {
  background: rgba(154, 60, 78, 0.18);
  color: #ff9fb0;
}

.alert-danger .system-flash__progress {
  background: linear-gradient(90deg, #df5d74, #ff97a8);
}

.alert-warning.system-flash {
  background: rgba(58, 43, 18, 0.96);
  border-color: rgba(157, 125, 59, 0.42);
  color: #ffe9be;
}

.alert-warning .system-flash__icon {
  background: rgba(176, 126, 37, 0.2);
  color: #ffd277;
}

.alert-warning .system-flash__progress {
  background: linear-gradient(90deg, #d6a541, #ffd984);
}

html[data-theme="dark"] .alert-warning:not(.system-flash),
.alert-warning:not(.system-flash) {
  --bs-alert-bg: rgba(42, 34, 14, 0.92);
  --bs-alert-color: #f7e1b1;
  --bs-alert-border-color: rgba(150, 122, 58, 0.36);
  background: rgba(42, 34, 14, 0.92);
  border-color: rgba(150, 122, 58, 0.36);
  color: #f7e1b1;
}

html[data-theme="dark"] .alert-warning:not(.system-flash) a,
.alert-warning:not(.system-flash) a {
  color: #ffd277;
}

html[data-theme="dark"] .alert-warning:not(.system-flash) a:hover,
.alert-warning:not(.system-flash) a:hover {
  color: #ffe3a3;
}

html[data-theme="dark"] .alert-info:not(.system-flash) {
  --bs-alert-bg: rgba(18, 40, 64, 0.96);
  --bs-alert-color: #d6edff;
  --bs-alert-border-color: rgba(78, 124, 170, 0.42);
  background: rgba(18, 40, 64, 0.96);
  border-color: rgba(78, 124, 170, 0.42);
  color: #d6edff;
}

html[data-theme="dark"] .bg-warning-subtle {
  background-color: rgba(74, 54, 16, 0.6) !important;
  color: #f7e5be !important;
}

html[data-theme="dark"] .bg-success-subtle {
  background-color: rgba(16, 54, 34, 0.55) !important;
  color: #d3f6e5 !important;
}

html[data-theme="dark"] .bg-primary-subtle {
  background-color: rgba(20, 46, 86, 0.55) !important;
  color: #d4e7ff !important;
}

html[data-theme="dark"] .bg-secondary-subtle {
  background-color: rgba(28, 38, 56, 0.55) !important;
  color: #d8e2f0 !important;
}

html[data-theme="dark"] .alert-secondary,
html[data-theme="dark"] .alert-light {
  background: rgba(24, 35, 54, 0.96);
  border-color: rgba(94, 122, 159, 0.3);
  color: var(--color-text);
}

.alert-info.system-flash {
  background: rgba(19, 41, 63, 0.96);
  border-color: rgba(78, 124, 170, 0.42);
  color: #d6edff;
}

.alert-info .system-flash__icon {
  background: rgba(59, 116, 180, 0.18);
  color: #8ec9ff;
}

.alert-info .system-flash__progress {
  background: linear-gradient(90deg, #4da8ff, #9fd5ff);
}

@keyframes system-flash-progress {
  from {
    transform: scaleX(1);
  }
  to {
    transform: scaleX(0);
  }
}

.badge.text-bg-dark {
  background: #20324d !important;
  color: #d5e8ff !important;
}

.bg-secondary-subtle {
  background: rgba(97, 124, 160, 0.16) !important;
}

.text-secondary-emphasis {
  color: #d7e6fb !important;
}

/* Bootstrap "subtle" backgrounds and body tints are too bright without data-bs-theme.
 * Make them night-friendly in our dark theme. */
html[data-theme="dark"] .bg-body-tertiary {
  background: rgba(255, 255, 255, 0.04) !important;
  color: var(--color-text) !important;
}

html[data-theme="dark"] .bg-success-subtle {
  background: rgba(36, 164, 112, 0.18) !important;
}

html[data-theme="dark"] .text-success-emphasis {
  color: rgba(126, 236, 194, 0.92) !important;
}

html[data-theme="dark"] .bg-warning-subtle {
  background: rgba(176, 126, 37, 0.2) !important;
}

html[data-theme="dark"] .text-warning-emphasis {
  color: #ffd277 !important;
}

html[data-theme="dark"] .bg-info-subtle {
  background: rgba(59, 116, 180, 0.16) !important;
}

html[data-theme="dark"] .text-info-emphasis {
  color: #bfe0ff !important;
}

.bg-success-subtle {
  background: rgba(36, 164, 112, 0.14) !important;
}

.text-success-emphasis {
  color: #baf0d5 !important;
}

.bg-warning-subtle {
  background: rgba(214, 165, 65, 0.16) !important;
}

.text-warning-emphasis {
  color: #ffd98a !important;
}

.navbar {
  background: linear-gradient(90deg, #10192c, #15243c) !important;
  padding-block: 0.35rem;
}

.navbar .navbar-collapse {
  gap: 0.5rem;
}

.navbar .navbar-nav {
  flex-wrap: wrap;
  row-gap: 0.35rem;
}

.navbar-brand {
  font-family: var(--font-brand);
  font-size: 1.15rem;
  letter-spacing: 0.01em;
  font-weight: 700;
}

.navbar-brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.navbar-brand-title {
  display: block;
}

.navbar-brand-subtitle {
  display: block;
  margin-top: 0.12rem;
  color: #9fb2cc;
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.navbar-brand .brand-accent {
  color: #48d7ff;
}

.navbar .nav-link {
  color: #f3f8ff !important;
  border: 1px solid rgba(95, 120, 152, 0.18);
  border-radius: 8px;
  margin-left: 0.2rem;
  padding-inline: 0.62rem !important;
  padding-block: 0.45rem !important;
  white-space: nowrap;
  line-height: 1.15;
  font-size: 0.9rem;
  transition: all 0.18s ease;
  background: rgba(13, 22, 39, 0.52);
}

.navbar .nav-link:hover {
  background: rgba(72, 101, 141, 0.18);
  border-color: rgba(130, 162, 206, 0.4);
  color: #ffffff !important;
}

.navbar .nav-link.active {
  background: linear-gradient(180deg, rgba(45, 92, 151, 0.74), rgba(31, 64, 109, 0.74));
  border-color: rgba(141, 178, 223, 0.62);
  color: #ffffff !important;
  box-shadow: 0 10px 20px rgba(7, 17, 32, 0.24);
}

.top-search-form {
  position: relative;
  gap: 0.45rem;
  margin-right: 0.65rem;
  min-width: 240px;
  max-width: 380px;
  flex: 1 1 280px;
  padding: 0.18rem;
  border-radius: 12px;
  background: rgba(9, 20, 34, 0.5);
  border: 1px solid rgba(79, 118, 172, 0.24);
}

.top-search-form > i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #7ea8d9;
  pointer-events: none;
  z-index: 2;
}

.top-search-form .form-control {
  padding-left: 34px;
  min-width: 0;
  width: 100%;
}

.top-search-form__hint {
  align-items: center;
  justify-content: center;
  min-width: 56px;
  padding: 0.18rem 0.44rem;
  border-radius: 8px;
  border: 1px solid rgba(122, 156, 204, 0.35);
  background: rgba(17, 31, 48, 0.78);
  color: #c2d4ef;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.top-search-form .btn {
  min-width: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-inline: 0.75rem;
}

.top-search-form .btn i {
  position: static;
  transform: none;
  color: currentColor;
  pointer-events: auto;
  font-size: 0.95rem;
  line-height: 1;
}

.navbar-user-tools {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.42rem;
  flex-shrink: 0;
  flex-wrap: nowrap;
}

.navbar-user-tools__cash {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: nowrap;
  order: 1;
}

.sidebar-toggle-btn,
.theme-toggle-btn {
  min-height: 34px !important;
  width: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(132, 155, 189, 0.38);
  border-radius: 10px;
  background: rgba(17, 31, 49, 0.78);
  color: #eef5ff;
  padding: 0;
}

.sidebar-toggle-btn {
  order: 2;
}

.theme-toggle-btn {
  order: 3;
}

.sidebar-toggle-btn:hover,
.sidebar-toggle-btn:focus,
.theme-toggle-btn:hover,
.theme-toggle-btn:focus {
  border-color: rgba(169, 194, 226, 0.6);
  background: rgba(28, 47, 72, 0.92);
  color: #ffffff;
}

.navbar-logout-btn {
  order: 4;
  margin-left: auto;
  min-height: 34px !important;
  padding: 0.35rem 0.75rem;
  border: 1px solid rgba(132, 155, 189, 0.38);
  border-radius: 10px;
  background: rgba(17, 31, 49, 0.78);
  color: #eef5ff;
  font-size: 0.8rem;
  font-weight: 700;
}

.navbar-logout-btn:hover,
.navbar-logout-btn:focus {
  border-color: rgba(169, 194, 226, 0.6);
  background: rgba(28, 47, 72, 0.92);
  color: #ffffff;
}

.cash-top-actions__btn--open-cta-navbar,
.cash-top-actions__btn--close-cta-navbar {
  min-width: 108px;
  min-height: 34px !important;
  padding: 0.34rem 0.72rem;
  font-size: 0.78rem;
  border-radius: 10px;
}

.navbar-user-tools__cash .cash-top-actions__btn {
  min-height: 34px !important;
  padding: 0.34rem 0.68rem;
  font-size: 0.78rem;
  border-radius: 10px;
}

.cash-top-actions__btn--nav-secondary {
  min-width: 92px;
}

.app-shell {
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
  gap: 0;
}

.app-shell__main {
  min-width: 0;
}

.app-sidebar {
  background: var(--color-surface-alt);
  border-right: 1px solid var(--color-border);
  padding: 0.75rem 0.42rem 0.75rem 0.52rem;
}

.app-sidebar__inner {
  flex: 1 1 auto;
  width: 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: var(--app-nav-height);
  height: calc(100vh - var(--app-nav-height));
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 0;
  scrollbar-width: thin;
  scrollbar-color: rgba(132, 155, 189, 0.52) transparent;
}

.app-sidebar__inner::-webkit-scrollbar {
  width: 8px;
}

.app-sidebar__inner::-webkit-scrollbar-track {
  background: transparent;
}

.app-sidebar__inner::-webkit-scrollbar-thumb {
  background: rgba(132, 155, 189, 0.52);
  border-radius: 999px;
}

.app-sidebar__inner::-webkit-scrollbar-thumb:hover {
  background: rgba(156, 182, 220, 0.72);
}

.app-sidebar__nav {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  width: 100%;
}

.app-sidebar__row {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.app-sidebar__row .app-sidebar__link {
  flex: 1 1 auto;
  min-width: 0;
}

.app-sidebar__top {
  display: none;
  justify-content: flex-end;
  padding: 0 0.15rem 0.55rem;
}

.app-sidebar__collapse-btn.sidebar-toggle-btn {
  width: 34px;
  min-height: 34px !important;
  border-radius: 12px;
  border: 0 !important;
  outline: none !important;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: none;
  color: rgba(243, 247, 255, 0.96);
}

.app-sidebar__collapse-btn.sidebar-toggle-btn:hover,
.app-sidebar__collapse-btn.sidebar-toggle-btn:focus {
  border-color: transparent !important;
  outline: none !important;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: none;
  color: #ffffff;
}

.app-sidebar__collapse-btn.sidebar-toggle-btn:focus-visible {
  border: 0 !important;
  outline: none !important;
  box-shadow: none !important;
}

.app-sidebar__collapse-btn--inline.sidebar-toggle-btn {
  width: 30px;
  min-height: 30px !important;
  border-radius: 10px;
}

.app-sidebar__link {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  width: 100%;
  padding: 0.58rem 0.7rem;
  border-radius: 12px;
  text-decoration: none;
  border: 1px solid transparent;
  color: var(--color-text-muted);
  font-weight: 700;
  font-size: 0.92rem;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.app-sidebar__link i {
  font-size: 1rem;
  opacity: 0.9;
}

.app-sidebar__link:hover,
.app-sidebar__link:focus {
  background: rgba(29, 78, 216, 0.08);
  border-color: var(--color-border);
  color: var(--color-text);
}

.app-sidebar__link.is-active {
  background: rgba(29, 78, 216, 0.14);
  border-color: rgba(29, 78, 216, 0.28);
  color: var(--color-text);
}

.app-sidebar__link--attention {
  border-color: rgba(245, 158, 11, 0.18);
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.08), rgba(15, 23, 42, 0));
}

.app-sidebar__link--attention:hover,
.app-sidebar__link--attention:focus {
  border-color: rgba(245, 158, 11, 0.32);
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.14), rgba(15, 23, 42, 0));
}

.app-sidebar__link--attention.is-active {
  border-color: rgba(245, 158, 11, 0.45);
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.22), rgba(15, 23, 42, 0));
  color: #fff7e6;
}

.attention-badge {
  border-radius: 999px;
  padding: 0.18rem 0.5rem;
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  box-shadow: 0 0 0 1px rgba(245, 158, 11, 0.4), 0 8px 16px rgba(245, 158, 11, 0.2);
  animation: attention-pulse 2.6s ease-in-out infinite;
}

@keyframes attention-pulse {
  0%,
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 1px rgba(245, 158, 11, 0.35), 0 8px 16px rgba(245, 158, 11, 0.18);
  }
  50% {
    transform: scale(1.04);
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.45), 0 10px 18px rgba(245, 158, 11, 0.26);
  }
}

.app-sidebar__link--cashier {
  border-color: rgba(16, 185, 129, 0.22);
}

.app-sidebar__link--cashier:hover,
.app-sidebar__link--cashier:focus {
  background: rgba(16, 185, 129, 0.1);
  border-color: rgba(16, 185, 129, 0.32);
}

.app-sidebar__link--cashier.is-active {
  background: rgba(16, 185, 129, 0.16);
  border-color: rgba(16, 185, 129, 0.38);
}

.app-sidebar__divider {
  border-top: 1px solid var(--color-border);
  opacity: 0.7;
  margin: 0.55rem 0.25rem 0.3rem;
}

.app-sidebar__heading {
  margin: 0.35rem 0.7rem 0.05rem;
  color: var(--color-text-muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

html[data-sidebar="collapsed"] .app-shell {
  grid-template-columns: 50px minmax(0, 1fr);
}

html[data-sidebar="collapsed"] .app-sidebar {
  padding: 0.55rem 0.04rem;
}

html[data-sidebar="collapsed"] .app-sidebar__inner {
  padding-right: 0;
}

html[data-sidebar="collapsed"] .app-sidebar__top {
  display: flex;
  justify-content: center;
  padding: 0 0 0.28rem;
}

html[data-sidebar="collapsed"] .app-sidebar__collapse-btn.sidebar-toggle-btn {
  width: 30px;
  min-height: 30px !important;
  border-radius: 10px;
}

html[data-sidebar="collapsed"] .app-sidebar__collapse-btn--inline {
  display: none;
}

html[data-sidebar="collapsed"] .app-sidebar__link {
  justify-content: center;
  padding: 0.54rem 0;
}

html[data-sidebar="collapsed"] .app-sidebar__link span {
  display: none;
}

html[data-sidebar="collapsed"] .app-sidebar__heading {
  display: none;
}

html[data-sidebar="collapsed"] .app-sidebar__divider {
  width: 20px;
  margin: 0.55rem auto 0.3rem;
}

@media (max-width: 991.98px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  html[data-sidebar="collapsed"] .app-shell {
    grid-template-columns: 1fr;
  }
}

.navbar .admin-link {
  color: #9fd1ff !important;
  border-color: rgba(104, 159, 233, 0.42);
}

.navbar .admin-link:hover {
  background: rgba(58, 110, 180, 0.38);
  border-color: rgba(132, 183, 255, 0.65);
  color: #e8f4ff !important;
}

.navbar .admin-link.active {
  background: rgba(66, 124, 202, 0.5);
  border-color: rgba(145, 191, 255, 0.86);
  color: #ffffff !important;
}

.navbar .nav-link--cashier {
  border: 1px solid rgba(67, 182, 123, 0.38);
  background: rgba(23, 92, 58, 0.26);
  color: #dff8ea !important;
}

.navbar .nav-link--cashier:hover,
.navbar .nav-link--cashier:focus {
  border-color: rgba(94, 217, 150, 0.55);
  background: rgba(27, 108, 67, 0.4);
  color: #ffffff !important;
}

.navbar .nav-link--cashier.active {
  border-color: rgba(96, 233, 159, 0.92);
  background: linear-gradient(180deg, rgba(46, 173, 103, 0.95), rgba(30, 139, 80, 0.95));
  color: #ffffff !important;
  box-shadow: 0 8px 18px rgba(25, 103, 61, 0.28);
}

.brand-logo-nav {
  width: 84px;
  height: 84px;
  border-radius: 999px;
  overflow: hidden;
  display: inline-block;
  flex-shrink: 0;
  border: none;
  box-shadow: none;
}

.brand-logo-login {
  width: clamp(160px, 20vw, 220px);
  height: clamp(160px, 20vw, 220px);
  border-radius: 999px;
  overflow: hidden;
  display: inline-block;
  border: none;
  box-shadow: none;
}

.logo-zoom-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: none;
  display: block;
  border-radius: inherit;
}

.system-footer {
  border-top: 1px solid var(--color-border);
  background: var(--color-surface-alt);
}

.system-footer__copy {
  font-size: 0.74rem;
  color: var(--color-text-muted);
  text-align: left;
}

.login-shell {
  position: fixed;
  inset: 0;
  z-index: 20;
  min-height: 100vh;
  overflow-y: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background:
    radial-gradient(1200px circle at 20% 10%, rgba(88, 176, 255, 0.22), transparent 55%),
    radial-gradient(900px circle at 80% 20%, rgba(36, 164, 112, 0.18), transparent 55%),
    linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
}

.login-shell__frame {
  width: min(100%, 760px);
  margin: 0 auto;
}

.login-shell__col {
  width: 100%;
}

.login-card {
  width: 100%;
  max-width: 760px;
  margin: 0;
  background: linear-gradient(180deg, var(--color-surface) 0%, var(--color-surface-alt) 100%);
  border: 1px solid var(--color-border) !important;
  color: var(--color-text);
  border-radius: 22px;
  box-shadow: 0 24px 60px rgba(4, 10, 18, 0.42);
  transform: translateY(0) scale(1);
  animation: login-card-in 280ms ease both;
}

.login-card h1 {
  letter-spacing: 0.01em;
  white-space: normal;
}

.login-card:hover {
  transform: translateY(-2px) scale(1.01);
}

.login-title {
  font-family: var(--font-brand);
  font-weight: 800;
  font-size: clamp(1.5rem, 3.6vw, 2.05rem);
  line-height: 1.1;
  margin: 0;
  background: linear-gradient(135deg, rgba(88, 176, 255, 1) 0%, rgba(126, 236, 194, 1) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.login-subtitle {
  color: var(--color-text-muted);
  font-weight: 600;
}

.login-footnote {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  font-weight: 600;
}

.login-password-toggle {
  position: absolute;
  top: 50%;
  right: 0.7rem;
  transform: translateY(-50%);
  border: 0;
  background: transparent;
  color: var(--color-text-muted);
  padding: 0.25rem 0.5rem;
  border-radius: 10px;
  line-height: 1;
}

.login-password-toggle:hover,
.login-password-toggle:focus {
  color: var(--color-text);
  background: rgba(88, 176, 255, 0.1);
  outline: none;
}

.login-submit {
  box-shadow: inset 0 1px 0 rgba(214, 255, 236, 0.12), 0 14px 30px rgba(9, 38, 27, 0.22);
}

.login-card .form-label {
  color: var(--color-text-muted);
  font-weight: 600;
}

.login-card .form-control {
  background: var(--color-control-bg);
  border: 1px solid var(--color-control-border);
  color: var(--color-text);
}

.login-card .form-control:focus {
  border-color: var(--color-accent);
  box-shadow: 0 0 0 0.18rem rgba(79, 182, 255, 0.25);
}

.login-card .text-muted {
  color: var(--color-text-muted) !important;
}

html[data-theme="light"] .login-shell {
  background:
    radial-gradient(1200px circle at 20% 10%, rgba(29, 78, 216, 0.08), transparent 55%),
    radial-gradient(900px circle at 80% 20%, rgba(16, 185, 129, 0.08), transparent 55%),
    #f4f6fb;
}

@keyframes login-card-in {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.cash-auth-dialog {
  max-width: 500px;
}

.cash-auth-modal {
  background: linear-gradient(180deg, var(--color-surface) 0%, var(--color-surface-alt) 100%);
  border: 1px solid var(--color-border) !important;
  border-radius: 36px;
  box-shadow: 0 20px 48px rgba(4, 10, 18, 0.34);
}

.cash-auth-modal__body {
  position: relative;
  padding: 1.75rem;
}

.cash-auth-modal__close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  opacity: 0.78;
}

.cash-auth-modal__close:hover,
.cash-auth-modal__close:focus {
  opacity: 1;
}

.cash-auth-modal__logo {
  width: 120px;
  height: 120px;
  border-radius: 999px;
  overflow: hidden;
  display: inline-block;
  border: none;
  box-shadow: none;
}

.cash-auth-modal__kicker {
  margin-bottom: 0.35rem;
  color: var(--color-text-muted);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.cash-auth-form .form-label {
  color: var(--color-text-muted);
}

.cash-auth-form .form-control {
  background: var(--color-control-bg);
  border: 1px solid var(--color-control-border);
  color: var(--color-text);
  border-radius: 999px;
}

.cash-auth-form .form-control:focus {
  border-color: var(--color-accent);
  box-shadow: 0 0 0 0.18rem rgba(79, 182, 255, 0.25);
}

.cash-auth-modal__actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
  max-width: 360px;
  margin: 1.25rem auto 0;
}

.cash-auth-modal__actions--single {
  grid-template-columns: 1fr;
  max-width: 260px;
}

.cash-auth-modal__actions .btn {
  min-height: 46px;
  border-radius: 999px;
}

.checklist-grid .checklist-item {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 0.55rem 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.checklist-grid .checklist-item .form-check-input {
  margin-top: 0;
}

.package-picker {
  background: #0a1525;
  border-color: rgba(85, 123, 177, 0.35) !important;
}

.package-btn {
  min-height: 90px;
  border-color: rgba(75, 130, 207, 0.45);
  color: #d8e9ff;
  background: rgba(13, 32, 55, 0.45);
}

.package-btn:hover {
  background: rgba(56, 97, 154, 0.34);
  border-color: rgba(102, 163, 248, 0.8);
  color: #f3f8ff;
}

.package-btn.active,
.package-btn:active {
  background: linear-gradient(90deg, rgba(37, 134, 238, 0.85), rgba(31, 110, 204, 0.8)) !important;
  color: #ffffff !important;
  border-color: rgba(104, 172, 255, 0.95) !important;
}

.package-btn.active .text-muted {
  color: #e7f3ff !important;
}

.page-header-card {
  background: transparent;
  border: 0 !important;
  border-radius: 0;
  padding: 0;
  box-shadow: none;
}

.section-kicker {
  display: none;
}

.page-header-card .text-muted {
  display: none;
}

.page-header-card .h4,
.page-header-card .h3,
.page-header-card h1 {
  margin-bottom: 0 !important;
}

.crm-search {
  width: min(360px, 100%);
}

.metric-card,
.result-count-card,
.workorder-summary-card {
  background: linear-gradient(180deg, rgba(17, 33, 55, 0.95), rgba(11, 22, 39, 0.95));
  border: 1px solid rgba(83, 119, 167, 0.32) !important;
  box-shadow: 0 12px 24px rgba(3, 10, 23, 0.16);
}

.summary-panel-card {
  background: linear-gradient(180deg, rgba(17, 33, 55, 0.96), rgba(11, 22, 39, 0.96));
  border: 1px solid rgba(94, 122, 159, 0.28) !important;
  box-shadow: 0 14px 28px rgba(3, 10, 23, 0.18);
}

.summary-panel-card .card-body {
  padding: 1rem 1.05rem;
}

.summary-panel-label {
  display: block;
  color: #a7bbd7;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.summary-panel-value {
  display: block;
  margin-top: 0.28rem;
  color: #f5f9ff;
  font-size: 1.7rem;
  line-height: 1.05;
  font-weight: 700;
}

.summary-panel-value--success {
  color: #baf0d5;
}

.summary-panel-value--warning {
  color: #f5dca4;
}

.summary-panel-value--danger {
  color: #ffbcc8;
}

/* Dashboard: seller KPIs (clean, high-signal). */
.seller-kpis .summary-panel-card {
  position: relative;
  overflow: hidden;
}

.seller-kpis .summary-panel-card .card-body {
  position: relative;
}

.seller-kpis .summary-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.seller-kpis .summary-panel-icon {
  width: 36px;
  height: 36px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(94, 122, 159, 0.25);
  background: rgba(13, 22, 39, 0.55);
  color: rgba(245, 249, 255, 0.88);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.seller-kpis .summary-panel-meta {
  display: block;
  margin-top: 0.4rem;
  font-size: 0.82rem;
  color: var(--color-text-muted);
}

.seller-kpis .summary-panel-meta strong {
  color: #e7f0ff;
  font-weight: 700;
}

.seller-kpis .summary-panel-card--success {
  border-color: rgba(34, 197, 94, 0.28) !important;
}

.seller-kpis .summary-panel-card--success .summary-panel-icon {
  border-color: rgba(34, 197, 94, 0.25);
  background: rgba(34, 197, 94, 0.10);
  color: #baf0d5;
}

.seller-kpis .summary-panel-card--info {
  border-color: rgba(88, 176, 255, 0.28) !important;
}

.seller-kpis .summary-panel-card--info .summary-panel-icon {
  border-color: rgba(88, 176, 255, 0.22);
  background: rgba(88, 176, 255, 0.10);
  color: #cfe8ff;
}

.seller-kpis .summary-panel-card--danger {
  border-color: rgba(255, 143, 163, 0.30) !important;
}

.seller-kpis .summary-panel-card--danger .summary-panel-icon {
  border-color: rgba(255, 143, 163, 0.24);
  background: rgba(255, 143, 163, 0.10);
  color: #ffbcc8;
}

/* Dashboard: "Meu Negocio" + pendencias (Bling-like quick insights). */
.dashboard-insight-card {
  background: linear-gradient(180deg, rgba(17, 33, 55, 0.96), rgba(11, 22, 39, 0.96));
  border: 1px solid rgba(94, 122, 159, 0.24) !important;
  box-shadow: 0 14px 28px rgba(3, 10, 23, 0.16);
}

.dashboard-onboarding-card {
  background: linear-gradient(180deg, rgba(17, 33, 55, 0.96), rgba(11, 22, 39, 0.96));
  border: 1px solid rgba(94, 122, 159, 0.24) !important;
  box-shadow: 0 14px 28px rgba(3, 10, 23, 0.16);
}

.dashboard-onboarding-progress {
  --bs-progress-bg: rgba(226, 232, 240, 0.14) !important;
  background: rgba(226, 232, 240, 0.14) !important;
}

.dashboard-onboarding-list {
  --bs-list-group-bg: rgba(255, 255, 255, 0.03) !important;
  --bs-list-group-color: var(--color-text) !important;
  --bs-list-group-border-color: rgba(94, 122, 159, 0.18) !important;
  --bs-list-group-action-hover-bg: rgba(88, 176, 255, 0.08) !important;
  --bs-list-group-action-hover-color: var(--color-text) !important;
  --bs-list-group-action-active-bg: rgba(88, 176, 255, 0.12) !important;
  --bs-list-group-action-active-color: var(--color-text) !important;
}

.dashboard-onboarding-list .list-group-item {
  color: var(--color-text);
  background: rgba(255, 255, 255, 0.03) !important;
  border-color: rgba(94, 122, 159, 0.18) !important;
}

html[data-theme="dark"] .dashboard-onboarding-list,
html[data-theme="dark"] .dashboard-onboarding-list .list-group-item,
html[data-theme="dark"] .dashboard-onboarding-list .list-group-item-action {
  --bs-list-group-bg: rgba(255, 255, 255, 0.03) !important;
  --bs-list-group-color: var(--color-text) !important;
  --bs-list-group-border-color: rgba(94, 122, 159, 0.18) !important;
  --bs-list-group-action-hover-bg: rgba(88, 176, 255, 0.08) !important;
  --bs-list-group-action-active-bg: rgba(88, 176, 255, 0.12) !important;
  background-color: rgba(255, 255, 255, 0.03) !important;
  color: var(--color-text) !important;
  border-color: rgba(94, 122, 159, 0.18) !important;
}

.dashboard-onboarding-list .list-group-item:hover,
.dashboard-onboarding-list .list-group-item:focus {
  background: rgba(88, 176, 255, 0.08) !important;
}

.dashboard-onboarding-list .list-group-item .text-muted,
.dashboard-onboarding-card .text-muted {
  color: var(--color-text-muted) !important;
}

.dashboard-onboarding-list .list-group-item:first-child {
  border-top-left-radius: 14px;
  border-top-right-radius: 14px;
}

.dashboard-onboarding-list .list-group-item:last-child {
  border-bottom-left-radius: 14px;
  border-bottom-right-radius: 14px;
}

.mini-flow-chart {
  display: flex;
  align-items: flex-end;
  gap: 0.7rem;
  padding: 0.8rem 0.8rem 0.6rem;
  min-height: 160px;
  border-radius: 12px;
  border: 1px solid rgba(94, 122, 159, 0.18);
  background: rgba(13, 22, 39, 0.55);
}

.mini-flow-day {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.mini-flow-bars {
  height: 112px;
  display: flex;
  align-items: flex-end;
  gap: 4px;
}

.mini-flow-bar {
  width: 10px;
  border-radius: 999px 999px 2px 2px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.mini-flow-bar--in {
  background: rgba(88, 176, 255, 0.85);
}

.mini-flow-bar--out {
  background: rgba(255, 143, 163, 0.85);
}

.mini-flow-label {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
}

.mini-flow-legend {
  margin-top: 0.65rem;
  display: flex;
  gap: 1.1rem;
  flex-wrap: wrap;
  font-size: 0.82rem;
  color: var(--color-text-muted);
}

.mini-flow-dot {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  margin-right: 0.4rem;
  vertical-align: -1px;
}

.mini-flow-dot--in {
  background: rgba(88, 176, 255, 0.95);
}

.mini-flow-dot--out {
  background: rgba(255, 143, 163, 0.95);
}

.top-list-block + .top-list-block {
  margin-top: 0.9rem;
}

.top-list-title,
.status-block-title {
  color: var(--color-text-muted);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.45rem;
}

.top-list {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.top-list-item {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.75rem;
  padding: 0.45rem 0;
  border-bottom: 1px solid rgba(94, 122, 159, 0.18);
}

.top-list-item:last-child {
  border-bottom: 0;
}

.top-list-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--color-text);
}

.top-list-value {
  color: var(--color-text);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.status-block + .status-block {
  margin-top: 1rem;
}

.status-pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  border: 1px solid rgba(94, 122, 159, 0.22);
  background: rgba(13, 22, 39, 0.45);
  color: var(--color-text-muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.status-pill strong {
  color: var(--color-text);
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.pending-block {
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 0.85rem 0.9rem;
  border-radius: 12px;
  border: 1px solid rgba(94, 122, 159, 0.22);
  background: rgba(13, 22, 39, 0.48);
}

.pending-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  font-weight: 800;
  color: var(--color-text);
}

.pending-list {
  list-style: none;
  padding-left: 0;
  margin: 0.75rem 0 0;
  flex: 1 1 auto;
}

.pending-item {
  padding: 0.55rem 0;
  border-bottom: 1px solid rgba(94, 122, 159, 0.16);
}

.pending-item:last-child {
  border-bottom: 0;
}

.pending-link {
  color: var(--color-text);
  font-weight: 900;
  text-decoration: none;
}

.pending-link:hover,
.pending-link:focus {
  text-decoration: underline;
  color: var(--color-text);
}

.pending-meta {
  margin-top: 0.18rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
  color: var(--color-text-muted);
  font-size: 0.82rem;
}

.pending-flag {
  display: inline-flex;
  align-items: center;
  padding: 0.12rem 0.5rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.pending-flag--danger {
  background: rgba(255, 143, 163, 0.14);
  border: 1px solid rgba(255, 143, 163, 0.32);
  color: rgba(255, 188, 200, 0.95);
}

.pending-flag--warning {
  background: rgba(244, 188, 74, 0.14);
  border: 1px solid rgba(244, 188, 74, 0.32);
  color: rgba(245, 220, 164, 0.95);
}

.pending-more {
  margin-top: 0.6rem;
  color: #8ec9ff;
  font-weight: 800;
  font-size: 0.82rem;
  text-decoration: none;
}

.pending-more:hover,
.pending-more:focus {
  color: #b8dcff;
  text-decoration: underline;
}

@media (max-width: 576px) {
  .mini-flow-chart {
    gap: 0.5rem;
    padding: 0.7rem 0.6rem 0.5rem;
  }

  .mini-flow-bars {
    gap: 3px;
  }

  .mini-flow-bar {
    width: 9px;
  }
}

.workorder-summary-card--warning {
  border-top: 2px solid rgba(244, 188, 74, 0.9) !important;
}

.workorder-summary-card--success {
  border-top: 2px solid rgba(55, 207, 143, 0.85) !important;
}

.workorder-summary-card--info {
  border-top: 2px solid rgba(79, 182, 255, 0.9) !important;
}

.summary-number {
  font-size: 2rem;
  line-height: 1;
  font-weight: 700;
  color: #f4f8ff;
}

.summary-text {
  margin-top: 0.45rem;
  color: #9fb5d5;
  font-size: 0.94rem;
}

.workorder-filter-check {
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 0.95rem;
  border-radius: 12px;
  background: rgba(9, 18, 32, 0.78);
  border: 1px solid rgba(83, 119, 167, 0.28);
}

.workorder-filter-check .form-check-input {
  margin-top: 0;
}

.row-overdue td {
  background: rgba(128, 48, 52, 0.14) !important;
}

.metric-title {
  font-size: 1.06rem;
  font-weight: 700;
  color: #f4f8ff;
}

.metric-note {
  margin-top: 0.35rem;
  color: #9fb5d5;
  font-size: 0.92rem;
}

.info-stack {
  display: grid;
  gap: 1rem;
}

.compact-info-stack {
  gap: 0.75rem;
}

.info-block {
  padding: 1rem;
  border-radius: 12px;
  background: rgba(9, 18, 32, 0.58);
  border: 1px solid rgba(83, 119, 167, 0.22);
}

.info-label {
  display: block;
  margin-bottom: 0.35rem;
  color: #94c8ff;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.quick-info-list {
  display: grid;
  gap: 0.75rem;
}

.quick-info-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.85rem 0.95rem;
  border-radius: 12px;
  background: rgba(9, 18, 32, 0.58);
  border: 1px solid rgba(83, 119, 167, 0.22);
}

.search-hero .form-control-lg {
  min-height: 58px;
  font-size: 1.02rem;
}

.search-hero-badge {
  align-self: flex-start;
}

.featured-result-card {
  border: 1px solid rgba(95, 163, 255, 0.42) !important;
  box-shadow: 0 14px 32px rgba(8, 22, 41, 0.22);
}

.result-section .table th,
.result-section .table td {
  vertical-align: middle;
}

.quote-action-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.6rem;
}

.quote-action-bar__group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.quote-action-bar .btn {
  min-width: 96px;
  padding-inline: 0.9rem;
}

.quote-action-bar__group--highlight .btn-success {
  min-width: 120px;
}

.quote-whatsapp-help {
  border: 1px solid rgba(45, 166, 104, 0.35) !important;
}

.advanced-filters-panel {
  padding: 1rem;
  border-radius: 14px;
  background: rgba(8, 18, 32, 0.72);
  border: 1px solid rgba(83, 119, 167, 0.24);
}

.history-panel {
  padding: 0.8rem;
  border-radius: 14px;
  background: rgba(8, 18, 32, 0.56);
  border: 1px solid rgba(83, 119, 167, 0.2);
}

.simple-toolbar {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) auto auto auto;
  gap: 0.75rem;
  align-items: center;
}

.compact-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.compact-stat-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.38rem 0.7rem;
  border-radius: 12px;
  background: #0b1322;
  border: 1px solid rgba(84, 109, 144, 0.26);
  color: #dce8fd;
  font-size: 0.8rem;
}

.compact-stat-pill small {
  display: inline-block;
  color: #90a6c5;
  font-size: 0.66rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.compact-stat-pill strong {
  color: #ffffff;
  font-size: 0.92rem;
}

.compact-stat-pill--toggle {
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.compact-stat-pill--toggle:hover,
.compact-stat-pill--toggle:focus {
  border-color: rgba(111, 151, 206, 0.46);
  background: #0e182a;
}

.compact-stat-pill__value {
  transition: filter 0.2s ease, opacity 0.2s ease;
}

.compact-stat-pill__value--masked {
  filter: blur(6px);
  opacity: 0.78;
}

.compact-stat-pill__value--revealed {
  filter: blur(0);
  opacity: 1;
}

.compact-stat-pill--warning {
  border-color: rgba(244, 188, 74, 0.44);
}

.compact-stat-pill--success {
  border-color: rgba(35, 181, 122, 0.42);
}

.compact-stat-pill--info {
  border-color: rgba(79, 182, 255, 0.45);
}

.cash-status-badge,
.cash-entry-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.38rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(83, 119, 167, 0.28);
  background: rgba(11, 23, 39, 0.72);
  color: #dce8fd;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.cash-status-badge--open {
  border-color: rgba(63, 146, 112, 0.36);
  color: #b9f0d5;
}

.cash-status-badge--closed {
  border-color: rgba(103, 124, 156, 0.32);
  color: #c2d3ec;
}

.cash-entry-badge--in {
  border-color: rgba(63, 146, 112, 0.34);
  background: rgba(20, 58, 45, 0.38);
  color: #b9f0d5;
}

.cash-entry-badge--out {
  border-color: rgba(158, 129, 73, 0.34);
  background: rgba(60, 45, 18, 0.34);
  color: #f1d49a;
}

.cash-entry-amount--in {
  color: #d8f8e9;
}

.cash-entry-amount--out {
  color: #f3dcad;
}

.cash-stock-hint--danger {
  color: #ff8f98;
  font-weight: 700;
}

.cash-entry-row--canceled td {
  opacity: 0.68;
}

.cash-batch {
  border-top: 1px solid rgba(76, 108, 153, 0.18);
  padding-top: 0.9rem;
}

.cash-batch--inline {
  padding-top: 0.7rem;
}

.cash-batch-table-wrap {
  border: 1px solid rgba(76, 108, 153, 0.2);
  border-radius: 14px;
  overflow: hidden;
}

.cash-batch-table-wrap .table th,
.cash-batch-table-wrap .table td {
  padding-block: 0.34rem;
  font-size: 0.9rem;
}

.cash-batch-table-wrap .table th {
  color: #9ab1d1;
  font-size: 0.73rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.cash-price-preview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.45rem;
}

.cash-price-preview {
  min-width: 0;
  padding: 0.45rem 0.55rem;
  border: 1px solid rgba(84, 109, 144, 0.26);
  border-radius: 12px;
  background: rgba(13, 22, 39, 0.76);
}

.cash-price-preview__head,
.cash-price-preview__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.cash-price-preview__head {
  margin-bottom: 0.08rem;
  color: #dce8fd;
  font-size: 0.8rem;
}

.cash-price-preview__head strong {
  color: #ffffff;
  font-size: 0.92rem;
}

.cash-price-preview__row {
  color: #9eb7d8;
  font-size: 0.7rem;
}

.cash-price-preview__row strong {
  color: #86f0be;
  font-size: 0.78rem;
}

.cash-price-preview__meta {
  display: none;
}

.cash-price-preview--active {
  border-color: rgba(63, 146, 112, 0.5);
  box-shadow: 0 0 0 1px rgba(63, 146, 112, 0.15);
}

.cash-price-preview--active .cash-price-preview__head strong,
.cash-price-preview--active .cash-price-preview__row strong {
  color: #b9f0d5;
}

.cash-price-preview--disabled {
  opacity: 0.72;
  border-color: rgba(84, 109, 144, 0.18);
}

.cash-price-preview--disabled .cash-price-preview__row strong {
  color: #cbd8ea;
}

.cash-discount-switch {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.cash-discount-switch--inline {
  justify-content: flex-start;
  gap: 0.45rem;
}

.cash-discount-switch .form-check-input {
  margin-top: 0;
  transform: scale(0.92);
}

.cash-discount-switch .form-check-label {
  color: #a8bfdc;
  font-size: 0.76rem;
  font-weight: 600;
}

.cash-summary-card {
  padding: 0.85rem 0.95rem;
  border: 1px solid rgba(84, 109, 144, 0.22);
  border-radius: 16px;
  background: rgba(13, 22, 39, 0.58);
}

.cash-summary-card__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  color: #a8bfdc;
  font-size: 0.92rem;
}

.cash-summary-card__row + .cash-summary-card__row {
  margin-top: 0.55rem;
  padding-top: 0.55rem;
  border-top: 1px solid rgba(76, 108, 153, 0.18);
}

.cash-summary-card__row strong {
  color: #ffffff;
  font-size: 1rem;
}

.cash-panel-compact .card-body {
  padding-top: 0.5rem !important;
  padding-bottom: 0.5rem !important;
}

.cash-panel-compact .btn-sm {
  padding: 0.35rem 0.7rem;
}

.cash-card-footer {
  background: rgba(22, 35, 59, 0.78) !important;
  border-top: 1px solid rgba(84, 109, 144, 0.22) !important;
}

.cash-stock-hint--ok {
  color: #8fdab8;
}

.cash-movement-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.cash-movement-filter.active {
  background: rgba(53, 97, 154, 0.24);
  border-color: rgba(123, 163, 218, 0.42);
  color: #ffffff;
}

.cash-counter-shell {
  display: grid;
  gap: 0.55rem;
}

.cash-closed-card {
  background: linear-gradient(180deg, rgba(15, 29, 47, 0.94) 0%, rgba(12, 24, 40, 0.94) 100%);
  border: 1px solid rgba(101, 143, 193, 0.22) !important;
}

.cash-closed-card .card-body {
  padding: 1.1rem 1.25rem;
}

.cash-closed-card__content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.cash-closed-card__summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.cash-closed-card__button {
  min-width: 210px;
}

.cash-closed-card__button--full {
  width: 100%;
  min-height: 52px;
  border-radius: 14px;
  font-size: 1rem;
}

.cash-counter-shell--counter {
  gap: 0.4rem;
}

.cash-session-strip {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
  min-height: 0;
  padding: 0.35rem 0.45rem;
  border: 1px solid rgba(74, 98, 133, 0.18);
  border-radius: 14px;
  background: rgba(8, 16, 29, 0.72);
}

.cash-session-meta {
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  min-width: 0;
}

.cash-session-meta__text {
  color: rgba(154, 177, 209, 0.86);
  font-size: 0.72rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cash-privacy-toggle {
  min-height: 34px !important;
  padding: 0.35rem 0.65rem;
  border-radius: 12px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  white-space: nowrap;
}

.cash-privacy-toggle i {
  font-size: 1rem;
}

.cash-counter-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.45rem 0.7rem;
  border-radius: 12px;
  background: #050b15;
  border: 1px solid rgba(76, 108, 153, 0.24);
  color: #f7fbff;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  white-space: nowrap;
}

.cash-top-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.cash-top-actions__btn {
  min-height: 34px !important;
  padding: 0.32rem 0.68rem;
  font-size: 0.82rem;
  font-weight: 700;
}

.cash-top-actions__btn--open-cta {
  min-width: 180px;
  min-height: 42px !important;
  padding: 0.55rem 1.15rem;
  font-size: 0.94rem;
  border-radius: 14px;
}

.cash-top-actions__btn--close-cta {
  min-width: 180px;
  min-height: 42px !important;
  padding: 0.55rem 1.15rem;
  font-size: 0.94rem;
  border-radius: 14px;
}

.cash-top-actions__locked {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 34px;
}

.cash-launch-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.cash-launch-kicker {
  display: inline-block;
  margin-bottom: 0.18rem;
  color: #9ab1d1;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.cash-side-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 0.75rem;
}


.cash-top-actions__btn--status {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  border: 1px solid rgba(168, 83, 94, 0.62);
  background: rgba(71, 28, 35, 0.24);
  color: #f4f7fd;
}

.cash-top-actions__btn--status:hover,
.cash-top-actions__btn--status:focus {
  border-color: rgba(204, 102, 115, 0.8);
  background: rgba(93, 35, 46, 0.34);
  color: #ffffff;
}

.cash-top-actions__state {
  font-weight: 700;
}

.cash-top-actions__state--open {
  color: #9ef0c4;
}

.cash-top-actions__btn--status-closed {
  border-color: rgba(84, 109, 144, 0.32);
  background: rgba(15, 28, 47, 0.76);
}

.cash-top-actions__btn--status-opening {
  border-color: rgba(77, 168, 118, 0.55);
  background: linear-gradient(180deg, rgba(30, 112, 71, 0.95), rgba(22, 86, 55, 0.95));
  color: #ffffff;
  box-shadow: 0 10px 24px rgba(13, 49, 31, 0.2);
}

.cash-top-actions__btn--status-opening .cash-top-actions__state--closed {
  color: #d9ffe8;
}

.cash-top-actions__btn--status-closed:hover,
.cash-top-actions__btn--status-closed:focus {
  border-color: rgba(123, 163, 218, 0.42);
  background: rgba(19, 35, 58, 0.92);
}

.cash-top-actions__btn--status-opening:hover,
.cash-top-actions__btn--status-opening:focus {
  border-color: rgba(111, 211, 157, 0.68);
  background: linear-gradient(180deg, rgba(37, 131, 83, 0.98), rgba(25, 95, 61, 0.98));
  color: #ffffff;
}

.cash-top-actions__state--closed {
  color: #d4e1f2;
}

.cash-top-actions__divider {
  width: 1px;
  height: 14px;
  background: rgba(212, 226, 247, 0.22);
}

.cash-counter-tools .badge {
  padding-inline: 0.7rem;
  padding-block: 0.45rem;
}

.cash-counter-shell .form-control,
.cash-counter-shell .form-select {
  min-height: 42px;
  font-size: 0.96rem;
}

.cash-counter-shell .btn {
  min-height: 42px;
}

.cash-launch-grid .form-label {
  margin-bottom: 0.3rem;
}

.cash-launch-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(150px, 0.72fr) minmax(150px, 0.72fr) minmax(220px, 0.9fr);
  gap: 0.7rem;
  align-items: end;
}

.cash-launch-field {
  min-width: 0;
}

.cash-launch-field--item,
.cash-launch-field--note {
  align-self: start;
}

.cash-launch-field--qty {
  max-width: 78px;
}

.cash-launch-field--action .btn {
  white-space: nowrap;
  font-weight: 700;
}

.cash-payment-quick__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 42px;
  padding: 0.6rem 0.75rem;
  border-radius: 14px;
  background: rgba(11, 19, 34, 0.72);
  font-size: 0.92rem;
  line-height: 1;
  letter-spacing: 0.01em;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
  min-width: 0;
  overflow: hidden;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  transition: transform 0.08s ease, box-shadow 0.18s ease;
}

.cash-payment-quick__btn i {
  font-size: 1rem;
  flex: 0 0 auto;
  line-height: 1;
  opacity: 0.92;
}

.cash-payment-quick__btn[data-cash-payment-quick="Dinheiro"] {
  font-size: 0.76rem;
  gap: 0.4rem;
  padding: 0.55rem 0.55rem;
  letter-spacing: 0;
}

.cash-payment-quick__btn[data-cash-payment-quick="Dinheiro"] i {
  font-size: 0.86rem;
}

.cash-payment-quick__btn span {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  transform: translateY(0.5px);
}

.cash-payment-quick__btn:active {
  transform: translateY(1px);
}

.cash-payment-quick__btn.is-active,
.cash-payment-quick__btn.active {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 14px 28px rgba(0, 0, 0, 0.18);
}

#cashAddItemButton {
  background: linear-gradient(180deg, rgba(40, 103, 176, 0.96), rgba(29, 74, 130, 0.96));
  border-color: rgba(101, 164, 235, 0.38);
  color: #f7fbff;
  box-shadow: inset 0 1px 0 rgba(190, 224, 255, 0.08);
}

#cashAddItemButton:hover,
#cashAddItemButton:focus {
  background: linear-gradient(180deg, rgba(48, 117, 198, 0.98), rgba(35, 85, 147, 0.98));
  border-color: rgba(125, 183, 248, 0.52);
  color: #ffffff;
}

@media (min-width: 992px) {
  .cash-launch-field--item {
    grid-column: 1 / span 2;
    grid-row: 1;
  }

  .cash-launch-field--amount {
    grid-column: 3;
    grid-row: 1;
  }

  .cash-launch-field--type {
    grid-column: 4;
    grid-row: 1;
  }

  .cash-launch-field--payment {
    grid-column: 1;
    grid-row: 2;
  }

  .cash-launch-field--qty {
    grid-column: 2;
    grid-row: 2;
  }

  .cash-launch-field--category {
    grid-column: 3;
    grid-row: 2;
  }

  .cash-launch-field--note {
    grid-column: 4;
    grid-row: 2;
  }

  .cash-launch-field--action {
    grid-column: 4;
    grid-row: 3;
  }
}

.cash-side-stack {
  display: grid;
  gap: 0.5rem;
  position: sticky;
  top: calc(var(--app-nav-height) + 4px);
}

.cash-side-stack--counter {
  padding: 0.75rem;
  border-radius: 18px;
  border: 1px solid rgba(86, 116, 156, 0.22);
  background: linear-gradient(180deg, rgba(9, 18, 31, 0.98), rgba(7, 14, 24, 0.98));
}

.cash-total-display {
  padding: 0.75rem 0.9rem;
  border: 1px solid rgba(122, 165, 216, 0.28);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(8, 19, 34, 1), rgba(5, 11, 21, 1));
  box-shadow: inset 0 1px 0 rgba(164, 204, 248, 0.08);
}

.cash-total-display__label {
  display: block;
  color: #c3d8f7;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.cash-total-display__value {
  display: block;
  margin-top: 0.12rem;
  color: #f8fbff;
  font-size: clamp(2.15rem, 3.2vw, 3.05rem);
  line-height: 0.95;
  font-weight: 800;
  letter-spacing: -0.04em;
}

.cash-customer-readout {
  padding: 0.55rem 0.75rem;
  border: 1px solid rgba(84, 109, 144, 0.22);
  border-radius: 16px;
  background: rgba(13, 22, 39, 0.54);
}

.cash-customer-readout__row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.6rem;
}

.cash-customer-readout__row + .cash-customer-readout__row {
  margin-top: 0.35rem;
}

.cash-customer-readout__label {
  color: #9fb2cc;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.cash-customer-readout__value {
  color: #ffffff;
  font-size: 0.92rem;
  font-weight: 800;
  text-align: right;
}

.cash-customer-readout__value--item {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 700;
  font-size: 0.86rem;
}

#cashSubmitButton {
  background: linear-gradient(180deg, rgba(28, 142, 97, 0.98), rgba(19, 99, 68, 0.98));
  border-color: rgba(101, 221, 174, 0.34);
  color: #f7fffb;
  box-shadow: inset 0 1px 0 rgba(214, 255, 236, 0.08);
}

#cashSubmitButton:hover,
#cashSubmitButton:focus {
  background: linear-gradient(180deg, rgba(35, 170, 116, 1), rgba(22, 118, 81, 1));
  border-color: rgba(126, 236, 194, 0.48);
  color: #ffffff;
}

#cashAmountInput {
  text-align: right;
  font-size: 1.08rem;
  font-weight: 800;
}

#cashQuantityWrap .form-control {
  text-align: center;
  font-weight: 700;
}

.modal-content {
  background: linear-gradient(180deg, var(--color-surface) 0%, #0f192d 100%);
  border: 1px solid rgba(94, 122, 159, 0.28);
  color: var(--color-text);
}

.modal-header,
.modal-footer {
  border-color: rgba(84, 109, 144, 0.22);
}

.cash-summary-mini-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.4rem;
}

.cash-mini-metric {
  padding: 0.5rem 0.6rem;
  border: 1px solid rgba(84, 109, 144, 0.2);
  border-radius: 12px;
  background: rgba(13, 22, 39, 0.54);
}

.cash-mini-metric span {
  display: block;
  color: #9fb2cc;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.cash-mini-metric strong {
  display: block;
  margin-top: 0.08rem;
  color: #ffffff;
  font-size: 0.92rem;
}

.cash-mini-metric--wide {
  grid-column: span 2;
}

.cash-mobile-dock {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1040;
  padding: 0.75rem 0.9rem;
  padding-bottom: calc(0.75rem + env(safe-area-inset-bottom));
  border-top: 1px solid rgba(84, 109, 144, 0.22);
  background: rgba(7, 14, 24, 0.88);
  backdrop-filter: blur(14px);
}

.cash-mobile-dock__inner {
  max-width: 560px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.cash-mobile-dock__summary span {
  display: block;
  color: #9fb2cc;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.cash-mobile-dock__summary strong {
  display: block;
  margin-top: 0.12rem;
  color: #ffffff;
  font-size: 1.35rem;
  font-weight: 900;
  line-height: 1;
}

.cash-mobile-dock__summary small {
  color: rgba(212, 226, 247, 0.72);
  font-size: 0.85rem;
  font-weight: 700;
}

.cash-mobile-dock__cta {
  min-height: 50px !important;
  padding: 0.68rem 1.15rem;
  border-radius: 16px;
  font-weight: 900;
  white-space: nowrap;
}

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

  .cash-launch-field--qty {
    max-width: none;
  }
}

@media (max-width: 992px) {
  .cash-launch-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cash-side-stack {
    position: static;
  }

  .cash-counter-shell--counter {
    padding-bottom: 92px;
  }

  #cashSubmitButton {
    display: none;
  }
}

@media (max-width: 640px) {
  .cash-launch-grid {
    grid-template-columns: 1fr;
  }

  .cash-counter-shell .form-control,
  .cash-counter-shell .form-select {
    min-height: 48px;
    font-size: 1.02rem;
  }

  .cash-counter-shell .btn {
    min-height: 48px;
  }

  .cash-summary-mini-grid {
    grid-template-columns: 1fr;
  }

  .cash-mini-metric--wide {
    grid-column: auto;
  }

  .cash-price-preview-grid {
    display: none;
  }
}

.form-grid-compact {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}

.form-grid-compact--service {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.form-grid-compact > * {
  min-width: 0;
}

.form-grid-compact .col-span-2 {
  grid-column: span 2;
}

.quote-toolbar {
  display: grid;
  grid-template-columns: minmax(280px, 1.6fr) minmax(180px, 0.8fr) auto auto auto;
  gap: 0.75rem;
  align-items: center;
}

.quote-form-core {
  display: grid;
  grid-template-columns: minmax(260px, 1.2fr) minmax(260px, 1.2fr) minmax(170px, 0.7fr);
  gap: 1rem;
  align-items: end;
}

.quote-package-box .card-body {
  padding-block: 0.9rem;
}

.package-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.package-btn--compact {
  min-height: auto;
  padding: 0.65rem 0.9rem;
  white-space: nowrap;
}

.quote-item-actions .btn {
  min-width: 92px;
}

.quote-totals-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.9rem;
}

.workorder-toolbar {
  display: grid;
  grid-template-columns: minmax(280px, 1.6fr) minmax(180px, 0.8fr) auto auto auto;
  gap: 0.75rem;
  align-items: center;
}

.workorder-payment-preview {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem 1rem;
  padding: 0.9rem 1rem;
  border: 1px solid rgba(76, 108, 153, 0.26);
  border-radius: 16px;
  background: rgba(10, 20, 35, 0.62);
}

.workorder-payment-preview__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  color: #a8bfdc;
  font-size: 0.9rem;
}

.workorder-payment-preview__row strong {
  color: #ffffff;
  font-size: 0.96rem;
}

.quote-receive-preview {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.4rem 0.85rem;
  min-width: 260px;
  padding: 0.7rem 0.85rem;
  border: 1px solid rgba(76, 108, 153, 0.26);
  border-radius: 14px;
  background: rgba(10, 20, 35, 0.62);
}

.quote-receive-preview__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  color: #a8bfdc;
  font-size: 0.8rem;
}

.quote-receive-preview__row strong {
  color: #ffffff;
  font-size: 0.88rem;
}

.workorder-payment-preview--pix {
  border-color: rgba(35, 181, 122, 0.38);
}

.workorder-payment-preview--pix .workorder-payment-preview__row:nth-child(2) strong {
  color: #86f0be;
}

.workorder-payment-preview--money {
  border-color: rgba(244, 188, 74, 0.34);
}

.workorder-payment-preview--money .workorder-payment-preview__row:nth-child(2) strong {
  color: #ffd47e;
}

.workorder-payment-preview--pix .quote-receive-preview__row:nth-child(2) strong {
  color: #86f0be;
}

.workorder-payment-preview--money .quote-receive-preview__row:nth-child(2) strong {
  color: #ffd47e;
}

.billing-toolbar {
  display: grid;
  grid-template-columns: minmax(160px, 0.8fr) minmax(130px, 0.6fr) minmax(180px, 0.9fr) auto auto;
  gap: 0.75rem;
  align-items: end;
}

.billing-page {
  background: #0b1727;
  border: 1px solid rgba(76, 108, 153, 0.36);
  border-radius: 16px;
  padding: 1rem;
  color: #dce8fd;
}

.billing-header p {
  color: #8ea6cc;
}

.billing-private-badge {
  background: #122643;
  border: 1px solid #284b7a;
  color: #c6dcff;
  font-weight: 600;
}

.billing-panel {
  background: #0b1727;
  border: 1px solid rgba(76, 108, 153, 0.35) !important;
  color: #dce8fd;
}

.billing-panel .form-label {
  color: #9fb8df;
  font-weight: 600;
}

.billing-panel .form-select,
.billing-panel .form-control {
  background: #081220;
  border-color: #2a456b;
  color: #f1f6ff;
}

.billing-panel .form-select:focus,
.billing-panel .form-control:focus {
  border-color: #4fb6ff;
  box-shadow: 0 0 0 0.18rem rgba(79, 182, 255, 0.22);
  background: #081220;
  color: #f1f6ff;
}

.billing-panel .btn-outline-primary {
  border-color: #3f91ff;
  color: #8ab9ff;
}

.billing-panel .btn-outline-primary:hover {
  background: #1f4f8c;
  border-color: #4c9fff;
  color: #ffffff;
}

.billing-panel .btn-outline-secondary {
  border-color: #3f516b;
  color: #a7b5cc;
}

.billing-panel .btn-outline-secondary:hover {
  background: #2a3c56;
  border-color: #4e6381;
  color: #ffffff;
}

.billing-stat-card {
  box-shadow: 0 10px 22px rgba(2, 10, 23, 0.25) !important;
}

.billing-stat-title {
  color: #89a6ce !important;
  font-weight: 600;
}

.billing-stat-card .summary-panel-label,
.billing-stat-card .summary-panel-value {
  display: block;
}

.billing-stat-card .summary-panel-value {
  font-size: 1.4rem;
}

.billing-stat-card--primary {
  border-top: 2px solid rgba(63, 145, 255, 0.8) !important;
}

.billing-stat-card--success {
  border-top: 2px solid rgba(35, 181, 122, 0.9) !important;
}

.billing-stat-card--danger {
  border-top: 2px solid rgba(237, 91, 108, 0.88) !important;
}

.billing-table-card h2 {
  color: #dce8fd;
}

.billing-search-wrap {
  position: relative;
  min-width: 290px;
}

.billing-search-wrap i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #6d8fbf;
  pointer-events: none;
}

.billing-search-wrap .form-control {
  padding-left: 34px;
}

.billing-table-card .table {
  margin-bottom: 0;
  color: #d9e7ff;
  --bs-table-bg: #0b1727;
  --bs-table-color: #d9e7ff;
  --bs-table-border-color: rgba(81, 110, 151, 0.35);
  --bs-table-hover-bg: rgba(47, 82, 130, 0.3);
  --bs-table-hover-color: #f4f8ff;
}

.billing-table-card .table thead th {
  background: #0b1727;
  color: #9fc2f6;
  border-bottom: 1px solid rgba(102, 135, 181, 0.45);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 0.78rem;
  font-weight: 700;
}

.billing-table-card .table tbody td {
  border-color: rgba(81, 110, 151, 0.35);
  color: #e5efff;
  background: transparent;
}

.billing-table-card .table tbody tr {
  background: #0b1727;
}

.billing-table-card .table tbody tr:nth-child(even) {
  background: #0b1727;
}

.billing-table-card .table tbody tr:hover {
  background: rgba(47, 82, 130, 0.3);
}

.billing-table-card .badge {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.billing-table-card .table .text-muted {
  color: #9db3d3 !important;
}

.billing-table-card .btn-outline-primary {
  border-color: rgba(91, 143, 222, 0.7);
  color: #b9d8ff;
}

.billing-table-card .btn-outline-primary:hover {
  background: rgba(73, 122, 203, 0.34);
  border-color: #7fb3ff;
}

.billing-chart-card .card-body {
  padding: 1rem;
}

.billing-chart-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.9rem;
  margin-bottom: 0.85rem;
}

.billing-legend {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
  font-size: 0.86rem;
  color: #9fc2f6;
}

.billing-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.billing-legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  display: inline-block;
  box-shadow: 0 0 0 3px rgba(13, 22, 39, 0.65);
}

.billing-legend-dot--forecast {
  background: rgba(63, 145, 255, 0.95);
}

.billing-legend-dot--received {
  background: rgba(35, 181, 122, 0.95);
}

.billing-chart-canvas {
  position: relative;
  height: 320px;
  border-radius: 14px;
  background: rgba(8, 18, 32, 0.38);
  border: 1px solid rgba(42, 69, 107, 0.5);
  padding: 0.6rem;
}

.billing-chart-canvas--donut {
  height: 250px;
}

.billing-chart-canvas--bar {
  height: 310px;
}

.billing-mini-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin-top: 0.85rem;
}

.billing-mini-tile {
  background: rgba(8, 18, 32, 0.6);
  border: 1px solid rgba(42, 69, 107, 0.55);
  border-radius: 14px;
  padding: 0.65rem 0.75rem;
}

.billing-mini-tile span {
  display: block;
  font-size: 0.82rem;
  font-weight: 700;
  color: #9fb8df;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin-bottom: 0.25rem;
}

.billing-mini-tile strong {
  display: block;
  font-size: 1rem;
  color: #eef6ff;
}

.subscription-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.8rem;
}

.subscription-tile {
  background: rgba(8, 18, 32, 0.6);
  border: 1px solid rgba(42, 69, 107, 0.55);
  border-radius: 14px;
  padding: 0.85rem 0.9rem;
}

.subscription-tile span {
  display: block;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #9fb8df;
  margin-bottom: 0.3rem;
}

.subscription-tile strong {
  display: block;
  font-size: 1.05rem;
  color: #eef6ff;
}

.kanban-board {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(290px, 1fr);
  gap: 0.9rem;
  overflow-x: auto;
  padding-bottom: 0.4rem;
  scroll-snap-type: x mandatory;
}

.kanban-col {
  background: #0b1727;
  border: 1px solid rgba(76, 108, 153, 0.36);
  border-radius: 16px;
  min-height: 260px;
  scroll-snap-align: start;
}

.kanban-col__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 0.85rem;
  border-bottom: 1px solid rgba(76, 108, 153, 0.3);
}

.kanban-col__title {
  font-weight: 800;
  color: #dce8fd;
}

.kanban-col__body {
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.kanban-empty {
  padding: 0.35rem 0.2rem;
}

.kanban-card {
  background: rgba(8, 18, 32, 0.72);
  border: 1px solid rgba(42, 69, 107, 0.58);
  border-radius: 16px;
  padding: 0.75rem 0.8rem;
  box-shadow: 0 14px 30px rgba(2, 10, 23, 0.32);
}

.kanban-card--overdue {
  border-color: rgba(244, 188, 74, 0.65);
  box-shadow: 0 18px 36px rgba(244, 188, 74, 0.1);
}

.kanban-card__top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.35rem;
}

.kanban-card__id {
  font-weight: 900;
  text-decoration: none;
  color: #e9f2ff;
}

.kanban-card__id:hover {
  color: #8ec9ff;
}

.kanban-card__meta {
  margin-bottom: 0.55rem;
}

.kanban-card__client {
  font-weight: 700;
  color: #dce8fd;
}

.kanban-card__sub {
  color: #9db3d3 !important;
}

.kanban-card__row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.3rem;
}

.kanban-card__actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.kanban-card__actions .form-select {
  background: rgba(11, 23, 39, 0.9);
  border-color: rgba(63, 89, 130, 0.8);
  color: #eef6ff;
}

.table > :not(caption) > * > * {
  padding: 0.7rem 0.7rem;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-body);
  font-weight: 700;
}

.quote-sheet {
  background: linear-gradient(180deg, #f7f8fc 0%, #eef2f8 100%);
  max-width: 210mm;
  margin: 0 auto;
  border: 1px solid #d8e2ee !important;
  font-family: var(--font-doc);
  color: #1a2e4a;
  line-height: 1.42;
  font-size: 0.98rem;
  border-radius: 18px;
  overflow: hidden;
}

.invoice-sheet {
  /* Save ink and keep the invoice export clean/neutral. */
  background: #ffffff !important;
}

.quote-sheet h2,
.quote-sheet h3 {
  font-family: var(--font-doc);
  color: #102846;
  letter-spacing: 0.01em;
}

.quote-sheet h1,
.quote-sheet h4,
.quote-sheet h5,
.quote-sheet h6 {
  color: #102846;
}

.quote-sheet .table {
  font-size: 0.94rem;
  --bs-table-bg: #ffffff;
  --bs-table-color: #1a2e4a;
  --bs-table-border-color: #d0d9e6;
  --bs-table-hover-bg: #f3f6fb;
  --bs-table-hover-color: #1a2e4a;
}

.quote-sheet .table th {
  color: #314766;
  font-weight: 700;
  text-transform: none;
  letter-spacing: normal;
  font-size: 0.92rem;
}

.quote-sheet .text-muted {
  color: #6b7890 !important;
}

.quote-sheet .table-light,
.quote-sheet .table-light > th,
.quote-sheet .table-light > td {
  background: #eef3fa !important;
  color: #1a2e4a !important;
}

.quote-sheet .table-dark th,
.quote-sheet .table-dark td {
  font-weight: 800;
  letter-spacing: 0.01em;
}

.quote-header-logo {
  grid-area: logo;
  width: 112px;
  height: 112px;
  object-fit: cover;
  border-radius: 50%;
  border: 1px solid #d7e1ee;
  background: #ffffff;
  box-shadow: 0 8px 18px rgba(16, 40, 70, 0.08);
  flex: 0 0 112px;
}

.quote-topbar {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(260px, 0.95fr);
  gap: 1.25rem;
  align-items: start;
  margin-bottom: 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid #dce4ef;
}

.quote-identity-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.quote-identity-pill {
  min-width: 150px;
  padding: 0.72rem 0.9rem;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid #d8e2ee;
  box-shadow: 0 10px 18px rgba(16, 40, 70, 0.06);
}

.quote-identity-pill__label {
  display: block;
  margin-bottom: 0.24rem;
  color: #607694;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.quote-identity-pill strong {
  color: #132f4e;
  font-size: 0.96rem;
  font-weight: 800;
}

.quote-commercial-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.9rem;
  margin-bottom: 1.15rem;
}

.quote-commercial-card {
  padding: 0.95rem 1rem;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(247, 250, 255, 0.88));
  border: 1px solid #d7e2ee;
  box-shadow: 0 10px 18px rgba(16, 40, 70, 0.05);
}

.quote-commercial-card--accent {
  background: linear-gradient(180deg, #122c4a 0%, #0d2036 100%);
  border-color: #18385c;
}

.quote-commercial-card__label {
  display: block;
  margin-bottom: 0.35rem;
  color: #617895;
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.quote-commercial-card strong {
  display: block;
  color: #14304f;
  font-size: 0.98rem;
  line-height: 1.35;
  font-weight: 800;
}

.quote-commercial-card small {
  display: block;
  margin-top: 0.28rem;
  color: #647a96;
  font-size: 0.82rem;
}

.quote-commercial-card--accent .quote-commercial-card__label {
  color: rgba(198, 221, 251, 0.82);
}

.quote-commercial-card--accent strong,
.quote-commercial-card--accent small {
  color: #f5f9ff;
}

.quote-sheet--compact-print .quote-commercial-strip {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.quote-sheet--compact-print .quote-panel--service-meta .quote-summary-stack {
  gap: 0.75rem;
}

.quote-brand-block {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  grid-template-areas:
    "kicker copy"
    "logo copy";
  gap: 0.95rem;
  align-items: start;
}

.quote-brand-copy {
  grid-area: copy;
  min-width: 0;
}

.quote-kicker {
  display: inline-flex;
  align-items: center;
  padding: 0.28rem 0.72rem;
  border-radius: 999px;
  background: #dbeafe;
  color: #0f3c67;
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.75rem;
}

.quote-kicker--corner {
  grid-area: kicker;
  margin-bottom: 0.05rem;
  align-self: end;
  justify-self: start;
}

.quote-company-title {
  font-size: 1.65rem;
  font-weight: 800;
}

.quote-company-meta {
  color: #59708e;
  font-size: 0.9rem;
  line-height: 1.45;
}

.quote-meta-card {
  background: #ffffff;
  color: #14304f;
  border: 1px solid #d7e1ee;
  border-radius: 16px;
  padding: 0.8rem 0.9rem;
  box-shadow: 0 8px 18px rgba(16, 40, 70, 0.05);
}

.quote-meta-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.38rem 0;
  border-bottom: 1px solid #e2e8f0;
  font-size: 0.9rem;
}

.quote-meta-row:last-child {
  border-bottom: none;
}

.quote-meta-row span {
  color: #607694;
}

.quote-meta-row strong {
  color: #14304f;
}

.quote-meta-row--accent {
  margin-top: 0.35rem;
  padding: 0.7rem 0.8rem;
  border: 1px solid #dbe4ef;
  border-radius: 12px;
  background: #f4f7fb;
}

.quote-meta-row--accent strong {
  font-size: 1.08rem;
}

.quote-client-grid,
.quote-summary-grid,
.quote-details-grid {
  display: grid;
  gap: 1rem;
  align-items: start;
}

.quote-client-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 1rem;
}

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

.quote-summary-grid--single {
  grid-template-columns: minmax(0, 1fr);
}

.quote-summary-grid--single .quote-total-card {
  width: 100%;
  max-width: 420px;
  justify-self: end;
}

.quote-panel {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid #d7e1ee;
  border-radius: 16px;
  padding: 1rem 1.1rem;
}

.quote-panel--soft {
  background: #f7f9fd;
}

.quote-panel-title,
.quote-summary-label {
  display: block;
  margin-bottom: 0.38rem;
  color: #4b6484;
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.quote-field-value {
  color: #112d4d;
  font-size: 1.06rem;
  font-weight: 700;
}

.quote-field-subtle,
.quote-copy-text {
  color: #5b6f89;
}

.quote-copy-text {
  line-height: 1.65;
}

.quote-table-wrap {
  border: 1px solid #d7e1ee;
  border-radius: 16px;
  overflow: hidden;
  background: #ffffff;
}

.quote-table-subtotal {
  font-weight: 700;
  color: #102846;
}

.quote-total-card {
  background: #ffffff;
  color: #14304f;
  border: 1px solid #d7e1ee;
  border-radius: 18px;
  padding: 0.95rem 1rem;
  box-shadow: 0 10px 20px rgba(16, 40, 70, 0.05);
  position: relative;
  overflow: hidden;
}

.quote-total-card::after {
  display: none;
}

.quote-total-card__title {
  margin-bottom: 0.75rem;
  color: #4b6484;
  font-size: 0.86rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.quote-total-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid #e4ebf3;
  color: #4c6482;
}

.quote-total-row:last-of-type {
  border-bottom: none;
}

.quote-total-row--pix {
  color: #1e7a50;
}

.quote-total-row--money {
  color: #8e6214;
}

.quote-total-note {
  display: inline-block;
  margin-left: 0.35rem;
  color: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.quote-grand-total {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 0.8rem;
  padding: 0.85rem 0.95rem;
  border-radius: 14px;
  background: #eef4fb;
  color: #102846;
  border: 1px solid #d8e3ef;
}

.quote-grand-total span {
  font-weight: 700;
  font-size: 0.92rem;
}

.quote-grand-total strong {
  font-size: 1.12rem;
  font-weight: 800;
}

.quote-payment-balance {
  margin-top: 0.85rem;
  padding-top: 0.85rem;
  border-top: 1px dashed rgba(255, 255, 255, 0.15);
  display: grid;
  gap: 0.45rem;
}

.quote-payment-balance__row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  color: #5c728e;
  font-size: 0.9rem;
}

.quote-payment-balance__row strong {
  color: #14304f;
  font-weight: 800;
}

.quote-total-footer {
  margin-top: 0.9rem;
  padding-top: 0.85rem;
  border-top: 1px dashed #d4ddeb;
  color: #6a809b;
  font-size: 0.84rem;
  line-height: 1.55;
}

.quote-summary-stack {
  display: grid;
  gap: 0.95rem;
}

.quote-signoff {
  margin-top: 1.75rem;
  padding-top: 1.5rem;
}

.quote-signoff__line {
  border-bottom: 1px solid #9db0c7;
  width: 360px;
  max-width: 100%;
  margin-bottom: 0.45rem;
}

.quote-signoff__label,
.quote-footer-note {
  color: #69809d;
  font-size: 0.9rem;
}

.quote-approval-panel {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1.15rem;
  padding: 0.95rem 1rem;
  border-radius: 14px;
  background: #f1f5fb;
  border: 1px solid #d6dfeb;
  color: #314766;
}

.quote-approval-panel__label {
  display: block;
  margin-bottom: 0.3rem;
  color: #4f6684;
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.quote-approval-panel strong {
  display: block;
  color: #12314f;
  font-size: 0.95rem;
  line-height: 1.45;
}

.quote-approval-panel__meta {
  min-width: 210px;
  color: #637995;
  font-size: 0.86rem;
  text-align: right;
}

.quote-footer-note {
  margin-top: 1.4rem;
  padding-top: 1rem;
  border-top: 1px solid #d5ddea;
  line-height: 1.65;
}

.quote-meta-row--pix strong {
  color: #b8ffd8;
}

.quote-meta-row--money strong {
  color: #ffe4aa;
}

.quote-inline-badge {
  display: inline-flex;
  align-items: center;
  margin-left: 0.45rem;
  padding: 0.16rem 0.46rem;
  border-radius: 999px;
  background: rgba(77, 201, 132, 0.18);
  color: #b8ffd8;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.quote-inline-badge--money {
  background: rgba(244, 188, 74, 0.18);
  color: #ffd47e;
}

.quote-payment-highlight {
  margin-top: 0.85rem;
  padding: 0.8rem 0.9rem;
  border-radius: 14px;
  border: 1px solid #dce5ef;
  background: #f6f9fd;
}

.quote-payment-highlight__label {
  margin-bottom: 0.2rem;
  color: #607694;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.quote-payment-highlight__value {
  color: #14304f;
  font-size: 0.95rem;
  font-weight: 700;
}

.quote-payment-highlight--pix {
  border-color: rgba(63, 146, 112, 0.24);
  background: #f1fbf6;
}

.quote-payment-highlight--money {
  border-color: rgba(244, 188, 74, 0.24);
  background: #fff9ef;
}

/* Document previews use a monochrome palette for cleaner on-screen reading
   and low-ink printing. */
.quote-sheet {
  background: #ffffff;
  border: 1px solid #cfcfcf !important;
  color: #111111;
  box-shadow: none;
}

.quote-sheet h1,
.quote-sheet h2,
.quote-sheet h3,
.quote-sheet h4,
.quote-sheet h5,
.quote-sheet h6,
.quote-sheet .table-dark th,
.quote-sheet .table-dark td,
.quote-company-title,
.quote-field-value,
.quote-table-subtotal,
.quote-grand-total strong,
.quote-meta-row strong,
.quote-payment-balance__row strong,
.quote-payment-highlight__value,
.quote-approval-panel strong {
  color: #111111;
}

.quote-sheet .table {
  --bs-table-bg: #ffffff;
  --bs-table-color: #111111;
  --bs-table-border-color: #d2d2d2;
  --bs-table-hover-bg: #f5f5f5;
  --bs-table-hover-color: #111111;
}

.quote-sheet .table th {
  color: #333333;
}

.quote-sheet .text-muted,
.quote-company-meta,
.quote-field-subtle,
.quote-copy-text,
.quote-total-row,
.quote-total-footer,
.quote-footer-note,
.quote-signoff__label,
.quote-payment-balance__row,
.quote-panel-title,
.quote-summary-label,
.quote-total-card__title,
.quote-approval-panel__label,
.quote-approval-panel__meta,
.quote-payment-highlight__label,
.quote-meta-row span,
.quote-total-note {
  color: #555555 !important;
}

.quote-sheet .table-light,
.quote-sheet .table-light > th,
.quote-sheet .table-light > td,
.quote-panel--soft,
.quote-meta-row--accent,
.quote-grand-total,
.quote-payment-highlight,
.quote-approval-panel {
  background: #f4f4f4 !important;
  color: #111111 !important;
}

.quote-header-logo {
  border: 1px solid #cfcfcf;
  background: #ffffff;
  box-shadow: none;
  filter: grayscale(100%);
}

.quote-topbar,
.quote-total-row,
.quote-payment-balance,
.quote-total-footer,
.quote-footer-note,
.quote-meta-row {
  border-color: #d4d4d4;
}

.quote-kicker,
.quote-inline-badge,
.quote-inline-badge--money {
  background: #111111;
  color: #ffffff;
}

.quote-identity-pill,
.quote-commercial-card,
.quote-meta-card,
.quote-panel,
.quote-table-wrap,
.quote-total-card {
  background: #ffffff;
  border: 1px solid #d2d2d2;
  box-shadow: none;
}

.quote-commercial-card--accent,
.quote-payment-highlight--pix,
.quote-payment-highlight--money {
  background: #f4f4f4;
  border-color: #d2d2d2;
}

.quote-commercial-card__label,
.quote-commercial-card strong,
.quote-commercial-card small,
.quote-commercial-card--accent .quote-commercial-card__label,
.quote-commercial-card--accent strong,
.quote-commercial-card--accent small,
.quote-meta-row--pix strong,
.quote-meta-row--money strong,
.quote-total-row--pix,
.quote-total-row--money {
  color: #111111;
}

.pix-discount-wrap--active .form-label {
  color: #27b36d;
}

#pixDiscountDisplay.is-active {
  background: #0f2a1d;
  border-color: #2b8f62;
  color: #c8f4dd;
  font-weight: 700;
}

.pix-discount-note {
  color: #27b36d;
  font-weight: 700;
}

@media (max-width: 991px) {
  .billing-search-wrap {
    min-width: 100%;
  }

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

  .kanban-board {
    grid-auto-columns: minmax(260px, 86vw);
  }

  .billing-chart-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .billing-chart-canvas {
    height: 260px;
  }

  .billing-chart-canvas--donut {
    height: 220px;
  }

  .billing-chart-canvas--bar {
    height: 280px;
  }

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

  .top-search-form {
    min-width: 100%;
    margin: 0.6rem 0;
  }

  .top-search-form .form-control {
    min-width: 0;
    width: 100%;
  }

  .brand-logo-nav {
    width: 64px;
    height: 64px;
  }

  .quote-toolbar,
  .workorder-toolbar {
    grid-template-columns: 1fr;
  }

  .quote-form-core,
  .quote-totals-grid {
    grid-template-columns: 1fr;
  }

  .form-grid-compact,
  .form-grid-compact--service {
    grid-template-columns: 1fr;
  }

  .form-grid-compact .col-span-2 {
    grid-column: span 1;
  }

  .simple-toolbar,
  .billing-toolbar {
    grid-template-columns: 1fr;
  }

  .quote-topbar,
  .quote-identity-strip,
  .quote-commercial-strip,
  .quote-client-grid,
  .quote-summary-grid,
  .quote-details-grid {
    grid-template-columns: 1fr;
  }

  .quote-action-bar {
    justify-content: flex-start;
  }

  .quote-brand-block {
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-areas:
      "kicker kicker"
      "logo copy";
    gap: 0.6rem 0.8rem;
  }

  .quote-approval-panel {
    flex-direction: column;
  }

  .quote-approval-panel__meta {
    min-width: 0;
    text-align: left;
  }

  .cash-price-preview {
    width: 100%;
  }

  .cash-price-preview-grid {
    grid-template-columns: 1fr;
  }

  .workorder-payment-preview {
    grid-template-columns: 1fr;
  }

  .quote-receive-preview {
    grid-template-columns: 1fr;
    min-width: 100%;
  }
}

/* Light theme tweaks (navbar + small details). */
/* Keep the light theme mostly neutral; avoid over-saturating the UI. */
html[data-theme="light"] a {
  color: rgba(15, 23, 42, 0.86);
}

html[data-theme="light"] a:hover {
  color: rgba(15, 23, 42, 0.94);
}

html[data-theme="light"] main a:not(.btn) {
  color: rgba(15, 23, 42, 0.82);
  text-decoration-color: rgba(15, 23, 42, 0.25);
  text-underline-offset: 0.18em;
}

html[data-theme="light"] main a:not(.btn):hover {
  color: rgba(15, 23, 42, 0.92);
  text-decoration-color: rgba(15, 23, 42, 0.4);
}

html[data-theme="light"] .table {
  --bs-table-hover-bg: rgba(15, 23, 42, 0.04);
}

html[data-theme="light"] .navbar {
  --bs-navbar-color: rgba(15, 23, 42, 0.78);
  --bs-navbar-hover-color: rgba(15, 23, 42, 0.92);
  --bs-navbar-active-color: rgba(15, 23, 42, 0.95);
  --bs-navbar-brand-color: rgba(15, 23, 42, 0.95);
  --bs-navbar-brand-hover-color: rgba(15, 23, 42, 0.95);
  --bs-navbar-toggler-border-color: rgba(15, 23, 42, 0.16);
  background: rgba(255, 255, 255, 0.92) !important;
  border-bottom-color: var(--color-border) !important;
}

html[data-theme="light"] .navbar .navbar-toggler-icon {
  filter: invert(1);
}

html[data-theme="light"] .navbar-brand-subtitle {
  color: rgba(15, 23, 42, 0.62);
}

html[data-theme="light"] .navbar .nav-link {
  color: rgba(15, 23, 42, 0.92) !important;
  background: rgba(15, 23, 42, 0.035);
  border-color: rgba(15, 23, 42, 0.12);
}

html[data-theme="light"] .navbar .nav-link:hover {
  background: rgba(15, 23, 42, 0.06);
  border-color: rgba(15, 23, 42, 0.18);
  color: rgba(15, 23, 42, 0.95) !important;
}

html[data-theme="light"] .navbar .nav-link.active {
  background: rgba(29, 78, 216, 0.12);
  border-color: rgba(29, 78, 216, 0.24);
  color: rgba(15, 23, 42, 0.98) !important;
  box-shadow: none;
}

html[data-theme="light"] .navbar .admin-link {
  color: rgba(15, 23, 42, 0.92) !important;
  background: rgba(29, 78, 216, 0.06);
  border-color: rgba(29, 78, 216, 0.22);
}

html[data-theme="light"] .navbar .admin-link:hover {
  background: rgba(29, 78, 216, 0.1);
  border-color: rgba(29, 78, 216, 0.3);
  color: rgba(15, 23, 42, 0.98) !important;
}

html[data-theme="light"] .navbar .admin-link.active {
  background: rgba(29, 78, 216, 0.14);
  border-color: rgba(29, 78, 216, 0.34);
  color: rgba(15, 23, 42, 0.98) !important;
}

html[data-theme="light"] .navbar .nav-link--cashier {
  background: rgba(16, 185, 129, 0.1);
  border-color: rgba(16, 185, 129, 0.25);
  color: rgba(15, 23, 42, 0.95) !important;
}

html[data-theme="light"] .navbar .nav-link--cashier:hover,
html[data-theme="light"] .navbar .nav-link--cashier:focus {
  background: rgba(16, 185, 129, 0.14);
  border-color: rgba(16, 185, 129, 0.32);
  color: rgba(15, 23, 42, 0.98) !important;
}

html[data-theme="light"] .navbar .nav-link--cashier.active {
  background: rgba(16, 185, 129, 0.18);
  border-color: rgba(16, 185, 129, 0.38);
  color: rgba(15, 23, 42, 0.98) !important;
  box-shadow: none;
}

html[data-theme="light"] .top-search-form {
  background: rgba(255, 255, 255, 0.88);
  border-color: rgba(15, 23, 42, 0.12);
}

html[data-theme="light"] .top-search-form > i {
  color: rgba(15, 23, 42, 0.48);
}

html[data-theme="light"] .top-search-form__hint {
  border-color: rgba(98, 126, 168, 0.35);
  background: rgba(233, 240, 250, 0.9);
  color: #2a446b;
}

html[data-theme="light"] .navbar-logout-btn,
html[data-theme="light"] .sidebar-toggle-btn,
html[data-theme="light"] .theme-toggle-btn {
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(15, 23, 42, 0.16);
  color: rgba(15, 23, 42, 0.92);
}

html[data-theme="light"] .navbar-logout-btn:hover,
html[data-theme="light"] .navbar-logout-btn:focus,
html[data-theme="light"] .sidebar-toggle-btn:hover,
html[data-theme="light"] .sidebar-toggle-btn:focus,
html[data-theme="light"] .theme-toggle-btn:hover,
html[data-theme="light"] .theme-toggle-btn:focus {
  background: rgba(255, 255, 255, 1);
  border-color: rgba(15, 23, 42, 0.24);
  color: rgba(15, 23, 42, 0.98);
}

html[data-theme="light"] .summary-panel-card,
html[data-theme="light"] .metric-card,
html[data-theme="light"] .result-count-card,
html[data-theme="light"] .workorder-summary-card {
  background: linear-gradient(180deg, #ffffff 0%, #eef2f7 100%);
  border: 1px solid var(--color-border) !important;
  box-shadow: 0 10px 20px rgba(15, 23, 42, 0.08);
}

html[data-theme="light"] .dashboard-onboarding-card {
  background: linear-gradient(180deg, #ffffff 0%, #eef2f7 100%);
  border: 1px solid var(--color-border) !important;
  box-shadow: 0 10px 20px rgba(15, 23, 42, 0.08);
}

html[data-theme="light"] .dashboard-onboarding-progress {
  --bs-progress-bg: rgba(15, 23, 42, 0.08) !important;
  background: rgba(15, 23, 42, 0.08) !important;
}

html[data-theme="light"] .dashboard-onboarding-list {
  --bs-list-group-bg: rgba(255, 255, 255, 0.72) !important;
  --bs-list-group-color: var(--color-text) !important;
  --bs-list-group-border-color: rgba(15, 23, 42, 0.08) !important;
  --bs-list-group-action-hover-bg: rgba(37, 99, 235, 0.06) !important;
  --bs-list-group-action-hover-color: var(--color-text) !important;
  --bs-list-group-action-active-bg: rgba(37, 99, 235, 0.1) !important;
  --bs-list-group-action-active-color: var(--color-text) !important;
}

html[data-theme="light"] .dashboard-onboarding-list .list-group-item {
  background: rgba(255, 255, 255, 0.72) !important;
  border-color: rgba(15, 23, 42, 0.08) !important;
}

html[data-theme="light"] .dashboard-onboarding-list .list-group-item:hover,
html[data-theme="light"] .dashboard-onboarding-list .list-group-item:focus {
  background: rgba(37, 99, 235, 0.06) !important;
}

html[data-theme="light"] .summary-panel-label {
  color: var(--color-text-muted);
}

html[data-theme="light"] .summary-panel-value {
  color: var(--color-text);
}

html[data-theme="light"] .summary-panel-value--success {
  color: #0f5132;
}

html[data-theme="light"] .summary-panel-value--warning {
  color: #664d03;
}

html[data-theme="light"] .summary-panel-value--danger {
  color: #842029;
}

html[data-theme="light"] .dashboard-insight-card {
  background: linear-gradient(180deg, #ffffff 0%, #eef2f7 100%);
  border: 1px solid var(--color-border) !important;
  box-shadow: 0 10px 20px rgba(15, 23, 42, 0.08);
}

html[data-theme="light"] .mini-flow-chart {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(15, 23, 42, 0.14);
}

html[data-theme="light"] .mini-flow-bar {
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.12);
}

html[data-theme="light"] .top-list-item {
  border-bottom-color: rgba(15, 23, 42, 0.12);
}

html[data-theme="light"] .status-pill {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(15, 23, 42, 0.16);
}

html[data-theme="light"] .pending-block {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(15, 23, 42, 0.14);
}

html[data-theme="light"] .pending-item {
  border-bottom-color: rgba(15, 23, 42, 0.12);
}

html[data-theme="light"] .pending-flag--danger {
  background: rgba(220, 53, 69, 0.1);
  border-color: rgba(220, 53, 69, 0.25);
  color: #842029;
}

html[data-theme="light"] .pending-flag--warning {
  background: rgba(255, 193, 7, 0.18);
  border-color: rgba(255, 193, 7, 0.3);
  color: #664d03;
}

html[data-theme="light"] .summary-number {
  color: var(--color-text);
}

html[data-theme="light"] .summary-text {
  color: var(--color-text-muted);
}

html[data-theme="light"] .badge.text-bg-dark {
  background: rgba(15, 23, 42, 0.08) !important;
  color: rgba(15, 23, 42, 0.78) !important;
}

html[data-theme="light"] .btn-outline-secondary,
html[data-theme="light"] .btn-outline-primary,
html[data-theme="light"] .btn-outline-dark {
  box-shadow: none;
}

html[data-theme="light"] .btn-outline-secondary {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(15, 23, 42, 0.18);
  color: rgba(15, 23, 42, 0.86);
}

html[data-theme="light"] .btn-outline-secondary:hover,
html[data-theme="light"] .btn-outline-secondary:focus {
  background: rgba(15, 23, 42, 0.045);
  border-color: rgba(15, 23, 42, 0.26);
  color: rgba(15, 23, 42, 0.92);
}

html[data-theme="light"] .btn-outline-primary {
  background: rgba(29, 78, 216, 0.05);
  border-color: rgba(29, 78, 216, 0.22);
  color: rgba(15, 23, 42, 0.9);
}

html[data-theme="light"] .btn-outline-primary:hover,
html[data-theme="light"] .btn-outline-primary:focus {
  background: rgba(29, 78, 216, 0.09);
  border-color: rgba(29, 78, 216, 0.3);
  color: rgba(15, 23, 42, 0.95);
}

html[data-theme="light"] .btn-outline-dark {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(15, 23, 42, 0.18);
  color: rgba(15, 23, 42, 0.86);
}

html[data-theme="light"] .btn-outline-dark:hover,
html[data-theme="light"] .btn-outline-dark:focus {
  background: rgba(15, 23, 42, 0.045);
  border-color: rgba(15, 23, 42, 0.26);
  color: rgba(15, 23, 42, 0.92);
}

html[data-theme="light"] .compact-stat-pill,
html[data-theme="light"] .cash-status-badge,
html[data-theme="light"] .cash-entry-badge {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(15, 23, 42, 0.18);
  color: rgba(15, 23, 42, 0.86);
}

html[data-theme="light"] .compact-stat-pill small {
  color: rgba(15, 23, 42, 0.55);
}

html[data-theme="light"] .compact-stat-pill strong {
  color: rgba(15, 23, 42, 0.92);
}

html[data-theme="light"] .compact-stat-pill--warning {
  border-color: rgba(102, 77, 3, 0.32);
}

html[data-theme="light"] .compact-stat-pill--success {
  border-color: rgba(15, 81, 50, 0.32);
}

html[data-theme="light"] .compact-stat-pill--info {
  border-color: rgba(29, 78, 216, 0.28);
}

/* Sidebar: keep neutral on light theme; reserve strong colors for true CTAs only. */
html[data-theme="light"] .app-sidebar__link {
  color: rgba(15, 23, 42, 0.76);
}

html[data-theme="light"] .app-sidebar__link:hover,
html[data-theme="light"] .app-sidebar__link:focus {
  background: rgba(15, 23, 42, 0.045);
  border-color: rgba(15, 23, 42, 0.14);
  color: rgba(15, 23, 42, 0.92);
}

html[data-theme="light"] .app-sidebar__link.is-active {
  background: rgba(15, 23, 42, 0.065);
  border-color: rgba(15, 23, 42, 0.2);
  color: rgba(15, 23, 42, 0.95);
}

html[data-theme="light"] .app-sidebar__link--attention {
  border-color: rgba(245, 158, 11, 0.28);
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.12), rgba(255, 255, 255, 0));
}

html[data-theme="light"] .app-sidebar__link--attention:hover,
html[data-theme="light"] .app-sidebar__link--attention:focus {
  border-color: rgba(245, 158, 11, 0.4);
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.18), rgba(255, 255, 255, 0));
}

html[data-theme="light"] .app-sidebar__link--attention.is-active {
  border-color: rgba(245, 158, 11, 0.5);
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.22), rgba(255, 255, 255, 0));
  color: rgba(15, 23, 42, 0.95);
}

html[data-theme="light"] .app-sidebar__link--cashier {
  border-color: rgba(16, 185, 129, 0.28);
}

html[data-theme="light"] .app-sidebar__link--cashier:hover,
html[data-theme="light"] .app-sidebar__link--cashier:focus {
  background: rgba(16, 185, 129, 0.075);
  border-color: rgba(16, 185, 129, 0.34);
}

html[data-theme="light"] .app-sidebar__link--cashier.is-active {
  background: rgba(16, 185, 129, 0.1);
  border-color: rgba(16, 185, 129, 0.4);
}

/* Cashier: make the "visor" panel match the light theme (no big dark block). */
html[data-theme="light"] .cash-session-strip {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(15, 23, 42, 0.12);
}

html[data-theme="light"] .cash-counter-chip {
  background: rgba(15, 23, 42, 0.06);
  border-color: rgba(15, 23, 42, 0.12);
  color: rgba(15, 23, 42, 0.86);
}

html[data-theme="light"] .cash-session-meta__text {
  color: rgba(15, 23, 42, 0.56);
}

html[data-theme="light"] .cash-launch-kicker {
  color: rgba(15, 23, 42, 0.58);
}

html[data-theme="light"] .cash-side-stack--counter {
  background: linear-gradient(180deg, #ffffff 0%, #eef2f7 100%);
  border-color: rgba(15, 23, 42, 0.14);
}

html[data-theme="light"] .cash-total-display {
  background: rgba(255, 255, 255, 0.95);
  border-color: rgba(15, 23, 42, 0.14);
  box-shadow: none;
}

html[data-theme="light"] .cash-total-display__label {
  color: rgba(15, 23, 42, 0.62);
}

html[data-theme="light"] .cash-total-display__value {
  color: rgba(15, 23, 42, 0.96);
}

html[data-theme="light"] .cash-price-preview {
  background: rgba(255, 255, 255, 0.95);
  border-color: rgba(15, 23, 42, 0.14);
}

html[data-theme="light"] .cash-price-preview__head {
  color: rgba(15, 23, 42, 0.82);
}

html[data-theme="light"] .cash-price-preview__head strong {
  color: rgba(15, 23, 42, 0.96);
}

html[data-theme="light"] .cash-price-preview__row {
  color: rgba(15, 23, 42, 0.62);
}

html[data-theme="light"] .cash-price-preview__row strong {
  color: rgba(15, 81, 50, 0.92);
}

html[data-theme="light"] .cash-price-preview--active {
  border-color: rgba(16, 185, 129, 0.34);
  box-shadow: 0 0 0 1px rgba(16, 185, 129, 0.12);
}

html[data-theme="light"] .cash-customer-readout {
  background: rgba(255, 255, 255, 0.95);
  border-color: rgba(15, 23, 42, 0.14);
}

html[data-theme="light"] .cash-customer-readout__label {
  color: rgba(15, 23, 42, 0.58);
}

html[data-theme="light"] .cash-customer-readout__value {
  color: rgba(15, 23, 42, 0.96);
}

html[data-theme="light"] .cash-mini-metric {
  background: rgba(255, 255, 255, 0.95);
  border-color: rgba(15, 23, 42, 0.14);
}

html[data-theme="light"] .cash-mini-metric span {
  color: rgba(15, 23, 42, 0.58);
}

html[data-theme="light"] .cash-mini-metric strong {
  color: rgba(15, 23, 42, 0.96);
}

html[data-theme="light"] #cashAddItemButton {
  background: rgba(15, 23, 42, 0.045);
  border-color: rgba(15, 23, 42, 0.18);
  color: rgba(15, 23, 42, 0.92);
  box-shadow: none;
}

html[data-theme="light"] .cash-payment-quick__btn {
  background: rgba(255, 255, 255, 0.96);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

html[data-theme="light"] .cash-payment-quick__btn.is-active,
html[data-theme="light"] .cash-payment-quick__btn.active {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72), 0 14px 28px rgba(15, 23, 42, 0.12);
}

html[data-theme="light"] .cash-mobile-dock {
  background: rgba(255, 255, 255, 0.96);
  border-top-color: rgba(15, 23, 42, 0.14);
}

html[data-theme="light"] .cash-mobile-dock__summary span {
  color: rgba(15, 23, 42, 0.58);
}

html[data-theme="light"] .cash-mobile-dock__summary strong {
  color: rgba(15, 23, 42, 0.96);
}

html[data-theme="light"] .cash-mobile-dock__summary small {
  color: rgba(15, 23, 42, 0.7);
}

html[data-theme="light"] #cashAddItemButton:hover,
html[data-theme="light"] #cashAddItemButton:focus {
  background: rgba(15, 23, 42, 0.07);
  border-color: rgba(15, 23, 42, 0.24);
  color: rgba(15, 23, 42, 0.96);
}

html[data-theme="light"] .app-sidebar__collapse-btn.sidebar-toggle-btn {
  background: rgba(15, 23, 42, 0.05);
  border: 0 !important;
  outline: none !important;
  color: rgba(15, 23, 42, 0.9);
  box-shadow: none;
}

html[data-theme="light"] .app-sidebar__collapse-btn.sidebar-toggle-btn:hover,
html[data-theme="light"] .app-sidebar__collapse-btn.sidebar-toggle-btn:focus {
  background: rgba(15, 23, 42, 0.08);
  border-color: transparent !important;
  outline: none !important;
  box-shadow: none;
  color: rgba(15, 23, 42, 0.95);
}

html[data-theme="light"] .app-sidebar__collapse-btn.sidebar-toggle-btn:focus-visible {
  border: 0 !important;
  outline: none !important;
  box-shadow: none !important;
}


.delivery-checklist-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.5rem 0.75rem;
}

.delivery-checklist-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.delivery-checklist-toolbar__actions {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.intake-reception-grid {
  border: 1px solid rgba(83, 119, 167, 0.28);
  border-radius: 12px;
  padding: 0.65rem;
  background: rgba(10, 20, 34, 0.34);
}

.delivery-checklist-progress-text {
  color: var(--color-text-muted);
  font-size: 0.82rem;
  font-weight: 600;
}

.delivery-checklist-progress {
  margin-top: 0.55rem;
  margin-bottom: 0.8rem;
  height: 8px;
  width: 100%;
  border-radius: 999px;
  border: 1px solid rgba(83, 119, 167, 0.35);
  background: rgba(10, 20, 34, 0.55);
  overflow: hidden;
}

.delivery-checklist-progress__bar {
  height: 100%;
  width: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #1faa73, #3bc691);
  transition: width 0.18s ease;
}

.delivery-checklist-section {
  margin-bottom: 0.8rem;
}

.delivery-checklist-section__title {
  margin-bottom: 0.4rem;
  color: var(--color-text-muted);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.delivery-checklist-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.6rem;
  border-radius: 10px;
  border: 1px solid rgba(83, 119, 167, 0.3);
  background: rgba(14, 24, 40, 0.5);
  transition: border-color 0.2s ease, background 0.2s ease;
}

.delivery-checklist-item.is-checked {
  border-color: rgba(40, 167, 105, 0.55);
  background: rgba(31, 122, 79, 0.2);
}

.delivery-checklist-required {
  margin-left: auto;
  padding: 0.08rem 0.42rem;
  border-radius: 999px;
  background: rgba(16, 185, 129, 0.22);
  color: #ccffe4;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.delivery-inspection {
  border: 1px solid rgba(83, 119, 167, 0.3);
  border-radius: 14px;
  background: rgba(10, 20, 34, 0.38);
  padding: 0.75rem;
}

.vehicle-map {
  position: relative;
  width: 100%;
  border-radius: 14px;
  border: 1px solid rgba(83, 119, 167, 0.32);
  background: linear-gradient(180deg, rgba(236, 242, 251, 0.98), rgba(223, 231, 243, 0.96));
  overflow: hidden;
  cursor: crosshair;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.36);
}

.vehicle-map--sheet {
  min-height: 360px;
  aspect-ratio: 3 / 2;
}

.vehicle-map__svg,
.vehicle-map__image {
  width: 100%;
  height: auto;
  display: block;
}

.vehicle-map__image {
  user-select: none;
  pointer-events: none;
}

.vehicle-map.is-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: default;
  background: linear-gradient(180deg, rgba(24, 39, 62, 0.95), rgba(14, 25, 40, 0.97));
}

.vehicle-map.is-fallback .vehicle-map__image,
.vehicle-map.is-fallback .vehicle-map__markers {
  display: none;
}

.vehicle-map.is-fallback::after {
  content: "Falha ao carregar o diagrama. Recarregue a página.";
  color: rgba(210, 225, 246, 0.9);
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-align: center;
  padding: 1rem;
}

.vehicle-map__label {
  fill: rgba(186, 206, 236, 0.78);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.vehicle-map__markers {
  position: absolute;
  inset: 0;
}

.vehicle-map-help {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  font-size: 0.82rem;
  color: var(--color-text-muted);
}

.vehicle-map-help span {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.16rem 0.55rem;
  border-radius: 999px;
  border: 1px solid rgba(83, 119, 167, 0.26);
  background: rgba(9, 18, 32, 0.55);
}

.vehicle-map-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.vehicle-map-quick-notes {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.vehicle-map-quick-notes .btn {
  --bs-btn-padding-y: 0.18rem;
  --bs-btn-padding-x: 0.52rem;
  --bs-btn-font-size: 0.74rem;
}

.quote-item-picker-quick-create {
  position: sticky;
  bottom: 0;
  z-index: 4;
  background: linear-gradient(180deg, rgba(14, 27, 49, 0.96), rgba(12, 24, 45, 0.98));
  border-color: rgba(124, 165, 220, 0.45) !important;
  box-shadow: 0 -10px 26px rgba(3, 10, 21, 0.45);
}

html[data-theme="light"] .quote-item-picker-quick-create {
  background: #ffffff;
  border-color: #d4deeb !important;
  box-shadow: 0 -8px 24px rgba(11, 24, 46, 0.08);
}

.quote-picker-dialog-fallback {
  width: min(760px, 94vw);
  border: 0;
  border-radius: 14px;
  padding: 0;
  background: var(--color-surface, #0e1b31);
  color: var(--color-text, #e6eefb);
  box-shadow: 0 24px 48px rgba(3, 10, 21, 0.55);
}

.quote-picker-dialog-fallback::backdrop {
  background: rgba(1, 6, 16, 0.72);
}

.quote-picker-dialog-fallback__form {
  padding: 0.9rem;
}

.quote-picker-dialog-fallback__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.7rem;
  margin-bottom: 0.7rem;
}

.quote-picker-dialog-fallback__header h3 {
  margin: 0;
  font-size: 1rem;
}

html[data-theme="light"] .quote-picker-dialog-fallback {
  background: #ffffff;
  color: #111827;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.2);
}

.vehicle-map-type-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.vehicle-map-marker {
  position: absolute;
  transform: translate(-50%, -50%);
  width: 22px;
  height: 22px;
  border: 1px solid #ffffff;
  border-radius: 999px;
  color: #fff;
  font-size: 0.64rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.26);
}

.vehicle-map-marker.risk {
  background: #ef4444;
}

.vehicle-map-marker.scratch {
  background: #f97316;
}

.vehicle-map-marker.dent {
  background: #2563eb;
}

.vehicle-map-marker.break {
  background: #f59e0b;
}

.vehicle-map-marker.crack {
  background: #16a34a;
}

.vehicle-map-marker.missing {
  background: #7c3aed;
}

.vehicle-map-marker.other {
  background: #334155;
}

.vehicle-map-marker.paint {
  background: #22c55e;
}

.vehicle-map-list {
  max-height: 140px;
  overflow: auto;
  border: 1px solid rgba(83, 119, 167, 0.24);
  border-radius: 10px;
  padding: 0.35rem 0.45rem;
  background: rgba(8, 17, 30, 0.5);
}

.vehicle-map-list__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  font-size: 0.82rem;
  color: var(--color-text-muted);
  padding: 0.3rem 0.2rem;
  border-bottom: 1px dashed rgba(83, 119, 167, 0.2);
}

.vehicle-map-list__left {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
}

.vehicle-map-list__left span:last-child {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vehicle-map-type-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid transparent;
  padding: 0.1rem 0.42rem;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #fff;
}

.vehicle-map-type-tag.risk {
  background: rgba(239, 68, 68, 0.36);
  border-color: rgba(245, 146, 146, 0.56);
}

.vehicle-map-type-tag.scratch {
  background: rgba(249, 115, 22, 0.34);
  border-color: rgba(252, 175, 125, 0.56);
}

.vehicle-map-type-tag.dent {
  background: rgba(37, 99, 235, 0.34);
  border-color: rgba(132, 170, 250, 0.56);
}

.vehicle-map-type-tag.break {
  background: rgba(245, 158, 11, 0.36);
  border-color: rgba(248, 190, 87, 0.56);
}

.vehicle-map-type-tag.crack {
  background: rgba(22, 163, 74, 0.34);
  border-color: rgba(124, 232, 157, 0.56);
}

.vehicle-map-type-tag.missing {
  background: rgba(124, 58, 237, 0.34);
  border-color: rgba(181, 145, 249, 0.56);
}

.vehicle-map-type-tag.other {
  background: rgba(51, 65, 85, 0.4);
  border-color: rgba(153, 168, 190, 0.56);
}

.vehicle-map-type-tag.paint {
  background: rgba(34, 197, 94, 0.36);
  border-color: rgba(116, 223, 154, 0.56);
}

.vehicle-map-list__remove {
  border: 1px solid rgba(83, 119, 167, 0.42);
  background: rgba(9, 18, 32, 0.6);
  color: var(--color-text-muted);
  border-radius: 8px;
  padding: 0.2rem 0.48rem;
  font-size: 0.72rem;
  font-weight: 600;
}

.vehicle-map-list__remove:hover {
  border-color: rgba(110, 151, 212, 0.66);
  color: var(--color-text-primary);
}

.vehicle-map-list__item:last-child {
  border-bottom: 0;
}

.vehicle-map-list__empty {
  color: var(--color-text-muted);
  font-size: 0.8rem;
  padding: 0.4rem 0.2rem;
}

.signature-pad {
  position: relative;
  width: 100%;
  min-height: 170px;
  border-radius: 14px;
  border: 1px dashed rgba(120, 160, 210, 0.45);
  background: rgba(10, 20, 34, 0.65);
  overflow: hidden;
}

.signature-pad canvas {
  width: 100%;
  height: 170px;
  display: block;
}

.signature-pad__hint {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(159, 178, 204, 0.6);
  font-size: 0.85rem;
  pointer-events: none;
}

@media (max-width: 768px) {
  .vehicle-map--sheet {
    min-height: 230px;
  }
}

html[data-theme="light"] .delivery-checklist-item {
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(15, 23, 42, 0.16);
}

html[data-theme="light"] .delivery-checklist-item.is-checked {
  background: rgba(20, 148, 89, 0.11);
  border-color: rgba(20, 148, 89, 0.28);
}

html[data-theme="light"] .delivery-checklist-required {
  background: rgba(16, 185, 129, 0.14);
  color: rgba(8, 72, 49, 0.95);
}

html[data-theme="light"] .delivery-inspection {
  background: rgba(255, 255, 255, 0.78);
  border-color: rgba(15, 23, 42, 0.14);
}

html[data-theme="light"] .intake-reception-grid {
  background: rgba(255, 255, 255, 0.82);
  border-color: rgba(15, 23, 42, 0.14);
}

html[data-theme="light"] .vehicle-map {
  border-color: rgba(15, 23, 42, 0.18);
  background: linear-gradient(180deg, rgba(252, 253, 255, 0.98), rgba(244, 248, 255, 0.96));
}

html[data-theme="light"] .vehicle-map-help span {
  background: rgba(255, 255, 255, 0.88);
  border-color: rgba(15, 23, 42, 0.14);
  color: rgba(15, 23, 42, 0.65);
}

html[data-theme="light"] .vehicle-map-list {
  background: rgba(255, 255, 255, 0.88);
  border-color: rgba(15, 23, 42, 0.14);
}

html[data-theme="light"] .vehicle-map-list__item {
  color: rgba(15, 23, 42, 0.72);
  border-bottom-color: rgba(15, 23, 42, 0.1);
}

html[data-theme="light"] .vehicle-map-list__remove {
  border-color: rgba(15, 23, 42, 0.18);
  background: rgba(255, 255, 255, 0.9);
  color: rgba(15, 23, 42, 0.66);
}

html[data-theme="light"] .signature-pad {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(15, 23, 42, 0.2);
}

html[data-theme="light"] .signature-pad__hint {
  color: rgba(15, 23, 42, 0.45);
}

html[data-theme="light"] .guided-flow-card {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(15, 23, 42, 0.14);
}

html[data-theme="light"] .guided-flow-step {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(15, 23, 42, 0.16);
  color: rgba(15, 23, 42, 0.72);
}

html[data-theme="light"] .mobile-quick-dock {
  background: rgba(255, 255, 255, 0.95);
  border-color: rgba(15, 23, 42, 0.14);
}


.audit-details summary {
  cursor: pointer;
  list-style: none;
}

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

.audit-details__body {
  margin-top: 0.4rem;
  display: grid;
  gap: 0.25rem;
}

.audit-details__meta {
  white-space: pre-wrap;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.78rem;
  background: rgba(10, 20, 34, 0.6);
  border: 1px solid rgba(83, 119, 167, 0.35);
  border-radius: 10px;
  padding: 0.5rem 0.6rem;
  color: var(--color-text);
  max-height: 180px;
  overflow: auto;
}

html[data-theme="light"] .audit-details__meta {
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(15, 23, 42, 0.16);
}

.form-mobile-actions {
  border-top: 1px solid rgba(83, 119, 167, 0.2);
}

.guided-flow-card {
  border: 1px solid rgba(83, 119, 167, 0.32);
  border-radius: 14px;
  padding: 0.75rem 0.85rem;
  background: rgba(10, 20, 34, 0.56);
}

.guided-flow-card__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.guided-flow-steps {
  margin-top: 0.55rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.guided-flow-step {
  border: 1px solid rgba(83, 119, 167, 0.34);
  border-radius: 999px;
  background: rgba(9, 18, 32, 0.58);
  color: var(--color-text-muted);
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1;
  padding: 0.42rem 0.78rem;
}

.guided-flow-step.is-active {
  color: #06101c;
  border-color: rgba(39, 196, 128, 0.9);
  background: linear-gradient(135deg, rgba(38, 193, 126, 0.98), rgba(76, 228, 162, 0.96));
}

.mobile-quick-dock {
  position: fixed;
  left: 0.75rem;
  right: 0.75rem;
  bottom: 0.6rem;
  z-index: 1100;
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.6rem;
  border: 1px solid rgba(83, 119, 167, 0.42);
  border-radius: 14px;
  background: rgba(8, 16, 29, 0.95);
  backdrop-filter: blur(8px);
}

.mobile-quick-dock .btn {
  flex: 1 1 0;
  min-height: 38px;
}

.mobile-dock-offset {
  display: none;
}

.search-quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.search-quick-actions .btn {
  border-radius: 999px;
}

.search-stats-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border: 1px solid rgba(83, 119, 167, 0.36);
  border-radius: 999px;
  padding: 0.22rem 0.65rem;
  font-size: 0.78rem;
  color: var(--color-text-muted);
  background: rgba(9, 18, 32, 0.52);
}

.timeline-list {
  display: grid;
  gap: 0.75rem;
}

.timeline-item {
  position: relative;
  padding-left: 1.1rem;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.35rem;
  width: 0.52rem;
  height: 0.52rem;
  border-radius: 999px;
  background: rgba(83, 119, 167, 0.85);
  box-shadow: 0 0 0 3px rgba(83, 119, 167, 0.18);
}

.timeline-item__title {
  font-weight: 600;
  color: var(--color-text-primary);
}

.timeline-item__meta {
  font-size: 0.78rem;
  color: var(--color-text-muted);
}

.dashboard-focus-grid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.dashboard-focus-item {
  border: 1px solid rgba(83, 119, 167, 0.3);
  border-radius: 14px;
  padding: 0.8rem 0.9rem;
  background: rgba(10, 20, 34, 0.52);
}

.dashboard-focus-item--danger {
  border-color: rgba(224, 95, 95, 0.42);
  background: rgba(46, 13, 17, 0.44);
}

.dashboard-focus-item--warning {
  border-color: rgba(221, 153, 81, 0.42);
  background: rgba(48, 29, 10, 0.44);
}

.dashboard-focus-item--info {
  border-color: rgba(83, 119, 167, 0.42);
}

@media (max-width: 991.98px) {
  .navbar-user-tools {
    width: 100%;
    justify-content: flex-end;
  }

  .form-mobile-actions {
    position: sticky;
    bottom: 0;
    z-index: 6;
    background: rgba(8, 17, 31, 0.94) !important;
    backdrop-filter: blur(8px);
    margin-inline: -1rem;
    padding-inline: 1rem;
    padding-block: 0.7rem;
  }

  .guided-flow-card__head {
    flex-direction: column;
    align-items: flex-start;
  }

  .guided-flow-steps {
    width: 100%;
  }

  .guided-flow-step {
    flex: 1 1 0;
    text-align: center;
  }

  .mobile-quick-dock {
    display: flex;
  }

  .mobile-dock-offset {
    display: block;
    height: 84px;
  }

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

  .simple-toolbar .btn {
    width: 100%;
  }
}

@media (max-width: 575.98px) {
  .timeline-item__title {
    font-size: 0.92rem;
  }

  .search-stats-chip {
    font-size: 0.72rem;
    padding: 0.18rem 0.56rem;
  }
}

/* Print refinements (A4) for quote sheet: cleaner and less visual noise. */
@media print {
  @page {
    size: A4;
    margin: 9mm;
  }

  .navbar,
  .no-print {
    display: none !important;
  }

  main.py-3 {
    padding-top: 0 !important;
  }

  .container-fluid {
    max-width: 100% !important;
    padding: 0 !important;
  }

  .card {
    border: none !important;
    box-shadow: none !important;
  }

  body {
    background: #ffffff !important;
  }

  .quote-sheet {
    background: #ffffff !important;
    border: 1px solid #cfd3d8 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    color: #111111 !important;
    font-size: 10pt !important;
    line-height: 1.35 !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .quote-sheet .card-body {
    padding: 0 !important;
  }

  .quote-topbar {
    grid-template-columns: minmax(0, 1fr) 60mm !important;
    gap: 3.2mm !important;
    margin-bottom: 2.4mm !important;
    padding-bottom: 2mm !important;
    border-bottom: 1px solid #d2d2d2 !important;
  }

  .quote-brand-block {
    gap: 3mm !important;
  }

  .quote-header-logo {
    width: 16mm !important;
    height: 16mm !important;
    flex-basis: 16mm !important;
    border-radius: 2.5mm !important;
    border: 1px solid #cfd3d8 !important;
    box-shadow: none !important;
    filter: grayscale(100%) !important;
  }

  .quote-kicker,
  .quote-commercial-strip,
  .quote-identity-strip,
  .quote-inline-badge,
  .quote-payment-highlight,
  .quote-total-footer,
  .quote-approval-panel,
  .quote-intake-panel {
    display: none !important;
  }

  .quote-company-title {
    font-size: 13pt !important;
    margin-bottom: 1mm !important;
  }

  .quote-company-meta {
    font-size: 7.4pt !important;
    line-height: 1.24 !important;
    color: #4d4d4d !important;
  }

  .quote-meta-card,
  .quote-panel,
  .quote-table-wrap,
  .quote-total-card {
    background: #ffffff !important;
    border: 1px solid #d2d2d2 !important;
    border-radius: 2.5mm !important;
    box-shadow: none !important;
    break-inside: avoid;
    page-break-inside: avoid;
  }

  .quote-meta-card {
    padding: 1.5mm 1.9mm !important;
  }

  .quote-meta-row {
    padding: 0.72mm 0 !important;
    font-size: 7.8pt !important;
    border-bottom: 1px solid #e1e1e1 !important;
  }

  .quote-meta-row--accent {
    margin-top: 0.7mm !important;
    padding: 0.9mm !important;
    background: #f5f5f5 !important;
    border: 1px solid #d2d2d2 !important;
    border-radius: 1.6mm !important;
  }

  .quote-meta-row--accent strong {
    font-size: 9.2pt !important;
  }

  .quote-client-grid,
  .quote-details-grid,
  .quote-summary-grid {
    gap: 3mm !important;
    margin-bottom: 3mm !important;
  }

  .quote-client-grid,
  .quote-details-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .quote-summary-grid {
    grid-template-columns: minmax(0, 1fr) 60mm !important;
  }
  .quote-summary-grid--single {
    grid-template-columns: minmax(0, 1fr) !important;
  }
  .quote-summary-grid--single .quote-total-card {
    width: 60mm !important;
    max-width: 60mm !important;
  }

  .quote-panel {
    padding: 2.3mm 2.7mm !important;
  }

  .quote-panel-title,
  .quote-summary-label,
  .quote-total-card__title {
    color: #4a4a4a !important;
    font-size: 7.2pt !important;
    letter-spacing: 0.04em !important;
    margin-bottom: 0.8mm !important;
  }

  .quote-field-value {
    font-size: 9.6pt !important;
    color: #111111 !important;
  }

  .quote-field-subtle,
  .quote-copy-text,
  .quote-total-row,
  .quote-payment-balance__row,
  .quote-signoff__label,
  .quote-footer-note {
    color: #4e4e4e !important;
    font-size: 8.2pt !important;
    line-height: 1.35 !important;
  }

  .quote-table-wrap {
    margin-bottom: 3mm !important;
  }

  .quote-sheet .table {
    font-size: 8.6pt !important;
    margin-bottom: 0 !important;
  }

  .quote-sheet .table thead {
    display: table-header-group;
  }

  .quote-sheet .table th {
    background: #f3f3f3 !important;
    color: #2e2e2e !important;
    font-size: 7.4pt !important;
    text-transform: uppercase !important;
    letter-spacing: 0.04em !important;
    padding: 1.6mm 1.8mm !important;
    border-color: #d8d8d8 !important;
  }

  .quote-sheet .table > :not(caption) > * > * {
    padding: 1.45mm 1.8mm !important;
    border-color: #d8d8d8 !important;
  }

  .quote-sheet--items-compact .quote-topbar {
    grid-template-columns: minmax(0, 1fr) 56mm !important;
    gap: 2.4mm !important;
    margin-bottom: 1.8mm !important;
    padding-bottom: 1.6mm !important;
  }

  .quote-sheet--items-compact .quote-company-title {
    font-size: 12pt !important;
    margin-bottom: 0.6mm !important;
  }

  .quote-sheet--items-compact .quote-company-meta {
    font-size: 6.6pt !important;
    line-height: 1.15 !important;
  }

  .quote-sheet--items-compact .quote-meta-card {
    padding: 1.2mm 1.6mm !important;
  }

  .quote-sheet--items-compact .quote-meta-row {
    padding: 0.55mm 0 !important;
    font-size: 7.4pt !important;
  }

  .quote-sheet--items-compact .quote-client-grid,
  .quote-sheet--items-compact .quote-details-grid,
  .quote-sheet--items-compact .quote-summary-grid {
    gap: 2.2mm !important;
    margin-bottom: 2.2mm !important;
  }

  .quote-sheet--items-compact .quote-panel {
    padding: 1.8mm 2.2mm !important;
  }

  .quote-sheet--items-compact .quote-sheet .table {
    font-size: 8.1pt !important;
  }

  .quote-sheet--items-compact .quote-sheet .table th {
    font-size: 7pt !important;
    padding: 1.2mm 1.5mm !important;
  }

  .quote-sheet--items-compact .quote-sheet .table > :not(caption) > * > * {
    padding: 1.08mm 1.5mm !important;
  }

  .quote-sheet--items-dense .quote-company-meta {
    font-size: 6.7pt !important;
  }

  .quote-sheet--items-dense .quote-sheet .table {
    font-size: 7.6pt !important;
  }

  .quote-sheet--items-dense .quote-sheet .table th {
    font-size: 6.6pt !important;
    padding: 1.02mm 1.3mm !important;
  }

  .quote-sheet--items-dense .quote-sheet .table > :not(caption) > * > * {
    padding: 0.95mm 1.3mm !important;
  }

  .quote-sheet--items-ultra .quote-company-meta {
    font-size: 6.3pt !important;
  }

  .quote-sheet--items-ultra .quote-sheet .table {
    font-size: 7.1pt !important;
  }

  .quote-sheet--items-ultra .quote-sheet .table th {
    font-size: 6.2pt !important;
    padding: 0.9mm 1.15mm !important;
  }

  .quote-sheet--items-ultra .quote-sheet .table > :not(caption) > * > * {
    padding: 0.82mm 1.15mm !important;
  }

  .quote-sheet .table tbody tr {
    break-inside: avoid;
    page-break-inside: avoid;
  }

  .quote-total-card {
    padding: 2.1mm 2.5mm !important;
  }

  .quote-total-row {
    padding: 0.9mm 0 !important;
    border-bottom: 1px solid #e1e1e1 !important;
  }

  .quote-grand-total {
    margin-top: 1.2mm !important;
    padding: 1.5mm !important;
    border-radius: 2mm !important;
    border: 1px solid #d2d2d2 !important;
    background: #f4f4f4 !important;
  }

  .quote-grand-total span {
    font-size: 8.2pt !important;
  }

  .quote-grand-total strong {
    font-size: 10.2pt !important;
  }

  .quote-payment-balance {
    margin-top: 1.2mm !important;
    padding-top: 1.2mm !important;
    border-top: 1px dashed #d2d2d2 !important;
  }

  .quote-signoff {
    margin-top: 4mm !important;
    padding-top: 3mm !important;
  }

  .quote-signoff__line {
    width: 72mm !important;
    border-bottom: 1px solid #9d9d9d !important;
    margin-bottom: 1mm !important;
  }

  .quote-footer-note {
    margin-top: 3mm !important;
    padding-top: 2mm !important;
    border-top: 1px solid #d2d2d2 !important;
  }
}
