:root {
  --bg: #0a1120;
  --bg-soft: #101a2d;
  --surface: rgba(18, 28, 46, 0.92);
  --surface-strong: rgba(22, 34, 56, 0.96);
  --surface-soft: rgba(33, 45, 70, 0.72);
  --surface-muted: rgba(20, 30, 49, 0.72);
  --text: #f4f7ff;
  --muted: #96a4bd;
  --muted-soft: #7d8aa3;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.16);
  --accent: #ff8f43;
  --accent-strong: #ff6f29;
  --accent-soft: rgba(255, 143, 67, 0.15);
  --accent-glow: rgba(255, 129, 56, 0.3);
  --good: #7ee3a8;
  --good-soft: rgba(126, 227, 168, 0.14);
  --warn: #ff7b74;
  --warn-soft: rgba(255, 123, 116, 0.14);
  --blue: #5da8ff;
  --blue-soft: rgba(93, 168, 255, 0.16);
  --shadow-xl: 0 34px 84px rgba(0, 0, 0, 0.34);
  --shadow-lg: 0 24px 52px rgba(0, 0, 0, 0.26);
  --shadow-md: 0 12px 28px rgba(0, 0, 0, 0.18);
  --radius-xl: 34px;
  --radius-lg: 26px;
  --radius-md: 20px;
  --radius-sm: 16px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-7: 28px;
  --space-8: 32px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  font-family: "Segoe UI Variable Text", "Segoe UI", system-ui, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 8% 8%, rgba(255, 142, 73, 0.18) 0, rgba(255, 142, 73, 0) 22%),
    radial-gradient(circle at 82% 22%, rgba(98, 140, 255, 0.16) 0, rgba(98, 140, 255, 0) 26%),
    linear-gradient(180deg, #09111f 0%, #0d1628 40%, #09111b 100%);
  overflow-x: hidden;
  overflow-y: auto;
  padding: 16px 20px 24px;
}

.app-shell {
  position: relative;
  max-width: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow: visible;
}

.ambient {
  position: fixed;
  pointer-events: none;
  border-radius: 999px;
  filter: blur(90px);
  opacity: 0.48;
  z-index: 0;
}

.ambient-one {
  width: 380px;
  height: 380px;
  top: -90px;
  left: -120px;
  background: rgba(255, 126, 54, 0.2);
}

.ambient-two {
  width: 340px;
  height: 340px;
  top: 180px;
  right: -120px;
  background: rgba(93, 168, 255, 0.16);
}

.ambient-three {
  width: 440px;
  height: 220px;
  right: 10%;
  bottom: -80px;
  background: rgba(255, 143, 67, 0.16);
}

.app-shell > :not(.ambient) {
  position: relative;
  z-index: 1;
}

.card {
  border-radius: var(--radius-xl);
  border: 1px solid var(--line-strong);
  background:
    linear-gradient(180deg, rgba(26, 38, 61, 0.96) 0%, rgba(15, 24, 40, 0.95) 100%);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.02) inset,
    var(--shadow-lg);
  backdrop-filter: blur(18px);
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: 34px;
  line-height: 0.98;
  letter-spacing: -0.06em;
}

h2 {
  font-size: 22px;
  line-height: 1.06;
  letter-spacing: -0.04em;
}

.hero-shell {
  overflow: visible;
  padding: 14px 18px;
  margin-bottom: 14px;
  z-index: 200;
}

.hero-shell-compact {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.topbar {
  flex: 1 1 auto;
  min-width: 0;
}

.topbar-main {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  min-width: 0;
}

.topbar-copy {
  min-width: 0;
}

.brand-chip,
.modal-brand {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background:
    linear-gradient(180deg, rgba(255, 143, 67, 0.24) 0%, rgba(255, 143, 67, 0.08) 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 16px 34px rgba(255, 118, 49, 0.14);
}

.brand-chip img,
.modal-brand img {
  width: 100%;
  height: 100%;
  display: block;
  padding: 6px;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 6px;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 143, 67, 0.2);
  background: rgba(255, 143, 67, 0.12);
  color: #ffd6b9;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-pill-muted {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.08);
  color: var(--muted);
}

.stat::before,
.position-card::before,
.kpi::before,
.soft-block::before,
.license-card::before,
.modal-card::before,
.order-card::before,
.stats-shell::before,
.sidebar::before,
.editor::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle at top left, rgba(255, 143, 67, 0.12) 0, rgba(255, 143, 67, 0) 34%);
  opacity: 0.9;
}

.section-kicker,
.stat .k,
.kpi .k {
  display: block;
  color: var(--muted-soft);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.toolbar {
  position: relative;
  z-index: 60;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 12px;
  margin-top: 0;
}

.btn {
  min-height: 46px;
  padding: 11px 18px;
  border-radius: 16px;
  border: 1px solid transparent;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  font: 700 13px/1 "Segoe UI Variable Text", "Segoe UI", sans-serif;
  cursor: pointer;
  transition:
    transform 0.18s ease,
    background 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.16);
}

.btn:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
}

.btn:disabled {
  opacity: 0.42;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-primary {
  color: #fff4ea;
  border-color: rgba(255, 143, 67, 0.34);
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-strong) 100%);
  box-shadow: 0 18px 30px rgba(255, 111, 41, 0.26);
}

.btn-secondary,
.btn-ghost {
  border-color: var(--line);
}

.btn-strong {
  border-color: rgba(255, 143, 67, 0.22);
  background: linear-gradient(180deg, rgba(255, 143, 67, 0.16) 0%, rgba(255, 143, 67, 0.08) 100%);
}

.btn-secondary.active {
  color: #fff5ee;
  border-color: rgba(255, 143, 67, 0.34);
  background: linear-gradient(180deg, rgba(255, 143, 67, 0.9) 0%, rgba(255, 111, 41, 0.9) 100%);
}

.btn-sm {
  min-height: 40px;
  padding: 8px 14px;
  font-size: 12px;
}

.btn.danger {
  color: #ffaba6;
  border-color: rgba(255, 123, 116, 0.22);
}

.menu-wrap {
  position: relative;
  z-index: 80;
}

.menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 240px;
  padding: 8px;
  border-radius: 18px;
  border: 1px solid var(--line-strong);
  background: rgba(14, 22, 37, 0.98);
  box-shadow: var(--shadow-xl);
  display: none;
  z-index: 120;
}

.toolbar .menu {
  top: calc(100% + 10px);
  bottom: auto;
}

.menu.menu-floating {
  position: absolute;
  top: 0;
  left: 0;
  right: auto;
  bottom: auto;
  z-index: 5000;
  isolation: isolate;
  pointer-events: auto;
}

.menu.show {
  display: grid;
}

.menu button {
  min-height: 42px;
  width: 100%;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--text);
  text-align: left;
  font: 600 13px/1.1 "Segoe UI Variable Text", "Segoe UI", sans-serif;
  padding: 12px 14px;
  cursor: pointer;
}

.menu button:hover {
  background: rgba(255, 255, 255, 0.07);
}

.feature-strip {
  display: none;
}

.feature-pill {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  padding: 11px 16px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

.dealer-banner {
  margin-bottom: var(--space-5);
  padding: 18px 20px;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 143, 67, 0.22);
  background: linear-gradient(180deg, rgba(255, 143, 67, 0.14) 0%, rgba(255, 143, 67, 0.06) 100%);
  color: #ffd5bb;
  font-weight: 700;
  box-shadow: 0 16px 34px rgba(255, 111, 41, 0.1);
}

.top-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(420px, 0.95fr);
  gap: var(--space-5);
  margin-bottom: 0;
  flex: 0 0 auto;
}

.order-card,
.stats-shell,
.sidebar,
.editor {
  padding: var(--space-6);
}

.section-heading,
.sidebar-head,
.editor-hero {
  display: flex;
  justify-content: space-between;
  gap: var(--space-5);
  align-items: flex-start;
}

.section-note {
  max-width: 520px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.order-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: var(--space-4);
  margin-top: var(--space-5);
}

.field {
  display: grid;
  gap: 9px;
  min-width: 0;
}

.field-wide {
  grid-column: 1 / -1;
}

.field span {
  color: #c8d2e4;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.field input {
  width: 100%;
  min-width: 0;
  min-height: 52px;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  font: 600 15px/1.2 "Segoe UI Variable Text", "Segoe UI", sans-serif;
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.field input::placeholder {
  color: #7d8aa3;
}

.field input:focus {
  border-color: rgba(255, 143, 67, 0.46);
  background: rgba(255, 255, 255, 0.07);
  box-shadow: 0 0 0 4px rgba(255, 143, 67, 0.12);
}

.stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
  margin-top: var(--space-5);
}

.stat,
.kpi {
  position: relative;
  overflow: hidden;
  min-height: 132px;
  padding: 18px 20px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.02) 100%);
}

.stat::after,
.position-card::after,
.kpi::after {
  content: "";
  position: absolute;
  top: 18px;
  left: 0;
  width: 4px;
  height: 40px;
  border-radius: 999px;
  background: linear-gradient(180deg, #ffaf72 0%, var(--accent-strong) 100%);
  box-shadow: 0 0 24px var(--accent-glow);
}

.stat .v,
.kpi .v {
  margin-top: 16px;
  font-size: 26px;
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.workspace {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: var(--space-5);
  align-items: start;
}

.sidebar {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: visible;
}

.sidebar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.position-list {
  display: grid;
  gap: 14px;
  margin-top: var(--space-5);
  min-height: 0;
  overflow: visible;
  padding-right: 0;
}

.position-card {
  position: relative;
  overflow: hidden;
  padding: 18px;
  border-radius: 24px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(18, 29, 49, 0.96) 0%, rgba(13, 22, 37, 0.98) 100%);
  cursor: pointer;
  transition:
    transform 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.position-card:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.16);
}

.position-card.active {
  border-color: rgba(255, 143, 67, 0.34);
  box-shadow:
    0 20px 38px rgba(0, 0, 0, 0.26),
    0 0 0 1px rgba(255, 143, 67, 0.12) inset;
}

.position-top,
.position-bottom {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
}

.position-bottom {
  margin-top: 16px;
  align-items: center;
}

.position-name {
  font-size: 18px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
}

.position-meta {
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.position-bottom strong {
  font-size: 21px;
  line-height: 1;
  letter-spacing: -0.04em;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.tag-blue {
  color: #cfe4ff;
  background: var(--blue-soft);
  border-color: rgba(93, 168, 255, 0.22);
}

.tag-green {
  color: #d4ffe1;
  background: var(--good-soft);
  border-color: rgba(126, 227, 168, 0.2);
}

.tag-red {
  color: #ffd3cf;
  background: var(--warn-soft);
  border-color: rgba(255, 123, 116, 0.2);
}

.editor {
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: visible;
}

.empty-state {
  min-height: 0;
  flex: 1 1 auto;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 14px;
  text-align: center;
  color: var(--muted);
}

.empty-state-mark {
  width: 84px;
  height: 84px;
  border-radius: 28px;
  display: grid;
  place-items: center;
  background: rgba(255, 143, 67, 0.12);
  color: var(--accent);
  font-size: 44px;
  font-weight: 300;
  border: 1px solid rgba(255, 143, 67, 0.18);
}

.empty-state-title {
  color: var(--text);
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.04em;
}

.empty-state-text {
  max-width: 520px;
  font-size: 15px;
  line-height: 1.6;
}

.editor-content {
  display: grid;
  gap: var(--space-5);
  min-height: 0;
  overflow: visible;
  padding-right: 0;
}

.status-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.position-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-4);
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-4);
}

#errorBox {
  min-height: 0;
}

#errorBox .error-card {
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid rgba(255, 123, 116, 0.24);
  background: rgba(255, 123, 116, 0.08);
  color: #ffd6d2;
}

.soft-block {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.02) 100%);
}

.soft-block summary {
  list-style: none;
  cursor: pointer;
  padding: 20px 22px;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.soft-block summary::-webkit-details-marker {
  display: none;
}

.soft-block summary::after {
  content: "▾";
  float: right;
  color: var(--muted);
}

.soft-block:not([open]) summary::after {
  content: "▸";
}

.table-wrap {
  padding: 0 20px 20px;
  overflow: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 680px;
}

th,
td {
  padding: 13px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  text-align: left;
}

th {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

td {
  color: var(--text);
  font-size: 14px;
}

.right {
  text-align: right;
}

.center {
  text-align: center;
}

.compact-table td input {
  min-height: 40px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  padding: 9px 12px;
  width: 100%;
}

.license-gate,
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(7, 12, 22, 0.78);
  backdrop-filter: blur(14px);
}

.license-card,
.modal-card {
  position: relative;
  width: min(560px, calc(100vw - 32px));
  padding: 28px;
  border-radius: 30px;
  border: 1px solid var(--line-strong);
  background: linear-gradient(180deg, rgba(20, 30, 49, 0.98) 0%, rgba(11, 19, 33, 0.98) 100%);
  box-shadow: var(--shadow-xl);
  overflow: hidden;
}

.orders-modal {
  width: min(1040px, calc(100vw - 32px));
  max-height: min(820px, calc(100vh - 40px));
  display: grid;
  grid-template-rows: auto auto minmax(220px, 1fr) auto auto;
  gap: 16px;
}

.orders-modal-head,
.orders-footer,
.orders-head-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.orders-modal-head {
  justify-content: space-between;
  padding-right: 44px;
}

.orders-filters {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 12px;
}

.orders-filter-tabs {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 8px;
}

.orders-filter-tab {
  min-height: 42px;
  padding: 10px 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  font: 700 13px/1 "Segoe UI Variable Text", "Segoe UI", sans-serif;
  cursor: pointer;
  transition:
    background 0.16s ease,
    border-color 0.16s ease,
    color 0.16s ease,
    transform 0.16s ease;
}

.orders-filter-tab:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.14);
  color: var(--text);
}

.orders-filter-tab.active {
  border-color: rgba(255, 143, 67, 0.28);
  background: rgba(255, 143, 67, 0.14);
  color: #ffe1cd;
}

.orders-table-wrap {
  border-radius: 20px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  overflow: auto;
  min-height: 260px;
}

.orders-table {
  min-width: 100%;
}

.orders-table tbody tr {
  cursor: pointer;
  transition: background 0.16s ease;
}

.orders-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.04);
}

.orders-table tbody tr.active {
  background: rgba(255, 143, 67, 0.12);
}

.orders-status {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  border: 1px solid var(--line);
  color: var(--muted);
}

.orders-status.archived {
  border-color: rgba(255, 143, 67, 0.25);
  background: rgba(255, 143, 67, 0.12);
  color: #ffd7bd;
}

.orders-status.draft {
  border-color: rgba(93, 168, 255, 0.2);
  background: rgba(93, 168, 255, 0.12);
  color: #d9eaff;
}

.orders-preview {
  min-height: 88px;
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  line-height: 1.5;
}

.orders-preview strong {
  color: var(--text);
}

.orders-empty {
  padding: 34px 20px;
  text-align: center;
  color: var(--muted);
}

.orders-footer-spacer {
  flex: 1 1 auto;
}

.license-top {
  display: flex;
  gap: 18px;
  align-items: flex-start;
}

.license-title {
  margin-top: 10px;
}

.license-text,
.modal-text {
  margin-top: 12px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.license-meta {
  display: grid;
  gap: 10px;
  margin-top: 20px;
  margin-bottom: 20px;
}

.license-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 20px;
}

.license-note {
  display: grid;
  gap: 8px;
  margin-top: 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  font-size: 22px;
  cursor: pointer;
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 22px;
}

.about-item {
  padding: 16px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
}

.about-item span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.about-item strong {
  display: block;
  margin-top: 8px;
  font-size: 15px;
  line-height: 1.4;
}

.hidden {
  display: none !important;
}

.menu-portal {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 7000;
}

@media (max-width: 1440px) {
  .top-grid {
    grid-template-columns: 1fr;
  }

  .workspace {
    grid-template-columns: 320px minmax(0, 1fr);
  }

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

  .position-form,
  .kpi-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1120px) {
  .app-shell {
    gap: 12px;
  }

  .hero-shell-compact {
    flex-direction: column;
    align-items: stretch;
  }

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

  .sidebar {
    min-height: 0;
  }

  .order-grid,
  .position-form,
  .kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  body {
    padding: 10px 10px 16px;
  }

  .hero-shell,
  .order-card,
  .stats-shell,
  .sidebar,
  .editor {
    padding: 18px;
  }

  h1 {
    font-size: 30px;
  }

  .topbar-main,
  .stats,
  .order-grid,
  .position-form,
  .kpi-grid,
  .about-grid,
  .orders-filters {
    grid-template-columns: 1fr;
  }

  .orders-modal {
    max-height: calc(100vh - 20px);
  }

  .orders-modal-head,
  .orders-footer {
    flex-wrap: wrap;
  }

  .section-heading,
  .sidebar-head,
  .editor-hero {
    flex-direction: column;
    align-items: stretch;
  }

  .toolbar,
  .sidebar-actions {
    justify-content: stretch;
  }

  .toolbar .btn,
  .sidebar-actions .btn,
  .menu-wrap {
    width: 100%;
  }

  .menu {
    left: 0;
    right: 0;
    min-width: 0;
  }

  .position-top,
  .position-bottom,
  .license-top,
  .license-actions {
    flex-direction: column;
    align-items: flex-start;
  }

  table {
    min-width: 560px;
  }
}
