@import url("https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700;800&family=Manrope:wght@400;500;600;700;800&display=swap");

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

:root {
  --dark: #142333;
  --ink: #182b3d;
  --green: #087f8c;
  --mint: #28c7ad;
  --bg: #f2f5f8;
  --line: #dfe7ed;
  --muted: #718092;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "DM Sans", system-ui, sans-serif;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

button:disabled {
  opacity: 0.6;
  cursor: wait;
}

[hidden] {
  display: none !important;
}

.accent {
  color: var(--mint);
}

.logo-mark {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: linear-gradient(145deg, #29c68b, #087a55);
  color: #fff;
  font-size: 25px;
  flex-shrink: 0;
}

.eyebrow {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 2px;
  color: var(--green);
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

.login-screen {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 52% 48%;
  background: #fff;
  animation: appear 0.5s ease;
}

.login-art {
  background: radial-gradient(circle at 80% 70%, #236d54, #102d27 55%, #091d1a);
  color: #fff;
  padding: 55px clamp(30px, 6vw, 100px);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.login-art:after {
  content: "";
  position: absolute;
  width: 480px;
  height: 480px;
  border: 1px solid #ffffff18;
  border-radius: 50%;
  right: -190px;
  top: 24%;
  box-shadow:
    0 0 0 80px #ffffff06,
    0 0 0 160px #ffffff05;
  pointer-events: none;
}

.art-top {
  font-weight: 800;
  letter-spacing: 1.5px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.art-content {
  margin: auto 0;
  position: relative;
  z-index: 1;
}

.tag,
.welcome-tag {
  display: inline-block;
  background: #ffffff17;
  border: 1px solid #ffffff27;
  padding: 9px 13px;
  border-radius: 30px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.2px;
}

.art-content h2 {
  font-family: Manrope, sans-serif;
  font-size: clamp(38px, 4vw, 66px);
  line-height: 1.14;
  letter-spacing: -2px;
  margin: 25px 0;
}

.art-content h2 em {
  font-style: normal;
  color: #55dfad;
}

.art-content p {
  max-width: 440px;
  color: #bdd2c9;
  line-height: 1.8;
}

.art-tiles {
  display: flex;
  gap: 15px;
  margin-top: 50px;
}

.art-tiles > div {
  border: 1px solid #ffffff25;
  border-radius: 16px;
  padding: 18px 24px;
  min-width: 150px;
  background: #ffffff0c;
}

.art-tiles b {
  font-size: 24px;
  display: block;
  color: #64dfb1;
}

.art-tiles small {
  color: #b5cfc4;
}

.art-foot {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: #8fb6a6;
  letter-spacing: 1px;
}

.login-side {
  display: grid;
  place-items: center;
  padding: 36px;
}

.login-card {
  width: min(430px, 100%);
}

.mobile-brand {
  display: none;
}

.login-card h1 {
  font-family: Manrope, sans-serif;
  font-size: clamp(30px, 3vw, 42px);
  letter-spacing: -1.5px;
  margin: 15px 0;
}

.sub {
  color: #87958f;
  margin-bottom: 40px;
}
.login-environment {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 13px;
  margin: -18px 0 25px;
  padding: 12px 15px;
  border: 1px solid #dce7e2;
  border-radius: 13px;
  background: #f8fbf9;
}
.environment-choice {
  color: #84948e;
  font-size: 12px;
  font-weight: 700;
  transition: color 0.2s ease;
}
.environment-choice.selected {
  color: #18332e;
}
.environment-toggle {
  display: inline-flex;
  align-items: center;
  width: 48px;
  height: 27px;
  padding: 3px;
  border: 0;
  border-radius: 99px;
  background: #168a60;
  transition: background 0.2s ease;
}
.environment-toggle > span {
  width: 21px;
  height: 21px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 4px #09251b40;
  transition: transform 0.2s ease;
}
.environment-toggle[aria-checked="true"] {
  background: #147e59;
}
.environment-toggle[aria-checked="true"] > span {
  transform: translateX(21px);
}
.environment-toggle:focus-visible {
  outline: 3px solid #22c78b55;
  outline-offset: 3px;
}
.environment-toggle:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.login-card form,
.form {
  display: grid;
  gap: 20px;
}

.login-card label,
.form label {
  display: grid;
  gap: 9px;
  font-size: 13px;
  font-weight: 700;
}

.login-card input,
.form input,
.form select,
.toolbar input,
.toolbar select {
  width: 100%;
  padding: 15px 16px;
  border: 1px solid #dce7e2;
  border-radius: 11px;
  background: #fff;
  color: #233e35;
  outline: none;
}

.password-input-wrap {
  position: relative;
  display: block;
  width: 100%;
}

.password-input-wrap input {
  padding-right: 82px !important;
}

.password-visibility-toggle {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  padding: 6px 4px;
  border: 0;
  background: transparent;
  color: #168a60;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.password-visibility-toggle:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 2px;
  border-radius: 4px;
}

.login-card input:focus,
.form input:focus,
.form select:focus,
.toolbar input:focus {
  border-color: #23ad7d;
  box-shadow: 0 0 0 3px #1aaa7915;
}

.primary {
  border: 0;
  background: #168a60;
  color: #fff;
  border-radius: 11px;
  padding: 15px 20px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.primary:hover {
  background: #0e7450;
}

.wide {
  width: 100%;
}

.feedback {
  color: #c34839;
  min-height: 24px;
  margin: 16px 0;
}

.secure-note {
  text-align: center;
  border-top: 1px solid var(--line);
  padding-top: 25px;
  color: #9ca9a4;
  font-size: 12px;
}

.shell {
  min-height: 100vh;
  display: flex;
  animation: dashboardEnter 0.65s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.sidebar {
  width: 264px;
  background: #102d27;
  color: #fff;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 30px 18px;
  flex-shrink: 0;
}

.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 0 12px;
  font-size: 18px;
  font-weight: 800;
  white-space: nowrap;
}

.brand small {
  display: block;
  color: #82aa99;
  font-size: 9px;
  letter-spacing: 1.6px;
  margin-top: 3px;
}

.nav-label {
  font-size: 10px;
  letter-spacing: 1.8px;
  font-weight: 800;
  color: #72998a;
  margin: 46px 15px 14px;
}

.nav-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 14px 16px;
  background: none;
  color: #b5cfc3;
  border: 0;
  border-radius: 10px;
  text-align: left;
  font-weight: 600;
  margin-bottom: 5px;
  transition: 0.2s;
}

a.nav-btn {
  text-decoration: none;
  cursor: pointer;
}

.nav-btn > span:first-child {
  font-size: 20px;
  width: 24px;
  text-align: center;
}

.nav-btn.active,
.nav-btn:hover {
  background: #1e4a3c;
  color: #fff;
}

.soon {
  font-size: 8px;
  letter-spacing: 0.4px;
  background: #265a49;
  border-radius: 4px;
  padding: 4px 5px;
  margin-left: auto;
}

.side-bottom {
  margin-top: auto;
  border-top: 1px solid #ffffff20;
  padding: 22px 6px 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.avatar,
.top-avatar {
  background: #dbf4e7;
  color: #137953;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-weight: 800;
}

.account {
  min-width: 0;
  flex: 1;
}

.account b,
.account small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account b {
  font-size: 13px;
}

.account small {
  font-size: 10px;
  color: #86ac9b;
  margin-top: 3px;
}

.logout {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 0;
  background: #ffffff12;
  color: #fff;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 700;
  padding: 9px 11px;
  white-space: nowrap;
}
.topbar .logout {
  min-height: 40px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  background: #f1f6f3;
  color: #315044;
  flex-shrink: 0;
}
.topbar .logout:hover {
  background: #e4efe9;
}

.logout span {
  font-size: 18px;
}

.remember-login {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: -2px 0 18px;
  color: var(--muted);
  font-size: 12px;
  cursor: pointer;
}

.remember-login input {
  width: 16px !important;
  height: 16px;
  margin: 0;
  padding: 0 !important;
  border: 0;
  background: transparent;
  accent-color: #15966a;
}

.main-wrap {
  min-width: 0;
  flex: 1;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  height: 82px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 clamp(22px, 3vw, 55px);
}

.breadcrumb {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1.2px;
  color: #9ca9a3;
}

.breadcrumb span {
  margin: 0 12px;
  color: #c2ccc7;
}

.breadcrumb strong {
  color: #304d40;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 22px;
}

.connected {
  color: #168a60;
  font-size: 12px;
  font-weight: 700;
}

.connected i {
  display: inline-block;
  width: 7px;
  height: 7px;
  background: #18b97d;
  border-radius: 50%;
  margin-right: 6px;
}

.top-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 11px;
}

.main {
  max-width: 1650px;
  margin: auto;
  padding: 40px clamp(22px, 3vw, 55px);
}

.page {
  display: none;
  animation: pageEnter 0.35s ease both;
}

.page.active {
  display: block;
}

.page-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 28px;
}

.page-head h1 {
  font:
    800 clamp(29px, 3vw, 39px) Manrope,
    sans-serif;
  letter-spacing: -1.5px;
  margin: 8px 0;
}

.page-head p {
  color: var(--muted);
  margin: 0;
  font-size: 14px;
}

.secondary {
  background: #fff;
  border: 1px solid var(--line);
  padding: 13px 18px;
  border-radius: 10px;
  color: #2a5444;
  font-weight: 800;
}

.secondary:hover {
  background: #eaf6ef;
}

.welcome {
  background: linear-gradient(105deg, #123e30, #176b4b);
  border-radius: 20px;
  padding: 32px 38px;
  color: #fff;
  display: flex;
  justify-content: space-between;
  overflow: hidden;
  position: relative;
  margin-bottom: 23px;
}

.welcome-tag {
  background: #ffffff18;
  color: #c7f6e2;
}

.welcome h2 {
  font:
    800 27px Manrope,
    sans-serif;
  margin: 15px 0 10px;
}

.welcome p {
  font-size: 13px;
  color: #b8e0cf;
  max-width: 520px;
  line-height: 1.7;
  margin: 0;
}

.welcome-graphic {
  position: relative;
  min-width: 160px;
  display: grid;
  place-items: center;
}

.welcome-graphic > span {
  font-size: 65px;
  color: #71edb5;
  z-index: 1;
}

.orbit {
  position: absolute;
  width: 200px;
  height: 200px;
  border: 1px solid #ffffff22;
  border-radius: 50%;
  box-shadow:
    0 0 0 35px #ffffff07,
    0 0 0 70px #ffffff06;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 17px;
  margin-bottom: 23px;
}

.stat,
.panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 17px;
  box-shadow: 0 5px 25px #173d2c07;
}

.stat {
  padding: 23px;
  min-width: 0;
}

.stat-icon {
  display: grid;
  place-items: center;
  width: 39px;
  height: 39px;
  background: #e1f6ec;
  color: #138c60;
  border-radius: 11px;
  font-size: 21px;
  font-weight: 800;
  margin-bottom: 19px;
}

.stat-icon.amber {
  background: #fff2df;
  color: #c28b35;
}

.stat-icon.blue {
  background: #e5f1fc;
  color: #3778be;
}

.stat-icon.violet {
  background: #efe9ff;
  color: #7658b6;
  font-size: 13px;
}

.stat small,
.stat span {
  display: block;
  color: #889a91;
  font-size: 12px;
}

.stat strong {
  display: block;
  font:
    800 clamp(22px, 2.1vw, 32px) Manrope,
    sans-serif;
  letter-spacing: -1px;
  margin: 9px 0;
  overflow-wrap: anywhere;
}

.overview-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.panel {
  padding: 26px;
  margin-bottom: 22px;
}

.panel-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 22px;
}

.panel h3 {
  font:
    800 17px Manrope,
    sans-serif;
  margin-bottom: 5px;
}

.panel-heading p {
  font-size: 12px;
  color: #94a29c;
  margin: 0;
}

.soft-pill {
  background: #edf8f2;
  color: #16895f;
  font-size: 10px;
  font-weight: 800;
  padding: 7px 11px;
  border-radius: 20px;
  white-space: nowrap;
}

.health {
  display: flex;
  align-items: center;
  gap: 35px;
  padding: 8px 0;
}

.donut {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  background: conic-gradient(#18a675 0%, #f1b45a 0);
}

.donut > div {
  background: #fff;
  width: 126px;
  height: 126px;
  border-radius: 50%;
  display: grid;
  align-content: center;
  text-align: center;
}

.donut strong {
  font:
    800 28px Manrope,
    sans-serif;
}

.donut small {
  color: #98a59f;
  font-size: 11px;
}

.legend {
  flex: 1;
  min-width: 0;
}

.legend > div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-size: 12px;
}

.legend > div > span {
  color: #84968c;
}

.dot {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  margin-right: 6px;
}

.green {
  background: #18a675;
}

.orange {
  background: #f1b45a;
}

.critical-list {
  display: grid;
  gap: 12px;
}

.critical-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  background: #f9fbfa;
  border: 1px solid #edf1ee;
  border-radius: 11px;
}

.critical-item b {
  font-size: 13px;
}

.critical-item small {
  display: block;
  font-size: 11px;
  color: #97a39d;
  margin-top: 4px;
}

.critical-item strong {
  color: #c68c36;
  font-size: 12px;
  white-space: nowrap;
}

.empty {
  color: #8c9e94;
  text-align: center;
  padding: 30px 12px;
  font-size: 13px;
}

.text-btn {
  border: 0;
  background: none;
  color: #12875d;
  font-weight: 800;
  font-size: 12px;
}

.toolbar {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 22px;
}

.search {
  display: flex;
  align-items: center;
  gap: 9px;
  background: #fff;
  border: 1px solid #dce7e2;
  border-radius: 10px;
  padding-left: 14px;
  width: min(420px, 100%);
  color: #95a39c;
}

.search input {
  border: 0;
  box-shadow: none !important;
}

.toolbar select {
  width: auto;
  min-width: 190px;
}

.table-scroll {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  min-width: 630px;
}

th {
  font-size: 10px;
  letter-spacing: 1px;
  color: #93a39b;
  background: #f8faf9;
}

td,
th {
  padding: 16px;
  border-bottom: 1px solid #edf1ee;
}

td {
  font-size: 13px;
}

td:first-child {
  font-weight: 700;
}

.status-pill {
  display: inline-block;
  border-radius: 20px;
  padding: 6px 10px;
  background: #e3f6ec;
  color: #118354;
  font-size: 11px;
  font-weight: 800;
}

.status-pill.low {
  background: #fff2df;
  color: #aa7b2d;
}

.table-footer {
  font-size: 11px;
  color: #9da9a3;
  padding-top: 20px;
}

.two-col {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 20px;
}

.form {
  margin-top: 20px;
}

.fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}

.info-panel {
  border-radius: 17px;
  background: #143d31;
  color: #fff;
  padding: 35px;
  align-self: start;
}

.info-icon {
  font-size: 34px;
  color: #78dcb0;
}

.info-panel h3 {
  font-size: 23px;
  margin: 24px 0 12px;
}

.info-panel p {
  font-size: 13px;
  color: #b7d5c7;
  line-height: 1.8;
}

.info-rule {
  font-size: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #ffffff1a;
  color: #c6e7d6;
}

.ai-placeholder {
  background: linear-gradient(140deg, #123b30, #195f49);
  border-radius: 22px;
  color: #fff;
  padding: 70px 35px;
  text-align: center;
}

.ai-symbol {
  font-size: 55px;
  color: #69e9ae;
}

.ai-placeholder h2 {
  font:
    800 clamp(25px, 3vw, 36px) Manrope,
    sans-serif;
  max-width: 600px;
  margin: 24px auto 16px;
}

.ai-placeholder p {
  color: #bbd9cc;
  max-width: 590px;
  margin: 0 auto 30px;
  line-height: 1.7;
}

.ai-checks {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.ai-checks span {
  border: 1px solid #ffffff35;
  padding: 10px 15px;
  border-radius: 25px;
  font-size: 12px;
}

.ai-placeholder small {
  color: #95b9a7;
}
.ai-workspace {
  padding: clamp(28px, 5vw, 56px);
  text-align: left;
}
.ai-workspace .ai-symbol {
  line-height: 1;
}
.ai-workspace h2,
.ai-workspace > p {
  margin-left: 0;
}
.ai-workspace > p {
  margin-bottom: 20px;
}
.ai-run-button {
  margin: 4px 0 10px;
}
.ai-workspace .sales-feedback {
  max-width: 100%;
  margin: 8px 0;
  color: #d4e9df;
  font-size: 12px;
}
.ai-results {
  margin-top: 26px;
  padding-top: 24px;
  border-top: 1px solid #ffffff30;
}
.ai-results > h3 {
  margin: 0 0 16px;
  font: 800 18px Manrope, sans-serif;
}
.ai-recommendation-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.ai-recommendation-card {
  display: grid;
  gap: 14px;
  min-width: 0;
  padding: 16px;
  border: 1px solid #ffffff2b;
  border-radius: 14px;
  background: #ffffff0c;
}
.ai-recommendation-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}
.ai-recommendation-heading h4 {
  margin: 0 0 4px;
  font: 800 15px Manrope, sans-serif;
}
.ai-recommendation-heading small,
.ai-recommendation-timing {
  color: #a9cbbc;
  font-size: 11px;
}
.ai-urgency {
  padding: 5px 8px;
  border: 1px solid #ffffff30;
  border-radius: 999px;
  color: #d6e8df;
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
  white-space: nowrap;
}
.ai-urgency.critica,
.ai-urgency.alta {
  color: #ffe3cf;
  background: #b34e3540;
}
.ai-recommendation-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.ai-recommendation-metrics > div {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 9px;
  border-radius: 9px;
  background: #ffffff0c;
}
.ai-recommendation-metrics small {
  color: #a9cbbc;
  font-size: 9px;
}
.ai-recommendation-metrics strong {
  overflow-wrap: anywhere;
  font-size: 13px;
}
.ai-recommendation-card p,
.ai-empty-results {
  margin: 0;
  color: #d3e8de;
  font-size: 12px;
  line-height: 1.6;
}
.ai-data-warning {
  grid-column: 1 / -1;
  margin: 0;
  padding: 10px 12px;
  border: 1px solid #e5c97b;
  border-radius: 10px;
  background: #fff8df;
  color: #6f5310;
  font-size: 12px;
  line-height: 1.5;
}
.ai-empty-results {
  grid-column: 1 / -1;
  padding: 18px 0;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: #091d19b3;
  z-index: 10;
  display: grid;
  place-items: center;
  padding: 20px;
  animation: appear 0.2s;
}

.modal {
  background: #fff;
  border-radius: 20px;
  width: min(510px, 100%);
  padding: 30px;
  max-height: 90vh;
  overflow: auto;
  box-shadow: 0 30px 90px #0003;
  animation: pageEnter 0.25s;
}

.modal-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
}

.modal h2 {
  margin: 9px 0 0;
}

.close {
  border: 0;
  background: #f1f5f3;
  border-radius: 9px;
  font-size: 26px;
  width: 36px;
  height: 36px;
}

.form-hint {
  font-size: 12px;
  color: #8e9f95;
  line-height: 1.5;
}

.toast {
  padding: 14px 18px;
  background: #e6f7ec;
  color: #176f4d;
  border: 1px solid #b8e3cb;
  border-radius: 12px;
  margin-bottom: 22px;
  font-size: 13px;
}

.toast.error {
  background: #fff0ed;
  border-color: #f4c7bf;
  color: #aa3d31;
}

@keyframes dashboardEnter {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pageEnter {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes appear {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@media (max-width: 1150px) {
  .stats {
    grid-template-columns: repeat(2, 1fr);
  }

  .overview-grid {
    grid-template-columns: 1fr;
  }

  .health {
    justify-content: center;
  }

  .sidebar {
    width: 225px;
  }

  .brand {
    font-size: 15px;
  }
}

@media (max-width: 750px) {
  .login-screen {
    grid-template-columns: 1fr;
  }

  .login-art {
    display: none;
  }

  .login-side {
    min-height: 100vh;
  }

  .mobile-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 55px;
    font-size: 19px;
    font-weight: 800;
  }

  .sidebar {
    width: 100%;
    height: auto;
    position: relative;
    padding: 15px;
  }

  .brand {
    padding: 0;
  }

  .nav-label {
    display: none;
  }

  .sidebar nav {
    display: flex;
    overflow: auto;
    margin-top: 15px;
    gap: 6px;
  }

  .nav-btn {
    white-space: nowrap;
    width: auto;
    font-size: 12px;
  }

  .nav-btn > span:first-child {
    font-size: 16px;
    width: auto;
  }

  .soon {
    display: none;
  }

  .side-bottom {
    padding-top: 10px;
  }

  .shell {
    display: block;
  }

  .topbar {
    height: 64px;
    padding: 0 18px;
    gap: 8px;
  }

  .top-actions {
    gap: 8px;
    flex-shrink: 0;
  }

  .top-actions .connected,
  .top-actions .top-avatar {
    display: none;
  }

  .topbar .logout {
    padding: 7px 9px;
  }

  .breadcrumb {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .main {
    padding: 22px 16px;
  }

  .page-head {
    align-items: start;
    flex-direction: column;
  }

  .welcome-graphic {
    display: none;
  }

  .welcome {
    padding: 25px;
  }

  .two-col {
    grid-template-columns: 1fr;
  }

  .toolbar {
    flex-direction: column;
  }

  .toolbar select {
    width: 100%;
  }
}

@media (max-width: 440px) {
  .stats {
    gap: 10px;
  }

  .stat {
    padding: 15px;
  }

  .stat strong {
    font-size: 22px;
  }

  .panel {
    padding: 18px;
  }

  .health {
    flex-direction: column;
  }

  .fields {
    grid-template-columns: 1fr;
  }

  .top-actions .connected {
    font-size: 0;
  }

  .top-actions .connected i {
    width: 9px;
    height: 9px;
  }

  .breadcrumb {
    font-size: 9px;
  }
}

/* Navigation, theme control and rotating product showcase */
.top-actions {
  gap: 12px;
}
.theme-toggle {
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: #254c3e;
  font-size: 19px;
}
.environment-switch {
  display: grid;
  gap: 3px;
  color: #91a198;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 1px;
}
.environment-switch select {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 7px 9px;
  color: var(--ink);
  background: #fff;
}
.product-carousel {
  overflow: hidden;
  padding: 22px 24px;
}
.carousel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.carousel-heading h3 {
  margin: 6px 0 0;
  font:
    800 18px Manrope,
    sans-serif;
}
.carousel-window {
  overflow: hidden;
  mask-image: linear-gradient(
    90deg,
    transparent,
    #000 5%,
    #000 95%,
    transparent
  );
}
.carousel-track {
  display: flex;
  width: max-content;
  gap: 0;
  animation: carouselMove 24s linear infinite;
}
.carousel-track.is-static {
  animation: none;
}
.carousel-card {
  width: 220px;
  margin-right: 14px;
  min-height: 116px;
  display: grid;
  grid-template-columns: 42px 1fr;
  align-content: center;
  column-gap: 12px;
  row-gap: 5px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 15px;
  text-align: left;
  color: var(--ink);
  background: linear-gradient(145deg, #fff, #f5faf7);
}
.carousel-product-icon {
  grid-row: span 2;
  width: 42px;
  height: 42px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  color: #137b56;
  background: #dff5e9;
  font-size: 19px;
  font-weight: 800;
}
.carousel-card b {
  align-self: end;
}
.carousel-card small {
  color: var(--muted);
}
.carousel-hint {
  margin: 13px 0 0;
  color: var(--muted);
  font-size: 11px;
}
.grocery-expenses {
  margin: 0 0 22px;
  padding: 22px 24px;
}
.expense-summary {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 8px 0 16px;
}
.expense-summary strong {
  font:
    800 clamp(24px, 3vw, 34px) Manrope,
    sans-serif;
  color: #137b56;
}
.expense-summary span,
.expense-row small {
  color: var(--muted);
  font-size: 12px;
}
.expense-list {
  display: grid;
  gap: 10px;
}
.expense-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}
.expense-row div {
  display: grid;
  gap: 4px;
}
.expense-row strong {
  font-size: 13px;
  white-space: nowrap;
}
.purchase-cost-field small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.5;
}
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.feature-card {
  min-height: 190px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface, #fff);
  box-shadow: 0 8px 26px #173d2c08;
}
.feature-card > span {
  color: #169267;
  font-size: 12px;
  font-weight: 800;
}
.feature-card h3 {
  margin: 25px 0 8px;
  font:
    800 18px Manrope,
    sans-serif;
}
.feature-card p,
.setup-note p,
.kiosk-details p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
  font-size: 13px;
}
.setup-note {
  margin-top: 20px;
  padding: 20px 23px;
  border-radius: 15px;
  background: #fff6e8;
  border: 1px solid #f4dfbd;
  color: #805a1b;
}
.setup-note p {
  margin-top: 6px;
  color: #8d7958;
}
.sales-panel {
  padding: 24px;
}
.cash-panel {
  padding: 23px 24px;
}
.reports-panel {
  margin-top: 22px;
}
.sales-report-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 16px 0 22px;
}
.sales-report-metrics > div {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface, #fff);
}
.sales-report-metrics small {
  color: var(--muted);
  font-size: 11px;
}
.sales-report-metrics strong {
  overflow-wrap: anywhere;
  color: var(--green);
  font: 800 clamp(16px, 2vw, 22px) Manrope, sans-serif;
}
.reports-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}
.reports-grid h4 {
  margin: 0 0 10px;
  font: 800 14px Manrope, sans-serif;
}
.table-scroll {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 10px;
}
.report-table {
  width: 100%;
  min-width: 440px;
  border-collapse: collapse;
  font-size: 11px;
}
.report-table th,
.report-table td {
  padding: 10px 11px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  white-space: nowrap;
}
.report-table th {
  color: var(--muted);
  font-size: 9px;
  letter-spacing: 0.06em;
}
.report-table tbody tr:last-child td {
  border-bottom: 0;
}
.numeric-cell {
  text-align: right !important;
  font-variant-numeric: tabular-nums;
}
.empty-report {
  padding: 18px !important;
  color: var(--muted);
  text-align: center !important;
  white-space: normal !important;
}
.negative-value {
  color: #c5483d;
}
.positive-value {
  color: var(--green);
}
.cash-form {
  display: flex;
  align-items: end;
  gap: 12px;
  flex-wrap: wrap;
}
.cash-form[hidden] {
  display: none;
}
.cash-form label,
.pos-cart label {
  display: grid;
  gap: 7px;
  min-width: 210px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
}
.cash-form input,
.pos-cart select {
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--surface, #fff);
  color: var(--ink);
}
.cash-active[hidden],
.pos-panel[hidden] {
  display: none;
}
.cash-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0 0 20px;
}
.cash-metrics > div {
  display: grid;
  gap: 7px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 11px;
}
.cash-metrics small {
  color: var(--muted);
  font-size: 10px;
}
.cash-metrics strong,
.pos-total strong {
  font:
    800 18px Manrope,
    sans-serif;
}
.pos-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(250px, 0.7fr);
  gap: 18px;
  align-items: start;
}
.pos-dishes {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.pos-dish,
.pos-cart {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface, #fff);
}
.pos-dish {
  display: grid;
  align-content: start;
  gap: 9px;
}
.pos-dish-heading,
.pos-total,
.pos-cart-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.pos-dish-heading b {
  font-size: 12px;
}
.pos-dish-heading span {
  color: var(--green);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}
.pos-option {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 10px;
}
.pos-option input {
  accent-color: #168a60;
}
.pos-note {
  width: 100%;
  min-height: 34px;
  padding: 7px 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
}
.pos-cart h4 {
  margin: 0 0 10px;
}
.pos-cart-line {
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-size: 10px;
}
.pos-total {
  margin: 12px 0;
  font-size: 11px;
}
.pos-total strong {
  color: var(--green);
}
.pos-cart label {
  margin: 0 0 12px;
}
.payment-state {
  font-size: 10px;
  font-weight: 700;
}
.payment-state.paid {
  color: #14855e;
}
.payment-state.pending {
  color: #ab7521;
}
.payment-method-select {
  min-width: 93px;
  padding: 7px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface, #fff);
  color: var(--ink);
  font-size: 10px;
}
.dish-editor {
  display: grid;
  gap: 15px;
  margin: 0 0 18px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: #f8fbf9;
}
.dish-editor[hidden] {
  display: none;
}
.dish-editor label {
  display: grid;
  gap: 7px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
}
.dish-editor input:not([type="checkbox"]),
.dish-editor textarea {
  width: 100%;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}
.dish-editor textarea {
  min-height: 88px;
  resize: vertical;
}
.dish-editor label small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 500;
  line-height: 1.5;
}
.dish-active-label {
  display: flex !important;
  align-items: center;
  gap: 9px !important;
}
.dish-active-label input {
  width: 16px;
  height: 16px;
  accent-color: #168a60;
}
.dish-editor-actions,
.dish-row-actions,
.order-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}
.dish-editor-actions .primary {
  min-width: 150px;
}
.sales-feedback {
  min-height: 18px;
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 12px;
}
.dish-list,
.order-list {
  display: grid;
  gap: 10px;
}
.dish-row,
.order-card {
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: var(--surface, #fff);
}
.dish-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 15px;
}
.dish-row.inactive {
  opacity: 0.72;
}
.dish-row-details {
  display: grid;
  gap: 4px;
  min-width: 0;
}
.dish-row-details b {
  font-size: 13px;
}
.dish-row-details small {
  overflow: hidden;
  color: var(--muted);
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.dish-row > strong {
  white-space: nowrap;
}
.small-button {
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 11px;
}
.danger-button {
  color: #a33b32;
}
.order-panel {
  margin-top: 24px;
}
.order-card {
  display: grid;
  gap: 10px;
}
.order-card-heading,
.order-item,
.order-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.order-card-heading b {
  font:
    800 15px Manrope,
    sans-serif;
}
.order-card > small,
.order-items > small {
  color: var(--muted);
  font-size: 10px;
}
.order-items {
  display: grid;
  gap: 7px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.order-item {
  font-size: 12px;
}
.order-card-footer {
  flex-wrap: wrap;
}
.order-card-footer > strong {
  font-size: 12px;
}
.kiosk-preview {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(260px, 0.7fr);
  gap: 20px;
  align-items: stretch;
}
.kiosk-screen {
  padding: clamp(25px, 5vw, 55px);
  border-radius: 22px;
  color: #fff;
  background: radial-gradient(circle at 90% 10%, #317757, #102f29 65%);
}
.kiosk-icon {
  display: block;
  color: #75e3b2;
  font-size: 40px;
  margin-bottom: 20px;
}
.kiosk-screen h2 {
  max-width: 570px;
  margin: 22px 0 12px;
  font:
    800 clamp(26px, 4vw, 42px) Manrope,
    sans-serif;
}
.kiosk-screen p {
  color: #c1ded0;
  line-height: 1.6;
}
.kiosk-details {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface, #fff);
}
.kiosk-details h3 {
  font:
    800 19px Manrope,
    sans-serif;
}
.kiosk-details .status-pill {
  margin-top: 24px;
}
@keyframes carouselMove {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}
body.dark-theme {
  --bg: #101923;
  --ink: #e7eef5;
  --line: #2b3b49;
  --muted: #9baaba;
  --surface: #192735;
  background: var(--bg);
  color: var(--ink);
}
.dark-theme .topbar,
.dark-theme .stat,
.dark-theme .panel,
.dark-theme .modal,
.dark-theme .feature-card,
.dark-theme .kiosk-details,
.dark-theme .login-environment {
  background: #192735;
  color: var(--ink);
}
.dark-theme .theme-toggle,
.dark-theme .secondary,
.dark-theme .environment-switch select {
  background: #223442;
  color: var(--ink);
  border-color: var(--line);
}
.dark-theme .topbar .logout {
  background: #223442;
  color: var(--ink);
  border-color: var(--line);
}
.dark-theme .donut > div,
.dark-theme .critical-item,
.dark-theme th,
.dark-theme .search,
.dark-theme .login-card input,
.dark-theme .form input,
.dark-theme .form select,
.dark-theme .dish-editor,
.dark-theme .dish-editor input,
.dark-theme .dish-editor textarea,
.dark-theme .dish-row,
.dark-theme .order-card,
.dark-theme .cash-form input,
.dark-theme .pos-dish,
.dark-theme .pos-cart,
.dark-theme .pos-note,
.dark-theme .payment-method-select,
.dark-theme .pos-cart select,
.dark-theme .toolbar select {
  background: #202e28;
  color: var(--ink);
  border-color: var(--line);
}
.dark-theme .environment-choice.selected {
  color: var(--ink);
}
.dark-theme .expense-summary strong {
  color: #75d8ac;
}
.dark-theme .carousel-card {
  background: linear-gradient(145deg, #223442, #192735);
  color: var(--ink);
}

/* Acabamento visual do painel e componentes dos novos fluxos. */
.main {
  max-width: 1740px;
  padding-top: clamp(28px, 4vw, 56px);
  background:
    radial-gradient(ellipse at 90% 0%, #20a8750b, transparent 36%),
    radial-gradient(ellipse at 2% 20%, #60cfa20a, transparent 32%);
}
.page-head { margin-bottom: 32px; }
.page-head h1 { font-size: clamp(32px, 3.6vw, 46px); }
.welcome {
  min-height: 225px;
  border: 1px solid #ffffff20;
  border-radius: 26px;
  padding: clamp(30px, 4vw, 54px);
  background:
    radial-gradient(circle at 78% 20%, #56e3d333, transparent 28%),
    linear-gradient(118deg, #142333 0%, #14566a 58%, #087f8c 100%);
  box-shadow: 0 24px 65px #14233324, inset 0 1px #ffffff1c;
}
.welcome::after {
  content: "";
  position: absolute;
  width: 360px;
  height: 360px;
  right: -80px;
  top: -180px;
  border-radius: 50%;
  border: 1px solid #ffffff20;
  box-shadow: 0 0 0 35px #ffffff08, 0 0 0 74px #ffffff06;
}
.welcome h2 { font-size: clamp(29px, 3.4vw, 42px); letter-spacing: -1.4px; }
.welcome-graphic { z-index: 1; }
.welcome-graphic > span { filter: drop-shadow(0 0 24px #65f1d7a0); }
.orbit { animation: orbitPulse 7s ease-in-out infinite alternate; }
@keyframes orbitPulse { to { transform: scale(1.12) rotate(18deg); opacity: .58; } }
.stat, .panel {
  border-radius: 20px;
  box-shadow: 0 14px 38px #173d2c0c, 0 2px 8px #173d2c06;
  transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}
.stat:hover, .panel:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 44px #173d2c12, 0 3px 10px #173d2c08;
  border-color: #b8d8c9;
}
.stat { padding: 26px; }
.stat-icon { box-shadow: inset 0 1px #ffffffaa; }
.movement-chart-panel { overflow: hidden; }
.chart-legend { display: flex; gap: 16px; flex-wrap: wrap; color: var(--muted); font-size: 12px; font-weight: 700; }
.chart-legend span { display: inline-flex; align-items: center; gap: 7px; }
.chart-dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.chart-dot.incoming { background: #12a88a; }
.chart-dot.outgoing { background: #f18a62; }
.movement-chart { min-height: 220px; }
.movement-chart svg { display: block; width: 100%; height: auto; overflow: visible; }
.movement-chart .chart-grid { stroke: #e8eef2; stroke-width: 1; }
.movement-chart .chart-axis-label { fill: #8795a3; font: 11px "DM Sans", sans-serif; }
.movement-chart .chart-series { fill: none; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.movement-chart .chart-series.incoming { stroke: #12a88a; }
.movement-chart .chart-series.outgoing { stroke: #f18a62; }
.movement-chart .chart-point { stroke: #fff; stroke-width: 2; }
.movement-chart .chart-point.incoming { fill: #12a88a; }
.movement-chart .chart-point.outgoing { fill: #f18a62; }
.dark-theme .movement-chart .chart-grid { stroke: #2b3b49; }
.dark-theme .movement-chart .chart-axis-label { fill: #a5b4c3; }
.dark-theme .movement-chart .chart-point { stroke: #192735; }
.stat-icon { background: #e2f6f3; color: #087f8c; }
.stat-icon.amber { background: #fff3e5; color: #c77b16; }
.stat-icon.blue { background: #e7f0fa; color: #3c72ad; }
.stat-icon.violet { background: #f0ebff; color: #7559bb; }
.soft-pill { background: #e5f5f3; color: #087f8c; }
.history-tab.active { background: #14566a; border-color: #14566a; }
.product-carousel { overflow: hidden; }
.history-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  margin: 0 0 16px;
  padding: 5px 2px;
}
.history-actions { display: flex; flex-wrap: wrap; gap: 9px; }
.history-actions button { white-space: nowrap; }
.history-tab {
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 11px 17px;
  color: var(--muted);
  background: var(--surface, #fff);
  font-weight: 800;
}
.history-tab.active { background: #123e30; border-color: #123e30; color: #fff; }
.history-pane { min-height: 130px; }
.approvals-panel { margin-top: 24px; }
.approval-list { display: grid; gap: 12px; }
.approval-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 17px 19px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: linear-gradient(115deg, #f6faf7, #ffffff);
}
.approval-card p { margin: 7px 0 0; color: var(--muted); font-size: 13px; }
.approval-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.small-button { padding: 10px 13px; font-size: 12px; }
.dark-theme .approval-card { background: linear-gradient(115deg, #202e28, #19241f); }
.dark-theme .history-tab { background: #202e28; border-color: var(--line); }
.dark-theme .history-tab.active { background: #087f8c; border-color: #087f8c; }
@media (max-width: 700px) {
  .approval-card { align-items: stretch; flex-direction: column; }
  .approval-actions > button { flex: 1; }
  .welcome { min-height: 190px; }
}
@media (max-width: 800px) {
  .feature-grid {
    grid-template-columns: 1fr;
  }
  .kiosk-preview {
    grid-template-columns: 1fr;
  }
  .dish-row {
    grid-template-columns: minmax(0, 1fr) auto;
  }
  .dish-row-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }
  .cash-metrics {
    grid-template-columns: 1fr;
  }
  .sales-report-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .reports-grid {
    grid-template-columns: 1fr;
  }
  .pos-layout {
    grid-template-columns: 1fr;
  }
  .pos-dishes {
    grid-template-columns: 1fr;
  }
  .ai-recommendation-list {
    grid-template-columns: 1fr;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* Paleta A: creme, carvão, terracota e sálvia. */
:root {
  --dark: #252a28;
  --ink: #252a28;
  --green: #67836c;
  --mint: #d96643;
  --bg: #f4efe6;
  --surface: #fffdf9;
  --line: #e4dbce;
  --muted: #77766e;
}
body { background: var(--bg); color: var(--ink); }
.main { background: radial-gradient(ellipse at 90% 0%, #d966430d, transparent 36%), radial-gradient(ellipse at 2% 20%, #67836c12, transparent 32%); }
.sidebar { background: #252a28; }
.brand small, .nav-label { color: #c8bca9; }
.nav-btn { color: #e9e1d5; }
.nav-btn.active, .nav-btn:hover { background: #3a403c; color: #fffdf9; }
.logo-mark { background: linear-gradient(145deg, #d96643, #a9462e); }
.accent, .eyebrow { color: #b75035; }
.primary { background: #d96643; }
.primary:hover { background: #b75035; }
.secondary { color: #35463a; }
.topbar { background: #fffdf9; }
.breadcrumb strong { color: #35463a; }
.connected { color: #67836c; }
.connected i { background: #67836c; }
.welcome {
  background: radial-gradient(circle at 78% 20%, #ffffff1d, transparent 30%), linear-gradient(118deg, #252a28 0%, #3e4b41 58%, #67836c 100%);
  box-shadow: 0 24px 65px #252a2824, inset 0 1px #ffffff1c;
}
.welcome-tag { color: #f5d4c7; }
.welcome-graphic > span { color: #edab83; }
.welcome-graphic > span { filter: drop-shadow(0 0 24px #d9664380); }
.stat, .panel { background: #fffdf9; border-color: var(--line); }
.stat:hover, .panel:hover { border-color: #cdbda8; box-shadow: 0 20px 44px #252a2815, 0 3px 10px #252a280a; }
.stat-icon { background: #e6ece4; color: #526c57; }
.stat-icon.amber { background: #f8ecd6; color: #9a6a17; }
.stat-icon.blue { background: #f7e2da; color: #b75035; }
.stat-icon.violet { background: #eee7dc; color: #6b6254; }
.soft-pill { background: #e6ece4; color: #526c57; }
.history-tab.active { background: #67836c; border-color: #67836c; }
.chart-dot.incoming { background: #67836c; }
.chart-dot.outgoing { background: #d96643; }
.movement-chart .chart-grid { stroke: #e8dfd2; }
.movement-chart .chart-series.incoming { stroke: #67836c; }
.movement-chart .chart-series.outgoing { stroke: #d96643; }
.movement-chart .chart-point.incoming { fill: #67836c; }
.movement-chart .chart-point.outgoing { fill: #d96643; }
.donut { background: conic-gradient(#67836c 0 68%, #d96643 68% 100%); }
.status-pill.low { background: #fff0dd; color: #9a5e16; }
.approval-card { background: linear-gradient(115deg, #f8f4ed, #fffdf9); }
.history-tab { background: var(--surface); }
.form input, .form select, .toolbar input, .toolbar select { background: #fffdf9; border-color: #d9d0c2; color: #252a28; }
.login-card input:focus, .form input:focus, .form select:focus, .toolbar input:focus { border-color: #67836c; box-shadow: 0 0 0 3px #67836c20; }
.remember-login input { accent-color: #67836c; }
.insight-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin: 0 0 23px; }
.insight-panel { min-width: 0; padding: 22px; }
.insight-panel .panel-heading { align-items: flex-start; }
.insight-icon { display: grid; place-items: center; flex: 0 0 38px; height: 38px; border-radius: 12px; background: #f7e2da; color: #b75035; font-weight: 800; }
.insight-content { min-height: 100px; }
.insight-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 0; border-bottom: 1px solid #eee7dc; }
.insight-row:last-of-type { border-bottom: 0; }
.insight-row > div { min-width: 0; }
.insight-row b, .insight-row small { display: block; }
.insight-row b { overflow-wrap: anywhere; font-size: 13px; }
.insight-row small, .insight-summary { color: var(--muted); font-size: 11px; line-height: 1.5; }
.insight-row strong { flex: 0 0 auto; font-size: 13px; color: #526c57; text-align: right; }
.insight-row.warning strong { color: #b75035; }
.insight-row.muted { opacity: .72; }
.insight-summary { margin: 12px 0 0; }
.insight-note { padding: 16px; border: 1px solid #e9d5c9; border-radius: 13px; background: #fbf2ec; color: #5b5048; }
.insight-note b { color: #a9462e; font-size: 13px; }
.insight-note p { margin: 7px 0 0; font-size: 12px; line-height: 1.6; }
.order-trend-bars { height: 150px; display: grid; grid-template-columns: repeat(30, minmax(2px, 1fr)); align-items: end; gap: 3px; padding: 12px 2px 20px; border-bottom: 1px solid var(--line); }
.order-trend-bar { position: relative; display: block; min-height: 3px; height: var(--bar-height); border-radius: 5px 5px 2px 2px; background: linear-gradient(180deg, #d96643, #e9a084); }
.order-trend-bar small { position: absolute; top: calc(100% + 5px); left: 50%; color: var(--muted); font-size: 8px; white-space: nowrap; transform: translateX(-50%); }
.heatmap-grid { display: grid; grid-template-columns: 42px repeat(4, minmax(0, 1fr)); gap: 5px; align-items: center; }
.heatmap-heading { color: var(--muted); text-align: center; font-size: 9px; }
.heatmap-day { color: var(--muted); font-size: 10px; }
.heatmap-cell { display: grid; place-items: center; min-height: 27px; border-radius: 7px; background: color-mix(in srgb, #67836c calc(12% + var(--heat)), #f4efe6); color: #252a28; font-size: 10px; }
.text-btn { color: #b75035; }
body.dark-theme {
  --bg: #181c1a;
  --ink: #f1ece3;
  --line: #3c423d;
  --muted: #b4afa5;
  --surface: #242a26;
  background: var(--bg);
  color: var(--ink);
}
.dark-theme .topbar, .dark-theme .stat, .dark-theme .panel, .dark-theme .modal, .dark-theme .feature-card, .dark-theme .kiosk-details, .dark-theme .login-environment { background: #242a26; color: var(--ink); }
.dark-theme .sidebar { background: #121513; }
.dark-theme .nav-btn.active, .dark-theme .nav-btn:hover { background: #343d36; }
.dark-theme .form input, .dark-theme .form select, .dark-theme .toolbar input, .dark-theme .toolbar select, .dark-theme .search { background: #202521; color: var(--ink); border-color: var(--line); }
.dark-theme .insight-row { border-color: #3c423d; }
.dark-theme .insight-row strong { color: #b6c5ae; }
.dark-theme .insight-note { background: #302821; border-color: #604335; color: #e4d8cb; }
.dark-theme .insight-note b { color: #edab83; }
.dark-theme .heatmap-cell { background: color-mix(in srgb, #67836c calc(18% + var(--heat)), #252b27); color: #f1ece3; }
.dark-theme .movement-chart .chart-grid { stroke: #3c423d; }
.dark-theme .movement-chart .chart-axis-label { fill: #b4afa5; }
.dark-theme .movement-chart .chart-point { stroke: #242a26; }
.dark-theme .approval-card { background: linear-gradient(115deg, #302821, #242a26); }
@media (max-width: 900px) { .insight-grid { grid-template-columns: 1fr; } }
@media (max-width: 750px) { .order-trend-bars { gap: 2px; } .insight-panel { padding: 17px; } }

/* Dashboard layout adapted from the supplied card-and-chart reference. */
#page-overview .page-head {
  margin-bottom: 22px;
}

#page-overview .page-head h1 {
  font-size: clamp(30px, 3vw, 40px);
  letter-spacing: -1.7px;
}

#page-overview .page-head .secondary {
  border-radius: 12px;
  min-height: 44px;
  padding-inline: 17px;
}

#page-overview .stats {
  gap: 15px;
  margin-bottom: 20px;
}

#page-overview .stat {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  grid-template-rows: auto auto auto;
  align-items: center;
  column-gap: 13px;
  row-gap: 2px;
  min-height: 128px;
  padding: 19px 20px;
}

#page-overview .stat-icon {
  grid-column: 1;
  grid-row: 1 / 4;
  width: 42px;
  height: 42px;
  margin: 0;
  border-radius: 13px;
}

#page-overview .stat small,
#page-overview .stat strong,
#page-overview .stat span {
  grid-column: 2;
  min-width: 0;
}

#page-overview .stat small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.35;
}

#page-overview .stat strong {
  margin: 2px 0;
  font-size: clamp(21px, 2vw, 29px);
  line-height: 1.15;
}

#page-overview .stat span {
  font-size: 11px;
  line-height: 1.4;
}

.overview-main-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(300px, .9fr);
  align-items: stretch;
  gap: 18px;
  margin-bottom: 18px;
}

.overview-main-grid > .panel,
.overview-side-stack > .panel {
  min-width: 0;
  margin-bottom: 0;
}

.overview-side-stack {
  display: grid;
  grid-template-rows: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px;
  min-width: 0;
}

.overview-side-stack .panel {
  padding: 21px;
}

.overview-side-stack .panel-heading {
  margin-bottom: 15px;
}

.overview-side-stack .panel-heading h3 {
  margin: 5px 0 4px;
}

.overview-side-stack .panel-heading .eyebrow {
  font-size: 9px;
  letter-spacing: 1.35px;
}

.inventory-health-panel .health {
  justify-content: flex-start;
  gap: 17px;
  padding: 0;
}

.inventory-health-panel .donut {
  width: 128px;
  height: 128px;
}

.inventory-health-panel .donut > div {
  width: 91px;
  height: 91px;
}

.inventory-health-panel .legend {
  min-width: 0;
  flex: 1;
}

.inventory-health-panel .legend > div {
  gap: 8px;
}

.attention-panel .critical-list {
  max-height: 190px;
  overflow-y: auto;
  padding-right: 3px;
}

.movement-chart-panel {
  display: flex;
  flex-direction: column;
  min-height: 370px;
  padding: 25px;
}

.movement-chart-panel .panel-heading {
  align-items: center;
  margin-bottom: 14px;
}

.movement-chart-panel .panel-heading h3 {
  margin: 5px 0;
  font-size: 19px;
}

.movement-chart-panel .panel-heading .eyebrow {
  font-size: 9px;
  letter-spacing: 1.4px;
}

.movement-chart-panel .movement-chart {
  display: flex;
  flex: 1;
  align-items: center;
  min-height: 245px;
}

.product-carousel {
  padding: 22px 25px 16px;
  margin-bottom: 18px;
}

.product-carousel .carousel-heading {
  margin-bottom: 13px;
}

.product-carousel .carousel-heading h3 {
  margin: 5px 0 0;
}

.product-carousel .carousel-hint {
  margin: 10px 0 0;
  font-size: 11px;
}

#page-overview .insight-grid {
  gap: 16px;
  margin-bottom: 18px;
}

#page-overview .insight-panel {
  padding: 20px 22px;
}

.overview-lower-grid {
  align-items: stretch;
  gap: 18px;
}

.overview-lower-grid > .panel {
  min-width: 0;
  margin-bottom: 0;
}

.overview-lower-grid .panel-heading {
  align-items: center;
  margin-bottom: 15px;
}

.overview-lower-grid .grocery-expenses {
  padding: 22px;
}

.overview-lower-grid .dashboard-activity-card {
  padding: 22px;
}

.overview-lower-grid .panel-heading h3 {
  margin: 5px 0 4px;
}

.overview-lower-grid .panel-heading .eyebrow {
  font-size: 9px;
  letter-spacing: 1.35px;
}

#page-overview .stat:focus-within,
#page-overview .panel:focus-within {
  outline: 2px solid #67836c;
  outline-offset: 2px;
}

.dark-theme .overview-side-stack .panel,
.dark-theme .overview-lower-grid > .panel {
  background: #242a26;
}

@media (max-width: 1120px) {
  .overview-main-grid {
    grid-template-columns: minmax(0, 1.2fr) minmax(270px, .9fr);
  }

  .inventory-health-panel .health {
    gap: 12px;
  }

  .inventory-health-panel .donut {
    width: 108px;
    height: 108px;
  }

  .inventory-health-panel .donut > div {
    width: 77px;
    height: 77px;
  }
}

@media (max-width: 900px) {
  .overview-main-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .overview-side-stack {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto;
  }

  .overview-lower-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 650px) {
  #page-overview .page-head {
    align-items: stretch;
  }

  #page-overview .page-head .secondary {
    align-self: flex-start;
  }

  #page-overview .stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  #page-overview .stat {
    grid-template-columns: 36px minmax(0, 1fr);
    column-gap: 9px;
    min-height: 112px;
    padding: 14px 12px;
  }

  #page-overview .stat-icon {
    width: 35px;
    height: 35px;
    border-radius: 11px;
    font-size: 17px;
  }

  #page-overview .stat small,
  #page-overview .stat span {
    font-size: 10px;
  }

  #page-overview .stat strong {
    font-size: 20px;
  }

  .overview-main-grid,
  .overview-side-stack {
    grid-template-columns: minmax(0, 1fr);
  }

  .overview-side-stack {
    gap: 12px;
  }

  .movement-chart-panel {
    min-height: 320px;
    padding: 19px;
  }

  .movement-chart-panel .panel-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .inventory-health-panel .health {
    justify-content: space-around;
  }

  .product-carousel {
    padding: 19px;
  }
}

@media (max-width: 380px) {
  #page-overview .stats {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Bento dashboard inspired by the supplied Web3 reference, using stock data. */
#page-overview .stats {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(122px, auto));
  gap: 13px;
}

#page-overview .stat {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  border-color: #e3dbcf;
  box-shadow: 0 5px 18px #292c2810;
}

#page-overview .stat-bento-hero {
  grid-column: 1 / span 2;
  grid-row: 1 / span 2;
  grid-template-columns: 46px minmax(0, 1fr);
  grid-template-rows: auto auto auto;
  align-content: center;
  min-height: 257px;
  padding: 27px;
  border-color: #303b33;
  background: linear-gradient(137deg, #242a26 0%, #313b33 58%, #526950 100%);
  color: #f8f5ed;
  box-shadow: 0 16px 34px #252a281c, inset 0 1px #ffffff1a;
}

#page-overview .stat-bento-hero .stat-icon {
  background: #d8f6a4;
  color: #28352a;
}

#page-overview .stat-bento-hero small,
#page-overview .stat-bento-hero span {
  color: #d5ddcf;
}

#page-overview .stat-bento-hero small {
  letter-spacing: 1.2px;
}

#page-overview .stat-bento-hero strong {
  font-size: clamp(42px, 5vw, 66px);
  letter-spacing: -2.8px;
  line-height: 1;
}

#page-overview .stat-bento-hero .stat-bento-mark {
  position: absolute;
  right: 20px;
  top: 14px;
  color: #d8f6a4;
  font-size: 94px;
  line-height: 1;
  opacity: .12;
  transform: rotate(-14deg);
  pointer-events: none;
}

#page-overview .stat-bento-critical {
  grid-column: 3;
  grid-row: 1;
}

#page-overview .stat-bento-units {
  grid-column: 4;
  grid-row: 1;
}

#page-overview .stat-bento-value {
  grid-column: 3 / span 2;
  grid-row: 2;
  grid-template-columns: 44px minmax(0, 1fr);
  grid-template-rows: auto auto auto;
}

#page-overview .stat-bento-value strong {
  font-size: clamp(22px, 2.3vw, 31px);
}

#page-overview .overview-main-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(178px, auto));
  gap: 13px;
}

#page-overview .movement-chart-panel {
  grid-column: 1 / span 2;
  grid-row: 1 / span 2;
  min-height: 370px;
  border-radius: 24px;
  background: #fffdf9;
}

#page-overview .overview-side-stack {
  display: contents;
}

#page-overview .inventory-health-panel {
  grid-column: 3 / span 2;
  grid-row: 1;
  border-radius: 24px;
}

#page-overview .attention-panel {
  grid-column: 3 / span 2;
  grid-row: 2;
  border-radius: 24px;
}

#page-overview .inventory-health-panel .health {
  justify-content: space-around;
}

#page-overview .product-carousel,
#page-overview .insight-panel,
#page-overview .overview-lower-grid > .panel {
  border-radius: 23px;
}

#page-overview .product-carousel {
  border-color: #e3dbcf;
  background: linear-gradient(115deg, #fffdf9, #f8f4ec);
}

#page-overview .insight-panel {
  box-shadow: 0 4px 16px #292c280b;
}

#page-overview .chart-dot.incoming,
#page-overview .movement-chart .chart-series.incoming,
#page-overview .movement-chart .chart-point.incoming {
  background: #67836c;
  stroke: #67836c;
  fill: #67836c;
}

#page-overview .chart-dot.outgoing,
#page-overview .movement-chart .chart-series.outgoing,
#page-overview .movement-chart .chart-point.outgoing {
  background: #b59ae8;
  stroke: #9b7dd3;
  fill: #9b7dd3;
}

.dark-theme #page-overview .stat,
.dark-theme #page-overview .panel {
  background-color: #1b2025;
  border-color: #303740;
  color: #f1f0ec;
  box-shadow: 0 9px 24px #00000028;
}

.dark-theme #page-overview .stat-bento-hero {
  background: linear-gradient(137deg, #202722 0%, #303c32 58%, #476347 100%);
  border-color: #4b5c4c;
}

.dark-theme #page-overview .stat-bento-hero small,
.dark-theme #page-overview .stat-bento-hero span,
.dark-theme #page-overview .panel-heading p {
  color: #b6b9b3;
}

.dark-theme #page-overview .product-carousel {
  background: linear-gradient(115deg, #1b2025, #21251f);
}

@media (max-width: 1050px) {
  #page-overview .stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto;
  }

  #page-overview .stat-bento-hero {
    grid-column: 1 / span 2;
    grid-row: auto;
    min-height: 185px;
  }

  #page-overview .stat-bento-critical,
  #page-overview .stat-bento-units {
    grid-column: span 1;
    grid-row: auto;
  }

  #page-overview .stat-bento-value {
    grid-column: 1 / span 2;
    grid-row: auto;
  }

  #page-overview .overview-main-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto;
  }

  #page-overview .movement-chart-panel {
    grid-column: 1 / span 2;
    grid-row: auto;
    min-height: 340px;
  }

  #page-overview .inventory-health-panel,
  #page-overview .attention-panel {
    grid-column: span 1;
    grid-row: auto;
  }
}

@media (max-width: 650px) {
  #page-overview .stats {
    gap: 10px;
  }

  #page-overview .stat-bento-hero {
    padding: 22px;
  }

  #page-overview .stat-bento-critical,
  #page-overview .stat-bento-units {
    min-height: 115px;
  }

  #page-overview .overview-main-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  #page-overview .movement-chart-panel,
  #page-overview .inventory-health-panel,
  #page-overview .attention-panel {
    grid-column: 1;
  }

  #page-overview .movement-chart-panel {
    min-height: 315px;
  }
}

@media (max-width: 380px) {
  #page-overview .stats {
    grid-template-columns: minmax(0, 1fr);
  }

  #page-overview .stat-bento-hero,
  #page-overview .stat-bento-critical,
  #page-overview .stat-bento-units,
  #page-overview .stat-bento-value {
    grid-column: 1;
  }

  #page-overview .stat-bento-hero {
    min-height: 160px;
  }
}

/* Stronger dark bento treatment for the inventory overview. */
body:has(#page-overview.active) {
  background: #0c110f;
  color: #e8eee8;
}

body:has(#page-overview.active) .main-wrap {
  background: #0c110f;
}

body:has(#page-overview.active) .topbar {
  background: #111815;
  border-color: #28332d;
}

body:has(#page-overview.active) .breadcrumb,
body:has(#page-overview.active) .breadcrumb strong {
  color: #a6b5aa;
}

body:has(#page-overview.active) .connected {
  color: #9cdaa6;
}

body:has(#page-overview.active) .connected i {
  background: #86d594;
  box-shadow: 0 0 12px #86d59488;
}

body:has(#page-overview.active) .top-avatar {
  background: #263a2d;
  color: #b9e998;
}

body:has(#page-overview.active) .main {
  min-height: calc(100vh - 82px);
  color: #e8eee8;
  background:
    radial-gradient(ellipse at 82% 0%, #416b4824, transparent 33%),
    radial-gradient(ellipse at 5% 38%, #345b4120, transparent 32%),
    #0c110f;
}

#page-overview .page-head h1 {
  color: #f0f4ee;
  font-size: clamp(36px, 4vw, 54px);
  letter-spacing: -2.3px;
}

#page-overview .page-head .accent,
#page-overview > .page-head .eyebrow {
  color: #b9e998;
}

#page-overview .page-head p {
  color: #a1ada4;
  font-size: 14px;
}

#page-overview .page-head .secondary {
  background: #1a241e;
  border-color: #35463a;
  color: #e4ebe3;
}

#page-overview .stats {
  grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(132px, auto));
  gap: 14px;
  margin-bottom: 28px;
}

#page-overview .stat {
  min-height: 132px;
  padding: 22px;
  border-radius: 19px;
  border-color: #2d3931;
  background: #171e1a;
  color: #edf2ec;
  box-shadow: 0 12px 28px #0000002b;
}

#page-overview .stat-bento-hero {
  grid-column: 1 / span 6;
  grid-row: 1 / span 2;
  min-height: 278px;
  padding: clamp(24px, 3vw, 38px);
  border-color: #526f4d;
  background:
    radial-gradient(circle at 89% 20%, #b9e99822, transparent 27%),
    linear-gradient(135deg, #253a2c, #304d37 58%, #3e6041);
  box-shadow: 0 18px 42px #00000035, inset 0 1px #ffffff16;
}

#page-overview .stat-bento-hero .stat-icon {
  background: #c5ed9d;
  color: #18321f;
}

#page-overview .stat-bento-hero small {
  color: #c4d7c1;
  font-size: 11px;
}

#page-overview .stat-bento-hero strong {
  color: #f4f8f0;
  font-size: clamp(52px, 6vw, 78px);
}

#page-overview .stat-bento-hero span {
  color: #c7d5c5;
  font-size: 13px;
}

#page-overview .stat-bento-hero .stat-bento-mark {
  right: 28px;
  top: 25px;
  color: #d4f4b1;
  font-size: clamp(100px, 12vw, 160px);
  opacity: .09;
}

#page-overview .stat-bento-critical {
  grid-column: 7 / span 3;
  grid-row: 1;
  border-color: #65462d;
  background: linear-gradient(145deg, #30241a, #241d17);
}

#page-overview .stat-bento-critical .stat-icon {
  background: #4b3422;
  color: #f0b66e;
}

#page-overview .stat-bento-units {
  grid-column: 10 / span 3;
  grid-row: 1;
  border-color: #334e52;
  background: linear-gradient(145deg, #1c2b2d, #182123);
}

#page-overview .stat-bento-units .stat-icon {
  background: #294146;
  color: #8bd3cc;
}

#page-overview .stat-bento-value {
  grid-column: 7 / span 6;
  grid-row: 2;
  border-color: #4b405f;
  background: linear-gradient(125deg, #282238, #1e1b29);
}

#page-overview .stat-bento-value .stat-icon {
  background: #3b3152;
  color: #c4a8f1;
}

#page-overview .stat small,
#page-overview .stat span {
  color: #a8b4aa;
}

#page-overview .stat small {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1px;
}

#page-overview .stat strong {
  color: #f0f4ee;
}

#page-overview .overview-main-grid {
  grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(200px, auto));
  gap: 14px;
  margin-bottom: 27px;
}

#page-overview .overview-main-grid > .panel,
#page-overview .overview-side-stack > .panel {
  margin: 0;
  border-radius: 20px;
  border-color: #2d3931;
  background: #171e1a;
  color: #e8eee8;
  box-shadow: 0 12px 28px #0000002b;
}

#page-overview .movement-chart-panel {
  grid-column: 1 / span 7;
  grid-row: 1 / span 2;
  min-height: 414px;
  padding: 28px;
  background:
    radial-gradient(ellipse at 100% 0%, #3b5d3c14, transparent 40%),
    #171e1a;
}

#page-overview .overview-side-stack {
  display: contents;
}

#page-overview .inventory-health-panel {
  grid-column: 8 / span 5;
  grid-row: 1;
  background: linear-gradient(140deg, #1a241e, #171e1a);
}

#page-overview .attention-panel {
  grid-column: 8 / span 5;
  grid-row: 2;
  background: linear-gradient(140deg, #282218, #1d1c18);
}

#page-overview .panel h3 {
  color: #f0f4ee;
}

#page-overview .panel-heading p {
  color: #a1ada4;
}

#page-overview .panel .eyebrow {
  color: #a9d68b;
  letter-spacing: 1px;
}

#page-overview .movement-chart .chart-grid {
  stroke: #334039;
}

#page-overview .movement-chart .chart-axis-label {
  fill: #a1ada4;
}

#page-overview .movement-chart .chart-point {
  stroke: #171e1a;
}

#page-overview .chart-dot.incoming,
#page-overview .movement-chart .chart-series.incoming,
#page-overview .movement-chart .chart-point.incoming {
  background: #a8dd83;
  stroke: #a8dd83;
  fill: #a8dd83;
}

#page-overview .chart-dot.outgoing,
#page-overview .movement-chart .chart-series.outgoing,
#page-overview .movement-chart .chart-point.outgoing {
  background: #ed9875;
  stroke: #ed9875;
  fill: #ed9875;
}

#page-overview .donut > div {
  background: #1b231e;
  color: #f0f4ee;
}

#page-overview .donut small,
#page-overview .health-legend,
#page-overview .health-legend small {
  color: #a1ada4;
}

#page-overview .critical-item,
#page-overview .carousel-card,
#page-overview .insight-row,
#page-overview .expense-row {
  border-color: #334039;
  background: #1b231e;
  color: #e8eee8;
}

#page-overview .critical-item {
  padding: 11px 13px;
}

#page-overview .critical-item strong,
#page-overview .critical-item b,
#page-overview .carousel-card strong,
#page-overview .insight-row b,
#page-overview .insight-row strong {
  color: #e8eee8;
}

#page-overview .critical-item small,
#page-overview .carousel-card small,
#page-overview .insight-row small,
#page-overview .insight-summary {
  color: #9eaaa1;
}

#page-overview .product-carousel,
#page-overview .insight-panel,
#page-overview .overview-lower-grid > .panel {
  border-color: #2d3931;
  border-radius: 20px;
  background: #171e1a;
  color: #e8eee8;
  box-shadow: 0 12px 28px #0000002b;
}

#page-overview .product-carousel {
  padding: 25px;
  background: linear-gradient(110deg, #1b2620, #171e1a 70%);
}

#page-overview .insight-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

#page-overview .insight-panel {
  min-height: 190px;
}

#page-overview .insight-icon {
  background: #2b3b30;
  color: #b9e998;
}

#page-overview .insight-row {
  background: transparent;
}

#page-overview .insight-row strong {
  color: #b9e998;
}

#page-overview .insight-row.warning strong {
  color: #f0b66e;
}

#page-overview .insight-note {
  border-color: #5b4432;
  background: #2b211a;
  color: #ded5c8;
}

#page-overview .insight-note b {
  color: #f0b66e;
}

#page-overview .heatmap-cell {
  background: color-mix(in srgb, #79ac68 calc(18% + var(--heat)), #202922);
  color: #e8eee8;
}

#page-overview .order-trend-bar {
  background: linear-gradient(180deg, #a8dd83, #4d8151);
}

#page-overview .expense-summary strong {
  color: #f0f4ee;
}

#page-overview .expense-summary span,
#page-overview .expense-list,
#page-overview .carousel-hint,
#page-overview .empty {
  color: #9eaaa1;
}

#page-overview .soft-pill {
  background: #27392d;
  color: #b9e998;
}

#page-overview .text-btn {
  color: #c1e99e;
}

#page-overview :is(button, a):focus-visible {
  outline: 3px solid #b9e998;
  outline-offset: 3px;
}

@media (max-width: 1050px) {
  #page-overview .stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto;
  }

  #page-overview .stat-bento-hero {
    grid-column: 1 / span 2;
    grid-row: auto;
    min-height: 210px;
  }

  #page-overview .stat-bento-critical,
  #page-overview .stat-bento-units {
    grid-column: span 1;
    grid-row: auto;
  }

  #page-overview .stat-bento-value {
    grid-column: 1 / span 2;
    grid-row: auto;
  }

  #page-overview .overview-main-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto;
  }

  #page-overview .movement-chart-panel {
    grid-column: 1 / span 2;
    grid-row: auto;
    min-height: 340px;
  }

  #page-overview .inventory-health-panel,
  #page-overview .attention-panel {
    grid-column: span 1;
    grid-row: auto;
  }

  #page-overview .insight-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 650px) {
  body:has(#page-overview.active) .topbar {
    padding-inline: 16px;
  }

  body:has(#page-overview.active) .main {
    padding: 27px 16px;
  }

  #page-overview .stats {
    gap: 10px;
  }

  #page-overview .stat {
    padding: 17px;
  }

  #page-overview .stat-bento-hero {
    min-height: 190px;
    padding: 21px;
  }

  #page-overview .stat-bento-hero strong {
    font-size: clamp(44px, 12vw, 64px);
  }

  #page-overview .overview-main-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  #page-overview .movement-chart-panel,
  #page-overview .inventory-health-panel,
  #page-overview .attention-panel {
    grid-column: 1;
    padding: 20px;
  }

  #page-overview .movement-chart-panel {
    min-height: 315px;
  }

  #page-overview .insight-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 380px) {
  #page-overview .stats {
    grid-template-columns: minmax(0, 1fr);
  }

  #page-overview .stat-bento-hero,
  #page-overview .stat-bento-critical,
  #page-overview .stat-bento-units,
  #page-overview .stat-bento-value {
    grid-column: 1;
  }

  #page-overview .stat-bento-hero {
    min-height: 160px;
  }
}
/* Owner notification preferences reuse the dashboard's forest and teal identity. */
#page-notifications { --ink: #182b3d; --muted: #596d7c; --line: #dfe7ed; color: var(--ink); }
#notificationFields { min-width: 0; margin: 0; padding: 0; border: 0; }
.notification-settings-grid { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(260px, 1fr); gap: 22px; align-items: start; }
#page-notifications .panel { padding: 24px; background: #fff; border: 1px solid var(--line); box-shadow: none; }
#page-notifications .accent { color: #087f8c; }
#page-notifications .primary { background: #087f8c; color: #fff; }
#page-notifications .secondary { background: #edf6f5; border-color: #d6e7e5; color: #102d27; }
#page-notifications .panel-heading { margin-bottom: 18px; }
#page-notifications .panel-heading h3 { margin: 0 0 6px; font-family: Manrope, sans-serif; font-size: 18px; }
#page-notifications .panel-heading p { max-width: 65ch; color: var(--muted); font-size: 13px; line-height: 1.6; }
.notification-channel { display: grid; gap: 12px; padding: 22px 0; border-top: 1px solid var(--line); }
.notification-channel:first-of-type { padding-top: 4px; border-top: 0; }
.notification-choice, .notification-consent { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; }
.notification-choice input, .notification-consent input { width: 19px; height: 19px; margin: 2px 0 0; flex: 0 0 auto; accent-color: #087f8c; }
.notification-choice strong, .notification-choice small { display: block; }
.notification-choice strong { font-size: 15px; color: var(--ink); }
.notification-choice small, .notification-channel small, .notification-channel-status { margin: 5px 0 0; color: var(--muted); font-size: 12px; line-height: 1.6; overflow-wrap: anywhere; }
.notification-channel > button { justify-self: start; }
.notification-field { display: grid; gap: 8px; color: var(--ink); font-size: 13px; font-weight: 700; }
.notification-field input { width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid #b8c9d2; border-radius: 9px; background: #fff; color: var(--ink); font-size: 14px; }
.notification-consent { margin-top: 3px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.notification-digest { display: grid; gap: 20px; }
.notification-digest .panel-heading { margin-bottom: 0 !important; }
.notification-note { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.7; }
.notification-note + .notification-note { border-top: 1px solid var(--line); padding-top: 18px; }
.notification-save { display: flex; align-items: center; gap: 16px; margin: 22px 0 30px; }
.notification-save span { color: var(--muted); font-size: 12px; }
.notification-feedback { min-height: 1.5em; margin: 0 0 18px; color: var(--ink); font-size: 13px; line-height: 1.6; }
.notification-pairing { display: grid; gap: 12px; padding: 16px; border-left: 3px solid #087f8c; background: #edf6f7; border-radius: 0 9px 9px 0; }
.notification-pairing p { margin: 0; font-size: 13px; line-height: 1.6; }
.notification-pairing a { color: #056775; font-weight: 700; text-decoration: underline; }
.notification-pairing code { display: block; user-select: all; overflow-wrap: anywhere; padding: 10px; background: #fff; color: #102d27; font-size: 12px; }
.notification-pairing button { justify-self: start; }
.notification-history { margin-top: 0; }
.notification-history table { min-width: 680px; }
.notification-history .table-wrap { overflow-x: auto; }
.notification-history td { white-space: normal; vertical-align: top; line-height: 1.6; }
.notification-history td:last-child { min-width: 210px; max-width: 350px; overflow-wrap: anywhere; }
.notification-history .notification-feedback { margin-top: 16px; margin-bottom: 0; }
.notification-delivery-status { display: inline-block; color: #536976; font-size: 12px; font-weight: 700; }
.notification-delivery-status.sent { color: #166547; }
.notification-delivery-status.permanent_failure { color: #a03324; }
.notification-delivery-status.retryable_failure { color: #8c600c; }
#page-notifications :is(button, input, a):focus-visible { outline: 3px solid #087f8c; outline-offset: 3px; }
.dark-theme #page-notifications { --ink: #edf3f5; --muted: #b4c3cd; --line: #3c4a50; }
.dark-theme #page-notifications .panel, .dark-theme #page-notifications input { background: #202c31; color: var(--ink); }
.dark-theme #page-notifications .notification-pairing { background: #193c41; }
.dark-theme #page-notifications .notification-pairing code { background: #102d27; color: #edf3f5; }
.dark-theme #page-notifications .notification-pairing a { color: #62dacb; }
.dark-theme #page-notifications .notification-delivery-status.sent { color: #70d9ac; }
.dark-theme #page-notifications .notification-delivery-status.permanent_failure { color: #ffab98; }
.dark-theme #page-notifications .notification-delivery-status.retryable_failure { color: #f0cd7b; }
@media (max-width: 900px) { .notification-settings-grid { grid-template-columns: 1fr; } }
@media (max-width: 580px) { #page-notifications .panel { padding: 19px 16px; } .notification-save { align-items: flex-start; flex-direction: column; gap: 10px; } .notification-save .primary { width: 100%; } }
