:root {
  font-family:
    Inter,
    Segoe UI,
    Arial,
    sans-serif;
  color: #243345;
  background: #f3f5f8;
  font-synthesis: none;
  font-size: 14px;
  --navy: #132a3b;
  --teal: #087f72;
  --muted: #738091;
  --border: #e3e8ee;
}
* {
  box-sizing: border-box;
}
.plan-reference {
  max-width: 24rem;
}
.plan-reference summary {
  cursor: pointer;
  color: var(--teal);
  margin-top: 7px;
  font-size: 11px;
}
.plan-reference small {
  overflow-wrap: anywhere;
}
body {
  margin: 0;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a,
input,
select,
textarea {
  outline-offset: 4px;
}
button {
  cursor: pointer;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: white;
  color: inherit;
  padding: 10px 15px;
  font-weight: 600;
}
button:hover {
  background: #f0f5f5;
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
a {
  color: var(--teal);
  text-decoration: none;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1 {
  font-size: 30px;
  font-weight: 650;
  letter-spacing: -0.8px;
  margin-bottom: 8px;
}
h2 {
  font-size: 21px;
}
h3 {
  font-size: 15px;
}
p {
  color: var(--muted);
  line-height: 1.6;
}
small {
  font-size: 12px;
  color: var(--muted);
}
[hidden] {
  display: none !important;
}
.primary {
  background: var(--teal);
  border-color: var(--teal);
  color: white;
}
.primary:hover {
  background: #086b61;
}
.danger {
  color: #ac3b43;
  border-color: #f2d1d4;
}
.text-button {
  border: 0;
  background: transparent;
}
.icon-button {
  border: 0;
  font-size: 20px;
  padding: 4px 10px;
}
.eyebrow {
  font-size: 10px;
  letter-spacing: 2px;
  font-weight: 750;
  color: var(--teal);
}
.brand-symbol {
  display: inline-grid;
  place-items: center;
  background: #17998a;
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 11px;
  font-size: 27px;
  font-weight: 750;
}
.shell {
  display: flex;
  min-height: 100vh;
}
aside {
  overflow-y: auto;
  width: 242px;
  position: fixed;
  inset: 0 auto 0 0;
  background: var(--navy);
  color: #d9e5ec;
  padding: 32px 18px;
  display: flex;
  flex-direction: column;
  z-index: 10;
}
aside > * {
  flex-shrink: 0;
}
.brand {
  display: flex;
  gap: 11px;
  align-items: center;
  color: white;
  font-size: 21px;
  font-weight: 650;
  margin: 0 10px 45px;
}
.brand small {
  display: block;
  font-size: 8px;
  letter-spacing: 1px;
  margin-top: 6px;
  color: #a0b3c0;
}
.nav-label {
  font-size: 9px;
  letter-spacing: 1.5px;
  color: #8ba1b2;
  margin: 0 14px 16px;
}
nav {
  display: grid;
  gap: 6px;
}
nav a {
  color: #acbfcd;
  padding: 13px 15px;
  border-radius: 7px;
  display: flex;
  align-items: center;
  gap: 13px;
  font-size: 13px;
}
nav a span {
  font-size: 18px;
  width: 20px;
}
nav a.active {
  background: #21464f;
  color: #fff;
  box-shadow: inset 3px 0 #43c0ac;
}
nav a:hover {
  background: #203c4e;
}
.side-bottom {
  margin-top: auto;
  border-top: 1px solid #304758;
  padding: 22px 12px 0;
  font-size: 11px;
  color: #bed1dd;
}
.side-bottom div {
  margin-top: 9px;
  color: #7893a6;
  font-size: 10px;
}
.live-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 100%;
  background: #45c5a9;
  margin-right: 7px;
}
.workspace {
  margin-left: 242px;
  width: calc(100% - 242px);
}
header {
  height: 74px;
  background: white;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 38px;
  font-size: 12px;
  color: #6d7d8d;
}
.header-right {
  display: flex;
  gap: 23px;
  align-items: center;
}
#user-badge {
  color: #35465a;
}
#menu-toggle {
  display: none;
}
main {
  padding: 34px 38px;
  min-height: calc(100vh - 120px);
}
footer {
  display: flex;
  justify-content: space-between;
  margin: 0 38px;
  padding: 20px 0;
  border-top: 1px solid var(--border);
  font-size: 10px;
  color: #8b97a5;
}
.page-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 26px;
}
.page-top p {
  margin: 0;
}
.actions {
  display: flex;
  gap: 9px;
  align-items: center;
  flex-wrap: wrap;
}
.page-top .eyebrow {
  display: block;
  margin-bottom: 12px;
}
.overview-banner {
  background: #e6f1ef;
  border: 1px solid #d2e7e2;
  display: flex;
  align-items: center;
  gap: 14px;
  border-radius: 9px;
  padding: 17px 20px;
  margin-bottom: 24px;
  color: #346258;
  font-size: 12px;
}
.overview-banner strong {
  display: block;
  margin-bottom: 5px;
}
.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 17px;
  margin-bottom: 24px;
}
.metric {
  background: white;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 21px;
}
.metric .label {
  color: #68778a;
  font-size: 12px;
}
.metric strong {
  display: block;
  font-size: 32px;
  font-weight: 650;
  margin: 17px 0 6px;
  letter-spacing: -1px;
}
.metric small {
  font-size: 10px;
}
.metric .metric-icon {
  float: right;
  color: #548f87;
  background: #edf5f3;
  padding: 7px;
  border-radius: 6px;
}
.panel {
  background: white;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 22px;
}
.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 21px 23px;
  border-bottom: 1px solid var(--border);
}
.panel-heading h3 {
  margin: 0;
}
.panel-heading small {
  font-size: 10px;
}
.panel-body {
  padding: 23px;
}
.chart-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.bar-row {
  margin-bottom: 18px;
  font-size: 12px;
}
.bar-row div {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}
progress {
  height: 8px;
  width: 100%;
  appearance: none;
  border: 0;
  border-radius: 8px;
  background: #edf1f5;
}
progress::-webkit-progress-bar {
  background: #edf1f5;
  border-radius: 8px;
}
progress::-webkit-progress-value {
  background: #329d90;
  border-radius: 8px;
}
.empty {
  text-align: center;
  padding: 45px 20px;
  color: #8a97a6;
  font-size: 13px;
  line-height: 1.7;
}
.empty-symbol {
  font-size: 27px;
  margin-bottom: 9px;
  color: #b1bfca;
}
.toolbar {
  display: flex;
  gap: 12px;
  padding: 18px 21px;
  align-items: center;
  border-bottom: 1px solid var(--border);
}
.toolbar input {
  max-width: 340px;
}
.toolbar select {
  width: auto;
  min-width: 180px;
}
.toolbar .count {
  margin-left: auto;
  white-space: nowrap;
  color: var(--muted);
  font-size: 11px;
}
.table-wrap {
  overflow-x: auto;
}
#disposition-records table {
  min-width: 1900px;
}
#disposition-records td:nth-child(3) {
  min-width: 180px;
}
#disposition-records td:nth-child(6) {
  min-width: 220px;
}
#disposition-records td:nth-child(11),
#disposition-records td:nth-child(12) {
  min-width: 150px;
}
#disposition-records th:last-child,
#disposition-records td:last-child {
  position: sticky;
  right: 0;
  background: white;
  box-shadow: -3px 0 6px #132c3c0a;
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  text-align: left;
}
th {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: #718195;
  font-weight: 650;
  background: #fafbfd;
  padding: 15px 20px;
  white-space: nowrap;
}
td {
  padding: 17px 20px;
  border-top: 1px solid #edf0f4;
  vertical-align: middle;
}
td strong {
  font-size: 12px;
}
td small {
  display: block;
  margin-top: 4px;
}
td .actions {
  flex-wrap: nowrap;
}
td button {
  font-size: 11px;
  padding: 7px 10px;
  white-space: nowrap;
}
.badge {
  display: inline-block;
  border-radius: 5px;
  padding: 5px 8px;
  font-size: 10px;
  white-space: nowrap;
  font-weight: 600;
  background: #edf0f5;
  color: #5d6d80;
}
.badge.green {
  background: #e6f4ed;
  color: #218057;
}
.badge.red {
  background: #fbecee;
  color: #b34855;
}
.badge.amber {
  background: #fff3dc;
  color: #a77923;
}
.badge.blue {
  background: #eaf0fc;
  color: #5276b6;
}
label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 12px;
  font-weight: 600;
  color: #4b5d6e;
}
input,
select,
textarea {
  border: 1px solid #dbe2e9;
  border-radius: 6px;
  background: white;
  padding: 10px 12px;
  width: 100%;
  color: #243345;
  min-width: 0;
}
input:focus,
select:focus,
textarea:focus {
  border-color: #258e82;
  outline: 2px solid #def1ec;
}
input[readonly] {
  background: #f3f6f8;
}
textarea {
  min-height: 95px;
  resize: vertical;
}
input[type="checkbox"] {
  width: auto;
}
input[type="file"] {
  font-size: 12px;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.full {
  grid-column: 1/-1;
}
.check {
  flex-direction: row;
  align-items: center;
}
.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 9px;
  margin-top: 26px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}
.error {
  color: #aa3545;
  font-size: 12px;
  line-height: 1.5;
  margin: 12px 0;
}
.note {
  padding: 14px 16px;
  border-radius: 7px;
  background: #f3f6fa;
  font-size: 12px;
  color: #607286;
  line-height: 1.6;
  margin-bottom: 18px;
}
.warning {
  background: #fff5e3;
  color: #916526;
}
.details {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 24px;
}
.details dt {
  font-size: 10px;
  color: #8090a0;
  margin-bottom: 6px;
}
.details dd {
  margin: 0;
  overflow-wrap: anywhere;
  font-size: 13px;
  white-space: pre-wrap;
}
.photos {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 13px 0 22px;
}
.photos button {
  padding: 3px;
}
.photos img {
  width: 85px;
  height: 75px;
  object-fit: cover;
  display: block;
  border-radius: 4px;
}
.photos small {
  display: block;
  max-width: 90px;
  font-size: 9px;
}
.history {
  border-left: 2px solid #dce9e6;
  padding-left: 18px;
  margin: 20px 4px;
}
.history article {
  margin-bottom: 22px;
}
.history p {
  color: #45596a;
  white-space: pre-wrap;
  margin: 8px 0;
}
.history small {
  font-size: 10px;
}
.size-row {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 8px;
  margin-bottom: 8px;
}
dialog {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0;
  width: min(900px, 94vw);
  max-height: 90vh;
  box-shadow: 0 25px 100px #10253944;
}
dialog::backdrop {
  background: #10253988;
  backdrop-filter: blur(3px);
}
.modal-heading {
  padding: 22px 27px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: white;
  z-index: 1;
}
.modal-heading h2 {
  margin: 0;
  font-size: 20px;
}
#modal-content {
  padding: 25px 27px;
}
#photo-modal {
  width: auto;
  max-width: 95vw;
  background: #132a3b;
}
#photo-modal img {
  display: block;
  max-width: 90vw;
  max-height: 80vh;
  object-fit: contain;
}
#photo-close {
  position: absolute;
  right: 5px;
  top: 5px;
  background: white;
}
#toast {
  position: fixed;
  right: 25px;
  bottom: 25px;
  background: #153e36;
  color: white;
  max-width: 420px;
  padding: 15px 22px;
  border-radius: 9px;
  box-shadow: 0 8px 30px #132a3b33;
  z-index: 50;
  font-size: 13px;
}
.login-screen {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 100vh;
}
.settings-tabs {
  display: flex;
  gap: 12px;
  margin-bottom: 22px;
  flex-wrap: wrap;
}
.receipt-item,
.correction-action {
  margin-bottom: 16px;
}
.preserve-text,
.evidence-caption,
.details dd {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.sidebar nav a {
  line-height: 1.4;
}
.login-brand {
  background: #132a3b;
  color: white;
  padding: 70px 65px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.login-brand > span {
  letter-spacing: 2px;
  font-size: 10px;
  margin: 25px 0 85px;
  color: #91b8bb;
}
.login-brand h1 {
  font-size: 45px;
  line-height: 1.18;
  letter-spacing: -1.5px;
}
.login-brand p {
  color: #9bb4c3;
  margin-top: 20px;
  line-height: 1.9;
}
.login-footer {
  margin-top: auto;
  width: 100%;
  max-width: 695px;
  padding-top: 60px;
}
.login-footer img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 6px;
}
.login-panel {
  display: grid;
  place-items: center;
  background: white;
  padding: 45px;
}
.login-panel form {
  width: 100%;
  max-width: 360px;
}
.login-panel h2 {
  font-size: 28px;
  margin-top: 18px;
}
.login-panel label {
  margin-top: 23px;
}
.login-panel button {
  width: 100%;
  margin: 12px 0 25px;
  display: flex;
  justify-content: space-between;
}
.login-panel small {
  display: block;
  text-align: center;
}
/* Login pelo Entra ID: link com a mesma aparência do botão de entrar. */
#login-entra {
  width: 100%;
  max-width: 360px;
}
.login-entra-button {
  width: 100%;
  margin: 12px 0 25px;
  display: flex;
  justify-content: space-between;
  border: 1px solid var(--teal);
  border-radius: 7px;
  padding: 10px 15px;
  text-decoration: none;
}
.login-entra-button:hover,
.login-entra-button:focus-visible {
  color: white;
}
.pagination {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 15px;
  padding: 15px;
  font-size: 12px;
}
pre {
  white-space: pre-wrap;
  word-break: break-word;
  font-size: 11px;
  background: #f4f6f8;
  padding: 14px;
  border-radius: 6px;
}
.section-title {
  margin: 26px 0 14px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}
@media (min-width: 1600px) {
  main {
    max-width: 1550px;
    margin: auto;
  }
}
@media (max-width: 1150px) {
  aside {
    width: 205px;
    padding-left: 10px;
    padding-right: 10px;
  }
  .workspace {
    margin-left: 205px;
    width: calc(100% - 205px);
  }
  main {
    padding: 25px;
  }
  .metrics {
    grid-template-columns: repeat(2, 1fr);
  }
  .chart-grid {
    grid-template-columns: 1fr;
  }
  .page-top {
    align-items: flex-start;
  }
  header {
    padding: 0 25px;
  }
  .brand {
    font-size: 18px;
  }
  .brand small {
    font-size: 7px;
  }
}
@media (max-width: 700px) {
  aside {
    transform: translateX(-100%);
    transition: transform 0.2s;
    width: 242px;
  }
  body.menu-open aside {
    transform: translateX(0);
  }
  .workspace {
    margin: 0;
    width: 100%;
  }
  #menu-toggle {
    display: block;
  }
  header {
    padding: 0 15px;
    gap: 12px;
  }
  .header-right {
    gap: 5px;
    font-size: 10px;
  }
  #breadcrumb {
    display: none;
  }
  main {
    padding: 23px 15px;
  }
  .page-top {
    flex-direction: column;
    gap: 16px;
  }
  h1 {
    font-size: 26px;
  }
  .metrics {
    gap: 10px;
  }
  .metric {
    padding: 15px;
  }
  .metric .metric-icon {
    display: none;
  }
  .metric strong {
    font-size: 27px;
  }
  .form-grid,
  .details {
    grid-template-columns: 1fr;
  }
  .toolbar {
    flex-wrap: wrap;
    padding: 14px;
  }
  .toolbar input,
  .toolbar select {
    max-width: none;
    width: 100%;
  }
  .toolbar .count {
    margin: 0;
  }
  .modal-heading {
    padding: 16px;
  }
  #modal-content {
    padding: 18px;
  }
  footer {
    margin: 0 15px;
  }
  footer span {
    display: none;
  }
  .login-screen {
    grid-template-columns: 1fr;
  }
  .login-brand {
    padding: 25px 30px;
  }
  .login-brand > span,
  .login-brand p {
    display: none;
  }
  .login-footer {
    padding-top: 24px;
  }
  .login-brand h1 {
    font-size: 27px;
    margin: 20px 0 0;
  }
  .login-panel {
    padding: 35px 25px;
  }
  .login-panel h2 {
    font-size: 25px;
  }
}

.return-radio {
  border: 1px solid var(--line, #dce3e8);
  border-radius: 10px;
  padding: 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}
.return-radio label {
  display: flex;
  align-items: center;
  gap: 8px;
}
.return-radio input,
input[type="checkbox"] {
  width: auto;
}
.return-evidence {
  margin: 16px 0;
  padding: 12px;
  border: 1px solid #dce3e8;
  border-radius: 8px;
}
.preserve-lines {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.notice {
  padding: 14px 18px;
  border: 1px solid #dfd3ac;
  border-radius: 10px;
  background: #fff9e9;
  color: #635020;
  line-height: 1.5;
}

.return-sizes { display: grid; grid-template-columns: repeat(auto-fit,minmax(68px,1fr)); gap: 8px; }
.return-check { display: flex; align-items: center; gap: 8px; }
[data-model-key][hidden] { display: none; }
.receipt-search {
  margin: 16px 0 4px;
}
.receipt-search label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
}
.receipt-search-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.receipt-search-row input {
  flex: 1;
  min-width: 200px;
}
.receipt-search-row select {
  width: auto;
  flex: 0 0 auto;
}
.receipt-search-row span {
  color: var(--muted);
  font-size: 13px;
  white-space: nowrap;
}
#rework-sheet-result {
  margin-bottom: 16px;
}
