/* workspace.css */
.environment-bar {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-wrap: wrap;
  margin-bottom: var(--space-5);
  color: var(--ink-soft);
  font-size: var(--text-sm);
}

.environment-bar a {
  margin-left: auto;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand);
  box-shadow: var(--shadow-1);
}

.eyebrow {
  color: var(--brand-hover);
  font-size: var(--text-sm);
  letter-spacing: .08em;
  text-transform: uppercase;
  font-weight: 800;
  margin-bottom: var(--space-3);
}

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

.task-card {
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--space-5) var(--space-4);
  text-decoration: none;
  display: grid;
  grid-template-columns: 48px minmax(0,1fr) 12px;
  gap: var(--space-3);
  align-items: start;
  box-shadow: var(--shadow-1);
  min-height: 140px;
  transition: border-color .15s,transform .15s,box-shadow .15s;
}

.task-card:hover {
  border-color: var(--brand-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow-1);
}

.task-card strong {
  display: block;
  font-size: var(--text-lg);
  line-height: var(--leading-tight);
  margin-bottom: var(--space-2);
}

.task-card small {
  display: block;
  color: var(--ink-soft);
  font-size: var(--text-sm);
  line-height: var(--leading-normal);
}

.task-card .arrow {
  color: var(--brand-hover);
  font-weight: 800;
  margin-top: var(--space-1);
}

.icon-box {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-lg);
  background: var(--brand-soft);
  color: var(--brand-hover);
}

.manager-tools {
  margin-top: var(--space-5);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--brand-mist);
  padding: 0 var(--space-4);
}

.manager-tools>summary {
  font-size: var(--text-md);
  font-weight: 750;
  padding: var(--space-4) 0;
  min-height: 58px;
}

.manager-tools>p {
  color: var(--ink-soft);
}

.manager-tools .task-grid {
  padding-bottom: var(--space-4);
  grid-template-columns: repeat(2,minmax(0,1fr));
}

.manager-tools .task-card {
  box-shadow: none;
  min-height: 108px;
}

.record-details {
  margin-top: var(--space-4);
  color: var(--ink-soft);
  font-size: var(--text-sm);
}

.record-details summary {
  padding: var(--space-2) 0;
  min-height: 44px;
}

.record-details p {
  overflow-wrap: anywhere;
}

.versions-panel {
  border-top: 1px solid var(--line);
  margin-top: var(--space-6);
  padding-top: var(--space-3);
  scroll-margin-top: 160px;
  color: var(--ink-soft);
  font-size: var(--text-sm);
}

.versions-panel>summary {
  font-weight: 700;
  color: var(--brand-action);
  padding: var(--space-3) 0;
  min-height: 44px;
}

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

.versions-grid section {
  padding: var(--space-4);
  border: 1px solid var(--line);
  background: var(--brand-mist);
  border-radius: var(--radius-lg);
}

.versions-grid b {
  color: var(--brand-hover);
  font-size: var(--text-sm);
}

.versions-grid h3 {
  color: var(--ink);
  margin: var(--space-2) 0;
}

.versions-grid p:last-child {
  margin: 0;
}

.login-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-5);
  align-items: stretch;
  padding: var(--space-2) 0 var(--space-4);
}

.login-brand-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface-sunken);
  padding: var(--space-7) var(--space-6);
}

.login-brand-panel>img {
  width: 240px;
  max-width: 85%;
  height: auto;
  margin-bottom: var(--space-6);
}

.login-brand-panel h1 {
  font-size: var(--text-xl);
  max-width: 400px;
}

.login-brand-panel>p:not(.eyebrow) {
  font-size: var(--text-md);
  color: var(--ink-soft);
}

.brand-benefits {
  list-style: none;
  padding: 0;
  margin: var(--space-5) 0 0;
  display: grid;
  gap: var(--space-3);
}

.brand-benefits li {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-weight: 650;
  font-size: var(--text-base);
}

.login-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  box-shadow: var(--shadow-2);
}

.login-card h2 {
  font-size: var(--text-xl);
  letter-spacing: -.02em;
}

.login-card>p {
  color: var(--ink-soft);
}

.login-card form {
  border: 0;
  padding: 0;
  max-width: none;
  margin: var(--space-5) 0 var(--space-4);
}

.login-card .login-tip {
  font-size: var(--text-sm);
  line-height: var(--leading-normal);
  margin: 0;
}

.back-link {
  display: inline-flex;
  margin-top: var(--space-4);
  min-height: 44px;
  align-items: center;
  font-weight: 650;
}

@media(max-width:1023px) {
  .header-title {
    display: none;
  }

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

  .login-brand-panel {
    padding: var(--space-6) var(--space-5);
  }

  .login-card {
    padding: var(--space-6) var(--space-5);
  }
}

@media(max-width:599px) {
  .app-header {
    padding: var(--space-3) var(--space-4);
    gap: var(--space-2);
  }

  .header-logo {
    width: 120px;
    max-width: 31vw;
  }

  main {
    padding: var(--space-4) var(--space-4) var(--space-5);
  }

  .environment-bar {
    gap: var(--space-2);
    font-size: var(--text-sm);
    margin-bottom: var(--space-5);
  }

  .environment-bar a {
    margin-left: 0;
  }

  .login-layout {
    grid-template-columns: 1fr;
    gap: var(--space-4);
    padding-top: 0;
  }

  .login-brand-panel {
    padding: var(--space-5);
  }

  .login-brand-panel>img {
    display: none;
  }

  .login-brand-panel h1 {
    font-size: var(--text-2xl);
  }

  .login-brand-panel .eyebrow {
    margin-bottom: var(--space-2);
  }

  .login-brand-panel>p:not(.eyebrow) {
    font-size: var(--text-base);
    margin-bottom: 0;
  }

  .brand-benefits {
    display: none;
  }

  .login-card {
    padding: var(--space-5) var(--space-5);
  }

  .login-card h2 {
    font-size: var(--text-xl);
  }

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

  .task-steps {
    grid-template-columns: 1fr;
    gap: var(--space-2);
  }

  .task-steps li {
    padding: var(--space-2) var(--space-3);
  }

  .task-steps span {
    width: 25px;
    height: 25px;
  }

  .manager-tools .task-grid {
    grid-template-columns: 1fr;
  }

  .header-actions {
    gap: var(--space-1);
  }

  .header-actions>a,.header-actions summary {
    font-size: var(--text-sm);
    padding: var(--space-2) var(--space-2);
  }

  .live td,.live th {
    padding: var(--space-2);
    font-size: var(--text-sm);
  }

  form {
    padding: var(--space-4);
  }

  .page-heading h1 {
    font-size: var(--text-xl);
  }
}

@media(max-width:599px) {
  .task-grid,.cards,.grid {
    grid-template-columns: 1fr;
  }

  .task-card {
    min-height: 114px;
    padding: var(--space-4);
  }

  .task-card strong {
    font-size: var(--text-md);
  }

  .section-heading {
    margin-top: var(--space-5);
  }

  .header-logo {
    width: 100px;
  }

  .app-header {
    gap: var(--space-2);
  }

  .header-actions>a,.header-actions summary {
    padding: var(--space-2);
    font-size: var(--text-sm);
  }

  .manager-tools {
    padding: 0 var(--space-4);
  }

  .form-actions {
    flex-direction: column;
  }

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

  .login-brand-panel {
    padding: var(--space-4);
  }

  .login-brand-panel h1 {
    font-size: var(--text-xl);
  }

  .account-panel {
    min-width: 190px;
  }

  .environment-bar>span:last-child {
    font-size: var(--text-sm);
  }
}

@media(prefers-reduced-motion:reduce) {
  *,*::before,*::after {
    transition: none!important;
    scroll-behavior: auto!important;
  }
}

@media(min-width:600px) and (max-width:1023px) {
  .daily-group .task-grid {
    grid-template-columns: repeat(3,minmax(0,1fr));
  }

  .task-card {
    padding: var(--space-4) var(--space-4);
    grid-template-columns: 40px minmax(0,1fr) 10px;
    gap: var(--space-2);
    min-height: 132px;
  }

  .task-card .icon-box {
    width: 40px;
    height: 40px;
  }

  .task-card strong {
    font-size: var(--text-md);
  }
}

/* form-layout.css */
.live form>.notice,.live form>.success {
  margin: var(--space-5) 0;
}

.live form>button {
  margin-top: var(--space-2);
  margin-right: var(--space-2);
}

.live form>button:last-child {
  margin-right: 0;
}

.live .record-panel>form {
  margin-top: var(--space-4);
}

.live .record-panel>form:first-child {
  margin-top: 0;
}

.live details>form {
  margin-top: var(--space-3);
}

.live .form-actions {
  margin-top: var(--space-5);
  padding-top: var(--space-4);
  border-top: 1px solid var(--line);
}

.live .form-actions button {
  margin: 0;
}

.table-scroll {
  max-width: 100%;
  overflow-x: auto;
  border-radius: var(--radius-md);
}

.table-scroll table {
  min-width: 620px;
}

.approval-page .record-panel {
  padding: var(--space-5);
  margin: var(--space-4) 0;
}

.approval-page .record-panel>label {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
}

.approval-page .record-panel>p {
  color: var(--ink-soft);
}

.approval-page main details {
  margin-top: var(--space-4);
  border-top: 1px solid var(--line);
  padding-top: var(--space-2);
}

.approval-page main details summary {
  color: var(--brand-action);
  font-weight: 700;
  padding: var(--space-2) 0;
}

.approval-page main details form {
  max-width: none;
  padding: var(--space-4);
  background: var(--brand-mist);
  border-radius: var(--radius-md);
}

.approval-page main details textarea {
  margin-bottom: var(--space-3);
}

.approval-page #batch-approval {
  max-width: none;
  padding: 0;
  border: 0;
  background: transparent;
  margin: var(--space-5) 0 var(--space-6);
}

@media(max-width:599px) {
  .live form>button {
    width: 100%;
    margin: var(--space-2) 0 0;
  }

  .live .form-actions {
    display: flex;
    flex-direction: column;
  }

  .live .form-actions button {
    width: 100%;
  }

  .approval-page .record-panel {
    padding: var(--space-4);
  }

  .approval-page .live td,.approval-page .live th {
    min-width: 130px;
  }
}

/* staff-feedback.css */
.choice-chips>div {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.choice-chips label {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 45px;
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  cursor: pointer;
}

.choice-chips label:has(input:checked) {
  border-color: var(--brand-action);
  background: var(--brand-soft);
  color: var(--brand-deep);
  font-weight: 750;
}

.choice-chips input {
  margin: 0;
}

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

.table-button-grid button {
  min-height: 42px;
  margin: 0;
  padding: var(--space-2);
}

.table-button-grid button.active {
  background: var(--brand-action);
  color: var(--surface);
}

.blocker-panel {
  grid-column: 1/-1;
}

.blocker-panel li {
  margin: var(--space-2) 0;
}

.calculation-box {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-4);
  margin: var(--space-4) 0;
  padding: var(--space-4) var(--space-4);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--brand-soft);
}

.calculation-box span {
  font-size: var(--text-lg);
  font-weight: 800;
  color: var(--brand-deep);
}

.form-error-summary {
  outline: 3px solid transparent;
}

.form-error-summary strong {
  display: block;
  margin-bottom: var(--space-2);
}

.form-error-summary ul {
  margin: 0;
  padding-left: var(--space-5);
}

.form-error-summary li {
  margin: var(--space-1) 0;
}

@media(max-width:599px) {
  .choice-chips>div {
    display: grid;
    grid-template-columns: repeat(2,minmax(0,1fr));
  }

  .choice-chips label {
    justify-content: center;
  }

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

  .calculation-box {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* material-ui.css */
.material-picker {
  display: grid;
  grid-template-columns: minmax(140px,.75fr) minmax(190px,1.5fr);
  gap: var(--space-3);
  width: 100%;
}

.material-picker>span {
  min-width: 0;
}

.material-picker select,.menu-material-picker select {
  width: 100%;
  min-width: 0;
}

.material-unit-hint {
  display: block;
  margin-top: var(--space-1);
}

.menu-material-picker {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: var(--space-3);
  width: 100%;
}

.menu-exact {
  grid-column: 1/-1;
}

.workflow-section {
  margin: var(--space-3) 0 var(--space-5);
}

.workflow-section h2 {
  font-size: var(--text-lg);
  margin: 0 0 var(--space-4);
}

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

.workflow-fields>.form-field:has(.material-picker),.workflow-fields>.form-field:has(.menu-material-picker) {
  grid-column: 1/-1;
}

.workflow-fields .form-field {
  margin: 0;
}

.workflow-extra {
  border-top: 1px solid var(--border);
  padding-top: var(--space-4);
  margin-top: var(--space-4);
}

.workflow-extra summary {
  cursor: pointer;
  font-weight: 600;
  margin-bottom: var(--space-4);
}

.stock-filter {
  display: block;
  max-width: 420px;
  margin-bottom: var(--space-4);
}

.material-feedback {
  max-width: 1000px;
  margin: auto;
}

.material-feedback>form {
  max-width: none;
}

.material-feedback .workflow-fields>.form-field:has(select[multiple]) {
  grid-column: 1/-1;
}

.recipe-editor {
  max-width: 1020px;
  margin: auto;
}

.recipe-editor h1 {
  margin-bottom: var(--space-2);
}

.recipe-section {
  background: var(--surface);
  border: 1px solid var(--info-bd);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  margin: var(--space-4) 0;
}

.recipe-section h2 {
  font-size: var(--text-lg);
  margin: 0 0 var(--space-4);
}

.recipe-section form,.recipe-editor>form {
  max-width: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.recipe-mode {
  display: flex;
  gap: var(--space-4);
  margin-bottom: var(--space-4);
}

.recipe-mode label {
  flex: 1;
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3);
  background: var(--surface-sunken);
  border: 1px solid var(--info-bd);
  border-radius: var(--radius-sm);
}

.recipe-mode input {
  width: auto;
  margin: 0;
}

.recipe-reference {
  max-width: 440px;
}

.recipe-inputs {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.recipe-input-row {
  display: grid;
  grid-template-columns: minmax(360px,1fr) minmax(120px,180px) 64px;
  align-items: start;
  gap: var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-4);
  background: var(--surface);
}

.recipe-input-row .form-field {
  margin: 0;
}

.recipe-amount input {
  width: 100%;
}

.recipe-amount {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.recipe-unit {
  font-weight: 700;
  min-width: 30px;
}

.recipe-row-extra {
  grid-column: 1/-1;
  border-top: 1px solid var(--border);
  padding-top: var(--space-2);
}

.recipe-row-extra summary {
  cursor: pointer;
  font-size: var(--text-sm);
}

.recipe-extra-grid {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: var(--space-3);
  margin-top: var(--space-3);
}

.recipe-remove {
  margin-top: var(--space-5);
  padding: var(--space-2) var(--space-2);
  font-size: var(--text-sm);
}

.recipe-input-row .measured input {
  display: none;
}

.recipe-footer {
  display: flex;
  gap: var(--space-3);
  align-items: center;
  flex-wrap: wrap;
  margin: var(--space-5) 0;
}

.recipe-history {
  margin: var(--space-5) 0;
  border-top: 1px solid var(--info-bd);
  padding-top: var(--space-4);
}

.recipe-history summary {
  cursor: pointer;
  font-weight: 600;
}

.recipe-hint {
  margin: 0 0 var(--space-4);
  color: var(--text-secondary);
}

.recipe-basis {
  margin-top: var(--space-4);
}

.recipe-empty {
  margin: var(--space-3) 0;
}

.recipe-section:has([data-boba-basis][hidden]) {
  min-height: 0;
}

@media(max-width:599px) {
  .material-picker,.menu-material-picker,.workflow-fields {
    grid-template-columns: 1fr;
  }

  .recipe-input-row {
    grid-template-columns: 1fr 64px;
  }

  .recipe-input-row>.form-field {
    grid-column: 1/-1;
  }

  .recipe-input-row>[data-recipe-quantity] {
    grid-column: 1;
  }

  .recipe-remove {
    grid-column: 2;
    grid-row: 2;
    margin-top: var(--space-5);
  }

  .recipe-mode {
    flex-direction: column;
    gap: var(--space-2);
  }

  .recipe-section {
    padding: var(--space-4);
  }

  .recipe-extra-grid {
    grid-template-columns: 1fr;
  }

  .recipe-input-row .material-picker {
    grid-template-columns: 1fr;
  }

  .recipe-footer {
    align-items: stretch;
    flex-direction: column;
  }
}

.live input.generated-code:disabled {
  background: var(--surface-sunken);
  border-color: var(--border-strong);
  color: var(--text-secondary);
  -webkit-text-fill-color: var(--text-secondary);
  opacity: 1;
  cursor: default;
}

.live .form-field:has(.generated-code) .field-hint {
  margin-top: var(--space-1);
}

/* store-workflow.css */
.store-employee-dialog {
  width: min(92vw,560px);
  max-height: 85vh;
  overflow: auto;
  border: 1px solid var(--info-bd);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  background: var(--surface);
  color: var(--text);
}

.store-employee-dialog::backdrop {
  background: var(--overlay);
}

.store-employee-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(120px,1fr));
  gap: var(--space-3);
  margin-top: var(--space-4);
}

.store-employee-grid button {
  min-height: 64px;
  font-size: var(--text-md);
}

.store-credit-label {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
  margin: var(--space-3) 0;
}

.store-prepayment {
  padding: var(--space-4) 0;
  border-top: 1px solid var(--border);
}

.store-report-filters {
  display: flex;
  align-items: end;
  gap: var(--space-3);
  flex-wrap: wrap;
}

.store-report-filters p {
  flex: 1 1 170px;
}

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

.store-table-wrap table {
  width: 100%;
  border-collapse: collapse;
}

.store-table-wrap th,.store-table-wrap td {
  padding: var(--space-2);
  text-align: left;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.fulfillment-list .choice-row {
  align-items: start;
}

.fulfillment-list input[type=checkbox] {
  width: 20px;
  height: 20px;
  flex: none;
}

.fulfillment-action {
  flex-wrap: wrap;
}

.plain-history li small {
  display: block;
}

.store-draft-hint {
  margin: var(--space-3) 0;
}

@media(max-width:599px) {
  .store-employee-grid {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }

  .fulfillment-unit {
    display: block;
  }

  .fulfillment-action {
    margin-top: var(--space-2);
  }

  .store-report-filters {
    display: block;
  }
}

.header-actions .shift-button {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  min-height: 48px;
  padding: var(--space-2) var(--space-3);
  background: var(--brand-soft);
  color: var(--info-fg);
  border: 1px solid var(--info-bd);
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: var(--text-sm);
  line-height: var(--leading-tight);
  font-weight: 600;
  max-width: 100%;
  flex-wrap: wrap;
}

.shift-button strong {
  overflow-wrap: anywhere;
}

#store-shift-dialog button[aria-pressed="true"] {
  outline: 3px solid var(--brand);
}

.cash-shortcut-buttons {
  display: flex;
  gap: var(--space-2);
  flex-wrap: wrap;
  margin: var(--space-2) 0;
}

.cash-shortcut-buttons button {
  min-width: 52px;
  min-height: 48px;
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-base);
}

.cash-shortcuts [role="alert"] {
  color: var(--danger-fg);
}

.live .store-contribution-table {
  table-layout: auto;
  min-width: 1200px;
}

.store-table-wrap:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 3px;
}

.store-employee-dialog {
  box-sizing: border-box;
  width: min(560px,calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  max-height: calc(100dvh - 32px);
  overflow: auto;
  overscroll-behavior: contain;
}

.store-employee-dialog[open] {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.store-employee-dialog>div,.store-employee-dialog>p {
  flex-shrink: 0;
}

.store-employee-dialog .dialog-head {
  gap: var(--space-3);
  flex-wrap: wrap;
}

.store-employee-dialog .dialog-head h2 {
  margin: 0;
  min-width: 0;
  flex: 1 1 160px;
  overflow-wrap: anywhere;
}

.store-employee-dialog .dialog-head button {
  flex: none;
}

.store-employee-dialog .store-employee-grid {
  margin: 0;
  min-width: 0;
}

.store-employee-dialog .store-employee-grid button {
  min-width: 0;
  white-space: normal;
  overflow-wrap: anywhere;
  line-height: var(--leading-tight);
}

.store-employee-dialog .field-hint {
  margin: 0;
  line-height: var(--leading-normal);
  overflow-wrap: anywhere;
}

.store-employee-dialog>.notice {
  margin: 0;
}

.fulfillment-action {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: var(--space-3);
  min-width: 240px;
}

.fulfillment-action>.maker-credit {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: var(--space-2);
  margin: 0;
}

.fulfillment-action>.maker-credit>span {
  display: block;
}

.fulfillment-action>.maker-credit button {
  min-height: 44px;
  padding: var(--space-2) var(--space-3);
}

.fulfillment-action>button {
  min-width: 200px;
  margin: 0;
}

@media(max-width:599px) {
  .fulfillment-action {
    min-width: 0;
    align-items: stretch;
    margin-top: var(--space-4);
  }

  .fulfillment-action>.maker-credit {
    align-items: flex-start;
  }

  .fulfillment-action>button {
    width: 100%;
    min-width: 0;
  }
}

.bulk-completion {
  margin-top: var(--space-5);
  padding-top: var(--space-4);
  border-top: 1px solid var(--line);
}

.bulk-completion>.maker-credit {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-wrap: wrap;
}

.bulk-completion .form-actions {
  gap: var(--space-3);
  align-items: stretch;
}

.bulk-completion .form-actions>button {
  margin: 0;
  min-height: 52px;
}

.order-detail-actions {
  display: flex;
  gap: var(--space-3);
  align-items: center;
  flex-wrap: wrap;
  margin: var(--space-4) 0;
}

.order-detail-actions>a {
  margin: 0;
  min-height: 52px;
}

.restaurant .receipt-action {
  margin: var(--space-3) 0 var(--space-4);
  display: inline-flex;
}

.restaurant .payment-redirect {
  margin: var(--space-4) 0 var(--space-3);
}

@media(max-width:599px) {
  .bulk-completion .form-actions>button {
    flex: 1 1 100%;
  }

  .order-detail-actions>a {
    width: 100%;
  }
}

.fulfillment-panel {
  overflow-anchor: none;
}

.order-detail-actions .receipt-print-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  margin: 0;
  box-sizing: border-box;
}

.order-detail-actions .go-to-payment {
  margin: 0;
}

.order-entry-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3);
}

.store-employee-dialog .store-employee-grid button {
  padding-inline: var(--space-3);
}

.recording-context {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  flex-wrap: wrap;
  padding: var(--space-3) var(--space-4);
  margin: 0 0 var(--space-4);
  border: 1px solid var(--info-bd);
  border-radius: var(--radius-md);
  background: var(--brand-soft);
  color: var(--info-fg);
  overflow-wrap: anywhere;
}

.recording-context[hidden] {
  display: none;
}

.recording-context>span {
  flex: 1 1 220px;
  min-width: 0;
}

.recording-context>button {
  margin: 0;
  max-width: 100%;
}

[data-recording-note]:not([hidden]) {
  padding: var(--space-2) var(--space-3);
  border-left: 3px solid var(--brand);
  background: var(--brand-soft);
  overflow-wrap: anywhere;
}

/* navigation.css */
/* Permission-filtered navigation, with bottom controls on narrow phones. */
.live .app-header.compact-header { position: sticky; top: 0; z-index: 30; height: var(--header-h); min-height: var(--header-h); padding: 0 var(--page-gutter); display: flex; align-items: center; gap: var(--space-3); border-bottom: 1px solid var(--border); background: var(--surface); }
.brand-lockup { display: flex; align-items: center; flex: none; min-width: var(--control-h); min-height: var(--control-h); }
.header-logo { display: block; width: 36px; height: 36px; object-fit: contain; }
.current-page { min-width: 0; max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.header-actions { display: flex; align-items: center; justify-content: flex-end; gap: var(--space-2); margin-left: auto; flex-wrap: nowrap; }
.header-actions > a, .header-actions > button, .header-actions summary, .shift-button { min-width: var(--control-h); min-height: var(--control-h); display: flex; align-items: center; justify-content: center; padding: 0 var(--space-3); margin: 0; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); color: var(--text); font-size: var(--text-sm); font-weight: 600; text-decoration: none; white-space: nowrap; }
.shift-button { max-width: 140px; overflow: hidden; }
.shift-button strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.language-button { color: var(--brand-hover); }
.primary-navigation { display: flex; justify-content: center; gap: var(--space-1); flex: 1; min-width: 0; }
.primary-navigation a { display: flex; align-items: center; justify-content: center; gap: var(--space-2); min-height: var(--control-h); padding: var(--space-2); border-radius: var(--radius-sm); color: var(--text); text-decoration: none; font-size: var(--text-sm); font-weight: 600; white-space: nowrap; }
.primary-navigation a[aria-current=page] { background: var(--brand-hover); color: var(--surface); }
.primary-navigation .icon { width: 18px; height: 18px; }
.account-menu { position: relative; margin: 0; }
.account-menu > summary { list-style: none; }
.account-menu > summary::-webkit-details-marker { display: none; }
.navigation-panel { position: absolute; right: 0; top: calc(100% + var(--space-2)); width: min(360px, calc(100vw - var(--space-6))); max-height: calc(100dvh - 96px); overflow-y: auto; overscroll-behavior: contain; padding: var(--space-3); border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow-2); }
details:not([open]) > .navigation-panel { display: none; }
.navigation-panel a, .navigation-panel button { display: flex; align-items: center; width: 100%; min-height: var(--control-h); padding: var(--space-3); margin: 0; border-radius: var(--radius-sm); font-size: var(--text-sm); white-space: normal; text-decoration: none; }
.navigation-panel form { padding: 0; margin: 0; border: 0; }
.navigation-group { border-top: 1px solid var(--border); margin-top: var(--space-2); padding-top: var(--space-2); }
.navigation-group > strong { display: block; color: var(--text-secondary); padding: var(--space-2) var(--space-3); font-size: var(--text-sm); }
.navigation-dot { width: 6px; height: 6px; border-radius: var(--radius-pill); background: var(--danger-fg); margin-left: var(--space-1); }
.live dialog { max-width: calc(100vw - var(--space-6)); max-height: calc(100dvh - var(--space-6)); overflow-y: auto; overscroll-behavior: contain; }
.live dialog .dialog-head { background: var(--surface); }
@media (min-width: 600px) and (max-width: 1023px) {
  .live:has(.compact-header .primary-navigation a) {
    --header-h: calc(var(--control-h) * 2 + var(--space-1) * 3 + 1px);
  }
  .live .app-header.compact-header:has(.primary-navigation a) {
    flex-wrap: wrap;
    gap: var(--space-1) var(--space-2);
    padding-block: var(--space-1);
    height: auto;
  }
  .compact-header .primary-navigation {
    order: 1;
    flex: 0 0 100%;
  }
  .primary-navigation a {
    flex: 1 1 0;
    min-width: 0;
    padding: var(--space-1);
    gap: var(--space-1);
    text-align: center;
  }
}
@media (max-width: 1023px) {
  .current-page { flex: 1; max-width: none; }
  .navigation-panel { position: fixed; top: calc(var(--header-h) + var(--space-2)); right: var(--space-2); max-height: calc(100dvh - var(--header-h) - var(--space-5)); }
}
@media (max-width: 599px) {
  .live .app-header.compact-header { column-gap: var(--space-2); padding-inline: var(--space-3); }
  .primary-navigation { position: fixed; inset: auto 0 0; z-index: 50; gap: var(--space-1); padding: var(--space-1) var(--space-2) calc(var(--space-1) + env(safe-area-inset-bottom, 0px)); background: var(--surface); border-top: 1px solid var(--border); }
  .primary-navigation a { flex: 1 1 0; flex-direction: column; min-width: 0; padding: var(--space-1); gap: var(--space-1); font-size: var(--text-xs); white-space: normal; overflow-wrap: anywhere; text-align: center; }
  .live:has(.primary-navigation a) main { padding-bottom: calc(var(--space-8) + var(--space-6) + env(safe-area-inset-bottom, 0px)); }
  .live[data-keyboard-open=true] .primary-navigation { display: none; }
  .navigation-panel { max-height: calc(100dvh - var(--header-h) - var(--space-8) - var(--space-5) - env(safe-area-inset-bottom, 0px)); }
  .current-page { font-size: var(--text-sm); }
  .header-actions { gap: var(--space-1); }
  .header-actions > a, .header-actions > button, .header-actions summary, .shift-button { padding-inline: var(--space-2); }
  .shift-button { max-width: 96px; }
}

@media (max-width: 599px) { .current-page { display: none; } }
.staff-fullscreen-icon { display: none; }

[data-fullscreen-leave-dialog] {
  width: min(420px, calc(100vw - 24px));
  padding: var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}
[data-fullscreen-leave-dialog] > div {
  display: flex;
  justify-content: end;
  gap: var(--space-2);
}

@media (max-width: 430px) {
  .header-actions [data-staff-fullscreen] {
    min-inline-size: 44px;
    padding-inline: 6px;
  }
  .staff-fullscreen-icon { display: inline; font-size: 18px; line-height: 1; }
  .header-actions [data-fullscreen-label] { display: none; }
}

/* account-switch.css */
.live .account-switch-dialog,.live .account-switch-page {
  width: min(460px,calc(100vw - 32px));
  box-sizing: border-box;
  padding: var(--space-4);
  border: 1px solid var(--line,var(--info-bd));
  border-radius: var(--radius-lg);
  background: var(--surface);
  color: var(--ink,var(--text));
}

.live .account-switch-dialog::backdrop {
  background: var(--overlay);
}

.live .account-switch-dialog .dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
}

.live .account-switch-dialog h2 {
  font-size: var(--text-lg);
  margin: 0;
}

.live .account-switch-dialog form,.live .account-switch-page form {
  display: grid;
  gap: var(--space-4);
  margin: var(--space-4) 0 0;
  padding: 0;
  border: 0;
  box-shadow: none;
  background: none;
}

.live .account-switch-dialog label,.live .account-switch-page label {
  display: grid;
  gap: var(--space-2);
  font-weight: 700;
}

.live .account-switch-dialog input,.live .account-switch-page input {
  width: 100%;
  min-width: 0;
  font-size: var(--text-base);
}

.live .account-switch-dialog .notice[hidden],.live .team-form [hidden] {
  display: none;
}

.live .account-switch-page {
  margin: var(--space-5) auto;
}

.live .account-switch-dialog button {
  min-height: 48px;
}

.live .team-form[data-terminal-account] .permission-section,.live .team-form[data-terminal-account] .owner-only {
  display: none;
}
