:root {
  font-family:'DM Sans',Arial,sans-serif;
  color:#202923;
  background:#f6f7f4;
  font-synthesis:none;
  text-rendering:optimizeLegibility;
  --green:#315b43;
  --muted:#7d867f;
  --line:#e8ebe6
}
* {
  box-sizing:border-box
}
body {
  margin:0;
  min-height:100vh
}
button,input,select {
  font:inherit
}
.hidden {
  display:none!important
}
.app-shell {
  min-height:100vh
}
.sidebar {
  position:fixed;
  inset:0 auto 0 0;
  width:248px;
  background:#172821;
  color:#f5f7f2;
  padding:28px 19px 16px;
  display:flex;
  flex-direction:column;
  z-index:2
}
.brand {
  display:flex;
  align-items:center;
  gap:11px;
  padding:0 5px 35px;
  color:inherit;
  text-decoration:none;
  font-family:Manrope,sans-serif
}
.brand-mark {
  width:40px;
  height:40px;
  border-radius:13px;
  background:#d8e8bd;
  color:#244331;
  display:grid;
  place-items:center;
  font-weight:800;
  font-size:14px
}
.brand strong,.brand small {
  display:block
}
.brand strong {
  font-size:15px;
  letter-spacing:-.3px
}
.brand small {
  font-size:9px;
  letter-spacing:2px;
  color:#a9b8ad;
  margin-top:2px
}
.nav-label,.eyebrow {
  font-size:10px;
  letter-spacing:1.25px;
  font-weight:700;
  color:#909d91
}
.nav-label {
  padding:0 10px;
  margin:0 0 12px
}
.sidebar nav {
  display:grid;
  gap:5px
}
.nav-link {
  color:#b7c1b9;
  text-decoration:none;
  font-size:13px;
  padding:12px 11px;
  border-radius:8px;
  display:flex;
  gap:12px;
  align-items:center
}
.nav-link span {
  font-size:17px;
  width:20px;
  text-align:center
}
.nav-link.active,.nav-link:hover {
  background:#2b4034;
  color:white
}
.sidebar-bottom {
  margin-top:auto
}
.side-tip {
  background:#21372b;
  border:1px solid #31483a;
  border-radius:10px;
  padding:14px;
  margin-bottom:20px
}
.side-tip>span {
  color:#d8e8bd;
  font-size:17px
}
.side-tip strong {
  display:block;
  font-size:12px;
  margin-top:8px
}
.side-tip p {
  font-size:11px;
  line-height:1.6;
  color:#adbaaf;
  margin:7px 0 0
}
.user {
  border-top:1px solid #35433a;
  padding:15px 4px 0;
  display:flex;
  align-items:center;
  gap:10px
}
.avatar {
  width:32px;
  height:32px;
  display:grid;
  place-items:center;
  background:#3d5846;
  border-radius:50%;
  font-size:10px
}
.user strong,.user small {
  display:block
}
.user strong {
  font-size:11px
}
.user small {
  font-size:10px;
  color:#a1ada4;
  margin-top:3px
}
.logout {
  margin-left:auto;
  border:1px solid #46584b;
  color:#e2e9e2;
  background:transparent;
  border-radius:6px;
  padding:6px 9px;
  cursor:pointer;
  font-size:11px
}
.logout:hover {
  background:#2b4034
}
.main {
  max-width:1500px;
  margin-left:248px;
  padding:40px 48px 22px
}
.topbar {
  display:flex;
  justify-content:space-between;
  align-items:center;
  margin-bottom:27px
}
.eyebrow {
  margin:0 0 8px;
  color:#879087
}
.topbar h1,.modal-head h2 {
  font-family:Manrope,sans-serif;
  letter-spacing:-1px;
  margin:0;
  font-size:27px
}
.subtitle,.section-head p {
  color:var(--muted);
  font-size:12px;
  margin:6px 0 0
}
.button {
  min-height:39px;
  border-radius:7px;
  padding:0 14px;
  font-size:12px;
  font-weight:600;
  cursor:pointer;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:7px;
  transition:.15s
}
.button-primary {
  background:var(--green);
  color:white;
  border:1px solid var(--green)
}
.button-primary:hover {
  background:#244832
}
.button-primary span {
  font-size:17px
}
.button-outline {
  background:#fff;
  border:1px solid #dfe4dd;
  color:#39443c
}
.button-outline:hover {
  background:#f5f7f3
}
.stats {
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:14px;
  margin-bottom:24px
}
.stat-card,.content-card {
  background:#fff;
  border:1px solid #eaede8;
  border-radius:10px
}
.stat-card {
  padding:16px 17px 14px;
  min-height:125px
}
.stat-heading {
  display:flex;
  align-items:center;
  justify-content:space-between;
  font-size:11px;
  color:#737d75
}
.stat-icon {
  width:27px;
  height:27px;
  border-radius:7px;
  display:grid;
  place-items:center;
  font-size:12px;
  font-weight:700
}
.green {
  background:#e8f2e9;
  color:#458153
}
.yellow {
  background:#fff3dc;
  color:#bd8727
}
.red {
  background:#fae9e7;
  color:#c25e55
}
.blue {
  background:#e7eff7;
  color:#6387a8
}
.stat-card>strong {
  display:block;
  font:700 25px Manrope,sans-serif;
  letter-spacing:-.6px;
  margin:8px 0 3px
}
.stat-card>small {
  font-size:10px;
  color:#919992
}
.content-card {
  padding:20px 20px 0;
  margin-bottom:18px
}
.section-head {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px
}
.section-head h2 {
  font:700 15px Manrope,sans-serif;
  letter-spacing:-.25px;
  margin:0
}
.section-head p {
  font-size:11px
}
.toolbar {
  display:flex;
  gap:9px;
  margin:20px 0 13px
}
.search {
  height:36px;
  border:1px solid #e1e5df;
  border-radius:7px;
  display:flex;
  align-items:center;
  padding:0 10px;
  gap:7px;
  flex:1;
  max-width:340px;
  color:#89938a
}
.search span {
  font-size:20px
}
.search input {
  border:0;
  outline:0;
  font-size:11px;
  width:100%;
  background:transparent
}
.toolbar select {
  font-size:11px;
  color:#505b52;
  border:1px solid #e1e5df;
  border-radius:7px;
  background:#fff;
  padding:0 11px;
  height:36px;
  outline-color:#6d8a72;
  min-width:144px
}
.table-wrap {
  overflow:auto
}
table {
  width:100%;
  border-collapse:collapse;
  min-width:790px
}
th {
  text-align:left;
  font-size:9px;
  letter-spacing:.6px;
  color:#8c958d;
  font-weight:700;
  padding:11px 10px;
  border-bottom:1px solid #e9ece8
}
td {
  padding:12px 10px;
  border-bottom:1px solid #eff1ee;
  font-size:11px;
  color:#556057
}
tbody tr:last-child td {
  border-bottom:0
}
.product-cell {
  display:flex;
  align-items:center;
  gap:9px;
  min-width:155px
}
.product-thumb {
  width:30px;
  height:30px;
  border-radius:7px;
  background:#f5eee7;
  display:grid;
  place-items:center;
  font-size:15px
}
.product-name {
  font-weight:600;
  color:#303a33
}
.product-detail {
  display:block;
  font-size:9px;
  color:#949c95;
  margin-top:3px
}
.qty {
  font-weight:600;
  color:#313d34
}
.badge {
  display:inline-flex;
  align-items:center;
  border-radius:20px;
  padding:5px 8px;
  font-size:9px;
  font-weight:600;
  white-space:nowrap
}
.badge.ok {
  background:#edf5ed;
  color:#4d8056
}
.badge.low {
  background:#fbefeb;
  color:#bb6252
}
.badge.soon {
  background:#fff3dd;
  color:#ac7a24
}
.action-cell {
  white-space:nowrap;
  text-align:right
}
.icon-button {
  border:0;
  background:transparent;
  color:#78837a;
  font-size:16px;
  padding:5px;
  cursor:pointer;
  border-radius:5px
}
.icon-button:hover {
  color:#315b43;
  background:#eef3ed
}
.empty {
  text-align:center;
  padding:35px 10px;
  color:#89938a
}
.empty span {
  font-size:23px
}
.empty strong {
  display:block;
  margin-top:7px;
  font-size:12px;
  color:#414c44
}
.empty p {
  font-size:11px;
  margin:5px
}
.table-foot {
  border-top:1px solid #eff1ee;
  padding:12px 2px;
  display:flex;
  justify-content:space-between;
  color:#909991;
  font-size:10px
}
.movements-card {
  padding-bottom:5px
}
.movement-list {
  margin-top:14px
}
.movement {
  display:flex;
  align-items:center;
  gap:11px;
  padding:11px 0;
  border-top:1px solid #eff1ee
}
.move-icon {
  width:31px;
  height:31px;
  display:grid;
  place-items:center;
  border-radius:8px;
  font-size:14px
}
.move-icon.entrada {
  color:#4d8056;
  background:#edf5ed
}
.move-icon.saida {
  color:#bb6252;
  background:#fbefeb
}
.move-main {
  flex:1
}
.move-main strong {
  display:block;
  font-size:11px;
  color:#39443c
}
.move-main small,.move-date {
  font-size:10px;
  color:#8b958d
}
.move-amount {
  font-size:11px;
  font-weight:700
}
.move-amount.entrada {
  color:#4d8056
}
.move-amount.saida {
  color:#bb6252
}
footer {
  display:flex;
  justify-content:space-between;
  padding:7px 1px;
  color:#929a93;
  font-size:10px
}
dialog {
  border:0;
  border-radius:12px;
  padding:0;
  width:min(500px,calc(100% - 30px));
  max-height:calc(100% - 30px);
  overflow:auto;
  box-shadow:0 22px 80px #15271d38
}
dialog::backdrop {
  background:#17282178;
  backdrop-filter:blur(2px)
}
dialog form {
  padding:23px
}
.modal-head {
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  margin-bottom:20px
}
.modal-head h2 {
  font-size:21px
}
.modal-head .eyebrow {
  font-size:9px
}
.close-button {
  border:0;
  background:#f2f4f1;
  border-radius:50%;
  width:29px;
  height:29px;
  font-size:20px;
  color:#6d786f;
  cursor:pointer
}
.form-grid {
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:13px;
  margin-bottom:13px
}
.form-grid label,dialog form>label {
  display:block;
  color:#59645b;
  font-size:10px;
  font-weight:600
}
dialog form>label {
  margin-bottom:13px
}
.form-grid label input,.form-grid label select,dialog form>label input,dialog form>label select {
  display:block;
  width:100%;
  margin-top:6px;
  height:37px;
  border:1px solid #dfe4dd;
  border-radius:7px;
  padding:0 10px;
  font-size:11px;
  color:#37423a;
  background:#fff;
  outline-color:#6d8a72
}
.form-grid .wide {
  grid-column:1/-1
}
.modal-actions {
  display:flex;
  justify-content:flex-end;
  gap:8px;
  border-top:1px solid #edf0ec;
  padding-top:15px;
  margin-top:16px
}
.form-error {
  color:#ad5148;
  font-size:11px;
  margin:8px 0
}
.toast {
  position:fixed;
  right:24px;
  bottom:24px;
  background:#203b2b;
  color:white;
  border-radius:8px;
  padding:12px 17px;
  font-size:12px;
  box-shadow:0 8px 30px #17282130;
  opacity:0;
  transform:translateY(8px);
  transition:.2s;
  pointer-events:none;
  z-index:5
}
.toast.show {
  opacity:1;
  transform:translateY(0)
}
.auth-screen {
  min-height:100vh;
  display:grid;
  place-items:center;
  padding:24px;
  background:radial-gradient(ellipse at 15% 15%,#e6efdf 0,transparent 40%),#f3f5f1
}
.auth-card {
  width:min(430px,100%);
  background:#fff;
  border:1px solid #eaede8;
  border-radius:16px;
  padding:30px;
  box-shadow:0 18px 55px #203b2b12
}
.auth-brand {
  display:flex;
  align-items:center;
  gap:11px;
  margin-bottom:27px;
  color:#202923
}
.auth-card h1 {
  font:700 25px Manrope,sans-serif;
  letter-spacing:-.8px;
  margin:0
}
.auth-card>p {
  color:#737d75;
  font-size:13px;
  line-height:1.6;
  margin:8px 0 22px
}
.auth-card form>label {
  display:block;
  font-size:11px;
  font-weight:600;
  color:#59645b;
  margin:14px 0
}
.auth-card input {
  display:block;
  width:100%;
  height:42px;
  border:1px solid #dfe4dd;
  border-radius:8px;
  padding:0 12px;
  margin-top:7px;
  font-size:13px
}
.auth-card .button {
  width:100%;
  height:43px;
  margin-top:9px
}
.auth-error {
  background:#fbefeb;
  color:#9d453c;
  border-radius:7px;
  padding:10px;
  font-size:12px;
  margin:12px 0
}
.auth-help {
  font-size:11px!important;
  color:#858d86!important;
  margin:18px 0 0!important
}
.loading {
  color:#657168;
  font-size:14px
}
@media(max-width:1050px) {
  .sidebar {
    width:210px
  }
  .main {
    margin-left:210px;
    padding:32px 26px
  }
  .stats {
    grid-template-columns:repeat(2,minmax(0,1fr))
  }
}
@media(max-width:680px) {
  .sidebar {
    position:static;
    width:auto;
    height:auto;
    padding:12px 16px;
    flex-direction:row;
    align-items:center
  }
  .brand {
    padding:0
  }
  .brand-mark {
    width:34px;
    height:34px
  }
  .sidebar .nav-label,.sidebar-bottom {
    display:none
  }
  .sidebar nav {
    display:flex;
    margin-left:auto
  }
  .nav-link {
    padding:9px;
    font-size:0;
    gap:0
  }
  .nav-link span {
    font-size:16px
  }
  .main {
    margin:0;
    padding:24px 15px
  }
  .topbar {
    align-items:flex-start;
    gap:10px
  }
  .topbar h1 {
    font-size:22px
  }
  .topbar .button {
    font-size:0;
    padding:0 11px;
    min-width:40px
  }
  .topbar .button span {
    font-size:20px
  }
  .stats {
    gap:9px
  }
  .stat-card {
    padding:12px;
    min-height:112px
  }
  .stat-heading {
    font-size:10px;
    gap:4px
  }
  .stat-card>strong {
    font-size:22px
  }
  .content-card {
    padding:16px 13px 0
  }
  .toolbar {
    flex-wrap:wrap
  }
  .search {
    max-width:none;
    flex-basis:100%
  }
  .toolbar select {
    flex:1;
    min-width:0
  }
  .section-head h2 {
    font-size:14px
  }
  .section-head p {
    max-width:220px;
    line-height:1.5
  }
  .button-outline {
    padding:0 10px
  }
  .table-foot span:last-child {
    display:none
  }
  footer {
    font-size:9px
  }
  .form-grid {
    gap:10px
  }
  .movement {
    gap:7px
  }
  .move-date {
    display:none
  }
  .auth-card {
    padding:23px
  }
}
/* Navegação entre as páginas do aplicativo */
.sidebar nav {
  margin-top: 4px;
}
.nav-link {
  width: 100%;
  border: 0;
  background: transparent;
  font-family: inherit;
  text-align: left;
  cursor: pointer;
}
.page {
  display: block;
}
/* Página de resumo */
.summary-stats {
  margin-bottom: 18px;
}
.summary-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 16px;
  margin-bottom: 18px;
}
.summary-card {
  margin-bottom: 0;
  padding-bottom: 18px;
}
.unit-totals {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 18px;
}
.unit-total {
  min-width: 0;
  padding: 13px;
  border: 1px solid #edf0ec;
  border-radius: 9px;
  background: #fafbf9;
}
.unit-total > span {
  display: block;
  color: var(--muted);
  font-size: 10px;
}
.unit-total strong {
  display: block;
  margin-top: 7px;
  color: #26342a;
  font: 700 19px Manrope, sans-serif;
  overflow-wrap: anywhere;
}
.unit-total small {
  color: var(--muted);
  font: 500 11px 'DM Sans', Arial, sans-serif;
}
.attention-list {
  max-height: 215px;
  overflow: auto;
  margin-top: 10px;
}
.attention-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 0;
  border-top: 1px solid #eff1ee;
}
.attention-item > div {
  min-width: 0;
}
.attention-item strong,
.attention-item small {
  display: block;
}
.attention-item strong {
  overflow: hidden;
  color: #39443c;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.attention-item small {
  margin-top: 4px;
  color: #8b958d;
  font-size: 10px;
}
.badge.expired {
  background: #f7e3e2;
  color: #a7423d;
}
.empty.compact {
  padding: 24px 8px 8px;
}
.summary-table {
  min-width: 700px;
}
.category-name {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-weight: 600;
  color: #39443c;
}
.total-row th {
  padding: 12px 10px;
  border-top: 1px solid #e4e9e2;
  color: #303a33;
  text-align: left;
  font-size: 10px;
}
@media (max-width: 1050px) {
  .summary-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 680px) {
  .unit-total {
    padding: 10px 8px;
  }
  .unit-total strong {
    font-size: 16px;
  }
  .attention-item {
    align-items: flex-start;
  }
  .attention-item .badge {
    font-size: 8px;
  }
  .sidebar nav {
    gap: 2px;
  }
  .nav-link {
    justify-content: center;
  }
  .summary-table {
    min-width: 650px;
  }
}
/* Navegação dedicada por função */
.sidebar nav {
  margin-top: 4px;
}
.nav-link {
  width: 100%;
  border: 0;
  background: transparent;
  font-family: inherit;
  text-align: left;
  cursor: pointer;
}
.nav-link.active {
  background: #2b4034;
  color: #fff;
}
.nav-link:hover {
  background: #2b4034;
  color: #fff;
}
.form-card {
  padding-bottom: 22px;
}
.form-card form {
  margin-top: 22px;
}
.form-card .form-grid {
  max-width: 820px;
}
.form-grid .wide {
  grid-column: 1 / -1;
}
.form-actions {
  display: flex;
  gap: 9px;
  padding-top: 16px;
  border-top: 1px solid #edf0ec;
}
.stock-hint {
  padding: 11px 13px;
  color: #58685b;
  background: #f2f6ef;
  border-radius: 7px;
  font-size: 11px;
}
.icon-button {
  font-size: 11px;
}
.operation-pill {
  display: inline-flex;
  align-items: center;
  padding: 5px 9px;
  border-radius: 20px;
  background: #edf5ed;
  color: #4d8056;
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}
.operation-pill.venda {
  background: #e7eff7;
  color: #52789b;
}
.operation-pill.saida,
.operation-pill.ajuste {
  background: #fbefeb;
  color: #bb6252;
}
.badge.expired {
  background: #f7e3e2;
  color: #a7423d;
}
.report-head,
.history-head {
  align-items: flex-start;
}
.month-field,
.history-filter {
  display: grid;
  gap: 6px;
  color: #59645b;
  font-size: 10px;
  font-weight: 700;
}
.month-field input,
.history-filter select {
  min-height: 37px;
  padding: 0 10px;
  color: #37423a;
  background: white;
  border: 1px solid #dfe4dd;
  border-radius: 7px;
  font-size: 12px;
}
.report-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 22px 0 28px;
}
.report-total {
  min-width: 0;
  padding: 17px;
  border: 1px solid #e9ede7;
  border-radius: 9px;
  background: #fafbf9;
}
.report-total > span,
.report-total > small {
  display: block;
  color: #778179;
  font-size: 11px;
}
.report-total strong {
  display: block;
  margin: 11px 0 7px;
  color: #253329;
  font: 700 18px Manrope, sans-serif;
  overflow-wrap: anywhere;
}
.report-total.incoming {
  border-top: 3px solid #5c9166;
}
.report-total.sold {
  border-top: 3px solid #6387a8;
}
.report-total.other {
  border-top: 3px solid #c57562;
}
.report-table {
  min-width: 620px;
}
.report-table-heading {
  margin-bottom: 14px;
}
.history-product-card {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 20px 0;
  padding: 15px;
  border: 1px solid #e9ede7;
  border-radius: 9px;
  background: #fafbf9;
}
.history-product-card > div span,
.history-product-card > div strong {
  display: block;
}
.history-product-card > div span {
  color: #858e87;
  font-size: 10px;
}
.history-product-card > div strong {
  margin-top: 5px;
  color: #344037;
  font-size: 12px;
}
.history-product-card + .table-wrap {
  margin-top: 18px;
}
@media (max-width: 1050px) {
  .sidebar nav {
    gap: 3px;
  }
  .nav-link {
    padding-left: 9px;
    padding-right: 9px;
  }
}
@media (max-width: 680px) {
  .report-summary {
    grid-template-columns: 1fr;
  }
  .report-total {
    padding: 13px;
  }
  .report-total strong {
    margin: 6px 0;
    font-size: 16px;
  }
  .history-product-card {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .report-head,
  .history-head {
    flex-direction: column;
  }
  .month-field,
  .history-filter {
    width: 100%;
  }
  .month-field input,
  .history-filter select {
    width: 100%;
  }
}

