/* MIHA Liquid: optical chrome, solid working surfaces. No imitation OS API. */
:root {
  --ink: #16333d;
  --muted: #49616e;
  --accent: #006f7c;
  --paper: #fff;
  --ground: #eaf1f3;
  --line: #d6e2e6;
  --glass: rgba(255, 255, 255, 0.72);
  --glass-strong: rgba(255, 255, 255, 0.91);
  --radius: 22px;
  --glass-shadow:
    0 14px 42px rgba(37, 74, 89, 0.1), inset 0 1px 0 #fff,
    inset 0 -1px 0 rgba(255, 255, 255, 0.6);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}
body {
  background: var(--ground);
  color: var(--ink);
  font-size: 15px;
  caret-color: var(--accent);
  scrollbar-color: #94b0bb transparent;
}
body:before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse at 4% 8%, #d9edf0 0, transparent 44%),
    radial-gradient(ellipse at 95% 76%, #dfe7f4 0, transparent 48%);
  pointer-events: none;
}
::selection {
  background: #b8e6e9;
  color: #103943;
}
.workarea {
  background: transparent;
}
.workspace {
  max-width: 1500px;
  padding: 38px 44px 80px;
}
.sidebar {
  width: 244px;
  background: var(--glass);
  border-left: 1px solid #ffffffba;
  box-shadow: var(--glass-shadow);
  backdrop-filter: blur(26px) saturate(150%);
  -webkit-backdrop-filter: blur(26px) saturate(150%);
}
.toolbar {
  position: sticky;
  top: 0;
  z-index: 25;
  height: 76px;
  background: var(--glass);
  border-bottom: 1px solid #ffffffc9;
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
}
.sidebar nav button {
  border-radius: 15px;
  min-height: 52px;
  font-size: 14px;
}
.sidebar nav button.active {
  background: #fff9;
  box-shadow:
    inset 0 1px 1px #fff,
    0 6px 18px #1a58600d;
  color: var(--accent);
}
.sidebar nav button.active:before {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  top: 18px;
  bottom: 18px;
  width: 3px;
  border-radius: 3px;
  background: var(--accent);
}
button {
  font-size: 14px;
  min-height: 44px;
  transition:
    background 0.16s,
    box-shadow 0.16s,
    transform 0.16s var(--ease);
}
button:active {
  transform: scale(0.98);
}
button:disabled {
  transform: none;
  cursor: wait;
}
.icon-button,
.toolbar .icon-button,
.case-heading .icon-button {
  min-width: 44px;
  min-height: 44px;
}
.tools .quiet {
  min-width: 44px;
  min-height: 44px;
  font-size: 13px;
}
.primary {
  background: var(--accent);
  color: white;
  box-shadow:
    0 5px 12px #006f7c19,
    inset 0 1px 0 #ffffff35;
}
.primary:hover {
  background: #005b66;
}
.surface {
  background: var(--paper);
  border: 1px solid #dce6e9;
  border-radius: var(--radius);
  box-shadow: 0 3px 12px #244e5e04;
  padding: 26px;
}
.surface .surface {
  box-shadow: none;
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0;
  padding: 22px 0;
}
.welcome {
  background: transparent;
  border: 0;
  box-shadow: none;
  padding: 18px 0 30px;
  min-height: 0;
}
.welcome img {
  display: none;
}
.welcome h2 {
  font-size: 31px;
  letter-spacing: -0.025em;
  line-height: 1.65;
}
.welcome p {
  font-size: 15px;
  color: var(--muted);
  max-width: 64ch;
}
.welcome .welcome-copy {
  max-width: 760px;
}
.dashboard-facts {
  background: var(--glass-strong);
  border: 1px solid #fff;
  box-shadow: var(--glass-shadow);
  border-radius: 22px;
  padding: 24px 30px;
}
.dashboard-facts strong {
  font-size: 30px;
}
.dashboard-facts small,
.dashboard-facts span {
  font-size: 13px;
  color: var(--muted);
}
.case-person h1 {
  font-size: 30px;
}
.case-person p,
.case-meta,
.case-meta .tag {
  font-size: 13px;
  color: var(--muted);
}
.case-heading {
  margin-bottom: 22px;
}
.tabs {
  position: sticky;
  top: 87px;
  z-index: 20;
  background: var(--glass);
  padding: 6px;
  border: 1px solid #fff;
  border-radius: 19px;
  box-shadow: var(--glass-shadow);
  backdrop-filter: blur(24px) saturate(155%);
  -webkit-backdrop-filter: blur(24px) saturate(155%);
}
.tabs button {
  min-height: 46px;
  font-size: 13px;
  border-radius: 13px;
  white-space: nowrap;
  flex: 1;
}
.tabs button.active {
  background: #fffffff0;
  color: var(--accent);
  box-shadow:
    0 3px 10px #25465312,
    inset 0 1px 0 white;
}
.next {
  background: #fff8ed;
  border: 1px solid #eadfc9;
  border-radius: 20px;
}
.next p {
  color: #68543c;
  font-size: 14px;
}
.next strong {
  font-size: 17px;
}
.activity-list small,
.side-note,
.muted,
.quantity-caption,
.quantity-strip span,
.quiet-foot,
.balance-label,
.case-reason {
  color: var(--muted);
}
.activity-list small,
.side-note {
  font-size: 13px;
}
.quantity-strip span,
.quantity-caption,
.shipment-counts,
.shipment-main small,
.balance-row {
  font-size: 13px;
}
.balance-amount {
  color: #155563;
}
.tag {
  font-size: 12px;
}
.case-title small,
.case-balance small,
.customer-identity small {
  font-size: 13px;
  color: var(--muted);
}
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
button:focus-visible,
a:focus-visible,
summary:focus-visible {
  outline: 3px solid #007d8b;
  outline-offset: 3px;
}
.product-picker {
  display: grid;
  gap: 12px;
}
.picker-item {
  display: grid;
  grid-template-columns: 1fr 100px;
  gap: 16px;
  align-items: center;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: white;
}
.picker-item strong {
  display: block;
  font-size: 15px;
}
.picker-item bdi {
  font-size: 13px;
  color: var(--muted);
  display: block;
}
.picker-item label {
  margin: 0;
}
.picker-item input {
  max-width: 100px;
  text-align: center;
}
.picker-search {
  position: sticky;
  top: -24px;
  padding: 8px 0 16px;
  background: var(--glass-strong);
  z-index: 2;
}
.stock-facts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  margin: 18px 0;
}
.stock-facts > div {
  background: white;
  padding: 18px;
}
.stock-facts strong {
  display: block;
  font-size: 24px;
}
.stock-facts span {
  font-size: 12px;
  color: var(--muted);
}
.followup-replies {
  padding: 12px 0;
  border-top: 1px solid var(--line);
  margin-top: 10px;
}
.followup-replies p {
  font-size: 14px;
}
.followup-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 12px;
  color: var(--muted);
}
.catalog-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
}
.catalog-row h3 {
  font-size: 18px;
}
.catalog-row bdi {
  white-space: nowrap;
}
.catalog-intro img {
  width: 160px;
  height: 110px;
  object-fit: cover;
  border-radius: 16px;
}
.catalog-intro {
  border-radius: 22px;
  background: #ffffffa1;
  border: 1px solid #fff;
}
.catalog-row button {
  min-width: 80px;
}
.money {
  font-variant-numeric: tabular-nums;
}
.print-only {
  display: none;
}
.signin {
  background: transparent;
}
.signin-story {
  background: #e0eff1;
  border: 1px solid white;
}
.signin-form {
  background: #ffffffb0;
  border: 1px solid white;
  border-radius: 28px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}
.signin-form a {
  font-size: 14px;
}
.signin-foot {
  font-size: 13px !important;
  color: var(--muted);
}
.signin-art {
  object-fit: contain;
}
.loading-lines {
  max-width: 220px;
}
.workspace[data-page="case"] .case-content {
  animation: caseReveal 0.25s var(--ease);
}
@keyframes caseReveal {
  from {
    opacity: 0.8;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@media (max-width: 780px) {
  .workspace {
    padding: 22px 18px 120px;
  }
  .toolbar {
    height: 64px;
    padding: 10px 18px;
  }
  .welcome {
    padding: 0 0 22px;
  }
  .welcome h2 {
    font-size: 23px;
    line-height: 1.7;
  }
  .welcome p {
    font-size: 14px;
  }
  .dashboard-facts {
    padding: 20px 16px;
  }
  .dashboard-facts strong {
    font-size: 25px;
  }
  .dashboard-facts small {
    font-size: 12px;
  }
  .bottom-nav {
    background: rgba(255, 255, 255, 0.68);
    border: 1px solid #fff;
    box-shadow:
      0 12px 40px #123a502b,
      inset 0 1px 0 #fff,
      inset 0 -1px 1px #ffffff90;
    backdrop-filter: blur(28px) saturate(180%);
    -webkit-backdrop-filter: blur(28px) saturate(180%);
    border-radius: 27px;
    padding: 7px;
    bottom: max(14px, env(safe-area-inset-bottom));
    left: 16px;
    right: 16px;
  }
  .bottom-nav button {
    border-radius: 20px;
    min-height: 58px;
    font-size: 12px;
    color: #3d5b69;
  }
  .bottom-nav button.active {
    background: #ffffffcb;
    box-shadow:
      0 2px 9px #1e465c12,
      inset 0 1px 0 white;
    color: #006c79;
  }
  .case-person h1 {
    font-size: 23px;
  }
  .case-person p,
  .case-meta {
    font-size: 12px;
  }
  .tabs {
    top: 72px;
    border-radius: 18px;
    overflow-x: auto;
    scrollbar-width: none;
    margin-bottom: 22px;
  }
  .tabs button {
    font-size: 13px;
    min-height: 46px;
    flex: none;
    padding: 9px 15px;
  }
  .case-glance {
    padding: 18px 0;
    gap: 10px;
  }
  .case-glance strong,
  .case-glance .money {
    font-size: 14px;
  }
  .case-glance span {
    font-size: 12px;
  }
  .surface {
    padding: 22px 20px;
    border-radius: 22px;
  }
  .next {
    padding: 20px;
  }
  .next strong {
    font-size: 16px;
  }
  .next p {
    font-size: 14px;
  }
  .case-content {
    padding-top: 0;
  }
  .activity-list small {
    font-size: 12px;
  }
  .surface .list-heading button {
    font-size: 13px;
    min-height: 44px;
  }
  .surface .surface .inline button {
    font-size: 13px;
    min-height: 46px;
  }
  .balance-amount {
    font-size: 25px;
  }
  .picker-item {
    grid-template-columns: 1fr 80px;
    padding: 14px;
    gap: 10px;
  }
  .picker-item strong {
    font-size: 14px;
  }
  .picker-item bdi {
    font-size: 12px;
    white-space: nowrap;
  }
  .picker-item input {
    max-width: 80px;
  }
  .picker-search {
    top: -20px;
  }
  .stock-facts {
    grid-template-columns: repeat(2, 1fr);
  }
  .stock-facts > div {
    padding: 16px;
  }
  .catalog-intro img {
    width: 110px;
    height: 100px;
  }
  .catalog-row {
    gap: 12px;
  }
  .catalog-row h3 {
    font-size: 16px;
  }
  .catalog-row .inline {
    flex-direction: column;
  }
  .signin {
    padding: 14px;
  }
  .signin-story {
    min-height: 280px;
  }
  .signin-form {
    padding: 28px 22px;
    margin-top: 16px;
  }
  .signin-story p {
    font-size: 14px;
  }
  .signin-story > small {
    font-size: 12px;
  }
}
@supports not (backdrop-filter: blur(1px)) {
  .sidebar,
  .toolbar,
  .tabs,
  .bottom-nav,
  .signin-form {
    background: #f8fbfc;
  }
}
@media (prefers-reduced-transparency: reduce), (prefers-contrast: more) {
  .sidebar,
  .toolbar,
  .tabs,
  .bottom-nav,
  .signin-form {
    background: white;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    box-shadow: none;
    border-color: #a5bac4;
  }
}
@media (prefers-reduced-motion: reduce) {
  .case-content {
    animation: none !important;
  }
  button {
    transition: none !important;
  }
}
@media print {
  body:before,
  .sidebar,
  .toolbar,
  .bottom-nav,
  .head-actions,
  .tabs,
  button,
  .demo-banner {
    display: none !important;
  }
  .workarea {
    margin: 0 !important;
  }
  .workspace {
    padding: 0;
  }
  .surface {
    box-shadow: none;
    border: 0;
    break-inside: avoid;
  }
  .print-only {
    display: block;
  }
  dialog {
    display: none !important;
  }
  .money {
    white-space: nowrap;
  }
}

.followup-reply {
  padding: 12px;
  background: #f1f6f7;
  border-radius: 12px;
}
.followup-reply small {
  display: block;
  color: #49616e;
}
.decision {
  flex-wrap: wrap;
  gap: 12px;
}
.decision > div:first-child {
  flex: 1;
  min-width: 180px;
}
.picker-item small {
  color: #49616e;
  font-size: 12px;
}
.picker-item[hidden] {
  display: none;
}
td bdi {
  display: block;
  white-space: nowrap;
}
#statement {
  background: #fff;
  padding: 24px;
}
.recent-row time {
  color: #49616e;
}
.toolbar-search {
  min-height: 44px;
}
.sidebar .nav-item {
  position: relative;
}
.nav-item.active:before {
  pointer-events: none;
}
@media print {
  body.printing #app,
  body.printing .skip,
  body.printing #toast {
    display: none !important;
  }
  body.printing dialog[open] {
    display: block !important;
    position: static;
    width: 100%;
    max-width: none;
    max-height: none;
    border: 0;
    box-shadow: none;
    background: #fff;
  }
  body.printing #dialogForm,
  body.printing #dialogBody {
    display: block;
    max-height: none;
    overflow: visible;
    padding: 0;
  }
  body.printing dialog header,
  body.printing dialog footer {
    display: none !important;
  }
}

/* Keep real work in the first viewport; the material is navigation, not a hero. */
.workspace[data-page="today"] .head {
  margin-bottom: 12px;
}
.workspace[data-page="today"] .welcome {
  padding: 4px 0 18px;
  margin-bottom: 0;
}
.workspace[data-page="today"] .welcome h2 {
  font-size: 22px;
  margin: 0 0 5px;
  line-height: 1.6;
}
.workspace[data-page="today"] .welcome p {
  margin: 0 0 12px;
}
.workspace[data-page="today"] .welcome-links {
  margin: 0;
  gap: 16px;
}
.dashboard-facts {
  padding: 8px 16px;
  gap: 0;
  margin-bottom: 24px;
}
.dashboard-facts > div {
  border: 0;
  border-radius: 0;
  box-shadow: none;
  background: transparent;
  padding: 14px 20px;
}
.dashboard-facts > div + div {
  border-inline-start: 1px solid #d6e2e6;
}
.dashboard-facts .money {
  font-size: 22px;
}
.dashboard-facts strong {
  font-size: 27px;
}
@media (max-width: 780px) {
  .workspace[data-page="today"] .welcome h2 {
    font-size: 19px;
  }
  .workspace[data-page="today"] .welcome-links > span {
    display: none;
  }
  .dashboard-facts {
    padding: 12px 0;
    margin-bottom: 20px;
  }
  .dashboard-facts > div {
    padding: 8px 14px;
  }
  .dashboard-facts .money {
    font-size: 19px;
  }
}
/* Short desktop windows must reveal the first complete attention item. */
@media (min-width: 900px) and (max-height: 760px) {
  .welcome {
    display: none;
  }
}
