:root {
  --sidebar-width: 286px;
  --sidebar-bg: #141b2b;
  --sidebar-bg-soft: #1d2434;
  --sidebar-line: rgba(255, 255, 255, 0.08);
  --sidebar-text: #a0a8b8;
  --sidebar-text-strong: #dfe6f4;
  --sidebar-active: #6f68ff;
  --page-bg: #edf2f8;
  --page-border: #d8dfeb;
  --surface: #ffffff;
  --surface-soft: #f7f9fd;
  --text: #46546d;
  --text-strong: #18233a;
  --muted: #7f8da5;
  --danger-soft: #ffd6da;
  --warn-soft: #ffeab4;
  --info-soft: #d8f0ff;
  --blue-soft: #e4edff;
  --shadow: 0 10px 30px rgba(31, 42, 66, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--page-bg);
  color: var(--text);
  font-family: "Segoe UI", "Aptos", sans-serif;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
a {
  touch-action: manipulation;
}

.skip-link {
  position: absolute;
  left: 20px;
  top: -48px;
  z-index: 50;
  padding: 10px 14px;
  border-radius: 12px;
  background: #10192a;
  color: #f4f7ff;
  font-weight: 700;
  transition: top 160ms ease;
}

.skip-link:focus-visible {
  top: 18px;
}

.app-top-line {
  height: 14px;
  background: #213f6d;
}

.shell-grid {
  display: grid;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  min-height: calc(100vh - 14px);
  transition: grid-template-columns 220ms ease;
}

.app-sidebar {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--sidebar-bg);
  color: var(--sidebar-text);
  border-right: 1px solid rgba(0, 0, 0, 0.12);
  overflow: hidden;
  transition: transform 220ms ease, opacity 220ms ease, border-color 220ms ease;
}

.sidebar-top {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 14px;
  min-height: 92px;
  padding: 18px 20px 10px;
}

.sidebar-section-list,
.sidebar-section-button,
.sidebar-chevron {
  display: none !important;
}

.sidebar-collapse-button,
.topbar-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--sidebar-text-strong);
  transition: background 180ms ease, border-color 180ms ease, transform 180ms ease;
}

.sidebar-collapse-button:hover,
.topbar-button:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.22);
}

.sidebar-collapse-button {
  flex: 0 0 auto;
}

.topbar-button {
  flex: 0 0 auto;
  color: #53607c;
  background: #f7f9fd;
  border-color: var(--page-border);
}

.sidebar-toggle-icon,
.sidebar-toggle-icon::before,
.sidebar-toggle-icon::after {
  display: block;
  width: 16px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transition: transform 180ms ease, opacity 180ms ease;
}

.sidebar-toggle-icon {
  position: relative;
}

.sidebar-toggle-icon::before,
.sidebar-toggle-icon::after {
  content: "";
  position: absolute;
  left: 0;
}

.sidebar-toggle-icon::before {
  top: -5px;
}

.sidebar-toggle-icon::after {
  top: 5px;
}

.sidebar-backdrop {
  position: fixed;
  inset: 14px 0 0;
  border: 0;
  background: rgba(9, 16, 31, 0.46);
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease;
  z-index: 24;
}

.sidebar-logo {
  display: block;
  width: min(100%, 136px);
  height: auto;
  aspect-ratio: 3 / 2;
  max-width: 100%;
  object-fit: contain;
  filter: drop-shadow(0 8px 18px rgba(3, 11, 28, 0.24));
}

.sidebar-nav {
  display: grid;
  gap: 2px;
  padding: 8px 6px 0;
  border-top: 1px solid var(--sidebar-line);
}

.sidebar-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  padding: 11px 15px;
  border-radius: 12px;
  color: var(--sidebar-text);
  font-size: 0.87rem;
  font-weight: 500;
  transition: background 180ms ease, color 180ms ease;
}

.sidebar-link::after {
  content: "";
  margin-left: auto;
}

.sidebar-link:hover {
  color: var(--sidebar-text-strong);
  background: rgba(255, 255, 255, 0.03);
}

.sidebar-link.is-active {
  color: var(--sidebar-active);
  background: rgba(111, 104, 255, 0.12);
}

.sidebar-link.is-active::before {
  content: "";
  position: absolute;
  left: -8px;
  top: 8px;
  bottom: 8px;
  width: 4px;
  border-radius: 999px;
  background: var(--sidebar-active);
}

.sidebar-link.is-active::after {
  display: none;
}

.sidebar-link.is-disabled {
  color: rgba(160, 168, 184, 0.5);
  background: rgba(255, 255, 255, 0.02);
  cursor: default;
}

.sidebar-link.is-disabled:hover {
  color: rgba(160, 168, 184, 0.5);
  background: rgba(255, 255, 255, 0.02);
}

.sidebar-link.is-disabled .nav-glyph {
  opacity: 0.5;
}

.sidebar-group {
  display: grid;
  gap: 2px;
}

.sidebar-link-group-label {
  margin-bottom: 0;
}

.sidebar-link-group-label::after {
  display: none;
}

.sidebar-group-toggle {
  width: 100%;
  border: 0;
  background: transparent;
  text-align: left;
  justify-content: flex-start;
}

.sidebar-link-group-label:hover {
  color: var(--sidebar-text);
  background: transparent;
}

.sidebar-group-toggle.is-expanded {
  color: var(--sidebar-text-strong);
}

.sidebar-group-chevron {
  margin-left: auto;
  flex: 0 0 auto;
  width: 7px;
  height: 7px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
  transition: transform 180ms ease;
  opacity: 0.72;
}

.sidebar-group-toggle.is-expanded .sidebar-group-chevron {
  transform: rotate(225deg);
}

.sidebar-submenu {
  display: grid;
  gap: 1px;
  max-height: 0;
  padding-left: 30px;
  overflow: hidden;
  opacity: 0;
  transition: max-height 200ms ease, opacity 160ms ease, padding-top 160ms ease;
}

.sidebar-submenu.is-expanded {
  max-height: 112px;
  opacity: 1;
}

.sidebar-sublink {
  display: flex;
  align-items: center;
  min-width: 0;
  padding: 7px 14px 7px 24px;
  border-radius: 10px;
  color: rgba(223, 230, 244, 0.82);
  font-size: 0.8rem;
  font-weight: 500;
  text-decoration: none;
  transition: background 180ms ease, color 180ms ease;
}

.sidebar-sublink:hover {
  color: var(--sidebar-active);
  background: rgba(111, 104, 255, 0.06);
}

.sidebar-sublink.is-active {
  color: var(--sidebar-active);
  background: rgba(111, 104, 255, 0.08);
}

.nav-glyph {
  position: relative;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  border: 2px solid currentColor;
  border-radius: 4px;
  opacity: 0.9;
}

.nav-glyph-home {
  border: 0;
  border-radius: 0;
}

.nav-glyph-home::before {
  content: "";
  position: absolute;
  left: 3px;
  top: 1px;
  width: 10px;
  height: 10px;
  border-top: 2px solid currentColor;
  border-left: 2px solid currentColor;
  transform: rotate(45deg);
  border-radius: 2px 0 0 0;
}

.nav-glyph-home::after {
  content: "";
  position: absolute;
  left: 3px;
  bottom: 1px;
  width: 10px;
  height: 8px;
  border: 2px solid currentColor;
  border-top: 0;
  border-radius: 0 0 3px 3px;
}

.nav-glyph-building::before,
.nav-glyph-building::after {
  content: "";
  position: absolute;
  background: currentColor;
}

.nav-glyph-building::before {
  left: 3px;
  top: 3px;
  width: 2px;
  height: 2px;
  box-shadow: 5px 0 0 currentColor, 10px 0 0 currentColor, 0 5px 0 currentColor, 5px 5px 0 currentColor, 10px 5px 0 currentColor, 0 10px 0 currentColor, 5px 10px 0 currentColor, 10px 10px 0 currentColor;
}

.nav-glyph-team {
  border-radius: 50%;
}

.nav-glyph-team::before,
.nav-glyph-team::after {
  content: "";
  position: absolute;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.nav-glyph-team::before {
  width: 7px;
  height: 7px;
  left: -6px;
  top: 5px;
  border-right: 0;
}

.nav-glyph-team::after {
  width: 7px;
  height: 7px;
  right: -6px;
  top: 5px;
  border-left: 0;
}

.nav-glyph-doc::before,
.nav-glyph-files::before,
.nav-glyph-bank::before,
.nav-glyph-calendar::before,
.nav-glyph-chat::before,
.nav-glyph-globe::before,
.nav-glyph-gear::before {
  content: "";
  position: absolute;
}

.nav-glyph-doc::before {
  right: -2px;
  top: -2px;
  width: 7px;
  height: 7px;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
  background: var(--sidebar-bg);
}

.nav-glyph-files::before {
  left: 4px;
  top: -5px;
  width: 12px;
  height: 14px;
  border: 2px solid currentColor;
  border-radius: 4px;
  background: var(--sidebar-bg);
}

.nav-glyph-bank {
  border-bottom: 0;
  border-radius: 0;
}

.nav-glyph-bank::before {
  left: -1px;
  top: -7px;
  width: 16px;
  height: 0;
  border-left: 9px solid transparent;
  border-right: 9px solid transparent;
  border-bottom: 6px solid currentColor;
}

.nav-glyph-calendar::before {
  left: 2px;
  right: 2px;
  top: 4px;
  height: 2px;
  background: currentColor;
}

.nav-glyph-chat::before {
  left: 3px;
  bottom: -5px;
  width: 7px;
  height: 7px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: skew(-25deg);
  background: var(--sidebar-bg);
}

.nav-glyph-globe {
  border-radius: 50%;
}

.nav-glyph-globe::before {
  inset: 3px 6px;
  border-left: 2px solid currentColor;
  border-right: 2px solid currentColor;
}

.nav-glyph-gear {
  border-radius: 50%;
}

.nav-glyph-gear::before {
  inset: 4px;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.sidebar-footer {
  margin-top: auto;
  padding: 18px 18px 16px;
  border-top: 1px solid var(--sidebar-line);
  text-align: center;
}

.sidebar-socials {
  display: flex;
  justify-content: center;
  gap: 22px;
  margin-bottom: 18px;
  color: #b8c2d4;
  font-size: 1.1rem;
  font-weight: 700;
}

.sidebar-footer p {
  margin: 0;
  color: #4e74ff;
  font-size: 0.95rem;
}

.sidebar-footer strong {
  display: block;
  margin-top: 4px;
  color: #ffffff;
  font-size: 0.95rem;
}

.app-stage {
  display: flex;
  flex-direction: column;
}

.app-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 88px;
  background: var(--surface);
  border-bottom: 1px solid var(--page-border);
}

.topbar-brand {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
  padding: 0 32px;
}

.topbar-company {
  color: #a6aec4;
  font-size: 1.02rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-variant-numeric: tabular-nums;
}

.topbar-actions {
  display: flex;
  align-items: stretch;
}

body.sidebar-collapsed .shell-grid {
  grid-template-columns: 0 minmax(0, 1fr);
}

body.sidebar-collapsed .app-sidebar {
  transform: translateX(calc(-1 * var(--sidebar-width)));
  opacity: 0;
  border-color: transparent;
  pointer-events: none;
}

body.sidebar-collapsed .topbar-button .sidebar-toggle-icon::before {
  transform: translateY(5px) rotate(45deg);
}

body.sidebar-collapsed .topbar-button .sidebar-toggle-icon {
  background: transparent;
}

body.sidebar-collapsed .topbar-button .sidebar-toggle-icon::after {
  transform: translateY(-5px) rotate(-45deg);
}

.topbar-user {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 24px;
  border-left: 1px solid var(--page-border);
  background: transparent;
}

.topbar-admin-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  margin: auto 18px auto 0;
  padding: 0 16px;
  border: 1px solid var(--page-border);
  border-radius: 999px;
  background: var(--surface-soft);
  color: #51617e;
  font-size: 0.9rem;
  font-weight: 700;
}

.topbar-avatar {
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: linear-gradient(135deg, #616d84, #2f3848);
  color: white;
  font-weight: 700;
  font-size: 1rem;
}

.topbar-user span {
  color: #697894;
  font-size: 0.96rem;
  font-weight: 600;
}

.topbar-user:hover {
  color: inherit;
}

.topbar-logout {
  display: flex;
  align-items: center;
  padding: 0 24px 0 0;
}

.topbar-logout-button,
.topbar-login-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--page-border);
  border-radius: 999px;
  background: var(--surface-soft);
  color: #51617e;
  font-size: 0.9rem;
  font-weight: 700;
}

.topbar-logout-button {
  cursor: pointer;
}

.ops-form {
  display: grid;
  gap: 18px;
  min-width: 0;
}

.ops-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) auto;
  gap: 16px;
  align-items: end;
  min-width: 0;
}

.ops-toolbar-field {
  display: grid;
  gap: 8px;
}

.ops-select,
.ops-readonly {
  min-height: 44px;
}

.ops-readonly {
  background: #f7f9fd;
}

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

.ops-submit {
  min-width: 160px;
  min-height: 44px;
}

.ops-search-form {
  display: grid;
  gap: 16px;
}

.ops-search-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto auto;
  gap: 14px;
  align-items: end;
}

.op-status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 118px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  white-space: nowrap;
}

.op-status-pending {
  background: #fff1cf;
  color: #8a5f11;
}

.op-status-loteada {
  background: #def6e4;
  color: #2f8a4b;
}

.op-status-transferido {
  background: #d8f0ff;
  color: #28699a;
}

.compact-empty-state {
  padding: 16px 18px;
}

.select-column {
  width: 44px;
  text-align: center;
}

.table-inline-note {
  margin-top: 4px;
  color: #8a93aa;
  font-size: 0.76rem;
}

.shell-main {
  padding: 36px 42px;
}

.workspace-card,
.panel-card,
.hero-panel,
.feed-card,
.kpi-card {
  background: var(--surface);
  border: 1px solid var(--page-border);
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.workspace-card {
  padding: 24px;
}

.workspace-header {
  padding: 6px 2px 18px;
}

.workspace-header-actions {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
}

.workspace-title {
  margin: 0;
  color: var(--text-strong);
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 0.96;
  text-wrap: balance;
}

.workspace-subtitle {
  margin: 16px 0 0;
  color: #556580;
  font-size: 1rem;
}

.announcement-bar {
  padding: 0;
  border: 1px solid var(--page-border);
  border-radius: 18px;
  background: var(--surface-soft);
}

.announcement-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px 10px;
  color: #415067;
  font-size: 0.98rem;
}

.announcement-dots {
  display: flex;
  gap: 6px;
}

.announcement-dots i {
  width: 12px;
  height: 12px;
  display: block;
  border-radius: 50%;
  background: #cfd7e2;
}

.announcement-dots i:first-child {
  background: #3c4c64;
}

.announcement-body {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 18px 18px;
}

.announcement-icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #cd242b;
  border: 2px solid #cd242b;
  font-weight: 800;
  flex: 0 0 auto;
}

.announcement-body p {
  margin: 0;
  color: #2f3846;
  font-size: 1rem;
  flex: 1;
}

.announcement-badge {
  padding: 8px 14px;
  border-radius: 999px;
  background: #ffd2d7;
  color: #dc3a47;
  font-weight: 700;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.summary-card {
  position: relative;
  padding: 20px 18px 18px;
  border: 1px solid var(--page-border);
  border-radius: 18px;
  background: var(--surface-soft);
}

.summary-card strong {
  display: block;
  margin-top: 44px;
  color: var(--text-strong);
  font-size: clamp(1.04rem, 1.32vw, 1.38rem);
  font-weight: 760;
  line-height: 1.05;
  letter-spacing: -0.045em;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}

.summary-card h3 {
  margin: 8px 0 0;
  color: #3d4b60;
  font-size: 0.94rem;
}

.summary-card p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.summary-pill {
  position: absolute;
  top: 18px;
  right: 18px;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 700;
}

.summary-pill-warn {
  background: var(--warn-soft);
  color: #cc7f08;
}

.summary-pill-danger {
  background: var(--danger-soft);
  color: #dd3f51;
}

.summary-pill-info {
  background: var(--info-soft);
  color: #1f79bc;
}

.panel-cluster {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(360px, 0.9fr);
  gap: 12px;
  margin-top: 14px;
}

.feed-card {
  overflow: hidden;
}

.feed-card-head {
  display: flex;
  align-items: center;
  min-height: 72px;
  padding: 0 22px;
  border-bottom: 1px solid var(--page-border);
  color: #435168;
}

.feed-card-head h3 {
  margin: 0;
  font-size: 1rem;
}

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

.feed-table th,
.feed-table td {
  padding: 18px 22px;
  border-bottom: 1px solid #e3e9f3;
  text-align: left;
}

.feed-table th {
  color: #71819b;
  font-size: 0.84rem;
  font-weight: 700;
  text-transform: uppercase;
}

.feed-table td {
  color: #2f3847;
  font-size: 1rem;
}

.feed-list {
  display: grid;
}

.feed-item {
  display: grid;
  grid-template-columns: 30px 1fr;
  gap: 14px;
  align-items: start;
  padding: 18px 22px;
  border-bottom: 1px solid #e3e9f3;
}

.feed-item-icon {
  color: #164f96;
  font-size: 1.1rem;
  line-height: 1.4;
}

.feed-item strong {
  display: block;
  color: #2f3847;
  font-size: 1rem;
}

.feed-item p {
  margin: 4px 0 0;
  color: #56657e;
  line-height: 1.45;
}

.empty-state,
.table-empty-cell {
  padding: 22px;
  color: #6b7c96;
  font-size: 0.95rem;
}

.empty-state {
  margin: 12px 0 0;
  border: 1px dashed var(--page-border);
  border-radius: 16px;
  background: var(--surface-soft);
}

.table-empty-cell {
  text-align: center;
}

.auth-shell {
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(90, 120, 189, 0.18), transparent 32%),
    linear-gradient(180deg, #10182a 0%, #17233a 100%);
}

.auth-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 28px;
}

.auth-card {
  width: min(920px, 100%);
  display: grid;
  grid-template-columns: minmax(280px, 1.05fr) minmax(320px, 0.95fr);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 28px;
  background: rgba(15, 22, 38, 0.9);
  box-shadow: 0 28px 80px rgba(4, 10, 22, 0.35);
}

.auth-brand {
  padding: 48px 44px;
  background: linear-gradient(160deg, rgba(87, 107, 165, 0.22), rgba(17, 24, 39, 0.14));
  color: #e8edf8;
}

.auth-logo {
  width: 220px;
  max-width: 100%;
  object-fit: contain;
}

.auth-kicker {
  margin: 28px 0 10px;
  color: #9cadcb;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.auth-brand h1 {
  margin: 0;
  font-size: 2.4rem;
  line-height: 0.96;
}

.auth-copy {
  margin: 18px 0 0;
  max-width: 420px;
  color: #b5c1d7;
  font-size: 1rem;
  line-height: 1.6;
}

.auth-form {
  display: grid;
  gap: 18px;
  padding: 48px 44px;
  background: rgba(255, 255, 255, 0.98);
}

.auth-field {
  display: grid;
  gap: 8px;
}

.auth-field label {
  color: #3c4c66;
  font-size: 0.9rem;
  font-weight: 700;
}

.auth-input {
  min-height: 48px;
  border-radius: 14px;
  font-size: 0.96rem;
}

.auth-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.auth-check {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #5b6a84;
  font-size: 0.9rem;
}

.auth-submit {
  min-height: 50px;
  border: 0;
  border-radius: 16px;
  background: linear-gradient(135deg, #415d9a, #243759);
  color: #fff;
  font-size: 0.96rem;
  font-weight: 700;
}

.auth-error {
  padding: 12px 14px;
  border-radius: 14px;
  background: #ffe5e7;
  color: #bf3346;
  font-size: 0.88rem;
}

.auth-error:empty {
  display: none;
}

.auth-field-error {
  color: #c13a4d;
  font-size: 0.84rem;
}

.user-profile-card {
  padding-bottom: 30px;
}

.user-admin-card,
.user-form-card {
  padding-bottom: 28px;
}

.users-flash {
  margin-bottom: 18px;
  padding: 14px 16px;
  border: 1px solid #cfe6d5;
  border-radius: 16px;
  background: #edf9f0;
  color: #2e7142;
  font-weight: 600;
}

.users-table-wrap {
  overflow-x: auto;
}

.users-table td strong,
.users-table td span {
  display: block;
}

.users-table td span {
  margin-top: 4px;
  color: #6f8099;
  font-size: 0.9rem;
}

.users-table-action {
  width: 92px;
  text-align: right;
}

.users-inline-link {
  color: #425e96;
  font-weight: 700;
}

.status-pill-success {
  background: #def6e4;
  color: #2f8a4b;
}

.status-pill-muted {
  background: #eceff5;
  color: #667891;
}

.user-form {
  display: grid;
  gap: 22px;
}

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

.user-form-options {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  padding: 6px 2px 0;
}

.user-form-actions {
  display: flex;
  justify-content: flex-end;
}

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

.profile-panel {
  display: grid;
  gap: 8px;
  padding: 18px 20px;
  border: 1px solid var(--page-border);
  border-radius: 18px;
  background: var(--surface-soft);
}

.profile-label {
  color: #6e7d96;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.profile-panel strong {
  color: var(--text-strong);
  font-size: 1.02rem;
}

.profile-security-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 18px;
  padding: 22px 24px;
  border: 1px solid #cfd9e9;
  border-radius: 20px;
  background: linear-gradient(135deg, #f8fbff 0%, #edf3fb 100%);
}

.profile-security-panel h3 {
  margin: 6px 0 4px;
  color: var(--text-strong);
  font-size: 1.12rem;
}

.profile-security-panel p {
  margin: 0;
  color: var(--muted);
}

.profile-password-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 148px;
  padding: 0 22px;
  white-space: nowrap;
}

.user-first-access-note {
  padding: 10px 14px;
  border: 1px solid #d7e2f1;
  border-radius: 12px;
  background: #f3f7fc;
  color: #52627c;
  font-size: 0.88rem;
  font-weight: 600;
}

.password-change-card {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 1.1fr);
  max-width: 980px;
  margin: 34px auto 0;
  padding: 0;
  overflow: hidden;
}

.password-change-intro {
  position: relative;
  padding: 44px 40px;
  background:
    radial-gradient(circle at 12% 12%, rgba(116, 151, 214, 0.3), transparent 34%),
    linear-gradient(145deg, #17243d, #263b61);
  color: #dce6f6;
}

.password-change-intro .eyebrow {
  margin-top: 24px;
  color: #9fb5da;
}

.password-change-intro h2 {
  margin: 10px 0 16px;
  color: #fff;
  font-size: clamp(1.8rem, 3vw, 2.55rem);
  line-height: 1.05;
}

.password-change-intro > p:not(.eyebrow) {
  margin: 0;
  color: #c4d0e3;
  line-height: 1.65;
}

.security-mark {
  position: relative;
  width: 58px;
  height: 64px;
  border: 2px solid #9db9e8;
  border-radius: 28px 28px 20px 20px;
  background: rgba(255, 255, 255, 0.06);
  clip-path: polygon(50% 0, 100% 17%, 92% 76%, 50% 100%, 8% 76%, 0 17%);
}

.security-mark span {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 9px;
  height: 18px;
  border-radius: 999px;
  background: #fff;
  transform: translate(-50%, -38%);
}

.security-mark span::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -8px;
  width: 18px;
  height: 18px;
  border: 3px solid #fff;
  border-bottom: 0;
  border-radius: 12px 12px 0 0;
  transform: translateX(-50%);
}

.password-guidance {
  display: grid;
  gap: 3px;
  margin-top: 28px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
}

.password-guidance span {
  color: #b9c8df;
  font-size: 0.88rem;
}

.password-change-form {
  display: grid;
  align-content: center;
  gap: 18px;
  padding: 44px;
  background: #fff;
}

.password-cancel-link {
  color: #61718c;
  font-size: 0.88rem;
  font-weight: 700;
  text-align: center;
}

.password-cancel-link:hover {
  color: #304b7c;
}

.sidebar-link:focus-visible {
  outline: 0;
  box-shadow: 0 0 0 3px rgba(111, 104, 255, 0.24);
}

.hero-panel,
.kpi-card,
.dashboard-grid,
.module-grid,
.token-grid,
.bar-chart,
.meter-stack,
.list-stack {
  margin-top: 14px;
}

.hero-panel,
.panel-card,
.kpi-card {
  padding: 22px;
}

.hero-copy h2,
.panel-head h3,
.kpi-card strong,
.module-card h4 {
  color: var(--text-strong);
}

.hero-text,
.kpi-card span,
.module-card span,
.list-row span,
.meter-copy span,
.hero-range span {
  color: var(--muted);
}

.eyebrow,
.kpi-card p,
.module-card p {
  color: #7b899f;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

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

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

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

.ops-dashboard-grid {
  grid-template-columns: 1fr;
}

.ops-dashboard-grid > .panel-card,
.ops-dashboard-grid > .panel-wide,
.ops-dashboard-grid > .panel-full {
  grid-column: 1 / -1;
}

.panel-card {
  grid-column: span 4;
  min-width: 0;
}

.panel-wide {
  grid-column: span 8;
  min-width: 0;
}

.panel-full {
  grid-column: 1 / -1;
  min-width: 0;
}

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

.panel-link,
.status-pill {
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--blue-soft);
  color: #526eaa;
  font-weight: 700;
}

.bar-chart {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
  gap: 10px;
  align-items: end;
}

.bar-item {
  display: grid;
  gap: 8px;
}

.bar-track {
  height: 160px;
  border-radius: 14px;
  background: #eef3fa;
  overflow: hidden;
}

.bar-fill {
  background: linear-gradient(180deg, #8db1ff, #5d7de7);
}

.list-stack,
.meter-stack,
.token-grid,
.module-grid {
  display: grid;
  gap: 10px;
}

.list-row,
.meter-row,
.token-card,
.module-card {
  padding: 14px;
  border: 1px solid var(--page-border);
  border-radius: 16px;
  background: var(--surface-soft);
}

.list-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.list-metric,
.meter-value {
  text-align: right;
}

.meter-row {
  display: grid;
  grid-template-columns: minmax(0, 180px) minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.meter-bar {
  height: 10px;
  border-radius: 999px;
  background: #e6ecf6;
  overflow: hidden;
}

.meter-fill {
  height: 100%;
  background: linear-gradient(90deg, #7a8cf7, #5369e1);
}

.token-grid,
.module-grid {
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.token-card em {
  display: block;
  margin-top: 8px;
  font-style: normal;
  color: #4a628f;
}

.table-shell {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
}

.signal-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

.signal-table th,
.signal-table td {
  padding: 11px 8px;
  border-bottom: 1px solid #e3e9f3;
  text-align: left;
}

.signal-table th {
  color: #72819c;
  font-size: 0.76rem;
  text-transform: uppercase;
}

.signal-table td {
  color: #2f3847;
  font-size: 0.92rem;
}

.ops-pending-table {
  min-width: 0;
}

.ops-pending-table th,
.ops-pending-table td {
  padding: 8px 4px;
  line-height: 1.15;
  white-space: nowrap;
}

.ops-pending-table th {
  font-size: 0.64rem;
  letter-spacing: -0.01em;
}

.ops-pending-table td {
  font-size: 0.76rem;
}

.ops-pending-table .select-column {
  width: 30px;
  padding-right: 5px;
  padding-left: 2px;
}

.ops-pending-table .ops-provider-cell {
  max-width: 270px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ops-pending-table .op-status-badge {
  min-width: 0;
  padding: 5px 8px;
  font-size: 0.66rem;
}

.kpi-stack {
  display: grid;
  gap: 8px;
}

.kpi-stack strong {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.2;
}

.lotes-table th,
.lotes-table td,
.lote-detail-table th,
.lote-detail-table td {
  padding: 10px 6px;
}

.lotes-table th,
.lote-detail-table th {
  font-size: 0.72rem;
}

.lotes-table td,
.lote-detail-table td {
  font-size: 0.86rem;
}

.amount-cell {
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.table-link {
  color: #375ea8;
  font-weight: 700;
}

.table-link:hover {
  color: #27457d;
}

.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.36s ease, transform 0.36s ease;
}

.is-ready .reveal {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1380px) {
  :root {
    --sidebar-width: 272px;
  }

  .shell-grid {
    grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  }

  .sidebar-logo {
    width: min(100%, 126px);
  }

  .shell-main {
    padding: 28px;
  }
}

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

  .app-sidebar {
    position: fixed;
    inset: 14px auto 0 0;
    width: min(92vw, 360px);
    z-index: 30;
    transform: translateX(-100%);
    opacity: 1;
    pointer-events: none;
    box-shadow: 0 24px 60px rgba(10, 19, 37, 0.34);
  }

  body.sidebar-collapsed .app-sidebar {
    transform: translateX(-100%);
  }

  body.sidebar-open .app-sidebar {
    transform: translateX(0);
    pointer-events: auto;
  }

  body.sidebar-open .sidebar-backdrop {
    opacity: 1;
    pointer-events: auto;
  }

  .panel-cluster,
  .summary-grid,
  .kpi-grid,
  .kpi-grid-three {
    grid-template-columns: 1fr 1fr;
  }

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

  .panel-card,
  .panel-wide {
    grid-column: auto;
  }

  .auth-card,
  .profile-grid,
  .user-form-grid {
    grid-template-columns: 1fr;
  }

  .ops-toolbar {
    grid-template-columns: 1fr 1fr;
  }

  .ops-search-grid {
    grid-template-columns: 1fr 1fr;
  }

  .ops-toolbar-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }
}

@media (max-width: 760px) {
  .shell-main {
    padding: 18px;
  }

  .sidebar-top {
    gap: 16px;
    min-height: 96px;
    padding: 18px 20px 12px;
  }

  .sidebar-logo {
    width: min(100%, 132px);
  }

  .summary-grid,
  .panel-cluster,
  .kpi-grid,
  .kpi-grid-three,
  .dashboard-grid {
    grid-template-columns: 1fr;
  }

  .app-topbar,
  .topbar-actions {
    flex-direction: column;
  }

  .topbar-brand,
  .topbar-company,
  .topbar-user {
    width: 100%;
  }

  .topbar-brand {
    justify-content: space-between;
    padding: 0 18px;
    min-height: 72px;
  }

  .topbar-company,
  .topbar-user {
    justify-content: center;
  }

  .topbar-user {
    border-left: 0;
    border-top: 1px solid var(--page-border);
    min-height: 64px;
  }

  .topbar-company {
    font-size: 0.84rem;
    letter-spacing: 0.12em;
    text-align: center;
  }

  .topbar-admin-link {
    width: calc(100% - 36px);
    margin: 16px 18px 0;
  }

  .topbar-logout {
    width: 100%;
    justify-content: center;
    padding: 14px 18px 18px;
    border-top: 1px solid var(--page-border);
  }

  .workspace-title {
    font-size: 2rem;
  }

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

  .auth-brand,
  .auth-form {
    padding: 32px 24px;
  }

  .ops-toolbar {
    grid-template-columns: 1fr;
  }

  .ops-search-grid {
    grid-template-columns: 1fr;
  }

  .ops-submit {
    width: 100%;
  }

  .password-change-card {
    grid-template-columns: 1fr;
    margin-top: 18px;
  }

  .password-change-intro,
  .password-change-form {
    padding: 30px 24px;
  }

  .profile-security-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .profile-password-link {
    width: 100%;
  }
}
