/* Ops Desk — tema-agnostik layout (base) */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  height: 100%;
  min-height: 100%;
  min-height: 100dvh;
  overflow: hidden;
  font-size: 11px;
  user-select: none;
  cursor: default;
}

:root {
  --taskbar-height: 40px;
  --app-icon-size: 48px;
  --taskbar-icon-size: 20px;
}

body.is-mobile-shell {
  --taskbar-height: calc(40px + env(safe-area-inset-bottom, 0px));
}

/* Masaüstü alanı */
.desktop {
  position: relative;
  width: 100%;
  height: calc(100% - var(--taskbar-height));
  height: calc(100dvh - var(--taskbar-height));
  overflow: hidden;
}

.desktop-icons {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.desktop-icon {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 88px;
  padding: 6px 4px;
  text-align: center;
  pointer-events: auto;
  touch-action: none;
  cursor: grab;
  border-radius: 6px;
}

.desktop-icon.dragging {
  cursor: grabbing;
  opacity: 0.9;
  z-index: 6;
}

.desktop-icon img,
.desktop-icon .icon-glyph {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 6px;
  flex-shrink: 0;
}

.app-icon {
  display: block;
  flex-shrink: 0;
  overflow: visible;
}

.app-icon--desktop {
  width: var(--app-icon-size);
  height: var(--app-icon-size);
}

.app-icon--menu {
  width: 24px;
  height: 24px;
  margin-right: 6px;
  vertical-align: middle;
}

.app-icon--taskbar {
  width: var(--taskbar-icon-size);
  height: var(--taskbar-icon-size);
}

.startup-app-icon.app-icon {
  width: 24px;
  height: 24px;
}

.taskbar-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 200px;
  padding: 4px 10px;
  font-size: 11px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  cursor: pointer;
}

.taskbar-app-label {
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.desktop-icon span {
  font-size: 11px;
  line-height: 1.2;
  word-break: break-word;
}

/* Görev çubuğu — yapı */
.taskbar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--taskbar-height);
  min-height: calc(var(--taskbar-height) + env(safe-area-inset-bottom, 0px));
  padding-bottom: env(safe-area-inset-bottom, 0);
  display: flex;
  align-items: stretch;
  z-index: 10000;
}

.start-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  margin: 3px;
  font-weight: bold;
  font-size: 12px;
  cursor: pointer;
}

.start-btn .win-logo {
  width: 16px;
  height: 16px;
}

.taskbar-windows {
  flex: 1;
  display: flex;
  gap: 3px;
  padding: 4px 6px;
  overflow: hidden;
  align-items: center;
}

.taskbar-tray {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 8px;
  margin: 2px 4px 2px 0;
  font-size: 11px;
}

.tray-status {
  display: flex;
  align-items: center;
  gap: 4px;
  font-family: inherit;
  font-size: 11px;
  padding: 2px 6px;
  cursor: pointer;
}

.tray-status .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.tray-menu {
  display: none;
  position: fixed;
  right: 6px;
  bottom: calc(var(--taskbar-height) + 6px);
  min-width: 220px;
  z-index: 21000;
  padding: 2px;
}

.tray-menu.open {
  display: block;
}

.tray-menu-title {
  padding: 4px 8px;
  font-weight: bold;
}

.tray-menu-item {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  padding: 4px 8px;
  font-family: inherit;
  font-size: 11px;
  text-align: left;
  cursor: pointer;
}

.tray-menu-check {
  width: 12px;
  text-align: center;
}

.tray-menu-sep {
  height: 1px;
  margin: 4px 6px;
}

.tray-menu-info {
  padding: 6px 8px;
  font-size: 10px;
  line-height: 1.35;
}

/* Pencere — yapı */
.window {
  position: absolute;
  min-width: 320px;
  min-height: 200px;
  display: flex;
  flex-direction: column;
  resize: none;
}

.resize-handle {
  position: absolute;
  z-index: 5;
}

.window.maximized .resize-handle {
  display: none;
}

.resize-n,
.resize-s {
  left: 8px;
  right: 8px;
  height: 5px;
}

.resize-n {
  top: 0;
  cursor: n-resize;
}

.resize-s {
  bottom: 0;
  cursor: s-resize;
}

.resize-e,
.resize-w {
  top: 8px;
  bottom: 8px;
  width: 5px;
}

.resize-e {
  right: 0;
  cursor: e-resize;
}

.resize-w {
  left: 0;
  cursor: w-resize;
}

.resize-nw,
.resize-ne,
.resize-sw,
.resize-se {
  width: 12px;
  height: 12px;
}

.resize-nw {
  top: 0;
  left: 0;
  cursor: nw-resize;
}

.resize-ne {
  top: 0;
  right: 0;
  cursor: ne-resize;
}

.resize-sw {
  bottom: 0;
  left: 0;
  cursor: sw-resize;
}

.resize-se {
  right: 0;
  bottom: 0;
  cursor: nwse-resize;
}

.window.minimized {
  display: none;
}

.window.maximized {
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
  max-height: none !important;
}

.title-bar {
  display: flex;
  align-items: center;
  padding: 2px 2px 2px 4px;
  font-weight: bold;
  font-size: 11px;
}

.title-bar-text {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.title-bar-controls {
  display: flex;
  gap: 2px;
}

.title-btn {
  width: 16px;
  height: 14px;
  padding: 0;
  font-size: 9px;
  line-height: 12px;
  font-weight: bold;
  cursor: pointer;
}

.window-body {
  flex: 1;
  min-height: 0;
  padding: 8px;
  overflow: auto;
  margin: 2px;
}

.window-body.layout-fill {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.window-body.layout-fill .orders-list-layout {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
}

.window-body.layout-fill .orders-filters-panel,
.window-body.layout-fill .orders-list-toolbar,
.window-body.layout-fill .pager-bar {
  flex-shrink: 0;
}

.window-body.layout-fill .table-wrap-fill {
  flex: 1 1 0;
  min-height: 80px;
  max-height: none;
  overflow: auto;
}

/* Sipariş listesi — daraltılabilir filtreler */
.orders-filters-panel {
  margin: 0 0 6px;
}

.orders-filters-summary {
  cursor: pointer;
  user-select: none;
  font-weight: bold;
  font-size: 11px;
  padding: 2px 0 4px;
  list-style: none;
}

.orders-filters-summary::-webkit-details-marker {
  display: none;
}

.orders-filters-summary::before {
  content: '▸ ';
  display: inline-block;
  width: 1em;
}

.orders-filters-panel[open] > .orders-filters-summary::before {
  content: '▾ ';
}

.orders-filters-body {
  padding-top: 4px;
}

.orders-list-toolbar {
  margin-bottom: 6px;
}

.filter-hint {
  margin: 4px 0 0;
  line-height: 1.3;
  font-size: 10px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.window-body.layout-fill .filter-hint {
  white-space: normal;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.status-bar {
  display: flex;
  margin: 0 2px 2px;
}

.status-panel {
  padding: 2px 6px;
  font-size: 11px;
}

.status-panel:first-child {
  flex: 1;
}

/* Başlangıç menüsü — yapı */
.start-menu {
  display: none;
  position: fixed;
  bottom: var(--taskbar-height);
  left: 0;
  width: 200px;
  z-index: 10001;
}

.start-menu.open {
  display: block;
}

.start-menu-sidebar {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 24px;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-weight: bold;
  font-size: 14px;
  padding: 8px 4px;
  letter-spacing: 1px;
}

.start-menu-items {
  margin-left: 24px;
  padding: 4px 0;
}

.start-menu-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  cursor: pointer;
}

.start-menu-separator {
  height: 2px;
  margin: 4px 8px;
}

.start-menu-subtitle {
  padding: 4px 12px 2px;
  font-size: 10px;
  font-weight: bold;
  opacity: 0.75;
  pointer-events: none;
}

.start-menu-theme-check {
  width: 14px;
  text-align: center;
  opacity: 0;
}

.start-menu-theme-check.active {
  opacity: 1;
}

/* Diyalog — yapı */
.dialog-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 20000;
  align-items: center;
  justify-content: center;
}

.dialog-overlay.open {
  display: flex;
}

.dialog {
  min-width: 300px;
  max-width: 420px;
}

.dialog-json {
  min-width: 480px;
  max-width: 90vw;
}

.dialog-body {
  display: flex;
  gap: 12px;
  padding: 16px;
  align-items: flex-start;
}

.dialog-buttons {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 8px 12px 12px;
}

/* Tablo / filtre — yapı */
.table-wrap {
  overflow: auto;
  max-height: 340px;
}

table.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
}

table.data-table th {
  padding: 4px 6px;
  text-align: left;
  position: sticky;
  top: 0;
  z-index: 1;
  white-space: nowrap;
}

/* Selected / hover rows — cell text must follow row foreground */
table.data-table tbody tr.selected td,
table.data-table tbody tr:hover td {
  color: inherit;
}

table.data-table tbody tr.selected td strong,
table.data-table tbody tr:hover td strong {
  color: inherit;
}

.tabs {
  display: flex;
  gap: 2px;
  margin-bottom: -2px;
  position: relative;
  z-index: 1;
}

.tab {
  padding: 4px 12px;
  cursor: pointer;
  font-size: 11px;
}

.tab-panel {
  display: none;
  padding: 12px;
  min-height: 280px;
  overflow: auto;
}

.tab-panel.active {
  display: block;
}

.detail-grid {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 4px 12px;
  font-size: 11px;
}

.filter-row {
  display: grid;
  grid-template-columns: 1fr 140px 140px auto;
  gap: 8px;
  align-items: end;
  margin-bottom: 8px;
}

.filter-row-main {
  grid-template-columns: minmax(160px, 1.4fr) repeat(4, minmax(110px, 1fr));
}

.filter-row-dates {
  grid-template-columns: 1fr 1fr auto;
  margin-bottom: 4px;
}

.filter-row-events {
  grid-template-columns: minmax(180px, 1fr) minmax(140px, 0.6fr);
}

.filter-action-btns {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.rate-main-row {
  display: flex;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

.rate-main-col {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
  min-height: 0;
}

.rate-table-wrap {
  flex: 1;
  min-height: 180px;
  overflow: auto;
}

.window-body.layout-fill .tab-panel.active {
  flex: 1;
  min-height: 160px;
  max-height: none;
  display: block;
}

.window-body.layout-fill .tabs {
  flex-shrink: 0;
}

@media (max-width: 768px) {
  .filter-row,
  .filter-row-dates,
  .filter-row-events {
    grid-template-columns: 1fr;
  }

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

  .filter-row-main > div:first-child {
    grid-column: 1 / -1;
  }
}

body.is-mobile-shell .filter-row-main {
  grid-template-columns: 1fr 1fr;
}

body.is-mobile-shell .filter-row-main > div:first-child {
  grid-column: 1 / -1;
}

body.is-mobile-shell .filter-row-dates {
  grid-template-columns: 1fr;
}

/* Mobil kabuk + tablet (tema-agnostik layout) */

body.is-mobile-shell .desktop-icons {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(84px, 1fr));
  gap: 10px 6px;
  align-content: start;
  padding: 12px 10px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  pointer-events: auto;
  z-index: 1;
}

body.is-mobile-shell .desktop-icon {
  position: relative;
  left: auto !important;
  top: auto !important;
  width: auto;
  max-width: 96px;
  margin: 0 auto;
  touch-action: manipulation;
  cursor: pointer;
}

body.is-mobile-shell .window:not(.minimized),
body.is-mobile-shell .window.mobile-fill {
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
  min-width: 0;
  max-width: none;
}

body.is-mobile-shell .resize-handle {
  display: none !important;
}

body.is-mobile-shell .title-bar {
  cursor: default;
}

body.is-mobile-shell .title-btn[data-action='maximize'] {
  display: none;
}

body.is-mobile-shell .start-btn,
body.is-mobile-shell .taskbar-btn,
body.is-mobile-shell .tray-status {
  min-height: 32px;
  padding-top: 4px;
  padding-bottom: 4px;
}

body.is-mobile-shell .taskbar-windows {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

body.is-mobile-shell .taskbar-btn {
  max-width: none;
  flex-shrink: 0;
}

body.is-mobile-shell .start-menu {
  left: 0;
  right: 0;
  width: auto;
  bottom: calc(var(--taskbar-height) + env(safe-area-inset-bottom, 0));
  max-height: min(70dvh, calc(100dvh - var(--taskbar-height) - 16px));
  overflow: auto;
}

body.is-mobile-shell .start-menu-sidebar {
  position: static;
  width: auto;
  writing-mode: horizontal-tb;
  transform: none;
  padding: 8px 12px;
}

body.is-mobile-shell .start-menu-items {
  margin-left: 0;
}

body.is-mobile-shell .start-menu-item {
  min-height: 44px;
  padding: 10px 16px;
}

body.is-mobile-shell .tray-menu {
  left: 8px;
  right: 8px;
  bottom: calc(var(--taskbar-height) + env(safe-area-inset-bottom, 0) + 4px);
  min-width: 0;
  width: auto;
}

body.is-mobile-shell .tray-menu-item {
  min-height: 44px;
  padding: 10px 12px;
}

body.is-mobile-shell .table-wrap,
body.is-mobile-shell .rate-table-wrap,
body.is-mobile-shell .product-summary-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

body.is-mobile-shell table.data-table tbody tr {
  min-height: 40px;
}

body.is-mobile-shell .detail-grid {
  grid-template-columns: 1fr;
}

body.is-mobile-shell .tabs {
  overflow-x: auto;
  flex-wrap: nowrap;
  -webkit-overflow-scrolling: touch;
  max-width: 100%;
}

body.is-mobile-shell .tab {
  flex-shrink: 0;
}

body.is-mobile-shell .filter-action-btns {
  width: 100%;
}

body.is-mobile-shell .filter-action-btns .btn {
  min-height: 36px;
}

body.is-mobile-shell .rate-main-row {
  position: relative;
  flex-direction: column;
}

body.is-mobile-shell .rate-settings-sidebar {
  position: absolute;
  inset: 0;
  z-index: 20;
  width: auto;
  max-width: none;
  border-right: none;
}

body.is-mobile-shell .rate-license-actions {
  flex-wrap: wrap;
  gap: 4px;
}

body.is-mobile-shell .rate-action-btn,
body.is-mobile-shell .rate-menubar-btn {
  flex-shrink: 0;
}

body.is-mobile-shell .dialog,
body.is-mobile-shell .dialog-json,
body.is-tablet .dialog,
body.is-tablet .dialog-json {
  width: min(560px, calc(100vw - 16px));
  min-width: unset;
  max-width: calc(100vw - 16px);
}

body.is-tablet .filter-row-main {
  grid-template-columns: 1fr 1fr;
}

body.is-tablet .table-wrap,
body.is-tablet .rate-table-wrap,
body.is-tablet .product-summary-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

body.is-tablet .detail-grid {
  grid-template-columns: 120px 1fr;
}

@media (prefers-reduced-motion: reduce) {
  .rate-conn-led.is-wait,
  .rate-conn-led.is-on,
  .rate-conn-led.is-tick,
  tr.order-row-flash,
  .rate-flash .rate-pub-value,
  .rate-flash .rate-pub-delta {
    animation: none !important;
  }
}

@media print {
  .taskbar,
  .start-menu,
  .tray-menu,
  .dialog-overlay {
    display: none !important;
  }
}

/* Sayfalama — kompakt SaaS satırı */
.pager-bar {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
  padding-top: 6px;
}

.pager-nav {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  gap: 4px;
}

.pager-nav .pager-btn {
  min-width: 0;
  padding: 4px 8px;
}

.pager-nav .pager-btn:first-child,
.pager-nav .pager-btn:last-child {
  min-width: 28px;
  padding: 4px 6px;
}

.pager-info {
  flex: 1;
  min-width: 0;
  text-align: center;
  font-size: 11px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #404040;
}

.pager-info strong {
  color: #000;
  font-weight: 700;
}

.pager-size {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  gap: 6px;
  margin-left: auto;
}

.pager-size-label {
  font-size: 11px;
  white-space: nowrap;
  color: #404040;
}

.pager-size-select {
  width: auto;
  min-width: 3.5rem;
  max-width: 4.75rem;
  padding: 3px 22px 3px 8px;
  font-family: inherit;
  font-size: 11px;
  line-height: 1.2;
  flex: 0 0 auto;
  color: #000;
  background-color: #fff;
  border: 2px inset #808080;
  box-sizing: border-box;
}

.pager-size-select option {
  color: #000;
  background: #fff;
}

body.is-mobile-shell .pager-bar {
  flex-wrap: wrap;
  row-gap: 6px;
}

body.is-mobile-shell .pager-info {
  order: 3;
  flex: 1 1 100%;
  text-align: left;
}

body.is-mobile-shell .pager-size {
  margin-left: 0;
}

/* --- Sipariş Express --- */
.express-root.layout-fill {
  padding: 4px 6px;
}

.express-layout {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-height: 0;
  min-width: 0;
  width: 100%;
  height: 100%;
}

.express-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  font-size: 10px;
}

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

.express-count {
  opacity: 0.85;
  white-space: nowrap;
}

.express-error {
  flex-shrink: 0;
}

.express-strip-wrap {
  flex: 1 1 auto;
  min-height: 0;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  cursor: grab;
}

.express-strip-wrap.express-strip-dragging {
  cursor: grabbing;
  user-select: none;
}

.express-strip {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  gap: 8px;
  min-height: min-content;
  width: max-content;
  max-width: none;
  padding: 2px 4px 6px;
}

.express-empty {
  margin: 0;
  padding: 12px 8px;
  font-size: 11px;
}

.express-card {
  flex: 0 0 auto;
  width: 340px;
  min-width: 260px;
  max-width: none;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  text-align: left;
  outline: none;
}

.express-card-head {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 6px 8px;
  flex-shrink: 0;
}

.express-card-head-main {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px;
}

.express-card-no {
  font-size: 12px;
}

.express-card-customer {
  font-size: 11px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}

.express-card-head-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  font-size: 10px;
}

.express-card-date {
  opacity: 0.85;
}

.express-card-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.express-card-body .product-summary {
  margin: 0;
  min-width: 0;
}

.express-card-body .product-summary legend,
.express-card-body .ps-intro {
  display: none;
}

.express-card-body .product-summary-scroll {
  overflow-x: auto;
  overflow-y: visible;
  max-height: none;
}

.express-card-body .product-summary-table {
  min-width: 0;
  width: 100%;
  font-size: 10px;
  table-layout: fixed;
}

.express-card-body .product-summary-table th,
.express-card-body .product-summary-table td {
  padding: 3px 4px;
  white-space: normal;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.express-card--flash {
  animation: express-card-flash 1.1s ease-in-out infinite;
}

@keyframes express-card-flash {
  0%,
  100% {
    box-shadow: inset 0 0 0 2px #ffd60a;
  }
  50% {
    box-shadow: inset 0 0 0 2px #fff3a0;
  }
}

.express-loading .express-strip {
  opacity: 0.65;
}

body.is-mobile-shell .express-card {
  width: min(300px, 100%);
  min-width: min(240px, 100%);
}

/* User Admin */
.ua-root.layout-fill {
  padding: 6px;
}

.ua-layout {
  display: flex;
  flex-direction: column;
  gap: 6px;
  height: 100%;
  min-height: 0;
  min-width: 0;
  overflow: hidden;
}

.ua-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.ua-split {
  display: flex;
  flex: 1 1 auto;
  min-height: 0;
  min-width: 0;
  gap: 6px;
  overflow: hidden;
}

.ua-panel {
  border: 1px solid var(--border-color, #808080);
  padding: 6px;
  min-height: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.ua-panel-users {
  flex: 1 1 52%;
}

.ua-panel-editor {
  flex: 1 1 48%;
}

.ua-panel-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}

.ua-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
  flex-shrink: 0;
}

.ua-editor-panel {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}

.ua-users-table tbody tr {
  cursor: pointer;
}

.ua-users-table tbody tr.selected {
  background: rgba(0, 0, 128, 0.12);
}

.order-status-help {
  cursor: help;
  position: relative;
}

.order-status-tooltip {
  display: none;
}

.order-status-tip-line {
  margin: 0 0 4px;
  line-height: 1.35;
}

.order-status-tip-line:last-child {
  margin-bottom: 0;
}

@media (max-width: 900px) {
  .ua-split {
    flex-direction: column;
    overflow: auto;
  }

  .ua-panel-users,
  .ua-panel-editor {
    flex: 0 0 auto;
    min-height: 220px;
  }
}

.ua-field {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-bottom: 8px;
}

.ua-field input,
.ua-field select {
  width: 100%;
  font: inherit;
  padding: 4px 6px;
}

.ua-field-inline label {
  display: flex;
  align-items: center;
  gap: 6px;
}

.perm-tree {
  flex: 1 1 auto;
  min-height: 120px;
  max-height: none;
  overflow: auto;
  border: 1px inset var(--border-color, #c0c0c0);
  padding: 4px;
}

.ua-field-fill {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.ua-perm-tree {
  flex: 1 1 auto;
  min-height: 160px;
}

.ua-tab-bar {
  margin-bottom: 8px;
}

.ua-tab-panel {
  display: none;
}

.ua-tab-panel.active {
  display: block;
}

.ua-editor {
  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100%;
}

.ua-editor-actions {
  margin-top: 8px;
  flex-shrink: 0;
}

.perm-tree-row {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 8px;
  align-items: start;
  margin-bottom: 4px;
  font-size: 10px;
}

.perm-tree-desc {
  grid-column: 2;
  opacity: 0.75;
  font-size: 9px;
}

.ua-users-table {
  width: 100%;
  font-size: 10px;
}

.ua-actions {
  white-space: nowrap;
}

.badge-root {
  background: #004;
  color: #fff;
  padding: 1px 4px;
  font-size: 9px;
}

.badge-muted {
  opacity: 0.7;
  font-size: 9px;
}

.ua-status.ok {
  color: #060;
}

.ua-status.error {
  color: #900;
}

.ua-note {
  font-size: 10px;
  opacity: 0.85;
}

@media (max-width: 900px) {
  .ua-layout {
    grid-template-columns: 1fr;
  }
}

/* Login / auth */
body.auth-page {
  overflow: auto;
}

.auth-shell {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
}

.auth-window {
  width: min(420px, 100%);
}

.auth-form {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.auth-lead {
  margin: 0;
  line-height: 1.45;
}

.auth-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.auth-field input {
  width: 100%;
  padding: 6px 8px;
  font: inherit;
}

.auth-error {
  padding: 8px;
  border: 1px solid #c00;
  background: #ffecec;
  color: #900;
}

.auth-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

/* --- Uygulama simgeleri (SVG sprite) --- */
.start-menu-item .app-icon--menu {
  flex-shrink: 0;
}

.alt-tab-card-foot .app-icon--taskbar {
  flex-shrink: 0;
}

.menu-app-icon {
  display: inline-block;
  vertical-align: middle;
  margin-right: 6px;
}

.dialog-footer-extra {
  padding: 0 16px 8px;
  font-size: 11px;
}

.dialog-suppress-label {
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

/* --- Alt+Tab switcher --- */
.alt-tab-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 18000;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(4px);
}

.alt-tab-overlay.open {
  display: flex;
}

.alt-tab-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
  max-width: min(1200px, 100%);
}

.alt-tab-card {
  display: flex;
  flex-direction: column;
  width: min(220px, 42vw);
  padding: 0;
  border: 2px solid rgba(255, 255, 255, 0.25);
  border-radius: 8px;
  background: rgba(30, 30, 30, 0.92);
  color: #fff;
  cursor: pointer;
  overflow: hidden;
  opacity: 0.82;
  transform: scale(0.96);
  transition: transform 0.12s ease, opacity 0.12s ease, border-color 0.12s ease;
}

.alt-tab-card.is-selected {
  opacity: 1;
  transform: scale(1.04);
  border-color: #5ac8fa;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
}

.alt-tab-preview-wrap {
  height: 130px;
  overflow: hidden;
  background: #111;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.alt-tab-preview {
  width: 100%;
  height: 100%;
  overflow: hidden;
  position: relative;
}

.alt-tab-preview-clone {
  transform: scale(0.22);
  transform-origin: top left;
  width: 460%;
  max-height: none;
  pointer-events: none;
  user-select: none;
}

.alt-tab-card-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  font-size: 11px;
}

.alt-tab-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

