:root {
  color-scheme: light;
  --ink: #070707;
  --muted: #5f5a50;
  --line: #ece5d7;
  --line-dark: #dfcfaa;
  --paper: #ffffff;
  --surface: #ffffff;
  --soft: #fff9ec;
  --soft-2: #f4efe5;
  --brand: #f7ad00;
  --brand-strong: #e49c00;
  --brand-soft: #fff0bf;
  --black: #050505;
  --danger: #9d1c16;
  --warning: #8b5b00;
  --success: #0b0b0b;
  --blue: #111111;
  --shadow: 0 18px 42px rgba(28, 20, 2, 0.08);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-width: 320px;
  min-height: 100vh;
}

body {
  margin: 0;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  color: var(--ink);
  background: #fbf8f1;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: rgba(247, 173, 0, 0.22);
}

input:focus,
select:focus,
textarea:focus,
button:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(247, 173, 0, 0.38);
  outline-offset: 2px;
}

button {
  border: 0;
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.shell {
  min-height: 100vh;
}

.header {
  position: sticky;
  top: 0;
  z-index: 10;
  min-height: 132px;
  display: grid;
  grid-template-columns: minmax(150px, auto) minmax(0, 1fr) 190px;
  align-items: center;
  gap: 18px;
  padding: 12px 20px;
  border-bottom: 3px solid var(--brand);
  color: var(--ink);
  background: #fff;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0;
}

.logo-symbol {
  position: relative;
  width: 128px;
  height: 138px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
  padding: 0;
  border-radius: 0;
  background: transparent;
}

.logo-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.brand-name {
  font-size: 18px;
  line-height: 1;
  font-weight: 950;
  letter-spacing: 0;
}

.brand-line {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.nav {
  display: flex;
  gap: 7px;
  overflow-x: auto;
  scrollbar-width: none;
}

.nav::-webkit-scrollbar {
  display: none;
}

.menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  min-height: 44px;
  border-radius: 10px;
  padding: 0;
  border: 1px solid rgba(247, 173, 0, 0.56);
  font-size: 20px;
  color: var(--ink);
  background: var(--brand);
}

.mobile-nav {
  display: none;
}

.mobile-nav.open {
  display: block;
}

.nav-button {
  min-height: 38px;
  flex: 0 0 auto;
  padding: 0 12px;
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  font-size: 12px;
  font-weight: 900;
}

.nav-button.active,
.nav-button:hover {
  color: #111;
  border-color: var(--brand);
  background: var(--brand);
}

.nav-button.locked {
  color: rgba(7, 7, 7, 0.32);
}

.role-picker,
.filter-picker {
  display: grid;
  gap: 6px;
  font-size: 10px;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.role-picker select,
.filter-picker select {
  width: 100%;
  min-height: 38px;
  padding: 0 10px;
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: none;
}

.role-picker {
  color: var(--muted);
}

.auth-status {
  min-width: 190px;
  display: grid;
  gap: 4px;
  justify-items: end;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.auth-status span,
.auth-status strong {
  max-width: 210px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.auth-status strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 950;
}

.main {
  width: min(1440px, 100%);
  margin: 0 auto;
  padding: 20px;
}

.context-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 240px;
  gap: 16px;
  align-items: end;
  margin-bottom: 16px;
  padding: 16px;
  border: 1px solid var(--line-dark);
  border-left: 6px solid var(--brand);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: var(--shadow);
}

.kicker {
  margin: 0 0 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 5px;
  font-size: 28px;
  line-height: 1.05;
  font-weight: 950;
}

.role-summary {
  max-width: 760px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

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

.span-12 {
  grid-column: span 12;
}

.span-8 {
  grid-column: span 8;
}

.span-7 {
  grid-column: span 7;
}

.span-5 {
  grid-column: span 5;
}

.span-4 {
  grid-column: span 4;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.metric-card,
.panel,
.attention-item,
.status-card,
.availability-card,
.control-card,
.mobile-card {
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.metric-card {
  min-height: 96px;
  display: grid;
  align-content: space-between;
  padding: 13px;
  position: relative;
  overflow: hidden;
}

.metric-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 5px;
  background: var(--brand);
}

.metric-card strong {
  margin-top: 8px;
  font-size: 30px;
  line-height: 1;
  font-weight: 950;
}

.metric-card span {
  margin-top: 12px;
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
  color: var(--ink);
}

.metric-card small {
  color: var(--muted);
  font-size: 12px;
}

.panel {
  min-width: 0;
  padding: 15px;
}

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

.panel-head h2 {
  margin-bottom: 0;
  font-size: 16px;
  line-height: 1.15;
  font-weight: 950;
}

.panel-head p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.pill {
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  justify-content: center;
  padding: 0 9px;
  border: 1px solid var(--line-dark);
  border-radius: 999px;
  color: var(--muted);
  background: var(--soft);
  font-size: 11px;
  font-weight: 950;
  white-space: nowrap;
}

.pill.neutral {
  color: var(--ink);
  border-color: var(--line-dark);
  background: #fff;
}

.pill.good {
  color: var(--success);
  border-color: rgba(247, 173, 0, 0.5);
  background: var(--brand-soft);
}

.pill.warn {
  color: var(--warning);
  border-color: rgba(247, 173, 0, 0.62);
  background: rgba(247, 173, 0, 0.16);
}

.pill.danger {
  color: var(--danger);
  border-color: rgba(179, 38, 30, 0.28);
  background: rgba(179, 38, 30, 0.08);
}

.button,
.danger-button,
.text-button {
  min-height: 36px;
  min-width: 0;
  max-width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 950;
  line-height: 1.15;
  text-align: center;
  white-space: normal;
  overflow-wrap: anywhere;
}

.button,
.danger-button {
  padding: 0 12px;
  color: #050505;
  background: var(--brand);
}

.danger-button {
  color: #fff;
  background: var(--black);
}

.text-button {
  padding: 0 10px;
  border: 1px solid var(--line-dark);
  color: #111;
  background: #fff;
}

.text-button.danger-text {
  color: var(--danger);
  border-color: rgba(179, 38, 30, 0.32);
}

.text-button.good-action {
  color: var(--ink);
  border-color: rgba(247, 173, 0, 0.66);
  background: var(--brand-soft);
}

.map-link {
  margin-top: 8px;
}

.mini-map {
  width: min(260px, 100%);
  height: 142px;
  margin-top: 8px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.mini-map iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

.text-button.inverse {
  min-height: 30px;
  color: #fff;
  border-color: rgba(5, 5, 5, 0.96);
  background: #050505;
}

.text-button:hover,
.button:hover {
  filter: brightness(0.98);
  transform: translateY(-1px);
}

.processing-overlay {
  position: fixed;
  inset: 0;
  z-index: 35;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(17, 17, 17, 0.18);
  backdrop-filter: blur(2px);
}

.processing-card {
  width: min(360px, 100%);
  min-height: 82px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 13px;
  align-items: center;
  padding: 16px;
  border: 1px solid rgba(17, 17, 17, 0.12);
  border-radius: 8px;
  color: #111;
  background: #fff;
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.18);
}

.processing-card strong,
.processing-card span {
  display: block;
}

.processing-card strong {
  font-size: 13px;
  font-weight: 950;
}

.processing-card span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}

.processing-spinner {
  width: 30px;
  height: 30px;
  margin: 0;
  border: 3px solid var(--line-dark);
  border-top-color: var(--brand);
  border-radius: 999px;
  animation: processing-spin 0.8s linear infinite;
}

@keyframes processing-spin {
  to {
    transform: rotate(360deg);
  }
}

.attention-list,
.audit-list,
.report-list,
.pipeline {
  display: grid;
  gap: 10px;
}

.attention-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  box-shadow: none;
}

.attention-item strong,
.row-title strong {
  display: block;
  font-size: 13px;
  font-weight: 950;
}

.attention-item span,
.row-title span,
.attention-item small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.attention-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pipeline-row {
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr) 28px;
  align-items: center;
  gap: 10px;
}

.pipeline-row strong {
  display: block;
  font-size: 12px;
  font-weight: 950;
}

.pipeline-row span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.25;
}

.pipeline-row b {
  font-size: 12px;
  text-align: right;
}

.bar {
  height: 9px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--soft-2);
}

.bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--brand);
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.data-table {
  width: 100%;
  min-width: 820px;
  border-collapse: collapse;
  background: #fff;
}

.data-table.compact-table {
  min-width: 640px;
}

.data-table th,
.data-table td {
  padding: 11px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
  font-size: 12px;
}

.data-table th {
  color: var(--muted);
  background: var(--soft);
  font-size: 10px;
  font-weight: 950;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.data-table tr:last-child td {
  border-bottom: 0;
}

.segmented {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.segmented button {
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  color: #111;
  background: #fff;
  font-size: 12px;
  font-weight: 950;
}

.segmented button.active {
  color: #050505;
  border-color: var(--brand);
  background: var(--brand);
}

.mobile-list {
  display: none;
}

.card-grid,
.availability-grid,
.control-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

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

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

.control-grid.simple-controls {
  grid-template-columns: minmax(0, 1fr);
}

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

.card-grid.one-col {
  grid-template-columns: minmax(0, 1fr);
}

.status-card,
.availability-card,
.control-card {
  min-width: 0;
  padding: 14px;
  box-shadow: none;
}

.status-card {
  border-color: rgba(223, 207, 170, 0.86);
}

.status-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.status-card h3,
.availability-card h3,
.control-card h3 {
  margin-bottom: 4px;
  font-size: 15px;
  line-height: 1.15;
  font-weight: 950;
}

.status-card p,
.availability-card p,
.control-card p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.details-grid {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 8px 10px;
  padding: 10px;
  border-radius: 8px;
  background: var(--soft);
}

.details-grid span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.details-grid strong {
  min-width: 0;
  font-size: 12px;
  font-weight: 950;
  overflow-wrap: anywhere;
}

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

.center-number {
  min-height: 66px;
  display: grid;
  align-content: space-between;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdf7;
}

.center-number.good {
  border-color: rgba(247, 173, 0, 0.5);
  background: var(--brand-soft);
}

.center-number.danger {
  border-color: rgba(179, 38, 30, 0.3);
  background: rgba(179, 38, 30, 0.08);
}

.center-number.danger strong {
  color: var(--danger);
}

.center-number span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
}

.center-number strong {
  font-size: 22px;
  line-height: 1;
  font-weight: 950;
}

.rider-quick-list {
  display: grid;
  gap: 10px;
}

.rider-quick-card {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdf7;
}

.rider-quick-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.rider-quick-head strong,
.rider-quick-head span,
.rider-location-line strong,
.rider-location-line small {
  min-width: 0;
  overflow-wrap: anywhere;
}

.rider-quick-head strong {
  display: block;
  font-size: 14px;
  line-height: 1.2;
  font-weight: 950;
}

.rider-quick-head span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.rider-location-line {
  display: grid;
  gap: 3px;
  margin-top: 10px;
}

.rider-location-line span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
}

.rider-location-line strong {
  font-size: 12px;
  line-height: 1.3;
  font-weight: 950;
}

.rider-location-line small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.meal-action-box {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.meal-action-box label {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.meal-action-box input {
  min-height: 36px;
  width: 100%;
  padding: 0 10px;
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  font-size: 13px;
  font-weight: 850;
}

.button,
.danger-button,
.text-button,
.nav-button,
.segmented button {
  transition:
    background-color 0.16s ease,
    border-color 0.16s ease,
    color 0.16s ease,
    transform 0.16s ease,
    filter 0.16s ease;
}

.issue-line,
.inventory-line,
.reason-line {
  margin-top: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  color: var(--warning);
  background: rgba(247, 173, 0, 0.12);
  font-size: 11px;
  font-weight: 850;
  line-height: 1.35;
}

.reason-line {
  color: var(--muted);
  background: var(--soft);
}

.ad-preview {
  min-height: 76px;
  display: grid;
  place-items: center;
  margin-bottom: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: #111;
  background:
    linear-gradient(135deg, rgba(247, 173, 0, 0.24), transparent),
    var(--soft);
  text-align: center;
}

.ad-preview strong {
  display: block;
  font-size: 18px;
  font-weight: 950;
}

.ad-preview span {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.ad-preview.has-image {
  min-height: 156px;
  padding: 0;
  overflow: hidden;
  place-items: stretch;
  background: #fff;
}

.ad-preview.has-image img {
  width: 100%;
  height: 132px;
  display: block;
  object-fit: cover;
  background: #fff;
}

.ad-preview.has-image span {
  min-height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 0;
  padding: 0 10px;
  border-top: 1px solid var(--line);
}

.center-actions,
.card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 10px;
}

.center-actions .text-button,
.card-actions .text-button {
  flex: 1 1 104px;
}

.audit-item,
.report-row {
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 12px;
  font-weight: 850;
  line-height: 1.4;
}

.audit-item:last-child,
.report-row:last-child {
  border-bottom: 0;
}

.report-row strong {
  display: block;
  font-size: 13px;
  font-weight: 950;
}

.report-row span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.push-template-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.push-template {
  min-height: 78px;
  display: grid;
  align-content: center;
  gap: 5px;
  padding: 10px;
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  text-align: left;
}

.push-template:hover {
  border-color: var(--brand);
  background: var(--brand-soft);
}

.push-template strong {
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}

.push-template span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  line-height: 1.3;
}

.push-form,
.push-field,
.form-grid label {
  display: grid;
  gap: 7px;
}

.push-form {
  gap: 12px;
}

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

.push-field span,
.form-grid label span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.push-form input,
.push-form select,
.push-form textarea {
  width: 100%;
  min-height: 42px;
  padding: 10px 11px;
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  font-size: 13px;
  font-weight: 800;
}

.push-form textarea {
  min-height: 100px;
  line-height: 1.45;
  resize: vertical;
}

.push-preview {
  padding: 12px;
  border: 1px dashed var(--line-dark);
  border-radius: 8px;
  background: var(--soft);
}

.push-phone-card {
  max-width: 420px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(247, 173, 0, 0.48);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 18px 40px rgba(15, 12, 4, 0.12);
}

.push-dot {
  width: 38px;
  height: 38px;
  border-radius: 999px;
  background:
    radial-gradient(circle at 50% 50%, var(--brand) 0 42%, #050505 43% 100%);
}

.push-phone-card strong,
.push-phone-card span {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.push-phone-card strong {
  font-size: 13px;
  font-weight: 950;
}

.push-phone-card span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.push-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.push-row:last-child {
  border-bottom: 0;
}

.push-row strong,
.push-row span,
.push-row small {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.push-row strong {
  font-size: 13px;
  font-weight: 950;
}

.push-row span,
.push-row small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.push-counts {
  display: grid;
  justify-items: end;
  gap: 4px;
}

.field-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.field-list span {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #111;
  background: var(--soft);
  font-size: 11px;
  font-weight: 900;
}

.backend-notice {
  margin-bottom: 14px;
  padding: 10px 12px;
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  color: #111;
  background: #fff;
  font-size: 12px;
  font-weight: 850;
}

.backend-notice.good {
  color: var(--success);
  border-color: rgba(247, 173, 0, 0.5);
  background: var(--brand-soft);
}

.backend-notice.warn {
  color: var(--warning);
  border-color: rgba(154, 100, 0, 0.3);
  background: rgba(154, 100, 0, 0.1);
}

.backend-notice.danger {
  color: var(--danger);
  border-color: rgba(179, 38, 30, 0.28);
  background: rgba(179, 38, 30, 0.08);
}

.auth-panel {
  display: grid;
  gap: 16px;
}

.auth-panel h2 {
  margin-bottom: 6px;
  font-size: 18px;
  font-weight: 950;
}

.auth-panel p {
  max-width: 720px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.signin-form {
  max-width: 460px;
  display: grid;
  gap: 12px;
}

.signin-form label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.signin-form input,
.signin-form select {
  min-height: 42px;
  padding: 0 11px;
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  font-size: 14px;
  font-weight: 750;
  text-transform: none;
}

.logo-upload-box {
  display: grid;
  gap: 8px;
  padding: 11px;
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  background: var(--soft);
}

.logo-upload-box > span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.logo-upload-box input[type="file"] {
  min-height: 44px;
  padding: 9px;
  border: 1px dashed var(--line-dark);
  border-radius: 8px;
  background: #fff;
}

.logo-upload-preview,
.partner-title {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.logo-upload-preview img,
.partner-logo {
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  object-fit: contain;
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  background: #fff;
}

.partner-logo.placeholder {
  display: inline-grid;
  place-items: center;
  color: var(--muted);
  font-size: 10px;
  font-weight: 950;
}

.logo-upload-preview strong,
.partner-title h3,
.partner-title p {
  min-width: 0;
  overflow-wrap: anywhere;
}

.empty-state {
  padding: 20px;
  border: 1px dashed var(--line-dark);
  border-radius: 8px;
  color: var(--muted);
  background: #fffdf7;
  font-size: 13px;
  font-weight: 850;
  text-align: center;
}

.toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 40;
  max-width: min(360px, calc(100vw - 36px));
  padding: 12px 14px;
  border-radius: 8px;
  color: #050505;
  background: var(--brand);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.18);
  font-size: 13px;
  font-weight: 850;
}

.toast[hidden] {
  display: none;
}

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

  .role-picker {
    max-width: 260px;
  }

  .auth-status {
    justify-items: start;
  }

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

  .span-8,
  .span-7,
  .span-5,
  .span-4 {
    grid-column: span 12;
  }
}

@media (max-width: 720px) {
  body {
    background: #fff;
  }

  .header {
    position: static;
    padding: 14px;
  }

  .auth-status {
    min-width: 0;
  }

  .main {
    padding: 14px;
  }

  .context-bar {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 24px;
  }

  .metrics,
  .card-grid,
  .card-grid.two-col,
  .card-grid.one-col,
  .availability-grid,
  .control-grid {
    grid-template-columns: 1fr;
  }

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

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

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

  .push-counts {
    justify-items: start;
  }

  .panel-head,
  .attention-item {
    display: grid;
  }

  .attention-actions {
    justify-content: flex-start;
  }

  .table-wrap {
    display: none;
  }

  .mobile-list {
    display: grid;
    gap: 10px;
  }

  .mobile-card {
    padding: 12px;
    box-shadow: none;
  }

  .mobile-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
  }

  .mobile-card p {
    margin: 8px 0;
    color: var(--muted);
    font-size: 12px;
  }

  .mobile-card dl {
    display: grid;
    grid-template-columns: 82px minmax(0, 1fr);
    gap: 7px 10px;
    margin: 0;
  }

  .mobile-card dt {
    color: var(--muted);
    font-size: 11px;
    font-weight: 950;
    text-transform: uppercase;
  }

  .mobile-card dd {
    margin: 0;
    font-size: 12px;
    font-weight: 850;
  }
}

:root {
  --app-bg: #fbf6eb;
  --touch: 44px;
  --radius: 10px;
}

body {
  background: var(--app-bg);
  overflow-x: hidden;
}

.shell {
  background:
    radial-gradient(circle at 12% 0, rgba(247, 173, 0, 0.1), transparent 260px),
    linear-gradient(180deg, #fff 0, var(--app-bg) 280px, var(--app-bg) 100%);
}

.header {
  background: #fff;
  box-shadow: 0 10px 24px rgba(32, 22, 2, 0.08);
}

.logo-symbol {
  width: 126px;
  height: 136px;
}

.metric-card,
.panel,
.attention-item,
.status-card,
.availability-card,
.control-card,
.mobile-card,
.center-number,
.text-field,
.toast {
  border-radius: var(--radius);
}

.nav {
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.nav::-webkit-scrollbar {
  display: none;
}

.main {
  max-width: 1360px;
}

.button,
.danger-button,
.text-button,
.segmented button,
.nav-button {
  min-height: var(--touch);
  touch-action: manipulation;
}

.role-picker select,
.filter-picker select,
.signin-form input,
.signin-form select,
.meal-action-box input,
.text-button {
  min-height: var(--touch);
}

.data-table {
  min-width: 760px;
}

.table-wrap {
  -webkit-overflow-scrolling: touch;
}

.mobile-list .mobile-card {
  border-radius: 12px;
}

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

  .role-picker,
  .auth-status {
    width: 100%;
  }

  .header,
  .brand,
  .nav,
  .auth-status,
  .context-bar {
    justify-items: center;
    text-align: center;
  }

  .auth-status,
  .role-picker select,
  .filter-picker select {
    width: 100%;
  }

  .nav {
    justify-content: center;
    width: 100%;
  }
}

@media (max-width: 720px) {
  body {
    background: var(--app-bg);
    padding: env(safe-area-inset-top) 0 0;
  }

  .header {
    position: sticky;
    top: 0;
    z-index: 20;
    grid-template-columns: 1fr auto 1fr;
    gap: 10px;
    padding: 12px 12px 8px;
  }

  .logo-symbol {
    width: 98px;
    height: 106px;
  }

  .brand-name {
    font-size: 15px;
  }

  .brand-line {
    font-size: 10px;
  }

  .brand {
    justify-self: center;
    grid-column: 2;
  }

  .nav-desktop,
  .header > .auth-status,
  .header > .role-picker {
    display: none;
  }

  .menu-toggle {
    display: inline-flex;
    grid-column: 3;
    justify-self: end;
  }

  .mobile-nav {
    max-height: 0;
    overflow: hidden;
    transition:
      max-height 0.2s ease,
      opacity 0.2s ease;
    opacity: 0;
    pointer-events: none;
    background: #fff;
    border-bottom: 1px solid rgba(247, 173, 0, 0.44);
    border-top: none;
  }

  .mobile-nav.open {
    max-height: 460px;
    opacity: 1;
    pointer-events: auto;
  }

  .mobile-nav-inner {
    display: grid;
    gap: 8px;
    padding: 10px 12px 12px;
  }

  .mobile-nav .nav {
    display: grid;
    width: 100%;
    gap: 8px;
    justify-content: stretch;
  }

  .mobile-nav .nav .nav-button {
    width: 100%;
    justify-content: flex-start;
    border-radius: 12px;
    text-align: left;
    min-height: 44px;
  }

  .mobile-auth .auth-status {
    justify-items: start;
    padding: 8px 10px;
    border-top: 1px solid rgba(247, 173, 0, 0.26);
    margin-top: 4px;
  }

  .main {
    padding: 12px 12px 18px;
  }

  .context-bar {
    border-radius: 12px;
    box-shadow: none;
    text-align: center;
  }

  .context-bar .filter-picker,
  .context-bar .filter-picker select {
    width: 100%;
  }

  .panel,
  .attention-item,
  .status-card,
  .availability-card,
  .control-card,
  .mobile-card {
    border-radius: 12px;
  }

  .center-actions,
  .card-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .button,
  .danger-button,
  .text-button,
  .segmented button {
    width: 100%;
  }

  .meal-action-box input {
    min-height: 42px;
  }
}
