﻿:root {
  --bg: #f7f8f2;
  --panel: #ffffff;
  --ink: #101820;
  --muted: #667789;
  --line: #dfe8dd;
  --line-strong: #c9dac7;
  --brand: #aeea00;
  --brand-2: #d9ff21;
  --brand-dark: #1b3d2a;
  --brand-soft: #f0fad2;
  --green: #0a9f6a;
  --green-soft: #e5f8ef;
  --amber: #ffb545;
  --amber-soft: #fff5df;
  --red: #df4b38;
  --red-soft: #ffecea;
  --violet: #5b6ee1;
  --shadow: 0 24px 70px rgba(19, 49, 72, 0.14);
  --soft-shadow: 0 12px 32px rgba(19, 49, 72, 0.08);
  --hairline: 1px solid rgba(16, 24, 32, 0.08);
  --font-body: Aptos, "Segoe UI Variable", "Segoe UI", Inter, -apple-system, BlinkMacSystemFont, Arial, sans-serif;
  --font-display: "Aptos Display", Aptos, "Segoe UI Variable", "Segoe UI", Inter, -apple-system, BlinkMacSystemFont, Arial, sans-serif;
  font-family: var(--font-body);
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 10% -10%, rgba(47, 179, 109, 0.2), transparent 34rem),
    radial-gradient(circle at 90% 10%, rgba(185, 231, 105, 0.14), transparent 30rem),
    linear-gradient(135deg, #fbfdff 0%, var(--bg) 55%, #eef5f9 100%);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.45;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

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

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

h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: 0;
}

p {
  line-height: 1.5;
}

strong {
  font-weight: 800;
}

.shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 304px minmax(0, 1fr);
}

.rail {
  min-height: 100vh;
  position: sticky;
  top: 0;
  padding: 22px;
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 22px;
  background:
    radial-gradient(circle at 20% 0%, rgba(174, 234, 0, 0.22), transparent 18rem),
    linear-gradient(180deg, #1b3d2a 0%, #111111 100%);
  box-shadow: inset -1px 0 rgba(255, 255, 255, 0.08);
}

.brand {
  color: inherit;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px;
  border-radius: 8px;
}

.brand span {
  width: 50px;
  height: 50px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #111111;
  box-shadow: 0 16px 32px rgba(174, 234, 0, 0.26);
}

.brand-mark img {
  width: 50px;
  height: 50px;
  display: block;
  object-fit: cover;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-size: 1.12rem;
}

.brand small {
  color: #d7f7a4;
  margin-top: 2px;
  font-size: 0.72rem;
  font-weight: 850;
  text-transform: uppercase;
}

.role-nav {
  display: grid;
  gap: 8px;
}

.app-switcher {
  display: none;
}

body[data-role="admin"] .app-switcher {
  display: grid;
}

body:not([data-role="admin"]) .internal-only {
  display: none;
}

body[data-role="customer"] .staff-only {
  display: none;
}

.role-nav button {
  min-height: 48px;
  border: 0;
  border-radius: 8px;
  padding: 0 14px;
  text-align: left;
  color: #d9edf7;
  background: transparent;
  font-weight: 900;
  transition: background 140ms ease, transform 140ms ease;
}

.role-nav button:hover,
.role-nav button.active {
  background: rgba(255, 255, 255, 0.12);
}

.role-nav button.active {
  box-shadow: inset 3px 0 var(--brand-2);
}

.pilot-card {
  margin-top: auto;
  padding: 16px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(12px);
}

.pilot-card span,
.eyebrow {
  color: var(--brand);
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0;
}

.pilot-card span {
  color: #b8f07b;
}

.pilot-card strong {
  display: block;
  margin: 5px 0 6px;
  font-size: 1.2rem;
}

.pilot-card p {
  color: #bdd8e7;
  line-height: 1.48;
}

.app {
  min-width: 0;
  padding: 30px;
  display: grid;
  gap: 24px;
  align-content: start;
}

.topbar {
  min-height: 168px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  padding: 26px;
  border: var(--hairline);
  border-radius: 8px;
  color: #fff;
  background:
    linear-gradient(120deg, rgba(4, 47, 75, 0.92), rgba(47, 179, 109, 0.76)),
    url("https://images.unsplash.com/photo-1504674900247-0877df9cc836?auto=format&fit=crop&w=1800&q=80");
  background-size: cover;
  background-position: center;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.topbar .eyebrow {
  color: #b8ecff;
}

.topbar h1 {
  margin-top: 8px;
  max-width: 850px;
  font-size: clamp(2rem, 3.8vw, 4.1rem);
  line-height: 1;
  letter-spacing: 0;
}

.top-actions,
.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.top-actions {
  justify-content: flex-end;
  flex-wrap: wrap;
}

.primary-btn,
.ghost-btn {
  min-height: 42px;
  border-radius: 8px;
  border: 1px solid var(--line);
  padding: 0 14px;
  font-weight: 800;
  transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease;
}

.primary-btn {
  color: #111;
  border-color: transparent;
  background: linear-gradient(135deg, var(--brand-2), var(--brand));
  box-shadow: 0 12px 26px rgba(174, 234, 0, 0.24);
}

.ghost-btn {
  color: var(--ink);
  background: #fff;
}

.topbar .ghost-btn {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.13);
  backdrop-filter: blur(10px);
}

.topbar .ghost-btn.alert-on {
  color: #052235;
  border-color: rgba(255, 255, 255, 0.65);
  background: #fff;
}

.primary-btn:hover,
.ghost-btn:hover {
  transform: translateY(-1px);
}

.full {
  width: 100%;
}

.view {
  display: none;
}

.view.active {
  display: block;
}

.market-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  gap: 20px;
  align-items: start;
}

.market-main {
  display: grid;
  gap: 18px;
}

body[data-role="customer"] {
  background:
    linear-gradient(180deg, #05070a 0, #05070a 420px, #f7f8f2 421px, #f7f8f2 100%);
}

body[data-role="customer"] .topbar {
  display: none;
}

body[data-role="customer"] .app {
  padding-top: 22px;
}

#customerView[data-page="restaurants"] .market-layout {
  grid-template-columns: 1fr;
}

#customerView[data-page="restaurants"] .cart {
  display: none;
}

#customerView[data-page="restaurants"] .market-main {
  max-width: 1180px;
  width: 100%;
  margin: 0 auto;
}

#customerView[data-page="taxi"] .market-layout {
  grid-template-columns: 1fr;
}

#customerView[data-page="orders"] .market-layout {
  grid-template-columns: 1fr;
}

#customerView[data-page="tracking"] .market-layout {
  grid-template-columns: minmax(0, 760px);
  justify-content: center;
}

#customerView[data-page="taxi"] .cart {
  display: none;
}

#customerView[data-page="orders"] .cart {
  display: none;
}

#customerView[data-page="tracking"] .cart {
  position: static;
}

#customerView[data-page="tracking"] #cartItems,
#customerView[data-page="tracking"] .checkout,
#customerView[data-page="tracking"] .panel-head {
  display: none;
}

#customerView[data-page="taxi"] .market-main {
  max-width: 980px;
  width: 100%;
  margin: 0 auto;
}

#customerView[data-page="orders"] .market-main {
  max-width: 980px;
  width: 100%;
  margin: 0 auto;
}

#customerView[data-page="restaurant"] .market-main {
  gap: 0;
}

#customerView[data-page="restaurant"] .restaurant-detail {
  align-self: start;
}

.location-card,
.cart,
.board-panel,
.restaurant-card,
.restaurant-detail,
.stat-card {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--soft-shadow);
}

.location-card {
  display: grid;
  gap: 4px;
  padding: 18px 20px;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(135deg, rgba(16, 24, 32, 0.9), rgba(47, 179, 109, 0.25));
}

.location-card span {
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 900;
}

.location-card strong {
  font-size: 1.45rem;
}

.location-card p,
.muted {
  color: var(--muted);
}

.location-card p,
.location-card span {
  color: rgba(255, 255, 255, 0.72);
}

.service-categories {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding-bottom: 4px;
}

.service-tile {
  min-height: 128px;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 10px;
  border: 0;
  border-radius: 22px;
  padding: 14px;
  color: #fff;
  background: var(--tile);
  box-shadow: 0 18px 34px rgba(0, 0, 0, 0.2);
}

.service-tile span {
  font-size: 2.35rem;
}

.service-tile strong {
  font-size: 1.03rem;
}

.coming-soon-panel {
  display: grid;
  gap: 8px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(240, 250, 210, 0.84)),
    radial-gradient(circle at 100% 0%, rgba(174, 234, 0, 0.18), transparent 12rem);
  box-shadow: var(--soft-shadow);
}

.coming-soon-panel span {
  color: var(--brand-dark);
  font-size: 0.76rem;
  font-weight: 950;
  text-transform: uppercase;
}

.coming-soon-panel strong {
  color: var(--ink);
  font-size: 1.25rem;
}

.coming-soon-panel p {
  color: var(--muted);
  line-height: 1.45;
}

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

.product-filter-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.product-filter-row button {
  flex: 0 0 auto;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 14px;
  color: var(--ink);
  background: #fff;
  font-weight: 850;
}

.product-filter-row button.active {
  color: #111;
  border-color: rgba(174, 234, 0, 0.9);
  background: var(--brand);
}

.local-product-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.local-product-photo {
  min-height: 168px;
  background-size: cover;
  background-position: center;
}

.local-product-body {
  display: grid;
  gap: 14px;
  padding: 14px;
}

.local-product-body span {
  color: var(--brand-dark);
  font-size: 0.75rem;
  font-weight: 950;
  text-transform: uppercase;
}

.local-product-body h3 {
  margin-top: 4px;
  font-size: 1.18rem;
}

.local-product-body p {
  margin-top: 5px;
  color: var(--muted);
  line-height: 1.4;
}

.local-product-meta {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 10px;
  align-items: center;
}

.local-product-meta strong {
  color: var(--ink);
  font-size: 1.18rem;
}

.local-product-meta span {
  color: var(--muted);
  text-transform: none;
}

.local-product-meta em {
  grid-column: 1 / -1;
  color: var(--brand-dark);
  font-size: 0.86rem;
  font-style: normal;
  font-weight: 850;
}

.promo-spot {
  min-height: 260px;
  display: grid;
  align-items: end;
  overflow: hidden;
  border-radius: 18px;
  padding: 24px;
  color: #fff;
  background:
    linear-gradient(180deg, transparent 20%, rgba(0, 0, 0, 0.84)),
    linear-gradient(120deg, rgba(47, 179, 109, 0.2), rgba(223, 75, 56, 0.2)),
    url("https://images.unsplash.com/photo-1565299624946-b28f40a0ae38?auto=format&fit=crop&w=1400&q=80");
  background-size: cover;
  background-position: center;
  box-shadow: var(--shadow);
}

.promo-spot span {
  color: #9fe6ff;
  text-transform: uppercase;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
}

.promo-spot strong {
  display: block;
  margin-top: 6px;
  font-size: clamp(1.85rem, 4vw, 3.3rem);
  line-height: 1.03;
}

.promo-spot p {
  margin-top: 8px;
  max-width: 720px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 1.08rem;
  font-weight: 650;
}

.quick-order {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 18px 20px;
  border: 1px solid rgba(47, 179, 109, 0.2);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(230, 247, 255, 0.98), rgba(255, 255, 255, 0.96));
  box-shadow: var(--soft-shadow);
}

.quick-order[hidden] {
  display: none;
}

.quick-order span {
  color: var(--brand-dark);
  text-transform: uppercase;
  font-size: 0.76rem;
  font-weight: 850;
}

.quick-order strong {
  display: block;
  margin-top: 4px;
  font-size: 1.35rem;
}

.quick-order p,
.quick-order small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  line-height: 1.4;
}

.quick-order small {
  max-width: 820px;
  font-weight: 800;
}

.search {
  min-height: 56px;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 10px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--muted);
  background: #eaf3f8;
  font-weight: 900;
}

.search:focus-within {
  background: #fff;
  border-color: rgba(47, 179, 109, 0.34);
  box-shadow: 0 0 0 4px rgba(47, 179, 109, 0.1);
}

.search input {
  min-width: 0;
  border: 0;
  outline: 0;
  color: var(--ink);
  background: transparent;
}

.chips {
  display: flex;
  gap: 9px;
  overflow-x: auto;
  padding: 2px 2px 6px;
}

.chips button {
  min-height: 40px;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 15px;
  color: var(--ink);
  background: #fff;
  font-weight: 900;
  box-shadow: 0 8px 18px rgba(19, 49, 72, 0.05);
}

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

.restaurant-grid {
  display: grid;
  gap: 14px;
}

.market-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.market-section-head h2 {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
}

.restaurant-card-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.restaurant-card {
  position: relative;
  color: inherit;
  text-decoration: none;
  padding: 0;
  overflow: hidden;
  text-align: left;
  border: 1px solid var(--line);
  cursor: pointer;
  transition: transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease;
}

.restaurant-card:hover,
.restaurant-card.selected {
  transform: translateY(-2px);
  border-color: rgba(47, 179, 109, 0.45);
  box-shadow: var(--shadow);
}

.restaurant-card.selected {
  outline: 3px solid rgba(47, 179, 109, 0.13);
}

.photo {
  min-height: 160px;
  background-size: cover;
  background-position: center;
}

.deal-ribbon {
  position: absolute;
  z-index: 2;
  top: 14px;
  left: 14px;
  border-radius: 999px;
  padding: 7px 11px;
  color: #fff;
  background: #ff3b2f;
  font-size: 0.82rem;
  font-weight: 850;
  box-shadow: 0 8px 18px rgba(223, 75, 56, 0.24);
}

.restaurant-body {
  display: grid;
  gap: 8px;
  padding: 15px;
}

.restaurant-body h3,
.restaurant-detail h2,
.board-panel h2 {
  margin: 0;
}

.restaurant-body h3 {
  font-size: 1.12rem;
}

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

.pill,
.status-pill {
  min-height: 27px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0 9px;
  color: var(--brand-dark);
  background: var(--brand-soft);
  font-size: 0.78rem;
  font-weight: 850;
  white-space: nowrap;
}

.restaurant-detail {
  display: grid;
  gap: 0;
  overflow: hidden;
}

.taxi-view {
  display: grid;
  gap: 14px;
}

.order-history {
  display: grid;
  gap: 14px;
}

.history-hero {
  display: grid;
  gap: 8px;
  border-radius: 18px;
  padding: 26px;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(5, 7, 10, 0.92), rgba(47, 179, 109, 0.48)),
    url("https://images.unsplash.com/photo-1540189549336-e6e99c3679fe?auto=format&fit=crop&w=1400&q=80");
  background-size: cover;
  background-position: center;
  box-shadow: var(--shadow);
}

.history-hero span {
  color: #9fe6ff;
  text-transform: uppercase;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0;
}

.history-hero h2 {
  font-size: clamp(1.9rem, 4vw, 3.4rem);
  line-height: 1.04;
}

.history-hero p {
  max-width: 660px;
  color: rgba(255, 255, 255, 0.84);
  font-weight: 650;
}

.history-list {
  display: grid;
  gap: 12px;
}

.history-card {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.history-card > div:last-child {
  display: grid;
  justify-items: end;
  gap: 8px;
}

.history-empty {
  padding: 14px;
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
  text-align: center;
}

.taxi-hero {
  min-height: 280px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 18px;
  border-radius: 18px;
  padding: 26px;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(5, 7, 10, 0.88), rgba(255, 181, 69, 0.52)),
    url("https://images.unsplash.com/photo-1511527844068-006b95d162c2?auto=format&fit=crop&w=1400&q=80");
  background-size: cover;
  background-position: center;
  box-shadow: var(--shadow);
}

.taxi-hero span {
  color: #ffe29b;
  text-transform: uppercase;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0;
}

.taxi-hero h2 {
  margin-top: 7px;
  font-size: clamp(2rem, 4vw, 3.6rem);
  line-height: 1.04;
}

.taxi-hero p {
  max-width: 620px;
  margin-top: 10px;
  color: rgba(255, 255, 255, 0.84);
  font-weight: 800;
}

.taxi-hero > strong {
  min-width: 120px;
  border-radius: 999px;
  padding: 12px 16px;
  color: var(--ink);
  background: #fff;
  text-align: center;
}

.taxi-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, 0.8fr);
  gap: 16px;
}

.taxi-form,
.taxi-status {
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

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

.taxi-form label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 900;
}

.vehicle-choice {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 900;
}

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

.taxi-vehicle-card {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-height: 82px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  color: var(--ink);
  background: #fff;
  text-align: left;
  box-shadow: 0 8px 18px rgba(19, 49, 72, 0.05);
  transition: border-color 140ms ease, box-shadow 140ms ease, transform 140ms ease;
}

.taxi-vehicle-card:hover {
  transform: translateY(-1px);
}

.taxi-vehicle-card.active {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(17, 166, 222, 0.16), 0 10px 24px rgba(19, 49, 72, 0.08);
}

.taxi-vehicle-card strong,
.taxi-vehicle-card small {
  display: block;
}

.taxi-vehicle-card strong {
  font-size: 0.98rem;
  font-weight: 950;
}

.taxi-vehicle-card small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
}

.taxi-vehicle-icon {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: var(--brand-dark);
  background: #edf9ee;
}

.taxi-vehicle-icon svg {
  width: 42px;
  height: 28px;
  fill: currentColor;
}

.taxi-form input,
.taxi-form select {
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  color: var(--ink);
  background: #fff;
}

.address-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.address-input-row .ghost-btn {
  min-width: 172px;
}

.taxi-form small,
.checkout small {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.35;
}

.taxi-form small[data-tone="success"],
.checkout small[data-tone="success"] {
  color: var(--green);
}

.taxi-form small[data-tone="error"],
.checkout small[data-tone="error"] {
  color: var(--red);
}

.address-input-row .ghost-btn:disabled {
  cursor: wait;
  opacity: 0.72;
}

.taxi-form small[data-tone="success"] {
  color: #07845f;
}

.taxi-form small[data-tone="error"] {
  color: #c04232;
}

.taxi-estimate {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.taxi-map-links {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.taxi-map-links .ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  text-align: center;
  text-decoration: none;
}

.taxi-estimate div {
  display: grid;
  gap: 4px;
  padding: 12px;
  border-radius: 8px;
  background: #f7fbf3;
}

.taxi-estimate span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
}

.taxi-form .primary-btn {
  grid-column: 1 / -1;
}

.taxi-route-card {
  display: grid;
  gap: 5px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7fbf3;
}

.taxi-route-card span,
.taxi-summary span {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 850;
}

.taxi-route-card strong + span {
  margin-top: 8px;
}

.taxi-progress {
  display: grid;
  gap: 8px;
}

.taxi-progress span {
  position: relative;
  padding-left: 12px;
  border-left: 3px solid var(--line-strong);
  color: var(--muted);
  font-weight: 850;
}

.taxi-progress span.done {
  color: var(--brand-dark);
  border-color: var(--brand);
}

.taxi-progress span.current::before {
  content: "";
  position: absolute;
  left: -8px;
  top: 50%;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--brand);
  transform: translateY(-50%);
  animation: currentStep 1.2s ease-in-out infinite;
}

.taxi-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.taxi-summary div {
  display: grid;
  gap: 4px;
  padding: 10px;
  border-radius: 8px;
  background: #f8fbfd;
}

.back-link {
  justify-self: start;
  min-height: 40px;
  margin: 12px 12px 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  color: var(--brand-dark);
  background: #fff;
  font-weight: 850;
  z-index: 2;
}

.restaurant-hero {
  position: relative;
  min-height: 260px;
  display: grid;
  align-items: end;
  padding: 20px;
  color: #fff;
  background: #082235;
}

.restaurant-hero-photo {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}

.restaurant-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, transparent 20%, rgba(0, 0, 0, 0.76)),
    linear-gradient(90deg, rgba(0, 0, 0, 0.58), transparent);
}

.restaurant-hero-copy,
.restaurant-hero .status-pill {
  position: relative;
  z-index: 1;
}

.restaurant-hero .status-pill {
  position: absolute;
  top: 16px;
  right: 16px;
  color: var(--green);
  background: #fff;
}

.restaurant-hero-copy {
  display: grid;
  gap: 9px;
  max-width: 680px;
}

.restaurant-hero-copy h2 {
  font-size: clamp(1.85rem, 3vw, 2.85rem);
  line-height: 1.05;
}

.restaurant-hero-copy p {
  color: rgba(255, 255, 255, 0.84);
  line-height: 1.5;
}

.section-title {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 18px 0;
}

.section-title h3 {
  font-size: 1.28rem;
}

.menu-category-nav {
  position: sticky;
  top: 0;
  z-index: 6;
  display: flex;
  gap: 8px;
  padding: 12px 18px;
  overflow-x: auto;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(14px);
  scrollbar-width: none;
}

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

.menu-category-nav button {
  min-height: 40px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  background: #fff;
  font-weight: 800;
  white-space: nowrap;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.05);
}

.menu-category-nav button.active,
.menu-category-nav button:hover {
  color: #fff;
  border-color: var(--ink);
  background: var(--ink);
}

.menu-category-section {
  display: grid;
  gap: 0;
  scroll-margin-top: 72px;
}

.menu-category-section + .menu-category-section {
  border-top: 1px solid var(--line);
}

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

.dish {
  min-height: 130px;
  display: grid;
  grid-template-columns: 1fr 116px;
  gap: 12px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  transition: border-color 140ms ease, transform 140ms ease;
}

.dish:hover {
  transform: translateY(-1px);
  border-color: rgba(47, 179, 109, 0.35);
}

.dish-info {
  display: grid;
  align-content: center;
  gap: 7px;
}

.dish-info strong:first-child {
  font-size: 1.02rem;
  line-height: 1.25;
}

.dish-ingredients {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.35;
}

.dish-photo {
  border-radius: 8px;
  background-size: cover;
  background-position: center;
}

.cart {
  position: sticky;
  top: 18px;
  display: grid;
  gap: 14px;
  padding: 18px;
}

.mobile-tabbar {
  display: none;
}

.cart .panel-head h2 {
  font-size: 1.35rem;
}

.cart-line,
.delivery-card,
.admin-row,
.menu-row {
  padding: 12px 0;
  border-top: 1px solid var(--line);
}

.cart-line:first-child,
.delivery-card:first-child,
.admin-row:first-child,
.menu-row:first-child {
  border-top: 0;
}

.courier-subhead {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.taxi-card {
  border-left: 4px solid var(--amber);
}

.cart-line {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
}

.stepper {
  display: flex;
  align-items: center;
  gap: 5px;
}

.stepper button {
  width: 32px;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--brand-dark);
  background: var(--brand-soft);
  font-weight: 850;
}

.checkout {
  display: grid;
  gap: 10px;
}

.cart-breakdown {
  display: grid;
  gap: 7px;
  padding: 10px 0 2px;
  border-top: 1px solid var(--line);
}

.cart-breakdown div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 850;
}

.cart-breakdown strong {
  color: var(--ink);
}

.tax-note {
  padding-top: 4px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.35;
}

.payment-options {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7fbf3;
}

.payment-options label {
  min-height: 40px;
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--ink);
}

.payment-options input {
  width: 18px;
  min-height: 18px;
}

.checkout label,
.compact-field {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 900;
}

.checkout input,
.compact-field select,
.pin-card input {
  min-height: 44px;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  color: var(--ink);
  background: #fff;
}

.checkout input:focus,
.compact-field select:focus,
.pin-card input:focus {
  outline: 0;
  border-color: rgba(47, 179, 109, 0.55);
  box-shadow: 0 0 0 4px rgba(47, 179, 109, 0.1);
}

.total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 13px;
  border-top: 1px solid var(--line);
}

.total-row strong {
  font-size: 1.55rem;
}

.tracking {
  display: grid;
  gap: 12px;
  padding: 14px;
  border-radius: 8px;
  background: #f7fbf3;
}

.live-status {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 12px;
  align-items: center;
  padding: 13px;
  border: 1px solid rgba(47, 179, 109, 0.16);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.08);
}

.live-pulse {
  position: relative;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: var(--brand);
  box-shadow: 0 0 0 8px rgba(47, 179, 109, 0.1);
}

.live-pulse::before,
.live-pulse::after {
  content: "";
  position: absolute;
  inset: -7px;
  border: 2px solid rgba(47, 179, 109, 0.26);
  border-radius: inherit;
  animation: livePulse 1.7s ease-out infinite;
}

.live-pulse::after {
  animation-delay: 0.65s;
}

.live-status small {
  display: block;
  margin-bottom: 3px;
  color: var(--brand-dark);
  font-size: 0.72rem;
  font-weight: 850;
  text-transform: uppercase;
}

.live-status strong {
  display: block;
  font-size: 1.08rem;
}

.live-status p {
  margin-top: 3px;
  color: var(--muted);
  line-height: 1.4;
}

.live-delivered .live-pulse {
  background: var(--green);
  box-shadow: 0 0 0 8px rgba(0, 167, 111, 0.12);
}

.live-new {
  border-color: rgba(16, 24, 32, 0.08);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(246, 251, 254, 0.96)),
    linear-gradient(120deg, rgba(47, 179, 109, 0.08), rgba(185, 231, 105, 0.08));
}

.live-new .live-pulse {
  background: var(--ink);
  box-shadow: 0 0 0 8px rgba(16, 24, 32, 0.08);
}

.live-new .live-pulse::before,
.live-new .live-pulse::after {
  border-color: rgba(16, 24, 32, 0.18);
}

.kitchen-wait {
  position: relative;
  min-height: 104px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  align-items: center;
  gap: 12px;
  overflow: hidden;
  border: 1px solid rgba(16, 24, 32, 0.08);
  border-radius: 8px;
  padding: 16px 18px 34px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(241, 249, 253, 0.96)),
    radial-gradient(circle at 18% 30%, rgba(47, 179, 109, 0.12), transparent 12rem);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.kitchen-wait span {
  min-height: 42px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(47, 179, 109, 0.16), rgba(185, 231, 105, 0.26));
  transform: scaleY(0.72);
  animation: kitchenConfirm 1.8s ease-in-out infinite;
}

.kitchen-wait span:nth-child(2) {
  animation-delay: 0.22s;
}

.kitchen-wait span:nth-child(3) {
  animation-delay: 0.44s;
}

.kitchen-wait strong {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 10px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
  text-align: center;
}

.polva-wait-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(16, 24, 32, 0.08);
  border-radius: 8px;
  padding: 16px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(238, 249, 252, 0.94)),
    radial-gradient(circle at 100% 0%, rgba(47, 179, 109, 0.15), transparent 12rem);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.polva-wait-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: linear-gradient(180deg, var(--brand), var(--green));
}

.polva-wait-card div {
  display: grid;
  gap: 5px;
}

.polva-wait-card span {
  color: var(--brand-dark);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.polva-wait-card strong {
  color: var(--ink);
  font-size: 1.05rem;
  font-weight: 950;
}

.polva-wait-card p {
  color: var(--muted);
  line-height: 1.45;
}

.order-motion {
  position: relative;
  min-height: 74px;
  padding: 18px 20px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(231, 248, 255, 0.9)),
    repeating-linear-gradient(90deg, transparent 0 26px, rgba(47, 179, 109, 0.06) 27px);
}

.motion-line {
  position: absolute;
  left: 38px;
  right: 38px;
  top: 36px;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(47, 179, 109, 0.22), rgba(47, 179, 109, 0.62));
}

.motion-point {
  position: absolute;
  top: 27px;
  z-index: 2;
  width: 22px;
  height: 22px;
  border: 4px solid #fff;
  border-radius: 999px;
  background: var(--brand);
  box-shadow: 0 8px 20px rgba(47, 179, 109, 0.22);
}

.point-restaurant {
  left: 26px;
}

.point-home {
  right: 26px;
  background: var(--green);
}

.motion-runner {
  position: absolute;
  left: 34px;
  top: 28px;
  z-index: 3;
  width: 20px;
  height: 20px;
  border-radius: 999px;
  background: var(--ink);
  box-shadow: 0 0 0 7px rgba(16, 24, 32, 0.08);
  animation: orderRunner 2.6s ease-in-out infinite;
}

.motion-new .motion-runner,
.motion-preparing .motion-runner {
  animation: kitchenRunner 1.45s ease-in-out infinite;
}

.motion-ready .motion-runner {
  animation-duration: 3.2s;
}

.motion-delivered .motion-runner {
  left: auto;
  right: 28px;
  background: var(--green);
  animation: deliveredPulse 1.8s ease-in-out infinite;
}

.motion-label {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 8px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
  text-align: center;
}

.courier-tools {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin-bottom: 12px;
}

.mini-map {
  position: relative;
  min-height: 220px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(230, 247, 255, 0.92), rgba(246, 251, 254, 0.96)),
    repeating-linear-gradient(0deg, transparent 0 27px, rgba(16, 24, 32, 0.04) 28px),
    repeating-linear-gradient(90deg, transparent 0 27px, rgba(16, 24, 32, 0.04) 28px);
}

.mini-map.empty {
  display: grid;
  place-items: center;
  padding: 18px;
  text-align: center;
}

.map-road {
  position: absolute;
  height: 9px;
  border-radius: 999px;
  background: rgba(47, 179, 109, 0.22);
  box-shadow: 0 0 0 1px rgba(47, 179, 109, 0.12);
}

.road-one {
  width: 86%;
  left: 7%;
  top: 52%;
  transform: rotate(-17deg);
}

.road-two {
  width: 68%;
  left: 13%;
  top: 34%;
  transform: rotate(26deg);
}

.road-three {
  width: 72%;
  left: 17%;
  top: 70%;
  transform: rotate(8deg);
  background: rgba(10, 159, 106, 0.18);
}

.map-label {
  position: absolute;
  padding: 4px 7px;
  border-radius: 999px;
  color: var(--brand-dark);
  background: rgba(255, 255, 255, 0.82);
  font-size: 0.72rem;
  font-weight: 850;
}

.label-center {
  left: 36%;
  top: 45%;
}

.label-station {
  left: 12%;
  top: 27%;
}

.label-lake {
  right: 9%;
  bottom: 18%;
}

.courier-pin {
  position: absolute;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(47, 179, 109, 0.22);
  transform: translate(-50%, -50%);
  box-shadow: 0 0 0 10px rgba(47, 179, 109, 0.08);
}

.courier-pin span {
  width: 15px;
  height: 15px;
  border: 3px solid #fff;
  border-radius: 999px;
  background: var(--brand);
  box-shadow: 0 8px 18px rgba(47, 179, 109, 0.34);
}

.map-meta {
  display: grid;
  gap: 3px;
  padding-top: 9px;
}

.map-meta span,
.location-note {
  color: var(--muted);
  font-size: 0.86rem;
}

.progress {
  display: grid;
  gap: 8px;
}

.progress span {
  padding-left: 10px;
  border-left: 3px solid var(--line-strong);
  color: var(--muted);
  font-weight: 900;
}

.progress span.done {
  color: var(--brand-dark);
  border-color: var(--brand);
}

.progress span.current {
  position: relative;
  color: var(--ink);
}

.progress span.current::before {
  content: "";
  position: absolute;
  left: -8px;
  top: 50%;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--brand);
  transform: translateY(-50%);
  animation: currentStep 1.2s ease-in-out infinite;
}

@keyframes livePulse {
  from {
    opacity: 0.9;
    transform: scale(0.68);
  }
  to {
    opacity: 0;
    transform: scale(1.35);
  }
}

@keyframes orderRunner {
  0%,
  100% {
    left: 34px;
  }
  50% {
    left: calc(100% - 54px);
  }
}

@keyframes kitchenRunner {
  0%,
  100% {
    left: 34px;
    transform: scale(0.9);
  }
  50% {
    left: 88px;
    transform: scale(1.12);
  }
}

@keyframes kitchenConfirm {
  0%,
  100% {
    opacity: 0.55;
    transform: scaleY(0.62);
  }
  45% {
    opacity: 1;
    transform: scaleY(1);
  }
}

@keyframes deliveredPulse {
  0%,
  100% {
    transform: scale(0.96);
  }
  50% {
    transform: scale(1.16);
  }
}

@keyframes currentStep {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(47, 179, 109, 0.28);
  }
  50% {
    box-shadow: 0 0 0 7px rgba(47, 179, 109, 0);
  }
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  align-items: start;
}

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

.board-panel {
  padding: 18px;
}

.board-panel > h2 {
  margin-bottom: 14px;
}

.panel-head {
  margin-bottom: 14px;
}

.compact-field {
  margin-top: 10px;
}

.order-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(240px, 1fr));
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.order-column {
  min-height: 260px;
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 12px;
  border: 1px solid #e8f1f7;
  border-radius: 8px;
  background: #f5f9fc;
}

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

.column-head h3 {
  margin: 0;
  color: var(--ink);
  font-size: 1.05rem;
}

.column-head span {
  min-width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: var(--brand-dark);
  background: var(--brand-soft);
  font-weight: 850;
}

.column-hint {
  min-height: 38px;
  font-size: 0.84rem;
}

.order-empty {
  padding: 14px;
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
  text-align: center;
}

.order-card,
.delivery-card {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 18px rgba(19, 49, 72, 0.06);
}

.order-card {
  border-left: 4px solid var(--brand);
}

.order-main {
  display: grid;
  gap: 4px;
}

.order-main p {
  color: var(--muted);
  line-height: 1.35;
}

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

.order-facts span {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0 9px;
  background: #f2f7fb;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 900;
}

.prep-time {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 900;
}

.prep-choices {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}

.prep-choices button {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 8px;
  color: var(--ink);
  background: #fff;
  font-weight: 850;
}

.prep-choices button.active,
.prep-choices button:hover {
  color: #fff;
  border-color: var(--brand);
  background: var(--brand);
}

.order-confirmed {
  border-left-color: var(--violet);
}

.order-preparing {
  border-left-color: var(--amber);
}

.order-ready {
  border-left-color: var(--green);
}

.order-picked {
  border-left-color: var(--brand-dark);
}

.order-top,
.order-actions,
.menu-row {
  display: grid;
  gap: 10px;
}

.order-top {
  grid-template-columns: 1fr auto;
  align-items: center;
}

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

.order-actions .primary-btn,
.order-actions .ghost-btn {
  width: 100%;
}

.courier-card-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr)) 1.4fr;
  gap: 8px;
}

.courier-card-actions .primary-btn,
.courier-card-actions .ghost-btn {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  text-decoration: none;
}

.menu-row {
  grid-template-columns: 58px 1fr auto;
  align-items: center;
}

.menu-toolbar,
.menu-row-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.menu-thumb {
  width: 58px;
  aspect-ratio: 1;
  border-radius: 8px;
  background: #edf5fa;
  background-size: cover;
  background-position: center;
  border: 1px solid var(--line);
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.stat-card {
  padding: 18px;
  position: relative;
  overflow: hidden;
}

.stat-card::after {
  content: "";
  position: absolute;
  top: -26px;
  right: -24px;
  width: 92px;
  height: 92px;
  border-radius: 50%;
  background: rgba(47, 179, 109, 0.1);
}

.stat-card span {
  color: var(--muted);
  font-weight: 900;
}

.stat-card strong {
  display: block;
  margin-top: 7px;
  font-size: 2.15rem;
}

.admin-table,
#adminPartners,
.delivery-list,
#restaurantMenu {
  display: grid;
  gap: 10px;
}

.admin-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px 12px;
  align-items: center;
}

.admin-row p {
  grid-column: 1;
}

.pin-dialog {
  width: min(430px, calc(100% - 32px));
  border: 0;
  border-radius: 8px;
  padding: 0;
  box-shadow: var(--shadow);
}

.editor-dialog {
  width: min(620px, calc(100% - 32px));
  border: 0;
  border-radius: 8px;
  padding: 0;
  box-shadow: var(--shadow);
}

.editor-dialog::backdrop {
  background: rgba(6, 31, 49, 0.56);
  backdrop-filter: blur(7px);
}

.editor-card {
  display: grid;
  gap: 14px;
  padding: 24px;
}

.editor-card label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 900;
}

.editor-card input {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  color: var(--ink);
}

.editor-card input:focus {
  outline: 0;
  border-color: rgba(47, 179, 109, 0.55);
  box-shadow: 0 0 0 4px rgba(47, 179, 109, 0.1);
}

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

.checkbox-line {
  grid-template-columns: auto 1fr;
  align-items: center;
  align-content: center;
}

.checkbox-line input {
  width: 20px;
  min-height: 20px;
}

.image-preview {
  min-height: 180px;
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
  background: #f7fbf3;
  background-size: cover;
  background-position: center;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-weight: 900;
}

.menu-option-count,
.cart-options {
  color: var(--brand-dark);
  font-size: 0.82rem;
  font-weight: 900;
}

.cart-options {
  margin: 2px 0 0;
  color: var(--muted);
  line-height: 1.35;
}

.option-editor-block {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7fbf3;
}

.option-editor-block .panel-head {
  margin-bottom: 0;
}

.menu-option-editor {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.option-editor-head,
.option-editor-toggles,
.choice-editor,
.dish-dialog-head,
.dish-dialog-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.option-editor-head {
  align-items: end;
}

.option-editor-head label {
  flex: 1;
}

.option-editor-toggles {
  flex-wrap: wrap;
}

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

.choice-editor {
  display: grid;
  grid-template-columns: 1fr 110px 38px;
}

.icon-btn {
  min-width: 38px;
  width: 38px;
  min-height: 38px;
  padding: 0;
}

.slim {
  min-height: 38px;
}

.option-empty {
  padding: 12px;
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
  text-align: center;
}

.dish-dialog {
  width: min(560px, calc(100% - 32px));
  border: 0;
  border-radius: 8px;
  padding: 0;
  box-shadow: var(--shadow);
}

.dish-dialog::backdrop {
  background: rgba(6, 31, 49, 0.56);
  backdrop-filter: blur(7px);
}

.dish-card {
  display: grid;
  max-height: min(88vh, 760px);
  overflow: auto;
  background: #fff;
}

.dish-dialog-photo {
  min-height: 180px;
  background-size: cover;
  background-position: center;
}

.dish-dialog-head {
  justify-content: space-between;
  align-items: start;
  padding: 18px 20px 8px;
}

#dishOptions {
  display: grid;
  gap: 12px;
  padding: 8px 20px 18px;
}

.option-group {
  display: grid;
  gap: 8px;
}

.option-group-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.option-group-head span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
}

.option-choice {
  min-height: 46px;
  display: grid;
  grid-template-columns: 22px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f9fcfe;
  font-weight: 900;
}

.option-choice input {
  width: 18px;
  min-height: 18px;
}

.option-choice strong {
  color: var(--brand-dark);
}

.dish-dialog-actions {
  position: sticky;
  bottom: 0;
  justify-content: space-between;
  padding: 14px 20px;
  border-top: 1px solid var(--line);
  background: #fff;
}

.dish-dialog-actions strong {
  font-size: 1.35rem;
}

.pin-dialog::backdrop {
  background: rgba(6, 31, 49, 0.56);
  backdrop-filter: blur(7px);
}

.pin-card {
  display: grid;
  gap: 12px;
  padding: 24px;
}

.pin-card h2 {
  margin: 0;
}

.pin-card input {
  font-size: 1.15rem;
}

.pin-error {
  min-height: 20px;
  color: var(--red);
  font-weight: 900;
}

.pin-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.toast {
  position: fixed;
  right: 22px;
  bottom: 22px;
  max-width: min(360px, calc(100vw - 44px));
  padding: 14px 16px;
  border-radius: 8px;
  background: #061f31;
  color: #fff;
  box-shadow: var(--shadow);
  font-weight: 900;
  transform: translateY(16px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease;
  z-index: 20;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

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

  .rail {
    position: static;
    min-height: auto;
  }

  .role-nav {
    grid-template-columns: repeat(4, 1fr);
  }

  .market-layout,
  .dashboard-grid,
  .stats {
    grid-template-columns: 1fr;
  }

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

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

  .cart {
    position: static;
  }
}

@media (max-width: 760px) {
  body[data-role="customer"] {
    padding-bottom: 96px;
  }

  .app,
  .rail {
    padding: 16px;
  }

  .topbar {
    min-height: 240px;
    align-items: flex-start;
    flex-direction: column;
  }

  .top-actions {
    width: 100%;
  }

  .top-actions .primary-btn,
  .top-actions .ghost-btn {
    flex: 1;
  }

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

  .restaurant-card-row,
  .local-product-grid,
  .menu-grid {
    grid-template-columns: 1fr;
  }

  .service-categories {
    grid-template-columns: 1fr;
  }

  .promo-spot {
    min-height: 230px;
  }

  body[data-role="customer"] .rail {
    display: none;
  }

  body[data-role="customer"] .app {
    padding: 14px;
  }

  body[data-role="customer"] .cart {
    position: static;
    margin-top: 12px;
  }

  .mobile-tabbar {
    position: fixed;
    left: 50%;
    bottom: 18px;
    z-index: 30;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    width: min(440px, calc(100% - 28px));
    padding: 8px;
    border: 1px solid rgba(255, 255, 255, 0.78);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.24);
    transform: translateX(-50%);
    backdrop-filter: blur(14px);
  }

  .mobile-tabbar button {
    position: relative;
    min-height: 58px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    border: 0;
    border-radius: 999px;
    color: var(--ink);
    background: transparent;
    font-weight: 850;
  }

  .mobile-tabbar button.active,
  .mobile-tabbar button:hover {
    color: #fff;
    background: var(--ink);
  }

  .mobile-tabbar span {
    font-size: 1.2rem;
    line-height: 1;
  }

  .mobile-tabbar strong {
    font-size: 0.76rem;
    line-height: 1;
  }

  .mobile-tabbar em {
    position: absolute;
    top: 5px;
    right: 18px;
    min-width: 20px;
    height: 20px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #fff;
    background: var(--brand);
    font-size: 0.72rem;
    font-style: normal;
  }

  .mobile-tabbar em[hidden] {
    display: none;
  }

  .dish {
    grid-template-columns: 1fr 108px;
  }

  .restaurant-hero {
    min-height: 320px;
  }

  .section-title,
  .panel-head,
  .admin-row,
  .quick-order,
  .taxi-hero,
  .taxi-panel,
  .taxi-form,
  .taxi-estimate,
  .taxi-map-links,
  .taxi-vehicle-grid,
  .address-input-row,
  .history-card {
    align-items: flex-start;
    grid-template-columns: 1fr;
  }

  .address-input-row .ghost-btn {
    width: 100%;
  }

  .panel-head {
    flex-direction: column;
  }

  .editor-grid,
  .menu-row,
  .courier-tools,
  .choice-editor {
    grid-template-columns: 1fr;
  }

  .menu-row-actions {
    justify-content: stretch;
  }

  .menu-row-actions .ghost-btn,
  .menu-toolbar .ghost-btn {
    flex: 1;
  }
}


