:root {
  /* iLiberty brand (aligned with Validador TISS / Central de Validação) */
  --brand-dark: #002b49;
  --brand-light: #00b6d6;
  --brand-primary: #00bf9a;
  --brand-secondary: #002b49;
  --primary-color: #00bf9a;
  --primary-hover: #059669;
  --secondary-color: #64748b;
  --success-color: #10b981;
  --error-color: #ef4444;
  --warning-color: #f59e0b;
  --background-color: #f8fafc;
  --surface-color: #ffffff;
  --border-color: #e2e8f0;
  --text-primary: #1e293b;
  --text-secondary: #64748b;

  /* Legacy names — map to brand so existing components keep working */
  --liberty-accent: var(--brand-primary);
  --liberty-accent-dark: var(--brand-dark);
  --liberty-accent-soft: rgb(0 182 214 / 0.2);
  --liberty-accent-deep: var(--brand-dark);
  --liberty-teal-mist: #e8f4f8;
  --liberty-ink: var(--text-primary);
  --liberty-text: var(--text-primary);
  --liberty-text-muted: var(--text-secondary);
  --liberty-bg: var(--surface-color);
  --liberty-surface: var(--background-color);
  --liberty-surface-warm: #f1f5f9;
  --liberty-border: var(--border-color);
  --liberty-sidebar-bg: #ffffff;
  --liberty-sidebar-border: #e5e7eb;
  --liberty-nav-active: #ffffff;
  --liberty-violet-note: var(--text-secondary);
  --liberty-radius: 12px;
  --liberty-radius-sm: 9px;
  --liberty-radius-lg: 16px;

  /* Elevation — soft, layered, faintly brand-tinted for a premium feel */
  --liberty-shadow:
    0 1px 2px rgb(15 23 42 / 0.04),
    0 1px 3px rgb(15 23 42 / 0.06);
  --liberty-shadow-md:
    0 1px 2px rgb(15 23 42 / 0.04),
    0 8px 24px -8px rgb(15 23 42 / 0.12);
  --liberty-shadow-lg:
    0 2px 4px rgb(15 23 42 / 0.04),
    0 24px 48px -16px rgb(0 43 73 / 0.18);
  --liberty-ring: 0 0 0 3px rgb(0 191 154 / 0.18);

  /* Surfaces & hairlines */
  --liberty-hairline: rgb(148 163 184 / 0.22);
  --liberty-canvas: #f6f8fb;
  --brand-primary-strong: #059f83;
}

/* -------------------------------------------------------------------------
   Standard action buttons (UniConecta / shell pattern)
   <button class="app-btn app-btn--secondary">…</button>
   <button class="app-btn app-btn--primary">…</button>
   ------------------------------------------------------------------------- */
.app-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  min-height: 2.25rem;
  box-sizing: border-box;
  border-radius: 7px;
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.25;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition:
    background-color 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease,
    filter 0.15s ease,
    box-shadow 0.15s ease;
  white-space: nowrap;
}

.app-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.app-btn .material-icons {
  font-size: 1.125rem;
  line-height: 1;
}

.app-btn--primary {
  background: linear-gradient(
    180deg,
    #00c8a3 0%,
    var(--brand-primary-strong) 100%
  );
  color: #fff;
  border-color: rgb(0 143 116 / 0.5);
  box-shadow:
    0 1px 1px rgb(15 23 42 / 0.06),
    0 2px 6px rgb(0 191 154 / 0.22),
    0 1px 0 rgb(255 255 255 / 0.25) inset;
}

.app-btn--primary:hover:not(:disabled) {
  filter: brightness(1.04);
  box-shadow:
    0 1px 1px rgb(15 23 42 / 0.06),
    0 4px 12px rgb(0 191 154 / 0.3),
    0 1px 0 rgb(255 255 255 / 0.25) inset;
}

.app-btn--secondary {
  background: linear-gradient(180deg, #fff 0%, #f8fafc 100%);
  color: var(--brand-dark);
  border-color: rgb(203 213 225 / 0.95);
  box-shadow: 0 1px 1px rgb(15 23 42 / 0.04);
}

.app-btn--secondary:hover:not(:disabled) {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.app-btn--ghost {
  background: transparent;
  color: var(--brand-dark);
  border-color: var(--border-color);
}

.app-btn--ghost:hover:not(:disabled) {
  background: #f8fafc;
}

.app-btn--danger {
  background: var(--error-color);
  color: #fff;
  border-color: rgb(239 68 68 / 0.45);
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.06);
}

.app-btn--danger:hover:not(:disabled) {
  filter: brightness(1.05);
}

.app-btn--success {
  background: var(--success-color);
  color: #fff;
  border-color: rgb(16 185 129 / 0.45);
}

.app-btn--success:hover:not(:disabled) {
  filter: brightness(1.05);
}

.app-btn--sm {
  padding: 0.35rem 0.65rem;
  min-height: auto;
  font-size: 0.8125rem;
  gap: 0.35rem;
}

.app-btn--sm .material-icons {
  font-size: 1rem;
}

.app-btn--icon {
  width: 2.35rem;
  min-width: 2.35rem;
  padding-inline: 0;
}

.app-btn--block {
  width: 100%;
}

.app-btn--align-start {
  justify-content: flex-start;
}

.app-btn--multiline {
  white-space: normal;
  min-height: auto;
  align-items: flex-start;
}

.app-btn--choice {
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  min-height: auto;
  white-space: normal;
  text-align: left;
}

/* Row of standard buttons (e.g. modal footers) */
.app-btn-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
* {
  margin: 0;
}
button {
  color: inherit;
}
button, [role="button"] {
  cursor: pointer;
}
code {
  font-family:
    ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono",
    "Courier New", monospace;
  font-size: 1em;
}
img,
svg {
  display: block;
}
img,
video {
  max-width: 100%;
  height: auto;
}

html {
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
  color: var(--liberty-text);
  font-family:
    "Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  height: 100%;
}

.app-body {
  margin: 0;
  min-height: 100%;
  min-height: 100dvh;
  height: 100%;
  background: var(--background-color);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* App shell: fixed navy header + sidebar + main — scroll lives in .app-main-wrap only */
.app-shell {
  display: flex;
  flex: 1;
  min-height: 0;
  flex-direction: column;
  overflow: hidden;
}

.app-top-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  padding-top: env(safe-area-inset-top, 0);
  height: calc(4rem + env(safe-area-inset-top, 0px));
  box-sizing: border-box;
  background:
    radial-gradient(
      120% 180% at 0% 0%,
      rgb(0 191 154 / 0.16),
      transparent 42%
    ),
    linear-gradient(180deg, #013655 0%, var(--brand-dark) 100%);
  color: #fff;
  border-bottom: 1px solid rgb(0 191 154 / 0.18);
  box-shadow:
    0 1px 0 rgb(255 255 255 / 0.04) inset,
    0 6px 20px -12px rgb(0 43 73 / 0.7);
}

.app-top-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  padding: 0 1rem;
  gap: 0.75rem;
}

.app-top-header-left {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 0.5rem;
}

.app-header-menu-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: -0.5rem;
  padding: 0.5rem;
  border-radius: 0.375rem;
  color: inherit;
  cursor: pointer;
}

.app-header-menu-btn:hover {
  background: rgb(255 255 255 / 0.1);
}

@media (min-width: 1024px) {
  .app-header-menu-btn {
    display: none;
  }
}

.app-header-brand {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: inherit;
}

/* Logo + separator + title (same pattern as Validador TISS / iLiberty apps) */
.app-header-logo {
  height: 2rem;
  width: auto;
  max-width: min(10rem, 34vw);
  object-fit: contain;
  object-position: left center;
  flex-shrink: 0;
  filter: brightness(0) invert(1);
}

.app-header-divider {
  display: none;
  width: 1px;
  height: 1.5rem;
  flex-shrink: 0;
  background: rgb(156 163 175);
}

@media (min-width: 640px) {
  .app-header-divider {
    display: block;
  }
}

.app-header-title {
  background-image: linear-gradient(to right, var(--brand-light), #ffffff);
  -webkit-background-clip: text;
  background-clip: text;
  font-weight: 600;
  font-size: 1rem;
  color: transparent;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (min-width: 1024px) {
  .app-header-title {
    font-size: 1.125rem;
  }
}

.app-top-header-right {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
}

/* Conta: menu no header (nome, papel, sair) */
.user-account {
  position: relative;
  min-width: 0;
}

.user-account--loading {
  min-height: 2.25rem;
  min-width: 8rem;
}

.user-account-skeleton {
  display: block;
  height: 2.25rem;
  width: 10rem;
  border-radius: 0.5rem;
  background: rgb(255 255 255 / 0.1);
  animation: user-skel 1.1s ease-in-out infinite alternate;
}

@keyframes user-skel {
  from {
    opacity: 0.55;
  }
  to {
    opacity: 0.9;
  }
}

.user-account-trigger {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  max-width: min(100%, 18rem);
  padding: 0.25rem 0.5rem 0.25rem 0.25rem;
  margin: 0;
  list-style: none;
  cursor: pointer;
  border-radius: 0.5rem;
  border: 1px solid transparent;
  color: inherit;
  background: transparent;
  font: inherit;
}

.user-account-trigger::-webkit-details-marker {
  display: none;
}

.user-account-trigger:hover {
  background: rgb(255 255 255 / 0.08);
  border-color: rgb(255 255 255 / 0.12);
}

.user-account-avatar {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 9999px;
  background: linear-gradient(135deg, rgb(37 99 235), rgb(14 165 233));
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.user-account-text {
  display: flex;
  min-width: 0;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
}

.user-account-name {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #fff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 12rem;
}

.user-account-role {
  font-size: 0.6875rem;
  font-weight: 500;
  color: rgb(186 230 253);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.user-account-chevron {
  flex-shrink: 0;
  font-size: 1.125rem !important;
  opacity: 0.85;
}

.user-account-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 0.35rem);
  min-width: 12rem;
  padding: 0.35rem;
  border-radius: 0.5rem;
  background: rgb(15 23 42);
  border: 1px solid rgb(51 65 85);
  box-shadow: 0 16px 40px rgb(0 0 0 / 0.45);
  z-index: 60;
}

.user-account-logout {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.65rem;
  border: none;
  border-radius: 0.375rem;
  background: transparent;
  color: rgb(248 250 252);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
}

.user-account-logout:hover {
  background: rgb(255 255 255 / 0.08);
}

.user-account-logout .material-icons {
  font-size: 1.125rem !important;
  opacity: 0.9;
}

.app-nav-loading {
  padding: 0.5rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.app-nav-loading-line {
  height: 0.65rem;
  border-radius: 0.25rem;
  background: rgb(228 231 236);
  animation: user-skel 1s ease-in-out infinite alternate;
}

.app-nav-loading-line--short {
  width: 66%;
}

/* Admin — usuários e matriz */
.admin-users-header {
  margin-bottom: 1rem;
}

.admin-users-lede {
  max-width: 42rem;
}

.admin-tabs {
  display: flex;
  gap: 0.25rem;
  margin-bottom: 1.25rem;
  padding: 0.2rem;
  border-radius: 0.5rem;
  background: rgb(241 245 249);
  width: fit-content;
}

.admin-tab {
  padding: 0.45rem 1rem;
  border: none;
  border-radius: 0.375rem;
  background: transparent;
  font-size: 0.875rem;
  font-weight: 600;
  color: rgb(71 85 105);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.admin-tab:hover {
  color: rgb(15 23 42);
}

.admin-tab--active {
  background: #fff;
  color: rgb(0 43 73);
  box-shadow: 0 1px 3px rgb(0 0 0 / 0.08);
}

.admin-alert {
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  margin-bottom: 1rem;
  font-size: 0.875rem;
}

.admin-alert--error {
  background: rgb(254 242 242);
  border: 1px solid rgb(252 165 165);
  color: rgb(127 29 29);
}

.admin-card {
  background: #fff;
  border: 1px solid rgb(228 231 236);
  border-radius: 0.75rem;
  padding: 1rem;
  box-shadow: 0 1px 3px rgb(0 0 0 / 0.04);
}

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

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.admin-table th,
.admin-table td {
  padding: 0.65rem 0.75rem;
  text-align: left;
  border-bottom: 1px solid rgb(241 245 249);
}

.admin-table th {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: rgb(100 116 139);
}

.admin-table-mono {
  font-family: ui-monospace, monospace;
  font-size: 0.8125rem;
  color: rgb(51 65 85);
}

.admin-invite-section {
  margin-bottom: 1.25rem;
}

.admin-invite-hint {
  font-size: 0.875rem;
  color: rgb(100 116 139);
  margin-bottom: 0.75rem;
  line-height: 1.45;
}

.admin-invite-hint code {
  font-size: 0.8125rem;
}

.admin-invite-heading {
  margin-bottom: 0.75rem;
}

.admin-invite-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: flex-end;
}

.admin-invite-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 12rem;
}

.admin-invite-field label {
  font-size: 0.8rem;
  color: rgb(100 116 139);
  font-weight: 500;
}

.admin-invite-field input,
.admin-invite-field select {
  padding: 0.45rem 0.6rem;
  border: 1px solid rgb(203 213 225);
  border-radius: 0.375rem;
  font: inherit;
}

.admin-inline-field {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}

.admin-inline-field input {
  min-width: 8rem;
  max-width: 16rem;
  padding: 0.35rem 0.5rem;
  border: 1px solid rgb(203 213 225);
  border-radius: 0.375rem;
  font: inherit;
  font-size: 0.875rem;
}

.admin-btn-small {
  padding: 0.35rem 0.65rem;
  font-size: 0.8rem;
  border-radius: 0.375rem;
  border: 1px solid rgb(203 213 225);
  background: #fff;
  color: rgb(30 41 59);
}

.admin-btn-small:hover:not(:disabled) {
  background: rgb(248 250 252);
}

.admin-btn-danger {
  color: rgb(220 38 38);
  border-color: rgb(252 165 165);
}

.admin-btn-danger:hover:not(:disabled) {
  background: rgb(254 242 242);
}

.admin-select {
  min-width: 11rem;
  padding: 0.35rem 0.5rem;
  border-radius: 0.375rem;
  border: 1px solid rgb(203 213 225);
  font-size: 0.875rem;
  background: #fff;
}

.admin-matrix {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.admin-matrix-card {
  padding: 1.25rem;
}

.admin-matrix-card-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.admin-matrix-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 600;
  color: rgb(15 23 42);
}

.admin-matrix-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.35rem;
}

@media (min-width: 720px) {
  .admin-matrix-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

.admin-matrix-label {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 0.65rem;
  row-gap: 0.1rem;
  align-items: start;
  padding: 0.5rem 0.65rem;
  border-radius: 0.5rem;
  border: 1px solid rgb(241 245 249);
  cursor: pointer;
}

.admin-matrix-label:hover {
  background: rgb(248 250 252);
}

.admin-matrix-label input[type="checkbox"] {
  grid-row: span 2;
  margin-top: 0.2rem;
}

.admin-matrix-key {
  font-family: ui-monospace, monospace;
  font-size: 0.75rem;
  color: rgb(37 99 235);
  font-weight: 600;
}

.admin-matrix-desc {
  font-size: 0.8125rem;
  color: rgb(51 65 85);
  grid-column: 2;
}

.admin-matrix-cat {
  grid-column: 2;
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: rgb(148 163 184);
}

.admin-page-loading,
.admin-page-denied {
  padding: 2rem;
  text-align: center;
  color: rgb(71 85 105);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

@keyframes um-spin {
  to {
    transform: rotate(360deg);
  }
}
.um-spin {
  animation: um-spin 1s linear infinite;
  display: inline-block;
}

/* ── Toast ─────────────────────────────────────────────────────────────────── */
.um-toast {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 9999;
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.75rem 1.125rem;
  border-radius: 0.625rem;
  font-size: 0.9rem;
  font-weight: 500;
  box-shadow: 0 8px 24px rgb(0 0 0 / 0.14);
  animation: um-toast-in 0.2s ease;
  max-width: 22rem;
}
@keyframes um-toast-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.um-toast--success {
  background: #002b49;
  color: #fff;
  border: 1px solid rgb(0 182 214 / 0.35);
}
.um-toast--error {
  background: rgb(254 242 242);
  color: rgb(185 28 28);
  border: 1px solid rgb(252 165 165);
}
.um-toast-icon {
  font-size: 1.1rem;
  flex-shrink: 0;
}

/* ── Tabs (icon variant) ────────────────────────────────────────────────────── */
.admin-tab-icon {
  font-size: 1rem;
  vertical-align: middle;
  margin-right: 0.3rem;
}

/* ── Invite card ────────────────────────────────────────────────────────────── */
.um-invite-card {
  padding: 1.5rem;
  margin-bottom: 1.25rem;
  border-left: 3px solid var(--brand-primary);
}
.um-invite-card-head {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.25rem;
}
.um-invite-card-icon {
  flex-shrink: 0;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.5rem;
  background: rgb(0 191 154 / 0.1);
  color: var(--brand-primary);
  display: flex;
  align-items: center;
  justify-content: center;
}
.um-invite-card-icon .material-icons {
  font-size: 1.25rem;
}
.um-invite-title {
  margin: 0 0 0.2rem;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}
.um-invite-subtitle {
  margin: 0;
  font-size: 0.8125rem;
  color: var(--text-secondary);
  line-height: 1.45;
}
.um-invite-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.875rem;
  align-items: flex-end;
}
.um-invite-actions {
  display: flex;
  align-items: flex-end;
  padding-bottom: 0;
}
.um-invite-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
}
.um-invite-btn .material-icons {
  font-size: 1rem;
}

/* ── Form primitives ────────────────────────────────────────────────────────── */
.um-field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  min-width: 13rem;
  flex: 1 1 13rem;
}
.um-label {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-secondary);
}
.um-required {
  color: var(--error-color);
}
.um-input {
  padding: 0.5rem 0.7rem;
  border: 1px solid var(--border-color);
  border-radius: var(--liberty-radius-sm);
  font-size: 0.9rem;
  color: var(--text-primary);
  background: #fff;
  transition: border-color 0.15s, box-shadow 0.15s;
  width: 100%;
}
.um-input:focus {
  outline: none;
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgb(0 191 154 / 0.15);
}
.um-input--error {
  border-color: var(--error-color);
}
.um-input--sm {
  padding: 0.35rem 0.55rem;
  font-size: 0.8125rem;
}
.um-select {
  padding: 0.5rem 0.7rem;
  border: 1px solid var(--border-color);
  border-radius: var(--liberty-radius-sm);
  font-size: 0.9rem;
  color: var(--text-primary);
  background: #fff;
  width: 100%;
}
.um-select--sm {
  padding: 0.3rem 0.5rem;
  font-size: 0.8125rem;
}
.um-field-error {
  font-size: 0.78rem;
  color: var(--error-color);
}

/* ── Users table card ───────────────────────────────────────────────────────── */
.um-users-card {
  padding: 0;
  overflow: hidden;
}
.um-users-card-head {
  padding: 1rem 1.25rem 0.75rem;
  border-bottom: 1px solid var(--border-color);
}
.um-section-title {
  margin: 0;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.um-count-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.4rem;
  height: 1.4rem;
  padding: 0 0.35rem;
  border-radius: 9999px;
  background: rgb(0 43 73 / 0.08);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--brand-dark);
}
.um-empty {
  padding: 2.5rem;
  text-align: center;
  color: var(--text-secondary);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}
.um-empty .material-icons {
  font-size: 2rem;
  opacity: 0.35;
}

/* ── Table ──────────────────────────────────────────────────────────────────── */
.um-table th {
  background: rgb(248 250 252);
}
.um-row:hover {
  background: rgb(248 250 252);
}
.um-th-actions, .um-td-actions {
  width: 3rem;
  text-align: center;
}

/* ── User cell ──────────────────────────────────────────────────────────────── */
.um-user-cell {
  display: flex;
  align-items: center;
  gap: 0.625rem;
}
.um-avatar {
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-dark), var(--brand-light));
  color: #fff;
  font-size: 0.6875rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  letter-spacing: 0.03em;
}
.um-inline-edit {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

/* ── Role cell ──────────────────────────────────────────────────────────────── */
.um-role-cell {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.role-badge {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 9999px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  white-space: nowrap;
}
.badge--admin {
  background: rgb(0 43 73 / 0.1);
  color: var(--brand-dark);
}
.badge--pm {
  background: rgb(0 191 154 / 0.12);
  color: #047857;
}
.badge--finance {
  background: rgb(245 158 11 / 0.12);
  color: #92400e;
}
.badge--default {
  background: rgb(100 116 139 / 0.1);
  color: var(--text-secondary);
}

/* ── Icon buttons ───────────────────────────────────────────────────────────── */
.um-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.875rem;
  height: 1.875rem;
  border-radius: 0.375rem;
  border: 1px solid var(--border-color);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: background 0.12s, color 0.12s, border-color 0.12s;
  flex-shrink: 0;
}
.um-icon-btn .material-icons {
  font-size: 1rem;
}
.um-icon-btn:hover:not(:disabled) {
  background: rgb(0 191 154 / 0.08);
  border-color: var(--brand-primary);
  color: var(--brand-primary);
}
.um-icon-btn--danger:hover:not(:disabled) {
  background: rgb(239 68 68 / 0.08);
  border-color: rgb(239 68 68);
  color: rgb(220 38 38);
}
.um-icon-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ── Permission groups ──────────────────────────────────────────────────────── */
.um-perm-group {
  margin-top: 1rem;
}
.um-perm-group-label {
  margin: 0 0 0.5rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-secondary);
}

.app-header-auth {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
  max-width: min(100%, 20rem);
}

.app-header-auth--muted {
  font-size: 0.875rem;
  color: rgb(203 213 225);
}

.app-header-auth-user {
  font-size: 0.8125rem;
  font-weight: 500;
  color: rgb(226 232 240);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 12rem;
}

@media (min-width: 640px) {
  .app-header-auth-user {
    max-width: 16rem;
  }
}

.app-header-auth-btn {
  flex-shrink: 0;
  padding: 0.375rem 0.75rem;
  border-radius: 0.375rem;
  border: 1px solid rgb(255 255 255 / 0.25);
  background: rgb(255 255 255 / 0.08);
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.app-header-auth-btn:hover {
  background: rgb(255 255 255 / 0.16);
  border-color: rgb(255 255 255 / 0.35);
}

.app-header-auth-btn--accent {
  border-color: rgb(96 165 250 / 0.6);
  background: rgb(37 99 235 / 0.35);
}

.app-header-auth-btn--accent:hover {
  background: rgb(37 99 235 / 0.5);
}

.auth-callback-shell {
  display: flex;
  min-height: 100vh;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background: linear-gradient(160deg, rgb(15 23 42) 0%, rgb(0 43 73) 100%);
  color: #fff;
}

.auth-callback-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  padding: 2.5rem 2rem;
  border-radius: 0.75rem;
  background: rgb(255 255 255 / 0.06);
  border: 1px solid rgb(255 255 255 / 0.12);
  box-shadow: 0 20px 50px rgb(0 0 0 / 0.35);
  min-width: 18rem;
}

.auth-callback-mark {
  filter: brightness(0) invert(1);
  opacity: 0.9;
}

.auth-callback-message {
  margin: 0;
  font-size: 1rem;
  text-align: center;
  display: flex;
  align-items: center;
  gap: 0.625rem;
  color: rgb(203 213 225);
}

.auth-callback-message--error {
  color: rgb(252 165 165);
}

.auth-callback-retry {
  font-size: 0.875rem;
  color: var(--brand-light);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.auth-callback-retry:hover {
  color: #fff;
}

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

.auth-callback-spinner {
  display: inline-block;
  width: 1rem;
  height: 1rem;
  border: 2px solid rgb(255 255 255 / 0.25);
  border-top-color: var(--brand-light);
  border-radius: 50%;
  animation: spin 0.75s linear infinite;
  flex-shrink: 0;
}

.login-page {
  display: flex;
  min-height: 100vh;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background: linear-gradient(160deg, rgb(15 23 42) 0%, rgb(0 43 73) 100%);
  color: #fff;
}

.login-page-card {
  width: 100%;
  max-width: 22rem;
  padding: 2rem 1.75rem;
  border-radius: 0.75rem;
  background: rgb(255 255 255 / 0.06);
  border: 1px solid rgb(255 255 255 / 0.12);
  box-shadow: 0 20px 50px rgb(0 0 0 / 0.35);
}

.login-page-logo {
  display: block;
  height: 2.5rem;
  width: auto;
  margin: 0 auto 1.25rem;
  filter: brightness(0) invert(1);
}

.login-page-title {
  margin: 0 0 0.5rem;
  font-size: 1.375rem;
  font-weight: 600;
  text-align: center;
}

.login-page-hint {
  margin: 0 0 1.5rem;
  font-size: 0.875rem;
  line-height: 1.45;
  text-align: center;
  color: rgb(203 213 225);
}

.login-page-actions {
  display: flex;
  justify-content: center;
}

.login-page-error {
  margin: 0;
  font-size: 0.875rem;
  color: rgb(252 165 165);
  text-align: center;
}

.app-header-auth--standalone {
  flex-direction: column;
  width: 100%;
  max-width: none;
}

.app-header-auth--standalone .app-header-auth-btn--accent {
  width: 100%;
  justify-content: center;
  padding: 0.5rem 1rem;
}

.app-header-data-pill {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 9999px;
  background: rgb(255 255 255 / 0.12);
  color: rgb(226 232 240);
  transition: background 0.15s ease;
}

.app-header-data-pill:hover {
  background: rgb(255 255 255 / 0.2);
}

.app-header-data-pill-icon {
  font-size: 1.125rem !important;
  opacity: 0.95;
}

.app-header-meta {
  display: none;
  font-size: 0.875rem;
  font-weight: 500;
  color: rgb(226 232 240);
}

@media (min-width: 640px) {
  .app-header-meta {
    display: block;
    max-width: 14rem;
    text-align: right;
  }
}

.app-below-header {
  display: flex;
  flex: 1;
  min-width: 0;
  min-height: 0;
  padding-top: calc(4rem + env(safe-area-inset-top, 0px));
  position: relative;
  overflow: hidden;
}

.app-nav-backdrop {
  display: none;
  position: fixed;
  top: calc(4rem + env(safe-area-inset-top, 0px));
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  background: rgb(0 0 0 / 0.5);
  cursor: pointer;
}

@media (max-width: 1023px) {
  #app-nav-toggle:checked ~ .app-below-header .app-nav-backdrop {
    display: block;
  }
}

/* Sidebar — column height follows shell (main scrolls separately; nav scrolls inside if needed) */
.app-sidebar {
  flex-shrink: 0;
  width: 15.75rem;
  align-self: stretch;
  min-height: 0;
  background: rgb(252 252 253);
  border-right: 1px solid rgb(228 231 236);
}

.app-sidebar-inner {
  display: flex;
  height: 100%;
  min-height: 0;
  flex-direction: column;
  padding: 1rem 1rem 1.25rem;
  padding-left: max(1rem, env(safe-area-inset-left, 0px));
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

@media (min-width: 640px) {
  .app-sidebar-inner {
    padding: 1.25rem 1.25rem 1.5rem;
    padding-left: max(1.25rem, env(safe-area-inset-left, 0px));
  }
}

.custom-scrollbar::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
.custom-scrollbar::-webkit-scrollbar-track {
  background: transparent;
}
.custom-scrollbar::-webkit-scrollbar-thumb {
  background-color: rgb(156 163 175 / 0.5);
  border-radius: 4px;
}
.custom-scrollbar::-webkit-scrollbar-thumb:hover {
  background-color: rgb(107 114 128 / 0.8);
}

.app-sidebar-drawer-head {
  display: none;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.app-sidebar-drawer-title {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
}

.app-sidebar-drawer-close {
  display: flex;
  padding: 0.25rem;
  color: rgb(107 114 128);
  cursor: pointer;
  border-radius: 0.25rem;
}

.app-sidebar-drawer-close:hover {
  color: var(--text-primary);
}

@media (max-width: 1023px) {
  .app-sidebar {
    position: fixed;
    top: calc(4rem + env(safe-area-inset-top, 0px));
    left: 0;
    z-index: 50;
    width: min(19rem, 100vw - 1.5rem);
    max-width: 90vw;
    height: calc(100dvh - 4rem - env(safe-area-inset-top, 0px));
    max-height: calc(100dvh - 4rem - env(safe-area-inset-top, 0px));
    align-self: auto;
    box-shadow:
      0 20px 25px -5px rgb(0 0 0 / 0.1),
      0 8px 10px -6px rgb(0 0 0 / 0.1);
    transform: translateX(-100%);
    transition: transform 0.2s ease-out;
  }

  #app-nav-toggle:checked ~ .app-below-header .app-sidebar {
    transform: translateX(0);
  }

  .app-sidebar-inner {
    position: relative;
    top: 0;
    height: 100%;
    max-height: 100%;
    padding-bottom: max(1.25rem, env(safe-area-inset-bottom, 0px));
  }

  .app-sidebar-drawer-head {
    display: flex;
  }

  .app-below-header {
    flex: 1;
    min-width: 0;
  }
}

@media (min-width: 1024px) {
  .app-sidebar {
    transform: none !important;
    height: auto;
    max-height: none;
  }
}

.app-sidebar-product {
  margin: 0 0 1rem;
  padding-left: 0.15rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-secondary);
}

@media (max-width: 1023px) {
  .app-sidebar-product {
    margin-top: 0;
  }
}

.app-sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 0;
  flex: 1;
}

/*
 * Navegação por seções (referência: dashboards SaaS — seção + links,
 * sem acordeão: hierarquia por tipografia e espaçamento).
 */
.app-nav-section {
  margin: 0;
  padding: 0;
}

.app-nav-section--spaced {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgb(237 240 244);
}

.app-nav-section-title {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0 0 0.5rem;
  padding: 0 0.125rem;
  font: inherit;
  font-weight: 600;
}

.app-nav-section-title-icon {
  font-size: 1rem !important;
  width: 1rem;
  height: 1rem;
  color: rgb(148 163 184);
  flex-shrink: 0;
  opacity: 0.9;
}

.app-nav-section-title-text {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgb(100 116 139);
  line-height: 1.2;
}

/* Collapsible section header (rendered as a button). */
.app-nav-section-toggle {
  width: 100%;
  background: transparent;
  border: 0;
  cursor: pointer;
  text-align: left;
  border-radius: 0.5rem;
  padding: 0.25rem 0.25rem;
  transition: background-color 0.15s ease;
}

.app-nav-section-toggle:hover {
  background: rgb(241 245 249);
}

.app-nav-section-toggle:focus-visible {
  outline: 2px solid rgb(96 165 250);
  outline-offset: 1px;
}

.app-nav-section-chevron {
  margin-left: auto;
  font-size: 1.125rem !important;
  width: 1.125rem;
  height: 1.125rem;
  color: rgb(148 163 184);
  flex-shrink: 0;
  transition: transform 0.18s ease;
}

.app-nav-section--collapsed .app-nav-section-chevron {
  transform: rotate(-90deg);
}

.app-nav-section-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
}

.app-nav-link {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.5rem 0.625rem;
  margin: 0;
  border-radius: 0.5rem;
  text-decoration: none;
  color: rgb(51 65 85);
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.35;
  border: 1px solid transparent;
  transition:
    background 0.12s ease,
    color 0.12s ease,
    border-color 0.12s ease,
    box-shadow 0.12s ease;
}

@media (max-width: 1023px) {
  .app-nav-link {
    min-height: 2.625rem;
  }
}

.app-nav-link:hover {
  background: rgb(255 255 255);
  border-color: rgb(226 232 240);
  color: rgb(15 23 42);
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.04);
}

.app-nav-link:focus-visible {
  outline: 2px solid rgb(0 182 214 / 0.45);
  outline-offset: 1px;
}

.app-nav-link--active {
  background: rgb(255 255 255);
  border-color: rgb(0 191 154 / 0.35);
  color: var(--brand-dark);
  font-weight: 600;
  box-shadow: 0 0 0 1px rgb(0 191 154 / 0.12), 0 1px 3px rgb(0 43 73 / 0.06);
}

.app-nav-link-icon {
  font-size: 1.125rem !important;
  flex-shrink: 0;
  color: rgb(148 163 184);
  transition: color 0.12s ease;
}

.app-nav-link:hover .app-nav-link-icon {
  color: rgb(100 116 139);
}

.app-nav-link--active .app-nav-link-icon {
  color: var(--brand-primary);
}

.app-nav-link-label {
  min-width: 0;
  flex: 1;
}

.app-sidebar-link {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.5rem 0.75rem;
  border-radius: 0.375rem;
  text-decoration: none;
  color: rgb(55 65 81);
  border: 2px solid transparent;
  border-right: 2px solid transparent;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

/* Drawer / narrow screens: comfortable tap targets (mobile-first touch) */
@media (max-width: 1023px) {
  .app-sidebar-link {
    align-items: center;
    min-height: 2.75rem;
    padding-top: 0.625rem;
    padding-bottom: 0.625rem;
  }
}

.app-sidebar-link:hover {
  background: rgb(249 250 251);
  color: rgb(17 24 39);
}

.app-sidebar-link--active {
  background: var(--liberty-nav-active);
  color: rgb(29 78 216);
  border-right-color: rgb(29 78 216);
}

.app-sidebar-link-icon {
  font-size: 1.25rem;
  flex-shrink: 0;
  margin-top: 0.1rem;
  color: rgb(100 116 139);
}

.app-sidebar-link--active .app-sidebar-link-icon {
  color: rgb(29 78 216);
}

.app-sidebar-link-text {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 0.1rem;
}

.app-sidebar-link-label {
  font-size: 0.875rem;
  font-weight: 500;
}

.app-sidebar-link--active .app-sidebar-link-label {
  font-weight: 600;
}

.app-sidebar-link-desc {
  font-size: 0.72rem;
  line-height: 1.35;
  color: var(--liberty-text-muted);
}

.app-sidebar-link--active .app-sidebar-link-desc {
  color: rgb(29 78 216 / 0.85);
}

.app-sidebar-footer {
  margin-top: auto;
  padding-top: 2rem;
  border-top: 1px solid var(--liberty-sidebar-border);
}

.app-sidebar-footnote {
  font-size: 0.75rem;
  line-height: 1.5;
  color: rgb(107 114 128);
}

.app-sidebar-copyright {
  margin-top: 0.25rem;
}

.app-main-wrap {
  flex: 1;
  min-width: 0;
  min-height: 0;
  width: 100%;
  display: flex;
  flex-direction: column;
  background: var(--liberty-canvas);
  overflow-x: auto;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding-bottom: env(safe-area-inset-bottom, 0);
  padding-right: env(safe-area-inset-right, 0);
}

/*
 * Page shells — mobile-first spacing.
 * Use `page-shell page-shell--fluid` on every main screen (Cockpit, Config, Relatórios,
 * Capacidade, Novo quadro, Financeiro) so content uses the full main column with the same
 * horizontal padding (`clamp`) on large viewports.
 */
.page-shell {
  flex: 1;
  min-width: 0;
  padding: 1rem 1rem 1.5rem;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
}

@media (min-width: 640px) {
  .page-shell {
    padding: 1.25rem 1.25rem 2rem;
  }
}

/** @deprecated Prefer `page-shell--fluid` so all main screens match Cockpit / Config width. */
.page-shell--config {
  max-width: 960px;
}

.config-page-lede {
  max-width: 48rem;
}

.config-inline-code {
  font-size: 0.88em;
  padding: 0.12rem 0.35rem;
  border-radius: 4px;
  background: var(--liberty-surface-warm);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

.board-sync-api-line {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin: 0 0 1rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--liberty-radius-sm);
  font-size: 0.8125rem;
  line-height: 1.45;
}

.board-sync-api-line--ok {
  border: 1px solid rgb(167 243 208);
  background: rgb(240 253 244);
  color: rgb(20 83 45);
}

.board-sync-api-line--bad {
  border: 1px solid rgb(254 202 202);
  background: rgb(254 242 242);
  color: rgb(127 29 29);
}

.board-sync-api-icon {
  font-size: 1.25rem;
  flex-shrink: 0;
  line-height: 1.2;
}

.board-sync-help {
  margin: 1.25rem 0 0;
  padding: 0.65rem 0.9rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: rgb(248 250 252);
}

.board-sync-help summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 0.8125rem;
  color: var(--liberty-accent-deep);
}

.board-sync-help-lede {
  margin: 0.65rem 0 0.45rem;
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--liberty-text-muted);
}

.board-sync-help-list {
  margin: 0;
  padding-left: 1.15rem;
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--liberty-text);
}

/** @deprecated Prefer `page-shell--fluid` for the same usable width as Cockpit on large viewports. */
.page-shell--wide {
  max-width: 1400px;
}

/** Cockpit / wide dashboards: use full main column width (no arbitrary max-width cap). */
.page-shell--fluid {
  display: flex;
  flex-direction: column;
  max-width: none;
  width: 100%;
  box-sizing: border-box;
  padding-left: clamp(1rem, 2.5vw, 2rem);
  padding-right: clamp(1rem, 2.5vw, 2rem);
}

.config-page {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.page-header {
  margin-bottom: 1.25rem;
}

.page-title {
  font-size: 1.25rem;
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--liberty-text);
}

@media (min-width: 640px) {
  .page-title {
    font-size: 1.5rem;
    line-height: 1.2;
  }
}

.page-lede {
  margin-top: 0.4rem;
  max-width: 40rem;
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--liberty-text-muted);
}

.report-inline-link {
  color: var(--liberty-accent-deep);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid rgb(110 176 204 / 0.45);
}

.report-inline-link:hover {
  color: var(--liberty-accent-dark);
  border-bottom-color: var(--liberty-accent-dark);
}

/* Quadros sincronizados (island) */
.board-sync {
  margin-bottom: 1.25rem;
  border-radius: var(--liberty-radius);
  border: 1px solid var(--liberty-border);
  background: var(--liberty-bg);
  box-shadow: var(--liberty-shadow);
  overflow: hidden;
}

.board-sync-toggle {
  display: flex;
  width: 100%;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.15rem;
  padding: 0.85rem 1rem;
  border: none;
  background: linear-gradient(
    180deg,
    rgb(110 176 204 / 0.08) 0%,
    var(--liberty-bg) 100%
  );
  text-align: left;
  font: inherit;
  cursor: pointer;
}

.board-sync-toggle-title {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--liberty-text);
}

.board-sync-toggle-hint {
  font-size: 0.8125rem;
  color: var(--liberty-text-muted);
}

.board-sync-panel {
  padding: 0 1rem 1rem;
  border-top: 1px solid var(--liberty-border);
}

.board-sync-lede {
  margin: 0.85rem 0;
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--liberty-text-muted);
  max-width: 52rem;
}

.board-sync-muted {
  font-size: 0.875rem;
  color: var(--liberty-text-muted);
}

.board-sync-alert {
  margin: 0.5rem 0;
  padding: 0.65rem 0.75rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid #fecaca;
  background: #fef2f2;
  color: #991b1b;
  font-size: 0.875rem;
}

.board-sync-list {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
}

.board-sync-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.35rem 0.75rem;
  align-items: start;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--liberty-border);
  font-size: 0.875rem;
}

.board-sync-row-body {
  min-width: 0;
}

.board-sync-row:last-child {
  border-bottom: none;
}

.board-sync-row-main {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.75rem;
}

.board-sync-name {
  color: var(--liberty-text);
  font-weight: 500;
}

.board-sync-id {
  font-size: 0.75rem;
  color: var(--liberty-text-muted);
  font-variant-numeric: tabular-nums;
}

.board-sync-status {
  display: inline-block;
  padding: 0.12rem 0.45rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.board-sync-status--ok {
  background: rgb(110 176 204 / 0.25);
  color: var(--liberty-accent-dark);
}

.board-sync-status--warn {
  background: #fef3c7;
  color: #92400e;
}

.board-sync-status--err {
  background: #fee2e2;
  color: #991b1b;
}

.board-sync-status--pending {
  background: #f1f5f9;
  color: #64748b;
}

.board-sync-warnings {
  margin: 0.35rem 0 0;
  padding-left: 1.1rem;
  font-size: 0.8125rem;
  color: #92400e;
}

.board-sync-error-detail {
  margin: 0.35rem 0 0;
  font-size: 0.8125rem;
  color: #991b1b;
}

.board-sync-remove {
  border: 1px solid var(--liberty-border);
  border-radius: var(--liberty-radius-sm);
  background: var(--liberty-bg);
  padding: 0.35rem 0.65rem;
  font-size: 0.8125rem;
  color: var(--liberty-text-muted);
}

.board-sync-remove:hover {
  border-color: #fecaca;
  color: #991b1b;
}

.board-sync-add {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.board-sync-field {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--liberty-text);
}

.board-sync-field input {
  min-width: 12rem;
  border: 1px solid var(--liberty-border);
  border-radius: var(--liberty-radius-sm);
  padding: 0.45rem 0.6rem;
  font-size: 0.875rem;
}

.board-sync-footnote {
  margin: 0;
  font-size: 0.75rem;
  color: var(--liberty-text-muted);
}

.board-sync-code {
  font-size: 0.7rem;
  padding: 0.1rem 0.25rem;
  border-radius: 4px;
  background: var(--liberty-surface);
}

/* Column mapping health (Configurações) */
.column-health {
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid var(--liberty-border);
}

.column-health-panel {
  max-width: 52rem;
}

.column-health-title {
  margin: 0 0 0.5rem;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--liberty-text);
}

.column-health-lede,
.column-health-persist {
  margin: 0 0 0.75rem;
  font-size: 0.875rem;
  line-height: 1.55;
  color: var(--liberty-text-muted);
}

.column-health-code {
  font-size: 0.75rem;
  padding: 0.1rem 0.3rem;
  border-radius: 4px;
  background: var(--liberty-surface-warm);
  color: var(--liberty-text);
}

.column-health-muted {
  font-size: 0.8125rem;
  color: var(--liberty-text-muted);
}

.column-health-alert {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
  margin: 0 0 1rem;
  padding: 0.75rem 1rem;
  border-radius: var(--liberty-radius);
  font-size: 0.8125rem;
  line-height: 1.45;
}

.column-health-alert-icon {
  font-size: 1.25rem !important;
  flex-shrink: 0;
  margin-top: 0.05rem;
}

.column-health-alert--critical {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #7f1d1d;
}

.column-health-alert--warn {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #78350f;
}

.column-health-alert--ok {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
}

.column-health-alert--err {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
}

.column-health-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.column-health-boards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.column-health-card {
  border-radius: var(--liberty-radius);
  border: 1px solid var(--liberty-border);
  padding: 1rem 1.1rem;
  background: var(--liberty-bg);
}

.column-health-card--ok {
  border-color: rgb(167 243 208 / 0.8);
}

.column-health-card--warn {
  border-color: #fde68a;
  background: #fffbeb;
}

.column-health-card--err {
  border-color: #fecaca;
  background: #fef2f2;
}

.column-health-card-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}

.column-health-board-name {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--liberty-text);
}

.column-health-board-id {
  font-size: 0.75rem;
  color: var(--liberty-text-muted);
}

.column-health-source {
  margin: 0 0 0.5rem;
  font-size: 0.8125rem;
  color: var(--liberty-text-muted);
}

.column-health-admin-badge {
  display: inline-block;
  margin-left: 0.35rem;
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  background: rgb(0 182 214 / 0.12);
  font-size: 0.72rem;
  color: var(--brand-dark);
}

.column-health-resolve-err {
  margin: 0 0 0.5rem;
  font-size: 0.8125rem;
  color: #991b1b;
}

.column-health-issues-details {
  margin: 0 0 0.65rem;
}

.column-health-issues-details .column-health-issues {
  margin-top: 0.5rem;
}

.column-health-issues-summary {
  cursor: pointer;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--brand-dark);
}

.column-health-issues {
  margin: 0 0 0.65rem;
  padding-left: 1.1rem;
  font-size: 0.8125rem;
}

.column-health-issue {
  margin-bottom: 0.35rem;
}

.column-health-issue--err {
  color: #7f1d1d;
}

.column-health-issue--warn {
  color: #92400e;
}

.column-health-issue-label {
  display: inline-block;
  min-width: 2.5rem;
  font-weight: 600;
  margin-right: 0.35rem;
}

.column-health-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.column-health-actions .btn-primary,
.column-health-actions .btn-secondary {
  padding: 0.4rem 0.75rem;
  font-size: 0.8125rem;
}

.btn-primary {
  border: none;
  border-radius: var(--liberty-radius-sm);
  background: #1e293b;
  color: #fff;
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.06);
  transition:
    background 0.15s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

.btn-primary:hover {
  background: #0f172a;
  transform: translateY(-1px);
  box-shadow:
    0 10px 15px -3px rgb(0 0 0 / 0.1),
    0 4px 6px -2px rgb(0 0 0 / 0.05);
}

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

.btn-primary:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.btn-secondary {
  border: 1px solid var(--liberty-border);
  border-radius: var(--liberty-radius-sm);
  background: var(--liberty-bg);
  color: var(--liberty-text);
  padding: 0.45rem 0.85rem;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
}

.btn-secondary:hover {
  border-color: var(--liberty-accent);
  color: var(--liberty-accent-dark);
}

.btn-secondary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.transition-colors {
  transition-property: background-color, border-color, color, fill, stroke;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 150ms;
}
.my-6 {
  margin-bottom: 1.5rem;
  margin-top: 1.5rem;
}
.text-4xl {
  font-size: 2.25rem;
  line-height: 2.5rem;
}
.mx-2 {
  margin-left: 0.5rem;
  margin-right: 0.5rem;
}
.my-4 {
  margin-bottom: 1rem;
  margin-top: 1rem;
}
.mx-auto {
  margin-left: auto;
  margin-right: auto;
}
.px-4 {
  padding-left: 1rem;
  padding-right: 1rem;
}
.py-8 {
  padding-bottom: 2rem;
  padding-top: 2rem;
}
.bg-\[\#86efac\] {
  background-color: #86efac;
}
.text-3xl {
  font-size: 1.875rem;
  line-height: 2.25rem;
}
.py-6 {
  padding-bottom: 1.5rem;
  padding-top: 1.5rem;
}
.px-2 {
  padding-left: 0.5rem;
  padding-right: 0.5rem;
}
.py-1 {
  padding-bottom: 0.25rem;
  padding-top: 0.25rem;
}
.border-gray-500 {
  border-color: #6b7280;
}
.bg-white {
  background-color: #fff;
}
.flex {
  display: flex;
}
.gap-8 {
  grid-gap: 2rem;
  gap: 2rem;
}
.font-bold {
  font-weight: 700;
}
.max-w-screen-md {
  max-width: 768px;
}
.flex-col {
  flex-direction: column;
}
.items-center {
  align-items: center;
}
.justify-center {
  justify-content: center;
}
.border-2 {
  border-width: 2px;
}
.rounded {
  border-radius: 0.25rem;
}
.hover\:bg-gray-200:hover {
  background-color: #e5e7eb;
}
.tabular-nums {
  font-variant-numeric: tabular-nums;
}

/* AG Grid — summary report header (Liberty accent) */
.hours-header-accent {
  background: var(--liberty-accent-dark) !important;
  color: white !important;
}

/* Relatórios padrão (AUO + planilha) */
.std-report {
  margin-bottom: 2rem;
  padding: 1.25rem;
  border-radius: 0.5rem;
  border: 1px solid #e2e8f0;
  background: #fff;
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.06);
}
.std-report-header {
  margin-bottom: 1rem;
}
.std-report-title {
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--liberty-text);
}
.std-report-meta {
  margin-top: 0.35rem;
  font-size: 0.875rem;
  color: #475569;
}
.std-report-table-wrap {
  overflow-x: auto;
}
.std-report-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}
.std-report-table th,
.std-report-table td {
  border: 1px solid #cbd5e1;
  padding: 0.5rem 0.65rem;
  text-align: left;
  vertical-align: top;
}
.std-report--auo .std-report-table thead th {
  background: var(--liberty-accent-dark);
  color: #fff;
  font-weight: 600;
}
.std-report--excel .std-report-table thead th {
  background: var(--liberty-accent-dark);
  color: #fff;
  font-weight: 600;
}
.std-report-num {
  text-align: right;
  white-space: nowrap;
}
.std-report-total-label {
  font-weight: 600;
  background: #f1f5f9;
}
.std-report-total {
  font-weight: 700;
}
.std-report-task-total {
  background: #e0f2fe;
}
.std-report-task-total td {
  font-weight: 500;
}
.std-report-sub-indent {
  width: 1.25rem;
  border-right: none !important;
  background: #fafafa;
}
.std-report-controle {
  font-weight: 500;
  color: #475569;
}
.std-report-muted {
  font-size: 0.8125rem;
  color: #64748b;
  font-style: italic;
}

.std-report--consultant .std-report-meta {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.std-report-meta-note {
  font-size: 0.8125rem;
  color: #64748b;
  line-height: 1.45;
}
.std-report-consultant-list {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
.std-report-consultant-block {
  margin: 0;
  padding: 0.75rem 0.85rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid rgb(110 176 204 / 0.35);
  background: linear-gradient(
    165deg,
    #fff 0%,
    var(--liberty-teal-mist) 100%
  );
}
.std-report-consultant-name {
  margin: 0 0 0.65rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--liberty-accent-deep);
  letter-spacing: 0.01em;
}
.std-report--consultant .std-report-table--nested thead th {
  background: var(--liberty-accent-dark);
  color: #fff;
  font-weight: 600;
}
.std-report-grand-total-wrap {
  margin-top: 1rem;
}
.std-report-grand-total-wrap .std-report-table {
  max-width: 36rem;
  margin-left: auto;
}

.std-report-project-block {
  margin: 0 0 1rem;
}
.std-report-project-title {
  margin: 0 0 0.4rem;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--liberty-accent-deep);
  line-height: 1.35;
}
.std-report-table--zebra tbody tr:nth-child(even) {
  background: rgb(110 176 204 / 0.08);
}
.std-report-consultant-total-wrap {
  margin-top: 0.5rem;
}
.std-report-table--consultant-sum {
  max-width: 100%;
}

.report-field-static {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.report-static-value {
  margin: 0;
  padding: 0.45rem 0.65rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px dashed var(--liberty-border);
  background: var(--liberty-teal-mist);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--liberty-accent-deep);
  max-width: 22rem;
}

.report-board-pick {
  margin-bottom: 1rem;
  padding: 0.85rem 1rem;
  border-radius: var(--liberty-radius);
  border: 1px solid rgb(110 176 204 / 0.45);
  background: linear-gradient(
    165deg,
    #fff 0%,
    var(--liberty-teal-mist) 100%
  );
}
.report-board-pick-lede {
  margin: 0 0 0.65rem;
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--liberty-text-muted);
}
.report-board-pick-list {
  margin: 0 0 0.65rem;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  max-height: 14rem;
  overflow-y: auto;
}
.report-board-pick-item {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.8125rem;
  line-height: 1.4;
  cursor: pointer;
  color: var(--liberty-text);
}
.report-board-pick-item input {
  margin-top: 0.15rem;
  accent-color: var(--liberty-accent);
  flex-shrink: 0;
}
.report-board-pick-reset {
  border: 1px solid var(--liberty-border);
  border-radius: var(--liberty-radius-sm);
  background: var(--liberty-bg);
  padding: 0.35rem 0.65rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--liberty-accent-deep);
  cursor: pointer;
}
.report-board-pick-reset:hover {
  border-color: var(--liberty-accent);
  background: var(--liberty-teal-mist);
}

/* Hours report shell */
.report-page {
  flex: 1;
  display: flex;
  flex-direction: column;
  color: var(--liberty-text);
  background: transparent;
}
.report-header {
  border-bottom: 1px solid var(--liberty-border);
  background: var(--liberty-bg);
  padding: 1.25rem 0;
  box-shadow: var(--liberty-shadow);
}
.report-title {
  font-size: 1.375rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--liberty-text);
}
.report-lede {
  margin-top: 0.35rem;
  max-width: 48rem;
  font-size: 0.875rem;
  color: var(--liberty-text-muted);
  line-height: 1.55;
}
.report-main {
  margin: 0;
  width: 100%;
  max-width: none;
  padding: 1.5rem 0;
}
.report-toolbar {
  margin-bottom: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 1rem;
  padding: 1rem;
  border-radius: var(--liberty-radius);
  border: 1px solid var(--liberty-border);
  background: var(--liberty-bg);
  box-shadow: var(--liberty-shadow);
}
.report-field-report-type select {
  min-width: min(100%, 22rem);
  max-width: 100%;
}
.report-toolbar-ws-err {
  flex: 1 1 12rem;
  align-self: center;
}
.report-field {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 0.875rem;
}
.report-field span {
  font-weight: 500;
  color: var(--liberty-text);
}
.report-field input,
.report-field select {
  border: 1px solid var(--liberty-border);
  border-radius: var(--liberty-radius-sm);
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  color: var(--liberty-text);
}
.report-field-checkbox {
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
}
.report-field-checkbox input[type="checkbox"] {
  width: 1rem;
  height: 1rem;
  accent-color: var(--liberty-accent);
}
.report-btn-primary {
  border: none;
  border-radius: var(--liberty-radius-sm);
  background: var(--liberty-accent);
  color: #fff;
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 1px 2px rgb(110 176 204 / 0.35);
}
.report-btn-primary:hover {
  background: var(--liberty-accent-dark);
}
.report-btn-primary:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}
.report-toolbar-actions {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.5rem;
}
.report-export {
  position: relative;
  display: inline-flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.2rem;
}
.report-export-trigger {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.45rem 0.65rem;
  border: 1px solid var(--liberty-border);
  border-radius: var(--liberty-radius-sm);
  background: var(--surface-color);
  color: var(--liberty-text-muted);
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.2;
  cursor: pointer;
  transition:
    border-color 0.15s ease,
    color 0.15s ease,
    background 0.15s ease,
    box-shadow 0.15s ease;
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.04);
}
.report-export-trigger:hover:not(:disabled) {
  border-color: rgb(0 43 73 / 0.22);
  color: var(--brand-dark);
  background: rgb(248 250 252);
}
.report-export-trigger:focus-visible {
  outline: 2px solid rgb(0 191 154 / 0.45);
  outline-offset: 2px;
}
.report-export-trigger:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
}
.report-export-trigger-label {
  letter-spacing: 0.01em;
}
.report-export-trigger[aria-expanded="true"] {
  border-color: rgb(0 43 73 / 0.28);
  color: var(--brand-dark);
  background: rgb(255 255 255);
  box-shadow: 0 1px 3px rgb(0 43 73 / 0.08);
}
.report-export-chevron {
  flex-shrink: 0;
  opacity: 0.85;
  transition: transform 0.18s ease;
}
.report-export-chevron--open {
  transform: rotate(180deg);
}
.report-export-panel {
  position: absolute;
  z-index: 40;
  top: calc(100% + 4px);
  right: 0;
  min-width: 12.5rem;
  padding: 0.25rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: var(--surface-color);
  box-shadow:
    0 4px 6px -1px rgb(15 23 42 / 0.07),
    0 10px 20px -8px rgb(0 43 73 / 0.12);
}
.report-export-menu-item {
  display: flex;
  width: 100%;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.1rem;
  padding: 0.45rem 0.6rem;
  border: none;
  border-radius: calc(var(--liberty-radius-sm) - 2px);
  background: transparent;
  color: var(--liberty-text);
  font-size: 0.8125rem;
  text-align: left;
  cursor: pointer;
  transition: background 0.12s ease;
}
.report-export-menu-item:hover {
  background: rgb(0 191 154 / 0.08);
}
.report-export-menu-item:focus-visible {
  outline: 2px solid rgb(0 191 154 / 0.45);
  outline-offset: 0;
}
.report-export-menu-item--pdf {
  margin-top: 1px;
  border-top: 1px solid var(--liberty-border);
  border-radius: 0 0 calc(var(--liberty-radius-sm) - 2px)
    calc(var(--liberty-radius-sm) - 2px);
  padding-top: 0.5rem;
}
.report-export-menu-title {
  font-weight: 600;
  color: var(--brand-dark);
}
.report-export-menu-meta {
  font-size: 0.6875rem;
  font-weight: 400;
  color: var(--liberty-text-muted);
  line-height: 1.3;
}
.report-export-busy {
  position: absolute;
  top: calc(100% + 2px);
  right: 0;
  white-space: nowrap;
  font-size: 0.6875rem;
  color: var(--liberty-text-muted);
}
.report-export-err {
  position: absolute;
  top: calc(100% + 2px);
  right: 0;
  max-width: 14rem;
  margin: 0;
  font-size: 0.6875rem;
  line-height: 1.35;
  color: var(--error-color);
  text-align: right;
}
.report-note--scope {
  margin-bottom: 0.75rem;
}
.report-note {
  margin-bottom: 1rem;
  padding: 0.75rem 1rem;
  border-radius: 0.25rem;
  border: 1px solid #fde68a;
  background: #fffbeb;
  font-size: 0.875rem;
  color: #78350f;
}
.report-dimensions {
  margin-bottom: 1rem;
  padding: 0.75rem 1rem;
  border-radius: 0.375rem;
  border: 1px solid #e2e8f0;
  background: #fff;
  font-size: 0.8125rem;
  color: #334155;
}
.report-dimensions-title {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 0.875rem;
  color: #0f172a;
}
.report-dimensions-lede {
  margin: 0 0 0.5rem;
  max-width: 42rem;
  line-height: 1.45;
  color: #64748b;
}
.report-dimension-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.report-dimension-list li {
  margin: 0;
}
.report-dimension-pill {
  display: inline-block;
  padding: 0.15rem 0.45rem;
  border-radius: 0.25rem;
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  font-size: 0.75rem;
  color: #0f172a;
}
.text-gray-600 {
  color: #475569;
}
.rounded-lg {
  border-radius: 0.5rem;
}
.border-red-200 {
  border-color: #fecaca;
}
.bg-red-50 {
  background: #fef2f2;
}
.text-red-800 {
  color: #991b1b;
}
.text-sm {
  font-size: 0.875rem;
}
.mx-1 {
  margin-left: 0.25rem;
  margin-right: 0.25rem;
}
.px-4 {
  padding-left: 1rem;
  padding-right: 1rem;
}
.py-3 {
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
}
.rounded {
  border-radius: 0.25rem;
}
.border {
  border-width: 1px;
  border-style: solid;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Cockpit central */
.cockpit-page {
  color: var(--liberty-text);
}
.cockpit-hero {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.25rem;
  margin-bottom: 1.25rem;
  padding: 1.35rem 1.5rem;
  border-radius: var(--liberty-radius);
  border: 1px solid rgb(110 176 204 / 0.35);
  background:
    radial-gradient(
      ellipse 120% 80% at 100% 0%,
      rgb(110 176 204 / 0.18),
      transparent 55%
    ),
    linear-gradient(145deg, #fff 0%, var(--liberty-teal-mist) 100%);
  box-shadow: var(--liberty-shadow-md);
}
.cockpit-eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--liberty-accent-deep);
}
.cockpit-title {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--liberty-ink);
}
.cockpit-lede {
  margin: 0.5rem 0 0;
  max-width: 40rem;
  font-size: 0.875rem;
  line-height: 1.55;
  color: var(--liberty-text-muted);
}
.cockpit-kpi-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.cockpit-kpi-pill {
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  border: 1px solid rgb(110 176 204 / 0.4);
  background: rgb(255 255 255 / 0.85);
  font-size: 0.78rem;
  color: var(--liberty-text-muted);
}
.cockpit-kpi-pill strong {
  color: var(--liberty-accent-deep);
  font-weight: 700;
}
.cockpit-kpi-pill--warn {
  border-color: #fecaca;
  background: #fef2f2;
  color: #991b1b;
}
.cockpit-api-note {
  margin: 0 0 1rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px dashed var(--liberty-border);
  background: var(--liberty-surface-warm);
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--liberty-text-muted);
}
.cockpit-toolbar {
  margin-bottom: 1rem;
}
.cockpit-search-input {
  width: 100%;
  max-width: 28rem;
  padding: 0.55rem 0.85rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  font-size: 0.875rem;
}
.cockpit-muted {
  font-size: 0.875rem;
  color: #64748b;
}
.cockpit-error {
  padding: 0.75rem 1rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid #fecaca;
  background: #fef2f2;
  color: #991b1b;
  font-size: 0.875rem;
}
.cockpit-section {
  margin-bottom: 2rem;
}
.cockpit-section-title {
  margin: 0 0 0.75rem;
  font-size: 1rem;
  font-weight: 700;
  color: var(--liberty-ink);
}
.cockpit-overview-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.cockpit-overview-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: var(--liberty-bg);
}
.cockpit-overview-name {
  margin: 0;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--liberty-text);
}
.cockpit-overview-meta {
  margin: 0.15rem 0 0;
  font-size: 0.72rem;
  color: #64748b;
}
.cockpit-workspace-stack {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}
.cockpit-workspace {
  border-radius: var(--liberty-radius);
  border: 1px solid var(--liberty-border);
  background: var(--liberty-bg);
  overflow: hidden;
}
.cockpit-workspace-summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}
.cockpit-workspace-summary::-webkit-details-marker {
  display: none;
}
.cockpit-workspace-name {
  font-size: 0.9rem;
  color: var(--liberty-ink);
}
.cockpit-workspace-count {
  font-size: 0.75rem;
  font-weight: 500;
  color: #64748b;
}
.cockpit-board-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
  gap: 0.65rem;
  padding: 0 1rem 1rem;
}
.cockpit-board-card {
  display: flex;
  flex-direction: column;
  padding: 0.75rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid #e2e8f0;
  background: linear-gradient(180deg, #fff 0%, #f8fafc 100%);
  min-height: 7rem;
}
.cockpit-board-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.35rem;
  margin-bottom: 0.35rem;
}
.cockpit-board-title {
  margin: 0;
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--liberty-text);
}
.cockpit-board-id {
  flex-shrink: 0;
  font-size: 0.68rem;
  font-weight: 700;
  color: #94a3b8;
}
.cockpit-board-badges {
  margin-bottom: 0.35rem;
}
.cockpit-badge {
  display: inline-block;
  padding: 0.12rem 0.4rem;
  border-radius: 4px;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: #f1f5f9;
  color: #64748b;
}
.cockpit-badge--sync {
  background: rgb(110 176 204 / 0.25);
  color: var(--liberty-accent-deep);
}
.cockpit-board-drill {
  margin-top: auto;
  font-size: 0.72rem;
}
.cockpit-board-drill summary {
  cursor: pointer;
  color: var(--liberty-accent-dark);
  font-weight: 500;
}
.cockpit-board-actions {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-top: 0.4rem;
}
.cockpit-link-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.4rem 0.55rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-accent);
  background: var(--liberty-accent);
  color: #fff !important;
  font-size: 0.72rem;
  font-weight: 600;
  text-decoration: none;
  text-align: center;
}
.cockpit-link-btn:hover {
  background: var(--liberty-accent-dark);
  border-color: var(--liberty-accent-dark);
}
.cockpit-link-btn--secondary {
  border-color: var(--liberty-border);
  background: #fff;
  color: var(--liberty-accent-deep) !important;
}
.cockpit-link-btn--secondary:hover {
  border-color: var(--liberty-accent);
  background: var(--liberty-teal-mist);
}

.cockpit-section--primary {
  margin-bottom: 2rem;
}
.cockpit-board-card--selected {
  border-color: var(--liberty-accent) !important;
  box-shadow: 0 0 0 1px rgb(110 176 204 / 0.45);
}
.cockpit-board-actions--inline {
  flex-direction: column;
  gap: 0.4rem;
  margin-top: 0.5rem;
}
.cockpit-pick-board {
  width: 100%;
  padding: 0.45rem 0.6rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-accent);
  background: var(--liberty-accent);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
}
.cockpit-pick-board:hover {
  background: var(--liberty-accent-dark);
}
.cockpit-pick-board--active {
  background: var(--liberty-accent-deep);
  border-color: var(--liberty-accent-deep);
}

.cockpit-views-shell {
  padding: 1rem 1.1rem 1.25rem;
  border-radius: var(--liberty-radius);
  border: 1px solid rgb(110 176 204 / 0.4);
  background: linear-gradient(
    165deg,
    #f8fafc 0%,
    #fff 40%,
    var(--liberty-teal-mist) 100%
  );
}
.cockpit-views-head {
  margin-bottom: 0.75rem;
}
.cockpit-views-heading {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--liberty-ink);
}
.cockpit-views-sub {
  margin: 0.25rem 0 0;
  font-size: 0.8rem;
  color: #64748b;
}

.cockpit-view-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 0.85rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--liberty-border);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.cockpit-view-tab {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.1rem;
  padding: 0.45rem 0.65rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  text-align: left;
  min-width: 7rem;
  max-width: 14rem;
}
.cockpit-view-tab:hover {
  background: rgb(110 176 204 / 0.12);
}
.cockpit-view-tab--active {
  border-color: var(--liberty-accent);
  background: rgb(110 176 204 / 0.18);
}
.cockpit-view-tab-name {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--liberty-ink);
  line-height: 1.25;
}
.cockpit-view-tab-type {
  font-size: 0.62rem;
  color: #64748b;
  font-family: ui-monospace, monospace;
  word-break: break-all;
}

.cockpit-view-panel {
  min-height: 8rem;
}

.cockpit-dash-mirror {
  padding: 1rem;
  border-radius: var(--liberty-radius);
  background: linear-gradient(160deg, #1e293b 0%, #0f172a 100%);
  color: #e2e8f0;
  border: 1px solid #334155;
}
.cockpit-dash-mirror-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  margin-bottom: 0.5rem;
}
.cockpit-dash-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: #f8fafc;
}
.cockpit-dash-note {
  margin: 0 0 0.85rem;
  font-size: 0.75rem;
  line-height: 1.45;
  color: #94a3b8;
}
.cockpit-dash-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr));
  gap: 0.65rem;
}
.cockpit-dash-widget {
  padding: 0.55rem 0.6rem;
  border-radius: 0.35rem;
  background: rgb(15 23 42 / 0.85);
  border: 1px solid #475569;
}
.cockpit-dash-widget-title {
  margin: 0 0 0.4rem;
  font-size: 0.68rem;
  font-weight: 600;
  color: #cbd5e1;
  line-height: 1.3;
}
.cockpit-dash-widget-body {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.cockpit-dash-chart-ph {
  height: 3.25rem;
  border-radius: 0.25rem;
  background: linear-gradient(
    90deg,
    rgb(110 176 204 / 0.35) 0%,
    rgb(110 176 204 / 0.08) 40%,
    rgb(251 191 36 / 0.25) 100%
  );
}
.cockpit-dash-widget-hint {
  font-size: 0.58rem;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.cockpit-dash-meta {
  margin: 0.75rem 0 0;
  font-size: 0.68rem;
  color: #94a3b8;
}

.cockpit-plain-view {
  padding: 1rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: var(--liberty-bg);
}
.cockpit-plain-title {
  margin: 0 0 0.35rem;
  font-size: 1rem;
  font-weight: 700;
  color: var(--liberty-ink);
}
.cockpit-plain-type {
  margin: 0 0 0.5rem;
  font-size: 0.75rem;
  color: #64748b;
}
.cockpit-plain-copy {
  margin: 0 0 0.75rem;
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--liberty-text-muted);
}

.cockpit-api-note--tight {
  margin-top: 0.75rem;
  margin-bottom: 0;
}

/* Painel de Gestão-Equipe (overview Monday) */
.cockpit-painel-section {
  margin-bottom: 2rem;
  padding: 1.1rem 1.15rem 1.25rem;
  border-radius: var(--liberty-radius);
  border: 2px solid rgb(110 176 204 / 0.55);
  background: linear-gradient(
    145deg,
    #fff 0%,
    rgb(232 244 248) 55%,
    var(--liberty-teal-mist) 100%
  );
  box-shadow: var(--liberty-shadow-md);
}
.cockpit-painel-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.65rem;
}
.cockpit-painel-title {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--liberty-ink);
}
.cockpit-painel-sub {
  margin: 0.35rem 0 0;
  font-size: 0.8125rem;
  line-height: 1.45;
  color: var(--liberty-text-muted);
  max-width: 42rem;
}
.cockpit-painel-notes {
  margin: 0 0 1rem;
  padding-left: 1.1rem;
  font-size: 0.75rem;
  line-height: 1.45;
  color: #64748b;
}
.cockpit-painel-notes li {
  margin-bottom: 0.25rem;
}
.cockpit-painel-grid {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr));
  gap: 0.75rem;
}
.cockpit-painel-card {
  display: flex;
  flex-direction: column;
  padding: 0.85rem 0.9rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: #fff;
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.04);
}
.cockpit-painel-ws {
  margin: 0 0 0.2rem;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--liberty-accent-deep);
}
.cockpit-painel-board {
  margin: 0 0 0.25rem;
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--liberty-text);
}
.cockpit-painel-id {
  margin: 0 0 0.4rem;
  font-size: 0.68rem;
  color: #94a3b8;
}

/* Cockpit — dashboard-first layout */
.cockpit-hero--compact {
  margin-bottom: 1rem;
  padding: 1rem 1.25rem;
}
.cockpit-hero--compact .cockpit-title {
  font-size: 1.35rem;
}
.cockpit-dashboard-toolbar {
  align-items: flex-end;
}
.cockpit-dashboard-toolbar--stack {
  flex-direction: column;
  align-items: stretch;
  gap: 0.75rem;
}
.cockpit-toolbar-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.75rem 1rem;
}
.cockpit-toolbar-row--search {
  margin: 0;
  padding-top: 0.75rem;
  border-top: 1px solid var(--liberty-border);
}
.cockpit-dashboard-field-ws {
  flex: 1 1 12rem;
  min-width: min(100%, 11rem);
}
.cockpit-dashboard-field-ws select {
  min-width: min(100%, 22rem);
  max-width: 100%;
}
.cockpit-dashboard-field-painel {
  flex: 2 1 18rem;
  min-width: min(100%, 14rem);
}
.cockpit-dashboard-field-painel select {
  min-width: min(100%, 36rem);
  max-width: 100%;
}
.cockpit-dashboard-field-grow {
  flex: 1 1 14rem;
  min-width: min(100%, 12rem);
}
.cockpit-dashboard-field-grow .cockpit-search-input {
  max-width: none;
  width: 100%;
}
.cockpit-link-btn--toolbar {
  flex: 0 0 auto;
  align-self: flex-end;
  white-space: nowrap;
}
.cockpit-help-details {
  margin: 0 0 0.75rem;
  padding: 0.4rem 0.65rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: var(--liberty-bg);
  font-size: 0.78rem;
  color: var(--liberty-text-muted);
}
.cockpit-help-details summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--liberty-text);
  list-style-position: outside;
}
.cockpit-help-inner {
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--liberty-border);
}
.cockpit-help-heading {
  margin: 0 0 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--liberty-text-muted);
}
.cockpit-help-list {
  margin: 0;
  padding-left: 1.1rem;
}
.cockpit-help-list li {
  margin: 0.2rem 0;
}
.cockpit-help-text {
  margin: 0.35rem 0 0;
  line-height: 1.45;
}
.cockpit-help-text:first-child {
  margin-top: 0;
}
.cockpit-dashboard-stage {
  margin-top: 0.5rem;
}
.cockpit-dash-context {
  margin: 0 0 0.35rem;
  font-size: 0.72rem;
  color: var(--liberty-text-muted);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
}
.cockpit-dash-board-ref {
  margin: 0.15rem 0 0;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--liberty-text);
}
.cockpit-dash-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  justify-content: flex-end;
}
.cockpit-badge--inline {
  margin-left: 0.15rem;
  vertical-align: middle;
}

/* Cockpit v2 — PM / capacity dashboards */
.cockpit-v2 {
  color: var(--liberty-text);
  width: 100%;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.cockpit-v2-loading {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: min(52vh, 32rem);
  margin: 0.25rem 0 1.5rem;
  padding: 2rem 1.5rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px dashed rgb(148 163 184 / 0.65);
  background: rgb(255 255 255 / 0.75);
  box-shadow: var(--liberty-shadow);
}

@keyframes cockpit-spin {
  to {
    transform: rotate(360deg);
  }
}
.cockpit-v2-spin {
  display: inline-block;
  width: 1.25rem;
  height: 1.25rem;
  line-height: 1.25rem;
  transform-origin: center center;
  animation: cockpit-spin 1s linear infinite;
  color: var(--liberty-primary, #22789e);
  font-size: 1.25rem;
  vertical-align: middle;
}
.cockpit-v2-tile-spin {
  display: block;
  width: 1.5rem;
  height: 1.5rem;
  line-height: 1.5rem;
  transform-origin: center center;
  font-size: 1.5rem;
  margin: 0.5rem 0;
}
.cockpit-v2-hero {
  display: grid;
  grid-template-columns: minmax(0, min(46rem, 100%)) minmax(0, 1fr);
  align-items: start;
  gap: 1.25rem 1.5rem;
  margin-bottom: 1.5rem;
  padding: 1.35rem 1.5rem;
  border-radius: var(--liberty-radius);
  border: 1px solid rgb(110 176 204 / 0.35);
  background:
    radial-gradient(
      ellipse 100% 80% at 100% 0%,
      rgb(110 176 204 / 0.14),
      transparent 50%
    ),
    linear-gradient(160deg, #fff 0%, var(--liberty-teal-mist) 100%);
  box-shadow: var(--liberty-shadow-md);
}

@media (max-width: 960px) {
  .cockpit-v2-hero {
    grid-template-columns: 1fr;
  }
}
.cockpit-v2-eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--liberty-accent-deep);
}
.cockpit-v2-title {
  margin: 0;
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--liberty-ink);
}
.cockpit-v2-lede {
  margin: 0.5rem 0 0;
  max-width: 46rem;
  font-size: 0.875rem;
  line-height: 1.55;
  color: var(--liberty-text-muted);
}
.cockpit-v2-toolbar {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  width: 100%;
  min-width: 0;
  padding: 0;
  border-radius: var(--liberty-radius);
  border: 1px solid rgb(148 163 184 / 0.28);
  background:
    linear-gradient(180deg, rgb(255 255 255 / 0.96), rgb(248 250 252 / 0.94)),
    #fff;
  box-shadow: 0 1px 1px rgb(15 23 42 / 0.04), 0 14px 34px rgb(15 23 42 / 0.07);
  overflow: hidden;
}
.cockpit-v2-toolbar-presets {
  display: grid;
  gap: 0.7rem;
  padding: 0.9rem 1rem 1rem;
  background: rgb(248 250 252 / 0.72);
  border-top: 1px solid rgb(226 232 240 / 0.9);
}
.cockpit-v2-preset-group {
  display: grid;
  grid-template-columns: minmax(5.2rem, auto) minmax(0, 1fr);
  align-items: start;
  gap: 0.45rem 0.8rem;
}
.cockpit-v2-preset-group-label {
  flex: 0 0 auto;
  min-width: 0;
  padding-top: 0.42rem;
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #475569;
}
.cockpit-v2-preset-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  flex: 1 1 12rem;
}
.cockpit-v2-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.32rem;
  padding: 0.34rem 0.7rem;
  min-height: 1.95rem;
  font-family: inherit;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.2;
  color: var(--liberty-text);
  border-radius: 999px;
  border: 1px solid rgb(203 213 225 / 0.85);
  background: rgb(255 255 255 / 0.92);
  box-shadow:
    0 1px 1px rgb(15 23 42 / 0.03),
    0 1px 0 rgb(255 255 255 / 0.75) inset;
  transition:
    border-color 0.15s ease,
    background 0.15s ease,
    box-shadow 0.15s ease,
    color 0.15s ease;
}
.cockpit-v2-chip:hover {
  border-color: rgb(0 191 154 / 0.45);
  background: #f0fdfa;
  color: #0f766e;
  transform: translateY(-1px);
}
.cockpit-v2-chip:focus {
  outline: none;
}
.cockpit-v2-chip:focus-visible {
  outline: 2px solid var(--liberty-accent);
  outline-offset: 2px;
}
.cockpit-v2-chip[aria-pressed="true"] {
  border-color: rgb(0 191 154 / 0.52);
  background: linear-gradient(180deg, #ccfbf1 0%, #ecfeff 100%);
  color: #064e3b;
  box-shadow:
    0 4px 10px rgb(0 191 154 / 0.1),
    0 1px 0 rgb(255 255 255 / 0.5) inset;
}
.cockpit-v2-toolbar-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.75rem 1rem;
  padding: 0.85rem 1rem;
}

/* Let filter fields use extra width on large screens instead of leaving a gap. */
.cockpit-v2-toolbar-controls .report-field {
  flex: 1 1 12rem;
  min-width: 0;
  max-width: min(22rem, 100%);
}

.cockpit-v2-toolbar-controls .report-btn-primary {
  flex: 0 0 auto;
}
.cockpit-v2-muted {
  font-size: 0.875rem;
  color: #64748b;
}
.cockpit-v2-kpi {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(12.5rem, 1fr));
  gap: 0.9rem;
  margin-bottom: 1.5rem;
}
.cockpit-v2-tile {
  position: relative;
  overflow: hidden;
  padding: 1.15rem 1.25rem;
  border-radius: var(--liberty-radius);
  border: 1px solid var(--liberty-hairline);
  background: #fff;
  box-shadow: var(--liberty-shadow);
  transition:
    box-shadow 0.18s ease,
    transform 0.18s ease,
    border-color 0.18s ease;
}
.cockpit-v2-tile:hover {
  transform: translateY(-2px);
  box-shadow: var(--liberty-shadow-md);
  border-color: rgb(148 163 184 / 0.4);
}
/* Optional icon chip (top-right) */
.cockpit-v2-tile-icon {
  position: absolute;
  top: 1rem;
  right: 1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 10px;
  background: rgb(0 191 154 / 0.1);
  color: var(--brand-primary-strong);
}
.cockpit-v2-tile-icon .material-icons {
  font-size: 1.25rem;
}
.cockpit-v2-tile--accent {
  border-color: rgb(0 191 154 / 0.3);
  background:
    radial-gradient(
      120% 140% at 100% 0%,
      rgb(0 191 154 / 0.08),
      transparent 55%
    ),
    #fff;
}
.cockpit-v2-tile--warn {
  border-color: rgb(245 158 11 / 0.4);
  background:
    radial-gradient(
      120% 140% at 100% 0%,
      rgb(245 158 11 / 0.1),
      transparent 55%
    ),
    #fff;
}
.cockpit-v2-tile--warn .cockpit-v2-tile-icon {
  background: rgb(245 158 11 / 0.14);
  color: #b45309;
}
.cockpit-v2-tile--danger {
  border-color: rgb(239 68 68 / 0.38);
  background:
    radial-gradient(
      120% 140% at 100% 0%,
      rgb(239 68 68 / 0.09),
      transparent 55%
    ),
    #fff;
}
.cockpit-v2-tile--danger .cockpit-v2-tile-icon {
  background: rgb(239 68 68 / 0.13);
  color: #b91c1c;
}
.cockpit-v2-tile-label {
  margin: 0;
  padding-right: 2.5rem;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--liberty-text-muted);
}
.cockpit-v2-tile-value {
  margin: 0.45rem 0 0;
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--liberty-accent-deep);
  letter-spacing: -0.02em;
  line-height: 1.05;
  font-variant-numeric: tabular-nums;
}
.cockpit-v2-tile--accent .cockpit-v2-tile-value {
  color: var(--brand-primary-strong);
}
.cockpit-v2-tile--warn .cockpit-v2-tile-value {
  color: #b45309;
}
.cockpit-v2-tile--danger .cockpit-v2-tile-value {
  color: #b91c1c;
}
.cockpit-v2-tile-hint {
  margin: 0.3rem 0 0;
  font-size: 0.74rem;
  line-height: 1.4;
  color: #64748b;
}
.cockpit-v2-charts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1.5rem;
}
@media (max-width: 960px) {
  .cockpit-v2-charts {
    grid-template-columns: 1fr;
  }
}
.cockpit-v2-chart-card {
  padding: 0.75rem 1rem 1rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: #fff;
  box-shadow: var(--liberty-shadow);
}
.cockpit-v2-chart-card--wide {
  grid-column: 1 / -1;
}
.cockpit-v2-chart-wrap {
  position: relative;
  height: 280px;
}
.cockpit-v2-chart-wrap--tall {
  height: 320px;
}
.cockpit-v2-section {
  margin-bottom: 1.75rem;
}
.cockpit-v2-section-title {
  margin: 0 0 0.75rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--liberty-ink);
}
.cockpit-v2-table-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin-bottom: 0.65rem;
}
.cockpit-v2-table-head .cockpit-v2-section-title {
  margin: 0;
  flex: 1 1 12rem;
}
.cockpit-v2-pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 0.85rem;
  font-size: 0.78rem;
  color: var(--liberty-text-muted);
}
.cockpit-v2-pagination-label {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
.cockpit-v2-pagination-select {
  padding: 0.25rem 1.5rem 0.25rem 0.45rem;
  font-size: 0.78rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: #fff;
  color: var(--liberty-text);
}
.cockpit-v2-pagination-meta {
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.cockpit-v2-pagination-nav {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}
.cockpit-v2-pagination-pages {
  font-variant-numeric: tabular-nums;
  padding: 0 0.15rem;
  color: var(--liberty-text);
}
.cockpit-v2-pagination-btn {
  padding: 0.3rem 0.55rem;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: #fff;
  color: var(--liberty-accent-dark);
  cursor: pointer;
}
.cockpit-v2-pagination-btn:hover:not(:disabled) {
  background: #f8fafc;
  border-color: #cbd5e1;
}
.cockpit-v2-pagination-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.cockpit-v2-cards {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr));
  gap: 0.85rem;
}
.cockpit-v2-card {
  display: flex;
  flex-direction: column;
  padding: 1rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: linear-gradient(180deg, #fff 0%, #f8fafc 100%);
  min-height: 10rem;
}
.cockpit-v2-card-ws {
  margin: 0;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--liberty-accent-deep);
}
.cockpit-v2-card-name {
  margin: 0.35rem 0 0.25rem;
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--liberty-text);
}
.cockpit-v2-card-hours {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--liberty-accent-deep);
}
.cockpit-v2-card-share {
  margin: 0.15rem 0 0.5rem;
  font-size: 0.75rem;
  color: #64748b;
}
.cockpit-v2-card-bar {
  height: 6px;
  border-radius: 3px;
  background: #e2e8f0;
  margin-bottom: 0.65rem;
  overflow: hidden;
}
.cockpit-v2-card-bar::after {
  content: "";
  display: block;
  height: 100%;
  width: var(--p, 0%);
  border-radius: 3px;
  background: linear-gradient(
    90deg,
    var(--liberty-accent),
    var(--liberty-accent-dark)
  );
}
.cockpit-v2-card-actions {
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.cockpit-v2-link {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--liberty-accent-dark);
  text-decoration: none;
}
.cockpit-v2-link:hover {
  text-decoration: underline;
}
.cockpit-v2-table-wrap {
  overflow-x: auto;
  border-radius: var(--liberty-radius);
  border: 1px solid var(--liberty-hairline);
  background: #fff;
  box-shadow: var(--liberty-shadow);
}
.cockpit-v2-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.8125rem;
}
.cockpit-v2-table th,
.cockpit-v2-table td {
  padding: 0.8rem 0.95rem;
  text-align: left;
  border-bottom: 1px solid rgb(226 232 240 / 0.8);
}
.cockpit-v2-table tbody tr:last-child td {
  border-bottom: none;
}
.cockpit-v2-table--align-top td {
  vertical-align: top;
}
.cockpit-v2-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  font-size: 0.66rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  background: linear-gradient(180deg, #fbfcfe 0%, #f4f7fb 100%);
  color: #64748b;
  white-space: nowrap;
  border-bottom: 1px solid rgb(203 213 225 / 0.7);
}
.cockpit-v2-table tbody tr {
  transition: background-color 0.15s ease, box-shadow 0.15s ease;
}
.cockpit-v2-table tbody tr:hover {
  background: #f8fafc;
  box-shadow: inset 0 0 0 999px rgb(15 23 42 / 0.015);
}
.cockpit-v2-row--fresh-hot {
  box-shadow: inset 3px 0 0 var(--brand-primary);
  background: rgb(209 250 229 / 0.44);
}
.cockpit-v2-row--fresh-warm {
  box-shadow: inset 3px 0 0 rgb(37 99 235 / 0.45);
  background: rgb(239 246 255 / 0.5);
}
.cockpit-v2-n {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.cockpit-v2-warnings {
  margin: 1rem 0;
  padding: 0.5rem 0.75rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: var(--liberty-bg);
  font-size: 0.8125rem;
  color: var(--liberty-text-muted);
}
.cockpit-v2-warnings summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--liberty-text);
}
.cockpit-v2-warnings ul {
  margin: 0.5rem 0 0;
  padding-left: 1.1rem;
}
.cockpit-v2-note {
  margin: 0;
  padding: 0.65rem 0.85rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px dashed var(--liberty-border);
  background: var(--liberty-surface-warm);
  font-size: 0.78rem;
  color: var(--liberty-text-muted);
}

/* -------------------------------------------------------------------------
   Unified product polish
   Shared visual layer for every screen in the test suite. This intentionally
   sits after the legacy rules so route-specific components inherit the same
   Support Center / UniConecta treatment without changing their data flow.
   ------------------------------------------------------------------------- */
:root {
  --liberty-canvas: #f5f7fa;
  --liberty-surface-raised: #ffffff;
  --liberty-border-soft: #dfe6ee;
  --liberty-shadow-soft:
    0 1px 2px rgb(15 23 42 / 0.04),
    0 8px 24px rgb(15 23 42 / 0.055);
  --liberty-shadow-hover:
    0 2px 4px rgb(15 23 42 / 0.05),
    0 14px 30px rgb(0 43 73 / 0.1);
}

html {
  background: var(--liberty-canvas);
}

body.app-body {
  background:
    radial-gradient(
      circle at 92% -10%,
      rgb(0 191 154 / 0.06),
      transparent 28rem
    ),
    var(--liberty-canvas);
}

.app-top-header {
  background:
    radial-gradient(circle at 12% 0%, rgb(0 191 154 / 0.18), transparent 28rem),
    linear-gradient(120deg, #002b49 0%, #003b5b 55%, #002b49 100%);
  border-bottom-color: rgb(0 191 154 / 0.32);
  box-shadow: 0 8px 24px rgb(0 43 73 / 0.18);
}

.app-header-brand {
  gap: 0.85rem;
}

.app-header-title {
  letter-spacing: -0.01em;
}

.app-sidebar {
  background: rgb(255 255 255 / 0.88);
  border-right-color: var(--liberty-border-soft);
  box-shadow: 8px 0 24px rgb(15 23 42 / 0.025);
}

.app-sidebar-inner {
  padding-top: 1.35rem;
}

.app-nav-section--spaced {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top-color: #edf1f5;
}

.app-main-wrap {
  background: transparent;
}

.page-shell--fluid {
  padding-top: clamp(1.25rem, 2.6vw, 2rem);
  padding-bottom: clamp(2rem, 4vw, 3rem);
}

.page-header {
  margin-bottom: 1.5rem;
}

.page-title {
  color: #102a43;
  font-size: clamp(1.45rem, 2vw, 1.85rem);
  letter-spacing: -0.035em;
}

.page-lede {
  max-width: 52rem;
  color: #64748b;
}

.app-btn,
.report-btn-primary,
.cockpit-v2-btn-primary {
  min-height: 2.55rem;
  border-radius: 0.7rem;
  font-weight: 700;
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.06);
  transition: transform 0.16s ease, box-shadow 0.16s ease, filter 0.16s ease;
}

.app-btn:hover:not(:disabled),
.report-btn-primary:hover:not(:disabled),
.cockpit-v2-btn-primary:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgb(0 43 73 / 0.12);
}

.app-btn--primary,
.report-btn-primary,
.cockpit-v2-btn-primary {
  background: linear-gradient(135deg, #00b6d6 0%, #00bf9a 100%);
  border-color: transparent;
  color: #fff;
}

.app-btn--secondary,
.app-btn--ghost {
  background: #fff;
  border-color: #d7e0e9;
  color: #21415a;
}

.cockpit-v2-hero {
  border-radius: 1rem;
  border-color: rgb(0 182 214 / 0.28);
  background:
    radial-gradient(
      ellipse 70% 100% at 100% 0%,
      rgb(0 191 154 / 0.14),
      transparent 62%
    ),
    linear-gradient(135deg, #ffffff 0%, #edfafa 100%);
  box-shadow: var(--liberty-shadow-soft);
}

.cockpit-v2-kpi {
  gap: 1rem;
}

.cockpit-v2-tile,
.cockpit-v2-chart-card,
.cockpit-v2-section,
.cockpit-v2-card {
  border-radius: 0.95rem;
}

.cockpit-v2-tile,
.cockpit-v2-chart-card,
.cockpit-v2-card {
  border-color: var(--liberty-border-soft);
  box-shadow: var(--liberty-shadow-soft);
}

.cockpit-v2-tile:hover,
.cockpit-v2-card:hover {
  box-shadow: var(--liberty-shadow-hover);
}

.cockpit-v2-tile-value {
  color: #123b57;
}

.cockpit-v2-table-wrap {
  border-radius: 0.95rem;
  border-color: var(--liberty-border-soft);
  box-shadow: var(--liberty-shadow-soft);
}

.cockpit-v2-table th {
  background: #f7fafc;
  color: #6b7d90;
}

.cockpit-v2-table td {
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
}

.cockpit-v2-table tbody tr:hover {
  background: #f0fbf8;
}

input:not([type="checkbox"]):not([type="radio"]),
select,
textarea {
  border-color: #d7e0e9;
  border-radius: 0.65rem;
  background: #fff;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

input:not([type="checkbox"]):not([type="radio"]):focus,
select:focus,
textarea:focus {
  border-color: #00a98b;
  box-shadow: 0 0 0 3px rgb(0 191 154 / 0.14);
  outline: none;
}

.login-page {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 15% 20%, rgb(0 182 214 / 0.2), transparent 22rem),
    radial-gradient(
    circle at 85% 85%,
    rgb(0 191 154 / 0.18),
    transparent 24rem
  ),
    linear-gradient(135deg, #001f35 0%, #003b5b 58%, #002b49 100%);
}

.login-page::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgb(255 255 255 / 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgb(255 255 255 / 0.035) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(to bottom, black, transparent 80%);
}

.login-page-card {
  position: relative;
  max-width: 25rem;
  padding: 2.5rem 2.25rem 2.25rem;
  border-radius: 1.25rem;
  background: rgb(255 255 255 / 0.1);
  border-color: rgb(255 255 255 / 0.2);
  box-shadow:
    0 30px 80px rgb(0 0 0 / 0.28),
    0 1px 0 rgb(255 255 255 / 0.14) inset;
  backdrop-filter: blur(18px);
}

.login-page-title {
  font-size: 1.6rem;
  letter-spacing: -0.03em;
}

@media (max-width: 639px) {
  .page-shell--fluid {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .login-page {
    padding: 1rem;
  }

  .login-page-card {
    padding: 2rem 1.35rem 1.75rem;
  }
}

/* Exact shell alignment with Support Center / UniConecta */
:root {
  --brand-dark: #002b49;
  --brand-light: #00b6d6;
  --brand-primary: #00bf9a;
  --background-color: #f8fafc;
  --surface-color: #ffffff;
  --border-color: #e2e8f0;
  --liberty-canvas: #f8fafc;
  --liberty-radius: 10px;
  --liberty-radius-sm: 6px;
  --liberty-radius-lg: 14px;
  --liberty-shadow: 0 1px 3px rgb(0 0 0 / 0.06), 0 1px 2px rgb(0 0 0 / 0.06);
  --liberty-shadow-md:
    0 4px 6px -1px rgb(0 0 0 / 0.1),
    0 2px 4px -2px rgb(0 0 0 / 0.1);
}

body.app-body {
  background: var(--background-color);
}

.app-top-header {
  background: var(--brand-dark);
  border-bottom: 1px solid rgb(55 65 81);
  box-shadow: none;
}

.app-top-header-inner {
  padding-left: 0.75rem;
  padding-right: 0.75rem;
}

.app-top-header-center {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: center;
  padding: 0 0.25rem;
}

.app-header-context {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 2.2rem;
  padding: 0.35rem 0.75rem;
  border: 1px solid rgb(255 255 255 / 0.2);
  border-radius: 0.5rem;
  background: rgb(0 0 0 / 0.12);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.app-header-context .material-icons {
  font-size: 1rem;
  color: #d7f9f1;
}

.app-sidebar {
  background: #fff;
  border-right-color: var(--border-color);
  box-shadow: none;
}

.app-sidebar-inner {
  padding-top: 1rem;
}

.app-nav-section--spaced {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top-color: #edf0f4;
}

.page-shell--fluid {
  padding-top: 1.25rem;
  padding-bottom: 2rem;
}

.page-header {
  margin-bottom: 1.25rem;
}

.page-title {
  font-size: 1.5rem;
  color: var(--text-primary);
}

.page-lede {
  font-size: 0.9rem;
}

.app-btn,
.report-btn-primary,
.cockpit-v2-btn-primary {
  min-height: 2.25rem;
  border-radius: 0.5rem;
  font-weight: 600;
  box-shadow: var(--liberty-shadow);
}

.app-btn--primary,
.report-btn-primary,
.cockpit-v2-btn-primary {
  background: var(--brand-primary);
  border-color: var(--brand-primary);
}

.app-btn--primary:hover:not(:disabled),
.report-btn-primary:hover:not(:disabled),
.cockpit-v2-btn-primary:hover:not(:disabled) {
  background: var(--primary-hover);
}

.app-btn--secondary,
.app-btn--ghost {
  border-color: var(--border-color);
  border-radius: 0.5rem;
}

.cockpit-v2-hero {
  border-radius: var(--liberty-radius);
  background: #fff;
  box-shadow: var(--liberty-shadow);
}

.cockpit-v2-tile,
.cockpit-v2-chart-card,
.cockpit-v2-card,
.cockpit-v2-table-wrap {
  border-radius: var(--liberty-radius);
  border-color: var(--border-color);
  box-shadow: var(--liberty-shadow);
}

.cockpit-v2-tile:hover,
.cockpit-v2-card:hover {
  box-shadow: var(--liberty-shadow-md);
}

.cockpit-v2-table tbody tr:hover {
  background: #f8fafc;
}

@media (max-width: 767px) {
  .app-top-header-center {
    display: none;
  }
}

/* Sidebar geometry matches the UniConecta shell at desktop widths. */
@media (min-width: 640px) {
  .app-sidebar-inner {
    padding: 1.25rem 1.25rem 1.5rem;
    padding-left: max(1.25rem, env(safe-area-inset-left, 0px));
  }
}

.app-sidebar-nav {
  width: calc(100% - 0.5rem);
}

@media (min-width: 1024px) {
  .page-shell--fluid {
    padding-top: 2rem;
  }
}

/* Accordion Section Styles */
.accordion-section {
  margin-bottom: 1.75rem;
}

.accordion-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 0.75rem 1.1rem;
  margin-bottom: 0;
  border: 1px solid rgb(110 176 204 / 0.3);
  border-radius: var(--liberty-radius-sm);
  background: linear-gradient(145deg, #fff 0%, rgb(110 176 204 / 0.04) 100%);
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
  text-align: left;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.accordion-header:hover {
  border-color: rgb(110 176 204 / 0.5);
  background: linear-gradient(145deg, #fff 0%, rgb(110 176 204 / 0.08) 100%);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06);
}

.accordion-header:focus {
  outline: none;
}

.accordion-header:focus-visible {
  outline: 2px solid var(--liberty-accent);
  outline-offset: 2px;
}

.accordion-title {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--liberty-accent-deep);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.accordion-icon {
  flex-shrink: 0;
  font-size: 1.5rem;
  color: var(--liberty-accent);
  transition: transform 0.2s ease;
}

.accordion-header[aria-expanded="true"] .accordion-icon {
  transform: rotate(0deg);
}

.accordion-header[aria-expanded="false"] .accordion-icon {
  transform: rotate(0deg);
}

.accordion-content {
  animation: accordion-slide-down 0.25s ease-out;
  padding-top: 1rem;
}

@keyframes accordion-slide-down {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Adjust spacing for accordion sections */
.accordion-section .cockpit-v2-kpi {
  margin-bottom: 0;
}

.accordion-section .cockpit-v2-charts {
  margin-bottom: 0;
}

.accordion-section .cockpit-v2-section {
  margin-bottom: 0;
}

.cockpit-v2-kpi-section .accordion-content {
  padding-top: 0.5rem;
}

/* Filter section accordion styling */
.cockpit-filters-section {
  margin-bottom: 1.5rem;
}

.cockpit-filters-section .accordion-header {
  background: linear-gradient(
    145deg,
    rgb(110 176 204 / 0.06) 0%,
    rgb(110 176 204 / 0.12) 100%
  );
  border-color: rgb(110 176 204 / 0.35);
}

.cockpit-filters-section .accordion-header:hover {
  background: linear-gradient(
    145deg,
    rgb(110 176 204 / 0.1) 0%,
    rgb(110 176 204 / 0.16) 100%
  );
  border-color: rgb(110 176 204 / 0.5);
}

.cockpit-filters-section .accordion-content {
  padding: 1.25rem;
  border: 1px solid rgb(110 176 204 / 0.2);
  border-top: none;
  border-radius: 0 0 var(--liberty-radius-sm) var(--liberty-radius-sm);
  background: linear-gradient(145deg, #fff 0%, rgb(110 176 204 / 0.02) 100%);
}

.cockpit-filters-section .cockpit-v2-toolbar {
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
  box-shadow: none;
}

.cockpit-filters-section .cockpit-v2-filters-row {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgb(110 176 204 / 0.15);
}

/* Visão financeira — extra controls (same tokens as Cockpit) */
.cockpit-v2-filters-row {
  display: grid;
  grid-template-columns:
    minmax(16rem, 1fr) repeat(auto-fit, minmax(11rem, auto));
  align-items: end;
  gap: 0.8rem;
  margin-bottom: 0;
  padding: 1rem;
  border: none;
  border-radius: 0;
  background: #fff;
  box-shadow: none;
}
.cockpit-v2-filter-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 10rem;
}
.cockpit-v2-filter-field--grow {
  flex: 1 1 18rem;
  min-width: min(100%, 14rem);
}
.cockpit-v2-filter-field label,
.cockpit-v2-filter-label {
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #64748b;
}
.cockpit-v2-select,
.cockpit-v2-search {
  border: 1px solid rgb(203 213 225 / 0.95);
  border-radius: 7px;
  padding: 0.58rem 0.68rem;
  font-family: inherit;
  font-size: 0.875rem;
  color: var(--liberty-text);
  background: #fff;
  box-shadow: 0 1px 1px rgb(15 23 42 / 0.03);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.cockpit-v2-select:focus,
.cockpit-v2-search:focus {
  border-color: rgb(0 191 154 / 0.62);
  box-shadow: 0 0 0 3px rgb(0 191 154 / 0.12);
  outline: none;
}
.cockpit-v2-search {
  width: 100%;
  border: none;
  box-shadow: none;
  padding-left: 0;
}
.cockpit-v2-search:focus {
  box-shadow: none;
}
.cockpit-v2-cell-main {
  display: block;
  font-weight: 600;
  color: var(--liberty-text);
}
.cockpit-v2-cell-sub {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.75rem;
  font-weight: 400;
  color: var(--liberty-text-muted);
}
.cockpit-v2-n--muted {
  color: var(--liberty-text-muted);
}
.cockpit-v2-inline-badge {
  display: inline-block;
  margin-left: 0.35rem;
  padding: 0.08rem 0.42rem;
  border-radius: 999px;
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: #f1f5f9;
  color: #64748b;
}
.cockpit-v2-inline-badge--fresh {
  background: #d1fae5;
  color: #047857;
  box-shadow: 0 0 0 1px rgb(0 191 154 / 0.18);
  animation: freshness-pulse 2s ease-in-out infinite;
}
.cockpit-v2-inline-badge--warm {
  background: #eff6ff;
  color: #2563eb;
}
@keyframes freshness-pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.75;
  }
}

/* Project cards & list UI */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(21rem, 1fr));
  gap: 1rem;
}
.project-card {
  position: relative;
  overflow: hidden;
  background: var(--surface-color);
  border: 1px solid var(--liberty-hairline);
  border-radius: var(--liberty-radius);
  padding: 1.1rem 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  box-shadow: var(--liberty-shadow);
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    transform 0.18s ease;
}
.project-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: #cbd5e1;
  opacity: 0;
  transition: opacity 0.18s ease;
}
.project-card:hover {
  border-color: rgb(0 191 154 / 0.32);
  box-shadow: var(--liberty-shadow-md);
  transform: translateY(-3px);
}
.project-card:hover::before {
  opacity: 1;
}
.project-card--healthy::before {
  background: var(--success-color);
  opacity: 1;
}
.project-card--warn::before {
  background: var(--warning-color);
  opacity: 1;
}
.project-card--critical::before {
  background: var(--error-color);
  opacity: 1;
}
.project-card--fresh-hot {
  border-color: rgb(0 191 154 / 0.4);
  background:
    linear-gradient(90deg, rgb(209 250 229 / 0.5), rgb(255 255 255 / 0) 45%),
    #fff;
  box-shadow: 0 0 0 1px rgb(0 191 154 / 0.14), 0 8px 22px rgb(0 43 73 / 0.08);
}
.project-card--fresh-warm {
  border-color: rgb(37 99 235 / 0.18);
  background:
    linear-gradient(90deg, rgb(239 246 255 / 0.9), rgb(255 255 255 / 0) 42%),
    #fff;
}
.project-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
}
.project-card__title-wrap {
  min-width: 0;
  flex: 1;
}
.project-card__title-row {
  display: flex;
  gap: 0.45rem;
  align-items: center;
  flex-wrap: wrap;
}
.project-card__icon {
  color: var(--brand-primary);
  font-size: 1.1rem;
}
.project-card__title {
  margin: 0;
  font-size: 1.02rem;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  letter-spacing: 0;
}
.project-card__slug {
  margin: 0.15rem 0 0 1.6rem;
  font-family: "JetBrains Mono", "SF Mono", Menlo, monospace;
  font-size: 0.72rem;
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.project-card__rate {
  font-size: 1.45rem;
  font-weight: 850;
  flex-shrink: 0;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0;
  line-height: 1;
}
.project-card__score {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.3rem;
  flex-shrink: 0;
}
.project-card__health {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.18rem 0.45rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 800;
  line-height: 1.1;
}
.project-card__health .material-icons {
  font-size: 0.9rem;
}
.project-card__health--healthy {
  background: #d1fae5;
  color: #047857;
}
.project-card__health--warn {
  background: #fef3c7;
  color: #92400e;
}
.project-card__health--critical {
  background: #fee2e2;
  color: #b91c1c;
}
.project-card__health--none {
  background: #f1f5f9;
  color: #64748b;
}
.project-card__progress {
  height: 0.45rem;
  overflow: hidden;
  border-radius: 999px;
  background: #e2e8f0;
}
.project-card__progress span {
  display: block;
  width: var(--project-pass-rate, 0%);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--brand-primary), var(--brand-light));
}
.project-card__pills {
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
  align-items: center;
  font-size: 0.7rem;
}
.project-card__pill {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  padding: 0.18rem 0.48rem;
  border-radius: 999px;
  font-weight: 700;
  border: 1px solid transparent;
}
.project-card__pill--secured {
  background: var(--liberty-teal-mist, #ecfdf5);
  color: var(--brand-dark, #002b49);
}
.project-card__pill--open {
  background: #fff7ed;
  color: #9a3412;
}
.project-card__pill--env {
  background: var(--background-color);
  color: var(--text-primary);
  font-weight: 600;
  border: 1px solid var(--border-color);
}
.project-card__pill--env-default {
  background: var(--liberty-teal-mist, #ecfdf5);
}
.project-card__stats {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0.45rem;
  font-size: 0.8rem;
}
.project-card__stat {
  background: #f8fafc;
  border: 1px solid rgb(226 232 240 / 0.85);
  border-radius: 7px;
  padding: 0.5rem 0.45rem;
  text-align: center;
}
.project-card__stat-value {
  font-size: 0.98rem;
  font-weight: 850;
  color: var(--text-primary);
  font-variant-numeric: tabular-nums;
}
.project-card__stat-value--warn {
  color: var(--error-color);
}
.project-card__stat-label {
  color: var(--text-secondary);
  font-size: 0.7rem;
}
.project-card__last-run {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.74rem;
  color: var(--text-secondary);
  margin: 0;
}
.project-card__last-run .material-icons {
  font-size: 0.95rem;
  color: #64748b;
}
.project-card__actions {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
  margin-top: auto;
  padding-top: 0.1rem;
}
.project-card__actions-compact {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

/* Filter pills */
.filter-pills {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}
.filter-pills__label {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.78rem;
  color: var(--text-secondary);
}
.filter-pills__label .material-icons {
  font-size: 14px;
}
.filter-pills__options {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.filter-pill-link {
  text-decoration: none;
  color: inherit;
}
.filter-pill-link--active,
.cockpit-v2-chip.filter-pill-link--active {
  border-color: var(--brand-primary, #00bf9a);
  background: var(--liberty-teal-mist, #ecfdf5);
  color: var(--brand-dark, #002b49);
  box-shadow: 0 0 0 1px rgb(0 191 154 / 0.25);
}

/* View toolbar */
.view-toolbar {
  margin-bottom: 0.75rem;
}

.view-toolbar--compact {
  border: 1px solid rgb(148 163 184 / 0.28);
  border-radius: var(--liberty-radius);
  background: #fff;
  box-shadow: 0 1px 1px rgb(15 23 42 / 0.04), 0 8px 20px rgb(15 23 42 / 0.05);
  overflow: hidden;
}

.view-toolbar-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.55rem;
  padding: 0.55rem 0.65rem;
}

.view-toolbar-searchbox--compact {
  flex: 1 1 12rem;
  min-width: min(100%, 10rem);
  min-height: 2.1rem;
  padding: 0 0.55rem;
}

.view-toolbar-searchbox--compact .cockpit-v2-search {
  padding: 0.35rem 0;
  font-size: 0.84rem;
}

.view-toolbar-sort-control--compact {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  flex: 0 1 auto;
}

.view-toolbar-sort-control--compact .cockpit-v2-select {
  min-width: 8.5rem;
  max-width: 11rem;
  padding: 0.42rem 0.55rem;
  font-size: 0.8rem;
}

.view-toolbar-view-toggle--icon {
  padding: 0.15rem;
}

.view-toolbar-view-toggle--icon .cockpit-v2-chip {
  min-height: 1.75rem;
  min-width: 1.75rem;
  padding: 0.25rem;
}

.view-toolbar-view-toggle--icon .cockpit-v2-chip .material-icons {
  font-size: 1rem;
  margin: 0;
}

.view-toolbar-filters-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  white-space: nowrap;
}

.view-toolbar-filters-toggle .material-icons {
  font-size: 1rem;
}

.view-toolbar-filters-toggle--open {
  border-color: rgb(0 191 154 / 0.45);
  background: #f0fdfa;
  color: #0f766e;
}

.view-toolbar-filters-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.1rem;
  height: 1.1rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 800;
  line-height: 1;
  color: #fff;
  background: var(--brand-primary, #00bf9a);
}

.view-toolbar-count {
  margin: 0 0 0 auto;
  font-size: 0.78rem;
  color: #64748b;
  white-space: nowrap;
}

.view-toolbar-count strong {
  color: var(--brand-dark);
  font-weight: 800;
}

.view-toolbar-count-sep {
  margin: 0 0.12rem;
  opacity: 0.55;
}

.view-toolbar-clear {
  margin-left: 0;
}

.view-toolbar-filters-panel {
  padding: 0.55rem 0.65rem 0.65rem;
  border-top: 1px solid rgb(226 232 240 / 0.9);
  background: rgb(248 250 252 / 0.85);
}

.view-toolbar-filters-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(9.5rem, 1fr));
  gap: 0.45rem 0.65rem;
}

.view-toolbar-filter-select {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.view-toolbar-filter-select > span {
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #64748b;
}

.view-toolbar-filter-select .cockpit-v2-select {
  width: 100%;
  min-width: 0;
  padding: 0.42rem 0.55rem;
  font-size: 0.8rem;
}

.view-toolbar-active-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  padding: 0 0.65rem 0.55rem;
  border-top: 1px solid rgb(226 232 240 / 0.75);
  background: rgb(248 250 252 / 0.55);
}

.view-toolbar-active-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  max-width: 100%;
  padding: 0.2rem 0.35rem 0.2rem 0.45rem;
  border: 1px solid rgb(203 213 225 / 0.9);
  border-radius: 999px;
  background: #fff;
  font: inherit;
  font-size: 0.72rem;
  color: #334155;
  cursor: pointer;
}

.view-toolbar-active-chip:hover {
  border-color: rgb(0 191 154 / 0.45);
  background: #f0fdfa;
}

.view-toolbar-active-chip-label {
  font-weight: 700;
  color: #64748b;
}

.view-toolbar-active-chip-value {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 10rem;
}

.view-toolbar-active-chip .material-icons {
  font-size: 0.9rem;
  color: #94a3b8;
}

.cockpit-v2-kpi--inline {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 0.65rem;
}

.cockpit-v2-kpi--inline .cockpit-v2-tile--inline {
  flex: 1 1 7rem;
  display: flex;
  align-items: baseline;
  gap: 0.45rem;
  padding: 0.45rem 0.7rem;
  min-width: 0;
}

.cockpit-v2-kpi--inline .cockpit-v2-tile-label {
  margin: 0;
  font-size: 0.68rem;
  white-space: nowrap;
}

.cockpit-v2-kpi--inline .cockpit-v2-tile-value {
  margin: 0;
  font-size: 1.05rem;
}

.cockpit-v2-kpi--inline .cockpit-v2-tile-hint {
  display: none;
}

.view-toolbar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid rgb(226 232 240 / 0.85);
  background:
    linear-gradient(90deg, rgb(0 43 73 / 0.04), rgb(0 191 154 / 0.05)),
    #fff;
}
.view-toolbar-eyebrow {
  display: block;
  margin-bottom: 0.1rem;
  font-size: 0.62rem;
  font-weight: 850;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #64748b;
}
.view-toolbar-title {
  display: block;
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--brand-dark);
}
.view-toolbar-searchbox {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 0.45rem;
  min-height: 2.45rem;
  padding: 0 0.65rem;
  border: 1px solid rgb(203 213 225 / 0.95);
  border-radius: 7px;
  background: #fff;
  box-shadow: 0 1px 1px rgb(15 23 42 / 0.03);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.view-toolbar-searchbox:focus-within {
  border-color: rgb(0 191 154 / 0.62);
  box-shadow: 0 0 0 3px rgb(0 191 154 / 0.12);
}
.view-toolbar-searchbox .material-icons {
  color: #64748b;
  font-size: 1.1rem;
}
.view-toolbar-view-toggle {
  display: inline-flex;
  gap: 0.25rem;
  flex-wrap: nowrap;
  padding: 0.22rem;
  border: 1px solid rgb(203 213 225 / 0.75);
  border-radius: 999px;
  background: #f8fafc;
}
.view-toolbar-view-toggle .cockpit-v2-chip {
  min-height: 1.85rem;
  border-color: transparent;
  box-shadow: none;
}
.view-toolbar-sort-control {
  display: grid;
  grid-template-columns: minmax(10rem, 1fr) auto;
  gap: 0.4rem;
}
.view-toolbar-sort-control .cockpit-v2-select {
  min-width: 0;
}

/* Project picker */
.project-picker {
  position: relative;
  min-width: 12rem;
}
.project-picker__label {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--liberty-text-muted);
  margin-bottom: 0.25rem;
}
.project-picker__trigger {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  width: 100%;
  text-align: left;
  cursor: pointer;
}
.project-picker__value {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.project-picker__dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 50;
  background: #fff;
  border: 1px solid var(--liberty-border);
  border-radius: var(--liberty-radius-sm);
  box-shadow: var(--liberty-shadow);
  padding: 0.5rem;
  min-width: 16rem;
}
.project-picker__search {
  margin-bottom: 0.5rem;
}
.project-picker__list {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 14rem;
  overflow-y: auto;
}
.project-picker__option {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  padding: 0.45rem 0.6rem;
  border: none;
  background: transparent;
  cursor: pointer;
  border-radius: var(--liberty-radius-sm);
  font-family: inherit;
  text-align: left;
}
.project-picker__option:hover,
.project-picker__option--active {
  background: var(--liberty-teal-mist, #ecfdf5);
}
.project-picker__option-name {
  font-weight: 600;
  font-size: 0.875rem;
}
.project-picker__option-id {
  font-size: 0.72rem;
  color: var(--text-secondary);
  font-family: monospace;
}
.project-picker__empty {
  padding: 0.5rem;
  color: var(--text-secondary);
  font-size: 0.875rem;
}

/* Breadcrumbs */
.page-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.78rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}
.page-breadcrumb a {
  color: var(--brand-primary);
  text-decoration: none;
}
.page-breadcrumb a:hover {
  text-decoration: underline;
}
.page-breadcrumb__sep {
  opacity: 0.5;
}

/* Freshness dot on home bars */
.freshness-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand-primary);
  margin-left: 0.35rem;
  animation: freshness-pulse 2s ease-in-out infinite;
}

/* Run freshness banner */
.run-freshness-banner {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1rem;
  margin-bottom: 1rem;
  border-radius: var(--liberty-radius-sm);
  background: var(--liberty-teal-mist, #ecfdf5);
  border: 1px solid rgb(0 191 154 / 0.3);
  font-size: 0.875rem;
  color: var(--brand-dark, #002b49);
}

/* Page header toolbar row */
.page-header-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 1rem;
  margin-bottom: 1rem;
}

@media (max-width: 640px) {
  .cockpit-v2-filters-row {
    grid-template-columns: 1fr;
  }
  .cockpit-v2-preset-group {
    grid-template-columns: 1fr;
  }
  .view-toolbar-bar {
    align-items: stretch;
  }
  .view-toolbar-searchbox--compact {
    flex-basis: 100%;
  }
  .view-toolbar-count {
    margin-left: 0;
  }
  .view-toolbar-header {
    align-items: flex-start;
  }
  .project-picker__dropdown {
    position: fixed;
    left: 1rem;
    right: 1rem;
    top: auto;
  }
}

.matrix-pr {
  margin-top: 1.25rem;
}
.matrix-pr-header {
  margin-bottom: 1rem;
}
.matrix-pr-heading {
  margin: 0 0 0.35rem;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--liberty-ink, #0f172a);
  line-height: 1.3;
}

@media (min-width: 640px) {
  .matrix-pr-heading {
    font-size: 1.25rem;
  }
}
.matrix-pr-meta {
  margin: 0;
  font-size: 0.875rem;
  color: var(--liberty-text-muted, #64748b);
  line-height: 1.5;
}
.matrix-pr-link {
  color: var(--liberty-accent, #0c4a6e);
  text-decoration: underline;
}
.matrix-pr-code {
  font-size: 0.8em;
  background: #f1f5f9;
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
}
.matrix-pr-warnings {
  margin: 0 0 1rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--liberty-radius-sm, 6px);
  border: 1px solid #fde68a;
  background: #fffbeb;
  font-size: 0.8125rem;
  color: #92400e;
}

.matrix-pr-mirror-hint {
  margin: 0.65rem 0 0;
  font-size: 0.8125rem;
  line-height: 1.45;
  color: #64748b;
}

.matrix-pr-kbd {
  display: inline-block;
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
  font-size: 0.75em;
  font-family: inherit;
  background: #f8fafc;
  color: #475569;
}

.matrix-pr-split-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: stretch;
  max-width: 100%;
}

.matrix-pr-pane {
  flex: 1 1 calc(50% - 0.35rem);
  min-width: min(100%, 18rem);
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.matrix-pr-pane-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--liberty-text-muted, #64748b);
  padding-left: 0.1rem;
}

.matrix-pr-scroll {
  overflow-x: auto;
  border: 1px solid var(--liberty-border, #e2e8f0);
  border-radius: var(--liberty-radius-sm, 6px);
  background: #fff;
}

.matrix-pr-scroll--pane {
  overflow: auto;
  flex: 1 1 auto;
  min-height: 0;
  max-width: 100%;
}

.matrix-pr-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8125rem;
}

.matrix-pr-table--pane {
  width: max-content;
  min-width: 100%;
}

@media (max-width: 720px) {
  .matrix-pr-split-wrap {
    flex-direction: column;
  }

  .matrix-pr-pane {
    flex-basis: auto;
    min-width: 0;
  }
}

.matrix-pr-table th,
.matrix-pr-table td {
  padding: 0.45rem 0.55rem;
  border-bottom: 1px solid #e2e8f0;
  vertical-align: middle;
}

.matrix-pr-table thead th {
  background: #f8fafc;
  font-weight: 600;
  text-align: left;
  white-space: nowrap;
}

.matrix-pr-section {
  padding: 0.5rem 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-align: center;
  border-bottom: 2px solid #cbd5e1;
}

.matrix-pr-section--planned {
  background: linear-gradient(180deg, #ecfdf5 0%, #d1fae5 100%);
  color: #065f46;
}

.matrix-pr-section--realized {
  background: linear-gradient(180deg, #eff6ff 0%, #dbeafe 100%);
  color: #1e40af;
}

.matrix-pr-corner-head {
  vertical-align: middle;
  z-index: 3;
  min-width: 6.5rem;
  max-width: 10rem;
}

.matrix-pr-split {
  border-left: 2px solid #94a3b8;
}

.matrix-pr-mirror-cell {
  cursor: pointer;
  user-select: none;
  transition: background 0.12s ease, box-shadow 0.12s ease;
}

.matrix-pr-mirror-lit {
  background: rgb(254 249 195 / 0.95) !important;
  box-shadow: inset 0 0 0 1px #f59e0b;
}

.matrix-pr-mirror-pinned {
  background: rgb(254 240 138 / 0.98) !important;
  box-shadow: inset 0 0 0 2px #d97706;
}

.matrix-pr-sticky-col {
  position: sticky;
  left: 0;
  z-index: 1;
  background: #fff;
  box-shadow: 2px 0 4px rgba(15, 23, 42, 0.06);
  min-width: 6.5rem;
}

.matrix-pr-table thead .matrix-pr-sticky-col {
  background: #f8fafc;
  z-index: 2;
}

.matrix-pr-table thead .matrix-pr-corner-head {
  background: #f8fafc;
}
.matrix-pr-num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.matrix-pr-total {
  font-weight: 600;
  background: #fafafa;
}
.matrix-pr-saldo-th {
  min-width: 10rem;
}

.matrix-pr-saldo-th--head {
  min-width: 8.5rem;
}
.matrix-pr-footer th,
.matrix-pr-footer td {
  background: #f1f5f9;
  font-weight: 600;
}

.matrix-pr-footer .matrix-pr-sticky-col {
  background: #f1f5f9;
}

.matrix-pr-capacity th,
.matrix-pr-capacity td {
  background: #ecfeff;
}

.matrix-pr-capacity .matrix-pr-sticky-col {
  background: #ecfeff;
}
.matrix-pr-saldo-cell {
  white-space: nowrap;
  max-width: 14rem;
}

.matrix-pr-saldo {
  display: inline;
  text-align: right;
  font-size: 0.78rem;
}

.matrix-pr-saldo-ref {
  display: inline;
  font-weight: 400;
  color: #64748b;
  font-size: 0.72rem;
  margin-left: 0.25rem;
}

@media (max-width: 639px) {
  .matrix-pr-saldo-cell {
    white-space: normal;
    max-width: none;
  }

  .matrix-pr-saldo-ref {
    display: block;
    margin-left: 0;
    margin-top: 0.15rem;
  }
}
.matrix-pr-grand {
  margin-top: 1.25rem;
  font-size: 0.875rem;
  color: var(--liberty-text-muted, #64748b);
}

/* Capacidade — layout */
.capacity-shell {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.capacity-hero {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid rgb(15 23 42 / 0.08);
}

.capacity-hero-main {
  display: contents;
}

.capacity-pill--snapshots {
  position: relative;
}

.capacity-pill-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.15rem;
  padding: 0 0.3rem;
  margin-left: 0.15rem;
  border-radius: 999px;
  font-size: 0.65rem;
  font-weight: 800;
  background: #e0f2fe;
  color: #0369a1;
}

.capacity-snapshots-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1950;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgb(15 23 42 / 0.45);
  backdrop-filter: blur(4px);
}

.capacity-snapshots-modal-panel {
  width: min(26rem, 100%);
  max-height: min(85vh, 40rem);
  display: flex;
  flex-direction: column;
  border-radius: 12px;
  border: 1px solid rgb(15 23 42 / 0.1);
  background: #fff;
  box-shadow:
    0 8px 40px rgb(15 23 42 / 0.18),
    0 0 0 1px rgb(255 255 255 / 0.06) inset;
  overflow: hidden;
}

.capacity-snapshots-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid rgb(15 23 42 / 0.08);
  background: linear-gradient(180deg, #fafafa 0%, #fff 100%);
  flex-shrink: 0;
}

.capacity-snapshots-modal-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
}

.capacity-snapshots-modal-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.25rem;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: #64748b;
  cursor: pointer;
}

.capacity-snapshots-modal-close:hover {
  background: rgb(15 23 42 / 0.06);
  color: #0f172a;
}

.capacity-snapshots-modal-close .material-icons {
  font-size: 1.35rem !important;
}

.capacity-snapshots-modal-empty {
  margin: 0;
  padding: 1.25rem 1rem;
  font-size: 0.875rem;
  color: #64748b;
  line-height: 1.45;
}

.capacity-snapshots-modal-list {
  margin: 0;
  padding: 0.65rem 1rem 1rem;
  list-style: none;
  overflow-y: auto;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.capacity-snapshots-modal-pager {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem 0.75rem;
  padding: 0.65rem 1rem;
  border-top: 1px solid rgb(15 23 42 / 0.08);
  background: #fafafa;
  flex-shrink: 0;
}

.capacity-snapshots-modal-page-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #334155;
}

.capacity-snapshots-modal-page-muted {
  font-weight: 500;
  color: #94a3b8;
}

.capacity-snapshots-modal-page-note {
  margin: 0;
  padding: 0 1rem 0.85rem;
  font-size: 0.75rem;
  color: #94a3b8;
  text-align: center;
}

.capacity-snapshot-card {
  border-radius: 10px;
  border: 1px solid rgb(15 23 42 / 0.1);
  background: linear-gradient(165deg, #fafafa 0%, #fff 55%);
  padding: 0.65rem 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.04);
}

.capacity-snapshot-card--modal {
  width: 100%;
}

.capacity-snapshot-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.35rem;
}

.capacity-snapshot-titles {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
}

.capacity-snapshot-date {
  font-size: 0.8125rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.25;
}

.capacity-snapshot-code {
  font-size: 0.6875rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: #94a3b8;
}

.capacity-snapshot-badge {
  flex-shrink: 0;
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  background: #d1fae5;
  color: #065f46;
}

.capacity-snapshot-stats {
  font-size: 0.75rem;
  color: #475569;
  line-height: 1.35;
}

.capacity-snapshot-hours {
  font-weight: 800;
  font-size: 0.9375rem;
  color: #0f172a;
  font-variant-numeric: tabular-nums;
}

.capacity-snapshot-stat-muted {
  font-weight: 500;
  color: #64748b;
}

.capacity-snapshot-sep {
  margin: 0 0.2rem;
  opacity: 0.45;
}

.capacity-snapshot-preview {
  margin: 0;
  font-size: 0.6875rem;
  line-height: 1.4;
  color: #64748b;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-break: break-word;
}

.capacity-snapshot-restore {
  align-self: flex-start;
  margin-top: 0.15rem;
}

.capacity-snapshot-restore .material-icons {
  font-size: 1rem !important;
}

.capacity-hero-title {
  margin: 0;
  font-size: clamp(1.35rem, 2.5vw, 1.65rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: #0f172a;
  line-height: 1.15;
}

.capacity-hero-sub {
  margin: 0.35rem 0 0;
  font-size: 0.8125rem;
  color: #64748b;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
}

.capacity-hero-dot {
  opacity: 0.45;
}

.capacity-hero-link {
  color: #0d9488;
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid rgb(13 148 136 / 0.35);
}

.capacity-hero-link:hover {
  color: #0f766e;
  border-bottom-color: #0f766e;
}

.capacity-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

@media (max-width: 540px) {
  .capacity-hero-actions {
    width: 100%;
  }

  .capacity-hero-actions .capacity-pill {
    flex: 1;
    justify-content: center;
  }
}

.capacity-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  font-size: 0.8125rem;
  font-weight: 600;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.capacity-pill:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.capacity-pill-icon {
  font-size: 1.1rem !important;
  opacity: 0.9;
}

.capacity-pill--primary {
  background: linear-gradient(180deg, #14b8a6 0%, #0d9488 100%);
  color: #fff;
  border-color: rgb(13 148 136 / 0.5);
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.08);
}

.capacity-pill--primary:hover:not(:disabled) {
  filter: brightness(1.05);
}

.capacity-pill--secondary {
  background: #fff;
  color: #0f172a;
  border-color: #e2e8f0;
}

.capacity-pill--secondary:hover:not(:disabled) {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.capacity-pill--ghost {
  background: #fff;
  color: #475569;
  border-color: #e2e8f0;
}

.capacity-pill--ghost:hover:not(:disabled) {
  background: #f8fafc;
  color: #0f172a;
}

.capacity-pill--sm {
  padding: 0.3rem 0.65rem;
  font-size: 0.75rem;
}

.capacity-flash {
  padding: 0.6rem 0.85rem;
  border-radius: 8px;
  font-size: 0.8125rem;
  font-weight: 500;
}

.capacity-flash--error {
  border: 1px solid #fecaca;
  background: linear-gradient(180deg, #fff 0%, #fef2f2 100%);
  color: #991b1b;
}

.capacity-flash--ok {
  border: 1px solid #a7f3d0;
  background: linear-gradient(180deg, #ecfdf5 0%, #d1fae5 100%);
  color: #065f46;
}

.capacity-archive-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  background: rgb(15 23 42 / 0.45);
  backdrop-filter: blur(4px);
}

.capacity-archive-panel {
  width: min(22rem, 100%);
  border-radius: 12px;
  border: 1px solid rgb(15 23 42 / 0.1);
  background: #fff;
  box-shadow:
    0 4px 24px rgb(15 23 42 / 0.12),
    0 0 0 1px rgb(255 255 255 / 0.06) inset;
  padding: 1.25rem 1.35rem;
  text-align: center;
}

.capacity-archive-title {
  margin: 0 0 0.85rem;
  font-size: 0.9375rem;
  font-weight: 700;
  color: #0f172a;
}

.capacity-archive-bar-wrap {
  height: 0.5rem;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}

.capacity-archive-bar {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #0ea5e9, #6366f1);
  transition: width 0.2s ease-out;
}

.capacity-archive-pct {
  margin: 0.65rem 0 0.35rem;
  font-size: 1.35rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: #0f172a;
  letter-spacing: -0.02em;
}

.capacity-archive-label {
  margin: 0;
  font-size: 0.8125rem;
  line-height: 1.4;
  color: #64748b;
}

.capacity-restore-overlay {
  position: fixed;
  inset: 0;
  z-index: 1900;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  background: rgb(15 23 42 / 0.4);
  backdrop-filter: blur(3px);
}

.capacity-restore-panel {
  width: min(26rem, 100%);
  border-radius: 12px;
  border: 1px solid rgb(15 23 42 / 0.1);
  background: #fff;
  padding: 1.25rem 1.35rem 1.1rem;
  box-shadow:
    0 8px 32px rgb(15 23 42 / 0.14),
    0 0 0 1px rgb(255 255 255 / 0.06) inset;
}

.capacity-restore-title {
  margin: 0 0 0.65rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: #0f172a;
}

.capacity-restore-text {
  margin: 0 0 1rem;
  font-size: 0.875rem;
  line-height: 1.5;
  color: #475569;
}

.capacity-restore-check {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin: 0 0 1.1rem;
  font-size: 0.8125rem;
  line-height: 1.45;
  color: #334155;
  cursor: pointer;
}

.capacity-restore-check input {
  margin-top: 0.15rem;
  flex-shrink: 0;
}

.capacity-restore-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.capacity-skeleton {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0.5rem 0;
}

.capacity-skeleton-line {
  height: 0.65rem;
  border-radius: 4px;
  background: linear-gradient(
    90deg,
    #f1f5f9 0%,
    #e2e8f0 50%,
    #f1f5f9 100%
  );
  background-size: 200% 100%;
  animation: capacity-shimmer 1.2s ease-in-out infinite;
}

.capacity-skeleton-line--short {
  width: 55%;
}

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

.capacity-sync-details {
  border-radius: 8px;
  border: 1px solid rgb(15 23 42 / 0.08);
  background: #fafafa;
  font-size: 0.75rem;
  color: #64748b;
}

.capacity-sync-summary {
  padding: 0.45rem 0.65rem;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 600;
  color: #475569;
}

.capacity-sync-summary::-webkit-details-marker {
  display: none;
}

.capacity-sync-summary-icon {
  font-size: 1rem !important;
  color: #94a3b8;
}

.capacity-sync-list {
  margin: 0;
  padding: 0 0.85rem 0.65rem 1.85rem;
  line-height: 1.45;
}

.capacity-card {
  border-radius: 12px;
  border: 1px solid rgb(15 23 42 / 0.08);
  background: #fff;
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.04), 0 4px 12px rgb(15 23 42 / 0.04);
}

.capacity-card--controls {
  padding: 0.65rem 1rem;
}

.capacity-controls-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 1rem;
}

.capacity-restore-toolbar {
  margin-top: 0.85rem;
  padding-top: 0.85rem;
  border-top: 1px solid rgb(15 23 42 / 0.08);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.5rem;
  width: 100%;
}

.capacity-restore-toolbar-label {
  display: block;
  margin-bottom: 0.1rem;
}

.capacity-restore-inline-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
}

.capacity-field-select--grow {
  flex: 1;
  min-width: 12rem;
}

.capacity-period-hint {
  margin: 0;
  font-size: 0.75rem;
  line-height: 1.45;
  color: #64748b;
  max-width: 40rem;
}

.capacity-period-hint--tight {
  margin-bottom: 0.15rem;
}

.capacity-controls-spacer {
  flex: 1;
  min-width: 0.5rem;
}

.capacity-field {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.capacity-field-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #94a3b8;
}

.capacity-field-select {
  min-width: 11rem;
  padding: 0.45rem 0.65rem;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  background: #fff;
  font: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  color: #0f172a;
}

.capacity-field-select:focus {
  outline: none;
  border-color: #14b8a6;
  box-shadow: 0 0 0 3px rgb(20 184 166 / 0.2);
}

.capacity-field-select--grow {
  flex: 1;
  min-width: 0;
  width: 100%;
}

.capacity-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.capacity-badge--live {
  background: rgb(20 184 166 / 0.12);
  color: #0f766e;
}

.capacity-badge--archive {
  background: #f1f5f9;
  color: #64748b;
}

.capacity-readonly-chip {
  margin: 0;
  font-size: 0.75rem;
  color: #94a3b8;
}

.capacity-inline-confirm {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.6rem;
}

.capacity-inline-confirm--stack {
  flex-direction: column;
  align-items: stretch;
}

.capacity-inline-confirm-text {
  font-size: 0.75rem;
  color: #475569;
  line-height: 1.35;
}

.capacity-inline-confirm-actions {
  display: flex;
  gap: 0.4rem;
}

.capacity-split {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0;
  padding: 1rem 1.1rem;
  align-items: stretch;
}

@media (max-width: 720px) {
  .capacity-split {
    grid-template-columns: 1fr;
  }

  .capacity-split-divider {
    height: 1px;
    width: 100% !important;
    min-height: 0;
  }
}

.capacity-split-col {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.capacity-split-head {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.capacity-split-icon {
  font-size: 1.1rem !important;
  color: #94a3b8;
}

.capacity-split-title {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #64748b;
}

.capacity-split-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.capacity-split-muted {
  margin: 0;
  font-size: 0.8125rem;
  color: #94a3b8;
  line-height: 1.4;
}

.capacity-split-ok {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.8125rem;
  color: #15803d;
  font-weight: 600;
}

.capacity-split-ok .material-icons {
  font-size: 1.1rem !important;
}

.capacity-split-divider {
  width: 1px;
  min-height: 3rem;
  background: linear-gradient(
    180deg,
    transparent,
    #e2e8f0 15%,
    #e2e8f0 85%,
    transparent
  );
  align-self: stretch;
}

.capacity-code {
  font-size: 0.75rem;
  padding: 0.05rem 0.25rem;
  border-radius: 4px;
  background: #f1f5f9;
}

.capacity-panel {
  overflow: hidden;
}

.capacity-panel--matrix {
  border-radius: 12px;
  border: 1px solid rgb(15 23 42 / 0.08);
  background: #fff;
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.04), 0 8px 28px rgb(15 23 42 / 0.06);
}

.capacity-panel-head {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid rgb(15 23 42 / 0.06);
  background: linear-gradient(180deg, #fafafa 0%, #fff 100%);
}

.capacity-panel-headline {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.capacity-panel-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #0f172a;
}

.capacity-panel-tagline {
  margin: 0;
  font-size: 0.75rem;
  color: #94a3b8;
}

.capacity-micro-icon {
  font-size: 0.95rem !important;
  vertical-align: -3px;
  color: #cbd5e1;
}

.capacity-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.capacity-table {
  width: 100%;
  min-width: 520px;
  border-collapse: collapse;
  font-size: 0.8125rem;
}

.capacity-th,
.capacity-td {
  padding: 0.5rem 0.6rem;
  border-bottom: 1px solid #e2e8f0;
  text-align: left;
  vertical-align: middle;
}

.capacity-th {
  background: #f8fafc;
  font-weight: 600;
  color: #334155;
  font-size: 0.78rem;
}

.capacity-th--sticky,
.capacity-td--sticky {
  position: sticky;
  left: 0;
  z-index: 1;
  min-width: 8rem;
  max-width: 14rem;
  background: #fff;
  box-shadow: 2px 0 4px rgba(15, 23, 42, 0.05);
}

.capacity-th--sticky {
  z-index: 2;
  background: #f8fafc;
}

.capacity-th-num,
.capacity-td-num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.capacity-th-project {
  max-width: 7rem;
  overflow: hidden;
  text-overflow: ellipsis;
}

.capacity-th-hint {
  display: block;
  font-weight: 400;
  font-size: 0.68rem;
  color: #64748b;
  margin-top: 0.15rem;
}

.capacity-th-actions {
  width: 3rem;
  text-align: center;
}

.capacity-empty {
  padding: 1.25rem 1rem !important;
  text-align: center;
  color: #64748b;
  font-size: 0.875rem;
}

.capacity-input {
  width: 5.25rem;
  max-width: 100%;
  padding: 0.4rem 0.45rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font: inherit;
  font-size: 0.8125rem;
  text-align: right;
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.capacity-input:focus {
  outline: none;
  border-color: #14b8a6;
  box-shadow: 0 0 0 3px rgb(20 184 166 / 0.18);
}

.capacity-input:disabled {
  cursor: wait;
  opacity: 0.92;
  background: #f1f5f9;
  color: #0f172a;
}

.capacity-td-actions {
  text-align: center;
  width: 3rem;
}

.capacity-icon-btn {
  display: inline-flex;
  padding: 0.35rem;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: #94a3b8;
  cursor: pointer;
}

.capacity-icon-btn:hover {
  background: #f1f5f9;
  color: #b91c1c;
}

.capacity-input--readonly {
  cursor: default;
  background: #f8fafc;
  color: #0f172a;
}

.capacity-th--drag {
  width: 2.5rem;
  min-width: 2.5rem;
  padding: 0.35rem;
  text-align: center;
}

.capacity-td-drag {
  position: sticky;
  left: 0;
  z-index: 2;
  width: 2.5rem;
  min-width: 2.5rem;
  padding: 0.25rem;
  text-align: center;
  vertical-align: middle;
  background: #fff;
  box-shadow: 2px 0 4px rgba(15, 23, 42, 0.05);
}

.capacity-th--sticky:not(.capacity-th--drag) {
  left: 2.5rem;
}

.capacity-td-name.capacity-td--sticky {
  left: 2.5rem;
}

.capacity-drag-handle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.2rem;
  border-radius: 6px;
  color: #94a3b8;
  cursor: grab;
}

.capacity-drag-handle:active {
  cursor: grabbing;
}

.capacity-drag-handle:hover {
  background: #f1f5f9;
  color: #475569;
}

.capacity-drag-handle .material-icons {
  font-size: 1.35rem;
}

/* Novo quadro (provisionamento) */
.page-header--provision {
  margin-bottom: 1.5rem;
}

.page-lede--tight {
  max-width: 28rem;
}

.provision-flow {
  flex: 1;
  min-width: 0;
}

.provision-muted {
  font-size: 0.9rem;
  color: var(--liberty-text-muted);
}

.provision-alert {
  border-radius: var(--liberty-radius);
  padding: 1rem 1.1rem;
  margin-bottom: 1.25rem;
  font-size: 0.9rem;
  line-height: 1.5;
}

.provision-alert--error {
  border: 1px solid rgb(254 202 202);
  background: rgb(254 242 242);
  color: rgb(127 29 29);
}

.provision-alert--ok {
  border: 1px solid rgb(167 243 208);
  background: rgb(240 253 244);
  color: rgb(20 83 45);
}

.provision-success-title {
  display: block;
  font-size: 0.95rem;
  margin-bottom: 0.35rem;
}

.provision-success-line {
  margin: 0 0 0.75rem;
  font-weight: 600;
}

.provision-id {
  font-weight: 500;
  opacity: 0.85;
  font-family: ui-monospace, monospace;
  font-size: 0.88em;
}

.provision-success-hint {
  margin: 0.75rem 0 0;
  font-size: 0.8125rem;
}

.provision-link-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.45rem 0.85rem;
  border-radius: var(--liberty-radius-sm);
  background: var(--brand-dark);
  color: #fff !important;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.875rem;
  border: none;
  transition: background 0.15s ease;
}

.provision-link-btn:hover {
  background: #003d6b;
}

.provision-link-btn .material-icons {
  font-size: 1.15rem;
}

.provision-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  max-width: min(52rem, 100%);
}

.provision-fieldset {
  border: none;
  padding: 0;
  margin: 0;
}

.provision-legend {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--liberty-text-muted);
  margin-bottom: 0.65rem;
}

.provision-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
}

@media (min-width: 520px) {
  .provision-cards {
    grid-template-columns: 1fr 1fr;
  }
}

.provision-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.35rem;
  padding: 1rem 1.1rem;
  border-radius: var(--liberty-radius);
  border: 2px solid var(--liberty-border);
  background: var(--liberty-bg);
  text-align: left;
  font: inherit;
  cursor: pointer;
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease,
    background 0.15s ease;
}

.provision-card:hover:not(:disabled) {
  border-color: rgb(110 176 204 / 0.55);
  box-shadow: var(--liberty-shadow);
}

.provision-card--selected {
  border-color: var(--brand-primary);
  background: linear-gradient(
    180deg,
    rgb(0 191 154 / 0.08) 0%,
    var(--liberty-bg) 100%
  );
  box-shadow: var(--liberty-shadow);
}

.provision-card--disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.provision-card-icon {
  font-size: 1.75rem;
  color: var(--brand-dark);
}

.provision-card-icon--muted {
  color: var(--text-secondary);
}

.provision-card-label {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--liberty-text);
  line-height: 1.35;
}

.provision-card-badge {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--warning-color);
}

.provision-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.provision-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--liberty-text);
}

.provision-input,
.provision-select {
  width: 100%;
  max-width: 100%;
  padding: 0.6rem 0.75rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: #fff;
  font: inherit;
  font-size: 0.9375rem;
}

.provision-input:focus,
.provision-select:focus {
  outline: 2px solid rgb(0 191 154 / 0.35);
  outline-offset: 1px;
  border-color: var(--brand-primary);
}

.provision-actions {
  padding-top: 0.25rem;
}

.provision-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 2.75rem;
  padding: 0 1.25rem;
  border: none;
  border-radius: var(--liberty-radius);
  background: var(--brand-primary);
  color: #fff;
  font-weight: 600;
  font-size: 0.9375rem;
  cursor: pointer;
  transition: background 0.15s ease;
}

.provision-submit:hover:not(:disabled) {
  background: var(--primary-hover);
}

.provision-submit:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.provision-submit-icon {
  font-size: 1.25rem;
}

.provision-toggle-wrap {
  margin-bottom: 0.25rem;
}

.provision-toggle {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--liberty-text);
  cursor: pointer;
}

.provision-toggle input {
  margin-top: 0.2rem;
  width: 1.1rem;
  height: 1.1rem;
  accent-color: var(--brand-primary);
}

.provision-toggle--inline {
  margin-bottom: 0.65rem;
}

.provision-file-btn--disabled {
  opacity: 0.45;
  pointer-events: none;
}

.provision-branding {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 0.25rem;
}

.provision-branding-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem;
}

.provision-color-wrap {
  display: inline-flex;
  flex-shrink: 0;
}

.provision-color-input {
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 1px solid var(--liberty-border);
  border-radius: var(--liberty-radius-sm);
  cursor: pointer;
  background: transparent;
}

.provision-input--hex {
  max-width: 7.5rem;
  font-family: ui-monospace, monospace;
  font-size: 0.875rem;
}

.provision-file-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.45rem 0.75rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: var(--liberty-bg);
  font-size: 0.8125rem;
  font-weight: 600;
  cursor: pointer;
  position: relative;
}

.provision-file-btn:hover {
  border-color: rgb(110 176 204 / 0.55);
}

.provision-file-native {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
}

.provision-file-btn:has(.provision-file-native:disabled) {
  opacity: 0.5;
  cursor: not-allowed;
}

.provision-hint {
  font-size: 0.78rem;
  line-height: 1.45;
  margin: 0;
}

.provision-hint--warn {
  color: #b45309;
}

.provision-icon-preview {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.provision-icon-preview img {
  border-radius: 6px;
  border: 1px solid var(--liberty-border);
  object-fit: cover;
}

.provision-warnings {
  margin: 0.75rem 0 0;
  padding-left: 1.2rem;
  font-size: 0.8125rem;
  color: #92400e;
  line-height: 1.45;
}

.capacity-row--drop {
  outline: 2px dashed var(--brand-primary);
  outline-offset: -2px;
  background: rgb(0 191 154 / 0.06);
}

.capacity-table thead .capacity-th--drag {
  background: #f8fafc;
  z-index: 3;
}

/* ——— Home / Início executive dashboard ——— */
.home-dash {
  margin-bottom: 0.5rem;
}

.home-dash-banner {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  padding: 0.85rem 1rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  margin-bottom: 1rem;
  font-size: 0.875rem;
  line-height: 1.45;
}

.home-dash-banner .material-icons {
  flex-shrink: 0;
  font-size: 1.35rem;
}

.home-dash-banner--warn {
  background: rgb(254 243 199 / 0.55);
  border-color: rgb(245 158 11 / 0.45);
}

.home-dash-kpi-compact {
  font-size: 1.15rem !important;
  font-weight: 700 !important;
}

.home-dash-chart-sub {
  margin: -0.35rem 0 0.65rem;
}

.home-dash-donut-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.25rem 1.75rem;
}

.home-dash-donut {
  width: min(11rem, 42vw);
  height: min(11rem, 42vw);
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: var(--liberty-shadow-md);
  display: grid;
  place-items: center;
}

.home-dash-donut-hole {
  width: 58%;
  height: 58%;
  border-radius: 50%;
  background: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 1px 2px rgb(0 0 0 / 0.06);
}

.home-dash-donut-value {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--liberty-accent-deep);
  letter-spacing: -0.03em;
}

.home-dash-donut-caption {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--liberty-text-muted);
}

.home-dash-legend {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 0.8125rem;
  color: var(--liberty-text);
  display: grid;
  gap: 0.45rem;
}

.home-dash-legend li {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.home-dash-swatch {
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 2px;
  flex-shrink: 0;
}

.home-dash-swatch--pass {
  background: #10b981;
}

.home-dash-swatch--flaky {
  background: #f59e0b;
}

.home-dash-swatch--fail {
  background: #ef4444;
}

.home-dash-swatch--skip {
  background: #94a3b8;
}

.home-dash-bar-list {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.home-dash-bar-item {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.home-dash-bar-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
}

.home-dash-project-link {
  font-weight: 600;
  font-size: 0.875rem;
}

.home-dash-bar-meta {
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
  color: var(--liberty-text-muted);
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.home-dash-bar-badge {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #b91c1c;
  background: rgb(254 226 226 / 0.85);
  padding: 0.15rem 0.35rem;
  border-radius: 4px;
}

.home-dash-bar-track {
  height: 0.55rem;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}

.home-dash-bar-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.35s ease;
}

.home-dash-chart-wrap-trend {
  height: 240px;
}

.home-dash-svg-trend {
  width: 100%;
  height: 100%;
  display: block;
}

.home-dash-empty-chart {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 160px;
  padding: 1rem;
  text-align: center;
  font-size: 0.875rem;
  color: var(--liberty-text-muted);
  border: 1px dashed var(--liberty-border);
  border-radius: var(--liberty-radius-sm);
  background: #fafafa;
}

.home-dash-timeline-axis {
  display: flex;
  justify-content: space-between;
  margin-top: 0.35rem;
  font-size: 0.72rem;
  color: var(--liberty-text-muted);
}

.home-dash-risk-pill {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.2rem 0.45rem;
  border-radius: 4px;
}

.home-dash-risk-pill--fail {
  background: rgb(254 226 226 / 0.9);
  color: #991b1b;
}

.home-dash-risk-pill--flaky {
  background: rgb(254 243 199 / 0.95);
  color: #92400e;
}

.home-dash-link-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
  gap: 0.85rem;
}

.home-dash-quick-card {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 1rem 1.1rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: #fff;
  box-shadow: var(--liberty-shadow);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.home-dash-quick-card:hover {
  border-color: rgb(110 176 204 / 0.55);
  box-shadow: var(--liberty-shadow-md);
}

.home-dash-quick-icon {
  font-size: 1.75rem !important;
  color: var(--brand-dark);
  opacity: 0.85;
}

.home-dash-quick-label {
  font-weight: 700;
  font-size: 0.9rem;
}

.home-dash-quick-hint {
  font-size: 0.72rem;
  color: var(--liberty-text-muted);
}

.home-dash-onboarding-hero {
  margin-bottom: 1.25rem;
}

.home-dash-onboarding-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1rem;
}

.home-dash-onboarding-actions a {
  text-decoration: none;
}

.home-dash-onboarding-icon-wrap {
  align-self: center;
  justify-self: end;
  opacity: 0.88;
}

.home-dash-onboarding-icon {
  font-size: 3.75rem !important;
  color: var(--liberty-accent-deep);
}

.home-dash-footer-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 1rem;
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--liberty-border);
  background: linear-gradient(145deg, #fff 0%, rgb(232 244 248 / 0.55) 100%);
}

.home-dash-footer-cta-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--liberty-text-muted);
}

.home-dash-footer-cta-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.875rem;
}

.home-dash-footer-cta-links a {
  color: var(--brand-dark);
  font-weight: 600;
  text-decoration: none;
}

.home-dash-footer-cta-links a:hover {
  text-decoration: underline;
}

.home-dash-footer-dot {
  color: var(--liberty-text-muted);
  user-select: none;
}

@media (min-width: 960px) {
  .cockpit-v2-kpi:has(+ .cockpit-v2-charts) {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* ── Run detail page: details/summary chevron rotation ── */
details .details-chevron {
  transition: transform 0.18s ease;
}
details[open] > summary .details-chevron {
  transform: rotate(180deg);
}
details > summary {
  list-style: none;
}
details > summary::-webkit-details-marker {
  display: none;
}

/* Test dashboard — execution card hover (no client handlers on server component) */
.td-execution-card:hover {
  box-shadow: var(--liberty-shadow-md, var(--liberty-shadow));
  transform: translateY(-2px);
}

a.cockpit-project-title-link:hover {
  color: var(--brand-primary) !important;
}

/* ---------------------------------------------------------------------------
   Evidence image fallback — shown when a screenshot artifact fails to load
   (progressive enhancement via islands/EvidenceImageFallback.tsx).
   --------------------------------------------------------------------------- */
.evidence-img-fallback {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.15rem;
  width: 100%;
  min-height: 160px;
  padding: 1.5rem 1rem;
  text-align: center;
  border-radius: var(--liberty-radius-sm);
  border: 1px dashed rgb(148 163 184 / 0.55);
  background:
    repeating-linear-gradient(
      -45deg,
      rgb(148 163 184 / 0.05) 0,
      rgb(148 163 184 / 0.05) 10px,
      transparent 10px,
      transparent 20px
    ),
    #f8fafc;
  color: #94a3b8;
}
.evidence-img-fallback .material-icons {
  font-size: 2rem;
  color: #cbd5e1;
}
.evidence-img-fallback-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: #64748b;
}
.evidence-img-fallback-sub {
  font-size: 0.72rem;
  font-family: "JetBrains Mono", "SF Mono", Menlo, monospace;
  color: #94a3b8;
  word-break: break-all;
}

/* ---------------------------------------------------------------------------
   Notification cards — severity-accented for fast triage
   --------------------------------------------------------------------------- */
.notif-card {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  padding: 0.9rem 1.1rem;
  border: 1px solid var(--liberty-hairline);
  border-left: 3px solid #94a3b8;
  border-radius: var(--liberty-radius-sm);
  box-shadow: var(--liberty-shadow);
  transition: box-shadow 0.16s ease, transform 0.16s ease;
}
.notif-card:hover {
  box-shadow: var(--liberty-shadow-md);
  transform: translateY(-1px);
}
.notif-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: 8px;
  flex-shrink: 0;
  margin-top: 0.1rem;
}
.notif-card__icon .material-icons {
  font-size: 1.2rem;
}
.notif-card__body {
  min-width: 0;
  flex: 1;
}
.notif-card__head {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: baseline;
}
.notif-card__title {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-primary);
}
.notif-card__meta {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin: 0.4rem 0 0.55rem;
  font-size: 0.78rem;
  color: var(--text-secondary);
}
.notif-card__sev {
  font-size: 0.66rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.12rem 0.45rem;
  border-radius: 999px;
}
.notif-card__actions {
  display: flex;
  gap: 0.85rem;
  flex-wrap: wrap;
}

/* =============================================================================
   Admin access UI — visual parity with UniConecta /admin/usuarios
   ============================================================================= */
:root {
  --brand-teal: var(--brand-primary);
  --ds-radius-xs: 4px;
  --ds-radius-sm: 6px;
  --ds-radius-md: 8px;
  --ds-radius-lg: 12px;
  --ds-radius-xl: 16px;
  --ds-radius-pill: 100px;
  --ds-btn-h: 2.25rem;
  --ds-btn-h-sm: 1.875rem;
  --ds-btn-h-lg: 2.75rem;
  --ds-shadow-xs: 0 1px 2px rgb(0 0 0 / 0.06);
  --ds-shadow-sm: 0 1px 3px rgb(0 0 0 / 0.08), 0 1px 2px rgb(0 0 0 / 0.06);
  --ds-shadow-md: 0 4px 12px rgb(0 0 0 / 0.1), 0 2px 4px rgb(0 0 0 / 0.06);
  --ds-shadow-lg: 0 12px 32px rgb(0 0 0 / 0.14), 0 4px 8px rgb(0 0 0 / 0.08);
  --ds-focus-ring: 0 0 0 3px rgb(0 191 154 / 0.2);
  --ds-space-0: 0;
  --ds-space-1: 0.25rem;
  --ds-space-2: 0.5rem;
  --ds-space-3: 0.75rem;
  --ds-space-4: 1rem;
  --ds-space-5: 1.25rem;
  --ds-space-6: 1.5rem;
  --ds-space-7: 2rem;
  --ds-space-8: 2.5rem;
  --ds-space-9: 3rem;
  --ds-space-10: 4rem;
  --ds-page-pad-x: clamp(1rem, 2.2vw, 2rem);
  --ds-page-pad-y: clamp(1rem, 1.8vw, 1.75rem);
  --ds-page-max: none;
  --ds-page-max-narrow: 64rem;
}

.app-page {
  width: 100%;
  max-width: var(--ds-page-max);
  margin: 0 auto;
  padding: var(--ds-page-pad-y) var(--ds-page-pad-x)
    calc(var(--ds-page-pad-y) * 1.4);
  box-sizing: border-box;
}

.app-page--fluid {
  max-width: none;
}

.app-page--narrow {
  max-width: var(--ds-page-max-narrow);
}

.app-page-title {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--brand-dark, #002b49);
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.app-page-title-icon {
  font-size: 1.5rem;
  color: var(--brand-primary, #00bf9a);
  flex-shrink: 0;
}

.app-breadcrumbs {
  margin-bottom: 0.875rem;
}

.app-breadcrumbs-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.78rem;
  color: var(--text-secondary, #64748b);
}

.app-breadcrumbs-list li {
  display: flex;
  align-items: center;
}

.app-breadcrumbs-list li + li::before {
  content: "/";
  margin: 0 0.4rem;
  opacity: 0.4;
}

.app-breadcrumbs-link {
  color: var(--text-secondary, #64748b);
  text-decoration: none;
  transition: color 0.15s;
}

.app-breadcrumbs-link:hover {
  color: var(--brand-primary, #00bf9a);
  text-decoration: underline;
}

.app-breadcrumbs-current {
  color: var(--text-primary, #1e293b);
  font-weight: 600;
}

.app-page-header {
  margin-bottom: var(--ds-space-5);
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.app-page-lead {
  margin: 0.25rem 0 0;
  font-size: 0.875rem;
  line-height: 1.55;
  color: var(--text-secondary, #64748b);
  max-width: 52rem;
}

.app-page-header-content {
  flex: 1;
  min-width: 0;
}

.app-page-body {
  display: flex;
  flex-direction: column;
  gap: var(--ds-space-6);
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
  box-shadow: none;
  width: 100%;
  min-width: 0;
}

.app-page-body--card {
  background: #fff;
  border: 1px solid var(--border-color, #e2e8f0);
  border-radius: var(--ds-radius-lg);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--ds-shadow-sm);
}

.app-page-header-actions {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  flex-shrink: 0;
  padding-top: 0.125rem;
}

.app-field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  flex: 1;
  min-width: min(100%, 14rem);
}

.app-field-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary, #64748b);
}

.app-input {
  width: 100%;
  height: 2.25rem;
  padding: 0 0.75rem;
  border: 1.5px solid var(--border-color, #e2e8f0);
  border-radius: var(--ds-radius-md);
  font-size: 0.875rem;
  font-family: inherit;
  color: var(--text-primary, #1e293b);
  background: #fff;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
  -webkit-appearance: none;
  appearance: none;
}

.app-input:focus {
  border-color: var(--brand-primary, #00bf9a);
  box-shadow: var(--ds-focus-ring);
}

.app-input:disabled {
  background: var(--background-color, #f8fafc);
  color: var(--text-secondary, #64748b);
  cursor: not-allowed;
}

select.app-input {
  padding-right: 2rem;
  cursor: pointer;
}

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

.material-icons.spin,
.spin.material-icons {
  animation: spin 0.8s linear infinite;
  display: inline-block;
}

.org-team {
  max-width: 52rem;
}

.org-team--loading {
  min-height: 8rem;
  display: flex;
  align-items: center;
}

.org-team-skeleton {
  display: block;
  width: 100%;
  height: 6rem;
  border-radius: var(--liberty-radius);
  background: linear-gradient(
    90deg,
    rgb(226 232 240 / 0.6) 0%,
    rgb(241 245 249 / 0.9) 50%,
    rgb(226 232 240 / 0.6) 100%
  );
  background-size: 200% 100%;
  animation: org-team-shimmer 1.2s ease-in-out infinite;
}

@keyframes org-team-shimmer {
  0% {
    background-position: 100% 0;
  }
  100% {
    background-position: -100% 0;
  }
}

.org-team-hero {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  margin-bottom: 1.5rem;
  padding: 1.1rem 1.15rem;
  border-radius: var(--liberty-radius);
  border: 1px solid rgb(0 182 214 / 0.25);
  background: linear-gradient(
    125deg,
    rgb(0 191 154 / 0.09),
    rgb(0 43 73 / 0.06)
  );
  box-shadow: var(--liberty-shadow);
}

.org-team-hero-icon {
  flex-shrink: 0;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: var(--brand-dark);
  color: #fff;
}

.org-team-hero-icon .material-icons {
  font-size: 1.5rem;
}

.org-team-hero-title {
  margin: 0 0 0.35rem;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--brand-dark);
}

.org-team-hero-lead {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--text-secondary);
}

.org-team-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  align-items: flex-end;
  margin-bottom: 1rem;
}

.org-team-field {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: min(100%, 14rem);
}

.org-team-field--grow {
  flex: 1 1 12rem;
}

.org-team-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-secondary);
}

.org-team-select {
  font: inherit;
  padding: 0.5rem 0.65rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--border-color);
  background: #fff;
  color: var(--text-primary);
  min-width: 0;
}

.org-team-select--compact {
  padding: 0.35rem 0.5rem;
  font-size: 0.8125rem;
}

.org-team-input {
  font: inherit;
  padding: 0.5rem 0.65rem;
  border-radius: var(--liberty-radius-sm);
  border: 1px solid var(--border-color);
  width: 100%;
}

.org-team-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
}

.org-team-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.3rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
}

.org-team-badge .material-icons {
  font-size: 1rem !important;
}

.org-team-badge--creator {
  background: rgb(0 191 154 / 0.15);
  color: var(--brand-dark);
}

.org-team-badge--admin {
  background: rgb(0 43 73 / 0.08);
  color: var(--brand-dark);
}

.org-team-badge--platform {
  background: rgb(0 182 214 / 0.18);
  color: var(--brand-dark);
  border: 1px solid rgb(0 182 214 / 0.45);
}

.org-team-error {
  margin: 0 0 1rem;
  padding: 0.65rem 0.75rem;
  border-radius: var(--liberty-radius-sm);
  background: rgb(239 68 68 / 0.1);
  color: var(--error-color);
  font-size: 0.875rem;
}

.org-team-notice {
  margin: 0 0 1rem;
  padding: 0.65rem 0.75rem;
  border-radius: var(--liberty-radius-sm);
  background: rgb(34 197 94 / 0.12);
  color: var(--brand-dark);
  font-size: 0.875rem;
}

.org-team-card {
  margin-bottom: 1.25rem;
  padding: 1rem 1.1rem;
  border-radius: var(--liberty-radius);
  border: 1px solid var(--border-color);
  background: var(--surface-color);
  box-shadow: var(--liberty-shadow);
}

.org-team-card-title {
  margin: 0 0 0.35rem;
  font-size: 1rem;
  font-weight: 700;
  color: var(--brand-dark);
}

.org-team-card-lead {
  margin: 0 0 0.85rem;
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--text-secondary);
}

.org-team-invite-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: flex-end;
}

.org-team-invite-btn {
  flex-shrink: 0;
}

.org-team-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.org-team-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: center;
  justify-content: space-between;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--border-color);
}

.org-team-row:last-child {
  border-bottom: none;
}

.org-team-row-main {
  flex: 1 1 12rem;
  min-width: 0;
}

.org-team-name {
  display: block;
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--text-primary);
}

.org-team-email {
  display: block;
  font-size: 0.8125rem;
  color: var(--text-secondary);
  word-break: break-all;
}

.org-team-meta {
  margin-top: 0.25rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.org-team-pill {
  display: inline-block;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  background: rgb(100 116 139 / 0.12);
  color: var(--text-secondary);
}

.org-team-pill--you {
  background: rgb(0 191 154 / 0.18);
  color: var(--brand-dark);
}

.org-team-since {
  display: inline-flex;
  align-items: center;
  font-size: 0.6875rem;
  color: var(--text-secondary);
  white-space: nowrap;
}

.org-team-row-actions {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.org-team-pill--readonly {
  background: rgb(234 179 8 / 0.15);
  color: rgb(161 98 7);
}

.org-team-pill--email {
  background: rgb(14 165 233 / 0.12);
  color: rgb(3 105 161);
}

.org-team-edit-access,
.org-team-resend {
  padding: 0.35rem !important;
  min-width: auto;
}

.org-team-remove {
  padding: 0.35rem !important;
  min-width: auto;
}

.org-team-invite-header {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: flex-start;
  justify-content: space-between;
}

.org-team-pill--custom {
  background: rgb(99 102 241 / 0.15);
  color: rgb(67 56 202);
}

/* Invite user wizard */
.invite-wiz-backdrop {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgb(15 23 42 / 0.45);
  backdrop-filter: blur(4px);
}

.invite-wiz {
  width: min(100%, 42rem);
  max-height: min(90vh, 44rem);
  display: flex;
  flex-direction: column;
  border-radius: var(--liberty-radius);
  background: #fff;
  box-shadow: 0 24px 48px rgb(15 23 42 / 0.18);
  overflow: hidden;
}

.invite-wiz-header {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  justify-content: space-between;
  padding: 1.1rem 1.25rem 0.75rem;
  border-bottom: 1px solid var(--border-color);
}

.invite-wiz-title {
  margin: 0 0 0.25rem;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--brand-dark);
}

.invite-wiz-subtitle {
  margin: 0;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.invite-wiz-close {
  flex-shrink: 0;
}

.invite-wiz-steps {
  display: flex;
  gap: 0.5rem;
  list-style: none;
  margin: 0;
  padding: 0.75rem 1.25rem;
  border-bottom: 1px solid var(--border-color);
}

.invite-wiz-step {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.invite-wiz-step--active {
  color: var(--brand-dark);
  font-weight: 600;
}

.invite-wiz-step--done {
  color: var(--brand-teal);
}

.invite-wiz-step-num {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 0.75rem;
  font-weight: 700;
  background: rgb(226 232 240 / 0.8);
}

.invite-wiz-step--active .invite-wiz-step-num {
  background: var(--brand-dark);
  color: #fff;
}

.invite-wiz-step--done .invite-wiz-step-num {
  background: rgb(0 191 154 / 0.2);
  color: var(--brand-teal);
}

.invite-wiz-step-num .material-icons {
  font-size: 0.95rem;
}

.invite-wiz-step-label {
  display: none;
}

@media (min-width: 520px) {
  .invite-wiz-step-label {
    display: inline;
  }
}

.invite-wiz-error {
  margin: 0.75rem 1.25rem 0;
  padding: 0.5rem 0.65rem;
  border-radius: var(--liberty-radius-sm);
  background: rgb(254 226 226);
  color: rgb(153 27 27);
  font-size: 0.875rem;
}

.invite-wiz-body {
  flex: 1;
  overflow: auto;
  padding: 1rem 1.25rem;
}

.invite-wiz-panel {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

/* The wizard stacks fields vertically, so the horizontal-row `--grow`
   flex-basis must not stretch them — keep each field at its natural height. */
.invite-wiz-panel .org-team-field,
.invite-wiz-panel .org-team-field--grow {
  flex: 0 0 auto;
}

/* Tighten the gap between a field and the hint that explains it. */
.invite-wiz-panel .invite-wiz-hint {
  margin-top: -0.25rem;
}

.invite-wiz-panel--perms {
  gap: 0.65rem;
}

.invite-wiz-hint,
.invite-wiz-lead {
  margin: 0;
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--text-secondary);
}

.invite-wiz-ws-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.invite-wiz-ws-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.55rem 0.65rem;
  border: 1px solid var(--border-color);
  border-radius: var(--liberty-radius-sm);
  cursor: pointer;
}

.invite-wiz-ws-item:has(input:checked) {
  border-color: rgb(0 191 154 / 0.55);
  background: rgb(0 191 154 / 0.06);
}

.invite-wiz-ws-main {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.invite-wiz-ws-name {
  font-weight: 600;
  font-size: 0.9rem;
}

.invite-wiz-ws-slug {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.invite-wiz-perm-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 0.35rem;
}

.invite-wiz-defaults {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.875rem;
  font-weight: 500;
}

.invite-wiz-perm-count {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.invite-wiz-accordions {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.invite-wiz-accordion {
  border: 1px solid var(--border-color);
  border-radius: var(--liberty-radius-sm);
  overflow: hidden;
}

.invite-wiz-accordion-head {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.6rem;
  border: none;
  background: rgb(248 250 252);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.invite-wiz-group-icon,
.member-access-group-icon {
  flex: 0 0 auto;
  width: 1.625rem;
  height: 1.625rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--liberty-radius-sm);
  background: rgb(0 43 73 / 0.06);
  color: var(--brand-dark);
  font-size: 1rem;
  line-height: 1;
  overflow: hidden;
}

.invite-wiz-accordion-title {
  flex: 1;
  min-width: 0;
  font-weight: 600;
  font-size: 0.8125rem;
  line-height: 1.3;
}

.invite-wiz-accordion-meta {
  flex: 0 0 auto;
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--text-secondary);
  white-space: nowrap;
}

.invite-wiz-chevron {
  font-size: 1.125rem !important;
  color: var(--text-secondary);
}

.invite-wiz-accordion-body {
  padding: 0.4rem 0.6rem 0.55rem;
  border-top: 1px solid var(--border-color);
}

.invite-wiz-group-toggle {
  margin-bottom: 0.45rem;
  font-size: 0.8125rem !important;
}

.invite-wiz-perm-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.invite-wiz-perm-item {
  display: flex;
  gap: 0.45rem;
  align-items: flex-start;
  font-size: 0.8125rem;
  cursor: pointer;
  line-height: 1.35;
}

.invite-wiz-perm-label {
  display: block;
  font-weight: 600;
}

.invite-wiz-perm-desc {
  display: block;
  color: var(--text-secondary);
  font-size: 0.75rem;
}

.invite-wiz-perm-key {
  display: inline-block;
  margin-top: 0.15rem;
  font-size: 0.6875rem;
  padding: 0.05rem 0.3rem;
  border-radius: 3px;
  background: rgb(226 232 240 / 0.7);
}

.invite-wiz-footer {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.85rem 1.25rem;
  border-top: 1px solid var(--border-color);
  background: rgb(248 250 252 / 0.8);
}

/* Member access — scenario-first profile and grouped permission editor */
.member-access-backdrop {
  padding: var(--ds-space-4, 1rem);
  background: rgb(0 27 47 / 0.58);
  backdrop-filter: blur(6px);
}

.member-access-modal {
  width: min(100%, 56rem);
  max-height: min(94vh, 52rem);
  border: 1px solid rgb(226 232 240 / 0.85);
  border-radius: var(--ds-radius-xl, 16px);
  box-shadow: 0 28px 80px rgb(0 27 47 / 0.28);
}

.member-access-header {
  align-items: center;
  padding: var(--ds-space-4, 1rem) var(--ds-space-5, 1.25rem);
  background: linear-gradient(135deg, #fff 70%, rgb(0 191 154 / 0.07));
}

.member-access-heading {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: var(--ds-space-3, 0.75rem);
}

.member-access-avatar {
  flex: 0 0 auto;
  width: 2.75rem;
  height: 2.75rem;
  display: grid;
  place-items: center;
  border-radius: var(--ds-radius-lg, 12px);
  background: var(--brand-dark);
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  box-shadow: 0 4px 12px rgb(0 43 73 / 0.18);
}

.member-access-heading .invite-wiz-title {
  font-size: 1.25rem;
}

.member-access-heading .invite-wiz-subtitle {
  line-height: 1.45;
}

.member-access-heading .invite-wiz-subtitle strong {
  color: var(--text-primary);
  font-weight: 600;
}

.member-access-body {
  display: flex;
  flex-direction: column;
  padding: 0;
  background: #f8fafc;
}

.member-access-modal .material-icons {
  line-height: 1;
}

.member-access-loading {
  flex: 1 1 auto;
  width: 100%;
  min-height: 14rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--ds-space-3, 0.75rem);
  padding: var(--ds-space-7, 2rem) var(--ds-space-6, 1.5rem);
  background: #fff;
  color: var(--text-secondary);
}

.member-access-loading-icon {
  flex: 0 0 auto;
  width: 2.5rem;
  height: 2.5rem;
  display: grid;
  place-items: center;
  border-radius: var(--ds-radius-lg, 12px);
  background: rgb(0 191 154 / 0.12);
  color: #007d69;
}

.member-access-loading-glyph {
  display: block;
  width: 1.25rem;
  height: 1.25rem;
  font-size: 1.25rem !important;
  line-height: 1 !important;
}

.member-access-loading-copy {
  display: flex;
  flex-direction: column;
  gap: var(--ds-space-1, 0.25rem);
}

.member-access-loading-copy strong {
  color: var(--brand-dark);
  font-size: 0.875rem;
  line-height: 1.35;
}

.member-access-loading-copy small {
  font-size: 0.75rem;
  line-height: 1.45;
}

.member-access-content {
  width: 100%;
  gap: 0;
}

.member-access-section {
  padding: var(--ds-space-4, 1rem) var(--ds-space-5, 1.25rem);
  background: #fff;
  border-bottom: 1px solid var(--border-color);
}

.member-access-section:last-child {
  border-bottom: 0;
}

.member-access-section-heading {
  display: flex;
  flex-direction: row-reverse;
  justify-content: flex-end;
  align-items: flex-start;
  gap: var(--ds-space-2, 0.5rem);
  margin-bottom: var(--ds-space-3, 0.75rem);
}

.member-access-section-heading > div {
  flex: 1;
}

.member-access-section-heading h3 {
  margin: 0 0 var(--ds-space-1, 0.25rem);
  color: var(--brand-dark);
  font-size: 0.9375rem;
  line-height: 1.35;
}

.member-access-section-heading p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.8125rem;
  line-height: 1.5;
}

.member-access-step {
  flex: 0 0 auto;
  width: 1.5rem;
  height: 1.5rem;
  display: grid;
  place-items: center;
  border-radius: var(--ds-radius-pill, 100px);
  background: rgb(0 191 154 / 0.12);
  color: #007d69;
  font-size: 0.75rem;
  font-weight: 800;
}

.member-access-profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--ds-space-2, 0.5rem);
}

.member-access-profile {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: var(--ds-space-2, 0.5rem);
  padding: var(--ds-space-2, 0.5rem) var(--ds-space-3, 0.75rem);
  border: 1.5px solid var(--border-color);
  border-radius: var(--ds-radius-lg, 12px);
  background: #fff;
  color: var(--text-primary);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition:
    border-color 0.15s ease,
    background-color 0.15s ease,
    box-shadow 0.15s ease,
    transform 0.15s ease;
}

.member-access-profile:last-child {
  grid-column: 1 / -1;
}

.member-access-profile:hover {
  border-color: rgb(0 191 154 / 0.5);
  transform: translateY(-1px);
  box-shadow: var(--ds-shadow-sm);
}

.member-access-profile:focus-visible {
  outline: none;
  box-shadow: var(--ds-focus-ring);
}

.member-access-profile--selected {
  border-color: var(--brand-primary);
  background: rgb(0 191 154 / 0.055);
  box-shadow: 0 0 0 1px rgb(0 191 154 / 0.12);
}

.member-access-profile-icon {
  flex: 0 0 auto;
  width: 1.75rem;
  height: 1.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--ds-radius-md, 8px);
  background: rgb(0 43 73 / 0.07);
  color: var(--brand-dark);
}

.member-access-profile-glyph {
  display: block;
  font-size: 1rem !important;
  line-height: 1 !important;
}

.member-access-profile--selected .member-access-profile-icon {
  background: rgb(0 191 154 / 0.15);
  color: #007d69;
}

.member-access-profile-copy {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.member-access-profile-copy strong {
  font-size: 0.8125rem;
  line-height: 1.35;
}

.member-access-profile-copy small {
  display: -webkit-box;
  overflow: hidden;
  color: var(--text-secondary);
  font-size: 0.72rem;
  line-height: 1.4;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.member-access-profile-check {
  flex: 0 0 auto;
  width: 1.125rem;
  height: 1.125rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  font-size: 1.05rem !important;
  line-height: 1 !important;
}

.member-access-profile--selected .member-access-profile-check {
  color: var(--brand-primary);
}

.member-access-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--ds-space-2, 0.5rem);
}

.member-access-summary-item {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: var(--ds-space-2, 0.5rem);
  padding: var(--ds-space-2, 0.5rem) var(--ds-space-3, 0.75rem);
  border: 1px solid var(--border-color);
  border-radius: var(--ds-radius-md, 8px);
  background: #f8fafc;
}

.member-access-summary-item > .material-icons {
  flex: 0 0 auto;
  width: 1.5rem;
  height: 1.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-primary);
  font-size: 1.05rem;
  line-height: 1;
}

.member-access-summary-item > span:last-child {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.member-access-summary-item small {
  color: var(--text-secondary);
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.045em;
}

.member-access-summary-item strong {
  overflow: hidden;
  color: var(--brand-dark);
  font-size: 0.78rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.member-access-custom-fields {
  justify-content: flex-start;
  margin-top: var(--ds-space-3, 0.75rem);
  padding: 0;
}

.member-access-defaults {
  display: flex;
  align-items: flex-start;
  gap: var(--ds-space-2, 0.5rem);
  padding: var(--ds-space-2, 0.5rem) var(--ds-space-3, 0.75rem);
  border: 1px solid rgb(0 191 154 / 0.28);
  border-radius: var(--ds-radius-lg, 12px);
  background: rgb(0 191 154 / 0.055);
  cursor: pointer;
}

.member-access-defaults input,
.member-access-perm-item input {
  flex: 0 0 auto;
  width: 1rem;
  height: 1rem;
  margin: 0.1rem 0 0;
  accent-color: var(--brand-primary);
}

.member-access-defaults > span {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.member-access-defaults strong {
  color: var(--brand-dark);
  font-size: 0.8125rem;
}

.member-access-defaults small {
  color: var(--text-secondary);
  font-size: 0.75rem;
  line-height: 1.4;
}

.member-access-perm-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--ds-space-2, 0.5rem);
  margin: var(--ds-space-2, 0.5rem) 0;
  color: var(--text-secondary);
  font-size: 0.75rem;
  font-weight: 600;
}

.member-access-badge {
  padding: 0.2rem 0.5rem;
  border-radius: var(--ds-radius-pill, 100px);
  background: rgb(0 191 154 / 0.13);
  color: #007d69;
  font-size: 0.68rem;
  font-weight: 700;
}

.member-access-accordion {
  border-radius: var(--ds-radius-md, 8px);
  background: #fff;
}

.member-access-accordion .invite-wiz-accordion-head {
  min-height: 0;
  padding-block: 0.4rem;
  background: #fff;
}

.member-access-accordion .invite-wiz-accordion-head:hover {
  background: #f8fafc;
}

.member-access-accordion .invite-wiz-chevron {
  flex: 0 0 auto;
  width: 1.25rem;
  height: 1.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.member-access-accordions--readonly .member-access-perm-list {
  opacity: 0.65;
}

.member-access-perm-list {
  gap: 0;
}

.member-access-perm-item {
  gap: var(--ds-space-2, 0.5rem);
  padding: 0.3rem 0;
  border-bottom: 1px solid rgb(226 232 240 / 0.72);
}

.member-access-perm-list li:last-child .member-access-perm-item {
  border-bottom: 0;
}

.member-access-footer {
  justify-content: flex-end;
  padding: var(--ds-space-3, 0.75rem) var(--ds-space-5, 1.25rem);
  background: #fff;
  box-shadow: 0 -8px 24px rgb(15 23 42 / 0.04);
}

@media (max-width: 640px) {
  .member-access-backdrop {
    align-items: flex-end;
    padding: 0;
  }

  .member-access-modal {
    max-height: 94vh;
    border-radius: var(--ds-radius-xl, 16px) var(--ds-radius-xl, 16px) 0 0;
  }

  .member-access-header,
  .member-access-section,
  .member-access-footer {
    padding-left: var(--ds-space-4, 1rem);
    padding-right: var(--ds-space-4, 1rem);
  }

  .member-access-profile-grid,
  .member-access-summary {
    grid-template-columns: 1fr;
  }

  .member-access-profile:last-child {
    grid-column: auto;
  }

  .member-access-profile-copy small {
    -webkit-line-clamp: 3;
  }

  .member-access-footer .app-btn {
    flex: 1;
  }
}

.org-team-remove .material-icons {
  font-size: 1.25rem !important;
}

.org-team-role-readonly {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.org-team-muted {
  margin: 0;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.org-team-hint {
  margin: 0;
  padding: 0.75rem 0.85rem;
  border-radius: var(--liberty-radius-sm);
  background: rgb(245 158 11 / 0.12);
  border: 1px solid rgb(245 158 11 / 0.35);
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--text-primary);
}

.tt-pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.85rem 1.25rem;
  background: var(--surface-secondary, #f8fafc);
  border-top: 1px solid var(--border-color, #e2e8f0);
  font-size: 0.8rem;
  color: var(--text-secondary, #64748b);
}
.tt-pagination-range strong {
  color: var(--text-primary, #1e293b);
  font-weight: 600;
}
.tt-pagination-btns {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.tt-pagination-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.15rem;
  padding: 0.4rem 0.65rem;
  font-size: 0.78rem;
  font-weight: 600;
  border: 1px solid var(--border-color, #e2e8f0);
  border-radius: 8px;
  background: var(--surface-color, #fff);
  color: var(--text-primary, #334155);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.tt-pagination-btn:hover:not(:disabled) {
  border-color: var(--primary-color, #3b82f6);
  color: var(--primary-color, #3b82f6);
}
.tt-pagination-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.tt-pagination-btn .material-icons {
  font-size: 1.1rem !important;
}
.tt-pagination-page {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-primary, #1e293b);
  padding: 0 0.35rem;
  min-width: 4.5rem;
  text-align: center;
}

/* ═══════════════════════════════════════════════════════════════════════
   Projetos hub + project cards (UniConecta parity)
   ═══════════════════════════════════════════════════════════════════════ */

.projetos-hub {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.projetos-hub .view-toolbar {
  margin-bottom: 0;
}

.projetos-hub .view-toolbar--compact {
  border-radius: 12px;
  border-color: var(--border-soft, #e2e8f0);
  box-shadow: none;
}

.projetos-hub-toolbar {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  flex-wrap: wrap;
  padding: 0.75rem;
  background: var(--surface-base, #fff);
  border: 1px solid var(--border-soft, #e2e8f0);
  border-radius: 12px;
}

.projetos-hub-toolbar-grow {
  flex: 1 1 280px;
  min-width: 200px;
}

.projetos-hub-body {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.proj-cards-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
}

.proj-card {
  background: var(--surface-base, #fff);
  border: 1px solid var(--border-soft, #e2e8f0);
  border-radius: 14px;
  padding: 1rem 1.125rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
  min-width: 0;
  overflow: hidden;
  transition: box-shadow 0.18s, transform 0.18s, border-color 0.18s;
}

.proj-card:hover {
  box-shadow: 0 6px 24px -10px rgba(15, 23, 42, 0.15);
  transform: translateY(-2px);
  border-color: var(--brand-primary, #00bf9a);
}

.proj-card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem;
}

.proj-card-head-left {
  flex: 1;
  min-width: 0;
}

.proj-card-name {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text-primary, #1e293b);
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  word-break: break-word;
}

.proj-card-client {
  margin: 0.35rem 0 0;
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.75rem;
  color: var(--text-secondary, #64748b);
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.proj-card-client .material-icons {
  font-size: 0.9rem;
  flex-shrink: 0;
}

.proj-card-pass-rate {
  flex-shrink: 0;
  font-size: 1.125rem;
  font-weight: 800;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  padding: 0.35rem 0.5rem;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid #eef2f6;
}

.proj-card-meta {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  align-items: center;
}

.proj-card-days {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-secondary, #64748b);
  padding: 0.2rem 0.55rem;
  background: #f1f5f9;
  border-radius: 99px;
  max-width: 100%;
  white-space: nowrap;
}

.proj-card-days .material-icons {
  font-size: 0.8rem;
  flex-shrink: 0;
}

.proj-card-days--warn {
  background: #fef3c7;
  color: #92400e;
}

.proj-card-days--late {
  background: #fee2e2;
  color: #b91c1c;
}

.proj-card-stats {
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  padding: 0.75rem;
  background: #f8fafc;
  border-radius: 10px;
  border: 1px solid #eef2f6;
}

.proj-card-stats-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.5rem 0.75rem;
}

.proj-card-stats-dates {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem 0.75rem;
  padding-top: 0.625rem;
  border-top: 1px solid #e2e8f0;
}

.proj-card-stat {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.proj-card-stat-label {
  font-size: 0.6875rem;
  font-weight: 500;
  color: var(--text-secondary, #64748b);
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.proj-card-stat-value {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary, #1e293b);
  line-height: 1.3;
  font-variant-numeric: tabular-nums;
}

.proj-card-stat-value strong {
  font-weight: 700;
}

.proj-card-foot {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: auto;
}

.proj-card-foot-primary {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.5rem;
}

.proj-card-foot-primary .app-btn {
  width: 100%;
  min-width: 0;
}

.proj-card-foot-secondary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding-top: 0.125rem;
  border-top: 1px solid var(--border-soft, #e2e8f0);
}

.proj-card-foot-secondary .app-btn {
  min-width: 0;
}

.uc-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  padding: 0.2rem 0.525rem;
  border-radius: var(--ds-radius-pill, 100px);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
  border: 1.5px solid transparent;
  line-height: 1.4;
}

.uc-badge .material-icons {
  font-size: 0.875rem;
  line-height: 1;
}

.uc-badge--neutral {
  background: #f1f5f9;
  color: #475569;
  border-color: #e2e8f0;
}

.uc-badge--success {
  background: #f0fdf4;
  color: #15803d;
  border-color: #bbf7d0;
}

.uc-badge--info {
  background: #eff6ff;
  color: #1d4ed8;
  border-color: #bfdbfe;
}

.uc-badge--warn {
  background: #fffbeb;
  color: #b45309;
  border-color: #fde68a;
}

.uc-badge--danger {
  background: #fef2f2;
  color: #dc2626;
  border-color: #fecaca;
}

.uc-badge--muted {
  background: #f8fafc;
  color: #94a3b8;
  border-color: #e2e8f0;
}

.uc-badge--outline {
  background: transparent;
  color: var(--text-secondary, #64748b);
  border-color: var(--border-color, #e2e8f0);
}

.uc-badge--primary-teal {
  background: color-mix(in srgb, var(--brand-primary, #00bf9a) 12%, white);
  color: var(--brand-primary, #00bf9a);
  border-color: color-mix(in srgb, var(--brand-primary, #00bf9a) 30%, white);
}

.app-error-banner {
  margin: 0;
  padding: 0.65rem 1rem;
  border-radius: 6px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
  font-size: 0.875rem;
}

.app-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 0.5rem;
  padding: clamp(2rem, 5vw, 3.5rem) 1.5rem;
  background: var(--surface-base, #fff);
  border: 1px dashed var(--border-soft, #e2e8f0);
  border-radius: 14px;
}

.app-empty-state-icon {
  font-size: 2.5rem !important;
  color: var(--brand-primary, #00bf9a);
  opacity: 0.85;
}

.app-empty-state-title {
  margin: 0.25rem 0 0;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--text-primary, #1e293b);
}

.app-empty-state-lead {
  margin: 0;
  max-width: 32rem;
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--text-secondary, #64748b);
}

.app-empty-state-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  margin-top: 0.75rem;
}

.mi-sm {
  font-size: 1rem !important;
}

.filter-pills__options .filter-pill-link {
  text-decoration: none;
}

.filter-pills__options button.filter-pill-link {
  cursor: pointer;
  font: inherit;
}

.filter-pills__options button.filter-pill-link:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.history-hub-body {
  transition: opacity 0.15s ease;
}

.history-hub-body--loading {
  opacity: 0.55;
  pointer-events: none;
}

@media (max-width: 480px) {
  .proj-card {
    padding: 0.875rem 1rem;
  }

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

  .proj-card-stats-metrics .proj-card-stat:last-child {
    grid-column: 1 / -1;
  }
}

