/* ============================================================
   Cotador — visual no estilo do Portal Aether (design Geist/Vercel)
   Tema: classe .dark no <html> (botão Tema na barra lateral)
   ============================================================ */
/* Fonte Geist servida pelo próprio site (licença OFL): 1 arquivo cobre 400–600 */
@font-face {
  font-family: "Geist";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/assets/fonts/geist-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg-100: #ffffff;
  --bg-200: hsl(0 0% 98%);
  --gray-100: hsl(0 0% 95%);
  --gray-200: hsl(0 0% 92%);
  --gray-400: hsl(0 0% 92%);
  --gray-600: hsl(0 0% 66%);
  --gray-700: hsl(0 0% 56%);
  --gray-900: hsl(0 0% 30%);
  --gray-1000: hsl(0 0% 9%);
  --alpha-100: #0000000d;
  --alpha-200: #00000014;
  --alpha-400: #00000014;
  --alpha-500: #00000036;
  --alpha-600: #00000057;
  --green-100: hsl(120 60% 96%);
  --green-400: hsl(122 60% 86%);
  --green-700: hsl(131 41% 46%);
  --green-900: hsl(133 50% 32%);
  --amber-100: hsl(39 100% 95%);
  --amber-400: hsl(42 100% 78%);
  --amber-900: hsl(30 100% 32%);
  --red-100: hsl(0 100% 97%);
  --red-400: hsl(0 90% 92%);
  --red-700: hsl(358 75% 59%);
  --red-900: hsl(358 66% 48%);
  --blue-700: hsl(212 100% 48%);
  --focus: var(--blue-700);
  --shadow-border: 0 0 0 1px #00000014;
  --shadow-small: 0 0 0 1px #00000014, 0 2px 2px #0000000a;
  --shadow-modal: 0 0 0 1px #00000014, 0 1px 1px #00000005, 0 8px 16px -4px #0000000a, 0 24px 32px -8px #0000000f;
  --font: "Geist", "Inter", -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, "Cascadia Mono", Consolas, monospace;
  color-scheme: light;
}

.dark {
  --bg-100: hsl(0 0% 4%);
  --bg-200: #000000;
  --gray-100: hsl(0 0% 10%);
  --gray-200: hsl(0 0% 12%);
  --gray-400: hsl(0 0% 18%);
  --gray-600: hsl(0 0% 53%);
  --gray-700: hsl(0 0% 56%);
  --gray-900: hsl(0 0% 63%);
  --gray-1000: hsl(0 0% 93%);
  --alpha-100: #ffffff0f;
  --alpha-200: #ffffff17;
  --alpha-400: #ffffff24;
  --alpha-500: #ffffff3d;
  --alpha-600: #ffffff82;
  --green-100: hsl(136 50% 9%);
  --green-400: hsl(135 70% 16%);
  --green-900: hsl(131 43% 57%);
  --amber-100: hsl(35 100% 8%);
  --amber-400: hsl(35 100% 17%);
  --amber-900: hsl(39 90% 50%);
  --red-100: hsl(357 37% 12%);
  --red-400: hsl(357 55% 26%);
  --red-900: hsl(358 100% 69%);
  --focus: hsl(210 100% 66%);
  --shadow-border: 0 0 0 1px #ffffff25;
  --shadow-small: 0 0 0 1px #ffffff25, 0 1px 2px #00000029;
  --shadow-modal: 0 0 0 1px #ffffff25, 0 8px 16px -4px #00000052, 0 24px 32px -8px #00000052;
  color-scheme: dark;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
body {
  min-height: 100dvh;
  background: var(--bg-200);
  color: var(--gray-1000);
  font-family: var(--font);
  font-size: 14px;
  line-height: 20px;
}
button { font: inherit; color: inherit; cursor: pointer; background: none; border: none; }
button:disabled { cursor: default; }
input { font: inherit; color: inherit; }
svg { flex-shrink: 0; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
::selection { background: var(--gray-1000); color: var(--gray-100); }
[hidden] { display: none !important; }

.icon { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }

/* ---------------- Barra lateral ---------------- */
.sidebar {
  position: fixed; inset: 0 auto 0 0; z-index: 40;
  will-change: transform; /* camada própria: não redesenha ao rolar */
  width: 240px;
  display: flex; flex-direction: column;
  background: var(--bg-100);
  border-right: 1px solid var(--alpha-400);
}
.brand {
  display: flex; align-items: center; gap: 10px;
  height: 64px; margin: 0 12px; padding: 0 8px;
  color: inherit; text-decoration: none;
}
.brand-badge { display: flex; align-items: center; flex-shrink: 0; }
.brand-badge img { width: 48px; height: auto; display: block; }
html:not(.dark) .brand-badge img { filter: invert(1); } /* logo é branco: no tema claro fica escuro */
/* Logo grande no topo da barra lateral */
.brand-grande { display: flex; justify-content: center; padding: 24px 12px 20px; border-radius: 8px; }
.brand-grande img { width: 176px; height: auto; display: block; }
html:not(.dark) .brand-grande img { filter: invert(1); }
.brand-text { min-width: 0; display: flex; flex-direction: column; }
.brand-text b { font-size: 14px; font-weight: 600; letter-spacing: -0.28px; white-space: nowrap; }
.brand-text small { font-size: 12px; line-height: 16px; color: var(--gray-900); }

.nav { flex: 1; display: flex; flex-direction: column; gap: 2px; padding: 8px 12px; overflow-y: auto; overflow-x: hidden; }
.nav-item {
  display: flex; align-items: center; gap: 10px;
  height: 32px; padding: 0 10px;
  border-radius: 6px;
  color: var(--gray-900);
  text-align: left;
  transition: background 0.15s, color 0.15s;
}
.nav-item:hover { background: var(--alpha-100); color: var(--gray-1000); }
.nav-item.active { background: var(--alpha-200); color: var(--gray-1000); font-weight: 500; }
.nav-item.active .icon { stroke-width: 2; }
.nav-badge {
  margin-left: auto;
  min-width: 20px; height: 20px; padding: 0 6px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 999px;
  background: var(--alpha-200);
  color: var(--gray-900);
  font-size: 11px; font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.nav-badge.full { background: var(--green-100); color: var(--green-900); }

.sidebar-foot { display: flex; flex-direction: column; gap: 12px; padding: 12px; border-top: 1px solid var(--alpha-400); }
.foot-row { display: flex; align-items: center; justify-content: space-between; padding: 0 4px; font-size: 13px; color: var(--gray-900); }

.theme-toggle { display: inline-flex; padding: 2px; gap: 2px; border-radius: 999px; box-shadow: 0 0 0 1px var(--alpha-400); }
.theme-toggle button { display: flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 999px; color: var(--gray-900); }
.theme-toggle button:hover { color: var(--gray-1000); }
.theme-toggle button[aria-pressed="true"] { background: var(--alpha-200); color: var(--gray-1000); }
.theme-toggle .icon { width: 14px; height: 14px; }

.user { display: flex; align-items: center; gap: 10px; padding: 4px; }
.avatar {
  width: 30px; height: 30px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  border-radius: 999px;
  background: #16a34a; color: #fff;
  font-size: 12px; font-weight: 600;
  box-shadow: 0 0 0 1px var(--alpha-400);
}
.user-info { min-width: 0; flex: 1; }
.user-info p { font-size: 13px; line-height: 16px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-transform: capitalize; }
.user-info small { font-size: 12px; line-height: 16px; color: var(--gray-900); }
.icon-btn { display: flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 6px; color: var(--gray-900); transition: background 0.15s, color 0.15s; }
.icon-btn:hover { background: var(--alpha-200); color: var(--gray-1000); }
.icon-btn.danger:hover, .icon-btn.danger:focus-visible { background: var(--red-100); color: var(--red-900); }

/* ---------------- Busca (Ctrl+K) ---------------- */
.busca-wrap { display: flex; gap: 8px; padding: 0 12px 4px; }

/* ---------------- Notificações ---------------- */
.sino {
  position: relative; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; border-radius: 6px;
  color: var(--gray-900);
  transition: background 0.15s, color 0.15s;
}
.busca-wrap .sino { box-shadow: 0 0 0 1px var(--alpha-400); }
.sino:hover, .sino[aria-expanded="true"] { background: var(--alpha-200); color: var(--gray-1000); }
.sino-num {
  position: absolute; top: -4px; right: -4px;
  min-width: 16px; height: 16px; padding: 0 4px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 999px;
  background: var(--red-700); color: #fff;
  font-size: 10px; font-weight: 600; line-height: 1;
}
.notif { position: fixed; inset: 0; z-index: 250; }
.notif-fundo { position: absolute; inset: 0; }
.notif-painel {
  position: absolute; top: 12px; left: 248px;
  width: 380px; max-height: min(560px, calc(100dvh - 80px));
  display: flex; flex-direction: column;
  background: var(--bg-100);
  border-radius: 12px;
  box-shadow: var(--shadow-modal);
  overflow: hidden;
  animation: pop-in 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.1);
}
.notif-topo { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 16px; border-bottom: 1px solid var(--alpha-400); }
.notif-topo h2 { font-size: 16px; line-height: 24px; font-weight: 600; letter-spacing: -0.32px; }
.notif-lidas { display: flex; align-items: center; gap: 4px; padding: 4px 8px; border-radius: 6px; font-size: 13px; color: var(--gray-900); }
.notif-lidas:hover { background: var(--alpha-200); color: var(--gray-1000); }
.notif-lidas .icon { width: 14px; height: 14px; }
.notif-lista { overflow-y: auto; padding: 4px 0; }
.notif-item { display: flex; align-items: flex-start; gap: 12px; width: 100%; padding: 10px 16px; text-align: left; transition: background 0.12s; }
.notif-item:hover { background: var(--alpha-100); }
.notif-item.nova { background: color-mix(in srgb, var(--focus) 8%, transparent); }
.notif-item .avatar { width: 28px; height: 28px; font-size: 11px; }
.notif-texto { flex: 1; min-width: 0; font-size: 13px; line-height: 18px; color: var(--gray-900); }
.notif-texto b { font-weight: 500; color: var(--gray-1000); }
.notif-texto small { display: block; margin-top: 2px; font-size: 12px; line-height: 16px; color: var(--gray-700); }
.notif-ponto { width: 8px; height: 8px; margin-top: 6px; flex-shrink: 0; border-radius: 50%; background: var(--focus); }
.notif-vazio { padding: 48px 24px; text-align: center; }
.notif-vazio b { font-size: 14px; font-weight: 600; }
.notif-vazio p { margin-top: 4px; font-size: 13px; color: var(--gray-900); }

.busca-btn {
  display: flex; align-items: center; gap: 8px;
  width: 100%; height: 32px; padding: 0 10px;
  border-radius: 6px;
  background: var(--bg-100);
  box-shadow: 0 0 0 1px var(--alpha-400);
  font-size: 13px; color: var(--gray-900);
  transition: background 0.15s;
}
.busca-btn:hover { background: var(--alpha-100); }
.busca-btn span { flex: 1; text-align: left; }
.busca-btn .icon { width: 14px; height: 14px; }

.modal.busca { align-items: flex-start; padding-top: 12vh; }
.cmd {
  position: relative; width: 100%; max-width: 600px;
  display: flex; flex-direction: column;
  max-height: min(520px, 76vh);
  background: var(--bg-100);
  border-radius: 12px;
  box-shadow: var(--shadow-modal);
  overflow: hidden;
  animation: pop-in 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.1);
}
.cmd-campo { display: flex; align-items: center; gap: 10px; height: 52px; padding: 0 16px; border-bottom: 1px solid var(--alpha-400); }
.cmd-campo .icon { color: var(--gray-700); }
.cmd-campo input { flex: 1; min-width: 0; height: 100%; border: none; outline: none; background: transparent; font-size: 15px; }
.cmd-campo input::placeholder { color: var(--gray-600); }
.cmd-lista { flex: 1; overflow-y: auto; padding: 6px; }
.cmd-grupo { padding: 10px 10px 6px; font-size: 12px; color: var(--gray-700); }
.cmd-item {
  display: flex; align-items: center; gap: 10px;
  width: 100%; height: 40px; padding: 0 10px;
  border-radius: 6px;
  font-size: 14px; text-align: left;
}
.cmd-item .icon { color: var(--gray-900); }
.cmd-item[aria-selected="true"] { background: var(--alpha-200); }
.cmd-item[aria-selected="true"] .icon { color: var(--gray-1000); }
.cmd-titulo { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cmd-detalhe { font-size: 12px; color: var(--gray-700); white-space: nowrap; }
.cmd-vazio { padding: 32px 16px; text-align: center; color: var(--gray-900); }
.cmd-rodape { display: flex; gap: 16px; padding: 10px 16px; border-top: 1px solid var(--alpha-400); background: var(--bg-200); font-size: 12px; color: var(--gray-900); }

/* Enquanto a página rola, o mouse não acende os itens (evita redesenhar a cada item que passa) */
body.rolando .ck-grid { pointer-events: none; }

/* Item achado pela busca pisca no checklist */
.ck-item.piscar { animation: piscar 1.6s ease-out; }
@keyframes piscar { 0%, 40% { background: var(--green-100); box-shadow: inset 0 0 0 1px var(--green-700); } 100% { background: transparent; box-shadow: none; } }

/* ---------------- Barra superior (celular) ---------------- */
.topbar { display: none; }
.overlay { display: none; }

/* ---------------- Conteúdo ---------------- */
.main { padding-left: 240px; min-height: 100dvh; }
.page { display: none; }
.page.active { display: block; animation: fade-in 0.2s ease-out; }

.page-header { background: var(--bg-100); border-bottom: 1px solid var(--alpha-400); }
.page-header .wrap {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding-top: 40px; padding-bottom: 40px;
}
.page-header h1 { font-size: 32px; line-height: 40px; font-weight: 600; letter-spacing: -1.28px; }
.page-header p { margin-top: 4px; color: var(--gray-900); }
.actions { display: flex; flex-wrap: wrap; gap: 8px; }

.wrap { max-width: 1200px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.wrap.wide { max-width: 1600px; }
.body { padding-top: 32px; padding-bottom: 48px; }

.alerts:empty { display: none; }
.alerts { display: flex; flex-direction: column; gap: 8px; padding: 16px 24px 0; max-width: 1200px; margin: 0 auto; }
.alert {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 13px; line-height: 18px;
  text-align: left; width: 100%;
}
.alert b { font-weight: 600; }
.alert.erro { background: var(--red-100); color: var(--red-900); box-shadow: inset 0 0 0 1px var(--red-400); }
.alert.aviso { background: var(--amber-100); color: var(--amber-900); box-shadow: inset 0 0 0 1px var(--amber-400); }
button.alert:hover { filter: brightness(0.98); }

/* ---------------- Pílulas ---------------- */
.pill {
  display: inline-flex; align-items: center; gap: 8px;
  height: 28px; padding: 0 12px;
  border-radius: 999px;
  font-size: 12px; font-weight: 500; white-space: nowrap;
  background: var(--bg-100);
  box-shadow: 0 0 0 1px var(--alpha-400);
  color: var(--gray-900);
}
.pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--gray-600); }
.pill.ok .dot { background: var(--green-700); box-shadow: 0 0 0 3px var(--green-100); }
.pill.erro { color: var(--red-900); }
.pill.erro .dot { background: var(--red-700); box-shadow: 0 0 0 3px var(--red-100); }

/* ---------------- Cards ---------------- */
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.card {
  display: flex; flex-direction: column;
  background: var(--bg-100);
  border-radius: 12px;
  box-shadow: var(--shadow-small);
  overflow: hidden;
}
.card-head { display: flex; align-items: flex-start; gap: 14px; padding: 24px 24px 0; }
.card-head h3 { font-size: 16px; line-height: 24px; font-weight: 600; letter-spacing: -0.32px; }
.card-head p { color: var(--gray-900); margin-top: 2px; }
.step {
  width: 28px; height: 28px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  border-radius: 999px;
  background: var(--gray-1000); color: var(--bg-100);
  font-size: 13px; font-weight: 600;
}
.card-body { flex: 1; padding: 20px 24px 24px; }
.card-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 24px;
  border-top: 1px solid var(--alpha-400);
  background: var(--bg-200);
  font-size: 13px; color: var(--gray-900);
}

.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  height: 26px; padding: 0 10px;
  border-radius: 999px;
  background: var(--gray-100);
  box-shadow: inset 0 0 0 1px var(--alpha-400);
  font-size: 12px; font-weight: 500;
}
.chip .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--gray-600); }
.chip.on .dot { background: var(--green-700); }
.chip.off .dot { background: var(--red-700); }
button.chip { cursor: pointer; transition: background 0.15s, box-shadow 0.15s; }
button.chip:hover { background: var(--alpha-200); box-shadow: inset 0 0 0 1px var(--alpha-500); }
.chip.off { color: var(--gray-700); }

/* ---------------- Botões ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 40px; padding: 0 14px;
  border-radius: 6px;
  font-size: 14px; font-weight: 500; white-space: nowrap;
  transition: background 0.15s, box-shadow 0.15s, color 0.15s;
}
.btn.sm { height: 32px; padding: 0 10px; font-size: 13px; }
.btn.primary { background: var(--gray-1000); color: var(--bg-100); }
.btn.primary:hover:not(:disabled) { background: color-mix(in srgb, var(--gray-1000) 85%, transparent); }
.btn.secondary { background: var(--bg-100); color: var(--gray-1000); box-shadow: 0 0 0 1px var(--alpha-400); }
.btn.secondary:hover:not(:disabled) { background: var(--alpha-100); }
.btn.danger { background: var(--red-700); color: #fff; }
.btn.danger:hover:not(:disabled) { background: var(--red-900); }
.btn:disabled { background: var(--gray-100); color: var(--gray-700); box-shadow: 0 0 0 1px var(--alpha-400); }
.btn .icon { width: 16px; height: 16px; }

/* ---------------- Busca ---------------- */
.search {
  display: flex; align-items: center; gap: 10px;
  height: 56px; padding: 0 14px;
  border-radius: 8px;
  background: var(--bg-100);
  box-shadow: 0 0 0 1px var(--alpha-400);
  transition: box-shadow 0.15s;
}
.search:focus-within { box-shadow: 0 0 0 1px var(--alpha-600), 0 0 0 4px var(--alpha-200); }
.search .icon { width: 20px; height: 20px; color: var(--gray-700); }
.search input {
  flex: 1; min-width: 0; height: 100%;
  border: none; outline: none; background: transparent;
  font-family: var(--mono); font-size: 20px; letter-spacing: 0.5px;
}
.search input::placeholder { color: var(--gray-600); font-family: var(--font); font-size: 16px; letter-spacing: 0; }
.search:has(input:disabled) { background: var(--gray-100); }
kbd {
  padding: 1px 6px; border-radius: 4px;
  border: 1px solid var(--alpha-400); background: var(--gray-100);
  font-family: var(--font); font-size: 11px; color: var(--gray-900);
}

.results { margin-top: 16px; }
.progress { height: 4px; background: var(--alpha-200); border-radius: 999px; overflow: hidden; }
.progress-bar { height: 100%; width: 0; background: var(--green-700); border-radius: 999px; transition: width 0.4s ease; }
.result-text { margin-top: 10px; font-size: 13px; color: var(--gray-900); }

/* ---------------- Checklist ---------------- */
.ck-top { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.ck-top .progress { flex: 1; height: 6px; }
.ck-top span { font-size: 13px; color: var(--gray-900); font-variant-numeric: tabular-nums; }
/* Computador: todas as categorias numa linha só (--cols = nº de categorias, definido pela página) */
.ck-grid { display: grid; grid-template-columns: repeat(var(--cols, 7), minmax(0, 1fr)); gap: 10px; align-items: start; }
.ck-col { background: var(--bg-100); border-radius: 12px; box-shadow: var(--shadow-small); padding: 4px; min-width: 0; contain: layout paint style; container-type: inline-size; }
/* Coluna bem fina (telas pequenas): letra um pouco menor para as palavras caberem inteiras */
@container (max-width: 125px) {
  .ck-col .ck-item { font-size: 11px; column-gap: 6px; padding: 5px 4px; }
  .ck-col .ck-head h3 { font-size: 11px; }
  .ck-col .ck-meta, .ck-col .ck-addbtn { font-size: 10px; }
}
.ck-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 8px; padding: 10px 8px 8px; }
.ck-head h3 { font-size: 12px; font-weight: 600; letter-spacing: 0.3px; }
.ck-count {
  padding: 0 7px; height: 20px; display: inline-flex; align-items: center;
  border-radius: 999px; background: var(--alpha-200);
  font-size: 11px; font-weight: 500; color: var(--gray-900);
  font-variant-numeric: tabular-nums;
}
.ck-count.full { background: var(--green-100); color: var(--green-900); }
.ck-item {
  display: grid; grid-template-columns: 16px minmax(0, 1fr); column-gap: 10px; align-items: center;
  width: 100%; padding: 6px 8px;
  border-radius: 6px;
  font-size: 13px; line-height: 18px; font-weight: 500;
  text-align: left;
}
.ck-item:hover { background: var(--alpha-100); }
.ck-nome { overflow-wrap: anywhere; hyphens: auto; }
.ck-box {
  position: relative; width: 16px; height: 16px;
  border-radius: 4px;
  box-shadow: inset 0 0 0 1px var(--alpha-500);
  background: var(--bg-100);
}
.ck-item:hover .ck-box { box-shadow: inset 0 0 0 1px var(--alpha-600); }
.ck-item.done .ck-box { background: var(--green-700); box-shadow: none; }
.ck-item.done .ck-box::after {
  content: ""; position: absolute; left: 5px; top: 2px;
  width: 4px; height: 8px;
  border: solid #fff; border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.ck-item.done .ck-nome { color: var(--gray-700); text-decoration: line-through; }
.ck-meta { grid-column: 2; display: flex; align-items: center; gap: 6px; margin-top: 3px; font-size: 11px; line-height: 14px; font-weight: 400; color: var(--gray-700); text-transform: capitalize; }
.ck-meta-txt { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ck-meta-data { flex-shrink: 0; white-space: nowrap; font-variant-numeric: tabular-nums; text-transform: none; }
.mini-avatar {
  width: 18px; height: 18px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 999px;
  color: #fff; font-size: 8px; font-weight: 600; line-height: 1; letter-spacing: 0;
  text-decoration: none;
  text-box: trim-both cap alphabetic; /* centraliza pela altura da letra maiúscula */
}
.ck-addbtn {
  display: flex; align-items: center; gap: 6px;
  width: 100%; margin-top: 2px; padding: 6px 8px;
  border-radius: 6px;
  font-size: 12px; color: var(--gray-700);
  text-align: left;
}
.ck-addbtn:hover { background: var(--alpha-100); color: var(--gray-1000); }
.ck-add { display: flex; flex-wrap: wrap; gap: 6px; padding: 4px; }
.ck-add input {
  flex: 1 1 100%; min-width: 0; height: 32px; padding: 0 10px;
  border: none; border-radius: 6px;
  background: var(--bg-100);
  box-shadow: 0 0 0 1px var(--alpha-400);
  font-size: 13px; outline: none;
  text-transform: uppercase;
}
.ck-add input:focus { box-shadow: 0 0 0 1px var(--alpha-600), 0 0 0 4px var(--alpha-200); }
.ck-add .btn { flex: 1; }
.ck-erro, .vazio {
  grid-column: 1 / -1;
  display: flex; flex-direction: column; align-items: center; gap: 14px;
  padding: 48px 24px;
  border: 1px dashed var(--alpha-500); border-radius: 8px;
  text-align: center; color: var(--gray-900);
}
.skeleton { height: 280px; border-radius: 12px; background: linear-gradient(90deg, var(--gray-100), var(--alpha-100), var(--gray-100)); background-size: 200% 100%; animation: shimmer 1.2s infinite linear; }

/* ---------------- Configurações ---------------- */
.table { width: 100%; border-collapse: collapse; }
.table th {
  text-align: left; padding: 10px 16px;
  font-size: 12px; font-weight: 500; color: var(--gray-900);
  background: var(--bg-200);
  border-bottom: 1px solid var(--alpha-400);
}
.table td { padding: 12px 16px; border-bottom: 1px solid var(--alpha-400); }
.table tr:last-child td { border-bottom: none; }
.table tbody tr:hover td { background: var(--alpha-100); }
.table td.nome { font-weight: 500; }
.table .url { font-family: var(--mono); font-size: 12px; color: var(--gray-900); word-break: break-all; }
.table .url:hover { color: var(--gray-1000); text-decoration: underline; }
.col-switch { width: 72px; }

.switch { position: relative; display: inline-flex; width: 32px; height: 18px; }
.switch input { position: absolute; inset: 0; opacity: 0; cursor: pointer; margin: 0; z-index: 1; }
.switch span { position: absolute; inset: 0; border-radius: 999px; background: var(--alpha-500); transition: background 0.15s; }
.switch span::after {
  content: ""; position: absolute; top: 2px; left: 2px;
  width: 14px; height: 14px; border-radius: 50%;
  background: #fff; box-shadow: 0 1px 2px #0003;
  transition: transform 0.15s;
}
.switch input:checked + span { background: var(--green-700); }
.switch input:checked + span::after { transform: translateX(14px); }
.switch input:focus-visible + span { outline: 2px solid var(--focus); outline-offset: 2px; }

/* ---------------- Aviso flutuante ---------------- */
.toast {
  position: fixed; right: 20px; bottom: 20px; z-index: 300;
  display: flex; align-items: center; gap: 10px;
  max-width: min(440px, calc(100vw - 40px));
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--bg-100);
  box-shadow: var(--shadow-modal);
  font-size: 13px; line-height: 18px;
  opacity: 0; transform: translateY(8px); pointer-events: none; visibility: hidden;
  transition: opacity 0.2s, transform 0.2s, visibility 0s 0.2s;
}
.toast.show { opacity: 1; transform: none; pointer-events: auto; visibility: visible; transition: opacity 0.2s, transform 0.2s; }
.toast .dot { width: 8px; height: 8px; flex-shrink: 0; border-radius: 50%; background: var(--green-700); }
.toast.erro .dot { background: var(--red-700); }

/* ---------------- Modal ---------------- */
.modal { position: fixed; inset: 0; z-index: 400; display: flex; align-items: center; justify-content: center; padding: 16px; }
.modal-fundo { position: absolute; inset: 0; background: color-mix(in srgb, var(--bg-200) 80%, transparent); backdrop-filter: blur(2px); animation: fade-in 0.2s ease-out; }
.modal-caixa { position: relative; width: 100%; max-width: 420px; background: var(--bg-100); border-radius: 12px; box-shadow: var(--shadow-modal); animation: pop-in 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.1); overflow: hidden; }
.modal-caixa .conteudo { padding: 24px; }
.modal-caixa h2 { font-size: 20px; line-height: 26px; font-weight: 600; letter-spacing: -0.4px; }
.modal-caixa p { margin-top: 6px; color: var(--gray-900); }
.modal-caixa .rodape { display: flex; justify-content: flex-end; gap: 8px; padding: 14px 24px; border-top: 1px solid var(--alpha-400); background: var(--bg-200); }

/* ---------------- Campos de formulário ---------------- */
.campos { display: flex; flex-direction: column; gap: 16px; margin-top: 20px; }
.campo { display: flex; flex-direction: column; gap: 8px; }
.campo span { font-size: 13px; color: var(--gray-900); }
.campo small { font-size: 12px; color: var(--gray-700); }
.campo input, .select {
  height: 40px; padding: 0 12px;
  border: none; border-radius: 6px; outline: none;
  background: var(--bg-100);
  box-shadow: 0 0 0 1px var(--alpha-400);
  transition: box-shadow 0.15s;
}
.campo input:hover, .select:hover { box-shadow: 0 0 0 1px var(--alpha-500); }
.campo input:focus, .select:focus { box-shadow: 0 0 0 1px var(--alpha-600), 0 0 0 4px var(--alpha-200); }
/* Seletor com seta própria (a do navegador fica colada na borda) */
.select {
  font: inherit; color: inherit; cursor: pointer;
  appearance: none; -webkit-appearance: none;
  padding-right: 38px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23525252' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px;
}
.dark .select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23a1a1a1' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); }

.select option { color: var(--gray-1000); background: var(--bg-100); }
.select.sm { height: 32px; padding: 0 30px 0 8px; font-size: 13px; background-position: right 8px center; background-size: 14px; }
.select:disabled { opacity: 0.5; cursor: default; }
.form-erro { padding: 10px 12px; border-radius: 6px; font-size: 13px; background: var(--red-100); color: var(--red-900); box-shadow: inset 0 0 0 1px var(--red-400); }

/* ---------------- Equipe ---------------- */
.badge {
  display: inline-flex; align-items: center; height: 20px; padding: 0 8px;
  border-radius: 999px;
  background: var(--alpha-200); color: var(--gray-900);
  font-size: 11px; font-weight: 500; white-space: nowrap;
}
.badge.admin { background: hsl(276 71% 92% / 0.6); color: hsl(274 71% 43%); }
.dark .badge.admin { background: hsl(277 46% 28% / 0.6); color: hsl(275 80% 71%); }
.equipe-lista { display: flex; flex-direction: column; }
.pessoa { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 20px; border-bottom: 1px solid var(--alpha-400); }
.pessoa:last-child { border-bottom: none; }
.equipe-grupo { display: flex; align-items: center; gap: 8px; padding: 10px 20px; background: var(--alpha-100); border-bottom: 1px solid var(--alpha-400); font-size: 12px; font-weight: 500; color: var(--gray-900); }
.equipe-grupo b { font-weight: 500; color: var(--gray-700); font-variant-numeric: tabular-nums; }
.pessoa.inativa .pessoa-quem { opacity: 0.5; }
.pessoa-quem { display: flex; align-items: center; gap: 12px; min-width: 0; }
.pessoa-quem .avatar { width: 36px; height: 36px; font-size: 13px; }
.pessoa-nome { display: flex; align-items: center; gap: 8px; font-weight: 500; text-transform: capitalize; }
.pessoa-nome .badge { text-transform: none; }
.pessoa-quem small { font-size: 12px; color: var(--gray-700); }
.pessoa-acoes { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.icon-btn:disabled { opacity: 0.4; cursor: default; background: none; }
.btn.perigo:hover:not(:disabled) { background: var(--red-100); color: var(--red-900); box-shadow: 0 0 0 1px var(--red-400); }
.cartao-senha, .cartao-aparencia { margin-top: 24px; }
.cartao-aparencia h3 { font-size: 20px; line-height: 26px; font-weight: 600; letter-spacing: -0.4px; }
.tema-grande { margin-top: 20px; }
.tema-grande button { width: 34px; height: 34px; }
.tema-grande .icon { width: 16px; height: 16px; }
.cartao-senha h3 { font-size: 20px; line-height: 26px; font-weight: 600; letter-spacing: -0.4px; }
.cartao-sub { margin-top: 6px; color: var(--gray-900); }
.campos-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 20px; }
.cartao-senha .form-erro { margin-top: 16px; }
/* Configurações: perfil */
.com-foto { background-size: cover; background-position: center; color: transparent; }
.cartao-perfil h3 { font-size: 20px; line-height: 26px; font-weight: 600; letter-spacing: -0.4px; }
.perfil-topo { display: flex; align-items: center; gap: 16px; margin-top: 20px; flex-wrap: wrap; }
.perfil-avatar { width: 64px; height: 64px; font-size: 22px; }
.perfil-quem { flex: 1; min-width: 120px; }
.perfil-quem p { font-size: 15px; font-weight: 500; text-transform: capitalize; }
.perfil-quem small { font-size: 13px; color: var(--gray-900); }
.perfil-foto-acoes { display: flex; gap: 8px; flex-wrap: wrap; }
.perfil-rotulo { margin-top: 24px; font-size: 13px; color: var(--gray-900); }
.perfil-cores { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 10px; }
.perfil-cor { width: 32px; height: 32px; border-radius: 999px; display: flex; align-items: center; justify-content: center; color: #fff; box-shadow: 0 0 0 1px var(--alpha-400); transition: transform 0.1s; }
.perfil-cor:not(:disabled):hover { transform: scale(1.1); }
.perfil-cor.escolhida { box-shadow: 0 0 0 2px var(--bg-100), 0 0 0 4px var(--gray-1000); }
.perfil-cor .icon { width: 16px; height: 16px; stroke-width: 3; }
.perfil-cor:disabled { opacity: 0.25; cursor: not-allowed; }
.perfil-cor.cor-invisivel { background: transparent; color: var(--gray-1000); border: 1.5px dashed var(--gray-700); box-shadow: none; cursor: default; }
.perfil-cor.cor-invisivel.escolhida { box-shadow: 0 0 0 2px var(--bg-100), 0 0 0 4px var(--gray-1000); }
.perfil-dica { margin-top: 12px; font-size: 12px; color: var(--gray-700); }
.perfil-dica:empty { display: none; }
@media (max-width: 760px) { .campos-2 { grid-template-columns: 1fr; } }
.papeis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 24px; }
.papel-card { padding: 20px; gap: 10px; align-items: flex-start; }
.papel-card p { color: var(--gray-900); font-size: 13px; line-height: 20px; }
@media (max-width: 760px) {
  .papeis { grid-template-columns: 1fr; }
  .pessoa { flex-wrap: wrap; padding: 12px 16px; }
}

/* ---------------- Compras ---------------- */
.compras-barra { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.compras-barra .select { min-width: 240px; }
.compras-busca { flex: 1; min-width: 240px; display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; border-radius: 6px; background: var(--bg-100); box-shadow: 0 0 0 1px var(--alpha-400); }
.compras-busca:focus-within { box-shadow: 0 0 0 1px var(--alpha-600), 0 0 0 4px var(--alpha-200); }
.compras-busca .icon { color: var(--gray-700); }
.compras-busca input { flex: 1; min-width: 0; height: 100%; border: none; outline: none; background: transparent; }
.compras-filtros { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.filtro { display: inline-flex; align-items: center; gap: 8px; height: 32px; padding: 0 12px; border-radius: 999px; font-size: 13px; color: var(--gray-900); box-shadow: 0 0 0 1px var(--alpha-400); background: var(--bg-100); }
.filtro b { font-weight: 500; font-variant-numeric: tabular-nums; color: var(--gray-1000); }
.filtro:hover { background: var(--alpha-100); }
.filtro.ativo { background: var(--gray-1000); color: var(--bg-100); box-shadow: none; }
.filtro.ativo b { color: var(--bg-100); }
.compras-card { overflow: hidden; }
.compras-rolagem { overflow-x: auto; }
.compras-tabela { min-width: 860px; }
/* Cronograma: larguras fixas, para as colunas não mudarem de lugar ao filtrar (Fornecedor fica com o que sobra) */
.cronograma-tabela { table-layout: fixed; min-width: 1000px; }
.cronograma-tabela th:nth-child(2) { width: 160px; }
.cronograma-tabela th:nth-child(3) { width: 125px; }
.cronograma-tabela th:nth-child(4) { width: 175px; }
.cronograma-tabela th:nth-child(5) { width: 160px; }
.cronograma-tabela th:nth-child(6) { width: 135px; }
.cronograma-tabela th:nth-child(7) { width: 92px; }
.compras-tabela td { vertical-align: middle; padding: 10px 16px; }
.compras-tabela .c-forn { font-weight: 500; }
.compras-tabela .c-forn small { display: block; margin-top: 2px; font-size: 12px; font-weight: 400; color: var(--gray-700); }
.compras-tabela .c-num { white-space: nowrap; font-variant-numeric: tabular-nums; }
.compras-tabela .c-num > * { vertical-align: middle; }
.compras-tabela .c-data { white-space: nowrap; color: var(--gray-900); font-variant-numeric: tabular-nums; }
.ordenar { display: inline-flex; align-items: center; gap: 6px; margin: -4px -6px; padding: 4px 6px; border-radius: 6px; font: inherit; color: inherit; white-space: nowrap; }
.ordenar:hover { background: var(--alpha-200); color: var(--gray-1000); }
.ordenar::after { content: ""; width: 12px; height: 12px; opacity: 0; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23888' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 15 5 5 5-5M7 9l5-5 5 5'/%3E%3C/svg%3E") no-repeat center; }
.ordenar:hover::after { opacity: 0.6; }
th[aria-sort=ascending] .ordenar, th[aria-sort=descending] .ordenar { color: var(--gray-1000); }
th[aria-sort=ascending] .ordenar::after { opacity: 1; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23888' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m18 15-6-6-6 6'/%3E%3C/svg%3E"); }
th[aria-sort=descending] .ordenar::after { opacity: 1; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23888' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); }
.compras-tabela .col-acao { width: 84px; text-align: right; white-space: nowrap; }
.compras-tabela .col-acao .icon-btn { display: inline-flex; }

.compras-tabela tr.s-cancelado td { color: var(--gray-700); }
.compras-tabela tr.s-cancelado .c-forn-nome { text-decoration: line-through; }
.compras-vazio { padding: 40px 16px !important; text-align: center; color: var(--gray-900); }
.num-link { color: var(--blue-700); text-decoration: underline; text-decoration-color: color-mix(in srgb, currentColor 40%, transparent); text-underline-offset: 3px; font-variant-numeric: tabular-nums; }
.dark .num-link { color: hsl(210 100% 70%); }
.num-link:hover { text-decoration-color: currentColor; }
.link-doc { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; margin-left: 4px; border-radius: 6px; color: var(--gray-900); }
.link-doc:hover { background: var(--alpha-200); color: var(--gray-1000); }
.link-doc.copiado { color: var(--green-700); }
.link-doc .icon { width: 14px; height: 14px; }
.estado { display: inline-flex; align-items: center; gap: 4px; height: 28px; padding: 0 10px; border-radius: 999px; font-size: 12px; font-weight: 500; white-space: nowrap; }
.estado .icon { width: 13px; height: 13px; stroke-width: 2.5; }
.estado.chegou, .estado.conferido { background: var(--green-100); color: var(--green-900); }
.estado.aguardando { background: var(--amber-100); color: var(--amber-900); box-shadow: inset 0 0 0 1px var(--amber-400); }
.estado.aguardando.atrasado { background: var(--red-100); color: var(--red-900); box-shadow: inset 0 0 0 1px var(--red-400); }
.estado.conferir { color: var(--gray-900); box-shadow: inset 0 0 0 1px var(--alpha-500); }
.estado.conferir:hover { color: var(--gray-1000); background: var(--alpha-100); }
.estado.chegou:hover, .estado.conferido:hover { filter: brightness(1.05); }
.estado.cancelado { background: var(--alpha-200); color: var(--gray-700); }

/* Faltas */
.faltas-tabela { min-width: 860px; }
.faltas-tabela .c-forn .num-link { font-weight: 500; }
.faltas-tabela .ft-quem { white-space: nowrap; color: var(--gray-900); font-size: 13px; }
.faltas-tabela .ft-quem .mini-avatar { margin-right: 6px; vertical-align: middle; }
.ft-pedido { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; padding: 4px 8px; margin: -4px -8px; border-radius: 6px; text-align: left; }
.ft-pedido b { font-weight: 500; color: var(--gray-1000); }
.ft-pedido small { font-size: 12px; color: var(--gray-700); font-variant-numeric: tabular-nums; }
.ft-pedido:hover { background: var(--alpha-100); }
.faltas-tabela tr.s-resolvida td { color: var(--gray-700); }
.nav-badge.alerta { background: var(--red-100); color: var(--red-900); }
.papel-vendedor .so-compra { display: none !important; }
.badge.vendedor { background: color-mix(in srgb, var(--blue-700) 14%, transparent); color: var(--blue-700); }
.campo-check.verde input { accent-color: var(--green-700); }
.ft-marca { display: inline-block; padding: 0 6px; border-radius: 4px; font-size: 12px; font-weight: 500; background: var(--alpha-200); color: var(--gray-900); vertical-align: 1px; }
.campo .opcional { font-style: normal; font-weight: 400; color: var(--gray-700); }
.campo > label { font-size: 13px; color: var(--gray-900); }
.combo { position: relative; }
.combo input { width: 100%; }
.combo-lista { position: absolute; z-index: 5; top: calc(100% + 4px); left: 0; right: 0; max-height: 232px; overflow-y: auto; padding: 4px; border-radius: 8px; background: var(--bg-100); box-shadow: 0 0 0 1px var(--alpha-400), 0 8px 24px rgba(0, 0, 0, 0.18); }
.combo-opcao { display: flex; align-items: center; gap: 6px; padding: 7px 10px; border-radius: 6px; font-size: 14px; cursor: pointer; }
.combo-opcao:hover, .combo-opcao.ativa { background: var(--alpha-200); }
.combo-nova { color: var(--green-900); font-weight: 500; }
.combo-nova .icon { width: 14px; height: 14px; }
.campo .combo-nova span { font-size: inherit; color: inherit; }
.modal-caixa:has(.combo-lista:not([hidden])) { overflow: visible; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.modal-caixa.largo { max-width: 620px; max-height: calc(100dvh - 32px); display: flex; flex-direction: column; }
.modal-caixa.largo .conteudo { overflow-y: auto; }
.modal-caixa .rodape { align-items: center; }
.campos-grade { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
.span-2 { grid-column: 1 / -1; }
.anexo-linha { display: flex; gap: 8px; }
.anexo-linha input { flex: 1; min-width: 0; }
.anexo-botao { cursor: pointer; height: 40px; }
.anexo-atual { display: flex; align-items: center; gap: 8px; margin-top: 2px; padding: 8px 10px; border-radius: 6px; background: var(--alpha-100); font-size: 13px; color: var(--gray-900); }
.anexo-atual span { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.campo-check { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--gray-900); cursor: pointer; }
.campo-check input { width: 16px; height: 16px; accent-color: var(--red-700); }
@media (max-width: 760px) {
  .campos-grade { grid-template-columns: 1fr; }
  .compras-barra .select, .compras-busca { min-width: 0; width: 100%; }
}

/* ---------------- Rodapé (login e páginas legais) ---------------- */
.rodape-legal {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 24px;
  padding: 24px 16px;
  border-top: 1px solid var(--alpha-400);
  font-size: 13px; color: var(--gray-900);
}
.rodape-legal a { color: inherit; text-decoration: none; transition: color 0.15s; }
.rodape-legal a:hover { color: var(--gray-1000); }

/* ---------------- Páginas de Privacidade e Termos ---------------- */
.legal-topo {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px; padding: 0 24px;
  border-bottom: 1px solid var(--alpha-400);
  background: var(--bg-100);
}
.legal-topo img { width: 72px; height: auto; display: block; }
html:not(.dark) .legal-topo img { filter: invert(1); }
.legal { max-width: 720px; margin: 0 auto; padding: 64px 16px; }
.legal h1 { font-size: 48px; line-height: 56px; font-weight: 600; letter-spacing: -2.88px; }
.legal .atualizado { margin-top: 12px; color: var(--gray-900); }
.legal-corpo { display: flex; flex-direction: column; gap: 32px; margin-top: 40px; font-size: 15px; line-height: 28px; color: var(--gray-900); }
.legal-corpo h2 { margin-bottom: 8px; font-size: 20px; line-height: 26px; font-weight: 600; letter-spacing: -0.4px; color: var(--gray-1000); }
.legal-corpo ul { padding-left: 20px; }
.legal-corpo strong { font-weight: 500; color: var(--gray-1000); }
.legal-pagina { min-height: 100dvh; display: flex; flex-direction: column; background: var(--bg-100); }
.legal-pagina main { flex: 1; }
@media (max-width: 760px) {
  .legal { padding: 40px 16px; }
  .legal h1 { font-size: 32px; line-height: 40px; letter-spacing: -1.28px; }
  .legal-topo { padding: 0 16px; }
}

@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes pop-in { from { opacity: 0; transform: translateY(-8px) scale(0.98); } to { opacity: 1; transform: none; } }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

/* ---------------- Celular / tela pequena ---------------- */
/* Tela pequena de notebook (1024–1279px): barra lateral só com ícones, sobra espaço para os Pedidos */
@media (min-width: 1024px) and (max-width: 1279px) {
  .sidebar { width: 64px; }
  .main { padding-left: 64px; }
  .brand-grande { padding: 16px 6px 12px; }
  .brand-grande img { width: 50px; }
  .busca-wrap { flex-direction: column; align-items: center; padding: 0 12px 4px; }
  .busca-btn { width: 40px; height: 36px; justify-content: center; padding: 0; }
  .busca-btn span, .busca-btn kbd { display: none; }
  .busca-wrap .sino { width: 40px; height: 36px; }
  .nav { padding: 8px 12px; align-items: center; }
  .nav-item { width: 40px; height: 36px; padding: 0; justify-content: center; font-size: 0; }
  .nav-item .icon { width: 18px; height: 18px; }
  .nav-badge { display: none; }
  .foot-row { justify-content: center; padding: 0; }
  .foot-row > span { display: none; }
  .theme-toggle { flex-direction: column; }
  .user { flex-direction: column; gap: 8px; padding: 4px 0; }
  .user-info { display: none; }
  .notif-painel { left: 72px; }
}

/* Notebook: colunas mais finas → itens mais compactos para tudo caber sem cortar */
@media (max-width: 1599px) {
  .wrap.wide { padding-left: 16px; padding-right: 16px; }
  .ck-grid { gap: 8px; }
  .ck-col { padding: 3px; }
  .ck-item { padding: 6px; column-gap: 7px; font-size: 12px; }
  .ck-meta { gap: 4px; }
  .mini-avatar { width: 16px; height: 16px; font-size: 7.5px; }
}

@media (max-width: 1023px) {
  .ck-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
  .notif-painel { top: 64px; left: 8px; right: 8px; width: auto; }
  .main { padding-left: 0; }
  .sidebar { transform: translateX(-100%); transition: transform 0.2s ease; width: 280px; z-index: 210; }
  body.menu-aberto .sidebar { transform: none; }
  body.menu-aberto .overlay { display: block; position: fixed; inset: 0; z-index: 200; background: color-mix(in srgb, var(--bg-200) 80%, transparent); }
  .topbar {
    position: sticky; top: 0; z-index: 40;
    display: flex; align-items: center; justify-content: space-between;
    height: 56px; padding: 0 12px;
    background: color-mix(in srgb, var(--bg-100) 80%, transparent);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--alpha-400);
  }
  .topbar .brand { height: auto; margin: 0; padding: 0; }
  .page-header .wrap { padding-top: 28px; padding-bottom: 28px; }
  .page-header h1 { font-size: 24px; line-height: 32px; letter-spacing: -0.96px; }
}
@media (max-width: 760px) {
  .cmd-rodape { display: none; }
  .modal.busca { padding-top: 16px; }
  .grid-2 { grid-template-columns: 1fr; }
  .wrap { padding-left: 16px; padding-right: 16px; }
  .alerts { padding: 12px 16px 0; }
  .body { padding-top: 20px; }
  .ck-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
  .col-url { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
