:root {
  --bg: #f3f5f9;
  --panel: #ffffff;
  --ink: #111827;
  --muted: #667085;
  --line: #d7deea;
  --brand: #0b2f8a;
  --brand-dark: #071b3a;
  --accent: #1d4ed8;
  --royal-soft: #eaf0ff;
  --royal-line: #b8c7f5;
  --surface: #f8fafc;
  --success: #178455;
  --shadow: 0 18px 46px rgba(17, 24, 39, 0.1);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: linear-gradient(135deg, #f8fafc, #eef2f7 58%, #e8eef8);
  font-family: "Segoe UI", Arial, sans-serif;
}

.auth-hidden,
.access-hidden,
.hidden {
  display: none !important;
}

.login-screen {
  align-items: center;
  background: linear-gradient(135deg, #071b3a 0%, #0b2f8a 54%, #eef2f7 54%, #f8fafc 100%);
  display: grid;
  min-height: 100vh;
  padding: 28px;
  place-items: center;
}

.login-card {
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 28px 68px rgba(7, 27, 58, 0.26);
  display: grid;
  gap: 16px;
  max-width: 430px;
  padding: 34px;
  width: min(100%, 430px);
}

.login-card img {
  height: 72px;
  object-fit: contain;
  width: 72px;
}

.login-card h1 {
  margin: 0;
}

.user-chip {
  border: 1px solid var(--royal-line);
  border-radius: 999px;
  background: var(--royal-soft);
  color: var(--brand-dark);
  font-weight: 900;
  padding: 10px 14px;
  white-space: nowrap;
}

button,
input,
select {
  font: inherit;
}

.app-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  min-height: 100vh;
}

.app-shell.vendor-shell {
  display: block;
}

.sidebar {
  background: linear-gradient(180deg, #050b18, #071b3a 54%, #0b2f8a);
  color: #fff;
  padding: 28px 22px;
  box-shadow: 14px 0 36px rgba(7, 27, 58, 0.18);
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 34px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 86px;
  height: 58px;
  border-radius: 14px;
  background: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.52);
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.18);
  overflow: hidden;
}

.brand-mark img {
  display: block;
  width: 78px;
  height: 50px;
  object-fit: contain;
}

.brand span,
.muted {
  color: var(--muted);
}

.brand span {
  display: block;
  margin-top: 3px;
  color: #b8c5d4;
  font-size: 14px;
}

.nav {
  display: grid;
  gap: 10px;
}

.nav-item[data-view="regions"],
.hero-actions [data-view="regions"] {
  display: none;
}

.nav-item {
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.055);
  color: #edf2ff;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 14px;
  text-align: left;
}

.nav-item[data-view="atualizar"] {
  background: linear-gradient(135deg, #facc15, #f59e0b);
  border-color: rgba(250, 204, 21, 0.95);
  color: #172033;
  font-weight: 900;
  box-shadow: 0 16px 30px rgba(245, 158, 11, 0.22);
}

.nav-item[data-view="atualizar"] .nav-icon {
  background: rgba(255, 255, 255, 0.42);
  color: #172033;
}

.nav-item[data-view="atualizar"]:hover,
.nav-item[data-view="atualizar"].active {
  background: linear-gradient(135deg, #fde047, #f97316);
  border-color: #fde047;
  color: #111827;
  box-shadow: 0 18px 34px rgba(249, 115, 22, 0.28);
}

.nav-item.active,
.nav-item:hover {
  background: #ffffff;
  border-color: #ffffff;
  color: var(--brand-dark);
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.16);
}

.update-routine {
  display: none;
}

.update-routine.visible {
  display: block;
}

.nav-icon {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.12);
}

.content {
  padding: 30px;
}

.vendor-shell .content {
  min-height: 100vh;
  padding: 32px;
  background:
    linear-gradient(145deg, rgba(7, 27, 58, 0.98), rgba(11, 47, 138, 0.92) 38%, #f3f5f9 38%, #f8fafc);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 26px;
}

.topbar-title {
  align-items: center;
  display: flex;
  gap: 14px;
  min-width: 0;
}

.topbar-logo {
  width: 118px;
  height: 54px;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 10px 24px rgba(11, 47, 138, 0.12);
  object-fit: contain;
  padding: 4px;
}

.topbar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 12px;
}

.home-return-button {
  min-height: 42px;
  border: 1px solid rgba(9, 95, 115, 0.28);
  border-radius: 8px;
  background: #ffffff;
  color: var(--brand-dark);
  cursor: pointer;
  font-weight: 800;
  padding: 0 16px;
  box-shadow: 0 10px 24px rgba(23, 32, 51, 0.08);
}

.home-return-button:hover {
  background: var(--brand);
  border-color: var(--brand);
  color: #ffffff;
}

.home-return-button.hidden {
  display: none;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--brand);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: 34px;
}

h2 {
  margin-bottom: 8px;
  font-size: 25px;
}

h3 {
  margin-bottom: 8px;
}

.company-strip {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  max-width: 560px;
}

.company-pill {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  padding: 8px 12px;
  color: #42526b;
  font-size: 13px;
  font-weight: 700;
}

.view {
  display: none;
}

.view.visible {
  display: block;
}

.hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  min-height: 240px;
  border-radius: 8px;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.72)),
    linear-gradient(135deg, var(--brand), var(--accent));
  box-shadow: var(--shadow);
  padding: 34px;
}

.hero h2 {
  max-width: 650px;
  font-size: 32px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.primary-action {
  min-height: 46px;
  border: 0;
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  cursor: pointer;
  font-weight: 800;
  padding: 0 18px;
  white-space: nowrap;
}

.primary-action:hover {
  background: var(--brand-dark);
}

.secondary-action {
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.88);
  color: var(--brand-dark);
  cursor: pointer;
  font-weight: 800;
  padding: 0 16px;
  white-space: nowrap;
}

.secondary-action:hover {
  border-color: var(--brand);
  color: var(--brand);
}

.portal-return-link {
  align-items: center;
  background: var(--brand);
  color: #ffffff;
  display: inline-flex;
  justify-content: center;
  text-decoration: none;
}

.portal-return-link:hover {
  background: var(--brand-dark);
  color: #ffffff;
}

.import-progress-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 50% 42%, rgba(37, 99, 235, 0.22), transparent 34%),
    rgba(8, 19, 43, 0.5);
  backdrop-filter: blur(5px);
}

.import-progress-overlay.hidden {
  display: none;
}

.import-progress-panel {
  width: min(520px, 92vw);
  border: 1px solid rgba(191, 211, 245, 0.95);
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff, #f8fbff);
  box-shadow: 0 34px 90px rgba(8, 19, 43, 0.36);
  display: grid;
  gap: 12px;
  justify-items: center;
  padding: 32px;
  text-align: center;
}

.import-progress-brand {
  position: relative;
  display: grid;
  place-items: center;
  width: 94px;
  height: 94px;
  margin-bottom: 4px;
}

.import-progress-brand img {
  position: relative;
  z-index: 2;
  width: 70px;
  height: 70px;
  border: 1px solid #d7e4f7;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 16px 34px rgba(11, 47, 138, 0.18);
  object-fit: contain;
  padding: 5px;
  animation: ion-logo-pulse 1.55s ease-in-out infinite;
}

.import-progress-ring {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background:
    conic-gradient(from 0deg, rgba(11, 47, 138, 0), rgba(11, 47, 138, 0.95), #f5b400, rgba(11, 47, 138, 0));
  animation: ion-ring-spin 1.25s linear infinite;
}

.import-progress-ring::after {
  content: "";
  position: absolute;
  inset: 5px;
  border-radius: inherit;
  background: #ffffff;
}

.import-progress-panel h3 {
  color: #071b3a;
  font-size: 24px;
  font-weight: 950;
  margin: 0 0 4px;
}

.import-progress-panel .eyebrow {
  color: #0b2f8a;
  margin: 0;
}

.import-progress-track {
  position: relative;
  overflow: hidden;
  width: 100%;
  height: 14px;
  border-radius: 999px;
  background: #e7eefb;
  border: 1px solid rgba(29, 78, 216, 0.18);
  box-shadow: inset 0 2px 6px rgba(7, 27, 58, 0.08);
}

.import-progress-track span {
  position: absolute;
  inset: 2px auto 2px 2px;
  width: 38%;
  border-radius: 999px;
  background: linear-gradient(90deg, #0b2f8a, #1d4ed8 50%, #0f8b8d);
  box-shadow: 0 8px 18px rgba(29, 78, 216, 0.22);
  animation: import-progress-slide 1.18s ease-in-out infinite;
}

.import-progress-track span::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.62), transparent);
  animation: import-progress-shine 1.18s ease-in-out infinite;
}

.import-progress-overlay.done .import-progress-track span {
  inset: 2px;
  width: auto;
  background: linear-gradient(90deg, #15803d, #22c55e);
  animation: none;
}

.import-progress-overlay.error .import-progress-track span {
  inset: 2px;
  width: auto;
  background: linear-gradient(90deg, #b91c1c, #ef4444);
  animation: none;
}

.import-progress-overlay.done .import-progress-brand img {
  animation: ion-logo-done 0.55s ease-out both;
}

.import-progress-overlay.done .import-progress-ring {
  background: conic-gradient(from 0deg, #22c55e, #15803d, #22c55e);
  animation: none;
}

.import-progress-overlay.error .import-progress-brand img {
  animation: ion-logo-error 0.42s ease-in-out both;
}

.import-progress-overlay.error .import-progress-ring {
  background: conic-gradient(from 0deg, #ef4444, #b91c1c, #ef4444);
  animation: none;
}

.import-progress-panel p:last-child {
  margin: 0;
  color: #344054;
  font-weight: 700;
}

.import-memory-card {
  border: 1px solid rgba(11, 47, 138, 0.14);
  border-left: 4px solid #facc15;
  border-radius: 8px;
  background: linear-gradient(135deg, #fffdf2, #f8fbff);
  display: grid;
  gap: 4px;
  padding: 10px 12px;
}

.import-memory-card span {
  color: #806000;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.import-memory-card strong {
  color: #071b3a;
  font-size: 15px;
  font-weight: 900;
}

.import-memory-card small {
  color: #526178;
  font-size: 12px;
  font-weight: 700;
  overflow-wrap: anywhere;
}

@keyframes import-progress-slide {
  0% {
    transform: translateX(-12%);
  }
  50% {
    transform: translateX(132%);
  }
  100% {
    transform: translateX(-12%);
  }
}

@keyframes import-progress-shine {
  0% {
    transform: translateX(-120%);
  }
  100% {
    transform: translateX(120%);
  }
}

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

@keyframes ion-logo-pulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.06);
  }
}

@keyframes ion-logo-done {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
  100% {
    transform: scale(1.03);
  }
}

@keyframes ion-logo-error {
  0%,
  100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-4px);
  }
  75% {
    transform: translateX(4px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .import-progress-brand img,
  .import-progress-ring,
  .import-progress-track span,
  .import-progress-track span::after {
    animation-duration: 0.01ms;
    animation-iteration-count: 1;
  }
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.stat-card,
.import-panel,
.result-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.07);
}

.stat-card {
  padding: 20px;
}

.stat-card strong {
  display: block;
  font-size: 28px;
}

.home-vendor-pages {
  margin-top: 24px;
}

.home-vendor-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
}

.home-vendor-card {
  border: 1px solid rgba(9, 95, 115, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(234, 240, 255, 0.9)),
    #fff;
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.08);
  color: var(--ink);
  display: grid;
  gap: 8px;
  min-height: 128px;
  padding: 18px;
  text-decoration: none;
}

.home-vendor-card:hover {
  border-color: var(--brand);
  box-shadow: 0 18px 42px rgba(9, 95, 115, 0.16);
  transform: translateY(-1px);
}

.home-vendor-card span {
  color: var(--brand);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.home-vendor-card strong {
  color: var(--brand-dark);
  font-size: 17px;
}

.home-vendor-card small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.section-header {
  margin-bottom: 18px;
}

.table-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
}

.dashboard-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
}

.dashboard-company {
  width: min(280px, 100%);
}

.dashboard-filter-stack {
  align-items: end;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: flex-end;
}

.dashboard-chart-menu {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.dashboard-chart-button {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.07);
  color: var(--ink);
  cursor: pointer;
  display: grid;
  gap: 6px;
  min-height: 92px;
  padding: 18px;
  text-align: left;
}

.dashboard-chart-button span {
  color: var(--brand-dark);
  font-size: 16px;
  font-weight: 950;
}

.dashboard-chart-button small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.dashboard-chart-button.active,
.dashboard-chart-button:hover {
  border-color: var(--brand);
  background: linear-gradient(135deg, rgba(9, 95, 115, 0.12), rgba(255, 255, 255, 0.96));
}

.dashboard-chart-panel {
  display: none;
}

.dashboard-chart-panel.visible {
  display: block;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 18px;
}

.dashboard-annual-grid {
  display: grid;
  gap: 18px;
}

.dashboard-annual-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(248, 252, 253, 0.88);
  padding: 18px;
}

.dashboard-bars {
  --chart-height: 460px;
  align-items: start;
  display: grid;
  grid-template-columns: 136px minmax(0, 1fr);
  gap: 20px;
  min-height: calc(var(--chart-height) + 118px);
  overflow-x: auto;
  padding: 10px 0 18px;
}

.dashboard-bar-ruler {
  position: relative;
  height: var(--chart-height);
  border-right: 1px solid #c7d9e3;
  align-self: start;
}

.dashboard-bar-ruler span {
  position: absolute;
  right: 10px;
  bottom: var(--mark);
  transform: translateY(50%);
  color: #50627f;
  font-size: 15px;
  font-weight: 900;
  white-space: nowrap;
}

.dashboard-bars-plot {
  position: relative;
  display: grid;
  grid-template-columns: repeat(var(--bar-count), minmax(132px, 1fr));
  gap: 24px;
  min-width: max(100%, calc(var(--bar-count) * 156px));
  height: var(--chart-height);
  align-items: end;
  overflow: visible;
  border-bottom: 1px solid #c7d9e3;
  background-image: linear-gradient(to top, rgba(80, 98, 127, 0.12) 1px, transparent 1px);
  background-size: 100% 40px;
}

.dashboard-bars.monthly {
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 12px;
}

.dashboard-bars.monthly .dashboard-bars-plot {
  grid-template-columns: repeat(var(--bar-count), minmax(58px, 1fr));
  gap: 8px;
  min-width: 100%;
}

.dashboard-bars.monthly .dashboard-bar-fill {
  width: min(54px, 86%);
}

.dashboard-bars.monthly .dashboard-bar-fill span {
  font-size: 13px;
}

.dashboard-bars.monthly .dashboard-bar-column strong,
.dashboard-bars.monthly .dashboard-bar-column small {
  font-size: 13px;
  max-width: 64px;
}

.dashboard-bars.monthly .dashboard-bar-column strong {
  top: calc(100% + 8px);
}

.dashboard-bars.monthly .dashboard-bar-column small {
  top: calc(100% + 32px);
}

.dashboard-bar-column {
  position: relative;
  display: block;
  height: 100%;
  min-width: 0;
  text-align: center;
}

.dashboard-bar-fill {
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: min(76px, 78%);
  height: var(--bar-height);
  min-height: 2px;
  border-radius: 7px 7px 0 0;
  background: #08758b;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.32);
}

.dashboard-bar-fill.color-1 { background: #0f8f4d; }
.dashboard-bar-fill.color-2 { background: #173e8f; }
.dashboard-bar-fill.color-3 { background: #d8872c; }
.dashboard-bar-fill.color-4 { background: #b51d2a; }
.dashboard-bar-fill.color-5 { background: #5a6f82; }
.dashboard-bar-fill.color-6 { background: #5c469c; }

.dashboard-bar-fill span {
  color: #fff;
  font-size: 15px;
  font-weight: 950;
  line-height: 1;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.28);
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  white-space: nowrap;
}

.dashboard-bar-fill.tiny-bar span,
.bar-shape.tiny-bar .bar-value,
.annual-bar.tiny-bar span {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 7px);
  transform: translateX(-50%);
  writing-mode: horizontal-tb;
  color: #21324d;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(199, 217, 227, 0.9);
  border-radius: 6px;
  padding: 4px 7px;
  font-size: 14px;
  font-weight: 950;
  line-height: 1.1;
  text-shadow: none;
  white-space: nowrap;
  z-index: 3;
}

.dashboard-bar-column strong,
.dashboard-bar-column small {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  color: #30425f;
  display: block;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.18;
  max-width: 128px;
  overflow-wrap: break-word;
  white-space: normal;
  word-break: normal;
}

.dashboard-bar-column strong {
  top: calc(100% + 10px);
}

.dashboard-bar-column small {
  color: #65748c;
  font-size: 14px;
  font-weight: 650;
  top: calc(100% + 50px);
}

.dashboard-bars.family .dashboard-bar-column strong {
  min-height: 38px;
}

.dashboard-monthly-block {
  border-top: 1px solid var(--line);
  margin-top: 18px;
  padding-top: 16px;
}

.chart-panel,
.insight-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.07);
}

.chart-panel {
  padding: 24px;
}

.active-chart-panel {
  margin-top: 18px;
}

.chart-title-row {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 20px;
}

.chart-subtitle {
  margin-bottom: 0;
}

.chart-total {
  min-width: 104px;
  border-radius: 8px;
  background: #102434;
  color: #fff;
  font-size: 28px;
  font-weight: 900;
  padding: 12px 16px;
  text-align: center;
}

.uf-chart {
  overflow: auto;
}

.uf-row {
  display: grid;
  grid-template-columns: 46px minmax(180px, 1fr) repeat(var(--year-count), minmax(112px, 1fr)) 132px;
  align-items: center;
  min-width: calc(370px + (var(--year-count) * 122px));
  border-bottom: 1px solid #e8eef5;
}

.uf-row.header {
  position: sticky;
  top: 0;
  z-index: 2;
  border-bottom-color: var(--line);
  background: #f7fafc;
  color: #344054;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.uf-label {
  color: #344054;
  font-weight: 900;
  padding: 11px 10px;
}

.uf-client-cell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 74px;
  align-items: center;
  gap: 10px;
  padding: 10px;
}

.uf-track {
  height: 20px;
  border-radius: 999px;
  background: #e7edf4;
  overflow: hidden;
}

.uf-fill {
  width: var(--bar-width);
  min-width: var(--bar-min);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--brand), #1d4ed8 64%, #111827);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22);
}

.uf-value {
  color: #1f2a3d;
  font-variant-numeric: tabular-nums;
  font-weight: 850;
  text-align: right;
}

.uf-money,
.uf-total {
  color: #1f2a3d;
  font-variant-numeric: tabular-nums;
  font-weight: 760;
  padding: 11px 10px;
  text-align: right;
  white-space: nowrap;
}

.uf-total {
  color: var(--brand-dark);
  font-weight: 900;
}

.insight-panel {
  align-self: start;
  display: grid;
  gap: 12px;
  padding: 18px;
}

.insight-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 18px;
}

.insight-card span,
.insight-note {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.insight-card strong {
  display: block;
  margin-top: 6px;
  color: var(--ink);
  font-size: 30px;
}

.insight-card.accent {
  border-color: rgba(11, 47, 138, 0.24);
  background: rgba(11, 47, 138, 0.08);
}

.insight-note {
  line-height: 1.45;
  padding: 4px 2px;
}

.activity-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px;
  color: #344054;
  font-size: 13px;
  font-weight: 850;
}

.activity-legend span {
  display: flex;
  align-items: center;
  gap: 7px;
}

.activity-legend i {
  display: block;
  width: 13px;
  height: 13px;
  border-radius: 4px;
}

.legend-active {
  background: #008f39;
}

.legend-inactive {
  background: #ff2800;
}

.activity-chart {
  display: grid;
  gap: 12px;
}

.activity-row {
  display: grid;
  grid-template-columns: 42px 70px repeat(var(--year-count), minmax(156px, 1fr));
  gap: 10px;
  align-items: center;
}

.activity-row.header {
  color: #344054;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.activity-uf {
  color: #344054;
  font-weight: 900;
}

.activity-total {
  border-radius: 8px;
  background: #f2f6fa;
  color: #1f2a3d;
  font-variant-numeric: tabular-nums;
  font-weight: 900;
  padding: 8px 10px;
  text-align: right;
}

.activity-year {
  display: grid;
}

.activity-stack {
  display: flex;
  height: 30px;
  overflow: hidden;
  border-radius: 999px;
  background: #eef2f6;
  box-shadow: inset 0 0 0 1px rgba(23, 32, 51, 0.06);
}

.vendor-region-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.vendor-region-summary article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7fafc;
  padding: 16px;
}

.vendor-region-summary span {
  color: var(--muted);
  display: block;
  font-size: 12px;
  font-weight: 850;
}

.vendor-region-summary strong {
  color: var(--ink);
  display: block;
  font-size: 24px;
  margin-top: 4px;
}

.vendor-region-controls {
  display: grid;
  gap: 10px;
  margin-bottom: 18px;
}

.segmented-control {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.segmented-control button {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: #344054;
  cursor: pointer;
  font-weight: 850;
  padding: 0 13px;
}

.segmented-control button.active,
.segmented-control button:hover {
  border-color: var(--brand);
  background: var(--brand);
  color: #fff;
}

.vendor-region-sections {
  display: grid;
  gap: 18px;
}

.vendor-region-chart-block {
  display: grid;
  gap: 16px;
}

.vendor-region-chart-block h4 {
  margin: 0;
  color: var(--brand-dark);
}

.vendor-daily-contacts-card {
  background: #fff;
  border: 1px solid rgba(148, 163, 184, 0.34);
  border-radius: 8px;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.08);
  margin: 0 0 16px;
  padding: 18px;
}

.vendor-daily-contact-chart {
  overflow-x: auto;
  padding: 10px 2px 2px;
}

.vendor-monthly-clients-chart {
  overflow-x: auto;
  padding: 16px 4px 4px;
}

.vendor-monthly-client-bars {
  align-items: end;
  display: grid;
  gap: 12px;
  grid-auto-columns: minmax(64px, 1fr);
  grid-auto-flow: column;
  min-height: 250px;
  padding: 8px 2px 0;
}

.vendor-monthly-client-bar {
  align-items: center;
  display: grid;
  gap: 8px;
  grid-template-rows: 24px 170px 20px;
  justify-items: center;
  min-width: 64px;
}

.vendor-monthly-client-bar span {
  color: #0f172a;
  font-size: 11px;
  font-weight: 650;
}

.vendor-monthly-client-bar i {
  align-self: end;
  background: linear-gradient(180deg, #1d4ed8 0%, #0f8f9f 100%);
  border-radius: 8px 8px 4px 4px;
  box-shadow: 0 10px 22px rgba(29, 78, 216, 0.22);
  display: block;
  height: var(--bar-height);
  min-height: 0;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  width: 38px;
}

.vendor-monthly-client-bar:hover i {
  box-shadow: 0 14px 28px rgba(29, 78, 216, 0.3);
  transform: translateY(-2px);
}

.vendor-monthly-client-bar strong {
  color: #475569;
  font-size: 12px;
  font-weight: 850;
}

.vendor-monthly-client-line-wrap {
  min-width: 560px;
}

.vendor-monthly-client-line {
  display: block;
  height: 270px;
  overflow: visible;
  width: 100%;
}

.vendor-line-grid {
  stroke: #dbe4f0;
  stroke-width: 1;
}

.vendor-line-area {
  fill: url(#vendor-client-line-fill);
}

.vendor-line-path {
  fill: none;
  stroke: #1d4ed8;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 4;
}

.vendor-line-point circle {
  fill: #fff;
  stroke: #0f8f9f;
  stroke-width: 3;
}

.vendor-line-value {
  fill: #0f172a;
  font-size: 12px;
  font-weight: 650;
  text-anchor: middle;
}

.vendor-line-label {
  fill: #475569;
  font-size: 12px;
  font-weight: 850;
  text-anchor: middle;
}

.vendor-monthly-client-line-legend {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
  margin-top: 10px;
}

.vendor-monthly-client-line-legend article {
  align-items: center;
  background: #f8fafc;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 8px;
  display: flex;
  justify-content: space-between;
  padding: 8px 10px;
}

.vendor-monthly-client-line-legend strong,
.vendor-monthly-client-line-legend span {
  color: #334155;
  font-size: 12px;
  font-weight: 800;
}

.vendor-daily-month-filter {
  align-items: center;
  color: #475569;
  display: inline-flex;
  font-size: 12px;
  font-weight: 850;
  gap: 8px;
}

.vendor-daily-month-filter input,
.vendor-daily-month-filter select {
  border: 1px solid rgba(148, 163, 184, 0.42);
  border-radius: 8px;
  color: #0f172a;
  font: inherit;
  min-height: 34px;
  padding: 6px 9px;
}

.vendor-daily-contact-bars {
  align-items: end;
  display: grid;
  gap: 10px;
  grid-auto-columns: minmax(54px, 1fr);
  grid-auto-flow: column;
  min-height: 240px;
}

.vendor-daily-contact-day {
  align-items: center;
  display: grid;
  gap: 7px;
  justify-items: center;
  min-width: 54px;
}

.vendor-daily-contact-stack {
  align-items: end;
  background: #eef2f7;
  border: 1px solid rgba(148, 163, 184, 0.36);
  border-radius: 8px 8px 4px 4px;
  display: flex;
  height: 170px;
  overflow: hidden;
  width: 34px;
}

.vendor-daily-contact-stack i {
  align-items: start;
  color: #fff;
  display: flex;
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
  justify-content: center;
  min-height: 4px;
  width: 50%;
}

.vendor-daily-contact-stack i.inactive,
.vendor-daily-contact-legend i.inactive {
  background: #1d4ed8;
}

.vendor-daily-contact-stack i.never,
.vendor-daily-contact-legend i.never {
  background: #059669;
}

.vendor-daily-contact-stack span {
  margin-top: 4px;
}

.vendor-daily-contact-day strong,
.vendor-daily-contact-day span {
  color: #475569;
  font-size: 11px;
  font-weight: 850;
  text-align: center;
}

.vendor-daily-contact-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 12px;
}

.vendor-daily-contact-legend span {
  align-items: center;
  color: #475569;
  display: inline-flex;
  font-size: 12px;
  font-weight: 850;
  gap: 7px;
}

.vendor-daily-contact-legend i {
  border-radius: 999px;
  display: inline-block;
  height: 10px;
  width: 10px;
}

.vendor-portal-hero {
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(16, 36, 52, 0.96), rgba(9, 95, 115, 0.88)),
    #102434;
  box-shadow: 0 26px 70px rgba(7, 25, 36, 0.28);
  color: #fff;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 18px;
  min-height: 190px;
  padding: 30px;
}

.vendor-portal-hero .eyebrow {
  color: #8ee8df;
}

.vendor-portal-hero h2 {
  font-size: 36px;
  margin-bottom: 10px;
}

.vendor-portal-hero p:last-child {
  color: #c7d7e4;
  margin: 0;
}

.vendor-portal-badge {
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  min-width: 190px;
  padding: 18px;
  text-align: right;
}

.vendor-portal-badge img {
  width: 58px;
  height: 58px;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 14px;
  object-fit: contain;
}

.vendor-portal-badge strong {
  display: block;
  font-size: 24px;
  margin-top: 6px;
}

.vendor-portal-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 20px 60px rgba(23, 32, 51, 0.14);
  padding: 24px;
}

.vendor-workspace-nav {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 18px 0;
}

.vendor-workspace-nav button {
  border: 1px solid rgba(0, 114, 136, 0.2);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 12px 28px rgba(16, 36, 52, 0.1);
  color: var(--brand-dark);
  cursor: pointer;
  font-size: 15px;
  font-weight: 950;
  min-height: 58px;
  padding: 14px 16px;
  text-align: left;
}

.vendor-workspace-nav button.active,
.vendor-workspace-nav button:hover {
  background: linear-gradient(135deg, var(--brand-dark), var(--brand));
  border-color: var(--brand);
  color: #fff;
}

.vendor-workspace-panel {
  display: none;
}

.vendor-workspace-panel.active {
  display: block;
}

.daybyday-shell h3 {
  color: var(--brand-dark);
  font-size: 28px;
  margin: 0 0 8px;
}

.daybyday-content {
  margin-top: 14px;
}

.daybyday-lists {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: 16px;
}

.daybyday-list-card,
.daybyday-detail {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 14px 34px rgba(16, 36, 52, 0.08);
  padding: 16px;
}

.daybyday-list-head,
.daybyday-detail-head,
.daybyday-actions {
  align-items: center;
  display: flex;
  gap: 14px;
  justify-content: space-between;
}

.daybyday-list-head h4,
.daybyday-detail-head h4 {
  color: var(--brand-dark);
  font-size: 20px;
  margin: 0;
}

.daybyday-list-head strong {
  align-items: center;
  background: var(--brand);
  border-radius: 999px;
  color: #fff;
  display: inline-flex;
  font-size: 18px;
  height: 42px;
  justify-content: center;
  min-width: 42px;
  padding: 0 12px;
}

.daybyday-client-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
  max-height: 680px;
  overflow-anchor: none;
  overflow: auto;
  padding-right: 4px;
}

.daybyday-client-card {
  border: 1px solid rgba(0, 114, 136, 0.18);
  border-radius: 8px;
  background: #fff;
  color: var(--brand-dark);
  display: grid;
  gap: 4px;
  padding: 12px;
  text-align: left;
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.daybyday-client-card:hover {
  border-color: var(--brand);
  box-shadow: 0 10px 24px rgba(0, 114, 136, 0.15);
  transform: translateY(-1px);
}

.daybyday-client-card.saved {
  border-color: rgba(0, 148, 76, 0.4);
  background: #f3fff8;
}

.daybyday-client-card .client-code,
.daybyday-client-card em {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
  text-transform: uppercase;
}

.daybyday-client-card strong {
  font-size: 15px;
}

.daybyday-client-card span {
  color: #53627a;
  font-size: 12px;
  font-weight: 700;
}

.daybyday-year-counts {
  display: grid;
  gap: 6px;
  grid-template-columns: repeat(auto-fit, minmax(54px, 1fr));
  margin-top: 8px;
}

.daybyday-year-counts button {
  align-items: center;
  background: #f3f7fb;
  border: 1px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  padding: 6px 8px;
  text-align: left;
}

.daybyday-year-counts button:hover {
  background: #e9f7fb;
  border-color: var(--brand);
}

.daybyday-year-counts button.active {
  background: linear-gradient(135deg, rgba(0, 114, 136, 0.1), rgba(0, 114, 136, 0.18));
  border-color: var(--brand);
  box-shadow: 0 8px 18px rgba(0, 114, 136, 0.12);
}

.daybyday-year-counts small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
}

.daybyday-year-counts strong {
  color: var(--brand);
  font-size: 14px;
}

.daybyday-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.daybyday-purchases-detail {
  border: 1px solid rgba(0, 114, 136, 0.18);
  border-radius: 10px;
  background: linear-gradient(180deg, #f8fbff 0%, #ffffff 100%);
  display: grid;
  gap: 12px;
  margin-bottom: 14px;
  padding: 14px;
  scroll-margin-top: 18px;
}

.daybyday-purchases-banner {
  border: 2px solid rgba(22, 71, 173, 0.35);
  border-radius: 12px;
  background: linear-gradient(180deg, #eef4ff 0%, #ffffff 100%);
  box-shadow: 0 16px 42px rgba(15, 23, 42, 0.1);
  margin-bottom: 16px;
  padding: 14px;
}

.daybyday-purchases-summary-card {
  border: 1px solid rgba(22, 71, 173, 0.26);
  border-radius: 10px;
  background: linear-gradient(180deg, #ffffff 0%, #eff6ff 100%);
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.08);
  display: grid;
  gap: 6px;
  padding: 14px;
}

.daybyday-purchases-summary-card > span {
  color: var(--brand);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.daybyday-purchases-summary-card strong {
  color: var(--brand-dark);
  font-size: 15px;
}

.daybyday-purchases-summary-card small {
  color: #334155;
  font-size: 12px;
  font-weight: 700;
}

.daybyday-purchases-summary-lines {
  display: grid;
  gap: 8px;
  margin-top: 4px;
}

.daybyday-purchases-summary-lines div {
  border-left: 3px solid var(--brand);
  display: grid;
  gap: 2px;
  padding-left: 8px;
}

.daybyday-purchases-summary-lines strong {
  color: var(--brand-dark);
  font-size: 12px;
}

.daybyday-purchases-summary-lines span {
  color: #475569;
  font-size: 12px;
  font-weight: 700;
}

.daybyday-purchases-inline {
  border: 1px solid rgba(22, 71, 173, 0.22);
  border-radius: 10px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  display: grid;
  gap: 8px;
  margin-top: 10px;
  padding: 12px;
  overflow-anchor: none;
}

.daybyday-purchases-inline.error {
  border-color: rgba(185, 28, 28, 0.22);
  background: linear-gradient(180deg, #fff, #fff7f7);
}

.daybyday-purchase-layer {
  position: relative;
  z-index: 4000;
}

.daybyday-purchases-overlay {
  align-items: flex-start;
  background: rgba(9, 18, 40, 0.46);
  bottom: 0;
  display: flex;
  justify-content: center;
  left: 0;
  overflow: auto;
  padding: 24px 16px 36px;
  position: fixed;
  right: 0;
  top: 0;
  z-index: 1200;
}

.daybyday-purchases-overlay .daybyday-purchases-detail {
  box-shadow: 0 28px 80px rgba(9, 18, 40, 0.24);
  margin: 0;
  max-width: min(1100px, calc(100vw - 32px));
  width: 100%;
}

.daybyday-purchases-detail-head {
  align-items: flex-start;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
}

.daybyday-purchases-detail-head h4 {
  color: var(--brand-dark);
  margin: 0;
}

.daybyday-purchases-detail-head span {
  color: var(--muted);
  display: block;
  font-size: 12px;
  margin-top: 2px;
}

.daybyday-purchases-panel {
  border-top: 1px solid var(--line);
  display: none;
  margin-top: 10px;
  overflow-x: auto;
  padding-top: 10px;
}

.daybyday-purchases-panel.active {
  display: block;
}

.daybyday-purchases-panel table {
  border-collapse: collapse;
  font-size: 12px;
  width: 100%;
}

.daybyday-purchases-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  margin-top: 10px;
}

.daybyday-purchases-summary strong {
  color: var(--brand-dark);
}

.daybyday-purchases-panel h5 {
  color: var(--brand-dark);
  font-size: 13px;
  margin: 0 0 8px;
}

.daybyday-purchases-panel th,
.daybyday-purchases-panel td {
  border-bottom: 1px solid var(--line);
  padding: 7px 6px;
  text-align: left;
  white-space: nowrap;
}

.daybyday-purchases-panel th {
  color: var(--muted);
  font-size: 10px;
  text-transform: uppercase;
}

.daybyday-items-row td {
  background: #f8fbfd;
  white-space: normal;
}

.daybyday-items-list {
  display: grid;
  gap: 6px;
}

.daybyday-items-list div {
  border-left: 3px solid var(--brand);
  display: grid;
  gap: 2px;
  padding-left: 8px;
}

.daybyday-items-list strong {
  color: var(--brand-dark);
  font-size: 12px;
}

.daybyday-items-list span {
  color: #53627a;
  font-size: 12px;
}

.daybyday-items-list em {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
}

.daybyday-detail-head {
  border-bottom: 1px solid var(--line);
  margin-bottom: 16px;
  padding-bottom: 14px;
}

.daybyday-detail-head span {
  color: var(--muted);
  display: block;
  font-weight: 800;
  margin-top: 4px;
}

.daybyday-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.daybyday-form label {
  color: var(--brand-dark);
  display: grid;
  font-weight: 900;
  gap: 7px;
}

.daybyday-form .full,
.daybyday-actions,
.daybyday-closed-fields {
  grid-column: 1 / -1;
}

.daybyday-group-client-field {
  display: none !important;
  position: relative;
}

.daybyday-group-client-field.active {
  display: grid !important;
}

.daybyday-main-fields {
  display: contents;
}

.daybyday-main-fields.hidden,
.daybyday-problem-field,
.daybyday-schedule-field {
  display: none !important;
}

.daybyday-problem-field.active,
.daybyday-schedule-field.active {
  display: grid !important;
}

.daybyday-history-item {
  border-left: 3px solid var(--brand);
  display: grid;
  gap: 5px;
  margin-bottom: 8px;
  padding-left: 10px;
}

.daybyday-history-item p {
  margin: 0;
  white-space: normal;
}

.daybyday-closed-fields {
  border: 1px dashed rgba(190, 24, 44, 0.35);
  border-radius: 8px;
  display: none;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 12px;
}

.daybyday-closed-fields.active {
  display: grid;
}

.daybyday-extra-contacts {
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 12px;
  padding: 14px;
}

.daybyday-extra-contacts-head {
  align-items: center;
  display: flex;
  gap: 14px;
  justify-content: space-between;
}

.daybyday-extra-contacts-head span {
  color: var(--muted);
  display: block;
  font-size: 12px;
  font-weight: 800;
  margin-top: 3px;
}

.daybyday-extra-contacts-list {
  display: grid;
  gap: 10px;
}

.daybyday-extra-contact-row {
  align-items: end;
  border-top: 1px solid var(--line);
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(4, minmax(0, 1fr)) auto;
  padding-top: 12px;
}

.mini-action.danger {
  border-color: rgba(190, 24, 44, 0.28);
  color: #be123c;
}

.daybyday-form input,
.daybyday-form select,
.daybyday-form textarea {
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--brand-dark);
  font: inherit;
  padding: 11px 12px;
}

.daybyday-form label.daybyday-field-error {
  color: #d90429;
}

.daybyday-form label.daybyday-field-error input,
.daybyday-form label.daybyday-field-error select,
.daybyday-form label.daybyday-field-error textarea,
.agrp-multi-list.daybyday-field-error {
  border-color: #d90429;
  box-shadow: 0 0 0 3px rgba(217, 4, 41, 0.12);
}

.agrp-multi-list {
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-height: 260px;
  overflow: auto;
  padding: 12px;
}

.agrp-multi-list label {
  align-items: center;
  display: flex;
  flex-direction: row;
  font-size: 12px;
  gap: 8px;
}

.agrp-multi-list input {
  width: auto;
}

.vendor-client-region-panel {
  margin-top: 18px;
}

.vendor-region-clients.hidden {
  display: none;
}

.vendor-client-filters {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.vendor-client-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.vendor-client-summary article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7fafc;
  padding: 12px;
}

.vendor-client-summary span {
  color: var(--muted);
  display: block;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.vendor-client-summary strong {
  color: var(--brand-dark);
  display: block;
  font-size: 22px;
  margin-top: 4px;
}

.vendor-clients-table {
  min-width: 1080px;
}

.vendor-page-link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.donut-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
  gap: 18px;
}

.donut-card {
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 22px;
  padding: 22px;
}

.donut-chart {
  align-items: center;
  aspect-ratio: 1;
  background: conic-gradient(#008f39 0 var(--active-deg), #ff2800 var(--active-deg) var(--inactive-deg), #ffef00 var(--inactive-deg) 360deg);
  border-radius: 50%;
  display: grid;
  justify-items: center;
  padding: 54px;
  position: relative;
}

.donut-chart::after {
  content: "";
  position: absolute;
  inset: 48px;
  border-radius: 50%;
  background: #fff;
}

.donut-chart strong,
.donut-chart span {
  position: relative;
  z-index: 1;
}

.donut-chart strong {
  font-size: 38px;
}

.donut-chart span,
.donut-card p {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.donut-card h5,
.sales-chart-title h5 {
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 15px;
}

.donut-card p {
  margin: 5px 0;
}

.dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 6px;
}

.dot.active {
  background: #008f39;
}

.dot.inactive {
  background: #ff2800;
}

.dot.never {
  background: #ffef00;
}

.dot.average {
  background: #0b2f8a;
}

.quant-donut-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 20px;
}

.quant-title.full {
  align-items: flex-start;
  margin-bottom: 18px;
}

.period-donut-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 18px;
}

.period-donut-item {
  align-items: center;
  display: grid;
  gap: 8px;
  justify-items: center;
  text-align: center;
}

.period-donut {
  align-items: center;
  aspect-ratio: 1;
  background: conic-gradient(#008f39 0 var(--active-deg), #ff2800 var(--active-deg) var(--inactive-deg), #ffef00 var(--inactive-deg) var(--never-deg), #e7edf4 var(--never-deg) 360deg);
  border-radius: 50%;
  display: grid;
  justify-items: center;
  max-width: 180px;
  padding: 38px;
  position: relative;
  width: 100%;
}

.period-donut.average {
  box-shadow: 0 0 0 3px rgba(11, 47, 138, 0.14);
}

.period-donut::after {
  content: "";
  position: absolute;
  inset: 31px;
  border-radius: 50%;
  background: #fff;
}

.period-donut strong,
.period-donut span {
  position: relative;
  z-index: 1;
}

.period-donut strong {
  color: var(--ink);
  font-size: 26px;
  line-height: 1;
}

.period-donut span,
.period-donut-item small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.period-donut span {
  margin-top: 4px;
}

.period-donut-metrics {
  display: grid;
  gap: 4px;
  justify-items: start;
  min-width: 150px;
}

.period-donut-metrics span {
  color: #344054;
  font-size: 11px;
  font-weight: 850;
  text-align: left;
}

.quant-chart-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(520px, 1fr));
  gap: 18px;
}

.quant-chart-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 16px;
}

.quant-title {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.quant-title h5 {
  margin: 0;
  color: var(--ink);
  font-size: 15px;
}

.quant-title span,
.quant-legend {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.quant-plot {
  position: relative;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(74px, 1fr));
  gap: 12px;
  align-items: end;
  height: 300px;
  border-left: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 12px 10px 0;
}

.quant-column {
  align-items: center;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 8px;
  height: 100%;
  position: relative;
}

.quant-bar {
  align-items: center;
  background: #008f39;
  border-radius: 6px 6px 2px 2px;
  color: #fff;
  display: flex;
  justify-content: center;
  min-height: 4px;
  width: 52px;
  height: var(--bar-height);
}

.quant-column.average .quant-bar {
  background: #0b2f8a;
}

.quant-bar strong {
  font-size: 12px;
}

.quant-column span {
  position: absolute;
  top: calc(100% + 8px);
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  min-height: 30px;
  text-align: center;
}

.quant-total-line {
  position: absolute;
  left: 0;
  right: 0;
  bottom: var(--line);
  border-top: 2px solid #5b6472;
  z-index: 2;
}

.quant-total-line span {
  background: #fff;
  color: #344054;
  font-size: 11px;
  font-weight: 900;
  padding: 2px 6px;
}

.quant-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 48px;
}

.sales-chart-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(520px, 1fr));
  gap: 18px;
}

.stacked-sales .sales-chart-list {
  grid-template-columns: 1fr;
}

.annual-sales-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(620px, 1fr));
  gap: 18px;
}

.stacked-sales .annual-sales-list {
  grid-template-columns: 1fr;
}

.sales-chart-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 16px;
}

.annual-sales-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 16px;
}

.sales-chart-title {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.sales-chart-title span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.bar-chart-wrap {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 10px;
}

.bar-ruler {
  position: relative;
  height: var(--chart-height);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-align: right;
}

.bar-ruler span {
  position: absolute;
  right: 0;
  bottom: var(--mark);
  transform: translateY(50%);
  white-space: nowrap;
}

.bar-3d-chart {
  position: relative;
  display: block;
  overflow-x: auto;
  min-height: calc(var(--chart-height) + 66px);
  padding: 0 12px;
}

.plot-area {
  position: relative;
  height: var(--chart-height);
  border-left: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  min-width: max(760px, calc(var(--bar-count) * 118px));
}

.bars-row {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(var(--bar-count), minmax(86px, 1fr));
  align-items: stretch;
  gap: 14px;
}

.bar-column {
  align-items: center;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 8px;
  height: 100%;
  position: relative;
}

.bar-value {
  color: #fff;
  font-size: 13px;
  font-weight: 950;
  line-height: 1;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.28);
  text-align: center;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
}

.bar-shape {
  position: relative;
  align-items: center;
  flex: 0 0 var(--bar-height);
  display: flex;
  justify-content: center;
  width: 54px;
  height: var(--bar-height);
  min-height: 0;
  border-radius: 6px 6px 2px 2px;
  background: var(--brand);
}

.bar-column.current .bar-shape {
  background: #1d4ed8;
}

.bar-column.trend .bar-shape {
  background: #102434;
}

.annual-sales-scroll {
  overflow-x: auto;
}

.annual-sales-chart {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 10px;
  min-width: 1060px;
}

.annual-ruler {
  position: relative;
  height: var(--chart-height);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-align: right;
}

.annual-ruler span {
  position: absolute;
  right: 0;
  bottom: var(--mark);
  transform: translateY(50%);
  white-space: nowrap;
}

.annual-years {
  display: grid;
  gap: 22px;
}

.annual-year-group {
  display: grid;
  gap: 8px;
  padding-bottom: 34px;
}

.annual-year-group > strong {
  color: var(--brand-dark);
  font-size: 15px;
}

.annual-month-bars {
  border-left: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: repeat(12, minmax(54px, 1fr));
  gap: 8px;
  height: var(--chart-height);
  padding: 0 8px;
  overflow: visible;
}

.annual-month {
  position: relative;
  display: block;
  min-width: 0;
}

.annual-bar {
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  align-items: center;
  background: linear-gradient(180deg, #1d4ed8, var(--brand));
  border-radius: 6px 6px 2px 2px;
  display: flex;
  justify-content: center;
  height: var(--bar-height);
  min-height: 0;
  width: 44px;
}

.annual-bar span {
  color: #fff;
  font-size: 12px;
  font-weight: 950;
  line-height: 1;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.28);
  text-align: center;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
}

.annual-month small {
  position: absolute;
  left: 50%;
  top: calc(100% + 7px);
  transform: translateX(-50%);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.bar-column span {
  position: absolute;
  top: calc(100% + 8px);
  min-height: 32px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-align: center;
}

.average-line {
  position: absolute;
  left: 0;
  right: 0;
  bottom: var(--avg);
  border-top: 2px dashed #ff2800;
  z-index: 4;
}

.average-line.current {
  border-top-color: #102434;
}

.average-line span {
  background: #fff;
  color: var(--ink);
  font-size: 11px;
  font-weight: 900;
  padding: 2px 6px;
}

.vendor-region-table {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.vendor-region-table h4 {
  margin: 0;
  background: #102434;
  color: #fff;
  padding: 12px 14px;
}

.vendor-region-table table {
  min-width: 1120px;
}

.vendor-region-table tfoot td {
  background: #eef3ff;
  color: var(--brand-dark);
  font-weight: 950;
}

.vendor-region-table .region-average-row td {
  background: rgba(11, 47, 138, 0.08);
  color: var(--brand-dark);
  font-weight: 900;
}

.vendor-region-table .trend-cell {
  background: #102434;
  color: #fff;
  font-weight: 950;
}

.activity-active,
.activity-inactive {
  align-items: center;
  color: #fff;
  display: flex;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  font-weight: 950;
  justify-content: center;
  min-width: 0;
  overflow: hidden;
  padding: 0 4px;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.35);
  transition: width 0.18s ease;
  white-space: nowrap;
}

.activity-active span,
.activity-inactive span {
  overflow: hidden;
  text-overflow: clip;
}

.activity-active {
  width: var(--active-width);
  background: #008f39;
}

.activity-active.has-value {
  min-width: 42px;
}

.activity-inactive {
  width: var(--inactive-width);
  background: #ff2800;
}

.table-tools {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  align-items: end;
}

.prospect-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.07);
  display: grid;
  grid-template-columns: repeat(5, minmax(150px, 1fr));
  gap: 14px;
  padding: 20px;
}

.prospect-client-field {
  position: relative;
  grid-column: span 2;
}

.blocked-client-field {
  position: relative;
}

.prospect-actions {
  align-self: end;
}

.prospect-suggestions {
  position: absolute;
  z-index: 6;
  left: 0;
  right: 0;
  top: calc(100% + 4px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
  display: none;
  max-height: 260px;
  overflow: auto;
}

.prospect-suggestions.visible {
  display: block;
}

.prospect-suggestion {
  border: 0;
  border-bottom: 1px solid #eef2f6;
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  display: grid;
  gap: 3px;
  padding: 10px 12px;
  text-align: left;
  width: 100%;
}

.prospect-suggestion:hover {
  background: rgba(9, 95, 115, 0.06);
}

.prospect-suggestion strong {
  font-size: 13px;
}

.prospect-suggestion span {
  color: var(--muted);
  font-size: 12px;
}

.prospect-summary {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  margin: 16px 0;
}

.prospect-summary article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.07);
  padding: 16px;
}

.prospect-summary span {
  color: var(--muted);
  display: block;
  font-size: 13px;
  font-weight: 800;
}

.prospect-summary strong {
  color: var(--ink);
  display: block;
  font-size: 26px;
  margin-top: 4px;
}

.prospect-results table {
  min-width: 980px;
}

.vendor-register-shell,
.vendor-list-page,
.vendor-editor-page {
  display: grid;
  gap: 18px;
}

.vendor-editor-page {
  display: none;
}

.vendor-register-shell.editing .vendor-list-page {
  display: none;
}

.vendor-register-shell.editing .vendor-editor-page {
  display: grid;
}

.vendor-list-hero,
.vendor-editor-hero {
  align-items: end;
  border: 1px solid rgba(0, 112, 134, 0.18);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(234, 240, 255, 0.9));
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  padding: 18px;
}

.vendor-list-hero h2,
.vendor-editor-hero h2 {
  margin-bottom: 4px;
}

.vendor-editor-side {
  align-items: end;
  display: grid;
  gap: 10px;
  justify-items: end;
}

.vendor-uf-summary {
  border: 1px solid rgba(0, 112, 134, 0.24);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
  display: grid;
  gap: 4px;
  min-width: 220px;
  padding: 10px 12px;
  text-align: right;
}

.vendor-uf-summary span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.vendor-uf-summary strong {
  color: var(--brand);
  font-size: 16px;
  line-height: 1.35;
}

.vendor-page-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.vendor-page-tab {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  color: #42526b;
  cursor: pointer;
  font-weight: 900;
  padding: 0 16px;
}

.vendor-page-tab.active,
.vendor-page-tab:hover {
  border-color: var(--brand);
  background: var(--brand);
  color: #fff;
}

.vendor-status-tabs {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7fbfd;
  display: inline-flex;
  gap: 6px;
  padding: 5px;
}

.vendor-status-tabs button {
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--brand-dark);
  cursor: pointer;
  font-size: 14px;
  font-weight: 900;
  min-width: 110px;
  padding: 10px 16px;
}

.vendor-status-tabs button.active,
.vendor-status-tabs button:hover {
  background: var(--brand);
  color: #fff;
}

.vendor-section-panel {
  display: none;
}

.vendor-section-panel.active {
  display: block;
}

.vendor-region-register-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.vendor-region-register-summary div {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 10px 24px rgba(23, 32, 51, 0.06);
  display: grid;
  gap: 6px;
  min-height: 82px;
  padding: 14px;
}

.vendor-region-register-summary span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.vendor-region-register-summary strong {
  color: var(--text);
  font-size: 28px;
  font-weight: 950;
}

.vendor-regions-client-table {
  min-width: 980px;
}

.vendor-region-manager {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 10px 24px rgba(23, 32, 51, 0.06);
  display: grid;
  gap: 14px;
  margin-bottom: 14px;
  padding: 16px;
}

.vendor-region-manager-head {
  align-items: center;
  display: flex;
  justify-content: space-between;
  gap: 14px;
}

.vendor-region-manager-head h3 {
  margin: 4px 0;
}

.vendor-region-manager-grid {
  display: grid;
  grid-template-columns: 220px minmax(0, 0.75fr) minmax(0, 1.25fr);
  gap: 14px;
}

.vendor-region-manager-grid > label {
  display: grid;
  gap: 7px;
  align-self: start;
}

.vendor-region-manager-grid > div {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.vendor-region-manager .compact-assignment-list {
  max-height: 300px;
}

.block-layout {
  display: grid;
  grid-template-columns: 380px minmax(0, 1fr);
  gap: 18px;
}

.region-layout {
  align-items: start;
  display: grid;
  grid-template-columns: minmax(320px, 0.9fr) minmax(360px, 1.1fr);
  gap: 18px;
}

.region-hierarchy-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.07);
  overflow: hidden;
}

.region-hierarchy-header {
  align-items: center;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 20px 22px;
}

.region-hierarchy-header h3 {
  margin: 4px 0;
}

.region-hierarchy-table {
  display: grid;
}

.region-tree-head,
.region-tree-row {
  display: grid;
  grid-template-columns: 44px minmax(260px, 1.6fr) minmax(130px, 0.6fr) minmax(260px, 1fr);
  gap: 12px;
  align-items: center;
}

.region-tree-head {
  background: #f4f8fb;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  font-size: 12px;
  font-weight: 950;
  padding: 12px 18px 12px 74px;
  text-transform: uppercase;
}

.region-tree-head span:first-child {
  grid-column: 1 / span 2;
}

.region-tree-row {
  border-bottom: 1px solid var(--line);
  min-height: 54px;
  padding: 9px 18px;
}

.region-tree-uf-row {
  background: #ffffff;
}

.region-tree-city-row {
  background: rgba(245, 248, 251, 0.78);
  padding-left: 46px;
}

.region-tree-ddd-row {
  background: rgba(255, 255, 255, 0.72);
  padding-left: 82px;
}

.region-tree-client-row {
  background: rgba(248, 250, 252, 0.92);
  padding-left: 118px;
}

.region-tree-client-row strong {
  font-size: 13px;
}

.region-tree-row strong {
  color: var(--text);
  font-size: 14px;
  font-weight: 900;
}

.region-tree-row span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.region-expand-button {
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--brand);
  cursor: pointer;
  display: inline-flex;
  font-size: 18px;
  font-weight: 950;
  height: 34px;
  justify-content: center;
  width: 34px;
}

.region-owner-select {
  min-height: 38px;
  width: 100%;
}

.region-tree-children {
  display: grid;
}

.region-builder {
  display: contents;
}

.region-card,
.region-saved-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.07);
}

.region-card {
  align-self: start;
  display: grid;
  gap: 13px;
  padding: 18px;
}

.region-step-card label,
.selected-region-panel label {
  display: grid;
  gap: 7px;
}

.region-step-label {
  color: var(--brand-dark);
  font-size: 13px;
  font-weight: 950;
  letter-spacing: 0;
  text-transform: uppercase;
}

.region-help-text {
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
  padding-top: 12px;
}

.region-saved-panel {
  grid-column: 1 / -1;
  overflow: hidden;
}

.region-saved-header {
  align-items: center;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  gap: 22px;
  padding: 22px 24px;
}

.region-saved-header h3 {
  margin: 4px 0;
}

.region-saved-summary {
  border-bottom: 1px solid var(--line);
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  padding: 18px 24px;
}

.region-split-manager {
  border-bottom: 1px solid var(--line);
  display: grid;
  gap: 14px;
  padding: 18px 24px;
}

.region-split-header {
  align-items: center;
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

.region-split-header h3 {
  margin: 4px 0;
}

.region-split-grid {
  display: grid;
  grid-template-columns: 220px minmax(0, 0.8fr) minmax(0, 1.3fr);
  gap: 14px;
}

.region-split-grid > label,
.region-split-grid > div {
  display: grid;
  gap: 8px;
  align-self: start;
  min-width: 0;
}

.region-split-manager .compact-assignment-list {
  max-height: 320px;
}

.region-summary-group {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(245, 248, 251, 0.9);
  display: grid;
  gap: 12px;
  min-height: 132px;
  padding: 16px;
}

.region-summary-group-head {
  align-items: center;
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.region-summary-group-head strong {
  color: var(--text);
  font-size: 15px;
  font-weight: 950;
}

.region-summary-group-head span {
  border-radius: 999px;
  background: var(--brand);
  color: #fff;
  font-size: 14px;
  font-weight: 950;
  min-width: 34px;
  padding: 5px 10px;
  text-align: center;
}

.region-summary-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  max-height: 190px;
  overflow: auto;
}

.region-summary-list span,
.region-summary-list em {
  border: 1px solid rgba(12, 111, 128, 0.2);
  border-radius: 999px;
  background: #fff;
  color: #344054;
  font-size: 13px;
  font-style: normal;
  font-weight: 850;
  padding: 7px 10px;
}

.regions-table {
  min-width: 980px;
}

.selected-region-panel {
  min-height: 360px;
}

.selected-region-panel span {
  color: var(--text);
  display: block;
  font-weight: 950;
}

.selected-region-panel small {
  color: var(--muted);
  font-weight: 750;
}

.assignment-pill {
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  padding: 9px 10px;
}

.assignment-pill strong {
  display: block;
  font-size: 13px;
}

.assignment-pill span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.empty-state {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.block-forms {
  align-self: start;
  display: grid;
  gap: 14px;
}

.vendor-form {
  align-self: start;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.07);
  display: grid;
  gap: 14px;
  padding: 22px;
}

.checkbox-row {
  align-items: center;
  display: flex;
  gap: 10px;
  min-height: 42px;
}

.checkbox-row input {
  width: 18px;
  height: 18px;
}

.checkbox-row span {
  color: #24324d;
  font-weight: 800;
}

#vendor-main-panel.visible {
  grid-template-columns: 220px repeat(2, minmax(0, 1fr));
}

#vendor-main-panel .vendor-photo-preview,
#vendor-main-panel label:first-child {
  grid-column: 1;
}

#vendor-main-panel .vendor-access {
  grid-column: 1 / -1;
}

#vendor-clients-panel.visible {
  grid-template-columns: 1fr;
  align-items: start;
}

#vendor-clients-panel .vendor-access,
#vendor-clients-panel .blocked-client-field,
#vendor-clients-panel > .secondary-action,
#vendor-clients-panel > .assignment-list,
#vendor-clients-panel > .vendor-actions {
  min-width: 0;
}

#vendor-clients-panel .vendor-client-workbench,
#vendor-clients-panel .vendor-availability-panel,
#vendor-clients-panel .blocked-client-field,
#vendor-clients-panel #vendor-add-specific-client,
#vendor-clients-panel #vendor-specific-client-list {
  grid-column: 1 / -1;
}

.vendor-client-workbench {
  display: grid;
  grid-template-columns: minmax(220px, 0.55fr) minmax(340px, 1fr) minmax(340px, 1fr);
  gap: 12px;
  align-items: start;
}

.vendor-panel-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  display: grid;
  gap: 10px;
  min-width: 0;
  padding: 12px;
}

.vendor-panel-card > span,
.vendor-panel-card label {
  color: #344054;
  font-weight: 850;
}

.vendor-current-cities-card {
  grid-row: span 2;
}

.vendor-add-cities-card {
  grid-row: span 2;
}

.vendor-excluded-cities-card {
  border-color: rgba(11, 47, 138, 0.22);
  background: rgba(11, 47, 138, 0.06);
}

.vendor-excluded-cities-card small {
  color: var(--muted);
  font-weight: 750;
}

.vendor-panel-card select[multiple] {
  min-height: 180px;
}

.vendor-form-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.vendor-form-tab {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: #42526b;
  cursor: pointer;
  font-weight: 850;
  padding: 0 12px;
}

.vendor-form-tab.active,
.vendor-form-tab:hover {
  border-color: var(--brand);
  background: var(--brand);
  color: #fff;
}

#vendors-view .vendor-form-tab[data-vendor-tab="vendor-clients"],
#vendors-view .vendor-uf-summary,
#vendor-clients-panel {
  display: none !important;
}

.vendor-tab-panel {
  display: none;
  gap: 14px;
}

.vendor-tab-panel.visible {
  display: grid;
}

.vendor-form.locked {
  opacity: 0.72;
}

.permission-note {
  border: 1px solid rgba(11, 47, 138, 0.24);
  border-radius: 8px;
  background: rgba(11, 47, 138, 0.08);
  color: var(--brand-dark);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.35;
  padding: 10px 12px;
}

.vendor-access {
  display: grid;
  gap: 10px;
  color: #344054;
  font-weight: 750;
}

.vendor-access > span {
  line-height: 1.35;
}

#vendor-access-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.vendor-uf-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  max-height: 220px;
  overflow: auto;
  padding-right: 4px;
}

.vendor-ddd-box {
  display: none;
  gap: 8px;
}

.vendor-ddd-box.visible {
  display: grid;
}

.compact-table-heading {
  align-items: end;
  gap: 14px;
  grid-template-columns: minmax(0, 1fr) 180px;
  margin-bottom: 10px;
}

.vendor-availability-panel {
  border-color: rgba(0, 112, 134, 0.22);
}

.vendor-city-manager {
  border: 1px solid rgba(0, 112, 134, 0.18);
  border-radius: 8px;
  background: rgba(248, 251, 253, 0.92);
  display: grid;
  gap: 10px;
  padding: 12px;
}

.vendor-city-manager > div:first-child {
  align-items: baseline;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: space-between;
}

.vendor-city-manager span {
  color: #344054;
  font-size: 13px;
  font-weight: 900;
}

.vendor-city-manager small {
  color: var(--muted);
  font-weight: 750;
}

.vendor-city-list {
  max-height: 260px;
  overflow: auto;
  padding-right: 4px;
}

.compact-assignment-list {
  max-height: 190px;
  overflow: auto;
  padding-right: 4px;
}

.assignment-list {
  display: grid;
  gap: 8px;
}

.assignment-item {
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  min-height: 42px;
  padding: 8px 10px;
}

.assignment-item.selectable {
  grid-template-columns: auto minmax(0, 1fr);
}

.assignment-item.pending {
  border-color: rgba(255, 40, 0, 0.35);
  background: rgba(255, 40, 0, 0.05);
}

.assignment-item.available {
  border-color: rgba(0, 112, 134, 0.28);
  background: rgba(0, 112, 134, 0.04);
}

.assignment-item strong {
  display: block;
  font-size: 13px;
}

.assignment-item span {
  color: var(--muted);
  font-size: 12px;
}

.assignment-item button {
  min-height: 30px;
}

.check-option {
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  display: flex;
  gap: 8px;
  min-height: 38px;
  padding: 8px 10px;
}

.check-option input {
  width: 16px;
  height: 16px;
}

.check-option span {
  font-size: 13px;
}

.check-option.uf-assigned span {
  color: #ff2800;
  font-weight: 950;
}

.check-option.uf-assigned {
  border-color: rgba(255, 40, 0, 0.45);
  background: rgba(255, 40, 0, 0.06);
}

.check-option.uf-selected-current {
  border-color: rgba(23, 132, 85, 0.55);
  background: rgba(23, 132, 85, 0.08);
}

.check-option.uf-selected-current span {
  color: var(--success);
  font-weight: 950;
}

.secondary-action.danger {
  border-color: rgba(255, 40, 0, 0.35);
  color: #b42318;
}

.vendor-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.vendor-photo-preview {
  align-items: center;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #f7fafc;
  color: var(--muted);
  display: flex;
  font-size: 13px;
  font-weight: 800;
  height: 96px;
  justify-content: center;
  overflow: hidden;
}

.vendor-photo-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.vendor-photo-thumb {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #fff;
  box-shadow: 0 4px 12px rgba(23, 32, 51, 0.16);
}

.vendor-photo-empty {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.vendors-table {
  min-width: 1120px;
}

.vendor-goals-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.07);
  padding: 22px;
}

.vendor-goals-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 16px 0 18px;
}

.vendor-goals-summary article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfd;
  display: grid;
  gap: 6px;
  padding: 14px;
}

.vendor-goals-summary span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.vendor-goals-summary strong {
  color: #071b3a;
  font-size: 18px;
}

.vendor-goals-summary small {
  color: #42526b;
  font-size: 11px;
  font-weight: 850;
}

.vendor-goals-months {
  display: grid;
  gap: 16px;
}

.vendor-goal-month {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 16px;
}

.vendor-goal-month header {
  align-items: center;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.vendor-goal-month h3 {
  margin: 0;
}

.vendor-goal-month header span {
  color: var(--brand);
  font-weight: 950;
}

.vendor-goal-month-inputs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.vendor-goal-table {
  min-width: 860px;
}

.monthly-items-table {
  min-width: 1080px;
}

.vendor-goal-table input,
.vendor-goal-month-inputs input {
  min-height: 36px;
}

.vendor-goal-suggested {
  border-color: rgba(0, 111, 132, 0.45);
  background: rgba(0, 111, 132, 0.06);
  font-weight: 900;
}

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

.finance-controls,
.finance-expense-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.finance-note-entry {
  align-items: end;
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  gap: 12px;
}

.finance-detected-vendor {
  border: 1px solid #cfe0f7;
  border-radius: 8px;
  background: #f5f9ff;
  color: #143762;
  font-weight: 850;
  padding: 12px 14px;
}

.finance-notes-list {
  display: grid;
  gap: 14px;
}

.finance-note-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(23, 32, 51, 0.06);
  padding: 16px;
}

.finance-vendor-return-group {
  border: 1px solid #cfe0f7;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(23, 32, 51, 0.06);
  overflow: hidden;
}

.finance-vendor-return-group summary {
  align-items: center;
  cursor: pointer;
  display: grid;
  gap: 10px;
  grid-template-columns: auto minmax(220px, 1fr) auto auto auto;
  list-style: none;
  padding: 16px;
}

.finance-vendor-return-group summary::-webkit-details-marker {
  display: none;
}

.finance-vendor-return-group summary::before {
  content: "+";
  border-radius: 999px;
  background: #eaf2ff;
  color: #123f7a;
  display: inline-grid;
  font-weight: 950;
  height: 24px;
  place-items: center;
  width: 24px;
}

.finance-vendor-return-group[open] summary::before {
  content: "-";
}

.finance-vendor-return-group summary span {
  color: #071b3a;
  font-size: 1.05rem;
  font-weight: 950;
}

.finance-vendor-return-group summary strong,
.finance-vendor-return-group summary em {
  color: #38506d;
  font-style: normal;
  font-weight: 850;
}

.finance-vendor-return-details {
  border-top: 1px solid #d8e2f0;
  display: grid;
  gap: 14px;
  padding: 16px;
}

.finance-note-card header,
.finance-note-card footer {
  align-items: center;
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.finance-note-card header {
  margin-bottom: 12px;
}

.finance-note-card h4 {
  margin: 0 0 4px;
}

.finance-note-card header span,
.finance-note-card small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.finance-return-note {
  display: block;
  margin-bottom: 12px;
}

.finance-items-table {
  min-width: 1180px;
}

.finance-qty-input {
  max-width: 120px;
}

.finance-commission-percent-input {
  max-width: 130px;
}

.mini-action.danger {
  border-color: rgba(220, 38, 38, 0.28);
  color: #b42318;
}

.finance-expenses {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfd;
  padding: 16px;
}

.finance-expenses h4 {
  margin: 0 0 12px;
}

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

.finance-totals article {
  border: 1px solid rgba(250, 204, 21, 0.55);
  border-radius: 8px;
  background: #fff8d8;
  display: grid;
  gap: 4px;
  padding: 16px;
}

.finance-totals span {
  color: #7a4d00;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.finance-totals strong {
  color: #071b3a;
  font-size: 24px;
}

.finance-summary-table tfoot td {
  background: #071b3a;
  color: #fff;
  font-size: 1rem;
  font-weight: 900;
}

.yellow-action {
  background: #facc15 !important;
  border-color: #eab308 !important;
  color: #071b3a !important;
}

.yellow-action:hover {
  background: #eab308 !important;
}

@media (max-width: 960px) {
  .finance-controls,
  .finance-expense-grid,
  .finance-totals,
  .finance-note-entry {
    grid-template-columns: 1fr;
  }

  .finance-vendor-return-group summary {
    align-items: start;
    grid-template-columns: auto 1fr;
  }

  .finance-vendor-return-group summary strong,
  .finance-vendor-return-group summary em {
    grid-column: 2;
  }
}

.vendor-page-goals-list {
  display: grid;
  gap: 12px;
}

.vendor-page-goal-context {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(135deg, #f8fafc, #eef3ff);
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 10px 12px;
}

.vendor-page-goal-context span {
  color: #42526b;
  font-size: 12px;
  font-weight: 850;
}

#vendor-page-view .vendor-workspace-nav button {
  font-size: 30px;
  min-height: 92px;
  padding: 22px 24px;
}

#vendor-page-view .vendor-page-goal-context {
  gap: 10px;
  padding: 12px 14px;
}

#vendor-page-view .vendor-page-goal-context span {
  font-size: 14px;
  font-weight: 650;
}

.vendor-page-goal-table {
  min-width: 980px;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
  width: 100%;
}

.vendor-page-goal-table th {
  background: #f5f9fc;
  border-right: 1px solid #ffffff;
  border-bottom: 1px solid #ffffff;
  color: #42526b;
  font-size: 12px;
  text-transform: uppercase;
}

.vendor-page-goal-table th:last-child,
.vendor-page-goal-table td:last-child {
  border-right: 0;
}

#vendor-page-view .vendor-page-goal-table {
  min-width: 1040px;
}

#vendor-page-view .vendor-page-main-goal-table th:nth-child(1),
#vendor-page-view .vendor-page-main-goal-table td:nth-child(1) {
  width: 28%;
}

#vendor-page-view .vendor-page-main-goal-table th:nth-child(2),
#vendor-page-view .vendor-page-main-goal-table td:nth-child(2),
#vendor-page-view .vendor-page-main-goal-table th:nth-child(3),
#vendor-page-view .vendor-page-main-goal-table td:nth-child(3) {
  width: 13%;
}

#vendor-page-view .vendor-page-main-goal-table th:nth-child(4),
#vendor-page-view .vendor-page-main-goal-table td:nth-child(4) {
  width: 13%;
}

#vendor-page-view .vendor-page-main-goal-table th:nth-child(5),
#vendor-page-view .vendor-page-main-goal-table td:nth-child(5),
#vendor-page-view .vendor-page-main-goal-table th:nth-child(6),
#vendor-page-view .vendor-page-main-goal-table td:nth-child(6) {
  width: 8%;
}

#vendor-page-view .vendor-page-main-goal-table th:nth-child(7),
#vendor-page-view .vendor-page-main-goal-table td:nth-child(7) {
  width: 17%;
}

#vendor-page-view .vendor-page-goal-table th {
  font-size: 13px;
  font-weight: 750;
  letter-spacing: 0;
}

.vendor-page-goal-table td {
  border-right: 1px solid #ffffff;
  border-bottom: 1px solid #ffffff;
  padding: 11px 12px;
  vertical-align: middle;
}

#vendor-page-view .vendor-page-goal-table td {
  font-size: 14px;
  font-weight: 500;
  padding: 12px 14px;
}

.vendor-page-goal-table td:not(:first-child) {
  text-align: right;
  white-space: nowrap;
}

.vendor-page-goal-table strong {
  color: #071b3a;
  font-size: 14px;
}

#vendor-page-view .vendor-page-goal-table strong {
  font-size: 15px;
  font-weight: 650;
}

.goal-name-with-help {
  align-items: center;
  display: inline-flex;
  gap: 8px;
}

.goal-help-icon {
  align-items: center;
  border: 1px solid rgba(0, 112, 134, 0.32);
  border-radius: 999px;
  background: rgba(0, 112, 134, 0.08);
  color: var(--brand);
  cursor: help;
  display: inline-flex;
  font-size: 12px;
  font-weight: 950;
  height: 20px;
  justify-content: center;
  line-height: 1;
  width: 20px;
}

#vendor-page-view .goal-help-icon {
  font-size: 13px;
  height: 22px;
  width: 22px;
}

.goal-help-icon:hover,
.goal-help-icon:focus {
  border-color: var(--brand);
  background: var(--brand);
  color: #fff;
  outline: none;
}

.vendor-page-goal-table .achieved-value {
  color: var(--brand);
  font-weight: 950;
}

.vendor-goal-table .commission-value,
.vendor-page-goal-table .commission-value {
  color: #071b3a;
  font-weight: 950;
  text-align: right;
}

.vendor-page-goal-table .commission-money {
  color: #b91c1c;
  font-size: 15px;
  font-weight: 950;
  text-align: right;
  white-space: nowrap;
}

#vendor-page-view .vendor-page-goal-table .commission-money {
  font-size: 15px;
  font-weight: 800;
}

.goal-progress {
  align-items: center;
  display: grid;
  grid-template-columns: 44px minmax(48px, max-content);
  justify-content: end;
  gap: 6px;
}

#vendor-page-view .goal-progress {
  grid-template-columns: 48px minmax(54px, max-content);
  gap: 7px;
}

.goal-progress span {
  background: linear-gradient(90deg, var(--success), var(--brand));
  border-radius: 999px;
  display: block;
  height: 9px;
  min-width: 3px;
}

.goal-progress.is-red span {
  background: linear-gradient(90deg, #ef4444, #b91c1c) !important;
}

.goal-progress.is-yellow span {
  background: linear-gradient(90deg, #facc15, #eab308) !important;
}

.goal-progress.is-green span {
  background: linear-gradient(90deg, #22c55e, #15803d) !important;
}

#vendor-page-view .goal-progress span {
  height: 10px;
}

.goal-progress strong {
  color: #071b3a;
  font-size: 13px;
  line-height: 1;
  text-align: right;
}

#vendor-page-view .goal-progress strong {
  font-size: 14px;
  font-weight: 700;
}

.blocked-table {
  min-width: 900px;
}

.client-found {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7fafc;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.35;
  min-height: 46px;
  padding: 12px;
}

.client-found.found {
  border-color: rgba(23, 132, 85, 0.35);
  background: rgba(23, 132, 85, 0.08);
  color: #12633f;
}

.client-found.missing {
  border-color: rgba(255, 40, 0, 0.3);
  background: rgba(255, 40, 0, 0.07);
  color: #ab1e00;
}

.mini-action {
  min-height: 32px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--brand-dark);
  cursor: pointer;
  font-weight: 850;
  padding: 0 12px;
}

.mini-action:hover {
  border-color: var(--brand);
  color: var(--brand);
}

.status-pill {
  border-radius: 999px;
  color: #fff;
  display: inline-block;
  font-size: 12px;
  font-weight: 900;
  padding: 5px 9px;
}

.status-pill.active {
  background: #008f39;
}

.status-pill.inactive {
  background: #ff2800;
}

.status-pill.never {
  background: #5b6472;
}

.routine-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.routine-tab {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  color: #42526b;
  cursor: pointer;
  font-weight: 800;
  padding: 0 14px;
}

.routine-tab.active,
.routine-tab:hover {
  border-color: var(--brand);
  background: var(--brand);
  color: #fff;
}

.costing-internal-tabs {
  margin-top: 6px;
}

.costing-internal-panel.hidden {
  display: none;
}

.compact-heading {
  margin-top: 10px;
}

.compact-heading h3 {
  margin: 0;
  font-size: 1.35rem;
}

.routine {
  display: none;
}

.routine.visible {
  display: block;
}

.slow-items-toolbar {
  align-items: end;
  display: grid;
  grid-template-columns: minmax(180px, 260px) minmax(260px, 1fr) auto auto auto;
  gap: 14px;
  margin-bottom: 18px;
}

.slow-items-panel {
  padding: 18px;
}

.slow-items-table input {
  min-height: 36px;
  text-align: right;
}

.slow-items-percent-cell {
  min-width: 130px;
}

.slow-items-percent-cell input {
  border-color: rgba(29, 78, 216, 0.35);
  color: var(--brand);
  font-weight: 800;
}

.slow-items-missing-price {
  color: #d11a2a !important;
  font-weight: 900;
}

.stock-bonus-input {
  width: 86px;
  min-height: 34px;
  text-align: right;
  border: 1px solid rgba(29, 78, 216, 0.3);
  border-radius: 8px;
  padding: 6px 8px;
  font-weight: 700;
  color: var(--brand);
}

.ml-panel {
  display: none;
}

.ml-panel.active {
  display: grid;
  gap: 18px;
}

.ml-company-tabs,
.ml-file-tabs,
.ml-kind-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.ml-company-tabs {
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
}

.ml-kind-tabs {
  margin-top: 12px;
}

.ml-file-tabs {
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
}

.mercado-livre-table-card {
  margin-top: 6px;
}

.ml-dashboard-filters {
  align-items: end;
  grid-template-columns: repeat(3, minmax(150px, 220px)) minmax(260px, 1fr);
}

#ml-dashboard-product {
  min-width: 260px;
}

.ml-dashboard-chart-tabs {
  margin: 0 0 16px;
}

.ml-dashboard-chart {
  padding: 22px 24px 28px;
}

.ml-chart-header {
  align-items: start;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
  padding-bottom: 16px;
}

.ml-chart-header h3 {
  margin: 4px 0 6px;
}

.ml-chart-header > strong {
  color: var(--brand);
  font-size: 24px;
  white-space: nowrap;
}

.ml-column-chart {
  display: grid;
  grid-template-columns: 100px minmax(760px, 1fr);
  min-height: 430px;
  overflow-x: auto;
}

.ml-chart-scale,
.ml-chart-plot {
  height: 360px;
  position: relative;
}

.ml-chart-scale {
  border-right: 1px solid #b9c9da;
  color: #465a78;
  font-size: 13px;
  font-weight: 800;
}

.ml-chart-scale span {
  position: absolute;
  right: 12px;
  transform: translateY(-50%);
  white-space: nowrap;
}

.ml-chart-plot {
  min-width: 760px;
}

.ml-chart-plot i {
  border-top: 1px solid #d7e0ea;
  left: 0;
  position: absolute;
  right: 0;
}

.ml-chart-bars {
  align-items: end;
  bottom: 0;
  display: grid;
  gap: 12px;
  grid-auto-columns: minmax(72px, 1fr);
  grid-auto-flow: column;
  left: 0;
  min-width: max-content;
  padding: 0 10px;
  position: absolute;
  right: 0;
  top: 0;
}

.ml-chart-bar-item {
  align-items: center;
  display: grid;
  gap: 10px;
  grid-template-rows: 1fr auto;
  height: 100%;
  min-width: 72px;
}

.ml-chart-bar-wrap {
  align-items: end;
  align-self: stretch;
  display: flex;
  width: 100%;
}

.ml-chart-bar {
  align-items: center;
  background: linear-gradient(180deg, #2148c6 0%, #0f2f91 100%);
  border-radius: 7px 7px 0 0;
  display: flex;
  justify-content: center;
  min-height: 2px;
  width: 100%;
}

.ml-chart-bar span {
  color: #fff;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.1;
  padding: 6px 2px;
  text-align: center;
  transform: rotate(-90deg);
  white-space: nowrap;
}

.ml-chart-bar-item strong {
  color: #263a5d;
  font-size: 10px;
  line-height: 1.15;
  min-height: 24px;
  overflow-wrap: anywhere;
  text-align: center;
  white-space: normal;
}

.vendor-page-goal-table .muted-cell {
  color: #94a3b8;
  font-weight: 700;
  text-align: center;
}

.commission-memory-button {
  position: relative;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font: inherit;
  font-weight: 950;
  padding: 5px 8px;
  text-align: right;
}

.commission-memory-button:hover,
.commission-memory-button:focus {
  background: #fff8d8;
  box-shadow: inset 0 0 0 1px rgba(245, 180, 0, 0.45);
  color: #7c2d12;
  outline: none;
}

.commission-memory-button::after {
  content: "Clique para ver memória de cálculo!";
  position: absolute;
  right: 0;
  bottom: calc(100% + 8px);
  z-index: 35;
  width: 230px;
  border: 1px solid #f5c542;
  border-radius: 8px;
  background: #fff8d8;
  box-shadow: 0 14px 28px rgba(113, 63, 18, 0.16);
  color: #713f12;
  font-size: 12px;
  font-weight: 850;
  line-height: 1.35;
  opacity: 0;
  padding: 9px 10px;
  pointer-events: none;
  text-align: left;
  transform: translateY(4px);
  transition: opacity 0.15s ease, transform 0.15s ease;
  white-space: normal;
}

.commission-memory-button:hover::after,
.commission-memory-button:focus::after {
  opacity: 1;
  transform: translateY(0);
}

.ml-pfpj-chart {
  align-items: end;
  display: grid;
  gap: 14px;
  grid-auto-columns: minmax(72px, 1fr);
  grid-auto-flow: column;
  min-height: 360px;
  overflow-x: auto;
  padding: 18px 10px 8px;
}

.ml-pfpj-group {
  align-items: center;
  display: grid;
  gap: 10px;
  grid-template-rows: 1fr auto;
  height: 340px;
  min-width: 72px;
}

.ml-pfpj-bars {
  align-items: end;
  display: flex;
  gap: 0;
  height: 100%;
  justify-content: center;
  width: 100%;
}

.ml-pfpj-bar {
  align-items: start;
  border-radius: 7px 7px 0 0;
  display: flex;
  justify-content: center;
  min-height: 2px;
  padding-top: 6px;
  width: 32px;
}

.ml-pfpj-bar span {
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  writing-mode: vertical-rl;
}

.ml-pfpj-group strong {
  color: #263a5d;
  font-size: 13px;
  text-align: center;
  white-space: nowrap;
}

.ml-pfpj-pj {
  background: linear-gradient(180deg, #2148c6, #0f2f91);
}

.ml-pfpj-pf {
  background: linear-gradient(180deg, #0f9f8f, #08756b);
}

.ml-chart-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-top: 14px;
}

.ml-chart-legend span {
  align-items: center;
  color: #42526b;
  display: inline-flex;
  font-size: 13px;
  font-weight: 850;
  gap: 6px;
}

.ml-chart-legend i {
  border-radius: 4px;
  display: inline-block;
  height: 12px;
  width: 18px;
}

.ml-summary-inactive-row td {
  background: #fff7cc !important;
}

.workflow {
  display: grid;
  grid-template-columns: minmax(320px, 460px) minmax(0, 1fr);
  gap: 18px;
}

.import-panel,
.result-panel {
  padding: 24px;
}

.import-panel {
  display: grid;
  gap: 18px;
}

.export-filter-box {
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 12px;
  padding: 14px;
}

label {
  display: grid;
  gap: 8px;
  color: #344054;
  font-weight: 750;
}

select,
input[type="file"],
input[type="search"],
input[type="text"],
input[type="tel"],
input[type="email"],
input[type="password"] {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  padding: 10px 12px;
}

select[multiple] {
  min-height: 220px;
}

select option.city-option-added {
  color: #ff2800;
  font-weight: 900;
}

.table-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.07);
  overflow: hidden;
}

.stock-summary-grid {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(280px, 1.4fr);
  gap: 14px;
  margin-bottom: 16px;
}

.stock-bonus-default-panel {
  align-items: end;
  border: 1px solid rgba(250, 204, 21, 0.5);
  border-radius: 10px;
  background: linear-gradient(135deg, #fffdf2, #f8fbff);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(260px, 1fr) repeat(3, minmax(130px, 170px)) auto;
  margin-bottom: 16px;
  padding: 14px;
}

.stock-bonus-default-panel strong {
  color: #071b3a;
  display: block;
  font-size: 16px;
  margin-top: 2px;
}

.stock-bonus-default-panel span {
  color: #526178;
  display: block;
  font-size: 13px;
  line-height: 1.35;
  margin-top: 4px;
}

.stock-bonus-default-panel label {
  color: #26344f;
  display: grid;
  font-size: 12px;
  font-weight: 850;
  gap: 6px;
}

.stock-bonus-default-panel input {
  min-height: 42px;
}

@media (max-width: 1100px) {
  .stock-bonus-default-panel {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.stock-summary-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.07);
  padding: 18px;
}

.stock-summary-grid span {
  color: var(--muted);
  display: block;
  font-size: 13px;
  font-weight: 800;
}

.stock-summary-grid small {
  color: var(--muted);
  display: block;
  font-size: 13px;
  font-weight: 800;
  margin-top: 8px;
}

.stock-summary-grid strong {
  color: var(--brand-dark);
  display: block;
  font-size: 30px;
  margin-top: 6px;
}

.stock-summary-grid .stock-value-card strong {
  color: #d00000;
  font-size: 38px;
  font-weight: 950;
}

.users-layout {
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(360px, 0.9fr) minmax(520px, 1.25fr);
}

.users-list-panel {
  min-height: 520px;
}

.user-editor-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.07);
  padding: 22px;
}

.user-permissions {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
}

.permission-group {
  border-top: 1px solid #e8eef5;
  display: grid;
  gap: 10px;
  padding: 16px 0;
}

.permission-group:first-child {
  border-top: 0;
}

.permission-group h4 {
  color: var(--brand-dark);
  margin: 0;
}

.permission-row {
  align-items: center;
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(220px, 1fr) minmax(170px, 220px);
}

.permission-row span {
  color: #24324d;
  font-weight: 800;
}

.user-company-access-panel {
  border: 1px solid #d6e3f5;
  border-radius: 8px;
  display: grid;
  gap: 10px;
  grid-column: 1 / -1;
  padding: 14px;
}

.permission-group-title {
  color: var(--brand-dark);
  font-weight: 950;
}

.company-access-options {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}

.company-access-option {
  background: #f8fbff;
  border: 1px solid #dce7f7;
  border-radius: 8px;
  padding: 8px 10px;
}

.vendor-goal-subtotal-row td {
  background: #eaf0ff !important;
  border-top: 2px solid var(--brand);
  color: var(--brand-dark);
  font-weight: 900;
}

.vendor-goal-total-row td {
  background: #071b3a !important;
  border-top: 2px solid #facc15;
  color: #fff !important;
  font-size: 18px !important;
  font-weight: 950 !important;
  letter-spacing: 0;
}

.vendor-goal-total-row .commission-money {
  color: #fff !important;
  font-size: 20px !important;
  font-weight: 950 !important;
}

.vendor-page-bonus-section {
  border: 1px solid rgba(250, 204, 21, 0.45);
  border-radius: 10px;
  background: linear-gradient(180deg, #fffdf2, #ffffff);
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.08);
  margin-top: 18px;
  overflow: hidden;
}

.vendor-page-bonus-header {
  align-items: center;
  background: #fff8d8;
  border-bottom: 1px solid rgba(250, 204, 21, 0.55);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
}

.vendor-page-bonus-header span {
  color: #806000;
  display: block;
  font-size: 18px;
  font-weight: 900;
  text-transform: uppercase;
}

.vendor-page-goals-section {
  margin-top: 0;
}

.vendor-page-goals-section-header {
  background: linear-gradient(180deg, #eef5ff, #ffffff);
  border-bottom-color: #cfe0f7;
}

.vendor-page-goals-section-header span {
  color: #0b3b83;
}

.vendor-page-main-goal-table th {
  background: #eef5ff;
  color: #143762;
}

.vendor-page-bonus-header strong {
  color: #071b3a;
  display: block;
  font-size: 20px;
  margin-top: 4px;
}

.vendor-page-bonus-header article {
  border: 1px solid rgba(250, 204, 21, 0.55);
  border-radius: 8px;
  background: #fff;
  min-width: 190px;
  padding: 10px 14px;
  text-align: right;
}

.vendor-page-bonus-table th {
  background: #fff8d8;
  color: #6f5200;
}

.vendor-page-consumer-final-table {
  min-width: 980px;
}

.vendor-page-consumer-final-table th {
  background: #fff8d8;
  color: #6f5200;
}

.vendor-consumer-company-row td {
  background: #f8fafc;
  color: #071b3a;
  text-align: left !important;
}

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

.vendor-sac-grid article {
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  padding: 12px;
}

.vendor-sac-grid h4 {
  margin: 0 0 10px;
  color: var(--text);
  font-size: 1rem;
}

.vendor-sac-table th,
.vendor-sac-table td {
  font-size: 0.92rem;
}

.vendor-page-summary-header {
  background: #f8fbff;
  border-bottom-color: #cfe0f7;
}

.vendor-page-summary-header span {
  color: #071b3a;
  font-size: 20px;
}

.vendor-month-summary-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  padding: 16px;
}

.vendor-month-summary-grid article {
  border: 1px solid #d8e2f0;
  border-radius: 10px;
  background: #ffffff;
  display: grid;
  gap: 8px;
  padding: 14px;
}

.vendor-month-summary-grid span {
  color: #53657d;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.vendor-month-summary-grid strong {
  color: #071b3a;
  font-size: 1.25rem;
  font-weight: 950;
}

.vendor-month-summary-grid .is-deduction {
  border-color: rgba(220, 38, 38, 0.35);
  background: #fff5f5;
}

.vendor-month-summary-grid .is-deduction span,
.vendor-month-summary-grid .is-deduction strong {
  color: #dc2626;
}

.vendor-month-summary-grid .is-total {
  border-color: #071b3a;
  background: #071b3a;
}

.vendor-month-summary-grid .is-total span,
.vendor-month-summary-grid .is-total strong {
  color: #ffffff;
}

@media (max-width: 820px) {
  .vendor-sac-grid {
    grid-template-columns: 1fr;
  }

  .vendor-month-summary-grid {
    grid-template-columns: 1fr;
  }
}

.vendor-goal-bonus-heading {
  align-items: center;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 18px;
}

.vendor-goal-bonus-heading .vendor-goal-bonus-title {
  margin: 0;
}

.vendor-goal-text-input {
  min-width: 170px;
}

.vendor-goals-actions {
  align-items: end;
  display: flex;
  gap: 10px;
}

#vendor-page-goals-print {
  background: linear-gradient(135deg, #ffd84d, #f5b400) !important;
  border-color: #e3a900 !important;
  color: #111827 !important;
  font-weight: 950;
}

#vendor-page-goals-print:hover {
  background: linear-gradient(135deg, #facc15, #eab308) !important;
  box-shadow: 0 12px 24px rgba(245, 180, 0, 0.24);
}

.vendor-print-cover,
.vendor-print-signature,
.vendor-print-section-header,
.vendor-print-page-number {
  display: none;
}

.compact-action {
  min-height: 36px;
  padding: 0 12px;
}

.table-status {
  min-height: 44px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  display: flex;
  align-items: center;
  padding: 0 16px;
  font-weight: 700;
}

.vendor-link-warning {
  align-items: flex-start;
  background: #fff1f2;
  border: 1px solid rgba(190, 18, 60, 0.32);
  border-radius: 8px;
  color: #9f1239;
  display: grid;
  gap: 6px;
  padding: 14px 16px;
}

.vendor-link-warning p {
  margin: 0;
}

.table-scroll {
  max-height: 62vh;
  overflow: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1120px;
}

th,
td {
  border-bottom: 1px solid #e8eef5;
  padding: 11px 12px;
  text-align: left;
  vertical-align: top;
}

th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f7fafc;
  color: #344054;
  font-size: 13px;
}

.table-sort-button {
  width: 100%;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 4px;
  padding: 0;
  text-align: left;
  font: inherit;
  font-weight: 800;
}

.table-sort-button:hover,
.table-sort-button.active {
  color: var(--brand);
}

.table-sort-button span {
  color: var(--brand);
  font-weight: 900;
}

td {
  color: #344054;
  font-size: 13px;
}

.costing-value-cell {
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.costing-index-cell {
  color: #d00000;
  font-size: 15px;
  font-weight: 900;
}

.stock-total-cell {
  color: #d00000;
  font-size: 15px;
  font-weight: 900;
}

tbody tr:hover {
  background: rgba(9, 95, 115, 0.05);
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.result-item {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
}

.result-item span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.result-item strong {
  display: block;
  margin-top: 4px;
  color: var(--success);
  font-size: 24px;
}

@media (max-width: 900px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
  }

  .topbar,
  .hero,
  .vendor-list-hero,
  .vendor-editor-hero,
  .workflow,
  .table-heading,
  .dashboard-heading {
    display: grid;
  }

  .hero-actions {
    justify-content: flex-start;
  }

  .topbar-actions,
  .company-strip {
    justify-content: flex-start;
  }

  .stats-grid,
  .workflow,
  .table-tools,
  .dashboard-chart-menu,
  .dashboard-grid,
  .vendor-region-summary,
  .vendor-workspace-nav,
  .compact-table-heading,
  .vendor-client-filters,
  .vendor-client-summary,
  .vendor-region-register-summary,
  .vendor-goals-summary,
  .vendor-page-goal-context,
  .prospect-panel,
  .prospect-summary,
  .vendor-layout,
  .region-layout,
  .block-layout {
    grid-template-columns: 1fr;
  }

  .vendor-region-manager-head,
  .vendor-region-manager-grid,
  .region-split-grid,
  .region-tree-head,
  .region-tree-row {
    grid-template-columns: 1fr;
  }

  .region-tree-head {
    padding-left: 18px;
  }

  .region-tree-city-row,
  .region-tree-ddd-row {
    padding-left: 18px;
  }

  .vendor-region-manager-head,
  .region-split-header {
    display: grid;
  }

  .region-saved-summary {
    grid-template-columns: 1fr;
  }

  #vendor-main-panel.visible,
  #vendor-clients-panel.visible {
    grid-template-columns: 1fr;
  }

  .vendor-client-workbench {
    grid-template-columns: 1fr;
  }

  .vendor-editor-side {
    justify-items: stretch;
  }

  .vendor-uf-summary {
    text-align: left;
  }

  #vendor-main-panel .vendor-photo-preview,
  #vendor-main-panel label:first-child,
  #vendor-main-panel .vendor-access,
  #vendor-clients-panel .vendor-availability-panel,
  #vendor-clients-panel .blocked-client-field,
  #vendor-clients-panel #vendor-add-specific-client,
  #vendor-clients-panel #vendor-specific-client-list {
    grid-column: auto;
  }

  .prospect-client-field {
    grid-column: auto;
  }

  .uf-row {
    grid-template-columns: 46px minmax(180px, 1fr) repeat(var(--year-count), minmax(104px, 1fr)) 124px;
  }

  .activity-row {
    grid-template-columns: 42px 70px repeat(var(--year-count), minmax(156px, 1fr));
    min-width: calc(112px + (var(--year-count) * 166px));
  }

  .activity-chart {
    overflow-x: auto;
  }
}

/* Royal blue visual refresh */
.hero,
.stat-card,
.chart-panel,
.insight-panel,
.insight-card,
.vendor-portal-panel,
.daybyday-list-card,
.daybyday-detail,
.vendor-client-summary article,
.dashboard-chart-button,
.table-panel,
.import-card,
.result-card,
.vendor-editor-shell,
.region-hierarchy-panel,
.region-card,
.region-saved-panel,
.prospect-panel,
.vendor-region-chart-block,
.vendor-region-table,
.vendor-goal-month,
.vendor-page-goal-table,
.home-vendor-card,
.vendor-region-manager,
.blocked-panel,
.stock-summary-card,
.vendor-form-panel {
  border-color: rgba(11, 47, 138, 0.16) !important;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 14px 34px rgba(17, 24, 39, 0.08);
}

.hero {
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.96), rgba(234, 240, 255, 0.88)),
    linear-gradient(135deg, var(--brand), #1d4ed8) !important;
}

.hero h2,
.section-header h2,
.chart-title-row h3,
.daybyday-shell h3,
.vendor-page-goal-table th,
.vendor-region-table h4,
.vendor-region-chart-block h4,
.table-panel h3,
.vendor-portal-panel h3,
.vendor-portal-panel h4 {
  color: var(--brand-dark) !important;
}

.eyebrow,
.dashboard-chart-button span,
.home-vendor-card span,
.vendor-client-summary span,
.insight-card span,
.stat-card span {
  color: var(--brand) !important;
}

.primary-action,
.primary,
button.primary,
.home-return-button:hover,
.dashboard-chart-button.active,
.dashboard-chart-button:hover,
.segmented-control button.active,
.segmented-control button:hover,
.vendor-workspace-nav button.active,
.vendor-workspace-nav button:hover,
.vendor-page-tab.active,
.mini-action:hover,
.table-action.primary,
.vendor-region-controls button.active,
.vendor-region-controls button:hover {
  background: linear-gradient(135deg, var(--brand), #1d4ed8) !important;
  border-color: var(--brand) !important;
  color: #ffffff !important;
  box-shadow: 0 12px 26px rgba(11, 47, 138, 0.2);
}

.secondary-action,
.secondary,
button.secondary,
.mini-action,
.dashboard-chart-button,
.segmented-control button,
.vendor-workspace-nav button,
.vendor-page-tab,
.home-return-button,
.company-pill,
.region-owner-select {
  border-color: rgba(11, 47, 138, 0.18) !important;
  background: #ffffff !important;
  color: var(--brand-dark) !important;
}

.secondary-action:hover,
.secondary:hover,
button.secondary:hover,
.mini-action:hover,
.home-return-button:hover,
.company-pill:hover {
  border-color: var(--brand) !important;
}

input,
select,
textarea {
  border-color: rgba(11, 47, 138, 0.18) !important;
  color: var(--ink);
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--brand) !important;
  box-shadow: 0 0 0 3px rgba(11, 47, 138, 0.12);
  outline: none;
}

table th,
.table-scroll thead th,
.regions-table th,
.vendor-page-goal-table th,
.vendor-clients-table th {
  background: #eef3ff !important;
  color: var(--brand-dark) !important;
  font-weight: 900;
}

table td,
.table-scroll td {
  border-color: #e5eaf3 !important;
}

tbody tr:hover,
.table-scroll tbody tr:hover {
  background: #f7f9ff !important;
}

.table-status,
.empty-state,
.client-found {
  border-color: rgba(11, 47, 138, 0.14) !important;
  background: #f8fafc !important;
  color: #475467 !important;
}

.dashboard-bar-fill,
.sales-bar-fill,
.monthly-bar-fill,
.annual-bar-fill {
  background: linear-gradient(180deg, #1d4ed8, var(--brand)) !important;
}

.dashboard-bar-fill.color-1,
.dashboard-bar-fill.color-2,
.dashboard-bar-fill.color-3,
.dashboard-bar-fill.color-4,
.dashboard-bar-fill.color-5,
.dashboard-bar-fill.color-6 {
  background: linear-gradient(180deg, #1d4ed8, var(--brand)) !important;
}

.vendor-page-hero {
  background:
    linear-gradient(135deg, rgba(7, 27, 58, 0.97), rgba(11, 47, 138, 0.94)),
    var(--brand-dark) !important;
}

.vendor-page-hero .eyebrow,
.vendor-page-hero span {
  color: #c7d7ff !important;
}

.vendor-workspace-nav {
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(11, 47, 138, 0.12);
  border-radius: 8px;
  padding: 10px;
}

.daybyday-list-head strong,
.region-summary-badge,
.vendor-region-register-summary strong {
  background: var(--brand) !important;
  color: #fff !important;
}

.daybyday-client-card:hover,
.home-vendor-card:hover,
.stat-card:hover,
.dashboard-chart-button:hover {
  border-color: rgba(11, 47, 138, 0.32) !important;
  box-shadow: 0 18px 42px rgba(11, 47, 138, 0.14);
}

.daybyday-year-counts button {
  background: #eef3ff !important;
  border-color: rgba(11, 47, 138, 0.18) !important;
}

.daybyday-year-counts button:hover {
  background: #dfe8ff !important;
  border-color: var(--brand) !important;
}

.daybyday-year-counts strong,
.daybyday-items-list strong,
.commission-money,
.achieved-value {
  color: var(--brand) !important;
}

.goal-progress span,
.stock-value-bar,
.vendor-goal-progress span {
  background: linear-gradient(90deg, var(--brand), #1d4ed8) !important;
}

.prospect-suggestion:hover,
.prospect-suggestion:focus {
  background: #eef3ff !important;
}

.result-card strong,
.table-total,
.chart-total,
.stock-total-value,
.costing-index-value {
  color: var(--brand) !important;
}

/* Vendor panel refinement */
.vendor-shell .content {
  background: linear-gradient(180deg, #f8fafc 0%, #eef2f7 100%) !important;
  padding: 24px 28px 34px;
}

#vendor-page-view {
  max-width: 1680px;
  margin: 0 auto;
}

.vendor-shell .topbar {
  align-items: center;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(11, 47, 138, 0.12);
  border-radius: 8px;
  box-shadow: 0 12px 30px rgba(17, 24, 39, 0.06);
  margin-bottom: 16px;
  padding: 18px 20px;
}

.vendor-shell .topbar h1 {
  color: var(--brand-dark);
  font-size: 30px;
}

.vendor-portal-hero {
  background:
    linear-gradient(135deg, rgba(7, 27, 58, 0.96), rgba(11, 47, 138, 0.92)),
    var(--brand-dark) !important;
  border: 0;
  box-shadow: 0 18px 44px rgba(11, 47, 138, 0.18);
  margin-bottom: 14px;
  min-height: 136px;
  padding: 24px 28px;
}

.vendor-portal-hero h2 {
  font-size: 32px;
  line-height: 1.1;
}

.vendor-portal-hero .eyebrow,
.vendor-portal-badge span {
  color: #c7d7ff !important;
}

.vendor-portal-badge {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.24);
  min-width: 150px;
  padding: 14px 16px;
}

.vendor-workspace-nav {
  background: #ffffff;
  border: 1px solid rgba(11, 47, 138, 0.14);
  box-shadow: 0 14px 34px rgba(17, 24, 39, 0.08);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 8px;
  margin: 0 0 16px;
  padding: 8px;
}

.quote-hero {
  align-items: stretch;
  background: #0b1220;
  border-radius: 8px;
  color: #ffffff;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
  padding: 22px 24px;
}

.quote-hero h3 {
  color: #ffffff;
  font-size: 28px;
  line-height: 1.1;
  margin: 2px 0 8px;
}

.quote-hero p:not(.eyebrow) {
  color: #cbd5e1;
  margin: 0;
  max-width: 680px;
}

.quote-number-card {
  align-items: flex-end;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 190px;
  padding: 14px 18px;
  text-align: right;
}

.quote-number-card span,
.quote-summary-panel span {
  color: #64748b;
  display: block;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.quote-number-card span {
  color: #bfdbfe;
}

.quote-number-card strong {
  color: #ffffff;
  display: block;
  font-size: 26px;
  margin-top: 4px;
}

.quote-workbench {
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(360px, 1.15fr) minmax(340px, 0.85fr);
  margin-bottom: 14px;
}

.quote-panel,
.quote-items-panel,
.quote-footer {
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 8px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
}

.quote-panel {
  padding: 18px;
}

.quote-panel-heading {
  align-items: flex-start;
  display: flex;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.quote-panel-heading div {
  align-items: center;
  display: flex;
  gap: 10px;
}

.quote-panel-heading span {
  align-items: center;
  background: #dbeafe;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  color: #1d4ed8;
  display: inline-flex;
  font-size: 13px;
  font-weight: 900;
  height: 28px;
  justify-content: center;
  width: 28px;
}

.quote-panel-heading h4 {
  color: #0f172a;
  font-size: 17px;
  margin: 0;
}

.quote-panel-heading small {
  color: #64748b;
  line-height: 1.35;
  max-width: 260px;
  text-align: right;
}

.quote-panel label,
.quote-add-item-panel label {
  color: #334155;
  font-size: 12px;
  font-weight: 800;
}

.quote-panel input,
.quote-add-item-panel input {
  background: #f8fafc;
  border-color: #cbd5e1;
  color: #0f172a;
  min-height: 40px;
}

.quote-form-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(160px, 1fr));
  margin-top: 12px;
}

.quote-form-grid label:first-child,
.quote-form-grid label:nth-child(4) {
  grid-column: 1 / -1;
}

.quote-add-item-panel {
  align-items: end;
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(120px, 1fr) minmax(120px, 1fr) auto;
  margin-top: 12px;
}

.quote-add-item-panel .primary-action {
  min-height: 40px;
  padding-left: 22px;
  padding-right: 22px;
}

.quote-search-field {
  position: relative;
}

.quote-product-alert {
  background: #fff1f2;
  border: 1px solid #fecdd3;
  border-radius: 8px;
  color: #be123c;
  display: none;
  font-weight: 800;
  grid-column: 1 / -1;
  margin-top: 10px;
  padding: 10px 12px;
}

.quote-product-alert.visible {
  display: block;
}

.quote-missing-price strong,
.quote-missing-price span {
  color: #d60000;
}

.quote-items-table th,
.quote-items-table td {
  font-size: 12px;
  vertical-align: top;
}

.quote-items-panel {
  overflow: hidden;
  padding: 16px;
}

.quote-items-panel .table-scroll {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  margin: 0;
}

.quote-items-table {
  border-collapse: separate;
  border-spacing: 0;
}

.quote-items-table thead th {
  background: #f1f5f9;
  color: #475569;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  white-space: nowrap;
}

.quote-items-table tbody td {
  border-bottom: 1px solid #e2e8f0;
  color: #1e293b;
}

.quote-items-table tbody tr:last-child td {
  border-bottom: 0;
}

.quote-empty-row td {
  background: #f8fafc;
  color: #64748b;
  font-size: 14px;
  padding: 26px !important;
  text-align: center;
}

.quote-line-input {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font: inherit;
  max-width: 92px;
  padding: 6px 8px;
  text-align: right;
}

.quote-items-table small {
  color: #64748b;
  display: block;
  font-size: 10px;
  margin-top: 4px;
  white-space: nowrap;
}

.quote-summary-panel {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  margin: 0;
}

.quote-summary-panel article {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 14px 16px;
}

.quote-summary-panel strong {
  color: #0f172a;
  display: block;
  font-size: 22px;
  margin-top: 6px;
}

.quote-summary-panel .quote-total-card {
  background: #0f172a;
  border-color: #0f172a;
}

.quote-summary-panel .quote-total-card span,
.quote-summary-panel .quote-total-card strong {
  color: #ffffff;
}

.quote-footer {
  align-items: center;
  display: grid;
  gap: 16px;
  grid-template-columns: minmax(360px, 1fr) auto;
  margin-top: 14px;
  padding: 16px;
}

.quote-actions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: flex-end;
  margin-top: 0;
}

#quote-status {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  color: #475569;
  margin: 12px 0 0;
  padding: 10px 12px;
}

.shortcut-chip {
  background: rgba(11, 47, 138, 0.08);
  border: 1px solid rgba(11, 47, 138, 0.18);
  border-radius: 8px;
  color: #0b2f8a;
  font-weight: 800;
  padding: 8px 12px;
}

.quick-consult-result {
  margin-top: 18px;
}

.quick-consult-card {
  background: #fff;
  border: 1px solid rgba(11, 47, 138, 0.14);
  border-radius: 8px;
  display: grid;
  gap: 18px;
  padding: 18px;
}

.quick-consult-card h3 {
  color: #0b2f8a;
  font-size: 26px;
  margin: 0 0 6px;
}

.quick-consult-metrics {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
}

.quick-consult-metrics article {
  background: rgba(11, 47, 138, 0.04);
  border: 1px solid rgba(11, 47, 138, 0.1);
  border-radius: 8px;
  padding: 14px;
}

.quick-consult-metrics span {
  color: #52627a;
  display: block;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.quick-consult-metrics strong {
  color: #061a44;
  display: block;
  font-size: 22px;
  margin-top: 6px;
}

.quick-consult-metrics .quick-consult-highlight {
  background: linear-gradient(135deg, #0b2f8a, #1f5eff);
  border-color: rgba(11, 47, 138, 0.28);
}

.quick-consult-metrics .quick-consult-highlight span,
.quick-consult-metrics .quick-consult-highlight strong {
  color: #fff;
}

.quick-consult-transit {
  border-top: 1px solid rgba(11, 47, 138, 0.12);
  padding-top: 14px;
}

.quick-consult-transit ul {
  margin: 8px 0 0;
  padding-left: 18px;
}

.text-danger {
  color: #d60000 !important;
}

@media (max-width: 900px) {
  .quote-form-grid,
  .quote-add-item-panel,
  .quote-summary-panel,
  .quick-consult-metrics {
    grid-template-columns: 1fr;
  }
}

.vendor-workspace-nav button {
  border-radius: 8px;
  box-shadow: none;
  font-size: 14px;
  min-height: 46px;
  padding: 10px 14px;
  text-align: center;
}

#vendor-page-view .vendor-workspace-nav button {
  font-size: 14px;
  min-height: 46px;
}

.vendor-portal-panel {
  border-radius: 8px;
  box-shadow: 0 16px 40px rgba(17, 24, 39, 0.08);
  padding: 20px 24px;
}

.daybyday-shell .chart-title-row {
  align-items: center;
  border-bottom: 1px solid rgba(11, 47, 138, 0.1);
  margin-bottom: 16px;
  padding-bottom: 16px;
}

.daybyday-shell h3 {
  font-size: 26px;
}

#vendor-daybyday-refresh {
  min-height: 40px;
  padding: 0 16px;
}

#vendor-daybyday-status {
  margin-top: 14px;
}

@media (max-width: 900px) {
  .vendor-shell .content {
    padding: 16px;
  }

  .vendor-portal-hero,
  .vendor-shell .topbar {
    display: grid;
  }

  .vendor-workspace-nav {
    grid-template-columns: 1fr;
  }
}

/* Day by Day - professional workbench */
#vendor-workspace-day.vendor-portal-panel {
  background: #f8fafc;
  border-color: rgba(15, 23, 42, 0.08);
  box-shadow: none;
}

.daybyday-shell {
  display: grid;
  gap: 18px;
}

.daybyday-shell > .eyebrow,
.daybyday-shell h3 {
  margin: 0;
}

.daybyday-shell h3 {
  color: #0f172a;
  font-size: 24px;
  font-weight: 850;
  letter-spacing: 0;
}

.daybyday-shell > .vendor-actions {
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 8px;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
  display: flex;
  gap: 8px;
  justify-content: flex-start;
  padding: 10px;
}

#vendor-daybyday-summary.vendor-goals-summary {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(4, minmax(180px, 1fr));
}

#vendor-daybyday-summary.vendor-goals-summary article {
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.09);
  border-radius: 8px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.045);
  min-height: 74px;
  padding: 12px 14px;
}

#vendor-daybyday-summary.vendor-goals-summary article span {
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

#vendor-daybyday-summary.vendor-goals-summary article strong {
  color: #0f172a;
  font-size: 19px;
  font-weight: 850;
  margin-top: 6px;
}

#vendor-daybyday-status.table-status {
  background: #eef6ff;
  border: 1px solid rgba(37, 99, 235, 0.14);
  border-radius: 8px;
  color: #1e3a8a;
  font-weight: 750;
  margin: 0;
  padding: 12px 14px;
}

.daybyday-lists {
  align-items: start;
  gap: 16px;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.daybyday-list-card {
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 8px;
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.07);
  padding: 16px;
}

.daybyday-list-head {
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  margin: -2px 0 12px;
  padding-bottom: 12px;
}

.daybyday-list-head h4 {
  color: #0f172a;
  font-size: 19px;
  font-weight: 850;
}

.daybyday-list-head .eyebrow {
  color: #2563eb;
  font-size: 11px;
}

.daybyday-list-head > strong {
  background: #0f172a !important;
  border-radius: 8px;
  box-shadow: none;
  color: #fff !important;
  font-size: 18px;
  height: 44px;
  width: 44px;
}

.daybyday-client-list {
  gap: 10px;
  margin-top: 0;
  max-height: 620px;
  padding-right: 8px;
}

.daybyday-client-card {
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 8px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.04);
  color: #0f172a;
  gap: 8px;
  padding: 14px;
}

.daybyday-client-card:hover {
  border-color: rgba(37, 99, 235, 0.36) !important;
  box-shadow: 0 14px 28px rgba(37, 99, 235, 0.11);
  transform: none;
}

.daybyday-client-card.saved {
  background: #f0fdf4;
  border-color: rgba(22, 163, 74, 0.26);
}

.daybyday-client-card .client-code {
  color: #64748b;
  font-size: 11px;
  letter-spacing: 0;
}

.daybyday-client-card strong {
  color: #0f172a;
  font-size: 14px;
  line-height: 1.25;
}

.daybyday-client-card span {
  color: #475569;
  font-size: 12px;
  font-weight: 650;
}

.daybyday-year-counts {
  gap: 6px;
  grid-template-columns: repeat(6, minmax(58px, 1fr));
}

.daybyday-year-counts button {
  background: #f8fafc !important;
  border-color: rgba(15, 23, 42, 0.1) !important;
  border-radius: 8px;
  min-height: 34px;
  padding: 6px 8px;
}

.daybyday-year-counts strong {
  color: #1d4ed8 !important;
  font-size: 13px;
}

.daybyday-card-actions {
  margin-top: 10px;
}

.daybyday-card-actions .mini-action {
  background: #fff;
  border-color: rgba(37, 99, 235, 0.22);
  color: #1e3a8a;
  min-height: 34px;
}

.follow-up-panel {
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 8px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
  display: grid;
  gap: 14px;
  padding: 16px;
}

.follow-up-filters {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
}

.follow-up-filters label {
  color: #475569;
  display: grid;
  font-size: 12px;
  font-weight: 800;
  gap: 5px;
}

.follow-up-filters input,
.follow-up-filters select {
  min-width: 0;
}

.follow-up-summary {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
}

.follow-up-summary article {
  background: #f8fafc;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 8px;
  padding: 12px 14px;
}

.follow-up-summary span {
  color: #64748b;
  display: block;
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.follow-up-summary strong {
  color: #0f172a;
  display: block;
  font-size: 24px;
  margin-top: 4px;
}

.follow-up-table th,
.follow-up-table td {
  vertical-align: top;
}

.follow-up-detail-row {
  display: none;
}

.follow-up-detail-row.active {
  display: table-row;
}

.follow-up-detail {
  background: #f8fafc;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 8px;
  display: grid;
  gap: 14px;
  padding: 14px;
}

.follow-up-detail h4,
.follow-up-detail p {
  margin: 0;
}

.follow-up-detail small {
  color: #64748b;
  display: block;
  font-weight: 700;
  margin-top: 8px;
}

.follow-up-answers {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
}

.follow-up-answers article {
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 8px;
  padding: 10px 12px;
}

.follow-up-answers span {
  color: #64748b;
  display: block;
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.follow-up-answers strong {
  color: #0f172a;
  display: block;
  font-size: 13px;
  line-height: 1.35;
  margin-top: 4px;
  overflow-wrap: anywhere;
}

@media (max-width: 1100px) {
  #vendor-daybyday-summary.vendor-goals-summary,
  .daybyday-lists,
  .follow-up-filters,
  .follow-up-summary,
  .follow-up-answers {
    grid-template-columns: 1fr;
  }
}

/* Day by Day - layout rebuild */
#vendor-workspace-day {
  padding: 0 !important;
}

#vendor-workspace-day .daybyday-shell {
  background: #f3f6fb;
  border-radius: 8px;
  display: grid;
  gap: 18px;
  padding: 22px;
}

#vendor-workspace-day .daybyday-shell > .eyebrow {
  color: #1d4ed8;
  font-size: 11px;
  margin: 0;
}

#vendor-workspace-day .daybyday-shell > h3 {
  color: #0f172a;
  font-size: 28px;
  line-height: 1;
  margin: -8px 0 0;
}

#vendor-workspace-day .daybyday-shell > .vendor-actions {
  align-items: center;
  background: transparent;
  border: 0;
  box-shadow: none;
  display: flex;
  gap: 8px;
  padding: 0;
}

#vendor-workspace-day .daybyday-shell > .vendor-actions button {
  background: #fff;
  min-width: 104px;
}

#vendor-workspace-day .daybyday-shell > .vendor-actions button:hover {
  background: #eef4ff;
}

#vendor-daybyday-summary.vendor-goals-summary {
  grid-template-columns: minmax(280px, 1.25fr) repeat(3, minmax(150px, 1fr));
}

#vendor-daybyday-summary .daybyday-progress-card {
  background: linear-gradient(135deg, #0f172a, #1d4ed8) !important;
  border: 0 !important;
  color: #fff;
  grid-row: span 2;
  min-height: 158px !important;
}

#vendor-daybyday-summary .daybyday-progress-card span,
#vendor-daybyday-summary .daybyday-progress-card strong,
#vendor-daybyday-summary .daybyday-progress-card small {
  color: #fff !important;
}

#vendor-daybyday-summary .daybyday-progress-card strong {
  font-size: 34px !important;
  letter-spacing: 0;
}

.daybyday-progress {
  background: rgba(255, 255, 255, 0.24);
  border-radius: 999px;
  height: 10px;
  margin: 16px 0 10px;
  overflow: hidden;
}

.daybyday-progress i {
  background: #38bdf8;
  border-radius: inherit;
  display: block;
  height: 100%;
}

#vendor-daybyday-summary.vendor-goals-summary article:not(.daybyday-progress-card) {
  min-height: 72px !important;
}

#vendor-daybyday-status {
  order: 4;
}

#vendor-daybyday-content {
  order: 5;
}

#vendor-daybyday-content .daybyday-lists {
  gap: 18px;
}

#vendor-daybyday-content .daybyday-list-card {
  padding: 0;
}

#vendor-daybyday-content .daybyday-list-head {
  background: #fff;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 8px 8px 0 0;
  margin: 0;
  padding: 18px;
}

#vendor-daybyday-content .daybyday-list-head h4 {
  font-size: 21px;
}

#vendor-daybyday-content .daybyday-list-head span {
  color: #64748b;
  display: block;
  font-size: 12px;
  font-weight: 700;
  margin-top: 4px;
}

#vendor-daybyday-content .daybyday-client-list {
  background: #f8fafc;
  max-height: 660px;
  padding: 12px;
}

#vendor-daybyday-content .daybyday-client-card {
  display: grid;
  gap: 10px;
}

.daybyday-client-main {
  display: grid;
  gap: 3px;
}

.daybyday-client-main strong {
  font-size: 15px !important;
}

.daybyday-client-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.daybyday-client-meta span {
  background: #eef4ff;
  border: 1px solid rgba(37, 99, 235, 0.12);
  border-radius: 999px;
  color: #1e3a8a !important;
  padding: 5px 9px;
}

#vendor-daybyday-content .daybyday-year-counts {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

#vendor-daybyday-content .daybyday-year-counts button {
  display: flex;
  justify-content: space-between;
}

@media (max-width: 1100px) {
  #vendor-daybyday-summary.vendor-goals-summary {
    grid-template-columns: 1fr 1fr;
  }

  #vendor-daybyday-summary .daybyday-progress-card {
    grid-column: 1 / -1;
    grid-row: auto;
  }
}

@media (max-width: 760px) {
  #vendor-daybyday-summary.vendor-goals-summary {
    grid-template-columns: 1fr;
  }
}

/* Vendor panel - modern executive layout */
.vendor-shell .content {
  background:
    radial-gradient(circle at top left, rgba(29, 78, 216, 0.08), transparent 34%),
    linear-gradient(180deg, #f8fafc 0%, #eef2f7 100%) !important;
  padding: 22px 28px 38px;
}

.vendor-shell .topbar {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.32);
  border-radius: 8px;
  box-shadow: 0 16px 42px rgba(15, 23, 42, 0.08);
  margin: 0 auto 18px;
  max-width: 1680px;
  padding: 14px 18px;
}

.vendor-shell .topbar-logo {
  background: #fff;
  border-color: rgba(148, 163, 184, 0.28);
  border-radius: 8px;
  height: 52px;
  width: 52px;
}

.vendor-shell .topbar .eyebrow {
  color: #0b2f8a;
  font-size: 11px;
  margin-bottom: 3px;
}

.vendor-shell .topbar h1 {
  color: #061a44;
  font-size: 28px;
  line-height: 1.05;
  margin: 0;
}

.vendor-shell .user-chip {
  background: #eef4ff;
  border-color: #b8c7f5;
  color: #061a44;
  min-height: 42px;
}

.vendor-shell .topbar-actions .secondary-action,
.vendor-shell .topbar-actions .home-return-button {
  background: #fff;
  border-color: rgba(148, 163, 184, 0.42);
  box-shadow: none;
  min-height: 42px;
}

#vendor-page-view.view.visible {
  display: grid;
  gap: 16px;
}

.vendor-portal-hero {
  align-items: stretch;
  background:
    linear-gradient(135deg, rgba(6, 26, 68, 0.98), rgba(11, 47, 138, 0.92) 58%, rgba(29, 78, 216, 0.86)),
    #061a44 !important;
  border-radius: 8px;
  box-shadow: 0 22px 54px rgba(11, 47, 138, 0.2);
  margin: 0;
  min-height: 154px;
  overflow: hidden;
  padding: 28px;
  position: relative;
}

.vendor-portal-hero::after {
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.14));
  content: "";
  inset: 0 0 0 auto;
  position: absolute;
  width: 38%;
}

.vendor-hero-copy {
  display: grid;
  gap: 8px;
  max-width: 860px;
  position: relative;
  z-index: 1;
}

.vendor-portal-hero h2 {
  color: #fff;
  font-size: 34px;
  letter-spacing: 0;
  margin: 0;
}

.vendor-portal-hero p:last-child,
.vendor-portal-hero #vendor-page-subtitle {
  color: #dbeafe;
  font-size: 15px;
  line-height: 1.45;
  margin: 0;
}

.vendor-hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.vendor-hero-tags span {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  color: #eff6ff;
  font-size: 12px;
  font-weight: 800;
  padding: 7px 10px;
}

.vendor-portal-badge {
  align-self: center;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14);
  min-width: 178px;
  padding: 16px 18px;
  position: relative;
  z-index: 1;
}

.vendor-portal-badge strong {
  color: #fff;
  font-size: 23px;
  letter-spacing: 0;
}

.vendor-workspace-nav {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(148, 163, 184, 0.36);
  border-radius: 8px;
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.08);
  display: flex;
  gap: 8px;
  margin: 0;
  overflow-x: auto;
  padding: 8px;
}

.vendor-workspace-nav button,
#vendor-page-view .vendor-workspace-nav button {
  background: #fff;
  border: 1px solid #d7deea;
  border-radius: 8px;
  color: #0f172a;
  flex: 0 0 auto;
  font-size: 13px;
  font-weight: 850;
  min-height: 44px;
  min-width: 146px;
  padding: 10px 14px;
}

.vendor-workspace-nav button.active {
  background: linear-gradient(135deg, #0b2f8a, #1d4ed8);
  border-color: transparent;
  box-shadow: 0 12px 28px rgba(29, 78, 216, 0.24);
  color: #fff;
}

.vendor-workspace-nav button:hover:not(.active) {
  background: #f1f5ff;
  border-color: #b8c7f5;
  box-shadow: none;
  color: #0b2f8a;
}

#vendor-workspace-day.vendor-portal-panel,
.vendor-portal-panel {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(148, 163, 184, 0.32);
  border-radius: 8px;
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.08);
}

#vendor-workspace-day .daybyday-shell {
  background: transparent;
  border-radius: 8px;
  gap: 16px;
  padding: 22px;
}

.daybyday-header {
  align-items: center;
  background: #fff;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 8px;
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 16px;
}

.daybyday-header h3,
#vendor-workspace-day .daybyday-shell > h3 {
  color: #061a44;
  font-size: 27px;
  line-height: 1.05;
  margin: 0;
}

.daybyday-header .eyebrow {
  color: #0b2f8a;
  margin-bottom: 6px;
}

#vendor-workspace-day .daybyday-shell > .eyebrow,
#vendor-workspace-day .daybyday-shell > h3,
#vendor-workspace-day .daybyday-shell > .vendor-actions {
  display: none;
}

.daybyday-header .vendor-actions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.daybyday-header .vendor-actions button,
#vendor-workspace-day .daybyday-shell > .vendor-actions button {
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  color: #0f172a;
  font-weight: 850;
  min-height: 40px;
  min-width: 104px;
}

.daybyday-header .vendor-actions button:hover {
  background: #eef4ff;
  border-color: #b8c7f5;
  color: #0b2f8a;
}

#vendor-daybyday-summary.vendor-goals-summary {
  gap: 12px;
  grid-template-columns: minmax(300px, 1.22fr) repeat(3, minmax(150px, 1fr));
}

#vendor-daybyday-summary.vendor-goals-summary article {
  border-color: rgba(148, 163, 184, 0.28);
  border-radius: 8px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.05);
}

#vendor-daybyday-summary .daybyday-progress-card {
  background: linear-gradient(135deg, #061a44, #0b2f8a 62%, #1d4ed8) !important;
}

#vendor-daybyday-status.table-status,
#vendor-daybyday-status {
  background: #eff6ff;
  border-color: #bfdbfe;
  border-radius: 8px;
  color: #1e3a8a;
  font-weight: 850;
}

#vendor-daybyday-content .daybyday-list-card,
.daybyday-list-card {
  border-color: rgba(148, 163, 184, 0.28);
  border-radius: 8px;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.07);
  overflow: hidden;
}

#vendor-daybyday-content .daybyday-list-head {
  background: linear-gradient(180deg, #fff, #f8fafc);
  padding: 18px 20px;
}

#vendor-daybyday-content .daybyday-client-list {
  background: #f8fafc;
  padding: 14px;
}

#vendor-daybyday-content .daybyday-client-card,
.daybyday-client-card {
  border-color: rgba(148, 163, 184, 0.32);
  border-radius: 8px;
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.045);
}

.daybyday-client-card.saved {
  background: #f0fdf4;
  border-color: rgba(22, 163, 74, 0.32);
}

.daybyday-card-actions .mini-action {
  border-radius: 8px;
  font-weight: 850;
}

@media (max-width: 900px) {
  .vendor-shell .content {
    padding: 14px;
  }

  .vendor-shell .topbar,
  .vendor-portal-hero,
  .daybyday-header {
    display: grid;
  }

  .vendor-portal-badge {
    justify-self: start;
  }

  .vendor-workspace-nav {
    display: grid;
    grid-template-columns: 1fr;
    overflow: visible;
  }

  .vendor-workspace-nav button,
  #vendor-page-view .vendor-workspace-nav button {
    min-width: 0;
  }
}

/* Main workspace refresh */
:root {
  --bg: #eef3f8;
  --panel: #ffffff;
  --ink: #07162d;
  --muted: #64748b;
  --line: #d8e0ec;
  --brand: #1647ad;
  --brand-dark: #071b3a;
  --accent: #0f8b8d;
  --warm: #b7791f;
  --surface: #f7f9fc;
  --shadow: 0 18px 44px rgba(15, 23, 42, 0.08);
}

body {
  background: linear-gradient(180deg, #f8fbff 0%, #eef3f8 48%, #e8eef6 100%);
}

.app-shell:not(.vendor-shell) {
  grid-template-columns: 274px minmax(0, 1fr);
}

.app-shell:not(.vendor-shell) .sidebar {
  position: sticky;
  top: 0;
  align-self: start;
  min-height: 100vh;
  background: linear-gradient(180deg, rgba(4, 12, 28, 0.98), rgba(7, 27, 58, 0.98) 58%, rgba(9, 57, 82, 0.98));
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 18px 0 40px rgba(15, 23, 42, 0.14);
  padding: 28px 16px;
}

.app-shell:not(.vendor-shell) .brand {
  gap: 12px;
  margin-bottom: 32px;
  padding: 0 2px;
}

.app-shell:not(.vendor-shell) .brand-mark {
  width: 58px;
  height: 58px;
  border-radius: 8px;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.2);
}

.app-shell:not(.vendor-shell) .brand strong {
  color: #ffffff;
  font-size: 17px;
  letter-spacing: 0;
}

.app-shell:not(.vendor-shell) .brand span {
  color: #bfccd9;
}

.app-shell:not(.vendor-shell) .nav {
  gap: 8px;
}

.app-shell:not(.vendor-shell) .nav-item {
  min-height: 48px;
  border: 1px solid rgba(226, 232, 240, 0.11);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.055);
  color: #edf5ff;
  font-weight: 750;
  padding: 0 14px;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease, transform 0.16s ease;
}

.app-shell:not(.vendor-shell) .nav-item:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.22);
  color: #ffffff;
  transform: translateX(2px);
}

.app-shell:not(.vendor-shell) .nav-item.active {
  background: #ffffff;
  border-color: #ffffff;
  color: var(--brand-dark);
  box-shadow: 0 14px 26px rgba(0, 0, 0, 0.16);
}

.app-shell:not(.vendor-shell) .nav-icon {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.13);
  color: #ffffff;
  font-size: 12px;
  font-weight: 850;
}

.app-shell:not(.vendor-shell) .nav-item.active .nav-icon {
  background: #e9f0ff;
  color: var(--brand);
}

.app-shell:not(.vendor-shell) .content {
  padding: 28px 30px 42px;
}

.app-shell:not(.vendor-shell) .topbar {
  position: sticky;
  top: 0;
  z-index: 15;
  margin: -28px -30px 28px;
  padding: 18px 30px;
  background: rgba(248, 251, 255, 0.88);
  border-bottom: 1px solid rgba(203, 213, 225, 0.78);
  backdrop-filter: blur(18px);
}

.app-shell:not(.vendor-shell) .topbar-logo {
  width: 56px;
  height: 56px;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.09);
}

.app-shell:not(.vendor-shell) .topbar h1 {
  color: var(--brand-dark);
  font-size: 34px;
  line-height: 1.05;
}

.app-shell:not(.vendor-shell) .topbar-actions {
  gap: 10px;
}

.app-shell:not(.vendor-shell) .user-chip,
.app-shell:not(.vendor-shell) .company-pill,
.app-shell:not(.vendor-shell) .home-return-button,
.app-shell:not(.vendor-shell) .secondary-action {
  min-height: 42px;
  border-radius: 8px;
  border-color: #cdd7e8 !important;
  background: rgba(255, 255, 255, 0.86) !important;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
}

.app-shell:not(.vendor-shell) .user-chip {
  background: #edf4ff !important;
  color: var(--brand-dark);
}

.app-shell:not(.vendor-shell) .company-strip {
  max-width: 760px;
}

.app-shell:not(.vendor-shell) .company-pill {
  color: #17324d !important;
  padding: 8px 13px;
}

.app-shell:not(.vendor-shell) .company-pill:hover,
.app-shell:not(.vendor-shell) .secondary-action:hover,
.app-shell:not(.vendor-shell) .home-return-button:hover {
  border-color: var(--brand) !important;
  color: var(--brand) !important;
  transform: translateY(-1px);
}

#home-view {
  max-width: 1580px;
}

#home-view .hero {
  position: relative;
  overflow: hidden;
  align-items: stretch;
  min-height: 236px;
  border: 1px solid rgba(196, 208, 226, 0.82);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(240, 246, 255, 0.96) 48%, rgba(225, 236, 255, 0.92) 100%),
    linear-gradient(135deg, rgba(22, 71, 173, 0.22), rgba(15, 139, 141, 0.16)) !important;
  box-shadow: 0 22px 48px rgba(15, 23, 42, 0.09);
  padding: 36px 34px;
}

#home-view .hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(22, 71, 173, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(22, 71, 173, 0.045) 1px, transparent 1px);
  background-size: 44px 44px;
  pointer-events: none;
}

#home-view .hero > * {
  position: relative;
  z-index: 1;
}

#home-view .hero h2 {
  max-width: 720px;
  color: #061a38 !important;
  font-size: clamp(30px, 2.4vw, 42px);
  line-height: 1.12;
  margin-bottom: 12px;
}

#home-view .hero .muted {
  max-width: 660px;
  color: #52637a;
  font-size: 16px;
}

#home-view .hero-actions {
  align-content: center;
  align-items: center;
  display: grid;
  grid-template-columns: repeat(3, minmax(130px, 1fr));
  justify-content: stretch;
  max-width: 620px;
  width: 100%;
}

#home-view .primary-action,
#home-view .secondary-action {
  align-items: center;
  display: inline-flex;
  justify-content: center;
  min-height: 46px;
  min-width: 0;
  border-radius: 8px;
  line-height: 1.15;
  padding: 0 14px;
  text-align: center;
  white-space: normal;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease, background 0.16s ease;
  width: 100%;
}

#home-view .primary-action {
  background: linear-gradient(135deg, #1647ad, #0f8b8d) !important;
  box-shadow: 0 16px 30px rgba(22, 71, 173, 0.22);
}

#home-view .secondary-action {
  background: rgba(255, 255, 255, 0.92) !important;
}

#home-view .primary-action:hover,
#home-view .secondary-action:hover {
  transform: translateY(-2px);
}

#home-view .hero-actions [data-view="follow-up"] {
  grid-column: span 2;
}

#logout-button {
  background: #e60012 !important;
  border-color: #e60012 !important;
  color: #ffffff !important;
  box-shadow: 0 12px 24px rgba(230, 0, 18, 0.24) !important;
}

#logout-button:hover {
  background: #b8000e !important;
  border-color: #b8000e !important;
  color: #ffffff !important;
  transform: translateY(-1px);
}

#refresh-data-button {
  background: #fff7d6 !important;
  border-color: #f2c94c !important;
  color: #6f4a00 !important;
}

#refresh-data-button:hover {
  background: #ffe07a !important;
  border-color: #d9a800 !important;
  color: #3f2a00 !important;
}

#refresh-data-button:disabled {
  cursor: wait;
  opacity: 0.72;
  transform: none;
}

#home-view .vendor-panel-action {
  align-items: stretch;
  background: linear-gradient(135deg, #ffd84d, #f5b900) !important;
  border: 1px solid rgba(148, 106, 0, 0.18) !important;
  border-radius: 8px;
  color: #3b2a00 !important;
  display: grid;
  gap: 10px;
  grid-column: 1 / -1;
  min-height: 74px;
  padding: 14px;
  box-shadow: 0 16px 30px rgba(245, 185, 0, 0.26) !important;
}

#home-view .vendor-panel-action:hover {
  background: linear-gradient(135deg, #ffe270, #e6a800) !important;
  color: #2a1d00 !important;
}

.vendor-panel-action-head {
  align-items: baseline;
  display: flex;
  gap: 10px;
  justify-content: space-between;
}

.vendor-panel-action-head strong {
  color: #2a1d00;
  font-size: 17px;
  line-height: 1.1;
}

.vendor-panel-action-head span {
  color: rgba(59, 42, 0, 0.72);
  font-size: 12px;
  font-weight: 700;
  text-align: right;
}

.vendor-panel-button-list {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  max-height: 178px;
  overflow-y: auto;
  padding-right: 2px;
}

.vendor-panel-pill {
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(59, 42, 0, 0.16);
  border-radius: 8px;
  color: #2a1d00;
  cursor: pointer;
  display: grid;
  gap: 2px;
  min-height: 46px;
  padding: 8px 10px;
  text-align: left;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}

.vendor-panel-pill:hover {
  border-color: rgba(59, 42, 0, 0.38);
  box-shadow: 0 10px 18px rgba(120, 84, 0, 0.16);
  transform: translateY(-1px);
}

.vendor-panel-pill span {
  font-size: 12px;
  font-weight: 850;
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vendor-panel-pill small,
.vendor-panel-empty {
  color: rgba(59, 42, 0, 0.72);
  font-size: 11px;
  font-weight: 700;
}

.sent-documents-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.sent-documents-panel {
  border: 1px solid #d7e0ef;
  border-radius: 8px;
  background: #ffffff;
  padding: 14px;
}

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

.sent-documents-head h4 {
  margin: 0;
  font-size: 0.95rem;
  color: #0f2240;
}

.sent-documents-head span {
  color: #64748b;
  font-size: 0.82rem;
  font-weight: 700;
}

.sent-documents-list {
  display: grid;
  gap: 8px;
  min-height: 72px;
}

.sent-document-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  background: #f8fafc;
  padding: 10px;
  text-align: left;
}

.sent-document-row strong,
.sent-document-row span,
.sent-document-row small {
  display: block;
}

.sent-document-row strong {
  color: #0f2240;
  font-size: 0.9rem;
}

.sent-document-row span {
  color: #334155;
  font-size: 0.82rem;
  margin-top: 2px;
}

.sent-document-row small {
  color: #64748b;
  font-size: 0.76rem;
  margin-top: 2px;
}

.sent-document-row button,
.sent-documents-pages button {
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  background: #ffffff;
  color: #1746a2;
  font-weight: 800;
  cursor: pointer;
}

.sent-document-row button {
  padding: 8px 10px;
}

.sent-documents-pages {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
}

.sent-documents-pages button {
  min-width: 32px;
  padding: 6px 8px;
}

.sent-documents-pages button.active {
  background: #1746a2;
  color: #ffffff;
}

@media (max-width: 900px) {
  .sent-documents-grid {
    grid-template-columns: 1fr;
  }
}

.sent-document-modal.hidden {
  display: none;
}

.sent-document-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  padding: 24px;
}

.sent-document-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.58);
}

.sent-document-modal-panel {
  position: relative;
  z-index: 1;
  width: min(1080px, 96vw);
  max-height: min(86vh, 920px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 24px 64px rgba(15, 23, 42, 0.28);
}

.sent-document-modal-head,
.sent-document-modal-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid #e2e8f0;
}

.sent-document-modal-head h3 {
  margin: 2px 0 0;
  color: #0f2240;
  font-size: 1.2rem;
}

.sent-document-modal-close {
  width: 36px;
  height: 36px;
  border: 1px solid #d7e0ef;
  border-radius: 50%;
  background: #ffffff;
  color: #0f2240;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
}

.sent-document-modal-body {
  overflow: auto;
  padding: 18px;
}

.sent-document-modal-actions {
  border-top: 1px solid #e2e8f0;
  border-bottom: 0;
  justify-content: flex-end;
}

.sent-document-focus-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.sent-document-focus-summary article {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 10px;
  background: #f8fafc;
}

.sent-document-focus-summary span {
  display: block;
  color: #64748b;
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
}

.sent-document-focus-summary strong {
  display: block;
  margin-top: 4px;
  color: #0f2240;
  font-size: 0.95rem;
}

.sent-document-client-box {
  border: 1px solid #d7e0ef;
  border-radius: 8px;
  padding: 12px;
  margin-bottom: 16px;
  background: #ffffff;
}

.sent-document-client-box strong,
.sent-document-client-box span {
  display: block;
}

.sent-document-client-box strong {
  color: #0f2240;
  font-size: 1rem;
}

.sent-document-client-box span {
  color: #475569;
  font-size: 0.86rem;
  margin-top: 4px;
}

.sent-document-items-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
}

.sent-document-items-table th,
.sent-document-items-table td {
  border-bottom: 1px solid #e2e8f0;
  padding: 9px 8px;
  text-align: left;
  vertical-align: top;
}

.sent-document-items-table th {
  background: #eef4ff;
  color: #0f2240;
  font-weight: 900;
}

@media (max-width: 760px) {
  .sent-document-modal {
    padding: 10px;
  }

  .sent-document-focus-summary {
    grid-template-columns: 1fr 1fr;
  }

  .sent-document-modal-actions {
    align-items: stretch;
    flex-direction: column;
  }
}

.sent-document-modal-body .sent-modal-editor {
  margin: 0;
  border: 0;
  box-shadow: none;
  padding: 0;
}

.sent-document-modal-body .sent-modal-editor .quote-builder-grid {
  grid-template-columns: minmax(0, 1fr);
}

/* Full-screen focus mode for sent documents */
.sent-document-modal {
  padding: 0;
  place-items: stretch;
}

.sent-document-modal-backdrop {
  background: #f3f6fb;
}

.sent-document-modal-panel {
  width: 100vw;
  max-height: 100vh;
  height: 100vh;
  border-radius: 0;
  box-shadow: none;
}

.sent-document-modal-body {
  flex: 1;
  padding: 20px 24px;
}

.sent-document-modal-head,
.sent-document-modal-actions {
  padding-left: 24px;
  padding-right: 24px;
}

.sent-document-modal-actions {
  background: #ffffff;
  box-shadow: 0 -10px 24px rgba(15, 23, 42, 0.06);
}

.sent-document-modal-actions .secondary-action,
.sent-document-modal-actions .primary-action {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 8px;
  padding: 0 16px;
  font-size: 0.88rem;
  font-weight: 900;
  text-decoration: none;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease, background 0.16s ease;
}

.sent-document-modal-actions .secondary-action {
  border: 1px solid #bfd0e8;
  background: #ffffff;
  color: #1746a2;
}

.sent-document-modal-actions .secondary-action::before {
  content: "PDF";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 30px;
  height: 22px;
  border-radius: 5px;
  background: #eef4ff;
  color: #1746a2;
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.02em;
}

.sent-document-modal-actions .primary-action::before {
  content: "✎";
  font-size: 1rem;
  line-height: 1;
}

.sent-document-modal-actions .secondary-action:hover,
.sent-document-modal-actions .primary-action:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(23, 70, 162, 0.16);
}

.sent-document-modal-actions .secondary-action:focus-visible,
.sent-document-modal-actions .primary-action:focus-visible {
  outline: 3px solid rgba(37, 99, 235, 0.24);
  outline-offset: 2px;
}

@media (max-width: 760px) {
  .sent-document-modal-actions .secondary-action,
  .sent-document-modal-actions .primary-action {
    width: 100%;
  }
}

/* Day by Day - light UX polish */
#vendor-workspace-day .daybyday-shell {
  gap: 14px;
  padding: 18px;
}

.daybyday-header {
  align-items: center;
  background: #ffffff;
  border: 1px solid #d7e0ef;
  border-radius: 8px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.04);
  display: flex;
  justify-content: space-between;
  padding: 14px 16px;
}

.daybyday-header h3 {
  font-size: 1.35rem;
  margin: 2px 0 0;
}

.daybyday-header .vendor-actions {
  display: flex;
  gap: 8px;
}

.daybyday-header .vendor-actions button {
  min-height: 36px;
  border-radius: 7px;
  font-weight: 900;
}

#vendor-daybyday-summary.vendor-goals-summary {
  gap: 10px;
}

#vendor-daybyday-summary.vendor-goals-summary article {
  min-height: 64px !important;
  padding: 12px 14px;
}

#vendor-daybyday-summary.vendor-goals-summary article span {
  color: #52637a;
  font-size: 0.68rem;
  letter-spacing: 0.02em;
}

#vendor-daybyday-summary.vendor-goals-summary article strong {
  font-size: 1rem;
}

#vendor-daybyday-summary .daybyday-progress-card {
  min-height: 142px !important;
  padding: 18px !important;
}

#vendor-daybyday-summary .daybyday-progress-card strong {
  font-size: 2rem !important;
}

#vendor-daybyday-status {
  margin: 0;
  padding: 10px 12px;
}

#vendor-daybyday-content .daybyday-lists {
  gap: 12px;
}

#vendor-daybyday-content .daybyday-list-head {
  align-items: center;
  display: flex;
  justify-content: space-between;
  padding: 14px 16px;
}

#vendor-daybyday-content .daybyday-list-head h4 {
  font-size: 1.05rem;
  margin: 2px 0 0;
}

#vendor-daybyday-content .daybyday-list-head > strong {
  align-items: center;
  background: #0f172a;
  border-radius: 7px;
  color: #ffffff;
  display: inline-flex;
  min-height: 32px;
  min-width: 38px;
  justify-content: center;
  padding: 0 10px;
}

#vendor-daybyday-content .daybyday-client-list {
  max-height: 620px;
  padding: 10px;
}

#vendor-daybyday-content .daybyday-client-card,
.daybyday-client-card {
  gap: 8px;
  padding: 12px;
}

.daybyday-client-main .client-code,
.daybyday-client-main em {
  color: #475569;
  font-size: 0.74rem;
  font-style: normal;
  font-weight: 850;
}

.daybyday-client-main strong {
  color: #0f172a;
  font-size: 0.9rem !important;
  line-height: 1.22;
}

.daybyday-client-main span {
  color: #475569 !important;
  font-size: 0.76rem;
}

.daybyday-client-meta {
  gap: 6px;
}

.daybyday-client-meta span {
  border-radius: 7px;
  font-size: 0.72rem;
  font-weight: 850;
  padding: 5px 8px;
}

#vendor-daybyday-content .daybyday-year-counts {
  gap: 6px;
}

#vendor-daybyday-content .daybyday-year-counts button {
  min-height: 30px;
  border-radius: 6px;
  font-size: 0.72rem;
  padding: 5px 7px;
}

.daybyday-card-actions .mini-action {
  min-height: 34px;
  padding: 0 12px;
}

@media (max-width: 760px) {
  .daybyday-header,
  #vendor-daybyday-content .daybyday-list-head {
    align-items: stretch;
    flex-direction: column;
  }

  .daybyday-header .vendor-actions {
    width: 100%;
  }

  .daybyday-header .vendor-actions button {
    flex: 1;
  }
}

/* Day by Day - subtle motion and depth */
@keyframes daybydayFadeUp {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#vendor-workspace-day .daybyday-shell {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.daybyday-header,
#vendor-daybyday-summary.vendor-goals-summary article,
#vendor-daybyday-content .daybyday-list-card {
  animation: daybydayFadeUp 0.28s ease both;
}

#vendor-daybyday-summary.vendor-goals-summary article:nth-child(2) { animation-delay: 0.03s; }
#vendor-daybyday-summary.vendor-goals-summary article:nth-child(3) { animation-delay: 0.06s; }
#vendor-daybyday-summary.vendor-goals-summary article:nth-child(4) { animation-delay: 0.09s; }
#vendor-daybyday-summary.vendor-goals-summary article:nth-child(5) { animation-delay: 0.12s; }
#vendor-daybyday-summary.vendor-goals-summary article:nth-child(6) { animation-delay: 0.15s; }

#vendor-daybyday-content .daybyday-list-card:nth-child(1) { animation-delay: 0.08s; }
#vendor-daybyday-content .daybyday-list-card:nth-child(2) { animation-delay: 0.12s; }

#vendor-daybyday-summary.vendor-goals-summary article {
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

#vendor-daybyday-summary.vendor-goals-summary article:not(.daybyday-progress-card):hover {
  border-color: rgba(37, 99, 235, 0.28);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.09);
  transform: translateY(-2px);
}

#vendor-daybyday-summary .daybyday-progress-card {
  box-shadow: 0 18px 38px rgba(29, 78, 216, 0.22) !important;
}

#vendor-daybyday-content .daybyday-list-card {
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
}

#vendor-daybyday-content .daybyday-client-card,
.daybyday-client-card {
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease, background 0.16s ease;
}

#vendor-daybyday-content .daybyday-client-card:hover,
.daybyday-client-card:hover {
  border-color: rgba(37, 99, 235, 0.34);
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.11);
  transform: translateY(-2px);
}

.daybyday-card-actions .mini-action,
.daybyday-header .vendor-actions button {
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease, border-color 0.16s ease;
}

.daybyday-card-actions .mini-action:hover,
.daybyday-header .vendor-actions button:hover {
  box-shadow: 0 10px 20px rgba(23, 70, 162, 0.13);
  transform: translateY(-1px);
}

.daybyday-progress i {
  transition: width 0.45s ease;
}

#vendor-daybyday-status {
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.08);
}

@media (prefers-reduced-motion: reduce) {
  .daybyday-header,
  #vendor-daybyday-summary.vendor-goals-summary article,
  #vendor-daybyday-content .daybyday-list-card,
  #vendor-daybyday-summary.vendor-goals-summary article,
  #vendor-daybyday-content .daybyday-client-card,
  .daybyday-client-card,
  .daybyday-card-actions .mini-action,
  .daybyday-header .vendor-actions button,
  .daybyday-progress i {
    animation: none !important;
    transition: none !important;
    transform: none !important;
  }
}

/* Quote workspace - visual polish */
@keyframes quoteFadeUp {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#vendor-workspace-quotes {
  background: linear-gradient(180deg, #f8fbff 0%, #f3f6fb 100%);
}

.quote-hero {
  background: radial-gradient(circle at 82% 18%, rgba(59, 130, 246, 0.24), transparent 28%), linear-gradient(135deg, #07111f, #0f2240 62%, #12357a);
  border: 0;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.18);
}

.quote-hero h3 {
  color: #ffffff;
  font-size: 1.45rem;
}

.quote-hero p:not(.eyebrow) {
  color: #dbeafe;
}

.quote-number-card {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.28);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.quote-workbench,
.quote-items-panel,
.quote-footer {
  animation: quoteFadeUp 0.28s ease both;
}

.quote-items-panel { animation-delay: 0.05s; }
.quote-footer { animation-delay: 0.08s; }

.quote-panel,
.quote-items-panel,
.quote-footer {
  border-color: rgba(148, 163, 184, 0.3);
  border-radius: 10px;
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.07);
}

.quote-panel-heading {
  border-bottom: 1px solid rgba(148, 163, 184, 0.22);
  margin: -2px -2px 14px;
  padding-bottom: 10px;
}

.quote-panel-heading h4 {
  color: #0f2240;
  font-size: 1rem;
}

.quote-panel-heading span:first-child {
  background: #dbeafe;
  color: #1746a2;
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.12);
}

.quote-panel input,
.quote-add-item-panel input,
.quote-line-input {
  background: #ffffff;
  border-color: #c9d6ea;
  border-radius: 8px;
  min-height: 38px;
  transition: border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.quote-panel input:focus,
.quote-add-item-panel input:focus,
.quote-line-input:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
  outline: none;
}

.quote-add-item-panel .primary-action,
.quote-actions .primary-action,
.quote-actions .secondary-action {
  border-radius: 8px;
  min-height: 42px;
  font-weight: 900;
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.quote-add-item-panel .primary-action:hover,
.quote-actions .primary-action:hover,
.quote-actions .secondary-action:hover {
  box-shadow: 0 12px 24px rgba(23, 70, 162, 0.16);
  transform: translateY(-1px);
}

.quote-items-panel .table-scroll {
  border-radius: 8px;
  border: 1px solid #dbe3f0;
}

.quote-items-table thead th {
  background: #eef4ff;
  color: #0f2240;
  font-size: 0.72rem;
  letter-spacing: 0.02em;
}

.quote-items-table tbody tr {
  transition: background 0.14s ease;
}

.quote-items-table tbody tr:hover {
  background: #f8fbff;
}

.quote-empty-row td {
  color: #64748b;
  font-weight: 750;
  padding: 22px !important;
}

.quote-summary-panel article {
  border-color: rgba(148, 163, 184, 0.28);
  border-radius: 10px;
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.06);
}

.quote-summary-panel .quote-total-card {
  background: linear-gradient(135deg, #07111f, #12357a);
  box-shadow: 0 18px 36px rgba(18, 53, 122, 0.2);
}

#quote-status {
  border-radius: 8px;
  margin-top: 12px;
}

@media (prefers-reduced-motion: reduce) {
  .quote-workbench,
  .quote-items-panel,
  .quote-footer,
  .quote-panel input,
  .quote-add-item-panel input,
  .quote-line-input,
  .quote-add-item-panel .primary-action,
  .quote-actions .primary-action,
  .quote-actions .secondary-action,
  .quote-items-table tbody tr {
    animation: none !important;
    transition: none !important;
    transform: none !important;
  }
}

/* Quote workspace - readability pass */
#vendor-workspace-quotes .quote-hero {
  background: linear-gradient(135deg, #0b1730 0%, #12366f 100%);
  padding: 22px 24px;
}

#vendor-workspace-quotes .quote-hero .eyebrow {
  color: #93c5fd;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.04em;
}

#vendor-workspace-quotes .quote-hero h3,
#vendor-workspace-quotes .quote-hero .quote-title {
  color: #ffffff !important;
  font-size: 1.72rem;
  line-height: 1.15;
  font-weight: 900;
  margin-top: 4px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.18);
}

#vendor-workspace-quotes .quote-hero p:not(.eyebrow) {
  color: #f8fbff;
  font-size: 0.98rem;
  line-height: 1.45;
  max-width: 680px;
}

#vendor-workspace-quotes .quote-number-card {
  min-width: 150px;
  padding: 18px 20px;
}

#vendor-workspace-quotes .quote-number-card span,
#vendor-workspace-quotes .quote-number-card small {
  color: #dbeafe;
  font-size: 0.72rem;
  font-weight: 900;
}

#vendor-workspace-quotes .quote-number-card strong {
  color: #ffffff;
  font-size: 1.7rem;
  line-height: 1.05;
}

#vendor-workspace-quotes .quote-panel,
#vendor-workspace-quotes .quote-items-panel,
#vendor-workspace-quotes .quote-footer {
  padding: 22px;
}

#vendor-workspace-quotes .quote-panel-heading h4 {
  font-size: 1.12rem;
  color: #0f172a;
}

#vendor-workspace-quotes .quote-panel-heading p,
#vendor-workspace-quotes .quote-panel-heading small {
  color: #475569;
  font-size: 0.86rem;
  line-height: 1.35;
}

#vendor-workspace-quotes label,
#vendor-workspace-quotes .quote-panel label,
#vendor-workspace-quotes .quote-add-item-panel label {
  color: #0f172a;
  font-size: 0.86rem;
  font-weight: 850;
  margin-bottom: 7px;
}

#vendor-workspace-quotes .quote-panel input,
#vendor-workspace-quotes .quote-add-item-panel input,
#vendor-workspace-quotes .quote-line-input {
  min-height: 46px;
  font-size: 0.96rem;
  color: #0f172a;
  padding: 10px 13px;
}

#vendor-workspace-quotes .quote-panel input::placeholder,
#vendor-workspace-quotes .quote-add-item-panel input::placeholder {
  color: #64748b;
  font-weight: 650;
}

#vendor-workspace-quotes .quote-add-item-panel .primary-action,
#vendor-workspace-quotes .quote-actions .primary-action,
#vendor-workspace-quotes .quote-actions .secondary-action {
  min-height: 46px;
  padding: 0 20px;
  font-size: 0.95rem;
  white-space: nowrap;
}

#vendor-workspace-quotes .quote-items-table thead th {
  font-size: 0.78rem;
  color: #0f172a;
  padding: 13px 12px;
}

#vendor-workspace-quotes .quote-items-table tbody td {
  font-size: 0.9rem;
  color: #1e293b;
  padding: 12px;
}

#vendor-workspace-quotes .quote-summary-panel article span,
#vendor-workspace-quotes .quote-summary-panel article small {
  color: #475569;
  font-size: 0.8rem;
  font-weight: 850;
}

#vendor-workspace-quotes .quote-summary-panel article strong {
  color: #0f172a;
  font-size: 1.32rem;
}

#vendor-workspace-quotes .quote-summary-panel .quote-total-card span,
#vendor-workspace-quotes .quote-summary-panel .quote-total-card small,
#vendor-workspace-quotes .quote-summary-panel .quote-total-card strong {
  color: #ffffff;
}

@media (max-width: 760px) {
  #vendor-workspace-quotes .quote-hero {
    padding: 18px;
  }

  #vendor-workspace-quotes .quote-hero h3,
  #vendor-workspace-quotes .quote-hero .quote-title {
    font-size: 1.42rem;
  }

  #vendor-workspace-quotes .quote-number-card {
    min-width: 100%;
  }
}

/* Quote workspace - hero label contrast */
#vendor-workspace-quotes .quote-hero .eyebrow,
#vendor-workspace-quotes .quote-hero [class*= eyebrow] {
  color: #ffffff !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.18);
}

/* Quote workspace - softer reading hierarchy */
#vendor-workspace-quotes {
  color: #1f2937;
}

#vendor-workspace-quotes .quote-panel-heading h4,
#vendor-workspace-quotes .quote-items-panel h4 {
  font-weight: 750;
}

#vendor-workspace-quotes .quote-panel-heading p,
#vendor-workspace-quotes .quote-panel-heading small,
#vendor-workspace-quotes .quote-items-panel small {
  color: #526174;
  font-weight: 500;
}

#vendor-workspace-quotes label,
#vendor-workspace-quotes .quote-panel label,
#vendor-workspace-quotes .quote-add-item-panel label {
  color: #1e293b;
  font-size: 0.84rem;
  font-weight: 650;
}

#vendor-workspace-quotes .quote-panel input,
#vendor-workspace-quotes .quote-add-item-panel input,
#vendor-workspace-quotes .quote-line-input {
  font-weight: 500;
}

#vendor-workspace-quotes .quote-panel input::placeholder,
#vendor-workspace-quotes .quote-add-item-panel input::placeholder {
  color: #78869a;
  font-weight: 500;
}

#vendor-workspace-quotes .customer-search-results,
#vendor-workspace-quotes .product-search-results,
#vendor-workspace-quotes .quote-search-results,
#vendor-workspace-quotes [class*= search-results] {
  font-weight: 500;
  color: #334155;
}

#vendor-workspace-quotes .customer-search-results strong,
#vendor-workspace-quotes .product-search-results strong,
#vendor-workspace-quotes .quote-search-results strong,
#vendor-workspace-quotes [class*=search-results] strong,
#vendor-workspace-quotes [class*=search-results] b {
  color: #0f172a;
  font-weight: 700;
}

#vendor-workspace-quotes .customer-search-results small,
#vendor-workspace-quotes .product-search-results small,
#vendor-workspace-quotes .quote-search-results small,
#vendor-workspace-quotes [class*=search-results] small {
  color: #526174;
  font-weight: 500;
  line-height: 1.35;
}

#vendor-workspace-quotes .customer-search-results li,
#vendor-workspace-quotes .product-search-results li,
#vendor-workspace-quotes .quote-search-results li,
#vendor-workspace-quotes [class*=search-results] li,
#vendor-workspace-quotes [class*=suggestion] {
  line-height: 1.38;
}

#vendor-workspace-quotes .quote-add-item-panel .primary-action,
#vendor-workspace-quotes .quote-actions .primary-action,
#vendor-workspace-quotes .quote-actions .secondary-action {
  font-weight: 750;
}

#vendor-workspace-quotes .quote-items-table thead th {
  font-weight: 700;
}

#vendor-workspace-quotes .quote-items-table tbody td {
  font-weight: 500;
}

#vendor-workspace-quotes .quote-summary-panel article span,
#vendor-workspace-quotes .quote-summary-panel article small {
  font-weight: 650;
}

#vendor-workspace-quotes .quote-summary-panel article strong {
  font-weight: 800;
}

/* Quote workspace - autocomplete readability */
#vendor-workspace-quotes .prospect-suggestions {
  font-size: 0.9rem;
}

#vendor-workspace-quotes .prospect-suggestion {
  color: #263449;
  font-weight: 500 !important;
  padding: 12px 14px;
}

#vendor-workspace-quotes .prospect-suggestion strong,
#vendor-workspace-quotes .prospect-suggestion b {
  color: #111827;
  font-weight: 650 !important;
}

#vendor-workspace-quotes .prospect-suggestion small,
#vendor-workspace-quotes .prospect-suggestion span,
#vendor-workspace-quotes .prospect-suggestion em {
  color: #536276;
  font-weight: 500 !important;
}

#vendor-workspace-quotes .prospect-suggestion:hover,
#vendor-workspace-quotes .prospect-suggestion:focus-visible {
  background: #f3f7ff;
  color: #111827;
}

#vendor-workspace-quotes .table-status {
  color: #536276;
  font-weight: 500;
}

/* Vendor workspace - shared UX polish */
.vendor-workspace-nav button {
  font-weight: 750;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.vendor-workspace-nav button:hover {
  box-shadow: 0 10px 20px rgba(20, 54, 117, 0.12);
  transform: translateY(-1px);
}

.vendor-workspace-panel.active {
  animation: vendorPanelFade 0.22s ease both;
}

@keyframes vendorPanelFade {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.vendor-workspace-panel h3,
.vendor-workspace-panel h4,
.vendor-workspace-panel h5 {
  color: #0f172a;
  font-weight: 760;
  letter-spacing: 0;
}

.vendor-workspace-panel p,
.vendor-workspace-panel span,
.vendor-workspace-panel small,
.vendor-workspace-panel td,
.vendor-workspace-panel label {
  font-weight: 500;
}

.vendor-workspace-panel strong,
.vendor-workspace-panel th {
  font-weight: 720;
}

.vendor-workspace-panel .eyebrow,
.vendor-workspace-panel .client-code,
.vendor-workspace-panel th {
  font-weight: 760;
}

.vendor-workspace-panel input,
.vendor-workspace-panel select,
.vendor-workspace-panel textarea {
  transition: border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.vendor-workspace-panel input:focus,
.vendor-workspace-panel select:focus,
.vendor-workspace-panel textarea:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.13);
  outline: none;
}

.vendor-workspace-panel .mini-action,
.vendor-workspace-panel .primary-action,
.vendor-workspace-panel .secondary-action,
.vendor-workspace-panel button:not(.vendor-workspace-nav button) {
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.vendor-workspace-panel .mini-action:hover,
.vendor-workspace-panel .primary-action:hover,
.vendor-workspace-panel .secondary-action:hover {
  box-shadow: 0 10px 20px rgba(20, 54, 117, 0.12);
  transform: translateY(-1px);
}

.loading-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 8px;
  border-radius: 999px;
  background: #2563eb;
  box-shadow: 0 0 0 rgba(37, 99, 235, 0.2);
  animation: loadingDotPulse 1s ease-in-out infinite;
  vertical-align: middle;
}

@keyframes loadingDotPulse {
  0%, 100% {
    opacity: 0.45;
    transform: scale(0.8);
    box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.18);
  }
  50% {
    opacity: 1;
    transform: scale(1);
    box-shadow: 0 0 0 7px rgba(37, 99, 235, 0);
  }
}

/* Vendor indicators - daily contact chart readability */
.vendor-daily-contact-chart,
#vendor-daily-contact-chart {
  overflow: visible;
}

.vendor-daily-contact-bars {
  align-items: end;
  gap: 26px;
  padding: 18px 12px 8px;
}

.vendor-daily-contact-day {
  color: #334155;
  font-weight: 500;
  transition: transform 0.18s ease;
}

.vendor-daily-contact-day:hover {
  transform: translateY(-2px);
}

.vendor-daily-contact-stack {
  position: relative;
  background: #eef4fb;
  border-color: #cbd8ea;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8), 0 12px 22px rgba(15, 23, 42, 0.07);
  transition: box-shadow 0.18s ease, transform 0.18s ease, border-color 0.18s ease;
}

.vendor-daily-contact-day:hover .vendor-daily-contact-stack {
  border-color: #2563eb;
  box-shadow: 0 14px 28px rgba(37, 99, 235, 0.16);
}

.vendor-daily-contact-stack::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 10px);
  z-index: 5;
  width: max-content;
  max-width: 250px;
  padding: 9px 11px;
  border-radius: 8px;
  background: #0f172a;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 650;
  line-height: 1.35;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 5px);
  transition: opacity 0.16s ease, transform 0.16s ease;
}

.vendor-daily-contact-stack::before {
  content: ";
  position: absolute;
  left: 50%;
  bottom: calc(100% + 4px);
  z-index: 5;
  border: 6px solid transparent;
  border-top-color: #0f172a;
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%);
  transition: opacity 0.16s ease;
}

.vendor-daily-contact-day:hover .vendor-daily-contact-stack::after,
.vendor-daily-contact-day:hover .vendor-daily-contact-stack::before {
  opacity: 1;
  transform: translate(-50%, 0);
}

.vendor-daily-contact-day:hover .vendor-daily-contact-stack::before {
  transform: translateX(-50%);
}

.vendor-daily-contact-day strong {
  color: #0f172a;
  font-weight: 680;
}

.vendor-daily-contact-day > span {
  color: #475569;
  font-weight: 500;
}

.vendor-daily-contact-legend span {
  color: #334155;
  font-weight: 600;
}

@media (prefers-reduced-motion: reduce) {
  .vendor-workspace-panel.active,
  .vendor-workspace-nav button,
  .vendor-workspace-panel .mini-action,
  .vendor-workspace-panel .primary-action,
  .vendor-workspace-panel .secondary-action,
  .vendor-daily-contact-day,
  .vendor-daily-contact-stack,
  .loading-dot {
    animation: none !important;
    transition: none !important;
    transform: none !important;
  }
}

/* Vendor indicators - readable daily contact list */
.vendor-daily-contact-list {
  display: grid;
  gap: 10px;
  padding: 10px 2px 4px;
}

.vendor-daily-contact-row {
  position: relative;
  display: grid;
  grid-template-columns: minmax(120px, 160px) minmax(220px, 1fr) minmax(220px, auto);
  align-items: center;
  gap: 16px;
  padding: 14px 16px;
  border: 1px solid #d8e2f0;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
  transition: border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease, background 0.16s ease;
}

.vendor-daily-contact-row:hover {
  border-color: #2563eb;
  background: #f8fbff;
  box-shadow: 0 14px 28px rgba(37, 99, 235, 0.13);
  transform: translateY(-1px);
}

.vendor-daily-contact-row::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 16px;
  bottom: calc(100% + 8px);
  z-index: 8;
  max-width: 360px;
  padding: 9px 11px;
  border-radius: 8px;
  background: #0f172a;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 650;
  line-height: 1.35;
  opacity: 0;
  pointer-events: none;
  transform: translateY(4px);
  transition: opacity 0.16s ease, transform 0.16s ease;
}

.vendor-daily-contact-row:hover::after {
  opacity: 1;
  transform: translateY(0);
}

.vendor-daily-contact-date strong {
  display: block;
  color: #0f172a;
  font-size: 0.96rem;
  font-weight: 760;
}

.vendor-daily-contact-date span,
.vendor-daily-contact-breakdown span {
  color: #475569;
  font-size: 0.82rem;
  font-weight: 550;
}

.vendor-daily-contact-meter {
  min-width: 0;
}

.vendor-daily-contact-track {
  display: flex;
  width: var(--total-width);
  min-width: 46px;
  height: 22px;
  overflow: hidden;
  border-radius: 999px;
  background: #e8eef7;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.12);
  transition: width 0.24s ease;
}

.vendor-daily-contact-row:hover .vendor-daily-contact-track {
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.12), 0 8px 18px rgba(37, 99, 235, 0.14);
}

.vendor-daily-contact-track i {
  display: grid;
  place-items: center;
  width: var(--segment-width);
  min-width: 0;
  color: #ffffff;
  font-size: 0.72rem;
  font-style: normal;
  font-weight: 750;
}

.vendor-daily-contact-track i.inactive,
.vendor-daily-contact-breakdown i.inactive,
.vendor-daily-contact-legend i.inactive {
  background: #2563eb;
}

.vendor-daily-contact-track i.never,
.vendor-daily-contact-breakdown i.never,
.vendor-daily-contact-legend i.never {
  background: #059669;
}

.vendor-daily-contact-breakdown {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.vendor-daily-contact-breakdown i,
.vendor-daily-contact-legend i {
  display: inline-block;
  width: 9px;
  height: 9px;
  margin-right: 5px;
  border-radius: 999px;
  vertical-align: middle;
}

/* Vendor indicators - chart hover feedback */
.period-donut-item,
.bar-column,
.annual-month {
  cursor: help;
}

.period-donut-item {
  position: relative;
  border-radius: 10px;
  transition: background 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.period-donut-item:hover {
  background: #f8fbff;
  box-shadow: 0 12px 26px rgba(37, 99, 235, 0.12);
  transform: translateY(-2px);
}

.period-donut-item:hover .period-donut,
.period-donut-item:hover .donut-chart {
  filter: saturate(1.08);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12), 0 14px 28px rgba(15, 23, 42, 0.12);
}

.period-donut-item::after {
  content: attr(title);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  z-index: 8;
  width: max-content;
  max-width: 320px;
  padding: 9px 11px;
  border-radius: 8px;
  background: #0f172a;
  color: #ffffff;
  font-size: 0.76rem;
  font-weight: 650;
  line-height: 1.35;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 4px);
  transition: opacity 0.16s ease, transform 0.16s ease;
}

.period-donut-item:hover::after {
  opacity: 1;
  transform: translate(-50%, 0);
}

.bar-column:hover .bar-shape,
.annual-month:hover .annual-bar {
  filter: saturate(1.12);
  box-shadow: 0 12px 24px rgba(37, 99, 235, 0.18);
}

@media (max-width: 860px) {
  .vendor-daily-contact-row {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .vendor-daily-contact-breakdown {
    justify-content: flex-start;
  }
}

/* Vendor goals - clickable help popovers */
.goal-name-with-help {
  position: relative;
}

.goal-help-icon {
  border: 1px solid rgba(37, 99, 235, 0.35);
  background: #eff6ff;
  color: #1d4ed8;
  font-family: inherit;
  padding: 0;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.goal-help-icon:hover,
.goal-help-icon:focus,
.goal-help-icon.active {
  border-color: #2563eb;
  background: #2563eb;
  color: #ffffff;
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.18);
  transform: translateY(-1px);
}

.goal-name-with-help .goal-help-icon[data-goal-help]::after {
  content: attr(data-goal-help);
  position: absolute;
  left: 100%;
  top: 50%;
  z-index: 20;
  width: 300px;
  max-width: min(300px, 72vw);
  padding: 10px 12px;
  border-radius: 8px;
  background: #0f172a;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 550;
  line-height: 1.42;
  opacity: 0;
  pointer-events: none;
  transform: translate(10px, -50%);
  transition: opacity 0.16s ease, transform 0.16s ease;
  white-space: normal;
}

.goal-name-with-help .goal-help-icon[data-goal-help]:hover::after,
.goal-name-with-help .goal-help-icon[data-goal-help]:focus::after {
  opacity: 1;
  transform: translate(8px, -50%);
}

.goal-help-popover {
  position: absolute;
  left: calc(100% + 8px);
  top: 50%;
  z-index: 25;
  width: 320px;
  max-width: min(320px, 72vw);
  padding: 11px 13px;
  border-radius: 8px;
  background: #0f172a;
  color: #ffffff;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.24);
  font-size: 0.8rem;
  font-weight: 550;
  line-height: 1.42;
  transform: translateY(-50%);
  white-space: normal;
}

.goal-help-popover::before {
  content: "";
  position: absolute;
  right: 100%;
  top: 50%;
  border: 7px solid transparent;
  border-right-color: #0f172a;
  transform: translateY(-50%);
}

.commission-memory-modal {
  position: fixed;
  inset: 0;
  z-index: 10020;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(7, 27, 58, 0.46);
  backdrop-filter: blur(3px);
}

.commission-memory-panel {
  width: min(1180px, 96vw);
  max-height: min(84vh, 780px);
  border: 1px solid #f2c94c;
  border-radius: 12px;
  background: linear-gradient(180deg, #fffdf2, #ffffff);
  box-shadow: 0 28px 72px rgba(7, 27, 58, 0.3);
  overflow: auto;
  padding: 22px;
}

.commission-memory-panel header {
  align-items: flex-start;
  border-bottom: 1px solid #f7e3a1;
  display: flex;
  gap: 16px;
  justify-content: space-between;
  margin-bottom: 16px;
  padding-bottom: 14px;
}

.commission-memory-panel h3 {
  color: #071b3a;
  font-size: 24px;
  margin: 2px 0 0;
}

.commission-memory-close {
  width: 38px;
  height: 38px;
  border: 1px solid #f2c94c;
  border-radius: 10px;
  background: #fff8d8;
  color: #713f12;
  cursor: pointer;
  font-size: 24px;
  font-weight: 900;
  line-height: 1;
}

.commission-memory-result {
  border: 1px solid #dbe7f8;
  border-left: 5px solid #f5b400;
  border-radius: 10px;
  background: #ffffff;
  display: grid;
  gap: 4px;
  margin-bottom: 16px;
  padding: 14px 16px;
}

.commission-memory-result span {
  color: #6b7280;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.commission-memory-result strong {
  color: #071b3a;
  font-size: 28px;
  font-weight: 950;
}

.commission-memory-panel ol {
  display: grid;
  gap: 10px;
  margin: 0;
  padding-left: 22px;
}

.commission-memory-panel li {
  color: #26344f;
  font-size: 14px;
  font-weight: 650;
  line-height: 1.45;
}

.commission-memory-table-block {
  border-top: 1px solid #f7e3a1;
  margin-top: 18px;
  padding-top: 16px;
}

.commission-memory-table-block .table-scroll {
  max-height: 46vh;
  overflow: auto;
  padding-bottom: 8px;
  scrollbar-gutter: stable both-edges;
}

.commission-memory-table-block h4 {
  color: #071b3a;
  font-size: 16px;
  margin: 0 0 10px;
}

.commission-memory-table {
  min-width: 1320px;
  width: 100%;
}

.commission-memory-table th {
  background: #fff8d8;
  color: #713f12;
  font-size: 11px;
  text-transform: uppercase;
}

.commission-memory-table td {
  color: #24324d;
  font-size: 12px;
  font-weight: 650;
}

@media (max-width: 860px) {
  .goal-name-with-help .goal-help-icon[data-goal-help]::after,
  .goal-help-popover {
    left: 0;
    right: auto;
    top: calc(100% + 8px);
    transform: none;
  }

  .goal-name-with-help .goal-help-icon[data-goal-help]:hover::after,
  .goal-name-with-help .goal-help-icon[data-goal-help]:focus::after {
    transform: none;
  }

  .goal-help-popover::before {
    display: none;
  }
}

/* Home dashboard - faster perceived loading */
.home-loading-panel {
  border: 1px solid #d8e2f0;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
  padding: 18px;
}

.home-vendor-card-skeleton-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

.home-vendor-card-skeleton {
  min-height: 130px;
  border: 1px solid #d8e2f0;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.05);
  pointer-events: none;
}

.home-vendor-card-skeleton span,
.home-vendor-card-skeleton strong,
.home-vendor-card-skeleton small {
  display: block;
  border-radius: 999px;
  background: linear-gradient(90deg, #eef3fb 0%, #f8fbff 48%, #eef3fb 100%);
  background-size: 220% 100%;
  animation: skeletonShimmer 1.15s ease-in-out infinite;
}

.home-vendor-card-skeleton span {
  width: 34%;
  height: 10px;
  margin: 16px 16px 12px;
}

.home-vendor-card-skeleton strong {
  width: 68%;
  height: 18px;
  margin: 0 16px 18px;
}

.home-vendor-card-skeleton small {
  width: calc(100% - 32px);
  height: 44px;
  margin: 0 16px 16px;
}

.vendor-panel-loading {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

@keyframes skeletonShimmer {
  0% { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

@media (prefers-reduced-motion: reduce) {
        .home-vendor-card-skeleton span,
  .home-vendor-card-skeleton strong,
  .home-vendor-card-skeleton small {
    animation: none !important;
  }
}

.vendor-workspace-nav button.vendor-workspace-highlight {
  background: linear-gradient(135deg, #ffd84d, #f5b400);
  border-color: #e6a700;
  color: #1e293b;
  box-shadow: 0 14px 30px rgba(245, 180, 0, 0.24);
}

.vendor-workspace-nav button.vendor-workspace-highlight.active,
.vendor-workspace-nav button.vendor-workspace-highlight:hover {
  background: linear-gradient(135deg, #f5b400, #d89000);
  border-color: #c47d00;
  color: #111827;
}

.vendor-about-shell {
  display: grid;
  gap: 18px;
}

.vendor-page-seller-card {
  align-items: center;
  border: 1px solid #d8e2f0;
  border-left: 5px solid #facc15;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  justify-content: space-between;
  margin-top: -2px;
  padding: 14px 18px;
}

.vendor-page-seller-card span {
  color: #0b2f8a;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.vendor-page-seller-card strong {
  color: #071b3a;
  font-size: 24px;
  font-weight: 950;
}

.vendor-page-goals-month-card {
  align-items: center;
  background: linear-gradient(135deg, #fff8d8, #fffdf2);
  border: 1px solid rgba(245, 180, 0, 0.6);
  border-radius: 10px;
  box-shadow: 0 10px 22px rgba(148, 116, 20, 0.12);
  display: grid;
  gap: 6px;
  min-width: 138px;
  padding: 10px 12px;
}

.vendor-page-goals-month-card span {
  color: #7a4d00;
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.vendor-page-goals-month-card select {
  background: #fff;
  border: 1px solid #e3a900;
  border-radius: 8px;
  color: #071b3a;
  font-size: 16px;
  font-weight: 950;
  min-height: 40px;
}

.vendor-about-hero {
  align-items: center;
  border: 1px solid #d8e2f0;
  border-radius: 10px;
  background: linear-gradient(135deg, #f8fbff, #edf5ff);
  display: flex;
  gap: 18px;
  justify-content: space-between;
  padding: 22px;
}

.vendor-about-hero h3,
.vendor-about-title h4 {
  color: #071b3a;
  margin: 0;
}

.vendor-about-hero h3 {
  font-size: 28px;
}

.vendor-about-hero p {
  color: #536179;
  margin: 8px 0 0;
}

.vendor-about-badge {
  border: 1px solid rgba(245, 180, 0, 0.45);
  border-radius: 10px;
  background: #fff9df;
  display: grid;
  gap: 4px;
  min-width: 190px;
  padding: 16px;
  text-align: center;
}

.vendor-about-badge span,
.vendor-about-badge small {
  color: #6b5a1b;
  font-size: 12px;
  font-weight: 850;
}

.vendor-about-badge strong {
  color: #111827;
  font-size: 32px;
}

.vendor-about-card {
  border: 1px solid #d8e2f0;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.07);
  padding: 18px;
}

.vendor-about-title {
  margin-bottom: 14px;
}

.vendor-about-title-highlight {
  border: 1px solid #f4c84a;
  border-left: 5px solid #f5b400;
  border-radius: 10px;
  background: linear-gradient(135deg, #fff8dd, #fffdf4);
  box-shadow: 0 10px 24px rgba(148, 116, 20, 0.08);
  margin-bottom: 18px;
  padding: 16px 18px;
}

.vendor-about-title-highlight .eyebrow {
  color: #8a5a00;
  font-size: 13px;
}

.vendor-about-title-highlight h4 {
  color: #071b3a;
  font-size: 22px;
  line-height: 1.2;
  margin-top: 4px;
}

.vendor-about-table {
  min-width: 720px;
}

.vendor-about-table th {
  background: #f5f9fc;
  color: #42526b;
  font-size: 12px;
  text-transform: uppercase;
}

.vendor-about-table td {
  color: #0f1f3d;
  font-size: 14px;
}

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

.vendor-rule-group {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.vendor-rule-group h5 {
  border-left: 4px solid #f5b400;
  border-radius: 8px;
  background: #fff8d8;
  color: #071b3a;
  font-size: 16px;
  font-weight: 950;
  margin: 0;
  padding: 10px 12px;
}

.vendor-rule-group + .vendor-rule-group {
  margin-top: 22px;
}

.vendor-rule-card {
  border: 1px solid #d8e2f0;
  border-left: 4px solid #f5b400;
  border-radius: 10px;
  background: #fbfdff;
  display: grid;
  gap: 12px;
  padding: 16px;
}

.vendor-rule-card > div:first-child {
  display: grid;
  gap: 5px;
}

.vendor-rule-card span {
  color: #42526b;
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.vendor-rule-card strong {
  color: #071b3a;
  font-size: 18px;
}

.vendor-rule-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.vendor-rule-meta span {
  border-radius: 999px;
  background: #edf5ff;
  color: #17417d;
  padding: 6px 10px;
  text-transform: none;
}

.vendor-rule-card ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 18px;
}

.vendor-rule-card li {
  color: #35445f;
  line-height: 1.45;
}

@media (max-width: 900px) {
  .vendor-about-hero {
    align-items: stretch;
    flex-direction: column;
  }

  .vendor-rules-grid {
    grid-template-columns: 1fr;
  }
}

/* Painel do vendedor - acabamento profissional */
.vendor-shell .content {
  background:
    linear-gradient(180deg, #f4f7fb 0%, #edf3fa 100%);
}

#vendor-page-view.view.visible {
  gap: 14px;
}

.vendor-shell .topbar {
  border-color: #d8e2f0;
  border-radius: 10px;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
}

.vendor-portal-hero {
  border-radius: 10px;
  min-height: 136px;
  padding: 26px 28px;
}

.vendor-portal-hero h2 {
  font-size: 30px;
}

.vendor-workspace-nav,
#vendor-page-view .vendor-workspace-nav {
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid #d8e2f0;
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.06);
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
  margin: 0;
  overflow: visible !important;
  padding: 8px;
}

.vendor-workspace-nav button,
#vendor-page-view .vendor-workspace-nav button {
  align-items: center;
  border: 1px solid #cbd8ea;
  border-radius: 8px;
  box-shadow: none;
  display: inline-flex;
  font-size: 13px;
  font-weight: 850;
  justify-content: center;
  line-height: 1.2;
  min-height: 44px;
  padding: 8px 10px;
  text-align: center;
  white-space: normal;
}

.vendor-workspace-nav button.active,
.vendor-workspace-nav button:hover {
  box-shadow: 0 10px 20px rgba(29, 78, 216, 0.18);
}

.vendor-workspace-nav button.vendor-workspace-highlight {
  background: linear-gradient(135deg, #ffe38a, #ffc928);
  border-color: #e8b300;
}

.vendor-portal-panel {
  border-color: #d8e2f0;
  border-radius: 10px;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.07);
}

.vendor-about-hero {
  background:
    linear-gradient(135deg, #ffffff 0%, #f1f7ff 100%);
  border-radius: 10px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.vendor-about-card {
  border-radius: 10px;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.06);
}

.vendor-about-title {
  display: grid;
  gap: 4px;
}

.vendor-about-client-title {
  color: #334155;
  font-size: 14px;
  font-weight: 850;
}

.vendor-rules-grid {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.vendor-rule-card {
  background: linear-gradient(180deg, #ffffff, #f8fbff);
  border-left-color: #1d4ed8;
  min-width: 0;
  overflow: hidden;
}

.vendor-rule-card:first-child {
  border-left-color: #f5b400;
  grid-column: 1 / -1;
}

.vendor-sales-calc {
  border: 1px solid #d8e2f0;
  border-radius: 8px;
  background: #fffaf0;
  display: grid;
  gap: 10px;
  padding: 12px;
}

.vendor-sales-calc > strong {
  color: #7a4d00;
  font-size: 14px;
}

.vendor-sales-calc-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.vendor-sales-calc-grid span {
  background: #fff;
  border: 1px solid #f3d38a;
  border-radius: 8px;
  color: #1f2937;
  font-size: 13px;
  padding: 8px 10px;
  text-transform: none;
}

.vendor-sales-calc p {
  color: #334155;
  font-size: 14px;
  line-height: 1.45;
  margin: 0;
}

.vendor-bonus-rule-box {
  border: 1px solid #d8e2f0;
  border-radius: 8px;
  background: #f8fbff;
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(88px, 1fr));
  max-width: 100%;
  min-width: 0;
  padding: 12px;
}

.vendor-bonus-rule-box > span {
  color: #0b2f8a;
  font-size: 13px;
  font-weight: 950;
  grid-column: 1 / -1;
  text-transform: uppercase;
}

.vendor-bonus-rule-box div {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #fff;
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 8px 10px;
}

.vendor-bonus-rule-box strong {
  color: #64748b;
  font-size: 11px;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.vendor-bonus-rule-box b {
  color: #0f172a;
  font-size: 14px;
  overflow-wrap: anywhere;
}

@media (max-width: 1180px) {
  .vendor-workspace-nav,
  #vendor-page-view .vendor-workspace-nav {
    grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
  }
}

@media print {
  @page {
    margin: 7mm;
    size: A4 portrait;
  }

  body {
    background: #fff !important;
    color: #111827 !important;
  }

  body * {
    box-shadow: none !important;
  }

  .sidebar,
  .topbar,
  .import-progress-overlay,
  .vendor-portal-hero,
  .vendor-workspace-nav,
  .vendor-goals-actions,
  .table-status,
  .goal-help-icon,
  .vendor-page-bonus-header article,
  #vendor-workspace-goals > .chart-title-row,
  .vendor-workspace-panel:not(#vendor-workspace-goals),
  .view:not(#vendor-page-view) {
    display: none !important;
  }

  .app-shell,
  .vendor-shell,
  .content,
  #vendor-page-view,
  #vendor-workspace-goals {
    background: #fff !important;
    display: block !important;
    margin: 0 !important;
    max-width: none !important;
    min-height: 0 !important;
    overflow: visible !important;
    padding: 0 !important;
    width: 100% !important;
  }

  #vendor-workspace-goals,
  #vendor-workspace-goals.vendor-workspace-panel,
  #vendor-workspace-goals.vendor-portal-panel {
    border: 0 !important;
    display: block !important;
    overflow: visible !important;
    padding: 0 !important;
  }

  .vendor-print-cover {
    background: linear-gradient(135deg, #f8fbff, #eef4ff) !important;
    border: 1px solid #cbd8ea;
    border-left: 6px solid #facc15;
    border-radius: 8px;
    display: block !important;
    margin-bottom: 6px;
    padding: 7px 9px;
  }

  .vendor-print-brand {
    align-items: center;
    display: flex;
    gap: 8px;
    margin-bottom: 4px;
  }

  .vendor-print-brand img {
    height: 34px;
    width: 34px;
  }

  .vendor-print-brand strong {
    color: #071b3a;
    display: block;
    font-size: 12px;
  }

  .vendor-print-brand span {
    color: #475569;
    display: block;
    font-size: 8px;
    text-transform: uppercase;
  }

  .vendor-print-cover h1 {
    color: #071b3a;
    font-size: 13px;
    line-height: 1.12;
    margin: 0 0 4px;
  }

  .vendor-print-cover h2 {
    display: none !important;
  }

  .vendor-print-cover p {
    color: #1f2937;
    font-size: 7px;
    line-height: 1.16;
    margin: 2px 0;
    text-align: justify;
  }

  .vendor-print-page-number {
    color: transparent;
    display: block !important;
    font-size: 0;
    font-weight: 900;
    height: 0;
    line-height: 0;
    margin: 0;
    overflow: hidden;
    text-align: right;
  }

  .vendor-print-page-number-one {
    break-after: page;
    page-break-after: always;
  }

  .vendor-print-report-page {
    break-after: page;
    display: block !important;
    min-height: 260mm;
    page-break-after: always;
    position: relative;
  }

  .vendor-print-page-three {
    break-after: auto;
    min-height: 0 !important;
    page-break-after: auto;
  }

  .vendor-print-section-header {
    align-items: center;
    border: 1px solid #cbd8ea;
    border-left: 6px solid #facc15;
    border-radius: 8px;
    background: #f8fbff !important;
    display: flex !important;
    gap: 12px;
    margin-bottom: 10px;
    padding: 9px 12px;
  }

  .vendor-print-section-header img {
    height: 42px;
    width: 42px;
  }

  .vendor-print-section-header h3 {
    color: #071b3a;
    font-size: 18px;
    font-weight: 950;
    letter-spacing: 0;
    margin: 0;
  }

  .vendor-goals-summary,
  .vendor-page-goal-context,
  .vendor-sales-calc-grid {
    display: grid !important;
  }

  .vendor-goals-summary {
    gap: 3px !important;
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    margin-bottom: 4px !important;
  }

  .vendor-goals-summary article {
    border: 1px solid #d8e2f0 !important;
    border-radius: 6px !important;
    padding: 3px 4px !important;
  }

  .vendor-goals-summary article span {
    font-size: 9px !important;
  }

  .vendor-goals-summary article strong {
    font-size: 12px !important;
  }

  .vendor-page-goal-context {
    display: none !important;
  }

  .table-scroll {
    overflow: visible !important;
  }

  .vendor-page-goal-table,
  #vendor-page-view .vendor-page-goal-table,
  .vendor-about-table {
    min-width: 0 !important;
    width: 100% !important;
  }

  .vendor-page-goal-table th,
  .vendor-page-goal-table td,
  .vendor-about-table th,
  .vendor-about-table td {
    font-size: 9.6px !important;
    line-height: 1.18 !important;
    padding: 4px 5px !important;
  }

  .vendor-page-main-goal-table th:nth-child(1),
  .vendor-page-main-goal-table td:nth-child(1) {
    width: 30% !important;
  }

  .vendor-page-main-goal-table th:nth-child(2),
  .vendor-page-main-goal-table td:nth-child(2),
  .vendor-page-main-goal-table th:nth-child(3),
  .vendor-page-main-goal-table td:nth-child(3) {
    width: 13% !important;
  }

  .vendor-page-main-goal-table th:nth-child(4),
  .vendor-page-main-goal-table td:nth-child(4) {
    width: 10% !important;
  }

  .vendor-page-main-goal-table th:nth-child(5),
  .vendor-page-main-goal-table td:nth-child(5),
  .vendor-page-main-goal-table th:nth-child(6),
  .vendor-page-main-goal-table td:nth-child(6) {
    width: 8% !important;
  }

  .vendor-page-main-goal-table th:nth-child(7),
  .vendor-page-main-goal-table td:nth-child(7) {
    width: 18% !important;
  }

  .vendor-page-bonus-table th:nth-child(1),
  .vendor-page-bonus-table td:nth-child(1) {
    width: 31% !important;
  }

  .vendor-page-bonus-table th:nth-child(2),
  .vendor-page-bonus-table td:nth-child(2),
  .vendor-page-bonus-table th:nth-child(3),
  .vendor-page-bonus-table td:nth-child(3),
  .vendor-page-bonus-table th:nth-child(4),
  .vendor-page-bonus-table td:nth-child(4),
  .vendor-page-bonus-table th:nth-child(5),
  .vendor-page-bonus-table td:nth-child(5),
  .vendor-page-bonus-table th:nth-child(6),
  .vendor-page-bonus-table td:nth-child(6),
  .vendor-page-bonus-table th:nth-child(7),
  .vendor-page-bonus-table td:nth-child(7),
  .vendor-page-bonus-table th:nth-child(8),
  .vendor-page-bonus-table td:nth-child(8) {
    width: 7.5% !important;
  }

  .vendor-page-bonus-table th:nth-child(9),
  .vendor-page-bonus-table td:nth-child(9) {
    width: 16% !important;
  }

  .vendor-goal-total-row td {
    font-size: 12px !important;
    padding: 6px 7px !important;
  }

  .vendor-goal-total-row .commission-money {
    font-size: 13.5px !important;
  }

  .goal-progress {
    display: block !important;
    text-align: right !important;
  }

  .goal-progress span {
    display: none !important;
  }

  .goal-progress strong,
  #vendor-page-view .goal-progress strong {
    font-size: 10.5px !important;
    font-weight: 900 !important;
  }

  .vendor-page-bonus-section,
  .vendor-about-card,
  .vendor-rule-card {
    break-inside: auto;
    page-break-inside: auto;
  }

  .vendor-about-hero {
    display: none !important;
  }

  .vendor-page-bonus-section,
  .vendor-about-card {
    border: 1px solid #d8e2f0 !important;
    border-radius: 7px !important;
    margin-top: 3px !important;
    min-height: 0 !important;
    padding: 4px !important;
  }

  .vendor-page-bonus-header {
    background: #fff8d8 !important;
    border-radius: 6px !important;
    margin: -2px -2px 3px !important;
    padding: 4px 6px !important;
  }

  .vendor-page-bonus-header strong,
  .vendor-about-title h4 {
    font-size: 13.5px !important;
  }

  .vendor-page-bonus-header span {
    font-size: 10.5px !important;
  }

  .vendor-about-title,
  .vendor-rule-card ul {
    margin-bottom: 2px !important;
  }

  .vendor-rules-grid {
    column-count: 3 !important;
    column-gap: 5px !important;
    display: block !important;
  }

  .vendor-rule-card:first-child {
    column-span: none;
  }

  .vendor-bonus-rule-box {
    gap: 2px !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    margin: 2px 0 !important;
    padding: 3px !important;
  }

  .vendor-rule-card {
    border-left-width: 2px !important;
    break-inside: avoid;
    display: inline-block !important;
    margin: 0 0 3px !important;
    padding: 4px !important;
    page-break-inside: avoid;
    width: 100% !important;
  }

  .vendor-about-shell,
  .vendor-page-goals-about {
    display: block !important;
    gap: 0 !important;
    min-height: 0 !important;
  }

  .vendor-about-title-highlight {
    margin-bottom: 3px !important;
    min-height: 0 !important;
    padding: 4px 6px !important;
  }

  .vendor-rule-card strong {
    font-size: 7px !important;
    line-height: 1.08 !important;
  }

  .vendor-rule-card li,
  .vendor-sales-calc p,
  .vendor-about-card,
  .vendor-bonus-rule-box b {
    font-size: 8.7px !important;
    line-height: 1.18 !important;
  }

  .vendor-print-page-three .vendor-print-section-header {
    margin-bottom: 4px !important;
    padding: 5px 7px !important;
  }

  .vendor-print-page-three .vendor-print-section-header img {
    height: 30px !important;
    width: 30px !important;
  }

  .vendor-print-page-three .vendor-print-section-header h3 {
    font-size: 13px !important;
  }

  .vendor-print-page-three .vendor-about-card {
    padding: 4px !important;
  }

  .vendor-print-page-three .vendor-about-title h4 {
    font-size: 12px !important;
    line-height: 1.16 !important;
    margin: 0 !important;
  }

  .vendor-print-page-three .vendor-about-title .eyebrow,
  .vendor-rule-group h5,
  .vendor-rule-card span,
  .vendor-bonus-rule-box strong,
  .vendor-rule-meta span {
    font-size: 8.7px !important;
    line-height: 1.15 !important;
  }

  .vendor-rule-group,
  .vendor-rule-group + .vendor-rule-group {
    margin-top: 3px !important;
  }

  .vendor-rule-group h5 {
    margin: 0 0 2px !important;
  }

  .vendor-rule-meta {
    gap: 2px !important;
    margin: 2px 0 !important;
  }

  .vendor-sales-calc {
    margin: 2px 0 !important;
    padding: 3px !important;
  }

  .vendor-sales-calc strong {
    font-size: 9px !important;
  }

  .vendor-sales-calc-grid {
    gap: 2px !important;
    grid-template-columns: 1fr !important;
    margin: 2px 0 !important;
  }

  .vendor-sales-calc-grid span {
    font-size: 8.2px !important;
    padding: 3px !important;
  }

  #vendor-workspace-goals > .vendor-print-signature {
    display: none !important;
  }

  .vendor-print-signature-clone {
    display: block !important;
    margin-top: 5px;
    page-break-inside: avoid;
    text-align: center;
  }

  .vendor-print-signature p {
    color: #1f2937;
    font-size: 10.5px;
    margin-bottom: 14px;
    text-align: left;
  }

  .vendor-print-signature div {
    border-top: 1px solid #111827;
    margin: 0 auto 4px;
    width: 210px;
  }

  .vendor-print-signature strong,
  .vendor-print-signature span {
    color: #111827;
    display: block;
    font-size: 12px;
  }
}

.economic-group-panel {
  margin-bottom: 16px;
}

.economic-groups-saved-list {
  border-top: 1px solid #d8e2f0;
  margin-top: 16px;
  padding-top: 14px;
}

.economic-groups-saved-list h4 {
  color: #071b3a;
  font-size: 16px;
  margin: 0 0 10px;
}

.economic-group-layout {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 16px;
}

.economic-group-card {
  border: 1px solid #d8e2f0;
  border-radius: 10px;
  background: #f8fbff;
  display: grid;
  gap: 12px;
  padding: 16px;
}

.economic-group-card h4 {
  color: #071b3a;
  margin: 0;
}

.economic-client-fields {
  display: grid;
  gap: 10px;
  grid-template-columns: 2fr 90px 1.4fr;
}

.economic-client-fields input[readonly] {
  background: #eef4fb;
  color: #1f2f46;
  font-weight: 800;
}

.economic-group-table {
  min-width: 760px;
}

.ge-pill {
  border: 1px solid #d6a500;
  border-radius: 999px;
  background: linear-gradient(135deg, #ffe38a, #ffc928);
  color: #1f2937;
  cursor: pointer;
  font-size: 12px;
  font-weight: 950;
  min-height: 28px;
  padding: 4px 10px;
}

.ge-pill:hover {
  filter: brightness(0.96);
}

.vendor-goal-bonus-title {
  border-left: 4px solid #f5b400;
  color: #071b3a;
  font-size: 18px;
  margin: 18px 0 10px;
  padding-left: 10px;
}

@media (max-width: 980px) {
  .economic-group-layout,
  .economic-client-fields {
    grid-template-columns: 1fr;
  }
}

@media print {
  body.finance-summary-printing > * {
    visibility: hidden !important;
  }

  body.finance-summary-printing #finance-commission-summary-panel,
  body.finance-summary-printing #finance-commission-summary-panel * {
    visibility: visible !important;
  }

  body.finance-summary-printing #finance-commission-summary-panel {
    border: 0 !important;
    box-shadow: none !important;
    left: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    position: absolute !important;
    top: 0 !important;
    width: 100% !important;
  }

  body.finance-summary-printing .app-sidebar,
  body.finance-summary-printing .topbar,
  body.finance-summary-printing .routine-tabs,
  body.finance-summary-printing #finance-commission-summary-panel .vendor-actions,
  body.finance-summary-printing #finance-commission-summary-panel .finance-controls,
  body.finance-summary-printing #finance-summary-status {
    display: none !important;
  }
}
