/* ==========================================================================
   Torneadora Goyaz — Sistema de Gestão
   Identidade: preto industrial + verde Goyaz (#41e902)
   ========================================================================== */

:root {
  --bg: #f5f6f3;
  --surface: #ffffff;
  --surface-2: #fafbf8;
  --line: #e4e7e0;
  --line-soft: #eef0ea;
  --ink: #0f130f;
  --ink-2: #394035;
  --muted: #6f776b;
  --muted-2: #939b8f;

  --brand: #41e902;
  --brand-dark: #1f9e0a;
  --brand-deep: #0e5f04;
  --brand-soft: #ecffe3;
  --brand-line: #c9f7b6;

  --sidebar: #0b0d0a;
  --sidebar-2: #12160f;
  --sidebar-line: #23291e;

  --danger: #d92d20;
  --danger-soft: #fee4e2;
  --warn: #b54708;
  --warn-soft: #fef0c7;
  --info: #175cd3;
  --info-soft: #e8f1ff;
  --ok: #067647;
  --ok-soft: #e3f9ec;
  --purple: #6941c6;
  --purple-soft: #f4f0ff;

  --radius: 16px;
  --radius-sm: 10px;
  --radius-xs: 8px;

  --shadow-sm: 0 1px 2px rgba(16, 20, 16, 0.06);
  --shadow: 0 1px 3px rgba(16, 20, 16, 0.05), 0 14px 30px -18px rgba(16, 20, 16, 0.28);
  --shadow-lg: 0 24px 60px -20px rgba(10, 14, 9, 0.35);

  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --display: 'Archivo', 'Inter', system-ui, sans-serif;
  --mono: ui-monospace, 'SF Mono', 'Cascadia Mono', Consolas, monospace;

  --sidebar-w: 264px;
  --topbar-h: 68px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html, body { height: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 14.5px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5 { margin: 0; font-family: var(--display); font-weight: 700; letter-spacing: -0.02em; color: var(--ink); }
p { margin: 0; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; }
img { max-width: 100%; }
svg { flex: none; }

::selection { background: var(--brand); color: #071005; }

/* Scrollbar discreta */
* { scrollbar-width: thin; scrollbar-color: #c9cec3 transparent; }
*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-thumb { background: #ccd2c7; border-radius: 99px; border: 3px solid transparent; background-clip: content-box; }
*::-webkit-scrollbar-thumb:hover { background: #b3bbae; background-clip: content-box; }

/* ==========================================================================
   Tela de carregamento
   ========================================================================== */

.boot {
  min-height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px;
  background: radial-gradient(1200px 600px at 50% -10%, #eef3e8, var(--bg));
}
.boot-logo img { width: 260px; max-width: 70vw; display: block; }
.boot-bar { width: 180px; height: 4px; border-radius: 99px; background: #e2e6dd; overflow: hidden; }
.boot-bar span { display: block; height: 100%; width: 40%; border-radius: 99px; background: var(--brand); animation: bootbar 1.1s ease-in-out infinite; }
@keyframes bootbar { 0% { transform: translateX(-110%); } 100% { transform: translateX(460%); } }
.boot p { color: var(--muted); font-size: 13px; letter-spacing: 0.02em; }

/* ==========================================================================
   Login / Instalação
   ========================================================================== */

.auth { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }

.auth-brand {
  position: relative; overflow: hidden;
  background:
    radial-gradient(900px 500px at 10% 0%, #1a2415 0%, transparent 60%),
    radial-gradient(700px 500px at 90% 100%, #16220f 0%, transparent 55%),
    var(--sidebar);
  color: #e9efe4;
  padding: 54px 56px;
  display: flex; flex-direction: column; justify-content: space-between; gap: 40px;
}
.auth-brand::before {
  content: ''; position: absolute; inset: -30% -20% auto auto;
  width: 620px; height: 620px;
  background-image: radial-gradient(#2b3a22 1.4px, transparent 1.4px);
  background-size: 22px 22px;
  opacity: .5; transform: rotate(8deg);
}
.auth-logo {
  background: #fff; border-radius: 18px; padding: 18px 22px;
  width: min(360px, 100%); position: relative; z-index: 1;
  box-shadow: 0 20px 50px -20px rgba(0, 0, 0, .8);
}
.auth-logo img { display: block; width: 100%; height: auto; }
.auth-brand h1 { position: relative; z-index: 1; font-size: 40px; line-height: 1.08; color: #fff; letter-spacing: -0.035em; max-width: 460px; }
.auth-brand h1 em { font-style: normal; color: var(--brand); }
.auth-brand p.lead { position: relative; z-index: 1; color: #a9b6a2; max-width: 440px; font-size: 15px; margin-top: 14px; }
.auth-servicos { position: relative; z-index: 1; display: flex; flex-wrap: wrap; gap: 10px; }
.auth-servicos span {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px; border-radius: 99px; font-size: 12.5px; font-weight: 600;
  color: #dfe8da; border: 1px solid #2e3a27; background: #131a10;
}
.auth-servicos span::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 3px rgba(65, 233, 2, .14); }
.auth-brand .foot { position: relative; z-index: 1; color: #6f7f66; font-size: 12px; }

.auth-panel { display: flex; align-items: center; justify-content: center; padding: 40px 28px; background: var(--surface); }
.auth-box { width: 100%; max-width: 400px; }
.auth-box .brand-mini { display: none; }
.auth-box h2 { font-size: 27px; margin-bottom: 6px; }
.auth-box .sub { color: var(--muted); margin-bottom: 26px; font-size: 14px; }
.auth-form { display: flex; flex-direction: column; gap: 16px; }
.auth-links { display: flex; justify-content: space-between; align-items: center; margin-top: 4px; font-size: 13px; color: var(--muted); }
.auth-hint { margin-top: 24px; padding: 14px 16px; border-radius: 12px; background: var(--surface-2); border: 1px dashed var(--line); color: var(--muted); font-size: 12.5px; }
.auth-demo-toggle { margin-top: 4px; }

/* ==========================================================================
   Estrutura do app
   ========================================================================== */

.app-shell { min-height: 100vh; display: grid; grid-template-columns: var(--sidebar-w) 1fr; }

.sidebar {
  position: sticky; top: 0; height: 100vh; z-index: 60;
  background: var(--sidebar);
  border-right: 1px solid #1b2117;
  display: flex; flex-direction: column;
  padding: 18px 14px 14px;
  color: #cfd8ca;
}
.sidebar-brand {
  background: #fff; border-radius: 14px; padding: 10px 12px; margin: 0 2px 18px;
  box-shadow: 0 10px 24px -14px rgba(0, 0, 0, .9);
}
.sidebar-brand img { display: block; width: 100%; height: auto; }
.sidebar-title { display: none; }

.nav { display: flex; flex-direction: column; gap: 3px; overflow-y: auto; flex: 1; padding-right: 2px; }
.nav-label {
  font-size: 10px; letter-spacing: .14em; text-transform: uppercase;
  color: #5d6a55; padding: 14px 12px 7px; font-weight: 700;
}
.nav-item {
  display: flex; align-items: center; gap: 11px;
  padding: 10px 12px; border-radius: 10px;
  color: #b9c4b3; font-weight: 500; font-size: 14px;
  border: 1px solid transparent;
  transition: background .15s, color .15s, border-color .15s;
  cursor: pointer;
}
.nav-item svg { width: 19px; height: 19px; opacity: .85; }
.nav-item:hover { background: #161c12; color: #f2f6ef; }
.nav-item.active {
  background: linear-gradient(90deg, rgba(65, 233, 2, .16), rgba(65, 233, 2, .05));
  color: #fff; border-color: rgba(65, 233, 2, .28);
  box-shadow: inset 2px 0 0 var(--brand);
}
.nav-item.active svg { color: var(--brand); opacity: 1; }
.nav-item .count {
  margin-left: auto; font-size: 11.5px; font-weight: 700;
  background: #1d2518; color: #cfd8ca; border-radius: 99px; padding: 2px 8px;
  border: 1px solid #2a3423;
}
.nav-item.active .count { background: var(--brand); color: #08120a; border-color: transparent; }

.sidebar-foot { padding-top: 14px; border-top: 1px solid var(--sidebar-line); margin-top: 12px; }
.user-chip {
  display: flex; align-items: center; gap: 10px; width: 100%;
  background: #131811; border: 1px solid #232b1e; border-radius: 12px;
  padding: 8px 10px; color: #dfe7da; cursor: pointer; text-align: left;
  transition: background .15s, border-color .15s;
}
.user-chip:hover { background: #182013; border-color: #2f3a28; }
.user-chip .avatar { width: 32px; height: 32px; font-size: 12px; }
.user-chip .u-info { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.user-chip .u-name { display: block; font-size: 13px; font-weight: 600; color: #f0f5ec; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.25; }
.user-chip .u-role { display: block; font-size: 11px; color: #7c8a73; line-height: 1.2; }
.sidebar .tiny { text-align: center; color: #4c5745; font-size: 10.5px; margin-top: 10px; letter-spacing: .04em; }

.main { min-width: 0; display: flex; flex-direction: column; }

.topbar {
  position: sticky; top: 0; z-index: 40;
  height: var(--topbar-h);
  display: flex; align-items: center; gap: 14px;
  padding: 0 26px;
  background: rgba(245, 246, 243, .86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.topbar .crumb { font-size: 13px; color: var(--muted); display: flex; align-items: center; gap: 8px; white-space: nowrap; min-width: 0; }
.topbar .crumb b { color: var(--ink); font-weight: 600; overflow: hidden; text-overflow: ellipsis; }
.topbar-spacer { flex: 1; }
.topbar .today { font-size: 12.5px; color: var(--muted); display: flex; align-items: center; gap: 7px; }
.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink-2);
  cursor: pointer; transition: background .15s, border-color .15s, transform .1s;
}
.icon-btn:hover { background: #fff; border-color: #cfd6c9; }
.icon-btn:active { transform: scale(.97); }
.burger { display: none; }

.page { padding: 26px; max-width: 1440px; width: 100%; margin: 0 auto; flex: 1; }
.page.narrow { max-width: 1080px; }

.page-head { display: flex; align-items: flex-end; gap: 18px; flex-wrap: wrap; margin-bottom: 22px; }
.page-head h1 { font-size: 28px; line-height: 1.15; }
.page-head .sub { color: var(--muted); font-size: 13.5px; margin-top: 5px; }
.page-actions { margin-left: auto; display: flex; gap: 9px; flex-wrap: wrap; }

.back-link {
  display: inline-flex; align-items: center; gap: 6px; color: var(--muted);
  font-size: 13px; font-weight: 500; margin-bottom: 10px; cursor: pointer;
}
.back-link:hover { color: var(--ink); }

/* ==========================================================================
   Grid e cartões
   ========================================================================== */

.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-main { grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); align-items: start; }
.stack { display: flex; flex-direction: column; gap: 16px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.grow { flex: 1; min-width: 0; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.card-head {
  display: flex; align-items: center; gap: 12px;
  padding: 16px 18px; border-bottom: 1px solid var(--line-soft);
}
.card-head h3 { font-size: 15.5px; }
.card-head .sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.card-head .spacer { flex: 1; }
.card-body { padding: 18px; }
.card-body.tight { padding: 12px; }
.card-foot { padding: 12px 18px; border-top: 1px solid var(--line-soft); background: var(--surface-2); font-size: 12.5px; color: var(--muted); }
.card.flush .card-body { padding: 0; }

/* KPI */
.kpi { padding: 17px 18px; position: relative; overflow: hidden; }
.kpi-top { display: flex; align-items: center; gap: 10px; }
.kpi-ico {
  width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center;
  background: var(--surface-2); border: 1px solid var(--line); color: var(--ink-2);
}
.kpi-ico svg { width: 17px; height: 17px; }
.kpi-label { font-size: 12px; font-weight: 600; letter-spacing: .02em; color: var(--muted); text-transform: uppercase; }
.kpi-value { font-family: var(--display); font-size: 29px; font-weight: 700; letter-spacing: -.03em; margin-top: 12px; line-height: 1; }
.kpi-value.small { font-size: 24px; }
.kpi-foot { margin-top: 8px; font-size: 12.5px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.kpi-foot b { color: var(--ink-2); font-weight: 600; }
.kpi.accent { background: linear-gradient(160deg, #f4ffef 0%, #ffffff 60%); border-color: var(--brand-line); }
.kpi.accent .kpi-ico { background: var(--brand); border-color: var(--brand); color: #07130a; }
.kpi.alerta .kpi-ico { background: var(--danger-soft); border-color: #fbc9c4; color: var(--danger); }
.kpi.alerta .kpi-value { color: var(--danger); }

.trend { display: inline-flex; align-items: center; gap: 3px; font-weight: 600; font-size: 12px; padding: 2px 6px; border-radius: 6px; }
.trend.up { color: var(--ok); background: var(--ok-soft); }
.trend.down { color: var(--danger); background: var(--danger-soft); }

/* ==========================================================================
   Botões
   ========================================================================== */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 38px; padding: 0 15px;
  border-radius: 10px; border: 1px solid transparent;
  background: var(--surface); color: var(--ink);
  font-size: 13.5px; font-weight: 600; letter-spacing: -0.01em;
  cursor: pointer; white-space: nowrap;
  transition: filter .15s, background .15s, border-color .15s, transform .1s, box-shadow .15s;
}
.btn svg { width: 17px; height: 17px; }
.btn:hover { filter: brightness(.97); }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .55; cursor: not-allowed; transform: none; }
.btn--primary { background: var(--brand); border-color: #35c402; color: #08130a; box-shadow: 0 1px 2px rgba(0, 0, 0, .08); }
.btn--primary:hover { filter: none; background: #3adb00; }
.btn--dark { background: var(--sidebar); color: #f2f6ef; border-color: #1b2117; }
.btn--dark:hover { background: #171d13; }
.btn--ghost { background: var(--surface); border-color: var(--line); color: var(--ink-2); }
.btn--ghost:hover { background: var(--surface-2); border-color: #cfd6c9; }
.btn--subtle { background: var(--surface-2); border-color: transparent; color: var(--ink-2); }
.btn--subtle:hover { background: #f0f2ec; }
.btn--danger { background: var(--danger); color: #fff; }
.btn--danger-ghost { background: #fff; border-color: #f3c1bc; color: var(--danger); }
.btn--danger-ghost:hover { background: var(--danger-soft); }
.btn--whats { background: #fff; color: #0e8a3a; border-color: #b4e6c5; }
.btn--whats:hover { background: #f2fdf6; filter: none; }
.btn--sm { height: 32px; padding: 0 11px; font-size: 12.5px; border-radius: 8px; }
.btn--sm svg { width: 15px; height: 15px; }
.btn--lg { height: 46px; padding: 0 22px; font-size: 15px; border-radius: 12px; }
.btn--block { width: 100%; }
.btn--icon { width: 34px; height: 34px; padding: 0; border-radius: 9px; }
.btn--icon svg { width: 16px; height: 16px; }
.btn-group { display: inline-flex; gap: 6px; }

.link-btn { background: none; border: 0; padding: 0; color: var(--brand-dark); font-weight: 600; cursor: pointer; font-size: 13px; }
.link-btn:hover { text-decoration: underline; }

/* ==========================================================================
   Formulários
   ========================================================================== */

.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.label { font-size: 12.5px; font-weight: 600; color: var(--ink-2); display: flex; gap: 6px; align-items: center; }
.label .req { color: var(--danger); }
.label .opt { color: var(--muted-2); font-weight: 500; font-size: 11.5px; }
.input, .select, .textarea {
  width: 100%; height: 40px; padding: 0 12px;
  border: 1px solid var(--line); border-radius: 10px;
  background: #fff; color: var(--ink); font-family: inherit; font-size: 14px;
  transition: border-color .15s, box-shadow .15s;
  appearance: none;
}
.textarea { height: auto; min-height: 84px; padding: 10px 12px; resize: vertical; line-height: 1.5; }
.select {
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236f776b' stroke-width='2.4' 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 11px center; padding-right: 34px;
}
.input:focus, .select:focus, .textarea:focus {
  outline: none; border-color: #9ddb83; box-shadow: 0 0 0 3.5px rgba(65, 233, 2, .16);
}
.input::placeholder, .textarea::placeholder { color: #a8afa2; }
.input[readonly] { background: var(--surface-2); }
.input.is-error, .select.is-error { border-color: #f0a8a2; box-shadow: 0 0 0 3px rgba(217, 45, 32, .1); }
.hint { font-size: 12px; color: var(--muted); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field-row.three { grid-template-columns: repeat(3, 1fr); }
.field-row.two-one { grid-template-columns: 2fr 1fr; }
.form-grid { display: flex; flex-direction: column; gap: 16px; }
.input-prefix { position: relative; }
.input-prefix span { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 13px; pointer-events: none; }
.input-prefix .input { padding-left: 36px; }

.search { position: relative; flex: 1; max-width: 400px; min-width: 180px; }
.search svg { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); width: 17px; height: 17px; color: var(--muted); pointer-events: none; }
.search .input { padding-left: 37px; background: #fff; }

.check { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; font-size: 13.5px; color: var(--ink-2); }
.check input { width: 17px; height: 17px; margin: 1px 0 0; accent-color: #22b000; flex: none; }

.switch { position: relative; display: inline-flex; align-items: center; gap: 9px; cursor: pointer; font-size: 13px; color: var(--ink-2); }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.switch .track { width: 38px; height: 22px; border-radius: 99px; background: #d4dace; position: relative; transition: background .18s; flex: none; }
.switch .track::after { content: ''; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: transform .18s; }
.switch input:checked + .track { background: var(--brand-dark); }
.switch input:checked + .track::after { transform: translateX(16px); }
.switch input:focus-visible + .track { box-shadow: 0 0 0 3px rgba(65, 233, 2, .25); }

/* ==========================================================================
   Tabelas
   ========================================================================== */

.table-wrap { width: 100%; overflow-x: auto; }
.table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13.5px; }
.table th {
  text-align: left; font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--muted); font-weight: 700; background: var(--surface-2);
  padding: 10px 14px; border-bottom: 1px solid var(--line);
  white-space: nowrap; position: sticky; top: 0; z-index: 1;
}
.table td { padding: 12px 14px; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: #fbfcfa; }
.table tr.row-click { cursor: pointer; }
.table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.table .center { text-align: center; }
.table .nowrap { white-space: nowrap; }
.table .actions { text-align: right; white-space: nowrap; }
.table .actions .btn--icon { background: transparent; border-color: transparent; color: var(--muted); }
.table .actions .btn--icon:hover { background: var(--surface-2); color: var(--ink); }
.table .strong { font-weight: 600; }
.table .muted { color: var(--muted); }
.table .small { font-size: 12px; }
.td-main { display: flex; align-items: center; gap: 10px; min-width: 0; }
.td-main .t { min-width: 0; }
.td-main .t b { display: block; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 260px; }
.td-main .t span { display: block; font-size: 12px; color: var(--muted); }

.avatar {
  width: 34px; height: 34px; border-radius: 50%; flex: none;
  display: grid; place-items: center;
  background: linear-gradient(145deg, #e9fbe1, #d6f7c6);
  color: #12620a; font-weight: 700; font-size: 12.5px; font-family: var(--display);
  border: 1px solid #c9eeb8; text-transform: uppercase;
}
.avatar--pj { background: #eef1f9; color: #33478c; border-color: #dbe1f2; }
.avatar--lg { width: 56px; height: 56px; font-size: 19px; }
.avatar--sm { width: 26px; height: 26px; font-size: 10px; }

.paginacao { display: flex; align-items: center; gap: 6px; justify-content: flex-end; padding: 12px 16px; }
.paginacao .info { font-size: 12.5px; color: var(--muted); margin-right: auto; }
.pag-btn {
  min-width: 32px; height: 32px; padding: 0 8px; border-radius: 8px;
  border: 1px solid var(--line); background: #fff; color: var(--ink-2);
  font-size: 13px; font-weight: 600; cursor: pointer;
}
.pag-btn.active { background: var(--ink); color: #fff; border-color: var(--ink); }
.pag-btn[disabled] { opacity: .4; cursor: not-allowed; }

/* ==========================================================================
   Badges, chips, pills
   ========================================================================== */

.badge {
  display: inline-flex; align-items: center; gap: 6px;
  height: 24px; padding: 0 9px; border-radius: 7px;
  font-size: 12px; font-weight: 600; letter-spacing: -0.01em; white-space: nowrap;
  background: #f1f3ee; color: var(--ink-2); border: 1px solid transparent;
}
.badge .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge--cinza { background: #f2f4ef; color: #55604f; border-color: #e3e7dd; }
.badge--azul { background: var(--info-soft); color: var(--info); border-color: #cfe0ff; }
.badge--ambar { background: var(--warn-soft); color: var(--warn); border-color: #f7dfa8; }
.badge--laranja { background: #fff1e6; color: #b93815; border-color: #fbd9c4; }
.badge--verde { background: var(--ok-soft); color: var(--ok); border-color: #bdeecf; }
.badge--escuro { background: #101410; color: #eaf2e5; border-color: #101410; }
.badge--vermelho { background: var(--danger-soft); color: var(--danger); border-color: #fbc9c4; }
.badge--roxo { background: var(--purple-soft); color: var(--purple); border-color: #e3d9ff; }
.badge--brand { background: var(--brand-soft); color: var(--brand-deep); border-color: var(--brand-line); }
.badge--sm { height: 21px; font-size: 11px; padding: 0 7px; }

.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  display: inline-flex; align-items: center; gap: 7px;
  height: 34px; padding: 0 13px; border-radius: 99px;
  border: 1px solid var(--line); background: #fff;
  font-size: 13px; font-weight: 500; color: var(--ink-2); cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
  white-space: nowrap;
}
.chip:hover { border-color: #cfd6c9; background: var(--surface-2); }
.chip.active { background: var(--ink); border-color: var(--ink); color: #fff; }
.chip .n {
  font-size: 11.5px; font-weight: 700; min-width: 20px; height: 20px; padding: 0 6px;
  display: inline-grid; place-items: center; border-radius: 99px;
  background: #f0f2ec; color: var(--ink-2);
}
.chip.active .n { background: rgba(255, 255, 255, .18); color: #fff; }

.pill { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 600; color: var(--muted); background: var(--surface-2); border: 1px solid var(--line); border-radius: 6px; padding: 2px 7px; }

/* ==========================================================================
   Modal
   ========================================================================== */

.modal-backdrop {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(9, 13, 8, .55); backdrop-filter: blur(3px);
  display: flex; align-items: flex-start; justify-content: center;
  padding: 5vh 18px 4vh; overflow-y: auto;
  animation: fadein .14s ease-out;
}
.modal {
  background: var(--surface); border-radius: 18px; width: 100%; max-width: 560px;
  box-shadow: var(--shadow-lg); border: 1px solid rgba(255, 255, 255, .5);
  animation: modalin .18s cubic-bezier(.2, .8, .2, 1);
  margin: auto 0;
}
.modal.wide { max-width: 760px; }
.modal.xwide { max-width: 940px; }
.modal-head { display: flex; align-items: flex-start; gap: 14px; padding: 20px 22px 14px; }
.modal-head h3 { font-size: 18px; }
.modal-head .sub { color: var(--muted); font-size: 13px; margin-top: 3px; }
.modal-head .x { margin-left: auto; }
.modal-body { padding: 4px 22px 20px; }
.modal-foot { display: flex; gap: 9px; justify-content: flex-end; padding: 15px 22px; border-top: 1px solid var(--line-soft); background: var(--surface-2); border-radius: 0 0 18px 18px; }
.modal-foot .left { margin-right: auto; }

@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }
@keyframes modalin { from { opacity: 0; transform: translateY(12px) scale(.985); } to { opacity: 1; transform: none; } }

/* Toasts */
.toasts { position: fixed; right: 20px; bottom: 20px; z-index: 300; display: flex; flex-direction: column; gap: 10px; align-items: flex-end; pointer-events: none; }
.toast {
  display: flex; align-items: center; gap: 10px;
  background: var(--ink); color: #f2f6ef; border-radius: 12px;
  padding: 12px 16px; font-size: 13.5px; font-weight: 500;
  box-shadow: 0 16px 40px -12px rgba(0, 0, 0, .5);
  max-width: 380px; pointer-events: auto;
  animation: toastin .2s cubic-bezier(.2, .8, .2, 1);
}
.toast svg { width: 17px; height: 17px; color: var(--brand); }
.toast--erro svg { color: #ff8a80; }
.toast--erro { background: #2b0f0d; }
.toast.saindo { animation: toastout .18s ease-in forwards; }
@keyframes toastin { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes toastout { to { opacity: 0; transform: translateY(6px); } }

/* ==========================================================================
   Estados vazios e alertas
   ========================================================================== */

.empty { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 46px 20px; gap: 8px; }
.empty-ico {
  width: 54px; height: 54px; border-radius: 16px; display: grid; place-items: center;
  background: var(--surface-2); border: 1px solid var(--line); color: var(--muted);
  margin-bottom: 6px;
}
.empty-ico svg { width: 24px; height: 24px; }
.empty h4 { font-size: 15.5px; }
.empty p { color: var(--muted); font-size: 13.5px; max-width: 380px; }
.empty .btn { margin-top: 10px; }

.alert {
  display: flex; gap: 11px; align-items: flex-start;
  border-radius: 12px; padding: 12px 14px; font-size: 13px; line-height: 1.45;
  border: 1px solid var(--line); background: var(--surface-2); color: var(--ink-2);
}
.alert svg { width: 18px; height: 18px; margin-top: 1px; }
.alert--info { background: var(--info-soft); border-color: #cfe0ff; color: #123f8f; }
.alert--warn { background: #fffaeb; border-color: #f7dfa8; color: #8a4b09; }
.alert--danger { background: #fff5f4; border-color: #fbc9c4; color: #96231a; }
.alert--ok { background: var(--ok-soft); border-color: #bdeecf; color: #05603a; }
.alert b { font-weight: 600; }

/* ==========================================================================
   Gráficos
   ========================================================================== */

.chart { display: flex; align-items: flex-end; gap: 8px; height: 190px; padding: 8px 2px 0; }
.chart .col { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; gap: 8px; height: 100%; text-align: center; min-width: 0; }
.chart .bar-track {
  flex: 1; display: flex; align-items: flex-end; justify-content: center; gap: 5px;
  background: repeating-linear-gradient(to top, #eef0ea 0 1px, transparent 1px 25%);
  border-bottom: 1px solid #e3e7dd;
}
.chart .bar {
  width: 42%; max-width: 30px; border-radius: 6px 6px 3px 3px;
  background: #e7ebdf; min-height: 3px; position: relative;
  transition: height .5s cubic-bezier(.2, .8, .2, 1);
}
.chart .bar.fill { background: linear-gradient(180deg, #47ef08, #2fc400); }
.chart .bar.recebido { background: linear-gradient(180deg, #111b0d, #33402b); }
.chart .bar:hover { filter: brightness(1.06); }
.chart .bar[data-tip]:hover::after {
  content: attr(data-tip); position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%);
  background: var(--ink); color: #fff; font-size: 11px; font-weight: 600; padding: 4px 7px; border-radius: 6px; white-space: nowrap; z-index: 5;
}
.chart .lbl { font-size: 11.5px; color: var(--muted); font-weight: 500; white-space: nowrap; }
.chart-legenda { display: flex; gap: 16px; flex-wrap: wrap; font-size: 12px; color: var(--muted); }
.chart-legenda i { width: 9px; height: 9px; border-radius: 3px; display: inline-block; margin-right: 6px; }

.meter { display: flex; flex-direction: column; gap: 13px; }
.meter-row { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; align-items: center; font-size: 13px; }
.meter-row .name { color: var(--ink-2); font-weight: 500; display: flex; align-items: center; gap: 7px; }
.meter-row .val { color: var(--muted); font-size: 12.5px; font-variant-numeric: tabular-nums; }
.meter-track { grid-column: 1 / -1; height: 7px; border-radius: 99px; background: #f0f2ec; overflow: hidden; }
.meter-fill { height: 100%; border-radius: 99px; background: var(--brand); transition: width .5s ease; }

/* ==========================================================================
   Página do painel
   ========================================================================== */

.hello { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.hello h1 { font-size: 30px; }
.hello .sub { color: var(--muted); font-size: 13.5px; margin-top: 4px; }
.hello .page-actions { margin-left: auto; }

.onboarding { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.ob-card { display: flex; gap: 13px; padding: 17px; border: 1px dashed #d8ded1; border-radius: 14px; background: #fdfdfb; }
.ob-num { width: 28px; height: 28px; border-radius: 9px; background: var(--brand-soft); color: var(--brand-deep); border: 1px solid var(--brand-line); display: grid; place-items: center; font-weight: 800; font-family: var(--display); font-size: 13px; flex: none; }
.ob-card h4 { font-size: 14px; margin-bottom: 3px; }
.ob-card p { font-size: 12.5px; color: var(--muted); }
.ob-card a { color: var(--brand-dark); font-weight: 600; font-size: 12.5px; }

.feed { display: flex; flex-direction: column; }
.feed-item { display: flex; gap: 12px; padding: 12px 18px; border-bottom: 1px solid var(--line-soft); align-items: flex-start; }
.feed-item:last-child { border-bottom: 0; }
.feed-item .ico { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: var(--surface-2); border: 1px solid var(--line); color: var(--ink-2); flex: none; }
.feed-item .ico svg { width: 15px; height: 15px; }
.feed-item .txt { flex: 1; min-width: 0; font-size: 13px; }
.feed-item .txt b { font-weight: 600; }
.feed-item .txt .m { display: block; color: var(--muted); font-size: 12px; }
.feed-item .val { font-weight: 700; font-size: 13px; font-variant-numeric: tabular-nums; white-space: nowrap; }

/* ==========================================================================
   Ordens de serviço
   ========================================================================== */

.os-hero {
  display: flex; align-items: flex-start; gap: 18px; flex-wrap: wrap;
  padding: 20px 22px; border-radius: var(--radius); border: 1px solid var(--line);
  background: linear-gradient(120deg, #ffffff 0%, #fbfdf9 100%);
  box-shadow: var(--shadow-sm);
}
.os-hero .num { font-family: var(--display); font-size: 30px; font-weight: 800; letter-spacing: -.03em; line-height: 1; }
.os-hero .meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 9px; align-items: center; }
.os-hero .acoes { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

.kv { display: grid; grid-template-columns: 116px 1fr; gap: 9px 14px; font-size: 13.5px; }
.kv dt { color: var(--muted); font-size: 12.5px; padding-top: 1px; }
.kv dd { margin: 0; color: var(--ink); font-weight: 500; word-break: break-word; }
.kv dd .muted { color: var(--muted); font-weight: 400; }

.itens-tabela td { padding: 10px 12px; }
.itens-tabela .desc { font-weight: 500; }
.itens-tabela .desc small { color: var(--muted); display: block; font-size: 11.5px; font-weight: 400; }

.totais { display: flex; flex-direction: column; gap: 9px; font-size: 13.5px; }
.totais .linha { display: flex; justify-content: space-between; gap: 12px; color: var(--ink-2); }
.totais .linha.total { border-top: 1px dashed var(--line); padding-top: 11px; margin-top: 3px; font-family: var(--display); font-size: 21px; font-weight: 700; letter-spacing: -.02em; color: var(--ink); align-items: baseline; }
.totais .linha.total .v { font-variant-numeric: tabular-nums; }
.totais .linha.pago { color: var(--ok); }
.totais .linha.saldo { font-weight: 700; color: var(--ink); }

.pag-item { display: flex; align-items: center; gap: 11px; padding: 11px 0; border-bottom: 1px dashed var(--line-soft); }
.pag-item:last-child { border-bottom: 0; }
.pag-item .ico { width: 32px; height: 32px; border-radius: 9px; background: var(--ok-soft); color: var(--ok); display: grid; place-items: center; flex: none; }
.pag-item .ico svg { width: 15px; height: 15px; }
.pag-item .info { flex: 1; min-width: 0; font-size: 13px; }
.pag-item .info b { font-weight: 600; }
.pag-item .info span { display: block; font-size: 11.5px; color: var(--muted); }
.pag-item .v { font-weight: 700; font-variant-numeric: tabular-nums; font-size: 13.5px; }

.timeline { position: relative; padding-left: 22px; }
.timeline::before { content: ''; position: absolute; left: 6px; top: 6px; bottom: 6px; width: 2px; background: var(--line-soft); }
.tl-item { position: relative; padding: 0 0 18px; font-size: 13px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before { content: ''; position: absolute; left: -22px; top: 4px; width: 10px; height: 10px; border-radius: 50%; background: #fff; border: 2.5px solid #cfd6c9; }
.tl-item.done::before { border-color: var(--brand-dark); background: var(--brand-soft); }
.tl-item.danger::before { border-color: var(--danger); background: var(--danger-soft); }
.tl-item b { font-weight: 600; display: block; }
.tl-item span { color: var(--muted); font-size: 12px; }

.status-select { min-width: 180px; height: 36px; font-weight: 600; }
.status-mini { width: auto; height: 30px; font-size: 12.5px; font-weight: 600; padding: 0 30px 0 10px; color: var(--ink); }

/* Formulário de OS — itens */
.itens-editor { display: flex; flex-direction: column; gap: 10px; }
.item-linha {
  display: grid; grid-template-columns: minmax(0, 2.4fr) 76px 108px 104px 34px; gap: 9px; align-items: end;
  padding: 11px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2);
}
.item-linha .sub { height: 34px; display: flex; align-items: center; justify-content: flex-end; font-weight: 700; font-size: 13px; font-variant-numeric: tabular-nums; }
.item-linha .btn { margin-bottom: 0; }
.item-head { display: grid; grid-template-columns: minmax(0, 2.4fr) 76px 108px 104px 34px; gap: 9px; padding: 0 12px; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.item-head span:nth-child(2), .item-head span:nth-child(3), .item-head span:nth-child(4) { text-align: right; }

.resumo-os { position: sticky; top: calc(var(--topbar-h) + 18px); }
.resumo-os .linha { display: flex; justify-content: space-between; font-size: 13.5px; color: var(--ink-2); }
.resumo-os .total { font-family: var(--display); font-size: 26px; font-weight: 800; letter-spacing: -.03em; }
.cliente-resumo { display: flex; gap: 12px; align-items: center; padding: 12px; border-radius: 12px; background: var(--brand-soft); border: 1px solid var(--brand-line); }
.cliente-resumo .t { min-width: 0; font-size: 13px; }
.cliente-resumo .t b { display: block; }
.cliente-resumo .t span { color: var(--brand-deep); font-size: 12px; }

/* ==========================================================================
   Serviços
   ========================================================================== */

.cat-block { margin-bottom: 8px; }
.cat-head { display: flex; align-items: center; gap: 10px; margin: 22px 0 12px; }
.cat-head h2 { font-size: 18px; }
.cat-head .n { font-size: 12px; color: var(--muted); background: var(--surface-2); border: 1px solid var(--line); border-radius: 99px; padding: 2px 9px; font-weight: 600; }
.cat-head .linha { flex: 1; height: 1px; background: var(--line); }
.servicos-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.servico-card { padding: 16px; border-radius: 14px; border: 1px solid var(--line); background: #fff; display: flex; flex-direction: column; gap: 10px; transition: border-color .15s, box-shadow .15s, transform .15s; }
.servico-card:hover { border-color: #cfd8c8; box-shadow: var(--shadow); transform: translateY(-1px); }
.servico-card.inativo { opacity: .62; }
.servico-card .top { display: flex; align-items: flex-start; gap: 8px; }
.servico-card h4 { font-size: 14.5px; line-height: 1.3; flex: 1; }
.servico-card .desc { font-size: 12.5px; color: var(--muted); min-height: 34px; }
.servico-card .foot { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; margin-top: auto; }
.servico-card .preco { font-family: var(--display); font-size: 22px; font-weight: 700; letter-spacing: -.02em; }
.servico-card .preco small { font-family: var(--font); font-size: 11.5px; color: var(--muted); font-weight: 500; letter-spacing: 0; }
.servico-card .acoes { display: flex; gap: 4px; }

/* ==========================================================================
   Financeiro
   ========================================================================== */

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 18px; overflow-x: auto; }
.tab {
  padding: 10px 14px; border: 0; background: none; cursor: pointer;
  font-size: 13.5px; font-weight: 600; color: var(--muted);
  border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap;
  display: inline-flex; align-items: center; gap: 7px;
}
.tab:hover { color: var(--ink); }
.tab.active { color: var(--ink); border-bottom-color: var(--brand); }
.tab .n { font-size: 11px; background: var(--surface-2); border-radius: 99px; padding: 2px 7px; color: var(--muted); }
.tab.active .n { background: var(--brand-soft); color: var(--brand-deep); }

.mes-picker { display: inline-flex; align-items: center; gap: 6px; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 4px; }
.mes-picker .btn { border: 0; background: transparent; }
.mes-picker .btn svg.girado { transform: rotate(180deg); }

.painel-top { grid-template-columns: minmax(0, 1.72fr) minmax(0, 1fr); align-items: start; }
.mes-picker input {
  border: 0; background: transparent; font-family: var(--font); font-weight: 600; font-size: 13px;
  color: var(--ink); width: 152px; text-align: center; outline: none;
}

.val-pos { color: var(--ok); }
.val-neg { color: var(--danger); }

/* ==========================================================================
   Relatórios
   ========================================================================== */

.rel-head { display: flex; gap: 12px; flex-wrap: wrap; align-items: flex-end; margin-bottom: 18px; }
.rel-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.rel-kpi { padding: 15px 16px; border-radius: 14px; border: 1px solid var(--line); background: #fff; }
.rel-kpi .l { font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 600; }
.rel-kpi .v { font-family: var(--display); font-size: 25px; font-weight: 700; letter-spacing: -.02em; margin-top: 6px; }
.rel-kpi .s { font-size: 12px; color: var(--muted); margin-top: 2px; }

.bars-list { display: flex; flex-direction: column; gap: 12px; }
.bars-list .item { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; font-size: 13px; }
.bars-list .item .n { font-weight: 500; }
.bars-list .item .v { font-weight: 600; font-variant-numeric: tabular-nums; }
.bars-list .trk { grid-column: 1 / -1; height: 8px; border-radius: 99px; background: #f0f2ec; overflow: hidden; }
.bars-list .fil { height: 100%; border-radius: 99px; background: linear-gradient(90deg, #41e902, #2bbd00); }

/* ==========================================================================
   Configurações
   ========================================================================== */

.config-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 22px; align-items: start; }
.config-nav { display: flex; flex-direction: column; gap: 3px; position: sticky; top: calc(var(--topbar-h) + 20px); }
.config-nav button {
  display: flex; align-items: center; gap: 9px; width: 100%;
  padding: 10px 12px; border-radius: 10px; border: 1px solid transparent;
  background: none; text-align: left; cursor: pointer; font-size: 13.5px; font-weight: 500; color: var(--ink-2);
}
.config-nav button svg { width: 17px; height: 17px; color: var(--muted); }
.config-nav button:hover { background: #fff; border-color: var(--line); }
.config-nav button.active { background: #fff; border-color: var(--line); color: var(--ink); box-shadow: var(--shadow-sm); }
.config-nav button.active svg { color: var(--brand-dark); }

.logo-preview { display: flex; align-items: center; gap: 16px; padding: 14px; border: 1px dashed var(--line); border-radius: 12px; background: var(--surface-2); }
.logo-preview img { width: 180px; height: auto; }

.usuario-row { display: flex; align-items: center; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--line-soft); }
.usuario-row:last-child { border-bottom: 0; }
.usuario-row .info { flex: 1; min-width: 0; }
.usuario-row .info b { font-weight: 600; font-size: 13.5px; display: block; }
.usuario-row .info span { color: var(--muted); font-size: 12px; }

.danger-zone { border: 1px solid #f3c1bc; border-radius: 14px; padding: 16px; background: #fffafa; }
.danger-zone h4 { color: var(--danger); margin-bottom: 4px; }

/* ==========================================================================
   Responsivo
   ========================================================================== */

@media (max-width: 1180px) {
  .grid-main { grid-template-columns: minmax(0, 1fr); }
  .resumo-os { position: static; }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rel-kpis { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 980px) {
  .painel-top { grid-template-columns: minmax(0, 1fr); }
  .auth { grid-template-columns: 1fr; }
  .auth-brand { display: none; }
  .auth-box .brand-mini { display: block; margin-bottom: 26px; }
  .auth-box .brand-mini img { width: 200px; }
  .config-layout { grid-template-columns: 1fr; }
  .config-nav { position: static; flex-direction: row; overflow-x: auto; }
  .config-nav button { white-space: nowrap; width: auto; }
  .app-shell { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed; left: 0; top: 0; bottom: 0; width: 280px; height: 100vh;
    transform: translateX(-100%); transition: transform .22s ease; box-shadow: var(--shadow-lg);
  }
  .sidebar.aberta { transform: none; }
  .sidebar-backdrop { position: fixed; inset: 0; background: rgba(9, 13, 8, .5); z-index: 55; backdrop-filter: blur(2px); }
  .burger { display: inline-flex; }
  .crumb-brand { display: none; }
  .page { padding: 18px 16px 40px; }
  .topbar { padding: 0 16px; }
  .topbar .today { display: none; }
}

@media (max-width: 820px) {
  .grid-2, .grid-3, .grid-4, .onboarding { grid-template-columns: minmax(0, 1fr); }
  .item-linha, .item-head { grid-template-columns: minmax(0, 1fr) 66px 96px 34px; }
  .item-head span:nth-child(4), .item-linha .sub { display: none; }
  .item-linha .btn--icon { grid-column: 4; }
  .kv { grid-template-columns: 100px 1fr; }
  .page-head h1, .hello h1 { font-size: 23px; }
  .os-hero .acoes { margin-left: 0; width: 100%; }
  .os-hero .acoes .btn { flex: 1; justify-content: center; }
  .rel-kpis { grid-template-columns: 1fr; }
  .field-row, .field-row.three, .field-row.two-one { grid-template-columns: 1fr; }
  .modal-foot { flex-direction: column-reverse; }
  .modal-foot .btn { width: 100%; }
  .modal-foot .left { margin-right: 0; }
  .chart { height: 160px; gap: 5px; }
  .table th, .table td { padding: 10px 11px; }
  .toasts { left: 14px; right: 14px; bottom: 14px; align-items: stretch; }
  .toast { max-width: none; }
}

@media (max-width: 540px) {
  .kpi-value { font-size: 25px; }
  .page-actions { width: 100%; }
  .page-actions .btn { flex: 1; }
  .search { max-width: none; }
  .table { font-size: 12.5px; }
}

/* ==========================================================================
   Impressão (relatórios)
   ========================================================================== */

.print-only { display: none; }

@media print {
  @page { size: A4; margin: 13mm; }
  body { background: #fff; font-size: 11px; }
  .sidebar, .topbar, .page-head, .page-actions, .tabs, .search, .burger, .toasts, .btn, .no-print, .paginacao, .sidebar-backdrop { display: none !important; }
  .app-shell { display: block; }
  .page { padding: 0; max-width: none; }
  .card { box-shadow: none; border: 1px solid #ddd; break-inside: avoid; margin-bottom: 10px; }
  .rel-kpis { grid-template-columns: repeat(2, 1fr); }
  .grid-2, .grid-3, .grid-4, .grid-main { grid-template-columns: 1fr 1fr; }
  .print-only { display: block; }
  .chart { height: 130px; }
  .badge { border: 1px solid #ccc; print-color-adjust: exact; -webkit-print-color-adjust: exact; }
  .chart .bar { print-color-adjust: exact; -webkit-print-color-adjust: exact; }
  .meter-fill, .bars-list .fil { print-color-adjust: exact; -webkit-print-color-adjust: exact; }
  a[href]::after { content: none; }
}
