:root {
  color-scheme: dark;
  --bg: #03080c;
  --panel: rgba(12, 22, 30, 0.88);
  --panel-soft: rgba(18, 31, 42, 0.78);
  --line: rgba(78, 168, 255, 0.18);
  --line-strong: rgba(45, 159, 255, 0.48);
  --text: #f4f8fb;
  --muted: #94a7b9;
  --blue: #189bff;
  --blue-2: #55c1ff;
  --green: #34d16f;
  --orange: #ffad32;
  --red: #ff563f;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  color: var(--text);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  background:
    radial-gradient(circle at 18% -10%, rgba(25, 155, 255, 0.28), transparent 30rem),
    radial-gradient(circle at 82% 4%, rgba(26, 194, 255, 0.14), transparent 24rem),
    linear-gradient(135deg, #06131b 0%, #020407 42%, #04090d 100%);
}

button,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

[hidden] {
  display: none !important;
}

.app-shell {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 26px;
  min-height: calc(100vh - 68px);
  padding: 18px 26px 20px;
}

.sidebar,
.panel,
.kpi,
.quick-side,
.user-menu {
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(15, 27, 37, 0.92), rgba(6, 12, 17, 0.92));
  box-shadow: var(--shadow);
}

.sidebar {
  position: sticky;
  top: 18px;
  align-self: start;
  height: calc(100vh - 106px);
  min-height: 760px;
  padding: 18px 14px;
  border-radius: 8px;
  overflow: auto;
}

.brand-mark {
  display: grid;
  grid-template-columns: 74px 1fr;
  gap: 12px;
  align-items: center;
  min-height: 112px;
  margin-bottom: 18px;
  width: 100%;
  padding: 0;
  border: 0;
  color: inherit;
  text-align: left;
  background: transparent;
}

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

.brand-orbit {
  position: absolute;
  width: 105px;
  height: 58px;
  border: 2px solid rgba(111, 195, 255, 0.8);
  border-radius: 50%;
  transform: rotate(-14deg);
  filter: drop-shadow(0 0 10px rgba(25, 155, 255, 0.45));
}

.brand-car,
.badge-logo {
  display: grid;
  place-items: center;
  width: 68px;
  height: 68px;
  border: 2px solid var(--blue);
  border-radius: 8px;
  color: white;
  font-weight: 900;
  background: linear-gradient(160deg, #0b1016, #0b3f66);
  box-shadow: inset 0 0 22px rgba(24, 155, 255, 0.24), 0 0 24px rgba(24, 155, 255, 0.24);
  z-index: 1;
}

.brand-mark strong,
.footer-strip strong {
  display: block;
  text-transform: uppercase;
  letter-spacing: 0;
  font-size: 16px;
}

.brand-mark span,
.hero-title span,
.footer-strip span {
  color: var(--blue);
}

.brand-mark small {
  color: var(--muted);
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.main-nav p,
.quick-side p {
  margin: 14px 16px 10px;
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
}

.main-nav,
.quick-side {
  display: grid;
  gap: 4px;
}

.main-nav a,
.quick-side a,
.shortcut-grid a,
.calendar-actions button,
.panel-head button,
.panel-head a,
.add-vehicle {
  border: 1px solid transparent;
  color: var(--text);
  background: transparent;
}

.main-nav a,
.quick-side a {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 6px;
  text-align: left;
  text-decoration: none;
}

.sidebar .main-nav > a,
.sidebar .quick-side > a {
  width: 100%;
  color: var(--text);
  font-size: 15px;
  font-weight: 500;
  line-height: 1;
  text-decoration: none;
  transition: border-color 160ms ease, background-color 160ms ease, color 160ms ease;
}

.sidebar .main-nav > a:visited,
.sidebar .quick-side > a:visited {
  color: var(--text);
}

.main-nav a span,
.quick-side a span {
  width: 20px;
  color: #a8bdd1;
  text-align: center;
}

.main-nav a.active,
.main-nav a:hover,
.quick-side a:hover {
  border-color: rgba(48, 163, 255, 0.24);
  background: linear-gradient(90deg, rgba(24, 155, 255, 0.92), rgba(24, 155, 255, 0.13));
}

.sidebar .main-nav > a.active {
  border-color: #2da4ff;
  color: #ffffff;
  background: linear-gradient(90deg, #168fe8, rgba(24, 155, 255, 0.18));
  box-shadow: inset 3px 0 0 #67c5ff;
}

.sidebar .main-nav > a:hover,
.sidebar .quick-side > a:hover {
  color: #ffffff;
}

.sub-nav {
  position: relative;
  display: grid;
  gap: 3px;
  margin: 2px 0 5px 17px;
  padding-left: 9px;
  border-left: 1px solid rgba(72, 159, 231, 0.22);
}

.service-sub-nav {
  margin-bottom: 8px;
}

.service-sub-nav > a {
  white-space: nowrap;
}

.sidebar .sub-nav > a {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  line-height: 1;
  text-decoration: none;
}

.sidebar .sub-nav > a:visited {
  color: var(--muted);
}

.sidebar .sub-nav > a span {
  width: 16px;
  color: #7790a5;
  text-align: center;
}

.sidebar .sub-nav > a:hover {
  color: white;
  background: rgba(24, 155, 255, 0.08);
}

.sidebar .sub-nav > a.active {
  border-color: rgba(24, 155, 255, 0.22);
  color: var(--blue-2);
  background: rgba(24, 155, 255, 0.13);
}

.sidebar .sub-nav > a.active span {
  color: var(--blue);
}

.quick-side {
  margin-top: 16px;
  padding: 10px 0 14px;
  border-radius: 8px;
}

.dashboard {
  min-width: 0;
}

.topbar {
  display: grid;
  grid-template-columns: minmax(380px, 1fr) minmax(520px, 1.55fr) auto;
  gap: 14px;
  align-items: center;
  margin-bottom: 22px;
}

.hero-title {
  display: flex;
  gap: 20px;
  align-items: center;
}

.hero-title h1 {
  margin: 0;
  font-size: clamp(24px, 2.4vw, 38px);
  line-height: 1;
  letter-spacing: 0;
}

.hero-title p {
  margin: 10px 0 0;
  color: #f2f7fb;
  font-size: 18px;
  font-weight: 700;
  text-transform: uppercase;
}

.kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  gap: 14px;
}

.kpi {
  min-height: 96px;
  padding: 16px 18px;
  border-radius: 8px;
}

.kpi span,
.kpi small,
.panel-head button,
.panel-head a,
.panel-head select,
td,
.legend {
  color: var(--muted);
}

.kpi span {
  display: block;
  font-size: 12px;
  text-transform: uppercase;
}

.kpi strong {
  display: block;
  margin: 4px 0;
  color: var(--blue-2);
  font-size: 30px;
  line-height: 1;
}

.kpi .positive {
  color: var(--green);
}

.user-menu {
  display: grid;
  grid-template-columns: 30px 30px 42px auto;
  gap: 8px;
  align-items: center;
  min-height: 62px;
  padding: 8px 12px;
  border-radius: 8px;
}

.user-menu button,
.avatar {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 50%;
  color: white;
  background: rgba(20, 38, 52, 0.9);
}

.avatar {
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: linear-gradient(145deg, #cbd5df, #4b6782);
  font-size: 12px;
  font-weight: 900;
}

.user-menu small {
  display: block;
  color: var(--muted);
}

.grid {
  display: grid;
  grid-template-columns: 1.15fr 1.4fr 1.32fr;
  gap: 16px;
}

.panel {
  min-width: 0;
  padding: 16px;
  border-radius: 8px;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

h2 {
  margin: 0;
  font-size: 16px;
  text-transform: uppercase;
}

.panel-head strong {
  display: block;
  margin-top: 18px;
  font-size: 16px;
}

#currentDate {
  margin-top: 10px;
}

.panel-head button,
.panel-head select,
.inline-title select {
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 6px;
  background: rgba(19, 32, 43, 0.9);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.job-list,
.schedule,
#orderOverview,
#stockList,
#notifications {
  display: grid;
  gap: 8px;
}

.job,
.slot,
.overview-row,
.stock-row,
.note {
  display: grid;
  align-items: center;
  gap: 12px;
  min-height: 48px;
  padding: 9px 10px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.035);
  border-bottom: 1px solid rgba(255, 255, 255, 0.035);
}

.job {
  grid-template-columns: 62px 1fr auto;
}

.job-code {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 42px;
  border-radius: 6px;
  color: var(--blue);
  background: rgba(23, 44, 58, 0.9);
}

.job-code.warning {
  color: var(--orange);
}

.job-code.done {
  color: var(--green);
}

.job h3,
.slot strong {
  margin: 0 0 3px;
  font-size: 15px;
}

.job p,
.slot span,
.note span,
.overview-row span {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.job-time {
  text-align: right;
}

.job-time strong {
  display: block;
  color: var(--muted);
  font-weight: 500;
}

.job-time span {
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.job-time span.red {
  color: var(--red);
}

.job-time span.green {
  color: var(--green);
}

.slot {
  grid-template-columns: 58px 6px 1fr 1fr 130px;
}

.slot time {
  font-weight: 800;
}

.slot i {
  width: 4px;
  height: 34px;
  border-radius: 99px;
  background: var(--blue);
}

.slot:nth-child(1) i,
.slot:nth-child(3) i {
  background: var(--orange);
}

.shortcuts {
  grid-row: span 1;
}

.shortcut-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(96px, 1fr));
  gap: 10px;
}

.shortcut-grid a {
  display: grid;
  place-items: center;
  gap: 8px;
  min-height: 88px;
  padding: 10px 8px;
  border-radius: 7px;
  background: var(--panel-soft);
  color: var(--text);
  text-align: center;
  text-decoration: none;
}

.shortcut-grid a span {
  color: var(--blue);
  font-size: 30px;
  line-height: 1;
}

.shortcut-grid a:hover {
  border-color: var(--line-strong);
  transform: translateY(-1px);
}

.register {
  grid-column: span 2;
}

.inline-title {
  display: flex;
  align-items: center;
  gap: 16px;
}

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

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

th,
td {
  padding: 11px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.055);
  text-align: left;
  font-size: 13px;
}

th {
  color: #7f93a7;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

td:first-child,
td:nth-child(2) {
  color: var(--text);
  font-weight: 800;
}

td:last-child {
  color: var(--blue);
}

.add-vehicle {
  width: 100%;
  min-height: 38px;
  margin-top: 12px;
  border-color: var(--line-strong);
  border-radius: 6px;
  color: var(--blue);
  background: rgba(8, 24, 35, 0.82);
  font-weight: 800;
  text-transform: uppercase;
  display: grid;
  place-items: center;
  text-decoration: none;
}

.icon-link {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  color: white;
  background: rgba(20, 38, 52, 0.9);
  text-decoration: none;
}

.donut-layout,
.area-layout {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 18px;
  align-items: center;
}

.donut,
.area-donut {
  display: grid;
  place-items: center;
  width: 138px;
  height: 138px;
  border-radius: 50%;
  background: conic-gradient(var(--blue) 0 50%, #248be5 50% 79%, var(--orange) 79% 92%, var(--green) 92% 100%);
  position: relative;
}

.donut.is-empty,
.area-donut.is-empty {
  background: conic-gradient(rgba(148, 167, 185, 0.22) 0 100%);
}

.donut::after,
.area-donut::after {
  content: "";
  position: absolute;
  inset: 24px;
  border-radius: 50%;
  background: #071016;
}

.donut strong,
.donut span {
  position: relative;
  z-index: 1;
}

.donut strong {
  font-size: 34px;
}

.donut span {
  margin-top: 34px;
  font-size: 12px;
  text-transform: uppercase;
}

.legend {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 13px;
}

.legend li {
  display: grid;
  grid-template-columns: 12px 1fr auto;
  gap: 10px;
  align-items: center;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.dot.blue {
  background: var(--blue);
}

.dot.light-blue {
  background: var(--blue-2);
}

.dot.orange {
  background: var(--orange);
}

.dot.green {
  background: var(--green);
}

.overview-row,
.stock-row,
.note {
  grid-template-columns: 32px 1fr auto;
}

.overview-row b,
.stock-row b,
.note b {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  color: #071016;
}

.bars {
  display: grid;
  gap: 12px;
}

.bar {
  display: grid;
  grid-template-columns: 116px 1fr 34px;
  gap: 14px;
  align-items: center;
  font-size: 13px;
}

.bar-track {
  height: 4px;
  overflow: hidden;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.06);
}

.bar-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(24, 155, 255, 0.2), var(--blue));
}

.revenue,
.areas,
.stock,
.notifications {
  min-height: 210px;
}

canvas {
  display: block;
  width: 100%;
  height: 160px;
}

.area-donut {
  width: 118px;
  height: 118px;
  background: conic-gradient(#189bff 0 46%, #88c9b8 46% 74%, #f47a38 74% 93%, #b18a54 93% 100%);
}

.area-donut::after {
  inset: 32px;
}

.compact {
  gap: 9px;
}

.empty-state {
  display: grid;
  place-items: center;
  min-height: 210px;
  padding: 28px;
  border: 1px dashed rgba(148, 167, 185, 0.2);
  border-radius: 6px;
  text-align: center;
  background: rgba(255, 255, 255, 0.018);
}

.empty-state strong {
  align-self: end;
  margin-bottom: 7px;
  color: var(--text);
  font-size: 15px;
}

.empty-state span,
.empty-copy span {
  align-self: start;
  color: var(--muted);
  font-size: 13px;
}

.compact-empty {
  min-height: 138px;
}

.count-badge {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 6px;
  color: var(--muted);
  background: rgba(19, 32, 43, 0.9);
  font-size: 12px;
}

.empty-row td {
  height: 150px;
  color: var(--muted) !important;
  font-weight: 500 !important;
  text-align: center;
}

.zero-list {
  display: grid;
  gap: 8px;
}

.zero-list > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 43px;
  padding: 0 12px;
  border-radius: 6px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.035);
}

.zero-list strong {
  color: var(--text);
}

.empty-copy {
  display: grid;
  gap: 6px;
}

.empty-copy strong {
  font-size: 28px;
}

.section-view {
  min-height: 650px;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 20px;
  padding: 6px 2px 18px;
  border-bottom: 1px solid var(--line);
}

.section-heading > div {
  min-width: 0;
}

.section-heading > div > span {
  color: var(--blue-2);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.section-heading h2 {
  margin-top: 7px;
  font-size: 26px;
}

.section-heading p {
  margin: 8px 0 0;
  color: var(--muted);
}

.primary-action {
  min-height: 42px;
  padding: 0 18px;
  border: 1px solid var(--blue);
  border-radius: 6px;
  color: white;
  background: #087ccc;
  font-weight: 800;
}

.primary-action:hover {
  background: var(--blue);
}

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

.section-card {
  min-height: 132px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(15, 27, 37, 0.92), rgba(6, 12, 17, 0.92));
  box-shadow: var(--shadow);
}

.section-card span,
.section-card small {
  display: block;
  color: var(--muted);
}

.section-card strong {
  display: block;
  margin: 10px 0 8px;
  color: var(--blue-2);
  font-size: 32px;
}

.section-workspace {
  grid-column: 1 / -1;
  min-height: 330px;
}

.section-workspace .empty-state {
  min-height: 250px;
}

.section-topbar {
  grid-template-columns: minmax(380px, 1fr) minmax(420px, 1.1fr) auto;
}

.section-topbar .kpis {
  grid-template-columns: repeat(3, minmax(120px, 1fr));
}

.section-topbar .user-menu {
  grid-template-columns: 30px 42px auto;
}

.table-actions {
  display: flex;
  gap: 8px;
}

.table-actions input {
  min-width: 220px;
  min-height: 34px;
  padding: 0 11px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  color: var(--text);
  outline: none;
  background: rgba(19, 32, 43, 0.9);
}

.table-actions input:focus {
  border-color: var(--line-strong);
}

.workshop-page .section-topbar {
  grid-template-columns: minmax(420px, 1fr) auto;
}

.workshop-page .section-topbar .kpis {
  display: none;
}

.workshop-page .section-topbar .user-menu {
  justify-self: end;
}

.workshop-page .section-heading {
  margin-bottom: 14px;
  padding-bottom: 14px;
}

.workshop-content {
  display: grid;
  gap: 14px;
}

.workshop-toolbar,
.calendar-toolbar,
.workshop-filters {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.segmented,
.filter-tabs,
.calendar-toolbar > div {
  display: flex;
  align-items: center;
  gap: 5px;
}

.segmented button,
.filter-tabs button,
.calendar-toolbar button,
.workshop-filters > button,
.category-list button {
  min-height: 32px;
  padding: 0 11px;
  border: 1px solid rgba(148, 167, 185, 0.13);
  border-radius: 5px;
  color: var(--muted);
  background: rgba(13, 27, 37, 0.84);
  font-size: 12px;
}

.segmented button.selected,
.filter-tabs button.selected {
  border-color: rgba(24, 155, 255, 0.4);
  color: white;
  background: rgba(24, 155, 255, 0.18);
}

.hall-layout,
.planner-layout,
.inventory-layout,
.employee-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 240px;
  gap: 14px;
  align-items: start;
}

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

.hall-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: linear-gradient(180deg, rgba(16, 29, 39, 0.96), rgba(5, 12, 17, 0.96));
  box-shadow: var(--shadow);
}

.hall-card-head,
.hall-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
}

.hall-card-head h3 {
  margin: 0 0 3px;
  font-size: 15px;
  text-transform: uppercase;
}

.hall-card-head span,
.hall-meta,
.hall-stage small {
  color: var(--muted);
  font-size: 11px;
}

.hall-card-head b {
  padding: 5px 8px;
  border-radius: 4px;
  color: var(--green);
  background: rgba(52, 209, 111, 0.12);
  font-size: 10px;
  text-transform: uppercase;
}

.hall-card-head b.in_arbeit,
.status-pill.in_arbeit {
  color: var(--green);
  background: rgba(52, 209, 111, 0.12);
}

.hall-card-head b.wartet_auf_teile,
.status-pill.wartet_auf_teile {
  color: var(--orange);
  background: rgba(255, 173, 50, 0.13);
}

.hall-card-head b.bereit,
.status-pill.bereit {
  color: var(--blue-2);
  background: rgba(24, 155, 255, 0.13);
}

.hall-stage {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 145px;
  padding: 20px;
  overflow: hidden;
  text-align: center;
  background:
    linear-gradient(rgba(4, 11, 16, 0.38), rgba(4, 11, 16, 0.88)),
    repeating-linear-gradient(90deg, transparent 0 54px, rgba(30, 143, 220, 0.1) 55px 57px),
    linear-gradient(155deg, #122b3a, #081016 62%);
}

.hall-stage::after {
  content: "";
  position: absolute;
  left: 8%;
  right: 8%;
  bottom: 22px;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(54, 176, 255, 0.6), transparent);
}

.hall-stage strong,
.hall-stage small {
  position: relative;
  z-index: 1;
}

.hall-stage small {
  margin-top: 28px;
}

.hall-mark {
  position: absolute;
  color: rgba(78, 168, 255, 0.11);
  font-size: 72px;
  font-weight: 900;
}

.hall-card > button {
  width: calc(100% - 24px);
  min-height: 34px;
  margin: 0 12px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  color: var(--blue-2);
  background: transparent;
}

.hall-progress {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 7px 12px;
  padding: 10px 14px 0;
  color: var(--muted);
  font-size: 11px;
}

.hall-progress strong {
  color: var(--text);
}

.hall-progress i {
  grid-column: 1 / -1;
  height: 4px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.07);
}

.hall-progress i b {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #148ee1, var(--blue-2));
}

.hall-loading,
.hall-empty {
  display: grid;
  grid-column: 1 / -1;
  place-items: center;
  min-height: 310px;
  padding: 30px;
  border: 1px dashed rgba(148, 167, 185, 0.2);
  border-radius: 7px;
  color: var(--muted);
  text-align: center;
  background: rgba(255, 255, 255, 0.018);
}

.hall-empty strong {
  align-self: end;
  color: var(--text);
}

.hall-empty span {
  align-self: start;
  margin-top: 8px;
}

.hall-empty.error strong {
  color: var(--red);
}

.hall-list {
  min-height: 360px;
}

.empty-mini {
  padding: 28px 8px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.table-icon-button {
  min-height: 28px;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--blue-2);
  background: transparent;
}

.workshop-side {
  min-height: 0;
}

.util-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 5px 12px;
  padding: 11px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 12px;
}

.util-row span small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
}

.util-row i {
  grid-column: 1 / -1;
  height: 4px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.06);
}

.util-row i b {
  display: block;
  height: 100%;
  background: var(--blue);
}

.workshop-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.workshop-stats article {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 11px;
  align-items: center;
  min-height: 78px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: linear-gradient(180deg, rgba(15, 27, 37, 0.92), rgba(6, 12, 17, 0.92));
}

.workshop-stat-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 6px;
  color: var(--blue);
  background: rgba(24, 155, 255, 0.11);
  font-size: 19px;
}

.workshop-stats small,
.workshop-stats article div > span {
  display: block;
  color: var(--muted);
  font-size: 10px;
}

.workshop-stats strong {
  display: inline-block;
  margin: 2px 6px 2px 0;
  color: var(--blue-2);
  font-size: 23px;
}

.workshop-table-panel {
  min-height: 390px;
}

.workshop-filters {
  margin-bottom: 12px;
}

.calendar-toolbar {
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: rgba(9, 18, 25, 0.9);
}

.planner {
  position: relative;
  min-height: 560px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: rgba(7, 15, 21, 0.92);
}

.planner-head,
.planner-body {
  display: grid;
  grid-template-columns: 60px repeat(6, 1fr);
}

.planner-head {
  min-height: 44px;
  border-bottom: 1px solid var(--line);
}

.planner-head strong {
  display: grid;
  place-items: center;
  border-left: 1px solid rgba(255, 255, 255, 0.055);
  font-size: 11px;
}

.time-axis,
.day-column {
  display: grid;
  grid-template-rows: repeat(10, 48px);
}

.time-axis span {
  padding: 7px 8px 0 0;
  color: var(--muted);
  font-size: 10px;
  text-align: right;
}

.day-column {
  border-left: 1px solid rgba(255, 255, 255, 0.055);
}

.day-column i {
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.planner-empty {
  position: absolute;
  top: 49%;
  left: calc(50% + 30px);
  transform: translate(-50%, -50%);
  color: var(--muted);
  font-size: 13px;
}

.category-list {
  display: grid;
  gap: 4px;
}

.category-list button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.category-list button.active {
  color: var(--blue-2);
  background: rgba(24, 155, 255, 0.12);
}

.status-ring {
  display: grid;
  place-items: center;
  width: 132px;
  height: 132px;
  margin: 12px auto 20px;
  border: 18px solid rgba(24, 155, 255, 0.16);
  border-radius: 50%;
}

.status-ring strong {
  font-size: 27px;
}

.status-ring span {
  margin-top: -28px;
  color: var(--muted);
  font-size: 10px;
}

.workshop-side .legend > div {
  display: grid;
  grid-template-columns: 10px 1fr auto;
  gap: 8px;
  align-items: center;
}

.auftrag-dialog {
  width: min(820px, calc(100vw - 32px));
  max-height: calc(100vh - 40px);
  padding: 0;
  overflow: auto;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  color: var(--text);
  background: #08131b;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.75);
}

.auftrag-dialog::backdrop {
  background: rgba(0, 5, 9, 0.82);
  backdrop-filter: blur(3px);
}

.auftrag-form {
  display: grid;
}

.dialog-head {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 20px 22px;
  border-bottom: 1px solid var(--line);
  background: rgba(8, 19, 27, 0.97);
}

.dialog-head span {
  color: var(--blue-2);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.dialog-head h2 {
  margin-top: 5px;
  font-size: 21px;
}

.dialog-close {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
  font-size: 24px;
}

.dialog-close:hover {
  border-color: var(--line-strong);
  color: white;
}

.form-section {
  padding: 20px 22px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.form-section h3 {
  margin: 0 0 15px;
  color: var(--text);
  font-size: 13px;
  text-transform: uppercase;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 15px;
}

.form-grid label {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.form-grid label > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.form-grid .span-2 {
  grid-column: 1 / -1;
}

.form-grid input,
.form-grid select,
.form-grid textarea {
  width: 100%;
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid rgba(148, 167, 185, 0.2);
  border-radius: 6px;
  color: var(--text);
  outline: none;
  background: #0d1b25;
}

.form-grid textarea {
  min-height: 94px;
  resize: vertical;
}

.form-grid input:focus,
.form-grid select:focus,
.form-grid textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(24, 155, 255, 0.12);
}

.dialog-actions {
  position: sticky;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 22px;
  border-top: 1px solid var(--line);
  background: rgba(8, 19, 27, 0.97);
}

.secondary-action {
  min-height: 42px;
  padding: 0 18px;
  border: 1px solid rgba(148, 167, 185, 0.25);
  border-radius: 6px;
  color: var(--text);
  background: transparent;
  font-weight: 700;
}

.danger-action {
  min-height: 42px;
  padding: 0 18px;
  border: 1px solid rgba(255, 86, 63, 0.45);
  border-radius: 6px;
  color: #ff8a78;
  background: rgba(255, 86, 63, 0.08);
  font-weight: 700;
}

.danger-action:hover {
  color: white;
  background: rgba(255, 86, 63, 0.25);
}

.dialog-spacer {
  flex: 1;
}

.primary-action:disabled {
  cursor: wait;
  opacity: 0.55;
}

.form-message {
  min-height: 18px;
  margin: 14px 22px 0;
  color: var(--muted);
  font-size: 13px;
}

.form-message.success {
  color: var(--green);
}

.form-message.error {
  color: var(--red);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 9px;
  border-radius: 99px;
  color: var(--blue-2);
  background: rgba(24, 155, 255, 0.12);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.footer-strip {
  display: grid;
  grid-template-columns: 260px 1fr 260px;
  align-items: center;
  gap: 26px;
  min-height: 68px;
  padding: 0 42px;
  border-top: 1px solid var(--line);
  background: rgba(1, 6, 10, 0.94);
}

.footer-strip p {
  margin: 0;
  text-align: center;
  font-size: clamp(15px, 1.35vw, 23px);
  letter-spacing: 5px;
  text-transform: uppercase;
}

.footer-strip strong:last-child {
  text-align: right;
}

@media (max-width: 1420px) {
  .app-shell {
    grid-template-columns: 220px 1fr;
    padding: 14px;
  }

  .brand-mark {
    grid-template-columns: 58px minmax(0, 1fr);
    gap: 9px;
  }

  .brand-car {
    width: 54px;
    height: 54px;
  }

  .brand-orbit {
    width: 78px;
    height: 48px;
  }

  .brand-mark strong {
    font-size: 13px;
  }

  .brand-mark small {
    font-size: 10px;
    letter-spacing: 1px;
  }

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

  .user-menu {
    justify-self: start;
  }

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

  .shortcuts,
  .order-status,
  .register {
    grid-column: span 1;
  }

  .hall-layout,
  .planner-layout,
  .inventory-layout,
  .employee-layout {
    grid-template-columns: 1fr;
  }
}

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

  .sidebar {
    position: static;
    height: auto;
    min-height: 0;
  }

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

  .grid,
  .kpis,
  .shortcut-grid,
  .section-grid,
  .workshop-stats,
  .footer-strip {
    grid-template-columns: 1fr;
  }

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

  .footer-strip {
    gap: 8px;
    padding: 16px 20px;
    text-align: center;
  }

  .footer-strip strong:last-child {
    text-align: center;
  }
}

@media (max-width: 620px) {
  .app-shell {
    padding: 10px;
  }

  .hero-title,
  .inline-title,
  .donut-layout,
  .area-layout {
    grid-template-columns: 1fr;
    display: grid;
  }

  .slot {
    grid-template-columns: 52px 5px 1fr;
  }

  .slot span:last-child {
    display: none;
  }

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

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

  .primary-action {
    width: 100%;
  }

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

  .form-grid .span-2 {
    grid-column: auto;
  }

  .dialog-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .dialog-actions button {
    width: 100%;
  }
}
