/* H2's gated controls reuse the workshop palette and leave the capsule dock free. */
.logistics-controls[hidden], .logistics-controls [hidden] { display: none; }
.logistics-controls {
  position: absolute; z-index: 24; left: 26%; right: 19%; bottom: 20%;
  display: flex; align-items: center; gap: 6px; pointer-events: auto;
}
.logistics-controls button {
  display: flex; align-items: center; justify-content: center; gap: 4px;
  min-height: 44px; padding: 5px 9px; border: 1px solid #a58155;
  border-radius: 14px; background: #fff4df; color: #4f4145;
  box-shadow: 0 3px 0 #b68c61; font: 600 12px/1.2 system-ui, sans-serif;
  cursor: pointer;
}
.logistics-controls button:disabled { opacity: .6; cursor: default; }
.logistics-controls .crank-button { background: #d8f4e9; min-width: 124px; }
.crank-button svg { width: 32px; height: 32px; flex: 0 0 32px; }
.logistics-readout { display: flex; flex-direction: column; gap: 3px; flex: 1; min-width: 0; padding: 5px 7px; border: 1px solid #dbc6a6; border-radius: 10px; background: #fff4df; font: 600 11px/1.2 system-ui, sans-serif; color: #50424b; }
.app-shell[data-logistics="h2"] .field-stones::after { display: none; }
.app-shell[data-logistics="h2"] .logistics-readout { flex: 0 1 auto; max-width: 152px; }
/* Never render a decorative duplicate of a purchased capsule. Real ID-backed
   buttons carry all capsule motion and remain the only inventory subjects. */
.facility-motion-capsule { display: none !important; }
@media (min-width: 680px) {
  .app-shell[data-logistics="h2"] .status-text { display: none; }
  .app-shell[data-logistics="h2"] .automation-status { display: none !important; }
  .app-shell[data-logistics="h2"] .left-rail { pointer-events: none; }
  .app-shell[data-logistics="h2"] .left-rail button { pointer-events: auto; }
  .app-shell[data-logistics="h2"] .field-stone-button[data-location="receiving"] {
    top: 47%; left: 17%; bottom: auto; right: auto; width: 50px; height: 50px;
    min-width: 44px; min-height: 44px; transform: translate(-50%,-50%);
    border: none; background: none; box-shadow: none; touch-action: none; cursor: grab;
  }
  .app-shell[data-logistics="h2"] .field-stone-button[data-location="receiving"] .field-stone-art { width: 50px; height: 50px; }
  .app-shell[data-logistics="h2"] .field-stone-button[data-location="receiving"][data-receiving-slot="1"] { left: 11%; }
  .app-shell[data-logistics="h2"] .field-stone-button[data-location="receiving"][data-receiving-slot="2"] { left: 23%; }
  .app-shell[data-logistics="h2"][data-conveyor-level="0"] .field-stone-button[data-location="receiving"] { top: 54%; }
  .app-shell[data-logistics="h2"] .field-stone-button[data-location="output"] {
    top: auto; bottom: 10%; left: 85%; right: auto;
    width: 44px; min-width: 44px; height: 48px; min-height: 48px;
    transform: translateX(-50%); padding: 0;
  }
  .app-shell[data-logistics="h2"] .field-stone-button[data-output-slot="1"] { left: 90.5%; bottom: 7%; }
  .app-shell[data-logistics="h2"] .field-stone-button[data-output-slot="2"] { left: 96%; bottom: 4%; }
  .app-shell[data-logistics="h2"] .field-stone-button[data-location="output"] .field-stone-name { display: none; }
  .app-shell[data-logistics="h2"] .field-stone-button[data-location="output"] .field-stone-art { width: 34px; height: 34px; }
  .app-shell[data-logistics="h2"] .field-stone-button[data-location="receiving"] .field-stone-name,
  .app-shell[data-logistics="h2"] .field-stone-button[data-location="receiving"] .field-stone-hint { display: none; }
  .app-shell[data-logistics="h2"] .field-stone-button.is-dragging {
    z-index: 40 !important;
    transform: translate(calc(-50% + var(--drag-x, 0px)), calc(-50% + var(--drag-y, 0px))) scale(1.1) !important;
    transition: none;
  }
  .app-shell[data-logistics="h2"]:not(.transport-cycle) .facility-line-motion * { animation-play-state: paused; }
  .app-shell[data-logistics="h2"] .field-stone-button.is-transport-arrival {
    animation: logistics-arrival 350ms ease-out both;
  }
  @keyframes logistics-arrival {
    from { translate: -80px -25px; opacity: .6; }
    to { translate: 0 0; opacity: 1; }
  }
}
@media (prefers-reduced-motion: reduce) {
  .app-shell[data-logistics="h2"] .field-stone-button.is-transport-arrival { animation: none; }
}
