:root {
  --navy: #13233a;
  --navy-2: #1b304c;
  --blue: #246bfd;
  --blue-dark: #1554d1;
  --blue-soft: #eaf1ff;
  --green: #13a66b;
  --green-soft: #e7f8f1;
  --red: #dc4c4c;
  --red-soft: #fff0f0;
  --amber: #d98b12;
  --amber-soft: #fff6df;
  --purple: #7c3aed;
  --purple-soft: #f0e9ff;
  --purple-ink: #5b21b6;
  --coin: #f3b51b;
  --coin-dark: #9b6700;
  --coin-soft: #fff7d6;
  --ink: #1d2939;
  --muted: #667085;
  --line: #e5e9f0;
  --surface: #ffffff;
  --background: #f5f7fb;
  --surface-subtle: #fafbfc;
  --surface-muted: #f1f3f6;
  --surface-hover: #edf4ff;
  --surface-disabled: #f4f6f8;
  --control-border: #d7deea;
  --control-border-strong: #aab8ca;
  --row-border: #edf0f4;
  --neutral-soft: #eef1f5;
  --on-primary: #ffffff;
  --sidebar-end: #0e1b2e;
  --sidebar-text: #d7e1ed;
  --sidebar-link: #b7c5d5;
  --sidebar-muted: #8194aa;
  --sidebar-brand-muted: #9fb0c4;
  --sidebar-accent: #f4c94e;
  --success-ink: #08794d;
  --primary-ink: #165dce;
  --warning-ink: #a66708;
  --danger-ink: #b73535;
  --info-ink: #294b82;
  --coin-black: #17120c;
  --coin-border: #efbd3a;
  --coin-highlight: #ffe17d;
  --choice-hover-border: #b9c9e8;
  --icon-muted: #a7b0bd;
  --coin-hero-start: #15243b;
  --coin-hero-end: #233b5c;
  --coin-hero-text: #bac7d7;
  --coin-hero-panel: rgba(255,255,255,.065);
  --coin-hero-line: rgba(255,255,255,.11);
  --coin-orbit-line: rgba(255,222,113,.24);
  --coin-orbit-glow: rgba(255,196,50,.12);
  --coin-shadow: rgba(0,0,0,.34);
  --coin-toast: #182b45;
  --coin-toast-loss: #563238;
  --coin-toast-text: #bdc8d6;
  --login-accent: #dce9ff;
  --login-accent-2: #e4f8ef;
  --login-panel: rgba(255,255,255,.96);
  --focus-ring: rgba(36,107,253,.1);
  --sidebar-hover: rgba(255,255,255,.065);
  --sidebar-active: rgba(69,132,255,.22);
  --sidebar-line: rgba(255,255,255,.08);
  --primary-shadow: rgba(36,107,253,.2);
  --sticky-shadow: rgba(21,37,58,.06);
  --shadow: 0 8px 26px rgba(17, 34, 56, .07);
  --radius: 14px;
  --sidebar: 236px;
}

* { box-sizing: border-box; }
html { font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; color: var(--ink); background: var(--background); }
body { margin: 0; min-height: 100vh; font-size: 14px; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button, select { cursor: pointer; }

.sidebar {
  position: fixed; inset: 0 auto 0 0; width: var(--sidebar); z-index: 20;
  display: flex; flex-direction: column; padding: 24px 14px 14px;
  background: linear-gradient(180deg, var(--navy), var(--sidebar-end)); color: var(--sidebar-text);
}
.brand { display: flex; align-items: center; gap: 11px; padding: 0 10px 26px; color: var(--on-primary); font-size: 18px; }
.brand span:last-child { display: flex; flex-direction: column; line-height: 1.05; }
.brand small { font-size: 12px; color: var(--sidebar-brand-muted); margin-top: 4px; }
.brand-mark { width: 39px; height: 39px; border-radius: 11px; display: grid; place-items: center; color: var(--on-primary); font-weight: 800; font-size: 13px; background: var(--blue); box-shadow: 0 8px 20px var(--primary-shadow); }
.brand-large { width: 52px; height: 52px; font-size: 16px; }
.brand-logo { max-width: 160px; height: auto; display: block; }
.login-logo { max-width: 200px; }
.sidebar nav { display: flex; flex-direction: column; gap: 4px; }
.nav-item { display: flex; align-items: center; gap: 11px; min-height: 44px; padding: 10px 12px; border-radius: 9px; color: var(--sidebar-link); transition: .18s ease; }
.nav-item:hover { background: var(--sidebar-hover); color: var(--on-primary); }
.nav-item.active { color: var(--on-primary); background: var(--sidebar-active); box-shadow: inset 3px 0 var(--blue); }
.nav-icon { flex: 0 0 23px; width: 23px; display: grid; place-items: center; }
.nav-icon svg { width: 19px; height: 19px; }
.nav-item small { display: block; color: var(--sidebar-muted); font-size: 11px; margin-top: 2px; }
.sidebar-bottom { margin-top: auto; border-top: 1px solid var(--sidebar-line); padding-top: 10px; }
.version-label { display: block; padding: 3px 12px 8px; color: var(--sidebar-accent); font-size: 8px; font-weight: 900; letter-spacing: .05em; }
.sidebar-bottom form { margin: 0; }
.nav-button { width: 100%; background: none; border: 0; text-align: left; }
.avatar { flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; font-weight: 800; color: var(--on-primary); background: var(--blue); }
.avatar-small { width: 30px; height: 30px; font-size: 10px; }
.avatar-large { width: 82px; height: 82px; font-size: 24px; }

.app-shell { min-height: 100vh; margin-left: var(--sidebar); }
.topbar { min-height: 68px; padding: 10px 30px; display: flex; align-items: center; justify-content: flex-end; border-bottom: 1px solid var(--line); background: var(--surface); }
.header-assistant { display: flex; align-items: center; gap: 9px; color: var(--ink); }
.mascot-loop { width: 44px; height: 44px; position: relative; display: block; flex: 0 0 auto; overflow: hidden; border-radius: 12px; box-shadow: var(--shadow); animation: mascot-idle 4.8s ease-in-out infinite; }
.mascot-loop video, .mascot-loop img { width: 100%; height: 100%; position: absolute; inset: 0; display: block; object-fit: cover; object-position: 50% 40%; }
.mascot-loop video { z-index: 2; }
.header-assistant span { display: flex; flex-direction: column; }
.header-assistant small { margin-top: 2px; color: var(--muted); font-size: 10px; }
.coin-mini { width: 27px; height: 27px; display: inline-grid; place-items: center; overflow: hidden; border-radius: 50%; background: var(--coin-black); border: 2px solid var(--coin-border); }
.coin-mini img { width: 100%; height: 100%; display: block; object-fit: cover; }
.eyebrow { color: var(--blue); font-size: 10px; font-weight: 800; letter-spacing: .14em; }
.menu-button { display: none; border: 0; background: none; font-size: 23px; color: var(--ink); }
main { max-width: 1680px; margin: 0 auto; padding: 28px 30px 48px; }

h1, h2, p { margin-top: 0; }
h1 { margin: 5px 0 7px; font-size: clamp(25px, 3vw, 32px); letter-spacing: -.035em; }
h2 { margin-bottom: 5px; font-size: 17px; letter-spacing: -.015em; }
p { color: var(--muted); line-height: 1.5; }
.muted { color: var(--muted); }
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 22px; }
.page-heading p { margin-bottom: 0; }
.heading-actions { display: flex; gap: 8px; align-items: center; }
.dashboard-heading { align-items: flex-start; }
.dashboard-actions { align-items: flex-end; flex-wrap: wrap; justify-content: flex-end; }
.dashboard-actions .period-form { margin: 0; }

.btn { min-height: 40px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 9px 15px; border: 1px solid transparent; border-radius: 9px; font-weight: 700; transition: .15s ease; white-space: nowrap; }
.btn:hover { transform: translateY(-1px); }
.btn-primary { color: var(--on-primary); background: var(--blue); box-shadow: 0 5px 13px var(--primary-shadow); }
.btn-primary:hover { background: var(--blue-dark); }
.btn-secondary { background: var(--surface); border-color: var(--control-border); color: var(--ink); }
.btn-secondary:hover { border-color: var(--control-border-strong); background: var(--surface-subtle); }
.btn-ghost { background: transparent; color: var(--muted); }
.btn-danger { background: var(--red-soft); color: var(--danger-ink); border-color: var(--red); }
.btn-block { width: 100%; }
.link, .table-link, .link-button { color: var(--blue); font-weight: 700; }
.link-button { border: 0; background: none; padding: 3px; }
.link-button.danger { color: var(--danger-ink); }
.row-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.row-actions form { margin: 0; }
.icon-link { width: 30px; height: 30px; display: grid; place-items: center; font-size: 24px; color: var(--muted); border-radius: 50%; }
.icon-link:hover { background: var(--blue-soft); color: var(--blue); }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 20px; overflow: hidden; }
.panel-heading { min-height: 72px; padding: 19px 21px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.panel-heading h2, .panel-heading p { margin-bottom: 0; }
.panel-heading p { font-size: 12px; }
.panel-filter { align-items: flex-end; }

.stats-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 15px; margin-bottom: 20px; }
.stat-card { min-height: 126px; display: flex; align-items: flex-start; gap: 14px; padding: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.stat-card > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.stat-card span { color: var(--muted); font-size: 12px; }
.stat-card b { font-size: 27px; line-height: 1.2; letter-spacing: -.04em; }
.stat-card b small { color: var(--muted); font-size: 13px; font-weight: 600; letter-spacing: 0; }
.stat-card small { color: var(--muted); font-size: 11px; }
.stat-icon { flex: 0 0 38px; height: 38px; display: grid; place-items: center; border-radius: 10px; font-weight: 900; }
.stat-icon.blue { background: var(--blue-soft); color: var(--blue); }
.stat-icon.green { background: var(--green-soft); color: var(--green); }
.stat-icon.red { background: var(--red-soft); color: var(--red); }
.stat-icon.amber { background: var(--amber-soft); color: var(--amber); }
.stat-icon.neutral { background: var(--neutral-soft); color: var(--muted); }
.stat-icon.coin { padding: 0; overflow: hidden; background: var(--coin-black); border: 2px solid var(--coin-border); border-radius: 50%; }
.stat-icon.coin img { width: 100%; height: 100%; display: block; object-fit: cover; }
.stat-card-danger { color: var(--red); background: var(--red-soft); border-color: var(--red); }
.stat-card-danger > div > span, .stat-card-danger > div > small { color: var(--red); }
.coin-text { color: var(--coin-dark); }
.progress { height: 8px; position: relative; background: var(--neutral-soft); border-radius: 99px; overflow: hidden; }
.progress span { height: 100%; display: block; background: var(--blue); border-radius: inherit; transition: width .25s ease; }
.progress-compact { height: 5px; margin-top: 3px; }

.two-columns { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(310px, .8fr); gap: 20px; align-items: start; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { padding: 11px 15px; color: var(--muted); background: var(--surface-subtle); border-bottom: 1px solid var(--line); text-align: left; font-size: 10px; white-space: nowrap; }
td { padding: 13px 15px; border-bottom: 1px solid var(--row-border); vertical-align: middle; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background-color: var(--surface-hover); }
td small, .table-link + small { display: block; color: var(--muted); font-size: 11px; margin-top: 3px; }
.empty-cell { padding: 35px; text-align: center; color: var(--muted); }
.team-list { padding: 6px 21px 16px; }
.team-progress { padding: 15px 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 1fr auto; gap: 6px 14px; }
.team-progress:last-child { border-bottom: 0; }
.team-progress div { display: flex; flex-direction: column; }
.team-progress div span, .team-progress small { color: var(--muted); font-size: 11px; }
.team-progress .progress { grid-column: 1 / -1; }
.team-progress small { grid-column: 1 / -1; }

.badge { display: inline-flex; align-items: center; padding: 5px 9px; border-radius: 99px; font-size: 11px; font-weight: 800; white-space: nowrap; }
.badge-concluida { color: var(--success-ink); background: var(--green-soft); }
.badge-pendente { color: var(--muted); background: var(--neutral-soft); }
.badge-em_andamento { color: var(--primary-ink); background: var(--blue-soft); }
.badge-aguardando { color: var(--warning-ink); background: var(--amber-soft); }
.badge-atrasada { color: var(--danger-ink); background: var(--red-soft); }
.coin-balance { display: inline-flex; align-items: center; gap: 6px; color: var(--coin-dark); font-weight: 800; white-space: nowrap; }
.coin-balance i { width: 24px; height: 24px; display: inline-grid; place-items: center; overflow: hidden; border-radius: 50%; background: var(--coin-black); border: 1px solid var(--coin-border); font-style: normal; }
.coin-balance i img { width: 100%; height: 100%; display: block; object-fit: cover; }
.coin-earned, .coin-preview { color: var(--coin-dark); font-weight: 800; }

label { display: flex; flex-direction: column; gap: 6px; color: var(--ink); font-size: 12px; font-weight: 700; }
input, select, textarea { width: 100%; min-height: 40px; padding: 9px 11px; color: var(--ink); background: var(--surface); border: 1px solid var(--control-border); border-radius: 8px; outline: 0; transition: .15s ease; }
select {
  -webkit-appearance: none; appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='%237e8ea4' d='M4 6l4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 10px center; background-size: 13px; padding-right: 30px;
}
textarea { resize: vertical; line-height: 1.45; }
input:focus, select:focus, textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px var(--focus-ring); }
input:disabled { background: var(--surface-disabled); color: var(--muted); }
.period-form { display: flex; align-items: flex-end; gap: 9px; }
.period-form label { min-width: 150px; }
.filter-grid { padding: 18px; display: grid; grid-template-columns: repeat(6, minmax(120px, 1fr)) auto; gap: 12px; align-items: flex-end; }
.filter-grid.sped-filters { grid-template-columns: minmax(150px, .3fr) minmax(280px, 1fr) auto; }
.sped-alert-panel { border-color: var(--warning); background: var(--amber-soft); }
.sped-alert-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; padding: 14px 20px 20px; list-style: none; }
.sped-alert-list a { display: flex; flex-direction: column; gap: 3px; padding: 10px 12px; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: 9px; text-decoration: none; }
.sped-alert-list a:hover { border-color: var(--warning); }
.sped-alert-list span { color: var(--muted); font-size: 11px; }
.company-actions { flex-wrap: wrap; min-width: 120px; }
.company-filters { padding: 18px; display: grid; grid-template-columns: minmax(220px, 1.5fr) repeat(3, minmax(135px, .75fr)) auto; gap: 12px; align-items: flex-end; }
.check-progress { min-width: 90px; display: flex; flex-direction: column; gap: 5px; }

.matrix-panel { overflow: visible; }
.matrix-legend { display: flex; align-items: center; flex-wrap: wrap; gap: 18px; padding: 12px 20px; color: var(--muted); font-size: 11px; border-bottom: 1px solid var(--line); }
.matrix-legend span { display: flex; align-items: center; gap: 5px; }
.legend-box, .matrix-check { width: 20px; height: 20px; border: 2px solid var(--control-border-strong); border-radius: 4px; background: var(--surface); color: transparent; font-style: normal; display: inline-grid; place-items: center; font-size: 12px; font-weight: 900; }
.legend-box.done, .matrix-check.done { border-color: var(--green); background: var(--green); color: var(--on-primary); }
.legend-box.late, .matrix-check.late:not(.done) { border-color: var(--red); background: var(--red-soft); }
.matrix-wrap { max-width: 100%; overflow: auto; max-height: calc(100vh - 300px); }
.matrix-table { width: max-content; min-width: 100%; }
.matrix-table th { position: sticky; top: 0; z-index: 4; height: 48px; text-align: center; background: var(--surface-subtle); box-shadow: inset 0 -1px var(--line); }
.matrix-table td { height: 46px; padding: 7px 8px; background: var(--surface); }
.matrix-table tbody tr:nth-child(even) td { background: var(--surface-subtle); }
.matrix-table tbody tr:hover td { background: var(--surface-hover); }
.matrix-table .sticky-code { position: sticky; left: 0; width: 70px; min-width: 70px; z-index: 5; text-align: center; }
.matrix-table .sticky-company { position: sticky; left: 70px; width: 285px; min-width: 285px; z-index: 5; text-align: left; box-shadow: 4px 0 8px var(--sticky-shadow); }
.matrix-table th.sticky-code, .matrix-table th.sticky-company { z-index: 8; background: var(--neutral-soft); }
.matrix-table .sticky-company small { display: block; color: var(--muted); font-weight: 400; text-transform: none; letter-spacing: 0; }
.matrix-table .sticky-status { position: sticky; right: 0; width: 92px; min-width: 92px; z-index: 6; background: var(--surface-subtle); box-shadow: -4px 0 8px var(--sticky-shadow); }
.routine-head { width: 76px; max-width: 86px; overflow: hidden; text-overflow: ellipsis; }
.matrix-cell { min-width: 76px; text-align: center; }
.matrix-check { margin: 0 auto; padding: 0; transition: .15s ease; }
.matrix-check:hover { transform: scale(1.12); border-color: var(--blue); }
.matrix-check.loading { opacity: .45; pointer-events: none; }
.matrix-empty { color: var(--muted); }
.matrix-percent { min-width: 68px; text-align: center; }
.matrix-percent b { font-size: 12px; }
.matrix-percent.complete b { color: var(--green); }
.matrix-percent.complete .progress span { background: var(--green); }

.annual-panel { overflow: visible; }
.annual-count { color: var(--muted); font-size: 11px; font-weight: 800; white-space: nowrap; }
.annual-filters { padding: 16px 20px; display: grid; grid-template-columns: minmax(250px, 1.4fr) repeat(3, minmax(150px, .7fr)); gap: 12px; align-items: end; border-bottom: 1px solid var(--line); background: var(--surface-subtle); }
.search-control { position: relative; }
.search-control svg { width: 17px; height: 17px; position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.search-control input { padding-left: 36px; }
.annual-filter-empty td { padding: 34px; color: var(--muted); text-align: center; }
[hidden] { display: none !important; }
.annual-legend { display: flex; align-items: center; flex-wrap: wrap; gap: 17px; padding: 11px 20px; color: var(--muted); font-size: 11px; border-bottom: 1px solid var(--line); }
.annual-legend span { display: flex; align-items: center; gap: 6px; }
.legend-status { width: 20px; height: 20px; display: inline-grid; place-items: center; border-radius: 6px; font-size: 11px; font-style: normal; font-weight: 900; }
.legend-status.complete { color: var(--green); background: var(--green-soft); }
.legend-status.special { color: var(--purple-ink); background: var(--purple-soft); }
.legend-status.progressing { color: var(--blue); background: var(--blue-soft); }
.legend-status.pending { color: var(--red); background: var(--red-soft); }
.legend-status.empty { color: var(--muted); background: var(--neutral-soft); }
.annual-wrap { max-width: 100%; max-height: 620px; overflow: auto; }
.annual-table { width: 1288px; min-width: 100%; table-layout: fixed; }
.annual-table th { position: sticky; top: 0; z-index: 5; text-align: center; background: var(--surface-subtle); box-shadow: inset 0 -1px var(--line); }
.annual-table td { height: 76px; padding: 9px 10px; background: var(--surface); }
.annual-table tbody tr:nth-child(even) td { background: var(--surface-subtle); }
.annual-table tbody tr:hover td { background: var(--surface-hover); }
.annual-table .annual-company { position: sticky; left: 0; width: 370px; min-width: 370px; z-index: 7; text-align: left; border-right: 1px solid var(--line); box-shadow: 7px 0 12px var(--sticky-shadow); }
.annual-table th.annual-company { z-index: 9; background: var(--neutral-soft); }
.company-heading { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.company-heading b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.company-heading .company-edit-link { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.company-code { flex: 0 0 auto; color: var(--blue); font-size: 10px; font-weight: 900; }
.mobile-row-summary { display: none; }
.company-edit-link { color: var(--blue); font-weight: 800; text-decoration: none; }
.company-edit-link:hover { color: var(--blue-dark); text-decoration: underline; }
.annual-company > small { display: block; margin: 3px 0 5px; overflow: hidden; color: var(--muted); font-size: 10px; font-weight: 400; text-overflow: ellipsis; white-space: nowrap; }
.company-responsible { max-width: 245px; }
.annual-month, .annual-month-cell { width: 64px; min-width: 64px; text-align: center; }
.annual-table .current-month { background: var(--blue-soft) !important; box-shadow: inset 2px 0 var(--blue), inset -2px 0 var(--blue); }
.month-status { min-width: 49px; min-height: 31px; padding: 4px 6px; display: inline-flex; align-items: center; justify-content: center; gap: 4px; border-radius: 7px; font-size: 10px; font-weight: 900; }
.month-status i { min-width: 11px; font-style: normal; font-size: 11px; }
.month-status.complete { color: var(--success-ink); background: var(--green-soft); }
.month-status.special { color: var(--purple-ink); background: var(--purple-soft); }
.month-status.progressing { color: var(--blue-dark); background: var(--blue-soft); }
.month-status.pending { color: var(--danger-ink); background: var(--red-soft); }
.month-status.empty { color: var(--muted); background: var(--surface-muted); }
.annual-table .annual-total { position: sticky; right: 0; width: 91px; min-width: 91px; z-index: 7; background: var(--surface-subtle); box-shadow: -4px 0 8px var(--sticky-shadow); }
.annual-table th.annual-total { z-index: 9; }
.annual-overall { min-width: 66px; text-align: center; }
.annual-overall b { font-size: 11px; }
.responsible-inline { display: grid; grid-template-columns: minmax(105px, 1fr) auto; gap: 5px; align-items: center; margin: 0; }
.responsible-inline select { min-height: 32px; padding: 5px 24px 5px 7px; font-size: 11px; background-position: right 7px center; background-size: 11px; }
.priority-inline { display: grid; grid-template-columns: minmax(120px, 1fr) auto; gap: 5px; align-items: center; margin: 0; }
.priority-inline select { min-height: 32px; padding: 5px 24px 5px 7px; font-size: 11px; background-position: right 7px center; background-size: 11px; }
.priority-badge { display: inline-flex; padding: 5px 9px; border-radius: 99px; font-size: 10px; font-weight: 800; white-space: nowrap; }
.priority-mensal { color: var(--warning-ink); background: var(--amber-soft); }
.priority-normal { color: var(--primary-ink); background: var(--blue-soft); }
.badge-especial { color: var(--purple-ink); background: var(--purple-soft); }
.special-note { display: block; margin-top: 5px; color: var(--purple-ink); font-size: 10px; font-weight: 800; }
.priority-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.priority-stats .stat-icon { flex-basis: 43px; font-size: 10px; }
.priority-stats .stat-card:nth-child(n+3) b { font-size: 18px; letter-spacing: -.02em; }
.btn-save-mini { min-height: 32px; padding: 5px 8px; color: var(--on-primary); background: var(--blue); border: 0; border-radius: 7px; font-size: 10px; font-weight: 800; }
.btn-save-mini:hover { background: var(--blue-dark); }
.responsible-name { color: var(--ink); font-size: 11px; font-weight: 700; }

.form-panel { padding: 23px; }
.form-panel > .panel-heading { margin: -23px -23px 22px; }
.form-panel.wide { max-width: 1150px; margin-left: auto; margin-right: auto; }
.form-stack { display: flex; flex-direction: column; gap: 17px; }
.form-grid { display: grid; gap: 14px; }
.form-grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.form-grid.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.label-hint { color: var(--muted); font-weight: 400; }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; border-top: 1px solid var(--line); padding-top: 18px; }
fieldset { margin: 0; padding: 17px; border: 1px solid var(--line); border-radius: 10px; }
legend { padding: 0 6px; font-weight: 800; }
.field-tools { display: flex; justify-content: flex-end; gap: 10px; margin: -29px 0 12px; }
.choice-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; max-height: 280px; overflow-y: auto; }
.routine-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.choice-card { flex-direction: row; align-items: center; gap: 9px; min-height: 47px; padding: 9px 11px; border: 1px solid var(--line); border-radius: 8px; font-weight: 500; cursor: pointer; }
.choice-card:hover { border-color: var(--choice-hover-border); background: var(--surface-hover); }
.choice-card:has(input:checked) { border-color: var(--blue); background: var(--blue-soft); }
.choice-card input { width: 17px; min-height: 17px; margin: 0; accent-color: var(--blue); }
.choice-card span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.choice-card b { display: block; font-size: 10px; color: var(--blue); }
.choice-card.compact { justify-content: flex-start; }
.info-box { display: flex; flex-direction: column; gap: 4px; padding: 14px; border-radius: 9px; background: var(--blue-soft); color: var(--info-ink); font-size: 12px; }

.task-layout { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(300px, .65fr); gap: 20px; }
.detail-progress { padding: 18px 21px 8px; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 12px; }
.checklist { list-style: none; padding: 8px 21px 12px; margin: 0; }
.checklist-item { min-height: 52px; display: flex; align-items: center; gap: 11px; border-bottom: 1px solid var(--line); }
.checklist-item > span { flex: 1; }
.checklist-item.done > span { color: var(--muted); text-decoration: line-through; }
.check-button { flex: 0 0 22px; width: 22px; height: 22px; padding: 0; border: 2px solid var(--control-border-strong); color: transparent; background: var(--surface); border-radius: 5px; font-size: 12px; font-weight: 900; }
.checklist-item.done .check-button { color: var(--on-primary); border-color: var(--green); background: var(--green); }
.delete-link { border: 0; background: none; color: var(--icon-muted); font-size: 20px; }
.delete-link:hover { color: var(--red); }
.inline-form { display: flex; gap: 8px; padding: 16px 21px 21px; border-top: 1px solid var(--line); }
.task-meta { padding: 21px; }
.task-meta h2 { padding-bottom: 13px; border-bottom: 1px solid var(--line); }
.task-meta dl { margin: 0; }
.task-meta dl div { display: flex; justify-content: space-between; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.task-meta dt { color: var(--muted); }
.task-meta dd { margin: 0; text-align: right; font-weight: 700; }
.notes { margin: 17px 0; padding: 13px; border-radius: 9px; background: var(--surface-subtle); }
.notes span { color: var(--muted); font-size: 11px; text-transform: uppercase; font-weight: 800; }
.notes p { margin: 5px 0 0; color: var(--ink); white-space: pre-line; }

.clients-layout { grid-template-columns: minmax(280px, .7fr) minmax(500px, 1.5fr); }
.account-layout { max-width: 850px; grid-template-columns: .7fr 1.3fr; margin: 0 auto; }
.profile-card { padding: 32px; text-align: center; display: flex; flex-direction: column; align-items: center; }
.profile-card h2 { margin: 16px 0 3px; }
.profile-card p { margin-bottom: 15px; }
.report-progress { min-width: 130px; display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: center; }
.negative { color: var(--red); font-weight: 700; }
.positive { color: var(--green); font-weight: 700; }

.coin-hero { min-height: 172px; margin-bottom: 18px; padding: 25px 30px; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 23px; overflow: hidden; position: relative; border-radius: 18px; color: var(--on-primary); background: linear-gradient(120deg, var(--coin-hero-start), var(--coin-hero-end)); box-shadow: var(--shadow); }
.coin-hero:after { content: ''; position: absolute; width: 220px; height: 220px; right: -70px; top: -90px; border: 1px solid var(--coin-orbit-line); border-radius: 50%; }
.coin-hero h2 { margin: 4px 0; color: var(--on-primary); font-size: 36px; }
.coin-hero h2 small { font-size: 15px; color: var(--coin-highlight); }
.coin-hero p { margin: 0; color: var(--coin-hero-text); }
.coin-orbit { width: 118px; height: 118px; display: grid; place-items: center; position: relative; isolation: isolate; border: 1px solid var(--coin-orbit-line); border-radius: 50%; box-shadow: 0 0 34px var(--coin-orbit-glow); }
.coin-orbit::after { content: ''; position: absolute; z-index: 0; left: 25px; right: 25px; bottom: 6px; height: 10px; border-radius: 50%; background: var(--coin-shadow); filter: blur(5px); animation: directcoin-shadow 3.2s ease-in-out infinite; }
.directcoin-3d-canvas { position: absolute; z-index: 2; inset: 0; width: 100%; height: 100%; display: block; }
.directcoin-3d-fallback { z-index: 1; width: 84px; height: 84px; display: grid; place-items: center; border-radius: 50%; transition: opacity .2s ease; }
.directcoin-3d-fallback img { width: 100%; height: 100%; display: block; object-fit: cover; border: 3px solid var(--coin-border); border-radius: 50%; }
.directcoin-3d-ready .directcoin-3d-fallback { opacity: 0; }
.direct-coin { width: 76px; height: 76px; position: relative; display: grid; place-items: center; overflow: hidden; border-radius: 50%; background: var(--coin-black); border: 3px solid var(--coin-border); box-shadow: var(--shadow); }
.direct-coin img { width: 100%; height: 100%; display: block; object-fit: cover; }
.direct-coin.small { width: 54px; height: 54px; border-width: 2px; }
@keyframes directcoin-shadow {
  0%, 100% { transform: scale(.82); opacity: .42; }
  50% { transform: scale(1.08); opacity: .2; }
}
@media (prefers-reduced-motion: reduce) {
  .coin-orbit::after, .mascot-loop, .empty-mascot, .assistant-media { animation: none !important; }
}
.coin-hero-stat { min-width: 225px; z-index: 1; padding: 17px 20px; border: 1px solid var(--coin-hero-line); border-radius: 12px; background: var(--coin-hero-panel); display: flex; flex-direction: column; }
.coin-hero-stat span, .coin-hero-stat small { color: var(--coin-hero-text); font-size: 11px; }
.coin-hero-stat b { margin: 5px 0 2px; color: var(--coin-highlight); font-size: 24px; }
.coin-rule-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 13px; margin-bottom: 20px; }
.coin-rule-grid article { min-height: 118px; padding: 18px; display: flex; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); }
.coin-rule-grid small { color: var(--muted); font-weight: 800; letter-spacing: .08em; font-size: 9px; }
.coin-rule-grid b { display: block; margin: 4px 0; font-size: 19px; }
.coin-rule-grid p { margin: 0; font-size: 11px; }
.rule-icon { flex: 0 0 33px; height: 33px; display: grid; place-items: center; border-radius: 9px; color: var(--green); background: var(--green-soft); font-weight: 900; }
.rule-icon.fast, .rule-icon.max { color: var(--coin-dark); background: var(--coin-soft); }
.rule-icon.late { color: var(--muted); background: var(--neutral-soft); }
.coin-layout { grid-template-columns: minmax(0, 1.4fr) minmax(300px, .7fr); }
.rank-number { display: inline-flex; min-width: 32px; font-size: 18px; }
tr.current-user td { background: var(--coin-soft); }
.department-badge { display: inline-flex; padding: 5px 9px; border: 1px solid var(--line); border-radius: 99px; color: var(--muted); background: var(--surface-subtle); font-size: 10px; font-weight: 800; }
.ranking-protected td { background: var(--surface-subtle); }
.ranking-obscured { display: inline-flex; color: var(--muted); filter: blur(5px); opacity: .7; user-select: none; pointer-events: none; }
.ranking-protected small.ranking-obscured { display: block; width: max-content; }
.coin-label { padding: 4px 9px 4px 5px; display: inline-flex; align-items: center; gap: 5px; color: var(--coin-dark); background: var(--coin-soft); border-radius: 99px; font-size: 10px; font-weight: 900; }
.coin-label img { width: 24px; height: 24px; display: block; object-fit: cover; border: 1px solid var(--coin-border); border-radius: 50%; }
.coin-settings .btn { align-self: flex-end; }
.coin-info { padding: 28px; text-align: center; display: flex; flex-direction: column; align-items: center; }
.coin-info h2 { margin-top: 13px; }
.coin-info .fine-print { margin-top: auto; padding-top: 15px; font-size: 10px; border-top: 1px solid var(--line); }
.coin-amount { font-weight: 900; white-space: nowrap; }
.coin-disclaimer { text-align: center; font-size: 10px; }
.coin-toast { position: fixed; right: 24px; bottom: 24px; z-index: 100; min-width: 260px; padding: 13px 17px; display: flex; align-items: center; gap: 10px; border-radius: 13px; background: var(--coin-toast); color: var(--on-primary); box-shadow: var(--shadow); opacity: 0; transform: translateY(20px); transition: .22s ease; }
.coin-toast.visible { opacity: 1; transform: translateY(0); }
.coin-toast.loss { background: var(--coin-toast-loss); }
.coin-toast div { display: flex; flex-direction: column; }
.coin-toast small { color: var(--coin-toast-text); font-size: 10px; margin-top: 2px; }

.flash { position: relative; margin-bottom: 16px; padding: 13px 44px 13px 15px; border-radius: 9px; font-weight: 650; animation: flash-in .25s ease; }
.flash-success { color: var(--success-ink); background: var(--green-soft); border: 1px solid var(--green); }
.flash-error { color: var(--danger-ink); background: var(--red-soft); border: 1px solid var(--red); }
.flash button { position: absolute; right: 10px; top: 7px; border: 0; background: none; font-size: 22px; color: inherit; }
@keyframes flash-in { from { opacity: 0; transform: translateY(-6px); } }
.empty-state { color: var(--muted); text-align: center; padding: 30px; }
.empty-state.compact { padding: 16px; }
.dashboard-empty-state { min-height: 330px; padding: 52px 24px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.empty-illustration { width: 58px; height: 58px; margin-bottom: 18px; display: grid; place-items: center; color: var(--blue); background: var(--blue-soft); border-radius: 16px; }
.empty-illustration svg { width: 30px; height: 30px; }
.dashboard-empty-state h2 { margin-bottom: 8px; font-size: 21px; }
.dashboard-empty-state p { max-width: 600px; margin-bottom: 22px; }
.empty-mascot { width: 112px; height: 112px; margin-bottom: 17px; object-fit: cover; object-position: 50% 40%; border: 3px solid var(--surface); border-radius: 28px; box-shadow: var(--shadow); animation: mascot-idle 4.8s ease-in-out infinite; }
.empty-actions { display: flex; flex-direction: column; align-items: center; gap: 13px; }

.assistant-fab { position: fixed; right: 22px; bottom: 22px; z-index: 45; min-width: 188px; padding: 7px 12px 7px 7px; display: flex; align-items: center; gap: 9px; color: var(--on-primary); border: 1px solid rgba(255,255,255,.12); border-radius: 15px; background: linear-gradient(135deg, var(--navy), var(--navy-2)); box-shadow: 0 14px 34px rgba(9,21,38,.24); }
.assistant-fab .mascot-loop { width: 42px; height: 42px; border-radius: 11px; box-shadow: none; }
.assistant-fab span { display: flex; flex-direction: column; align-items: flex-start; }
.assistant-fab small { margin-top: 2px; color: var(--sidebar-brand-muted); font-size: 9px; }
.assistant-overlay { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 20px; background: rgba(7,16,28,.54); backdrop-filter: blur(5px); }
.assistant-overlay-card { width: min(520px, 100%); padding: 20px; display: grid; grid-template-columns: 154px 1fr; align-items: center; gap: 22px; border: 1px solid var(--line); border-radius: 22px; background: var(--surface); box-shadow: 0 24px 60px rgba(5,14,27,.3); animation: assistant-in .22s ease-out; }
.assistant-overlay-card h2 { margin: 6px 0; font-size: 21px; }
.assistant-overlay-card p { margin: 0; font-size: 12px; }
.assistant-media { width: 154px; height: 120px; position: relative; overflow: hidden; border-radius: 17px; background: var(--surface-subtle); }
.assistant-media video, .assistant-media img, .assistant-media > div { width: 100%; height: 100%; position: absolute; inset: 0; object-fit: cover; object-position: 50% 42%; }
.assistant-overlay[data-state="loading"] .assistant-media, .assistant-overlay[data-state="analyzing"] .assistant-media { animation: mascot-working 1.5s ease-in-out infinite; }
.assistant-overlay[data-state="success"] .assistant-media { box-shadow: 0 0 0 3px var(--green-soft); }
.assistant-overlay[data-state="alert"] .assistant-media { box-shadow: 0 0 0 3px var(--amber-soft); }
@keyframes assistant-in { from { opacity: 0; transform: translateY(9px) scale(.98); } }
@keyframes mascot-idle { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
@keyframes mascot-working { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.025); } }

.login-body { min-height: 100vh; display: grid; place-items: center; padding: 20px; background: radial-gradient(circle at 15% 5%, var(--login-accent), transparent 37%), radial-gradient(circle at 85% 100%, var(--login-accent-2), transparent 35%), var(--background); }
.login-card { width: min(440px, 100%); padding: 36px; border-radius: 20px; background: var(--login-panel); border: 1px solid var(--line); box-shadow: var(--shadow); }
.login-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 38px; }
.login-brand > div { display: flex; flex-direction: column; font-size: 17px; }
.login-brand small { color: var(--muted); font-size: 10px; margin-top: 3px; text-transform: uppercase; letter-spacing: .08em; }
.login-card h1 { font-size: 27px; }
.login-card .form-stack { margin-top: 24px; }
.login-hint { margin: 22px 0 0; padding-top: 17px; border-top: 1px solid var(--line); text-align: center; font-size: 11px; }
.error-card { text-align: center; }
.error-card .btn { margin-top: 15px; }

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --blue: #6ea0ff;
    --blue-dark: #8eb6ff;
    --blue-soft: #172d50;
    --green: #48c991;
    --green-soft: #15382d;
    --red: #ff7979;
    --red-soft: #462326;
    --amber: #f1b94d;
    --amber-soft: #3d311b;
    --coin-dark: #ffd36a;
    --coin-soft: #3b311a;
    --ink: #e8eef7;
    --muted: #9eacc0;
    --line: #29384b;
    --surface: #111c2b;
    --background: #0b1420;
    --surface-subtle: #162235;
    --surface-muted: #1c2a3c;
    --surface-hover: #1a3152;
    --surface-disabled: #202d3f;
    --control-border: #3a4a60;
    --control-border-strong: #64758d;
    --row-border: #253449;
    --neutral-soft: #243246;
    --success-ink: #72d9aa;
    --primary-ink: #9bbcff;
    --warning-ink: #f4c56d;
    --danger-ink: #ff9a9a;
    --info-ink: #aec8ff;
    --choice-hover-border: #5274a8;
    --icon-muted: #7e8ea4;
    --focus-ring: rgba(110,160,255,.2);
    --sticky-shadow: rgba(0,0,0,.28);
    --shadow: 0 8px 26px rgba(0,0,0,.22);
    --login-accent: #132d50;
    --login-accent-2: #15382d;
    --login-panel: rgba(17,28,43,.96);
  }
}

@media (max-width: 1250px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .filter-grid { grid-template-columns: repeat(3, 1fr); }
  .routine-grid { grid-template-columns: repeat(4, 1fr); }
  .coin-rule-grid { grid-template-columns: repeat(2, 1fr); }
  .annual-filters { grid-template-columns: repeat(2, minmax(180px, 1fr)); }
  .company-filters { grid-template-columns: repeat(2, minmax(180px, 1fr)); }
}
@media (max-width: 980px) {
  .sidebar { transform: translateX(-100%); transition: transform .2s ease; }
  .sidebar.open { transform: translateX(0); box-shadow: var(--shadow); }
  .app-shell { margin-left: 0; }
  .menu-button { display: block; }
  .topbar { height: 58px; padding: 0 18px; background: var(--surface); border-bottom: 1px solid var(--line); display: flex; align-items: center; position: sticky; top: 0; z-index: 12; backdrop-filter: blur(8px); }
  main { padding: 22px 18px 40px; }
  .two-columns, .task-layout, .clients-layout, .account-layout { grid-template-columns: 1fr; }
  .choice-grid { grid-template-columns: repeat(2, 1fr); }
  .routine-grid { grid-template-columns: repeat(3, 1fr); }
  .form-grid.four { grid-template-columns: repeat(2, 1fr); }
  .coin-hero { grid-template-columns: auto 1fr; }
  .coin-hero-stat { grid-column: 1 / -1; }
}
@media (max-width: 680px) {
  .page-heading { align-items: flex-start; flex-direction: column; }
  .stats-grid { grid-template-columns: 1fr; }
  .stat-card { min-height: 108px; }
  .period-form, .panel-filter { align-items: stretch; flex-direction: column; width: 100%; }
  .period-form { margin-top: 10px; }
  .period-form label { min-width: 0; }
  .filter-grid { grid-template-columns: 1fr 1fr; }
  .filter-grid .btn { grid-column: 1 / -1; }
  .form-grid.two, .form-grid.three, .form-grid.four { grid-template-columns: 1fr; }
  .choice-grid, .routine-grid { grid-template-columns: 1fr; }
  .matrix-table .sticky-company { width: 210px; min-width: 210px; }
  .annual-table .annual-company { width: 280px; min-width: 280px; }
  .login-card { padding: 27px 23px; }
  .inline-form { flex-direction: column; }
  .coin-rule-grid { grid-template-columns: 1fr; }
  .annual-filters { grid-template-columns: 1fr; }
  .company-filters { grid-template-columns: 1fr; }
  .coin-hero { grid-template-columns: 1fr; text-align: center; justify-items: center; padding: 25px 20px; }
  .coin-hero-stat { width: 100%; min-width: 0; }
  .header-assistant span, .assistant-fab span { display: none; }
  .assistant-fab { min-width: 0; padding: 7px; border-radius: 14px; }
  .assistant-overlay-card { grid-template-columns: 1fr; text-align: center; justify-items: center; }
}
@media (max-width: 500px) {
  /* Nas telas de celular, as tabelas densas (matriz de rotinas, status anual,
     tarefas, relatórios) viram cartões empilhados em vez de exigir rolagem
     lateral: cada <tr> passa a ser um bloco, e cada <td> mostra seu rótulo
     (via data-label) acima ou ao lado do valor. */
  .matrix-wrap, .annual-wrap { overflow: visible; max-height: none; }

  .matrix-table, .matrix-table thead, .matrix-table tbody,
  .matrix-table tr, .matrix-table td, .matrix-table th,
  .annual-table, .annual-table thead, .annual-table tbody,
  .annual-table tr, .annual-table td, .annual-table th,
  .table-wrap table, .table-wrap thead, .table-wrap tbody,
  .table-wrap tr, .table-wrap td, .table-wrap th {
    display: block; width: auto !important; min-width: 0 !important; max-width: none !important;
  }
  .matrix-table thead, .annual-table thead, .table-wrap thead { display: none; }
  .matrix-table, .annual-table, .table-wrap table { width: 100% !important; }

  .matrix-table tbody tr, .annual-table tbody tr, .table-wrap tbody tr {
    margin-bottom: 12px; border: 1px solid var(--line); border-radius: 12px;
    background: var(--surface) !important; overflow: hidden;
  }

  /* célula genérica: rótulo à esquerda, valor à direita */
  .matrix-table td, .annual-table td, .table-wrap td {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
    position: static !important; box-shadow: none !important; background: transparent !important;
    height: auto; padding: 9px 12px; border-bottom: 1px solid var(--line);
  }
  .matrix-table tr td:last-child, .annual-table tr td:last-child, .table-wrap tr td:last-child { border-bottom: none; }
  .matrix-table td[data-label]::before, .annual-table td[data-label]::before, .table-wrap td[data-label]::before {
    content: attr(data-label); font-weight: 600; color: var(--muted); font-size: 12px; flex-shrink: 0;
    min-width: 92px;
  }

  /* célula de identidade (empresa/tarefa): vira o cabeçalho do cartão, sem rótulo */
  .matrix-table .sticky-company, .annual-table .annual-company, .table-wrap .card-title {
    display: block; background: var(--surface-subtle) !important; font-weight: 600;
    padding: 12px 14px; text-align: left;
  }
  .matrix-table .sticky-company small { display: block; margin-top: 2px; }
  .annual-company > small { display: block; margin: 4px 0; }
  .annual-table .company-responsible { margin-top: 8px; }

  /* Visão geral: os 12 meses viram uma grade compacta (4 por linha) em vez de
     12 linhas cheias empilhadas, para cada empresa caber num cartão menor.
     Usa CSS Grid (não flex-wrap) porque alguns navegadores móveis calculam
     mal a altura de um flex container com quebra de linha + overflow, e
     acabam cortando as linhas de baixo da grade. */
  .annual-table tbody tr { display: grid; grid-template-columns: repeat(4, 1fr); overflow: visible !important; }
  .annual-table .annual-company, .annual-table .annual-total { grid-column: 1 / -1; }
  .annual-table .annual-month-cell {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
    padding: 8px 4px; border-right: 1px solid var(--line);
  }
  .annual-table td:nth-child(5), .annual-table td:nth-child(9), .annual-table td:nth-child(13) { border-right: none; }
  .annual-table .annual-month-cell[data-label]::before { font-size: 10px; min-width: 0; }

  /* Visão geral: cada empresa vira 1 linha resumida (código + nome + status%);
     CNPJ, responsável e os 12 meses só aparecem ao tocar para abrir. */
  .annual-table .annual-company > small,
  .annual-table .company-responsible,
  .annual-table .annual-month-cell,
  .annual-table .annual-total {
    display: none;
  }
  .annual-table tbody tr.row-expanded .annual-company > small { display: block; }
  .annual-table tbody tr.row-expanded .company-responsible { display: block; }
  .annual-table tbody tr.row-expanded .annual-month-cell { display: flex; }
  .annual-table tbody tr.row-expanded .annual-total { display: flex; }
  .annual-table .annual-company { padding-bottom: 12px; }
  .annual-table tbody tr.row-expanded .annual-company { padding-bottom: 8px; }

  .mobile-row-summary { display: inline-flex; align-items: center; gap: 8px; margin-left: auto; flex-shrink: 0; }
  .mobile-status-pill { font-size: 13px; }
  .row-toggle-btn {
    width: 26px; height: 26px; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center;
    border-radius: 50%; border: 1px solid var(--line); background: transparent; color: var(--ink);
    font-size: 12px; line-height: 1; transition: transform .15s ease;
  }
  .annual-table tbody tr.row-expanded .row-toggle-btn { transform: rotate(180deg); }
  .table-wrap .card-title small { display: block; margin-top: 3px; font-weight: 400; color: var(--muted); }

  /* elementos redundantes num cartão empilhado */
  .table-wrap tr td.row-open-link { display: none; }
  .matrix-percent, .annual-overall { justify-content: flex-end; }
}
