:root {
  color-scheme: light;
  --bg: #f5f7f6;
  --panel: #ffffff;
  --ink: #172126;
  --muted: #62707a;
  --line: #dce3e1;
  --brand: #00a76f;
  --brand-dark: #06705f;
  --brand-bright: #22c55e;
  --brand-black: #081312;
  --brand-soft: #e8fff2;
  --amber: #f59e0b;
  --red: #ef4444;
  --blue: #1d4ed8;
  --green: #16a34a;
  --surface-gradient:
    linear-gradient(90deg, rgba(8, 19, 18, 0.055), transparent 18rem),
    radial-gradient(circle at 8% 0%, rgba(34, 197, 94, 0.16), transparent 26rem),
    radial-gradient(circle at 92% 8%, rgba(0, 167, 111, 0.1), transparent 32rem),
    linear-gradient(135deg, #f3fbf6 0%, #f8fbfa 48%, #eef7f2 100%);
  --card-gradient: linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(248, 253, 250, 0.94));
  --shadow: 0 18px 46px rgba(8, 19, 18, 0.08);
  --shadow-soft: 0 10px 28px rgba(8, 19, 18, 0.065);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

body {
  position: relative;
  margin: 0;
  min-height: 100vh;
  padding-bottom: env(safe-area-inset-bottom);
  background: var(--surface-gradient);
}

body::before {
  content: var(--fixflow-version-label, "FixFlow");
  position: fixed;
  inset: auto auto 7vh -2rem;
  z-index: 0;
  color: transparent;
  font-size: clamp(5rem, 15vw, 13rem);
  font-weight: 950;
  line-height: 0.8;
  letter-spacing: 0;
  pointer-events: none;
  text-shadow:
    0 0 0 rgba(0, 167, 111, 0.055),
    0.08em 0.08em 0 rgba(8, 19, 18, 0.045);
  transform: rotate(-14deg);
  white-space: nowrap;
}

body::after {
  content: "FixFlow v1.0.86  |  Updated June 17, 2026";
  position: fixed;
  right: max(0.8rem, env(safe-area-inset-right));
  bottom: max(0.8rem, env(safe-area-inset-bottom));
  z-index: 20;
  border: 1px solid rgba(0, 167, 111, 0.2);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.86);
  padding: 0.55rem 0.7rem;
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(14px);
  color: var(--brand-black);
  font-size: 0.76rem;
  font-weight: 950;
  pointer-events: none;
}

.topbar,
.shell,
.product-footer,
.alpha-gate,
.desktop-tab-jump,
.app-update-banner {
  position: relative;
  z-index: 1;
}

body.alpha-locked {
  overflow: hidden;
}

body.dashboard-active {
  overflow-x: hidden;
  background:
    radial-gradient(circle at 7% 0%, rgba(22, 163, 74, 0.18), transparent 24rem),
    linear-gradient(135deg, #071110 0%, #edf6f2 22%, #f8fbfa 100%);
}

body.dashboard-active .topbar,
body.dashboard-active .product-footer,
body.dashboard-active .desktop-tab-jump {
  display: none;
}

body:has(#appView:not([hidden])) .desktop-tab-jump,
body:has(#appView:not([hidden])) .home-page,
body:has(#appView:not([hidden])) #homeDashboard,
body:has(#appView:not([hidden])) .dashboard-rail {
  display: none !important;
}

body.dashboard-active .shell {
  width: 100%;
  max-width: none;
  padding: 0;
}

button,
input,
select,
textarea {
  font: inherit;
}

[hidden] {
  display: none !important;
}

button {
  cursor: pointer;
}

svg {
  width: 1.15rem;
  height: 1.15rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 5.25rem;
  padding: 0.72rem max(1rem, env(safe-area-inset-left)) 0.72rem max(1rem, env(safe-area-inset-right));
  border-bottom: 1px solid rgba(0, 167, 111, 0.18);
  background:
    linear-gradient(135deg, rgba(8, 19, 18, 0.96), rgba(5, 54, 48, 0.96) 58%, rgba(6, 112, 95, 0.92));
  color: #f8fffb;
  backdrop-filter: blur(14px);
  box-shadow: 0 18px 44px rgba(8, 19, 18, 0.16);
}

body.is-standalone .topbar {
  padding-top: max(0.72rem, env(safe-area-inset-top));
}

.topbar > div:first-child {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  grid-template-areas:
    "brand eyebrow"
    "brand title"
    "brand line";
  align-items: center;
  column-gap: 0.85rem;
  min-width: 0;
}

.topbar > div:first-child .eyebrow {
  grid-area: eyebrow;
  margin: 0;
}

.topbar > div:first-child .brand-name {
  grid-area: brand;
  min-width: 7.4rem;
}

.topbar > div:first-child h1 {
  grid-area: title;
}

.topbar > div:first-child .site-line {
  grid-area: line;
}

.eyebrow {
  margin: 0 0 0.15rem;
  color: var(--brand-bright);
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
}

.brand-name {
  display: flex;
  align-items: baseline;
  margin-bottom: 0.12rem;
  font-size: clamp(1.45rem, 3vw, 2.1rem);
  font-weight: 900;
  line-height: 0.95;
}

.brand-name span:first-child {
  color: var(--brand-bright);
}

.brand-name span:last-child {
  color: #ffffff;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  font-size: clamp(1.1rem, 2.4vw, 1.55rem);
  line-height: 1.05;
}

.site-line {
  margin-top: 0.18rem;
  color: rgba(236, 253, 245, 0.78);
  font-size: 0.78rem;
  font-weight: 700;
}

h2 {
  font-size: 1rem;
}

.topbar-actions,
.data-actions,
.card-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.topbar-actions {
  min-width: max-content;
}

.topbar .icon-button,
.topbar .text-button,
.topbar .primary-button {
  border-color: rgba(236, 253, 245, 0.24);
  background: rgba(255, 255, 255, 0.1);
  color: #f8fffb;
}

.topbar .icon-button:hover,
.topbar .text-button:hover,
.topbar .primary-button:hover {
  border-color: rgba(34, 197, 94, 0.58);
  background: rgba(34, 197, 94, 0.22);
}

.shell {
  width: min(1240px, 100%);
  margin: 0 auto;
  padding: 1.25rem;
}

.desktop-tab-jump {
  display: none;
  align-items: center;
  gap: 0.4rem;
  min-height: 2.6rem;
  border: 1px solid rgba(236, 253, 245, 0.24);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  padding: 0.28rem 0.36rem 0.28rem 0.72rem;
  box-shadow: none;
}

.desktop-tab-jump span {
  color: rgba(236, 253, 245, 0.78);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.desktop-tab-jump select {
  min-width: 9.2rem;
  min-height: 2rem;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--brand-black);
  font-size: 0.85rem;
  font-weight: 850;
  padding: 0 0.65rem;
}

.app-update-banner {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 60;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto auto;
  align-items: center;
  gap: 0.65rem;
  width: min(720px, calc(100% - 2rem));
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.96);
  padding: 0.85rem;
  box-shadow: 0 24px 64px rgba(8, 19, 18, 0.22);
}

.app-update-banner div {
  display: grid;
  gap: 0.15rem;
}

.app-update-banner strong {
  color: var(--brand-black);
}

.app-update-banner span {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 750;
}

.alpha-gate {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 1rem;
  background:
    radial-gradient(circle at 50% 0%, rgba(34, 197, 94, 0.24), transparent 24rem),
    rgba(245, 250, 247, 0.96);
  backdrop-filter: blur(10px);
}

.alpha-gate[hidden] {
  display: none;
}

.alpha-panel {
  display: grid;
  width: min(100%, 520px);
  gap: 0.85rem;
  border: 1px solid rgba(0, 167, 111, 0.2);
  border-radius: 24px;
  background: var(--card-gradient);
  padding: 1.1rem;
  box-shadow: var(--shadow);
}

.alpha-panel p {
  color: var(--muted);
  line-height: 1.45;
}

.alpha-consent {
  align-items: flex-start;
  border: 1px solid rgba(0, 167, 111, 0.16);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  padding: 0.75rem;
}

.home-page {
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  min-height: calc(100vh - 9rem);
  padding: 2rem 0.5rem;
  text-align: center;
}

.home-page.dashboard-mode {
  display: block;
  min-height: 100vh;
  padding: 0;
  text-align: left;
}

.home-page.dashboard-mode > .home-brand,
.home-page.dashboard-mode > p,
.home-page.dashboard-mode .login-flow-tools,
.home-page.dashboard-mode .manager-tools-panel {
  display: none;
}

.home-page.dashboard-mode .current-client-panel {
  display: none;
}

.home-page.dashboard-mode .home-actions {
  display: none;
}

.home-page.dashboard-mode .home-completed-summary {
  display: none;
}

.home-brand {
  display: flex;
  justify-content: center;
  align-items: baseline;
  font-size: clamp(3.6rem, 14vw, 7.5rem);
  font-weight: 950;
  line-height: 0.9;
}

.home-brand span:first-child {
  color: var(--brand);
}

.home-brand span:last-child {
  color: #111827;
}

.home-page p {
  margin: 0.85rem 0 1.5rem;
  color: var(--muted);
  font-size: clamp(1rem, 3vw, 1.25rem);
  font-weight: 750;
}

.login-flow-tools {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.login-flow-tools + .current-client-panel,
.login-flow-tools ~ .login-panel,
.login-flow-tools ~ .home-actions,
.login-flow-tools ~ .manager-tools-panel,
.login-flow-tools ~ .ops-dashboard {
  position: relative;
  z-index: 1;
}

.flying-tool {
  position: absolute;
  display: block;
  width: 5.2rem;
  height: 5.2rem;
  opacity: 0.18;
  animation: toolFly 12s linear infinite;
}

.flying-tool:nth-child(1) {
  left: -8rem;
  top: 18%;
}

.flying-tool:nth-child(2) {
  left: 105%;
  top: 34%;
  animation-name: toolFlyReverse;
  animation-duration: 15s;
}

.flying-tool:nth-child(3) {
  left: -10rem;
  top: 68%;
  animation-duration: 17s;
  animation-delay: -5s;
}

.flying-tool:nth-child(4) {
  left: 94%;
  top: 78%;
  animation-name: toolFlyReverse;
  animation-duration: 13s;
  animation-delay: -3s;
}

.small-tool {
  width: 3.6rem;
  height: 3.6rem;
  opacity: 0.16;
}

.tool-wrench::before,
.tool-wrench::after {
  content: "";
  position: absolute;
  background: linear-gradient(135deg, var(--brand), var(--brand-black));
}

.tool-wrench::before {
  left: 46%;
  top: 12%;
  width: 0.72rem;
  height: 76%;
  border-radius: 999px;
  transform: rotate(42deg);
}

.tool-wrench::after {
  left: 54%;
  top: 2%;
  width: 1.85rem;
  height: 1.85rem;
  border: 0.5rem solid var(--brand);
  border-right-color: transparent;
  border-radius: 50%;
  background: transparent;
  transform: rotate(34deg);
}

.tool-nut {
  clip-path: polygon(25% 4%, 75% 4%, 100% 50%, 75% 96%, 25% 96%, 0 50%);
  background: linear-gradient(135deg, var(--brand-black), var(--brand-bright));
}

.tool-nut::after {
  content: "";
  position: absolute;
  inset: 31%;
  border-radius: 50%;
  background: var(--surface);
}

@keyframes toolFly {
  0% {
    transform: translate3d(0, 2rem, 0) rotate(0deg);
  }
  100% {
    transform: translate3d(calc(100vw + 14rem), -6rem, 0) rotate(540deg);
  }
}

@keyframes toolFlyReverse {
  0% {
    transform: translate3d(0, -1rem, 0) rotate(0deg);
  }
  100% {
    transform: translate3d(calc(-100vw - 14rem), 5rem, 0) rotate(-520deg);
  }
}

.home-actions {
  display: grid;
  width: min(100%, 360px);
  gap: 0.75rem;
}

.home-actions[hidden] {
  display: none;
}

.admin-welcome {
  margin-bottom: 0.35rem;
  color: var(--ink);
  font-size: clamp(1.65rem, 6vw, 2.8rem);
  font-weight: 950;
  line-height: 1.05;
}

.manager-tools-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.8fr);
  gap: 1rem;
  width: min(100%, 760px);
  margin: 1rem auto 0;
  border: 1px solid rgba(20, 184, 132, 0.26);
  border-radius: 22px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(236, 253, 245, 0.92)),
    radial-gradient(circle at 88% 4%, rgba(20, 184, 132, 0.18), transparent 15rem);
  padding: 1rem;
  box-shadow: var(--shadow-soft);
  text-align: left;
}

.manager-tools-panel[hidden] {
  display: none;
}

.manager-tools-panel h2 {
  margin: 0.25rem 0;
  color: var(--ink);
  font-size: clamp(1.25rem, 3vw, 2rem);
  line-height: 1.05;
}

.manager-tools-panel p:not(.eyebrow) {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.manager-tool-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
}

.manager-tool-grid a {
  display: grid;
  min-height: 3.4rem;
  place-items: center;
  border: 1px solid rgba(20, 184, 132, 0.22);
  border-radius: 16px;
  background: #ffffff;
  color: var(--brand-dark);
  font-size: 0.86rem;
  font-weight: 900;
  text-align: center;
  text-decoration: none;
}

.manager-tool-grid a:hover {
  border-color: var(--brand);
  background: #ecfdf5;
}

.home-completed-summary {
  display: grid;
  width: min(100%, 620px);
  gap: 0.75rem;
  margin-top: 1.25rem;
  text-align: left;
}

.ops-dashboard {
  display: grid;
  width: 100%;
  gap: 0;
  margin-top: 0;
  text-align: left;
}

.ops-dashboard[hidden] {
  display: none;
}

.tablet-dashboard {
  grid-template-columns: 15.5rem minmax(0, 1fr);
  gap: 0;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: #0d1a1b;
  box-shadow: none;
  transition: grid-template-columns 220ms ease;
}

.home-page.dashboard-mode .tablet-dashboard {
  width: 100%;
  min-height: 100vh;
  margin: 0;
}

body.dashboard-rail-collapsed .home-page.dashboard-mode .tablet-dashboard,
.home-page.dashboard-mode .tablet-dashboard:has(.dashboard-rail.is-collapsed) {
  grid-template-columns: 4.85rem minmax(0, 1fr);
}

.dashboard-rail {
  display: grid;
  align-content: start;
  gap: 1.15rem;
  min-height: 100vh;
  background:
    linear-gradient(180deg, rgba(7, 19, 18, 0.98) 0%, rgba(12, 35, 31, 0.99) 58%, rgba(8, 19, 18, 1) 100%),
    radial-gradient(circle at 50% 4%, rgba(22, 163, 74, 0.34), transparent 19rem);
  border-right: 1px solid rgba(167, 243, 208, 0.12);
  padding: 1rem 0.9rem;
  color: #e6f4f1;
  box-shadow: 14px 0 34px rgba(15, 23, 42, 0.12);
  transition: padding 220ms ease;
}

.rail-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 2.75rem;
  border: 1px solid rgba(134, 239, 172, 0.32);
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(22, 163, 74, 0.22), rgba(255, 255, 255, 0.08));
  color: #eafff2;
  cursor: pointer;
  font-size: 0.76rem;
  font-weight: 950;
  letter-spacing: 0;
  text-transform: uppercase;
}

.rail-toggle::before {
  content: "";
  width: 1rem;
  height: 0.72rem;
  border-top: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  box-shadow: 0 -5px 0 -3px currentColor inset;
}

.rail-toggle span {
  margin-left: 0.45rem;
}

.rail-brand {
  padding: 0 0.55rem;
  color: #ffffff;
  font-size: 1.42rem;
  font-weight: 950;
  letter-spacing: 0;
  text-shadow: 0 10px 24px rgba(0, 0, 0, 0.24);
}

.rail-brand::first-letter {
  color: var(--brand-bright);
}

.dashboard-rail nav {
  display: grid;
  gap: 0.35rem;
}

.dashboard-rail a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 0.82rem 0.95rem;
  color: #d1e6e1;
  font-size: 0.92rem;
  font-weight: 850;
  text-decoration: none;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.dashboard-rail a.is-active,
.dashboard-rail a:hover {
  border-color: rgba(52, 211, 153, 0.28);
  background: linear-gradient(135deg, var(--brand), #10b981);
  color: #fff;
  transform: none;
}

.dashboard-rail.is-collapsed {
  justify-items: center;
  padding: 1rem 0.55rem;
}

.dashboard-rail.is-collapsed .rail-toggle {
  width: 3.1rem;
  padding: 0;
}

.dashboard-rail.is-collapsed .rail-toggle span,
.dashboard-rail.is-collapsed nav {
  display: none;
}

.dashboard-rail.is-collapsed .rail-brand {
  align-self: stretch;
  justify-self: stretch;
  display: grid;
  place-items: center;
  min-height: calc(100vh - 5.2rem);
  padding: 0;
  border: 1px solid rgba(134, 239, 172, 0.18);
  border-radius: 999px;
  background:
    linear-gradient(180deg, rgba(22, 163, 74, 0.18), rgba(8, 19, 18, 0.62)),
    rgba(255, 255, 255, 0.04);
  color: transparent;
  font-size: clamp(2.25rem, 5.8vh, 4.8rem);
  writing-mode: vertical-rl;
  text-orientation: mixed;
  text-transform: uppercase;
  background-clip: padding-box;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04), 0 18px 38px rgba(0, 0, 0, 0.18);
}

.dashboard-rail.is-collapsed .rail-brand::before {
  content: "FIXFLOW";
  background: linear-gradient(180deg, #22c55e 0%, #eafff2 28%, #0f766e 56%, #081312 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 12px 18px rgba(0, 0, 0, 0.22));
}

.dashboard-rail.is-collapsed .rail-brand {
  font-size: 0;
}

.dashboard-board {
  display: grid;
  gap: 1.15rem;
  align-content: start;
  min-height: 100vh;
  background:
    linear-gradient(90deg, rgba(8, 19, 18, 0.05), transparent 16rem),
    radial-gradient(circle at 18% 0%, rgba(34, 197, 94, 0.14), transparent 34rem),
    radial-gradient(circle at 88% 12%, rgba(0, 167, 111, 0.1), transparent 28rem),
    linear-gradient(180deg, #fbfefd 0%, #eef8f2 100%);
  padding: 1.45rem;
}

.dashboard-welcome {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  border: 1px solid rgba(20, 184, 132, 0.26);
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(20, 184, 132, 0.12), rgba(17, 24, 39, 0.06));
  padding: 0.95rem 1rem;
  box-shadow: 0 16px 38px rgba(8, 19, 18, 0.08);
}

.dashboard-welcome strong {
  color: var(--brand-black);
  font-size: clamp(1.3rem, 3vw, 2rem);
  font-weight: 950;
}

.dashboard-welcome span {
  color: var(--brand-dark);
  font-size: 0.88rem;
  font-weight: 900;
}

.dashboard-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 28px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(242, 253, 247, 0.84));
  padding: 1.05rem 1.15rem;
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(16px);
}

.dashboard-topline h2 {
  color: var(--brand-black);
  font-size: 1.55rem;
}

.dashboard-topline .eyebrow {
  color: var(--brand);
}

.dashboard-search {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: min(100%, 22rem);
  border: 1px solid rgba(15, 118, 110, 0.22);
  border-radius: 999px;
  background: #fff;
  padding: 0.58rem 0.8rem;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.7);
}

.dashboard-search span {
  color: var(--brand-dark);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.dashboard-search input {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--ink);
  font-size: 0.84rem;
}

.dashboard-grid {
  display: grid;
  gap: 1rem;
}

.top-grid {
  grid-template-columns: 1.35fr 1fr 1fr 1.25fr;
}

.lower-grid {
  grid-template-columns: 1.05fr 1.05fr 1.3fr;
}

.dash-card {
  display: grid;
  min-height: 11.25rem;
  gap: 0.75rem;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(0, 167, 111, 0.14);
  border-radius: 26px;
  background: var(--card-gradient);
  padding: 1.05rem;
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(14px);
}

.dash-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: linear-gradient(90deg, var(--brand-bright), var(--brand), transparent);
  opacity: 0.74;
}

.work-order-total {
  border-color: rgba(34, 197, 94, 0.22);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.99) 0%, rgba(232, 255, 242, 0.92) 100%);
}

.insights-card {
  min-height: 13rem;
}

.dash-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.dash-heading span {
  color: var(--brand-dark);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.dash-heading strong {
  color: var(--brand-black);
  font-size: 1.65rem;
  line-height: 1;
}

.mini-points {
  display: grid;
  gap: 0.55rem;
}

.mini-points div,
.dash-list span,
.status-legend span {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  border: 1px solid rgba(0, 167, 111, 0.1);
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(242, 253, 247, 0.64));
  padding: 0.52rem 0.6rem;
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 800;
}

.status-legend span {
  align-items: center;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
}

.status-legend i {
  width: 0.68rem;
  height: 0.68rem;
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(15, 23, 42, 0.04);
}

.status-legend b,
.status-legend em {
  color: var(--ink);
  font-style: normal;
}

.mini-points span,
.dash-list p,
.dispatch-detail p {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 750;
}

.dash-list,
.status-legend,
.tech-insights {
  display: grid;
  gap: 0.45rem;
}

.chart-card {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 1.05rem;
  min-height: 12rem;
}

.pie-chart {
  position: relative;
  width: 9.3rem;
  aspect-ratio: 1;
  border-radius: 50%;
  border: 14px solid #fafffb;
  background: #e5e7eb;
  box-shadow:
    inset 0 0 0 1px rgba(148, 163, 184, 0.2),
    inset 0 0 0 999px rgba(255, 255, 255, 0.02),
    0 16px 34px rgba(8, 19, 18, 0.11);
}

.pie-chart::after {
  content: "";
  position: absolute;
  inset: 24%;
  border-radius: inherit;
  background:
    radial-gradient(circle at 50% 38%, rgba(22, 163, 74, 0.12), transparent 48%),
    #ffffff;
  box-shadow: inset 0 1px 4px rgba(15, 23, 42, 0.08);
}

.chart-info {
  display: grid;
  align-content: center;
  gap: 0.75rem;
  min-width: 0;
}

.chart-card p {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 750;
  line-height: 1.45;
  text-align: left;
}

.dash-card select {
  min-height: 2.45rem;
  border: 1px solid rgba(15, 118, 110, 0.18);
  border-radius: 14px;
  background: #fff;
  padding: 0.45rem 0.55rem;
  color: var(--ink);
  font-weight: 800;
}

.dispatch-detail dl {
  display: grid;
  gap: 0.45rem;
  margin: 0;
}

.dispatch-detail div {
  display: grid;
  grid-template-columns: 5rem 1fr;
  gap: 0.5rem;
  border-bottom: 1px solid #edf1ef;
  padding-bottom: 0.35rem;
}

.dispatch-detail dt {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.dispatch-detail dd {
  margin: 0;
  color: var(--ink);
  font-size: 0.84rem;
  font-weight: 800;
}

.insights-card {
  min-height: 13rem;
}

.tech-insight {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 7rem;
  align-items: center;
  gap: 0.75rem;
  border: 1px solid rgba(15, 118, 110, 0.14);
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(242, 253, 247, 0.86));
  padding: 0.82rem 0.9rem;
  box-shadow: 0 10px 24px rgba(8, 19, 18, 0.045);
}

.tech-insight div {
  display: grid;
  gap: 0.15rem;
}

.tech-insight strong {
  color: var(--ink);
  font-size: 1rem;
}

.tech-insight span {
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 750;
}

.mini-line {
  width: 7rem;
  height: 3.3rem;
  overflow: visible;
}

.mini-line polyline {
  fill: none;
  stroke: var(--brand);
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.dashboard-locked .dashboard-search input,
.dashboard-locked .dash-card select {
  pointer-events: none;
  opacity: 0.58;
}

@media (min-width: 900px) {
  .desktop-tab-jump {
    display: inline-flex;
  }
}

@media (max-width: 980px) {
  .tablet-dashboard {
    grid-template-columns: 1fr;
  }

  .dashboard-rail {
    min-height: 0;
    padding: 0.9rem;
  }

  .dashboard-rail nav {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .dashboard-board {
    min-height: auto;
    padding: 1rem;
  }

  .top-grid,
  .lower-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .home-page.dashboard-mode {
    min-height: 100vh;
  }

  .home-page.dashboard-mode .tablet-dashboard,
  body.dashboard-rail-collapsed .home-page.dashboard-mode .tablet-dashboard,
  .home-page.dashboard-mode .tablet-dashboard:has(.dashboard-rail.is-collapsed) {
    grid-template-columns: 1fr;
  }

  .dashboard-rail {
    display: none;
  }

  .dashboard-topline {
    align-items: stretch;
    flex-direction: column;
    border-radius: 18px;
  }

  .dashboard-rail nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .top-grid,
  .lower-grid {
    grid-template-columns: 1fr;
  }

  .chart-card {
    grid-template-columns: 1fr;
  }

  .pie-chart {
    justify-self: center;
  }

  .tech-insight {
    grid-template-columns: 1fr;
  }

  .dash-card {
    border-radius: 18px;
  }
}

.home-completed-summary[hidden] {
  display: none;
}

.home-completed-summary h2 {
  text-align: center;
}

.home-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.6rem;
}

.home-summary-grid article {
  display: grid;
  gap: 0.3rem;
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 24px;
  background: var(--card-gradient);
  padding: 0.8rem;
  box-shadow: var(--shadow-soft);
  text-align: center;
}

.home-summary-grid span {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
}

.home-summary-grid strong {
  color: var(--ink);
  font-size: 1.3rem;
}

.login-panel {
  display: grid;
  width: min(100%, 360px);
  gap: 0.75rem;
  margin-bottom: 1rem;
  border: 1px solid rgba(0, 167, 111, 0.2);
  border-radius: 24px;
  background: var(--card-gradient);
  padding: 1rem;
  box-shadow: var(--shadow-soft);
}

.login-panel[hidden] {
  display: none;
}

.login-panel label {
  text-align: left;
}

.login-error {
  min-height: 1.15rem;
  color: var(--red);
  font-size: 0.82rem;
  font-weight: 800;
}

.register-name-grid {
  gap: 0.55rem;
}

.app-version-badge {
  position: fixed;
  right: max(0.8rem, env(safe-area-inset-right));
  bottom: max(0.8rem, env(safe-area-inset-bottom));
  display: grid;
  gap: 0.1rem;
  border: 1px solid rgba(0, 167, 111, 0.2);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.86);
  padding: 0.55rem 0.7rem;
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(14px);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  text-align: right;
}

.app-version-badge strong {
  color: var(--brand-black);
  font-size: 0.82rem;
  font-weight: 950;
}

.app-version-badge span {
  color: var(--brand-dark);
}

.alpha-version-line {
  margin-top: 0.75rem;
  color: var(--brand-dark);
  font-size: 0.82rem;
  font-weight: 850;
}

.product-footer {
  display: grid;
  gap: 0.25rem;
  width: min(100%, 620px);
  margin: -2.2rem auto 1rem;
  padding: 0 1rem;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.45;
  text-align: center;
}

.product-footer strong {
  color: var(--ink);
}

.product-footer a {
  color: var(--brand-dark);
  font-weight: 800;
}

.home-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  min-height: 4rem;
  border: 1px solid rgba(0, 167, 111, 0.2);
  border-radius: 22px;
  background: var(--card-gradient);
  color: var(--ink);
  box-shadow: var(--shadow-soft);
  font-size: 1.05rem;
  font-weight: 900;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.home-action[hidden] {
  display: none;
}

.home-action svg {
  width: 1.35rem;
  height: 1.35rem;
}

.active-action {
  border-color: var(--brand-bright);
  background: linear-gradient(135deg, var(--brand-bright), var(--brand));
  color: #fff;
}

.completed-action {
  border-color: var(--brand-black);
  background: linear-gradient(135deg, var(--brand-black), #14302b);
  color: #ffffff;
}

.admin-action {
  border-color: var(--brand-black);
  background: rgba(255, 255, 255, 0.9);
  color: var(--brand-black);
}

.mode-action {
  border-color: var(--brand-dark);
  background: #ecfdf5;
  color: var(--brand-dark);
}

.home-action:hover {
  transform: none;
  box-shadow: 0 18px 42px rgba(8, 19, 18, 0.12);
}

.install-action {
  border-color: var(--brand-black);
  background: linear-gradient(135deg, var(--brand-black), var(--brand-dark));
  color: #fff;
}

.install-note {
  min-height: 1.1rem;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 750;
}

.admin-app {
  background: var(--surface-gradient);
}

.admin-header-icon {
  width: 3.4rem;
  height: 3.4rem;
  border-radius: 18px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
}

.admin-back,
.admin-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.65rem;
  border: 1px solid rgba(0, 167, 111, 0.28);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  padding: 0.55rem 0.8rem;
  color: var(--brand-dark);
  font-size: 0.84rem;
  font-weight: 850;
  text-decoration: none;
}

.admin-shell {
  display: grid;
  width: min(760px, 100%);
  margin: 0 auto;
  gap: 1rem;
  padding: 1rem;
}

.admin-panel {
  display: grid;
  gap: 0.75rem;
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 24px;
  background: var(--card-gradient);
  padding: 1rem;
  box-shadow: var(--shadow-soft);
}

.admin-panel p {
  color: var(--muted);
  line-height: 1.45;
}

.admin-login {
  width: min(420px, 100%);
  margin: 2rem auto;
}

.admin-tools[hidden],
.admin-login[hidden] {
  display: none;
}

.main-admin-only[hidden] {
  display: none;
}

.super-admin-only[hidden] {
  display: none;
}

.admin-search {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.6rem;
}

.admin-result {
  min-height: 2.5rem;
  border: 1px solid rgba(0, 167, 111, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  padding: 0.7rem;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.admin-log-list {
  display: grid;
  gap: 0.55rem;
  max-height: 28rem;
  overflow: auto;
}

.admin-log-item {
  border: 1px solid rgba(0, 167, 111, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.74);
  padding: 0.65rem;
}

.admin-log-item strong,
.admin-log-item span {
  display: block;
}

.admin-log-item span {
  margin-top: 0.15rem;
  color: var(--muted);
  font-size: 0.8rem;
}

.admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.parts-action {
  border-color: var(--brand);
  color: var(--brand-dark);
}

.current-client {
  color: var(--brand-dark);
  font-weight: 900;
}

.current-client-panel {
  display: grid;
  gap: 0.25rem;
  width: min(100%, 520px);
  margin: 0.85rem auto 0;
  border: 1px solid rgba(34, 197, 94, 0.28);
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(236, 253, 245, 0.96), rgba(255, 255, 255, 0.78));
  padding: 0.75rem;
  color: var(--brand-dark);
}

.current-client-panel[hidden] {
  display: none;
}

.current-client-panel strong {
  font-size: 1.2rem;
}

.current-client-panel span {
  color: var(--ink);
  font-size: 0.85rem;
  font-weight: 750;
}

.clients-shell {
  display: grid;
  width: min(1000px, 100%);
  margin: 0 auto;
  gap: 1rem;
  padding: 1.15rem;
}

.client-intro {
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 28px;
  background: var(--card-gradient);
  padding: 1.1rem;
  box-shadow: var(--shadow-soft);
  text-align: center;
}

.client-intro p {
  margin-top: 0.35rem;
  color: var(--muted);
}

.clients-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
}

.client-card {
  display: grid;
  gap: 0.65rem;
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 24px;
  background: var(--card-gradient);
  padding: 1rem;
  box-shadow: var(--shadow-soft);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.client-card:hover {
  border-color: rgba(34, 197, 94, 0.36);
  box-shadow: 0 16px 38px rgba(8, 19, 18, 0.11);
  transform: translateY(-1px);
}

.client-card.is-current {
  border-color: var(--brand-bright);
  border-width: 1px;
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.16), var(--shadow-soft);
}

.client-card p,
.client-card span {
  color: var(--muted);
}

.client-card .client-contact {
  color: var(--ink);
  font-weight: 800;
}

.client-card span {
  font-size: 0.78rem;
  font-weight: 850;
}

.parts-shell {
  display: grid;
  width: min(1000px, 100%);
  margin: 0 auto;
  gap: 1rem;
  padding: 1.15rem;
}

.parts-index-list {
  display: grid;
  gap: 0.75rem;
}

.parts-filters {
  display: grid;
  grid-template-columns: minmax(180px, 260px) minmax(0, 1fr);
  gap: 0.75rem;
  align-items: end;
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 24px;
  background: var(--card-gradient);
  padding: 0.9rem;
  box-shadow: var(--shadow-soft);
}

.parts-area-group {
  overflow: hidden;
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 24px;
  background: var(--card-gradient);
  box-shadow: var(--shadow-soft);
}

.parts-area-group summary {
  cursor: pointer;
  padding: 0.95rem 1.05rem;
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.18), rgba(255, 255, 255, 0.72));
  color: var(--brand-dark);
  font-weight: 900;
}

.parts-area-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  border-top: 1px solid var(--line);
  padding: 0.75rem;
}

.part-index-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.75rem;
  border: 1px solid rgba(0, 167, 111, 0.14);
  border-radius: 20px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(236, 253, 245, 0.7));
  padding: 0.85rem;
  box-shadow: 0 8px 20px rgba(8, 19, 18, 0.04);
}

.part-index-card span,
.part-index-card p {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 750;
}

.part-index-card h2 {
  margin: 0.2rem 0;
}

.part-index-card dl {
  display: grid;
  grid-template-columns: repeat(2, minmax(90px, 1fr));
  gap: 0.45rem;
  margin: 0;
}

.part-index-card dl div {
  border-radius: 16px;
  background: rgba(236, 253, 245, 0.8);
  padding: 0.55rem;
}

.web-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1rem;
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-left: 6px solid var(--brand-bright);
  border-radius: 24px;
  background: var(--card-gradient);
  padding: 0.75rem 0.9rem;
  box-shadow: var(--shadow-soft);
}

.app-nav {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: thin;
  margin-bottom: 1rem;
  border: 1px solid rgba(0, 167, 111, 0.16);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.82);
  padding: 0.45rem;
  box-shadow: var(--shadow-soft);
}

.app-nav-home {
  max-width: 220px;
}

.app-nav a {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 2.75rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 850;
  text-align: center;
  text-decoration: none;
  box-shadow: none;
  white-space: nowrap;
}

.nav-icon {
  display: inline-grid;
  width: 1.7rem;
  height: 1.7rem;
  place-items: center;
  border-radius: 999px;
  background: rgba(0, 167, 111, 0.1);
  color: var(--brand-dark);
  font-size: 1rem;
  line-height: 1;
}

.app-nav a:hover {
  border-color: rgba(34, 197, 94, 0.28);
  background: rgba(236, 253, 245, 0.86);
}

.app-nav a.is-active {
  border-color: var(--brand-bright);
  background: linear-gradient(135deg, var(--brand-bright), var(--brand));
  color: #fff;
}

.app-nav a.is-active .nav-icon {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.web-status div {
  display: grid;
  gap: 0.12rem;
}

.web-status strong {
  font-size: 0.92rem;
}

.web-status span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.web-status-actions {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.5rem;
}

#appView .app-nav {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  z-index: 12;
  display: grid;
  align-content: start;
  gap: 0.26rem;
  width: 14.25rem;
  overflow-y: auto;
  overflow-x: hidden;
  border-right: 1px solid rgba(167, 243, 208, 0.12);
  border-radius: 0;
  background:
    linear-gradient(180deg, rgba(7, 19, 18, 0.98) 0%, rgba(12, 35, 31, 0.99) 58%, rgba(8, 19, 18, 1) 100%),
    radial-gradient(circle at 50% 4%, rgba(22, 163, 74, 0.34), transparent 19rem);
  padding: 0.8rem 0.65rem;
  box-shadow: 14px 0 34px rgba(15, 23, 42, 0.12);
  --active-nav-top: 5rem;
  --active-nav-left: 0.65rem;
  --active-nav-width: calc(100% - 1.3rem);
  --active-nav-height: 2.34rem;
}

#appView:not([hidden]) {
  display: block;
  position: relative;
}

@media (min-width: 901px) {
  body:has(#appView:not([hidden])) .shell {
    max-width: none;
    padding-left: calc(14.25rem + max(1.15rem, env(safe-area-inset-left)));
  }
}

#appView .app-nav::before {
  content: "FIXFLOW";
  display: block;
  margin: 0.1rem 0.55rem 0.5rem;
  background: linear-gradient(90deg, var(--brand-bright) 0 42%, #fff 42% 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-size: 1.24rem;
  font-weight: 950;
  letter-spacing: 0;
  text-shadow: 0 10px 24px rgba(0, 0, 0, 0.24);
}

#appView .app-nav-indicator {
  position: absolute;
  left: var(--active-nav-left);
  top: var(--active-nav-top);
  width: var(--active-nav-width);
  height: var(--active-nav-height);
  border: 1px solid rgba(52, 211, 153, 0.36);
  border-radius: 999px;
  background: linear-gradient(135deg, var(--brand), #10b981);
  box-shadow: 0 10px 22px rgba(6, 95, 70, 0.2);
  transform: translate3d(0, 0, 0);
  transition:
    top 220ms ease,
    left 220ms ease,
    width 220ms ease,
    height 220ms ease;
  pointer-events: none;
}

#appView .app-nav a {
  position: relative;
  z-index: 1;
  justify-content: flex-start;
  width: 100%;
  min-height: 2.34rem;
  border-color: transparent;
  padding: 0.52rem 0.68rem;
  color: #d1e6e1;
  font-size: 0.82rem;
  transition:
    color 180ms ease,
    border-color 180ms ease,
    background 180ms ease,
    box-shadow 180ms ease;
}

#appView .app-nav .nav-icon {
  flex: 0 0 auto;
  width: 1.45rem;
  height: 1.45rem;
  background: rgba(255, 255, 255, 0.08);
  color: #eafff2;
  font-size: 0.86rem;
}

#appView .app-nav a:hover,
#appView .app-nav a.is-active {
  border-color: transparent;
  background: transparent;
  color: #fff;
}

#appView .app-nav a:hover {
  background: rgba(255, 255, 255, 0.07);
}

#appView .app-nav a.is-active .nav-icon {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.app-transition-tools {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease;
}

#appView.is-tab-transitioning .app-transition-tools {
  opacity: 0.24;
}

#appView.is-tab-transitioning .workspace,
#appView.is-tab-transitioning .ops-page,
#appView.is-tab-transitioning .operations-hub,
#appView.is-tab-transitioning .form-panel,
#appView.is-tab-transitioning .stats {
  animation: appPanelFlow 520ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

@keyframes appPanelFlow {
  0% {
    opacity: 0.72;
    transform: translateY(10px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.web-status a {
  flex: 0 0 auto;
  border: 1px solid rgba(0, 167, 111, 0.24);
  border-radius: 999px;
  padding: 0.55rem 0.7rem;
  color: var(--brand-dark);
  font-size: 0.8rem;
  font-weight: 850;
  text-decoration: none;
}

.web-status a:hover {
  background: #e7f6f4;
}

.web-status .text-button {
  min-height: 2.25rem;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.stat {
  min-height: 5.75rem;
  padding: 1rem;
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-left: 6px solid var(--brand-bright);
  border-radius: 24px;
  background: var(--card-gradient);
  box-shadow: var(--shadow-soft);
}

.stat span {
  display: block;
  margin-bottom: 0.4rem;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.stat strong {
  font-size: clamp(1.5rem, 5vw, 2.1rem);
  line-height: 1;
}

.stat-progress {
  border-left-color: #38bdf8;
}

.stat-due {
  border-left-color: var(--amber);
}

.stat-cost {
  border-left-color: var(--green);
}

.workspace {
  display: grid;
  grid-template-columns: minmax(300px, 390px) minmax(0, 1fr);
  align-items: start;
  gap: 1rem;
}

.operations-hub {
  display: grid;
  gap: 0.8rem;
  margin-bottom: 1rem;
}

.ops-hub-heading,
.ops-tool {
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 26px;
  background: var(--card-gradient);
  box-shadow: var(--shadow-soft);
}

.ops-hub-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1rem;
}

.ops-hub-heading h2 {
  color: var(--brand-black);
  font-size: clamp(1rem, 1.8vw, 1.18rem);
}

.ops-hub-heading p:not(.eyebrow) {
  max-width: 52rem;
  margin-top: 0.18rem;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 750;
  line-height: 1.35;
}

.ops-hub-actions {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.5rem;
}

.ops-hub-body {
  display: grid;
  gap: 1rem;
}

.ops-hub-body[hidden] {
  display: none;
}

.ops-feature-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1rem;
}

.ops-feature-grid.lower-tools {
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.65fr);
}

.ops-tool {
  display: grid;
  align-content: start;
  gap: 0.85rem;
  min-width: 0;
  padding: 1rem;
}

.ops-tool-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.ops-tool-title span {
  color: var(--brand-dark);
  font-size: 0.78rem;
  font-weight: 950;
  text-transform: uppercase;
}

.ops-tool-title strong {
  color: var(--brand-black);
  font-size: 0.9rem;
}

.inline-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.stock-result,
.mobile-tech-ticket,
.thread-message,
.analytics-grid article {
  display: grid;
  gap: 0.3rem;
  border: 1px solid rgba(0, 167, 111, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  padding: 0.75rem;
}

.stock-result span,
.mobile-tech-ticket span,
.thread-message span,
.analytics-grid p,
.mobile-tech-list p,
.thread-list p {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 750;
}

.mobile-tech-list,
.thread-list {
  display: grid;
  gap: 0.6rem;
  max-height: 22rem;
  overflow: auto;
}

.mobile-tech-ticket textarea,
.comms-tool textarea {
  min-height: 4.6rem;
}

.analytics-grid {
  display: grid;
  gap: 0.6rem;
}

.analytics-grid span {
  color: var(--brand-dark);
  font-size: 0.72rem;
  font-weight: 950;
  text-transform: uppercase;
}

.analytics-grid strong {
  color: var(--brand-black);
  font-size: 1.45rem;
}

.kanban-board {
  display: grid;
  grid-auto-columns: minmax(210px, 1fr);
  grid-auto-flow: column;
  gap: 0.75rem;
  overflow-x: auto;
  padding-bottom: 0.25rem;
}

.kanban-column {
  display: grid;
  align-content: start;
  gap: 0.6rem;
  min-height: 14rem;
  border: 1px solid rgba(0, 167, 111, 0.12);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.62);
  padding: 0.75rem;
}

.kanban-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
}

.kanban-title strong {
  color: var(--brand-black);
  font-size: 0.9rem;
}

.kanban-title span {
  display: inline-grid;
  place-items: center;
  min-width: 1.65rem;
  min-height: 1.65rem;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-weight: 900;
}

.kanban-list {
  display: grid;
  gap: 0.55rem;
  min-height: 10rem;
}

.kanban-card {
  display: grid;
  gap: 0.18rem;
  width: 100%;
  border: 1px solid rgba(0, 167, 111, 0.14);
  border-radius: 16px;
  background: #ffffff;
  padding: 0.65rem;
  color: var(--ink);
  text-align: left;
  box-shadow: 0 8px 18px rgba(8, 19, 18, 0.045);
}

.kanban-card span,
.kanban-card em {
  color: var(--muted);
  font-size: 0.78rem;
  font-style: normal;
  font-weight: 750;
}

.thread-message.thread-customer {
  border-color: rgba(34, 197, 94, 0.28);
  background: rgba(236, 253, 245, 0.78);
}

.workspace.list-only {
  grid-template-columns: 1fr;
}

.ops-pages {
  display: grid;
  gap: 1rem;
  margin-bottom: 1rem;
}

.ops-page {
  display: grid;
  gap: 1rem;
}

.ops-page[hidden] {
  display: none;
}

.page-heading,
.triage-column,
.dispatch-queue,
.dispatch-lane,
.report-panel,
.report-metric {
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 26px;
  background: var(--card-gradient);
  box-shadow: var(--shadow-soft);
}

.page-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem;
}

.page-heading h2 {
  color: var(--brand-black);
  font-size: clamp(1.25rem, 3vw, 1.75rem);
}

.page-heading p:not(.eyebrow) {
  max-width: 64rem;
  margin-top: 0.25rem;
  color: var(--muted);
  font-weight: 750;
  line-height: 1.4;
}

.triage-board {
  display: grid;
  grid-template-columns: repeat(4, minmax(210px, 1fr));
  gap: 1rem;
  align-items: start;
}

.triage-column {
  display: grid;
  gap: 0.75rem;
  min-height: 20rem;
  padding: 0.85rem;
}

.triage-column-title,
.dispatch-lane-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.6rem;
}

.triage-column-title strong,
.dispatch-lane-title strong {
  color: var(--brand-black);
}

.triage-column-title span,
.dispatch-lane-title span,
.triage-list p,
.dispatch-queue p,
.dispatch-job-list p {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 750;
}

.triage-column-title em {
  display: inline-grid;
  place-items: center;
  min-width: 1.8rem;
  min-height: 1.8rem;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-style: normal;
  font-weight: 950;
}

.triage-list,
.dispatch-job-list,
#dispatchQueue,
.parts-trend-list {
  display: grid;
  gap: 0.65rem;
}

.triage-card,
.dispatch-card,
.parts-trend-item {
  display: grid;
  gap: 0.45rem;
  border: 1px solid rgba(0, 167, 111, 0.13);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  padding: 0.72rem;
  box-shadow: 0 8px 20px rgba(8, 19, 18, 0.045);
}

.triage-card strong,
.dispatch-card strong,
.parts-trend-item strong {
  color: var(--brand-black);
}

.triage-card span,
.dispatch-card span,
.parts-trend-item span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 750;
}

.triage-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.triage-meta span {
  border-radius: 999px;
  background: var(--brand-soft);
  padding: 0.18rem 0.5rem;
  color: var(--brand-dark);
  font-weight: 900;
}

.dispatch-layout {
  display: grid;
  grid-template-columns: minmax(260px, 0.36fr) minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
}

.dispatch-queue,
.dispatch-lane {
  display: grid;
  gap: 0.75rem;
  padding: 0.9rem;
}

.dispatch-lanes {
  display: grid;
  grid-template-columns: repeat(2, minmax(240px, 1fr));
  gap: 1rem;
}

.dispatch-assign-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.5rem;
  align-items: center;
}

.report-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.report-metric {
  display: grid;
  gap: 0.35rem;
  padding: 1rem;
}

.report-metric span,
.report-panel .ops-tool-title span {
  color: var(--brand-dark);
  font-size: 0.78rem;
  font-weight: 950;
  text-transform: uppercase;
}

.report-metric strong {
  color: var(--brand-black);
  font-size: clamp(1.45rem, 4vw, 2rem);
}

.report-metric p {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 750;
}

.simple-chart {
  display: grid;
  gap: 0.78rem;
  padding-top: 0.25rem;
}

.simple-chart div {
  display: grid;
  grid-template-columns: 6.8rem minmax(0, 1fr) minmax(4.2rem, auto);
  gap: 0.65rem;
  align-items: center;
}

.simple-chart em {
  color: var(--muted);
  font-size: 0.78rem;
  font-style: normal;
  font-weight: 850;
}

.simple-chart i {
  display: block;
  width: var(--bar-width);
  height: 1.05rem;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), var(--brand-bright));
  box-shadow: 0 8px 18px rgba(22, 163, 74, 0.16);
}

.simple-chart b {
  color: var(--brand-black);
  font-size: 0.78rem;
  text-align: right;
}

.simple-chart .trend-growth i {
  background: linear-gradient(90deg, #059669, #22c55e);
}

.simple-chart .trend-drop i {
  background: linear-gradient(90deg, #b91c1c, #ef4444);
  box-shadow: 0 8px 18px rgba(239, 68, 68, 0.16);
}

.simple-chart .trend-stagnant i {
  background: linear-gradient(90deg, #b45309, #f59e0b);
  box-shadow: 0 8px 18px rgba(245, 158, 11, 0.18);
}

.super-admin-chart {
  border-color: rgba(8, 19, 18, 0.18);
  background:
    linear-gradient(135deg, rgba(8, 19, 18, 0.04), rgba(236, 253, 245, 0.72)),
    var(--card-gradient);
}

.today-job-list {
  display: grid;
  gap: 1rem;
}

.today-job-card {
  display: grid;
  gap: 0.9rem;
  border: 1px solid rgba(0, 167, 111, 0.2);
  border-radius: 28px;
  background: var(--card-gradient);
  padding: 1rem;
  box-shadow: var(--shadow-soft);
}

.today-job-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0.75rem;
  align-items: start;
}

.today-job-head > span {
  display: grid;
  width: 2.6rem;
  height: 2.6rem;
  place-items: center;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--brand), var(--brand-bright));
  color: #fff;
  font-weight: 950;
}

.today-job-head strong {
  color: var(--brand-black);
  font-size: clamp(1.2rem, 5vw, 1.8rem);
}

.today-job-head p,
.today-job-log,
.ai-summary {
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 750;
}

.ai-summary {
  border-left: 4px solid var(--brand);
  background: rgba(236, 253, 245, 0.78);
  padding: 0.75rem;
}

.today-action-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
}

.today-action-grid button,
.today-upload {
  display: grid;
  min-height: 4rem;
  place-items: center;
  border: 1px solid rgba(0, 167, 111, 0.22);
  border-radius: 20px;
  background: #fff;
  color: var(--brand-black);
  font-weight: 950;
  text-align: center;
}

.today-action-grid button:last-child {
  grid-column: 1 / -1;
  background: linear-gradient(135deg, var(--brand), var(--brand-bright));
  color: #fff;
}

.today-upload input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.today-job-log {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.today-job-log span {
  border-radius: 999px;
  background: rgba(8, 19, 18, 0.06);
  padding: 0.35rem 0.55rem;
}

.report-panels {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
  gap: 1rem;
}

.report-panel {
  display: grid;
  gap: 0.8rem;
  padding: 1rem;
}

.report-table-wrap {
  overflow-x: auto;
}

.report-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.report-table th,
.report-table td {
  border-bottom: 1px solid rgba(0, 167, 111, 0.12);
  padding: 0.7rem 0.55rem;
  text-align: left;
}

.report-table th {
  color: var(--brand-dark);
  font-size: 0.76rem;
  text-transform: uppercase;
}

.module-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.72fr) minmax(0, 1.28fr);
  gap: 1rem;
  align-items: start;
}

.module-form,
.module-card,
.settings-version {
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 24px;
  background: var(--card-gradient);
  box-shadow: var(--shadow-soft);
}

.module-form {
  display: grid;
  gap: 0.75rem;
  padding: 1rem;
}

.module-form h3 {
  color: var(--brand-black);
}

.module-list {
  display: grid;
  gap: 0.75rem;
  min-width: 0;
}

.module-card {
  display: grid;
  gap: 0.75rem;
  padding: 1rem;
}

.module-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.module-card strong {
  color: var(--brand-black);
}

.module-card span,
.module-card p,
.settings-version span {
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 750;
}

.customer-sections {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
}

.customer-sections section {
  border: 1px solid rgba(8, 19, 18, 0.08);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.7);
  padding: 0.72rem;
}

.customer-sections h4 {
  margin: 0 0 0.25rem;
  color: var(--brand-dark);
  font-size: 0.78rem;
  font-weight: 950;
  text-transform: uppercase;
}

.linked-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.linked-list span {
  border-radius: 999px;
  background: var(--brand-soft);
  padding: 0.35rem 0.55rem;
  color: var(--brand-dark);
  font-size: 0.78rem;
  font-weight: 850;
}

.employee-points {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.invoice-total {
  border-color: rgba(0, 167, 111, 0.3);
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.14), rgba(255, 255, 255, 0.95));
}

.settings-version {
  display: grid;
  gap: 0.25rem;
  padding: 0.8rem;
}

.settings-version strong {
  color: var(--brand-black);
  font-size: 1rem;
}

.settings-priority-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.78);
  padding: 0.72rem;
  box-shadow: var(--shadow-soft);
}

.settings-priority-strip span {
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.15), rgba(255, 255, 255, 0.92));
  padding: 0.48rem 0.7rem;
  color: var(--brand-dark);
  font-size: 0.8rem;
  font-weight: 900;
}

.settings-console {
  display: grid;
  grid-template-columns: minmax(210px, 0.32fr) minmax(0, 1fr);
  gap: 0.85rem;
  align-items: start;
}

.settings-section-tabs,
.settings-detail {
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 24px;
  background: var(--card-gradient);
  box-shadow: var(--shadow-soft);
}

.settings-section-tabs {
  display: grid;
  gap: 0.4rem;
  padding: 0.55rem;
}

.settings-section-tabs button {
  display: grid;
  gap: 0.15rem;
  width: 100%;
  border: 1px solid transparent;
  border-radius: 16px;
  background: transparent;
  padding: 0.72rem 0.78rem;
  text-align: left;
}

.settings-section-tabs button span,
.settings-detail-head span {
  color: var(--brand-dark);
  font-size: 0.7rem;
  font-weight: 950;
  text-transform: uppercase;
}

.settings-section-tabs button strong,
.settings-detail-head strong {
  color: var(--brand-black);
  font-size: 0.94rem;
}

.settings-section-tabs button.is-active,
.settings-section-tabs button:hover {
  border-color: rgba(34, 197, 94, 0.28);
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.16), rgba(255, 255, 255, 0.92));
}

.settings-detail {
  display: grid;
  gap: 0.85rem;
  min-width: 0;
  padding: 0.9rem;
}

.settings-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.85rem;
  border-bottom: 1px solid rgba(0, 167, 111, 0.12);
  padding-bottom: 0.8rem;
}

.settings-detail-head > div:first-child {
  display: grid;
  gap: 0.25rem;
}

.settings-action-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.45rem;
}

.settings-action-row .primary-button,
.settings-action-row .text-button {
  min-height: 2.35rem;
  padding-inline: 0.78rem;
  font-size: 0.8rem;
}

.settings-subgrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.65rem;
}

.settings-form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.75rem;
}

.settings-form-grid label {
  display: grid;
  gap: 0.35rem;
}

.settings-toggle-list {
  display: grid;
  gap: 0.65rem;
}

.settings-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  border: 1px solid rgba(0, 167, 111, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  padding: 0.75rem 0.85rem;
}

.settings-toggle span,
.settings-form-grid label span {
  color: var(--brand-black);
  font-size: 0.84rem;
  font-weight: 850;
}

.settings-toggle input {
  width: 1.25rem;
  height: 1.25rem;
  accent-color: var(--brand);
}

.settings-list {
  display: grid;
  gap: 0.4rem;
  border: 1px solid rgba(0, 167, 111, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  padding: 0.75rem;
}

.settings-list span {
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 750;
}

.settings-subgrid section {
  border: 1px solid rgba(8, 19, 18, 0.08);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.74);
  padding: 0.75rem;
}

.settings-subgrid h3 {
  margin: 0 0 0.45rem;
  color: var(--brand-black);
  font-size: 0.86rem;
}

.settings-subgrid ul {
  display: grid;
  gap: 0.28rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.settings-subgrid li {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 750;
  line-height: 1.32;
}

.settings-subgrid li::before {
  content: "";
  display: inline-block;
  width: 0.42rem;
  height: 0.42rem;
  margin-right: 0.45rem;
  border-radius: 999px;
  background: var(--brand-bright);
  vertical-align: 0.08rem;
}

.settings-action-status {
  min-height: 1.1rem;
  color: var(--brand-dark);
  font-size: 0.84rem;
  font-weight: 850;
}

.settings-tier-super .settings-detail-head span,
.settings-tier-admin .settings-detail-head span {
  color: var(--brand-black);
}

.settings-tier-super {
  border-color: rgba(8, 19, 18, 0.18);
  background:
    linear-gradient(135deg, rgba(8, 19, 18, 0.05), rgba(236, 253, 245, 0.8)),
    var(--card-gradient);
}

.settings-tier-standout {
  border-color: rgba(34, 197, 94, 0.28);
}

.bug-status {
  min-height: 1.1rem;
  color: var(--brand-dark);
  font-size: 0.84rem;
  font-weight: 850;
}

.bug-card {
  border-color: rgba(239, 68, 68, 0.22);
}

.stack-card span,
.inventory-section-title span {
  display: block;
}

.role-access-panel {
  grid-column: 1 / -1;
}

.role-current-card,
.role-card {
  display: grid;
  gap: 0.45rem;
  border: 1px solid rgba(0, 167, 111, 0.16);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  padding: 0.85rem;
}

.role-current-card {
  border-color: rgba(0, 167, 111, 0.34);
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.13), rgba(255, 255, 255, 0.88));
}

.role-current-card span,
.role-card span {
  color: var(--brand-dark);
  font-size: 0.78rem;
  font-weight: 950;
  text-transform: uppercase;
}

.role-current-card strong,
.role-card strong {
  color: var(--brand-black);
  font-size: 1.05rem;
}

.role-current-card p {
  margin: 0;
  color: var(--muted);
  font-weight: 750;
}

.role-current-card ul,
.role-card ul {
  display: grid;
  gap: 0.25rem;
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 750;
}

.role-matrix {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}

.role-card.is-current-role {
  border-color: var(--brand);
  box-shadow: inset 0 0 0 1px rgba(0, 167, 111, 0.25);
}

.panel {
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 26px;
  background: var(--card-gradient);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(14px);
}

.form-panel {
  position: sticky;
  top: 5.3rem;
  display: grid;
  gap: 0.9rem;
  padding: 1rem;
}

.form-panel[hidden] {
  display: none;
}

.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.panel-heading h2 {
  color: var(--brand-black);
  font-size: 1.08rem;
}

.list-panel {
  min-width: 0;
  padding: 1rem;
}

.list-heading {
  margin-bottom: 0.85rem;
}

.list-heading p {
  margin-top: 0.15rem;
  color: var(--muted);
  font-size: 0.86rem;
}

.list-heading strong,
.section-title h3 {
  color: var(--brand-dark);
}

label {
  display: grid;
  gap: 0.35rem;
  color: var(--brand-dark);
  font-size: 0.82rem;
  font-weight: 750;
}

.check-label {
  align-content: end;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  min-height: 4.9rem;
  color: var(--ink);
}

.check-label input {
  width: 1.1rem;
  min-height: 1.1rem;
  accent-color: var(--brand);
}

.login-remember {
  min-height: auto;
}

input,
select,
textarea {
  width: 100%;
  min-height: 2.75rem;
  border: 1px solid rgba(0, 167, 111, 0.2);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--ink);
  outline: none;
  padding: 0.7rem 0.78rem;
}

textarea {
  min-height: 6.3rem;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--brand-bright);
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.18);
}

.two-col {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.primary-button,
.text-button,
.icon-button {
  border: 1px solid rgba(0, 167, 111, 0.2);
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  transform: none !important;
  transition:
    background 160ms ease,
    border-color 160ms ease,
    box-shadow 160ms ease,
    color 160ms ease;
  will-change: auto;
}

.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 2.9rem;
  border-color: var(--brand-bright);
  background: linear-gradient(135deg, var(--brand-bright), var(--brand));
  color: #fff;
  font-weight: 800;
  text-decoration: none;
}

.primary-button:hover {
  background: linear-gradient(135deg, #4ade80, var(--brand-dark));
}

.text-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.25rem;
  padding: 0 0.75rem;
  color: var(--brand-dark);
  font-weight: 800;
  text-decoration: none;
}

.icon-button {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  width: 2.6rem;
  height: 2.6rem;
  color: var(--brand-dark);
}

.icon-button:hover,
.text-button:hover {
  border-color: var(--brand-bright);
  background: #ecfdf5;
}

.module-form .primary-button,
.module-form .text-button,
.module-card .primary-button,
.module-card .text-button,
.ops-page .primary-button,
.ops-page .text-button {
  min-width: 0;
  white-space: normal;
  text-align: center;
  line-height: 1.15;
}

.blueprint-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.65rem;
  width: 100%;
}

.blueprint-pill {
  display: grid;
  gap: 0.28rem;
  min-height: 5.7rem;
  border: 1px solid rgba(0, 167, 111, 0.16);
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(236, 253, 245, 0.92), rgba(255, 255, 255, 0.96)),
    radial-gradient(circle at 100% 0%, rgba(34, 197, 94, 0.16), transparent 7rem);
  padding: 0.75rem;
}

.blueprint-pill strong {
  color: var(--brand-black);
  font-size: 0.9rem;
}

.blueprint-pill span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 750;
  line-height: 1.35;
}

.file-button input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.filters {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 150px 150px;
  gap: 0.65rem;
  margin-bottom: 1rem;
  border: 1px solid rgba(0, 167, 111, 0.14);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.72);
  padding: 0.65rem;
}

.search {
  position: relative;
  display: block;
}

.search svg {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  color: var(--muted);
  transform: translateY(-50%);
}

.search input {
  padding-left: 2.45rem;
}

.orders {
  display: grid;
  gap: 0.8rem;
}

.order-section {
  display: grid;
  gap: 0.7rem;
}

.order-section + .order-section {
  margin-top: 1.2rem;
  border-top: 1px solid var(--line);
  padding-top: 1rem;
}

.order-section[hidden] {
  display: none;
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.section-title h3 {
  font-size: 0.92rem;
  text-transform: uppercase;
  color: var(--muted);
}

.section-title span {
  display: inline-grid;
  place-items: center;
  min-width: 2rem;
  min-height: 1.65rem;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.18), rgba(255, 255, 255, 0.92));
  color: var(--brand-black);
  font-size: 0.78rem;
  font-weight: 850;
}

.order-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(0, 167, 111, 0.16);
  border-radius: 24px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(248, 253, 250, 0.92));
  padding: 1rem 1rem 1rem 1.1rem;
  box-shadow: var(--shadow-soft);
}

.order-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 6px;
  background: var(--brand);
}

.order-card.status-card-open {
  border-color: rgba(34, 197, 94, 0.42);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(232, 255, 242, 0.9));
  color: #052e16;
}

.order-card.status-card-open::before {
  background: linear-gradient(180deg, #22c55e, #00a76f);
}

.order-card.status-card-in-progress {
  border-color: rgba(245, 158, 11, 0.5);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(255, 251, 235, 0.92));
  color: #451a03;
}

.order-card.status-card-in-progress::before {
  background: linear-gradient(180deg, #fbbf24, #f59e0b);
}

.order-card.status-card-waiting {
  border-color: rgba(239, 68, 68, 0.5);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(255, 241, 242, 0.92));
  color: #450a0a;
}

.order-card.status-card-waiting::before {
  background: linear-gradient(180deg, #fb7185, #ef4444);
}

.order-card.is-complete {
  border-color: rgba(8, 19, 18, 0.16);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.96), rgba(241, 245, 249, 0.9));
}

.order-card.is-complete::before {
  background: linear-gradient(180deg, #475569, #081312);
}

.order-card.is-complete .edit-order,
.order-card.is-complete .quick-status button {
  cursor: not-allowed;
  opacity: 0.5;
}

.order-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.75rem;
}

.order-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
  margin-bottom: 0.4rem;
}

.order-number {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
}

.pill {
  display: inline-flex;
  min-height: 1.45rem;
  align-items: center;
  border-radius: 999px;
  padding: 0.18rem 0.55rem;
  background: rgba(255, 255, 255, 0.72);
  color: var(--ink);
  font-size: 0.74rem;
  font-weight: 850;
}

.priority-urgent {
  background: #fee2e2;
  color: var(--red);
}

.priority-high {
  background: #ffedd5;
  color: #9a3412;
}

.priority-normal {
  background: #dbeafe;
  color: var(--blue);
}

.priority-low {
  background: #dcfce7;
  color: var(--green);
}

.status-open {
  background: #dcfce7;
  color: #14532d;
}

.status-in-progress {
  background: #fef3c7;
  color: #92400e;
}

.status-waiting {
  background: #fee2e2;
  color: #991b1b;
}

.status-complete {
  background: #dcfce7;
  color: var(--green);
}

.order-card h3 {
  overflow-wrap: anywhere;
  font-size: 1.04rem;
  line-height: 1.25;
}

.details {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.45rem;
  margin: 0.75rem 0;
}

.details div {
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.82);
  padding: 0.45rem 0.5rem;
}

dt {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
}

dd {
  margin: 0.16rem 0 0;
  overflow-wrap: anywhere;
  font-size: 0.86rem;
  font-weight: 750;
}

.description-box {
  margin: 0 0 0.75rem;
  border: 1px solid rgba(0, 167, 111, 0.16);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  padding: 0.6rem 0.7rem;
}

.description-box .description {
  color: var(--muted);
  line-height: 1.45;
  font-weight: 650;
}

.quick-status {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.45rem;
}

.quick-status button {
  min-height: 2.25rem;
  border: 1px solid rgba(0, 167, 111, 0.18);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.88);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.quick-status button.is-active {
  border-color: var(--brand-bright);
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.92), rgba(0, 167, 111, 0.92));
  color: #ffffff;
  box-shadow: 0 8px 18px rgba(0, 167, 111, 0.2);
}

.reopen-button {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  min-height: 2.45rem;
  margin-top: 0.6rem;
  border: 1px solid var(--brand-bright);
  border-radius: 999px;
  background: #fff;
  color: var(--brand-dark);
  font-weight: 850;
}

.reopen-button:hover {
  background: #e7f6f4;
}

.order-card.is-complete .reopen-button {
  display: inline-flex;
}

.empty {
  display: grid;
  place-items: center;
  gap: 0.35rem;
  min-height: 16rem;
  border: 1px solid rgba(0, 167, 111, 0.14);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.58);
  color: var(--muted);
  text-align: center;
}

.empty svg {
  width: 5rem;
  height: 5rem;
  color: #9aa8a4;
}

@media (max-width: 900px) {
  #appView .app-nav {
    position: static;
    isolation: isolate;
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
    max-height: none;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.86);
    padding: 0.45rem;
    box-shadow: var(--shadow-soft);
  }

  #appView .app-nav::before {
    display: none;
  }

  #appView .app-nav-indicator {
    z-index: 0;
    top: var(--active-nav-top);
    left: var(--active-nav-left);
    width: var(--active-nav-width);
    height: var(--active-nav-height);
  }

  #appView .app-nav a {
    justify-content: center;
    width: auto;
    color: var(--ink);
  }

  #appView .app-nav .nav-icon {
    background: rgba(0, 167, 111, 0.1);
    color: var(--brand-dark);
  }

  #appView .app-nav a.is-active {
    color: #fff;
  }

  #appView .app-nav a.is-active .nav-icon {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
  }

  .manager-tools-panel {
    grid-template-columns: 1fr;
  }

  .stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ops-feature-grid,
  .ops-feature-grid.lower-tools,
  .triage-board,
  .dispatch-layout,
  .dispatch-lanes,
  .report-grid,
  .report-panels,
  .module-layout,
  .customer-sections,
  .settings-console,
  .role-matrix {
    grid-template-columns: 1fr;
  }

  .settings-section-tabs {
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  }

  .settings-detail-head {
    align-items: stretch;
    flex-direction: column;
  }

  .settings-action-row {
    justify-content: flex-start;
  }

  .workspace {
    grid-template-columns: 1fr;
  }

  .form-panel {
    position: static;
  }
}

@media (max-width: 640px) {
  .topbar {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    min-height: 4.6rem;
    gap: 0.55rem;
    padding-block: 0.55rem;
  }

  .topbar > div:first-child {
    grid-template-columns: auto minmax(0, 1fr);
    column-gap: 0.55rem;
  }

  .topbar > div:first-child .brand-name {
    min-width: 5.8rem;
    font-size: 1.42rem;
  }

  .topbar > div:first-child .eyebrow,
  .topbar > div:first-child .site-line {
    font-size: 0.68rem;
  }

  .topbar > div:first-child h1 {
    font-size: 1rem;
  }

  .topbar-actions {
    width: auto;
    justify-content: flex-end;
    gap: 0.35rem;
  }

  .topbar .icon-button {
    width: 2.35rem;
    height: 2.35rem;
  }

  .app-update-banner {
    grid-template-columns: 1fr;
    right: 0.75rem;
    bottom: 0.75rem;
    width: calc(100% - 1.5rem);
  }

  .shell {
    padding: 0.75rem;
  }

  .stats {
    gap: 0.55rem;
  }

  .ops-hub-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .page-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .settings-subgrid {
    grid-template-columns: 1fr;
  }

  .ops-hub-actions {
    display: grid;
    width: 100%;
  }

  .kanban-board {
    grid-auto-columns: minmax(82vw, 1fr);
  }

  .stat {
    min-height: 4.8rem;
    padding: 0.75rem;
  }

  .two-col,
  .filters,
  .today-action-grid,
  .details {
    grid-template-columns: 1fr;
  }

  .simple-chart div {
    grid-template-columns: 1fr;
  }

  .order-main {
    grid-template-columns: 1fr;
  }

  .card-actions {
    justify-content: flex-end;
  }

  .quick-status {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .web-status {
    align-items: stretch;
    flex-direction: column;
  }

  .app-nav {
    border-radius: 22px;
    padding-bottom: 0.6rem;
  }

  .app-nav a {
    min-height: 3rem;
    border-radius: 18px;
  }

  .home-summary-grid {
    grid-template-columns: 1fr;
  }

  .parts-index-list,
  .part-index-card,
  .parts-filters,
  .parts-area-cards,
  .clients-grid {
    grid-template-columns: 1fr;
  }

  .web-status a {
    text-align: center;
  }

  .web-status-actions {
    display: grid;
    width: 100%;
  }
}

@media print {
  .topbar,
  .web-status,
  .form-panel,
  .filters,
  .card-actions,
  .quick-status,
  .data-actions {
    display: none !important;
  }

  body,
  html {
    background: #fff;
  }

  .shell {
    width: 100%;
    padding: 0;
  }

  .workspace,
  .stats {
    display: block;
  }

  .stat,
  .panel,
  .order-card {
    box-shadow: none;
    break-inside: avoid;
  }
}
